hotime/example/tpt/wx/js/chunk-vendors.5cecbfc6.js.map
2022-03-03 21:23:57 +08:00

1 line
1.5 MiB

{"version":3,"sources":["webpack:///./node_modules/core-js/internals/to-string-tag-support.js","webpack:///./node_modules/core-js/internals/function-bind-context.js","webpack:///./node_modules/vant/es/cell-group/style/index.js","webpack:///./node_modules/core-js/internals/object-get-own-property-descriptor.js","webpack:///./node_modules/core-js/internals/length-of-array-like.js","webpack:///./node_modules/vant/es/config-provider/index.js","webpack:///./node_modules/core-js/internals/array-species-constructor.js","webpack:///./node_modules/core-js/internals/get-substitution.js","webpack:///./node_modules/vant/es/sticky/style/index.js","webpack:///./node_modules/core-js/internals/ie8-dom-define.js","webpack:///./node_modules/core-js/internals/try-to-string.js","webpack:///./node_modules/core-js/internals/regexp-unsupported-ncg.js","webpack:///./node_modules/core-js/internals/regexp-exec-abstract.js","webpack:///./node_modules/core-js/internals/is-callable.js","webpack:///./node_modules/core-js/internals/an-instance.js","webpack:///./node_modules/vant/es/switch/Switch.js","webpack:///./node_modules/vant/es/switch/index.js","webpack:///./node_modules/core-js/internals/has-own-property.js","webpack:///./node_modules/core-js/internals/html.js","webpack:///./node_modules/vant/es/composables/on-popup-reopen.js","webpack:///./node_modules/core-js/internals/check-correctness-of-iteration.js","webpack:///./node_modules/core-js/internals/engine-is-ios.js","webpack:///./node_modules/core-js/internals/require-object-coercible.js","webpack:///./node_modules/vant/es/utils/mount-component.js","webpack:///./node_modules/core-js/internals/array-method-has-species-support.js","webpack:///./node_modules/core-js/internals/iterate.js","webpack:///./node_modules/core-js/internals/to-absolute-index.js","webpack:///./node_modules/core-js/internals/export.js","webpack:///./node_modules/core-js/internals/object-get-own-property-names.js","webpack:///./node_modules/core-js/internals/set-species.js","webpack:///./node_modules/vant/es/image-preview/index.js","webpack:///./node_modules/vant/es/list/style/index.js","webpack:///./node_modules/core-js/internals/iterator-close.js","webpack:///./node_modules/core-js/internals/function-apply.js","webpack:///./node_modules/vant/es/composables/use-tab-status.js","webpack:///./node_modules/vant/es/list/List.js","webpack:///./node_modules/vant/es/list/index.js","webpack:///./node_modules/core-js/internals/task.js","webpack:///./node_modules/core-js/internals/engine-v8-version.js","webpack:///./node_modules/vant/es/composables/use-visibility-change.js","webpack:///./node_modules/vant/es/sticky/Sticky.js","webpack:///./node_modules/vant/es/sticky/index.js","webpack:///./node_modules/core-js/internals/engine-user-agent.js","webpack:///./node_modules/vant/es/cell-group/CellGroup.js","webpack:///./node_modules/vant/es/cell-group/index.js","webpack:///./node_modules/core-js/internals/get-iterator-method.js","webpack:///./node_modules/core-js/internals/object-define-properties.js","webpack:///./node_modules/core-js/internals/object-is-prototype-of.js","webpack:///./node_modules/vant/es/checkbox-group/index.js","webpack:///./node_modules/core-js/internals/a-possible-prototype.js","webpack:///./node_modules/vant/es/config-provider/ConfigProvider.js","webpack:///./node_modules/vant/es/checkbox/style/index.js","webpack:///./node_modules/core-js/modules/es.string.iterator.js","webpack:///./node_modules/vant/es/checkbox/Checker.js","webpack:///./node_modules/@vue/devtools-api/lib/esm/index.js","webpack:///./node_modules/core-js/internals/iterators.js","webpack:///./node_modules/vant/es/image/style/index.js","webpack:///./node_modules/vant/es/checkbox/Checkbox.js","webpack:///./node_modules/vant/es/checkbox/index.js","webpack:///./node_modules/core-js/internals/indexed-object.js","webpack:///./node_modules/vant/es/image/Image.js","webpack:///./node_modules/vant/es/image/index.js","webpack:///./node_modules/core-js/internals/add-to-unscopables.js","webpack:///./node_modules/core-js/internals/host-report-errors.js","webpack:///./node_modules/vant/es/config-provider/style/index.js","webpack:///./node_modules/vant/es/image-preview/style/index.js","webpack:///./node_modules/vant/es/image-preview/function-call.js","webpack:///./node_modules/vant/es/swipe/Swipe.js","webpack:///./node_modules/vant/es/swipe/index.js","webpack:///./node_modules/vant/es/swipe-item/SwipeItem.js","webpack:///./node_modules/vant/es/swipe-item/index.js","webpack:///./node_modules/vant/es/image-preview/ImagePreviewItem.js","webpack:///./node_modules/vant/es/image-preview/ImagePreview.js","webpack:///./node_modules/core-js/internals/species-constructor.js","webpack:///./node_modules/core-js/internals/ordinary-to-primitive.js","webpack:///./node_modules/core-js/internals/native-symbol.js","webpack:///./node_modules/vant/es/utils/dom.js","webpack:///./node_modules/vant/es/row/style/index.js","webpack:///./node_modules/core-js/internals/array-includes.js","webpack:///./node_modules/vant/es/radio/style/index.js","webpack:///./node_modules/vant/es/composables/use-expose.js","webpack:///./node_modules/core-js/internals/a-constructor.js","webpack:///./node_modules/core-js/internals/to-length.js","webpack:///./node_modules/vant/es/nav-bar/style/index.js","webpack:///./node_modules/core-js/modules/es.string.replace.js","webpack:///./node_modules/vant/es/loading/Loading.js","webpack:///./node_modules/vant/es/loading/index.js","webpack:///./node_modules/vant/es/radio-group/RadioGroup.js","webpack:///./node_modules/vant/es/field/utils.js","webpack:///./node_modules/vant/es/composables/use-id.js","webpack:///./node_modules/vant/es/field/Field.js","webpack:///./node_modules/vant/es/field/index.js","webpack:///./node_modules/core-js/internals/shared.js","webpack:///./node_modules/vant/es/row/Row.js","webpack:///./node_modules/core-js/internals/own-keys.js","webpack:///./node_modules/core-js/internals/to-string.js","webpack:///./node_modules/vant/es/pull-refresh/PullRefresh.js","webpack:///./node_modules/vant/es/pull-refresh/index.js","webpack:///./node_modules/core-js/internals/to-integer-or-infinity.js","webpack:///./node_modules/core-js/internals/a-callable.js","webpack:///./node_modules/core-js/internals/create-property-descriptor.js","webpack:///./node_modules/core-js/internals/function-name.js","webpack:///./node_modules/vant/es/picker/style/index.js","webpack:///./node_modules/core-js/internals/engine-is-node.js","webpack:///./node_modules/core-js/internals/engine-is-browser.js","webpack:///./node_modules/core-js/internals/object-assign.js","webpack:///./node_modules/core-js/internals/string-multibyte.js","webpack:///./node_modules/core-js/internals/array-species-create.js","webpack:///./node_modules/vant/es/button/style/index.js","webpack:///./node_modules/vant/es/cell/Cell.js","webpack:///./node_modules/core-js/internals/is-constructor.js","webpack:///./node_modules/core-js/internals/internal-state.js","webpack:///./node_modules/vant/es/composables/use-height.js","webpack:///./node_modules/vant/es/composables/use-placeholder.js","webpack:///./node_modules/vant/es/nav-bar/NavBar.js","webpack:///./node_modules/vant/es/nav-bar/index.js","webpack:///./node_modules/vue-router/dist/vue-router.esm-bundler.js","webpack:///./node_modules/vant/es/overlay/Overlay.js","webpack:///./node_modules/vant/es/overlay/index.js","webpack:///./node_modules/core-js/internals/redefine.js","webpack:///./node_modules/core-js/internals/object-get-own-property-symbols.js","webpack:///./node_modules/vant/es/cell/index.js","webpack:///./node_modules/core-js/internals/enum-bug-keys.js","webpack:///./node_modules/core-js/internals/dom-token-list-prototype.js","webpack:///./node_modules/core-js/internals/to-object.js","webpack:///./node_modules/core-js/internals/object-create.js","webpack:///./node_modules/core-js/internals/define-iterator.js","webpack:///./node_modules/vant/es/utils/interceptor.js","webpack:///./node_modules/core-js/internals/native-weak-map.js","webpack:///./node_modules/@vant/use/dist/esm/index.js","webpack:///./node_modules/vant/es/col/style/index.js","webpack:///./node_modules/core-js/internals/an-object.js","webpack:///./node_modules/core-js/internals/descriptors.js","webpack:///./node_modules/vant/es/utils/format.js","webpack:///./node_modules/core-js/internals/create-property.js","webpack:///./node_modules/core-js/internals/is-object.js","webpack:///./node_modules/core-js/internals/inspect-source.js","webpack:///./node_modules/vant/es/popup/style/index.js","webpack:///./node_modules/core-js/internals/advance-string-index.js","webpack:///./node_modules/vant/es/utils/validate.js","webpack:///./node_modules/vant/es/uploader/utils.js","webpack:///./node_modules/vant/es/uploader/UploaderPreviewItem.js","webpack:///./node_modules/vant/es/uploader/Uploader.js","webpack:///./node_modules/vant/es/uploader/index.js","webpack:///./node_modules/core-js/internals/uid.js","webpack:///./node_modules/core-js/internals/create-non-enumerable-property.js","webpack:///./node_modules/core-js/internals/regexp-exec.js","webpack:///./node_modules/core-js/internals/is-forced.js","webpack:///./node_modules/vant/es/checkbox-group/CheckboxGroup.js","webpack:///./node_modules/core-js/modules/es.array.concat.js","webpack:///./node_modules/core-js/internals/get-iterator.js","webpack:///./node_modules/vant/es/notify/style/index.js","webpack:///./node_modules/core-js/internals/object-define-property.js","webpack:///./node_modules/core-js/internals/create-iterator-constructor.js","webpack:///./node_modules/vant/es/radio/Radio.js","webpack:///./node_modules/vant/es/radio/index.js","webpack:///./node_modules/core-js/internals/regexp-sticky-helpers.js","webpack:///./node_modules/@vue/shared/dist/shared.esm-bundler.js","webpack:///./node_modules/vant/es/col/Col.js","webpack:///./node_modules/vant/es/col/index.js","webpack:///./node_modules/core-js/internals/to-property-key.js","webpack:///./node_modules/vant/es/radio-group/style/index.js","webpack:///./node_modules/core-js/internals/engine-is-webos-webkit.js","webpack:///./node_modules/core-js/modules/es.promise.finally.js","webpack:///./node_modules/vant/es/checkbox-group/style/index.js","webpack:///./node_modules/vant/es/pull-refresh/style/index.js","webpack:///./node_modules/@vue/devtools-api/lib/esm/env.js","webpack:///./node_modules/core-js/modules/es.regexp.exec.js","webpack:///./node_modules/vant/es/badge/Badge.js","webpack:///./node_modules/vant/es/badge/index.js","webpack:///./node_modules/vant/es/icon/Icon.js","webpack:///./node_modules/vant/es/icon/index.js","webpack:///./node_modules/core-js/internals/regexp-flags.js","webpack:///./node_modules/core-js/internals/iterators-core.js","webpack:///./node_modules/vant/es/switch/style/index.js","webpack:///./node_modules/core-js/internals/object-to-string.js","webpack:///./node_modules/vant/es/composables/use-route.js","webpack:///./node_modules/vant/es/utils/constant.js","webpack:///./node_modules/core-js/internals/microtask.js","webpack:///./node_modules/core-js/internals/well-known-symbol.js","webpack:///./node_modules/vant/es/button/Button.js","webpack:///./node_modules/vant/es/button/index.js","webpack:///./node_modules/@vue/devtools-api/lib/esm/const.js","webpack:///./node_modules/vant/es/field/style/index.js","webpack:///./node_modules/core-js/internals/to-primitive.js","webpack:///./node_modules/vant/es/cell/style/index.js","webpack:///./node_modules/vant/es/utils/with-install.js","webpack:///./node_modules/vant/es/icon/style/index.js","webpack:///./node_modules/core-js/internals/is-pure.js","webpack:///./node_modules/core-js/internals/function-call.js","webpack:///./node_modules/core-js/internals/classof-raw.js","webpack:///./node_modules/core-js/internals/shared-store.js","webpack:///(webpack)/buildin/global.js","webpack:///./node_modules/core-js/internals/object-keys-internal.js","webpack:///./node_modules/core-js/internals/document-create-element.js","webpack:///./node_modules/core-js/modules/es.object.assign.js","webpack:///./node_modules/vant/es/composables/use-touch.js","webpack:///./node_modules/core-js/internals/promise-resolve.js","webpack:///./node_modules/core-js/internals/set-global.js","webpack:///./node_modules/core-js/internals/hidden-keys.js","webpack:///./node_modules/core-js/internals/fails.js","webpack:///./node_modules/core-js/internals/get-built-in.js","webpack:///./node_modules/vant/es/composables/use-lazy-render.js","webpack:///./node_modules/vant/es/row/index.js","webpack:///./node_modules/core-js/internals/object-property-is-enumerable.js","webpack:///./node_modules/core-js/internals/object-set-prototype-of.js","webpack:///./node_modules/core-js/modules/es.object.to-string.js","webpack:///./node_modules/core-js/internals/set-to-string-tag.js","webpack:///./node_modules/core-js/internals/engine-is-ios-pebble.js","webpack:///./node_modules/core-js/internals/fix-regexp-well-known-symbol-logic.js","webpack:///./node_modules/@vue/cli-service/node_modules/vue-loader-v16/dist/exportHelper.js","webpack:///./node_modules/core-js/internals/is-symbol.js","webpack:///./node_modules/core-js/internals/global.js","webpack:///./node_modules/core-js/internals/get-method.js","webpack:///./node_modules/core-js/modules/web.dom-collections.iterator.js","webpack:///./node_modules/core-js/internals/object-keys.js","webpack:///./node_modules/core-js/internals/object-get-prototype-of.js","webpack:///./node_modules/core-js/internals/correct-prototype-getter.js","webpack:///./node_modules/core-js/modules/es.array.iterator.js","webpack:///./node_modules/vant/es/radio-group/index.js","webpack:///./node_modules/core-js/internals/redefine-all.js","webpack:///./node_modules/core-js/internals/function-uncurry-this.js","webpack:///./node_modules/vant/es/composables/use-lock-scroll.js","webpack:///./node_modules/vant/es/popup/Popup.js","webpack:///./node_modules/vant/es/popup/index.js","webpack:///./node_modules/core-js/internals/perform.js","webpack:///./node_modules/core-js/modules/es.promise.js","webpack:///./node_modules/core-js/internals/copy-constructor-properties.js","webpack:///./node_modules/core-js/internals/is-array.js","webpack:///./node_modules/vant/es/uploader/style/index.js","webpack:///./node_modules/core-js/internals/is-array-iterator-method.js","webpack:///./node_modules/core-js/modules/es.json.stringify.js","webpack:///./node_modules/core-js/internals/new-promise-capability.js","webpack:///./node_modules/vant/es/overlay/style/index.js","webpack:///./node_modules/vant/es/utils/deep-clone.js","webpack:///./node_modules/vant/es/picker/PickerColumn.js","webpack:///./node_modules/vant/es/picker/Picker.js","webpack:///./node_modules/vant/es/picker/index.js","webpack:///./node_modules/@vue/reactivity/dist/reactivity.esm-bundler.js","webpack:///./node_modules/@vue/runtime-core/dist/runtime-core.esm-bundler.js","webpack:///./node_modules/@vue/runtime-dom/dist/runtime-dom.esm-bundler.js","webpack:///./node_modules/@vue/compiler-core/dist/compiler-core.esm-bundler.js","webpack:///./node_modules/@vue/compiler-dom/dist/compiler-dom.esm-bundler.js","webpack:///./node_modules/vue/dist/vue.esm-bundler.js","webpack:///./node_modules/@vue/devtools-api/lib/esm/proxy.js","webpack:///./node_modules/vant/es/utils/basic.js","webpack:///./node_modules/core-js/internals/array-slice.js","webpack:///./node_modules/vant/es/notify/function-call.js","webpack:///./node_modules/vant/es/notify/Notify.js","webpack:///./node_modules/vant/es/notify/index.js","webpack:///./node_modules/core-js/internals/classof.js","webpack:///./node_modules/vant/es/utils/props.js","webpack:///./node_modules/core-js/internals/shared-key.js","webpack:///./node_modules/vant/es/popup/shared.js","webpack:///./node_modules/core-js/modules/es.array.slice.js","webpack:///./node_modules/core-js/internals/to-indexed-object.js","webpack:///./node_modules/core-js/internals/regexp-unsupported-dot-all.js","webpack:///./node_modules/core-js/internals/dom-iterables.js","webpack:///./node_modules/core-js/internals/use-symbol-as-uid.js","webpack:///./node_modules/vant/es/utils/deep-assign.js","webpack:///./node_modules/vant/es/locale/lang/zh-CN.js","webpack:///./node_modules/vant/es/locale/index.js","webpack:///./node_modules/vant/es/utils/create.js","webpack:///./node_modules/core-js/internals/native-promise-constructor.js"],"names":["wellKnownSymbol","TO_STRING_TAG","test","module","exports","String","uncurryThis","aCallable","bind","fn","that","undefined","apply","arguments","DESCRIPTORS","call","propertyIsEnumerableModule","createPropertyDescriptor","toIndexedObject","toPropertyKey","hasOwn","IE8_DOM_DEFINE","$getOwnPropertyDescriptor","Object","getOwnPropertyDescriptor","f","O","P","error","toLength","obj","length","ConfigProvider","global","isArray","isConstructor","isObject","SPECIES","Array","originalArray","C","constructor","prototype","toObject","floor","Math","charAt","replace","stringSlice","slice","SUBSTITUTION_SYMBOLS","SUBSTITUTION_SYMBOLS_NO_NAMED","matched","str","position","captures","namedCaptures","replacement","tailPos","m","symbols","match","ch","capture","n","fails","createElement","defineProperty","get","a","argument","$RegExp","RegExp","re","exec","groups","anObject","isCallable","classof","regexpExec","TypeError","R","S","result","isPrototypeOf","it","Prototype","bem","create","switchProps","size","loading","Boolean","disabled","modelValue","activeColor","inactiveColor","activeValue","type","default","inactiveValue","name","props","emits","_ref","emit","isChecked","onClick","newValue","renderLoading","color","checked","style","fontSize","backgroundColor","on","hasOwnProperty","key","getBuiltIn","POPUP_TOGGLE_KEY","Symbol","onPopupReopen","callback","popupToggleStatus","show","ITERATOR","SAFE_CLOSING","called","iteratorWithReturn","next","done","this","from","SKIP_CLOSING","ITERATION_SUPPORT","object","userAgent","usePopupState","state","toggle","open","transitionAppear","close","mountComponent","RootComponent","app","root","document","body","appendChild","instance","mount","unmount","removeChild","V8_VERSION","METHOD_NAME","array","foo","tryToString","isArrayIteratorMethod","lengthOfArrayLike","getIterator","getIteratorMethod","iteratorClose","Result","stopped","ResultPrototype","iterable","unboundFunction","options","iterator","iterFn","index","step","AS_ENTRIES","IS_ITERATOR","INTERRUPTED","stop","condition","callFn","value","toIntegerOrInfinity","max","min","integer","createNonEnumerableProperty","redefine","setGlobal","copyConstructorProperties","isForced","source","FORCED","target","targetProperty","sourceProperty","descriptor","TARGET","GLOBAL","STATIC","stat","noTargetGet","forced","sham","internalObjectKeys","enumBugKeys","hiddenKeys","concat","getOwnPropertyNames","definePropertyModule","CONSTRUCTOR_NAME","Constructor","configurable","getMethod","kind","innerResult","innerError","FunctionPrototype","Function","Reflect","TAB_STATUS_KEY","useTabStatus","t","listProps","offset","finished","errorText","direction","loadingText","finishedText","immediateCheck","slots","placeholder","tabStatus","scrollParent","check","scrollParentRect","height","isReachEdge","placeholderRect","top","bottom","renderFinishedText","text","clickErrorText","renderErrorText","tabActive","Content","Placeholder","location","defer","channel","port","html","arraySlice","IS_IOS","IS_NODE","set","setImmediate","clear","clearImmediate","process","Dispatch","MessageChannel","counter","queue","ONREADYSTATECHANGE","run","id","runner","listener","event","data","post","postMessage","protocol","host","args","nextTick","now","port2","port1","onmessage","addEventListener","importScripts","setTimeout","version","Deno","versions","v8","split","useVisibilityChange","onChange","window","IntersectionObserver","observer","entries","intersectionRatio","observe","unobserve","stickyProps","zIndex","container","offsetTop","offsetBottom","fixed","width","transform","rootStyle","stickyStyle","emitScroll","scrollTop","isFixed","onScroll","rootRect","containerRect","difference","clientHeight","documentElement","_containerRect","_difference","cellGroupProps","title","inset","border","inheritAttrs","attrs","renderGroup","renderTitle","Iterators","objectKeys","defineProperties","Properties","keys","CheckboxGroup","CONFIG_PROVIDER_KEY","configProviderProps","tag","themeVars","iconPrefix","mapThemeVarsToCSSVars","cssVars","forEach","toString","InternalStateModule","defineIterator","STRING_ITERATOR","setInternalState","getInternalState","getterFor","iterated","string","point","checkerProps","shape","iconSize","checkedColor","labelPosition","labelDisabled","role","parent","bindGroup","iconRef","getParentProp","iconStyle","borderColor","icon","iconClicked","contains","renderIcon","renderLabel","nodes","setupDevtoolsPlugin","pluginDescriptor","setupFn","hook","enableProxy","enableEarlyProxy","__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__","proxy","list","__VUE_DEVTOOLS_PLUGINS__","push","proxiedTarget","checkboxProps","setParentValue","overlimit","includes","updateValue","indexOf","splice","Checker","propertyIsEnumerable","imageProps","src","alt","fit","round","radius","lazyLoad","showError","errorIcon","showLoading","loadingIcon","imageRef","$Lazyload","overflow","borderRadius","onLoad","onError","className","slot","renderPlaceholder","renderImage","class","objectFit","onLazyLoaded","_ref2","el","onLazyLoadError","_ref3","$on","$off","UNSCOPABLES","ArrayPrototype","b","console","swipeProps","loop","vertical","autoplay","duration","touchable","lazyRender","initialSwipe","indicatorColor","showIndicators","stopPropagation","SWIPE_KEY","autoplayTimer","touchStartTime","rect","active","swiping","touch","children","linkChildren","count","delta","deltaY","deltaX","minOffset","base","maxCount","ceil","abs","trackSize","activeIndicator","isCorrectDirection","expect","trackStyle","transitionDuration","mainAxis","crossAxis","getTargetActive","pace","getTargetOffset","targetActive","currentPosition","targetOffset","move","emitChange","outRightBound","setOffset","outLeftBound","correctPosition","prev","reset","stopAutoplay","clearTimeout","initialize","_props$width","_props$height","offsetWidth","offsetHeight","swipe","resize","onTouchStart","start","Date","onTouchMove","shouldPrevent","offsetY","offsetX","onTouchEnd","speed","shouldSwipe","swipeTo","targetIndex","immediate","renderDot","_","renderIndicator","indicator","fill","map","visible","rendered","inited","mounted","shouldRender","maxActive","prevActive","nextActive","getDistance","touches","sqrt","pow","clientX","clientY","Number","minZoom","maxZoom","rootWidth","rootHeight","startMoveX","startMoveY","startScale","startDistance","doubleTapTimer","scale","moveX","moveY","moving","zooming","imageRatio","displayWidth","displayHeight","rootRatio","imageStyle","maxMoveX","maxMoveY","setScale","resetScale","toggleScale","distance","checkTap","deltaTime","TAP_TIME","TAP_OFFSET","naturalWidth","naturalHeight","imageSlots","popupProps","imagePreviewProps","images","overlay","closeable","showIndex","closeIcon","transition","beforeClose","overlayStyle","swipeDuration","startPosition","closeOnPopstate","closeIconPosition","swipeRef","$el","emitScale","updateShow","emitClose","setActive","renderIndex","renderCover","cover","renderImages","image","ImagePreviewItem","renderClose","onClosed","_swipeRef$value","url","defaultConfig","onScale","onClose","teleport","initInstance","Component","install","use","aConstructor","defaultConstructor","input","pref","val","valueOf","getOwnPropertySymbols","symbol","getScrollTop","pageYOffset","setScrollTop","scrollTo","scrollX","getRootScrollTop","setRootScrollTop","isIOS","resetScroll","preventDefault","isStopPropagation","cancelable","isHidden","elementRef","getComputedStyle","hidden","display","parentHidden","offsetParent","windowWidth","windowHeight","toAbsoluteIndex","createMethod","IS_INCLUDES","$this","fromIndex","useExpose","apis","fixRegExpWellKnownSymbolLogic","requireObjectCoercible","advanceStringIndex","getSubstitution","regExpExec","REPLACE","stringIndexOf","maybeToString","REPLACE_KEEPS_$0","REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE","REPLACE_SUPPORTS_NAMED_GROUPS","nativeReplace","maybeCallNative","UNSAFE_SUBSTITUTE","searchValue","replaceValue","replacer","rx","res","functionalReplace","fullUnicode","unicode","lastIndex","results","matchStr","accumulatedResult","nextSourcePosition","i","j","replacerArgs","SpinIcon","CircularIcon","loadingProps","textSize","textColor","spinnerStyle","renderText","_props$textColor","radioGroupProps","RADIO_KEY","isEmptyValue","runSyncRule","rule","required","pattern","runRuleValidator","Promise","resolve","returnVal","validator","then","getRuleMessage","message","startComposing","composing","endComposing","dispatchEvent","Event","resizeTextarea","autosize","scrollHeight","maxHeight","minHeight","mapInputType","inputmode","current","useId","vm","fieldSharedProps","leftIcon","rightIcon","autofocus","clearable","maxlength","formatter","clearIcon","inputAlign","autocomplete","errorMessage","clearTrigger","formatTrigger","readonly","fieldProps","rows","rules","labelWidth","labelClass","labelAlign","showWordLimit","errorMessageAlign","colon","focused","validateFailed","validateMessage","inputRef","customValue","form","getModelValue","_props$modelValue","getProp","showClear","hasValue","trigger","formValue","runRules","reduce","promise","resetValidation","validate","validateWithTrigger","defaultTrigger","validateTrigger","filter","limitValueLength","isNumber","format","onInput","blur","_inputRef$value","focus","_inputRef$value2","adjustTextareaSize","onFocus","onBlur","onClickInput","onClickLeftIcon","onClickRightIcon","onClear","labelStyle","onKeypress","ENTER_CODE","keyCode","submitOnEnter","getInputId","renderInput","controlClass","custom","inputAttrs","ref","label","onCompositionend","onCompositionstart","renderLeftIcon","leftIconSlot","renderRightIcon","rightIconSlot","renderWordLimit","renderMessage","showErrorMessage","renderFieldBody","button","Label","LeftIcon","center","isLink","clickable","arrowDirection","extra","IS_PURE","store","mode","copyright","ROW_KEY","rowProps","wrap","align","gutter","justify","totalSpan","child","span","spaces","group","averagePadding","item","right","left","nowrap","getOwnPropertyNamesModule","getOwnPropertySymbolsModule","DEFAULT_HEAD_HEIGHT","TEXT_STATUS","pullRefreshProps","headHeight","successText","pullingText","loosingText","pullDistance","successDuration","animationDuration","reachTop","status","getHeadStyle","isTouchable","ease","setStatus","isLoading","getStatusText","renderStatus","showSuccessTip","checkPosition","isVertical","success","number","bitmap","enumerable","writable","getDescriptor","EXISTS","PROPER","CONFIGURABLE","IndexedObject","$assign","assign","A","B","alphabet","chr","join","T","argumentsLength","charCodeAt","CONVERT_TO_STRING","pos","first","second","codeAt","arraySpeciesConstructor","cellSharedProps","valueClass","titleClass","titleStyle","cellProps","route","showLabel","renderValue","hasTitle","alone","_name","_props$clickable","classes","borderless","inspectSource","noop","empty","construct","constructorRegExp","INCORRECT_TO_STRING","isConstructorModern","isConstructorLegacy","has","NATIVE_WEAK_MAP","shared","sharedKey","OBJECT_ALREADY_INITIALIZED","WeakMap","enforce","TYPE","wmget","wmhas","wmset","metadata","facade","STATE","useHeight","element","usePlaceholder","contentRef","renderContent","navBarProps","leftText","rightText","leftArrow","safeAreaInsetTop","navBarRef","onClickLeft","onClickRight","renderLeft","renderRight","renderNavBar","hasLeft","hasRight","hasSymbol","toStringTag","PolySymbol","matchedRouteKey","viewDepthKey","routerKey","routeLocationKey","routerViewLocationKey","isBrowser","isESModule","__esModule","applyToParams","params","newParams","TRAILING_SLASH_RE","removeTrailingSlash","path","parseURL","parseQuery","currentLocation","query","searchString","hash","searchPos","hashPos","resolveRelativePath","fullPath","stringifyURL","stringifyQuery","stripBase","pathname","toLowerCase","startsWith","isSameRouteLocation","aLastIndex","bLastIndex","isSameRouteRecord","isSameRouteLocationParams","aliasOf","isSameRouteLocationParamsValue","isEquivalentArray","every","to","fromSegments","toSegments","toPosition","segment","NavigationType","NavigationDirection","normalizeBase","baseEl","querySelector","getAttribute","BEFORE_HASH_RE","createHref","getElementPosition","docRect","getBoundingClientRect","elRect","behavior","computeScrollPosition","pageXOffset","scrollToPosition","scrollToOptions","positionEl","isIdSelector","getElementById","getScrollKey","history","scrollPositions","Map","saveScrollPosition","scrollPosition","getSavedScrollPosition","scroll","delete","createBaseLocation","createCurrentLocation","search","slicePos","pathFromHash","useHistoryListeners","historyState","listeners","teardowns","pauseState","popStateHandler","fromState","pop","forward","back","unknown","pauseListeners","listen","teardown","beforeUnloadListener","replaceState","destroy","removeEventListener","buildState","replaced","computeScroll","useHistoryStateNavigation","changeLocation","hashIndex","err","currentState","createWebHistory","historyNavigation","historyListeners","go","triggerListeners","routerHistory","createWebHashHistory","isRouteLocation","isRouteName","START_LOCATION_NORMALIZED","meta","redirectedFrom","NavigationFailureSymbol","NavigationFailureType","createRouterError","Error","isNavigationFailure","BASE_PARAM_PATTERN","BASE_PATH_PARSER_OPTIONS","sensitive","strict","end","REGEX_CHARS_RE","tokensToParser","segments","extraOptions","score","segmentScores","tokenIndex","token","subSegmentScore","repeatable","optional","regexp","subPattern","parse","stringify","avoidDuplicatedSlash","endsWith","param","compareScoreArray","diff","comparePathParserScore","aScore","bScore","comp","ROOT_TOKEN","VALID_PARAM_RE","tokenizePath","crash","buffer","previousState","tokens","finalizeSegment","char","customRe","consumeBuffer","addCharToBuffer","createRouteRecordMatcher","record","parser","matcher","alias","createRouterMatcher","routes","globalOptions","matchers","matcherMap","getRecordMatcher","addRoute","originalRecord","isRootAdd","mainNormalizedRecord","normalizeRouteRecord","mergeOptions","normalizedRecords","aliases","components","originalMatcher","normalizedRecord","parentPath","connectingSlash","isAliasRecord","removeRoute","insertMatcher","matcherRef","getRoutes","paramsFromLocation","k","find","parentMatcher","unshift","mergeMetaFields","redirect","beforeEnter","normalizeRecordProps","instances","leaveGuards","Set","updateGuards","enterCallbacks","component","propsObject","defaults","partialOptions","HASH_RE","AMPERSAND_RE","SLASH_RE","EQUAL_RE","IM_RE","PLUS_RE","ENC_BRACKET_OPEN_RE","ENC_BRACKET_CLOSE_RE","ENC_CARET_RE","ENC_BACKTICK_RE","ENC_CURLY_OPEN_RE","ENC_PIPE_RE","ENC_CURLY_CLOSE_RE","ENC_SPACE_RE","commonEncode","encodeURI","encodeHash","encodeQueryValue","encodeQueryKey","encodePath","encodeParam","decode","decodeURIComponent","hasLeadingIM","searchParams","searchParam","eqPos","currentValue","values","v","normalizeQuery","normalizedQuery","useCallbacks","handlers","add","handler","guardToPromiseFn","guard","enterCallbackArray","reject","valid","guardReturn","guardCall","catch","extractComponentsGuards","guardType","guards","rawComponent","isRouteComponent","__vccOpts","componentPromise","resolved","resolvedComponent","useLink","router","currentRoute","activeRecordIndex","routeMatched","currentMatched","findIndex","parentRecordPath","getOriginalPath","isActive","includesParams","isExactActive","navigate","e","guardEvent","href","RouterLinkImpl","activeClass","exactActiveClass","ariaCurrentValue","link","elClass","getLinkClass","linkActiveClass","linkExactActiveClass","RouterLink","metaKey","altKey","ctrlKey","shiftKey","defaultPrevented","currentTarget","outer","inner","innerValue","outerValue","some","propClass","globalClass","defaultClass","RouterViewImpl","injectedRoute","routeToDisplay","depth","matchedRouteRef","viewRef","oldInstance","oldName","flush","matchedRoute","ViewComponent","currentName","normalizeSlot","routePropsOption","routeProps","onVnodeUnmounted","vnode","isUnmounted","slotContent","RouterView","createRouter","parseQuery$1","stringifyQuery$1","beforeGuards","beforeResolveGuards","afterGuards","pendingLocation","scrollBehavior","scrollRestoration","normalizeParams","paramValue","encodeParams","decodeParams","parentOrRoute","recordMatcher","routeMatcher","hasRoute","rawLocation","locationNormalized","matcherLocation","targetParams","locationAsObject","checkCanceledNavigation","pushWithRedirect","handleRedirectRecord","lastMatched","newTargetLocation","targetLocation","force","shouldRedirect","toLocation","failure","handleScroll","triggerError","finalizeNavigation","triggerAfterEach","checkCanceledNavigationAndReject","leavingRecords","updatingRecords","enteringRecords","extractChangingRecords","reverse","canceledNavigationCheck","runGuardQueue","isPush","isFirstNavigation","markAsReady","removeHistoryListener","setupListeners","_from","info","ready","readyHandlers","errorHandlers","isReady","started","installedApps","beforeEach","beforeResolve","afterEach","config","globalProperties","$router","reactiveRoute","provide","unmountApp","len","recordFrom","recordTo","overlayProps","lockScroll","customStyle","preventTouchMove","renderOverlay","CONFIGURABLE_FUNCTION_NAME","enforceInternalState","TEMPLATE","unsafe","simple","Cell","documentCreateElement","classList","DOMTokenListPrototype","activeXDocument","GT","LT","PROTOTYPE","SCRIPT","IE_PROTO","EmptyConstructor","scriptTag","content","NullProtoObjectViaActiveX","write","temp","parentWindow","NullProtoObjectViaIFrame","iframeDocument","iframe","JS","contentWindow","F","NullProtoObject","ActiveXObject","domain","$","FunctionName","createIteratorConstructor","getPrototypeOf","setPrototypeOf","setToStringTag","IteratorsCore","PROPER_FUNCTION_NAME","IteratorPrototype","BUGGY_SAFARI_ITERATORS","KEYS","VALUES","ENTRIES","returnThis","Iterable","NAME","IteratorConstructor","DEFAULT","IS_SET","CurrentIteratorPrototype","methods","KEY","getIterationMethod","KIND","defaultIterator","IterablePrototype","INCORRECT_VALUES_NAME","nativeIterator","anyNativeIterator","proto","callInterceptor","interceptor","canceled","inBrowser","raf","requestAnimationFrame","doubleRaf","isWindow","makeDOMRect","useRect","elementOrRef","innerWidth","innerHeight","useParent","unlink","internalChildren","flattenVNodes","traverse","children2","_a","subTree","sortChildren","publicChildren","vnodes","sort","orderedPublicChildren","indexA","indexB","useChildren","onMountedOrActivated","useEventListener","passive","attached","target2","remove","oldVal","useWindowSize","update","overflowScrollReg","defaultRoot","isElement","node","ELEMENT_NODE_TYPE","tagName","nodeType","getScrollParent","overflowY","parentNode","useScrollParent","visibility","usePageVisibility","CUSTOM_FIELD_INJECTION_KEY","useCustomFieldValue","field","rootFontSize","addUnit","getSizeStyle","originSize","getZIndexStyle","getRootFontSize","doc","parseFloat","convertRem","convertVw","convertVh","unitToPx","camelizeRE","camelize","c","toUpperCase","kebabCase","clamp","num","trimExtraChar","regExp","formatNumber","allowDot","allowMinus","propertyKey","functionToString","isDef","isFunction","isPromise","isNumeric","navigator","toArray","readFileContent","file","resultType","reader","FileReader","onload","readAsDataURL","readAsText","isOversize","items","maxSize","filterFiles","invalid","IMAGE_REGEXP","isImageUrl","isImageFile","isImage","imageFit","deletable","previewSize","beforeDelete","renderMask","MaskIcon","showMessage","onDelete","onPreview","renderDeleteIcon","renderPreview","uploaderProps","accept","multiple","Infinity","uploadIcon","uploadText","afterRead","showUpload","beforeRead","previewImage","previewOptions","previewFullImage","imagePreview","urls","getDetail","resetInput","onAfterRead","readFile","files","remainCount","all","contents","fileList","response","onClosePreview","imageFiles","URL","createObjectURL","closeImagePreview","deleteFile","renderPreviewItem","needPickData","previewData","UploaderPreviewItem","renderPreviewList","onClickUpload","renderUpload","Input","chooseFile","click","revokeObjectURL","postfix","random","regexpFlags","stickyHelpers","UNSUPPORTED_DOT_ALL","UNSUPPORTED_NCG","nativeExec","patchedExec","UPDATES_LAST_INDEX_WRONG","re1","re2","UNSUPPORTED_Y","BROKEN_CARET","NPCG_INCLUDED","PATCH","reCopy","raw","sticky","flags","charsAdded","strCopy","multiline","feature","detection","normalize","POLYFILL","NATIVE","checkboxGroupProps","CHECKBOX_GROUP_KEY","toggleAll","skipDisabled","checkedChildren","names","createProperty","arraySpeciesCreate","arrayMethodHasSpeciesSupport","IS_CONCAT_SPREADABLE","MAX_SAFE_INTEGER","MAXIMUM_ALLOWED_INDEX_EXCEEDED","IS_CONCAT_SPREADABLE_SUPPORT","SPECIES_SUPPORT","isConcatSpreadable","spreadable","arg","E","usingIterator","iteratorMethod","$defineProperty","Attributes","MISSED_STICKY","makeMap","expectsLowerCase","PatchFlagNames","GLOBALS_WHITE_LISTED","isGloballyWhitelisted","range","generateCodeFrame","lines","newlineSequences","idx","line","repeat","lineLength","newLineSeqLength","pad","specialBooleanAttrs","isSpecialBooleanAttr","includeBooleanAttr","normalizeStyle","normalized","isString","parseStringStyle","listDelimiterRE","propertyDelimiterRE","cssText","ret","tmp","trim","normalizeClass","normalizeProps","klass","HTML_TAGS","SVG_TAGS","VOID_TAGS","isHTMLTag","isSVGTag","isVoidTag","looseCompareArrays","equal","looseEqual","aValidType","isDate","bValidType","getTime","aKeysCount","bKeysCount","aHasKey","bHasKey","looseIndexOf","arr","toDisplayString","objectToString","JSON","_key","__v_isRef","isMap","isSet","isPlainObject","EMPTY_OBJ","EMPTY_ARR","NOOP","NO","onRE","isOn","isModelListener","extend","toTypeString","isSymbol","toRawType","isIntegerKey","parseInt","isReservedProp","cacheStringFunction","cache","hit","hyphenateRE","hyphenate","capitalize","toHandlerKey","hasChanged","oldValue","is","invokeArrayFns","fns","def","toNumber","isNaN","_globalThis","getGlobalThis","globalThis","self","colProps","paddingLeft","paddingRight","toPrimitive","NativePromise","speciesConstructor","promiseResolve","NON_GENERIC","real","onFinally","x","method","getDevtoolsGlobalHook","getTarget","__VUE_DEVTOOLS_GLOBAL_HOOK__","isProxyAvailable","Proxy","badgeProps","dot","showZero","hasContent","background","y","marginTop","marginLeft","renderBadge","iconProps","badge","classPrefix","isImageIcon","ignoreCase","dotAll","PrototypeOfArrayIteratorPrototype","arrayIterator","NEW_ITERATOR_PROTOTYPE","TO_STRING_TAG_SUPPORT","useRoute","BORDER","BORDER_TOP","BORDER_LEFT","BORDER_BOTTOM","BORDER_SURROUND","BORDER_TOP_BOTTOM","BORDER_UNSET_TOP_BOTTOM","HAPTICS_FEEDBACK","FORM_KEY","head","last","notify","macrotask","IS_IOS_PEBBLE","IS_WEBOS_WEBKIT","MutationObserver","WebKitMutationObserver","queueMicrotaskDescriptor","queueMicrotask","exit","enter","createTextNode","characterData","task","uid","NATIVE_SYMBOL","USE_SYMBOL_AS_UID","WellKnownSymbolsStore","symbolFor","createWellKnownSymbol","withoutSetter","description","buttonProps","block","plain","square","hairline","nativeType","loadingSize","loadingType","iconPosition","renderLoadingIcon","getStyle","HOOK_SETUP","HOOK_PLUGIN_SETTINGS_SET","ordinaryToPrimitive","TO_PRIMITIVE","exoticToPrim","withInstall","SHARED","g","MIN_DISTANCE","getDirection","useTouch","startX","startY","isHorizontal","newPromiseCapability","promiseCapability","aFunction","namespace","useLazyRender","render","Row","$propertyIsEnumerable","NASHORN_BUG","1","V","aPossiblePrototype","setter","CORRECT_SETTER","__proto__","TAG","Pebble","RegExpPrototype","SHAM","SYMBOL","DELEGATES_TO_SYMBOL","DELEGATES_TO_EXEC","execCalled","uncurriedNativeRegExpMethod","nativeMethod","arg2","forceStringMethod","uncurriedNativeMethod","$exec","sfc","$Symbol","func","DOMIterables","ArrayIteratorMethods","ArrayValues","handlePrototype","CollectionPrototype","COLLECTION_NAME","CORRECT_PROTOTYPE_GETTER","ObjectPrototype","addToUnscopables","ARRAY_ITERATOR","Arguments","RadioGroup","callBind","totalLockCount","BODY_LOCK_CLASS","useLockScroll","rootRef","shouldLock","lock","unlock","init","safeAreaInsetBottom","globalZIndex","opened","shouldReopen","popupRef","onClickOverlay","closeOnClickOverlay","overlayClass","onClickCloseIcon","renderCloseIcon","onOpened","renderPopup","renderTransition","Internal","OwnPromiseCapability","PromiseWrapper","nativeThen","redefineAll","setSpecies","anInstance","iterate","checkCorrectnessOfIteration","microtask","hostReportErrors","newPromiseCapabilityModule","perform","IS_BROWSER","PROMISE","getInternalPromiseState","NativePromisePrototype","PromiseConstructor","PromisePrototype","newGenericPromiseCapability","DISPATCH_EVENT","createEvent","NATIVE_REJECTION_EVENT","PromiseRejectionEvent","UNHANDLED_REJECTION","REJECTION_HANDLED","PENDING","FULFILLED","REJECTED","HANDLED","UNHANDLED","SUBCLASSING","PROMISE_CONSTRUCTOR_SOURCE","GLOBAL_CORE_JS_PROMISE","FakePromise","INCORRECT_ITERATION","isThenable","isReject","notified","chain","reactions","ok","exited","reaction","fail","rejection","onHandleUnhandled","onUnhandled","reason","initEvent","IS_UNHANDLED","isUnhandled","unwrap","internalReject","internalResolve","wrapper","executor","onFulfilled","onRejected","r","capability","$promiseResolve","remaining","alreadyCalled","race","ownKeys","getOwnPropertyDescriptorModule","$stringify","numberToString","tester","low","hi","fix","space","l","PromiseCapability","$$resolve","$$reject","deepClone","DEFAULT_DURATION","MOMENTUM_LIMIT_TIME","MOMENTUM_LIMIT_DISTANCE","getElementTranslateY","translateY","PICKER_KEY","isOptionDisabled","option","textKey","allowHtml","itemHeight","defaultIndex","initialOptions","visibleItemCount","startOffset","momentumOffset","transitionEndTrigger","baseOffset","adjustIndex","_i","setIndex","setOptions","onClickItem","getOptionText","getIndexByOffset","momentum","stopMomentum","allowMomentum","renderOptions","optionStyle","tabindex","selected","childData","setValue","getValue","transitionProperty","pickerSharedProps","showToolbar","cancelButtonText","confirmButtonText","pickerProps","columns","valueKey","toolbarPosition","columnsFieldNames","formattedColumns","valuesKey","childrenKey","dataType","firstColumn","formatCascade","formatted","cursor","_cursor$defaultIndex","_children","getIndexes","setColumnValues","column","onCascadeChange","columnIndex","indexes","getChild","getColumnValue","setColumnValue","getColumnIndex","setColumnIndex","optionIndex","getColumnValues","getValues","setValues","setIndexes","emitAction","confirm","cancel","renderCancel","renderConfirm","renderToolbar","toolbar","renderColumnItems","_item$defaultIndex","renderColumns","wrapHeight","frameStyle","columnsStyle","maskStyle","backgroundSize","_slots$columnsTop","_slots$columnsBottom","activeEffectScope","effectScopeStack","EffectScope","detached","effects","cleanups","scopes","off","fromParent","cleanup","effectScope","recordEffectScope","effect","scope","getCurrentScope","onScopeDispose","createDep","dep","w","wasTracked","trackOpBit","newTracked","initDepMarkers","deps","finalizeDepMarkers","ptr","targetMap","effectTrackDepth","maxMarkerBits","effectStack","activeEffect","ITERATE_KEY","MAP_KEY_ITERATE_KEY","ReactiveEffect","scheduler","enableTracking","cleanupEffect","resetTracking","onStop","_effect","lazy","shouldTrack","trackStack","pauseTracking","track","isTracking","depsMap","eventInfo","trackEffects","debuggerEventExtraInfo","oldTarget","triggerEffects","allowRecurse","isNonTrackableKeys","builtInSymbols","createGetter","shallowGet","readonlyGet","shallowReadonlyGet","arrayInstrumentations","createArrayInstrumentations","instrumentations","toRaw","isReadonly","shallow","receiver","shallowReadonlyMap","readonlyMap","shallowReactiveMap","reactiveMap","targetIsArray","isRef","shouldUnwrap","reactive","createSetter","shallowSet","hadKey","deleteProperty","mutableHandlers","readonlyHandlers","shallowReactiveHandlers","shallowReadonlyHandlers","toShallow","getProto","get$1","isShallow","rawTarget","rawKey","toReadonly","toReactive","has$1","set$1","deleteEntry","hadItems","createForEach","thisArg","observed","createIterableMethod","targetIsMap","isPair","isKeyOnly","innerIterator","createReadonlyMethod","createInstrumentations","mutableInstrumentations","shallowInstrumentations","readonlyInstrumentations","shallowReadonlyInstrumentations","iteratorMethods","createInstrumentationGetter","mutableCollectionHandlers","shallowCollectionHandlers","readonlyCollectionHandlers","shallowReadonlyCollectionHandlers","targetTypeMap","rawType","getTargetType","isExtensible","createReactiveObject","shallowReactive","shallowReadonly","baseHandlers","collectionHandlers","proxyMap","existingProxy","targetType","isReactive","isProxy","markRaw","trackRefValue","triggerRefValue","newVal","createRef","shallowRef","rawValue","_shallow","_rawValue","_value","triggerRef","unref","shallowUnwrapHandlers","proxyRefs","objectWithRefs","CustomRefImpl","factory","_get","_set","customRef","toRefs","toRef","ObjectRefImpl","_object","ComputedRefImpl","getter","_setter","_dirty","getterOrOptions","debugOptions","onlyGetter","cRef","devtools","devtoolsNotInstalled","setDevtoolsHook","_b","enabled","HTMLElement","replay","__VUE_DEVTOOLS_HOOK_REPLAY__","newHook","emit$1","rawArgs","modelArg","modifiersKey","handlerName","callWithAsyncErrorHandling","onceHandler","emitted","normalizeEmitsOptions","appContext","asMixin","emitsCache","cached","hasExtends","extendEmits","normalizedFromExtend","mixins","extends","isEmitListener","currentRenderingInstance","currentScopeId","setCurrentRenderingInstance","__scopeId","pushScopeId","popScopeId","withScopeId","_id","withCtx","ctx","isNonScopedSlot","_n","renderFnWithContext","_d","setBlockTracking","prevInstance","_c","renderComponentRoot","withProxy","propsOptions","renderCache","setupState","fallthroughAttrs","shapeFlag","proxyToUse","normalizeVNode","getFunctionalFallthrough","blockStack","handleError","createVNode","Comment","filterModelListeners","cloneVNode","dirs","filterSingleRoot","singleRoot","isVNode","shouldUpdateComponent","prevVNode","nextVNode","optimized","prevProps","prevChildren","nextProps","nextChildren","patchFlag","emitsOptions","$stable","hasPropsChanged","dynamicProps","nextKeys","updateHOCHostEl","isSuspense","__isSuspense","SuspenseImpl","n1","n2","anchor","parentComponent","parentSuspense","isSVG","slotScopeIds","rendererInternals","mountSuspense","patchSuspense","hydrate","hydrateSuspense","createSuspenseBoundary","normalizeSuspenseChildren","Suspense","triggerEvent","eventListener","p","patch","o","hiddenContainer","suspense","pendingBranch","ssContent","ssFallback","setActiveBranch","um","newBranch","newFallback","activeBranch","isInFallback","isHydrating","isSameVNodeType","pendingId","timeout","fallback","resume","delayEnter","afterLeave","hasUnresolvedAncestor","queuePostFlushCb","fallbackVNode","mountFallback","setupRenderEffect","isInPendingSuspense","hydratedEl","asyncDep","asyncSetupResult","suspenseId","asyncResolved","handleSetupResult","doRemove","hydrateNode","isSlotChildren","normalizeSuspenseSlot","s","trackBlock","isBlockTreeEnabled","openBlock","currentBlock","closeBlock","singleChild","dynamicChildren","queueEffectWithSuspense","branch","currentInstance","provides","parentProvides","inject","defaultValue","treatDefaultAsFactory","useTransitionState","isMounted","isLeaving","isUnmounting","leavingVNodes","onMounted","onBeforeUnmount","TransitionHookValidator","BaseTransitionImpl","appear","persisted","onBeforeEnter","onEnter","onAfterEnter","onEnterCancelled","onBeforeLeave","onLeave","onAfterLeave","onLeaveCancelled","onBeforeAppear","onAppear","onAfterAppear","onAppearCancelled","getCurrentInstance","prevTransitionKey","getTransitionRawChildren","rawProps","emptyPlaceholder","innerChild","getKeepAliveChild","enterHooks","resolveTransitionHooks","setTransitionHooks","oldChild","oldInnerChild","transitionKeyChanged","getTransitionKey","leavingHooks","delayLeave","earlyRemove","delayedLeave","leavingVNodesCache","getLeavingNodesForType","_leaveCb","BaseTransition","callHook","hooks","leavingVNode","afterHook","cancelHook","_enterCb","cancelled","isKeepAlive","clone","keepComment","keyedFragmentCount","Fragment","defineComponent","setup","isAsyncWrapper","__asyncLoader","defineAsyncComponent","loader","loadingComponent","errorComponent","delay","suspensible","userOnError","resolvedComp","pendingRequest","retries","retry","load","thisRequest","userRetry","userFail","createInnerComp","loaded","delayed","queueJob","__isKeepAlive","KeepAliveImpl","include","exclude","sharedContext","renderer","_unmount","storageContainer","resetShapeFlag","pruneCache","getComponentName","pruneCacheEntry","activate","queuePostRenderEffect","isDeactivated","vnodeHook","onVnodeMounted","invokeVNodeHook","deactivate","da","watch","deep","pendingCacheKey","cacheSubtree","getInnerChild","onUpdated","rawVNode","__asyncResolved","cachedVNode","KeepAlive","onActivated","registerKeepAliveHook","onDeactivated","wrappedHook","__wdc","injectHook","injectToKeepAliveRoot","keepAliveRoot","injected","onUnmounted","prepend","__weh","setCurrentInstance","unsetCurrentInstance","createHook","lifecycle","isInSSRComponentSetup","onBeforeMount","onBeforeUpdate","onServerPrefetch","onRenderTriggered","onRenderTracked","onErrorCaptured","shouldCacheAccess","applyOptions","resolveMergedOptions","publicThis","beforeCreate","dataOptions","computed","computedOptions","watchOptions","provideOptions","injectOptions","created","beforeMount","beforeUpdate","updated","activated","deactivated","beforeDestroy","beforeUnmount","destroyed","unmounted","renderTracked","renderTriggered","errorCaptured","serverPrefetch","expose","directives","filters","checkDuplicateProperties","resolveInjections","unwrapInjectedRef","methodHandler","opt","createWatcher","registerLifecycleHook","register","_hook","exposed","unwrapRef","normalizeInject","h","createPathGetter","extendsOptions","globalMixins","optionsCache","optionMergeStrategies","strats","strat","internalOptionMergeStrats","mergeDataFn","mergeObjectOptions","mergeAsArray","mergeWatchOptions","mergeInject","merged","initProps","isStateful","isSSR","InternalObjectKey","propsDefaults","setFullProps","updateProps","rawPrevProps","rawCurrentProps","hasAttrsChanged","kebabKey","resolvePropValue","propsToUpdate","camelizedKey","needCastKeys","rawCastValues","camelKey","castValues","isAbsent","hasDefault","normalizePropsOptions","propsCache","extendProps","normalizedKey","validatePropName","prop","booleanIndex","getTypeIndex","stringIndex","getType","ctor","isSameType","expectedTypes","isInternalKey","normalizeSlotValue","rawSlot","normalizeObjectSlots","rawSlots","_ctx","normalizeVNodeSlots","initSlots","updateSlots","needDeletionCheck","deletionComparisonTarget","withDirectives","internalInstance","bindings","dir","modifiers","invokeDirectiveHook","oldBindings","binding","createAppContext","isNativeTag","performance","errorHandler","warnHandler","compilerOptions","createAppAPI","rootComponent","rootProps","context","installedPlugins","_uid","_component","_props","_container","_context","_instance","plugin","mixin","directive","rootContainer","isHydrate","__vue_app__","getExposeProxy","hasMismatch","isSVGContainer","namespaceURI","isComment","createHydrationFunctions","mt","patchProp","nextSibling","insert","createComment","hasChildNodes","flushPostFlushCbs","firstChild","isFragmentStart","onMismatch","handleMismatch","domType","nextNode","Text","Static","needToAdoptContent","staticCount","outerHTML","hydrateFragment","hydrateElement","locateClosingAsyncAnchor","previousSibling","lastChild","createTextVNode","hydrateChildren","setRef","forcePatchValue","vnodeHooks","onVnodeBeforeMount","innerHTML","textContent","cur","parentVNode","fragmentSlotScopeIds","isFragment","initFeatureFlags","createRenderer","baseCreateRenderer","createHydrationRenderer","createHydrationFns","__VUE__","hostInsert","hostRemove","hostPatchProp","hostCreateElement","createText","hostCreateText","hostCreateComment","setText","hostSetText","setElementText","hostSetElementText","hostParentNode","hostNextSibling","setScopeId","hostSetScopeId","cloneNode","hostCloneNode","insertStaticContent","hostInsertStaticContent","getNextHostNode","processText","processCommentNode","mountStaticNode","processFragment","processElement","processComponent","internals","moveStaticNode","removeStaticNode","mountElement","patchElement","mountChildren","unmountChildren","scopeId","needCallTransitionHooks","cloneIfMounted","oldProps","newProps","onVnodeBeforeUpdate","areChildrenSVG","patchBlockChildren","patchChildren","patchProps","onVnodeUpdated","oldChildren","newChildren","fallbackContainer","oldVNode","newVNode","fragmentStartAnchor","fragmentEndAnchor","traverseStaticChildren","updateComponent","initialVNode","createComponentInstance","setupComponent","registerDep","updateComponentPreRender","invalidateJob","componentUpdateFn","bu","u","originNext","nextTree","prevTree","bm","isAsyncWrapperVNode","hydrateSubTree","scopedInitialVNode","flushPreFlushCbs","c1","prevShapeFlag","c2","patchKeyedChildren","patchUnkeyedChildren","oldLength","newLength","commonLength","nextChild","parentAnchor","l2","e1","e2","nextPos","s1","s2","keyToNewIndexMap","patched","toBePatched","moved","maxNewIndexSoFar","newIndexToOldIndexMap","prevChild","newIndex","increasingNewIndexSequence","getSequence","nextIndex","moveType","needTransition","leave","performLeave","shouldInvokeDirs","shouldInvokeVnodeHook","onVnodeBeforeUnmount","unmountComponent","removeFragment","performRemove","bum","_vnode","mc","pc","pbc","createApp","rawRef","oldRawRef","isUnmount","refValue","owner","oldRef","refs","doSet","callWithErrorHandling","ch1","ch2","arrI","isTeleport","__isTeleport","isTeleportDisabled","isTargetSVG","SVGElement","resolveTarget","select","targetSelector","TeleportImpl","mainAnchor","targetAnchor","wasDisabled","currentContainer","currentAnchor","moveTeleport","nextTarget","hydrateTeleport","isReorder","targetNode","_lpa","Teleport","COMPONENTS","DIRECTIVES","resolveComponent","maybeSelfReference","resolveAsset","NULL_DYNAMIC_COMPONENT","resolveDynamicComponent","resolveDirective","warnMissing","selfName","registry","disableTracking","vnodeArgsTransformer","setupBlock","createElementBlock","createBaseVNode","createBlock","__v_isVNode","transformVNodeArgs","transformer","normalizeKey","normalizeRef","isBlockNode","needFullChildrenNormalization","__v_skip","normalizeChildren","_createVNode","cloned","isClassComponent","guardReactiveProps","extraProps","mergeRef","mergedProps","mergeProps","flag","createStaticVNode","numberOfNodes","createCommentVNode","asBlock","memo","slotFlag","toMerge","existing","incoming","renderList","renderItem","createSlots","dynamicSlots","renderSlot","noSlotted","isCE","validSlotContent","ensureValidVNode","toHandlers","getPublicInstance","isStatefulComponent","publicPropertiesMap","$data","$props","$attrs","$slots","$refs","$parent","$root","$emit","$options","$forceUpdate","$nextTick","$watch","instanceWatch","PublicInstanceProxyHandlers","accessCache","normalizedProps","publicGetter","cssModule","__cssModules","RuntimeCompiledPublicInstanceProxyHandlers","unscopables","emptyAppContext","uid$1","exposeProxy","setupContext","bc","rtg","rtc","ec","sp","ce","compile","installWithProxy","setupResult","setupStatefulComponent","createSetupContext","resolvedResult","finishComponentSetup","__ssrInlineRender","ssrRender","registerRuntimeCompiler","_compile","_rc","isRuntimeOnly","skipOptions","template","isCustomElement","delimiters","componentCompilerOptions","finalCompilerOptions","createAttrsProxy","classifyRE","classify","displayName","formatComponentName","isRoot","__file","inferFromRegistry","stack","msg","appWarnHandler","trace","getComponentTrace","warnArgs","formatTrace","warn","currentVNode","normalizedStack","recurseCount","parentInstance","logs","entry","formatTraceEntry","formatProps","formatProp","throwInDev","contextVNode","exposedInstance","errorInfo","errorCapturedHooks","appErrorHandler","logError","isFlushing","isFlushPending","flushIndex","pendingPreFlushCbs","activePreFlushCbs","preFlushIndex","pendingPostFlushCbs","activePostFlushCbs","postFlushIndex","resolvedPromise","currentFlushPromise","currentPreFlushParentJob","findInsertionIndex","middle","middleJobId","getId","job","queueFlush","flushJobs","queueCb","cb","activeQueue","pendingQueue","queuePreFlushCb","seen","parentJob","deduped","watchEffect","doWatch","watchPostEffect","watchSyncEffect","INITIAL_WATCHER_VALUE","onTrack","onTrigger","forceTrigger","isMultiSource","onInvalidate","baseGetter","defineProps","defineEmits","defineExpose","withDefaults","useSlots","getContext","useAttrs","mergeDefaults","createPropsRestProxy","excludedKeys","withAsyncContext","getAwaitable","awaitable","propsOrChildren","ssrContextKey","useSSRContext","initCustomFormatter","withMemo","isMemoSame","_ssrUtils","ssrUtils","resolveFilter","compatUtils","svgNS","staticTemplateCache","nodeOps","insertBefore","createElementNS","setAttribute","nodeValue","selector","before","patchClass","transitionClasses","_vtc","removeAttribute","patchStyle","isCssString","setStyle","currentDisplay","importantRE","setProperty","prefixed","autoPrefix","prefixes","prefixCache","rawName","xlinkNS","patchAttr","removeAttributeNS","setAttributeNS","isBoolean","patchDOMProp","_getNow","skipTimestampCheck","timeStamp","ffMatch","cachedNow","getNow","patchEvent","prevValue","nextValue","invokers","_vei","existingInvoker","parseName","invoker","createInvoker","optionsModifierRE","initialValue","patchStopImmediatePropagation","originalStop","stopImmediatePropagation","_stopped","nativeOnRE","shouldSetAsProp","_trueValue","_falseValue","defineCustomElement","hydate","Comp","VueCustomElement","initialProps","super","defineSSRCustomElement","BaseClass","_def","_connected","_resolved","_numberProps","shadowRoot","attachShadow","_resolveDef","attributes","_setAttr","mutations","attributeName","styles","hasOptions","rawKeys","numberProps","_setProp","_getProp","_applyStyles","_update","asyncDef","shouldReflect","shouldUpdate","CustomEvent","detail","css","useCssModule","modules","mod","useCssVars","setVars","setVarsOnVNode","ob","childList","disconnect","vars","setVarsOnNode","TRANSITION","ANIMATION","Transition","resolveTransitionProps","DOMTransitionPropsValidators","enterFromClass","enterActiveClass","enterToClass","appearFromClass","appearActiveClass","appearToClass","leaveFromClass","leaveActiveClass","leaveToClass","TransitionPropsValidators","hasExplicitCallback","baseProps","durations","normalizeDuration","enterDuration","leaveDuration","finishEnter","isAppear","removeTransitionClass","finishLeave","makeEnterHook","nextFrame","addTransitionClass","whenTransitionEnds","forceReflow","NumberOf","cls","endId","expectedType","explicitTimeout","_endId","resolveIfNotStale","propCount","getTransitionInfo","endEvent","ended","onEnd","getStyleProperties","transitionDelays","transitionDurations","transitionTimeout","getTimeout","animationDelays","animationDurations","animationTimeout","hasTransform","delays","d","toMs","positionMap","newPositionMap","TransitionGroupImpl","moveClass","hasCSSTransform","callPendingCbs","recordPosition","movedChildren","applyTranslation","webkitTransform","_moveCb","propertyName","cssTransitionProps","TransitionGroup","oldPos","newPos","dx","dy","getModelAssigner","onCompositionStart","onCompositionEnd","vModelText","_assign","castToNumber","domValue","activeElement","vModelCheckbox","_modelValue","elementValue","found","filtered","getCheckboxValue","setChecked","vModelRadio","vModelSelect","isSetModel","selectedVal","setSelected","_binding","isMultiple","optionValue","selectedIndex","vModelDynamic","callModelHook","modelToUse","initVModelForSSR","getSSRProps","systemModifiers","modifierGuards","prevent","ctrl","shift","exact","withModifiers","keyNames","esc","up","down","withKeys","eventKey","vShow","_vod","setDisplay","initVShowForSSR","rendererOptions","enabledHydration","ensureRenderer","ensureHydrationRenderer","containerOrSelector","normalizeContainer","Element","createSSRApp","ssrDirectiveInitialized","initDirectivesForSSR","defaultOnError","defaultOnWarn","createCompilerError","code","loc","messages","additionalMessage","SyntaxError","FRAGMENT","TELEPORT","SUSPENSE","KEEP_ALIVE","BASE_TRANSITION","OPEN_BLOCK","CREATE_BLOCK","CREATE_ELEMENT_BLOCK","CREATE_VNODE","CREATE_ELEMENT_VNODE","CREATE_COMMENT","CREATE_TEXT","CREATE_STATIC","RESOLVE_COMPONENT","RESOLVE_DYNAMIC_COMPONENT","RESOLVE_DIRECTIVE","RESOLVE_FILTER","WITH_DIRECTIVES","RENDER_LIST","RENDER_SLOT","CREATE_SLOTS","TO_DISPLAY_STRING","MERGE_PROPS","NORMALIZE_CLASS","NORMALIZE_STYLE","NORMALIZE_PROPS","GUARD_REACTIVE_PROPS","TO_HANDLERS","CAMELIZE","CAPITALIZE","TO_HANDLER_KEY","SET_BLOCK_TRACKING","PUSH_SCOPE_ID","POP_SCOPE_ID","WITH_CTX","UNREF","IS_REF","WITH_MEMO","IS_MEMO_SAME","helperNameMap","registerRuntimeHelpers","helpers","locStub","createRoot","hoists","imports","temps","codegenNode","createVNodeCall","isBlock","isComponent","helper","getVNodeBlockHelper","inSSR","getVNodeHelper","createArrayExpression","elements","createObjectExpression","properties","createObjectProperty","createSimpleExpression","isStatic","constType","createCompoundExpression","createCallExpression","callee","createFunctionExpression","returns","newline","isSlot","createConditionalExpression","consequent","alternate","createCacheExpression","createBlockStatement","isStaticExp","isBuiltInType","expected","isCoreComponent","nonIdentifierRE","isSimpleIdentifier","validFirstIdentCharRE","validIdentCharRE","whitespaceRE","isMemberExpressionBrowser","stateStack","currentOpenBracketCount","currentOpenParensCount","currentStringType","isMemberExpression","getInnerRange","newLoc","advancePositionWithClone","numberOfCharacters","advancePositionWithMutation","linesCount","lastNewLinePos","findDir","allowEmpty","exp","findProp","dynamicOnly","isBindKey","hasDynamicKeyVBind","isText","isVSlot","isTemplateNode","tagType","isSlotOutlet","ssr","propsHelperSet","getUnnormalizedProps","callPath","injectProp","propsWithInjection","originalProps","parentCall","alreadyExists","propKeyName","toValidAssetId","getMemoedVNodeCall","makeBlock","removeHelper","getCompatValue","compatConfig","isCompatEnabled","checkCompatEnabled","decodeRE","decodeMap","gt","lt","amp","apos","quot","defaultParserOptions","getNamespace","getTextMode","isPreTag","decodeEntities","rawText","p1","onWarn","comments","baseParse","createParserContext","getCursor","parseChildren","getSelection","rawOptions","originalSource","inPre","inVPre","ancestors","ns","isEnd","parseInterpolation","emitError","parseComment","parseBogusComment","parseCDATA","advanceBy","parseTag","parseElement","isSpecialTemplateDirective","parseText","pushNode","removedWhitespace","shouldCondense","whitespace","prevIndex","nestedIndex","contentStart","closeIndex","wasInPre","wasInVPre","isPreBoundary","isVPreBoundary","isSelfClosing","inlineTemplateProp","startsWithEndTagOpen","advanceSpaces","currentSource","parseAttributes","isBuiltInComponent","attributeNames","attr","parseAttribute","nameSet","parseAttributeValue","isPropShorthand","dirName","lastIndexOf","getNewPosition","isQuoted","valueLoc","quote","endIndex","parseTextData","unexpectedChars","innerStart","innerEnd","rawContentLength","rawContent","preTrimContent","endOffset","endTokens","xs","walk","isSingleElementRoot","doNotHoistNode","canStringify","originalCount","hoistedCount","constantType","getConstantType","hoist","getPatchFlag","getGeneratedPropsConstantType","getNodeProps","contentType","vSlot","branches","transformHoist","constantCache","returnType","generatedPropsType","childType","expType","allowHoistedHelperSet","getConstantTypeOfHelperCall","keyType","valueType","createTransformContext","filename","prefixIdentifiers","hoistStatic","cacheHandlers","nodeTransforms","directiveTransforms","expressionPlugins","slotted","ssrCssVars","bindingMetadata","inline","isTS","nameMatch","identifiers","vFor","vPre","vOnce","currentNode","childIndex","inVOnce","currentCount","removalIndex","onNodeRemoved","identifier","hoisted","traverseNode","createRootCodegen","traverseChildren","nodeRemoved","exitFns","onExit","createStructuralDirectiveTransform","matches","PURE_ANNOTATION","createCodegenContext","ast","sourceMap","optimizeImports","runtimeGlobalName","runtimeModuleName","ssrRuntimeModuleName","indentLevel","pure","withoutNewLine","generate","onContextCreated","indent","deindent","hasHelpers","useWithBlock","preambleContext","genFunctionPreamble","functionName","signature","genAssets","genNode","preamble","toJSON","VueBinding","aliasHelper","staticHelpers","genHoists","assets","resolver","genNodeListAsArray","multilines","genNodeList","comma","genText","genExpression","genInterpolation","genCompoundExpression","genComment","genVNodeCall","genCallExpression","genObjectExpression","genArrayExpression","genFunctionExpression","genConditionalExpression","genCacheExpression","genExpressionAsPropertyKey","callHelper","genNullableArgs","needNewline","needsParens","isNested","transformIf","processIf","ifNode","siblings","sibling","createCodegenNodeForBranch","parentCondition","getParentCondition","processCodegen","createIfBranch","replaceNode","removeNode","userKey","keyIndex","createChildrenCodegenNode","keyProperty","needFragmentWrapper","vnodeCall","transformFor","processFor","forNode","renderExp","keyProp","keyExp","isStableFragment","fragmentFlag","childBlock","isTemplate","slotOutlet","createForLoopParams","parseResult","helperString","parseForExpression","addIdentifiers","removeIdentifiers","valueAlias","keyAlias","objectIndexAlias","forAliasRE","forIteratorRE","stripParensRE","inMatch","LHS","RHS","createAliasExpression","valueContent","trimmedOffset","iteratorMatch","keyContent","keyOffset","indexContent","memoArgs","createParamsList","defaultFallback","trackSlotScopes","buildClientSlotFn","buildSlots","buildSlotFn","slotsProperties","hasDynamicSlots","onComponentSlot","hasTemplateSlots","hasNamedDefaultSlot","implicitDefaultChildren","seenSlotNames","slotElement","slotDir","slotChildren","slotLoc","slotName","slotProps","dirLoc","staticSlotName","slotFunction","vIf","vElse","buildDynamicSlot","conditional","buildDefaultSlotProperty","isNonWhitespaceContent","hasForwardedSlots","directiveImportMap","transformElement","vnodeTag","resolveComponentType","isDynamicComponent","vnodeProps","vnodeChildren","vnodePatchFlag","vnodeDynamicProps","dynamicPropNames","vnodeDirectives","shouldUseBlock","propsBuildResult","buildProps","buildDirectiveArgs","shouldBuildAsSlots","hasDynamicTextChild","stringifyDynamicPropNames","isExplicitDynamic","isComponentTag","isProp","isDir","builtIn","elementLoc","mergeArgs","runtimeDirectives","hasRef","hasClassBinding","hasStyleBinding","hasHydrationEventBinding","hasDynamicKeys","hasVnodeHook","analyzePatchFlag","isEventHandler","valueNode","isVBind","isVOn","dedupeProperties","directiveTransform","needRuntime","propsExpression","classKeyIndex","styleKeyIndex","hasDynamicKey","isHandlerKey","classProp","styleProp","knownProps","dirArgs","runtime","trueExpression","modifier","propsNamesString","transformSlotOutlet","processSlotOutlet","slotArgs","expectedLen","nonNameProps","fnExpRE","transformOn","augmentor","eventName","shouldCache","isMemberExp","isInlineStatement","hasMultipleStatements","transformBind","_node","injectPrefix","prefix","transformText","hasText","callArgs","WeakSet","transformOnce","transformModel","createTransformProps","rawExp","expString","maybeRef","propName","assignmentExp","eventArg","validDivisionCharRE","transformFilter","rewriteFilter","parseFilter","expression","inSingle","inDouble","inTemplateString","inRegex","curly","paren","lastFilterIndex","pushFilter","wrapFilter","seen$1","transformMemo","getBaseTransformPreset","model","baseCompile","isModuleMode","noopDirectiveTransform","V_MODEL_RADIO","V_MODEL_CHECKBOX","V_MODEL_TEXT","V_MODEL_SELECT","V_MODEL_DYNAMIC","V_ON_WITH_MODIFIERS","V_ON_WITH_KEYS","V_SHOW","TRANSITION_GROUP","decoder","decodeHtmlBrowser","asAttr","isRawTextContainer","parserOptions","transformStyle","parseInlineCSS","createDOMCompilerError","transformVHtml","transformVText","baseResult","directiveToUse","isInvalidType","isEventOptionModifier","isNonKeyModifier","maybeKeyModifier","isKeyboardEvent","resolveModifiers","keyModifiers","nonKeyModifiers","eventOptionModifiers","transformClick","isStaticClick","handlerExp","modifierPostfix","transformShow","ignoreSideEffectTags","DOMNodeTransforms","DOMDirectiveTransforms","cloak","compileCache","compileToFunction","ApiProxy","targetQueue","onQueue","defaultSettings","settings","localSettingsSaveId","currentSettings","localStorage","getItem","fallbacks","setItem","pluginId","setSettings","proxiedOn","_target","_result$key","pick","ignoreUndefined","timer","notifyProps","parseOptions","currentOptions","getDefaultOptions","setDefaultOptions","resetDefaultOptions","$notify","classofRaw","CORRECT_ARGUMENTS","tryGet","unknownProp","numericProp","truthProp","makeRequiredProp","makeArrayProp","makeNumberProp","defaultVal","makeNumericProp","makeStringProp","popupSharedProps","popupSharedPropKeys","un$Slice","HAS_SPECIES_SUPPORT","fin","CSSRuleList","CSSStyleDeclaration","CSSValueList","ClientRectList","DOMRectList","DOMStringList","DOMTokenList","DataTransferItemList","FileList","HTMLAllCollection","HTMLCollection","HTMLFormElement","HTMLSelectElement","MediaList","MimeTypeArray","NamedNodeMap","NodeList","PaintRequestList","Plugin","PluginArray","SVGLengthList","SVGNumberList","SVGPathSegList","SVGPointList","SVGStringList","SVGTransformList","SourceBufferList","StyleSheetList","TextTrackCueList","TextTrackList","TouchList","assignKey","deepAssign","tel","save","noCoupon","nameEmpty","telInvalid","vanCalendar","startEnd","weekdays","monthTitle","year","month","rangePrompt","maxRange","vanCascader","vanContactCard","addText","vanContactList","vanPagination","vanPullRefresh","pulling","loosing","vanSubmitBar","vanCoupon","unlimited","discount","vanCouponCell","vanCouponList","exchange","enable","vanAddressEdit","area","postal","areaEmpty","addressEmpty","postalEmpty","defaultAddress","vanAddressEditDetail","vanAddressList","lang","Locale","newLang","newMessages","createTranslate","locale","_len","genBem","mods","createBEM","createNamespace","prefixedName"],"mappings":"oGAAA,IAAIA,EAAkB,EAAQ,QAE1BC,EAAgBD,EAAgB,eAChCE,EAAO,GAEXA,EAAKD,GAAiB,IAEtBE,EAAOC,QAA2B,eAAjBC,OAAOH,I,uBCPxB,IAAII,EAAc,EAAQ,QACtBC,EAAY,EAAQ,QAEpBC,EAAOF,EAAYA,EAAYE,MAGnCL,EAAOC,QAAU,SAAUK,EAAIC,GAE7B,OADAH,EA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MAAMJ,QAAQqvH,GACTA,EAAK5jG,OAAO,CAACm2B,EAAK9xB,IAAS8xB,EAAMwtE,EAAOjrH,EAAM2rB,GAAO,IAGvDzwB,OAAOqT,KAAK28G,GAAM5jG,OAAO,CAACm2B,EAAKz8C,IAAQy8C,GAAOytE,EAAKlqH,GAAOiqH,EAAOjrH,EAAMgB,GAAO,IAAK,IAXjF,GAuBJ,SAASmqH,EAAUnrH,GACxB,MAAO,CAAC4T,EAAIs3G,KACNt3G,GAAoB,kBAAPA,IACfs3G,EAAOt3G,EACPA,EAAK,IAGPA,EAAKA,EAAK5T,EAAO,KAAO4T,EAAK5T,EACtB,GAAK4T,EAAKq3G,EAAOr3G,EAAIs3G,IAGzB,SAASE,EAAgBprH,GAC9B,IAAIqrH,EAAe,OAASrrH,EAC5B,MAAO,CAACqrH,EAAcF,EAAUE,GAAeP,EAAgBO,M,qBCxDjE,IAAIzvH,EAAS,EAAQ,QAErB9B,EAAOC,QAAU6B,EAAO+nB","file":"js/chunk-vendors.5cecbfc6.js","sourcesContent":["var wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar test = {};\n\ntest[TO_STRING_TAG] = 'z';\n\nmodule.exports = String(test) === '[object z]';\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar aCallable = require('../internals/a-callable');\n\nvar bind = uncurryThis(uncurryThis.bind);\n\n// optional / simple context binding\nmodule.exports = function (fn, that) {\n aCallable(fn);\n return that === undefined ? fn : bind ? bind(fn, that) : function (/* ...args */) {\n return fn.apply(that, arguments);\n };\n};\n","import '../../style/base.css';\nimport '../index.css';","var DESCRIPTORS = require('../internals/descriptors');\nvar call = require('../internals/function-call');\nvar propertyIsEnumerableModule = require('../internals/object-property-is-enumerable');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar toPropertyKey = require('../internals/to-property-key');\nvar hasOwn = require('../internals/has-own-property');\nvar IE8_DOM_DEFINE = require('../internals/ie8-dom-define');\n\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar $getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// `Object.getOwnPropertyDescriptor` method\n// https://tc39.es/ecma262/#sec-object.getownpropertydescriptor\nexports.f = DESCRIPTORS ? $getOwnPropertyDescriptor : function getOwnPropertyDescriptor(O, P) {\n O = toIndexedObject(O);\n P = toPropertyKey(P);\n if (IE8_DOM_DEFINE) try {\n return $getOwnPropertyDescriptor(O, P);\n } catch (error) { /* empty */ }\n if (hasOwn(O, P)) return createPropertyDescriptor(!call(propertyIsEnumerableModule.f, O, P), O[P]);\n};\n","var toLength = require('../internals/to-length');\n\n// `LengthOfArrayLike` abstract operation\n// https://tc39.es/ecma262/#sec-lengthofarraylike\nmodule.exports = function (obj) {\n return toLength(obj.length);\n};\n","import { withInstall } from '../utils';\nimport _ConfigProvider from './ConfigProvider';\nexport var ConfigProvider = withInstall(_ConfigProvider);\nexport default ConfigProvider;","var global = require('../internals/global');\nvar isArray = require('../internals/is-array');\nvar isConstructor = require('../internals/is-constructor');\nvar isObject = require('../internals/is-object');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar SPECIES = wellKnownSymbol('species');\nvar Array = global.Array;\n\n// a part of `ArraySpeciesCreate` abstract operation\n// https://tc39.es/ecma262/#sec-arrayspeciescreate\nmodule.exports = function (originalArray) {\n var C;\n if (isArray(originalArray)) {\n C = originalArray.constructor;\n // cross-realm fallback\n if (isConstructor(C) && (C === Array || isArray(C.prototype))) C = undefined;\n else if (isObject(C)) {\n C = C[SPECIES];\n if (C === null) C = undefined;\n }\n } return C === undefined ? Array : C;\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar toObject = require('../internals/to-object');\n\nvar floor = Math.floor;\nvar charAt = uncurryThis(''.charAt);\nvar replace = uncurryThis(''.replace);\nvar stringSlice = uncurryThis(''.slice);\nvar SUBSTITUTION_SYMBOLS = /\\$([$&'`]|\\d{1,2}|<[^>]*>)/g;\nvar SUBSTITUTION_SYMBOLS_NO_NAMED = /\\$([$&'`]|\\d{1,2})/g;\n\n// `GetSubstitution` abstract operation\n// https://tc39.es/ecma262/#sec-getsubstitution\nmodule.exports = function (matched, str, position, captures, namedCaptures, replacement) {\n var tailPos = position + matched.length;\n var m = captures.length;\n var symbols = SUBSTITUTION_SYMBOLS_NO_NAMED;\n if (namedCaptures !== undefined) {\n namedCaptures = toObject(namedCaptures);\n symbols = SUBSTITUTION_SYMBOLS;\n }\n return replace(replacement, symbols, function (match, ch) {\n var capture;\n switch (charAt(ch, 0)) {\n case '$': return '$';\n case '&': return matched;\n case '`': return stringSlice(str, 0, position);\n case \"'\": return stringSlice(str, tailPos);\n case '<':\n capture = namedCaptures[stringSlice(ch, 1, -1)];\n break;\n default: // \\d\\d?\n var n = +ch;\n if (n === 0) return match;\n if (n > m) {\n var f = floor(n / 10);\n if (f === 0) return match;\n if (f <= m) return captures[f - 1] === undefined ? charAt(ch, 1) : captures[f - 1] + charAt(ch, 1);\n return match;\n }\n capture = captures[n - 1];\n }\n return capture === undefined ? '' : capture;\n });\n};\n","import '../../style/base.css';\nimport '../index.css';","var DESCRIPTORS = require('../internals/descriptors');\nvar fails = require('../internals/fails');\nvar createElement = require('../internals/document-create-element');\n\n// Thank's IE8 for his funny defineProperty\nmodule.exports = !DESCRIPTORS && !fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- requied for testing\n return Object.defineProperty(createElement('div'), 'a', {\n get: function () { return 7; }\n }).a != 7;\n});\n","var global = require('../internals/global');\n\nvar String = global.String;\n\nmodule.exports = function (argument) {\n try {\n return String(argument);\n } catch (error) {\n return 'Object';\n }\n};\n","var fails = require('../internals/fails');\nvar global = require('../internals/global');\n\n// babel-minify and Closure Compiler transpiles RegExp('(?<a>b)', 'g') -> /(?<a>b)/g and it causes SyntaxError\nvar $RegExp = global.RegExp;\n\nmodule.exports = fails(function () {\n var re = $RegExp('(?<a>b)', 'g');\n return re.exec('b').groups.a !== 'b' ||\n 'b'.replace(re, '$<a>c') !== 'bc';\n});\n","var global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar anObject = require('../internals/an-object');\nvar isCallable = require('../internals/is-callable');\nvar classof = require('../internals/classof-raw');\nvar regexpExec = require('../internals/regexp-exec');\n\nvar TypeError = global.TypeError;\n\n// `RegExpExec` abstract operation\n// https://tc39.es/ecma262/#sec-regexpexec\nmodule.exports = function (R, S) {\n var exec = R.exec;\n if (isCallable(exec)) {\n var result = call(exec, R, S);\n if (result !== null) anObject(result);\n return result;\n }\n if (classof(R) === 'RegExp') return call(regexpExec, R, S);\n throw TypeError('RegExp#exec called on incompatible receiver');\n};\n","// `IsCallable` abstract operation\n// https://tc39.es/ecma262/#sec-iscallable\nmodule.exports = function (argument) {\n return typeof argument == 'function';\n};\n","var global = require('../internals/global');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\n\nvar TypeError = global.TypeError;\n\nmodule.exports = function (it, Prototype) {\n if (isPrototypeOf(Prototype, it)) return it;\n throw TypeError('Incorrect invocation');\n};\n","import { createVNode as _createVNode } from \"vue\";\nimport { defineComponent } from 'vue';\nimport { addUnit, numericProp, unknownProp, createNamespace } from '../utils';\nimport { useCustomFieldValue } from '@vant/use';\nimport { Loading } from '../loading';\nvar [name, bem] = createNamespace('switch');\nvar switchProps = {\n size: numericProp,\n loading: Boolean,\n disabled: Boolean,\n modelValue: unknownProp,\n activeColor: String,\n inactiveColor: String,\n activeValue: {\n type: unknownProp,\n default: true\n },\n inactiveValue: {\n type: unknownProp,\n default: false\n }\n};\nexport default defineComponent({\n name,\n props: switchProps,\n emits: ['change', 'update:modelValue'],\n\n setup(props, _ref) {\n var {\n emit\n } = _ref;\n\n var isChecked = () => props.modelValue === props.activeValue;\n\n var onClick = () => {\n if (!props.disabled && !props.loading) {\n var newValue = isChecked() ? props.inactiveValue : props.activeValue;\n emit('update:modelValue', newValue);\n emit('change', newValue);\n }\n };\n\n var renderLoading = () => {\n if (props.loading) {\n var color = isChecked() ? props.activeColor : props.inactiveColor;\n return _createVNode(Loading, {\n \"class\": bem('loading'),\n \"color\": color\n }, null);\n }\n };\n\n useCustomFieldValue(() => props.modelValue);\n return () => {\n var {\n size,\n loading,\n disabled,\n activeColor,\n inactiveColor\n } = props;\n var checked = isChecked();\n var style = {\n fontSize: addUnit(size),\n backgroundColor: checked ? activeColor : inactiveColor\n };\n return _createVNode(\"div\", {\n \"role\": \"switch\",\n \"class\": bem({\n on: checked,\n loading,\n disabled\n }),\n \"style\": style,\n \"tabindex\": disabled ? undefined : 0,\n \"aria-checked\": checked,\n \"onClick\": onClick\n }, [_createVNode(\"div\", {\n \"class\": bem('node')\n }, [renderLoading()])]);\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _Switch from './Switch';\nexport var Switch = withInstall(_Switch);\nexport default Switch;","var uncurryThis = require('../internals/function-uncurry-this');\nvar toObject = require('../internals/to-object');\n\nvar hasOwnProperty = uncurryThis({}.hasOwnProperty);\n\n// `HasOwnProperty` abstract operation\n// https://tc39.es/ecma262/#sec-hasownproperty\nmodule.exports = Object.hasOwn || function hasOwn(it, key) {\n return hasOwnProperty(toObject(it), key);\n};\n","var getBuiltIn = require('../internals/get-built-in');\n\nmodule.exports = getBuiltIn('document', 'documentElement');\n","import { inject, watch } from 'vue'; // eslint-disable-next-line\n\nexport var POPUP_TOGGLE_KEY = Symbol();\nexport function onPopupReopen(callback) {\n var popupToggleStatus = inject(POPUP_TOGGLE_KEY, null);\n\n if (popupToggleStatus) {\n watch(popupToggleStatus, show => {\n if (show) {\n callback();\n }\n });\n }\n}","var wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar SAFE_CLOSING = false;\n\ntry {\n var called = 0;\n var iteratorWithReturn = {\n next: function () {\n return { done: !!called++ };\n },\n 'return': function () {\n SAFE_CLOSING = true;\n }\n };\n iteratorWithReturn[ITERATOR] = function () {\n return this;\n };\n // eslint-disable-next-line es/no-array-from, no-throw-literal -- required for testing\n Array.from(iteratorWithReturn, function () { throw 2; });\n} catch (error) { /* empty */ }\n\nmodule.exports = function (exec, SKIP_CLOSING) {\n if (!SKIP_CLOSING && !SAFE_CLOSING) return false;\n var ITERATION_SUPPORT = false;\n try {\n var object = {};\n object[ITERATOR] = function () {\n return {\n next: function () {\n return { done: ITERATION_SUPPORT = true };\n }\n };\n };\n exec(object);\n } catch (error) { /* empty */ }\n return ITERATION_SUPPORT;\n};\n","var userAgent = require('../internals/engine-user-agent');\n\nmodule.exports = /(?:ipad|iphone|ipod).*applewebkit/i.test(userAgent);\n","var global = require('../internals/global');\n\nvar TypeError = global.TypeError;\n\n// `RequireObjectCoercible` abstract operation\n// https://tc39.es/ecma262/#sec-requireobjectcoercible\nmodule.exports = function (it) {\n if (it == undefined) throw TypeError(\"Can't call method on \" + it);\n return it;\n};\n","import { createApp, reactive } from 'vue';\nimport { extend } from '../utils';\nimport { useExpose } from '../composables/use-expose';\nexport function usePopupState() {\n var state = reactive({\n show: false\n });\n\n var toggle = show => {\n state.show = show;\n };\n\n var open = props => {\n extend(state, props, {\n transitionAppear: true\n });\n toggle(true);\n };\n\n var close = () => toggle(false);\n\n useExpose({\n open,\n close,\n toggle\n });\n return {\n open,\n close,\n state,\n toggle\n };\n}\nexport function mountComponent(RootComponent) {\n var app = createApp(RootComponent);\n var root = document.createElement('div');\n document.body.appendChild(root);\n return {\n instance: app.mount(root),\n\n unmount() {\n app.unmount();\n document.body.removeChild(root);\n }\n\n };\n}","var fails = require('../internals/fails');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar V8_VERSION = require('../internals/engine-v8-version');\n\nvar SPECIES = wellKnownSymbol('species');\n\nmodule.exports = function (METHOD_NAME) {\n // We can't use this feature detection in V8 since it causes\n // deoptimization and serious performance degradation\n // https://github.com/zloirock/core-js/issues/677\n return V8_VERSION >= 51 || !fails(function () {\n var array = [];\n var constructor = array.constructor = {};\n constructor[SPECIES] = function () {\n return { foo: 1 };\n };\n return array[METHOD_NAME](Boolean).foo !== 1;\n });\n};\n","var global = require('../internals/global');\nvar bind = require('../internals/function-bind-context');\nvar call = require('../internals/function-call');\nvar anObject = require('../internals/an-object');\nvar tryToString = require('../internals/try-to-string');\nvar isArrayIteratorMethod = require('../internals/is-array-iterator-method');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar getIterator = require('../internals/get-iterator');\nvar getIteratorMethod = require('../internals/get-iterator-method');\nvar iteratorClose = require('../internals/iterator-close');\n\nvar TypeError = global.TypeError;\n\nvar Result = function (stopped, result) {\n this.stopped = stopped;\n this.result = result;\n};\n\nvar ResultPrototype = Result.prototype;\n\nmodule.exports = function (iterable, unboundFunction, options) {\n var that = options && options.that;\n var AS_ENTRIES = !!(options && options.AS_ENTRIES);\n var IS_ITERATOR = !!(options && options.IS_ITERATOR);\n var INTERRUPTED = !!(options && options.INTERRUPTED);\n var fn = bind(unboundFunction, that);\n var iterator, iterFn, index, length, result, next, step;\n\n var stop = function (condition) {\n if (iterator) iteratorClose(iterator, 'normal', condition);\n return new Result(true, condition);\n };\n\n var callFn = function (value) {\n if (AS_ENTRIES) {\n anObject(value);\n return INTERRUPTED ? fn(value[0], value[1], stop) : fn(value[0], value[1]);\n } return INTERRUPTED ? fn(value, stop) : fn(value);\n };\n\n if (IS_ITERATOR) {\n iterator = iterable;\n } else {\n iterFn = getIteratorMethod(iterable);\n if (!iterFn) throw TypeError(tryToString(iterable) + ' is not iterable');\n // optimisation for array iterators\n if (isArrayIteratorMethod(iterFn)) {\n for (index = 0, length = lengthOfArrayLike(iterable); length > index; index++) {\n result = callFn(iterable[index]);\n if (result && isPrototypeOf(ResultPrototype, result)) return result;\n } return new Result(false);\n }\n iterator = getIterator(iterable, iterFn);\n }\n\n next = iterator.next;\n while (!(step = call(next, iterator)).done) {\n try {\n result = callFn(step.value);\n } catch (error) {\n iteratorClose(iterator, 'throw', error);\n }\n if (typeof result == 'object' && result && isPrototypeOf(ResultPrototype, result)) return result;\n } return new Result(false);\n};\n","var toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar max = Math.max;\nvar min = Math.min;\n\n// Helper for a popular repeating case of the spec:\n// Let integer be ? ToInteger(index).\n// If integer < 0, let result be max((length + integer), 0); else let result be min(integer, length).\nmodule.exports = function (index, length) {\n var integer = toIntegerOrInfinity(index);\n return integer < 0 ? max(integer + length, 0) : min(integer, length);\n};\n","var global = require('../internals/global');\nvar getOwnPropertyDescriptor = require('../internals/object-get-own-property-descriptor').f;\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar redefine = require('../internals/redefine');\nvar setGlobal = require('../internals/set-global');\nvar copyConstructorProperties = require('../internals/copy-constructor-properties');\nvar isForced = require('../internals/is-forced');\n\n/*\n options.target - name of the target object\n options.global - target is the global object\n options.stat - export as static methods of target\n options.proto - export as prototype methods of target\n options.real - real prototype method for the `pure` version\n options.forced - export even if the native feature is available\n options.bind - bind methods to the target, required for the `pure` version\n options.wrap - wrap constructors to preventing global pollution, required for the `pure` version\n options.unsafe - use the simple assignment of property instead of delete + defineProperty\n options.sham - add a flag to not completely full polyfills\n options.enumerable - export as enumerable property\n options.noTargetGet - prevent calling a getter on target\n options.name - the .name of the function if it does not match the key\n*/\nmodule.exports = function (options, source) {\n var TARGET = options.target;\n var GLOBAL = options.global;\n var STATIC = options.stat;\n var FORCED, target, key, targetProperty, sourceProperty, descriptor;\n if (GLOBAL) {\n target = global;\n } else if (STATIC) {\n target = global[TARGET] || setGlobal(TARGET, {});\n } else {\n target = (global[TARGET] || {}).prototype;\n }\n if (target) for (key in source) {\n sourceProperty = source[key];\n if (options.noTargetGet) {\n descriptor = getOwnPropertyDescriptor(target, key);\n targetProperty = descriptor && descriptor.value;\n } else targetProperty = target[key];\n FORCED = isForced(GLOBAL ? key : TARGET + (STATIC ? '.' : '#') + key, options.forced);\n // contained in target\n if (!FORCED && targetProperty !== undefined) {\n if (typeof sourceProperty == typeof targetProperty) continue;\n copyConstructorProperties(sourceProperty, targetProperty);\n }\n // add a flag to not completely full polyfills\n if (options.sham || (targetProperty && targetProperty.sham)) {\n createNonEnumerableProperty(sourceProperty, 'sham', true);\n }\n // extend global\n redefine(target, key, sourceProperty, options);\n }\n};\n","var internalObjectKeys = require('../internals/object-keys-internal');\nvar enumBugKeys = require('../internals/enum-bug-keys');\n\nvar hiddenKeys = enumBugKeys.concat('length', 'prototype');\n\n// `Object.getOwnPropertyNames` method\n// https://tc39.es/ecma262/#sec-object.getownpropertynames\n// eslint-disable-next-line es/no-object-getownpropertynames -- safe\nexports.f = Object.getOwnPropertyNames || function getOwnPropertyNames(O) {\n return internalObjectKeys(O, hiddenKeys);\n};\n","'use strict';\nvar getBuiltIn = require('../internals/get-built-in');\nvar definePropertyModule = require('../internals/object-define-property');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar DESCRIPTORS = require('../internals/descriptors');\n\nvar SPECIES = wellKnownSymbol('species');\n\nmodule.exports = function (CONSTRUCTOR_NAME) {\n var Constructor = getBuiltIn(CONSTRUCTOR_NAME);\n var defineProperty = definePropertyModule.f;\n\n if (DESCRIPTORS && Constructor && !Constructor[SPECIES]) {\n defineProperty(Constructor, SPECIES, {\n configurable: true,\n get: function () { return this; }\n });\n }\n};\n","import { ImagePreview } from './function-call';\nexport default ImagePreview;\nexport { ImagePreview };","import '../../style/base.css';\nimport '../../loading/index.css';\nimport '../index.css';","var call = require('../internals/function-call');\nvar anObject = require('../internals/an-object');\nvar getMethod = require('../internals/get-method');\n\nmodule.exports = function (iterator, kind, value) {\n var innerResult, innerError;\n anObject(iterator);\n try {\n innerResult = getMethod(iterator, 'return');\n if (!innerResult) {\n if (kind === 'throw') throw value;\n return value;\n }\n innerResult = call(innerResult, iterator);\n } catch (error) {\n innerError = true;\n innerResult = error;\n }\n if (kind === 'throw') throw value;\n if (innerError) throw innerResult;\n anObject(innerResult);\n return value;\n};\n","var FunctionPrototype = Function.prototype;\nvar apply = FunctionPrototype.apply;\nvar bind = FunctionPrototype.bind;\nvar call = FunctionPrototype.call;\n\n// eslint-disable-next-line es/no-reflect -- safe\nmodule.exports = typeof Reflect == 'object' && Reflect.apply || (bind ? call.bind(apply) : function () {\n return call.apply(apply, arguments);\n});\n","import { inject } from 'vue'; // eslint-disable-next-line\n\nexport var TAB_STATUS_KEY = Symbol();\nexport var useTabStatus = () => inject(TAB_STATUS_KEY, null);","import { createVNode as _createVNode } from \"vue\";\nimport { ref, watch, nextTick, onUpdated, onMounted, defineComponent } from 'vue'; // Utils\n\nimport { isHidden, truthProp, makeStringProp, makeNumericProp, createNamespace } from '../utils'; // Composables\n\nimport { useRect, useScrollParent, useEventListener } from '@vant/use';\nimport { useExpose } from '../composables/use-expose';\nimport { useTabStatus } from '../composables/use-tab-status'; // Components\n\nimport { Loading } from '../loading'; // Types\n\nvar [name, bem, t] = createNamespace('list');\nvar listProps = {\n error: Boolean,\n offset: makeNumericProp(300),\n loading: Boolean,\n finished: Boolean,\n errorText: String,\n direction: makeStringProp('down'),\n loadingText: String,\n finishedText: String,\n immediateCheck: truthProp\n};\nexport default defineComponent({\n name,\n props: listProps,\n emits: ['load', 'update:error', 'update:loading'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n // use sync innerLoading state to avoid repeated loading in some edge cases\n var loading = ref(false);\n var root = ref();\n var placeholder = ref();\n var tabStatus = useTabStatus();\n var scrollParent = useScrollParent(root);\n\n var check = () => {\n nextTick(() => {\n if (loading.value || props.finished || props.error || // skip check when inside an inactive tab\n (tabStatus == null ? void 0 : tabStatus.value) === false) {\n return;\n }\n\n var {\n offset,\n direction\n } = props;\n var scrollParentRect = useRect(scrollParent);\n\n if (!scrollParentRect.height || isHidden(root)) {\n return;\n }\n\n var isReachEdge = false;\n var placeholderRect = useRect(placeholder);\n\n if (direction === 'up') {\n isReachEdge = scrollParentRect.top - placeholderRect.top <= offset;\n } else {\n isReachEdge = placeholderRect.bottom - scrollParentRect.bottom <= offset;\n }\n\n if (isReachEdge) {\n loading.value = true;\n emit('update:loading', true);\n emit('load');\n }\n });\n };\n\n var renderFinishedText = () => {\n if (props.finished) {\n var text = slots.finished ? slots.finished() : props.finishedText;\n\n if (text) {\n return _createVNode(\"div\", {\n \"class\": bem('finished-text')\n }, [text]);\n }\n }\n };\n\n var clickErrorText = () => {\n emit('update:error', false);\n check();\n };\n\n var renderErrorText = () => {\n if (props.error) {\n var text = slots.error ? slots.error() : props.errorText;\n\n if (text) {\n return _createVNode(\"div\", {\n \"role\": \"button\",\n \"class\": bem('error-text'),\n \"tabindex\": 0,\n \"onClick\": clickErrorText\n }, [text]);\n }\n }\n };\n\n var renderLoading = () => {\n if (loading.value && !props.finished) {\n return _createVNode(\"div\", {\n \"class\": bem('loading')\n }, [slots.loading ? slots.loading() : _createVNode(Loading, {\n \"class\": bem('loading-icon')\n }, {\n default: () => [props.loadingText || t('loading')]\n })]);\n }\n };\n\n watch(() => [props.loading, props.finished, props.error], check);\n\n if (tabStatus) {\n watch(tabStatus, tabActive => {\n if (tabActive) {\n check();\n }\n });\n }\n\n onUpdated(() => {\n loading.value = props.loading;\n });\n onMounted(() => {\n if (props.immediateCheck) {\n check();\n }\n });\n useExpose({\n check\n });\n useEventListener('scroll', check, {\n target: scrollParent\n });\n return () => {\n var Content = slots.default == null ? void 0 : slots.default();\n\n var Placeholder = _createVNode(\"div\", {\n \"ref\": placeholder,\n \"class\": bem('placeholder')\n }, null);\n\n return _createVNode(\"div\", {\n \"ref\": root,\n \"role\": \"feed\",\n \"class\": bem(),\n \"aria-busy\": loading.value\n }, [props.direction === 'down' ? Content : Placeholder, renderLoading(), renderFinishedText(), renderErrorText(), props.direction === 'up' ? Content : Placeholder]);\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _List from './List';\nexport var List = withInstall(_List);\nexport default List;","var global = require('../internals/global');\nvar apply = require('../internals/function-apply');\nvar bind = require('../internals/function-bind-context');\nvar isCallable = require('../internals/is-callable');\nvar hasOwn = require('../internals/has-own-property');\nvar fails = require('../internals/fails');\nvar html = require('../internals/html');\nvar arraySlice = require('../internals/array-slice');\nvar createElement = require('../internals/document-create-element');\nvar IS_IOS = require('../internals/engine-is-ios');\nvar IS_NODE = require('../internals/engine-is-node');\n\nvar set = global.setImmediate;\nvar clear = global.clearImmediate;\nvar process = global.process;\nvar Dispatch = global.Dispatch;\nvar Function = global.Function;\nvar MessageChannel = global.MessageChannel;\nvar String = global.String;\nvar counter = 0;\nvar queue = {};\nvar ONREADYSTATECHANGE = 'onreadystatechange';\nvar location, defer, channel, port;\n\ntry {\n // Deno throws a ReferenceError on `location` access without `--location` flag\n location = global.location;\n} catch (error) { /* empty */ }\n\nvar run = function (id) {\n if (hasOwn(queue, id)) {\n var fn = queue[id];\n delete queue[id];\n fn();\n }\n};\n\nvar runner = function (id) {\n return function () {\n run(id);\n };\n};\n\nvar listener = function (event) {\n run(event.data);\n};\n\nvar post = function (id) {\n // old engines have not location.origin\n global.postMessage(String(id), location.protocol + '//' + location.host);\n};\n\n// Node.js 0.9+ & IE10+ has setImmediate, otherwise:\nif (!set || !clear) {\n set = function setImmediate(fn) {\n var args = arraySlice(arguments, 1);\n queue[++counter] = function () {\n apply(isCallable(fn) ? fn : Function(fn), undefined, args);\n };\n defer(counter);\n return counter;\n };\n clear = function clearImmediate(id) {\n delete queue[id];\n };\n // Node.js 0.8-\n if (IS_NODE) {\n defer = function (id) {\n process.nextTick(runner(id));\n };\n // Sphere (JS game engine) Dispatch API\n } else if (Dispatch && Dispatch.now) {\n defer = function (id) {\n Dispatch.now(runner(id));\n };\n // Browsers with MessageChannel, includes WebWorkers\n // except iOS - https://github.com/zloirock/core-js/issues/624\n } else if (MessageChannel && !IS_IOS) {\n channel = new MessageChannel();\n port = channel.port2;\n channel.port1.onmessage = listener;\n defer = bind(port.postMessage, port);\n // Browsers with postMessage, skip WebWorkers\n // IE8 has postMessage, but it's sync & typeof its postMessage is 'object'\n } else if (\n global.addEventListener &&\n isCallable(global.postMessage) &&\n !global.importScripts &&\n location && location.protocol !== 'file:' &&\n !fails(post)\n ) {\n defer = post;\n global.addEventListener('message', listener, false);\n // IE8-\n } else if (ONREADYSTATECHANGE in createElement('script')) {\n defer = function (id) {\n html.appendChild(createElement('script'))[ONREADYSTATECHANGE] = function () {\n html.removeChild(this);\n run(id);\n };\n };\n // Rest old browsers\n } else {\n defer = function (id) {\n setTimeout(runner(id), 0);\n };\n }\n}\n\nmodule.exports = {\n set: set,\n clear: clear\n};\n","var global = require('../internals/global');\nvar userAgent = require('../internals/engine-user-agent');\n\nvar process = global.process;\nvar Deno = global.Deno;\nvar versions = process && process.versions || Deno && Deno.version;\nvar v8 = versions && versions.v8;\nvar match, version;\n\nif (v8) {\n match = v8.split('.');\n // in old Chrome, versions of V8 isn't V8 = Chrome / 10\n // but their correct versions are not interesting for us\n version = match[0] > 0 && match[0] < 4 ? 1 : +(match[0] + match[1]);\n}\n\n// BrowserFS NodeJS `process` polyfill incorrectly set `.v8` to `0.0`\n// so check `userAgent` even if `.v8` exists, but 0\nif (!version && userAgent) {\n match = userAgent.match(/Edge\\/(\\d+)/);\n if (!match || match[1] >= 74) {\n match = userAgent.match(/Chrome\\/(\\d+)/);\n if (match) version = +match[1];\n }\n}\n\nmodule.exports = version;\n","import { inBrowser } from '../utils';\nimport { onDeactivated, onBeforeUnmount } from 'vue';\nimport { onMountedOrActivated } from '@vant/use'; // @Experimental\n\nexport function useVisibilityChange(target, onChange) {\n // compatibility: https://caniuse.com/#feat=intersectionobserver\n if (!inBrowser || !window.IntersectionObserver) {\n return;\n }\n\n var observer = new IntersectionObserver(entries => {\n // visibility changed\n onChange(entries[0].intersectionRatio > 0);\n }, {\n root: document.body\n });\n\n var observe = () => {\n if (target.value) {\n observer.observe(target.value);\n }\n };\n\n var unobserve = () => {\n if (target.value) {\n observer.unobserve(target.value);\n }\n };\n\n onDeactivated(unobserve);\n onBeforeUnmount(unobserve);\n onMountedOrActivated(observe);\n}","import { createVNode as _createVNode } from \"vue\";\nimport { ref, watch, computed, reactive, defineComponent } from 'vue'; // Utils\n\nimport { extend, isHidden, unitToPx, numericProp, getScrollTop, getZIndexStyle, makeStringProp, makeNumericProp, createNamespace } from '../utils'; // Composables\n\nimport { useRect, useEventListener, useScrollParent } from '@vant/use';\nimport { useVisibilityChange } from '../composables/use-visibility-change';\nvar [name, bem] = createNamespace('sticky');\nvar stickyProps = {\n zIndex: numericProp,\n position: makeStringProp('top'),\n container: Object,\n offsetTop: makeNumericProp(0),\n offsetBottom: makeNumericProp(0)\n};\nexport default defineComponent({\n name,\n props: stickyProps,\n emits: ['scroll', 'change'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var root = ref();\n var scrollParent = useScrollParent(root);\n var state = reactive({\n fixed: false,\n width: 0,\n // root width\n height: 0,\n // root height\n transform: 0\n });\n var offset = computed(() => unitToPx(props.position === 'top' ? props.offsetTop : props.offsetBottom));\n var rootStyle = computed(() => {\n var {\n fixed,\n height,\n width\n } = state;\n\n if (fixed) {\n return {\n width: width + \"px\",\n height: height + \"px\"\n };\n }\n });\n var stickyStyle = computed(() => {\n if (!state.fixed) {\n return;\n }\n\n var style = extend(getZIndexStyle(props.zIndex), {\n width: state.width + \"px\",\n height: state.height + \"px\",\n [props.position]: offset.value + \"px\"\n });\n\n if (state.transform) {\n style.transform = \"translate3d(0, \" + state.transform + \"px, 0)\";\n }\n\n return style;\n });\n\n var emitScroll = scrollTop => emit('scroll', {\n scrollTop,\n isFixed: state.fixed\n });\n\n var onScroll = () => {\n if (!root.value || isHidden(root)) {\n return;\n }\n\n var {\n container,\n position\n } = props;\n var rootRect = useRect(root);\n var scrollTop = getScrollTop(window);\n state.width = rootRect.width;\n state.height = rootRect.height;\n\n if (position === 'top') {\n // The sticky component should be kept inside the container element\n if (container) {\n var containerRect = useRect(container);\n var difference = containerRect.bottom - offset.value - state.height;\n state.fixed = offset.value > rootRect.top && containerRect.bottom > 0;\n state.transform = difference < 0 ? difference : 0;\n } else {\n state.fixed = offset.value > rootRect.top;\n }\n } else {\n var {\n clientHeight\n } = document.documentElement;\n\n if (container) {\n var _containerRect = useRect(container);\n\n var _difference = clientHeight - _containerRect.top - offset.value - state.height;\n\n state.fixed = clientHeight - offset.value < rootRect.bottom && clientHeight > _containerRect.top;\n state.transform = _difference < 0 ? -_difference : 0;\n } else {\n state.fixed = clientHeight - offset.value < rootRect.bottom;\n }\n }\n\n emitScroll(scrollTop);\n };\n\n watch(() => state.fixed, value => emit('change', value));\n useEventListener('scroll', onScroll, {\n target: scrollParent\n });\n useVisibilityChange(root, onScroll);\n return () => _createVNode(\"div\", {\n \"ref\": root,\n \"style\": rootStyle.value\n }, [_createVNode(\"div\", {\n \"class\": bem({\n fixed: state.fixed\n }),\n \"style\": stickyStyle.value\n }, [slots.default == null ? void 0 : slots.default()])]);\n }\n\n});","import { withInstall } from '../utils';\nimport _Sticky from './Sticky';\nexport var Sticky = withInstall(_Sticky);\nexport default Sticky;","var getBuiltIn = require('../internals/get-built-in');\n\nmodule.exports = getBuiltIn('navigator', 'userAgent') || '';\n","import { Fragment as _Fragment, createVNode as _createVNode, mergeProps as _mergeProps } from \"vue\";\nimport { defineComponent } from 'vue';\nimport { truthProp, createNamespace, BORDER_TOP_BOTTOM } from '../utils';\nvar [name, bem] = createNamespace('cell-group');\nvar cellGroupProps = {\n title: String,\n inset: Boolean,\n border: truthProp\n};\nexport default defineComponent({\n name,\n inheritAttrs: false,\n props: cellGroupProps,\n\n setup(props, _ref) {\n var {\n slots,\n attrs\n } = _ref;\n\n var renderGroup = () => _createVNode(\"div\", _mergeProps({\n \"class\": [bem({\n inset: props.inset\n }), {\n [BORDER_TOP_BOTTOM]: props.border && !props.inset\n }]\n }, attrs), [slots.default == null ? void 0 : slots.default()]);\n\n var renderTitle = () => _createVNode(\"div\", {\n \"class\": bem('title', {\n inset: props.inset\n })\n }, [slots.title ? slots.title() : props.title]);\n\n return () => {\n if (props.title || slots.title) {\n return _createVNode(_Fragment, null, [renderTitle(), renderGroup()]);\n }\n\n return renderGroup();\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _CellGroup from './CellGroup';\nexport var CellGroup = withInstall(_CellGroup);\nexport default CellGroup;","var classof = require('../internals/classof');\nvar getMethod = require('../internals/get-method');\nvar Iterators = require('../internals/iterators');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar ITERATOR = wellKnownSymbol('iterator');\n\nmodule.exports = function (it) {\n if (it != undefined) return getMethod(it, ITERATOR)\n || getMethod(it, '@@iterator')\n || Iterators[classof(it)];\n};\n","var DESCRIPTORS = require('../internals/descriptors');\nvar definePropertyModule = require('../internals/object-define-property');\nvar anObject = require('../internals/an-object');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar objectKeys = require('../internals/object-keys');\n\n// `Object.defineProperties` method\n// https://tc39.es/ecma262/#sec-object.defineproperties\n// eslint-disable-next-line es/no-object-defineproperties -- safe\nmodule.exports = DESCRIPTORS ? Object.defineProperties : function defineProperties(O, Properties) {\n anObject(O);\n var props = toIndexedObject(Properties);\n var keys = objectKeys(Properties);\n var length = keys.length;\n var index = 0;\n var key;\n while (length > index) definePropertyModule.f(O, key = keys[index++], props[key]);\n return O;\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\n\nmodule.exports = uncurryThis({}.isPrototypeOf);\n","import { withInstall } from '../utils';\nimport _CheckboxGroup from './CheckboxGroup';\nexport var CheckboxGroup = withInstall(_CheckboxGroup);\nexport default CheckboxGroup;","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\n\nvar String = global.String;\nvar TypeError = global.TypeError;\n\nmodule.exports = function (argument) {\n if (typeof argument == 'object' || isCallable(argument)) return argument;\n throw TypeError(\"Can't set \" + String(argument) + ' as a prototype');\n};\n","import { createVNode as _createVNode } from \"vue\";\nimport { provide, computed, defineComponent } from 'vue';\nimport { kebabCase, makeStringProp, createNamespace } from '../utils';\nvar [name, bem] = createNamespace('config-provider');\nexport var CONFIG_PROVIDER_KEY = Symbol(name);\nvar configProviderProps = {\n tag: makeStringProp('div'),\n themeVars: Object,\n iconPrefix: String\n};\n\nfunction mapThemeVarsToCSSVars(themeVars) {\n var cssVars = {};\n Object.keys(themeVars).forEach(key => {\n cssVars[\"--van-\" + kebabCase(key)] = themeVars[key];\n });\n return cssVars;\n}\n\nexport default defineComponent({\n name,\n props: configProviderProps,\n\n setup(props, _ref) {\n var {\n slots\n } = _ref;\n var style = computed(() => {\n if (props.themeVars) {\n return mapThemeVarsToCSSVars(props.themeVars);\n }\n });\n provide(CONFIG_PROVIDER_KEY, props);\n return () => _createVNode(props.tag, {\n \"class\": bem(),\n \"style\": style.value\n }, {\n default: () => [slots.default == null ? void 0 : slots.default()]\n });\n }\n\n});","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../../icon/index.css';\nimport '../../checkbox-group/index.css';\nimport '../index.css';","'use strict';\nvar charAt = require('../internals/string-multibyte').charAt;\nvar toString = require('../internals/to-string');\nvar InternalStateModule = require('../internals/internal-state');\nvar defineIterator = require('../internals/define-iterator');\n\nvar STRING_ITERATOR = 'String Iterator';\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(STRING_ITERATOR);\n\n// `String.prototype[@@iterator]` method\n// https://tc39.es/ecma262/#sec-string.prototype-@@iterator\ndefineIterator(String, 'String', function (iterated) {\n setInternalState(this, {\n type: STRING_ITERATOR,\n string: toString(iterated),\n index: 0\n });\n// `%StringIteratorPrototype%.next` method\n// https://tc39.es/ecma262/#sec-%stringiteratorprototype%.next\n}, function next() {\n var state = getInternalState(this);\n var string = state.string;\n var index = state.index;\n var point;\n if (index >= string.length) return { value: undefined, done: true };\n point = charAt(string, index);\n state.index += point.length;\n return { value: point, done: false };\n});\n","import { createVNode as _createVNode } from \"vue\";\nimport { ref, computed, defineComponent } from 'vue';\nimport { extend, addUnit, truthProp, numericProp, unknownProp, makeStringProp, makeRequiredProp } from '../utils';\nimport { Icon } from '../icon';\nexport var checkerProps = {\n name: unknownProp,\n shape: makeStringProp('round'),\n disabled: Boolean,\n iconSize: numericProp,\n modelValue: unknownProp,\n checkedColor: String,\n labelPosition: String,\n labelDisabled: Boolean\n};\nexport default defineComponent({\n props: extend({}, checkerProps, {\n bem: makeRequiredProp(Function),\n role: String,\n parent: Object,\n checked: Boolean,\n bindGroup: truthProp\n }),\n emits: ['click', 'toggle'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var iconRef = ref();\n\n var getParentProp = name => {\n if (props.parent && props.bindGroup) {\n return props.parent.props[name];\n }\n };\n\n var disabled = computed(() => getParentProp('disabled') || props.disabled);\n var direction = computed(() => getParentProp('direction'));\n var iconStyle = computed(() => {\n var checkedColor = props.checkedColor || getParentProp('checkedColor');\n\n if (checkedColor && props.checked && !disabled.value) {\n return {\n borderColor: checkedColor,\n backgroundColor: checkedColor\n };\n }\n });\n\n var onClick = event => {\n var {\n target\n } = event;\n var icon = iconRef.value;\n var iconClicked = icon === target || (icon == null ? void 0 : icon.contains(target));\n\n if (!disabled.value && (iconClicked || !props.labelDisabled)) {\n emit('toggle');\n }\n\n emit('click', event);\n };\n\n var renderIcon = () => {\n var {\n bem,\n shape,\n checked\n } = props;\n var iconSize = props.iconSize || getParentProp('iconSize');\n return _createVNode(\"div\", {\n \"ref\": iconRef,\n \"class\": bem('icon', [shape, {\n disabled: disabled.value,\n checked\n }]),\n \"style\": {\n fontSize: addUnit(iconSize)\n }\n }, [slots.icon ? slots.icon({\n checked,\n disabled: disabled.value\n }) : _createVNode(Icon, {\n \"name\": \"success\",\n \"style\": iconStyle.value\n }, null)]);\n };\n\n var renderLabel = () => {\n if (slots.default) {\n return _createVNode(\"span\", {\n \"class\": props.bem('label', [props.labelPosition, {\n disabled: disabled.value\n }])\n }, [slots.default()]);\n }\n };\n\n return () => {\n var nodes = props.labelPosition === 'left' ? [renderLabel(), renderIcon()] : [renderIcon(), renderLabel()];\n return _createVNode(\"div\", {\n \"role\": props.role,\n \"class\": props.bem([{\n disabled: disabled.value,\n 'label-disabled': props.labelDisabled\n }, direction.value]),\n \"tabindex\": disabled.value ? undefined : 0,\n \"aria-checked\": props.checked,\n \"onClick\": onClick\n }, [nodes]);\n };\n }\n\n});","import { getTarget, getDevtoolsGlobalHook, isProxyAvailable } from './env';\nimport { HOOK_SETUP } from './const';\nimport { ApiProxy } from './proxy';\nexport * from './api';\nexport * from './plugin';\nexport function setupDevtoolsPlugin(pluginDescriptor, setupFn) {\n const target = getTarget();\n const hook = getDevtoolsGlobalHook();\n const enableProxy = isProxyAvailable && pluginDescriptor.enableEarlyProxy;\n if (hook && (target.__VUE_DEVTOOLS_PLUGIN_API_AVAILABLE__ || !enableProxy)) {\n hook.emit(HOOK_SETUP, pluginDescriptor, setupFn);\n }\n else {\n const proxy = enableProxy ? new ApiProxy(pluginDescriptor, hook) : null;\n const list = target.__VUE_DEVTOOLS_PLUGINS__ = target.__VUE_DEVTOOLS_PLUGINS__ || [];\n list.push({\n pluginDescriptor,\n setupFn,\n proxy,\n });\n if (proxy)\n setupFn(proxy.proxiedTarget);\n }\n}\n","module.exports = {};\n","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../../icon/index.css';\nimport '../index.css';","import { createVNode as _createVNode, mergeProps as _mergeProps, resolveDirective as _resolveDirective } from \"vue\";\nimport { watch, computed, defineComponent } from 'vue'; // Utils\n\nimport { createNamespace, extend, pick, truthProp } from '../utils';\nimport { CHECKBOX_GROUP_KEY } from '../checkbox-group/CheckboxGroup'; // Composables\n\nimport { useParent, useCustomFieldValue } from '@vant/use';\nimport { useExpose } from '../composables/use-expose'; // Components\n\nimport Checker, { checkerProps } from './Checker'; // Types\n\nvar [name, bem] = createNamespace('checkbox');\nvar checkboxProps = extend({}, checkerProps, {\n bindGroup: truthProp\n});\nexport default defineComponent({\n name,\n props: checkboxProps,\n emits: ['change', 'update:modelValue'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var {\n parent\n } = useParent(CHECKBOX_GROUP_KEY);\n\n var setParentValue = checked => {\n var {\n name\n } = props;\n var {\n max,\n modelValue\n } = parent.props;\n var value = modelValue.slice();\n\n if (checked) {\n var overlimit = max && value.length >= max;\n\n if (!overlimit && !value.includes(name)) {\n value.push(name);\n\n if (props.bindGroup) {\n parent.updateValue(value);\n }\n }\n } else {\n var index = value.indexOf(name);\n\n if (index !== -1) {\n value.splice(index, 1);\n\n if (props.bindGroup) {\n parent.updateValue(value);\n }\n }\n }\n };\n\n var checked = computed(() => {\n if (parent && props.bindGroup) {\n return parent.props.modelValue.indexOf(props.name) !== -1;\n }\n\n return !!props.modelValue;\n });\n\n var toggle = function (newValue) {\n if (newValue === void 0) {\n newValue = !checked.value;\n }\n\n if (parent && props.bindGroup) {\n setParentValue(newValue);\n } else {\n emit('update:modelValue', newValue);\n }\n };\n\n watch(() => props.modelValue, value => emit('change', value));\n useExpose({\n toggle,\n props,\n checked\n });\n useCustomFieldValue(() => props.modelValue);\n return () => _createVNode(Checker, _mergeProps({\n \"bem\": bem,\n \"role\": \"checkbox\",\n \"parent\": parent,\n \"checked\": checked.value,\n \"onToggle\": toggle\n }, props), pick(slots, ['default', 'icon']));\n }\n\n});","import { withInstall } from '../utils';\nimport _Checkbox from './Checkbox';\nexport var Checkbox = withInstall(_Checkbox);\nexport default Checkbox;","var global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\nvar classof = require('../internals/classof-raw');\n\nvar Object = global.Object;\nvar split = uncurryThis(''.split);\n\n// fallback for non-array-like ES3 and non-enumerable old V8 strings\nmodule.exports = fails(function () {\n // throws an error in rhino, see https://github.com/mozilla/rhino/issues/346\n // eslint-disable-next-line no-prototype-builtins -- safe\n return !Object('z').propertyIsEnumerable(0);\n}) ? function (it) {\n return classof(it) == 'String' ? split(it, '') : Object(it);\n} : Object;\n","import { withDirectives as _withDirectives, mergeProps as _mergeProps, resolveDirective as _resolveDirective, createVNode as _createVNode } from \"vue\";\nimport { ref, watch, computed, onBeforeUnmount, defineComponent, getCurrentInstance } from 'vue'; // Utils\n\nimport { isDef, addUnit, inBrowser, truthProp, numericProp, makeStringProp, createNamespace } from '../utils'; // Components\n\nimport { Icon } from '../icon';\nvar [name, bem] = createNamespace('image');\nvar imageProps = {\n src: String,\n alt: String,\n fit: String,\n round: Boolean,\n width: numericProp,\n height: numericProp,\n radius: numericProp,\n lazyLoad: Boolean,\n iconSize: numericProp,\n showError: truthProp,\n errorIcon: makeStringProp('photo-fail'),\n iconPrefix: String,\n showLoading: truthProp,\n loadingIcon: makeStringProp('photo')\n};\nexport default defineComponent({\n name,\n props: imageProps,\n emits: ['load', 'error'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var error = ref(false);\n var loading = ref(true);\n var imageRef = ref();\n var {\n $Lazyload\n } = getCurrentInstance().proxy;\n var style = computed(() => {\n var style = {\n width: addUnit(props.width),\n height: addUnit(props.height)\n };\n\n if (isDef(props.radius)) {\n style.overflow = 'hidden';\n style.borderRadius = addUnit(props.radius);\n }\n\n return style;\n });\n watch(() => props.src, () => {\n error.value = false;\n loading.value = true;\n });\n\n var onLoad = event => {\n loading.value = false;\n emit('load', event);\n };\n\n var onError = event => {\n error.value = true;\n loading.value = false;\n emit('error', event);\n };\n\n var renderIcon = (name, className, slot) => {\n if (slot) {\n return slot();\n }\n\n return _createVNode(Icon, {\n \"name\": name,\n \"size\": props.iconSize,\n \"class\": className,\n \"classPrefix\": props.iconPrefix\n }, null);\n };\n\n var renderPlaceholder = () => {\n if (loading.value && props.showLoading) {\n return _createVNode(\"div\", {\n \"class\": bem('loading')\n }, [renderIcon(props.loadingIcon, bem('loading-icon'), slots.loading)]);\n }\n\n if (error.value && props.showError) {\n return _createVNode(\"div\", {\n \"class\": bem('error')\n }, [renderIcon(props.errorIcon, bem('error-icon'), slots.error)]);\n }\n };\n\n var renderImage = () => {\n if (error.value || !props.src) {\n return;\n }\n\n var attrs = {\n alt: props.alt,\n class: bem('img'),\n style: {\n objectFit: props.fit\n }\n };\n\n if (props.lazyLoad) {\n return _withDirectives(_createVNode(\"img\", _mergeProps({\n \"ref\": imageRef\n }, attrs), null), [[_resolveDirective(\"lazy\"), props.src]]);\n }\n\n return _createVNode(\"img\", _mergeProps({\n \"src\": props.src,\n \"onLoad\": onLoad,\n \"onError\": onError\n }, attrs), null);\n };\n\n var onLazyLoaded = _ref2 => {\n var {\n el\n } = _ref2;\n\n if (el === imageRef.value && loading.value) {\n onLoad();\n }\n };\n\n var onLazyLoadError = _ref3 => {\n var {\n el\n } = _ref3;\n\n if (el === imageRef.value && !error.value) {\n onError();\n }\n };\n\n if ($Lazyload && inBrowser) {\n $Lazyload.$on('loaded', onLazyLoaded);\n $Lazyload.$on('error', onLazyLoadError);\n onBeforeUnmount(() => {\n $Lazyload.$off('loaded', onLazyLoaded);\n $Lazyload.$off('error', onLazyLoadError);\n });\n }\n\n return () => _createVNode(\"div\", {\n \"class\": bem({\n round: props.round\n }),\n \"style\": style.value\n }, [renderImage(), renderPlaceholder(), slots.default == null ? void 0 : slots.default()]);\n }\n\n});","import { withInstall } from '../utils';\nimport _Image from './Image';\nexport var Image = withInstall(_Image);\nexport default Image;","var wellKnownSymbol = require('../internals/well-known-symbol');\nvar create = require('../internals/object-create');\nvar definePropertyModule = require('../internals/object-define-property');\n\nvar UNSCOPABLES = wellKnownSymbol('unscopables');\nvar ArrayPrototype = Array.prototype;\n\n// Array.prototype[@@unscopables]\n// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables\nif (ArrayPrototype[UNSCOPABLES] == undefined) {\n definePropertyModule.f(ArrayPrototype, UNSCOPABLES, {\n configurable: true,\n value: create(null)\n });\n}\n\n// add a key to Array.prototype[@@unscopables]\nmodule.exports = function (key) {\n ArrayPrototype[UNSCOPABLES][key] = true;\n};\n","var global = require('../internals/global');\n\nmodule.exports = function (a, b) {\n var console = global.console;\n if (console && console.error) {\n arguments.length == 1 ? console.error(a) : console.error(a, b);\n }\n};\n","import '../../style/base.css';","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../../icon/index.css';\nimport '../../image/index.css';\nimport '../../loading/index.css';\nimport '../../overlay/index.css';\nimport '../../popup/index.css';\nimport '../../swipe/index.css';\nimport '../../swipe-item/index.css';\nimport '../index.css';","import { createVNode as _createVNode, mergeProps as _mergeProps } from \"vue\";\nimport { extend, inBrowser, withInstall } from '../utils';\nimport { mountComponent, usePopupState } from '../utils/mount-component';\nimport VanImagePreview from './ImagePreview';\nvar instance;\nvar defaultConfig = {\n loop: true,\n images: [],\n maxZoom: 3,\n minZoom: 1 / 3,\n onScale: undefined,\n onClose: undefined,\n onChange: undefined,\n teleport: 'body',\n className: '',\n showIndex: true,\n closeable: false,\n closeIcon: 'clear',\n transition: undefined,\n beforeClose: undefined,\n overlayStyle: undefined,\n startPosition: 0,\n swipeDuration: 300,\n showIndicators: false,\n closeOnPopstate: true,\n closeIconPosition: 'top-right'\n};\n\nfunction initInstance() {\n ({\n instance\n } = mountComponent({\n setup() {\n var {\n state,\n toggle\n } = usePopupState();\n\n var onClosed = () => {\n state.images = [];\n };\n\n return () => _createVNode(VanImagePreview, _mergeProps(state, {\n \"onClosed\": onClosed,\n \"onUpdate:show\": toggle\n }), null);\n }\n\n }));\n}\n\nvar ImagePreview = function (options, startPosition) {\n if (startPosition === void 0) {\n startPosition = 0;\n }\n\n /* istanbul ignore if */\n if (!inBrowser) {\n return;\n }\n\n if (!instance) {\n initInstance();\n }\n\n options = Array.isArray(options) ? {\n images: options,\n startPosition\n } : options;\n instance.open(extend({}, defaultConfig, options));\n return instance;\n};\n\nImagePreview.Component = withInstall(VanImagePreview);\n\nImagePreview.install = app => {\n app.use(ImagePreview.Component);\n};\n\nexport { ImagePreview };","import { createVNode as _createVNode } from \"vue\";\nimport { ref, watch, reactive, computed, onMounted, onActivated, onDeactivated, onBeforeUnmount, defineComponent } from 'vue'; // Utils\n\nimport { clamp, isHidden, truthProp, numericProp, windowWidth, windowHeight, preventDefault, createNamespace, makeNumericProp } from '../utils'; // Composables\n\nimport { doubleRaf, useChildren, usePageVisibility } from '@vant/use';\nimport { useTouch } from '../composables/use-touch';\nimport { useExpose } from '../composables/use-expose';\nimport { onPopupReopen } from '../composables/on-popup-reopen'; // Types\n\nvar [name, bem] = createNamespace('swipe');\nvar swipeProps = {\n loop: truthProp,\n width: numericProp,\n height: numericProp,\n vertical: Boolean,\n autoplay: makeNumericProp(0),\n duration: makeNumericProp(500),\n touchable: truthProp,\n lazyRender: Boolean,\n initialSwipe: makeNumericProp(0),\n indicatorColor: String,\n showIndicators: truthProp,\n stopPropagation: truthProp\n};\nexport var SWIPE_KEY = Symbol(name);\nexport default defineComponent({\n name,\n props: swipeProps,\n emits: ['change'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var root = ref();\n var state = reactive({\n rect: null,\n width: 0,\n height: 0,\n offset: 0,\n active: 0,\n swiping: false\n });\n var touch = useTouch();\n var {\n children,\n linkChildren\n } = useChildren(SWIPE_KEY);\n var count = computed(() => children.length);\n var size = computed(() => state[props.vertical ? 'height' : 'width']);\n var delta = computed(() => props.vertical ? touch.deltaY.value : touch.deltaX.value);\n var minOffset = computed(() => {\n if (state.rect) {\n var base = props.vertical ? state.rect.height : state.rect.width;\n return base - size.value * count.value;\n }\n\n return 0;\n });\n var maxCount = computed(() => Math.ceil(Math.abs(minOffset.value) / size.value));\n var trackSize = computed(() => count.value * size.value);\n var activeIndicator = computed(() => (state.active + count.value) % count.value);\n var isCorrectDirection = computed(() => {\n var expect = props.vertical ? 'vertical' : 'horizontal';\n return touch.direction.value === expect;\n });\n var trackStyle = computed(() => {\n var style = {\n transitionDuration: (state.swiping ? 0 : props.duration) + \"ms\",\n transform: \"translate\" + (props.vertical ? 'Y' : 'X') + \"(\" + state.offset + \"px)\"\n };\n\n if (size.value) {\n var mainAxis = props.vertical ? 'height' : 'width';\n var crossAxis = props.vertical ? 'width' : 'height';\n style[mainAxis] = trackSize.value + \"px\";\n style[crossAxis] = props[crossAxis] ? props[crossAxis] + \"px\" : '';\n }\n\n return style;\n });\n\n var getTargetActive = pace => {\n var {\n active\n } = state;\n\n if (pace) {\n if (props.loop) {\n return clamp(active + pace, -1, count.value);\n }\n\n return clamp(active + pace, 0, maxCount.value);\n }\n\n return active;\n };\n\n var getTargetOffset = function (targetActive, offset) {\n if (offset === void 0) {\n offset = 0;\n }\n\n var currentPosition = targetActive * size.value;\n\n if (!props.loop) {\n currentPosition = Math.min(currentPosition, -minOffset.value);\n }\n\n var targetOffset = offset - currentPosition;\n\n if (!props.loop) {\n targetOffset = clamp(targetOffset, minOffset.value, 0);\n }\n\n return targetOffset;\n };\n\n var move = _ref2 => {\n var {\n pace = 0,\n offset = 0,\n emitChange\n } = _ref2;\n\n if (count.value <= 1) {\n return;\n }\n\n var {\n active\n } = state;\n var targetActive = getTargetActive(pace);\n var targetOffset = getTargetOffset(targetActive, offset); // auto move first and last swipe in loop mode\n\n if (props.loop) {\n if (children[0] && targetOffset !== minOffset.value) {\n var outRightBound = targetOffset < minOffset.value;\n children[0].setOffset(outRightBound ? trackSize.value : 0);\n }\n\n if (children[count.value - 1] && targetOffset !== 0) {\n var outLeftBound = targetOffset > 0;\n children[count.value - 1].setOffset(outLeftBound ? -trackSize.value : 0);\n }\n }\n\n state.active = targetActive;\n state.offset = targetOffset;\n\n if (emitChange && targetActive !== active) {\n emit('change', activeIndicator.value);\n }\n };\n\n var correctPosition = () => {\n state.swiping = true;\n\n if (state.active <= -1) {\n move({\n pace: count.value\n });\n } else if (state.active >= count.value) {\n move({\n pace: -count.value\n });\n }\n }; // swipe to prev item\n\n\n var prev = () => {\n correctPosition();\n touch.reset();\n doubleRaf(() => {\n state.swiping = false;\n move({\n pace: -1,\n emitChange: true\n });\n });\n }; // swipe to next item\n\n\n var next = () => {\n correctPosition();\n touch.reset();\n doubleRaf(() => {\n state.swiping = false;\n move({\n pace: 1,\n emitChange: true\n });\n });\n };\n\n var autoplayTimer;\n\n var stopAutoplay = () => clearTimeout(autoplayTimer);\n\n var autoplay = () => {\n stopAutoplay();\n\n if (props.autoplay > 0 && count.value > 1) {\n autoplayTimer = setTimeout(() => {\n next();\n autoplay();\n }, +props.autoplay);\n }\n }; // initialize swipe position\n\n\n var initialize = function (active) {\n if (active === void 0) {\n active = +props.initialSwipe;\n }\n\n if (!root.value) {\n return;\n }\n\n if (!isHidden(root)) {\n var _props$width, _props$height;\n\n var rect = {\n width: root.value.offsetWidth,\n height: root.value.offsetHeight\n };\n state.rect = rect;\n state.width = +((_props$width = props.width) != null ? _props$width : rect.width);\n state.height = +((_props$height = props.height) != null ? _props$height : rect.height);\n }\n\n if (count.value) {\n active = Math.min(count.value - 1, active);\n }\n\n state.active = active;\n state.swiping = true;\n state.offset = getTargetOffset(active);\n children.forEach(swipe => {\n swipe.setOffset(0);\n });\n autoplay();\n };\n\n var resize = () => initialize(state.active);\n\n var touchStartTime;\n\n var onTouchStart = event => {\n if (!props.touchable) return;\n touch.start(event);\n touchStartTime = Date.now();\n stopAutoplay();\n correctPosition();\n };\n\n var onTouchMove = event => {\n if (props.touchable && state.swiping) {\n touch.move(event); // if user starting to touchmove, prevent the event bubbling to\n // avoid affecting the parent components\n\n var shouldPrevent = isCorrectDirection.value || touch.offsetY.value > touch.offsetX.value === props.vertical;\n\n if (shouldPrevent) {\n preventDefault(event, props.stopPropagation);\n }\n\n if (isCorrectDirection.value) {\n move({\n offset: delta.value\n });\n }\n }\n };\n\n var onTouchEnd = () => {\n if (!props.touchable || !state.swiping) {\n return;\n }\n\n var duration = Date.now() - touchStartTime;\n var speed = delta.value / duration;\n var shouldSwipe = Math.abs(speed) > 0.25 || Math.abs(delta.value) > size.value / 2;\n\n if (shouldSwipe && isCorrectDirection.value) {\n var offset = props.vertical ? touch.offsetY.value : touch.offsetX.value;\n var pace = 0;\n\n if (props.loop) {\n pace = offset > 0 ? delta.value > 0 ? -1 : 1 : 0;\n } else {\n pace = -Math[delta.value > 0 ? 'ceil' : 'floor'](delta.value / size.value);\n }\n\n move({\n pace,\n emitChange: true\n });\n } else if (delta.value) {\n move({\n pace: 0\n });\n }\n\n state.swiping = false;\n autoplay();\n };\n\n var swipeTo = function (index, options) {\n if (options === void 0) {\n options = {};\n }\n\n correctPosition();\n touch.reset();\n doubleRaf(() => {\n var targetIndex;\n\n if (props.loop && index === count.value) {\n targetIndex = state.active === 0 ? 0 : index;\n } else {\n targetIndex = index % count.value;\n }\n\n if (options.immediate) {\n doubleRaf(() => {\n state.swiping = false;\n });\n } else {\n state.swiping = false;\n }\n\n move({\n pace: targetIndex - state.active,\n emitChange: true\n });\n });\n };\n\n var renderDot = (_, index) => {\n var active = index === activeIndicator.value;\n var style = active ? {\n backgroundColor: props.indicatorColor\n } : undefined;\n return _createVNode(\"i\", {\n \"style\": style,\n \"class\": bem('indicator', {\n active\n })\n }, null);\n };\n\n var renderIndicator = () => {\n if (slots.indicator) {\n return slots.indicator({\n active: activeIndicator.value\n });\n }\n\n if (props.showIndicators && count.value > 1) {\n return _createVNode(\"div\", {\n \"class\": bem('indicators', {\n vertical: props.vertical\n })\n }, [Array(count.value).fill('').map(renderDot)]);\n }\n };\n\n useExpose({\n prev,\n next,\n state,\n resize,\n swipeTo\n });\n linkChildren({\n size,\n props,\n count,\n activeIndicator\n });\n watch(() => props.initialSwipe, value => initialize(+value));\n watch(count, () => initialize(state.active));\n watch(() => props.autoplay, autoplay);\n watch([windowWidth, windowHeight], resize);\n watch(usePageVisibility(), visible => {\n if (visible === 'visible') {\n autoplay();\n } else {\n stopAutoplay();\n }\n });\n onMounted(initialize);\n onActivated(() => initialize(state.active));\n onPopupReopen(() => initialize(state.active));\n onDeactivated(stopAutoplay);\n onBeforeUnmount(stopAutoplay);\n return () => _createVNode(\"div\", {\n \"ref\": root,\n \"class\": bem()\n }, [_createVNode(\"div\", {\n \"style\": trackStyle.value,\n \"class\": bem('track', {\n vertical: props.vertical\n }),\n \"onTouchstart\": onTouchStart,\n \"onTouchmove\": onTouchMove,\n \"onTouchend\": onTouchEnd,\n \"onTouchcancel\": onTouchEnd\n }, [slots.default == null ? void 0 : slots.default()]), renderIndicator()]);\n }\n\n});","import { withInstall } from '../utils';\nimport _Swipe from './Swipe';\nexport var Swipe = withInstall(_Swipe);\nexport default Swipe;","import { createVNode as _createVNode } from \"vue\";\nimport { computed, nextTick, reactive, onMounted, defineComponent } from 'vue'; // Utils\n\nimport { createNamespace } from '../utils';\nimport { SWIPE_KEY } from '../swipe/Swipe'; // Composables\n\nimport { useParent } from '@vant/use';\nimport { useExpose } from '../composables/use-expose';\nvar [name, bem] = createNamespace('swipe-item');\nexport default defineComponent({\n name,\n\n setup(props, _ref) {\n var {\n slots\n } = _ref;\n var rendered;\n var state = reactive({\n offset: 0,\n inited: false,\n mounted: false\n });\n var {\n parent,\n index\n } = useParent(SWIPE_KEY);\n\n if (!parent) {\n if (process.env.NODE_ENV !== 'production') {\n console.error('[Vant] <SwipeItem> must be a child component of <Swipe>.');\n }\n\n return;\n }\n\n var style = computed(() => {\n var style = {};\n var {\n vertical\n } = parent.props;\n\n if (parent.size.value) {\n style[vertical ? 'height' : 'width'] = parent.size.value + \"px\";\n }\n\n if (state.offset) {\n style.transform = \"translate\" + (vertical ? 'Y' : 'X') + \"(\" + state.offset + \"px)\";\n }\n\n return style;\n });\n var shouldRender = computed(() => {\n var {\n loop,\n lazyRender\n } = parent.props;\n\n if (!lazyRender || rendered) {\n return true;\n } // wait for all item to mount, so we can get the exact count\n\n\n if (!state.mounted) {\n return false;\n }\n\n var active = parent.activeIndicator.value;\n var maxActive = parent.count.value - 1;\n var prevActive = active === 0 && loop ? maxActive : active - 1;\n var nextActive = active === maxActive && loop ? 0 : active + 1;\n rendered = index.value === active || index.value === prevActive || index.value === nextActive;\n return rendered;\n });\n\n var setOffset = offset => {\n state.offset = offset;\n };\n\n onMounted(() => {\n nextTick(() => {\n state.mounted = true;\n });\n });\n useExpose({\n setOffset\n });\n return () => _createVNode(\"div\", {\n \"class\": bem(),\n \"style\": style.value\n }, [shouldRender.value ? slots.default == null ? void 0 : slots.default() : null]);\n }\n\n});","import { withInstall } from '../utils';\nimport _SwipeItem from './SwipeItem';\nexport var SwipeItem = withInstall(_SwipeItem);\nexport default SwipeItem;","import { resolveDirective as _resolveDirective, createVNode as _createVNode } from \"vue\";\nimport { watch, computed, reactive, defineComponent } from 'vue'; // Utils\n\nimport { clamp, numericProp, preventDefault, createNamespace, makeRequiredProp } from '../utils'; // Composables\n\nimport { useTouch } from '../composables/use-touch'; // Components\n\nimport { Image } from '../image';\nimport { Loading } from '../loading';\nimport { SwipeItem } from '../swipe-item';\n\nvar getDistance = touches => Math.sqrt(Math.pow(touches[0].clientX - touches[1].clientX, 2) + Math.pow(touches[0].clientY - touches[1].clientY, 2));\n\nvar bem = createNamespace('image-preview')[1];\nexport default defineComponent({\n props: {\n src: String,\n show: Boolean,\n active: Number,\n minZoom: makeRequiredProp(numericProp),\n maxZoom: makeRequiredProp(numericProp),\n rootWidth: makeRequiredProp(Number),\n rootHeight: makeRequiredProp(Number)\n },\n emits: ['scale', 'close'],\n\n setup(props, _ref) {\n var {\n emit\n } = _ref;\n var state = reactive({\n scale: 1,\n moveX: 0,\n moveY: 0,\n moving: false,\n zooming: false,\n imageRatio: 0,\n displayWidth: 0,\n displayHeight: 0\n });\n var touch = useTouch();\n var vertical = computed(() => {\n var {\n rootWidth,\n rootHeight\n } = props;\n var rootRatio = rootHeight / rootWidth;\n return state.imageRatio > rootRatio;\n });\n var imageStyle = computed(() => {\n var {\n scale,\n moveX,\n moveY,\n moving,\n zooming\n } = state;\n var style = {\n transitionDuration: zooming || moving ? '0s' : '.3s'\n };\n\n if (scale !== 1) {\n var offsetX = moveX / scale;\n var offsetY = moveY / scale;\n style.transform = \"scale(\" + scale + \", \" + scale + \") translate(\" + offsetX + \"px, \" + offsetY + \"px)\";\n }\n\n return style;\n });\n var maxMoveX = computed(() => {\n if (state.imageRatio) {\n var {\n rootWidth,\n rootHeight\n } = props;\n var displayWidth = vertical.value ? rootHeight / state.imageRatio : rootWidth;\n return Math.max(0, (state.scale * displayWidth - rootWidth) / 2);\n }\n\n return 0;\n });\n var maxMoveY = computed(() => {\n if (state.imageRatio) {\n var {\n rootWidth,\n rootHeight\n } = props;\n var displayHeight = vertical.value ? rootHeight : rootWidth * state.imageRatio;\n return Math.max(0, (state.scale * displayHeight - rootHeight) / 2);\n }\n\n return 0;\n });\n\n var setScale = scale => {\n scale = clamp(scale, +props.minZoom, +props.maxZoom);\n\n if (scale !== state.scale) {\n state.scale = scale;\n emit('scale', {\n scale,\n index: props.active\n });\n }\n };\n\n var resetScale = () => {\n setScale(1);\n state.moveX = 0;\n state.moveY = 0;\n };\n\n var toggleScale = () => {\n var scale = state.scale > 1 ? 1 : 2;\n setScale(scale);\n state.moveX = 0;\n state.moveY = 0;\n };\n\n var startMoveX;\n var startMoveY;\n var startScale;\n var startDistance;\n var doubleTapTimer;\n var touchStartTime;\n\n var onTouchStart = event => {\n var {\n touches\n } = event;\n var {\n offsetX\n } = touch;\n touch.start(event);\n startMoveX = state.moveX;\n startMoveY = state.moveY;\n touchStartTime = Date.now();\n state.moving = touches.length === 1 && state.scale !== 1;\n state.zooming = touches.length === 2 && !offsetX.value;\n\n if (state.zooming) {\n startScale = state.scale;\n startDistance = getDistance(event.touches);\n }\n };\n\n var onTouchMove = event => {\n var {\n touches\n } = event;\n touch.move(event);\n\n if (state.moving || state.zooming) {\n preventDefault(event, true);\n }\n\n if (state.moving) {\n var {\n deltaX,\n deltaY\n } = touch;\n var moveX = deltaX.value + startMoveX;\n var moveY = deltaY.value + startMoveY;\n state.moveX = clamp(moveX, -maxMoveX.value, maxMoveX.value);\n state.moveY = clamp(moveY, -maxMoveY.value, maxMoveY.value);\n }\n\n if (state.zooming && touches.length === 2) {\n var distance = getDistance(touches);\n var scale = startScale * distance / startDistance;\n setScale(scale);\n }\n };\n\n var checkTap = () => {\n var {\n offsetX,\n offsetY\n } = touch;\n var deltaTime = Date.now() - touchStartTime;\n var TAP_TIME = 250;\n var TAP_OFFSET = 10;\n\n if (offsetX.value < TAP_OFFSET && offsetY.value < TAP_OFFSET && deltaTime < TAP_TIME) {\n if (doubleTapTimer) {\n clearTimeout(doubleTapTimer);\n doubleTapTimer = null;\n toggleScale();\n } else {\n doubleTapTimer = setTimeout(() => {\n emit('close');\n doubleTapTimer = null;\n }, TAP_TIME);\n }\n }\n };\n\n var onTouchEnd = event => {\n var stopPropagation = false;\n /* istanbul ignore else */\n\n if (state.moving || state.zooming) {\n stopPropagation = true;\n\n if (state.moving && startMoveX === state.moveX && startMoveY === state.moveY) {\n stopPropagation = false;\n }\n\n if (!event.touches.length) {\n if (state.zooming) {\n state.moveX = clamp(state.moveX, -maxMoveX.value, maxMoveX.value);\n state.moveY = clamp(state.moveY, -maxMoveY.value, maxMoveY.value);\n state.zooming = false;\n }\n\n state.moving = false;\n startMoveX = 0;\n startMoveY = 0;\n startScale = 1;\n\n if (state.scale < 1) {\n resetScale();\n }\n }\n } // eliminate tap delay on safari\n\n\n preventDefault(event, stopPropagation);\n checkTap();\n touch.reset();\n };\n\n var onLoad = event => {\n var {\n naturalWidth,\n naturalHeight\n } = event.target;\n state.imageRatio = naturalHeight / naturalWidth;\n };\n\n watch(() => props.active, resetScale);\n watch(() => props.show, value => {\n if (!value) {\n resetScale();\n }\n });\n return () => {\n var imageSlots = {\n loading: () => _createVNode(Loading, {\n \"type\": \"spinner\"\n }, null)\n };\n return _createVNode(SwipeItem, {\n \"class\": bem('swipe-item'),\n \"onTouchstart\": onTouchStart,\n \"onTouchmove\": onTouchMove,\n \"onTouchend\": onTouchEnd,\n \"onTouchcancel\": onTouchEnd\n }, {\n default: () => [_createVNode(Image, {\n \"src\": props.src,\n \"fit\": \"contain\",\n \"class\": bem('image', {\n vertical: vertical.value\n }),\n \"style\": imageStyle.value,\n \"onLoad\": onLoad\n }, imageSlots)]\n });\n };\n }\n\n});","import { mergeProps as _mergeProps, createVNode as _createVNode } from \"vue\";\nimport { ref, watch, nextTick, reactive, onMounted, defineComponent } from 'vue'; // Utils\n\nimport { pick, truthProp, unknownProp, windowWidth, windowHeight, makeArrayProp, makeStringProp, makeNumericProp, callInterceptor, createNamespace, HAPTICS_FEEDBACK } from '../utils'; // Composables\n\nimport { useRect } from '@vant/use';\nimport { useExpose } from '../composables/use-expose'; // Components\n\nimport { Icon } from '../icon';\nimport { Swipe } from '../swipe';\nimport { Popup } from '../popup';\nimport ImagePreviewItem from './ImagePreviewItem'; // Types\n\nvar [name, bem] = createNamespace('image-preview');\nvar popupProps = ['show', 'transition', 'overlayStyle', 'closeOnPopstate'];\nvar imagePreviewProps = {\n show: Boolean,\n loop: truthProp,\n images: makeArrayProp(),\n minZoom: makeNumericProp(1 / 3),\n maxZoom: makeNumericProp(3),\n overlay: truthProp,\n closeable: Boolean,\n showIndex: truthProp,\n className: unknownProp,\n closeIcon: makeStringProp('clear'),\n transition: String,\n beforeClose: Function,\n overlayStyle: Object,\n swipeDuration: makeNumericProp(300),\n startPosition: makeNumericProp(0),\n showIndicators: Boolean,\n closeOnPopstate: truthProp,\n closeIconPosition: makeStringProp('top-right')\n};\nexport default defineComponent({\n name,\n props: imagePreviewProps,\n emits: ['scale', 'close', 'closed', 'change', 'update:show'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var swipeRef = ref();\n var state = reactive({\n active: 0,\n rootWidth: 0,\n rootHeight: 0\n });\n\n var resize = () => {\n if (swipeRef.value) {\n var rect = useRect(swipeRef.value.$el);\n state.rootWidth = rect.width;\n state.rootHeight = rect.height;\n swipeRef.value.resize();\n }\n };\n\n var emitScale = args => emit('scale', args);\n\n var updateShow = show => emit('update:show', show);\n\n var emitClose = () => {\n callInterceptor(props.beforeClose, {\n args: [state.active],\n done: () => updateShow(false)\n });\n };\n\n var setActive = active => {\n if (active !== state.active) {\n state.active = active;\n emit('change', active);\n }\n };\n\n var renderIndex = () => {\n if (props.showIndex) {\n return _createVNode(\"div\", {\n \"class\": bem('index')\n }, [slots.index ? slots.index({\n index: state.active\n }) : state.active + 1 + \" / \" + props.images.length]);\n }\n };\n\n var renderCover = () => {\n if (slots.cover) {\n return _createVNode(\"div\", {\n \"class\": bem('cover')\n }, [slots.cover()]);\n }\n };\n\n var renderImages = () => _createVNode(Swipe, {\n \"ref\": swipeRef,\n \"lazyRender\": true,\n \"loop\": props.loop,\n \"class\": bem('swipe'),\n \"duration\": props.swipeDuration,\n \"initialSwipe\": props.startPosition,\n \"showIndicators\": props.showIndicators,\n \"indicatorColor\": \"white\",\n \"onChange\": setActive\n }, {\n default: () => [props.images.map(image => _createVNode(ImagePreviewItem, {\n \"src\": image,\n \"show\": props.show,\n \"active\": state.active,\n \"maxZoom\": props.maxZoom,\n \"minZoom\": props.minZoom,\n \"rootWidth\": state.rootWidth,\n \"rootHeight\": state.rootHeight,\n \"onScale\": emitScale,\n \"onClose\": emitClose\n }, null))]\n });\n\n var renderClose = () => {\n if (props.closeable) {\n return _createVNode(Icon, {\n \"role\": \"button\",\n \"name\": props.closeIcon,\n \"class\": [bem('close-icon', props.closeIconPosition), HAPTICS_FEEDBACK],\n \"onClick\": emitClose\n }, null);\n }\n };\n\n var onClosed = () => emit('closed');\n\n var swipeTo = (index, options) => {\n var _swipeRef$value;\n\n return (_swipeRef$value = swipeRef.value) == null ? void 0 : _swipeRef$value.swipeTo(index, options);\n };\n\n useExpose({\n swipeTo\n });\n onMounted(resize);\n watch([windowWidth, windowHeight], resize);\n watch(() => props.startPosition, value => setActive(+value));\n watch(() => props.show, value => {\n var {\n images,\n startPosition\n } = props;\n\n if (value) {\n setActive(+startPosition);\n nextTick(() => {\n resize();\n swipeTo(+startPosition, {\n immediate: true\n });\n });\n } else {\n emit('close', {\n index: state.active,\n url: images[state.active]\n });\n }\n });\n return () => _createVNode(Popup, _mergeProps({\n \"class\": [bem(), props.className],\n \"overlayClass\": bem('overlay'),\n \"onClosed\": onClosed,\n \"onUpdate:show\": updateShow\n }, pick(props, popupProps)), {\n default: () => [renderClose(), renderImages(), renderIndex(), renderCover()]\n });\n }\n\n});","var anObject = require('../internals/an-object');\nvar aConstructor = require('../internals/a-constructor');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar SPECIES = wellKnownSymbol('species');\n\n// `SpeciesConstructor` abstract operation\n// https://tc39.es/ecma262/#sec-speciesconstructor\nmodule.exports = function (O, defaultConstructor) {\n var C = anObject(O).constructor;\n var S;\n return C === undefined || (S = anObject(C)[SPECIES]) == undefined ? defaultConstructor : aConstructor(S);\n};\n","var global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\n\nvar TypeError = global.TypeError;\n\n// `OrdinaryToPrimitive` abstract operation\n// https://tc39.es/ecma262/#sec-ordinarytoprimitive\nmodule.exports = function (input, pref) {\n var fn, val;\n if (pref === 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;\n if (isCallable(fn = input.valueOf) && !isObject(val = call(fn, input))) return val;\n if (pref !== 'string' && isCallable(fn = input.toString) && !isObject(val = call(fn, input))) return val;\n throw TypeError(\"Can't convert object to primitive value\");\n};\n","/* eslint-disable es/no-symbol -- required for testing */\nvar V8_VERSION = require('../internals/engine-v8-version');\nvar fails = require('../internals/fails');\n\n// eslint-disable-next-line es/no-object-getownpropertysymbols -- required for testing\nmodule.exports = !!Object.getOwnPropertySymbols && !fails(function () {\n var symbol = Symbol();\n // Chrome 38 Symbol has incorrect toString conversion\n // `get-own-property-symbols` polyfill symbols converted to object are not Symbol instances\n return !String(symbol) || !(Object(symbol) instanceof Symbol) ||\n // Chrome 38-40 symbols are not inherited from DOM collections prototypes to instances\n !Symbol.sham && V8_VERSION && V8_VERSION < 41;\n});\n","import { useRect, useWindowSize } from '@vant/use';\nimport { unref } from 'vue';\nimport { isIOS as checkIsIOS } from './validate';\nexport function getScrollTop(el) {\n var top = 'scrollTop' in el ? el.scrollTop : el.pageYOffset; // iOS scroll bounce cause minus scrollTop\n\n return Math.max(top, 0);\n}\nexport function setScrollTop(el, value) {\n if ('scrollTop' in el) {\n el.scrollTop = value;\n } else {\n el.scrollTo(el.scrollX, value);\n }\n}\nexport function getRootScrollTop() {\n return window.pageYOffset || document.documentElement.scrollTop || document.body.scrollTop || 0;\n}\nexport function setRootScrollTop(value) {\n setScrollTop(window, value);\n setScrollTop(document.body, value);\n} // get distance from element top to page top or scroller top\n\nexport function getElementTop(el, scroller) {\n if (el === window) {\n return 0;\n }\n\n var scrollTop = scroller ? getScrollTop(scroller) : getRootScrollTop();\n return useRect(el).top + scrollTop;\n}\nvar isIOS = checkIsIOS(); // hack for iOS12 page scroll\n// see: https://developers.weixin.qq.com/community/develop/doc/00044ae90742f8c82fb78fcae56800\n\nexport function resetScroll() {\n if (isIOS) {\n setRootScrollTop(getRootScrollTop());\n }\n}\nexport var stopPropagation = event => event.stopPropagation();\nexport function preventDefault(event, isStopPropagation) {\n /* istanbul ignore else */\n if (typeof event.cancelable !== 'boolean' || event.cancelable) {\n event.preventDefault();\n }\n\n if (isStopPropagation) {\n stopPropagation(event);\n }\n}\nexport function isHidden(elementRef) {\n var el = unref(elementRef);\n\n if (!el) {\n return false;\n }\n\n var style = window.getComputedStyle(el);\n var hidden = style.display === 'none'; // offsetParent returns null in the following situations:\n // 1. The element or its parent element has the display property set to none.\n // 2. The element has the position property set to fixed\n\n var parentHidden = el.offsetParent === null && style.position !== 'fixed';\n return hidden || parentHidden;\n}\nexport var {\n width: windowWidth,\n height: windowHeight\n} = useWindowSize();","import '../../style/base.css';\nimport '../index.css';","var toIndexedObject = require('../internals/to-indexed-object');\nvar toAbsoluteIndex = require('../internals/to-absolute-index');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\n\n// `Array.prototype.{ indexOf, includes }` methods implementation\nvar createMethod = function (IS_INCLUDES) {\n return function ($this, el, fromIndex) {\n var O = toIndexedObject($this);\n var length = lengthOfArrayLike(O);\n var index = toAbsoluteIndex(fromIndex, length);\n var value;\n // Array#includes uses SameValueZero equality algorithm\n // eslint-disable-next-line no-self-compare -- NaN check\n if (IS_INCLUDES && el != el) while (length > index) {\n value = O[index++];\n // eslint-disable-next-line no-self-compare -- NaN check\n if (value != value) return true;\n // Array#indexOf ignores holes, Array#includes - not\n } else for (;length > index; index++) {\n if ((IS_INCLUDES || index in O) && O[index] === el) return IS_INCLUDES || index || 0;\n } return !IS_INCLUDES && -1;\n };\n};\n\nmodule.exports = {\n // `Array.prototype.includes` method\n // https://tc39.es/ecma262/#sec-array.prototype.includes\n includes: createMethod(true),\n // `Array.prototype.indexOf` method\n // https://tc39.es/ecma262/#sec-array.prototype.indexof\n indexOf: createMethod(false)\n};\n","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../../icon/index.css';\nimport '../../radio-group/index.css';\nimport '../../checkbox/index.css';\nimport '../index.css';","import { getCurrentInstance } from 'vue';\nimport { extend } from '../utils'; // expose public api\n\nexport function useExpose(apis) {\n var instance = getCurrentInstance();\n\n if (instance) {\n extend(instance.proxy, apis);\n }\n}","var global = require('../internals/global');\nvar isConstructor = require('../internals/is-constructor');\nvar tryToString = require('../internals/try-to-string');\n\nvar TypeError = global.TypeError;\n\n// `Assert: IsConstructor(argument) is true`\nmodule.exports = function (argument) {\n if (isConstructor(argument)) return argument;\n throw TypeError(tryToString(argument) + ' is not a constructor');\n};\n","var toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\n\nvar min = Math.min;\n\n// `ToLength` abstract operation\n// https://tc39.es/ecma262/#sec-tolength\nmodule.exports = function (argument) {\n return argument > 0 ? min(toIntegerOrInfinity(argument), 0x1FFFFFFFFFFFFF) : 0; // 2 ** 53 - 1 == 9007199254740991\n};\n","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../../icon/index.css';\nimport '../index.css';","'use strict';\nvar apply = require('../internals/function-apply');\nvar call = require('../internals/function-call');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fixRegExpWellKnownSymbolLogic = require('../internals/fix-regexp-well-known-symbol-logic');\nvar fails = require('../internals/fails');\nvar anObject = require('../internals/an-object');\nvar isCallable = require('../internals/is-callable');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar toLength = require('../internals/to-length');\nvar toString = require('../internals/to-string');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\nvar advanceStringIndex = require('../internals/advance-string-index');\nvar getMethod = require('../internals/get-method');\nvar getSubstitution = require('../internals/get-substitution');\nvar regExpExec = require('../internals/regexp-exec-abstract');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar REPLACE = wellKnownSymbol('replace');\nvar max = Math.max;\nvar min = Math.min;\nvar concat = uncurryThis([].concat);\nvar push = uncurryThis([].push);\nvar stringIndexOf = uncurryThis(''.indexOf);\nvar stringSlice = uncurryThis(''.slice);\n\nvar maybeToString = function (it) {\n return it === undefined ? it : String(it);\n};\n\n// IE <= 11 replaces $0 with the whole match, as if it was $&\n// https://stackoverflow.com/questions/6024666/getting-ie-to-replace-a-regex-with-the-literal-string-0\nvar REPLACE_KEEPS_$0 = (function () {\n // eslint-disable-next-line regexp/prefer-escape-replacement-dollar-char -- required for testing\n return 'a'.replace(/./, '$0') === '$0';\n})();\n\n// Safari <= 13.0.3(?) substitutes nth capture where n>m with an empty string\nvar REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE = (function () {\n if (/./[REPLACE]) {\n return /./[REPLACE]('a', '$0') === '';\n }\n return false;\n})();\n\nvar REPLACE_SUPPORTS_NAMED_GROUPS = !fails(function () {\n var re = /./;\n re.exec = function () {\n var result = [];\n result.groups = { a: '7' };\n return result;\n };\n // eslint-disable-next-line regexp/no-useless-dollar-replacements -- false positive\n return ''.replace(re, '$<a>') !== '7';\n});\n\n// @@replace logic\nfixRegExpWellKnownSymbolLogic('replace', function (_, nativeReplace, maybeCallNative) {\n var UNSAFE_SUBSTITUTE = REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE ? '$' : '$0';\n\n return [\n // `String.prototype.replace` method\n // https://tc39.es/ecma262/#sec-string.prototype.replace\n function replace(searchValue, replaceValue) {\n var O = requireObjectCoercible(this);\n var replacer = searchValue == undefined ? undefined : getMethod(searchValue, REPLACE);\n return replacer\n ? call(replacer, searchValue, O, replaceValue)\n : call(nativeReplace, toString(O), searchValue, replaceValue);\n },\n // `RegExp.prototype[@@replace]` method\n // https://tc39.es/ecma262/#sec-regexp.prototype-@@replace\n function (string, replaceValue) {\n var rx = anObject(this);\n var S = toString(string);\n\n if (\n typeof replaceValue == 'string' &&\n stringIndexOf(replaceValue, UNSAFE_SUBSTITUTE) === -1 &&\n stringIndexOf(replaceValue, '$<') === -1\n ) {\n var res = maybeCallNative(nativeReplace, rx, S, replaceValue);\n if (res.done) return res.value;\n }\n\n var functionalReplace = isCallable(replaceValue);\n if (!functionalReplace) replaceValue = toString(replaceValue);\n\n var global = rx.global;\n if (global) {\n var fullUnicode = rx.unicode;\n rx.lastIndex = 0;\n }\n var results = [];\n while (true) {\n var result = regExpExec(rx, S);\n if (result === null) break;\n\n push(results, result);\n if (!global) break;\n\n var matchStr = toString(result[0]);\n if (matchStr === '') rx.lastIndex = advanceStringIndex(S, toLength(rx.lastIndex), fullUnicode);\n }\n\n var accumulatedResult = '';\n var nextSourcePosition = 0;\n for (var i = 0; i < results.length; i++) {\n result = results[i];\n\n var matched = toString(result[0]);\n var position = max(min(toIntegerOrInfinity(result.index), S.length), 0);\n var captures = [];\n // NOTE: This is equivalent to\n // captures = result.slice(1).map(maybeToString)\n // but for some reason `nativeSlice.call(result, 1, result.length)` (called in\n // the slice polyfill when slicing native arrays) \"doesn't work\" in safari 9 and\n // causes a crash (https://pastebin.com/N21QzeQA) when trying to debug it.\n for (var j = 1; j < result.length; j++) push(captures, maybeToString(result[j]));\n var namedCaptures = result.groups;\n if (functionalReplace) {\n var replacerArgs = concat([matched], captures, position, S);\n if (namedCaptures !== undefined) push(replacerArgs, namedCaptures);\n var replacement = toString(apply(replaceValue, undefined, replacerArgs));\n } else {\n replacement = getSubstitution(matched, S, position, captures, namedCaptures, replaceValue);\n }\n if (position >= nextSourcePosition) {\n accumulatedResult += stringSlice(S, nextSourcePosition, position) + replacement;\n nextSourcePosition = position + matched.length;\n }\n }\n return accumulatedResult + stringSlice(S, nextSourcePosition);\n }\n ];\n}, !REPLACE_SUPPORTS_NAMED_GROUPS || !REPLACE_KEEPS_$0 || REGEXP_REPLACE_SUBSTITUTES_UNDEFINED_CAPTURE);\n","import { createVNode as _createVNode } from \"vue\";\nimport { computed, defineComponent } from 'vue';\nimport { extend, addUnit, numericProp, getSizeStyle, makeStringProp, createNamespace } from '../utils';\nvar [name, bem] = createNamespace('loading');\nvar SpinIcon = Array(12).fill(null).map((_, index) => _createVNode(\"i\", {\n \"class\": bem('line', String(index + 1))\n}, null));\n\nvar CircularIcon = _createVNode(\"svg\", {\n \"class\": bem('circular'),\n \"viewBox\": \"25 25 50 50\"\n}, [_createVNode(\"circle\", {\n \"cx\": \"50\",\n \"cy\": \"50\",\n \"r\": \"20\",\n \"fill\": \"none\"\n}, null)]);\n\nvar loadingProps = {\n size: numericProp,\n type: makeStringProp('circular'),\n color: String,\n vertical: Boolean,\n textSize: numericProp,\n textColor: String\n};\nexport default defineComponent({\n name,\n props: loadingProps,\n\n setup(props, _ref) {\n var {\n slots\n } = _ref;\n var spinnerStyle = computed(() => extend({\n color: props.color\n }, getSizeStyle(props.size)));\n\n var renderText = () => {\n if (slots.default) {\n var _props$textColor;\n\n return _createVNode(\"span\", {\n \"class\": bem('text'),\n \"style\": {\n fontSize: addUnit(props.textSize),\n color: (_props$textColor = props.textColor) != null ? _props$textColor : props.color\n }\n }, [slots.default()]);\n }\n };\n\n return () => {\n var {\n type,\n vertical\n } = props;\n return _createVNode(\"div\", {\n \"class\": bem([type, {\n vertical\n }])\n }, [_createVNode(\"span\", {\n \"class\": bem('spinner', type),\n \"style\": spinnerStyle.value\n }, [type === 'spinner' ? SpinIcon : CircularIcon]), renderText()]);\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _Loading from './Loading';\nexport var Loading = withInstall(_Loading);\nexport default Loading;","import { createVNode as _createVNode } from \"vue\";\nimport { watch, defineComponent } from 'vue';\nimport { unknownProp, numericProp, createNamespace } from '../utils';\nimport { useChildren, useCustomFieldValue } from '@vant/use';\nvar [name, bem] = createNamespace('radio-group');\nvar radioGroupProps = {\n disabled: Boolean,\n iconSize: numericProp,\n direction: String,\n modelValue: unknownProp,\n checkedColor: String\n};\nexport var RADIO_KEY = Symbol(name);\nexport default defineComponent({\n name,\n props: radioGroupProps,\n emits: ['change', 'update:modelValue'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var {\n linkChildren\n } = useChildren(RADIO_KEY);\n\n var updateValue = value => emit('update:modelValue', value);\n\n watch(() => props.modelValue, value => emit('change', value));\n linkChildren({\n props,\n updateValue\n });\n useCustomFieldValue(() => props.modelValue);\n return () => _createVNode(\"div\", {\n \"class\": bem([props.direction]),\n \"role\": \"radiogroup\"\n }, [slots.default == null ? void 0 : slots.default()]);\n }\n\n});","import { isObject, isPromise, isFunction, getRootScrollTop, setRootScrollTop } from '../utils';\n\nfunction isEmptyValue(value) {\n if (Array.isArray(value)) {\n return !value.length;\n }\n\n if (value === 0) {\n return false;\n }\n\n return !value;\n}\n\nexport function runSyncRule(value, rule) {\n if (rule.required && isEmptyValue(value)) {\n return false;\n }\n\n if (rule.pattern && !rule.pattern.test(String(value))) {\n return false;\n }\n\n return true;\n}\nexport function runRuleValidator(value, rule) {\n return new Promise(resolve => {\n var returnVal = rule.validator(value, rule);\n\n if (isPromise(returnVal)) {\n return returnVal.then(resolve);\n }\n\n resolve(returnVal);\n });\n}\nexport function getRuleMessage(value, rule) {\n var {\n message\n } = rule;\n\n if (isFunction(message)) {\n return message(value, rule);\n }\n\n return message || '';\n}\nexport function startComposing(_ref) {\n var {\n target\n } = _ref;\n target.composing = true;\n}\nexport function endComposing(_ref2) {\n var {\n target\n } = _ref2;\n\n if (target.composing) {\n target.composing = false;\n target.dispatchEvent(new Event('input'));\n }\n}\nexport function resizeTextarea(input, autosize) {\n var scrollTop = getRootScrollTop();\n input.style.height = 'auto';\n var height = input.scrollHeight;\n\n if (isObject(autosize)) {\n var {\n maxHeight,\n minHeight\n } = autosize;\n\n if (maxHeight !== undefined) {\n height = Math.min(height, maxHeight);\n }\n\n if (minHeight !== undefined) {\n height = Math.max(height, minHeight);\n }\n }\n\n if (height) {\n input.style.height = height + \"px\"; // https://github.com/youzan/vant/issues/9178\n\n setRootScrollTop(scrollTop);\n }\n}\nexport function mapInputType(type) {\n // type=\"number\" is weird in iOS, and can't prevent dot in Android\n // so use inputmode to set keyboard in modern browsers\n if (type === 'number') {\n return {\n type: 'text',\n inputmode: 'decimal'\n };\n }\n\n if (type === 'digit') {\n return {\n type: 'tel',\n inputmode: 'numeric'\n };\n }\n\n return {\n type\n };\n}","import { getCurrentInstance } from 'vue';\nvar current = 0;\nexport function useId() {\n var vm = getCurrentInstance();\n var {\n name = 'unknown'\n } = (vm == null ? void 0 : vm.type) || {}; // keep jest snapshot stable\n\n if (process.env.NODE_ENV === 'test') {\n return name;\n }\n\n return name + \"-\" + ++current;\n}","import { resolveDirective as _resolveDirective, createTextVNode as _createTextVNode, mergeProps as _mergeProps, createVNode as _createVNode } from \"vue\";\nimport { ref, watch, provide, computed, nextTick, reactive, onMounted, defineComponent } from 'vue'; // Utils\n\nimport { isDef, extend, addUnit, FORM_KEY, numericProp, unknownProp, resetScroll, formatNumber, preventDefault, makeStringProp, makeNumericProp, createNamespace } from '../utils';\nimport { runSyncRule, endComposing, mapInputType, startComposing, getRuleMessage, resizeTextarea, runRuleValidator } from './utils';\nimport { cellSharedProps } from '../cell/Cell'; // Composables\n\nimport { CUSTOM_FIELD_INJECTION_KEY, useParent } from '@vant/use';\nimport { useId } from '../composables/use-id';\nimport { useExpose } from '../composables/use-expose'; // Components\n\nimport { Icon } from '../icon';\nimport { Cell } from '../cell'; // Types\n\nvar [name, bem] = createNamespace('field'); // provide to Search component to inherit\n\nexport var fieldSharedProps = {\n id: String,\n name: String,\n leftIcon: String,\n rightIcon: String,\n autofocus: Boolean,\n clearable: Boolean,\n maxlength: numericProp,\n formatter: Function,\n clearIcon: makeStringProp('clear'),\n modelValue: makeNumericProp(''),\n inputAlign: String,\n placeholder: String,\n autocomplete: String,\n errorMessage: String,\n clearTrigger: makeStringProp('focus'),\n formatTrigger: makeStringProp('onChange'),\n error: {\n type: Boolean,\n default: null\n },\n disabled: {\n type: Boolean,\n default: null\n },\n readonly: {\n type: Boolean,\n default: null\n }\n};\nvar fieldProps = extend({}, cellSharedProps, fieldSharedProps, {\n rows: numericProp,\n type: makeStringProp('text'),\n rules: Array,\n autosize: [Boolean, Object],\n labelWidth: numericProp,\n labelClass: unknownProp,\n labelAlign: String,\n showWordLimit: Boolean,\n errorMessageAlign: String,\n colon: {\n type: Boolean,\n default: null\n }\n});\nexport default defineComponent({\n name,\n props: fieldProps,\n emits: ['blur', 'focus', 'clear', 'keypress', 'click-input', 'click-left-icon', 'click-right-icon', 'update:modelValue'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var id = useId();\n var state = reactive({\n focused: false,\n validateFailed: false,\n validateMessage: ''\n });\n var inputRef = ref();\n var customValue = ref();\n var {\n parent: form\n } = useParent(FORM_KEY);\n\n var getModelValue = () => {\n var _props$modelValue;\n\n return String((_props$modelValue = props.modelValue) != null ? _props$modelValue : '');\n };\n\n var getProp = key => {\n if (isDef(props[key])) {\n return props[key];\n }\n\n if (form && isDef(form.props[key])) {\n return form.props[key];\n }\n };\n\n var showClear = computed(() => {\n var readonly = getProp('readonly');\n\n if (props.clearable && !readonly) {\n var hasValue = getModelValue() !== '';\n var trigger = props.clearTrigger === 'always' || props.clearTrigger === 'focus' && state.focused;\n return hasValue && trigger;\n }\n\n return false;\n });\n var formValue = computed(() => {\n if (customValue.value && slots.input) {\n return customValue.value();\n }\n\n return props.modelValue;\n });\n\n var runRules = rules => rules.reduce((promise, rule) => promise.then(() => {\n if (state.validateFailed) {\n return;\n }\n\n var {\n value\n } = formValue;\n\n if (rule.formatter) {\n value = rule.formatter(value, rule);\n }\n\n if (!runSyncRule(value, rule)) {\n state.validateFailed = true;\n state.validateMessage = getRuleMessage(value, rule);\n return;\n }\n\n if (rule.validator) {\n return runRuleValidator(value, rule).then(result => {\n if (result && typeof result === 'string') {\n state.validateFailed = true;\n state.validateMessage = result;\n } else if (result === false) {\n state.validateFailed = true;\n state.validateMessage = getRuleMessage(value, rule);\n }\n });\n }\n }), Promise.resolve());\n\n var resetValidation = () => {\n if (state.validateFailed) {\n state.validateFailed = false;\n state.validateMessage = '';\n }\n };\n\n var validate = function (rules) {\n if (rules === void 0) {\n rules = props.rules;\n }\n\n return new Promise(resolve => {\n resetValidation();\n\n if (rules) {\n runRules(rules).then(() => {\n if (state.validateFailed) {\n resolve({\n name: props.name,\n message: state.validateMessage\n });\n } else {\n resolve();\n }\n });\n } else {\n resolve();\n }\n });\n };\n\n var validateWithTrigger = trigger => {\n if (form && props.rules) {\n var defaultTrigger = form.props.validateTrigger === trigger;\n var rules = props.rules.filter(rule => {\n if (rule.trigger) {\n return rule.trigger === trigger;\n }\n\n return defaultTrigger;\n });\n\n if (rules.length) {\n validate(rules);\n }\n }\n }; // native maxlength have incorrect line-break counting\n // see: https://github.com/youzan/vant/issues/5033\n\n\n var limitValueLength = value => {\n var {\n maxlength\n } = props;\n\n if (isDef(maxlength) && value.length > maxlength) {\n var modelValue = getModelValue();\n\n if (modelValue && modelValue.length === +maxlength) {\n return modelValue;\n }\n\n return value.slice(0, +maxlength);\n }\n\n return value;\n };\n\n var updateValue = function (value, trigger) {\n if (trigger === void 0) {\n trigger = 'onChange';\n }\n\n value = limitValueLength(value);\n\n if (props.type === 'number' || props.type === 'digit') {\n var isNumber = props.type === 'number';\n value = formatNumber(value, isNumber, isNumber);\n }\n\n if (props.formatter && trigger === props.formatTrigger) {\n value = props.formatter(value);\n }\n\n if (inputRef.value && inputRef.value.value !== value) {\n inputRef.value.value = value;\n }\n\n if (value !== props.modelValue) {\n emit('update:modelValue', value);\n }\n };\n\n var onInput = event => {\n // skip update value when composing\n if (!event.target.composing) {\n updateValue(event.target.value);\n }\n };\n\n var blur = () => {\n var _inputRef$value;\n\n return (_inputRef$value = inputRef.value) == null ? void 0 : _inputRef$value.blur();\n };\n\n var focus = () => {\n var _inputRef$value2;\n\n return (_inputRef$value2 = inputRef.value) == null ? void 0 : _inputRef$value2.focus();\n };\n\n var adjustTextareaSize = () => {\n var input = inputRef.value;\n\n if (props.type === 'textarea' && props.autosize && input) {\n resizeTextarea(input, props.autosize);\n }\n };\n\n var onFocus = event => {\n state.focused = true;\n emit('focus', event);\n nextTick(adjustTextareaSize); // readonly not work in legacy mobile safari\n\n if (getProp('readonly')) {\n blur();\n }\n };\n\n var onBlur = event => {\n if (getProp('readonly')) {\n return;\n }\n\n state.focused = false;\n updateValue(getModelValue(), 'onBlur');\n emit('blur', event);\n validateWithTrigger('onBlur');\n nextTick(adjustTextareaSize);\n resetScroll();\n };\n\n var onClickInput = event => emit('click-input', event);\n\n var onClickLeftIcon = event => emit('click-left-icon', event);\n\n var onClickRightIcon = event => emit('click-right-icon', event);\n\n var onClear = event => {\n preventDefault(event);\n emit('update:modelValue', '');\n emit('clear', event);\n };\n\n var showError = computed(() => {\n if (typeof props.error === 'boolean') {\n return props.error;\n }\n\n if (form && form.props.showError && state.validateFailed) {\n return true;\n }\n });\n var labelStyle = computed(() => {\n var labelWidth = getProp('labelWidth');\n\n if (labelWidth) {\n return {\n width: addUnit(labelWidth)\n };\n }\n });\n\n var onKeypress = event => {\n var ENTER_CODE = 13;\n\n if (event.keyCode === ENTER_CODE) {\n var submitOnEnter = form && form.props.submitOnEnter;\n\n if (!submitOnEnter && props.type !== 'textarea') {\n preventDefault(event);\n } // trigger blur after click keyboard search button\n\n\n if (props.type === 'search') {\n blur();\n }\n }\n\n emit('keypress', event);\n };\n\n var getInputId = () => props.id || id + \"-input\";\n\n var renderInput = () => {\n var controlClass = bem('control', [getProp('inputAlign'), {\n error: showError.value,\n custom: !!slots.input,\n 'min-height': props.type === 'textarea' && !props.autosize\n }]);\n\n if (slots.input) {\n return _createVNode(\"div\", {\n \"class\": controlClass,\n \"onClick\": onClickInput\n }, [slots.input()]);\n }\n\n var inputAttrs = {\n id: getInputId(),\n ref: inputRef,\n name: props.name,\n rows: props.rows !== undefined ? +props.rows : undefined,\n class: controlClass,\n value: props.modelValue,\n disabled: getProp('disabled'),\n readonly: getProp('readonly'),\n autofocus: props.autofocus,\n placeholder: props.placeholder,\n autocomplete: props.autocomplete,\n 'aria-labelledby': props.label ? id + \"-label\" : undefined,\n onBlur,\n onFocus,\n onInput,\n onClick: onClickInput,\n onChange: endComposing,\n onKeypress,\n onCompositionend: endComposing,\n onCompositionstart: startComposing\n };\n\n if (props.type === 'textarea') {\n return _createVNode(\"textarea\", inputAttrs, null);\n }\n\n return _createVNode(\"input\", _mergeProps(mapInputType(props.type), inputAttrs), null);\n };\n\n var renderLeftIcon = () => {\n var leftIconSlot = slots['left-icon'];\n\n if (props.leftIcon || leftIconSlot) {\n return _createVNode(\"div\", {\n \"class\": bem('left-icon'),\n \"onClick\": onClickLeftIcon\n }, [leftIconSlot ? leftIconSlot() : _createVNode(Icon, {\n \"name\": props.leftIcon,\n \"classPrefix\": props.iconPrefix\n }, null)]);\n }\n };\n\n var renderRightIcon = () => {\n var rightIconSlot = slots['right-icon'];\n\n if (props.rightIcon || rightIconSlot) {\n return _createVNode(\"div\", {\n \"class\": bem('right-icon'),\n \"onClick\": onClickRightIcon\n }, [rightIconSlot ? rightIconSlot() : _createVNode(Icon, {\n \"name\": props.rightIcon,\n \"classPrefix\": props.iconPrefix\n }, null)]);\n }\n };\n\n var renderWordLimit = () => {\n if (props.showWordLimit && props.maxlength) {\n var count = getModelValue().length;\n return _createVNode(\"div\", {\n \"class\": bem('word-limit')\n }, [_createVNode(\"span\", {\n \"class\": bem('word-num')\n }, [count]), _createTextVNode(\"/\"), props.maxlength]);\n }\n };\n\n var renderMessage = () => {\n if (form && form.props.showErrorMessage === false) {\n return;\n }\n\n var message = props.errorMessage || state.validateMessage;\n\n if (message) {\n var slot = slots['error-message'];\n var errorMessageAlign = getProp('errorMessageAlign');\n return _createVNode(\"div\", {\n \"class\": bem('error-message', errorMessageAlign)\n }, [slot ? slot({\n message\n }) : message]);\n }\n };\n\n var renderLabel = () => {\n var colon = getProp('colon') ? ':' : '';\n\n if (slots.label) {\n return [slots.label(), colon];\n }\n\n if (props.label) {\n return _createVNode(\"label\", {\n \"id\": id + \"-label\",\n \"for\": getInputId()\n }, [props.label + colon]);\n }\n };\n\n var renderFieldBody = () => [_createVNode(\"div\", {\n \"class\": bem('body')\n }, [renderInput(), showClear.value && _createVNode(Icon, {\n \"name\": props.clearIcon,\n \"class\": bem('clear'),\n \"onTouchstart\": onClear\n }, null), renderRightIcon(), slots.button && _createVNode(\"div\", {\n \"class\": bem('button')\n }, [slots.button()])]), renderWordLimit(), renderMessage()];\n\n useExpose({\n blur,\n focus,\n validate,\n formValue,\n resetValidation\n });\n provide(CUSTOM_FIELD_INJECTION_KEY, {\n customValue,\n resetValidation,\n validateWithTrigger\n });\n watch(() => props.modelValue, () => {\n updateValue(getModelValue());\n resetValidation();\n validateWithTrigger('onChange');\n nextTick(adjustTextareaSize);\n });\n onMounted(() => {\n updateValue(getModelValue(), props.formatTrigger);\n nextTick(adjustTextareaSize);\n });\n return () => {\n var disabled = getProp('disabled');\n var labelAlign = getProp('labelAlign');\n var Label = renderLabel();\n var LeftIcon = renderLeftIcon();\n return _createVNode(Cell, {\n \"size\": props.size,\n \"icon\": props.leftIcon,\n \"class\": bem({\n error: showError.value,\n disabled,\n [\"label-\" + labelAlign]: labelAlign\n }),\n \"center\": props.center,\n \"border\": props.border,\n \"isLink\": props.isLink,\n \"clickable\": props.clickable,\n \"titleStyle\": labelStyle.value,\n \"valueClass\": bem('value'),\n \"titleClass\": [bem('label', [labelAlign, {\n required: props.required\n }]), props.labelClass],\n \"arrowDirection\": props.arrowDirection\n }, {\n icon: LeftIcon ? () => LeftIcon : null,\n title: Label ? () => Label : null,\n value: renderFieldBody,\n extra: slots.extra\n });\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _Field from './Field';\nexport var Field = withInstall(_Field);\nexport default Field;","var IS_PURE = require('../internals/is-pure');\nvar store = require('../internals/shared-store');\n\n(module.exports = function (key, value) {\n return store[key] || (store[key] = value !== undefined ? value : {});\n})('versions', []).push({\n version: '3.19.2',\n mode: IS_PURE ? 'pure' : 'global',\n copyright: '© 2021 Denis Pushkarev (zloirock.ru)'\n});\n","import { createVNode as _createVNode } from \"vue\";\nimport { computed, defineComponent } from 'vue';\nimport { truthProp, makeStringProp, makeNumericProp, createNamespace } from '../utils';\nimport { useChildren } from '@vant/use';\nvar [name, bem] = createNamespace('row');\nexport var ROW_KEY = Symbol(name);\nvar rowProps = {\n tag: makeStringProp('div'),\n wrap: truthProp,\n align: String,\n gutter: makeNumericProp(0),\n justify: String\n};\nexport default defineComponent({\n name,\n props: rowProps,\n\n setup(props, _ref) {\n var {\n slots\n } = _ref;\n var {\n children,\n linkChildren\n } = useChildren(ROW_KEY);\n var groups = computed(() => {\n var groups = [[]];\n var totalSpan = 0;\n children.forEach((child, index) => {\n totalSpan += Number(child.span);\n\n if (totalSpan > 24) {\n groups.push([index]);\n totalSpan -= 24;\n } else {\n groups[groups.length - 1].push(index);\n }\n });\n return groups;\n });\n var spaces = computed(() => {\n var gutter = Number(props.gutter);\n var spaces = [];\n\n if (!gutter) {\n return spaces;\n }\n\n groups.value.forEach(group => {\n var averagePadding = gutter * (group.length - 1) / group.length;\n group.forEach((item, index) => {\n if (index === 0) {\n spaces.push({\n right: averagePadding\n });\n } else {\n var left = gutter - spaces[item - 1].right;\n var right = averagePadding - left;\n spaces.push({\n left,\n right\n });\n }\n });\n });\n return spaces;\n });\n linkChildren({\n spaces\n });\n return () => {\n var {\n tag,\n wrap,\n align,\n justify\n } = props;\n return _createVNode(tag, {\n \"class\": bem({\n [\"align-\" + align]: align,\n [\"justify-\" + justify]: justify,\n nowrap: !wrap\n })\n }, {\n default: () => [slots.default == null ? void 0 : slots.default()]\n });\n };\n }\n\n});","var getBuiltIn = require('../internals/get-built-in');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar getOwnPropertyNamesModule = require('../internals/object-get-own-property-names');\nvar getOwnPropertySymbolsModule = require('../internals/object-get-own-property-symbols');\nvar anObject = require('../internals/an-object');\n\nvar concat = uncurryThis([].concat);\n\n// all object keys, includes non-enumerable and symbols\nmodule.exports = getBuiltIn('Reflect', 'ownKeys') || function ownKeys(it) {\n var keys = getOwnPropertyNamesModule.f(anObject(it));\n var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;\n return getOwnPropertySymbols ? concat(keys, getOwnPropertySymbols(it)) : keys;\n};\n","var global = require('../internals/global');\nvar classof = require('../internals/classof');\n\nvar String = global.String;\n\nmodule.exports = function (argument) {\n if (classof(argument) === 'Symbol') throw TypeError('Cannot convert a Symbol value to a string');\n return String(argument);\n};\n","import { resolveDirective as _resolveDirective, createVNode as _createVNode } from \"vue\";\nimport { ref, watch, reactive, nextTick, defineComponent } from 'vue'; // Utils\n\nimport { numericProp, getScrollTop, preventDefault, createNamespace, makeNumericProp } from '../utils'; // Composables\n\nimport { useScrollParent } from '@vant/use';\nimport { useTouch } from '../composables/use-touch'; // Components\n\nimport { Loading } from '../loading';\nvar [name, bem, t] = createNamespace('pull-refresh');\nvar DEFAULT_HEAD_HEIGHT = 50;\nvar TEXT_STATUS = ['pulling', 'loosing', 'success'];\nvar pullRefreshProps = {\n disabled: Boolean,\n modelValue: Boolean,\n headHeight: makeNumericProp(DEFAULT_HEAD_HEIGHT),\n successText: String,\n pullingText: String,\n loosingText: String,\n loadingText: String,\n pullDistance: numericProp,\n successDuration: makeNumericProp(500),\n animationDuration: makeNumericProp(300)\n};\nexport default defineComponent({\n name,\n props: pullRefreshProps,\n emits: ['refresh', 'update:modelValue'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var reachTop;\n var root = ref();\n var scrollParent = useScrollParent(root);\n var state = reactive({\n status: 'normal',\n distance: 0,\n duration: 0\n });\n var touch = useTouch();\n\n var getHeadStyle = () => {\n if (props.headHeight !== DEFAULT_HEAD_HEIGHT) {\n return {\n height: props.headHeight + \"px\"\n };\n }\n };\n\n var isTouchable = () => state.status !== 'loading' && state.status !== 'success' && !props.disabled;\n\n var ease = distance => {\n var pullDistance = +(props.pullDistance || props.headHeight);\n\n if (distance > pullDistance) {\n if (distance < pullDistance * 2) {\n distance = pullDistance + (distance - pullDistance) / 2;\n } else {\n distance = pullDistance * 1.5 + (distance - pullDistance * 2) / 4;\n }\n }\n\n return Math.round(distance);\n };\n\n var setStatus = (distance, isLoading) => {\n var pullDistance = +(props.pullDistance || props.headHeight);\n state.distance = distance;\n\n if (isLoading) {\n state.status = 'loading';\n } else if (distance === 0) {\n state.status = 'normal';\n } else if (distance < pullDistance) {\n state.status = 'pulling';\n } else {\n state.status = 'loosing';\n }\n };\n\n var getStatusText = () => {\n var {\n status\n } = state;\n\n if (status === 'normal') {\n return '';\n }\n\n return props[status + \"Text\"] || t(status);\n };\n\n var renderStatus = () => {\n var {\n status,\n distance\n } = state;\n\n if (slots[status]) {\n return slots[status]({\n distance\n });\n }\n\n var nodes = [];\n\n if (TEXT_STATUS.includes(status)) {\n nodes.push(_createVNode(\"div\", {\n \"class\": bem('text')\n }, [getStatusText()]));\n }\n\n if (status === 'loading') {\n nodes.push(_createVNode(Loading, {\n \"class\": bem('loading')\n }, {\n default: getStatusText\n }));\n }\n\n return nodes;\n };\n\n var showSuccessTip = () => {\n state.status = 'success';\n setTimeout(() => {\n setStatus(0);\n }, +props.successDuration);\n };\n\n var checkPosition = event => {\n reachTop = getScrollTop(scrollParent.value) === 0;\n\n if (reachTop) {\n state.duration = 0;\n touch.start(event);\n }\n };\n\n var onTouchStart = event => {\n if (isTouchable()) {\n checkPosition(event);\n }\n };\n\n var onTouchMove = event => {\n if (isTouchable()) {\n if (!reachTop) {\n checkPosition(event);\n }\n\n var {\n deltaY\n } = touch;\n touch.move(event);\n\n if (reachTop && deltaY.value >= 0 && touch.isVertical()) {\n preventDefault(event);\n setStatus(ease(deltaY.value));\n }\n }\n };\n\n var onTouchEnd = () => {\n if (reachTop && touch.deltaY.value && isTouchable()) {\n state.duration = +props.animationDuration;\n\n if (state.status === 'loosing') {\n setStatus(+props.headHeight, true);\n emit('update:modelValue', true); // ensure value change can be watched\n\n nextTick(() => emit('refresh'));\n } else {\n setStatus(0);\n }\n }\n };\n\n watch(() => props.modelValue, value => {\n state.duration = +props.animationDuration;\n\n if (value) {\n setStatus(+props.headHeight, true);\n } else if (slots.success || props.successText) {\n showSuccessTip();\n } else {\n setStatus(0, false);\n }\n });\n return () => {\n var trackStyle = {\n transitionDuration: state.duration + \"ms\",\n transform: state.distance ? \"translate3d(0,\" + state.distance + \"px, 0)\" : ''\n };\n return _createVNode(\"div\", {\n \"ref\": root,\n \"class\": bem()\n }, [_createVNode(\"div\", {\n \"class\": bem('track'),\n \"style\": trackStyle,\n \"onTouchstart\": onTouchStart,\n \"onTouchmove\": onTouchMove,\n \"onTouchend\": onTouchEnd,\n \"onTouchcancel\": onTouchEnd\n }, [_createVNode(\"div\", {\n \"class\": bem('head'),\n \"style\": getHeadStyle()\n }, [renderStatus()]), slots.default == null ? void 0 : slots.default()])]);\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _PullRefresh from './PullRefresh';\nexport var PullRefresh = withInstall(_PullRefresh);\nexport default PullRefresh;","var ceil = Math.ceil;\nvar floor = Math.floor;\n\n// `ToIntegerOrInfinity` abstract operation\n// https://tc39.es/ecma262/#sec-tointegerorinfinity\nmodule.exports = function (argument) {\n var number = +argument;\n // eslint-disable-next-line no-self-compare -- safe\n return number !== number || number === 0 ? 0 : (number > 0 ? floor : ceil)(number);\n};\n","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\nvar tryToString = require('../internals/try-to-string');\n\nvar TypeError = global.TypeError;\n\n// `Assert: IsCallable(argument) is true`\nmodule.exports = function (argument) {\n if (isCallable(argument)) return argument;\n throw TypeError(tryToString(argument) + ' is not a function');\n};\n","module.exports = function (bitmap, value) {\n return {\n enumerable: !(bitmap & 1),\n configurable: !(bitmap & 2),\n writable: !(bitmap & 4),\n value: value\n };\n};\n","var DESCRIPTORS = require('../internals/descriptors');\nvar hasOwn = require('../internals/has-own-property');\n\nvar FunctionPrototype = Function.prototype;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getDescriptor = DESCRIPTORS && Object.getOwnPropertyDescriptor;\n\nvar EXISTS = hasOwn(FunctionPrototype, 'name');\n// additional protection from minified / mangled / dropped function names\nvar PROPER = EXISTS && (function something() { /* empty */ }).name === 'something';\nvar CONFIGURABLE = EXISTS && (!DESCRIPTORS || (DESCRIPTORS && getDescriptor(FunctionPrototype, 'name').configurable));\n\nmodule.exports = {\n EXISTS: EXISTS,\n PROPER: PROPER,\n CONFIGURABLE: CONFIGURABLE\n};\n","import '../../style/base.css';\nimport '../../loading/index.css';\nimport '../index.css';","var classof = require('../internals/classof-raw');\nvar global = require('../internals/global');\n\nmodule.exports = classof(global.process) == 'process';\n","module.exports = typeof window == 'object';\n","'use strict';\nvar DESCRIPTORS = require('../internals/descriptors');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar call = require('../internals/function-call');\nvar fails = require('../internals/fails');\nvar objectKeys = require('../internals/object-keys');\nvar getOwnPropertySymbolsModule = require('../internals/object-get-own-property-symbols');\nvar propertyIsEnumerableModule = require('../internals/object-property-is-enumerable');\nvar toObject = require('../internals/to-object');\nvar IndexedObject = require('../internals/indexed-object');\n\n// eslint-disable-next-line es/no-object-assign -- safe\nvar $assign = Object.assign;\n// eslint-disable-next-line es/no-object-defineproperty -- required for testing\nvar defineProperty = Object.defineProperty;\nvar concat = uncurryThis([].concat);\n\n// `Object.assign` method\n// https://tc39.es/ecma262/#sec-object.assign\nmodule.exports = !$assign || fails(function () {\n // should have correct order of operations (Edge bug)\n if (DESCRIPTORS && $assign({ b: 1 }, $assign(defineProperty({}, 'a', {\n enumerable: true,\n get: function () {\n defineProperty(this, 'b', {\n value: 3,\n enumerable: false\n });\n }\n }), { b: 2 })).b !== 1) return true;\n // should work with symbols and should have deterministic property order (V8 bug)\n var A = {};\n var B = {};\n // eslint-disable-next-line es/no-symbol -- safe\n var symbol = Symbol();\n var alphabet = 'abcdefghijklmnopqrst';\n A[symbol] = 7;\n alphabet.split('').forEach(function (chr) { B[chr] = chr; });\n return $assign({}, A)[symbol] != 7 || objectKeys($assign({}, B)).join('') != alphabet;\n}) ? function assign(target, source) { // eslint-disable-line no-unused-vars -- required for `.length`\n var T = toObject(target);\n var argumentsLength = arguments.length;\n var index = 1;\n var getOwnPropertySymbols = getOwnPropertySymbolsModule.f;\n var propertyIsEnumerable = propertyIsEnumerableModule.f;\n while (argumentsLength > index) {\n var S = IndexedObject(arguments[index++]);\n var keys = getOwnPropertySymbols ? concat(objectKeys(S), getOwnPropertySymbols(S)) : objectKeys(S);\n var length = keys.length;\n var j = 0;\n var key;\n while (length > j) {\n key = keys[j++];\n if (!DESCRIPTORS || call(propertyIsEnumerable, S, key)) T[key] = S[key];\n }\n } return T;\n} : $assign;\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar toIntegerOrInfinity = require('../internals/to-integer-or-infinity');\nvar toString = require('../internals/to-string');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nvar charAt = uncurryThis(''.charAt);\nvar charCodeAt = uncurryThis(''.charCodeAt);\nvar stringSlice = uncurryThis(''.slice);\n\nvar createMethod = function (CONVERT_TO_STRING) {\n return function ($this, pos) {\n var S = toString(requireObjectCoercible($this));\n var position = toIntegerOrInfinity(pos);\n var size = S.length;\n var first, second;\n if (position < 0 || position >= size) return CONVERT_TO_STRING ? '' : undefined;\n first = charCodeAt(S, position);\n return first < 0xD800 || first > 0xDBFF || position + 1 === size\n || (second = charCodeAt(S, position + 1)) < 0xDC00 || second > 0xDFFF\n ? CONVERT_TO_STRING\n ? charAt(S, position)\n : first\n : CONVERT_TO_STRING\n ? stringSlice(S, position, position + 2)\n : (first - 0xD800 << 10) + (second - 0xDC00) + 0x10000;\n };\n};\n\nmodule.exports = {\n // `String.prototype.codePointAt` method\n // https://tc39.es/ecma262/#sec-string.prototype.codepointat\n codeAt: createMethod(false),\n // `String.prototype.at` method\n // https://github.com/mathiasbynens/String.prototype.at\n charAt: createMethod(true)\n};\n","var arraySpeciesConstructor = require('../internals/array-species-constructor');\n\n// `ArraySpeciesCreate` abstract operation\n// https://tc39.es/ecma262/#sec-arrayspeciescreate\nmodule.exports = function (originalArray, length) {\n return new (arraySpeciesConstructor(originalArray))(length === 0 ? 0 : length);\n};\n","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../../icon/index.css';\nimport '../../loading/index.css';\nimport '../index.css';","import { createVNode as _createVNode } from \"vue\";\nimport { defineComponent } from 'vue'; // Utils\n\nimport { isDef, extend, truthProp, unknownProp, numericProp, createNamespace } from '../utils'; // Composables\n\nimport { useRoute, routeProps } from '../composables/use-route'; // Components\n\nimport { Icon } from '../icon';\nvar [name, bem] = createNamespace('cell');\nexport var cellSharedProps = {\n icon: String,\n size: String,\n title: numericProp,\n value: numericProp,\n label: numericProp,\n center: Boolean,\n isLink: Boolean,\n border: truthProp,\n required: Boolean,\n iconPrefix: String,\n valueClass: unknownProp,\n labelClass: unknownProp,\n titleClass: unknownProp,\n titleStyle: null,\n arrowDirection: String,\n clickable: {\n type: Boolean,\n default: null\n }\n};\nvar cellProps = extend({}, cellSharedProps, routeProps);\nexport default defineComponent({\n name,\n props: cellProps,\n\n setup(props, _ref) {\n var {\n slots\n } = _ref;\n var route = useRoute();\n\n var renderLabel = () => {\n var showLabel = slots.label || isDef(props.label);\n\n if (showLabel) {\n return _createVNode(\"div\", {\n \"class\": [bem('label'), props.labelClass]\n }, [slots.label ? slots.label() : props.label]);\n }\n };\n\n var renderTitle = () => {\n if (slots.title || isDef(props.title)) {\n return _createVNode(\"div\", {\n \"class\": [bem('title'), props.titleClass],\n \"style\": props.titleStyle\n }, [slots.title ? slots.title() : _createVNode(\"span\", null, [props.title]), renderLabel()]);\n }\n };\n\n var renderValue = () => {\n // slots.default is an alias of slots.value\n var slot = slots.value || slots.default;\n var hasValue = slot || isDef(props.value);\n\n if (hasValue) {\n var hasTitle = slots.title || isDef(props.title);\n return _createVNode(\"div\", {\n \"class\": [bem('value', {\n alone: !hasTitle\n }), props.valueClass]\n }, [slot ? slot() : _createVNode(\"span\", null, [props.value])]);\n }\n };\n\n var renderLeftIcon = () => {\n if (slots.icon) {\n return slots.icon();\n }\n\n if (props.icon) {\n return _createVNode(Icon, {\n \"name\": props.icon,\n \"class\": bem('left-icon'),\n \"classPrefix\": props.iconPrefix\n }, null);\n }\n };\n\n var renderRightIcon = () => {\n if (slots['right-icon']) {\n return slots['right-icon']();\n }\n\n if (props.isLink) {\n var _name = props.arrowDirection ? \"arrow-\" + props.arrowDirection : 'arrow';\n\n return _createVNode(Icon, {\n \"name\": _name,\n \"class\": bem('right-icon')\n }, null);\n }\n };\n\n return () => {\n var _props$clickable;\n\n var {\n size,\n center,\n border,\n isLink,\n required\n } = props;\n var clickable = (_props$clickable = props.clickable) != null ? _props$clickable : isLink;\n var classes = {\n center,\n required,\n clickable,\n borderless: !border\n };\n\n if (size) {\n classes[size] = !!size;\n }\n\n return _createVNode(\"div\", {\n \"class\": bem(classes),\n \"role\": clickable ? 'button' : undefined,\n \"tabindex\": clickable ? 0 : undefined,\n \"onClick\": route\n }, [renderLeftIcon(), renderTitle(), renderValue(), renderRightIcon(), slots.extra == null ? void 0 : slots.extra()]);\n };\n }\n\n});","var uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\nvar classof = require('../internals/classof');\nvar getBuiltIn = require('../internals/get-built-in');\nvar inspectSource = require('../internals/inspect-source');\n\nvar noop = function () { /* empty */ };\nvar empty = [];\nvar construct = getBuiltIn('Reflect', 'construct');\nvar constructorRegExp = /^\\s*(?:class|function)\\b/;\nvar exec = uncurryThis(constructorRegExp.exec);\nvar INCORRECT_TO_STRING = !constructorRegExp.exec(noop);\n\nvar isConstructorModern = function (argument) {\n if (!isCallable(argument)) return false;\n try {\n construct(noop, empty, argument);\n return true;\n } catch (error) {\n return false;\n }\n};\n\nvar isConstructorLegacy = function (argument) {\n if (!isCallable(argument)) return false;\n switch (classof(argument)) {\n case 'AsyncFunction':\n case 'GeneratorFunction':\n case 'AsyncGeneratorFunction': return false;\n // we can't check .prototype since constructors produced by .bind haven't it\n } return INCORRECT_TO_STRING || !!exec(constructorRegExp, inspectSource(argument));\n};\n\n// `IsConstructor` abstract operation\n// https://tc39.es/ecma262/#sec-isconstructor\nmodule.exports = !construct || fails(function () {\n var called;\n return isConstructorModern(isConstructorModern.call)\n || !isConstructorModern(Object)\n || !isConstructorModern(function () { called = true; })\n || called;\n}) ? isConstructorLegacy : isConstructorModern;\n","var NATIVE_WEAK_MAP = require('../internals/native-weak-map');\nvar global = require('../internals/global');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar isObject = require('../internals/is-object');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar hasOwn = require('../internals/has-own-property');\nvar shared = require('../internals/shared-store');\nvar sharedKey = require('../internals/shared-key');\nvar hiddenKeys = require('../internals/hidden-keys');\n\nvar OBJECT_ALREADY_INITIALIZED = 'Object already initialized';\nvar TypeError = global.TypeError;\nvar WeakMap = global.WeakMap;\nvar set, get, has;\n\nvar enforce = function (it) {\n return has(it) ? get(it) : set(it, {});\n};\n\nvar getterFor = function (TYPE) {\n return function (it) {\n var state;\n if (!isObject(it) || (state = get(it)).type !== TYPE) {\n throw TypeError('Incompatible receiver, ' + TYPE + ' required');\n } return state;\n };\n};\n\nif (NATIVE_WEAK_MAP || shared.state) {\n var store = shared.state || (shared.state = new WeakMap());\n var wmget = uncurryThis(store.get);\n var wmhas = uncurryThis(store.has);\n var wmset = uncurryThis(store.set);\n set = function (it, metadata) {\n if (wmhas(store, it)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);\n metadata.facade = it;\n wmset(store, it, metadata);\n return metadata;\n };\n get = function (it) {\n return wmget(store, it) || {};\n };\n has = function (it) {\n return wmhas(store, it);\n };\n} else {\n var STATE = sharedKey('state');\n hiddenKeys[STATE] = true;\n set = function (it, metadata) {\n if (hasOwn(it, STATE)) throw new TypeError(OBJECT_ALREADY_INITIALIZED);\n metadata.facade = it;\n createNonEnumerableProperty(it, STATE, metadata);\n return metadata;\n };\n get = function (it) {\n return hasOwn(it, STATE) ? it[STATE] : {};\n };\n has = function (it) {\n return hasOwn(it, STATE);\n };\n}\n\nmodule.exports = {\n set: set,\n get: get,\n has: has,\n enforce: enforce,\n getterFor: getterFor\n};\n","import { useRect } from '@vant/use';\nimport { ref, onMounted, nextTick } from 'vue';\nexport var useHeight = element => {\n var height = ref();\n onMounted(() => nextTick(() => {\n height.value = useRect(element).height;\n }));\n return height;\n};","import { createVNode as _createVNode } from \"vue\";\nimport { useHeight } from './use-height';\nexport function usePlaceholder(contentRef, bem) {\n var height = useHeight(contentRef);\n return renderContent => _createVNode(\"div\", {\n \"class\": bem('placeholder'),\n \"style\": {\n height: height.value ? height.value + \"px\" : undefined\n }\n }, [renderContent()]);\n}","import { createVNode as _createVNode } from \"vue\";\nimport { ref, defineComponent } from 'vue'; // Utils\n\nimport { truthProp, numericProp, BORDER_BOTTOM, getZIndexStyle, createNamespace, HAPTICS_FEEDBACK } from '../utils'; // Composables\n\nimport { usePlaceholder } from '../composables/use-placeholder'; // Components\n\nimport { Icon } from '../icon';\nvar [name, bem] = createNamespace('nav-bar');\nvar navBarProps = {\n title: String,\n fixed: Boolean,\n zIndex: numericProp,\n border: truthProp,\n leftText: String,\n rightText: String,\n leftArrow: Boolean,\n placeholder: Boolean,\n safeAreaInsetTop: Boolean\n};\nexport default defineComponent({\n name,\n props: navBarProps,\n emits: ['click-left', 'click-right'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var navBarRef = ref();\n var renderPlaceholder = usePlaceholder(navBarRef, bem);\n\n var onClickLeft = event => emit('click-left', event);\n\n var onClickRight = event => emit('click-right', event);\n\n var renderLeft = () => {\n if (slots.left) {\n return slots.left();\n }\n\n return [props.leftArrow && _createVNode(Icon, {\n \"class\": bem('arrow'),\n \"name\": \"arrow-left\"\n }, null), props.leftText && _createVNode(\"span\", {\n \"class\": bem('text')\n }, [props.leftText])];\n };\n\n var renderRight = () => {\n if (slots.right) {\n return slots.right();\n }\n\n return _createVNode(\"span\", {\n \"class\": bem('text')\n }, [props.rightText]);\n };\n\n var renderNavBar = () => {\n var {\n title,\n fixed,\n border,\n zIndex\n } = props;\n var style = getZIndexStyle(zIndex);\n var hasLeft = props.leftArrow || props.leftText || slots.left;\n var hasRight = props.rightText || slots.right;\n return _createVNode(\"div\", {\n \"ref\": navBarRef,\n \"style\": style,\n \"class\": [bem({\n fixed,\n 'safe-area-inset-top': props.safeAreaInsetTop\n }), {\n [BORDER_BOTTOM]: border\n }]\n }, [_createVNode(\"div\", {\n \"class\": bem('content')\n }, [hasLeft && _createVNode(\"div\", {\n \"class\": [bem('left'), HAPTICS_FEEDBACK],\n \"onClick\": onClickLeft\n }, [renderLeft()]), _createVNode(\"div\", {\n \"class\": [bem('title'), 'van-ellipsis']\n }, [slots.title ? slots.title() : title]), hasRight && _createVNode(\"div\", {\n \"class\": [bem('right'), HAPTICS_FEEDBACK],\n \"onClick\": onClickRight\n }, [renderRight()])])]);\n };\n\n return () => {\n if (props.fixed && props.placeholder) {\n return renderPlaceholder(renderNavBar);\n }\n\n return renderNavBar();\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _NavBar from './NavBar';\nexport var NavBar = withInstall(_NavBar);\nexport default NavBar;","/*!\n * vue-router v4.0.12\n * (c) 2021 Eduardo San Martin Morote\n * @license MIT\n */\nimport { getCurrentInstance, inject, onUnmounted, onDeactivated, onActivated, computed, unref, watchEffect, defineComponent, reactive, h, provide, ref, watch, shallowRef, nextTick } from 'vue';\nimport { setupDevtoolsPlugin } from '@vue/devtools-api';\n\nconst hasSymbol = typeof Symbol === 'function' && typeof Symbol.toStringTag === 'symbol';\r\nconst PolySymbol = (name) => \r\n// vr = vue router\r\nhasSymbol\r\n ? Symbol((process.env.NODE_ENV !== 'production') ? '[vue-router]: ' + name : name)\r\n : ((process.env.NODE_ENV !== 'production') ? '[vue-router]: ' : '_vr_') + name;\r\n// rvlm = Router View Location Matched\r\n/**\r\n * RouteRecord being rendered by the closest ancestor Router View. Used for\r\n * `onBeforeRouteUpdate` and `onBeforeRouteLeave`. rvlm stands for Router View\r\n * Location Matched\r\n *\r\n * @internal\r\n */\r\nconst matchedRouteKey = /*#__PURE__*/ PolySymbol((process.env.NODE_ENV !== 'production') ? 'router view location matched' : 'rvlm');\r\n/**\r\n * Allows overriding the router view depth to control which component in\r\n * `matched` is rendered. rvd stands for Router View Depth\r\n *\r\n * @internal\r\n */\r\nconst viewDepthKey = /*#__PURE__*/ PolySymbol((process.env.NODE_ENV !== 'production') ? 'router view depth' : 'rvd');\r\n/**\r\n * Allows overriding the router instance returned by `useRouter` in tests. r\r\n * stands for router\r\n *\r\n * @internal\r\n */\r\nconst routerKey = /*#__PURE__*/ PolySymbol((process.env.NODE_ENV !== 'production') ? 'router' : 'r');\r\n/**\r\n * Allows overriding the current route returned by `useRoute` in tests. rl\r\n * stands for route location\r\n *\r\n * @internal\r\n */\r\nconst routeLocationKey = /*#__PURE__*/ PolySymbol((process.env.NODE_ENV !== 'production') ? 'route location' : 'rl');\r\n/**\r\n * Allows overriding the current route used by router-view. Internally this is\r\n * used when the `route` prop is passed.\r\n *\r\n * @internal\r\n */\r\nconst routerViewLocationKey = /*#__PURE__*/ PolySymbol((process.env.NODE_ENV !== 'production') ? 'router view location' : 'rvl');\n\nconst isBrowser = typeof window !== 'undefined';\n\nfunction isESModule(obj) {\r\n return obj.__esModule || (hasSymbol && obj[Symbol.toStringTag] === 'Module');\r\n}\r\nconst assign = Object.assign;\r\nfunction applyToParams(fn, params) {\r\n const newParams = {};\r\n for (const key in params) {\r\n const value = params[key];\r\n newParams[key] = Array.isArray(value) ? value.map(fn) : fn(value);\r\n }\r\n return newParams;\r\n}\r\nconst noop = () => { };\n\nfunction warn(msg) {\r\n // avoid using ...args as it breaks in older Edge builds\r\n const args = Array.from(arguments).slice(1);\r\n console.warn.apply(console, ['[Vue Router warn]: ' + msg].concat(args));\r\n}\n\nconst TRAILING_SLASH_RE = /\\/$/;\r\nconst removeTrailingSlash = (path) => path.replace(TRAILING_SLASH_RE, '');\r\n/**\r\n * Transforms an URI into a normalized history location\r\n *\r\n * @param parseQuery\r\n * @param location - URI to normalize\r\n * @param currentLocation - current absolute location. Allows resolving relative\r\n * paths. Must start with `/`. Defaults to `/`\r\n * @returns a normalized history location\r\n */\r\nfunction parseURL(parseQuery, location, currentLocation = '/') {\r\n let path, query = {}, searchString = '', hash = '';\r\n // Could use URL and URLSearchParams but IE 11 doesn't support it\r\n const searchPos = location.indexOf('?');\r\n const hashPos = location.indexOf('#', searchPos > -1 ? searchPos : 0);\r\n if (searchPos > -1) {\r\n path = location.slice(0, searchPos);\r\n searchString = location.slice(searchPos + 1, hashPos > -1 ? hashPos : location.length);\r\n query = parseQuery(searchString);\r\n }\r\n if (hashPos > -1) {\r\n path = path || location.slice(0, hashPos);\r\n // keep the # character\r\n hash = location.slice(hashPos, location.length);\r\n }\r\n // no search and no query\r\n path = resolveRelativePath(path != null ? path : location, currentLocation);\r\n // empty path means a relative query or hash `?foo=f`, `#thing`\r\n return {\r\n fullPath: path + (searchString && '?') + searchString + hash,\r\n path,\r\n query,\r\n hash,\r\n };\r\n}\r\n/**\r\n * Stringifies a URL object\r\n *\r\n * @param stringifyQuery\r\n * @param location\r\n */\r\nfunction stringifyURL(stringifyQuery, location) {\r\n const query = location.query ? stringifyQuery(location.query) : '';\r\n return location.path + (query && '?') + query + (location.hash || '');\r\n}\r\n/**\r\n * Strips off the base from the beginning of a location.pathname in a non\r\n * case-sensitive way.\r\n *\r\n * @param pathname - location.pathname\r\n * @param base - base to strip off\r\n */\r\nfunction stripBase(pathname, base) {\r\n // no base or base is not found at the beginning\r\n if (!base || !pathname.toLowerCase().startsWith(base.toLowerCase()))\r\n return pathname;\r\n return pathname.slice(base.length) || '/';\r\n}\r\n/**\r\n * Checks if two RouteLocation are equal. This means that both locations are\r\n * pointing towards the same {@link RouteRecord} and that all `params`, `query`\r\n * parameters and `hash` are the same\r\n *\r\n * @param a - first {@link RouteLocation}\r\n * @param b - second {@link RouteLocation}\r\n */\r\nfunction isSameRouteLocation(stringifyQuery, a, b) {\r\n const aLastIndex = a.matched.length - 1;\r\n const bLastIndex = b.matched.length - 1;\r\n return (aLastIndex > -1 &&\r\n aLastIndex === bLastIndex &&\r\n isSameRouteRecord(a.matched[aLastIndex], b.matched[bLastIndex]) &&\r\n isSameRouteLocationParams(a.params, b.params) &&\r\n stringifyQuery(a.query) === stringifyQuery(b.query) &&\r\n a.hash === b.hash);\r\n}\r\n/**\r\n * Check if two `RouteRecords` are equal. Takes into account aliases: they are\r\n * considered equal to the `RouteRecord` they are aliasing.\r\n *\r\n * @param a - first {@link RouteRecord}\r\n * @param b - second {@link RouteRecord}\r\n */\r\nfunction isSameRouteRecord(a, b) {\r\n // since the original record has an undefined value for aliasOf\r\n // but all aliases point to the original record, this will always compare\r\n // the original record\r\n return (a.aliasOf || a) === (b.aliasOf || b);\r\n}\r\nfunction isSameRouteLocationParams(a, b) {\r\n if (Object.keys(a).length !== Object.keys(b).length)\r\n return false;\r\n for (const key in a) {\r\n if (!isSameRouteLocationParamsValue(a[key], b[key]))\r\n return false;\r\n }\r\n return true;\r\n}\r\nfunction isSameRouteLocationParamsValue(a, b) {\r\n return Array.isArray(a)\r\n ? isEquivalentArray(a, b)\r\n : Array.isArray(b)\r\n ? isEquivalentArray(b, a)\r\n : a === b;\r\n}\r\n/**\r\n * Check if two arrays are the same or if an array with one single entry is the\r\n * same as another primitive value. Used to check query and parameters\r\n *\r\n * @param a - array of values\r\n * @param b - array of values or a single value\r\n */\r\nfunction isEquivalentArray(a, b) {\r\n return Array.isArray(b)\r\n ? a.length === b.length && a.every((value, i) => value === b[i])\r\n : a.length === 1 && a[0] === b;\r\n}\r\n/**\r\n * Resolves a relative path that starts with `.`.\r\n *\r\n * @param to - path location we are resolving\r\n * @param from - currentLocation.path, should start with `/`\r\n */\r\nfunction resolveRelativePath(to, from) {\r\n if (to.startsWith('/'))\r\n return to;\r\n if ((process.env.NODE_ENV !== 'production') && !from.startsWith('/')) {\r\n warn(`Cannot resolve a relative location without an absolute path. Trying to resolve \"${to}\" from \"${from}\". It should look like \"/${from}\".`);\r\n return to;\r\n }\r\n if (!to)\r\n return from;\r\n const fromSegments = from.split('/');\r\n const toSegments = to.split('/');\r\n let position = fromSegments.length - 1;\r\n let toPosition;\r\n let segment;\r\n for (toPosition = 0; toPosition < toSegments.length; toPosition++) {\r\n segment = toSegments[toPosition];\r\n // can't go below zero\r\n if (position === 1 || segment === '.')\r\n continue;\r\n if (segment === '..')\r\n position--;\r\n // found something that is not relative path\r\n else\r\n break;\r\n }\r\n return (fromSegments.slice(0, position).join('/') +\r\n '/' +\r\n toSegments\r\n .slice(toPosition - (toPosition === toSegments.length ? 1 : 0))\r\n .join('/'));\r\n}\n\nvar NavigationType;\r\n(function (NavigationType) {\r\n NavigationType[\"pop\"] = \"pop\";\r\n NavigationType[\"push\"] = \"push\";\r\n})(NavigationType || (NavigationType = {}));\r\nvar NavigationDirection;\r\n(function (NavigationDirection) {\r\n NavigationDirection[\"back\"] = \"back\";\r\n NavigationDirection[\"forward\"] = \"forward\";\r\n NavigationDirection[\"unknown\"] = \"\";\r\n})(NavigationDirection || (NavigationDirection = {}));\r\n/**\r\n * Starting location for Histories\r\n */\r\nconst START = '';\r\n// Generic utils\r\n/**\r\n * Normalizes a base by removing any trailing slash and reading the base tag if\r\n * present.\r\n *\r\n * @param base - base to normalize\r\n */\r\nfunction normalizeBase(base) {\r\n if (!base) {\r\n if (isBrowser) {\r\n // respect <base> tag\r\n const baseEl = document.querySelector('base');\r\n base = (baseEl && baseEl.getAttribute('href')) || '/';\r\n // strip full URL origin\r\n base = base.replace(/^\\w+:\\/\\/[^\\/]+/, '');\r\n }\r\n else {\r\n base = '/';\r\n }\r\n }\r\n // ensure leading slash when it was removed by the regex above avoid leading\r\n // slash with hash because the file could be read from the disk like file://\r\n // and the leading slash would cause problems\r\n if (base[0] !== '/' && base[0] !== '#')\r\n base = '/' + base;\r\n // remove the trailing slash so all other method can just do `base + fullPath`\r\n // to build an href\r\n return removeTrailingSlash(base);\r\n}\r\n// remove any character before the hash\r\nconst BEFORE_HASH_RE = /^[^#]+#/;\r\nfunction createHref(base, location) {\r\n return base.replace(BEFORE_HASH_RE, '#') + location;\r\n}\n\nfunction getElementPosition(el, offset) {\r\n const docRect = document.documentElement.getBoundingClientRect();\r\n const elRect = el.getBoundingClientRect();\r\n return {\r\n behavior: offset.behavior,\r\n left: elRect.left - docRect.left - (offset.left || 0),\r\n top: elRect.top - docRect.top - (offset.top || 0),\r\n };\r\n}\r\nconst computeScrollPosition = () => ({\r\n left: window.pageXOffset,\r\n top: window.pageYOffset,\r\n});\r\nfunction scrollToPosition(position) {\r\n let scrollToOptions;\r\n if ('el' in position) {\r\n const positionEl = position.el;\r\n const isIdSelector = typeof positionEl === 'string' && positionEl.startsWith('#');\r\n /**\r\n * `id`s can accept pretty much any characters, including CSS combinators\r\n * like `>` or `~`. It's still possible to retrieve elements using\r\n * `document.getElementById('~')` but it needs to be escaped when using\r\n * `document.querySelector('#\\\\~')` for it to be valid. The only\r\n * requirements for `id`s are them to be unique on the page and to not be\r\n * empty (`id=\"\"`). Because of that, when passing an id selector, it should\r\n * be properly escaped for it to work with `querySelector`. We could check\r\n * for the id selector to be simple (no CSS combinators `+ >~`) but that\r\n * would make things inconsistent since they are valid characters for an\r\n * `id` but would need to be escaped when using `querySelector`, breaking\r\n * their usage and ending up in no selector returned. Selectors need to be\r\n * escaped:\r\n *\r\n * - `#1-thing` becomes `#\\31 -thing`\r\n * - `#with~symbols` becomes `#with\\\\~symbols`\r\n *\r\n * - More information about the topic can be found at\r\n * https://mathiasbynens.be/notes/html5-id-class.\r\n * - Practical example: https://mathiasbynens.be/demo/html5-id\r\n */\r\n if ((process.env.NODE_ENV !== 'production') && typeof position.el === 'string') {\r\n if (!isIdSelector || !document.getElementById(position.el.slice(1))) {\r\n try {\r\n const foundEl = document.querySelector(position.el);\r\n if (isIdSelector && foundEl) {\r\n warn(`The selector \"${position.el}\" should be passed as \"el: document.querySelector('${position.el}')\" because it starts with \"#\".`);\r\n // return to avoid other warnings\r\n return;\r\n }\r\n }\r\n catch (err) {\r\n warn(`The selector \"${position.el}\" is invalid. If you are using an id selector, make sure to escape it. You can find more information about escaping characters in selectors at https://mathiasbynens.be/notes/css-escapes or use CSS.escape (https://developer.mozilla.org/en-US/docs/Web/API/CSS/escape).`);\r\n // return to avoid other warnings\r\n return;\r\n }\r\n }\r\n }\r\n const el = typeof positionEl === 'string'\r\n ? isIdSelector\r\n ? document.getElementById(positionEl.slice(1))\r\n : document.querySelector(positionEl)\r\n : positionEl;\r\n if (!el) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Couldn't find element using selector \"${position.el}\" returned by scrollBehavior.`);\r\n return;\r\n }\r\n scrollToOptions = getElementPosition(el, position);\r\n }\r\n else {\r\n scrollToOptions = position;\r\n }\r\n if ('scrollBehavior' in document.documentElement.style)\r\n window.scrollTo(scrollToOptions);\r\n else {\r\n window.scrollTo(scrollToOptions.left != null ? scrollToOptions.left : window.pageXOffset, scrollToOptions.top != null ? scrollToOptions.top : window.pageYOffset);\r\n }\r\n}\r\nfunction getScrollKey(path, delta) {\r\n const position = history.state ? history.state.position - delta : -1;\r\n return position + path;\r\n}\r\nconst scrollPositions = new Map();\r\nfunction saveScrollPosition(key, scrollPosition) {\r\n scrollPositions.set(key, scrollPosition);\r\n}\r\nfunction getSavedScrollPosition(key) {\r\n const scroll = scrollPositions.get(key);\r\n // consume it so it's not used again\r\n scrollPositions.delete(key);\r\n return scroll;\r\n}\r\n// TODO: RFC about how to save scroll position\r\n/**\r\n * ScrollBehavior instance used by the router to compute and restore the scroll\r\n * position when navigating.\r\n */\r\n// export interface ScrollHandler<ScrollPositionEntry extends HistoryStateValue, ScrollPosition extends ScrollPositionEntry> {\r\n// // returns a scroll position that can be saved in history\r\n// compute(): ScrollPositionEntry\r\n// // can take an extended ScrollPositionEntry\r\n// scroll(position: ScrollPosition): void\r\n// }\r\n// export const scrollHandler: ScrollHandler<ScrollPosition> = {\r\n// compute: computeScroll,\r\n// scroll: scrollToPosition,\r\n// }\n\nlet createBaseLocation = () => location.protocol + '//' + location.host;\r\n/**\r\n * Creates a normalized history location from a window.location object\r\n * @param location -\r\n */\r\nfunction createCurrentLocation(base, location) {\r\n const { pathname, search, hash } = location;\r\n // allows hash bases like #, /#, #/, #!, #!/, /#!/, or even /folder#end\r\n const hashPos = base.indexOf('#');\r\n if (hashPos > -1) {\r\n let slicePos = hash.includes(base.slice(hashPos))\r\n ? base.slice(hashPos).length\r\n : 1;\r\n let pathFromHash = hash.slice(slicePos);\r\n // prepend the starting slash to hash so the url starts with /#\r\n if (pathFromHash[0] !== '/')\r\n pathFromHash = '/' + pathFromHash;\r\n return stripBase(pathFromHash, '');\r\n }\r\n const path = stripBase(pathname, base);\r\n return path + search + hash;\r\n}\r\nfunction useHistoryListeners(base, historyState, currentLocation, replace) {\r\n let listeners = [];\r\n let teardowns = [];\r\n // TODO: should it be a stack? a Dict. Check if the popstate listener\r\n // can trigger twice\r\n let pauseState = null;\r\n const popStateHandler = ({ state, }) => {\r\n const to = createCurrentLocation(base, location);\r\n const from = currentLocation.value;\r\n const fromState = historyState.value;\r\n let delta = 0;\r\n if (state) {\r\n currentLocation.value = to;\r\n historyState.value = state;\r\n // ignore the popstate and reset the pauseState\r\n if (pauseState && pauseState === from) {\r\n pauseState = null;\r\n return;\r\n }\r\n delta = fromState ? state.position - fromState.position : 0;\r\n }\r\n else {\r\n replace(to);\r\n }\r\n // console.log({ deltaFromCurrent })\r\n // Here we could also revert the navigation by calling history.go(-delta)\r\n // this listener will have to be adapted to not trigger again and to wait for the url\r\n // to be updated before triggering the listeners. Some kind of validation function would also\r\n // need to be passed to the listeners so the navigation can be accepted\r\n // call all listeners\r\n listeners.forEach(listener => {\r\n listener(currentLocation.value, from, {\r\n delta,\r\n type: NavigationType.pop,\r\n direction: delta\r\n ? delta > 0\r\n ? NavigationDirection.forward\r\n : NavigationDirection.back\r\n : NavigationDirection.unknown,\r\n });\r\n });\r\n };\r\n function pauseListeners() {\r\n pauseState = currentLocation.value;\r\n }\r\n function listen(callback) {\r\n // setup the listener and prepare teardown callbacks\r\n listeners.push(callback);\r\n const teardown = () => {\r\n const index = listeners.indexOf(callback);\r\n if (index > -1)\r\n listeners.splice(index, 1);\r\n };\r\n teardowns.push(teardown);\r\n return teardown;\r\n }\r\n function beforeUnloadListener() {\r\n const { history } = window;\r\n if (!history.state)\r\n return;\r\n history.replaceState(assign({}, history.state, { scroll: computeScrollPosition() }), '');\r\n }\r\n function destroy() {\r\n for (const teardown of teardowns)\r\n teardown();\r\n teardowns = [];\r\n window.removeEventListener('popstate', popStateHandler);\r\n window.removeEventListener('beforeunload', beforeUnloadListener);\r\n }\r\n // setup the listeners and prepare teardown callbacks\r\n window.addEventListener('popstate', popStateHandler);\r\n window.addEventListener('beforeunload', beforeUnloadListener);\r\n return {\r\n pauseListeners,\r\n listen,\r\n destroy,\r\n };\r\n}\r\n/**\r\n * Creates a state object\r\n */\r\nfunction buildState(back, current, forward, replaced = false, computeScroll = false) {\r\n return {\r\n back,\r\n current,\r\n forward,\r\n replaced,\r\n position: window.history.length,\r\n scroll: computeScroll ? computeScrollPosition() : null,\r\n };\r\n}\r\nfunction useHistoryStateNavigation(base) {\r\n const { history, location } = window;\r\n // private variables\r\n const currentLocation = {\r\n value: createCurrentLocation(base, location),\r\n };\r\n const historyState = { value: history.state };\r\n // build current history entry as this is a fresh navigation\r\n if (!historyState.value) {\r\n changeLocation(currentLocation.value, {\r\n back: null,\r\n current: currentLocation.value,\r\n forward: null,\r\n // the length is off by one, we need to decrease it\r\n position: history.length - 1,\r\n replaced: true,\r\n // don't add a scroll as the user may have an anchor and we want\r\n // scrollBehavior to be triggered without a saved position\r\n scroll: null,\r\n }, true);\r\n }\r\n function changeLocation(to, state, replace) {\r\n /**\r\n * if a base tag is provided and we are on a normal domain, we have to\r\n * respect the provided `base` attribute because pushState() will use it and\r\n * potentially erase anything before the `#` like at\r\n * https://github.com/vuejs/vue-router-next/issues/685 where a base of\r\n * `/folder/#` but a base of `/` would erase the `/folder/` section. If\r\n * there is no host, the `<base>` tag makes no sense and if there isn't a\r\n * base tag we can just use everything after the `#`.\r\n */\r\n const hashIndex = base.indexOf('#');\r\n const url = hashIndex > -1\r\n ? (location.host && document.querySelector('base')\r\n ? base\r\n : base.slice(hashIndex)) + to\r\n : createBaseLocation() + base + to;\r\n try {\r\n // BROWSER QUIRK\r\n // NOTE: Safari throws a SecurityError when calling this function 100 times in 30 seconds\r\n history[replace ? 'replaceState' : 'pushState'](state, '', url);\r\n historyState.value = state;\r\n }\r\n catch (err) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Error with push/replace State', err);\r\n }\r\n else {\r\n console.error(err);\r\n }\r\n // Force the navigation, this also resets the call count\r\n location[replace ? 'replace' : 'assign'](url);\r\n }\r\n }\r\n function replace(to, data) {\r\n const state = assign({}, history.state, buildState(historyState.value.back, \r\n // keep back and forward entries but override current position\r\n to, historyState.value.forward, true), data, { position: historyState.value.position });\r\n changeLocation(to, state, true);\r\n currentLocation.value = to;\r\n }\r\n function push(to, data) {\r\n // Add to current entry the information of where we are going\r\n // as well as saving the current position\r\n const currentState = assign({}, \r\n // use current history state to gracefully handle a wrong call to\r\n // history.replaceState\r\n // https://github.com/vuejs/vue-router-next/issues/366\r\n historyState.value, history.state, {\r\n forward: to,\r\n scroll: computeScrollPosition(),\r\n });\r\n if ((process.env.NODE_ENV !== 'production') && !history.state) {\r\n warn(`history.state seems to have been manually replaced without preserving the necessary values. Make sure to preserve existing history state if you are manually calling history.replaceState:\\n\\n` +\r\n `history.replaceState(history.state, '', url)\\n\\n` +\r\n `You can find more information at https://next.router.vuejs.org/guide/migration/#usage-of-history-state.`);\r\n }\r\n changeLocation(currentState.current, currentState, true);\r\n const state = assign({}, buildState(currentLocation.value, to, null), { position: currentState.position + 1 }, data);\r\n changeLocation(to, state, false);\r\n currentLocation.value = to;\r\n }\r\n return {\r\n location: currentLocation,\r\n state: historyState,\r\n push,\r\n replace,\r\n };\r\n}\r\n/**\r\n * Creates an HTML5 history. Most common history for single page applications.\r\n *\r\n * @param base -\r\n */\r\nfunction createWebHistory(base) {\r\n base = normalizeBase(base);\r\n const historyNavigation = useHistoryStateNavigation(base);\r\n const historyListeners = useHistoryListeners(base, historyNavigation.state, historyNavigation.location, historyNavigation.replace);\r\n function go(delta, triggerListeners = true) {\r\n if (!triggerListeners)\r\n historyListeners.pauseListeners();\r\n history.go(delta);\r\n }\r\n const routerHistory = assign({\r\n // it's overridden right after\r\n location: '',\r\n base,\r\n go,\r\n createHref: createHref.bind(null, base),\r\n }, historyNavigation, historyListeners);\r\n Object.defineProperty(routerHistory, 'location', {\r\n enumerable: true,\r\n get: () => historyNavigation.location.value,\r\n });\r\n Object.defineProperty(routerHistory, 'state', {\r\n enumerable: true,\r\n get: () => historyNavigation.state.value,\r\n });\r\n return routerHistory;\r\n}\n\n/**\r\n * Creates a in-memory based history. The main purpose of this history is to handle SSR. It starts in a special location that is nowhere.\r\n * It's up to the user to replace that location with the starter location by either calling `router.push` or `router.replace`.\r\n *\r\n * @param base - Base applied to all urls, defaults to '/'\r\n * @returns a history object that can be passed to the router constructor\r\n */\r\nfunction createMemoryHistory(base = '') {\r\n let listeners = [];\r\n let queue = [START];\r\n let position = 0;\r\n base = normalizeBase(base);\r\n function setLocation(location) {\r\n position++;\r\n if (position === queue.length) {\r\n // we are at the end, we can simply append a new entry\r\n queue.push(location);\r\n }\r\n else {\r\n // we are in the middle, we remove everything from here in the queue\r\n queue.splice(position);\r\n queue.push(location);\r\n }\r\n }\r\n function triggerListeners(to, from, { direction, delta }) {\r\n const info = {\r\n direction,\r\n delta,\r\n type: NavigationType.pop,\r\n };\r\n for (const callback of listeners) {\r\n callback(to, from, info);\r\n }\r\n }\r\n const routerHistory = {\r\n // rewritten by Object.defineProperty\r\n location: START,\r\n // TODO: should be kept in queue\r\n state: {},\r\n base,\r\n createHref: createHref.bind(null, base),\r\n replace(to) {\r\n // remove current entry and decrement position\r\n queue.splice(position--, 1);\r\n setLocation(to);\r\n },\r\n push(to, data) {\r\n setLocation(to);\r\n },\r\n listen(callback) {\r\n listeners.push(callback);\r\n return () => {\r\n const index = listeners.indexOf(callback);\r\n if (index > -1)\r\n listeners.splice(index, 1);\r\n };\r\n },\r\n destroy() {\r\n listeners = [];\r\n queue = [START];\r\n position = 0;\r\n },\r\n go(delta, shouldTrigger = true) {\r\n const from = this.location;\r\n const direction = \r\n // we are considering delta === 0 going forward, but in abstract mode\r\n // using 0 for the delta doesn't make sense like it does in html5 where\r\n // it reloads the page\r\n delta < 0 ? NavigationDirection.back : NavigationDirection.forward;\r\n position = Math.max(0, Math.min(position + delta, queue.length - 1));\r\n if (shouldTrigger) {\r\n triggerListeners(this.location, from, {\r\n direction,\r\n delta,\r\n });\r\n }\r\n },\r\n };\r\n Object.defineProperty(routerHistory, 'location', {\r\n enumerable: true,\r\n get: () => queue[position],\r\n });\r\n return routerHistory;\r\n}\n\n/**\r\n * Creates a hash history. Useful for web applications with no host (e.g.\r\n * `file://`) or when configuring a server to handle any URL is not possible.\r\n *\r\n * @param base - optional base to provide. Defaults to `location.pathname +\r\n * location.search` If there is a `<base>` tag in the `head`, its value will be\r\n * ignored in favor of this parameter **but note it affects all the\r\n * history.pushState() calls**, meaning that if you use a `<base>` tag, it's\r\n * `href` value **has to match this parameter** (ignoring anything after the\r\n * `#`).\r\n *\r\n * @example\r\n * ```js\r\n * // at https://example.com/folder\r\n * createWebHashHistory() // gives a url of `https://example.com/folder#`\r\n * createWebHashHistory('/folder/') // gives a url of `https://example.com/folder/#`\r\n * // if the `#` is provided in the base, it won't be added by `createWebHashHistory`\r\n * createWebHashHistory('/folder/#/app/') // gives a url of `https://example.com/folder/#/app/`\r\n * // you should avoid doing this because it changes the original url and breaks copying urls\r\n * createWebHashHistory('/other-folder/') // gives a url of `https://example.com/other-folder/#`\r\n *\r\n * // at file:///usr/etc/folder/index.html\r\n * // for locations with no `host`, the base is ignored\r\n * createWebHashHistory('/iAmIgnored') // gives a url of `file:///usr/etc/folder/index.html#`\r\n * ```\r\n */\r\nfunction createWebHashHistory(base) {\r\n // Make sure this implementation is fine in terms of encoding, specially for IE11\r\n // for `file://`, directly use the pathname and ignore the base\r\n // location.pathname contains an initial `/` even at the root: `https://example.com`\r\n base = location.host ? base || location.pathname + location.search : '';\r\n // allow the user to provide a `#` in the middle: `/base/#/app`\r\n if (!base.includes('#'))\r\n base += '#';\r\n if ((process.env.NODE_ENV !== 'production') && !base.endsWith('#/') && !base.endsWith('#')) {\r\n warn(`A hash base must end with a \"#\":\\n\"${base}\" should be \"${base.replace(/#.*$/, '#')}\".`);\r\n }\r\n return createWebHistory(base);\r\n}\n\nfunction isRouteLocation(route) {\r\n return typeof route === 'string' || (route && typeof route === 'object');\r\n}\r\nfunction isRouteName(name) {\r\n return typeof name === 'string' || typeof name === 'symbol';\r\n}\n\n/**\r\n * Initial route location where the router is. Can be used in navigation guards\r\n * to differentiate the initial navigation.\r\n *\r\n * @example\r\n * ```js\r\n * import { START_LOCATION } from 'vue-router'\r\n *\r\n * router.beforeEach((to, from) => {\r\n * if (from === START_LOCATION) {\r\n * // initial navigation\r\n * }\r\n * })\r\n * ```\r\n */\r\nconst START_LOCATION_NORMALIZED = {\r\n path: '/',\r\n name: undefined,\r\n params: {},\r\n query: {},\r\n hash: '',\r\n fullPath: '/',\r\n matched: [],\r\n meta: {},\r\n redirectedFrom: undefined,\r\n};\n\nconst NavigationFailureSymbol = /*#__PURE__*/ PolySymbol((process.env.NODE_ENV !== 'production') ? 'navigation failure' : 'nf');\r\n/**\r\n * Enumeration with all possible types for navigation failures. Can be passed to\r\n * {@link isNavigationFailure} to check for specific failures.\r\n */\r\nvar NavigationFailureType;\r\n(function (NavigationFailureType) {\r\n /**\r\n * An aborted navigation is a navigation that failed because a navigation\r\n * guard returned `false` or called `next(false)`\r\n */\r\n NavigationFailureType[NavigationFailureType[\"aborted\"] = 4] = \"aborted\";\r\n /**\r\n * A cancelled navigation is a navigation that failed because a more recent\r\n * navigation finished started (not necessarily finished).\r\n */\r\n NavigationFailureType[NavigationFailureType[\"cancelled\"] = 8] = \"cancelled\";\r\n /**\r\n * A duplicated navigation is a navigation that failed because it was\r\n * initiated while already being at the exact same location.\r\n */\r\n NavigationFailureType[NavigationFailureType[\"duplicated\"] = 16] = \"duplicated\";\r\n})(NavigationFailureType || (NavigationFailureType = {}));\r\n// DEV only debug messages\r\nconst ErrorTypeMessages = {\r\n [1 /* MATCHER_NOT_FOUND */]({ location, currentLocation }) {\r\n return `No match for\\n ${JSON.stringify(location)}${currentLocation\r\n ? '\\nwhile being at\\n' + JSON.stringify(currentLocation)\r\n : ''}`;\r\n },\r\n [2 /* NAVIGATION_GUARD_REDIRECT */]({ from, to, }) {\r\n return `Redirected from \"${from.fullPath}\" to \"${stringifyRoute(to)}\" via a navigation guard.`;\r\n },\r\n [4 /* NAVIGATION_ABORTED */]({ from, to }) {\r\n return `Navigation aborted from \"${from.fullPath}\" to \"${to.fullPath}\" via a navigation guard.`;\r\n },\r\n [8 /* NAVIGATION_CANCELLED */]({ from, to }) {\r\n return `Navigation cancelled from \"${from.fullPath}\" to \"${to.fullPath}\" with a new navigation.`;\r\n },\r\n [16 /* NAVIGATION_DUPLICATED */]({ from, to }) {\r\n return `Avoided redundant navigation to current location: \"${from.fullPath}\".`;\r\n },\r\n};\r\nfunction createRouterError(type, params) {\r\n // keep full error messages in cjs versions\r\n if ((process.env.NODE_ENV !== 'production') || !true) {\r\n return assign(new Error(ErrorTypeMessages[type](params)), {\r\n type,\r\n [NavigationFailureSymbol]: true,\r\n }, params);\r\n }\r\n else {\r\n return assign(new Error(), {\r\n type,\r\n [NavigationFailureSymbol]: true,\r\n }, params);\r\n }\r\n}\r\nfunction isNavigationFailure(error, type) {\r\n return (error instanceof Error &&\r\n NavigationFailureSymbol in error &&\r\n (type == null || !!(error.type & type)));\r\n}\r\nconst propertiesToLog = ['params', 'query', 'hash'];\r\nfunction stringifyRoute(to) {\r\n if (typeof to === 'string')\r\n return to;\r\n if ('path' in to)\r\n return to.path;\r\n const location = {};\r\n for (const key of propertiesToLog) {\r\n if (key in to)\r\n location[key] = to[key];\r\n }\r\n return JSON.stringify(location, null, 2);\r\n}\n\n// default pattern for a param: non greedy everything but /\r\nconst BASE_PARAM_PATTERN = '[^/]+?';\r\nconst BASE_PATH_PARSER_OPTIONS = {\r\n sensitive: false,\r\n strict: false,\r\n start: true,\r\n end: true,\r\n};\r\n// Special Regex characters that must be escaped in static tokens\r\nconst REGEX_CHARS_RE = /[.+*?^${}()[\\]/\\\\]/g;\r\n/**\r\n * Creates a path parser from an array of Segments (a segment is an array of Tokens)\r\n *\r\n * @param segments - array of segments returned by tokenizePath\r\n * @param extraOptions - optional options for the regexp\r\n * @returns a PathParser\r\n */\r\nfunction tokensToParser(segments, extraOptions) {\r\n const options = assign({}, BASE_PATH_PARSER_OPTIONS, extraOptions);\r\n // the amount of scores is the same as the length of segments except for the root segment \"/\"\r\n const score = [];\r\n // the regexp as a string\r\n let pattern = options.start ? '^' : '';\r\n // extracted keys\r\n const keys = [];\r\n for (const segment of segments) {\r\n // the root segment needs special treatment\r\n const segmentScores = segment.length ? [] : [90 /* Root */];\r\n // allow trailing slash\r\n if (options.strict && !segment.length)\r\n pattern += '/';\r\n for (let tokenIndex = 0; tokenIndex < segment.length; tokenIndex++) {\r\n const token = segment[tokenIndex];\r\n // resets the score if we are inside a sub segment /:a-other-:b\r\n let subSegmentScore = 40 /* Segment */ +\r\n (options.sensitive ? 0.25 /* BonusCaseSensitive */ : 0);\r\n if (token.type === 0 /* Static */) {\r\n // prepend the slash if we are starting a new segment\r\n if (!tokenIndex)\r\n pattern += '/';\r\n pattern += token.value.replace(REGEX_CHARS_RE, '\\\\$&');\r\n subSegmentScore += 40 /* Static */;\r\n }\r\n else if (token.type === 1 /* Param */) {\r\n const { value, repeatable, optional, regexp } = token;\r\n keys.push({\r\n name: value,\r\n repeatable,\r\n optional,\r\n });\r\n const re = regexp ? regexp : BASE_PARAM_PATTERN;\r\n // the user provided a custom regexp /:id(\\\\d+)\r\n if (re !== BASE_PARAM_PATTERN) {\r\n subSegmentScore += 10 /* BonusCustomRegExp */;\r\n // make sure the regexp is valid before using it\r\n try {\r\n new RegExp(`(${re})`);\r\n }\r\n catch (err) {\r\n throw new Error(`Invalid custom RegExp for param \"${value}\" (${re}): ` +\r\n err.message);\r\n }\r\n }\r\n // when we repeat we must take care of the repeating leading slash\r\n let subPattern = repeatable ? `((?:${re})(?:/(?:${re}))*)` : `(${re})`;\r\n // prepend the slash if we are starting a new segment\r\n if (!tokenIndex)\r\n subPattern =\r\n // avoid an optional / if there are more segments e.g. /:p?-static\r\n // or /:p?-:p2\r\n optional && segment.length < 2\r\n ? `(?:/${subPattern})`\r\n : '/' + subPattern;\r\n if (optional)\r\n subPattern += '?';\r\n pattern += subPattern;\r\n subSegmentScore += 20 /* Dynamic */;\r\n if (optional)\r\n subSegmentScore += -8 /* BonusOptional */;\r\n if (repeatable)\r\n subSegmentScore += -20 /* BonusRepeatable */;\r\n if (re === '.*')\r\n subSegmentScore += -50 /* BonusWildcard */;\r\n }\r\n segmentScores.push(subSegmentScore);\r\n }\r\n // an empty array like /home/ -> [[{home}], []]\r\n // if (!segment.length) pattern += '/'\r\n score.push(segmentScores);\r\n }\r\n // only apply the strict bonus to the last score\r\n if (options.strict && options.end) {\r\n const i = score.length - 1;\r\n score[i][score[i].length - 1] += 0.7000000000000001 /* BonusStrict */;\r\n }\r\n // TODO: dev only warn double trailing slash\r\n if (!options.strict)\r\n pattern += '/?';\r\n if (options.end)\r\n pattern += '$';\r\n // allow paths like /dynamic to only match dynamic or dynamic/... but not dynamic_something_else\r\n else if (options.strict)\r\n pattern += '(?:/|$)';\r\n const re = new RegExp(pattern, options.sensitive ? '' : 'i');\r\n function parse(path) {\r\n const match = path.match(re);\r\n const params = {};\r\n if (!match)\r\n return null;\r\n for (let i = 1; i < match.length; i++) {\r\n const value = match[i] || '';\r\n const key = keys[i - 1];\r\n params[key.name] = value && key.repeatable ? value.split('/') : value;\r\n }\r\n return params;\r\n }\r\n function stringify(params) {\r\n let path = '';\r\n // for optional parameters to allow to be empty\r\n let avoidDuplicatedSlash = false;\r\n for (const segment of segments) {\r\n if (!avoidDuplicatedSlash || !path.endsWith('/'))\r\n path += '/';\r\n avoidDuplicatedSlash = false;\r\n for (const token of segment) {\r\n if (token.type === 0 /* Static */) {\r\n path += token.value;\r\n }\r\n else if (token.type === 1 /* Param */) {\r\n const { value, repeatable, optional } = token;\r\n const param = value in params ? params[value] : '';\r\n if (Array.isArray(param) && !repeatable)\r\n throw new Error(`Provided param \"${value}\" is an array but it is not repeatable (* or + modifiers)`);\r\n const text = Array.isArray(param) ? param.join('/') : param;\r\n if (!text) {\r\n if (optional) {\r\n // if we have more than one optional param like /:a?-static we\r\n // don't need to care about the optional param\r\n if (segment.length < 2) {\r\n // remove the last slash as we could be at the end\r\n if (path.endsWith('/'))\r\n path = path.slice(0, -1);\r\n // do not append a slash on the next iteration\r\n else\r\n avoidDuplicatedSlash = true;\r\n }\r\n }\r\n else\r\n throw new Error(`Missing required param \"${value}\"`);\r\n }\r\n path += text;\r\n }\r\n }\r\n }\r\n return path;\r\n }\r\n return {\r\n re,\r\n score,\r\n keys,\r\n parse,\r\n stringify,\r\n };\r\n}\r\n/**\r\n * Compares an array of numbers as used in PathParser.score and returns a\r\n * number. This function can be used to `sort` an array\r\n *\r\n * @param a - first array of numbers\r\n * @param b - second array of numbers\r\n * @returns 0 if both are equal, < 0 if a should be sorted first, > 0 if b\r\n * should be sorted first\r\n */\r\nfunction compareScoreArray(a, b) {\r\n let i = 0;\r\n while (i < a.length && i < b.length) {\r\n const diff = b[i] - a[i];\r\n // only keep going if diff === 0\r\n if (diff)\r\n return diff;\r\n i++;\r\n }\r\n // if the last subsegment was Static, the shorter segments should be sorted first\r\n // otherwise sort the longest segment first\r\n if (a.length < b.length) {\r\n return a.length === 1 && a[0] === 40 /* Static */ + 40 /* Segment */\r\n ? -1\r\n : 1;\r\n }\r\n else if (a.length > b.length) {\r\n return b.length === 1 && b[0] === 40 /* Static */ + 40 /* Segment */\r\n ? 1\r\n : -1;\r\n }\r\n return 0;\r\n}\r\n/**\r\n * Compare function that can be used with `sort` to sort an array of PathParser\r\n *\r\n * @param a - first PathParser\r\n * @param b - second PathParser\r\n * @returns 0 if both are equal, < 0 if a should be sorted first, > 0 if b\r\n */\r\nfunction comparePathParserScore(a, b) {\r\n let i = 0;\r\n const aScore = a.score;\r\n const bScore = b.score;\r\n while (i < aScore.length && i < bScore.length) {\r\n const comp = compareScoreArray(aScore[i], bScore[i]);\r\n // do not return if both are equal\r\n if (comp)\r\n return comp;\r\n i++;\r\n }\r\n // if a and b share the same score entries but b has more, sort b first\r\n return bScore.length - aScore.length;\r\n // this is the ternary version\r\n // return aScore.length < bScore.length\r\n // ? 1\r\n // : aScore.length > bScore.length\r\n // ? -1\r\n // : 0\r\n}\n\nconst ROOT_TOKEN = {\r\n type: 0 /* Static */,\r\n value: '',\r\n};\r\nconst VALID_PARAM_RE = /[a-zA-Z0-9_]/;\r\n// After some profiling, the cache seems to be unnecessary because tokenizePath\r\n// (the slowest part of adding a route) is very fast\r\n// const tokenCache = new Map<string, Token[][]>()\r\nfunction tokenizePath(path) {\r\n if (!path)\r\n return [[]];\r\n if (path === '/')\r\n return [[ROOT_TOKEN]];\r\n if (!path.startsWith('/')) {\r\n throw new Error((process.env.NODE_ENV !== 'production')\r\n ? `Route paths should start with a \"/\": \"${path}\" should be \"/${path}\".`\r\n : `Invalid path \"${path}\"`);\r\n }\r\n // if (tokenCache.has(path)) return tokenCache.get(path)!\r\n function crash(message) {\r\n throw new Error(`ERR (${state})/\"${buffer}\": ${message}`);\r\n }\r\n let state = 0 /* Static */;\r\n let previousState = state;\r\n const tokens = [];\r\n // the segment will always be valid because we get into the initial state\r\n // with the leading /\r\n let segment;\r\n function finalizeSegment() {\r\n if (segment)\r\n tokens.push(segment);\r\n segment = [];\r\n }\r\n // index on the path\r\n let i = 0;\r\n // char at index\r\n let char;\r\n // buffer of the value read\r\n let buffer = '';\r\n // custom regexp for a param\r\n let customRe = '';\r\n function consumeBuffer() {\r\n if (!buffer)\r\n return;\r\n if (state === 0 /* Static */) {\r\n segment.push({\r\n type: 0 /* Static */,\r\n value: buffer,\r\n });\r\n }\r\n else if (state === 1 /* Param */ ||\r\n state === 2 /* ParamRegExp */ ||\r\n state === 3 /* ParamRegExpEnd */) {\r\n if (segment.length > 1 && (char === '*' || char === '+'))\r\n crash(`A repeatable param (${buffer}) must be alone in its segment. eg: '/:ids+.`);\r\n segment.push({\r\n type: 1 /* Param */,\r\n value: buffer,\r\n regexp: customRe,\r\n repeatable: char === '*' || char === '+',\r\n optional: char === '*' || char === '?',\r\n });\r\n }\r\n else {\r\n crash('Invalid state to consume buffer');\r\n }\r\n buffer = '';\r\n }\r\n function addCharToBuffer() {\r\n buffer += char;\r\n }\r\n while (i < path.length) {\r\n char = path[i++];\r\n if (char === '\\\\' && state !== 2 /* ParamRegExp */) {\r\n previousState = state;\r\n state = 4 /* EscapeNext */;\r\n continue;\r\n }\r\n switch (state) {\r\n case 0 /* Static */:\r\n if (char === '/') {\r\n if (buffer) {\r\n consumeBuffer();\r\n }\r\n finalizeSegment();\r\n }\r\n else if (char === ':') {\r\n consumeBuffer();\r\n state = 1 /* Param */;\r\n }\r\n else {\r\n addCharToBuffer();\r\n }\r\n break;\r\n case 4 /* EscapeNext */:\r\n addCharToBuffer();\r\n state = previousState;\r\n break;\r\n case 1 /* Param */:\r\n if (char === '(') {\r\n state = 2 /* ParamRegExp */;\r\n }\r\n else if (VALID_PARAM_RE.test(char)) {\r\n addCharToBuffer();\r\n }\r\n else {\r\n consumeBuffer();\r\n state = 0 /* Static */;\r\n // go back one character if we were not modifying\r\n if (char !== '*' && char !== '?' && char !== '+')\r\n i--;\r\n }\r\n break;\r\n case 2 /* ParamRegExp */:\r\n // TODO: is it worth handling nested regexp? like :p(?:prefix_([^/]+)_suffix)\r\n // it already works by escaping the closing )\r\n // https://paths.esm.dev/?p=AAMeJbiAwQEcDKbAoAAkP60PG2R6QAvgNaA6AFACM2ABuQBB#\r\n // is this really something people need since you can also write\r\n // /prefix_:p()_suffix\r\n if (char === ')') {\r\n // handle the escaped )\r\n if (customRe[customRe.length - 1] == '\\\\')\r\n customRe = customRe.slice(0, -1) + char;\r\n else\r\n state = 3 /* ParamRegExpEnd */;\r\n }\r\n else {\r\n customRe += char;\r\n }\r\n break;\r\n case 3 /* ParamRegExpEnd */:\r\n // same as finalizing a param\r\n consumeBuffer();\r\n state = 0 /* Static */;\r\n // go back one character if we were not modifying\r\n if (char !== '*' && char !== '?' && char !== '+')\r\n i--;\r\n customRe = '';\r\n break;\r\n default:\r\n crash('Unknown state');\r\n break;\r\n }\r\n }\r\n if (state === 2 /* ParamRegExp */)\r\n crash(`Unfinished custom RegExp for param \"${buffer}\"`);\r\n consumeBuffer();\r\n finalizeSegment();\r\n // tokenCache.set(path, tokens)\r\n return tokens;\r\n}\n\nfunction createRouteRecordMatcher(record, parent, options) {\r\n const parser = tokensToParser(tokenizePath(record.path), options);\r\n // warn against params with the same name\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const existingKeys = new Set();\r\n for (const key of parser.keys) {\r\n if (existingKeys.has(key.name))\r\n warn(`Found duplicated params with name \"${key.name}\" for path \"${record.path}\". Only the last one will be available on \"$route.params\".`);\r\n existingKeys.add(key.name);\r\n }\r\n }\r\n const matcher = assign(parser, {\r\n record,\r\n parent,\r\n // these needs to be populated by the parent\r\n children: [],\r\n alias: [],\r\n });\r\n if (parent) {\r\n // both are aliases or both are not aliases\r\n // we don't want to mix them because the order is used when\r\n // passing originalRecord in Matcher.addRoute\r\n if (!matcher.record.aliasOf === !parent.record.aliasOf)\r\n parent.children.push(matcher);\r\n }\r\n return matcher;\r\n}\n\n/**\r\n * Creates a Router Matcher.\r\n *\r\n * @internal\r\n * @param routes - array of initial routes\r\n * @param globalOptions - global route options\r\n */\r\nfunction createRouterMatcher(routes, globalOptions) {\r\n // normalized ordered array of matchers\r\n const matchers = [];\r\n const matcherMap = new Map();\r\n globalOptions = mergeOptions({ strict: false, end: true, sensitive: false }, globalOptions);\r\n function getRecordMatcher(name) {\r\n return matcherMap.get(name);\r\n }\r\n function addRoute(record, parent, originalRecord) {\r\n // used later on to remove by name\r\n const isRootAdd = !originalRecord;\r\n const mainNormalizedRecord = normalizeRouteRecord(record);\r\n // we might be the child of an alias\r\n mainNormalizedRecord.aliasOf = originalRecord && originalRecord.record;\r\n const options = mergeOptions(globalOptions, record);\r\n // generate an array of records to correctly handle aliases\r\n const normalizedRecords = [\r\n mainNormalizedRecord,\r\n ];\r\n if ('alias' in record) {\r\n const aliases = typeof record.alias === 'string' ? [record.alias] : record.alias;\r\n for (const alias of aliases) {\r\n normalizedRecords.push(assign({}, mainNormalizedRecord, {\r\n // this allows us to hold a copy of the `components` option\r\n // so that async components cache is hold on the original record\r\n components: originalRecord\r\n ? originalRecord.record.components\r\n : mainNormalizedRecord.components,\r\n path: alias,\r\n // we might be the child of an alias\r\n aliasOf: originalRecord\r\n ? originalRecord.record\r\n : mainNormalizedRecord,\r\n // the aliases are always of the same kind as the original since they\r\n // are defined on the same record\r\n }));\r\n }\r\n }\r\n let matcher;\r\n let originalMatcher;\r\n for (const normalizedRecord of normalizedRecords) {\r\n const { path } = normalizedRecord;\r\n // Build up the path for nested routes if the child isn't an absolute\r\n // route. Only add the / delimiter if the child path isn't empty and if the\r\n // parent path doesn't have a trailing slash\r\n if (parent && path[0] !== '/') {\r\n const parentPath = parent.record.path;\r\n const connectingSlash = parentPath[parentPath.length - 1] === '/' ? '' : '/';\r\n normalizedRecord.path =\r\n parent.record.path + (path && connectingSlash + path);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && normalizedRecord.path === '*') {\r\n throw new Error('Catch all routes (\"*\") must now be defined using a param with a custom regexp.\\n' +\r\n 'See more at https://next.router.vuejs.org/guide/migration/#removed-star-or-catch-all-routes.');\r\n }\r\n // create the object before hand so it can be passed to children\r\n matcher = createRouteRecordMatcher(normalizedRecord, parent, options);\r\n if ((process.env.NODE_ENV !== 'production') && parent && path[0] === '/')\r\n checkMissingParamsInAbsolutePath(matcher, parent);\r\n // if we are an alias we must tell the original record that we exist\r\n // so we can be removed\r\n if (originalRecord) {\r\n originalRecord.alias.push(matcher);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n checkSameParams(originalRecord, matcher);\r\n }\r\n }\r\n else {\r\n // otherwise, the first record is the original and others are aliases\r\n originalMatcher = originalMatcher || matcher;\r\n if (originalMatcher !== matcher)\r\n originalMatcher.alias.push(matcher);\r\n // remove the route if named and only for the top record (avoid in nested calls)\r\n // this works because the original record is the first one\r\n if (isRootAdd && record.name && !isAliasRecord(matcher))\r\n removeRoute(record.name);\r\n }\r\n if ('children' in mainNormalizedRecord) {\r\n const children = mainNormalizedRecord.children;\r\n for (let i = 0; i < children.length; i++) {\r\n addRoute(children[i], matcher, originalRecord && originalRecord.children[i]);\r\n }\r\n }\r\n // if there was no original record, then the first one was not an alias and all\r\n // other alias (if any) need to reference this record when adding children\r\n originalRecord = originalRecord || matcher;\r\n // TODO: add normalized records for more flexibility\r\n // if (parent && isAliasRecord(originalRecord)) {\r\n // parent.children.push(originalRecord)\r\n // }\r\n insertMatcher(matcher);\r\n }\r\n return originalMatcher\r\n ? () => {\r\n // since other matchers are aliases, they should be removed by the original matcher\r\n removeRoute(originalMatcher);\r\n }\r\n : noop;\r\n }\r\n function removeRoute(matcherRef) {\r\n if (isRouteName(matcherRef)) {\r\n const matcher = matcherMap.get(matcherRef);\r\n if (matcher) {\r\n matcherMap.delete(matcherRef);\r\n matchers.splice(matchers.indexOf(matcher), 1);\r\n matcher.children.forEach(removeRoute);\r\n matcher.alias.forEach(removeRoute);\r\n }\r\n }\r\n else {\r\n const index = matchers.indexOf(matcherRef);\r\n if (index > -1) {\r\n matchers.splice(index, 1);\r\n if (matcherRef.record.name)\r\n matcherMap.delete(matcherRef.record.name);\r\n matcherRef.children.forEach(removeRoute);\r\n matcherRef.alias.forEach(removeRoute);\r\n }\r\n }\r\n }\r\n function getRoutes() {\r\n return matchers;\r\n }\r\n function insertMatcher(matcher) {\r\n let i = 0;\r\n // console.log('i is', { i })\r\n while (i < matchers.length &&\r\n comparePathParserScore(matcher, matchers[i]) >= 0)\r\n i++;\r\n // console.log('END i is', { i })\r\n // while (i < matchers.length && matcher.score <= matchers[i].score) i++\r\n matchers.splice(i, 0, matcher);\r\n // only add the original record to the name map\r\n if (matcher.record.name && !isAliasRecord(matcher))\r\n matcherMap.set(matcher.record.name, matcher);\r\n }\r\n function resolve(location, currentLocation) {\r\n let matcher;\r\n let params = {};\r\n let path;\r\n let name;\r\n if ('name' in location && location.name) {\r\n matcher = matcherMap.get(location.name);\r\n if (!matcher)\r\n throw createRouterError(1 /* MATCHER_NOT_FOUND */, {\r\n location,\r\n });\r\n name = matcher.record.name;\r\n params = assign(\r\n // paramsFromLocation is a new object\r\n paramsFromLocation(currentLocation.params, \r\n // only keep params that exist in the resolved location\r\n // TODO: only keep optional params coming from a parent record\r\n matcher.keys.filter(k => !k.optional).map(k => k.name)), location.params);\r\n // throws if cannot be stringified\r\n path = matcher.stringify(params);\r\n }\r\n else if ('path' in location) {\r\n // no need to resolve the path with the matcher as it was provided\r\n // this also allows the user to control the encoding\r\n path = location.path;\r\n if ((process.env.NODE_ENV !== 'production') && !path.startsWith('/')) {\r\n warn(`The Matcher cannot resolve relative paths but received \"${path}\". Unless you directly called \\`matcher.resolve(\"${path}\")\\`, this is probably a bug in vue-router. Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/vue-router-next.`);\r\n }\r\n matcher = matchers.find(m => m.re.test(path));\r\n // matcher should have a value after the loop\r\n if (matcher) {\r\n // TODO: dev warning of unused params if provided\r\n // we know the matcher works because we tested the regexp\r\n params = matcher.parse(path);\r\n name = matcher.record.name;\r\n }\r\n // location is a relative path\r\n }\r\n else {\r\n // match by name or path of current route\r\n matcher = currentLocation.name\r\n ? matcherMap.get(currentLocation.name)\r\n : matchers.find(m => m.re.test(currentLocation.path));\r\n if (!matcher)\r\n throw createRouterError(1 /* MATCHER_NOT_FOUND */, {\r\n location,\r\n currentLocation,\r\n });\r\n name = matcher.record.name;\r\n // since we are navigating to the same location, we don't need to pick the\r\n // params like when `name` is provided\r\n params = assign({}, currentLocation.params, location.params);\r\n path = matcher.stringify(params);\r\n }\r\n const matched = [];\r\n let parentMatcher = matcher;\r\n while (parentMatcher) {\r\n // reversed order so parents are at the beginning\r\n matched.unshift(parentMatcher.record);\r\n parentMatcher = parentMatcher.parent;\r\n }\r\n return {\r\n name,\r\n path,\r\n params,\r\n matched,\r\n meta: mergeMetaFields(matched),\r\n };\r\n }\r\n // add initial routes\r\n routes.forEach(route => addRoute(route));\r\n return { addRoute, resolve, removeRoute, getRoutes, getRecordMatcher };\r\n}\r\nfunction paramsFromLocation(params, keys) {\r\n const newParams = {};\r\n for (const key of keys) {\r\n if (key in params)\r\n newParams[key] = params[key];\r\n }\r\n return newParams;\r\n}\r\n/**\r\n * Normalizes a RouteRecordRaw. Creates a copy\r\n *\r\n * @param record\r\n * @returns the normalized version\r\n */\r\nfunction normalizeRouteRecord(record) {\r\n return {\r\n path: record.path,\r\n redirect: record.redirect,\r\n name: record.name,\r\n meta: record.meta || {},\r\n aliasOf: undefined,\r\n beforeEnter: record.beforeEnter,\r\n props: normalizeRecordProps(record),\r\n children: record.children || [],\r\n instances: {},\r\n leaveGuards: new Set(),\r\n updateGuards: new Set(),\r\n enterCallbacks: {},\r\n components: 'components' in record\r\n ? record.components || {}\r\n : { default: record.component },\r\n };\r\n}\r\n/**\r\n * Normalize the optional `props` in a record to always be an object similar to\r\n * components. Also accept a boolean for components.\r\n * @param record\r\n */\r\nfunction normalizeRecordProps(record) {\r\n const propsObject = {};\r\n // props does not exist on redirect records but we can set false directly\r\n const props = record.props || false;\r\n if ('component' in record) {\r\n propsObject.default = props;\r\n }\r\n else {\r\n // NOTE: we could also allow a function to be applied to every component.\r\n // Would need user feedback for use cases\r\n for (const name in record.components)\r\n propsObject[name] = typeof props === 'boolean' ? props : props[name];\r\n }\r\n return propsObject;\r\n}\r\n/**\r\n * Checks if a record or any of its parent is an alias\r\n * @param record\r\n */\r\nfunction isAliasRecord(record) {\r\n while (record) {\r\n if (record.record.aliasOf)\r\n return true;\r\n record = record.parent;\r\n }\r\n return false;\r\n}\r\n/**\r\n * Merge meta fields of an array of records\r\n *\r\n * @param matched - array of matched records\r\n */\r\nfunction mergeMetaFields(matched) {\r\n return matched.reduce((meta, record) => assign(meta, record.meta), {});\r\n}\r\nfunction mergeOptions(defaults, partialOptions) {\r\n const options = {};\r\n for (const key in defaults) {\r\n options[key] = key in partialOptions ? partialOptions[key] : defaults[key];\r\n }\r\n return options;\r\n}\r\nfunction isSameParam(a, b) {\r\n return (a.name === b.name &&\r\n a.optional === b.optional &&\r\n a.repeatable === b.repeatable);\r\n}\r\n/**\r\n * Check if a path and its alias have the same required params\r\n *\r\n * @param a - original record\r\n * @param b - alias record\r\n */\r\nfunction checkSameParams(a, b) {\r\n for (const key of a.keys) {\r\n if (!key.optional && !b.keys.find(isSameParam.bind(null, key)))\r\n return warn(`Alias \"${b.record.path}\" and the original record: \"${a.record.path}\" should have the exact same param named \"${key.name}\"`);\r\n }\r\n for (const key of b.keys) {\r\n if (!key.optional && !a.keys.find(isSameParam.bind(null, key)))\r\n return warn(`Alias \"${b.record.path}\" and the original record: \"${a.record.path}\" should have the exact same param named \"${key.name}\"`);\r\n }\r\n}\r\nfunction checkMissingParamsInAbsolutePath(record, parent) {\r\n for (const key of parent.keys) {\r\n if (!record.keys.find(isSameParam.bind(null, key)))\r\n return warn(`Absolute path \"${record.record.path}\" should have the exact same param named \"${key.name}\" as its parent \"${parent.record.path}\".`);\r\n }\r\n}\n\n/**\r\n * Encoding Rules ␣ = Space Path: ␣ \" < > # ? { } Query: ␣ \" < > # & = Hash: ␣ \"\r\n * < > `\r\n *\r\n * On top of that, the RFC3986 (https://tools.ietf.org/html/rfc3986#section-2.2)\r\n * defines some extra characters to be encoded. Most browsers do not encode them\r\n * in encodeURI https://github.com/whatwg/url/issues/369, so it may be safer to\r\n * also encode `!'()*`. Leaving unencoded only ASCII alphanumeric(`a-zA-Z0-9`)\r\n * plus `-._~`. This extra safety should be applied to query by patching the\r\n * string returned by encodeURIComponent encodeURI also encodes `[\\]^`. `\\`\r\n * should be encoded to avoid ambiguity. Browsers (IE, FF, C) transform a `\\`\r\n * into a `/` if directly typed in. The _backtick_ (`````) should also be\r\n * encoded everywhere because some browsers like FF encode it when directly\r\n * written while others don't. Safari and IE don't encode ``\"<>{}``` in hash.\r\n */\r\n// const EXTRA_RESERVED_RE = /[!'()*]/g\r\n// const encodeReservedReplacer = (c: string) => '%' + c.charCodeAt(0).toString(16)\r\nconst HASH_RE = /#/g; // %23\r\nconst AMPERSAND_RE = /&/g; // %26\r\nconst SLASH_RE = /\\//g; // %2F\r\nconst EQUAL_RE = /=/g; // %3D\r\nconst IM_RE = /\\?/g; // %3F\r\nconst PLUS_RE = /\\+/g; // %2B\r\n/**\r\n * NOTE: It's not clear to me if we should encode the + symbol in queries, it\r\n * seems to be less flexible than not doing so and I can't find out the legacy\r\n * systems requiring this for regular requests like text/html. In the standard,\r\n * the encoding of the plus character is only mentioned for\r\n * application/x-www-form-urlencoded\r\n * (https://url.spec.whatwg.org/#urlencoded-parsing) and most browsers seems lo\r\n * leave the plus character as is in queries. To be more flexible, we allow the\r\n * plus character on the query but it can also be manually encoded by the user.\r\n *\r\n * Resources:\r\n * - https://url.spec.whatwg.org/#urlencoded-parsing\r\n * - https://stackoverflow.com/questions/1634271/url-encoding-the-space-character-or-20\r\n */\r\nconst ENC_BRACKET_OPEN_RE = /%5B/g; // [\r\nconst ENC_BRACKET_CLOSE_RE = /%5D/g; // ]\r\nconst ENC_CARET_RE = /%5E/g; // ^\r\nconst ENC_BACKTICK_RE = /%60/g; // `\r\nconst ENC_CURLY_OPEN_RE = /%7B/g; // {\r\nconst ENC_PIPE_RE = /%7C/g; // |\r\nconst ENC_CURLY_CLOSE_RE = /%7D/g; // }\r\nconst ENC_SPACE_RE = /%20/g; // }\r\n/**\r\n * Encode characters that need to be encoded on the path, search and hash\r\n * sections of the URL.\r\n *\r\n * @internal\r\n * @param text - string to encode\r\n * @returns encoded string\r\n */\r\nfunction commonEncode(text) {\r\n return encodeURI('' + text)\r\n .replace(ENC_PIPE_RE, '|')\r\n .replace(ENC_BRACKET_OPEN_RE, '[')\r\n .replace(ENC_BRACKET_CLOSE_RE, ']');\r\n}\r\n/**\r\n * Encode characters that need to be encoded on the hash section of the URL.\r\n *\r\n * @param text - string to encode\r\n * @returns encoded string\r\n */\r\nfunction encodeHash(text) {\r\n return commonEncode(text)\r\n .replace(ENC_CURLY_OPEN_RE, '{')\r\n .replace(ENC_CURLY_CLOSE_RE, '}')\r\n .replace(ENC_CARET_RE, '^');\r\n}\r\n/**\r\n * Encode characters that need to be encoded query values on the query\r\n * section of the URL.\r\n *\r\n * @param text - string to encode\r\n * @returns encoded string\r\n */\r\nfunction encodeQueryValue(text) {\r\n return (commonEncode(text)\r\n // Encode the space as +, encode the + to differentiate it from the space\r\n .replace(PLUS_RE, '%2B')\r\n .replace(ENC_SPACE_RE, '+')\r\n .replace(HASH_RE, '%23')\r\n .replace(AMPERSAND_RE, '%26')\r\n .replace(ENC_BACKTICK_RE, '`')\r\n .replace(ENC_CURLY_OPEN_RE, '{')\r\n .replace(ENC_CURLY_CLOSE_RE, '}')\r\n .replace(ENC_CARET_RE, '^'));\r\n}\r\n/**\r\n * Like `encodeQueryValue` but also encodes the `=` character.\r\n *\r\n * @param text - string to encode\r\n */\r\nfunction encodeQueryKey(text) {\r\n return encodeQueryValue(text).replace(EQUAL_RE, '%3D');\r\n}\r\n/**\r\n * Encode characters that need to be encoded on the path section of the URL.\r\n *\r\n * @param text - string to encode\r\n * @returns encoded string\r\n */\r\nfunction encodePath(text) {\r\n return commonEncode(text).replace(HASH_RE, '%23').replace(IM_RE, '%3F');\r\n}\r\n/**\r\n * Encode characters that need to be encoded on the path section of the URL as a\r\n * param. This function encodes everything {@link encodePath} does plus the\r\n * slash (`/`) character. If `text` is `null` or `undefined`, returns an empty\r\n * string instead.\r\n *\r\n * @param text - string to encode\r\n * @returns encoded string\r\n */\r\nfunction encodeParam(text) {\r\n return text == null ? '' : encodePath(text).replace(SLASH_RE, '%2F');\r\n}\r\n/**\r\n * Decode text using `decodeURIComponent`. Returns the original text if it\r\n * fails.\r\n *\r\n * @param text - string to decode\r\n * @returns decoded string\r\n */\r\nfunction decode(text) {\r\n try {\r\n return decodeURIComponent('' + text);\r\n }\r\n catch (err) {\r\n (process.env.NODE_ENV !== 'production') && warn(`Error decoding \"${text}\". Using original value`);\r\n }\r\n return '' + text;\r\n}\n\n/**\r\n * Transforms a queryString into a {@link LocationQuery} object. Accept both, a\r\n * version with the leading `?` and without Should work as URLSearchParams\r\n\n * @internal\r\n *\r\n * @param search - search string to parse\r\n * @returns a query object\r\n */\r\nfunction parseQuery(search) {\r\n const query = {};\r\n // avoid creating an object with an empty key and empty value\r\n // because of split('&')\r\n if (search === '' || search === '?')\r\n return query;\r\n const hasLeadingIM = search[0] === '?';\r\n const searchParams = (hasLeadingIM ? search.slice(1) : search).split('&');\r\n for (let i = 0; i < searchParams.length; ++i) {\r\n // pre decode the + into space\r\n const searchParam = searchParams[i].replace(PLUS_RE, ' ');\r\n // allow the = character\r\n const eqPos = searchParam.indexOf('=');\r\n const key = decode(eqPos < 0 ? searchParam : searchParam.slice(0, eqPos));\r\n const value = eqPos < 0 ? null : decode(searchParam.slice(eqPos + 1));\r\n if (key in query) {\r\n // an extra variable for ts types\r\n let currentValue = query[key];\r\n if (!Array.isArray(currentValue)) {\r\n currentValue = query[key] = [currentValue];\r\n }\r\n currentValue.push(value);\r\n }\r\n else {\r\n query[key] = value;\r\n }\r\n }\r\n return query;\r\n}\r\n/**\r\n * Stringifies a {@link LocationQueryRaw} object. Like `URLSearchParams`, it\r\n * doesn't prepend a `?`\r\n *\r\n * @internal\r\n *\r\n * @param query - query object to stringify\r\n * @returns string version of the query without the leading `?`\r\n */\r\nfunction stringifyQuery(query) {\r\n let search = '';\r\n for (let key in query) {\r\n const value = query[key];\r\n key = encodeQueryKey(key);\r\n if (value == null) {\r\n // only null adds the value\r\n if (value !== undefined) {\r\n search += (search.length ? '&' : '') + key;\r\n }\r\n continue;\r\n }\r\n // keep null values\r\n const values = Array.isArray(value)\r\n ? value.map(v => v && encodeQueryValue(v))\r\n : [value && encodeQueryValue(value)];\r\n values.forEach(value => {\r\n // skip undefined values in arrays as if they were not present\r\n // smaller code than using filter\r\n if (value !== undefined) {\r\n // only append & with non-empty search\r\n search += (search.length ? '&' : '') + key;\r\n if (value != null)\r\n search += '=' + value;\r\n }\r\n });\r\n }\r\n return search;\r\n}\r\n/**\r\n * Transforms a {@link LocationQueryRaw} into a {@link LocationQuery} by casting\r\n * numbers into strings, removing keys with an undefined value and replacing\r\n * undefined with null in arrays\r\n *\r\n * @param query - query object to normalize\r\n * @returns a normalized query object\r\n */\r\nfunction normalizeQuery(query) {\r\n const normalizedQuery = {};\r\n for (const key in query) {\r\n const value = query[key];\r\n if (value !== undefined) {\r\n normalizedQuery[key] = Array.isArray(value)\r\n ? value.map(v => (v == null ? null : '' + v))\r\n : value == null\r\n ? value\r\n : '' + value;\r\n }\r\n }\r\n return normalizedQuery;\r\n}\n\n/**\r\n * Create a list of callbacks that can be reset. Used to create before and after navigation guards list\r\n */\r\nfunction useCallbacks() {\r\n let handlers = [];\r\n function add(handler) {\r\n handlers.push(handler);\r\n return () => {\r\n const i = handlers.indexOf(handler);\r\n if (i > -1)\r\n handlers.splice(i, 1);\r\n };\r\n }\r\n function reset() {\r\n handlers = [];\r\n }\r\n return {\r\n add,\r\n list: () => handlers,\r\n reset,\r\n };\r\n}\n\nfunction registerGuard(record, name, guard) {\r\n const removeFromList = () => {\r\n record[name].delete(guard);\r\n };\r\n onUnmounted(removeFromList);\r\n onDeactivated(removeFromList);\r\n onActivated(() => {\r\n record[name].add(guard);\r\n });\r\n record[name].add(guard);\r\n}\r\n/**\r\n * Add a navigation guard that triggers whenever the component for the current\r\n * location is about to be left. Similar to {@link beforeRouteLeave} but can be\r\n * used in any component. The guard is removed when the component is unmounted.\r\n *\r\n * @param leaveGuard - {@link NavigationGuard}\r\n */\r\nfunction onBeforeRouteLeave(leaveGuard) {\r\n if ((process.env.NODE_ENV !== 'production') && !getCurrentInstance()) {\r\n warn('getCurrentInstance() returned null. onBeforeRouteLeave() must be called at the top of a setup function');\r\n return;\r\n }\r\n const activeRecord = inject(matchedRouteKey, \r\n // to avoid warning\r\n {}).value;\r\n if (!activeRecord) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn('No active route record was found when calling `onBeforeRouteLeave()`. Make sure you call this function inside of a component child of <router-view>. Maybe you called it inside of App.vue?');\r\n return;\r\n }\r\n registerGuard(activeRecord, 'leaveGuards', leaveGuard);\r\n}\r\n/**\r\n * Add a navigation guard that triggers whenever the current location is about\r\n * to be updated. Similar to {@link beforeRouteUpdate} but can be used in any\r\n * component. The guard is removed when the component is unmounted.\r\n *\r\n * @param updateGuard - {@link NavigationGuard}\r\n */\r\nfunction onBeforeRouteUpdate(updateGuard) {\r\n if ((process.env.NODE_ENV !== 'production') && !getCurrentInstance()) {\r\n warn('getCurrentInstance() returned null. onBeforeRouteUpdate() must be called at the top of a setup function');\r\n return;\r\n }\r\n const activeRecord = inject(matchedRouteKey, \r\n // to avoid warning\r\n {}).value;\r\n if (!activeRecord) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn('No active route record was found when calling `onBeforeRouteUpdate()`. Make sure you call this function inside of a component child of <router-view>. Maybe you called it inside of App.vue?');\r\n return;\r\n }\r\n registerGuard(activeRecord, 'updateGuards', updateGuard);\r\n}\r\nfunction guardToPromiseFn(guard, to, from, record, name) {\r\n // keep a reference to the enterCallbackArray to prevent pushing callbacks if a new navigation took place\r\n const enterCallbackArray = record &&\r\n // name is defined if record is because of the function overload\r\n (record.enterCallbacks[name] = record.enterCallbacks[name] || []);\r\n return () => new Promise((resolve, reject) => {\r\n const next = (valid) => {\r\n if (valid === false)\r\n reject(createRouterError(4 /* NAVIGATION_ABORTED */, {\r\n from,\r\n to,\r\n }));\r\n else if (valid instanceof Error) {\r\n reject(valid);\r\n }\r\n else if (isRouteLocation(valid)) {\r\n reject(createRouterError(2 /* NAVIGATION_GUARD_REDIRECT */, {\r\n from: to,\r\n to: valid,\r\n }));\r\n }\r\n else {\r\n if (enterCallbackArray &&\r\n // since enterCallbackArray is truthy, both record and name also are\r\n record.enterCallbacks[name] === enterCallbackArray &&\r\n typeof valid === 'function')\r\n enterCallbackArray.push(valid);\r\n resolve();\r\n }\r\n };\r\n // wrapping with Promise.resolve allows it to work with both async and sync guards\r\n const guardReturn = guard.call(record && record.instances[name], to, from, (process.env.NODE_ENV !== 'production') ? canOnlyBeCalledOnce(next, to, from) : next);\r\n let guardCall = Promise.resolve(guardReturn);\r\n if (guard.length < 3)\r\n guardCall = guardCall.then(next);\r\n if ((process.env.NODE_ENV !== 'production') && guard.length > 2) {\r\n const message = `The \"next\" callback was never called inside of ${guard.name ? '\"' + guard.name + '\"' : ''}:\\n${guard.toString()}\\n. If you are returning a value instead of calling \"next\", make sure to remove the \"next\" parameter from your function.`;\r\n if (typeof guardReturn === 'object' && 'then' in guardReturn) {\r\n guardCall = guardCall.then(resolvedValue => {\r\n // @ts-expect-error: _called is added at canOnlyBeCalledOnce\r\n if (!next._called) {\r\n warn(message);\r\n return Promise.reject(new Error('Invalid navigation guard'));\r\n }\r\n return resolvedValue;\r\n });\r\n // TODO: test me!\r\n }\r\n else if (guardReturn !== undefined) {\r\n // @ts-expect-error: _called is added at canOnlyBeCalledOnce\r\n if (!next._called) {\r\n warn(message);\r\n reject(new Error('Invalid navigation guard'));\r\n return;\r\n }\r\n }\r\n }\r\n guardCall.catch(err => reject(err));\r\n });\r\n}\r\nfunction canOnlyBeCalledOnce(next, to, from) {\r\n let called = 0;\r\n return function () {\r\n if (called++ === 1)\r\n warn(`The \"next\" callback was called more than once in one navigation guard when going from \"${from.fullPath}\" to \"${to.fullPath}\". It should be called exactly one time in each navigation guard. This will fail in production.`);\r\n // @ts-expect-error: we put it in the original one because it's easier to check\r\n next._called = true;\r\n if (called === 1)\r\n next.apply(null, arguments);\r\n };\r\n}\r\nfunction extractComponentsGuards(matched, guardType, to, from) {\r\n const guards = [];\r\n for (const record of matched) {\r\n for (const name in record.components) {\r\n let rawComponent = record.components[name];\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (!rawComponent ||\r\n (typeof rawComponent !== 'object' &&\r\n typeof rawComponent !== 'function')) {\r\n warn(`Component \"${name}\" in record with path \"${record.path}\" is not` +\r\n ` a valid component. Received \"${String(rawComponent)}\".`);\r\n // throw to ensure we stop here but warn to ensure the message isn't\r\n // missed by the user\r\n throw new Error('Invalid route component');\r\n }\r\n else if ('then' in rawComponent) {\r\n // warn if user wrote import('/component.vue') instead of () =>\r\n // import('./component.vue')\r\n warn(`Component \"${name}\" in record with path \"${record.path}\" is a ` +\r\n `Promise instead of a function that returns a Promise. Did you ` +\r\n `write \"import('./MyPage.vue')\" instead of ` +\r\n `\"() => import('./MyPage.vue')\" ? This will break in ` +\r\n `production if not fixed.`);\r\n const promise = rawComponent;\r\n rawComponent = () => promise;\r\n }\r\n else if (rawComponent.__asyncLoader &&\r\n // warn only once per component\r\n !rawComponent.__warnedDefineAsync) {\r\n rawComponent.__warnedDefineAsync = true;\r\n warn(`Component \"${name}\" in record with path \"${record.path}\" is defined ` +\r\n `using \"defineAsyncComponent()\". ` +\r\n `Write \"() => import('./MyPage.vue')\" instead of ` +\r\n `\"defineAsyncComponent(() => import('./MyPage.vue'))\".`);\r\n }\r\n }\r\n // skip update and leave guards if the route component is not mounted\r\n if (guardType !== 'beforeRouteEnter' && !record.instances[name])\r\n continue;\r\n if (isRouteComponent(rawComponent)) {\r\n // __vccOpts is added by vue-class-component and contain the regular options\r\n const options = rawComponent.__vccOpts || rawComponent;\r\n const guard = options[guardType];\r\n guard && guards.push(guardToPromiseFn(guard, to, from, record, name));\r\n }\r\n else {\r\n // start requesting the chunk already\r\n let componentPromise = rawComponent();\r\n if ((process.env.NODE_ENV !== 'production') && !('catch' in componentPromise)) {\r\n warn(`Component \"${name}\" in record with path \"${record.path}\" is a function that does not return a Promise. If you were passing a functional component, make sure to add a \"displayName\" to the component. This will break in production if not fixed.`);\r\n componentPromise = Promise.resolve(componentPromise);\r\n }\r\n guards.push(() => componentPromise.then(resolved => {\r\n if (!resolved)\r\n return Promise.reject(new Error(`Couldn't resolve component \"${name}\" at \"${record.path}\"`));\r\n const resolvedComponent = isESModule(resolved)\r\n ? resolved.default\r\n : resolved;\r\n // replace the function with the resolved component\r\n record.components[name] = resolvedComponent;\r\n // __vccOpts is added by vue-class-component and contain the regular options\r\n const options = resolvedComponent.__vccOpts || resolvedComponent;\r\n const guard = options[guardType];\r\n return guard && guardToPromiseFn(guard, to, from, record, name)();\r\n }));\r\n }\r\n }\r\n }\r\n return guards;\r\n}\r\n/**\r\n * Allows differentiating lazy components from functional components and vue-class-component\r\n *\r\n * @param component\r\n */\r\nfunction isRouteComponent(component) {\r\n return (typeof component === 'object' ||\r\n 'displayName' in component ||\r\n 'props' in component ||\r\n '__vccOpts' in component);\r\n}\n\n// TODO: we could allow currentRoute as a prop to expose `isActive` and\r\n// `isExactActive` behavior should go through an RFC\r\nfunction useLink(props) {\r\n const router = inject(routerKey);\r\n const currentRoute = inject(routeLocationKey);\r\n const route = computed(() => router.resolve(unref(props.to)));\r\n const activeRecordIndex = computed(() => {\r\n const { matched } = route.value;\r\n const { length } = matched;\r\n const routeMatched = matched[length - 1];\r\n const currentMatched = currentRoute.matched;\r\n if (!routeMatched || !currentMatched.length)\r\n return -1;\r\n const index = currentMatched.findIndex(isSameRouteRecord.bind(null, routeMatched));\r\n if (index > -1)\r\n return index;\r\n // possible parent record\r\n const parentRecordPath = getOriginalPath(matched[length - 2]);\r\n return (\r\n // we are dealing with nested routes\r\n length > 1 &&\r\n // if the parent and matched route have the same path, this link is\r\n // referring to the empty child. Or we currently are on a different\r\n // child of the same parent\r\n getOriginalPath(routeMatched) === parentRecordPath &&\r\n // avoid comparing the child with its parent\r\n currentMatched[currentMatched.length - 1].path !== parentRecordPath\r\n ? currentMatched.findIndex(isSameRouteRecord.bind(null, matched[length - 2]))\r\n : index);\r\n });\r\n const isActive = computed(() => activeRecordIndex.value > -1 &&\r\n includesParams(currentRoute.params, route.value.params));\r\n const isExactActive = computed(() => activeRecordIndex.value > -1 &&\r\n activeRecordIndex.value === currentRoute.matched.length - 1 &&\r\n isSameRouteLocationParams(currentRoute.params, route.value.params));\r\n function navigate(e = {}) {\r\n if (guardEvent(e)) {\r\n return router[unref(props.replace) ? 'replace' : 'push'](unref(props.to)\r\n // avoid uncaught errors are they are logged anyway\r\n ).catch(noop);\r\n }\r\n return Promise.resolve();\r\n }\r\n // devtools only\r\n if (((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) && isBrowser) {\r\n const instance = getCurrentInstance();\r\n if (instance) {\r\n const linkContextDevtools = {\r\n route: route.value,\r\n isActive: isActive.value,\r\n isExactActive: isExactActive.value,\r\n };\r\n // @ts-expect-error: this is internal\r\n instance.__vrl_devtools = instance.__vrl_devtools || [];\r\n // @ts-expect-error: this is internal\r\n instance.__vrl_devtools.push(linkContextDevtools);\r\n watchEffect(() => {\r\n linkContextDevtools.route = route.value;\r\n linkContextDevtools.isActive = isActive.value;\r\n linkContextDevtools.isExactActive = isExactActive.value;\r\n }, { flush: 'post' });\r\n }\r\n }\r\n return {\r\n route,\r\n href: computed(() => route.value.href),\r\n isActive,\r\n isExactActive,\r\n navigate,\r\n };\r\n}\r\nconst RouterLinkImpl = /*#__PURE__*/ defineComponent({\r\n name: 'RouterLink',\r\n props: {\r\n to: {\r\n type: [String, Object],\r\n required: true,\r\n },\r\n replace: Boolean,\r\n activeClass: String,\r\n // inactiveClass: String,\r\n exactActiveClass: String,\r\n custom: Boolean,\r\n ariaCurrentValue: {\r\n type: String,\r\n default: 'page',\r\n },\r\n },\r\n useLink,\r\n setup(props, { slots }) {\r\n const link = reactive(useLink(props));\r\n const { options } = inject(routerKey);\r\n const elClass = computed(() => ({\r\n [getLinkClass(props.activeClass, options.linkActiveClass, 'router-link-active')]: link.isActive,\r\n // [getLinkClass(\r\n // props.inactiveClass,\r\n // options.linkInactiveClass,\r\n // 'router-link-inactive'\r\n // )]: !link.isExactActive,\r\n [getLinkClass(props.exactActiveClass, options.linkExactActiveClass, 'router-link-exact-active')]: link.isExactActive,\r\n }));\r\n return () => {\r\n const children = slots.default && slots.default(link);\r\n return props.custom\r\n ? children\r\n : h('a', {\r\n 'aria-current': link.isExactActive\r\n ? props.ariaCurrentValue\r\n : null,\r\n href: link.href,\r\n // this would override user added attrs but Vue will still add\r\n // the listener so we end up triggering both\r\n onClick: link.navigate,\r\n class: elClass.value,\r\n }, children);\r\n };\r\n },\r\n});\r\n// export the public type for h/tsx inference\r\n// also to avoid inline import() in generated d.ts files\r\n/**\r\n * Component to render a link that triggers a navigation on click.\r\n */\r\nconst RouterLink = RouterLinkImpl;\r\nfunction guardEvent(e) {\r\n // don't redirect with control keys\r\n if (e.metaKey || e.altKey || e.ctrlKey || e.shiftKey)\r\n return;\r\n // don't redirect when preventDefault called\r\n if (e.defaultPrevented)\r\n return;\r\n // don't redirect on right click\r\n if (e.button !== undefined && e.button !== 0)\r\n return;\r\n // don't redirect if `target=\"_blank\"`\r\n // @ts-expect-error getAttribute does exist\r\n if (e.currentTarget && e.currentTarget.getAttribute) {\r\n // @ts-expect-error getAttribute exists\r\n const target = e.currentTarget.getAttribute('target');\r\n if (/\\b_blank\\b/i.test(target))\r\n return;\r\n }\r\n // this may be a Weex event which doesn't have this method\r\n if (e.preventDefault)\r\n e.preventDefault();\r\n return true;\r\n}\r\nfunction includesParams(outer, inner) {\r\n for (const key in inner) {\r\n const innerValue = inner[key];\r\n const outerValue = outer[key];\r\n if (typeof innerValue === 'string') {\r\n if (innerValue !== outerValue)\r\n return false;\r\n }\r\n else {\r\n if (!Array.isArray(outerValue) ||\r\n outerValue.length !== innerValue.length ||\r\n innerValue.some((value, i) => value !== outerValue[i]))\r\n return false;\r\n }\r\n }\r\n return true;\r\n}\r\n/**\r\n * Get the original path value of a record by following its aliasOf\r\n * @param record\r\n */\r\nfunction getOriginalPath(record) {\r\n return record ? (record.aliasOf ? record.aliasOf.path : record.path) : '';\r\n}\r\n/**\r\n * Utility class to get the active class based on defaults.\r\n * @param propClass\r\n * @param globalClass\r\n * @param defaultClass\r\n */\r\nconst getLinkClass = (propClass, globalClass, defaultClass) => propClass != null\r\n ? propClass\r\n : globalClass != null\r\n ? globalClass\r\n : defaultClass;\n\nconst RouterViewImpl = /*#__PURE__*/ defineComponent({\r\n name: 'RouterView',\r\n // #674 we manually inherit them\r\n inheritAttrs: false,\r\n props: {\r\n name: {\r\n type: String,\r\n default: 'default',\r\n },\r\n route: Object,\r\n },\r\n setup(props, { attrs, slots }) {\r\n (process.env.NODE_ENV !== 'production') && warnDeprecatedUsage();\r\n const injectedRoute = inject(routerViewLocationKey);\r\n const routeToDisplay = computed(() => props.route || injectedRoute.value);\r\n const depth = inject(viewDepthKey, 0);\r\n const matchedRouteRef = computed(() => routeToDisplay.value.matched[depth]);\r\n provide(viewDepthKey, depth + 1);\r\n provide(matchedRouteKey, matchedRouteRef);\r\n provide(routerViewLocationKey, routeToDisplay);\r\n const viewRef = ref();\r\n // watch at the same time the component instance, the route record we are\r\n // rendering, and the name\r\n watch(() => [viewRef.value, matchedRouteRef.value, props.name], ([instance, to, name], [oldInstance, from, oldName]) => {\r\n // copy reused instances\r\n if (to) {\r\n // this will update the instance for new instances as well as reused\r\n // instances when navigating to a new route\r\n to.instances[name] = instance;\r\n // the component instance is reused for a different route or name so\r\n // we copy any saved update or leave guards. With async setup, the\r\n // mounting component will mount before the matchedRoute changes,\r\n // making instance === oldInstance, so we check if guards have been\r\n // added before. This works because we remove guards when\r\n // unmounting/deactivating components\r\n if (from && from !== to && instance && instance === oldInstance) {\r\n if (!to.leaveGuards.size) {\r\n to.leaveGuards = from.leaveGuards;\r\n }\r\n if (!to.updateGuards.size) {\r\n to.updateGuards = from.updateGuards;\r\n }\r\n }\r\n }\r\n // trigger beforeRouteEnter next callbacks\r\n if (instance &&\r\n to &&\r\n // if there is no instance but to and from are the same this might be\r\n // the first visit\r\n (!from || !isSameRouteRecord(to, from) || !oldInstance)) {\r\n (to.enterCallbacks[name] || []).forEach(callback => callback(instance));\r\n }\r\n }, { flush: 'post' });\r\n return () => {\r\n const route = routeToDisplay.value;\r\n const matchedRoute = matchedRouteRef.value;\r\n const ViewComponent = matchedRoute && matchedRoute.components[props.name];\r\n // we need the value at the time we render because when we unmount, we\r\n // navigated to a different location so the value is different\r\n const currentName = props.name;\r\n if (!ViewComponent) {\r\n return normalizeSlot(slots.default, { Component: ViewComponent, route });\r\n }\r\n // props from route configuration\r\n const routePropsOption = matchedRoute.props[props.name];\r\n const routeProps = routePropsOption\r\n ? routePropsOption === true\r\n ? route.params\r\n : typeof routePropsOption === 'function'\r\n ? routePropsOption(route)\r\n : routePropsOption\r\n : null;\r\n const onVnodeUnmounted = vnode => {\r\n // remove the instance reference to prevent leak\r\n if (vnode.component.isUnmounted) {\r\n matchedRoute.instances[currentName] = null;\r\n }\r\n };\r\n const component = h(ViewComponent, assign({}, routeProps, attrs, {\r\n onVnodeUnmounted,\r\n ref: viewRef,\r\n }));\r\n if (((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) &&\r\n isBrowser &&\r\n component.ref) {\r\n // TODO: can display if it's an alias, its props\r\n const info = {\r\n depth,\r\n name: matchedRoute.name,\r\n path: matchedRoute.path,\r\n meta: matchedRoute.meta,\r\n };\r\n const internalInstances = Array.isArray(component.ref)\r\n ? component.ref.map(r => r.i)\r\n : [component.ref.i];\r\n internalInstances.forEach(instance => {\r\n // @ts-expect-error\r\n instance.__vrv_devtools = info;\r\n });\r\n }\r\n return (\r\n // pass the vnode to the slot as a prop.\r\n // h and <component :is=\"...\"> both accept vnodes\r\n normalizeSlot(slots.default, { Component: component, route }) ||\r\n component);\r\n };\r\n },\r\n});\r\nfunction normalizeSlot(slot, data) {\r\n if (!slot)\r\n return null;\r\n const slotContent = slot(data);\r\n return slotContent.length === 1 ? slotContent[0] : slotContent;\r\n}\r\n// export the public type for h/tsx inference\r\n// also to avoid inline import() in generated d.ts files\r\n/**\r\n * Component to display the current route the user is at.\r\n */\r\nconst RouterView = RouterViewImpl;\r\n// warn against deprecated usage with <transition> & <keep-alive>\r\n// due to functional component being no longer eager in Vue 3\r\nfunction warnDeprecatedUsage() {\r\n const instance = getCurrentInstance();\r\n const parentName = instance.parent && instance.parent.type.name;\r\n if (parentName &&\r\n (parentName === 'KeepAlive' || parentName.includes('Transition'))) {\r\n const comp = parentName === 'KeepAlive' ? 'keep-alive' : 'transition';\r\n warn(`<router-view> can no longer be used directly inside <transition> or <keep-alive>.\\n` +\r\n `Use slot props instead:\\n\\n` +\r\n `<router-view v-slot=\"{ Component }\">\\n` +\r\n ` <${comp}>\\n` +\r\n ` <component :is=\"Component\" />\\n` +\r\n ` </${comp}>\\n` +\r\n `</router-view>`);\r\n }\r\n}\n\nfunction formatRouteLocation(routeLocation, tooltip) {\r\n const copy = assign({}, routeLocation, {\r\n // remove variables that can contain vue instances\r\n matched: routeLocation.matched.map(matched => omit(matched, ['instances', 'children', 'aliasOf'])),\r\n });\r\n return {\r\n _custom: {\r\n type: null,\r\n readOnly: true,\r\n display: routeLocation.fullPath,\r\n tooltip,\r\n value: copy,\r\n },\r\n };\r\n}\r\nfunction formatDisplay(display) {\r\n return {\r\n _custom: {\r\n display,\r\n },\r\n };\r\n}\r\n// to support multiple router instances\r\nlet routerId = 0;\r\nfunction addDevtools(app, router, matcher) {\r\n // Take over router.beforeEach and afterEach\r\n // make sure we are not registering the devtool twice\r\n if (router.__hasDevtools)\r\n return;\r\n router.__hasDevtools = true;\r\n // increment to support multiple router instances\r\n const id = routerId++;\r\n setupDevtoolsPlugin({\r\n id: 'org.vuejs.router' + (id ? '.' + id : ''),\r\n label: 'Vue Router',\r\n packageName: 'vue-router',\r\n homepage: 'https://next.router.vuejs.org/',\r\n logo: 'https://vuejs.org/images/icons/favicon-96x96.png',\r\n componentStateTypes: ['Routing'],\r\n app,\r\n }, api => {\r\n // display state added by the router\r\n api.on.inspectComponent((payload, ctx) => {\r\n if (payload.instanceData) {\r\n payload.instanceData.state.push({\r\n type: 'Routing',\r\n key: '$route',\r\n editable: false,\r\n value: formatRouteLocation(router.currentRoute.value, 'Current Route'),\r\n });\r\n }\r\n });\r\n // mark router-link as active and display tags on router views\r\n api.on.visitComponentTree(({ treeNode: node, componentInstance }) => {\r\n if (componentInstance.__vrv_devtools) {\r\n const info = componentInstance.__vrv_devtools;\r\n node.tags.push({\r\n label: (info.name ? `${info.name.toString()}: ` : '') + info.path,\r\n textColor: 0,\r\n tooltip: 'This component is rendered by &lt;router-view&gt;',\r\n backgroundColor: PINK_500,\r\n });\r\n }\r\n // if multiple useLink are used\r\n if (Array.isArray(componentInstance.__vrl_devtools)) {\r\n componentInstance.__devtoolsApi = api;\r\n componentInstance.__vrl_devtools.forEach(devtoolsData => {\r\n let backgroundColor = ORANGE_400;\r\n let tooltip = '';\r\n if (devtoolsData.isExactActive) {\r\n backgroundColor = LIME_500;\r\n tooltip = 'This is exactly active';\r\n }\r\n else if (devtoolsData.isActive) {\r\n backgroundColor = BLUE_600;\r\n tooltip = 'This link is active';\r\n }\r\n node.tags.push({\r\n label: devtoolsData.route.path,\r\n textColor: 0,\r\n tooltip,\r\n backgroundColor,\r\n });\r\n });\r\n }\r\n });\r\n watch(router.currentRoute, () => {\r\n // refresh active state\r\n refreshRoutesView();\r\n api.notifyComponentUpdate();\r\n api.sendInspectorTree(routerInspectorId);\r\n api.sendInspectorState(routerInspectorId);\r\n });\r\n const navigationsLayerId = 'router:navigations:' + id;\r\n api.addTimelineLayer({\r\n id: navigationsLayerId,\r\n label: `Router${id ? ' ' + id : ''} Navigations`,\r\n color: 0x40a8c4,\r\n });\r\n // const errorsLayerId = 'router:errors'\r\n // api.addTimelineLayer({\r\n // id: errorsLayerId,\r\n // label: 'Router Errors',\r\n // color: 0xea5455,\r\n // })\r\n router.onError((error, to) => {\r\n api.addTimelineEvent({\r\n layerId: navigationsLayerId,\r\n event: {\r\n title: 'Error during Navigation',\r\n subtitle: to.fullPath,\r\n logType: 'error',\r\n time: Date.now(),\r\n data: { error },\r\n groupId: to.meta.__navigationId,\r\n },\r\n });\r\n });\r\n // attached to `meta` and used to group events\r\n let navigationId = 0;\r\n router.beforeEach((to, from) => {\r\n const data = {\r\n guard: formatDisplay('beforeEach'),\r\n from: formatRouteLocation(from, 'Current Location during this navigation'),\r\n to: formatRouteLocation(to, 'Target location'),\r\n };\r\n // Used to group navigations together, hide from devtools\r\n Object.defineProperty(to.meta, '__navigationId', {\r\n value: navigationId++,\r\n });\r\n api.addTimelineEvent({\r\n layerId: navigationsLayerId,\r\n event: {\r\n time: Date.now(),\r\n title: 'Start of navigation',\r\n subtitle: to.fullPath,\r\n data,\r\n groupId: to.meta.__navigationId,\r\n },\r\n });\r\n });\r\n router.afterEach((to, from, failure) => {\r\n const data = {\r\n guard: formatDisplay('afterEach'),\r\n };\r\n if (failure) {\r\n data.failure = {\r\n _custom: {\r\n type: Error,\r\n readOnly: true,\r\n display: failure ? failure.message : '',\r\n tooltip: 'Navigation Failure',\r\n value: failure,\r\n },\r\n };\r\n data.status = formatDisplay('❌');\r\n }\r\n else {\r\n data.status = formatDisplay('✅');\r\n }\r\n // we set here to have the right order\r\n data.from = formatRouteLocation(from, 'Current Location during this navigation');\r\n data.to = formatRouteLocation(to, 'Target location');\r\n api.addTimelineEvent({\r\n layerId: navigationsLayerId,\r\n event: {\r\n title: 'End of navigation',\r\n subtitle: to.fullPath,\r\n time: Date.now(),\r\n data,\r\n logType: failure ? 'warning' : 'default',\r\n groupId: to.meta.__navigationId,\r\n },\r\n });\r\n });\r\n /**\r\n * Inspector of Existing routes\r\n */\r\n const routerInspectorId = 'router-inspector:' + id;\r\n api.addInspector({\r\n id: routerInspectorId,\r\n label: 'Routes' + (id ? ' ' + id : ''),\r\n icon: 'book',\r\n treeFilterPlaceholder: 'Search routes',\r\n });\r\n function refreshRoutesView() {\r\n // the routes view isn't active\r\n if (!activeRoutesPayload)\r\n return;\r\n const payload = activeRoutesPayload;\r\n // children routes will appear as nested\r\n let routes = matcher.getRoutes().filter(route => !route.parent);\r\n // reset match state to false\r\n routes.forEach(resetMatchStateOnRouteRecord);\r\n // apply a match state if there is a payload\r\n if (payload.filter) {\r\n routes = routes.filter(route => \r\n // save matches state based on the payload\r\n isRouteMatching(route, payload.filter.toLowerCase()));\r\n }\r\n // mark active routes\r\n routes.forEach(route => markRouteRecordActive(route, router.currentRoute.value));\r\n payload.rootNodes = routes.map(formatRouteRecordForInspector);\r\n }\r\n let activeRoutesPayload;\r\n api.on.getInspectorTree(payload => {\r\n activeRoutesPayload = payload;\r\n if (payload.app === app && payload.inspectorId === routerInspectorId) {\r\n refreshRoutesView();\r\n }\r\n });\r\n /**\r\n * Display information about the currently selected route record\r\n */\r\n api.on.getInspectorState(payload => {\r\n if (payload.app === app && payload.inspectorId === routerInspectorId) {\r\n const routes = matcher.getRoutes();\r\n const route = routes.find(route => route.record.__vd_id === payload.nodeId);\r\n if (route) {\r\n payload.state = {\r\n options: formatRouteRecordMatcherForStateInspector(route),\r\n };\r\n }\r\n }\r\n });\r\n api.sendInspectorTree(routerInspectorId);\r\n api.sendInspectorState(routerInspectorId);\r\n });\r\n}\r\nfunction modifierForKey(key) {\r\n if (key.optional) {\r\n return key.repeatable ? '*' : '?';\r\n }\r\n else {\r\n return key.repeatable ? '+' : '';\r\n }\r\n}\r\nfunction formatRouteRecordMatcherForStateInspector(route) {\r\n const { record } = route;\r\n const fields = [\r\n { editable: false, key: 'path', value: record.path },\r\n ];\r\n if (record.name != null) {\r\n fields.push({\r\n editable: false,\r\n key: 'name',\r\n value: record.name,\r\n });\r\n }\r\n fields.push({ editable: false, key: 'regexp', value: route.re });\r\n if (route.keys.length) {\r\n fields.push({\r\n editable: false,\r\n key: 'keys',\r\n value: {\r\n _custom: {\r\n type: null,\r\n readOnly: true,\r\n display: route.keys\r\n .map(key => `${key.name}${modifierForKey(key)}`)\r\n .join(' '),\r\n tooltip: 'Param keys',\r\n value: route.keys,\r\n },\r\n },\r\n });\r\n }\r\n if (record.redirect != null) {\r\n fields.push({\r\n editable: false,\r\n key: 'redirect',\r\n value: record.redirect,\r\n });\r\n }\r\n if (route.alias.length) {\r\n fields.push({\r\n editable: false,\r\n key: 'aliases',\r\n value: route.alias.map(alias => alias.record.path),\r\n });\r\n }\r\n fields.push({\r\n key: 'score',\r\n editable: false,\r\n value: {\r\n _custom: {\r\n type: null,\r\n readOnly: true,\r\n display: route.score.map(score => score.join(', ')).join(' | '),\r\n tooltip: 'Score used to sort routes',\r\n value: route.score,\r\n },\r\n },\r\n });\r\n return fields;\r\n}\r\n/**\r\n * Extracted from tailwind palette\r\n */\r\nconst PINK_500 = 0xec4899;\r\nconst BLUE_600 = 0x2563eb;\r\nconst LIME_500 = 0x84cc16;\r\nconst CYAN_400 = 0x22d3ee;\r\nconst ORANGE_400 = 0xfb923c;\r\n// const GRAY_100 = 0xf4f4f5\r\nconst DARK = 0x666666;\r\nfunction formatRouteRecordForInspector(route) {\r\n const tags = [];\r\n const { record } = route;\r\n if (record.name != null) {\r\n tags.push({\r\n label: String(record.name),\r\n textColor: 0,\r\n backgroundColor: CYAN_400,\r\n });\r\n }\r\n if (record.aliasOf) {\r\n tags.push({\r\n label: 'alias',\r\n textColor: 0,\r\n backgroundColor: ORANGE_400,\r\n });\r\n }\r\n if (route.__vd_match) {\r\n tags.push({\r\n label: 'matches',\r\n textColor: 0,\r\n backgroundColor: PINK_500,\r\n });\r\n }\r\n if (route.__vd_exactActive) {\r\n tags.push({\r\n label: 'exact',\r\n textColor: 0,\r\n backgroundColor: LIME_500,\r\n });\r\n }\r\n if (route.__vd_active) {\r\n tags.push({\r\n label: 'active',\r\n textColor: 0,\r\n backgroundColor: BLUE_600,\r\n });\r\n }\r\n if (record.redirect) {\r\n tags.push({\r\n label: 'redirect: ' +\r\n (typeof record.redirect === 'string' ? record.redirect : 'Object'),\r\n textColor: 0xffffff,\r\n backgroundColor: DARK,\r\n });\r\n }\r\n // add an id to be able to select it. Using the `path` is not possible because\r\n // empty path children would collide with their parents\r\n let id = record.__vd_id;\r\n if (id == null) {\r\n id = String(routeRecordId++);\r\n record.__vd_id = id;\r\n }\r\n return {\r\n id,\r\n label: record.path,\r\n tags,\r\n children: route.children.map(formatRouteRecordForInspector),\r\n };\r\n}\r\n// incremental id for route records and inspector state\r\nlet routeRecordId = 0;\r\nconst EXTRACT_REGEXP_RE = /^\\/(.*)\\/([a-z]*)$/;\r\nfunction markRouteRecordActive(route, currentRoute) {\r\n // no route will be active if matched is empty\r\n // reset the matching state\r\n const isExactActive = currentRoute.matched.length &&\r\n isSameRouteRecord(currentRoute.matched[currentRoute.matched.length - 1], route.record);\r\n route.__vd_exactActive = route.__vd_active = isExactActive;\r\n if (!isExactActive) {\r\n route.__vd_active = currentRoute.matched.some(match => isSameRouteRecord(match, route.record));\r\n }\r\n route.children.forEach(childRoute => markRouteRecordActive(childRoute, currentRoute));\r\n}\r\nfunction resetMatchStateOnRouteRecord(route) {\r\n route.__vd_match = false;\r\n route.children.forEach(resetMatchStateOnRouteRecord);\r\n}\r\nfunction isRouteMatching(route, filter) {\r\n const found = String(route.re).match(EXTRACT_REGEXP_RE);\r\n route.__vd_match = false;\r\n if (!found || found.length < 3) {\r\n return false;\r\n }\r\n // use a regexp without $ at the end to match nested routes better\r\n const nonEndingRE = new RegExp(found[1].replace(/\\$$/, ''), found[2]);\r\n if (nonEndingRE.test(filter)) {\r\n // mark children as matches\r\n route.children.forEach(child => isRouteMatching(child, filter));\r\n // exception case: `/`\r\n if (route.record.path !== '/' || filter === '/') {\r\n route.__vd_match = route.re.test(filter);\r\n return true;\r\n }\r\n // hide the / route\r\n return false;\r\n }\r\n const path = route.record.path.toLowerCase();\r\n const decodedPath = decode(path);\r\n // also allow partial matching on the path\r\n if (!filter.startsWith('/') &&\r\n (decodedPath.includes(filter) || path.includes(filter)))\r\n return true;\r\n if (decodedPath.startsWith(filter) || path.startsWith(filter))\r\n return true;\r\n if (route.record.name && String(route.record.name).includes(filter))\r\n return true;\r\n return route.children.some(child => isRouteMatching(child, filter));\r\n}\r\nfunction omit(obj, keys) {\r\n const ret = {};\r\n for (const key in obj) {\r\n if (!keys.includes(key)) {\r\n // @ts-expect-error\r\n ret[key] = obj[key];\r\n }\r\n }\r\n return ret;\r\n}\n\n/**\r\n * Creates a Router instance that can be used by a Vue app.\r\n *\r\n * @param options - {@link RouterOptions}\r\n */\r\nfunction createRouter(options) {\r\n const matcher = createRouterMatcher(options.routes, options);\r\n const parseQuery$1 = options.parseQuery || parseQuery;\r\n const stringifyQuery$1 = options.stringifyQuery || stringifyQuery;\r\n const routerHistory = options.history;\r\n if ((process.env.NODE_ENV !== 'production') && !routerHistory)\r\n throw new Error('Provide the \"history\" option when calling \"createRouter()\":' +\r\n ' https://next.router.vuejs.org/api/#history.');\r\n const beforeGuards = useCallbacks();\r\n const beforeResolveGuards = useCallbacks();\r\n const afterGuards = useCallbacks();\r\n const currentRoute = shallowRef(START_LOCATION_NORMALIZED);\r\n let pendingLocation = START_LOCATION_NORMALIZED;\r\n // leave the scrollRestoration if no scrollBehavior is provided\r\n if (isBrowser && options.scrollBehavior && 'scrollRestoration' in history) {\r\n history.scrollRestoration = 'manual';\r\n }\r\n const normalizeParams = applyToParams.bind(null, paramValue => '' + paramValue);\r\n const encodeParams = applyToParams.bind(null, encodeParam);\r\n const decodeParams = \r\n // @ts-expect-error: intentionally avoid the type check\r\n applyToParams.bind(null, decode);\r\n function addRoute(parentOrRoute, route) {\r\n let parent;\r\n let record;\r\n if (isRouteName(parentOrRoute)) {\r\n parent = matcher.getRecordMatcher(parentOrRoute);\r\n record = route;\r\n }\r\n else {\r\n record = parentOrRoute;\r\n }\r\n return matcher.addRoute(record, parent);\r\n }\r\n function removeRoute(name) {\r\n const recordMatcher = matcher.getRecordMatcher(name);\r\n if (recordMatcher) {\r\n matcher.removeRoute(recordMatcher);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Cannot remove non-existent route \"${String(name)}\"`);\r\n }\r\n }\r\n function getRoutes() {\r\n return matcher.getRoutes().map(routeMatcher => routeMatcher.record);\r\n }\r\n function hasRoute(name) {\r\n return !!matcher.getRecordMatcher(name);\r\n }\r\n function resolve(rawLocation, currentLocation) {\r\n // const objectLocation = routerLocationAsObject(rawLocation)\r\n // we create a copy to modify it later\r\n currentLocation = assign({}, currentLocation || currentRoute.value);\r\n if (typeof rawLocation === 'string') {\r\n const locationNormalized = parseURL(parseQuery$1, rawLocation, currentLocation.path);\r\n const matchedRoute = matcher.resolve({ path: locationNormalized.path }, currentLocation);\r\n const href = routerHistory.createHref(locationNormalized.fullPath);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (href.startsWith('//'))\r\n warn(`Location \"${rawLocation}\" resolved to \"${href}\". A resolved location cannot start with multiple slashes.`);\r\n else if (!matchedRoute.matched.length) {\r\n warn(`No match found for location with path \"${rawLocation}\"`);\r\n }\r\n }\r\n // locationNormalized is always a new object\r\n return assign(locationNormalized, matchedRoute, {\r\n params: decodeParams(matchedRoute.params),\r\n hash: decode(locationNormalized.hash),\r\n redirectedFrom: undefined,\r\n href,\r\n });\r\n }\r\n let matcherLocation;\r\n // path could be relative in object as well\r\n if ('path' in rawLocation) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n 'params' in rawLocation &&\r\n !('name' in rawLocation) &&\r\n // @ts-expect-error: the type is never\r\n Object.keys(rawLocation.params).length) {\r\n warn(`Path \"${\r\n // @ts-expect-error: the type is never\r\n rawLocation.path}\" was passed with params but they will be ignored. Use a named route alongside params instead.`);\r\n }\r\n matcherLocation = assign({}, rawLocation, {\r\n path: parseURL(parseQuery$1, rawLocation.path, currentLocation.path).path,\r\n });\r\n }\r\n else {\r\n // remove any nullish param\r\n const targetParams = assign({}, rawLocation.params);\r\n for (const key in targetParams) {\r\n if (targetParams[key] == null) {\r\n delete targetParams[key];\r\n }\r\n }\r\n // pass encoded values to the matcher so it can produce encoded path and fullPath\r\n matcherLocation = assign({}, rawLocation, {\r\n params: encodeParams(rawLocation.params),\r\n });\r\n // current location params are decoded, we need to encode them in case the\r\n // matcher merges the params\r\n currentLocation.params = encodeParams(currentLocation.params);\r\n }\r\n const matchedRoute = matcher.resolve(matcherLocation, currentLocation);\r\n const hash = rawLocation.hash || '';\r\n if ((process.env.NODE_ENV !== 'production') && hash && !hash.startsWith('#')) {\r\n warn(`A \\`hash\\` should always start with the character \"#\". Replace \"${hash}\" with \"#${hash}\".`);\r\n }\r\n // decoding them) the matcher might have merged current location params so\r\n // we need to run the decoding again\r\n matchedRoute.params = normalizeParams(decodeParams(matchedRoute.params));\r\n const fullPath = stringifyURL(stringifyQuery$1, assign({}, rawLocation, {\r\n hash: encodeHash(hash),\r\n path: matchedRoute.path,\r\n }));\r\n const href = routerHistory.createHref(fullPath);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (href.startsWith('//')) {\r\n warn(`Location \"${rawLocation}\" resolved to \"${href}\". A resolved location cannot start with multiple slashes.`);\r\n }\r\n else if (!matchedRoute.matched.length) {\r\n warn(`No match found for location with path \"${'path' in rawLocation ? rawLocation.path : rawLocation}\"`);\r\n }\r\n }\r\n return assign({\r\n fullPath,\r\n // keep the hash encoded so fullPath is effectively path + encodedQuery +\r\n // hash\r\n hash,\r\n query: \r\n // if the user is using a custom query lib like qs, we might have\r\n // nested objects, so we keep the query as is, meaning it can contain\r\n // numbers at `$route.query`, but at the point, the user will have to\r\n // use their own type anyway.\r\n // https://github.com/vuejs/vue-router-next/issues/328#issuecomment-649481567\r\n stringifyQuery$1 === stringifyQuery\r\n ? normalizeQuery(rawLocation.query)\r\n : (rawLocation.query || {}),\r\n }, matchedRoute, {\r\n redirectedFrom: undefined,\r\n href,\r\n });\r\n }\r\n function locationAsObject(to) {\r\n return typeof to === 'string'\r\n ? parseURL(parseQuery$1, to, currentRoute.value.path)\r\n : assign({}, to);\r\n }\r\n function checkCanceledNavigation(to, from) {\r\n if (pendingLocation !== to) {\r\n return createRouterError(8 /* NAVIGATION_CANCELLED */, {\r\n from,\r\n to,\r\n });\r\n }\r\n }\r\n function push(to) {\r\n return pushWithRedirect(to);\r\n }\r\n function replace(to) {\r\n return push(assign(locationAsObject(to), { replace: true }));\r\n }\r\n function handleRedirectRecord(to) {\r\n const lastMatched = to.matched[to.matched.length - 1];\r\n if (lastMatched && lastMatched.redirect) {\r\n const { redirect } = lastMatched;\r\n let newTargetLocation = typeof redirect === 'function' ? redirect(to) : redirect;\r\n if (typeof newTargetLocation === 'string') {\r\n newTargetLocation =\r\n newTargetLocation.includes('?') || newTargetLocation.includes('#')\r\n ? (newTargetLocation = locationAsObject(newTargetLocation))\r\n : // force empty params\r\n { path: newTargetLocation };\r\n // @ts-expect-error: force empty params when a string is passed to let\r\n // the router parse them again\r\n newTargetLocation.params = {};\r\n }\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n !('path' in newTargetLocation) &&\r\n !('name' in newTargetLocation)) {\r\n warn(`Invalid redirect found:\\n${JSON.stringify(newTargetLocation, null, 2)}\\n when navigating to \"${to.fullPath}\". A redirect must contain a name or path. This will break in production.`);\r\n throw new Error('Invalid redirect');\r\n }\r\n return assign({\r\n query: to.query,\r\n hash: to.hash,\r\n params: to.params,\r\n }, newTargetLocation);\r\n }\r\n }\r\n function pushWithRedirect(to, redirectedFrom) {\r\n const targetLocation = (pendingLocation = resolve(to));\r\n const from = currentRoute.value;\r\n const data = to.state;\r\n const force = to.force;\r\n // to could be a string where `replace` is a function\r\n const replace = to.replace === true;\r\n const shouldRedirect = handleRedirectRecord(targetLocation);\r\n if (shouldRedirect)\r\n return pushWithRedirect(assign(locationAsObject(shouldRedirect), {\r\n state: data,\r\n force,\r\n replace,\r\n }), \r\n // keep original redirectedFrom if it exists\r\n redirectedFrom || targetLocation);\r\n // if it was a redirect we already called `pushWithRedirect` above\r\n const toLocation = targetLocation;\r\n toLocation.redirectedFrom = redirectedFrom;\r\n let failure;\r\n if (!force && isSameRouteLocation(stringifyQuery$1, from, targetLocation)) {\r\n failure = createRouterError(16 /* NAVIGATION_DUPLICATED */, { to: toLocation, from });\r\n // trigger scroll to allow scrolling to the same anchor\r\n handleScroll(from, from, \r\n // this is a push, the only way for it to be triggered from a\r\n // history.listen is with a redirect, which makes it become a push\r\n true, \r\n // This cannot be the first navigation because the initial location\r\n // cannot be manually navigated to\r\n false);\r\n }\r\n return (failure ? Promise.resolve(failure) : navigate(toLocation, from))\r\n .catch((error) => isNavigationFailure(error)\r\n ? error\r\n : // reject any unknown error\r\n triggerError(error, toLocation, from))\r\n .then((failure) => {\r\n if (failure) {\r\n if (isNavigationFailure(failure, 2 /* NAVIGATION_GUARD_REDIRECT */)) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n // we are redirecting to the same location we were already at\r\n isSameRouteLocation(stringifyQuery$1, resolve(failure.to), toLocation) &&\r\n // and we have done it a couple of times\r\n redirectedFrom &&\r\n // @ts-expect-error: added only in dev\r\n (redirectedFrom._count = redirectedFrom._count\r\n ? // @ts-expect-error\r\n redirectedFrom._count + 1\r\n : 1) > 10) {\r\n warn(`Detected an infinite redirection in a navigation guard when going from \"${from.fullPath}\" to \"${toLocation.fullPath}\". Aborting to avoid a Stack Overflow. This will break in production if not fixed.`);\r\n return Promise.reject(new Error('Infinite redirect in navigation guard'));\r\n }\r\n return pushWithRedirect(\r\n // keep options\r\n assign(locationAsObject(failure.to), {\r\n state: data,\r\n force,\r\n replace,\r\n }), \r\n // preserve the original redirectedFrom if any\r\n redirectedFrom || toLocation);\r\n }\r\n }\r\n else {\r\n // if we fail we don't finalize the navigation\r\n failure = finalizeNavigation(toLocation, from, true, replace, data);\r\n }\r\n triggerAfterEach(toLocation, from, failure);\r\n return failure;\r\n });\r\n }\r\n /**\r\n * Helper to reject and skip all navigation guards if a new navigation happened\r\n * @param to\r\n * @param from\r\n */\r\n function checkCanceledNavigationAndReject(to, from) {\r\n const error = checkCanceledNavigation(to, from);\r\n return error ? Promise.reject(error) : Promise.resolve();\r\n }\r\n // TODO: refactor the whole before guards by internally using router.beforeEach\r\n function navigate(to, from) {\r\n let guards;\r\n const [leavingRecords, updatingRecords, enteringRecords] = extractChangingRecords(to, from);\r\n // all components here have been resolved once because we are leaving\r\n guards = extractComponentsGuards(leavingRecords.reverse(), 'beforeRouteLeave', to, from);\r\n // leavingRecords is already reversed\r\n for (const record of leavingRecords) {\r\n record.leaveGuards.forEach(guard => {\r\n guards.push(guardToPromiseFn(guard, to, from));\r\n });\r\n }\r\n const canceledNavigationCheck = checkCanceledNavigationAndReject.bind(null, to, from);\r\n guards.push(canceledNavigationCheck);\r\n // run the queue of per route beforeRouteLeave guards\r\n return (runGuardQueue(guards)\r\n .then(() => {\r\n // check global guards beforeEach\r\n guards = [];\r\n for (const guard of beforeGuards.list()) {\r\n guards.push(guardToPromiseFn(guard, to, from));\r\n }\r\n guards.push(canceledNavigationCheck);\r\n return runGuardQueue(guards);\r\n })\r\n .then(() => {\r\n // check in components beforeRouteUpdate\r\n guards = extractComponentsGuards(updatingRecords, 'beforeRouteUpdate', to, from);\r\n for (const record of updatingRecords) {\r\n record.updateGuards.forEach(guard => {\r\n guards.push(guardToPromiseFn(guard, to, from));\r\n });\r\n }\r\n guards.push(canceledNavigationCheck);\r\n // run the queue of per route beforeEnter guards\r\n return runGuardQueue(guards);\r\n })\r\n .then(() => {\r\n // check the route beforeEnter\r\n guards = [];\r\n for (const record of to.matched) {\r\n // do not trigger beforeEnter on reused views\r\n if (record.beforeEnter && !from.matched.includes(record)) {\r\n if (Array.isArray(record.beforeEnter)) {\r\n for (const beforeEnter of record.beforeEnter)\r\n guards.push(guardToPromiseFn(beforeEnter, to, from));\r\n }\r\n else {\r\n guards.push(guardToPromiseFn(record.beforeEnter, to, from));\r\n }\r\n }\r\n }\r\n guards.push(canceledNavigationCheck);\r\n // run the queue of per route beforeEnter guards\r\n return runGuardQueue(guards);\r\n })\r\n .then(() => {\r\n // NOTE: at this point to.matched is normalized and does not contain any () => Promise<Component>\r\n // clear existing enterCallbacks, these are added by extractComponentsGuards\r\n to.matched.forEach(record => (record.enterCallbacks = {}));\r\n // check in-component beforeRouteEnter\r\n guards = extractComponentsGuards(enteringRecords, 'beforeRouteEnter', to, from);\r\n guards.push(canceledNavigationCheck);\r\n // run the queue of per route beforeEnter guards\r\n return runGuardQueue(guards);\r\n })\r\n .then(() => {\r\n // check global guards beforeResolve\r\n guards = [];\r\n for (const guard of beforeResolveGuards.list()) {\r\n guards.push(guardToPromiseFn(guard, to, from));\r\n }\r\n guards.push(canceledNavigationCheck);\r\n return runGuardQueue(guards);\r\n })\r\n // catch any navigation canceled\r\n .catch(err => isNavigationFailure(err, 8 /* NAVIGATION_CANCELLED */)\r\n ? err\r\n : Promise.reject(err)));\r\n }\r\n function triggerAfterEach(to, from, failure) {\r\n // navigation is confirmed, call afterGuards\r\n // TODO: wrap with error handlers\r\n for (const guard of afterGuards.list())\r\n guard(to, from, failure);\r\n }\r\n /**\r\n * - Cleans up any navigation guards\r\n * - Changes the url if necessary\r\n * - Calls the scrollBehavior\r\n */\r\n function finalizeNavigation(toLocation, from, isPush, replace, data) {\r\n // a more recent navigation took place\r\n const error = checkCanceledNavigation(toLocation, from);\r\n if (error)\r\n return error;\r\n // only consider as push if it's not the first navigation\r\n const isFirstNavigation = from === START_LOCATION_NORMALIZED;\r\n const state = !isBrowser ? {} : history.state;\r\n // change URL only if the user did a push/replace and if it's not the initial navigation because\r\n // it's just reflecting the url\r\n if (isPush) {\r\n // on the initial navigation, we want to reuse the scroll position from\r\n // history state if it exists\r\n if (replace || isFirstNavigation)\r\n routerHistory.replace(toLocation.fullPath, assign({\r\n scroll: isFirstNavigation && state && state.scroll,\r\n }, data));\r\n else\r\n routerHistory.push(toLocation.fullPath, data);\r\n }\r\n // accept current navigation\r\n currentRoute.value = toLocation;\r\n handleScroll(toLocation, from, isPush, isFirstNavigation);\r\n markAsReady();\r\n }\r\n let removeHistoryListener;\r\n // attach listener to history to trigger navigations\r\n function setupListeners() {\r\n removeHistoryListener = routerHistory.listen((to, _from, info) => {\r\n // cannot be a redirect route because it was in history\r\n const toLocation = resolve(to);\r\n // due to dynamic routing, and to hash history with manual navigation\r\n // (manually changing the url or calling history.hash = '#/somewhere'),\r\n // there could be a redirect record in history\r\n const shouldRedirect = handleRedirectRecord(toLocation);\r\n if (shouldRedirect) {\r\n pushWithRedirect(assign(shouldRedirect, { replace: true }), toLocation).catch(noop);\r\n return;\r\n }\r\n pendingLocation = toLocation;\r\n const from = currentRoute.value;\r\n // TODO: should be moved to web history?\r\n if (isBrowser) {\r\n saveScrollPosition(getScrollKey(from.fullPath, info.delta), computeScrollPosition());\r\n }\r\n navigate(toLocation, from)\r\n .catch((error) => {\r\n if (isNavigationFailure(error, 4 /* NAVIGATION_ABORTED */ | 8 /* NAVIGATION_CANCELLED */)) {\r\n return error;\r\n }\r\n if (isNavigationFailure(error, 2 /* NAVIGATION_GUARD_REDIRECT */)) {\r\n // Here we could call if (info.delta) routerHistory.go(-info.delta,\r\n // false) but this is bug prone as we have no way to wait the\r\n // navigation to be finished before calling pushWithRedirect. Using\r\n // a setTimeout of 16ms seems to work but there is not guarantee for\r\n // it to work on every browser. So Instead we do not restore the\r\n // history entry and trigger a new navigation as requested by the\r\n // navigation guard.\r\n // the error is already handled by router.push we just want to avoid\r\n // logging the error\r\n pushWithRedirect(error.to, toLocation\r\n // avoid an uncaught rejection, let push call triggerError\r\n )\r\n .then(failure => {\r\n // manual change in hash history #916 ending up in the URL not\r\n // changing but it was changed by the manual url change, so we\r\n // need to manually change it ourselves\r\n if (isNavigationFailure(failure, 4 /* NAVIGATION_ABORTED */ |\r\n 16 /* NAVIGATION_DUPLICATED */) &&\r\n !info.delta &&\r\n info.type === NavigationType.pop) {\r\n routerHistory.go(-1, false);\r\n }\r\n })\r\n .catch(noop);\r\n // avoid the then branch\r\n return Promise.reject();\r\n }\r\n // do not restore history on unknown direction\r\n if (info.delta)\r\n routerHistory.go(-info.delta, false);\r\n // unrecognized error, transfer to the global handler\r\n return triggerError(error, toLocation, from);\r\n })\r\n .then((failure) => {\r\n failure =\r\n failure ||\r\n finalizeNavigation(\r\n // after navigation, all matched components are resolved\r\n toLocation, from, false);\r\n // revert the navigation\r\n if (failure) {\r\n if (info.delta) {\r\n routerHistory.go(-info.delta, false);\r\n }\r\n else if (info.type === NavigationType.pop &&\r\n isNavigationFailure(failure, 4 /* NAVIGATION_ABORTED */ | 16 /* NAVIGATION_DUPLICATED */)) {\r\n // manual change in hash history #916\r\n // it's like a push but lacks the information of the direction\r\n routerHistory.go(-1, false);\r\n }\r\n }\r\n triggerAfterEach(toLocation, from, failure);\r\n })\r\n .catch(noop);\r\n });\r\n }\r\n // Initialization and Errors\r\n let readyHandlers = useCallbacks();\r\n let errorHandlers = useCallbacks();\r\n let ready;\r\n /**\r\n * Trigger errorHandlers added via onError and throws the error as well\r\n *\r\n * @param error - error to throw\r\n * @param to - location we were navigating to when the error happened\r\n * @param from - location we were navigating from when the error happened\r\n * @returns the error as a rejected promise\r\n */\r\n function triggerError(error, to, from) {\r\n markAsReady(error);\r\n const list = errorHandlers.list();\r\n if (list.length) {\r\n list.forEach(handler => handler(error, to, from));\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn('uncaught error during route navigation:');\r\n }\r\n console.error(error);\r\n }\r\n return Promise.reject(error);\r\n }\r\n function isReady() {\r\n if (ready && currentRoute.value !== START_LOCATION_NORMALIZED)\r\n return Promise.resolve();\r\n return new Promise((resolve, reject) => {\r\n readyHandlers.add([resolve, reject]);\r\n });\r\n }\r\n /**\r\n * Mark the router as ready, resolving the promised returned by isReady(). Can\r\n * only be called once, otherwise does nothing.\r\n * @param err - optional error\r\n */\r\n function markAsReady(err) {\r\n if (ready)\r\n return;\r\n ready = true;\r\n setupListeners();\r\n readyHandlers\r\n .list()\r\n .forEach(([resolve, reject]) => (err ? reject(err) : resolve()));\r\n readyHandlers.reset();\r\n }\r\n // Scroll behavior\r\n function handleScroll(to, from, isPush, isFirstNavigation) {\r\n const { scrollBehavior } = options;\r\n if (!isBrowser || !scrollBehavior)\r\n return Promise.resolve();\r\n const scrollPosition = (!isPush && getSavedScrollPosition(getScrollKey(to.fullPath, 0))) ||\r\n ((isFirstNavigation || !isPush) &&\r\n history.state &&\r\n history.state.scroll) ||\r\n null;\r\n return nextTick()\r\n .then(() => scrollBehavior(to, from, scrollPosition))\r\n .then(position => position && scrollToPosition(position))\r\n .catch(err => triggerError(err, to, from));\r\n }\r\n const go = (delta) => routerHistory.go(delta);\r\n let started;\r\n const installedApps = new Set();\r\n const router = {\r\n currentRoute,\r\n addRoute,\r\n removeRoute,\r\n hasRoute,\r\n getRoutes,\r\n resolve,\r\n options,\r\n push,\r\n replace,\r\n go,\r\n back: () => go(-1),\r\n forward: () => go(1),\r\n beforeEach: beforeGuards.add,\r\n beforeResolve: beforeResolveGuards.add,\r\n afterEach: afterGuards.add,\r\n onError: errorHandlers.add,\r\n isReady,\r\n install(app) {\r\n const router = this;\r\n app.component('RouterLink', RouterLink);\r\n app.component('RouterView', RouterView);\r\n app.config.globalProperties.$router = router;\r\n Object.defineProperty(app.config.globalProperties, '$route', {\r\n enumerable: true,\r\n get: () => unref(currentRoute),\r\n });\r\n // this initial navigation is only necessary on client, on server it doesn't\r\n // make sense because it will create an extra unnecessary navigation and could\r\n // lead to problems\r\n if (isBrowser &&\r\n // used for the initial navigation client side to avoid pushing\r\n // multiple times when the router is used in multiple apps\r\n !started &&\r\n currentRoute.value === START_LOCATION_NORMALIZED) {\r\n // see above\r\n started = true;\r\n push(routerHistory.location).catch(err => {\r\n if ((process.env.NODE_ENV !== 'production'))\r\n warn('Unexpected error when starting the router:', err);\r\n });\r\n }\r\n const reactiveRoute = {};\r\n for (const key in START_LOCATION_NORMALIZED) {\r\n // @ts-expect-error: the key matches\r\n reactiveRoute[key] = computed(() => currentRoute.value[key]);\r\n }\r\n app.provide(routerKey, router);\r\n app.provide(routeLocationKey, reactive(reactiveRoute));\r\n app.provide(routerViewLocationKey, currentRoute);\r\n const unmountApp = app.unmount;\r\n installedApps.add(app);\r\n app.unmount = function () {\r\n installedApps.delete(app);\r\n // the router is not attached to an app anymore\r\n if (installedApps.size < 1) {\r\n // invalidate the current navigation\r\n pendingLocation = START_LOCATION_NORMALIZED;\r\n removeHistoryListener && removeHistoryListener();\r\n currentRoute.value = START_LOCATION_NORMALIZED;\r\n started = false;\r\n ready = false;\r\n }\r\n unmountApp();\r\n };\r\n if (((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) && isBrowser) {\r\n addDevtools(app, router, matcher);\r\n }\r\n },\r\n };\r\n return router;\r\n}\r\nfunction runGuardQueue(guards) {\r\n return guards.reduce((promise, guard) => promise.then(() => guard()), Promise.resolve());\r\n}\r\nfunction extractChangingRecords(to, from) {\r\n const leavingRecords = [];\r\n const updatingRecords = [];\r\n const enteringRecords = [];\r\n const len = Math.max(from.matched.length, to.matched.length);\r\n for (let i = 0; i < len; i++) {\r\n const recordFrom = from.matched[i];\r\n if (recordFrom) {\r\n if (to.matched.find(record => isSameRouteRecord(record, recordFrom)))\r\n updatingRecords.push(recordFrom);\r\n else\r\n leavingRecords.push(recordFrom);\r\n }\r\n const recordTo = to.matched[i];\r\n if (recordTo) {\r\n // the type doesn't matter because we are comparing per reference\r\n if (!from.matched.find(record => isSameRouteRecord(record, recordTo))) {\r\n enteringRecords.push(recordTo);\r\n }\r\n }\r\n }\r\n return [leavingRecords, updatingRecords, enteringRecords];\r\n}\n\n/**\r\n * Returns the router instance. Equivalent to using `$router` inside\r\n * templates.\r\n */\r\nfunction useRouter() {\r\n return inject(routerKey);\r\n}\r\n/**\r\n * Returns the current route location. Equivalent to using `$route` inside\r\n * templates.\r\n */\r\nfunction useRoute() {\r\n return inject(routeLocationKey);\r\n}\n\nexport { NavigationFailureType, RouterLink, RouterView, START_LOCATION_NORMALIZED as START_LOCATION, createMemoryHistory, createRouter, createRouterMatcher, createWebHashHistory, createWebHistory, isNavigationFailure, matchedRouteKey, onBeforeRouteLeave, onBeforeRouteUpdate, parseQuery, routeLocationKey, routerKey, routerViewLocationKey, stringifyQuery, useLink, useRoute, useRouter, viewDepthKey };\n","import { resolveDirective as _resolveDirective, withDirectives as _withDirectives, createVNode as _createVNode, vShow as _vShow } from \"vue\";\nimport { Transition, defineComponent } from 'vue';\nimport { noop, isDef, extend, truthProp, numericProp, unknownProp, preventDefault, createNamespace, getZIndexStyle } from '../utils';\nimport { useLazyRender } from '../composables/use-lazy-render';\nvar [name, bem] = createNamespace('overlay');\nvar overlayProps = {\n show: Boolean,\n zIndex: numericProp,\n duration: numericProp,\n className: unknownProp,\n lockScroll: truthProp,\n customStyle: Object\n};\nexport default defineComponent({\n name,\n props: overlayProps,\n\n setup(props, _ref) {\n var {\n slots\n } = _ref;\n var lazyRender = useLazyRender(() => props.show);\n\n var preventTouchMove = event => {\n preventDefault(event, true);\n };\n\n var renderOverlay = lazyRender(() => {\n var style = extend(getZIndexStyle(props.zIndex), props.customStyle);\n\n if (isDef(props.duration)) {\n style.animationDuration = props.duration + \"s\";\n }\n\n return _withDirectives(_createVNode(\"div\", {\n \"style\": style,\n \"class\": [bem(), props.className],\n \"onTouchmove\": props.lockScroll ? preventTouchMove : noop\n }, [slots.default == null ? void 0 : slots.default()]), [[_vShow, props.show]]);\n });\n return () => _createVNode(Transition, {\n \"name\": \"van-fade\",\n \"appear\": true\n }, {\n default: renderOverlay\n });\n }\n\n});","import { withInstall } from '../utils';\nimport _Overlay from './Overlay';\nexport var Overlay = withInstall(_Overlay);\nexport default Overlay;","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\nvar hasOwn = require('../internals/has-own-property');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar setGlobal = require('../internals/set-global');\nvar inspectSource = require('../internals/inspect-source');\nvar InternalStateModule = require('../internals/internal-state');\nvar CONFIGURABLE_FUNCTION_NAME = require('../internals/function-name').CONFIGURABLE;\n\nvar getInternalState = InternalStateModule.get;\nvar enforceInternalState = InternalStateModule.enforce;\nvar TEMPLATE = String(String).split('String');\n\n(module.exports = function (O, key, value, options) {\n var unsafe = options ? !!options.unsafe : false;\n var simple = options ? !!options.enumerable : false;\n var noTargetGet = options ? !!options.noTargetGet : false;\n var name = options && options.name !== undefined ? options.name : key;\n var state;\n if (isCallable(value)) {\n if (String(name).slice(0, 7) === 'Symbol(') {\n name = '[' + String(name).replace(/^Symbol\\(([^)]*)\\)/, '$1') + ']';\n }\n if (!hasOwn(value, 'name') || (CONFIGURABLE_FUNCTION_NAME && value.name !== name)) {\n createNonEnumerableProperty(value, 'name', name);\n }\n state = enforceInternalState(value);\n if (!state.source) {\n state.source = TEMPLATE.join(typeof name == 'string' ? name : '');\n }\n }\n if (O === global) {\n if (simple) O[key] = value;\n else setGlobal(key, value);\n return;\n } else if (!unsafe) {\n delete O[key];\n } else if (!noTargetGet && O[key]) {\n simple = true;\n }\n if (simple) O[key] = value;\n else createNonEnumerableProperty(O, key, value);\n// add fake Function#toString for correct work wrapped methods / constructors with methods like LoDash isNative\n})(Function.prototype, 'toString', function toString() {\n return isCallable(this) && getInternalState(this).source || inspectSource(this);\n});\n","// eslint-disable-next-line es/no-object-getownpropertysymbols -- safe\nexports.f = Object.getOwnPropertySymbols;\n","import { withInstall } from '../utils';\nimport _Cell from './Cell';\nexport var Cell = withInstall(_Cell);\nexport default Cell;","// IE8- don't enum bug keys\nmodule.exports = [\n 'constructor',\n 'hasOwnProperty',\n 'isPrototypeOf',\n 'propertyIsEnumerable',\n 'toLocaleString',\n 'toString',\n 'valueOf'\n];\n","// in old WebKit versions, `element.classList` is not an instance of global `DOMTokenList`\nvar documentCreateElement = require('../internals/document-create-element');\n\nvar classList = documentCreateElement('span').classList;\nvar DOMTokenListPrototype = classList && classList.constructor && classList.constructor.prototype;\n\nmodule.exports = DOMTokenListPrototype === Object.prototype ? undefined : DOMTokenListPrototype;\n","var global = require('../internals/global');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nvar Object = global.Object;\n\n// `ToObject` abstract operation\n// https://tc39.es/ecma262/#sec-toobject\nmodule.exports = function (argument) {\n return Object(requireObjectCoercible(argument));\n};\n","/* global ActiveXObject -- old IE, WSH */\nvar anObject = require('../internals/an-object');\nvar defineProperties = require('../internals/object-define-properties');\nvar enumBugKeys = require('../internals/enum-bug-keys');\nvar hiddenKeys = require('../internals/hidden-keys');\nvar html = require('../internals/html');\nvar documentCreateElement = require('../internals/document-create-element');\nvar sharedKey = require('../internals/shared-key');\n\nvar GT = '>';\nvar LT = '<';\nvar PROTOTYPE = 'prototype';\nvar SCRIPT = 'script';\nvar IE_PROTO = sharedKey('IE_PROTO');\n\nvar EmptyConstructor = function () { /* empty */ };\n\nvar scriptTag = function (content) {\n return LT + SCRIPT + GT + content + LT + '/' + SCRIPT + GT;\n};\n\n// Create object with fake `null` prototype: use ActiveX Object with cleared prototype\nvar NullProtoObjectViaActiveX = function (activeXDocument) {\n activeXDocument.write(scriptTag(''));\n activeXDocument.close();\n var temp = activeXDocument.parentWindow.Object;\n activeXDocument = null; // avoid memory leak\n return temp;\n};\n\n// Create object with fake `null` prototype: use iframe Object with cleared prototype\nvar NullProtoObjectViaIFrame = function () {\n // Thrash, waste and sodomy: IE GC bug\n var iframe = documentCreateElement('iframe');\n var JS = 'java' + SCRIPT + ':';\n var iframeDocument;\n iframe.style.display = 'none';\n html.appendChild(iframe);\n // https://github.com/zloirock/core-js/issues/475\n iframe.src = String(JS);\n iframeDocument = iframe.contentWindow.document;\n iframeDocument.open();\n iframeDocument.write(scriptTag('document.F=Object'));\n iframeDocument.close();\n return iframeDocument.F;\n};\n\n// Check for document.domain and active x support\n// No need to use active x approach when document.domain is not set\n// see https://github.com/es-shims/es5-shim/issues/150\n// variation of https://github.com/kitcambridge/es5-shim/commit/4f738ac066346\n// avoid IE GC bug\nvar activeXDocument;\nvar NullProtoObject = function () {\n try {\n activeXDocument = new ActiveXObject('htmlfile');\n } catch (error) { /* ignore */ }\n NullProtoObject = typeof document != 'undefined'\n ? document.domain && activeXDocument\n ? NullProtoObjectViaActiveX(activeXDocument) // old IE\n : NullProtoObjectViaIFrame()\n : NullProtoObjectViaActiveX(activeXDocument); // WSH\n var length = enumBugKeys.length;\n while (length--) delete NullProtoObject[PROTOTYPE][enumBugKeys[length]];\n return NullProtoObject();\n};\n\nhiddenKeys[IE_PROTO] = true;\n\n// `Object.create` method\n// https://tc39.es/ecma262/#sec-object.create\nmodule.exports = Object.create || function create(O, Properties) {\n var result;\n if (O !== null) {\n EmptyConstructor[PROTOTYPE] = anObject(O);\n result = new EmptyConstructor();\n EmptyConstructor[PROTOTYPE] = null;\n // add \"__proto__\" for Object.getPrototypeOf polyfill\n result[IE_PROTO] = O;\n } else result = NullProtoObject();\n return Properties === undefined ? result : defineProperties(result, Properties);\n};\n","'use strict';\nvar $ = require('../internals/export');\nvar call = require('../internals/function-call');\nvar IS_PURE = require('../internals/is-pure');\nvar FunctionName = require('../internals/function-name');\nvar isCallable = require('../internals/is-callable');\nvar createIteratorConstructor = require('../internals/create-iterator-constructor');\nvar getPrototypeOf = require('../internals/object-get-prototype-of');\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar redefine = require('../internals/redefine');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar Iterators = require('../internals/iterators');\nvar IteratorsCore = require('../internals/iterators-core');\n\nvar PROPER_FUNCTION_NAME = FunctionName.PROPER;\nvar CONFIGURABLE_FUNCTION_NAME = FunctionName.CONFIGURABLE;\nvar IteratorPrototype = IteratorsCore.IteratorPrototype;\nvar BUGGY_SAFARI_ITERATORS = IteratorsCore.BUGGY_SAFARI_ITERATORS;\nvar ITERATOR = wellKnownSymbol('iterator');\nvar KEYS = 'keys';\nvar VALUES = 'values';\nvar ENTRIES = 'entries';\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (Iterable, NAME, IteratorConstructor, next, DEFAULT, IS_SET, FORCED) {\n createIteratorConstructor(IteratorConstructor, NAME, next);\n\n var getIterationMethod = function (KIND) {\n if (KIND === DEFAULT && defaultIterator) return defaultIterator;\n if (!BUGGY_SAFARI_ITERATORS && KIND in IterablePrototype) return IterablePrototype[KIND];\n switch (KIND) {\n case KEYS: return function keys() { return new IteratorConstructor(this, KIND); };\n case VALUES: return function values() { return new IteratorConstructor(this, KIND); };\n case ENTRIES: return function entries() { return new IteratorConstructor(this, KIND); };\n } return function () { return new IteratorConstructor(this); };\n };\n\n var TO_STRING_TAG = NAME + ' Iterator';\n var INCORRECT_VALUES_NAME = false;\n var IterablePrototype = Iterable.prototype;\n var nativeIterator = IterablePrototype[ITERATOR]\n || IterablePrototype['@@iterator']\n || DEFAULT && IterablePrototype[DEFAULT];\n var defaultIterator = !BUGGY_SAFARI_ITERATORS && nativeIterator || getIterationMethod(DEFAULT);\n var anyNativeIterator = NAME == 'Array' ? IterablePrototype.entries || nativeIterator : nativeIterator;\n var CurrentIteratorPrototype, methods, KEY;\n\n // fix native\n if (anyNativeIterator) {\n CurrentIteratorPrototype = getPrototypeOf(anyNativeIterator.call(new Iterable()));\n if (CurrentIteratorPrototype !== Object.prototype && CurrentIteratorPrototype.next) {\n if (!IS_PURE && getPrototypeOf(CurrentIteratorPrototype) !== IteratorPrototype) {\n if (setPrototypeOf) {\n setPrototypeOf(CurrentIteratorPrototype, IteratorPrototype);\n } else if (!isCallable(CurrentIteratorPrototype[ITERATOR])) {\n redefine(CurrentIteratorPrototype, ITERATOR, returnThis);\n }\n }\n // Set @@toStringTag to native iterators\n setToStringTag(CurrentIteratorPrototype, TO_STRING_TAG, true, true);\n if (IS_PURE) Iterators[TO_STRING_TAG] = returnThis;\n }\n }\n\n // fix Array.prototype.{ values, @@iterator }.name in V8 / FF\n if (PROPER_FUNCTION_NAME && DEFAULT == VALUES && nativeIterator && nativeIterator.name !== VALUES) {\n if (!IS_PURE && CONFIGURABLE_FUNCTION_NAME) {\n createNonEnumerableProperty(IterablePrototype, 'name', VALUES);\n } else {\n INCORRECT_VALUES_NAME = true;\n defaultIterator = function values() { return call(nativeIterator, this); };\n }\n }\n\n // export additional methods\n if (DEFAULT) {\n methods = {\n values: getIterationMethod(VALUES),\n keys: IS_SET ? defaultIterator : getIterationMethod(KEYS),\n entries: getIterationMethod(ENTRIES)\n };\n if (FORCED) for (KEY in methods) {\n if (BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME || !(KEY in IterablePrototype)) {\n redefine(IterablePrototype, KEY, methods[KEY]);\n }\n } else $({ target: NAME, proto: true, forced: BUGGY_SAFARI_ITERATORS || INCORRECT_VALUES_NAME }, methods);\n }\n\n // define iterator\n if ((!IS_PURE || FORCED) && IterablePrototype[ITERATOR] !== defaultIterator) {\n redefine(IterablePrototype, ITERATOR, defaultIterator, { name: DEFAULT });\n }\n Iterators[NAME] = defaultIterator;\n\n return methods;\n};\n","import { noop } from './basic';\nimport { isPromise } from './validate';\nexport function callInterceptor(interceptor, _ref) {\n var {\n args = [],\n done,\n canceled\n } = _ref;\n\n if (interceptor) {\n // eslint-disable-next-line prefer-spread\n var returnVal = interceptor.apply(null, args);\n\n if (isPromise(returnVal)) {\n returnVal.then(value => {\n if (value) {\n done();\n } else if (canceled) {\n canceled();\n }\n }).catch(noop);\n } else if (returnVal) {\n done();\n } else if (canceled) {\n canceled();\n }\n } else {\n done();\n }\n}","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\nvar inspectSource = require('../internals/inspect-source');\n\nvar WeakMap = global.WeakMap;\n\nmodule.exports = isCallable(WeakMap) && /native code/.test(inspectSource(WeakMap));\n","import { unref, ref, inject, getCurrentInstance, onUnmounted, computed, reactive, isVNode, provide, onBeforeUnmount, onActivated, onDeactivated, onMounted, nextTick, isRef, watch } from 'vue';\n\nconst inBrowser = typeof window !== \"undefined\";\nconst supportsPassive = true;\nfunction raf(fn) {\n return inBrowser ? requestAnimationFrame(fn) : -1;\n}\nfunction cancelRaf(id) {\n if (inBrowser) {\n cancelAnimationFrame(id);\n }\n}\nfunction doubleRaf(fn) {\n raf(() => raf(fn));\n}\n\nconst isWindow = (val) => val === window;\nconst makeDOMRect = (width, height) => ({\n top: 0,\n left: 0,\n right: width,\n bottom: height,\n width,\n height\n});\nconst useRect = (elementOrRef) => {\n const element = unref(elementOrRef);\n if (isWindow(element)) {\n const width = element.innerWidth;\n const height = element.innerHeight;\n return makeDOMRect(width, height);\n }\n if (element == null ? void 0 : element.getBoundingClientRect) {\n return element.getBoundingClientRect();\n }\n return makeDOMRect(0, 0);\n};\n\nfunction useToggle(defaultValue = false) {\n const state = ref(defaultValue);\n const toggle = (value = !state.value) => {\n state.value = value;\n };\n return [state, toggle];\n}\n\nfunction useParent(key) {\n const parent = inject(key, null);\n if (parent) {\n const instance = getCurrentInstance();\n const { link, unlink, internalChildren } = parent;\n link(instance);\n onUnmounted(() => unlink(instance));\n const index = computed(() => internalChildren.indexOf(instance));\n return {\n parent,\n index\n };\n }\n return {\n parent: null,\n index: ref(-1)\n };\n}\n\nfunction flattenVNodes(children) {\n const result = [];\n const traverse = (children2) => {\n if (Array.isArray(children2)) {\n children2.forEach((child) => {\n var _a;\n if (isVNode(child)) {\n result.push(child);\n if ((_a = child.component) == null ? void 0 : _a.subTree) {\n traverse(child.component.subTree.children);\n }\n if (child.children) {\n traverse(child.children);\n }\n }\n });\n }\n };\n traverse(children);\n return result;\n}\nfunction sortChildren(parent, publicChildren, internalChildren) {\n const vnodes = flattenVNodes(parent.subTree.children);\n internalChildren.sort((a, b) => vnodes.indexOf(a.vnode) - vnodes.indexOf(b.vnode));\n const orderedPublicChildren = internalChildren.map((item) => item.proxy);\n publicChildren.sort((a, b) => {\n const indexA = orderedPublicChildren.indexOf(a);\n const indexB = orderedPublicChildren.indexOf(b);\n return indexA - indexB;\n });\n}\nfunction useChildren(key) {\n const publicChildren = reactive([]);\n const internalChildren = reactive([]);\n const parent = getCurrentInstance();\n const linkChildren = (value) => {\n const link = (child) => {\n if (child.proxy) {\n internalChildren.push(child);\n publicChildren.push(child.proxy);\n sortChildren(parent, publicChildren, internalChildren);\n }\n };\n const unlink = (child) => {\n const index = internalChildren.indexOf(child);\n publicChildren.splice(index, 1);\n internalChildren.splice(index, 1);\n };\n provide(key, Object.assign({\n link,\n unlink,\n children: publicChildren,\n internalChildren\n }, value));\n };\n return {\n children: publicChildren,\n linkChildren\n };\n}\n\nconst SECOND = 1e3;\nconst MINUTE = 60 * SECOND;\nconst HOUR = 60 * MINUTE;\nconst DAY = 24 * HOUR;\nfunction parseTime(time) {\n const days = Math.floor(time / DAY);\n const hours = Math.floor(time % DAY / HOUR);\n const minutes = Math.floor(time % HOUR / MINUTE);\n const seconds = Math.floor(time % MINUTE / SECOND);\n const milliseconds = Math.floor(time % SECOND);\n return {\n total: time,\n days,\n hours,\n minutes,\n seconds,\n milliseconds\n };\n}\nfunction isSameSecond(time1, time2) {\n return Math.floor(time1 / 1e3) === Math.floor(time2 / 1e3);\n}\nfunction useCountDown(options) {\n let rafId;\n let endTime;\n let counting;\n let deactivated;\n const remain = ref(options.time);\n const current = computed(() => parseTime(remain.value));\n const pause = () => {\n counting = false;\n cancelRaf(rafId);\n };\n const getCurrentRemain = () => Math.max(endTime - Date.now(), 0);\n const setRemain = (value) => {\n var _a, _b;\n remain.value = value;\n (_a = options.onChange) == null ? void 0 : _a.call(options, current.value);\n if (value === 0) {\n pause();\n (_b = options.onFinish) == null ? void 0 : _b.call(options);\n }\n };\n const microTick = () => {\n rafId = raf(() => {\n if (counting) {\n setRemain(getCurrentRemain());\n if (remain.value > 0) {\n microTick();\n }\n }\n });\n };\n const macroTick = () => {\n rafId = raf(() => {\n if (counting) {\n const remainRemain = getCurrentRemain();\n if (!isSameSecond(remainRemain, remain.value) || remainRemain === 0) {\n setRemain(remainRemain);\n }\n if (remain.value > 0) {\n macroTick();\n }\n }\n });\n };\n const tick = () => {\n if (!inBrowser) {\n return;\n }\n if (options.millisecond) {\n microTick();\n } else {\n macroTick();\n }\n };\n const start = () => {\n if (!counting) {\n endTime = Date.now() + remain.value;\n counting = true;\n tick();\n }\n };\n const reset = (totalTime = options.time) => {\n pause();\n remain.value = totalTime;\n };\n onBeforeUnmount(pause);\n onActivated(() => {\n if (deactivated) {\n counting = true;\n deactivated = false;\n tick();\n }\n });\n onDeactivated(() => {\n if (counting) {\n pause();\n deactivated = true;\n }\n });\n return {\n start,\n pause,\n reset,\n current\n };\n}\n\nfunction onMountedOrActivated(hook) {\n let mounted;\n onMounted(() => {\n hook();\n nextTick(() => {\n mounted = true;\n });\n });\n onActivated(() => {\n if (mounted) {\n hook();\n }\n });\n}\n\nfunction useEventListener(type, listener, options = {}) {\n if (!inBrowser) {\n return;\n }\n const { target = window, passive = false, capture = false } = options;\n let attached;\n const add = (target2) => {\n const element = unref(target2);\n if (element && !attached) {\n element.addEventListener(type, listener, { capture, passive });\n attached = true;\n }\n };\n const remove = (target2) => {\n const element = unref(target2);\n if (element && attached) {\n element.removeEventListener(type, listener, capture);\n attached = false;\n }\n };\n onUnmounted(() => remove(target));\n onDeactivated(() => remove(target));\n onMountedOrActivated(() => add(target));\n if (isRef(target)) {\n watch(target, (val, oldVal) => {\n remove(oldVal);\n add(val);\n });\n }\n}\n\nfunction useClickAway(target, listener, options = {}) {\n if (!inBrowser) {\n return;\n }\n const { eventName = \"click\" } = options;\n const onClick = (event) => {\n const element = unref(target);\n if (element && !element.contains(event.target)) {\n listener(event);\n }\n };\n useEventListener(eventName, onClick, { target: document });\n}\n\nlet width;\nlet height;\nfunction useWindowSize() {\n if (!width) {\n width = ref(0);\n height = ref(0);\n if (inBrowser) {\n const update = () => {\n width.value = window.innerWidth;\n height.value = window.innerHeight;\n };\n update();\n window.addEventListener(\"resize\", update, { passive: true });\n window.addEventListener(\"orientationchange\", update, { passive: true });\n }\n }\n return { width, height };\n}\n\nconst overflowScrollReg = /scroll|auto/i;\nconst defaultRoot = inBrowser ? window : void 0;\nfunction isElement(node) {\n const ELEMENT_NODE_TYPE = 1;\n return node.tagName !== \"HTML\" && node.tagName !== \"BODY\" && node.nodeType === ELEMENT_NODE_TYPE;\n}\nfunction getScrollParent(el, root = defaultRoot) {\n let node = el;\n while (node && node !== root && isElement(node)) {\n const { overflowY } = window.getComputedStyle(node);\n if (overflowScrollReg.test(overflowY)) {\n return node;\n }\n node = node.parentNode;\n }\n return root;\n}\nfunction useScrollParent(el, root = defaultRoot) {\n const scrollParent = ref();\n onMounted(() => {\n if (el.value) {\n scrollParent.value = getScrollParent(el.value, root);\n }\n });\n return scrollParent;\n}\n\nlet visibility;\nfunction usePageVisibility() {\n if (!visibility) {\n visibility = ref(\"visible\");\n if (inBrowser) {\n const update = () => {\n visibility.value = document.hidden ? \"hidden\" : \"visible\";\n };\n update();\n window.addEventListener(\"visibilitychange\", update);\n }\n }\n return visibility;\n}\n\nconst CUSTOM_FIELD_INJECTION_KEY = Symbol(\"van-field\");\nfunction useCustomFieldValue(customValue) {\n const field = inject(CUSTOM_FIELD_INJECTION_KEY, null);\n if (field && !field.customValue.value) {\n field.customValue.value = customValue;\n watch(customValue, () => {\n field.resetValidation();\n field.validateWithTrigger(\"onChange\");\n });\n }\n}\n\nexport { CUSTOM_FIELD_INJECTION_KEY, cancelRaf, doubleRaf, flattenVNodes, getScrollParent, inBrowser, onMountedOrActivated, raf, sortChildren, supportsPassive, useChildren, useClickAway, useCountDown, useCustomFieldValue, useEventListener, usePageVisibility, useParent, useRect, useScrollParent, useToggle, useWindowSize };\n","import '../../style/base.css';\nimport '../../row/index.css';\nimport '../index.css';","var global = require('../internals/global');\nvar isObject = require('../internals/is-object');\n\nvar String = global.String;\nvar TypeError = global.TypeError;\n\n// `Assert: Type(argument) is Object`\nmodule.exports = function (argument) {\n if (isObject(argument)) return argument;\n throw TypeError(String(argument) + ' is not an object');\n};\n","var fails = require('../internals/fails');\n\n// Detect IE8's incomplete defineProperty implementation\nmodule.exports = !fails(function () {\n // eslint-disable-next-line es/no-object-defineproperty -- required for testing\n return Object.defineProperty({}, 1, { get: function () { return 7; } })[1] != 7;\n});\n","import { inBrowser } from './basic';\nimport { windowWidth, windowHeight } from './dom';\nimport { isDef, isNumeric } from './validate';\nexport function addUnit(value) {\n if (isDef(value)) {\n return isNumeric(value) ? value + \"px\" : String(value);\n }\n\n return undefined;\n}\nexport function getSizeStyle(originSize) {\n if (isDef(originSize)) {\n var size = addUnit(originSize);\n return {\n width: size,\n height: size\n };\n }\n}\nexport function getZIndexStyle(zIndex) {\n var style = {};\n\n if (zIndex !== undefined) {\n style.zIndex = +zIndex;\n }\n\n return style;\n} // cache\n\nvar rootFontSize;\n\nfunction getRootFontSize() {\n if (!rootFontSize) {\n var doc = document.documentElement;\n var fontSize = doc.style.fontSize || window.getComputedStyle(doc).fontSize;\n rootFontSize = parseFloat(fontSize);\n }\n\n return rootFontSize;\n}\n\nfunction convertRem(value) {\n value = value.replace(/rem/g, '');\n return +value * getRootFontSize();\n}\n\nfunction convertVw(value) {\n value = value.replace(/vw/g, '');\n return +value * windowWidth.value / 100;\n}\n\nfunction convertVh(value) {\n value = value.replace(/vh/g, '');\n return +value * windowHeight.value / 100;\n}\n\nexport function unitToPx(value) {\n if (typeof value === 'number') {\n return value;\n }\n\n if (inBrowser) {\n if (value.includes('rem')) {\n return convertRem(value);\n }\n\n if (value.includes('vw')) {\n return convertVw(value);\n }\n\n if (value.includes('vh')) {\n return convertVh(value);\n }\n }\n\n return parseFloat(value);\n}\nvar camelizeRE = /-(\\w)/g;\nexport var camelize = str => str.replace(camelizeRE, (_, c) => c.toUpperCase());\nexport var kebabCase = str => str.replace(/([A-Z])/g, '-$1').toLowerCase().replace(/^-/, '');\nexport function padZero(num, targetLength) {\n if (targetLength === void 0) {\n targetLength = 2;\n }\n\n var str = num + '';\n\n while (str.length < targetLength) {\n str = '0' + str;\n }\n\n return str;\n}\n/** clamps number within the inclusive lower and upper bounds */\n\nexport var clamp = (num, min, max) => Math.min(Math.max(num, min), max);\n\nfunction trimExtraChar(value, char, regExp) {\n var index = value.indexOf(char);\n\n if (index === -1) {\n return value;\n }\n\n if (char === '-' && index !== 0) {\n return value.slice(0, index);\n }\n\n return value.slice(0, index + 1) + value.slice(index).replace(regExp, '');\n}\n\nexport function formatNumber(value, allowDot, allowMinus) {\n if (allowDot === void 0) {\n allowDot = true;\n }\n\n if (allowMinus === void 0) {\n allowMinus = true;\n }\n\n if (allowDot) {\n value = trimExtraChar(value, '.', /\\./g);\n } else {\n value = value.split('.')[0];\n }\n\n if (allowMinus) {\n value = trimExtraChar(value, '-', /-/g);\n } else {\n value = value.replace(/-/, '');\n }\n\n var regExp = allowDot ? /[^-0-9.]/g : /[^-0-9]/g;\n return value.replace(regExp, '');\n} // add num and avoid float number\n\nexport function addNumber(num1, num2) {\n var cardinal = Math.pow(10, 10);\n return Math.round((num1 + num2) * cardinal) / cardinal;\n}","'use strict';\nvar toPropertyKey = require('../internals/to-property-key');\nvar definePropertyModule = require('../internals/object-define-property');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\n\nmodule.exports = function (object, key, value) {\n var propertyKey = toPropertyKey(key);\n if (propertyKey in object) definePropertyModule.f(object, propertyKey, createPropertyDescriptor(0, value));\n else object[propertyKey] = value;\n};\n","var isCallable = require('../internals/is-callable');\n\nmodule.exports = function (it) {\n return typeof it == 'object' ? it !== null : isCallable(it);\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar isCallable = require('../internals/is-callable');\nvar store = require('../internals/shared-store');\n\nvar functionToString = uncurryThis(Function.toString);\n\n// this helper broken in `core-js@3.4.1-3.4.4`, so we can't use `shared` helper\nif (!isCallable(store.inspectSource)) {\n store.inspectSource = function (it) {\n return functionToString(it);\n };\n}\n\nmodule.exports = store.inspectSource;\n","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../../icon/index.css';\nimport '../../overlay/index.css';\nimport '../index.css';","'use strict';\nvar charAt = require('../internals/string-multibyte').charAt;\n\n// `AdvanceStringIndex` abstract operation\n// https://tc39.es/ecma262/#sec-advancestringindex\nmodule.exports = function (S, index, unicode) {\n return index + (unicode ? charAt(S, index).length : 1);\n};\n","import { inBrowser } from './basic';\nexport var isDef = val => val !== undefined && val !== null; // eslint-disable-next-line @typescript-eslint/ban-types\n\nexport var isFunction = val => typeof val === 'function';\nexport var isObject = val => val !== null && typeof val === 'object';\nexport var isPromise = val => isObject(val) && isFunction(val.then) && isFunction(val.catch);\nexport var isDate = val => Object.prototype.toString.call(val) === '[object Date]' && !Number.isNaN(val.getTime());\nexport function isMobile(value) {\n value = value.replace(/[^-|\\d]/g, '');\n return /^((\\+86)|(86))?(1)\\d{10}$/.test(value) || /^0[0-9-]{10,13}$/.test(value);\n}\nexport var isNumeric = val => typeof val === 'number' || /^\\d+(\\.\\d+)?$/.test(val);\nexport var isIOS = () => inBrowser ? /ios|iphone|ipad|ipod/.test(navigator.userAgent.toLowerCase()) : false;","import { createNamespace, isFunction } from '../utils';\nvar [name, bem, t] = createNamespace('uploader');\nexport { name, bem, t };\nexport var toArray = item => Array.isArray(item) ? item : [item];\nexport function readFileContent(file, resultType) {\n return new Promise(resolve => {\n if (resultType === 'file') {\n resolve();\n return;\n }\n\n var reader = new FileReader();\n\n reader.onload = event => {\n resolve(event.target.result);\n };\n\n if (resultType === 'dataUrl') {\n reader.readAsDataURL(file);\n } else if (resultType === 'text') {\n reader.readAsText(file);\n }\n });\n}\nexport function isOversize(items, maxSize) {\n return toArray(items).some(item => {\n if (item.file) {\n if (isFunction(maxSize)) {\n return maxSize(item.file);\n }\n\n return item.file.size > maxSize;\n }\n\n return false;\n });\n}\nexport function filterFiles(items, maxSize) {\n var valid = [];\n var invalid = [];\n items.forEach(item => {\n if (isOversize(item, maxSize)) {\n invalid.push(item);\n } else {\n valid.push(item);\n }\n });\n return {\n valid,\n invalid\n };\n}\nvar IMAGE_REGEXP = /\\.(jpeg|jpg|gif|png|svg|webp|jfif|bmp|dpg)/i;\nexport var isImageUrl = url => IMAGE_REGEXP.test(url);\nexport function isImageFile(item) {\n // some special urls cannot be recognized\n // user can add `isImage` flag to mark it as an image url\n if (item.isImage) {\n return true;\n }\n\n if (item.file && item.file.type) {\n return item.file.type.indexOf('image') === 0;\n }\n\n if (item.url) {\n return isImageUrl(item.url);\n }\n\n if (typeof item.content === 'string') {\n return item.content.indexOf('data:image') === 0;\n }\n\n return false;\n}","import { resolveDirective as _resolveDirective, createVNode as _createVNode } from \"vue\";\nimport { defineComponent } from 'vue'; // Utils\n\nimport { t, bem, isImageFile } from './utils';\nimport { isDef, extend, numericProp, getSizeStyle, callInterceptor, makeRequiredProp } from '../utils'; // Components\n\nimport { Icon } from '../icon';\nimport { Image } from '../image';\nimport { Loading } from '../loading'; // Types\n\nexport default defineComponent({\n props: {\n name: numericProp,\n item: makeRequiredProp(Object),\n index: Number,\n imageFit: String,\n lazyLoad: Boolean,\n deletable: Boolean,\n previewSize: numericProp,\n beforeDelete: Function\n },\n emits: ['delete', 'preview'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n\n var renderMask = () => {\n var {\n status,\n message\n } = props.item;\n\n if (status === 'uploading' || status === 'failed') {\n var MaskIcon = status === 'failed' ? _createVNode(Icon, {\n \"name\": \"close\",\n \"class\": bem('mask-icon')\n }, null) : _createVNode(Loading, {\n \"class\": bem('loading')\n }, null);\n var showMessage = isDef(message) && message !== '';\n return _createVNode(\"div\", {\n \"class\": bem('mask')\n }, [MaskIcon, showMessage && _createVNode(\"div\", {\n \"class\": bem('mask-message')\n }, [message])]);\n }\n };\n\n var onDelete = event => {\n var {\n name,\n item,\n index,\n beforeDelete\n } = props;\n event.stopPropagation();\n callInterceptor(beforeDelete, {\n args: [item, {\n name,\n index\n }],\n done: () => emit('delete')\n });\n };\n\n var onPreview = () => emit('preview');\n\n var renderDeleteIcon = () => {\n if (props.deletable && props.item.status !== 'uploading') {\n return _createVNode(\"div\", {\n \"role\": \"button\",\n \"class\": bem('preview-delete'),\n \"tabindex\": 0,\n \"aria-label\": t('delete'),\n \"onClick\": onDelete\n }, [_createVNode(Icon, {\n \"name\": \"cross\",\n \"class\": bem('preview-delete-icon')\n }, null)]);\n }\n };\n\n var renderCover = () => {\n if (slots['preview-cover']) {\n var {\n index,\n item\n } = props;\n return _createVNode(\"div\", {\n \"class\": bem('preview-cover')\n }, [slots['preview-cover'](extend({\n index\n }, item))]);\n }\n };\n\n var renderPreview = () => {\n var {\n item\n } = props;\n\n if (isImageFile(item)) {\n return _createVNode(Image, {\n \"fit\": props.imageFit,\n \"src\": item.content || item.url,\n \"class\": bem('preview-image'),\n \"width\": props.previewSize,\n \"height\": props.previewSize,\n \"lazyLoad\": props.lazyLoad,\n \"onClick\": onPreview\n }, {\n default: renderCover\n });\n }\n\n return _createVNode(\"div\", {\n \"class\": bem('file'),\n \"style\": getSizeStyle(props.previewSize)\n }, [_createVNode(Icon, {\n \"class\": bem('file-icon'),\n \"name\": \"description\"\n }, null), _createVNode(\"div\", {\n \"class\": [bem('file-name'), 'van-ellipsis']\n }, [item.file ? item.file.name : item.url]), renderCover()]);\n };\n\n return () => _createVNode(\"div\", {\n \"class\": bem('preview')\n }, [renderPreview(), renderMask(), renderDeleteIcon()]);\n }\n\n});","import { createVNode as _createVNode, mergeProps as _mergeProps, resolveDirective as _resolveDirective } from \"vue\";\nimport { ref, reactive, defineComponent, onBeforeUnmount } from 'vue'; // Utils\n\nimport { pick, extend, isPromise, truthProp, numericProp, getSizeStyle, makeArrayProp, makeStringProp, makeNumericProp } from '../utils';\nimport { bem, name, toArray, isOversize, filterFiles, isImageFile, readFileContent } from './utils'; // Composables\n\nimport { useCustomFieldValue } from '@vant/use';\nimport { useExpose } from '../composables/use-expose'; // Components\n\nimport { Icon } from '../icon';\nimport { ImagePreview } from '../image-preview';\nimport UploaderPreviewItem from './UploaderPreviewItem'; // Types\n\nvar uploaderProps = {\n name: makeNumericProp(''),\n accept: makeStringProp('image/*'),\n capture: String,\n multiple: Boolean,\n disabled: Boolean,\n readonly: Boolean,\n lazyLoad: Boolean,\n maxCount: makeNumericProp(Infinity),\n imageFit: makeStringProp('cover'),\n resultType: makeStringProp('dataUrl'),\n uploadIcon: makeStringProp('photograph'),\n uploadText: String,\n deletable: truthProp,\n afterRead: Function,\n showUpload: truthProp,\n modelValue: makeArrayProp(),\n beforeRead: Function,\n beforeDelete: Function,\n previewSize: numericProp,\n previewImage: truthProp,\n previewOptions: Object,\n previewFullImage: truthProp,\n maxSize: {\n type: [Number, String, Function],\n default: Infinity\n }\n};\nexport default defineComponent({\n name,\n props: uploaderProps,\n emits: ['delete', 'oversize', 'click-upload', 'close-preview', 'click-preview', 'update:modelValue'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var inputRef = ref();\n var urls = [];\n\n var getDetail = function (index) {\n if (index === void 0) {\n index = props.modelValue.length;\n }\n\n return {\n name: props.name,\n index\n };\n };\n\n var resetInput = () => {\n if (inputRef.value) {\n inputRef.value.value = '';\n }\n };\n\n var onAfterRead = items => {\n resetInput();\n\n if (isOversize(items, props.maxSize)) {\n if (Array.isArray(items)) {\n var result = filterFiles(items, props.maxSize);\n items = result.valid;\n emit('oversize', result.invalid, getDetail());\n\n if (!items.length) {\n return;\n }\n } else {\n emit('oversize', items, getDetail());\n return;\n }\n }\n\n items = reactive(items);\n emit('update:modelValue', [...props.modelValue, ...toArray(items)]);\n\n if (props.afterRead) {\n props.afterRead(items, getDetail());\n }\n };\n\n var readFile = files => {\n var {\n maxCount,\n modelValue,\n resultType\n } = props;\n\n if (Array.isArray(files)) {\n var remainCount = +maxCount - modelValue.length;\n\n if (files.length > remainCount) {\n files = files.slice(0, remainCount);\n }\n\n Promise.all(files.map(file => readFileContent(file, resultType))).then(contents => {\n var fileList = files.map((file, index) => {\n var result = {\n file,\n status: '',\n message: ''\n };\n\n if (contents[index]) {\n result.content = contents[index];\n }\n\n return result;\n });\n onAfterRead(fileList);\n });\n } else {\n readFileContent(files, resultType).then(content => {\n var result = {\n file: files,\n status: '',\n message: ''\n };\n\n if (content) {\n result.content = content;\n }\n\n onAfterRead(result);\n });\n }\n };\n\n var onChange = event => {\n var {\n files\n } = event.target;\n\n if (props.disabled || !files || !files.length) {\n return;\n }\n\n var file = files.length === 1 ? files[0] : [].slice.call(files);\n\n if (props.beforeRead) {\n var response = props.beforeRead(file, getDetail());\n\n if (!response) {\n resetInput();\n return;\n }\n\n if (isPromise(response)) {\n response.then(data => {\n if (data) {\n readFile(data);\n } else {\n readFile(file);\n }\n }).catch(resetInput);\n return;\n }\n }\n\n readFile(file);\n };\n\n var imagePreview;\n\n var onClosePreview = () => emit('close-preview');\n\n var previewImage = item => {\n if (props.previewFullImage) {\n var imageFiles = props.modelValue.filter(isImageFile);\n var images = imageFiles.map(item => {\n if (item.file && !item.url) {\n item.url = URL.createObjectURL(item.file);\n urls.push(item.url);\n }\n\n return item.url;\n }).filter(Boolean);\n imagePreview = ImagePreview(extend({\n images,\n startPosition: imageFiles.indexOf(item),\n onClose: onClosePreview\n }, props.previewOptions));\n }\n };\n\n var closeImagePreview = () => {\n if (imagePreview) {\n imagePreview.close();\n }\n };\n\n var deleteFile = (item, index) => {\n var fileList = props.modelValue.slice(0);\n fileList.splice(index, 1);\n emit('update:modelValue', fileList);\n emit('delete', item, getDetail(index));\n };\n\n var renderPreviewItem = (item, index) => {\n var needPickData = ['imageFit', 'deletable', 'previewSize', 'beforeDelete'];\n var previewData = extend(pick(props, needPickData), pick(item, needPickData, true));\n return _createVNode(UploaderPreviewItem, _mergeProps({\n \"item\": item,\n \"index\": index,\n \"onClick\": () => emit('click-preview', item, getDetail(index)),\n \"onDelete\": () => deleteFile(item, index),\n \"onPreview\": () => previewImage(item)\n }, pick(props, ['name', 'lazyLoad']), previewData), {\n 'preview-cover': slots['preview-cover']\n });\n };\n\n var renderPreviewList = () => {\n if (props.previewImage) {\n return props.modelValue.map(renderPreviewItem);\n }\n };\n\n var onClickUpload = event => emit('click-upload', event);\n\n var renderUpload = () => {\n if (props.modelValue.length >= props.maxCount || !props.showUpload) {\n return;\n }\n\n var Input = props.readonly ? null : _createVNode(\"input\", {\n \"ref\": inputRef,\n \"type\": \"file\",\n \"class\": bem('input'),\n \"accept\": props.accept,\n \"capture\": props.capture,\n \"multiple\": props.multiple,\n \"disabled\": props.disabled,\n \"onChange\": onChange\n }, null);\n\n if (slots.default) {\n return _createVNode(\"div\", {\n \"class\": bem('input-wrapper'),\n \"onClick\": onClickUpload\n }, [slots.default(), Input]);\n }\n\n return _createVNode(\"div\", {\n \"class\": bem('upload', {\n readonly: props.readonly\n }),\n \"style\": getSizeStyle(props.previewSize),\n \"onClick\": onClickUpload\n }, [_createVNode(Icon, {\n \"name\": props.uploadIcon,\n \"class\": bem('upload-icon')\n }, null), props.uploadText && _createVNode(\"span\", {\n \"class\": bem('upload-text')\n }, [props.uploadText]), Input]);\n };\n\n var chooseFile = () => {\n if (inputRef.value && !props.disabled) {\n inputRef.value.click();\n }\n };\n\n onBeforeUnmount(() => {\n urls.forEach(url => URL.revokeObjectURL(url));\n });\n useExpose({\n chooseFile,\n closeImagePreview\n });\n useCustomFieldValue(() => props.modelValue);\n return () => _createVNode(\"div\", {\n \"class\": bem()\n }, [_createVNode(\"div\", {\n \"class\": bem('wrapper', {\n disabled: props.disabled\n })\n }, [renderPreviewList(), renderUpload()])]);\n }\n\n});","import { withInstall } from '../utils';\nimport _Uploader from './Uploader';\nexport var Uploader = withInstall(_Uploader);\nexport default Uploader;","var uncurryThis = require('../internals/function-uncurry-this');\n\nvar id = 0;\nvar postfix = Math.random();\nvar toString = uncurryThis(1.0.toString);\n\nmodule.exports = function (key) {\n return 'Symbol(' + (key === undefined ? '' : key) + ')_' + toString(++id + postfix, 36);\n};\n","var DESCRIPTORS = require('../internals/descriptors');\nvar definePropertyModule = require('../internals/object-define-property');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\n\nmodule.exports = DESCRIPTORS ? function (object, key, value) {\n return definePropertyModule.f(object, key, createPropertyDescriptor(1, value));\n} : function (object, key, value) {\n object[key] = value;\n return object;\n};\n","'use strict';\n/* eslint-disable regexp/no-empty-capturing-group, regexp/no-empty-group, regexp/no-lazy-ends -- testing */\n/* eslint-disable regexp/no-useless-quantifier -- testing */\nvar call = require('../internals/function-call');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar toString = require('../internals/to-string');\nvar regexpFlags = require('../internals/regexp-flags');\nvar stickyHelpers = require('../internals/regexp-sticky-helpers');\nvar shared = require('../internals/shared');\nvar create = require('../internals/object-create');\nvar getInternalState = require('../internals/internal-state').get;\nvar UNSUPPORTED_DOT_ALL = require('../internals/regexp-unsupported-dot-all');\nvar UNSUPPORTED_NCG = require('../internals/regexp-unsupported-ncg');\n\nvar nativeReplace = shared('native-string-replace', String.prototype.replace);\nvar nativeExec = RegExp.prototype.exec;\nvar patchedExec = nativeExec;\nvar charAt = uncurryThis(''.charAt);\nvar indexOf = uncurryThis(''.indexOf);\nvar replace = uncurryThis(''.replace);\nvar stringSlice = uncurryThis(''.slice);\n\nvar UPDATES_LAST_INDEX_WRONG = (function () {\n var re1 = /a/;\n var re2 = /b*/g;\n call(nativeExec, re1, 'a');\n call(nativeExec, re2, 'a');\n return re1.lastIndex !== 0 || re2.lastIndex !== 0;\n})();\n\nvar UNSUPPORTED_Y = stickyHelpers.BROKEN_CARET;\n\n// nonparticipating capturing group, copied from es5-shim's String#split patch.\nvar NPCG_INCLUDED = /()??/.exec('')[1] !== undefined;\n\nvar PATCH = UPDATES_LAST_INDEX_WRONG || NPCG_INCLUDED || UNSUPPORTED_Y || UNSUPPORTED_DOT_ALL || UNSUPPORTED_NCG;\n\nif (PATCH) {\n patchedExec = function exec(string) {\n var re = this;\n var state = getInternalState(re);\n var str = toString(string);\n var raw = state.raw;\n var result, reCopy, lastIndex, match, i, object, group;\n\n if (raw) {\n raw.lastIndex = re.lastIndex;\n result = call(patchedExec, raw, str);\n re.lastIndex = raw.lastIndex;\n return result;\n }\n\n var groups = state.groups;\n var sticky = UNSUPPORTED_Y && re.sticky;\n var flags = call(regexpFlags, re);\n var source = re.source;\n var charsAdded = 0;\n var strCopy = str;\n\n if (sticky) {\n flags = replace(flags, 'y', '');\n if (indexOf(flags, 'g') === -1) {\n flags += 'g';\n }\n\n strCopy = stringSlice(str, re.lastIndex);\n // Support anchored sticky behavior.\n if (re.lastIndex > 0 && (!re.multiline || re.multiline && charAt(str, re.lastIndex - 1) !== '\\n')) {\n source = '(?: ' + source + ')';\n strCopy = ' ' + strCopy;\n charsAdded++;\n }\n // ^(? + rx + ) is needed, in combination with some str slicing, to\n // simulate the 'y' flag.\n reCopy = new RegExp('^(?:' + source + ')', flags);\n }\n\n if (NPCG_INCLUDED) {\n reCopy = new RegExp('^' + source + '$(?!\\\\s)', flags);\n }\n if (UPDATES_LAST_INDEX_WRONG) lastIndex = re.lastIndex;\n\n match = call(nativeExec, sticky ? reCopy : re, strCopy);\n\n if (sticky) {\n if (match) {\n match.input = stringSlice(match.input, charsAdded);\n match[0] = stringSlice(match[0], charsAdded);\n match.index = re.lastIndex;\n re.lastIndex += match[0].length;\n } else re.lastIndex = 0;\n } else if (UPDATES_LAST_INDEX_WRONG && match) {\n re.lastIndex = re.global ? match.index + match[0].length : lastIndex;\n }\n if (NPCG_INCLUDED && match && match.length > 1) {\n // Fix browsers whose `exec` methods don't consistently return `undefined`\n // for NPCG, like IE8. NOTE: This doesn' work for /(.?)?/\n call(nativeReplace, match[0], reCopy, function () {\n for (i = 1; i < arguments.length - 2; i++) {\n if (arguments[i] === undefined) match[i] = undefined;\n }\n });\n }\n\n if (match && groups) {\n match.groups = object = create(null);\n for (i = 0; i < groups.length; i++) {\n group = groups[i];\n object[group[0]] = match[group[1]];\n }\n }\n\n return match;\n };\n}\n\nmodule.exports = patchedExec;\n","var fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\n\nvar replacement = /#|\\.prototype\\./;\n\nvar isForced = function (feature, detection) {\n var value = data[normalize(feature)];\n return value == POLYFILL ? true\n : value == NATIVE ? false\n : isCallable(detection) ? fails(detection)\n : !!detection;\n};\n\nvar normalize = isForced.normalize = function (string) {\n return String(string).replace(replacement, '.').toLowerCase();\n};\n\nvar data = isForced.data = {};\nvar NATIVE = isForced.NATIVE = 'N';\nvar POLYFILL = isForced.POLYFILL = 'P';\n\nmodule.exports = isForced;\n","import { createVNode as _createVNode } from \"vue\";\nimport { watch, defineComponent } from 'vue'; // Utils\n\nimport { numericProp, createNamespace, makeArrayProp } from '../utils'; // Composables\n\nimport { useChildren, useCustomFieldValue } from '@vant/use';\nimport { useExpose } from '../composables/use-expose'; // Types\n\nvar [name, bem] = createNamespace('checkbox-group');\nvar checkboxGroupProps = {\n max: numericProp,\n disabled: Boolean,\n iconSize: numericProp,\n direction: String,\n modelValue: makeArrayProp(),\n checkedColor: String\n};\nexport var CHECKBOX_GROUP_KEY = Symbol(name);\nexport default defineComponent({\n name,\n props: checkboxGroupProps,\n emits: ['change', 'update:modelValue'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var {\n children,\n linkChildren\n } = useChildren(CHECKBOX_GROUP_KEY);\n\n var updateValue = value => emit('update:modelValue', value);\n\n var toggleAll = function (options) {\n if (options === void 0) {\n options = {};\n }\n\n if (typeof options === 'boolean') {\n options = {\n checked: options\n };\n }\n\n var {\n checked,\n skipDisabled\n } = options;\n var checkedChildren = children.filter(item => {\n if (!item.props.bindGroup) {\n return false;\n }\n\n if (item.props.disabled && skipDisabled) {\n return item.checked.value;\n }\n\n return checked != null ? checked : !item.checked.value;\n });\n var names = checkedChildren.map(item => item.name);\n updateValue(names);\n };\n\n watch(() => props.modelValue, value => emit('change', value));\n useExpose({\n toggleAll\n });\n useCustomFieldValue(() => props.modelValue);\n linkChildren({\n props,\n updateValue\n });\n return () => _createVNode(\"div\", {\n \"class\": bem([props.direction])\n }, [slots.default == null ? void 0 : slots.default()]);\n }\n\n});","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar fails = require('../internals/fails');\nvar isArray = require('../internals/is-array');\nvar isObject = require('../internals/is-object');\nvar toObject = require('../internals/to-object');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar createProperty = require('../internals/create-property');\nvar arraySpeciesCreate = require('../internals/array-species-create');\nvar arrayMethodHasSpeciesSupport = require('../internals/array-method-has-species-support');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar V8_VERSION = require('../internals/engine-v8-version');\n\nvar IS_CONCAT_SPREADABLE = wellKnownSymbol('isConcatSpreadable');\nvar MAX_SAFE_INTEGER = 0x1FFFFFFFFFFFFF;\nvar MAXIMUM_ALLOWED_INDEX_EXCEEDED = 'Maximum allowed index exceeded';\nvar TypeError = global.TypeError;\n\n// We can't use this feature detection in V8 since it causes\n// deoptimization and serious performance degradation\n// https://github.com/zloirock/core-js/issues/679\nvar IS_CONCAT_SPREADABLE_SUPPORT = V8_VERSION >= 51 || !fails(function () {\n var array = [];\n array[IS_CONCAT_SPREADABLE] = false;\n return array.concat()[0] !== array;\n});\n\nvar SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('concat');\n\nvar isConcatSpreadable = function (O) {\n if (!isObject(O)) return false;\n var spreadable = O[IS_CONCAT_SPREADABLE];\n return spreadable !== undefined ? !!spreadable : isArray(O);\n};\n\nvar FORCED = !IS_CONCAT_SPREADABLE_SUPPORT || !SPECIES_SUPPORT;\n\n// `Array.prototype.concat` method\n// https://tc39.es/ecma262/#sec-array.prototype.concat\n// with adding support of @@isConcatSpreadable and @@species\n$({ target: 'Array', proto: true, forced: FORCED }, {\n // eslint-disable-next-line no-unused-vars -- required for `.length`\n concat: function concat(arg) {\n var O = toObject(this);\n var A = arraySpeciesCreate(O, 0);\n var n = 0;\n var i, k, length, len, E;\n for (i = -1, length = arguments.length; i < length; i++) {\n E = i === -1 ? O : arguments[i];\n if (isConcatSpreadable(E)) {\n len = lengthOfArrayLike(E);\n if (n + len > MAX_SAFE_INTEGER) throw TypeError(MAXIMUM_ALLOWED_INDEX_EXCEEDED);\n for (k = 0; k < len; k++, n++) if (k in E) createProperty(A, n, E[k]);\n } else {\n if (n >= MAX_SAFE_INTEGER) throw TypeError(MAXIMUM_ALLOWED_INDEX_EXCEEDED);\n createProperty(A, n++, E);\n }\n }\n A.length = n;\n return A;\n }\n});\n","var global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar aCallable = require('../internals/a-callable');\nvar anObject = require('../internals/an-object');\nvar tryToString = require('../internals/try-to-string');\nvar getIteratorMethod = require('../internals/get-iterator-method');\n\nvar TypeError = global.TypeError;\n\nmodule.exports = function (argument, usingIterator) {\n var iteratorMethod = arguments.length < 2 ? getIteratorMethod(argument) : usingIterator;\n if (aCallable(iteratorMethod)) return anObject(call(iteratorMethod, argument));\n throw TypeError(tryToString(argument) + ' is not iterable');\n};\n","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../../icon/index.css';\nimport '../../overlay/index.css';\nimport '../../popup/index.css';\nimport '../index.css';","var global = require('../internals/global');\nvar DESCRIPTORS = require('../internals/descriptors');\nvar IE8_DOM_DEFINE = require('../internals/ie8-dom-define');\nvar anObject = require('../internals/an-object');\nvar toPropertyKey = require('../internals/to-property-key');\n\nvar TypeError = global.TypeError;\n// eslint-disable-next-line es/no-object-defineproperty -- safe\nvar $defineProperty = Object.defineProperty;\n\n// `Object.defineProperty` method\n// https://tc39.es/ecma262/#sec-object.defineproperty\nexports.f = DESCRIPTORS ? $defineProperty : function defineProperty(O, P, Attributes) {\n anObject(O);\n P = toPropertyKey(P);\n anObject(Attributes);\n if (IE8_DOM_DEFINE) try {\n return $defineProperty(O, P, Attributes);\n } catch (error) { /* empty */ }\n if ('get' in Attributes || 'set' in Attributes) throw TypeError('Accessors not supported');\n if ('value' in Attributes) O[P] = Attributes.value;\n return O;\n};\n","'use strict';\nvar IteratorPrototype = require('../internals/iterators-core').IteratorPrototype;\nvar create = require('../internals/object-create');\nvar createPropertyDescriptor = require('../internals/create-property-descriptor');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar Iterators = require('../internals/iterators');\n\nvar returnThis = function () { return this; };\n\nmodule.exports = function (IteratorConstructor, NAME, next) {\n var TO_STRING_TAG = NAME + ' Iterator';\n IteratorConstructor.prototype = create(IteratorPrototype, { next: createPropertyDescriptor(1, next) });\n setToStringTag(IteratorConstructor, TO_STRING_TAG, false, true);\n Iterators[TO_STRING_TAG] = returnThis;\n return IteratorConstructor;\n};\n","import { createVNode as _createVNode, mergeProps as _mergeProps, resolveDirective as _resolveDirective } from \"vue\";\nimport { defineComponent } from 'vue'; // Utils\n\nimport { pick, createNamespace } from '../utils';\nimport { RADIO_KEY } from '../radio-group/RadioGroup'; // Composables\n\nimport { useParent } from '@vant/use'; // Components\n\nimport Checker, { checkerProps } from '../checkbox/Checker';\nvar [name, bem] = createNamespace('radio');\nexport default defineComponent({\n name,\n props: checkerProps,\n emits: ['update:modelValue'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var {\n parent\n } = useParent(RADIO_KEY);\n\n var checked = () => {\n var value = parent ? parent.props.modelValue : props.modelValue;\n return value === props.name;\n };\n\n var toggle = () => {\n if (parent) {\n parent.updateValue(props.name);\n } else {\n emit('update:modelValue', props.name);\n }\n };\n\n return () => _createVNode(Checker, _mergeProps({\n \"bem\": bem,\n \"role\": \"radio\",\n \"parent\": parent,\n \"checked\": checked(),\n \"onToggle\": toggle\n }, props), pick(slots, ['default', 'icon']));\n }\n\n});","import { withInstall } from '../utils';\nimport _Radio from './Radio';\nexport var Radio = withInstall(_Radio);\nexport default Radio;","var fails = require('../internals/fails');\nvar global = require('../internals/global');\n\n// babel-minify and Closure Compiler transpiles RegExp('a', 'y') -> /a/y and it causes SyntaxError\nvar $RegExp = global.RegExp;\n\nvar UNSUPPORTED_Y = fails(function () {\n var re = $RegExp('a', 'y');\n re.lastIndex = 2;\n return re.exec('abcd') != null;\n});\n\n// UC Browser bug\n// https://github.com/zloirock/core-js/issues/1008\nvar MISSED_STICKY = UNSUPPORTED_Y || fails(function () {\n return !$RegExp('a', 'y').sticky;\n});\n\nvar BROKEN_CARET = UNSUPPORTED_Y || fails(function () {\n // https://bugzilla.mozilla.org/show_bug.cgi?id=773687\n var re = $RegExp('^r', 'gy');\n re.lastIndex = 2;\n return re.exec('str') != null;\n});\n\nmodule.exports = {\n BROKEN_CARET: BROKEN_CARET,\n MISSED_STICKY: MISSED_STICKY,\n UNSUPPORTED_Y: UNSUPPORTED_Y\n};\n","/**\r\n * Make a map and return a function for checking if a key\r\n * is in that map.\r\n * IMPORTANT: all calls of this function must be prefixed with\r\n * \\/\\*#\\_\\_PURE\\_\\_\\*\\/\r\n * So that rollup can tree-shake them if necessary.\r\n */\r\nfunction makeMap(str, expectsLowerCase) {\r\n const map = Object.create(null);\r\n const list = str.split(',');\r\n for (let i = 0; i < list.length; i++) {\r\n map[list[i]] = true;\r\n }\r\n return expectsLowerCase ? val => !!map[val.toLowerCase()] : val => !!map[val];\r\n}\n\n/**\r\n * dev only flag -> name mapping\r\n */\r\nconst PatchFlagNames = {\r\n [1 /* TEXT */]: `TEXT`,\r\n [2 /* CLASS */]: `CLASS`,\r\n [4 /* STYLE */]: `STYLE`,\r\n [8 /* PROPS */]: `PROPS`,\r\n [16 /* FULL_PROPS */]: `FULL_PROPS`,\r\n [32 /* HYDRATE_EVENTS */]: `HYDRATE_EVENTS`,\r\n [64 /* STABLE_FRAGMENT */]: `STABLE_FRAGMENT`,\r\n [128 /* KEYED_FRAGMENT */]: `KEYED_FRAGMENT`,\r\n [256 /* UNKEYED_FRAGMENT */]: `UNKEYED_FRAGMENT`,\r\n [512 /* NEED_PATCH */]: `NEED_PATCH`,\r\n [1024 /* DYNAMIC_SLOTS */]: `DYNAMIC_SLOTS`,\r\n [2048 /* DEV_ROOT_FRAGMENT */]: `DEV_ROOT_FRAGMENT`,\r\n [-1 /* HOISTED */]: `HOISTED`,\r\n [-2 /* BAIL */]: `BAIL`\r\n};\n\n/**\r\n * Dev only\r\n */\r\nconst slotFlagsText = {\r\n [1 /* STABLE */]: 'STABLE',\r\n [2 /* DYNAMIC */]: 'DYNAMIC',\r\n [3 /* FORWARDED */]: 'FORWARDED'\r\n};\n\nconst GLOBALS_WHITE_LISTED = 'Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,' +\r\n 'decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,' +\r\n 'Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt';\r\nconst isGloballyWhitelisted = /*#__PURE__*/ makeMap(GLOBALS_WHITE_LISTED);\n\nconst range = 2;\r\nfunction generateCodeFrame(source, start = 0, end = source.length) {\r\n // Split the content into individual lines but capture the newline sequence\r\n // that separated each line. This is important because the actual sequence is\r\n // needed to properly take into account the full line length for offset\r\n // comparison\r\n let lines = source.split(/(\\r?\\n)/);\r\n // Separate the lines and newline sequences into separate arrays for easier referencing\r\n const newlineSequences = lines.filter((_, idx) => idx % 2 === 1);\r\n lines = lines.filter((_, idx) => idx % 2 === 0);\r\n let count = 0;\r\n const res = [];\r\n for (let i = 0; i < lines.length; i++) {\r\n count +=\r\n lines[i].length +\r\n ((newlineSequences[i] && newlineSequences[i].length) || 0);\r\n if (count >= start) {\r\n for (let j = i - range; j <= i + range || end > count; j++) {\r\n if (j < 0 || j >= lines.length)\r\n continue;\r\n const line = j + 1;\r\n res.push(`${line}${' '.repeat(Math.max(3 - String(line).length, 0))}| ${lines[j]}`);\r\n const lineLength = lines[j].length;\r\n const newLineSeqLength = (newlineSequences[j] && newlineSequences[j].length) || 0;\r\n if (j === i) {\r\n // push underline\r\n const pad = start - (count - (lineLength + newLineSeqLength));\r\n const length = Math.max(1, end > count ? lineLength - pad : end - start);\r\n res.push(` | ` + ' '.repeat(pad) + '^'.repeat(length));\r\n }\r\n else if (j > i) {\r\n if (end > count) {\r\n const length = Math.max(Math.min(end - count, lineLength), 1);\r\n res.push(` | ` + '^'.repeat(length));\r\n }\r\n count += lineLength + newLineSeqLength;\r\n }\r\n }\r\n break;\r\n }\r\n }\r\n return res.join('\\n');\r\n}\n\n/**\r\n * On the client we only need to offer special cases for boolean attributes that\r\n * have different names from their corresponding dom properties:\r\n * - itemscope -> N/A\r\n * - allowfullscreen -> allowFullscreen\r\n * - formnovalidate -> formNoValidate\r\n * - ismap -> isMap\r\n * - nomodule -> noModule\r\n * - novalidate -> noValidate\r\n * - readonly -> readOnly\r\n */\r\nconst specialBooleanAttrs = `itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly`;\r\nconst isSpecialBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs);\r\n/**\r\n * The full list is needed during SSR to produce the correct initial markup.\r\n */\r\nconst isBooleanAttr = /*#__PURE__*/ makeMap(specialBooleanAttrs +\r\n `,async,autofocus,autoplay,controls,default,defer,disabled,hidden,` +\r\n `loop,open,required,reversed,scoped,seamless,` +\r\n `checked,muted,multiple,selected`);\r\n/**\r\n * Boolean attributes should be included if the value is truthy or ''.\r\n * e.g. <select multiple> compiles to { multiple: '' }\r\n */\r\nfunction includeBooleanAttr(value) {\r\n return !!value || value === '';\r\n}\r\nconst unsafeAttrCharRE = /[>/=\"'\\u0009\\u000a\\u000c\\u0020]/;\r\nconst attrValidationCache = {};\r\nfunction isSSRSafeAttrName(name) {\r\n if (attrValidationCache.hasOwnProperty(name)) {\r\n return attrValidationCache[name];\r\n }\r\n const isUnsafe = unsafeAttrCharRE.test(name);\r\n if (isUnsafe) {\r\n console.error(`unsafe attribute name: ${name}`);\r\n }\r\n return (attrValidationCache[name] = !isUnsafe);\r\n}\r\nconst propsToAttrMap = {\r\n acceptCharset: 'accept-charset',\r\n className: 'class',\r\n htmlFor: 'for',\r\n httpEquiv: 'http-equiv'\r\n};\r\n/**\r\n * CSS properties that accept plain numbers\r\n */\r\nconst isNoUnitNumericStyleProp = /*#__PURE__*/ makeMap(`animation-iteration-count,border-image-outset,border-image-slice,` +\r\n `border-image-width,box-flex,box-flex-group,box-ordinal-group,column-count,` +\r\n `columns,flex,flex-grow,flex-positive,flex-shrink,flex-negative,flex-order,` +\r\n `grid-row,grid-row-end,grid-row-span,grid-row-start,grid-column,` +\r\n `grid-column-end,grid-column-span,grid-column-start,font-weight,line-clamp,` +\r\n `line-height,opacity,order,orphans,tab-size,widows,z-index,zoom,` +\r\n // SVG\r\n `fill-opacity,flood-opacity,stop-opacity,stroke-dasharray,stroke-dashoffset,` +\r\n `stroke-miterlimit,stroke-opacity,stroke-width`);\r\n/**\r\n * Known attributes, this is used for stringification of runtime static nodes\r\n * so that we don't stringify bindings that cannot be set from HTML.\r\n * Don't also forget to allow `data-*` and `aria-*`!\r\n * Generated from https://developer.mozilla.org/en-US/docs/Web/HTML/Attributes\r\n */\r\nconst isKnownHtmlAttr = /*#__PURE__*/ makeMap(`accept,accept-charset,accesskey,action,align,allow,alt,async,` +\r\n `autocapitalize,autocomplete,autofocus,autoplay,background,bgcolor,` +\r\n `border,buffered,capture,challenge,charset,checked,cite,class,code,` +\r\n `codebase,color,cols,colspan,content,contenteditable,contextmenu,controls,` +\r\n `coords,crossorigin,csp,data,datetime,decoding,default,defer,dir,dirname,` +\r\n `disabled,download,draggable,dropzone,enctype,enterkeyhint,for,form,` +\r\n `formaction,formenctype,formmethod,formnovalidate,formtarget,headers,` +\r\n `height,hidden,high,href,hreflang,http-equiv,icon,id,importance,integrity,` +\r\n `ismap,itemprop,keytype,kind,label,lang,language,loading,list,loop,low,` +\r\n `manifest,max,maxlength,minlength,media,min,multiple,muted,name,novalidate,` +\r\n `open,optimum,pattern,ping,placeholder,poster,preload,radiogroup,readonly,` +\r\n `referrerpolicy,rel,required,reversed,rows,rowspan,sandbox,scope,scoped,` +\r\n `selected,shape,size,sizes,slot,span,spellcheck,src,srcdoc,srclang,srcset,` +\r\n `start,step,style,summary,tabindex,target,title,translate,type,usemap,` +\r\n `value,width,wrap`);\r\n/**\r\n * Generated from https://developer.mozilla.org/en-US/docs/Web/SVG/Attribute\r\n */\r\nconst isKnownSvgAttr = /*#__PURE__*/ makeMap(`xmlns,accent-height,accumulate,additive,alignment-baseline,alphabetic,amplitude,` +\r\n `arabic-form,ascent,attributeName,attributeType,azimuth,baseFrequency,` +\r\n `baseline-shift,baseProfile,bbox,begin,bias,by,calcMode,cap-height,class,` +\r\n `clip,clipPathUnits,clip-path,clip-rule,color,color-interpolation,` +\r\n `color-interpolation-filters,color-profile,color-rendering,` +\r\n `contentScriptType,contentStyleType,crossorigin,cursor,cx,cy,d,decelerate,` +\r\n `descent,diffuseConstant,direction,display,divisor,dominant-baseline,dur,dx,` +\r\n `dy,edgeMode,elevation,enable-background,end,exponent,fill,fill-opacity,` +\r\n `fill-rule,filter,filterRes,filterUnits,flood-color,flood-opacity,` +\r\n `font-family,font-size,font-size-adjust,font-stretch,font-style,` +\r\n `font-variant,font-weight,format,from,fr,fx,fy,g1,g2,glyph-name,` +\r\n `glyph-orientation-horizontal,glyph-orientation-vertical,glyphRef,` +\r\n `gradientTransform,gradientUnits,hanging,height,href,hreflang,horiz-adv-x,` +\r\n `horiz-origin-x,id,ideographic,image-rendering,in,in2,intercept,k,k1,k2,k3,` +\r\n `k4,kernelMatrix,kernelUnitLength,kerning,keyPoints,keySplines,keyTimes,` +\r\n `lang,lengthAdjust,letter-spacing,lighting-color,limitingConeAngle,local,` +\r\n `marker-end,marker-mid,marker-start,markerHeight,markerUnits,markerWidth,` +\r\n `mask,maskContentUnits,maskUnits,mathematical,max,media,method,min,mode,` +\r\n `name,numOctaves,offset,opacity,operator,order,orient,orientation,origin,` +\r\n `overflow,overline-position,overline-thickness,panose-1,paint-order,path,` +\r\n `pathLength,patternContentUnits,patternTransform,patternUnits,ping,` +\r\n `pointer-events,points,pointsAtX,pointsAtY,pointsAtZ,preserveAlpha,` +\r\n `preserveAspectRatio,primitiveUnits,r,radius,referrerPolicy,refX,refY,rel,` +\r\n `rendering-intent,repeatCount,repeatDur,requiredExtensions,requiredFeatures,` +\r\n `restart,result,rotate,rx,ry,scale,seed,shape-rendering,slope,spacing,` +\r\n `specularConstant,specularExponent,speed,spreadMethod,startOffset,` +\r\n `stdDeviation,stemh,stemv,stitchTiles,stop-color,stop-opacity,` +\r\n `strikethrough-position,strikethrough-thickness,string,stroke,` +\r\n `stroke-dasharray,stroke-dashoffset,stroke-linecap,stroke-linejoin,` +\r\n `stroke-miterlimit,stroke-opacity,stroke-width,style,surfaceScale,` +\r\n `systemLanguage,tabindex,tableValues,target,targetX,targetY,text-anchor,` +\r\n `text-decoration,text-rendering,textLength,to,transform,transform-origin,` +\r\n `type,u1,u2,underline-position,underline-thickness,unicode,unicode-bidi,` +\r\n `unicode-range,units-per-em,v-alphabetic,v-hanging,v-ideographic,` +\r\n `v-mathematical,values,vector-effect,version,vert-adv-y,vert-origin-x,` +\r\n `vert-origin-y,viewBox,viewTarget,visibility,width,widths,word-spacing,` +\r\n `writing-mode,x,x-height,x1,x2,xChannelSelector,xlink:actuate,xlink:arcrole,` +\r\n `xlink:href,xlink:role,xlink:show,xlink:title,xlink:type,xml:base,xml:lang,` +\r\n `xml:space,y,y1,y2,yChannelSelector,z,zoomAndPan`);\n\nfunction normalizeStyle(value) {\r\n if (isArray(value)) {\r\n const res = {};\r\n for (let i = 0; i < value.length; i++) {\r\n const item = value[i];\r\n const normalized = isString(item)\r\n ? parseStringStyle(item)\r\n : normalizeStyle(item);\r\n if (normalized) {\r\n for (const key in normalized) {\r\n res[key] = normalized[key];\r\n }\r\n }\r\n }\r\n return res;\r\n }\r\n else if (isString(value)) {\r\n return value;\r\n }\r\n else if (isObject(value)) {\r\n return value;\r\n }\r\n}\r\nconst listDelimiterRE = /;(?![^(]*\\))/g;\r\nconst propertyDelimiterRE = /:(.+)/;\r\nfunction parseStringStyle(cssText) {\r\n const ret = {};\r\n cssText.split(listDelimiterRE).forEach(item => {\r\n if (item) {\r\n const tmp = item.split(propertyDelimiterRE);\r\n tmp.length > 1 && (ret[tmp[0].trim()] = tmp[1].trim());\r\n }\r\n });\r\n return ret;\r\n}\r\nfunction stringifyStyle(styles) {\r\n let ret = '';\r\n if (!styles || isString(styles)) {\r\n return ret;\r\n }\r\n for (const key in styles) {\r\n const value = styles[key];\r\n const normalizedKey = key.startsWith(`--`) ? key : hyphenate(key);\r\n if (isString(value) ||\r\n (typeof value === 'number' && isNoUnitNumericStyleProp(normalizedKey))) {\r\n // only render valid values\r\n ret += `${normalizedKey}:${value};`;\r\n }\r\n }\r\n return ret;\r\n}\r\nfunction normalizeClass(value) {\r\n let res = '';\r\n if (isString(value)) {\r\n res = value;\r\n }\r\n else if (isArray(value)) {\r\n for (let i = 0; i < value.length; i++) {\r\n const normalized = normalizeClass(value[i]);\r\n if (normalized) {\r\n res += normalized + ' ';\r\n }\r\n }\r\n }\r\n else if (isObject(value)) {\r\n for (const name in value) {\r\n if (value[name]) {\r\n res += name + ' ';\r\n }\r\n }\r\n }\r\n return res.trim();\r\n}\r\nfunction normalizeProps(props) {\r\n if (!props)\r\n return null;\r\n let { class: klass, style } = props;\r\n if (klass && !isString(klass)) {\r\n props.class = normalizeClass(klass);\r\n }\r\n if (style) {\r\n props.style = normalizeStyle(style);\r\n }\r\n return props;\r\n}\n\n// These tag configs are shared between compiler-dom and runtime-dom, so they\r\n// https://developer.mozilla.org/en-US/docs/Web/HTML/Element\r\nconst HTML_TAGS = 'html,body,base,head,link,meta,style,title,address,article,aside,footer,' +\r\n 'header,h1,h2,h3,h4,h5,h6,nav,section,div,dd,dl,dt,figcaption,' +\r\n 'figure,picture,hr,img,li,main,ol,p,pre,ul,a,b,abbr,bdi,bdo,br,cite,code,' +\r\n 'data,dfn,em,i,kbd,mark,q,rp,rt,ruby,s,samp,small,span,strong,sub,sup,' +\r\n 'time,u,var,wbr,area,audio,map,track,video,embed,object,param,source,' +\r\n 'canvas,script,noscript,del,ins,caption,col,colgroup,table,thead,tbody,td,' +\r\n 'th,tr,button,datalist,fieldset,form,input,label,legend,meter,optgroup,' +\r\n 'option,output,progress,select,textarea,details,dialog,menu,' +\r\n 'summary,template,blockquote,iframe,tfoot';\r\n// https://developer.mozilla.org/en-US/docs/Web/SVG/Element\r\nconst SVG_TAGS = 'svg,animate,animateMotion,animateTransform,circle,clipPath,color-profile,' +\r\n 'defs,desc,discard,ellipse,feBlend,feColorMatrix,feComponentTransfer,' +\r\n 'feComposite,feConvolveMatrix,feDiffuseLighting,feDisplacementMap,' +\r\n 'feDistanceLight,feDropShadow,feFlood,feFuncA,feFuncB,feFuncG,feFuncR,' +\r\n 'feGaussianBlur,feImage,feMerge,feMergeNode,feMorphology,feOffset,' +\r\n 'fePointLight,feSpecularLighting,feSpotLight,feTile,feTurbulence,filter,' +\r\n 'foreignObject,g,hatch,hatchpath,image,line,linearGradient,marker,mask,' +\r\n 'mesh,meshgradient,meshpatch,meshrow,metadata,mpath,path,pattern,' +\r\n 'polygon,polyline,radialGradient,rect,set,solidcolor,stop,switch,symbol,' +\r\n 'text,textPath,title,tspan,unknown,use,view';\r\nconst VOID_TAGS = 'area,base,br,col,embed,hr,img,input,link,meta,param,source,track,wbr';\r\nconst isHTMLTag = /*#__PURE__*/ makeMap(HTML_TAGS);\r\nconst isSVGTag = /*#__PURE__*/ makeMap(SVG_TAGS);\r\nconst isVoidTag = /*#__PURE__*/ makeMap(VOID_TAGS);\n\nconst escapeRE = /[\"'&<>]/;\r\nfunction escapeHtml(string) {\r\n const str = '' + string;\r\n const match = escapeRE.exec(str);\r\n if (!match) {\r\n return str;\r\n }\r\n let html = '';\r\n let escaped;\r\n let index;\r\n let lastIndex = 0;\r\n for (index = match.index; index < str.length; index++) {\r\n switch (str.charCodeAt(index)) {\r\n case 34: // \"\r\n escaped = '&quot;';\r\n break;\r\n case 38: // &\r\n escaped = '&amp;';\r\n break;\r\n case 39: // '\r\n escaped = '&#39;';\r\n break;\r\n case 60: // <\r\n escaped = '&lt;';\r\n break;\r\n case 62: // >\r\n escaped = '&gt;';\r\n break;\r\n default:\r\n continue;\r\n }\r\n if (lastIndex !== index) {\r\n html += str.slice(lastIndex, index);\r\n }\r\n lastIndex = index + 1;\r\n html += escaped;\r\n }\r\n return lastIndex !== index ? html + str.slice(lastIndex, index) : html;\r\n}\r\n// https://www.w3.org/TR/html52/syntax.html#comments\r\nconst commentStripRE = /^-?>|<!--|-->|--!>|<!-$/g;\r\nfunction escapeHtmlComment(src) {\r\n return src.replace(commentStripRE, '');\r\n}\n\nfunction looseCompareArrays(a, b) {\r\n if (a.length !== b.length)\r\n return false;\r\n let equal = true;\r\n for (let i = 0; equal && i < a.length; i++) {\r\n equal = looseEqual(a[i], b[i]);\r\n }\r\n return equal;\r\n}\r\nfunction looseEqual(a, b) {\r\n if (a === b)\r\n return true;\r\n let aValidType = isDate(a);\r\n let bValidType = isDate(b);\r\n if (aValidType || bValidType) {\r\n return aValidType && bValidType ? a.getTime() === b.getTime() : false;\r\n }\r\n aValidType = isArray(a);\r\n bValidType = isArray(b);\r\n if (aValidType || bValidType) {\r\n return aValidType && bValidType ? looseCompareArrays(a, b) : false;\r\n }\r\n aValidType = isObject(a);\r\n bValidType = isObject(b);\r\n if (aValidType || bValidType) {\r\n /* istanbul ignore if: this if will probably never be called */\r\n if (!aValidType || !bValidType) {\r\n return false;\r\n }\r\n const aKeysCount = Object.keys(a).length;\r\n const bKeysCount = Object.keys(b).length;\r\n if (aKeysCount !== bKeysCount) {\r\n return false;\r\n }\r\n for (const key in a) {\r\n const aHasKey = a.hasOwnProperty(key);\r\n const bHasKey = b.hasOwnProperty(key);\r\n if ((aHasKey && !bHasKey) ||\r\n (!aHasKey && bHasKey) ||\r\n !looseEqual(a[key], b[key])) {\r\n return false;\r\n }\r\n }\r\n }\r\n return String(a) === String(b);\r\n}\r\nfunction looseIndexOf(arr, val) {\r\n return arr.findIndex(item => looseEqual(item, val));\r\n}\n\n/**\r\n * For converting {{ interpolation }} values to displayed strings.\r\n * @private\r\n */\r\nconst toDisplayString = (val) => {\r\n return val == null\r\n ? ''\r\n : isArray(val) ||\r\n (isObject(val) &&\r\n (val.toString === objectToString || !isFunction(val.toString)))\r\n ? JSON.stringify(val, replacer, 2)\r\n : String(val);\r\n};\r\nconst replacer = (_key, val) => {\r\n // can't use isRef here since @vue/shared has no deps\r\n if (val && val.__v_isRef) {\r\n return replacer(_key, val.value);\r\n }\r\n else if (isMap(val)) {\r\n return {\r\n [`Map(${val.size})`]: [...val.entries()].reduce((entries, [key, val]) => {\r\n entries[`${key} =>`] = val;\r\n return entries;\r\n }, {})\r\n };\r\n }\r\n else if (isSet(val)) {\r\n return {\r\n [`Set(${val.size})`]: [...val.values()]\r\n };\r\n }\r\n else if (isObject(val) && !isArray(val) && !isPlainObject(val)) {\r\n return String(val);\r\n }\r\n return val;\r\n};\n\nconst EMPTY_OBJ = (process.env.NODE_ENV !== 'production')\r\n ? Object.freeze({})\r\n : {};\r\nconst EMPTY_ARR = (process.env.NODE_ENV !== 'production') ? Object.freeze([]) : [];\r\nconst NOOP = () => { };\r\n/**\r\n * Always return false.\r\n */\r\nconst NO = () => false;\r\nconst onRE = /^on[^a-z]/;\r\nconst isOn = (key) => onRE.test(key);\r\nconst isModelListener = (key) => key.startsWith('onUpdate:');\r\nconst extend = Object.assign;\r\nconst remove = (arr, el) => {\r\n const i = arr.indexOf(el);\r\n if (i > -1) {\r\n arr.splice(i, 1);\r\n }\r\n};\r\nconst hasOwnProperty = Object.prototype.hasOwnProperty;\r\nconst hasOwn = (val, key) => hasOwnProperty.call(val, key);\r\nconst isArray = Array.isArray;\r\nconst isMap = (val) => toTypeString(val) === '[object Map]';\r\nconst isSet = (val) => toTypeString(val) === '[object Set]';\r\nconst isDate = (val) => val instanceof Date;\r\nconst isFunction = (val) => typeof val === 'function';\r\nconst isString = (val) => typeof val === 'string';\r\nconst isSymbol = (val) => typeof val === 'symbol';\r\nconst isObject = (val) => val !== null && typeof val === 'object';\r\nconst isPromise = (val) => {\r\n return isObject(val) && isFunction(val.then) && isFunction(val.catch);\r\n};\r\nconst objectToString = Object.prototype.toString;\r\nconst toTypeString = (value) => objectToString.call(value);\r\nconst toRawType = (value) => {\r\n // extract \"RawType\" from strings like \"[object RawType]\"\r\n return toTypeString(value).slice(8, -1);\r\n};\r\nconst isPlainObject = (val) => toTypeString(val) === '[object Object]';\r\nconst isIntegerKey = (key) => isString(key) &&\r\n key !== 'NaN' &&\r\n key[0] !== '-' &&\r\n '' + parseInt(key, 10) === key;\r\nconst isReservedProp = /*#__PURE__*/ makeMap(\r\n// the leading comma is intentional so empty string \"\" is also included\r\n',key,ref,' +\r\n 'onVnodeBeforeMount,onVnodeMounted,' +\r\n 'onVnodeBeforeUpdate,onVnodeUpdated,' +\r\n 'onVnodeBeforeUnmount,onVnodeUnmounted');\r\nconst cacheStringFunction = (fn) => {\r\n const cache = Object.create(null);\r\n return ((str) => {\r\n const hit = cache[str];\r\n return hit || (cache[str] = fn(str));\r\n });\r\n};\r\nconst camelizeRE = /-(\\w)/g;\r\n/**\r\n * @private\r\n */\r\nconst camelize = cacheStringFunction((str) => {\r\n return str.replace(camelizeRE, (_, c) => (c ? c.toUpperCase() : ''));\r\n});\r\nconst hyphenateRE = /\\B([A-Z])/g;\r\n/**\r\n * @private\r\n */\r\nconst hyphenate = cacheStringFunction((str) => str.replace(hyphenateRE, '-$1').toLowerCase());\r\n/**\r\n * @private\r\n */\r\nconst capitalize = cacheStringFunction((str) => str.charAt(0).toUpperCase() + str.slice(1));\r\n/**\r\n * @private\r\n */\r\nconst toHandlerKey = cacheStringFunction((str) => str ? `on${capitalize(str)}` : ``);\r\n// compare whether a value has changed, accounting for NaN.\r\nconst hasChanged = (value, oldValue) => !Object.is(value, oldValue);\r\nconst invokeArrayFns = (fns, arg) => {\r\n for (let i = 0; i < fns.length; i++) {\r\n fns[i](arg);\r\n }\r\n};\r\nconst def = (obj, key, value) => {\r\n Object.defineProperty(obj, key, {\r\n configurable: true,\r\n enumerable: false,\r\n value\r\n });\r\n};\r\nconst toNumber = (val) => {\r\n const n = parseFloat(val);\r\n return isNaN(n) ? val : n;\r\n};\r\nlet _globalThis;\r\nconst getGlobalThis = () => {\r\n return (_globalThis ||\r\n (_globalThis =\r\n typeof globalThis !== 'undefined'\r\n ? globalThis\r\n : typeof self !== 'undefined'\r\n ? self\r\n : typeof window !== 'undefined'\r\n ? window\r\n : typeof global !== 'undefined'\r\n ? global\r\n : {}));\r\n};\n\nexport { EMPTY_ARR, EMPTY_OBJ, NO, NOOP, PatchFlagNames, camelize, capitalize, def, escapeHtml, escapeHtmlComment, extend, generateCodeFrame, getGlobalThis, hasChanged, hasOwn, hyphenate, includeBooleanAttr, invokeArrayFns, isArray, isBooleanAttr, isDate, isFunction, isGloballyWhitelisted, isHTMLTag, isIntegerKey, isKnownHtmlAttr, isKnownSvgAttr, isMap, isModelListener, isNoUnitNumericStyleProp, isObject, isOn, isPlainObject, isPromise, isReservedProp, isSSRSafeAttrName, isSVGTag, isSet, isSpecialBooleanAttr, isString, isSymbol, isVoidTag, looseEqual, looseIndexOf, makeMap, normalizeClass, normalizeProps, normalizeStyle, objectToString, parseStringStyle, propsToAttrMap, remove, slotFlagsText, stringifyStyle, toDisplayString, toHandlerKey, toNumber, toRawType, toTypeString };\n","import { createVNode as _createVNode } from \"vue\";\nimport { computed, defineComponent } from 'vue';\nimport { numericProp, createNamespace, makeNumericProp, makeStringProp } from '../utils';\nimport { useParent } from '@vant/use';\nimport { ROW_KEY } from '../row/Row';\nvar [name, bem] = createNamespace('col');\nvar colProps = {\n tag: makeStringProp('div'),\n span: makeNumericProp(0),\n offset: numericProp\n};\nexport default defineComponent({\n name,\n props: colProps,\n\n setup(props, _ref) {\n var {\n slots\n } = _ref;\n var {\n parent,\n index\n } = useParent(ROW_KEY);\n var style = computed(() => {\n if (!parent) {\n return;\n }\n\n var {\n spaces\n } = parent;\n\n if (spaces && spaces.value && spaces.value[index.value]) {\n var {\n left,\n right\n } = spaces.value[index.value];\n return {\n paddingLeft: left ? left + \"px\" : null,\n paddingRight: right ? right + \"px\" : null\n };\n }\n });\n return () => {\n var {\n tag,\n span,\n offset\n } = props;\n return _createVNode(tag, {\n \"style\": style.value,\n \"class\": bem({\n [span]: span,\n [\"offset-\" + offset]: offset\n })\n }, {\n default: () => [slots.default == null ? void 0 : slots.default()]\n });\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _Col from './Col';\nexport var Col = withInstall(_Col);\nexport default Col;","var toPrimitive = require('../internals/to-primitive');\nvar isSymbol = require('../internals/is-symbol');\n\n// `ToPropertyKey` abstract operation\n// https://tc39.es/ecma262/#sec-topropertykey\nmodule.exports = function (argument) {\n var key = toPrimitive(argument, 'string');\n return isSymbol(key) ? key : key + '';\n};\n","import '../../style/base.css';\nimport '../index.css';","var userAgent = require('../internals/engine-user-agent');\n\nmodule.exports = /web0s(?!.*chrome)/i.test(userAgent);\n","'use strict';\nvar $ = require('../internals/export');\nvar IS_PURE = require('../internals/is-pure');\nvar NativePromise = require('../internals/native-promise-constructor');\nvar fails = require('../internals/fails');\nvar getBuiltIn = require('../internals/get-built-in');\nvar isCallable = require('../internals/is-callable');\nvar speciesConstructor = require('../internals/species-constructor');\nvar promiseResolve = require('../internals/promise-resolve');\nvar redefine = require('../internals/redefine');\n\n// Safari bug https://bugs.webkit.org/show_bug.cgi?id=200829\nvar NON_GENERIC = !!NativePromise && fails(function () {\n NativePromise.prototype['finally'].call({ then: function () { /* empty */ } }, function () { /* empty */ });\n});\n\n// `Promise.prototype.finally` method\n// https://tc39.es/ecma262/#sec-promise.prototype.finally\n$({ target: 'Promise', proto: true, real: true, forced: NON_GENERIC }, {\n 'finally': function (onFinally) {\n var C = speciesConstructor(this, getBuiltIn('Promise'));\n var isFunction = isCallable(onFinally);\n return this.then(\n isFunction ? function (x) {\n return promiseResolve(C, onFinally()).then(function () { return x; });\n } : onFinally,\n isFunction ? function (e) {\n return promiseResolve(C, onFinally()).then(function () { throw e; });\n } : onFinally\n );\n }\n});\n\n// makes sure that native promise-based APIs `Promise#finally` properly works with patched `Promise#then`\nif (!IS_PURE && isCallable(NativePromise)) {\n var method = getBuiltIn('Promise').prototype['finally'];\n if (NativePromise.prototype['finally'] !== method) {\n redefine(NativePromise.prototype, 'finally', method, { unsafe: true });\n }\n}\n","import '../../style/base.css';\nimport '../index.css';","import '../../style/base.css';\nimport '../../loading/index.css';\nimport '../index.css';","export function getDevtoolsGlobalHook() {\n return getTarget().__VUE_DEVTOOLS_GLOBAL_HOOK__;\n}\nexport function getTarget() {\n // @ts-ignore\n return (typeof navigator !== 'undefined' && typeof window !== 'undefined')\n ? window\n : typeof global !== 'undefined'\n ? global\n : {};\n}\nexport const isProxyAvailable = typeof Proxy === 'function';\n","'use strict';\nvar $ = require('../internals/export');\nvar exec = require('../internals/regexp-exec');\n\n// `RegExp.prototype.exec` method\n// https://tc39.es/ecma262/#sec-regexp.prototype.exec\n$({ target: 'RegExp', proto: true, forced: /./.exec !== exec }, {\n exec: exec\n});\n","import { createVNode as _createVNode } from \"vue\";\nimport { computed, defineComponent } from 'vue';\nimport { isDef, addUnit, isNumeric, truthProp, numericProp, makeStringProp, createNamespace } from '../utils';\nvar [name, bem] = createNamespace('badge');\nvar badgeProps = {\n dot: Boolean,\n max: numericProp,\n tag: makeStringProp('div'),\n color: String,\n offset: Array,\n content: numericProp,\n showZero: truthProp\n};\nexport default defineComponent({\n name,\n props: badgeProps,\n\n setup(props, _ref) {\n var {\n slots\n } = _ref;\n\n var hasContent = () => {\n if (slots.content) {\n return true;\n }\n\n var {\n content,\n showZero\n } = props;\n return isDef(content) && content !== '' && (showZero || content !== 0);\n };\n\n var renderContent = () => {\n var {\n dot,\n max,\n content\n } = props;\n\n if (!dot && hasContent()) {\n if (slots.content) {\n return slots.content();\n }\n\n if (isDef(max) && isNumeric(content) && +content > max) {\n return max + \"+\";\n }\n\n return content;\n }\n };\n\n var style = computed(() => {\n var style = {\n background: props.color\n };\n\n if (props.offset) {\n var [x, y] = props.offset;\n\n if (slots.default) {\n style.top = addUnit(y);\n\n if (typeof x === 'number') {\n style.right = addUnit(-x);\n } else {\n style.right = x.startsWith('-') ? x.replace('-', '') : \"-\" + x;\n }\n } else {\n style.marginTop = addUnit(y);\n style.marginLeft = addUnit(x);\n }\n }\n\n return style;\n });\n\n var renderBadge = () => {\n if (hasContent() || props.dot) {\n return _createVNode(\"div\", {\n \"class\": bem({\n dot: props.dot,\n fixed: !!slots.default\n }),\n \"style\": style.value\n }, [renderContent()]);\n }\n };\n\n return () => {\n if (slots.default) {\n var {\n tag\n } = props;\n return _createVNode(tag, {\n \"class\": bem('wrapper')\n }, {\n default: () => [slots.default(), renderBadge()]\n });\n }\n\n return renderBadge();\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _Badge from './Badge';\nexport var Badge = withInstall(_Badge);\nexport default Badge;","import { createVNode as _createVNode } from \"vue\";\nimport { defineComponent, inject, computed } from 'vue';\nimport { addUnit, numericProp, makeStringProp, createNamespace } from '../utils';\nimport { Badge } from '../badge';\nimport { CONFIG_PROVIDER_KEY } from '../config-provider/ConfigProvider';\nvar [name, bem] = createNamespace('icon');\n\nvar isImage = name => name == null ? void 0 : name.includes('/');\n\nvar iconProps = {\n dot: Boolean,\n tag: makeStringProp('i'),\n name: String,\n size: numericProp,\n badge: numericProp,\n color: String,\n classPrefix: String\n};\nexport default defineComponent({\n name,\n props: iconProps,\n\n setup(props, _ref) {\n var {\n slots\n } = _ref;\n var config = inject(CONFIG_PROVIDER_KEY, null);\n var classPrefix = computed(() => props.classPrefix || (config == null ? void 0 : config.iconPrefix) || bem());\n return () => {\n var {\n tag,\n dot,\n name,\n size,\n badge,\n color\n } = props;\n var isImageIcon = isImage(name);\n return _createVNode(Badge, {\n \"dot\": dot,\n \"tag\": tag,\n \"content\": badge,\n \"class\": [classPrefix.value, isImageIcon ? '' : classPrefix.value + \"-\" + name],\n \"style\": {\n color,\n fontSize: addUnit(size)\n }\n }, {\n default: () => [slots.default == null ? void 0 : slots.default(), isImageIcon && _createVNode(\"img\", {\n \"class\": bem('image'),\n \"src\": name\n }, null)]\n });\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _Icon from './Icon';\nexport var Icon = withInstall(_Icon);\nexport default Icon;","'use strict';\nvar anObject = require('../internals/an-object');\n\n// `RegExp.prototype.flags` getter implementation\n// https://tc39.es/ecma262/#sec-get-regexp.prototype.flags\nmodule.exports = function () {\n var that = anObject(this);\n var result = '';\n if (that.global) result += 'g';\n if (that.ignoreCase) result += 'i';\n if (that.multiline) result += 'm';\n if (that.dotAll) result += 's';\n if (that.unicode) result += 'u';\n if (that.sticky) result += 'y';\n return result;\n};\n","'use strict';\nvar fails = require('../internals/fails');\nvar isCallable = require('../internals/is-callable');\nvar create = require('../internals/object-create');\nvar getPrototypeOf = require('../internals/object-get-prototype-of');\nvar redefine = require('../internals/redefine');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar IS_PURE = require('../internals/is-pure');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar BUGGY_SAFARI_ITERATORS = false;\n\n// `%IteratorPrototype%` object\n// https://tc39.es/ecma262/#sec-%iteratorprototype%-object\nvar IteratorPrototype, PrototypeOfArrayIteratorPrototype, arrayIterator;\n\n/* eslint-disable es/no-array-prototype-keys -- safe */\nif ([].keys) {\n arrayIterator = [].keys();\n // Safari 8 has buggy iterators w/o `next`\n if (!('next' in arrayIterator)) BUGGY_SAFARI_ITERATORS = true;\n else {\n PrototypeOfArrayIteratorPrototype = getPrototypeOf(getPrototypeOf(arrayIterator));\n if (PrototypeOfArrayIteratorPrototype !== Object.prototype) IteratorPrototype = PrototypeOfArrayIteratorPrototype;\n }\n}\n\nvar NEW_ITERATOR_PROTOTYPE = IteratorPrototype == undefined || fails(function () {\n var test = {};\n // FF44- legacy iterators case\n return IteratorPrototype[ITERATOR].call(test) !== test;\n});\n\nif (NEW_ITERATOR_PROTOTYPE) IteratorPrototype = {};\nelse if (IS_PURE) IteratorPrototype = create(IteratorPrototype);\n\n// `%IteratorPrototype%[@@iterator]()` method\n// https://tc39.es/ecma262/#sec-%iteratorprototype%-@@iterator\nif (!isCallable(IteratorPrototype[ITERATOR])) {\n redefine(IteratorPrototype, ITERATOR, function () {\n return this;\n });\n}\n\nmodule.exports = {\n IteratorPrototype: IteratorPrototype,\n BUGGY_SAFARI_ITERATORS: BUGGY_SAFARI_ITERATORS\n};\n","import '../../style/base.css';\nimport '../../loading/index.css';\nimport '../index.css';","'use strict';\nvar TO_STRING_TAG_SUPPORT = require('../internals/to-string-tag-support');\nvar classof = require('../internals/classof');\n\n// `Object.prototype.toString` method implementation\n// https://tc39.es/ecma262/#sec-object.prototype.tostring\nmodule.exports = TO_STRING_TAG_SUPPORT ? {}.toString : function toString() {\n return '[object ' + classof(this) + ']';\n};\n","/**\n * Vue Router support\n */\nimport { getCurrentInstance } from 'vue';\nexport var routeProps = {\n to: [String, Object],\n url: String,\n replace: Boolean\n};\nexport function route(_ref) {\n var {\n to,\n url,\n replace,\n $router: router\n } = _ref;\n\n if (to && router) {\n router[replace ? 'replace' : 'push'](to);\n } else if (url) {\n replace ? location.replace(url) : location.href = url;\n }\n}\nexport function useRoute() {\n var vm = getCurrentInstance().proxy;\n return () => route(vm);\n}","export var BORDER = 'van-hairline';\nexport var BORDER_TOP = BORDER + \"--top\";\nexport var BORDER_LEFT = BORDER + \"--left\";\nexport var BORDER_BOTTOM = BORDER + \"--bottom\";\nexport var BORDER_SURROUND = BORDER + \"--surround\";\nexport var BORDER_TOP_BOTTOM = BORDER + \"--top-bottom\";\nexport var BORDER_UNSET_TOP_BOTTOM = BORDER + \"-unset--top-bottom\";\nexport var HAPTICS_FEEDBACK = 'van-haptics-feedback';\nexport var FORM_KEY = Symbol('van-form');","var global = require('../internals/global');\nvar bind = require('../internals/function-bind-context');\nvar getOwnPropertyDescriptor = require('../internals/object-get-own-property-descriptor').f;\nvar macrotask = require('../internals/task').set;\nvar IS_IOS = require('../internals/engine-is-ios');\nvar IS_IOS_PEBBLE = require('../internals/engine-is-ios-pebble');\nvar IS_WEBOS_WEBKIT = require('../internals/engine-is-webos-webkit');\nvar IS_NODE = require('../internals/engine-is-node');\n\nvar MutationObserver = global.MutationObserver || global.WebKitMutationObserver;\nvar document = global.document;\nvar process = global.process;\nvar Promise = global.Promise;\n// Node.js 11 shows ExperimentalWarning on getting `queueMicrotask`\nvar queueMicrotaskDescriptor = getOwnPropertyDescriptor(global, 'queueMicrotask');\nvar queueMicrotask = queueMicrotaskDescriptor && queueMicrotaskDescriptor.value;\n\nvar flush, head, last, notify, toggle, node, promise, then;\n\n// modern engines have queueMicrotask method\nif (!queueMicrotask) {\n flush = function () {\n var parent, fn;\n if (IS_NODE && (parent = process.domain)) parent.exit();\n while (head) {\n fn = head.fn;\n head = head.next;\n try {\n fn();\n } catch (error) {\n if (head) notify();\n else last = undefined;\n throw error;\n }\n } last = undefined;\n if (parent) parent.enter();\n };\n\n // browsers with MutationObserver, except iOS - https://github.com/zloirock/core-js/issues/339\n // also except WebOS Webkit https://github.com/zloirock/core-js/issues/898\n if (!IS_IOS && !IS_NODE && !IS_WEBOS_WEBKIT && MutationObserver && document) {\n toggle = true;\n node = document.createTextNode('');\n new MutationObserver(flush).observe(node, { characterData: true });\n notify = function () {\n node.data = toggle = !toggle;\n };\n // environments with maybe non-completely correct, but existent Promise\n } else if (!IS_IOS_PEBBLE && Promise && Promise.resolve) {\n // Promise.resolve without an argument throws an error in LG WebOS 2\n promise = Promise.resolve(undefined);\n // workaround of WebKit ~ iOS Safari 10.1 bug\n promise.constructor = Promise;\n then = bind(promise.then, promise);\n notify = function () {\n then(flush);\n };\n // Node.js without promises\n } else if (IS_NODE) {\n notify = function () {\n process.nextTick(flush);\n };\n // for other environments - macrotask based on:\n // - setImmediate\n // - MessageChannel\n // - window.postMessag\n // - onreadystatechange\n // - setTimeout\n } else {\n // strange IE + webpack dev server bug - use .bind(global)\n macrotask = bind(macrotask, global);\n notify = function () {\n macrotask(flush);\n };\n }\n}\n\nmodule.exports = queueMicrotask || function (fn) {\n var task = { fn: fn, next: undefined };\n if (last) last.next = task;\n if (!head) {\n head = task;\n notify();\n } last = task;\n};\n","var global = require('../internals/global');\nvar shared = require('../internals/shared');\nvar hasOwn = require('../internals/has-own-property');\nvar uid = require('../internals/uid');\nvar NATIVE_SYMBOL = require('../internals/native-symbol');\nvar USE_SYMBOL_AS_UID = require('../internals/use-symbol-as-uid');\n\nvar WellKnownSymbolsStore = shared('wks');\nvar Symbol = global.Symbol;\nvar symbolFor = Symbol && Symbol['for'];\nvar createWellKnownSymbol = USE_SYMBOL_AS_UID ? Symbol : Symbol && Symbol.withoutSetter || uid;\n\nmodule.exports = function (name) {\n if (!hasOwn(WellKnownSymbolsStore, name) || !(NATIVE_SYMBOL || typeof WellKnownSymbolsStore[name] == 'string')) {\n var description = 'Symbol.' + name;\n if (NATIVE_SYMBOL && hasOwn(Symbol, name)) {\n WellKnownSymbolsStore[name] = Symbol[name];\n } else if (USE_SYMBOL_AS_UID && symbolFor) {\n WellKnownSymbolsStore[name] = symbolFor(description);\n } else {\n WellKnownSymbolsStore[name] = createWellKnownSymbol(description);\n }\n } return WellKnownSymbolsStore[name];\n};\n","import { createVNode as _createVNode } from \"vue\";\nimport { defineComponent } from 'vue'; // Utils\n\nimport { extend, numericProp, preventDefault, makeStringProp, createNamespace, BORDER_SURROUND } from '../utils';\nimport { useRoute, routeProps } from '../composables/use-route'; // Components\n\nimport { Icon } from '../icon';\nimport { Loading } from '../loading'; // Types\n\nvar [name, bem] = createNamespace('button');\nvar buttonProps = extend({}, routeProps, {\n tag: makeStringProp('button'),\n text: String,\n icon: String,\n type: makeStringProp('default'),\n size: makeStringProp('normal'),\n color: String,\n block: Boolean,\n plain: Boolean,\n round: Boolean,\n square: Boolean,\n loading: Boolean,\n hairline: Boolean,\n disabled: Boolean,\n iconPrefix: String,\n nativeType: makeStringProp('button'),\n loadingSize: numericProp,\n loadingText: String,\n loadingType: String,\n iconPosition: makeStringProp('left')\n});\nexport default defineComponent({\n name,\n props: buttonProps,\n emits: ['click'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var route = useRoute();\n\n var renderLoadingIcon = () => {\n if (slots.loading) {\n return slots.loading();\n }\n\n return _createVNode(Loading, {\n \"size\": props.loadingSize,\n \"type\": props.loadingType,\n \"class\": bem('loading')\n }, null);\n };\n\n var renderIcon = () => {\n if (props.loading) {\n return renderLoadingIcon();\n }\n\n if (slots.icon) {\n return _createVNode(\"div\", {\n \"class\": bem('icon')\n }, [slots.icon()]);\n }\n\n if (props.icon) {\n return _createVNode(Icon, {\n \"name\": props.icon,\n \"class\": bem('icon'),\n \"classPrefix\": props.iconPrefix\n }, null);\n }\n };\n\n var renderText = () => {\n var text;\n\n if (props.loading) {\n text = props.loadingText;\n } else {\n text = slots.default ? slots.default() : props.text;\n }\n\n if (text) {\n return _createVNode(\"span\", {\n \"class\": bem('text')\n }, [text]);\n }\n };\n\n var getStyle = () => {\n var {\n color,\n plain\n } = props;\n\n if (color) {\n var style = {\n color: plain ? color : 'white'\n };\n\n if (!plain) {\n // Use background instead of backgroundColor to make linear-gradient work\n style.background = color;\n } // hide border when color is linear-gradient\n\n\n if (color.includes('gradient')) {\n style.border = 0;\n } else {\n style.borderColor = color;\n }\n\n return style;\n }\n };\n\n var onClick = event => {\n if (props.loading) {\n preventDefault(event);\n } else if (!props.disabled) {\n emit('click', event);\n route();\n }\n };\n\n return () => {\n var {\n tag,\n type,\n size,\n block,\n round,\n plain,\n square,\n loading,\n disabled,\n hairline,\n nativeType,\n iconPosition\n } = props;\n var classes = [bem([type, size, {\n plain,\n block,\n round,\n square,\n loading,\n disabled,\n hairline\n }]), {\n [BORDER_SURROUND]: hairline\n }];\n return _createVNode(tag, {\n \"type\": nativeType,\n \"class\": classes,\n \"style\": getStyle(),\n \"disabled\": disabled,\n \"onClick\": onClick\n }, {\n default: () => [_createVNode(\"div\", {\n \"class\": bem('content')\n }, [iconPosition === 'left' && renderIcon(), renderText(), iconPosition === 'right' && renderIcon()])]\n });\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _Button from './Button';\nexport var Button = withInstall(_Button);\nexport default Button;","export const HOOK_SETUP = 'devtools-plugin:setup';\nexport const HOOK_PLUGIN_SETTINGS_SET = 'plugin:settings:set';\n","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../../icon/index.css';\nimport '../../cell/index.css';\nimport '../index.css';","var global = require('../internals/global');\nvar call = require('../internals/function-call');\nvar isObject = require('../internals/is-object');\nvar isSymbol = require('../internals/is-symbol');\nvar getMethod = require('../internals/get-method');\nvar ordinaryToPrimitive = require('../internals/ordinary-to-primitive');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TypeError = global.TypeError;\nvar TO_PRIMITIVE = wellKnownSymbol('toPrimitive');\n\n// `ToPrimitive` abstract operation\n// https://tc39.es/ecma262/#sec-toprimitive\nmodule.exports = function (input, pref) {\n if (!isObject(input) || isSymbol(input)) return input;\n var exoticToPrim = getMethod(input, TO_PRIMITIVE);\n var result;\n if (exoticToPrim) {\n if (pref === undefined) pref = 'default';\n result = call(exoticToPrim, input, pref);\n if (!isObject(result) || isSymbol(result)) return result;\n throw TypeError(\"Can't convert object to primitive value\");\n }\n if (pref === undefined) pref = 'number';\n return ordinaryToPrimitive(input, pref);\n};\n","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../../icon/index.css';\nimport '../index.css';","import { camelize } from './format'; // https://github.com/youzan/vant/issues/8302\n\nexport function withInstall(options) {\n options.install = app => {\n var {\n name\n } = options;\n app.component(name, options);\n app.component(camelize(\"-\" + name), options);\n };\n\n return options;\n}","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../index.css';","module.exports = false;\n","var call = Function.prototype.call;\n\nmodule.exports = call.bind ? call.bind(call) : function () {\n return call.apply(call, arguments);\n};\n","var uncurryThis = require('../internals/function-uncurry-this');\n\nvar toString = uncurryThis({}.toString);\nvar stringSlice = uncurryThis(''.slice);\n\nmodule.exports = function (it) {\n return stringSlice(toString(it), 8, -1);\n};\n","var global = require('../internals/global');\nvar setGlobal = require('../internals/set-global');\n\nvar SHARED = '__core-js_shared__';\nvar store = global[SHARED] || setGlobal(SHARED, {});\n\nmodule.exports = store;\n","var g;\n\n// This works in non-strict mode\ng = (function() {\n\treturn this;\n})();\n\ntry {\n\t// This works if eval is allowed (see CSP)\n\tg = g || new Function(\"return this\")();\n} catch (e) {\n\t// This works if the window reference is available\n\tif (typeof window === \"object\") g = window;\n}\n\n// g can still be undefined, but nothing to do about it...\n// We return undefined, instead of nothing here, so it's\n// easier to handle this case. if(!global) { ...}\n\nmodule.exports = g;\n","var uncurryThis = require('../internals/function-uncurry-this');\nvar hasOwn = require('../internals/has-own-property');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar indexOf = require('../internals/array-includes').indexOf;\nvar hiddenKeys = require('../internals/hidden-keys');\n\nvar push = uncurryThis([].push);\n\nmodule.exports = function (object, names) {\n var O = toIndexedObject(object);\n var i = 0;\n var result = [];\n var key;\n for (key in O) !hasOwn(hiddenKeys, key) && hasOwn(O, key) && push(result, key);\n // Don't enum bug & hidden keys\n while (names.length > i) if (hasOwn(O, key = names[i++])) {\n ~indexOf(result, key) || push(result, key);\n }\n return result;\n};\n","var global = require('../internals/global');\nvar isObject = require('../internals/is-object');\n\nvar document = global.document;\n// typeof document.createElement is 'object' in old IE\nvar EXISTS = isObject(document) && isObject(document.createElement);\n\nmodule.exports = function (it) {\n return EXISTS ? document.createElement(it) : {};\n};\n","var $ = require('../internals/export');\nvar assign = require('../internals/object-assign');\n\n// `Object.assign` method\n// https://tc39.es/ecma262/#sec-object.assign\n// eslint-disable-next-line es/no-object-assign -- required for testing\n$({ target: 'Object', stat: true, forced: Object.assign !== assign }, {\n assign: assign\n});\n","import { ref } from 'vue';\nvar MIN_DISTANCE = 10;\n\nfunction getDirection(x, y) {\n if (x > y && x > MIN_DISTANCE) {\n return 'horizontal';\n }\n\n if (y > x && y > MIN_DISTANCE) {\n return 'vertical';\n }\n\n return '';\n}\n\nexport function useTouch() {\n var startX = ref(0);\n var startY = ref(0);\n var deltaX = ref(0);\n var deltaY = ref(0);\n var offsetX = ref(0);\n var offsetY = ref(0);\n var direction = ref('');\n\n var isVertical = () => direction.value === 'vertical';\n\n var isHorizontal = () => direction.value === 'horizontal';\n\n var reset = () => {\n deltaX.value = 0;\n deltaY.value = 0;\n offsetX.value = 0;\n offsetY.value = 0;\n direction.value = '';\n };\n\n var start = event => {\n reset();\n startX.value = event.touches[0].clientX;\n startY.value = event.touches[0].clientY;\n };\n\n var move = event => {\n var touch = event.touches[0]; // Fix: Safari back will set clientX to negative number\n\n deltaX.value = touch.clientX < 0 ? 0 : touch.clientX - startX.value;\n deltaY.value = touch.clientY - startY.value;\n offsetX.value = Math.abs(deltaX.value);\n offsetY.value = Math.abs(deltaY.value);\n\n if (!direction.value) {\n direction.value = getDirection(offsetX.value, offsetY.value);\n }\n };\n\n return {\n move,\n start,\n reset,\n startX,\n startY,\n deltaX,\n deltaY,\n offsetX,\n offsetY,\n direction,\n isVertical,\n isHorizontal\n };\n}","var anObject = require('../internals/an-object');\nvar isObject = require('../internals/is-object');\nvar newPromiseCapability = require('../internals/new-promise-capability');\n\nmodule.exports = function (C, x) {\n anObject(C);\n if (isObject(x) && x.constructor === C) return x;\n var promiseCapability = newPromiseCapability.f(C);\n var resolve = promiseCapability.resolve;\n resolve(x);\n return promiseCapability.promise;\n};\n","var global = require('../internals/global');\n\n// eslint-disable-next-line es/no-object-defineproperty -- safe\nvar defineProperty = Object.defineProperty;\n\nmodule.exports = function (key, value) {\n try {\n defineProperty(global, key, { value: value, configurable: true, writable: true });\n } catch (error) {\n global[key] = value;\n } return value;\n};\n","module.exports = {};\n","module.exports = function (exec) {\n try {\n return !!exec();\n } catch (error) {\n return true;\n }\n};\n","var global = require('../internals/global');\nvar isCallable = require('../internals/is-callable');\n\nvar aFunction = function (argument) {\n return isCallable(argument) ? argument : undefined;\n};\n\nmodule.exports = function (namespace, method) {\n return arguments.length < 2 ? aFunction(global[namespace]) : global[namespace] && global[namespace][method];\n};\n","import { ref, watch } from 'vue';\nexport function useLazyRender(show) {\n var inited = ref(false);\n watch(show, value => {\n if (value) {\n inited.value = value;\n }\n }, {\n immediate: true\n });\n return render => () => inited.value ? render() : null;\n}","import { withInstall } from '../utils';\nimport _Row from './Row';\nexport var Row = withInstall(_Row);\nexport default Row;","'use strict';\nvar $propertyIsEnumerable = {}.propertyIsEnumerable;\n// eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\nvar getOwnPropertyDescriptor = Object.getOwnPropertyDescriptor;\n\n// Nashorn ~ JDK8 bug\nvar NASHORN_BUG = getOwnPropertyDescriptor && !$propertyIsEnumerable.call({ 1: 2 }, 1);\n\n// `Object.prototype.propertyIsEnumerable` method implementation\n// https://tc39.es/ecma262/#sec-object.prototype.propertyisenumerable\nexports.f = NASHORN_BUG ? function propertyIsEnumerable(V) {\n var descriptor = getOwnPropertyDescriptor(this, V);\n return !!descriptor && descriptor.enumerable;\n} : $propertyIsEnumerable;\n","/* eslint-disable no-proto -- safe */\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar anObject = require('../internals/an-object');\nvar aPossiblePrototype = require('../internals/a-possible-prototype');\n\n// `Object.setPrototypeOf` method\n// https://tc39.es/ecma262/#sec-object.setprototypeof\n// Works with __proto__ only. Old v8 can't work with null proto objects.\n// eslint-disable-next-line es/no-object-setprototypeof -- safe\nmodule.exports = Object.setPrototypeOf || ('__proto__' in {} ? function () {\n var CORRECT_SETTER = false;\n var test = {};\n var setter;\n try {\n // eslint-disable-next-line es/no-object-getownpropertydescriptor -- safe\n setter = uncurryThis(Object.getOwnPropertyDescriptor(Object.prototype, '__proto__').set);\n setter(test, []);\n CORRECT_SETTER = test instanceof Array;\n } catch (error) { /* empty */ }\n return function setPrototypeOf(O, proto) {\n anObject(O);\n aPossiblePrototype(proto);\n if (CORRECT_SETTER) setter(O, proto);\n else O.__proto__ = proto;\n return O;\n };\n}() : undefined);\n","var TO_STRING_TAG_SUPPORT = require('../internals/to-string-tag-support');\nvar redefine = require('../internals/redefine');\nvar toString = require('../internals/object-to-string');\n\n// `Object.prototype.toString` method\n// https://tc39.es/ecma262/#sec-object.prototype.tostring\nif (!TO_STRING_TAG_SUPPORT) {\n redefine(Object.prototype, 'toString', toString, { unsafe: true });\n}\n","var defineProperty = require('../internals/object-define-property').f;\nvar hasOwn = require('../internals/has-own-property');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\n\nmodule.exports = function (it, TAG, STATIC) {\n if (it && !hasOwn(it = STATIC ? it : it.prototype, TO_STRING_TAG)) {\n defineProperty(it, TO_STRING_TAG, { configurable: true, value: TAG });\n }\n};\n","var userAgent = require('../internals/engine-user-agent');\nvar global = require('../internals/global');\n\nmodule.exports = /ipad|iphone|ipod/i.test(userAgent) && global.Pebble !== undefined;\n","'use strict';\n// TODO: Remove from `core-js@4` since it's moved to entry points\nrequire('../modules/es.regexp.exec');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar redefine = require('../internals/redefine');\nvar regexpExec = require('../internals/regexp-exec');\nvar fails = require('../internals/fails');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\n\nvar SPECIES = wellKnownSymbol('species');\nvar RegExpPrototype = RegExp.prototype;\n\nmodule.exports = function (KEY, exec, FORCED, SHAM) {\n var SYMBOL = wellKnownSymbol(KEY);\n\n var DELEGATES_TO_SYMBOL = !fails(function () {\n // String methods call symbol-named RegEp methods\n var O = {};\n O[SYMBOL] = function () { return 7; };\n return ''[KEY](O) != 7;\n });\n\n var DELEGATES_TO_EXEC = DELEGATES_TO_SYMBOL && !fails(function () {\n // Symbol-named RegExp methods call .exec\n var execCalled = false;\n var re = /a/;\n\n if (KEY === 'split') {\n // We can't use real regex here since it causes deoptimization\n // and serious performance degradation in V8\n // https://github.com/zloirock/core-js/issues/306\n re = {};\n // RegExp[@@split] doesn't call the regex's exec method, but first creates\n // a new one. We need to return the patched regex when creating the new one.\n re.constructor = {};\n re.constructor[SPECIES] = function () { return re; };\n re.flags = '';\n re[SYMBOL] = /./[SYMBOL];\n }\n\n re.exec = function () { execCalled = true; return null; };\n\n re[SYMBOL]('');\n return !execCalled;\n });\n\n if (\n !DELEGATES_TO_SYMBOL ||\n !DELEGATES_TO_EXEC ||\n FORCED\n ) {\n var uncurriedNativeRegExpMethod = uncurryThis(/./[SYMBOL]);\n var methods = exec(SYMBOL, ''[KEY], function (nativeMethod, regexp, str, arg2, forceStringMethod) {\n var uncurriedNativeMethod = uncurryThis(nativeMethod);\n var $exec = regexp.exec;\n if ($exec === regexpExec || $exec === RegExpPrototype.exec) {\n if (DELEGATES_TO_SYMBOL && !forceStringMethod) {\n // The native String method already delegates to @@method (this\n // polyfilled function), leasing to infinite recursion.\n // We avoid it by directly calling the native @@method method.\n return { done: true, value: uncurriedNativeRegExpMethod(regexp, str, arg2) };\n }\n return { done: true, value: uncurriedNativeMethod(str, regexp, arg2) };\n }\n return { done: false };\n });\n\n redefine(String.prototype, KEY, methods[0]);\n redefine(RegExpPrototype, SYMBOL, methods[1]);\n }\n\n if (SHAM) createNonEnumerableProperty(RegExpPrototype[SYMBOL], 'sham', true);\n};\n","\"use strict\";\nObject.defineProperty(exports, \"__esModule\", { value: true });\n// runtime helper for setting properties on components\n// in a tree-shakable way\nexports.default = (sfc, props) => {\n const target = sfc.__vccOpts || sfc;\n for (const [key, val] of props) {\n target[key] = val;\n }\n return target;\n};\n","var global = require('../internals/global');\nvar getBuiltIn = require('../internals/get-built-in');\nvar isCallable = require('../internals/is-callable');\nvar isPrototypeOf = require('../internals/object-is-prototype-of');\nvar USE_SYMBOL_AS_UID = require('../internals/use-symbol-as-uid');\n\nvar Object = global.Object;\n\nmodule.exports = USE_SYMBOL_AS_UID ? function (it) {\n return typeof it == 'symbol';\n} : function (it) {\n var $Symbol = getBuiltIn('Symbol');\n return isCallable($Symbol) && isPrototypeOf($Symbol.prototype, Object(it));\n};\n","var check = function (it) {\n return it && it.Math == Math && it;\n};\n\n// https://github.com/zloirock/core-js/issues/86#issuecomment-115759028\nmodule.exports =\n // eslint-disable-next-line es/no-global-this -- safe\n check(typeof globalThis == 'object' && globalThis) ||\n check(typeof window == 'object' && window) ||\n // eslint-disable-next-line no-restricted-globals -- safe\n check(typeof self == 'object' && self) ||\n check(typeof global == 'object' && global) ||\n // eslint-disable-next-line no-new-func -- fallback\n (function () { return this; })() || Function('return this')();\n","var aCallable = require('../internals/a-callable');\n\n// `GetMethod` abstract operation\n// https://tc39.es/ecma262/#sec-getmethod\nmodule.exports = function (V, P) {\n var func = V[P];\n return func == null ? undefined : aCallable(func);\n};\n","var global = require('../internals/global');\nvar DOMIterables = require('../internals/dom-iterables');\nvar DOMTokenListPrototype = require('../internals/dom-token-list-prototype');\nvar ArrayIteratorMethods = require('../modules/es.array.iterator');\nvar createNonEnumerableProperty = require('../internals/create-non-enumerable-property');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar ArrayValues = ArrayIteratorMethods.values;\n\nvar handlePrototype = function (CollectionPrototype, COLLECTION_NAME) {\n if (CollectionPrototype) {\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype[ITERATOR] !== ArrayValues) try {\n createNonEnumerableProperty(CollectionPrototype, ITERATOR, ArrayValues);\n } catch (error) {\n CollectionPrototype[ITERATOR] = ArrayValues;\n }\n if (!CollectionPrototype[TO_STRING_TAG]) {\n createNonEnumerableProperty(CollectionPrototype, TO_STRING_TAG, COLLECTION_NAME);\n }\n if (DOMIterables[COLLECTION_NAME]) for (var METHOD_NAME in ArrayIteratorMethods) {\n // some Chrome versions have non-configurable methods on DOMTokenList\n if (CollectionPrototype[METHOD_NAME] !== ArrayIteratorMethods[METHOD_NAME]) try {\n createNonEnumerableProperty(CollectionPrototype, METHOD_NAME, ArrayIteratorMethods[METHOD_NAME]);\n } catch (error) {\n CollectionPrototype[METHOD_NAME] = ArrayIteratorMethods[METHOD_NAME];\n }\n }\n }\n};\n\nfor (var COLLECTION_NAME in DOMIterables) {\n handlePrototype(global[COLLECTION_NAME] && global[COLLECTION_NAME].prototype, COLLECTION_NAME);\n}\n\nhandlePrototype(DOMTokenListPrototype, 'DOMTokenList');\n","var internalObjectKeys = require('../internals/object-keys-internal');\nvar enumBugKeys = require('../internals/enum-bug-keys');\n\n// `Object.keys` method\n// https://tc39.es/ecma262/#sec-object.keys\n// eslint-disable-next-line es/no-object-keys -- safe\nmodule.exports = Object.keys || function keys(O) {\n return internalObjectKeys(O, enumBugKeys);\n};\n","var global = require('../internals/global');\nvar hasOwn = require('../internals/has-own-property');\nvar isCallable = require('../internals/is-callable');\nvar toObject = require('../internals/to-object');\nvar sharedKey = require('../internals/shared-key');\nvar CORRECT_PROTOTYPE_GETTER = require('../internals/correct-prototype-getter');\n\nvar IE_PROTO = sharedKey('IE_PROTO');\nvar Object = global.Object;\nvar ObjectPrototype = Object.prototype;\n\n// `Object.getPrototypeOf` method\n// https://tc39.es/ecma262/#sec-object.getprototypeof\nmodule.exports = CORRECT_PROTOTYPE_GETTER ? Object.getPrototypeOf : function (O) {\n var object = toObject(O);\n if (hasOwn(object, IE_PROTO)) return object[IE_PROTO];\n var constructor = object.constructor;\n if (isCallable(constructor) && object instanceof constructor) {\n return constructor.prototype;\n } return object instanceof Object ? ObjectPrototype : null;\n};\n","var fails = require('../internals/fails');\n\nmodule.exports = !fails(function () {\n function F() { /* empty */ }\n F.prototype.constructor = null;\n // eslint-disable-next-line es/no-object-getprototypeof -- required for testing\n return Object.getPrototypeOf(new F()) !== F.prototype;\n});\n","'use strict';\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar addToUnscopables = require('../internals/add-to-unscopables');\nvar Iterators = require('../internals/iterators');\nvar InternalStateModule = require('../internals/internal-state');\nvar defineIterator = require('../internals/define-iterator');\n\nvar ARRAY_ITERATOR = 'Array Iterator';\nvar setInternalState = InternalStateModule.set;\nvar getInternalState = InternalStateModule.getterFor(ARRAY_ITERATOR);\n\n// `Array.prototype.entries` method\n// https://tc39.es/ecma262/#sec-array.prototype.entries\n// `Array.prototype.keys` method\n// https://tc39.es/ecma262/#sec-array.prototype.keys\n// `Array.prototype.values` method\n// https://tc39.es/ecma262/#sec-array.prototype.values\n// `Array.prototype[@@iterator]` method\n// https://tc39.es/ecma262/#sec-array.prototype-@@iterator\n// `CreateArrayIterator` internal method\n// https://tc39.es/ecma262/#sec-createarrayiterator\nmodule.exports = defineIterator(Array, 'Array', function (iterated, kind) {\n setInternalState(this, {\n type: ARRAY_ITERATOR,\n target: toIndexedObject(iterated), // target\n index: 0, // next index\n kind: kind // kind\n });\n// `%ArrayIteratorPrototype%.next` method\n// https://tc39.es/ecma262/#sec-%arrayiteratorprototype%.next\n}, function () {\n var state = getInternalState(this);\n var target = state.target;\n var kind = state.kind;\n var index = state.index++;\n if (!target || index >= target.length) {\n state.target = undefined;\n return { value: undefined, done: true };\n }\n if (kind == 'keys') return { value: index, done: false };\n if (kind == 'values') return { value: target[index], done: false };\n return { value: [index, target[index]], done: false };\n}, 'values');\n\n// argumentsList[@@iterator] is %ArrayProto_values%\n// https://tc39.es/ecma262/#sec-createunmappedargumentsobject\n// https://tc39.es/ecma262/#sec-createmappedargumentsobject\nIterators.Arguments = Iterators.Array;\n\n// https://tc39.es/ecma262/#sec-array.prototype-@@unscopables\naddToUnscopables('keys');\naddToUnscopables('values');\naddToUnscopables('entries');\n","import { withInstall } from '../utils';\nimport _RadioGroup from './RadioGroup';\nexport var RadioGroup = withInstall(_RadioGroup);\nexport default RadioGroup;","var redefine = require('../internals/redefine');\n\nmodule.exports = function (target, src, options) {\n for (var key in src) redefine(target, key, src[key], options);\n return target;\n};\n","var FunctionPrototype = Function.prototype;\nvar bind = FunctionPrototype.bind;\nvar call = FunctionPrototype.call;\nvar callBind = bind && bind.bind(call);\n\nmodule.exports = bind ? function (fn) {\n return fn && callBind(call, fn);\n} : function (fn) {\n return fn && function () {\n return call.apply(fn, arguments);\n };\n};\n","import { watch, onBeforeUnmount, onDeactivated } from 'vue';\nimport { getScrollParent, onMountedOrActivated } from '@vant/use';\nimport { useTouch } from './use-touch';\nimport { preventDefault } from '../utils';\nvar totalLockCount = 0;\nvar BODY_LOCK_CLASS = 'van-overflow-hidden';\nexport function useLockScroll(rootRef, shouldLock) {\n var touch = useTouch();\n\n var onTouchMove = event => {\n touch.move(event);\n var direction = touch.deltaY.value > 0 ? '10' : '01';\n var el = getScrollParent(event.target, rootRef.value);\n var {\n scrollHeight,\n offsetHeight,\n scrollTop\n } = el;\n var status = '11';\n\n if (scrollTop === 0) {\n status = offsetHeight >= scrollHeight ? '00' : '01';\n } else if (scrollTop + offsetHeight >= scrollHeight) {\n status = '10';\n }\n\n if (status !== '11' && touch.isVertical() && !(parseInt(status, 2) & parseInt(direction, 2))) {\n preventDefault(event, true);\n }\n };\n\n var lock = () => {\n document.addEventListener('touchstart', touch.start);\n document.addEventListener('touchmove', onTouchMove, {\n passive: false\n });\n\n if (!totalLockCount) {\n document.body.classList.add(BODY_LOCK_CLASS);\n }\n\n totalLockCount++;\n };\n\n var unlock = () => {\n if (totalLockCount) {\n document.removeEventListener('touchstart', touch.start);\n document.removeEventListener('touchmove', onTouchMove);\n totalLockCount--;\n\n if (!totalLockCount) {\n document.body.classList.remove(BODY_LOCK_CLASS);\n }\n }\n };\n\n var init = () => shouldLock() && lock();\n\n var destroy = () => shouldLock() && unlock();\n\n onMountedOrActivated(init);\n onDeactivated(destroy);\n onBeforeUnmount(destroy);\n watch(shouldLock, value => {\n value ? lock() : unlock();\n });\n}","import { Fragment as _Fragment, withDirectives as _withDirectives, mergeProps as _mergeProps, vShow as _vShow, createVNode as _createVNode, resolveDirective as _resolveDirective } from \"vue\";\nimport { ref, watch, provide, Teleport, computed, onMounted, Transition, onActivated, onDeactivated, defineComponent } from 'vue'; // Utils\n\nimport { popupSharedProps } from './shared';\nimport { isDef, extend, makeStringProp, callInterceptor, createNamespace, HAPTICS_FEEDBACK } from '../utils'; // Composables\n\nimport { useEventListener } from '@vant/use';\nimport { useExpose } from '../composables/use-expose';\nimport { useLockScroll } from '../composables/use-lock-scroll';\nimport { useLazyRender } from '../composables/use-lazy-render';\nimport { POPUP_TOGGLE_KEY } from '../composables/on-popup-reopen'; // Components\n\nimport { Icon } from '../icon';\nimport { Overlay } from '../overlay';\nvar popupProps = extend({}, popupSharedProps, {\n round: Boolean,\n position: makeStringProp('center'),\n closeIcon: makeStringProp('cross'),\n closeable: Boolean,\n transition: String,\n iconPrefix: String,\n closeOnPopstate: Boolean,\n closeIconPosition: makeStringProp('top-right'),\n safeAreaInsetBottom: Boolean\n});\nvar [name, bem] = createNamespace('popup');\nvar globalZIndex = 2000;\nexport default defineComponent({\n name,\n inheritAttrs: false,\n props: popupProps,\n emits: ['open', 'close', 'opened', 'closed', 'update:show', 'click-overlay', 'click-close-icon'],\n\n setup(props, _ref) {\n var {\n emit,\n attrs,\n slots\n } = _ref;\n var opened;\n var shouldReopen;\n var zIndex = ref();\n var popupRef = ref();\n var lazyRender = useLazyRender(() => props.show || !props.lazyRender);\n var style = computed(() => {\n var style = {\n zIndex: zIndex.value\n };\n\n if (isDef(props.duration)) {\n var key = props.position === 'center' ? 'animationDuration' : 'transitionDuration';\n style[key] = props.duration + \"s\";\n }\n\n return style;\n });\n\n var open = () => {\n if (!opened) {\n if (props.zIndex !== undefined) {\n globalZIndex = +props.zIndex;\n }\n\n opened = true;\n zIndex.value = ++globalZIndex;\n emit('open');\n }\n };\n\n var close = () => {\n if (opened) {\n callInterceptor(props.beforeClose, {\n done() {\n opened = false;\n emit('close');\n emit('update:show', false);\n }\n\n });\n }\n };\n\n var onClickOverlay = event => {\n emit('click-overlay', event);\n\n if (props.closeOnClickOverlay) {\n close();\n }\n };\n\n var renderOverlay = () => {\n if (props.overlay) {\n return _createVNode(Overlay, {\n \"show\": props.show,\n \"class\": props.overlayClass,\n \"zIndex\": zIndex.value,\n \"duration\": props.duration,\n \"customStyle\": props.overlayStyle,\n \"onClick\": onClickOverlay\n }, {\n default: slots['overlay-content']\n });\n }\n };\n\n var onClickCloseIcon = event => {\n emit('click-close-icon', event);\n close();\n };\n\n var renderCloseIcon = () => {\n if (props.closeable) {\n return _createVNode(Icon, {\n \"role\": \"button\",\n \"tabindex\": 0,\n \"name\": props.closeIcon,\n \"class\": [bem('close-icon', props.closeIconPosition), HAPTICS_FEEDBACK],\n \"classPrefix\": props.iconPrefix,\n \"onClick\": onClickCloseIcon\n }, null);\n }\n };\n\n var onOpened = () => emit('opened');\n\n var onClosed = () => emit('closed');\n\n var renderPopup = lazyRender(() => {\n var {\n round,\n position,\n safeAreaInsetBottom\n } = props;\n return _withDirectives(_createVNode(\"div\", _mergeProps({\n \"ref\": popupRef,\n \"style\": style.value,\n \"class\": [bem({\n round,\n [position]: position\n }), {\n 'van-safe-area-bottom': safeAreaInsetBottom\n }]\n }, attrs), [slots.default == null ? void 0 : slots.default(), renderCloseIcon()]), [[_vShow, props.show]]);\n });\n\n var renderTransition = () => {\n var {\n position,\n transition,\n transitionAppear\n } = props;\n var name = position === 'center' ? 'van-fade' : \"van-popup-slide-\" + position;\n return _createVNode(Transition, {\n \"name\": transition || name,\n \"appear\": transitionAppear,\n \"onAfterEnter\": onOpened,\n \"onAfterLeave\": onClosed\n }, {\n default: renderPopup\n });\n };\n\n watch(() => props.show, value => {\n if (value) {\n open();\n } else {\n opened = false;\n emit('close');\n }\n });\n useExpose({\n popupRef\n });\n useLockScroll(popupRef, () => props.show && props.lockScroll);\n useEventListener('popstate', () => {\n if (props.closeOnPopstate) {\n close();\n shouldReopen = false;\n }\n });\n onMounted(() => {\n if (props.show) {\n open();\n }\n });\n onActivated(() => {\n if (shouldReopen) {\n emit('update:show', true);\n shouldReopen = false;\n }\n });\n onDeactivated(() => {\n if (props.show) {\n close();\n shouldReopen = true;\n }\n });\n provide(POPUP_TOGGLE_KEY, () => props.show);\n return () => {\n if (props.teleport) {\n return _createVNode(Teleport, {\n \"to\": props.teleport\n }, {\n default: () => [renderOverlay(), renderTransition()]\n });\n }\n\n return _createVNode(_Fragment, null, [renderOverlay(), renderTransition()]);\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _Popup from './Popup';\nexport var Popup = withInstall(_Popup);\nexport default Popup;","module.exports = function (exec) {\n try {\n return { error: false, value: exec() };\n } catch (error) {\n return { error: true, value: error };\n }\n};\n","'use strict';\nvar $ = require('../internals/export');\nvar IS_PURE = require('../internals/is-pure');\nvar global = require('../internals/global');\nvar getBuiltIn = require('../internals/get-built-in');\nvar call = require('../internals/function-call');\nvar NativePromise = require('../internals/native-promise-constructor');\nvar redefine = require('../internals/redefine');\nvar redefineAll = require('../internals/redefine-all');\nvar setPrototypeOf = require('../internals/object-set-prototype-of');\nvar setToStringTag = require('../internals/set-to-string-tag');\nvar setSpecies = require('../internals/set-species');\nvar aCallable = require('../internals/a-callable');\nvar isCallable = require('../internals/is-callable');\nvar isObject = require('../internals/is-object');\nvar anInstance = require('../internals/an-instance');\nvar inspectSource = require('../internals/inspect-source');\nvar iterate = require('../internals/iterate');\nvar checkCorrectnessOfIteration = require('../internals/check-correctness-of-iteration');\nvar speciesConstructor = require('../internals/species-constructor');\nvar task = require('../internals/task').set;\nvar microtask = require('../internals/microtask');\nvar promiseResolve = require('../internals/promise-resolve');\nvar hostReportErrors = require('../internals/host-report-errors');\nvar newPromiseCapabilityModule = require('../internals/new-promise-capability');\nvar perform = require('../internals/perform');\nvar InternalStateModule = require('../internals/internal-state');\nvar isForced = require('../internals/is-forced');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar IS_BROWSER = require('../internals/engine-is-browser');\nvar IS_NODE = require('../internals/engine-is-node');\nvar V8_VERSION = require('../internals/engine-v8-version');\n\nvar SPECIES = wellKnownSymbol('species');\nvar PROMISE = 'Promise';\n\nvar getInternalState = InternalStateModule.get;\nvar setInternalState = InternalStateModule.set;\nvar getInternalPromiseState = InternalStateModule.getterFor(PROMISE);\nvar NativePromisePrototype = NativePromise && NativePromise.prototype;\nvar PromiseConstructor = NativePromise;\nvar PromisePrototype = NativePromisePrototype;\nvar TypeError = global.TypeError;\nvar document = global.document;\nvar process = global.process;\nvar newPromiseCapability = newPromiseCapabilityModule.f;\nvar newGenericPromiseCapability = newPromiseCapability;\n\nvar DISPATCH_EVENT = !!(document && document.createEvent && global.dispatchEvent);\nvar NATIVE_REJECTION_EVENT = isCallable(global.PromiseRejectionEvent);\nvar UNHANDLED_REJECTION = 'unhandledrejection';\nvar REJECTION_HANDLED = 'rejectionhandled';\nvar PENDING = 0;\nvar FULFILLED = 1;\nvar REJECTED = 2;\nvar HANDLED = 1;\nvar UNHANDLED = 2;\nvar SUBCLASSING = false;\n\nvar Internal, OwnPromiseCapability, PromiseWrapper, nativeThen;\n\nvar FORCED = isForced(PROMISE, function () {\n var PROMISE_CONSTRUCTOR_SOURCE = inspectSource(PromiseConstructor);\n var GLOBAL_CORE_JS_PROMISE = PROMISE_CONSTRUCTOR_SOURCE !== String(PromiseConstructor);\n // V8 6.6 (Node 10 and Chrome 66) have a bug with resolving custom thenables\n // https://bugs.chromium.org/p/chromium/issues/detail?id=830565\n // We can't detect it synchronously, so just check versions\n if (!GLOBAL_CORE_JS_PROMISE && V8_VERSION === 66) return true;\n // We need Promise#finally in the pure version for preventing prototype pollution\n if (IS_PURE && !PromisePrototype['finally']) return true;\n // We can't use @@species feature detection in V8 since it causes\n // deoptimization and performance degradation\n // https://github.com/zloirock/core-js/issues/679\n if (V8_VERSION >= 51 && /native code/.test(PROMISE_CONSTRUCTOR_SOURCE)) return false;\n // Detect correctness of subclassing with @@species support\n var promise = new PromiseConstructor(function (resolve) { resolve(1); });\n var FakePromise = function (exec) {\n exec(function () { /* empty */ }, function () { /* empty */ });\n };\n var constructor = promise.constructor = {};\n constructor[SPECIES] = FakePromise;\n SUBCLASSING = promise.then(function () { /* empty */ }) instanceof FakePromise;\n if (!SUBCLASSING) return true;\n // Unhandled rejections tracking support, NodeJS Promise without it fails @@species test\n return !GLOBAL_CORE_JS_PROMISE && IS_BROWSER && !NATIVE_REJECTION_EVENT;\n});\n\nvar INCORRECT_ITERATION = FORCED || !checkCorrectnessOfIteration(function (iterable) {\n PromiseConstructor.all(iterable)['catch'](function () { /* empty */ });\n});\n\n// helpers\nvar isThenable = function (it) {\n var then;\n return isObject(it) && isCallable(then = it.then) ? then : false;\n};\n\nvar notify = function (state, isReject) {\n if (state.notified) return;\n state.notified = true;\n var chain = state.reactions;\n microtask(function () {\n var value = state.value;\n var ok = state.state == FULFILLED;\n var index = 0;\n // variable length - can't use forEach\n while (chain.length > index) {\n var reaction = chain[index++];\n var handler = ok ? reaction.ok : reaction.fail;\n var resolve = reaction.resolve;\n var reject = reaction.reject;\n var domain = reaction.domain;\n var result, then, exited;\n try {\n if (handler) {\n if (!ok) {\n if (state.rejection === UNHANDLED) onHandleUnhandled(state);\n state.rejection = HANDLED;\n }\n if (handler === true) result = value;\n else {\n if (domain) domain.enter();\n result = handler(value); // can throw\n if (domain) {\n domain.exit();\n exited = true;\n }\n }\n if (result === reaction.promise) {\n reject(TypeError('Promise-chain cycle'));\n } else if (then = isThenable(result)) {\n call(then, result, resolve, reject);\n } else resolve(result);\n } else reject(value);\n } catch (error) {\n if (domain && !exited) domain.exit();\n reject(error);\n }\n }\n state.reactions = [];\n state.notified = false;\n if (isReject && !state.rejection) onUnhandled(state);\n });\n};\n\nvar dispatchEvent = function (name, promise, reason) {\n var event, handler;\n if (DISPATCH_EVENT) {\n event = document.createEvent('Event');\n event.promise = promise;\n event.reason = reason;\n event.initEvent(name, false, true);\n global.dispatchEvent(event);\n } else event = { promise: promise, reason: reason };\n if (!NATIVE_REJECTION_EVENT && (handler = global['on' + name])) handler(event);\n else if (name === UNHANDLED_REJECTION) hostReportErrors('Unhandled promise rejection', reason);\n};\n\nvar onUnhandled = function (state) {\n call(task, global, function () {\n var promise = state.facade;\n var value = state.value;\n var IS_UNHANDLED = isUnhandled(state);\n var result;\n if (IS_UNHANDLED) {\n result = perform(function () {\n if (IS_NODE) {\n process.emit('unhandledRejection', value, promise);\n } else dispatchEvent(UNHANDLED_REJECTION, promise, value);\n });\n // Browsers should not trigger `rejectionHandled` event if it was handled here, NodeJS - should\n state.rejection = IS_NODE || isUnhandled(state) ? UNHANDLED : HANDLED;\n if (result.error) throw result.value;\n }\n });\n};\n\nvar isUnhandled = function (state) {\n return state.rejection !== HANDLED && !state.parent;\n};\n\nvar onHandleUnhandled = function (state) {\n call(task, global, function () {\n var promise = state.facade;\n if (IS_NODE) {\n process.emit('rejectionHandled', promise);\n } else dispatchEvent(REJECTION_HANDLED, promise, state.value);\n });\n};\n\nvar bind = function (fn, state, unwrap) {\n return function (value) {\n fn(state, value, unwrap);\n };\n};\n\nvar internalReject = function (state, value, unwrap) {\n if (state.done) return;\n state.done = true;\n if (unwrap) state = unwrap;\n state.value = value;\n state.state = REJECTED;\n notify(state, true);\n};\n\nvar internalResolve = function (state, value, unwrap) {\n if (state.done) return;\n state.done = true;\n if (unwrap) state = unwrap;\n try {\n if (state.facade === value) throw TypeError(\"Promise can't be resolved itself\");\n var then = isThenable(value);\n if (then) {\n microtask(function () {\n var wrapper = { done: false };\n try {\n call(then, value,\n bind(internalResolve, wrapper, state),\n bind(internalReject, wrapper, state)\n );\n } catch (error) {\n internalReject(wrapper, error, state);\n }\n });\n } else {\n state.value = value;\n state.state = FULFILLED;\n notify(state, false);\n }\n } catch (error) {\n internalReject({ done: false }, error, state);\n }\n};\n\n// constructor polyfill\nif (FORCED) {\n // 25.4.3.1 Promise(executor)\n PromiseConstructor = function Promise(executor) {\n anInstance(this, PromisePrototype);\n aCallable(executor);\n call(Internal, this);\n var state = getInternalState(this);\n try {\n executor(bind(internalResolve, state), bind(internalReject, state));\n } catch (error) {\n internalReject(state, error);\n }\n };\n PromisePrototype = PromiseConstructor.prototype;\n // eslint-disable-next-line no-unused-vars -- required for `.length`\n Internal = function Promise(executor) {\n setInternalState(this, {\n type: PROMISE,\n done: false,\n notified: false,\n parent: false,\n reactions: [],\n rejection: false,\n state: PENDING,\n value: undefined\n });\n };\n Internal.prototype = redefineAll(PromisePrototype, {\n // `Promise.prototype.then` method\n // https://tc39.es/ecma262/#sec-promise.prototype.then\n then: function then(onFulfilled, onRejected) {\n var state = getInternalPromiseState(this);\n var reactions = state.reactions;\n var reaction = newPromiseCapability(speciesConstructor(this, PromiseConstructor));\n reaction.ok = isCallable(onFulfilled) ? onFulfilled : true;\n reaction.fail = isCallable(onRejected) && onRejected;\n reaction.domain = IS_NODE ? process.domain : undefined;\n state.parent = true;\n reactions[reactions.length] = reaction;\n if (state.state != PENDING) notify(state, false);\n return reaction.promise;\n },\n // `Promise.prototype.catch` method\n // https://tc39.es/ecma262/#sec-promise.prototype.catch\n 'catch': function (onRejected) {\n return this.then(undefined, onRejected);\n }\n });\n OwnPromiseCapability = function () {\n var promise = new Internal();\n var state = getInternalState(promise);\n this.promise = promise;\n this.resolve = bind(internalResolve, state);\n this.reject = bind(internalReject, state);\n };\n newPromiseCapabilityModule.f = newPromiseCapability = function (C) {\n return C === PromiseConstructor || C === PromiseWrapper\n ? new OwnPromiseCapability(C)\n : newGenericPromiseCapability(C);\n };\n\n if (!IS_PURE && isCallable(NativePromise) && NativePromisePrototype !== Object.prototype) {\n nativeThen = NativePromisePrototype.then;\n\n if (!SUBCLASSING) {\n // make `Promise#then` return a polyfilled `Promise` for native promise-based APIs\n redefine(NativePromisePrototype, 'then', function then(onFulfilled, onRejected) {\n var that = this;\n return new PromiseConstructor(function (resolve, reject) {\n call(nativeThen, that, resolve, reject);\n }).then(onFulfilled, onRejected);\n // https://github.com/zloirock/core-js/issues/640\n }, { unsafe: true });\n\n // makes sure that native promise-based APIs `Promise#catch` properly works with patched `Promise#then`\n redefine(NativePromisePrototype, 'catch', PromisePrototype['catch'], { unsafe: true });\n }\n\n // make `.constructor === Promise` work for native promise-based APIs\n try {\n delete NativePromisePrototype.constructor;\n } catch (error) { /* empty */ }\n\n // make `instanceof Promise` work for native promise-based APIs\n if (setPrototypeOf) {\n setPrototypeOf(NativePromisePrototype, PromisePrototype);\n }\n }\n}\n\n$({ global: true, wrap: true, forced: FORCED }, {\n Promise: PromiseConstructor\n});\n\nsetToStringTag(PromiseConstructor, PROMISE, false, true);\nsetSpecies(PROMISE);\n\nPromiseWrapper = getBuiltIn(PROMISE);\n\n// statics\n$({ target: PROMISE, stat: true, forced: FORCED }, {\n // `Promise.reject` method\n // https://tc39.es/ecma262/#sec-promise.reject\n reject: function reject(r) {\n var capability = newPromiseCapability(this);\n call(capability.reject, undefined, r);\n return capability.promise;\n }\n});\n\n$({ target: PROMISE, stat: true, forced: IS_PURE || FORCED }, {\n // `Promise.resolve` method\n // https://tc39.es/ecma262/#sec-promise.resolve\n resolve: function resolve(x) {\n return promiseResolve(IS_PURE && this === PromiseWrapper ? PromiseConstructor : this, x);\n }\n});\n\n$({ target: PROMISE, stat: true, forced: INCORRECT_ITERATION }, {\n // `Promise.all` method\n // https://tc39.es/ecma262/#sec-promise.all\n all: function all(iterable) {\n var C = this;\n var capability = newPromiseCapability(C);\n var resolve = capability.resolve;\n var reject = capability.reject;\n var result = perform(function () {\n var $promiseResolve = aCallable(C.resolve);\n var values = [];\n var counter = 0;\n var remaining = 1;\n iterate(iterable, function (promise) {\n var index = counter++;\n var alreadyCalled = false;\n remaining++;\n call($promiseResolve, C, promise).then(function (value) {\n if (alreadyCalled) return;\n alreadyCalled = true;\n values[index] = value;\n --remaining || resolve(values);\n }, reject);\n });\n --remaining || resolve(values);\n });\n if (result.error) reject(result.value);\n return capability.promise;\n },\n // `Promise.race` method\n // https://tc39.es/ecma262/#sec-promise.race\n race: function race(iterable) {\n var C = this;\n var capability = newPromiseCapability(C);\n var reject = capability.reject;\n var result = perform(function () {\n var $promiseResolve = aCallable(C.resolve);\n iterate(iterable, function (promise) {\n call($promiseResolve, C, promise).then(capability.resolve, reject);\n });\n });\n if (result.error) reject(result.value);\n return capability.promise;\n }\n});\n","var hasOwn = require('../internals/has-own-property');\nvar ownKeys = require('../internals/own-keys');\nvar getOwnPropertyDescriptorModule = require('../internals/object-get-own-property-descriptor');\nvar definePropertyModule = require('../internals/object-define-property');\n\nmodule.exports = function (target, source) {\n var keys = ownKeys(source);\n var defineProperty = definePropertyModule.f;\n var getOwnPropertyDescriptor = getOwnPropertyDescriptorModule.f;\n for (var i = 0; i < keys.length; i++) {\n var key = keys[i];\n if (!hasOwn(target, key)) defineProperty(target, key, getOwnPropertyDescriptor(source, key));\n }\n};\n","var classof = require('../internals/classof-raw');\n\n// `IsArray` abstract operation\n// https://tc39.es/ecma262/#sec-isarray\n// eslint-disable-next-line es/no-array-isarray -- safe\nmodule.exports = Array.isArray || function isArray(argument) {\n return classof(argument) == 'Array';\n};\n","import '../../style/base.css';\nimport '../../badge/index.css';\nimport '../../icon/index.css';\nimport '../../image/index.css';\nimport '../../loading/index.css';\nimport '../../overlay/index.css';\nimport '../../popup/index.css';\nimport '../../swipe/index.css';\nimport '../../swipe-item/index.css';\nimport '../../image-preview/index.css';\nimport '../index.css';","var wellKnownSymbol = require('../internals/well-known-symbol');\nvar Iterators = require('../internals/iterators');\n\nvar ITERATOR = wellKnownSymbol('iterator');\nvar ArrayPrototype = Array.prototype;\n\n// check on default Array iterator\nmodule.exports = function (it) {\n return it !== undefined && (Iterators.Array === it || ArrayPrototype[ITERATOR] === it);\n};\n","var $ = require('../internals/export');\nvar global = require('../internals/global');\nvar getBuiltIn = require('../internals/get-built-in');\nvar apply = require('../internals/function-apply');\nvar uncurryThis = require('../internals/function-uncurry-this');\nvar fails = require('../internals/fails');\n\nvar Array = global.Array;\nvar $stringify = getBuiltIn('JSON', 'stringify');\nvar exec = uncurryThis(/./.exec);\nvar charAt = uncurryThis(''.charAt);\nvar charCodeAt = uncurryThis(''.charCodeAt);\nvar replace = uncurryThis(''.replace);\nvar numberToString = uncurryThis(1.0.toString);\n\nvar tester = /[\\uD800-\\uDFFF]/g;\nvar low = /^[\\uD800-\\uDBFF]$/;\nvar hi = /^[\\uDC00-\\uDFFF]$/;\n\nvar fix = function (match, offset, string) {\n var prev = charAt(string, offset - 1);\n var next = charAt(string, offset + 1);\n if ((exec(low, match) && !exec(hi, next)) || (exec(hi, match) && !exec(low, prev))) {\n return '\\\\u' + numberToString(charCodeAt(match, 0), 16);\n } return match;\n};\n\nvar FORCED = fails(function () {\n return $stringify('\\uDF06\\uD834') !== '\"\\\\udf06\\\\ud834\"'\n || $stringify('\\uDEAD') !== '\"\\\\udead\"';\n});\n\nif ($stringify) {\n // `JSON.stringify` method\n // https://tc39.es/ecma262/#sec-json.stringify\n // https://github.com/tc39/proposal-well-formed-stringify\n $({ target: 'JSON', stat: true, forced: FORCED }, {\n // eslint-disable-next-line no-unused-vars -- required for `.length`\n stringify: function stringify(it, replacer, space) {\n for (var i = 0, l = arguments.length, args = Array(l); i < l; i++) args[i] = arguments[i];\n var result = apply($stringify, null, args);\n return typeof result == 'string' ? replace(result, tester, fix) : result;\n }\n });\n}\n","'use strict';\nvar aCallable = require('../internals/a-callable');\n\nvar PromiseCapability = function (C) {\n var resolve, reject;\n this.promise = new C(function ($$resolve, $$reject) {\n if (resolve !== undefined || reject !== undefined) throw TypeError('Bad Promise constructor');\n resolve = $$resolve;\n reject = $$reject;\n });\n this.resolve = aCallable(resolve);\n this.reject = aCallable(reject);\n};\n\n// `NewPromiseCapability` abstract operation\n// https://tc39.es/ecma262/#sec-newpromisecapability\nmodule.exports.f = function (C) {\n return new PromiseCapability(C);\n};\n","import '../../style/base.css';\nimport '../index.css';","import { isDef, isObject } from './validate';\nexport function deepClone(obj) {\n if (!isDef(obj)) {\n return obj;\n }\n\n if (Array.isArray(obj)) {\n return obj.map(item => deepClone(item));\n }\n\n if (isObject(obj)) {\n var to = {};\n Object.keys(obj).forEach(key => {\n to[key] = deepClone(obj[key]);\n });\n return to;\n }\n\n return obj;\n}","import { createVNode as _createVNode } from \"vue\";\nimport { ref, watch, reactive, defineComponent } from 'vue'; // Utils\n\nimport { deepClone } from '../utils/deep-clone';\nimport { clamp, isObject, unknownProp, numericProp, makeArrayProp, makeNumberProp, preventDefault, createNamespace, makeRequiredProp } from '../utils'; // Composables\n\nimport { useParent } from '@vant/use';\nimport { useTouch } from '../composables/use-touch';\nimport { useExpose } from '../composables/use-expose'; // Types\n\nvar DEFAULT_DURATION = 200; // 惯性滑动思路:\n// 在手指离开屏幕时,如果和上一次 move 时的间隔小于 `MOMENTUM_LIMIT_TIME` 且 move\n// 距离大于 `MOMENTUM_LIMIT_DISTANCE` 时,执行惯性滑动\n\nvar MOMENTUM_LIMIT_TIME = 300;\nvar MOMENTUM_LIMIT_DISTANCE = 15;\nvar [name, bem] = createNamespace('picker-column');\n\nfunction getElementTranslateY(element) {\n var {\n transform\n } = window.getComputedStyle(element);\n var translateY = transform.slice(7, transform.length - 1).split(', ')[5];\n return Number(translateY);\n}\n\nexport var PICKER_KEY = Symbol(name);\n\nvar isOptionDisabled = option => isObject(option) && option.disabled;\n\nexport default defineComponent({\n name,\n props: {\n textKey: makeRequiredProp(String),\n readonly: Boolean,\n allowHtml: Boolean,\n className: unknownProp,\n itemHeight: makeRequiredProp(Number),\n defaultIndex: makeNumberProp(0),\n swipeDuration: makeRequiredProp(numericProp),\n initialOptions: makeArrayProp(),\n visibleItemCount: makeRequiredProp(numericProp)\n },\n emits: ['change'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n var moving;\n var startOffset;\n var touchStartTime;\n var momentumOffset;\n var transitionEndTrigger;\n var wrapper = ref();\n var state = reactive({\n index: props.defaultIndex,\n offset: 0,\n duration: 0,\n options: deepClone(props.initialOptions)\n });\n var touch = useTouch();\n\n var count = () => state.options.length;\n\n var baseOffset = () => props.itemHeight * (+props.visibleItemCount - 1) / 2;\n\n var adjustIndex = index => {\n index = clamp(index, 0, count());\n\n for (var i = index; i < count(); i++) {\n if (!isOptionDisabled(state.options[i])) return i;\n }\n\n for (var _i = index - 1; _i >= 0; _i--) {\n if (!isOptionDisabled(state.options[_i])) return _i;\n }\n };\n\n var setIndex = (index, emitChange) => {\n index = adjustIndex(index) || 0;\n var offset = -index * props.itemHeight;\n\n var trigger = () => {\n if (index !== state.index) {\n state.index = index;\n\n if (emitChange) {\n emit('change', index);\n }\n }\n }; // trigger the change event after transitionend when moving\n\n\n if (moving && offset !== state.offset) {\n transitionEndTrigger = trigger;\n } else {\n trigger();\n }\n\n state.offset = offset;\n };\n\n var setOptions = options => {\n if (JSON.stringify(options) !== JSON.stringify(state.options)) {\n state.options = deepClone(options);\n setIndex(props.defaultIndex);\n }\n };\n\n var onClickItem = index => {\n if (moving || props.readonly) {\n return;\n }\n\n transitionEndTrigger = null;\n state.duration = DEFAULT_DURATION;\n setIndex(index, true);\n };\n\n var getOptionText = option => {\n if (isObject(option) && props.textKey in option) {\n return option[props.textKey];\n }\n\n return option;\n };\n\n var getIndexByOffset = offset => clamp(Math.round(-offset / props.itemHeight), 0, count() - 1);\n\n var momentum = (distance, duration) => {\n var speed = Math.abs(distance / duration);\n distance = state.offset + speed / 0.003 * (distance < 0 ? -1 : 1);\n var index = getIndexByOffset(distance);\n state.duration = +props.swipeDuration;\n setIndex(index, true);\n };\n\n var stopMomentum = () => {\n moving = false;\n state.duration = 0;\n\n if (transitionEndTrigger) {\n transitionEndTrigger();\n transitionEndTrigger = null;\n }\n };\n\n var onTouchStart = event => {\n if (props.readonly) {\n return;\n }\n\n touch.start(event);\n\n if (moving) {\n var translateY = getElementTranslateY(wrapper.value);\n state.offset = Math.min(0, translateY - baseOffset());\n startOffset = state.offset;\n } else {\n startOffset = state.offset;\n }\n\n state.duration = 0;\n touchStartTime = Date.now();\n momentumOffset = startOffset;\n transitionEndTrigger = null;\n };\n\n var onTouchMove = event => {\n if (props.readonly) {\n return;\n }\n\n touch.move(event);\n\n if (touch.isVertical()) {\n moving = true;\n preventDefault(event, true);\n }\n\n state.offset = clamp(startOffset + touch.deltaY.value, -(count() * props.itemHeight), props.itemHeight);\n var now = Date.now();\n\n if (now - touchStartTime > MOMENTUM_LIMIT_TIME) {\n touchStartTime = now;\n momentumOffset = state.offset;\n }\n };\n\n var onTouchEnd = () => {\n if (props.readonly) {\n return;\n }\n\n var distance = state.offset - momentumOffset;\n var duration = Date.now() - touchStartTime;\n var allowMomentum = duration < MOMENTUM_LIMIT_TIME && Math.abs(distance) > MOMENTUM_LIMIT_DISTANCE;\n\n if (allowMomentum) {\n momentum(distance, duration);\n return;\n }\n\n var index = getIndexByOffset(state.offset);\n state.duration = DEFAULT_DURATION;\n setIndex(index, true); // compatible with desktop scenario\n // use setTimeout to skip the click event Emitted after touchstart\n\n setTimeout(() => {\n moving = false;\n }, 0);\n };\n\n var renderOptions = () => {\n var optionStyle = {\n height: props.itemHeight + \"px\"\n };\n return state.options.map((option, index) => {\n var text = getOptionText(option);\n var disabled = isOptionDisabled(option);\n var data = {\n role: 'button',\n style: optionStyle,\n tabindex: disabled ? -1 : 0,\n class: bem('item', {\n disabled,\n selected: index === state.index\n }),\n onClick: () => onClickItem(index)\n };\n var childData = {\n class: 'van-ellipsis',\n [props.allowHtml ? 'innerHTML' : 'textContent']: text\n };\n return _createVNode(\"li\", data, [slots.option ? slots.option(option) : _createVNode(\"div\", childData, null)]);\n });\n };\n\n var setValue = value => {\n var {\n options\n } = state;\n\n for (var i = 0; i < options.length; i++) {\n if (getOptionText(options[i]) === value) {\n return setIndex(i);\n }\n }\n };\n\n var getValue = () => state.options[state.index];\n\n setIndex(state.index);\n useParent(PICKER_KEY);\n useExpose({\n state,\n setIndex,\n getValue,\n setValue,\n setOptions,\n stopMomentum\n });\n watch(() => props.initialOptions, setOptions);\n watch(() => props.defaultIndex, value => setIndex(value));\n return () => _createVNode(\"div\", {\n \"class\": [bem(), props.className],\n \"onTouchstart\": onTouchStart,\n \"onTouchmove\": onTouchMove,\n \"onTouchend\": onTouchEnd,\n \"onTouchcancel\": onTouchEnd\n }, [_createVNode(\"ul\", {\n \"ref\": wrapper,\n \"style\": {\n transform: \"translate3d(0, \" + (state.offset + baseOffset()) + \"px, 0)\",\n transitionDuration: state.duration + \"ms\",\n transitionProperty: state.duration ? 'all' : 'none'\n },\n \"class\": bem('wrapper'),\n \"onTransitionend\": stopMomentum\n }, [renderOptions()])]);\n }\n\n});","import { resolveDirective as _resolveDirective, createVNode as _createVNode } from \"vue\";\nimport { ref, watch, computed, defineComponent } from 'vue'; // Utils\n\nimport { extend, unitToPx, truthProp, makeArrayProp, preventDefault, makeStringProp, makeNumericProp, createNamespace, HAPTICS_FEEDBACK, BORDER_UNSET_TOP_BOTTOM } from '../utils'; // Composables\n\nimport { useChildren } from '@vant/use';\nimport { useExpose } from '../composables/use-expose'; // Components\n\nimport { Loading } from '../loading';\nimport Column, { PICKER_KEY } from './PickerColumn'; // Types\n\nvar [name, bem, t] = createNamespace('picker');\nexport var pickerSharedProps = {\n title: String,\n loading: Boolean,\n readonly: Boolean,\n allowHtml: Boolean,\n itemHeight: makeNumericProp(44),\n showToolbar: truthProp,\n swipeDuration: makeNumericProp(1000),\n visibleItemCount: makeNumericProp(6),\n cancelButtonText: String,\n confirmButtonText: String\n};\nvar pickerProps = extend({}, pickerSharedProps, {\n columns: makeArrayProp(),\n // @deprecated\n // should be removed in next major version\n valueKey: String,\n defaultIndex: makeNumericProp(0),\n toolbarPosition: makeStringProp('top'),\n columnsFieldNames: Object\n});\nexport default defineComponent({\n name,\n props: pickerProps,\n emits: ['confirm', 'cancel', 'change'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n\n if (process.env.NODE_ENV !== 'production') {\n if (slots.default) {\n console.warn('[Vant] Picker: \"default\" slot is deprecated, please use \"toolbar\" slot instead.');\n }\n\n if (props.valueKey) {\n console.warn('[Vant] Picker: \"valueKey\" prop is deprecated, please use \"columnsFieldNames\" prop instead.');\n }\n }\n\n var formattedColumns = ref([]);\n var {\n text: textKey,\n values: valuesKey,\n children: childrenKey\n } = extend({\n // compatible with valueKey prop\n text: props.valueKey || 'text',\n values: 'values',\n children: 'children'\n }, props.columnsFieldNames);\n var {\n children,\n linkChildren\n } = useChildren(PICKER_KEY);\n linkChildren();\n var itemHeight = computed(() => unitToPx(props.itemHeight));\n var dataType = computed(() => {\n var firstColumn = props.columns[0];\n\n if (typeof firstColumn === 'object') {\n if (childrenKey in firstColumn) {\n return 'cascade';\n }\n\n if (valuesKey in firstColumn) {\n return 'object';\n }\n }\n\n return 'plain';\n });\n\n var formatCascade = () => {\n var formatted = [];\n var cursor = {\n [childrenKey]: props.columns\n };\n\n while (cursor && cursor[childrenKey]) {\n var _cursor$defaultIndex;\n\n var _children = cursor[childrenKey];\n var defaultIndex = (_cursor$defaultIndex = cursor.defaultIndex) != null ? _cursor$defaultIndex : +props.defaultIndex;\n\n while (_children[defaultIndex] && _children[defaultIndex].disabled) {\n if (defaultIndex < _children.length - 1) {\n defaultIndex++;\n } else {\n defaultIndex = 0;\n break;\n }\n }\n\n formatted.push({\n [valuesKey]: cursor[childrenKey],\n className: cursor.className,\n defaultIndex\n });\n cursor = _children[defaultIndex];\n }\n\n formattedColumns.value = formatted;\n };\n\n var format = () => {\n var {\n columns\n } = props;\n\n if (dataType.value === 'plain') {\n formattedColumns.value = [{\n [valuesKey]: columns\n }];\n } else if (dataType.value === 'cascade') {\n formatCascade();\n } else {\n formattedColumns.value = columns;\n }\n }; // get indexes of all columns\n\n\n var getIndexes = () => children.map(child => child.state.index); // set options of column by index\n\n\n var setColumnValues = (index, options) => {\n var column = children[index];\n\n if (column) {\n column.setOptions(options);\n }\n };\n\n var onCascadeChange = columnIndex => {\n var cursor = {\n [childrenKey]: props.columns\n };\n var indexes = getIndexes();\n\n for (var i = 0; i <= columnIndex; i++) {\n cursor = cursor[childrenKey][indexes[i]];\n }\n\n while (cursor && cursor[childrenKey]) {\n columnIndex++;\n setColumnValues(columnIndex, cursor[childrenKey]);\n cursor = cursor[childrenKey][cursor.defaultIndex || 0];\n }\n }; // get column instance by index\n\n\n var getChild = index => children[index]; // get column value by index\n\n\n var getColumnValue = index => {\n var column = getChild(index);\n\n if (column) {\n return column.getValue();\n }\n }; // set column value by index\n\n\n var setColumnValue = (index, value) => {\n var column = getChild(index);\n\n if (column) {\n column.setValue(value);\n\n if (dataType.value === 'cascade') {\n onCascadeChange(index);\n }\n }\n }; // get column option index by column index\n\n\n var getColumnIndex = index => {\n var column = getChild(index);\n\n if (column) {\n return column.state.index;\n }\n }; // set column option index by column index\n\n\n var setColumnIndex = (columnIndex, optionIndex) => {\n var column = getChild(columnIndex);\n\n if (column) {\n column.setIndex(optionIndex);\n\n if (dataType.value === 'cascade') {\n onCascadeChange(columnIndex);\n }\n }\n }; // get options of column by index\n\n\n var getColumnValues = index => {\n var column = getChild(index);\n\n if (column) {\n return column.state.options;\n }\n }; // get values of all columns\n\n\n var getValues = () => children.map(child => child.getValue()); // set values of all columns\n\n\n var setValues = values => {\n values.forEach((value, index) => {\n setColumnValue(index, value);\n });\n }; // set indexes of all columns\n\n\n var setIndexes = indexes => {\n indexes.forEach((optionIndex, columnIndex) => {\n setColumnIndex(columnIndex, optionIndex);\n });\n };\n\n var emitAction = event => {\n if (dataType.value === 'plain') {\n emit(event, getColumnValue(0), getColumnIndex(0));\n } else {\n emit(event, getValues(), getIndexes());\n }\n };\n\n var onChange = columnIndex => {\n if (dataType.value === 'cascade') {\n onCascadeChange(columnIndex);\n }\n\n if (dataType.value === 'plain') {\n emit('change', getColumnValue(0), getColumnIndex(0));\n } else {\n emit('change', getValues(), columnIndex);\n }\n };\n\n var confirm = () => {\n children.forEach(child => child.stopMomentum());\n emitAction('confirm');\n };\n\n var cancel = () => emitAction('cancel');\n\n var renderTitle = () => {\n if (slots.title) {\n return slots.title();\n }\n\n if (props.title) {\n return _createVNode(\"div\", {\n \"class\": [bem('title'), 'van-ellipsis']\n }, [props.title]);\n }\n };\n\n var renderCancel = () => {\n var text = props.cancelButtonText || t('cancel');\n return _createVNode(\"button\", {\n \"type\": \"button\",\n \"class\": [bem('cancel'), HAPTICS_FEEDBACK],\n \"onClick\": cancel\n }, [slots.cancel ? slots.cancel() : text]);\n };\n\n var renderConfirm = () => {\n var text = props.confirmButtonText || t('confirm');\n return _createVNode(\"button\", {\n \"type\": \"button\",\n \"class\": [bem('confirm'), HAPTICS_FEEDBACK],\n \"onClick\": confirm\n }, [slots.confirm ? slots.confirm() : text]);\n };\n\n var renderToolbar = () => {\n if (props.showToolbar) {\n // default slot is deprecated\n // should be removed in next major version\n var slot = slots.toolbar || slots.default;\n return _createVNode(\"div\", {\n \"class\": bem('toolbar')\n }, [slot ? slot() : [renderCancel(), renderTitle(), renderConfirm()]]);\n }\n };\n\n var renderColumnItems = () => formattedColumns.value.map((item, columnIndex) => {\n var _item$defaultIndex;\n\n return _createVNode(Column, {\n \"textKey\": textKey,\n \"readonly\": props.readonly,\n \"allowHtml\": props.allowHtml,\n \"className\": item.className,\n \"itemHeight\": itemHeight.value,\n \"defaultIndex\": (_item$defaultIndex = item.defaultIndex) != null ? _item$defaultIndex : +props.defaultIndex,\n \"swipeDuration\": props.swipeDuration,\n \"initialOptions\": item[valuesKey],\n \"visibleItemCount\": props.visibleItemCount,\n \"onChange\": () => onChange(columnIndex)\n }, {\n option: slots.option\n });\n });\n\n var renderColumns = () => {\n var wrapHeight = itemHeight.value * +props.visibleItemCount;\n var frameStyle = {\n height: itemHeight.value + \"px\"\n };\n var columnsStyle = {\n height: wrapHeight + \"px\"\n };\n var maskStyle = {\n backgroundSize: \"100% \" + (wrapHeight - itemHeight.value) / 2 + \"px\"\n };\n return _createVNode(\"div\", {\n \"class\": bem('columns'),\n \"style\": columnsStyle,\n \"onTouchmove\": preventDefault\n }, [renderColumnItems(), _createVNode(\"div\", {\n \"class\": bem('mask'),\n \"style\": maskStyle\n }, null), _createVNode(\"div\", {\n \"class\": [BORDER_UNSET_TOP_BOTTOM, bem('frame')],\n \"style\": frameStyle\n }, null)]);\n };\n\n watch(() => props.columns, format, {\n immediate: true\n });\n useExpose({\n confirm,\n getValues,\n setValues,\n getIndexes,\n setIndexes,\n getColumnIndex,\n setColumnIndex,\n getColumnValue,\n setColumnValue,\n getColumnValues,\n setColumnValues\n });\n return () => {\n var _slots$columnsTop, _slots$columnsBottom;\n\n return _createVNode(\"div\", {\n \"class\": bem()\n }, [props.toolbarPosition === 'top' ? renderToolbar() : null, props.loading ? _createVNode(Loading, {\n \"class\": bem('loading')\n }, null) : null, (_slots$columnsTop = slots['columns-top']) == null ? void 0 : _slots$columnsTop.call(slots), renderColumns(), (_slots$columnsBottom = slots['columns-bottom']) == null ? void 0 : _slots$columnsBottom.call(slots), props.toolbarPosition === 'bottom' ? renderToolbar() : null]);\n };\n }\n\n});","import { withInstall } from '../utils';\nimport _Picker from './Picker';\nexport var Picker = withInstall(_Picker);\nexport default Picker;","import { extend, isArray, isMap, isIntegerKey, isSymbol, hasOwn, isObject, hasChanged, makeMap, capitalize, toRawType, def, isFunction, NOOP } from '@vue/shared';\n\nfunction warn(msg, ...args) {\r\n console.warn(`[Vue warn] ${msg}`, ...args);\r\n}\n\nlet activeEffectScope;\r\nconst effectScopeStack = [];\r\nclass EffectScope {\r\n constructor(detached = false) {\r\n this.active = true;\r\n this.effects = [];\r\n this.cleanups = [];\r\n if (!detached && activeEffectScope) {\r\n this.parent = activeEffectScope;\r\n this.index =\r\n (activeEffectScope.scopes || (activeEffectScope.scopes = [])).push(this) - 1;\r\n }\r\n }\r\n run(fn) {\r\n if (this.active) {\r\n try {\r\n this.on();\r\n return fn();\r\n }\r\n finally {\r\n this.off();\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`cannot run an inactive effect scope.`);\r\n }\r\n }\r\n on() {\r\n if (this.active) {\r\n effectScopeStack.push(this);\r\n activeEffectScope = this;\r\n }\r\n }\r\n off() {\r\n if (this.active) {\r\n effectScopeStack.pop();\r\n activeEffectScope = effectScopeStack[effectScopeStack.length - 1];\r\n }\r\n }\r\n stop(fromParent) {\r\n if (this.active) {\r\n this.effects.forEach(e => e.stop());\r\n this.cleanups.forEach(cleanup => cleanup());\r\n if (this.scopes) {\r\n this.scopes.forEach(e => e.stop(true));\r\n }\r\n // nested scope, dereference from parent to avoid memory leaks\r\n if (this.parent && !fromParent) {\r\n // optimized O(1) removal\r\n const last = this.parent.scopes.pop();\r\n if (last && last !== this) {\r\n this.parent.scopes[this.index] = last;\r\n last.index = this.index;\r\n }\r\n }\r\n this.active = false;\r\n }\r\n }\r\n}\r\nfunction effectScope(detached) {\r\n return new EffectScope(detached);\r\n}\r\nfunction recordEffectScope(effect, scope) {\r\n scope = scope || activeEffectScope;\r\n if (scope && scope.active) {\r\n scope.effects.push(effect);\r\n }\r\n}\r\nfunction getCurrentScope() {\r\n return activeEffectScope;\r\n}\r\nfunction onScopeDispose(fn) {\r\n if (activeEffectScope) {\r\n activeEffectScope.cleanups.push(fn);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`onScopeDispose() is called when there is no active effect scope` +\r\n ` to be associated with.`);\r\n }\r\n}\n\nconst createDep = (effects) => {\r\n const dep = new Set(effects);\r\n dep.w = 0;\r\n dep.n = 0;\r\n return dep;\r\n};\r\nconst wasTracked = (dep) => (dep.w & trackOpBit) > 0;\r\nconst newTracked = (dep) => (dep.n & trackOpBit) > 0;\r\nconst initDepMarkers = ({ deps }) => {\r\n if (deps.length) {\r\n for (let i = 0; i < deps.length; i++) {\r\n deps[i].w |= trackOpBit; // set was tracked\r\n }\r\n }\r\n};\r\nconst finalizeDepMarkers = (effect) => {\r\n const { deps } = effect;\r\n if (deps.length) {\r\n let ptr = 0;\r\n for (let i = 0; i < deps.length; i++) {\r\n const dep = deps[i];\r\n if (wasTracked(dep) && !newTracked(dep)) {\r\n dep.delete(effect);\r\n }\r\n else {\r\n deps[ptr++] = dep;\r\n }\r\n // clear bits\r\n dep.w &= ~trackOpBit;\r\n dep.n &= ~trackOpBit;\r\n }\r\n deps.length = ptr;\r\n }\r\n};\n\nconst targetMap = new WeakMap();\r\n// The number of effects currently being tracked recursively.\r\nlet effectTrackDepth = 0;\r\nlet trackOpBit = 1;\r\n/**\r\n * The bitwise track markers support at most 30 levels of recursion.\r\n * This value is chosen to enable modern JS engines to use a SMI on all platforms.\r\n * When recursion depth is greater, fall back to using a full cleanup.\r\n */\r\nconst maxMarkerBits = 30;\r\nconst effectStack = [];\r\nlet activeEffect;\r\nconst ITERATE_KEY = Symbol((process.env.NODE_ENV !== 'production') ? 'iterate' : '');\r\nconst MAP_KEY_ITERATE_KEY = Symbol((process.env.NODE_ENV !== 'production') ? 'Map key iterate' : '');\r\nclass ReactiveEffect {\r\n constructor(fn, scheduler = null, scope) {\r\n this.fn = fn;\r\n this.scheduler = scheduler;\r\n this.active = true;\r\n this.deps = [];\r\n recordEffectScope(this, scope);\r\n }\r\n run() {\r\n if (!this.active) {\r\n return this.fn();\r\n }\r\n if (!effectStack.includes(this)) {\r\n try {\r\n effectStack.push((activeEffect = this));\r\n enableTracking();\r\n trackOpBit = 1 << ++effectTrackDepth;\r\n if (effectTrackDepth <= maxMarkerBits) {\r\n initDepMarkers(this);\r\n }\r\n else {\r\n cleanupEffect(this);\r\n }\r\n return this.fn();\r\n }\r\n finally {\r\n if (effectTrackDepth <= maxMarkerBits) {\r\n finalizeDepMarkers(this);\r\n }\r\n trackOpBit = 1 << --effectTrackDepth;\r\n resetTracking();\r\n effectStack.pop();\r\n const n = effectStack.length;\r\n activeEffect = n > 0 ? effectStack[n - 1] : undefined;\r\n }\r\n }\r\n }\r\n stop() {\r\n if (this.active) {\r\n cleanupEffect(this);\r\n if (this.onStop) {\r\n this.onStop();\r\n }\r\n this.active = false;\r\n }\r\n }\r\n}\r\nfunction cleanupEffect(effect) {\r\n const { deps } = effect;\r\n if (deps.length) {\r\n for (let i = 0; i < deps.length; i++) {\r\n deps[i].delete(effect);\r\n }\r\n deps.length = 0;\r\n }\r\n}\r\nfunction effect(fn, options) {\r\n if (fn.effect) {\r\n fn = fn.effect.fn;\r\n }\r\n const _effect = new ReactiveEffect(fn);\r\n if (options) {\r\n extend(_effect, options);\r\n if (options.scope)\r\n recordEffectScope(_effect, options.scope);\r\n }\r\n if (!options || !options.lazy) {\r\n _effect.run();\r\n }\r\n const runner = _effect.run.bind(_effect);\r\n runner.effect = _effect;\r\n return runner;\r\n}\r\nfunction stop(runner) {\r\n runner.effect.stop();\r\n}\r\nlet shouldTrack = true;\r\nconst trackStack = [];\r\nfunction pauseTracking() {\r\n trackStack.push(shouldTrack);\r\n shouldTrack = false;\r\n}\r\nfunction enableTracking() {\r\n trackStack.push(shouldTrack);\r\n shouldTrack = true;\r\n}\r\nfunction resetTracking() {\r\n const last = trackStack.pop();\r\n shouldTrack = last === undefined ? true : last;\r\n}\r\nfunction track(target, type, key) {\r\n if (!isTracking()) {\r\n return;\r\n }\r\n let depsMap = targetMap.get(target);\r\n if (!depsMap) {\r\n targetMap.set(target, (depsMap = new Map()));\r\n }\r\n let dep = depsMap.get(key);\r\n if (!dep) {\r\n depsMap.set(key, (dep = createDep()));\r\n }\r\n const eventInfo = (process.env.NODE_ENV !== 'production')\r\n ? { effect: activeEffect, target, type, key }\r\n : undefined;\r\n trackEffects(dep, eventInfo);\r\n}\r\nfunction isTracking() {\r\n return shouldTrack && activeEffect !== undefined;\r\n}\r\nfunction trackEffects(dep, debuggerEventExtraInfo) {\r\n let shouldTrack = false;\r\n if (effectTrackDepth <= maxMarkerBits) {\r\n if (!newTracked(dep)) {\r\n dep.n |= trackOpBit; // set newly tracked\r\n shouldTrack = !wasTracked(dep);\r\n }\r\n }\r\n else {\r\n // Full cleanup mode.\r\n shouldTrack = !dep.has(activeEffect);\r\n }\r\n if (shouldTrack) {\r\n dep.add(activeEffect);\r\n activeEffect.deps.push(dep);\r\n if ((process.env.NODE_ENV !== 'production') && activeEffect.onTrack) {\r\n activeEffect.onTrack(Object.assign({\r\n effect: activeEffect\r\n }, debuggerEventExtraInfo));\r\n }\r\n }\r\n}\r\nfunction trigger(target, type, key, newValue, oldValue, oldTarget) {\r\n const depsMap = targetMap.get(target);\r\n if (!depsMap) {\r\n // never been tracked\r\n return;\r\n }\r\n let deps = [];\r\n if (type === \"clear\" /* CLEAR */) {\r\n // collection being cleared\r\n // trigger all effects for target\r\n deps = [...depsMap.values()];\r\n }\r\n else if (key === 'length' && isArray(target)) {\r\n depsMap.forEach((dep, key) => {\r\n if (key === 'length' || key >= newValue) {\r\n deps.push(dep);\r\n }\r\n });\r\n }\r\n else {\r\n // schedule runs for SET | ADD | DELETE\r\n if (key !== void 0) {\r\n deps.push(depsMap.get(key));\r\n }\r\n // also run for iteration key on ADD | DELETE | Map.SET\r\n switch (type) {\r\n case \"add\" /* ADD */:\r\n if (!isArray(target)) {\r\n deps.push(depsMap.get(ITERATE_KEY));\r\n if (isMap(target)) {\r\n deps.push(depsMap.get(MAP_KEY_ITERATE_KEY));\r\n }\r\n }\r\n else if (isIntegerKey(key)) {\r\n // new index added to array -> length changes\r\n deps.push(depsMap.get('length'));\r\n }\r\n break;\r\n case \"delete\" /* DELETE */:\r\n if (!isArray(target)) {\r\n deps.push(depsMap.get(ITERATE_KEY));\r\n if (isMap(target)) {\r\n deps.push(depsMap.get(MAP_KEY_ITERATE_KEY));\r\n }\r\n }\r\n break;\r\n case \"set\" /* SET */:\r\n if (isMap(target)) {\r\n deps.push(depsMap.get(ITERATE_KEY));\r\n }\r\n break;\r\n }\r\n }\r\n const eventInfo = (process.env.NODE_ENV !== 'production')\r\n ? { target, type, key, newValue, oldValue, oldTarget }\r\n : undefined;\r\n if (deps.length === 1) {\r\n if (deps[0]) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n triggerEffects(deps[0], eventInfo);\r\n }\r\n else {\r\n triggerEffects(deps[0]);\r\n }\r\n }\r\n }\r\n else {\r\n const effects = [];\r\n for (const dep of deps) {\r\n if (dep) {\r\n effects.push(...dep);\r\n }\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n triggerEffects(createDep(effects), eventInfo);\r\n }\r\n else {\r\n triggerEffects(createDep(effects));\r\n }\r\n }\r\n}\r\nfunction triggerEffects(dep, debuggerEventExtraInfo) {\r\n // spread into array for stabilization\r\n for (const effect of isArray(dep) ? dep : [...dep]) {\r\n if (effect !== activeEffect || effect.allowRecurse) {\r\n if ((process.env.NODE_ENV !== 'production') && effect.onTrigger) {\r\n effect.onTrigger(extend({ effect }, debuggerEventExtraInfo));\r\n }\r\n if (effect.scheduler) {\r\n effect.scheduler();\r\n }\r\n else {\r\n effect.run();\r\n }\r\n }\r\n }\r\n}\n\nconst isNonTrackableKeys = /*#__PURE__*/ makeMap(`__proto__,__v_isRef,__isVue`);\r\nconst builtInSymbols = new Set(Object.getOwnPropertyNames(Symbol)\r\n .map(key => Symbol[key])\r\n .filter(isSymbol));\r\nconst get = /*#__PURE__*/ createGetter();\r\nconst shallowGet = /*#__PURE__*/ createGetter(false, true);\r\nconst readonlyGet = /*#__PURE__*/ createGetter(true);\r\nconst shallowReadonlyGet = /*#__PURE__*/ createGetter(true, true);\r\nconst arrayInstrumentations = /*#__PURE__*/ createArrayInstrumentations();\r\nfunction createArrayInstrumentations() {\r\n const instrumentations = {};\r\n ['includes', 'indexOf', 'lastIndexOf'].forEach(key => {\r\n instrumentations[key] = function (...args) {\r\n const arr = toRaw(this);\r\n for (let i = 0, l = this.length; i < l; i++) {\r\n track(arr, \"get\" /* GET */, i + '');\r\n }\r\n // we run the method using the original args first (which may be reactive)\r\n const res = arr[key](...args);\r\n if (res === -1 || res === false) {\r\n // if that didn't work, run it again using raw values.\r\n return arr[key](...args.map(toRaw));\r\n }\r\n else {\r\n return res;\r\n }\r\n };\r\n });\r\n ['push', 'pop', 'shift', 'unshift', 'splice'].forEach(key => {\r\n instrumentations[key] = function (...args) {\r\n pauseTracking();\r\n const res = toRaw(this)[key].apply(this, args);\r\n resetTracking();\r\n return res;\r\n };\r\n });\r\n return instrumentations;\r\n}\r\nfunction createGetter(isReadonly = false, shallow = false) {\r\n return function get(target, key, receiver) {\r\n if (key === \"__v_isReactive\" /* IS_REACTIVE */) {\r\n return !isReadonly;\r\n }\r\n else if (key === \"__v_isReadonly\" /* IS_READONLY */) {\r\n return isReadonly;\r\n }\r\n else if (key === \"__v_raw\" /* RAW */ &&\r\n receiver ===\r\n (isReadonly\r\n ? shallow\r\n ? shallowReadonlyMap\r\n : readonlyMap\r\n : shallow\r\n ? shallowReactiveMap\r\n : reactiveMap).get(target)) {\r\n return target;\r\n }\r\n const targetIsArray = isArray(target);\r\n if (!isReadonly && targetIsArray && hasOwn(arrayInstrumentations, key)) {\r\n return Reflect.get(arrayInstrumentations, key, receiver);\r\n }\r\n const res = Reflect.get(target, key, receiver);\r\n if (isSymbol(key) ? builtInSymbols.has(key) : isNonTrackableKeys(key)) {\r\n return res;\r\n }\r\n if (!isReadonly) {\r\n track(target, \"get\" /* GET */, key);\r\n }\r\n if (shallow) {\r\n return res;\r\n }\r\n if (isRef(res)) {\r\n // ref unwrapping - does not apply for Array + integer key.\r\n const shouldUnwrap = !targetIsArray || !isIntegerKey(key);\r\n return shouldUnwrap ? res.value : res;\r\n }\r\n if (isObject(res)) {\r\n // Convert returned value into a proxy as well. we do the isObject check\r\n // here to avoid invalid value warning. Also need to lazy access readonly\r\n // and reactive here to avoid circular dependency.\r\n return isReadonly ? readonly(res) : reactive(res);\r\n }\r\n return res;\r\n };\r\n}\r\nconst set = /*#__PURE__*/ createSetter();\r\nconst shallowSet = /*#__PURE__*/ createSetter(true);\r\nfunction createSetter(shallow = false) {\r\n return function set(target, key, value, receiver) {\r\n let oldValue = target[key];\r\n if (!shallow && !isReadonly(value)) {\r\n value = toRaw(value);\r\n oldValue = toRaw(oldValue);\r\n if (!isArray(target) && isRef(oldValue) && !isRef(value)) {\r\n oldValue.value = value;\r\n return true;\r\n }\r\n }\r\n const hadKey = isArray(target) && isIntegerKey(key)\r\n ? Number(key) < target.length\r\n : hasOwn(target, key);\r\n const result = Reflect.set(target, key, value, receiver);\r\n // don't trigger if target is something up in the prototype chain of original\r\n if (target === toRaw(receiver)) {\r\n if (!hadKey) {\r\n trigger(target, \"add\" /* ADD */, key, value);\r\n }\r\n else if (hasChanged(value, oldValue)) {\r\n trigger(target, \"set\" /* SET */, key, value, oldValue);\r\n }\r\n }\r\n return result;\r\n };\r\n}\r\nfunction deleteProperty(target, key) {\r\n const hadKey = hasOwn(target, key);\r\n const oldValue = target[key];\r\n const result = Reflect.deleteProperty(target, key);\r\n if (result && hadKey) {\r\n trigger(target, \"delete\" /* DELETE */, key, undefined, oldValue);\r\n }\r\n return result;\r\n}\r\nfunction has(target, key) {\r\n const result = Reflect.has(target, key);\r\n if (!isSymbol(key) || !builtInSymbols.has(key)) {\r\n track(target, \"has\" /* HAS */, key);\r\n }\r\n return result;\r\n}\r\nfunction ownKeys(target) {\r\n track(target, \"iterate\" /* ITERATE */, isArray(target) ? 'length' : ITERATE_KEY);\r\n return Reflect.ownKeys(target);\r\n}\r\nconst mutableHandlers = {\r\n get,\r\n set,\r\n deleteProperty,\r\n has,\r\n ownKeys\r\n};\r\nconst readonlyHandlers = {\r\n get: readonlyGet,\r\n set(target, key) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n console.warn(`Set operation on key \"${String(key)}\" failed: target is readonly.`, target);\r\n }\r\n return true;\r\n },\r\n deleteProperty(target, key) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n console.warn(`Delete operation on key \"${String(key)}\" failed: target is readonly.`, target);\r\n }\r\n return true;\r\n }\r\n};\r\nconst shallowReactiveHandlers = /*#__PURE__*/ extend({}, mutableHandlers, {\r\n get: shallowGet,\r\n set: shallowSet\r\n});\r\n// Props handlers are special in the sense that it should not unwrap top-level\r\n// refs (in order to allow refs to be explicitly passed down), but should\r\n// retain the reactivity of the normal readonly object.\r\nconst shallowReadonlyHandlers = /*#__PURE__*/ extend({}, readonlyHandlers, {\r\n get: shallowReadonlyGet\r\n});\n\nconst toShallow = (value) => value;\r\nconst getProto = (v) => Reflect.getPrototypeOf(v);\r\nfunction get$1(target, key, isReadonly = false, isShallow = false) {\r\n // #1772: readonly(reactive(Map)) should return readonly + reactive version\r\n // of the value\r\n target = target[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const rawKey = toRaw(key);\r\n if (key !== rawKey) {\r\n !isReadonly && track(rawTarget, \"get\" /* GET */, key);\r\n }\r\n !isReadonly && track(rawTarget, \"get\" /* GET */, rawKey);\r\n const { has } = getProto(rawTarget);\r\n const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n if (has.call(rawTarget, key)) {\r\n return wrap(target.get(key));\r\n }\r\n else if (has.call(rawTarget, rawKey)) {\r\n return wrap(target.get(rawKey));\r\n }\r\n else if (target !== rawTarget) {\r\n // #3602 readonly(reactive(Map))\r\n // ensure that the nested reactive `Map` can do tracking for itself\r\n target.get(key);\r\n }\r\n}\r\nfunction has$1(key, isReadonly = false) {\r\n const target = this[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const rawKey = toRaw(key);\r\n if (key !== rawKey) {\r\n !isReadonly && track(rawTarget, \"has\" /* HAS */, key);\r\n }\r\n !isReadonly && track(rawTarget, \"has\" /* HAS */, rawKey);\r\n return key === rawKey\r\n ? target.has(key)\r\n : target.has(key) || target.has(rawKey);\r\n}\r\nfunction size(target, isReadonly = false) {\r\n target = target[\"__v_raw\" /* RAW */];\r\n !isReadonly && track(toRaw(target), \"iterate\" /* ITERATE */, ITERATE_KEY);\r\n return Reflect.get(target, 'size', target);\r\n}\r\nfunction add(value) {\r\n value = toRaw(value);\r\n const target = toRaw(this);\r\n const proto = getProto(target);\r\n const hadKey = proto.has.call(target, value);\r\n if (!hadKey) {\r\n target.add(value);\r\n trigger(target, \"add\" /* ADD */, value, value);\r\n }\r\n return this;\r\n}\r\nfunction set$1(key, value) {\r\n value = toRaw(value);\r\n const target = toRaw(this);\r\n const { has, get } = getProto(target);\r\n let hadKey = has.call(target, key);\r\n if (!hadKey) {\r\n key = toRaw(key);\r\n hadKey = has.call(target, key);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n checkIdentityKeys(target, has, key);\r\n }\r\n const oldValue = get.call(target, key);\r\n target.set(key, value);\r\n if (!hadKey) {\r\n trigger(target, \"add\" /* ADD */, key, value);\r\n }\r\n else if (hasChanged(value, oldValue)) {\r\n trigger(target, \"set\" /* SET */, key, value, oldValue);\r\n }\r\n return this;\r\n}\r\nfunction deleteEntry(key) {\r\n const target = toRaw(this);\r\n const { has, get } = getProto(target);\r\n let hadKey = has.call(target, key);\r\n if (!hadKey) {\r\n key = toRaw(key);\r\n hadKey = has.call(target, key);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n checkIdentityKeys(target, has, key);\r\n }\r\n const oldValue = get ? get.call(target, key) : undefined;\r\n // forward the operation before queueing reactions\r\n const result = target.delete(key);\r\n if (hadKey) {\r\n trigger(target, \"delete\" /* DELETE */, key, undefined, oldValue);\r\n }\r\n return result;\r\n}\r\nfunction clear() {\r\n const target = toRaw(this);\r\n const hadItems = target.size !== 0;\r\n const oldTarget = (process.env.NODE_ENV !== 'production')\r\n ? isMap(target)\r\n ? new Map(target)\r\n : new Set(target)\r\n : undefined;\r\n // forward the operation before queueing reactions\r\n const result = target.clear();\r\n if (hadItems) {\r\n trigger(target, \"clear\" /* CLEAR */, undefined, undefined, oldTarget);\r\n }\r\n return result;\r\n}\r\nfunction createForEach(isReadonly, isShallow) {\r\n return function forEach(callback, thisArg) {\r\n const observed = this;\r\n const target = observed[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n !isReadonly && track(rawTarget, \"iterate\" /* ITERATE */, ITERATE_KEY);\r\n return target.forEach((value, key) => {\r\n // important: make sure the callback is\r\n // 1. invoked with the reactive map as `this` and 3rd arg\r\n // 2. the value received should be a corresponding reactive/readonly.\r\n return callback.call(thisArg, wrap(value), wrap(key), observed);\r\n });\r\n };\r\n}\r\nfunction createIterableMethod(method, isReadonly, isShallow) {\r\n return function (...args) {\r\n const target = this[\"__v_raw\" /* RAW */];\r\n const rawTarget = toRaw(target);\r\n const targetIsMap = isMap(rawTarget);\r\n const isPair = method === 'entries' || (method === Symbol.iterator && targetIsMap);\r\n const isKeyOnly = method === 'keys' && targetIsMap;\r\n const innerIterator = target[method](...args);\r\n const wrap = isShallow ? toShallow : isReadonly ? toReadonly : toReactive;\r\n !isReadonly &&\r\n track(rawTarget, \"iterate\" /* ITERATE */, isKeyOnly ? MAP_KEY_ITERATE_KEY : ITERATE_KEY);\r\n // return a wrapped iterator which returns observed versions of the\r\n // values emitted from the real iterator\r\n return {\r\n // iterator protocol\r\n next() {\r\n const { value, done } = innerIterator.next();\r\n return done\r\n ? { value, done }\r\n : {\r\n value: isPair ? [wrap(value[0]), wrap(value[1])] : wrap(value),\r\n done\r\n };\r\n },\r\n // iterable protocol\r\n [Symbol.iterator]() {\r\n return this;\r\n }\r\n };\r\n };\r\n}\r\nfunction createReadonlyMethod(type) {\r\n return function (...args) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const key = args[0] ? `on key \"${args[0]}\" ` : ``;\r\n console.warn(`${capitalize(type)} operation ${key}failed: target is readonly.`, toRaw(this));\r\n }\r\n return type === \"delete\" /* DELETE */ ? false : this;\r\n };\r\n}\r\nfunction createInstrumentations() {\r\n const mutableInstrumentations = {\r\n get(key) {\r\n return get$1(this, key);\r\n },\r\n get size() {\r\n return size(this);\r\n },\r\n has: has$1,\r\n add,\r\n set: set$1,\r\n delete: deleteEntry,\r\n clear,\r\n forEach: createForEach(false, false)\r\n };\r\n const shallowInstrumentations = {\r\n get(key) {\r\n return get$1(this, key, false, true);\r\n },\r\n get size() {\r\n return size(this);\r\n },\r\n has: has$1,\r\n add,\r\n set: set$1,\r\n delete: deleteEntry,\r\n clear,\r\n forEach: createForEach(false, true)\r\n };\r\n const readonlyInstrumentations = {\r\n get(key) {\r\n return get$1(this, key, true);\r\n },\r\n get size() {\r\n return size(this, true);\r\n },\r\n has(key) {\r\n return has$1.call(this, key, true);\r\n },\r\n add: createReadonlyMethod(\"add\" /* ADD */),\r\n set: createReadonlyMethod(\"set\" /* SET */),\r\n delete: createReadonlyMethod(\"delete\" /* DELETE */),\r\n clear: createReadonlyMethod(\"clear\" /* CLEAR */),\r\n forEach: createForEach(true, false)\r\n };\r\n const shallowReadonlyInstrumentations = {\r\n get(key) {\r\n return get$1(this, key, true, true);\r\n },\r\n get size() {\r\n return size(this, true);\r\n },\r\n has(key) {\r\n return has$1.call(this, key, true);\r\n },\r\n add: createReadonlyMethod(\"add\" /* ADD */),\r\n set: createReadonlyMethod(\"set\" /* SET */),\r\n delete: createReadonlyMethod(\"delete\" /* DELETE */),\r\n clear: createReadonlyMethod(\"clear\" /* CLEAR */),\r\n forEach: createForEach(true, true)\r\n };\r\n const iteratorMethods = ['keys', 'values', 'entries', Symbol.iterator];\r\n iteratorMethods.forEach(method => {\r\n mutableInstrumentations[method] = createIterableMethod(method, false, false);\r\n readonlyInstrumentations[method] = createIterableMethod(method, true, false);\r\n shallowInstrumentations[method] = createIterableMethod(method, false, true);\r\n shallowReadonlyInstrumentations[method] = createIterableMethod(method, true, true);\r\n });\r\n return [\r\n mutableInstrumentations,\r\n readonlyInstrumentations,\r\n shallowInstrumentations,\r\n shallowReadonlyInstrumentations\r\n ];\r\n}\r\nconst [mutableInstrumentations, readonlyInstrumentations, shallowInstrumentations, shallowReadonlyInstrumentations] = /* #__PURE__*/ createInstrumentations();\r\nfunction createInstrumentationGetter(isReadonly, shallow) {\r\n const instrumentations = shallow\r\n ? isReadonly\r\n ? shallowReadonlyInstrumentations\r\n : shallowInstrumentations\r\n : isReadonly\r\n ? readonlyInstrumentations\r\n : mutableInstrumentations;\r\n return (target, key, receiver) => {\r\n if (key === \"__v_isReactive\" /* IS_REACTIVE */) {\r\n return !isReadonly;\r\n }\r\n else if (key === \"__v_isReadonly\" /* IS_READONLY */) {\r\n return isReadonly;\r\n }\r\n else if (key === \"__v_raw\" /* RAW */) {\r\n return target;\r\n }\r\n return Reflect.get(hasOwn(instrumentations, key) && key in target\r\n ? instrumentations\r\n : target, key, receiver);\r\n };\r\n}\r\nconst mutableCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(false, false)\r\n};\r\nconst shallowCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(false, true)\r\n};\r\nconst readonlyCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(true, false)\r\n};\r\nconst shallowReadonlyCollectionHandlers = {\r\n get: /*#__PURE__*/ createInstrumentationGetter(true, true)\r\n};\r\nfunction checkIdentityKeys(target, has, key) {\r\n const rawKey = toRaw(key);\r\n if (rawKey !== key && has.call(target, rawKey)) {\r\n const type = toRawType(target);\r\n console.warn(`Reactive ${type} contains both the raw and reactive ` +\r\n `versions of the same object${type === `Map` ? ` as keys` : ``}, ` +\r\n `which can lead to inconsistencies. ` +\r\n `Avoid differentiating between the raw and reactive versions ` +\r\n `of an object and only use the reactive version if possible.`);\r\n }\r\n}\n\nconst reactiveMap = new WeakMap();\r\nconst shallowReactiveMap = new WeakMap();\r\nconst readonlyMap = new WeakMap();\r\nconst shallowReadonlyMap = new WeakMap();\r\nfunction targetTypeMap(rawType) {\r\n switch (rawType) {\r\n case 'Object':\r\n case 'Array':\r\n return 1 /* COMMON */;\r\n case 'Map':\r\n case 'Set':\r\n case 'WeakMap':\r\n case 'WeakSet':\r\n return 2 /* COLLECTION */;\r\n default:\r\n return 0 /* INVALID */;\r\n }\r\n}\r\nfunction getTargetType(value) {\r\n return value[\"__v_skip\" /* SKIP */] || !Object.isExtensible(value)\r\n ? 0 /* INVALID */\r\n : targetTypeMap(toRawType(value));\r\n}\r\nfunction reactive(target) {\r\n // if trying to observe a readonly proxy, return the readonly version.\r\n if (target && target[\"__v_isReadonly\" /* IS_READONLY */]) {\r\n return target;\r\n }\r\n return createReactiveObject(target, false, mutableHandlers, mutableCollectionHandlers, reactiveMap);\r\n}\r\n/**\r\n * Return a shallowly-reactive copy of the original object, where only the root\r\n * level properties are reactive. It also does not auto-unwrap refs (even at the\r\n * root level).\r\n */\r\nfunction shallowReactive(target) {\r\n return createReactiveObject(target, false, shallowReactiveHandlers, shallowCollectionHandlers, shallowReactiveMap);\r\n}\r\n/**\r\n * Creates a readonly copy of the original object. Note the returned copy is not\r\n * made reactive, but `readonly` can be called on an already reactive object.\r\n */\r\nfunction readonly(target) {\r\n return createReactiveObject(target, true, readonlyHandlers, readonlyCollectionHandlers, readonlyMap);\r\n}\r\n/**\r\n * Returns a reactive-copy of the original object, where only the root level\r\n * properties are readonly, and does NOT unwrap refs nor recursively convert\r\n * returned properties.\r\n * This is used for creating the props proxy object for stateful components.\r\n */\r\nfunction shallowReadonly(target) {\r\n return createReactiveObject(target, true, shallowReadonlyHandlers, shallowReadonlyCollectionHandlers, shallowReadonlyMap);\r\n}\r\nfunction createReactiveObject(target, isReadonly, baseHandlers, collectionHandlers, proxyMap) {\r\n if (!isObject(target)) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n console.warn(`value cannot be made reactive: ${String(target)}`);\r\n }\r\n return target;\r\n }\r\n // target is already a Proxy, return it.\r\n // exception: calling readonly() on a reactive object\r\n if (target[\"__v_raw\" /* RAW */] &&\r\n !(isReadonly && target[\"__v_isReactive\" /* IS_REACTIVE */])) {\r\n return target;\r\n }\r\n // target already has corresponding Proxy\r\n const existingProxy = proxyMap.get(target);\r\n if (existingProxy) {\r\n return existingProxy;\r\n }\r\n // only a whitelist of value types can be observed.\r\n const targetType = getTargetType(target);\r\n if (targetType === 0 /* INVALID */) {\r\n return target;\r\n }\r\n const proxy = new Proxy(target, targetType === 2 /* COLLECTION */ ? collectionHandlers : baseHandlers);\r\n proxyMap.set(target, proxy);\r\n return proxy;\r\n}\r\nfunction isReactive(value) {\r\n if (isReadonly(value)) {\r\n return isReactive(value[\"__v_raw\" /* RAW */]);\r\n }\r\n return !!(value && value[\"__v_isReactive\" /* IS_REACTIVE */]);\r\n}\r\nfunction isReadonly(value) {\r\n return !!(value && value[\"__v_isReadonly\" /* IS_READONLY */]);\r\n}\r\nfunction isProxy(value) {\r\n return isReactive(value) || isReadonly(value);\r\n}\r\nfunction toRaw(observed) {\r\n const raw = observed && observed[\"__v_raw\" /* RAW */];\r\n return raw ? toRaw(raw) : observed;\r\n}\r\nfunction markRaw(value) {\r\n def(value, \"__v_skip\" /* SKIP */, true);\r\n return value;\r\n}\r\nconst toReactive = (value) => isObject(value) ? reactive(value) : value;\r\nconst toReadonly = (value) => isObject(value) ? readonly(value) : value;\n\nfunction trackRefValue(ref) {\r\n if (isTracking()) {\r\n ref = toRaw(ref);\r\n if (!ref.dep) {\r\n ref.dep = createDep();\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n trackEffects(ref.dep, {\r\n target: ref,\r\n type: \"get\" /* GET */,\r\n key: 'value'\r\n });\r\n }\r\n else {\r\n trackEffects(ref.dep);\r\n }\r\n }\r\n}\r\nfunction triggerRefValue(ref, newVal) {\r\n ref = toRaw(ref);\r\n if (ref.dep) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n triggerEffects(ref.dep, {\r\n target: ref,\r\n type: \"set\" /* SET */,\r\n key: 'value',\r\n newValue: newVal\r\n });\r\n }\r\n else {\r\n triggerEffects(ref.dep);\r\n }\r\n }\r\n}\r\nfunction isRef(r) {\r\n return Boolean(r && r.__v_isRef === true);\r\n}\r\nfunction ref(value) {\r\n return createRef(value, false);\r\n}\r\nfunction shallowRef(value) {\r\n return createRef(value, true);\r\n}\r\nfunction createRef(rawValue, shallow) {\r\n if (isRef(rawValue)) {\r\n return rawValue;\r\n }\r\n return new RefImpl(rawValue, shallow);\r\n}\r\nclass RefImpl {\r\n constructor(value, _shallow) {\r\n this._shallow = _shallow;\r\n this.dep = undefined;\r\n this.__v_isRef = true;\r\n this._rawValue = _shallow ? value : toRaw(value);\r\n this._value = _shallow ? value : toReactive(value);\r\n }\r\n get value() {\r\n trackRefValue(this);\r\n return this._value;\r\n }\r\n set value(newVal) {\r\n newVal = this._shallow ? newVal : toRaw(newVal);\r\n if (hasChanged(newVal, this._rawValue)) {\r\n this._rawValue = newVal;\r\n this._value = this._shallow ? newVal : toReactive(newVal);\r\n triggerRefValue(this, newVal);\r\n }\r\n }\r\n}\r\nfunction triggerRef(ref) {\r\n triggerRefValue(ref, (process.env.NODE_ENV !== 'production') ? ref.value : void 0);\r\n}\r\nfunction unref(ref) {\r\n return isRef(ref) ? ref.value : ref;\r\n}\r\nconst shallowUnwrapHandlers = {\r\n get: (target, key, receiver) => unref(Reflect.get(target, key, receiver)),\r\n set: (target, key, value, receiver) => {\r\n const oldValue = target[key];\r\n if (isRef(oldValue) && !isRef(value)) {\r\n oldValue.value = value;\r\n return true;\r\n }\r\n else {\r\n return Reflect.set(target, key, value, receiver);\r\n }\r\n }\r\n};\r\nfunction proxyRefs(objectWithRefs) {\r\n return isReactive(objectWithRefs)\r\n ? objectWithRefs\r\n : new Proxy(objectWithRefs, shallowUnwrapHandlers);\r\n}\r\nclass CustomRefImpl {\r\n constructor(factory) {\r\n this.dep = undefined;\r\n this.__v_isRef = true;\r\n const { get, set } = factory(() => trackRefValue(this), () => triggerRefValue(this));\r\n this._get = get;\r\n this._set = set;\r\n }\r\n get value() {\r\n return this._get();\r\n }\r\n set value(newVal) {\r\n this._set(newVal);\r\n }\r\n}\r\nfunction customRef(factory) {\r\n return new CustomRefImpl(factory);\r\n}\r\nfunction toRefs(object) {\r\n if ((process.env.NODE_ENV !== 'production') && !isProxy(object)) {\r\n console.warn(`toRefs() expects a reactive object but received a plain one.`);\r\n }\r\n const ret = isArray(object) ? new Array(object.length) : {};\r\n for (const key in object) {\r\n ret[key] = toRef(object, key);\r\n }\r\n return ret;\r\n}\r\nclass ObjectRefImpl {\r\n constructor(_object, _key) {\r\n this._object = _object;\r\n this._key = _key;\r\n this.__v_isRef = true;\r\n }\r\n get value() {\r\n return this._object[this._key];\r\n }\r\n set value(newVal) {\r\n this._object[this._key] = newVal;\r\n }\r\n}\r\nfunction toRef(object, key) {\r\n const val = object[key];\r\n return isRef(val) ? val : new ObjectRefImpl(object, key);\r\n}\n\nclass ComputedRefImpl {\r\n constructor(getter, _setter, isReadonly) {\r\n this._setter = _setter;\r\n this.dep = undefined;\r\n this._dirty = true;\r\n this.__v_isRef = true;\r\n this.effect = new ReactiveEffect(getter, () => {\r\n if (!this._dirty) {\r\n this._dirty = true;\r\n triggerRefValue(this);\r\n }\r\n });\r\n this[\"__v_isReadonly\" /* IS_READONLY */] = isReadonly;\r\n }\r\n get value() {\r\n // the computed ref may get wrapped by other proxies e.g. readonly() #3376\r\n const self = toRaw(this);\r\n trackRefValue(self);\r\n if (self._dirty) {\r\n self._dirty = false;\r\n self._value = self.effect.run();\r\n }\r\n return self._value;\r\n }\r\n set value(newValue) {\r\n this._setter(newValue);\r\n }\r\n}\r\nfunction computed(getterOrOptions, debugOptions) {\r\n let getter;\r\n let setter;\r\n const onlyGetter = isFunction(getterOrOptions);\r\n if (onlyGetter) {\r\n getter = getterOrOptions;\r\n setter = (process.env.NODE_ENV !== 'production')\r\n ? () => {\r\n console.warn('Write operation failed: computed value is readonly');\r\n }\r\n : NOOP;\r\n }\r\n else {\r\n getter = getterOrOptions.get;\r\n setter = getterOrOptions.set;\r\n }\r\n const cRef = new ComputedRefImpl(getter, setter, onlyGetter || !setter);\r\n if ((process.env.NODE_ENV !== 'production') && debugOptions) {\r\n cRef.effect.onTrack = debugOptions.onTrack;\r\n cRef.effect.onTrigger = debugOptions.onTrigger;\r\n }\r\n return cRef;\r\n}\n\nvar _a;\r\nconst tick = Promise.resolve();\r\nconst queue = [];\r\nlet queued = false;\r\nconst scheduler = (fn) => {\r\n queue.push(fn);\r\n if (!queued) {\r\n queued = true;\r\n tick.then(flush);\r\n }\r\n};\r\nconst flush = () => {\r\n for (let i = 0; i < queue.length; i++) {\r\n queue[i]();\r\n }\r\n queue.length = 0;\r\n queued = false;\r\n};\r\nclass DeferredComputedRefImpl {\r\n constructor(getter) {\r\n this.dep = undefined;\r\n this._dirty = true;\r\n this.__v_isRef = true;\r\n this[_a] = true;\r\n let compareTarget;\r\n let hasCompareTarget = false;\r\n let scheduled = false;\r\n this.effect = new ReactiveEffect(getter, (computedTrigger) => {\r\n if (this.dep) {\r\n if (computedTrigger) {\r\n compareTarget = this._value;\r\n hasCompareTarget = true;\r\n }\r\n else if (!scheduled) {\r\n const valueToCompare = hasCompareTarget ? compareTarget : this._value;\r\n scheduled = true;\r\n hasCompareTarget = false;\r\n scheduler(() => {\r\n if (this.effect.active && this._get() !== valueToCompare) {\r\n triggerRefValue(this);\r\n }\r\n scheduled = false;\r\n });\r\n }\r\n // chained upstream computeds are notified synchronously to ensure\r\n // value invalidation in case of sync access; normal effects are\r\n // deferred to be triggered in scheduler.\r\n for (const e of this.dep) {\r\n if (e.computed) {\r\n e.scheduler(true /* computedTrigger */);\r\n }\r\n }\r\n }\r\n this._dirty = true;\r\n });\r\n this.effect.computed = true;\r\n }\r\n _get() {\r\n if (this._dirty) {\r\n this._dirty = false;\r\n return (this._value = this.effect.run());\r\n }\r\n return this._value;\r\n }\r\n get value() {\r\n trackRefValue(this);\r\n // the computed ref may get wrapped by other proxies e.g. readonly() #3376\r\n return toRaw(this)._get();\r\n }\r\n}\r\n_a = \"__v_isReadonly\" /* IS_READONLY */;\r\nfunction deferredComputed(getter) {\r\n return new DeferredComputedRefImpl(getter);\r\n}\n\nexport { EffectScope, ITERATE_KEY, ReactiveEffect, computed, customRef, deferredComputed, effect, effectScope, enableTracking, getCurrentScope, isProxy, isReactive, isReadonly, isRef, markRaw, onScopeDispose, pauseTracking, proxyRefs, reactive, readonly, ref, resetTracking, shallowReactive, shallowReadonly, shallowRef, stop, toRaw, toRef, toRefs, track, trigger, triggerRef, unref };\n","import { toRaw, ref, pauseTracking, resetTracking, reactive, computed, isRef, shallowReactive, trigger, ReactiveEffect, isProxy, shallowReadonly, track, EffectScope, markRaw, proxyRefs, isReactive, isReadonly } from '@vue/reactivity';\nexport { EffectScope, ReactiveEffect, computed, customRef, effect, effectScope, getCurrentScope, isProxy, isReactive, isReadonly, isRef, markRaw, onScopeDispose, proxyRefs, reactive, readonly, ref, shallowReactive, shallowReadonly, shallowRef, stop, toRaw, toRef, toRefs, triggerRef, unref } from '@vue/reactivity';\nimport { getGlobalThis, extend, EMPTY_OBJ, toHandlerKey, isFunction, toNumber, hyphenate, camelize, isArray, isOn, hasOwn, isModelListener, isObject, remove, isString, invokeArrayFns, isPromise, NOOP, def, isReservedProp, EMPTY_ARR, capitalize, toRawType, makeMap, NO, normalizeClass, normalizeStyle, isGloballyWhitelisted, hasChanged, isSet, isMap, isPlainObject } from '@vue/shared';\nexport { camelize, capitalize, normalizeClass, normalizeProps, normalizeStyle, toDisplayString, toHandlerKey } from '@vue/shared';\n\n/* eslint-disable no-restricted-globals */\r\nlet isHmrUpdating = false;\r\nconst hmrDirtyComponents = new Set();\r\n// Expose the HMR runtime on the global object\r\n// This makes it entirely tree-shakable without polluting the exports and makes\r\n// it easier to be used in toolings like vue-loader\r\n// Note: for a component to be eligible for HMR it also needs the __hmrId option\r\n// to be set so that its instances can be registered / removed.\r\nif ((process.env.NODE_ENV !== 'production')) {\r\n getGlobalThis().__VUE_HMR_RUNTIME__ = {\r\n createRecord: tryWrap(createRecord),\r\n rerender: tryWrap(rerender),\r\n reload: tryWrap(reload)\r\n };\r\n}\r\nconst map = new Map();\r\nfunction registerHMR(instance) {\r\n const id = instance.type.__hmrId;\r\n let record = map.get(id);\r\n if (!record) {\r\n createRecord(id, instance.type);\r\n record = map.get(id);\r\n }\r\n record.instances.add(instance);\r\n}\r\nfunction unregisterHMR(instance) {\r\n map.get(instance.type.__hmrId).instances.delete(instance);\r\n}\r\nfunction createRecord(id, initialDef) {\r\n if (map.has(id)) {\r\n return false;\r\n }\r\n map.set(id, {\r\n initialDef: normalizeClassComponent(initialDef),\r\n instances: new Set()\r\n });\r\n return true;\r\n}\r\nfunction normalizeClassComponent(component) {\r\n return isClassComponent(component) ? component.__vccOpts : component;\r\n}\r\nfunction rerender(id, newRender) {\r\n const record = map.get(id);\r\n if (!record) {\r\n return;\r\n }\r\n // update initial record (for not-yet-rendered component)\r\n record.initialDef.render = newRender;\r\n [...record.instances].forEach(instance => {\r\n if (newRender) {\r\n instance.render = newRender;\r\n normalizeClassComponent(instance.type).render = newRender;\r\n }\r\n instance.renderCache = [];\r\n // this flag forces child components with slot content to update\r\n isHmrUpdating = true;\r\n instance.update();\r\n isHmrUpdating = false;\r\n });\r\n}\r\nfunction reload(id, newComp) {\r\n const record = map.get(id);\r\n if (!record)\r\n return;\r\n newComp = normalizeClassComponent(newComp);\r\n // update initial def (for not-yet-rendered components)\r\n updateComponentDef(record.initialDef, newComp);\r\n // create a snapshot which avoids the set being mutated during updates\r\n const instances = [...record.instances];\r\n for (const instance of instances) {\r\n const oldComp = normalizeClassComponent(instance.type);\r\n if (!hmrDirtyComponents.has(oldComp)) {\r\n // 1. Update existing comp definition to match new one\r\n if (oldComp !== record.initialDef) {\r\n updateComponentDef(oldComp, newComp);\r\n }\r\n // 2. mark definition dirty. This forces the renderer to replace the\r\n // component on patch.\r\n hmrDirtyComponents.add(oldComp);\r\n }\r\n // 3. invalidate options resolution cache\r\n instance.appContext.optionsCache.delete(instance.type);\r\n // 4. actually update\r\n if (instance.ceReload) {\r\n // custom element\r\n hmrDirtyComponents.add(oldComp);\r\n instance.ceReload(newComp.styles);\r\n hmrDirtyComponents.delete(oldComp);\r\n }\r\n else if (instance.parent) {\r\n // 4. Force the parent instance to re-render. This will cause all updated\r\n // components to be unmounted and re-mounted. Queue the update so that we\r\n // don't end up forcing the same parent to re-render multiple times.\r\n queueJob(instance.parent.update);\r\n // instance is the inner component of an async custom element\r\n // invoke to reset styles\r\n if (instance.parent.type.__asyncLoader &&\r\n instance.parent.ceReload) {\r\n instance.parent.ceReload(newComp.styles);\r\n }\r\n }\r\n else if (instance.appContext.reload) {\r\n // root instance mounted via createApp() has a reload method\r\n instance.appContext.reload();\r\n }\r\n else if (typeof window !== 'undefined') {\r\n // root instance inside tree created via raw render(). Force reload.\r\n window.location.reload();\r\n }\r\n else {\r\n console.warn('[HMR] Root or manually mounted instance modified. Full reload required.');\r\n }\r\n }\r\n // 5. make sure to cleanup dirty hmr components after update\r\n queuePostFlushCb(() => {\r\n for (const instance of instances) {\r\n hmrDirtyComponents.delete(normalizeClassComponent(instance.type));\r\n }\r\n });\r\n}\r\nfunction updateComponentDef(oldComp, newComp) {\r\n extend(oldComp, newComp);\r\n for (const key in oldComp) {\r\n if (key !== '__file' && !(key in newComp)) {\r\n delete oldComp[key];\r\n }\r\n }\r\n}\r\nfunction tryWrap(fn) {\r\n return (id, arg) => {\r\n try {\r\n return fn(id, arg);\r\n }\r\n catch (e) {\r\n console.error(e);\r\n console.warn(`[HMR] Something went wrong during Vue component hot-reload. ` +\r\n `Full reload required.`);\r\n }\r\n };\r\n}\n\nlet devtools;\r\nlet buffer = [];\r\nlet devtoolsNotInstalled = false;\r\nfunction emit(event, ...args) {\r\n if (devtools) {\r\n devtools.emit(event, ...args);\r\n }\r\n else if (!devtoolsNotInstalled) {\r\n buffer.push({ event, args });\r\n }\r\n}\r\nfunction setDevtoolsHook(hook, target) {\r\n var _a, _b;\r\n devtools = hook;\r\n if (devtools) {\r\n devtools.enabled = true;\r\n buffer.forEach(({ event, args }) => devtools.emit(event, ...args));\r\n buffer = [];\r\n }\r\n else if (\r\n // handle late devtools injection - only do this if we are in an actual\r\n // browser environment to avoid the timer handle stalling test runner exit\r\n // (#4815)\r\n // eslint-disable-next-line no-restricted-globals\r\n typeof window !== 'undefined' &&\r\n // some envs mock window but not fully\r\n window.HTMLElement &&\r\n // also exclude jsdom\r\n !((_b = (_a = window.navigator) === null || _a === void 0 ? void 0 : _a.userAgent) === null || _b === void 0 ? void 0 : _b.includes('jsdom'))) {\r\n const replay = (target.__VUE_DEVTOOLS_HOOK_REPLAY__ =\r\n target.__VUE_DEVTOOLS_HOOK_REPLAY__ || []);\r\n replay.push((newHook) => {\r\n setDevtoolsHook(newHook, target);\r\n });\r\n // clear buffer after 3s - the user probably doesn't have devtools installed\r\n // at all, and keeping the buffer will cause memory leaks (#4738)\r\n setTimeout(() => {\r\n if (!devtools) {\r\n target.__VUE_DEVTOOLS_HOOK_REPLAY__ = null;\r\n devtoolsNotInstalled = true;\r\n buffer = [];\r\n }\r\n }, 3000);\r\n }\r\n else {\r\n // non-browser env, assume not installed\r\n devtoolsNotInstalled = true;\r\n buffer = [];\r\n }\r\n}\r\nfunction devtoolsInitApp(app, version) {\r\n emit(\"app:init\" /* APP_INIT */, app, version, {\r\n Fragment,\r\n Text,\r\n Comment,\r\n Static\r\n });\r\n}\r\nfunction devtoolsUnmountApp(app) {\r\n emit(\"app:unmount\" /* APP_UNMOUNT */, app);\r\n}\r\nconst devtoolsComponentAdded = /*#__PURE__*/ createDevtoolsComponentHook(\"component:added\" /* COMPONENT_ADDED */);\r\nconst devtoolsComponentUpdated = \r\n/*#__PURE__*/ createDevtoolsComponentHook(\"component:updated\" /* COMPONENT_UPDATED */);\r\nconst devtoolsComponentRemoved = \r\n/*#__PURE__*/ createDevtoolsComponentHook(\"component:removed\" /* COMPONENT_REMOVED */);\r\nfunction createDevtoolsComponentHook(hook) {\r\n return (component) => {\r\n emit(hook, component.appContext.app, component.uid, component.parent ? component.parent.uid : undefined, component);\r\n };\r\n}\r\nconst devtoolsPerfStart = /*#__PURE__*/ createDevtoolsPerformanceHook(\"perf:start\" /* PERFORMANCE_START */);\r\nconst devtoolsPerfEnd = /*#__PURE__*/ createDevtoolsPerformanceHook(\"perf:end\" /* PERFORMANCE_END */);\r\nfunction createDevtoolsPerformanceHook(hook) {\r\n return (component, type, time) => {\r\n emit(hook, component.appContext.app, component.uid, component, type, time);\r\n };\r\n}\r\nfunction devtoolsComponentEmit(component, event, params) {\r\n emit(\"component:emit\" /* COMPONENT_EMIT */, component.appContext.app, component, event, params);\r\n}\n\nfunction emit$1(instance, event, ...rawArgs) {\r\n const props = instance.vnode.props || EMPTY_OBJ;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const { emitsOptions, propsOptions: [propsOptions] } = instance;\r\n if (emitsOptions) {\r\n if (!(event in emitsOptions) &&\r\n !(false )) {\r\n if (!propsOptions || !(toHandlerKey(event) in propsOptions)) {\r\n warn(`Component emitted event \"${event}\" but it is neither declared in ` +\r\n `the emits option nor as an \"${toHandlerKey(event)}\" prop.`);\r\n }\r\n }\r\n else {\r\n const validator = emitsOptions[event];\r\n if (isFunction(validator)) {\r\n const isValid = validator(...rawArgs);\r\n if (!isValid) {\r\n warn(`Invalid event arguments: event validation failed for event \"${event}\".`);\r\n }\r\n }\r\n }\r\n }\r\n }\r\n let args = rawArgs;\r\n const isModelListener = event.startsWith('update:');\r\n // for v-model update:xxx events, apply modifiers on args\r\n const modelArg = isModelListener && event.slice(7);\r\n if (modelArg && modelArg in props) {\r\n const modifiersKey = `${modelArg === 'modelValue' ? 'model' : modelArg}Modifiers`;\r\n const { number, trim } = props[modifiersKey] || EMPTY_OBJ;\r\n if (trim) {\r\n args = rawArgs.map(a => a.trim());\r\n }\r\n else if (number) {\r\n args = rawArgs.map(toNumber);\r\n }\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentEmit(instance, event, args);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const lowerCaseEvent = event.toLowerCase();\r\n if (lowerCaseEvent !== event && props[toHandlerKey(lowerCaseEvent)]) {\r\n warn(`Event \"${lowerCaseEvent}\" is emitted in component ` +\r\n `${formatComponentName(instance, instance.type)} but the handler is registered for \"${event}\". ` +\r\n `Note that HTML attributes are case-insensitive and you cannot use ` +\r\n `v-on to listen to camelCase events when using in-DOM templates. ` +\r\n `You should probably use \"${hyphenate(event)}\" instead of \"${event}\".`);\r\n }\r\n }\r\n let handlerName;\r\n let handler = props[(handlerName = toHandlerKey(event))] ||\r\n // also try camelCase event handler (#2249)\r\n props[(handlerName = toHandlerKey(camelize(event)))];\r\n // for v-model update:xxx events, also trigger kebab-case equivalent\r\n // for props passed via kebab-case\r\n if (!handler && isModelListener) {\r\n handler = props[(handlerName = toHandlerKey(hyphenate(event)))];\r\n }\r\n if (handler) {\r\n callWithAsyncErrorHandling(handler, instance, 6 /* COMPONENT_EVENT_HANDLER */, args);\r\n }\r\n const onceHandler = props[handlerName + `Once`];\r\n if (onceHandler) {\r\n if (!instance.emitted) {\r\n instance.emitted = {};\r\n }\r\n else if (instance.emitted[handlerName]) {\r\n return;\r\n }\r\n instance.emitted[handlerName] = true;\r\n callWithAsyncErrorHandling(onceHandler, instance, 6 /* COMPONENT_EVENT_HANDLER */, args);\r\n }\r\n}\r\nfunction normalizeEmitsOptions(comp, appContext, asMixin = false) {\r\n const cache = appContext.emitsCache;\r\n const cached = cache.get(comp);\r\n if (cached !== undefined) {\r\n return cached;\r\n }\r\n const raw = comp.emits;\r\n let normalized = {};\r\n // apply mixin/extends props\r\n let hasExtends = false;\r\n if (__VUE_OPTIONS_API__ && !isFunction(comp)) {\r\n const extendEmits = (raw) => {\r\n const normalizedFromExtend = normalizeEmitsOptions(raw, appContext, true);\r\n if (normalizedFromExtend) {\r\n hasExtends = true;\r\n extend(normalized, normalizedFromExtend);\r\n }\r\n };\r\n if (!asMixin && appContext.mixins.length) {\r\n appContext.mixins.forEach(extendEmits);\r\n }\r\n if (comp.extends) {\r\n extendEmits(comp.extends);\r\n }\r\n if (comp.mixins) {\r\n comp.mixins.forEach(extendEmits);\r\n }\r\n }\r\n if (!raw && !hasExtends) {\r\n cache.set(comp, null);\r\n return null;\r\n }\r\n if (isArray(raw)) {\r\n raw.forEach(key => (normalized[key] = null));\r\n }\r\n else {\r\n extend(normalized, raw);\r\n }\r\n cache.set(comp, normalized);\r\n return normalized;\r\n}\r\n// Check if an incoming prop key is a declared emit event listener.\r\n// e.g. With `emits: { click: null }`, props named `onClick` and `onclick` are\r\n// both considered matched listeners.\r\nfunction isEmitListener(options, key) {\r\n if (!options || !isOn(key)) {\r\n return false;\r\n }\r\n key = key.slice(2).replace(/Once$/, '');\r\n return (hasOwn(options, key[0].toLowerCase() + key.slice(1)) ||\r\n hasOwn(options, hyphenate(key)) ||\r\n hasOwn(options, key));\r\n}\n\n/**\r\n * mark the current rendering instance for asset resolution (e.g.\r\n * resolveComponent, resolveDirective) during render\r\n */\r\nlet currentRenderingInstance = null;\r\nlet currentScopeId = null;\r\n/**\r\n * Note: rendering calls maybe nested. The function returns the parent rendering\r\n * instance if present, which should be restored after the render is done:\r\n *\r\n * ```js\r\n * const prev = setCurrentRenderingInstance(i)\r\n * // ...render\r\n * setCurrentRenderingInstance(prev)\r\n * ```\r\n */\r\nfunction setCurrentRenderingInstance(instance) {\r\n const prev = currentRenderingInstance;\r\n currentRenderingInstance = instance;\r\n currentScopeId = (instance && instance.type.__scopeId) || null;\r\n return prev;\r\n}\r\n/**\r\n * Set scope id when creating hoisted vnodes.\r\n * @private compiler helper\r\n */\r\nfunction pushScopeId(id) {\r\n currentScopeId = id;\r\n}\r\n/**\r\n * Technically we no longer need this after 3.0.8 but we need to keep the same\r\n * API for backwards compat w/ code generated by compilers.\r\n * @private\r\n */\r\nfunction popScopeId() {\r\n currentScopeId = null;\r\n}\r\n/**\r\n * Only for backwards compat\r\n * @private\r\n */\r\nconst withScopeId = (_id) => withCtx;\r\n/**\r\n * Wrap a slot function to memoize current rendering instance\r\n * @private compiler helper\r\n */\r\nfunction withCtx(fn, ctx = currentRenderingInstance, isNonScopedSlot // false only\r\n) {\r\n if (!ctx)\r\n return fn;\r\n // already normalized\r\n if (fn._n) {\r\n return fn;\r\n }\r\n const renderFnWithContext = (...args) => {\r\n // If a user calls a compiled slot inside a template expression (#1745), it\r\n // can mess up block tracking, so by default we disable block tracking and\r\n // force bail out when invoking a compiled slot (indicated by the ._d flag).\r\n // This isn't necessary if rendering a compiled `<slot>`, so we flip the\r\n // ._d flag off when invoking the wrapped fn inside `renderSlot`.\r\n if (renderFnWithContext._d) {\r\n setBlockTracking(-1);\r\n }\r\n const prevInstance = setCurrentRenderingInstance(ctx);\r\n const res = fn(...args);\r\n setCurrentRenderingInstance(prevInstance);\r\n if (renderFnWithContext._d) {\r\n setBlockTracking(1);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentUpdated(ctx);\r\n }\r\n return res;\r\n };\r\n // mark normalized to avoid duplicated wrapping\r\n renderFnWithContext._n = true;\r\n // mark this as compiled by default\r\n // this is used in vnode.ts -> normalizeChildren() to set the slot\r\n // rendering flag.\r\n renderFnWithContext._c = true;\r\n // disable block tracking by default\r\n renderFnWithContext._d = true;\r\n return renderFnWithContext;\r\n}\n\n/**\r\n * dev only flag to track whether $attrs was used during render.\r\n * If $attrs was used during render then the warning for failed attrs\r\n * fallthrough can be suppressed.\r\n */\r\nlet accessedAttrs = false;\r\nfunction markAttrsAccessed() {\r\n accessedAttrs = true;\r\n}\r\nfunction renderComponentRoot(instance) {\r\n const { type: Component, vnode, proxy, withProxy, props, propsOptions: [propsOptions], slots, attrs, emit, render, renderCache, data, setupState, ctx, inheritAttrs } = instance;\r\n let result;\r\n let fallthroughAttrs;\r\n const prev = setCurrentRenderingInstance(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n accessedAttrs = false;\r\n }\r\n try {\r\n if (vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */) {\r\n // withProxy is a proxy with a different `has` trap only for\r\n // runtime-compiled render functions using `with` block.\r\n const proxyToUse = withProxy || proxy;\r\n result = normalizeVNode(render.call(proxyToUse, proxyToUse, renderCache, props, setupState, data, ctx));\r\n fallthroughAttrs = attrs;\r\n }\r\n else {\r\n // functional\r\n const render = Component;\r\n // in dev, mark attrs accessed if optional props (attrs === props)\r\n if ((process.env.NODE_ENV !== 'production') && attrs === props) {\r\n markAttrsAccessed();\r\n }\r\n result = normalizeVNode(render.length > 1\r\n ? render(props, (process.env.NODE_ENV !== 'production')\r\n ? {\r\n get attrs() {\r\n markAttrsAccessed();\r\n return attrs;\r\n },\r\n slots,\r\n emit\r\n }\r\n : { attrs, slots, emit })\r\n : render(props, null /* we know it doesn't need it */));\r\n fallthroughAttrs = Component.props\r\n ? attrs\r\n : getFunctionalFallthrough(attrs);\r\n }\r\n }\r\n catch (err) {\r\n blockStack.length = 0;\r\n handleError(err, instance, 1 /* RENDER_FUNCTION */);\r\n result = createVNode(Comment);\r\n }\r\n // attr merging\r\n // in dev mode, comments are preserved, and it's possible for a template\r\n // to have comments along side the root element which makes it a fragment\r\n let root = result;\r\n let setRoot = undefined;\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n result.patchFlag > 0 &&\r\n result.patchFlag & 2048 /* DEV_ROOT_FRAGMENT */) {\r\n [root, setRoot] = getChildRoot(result);\r\n }\r\n if (fallthroughAttrs && inheritAttrs !== false) {\r\n const keys = Object.keys(fallthroughAttrs);\r\n const { shapeFlag } = root;\r\n if (keys.length) {\r\n if (shapeFlag & (1 /* ELEMENT */ | 6 /* COMPONENT */)) {\r\n if (propsOptions && keys.some(isModelListener)) {\r\n // If a v-model listener (onUpdate:xxx) has a corresponding declared\r\n // prop, it indicates this component expects to handle v-model and\r\n // it should not fallthrough.\r\n // related: #1543, #1643, #1989\r\n fallthroughAttrs = filterModelListeners(fallthroughAttrs, propsOptions);\r\n }\r\n root = cloneVNode(root, fallthroughAttrs);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') && !accessedAttrs && root.type !== Comment) {\r\n const allAttrs = Object.keys(attrs);\r\n const eventAttrs = [];\r\n const extraAttrs = [];\r\n for (let i = 0, l = allAttrs.length; i < l; i++) {\r\n const key = allAttrs[i];\r\n if (isOn(key)) {\r\n // ignore v-model handlers when they fail to fallthrough\r\n if (!isModelListener(key)) {\r\n // remove `on`, lowercase first letter to reflect event casing\r\n // accurately\r\n eventAttrs.push(key[2].toLowerCase() + key.slice(3));\r\n }\r\n }\r\n else {\r\n extraAttrs.push(key);\r\n }\r\n }\r\n if (extraAttrs.length) {\r\n warn(`Extraneous non-props attributes (` +\r\n `${extraAttrs.join(', ')}) ` +\r\n `were passed to component but could not be automatically inherited ` +\r\n `because component renders fragment or text root nodes.`);\r\n }\r\n if (eventAttrs.length) {\r\n warn(`Extraneous non-emits event listeners (` +\r\n `${eventAttrs.join(', ')}) ` +\r\n `were passed to component but could not be automatically inherited ` +\r\n `because component renders fragment or text root nodes. ` +\r\n `If the listener is intended to be a component custom event listener only, ` +\r\n `declare it using the \"emits\" option.`);\r\n }\r\n }\r\n }\r\n }\r\n // inherit directives\r\n if (vnode.dirs) {\r\n if ((process.env.NODE_ENV !== 'production') && !isElementRoot(root)) {\r\n warn(`Runtime directive used on component with non-element root node. ` +\r\n `The directives will not function as intended.`);\r\n }\r\n root.dirs = root.dirs ? root.dirs.concat(vnode.dirs) : vnode.dirs;\r\n }\r\n // inherit transition data\r\n if (vnode.transition) {\r\n if ((process.env.NODE_ENV !== 'production') && !isElementRoot(root)) {\r\n warn(`Component inside <Transition> renders non-element root node ` +\r\n `that cannot be animated.`);\r\n }\r\n root.transition = vnode.transition;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && setRoot) {\r\n setRoot(root);\r\n }\r\n else {\r\n result = root;\r\n }\r\n setCurrentRenderingInstance(prev);\r\n return result;\r\n}\r\n/**\r\n * dev only\r\n * In dev mode, template root level comments are rendered, which turns the\r\n * template into a fragment root, but we need to locate the single element\r\n * root for attrs and scope id processing.\r\n */\r\nconst getChildRoot = (vnode) => {\r\n const rawChildren = vnode.children;\r\n const dynamicChildren = vnode.dynamicChildren;\r\n const childRoot = filterSingleRoot(rawChildren);\r\n if (!childRoot) {\r\n return [vnode, undefined];\r\n }\r\n const index = rawChildren.indexOf(childRoot);\r\n const dynamicIndex = dynamicChildren ? dynamicChildren.indexOf(childRoot) : -1;\r\n const setRoot = (updatedRoot) => {\r\n rawChildren[index] = updatedRoot;\r\n if (dynamicChildren) {\r\n if (dynamicIndex > -1) {\r\n dynamicChildren[dynamicIndex] = updatedRoot;\r\n }\r\n else if (updatedRoot.patchFlag > 0) {\r\n vnode.dynamicChildren = [...dynamicChildren, updatedRoot];\r\n }\r\n }\r\n };\r\n return [normalizeVNode(childRoot), setRoot];\r\n};\r\nfunction filterSingleRoot(children) {\r\n let singleRoot;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (isVNode(child)) {\r\n // ignore user comment\r\n if (child.type !== Comment || child.children === 'v-if') {\r\n if (singleRoot) {\r\n // has more than 1 non-comment child, return now\r\n return;\r\n }\r\n else {\r\n singleRoot = child;\r\n }\r\n }\r\n }\r\n else {\r\n return;\r\n }\r\n }\r\n return singleRoot;\r\n}\r\nconst getFunctionalFallthrough = (attrs) => {\r\n let res;\r\n for (const key in attrs) {\r\n if (key === 'class' || key === 'style' || isOn(key)) {\r\n (res || (res = {}))[key] = attrs[key];\r\n }\r\n }\r\n return res;\r\n};\r\nconst filterModelListeners = (attrs, props) => {\r\n const res = {};\r\n for (const key in attrs) {\r\n if (!isModelListener(key) || !(key.slice(9) in props)) {\r\n res[key] = attrs[key];\r\n }\r\n }\r\n return res;\r\n};\r\nconst isElementRoot = (vnode) => {\r\n return (vnode.shapeFlag & (6 /* COMPONENT */ | 1 /* ELEMENT */) ||\r\n vnode.type === Comment // potential v-if branch switch\r\n );\r\n};\r\nfunction shouldUpdateComponent(prevVNode, nextVNode, optimized) {\r\n const { props: prevProps, children: prevChildren, component } = prevVNode;\r\n const { props: nextProps, children: nextChildren, patchFlag } = nextVNode;\r\n const emits = component.emitsOptions;\r\n // Parent component's render function was hot-updated. Since this may have\r\n // caused the child component's slots content to have changed, we need to\r\n // force the child to update as well.\r\n if ((process.env.NODE_ENV !== 'production') && (prevChildren || nextChildren) && isHmrUpdating) {\r\n return true;\r\n }\r\n // force child update for runtime directive or transition on component vnode.\r\n if (nextVNode.dirs || nextVNode.transition) {\r\n return true;\r\n }\r\n if (optimized && patchFlag >= 0) {\r\n if (patchFlag & 1024 /* DYNAMIC_SLOTS */) {\r\n // slot content that references values that might have changed,\r\n // e.g. in a v-for\r\n return true;\r\n }\r\n if (patchFlag & 16 /* FULL_PROPS */) {\r\n if (!prevProps) {\r\n return !!nextProps;\r\n }\r\n // presence of this flag indicates props are always non-null\r\n return hasPropsChanged(prevProps, nextProps, emits);\r\n }\r\n else if (patchFlag & 8 /* PROPS */) {\r\n const dynamicProps = nextVNode.dynamicProps;\r\n for (let i = 0; i < dynamicProps.length; i++) {\r\n const key = dynamicProps[i];\r\n if (nextProps[key] !== prevProps[key] &&\r\n !isEmitListener(emits, key)) {\r\n return true;\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // this path is only taken by manually written render functions\r\n // so presence of any children leads to a forced update\r\n if (prevChildren || nextChildren) {\r\n if (!nextChildren || !nextChildren.$stable) {\r\n return true;\r\n }\r\n }\r\n if (prevProps === nextProps) {\r\n return false;\r\n }\r\n if (!prevProps) {\r\n return !!nextProps;\r\n }\r\n if (!nextProps) {\r\n return true;\r\n }\r\n return hasPropsChanged(prevProps, nextProps, emits);\r\n }\r\n return false;\r\n}\r\nfunction hasPropsChanged(prevProps, nextProps, emitsOptions) {\r\n const nextKeys = Object.keys(nextProps);\r\n if (nextKeys.length !== Object.keys(prevProps).length) {\r\n return true;\r\n }\r\n for (let i = 0; i < nextKeys.length; i++) {\r\n const key = nextKeys[i];\r\n if (nextProps[key] !== prevProps[key] &&\r\n !isEmitListener(emitsOptions, key)) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n}\r\nfunction updateHOCHostEl({ vnode, parent }, el // HostNode\r\n) {\r\n while (parent && parent.subTree === vnode) {\r\n (vnode = parent.vnode).el = el;\r\n parent = parent.parent;\r\n }\r\n}\n\nconst isSuspense = (type) => type.__isSuspense;\r\n// Suspense exposes a component-like API, and is treated like a component\r\n// in the compiler, but internally it's a special built-in type that hooks\r\n// directly into the renderer.\r\nconst SuspenseImpl = {\r\n name: 'Suspense',\r\n // In order to make Suspense tree-shakable, we need to avoid importing it\r\n // directly in the renderer. The renderer checks for the __isSuspense flag\r\n // on a vnode's type and calls the `process` method, passing in renderer\r\n // internals.\r\n __isSuspense: true,\r\n process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, \r\n // platform-specific impl passed from renderer\r\n rendererInternals) {\r\n if (n1 == null) {\r\n mountSuspense(n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals);\r\n }\r\n else {\r\n patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotScopeIds, optimized, rendererInternals);\r\n }\r\n },\r\n hydrate: hydrateSuspense,\r\n create: createSuspenseBoundary,\r\n normalize: normalizeSuspenseChildren\r\n};\r\n// Force-casted public typing for h and TSX props inference\r\nconst Suspense = (SuspenseImpl );\r\nfunction triggerEvent(vnode, name) {\r\n const eventListener = vnode.props && vnode.props[name];\r\n if (isFunction(eventListener)) {\r\n eventListener();\r\n }\r\n}\r\nfunction mountSuspense(vnode, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals) {\r\n const { p: patch, o: { createElement } } = rendererInternals;\r\n const hiddenContainer = createElement('div');\r\n const suspense = (vnode.suspense = createSuspenseBoundary(vnode, parentSuspense, parentComponent, container, hiddenContainer, anchor, isSVG, slotScopeIds, optimized, rendererInternals));\r\n // start mounting the content subtree in an off-dom container\r\n patch(null, (suspense.pendingBranch = vnode.ssContent), hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds);\r\n // now check if we have encountered any async deps\r\n if (suspense.deps > 0) {\r\n // has async\r\n // invoke @fallback event\r\n triggerEvent(vnode, 'onPending');\r\n triggerEvent(vnode, 'onFallback');\r\n // mount the fallback tree\r\n patch(null, vnode.ssFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds);\r\n setActiveBranch(suspense, vnode.ssFallback);\r\n }\r\n else {\r\n // Suspense has no async deps. Just resolve.\r\n suspense.resolve();\r\n }\r\n}\r\nfunction patchSuspense(n1, n2, container, anchor, parentComponent, isSVG, slotScopeIds, optimized, { p: patch, um: unmount, o: { createElement } }) {\r\n const suspense = (n2.suspense = n1.suspense);\r\n suspense.vnode = n2;\r\n n2.el = n1.el;\r\n const newBranch = n2.ssContent;\r\n const newFallback = n2.ssFallback;\r\n const { activeBranch, pendingBranch, isInFallback, isHydrating } = suspense;\r\n if (pendingBranch) {\r\n suspense.pendingBranch = newBranch;\r\n if (isSameVNodeType(newBranch, pendingBranch)) {\r\n // same root type but content may have changed.\r\n patch(pendingBranch, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n suspense.resolve();\r\n }\r\n else if (isInFallback) {\r\n patch(activeBranch, newFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, newFallback);\r\n }\r\n }\r\n else {\r\n // toggled before pending tree is resolved\r\n suspense.pendingId++;\r\n if (isHydrating) {\r\n // if toggled before hydration is finished, the current DOM tree is\r\n // no longer valid. set it as the active branch so it will be unmounted\r\n // when resolved\r\n suspense.isHydrating = false;\r\n suspense.activeBranch = pendingBranch;\r\n }\r\n else {\r\n unmount(pendingBranch, parentComponent, suspense);\r\n }\r\n // increment pending ID. this is used to invalidate async callbacks\r\n // reset suspense state\r\n suspense.deps = 0;\r\n // discard effects from pending branch\r\n suspense.effects.length = 0;\r\n // discard previous container\r\n suspense.hiddenContainer = createElement('div');\r\n if (isInFallback) {\r\n // already in fallback state\r\n patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n suspense.resolve();\r\n }\r\n else {\r\n patch(activeBranch, newFallback, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, newFallback);\r\n }\r\n }\r\n else if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {\r\n // toggled \"back\" to current active branch\r\n patch(activeBranch, newBranch, container, anchor, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n // force resolve\r\n suspense.resolve(true);\r\n }\r\n else {\r\n // switched to a 3rd branch\r\n patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n suspense.resolve();\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n if (activeBranch && isSameVNodeType(newBranch, activeBranch)) {\r\n // root did not change, just normal patch\r\n patch(activeBranch, newBranch, container, anchor, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, newBranch);\r\n }\r\n else {\r\n // root node toggled\r\n // invoke @pending event\r\n triggerEvent(n2, 'onPending');\r\n // mount pending branch in off-dom container\r\n suspense.pendingBranch = newBranch;\r\n suspense.pendingId++;\r\n patch(null, newBranch, suspense.hiddenContainer, null, parentComponent, suspense, isSVG, slotScopeIds, optimized);\r\n if (suspense.deps <= 0) {\r\n // incoming branch has no async deps, resolve now.\r\n suspense.resolve();\r\n }\r\n else {\r\n const { timeout, pendingId } = suspense;\r\n if (timeout > 0) {\r\n setTimeout(() => {\r\n if (suspense.pendingId === pendingId) {\r\n suspense.fallback(newFallback);\r\n }\r\n }, timeout);\r\n }\r\n else if (timeout === 0) {\r\n suspense.fallback(newFallback);\r\n }\r\n }\r\n }\r\n }\r\n}\r\nlet hasWarned = false;\r\nfunction createSuspenseBoundary(vnode, parent, parentComponent, container, hiddenContainer, anchor, isSVG, slotScopeIds, optimized, rendererInternals, isHydrating = false) {\r\n /* istanbul ignore if */\r\n if ((process.env.NODE_ENV !== 'production') && !false && !hasWarned) {\r\n hasWarned = true;\r\n // @ts-ignore `console.info` cannot be null error\r\n console[console.info ? 'info' : 'log'](`<Suspense> is an experimental feature and its API will likely change.`);\r\n }\r\n const { p: patch, m: move, um: unmount, n: next, o: { parentNode, remove } } = rendererInternals;\r\n const timeout = toNumber(vnode.props && vnode.props.timeout);\r\n const suspense = {\r\n vnode,\r\n parent,\r\n parentComponent,\r\n isSVG,\r\n container,\r\n hiddenContainer,\r\n anchor,\r\n deps: 0,\r\n pendingId: 0,\r\n timeout: typeof timeout === 'number' ? timeout : -1,\r\n activeBranch: null,\r\n pendingBranch: null,\r\n isInFallback: true,\r\n isHydrating,\r\n isUnmounted: false,\r\n effects: [],\r\n resolve(resume = false) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (!resume && !suspense.pendingBranch) {\r\n throw new Error(`suspense.resolve() is called without a pending branch.`);\r\n }\r\n if (suspense.isUnmounted) {\r\n throw new Error(`suspense.resolve() is called on an already unmounted suspense boundary.`);\r\n }\r\n }\r\n const { vnode, activeBranch, pendingBranch, pendingId, effects, parentComponent, container } = suspense;\r\n if (suspense.isHydrating) {\r\n suspense.isHydrating = false;\r\n }\r\n else if (!resume) {\r\n const delayEnter = activeBranch &&\r\n pendingBranch.transition &&\r\n pendingBranch.transition.mode === 'out-in';\r\n if (delayEnter) {\r\n activeBranch.transition.afterLeave = () => {\r\n if (pendingId === suspense.pendingId) {\r\n move(pendingBranch, container, anchor, 0 /* ENTER */);\r\n }\r\n };\r\n }\r\n // this is initial anchor on mount\r\n let { anchor } = suspense;\r\n // unmount current active tree\r\n if (activeBranch) {\r\n // if the fallback tree was mounted, it may have been moved\r\n // as part of a parent suspense. get the latest anchor for insertion\r\n anchor = next(activeBranch);\r\n unmount(activeBranch, parentComponent, suspense, true);\r\n }\r\n if (!delayEnter) {\r\n // move content from off-dom container to actual container\r\n move(pendingBranch, container, anchor, 0 /* ENTER */);\r\n }\r\n }\r\n setActiveBranch(suspense, pendingBranch);\r\n suspense.pendingBranch = null;\r\n suspense.isInFallback = false;\r\n // flush buffered effects\r\n // check if there is a pending parent suspense\r\n let parent = suspense.parent;\r\n let hasUnresolvedAncestor = false;\r\n while (parent) {\r\n if (parent.pendingBranch) {\r\n // found a pending parent suspense, merge buffered post jobs\r\n // into that parent\r\n parent.effects.push(...effects);\r\n hasUnresolvedAncestor = true;\r\n break;\r\n }\r\n parent = parent.parent;\r\n }\r\n // no pending parent suspense, flush all jobs\r\n if (!hasUnresolvedAncestor) {\r\n queuePostFlushCb(effects);\r\n }\r\n suspense.effects = [];\r\n // invoke @resolve event\r\n triggerEvent(vnode, 'onResolve');\r\n },\r\n fallback(fallbackVNode) {\r\n if (!suspense.pendingBranch) {\r\n return;\r\n }\r\n const { vnode, activeBranch, parentComponent, container, isSVG } = suspense;\r\n // invoke @fallback event\r\n triggerEvent(vnode, 'onFallback');\r\n const anchor = next(activeBranch);\r\n const mountFallback = () => {\r\n if (!suspense.isInFallback) {\r\n return;\r\n }\r\n // mount the fallback tree\r\n patch(null, fallbackVNode, container, anchor, parentComponent, null, // fallback tree will not have suspense context\r\n isSVG, slotScopeIds, optimized);\r\n setActiveBranch(suspense, fallbackVNode);\r\n };\r\n const delayEnter = fallbackVNode.transition && fallbackVNode.transition.mode === 'out-in';\r\n if (delayEnter) {\r\n activeBranch.transition.afterLeave = mountFallback;\r\n }\r\n suspense.isInFallback = true;\r\n // unmount current active branch\r\n unmount(activeBranch, parentComponent, null, // no suspense so unmount hooks fire now\r\n true // shouldRemove\r\n );\r\n if (!delayEnter) {\r\n mountFallback();\r\n }\r\n },\r\n move(container, anchor, type) {\r\n suspense.activeBranch &&\r\n move(suspense.activeBranch, container, anchor, type);\r\n suspense.container = container;\r\n },\r\n next() {\r\n return suspense.activeBranch && next(suspense.activeBranch);\r\n },\r\n registerDep(instance, setupRenderEffect) {\r\n const isInPendingSuspense = !!suspense.pendingBranch;\r\n if (isInPendingSuspense) {\r\n suspense.deps++;\r\n }\r\n const hydratedEl = instance.vnode.el;\r\n instance\r\n .asyncDep.catch(err => {\r\n handleError(err, instance, 0 /* SETUP_FUNCTION */);\r\n })\r\n .then(asyncSetupResult => {\r\n // retry when the setup() promise resolves.\r\n // component may have been unmounted before resolve.\r\n if (instance.isUnmounted ||\r\n suspense.isUnmounted ||\r\n suspense.pendingId !== instance.suspenseId) {\r\n return;\r\n }\r\n // retry from this component\r\n instance.asyncResolved = true;\r\n const { vnode } = instance;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(vnode);\r\n }\r\n handleSetupResult(instance, asyncSetupResult, false);\r\n if (hydratedEl) {\r\n // vnode may have been replaced if an update happened before the\r\n // async dep is resolved.\r\n vnode.el = hydratedEl;\r\n }\r\n const placeholder = !hydratedEl && instance.subTree.el;\r\n setupRenderEffect(instance, vnode, \r\n // component may have been moved before resolve.\r\n // if this is not a hydration, instance.subTree will be the comment\r\n // placeholder.\r\n parentNode(hydratedEl || instance.subTree.el), \r\n // anchor will not be used if this is hydration, so only need to\r\n // consider the comment placeholder case.\r\n hydratedEl ? null : next(instance.subTree), suspense, isSVG, optimized);\r\n if (placeholder) {\r\n remove(placeholder);\r\n }\r\n updateHOCHostEl(instance, vnode.el);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n }\r\n // only decrease deps count if suspense is not already resolved\r\n if (isInPendingSuspense && --suspense.deps === 0) {\r\n suspense.resolve();\r\n }\r\n });\r\n },\r\n unmount(parentSuspense, doRemove) {\r\n suspense.isUnmounted = true;\r\n if (suspense.activeBranch) {\r\n unmount(suspense.activeBranch, parentComponent, parentSuspense, doRemove);\r\n }\r\n if (suspense.pendingBranch) {\r\n unmount(suspense.pendingBranch, parentComponent, parentSuspense, doRemove);\r\n }\r\n }\r\n };\r\n return suspense;\r\n}\r\nfunction hydrateSuspense(node, vnode, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, rendererInternals, hydrateNode) {\r\n /* eslint-disable no-restricted-globals */\r\n const suspense = (vnode.suspense = createSuspenseBoundary(vnode, parentSuspense, parentComponent, node.parentNode, document.createElement('div'), null, isSVG, slotScopeIds, optimized, rendererInternals, true /* hydrating */));\r\n // there are two possible scenarios for server-rendered suspense:\r\n // - success: ssr content should be fully resolved\r\n // - failure: ssr content should be the fallback branch.\r\n // however, on the client we don't really know if it has failed or not\r\n // attempt to hydrate the DOM assuming it has succeeded, but we still\r\n // need to construct a suspense boundary first\r\n const result = hydrateNode(node, (suspense.pendingBranch = vnode.ssContent), parentComponent, suspense, slotScopeIds, optimized);\r\n if (suspense.deps === 0) {\r\n suspense.resolve();\r\n }\r\n return result;\r\n /* eslint-enable no-restricted-globals */\r\n}\r\nfunction normalizeSuspenseChildren(vnode) {\r\n const { shapeFlag, children } = vnode;\r\n const isSlotChildren = shapeFlag & 32 /* SLOTS_CHILDREN */;\r\n vnode.ssContent = normalizeSuspenseSlot(isSlotChildren ? children.default : children);\r\n vnode.ssFallback = isSlotChildren\r\n ? normalizeSuspenseSlot(children.fallback)\r\n : createVNode(Comment);\r\n}\r\nfunction normalizeSuspenseSlot(s) {\r\n let block;\r\n if (isFunction(s)) {\r\n const trackBlock = isBlockTreeEnabled && s._c;\r\n if (trackBlock) {\r\n // disableTracking: false\r\n // allow block tracking for compiled slots\r\n // (see ./componentRenderContext.ts)\r\n s._d = false;\r\n openBlock();\r\n }\r\n s = s();\r\n if (trackBlock) {\r\n s._d = true;\r\n block = currentBlock;\r\n closeBlock();\r\n }\r\n }\r\n if (isArray(s)) {\r\n const singleChild = filterSingleRoot(s);\r\n if ((process.env.NODE_ENV !== 'production') && !singleChild) {\r\n warn(`<Suspense> slots expect a single root node.`);\r\n }\r\n s = singleChild;\r\n }\r\n s = normalizeVNode(s);\r\n if (block && !s.dynamicChildren) {\r\n s.dynamicChildren = block.filter(c => c !== s);\r\n }\r\n return s;\r\n}\r\nfunction queueEffectWithSuspense(fn, suspense) {\r\n if (suspense && suspense.pendingBranch) {\r\n if (isArray(fn)) {\r\n suspense.effects.push(...fn);\r\n }\r\n else {\r\n suspense.effects.push(fn);\r\n }\r\n }\r\n else {\r\n queuePostFlushCb(fn);\r\n }\r\n}\r\nfunction setActiveBranch(suspense, branch) {\r\n suspense.activeBranch = branch;\r\n const { vnode, parentComponent } = suspense;\r\n const el = (vnode.el = branch.el);\r\n // in case suspense is the root node of a component,\r\n // recursively update the HOC el\r\n if (parentComponent && parentComponent.subTree === vnode) {\r\n parentComponent.vnode.el = el;\r\n updateHOCHostEl(parentComponent, el);\r\n }\r\n}\n\nfunction provide(key, value) {\r\n if (!currentInstance) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`provide() can only be used inside setup().`);\r\n }\r\n }\r\n else {\r\n let provides = currentInstance.provides;\r\n // by default an instance inherits its parent's provides object\r\n // but when it needs to provide values of its own, it creates its\r\n // own provides object using parent provides object as prototype.\r\n // this way in `inject` we can simply look up injections from direct\r\n // parent and let the prototype chain do the work.\r\n const parentProvides = currentInstance.parent && currentInstance.parent.provides;\r\n if (parentProvides === provides) {\r\n provides = currentInstance.provides = Object.create(parentProvides);\r\n }\r\n // TS doesn't allow symbol as index type\r\n provides[key] = value;\r\n }\r\n}\r\nfunction inject(key, defaultValue, treatDefaultAsFactory = false) {\r\n // fallback to `currentRenderingInstance` so that this can be called in\r\n // a functional component\r\n const instance = currentInstance || currentRenderingInstance;\r\n if (instance) {\r\n // #2400\r\n // to support `app.use` plugins,\r\n // fallback to appContext's `provides` if the intance is at root\r\n const provides = instance.parent == null\r\n ? instance.vnode.appContext && instance.vnode.appContext.provides\r\n : instance.parent.provides;\r\n if (provides && key in provides) {\r\n // TS doesn't allow symbol as index type\r\n return provides[key];\r\n }\r\n else if (arguments.length > 1) {\r\n return treatDefaultAsFactory && isFunction(defaultValue)\r\n ? defaultValue.call(instance.proxy)\r\n : defaultValue;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`injection \"${String(key)}\" not found.`);\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`inject() can only be used inside setup() or functional components.`);\r\n }\r\n}\n\nfunction useTransitionState() {\r\n const state = {\r\n isMounted: false,\r\n isLeaving: false,\r\n isUnmounting: false,\r\n leavingVNodes: new Map()\r\n };\r\n onMounted(() => {\r\n state.isMounted = true;\r\n });\r\n onBeforeUnmount(() => {\r\n state.isUnmounting = true;\r\n });\r\n return state;\r\n}\r\nconst TransitionHookValidator = [Function, Array];\r\nconst BaseTransitionImpl = {\r\n name: `BaseTransition`,\r\n props: {\r\n mode: String,\r\n appear: Boolean,\r\n persisted: Boolean,\r\n // enter\r\n onBeforeEnter: TransitionHookValidator,\r\n onEnter: TransitionHookValidator,\r\n onAfterEnter: TransitionHookValidator,\r\n onEnterCancelled: TransitionHookValidator,\r\n // leave\r\n onBeforeLeave: TransitionHookValidator,\r\n onLeave: TransitionHookValidator,\r\n onAfterLeave: TransitionHookValidator,\r\n onLeaveCancelled: TransitionHookValidator,\r\n // appear\r\n onBeforeAppear: TransitionHookValidator,\r\n onAppear: TransitionHookValidator,\r\n onAfterAppear: TransitionHookValidator,\r\n onAppearCancelled: TransitionHookValidator\r\n },\r\n setup(props, { slots }) {\r\n const instance = getCurrentInstance();\r\n const state = useTransitionState();\r\n let prevTransitionKey;\r\n return () => {\r\n const children = slots.default && getTransitionRawChildren(slots.default(), true);\r\n if (!children || !children.length) {\r\n return;\r\n }\r\n // warn multiple elements\r\n if ((process.env.NODE_ENV !== 'production') && children.length > 1) {\r\n warn('<transition> can only be used on a single element or component. Use ' +\r\n '<transition-group> for lists.');\r\n }\r\n // there's no need to track reactivity for these props so use the raw\r\n // props for a bit better perf\r\n const rawProps = toRaw(props);\r\n const { mode } = rawProps;\r\n // check mode\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n mode &&\r\n mode !== 'in-out' && mode !== 'out-in' && mode !== 'default') {\r\n warn(`invalid <transition> mode: ${mode}`);\r\n }\r\n // at this point children has a guaranteed length of 1.\r\n const child = children[0];\r\n if (state.isLeaving) {\r\n return emptyPlaceholder(child);\r\n }\r\n // in the case of <transition><keep-alive/></transition>, we need to\r\n // compare the type of the kept-alive children.\r\n const innerChild = getKeepAliveChild(child);\r\n if (!innerChild) {\r\n return emptyPlaceholder(child);\r\n }\r\n const enterHooks = resolveTransitionHooks(innerChild, rawProps, state, instance);\r\n setTransitionHooks(innerChild, enterHooks);\r\n const oldChild = instance.subTree;\r\n const oldInnerChild = oldChild && getKeepAliveChild(oldChild);\r\n let transitionKeyChanged = false;\r\n const { getTransitionKey } = innerChild.type;\r\n if (getTransitionKey) {\r\n const key = getTransitionKey();\r\n if (prevTransitionKey === undefined) {\r\n prevTransitionKey = key;\r\n }\r\n else if (key !== prevTransitionKey) {\r\n prevTransitionKey = key;\r\n transitionKeyChanged = true;\r\n }\r\n }\r\n // handle mode\r\n if (oldInnerChild &&\r\n oldInnerChild.type !== Comment &&\r\n (!isSameVNodeType(innerChild, oldInnerChild) || transitionKeyChanged)) {\r\n const leavingHooks = resolveTransitionHooks(oldInnerChild, rawProps, state, instance);\r\n // update old tree's hooks in case of dynamic transition\r\n setTransitionHooks(oldInnerChild, leavingHooks);\r\n // switching between different views\r\n if (mode === 'out-in') {\r\n state.isLeaving = true;\r\n // return placeholder node and queue update when leave finishes\r\n leavingHooks.afterLeave = () => {\r\n state.isLeaving = false;\r\n instance.update();\r\n };\r\n return emptyPlaceholder(child);\r\n }\r\n else if (mode === 'in-out' && innerChild.type !== Comment) {\r\n leavingHooks.delayLeave = (el, earlyRemove, delayedLeave) => {\r\n const leavingVNodesCache = getLeavingNodesForType(state, oldInnerChild);\r\n leavingVNodesCache[String(oldInnerChild.key)] = oldInnerChild;\r\n // early removal callback\r\n el._leaveCb = () => {\r\n earlyRemove();\r\n el._leaveCb = undefined;\r\n delete enterHooks.delayedLeave;\r\n };\r\n enterHooks.delayedLeave = delayedLeave;\r\n };\r\n }\r\n }\r\n return child;\r\n };\r\n }\r\n};\r\n// export the public type for h/tsx inference\r\n// also to avoid inline import() in generated d.ts files\r\nconst BaseTransition = BaseTransitionImpl;\r\nfunction getLeavingNodesForType(state, vnode) {\r\n const { leavingVNodes } = state;\r\n let leavingVNodesCache = leavingVNodes.get(vnode.type);\r\n if (!leavingVNodesCache) {\r\n leavingVNodesCache = Object.create(null);\r\n leavingVNodes.set(vnode.type, leavingVNodesCache);\r\n }\r\n return leavingVNodesCache;\r\n}\r\n// The transition hooks are attached to the vnode as vnode.transition\r\n// and will be called at appropriate timing in the renderer.\r\nfunction resolveTransitionHooks(vnode, props, state, instance) {\r\n const { appear, mode, persisted = false, onBeforeEnter, onEnter, onAfterEnter, onEnterCancelled, onBeforeLeave, onLeave, onAfterLeave, onLeaveCancelled, onBeforeAppear, onAppear, onAfterAppear, onAppearCancelled } = props;\r\n const key = String(vnode.key);\r\n const leavingVNodesCache = getLeavingNodesForType(state, vnode);\r\n const callHook = (hook, args) => {\r\n hook &&\r\n callWithAsyncErrorHandling(hook, instance, 9 /* TRANSITION_HOOK */, args);\r\n };\r\n const hooks = {\r\n mode,\r\n persisted,\r\n beforeEnter(el) {\r\n let hook = onBeforeEnter;\r\n if (!state.isMounted) {\r\n if (appear) {\r\n hook = onBeforeAppear || onBeforeEnter;\r\n }\r\n else {\r\n return;\r\n }\r\n }\r\n // for same element (v-show)\r\n if (el._leaveCb) {\r\n el._leaveCb(true /* cancelled */);\r\n }\r\n // for toggled element with same key (v-if)\r\n const leavingVNode = leavingVNodesCache[key];\r\n if (leavingVNode &&\r\n isSameVNodeType(vnode, leavingVNode) &&\r\n leavingVNode.el._leaveCb) {\r\n // force early removal (not cancelled)\r\n leavingVNode.el._leaveCb();\r\n }\r\n callHook(hook, [el]);\r\n },\r\n enter(el) {\r\n let hook = onEnter;\r\n let afterHook = onAfterEnter;\r\n let cancelHook = onEnterCancelled;\r\n if (!state.isMounted) {\r\n if (appear) {\r\n hook = onAppear || onEnter;\r\n afterHook = onAfterAppear || onAfterEnter;\r\n cancelHook = onAppearCancelled || onEnterCancelled;\r\n }\r\n else {\r\n return;\r\n }\r\n }\r\n let called = false;\r\n const done = (el._enterCb = (cancelled) => {\r\n if (called)\r\n return;\r\n called = true;\r\n if (cancelled) {\r\n callHook(cancelHook, [el]);\r\n }\r\n else {\r\n callHook(afterHook, [el]);\r\n }\r\n if (hooks.delayedLeave) {\r\n hooks.delayedLeave();\r\n }\r\n el._enterCb = undefined;\r\n });\r\n if (hook) {\r\n hook(el, done);\r\n if (hook.length <= 1) {\r\n done();\r\n }\r\n }\r\n else {\r\n done();\r\n }\r\n },\r\n leave(el, remove) {\r\n const key = String(vnode.key);\r\n if (el._enterCb) {\r\n el._enterCb(true /* cancelled */);\r\n }\r\n if (state.isUnmounting) {\r\n return remove();\r\n }\r\n callHook(onBeforeLeave, [el]);\r\n let called = false;\r\n const done = (el._leaveCb = (cancelled) => {\r\n if (called)\r\n return;\r\n called = true;\r\n remove();\r\n if (cancelled) {\r\n callHook(onLeaveCancelled, [el]);\r\n }\r\n else {\r\n callHook(onAfterLeave, [el]);\r\n }\r\n el._leaveCb = undefined;\r\n if (leavingVNodesCache[key] === vnode) {\r\n delete leavingVNodesCache[key];\r\n }\r\n });\r\n leavingVNodesCache[key] = vnode;\r\n if (onLeave) {\r\n onLeave(el, done);\r\n if (onLeave.length <= 1) {\r\n done();\r\n }\r\n }\r\n else {\r\n done();\r\n }\r\n },\r\n clone(vnode) {\r\n return resolveTransitionHooks(vnode, props, state, instance);\r\n }\r\n };\r\n return hooks;\r\n}\r\n// the placeholder really only handles one special case: KeepAlive\r\n// in the case of a KeepAlive in a leave phase we need to return a KeepAlive\r\n// placeholder with empty content to avoid the KeepAlive instance from being\r\n// unmounted.\r\nfunction emptyPlaceholder(vnode) {\r\n if (isKeepAlive(vnode)) {\r\n vnode = cloneVNode(vnode);\r\n vnode.children = null;\r\n return vnode;\r\n }\r\n}\r\nfunction getKeepAliveChild(vnode) {\r\n return isKeepAlive(vnode)\r\n ? vnode.children\r\n ? vnode.children[0]\r\n : undefined\r\n : vnode;\r\n}\r\nfunction setTransitionHooks(vnode, hooks) {\r\n if (vnode.shapeFlag & 6 /* COMPONENT */ && vnode.component) {\r\n setTransitionHooks(vnode.component.subTree, hooks);\r\n }\r\n else if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n vnode.ssContent.transition = hooks.clone(vnode.ssContent);\r\n vnode.ssFallback.transition = hooks.clone(vnode.ssFallback);\r\n }\r\n else {\r\n vnode.transition = hooks;\r\n }\r\n}\r\nfunction getTransitionRawChildren(children, keepComment = false) {\r\n let ret = [];\r\n let keyedFragmentCount = 0;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n // handle fragment children case, e.g. v-for\r\n if (child.type === Fragment) {\r\n if (child.patchFlag & 128 /* KEYED_FRAGMENT */)\r\n keyedFragmentCount++;\r\n ret = ret.concat(getTransitionRawChildren(child.children, keepComment));\r\n }\r\n // comment placeholders should be skipped, e.g. v-if\r\n else if (keepComment || child.type !== Comment) {\r\n ret.push(child);\r\n }\r\n }\r\n // #1126 if a transition children list contains multiple sub fragments, these\r\n // fragments will be merged into a flat children array. Since each v-for\r\n // fragment may contain different static bindings inside, we need to de-op\r\n // these children to force full diffs to ensure correct behavior.\r\n if (keyedFragmentCount > 1) {\r\n for (let i = 0; i < ret.length; i++) {\r\n ret[i].patchFlag = -2 /* BAIL */;\r\n }\r\n }\r\n return ret;\r\n}\n\n// implementation, close to no-op\r\nfunction defineComponent(options) {\r\n return isFunction(options) ? { setup: options, name: options.name } : options;\r\n}\n\nconst isAsyncWrapper = (i) => !!i.type.__asyncLoader;\r\nfunction defineAsyncComponent(source) {\r\n if (isFunction(source)) {\r\n source = { loader: source };\r\n }\r\n const { loader, loadingComponent, errorComponent, delay = 200, timeout, // undefined = never times out\r\n suspensible = true, onError: userOnError } = source;\r\n let pendingRequest = null;\r\n let resolvedComp;\r\n let retries = 0;\r\n const retry = () => {\r\n retries++;\r\n pendingRequest = null;\r\n return load();\r\n };\r\n const load = () => {\r\n let thisRequest;\r\n return (pendingRequest ||\r\n (thisRequest = pendingRequest =\r\n loader()\r\n .catch(err => {\r\n err = err instanceof Error ? err : new Error(String(err));\r\n if (userOnError) {\r\n return new Promise((resolve, reject) => {\r\n const userRetry = () => resolve(retry());\r\n const userFail = () => reject(err);\r\n userOnError(err, userRetry, userFail, retries + 1);\r\n });\r\n }\r\n else {\r\n throw err;\r\n }\r\n })\r\n .then((comp) => {\r\n if (thisRequest !== pendingRequest && pendingRequest) {\r\n return pendingRequest;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && !comp) {\r\n warn(`Async component loader resolved to undefined. ` +\r\n `If you are using retry(), make sure to return its return value.`);\r\n }\r\n // interop module default\r\n if (comp &&\r\n (comp.__esModule || comp[Symbol.toStringTag] === 'Module')) {\r\n comp = comp.default;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && comp && !isObject(comp) && !isFunction(comp)) {\r\n throw new Error(`Invalid async component load result: ${comp}`);\r\n }\r\n resolvedComp = comp;\r\n return comp;\r\n })));\r\n };\r\n return defineComponent({\r\n name: 'AsyncComponentWrapper',\r\n __asyncLoader: load,\r\n get __asyncResolved() {\r\n return resolvedComp;\r\n },\r\n setup() {\r\n const instance = currentInstance;\r\n // already resolved\r\n if (resolvedComp) {\r\n return () => createInnerComp(resolvedComp, instance);\r\n }\r\n const onError = (err) => {\r\n pendingRequest = null;\r\n handleError(err, instance, 13 /* ASYNC_COMPONENT_LOADER */, !errorComponent /* do not throw in dev if user provided error component */);\r\n };\r\n // suspense-controlled or SSR.\r\n if ((suspensible && instance.suspense) ||\r\n (isInSSRComponentSetup)) {\r\n return load()\r\n .then(comp => {\r\n return () => createInnerComp(comp, instance);\r\n })\r\n .catch(err => {\r\n onError(err);\r\n return () => errorComponent\r\n ? createVNode(errorComponent, {\r\n error: err\r\n })\r\n : null;\r\n });\r\n }\r\n const loaded = ref(false);\r\n const error = ref();\r\n const delayed = ref(!!delay);\r\n if (delay) {\r\n setTimeout(() => {\r\n delayed.value = false;\r\n }, delay);\r\n }\r\n if (timeout != null) {\r\n setTimeout(() => {\r\n if (!loaded.value && !error.value) {\r\n const err = new Error(`Async component timed out after ${timeout}ms.`);\r\n onError(err);\r\n error.value = err;\r\n }\r\n }, timeout);\r\n }\r\n load()\r\n .then(() => {\r\n loaded.value = true;\r\n if (instance.parent && isKeepAlive(instance.parent.vnode)) {\r\n // parent is keep-alive, force update so the loaded component's\r\n // name is taken into account\r\n queueJob(instance.parent.update);\r\n }\r\n })\r\n .catch(err => {\r\n onError(err);\r\n error.value = err;\r\n });\r\n return () => {\r\n if (loaded.value && resolvedComp) {\r\n return createInnerComp(resolvedComp, instance);\r\n }\r\n else if (error.value && errorComponent) {\r\n return createVNode(errorComponent, {\r\n error: error.value\r\n });\r\n }\r\n else if (loadingComponent && !delayed.value) {\r\n return createVNode(loadingComponent);\r\n }\r\n };\r\n }\r\n });\r\n}\r\nfunction createInnerComp(comp, { vnode: { ref, props, children } }) {\r\n const vnode = createVNode(comp, props, children);\r\n // ensure inner component inherits the async wrapper's ref owner\r\n vnode.ref = ref;\r\n return vnode;\r\n}\n\nconst isKeepAlive = (vnode) => vnode.type.__isKeepAlive;\r\nconst KeepAliveImpl = {\r\n name: `KeepAlive`,\r\n // Marker for special handling inside the renderer. We are not using a ===\r\n // check directly on KeepAlive in the renderer, because importing it directly\r\n // would prevent it from being tree-shaken.\r\n __isKeepAlive: true,\r\n props: {\r\n include: [String, RegExp, Array],\r\n exclude: [String, RegExp, Array],\r\n max: [String, Number]\r\n },\r\n setup(props, { slots }) {\r\n const instance = getCurrentInstance();\r\n // KeepAlive communicates with the instantiated renderer via the\r\n // ctx where the renderer passes in its internals,\r\n // and the KeepAlive instance exposes activate/deactivate implementations.\r\n // The whole point of this is to avoid importing KeepAlive directly in the\r\n // renderer to facilitate tree-shaking.\r\n const sharedContext = instance.ctx;\r\n // if the internal renderer is not registered, it indicates that this is server-side rendering,\r\n // for KeepAlive, we just need to render its children\r\n if (!sharedContext.renderer) {\r\n return slots.default;\r\n }\r\n const cache = new Map();\r\n const keys = new Set();\r\n let current = null;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n instance.__v_cache = cache;\r\n }\r\n const parentSuspense = instance.suspense;\r\n const { renderer: { p: patch, m: move, um: _unmount, o: { createElement } } } = sharedContext;\r\n const storageContainer = createElement('div');\r\n sharedContext.activate = (vnode, container, anchor, isSVG, optimized) => {\r\n const instance = vnode.component;\r\n move(vnode, container, anchor, 0 /* ENTER */, parentSuspense);\r\n // in case props have changed\r\n patch(instance.vnode, vnode, container, anchor, instance, parentSuspense, isSVG, vnode.slotScopeIds, optimized);\r\n queuePostRenderEffect(() => {\r\n instance.isDeactivated = false;\r\n if (instance.a) {\r\n invokeArrayFns(instance.a);\r\n }\r\n const vnodeHook = vnode.props && vnode.props.onVnodeMounted;\r\n if (vnodeHook) {\r\n invokeVNodeHook(vnodeHook, instance.parent, vnode);\r\n }\r\n }, parentSuspense);\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n // Update components tree\r\n devtoolsComponentAdded(instance);\r\n }\r\n };\r\n sharedContext.deactivate = (vnode) => {\r\n const instance = vnode.component;\r\n move(vnode, storageContainer, null, 1 /* LEAVE */, parentSuspense);\r\n queuePostRenderEffect(() => {\r\n if (instance.da) {\r\n invokeArrayFns(instance.da);\r\n }\r\n const vnodeHook = vnode.props && vnode.props.onVnodeUnmounted;\r\n if (vnodeHook) {\r\n invokeVNodeHook(vnodeHook, instance.parent, vnode);\r\n }\r\n instance.isDeactivated = true;\r\n }, parentSuspense);\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n // Update components tree\r\n devtoolsComponentAdded(instance);\r\n }\r\n };\r\n function unmount(vnode) {\r\n // reset the shapeFlag so it can be properly unmounted\r\n resetShapeFlag(vnode);\r\n _unmount(vnode, instance, parentSuspense);\r\n }\r\n function pruneCache(filter) {\r\n cache.forEach((vnode, key) => {\r\n const name = getComponentName(vnode.type);\r\n if (name && (!filter || !filter(name))) {\r\n pruneCacheEntry(key);\r\n }\r\n });\r\n }\r\n function pruneCacheEntry(key) {\r\n const cached = cache.get(key);\r\n if (!current || cached.type !== current.type) {\r\n unmount(cached);\r\n }\r\n else if (current) {\r\n // current active instance should no longer be kept-alive.\r\n // we can't unmount it now but it might be later, so reset its flag now.\r\n resetShapeFlag(current);\r\n }\r\n cache.delete(key);\r\n keys.delete(key);\r\n }\r\n // prune cache on include/exclude prop change\r\n watch(() => [props.include, props.exclude], ([include, exclude]) => {\r\n include && pruneCache(name => matches(include, name));\r\n exclude && pruneCache(name => !matches(exclude, name));\r\n }, \r\n // prune post-render after `current` has been updated\r\n { flush: 'post', deep: true });\r\n // cache sub tree after render\r\n let pendingCacheKey = null;\r\n const cacheSubtree = () => {\r\n // fix #1621, the pendingCacheKey could be 0\r\n if (pendingCacheKey != null) {\r\n cache.set(pendingCacheKey, getInnerChild(instance.subTree));\r\n }\r\n };\r\n onMounted(cacheSubtree);\r\n onUpdated(cacheSubtree);\r\n onBeforeUnmount(() => {\r\n cache.forEach(cached => {\r\n const { subTree, suspense } = instance;\r\n const vnode = getInnerChild(subTree);\r\n if (cached.type === vnode.type) {\r\n // current instance will be unmounted as part of keep-alive's unmount\r\n resetShapeFlag(vnode);\r\n // but invoke its deactivated hook here\r\n const da = vnode.component.da;\r\n da && queuePostRenderEffect(da, suspense);\r\n return;\r\n }\r\n unmount(cached);\r\n });\r\n });\r\n return () => {\r\n pendingCacheKey = null;\r\n if (!slots.default) {\r\n return null;\r\n }\r\n const children = slots.default();\r\n const rawVNode = children[0];\r\n if (children.length > 1) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`KeepAlive should contain exactly one component child.`);\r\n }\r\n current = null;\r\n return children;\r\n }\r\n else if (!isVNode(rawVNode) ||\r\n (!(rawVNode.shapeFlag & 4 /* STATEFUL_COMPONENT */) &&\r\n !(rawVNode.shapeFlag & 128 /* SUSPENSE */))) {\r\n current = null;\r\n return rawVNode;\r\n }\r\n let vnode = getInnerChild(rawVNode);\r\n const comp = vnode.type;\r\n // for async components, name check should be based in its loaded\r\n // inner component if available\r\n const name = getComponentName(isAsyncWrapper(vnode)\r\n ? vnode.type.__asyncResolved || {}\r\n : comp);\r\n const { include, exclude, max } = props;\r\n if ((include && (!name || !matches(include, name))) ||\r\n (exclude && name && matches(exclude, name))) {\r\n current = vnode;\r\n return rawVNode;\r\n }\r\n const key = vnode.key == null ? comp : vnode.key;\r\n const cachedVNode = cache.get(key);\r\n // clone vnode if it's reused because we are going to mutate it\r\n if (vnode.el) {\r\n vnode = cloneVNode(vnode);\r\n if (rawVNode.shapeFlag & 128 /* SUSPENSE */) {\r\n rawVNode.ssContent = vnode;\r\n }\r\n }\r\n // #1513 it's possible for the returned vnode to be cloned due to attr\r\n // fallthrough or scopeId, so the vnode here may not be the final vnode\r\n // that is mounted. Instead of caching it directly, we store the pending\r\n // key and cache `instance.subTree` (the normalized vnode) in\r\n // beforeMount/beforeUpdate hooks.\r\n pendingCacheKey = key;\r\n if (cachedVNode) {\r\n // copy over mounted state\r\n vnode.el = cachedVNode.el;\r\n vnode.component = cachedVNode.component;\r\n if (vnode.transition) {\r\n // recursively update transition hooks on subTree\r\n setTransitionHooks(vnode, vnode.transition);\r\n }\r\n // avoid vnode being mounted as fresh\r\n vnode.shapeFlag |= 512 /* COMPONENT_KEPT_ALIVE */;\r\n // make this key the freshest\r\n keys.delete(key);\r\n keys.add(key);\r\n }\r\n else {\r\n keys.add(key);\r\n // prune oldest entry\r\n if (max && keys.size > parseInt(max, 10)) {\r\n pruneCacheEntry(keys.values().next().value);\r\n }\r\n }\r\n // avoid vnode being unmounted\r\n vnode.shapeFlag |= 256 /* COMPONENT_SHOULD_KEEP_ALIVE */;\r\n current = vnode;\r\n return rawVNode;\r\n };\r\n }\r\n};\r\n// export the public type for h/tsx inference\r\n// also to avoid inline import() in generated d.ts files\r\nconst KeepAlive = KeepAliveImpl;\r\nfunction matches(pattern, name) {\r\n if (isArray(pattern)) {\r\n return pattern.some((p) => matches(p, name));\r\n }\r\n else if (isString(pattern)) {\r\n return pattern.split(',').indexOf(name) > -1;\r\n }\r\n else if (pattern.test) {\r\n return pattern.test(name);\r\n }\r\n /* istanbul ignore next */\r\n return false;\r\n}\r\nfunction onActivated(hook, target) {\r\n registerKeepAliveHook(hook, \"a\" /* ACTIVATED */, target);\r\n}\r\nfunction onDeactivated(hook, target) {\r\n registerKeepAliveHook(hook, \"da\" /* DEACTIVATED */, target);\r\n}\r\nfunction registerKeepAliveHook(hook, type, target = currentInstance) {\r\n // cache the deactivate branch check wrapper for injected hooks so the same\r\n // hook can be properly deduped by the scheduler. \"__wdc\" stands for \"with\r\n // deactivation check\".\r\n const wrappedHook = hook.__wdc ||\r\n (hook.__wdc = () => {\r\n // only fire the hook if the target instance is NOT in a deactivated branch.\r\n let current = target;\r\n while (current) {\r\n if (current.isDeactivated) {\r\n return;\r\n }\r\n current = current.parent;\r\n }\r\n return hook();\r\n });\r\n injectHook(type, wrappedHook, target);\r\n // In addition to registering it on the target instance, we walk up the parent\r\n // chain and register it on all ancestor instances that are keep-alive roots.\r\n // This avoids the need to walk the entire component tree when invoking these\r\n // hooks, and more importantly, avoids the need to track child components in\r\n // arrays.\r\n if (target) {\r\n let current = target.parent;\r\n while (current && current.parent) {\r\n if (isKeepAlive(current.parent.vnode)) {\r\n injectToKeepAliveRoot(wrappedHook, type, target, current);\r\n }\r\n current = current.parent;\r\n }\r\n }\r\n}\r\nfunction injectToKeepAliveRoot(hook, type, target, keepAliveRoot) {\r\n // injectHook wraps the original for error handling, so make sure to remove\r\n // the wrapped version.\r\n const injected = injectHook(type, hook, keepAliveRoot, true /* prepend */);\r\n onUnmounted(() => {\r\n remove(keepAliveRoot[type], injected);\r\n }, target);\r\n}\r\nfunction resetShapeFlag(vnode) {\r\n let shapeFlag = vnode.shapeFlag;\r\n if (shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */) {\r\n shapeFlag -= 256 /* COMPONENT_SHOULD_KEEP_ALIVE */;\r\n }\r\n if (shapeFlag & 512 /* COMPONENT_KEPT_ALIVE */) {\r\n shapeFlag -= 512 /* COMPONENT_KEPT_ALIVE */;\r\n }\r\n vnode.shapeFlag = shapeFlag;\r\n}\r\nfunction getInnerChild(vnode) {\r\n return vnode.shapeFlag & 128 /* SUSPENSE */ ? vnode.ssContent : vnode;\r\n}\n\nfunction injectHook(type, hook, target = currentInstance, prepend = false) {\r\n if (target) {\r\n const hooks = target[type] || (target[type] = []);\r\n // cache the error handling wrapper for injected hooks so the same hook\r\n // can be properly deduped by the scheduler. \"__weh\" stands for \"with error\r\n // handling\".\r\n const wrappedHook = hook.__weh ||\r\n (hook.__weh = (...args) => {\r\n if (target.isUnmounted) {\r\n return;\r\n }\r\n // disable tracking inside all lifecycle hooks\r\n // since they can potentially be called inside effects.\r\n pauseTracking();\r\n // Set currentInstance during hook invocation.\r\n // This assumes the hook does not synchronously trigger other hooks, which\r\n // can only be false when the user does something really funky.\r\n setCurrentInstance(target);\r\n const res = callWithAsyncErrorHandling(hook, target, type, args);\r\n unsetCurrentInstance();\r\n resetTracking();\r\n return res;\r\n });\r\n if (prepend) {\r\n hooks.unshift(wrappedHook);\r\n }\r\n else {\r\n hooks.push(wrappedHook);\r\n }\r\n return wrappedHook;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n const apiName = toHandlerKey(ErrorTypeStrings[type].replace(/ hook$/, ''));\r\n warn(`${apiName} is called when there is no active component instance to be ` +\r\n `associated with. ` +\r\n `Lifecycle injection APIs can only be used during execution of setup().` +\r\n (` If you are using async setup(), make sure to register lifecycle ` +\r\n `hooks before the first await statement.`\r\n ));\r\n }\r\n}\r\nconst createHook = (lifecycle) => (hook, target = currentInstance) => \r\n// post-create lifecycle registrations are noops during SSR (except for serverPrefetch)\r\n(!isInSSRComponentSetup || lifecycle === \"sp\" /* SERVER_PREFETCH */) &&\r\n injectHook(lifecycle, hook, target);\r\nconst onBeforeMount = createHook(\"bm\" /* BEFORE_MOUNT */);\r\nconst onMounted = createHook(\"m\" /* MOUNTED */);\r\nconst onBeforeUpdate = createHook(\"bu\" /* BEFORE_UPDATE */);\r\nconst onUpdated = createHook(\"u\" /* UPDATED */);\r\nconst onBeforeUnmount = createHook(\"bum\" /* BEFORE_UNMOUNT */);\r\nconst onUnmounted = createHook(\"um\" /* UNMOUNTED */);\r\nconst onServerPrefetch = createHook(\"sp\" /* SERVER_PREFETCH */);\r\nconst onRenderTriggered = createHook(\"rtg\" /* RENDER_TRIGGERED */);\r\nconst onRenderTracked = createHook(\"rtc\" /* RENDER_TRACKED */);\r\nfunction onErrorCaptured(hook, target = currentInstance) {\r\n injectHook(\"ec\" /* ERROR_CAPTURED */, hook, target);\r\n}\n\nfunction createDuplicateChecker() {\r\n const cache = Object.create(null);\r\n return (type, key) => {\r\n if (cache[key]) {\r\n warn(`${type} property \"${key}\" is already defined in ${cache[key]}.`);\r\n }\r\n else {\r\n cache[key] = type;\r\n }\r\n };\r\n}\r\nlet shouldCacheAccess = true;\r\nfunction applyOptions(instance) {\r\n const options = resolveMergedOptions(instance);\r\n const publicThis = instance.proxy;\r\n const ctx = instance.ctx;\r\n // do not cache property access on public proxy during state initialization\r\n shouldCacheAccess = false;\r\n // call beforeCreate first before accessing other options since\r\n // the hook may mutate resolved options (#2791)\r\n if (options.beforeCreate) {\r\n callHook(options.beforeCreate, instance, \"bc\" /* BEFORE_CREATE */);\r\n }\r\n const { \r\n // state\r\n data: dataOptions, computed: computedOptions, methods, watch: watchOptions, provide: provideOptions, inject: injectOptions, \r\n // lifecycle\r\n created, beforeMount, mounted, beforeUpdate, updated, activated, deactivated, beforeDestroy, beforeUnmount, destroyed, unmounted, render, renderTracked, renderTriggered, errorCaptured, serverPrefetch, \r\n // public API\r\n expose, inheritAttrs, \r\n // assets\r\n components, directives, filters } = options;\r\n const checkDuplicateProperties = (process.env.NODE_ENV !== 'production') ? createDuplicateChecker() : null;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const [propsOptions] = instance.propsOptions;\r\n if (propsOptions) {\r\n for (const key in propsOptions) {\r\n checkDuplicateProperties(\"Props\" /* PROPS */, key);\r\n }\r\n }\r\n }\r\n // options initialization order (to be consistent with Vue 2):\r\n // - props (already done outside of this function)\r\n // - inject\r\n // - methods\r\n // - data (deferred since it relies on `this` access)\r\n // - computed\r\n // - watch (deferred since it relies on `this` access)\r\n if (injectOptions) {\r\n resolveInjections(injectOptions, ctx, checkDuplicateProperties, instance.appContext.config.unwrapInjectedRef);\r\n }\r\n if (methods) {\r\n for (const key in methods) {\r\n const methodHandler = methods[key];\r\n if (isFunction(methodHandler)) {\r\n // In dev mode, we use the `createRenderContext` function to define\r\n // methods to the proxy target, and those are read-only but\r\n // reconfigurable, so it needs to be redefined here\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n Object.defineProperty(ctx, key, {\r\n value: methodHandler.bind(publicThis),\r\n configurable: true,\r\n enumerable: true,\r\n writable: true\r\n });\r\n }\r\n else {\r\n ctx[key] = methodHandler.bind(publicThis);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n checkDuplicateProperties(\"Methods\" /* METHODS */, key);\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Method \"${key}\" has type \"${typeof methodHandler}\" in the component definition. ` +\r\n `Did you reference the function correctly?`);\r\n }\r\n }\r\n }\r\n if (dataOptions) {\r\n if ((process.env.NODE_ENV !== 'production') && !isFunction(dataOptions)) {\r\n warn(`The data option must be a function. ` +\r\n `Plain object usage is no longer supported.`);\r\n }\r\n const data = dataOptions.call(publicThis, publicThis);\r\n if ((process.env.NODE_ENV !== 'production') && isPromise(data)) {\r\n warn(`data() returned a Promise - note data() cannot be async; If you ` +\r\n `intend to perform data fetching before component renders, use ` +\r\n `async setup() + <Suspense>.`);\r\n }\r\n if (!isObject(data)) {\r\n (process.env.NODE_ENV !== 'production') && warn(`data() should return an object.`);\r\n }\r\n else {\r\n instance.data = reactive(data);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n for (const key in data) {\r\n checkDuplicateProperties(\"Data\" /* DATA */, key);\r\n // expose data on ctx during dev\r\n if (key[0] !== '$' && key[0] !== '_') {\r\n Object.defineProperty(ctx, key, {\r\n configurable: true,\r\n enumerable: true,\r\n get: () => data[key],\r\n set: NOOP\r\n });\r\n }\r\n }\r\n }\r\n }\r\n }\r\n // state initialization complete at this point - start caching access\r\n shouldCacheAccess = true;\r\n if (computedOptions) {\r\n for (const key in computedOptions) {\r\n const opt = computedOptions[key];\r\n const get = isFunction(opt)\r\n ? opt.bind(publicThis, publicThis)\r\n : isFunction(opt.get)\r\n ? opt.get.bind(publicThis, publicThis)\r\n : NOOP;\r\n if ((process.env.NODE_ENV !== 'production') && get === NOOP) {\r\n warn(`Computed property \"${key}\" has no getter.`);\r\n }\r\n const set = !isFunction(opt) && isFunction(opt.set)\r\n ? opt.set.bind(publicThis)\r\n : (process.env.NODE_ENV !== 'production')\r\n ? () => {\r\n warn(`Write operation failed: computed property \"${key}\" is readonly.`);\r\n }\r\n : NOOP;\r\n const c = computed({\r\n get,\r\n set\r\n });\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => c.value,\r\n set: v => (c.value = v)\r\n });\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n checkDuplicateProperties(\"Computed\" /* COMPUTED */, key);\r\n }\r\n }\r\n }\r\n if (watchOptions) {\r\n for (const key in watchOptions) {\r\n createWatcher(watchOptions[key], ctx, publicThis, key);\r\n }\r\n }\r\n if (provideOptions) {\r\n const provides = isFunction(provideOptions)\r\n ? provideOptions.call(publicThis)\r\n : provideOptions;\r\n Reflect.ownKeys(provides).forEach(key => {\r\n provide(key, provides[key]);\r\n });\r\n }\r\n if (created) {\r\n callHook(created, instance, \"c\" /* CREATED */);\r\n }\r\n function registerLifecycleHook(register, hook) {\r\n if (isArray(hook)) {\r\n hook.forEach(_hook => register(_hook.bind(publicThis)));\r\n }\r\n else if (hook) {\r\n register(hook.bind(publicThis));\r\n }\r\n }\r\n registerLifecycleHook(onBeforeMount, beforeMount);\r\n registerLifecycleHook(onMounted, mounted);\r\n registerLifecycleHook(onBeforeUpdate, beforeUpdate);\r\n registerLifecycleHook(onUpdated, updated);\r\n registerLifecycleHook(onActivated, activated);\r\n registerLifecycleHook(onDeactivated, deactivated);\r\n registerLifecycleHook(onErrorCaptured, errorCaptured);\r\n registerLifecycleHook(onRenderTracked, renderTracked);\r\n registerLifecycleHook(onRenderTriggered, renderTriggered);\r\n registerLifecycleHook(onBeforeUnmount, beforeUnmount);\r\n registerLifecycleHook(onUnmounted, unmounted);\r\n registerLifecycleHook(onServerPrefetch, serverPrefetch);\r\n if (isArray(expose)) {\r\n if (expose.length) {\r\n const exposed = instance.exposed || (instance.exposed = {});\r\n expose.forEach(key => {\r\n Object.defineProperty(exposed, key, {\r\n get: () => publicThis[key],\r\n set: val => (publicThis[key] = val)\r\n });\r\n });\r\n }\r\n else if (!instance.exposed) {\r\n instance.exposed = {};\r\n }\r\n }\r\n // options that are handled when creating the instance but also need to be\r\n // applied from mixins\r\n if (render && instance.render === NOOP) {\r\n instance.render = render;\r\n }\r\n if (inheritAttrs != null) {\r\n instance.inheritAttrs = inheritAttrs;\r\n }\r\n // asset options.\r\n if (components)\r\n instance.components = components;\r\n if (directives)\r\n instance.directives = directives;\r\n}\r\nfunction resolveInjections(injectOptions, ctx, checkDuplicateProperties = NOOP, unwrapRef = false) {\r\n if (isArray(injectOptions)) {\r\n injectOptions = normalizeInject(injectOptions);\r\n }\r\n for (const key in injectOptions) {\r\n const opt = injectOptions[key];\r\n let injected;\r\n if (isObject(opt)) {\r\n if ('default' in opt) {\r\n injected = inject(opt.from || key, opt.default, true /* treat default function as factory */);\r\n }\r\n else {\r\n injected = inject(opt.from || key);\r\n }\r\n }\r\n else {\r\n injected = inject(opt);\r\n }\r\n if (isRef(injected)) {\r\n // TODO remove the check in 3.3\r\n if (unwrapRef) {\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => injected.value,\r\n set: v => (injected.value = v)\r\n });\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`injected property \"${key}\" is a ref and will be auto-unwrapped ` +\r\n `and no longer needs \\`.value\\` in the next minor release. ` +\r\n `To opt-in to the new behavior now, ` +\r\n `set \\`app.config.unwrapInjectedRef = true\\` (this config is ` +\r\n `temporary and will not be needed in the future.)`);\r\n }\r\n ctx[key] = injected;\r\n }\r\n }\r\n else {\r\n ctx[key] = injected;\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n checkDuplicateProperties(\"Inject\" /* INJECT */, key);\r\n }\r\n }\r\n}\r\nfunction callHook(hook, instance, type) {\r\n callWithAsyncErrorHandling(isArray(hook)\r\n ? hook.map(h => h.bind(instance.proxy))\r\n : hook.bind(instance.proxy), instance, type);\r\n}\r\nfunction createWatcher(raw, ctx, publicThis, key) {\r\n const getter = key.includes('.')\r\n ? createPathGetter(publicThis, key)\r\n : () => publicThis[key];\r\n if (isString(raw)) {\r\n const handler = ctx[raw];\r\n if (isFunction(handler)) {\r\n watch(getter, handler);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid watch handler specified by key \"${raw}\"`, handler);\r\n }\r\n }\r\n else if (isFunction(raw)) {\r\n watch(getter, raw.bind(publicThis));\r\n }\r\n else if (isObject(raw)) {\r\n if (isArray(raw)) {\r\n raw.forEach(r => createWatcher(r, ctx, publicThis, key));\r\n }\r\n else {\r\n const handler = isFunction(raw.handler)\r\n ? raw.handler.bind(publicThis)\r\n : ctx[raw.handler];\r\n if (isFunction(handler)) {\r\n watch(getter, handler, raw);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid watch handler specified by key \"${raw.handler}\"`, handler);\r\n }\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid watch option: \"${key}\"`, raw);\r\n }\r\n}\r\n/**\r\n * Resolve merged options and cache it on the component.\r\n * This is done only once per-component since the merging does not involve\r\n * instances.\r\n */\r\nfunction resolveMergedOptions(instance) {\r\n const base = instance.type;\r\n const { mixins, extends: extendsOptions } = base;\r\n const { mixins: globalMixins, optionsCache: cache, config: { optionMergeStrategies } } = instance.appContext;\r\n const cached = cache.get(base);\r\n let resolved;\r\n if (cached) {\r\n resolved = cached;\r\n }\r\n else if (!globalMixins.length && !mixins && !extendsOptions) {\r\n {\r\n resolved = base;\r\n }\r\n }\r\n else {\r\n resolved = {};\r\n if (globalMixins.length) {\r\n globalMixins.forEach(m => mergeOptions(resolved, m, optionMergeStrategies, true));\r\n }\r\n mergeOptions(resolved, base, optionMergeStrategies);\r\n }\r\n cache.set(base, resolved);\r\n return resolved;\r\n}\r\nfunction mergeOptions(to, from, strats, asMixin = false) {\r\n const { mixins, extends: extendsOptions } = from;\r\n if (extendsOptions) {\r\n mergeOptions(to, extendsOptions, strats, true);\r\n }\r\n if (mixins) {\r\n mixins.forEach((m) => mergeOptions(to, m, strats, true));\r\n }\r\n for (const key in from) {\r\n if (asMixin && key === 'expose') {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`\"expose\" option is ignored when declared in mixins or extends. ` +\r\n `It should only be declared in the base component itself.`);\r\n }\r\n else {\r\n const strat = internalOptionMergeStrats[key] || (strats && strats[key]);\r\n to[key] = strat ? strat(to[key], from[key]) : from[key];\r\n }\r\n }\r\n return to;\r\n}\r\nconst internalOptionMergeStrats = {\r\n data: mergeDataFn,\r\n props: mergeObjectOptions,\r\n emits: mergeObjectOptions,\r\n // objects\r\n methods: mergeObjectOptions,\r\n computed: mergeObjectOptions,\r\n // lifecycle\r\n beforeCreate: mergeAsArray,\r\n created: mergeAsArray,\r\n beforeMount: mergeAsArray,\r\n mounted: mergeAsArray,\r\n beforeUpdate: mergeAsArray,\r\n updated: mergeAsArray,\r\n beforeDestroy: mergeAsArray,\r\n beforeUnmount: mergeAsArray,\r\n destroyed: mergeAsArray,\r\n unmounted: mergeAsArray,\r\n activated: mergeAsArray,\r\n deactivated: mergeAsArray,\r\n errorCaptured: mergeAsArray,\r\n serverPrefetch: mergeAsArray,\r\n // assets\r\n components: mergeObjectOptions,\r\n directives: mergeObjectOptions,\r\n // watch\r\n watch: mergeWatchOptions,\r\n // provide / inject\r\n provide: mergeDataFn,\r\n inject: mergeInject\r\n};\r\nfunction mergeDataFn(to, from) {\r\n if (!from) {\r\n return to;\r\n }\r\n if (!to) {\r\n return from;\r\n }\r\n return function mergedDataFn() {\r\n return (extend)(isFunction(to) ? to.call(this, this) : to, isFunction(from) ? from.call(this, this) : from);\r\n };\r\n}\r\nfunction mergeInject(to, from) {\r\n return mergeObjectOptions(normalizeInject(to), normalizeInject(from));\r\n}\r\nfunction normalizeInject(raw) {\r\n if (isArray(raw)) {\r\n const res = {};\r\n for (let i = 0; i < raw.length; i++) {\r\n res[raw[i]] = raw[i];\r\n }\r\n return res;\r\n }\r\n return raw;\r\n}\r\nfunction mergeAsArray(to, from) {\r\n return to ? [...new Set([].concat(to, from))] : from;\r\n}\r\nfunction mergeObjectOptions(to, from) {\r\n return to ? extend(extend(Object.create(null), to), from) : from;\r\n}\r\nfunction mergeWatchOptions(to, from) {\r\n if (!to)\r\n return from;\r\n if (!from)\r\n return to;\r\n const merged = extend(Object.create(null), to);\r\n for (const key in from) {\r\n merged[key] = mergeAsArray(to[key], from[key]);\r\n }\r\n return merged;\r\n}\n\nfunction initProps(instance, rawProps, isStateful, // result of bitwise flag comparison\r\nisSSR = false) {\r\n const props = {};\r\n const attrs = {};\r\n def(attrs, InternalObjectKey, 1);\r\n instance.propsDefaults = Object.create(null);\r\n setFullProps(instance, rawProps, props, attrs);\r\n // ensure all declared prop keys are present\r\n for (const key in instance.propsOptions[0]) {\r\n if (!(key in props)) {\r\n props[key] = undefined;\r\n }\r\n }\r\n // validation\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateProps(rawProps || {}, props, instance);\r\n }\r\n if (isStateful) {\r\n // stateful\r\n instance.props = isSSR ? props : shallowReactive(props);\r\n }\r\n else {\r\n if (!instance.type.props) {\r\n // functional w/ optional props, props === attrs\r\n instance.props = attrs;\r\n }\r\n else {\r\n // functional w/ declared props\r\n instance.props = props;\r\n }\r\n }\r\n instance.attrs = attrs;\r\n}\r\nfunction updateProps(instance, rawProps, rawPrevProps, optimized) {\r\n const { props, attrs, vnode: { patchFlag } } = instance;\r\n const rawCurrentProps = toRaw(props);\r\n const [options] = instance.propsOptions;\r\n let hasAttrsChanged = false;\r\n if (\r\n // always force full diff in dev\r\n // - #1942 if hmr is enabled with sfc component\r\n // - vite#872 non-sfc component used by sfc component\r\n !((process.env.NODE_ENV !== 'production') &&\r\n (instance.type.__hmrId ||\r\n (instance.parent && instance.parent.type.__hmrId))) &&\r\n (optimized || patchFlag > 0) &&\r\n !(patchFlag & 16 /* FULL_PROPS */)) {\r\n if (patchFlag & 8 /* PROPS */) {\r\n // Compiler-generated props & no keys change, just set the updated\r\n // the props.\r\n const propsToUpdate = instance.vnode.dynamicProps;\r\n for (let i = 0; i < propsToUpdate.length; i++) {\r\n let key = propsToUpdate[i];\r\n // PROPS flag guarantees rawProps to be non-null\r\n const value = rawProps[key];\r\n if (options) {\r\n // attr / props separation was done on init and will be consistent\r\n // in this code path, so just check if attrs have it.\r\n if (hasOwn(attrs, key)) {\r\n if (value !== attrs[key]) {\r\n attrs[key] = value;\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n else {\r\n const camelizedKey = camelize(key);\r\n props[camelizedKey] = resolvePropValue(options, rawCurrentProps, camelizedKey, value, instance, false /* isAbsent */);\r\n }\r\n }\r\n else {\r\n if (value !== attrs[key]) {\r\n attrs[key] = value;\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n // full props update.\r\n if (setFullProps(instance, rawProps, props, attrs)) {\r\n hasAttrsChanged = true;\r\n }\r\n // in case of dynamic props, check if we need to delete keys from\r\n // the props object\r\n let kebabKey;\r\n for (const key in rawCurrentProps) {\r\n if (!rawProps ||\r\n // for camelCase\r\n (!hasOwn(rawProps, key) &&\r\n // it's possible the original props was passed in as kebab-case\r\n // and converted to camelCase (#955)\r\n ((kebabKey = hyphenate(key)) === key || !hasOwn(rawProps, kebabKey)))) {\r\n if (options) {\r\n if (rawPrevProps &&\r\n // for camelCase\r\n (rawPrevProps[key] !== undefined ||\r\n // for kebab-case\r\n rawPrevProps[kebabKey] !== undefined)) {\r\n props[key] = resolvePropValue(options, rawCurrentProps, key, undefined, instance, true /* isAbsent */);\r\n }\r\n }\r\n else {\r\n delete props[key];\r\n }\r\n }\r\n }\r\n // in the case of functional component w/o props declaration, props and\r\n // attrs point to the same object so it should already have been updated.\r\n if (attrs !== rawCurrentProps) {\r\n for (const key in attrs) {\r\n if (!rawProps || !hasOwn(rawProps, key)) {\r\n delete attrs[key];\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n }\r\n }\r\n // trigger updates for $attrs in case it's used in component slots\r\n if (hasAttrsChanged) {\r\n trigger(instance, \"set\" /* SET */, '$attrs');\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateProps(rawProps || {}, props, instance);\r\n }\r\n}\r\nfunction setFullProps(instance, rawProps, props, attrs) {\r\n const [options, needCastKeys] = instance.propsOptions;\r\n let hasAttrsChanged = false;\r\n let rawCastValues;\r\n if (rawProps) {\r\n for (let key in rawProps) {\r\n // key, ref are reserved and never passed down\r\n if (isReservedProp(key)) {\r\n continue;\r\n }\r\n const value = rawProps[key];\r\n // prop option names are camelized during normalization, so to support\r\n // kebab -> camel conversion here we need to camelize the key.\r\n let camelKey;\r\n if (options && hasOwn(options, (camelKey = camelize(key)))) {\r\n if (!needCastKeys || !needCastKeys.includes(camelKey)) {\r\n props[camelKey] = value;\r\n }\r\n else {\r\n (rawCastValues || (rawCastValues = {}))[camelKey] = value;\r\n }\r\n }\r\n else if (!isEmitListener(instance.emitsOptions, key)) {\r\n if (value !== attrs[key]) {\r\n attrs[key] = value;\r\n hasAttrsChanged = true;\r\n }\r\n }\r\n }\r\n }\r\n if (needCastKeys) {\r\n const rawCurrentProps = toRaw(props);\r\n const castValues = rawCastValues || EMPTY_OBJ;\r\n for (let i = 0; i < needCastKeys.length; i++) {\r\n const key = needCastKeys[i];\r\n props[key] = resolvePropValue(options, rawCurrentProps, key, castValues[key], instance, !hasOwn(castValues, key));\r\n }\r\n }\r\n return hasAttrsChanged;\r\n}\r\nfunction resolvePropValue(options, props, key, value, instance, isAbsent) {\r\n const opt = options[key];\r\n if (opt != null) {\r\n const hasDefault = hasOwn(opt, 'default');\r\n // default values\r\n if (hasDefault && value === undefined) {\r\n const defaultValue = opt.default;\r\n if (opt.type !== Function && isFunction(defaultValue)) {\r\n const { propsDefaults } = instance;\r\n if (key in propsDefaults) {\r\n value = propsDefaults[key];\r\n }\r\n else {\r\n setCurrentInstance(instance);\r\n value = propsDefaults[key] = defaultValue.call(null, props);\r\n unsetCurrentInstance();\r\n }\r\n }\r\n else {\r\n value = defaultValue;\r\n }\r\n }\r\n // boolean casting\r\n if (opt[0 /* shouldCast */]) {\r\n if (isAbsent && !hasDefault) {\r\n value = false;\r\n }\r\n else if (opt[1 /* shouldCastTrue */] &&\r\n (value === '' || value === hyphenate(key))) {\r\n value = true;\r\n }\r\n }\r\n }\r\n return value;\r\n}\r\nfunction normalizePropsOptions(comp, appContext, asMixin = false) {\r\n const cache = appContext.propsCache;\r\n const cached = cache.get(comp);\r\n if (cached) {\r\n return cached;\r\n }\r\n const raw = comp.props;\r\n const normalized = {};\r\n const needCastKeys = [];\r\n // apply mixin/extends props\r\n let hasExtends = false;\r\n if (__VUE_OPTIONS_API__ && !isFunction(comp)) {\r\n const extendProps = (raw) => {\r\n hasExtends = true;\r\n const [props, keys] = normalizePropsOptions(raw, appContext, true);\r\n extend(normalized, props);\r\n if (keys)\r\n needCastKeys.push(...keys);\r\n };\r\n if (!asMixin && appContext.mixins.length) {\r\n appContext.mixins.forEach(extendProps);\r\n }\r\n if (comp.extends) {\r\n extendProps(comp.extends);\r\n }\r\n if (comp.mixins) {\r\n comp.mixins.forEach(extendProps);\r\n }\r\n }\r\n if (!raw && !hasExtends) {\r\n cache.set(comp, EMPTY_ARR);\r\n return EMPTY_ARR;\r\n }\r\n if (isArray(raw)) {\r\n for (let i = 0; i < raw.length; i++) {\r\n if ((process.env.NODE_ENV !== 'production') && !isString(raw[i])) {\r\n warn(`props must be strings when using array syntax.`, raw[i]);\r\n }\r\n const normalizedKey = camelize(raw[i]);\r\n if (validatePropName(normalizedKey)) {\r\n normalized[normalizedKey] = EMPTY_OBJ;\r\n }\r\n }\r\n }\r\n else if (raw) {\r\n if ((process.env.NODE_ENV !== 'production') && !isObject(raw)) {\r\n warn(`invalid props options`, raw);\r\n }\r\n for (const key in raw) {\r\n const normalizedKey = camelize(key);\r\n if (validatePropName(normalizedKey)) {\r\n const opt = raw[key];\r\n const prop = (normalized[normalizedKey] =\r\n isArray(opt) || isFunction(opt) ? { type: opt } : opt);\r\n if (prop) {\r\n const booleanIndex = getTypeIndex(Boolean, prop.type);\r\n const stringIndex = getTypeIndex(String, prop.type);\r\n prop[0 /* shouldCast */] = booleanIndex > -1;\r\n prop[1 /* shouldCastTrue */] =\r\n stringIndex < 0 || booleanIndex < stringIndex;\r\n // if the prop needs boolean casting or default value\r\n if (booleanIndex > -1 || hasOwn(prop, 'default')) {\r\n needCastKeys.push(normalizedKey);\r\n }\r\n }\r\n }\r\n }\r\n }\r\n const res = [normalized, needCastKeys];\r\n cache.set(comp, res);\r\n return res;\r\n}\r\nfunction validatePropName(key) {\r\n if (key[0] !== '$') {\r\n return true;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Invalid prop name: \"${key}\" is a reserved property.`);\r\n }\r\n return false;\r\n}\r\n// use function string name to check type constructors\r\n// so that it works across vms / iframes.\r\nfunction getType(ctor) {\r\n const match = ctor && ctor.toString().match(/^\\s*function (\\w+)/);\r\n return match ? match[1] : ctor === null ? 'null' : '';\r\n}\r\nfunction isSameType(a, b) {\r\n return getType(a) === getType(b);\r\n}\r\nfunction getTypeIndex(type, expectedTypes) {\r\n if (isArray(expectedTypes)) {\r\n return expectedTypes.findIndex(t => isSameType(t, type));\r\n }\r\n else if (isFunction(expectedTypes)) {\r\n return isSameType(expectedTypes, type) ? 0 : -1;\r\n }\r\n return -1;\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction validateProps(rawProps, props, instance) {\r\n const resolvedValues = toRaw(props);\r\n const options = instance.propsOptions[0];\r\n for (const key in options) {\r\n let opt = options[key];\r\n if (opt == null)\r\n continue;\r\n validateProp(key, resolvedValues[key], opt, !hasOwn(rawProps, key) && !hasOwn(rawProps, hyphenate(key)));\r\n }\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction validateProp(name, value, prop, isAbsent) {\r\n const { type, required, validator } = prop;\r\n // required!\r\n if (required && isAbsent) {\r\n warn('Missing required prop: \"' + name + '\"');\r\n return;\r\n }\r\n // missing but optional\r\n if (value == null && !prop.required) {\r\n return;\r\n }\r\n // type check\r\n if (type != null && type !== true) {\r\n let isValid = false;\r\n const types = isArray(type) ? type : [type];\r\n const expectedTypes = [];\r\n // value is valid as long as one of the specified types match\r\n for (let i = 0; i < types.length && !isValid; i++) {\r\n const { valid, expectedType } = assertType(value, types[i]);\r\n expectedTypes.push(expectedType || '');\r\n isValid = valid;\r\n }\r\n if (!isValid) {\r\n warn(getInvalidTypeMessage(name, value, expectedTypes));\r\n return;\r\n }\r\n }\r\n // custom validator\r\n if (validator && !validator(value)) {\r\n warn('Invalid prop: custom validator check failed for prop \"' + name + '\".');\r\n }\r\n}\r\nconst isSimpleType = /*#__PURE__*/ makeMap('String,Number,Boolean,Function,Symbol,BigInt');\r\n/**\r\n * dev only\r\n */\r\nfunction assertType(value, type) {\r\n let valid;\r\n const expectedType = getType(type);\r\n if (isSimpleType(expectedType)) {\r\n const t = typeof value;\r\n valid = t === expectedType.toLowerCase();\r\n // for primitive wrapper objects\r\n if (!valid && t === 'object') {\r\n valid = value instanceof type;\r\n }\r\n }\r\n else if (expectedType === 'Object') {\r\n valid = isObject(value);\r\n }\r\n else if (expectedType === 'Array') {\r\n valid = isArray(value);\r\n }\r\n else if (expectedType === 'null') {\r\n valid = value === null;\r\n }\r\n else {\r\n valid = value instanceof type;\r\n }\r\n return {\r\n valid,\r\n expectedType\r\n };\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction getInvalidTypeMessage(name, value, expectedTypes) {\r\n let message = `Invalid prop: type check failed for prop \"${name}\".` +\r\n ` Expected ${expectedTypes.map(capitalize).join(' | ')}`;\r\n const expectedType = expectedTypes[0];\r\n const receivedType = toRawType(value);\r\n const expectedValue = styleValue(value, expectedType);\r\n const receivedValue = styleValue(value, receivedType);\r\n // check if we need to specify expected value\r\n if (expectedTypes.length === 1 &&\r\n isExplicable(expectedType) &&\r\n !isBoolean(expectedType, receivedType)) {\r\n message += ` with value ${expectedValue}`;\r\n }\r\n message += `, got ${receivedType} `;\r\n // check if we need to specify received value\r\n if (isExplicable(receivedType)) {\r\n message += `with value ${receivedValue}.`;\r\n }\r\n return message;\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction styleValue(value, type) {\r\n if (type === 'String') {\r\n return `\"${value}\"`;\r\n }\r\n else if (type === 'Number') {\r\n return `${Number(value)}`;\r\n }\r\n else {\r\n return `${value}`;\r\n }\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction isExplicable(type) {\r\n const explicitTypes = ['string', 'number', 'boolean'];\r\n return explicitTypes.some(elem => type.toLowerCase() === elem);\r\n}\r\n/**\r\n * dev only\r\n */\r\nfunction isBoolean(...args) {\r\n return args.some(elem => elem.toLowerCase() === 'boolean');\r\n}\n\nconst isInternalKey = (key) => key[0] === '_' || key === '$stable';\r\nconst normalizeSlotValue = (value) => isArray(value)\r\n ? value.map(normalizeVNode)\r\n : [normalizeVNode(value)];\r\nconst normalizeSlot = (key, rawSlot, ctx) => {\r\n const normalized = withCtx((...args) => {\r\n if ((process.env.NODE_ENV !== 'production') && currentInstance) {\r\n warn(`Slot \"${key}\" invoked outside of the render function: ` +\r\n `this will not track dependencies used in the slot. ` +\r\n `Invoke the slot function inside the render function instead.`);\r\n }\r\n return normalizeSlotValue(rawSlot(...args));\r\n }, ctx);\r\n normalized._c = false;\r\n return normalized;\r\n};\r\nconst normalizeObjectSlots = (rawSlots, slots, instance) => {\r\n const ctx = rawSlots._ctx;\r\n for (const key in rawSlots) {\r\n if (isInternalKey(key))\r\n continue;\r\n const value = rawSlots[key];\r\n if (isFunction(value)) {\r\n slots[key] = normalizeSlot(key, value, ctx);\r\n }\r\n else if (value != null) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n !(false )) {\r\n warn(`Non-function value encountered for slot \"${key}\". ` +\r\n `Prefer function slots for better performance.`);\r\n }\r\n const normalized = normalizeSlotValue(value);\r\n slots[key] = () => normalized;\r\n }\r\n }\r\n};\r\nconst normalizeVNodeSlots = (instance, children) => {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n !isKeepAlive(instance.vnode) &&\r\n !(false )) {\r\n warn(`Non-function value encountered for default slot. ` +\r\n `Prefer function slots for better performance.`);\r\n }\r\n const normalized = normalizeSlotValue(children);\r\n instance.slots.default = () => normalized;\r\n};\r\nconst initSlots = (instance, children) => {\r\n if (instance.vnode.shapeFlag & 32 /* SLOTS_CHILDREN */) {\r\n const type = children._;\r\n if (type) {\r\n // users can get the shallow readonly version of the slots object through `this.$slots`,\r\n // we should avoid the proxy object polluting the slots of the internal instance\r\n instance.slots = toRaw(children);\r\n // make compiler marker non-enumerable\r\n def(children, '_', type);\r\n }\r\n else {\r\n normalizeObjectSlots(children, (instance.slots = {}));\r\n }\r\n }\r\n else {\r\n instance.slots = {};\r\n if (children) {\r\n normalizeVNodeSlots(instance, children);\r\n }\r\n }\r\n def(instance.slots, InternalObjectKey, 1);\r\n};\r\nconst updateSlots = (instance, children, optimized) => {\r\n const { vnode, slots } = instance;\r\n let needDeletionCheck = true;\r\n let deletionComparisonTarget = EMPTY_OBJ;\r\n if (vnode.shapeFlag & 32 /* SLOTS_CHILDREN */) {\r\n const type = children._;\r\n if (type) {\r\n // compiled slots.\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n // Parent was HMR updated so slot content may have changed.\r\n // force update slots and mark instance for hmr as well\r\n extend(slots, children);\r\n }\r\n else if (optimized && type === 1 /* STABLE */) {\r\n // compiled AND stable.\r\n // no need to update, and skip stale slots removal.\r\n needDeletionCheck = false;\r\n }\r\n else {\r\n // compiled but dynamic (v-if/v-for on slots) - update slots, but skip\r\n // normalization.\r\n extend(slots, children);\r\n // #2893\r\n // when rendering the optimized slots by manually written render function,\r\n // we need to delete the `slots._` flag if necessary to make subsequent updates reliable,\r\n // i.e. let the `renderSlot` create the bailed Fragment\r\n if (!optimized && type === 1 /* STABLE */) {\r\n delete slots._;\r\n }\r\n }\r\n }\r\n else {\r\n needDeletionCheck = !children.$stable;\r\n normalizeObjectSlots(children, slots);\r\n }\r\n deletionComparisonTarget = children;\r\n }\r\n else if (children) {\r\n // non slot object children (direct value) passed to a component\r\n normalizeVNodeSlots(instance, children);\r\n deletionComparisonTarget = { default: 1 };\r\n }\r\n // delete stale slots\r\n if (needDeletionCheck) {\r\n for (const key in slots) {\r\n if (!isInternalKey(key) && !(key in deletionComparisonTarget)) {\r\n delete slots[key];\r\n }\r\n }\r\n }\r\n};\n\n/**\r\nRuntime helper for applying directives to a vnode. Example usage:\r\n\nconst comp = resolveComponent('comp')\r\nconst foo = resolveDirective('foo')\r\nconst bar = resolveDirective('bar')\r\n\nreturn withDirectives(h(comp), [\r\n [foo, this.x],\r\n [bar, this.y]\r\n])\r\n*/\r\nconst isBuiltInDirective = /*#__PURE__*/ makeMap('bind,cloak,else-if,else,for,html,if,model,on,once,pre,show,slot,text,memo');\r\nfunction validateDirectiveName(name) {\r\n if (isBuiltInDirective(name)) {\r\n warn('Do not use built-in directive ids as custom directive id: ' + name);\r\n }\r\n}\r\n/**\r\n * Adds directives to a VNode.\r\n */\r\nfunction withDirectives(vnode, directives) {\r\n const internalInstance = currentRenderingInstance;\r\n if (internalInstance === null) {\r\n (process.env.NODE_ENV !== 'production') && warn(`withDirectives can only be used inside render functions.`);\r\n return vnode;\r\n }\r\n const instance = internalInstance.proxy;\r\n const bindings = vnode.dirs || (vnode.dirs = []);\r\n for (let i = 0; i < directives.length; i++) {\r\n let [dir, value, arg, modifiers = EMPTY_OBJ] = directives[i];\r\n if (isFunction(dir)) {\r\n dir = {\r\n mounted: dir,\r\n updated: dir\r\n };\r\n }\r\n if (dir.deep) {\r\n traverse(value);\r\n }\r\n bindings.push({\r\n dir,\r\n instance,\r\n value,\r\n oldValue: void 0,\r\n arg,\r\n modifiers\r\n });\r\n }\r\n return vnode;\r\n}\r\nfunction invokeDirectiveHook(vnode, prevVNode, instance, name) {\r\n const bindings = vnode.dirs;\r\n const oldBindings = prevVNode && prevVNode.dirs;\r\n for (let i = 0; i < bindings.length; i++) {\r\n const binding = bindings[i];\r\n if (oldBindings) {\r\n binding.oldValue = oldBindings[i].value;\r\n }\r\n let hook = binding.dir[name];\r\n if (hook) {\r\n // disable tracking inside all lifecycle hooks\r\n // since they can potentially be called inside effects.\r\n pauseTracking();\r\n callWithAsyncErrorHandling(hook, instance, 8 /* DIRECTIVE_HOOK */, [\r\n vnode.el,\r\n binding,\r\n vnode,\r\n prevVNode\r\n ]);\r\n resetTracking();\r\n }\r\n }\r\n}\n\nfunction createAppContext() {\r\n return {\r\n app: null,\r\n config: {\r\n isNativeTag: NO,\r\n performance: false,\r\n globalProperties: {},\r\n optionMergeStrategies: {},\r\n errorHandler: undefined,\r\n warnHandler: undefined,\r\n compilerOptions: {}\r\n },\r\n mixins: [],\r\n components: {},\r\n directives: {},\r\n provides: Object.create(null),\r\n optionsCache: new WeakMap(),\r\n propsCache: new WeakMap(),\r\n emitsCache: new WeakMap()\r\n };\r\n}\r\nlet uid = 0;\r\nfunction createAppAPI(render, hydrate) {\r\n return function createApp(rootComponent, rootProps = null) {\r\n if (rootProps != null && !isObject(rootProps)) {\r\n (process.env.NODE_ENV !== 'production') && warn(`root props passed to app.mount() must be an object.`);\r\n rootProps = null;\r\n }\r\n const context = createAppContext();\r\n const installedPlugins = new Set();\r\n let isMounted = false;\r\n const app = (context.app = {\r\n _uid: uid++,\r\n _component: rootComponent,\r\n _props: rootProps,\r\n _container: null,\r\n _context: context,\r\n _instance: null,\r\n version,\r\n get config() {\r\n return context.config;\r\n },\r\n set config(v) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`app.config cannot be replaced. Modify individual options instead.`);\r\n }\r\n },\r\n use(plugin, ...options) {\r\n if (installedPlugins.has(plugin)) {\r\n (process.env.NODE_ENV !== 'production') && warn(`Plugin has already been applied to target app.`);\r\n }\r\n else if (plugin && isFunction(plugin.install)) {\r\n installedPlugins.add(plugin);\r\n plugin.install(app, ...options);\r\n }\r\n else if (isFunction(plugin)) {\r\n installedPlugins.add(plugin);\r\n plugin(app, ...options);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`A plugin must either be a function or an object with an \"install\" ` +\r\n `function.`);\r\n }\r\n return app;\r\n },\r\n mixin(mixin) {\r\n if (__VUE_OPTIONS_API__) {\r\n if (!context.mixins.includes(mixin)) {\r\n context.mixins.push(mixin);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Mixin has already been applied to target app' +\r\n (mixin.name ? `: ${mixin.name}` : ''));\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Mixins are only available in builds supporting Options API');\r\n }\r\n return app;\r\n },\r\n component(name, component) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateComponentName(name, context.config);\r\n }\r\n if (!component) {\r\n return context.components[name];\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && context.components[name]) {\r\n warn(`Component \"${name}\" has already been registered in target app.`);\r\n }\r\n context.components[name] = component;\r\n return app;\r\n },\r\n directive(name, directive) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n validateDirectiveName(name);\r\n }\r\n if (!directive) {\r\n return context.directives[name];\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && context.directives[name]) {\r\n warn(`Directive \"${name}\" has already been registered in target app.`);\r\n }\r\n context.directives[name] = directive;\r\n return app;\r\n },\r\n mount(rootContainer, isHydrate, isSVG) {\r\n if (!isMounted) {\r\n const vnode = createVNode(rootComponent, rootProps);\r\n // store app context on the root VNode.\r\n // this will be set on the root instance on initial mount.\r\n vnode.appContext = context;\r\n // HMR root reload\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n context.reload = () => {\r\n render(cloneVNode(vnode), rootContainer, isSVG);\r\n };\r\n }\r\n if (isHydrate && hydrate) {\r\n hydrate(vnode, rootContainer);\r\n }\r\n else {\r\n render(vnode, rootContainer, isSVG);\r\n }\r\n isMounted = true;\r\n app._container = rootContainer;\r\n rootContainer.__vue_app__ = app;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n app._instance = vnode.component;\r\n devtoolsInitApp(app, version);\r\n }\r\n return getExposeProxy(vnode.component) || vnode.component.proxy;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`App has already been mounted.\\n` +\r\n `If you want to remount the same app, move your app creation logic ` +\r\n `into a factory function and create fresh app instances for each ` +\r\n `mount - e.g. \\`const createMyApp = () => createApp(App)\\``);\r\n }\r\n },\r\n unmount() {\r\n if (isMounted) {\r\n render(null, app._container);\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n app._instance = null;\r\n devtoolsUnmountApp(app);\r\n }\r\n delete app._container.__vue_app__;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Cannot unmount an app that is not mounted.`);\r\n }\r\n },\r\n provide(key, value) {\r\n if ((process.env.NODE_ENV !== 'production') && key in context.provides) {\r\n warn(`App already provides property with key \"${String(key)}\". ` +\r\n `It will be overwritten with the new value.`);\r\n }\r\n // TypeScript doesn't allow symbols as index type\r\n // https://github.com/Microsoft/TypeScript/issues/24587\r\n context.provides[key] = value;\r\n return app;\r\n }\r\n });\r\n return app;\r\n };\r\n}\n\nlet hasMismatch = false;\r\nconst isSVGContainer = (container) => /svg/.test(container.namespaceURI) && container.tagName !== 'foreignObject';\r\nconst isComment = (node) => node.nodeType === 8 /* COMMENT */;\r\n// Note: hydration is DOM-specific\r\n// But we have to place it in core due to tight coupling with core - splitting\r\n// it out creates a ton of unnecessary complexity.\r\n// Hydration also depends on some renderer internal logic which needs to be\r\n// passed in via arguments.\r\nfunction createHydrationFunctions(rendererInternals) {\r\n const { mt: mountComponent, p: patch, o: { patchProp, nextSibling, parentNode, remove, insert, createComment } } = rendererInternals;\r\n const hydrate = (vnode, container) => {\r\n if (!container.hasChildNodes()) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Attempting to hydrate existing markup but container is empty. ` +\r\n `Performing full mount instead.`);\r\n patch(null, vnode, container);\r\n flushPostFlushCbs();\r\n return;\r\n }\r\n hasMismatch = false;\r\n hydrateNode(container.firstChild, vnode, null, null, null);\r\n flushPostFlushCbs();\r\n if (hasMismatch && !false) {\r\n // this error should show up in production\r\n console.error(`Hydration completed but contains mismatches.`);\r\n }\r\n };\r\n const hydrateNode = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized = false) => {\r\n const isFragmentStart = isComment(node) && node.data === '[';\r\n const onMismatch = () => handleMismatch(node, vnode, parentComponent, parentSuspense, slotScopeIds, isFragmentStart);\r\n const { type, ref, shapeFlag } = vnode;\r\n const domType = node.nodeType;\r\n vnode.el = node;\r\n let nextNode = null;\r\n switch (type) {\r\n case Text:\r\n if (domType !== 3 /* TEXT */) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n if (node.data !== vnode.children) {\r\n hasMismatch = true;\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Hydration text mismatch:` +\r\n `\\n- Client: ${JSON.stringify(node.data)}` +\r\n `\\n- Server: ${JSON.stringify(vnode.children)}`);\r\n node.data = vnode.children;\r\n }\r\n nextNode = nextSibling(node);\r\n }\r\n break;\r\n case Comment:\r\n if (domType !== 8 /* COMMENT */ || isFragmentStart) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = nextSibling(node);\r\n }\r\n break;\r\n case Static:\r\n if (domType !== 1 /* ELEMENT */) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n // determine anchor, adopt content\r\n nextNode = node;\r\n // if the static vnode has its content stripped during build,\r\n // adopt it from the server-rendered HTML.\r\n const needToAdoptContent = !vnode.children.length;\r\n for (let i = 0; i < vnode.staticCount; i++) {\r\n if (needToAdoptContent)\r\n vnode.children += nextNode.outerHTML;\r\n if (i === vnode.staticCount - 1) {\r\n vnode.anchor = nextNode;\r\n }\r\n nextNode = nextSibling(nextNode);\r\n }\r\n return nextNode;\r\n }\r\n break;\r\n case Fragment:\r\n if (!isFragmentStart) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = hydrateFragment(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n break;\r\n default:\r\n if (shapeFlag & 1 /* ELEMENT */) {\r\n if (domType !== 1 /* ELEMENT */ ||\r\n vnode.type.toLowerCase() !==\r\n node.tagName.toLowerCase()) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = hydrateElement(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n }\r\n else if (shapeFlag & 6 /* COMPONENT */) {\r\n // when setting up the render effect, if the initial vnode already\r\n // has .el set, the component will perform hydration instead of mount\r\n // on its sub-tree.\r\n vnode.slotScopeIds = slotScopeIds;\r\n const container = parentNode(node);\r\n mountComponent(vnode, container, null, parentComponent, parentSuspense, isSVGContainer(container), optimized);\r\n // component may be async, so in the case of fragments we cannot rely\r\n // on component's rendered output to determine the end of the fragment\r\n // instead, we do a lookahead to find the end anchor node.\r\n nextNode = isFragmentStart\r\n ? locateClosingAsyncAnchor(node)\r\n : nextSibling(node);\r\n // #3787\r\n // if component is async, it may get moved / unmounted before its\r\n // inner component is loaded, so we need to give it a placeholder\r\n // vnode that matches its adopted DOM.\r\n if (isAsyncWrapper(vnode)) {\r\n let subTree;\r\n if (isFragmentStart) {\r\n subTree = createVNode(Fragment);\r\n subTree.anchor = nextNode\r\n ? nextNode.previousSibling\r\n : container.lastChild;\r\n }\r\n else {\r\n subTree =\r\n node.nodeType === 3 ? createTextVNode('') : createVNode('div');\r\n }\r\n subTree.el = node;\r\n vnode.component.subTree = subTree;\r\n }\r\n }\r\n else if (shapeFlag & 64 /* TELEPORT */) {\r\n if (domType !== 8 /* COMMENT */) {\r\n nextNode = onMismatch();\r\n }\r\n else {\r\n nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, rendererInternals, hydrateChildren);\r\n }\r\n }\r\n else if (shapeFlag & 128 /* SUSPENSE */) {\r\n nextNode = vnode.type.hydrate(node, vnode, parentComponent, parentSuspense, isSVGContainer(parentNode(node)), slotScopeIds, optimized, rendererInternals, hydrateNode);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid HostVNode type:', type, `(${typeof type})`);\r\n }\r\n }\r\n if (ref != null) {\r\n setRef(ref, null, parentSuspense, vnode);\r\n }\r\n return nextNode;\r\n };\r\n const hydrateElement = (el, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n optimized = optimized || !!vnode.dynamicChildren;\r\n const { type, props, patchFlag, shapeFlag, dirs } = vnode;\r\n // #4006 for form elements with non-string v-model value bindings\r\n // e.g. <option :value=\"obj\">, <input type=\"checkbox\" :true-value=\"1\">\r\n const forcePatchValue = (type === 'input' && dirs) || type === 'option';\r\n // skip props & children if this is hoisted static nodes\r\n if (forcePatchValue || patchFlag !== -1 /* HOISTED */) {\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'created');\r\n }\r\n // props\r\n if (props) {\r\n if (forcePatchValue ||\r\n !optimized ||\r\n patchFlag & (16 /* FULL_PROPS */ | 32 /* HYDRATE_EVENTS */)) {\r\n for (const key in props) {\r\n if ((forcePatchValue && key.endsWith('value')) ||\r\n (isOn(key) && !isReservedProp(key))) {\r\n patchProp(el, key, null, props[key], false, undefined, parentComponent);\r\n }\r\n }\r\n }\r\n else if (props.onClick) {\r\n // Fast path for click listeners (which is most often) to avoid\r\n // iterating through props.\r\n patchProp(el, 'onClick', null, props.onClick, false, undefined, parentComponent);\r\n }\r\n }\r\n // vnode / directive hooks\r\n let vnodeHooks;\r\n if ((vnodeHooks = props && props.onVnodeBeforeMount)) {\r\n invokeVNodeHook(vnodeHooks, parentComponent, vnode);\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'beforeMount');\r\n }\r\n if ((vnodeHooks = props && props.onVnodeMounted) || dirs) {\r\n queueEffectWithSuspense(() => {\r\n vnodeHooks && invokeVNodeHook(vnodeHooks, parentComponent, vnode);\r\n dirs && invokeDirectiveHook(vnode, null, parentComponent, 'mounted');\r\n }, parentSuspense);\r\n }\r\n // children\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */ &&\r\n // skip if element has innerHTML / textContent\r\n !(props && (props.innerHTML || props.textContent))) {\r\n let next = hydrateChildren(el.firstChild, vnode, el, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n let hasWarned = false;\r\n while (next) {\r\n hasMismatch = true;\r\n if ((process.env.NODE_ENV !== 'production') && !hasWarned) {\r\n warn(`Hydration children mismatch in <${vnode.type}>: ` +\r\n `server rendered element contains more child nodes than client vdom.`);\r\n hasWarned = true;\r\n }\r\n // The SSRed DOM contains more nodes than it should. Remove them.\r\n const cur = next;\r\n next = next.nextSibling;\r\n remove(cur);\r\n }\r\n }\r\n else if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n if (el.textContent !== vnode.children) {\r\n hasMismatch = true;\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Hydration text content mismatch in <${vnode.type}>:\\n` +\r\n `- Client: ${el.textContent}\\n` +\r\n `- Server: ${vnode.children}`);\r\n el.textContent = vnode.children;\r\n }\r\n }\r\n }\r\n return el.nextSibling;\r\n };\r\n const hydrateChildren = (node, parentVNode, container, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n optimized = optimized || !!parentVNode.dynamicChildren;\r\n const children = parentVNode.children;\r\n const l = children.length;\r\n let hasWarned = false;\r\n for (let i = 0; i < l; i++) {\r\n const vnode = optimized\r\n ? children[i]\r\n : (children[i] = normalizeVNode(children[i]));\r\n if (node) {\r\n node = hydrateNode(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n else if (vnode.type === Text && !vnode.children) {\r\n continue;\r\n }\r\n else {\r\n hasMismatch = true;\r\n if ((process.env.NODE_ENV !== 'production') && !hasWarned) {\r\n warn(`Hydration children mismatch in <${container.tagName.toLowerCase()}>: ` +\r\n `server rendered element contains fewer child nodes than client vdom.`);\r\n hasWarned = true;\r\n }\r\n // the SSRed DOM didn't contain enough nodes. Mount the missing ones.\r\n patch(null, vnode, container, null, parentComponent, parentSuspense, isSVGContainer(container), slotScopeIds);\r\n }\r\n }\r\n return node;\r\n };\r\n const hydrateFragment = (node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized) => {\r\n const { slotScopeIds: fragmentSlotScopeIds } = vnode;\r\n if (fragmentSlotScopeIds) {\r\n slotScopeIds = slotScopeIds\r\n ? slotScopeIds.concat(fragmentSlotScopeIds)\r\n : fragmentSlotScopeIds;\r\n }\r\n const container = parentNode(node);\r\n const next = hydrateChildren(nextSibling(node), vnode, container, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n if (next && isComment(next) && next.data === ']') {\r\n return nextSibling((vnode.anchor = next));\r\n }\r\n else {\r\n // fragment didn't hydrate successfully, since we didn't get a end anchor\r\n // back. This should have led to node/children mismatch warnings.\r\n hasMismatch = true;\r\n // since the anchor is missing, we need to create one and insert it\r\n insert((vnode.anchor = createComment(`]`)), container, next);\r\n return next;\r\n }\r\n };\r\n const handleMismatch = (node, vnode, parentComponent, parentSuspense, slotScopeIds, isFragment) => {\r\n hasMismatch = true;\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Hydration node mismatch:\\n- Client vnode:`, vnode.type, `\\n- Server rendered DOM:`, node, node.nodeType === 3 /* TEXT */\r\n ? `(text)`\r\n : isComment(node) && node.data === '['\r\n ? `(start of fragment)`\r\n : ``);\r\n vnode.el = null;\r\n if (isFragment) {\r\n // remove excessive fragment nodes\r\n const end = locateClosingAsyncAnchor(node);\r\n while (true) {\r\n const next = nextSibling(node);\r\n if (next && next !== end) {\r\n remove(next);\r\n }\r\n else {\r\n break;\r\n }\r\n }\r\n }\r\n const next = nextSibling(node);\r\n const container = parentNode(node);\r\n remove(node);\r\n patch(null, vnode, container, next, parentComponent, parentSuspense, isSVGContainer(container), slotScopeIds);\r\n return next;\r\n };\r\n const locateClosingAsyncAnchor = (node) => {\r\n let match = 0;\r\n while (node) {\r\n node = nextSibling(node);\r\n if (node && isComment(node)) {\r\n if (node.data === '[')\r\n match++;\r\n if (node.data === ']') {\r\n if (match === 0) {\r\n return nextSibling(node);\r\n }\r\n else {\r\n match--;\r\n }\r\n }\r\n }\r\n }\r\n return node;\r\n };\r\n return [hydrate, hydrateNode];\r\n}\n\nlet supported;\r\nlet perf;\r\nfunction startMeasure(instance, type) {\r\n if (instance.appContext.config.performance && isSupported()) {\r\n perf.mark(`vue-${type}-${instance.uid}`);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsPerfStart(instance, type, supported ? perf.now() : Date.now());\r\n }\r\n}\r\nfunction endMeasure(instance, type) {\r\n if (instance.appContext.config.performance && isSupported()) {\r\n const startTag = `vue-${type}-${instance.uid}`;\r\n const endTag = startTag + `:end`;\r\n perf.mark(endTag);\r\n perf.measure(`<${formatComponentName(instance, instance.type)}> ${type}`, startTag, endTag);\r\n perf.clearMarks(startTag);\r\n perf.clearMarks(endTag);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsPerfEnd(instance, type, supported ? perf.now() : Date.now());\r\n }\r\n}\r\nfunction isSupported() {\r\n if (supported !== undefined) {\r\n return supported;\r\n }\r\n /* eslint-disable no-restricted-globals */\r\n if (typeof window !== 'undefined' && window.performance) {\r\n supported = true;\r\n perf = window.performance;\r\n }\r\n else {\r\n supported = false;\r\n }\r\n /* eslint-enable no-restricted-globals */\r\n return supported;\r\n}\n\n/**\r\n * This is only called in esm-bundler builds.\r\n * It is called when a renderer is created, in `baseCreateRenderer` so that\r\n * importing runtime-core is side-effects free.\r\n *\r\n * istanbul-ignore-next\r\n */\r\nfunction initFeatureFlags() {\r\n const needWarn = [];\r\n if (typeof __VUE_OPTIONS_API__ !== 'boolean') {\r\n (process.env.NODE_ENV !== 'production') && needWarn.push(`__VUE_OPTIONS_API__`);\r\n getGlobalThis().__VUE_OPTIONS_API__ = true;\r\n }\r\n if (typeof __VUE_PROD_DEVTOOLS__ !== 'boolean') {\r\n (process.env.NODE_ENV !== 'production') && needWarn.push(`__VUE_PROD_DEVTOOLS__`);\r\n getGlobalThis().__VUE_PROD_DEVTOOLS__ = false;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && needWarn.length) {\r\n const multi = needWarn.length > 1;\r\n console.warn(`Feature flag${multi ? `s` : ``} ${needWarn.join(', ')} ${multi ? `are` : `is`} not explicitly defined. You are running the esm-bundler build of Vue, ` +\r\n `which expects these compile-time feature flags to be globally injected ` +\r\n `via the bundler config in order to get better tree-shaking in the ` +\r\n `production bundle.\\n\\n` +\r\n `For more details, see http://link.vuejs.org/feature-flags.`);\r\n }\r\n}\n\nconst queuePostRenderEffect = queueEffectWithSuspense\r\n ;\r\n/**\r\n * The createRenderer function accepts two generic arguments:\r\n * HostNode and HostElement, corresponding to Node and Element types in the\r\n * host environment. For example, for runtime-dom, HostNode would be the DOM\r\n * `Node` interface and HostElement would be the DOM `Element` interface.\r\n *\r\n * Custom renderers can pass in the platform specific types like this:\r\n *\r\n * ``` js\r\n * const { render, createApp } = createRenderer<Node, Element>({\r\n * patchProp,\r\n * ...nodeOps\r\n * })\r\n * ```\r\n */\r\nfunction createRenderer(options) {\r\n return baseCreateRenderer(options);\r\n}\r\n// Separate API for creating hydration-enabled renderer.\r\n// Hydration logic is only used when calling this function, making it\r\n// tree-shakable.\r\nfunction createHydrationRenderer(options) {\r\n return baseCreateRenderer(options, createHydrationFunctions);\r\n}\r\n// implementation\r\nfunction baseCreateRenderer(options, createHydrationFns) {\r\n // compile-time feature flags check\r\n {\r\n initFeatureFlags();\r\n }\r\n const target = getGlobalThis();\r\n target.__VUE__ = true;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n setDevtoolsHook(target.__VUE_DEVTOOLS_GLOBAL_HOOK__, target);\r\n }\r\n const { insert: hostInsert, remove: hostRemove, patchProp: hostPatchProp, createElement: hostCreateElement, createText: hostCreateText, createComment: hostCreateComment, setText: hostSetText, setElementText: hostSetElementText, parentNode: hostParentNode, nextSibling: hostNextSibling, setScopeId: hostSetScopeId = NOOP, cloneNode: hostCloneNode, insertStaticContent: hostInsertStaticContent } = options;\r\n // Note: functions inside this closure should use `const xxx = () => {}`\r\n // style in order to prevent being inlined by minifiers.\r\n const patch = (n1, n2, container, anchor = null, parentComponent = null, parentSuspense = null, isSVG = false, slotScopeIds = null, optimized = (process.env.NODE_ENV !== 'production') && isHmrUpdating ? false : !!n2.dynamicChildren) => {\r\n if (n1 === n2) {\r\n return;\r\n }\r\n // patching & not same type, unmount old tree\r\n if (n1 && !isSameVNodeType(n1, n2)) {\r\n anchor = getNextHostNode(n1);\r\n unmount(n1, parentComponent, parentSuspense, true);\r\n n1 = null;\r\n }\r\n if (n2.patchFlag === -2 /* BAIL */) {\r\n optimized = false;\r\n n2.dynamicChildren = null;\r\n }\r\n const { type, ref, shapeFlag } = n2;\r\n switch (type) {\r\n case Text:\r\n processText(n1, n2, container, anchor);\r\n break;\r\n case Comment:\r\n processCommentNode(n1, n2, container, anchor);\r\n break;\r\n case Static:\r\n if (n1 == null) {\r\n mountStaticNode(n2, container, anchor, isSVG);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n patchStaticNode(n1, n2, container, isSVG);\r\n }\r\n break;\r\n case Fragment:\r\n processFragment(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n break;\r\n default:\r\n if (shapeFlag & 1 /* ELEMENT */) {\r\n processElement(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else if (shapeFlag & 6 /* COMPONENT */) {\r\n processComponent(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else if (shapeFlag & 64 /* TELEPORT */) {\r\n type.process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals);\r\n }\r\n else if (shapeFlag & 128 /* SUSPENSE */) {\r\n type.process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid VNode type:', type, `(${typeof type})`);\r\n }\r\n }\r\n // set ref\r\n if (ref != null && parentComponent) {\r\n setRef(ref, n1 && n1.ref, parentSuspense, n2 || n1, !n2);\r\n }\r\n };\r\n const processText = (n1, n2, container, anchor) => {\r\n if (n1 == null) {\r\n hostInsert((n2.el = hostCreateText(n2.children)), container, anchor);\r\n }\r\n else {\r\n const el = (n2.el = n1.el);\r\n if (n2.children !== n1.children) {\r\n hostSetText(el, n2.children);\r\n }\r\n }\r\n };\r\n const processCommentNode = (n1, n2, container, anchor) => {\r\n if (n1 == null) {\r\n hostInsert((n2.el = hostCreateComment(n2.children || '')), container, anchor);\r\n }\r\n else {\r\n // there's no support for dynamic comments\r\n n2.el = n1.el;\r\n }\r\n };\r\n const mountStaticNode = (n2, container, anchor, isSVG) => {\r\n [n2.el, n2.anchor] = hostInsertStaticContent(n2.children, container, anchor, isSVG);\r\n };\r\n /**\r\n * Dev / HMR only\r\n */\r\n const patchStaticNode = (n1, n2, container, isSVG) => {\r\n // static nodes are only patched during dev for HMR\r\n if (n2.children !== n1.children) {\r\n const anchor = hostNextSibling(n1.anchor);\r\n // remove existing\r\n removeStaticNode(n1);\r\n [n2.el, n2.anchor] = hostInsertStaticContent(n2.children, container, anchor, isSVG);\r\n }\r\n else {\r\n n2.el = n1.el;\r\n n2.anchor = n1.anchor;\r\n }\r\n };\r\n const moveStaticNode = ({ el, anchor }, container, nextSibling) => {\r\n let next;\r\n while (el && el !== anchor) {\r\n next = hostNextSibling(el);\r\n hostInsert(el, container, nextSibling);\r\n el = next;\r\n }\r\n hostInsert(anchor, container, nextSibling);\r\n };\r\n const removeStaticNode = ({ el, anchor }) => {\r\n let next;\r\n while (el && el !== anchor) {\r\n next = hostNextSibling(el);\r\n hostRemove(el);\r\n el = next;\r\n }\r\n hostRemove(anchor);\r\n };\r\n const processElement = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n isSVG = isSVG || n2.type === 'svg';\r\n if (n1 == null) {\r\n mountElement(n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n patchElement(n1, n2, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n };\r\n const mountElement = (vnode, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n let el;\r\n let vnodeHook;\r\n const { type, props, shapeFlag, transition, patchFlag, dirs } = vnode;\r\n if (!(process.env.NODE_ENV !== 'production') &&\r\n vnode.el &&\r\n hostCloneNode !== undefined &&\r\n patchFlag === -1 /* HOISTED */) {\r\n // If a vnode has non-null el, it means it's being reused.\r\n // Only static vnodes can be reused, so its mounted DOM nodes should be\r\n // exactly the same, and we can simply do a clone here.\r\n // only do this in production since cloned trees cannot be HMR updated.\r\n el = vnode.el = hostCloneNode(vnode.el);\r\n }\r\n else {\r\n el = vnode.el = hostCreateElement(vnode.type, isSVG, props && props.is, props);\r\n // mount children first, since some props may rely on child content\r\n // being already rendered, e.g. `<select value>`\r\n if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n hostSetElementText(el, vnode.children);\r\n }\r\n else if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n mountChildren(vnode.children, el, null, parentComponent, parentSuspense, isSVG && type !== 'foreignObject', slotScopeIds, optimized);\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'created');\r\n }\r\n // props\r\n if (props) {\r\n for (const key in props) {\r\n if (key !== 'value' && !isReservedProp(key)) {\r\n hostPatchProp(el, key, null, props[key], isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n /**\r\n * Special case for setting value on DOM elements:\r\n * - it can be order-sensitive (e.g. should be set *after* min/max, #2325, #4024)\r\n * - it needs to be forced (#1471)\r\n * #2353 proposes adding another renderer option to configure this, but\r\n * the properties affects are so finite it is worth special casing it\r\n * here to reduce the complexity. (Special casing it also should not\r\n * affect non-DOM renderers)\r\n */\r\n if ('value' in props) {\r\n hostPatchProp(el, 'value', null, props.value);\r\n }\r\n if ((vnodeHook = props.onVnodeBeforeMount)) {\r\n invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n }\r\n }\r\n // scopeId\r\n setScopeId(el, vnode, vnode.scopeId, slotScopeIds, parentComponent);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n Object.defineProperty(el, '__vnode', {\r\n value: vnode,\r\n enumerable: false\r\n });\r\n Object.defineProperty(el, '__vueParentComponent', {\r\n value: parentComponent,\r\n enumerable: false\r\n });\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'beforeMount');\r\n }\r\n // #1583 For inside suspense + suspense not resolved case, enter hook should call when suspense resolved\r\n // #1689 For inside suspense + suspense resolved case, just call it\r\n const needCallTransitionHooks = (!parentSuspense || (parentSuspense && !parentSuspense.pendingBranch)) &&\r\n transition &&\r\n !transition.persisted;\r\n if (needCallTransitionHooks) {\r\n transition.beforeEnter(el);\r\n }\r\n hostInsert(el, container, anchor);\r\n if ((vnodeHook = props && props.onVnodeMounted) ||\r\n needCallTransitionHooks ||\r\n dirs) {\r\n queuePostRenderEffect(() => {\r\n vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n needCallTransitionHooks && transition.enter(el);\r\n dirs && invokeDirectiveHook(vnode, null, parentComponent, 'mounted');\r\n }, parentSuspense);\r\n }\r\n };\r\n const setScopeId = (el, vnode, scopeId, slotScopeIds, parentComponent) => {\r\n if (scopeId) {\r\n hostSetScopeId(el, scopeId);\r\n }\r\n if (slotScopeIds) {\r\n for (let i = 0; i < slotScopeIds.length; i++) {\r\n hostSetScopeId(el, slotScopeIds[i]);\r\n }\r\n }\r\n if (parentComponent) {\r\n let subTree = parentComponent.subTree;\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n subTree.patchFlag > 0 &&\r\n subTree.patchFlag & 2048 /* DEV_ROOT_FRAGMENT */) {\r\n subTree =\r\n filterSingleRoot(subTree.children) || subTree;\r\n }\r\n if (vnode === subTree) {\r\n const parentVNode = parentComponent.vnode;\r\n setScopeId(el, parentVNode, parentVNode.scopeId, parentVNode.slotScopeIds, parentComponent.parent);\r\n }\r\n }\r\n };\r\n const mountChildren = (children, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, start = 0) => {\r\n for (let i = start; i < children.length; i++) {\r\n const child = (children[i] = optimized\r\n ? cloneIfMounted(children[i])\r\n : normalizeVNode(children[i]));\r\n patch(null, child, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n };\r\n const patchElement = (n1, n2, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n const el = (n2.el = n1.el);\r\n let { patchFlag, dynamicChildren, dirs } = n2;\r\n // #1426 take the old vnode's patch flag into account since user may clone a\r\n // compiler-generated vnode, which de-opts to FULL_PROPS\r\n patchFlag |= n1.patchFlag & 16 /* FULL_PROPS */;\r\n const oldProps = n1.props || EMPTY_OBJ;\r\n const newProps = n2.props || EMPTY_OBJ;\r\n let vnodeHook;\r\n if ((vnodeHook = newProps.onVnodeBeforeUpdate)) {\r\n invokeVNodeHook(vnodeHook, parentComponent, n2, n1);\r\n }\r\n if (dirs) {\r\n invokeDirectiveHook(n2, n1, parentComponent, 'beforeUpdate');\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n // HMR updated, force full diff\r\n patchFlag = 0;\r\n optimized = false;\r\n dynamicChildren = null;\r\n }\r\n const areChildrenSVG = isSVG && n2.type !== 'foreignObject';\r\n if (dynamicChildren) {\r\n patchBlockChildren(n1.dynamicChildren, dynamicChildren, el, parentComponent, parentSuspense, areChildrenSVG, slotScopeIds);\r\n if ((process.env.NODE_ENV !== 'production') && parentComponent && parentComponent.type.__hmrId) {\r\n traverseStaticChildren(n1, n2);\r\n }\r\n }\r\n else if (!optimized) {\r\n // full diff\r\n patchChildren(n1, n2, el, null, parentComponent, parentSuspense, areChildrenSVG, slotScopeIds, false);\r\n }\r\n if (patchFlag > 0) {\r\n // the presence of a patchFlag means this element's render code was\r\n // generated by the compiler and can take the fast path.\r\n // in this path old node and new node are guaranteed to have the same shape\r\n // (i.e. at the exact same position in the source template)\r\n if (patchFlag & 16 /* FULL_PROPS */) {\r\n // element props contain dynamic keys, full diff needed\r\n patchProps(el, n2, oldProps, newProps, parentComponent, parentSuspense, isSVG);\r\n }\r\n else {\r\n // class\r\n // this flag is matched when the element has dynamic class bindings.\r\n if (patchFlag & 2 /* CLASS */) {\r\n if (oldProps.class !== newProps.class) {\r\n hostPatchProp(el, 'class', null, newProps.class, isSVG);\r\n }\r\n }\r\n // style\r\n // this flag is matched when the element has dynamic style bindings\r\n if (patchFlag & 4 /* STYLE */) {\r\n hostPatchProp(el, 'style', oldProps.style, newProps.style, isSVG);\r\n }\r\n // props\r\n // This flag is matched when the element has dynamic prop/attr bindings\r\n // other than class and style. The keys of dynamic prop/attrs are saved for\r\n // faster iteration.\r\n // Note dynamic keys like :[foo]=\"bar\" will cause this optimization to\r\n // bail out and go through a full diff because we need to unset the old key\r\n if (patchFlag & 8 /* PROPS */) {\r\n // if the flag is present then dynamicProps must be non-null\r\n const propsToUpdate = n2.dynamicProps;\r\n for (let i = 0; i < propsToUpdate.length; i++) {\r\n const key = propsToUpdate[i];\r\n const prev = oldProps[key];\r\n const next = newProps[key];\r\n // #1471 force patch value\r\n if (next !== prev || key === 'value') {\r\n hostPatchProp(el, key, prev, next, isSVG, n1.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n }\r\n }\r\n // text\r\n // This flag is matched when the element has only dynamic text children.\r\n if (patchFlag & 1 /* TEXT */) {\r\n if (n1.children !== n2.children) {\r\n hostSetElementText(el, n2.children);\r\n }\r\n }\r\n }\r\n else if (!optimized && dynamicChildren == null) {\r\n // unoptimized, full diff\r\n patchProps(el, n2, oldProps, newProps, parentComponent, parentSuspense, isSVG);\r\n }\r\n if ((vnodeHook = newProps.onVnodeUpdated) || dirs) {\r\n queuePostRenderEffect(() => {\r\n vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, n2, n1);\r\n dirs && invokeDirectiveHook(n2, n1, parentComponent, 'updated');\r\n }, parentSuspense);\r\n }\r\n };\r\n // The fast path for blocks.\r\n const patchBlockChildren = (oldChildren, newChildren, fallbackContainer, parentComponent, parentSuspense, isSVG, slotScopeIds) => {\r\n for (let i = 0; i < newChildren.length; i++) {\r\n const oldVNode = oldChildren[i];\r\n const newVNode = newChildren[i];\r\n // Determine the container (parent element) for the patch.\r\n const container = \r\n // oldVNode may be an errored async setup() component inside Suspense\r\n // which will not have a mounted element\r\n oldVNode.el &&\r\n // - In the case of a Fragment, we need to provide the actual parent\r\n // of the Fragment itself so it can move its children.\r\n (oldVNode.type === Fragment ||\r\n // - In the case of different nodes, there is going to be a replacement\r\n // which also requires the correct parent container\r\n !isSameVNodeType(oldVNode, newVNode) ||\r\n // - In the case of a component, it could contain anything.\r\n oldVNode.shapeFlag & (6 /* COMPONENT */ | 64 /* TELEPORT */))\r\n ? hostParentNode(oldVNode.el)\r\n : // In other cases, the parent container is not actually used so we\r\n // just pass the block element here to avoid a DOM parentNode call.\r\n fallbackContainer;\r\n patch(oldVNode, newVNode, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, true);\r\n }\r\n };\r\n const patchProps = (el, vnode, oldProps, newProps, parentComponent, parentSuspense, isSVG) => {\r\n if (oldProps !== newProps) {\r\n for (const key in newProps) {\r\n // empty string is not valid prop\r\n if (isReservedProp(key))\r\n continue;\r\n const next = newProps[key];\r\n const prev = oldProps[key];\r\n // defer patching value\r\n if (next !== prev && key !== 'value') {\r\n hostPatchProp(el, key, prev, next, isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n if (oldProps !== EMPTY_OBJ) {\r\n for (const key in oldProps) {\r\n if (!isReservedProp(key) && !(key in newProps)) {\r\n hostPatchProp(el, key, oldProps[key], null, isSVG, vnode.children, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n }\r\n }\r\n if ('value' in newProps) {\r\n hostPatchProp(el, 'value', oldProps.value, newProps.value);\r\n }\r\n }\r\n };\r\n const processFragment = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n const fragmentStartAnchor = (n2.el = n1 ? n1.el : hostCreateText(''));\r\n const fragmentEndAnchor = (n2.anchor = n1 ? n1.anchor : hostCreateText(''));\r\n let { patchFlag, dynamicChildren, slotScopeIds: fragmentSlotScopeIds } = n2;\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n // HMR updated, force full diff\r\n patchFlag = 0;\r\n optimized = false;\r\n dynamicChildren = null;\r\n }\r\n // check if this is a slot fragment with :slotted scope ids\r\n if (fragmentSlotScopeIds) {\r\n slotScopeIds = slotScopeIds\r\n ? slotScopeIds.concat(fragmentSlotScopeIds)\r\n : fragmentSlotScopeIds;\r\n }\r\n if (n1 == null) {\r\n hostInsert(fragmentStartAnchor, container, anchor);\r\n hostInsert(fragmentEndAnchor, container, anchor);\r\n // a fragment can only have array children\r\n // since they are either generated by the compiler, or implicitly created\r\n // from arrays.\r\n mountChildren(n2.children, container, fragmentEndAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n if (patchFlag > 0 &&\r\n patchFlag & 64 /* STABLE_FRAGMENT */ &&\r\n dynamicChildren &&\r\n // #2715 the previous fragment could've been a BAILed one as a result\r\n // of renderSlot() with no valid children\r\n n1.dynamicChildren) {\r\n // a stable fragment (template root or <template v-for>) doesn't need to\r\n // patch children order, but it may contain dynamicChildren.\r\n patchBlockChildren(n1.dynamicChildren, dynamicChildren, container, parentComponent, parentSuspense, isSVG, slotScopeIds);\r\n if ((process.env.NODE_ENV !== 'production') && parentComponent && parentComponent.type.__hmrId) {\r\n traverseStaticChildren(n1, n2);\r\n }\r\n else if (\r\n // #2080 if the stable fragment has a key, it's a <template v-for> that may\r\n // get moved around. Make sure all root level vnodes inherit el.\r\n // #2134 or if it's a component root, it may also get moved around\r\n // as the component is being moved.\r\n n2.key != null ||\r\n (parentComponent && n2 === parentComponent.subTree)) {\r\n traverseStaticChildren(n1, n2, true /* shallow */);\r\n }\r\n }\r\n else {\r\n // keyed / unkeyed, or manual fragments.\r\n // for keyed & unkeyed, since they are compiler generated from v-for,\r\n // each child is guaranteed to be a block so the fragment will never\r\n // have dynamicChildren.\r\n patchChildren(n1, n2, container, fragmentEndAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n }\r\n };\r\n const processComponent = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n n2.slotScopeIds = slotScopeIds;\r\n if (n1 == null) {\r\n if (n2.shapeFlag & 512 /* COMPONENT_KEPT_ALIVE */) {\r\n parentComponent.ctx.activate(n2, container, anchor, isSVG, optimized);\r\n }\r\n else {\r\n mountComponent(n2, container, anchor, parentComponent, parentSuspense, isSVG, optimized);\r\n }\r\n }\r\n else {\r\n updateComponent(n1, n2, optimized);\r\n }\r\n };\r\n const mountComponent = (initialVNode, container, anchor, parentComponent, parentSuspense, isSVG, optimized) => {\r\n const instance = (initialVNode.component = createComponentInstance(initialVNode, parentComponent, parentSuspense));\r\n if ((process.env.NODE_ENV !== 'production') && instance.type.__hmrId) {\r\n registerHMR(instance);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(initialVNode);\r\n startMeasure(instance, `mount`);\r\n }\r\n // inject renderer internals for keepAlive\r\n if (isKeepAlive(initialVNode)) {\r\n instance.ctx.renderer = internals;\r\n }\r\n // resolve props and slots for setup context\r\n {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `init`);\r\n }\r\n setupComponent(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `init`);\r\n }\r\n }\r\n // setup() is async. This component relies on async logic to be resolved\r\n // before proceeding\r\n if (instance.asyncDep) {\r\n parentSuspense && parentSuspense.registerDep(instance, setupRenderEffect);\r\n // Give it a placeholder if this is not hydration\r\n // TODO handle self-defined fallback\r\n if (!initialVNode.el) {\r\n const placeholder = (instance.subTree = createVNode(Comment));\r\n processCommentNode(null, placeholder, container, anchor);\r\n }\r\n return;\r\n }\r\n setupRenderEffect(instance, initialVNode, container, anchor, parentSuspense, isSVG, optimized);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n endMeasure(instance, `mount`);\r\n }\r\n };\r\n const updateComponent = (n1, n2, optimized) => {\r\n const instance = (n2.component = n1.component);\r\n if (shouldUpdateComponent(n1, n2, optimized)) {\r\n if (instance.asyncDep &&\r\n !instance.asyncResolved) {\r\n // async & still pending - just update props and slots\r\n // since the component's reactive effect for render isn't set-up yet\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(n2);\r\n }\r\n updateComponentPreRender(instance, n2, optimized);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n }\r\n return;\r\n }\r\n else {\r\n // normal update\r\n instance.next = n2;\r\n // in case the child component is also queued, remove it to avoid\r\n // double updating the same child component in the same flush.\r\n invalidateJob(instance.update);\r\n // instance.update is the reactive effect.\r\n instance.update();\r\n }\r\n }\r\n else {\r\n // no update needed. just copy over properties\r\n n2.component = n1.component;\r\n n2.el = n1.el;\r\n instance.vnode = n2;\r\n }\r\n };\r\n const setupRenderEffect = (instance, initialVNode, container, anchor, parentSuspense, isSVG, optimized) => {\r\n const componentUpdateFn = () => {\r\n if (!instance.isMounted) {\r\n let vnodeHook;\r\n const { el, props } = initialVNode;\r\n const { bm, m, parent } = instance;\r\n const isAsyncWrapperVNode = isAsyncWrapper(initialVNode);\r\n effect.allowRecurse = false;\r\n // beforeMount hook\r\n if (bm) {\r\n invokeArrayFns(bm);\r\n }\r\n // onVnodeBeforeMount\r\n if (!isAsyncWrapperVNode &&\r\n (vnodeHook = props && props.onVnodeBeforeMount)) {\r\n invokeVNodeHook(vnodeHook, parent, initialVNode);\r\n }\r\n effect.allowRecurse = true;\r\n if (el && hydrateNode) {\r\n // vnode has adopted host node - perform hydration instead of mount.\r\n const hydrateSubTree = () => {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `render`);\r\n }\r\n instance.subTree = renderComponentRoot(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `render`);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `hydrate`);\r\n }\r\n hydrateNode(el, instance.subTree, instance, parentSuspense, null);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `hydrate`);\r\n }\r\n };\r\n if (isAsyncWrapperVNode) {\r\n initialVNode.type.__asyncLoader().then(\r\n // note: we are moving the render call into an async callback,\r\n // which means it won't track dependencies - but it's ok because\r\n // a server-rendered async wrapper is already in resolved state\r\n // and it will never need to change.\r\n () => !instance.isUnmounted && hydrateSubTree());\r\n }\r\n else {\r\n hydrateSubTree();\r\n }\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `render`);\r\n }\r\n const subTree = (instance.subTree = renderComponentRoot(instance));\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `render`);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `patch`);\r\n }\r\n patch(null, subTree, container, anchor, instance, parentSuspense, isSVG);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `patch`);\r\n }\r\n initialVNode.el = subTree.el;\r\n }\r\n // mounted hook\r\n if (m) {\r\n queuePostRenderEffect(m, parentSuspense);\r\n }\r\n // onVnodeMounted\r\n if (!isAsyncWrapperVNode &&\r\n (vnodeHook = props && props.onVnodeMounted)) {\r\n const scopedInitialVNode = initialVNode;\r\n queuePostRenderEffect(() => invokeVNodeHook(vnodeHook, parent, scopedInitialVNode), parentSuspense);\r\n }\r\n // activated hook for keep-alive roots.\r\n // #1742 activated hook must be accessed after first render\r\n // since the hook may be injected by a child keep-alive\r\n if (initialVNode.shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */) {\r\n instance.a && queuePostRenderEffect(instance.a, parentSuspense);\r\n }\r\n instance.isMounted = true;\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentAdded(instance);\r\n }\r\n // #2458: deference mount-only object parameters to prevent memleaks\r\n initialVNode = container = anchor = null;\r\n }\r\n else {\r\n // updateComponent\r\n // This is triggered by mutation of component's own state (next: null)\r\n // OR parent calling processComponent (next: VNode)\r\n let { next, bu, u, parent, vnode } = instance;\r\n let originNext = next;\r\n let vnodeHook;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n pushWarningContext(next || instance.vnode);\r\n }\r\n // Disallow component effect recursion during pre-lifecycle hooks.\r\n effect.allowRecurse = false;\r\n if (next) {\r\n next.el = vnode.el;\r\n updateComponentPreRender(instance, next, optimized);\r\n }\r\n else {\r\n next = vnode;\r\n }\r\n // beforeUpdate hook\r\n if (bu) {\r\n invokeArrayFns(bu);\r\n }\r\n // onVnodeBeforeUpdate\r\n if ((vnodeHook = next.props && next.props.onVnodeBeforeUpdate)) {\r\n invokeVNodeHook(vnodeHook, parent, next, vnode);\r\n }\r\n effect.allowRecurse = true;\r\n // render\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `render`);\r\n }\r\n const nextTree = renderComponentRoot(instance);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `render`);\r\n }\r\n const prevTree = instance.subTree;\r\n instance.subTree = nextTree;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `patch`);\r\n }\r\n patch(prevTree, nextTree, \r\n // parent may have changed if it's in a teleport\r\n hostParentNode(prevTree.el), \r\n // anchor may have changed if it's in a fragment\r\n getNextHostNode(prevTree), instance, parentSuspense, isSVG);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `patch`);\r\n }\r\n next.el = nextTree.el;\r\n if (originNext === null) {\r\n // self-triggered update. In case of HOC, update parent component\r\n // vnode el. HOC is indicated by parent instance's subTree pointing\r\n // to child component's vnode\r\n updateHOCHostEl(instance, nextTree.el);\r\n }\r\n // updated hook\r\n if (u) {\r\n queuePostRenderEffect(u, parentSuspense);\r\n }\r\n // onVnodeUpdated\r\n if ((vnodeHook = next.props && next.props.onVnodeUpdated)) {\r\n queuePostRenderEffect(() => invokeVNodeHook(vnodeHook, parent, next, vnode), parentSuspense);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentUpdated(instance);\r\n }\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n popWarningContext();\r\n }\r\n }\r\n };\r\n // create reactive effect for rendering\r\n const effect = new ReactiveEffect(componentUpdateFn, () => queueJob(instance.update), instance.scope // track it in component's effect scope\r\n );\r\n const update = (instance.update = effect.run.bind(effect));\r\n update.id = instance.uid;\r\n // allowRecurse\r\n // #1801, #2043 component render effects should allow recursive updates\r\n effect.allowRecurse = update.allowRecurse = true;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n effect.onTrack = instance.rtc\r\n ? e => invokeArrayFns(instance.rtc, e)\r\n : void 0;\r\n effect.onTrigger = instance.rtg\r\n ? e => invokeArrayFns(instance.rtg, e)\r\n : void 0;\r\n // @ts-ignore (for scheduler)\r\n update.ownerInstance = instance;\r\n }\r\n update();\r\n };\r\n const updateComponentPreRender = (instance, nextVNode, optimized) => {\r\n nextVNode.component = instance;\r\n const prevProps = instance.vnode.props;\r\n instance.vnode = nextVNode;\r\n instance.next = null;\r\n updateProps(instance, nextVNode.props, prevProps, optimized);\r\n updateSlots(instance, nextVNode.children, optimized);\r\n pauseTracking();\r\n // props update may have triggered pre-flush watchers.\r\n // flush them before the render update.\r\n flushPreFlushCbs(undefined, instance.update);\r\n resetTracking();\r\n };\r\n const patchChildren = (n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized = false) => {\r\n const c1 = n1 && n1.children;\r\n const prevShapeFlag = n1 ? n1.shapeFlag : 0;\r\n const c2 = n2.children;\r\n const { patchFlag, shapeFlag } = n2;\r\n // fast path\r\n if (patchFlag > 0) {\r\n if (patchFlag & 128 /* KEYED_FRAGMENT */) {\r\n // this could be either fully-keyed or mixed (some keyed some not)\r\n // presence of patchFlag means children are guaranteed to be arrays\r\n patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n return;\r\n }\r\n else if (patchFlag & 256 /* UNKEYED_FRAGMENT */) {\r\n // unkeyed\r\n patchUnkeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n return;\r\n }\r\n }\r\n // children has 3 possibilities: text, array or no children.\r\n if (shapeFlag & 8 /* TEXT_CHILDREN */) {\r\n // text children fast path\r\n if (prevShapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n unmountChildren(c1, parentComponent, parentSuspense);\r\n }\r\n if (c2 !== c1) {\r\n hostSetElementText(container, c2);\r\n }\r\n }\r\n else {\r\n if (prevShapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n // prev children was array\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n // two arrays, cannot assume anything, do full diff\r\n patchKeyedChildren(c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n // no new children, just unmount old\r\n unmountChildren(c1, parentComponent, parentSuspense, true);\r\n }\r\n }\r\n else {\r\n // prev children was text OR null\r\n // new children is array OR null\r\n if (prevShapeFlag & 8 /* TEXT_CHILDREN */) {\r\n hostSetElementText(container, '');\r\n }\r\n // mount new if array\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n mountChildren(c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n }\r\n }\r\n };\r\n const patchUnkeyedChildren = (c1, c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n c1 = c1 || EMPTY_ARR;\r\n c2 = c2 || EMPTY_ARR;\r\n const oldLength = c1.length;\r\n const newLength = c2.length;\r\n const commonLength = Math.min(oldLength, newLength);\r\n let i;\r\n for (i = 0; i < commonLength; i++) {\r\n const nextChild = (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i]));\r\n patch(c1[i], nextChild, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n if (oldLength > newLength) {\r\n // remove old\r\n unmountChildren(c1, parentComponent, parentSuspense, true, false, commonLength);\r\n }\r\n else {\r\n // mount new\r\n mountChildren(c2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, commonLength);\r\n }\r\n };\r\n // can be all-keyed or mixed\r\n const patchKeyedChildren = (c1, c2, container, parentAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized) => {\r\n let i = 0;\r\n const l2 = c2.length;\r\n let e1 = c1.length - 1; // prev ending index\r\n let e2 = l2 - 1; // next ending index\r\n // 1. sync from start\r\n // (a b) c\r\n // (a b) d e\r\n while (i <= e1 && i <= e2) {\r\n const n1 = c1[i];\r\n const n2 = (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i]));\r\n if (isSameVNodeType(n1, n2)) {\r\n patch(n1, n2, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n break;\r\n }\r\n i++;\r\n }\r\n // 2. sync from end\r\n // a (b c)\r\n // d e (b c)\r\n while (i <= e1 && i <= e2) {\r\n const n1 = c1[e1];\r\n const n2 = (c2[e2] = optimized\r\n ? cloneIfMounted(c2[e2])\r\n : normalizeVNode(c2[e2]));\r\n if (isSameVNodeType(n1, n2)) {\r\n patch(n1, n2, container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else {\r\n break;\r\n }\r\n e1--;\r\n e2--;\r\n }\r\n // 3. common sequence + mount\r\n // (a b)\r\n // (a b) c\r\n // i = 2, e1 = 1, e2 = 2\r\n // (a b)\r\n // c (a b)\r\n // i = 0, e1 = -1, e2 = 0\r\n if (i > e1) {\r\n if (i <= e2) {\r\n const nextPos = e2 + 1;\r\n const anchor = nextPos < l2 ? c2[nextPos].el : parentAnchor;\r\n while (i <= e2) {\r\n patch(null, (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i])), container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n i++;\r\n }\r\n }\r\n }\r\n // 4. common sequence + unmount\r\n // (a b) c\r\n // (a b)\r\n // i = 2, e1 = 2, e2 = 1\r\n // a (b c)\r\n // (b c)\r\n // i = 0, e1 = 0, e2 = -1\r\n else if (i > e2) {\r\n while (i <= e1) {\r\n unmount(c1[i], parentComponent, parentSuspense, true);\r\n i++;\r\n }\r\n }\r\n // 5. unknown sequence\r\n // [i ... e1 + 1]: a b [c d e] f g\r\n // [i ... e2 + 1]: a b [e d c h] f g\r\n // i = 2, e1 = 4, e2 = 5\r\n else {\r\n const s1 = i; // prev starting index\r\n const s2 = i; // next starting index\r\n // 5.1 build key:index map for newChildren\r\n const keyToNewIndexMap = new Map();\r\n for (i = s2; i <= e2; i++) {\r\n const nextChild = (c2[i] = optimized\r\n ? cloneIfMounted(c2[i])\r\n : normalizeVNode(c2[i]));\r\n if (nextChild.key != null) {\r\n if ((process.env.NODE_ENV !== 'production') && keyToNewIndexMap.has(nextChild.key)) {\r\n warn(`Duplicate keys found during update:`, JSON.stringify(nextChild.key), `Make sure keys are unique.`);\r\n }\r\n keyToNewIndexMap.set(nextChild.key, i);\r\n }\r\n }\r\n // 5.2 loop through old children left to be patched and try to patch\r\n // matching nodes & remove nodes that are no longer present\r\n let j;\r\n let patched = 0;\r\n const toBePatched = e2 - s2 + 1;\r\n let moved = false;\r\n // used to track whether any node has moved\r\n let maxNewIndexSoFar = 0;\r\n // works as Map<newIndex, oldIndex>\r\n // Note that oldIndex is offset by +1\r\n // and oldIndex = 0 is a special value indicating the new node has\r\n // no corresponding old node.\r\n // used for determining longest stable subsequence\r\n const newIndexToOldIndexMap = new Array(toBePatched);\r\n for (i = 0; i < toBePatched; i++)\r\n newIndexToOldIndexMap[i] = 0;\r\n for (i = s1; i <= e1; i++) {\r\n const prevChild = c1[i];\r\n if (patched >= toBePatched) {\r\n // all new children have been patched so this can only be a removal\r\n unmount(prevChild, parentComponent, parentSuspense, true);\r\n continue;\r\n }\r\n let newIndex;\r\n if (prevChild.key != null) {\r\n newIndex = keyToNewIndexMap.get(prevChild.key);\r\n }\r\n else {\r\n // key-less node, try to locate a key-less node of the same type\r\n for (j = s2; j <= e2; j++) {\r\n if (newIndexToOldIndexMap[j - s2] === 0 &&\r\n isSameVNodeType(prevChild, c2[j])) {\r\n newIndex = j;\r\n break;\r\n }\r\n }\r\n }\r\n if (newIndex === undefined) {\r\n unmount(prevChild, parentComponent, parentSuspense, true);\r\n }\r\n else {\r\n newIndexToOldIndexMap[newIndex - s2] = i + 1;\r\n if (newIndex >= maxNewIndexSoFar) {\r\n maxNewIndexSoFar = newIndex;\r\n }\r\n else {\r\n moved = true;\r\n }\r\n patch(prevChild, c2[newIndex], container, null, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n patched++;\r\n }\r\n }\r\n // 5.3 move and mount\r\n // generate longest stable subsequence only when nodes have moved\r\n const increasingNewIndexSequence = moved\r\n ? getSequence(newIndexToOldIndexMap)\r\n : EMPTY_ARR;\r\n j = increasingNewIndexSequence.length - 1;\r\n // looping backwards so that we can use last patched node as anchor\r\n for (i = toBePatched - 1; i >= 0; i--) {\r\n const nextIndex = s2 + i;\r\n const nextChild = c2[nextIndex];\r\n const anchor = nextIndex + 1 < l2 ? c2[nextIndex + 1].el : parentAnchor;\r\n if (newIndexToOldIndexMap[i] === 0) {\r\n // mount new\r\n patch(null, nextChild, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n else if (moved) {\r\n // move if:\r\n // There is no stable subsequence (e.g. a reverse)\r\n // OR current node is not among the stable sequence\r\n if (j < 0 || i !== increasingNewIndexSequence[j]) {\r\n move(nextChild, container, anchor, 2 /* REORDER */);\r\n }\r\n else {\r\n j--;\r\n }\r\n }\r\n }\r\n }\r\n };\r\n const move = (vnode, container, anchor, moveType, parentSuspense = null) => {\r\n const { el, type, transition, children, shapeFlag } = vnode;\r\n if (shapeFlag & 6 /* COMPONENT */) {\r\n move(vnode.component.subTree, container, anchor, moveType);\r\n return;\r\n }\r\n if (shapeFlag & 128 /* SUSPENSE */) {\r\n vnode.suspense.move(container, anchor, moveType);\r\n return;\r\n }\r\n if (shapeFlag & 64 /* TELEPORT */) {\r\n type.move(vnode, container, anchor, internals);\r\n return;\r\n }\r\n if (type === Fragment) {\r\n hostInsert(el, container, anchor);\r\n for (let i = 0; i < children.length; i++) {\r\n move(children[i], container, anchor, moveType);\r\n }\r\n hostInsert(vnode.anchor, container, anchor);\r\n return;\r\n }\r\n if (type === Static) {\r\n moveStaticNode(vnode, container, anchor);\r\n return;\r\n }\r\n // single nodes\r\n const needTransition = moveType !== 2 /* REORDER */ &&\r\n shapeFlag & 1 /* ELEMENT */ &&\r\n transition;\r\n if (needTransition) {\r\n if (moveType === 0 /* ENTER */) {\r\n transition.beforeEnter(el);\r\n hostInsert(el, container, anchor);\r\n queuePostRenderEffect(() => transition.enter(el), parentSuspense);\r\n }\r\n else {\r\n const { leave, delayLeave, afterLeave } = transition;\r\n const remove = () => hostInsert(el, container, anchor);\r\n const performLeave = () => {\r\n leave(el, () => {\r\n remove();\r\n afterLeave && afterLeave();\r\n });\r\n };\r\n if (delayLeave) {\r\n delayLeave(el, remove, performLeave);\r\n }\r\n else {\r\n performLeave();\r\n }\r\n }\r\n }\r\n else {\r\n hostInsert(el, container, anchor);\r\n }\r\n };\r\n const unmount = (vnode, parentComponent, parentSuspense, doRemove = false, optimized = false) => {\r\n const { type, props, ref, children, dynamicChildren, shapeFlag, patchFlag, dirs } = vnode;\r\n // unset ref\r\n if (ref != null) {\r\n setRef(ref, null, parentSuspense, vnode, true);\r\n }\r\n if (shapeFlag & 256 /* COMPONENT_SHOULD_KEEP_ALIVE */) {\r\n parentComponent.ctx.deactivate(vnode);\r\n return;\r\n }\r\n const shouldInvokeDirs = shapeFlag & 1 /* ELEMENT */ && dirs;\r\n const shouldInvokeVnodeHook = !isAsyncWrapper(vnode);\r\n let vnodeHook;\r\n if (shouldInvokeVnodeHook &&\r\n (vnodeHook = props && props.onVnodeBeforeUnmount)) {\r\n invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n }\r\n if (shapeFlag & 6 /* COMPONENT */) {\r\n unmountComponent(vnode.component, parentSuspense, doRemove);\r\n }\r\n else {\r\n if (shapeFlag & 128 /* SUSPENSE */) {\r\n vnode.suspense.unmount(parentSuspense, doRemove);\r\n return;\r\n }\r\n if (shouldInvokeDirs) {\r\n invokeDirectiveHook(vnode, null, parentComponent, 'beforeUnmount');\r\n }\r\n if (shapeFlag & 64 /* TELEPORT */) {\r\n vnode.type.remove(vnode, parentComponent, parentSuspense, optimized, internals, doRemove);\r\n }\r\n else if (dynamicChildren &&\r\n // #1153: fast path should not be taken for non-stable (v-for) fragments\r\n (type !== Fragment ||\r\n (patchFlag > 0 && patchFlag & 64 /* STABLE_FRAGMENT */))) {\r\n // fast path for block nodes: only need to unmount dynamic children.\r\n unmountChildren(dynamicChildren, parentComponent, parentSuspense, false, true);\r\n }\r\n else if ((type === Fragment &&\r\n patchFlag &\r\n (128 /* KEYED_FRAGMENT */ | 256 /* UNKEYED_FRAGMENT */)) ||\r\n (!optimized && shapeFlag & 16 /* ARRAY_CHILDREN */)) {\r\n unmountChildren(children, parentComponent, parentSuspense);\r\n }\r\n if (doRemove) {\r\n remove(vnode);\r\n }\r\n }\r\n if ((shouldInvokeVnodeHook &&\r\n (vnodeHook = props && props.onVnodeUnmounted)) ||\r\n shouldInvokeDirs) {\r\n queuePostRenderEffect(() => {\r\n vnodeHook && invokeVNodeHook(vnodeHook, parentComponent, vnode);\r\n shouldInvokeDirs &&\r\n invokeDirectiveHook(vnode, null, parentComponent, 'unmounted');\r\n }, parentSuspense);\r\n }\r\n };\r\n const remove = vnode => {\r\n const { type, el, anchor, transition } = vnode;\r\n if (type === Fragment) {\r\n removeFragment(el, anchor);\r\n return;\r\n }\r\n if (type === Static) {\r\n removeStaticNode(vnode);\r\n return;\r\n }\r\n const performRemove = () => {\r\n hostRemove(el);\r\n if (transition && !transition.persisted && transition.afterLeave) {\r\n transition.afterLeave();\r\n }\r\n };\r\n if (vnode.shapeFlag & 1 /* ELEMENT */ &&\r\n transition &&\r\n !transition.persisted) {\r\n const { leave, delayLeave } = transition;\r\n const performLeave = () => leave(el, performRemove);\r\n if (delayLeave) {\r\n delayLeave(vnode.el, performRemove, performLeave);\r\n }\r\n else {\r\n performLeave();\r\n }\r\n }\r\n else {\r\n performRemove();\r\n }\r\n };\r\n const removeFragment = (cur, end) => {\r\n // For fragments, directly remove all contained DOM nodes.\r\n // (fragment child nodes cannot have transition)\r\n let next;\r\n while (cur !== end) {\r\n next = hostNextSibling(cur);\r\n hostRemove(cur);\r\n cur = next;\r\n }\r\n hostRemove(end);\r\n };\r\n const unmountComponent = (instance, parentSuspense, doRemove) => {\r\n if ((process.env.NODE_ENV !== 'production') && instance.type.__hmrId) {\r\n unregisterHMR(instance);\r\n }\r\n const { bum, scope, update, subTree, um } = instance;\r\n // beforeUnmount hook\r\n if (bum) {\r\n invokeArrayFns(bum);\r\n }\r\n // stop effects in component scope\r\n scope.stop();\r\n // update may be null if a component is unmounted before its async\r\n // setup has resolved.\r\n if (update) {\r\n // so that scheduler will no longer invoke it\r\n update.active = false;\r\n unmount(subTree, instance, parentSuspense, doRemove);\r\n }\r\n // unmounted hook\r\n if (um) {\r\n queuePostRenderEffect(um, parentSuspense);\r\n }\r\n queuePostRenderEffect(() => {\r\n instance.isUnmounted = true;\r\n }, parentSuspense);\r\n // A component with async dep inside a pending suspense is unmounted before\r\n // its async dep resolves. This should remove the dep from the suspense, and\r\n // cause the suspense to resolve immediately if that was the last dep.\r\n if (parentSuspense &&\r\n parentSuspense.pendingBranch &&\r\n !parentSuspense.isUnmounted &&\r\n instance.asyncDep &&\r\n !instance.asyncResolved &&\r\n instance.suspenseId === parentSuspense.pendingId) {\r\n parentSuspense.deps--;\r\n if (parentSuspense.deps === 0) {\r\n parentSuspense.resolve();\r\n }\r\n }\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n devtoolsComponentRemoved(instance);\r\n }\r\n };\r\n const unmountChildren = (children, parentComponent, parentSuspense, doRemove = false, optimized = false, start = 0) => {\r\n for (let i = start; i < children.length; i++) {\r\n unmount(children[i], parentComponent, parentSuspense, doRemove, optimized);\r\n }\r\n };\r\n const getNextHostNode = vnode => {\r\n if (vnode.shapeFlag & 6 /* COMPONENT */) {\r\n return getNextHostNode(vnode.component.subTree);\r\n }\r\n if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n return vnode.suspense.next();\r\n }\r\n return hostNextSibling((vnode.anchor || vnode.el));\r\n };\r\n const render = (vnode, container, isSVG) => {\r\n if (vnode == null) {\r\n if (container._vnode) {\r\n unmount(container._vnode, null, null, true);\r\n }\r\n }\r\n else {\r\n patch(container._vnode || null, vnode, container, null, null, null, isSVG);\r\n }\r\n flushPostFlushCbs();\r\n container._vnode = vnode;\r\n };\r\n const internals = {\r\n p: patch,\r\n um: unmount,\r\n m: move,\r\n r: remove,\r\n mt: mountComponent,\r\n mc: mountChildren,\r\n pc: patchChildren,\r\n pbc: patchBlockChildren,\r\n n: getNextHostNode,\r\n o: options\r\n };\r\n let hydrate;\r\n let hydrateNode;\r\n if (createHydrationFns) {\r\n [hydrate, hydrateNode] = createHydrationFns(internals);\r\n }\r\n return {\r\n render,\r\n hydrate,\r\n createApp: createAppAPI(render, hydrate)\r\n };\r\n}\r\nfunction setRef(rawRef, oldRawRef, parentSuspense, vnode, isUnmount = false) {\r\n if (isArray(rawRef)) {\r\n rawRef.forEach((r, i) => setRef(r, oldRawRef && (isArray(oldRawRef) ? oldRawRef[i] : oldRawRef), parentSuspense, vnode, isUnmount));\r\n return;\r\n }\r\n if (isAsyncWrapper(vnode) && !isUnmount) {\r\n // when mounting async components, nothing needs to be done,\r\n // because the template ref is forwarded to inner component\r\n return;\r\n }\r\n const refValue = vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */\r\n ? getExposeProxy(vnode.component) || vnode.component.proxy\r\n : vnode.el;\r\n const value = isUnmount ? null : refValue;\r\n const { i: owner, r: ref } = rawRef;\r\n if ((process.env.NODE_ENV !== 'production') && !owner) {\r\n warn(`Missing ref owner context. ref cannot be used on hoisted vnodes. ` +\r\n `A vnode with ref must be created inside the render function.`);\r\n return;\r\n }\r\n const oldRef = oldRawRef && oldRawRef.r;\r\n const refs = owner.refs === EMPTY_OBJ ? (owner.refs = {}) : owner.refs;\r\n const setupState = owner.setupState;\r\n // dynamic ref changed. unset old ref\r\n if (oldRef != null && oldRef !== ref) {\r\n if (isString(oldRef)) {\r\n refs[oldRef] = null;\r\n if (hasOwn(setupState, oldRef)) {\r\n setupState[oldRef] = null;\r\n }\r\n }\r\n else if (isRef(oldRef)) {\r\n oldRef.value = null;\r\n }\r\n }\r\n if (isString(ref)) {\r\n const doSet = () => {\r\n {\r\n refs[ref] = value;\r\n }\r\n if (hasOwn(setupState, ref)) {\r\n setupState[ref] = value;\r\n }\r\n };\r\n // #1789: for non-null values, set them after render\r\n // null values means this is unmount and it should not overwrite another\r\n // ref with the same key\r\n if (value) {\r\n doSet.id = -1;\r\n queuePostRenderEffect(doSet, parentSuspense);\r\n }\r\n else {\r\n doSet();\r\n }\r\n }\r\n else if (isRef(ref)) {\r\n const doSet = () => {\r\n ref.value = value;\r\n };\r\n if (value) {\r\n doSet.id = -1;\r\n queuePostRenderEffect(doSet, parentSuspense);\r\n }\r\n else {\r\n doSet();\r\n }\r\n }\r\n else if (isFunction(ref)) {\r\n callWithErrorHandling(ref, owner, 12 /* FUNCTION_REF */, [value, refs]);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid template ref type:', value, `(${typeof value})`);\r\n }\r\n}\r\nfunction invokeVNodeHook(hook, instance, vnode, prevVNode = null) {\r\n callWithAsyncErrorHandling(hook, instance, 7 /* VNODE_HOOK */, [\r\n vnode,\r\n prevVNode\r\n ]);\r\n}\r\n/**\r\n * #1156\r\n * When a component is HMR-enabled, we need to make sure that all static nodes\r\n * inside a block also inherit the DOM element from the previous tree so that\r\n * HMR updates (which are full updates) can retrieve the element for patching.\r\n *\r\n * #2080\r\n * Inside keyed `template` fragment static children, if a fragment is moved,\r\n * the children will always be moved. Therefore, in order to ensure correct move\r\n * position, el should be inherited from previous nodes.\r\n */\r\nfunction traverseStaticChildren(n1, n2, shallow = false) {\r\n const ch1 = n1.children;\r\n const ch2 = n2.children;\r\n if (isArray(ch1) && isArray(ch2)) {\r\n for (let i = 0; i < ch1.length; i++) {\r\n // this is only called in the optimized path so array children are\r\n // guaranteed to be vnodes\r\n const c1 = ch1[i];\r\n let c2 = ch2[i];\r\n if (c2.shapeFlag & 1 /* ELEMENT */ && !c2.dynamicChildren) {\r\n if (c2.patchFlag <= 0 || c2.patchFlag === 32 /* HYDRATE_EVENTS */) {\r\n c2 = ch2[i] = cloneIfMounted(ch2[i]);\r\n c2.el = c1.el;\r\n }\r\n if (!shallow)\r\n traverseStaticChildren(c1, c2);\r\n }\r\n // also inherit for comment nodes, but not placeholders (e.g. v-if which\r\n // would have received .el during block patch)\r\n if ((process.env.NODE_ENV !== 'production') && c2.type === Comment && !c2.el) {\r\n c2.el = c1.el;\r\n }\r\n }\r\n }\r\n}\r\n// https://en.wikipedia.org/wiki/Longest_increasing_subsequence\r\nfunction getSequence(arr) {\r\n const p = arr.slice();\r\n const result = [0];\r\n let i, j, u, v, c;\r\n const len = arr.length;\r\n for (i = 0; i < len; i++) {\r\n const arrI = arr[i];\r\n if (arrI !== 0) {\r\n j = result[result.length - 1];\r\n if (arr[j] < arrI) {\r\n p[i] = j;\r\n result.push(i);\r\n continue;\r\n }\r\n u = 0;\r\n v = result.length - 1;\r\n while (u < v) {\r\n c = (u + v) >> 1;\r\n if (arr[result[c]] < arrI) {\r\n u = c + 1;\r\n }\r\n else {\r\n v = c;\r\n }\r\n }\r\n if (arrI < arr[result[u]]) {\r\n if (u > 0) {\r\n p[i] = result[u - 1];\r\n }\r\n result[u] = i;\r\n }\r\n }\r\n }\r\n u = result.length;\r\n v = result[u - 1];\r\n while (u-- > 0) {\r\n result[u] = v;\r\n v = p[v];\r\n }\r\n return result;\r\n}\n\nconst isTeleport = (type) => type.__isTeleport;\r\nconst isTeleportDisabled = (props) => props && (props.disabled || props.disabled === '');\r\nconst isTargetSVG = (target) => typeof SVGElement !== 'undefined' && target instanceof SVGElement;\r\nconst resolveTarget = (props, select) => {\r\n const targetSelector = props && props.to;\r\n if (isString(targetSelector)) {\r\n if (!select) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Current renderer does not support string target for Teleports. ` +\r\n `(missing querySelector renderer option)`);\r\n return null;\r\n }\r\n else {\r\n const target = select(targetSelector);\r\n if (!target) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Failed to locate Teleport target with selector \"${targetSelector}\". ` +\r\n `Note the target element must exist before the component is mounted - ` +\r\n `i.e. the target cannot be rendered by the component itself, and ` +\r\n `ideally should be outside of the entire Vue component tree.`);\r\n }\r\n return target;\r\n }\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production') && !targetSelector && !isTeleportDisabled(props)) {\r\n warn(`Invalid Teleport target: ${targetSelector}`);\r\n }\r\n return targetSelector;\r\n }\r\n};\r\nconst TeleportImpl = {\r\n __isTeleport: true,\r\n process(n1, n2, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized, internals) {\r\n const { mc: mountChildren, pc: patchChildren, pbc: patchBlockChildren, o: { insert, querySelector, createText, createComment } } = internals;\r\n const disabled = isTeleportDisabled(n2.props);\r\n let { shapeFlag, children, dynamicChildren } = n2;\r\n // #3302\r\n // HMR updated, force full diff\r\n if ((process.env.NODE_ENV !== 'production') && isHmrUpdating) {\r\n optimized = false;\r\n dynamicChildren = null;\r\n }\r\n if (n1 == null) {\r\n // insert anchors in the main view\r\n const placeholder = (n2.el = (process.env.NODE_ENV !== 'production')\r\n ? createComment('teleport start')\r\n : createText(''));\r\n const mainAnchor = (n2.anchor = (process.env.NODE_ENV !== 'production')\r\n ? createComment('teleport end')\r\n : createText(''));\r\n insert(placeholder, container, anchor);\r\n insert(mainAnchor, container, anchor);\r\n const target = (n2.target = resolveTarget(n2.props, querySelector));\r\n const targetAnchor = (n2.targetAnchor = createText(''));\r\n if (target) {\r\n insert(targetAnchor, target);\r\n // #2652 we could be teleporting from a non-SVG tree into an SVG tree\r\n isSVG = isSVG || isTargetSVG(target);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') && !disabled) {\r\n warn('Invalid Teleport target on mount:', target, `(${typeof target})`);\r\n }\r\n const mount = (container, anchor) => {\r\n // Teleport *always* has Array children. This is enforced in both the\r\n // compiler and vnode children normalization.\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n mountChildren(children, container, anchor, parentComponent, parentSuspense, isSVG, slotScopeIds, optimized);\r\n }\r\n };\r\n if (disabled) {\r\n mount(container, mainAnchor);\r\n }\r\n else if (target) {\r\n mount(target, targetAnchor);\r\n }\r\n }\r\n else {\r\n // update content\r\n n2.el = n1.el;\r\n const mainAnchor = (n2.anchor = n1.anchor);\r\n const target = (n2.target = n1.target);\r\n const targetAnchor = (n2.targetAnchor = n1.targetAnchor);\r\n const wasDisabled = isTeleportDisabled(n1.props);\r\n const currentContainer = wasDisabled ? container : target;\r\n const currentAnchor = wasDisabled ? mainAnchor : targetAnchor;\r\n isSVG = isSVG || isTargetSVG(target);\r\n if (dynamicChildren) {\r\n // fast path when the teleport happens to be a block root\r\n patchBlockChildren(n1.dynamicChildren, dynamicChildren, currentContainer, parentComponent, parentSuspense, isSVG, slotScopeIds);\r\n // even in block tree mode we need to make sure all root-level nodes\r\n // in the teleport inherit previous DOM references so that they can\r\n // be moved in future patches.\r\n traverseStaticChildren(n1, n2, true);\r\n }\r\n else if (!optimized) {\r\n patchChildren(n1, n2, currentContainer, currentAnchor, parentComponent, parentSuspense, isSVG, slotScopeIds, false);\r\n }\r\n if (disabled) {\r\n if (!wasDisabled) {\r\n // enabled -> disabled\r\n // move into main container\r\n moveTeleport(n2, container, mainAnchor, internals, 1 /* TOGGLE */);\r\n }\r\n }\r\n else {\r\n // target changed\r\n if ((n2.props && n2.props.to) !== (n1.props && n1.props.to)) {\r\n const nextTarget = (n2.target = resolveTarget(n2.props, querySelector));\r\n if (nextTarget) {\r\n moveTeleport(n2, nextTarget, null, internals, 0 /* TARGET_CHANGE */);\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn('Invalid Teleport target on update:', target, `(${typeof target})`);\r\n }\r\n }\r\n else if (wasDisabled) {\r\n // disabled -> enabled\r\n // move into teleport target\r\n moveTeleport(n2, target, targetAnchor, internals, 1 /* TOGGLE */);\r\n }\r\n }\r\n }\r\n },\r\n remove(vnode, parentComponent, parentSuspense, optimized, { um: unmount, o: { remove: hostRemove } }, doRemove) {\r\n const { shapeFlag, children, anchor, targetAnchor, target, props } = vnode;\r\n if (target) {\r\n hostRemove(targetAnchor);\r\n }\r\n // an unmounted teleport should always remove its children if not disabled\r\n if (doRemove || !isTeleportDisabled(props)) {\r\n hostRemove(anchor);\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n unmount(child, parentComponent, parentSuspense, true, !!child.dynamicChildren);\r\n }\r\n }\r\n }\r\n },\r\n move: moveTeleport,\r\n hydrate: hydrateTeleport\r\n};\r\nfunction moveTeleport(vnode, container, parentAnchor, { o: { insert }, m: move }, moveType = 2 /* REORDER */) {\r\n // move target anchor if this is a target change.\r\n if (moveType === 0 /* TARGET_CHANGE */) {\r\n insert(vnode.targetAnchor, container, parentAnchor);\r\n }\r\n const { el, anchor, shapeFlag, children, props } = vnode;\r\n const isReorder = moveType === 2 /* REORDER */;\r\n // move main view anchor if this is a re-order.\r\n if (isReorder) {\r\n insert(el, container, parentAnchor);\r\n }\r\n // if this is a re-order and teleport is enabled (content is in target)\r\n // do not move children. So the opposite is: only move children if this\r\n // is not a reorder, or the teleport is disabled\r\n if (!isReorder || isTeleportDisabled(props)) {\r\n // Teleport has either Array children or no children.\r\n if (shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n for (let i = 0; i < children.length; i++) {\r\n move(children[i], container, parentAnchor, 2 /* REORDER */);\r\n }\r\n }\r\n }\r\n // move main view anchor if this is a re-order.\r\n if (isReorder) {\r\n insert(anchor, container, parentAnchor);\r\n }\r\n}\r\nfunction hydrateTeleport(node, vnode, parentComponent, parentSuspense, slotScopeIds, optimized, { o: { nextSibling, parentNode, querySelector } }, hydrateChildren) {\r\n const target = (vnode.target = resolveTarget(vnode.props, querySelector));\r\n if (target) {\r\n // if multiple teleports rendered to the same target element, we need to\r\n // pick up from where the last teleport finished instead of the first node\r\n const targetNode = target._lpa || target.firstChild;\r\n if (vnode.shapeFlag & 16 /* ARRAY_CHILDREN */) {\r\n if (isTeleportDisabled(vnode.props)) {\r\n vnode.anchor = hydrateChildren(nextSibling(node), vnode, parentNode(node), parentComponent, parentSuspense, slotScopeIds, optimized);\r\n vnode.targetAnchor = targetNode;\r\n }\r\n else {\r\n vnode.anchor = nextSibling(node);\r\n vnode.targetAnchor = hydrateChildren(targetNode, vnode, target, parentComponent, parentSuspense, slotScopeIds, optimized);\r\n }\r\n target._lpa =\r\n vnode.targetAnchor && nextSibling(vnode.targetAnchor);\r\n }\r\n }\r\n return vnode.anchor && nextSibling(vnode.anchor);\r\n}\r\n// Force-casted public typing for h and TSX props inference\r\nconst Teleport = TeleportImpl;\n\nconst COMPONENTS = 'components';\r\nconst DIRECTIVES = 'directives';\r\n/**\r\n * @private\r\n */\r\nfunction resolveComponent(name, maybeSelfReference) {\r\n return resolveAsset(COMPONENTS, name, true, maybeSelfReference) || name;\r\n}\r\nconst NULL_DYNAMIC_COMPONENT = Symbol();\r\n/**\r\n * @private\r\n */\r\nfunction resolveDynamicComponent(component) {\r\n if (isString(component)) {\r\n return resolveAsset(COMPONENTS, component, false) || component;\r\n }\r\n else {\r\n // invalid types will fallthrough to createVNode and raise warning\r\n return (component || NULL_DYNAMIC_COMPONENT);\r\n }\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction resolveDirective(name) {\r\n return resolveAsset(DIRECTIVES, name);\r\n}\r\n// implementation\r\nfunction resolveAsset(type, name, warnMissing = true, maybeSelfReference = false) {\r\n const instance = currentRenderingInstance || currentInstance;\r\n if (instance) {\r\n const Component = instance.type;\r\n // explicit self name has highest priority\r\n if (type === COMPONENTS) {\r\n const selfName = getComponentName(Component);\r\n if (selfName &&\r\n (selfName === name ||\r\n selfName === camelize(name) ||\r\n selfName === capitalize(camelize(name)))) {\r\n return Component;\r\n }\r\n }\r\n const res = \r\n // local registration\r\n // check instance[type] first which is resolved for options API\r\n resolve(instance[type] || Component[type], name) ||\r\n // global registration\r\n resolve(instance.appContext[type], name);\r\n if (!res && maybeSelfReference) {\r\n // fallback to implicit self-reference\r\n return Component;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && warnMissing && !res) {\r\n const extra = type === COMPONENTS\r\n ? `\\nIf this is a native custom element, make sure to exclude it from ` +\r\n `component resolution via compilerOptions.isCustomElement.`\r\n : ``;\r\n warn(`Failed to resolve ${type.slice(0, -1)}: ${name}${extra}`);\r\n }\r\n return res;\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`resolve${capitalize(type.slice(0, -1))} ` +\r\n `can only be used in render() or setup().`);\r\n }\r\n}\r\nfunction resolve(registry, name) {\r\n return (registry &&\r\n (registry[name] ||\r\n registry[camelize(name)] ||\r\n registry[capitalize(camelize(name))]));\r\n}\n\nconst Fragment = Symbol((process.env.NODE_ENV !== 'production') ? 'Fragment' : undefined);\r\nconst Text = Symbol((process.env.NODE_ENV !== 'production') ? 'Text' : undefined);\r\nconst Comment = Symbol((process.env.NODE_ENV !== 'production') ? 'Comment' : undefined);\r\nconst Static = Symbol((process.env.NODE_ENV !== 'production') ? 'Static' : undefined);\r\n// Since v-if and v-for are the two possible ways node structure can dynamically\r\n// change, once we consider v-if branches and each v-for fragment a block, we\r\n// can divide a template into nested blocks, and within each block the node\r\n// structure would be stable. This allows us to skip most children diffing\r\n// and only worry about the dynamic nodes (indicated by patch flags).\r\nconst blockStack = [];\r\nlet currentBlock = null;\r\n/**\r\n * Open a block.\r\n * This must be called before `createBlock`. It cannot be part of `createBlock`\r\n * because the children of the block are evaluated before `createBlock` itself\r\n * is called. The generated code typically looks like this:\r\n *\r\n * ```js\r\n * function render() {\r\n * return (openBlock(),createBlock('div', null, [...]))\r\n * }\r\n * ```\r\n * disableTracking is true when creating a v-for fragment block, since a v-for\r\n * fragment always diffs its children.\r\n *\r\n * @private\r\n */\r\nfunction openBlock(disableTracking = false) {\r\n blockStack.push((currentBlock = disableTracking ? null : []));\r\n}\r\nfunction closeBlock() {\r\n blockStack.pop();\r\n currentBlock = blockStack[blockStack.length - 1] || null;\r\n}\r\n// Whether we should be tracking dynamic child nodes inside a block.\r\n// Only tracks when this value is > 0\r\n// We are not using a simple boolean because this value may need to be\r\n// incremented/decremented by nested usage of v-once (see below)\r\nlet isBlockTreeEnabled = 1;\r\n/**\r\n * Block tracking sometimes needs to be disabled, for example during the\r\n * creation of a tree that needs to be cached by v-once. The compiler generates\r\n * code like this:\r\n *\r\n * ``` js\r\n * _cache[1] || (\r\n * setBlockTracking(-1),\r\n * _cache[1] = createVNode(...),\r\n * setBlockTracking(1),\r\n * _cache[1]\r\n * )\r\n * ```\r\n *\r\n * @private\r\n */\r\nfunction setBlockTracking(value) {\r\n isBlockTreeEnabled += value;\r\n}\r\nfunction setupBlock(vnode) {\r\n // save current block children on the block vnode\r\n vnode.dynamicChildren =\r\n isBlockTreeEnabled > 0 ? currentBlock || EMPTY_ARR : null;\r\n // close block\r\n closeBlock();\r\n // a block is always going to be patched, so track it as a child of its\r\n // parent block\r\n if (isBlockTreeEnabled > 0 && currentBlock) {\r\n currentBlock.push(vnode);\r\n }\r\n return vnode;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createElementBlock(type, props, children, patchFlag, dynamicProps, shapeFlag) {\r\n return setupBlock(createBaseVNode(type, props, children, patchFlag, dynamicProps, shapeFlag, true /* isBlock */));\r\n}\r\n/**\r\n * Create a block root vnode. Takes the same exact arguments as `createVNode`.\r\n * A block root keeps track of dynamic nodes within the block in the\r\n * `dynamicChildren` array.\r\n *\r\n * @private\r\n */\r\nfunction createBlock(type, props, children, patchFlag, dynamicProps) {\r\n return setupBlock(createVNode(type, props, children, patchFlag, dynamicProps, true /* isBlock: prevent a block from tracking itself */));\r\n}\r\nfunction isVNode(value) {\r\n return value ? value.__v_isVNode === true : false;\r\n}\r\nfunction isSameVNodeType(n1, n2) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n n2.shapeFlag & 6 /* COMPONENT */ &&\r\n hmrDirtyComponents.has(n2.type)) {\r\n // HMR only: if the component has been hot-updated, force a reload.\r\n return false;\r\n }\r\n return n1.type === n2.type && n1.key === n2.key;\r\n}\r\nlet vnodeArgsTransformer;\r\n/**\r\n * Internal API for registering an arguments transform for createVNode\r\n * used for creating stubs in the test-utils\r\n * It is *internal* but needs to be exposed for test-utils to pick up proper\r\n * typings\r\n */\r\nfunction transformVNodeArgs(transformer) {\r\n vnodeArgsTransformer = transformer;\r\n}\r\nconst createVNodeWithArgsTransform = (...args) => {\r\n return _createVNode(...(vnodeArgsTransformer\r\n ? vnodeArgsTransformer(args, currentRenderingInstance)\r\n : args));\r\n};\r\nconst InternalObjectKey = `__vInternal`;\r\nconst normalizeKey = ({ key }) => key != null ? key : null;\r\nconst normalizeRef = ({ ref }) => {\r\n return (ref != null\r\n ? isString(ref) || isRef(ref) || isFunction(ref)\r\n ? { i: currentRenderingInstance, r: ref }\r\n : ref\r\n : null);\r\n};\r\nfunction createBaseVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, shapeFlag = type === Fragment ? 0 : 1 /* ELEMENT */, isBlockNode = false, needFullChildrenNormalization = false) {\r\n const vnode = {\r\n __v_isVNode: true,\r\n __v_skip: true,\r\n type,\r\n props,\r\n key: props && normalizeKey(props),\r\n ref: props && normalizeRef(props),\r\n scopeId: currentScopeId,\r\n slotScopeIds: null,\r\n children,\r\n component: null,\r\n suspense: null,\r\n ssContent: null,\r\n ssFallback: null,\r\n dirs: null,\r\n transition: null,\r\n el: null,\r\n anchor: null,\r\n target: null,\r\n targetAnchor: null,\r\n staticCount: 0,\r\n shapeFlag,\r\n patchFlag,\r\n dynamicProps,\r\n dynamicChildren: null,\r\n appContext: null\r\n };\r\n if (needFullChildrenNormalization) {\r\n normalizeChildren(vnode, children);\r\n // normalize suspense children\r\n if (shapeFlag & 128 /* SUSPENSE */) {\r\n type.normalize(vnode);\r\n }\r\n }\r\n else if (children) {\r\n // compiled element vnode - if children is passed, only possible types are\r\n // string or Array.\r\n vnode.shapeFlag |= isString(children)\r\n ? 8 /* TEXT_CHILDREN */\r\n : 16 /* ARRAY_CHILDREN */;\r\n }\r\n // validate key\r\n if ((process.env.NODE_ENV !== 'production') && vnode.key !== vnode.key) {\r\n warn(`VNode created with invalid key (NaN). VNode type:`, vnode.type);\r\n }\r\n // track vnode for block tree\r\n if (isBlockTreeEnabled > 0 &&\r\n // avoid a block node from tracking itself\r\n !isBlockNode &&\r\n // has current parent block\r\n currentBlock &&\r\n // presence of a patch flag indicates this node needs patching on updates.\r\n // component nodes also should always be patched, because even if the\r\n // component doesn't need to update, it needs to persist the instance on to\r\n // the next vnode so that it can be properly unmounted later.\r\n (vnode.patchFlag > 0 || shapeFlag & 6 /* COMPONENT */) &&\r\n // the EVENTS flag is only for hydration and if it is the only flag, the\r\n // vnode should not be considered dynamic due to handler caching.\r\n vnode.patchFlag !== 32 /* HYDRATE_EVENTS */) {\r\n currentBlock.push(vnode);\r\n }\r\n return vnode;\r\n}\r\nconst createVNode = ((process.env.NODE_ENV !== 'production') ? createVNodeWithArgsTransform : _createVNode);\r\nfunction _createVNode(type, props = null, children = null, patchFlag = 0, dynamicProps = null, isBlockNode = false) {\r\n if (!type || type === NULL_DYNAMIC_COMPONENT) {\r\n if ((process.env.NODE_ENV !== 'production') && !type) {\r\n warn(`Invalid vnode type when creating vnode: ${type}.`);\r\n }\r\n type = Comment;\r\n }\r\n if (isVNode(type)) {\r\n // createVNode receiving an existing vnode. This happens in cases like\r\n // <component :is=\"vnode\"/>\r\n // #2078 make sure to merge refs during the clone instead of overwriting it\r\n const cloned = cloneVNode(type, props, true /* mergeRef: true */);\r\n if (children) {\r\n normalizeChildren(cloned, children);\r\n }\r\n return cloned;\r\n }\r\n // class component normalization.\r\n if (isClassComponent(type)) {\r\n type = type.__vccOpts;\r\n }\r\n // class & style normalization.\r\n if (props) {\r\n // for reactive or proxy objects, we need to clone it to enable mutation.\r\n props = guardReactiveProps(props);\r\n let { class: klass, style } = props;\r\n if (klass && !isString(klass)) {\r\n props.class = normalizeClass(klass);\r\n }\r\n if (isObject(style)) {\r\n // reactive state objects need to be cloned since they are likely to be\r\n // mutated\r\n if (isProxy(style) && !isArray(style)) {\r\n style = extend({}, style);\r\n }\r\n props.style = normalizeStyle(style);\r\n }\r\n }\r\n // encode the vnode type information into a bitmap\r\n const shapeFlag = isString(type)\r\n ? 1 /* ELEMENT */\r\n : isSuspense(type)\r\n ? 128 /* SUSPENSE */\r\n : isTeleport(type)\r\n ? 64 /* TELEPORT */\r\n : isObject(type)\r\n ? 4 /* STATEFUL_COMPONENT */\r\n : isFunction(type)\r\n ? 2 /* FUNCTIONAL_COMPONENT */\r\n : 0;\r\n if ((process.env.NODE_ENV !== 'production') && shapeFlag & 4 /* STATEFUL_COMPONENT */ && isProxy(type)) {\r\n type = toRaw(type);\r\n warn(`Vue received a Component which was made a reactive object. This can ` +\r\n `lead to unnecessary performance overhead, and should be avoided by ` +\r\n `marking the component with \\`markRaw\\` or using \\`shallowRef\\` ` +\r\n `instead of \\`ref\\`.`, `\\nComponent that was made reactive: `, type);\r\n }\r\n return createBaseVNode(type, props, children, patchFlag, dynamicProps, shapeFlag, isBlockNode, true);\r\n}\r\nfunction guardReactiveProps(props) {\r\n if (!props)\r\n return null;\r\n return isProxy(props) || InternalObjectKey in props\r\n ? extend({}, props)\r\n : props;\r\n}\r\nfunction cloneVNode(vnode, extraProps, mergeRef = false) {\r\n // This is intentionally NOT using spread or extend to avoid the runtime\r\n // key enumeration cost.\r\n const { props, ref, patchFlag, children } = vnode;\r\n const mergedProps = extraProps ? mergeProps(props || {}, extraProps) : props;\r\n const cloned = {\r\n __v_isVNode: true,\r\n __v_skip: true,\r\n type: vnode.type,\r\n props: mergedProps,\r\n key: mergedProps && normalizeKey(mergedProps),\r\n ref: extraProps && extraProps.ref\r\n ? // #2078 in the case of <component :is=\"vnode\" ref=\"extra\"/>\r\n // if the vnode itself already has a ref, cloneVNode will need to merge\r\n // the refs so the single vnode can be set on multiple refs\r\n mergeRef && ref\r\n ? isArray(ref)\r\n ? ref.concat(normalizeRef(extraProps))\r\n : [ref, normalizeRef(extraProps)]\r\n : normalizeRef(extraProps)\r\n : ref,\r\n scopeId: vnode.scopeId,\r\n slotScopeIds: vnode.slotScopeIds,\r\n children: (process.env.NODE_ENV !== 'production') && patchFlag === -1 /* HOISTED */ && isArray(children)\r\n ? children.map(deepCloneVNode)\r\n : children,\r\n target: vnode.target,\r\n targetAnchor: vnode.targetAnchor,\r\n staticCount: vnode.staticCount,\r\n shapeFlag: vnode.shapeFlag,\r\n // if the vnode is cloned with extra props, we can no longer assume its\r\n // existing patch flag to be reliable and need to add the FULL_PROPS flag.\r\n // note: perserve flag for fragments since they use the flag for children\r\n // fast paths only.\r\n patchFlag: extraProps && vnode.type !== Fragment\r\n ? patchFlag === -1 // hoisted node\r\n ? 16 /* FULL_PROPS */\r\n : patchFlag | 16 /* FULL_PROPS */\r\n : patchFlag,\r\n dynamicProps: vnode.dynamicProps,\r\n dynamicChildren: vnode.dynamicChildren,\r\n appContext: vnode.appContext,\r\n dirs: vnode.dirs,\r\n transition: vnode.transition,\r\n // These should technically only be non-null on mounted VNodes. However,\r\n // they *should* be copied for kept-alive vnodes. So we just always copy\r\n // them since them being non-null during a mount doesn't affect the logic as\r\n // they will simply be overwritten.\r\n component: vnode.component,\r\n suspense: vnode.suspense,\r\n ssContent: vnode.ssContent && cloneVNode(vnode.ssContent),\r\n ssFallback: vnode.ssFallback && cloneVNode(vnode.ssFallback),\r\n el: vnode.el,\r\n anchor: vnode.anchor\r\n };\r\n return cloned;\r\n}\r\n/**\r\n * Dev only, for HMR of hoisted vnodes reused in v-for\r\n * https://github.com/vitejs/vite/issues/2022\r\n */\r\nfunction deepCloneVNode(vnode) {\r\n const cloned = cloneVNode(vnode);\r\n if (isArray(vnode.children)) {\r\n cloned.children = vnode.children.map(deepCloneVNode);\r\n }\r\n return cloned;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createTextVNode(text = ' ', flag = 0) {\r\n return createVNode(Text, null, text, flag);\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createStaticVNode(content, numberOfNodes) {\r\n // A static vnode can contain multiple stringified elements, and the number\r\n // of elements is necessary for hydration.\r\n const vnode = createVNode(Static, null, content);\r\n vnode.staticCount = numberOfNodes;\r\n return vnode;\r\n}\r\n/**\r\n * @private\r\n */\r\nfunction createCommentVNode(text = '', \r\n// when used as the v-else branch, the comment node must be created as a\r\n// block to ensure correct updates.\r\nasBlock = false) {\r\n return asBlock\r\n ? (openBlock(), createBlock(Comment, null, text))\r\n : createVNode(Comment, null, text);\r\n}\r\nfunction normalizeVNode(child) {\r\n if (child == null || typeof child === 'boolean') {\r\n // empty placeholder\r\n return createVNode(Comment);\r\n }\r\n else if (isArray(child)) {\r\n // fragment\r\n return createVNode(Fragment, null, \r\n // #3666, avoid reference pollution when reusing vnode\r\n child.slice());\r\n }\r\n else if (typeof child === 'object') {\r\n // already vnode, this should be the most common since compiled templates\r\n // always produce all-vnode children arrays\r\n return cloneIfMounted(child);\r\n }\r\n else {\r\n // strings and numbers\r\n return createVNode(Text, null, String(child));\r\n }\r\n}\r\n// optimized normalization for template-compiled render fns\r\nfunction cloneIfMounted(child) {\r\n return child.el === null || child.memo ? child : cloneVNode(child);\r\n}\r\nfunction normalizeChildren(vnode, children) {\r\n let type = 0;\r\n const { shapeFlag } = vnode;\r\n if (children == null) {\r\n children = null;\r\n }\r\n else if (isArray(children)) {\r\n type = 16 /* ARRAY_CHILDREN */;\r\n }\r\n else if (typeof children === 'object') {\r\n if (shapeFlag & (1 /* ELEMENT */ | 64 /* TELEPORT */)) {\r\n // Normalize slot to plain children for plain element and Teleport\r\n const slot = children.default;\r\n if (slot) {\r\n // _c marker is added by withCtx() indicating this is a compiled slot\r\n slot._c && (slot._d = false);\r\n normalizeChildren(vnode, slot());\r\n slot._c && (slot._d = true);\r\n }\r\n return;\r\n }\r\n else {\r\n type = 32 /* SLOTS_CHILDREN */;\r\n const slotFlag = children._;\r\n if (!slotFlag && !(InternalObjectKey in children)) {\r\n children._ctx = currentRenderingInstance;\r\n }\r\n else if (slotFlag === 3 /* FORWARDED */ && currentRenderingInstance) {\r\n // a child component receives forwarded slots from the parent.\r\n // its slot type is determined by its parent's slot type.\r\n if (currentRenderingInstance.slots._ === 1 /* STABLE */) {\r\n children._ = 1 /* STABLE */;\r\n }\r\n else {\r\n children._ = 2 /* DYNAMIC */;\r\n vnode.patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n }\r\n }\r\n }\r\n }\r\n else if (isFunction(children)) {\r\n children = { default: children, _ctx: currentRenderingInstance };\r\n type = 32 /* SLOTS_CHILDREN */;\r\n }\r\n else {\r\n children = String(children);\r\n // force teleport children to array so it can be moved around\r\n if (shapeFlag & 64 /* TELEPORT */) {\r\n type = 16 /* ARRAY_CHILDREN */;\r\n children = [createTextVNode(children)];\r\n }\r\n else {\r\n type = 8 /* TEXT_CHILDREN */;\r\n }\r\n }\r\n vnode.children = children;\r\n vnode.shapeFlag |= type;\r\n}\r\nfunction mergeProps(...args) {\r\n const ret = {};\r\n for (let i = 0; i < args.length; i++) {\r\n const toMerge = args[i];\r\n for (const key in toMerge) {\r\n if (key === 'class') {\r\n if (ret.class !== toMerge.class) {\r\n ret.class = normalizeClass([ret.class, toMerge.class]);\r\n }\r\n }\r\n else if (key === 'style') {\r\n ret.style = normalizeStyle([ret.style, toMerge.style]);\r\n }\r\n else if (isOn(key)) {\r\n const existing = ret[key];\r\n const incoming = toMerge[key];\r\n if (existing !== incoming &&\r\n !(isArray(existing) && existing.includes(incoming))) {\r\n ret[key] = existing\r\n ? [].concat(existing, incoming)\r\n : incoming;\r\n }\r\n }\r\n else if (key !== '') {\r\n ret[key] = toMerge[key];\r\n }\r\n }\r\n }\r\n return ret;\r\n}\n\n/**\r\n * Actual implementation\r\n */\r\nfunction renderList(source, renderItem, cache, index) {\r\n let ret;\r\n const cached = (cache && cache[index]);\r\n if (isArray(source) || isString(source)) {\r\n ret = new Array(source.length);\r\n for (let i = 0, l = source.length; i < l; i++) {\r\n ret[i] = renderItem(source[i], i, undefined, cached && cached[i]);\r\n }\r\n }\r\n else if (typeof source === 'number') {\r\n if ((process.env.NODE_ENV !== 'production') && !Number.isInteger(source)) {\r\n warn(`The v-for range expect an integer value but got ${source}.`);\r\n return [];\r\n }\r\n ret = new Array(source);\r\n for (let i = 0; i < source; i++) {\r\n ret[i] = renderItem(i + 1, i, undefined, cached && cached[i]);\r\n }\r\n }\r\n else if (isObject(source)) {\r\n if (source[Symbol.iterator]) {\r\n ret = Array.from(source, (item, i) => renderItem(item, i, undefined, cached && cached[i]));\r\n }\r\n else {\r\n const keys = Object.keys(source);\r\n ret = new Array(keys.length);\r\n for (let i = 0, l = keys.length; i < l; i++) {\r\n const key = keys[i];\r\n ret[i] = renderItem(source[key], key, i, cached && cached[i]);\r\n }\r\n }\r\n }\r\n else {\r\n ret = [];\r\n }\r\n if (cache) {\r\n cache[index] = ret;\r\n }\r\n return ret;\r\n}\n\n/**\r\n * Compiler runtime helper for creating dynamic slots object\r\n * @private\r\n */\r\nfunction createSlots(slots, dynamicSlots) {\r\n for (let i = 0; i < dynamicSlots.length; i++) {\r\n const slot = dynamicSlots[i];\r\n // array of dynamic slot generated by <template v-for=\"...\" #[...]>\r\n if (isArray(slot)) {\r\n for (let j = 0; j < slot.length; j++) {\r\n slots[slot[j].name] = slot[j].fn;\r\n }\r\n }\r\n else if (slot) {\r\n // conditional single slot generated by <template v-if=\"...\" #foo>\r\n slots[slot.name] = slot.fn;\r\n }\r\n }\r\n return slots;\r\n}\n\n/**\r\n * Compiler runtime helper for rendering `<slot/>`\r\n * @private\r\n */\r\nfunction renderSlot(slots, name, props = {}, \r\n// this is not a user-facing function, so the fallback is always generated by\r\n// the compiler and guaranteed to be a function returning an array\r\nfallback, noSlotted) {\r\n if (currentRenderingInstance.isCE) {\r\n return createVNode('slot', name === 'default' ? null : { name }, fallback && fallback());\r\n }\r\n let slot = slots[name];\r\n if ((process.env.NODE_ENV !== 'production') && slot && slot.length > 1) {\r\n warn(`SSR-optimized slot function detected in a non-SSR-optimized render ` +\r\n `function. You need to mark this component with $dynamic-slots in the ` +\r\n `parent template.`);\r\n slot = () => [];\r\n }\r\n // a compiled slot disables block tracking by default to avoid manual\r\n // invocation interfering with template-based block tracking, but in\r\n // `renderSlot` we can be sure that it's template-based so we can force\r\n // enable it.\r\n if (slot && slot._c) {\r\n slot._d = false;\r\n }\r\n openBlock();\r\n const validSlotContent = slot && ensureValidVNode(slot(props));\r\n const rendered = createBlock(Fragment, { key: props.key || `_${name}` }, validSlotContent || (fallback ? fallback() : []), validSlotContent && slots._ === 1 /* STABLE */\r\n ? 64 /* STABLE_FRAGMENT */\r\n : -2 /* BAIL */);\r\n if (!noSlotted && rendered.scopeId) {\r\n rendered.slotScopeIds = [rendered.scopeId + '-s'];\r\n }\r\n if (slot && slot._c) {\r\n slot._d = true;\r\n }\r\n return rendered;\r\n}\r\nfunction ensureValidVNode(vnodes) {\r\n return vnodes.some(child => {\r\n if (!isVNode(child))\r\n return true;\r\n if (child.type === Comment)\r\n return false;\r\n if (child.type === Fragment &&\r\n !ensureValidVNode(child.children))\r\n return false;\r\n return true;\r\n })\r\n ? vnodes\r\n : null;\r\n}\n\n/**\r\n * For prefixing keys in v-on=\"obj\" with \"on\"\r\n * @private\r\n */\r\nfunction toHandlers(obj) {\r\n const ret = {};\r\n if ((process.env.NODE_ENV !== 'production') && !isObject(obj)) {\r\n warn(`v-on with no argument expects an object value.`);\r\n return ret;\r\n }\r\n for (const key in obj) {\r\n ret[toHandlerKey(key)] = obj[key];\r\n }\r\n return ret;\r\n}\n\n/**\r\n * #2437 In Vue 3, functional components do not have a public instance proxy but\r\n * they exist in the internal parent chain. For code that relies on traversing\r\n * public $parent chains, skip functional ones and go to the parent instead.\r\n */\r\nconst getPublicInstance = (i) => {\r\n if (!i)\r\n return null;\r\n if (isStatefulComponent(i))\r\n return getExposeProxy(i) || i.proxy;\r\n return getPublicInstance(i.parent);\r\n};\r\nconst publicPropertiesMap = extend(Object.create(null), {\r\n $: i => i,\r\n $el: i => i.vnode.el,\r\n $data: i => i.data,\r\n $props: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.props) : i.props),\r\n $attrs: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.attrs) : i.attrs),\r\n $slots: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.slots) : i.slots),\r\n $refs: i => ((process.env.NODE_ENV !== 'production') ? shallowReadonly(i.refs) : i.refs),\r\n $parent: i => getPublicInstance(i.parent),\r\n $root: i => getPublicInstance(i.root),\r\n $emit: i => i.emit,\r\n $options: i => (__VUE_OPTIONS_API__ ? resolveMergedOptions(i) : i.type),\r\n $forceUpdate: i => () => queueJob(i.update),\r\n $nextTick: i => nextTick.bind(i.proxy),\r\n $watch: i => (__VUE_OPTIONS_API__ ? instanceWatch.bind(i) : NOOP)\r\n});\r\nconst PublicInstanceProxyHandlers = {\r\n get({ _: instance }, key) {\r\n const { ctx, setupState, data, props, accessCache, type, appContext } = instance;\r\n // for internal formatters to know that this is a Vue instance\r\n if ((process.env.NODE_ENV !== 'production') && key === '__isVue') {\r\n return true;\r\n }\r\n // prioritize <script setup> bindings during dev.\r\n // this allows even properties that start with _ or $ to be used - so that\r\n // it aligns with the production behavior where the render fn is inlined and\r\n // indeed has access to all declared variables.\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n setupState !== EMPTY_OBJ &&\r\n setupState.__isScriptSetup &&\r\n hasOwn(setupState, key)) {\r\n return setupState[key];\r\n }\r\n // data / props / ctx\r\n // This getter gets called for every property access on the render context\r\n // during render and is a major hotspot. The most expensive part of this\r\n // is the multiple hasOwn() calls. It's much faster to do a simple property\r\n // access on a plain object, so we use an accessCache object (with null\r\n // prototype) to memoize what access type a key corresponds to.\r\n let normalizedProps;\r\n if (key[0] !== '$') {\r\n const n = accessCache[key];\r\n if (n !== undefined) {\r\n switch (n) {\r\n case 1 /* SETUP */:\r\n return setupState[key];\r\n case 2 /* DATA */:\r\n return data[key];\r\n case 4 /* CONTEXT */:\r\n return ctx[key];\r\n case 3 /* PROPS */:\r\n return props[key];\r\n // default: just fallthrough\r\n }\r\n }\r\n else if (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) {\r\n accessCache[key] = 1 /* SETUP */;\r\n return setupState[key];\r\n }\r\n else if (data !== EMPTY_OBJ && hasOwn(data, key)) {\r\n accessCache[key] = 2 /* DATA */;\r\n return data[key];\r\n }\r\n else if (\r\n // only cache other properties when instance has declared (thus stable)\r\n // props\r\n (normalizedProps = instance.propsOptions[0]) &&\r\n hasOwn(normalizedProps, key)) {\r\n accessCache[key] = 3 /* PROPS */;\r\n return props[key];\r\n }\r\n else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {\r\n accessCache[key] = 4 /* CONTEXT */;\r\n return ctx[key];\r\n }\r\n else if (!__VUE_OPTIONS_API__ || shouldCacheAccess) {\r\n accessCache[key] = 0 /* OTHER */;\r\n }\r\n }\r\n const publicGetter = publicPropertiesMap[key];\r\n let cssModule, globalProperties;\r\n // public $xxx properties\r\n if (publicGetter) {\r\n if (key === '$attrs') {\r\n track(instance, \"get\" /* GET */, key);\r\n (process.env.NODE_ENV !== 'production') && markAttrsAccessed();\r\n }\r\n return publicGetter(instance);\r\n }\r\n else if (\r\n // css module (injected by vue-loader)\r\n (cssModule = type.__cssModules) &&\r\n (cssModule = cssModule[key])) {\r\n return cssModule;\r\n }\r\n else if (ctx !== EMPTY_OBJ && hasOwn(ctx, key)) {\r\n // user may set custom properties to `this` that start with `$`\r\n accessCache[key] = 4 /* CONTEXT */;\r\n return ctx[key];\r\n }\r\n else if (\r\n // global properties\r\n ((globalProperties = appContext.config.globalProperties),\r\n hasOwn(globalProperties, key))) {\r\n {\r\n return globalProperties[key];\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') &&\r\n currentRenderingInstance &&\r\n (!isString(key) ||\r\n // #1091 avoid internal isRef/isVNode checks on component instance leading\r\n // to infinite warning loop\r\n key.indexOf('__v') !== 0)) {\r\n if (data !== EMPTY_OBJ &&\r\n (key[0] === '$' || key[0] === '_') &&\r\n hasOwn(data, key)) {\r\n warn(`Property ${JSON.stringify(key)} must be accessed via $data because it starts with a reserved ` +\r\n `character (\"$\" or \"_\") and is not proxied on the render context.`);\r\n }\r\n else if (instance === currentRenderingInstance) {\r\n warn(`Property ${JSON.stringify(key)} was accessed during render ` +\r\n `but is not defined on instance.`);\r\n }\r\n }\r\n },\r\n set({ _: instance }, key, value) {\r\n const { data, setupState, ctx } = instance;\r\n if (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) {\r\n setupState[key] = value;\r\n }\r\n else if (data !== EMPTY_OBJ && hasOwn(data, key)) {\r\n data[key] = value;\r\n }\r\n else if (hasOwn(instance.props, key)) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Attempting to mutate prop \"${key}\". Props are readonly.`, instance);\r\n return false;\r\n }\r\n if (key[0] === '$' && key.slice(1) in instance) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Attempting to mutate public property \"${key}\". ` +\r\n `Properties starting with $ are reserved and readonly.`, instance);\r\n return false;\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production') && key in instance.appContext.config.globalProperties) {\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n value\r\n });\r\n }\r\n else {\r\n ctx[key] = value;\r\n }\r\n }\r\n return true;\r\n },\r\n has({ _: { data, setupState, accessCache, ctx, appContext, propsOptions } }, key) {\r\n let normalizedProps;\r\n return (!!accessCache[key] ||\r\n (data !== EMPTY_OBJ && hasOwn(data, key)) ||\r\n (setupState !== EMPTY_OBJ && hasOwn(setupState, key)) ||\r\n ((normalizedProps = propsOptions[0]) && hasOwn(normalizedProps, key)) ||\r\n hasOwn(ctx, key) ||\r\n hasOwn(publicPropertiesMap, key) ||\r\n hasOwn(appContext.config.globalProperties, key));\r\n }\r\n};\r\nif ((process.env.NODE_ENV !== 'production') && !false) {\r\n PublicInstanceProxyHandlers.ownKeys = (target) => {\r\n warn(`Avoid app logic that relies on enumerating keys on a component instance. ` +\r\n `The keys will be empty in production mode to avoid performance overhead.`);\r\n return Reflect.ownKeys(target);\r\n };\r\n}\r\nconst RuntimeCompiledPublicInstanceProxyHandlers = /*#__PURE__*/ extend({}, PublicInstanceProxyHandlers, {\r\n get(target, key) {\r\n // fast path for unscopables when using `with` block\r\n if (key === Symbol.unscopables) {\r\n return;\r\n }\r\n return PublicInstanceProxyHandlers.get(target, key, target);\r\n },\r\n has(_, key) {\r\n const has = key[0] !== '_' && !isGloballyWhitelisted(key);\r\n if ((process.env.NODE_ENV !== 'production') && !has && PublicInstanceProxyHandlers.has(_, key)) {\r\n warn(`Property ${JSON.stringify(key)} should not start with _ which is a reserved prefix for Vue internals.`);\r\n }\r\n return has;\r\n }\r\n});\r\n// dev only\r\n// In dev mode, the proxy target exposes the same properties as seen on `this`\r\n// for easier console inspection. In prod mode it will be an empty object so\r\n// these properties definitions can be skipped.\r\nfunction createDevRenderContext(instance) {\r\n const target = {};\r\n // expose internal instance for proxy handlers\r\n Object.defineProperty(target, `_`, {\r\n configurable: true,\r\n enumerable: false,\r\n get: () => instance\r\n });\r\n // expose public properties\r\n Object.keys(publicPropertiesMap).forEach(key => {\r\n Object.defineProperty(target, key, {\r\n configurable: true,\r\n enumerable: false,\r\n get: () => publicPropertiesMap[key](instance),\r\n // intercepted by the proxy so no need for implementation,\r\n // but needed to prevent set errors\r\n set: NOOP\r\n });\r\n });\r\n return target;\r\n}\r\n// dev only\r\nfunction exposePropsOnRenderContext(instance) {\r\n const { ctx, propsOptions: [propsOptions] } = instance;\r\n if (propsOptions) {\r\n Object.keys(propsOptions).forEach(key => {\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => instance.props[key],\r\n set: NOOP\r\n });\r\n });\r\n }\r\n}\r\n// dev only\r\nfunction exposeSetupStateOnRenderContext(instance) {\r\n const { ctx, setupState } = instance;\r\n Object.keys(toRaw(setupState)).forEach(key => {\r\n if (!setupState.__isScriptSetup) {\r\n if (key[0] === '$' || key[0] === '_') {\r\n warn(`setup() return property ${JSON.stringify(key)} should not start with \"$\" or \"_\" ` +\r\n `which are reserved prefixes for Vue internals.`);\r\n return;\r\n }\r\n Object.defineProperty(ctx, key, {\r\n enumerable: true,\r\n configurable: true,\r\n get: () => setupState[key],\r\n set: NOOP\r\n });\r\n }\r\n });\r\n}\n\nconst emptyAppContext = createAppContext();\r\nlet uid$1 = 0;\r\nfunction createComponentInstance(vnode, parent, suspense) {\r\n const type = vnode.type;\r\n // inherit parent app context - or - if root, adopt from root vnode\r\n const appContext = (parent ? parent.appContext : vnode.appContext) || emptyAppContext;\r\n const instance = {\r\n uid: uid$1++,\r\n vnode,\r\n type,\r\n parent,\r\n appContext,\r\n root: null,\r\n next: null,\r\n subTree: null,\r\n update: null,\r\n scope: new EffectScope(true /* detached */),\r\n render: null,\r\n proxy: null,\r\n exposed: null,\r\n exposeProxy: null,\r\n withProxy: null,\r\n provides: parent ? parent.provides : Object.create(appContext.provides),\r\n accessCache: null,\r\n renderCache: [],\r\n // local resovled assets\r\n components: null,\r\n directives: null,\r\n // resolved props and emits options\r\n propsOptions: normalizePropsOptions(type, appContext),\r\n emitsOptions: normalizeEmitsOptions(type, appContext),\r\n // emit\r\n emit: null,\r\n emitted: null,\r\n // props default value\r\n propsDefaults: EMPTY_OBJ,\r\n // inheritAttrs\r\n inheritAttrs: type.inheritAttrs,\r\n // state\r\n ctx: EMPTY_OBJ,\r\n data: EMPTY_OBJ,\r\n props: EMPTY_OBJ,\r\n attrs: EMPTY_OBJ,\r\n slots: EMPTY_OBJ,\r\n refs: EMPTY_OBJ,\r\n setupState: EMPTY_OBJ,\r\n setupContext: null,\r\n // suspense related\r\n suspense,\r\n suspenseId: suspense ? suspense.pendingId : 0,\r\n asyncDep: null,\r\n asyncResolved: false,\r\n // lifecycle hooks\r\n // not using enums here because it results in computed properties\r\n isMounted: false,\r\n isUnmounted: false,\r\n isDeactivated: false,\r\n bc: null,\r\n c: null,\r\n bm: null,\r\n m: null,\r\n bu: null,\r\n u: null,\r\n um: null,\r\n bum: null,\r\n da: null,\r\n a: null,\r\n rtg: null,\r\n rtc: null,\r\n ec: null,\r\n sp: null\r\n };\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n instance.ctx = createDevRenderContext(instance);\r\n }\r\n else {\r\n instance.ctx = { _: instance };\r\n }\r\n instance.root = parent ? parent.root : instance;\r\n instance.emit = emit$1.bind(null, instance);\r\n // apply custom element special handling\r\n if (vnode.ce) {\r\n vnode.ce(instance);\r\n }\r\n return instance;\r\n}\r\nlet currentInstance = null;\r\nconst getCurrentInstance = () => currentInstance || currentRenderingInstance;\r\nconst setCurrentInstance = (instance) => {\r\n currentInstance = instance;\r\n instance.scope.on();\r\n};\r\nconst unsetCurrentInstance = () => {\r\n currentInstance && currentInstance.scope.off();\r\n currentInstance = null;\r\n};\r\nconst isBuiltInTag = /*#__PURE__*/ makeMap('slot,component');\r\nfunction validateComponentName(name, config) {\r\n const appIsNativeTag = config.isNativeTag || NO;\r\n if (isBuiltInTag(name) || appIsNativeTag(name)) {\r\n warn('Do not use built-in or reserved HTML elements as component id: ' + name);\r\n }\r\n}\r\nfunction isStatefulComponent(instance) {\r\n return instance.vnode.shapeFlag & 4 /* STATEFUL_COMPONENT */;\r\n}\r\nlet isInSSRComponentSetup = false;\r\nfunction setupComponent(instance, isSSR = false) {\r\n isInSSRComponentSetup = isSSR;\r\n const { props, children } = instance.vnode;\r\n const isStateful = isStatefulComponent(instance);\r\n initProps(instance, props, isStateful, isSSR);\r\n initSlots(instance, children);\r\n const setupResult = isStateful\r\n ? setupStatefulComponent(instance, isSSR)\r\n : undefined;\r\n isInSSRComponentSetup = false;\r\n return setupResult;\r\n}\r\nfunction setupStatefulComponent(instance, isSSR) {\r\n const Component = instance.type;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (Component.name) {\r\n validateComponentName(Component.name, instance.appContext.config);\r\n }\r\n if (Component.components) {\r\n const names = Object.keys(Component.components);\r\n for (let i = 0; i < names.length; i++) {\r\n validateComponentName(names[i], instance.appContext.config);\r\n }\r\n }\r\n if (Component.directives) {\r\n const names = Object.keys(Component.directives);\r\n for (let i = 0; i < names.length; i++) {\r\n validateDirectiveName(names[i]);\r\n }\r\n }\r\n if (Component.compilerOptions && isRuntimeOnly()) {\r\n warn(`\"compilerOptions\" is only supported when using a build of Vue that ` +\r\n `includes the runtime compiler. Since you are using a runtime-only ` +\r\n `build, the options should be passed via your build tool config instead.`);\r\n }\r\n }\r\n // 0. create render proxy property access cache\r\n instance.accessCache = Object.create(null);\r\n // 1. create public instance / render proxy\r\n // also mark it raw so it's never observed\r\n instance.proxy = markRaw(new Proxy(instance.ctx, PublicInstanceProxyHandlers));\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n exposePropsOnRenderContext(instance);\r\n }\r\n // 2. call setup()\r\n const { setup } = Component;\r\n if (setup) {\r\n const setupContext = (instance.setupContext =\r\n setup.length > 1 ? createSetupContext(instance) : null);\r\n setCurrentInstance(instance);\r\n pauseTracking();\r\n const setupResult = callWithErrorHandling(setup, instance, 0 /* SETUP_FUNCTION */, [(process.env.NODE_ENV !== 'production') ? shallowReadonly(instance.props) : instance.props, setupContext]);\r\n resetTracking();\r\n unsetCurrentInstance();\r\n if (isPromise(setupResult)) {\r\n setupResult.then(unsetCurrentInstance, unsetCurrentInstance);\r\n if (isSSR) {\r\n // return the promise so server-renderer can wait on it\r\n return setupResult\r\n .then((resolvedResult) => {\r\n handleSetupResult(instance, resolvedResult, isSSR);\r\n })\r\n .catch(e => {\r\n handleError(e, instance, 0 /* SETUP_FUNCTION */);\r\n });\r\n }\r\n else {\r\n // async setup returned Promise.\r\n // bail here and wait for re-entry.\r\n instance.asyncDep = setupResult;\r\n }\r\n }\r\n else {\r\n handleSetupResult(instance, setupResult, isSSR);\r\n }\r\n }\r\n else {\r\n finishComponentSetup(instance, isSSR);\r\n }\r\n}\r\nfunction handleSetupResult(instance, setupResult, isSSR) {\r\n if (isFunction(setupResult)) {\r\n // setup returned an inline render function\r\n if (instance.type.__ssrInlineRender) {\r\n // when the function's name is `ssrRender` (compiled by SFC inline mode),\r\n // set it as ssrRender instead.\r\n instance.ssrRender = setupResult;\r\n }\r\n else {\r\n instance.render = setupResult;\r\n }\r\n }\r\n else if (isObject(setupResult)) {\r\n if ((process.env.NODE_ENV !== 'production') && isVNode(setupResult)) {\r\n warn(`setup() should not return VNodes directly - ` +\r\n `return a render function instead.`);\r\n }\r\n // setup returned bindings.\r\n // assuming a render function compiled from template is present.\r\n if ((process.env.NODE_ENV !== 'production') || __VUE_PROD_DEVTOOLS__) {\r\n instance.devtoolsRawSetupState = setupResult;\r\n }\r\n instance.setupState = proxyRefs(setupResult);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n exposeSetupStateOnRenderContext(instance);\r\n }\r\n }\r\n else if ((process.env.NODE_ENV !== 'production') && setupResult !== undefined) {\r\n warn(`setup() should return an object. Received: ${setupResult === null ? 'null' : typeof setupResult}`);\r\n }\r\n finishComponentSetup(instance, isSSR);\r\n}\r\nlet compile;\r\nlet installWithProxy;\r\n/**\r\n * For runtime-dom to register the compiler.\r\n * Note the exported method uses any to avoid d.ts relying on the compiler types.\r\n */\r\nfunction registerRuntimeCompiler(_compile) {\r\n compile = _compile;\r\n installWithProxy = i => {\r\n if (i.render._rc) {\r\n i.withProxy = new Proxy(i.ctx, RuntimeCompiledPublicInstanceProxyHandlers);\r\n }\r\n };\r\n}\r\n// dev only\r\nconst isRuntimeOnly = () => !compile;\r\nfunction finishComponentSetup(instance, isSSR, skipOptions) {\r\n const Component = instance.type;\r\n // template / render function normalization\r\n // could be already set when returned from setup()\r\n if (!instance.render) {\r\n // only do on-the-fly compile if not in SSR - SSR on-the-fly compliation\r\n // is done by server-renderer\r\n if (!isSSR && compile && !Component.render) {\r\n const template = Component.template;\r\n if (template) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n startMeasure(instance, `compile`);\r\n }\r\n const { isCustomElement, compilerOptions } = instance.appContext.config;\r\n const { delimiters, compilerOptions: componentCompilerOptions } = Component;\r\n const finalCompilerOptions = extend(extend({\r\n isCustomElement,\r\n delimiters\r\n }, compilerOptions), componentCompilerOptions);\r\n Component.render = compile(template, finalCompilerOptions);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n endMeasure(instance, `compile`);\r\n }\r\n }\r\n }\r\n instance.render = (Component.render || NOOP);\r\n // for runtime-compiled render functions using `with` blocks, the render\r\n // proxy used needs a different `has` handler which is more performant and\r\n // also only allows a whitelist of globals to fallthrough.\r\n if (installWithProxy) {\r\n installWithProxy(instance);\r\n }\r\n }\r\n // support for 2.x options\r\n if (__VUE_OPTIONS_API__ && !(false )) {\r\n setCurrentInstance(instance);\r\n pauseTracking();\r\n applyOptions(instance);\r\n resetTracking();\r\n unsetCurrentInstance();\r\n }\r\n // warn missing template/render\r\n // the runtime compilation of template in SSR is done by server-render\r\n if ((process.env.NODE_ENV !== 'production') && !Component.render && instance.render === NOOP && !isSSR) {\r\n /* istanbul ignore if */\r\n if (!compile && Component.template) {\r\n warn(`Component provided template option but ` +\r\n `runtime compilation is not supported in this build of Vue.` +\r\n (` Configure your bundler to alias \"vue\" to \"vue/dist/vue.esm-bundler.js\".`\r\n ) /* should not happen */);\r\n }\r\n else {\r\n warn(`Component is missing template or render function.`);\r\n }\r\n }\r\n}\r\nfunction createAttrsProxy(instance) {\r\n return new Proxy(instance.attrs, (process.env.NODE_ENV !== 'production')\r\n ? {\r\n get(target, key) {\r\n markAttrsAccessed();\r\n track(instance, \"get\" /* GET */, '$attrs');\r\n return target[key];\r\n },\r\n set() {\r\n warn(`setupContext.attrs is readonly.`);\r\n return false;\r\n },\r\n deleteProperty() {\r\n warn(`setupContext.attrs is readonly.`);\r\n return false;\r\n }\r\n }\r\n : {\r\n get(target, key) {\r\n track(instance, \"get\" /* GET */, '$attrs');\r\n return target[key];\r\n }\r\n });\r\n}\r\nfunction createSetupContext(instance) {\r\n const expose = exposed => {\r\n if ((process.env.NODE_ENV !== 'production') && instance.exposed) {\r\n warn(`expose() should be called only once per setup().`);\r\n }\r\n instance.exposed = exposed || {};\r\n };\r\n let attrs;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n // We use getters in dev in case libs like test-utils overwrite instance\r\n // properties (overwrites should not be done in prod)\r\n return Object.freeze({\r\n get attrs() {\r\n return attrs || (attrs = createAttrsProxy(instance));\r\n },\r\n get slots() {\r\n return shallowReadonly(instance.slots);\r\n },\r\n get emit() {\r\n return (event, ...args) => instance.emit(event, ...args);\r\n },\r\n expose\r\n });\r\n }\r\n else {\r\n return {\r\n get attrs() {\r\n return attrs || (attrs = createAttrsProxy(instance));\r\n },\r\n slots: instance.slots,\r\n emit: instance.emit,\r\n expose\r\n };\r\n }\r\n}\r\nfunction getExposeProxy(instance) {\r\n if (instance.exposed) {\r\n return (instance.exposeProxy ||\r\n (instance.exposeProxy = new Proxy(proxyRefs(markRaw(instance.exposed)), {\r\n get(target, key) {\r\n if (key in target) {\r\n return target[key];\r\n }\r\n else if (key in publicPropertiesMap) {\r\n return publicPropertiesMap[key](instance);\r\n }\r\n }\r\n })));\r\n }\r\n}\r\nconst classifyRE = /(?:^|[-_])(\\w)/g;\r\nconst classify = (str) => str.replace(classifyRE, c => c.toUpperCase()).replace(/[-_]/g, '');\r\nfunction getComponentName(Component) {\r\n return isFunction(Component)\r\n ? Component.displayName || Component.name\r\n : Component.name;\r\n}\r\n/* istanbul ignore next */\r\nfunction formatComponentName(instance, Component, isRoot = false) {\r\n let name = getComponentName(Component);\r\n if (!name && Component.__file) {\r\n const match = Component.__file.match(/([^/\\\\]+)\\.\\w+$/);\r\n if (match) {\r\n name = match[1];\r\n }\r\n }\r\n if (!name && instance && instance.parent) {\r\n // try to infer the name based on reverse resolution\r\n const inferFromRegistry = (registry) => {\r\n for (const key in registry) {\r\n if (registry[key] === Component) {\r\n return key;\r\n }\r\n }\r\n };\r\n name =\r\n inferFromRegistry(instance.components ||\r\n instance.parent.type.components) || inferFromRegistry(instance.appContext.components);\r\n }\r\n return name ? classify(name) : isRoot ? `App` : `Anonymous`;\r\n}\r\nfunction isClassComponent(value) {\r\n return isFunction(value) && '__vccOpts' in value;\r\n}\n\nconst stack = [];\r\nfunction pushWarningContext(vnode) {\r\n stack.push(vnode);\r\n}\r\nfunction popWarningContext() {\r\n stack.pop();\r\n}\r\nfunction warn(msg, ...args) {\r\n // avoid props formatting or warn handler tracking deps that might be mutated\r\n // during patch, leading to infinite recursion.\r\n pauseTracking();\r\n const instance = stack.length ? stack[stack.length - 1].component : null;\r\n const appWarnHandler = instance && instance.appContext.config.warnHandler;\r\n const trace = getComponentTrace();\r\n if (appWarnHandler) {\r\n callWithErrorHandling(appWarnHandler, instance, 11 /* APP_WARN_HANDLER */, [\r\n msg + args.join(''),\r\n instance && instance.proxy,\r\n trace\r\n .map(({ vnode }) => `at <${formatComponentName(instance, vnode.type)}>`)\r\n .join('\\n'),\r\n trace\r\n ]);\r\n }\r\n else {\r\n const warnArgs = [`[Vue warn]: ${msg}`, ...args];\r\n /* istanbul ignore if */\r\n if (trace.length &&\r\n // avoid spamming console during tests\r\n !false) {\r\n warnArgs.push(`\\n`, ...formatTrace(trace));\r\n }\r\n console.warn(...warnArgs);\r\n }\r\n resetTracking();\r\n}\r\nfunction getComponentTrace() {\r\n let currentVNode = stack[stack.length - 1];\r\n if (!currentVNode) {\r\n return [];\r\n }\r\n // we can't just use the stack because it will be incomplete during updates\r\n // that did not start from the root. Re-construct the parent chain using\r\n // instance parent pointers.\r\n const normalizedStack = [];\r\n while (currentVNode) {\r\n const last = normalizedStack[0];\r\n if (last && last.vnode === currentVNode) {\r\n last.recurseCount++;\r\n }\r\n else {\r\n normalizedStack.push({\r\n vnode: currentVNode,\r\n recurseCount: 0\r\n });\r\n }\r\n const parentInstance = currentVNode.component && currentVNode.component.parent;\r\n currentVNode = parentInstance && parentInstance.vnode;\r\n }\r\n return normalizedStack;\r\n}\r\n/* istanbul ignore next */\r\nfunction formatTrace(trace) {\r\n const logs = [];\r\n trace.forEach((entry, i) => {\r\n logs.push(...(i === 0 ? [] : [`\\n`]), ...formatTraceEntry(entry));\r\n });\r\n return logs;\r\n}\r\nfunction formatTraceEntry({ vnode, recurseCount }) {\r\n const postfix = recurseCount > 0 ? `... (${recurseCount} recursive calls)` : ``;\r\n const isRoot = vnode.component ? vnode.component.parent == null : false;\r\n const open = ` at <${formatComponentName(vnode.component, vnode.type, isRoot)}`;\r\n const close = `>` + postfix;\r\n return vnode.props\r\n ? [open, ...formatProps(vnode.props), close]\r\n : [open + close];\r\n}\r\n/* istanbul ignore next */\r\nfunction formatProps(props) {\r\n const res = [];\r\n const keys = Object.keys(props);\r\n keys.slice(0, 3).forEach(key => {\r\n res.push(...formatProp(key, props[key]));\r\n });\r\n if (keys.length > 3) {\r\n res.push(` ...`);\r\n }\r\n return res;\r\n}\r\n/* istanbul ignore next */\r\nfunction formatProp(key, value, raw) {\r\n if (isString(value)) {\r\n value = JSON.stringify(value);\r\n return raw ? value : [`${key}=${value}`];\r\n }\r\n else if (typeof value === 'number' ||\r\n typeof value === 'boolean' ||\r\n value == null) {\r\n return raw ? value : [`${key}=${value}`];\r\n }\r\n else if (isRef(value)) {\r\n value = formatProp(key, toRaw(value.value), true);\r\n return raw ? value : [`${key}=Ref<`, value, `>`];\r\n }\r\n else if (isFunction(value)) {\r\n return [`${key}=fn${value.name ? `<${value.name}>` : ``}`];\r\n }\r\n else {\r\n value = toRaw(value);\r\n return raw ? value : [`${key}=`, value];\r\n }\r\n}\n\nconst ErrorTypeStrings = {\r\n [\"sp\" /* SERVER_PREFETCH */]: 'serverPrefetch hook',\r\n [\"bc\" /* BEFORE_CREATE */]: 'beforeCreate hook',\r\n [\"c\" /* CREATED */]: 'created hook',\r\n [\"bm\" /* BEFORE_MOUNT */]: 'beforeMount hook',\r\n [\"m\" /* MOUNTED */]: 'mounted hook',\r\n [\"bu\" /* BEFORE_UPDATE */]: 'beforeUpdate hook',\r\n [\"u\" /* UPDATED */]: 'updated',\r\n [\"bum\" /* BEFORE_UNMOUNT */]: 'beforeUnmount hook',\r\n [\"um\" /* UNMOUNTED */]: 'unmounted hook',\r\n [\"a\" /* ACTIVATED */]: 'activated hook',\r\n [\"da\" /* DEACTIVATED */]: 'deactivated hook',\r\n [\"ec\" /* ERROR_CAPTURED */]: 'errorCaptured hook',\r\n [\"rtc\" /* RENDER_TRACKED */]: 'renderTracked hook',\r\n [\"rtg\" /* RENDER_TRIGGERED */]: 'renderTriggered hook',\r\n [0 /* SETUP_FUNCTION */]: 'setup function',\r\n [1 /* RENDER_FUNCTION */]: 'render function',\r\n [2 /* WATCH_GETTER */]: 'watcher getter',\r\n [3 /* WATCH_CALLBACK */]: 'watcher callback',\r\n [4 /* WATCH_CLEANUP */]: 'watcher cleanup function',\r\n [5 /* NATIVE_EVENT_HANDLER */]: 'native event handler',\r\n [6 /* COMPONENT_EVENT_HANDLER */]: 'component event handler',\r\n [7 /* VNODE_HOOK */]: 'vnode hook',\r\n [8 /* DIRECTIVE_HOOK */]: 'directive hook',\r\n [9 /* TRANSITION_HOOK */]: 'transition hook',\r\n [10 /* APP_ERROR_HANDLER */]: 'app errorHandler',\r\n [11 /* APP_WARN_HANDLER */]: 'app warnHandler',\r\n [12 /* FUNCTION_REF */]: 'ref function',\r\n [13 /* ASYNC_COMPONENT_LOADER */]: 'async component loader',\r\n [14 /* SCHEDULER */]: 'scheduler flush. This is likely a Vue internals bug. ' +\r\n 'Please open an issue at https://new-issue.vuejs.org/?repo=vuejs/vue-next'\r\n};\r\nfunction callWithErrorHandling(fn, instance, type, args) {\r\n let res;\r\n try {\r\n res = args ? fn(...args) : fn();\r\n }\r\n catch (err) {\r\n handleError(err, instance, type);\r\n }\r\n return res;\r\n}\r\nfunction callWithAsyncErrorHandling(fn, instance, type, args) {\r\n if (isFunction(fn)) {\r\n const res = callWithErrorHandling(fn, instance, type, args);\r\n if (res && isPromise(res)) {\r\n res.catch(err => {\r\n handleError(err, instance, type);\r\n });\r\n }\r\n return res;\r\n }\r\n const values = [];\r\n for (let i = 0; i < fn.length; i++) {\r\n values.push(callWithAsyncErrorHandling(fn[i], instance, type, args));\r\n }\r\n return values;\r\n}\r\nfunction handleError(err, instance, type, throwInDev = true) {\r\n const contextVNode = instance ? instance.vnode : null;\r\n if (instance) {\r\n let cur = instance.parent;\r\n // the exposed instance is the render proxy to keep it consistent with 2.x\r\n const exposedInstance = instance.proxy;\r\n // in production the hook receives only the error code\r\n const errorInfo = (process.env.NODE_ENV !== 'production') ? ErrorTypeStrings[type] : type;\r\n while (cur) {\r\n const errorCapturedHooks = cur.ec;\r\n if (errorCapturedHooks) {\r\n for (let i = 0; i < errorCapturedHooks.length; i++) {\r\n if (errorCapturedHooks[i](err, exposedInstance, errorInfo) === false) {\r\n return;\r\n }\r\n }\r\n }\r\n cur = cur.parent;\r\n }\r\n // app-level handling\r\n const appErrorHandler = instance.appContext.config.errorHandler;\r\n if (appErrorHandler) {\r\n callWithErrorHandling(appErrorHandler, null, 10 /* APP_ERROR_HANDLER */, [err, exposedInstance, errorInfo]);\r\n return;\r\n }\r\n }\r\n logError(err, type, contextVNode, throwInDev);\r\n}\r\nfunction logError(err, type, contextVNode, throwInDev = true) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const info = ErrorTypeStrings[type];\r\n if (contextVNode) {\r\n pushWarningContext(contextVNode);\r\n }\r\n warn(`Unhandled error${info ? ` during execution of ${info}` : ``}`);\r\n if (contextVNode) {\r\n popWarningContext();\r\n }\r\n // crash in dev by default so it's more noticeable\r\n if (throwInDev) {\r\n throw err;\r\n }\r\n else {\r\n console.error(err);\r\n }\r\n }\r\n else {\r\n // recover in prod to reduce the impact on end-user\r\n console.error(err);\r\n }\r\n}\n\nlet isFlushing = false;\r\nlet isFlushPending = false;\r\nconst queue = [];\r\nlet flushIndex = 0;\r\nconst pendingPreFlushCbs = [];\r\nlet activePreFlushCbs = null;\r\nlet preFlushIndex = 0;\r\nconst pendingPostFlushCbs = [];\r\nlet activePostFlushCbs = null;\r\nlet postFlushIndex = 0;\r\nconst resolvedPromise = Promise.resolve();\r\nlet currentFlushPromise = null;\r\nlet currentPreFlushParentJob = null;\r\nconst RECURSION_LIMIT = 100;\r\nfunction nextTick(fn) {\r\n const p = currentFlushPromise || resolvedPromise;\r\n return fn ? p.then(this ? fn.bind(this) : fn) : p;\r\n}\r\n// #2768\r\n// Use binary-search to find a suitable position in the queue,\r\n// so that the queue maintains the increasing order of job's id,\r\n// which can prevent the job from being skipped and also can avoid repeated patching.\r\nfunction findInsertionIndex(id) {\r\n // the start index should be `flushIndex + 1`\r\n let start = flushIndex + 1;\r\n let end = queue.length;\r\n while (start < end) {\r\n const middle = (start + end) >>> 1;\r\n const middleJobId = getId(queue[middle]);\r\n middleJobId < id ? (start = middle + 1) : (end = middle);\r\n }\r\n return start;\r\n}\r\nfunction queueJob(job) {\r\n // the dedupe search uses the startIndex argument of Array.includes()\r\n // by default the search index includes the current job that is being run\r\n // so it cannot recursively trigger itself again.\r\n // if the job is a watch() callback, the search will start with a +1 index to\r\n // allow it recursively trigger itself - it is the user's responsibility to\r\n // ensure it doesn't end up in an infinite loop.\r\n if ((!queue.length ||\r\n !queue.includes(job, isFlushing && job.allowRecurse ? flushIndex + 1 : flushIndex)) &&\r\n job !== currentPreFlushParentJob) {\r\n if (job.id == null) {\r\n queue.push(job);\r\n }\r\n else {\r\n queue.splice(findInsertionIndex(job.id), 0, job);\r\n }\r\n queueFlush();\r\n }\r\n}\r\nfunction queueFlush() {\r\n if (!isFlushing && !isFlushPending) {\r\n isFlushPending = true;\r\n currentFlushPromise = resolvedPromise.then(flushJobs);\r\n }\r\n}\r\nfunction invalidateJob(job) {\r\n const i = queue.indexOf(job);\r\n if (i > flushIndex) {\r\n queue.splice(i, 1);\r\n }\r\n}\r\nfunction queueCb(cb, activeQueue, pendingQueue, index) {\r\n if (!isArray(cb)) {\r\n if (!activeQueue ||\r\n !activeQueue.includes(cb, cb.allowRecurse ? index + 1 : index)) {\r\n pendingQueue.push(cb);\r\n }\r\n }\r\n else {\r\n // if cb is an array, it is a component lifecycle hook which can only be\r\n // triggered by a job, which is already deduped in the main queue, so\r\n // we can skip duplicate check here to improve perf\r\n pendingQueue.push(...cb);\r\n }\r\n queueFlush();\r\n}\r\nfunction queuePreFlushCb(cb) {\r\n queueCb(cb, activePreFlushCbs, pendingPreFlushCbs, preFlushIndex);\r\n}\r\nfunction queuePostFlushCb(cb) {\r\n queueCb(cb, activePostFlushCbs, pendingPostFlushCbs, postFlushIndex);\r\n}\r\nfunction flushPreFlushCbs(seen, parentJob = null) {\r\n if (pendingPreFlushCbs.length) {\r\n currentPreFlushParentJob = parentJob;\r\n activePreFlushCbs = [...new Set(pendingPreFlushCbs)];\r\n pendingPreFlushCbs.length = 0;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n seen = seen || new Map();\r\n }\r\n for (preFlushIndex = 0; preFlushIndex < activePreFlushCbs.length; preFlushIndex++) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n checkRecursiveUpdates(seen, activePreFlushCbs[preFlushIndex])) {\r\n continue;\r\n }\r\n activePreFlushCbs[preFlushIndex]();\r\n }\r\n activePreFlushCbs = null;\r\n preFlushIndex = 0;\r\n currentPreFlushParentJob = null;\r\n // recursively flush until it drains\r\n flushPreFlushCbs(seen, parentJob);\r\n }\r\n}\r\nfunction flushPostFlushCbs(seen) {\r\n if (pendingPostFlushCbs.length) {\r\n const deduped = [...new Set(pendingPostFlushCbs)];\r\n pendingPostFlushCbs.length = 0;\r\n // #1947 already has active queue, nested flushPostFlushCbs call\r\n if (activePostFlushCbs) {\r\n activePostFlushCbs.push(...deduped);\r\n return;\r\n }\r\n activePostFlushCbs = deduped;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n seen = seen || new Map();\r\n }\r\n activePostFlushCbs.sort((a, b) => getId(a) - getId(b));\r\n for (postFlushIndex = 0; postFlushIndex < activePostFlushCbs.length; postFlushIndex++) {\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n checkRecursiveUpdates(seen, activePostFlushCbs[postFlushIndex])) {\r\n continue;\r\n }\r\n activePostFlushCbs[postFlushIndex]();\r\n }\r\n activePostFlushCbs = null;\r\n postFlushIndex = 0;\r\n }\r\n}\r\nconst getId = (job) => job.id == null ? Infinity : job.id;\r\nfunction flushJobs(seen) {\r\n isFlushPending = false;\r\n isFlushing = true;\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n seen = seen || new Map();\r\n }\r\n flushPreFlushCbs(seen);\r\n // Sort queue before flush.\r\n // This ensures that:\r\n // 1. Components are updated from parent to child. (because parent is always\r\n // created before the child so its render effect will have smaller\r\n // priority number)\r\n // 2. If a component is unmounted during a parent component's update,\r\n // its update can be skipped.\r\n queue.sort((a, b) => getId(a) - getId(b));\r\n // conditional usage of checkRecursiveUpdate must be determined out of\r\n // try ... catch block since Rollup by default de-optimizes treeshaking\r\n // inside try-catch. This can leave all warning code unshaked. Although\r\n // they would get eventually shaken by a minifier like terser, some minifiers\r\n // would fail to do that (e.g. https://github.com/evanw/esbuild/issues/1610)\r\n const check = (process.env.NODE_ENV !== 'production')\r\n ? (job) => checkRecursiveUpdates(seen, job)\r\n : NOOP;\r\n try {\r\n for (flushIndex = 0; flushIndex < queue.length; flushIndex++) {\r\n const job = queue[flushIndex];\r\n if (job && job.active !== false) {\r\n if ((process.env.NODE_ENV !== 'production') && check(job)) {\r\n continue;\r\n }\r\n // console.log(`running:`, job.id)\r\n callWithErrorHandling(job, null, 14 /* SCHEDULER */);\r\n }\r\n }\r\n }\r\n finally {\r\n flushIndex = 0;\r\n queue.length = 0;\r\n flushPostFlushCbs(seen);\r\n isFlushing = false;\r\n currentFlushPromise = null;\r\n // some postFlushCb queued jobs!\r\n // keep flushing until it drains.\r\n if (queue.length ||\r\n pendingPreFlushCbs.length ||\r\n pendingPostFlushCbs.length) {\r\n flushJobs(seen);\r\n }\r\n }\r\n}\r\nfunction checkRecursiveUpdates(seen, fn) {\r\n if (!seen.has(fn)) {\r\n seen.set(fn, 1);\r\n }\r\n else {\r\n const count = seen.get(fn);\r\n if (count > RECURSION_LIMIT) {\r\n const instance = fn.ownerInstance;\r\n const componentName = instance && getComponentName(instance.type);\r\n warn(`Maximum recursive updates exceeded${componentName ? ` in component <${componentName}>` : ``}. ` +\r\n `This means you have a reactive effect that is mutating its own ` +\r\n `dependencies and thus recursively triggering itself. Possible sources ` +\r\n `include component template, render function, updated hook or ` +\r\n `watcher source function.`);\r\n return true;\r\n }\r\n else {\r\n seen.set(fn, count + 1);\r\n }\r\n }\r\n}\n\n// Simple effect.\r\nfunction watchEffect(effect, options) {\r\n return doWatch(effect, null, options);\r\n}\r\nfunction watchPostEffect(effect, options) {\r\n return doWatch(effect, null, ((process.env.NODE_ENV !== 'production')\r\n ? Object.assign(options || {}, { flush: 'post' })\r\n : { flush: 'post' }));\r\n}\r\nfunction watchSyncEffect(effect, options) {\r\n return doWatch(effect, null, ((process.env.NODE_ENV !== 'production')\r\n ? Object.assign(options || {}, { flush: 'sync' })\r\n : { flush: 'sync' }));\r\n}\r\n// initial value for watchers to trigger on undefined initial values\r\nconst INITIAL_WATCHER_VALUE = {};\r\n// implementation\r\nfunction watch(source, cb, options) {\r\n if ((process.env.NODE_ENV !== 'production') && !isFunction(cb)) {\r\n warn(`\\`watch(fn, options?)\\` signature has been moved to a separate API. ` +\r\n `Use \\`watchEffect(fn, options?)\\` instead. \\`watch\\` now only ` +\r\n `supports \\`watch(source, cb, options?) signature.`);\r\n }\r\n return doWatch(source, cb, options);\r\n}\r\nfunction doWatch(source, cb, { immediate, deep, flush, onTrack, onTrigger } = EMPTY_OBJ) {\r\n if ((process.env.NODE_ENV !== 'production') && !cb) {\r\n if (immediate !== undefined) {\r\n warn(`watch() \"immediate\" option is only respected when using the ` +\r\n `watch(source, callback, options?) signature.`);\r\n }\r\n if (deep !== undefined) {\r\n warn(`watch() \"deep\" option is only respected when using the ` +\r\n `watch(source, callback, options?) signature.`);\r\n }\r\n }\r\n const warnInvalidSource = (s) => {\r\n warn(`Invalid watch source: `, s, `A watch source can only be a getter/effect function, a ref, ` +\r\n `a reactive object, or an array of these types.`);\r\n };\r\n const instance = currentInstance;\r\n let getter;\r\n let forceTrigger = false;\r\n let isMultiSource = false;\r\n if (isRef(source)) {\r\n getter = () => source.value;\r\n forceTrigger = !!source._shallow;\r\n }\r\n else if (isReactive(source)) {\r\n getter = () => source;\r\n deep = true;\r\n }\r\n else if (isArray(source)) {\r\n isMultiSource = true;\r\n forceTrigger = source.some(isReactive);\r\n getter = () => source.map(s => {\r\n if (isRef(s)) {\r\n return s.value;\r\n }\r\n else if (isReactive(s)) {\r\n return traverse(s);\r\n }\r\n else if (isFunction(s)) {\r\n return callWithErrorHandling(s, instance, 2 /* WATCH_GETTER */);\r\n }\r\n else {\r\n (process.env.NODE_ENV !== 'production') && warnInvalidSource(s);\r\n }\r\n });\r\n }\r\n else if (isFunction(source)) {\r\n if (cb) {\r\n // getter with cb\r\n getter = () => callWithErrorHandling(source, instance, 2 /* WATCH_GETTER */);\r\n }\r\n else {\r\n // no cb -> simple effect\r\n getter = () => {\r\n if (instance && instance.isUnmounted) {\r\n return;\r\n }\r\n if (cleanup) {\r\n cleanup();\r\n }\r\n return callWithAsyncErrorHandling(source, instance, 3 /* WATCH_CALLBACK */, [onInvalidate]);\r\n };\r\n }\r\n }\r\n else {\r\n getter = NOOP;\r\n (process.env.NODE_ENV !== 'production') && warnInvalidSource(source);\r\n }\r\n if (cb && deep) {\r\n const baseGetter = getter;\r\n getter = () => traverse(baseGetter());\r\n }\r\n let cleanup;\r\n let onInvalidate = (fn) => {\r\n cleanup = effect.onStop = () => {\r\n callWithErrorHandling(fn, instance, 4 /* WATCH_CLEANUP */);\r\n };\r\n };\r\n // in SSR there is no need to setup an actual effect, and it should be noop\r\n // unless it's eager\r\n if (isInSSRComponentSetup) {\r\n // we will also not call the invalidate callback (+ runner is not set up)\r\n onInvalidate = NOOP;\r\n if (!cb) {\r\n getter();\r\n }\r\n else if (immediate) {\r\n callWithAsyncErrorHandling(cb, instance, 3 /* WATCH_CALLBACK */, [\r\n getter(),\r\n isMultiSource ? [] : undefined,\r\n onInvalidate\r\n ]);\r\n }\r\n return NOOP;\r\n }\r\n let oldValue = isMultiSource ? [] : INITIAL_WATCHER_VALUE;\r\n const job = () => {\r\n if (!effect.active) {\r\n return;\r\n }\r\n if (cb) {\r\n // watch(source, cb)\r\n const newValue = effect.run();\r\n if (deep ||\r\n forceTrigger ||\r\n (isMultiSource\r\n ? newValue.some((v, i) => hasChanged(v, oldValue[i]))\r\n : hasChanged(newValue, oldValue)) ||\r\n (false )) {\r\n // cleanup before running cb again\r\n if (cleanup) {\r\n cleanup();\r\n }\r\n callWithAsyncErrorHandling(cb, instance, 3 /* WATCH_CALLBACK */, [\r\n newValue,\r\n // pass undefined as the old value when it's changed for the first time\r\n oldValue === INITIAL_WATCHER_VALUE ? undefined : oldValue,\r\n onInvalidate\r\n ]);\r\n oldValue = newValue;\r\n }\r\n }\r\n else {\r\n // watchEffect\r\n effect.run();\r\n }\r\n };\r\n // important: mark the job as a watcher callback so that scheduler knows\r\n // it is allowed to self-trigger (#1727)\r\n job.allowRecurse = !!cb;\r\n let scheduler;\r\n if (flush === 'sync') {\r\n scheduler = job; // the scheduler function gets called directly\r\n }\r\n else if (flush === 'post') {\r\n scheduler = () => queuePostRenderEffect(job, instance && instance.suspense);\r\n }\r\n else {\r\n // default: 'pre'\r\n scheduler = () => {\r\n if (!instance || instance.isMounted) {\r\n queuePreFlushCb(job);\r\n }\r\n else {\r\n // with 'pre' option, the first call must happen before\r\n // the component is mounted so it is called synchronously.\r\n job();\r\n }\r\n };\r\n }\r\n const effect = new ReactiveEffect(getter, scheduler);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n effect.onTrack = onTrack;\r\n effect.onTrigger = onTrigger;\r\n }\r\n // initial run\r\n if (cb) {\r\n if (immediate) {\r\n job();\r\n }\r\n else {\r\n oldValue = effect.run();\r\n }\r\n }\r\n else if (flush === 'post') {\r\n queuePostRenderEffect(effect.run.bind(effect), instance && instance.suspense);\r\n }\r\n else {\r\n effect.run();\r\n }\r\n return () => {\r\n effect.stop();\r\n if (instance && instance.scope) {\r\n remove(instance.scope.effects, effect);\r\n }\r\n };\r\n}\r\n// this.$watch\r\nfunction instanceWatch(source, value, options) {\r\n const publicThis = this.proxy;\r\n const getter = isString(source)\r\n ? source.includes('.')\r\n ? createPathGetter(publicThis, source)\r\n : () => publicThis[source]\r\n : source.bind(publicThis, publicThis);\r\n let cb;\r\n if (isFunction(value)) {\r\n cb = value;\r\n }\r\n else {\r\n cb = value.handler;\r\n options = value;\r\n }\r\n const cur = currentInstance;\r\n setCurrentInstance(this);\r\n const res = doWatch(getter, cb.bind(publicThis), options);\r\n if (cur) {\r\n setCurrentInstance(cur);\r\n }\r\n else {\r\n unsetCurrentInstance();\r\n }\r\n return res;\r\n}\r\nfunction createPathGetter(ctx, path) {\r\n const segments = path.split('.');\r\n return () => {\r\n let cur = ctx;\r\n for (let i = 0; i < segments.length && cur; i++) {\r\n cur = cur[segments[i]];\r\n }\r\n return cur;\r\n };\r\n}\r\nfunction traverse(value, seen) {\r\n if (!isObject(value) || value[\"__v_skip\" /* SKIP */]) {\r\n return value;\r\n }\r\n seen = seen || new Set();\r\n if (seen.has(value)) {\r\n return value;\r\n }\r\n seen.add(value);\r\n if (isRef(value)) {\r\n traverse(value.value, seen);\r\n }\r\n else if (isArray(value)) {\r\n for (let i = 0; i < value.length; i++) {\r\n traverse(value[i], seen);\r\n }\r\n }\r\n else if (isSet(value) || isMap(value)) {\r\n value.forEach((v) => {\r\n traverse(v, seen);\r\n });\r\n }\r\n else if (isPlainObject(value)) {\r\n for (const key in value) {\r\n traverse(value[key], seen);\r\n }\r\n }\r\n return value;\r\n}\n\n// dev only\r\nconst warnRuntimeUsage = (method) => warn(`${method}() is a compiler-hint helper that is only usable inside ` +\r\n `<script setup> of a single file component. Its arguments should be ` +\r\n `compiled away and passing it at runtime has no effect.`);\r\n// implementation\r\nfunction defineProps() {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`defineProps`);\r\n }\r\n return null;\r\n}\r\n// implementation\r\nfunction defineEmits() {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`defineEmits`);\r\n }\r\n return null;\r\n}\r\n/**\r\n * Vue `<script setup>` compiler macro for declaring a component's exposed\r\n * instance properties when it is accessed by a parent component via template\r\n * refs.\r\n *\r\n * `<script setup>` components are closed by default - i.e. varaibles inside\r\n * the `<script setup>` scope is not exposed to parent unless explicitly exposed\r\n * via `defineExpose`.\r\n *\r\n * This is only usable inside `<script setup>`, is compiled away in the\r\n * output and should **not** be actually called at runtime.\r\n */\r\nfunction defineExpose(exposed) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`defineExpose`);\r\n }\r\n}\r\n/**\r\n * Vue `<script setup>` compiler macro for providing props default values when\r\n * using type-based `defineProps` declaration.\r\n *\r\n * Example usage:\r\n * ```ts\r\n * withDefaults(defineProps<{\r\n * size?: number\r\n * labels?: string[]\r\n * }>(), {\r\n * size: 3,\r\n * labels: () => ['default label']\r\n * })\r\n * ```\r\n *\r\n * This is only usable inside `<script setup>`, is compiled away in the output\r\n * and should **not** be actually called at runtime.\r\n */\r\nfunction withDefaults(props, defaults) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warnRuntimeUsage(`withDefaults`);\r\n }\r\n return null;\r\n}\r\nfunction useSlots() {\r\n return getContext().slots;\r\n}\r\nfunction useAttrs() {\r\n return getContext().attrs;\r\n}\r\nfunction getContext() {\r\n const i = getCurrentInstance();\r\n if ((process.env.NODE_ENV !== 'production') && !i) {\r\n warn(`useContext() called without active instance.`);\r\n }\r\n return i.setupContext || (i.setupContext = createSetupContext(i));\r\n}\r\n/**\r\n * Runtime helper for merging default declarations. Imported by compiled code\r\n * only.\r\n * @internal\r\n */\r\nfunction mergeDefaults(raw, defaults) {\r\n const props = isArray(raw)\r\n ? raw.reduce((normalized, p) => ((normalized[p] = {}), normalized), {})\r\n : raw;\r\n for (const key in defaults) {\r\n const opt = props[key];\r\n if (opt) {\r\n if (isArray(opt) || isFunction(opt)) {\r\n props[key] = { type: opt, default: defaults[key] };\r\n }\r\n else {\r\n opt.default = defaults[key];\r\n }\r\n }\r\n else if (opt === null) {\r\n props[key] = { default: defaults[key] };\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`props default key \"${key}\" has no corresponding declaration.`);\r\n }\r\n }\r\n return props;\r\n}\r\n/**\r\n * Used to create a proxy for the rest element when destructuring props with\r\n * defineProps().\r\n * @internal\r\n */\r\nfunction createPropsRestProxy(props, excludedKeys) {\r\n const ret = {};\r\n for (const key in props) {\r\n if (!excludedKeys.includes(key)) {\r\n Object.defineProperty(ret, key, {\r\n enumerable: true,\r\n get: () => props[key]\r\n });\r\n }\r\n }\r\n return ret;\r\n}\r\n/**\r\n * `<script setup>` helper for persisting the current instance context over\r\n * async/await flows.\r\n *\r\n * `@vue/compiler-sfc` converts the following:\r\n *\r\n * ```ts\r\n * const x = await foo()\r\n * ```\r\n *\r\n * into:\r\n *\r\n * ```ts\r\n * let __temp, __restore\r\n * const x = (([__temp, __restore] = withAsyncContext(() => foo())),__temp=await __temp,__restore(),__temp)\r\n * ```\r\n * @internal\r\n */\r\nfunction withAsyncContext(getAwaitable) {\r\n const ctx = getCurrentInstance();\r\n if ((process.env.NODE_ENV !== 'production') && !ctx) {\r\n warn(`withAsyncContext called without active current instance. ` +\r\n `This is likely a bug.`);\r\n }\r\n let awaitable = getAwaitable();\r\n unsetCurrentInstance();\r\n if (isPromise(awaitable)) {\r\n awaitable = awaitable.catch(e => {\r\n setCurrentInstance(ctx);\r\n throw e;\r\n });\r\n }\r\n return [awaitable, () => setCurrentInstance(ctx)];\r\n}\n\n// Actual implementation\r\nfunction h(type, propsOrChildren, children) {\r\n const l = arguments.length;\r\n if (l === 2) {\r\n if (isObject(propsOrChildren) && !isArray(propsOrChildren)) {\r\n // single vnode without props\r\n if (isVNode(propsOrChildren)) {\r\n return createVNode(type, null, [propsOrChildren]);\r\n }\r\n // props without children\r\n return createVNode(type, propsOrChildren);\r\n }\r\n else {\r\n // omit props\r\n return createVNode(type, null, propsOrChildren);\r\n }\r\n }\r\n else {\r\n if (l > 3) {\r\n children = Array.prototype.slice.call(arguments, 2);\r\n }\r\n else if (l === 3 && isVNode(children)) {\r\n children = [children];\r\n }\r\n return createVNode(type, propsOrChildren, children);\r\n }\r\n}\n\nconst ssrContextKey = Symbol((process.env.NODE_ENV !== 'production') ? `ssrContext` : ``);\r\nconst useSSRContext = () => {\r\n {\r\n const ctx = inject(ssrContextKey);\r\n if (!ctx) {\r\n warn(`Server rendering context not provided. Make sure to only call ` +\r\n `useSSRContext() conditionally in the server build.`);\r\n }\r\n return ctx;\r\n }\r\n};\n\nfunction initCustomFormatter() {\r\n /* eslint-disable no-restricted-globals */\r\n if (!(process.env.NODE_ENV !== 'production') || typeof window === 'undefined') {\r\n return;\r\n }\r\n const vueStyle = { style: 'color:#3ba776' };\r\n const numberStyle = { style: 'color:#0b1bc9' };\r\n const stringStyle = { style: 'color:#b62e24' };\r\n const keywordStyle = { style: 'color:#9d288c' };\r\n // custom formatter for Chrome\r\n // https://www.mattzeunert.com/2016/02/19/custom-chrome-devtools-object-formatters.html\r\n const formatter = {\r\n header(obj) {\r\n // TODO also format ComponentPublicInstance & ctx.slots/attrs in setup\r\n if (!isObject(obj)) {\r\n return null;\r\n }\r\n if (obj.__isVue) {\r\n return ['div', vueStyle, `VueInstance`];\r\n }\r\n else if (isRef(obj)) {\r\n return [\r\n 'div',\r\n {},\r\n ['span', vueStyle, genRefFlag(obj)],\r\n '<',\r\n formatValue(obj.value),\r\n `>`\r\n ];\r\n }\r\n else if (isReactive(obj)) {\r\n return [\r\n 'div',\r\n {},\r\n ['span', vueStyle, 'Reactive'],\r\n '<',\r\n formatValue(obj),\r\n `>${isReadonly(obj) ? ` (readonly)` : ``}`\r\n ];\r\n }\r\n else if (isReadonly(obj)) {\r\n return [\r\n 'div',\r\n {},\r\n ['span', vueStyle, 'Readonly'],\r\n '<',\r\n formatValue(obj),\r\n '>'\r\n ];\r\n }\r\n return null;\r\n },\r\n hasBody(obj) {\r\n return obj && obj.__isVue;\r\n },\r\n body(obj) {\r\n if (obj && obj.__isVue) {\r\n return [\r\n 'div',\r\n {},\r\n ...formatInstance(obj.$)\r\n ];\r\n }\r\n }\r\n };\r\n function formatInstance(instance) {\r\n const blocks = [];\r\n if (instance.type.props && instance.props) {\r\n blocks.push(createInstanceBlock('props', toRaw(instance.props)));\r\n }\r\n if (instance.setupState !== EMPTY_OBJ) {\r\n blocks.push(createInstanceBlock('setup', instance.setupState));\r\n }\r\n if (instance.data !== EMPTY_OBJ) {\r\n blocks.push(createInstanceBlock('data', toRaw(instance.data)));\r\n }\r\n const computed = extractKeys(instance, 'computed');\r\n if (computed) {\r\n blocks.push(createInstanceBlock('computed', computed));\r\n }\r\n const injected = extractKeys(instance, 'inject');\r\n if (injected) {\r\n blocks.push(createInstanceBlock('injected', injected));\r\n }\r\n blocks.push([\r\n 'div',\r\n {},\r\n [\r\n 'span',\r\n {\r\n style: keywordStyle.style + ';opacity:0.66'\r\n },\r\n '$ (internal): '\r\n ],\r\n ['object', { object: instance }]\r\n ]);\r\n return blocks;\r\n }\r\n function createInstanceBlock(type, target) {\r\n target = extend({}, target);\r\n if (!Object.keys(target).length) {\r\n return ['span', {}];\r\n }\r\n return [\r\n 'div',\r\n { style: 'line-height:1.25em;margin-bottom:0.6em' },\r\n [\r\n 'div',\r\n {\r\n style: 'color:#476582'\r\n },\r\n type\r\n ],\r\n [\r\n 'div',\r\n {\r\n style: 'padding-left:1.25em'\r\n },\r\n ...Object.keys(target).map(key => {\r\n return [\r\n 'div',\r\n {},\r\n ['span', keywordStyle, key + ': '],\r\n formatValue(target[key], false)\r\n ];\r\n })\r\n ]\r\n ];\r\n }\r\n function formatValue(v, asRaw = true) {\r\n if (typeof v === 'number') {\r\n return ['span', numberStyle, v];\r\n }\r\n else if (typeof v === 'string') {\r\n return ['span', stringStyle, JSON.stringify(v)];\r\n }\r\n else if (typeof v === 'boolean') {\r\n return ['span', keywordStyle, v];\r\n }\r\n else if (isObject(v)) {\r\n return ['object', { object: asRaw ? toRaw(v) : v }];\r\n }\r\n else {\r\n return ['span', stringStyle, String(v)];\r\n }\r\n }\r\n function extractKeys(instance, type) {\r\n const Comp = instance.type;\r\n if (isFunction(Comp)) {\r\n return;\r\n }\r\n const extracted = {};\r\n for (const key in instance.ctx) {\r\n if (isKeyOfType(Comp, key, type)) {\r\n extracted[key] = instance.ctx[key];\r\n }\r\n }\r\n return extracted;\r\n }\r\n function isKeyOfType(Comp, key, type) {\r\n const opts = Comp[type];\r\n if ((isArray(opts) && opts.includes(key)) ||\r\n (isObject(opts) && key in opts)) {\r\n return true;\r\n }\r\n if (Comp.extends && isKeyOfType(Comp.extends, key, type)) {\r\n return true;\r\n }\r\n if (Comp.mixins && Comp.mixins.some(m => isKeyOfType(m, key, type))) {\r\n return true;\r\n }\r\n }\r\n function genRefFlag(v) {\r\n if (v._shallow) {\r\n return `ShallowRef`;\r\n }\r\n if (v.effect) {\r\n return `ComputedRef`;\r\n }\r\n return `Ref`;\r\n }\r\n if (window.devtoolsFormatters) {\r\n window.devtoolsFormatters.push(formatter);\r\n }\r\n else {\r\n window.devtoolsFormatters = [formatter];\r\n }\r\n}\n\nfunction withMemo(memo, render, cache, index) {\r\n const cached = cache[index];\r\n if (cached && isMemoSame(cached, memo)) {\r\n return cached;\r\n }\r\n const ret = render();\r\n // shallow clone\r\n ret.memo = memo.slice();\r\n return (cache[index] = ret);\r\n}\r\nfunction isMemoSame(cached, memo) {\r\n const prev = cached.memo;\r\n if (prev.length != memo.length) {\r\n return false;\r\n }\r\n for (let i = 0; i < prev.length; i++) {\r\n if (prev[i] !== memo[i]) {\r\n return false;\r\n }\r\n }\r\n // make sure to let parent block track it when returning cached\r\n if (isBlockTreeEnabled > 0 && currentBlock) {\r\n currentBlock.push(cached);\r\n }\r\n return true;\r\n}\n\n// Core API ------------------------------------------------------------------\r\nconst version = \"3.2.23\";\r\nconst _ssrUtils = {\r\n createComponentInstance,\r\n setupComponent,\r\n renderComponentRoot,\r\n setCurrentRenderingInstance,\r\n isVNode,\r\n normalizeVNode\r\n};\r\n/**\r\n * SSR utils for \\@vue/server-renderer. Only exposed in cjs builds.\r\n * @internal\r\n */\r\nconst ssrUtils = (_ssrUtils );\r\n/**\r\n * @internal only exposed in compat builds\r\n */\r\nconst resolveFilter = null;\r\n/**\r\n * @internal only exposed in compat builds.\r\n */\r\nconst compatUtils = (null);\n\nexport { BaseTransition, Comment, Fragment, KeepAlive, Static, Suspense, Teleport, Text, callWithAsyncErrorHandling, callWithErrorHandling, cloneVNode, compatUtils, createBlock, createCommentVNode, createElementBlock, createBaseVNode as createElementVNode, createHydrationRenderer, createPropsRestProxy, createRenderer, createSlots, createStaticVNode, createTextVNode, createVNode, defineAsyncComponent, defineComponent, defineEmits, defineExpose, defineProps, devtools, getCurrentInstance, getTransitionRawChildren, guardReactiveProps, h, handleError, initCustomFormatter, inject, isMemoSame, isRuntimeOnly, isVNode, mergeDefaults, mergeProps, nextTick, onActivated, onBeforeMount, onBeforeUnmount, onBeforeUpdate, onDeactivated, onErrorCaptured, onMounted, onRenderTracked, onRenderTriggered, onServerPrefetch, onUnmounted, onUpdated, openBlock, popScopeId, provide, pushScopeId, queuePostFlushCb, registerRuntimeCompiler, renderList, renderSlot, resolveComponent, resolveDirective, resolveDynamicComponent, resolveFilter, resolveTransitionHooks, setBlockTracking, setDevtoolsHook, setTransitionHooks, ssrContextKey, ssrUtils, toHandlers, transformVNodeArgs, useAttrs, useSSRContext, useSlots, useTransitionState, version, warn, watch, watchEffect, watchPostEffect, watchSyncEffect, withAsyncContext, withCtx, withDefaults, withDirectives, withMemo, withScopeId };\n","import { camelize, warn, callWithAsyncErrorHandling, defineComponent, nextTick, createVNode, getCurrentInstance, watchPostEffect, onMounted, onUnmounted, Fragment, Static, h, BaseTransition, useTransitionState, onUpdated, toRaw, getTransitionRawChildren, setTransitionHooks, resolveTransitionHooks, createRenderer, isRuntimeOnly, createHydrationRenderer } from '@vue/runtime-core';\nexport * from '@vue/runtime-core';\nimport { isString, isArray, hyphenate, capitalize, isSpecialBooleanAttr, includeBooleanAttr, isOn, isModelListener, isFunction, toNumber, camelize as camelize$1, extend, EMPTY_OBJ, isObject, invokeArrayFns, looseIndexOf, isSet, looseEqual, isHTMLTag, isSVGTag } from '@vue/shared';\n\nconst svgNS = 'http://www.w3.org/2000/svg';\r\nconst doc = (typeof document !== 'undefined' ? document : null);\r\nconst staticTemplateCache = new Map();\r\nconst nodeOps = {\r\n insert: (child, parent, anchor) => {\r\n parent.insertBefore(child, anchor || null);\r\n },\r\n remove: child => {\r\n const parent = child.parentNode;\r\n if (parent) {\r\n parent.removeChild(child);\r\n }\r\n },\r\n createElement: (tag, isSVG, is, props) => {\r\n const el = isSVG\r\n ? doc.createElementNS(svgNS, tag)\r\n : doc.createElement(tag, is ? { is } : undefined);\r\n if (tag === 'select' && props && props.multiple != null) {\r\n el.setAttribute('multiple', props.multiple);\r\n }\r\n return el;\r\n },\r\n createText: text => doc.createTextNode(text),\r\n createComment: text => doc.createComment(text),\r\n setText: (node, text) => {\r\n node.nodeValue = text;\r\n },\r\n setElementText: (el, text) => {\r\n el.textContent = text;\r\n },\r\n parentNode: node => node.parentNode,\r\n nextSibling: node => node.nextSibling,\r\n querySelector: selector => doc.querySelector(selector),\r\n setScopeId(el, id) {\r\n el.setAttribute(id, '');\r\n },\r\n cloneNode(el) {\r\n const cloned = el.cloneNode(true);\r\n // #3072\r\n // - in `patchDOMProp`, we store the actual value in the `el._value` property.\r\n // - normally, elements using `:value` bindings will not be hoisted, but if\r\n // the bound value is a constant, e.g. `:value=\"true\"` - they do get\r\n // hoisted.\r\n // - in production, hoisted nodes are cloned when subsequent inserts, but\r\n // cloneNode() does not copy the custom property we attached.\r\n // - This may need to account for other custom DOM properties we attach to\r\n // elements in addition to `_value` in the future.\r\n if (`_value` in el) {\r\n cloned._value = el._value;\r\n }\r\n return cloned;\r\n },\r\n // __UNSAFE__\r\n // Reason: innerHTML.\r\n // Static content here can only come from compiled templates.\r\n // As long as the user only uses trusted templates, this is safe.\r\n insertStaticContent(content, parent, anchor, isSVG) {\r\n // <parent> before | first ... last | anchor </parent>\r\n const before = anchor ? anchor.previousSibling : parent.lastChild;\r\n let template = staticTemplateCache.get(content);\r\n if (!template) {\r\n const t = doc.createElement('template');\r\n t.innerHTML = isSVG ? `<svg>${content}</svg>` : content;\r\n template = t.content;\r\n if (isSVG) {\r\n // remove outer svg wrapper\r\n const wrapper = template.firstChild;\r\n while (wrapper.firstChild) {\r\n template.appendChild(wrapper.firstChild);\r\n }\r\n template.removeChild(wrapper);\r\n }\r\n staticTemplateCache.set(content, template);\r\n }\r\n parent.insertBefore(template.cloneNode(true), anchor);\r\n return [\r\n // first\r\n before ? before.nextSibling : parent.firstChild,\r\n // last\r\n anchor ? anchor.previousSibling : parent.lastChild\r\n ];\r\n }\r\n};\n\n// compiler should normalize class + :class bindings on the same element\r\n// into a single binding ['staticClass', dynamic]\r\nfunction patchClass(el, value, isSVG) {\r\n // directly setting className should be faster than setAttribute in theory\r\n // if this is an element during a transition, take the temporary transition\r\n // classes into account.\r\n const transitionClasses = el._vtc;\r\n if (transitionClasses) {\r\n value = (value ? [value, ...transitionClasses] : [...transitionClasses]).join(' ');\r\n }\r\n if (value == null) {\r\n el.removeAttribute('class');\r\n }\r\n else if (isSVG) {\r\n el.setAttribute('class', value);\r\n }\r\n else {\r\n el.className = value;\r\n }\r\n}\n\nfunction patchStyle(el, prev, next) {\r\n const style = el.style;\r\n const isCssString = isString(next);\r\n if (next && !isCssString) {\r\n for (const key in next) {\r\n setStyle(style, key, next[key]);\r\n }\r\n if (prev && !isString(prev)) {\r\n for (const key in prev) {\r\n if (next[key] == null) {\r\n setStyle(style, key, '');\r\n }\r\n }\r\n }\r\n }\r\n else {\r\n const currentDisplay = style.display;\r\n if (isCssString) {\r\n if (prev !== next) {\r\n style.cssText = next;\r\n }\r\n }\r\n else if (prev) {\r\n el.removeAttribute('style');\r\n }\r\n // indicates that the `display` of the element is controlled by `v-show`,\r\n // so we always keep the current `display` value regardless of the `style`\r\n // value, thus handing over control to `v-show`.\r\n if ('_vod' in el) {\r\n style.display = currentDisplay;\r\n }\r\n }\r\n}\r\nconst importantRE = /\\s*!important$/;\r\nfunction setStyle(style, name, val) {\r\n if (isArray(val)) {\r\n val.forEach(v => setStyle(style, name, v));\r\n }\r\n else {\r\n if (name.startsWith('--')) {\r\n // custom property definition\r\n style.setProperty(name, val);\r\n }\r\n else {\r\n const prefixed = autoPrefix(style, name);\r\n if (importantRE.test(val)) {\r\n // !important\r\n style.setProperty(hyphenate(prefixed), val.replace(importantRE, ''), 'important');\r\n }\r\n else {\r\n style[prefixed] = val;\r\n }\r\n }\r\n }\r\n}\r\nconst prefixes = ['Webkit', 'Moz', 'ms'];\r\nconst prefixCache = {};\r\nfunction autoPrefix(style, rawName) {\r\n const cached = prefixCache[rawName];\r\n if (cached) {\r\n return cached;\r\n }\r\n let name = camelize(rawName);\r\n if (name !== 'filter' && name in style) {\r\n return (prefixCache[rawName] = name);\r\n }\r\n name = capitalize(name);\r\n for (let i = 0; i < prefixes.length; i++) {\r\n const prefixed = prefixes[i] + name;\r\n if (prefixed in style) {\r\n return (prefixCache[rawName] = prefixed);\r\n }\r\n }\r\n return rawName;\r\n}\n\nconst xlinkNS = 'http://www.w3.org/1999/xlink';\r\nfunction patchAttr(el, key, value, isSVG, instance) {\r\n if (isSVG && key.startsWith('xlink:')) {\r\n if (value == null) {\r\n el.removeAttributeNS(xlinkNS, key.slice(6, key.length));\r\n }\r\n else {\r\n el.setAttributeNS(xlinkNS, key, value);\r\n }\r\n }\r\n else {\r\n // note we are only checking boolean attributes that don't have a\r\n // corresponding dom prop of the same name here.\r\n const isBoolean = isSpecialBooleanAttr(key);\r\n if (value == null || (isBoolean && !includeBooleanAttr(value))) {\r\n el.removeAttribute(key);\r\n }\r\n else {\r\n el.setAttribute(key, isBoolean ? '' : value);\r\n }\r\n }\r\n}\n\n// __UNSAFE__\r\n// functions. The user is responsible for using them with only trusted content.\r\nfunction patchDOMProp(el, key, value, \r\n// the following args are passed only due to potential innerHTML/textContent\r\n// overriding existing VNodes, in which case the old tree must be properly\r\n// unmounted.\r\nprevChildren, parentComponent, parentSuspense, unmountChildren) {\r\n if (key === 'innerHTML' || key === 'textContent') {\r\n if (prevChildren) {\r\n unmountChildren(prevChildren, parentComponent, parentSuspense);\r\n }\r\n el[key] = value == null ? '' : value;\r\n return;\r\n }\r\n if (key === 'value' &&\r\n el.tagName !== 'PROGRESS' &&\r\n // custom elements may use _value internally\r\n !el.tagName.includes('-')) {\r\n // store value as _value as well since\r\n // non-string values will be stringified.\r\n el._value = value;\r\n const newValue = value == null ? '' : value;\r\n if (el.value !== newValue ||\r\n // #4956: always set for OPTION elements because its value falls back to\r\n // textContent if no value attribute is present. And setting .value for\r\n // OPTION has no side effect\r\n el.tagName === 'OPTION') {\r\n el.value = newValue;\r\n }\r\n if (value == null) {\r\n el.removeAttribute(key);\r\n }\r\n return;\r\n }\r\n if (value === '' || value == null) {\r\n const type = typeof el[key];\r\n if (type === 'boolean') {\r\n // e.g. <select multiple> compiles to { multiple: '' }\r\n el[key] = includeBooleanAttr(value);\r\n return;\r\n }\r\n else if (value == null && type === 'string') {\r\n // e.g. <div :id=\"null\">\r\n el[key] = '';\r\n el.removeAttribute(key);\r\n return;\r\n }\r\n else if (type === 'number') {\r\n // e.g. <img :width=\"null\">\r\n // the value of some IDL attr must be greater than 0, e.g. input.size = 0 -> error\r\n try {\r\n el[key] = 0;\r\n }\r\n catch (_a) { }\r\n el.removeAttribute(key);\r\n return;\r\n }\r\n }\r\n // some properties perform value validation and throw\r\n try {\r\n el[key] = value;\r\n }\r\n catch (e) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`Failed setting prop \"${key}\" on <${el.tagName.toLowerCase()}>: ` +\r\n `value ${value} is invalid.`, e);\r\n }\r\n }\r\n}\n\n// Async edge case fix requires storing an event listener's attach timestamp.\r\nlet _getNow = Date.now;\r\nlet skipTimestampCheck = false;\r\nif (typeof window !== 'undefined') {\r\n // Determine what event timestamp the browser is using. Annoyingly, the\r\n // timestamp can either be hi-res (relative to page load) or low-res\r\n // (relative to UNIX epoch), so in order to compare time we have to use the\r\n // same timestamp type when saving the flush timestamp.\r\n if (_getNow() > document.createEvent('Event').timeStamp) {\r\n // if the low-res timestamp which is bigger than the event timestamp\r\n // (which is evaluated AFTER) it means the event is using a hi-res timestamp,\r\n // and we need to use the hi-res version for event listeners as well.\r\n _getNow = () => performance.now();\r\n }\r\n // #3485: Firefox <= 53 has incorrect Event.timeStamp implementation\r\n // and does not fire microtasks in between event propagation, so safe to exclude.\r\n const ffMatch = navigator.userAgent.match(/firefox\\/(\\d+)/i);\r\n skipTimestampCheck = !!(ffMatch && Number(ffMatch[1]) <= 53);\r\n}\r\n// To avoid the overhead of repeatedly calling performance.now(), we cache\r\n// and use the same timestamp for all event listeners attached in the same tick.\r\nlet cachedNow = 0;\r\nconst p = Promise.resolve();\r\nconst reset = () => {\r\n cachedNow = 0;\r\n};\r\nconst getNow = () => cachedNow || (p.then(reset), (cachedNow = _getNow()));\r\nfunction addEventListener(el, event, handler, options) {\r\n el.addEventListener(event, handler, options);\r\n}\r\nfunction removeEventListener(el, event, handler, options) {\r\n el.removeEventListener(event, handler, options);\r\n}\r\nfunction patchEvent(el, rawName, prevValue, nextValue, instance = null) {\r\n // vei = vue event invokers\r\n const invokers = el._vei || (el._vei = {});\r\n const existingInvoker = invokers[rawName];\r\n if (nextValue && existingInvoker) {\r\n // patch\r\n existingInvoker.value = nextValue;\r\n }\r\n else {\r\n const [name, options] = parseName(rawName);\r\n if (nextValue) {\r\n // add\r\n const invoker = (invokers[rawName] = createInvoker(nextValue, instance));\r\n addEventListener(el, name, invoker, options);\r\n }\r\n else if (existingInvoker) {\r\n // remove\r\n removeEventListener(el, name, existingInvoker, options);\r\n invokers[rawName] = undefined;\r\n }\r\n }\r\n}\r\nconst optionsModifierRE = /(?:Once|Passive|Capture)$/;\r\nfunction parseName(name) {\r\n let options;\r\n if (optionsModifierRE.test(name)) {\r\n options = {};\r\n let m;\r\n while ((m = name.match(optionsModifierRE))) {\r\n name = name.slice(0, name.length - m[0].length);\r\n options[m[0].toLowerCase()] = true;\r\n }\r\n }\r\n return [hyphenate(name.slice(2)), options];\r\n}\r\nfunction createInvoker(initialValue, instance) {\r\n const invoker = (e) => {\r\n // async edge case #6566: inner click event triggers patch, event handler\r\n // attached to outer element during patch, and triggered again. This\r\n // happens because browsers fire microtask ticks between event propagation.\r\n // the solution is simple: we save the timestamp when a handler is attached,\r\n // and the handler would only fire if the event passed to it was fired\r\n // AFTER it was attached.\r\n const timeStamp = e.timeStamp || _getNow();\r\n if (skipTimestampCheck || timeStamp >= invoker.attached - 1) {\r\n callWithAsyncErrorHandling(patchStopImmediatePropagation(e, invoker.value), instance, 5 /* NATIVE_EVENT_HANDLER */, [e]);\r\n }\r\n };\r\n invoker.value = initialValue;\r\n invoker.attached = getNow();\r\n return invoker;\r\n}\r\nfunction patchStopImmediatePropagation(e, value) {\r\n if (isArray(value)) {\r\n const originalStop = e.stopImmediatePropagation;\r\n e.stopImmediatePropagation = () => {\r\n originalStop.call(e);\r\n e._stopped = true;\r\n };\r\n return value.map(fn => (e) => !e._stopped && fn(e));\r\n }\r\n else {\r\n return value;\r\n }\r\n}\n\nconst nativeOnRE = /^on[a-z]/;\r\nconst patchProp = (el, key, prevValue, nextValue, isSVG = false, prevChildren, parentComponent, parentSuspense, unmountChildren) => {\r\n if (key === 'class') {\r\n patchClass(el, nextValue, isSVG);\r\n }\r\n else if (key === 'style') {\r\n patchStyle(el, prevValue, nextValue);\r\n }\r\n else if (isOn(key)) {\r\n // ignore v-model listeners\r\n if (!isModelListener(key)) {\r\n patchEvent(el, key, prevValue, nextValue, parentComponent);\r\n }\r\n }\r\n else if (key[0] === '.'\r\n ? ((key = key.slice(1)), true)\r\n : key[0] === '^'\r\n ? ((key = key.slice(1)), false)\r\n : shouldSetAsProp(el, key, nextValue, isSVG)) {\r\n patchDOMProp(el, key, nextValue, prevChildren, parentComponent, parentSuspense, unmountChildren);\r\n }\r\n else {\r\n // special case for <input v-model type=\"checkbox\"> with\r\n // :true-value & :false-value\r\n // store value as dom properties since non-string values will be\r\n // stringified.\r\n if (key === 'true-value') {\r\n el._trueValue = nextValue;\r\n }\r\n else if (key === 'false-value') {\r\n el._falseValue = nextValue;\r\n }\r\n patchAttr(el, key, nextValue, isSVG);\r\n }\r\n};\r\nfunction shouldSetAsProp(el, key, value, isSVG) {\r\n if (isSVG) {\r\n // most keys must be set as attribute on svg elements to work\r\n // ...except innerHTML & textContent\r\n if (key === 'innerHTML' || key === 'textContent') {\r\n return true;\r\n }\r\n // or native onclick with function values\r\n if (key in el && nativeOnRE.test(key) && isFunction(value)) {\r\n return true;\r\n }\r\n return false;\r\n }\r\n // spellcheck and draggable are numerated attrs, however their\r\n // corresponding DOM properties are actually booleans - this leads to\r\n // setting it with a string \"false\" value leading it to be coerced to\r\n // `true`, so we need to always treat them as attributes.\r\n // Note that `contentEditable` doesn't have this problem: its DOM\r\n // property is also enumerated string values.\r\n if (key === 'spellcheck' || key === 'draggable') {\r\n return false;\r\n }\r\n // #1787, #2840 form property on form elements is readonly and must be set as\r\n // attribute.\r\n if (key === 'form') {\r\n return false;\r\n }\r\n // #1526 <input list> must be set as attribute\r\n if (key === 'list' && el.tagName === 'INPUT') {\r\n return false;\r\n }\r\n // #2766 <textarea type> must be set as attribute\r\n if (key === 'type' && el.tagName === 'TEXTAREA') {\r\n return false;\r\n }\r\n // native onclick with string value, must be set as attribute\r\n if (nativeOnRE.test(key) && isString(value)) {\r\n return false;\r\n }\r\n return key in el;\r\n}\n\nfunction defineCustomElement(options, hydate) {\r\n const Comp = defineComponent(options);\r\n class VueCustomElement extends VueElement {\r\n constructor(initialProps) {\r\n super(Comp, initialProps, hydate);\r\n }\r\n }\r\n VueCustomElement.def = Comp;\r\n return VueCustomElement;\r\n}\r\nconst defineSSRCustomElement = ((options) => {\r\n // @ts-ignore\r\n return defineCustomElement(options, hydrate);\r\n});\r\nconst BaseClass = (typeof HTMLElement !== 'undefined' ? HTMLElement : class {\r\n});\r\nclass VueElement extends BaseClass {\r\n constructor(_def, _props = {}, hydrate) {\r\n super();\r\n this._def = _def;\r\n this._props = _props;\r\n /**\r\n * @internal\r\n */\r\n this._instance = null;\r\n this._connected = false;\r\n this._resolved = false;\r\n this._numberProps = null;\r\n if (this.shadowRoot && hydrate) {\r\n hydrate(this._createVNode(), this.shadowRoot);\r\n }\r\n else {\r\n if ((process.env.NODE_ENV !== 'production') && this.shadowRoot) {\r\n warn(`Custom element has pre-rendered declarative shadow root but is not ` +\r\n `defined as hydratable. Use \\`defineSSRCustomElement\\`.`);\r\n }\r\n this.attachShadow({ mode: 'open' });\r\n }\r\n }\r\n connectedCallback() {\r\n this._connected = true;\r\n if (!this._instance) {\r\n this._resolveDef();\r\n }\r\n }\r\n disconnectedCallback() {\r\n this._connected = false;\r\n nextTick(() => {\r\n if (!this._connected) {\r\n render(null, this.shadowRoot);\r\n this._instance = null;\r\n }\r\n });\r\n }\r\n /**\r\n * resolve inner component definition (handle possible async component)\r\n */\r\n _resolveDef() {\r\n if (this._resolved) {\r\n return;\r\n }\r\n this._resolved = true;\r\n // set initial attrs\r\n for (let i = 0; i < this.attributes.length; i++) {\r\n this._setAttr(this.attributes[i].name);\r\n }\r\n // watch future attr changes\r\n new MutationObserver(mutations => {\r\n for (const m of mutations) {\r\n this._setAttr(m.attributeName);\r\n }\r\n }).observe(this, { attributes: true });\r\n const resolve = (def) => {\r\n const { props, styles } = def;\r\n const hasOptions = !isArray(props);\r\n const rawKeys = props ? (hasOptions ? Object.keys(props) : props) : [];\r\n // cast Number-type props set before resolve\r\n let numberProps;\r\n if (hasOptions) {\r\n for (const key in this._props) {\r\n const opt = props[key];\r\n if (opt === Number || (opt && opt.type === Number)) {\r\n this._props[key] = toNumber(this._props[key]);\r\n (numberProps || (numberProps = Object.create(null)))[key] = true;\r\n }\r\n }\r\n }\r\n this._numberProps = numberProps;\r\n // check if there are props set pre-upgrade or connect\r\n for (const key of Object.keys(this)) {\r\n if (key[0] !== '_') {\r\n this._setProp(key, this[key], true, false);\r\n }\r\n }\r\n // defining getter/setters on prototype\r\n for (const key of rawKeys.map(camelize$1)) {\r\n Object.defineProperty(this, key, {\r\n get() {\r\n return this._getProp(key);\r\n },\r\n set(val) {\r\n this._setProp(key, val);\r\n }\r\n });\r\n }\r\n // apply CSS\r\n this._applyStyles(styles);\r\n // initial render\r\n this._update();\r\n };\r\n const asyncDef = this._def.__asyncLoader;\r\n if (asyncDef) {\r\n asyncDef().then(resolve);\r\n }\r\n else {\r\n resolve(this._def);\r\n }\r\n }\r\n _setAttr(key) {\r\n let value = this.getAttribute(key);\r\n if (this._numberProps && this._numberProps[key]) {\r\n value = toNumber(value);\r\n }\r\n this._setProp(camelize$1(key), value, false);\r\n }\r\n /**\r\n * @internal\r\n */\r\n _getProp(key) {\r\n return this._props[key];\r\n }\r\n /**\r\n * @internal\r\n */\r\n _setProp(key, val, shouldReflect = true, shouldUpdate = true) {\r\n if (val !== this._props[key]) {\r\n this._props[key] = val;\r\n if (shouldUpdate && this._instance) {\r\n this._update();\r\n }\r\n // reflect\r\n if (shouldReflect) {\r\n if (val === true) {\r\n this.setAttribute(hyphenate(key), '');\r\n }\r\n else if (typeof val === 'string' || typeof val === 'number') {\r\n this.setAttribute(hyphenate(key), val + '');\r\n }\r\n else if (!val) {\r\n this.removeAttribute(hyphenate(key));\r\n }\r\n }\r\n }\r\n }\r\n _update() {\r\n render(this._createVNode(), this.shadowRoot);\r\n }\r\n _createVNode() {\r\n const vnode = createVNode(this._def, extend({}, this._props));\r\n if (!this._instance) {\r\n vnode.ce = instance => {\r\n this._instance = instance;\r\n instance.isCE = true;\r\n // HMR\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n instance.ceReload = newStyles => {\r\n // alawys reset styles\r\n if (this._styles) {\r\n this._styles.forEach(s => this.shadowRoot.removeChild(s));\r\n this._styles.length = 0;\r\n }\r\n this._applyStyles(newStyles);\r\n // if this is an async component, ceReload is called from the inner\r\n // component so no need to reload the async wrapper\r\n if (!this._def.__asyncLoader) {\r\n // reload\r\n this._instance = null;\r\n this._update();\r\n }\r\n };\r\n }\r\n // intercept emit\r\n instance.emit = (event, ...args) => {\r\n this.dispatchEvent(new CustomEvent(event, {\r\n detail: args\r\n }));\r\n };\r\n // locate nearest Vue custom element parent for provide/inject\r\n let parent = this;\r\n while ((parent =\r\n parent && (parent.parentNode || parent.host))) {\r\n if (parent instanceof VueElement) {\r\n instance.parent = parent._instance;\r\n break;\r\n }\r\n }\r\n };\r\n }\r\n return vnode;\r\n }\r\n _applyStyles(styles) {\r\n if (styles) {\r\n styles.forEach(css => {\r\n const s = document.createElement('style');\r\n s.textContent = css;\r\n this.shadowRoot.appendChild(s);\r\n // record for HMR\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n (this._styles || (this._styles = [])).push(s);\r\n }\r\n });\r\n }\r\n }\r\n}\n\nfunction useCssModule(name = '$style') {\r\n /* istanbul ignore else */\r\n {\r\n const instance = getCurrentInstance();\r\n if (!instance) {\r\n (process.env.NODE_ENV !== 'production') && warn(`useCssModule must be called inside setup()`);\r\n return EMPTY_OBJ;\r\n }\r\n const modules = instance.type.__cssModules;\r\n if (!modules) {\r\n (process.env.NODE_ENV !== 'production') && warn(`Current instance does not have CSS modules injected.`);\r\n return EMPTY_OBJ;\r\n }\r\n const mod = modules[name];\r\n if (!mod) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`Current instance does not have CSS module named \"${name}\".`);\r\n return EMPTY_OBJ;\r\n }\r\n return mod;\r\n }\r\n}\n\n/**\r\n * Runtime helper for SFC's CSS variable injection feature.\r\n * @private\r\n */\r\nfunction useCssVars(getter) {\r\n const instance = getCurrentInstance();\r\n /* istanbul ignore next */\r\n if (!instance) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`useCssVars is called without current active component instance.`);\r\n return;\r\n }\r\n const setVars = () => setVarsOnVNode(instance.subTree, getter(instance.proxy));\r\n watchPostEffect(setVars);\r\n onMounted(() => {\r\n const ob = new MutationObserver(setVars);\r\n ob.observe(instance.subTree.el.parentNode, { childList: true });\r\n onUnmounted(() => ob.disconnect());\r\n });\r\n}\r\nfunction setVarsOnVNode(vnode, vars) {\r\n if (vnode.shapeFlag & 128 /* SUSPENSE */) {\r\n const suspense = vnode.suspense;\r\n vnode = suspense.activeBranch;\r\n if (suspense.pendingBranch && !suspense.isHydrating) {\r\n suspense.effects.push(() => {\r\n setVarsOnVNode(suspense.activeBranch, vars);\r\n });\r\n }\r\n }\r\n // drill down HOCs until it's a non-component vnode\r\n while (vnode.component) {\r\n vnode = vnode.component.subTree;\r\n }\r\n if (vnode.shapeFlag & 1 /* ELEMENT */ && vnode.el) {\r\n setVarsOnNode(vnode.el, vars);\r\n }\r\n else if (vnode.type === Fragment) {\r\n vnode.children.forEach(c => setVarsOnVNode(c, vars));\r\n }\r\n else if (vnode.type === Static) {\r\n let { el, anchor } = vnode;\r\n while (el) {\r\n setVarsOnNode(el, vars);\r\n if (el === anchor)\r\n break;\r\n el = el.nextSibling;\r\n }\r\n }\r\n}\r\nfunction setVarsOnNode(el, vars) {\r\n if (el.nodeType === 1) {\r\n const style = el.style;\r\n for (const key in vars) {\r\n style.setProperty(`--${key}`, vars[key]);\r\n }\r\n }\r\n}\n\nconst TRANSITION = 'transition';\r\nconst ANIMATION = 'animation';\r\n// DOM Transition is a higher-order-component based on the platform-agnostic\r\n// base Transition component, with DOM-specific logic.\r\nconst Transition = (props, { slots }) => h(BaseTransition, resolveTransitionProps(props), slots);\r\nTransition.displayName = 'Transition';\r\nconst DOMTransitionPropsValidators = {\r\n name: String,\r\n type: String,\r\n css: {\r\n type: Boolean,\r\n default: true\r\n },\r\n duration: [String, Number, Object],\r\n enterFromClass: String,\r\n enterActiveClass: String,\r\n enterToClass: String,\r\n appearFromClass: String,\r\n appearActiveClass: String,\r\n appearToClass: String,\r\n leaveFromClass: String,\r\n leaveActiveClass: String,\r\n leaveToClass: String\r\n};\r\nconst TransitionPropsValidators = (Transition.props =\r\n /*#__PURE__*/ extend({}, BaseTransition.props, DOMTransitionPropsValidators));\r\n/**\r\n * #3227 Incoming hooks may be merged into arrays when wrapping Transition\r\n * with custom HOCs.\r\n */\r\nconst callHook = (hook, args = []) => {\r\n if (isArray(hook)) {\r\n hook.forEach(h => h(...args));\r\n }\r\n else if (hook) {\r\n hook(...args);\r\n }\r\n};\r\n/**\r\n * Check if a hook expects a callback (2nd arg), which means the user\r\n * intends to explicitly control the end of the transition.\r\n */\r\nconst hasExplicitCallback = (hook) => {\r\n return hook\r\n ? isArray(hook)\r\n ? hook.some(h => h.length > 1)\r\n : hook.length > 1\r\n : false;\r\n};\r\nfunction resolveTransitionProps(rawProps) {\r\n const baseProps = {};\r\n for (const key in rawProps) {\r\n if (!(key in DOMTransitionPropsValidators)) {\r\n baseProps[key] = rawProps[key];\r\n }\r\n }\r\n if (rawProps.css === false) {\r\n return baseProps;\r\n }\r\n const { name = 'v', type, duration, enterFromClass = `${name}-enter-from`, enterActiveClass = `${name}-enter-active`, enterToClass = `${name}-enter-to`, appearFromClass = enterFromClass, appearActiveClass = enterActiveClass, appearToClass = enterToClass, leaveFromClass = `${name}-leave-from`, leaveActiveClass = `${name}-leave-active`, leaveToClass = `${name}-leave-to` } = rawProps;\r\n const durations = normalizeDuration(duration);\r\n const enterDuration = durations && durations[0];\r\n const leaveDuration = durations && durations[1];\r\n const { onBeforeEnter, onEnter, onEnterCancelled, onLeave, onLeaveCancelled, onBeforeAppear = onBeforeEnter, onAppear = onEnter, onAppearCancelled = onEnterCancelled } = baseProps;\r\n const finishEnter = (el, isAppear, done) => {\r\n removeTransitionClass(el, isAppear ? appearToClass : enterToClass);\r\n removeTransitionClass(el, isAppear ? appearActiveClass : enterActiveClass);\r\n done && done();\r\n };\r\n const finishLeave = (el, done) => {\r\n removeTransitionClass(el, leaveToClass);\r\n removeTransitionClass(el, leaveActiveClass);\r\n done && done();\r\n };\r\n const makeEnterHook = (isAppear) => {\r\n return (el, done) => {\r\n const hook = isAppear ? onAppear : onEnter;\r\n const resolve = () => finishEnter(el, isAppear, done);\r\n callHook(hook, [el, resolve]);\r\n nextFrame(() => {\r\n removeTransitionClass(el, isAppear ? appearFromClass : enterFromClass);\r\n addTransitionClass(el, isAppear ? appearToClass : enterToClass);\r\n if (!hasExplicitCallback(hook)) {\r\n whenTransitionEnds(el, type, enterDuration, resolve);\r\n }\r\n });\r\n };\r\n };\r\n return extend(baseProps, {\r\n onBeforeEnter(el) {\r\n callHook(onBeforeEnter, [el]);\r\n addTransitionClass(el, enterFromClass);\r\n addTransitionClass(el, enterActiveClass);\r\n },\r\n onBeforeAppear(el) {\r\n callHook(onBeforeAppear, [el]);\r\n addTransitionClass(el, appearFromClass);\r\n addTransitionClass(el, appearActiveClass);\r\n },\r\n onEnter: makeEnterHook(false),\r\n onAppear: makeEnterHook(true),\r\n onLeave(el, done) {\r\n const resolve = () => finishLeave(el, done);\r\n addTransitionClass(el, leaveFromClass);\r\n // force reflow so *-leave-from classes immediately take effect (#2593)\r\n forceReflow();\r\n addTransitionClass(el, leaveActiveClass);\r\n nextFrame(() => {\r\n removeTransitionClass(el, leaveFromClass);\r\n addTransitionClass(el, leaveToClass);\r\n if (!hasExplicitCallback(onLeave)) {\r\n whenTransitionEnds(el, type, leaveDuration, resolve);\r\n }\r\n });\r\n callHook(onLeave, [el, resolve]);\r\n },\r\n onEnterCancelled(el) {\r\n finishEnter(el, false);\r\n callHook(onEnterCancelled, [el]);\r\n },\r\n onAppearCancelled(el) {\r\n finishEnter(el, true);\r\n callHook(onAppearCancelled, [el]);\r\n },\r\n onLeaveCancelled(el) {\r\n finishLeave(el);\r\n callHook(onLeaveCancelled, [el]);\r\n }\r\n });\r\n}\r\nfunction normalizeDuration(duration) {\r\n if (duration == null) {\r\n return null;\r\n }\r\n else if (isObject(duration)) {\r\n return [NumberOf(duration.enter), NumberOf(duration.leave)];\r\n }\r\n else {\r\n const n = NumberOf(duration);\r\n return [n, n];\r\n }\r\n}\r\nfunction NumberOf(val) {\r\n const res = toNumber(val);\r\n if ((process.env.NODE_ENV !== 'production'))\r\n validateDuration(res);\r\n return res;\r\n}\r\nfunction validateDuration(val) {\r\n if (typeof val !== 'number') {\r\n warn(`<transition> explicit duration is not a valid number - ` +\r\n `got ${JSON.stringify(val)}.`);\r\n }\r\n else if (isNaN(val)) {\r\n warn(`<transition> explicit duration is NaN - ` +\r\n 'the duration expression might be incorrect.');\r\n }\r\n}\r\nfunction addTransitionClass(el, cls) {\r\n cls.split(/\\s+/).forEach(c => c && el.classList.add(c));\r\n (el._vtc ||\r\n (el._vtc = new Set())).add(cls);\r\n}\r\nfunction removeTransitionClass(el, cls) {\r\n cls.split(/\\s+/).forEach(c => c && el.classList.remove(c));\r\n const { _vtc } = el;\r\n if (_vtc) {\r\n _vtc.delete(cls);\r\n if (!_vtc.size) {\r\n el._vtc = undefined;\r\n }\r\n }\r\n}\r\nfunction nextFrame(cb) {\r\n requestAnimationFrame(() => {\r\n requestAnimationFrame(cb);\r\n });\r\n}\r\nlet endId = 0;\r\nfunction whenTransitionEnds(el, expectedType, explicitTimeout, resolve) {\r\n const id = (el._endId = ++endId);\r\n const resolveIfNotStale = () => {\r\n if (id === el._endId) {\r\n resolve();\r\n }\r\n };\r\n if (explicitTimeout) {\r\n return setTimeout(resolveIfNotStale, explicitTimeout);\r\n }\r\n const { type, timeout, propCount } = getTransitionInfo(el, expectedType);\r\n if (!type) {\r\n return resolve();\r\n }\r\n const endEvent = type + 'end';\r\n let ended = 0;\r\n const end = () => {\r\n el.removeEventListener(endEvent, onEnd);\r\n resolveIfNotStale();\r\n };\r\n const onEnd = (e) => {\r\n if (e.target === el && ++ended >= propCount) {\r\n end();\r\n }\r\n };\r\n setTimeout(() => {\r\n if (ended < propCount) {\r\n end();\r\n }\r\n }, timeout + 1);\r\n el.addEventListener(endEvent, onEnd);\r\n}\r\nfunction getTransitionInfo(el, expectedType) {\r\n const styles = window.getComputedStyle(el);\r\n // JSDOM may return undefined for transition properties\r\n const getStyleProperties = (key) => (styles[key] || '').split(', ');\r\n const transitionDelays = getStyleProperties(TRANSITION + 'Delay');\r\n const transitionDurations = getStyleProperties(TRANSITION + 'Duration');\r\n const transitionTimeout = getTimeout(transitionDelays, transitionDurations);\r\n const animationDelays = getStyleProperties(ANIMATION + 'Delay');\r\n const animationDurations = getStyleProperties(ANIMATION + 'Duration');\r\n const animationTimeout = getTimeout(animationDelays, animationDurations);\r\n let type = null;\r\n let timeout = 0;\r\n let propCount = 0;\r\n /* istanbul ignore if */\r\n if (expectedType === TRANSITION) {\r\n if (transitionTimeout > 0) {\r\n type = TRANSITION;\r\n timeout = transitionTimeout;\r\n propCount = transitionDurations.length;\r\n }\r\n }\r\n else if (expectedType === ANIMATION) {\r\n if (animationTimeout > 0) {\r\n type = ANIMATION;\r\n timeout = animationTimeout;\r\n propCount = animationDurations.length;\r\n }\r\n }\r\n else {\r\n timeout = Math.max(transitionTimeout, animationTimeout);\r\n type =\r\n timeout > 0\r\n ? transitionTimeout > animationTimeout\r\n ? TRANSITION\r\n : ANIMATION\r\n : null;\r\n propCount = type\r\n ? type === TRANSITION\r\n ? transitionDurations.length\r\n : animationDurations.length\r\n : 0;\r\n }\r\n const hasTransform = type === TRANSITION &&\r\n /\\b(transform|all)(,|$)/.test(styles[TRANSITION + 'Property']);\r\n return {\r\n type,\r\n timeout,\r\n propCount,\r\n hasTransform\r\n };\r\n}\r\nfunction getTimeout(delays, durations) {\r\n while (delays.length < durations.length) {\r\n delays = delays.concat(delays);\r\n }\r\n return Math.max(...durations.map((d, i) => toMs(d) + toMs(delays[i])));\r\n}\r\n// Old versions of Chromium (below 61.0.3163.100) formats floating pointer\r\n// numbers in a locale-dependent way, using a comma instead of a dot.\r\n// If comma is not replaced with a dot, the input will be rounded down\r\n// (i.e. acting as a floor function) causing unexpected behaviors\r\nfunction toMs(s) {\r\n return Number(s.slice(0, -1).replace(',', '.')) * 1000;\r\n}\r\n// synchronously force layout to put elements into a certain state\r\nfunction forceReflow() {\r\n return document.body.offsetHeight;\r\n}\n\nconst positionMap = new WeakMap();\r\nconst newPositionMap = new WeakMap();\r\nconst TransitionGroupImpl = {\r\n name: 'TransitionGroup',\r\n props: /*#__PURE__*/ extend({}, TransitionPropsValidators, {\r\n tag: String,\r\n moveClass: String\r\n }),\r\n setup(props, { slots }) {\r\n const instance = getCurrentInstance();\r\n const state = useTransitionState();\r\n let prevChildren;\r\n let children;\r\n onUpdated(() => {\r\n // children is guaranteed to exist after initial render\r\n if (!prevChildren.length) {\r\n return;\r\n }\r\n const moveClass = props.moveClass || `${props.name || 'v'}-move`;\r\n if (!hasCSSTransform(prevChildren[0].el, instance.vnode.el, moveClass)) {\r\n return;\r\n }\r\n // we divide the work into three loops to avoid mixing DOM reads and writes\r\n // in each iteration - which helps prevent layout thrashing.\r\n prevChildren.forEach(callPendingCbs);\r\n prevChildren.forEach(recordPosition);\r\n const movedChildren = prevChildren.filter(applyTranslation);\r\n // force reflow to put everything in position\r\n forceReflow();\r\n movedChildren.forEach(c => {\r\n const el = c.el;\r\n const style = el.style;\r\n addTransitionClass(el, moveClass);\r\n style.transform = style.webkitTransform = style.transitionDuration = '';\r\n const cb = (el._moveCb = (e) => {\r\n if (e && e.target !== el) {\r\n return;\r\n }\r\n if (!e || /transform$/.test(e.propertyName)) {\r\n el.removeEventListener('transitionend', cb);\r\n el._moveCb = null;\r\n removeTransitionClass(el, moveClass);\r\n }\r\n });\r\n el.addEventListener('transitionend', cb);\r\n });\r\n });\r\n return () => {\r\n const rawProps = toRaw(props);\r\n const cssTransitionProps = resolveTransitionProps(rawProps);\r\n let tag = rawProps.tag || Fragment;\r\n prevChildren = children;\r\n children = slots.default ? getTransitionRawChildren(slots.default()) : [];\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (child.key != null) {\r\n setTransitionHooks(child, resolveTransitionHooks(child, cssTransitionProps, state, instance));\r\n }\r\n else if ((process.env.NODE_ENV !== 'production')) {\r\n warn(`<TransitionGroup> children must be keyed.`);\r\n }\r\n }\r\n if (prevChildren) {\r\n for (let i = 0; i < prevChildren.length; i++) {\r\n const child = prevChildren[i];\r\n setTransitionHooks(child, resolveTransitionHooks(child, cssTransitionProps, state, instance));\r\n positionMap.set(child, child.el.getBoundingClientRect());\r\n }\r\n }\r\n return createVNode(tag, null, children);\r\n };\r\n }\r\n};\r\nconst TransitionGroup = TransitionGroupImpl;\r\nfunction callPendingCbs(c) {\r\n const el = c.el;\r\n if (el._moveCb) {\r\n el._moveCb();\r\n }\r\n if (el._enterCb) {\r\n el._enterCb();\r\n }\r\n}\r\nfunction recordPosition(c) {\r\n newPositionMap.set(c, c.el.getBoundingClientRect());\r\n}\r\nfunction applyTranslation(c) {\r\n const oldPos = positionMap.get(c);\r\n const newPos = newPositionMap.get(c);\r\n const dx = oldPos.left - newPos.left;\r\n const dy = oldPos.top - newPos.top;\r\n if (dx || dy) {\r\n const s = c.el.style;\r\n s.transform = s.webkitTransform = `translate(${dx}px,${dy}px)`;\r\n s.transitionDuration = '0s';\r\n return c;\r\n }\r\n}\r\nfunction hasCSSTransform(el, root, moveClass) {\r\n // Detect whether an element with the move class applied has\r\n // CSS transitions. Since the element may be inside an entering\r\n // transition at this very moment, we make a clone of it and remove\r\n // all other transition classes applied to ensure only the move class\r\n // is applied.\r\n const clone = el.cloneNode();\r\n if (el._vtc) {\r\n el._vtc.forEach(cls => {\r\n cls.split(/\\s+/).forEach(c => c && clone.classList.remove(c));\r\n });\r\n }\r\n moveClass.split(/\\s+/).forEach(c => c && clone.classList.add(c));\r\n clone.style.display = 'none';\r\n const container = (root.nodeType === 1 ? root : root.parentNode);\r\n container.appendChild(clone);\r\n const { hasTransform } = getTransitionInfo(clone);\r\n container.removeChild(clone);\r\n return hasTransform;\r\n}\n\nconst getModelAssigner = (vnode) => {\r\n const fn = vnode.props['onUpdate:modelValue'];\r\n return isArray(fn) ? value => invokeArrayFns(fn, value) : fn;\r\n};\r\nfunction onCompositionStart(e) {\r\n e.target.composing = true;\r\n}\r\nfunction onCompositionEnd(e) {\r\n const target = e.target;\r\n if (target.composing) {\r\n target.composing = false;\r\n trigger(target, 'input');\r\n }\r\n}\r\nfunction trigger(el, type) {\r\n const e = document.createEvent('HTMLEvents');\r\n e.initEvent(type, true, true);\r\n el.dispatchEvent(e);\r\n}\r\n// We are exporting the v-model runtime directly as vnode hooks so that it can\r\n// be tree-shaken in case v-model is never used.\r\nconst vModelText = {\r\n created(el, { modifiers: { lazy, trim, number } }, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n const castToNumber = number || (vnode.props && vnode.props.type === 'number');\r\n addEventListener(el, lazy ? 'change' : 'input', e => {\r\n if (e.target.composing)\r\n return;\r\n let domValue = el.value;\r\n if (trim) {\r\n domValue = domValue.trim();\r\n }\r\n else if (castToNumber) {\r\n domValue = toNumber(domValue);\r\n }\r\n el._assign(domValue);\r\n });\r\n if (trim) {\r\n addEventListener(el, 'change', () => {\r\n el.value = el.value.trim();\r\n });\r\n }\r\n if (!lazy) {\r\n addEventListener(el, 'compositionstart', onCompositionStart);\r\n addEventListener(el, 'compositionend', onCompositionEnd);\r\n // Safari < 10.2 & UIWebView doesn't fire compositionend when\r\n // switching focus before confirming composition choice\r\n // this also fixes the issue where some browsers e.g. iOS Chrome\r\n // fires \"change\" instead of \"input\" on autocomplete.\r\n addEventListener(el, 'change', onCompositionEnd);\r\n }\r\n },\r\n // set value on mounted so it's after min/max for type=\"range\"\r\n mounted(el, { value }) {\r\n el.value = value == null ? '' : value;\r\n },\r\n beforeUpdate(el, { value, modifiers: { lazy, trim, number } }, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n // avoid clearing unresolved text. #2302\r\n if (el.composing)\r\n return;\r\n if (document.activeElement === el) {\r\n if (lazy) {\r\n return;\r\n }\r\n if (trim && el.value.trim() === value) {\r\n return;\r\n }\r\n if ((number || el.type === 'number') && toNumber(el.value) === value) {\r\n return;\r\n }\r\n }\r\n const newValue = value == null ? '' : value;\r\n if (el.value !== newValue) {\r\n el.value = newValue;\r\n }\r\n }\r\n};\r\nconst vModelCheckbox = {\r\n // #4096 array checkboxes need to be deep traversed\r\n deep: true,\r\n created(el, _, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n addEventListener(el, 'change', () => {\r\n const modelValue = el._modelValue;\r\n const elementValue = getValue(el);\r\n const checked = el.checked;\r\n const assign = el._assign;\r\n if (isArray(modelValue)) {\r\n const index = looseIndexOf(modelValue, elementValue);\r\n const found = index !== -1;\r\n if (checked && !found) {\r\n assign(modelValue.concat(elementValue));\r\n }\r\n else if (!checked && found) {\r\n const filtered = [...modelValue];\r\n filtered.splice(index, 1);\r\n assign(filtered);\r\n }\r\n }\r\n else if (isSet(modelValue)) {\r\n const cloned = new Set(modelValue);\r\n if (checked) {\r\n cloned.add(elementValue);\r\n }\r\n else {\r\n cloned.delete(elementValue);\r\n }\r\n assign(cloned);\r\n }\r\n else {\r\n assign(getCheckboxValue(el, checked));\r\n }\r\n });\r\n },\r\n // set initial checked on mount to wait for true-value/false-value\r\n mounted: setChecked,\r\n beforeUpdate(el, binding, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n setChecked(el, binding, vnode);\r\n }\r\n};\r\nfunction setChecked(el, { value, oldValue }, vnode) {\r\n el._modelValue = value;\r\n if (isArray(value)) {\r\n el.checked = looseIndexOf(value, vnode.props.value) > -1;\r\n }\r\n else if (isSet(value)) {\r\n el.checked = value.has(vnode.props.value);\r\n }\r\n else if (value !== oldValue) {\r\n el.checked = looseEqual(value, getCheckboxValue(el, true));\r\n }\r\n}\r\nconst vModelRadio = {\r\n created(el, { value }, vnode) {\r\n el.checked = looseEqual(value, vnode.props.value);\r\n el._assign = getModelAssigner(vnode);\r\n addEventListener(el, 'change', () => {\r\n el._assign(getValue(el));\r\n });\r\n },\r\n beforeUpdate(el, { value, oldValue }, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n if (value !== oldValue) {\r\n el.checked = looseEqual(value, vnode.props.value);\r\n }\r\n }\r\n};\r\nconst vModelSelect = {\r\n // <select multiple> value need to be deep traversed\r\n deep: true,\r\n created(el, { value, modifiers: { number } }, vnode) {\r\n const isSetModel = isSet(value);\r\n addEventListener(el, 'change', () => {\r\n const selectedVal = Array.prototype.filter\r\n .call(el.options, (o) => o.selected)\r\n .map((o) => number ? toNumber(getValue(o)) : getValue(o));\r\n el._assign(el.multiple\r\n ? isSetModel\r\n ? new Set(selectedVal)\r\n : selectedVal\r\n : selectedVal[0]);\r\n });\r\n el._assign = getModelAssigner(vnode);\r\n },\r\n // set value in mounted & updated because <select> relies on its children\r\n // <option>s.\r\n mounted(el, { value }) {\r\n setSelected(el, value);\r\n },\r\n beforeUpdate(el, _binding, vnode) {\r\n el._assign = getModelAssigner(vnode);\r\n },\r\n updated(el, { value }) {\r\n setSelected(el, value);\r\n }\r\n};\r\nfunction setSelected(el, value) {\r\n const isMultiple = el.multiple;\r\n if (isMultiple && !isArray(value) && !isSet(value)) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warn(`<select multiple v-model> expects an Array or Set value for its binding, ` +\r\n `but got ${Object.prototype.toString.call(value).slice(8, -1)}.`);\r\n return;\r\n }\r\n for (let i = 0, l = el.options.length; i < l; i++) {\r\n const option = el.options[i];\r\n const optionValue = getValue(option);\r\n if (isMultiple) {\r\n if (isArray(value)) {\r\n option.selected = looseIndexOf(value, optionValue) > -1;\r\n }\r\n else {\r\n option.selected = value.has(optionValue);\r\n }\r\n }\r\n else {\r\n if (looseEqual(getValue(option), value)) {\r\n if (el.selectedIndex !== i)\r\n el.selectedIndex = i;\r\n return;\r\n }\r\n }\r\n }\r\n if (!isMultiple && el.selectedIndex !== -1) {\r\n el.selectedIndex = -1;\r\n }\r\n}\r\n// retrieve raw value set via :value bindings\r\nfunction getValue(el) {\r\n return '_value' in el ? el._value : el.value;\r\n}\r\n// retrieve raw value for true-value and false-value set via :true-value or :false-value bindings\r\nfunction getCheckboxValue(el, checked) {\r\n const key = checked ? '_trueValue' : '_falseValue';\r\n return key in el ? el[key] : checked;\r\n}\r\nconst vModelDynamic = {\r\n created(el, binding, vnode) {\r\n callModelHook(el, binding, vnode, null, 'created');\r\n },\r\n mounted(el, binding, vnode) {\r\n callModelHook(el, binding, vnode, null, 'mounted');\r\n },\r\n beforeUpdate(el, binding, vnode, prevVNode) {\r\n callModelHook(el, binding, vnode, prevVNode, 'beforeUpdate');\r\n },\r\n updated(el, binding, vnode, prevVNode) {\r\n callModelHook(el, binding, vnode, prevVNode, 'updated');\r\n }\r\n};\r\nfunction callModelHook(el, binding, vnode, prevVNode, hook) {\r\n let modelToUse;\r\n switch (el.tagName) {\r\n case 'SELECT':\r\n modelToUse = vModelSelect;\r\n break;\r\n case 'TEXTAREA':\r\n modelToUse = vModelText;\r\n break;\r\n default:\r\n switch (vnode.props && vnode.props.type) {\r\n case 'checkbox':\r\n modelToUse = vModelCheckbox;\r\n break;\r\n case 'radio':\r\n modelToUse = vModelRadio;\r\n break;\r\n default:\r\n modelToUse = vModelText;\r\n }\r\n }\r\n const fn = modelToUse[hook];\r\n fn && fn(el, binding, vnode, prevVNode);\r\n}\r\n// SSR vnode transforms, only used when user includes client-oriented render\r\n// function in SSR\r\nfunction initVModelForSSR() {\r\n vModelText.getSSRProps = ({ value }) => ({ value });\r\n vModelRadio.getSSRProps = ({ value }, vnode) => {\r\n if (vnode.props && looseEqual(vnode.props.value, value)) {\r\n return { checked: true };\r\n }\r\n };\r\n vModelCheckbox.getSSRProps = ({ value }, vnode) => {\r\n if (isArray(value)) {\r\n if (vnode.props && looseIndexOf(value, vnode.props.value) > -1) {\r\n return { checked: true };\r\n }\r\n }\r\n else if (isSet(value)) {\r\n if (vnode.props && value.has(vnode.props.value)) {\r\n return { checked: true };\r\n }\r\n }\r\n else if (value) {\r\n return { checked: true };\r\n }\r\n };\r\n}\n\nconst systemModifiers = ['ctrl', 'shift', 'alt', 'meta'];\r\nconst modifierGuards = {\r\n stop: e => e.stopPropagation(),\r\n prevent: e => e.preventDefault(),\r\n self: e => e.target !== e.currentTarget,\r\n ctrl: e => !e.ctrlKey,\r\n shift: e => !e.shiftKey,\r\n alt: e => !e.altKey,\r\n meta: e => !e.metaKey,\r\n left: e => 'button' in e && e.button !== 0,\r\n middle: e => 'button' in e && e.button !== 1,\r\n right: e => 'button' in e && e.button !== 2,\r\n exact: (e, modifiers) => systemModifiers.some(m => e[`${m}Key`] && !modifiers.includes(m))\r\n};\r\n/**\r\n * @private\r\n */\r\nconst withModifiers = (fn, modifiers) => {\r\n return (event, ...args) => {\r\n for (let i = 0; i < modifiers.length; i++) {\r\n const guard = modifierGuards[modifiers[i]];\r\n if (guard && guard(event, modifiers))\r\n return;\r\n }\r\n return fn(event, ...args);\r\n };\r\n};\r\n// Kept for 2.x compat.\r\n// Note: IE11 compat for `spacebar` and `del` is removed for now.\r\nconst keyNames = {\r\n esc: 'escape',\r\n space: ' ',\r\n up: 'arrow-up',\r\n left: 'arrow-left',\r\n right: 'arrow-right',\r\n down: 'arrow-down',\r\n delete: 'backspace'\r\n};\r\n/**\r\n * @private\r\n */\r\nconst withKeys = (fn, modifiers) => {\r\n return (event) => {\r\n if (!('key' in event)) {\r\n return;\r\n }\r\n const eventKey = hyphenate(event.key);\r\n if (modifiers.some(k => k === eventKey || keyNames[k] === eventKey)) {\r\n return fn(event);\r\n }\r\n };\r\n};\n\nconst vShow = {\r\n beforeMount(el, { value }, { transition }) {\r\n el._vod = el.style.display === 'none' ? '' : el.style.display;\r\n if (transition && value) {\r\n transition.beforeEnter(el);\r\n }\r\n else {\r\n setDisplay(el, value);\r\n }\r\n },\r\n mounted(el, { value }, { transition }) {\r\n if (transition && value) {\r\n transition.enter(el);\r\n }\r\n },\r\n updated(el, { value, oldValue }, { transition }) {\r\n if (!value === !oldValue)\r\n return;\r\n if (transition) {\r\n if (value) {\r\n transition.beforeEnter(el);\r\n setDisplay(el, true);\r\n transition.enter(el);\r\n }\r\n else {\r\n transition.leave(el, () => {\r\n setDisplay(el, false);\r\n });\r\n }\r\n }\r\n else {\r\n setDisplay(el, value);\r\n }\r\n },\r\n beforeUnmount(el, { value }) {\r\n setDisplay(el, value);\r\n }\r\n};\r\nfunction setDisplay(el, value) {\r\n el.style.display = value ? el._vod : 'none';\r\n}\r\n// SSR vnode transforms, only used when user includes client-oriented render\r\n// function in SSR\r\nfunction initVShowForSSR() {\r\n vShow.getSSRProps = ({ value }) => {\r\n if (!value) {\r\n return { style: { display: 'none' } };\r\n }\r\n };\r\n}\n\nconst rendererOptions = extend({ patchProp }, nodeOps);\r\n// lazy create the renderer - this makes core renderer logic tree-shakable\r\n// in case the user only imports reactivity utilities from Vue.\r\nlet renderer;\r\nlet enabledHydration = false;\r\nfunction ensureRenderer() {\r\n return (renderer ||\r\n (renderer = createRenderer(rendererOptions)));\r\n}\r\nfunction ensureHydrationRenderer() {\r\n renderer = enabledHydration\r\n ? renderer\r\n : createHydrationRenderer(rendererOptions);\r\n enabledHydration = true;\r\n return renderer;\r\n}\r\n// use explicit type casts here to avoid import() calls in rolled-up d.ts\r\nconst render = ((...args) => {\r\n ensureRenderer().render(...args);\r\n});\r\nconst hydrate = ((...args) => {\r\n ensureHydrationRenderer().hydrate(...args);\r\n});\r\nconst createApp = ((...args) => {\r\n const app = ensureRenderer().createApp(...args);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n injectNativeTagCheck(app);\r\n injectCompilerOptionsCheck(app);\r\n }\r\n const { mount } = app;\r\n app.mount = (containerOrSelector) => {\r\n const container = normalizeContainer(containerOrSelector);\r\n if (!container)\r\n return;\r\n const component = app._component;\r\n if (!isFunction(component) && !component.render && !component.template) {\r\n // __UNSAFE__\r\n // Reason: potential execution of JS expressions in in-DOM template.\r\n // The user must make sure the in-DOM template is trusted. If it's\r\n // rendered by the server, the template should not contain any user data.\r\n component.template = container.innerHTML;\r\n }\r\n // clear content before mounting\r\n container.innerHTML = '';\r\n const proxy = mount(container, false, container instanceof SVGElement);\r\n if (container instanceof Element) {\r\n container.removeAttribute('v-cloak');\r\n container.setAttribute('data-v-app', '');\r\n }\r\n return proxy;\r\n };\r\n return app;\r\n});\r\nconst createSSRApp = ((...args) => {\r\n const app = ensureHydrationRenderer().createApp(...args);\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n injectNativeTagCheck(app);\r\n injectCompilerOptionsCheck(app);\r\n }\r\n const { mount } = app;\r\n app.mount = (containerOrSelector) => {\r\n const container = normalizeContainer(containerOrSelector);\r\n if (container) {\r\n return mount(container, true, container instanceof SVGElement);\r\n }\r\n };\r\n return app;\r\n});\r\nfunction injectNativeTagCheck(app) {\r\n // Inject `isNativeTag`\r\n // this is used for component name validation (dev only)\r\n Object.defineProperty(app.config, 'isNativeTag', {\r\n value: (tag) => isHTMLTag(tag) || isSVGTag(tag),\r\n writable: false\r\n });\r\n}\r\n// dev only\r\nfunction injectCompilerOptionsCheck(app) {\r\n if (isRuntimeOnly()) {\r\n const isCustomElement = app.config.isCustomElement;\r\n Object.defineProperty(app.config, 'isCustomElement', {\r\n get() {\r\n return isCustomElement;\r\n },\r\n set() {\r\n warn(`The \\`isCustomElement\\` config option is deprecated. Use ` +\r\n `\\`compilerOptions.isCustomElement\\` instead.`);\r\n }\r\n });\r\n const compilerOptions = app.config.compilerOptions;\r\n const msg = `The \\`compilerOptions\\` config option is only respected when using ` +\r\n `a build of Vue.js that includes the runtime compiler (aka \"full build\"). ` +\r\n `Since you are using the runtime-only build, \\`compilerOptions\\` ` +\r\n `must be passed to \\`@vue/compiler-dom\\` in the build setup instead.\\n` +\r\n `- For vue-loader: pass it via vue-loader's \\`compilerOptions\\` loader option.\\n` +\r\n `- For vue-cli: see https://cli.vuejs.org/guide/webpack.html#modifying-options-of-a-loader\\n` +\r\n `- For vite: pass it via @vitejs/plugin-vue options. See https://github.com/vitejs/vite/tree/main/packages/plugin-vue#example-for-passing-options-to-vuecompiler-dom`;\r\n Object.defineProperty(app.config, 'compilerOptions', {\r\n get() {\r\n warn(msg);\r\n return compilerOptions;\r\n },\r\n set() {\r\n warn(msg);\r\n }\r\n });\r\n }\r\n}\r\nfunction normalizeContainer(container) {\r\n if (isString(container)) {\r\n const res = document.querySelector(container);\r\n if ((process.env.NODE_ENV !== 'production') && !res) {\r\n warn(`Failed to mount app: mount target selector \"${container}\" returned null.`);\r\n }\r\n return res;\r\n }\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n window.ShadowRoot &&\r\n container instanceof window.ShadowRoot &&\r\n container.mode === 'closed') {\r\n warn(`mounting on a ShadowRoot with \\`{mode: \"closed\"}\\` may lead to unpredictable bugs`);\r\n }\r\n return container;\r\n}\r\nlet ssrDirectiveInitialized = false;\r\n/**\r\n * @internal\r\n */\r\nconst initDirectivesForSSR = () => {\r\n if (!ssrDirectiveInitialized) {\r\n ssrDirectiveInitialized = true;\r\n initVModelForSSR();\r\n initVShowForSSR();\r\n }\r\n }\r\n ;\n\nexport { Transition, TransitionGroup, VueElement, createApp, createSSRApp, defineCustomElement, defineSSRCustomElement, hydrate, initDirectivesForSSR, render, useCssModule, useCssVars, vModelCheckbox, vModelDynamic, vModelRadio, vModelSelect, vModelText, vShow, withKeys, withModifiers };\n","import { isString, hyphenate, NOOP, extend, isObject, NO, isArray, makeMap, isSymbol, EMPTY_OBJ, capitalize, camelize as camelize$1, PatchFlagNames, slotFlagsText, isOn, isReservedProp, toHandlerKey } from '@vue/shared';\nexport { generateCodeFrame } from '@vue/shared';\n\nfunction defaultOnError(error) {\r\n throw error;\r\n}\r\nfunction defaultOnWarn(msg) {\r\n (process.env.NODE_ENV !== 'production') && console.warn(`[Vue warn] ${msg.message}`);\r\n}\r\nfunction createCompilerError(code, loc, messages, additionalMessage) {\r\n const msg = (process.env.NODE_ENV !== 'production') || !true\r\n ? (messages || errorMessages)[code] + (additionalMessage || ``)\r\n : code;\r\n const error = new SyntaxError(String(msg));\r\n error.code = code;\r\n error.loc = loc;\r\n return error;\r\n}\r\nconst errorMessages = {\r\n // parse errors\r\n [0 /* ABRUPT_CLOSING_OF_EMPTY_COMMENT */]: 'Illegal comment.',\r\n [1 /* CDATA_IN_HTML_CONTENT */]: 'CDATA section is allowed only in XML context.',\r\n [2 /* DUPLICATE_ATTRIBUTE */]: 'Duplicate attribute.',\r\n [3 /* END_TAG_WITH_ATTRIBUTES */]: 'End tag cannot have attributes.',\r\n [4 /* END_TAG_WITH_TRAILING_SOLIDUS */]: \"Illegal '/' in tags.\",\r\n [5 /* EOF_BEFORE_TAG_NAME */]: 'Unexpected EOF in tag.',\r\n [6 /* EOF_IN_CDATA */]: 'Unexpected EOF in CDATA section.',\r\n [7 /* EOF_IN_COMMENT */]: 'Unexpected EOF in comment.',\r\n [8 /* EOF_IN_SCRIPT_HTML_COMMENT_LIKE_TEXT */]: 'Unexpected EOF in script.',\r\n [9 /* EOF_IN_TAG */]: 'Unexpected EOF in tag.',\r\n [10 /* INCORRECTLY_CLOSED_COMMENT */]: 'Incorrectly closed comment.',\r\n [11 /* INCORRECTLY_OPENED_COMMENT */]: 'Incorrectly opened comment.',\r\n [12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */]: \"Illegal tag name. Use '&lt;' to print '<'.\",\r\n [13 /* MISSING_ATTRIBUTE_VALUE */]: 'Attribute value was expected.',\r\n [14 /* MISSING_END_TAG_NAME */]: 'End tag name was expected.',\r\n [15 /* MISSING_WHITESPACE_BETWEEN_ATTRIBUTES */]: 'Whitespace was expected.',\r\n [16 /* NESTED_COMMENT */]: \"Unexpected '<!--' in comment.\",\r\n [17 /* UNEXPECTED_CHARACTER_IN_ATTRIBUTE_NAME */]: 'Attribute name cannot contain U+0022 (\"), U+0027 (\\'), and U+003C (<).',\r\n [18 /* UNEXPECTED_CHARACTER_IN_UNQUOTED_ATTRIBUTE_VALUE */]: 'Unquoted attribute value cannot contain U+0022 (\"), U+0027 (\\'), U+003C (<), U+003D (=), and U+0060 (`).',\r\n [19 /* UNEXPECTED_EQUALS_SIGN_BEFORE_ATTRIBUTE_NAME */]: \"Attribute name cannot start with '='.\",\r\n [21 /* UNEXPECTED_QUESTION_MARK_INSTEAD_OF_TAG_NAME */]: \"'<?' is allowed only in XML context.\",\r\n [20 /* UNEXPECTED_NULL_CHARACTER */]: `Unexpected null character.`,\r\n [22 /* UNEXPECTED_SOLIDUS_IN_TAG */]: \"Illegal '/' in tags.\",\r\n // Vue-specific parse errors\r\n [23 /* X_INVALID_END_TAG */]: 'Invalid end tag.',\r\n [24 /* X_MISSING_END_TAG */]: 'Element is missing end tag.',\r\n [25 /* X_MISSING_INTERPOLATION_END */]: 'Interpolation end sign was not found.',\r\n [27 /* X_MISSING_DYNAMIC_DIRECTIVE_ARGUMENT_END */]: 'End bracket for dynamic directive argument was not found. ' +\r\n 'Note that dynamic directive argument cannot contain spaces.',\r\n [26 /* X_MISSING_DIRECTIVE_NAME */]: 'Legal directive name was expected.',\r\n // transform errors\r\n [28 /* X_V_IF_NO_EXPRESSION */]: `v-if/v-else-if is missing expression.`,\r\n [29 /* X_V_IF_SAME_KEY */]: `v-if/else branches must use unique keys.`,\r\n [30 /* X_V_ELSE_NO_ADJACENT_IF */]: `v-else/v-else-if has no adjacent v-if or v-else-if.`,\r\n [31 /* X_V_FOR_NO_EXPRESSION */]: `v-for is missing expression.`,\r\n [32 /* X_V_FOR_MALFORMED_EXPRESSION */]: `v-for has invalid expression.`,\r\n [33 /* X_V_FOR_TEMPLATE_KEY_PLACEMENT */]: `<template v-for> key should be placed on the <template> tag.`,\r\n [34 /* X_V_BIND_NO_EXPRESSION */]: `v-bind is missing expression.`,\r\n [35 /* X_V_ON_NO_EXPRESSION */]: `v-on is missing expression.`,\r\n [36 /* X_V_SLOT_UNEXPECTED_DIRECTIVE_ON_SLOT_OUTLET */]: `Unexpected custom directive on <slot> outlet.`,\r\n [37 /* X_V_SLOT_MIXED_SLOT_USAGE */]: `Mixed v-slot usage on both the component and nested <template>.` +\r\n `When there are multiple named slots, all slots should use <template> ` +\r\n `syntax to avoid scope ambiguity.`,\r\n [38 /* X_V_SLOT_DUPLICATE_SLOT_NAMES */]: `Duplicate slot names found. `,\r\n [39 /* X_V_SLOT_EXTRANEOUS_DEFAULT_SLOT_CHILDREN */]: `Extraneous children found when component already has explicitly named ` +\r\n `default slot. These children will be ignored.`,\r\n [40 /* X_V_SLOT_MISPLACED */]: `v-slot can only be used on components or <template> tags.`,\r\n [41 /* X_V_MODEL_NO_EXPRESSION */]: `v-model is missing expression.`,\r\n [42 /* X_V_MODEL_MALFORMED_EXPRESSION */]: `v-model value must be a valid JavaScript member expression.`,\r\n [43 /* X_V_MODEL_ON_SCOPE_VARIABLE */]: `v-model cannot be used on v-for or v-slot scope variables because they are not writable.`,\r\n [44 /* X_INVALID_EXPRESSION */]: `Error parsing JavaScript expression: `,\r\n [45 /* X_KEEP_ALIVE_INVALID_CHILDREN */]: `<KeepAlive> expects exactly one child component.`,\r\n // generic errors\r\n [46 /* X_PREFIX_ID_NOT_SUPPORTED */]: `\"prefixIdentifiers\" option is not supported in this build of compiler.`,\r\n [47 /* X_MODULE_MODE_NOT_SUPPORTED */]: `ES module mode is not supported in this build of compiler.`,\r\n [48 /* X_CACHE_HANDLER_NOT_SUPPORTED */]: `\"cacheHandlers\" option is only supported when the \"prefixIdentifiers\" option is enabled.`,\r\n [49 /* X_SCOPE_ID_NOT_SUPPORTED */]: `\"scopeId\" option is only supported in module mode.`,\r\n // just to fulfill types\r\n [50 /* __EXTEND_POINT__ */]: ``\r\n};\n\nconst FRAGMENT = Symbol((process.env.NODE_ENV !== 'production') ? `Fragment` : ``);\r\nconst TELEPORT = Symbol((process.env.NODE_ENV !== 'production') ? `Teleport` : ``);\r\nconst SUSPENSE = Symbol((process.env.NODE_ENV !== 'production') ? `Suspense` : ``);\r\nconst KEEP_ALIVE = Symbol((process.env.NODE_ENV !== 'production') ? `KeepAlive` : ``);\r\nconst BASE_TRANSITION = Symbol((process.env.NODE_ENV !== 'production') ? `BaseTransition` : ``);\r\nconst OPEN_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `openBlock` : ``);\r\nconst CREATE_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `createBlock` : ``);\r\nconst CREATE_ELEMENT_BLOCK = Symbol((process.env.NODE_ENV !== 'production') ? `createElementBlock` : ``);\r\nconst CREATE_VNODE = Symbol((process.env.NODE_ENV !== 'production') ? `createVNode` : ``);\r\nconst CREATE_ELEMENT_VNODE = Symbol((process.env.NODE_ENV !== 'production') ? `createElementVNode` : ``);\r\nconst CREATE_COMMENT = Symbol((process.env.NODE_ENV !== 'production') ? `createCommentVNode` : ``);\r\nconst CREATE_TEXT = Symbol((process.env.NODE_ENV !== 'production') ? `createTextVNode` : ``);\r\nconst CREATE_STATIC = Symbol((process.env.NODE_ENV !== 'production') ? `createStaticVNode` : ``);\r\nconst RESOLVE_COMPONENT = Symbol((process.env.NODE_ENV !== 'production') ? `resolveComponent` : ``);\r\nconst RESOLVE_DYNAMIC_COMPONENT = Symbol((process.env.NODE_ENV !== 'production') ? `resolveDynamicComponent` : ``);\r\nconst RESOLVE_DIRECTIVE = Symbol((process.env.NODE_ENV !== 'production') ? `resolveDirective` : ``);\r\nconst RESOLVE_FILTER = Symbol((process.env.NODE_ENV !== 'production') ? `resolveFilter` : ``);\r\nconst WITH_DIRECTIVES = Symbol((process.env.NODE_ENV !== 'production') ? `withDirectives` : ``);\r\nconst RENDER_LIST = Symbol((process.env.NODE_ENV !== 'production') ? `renderList` : ``);\r\nconst RENDER_SLOT = Symbol((process.env.NODE_ENV !== 'production') ? `renderSlot` : ``);\r\nconst CREATE_SLOTS = Symbol((process.env.NODE_ENV !== 'production') ? `createSlots` : ``);\r\nconst TO_DISPLAY_STRING = Symbol((process.env.NODE_ENV !== 'production') ? `toDisplayString` : ``);\r\nconst MERGE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `mergeProps` : ``);\r\nconst NORMALIZE_CLASS = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeClass` : ``);\r\nconst NORMALIZE_STYLE = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeStyle` : ``);\r\nconst NORMALIZE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `normalizeProps` : ``);\r\nconst GUARD_REACTIVE_PROPS = Symbol((process.env.NODE_ENV !== 'production') ? `guardReactiveProps` : ``);\r\nconst TO_HANDLERS = Symbol((process.env.NODE_ENV !== 'production') ? `toHandlers` : ``);\r\nconst CAMELIZE = Symbol((process.env.NODE_ENV !== 'production') ? `camelize` : ``);\r\nconst CAPITALIZE = Symbol((process.env.NODE_ENV !== 'production') ? `capitalize` : ``);\r\nconst TO_HANDLER_KEY = Symbol((process.env.NODE_ENV !== 'production') ? `toHandlerKey` : ``);\r\nconst SET_BLOCK_TRACKING = Symbol((process.env.NODE_ENV !== 'production') ? `setBlockTracking` : ``);\r\nconst PUSH_SCOPE_ID = Symbol((process.env.NODE_ENV !== 'production') ? `pushScopeId` : ``);\r\nconst POP_SCOPE_ID = Symbol((process.env.NODE_ENV !== 'production') ? `popScopeId` : ``);\r\nconst WITH_CTX = Symbol((process.env.NODE_ENV !== 'production') ? `withCtx` : ``);\r\nconst UNREF = Symbol((process.env.NODE_ENV !== 'production') ? `unref` : ``);\r\nconst IS_REF = Symbol((process.env.NODE_ENV !== 'production') ? `isRef` : ``);\r\nconst WITH_MEMO = Symbol((process.env.NODE_ENV !== 'production') ? `withMemo` : ``);\r\nconst IS_MEMO_SAME = Symbol((process.env.NODE_ENV !== 'production') ? `isMemoSame` : ``);\r\n// Name mapping for runtime helpers that need to be imported from 'vue' in\r\n// generated code. Make sure these are correctly exported in the runtime!\r\n// Using `any` here because TS doesn't allow symbols as index type.\r\nconst helperNameMap = {\r\n [FRAGMENT]: `Fragment`,\r\n [TELEPORT]: `Teleport`,\r\n [SUSPENSE]: `Suspense`,\r\n [KEEP_ALIVE]: `KeepAlive`,\r\n [BASE_TRANSITION]: `BaseTransition`,\r\n [OPEN_BLOCK]: `openBlock`,\r\n [CREATE_BLOCK]: `createBlock`,\r\n [CREATE_ELEMENT_BLOCK]: `createElementBlock`,\r\n [CREATE_VNODE]: `createVNode`,\r\n [CREATE_ELEMENT_VNODE]: `createElementVNode`,\r\n [CREATE_COMMENT]: `createCommentVNode`,\r\n [CREATE_TEXT]: `createTextVNode`,\r\n [CREATE_STATIC]: `createStaticVNode`,\r\n [RESOLVE_COMPONENT]: `resolveComponent`,\r\n [RESOLVE_DYNAMIC_COMPONENT]: `resolveDynamicComponent`,\r\n [RESOLVE_DIRECTIVE]: `resolveDirective`,\r\n [RESOLVE_FILTER]: `resolveFilter`,\r\n [WITH_DIRECTIVES]: `withDirectives`,\r\n [RENDER_LIST]: `renderList`,\r\n [RENDER_SLOT]: `renderSlot`,\r\n [CREATE_SLOTS]: `createSlots`,\r\n [TO_DISPLAY_STRING]: `toDisplayString`,\r\n [MERGE_PROPS]: `mergeProps`,\r\n [NORMALIZE_CLASS]: `normalizeClass`,\r\n [NORMALIZE_STYLE]: `normalizeStyle`,\r\n [NORMALIZE_PROPS]: `normalizeProps`,\r\n [GUARD_REACTIVE_PROPS]: `guardReactiveProps`,\r\n [TO_HANDLERS]: `toHandlers`,\r\n [CAMELIZE]: `camelize`,\r\n [CAPITALIZE]: `capitalize`,\r\n [TO_HANDLER_KEY]: `toHandlerKey`,\r\n [SET_BLOCK_TRACKING]: `setBlockTracking`,\r\n [PUSH_SCOPE_ID]: `pushScopeId`,\r\n [POP_SCOPE_ID]: `popScopeId`,\r\n [WITH_CTX]: `withCtx`,\r\n [UNREF]: `unref`,\r\n [IS_REF]: `isRef`,\r\n [WITH_MEMO]: `withMemo`,\r\n [IS_MEMO_SAME]: `isMemoSame`\r\n};\r\nfunction registerRuntimeHelpers(helpers) {\r\n Object.getOwnPropertySymbols(helpers).forEach(s => {\r\n helperNameMap[s] = helpers[s];\r\n });\r\n}\n\n// AST Utilities ---------------------------------------------------------------\r\n// Some expressions, e.g. sequence and conditional expressions, are never\r\n// associated with template nodes, so their source locations are just a stub.\r\n// Container types like CompoundExpression also don't need a real location.\r\nconst locStub = {\r\n source: '',\r\n start: { line: 1, column: 1, offset: 0 },\r\n end: { line: 1, column: 1, offset: 0 }\r\n};\r\nfunction createRoot(children, loc = locStub) {\r\n return {\r\n type: 0 /* ROOT */,\r\n children,\r\n helpers: [],\r\n components: [],\r\n directives: [],\r\n hoists: [],\r\n imports: [],\r\n cached: 0,\r\n temps: 0,\r\n codegenNode: undefined,\r\n loc\r\n };\r\n}\r\nfunction createVNodeCall(context, tag, props, children, patchFlag, dynamicProps, directives, isBlock = false, disableTracking = false, isComponent = false, loc = locStub) {\r\n if (context) {\r\n if (isBlock) {\r\n context.helper(OPEN_BLOCK);\r\n context.helper(getVNodeBlockHelper(context.inSSR, isComponent));\r\n }\r\n else {\r\n context.helper(getVNodeHelper(context.inSSR, isComponent));\r\n }\r\n if (directives) {\r\n context.helper(WITH_DIRECTIVES);\r\n }\r\n }\r\n return {\r\n type: 13 /* VNODE_CALL */,\r\n tag,\r\n props,\r\n children,\r\n patchFlag,\r\n dynamicProps,\r\n directives,\r\n isBlock,\r\n disableTracking,\r\n isComponent,\r\n loc\r\n };\r\n}\r\nfunction createArrayExpression(elements, loc = locStub) {\r\n return {\r\n type: 17 /* JS_ARRAY_EXPRESSION */,\r\n loc,\r\n elements\r\n };\r\n}\r\nfunction createObjectExpression(properties, loc = locStub) {\r\n return {\r\n type: 15 /* JS_OBJECT_EXPRESSION */,\r\n loc,\r\n properties\r\n };\r\n}\r\nfunction createObjectProperty(key, value) {\r\n return {\r\n type: 16 /* JS_PROPERTY */,\r\n loc: locStub,\r\n key: isString(key) ? createSimpleExpression(key, true) : key,\r\n value\r\n };\r\n}\r\nfunction createSimpleExpression(content, isStatic = false, loc = locStub, constType = 0 /* NOT_CONSTANT */) {\r\n return {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n loc,\r\n content,\r\n isStatic,\r\n constType: isStatic ? 3 /* CAN_STRINGIFY */ : constType\r\n };\r\n}\r\nfunction createInterpolation(content, loc) {\r\n return {\r\n type: 5 /* INTERPOLATION */,\r\n loc,\r\n content: isString(content)\r\n ? createSimpleExpression(content, false, loc)\r\n : content\r\n };\r\n}\r\nfunction createCompoundExpression(children, loc = locStub) {\r\n return {\r\n type: 8 /* COMPOUND_EXPRESSION */,\r\n loc,\r\n children\r\n };\r\n}\r\nfunction createCallExpression(callee, args = [], loc = locStub) {\r\n return {\r\n type: 14 /* JS_CALL_EXPRESSION */,\r\n loc,\r\n callee,\r\n arguments: args\r\n };\r\n}\r\nfunction createFunctionExpression(params, returns = undefined, newline = false, isSlot = false, loc = locStub) {\r\n return {\r\n type: 18 /* JS_FUNCTION_EXPRESSION */,\r\n params,\r\n returns,\r\n newline,\r\n isSlot,\r\n loc\r\n };\r\n}\r\nfunction createConditionalExpression(test, consequent, alternate, newline = true) {\r\n return {\r\n type: 19 /* JS_CONDITIONAL_EXPRESSION */,\r\n test,\r\n consequent,\r\n alternate,\r\n newline,\r\n loc: locStub\r\n };\r\n}\r\nfunction createCacheExpression(index, value, isVNode = false) {\r\n return {\r\n type: 20 /* JS_CACHE_EXPRESSION */,\r\n index,\r\n value,\r\n isVNode,\r\n loc: locStub\r\n };\r\n}\r\nfunction createBlockStatement(body) {\r\n return {\r\n type: 21 /* JS_BLOCK_STATEMENT */,\r\n body,\r\n loc: locStub\r\n };\r\n}\r\nfunction createTemplateLiteral(elements) {\r\n return {\r\n type: 22 /* JS_TEMPLATE_LITERAL */,\r\n elements,\r\n loc: locStub\r\n };\r\n}\r\nfunction createIfStatement(test, consequent, alternate) {\r\n return {\r\n type: 23 /* JS_IF_STATEMENT */,\r\n test,\r\n consequent,\r\n alternate,\r\n loc: locStub\r\n };\r\n}\r\nfunction createAssignmentExpression(left, right) {\r\n return {\r\n type: 24 /* JS_ASSIGNMENT_EXPRESSION */,\r\n left,\r\n right,\r\n loc: locStub\r\n };\r\n}\r\nfunction createSequenceExpression(expressions) {\r\n return {\r\n type: 25 /* JS_SEQUENCE_EXPRESSION */,\r\n expressions,\r\n loc: locStub\r\n };\r\n}\r\nfunction createReturnStatement(returns) {\r\n return {\r\n type: 26 /* JS_RETURN_STATEMENT */,\r\n returns,\r\n loc: locStub\r\n };\r\n}\n\nconst isStaticExp = (p) => p.type === 4 /* SIMPLE_EXPRESSION */ && p.isStatic;\r\nconst isBuiltInType = (tag, expected) => tag === expected || tag === hyphenate(expected);\r\nfunction isCoreComponent(tag) {\r\n if (isBuiltInType(tag, 'Teleport')) {\r\n return TELEPORT;\r\n }\r\n else if (isBuiltInType(tag, 'Suspense')) {\r\n return SUSPENSE;\r\n }\r\n else if (isBuiltInType(tag, 'KeepAlive')) {\r\n return KEEP_ALIVE;\r\n }\r\n else if (isBuiltInType(tag, 'BaseTransition')) {\r\n return BASE_TRANSITION;\r\n }\r\n}\r\nconst nonIdentifierRE = /^\\d|[^\\$\\w]/;\r\nconst isSimpleIdentifier = (name) => !nonIdentifierRE.test(name);\r\nconst validFirstIdentCharRE = /[A-Za-z_$\\xA0-\\uFFFF]/;\r\nconst validIdentCharRE = /[\\.\\?\\w$\\xA0-\\uFFFF]/;\r\nconst whitespaceRE = /\\s+[.[]\\s*|\\s*[.[]\\s+/g;\r\n/**\r\n * Simple lexer to check if an expression is a member expression. This is\r\n * lax and only checks validity at the root level (i.e. does not validate exps\r\n * inside square brackets), but it's ok since these are only used on template\r\n * expressions and false positives are invalid expressions in the first place.\r\n */\r\nconst isMemberExpressionBrowser = (path) => {\r\n // remove whitespaces around . or [ first\r\n path = path.trim().replace(whitespaceRE, s => s.trim());\r\n let state = 0 /* inMemberExp */;\r\n let stateStack = [];\r\n let currentOpenBracketCount = 0;\r\n let currentOpenParensCount = 0;\r\n let currentStringType = null;\r\n for (let i = 0; i < path.length; i++) {\r\n const char = path.charAt(i);\r\n switch (state) {\r\n case 0 /* inMemberExp */:\r\n if (char === '[') {\r\n stateStack.push(state);\r\n state = 1 /* inBrackets */;\r\n currentOpenBracketCount++;\r\n }\r\n else if (char === '(') {\r\n stateStack.push(state);\r\n state = 2 /* inParens */;\r\n currentOpenParensCount++;\r\n }\r\n else if (!(i === 0 ? validFirstIdentCharRE : validIdentCharRE).test(char)) {\r\n return false;\r\n }\r\n break;\r\n case 1 /* inBrackets */:\r\n if (char === `'` || char === `\"` || char === '`') {\r\n stateStack.push(state);\r\n state = 3 /* inString */;\r\n currentStringType = char;\r\n }\r\n else if (char === `[`) {\r\n currentOpenBracketCount++;\r\n }\r\n else if (char === `]`) {\r\n if (!--currentOpenBracketCount) {\r\n state = stateStack.pop();\r\n }\r\n }\r\n break;\r\n case 2 /* inParens */:\r\n if (char === `'` || char === `\"` || char === '`') {\r\n stateStack.push(state);\r\n state = 3 /* inString */;\r\n currentStringType = char;\r\n }\r\n else if (char === `(`) {\r\n currentOpenParensCount++;\r\n }\r\n else if (char === `)`) {\r\n // if the exp ends as a call then it should not be considered valid\r\n if (i === path.length - 1) {\r\n return false;\r\n }\r\n if (!--currentOpenParensCount) {\r\n state = stateStack.pop();\r\n }\r\n }\r\n break;\r\n case 3 /* inString */:\r\n if (char === currentStringType) {\r\n state = stateStack.pop();\r\n currentStringType = null;\r\n }\r\n break;\r\n }\r\n }\r\n return !currentOpenBracketCount && !currentOpenParensCount;\r\n};\r\nconst isMemberExpressionNode = NOOP\r\n ;\r\nconst isMemberExpression = isMemberExpressionBrowser\r\n ;\r\nfunction getInnerRange(loc, offset, length) {\r\n const source = loc.source.slice(offset, offset + length);\r\n const newLoc = {\r\n source,\r\n start: advancePositionWithClone(loc.start, loc.source, offset),\r\n end: loc.end\r\n };\r\n if (length != null) {\r\n newLoc.end = advancePositionWithClone(loc.start, loc.source, offset + length);\r\n }\r\n return newLoc;\r\n}\r\nfunction advancePositionWithClone(pos, source, numberOfCharacters = source.length) {\r\n return advancePositionWithMutation(extend({}, pos), source, numberOfCharacters);\r\n}\r\n// advance by mutation without cloning (for performance reasons), since this\r\n// gets called a lot in the parser\r\nfunction advancePositionWithMutation(pos, source, numberOfCharacters = source.length) {\r\n let linesCount = 0;\r\n let lastNewLinePos = -1;\r\n for (let i = 0; i < numberOfCharacters; i++) {\r\n if (source.charCodeAt(i) === 10 /* newline char code */) {\r\n linesCount++;\r\n lastNewLinePos = i;\r\n }\r\n }\r\n pos.offset += numberOfCharacters;\r\n pos.line += linesCount;\r\n pos.column =\r\n lastNewLinePos === -1\r\n ? pos.column + numberOfCharacters\r\n : numberOfCharacters - lastNewLinePos;\r\n return pos;\r\n}\r\nfunction assert(condition, msg) {\r\n /* istanbul ignore if */\r\n if (!condition) {\r\n throw new Error(msg || `unexpected compiler condition`);\r\n }\r\n}\r\nfunction findDir(node, name, allowEmpty = false) {\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 7 /* DIRECTIVE */ &&\r\n (allowEmpty || p.exp) &&\r\n (isString(name) ? p.name === name : name.test(p.name))) {\r\n return p;\r\n }\r\n }\r\n}\r\nfunction findProp(node, name, dynamicOnly = false, allowEmpty = false) {\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 6 /* ATTRIBUTE */) {\r\n if (dynamicOnly)\r\n continue;\r\n if (p.name === name && (p.value || allowEmpty)) {\r\n return p;\r\n }\r\n }\r\n else if (p.name === 'bind' &&\r\n (p.exp || allowEmpty) &&\r\n isBindKey(p.arg, name)) {\r\n return p;\r\n }\r\n }\r\n}\r\nfunction isBindKey(arg, name) {\r\n return !!(arg && isStaticExp(arg) && arg.content === name);\r\n}\r\nfunction hasDynamicKeyVBind(node) {\r\n return node.props.some(p => p.type === 7 /* DIRECTIVE */ &&\r\n p.name === 'bind' &&\r\n (!p.arg || // v-bind=\"obj\"\r\n p.arg.type !== 4 /* SIMPLE_EXPRESSION */ || // v-bind:[_ctx.foo]\r\n !p.arg.isStatic) // v-bind:[foo]\r\n );\r\n}\r\nfunction isText(node) {\r\n return node.type === 5 /* INTERPOLATION */ || node.type === 2 /* TEXT */;\r\n}\r\nfunction isVSlot(p) {\r\n return p.type === 7 /* DIRECTIVE */ && p.name === 'slot';\r\n}\r\nfunction isTemplateNode(node) {\r\n return (node.type === 1 /* ELEMENT */ && node.tagType === 3 /* TEMPLATE */);\r\n}\r\nfunction isSlotOutlet(node) {\r\n return node.type === 1 /* ELEMENT */ && node.tagType === 2 /* SLOT */;\r\n}\r\nfunction getVNodeHelper(ssr, isComponent) {\r\n return ssr || isComponent ? CREATE_VNODE : CREATE_ELEMENT_VNODE;\r\n}\r\nfunction getVNodeBlockHelper(ssr, isComponent) {\r\n return ssr || isComponent ? CREATE_BLOCK : CREATE_ELEMENT_BLOCK;\r\n}\r\nconst propsHelperSet = new Set([NORMALIZE_PROPS, GUARD_REACTIVE_PROPS]);\r\nfunction getUnnormalizedProps(props, callPath = []) {\r\n if (props &&\r\n !isString(props) &&\r\n props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n const callee = props.callee;\r\n if (!isString(callee) && propsHelperSet.has(callee)) {\r\n return getUnnormalizedProps(props.arguments[0], callPath.concat(props));\r\n }\r\n }\r\n return [props, callPath];\r\n}\r\nfunction injectProp(node, prop, context) {\r\n let propsWithInjection;\r\n const originalProps = node.type === 13 /* VNODE_CALL */ ? node.props : node.arguments[2];\r\n /**\r\n * 1. mergeProps(...)\r\n * 2. toHandlers(...)\r\n * 3. normalizeProps(...)\r\n * 4. normalizeProps(guardReactiveProps(...))\r\n *\r\n * we need to get the real props before normalization\r\n */\r\n let props = originalProps;\r\n let callPath = [];\r\n let parentCall;\r\n if (props &&\r\n !isString(props) &&\r\n props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n const ret = getUnnormalizedProps(props);\r\n props = ret[0];\r\n callPath = ret[1];\r\n parentCall = callPath[callPath.length - 1];\r\n }\r\n if (props == null || isString(props)) {\r\n propsWithInjection = createObjectExpression([prop]);\r\n }\r\n else if (props.type === 14 /* JS_CALL_EXPRESSION */) {\r\n // merged props... add ours\r\n // only inject key to object literal if it's the first argument so that\r\n // if doesn't override user provided keys\r\n const first = props.arguments[0];\r\n if (!isString(first) && first.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n first.properties.unshift(prop);\r\n }\r\n else {\r\n if (props.callee === TO_HANDLERS) {\r\n // #2366\r\n propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [\r\n createObjectExpression([prop]),\r\n props\r\n ]);\r\n }\r\n else {\r\n props.arguments.unshift(createObjectExpression([prop]));\r\n }\r\n }\r\n !propsWithInjection && (propsWithInjection = props);\r\n }\r\n else if (props.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n let alreadyExists = false;\r\n // check existing key to avoid overriding user provided keys\r\n if (prop.key.type === 4 /* SIMPLE_EXPRESSION */) {\r\n const propKeyName = prop.key.content;\r\n alreadyExists = props.properties.some(p => p.key.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n p.key.content === propKeyName);\r\n }\r\n if (!alreadyExists) {\r\n props.properties.unshift(prop);\r\n }\r\n propsWithInjection = props;\r\n }\r\n else {\r\n // single v-bind with expression, return a merged replacement\r\n propsWithInjection = createCallExpression(context.helper(MERGE_PROPS), [\r\n createObjectExpression([prop]),\r\n props\r\n ]);\r\n // in the case of nested helper call, e.g. `normalizeProps(guardReactiveProps(props))`,\r\n // it will be rewritten as `normalizeProps(mergeProps({ key: 0 }, props))`,\r\n // the `guardReactiveProps` will no longer be needed\r\n if (parentCall && parentCall.callee === GUARD_REACTIVE_PROPS) {\r\n parentCall = callPath[callPath.length - 2];\r\n }\r\n }\r\n if (node.type === 13 /* VNODE_CALL */) {\r\n if (parentCall) {\r\n parentCall.arguments[0] = propsWithInjection;\r\n }\r\n else {\r\n node.props = propsWithInjection;\r\n }\r\n }\r\n else {\r\n if (parentCall) {\r\n parentCall.arguments[0] = propsWithInjection;\r\n }\r\n else {\r\n node.arguments[2] = propsWithInjection;\r\n }\r\n }\r\n}\r\nfunction toValidAssetId(name, type) {\r\n // see issue#4422, we need adding identifier on validAssetId if variable `name` has specific character\r\n return `_${type}_${name.replace(/[^\\w]/g, (searchValue, replaceValue) => {\r\n return searchValue === '-' ? '_' : name.charCodeAt(replaceValue).toString();\r\n })}`;\r\n}\r\n// Check if a node contains expressions that reference current context scope ids\r\nfunction hasScopeRef(node, ids) {\r\n if (!node || Object.keys(ids).length === 0) {\r\n return false;\r\n }\r\n switch (node.type) {\r\n case 1 /* ELEMENT */:\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 7 /* DIRECTIVE */ &&\r\n (hasScopeRef(p.arg, ids) || hasScopeRef(p.exp, ids))) {\r\n return true;\r\n }\r\n }\r\n return node.children.some(c => hasScopeRef(c, ids));\r\n case 11 /* FOR */:\r\n if (hasScopeRef(node.source, ids)) {\r\n return true;\r\n }\r\n return node.children.some(c => hasScopeRef(c, ids));\r\n case 9 /* IF */:\r\n return node.branches.some(b => hasScopeRef(b, ids));\r\n case 10 /* IF_BRANCH */:\r\n if (hasScopeRef(node.condition, ids)) {\r\n return true;\r\n }\r\n return node.children.some(c => hasScopeRef(c, ids));\r\n case 4 /* SIMPLE_EXPRESSION */:\r\n return (!node.isStatic &&\r\n isSimpleIdentifier(node.content) &&\r\n !!ids[node.content]);\r\n case 8 /* COMPOUND_EXPRESSION */:\r\n return node.children.some(c => isObject(c) && hasScopeRef(c, ids));\r\n case 5 /* INTERPOLATION */:\r\n case 12 /* TEXT_CALL */:\r\n return hasScopeRef(node.content, ids);\r\n case 2 /* TEXT */:\r\n case 3 /* COMMENT */:\r\n return false;\r\n default:\r\n if ((process.env.NODE_ENV !== 'production')) ;\r\n return false;\r\n }\r\n}\r\nfunction getMemoedVNodeCall(node) {\r\n if (node.type === 14 /* JS_CALL_EXPRESSION */ && node.callee === WITH_MEMO) {\r\n return node.arguments[1].returns;\r\n }\r\n else {\r\n return node;\r\n }\r\n}\r\nfunction makeBlock(node, { helper, removeHelper, inSSR }) {\r\n if (!node.isBlock) {\r\n node.isBlock = true;\r\n removeHelper(getVNodeHelper(inSSR, node.isComponent));\r\n helper(OPEN_BLOCK);\r\n helper(getVNodeBlockHelper(inSSR, node.isComponent));\r\n }\r\n}\n\nconst deprecationData = {\r\n [\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */]: {\r\n message: `Platform-native elements with \"is\" prop will no longer be ` +\r\n `treated as components in Vue 3 unless the \"is\" value is explicitly ` +\r\n `prefixed with \"vue:\".`,\r\n link: `https://v3.vuejs.org/guide/migration/custom-elements-interop.html`\r\n },\r\n [\"COMPILER_V_BIND_SYNC\" /* COMPILER_V_BIND_SYNC */]: {\r\n message: key => `.sync modifier for v-bind has been removed. Use v-model with ` +\r\n `argument instead. \\`v-bind:${key}.sync\\` should be changed to ` +\r\n `\\`v-model:${key}\\`.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-model.html`\r\n },\r\n [\"COMPILER_V_BIND_PROP\" /* COMPILER_V_BIND_PROP */]: {\r\n message: `.prop modifier for v-bind has been removed and no longer necessary. ` +\r\n `Vue 3 will automatically set a binding as DOM property when appropriate.`\r\n },\r\n [\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */]: {\r\n message: `v-bind=\"obj\" usage is now order sensitive and behaves like JavaScript ` +\r\n `object spread: it will now overwrite an existing non-mergeable attribute ` +\r\n `that appears before v-bind in the case of conflict. ` +\r\n `To retain 2.x behavior, move v-bind to make it the first attribute. ` +\r\n `You can also suppress this warning if the usage is intended.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-bind.html`\r\n },\r\n [\"COMPILER_V_ON_NATIVE\" /* COMPILER_V_ON_NATIVE */]: {\r\n message: `.native modifier for v-on has been removed as is no longer necessary.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-on-native-modifier-removed.html`\r\n },\r\n [\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */]: {\r\n message: `v-if / v-for precedence when used on the same element has changed ` +\r\n `in Vue 3: v-if now takes higher precedence and will no longer have ` +\r\n `access to v-for scope variables. It is best to avoid the ambiguity ` +\r\n `with <template> tags or use a computed property that filters v-for ` +\r\n `data source.`,\r\n link: `https://v3.vuejs.org/guide/migration/v-if-v-for.html`\r\n },\r\n [\"COMPILER_V_FOR_REF\" /* COMPILER_V_FOR_REF */]: {\r\n message: `Ref usage on v-for no longer creates array ref values in Vue 3. ` +\r\n `Consider using function refs or refactor to avoid ref usage altogether.`,\r\n link: `https://v3.vuejs.org/guide/migration/array-refs.html`\r\n },\r\n [\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */]: {\r\n message: `<template> with no special directives will render as a native template ` +\r\n `element instead of its inner content in Vue 3.`\r\n },\r\n [\"COMPILER_INLINE_TEMPLATE\" /* COMPILER_INLINE_TEMPLATE */]: {\r\n message: `\"inline-template\" has been removed in Vue 3.`,\r\n link: `https://v3.vuejs.org/guide/migration/inline-template-attribute.html`\r\n },\r\n [\"COMPILER_FILTER\" /* COMPILER_FILTERS */]: {\r\n message: `filters have been removed in Vue 3. ` +\r\n `The \"|\" symbol will be treated as native JavaScript bitwise OR operator. ` +\r\n `Use method calls or computed properties instead.`,\r\n link: `https://v3.vuejs.org/guide/migration/filters.html`\r\n }\r\n};\r\nfunction getCompatValue(key, context) {\r\n const config = context.options\r\n ? context.options.compatConfig\r\n : context.compatConfig;\r\n const value = config && config[key];\r\n if (key === 'MODE') {\r\n return value || 3; // compiler defaults to v3 behavior\r\n }\r\n else {\r\n return value;\r\n }\r\n}\r\nfunction isCompatEnabled(key, context) {\r\n const mode = getCompatValue('MODE', context);\r\n const value = getCompatValue(key, context);\r\n // in v3 mode, only enable if explicitly set to true\r\n // otherwise enable for any non-false value\r\n return mode === 3 ? value === true : value !== false;\r\n}\r\nfunction checkCompatEnabled(key, context, loc, ...args) {\r\n const enabled = isCompatEnabled(key, context);\r\n if ((process.env.NODE_ENV !== 'production') && enabled) {\r\n warnDeprecation(key, context, loc, ...args);\r\n }\r\n return enabled;\r\n}\r\nfunction warnDeprecation(key, context, loc, ...args) {\r\n const val = getCompatValue(key, context);\r\n if (val === 'suppress-warning') {\r\n return;\r\n }\r\n const { message, link } = deprecationData[key];\r\n const msg = `(deprecation ${key}) ${typeof message === 'function' ? message(...args) : message}${link ? `\\n Details: ${link}` : ``}`;\r\n const err = new SyntaxError(msg);\r\n err.code = key;\r\n if (loc)\r\n err.loc = loc;\r\n context.onWarn(err);\r\n}\n\n// The default decoder only provides escapes for characters reserved as part of\r\n// the template syntax, and is only used if the custom renderer did not provide\r\n// a platform-specific decoder.\r\nconst decodeRE = /&(gt|lt|amp|apos|quot);/g;\r\nconst decodeMap = {\r\n gt: '>',\r\n lt: '<',\r\n amp: '&',\r\n apos: \"'\",\r\n quot: '\"'\r\n};\r\nconst defaultParserOptions = {\r\n delimiters: [`{{`, `}}`],\r\n getNamespace: () => 0 /* HTML */,\r\n getTextMode: () => 0 /* DATA */,\r\n isVoidTag: NO,\r\n isPreTag: NO,\r\n isCustomElement: NO,\r\n decodeEntities: (rawText) => rawText.replace(decodeRE, (_, p1) => decodeMap[p1]),\r\n onError: defaultOnError,\r\n onWarn: defaultOnWarn,\r\n comments: (process.env.NODE_ENV !== 'production')\r\n};\r\nfunction baseParse(content, options = {}) {\r\n const context = createParserContext(content, options);\r\n const start = getCursor(context);\r\n return createRoot(parseChildren(context, 0 /* DATA */, []), getSelection(context, start));\r\n}\r\nfunction createParserContext(content, rawOptions) {\r\n const options = extend({}, defaultParserOptions);\r\n let key;\r\n for (key in rawOptions) {\r\n // @ts-ignore\r\n options[key] =\r\n rawOptions[key] === undefined\r\n ? defaultParserOptions[key]\r\n : rawOptions[key];\r\n }\r\n return {\r\n options,\r\n column: 1,\r\n line: 1,\r\n offset: 0,\r\n originalSource: content,\r\n source: content,\r\n inPre: false,\r\n inVPre: false,\r\n onWarn: options.onWarn\r\n };\r\n}\r\nfunction parseChildren(context, mode, ancestors) {\r\n const parent = last(ancestors);\r\n const ns = parent ? parent.ns : 0 /* HTML */;\r\n const nodes = [];\r\n while (!isEnd(context, mode, ancestors)) {\r\n const s = context.source;\r\n let node = undefined;\r\n if (mode === 0 /* DATA */ || mode === 1 /* RCDATA */) {\r\n if (!context.inVPre && startsWith(s, context.options.delimiters[0])) {\r\n // '{{'\r\n node = parseInterpolation(context, mode);\r\n }\r\n else if (mode === 0 /* DATA */ && s[0] === '<') {\r\n // https://html.spec.whatwg.org/multipage/parsing.html#tag-open-state\r\n if (s.length === 1) {\r\n emitError(context, 5 /* EOF_BEFORE_TAG_NAME */, 1);\r\n }\r\n else if (s[1] === '!') {\r\n // https://html.spec.whatwg.org/multipage/parsing.html#markup-declaration-open-state\r\n if (startsWith(s, '<!--')) {\r\n node = parseComment(context);\r\n }\r\n else if (startsWith(s, '<!DOCTYPE')) {\r\n // Ignore DOCTYPE by a limitation.\r\n node = parseBogusComment(context);\r\n }\r\n else if (startsWith(s, '<![CDATA[')) {\r\n if (ns !== 0 /* HTML */) {\r\n node = parseCDATA(context, ancestors);\r\n }\r\n else {\r\n emitError(context, 1 /* CDATA_IN_HTML_CONTENT */);\r\n node = parseBogusComment(context);\r\n }\r\n }\r\n else {\r\n emitError(context, 11 /* INCORRECTLY_OPENED_COMMENT */);\r\n node = parseBogusComment(context);\r\n }\r\n }\r\n else if (s[1] === '/') {\r\n // https://html.spec.whatwg.org/multipage/parsing.html#end-tag-open-state\r\n if (s.length === 2) {\r\n emitError(context, 5 /* EOF_BEFORE_TAG_NAME */, 2);\r\n }\r\n else if (s[2] === '>') {\r\n emitError(context, 14 /* MISSING_END_TAG_NAME */, 2);\r\n advanceBy(context, 3);\r\n continue;\r\n }\r\n else if (/[a-z]/i.test(s[2])) {\r\n emitError(context, 23 /* X_INVALID_END_TAG */);\r\n parseTag(context, 1 /* End */, parent);\r\n continue;\r\n }\r\n else {\r\n emitError(context, 12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */, 2);\r\n node = parseBogusComment(context);\r\n }\r\n }\r\n else if (/[a-z]/i.test(s[1])) {\r\n node = parseElement(context, ancestors);\r\n // 2.x <template> with no directive compat\r\n if (isCompatEnabled(\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */, context) &&\r\n node &&\r\n node.tag === 'template' &&\r\n !node.props.some(p => p.type === 7 /* DIRECTIVE */ &&\r\n isSpecialTemplateDirective(p.name))) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warnDeprecation(\"COMPILER_NATIVE_TEMPLATE\" /* COMPILER_NATIVE_TEMPLATE */, context, node.loc);\r\n node = node.children;\r\n }\r\n }\r\n else if (s[1] === '?') {\r\n emitError(context, 21 /* UNEXPECTED_QUESTION_MARK_INSTEAD_OF_TAG_NAME */, 1);\r\n node = parseBogusComment(context);\r\n }\r\n else {\r\n emitError(context, 12 /* INVALID_FIRST_CHARACTER_OF_TAG_NAME */, 1);\r\n }\r\n }\r\n }\r\n if (!node) {\r\n node = parseText(context, mode);\r\n }\r\n if (isArray(node)) {\r\n for (let i = 0; i < node.length; i++) {\r\n pushNode(nodes, node[i]);\r\n }\r\n }\r\n else {\r\n pushNode(nodes, node);\r\n }\r\n }\r\n // Whitespace handling strategy like v2\r\n let removedWhitespace = false;\r\n if (mode !== 2 /* RAWTEXT */ && mode !== 1 /* RCDATA */) {\r\n const shouldCondense = context.options.whitespace !== 'preserve';\r\n for (let i = 0; i < nodes.length; i++) {\r\n const node = nodes[i];\r\n if (!context.inPre && node.type === 2 /* TEXT */) {\r\n if (!/[^\\t\\r\\n\\f ]/.test(node.content)) {\r\n const prev = nodes[i - 1];\r\n const next = nodes[i + 1];\r\n // Remove if:\r\n // - the whitespace is the first or last node, or:\r\n // - (condense mode) the whitespace is adjacent to a comment, or:\r\n // - (condense mode) the whitespace is between two elements AND contains newline\r\n if (!prev ||\r\n !next ||\r\n (shouldCondense &&\r\n (prev.type === 3 /* COMMENT */ ||\r\n next.type === 3 /* COMMENT */ ||\r\n (prev.type === 1 /* ELEMENT */ &&\r\n next.type === 1 /* ELEMENT */ &&\r\n /[\\r\\n]/.test(node.content))))) {\r\n removedWhitespace = true;\r\n nodes[i] = null;\r\n }\r\n else {\r\n // Otherwise, the whitespace is condensed into a single space\r\n node.content = ' ';\r\n }\r\n }\r\n else if (shouldCondense) {\r\n // in condense mode, consecutive whitespaces in text are condensed\r\n // down to a single space.\r\n node.content = node.content.replace(/[\\t\\r\\n\\f ]+/g, ' ');\r\n }\r\n }\r\n // Remove comment nodes if desired by configuration.\r\n else if (node.type === 3 /* COMMENT */ && !context.options.comments) {\r\n removedWhitespace = true;\r\n nodes[i] = null;\r\n }\r\n }\r\n if (context.inPre && parent && context.options.isPreTag(parent.tag)) {\r\n // remove leading newline per html spec\r\n // https://html.spec.whatwg.org/multipage/grouping-content.html#the-pre-element\r\n const first = nodes[0];\r\n if (first && first.type === 2 /* TEXT */) {\r\n first.content = first.content.replace(/^\\r?\\n/, '');\r\n }\r\n }\r\n }\r\n return removedWhitespace ? nodes.filter(Boolean) : nodes;\r\n}\r\nfunction pushNode(nodes, node) {\r\n if (node.type === 2 /* TEXT */) {\r\n const prev = last(nodes);\r\n // Merge if both this and the previous node are text and those are\r\n // consecutive. This happens for cases like \"a < b\".\r\n if (prev &&\r\n prev.type === 2 /* TEXT */ &&\r\n prev.loc.end.offset === node.loc.start.offset) {\r\n prev.content += node.content;\r\n prev.loc.end = node.loc.end;\r\n prev.loc.source += node.loc.source;\r\n return;\r\n }\r\n }\r\n nodes.push(node);\r\n}\r\nfunction parseCDATA(context, ancestors) {\r\n advanceBy(context, 9);\r\n const nodes = parseChildren(context, 3 /* CDATA */, ancestors);\r\n if (context.source.length === 0) {\r\n emitError(context, 6 /* EOF_IN_CDATA */);\r\n }\r\n else {\r\n advanceBy(context, 3);\r\n }\r\n return nodes;\r\n}\r\nfunction parseComment(context) {\r\n const start = getCursor(context);\r\n let content;\r\n // Regular comment.\r\n const match = /--(\\!)?>/.exec(context.source);\r\n if (!match) {\r\n content = context.source.slice(4);\r\n advanceBy(context, context.source.length);\r\n emitError(context, 7 /* EOF_IN_COMMENT */);\r\n }\r\n else {\r\n if (match.index <= 3) {\r\n emitError(context, 0 /* ABRUPT_CLOSING_OF_EMPTY_COMMENT */);\r\n }\r\n if (match[1]) {\r\n emitError(context, 10 /* INCORRECTLY_CLOSED_COMMENT */);\r\n }\r\n content = context.source.slice(4, match.index);\r\n // Advancing with reporting nested comments.\r\n const s = context.source.slice(0, match.index);\r\n let prevIndex = 1, nestedIndex = 0;\r\n while ((nestedIndex = s.indexOf('<!--', prevIndex)) !== -1) {\r\n advanceBy(context, nestedIndex - prevIndex + 1);\r\n if (nestedIndex + 4 < s.length) {\r\n emitError(context, 16 /* NESTED_COMMENT */);\r\n }\r\n prevIndex = nestedIndex + 1;\r\n }\r\n advanceBy(context, match.index + match[0].length - prevIndex + 1);\r\n }\r\n return {\r\n type: 3 /* COMMENT */,\r\n content,\r\n loc: getSelection(context, start)\r\n };\r\n}\r\nfunction parseBogusComment(context) {\r\n const start = getCursor(context);\r\n const contentStart = context.source[1] === '?' ? 1 : 2;\r\n let content;\r\n const closeIndex = context.source.indexOf('>');\r\n if (closeIndex === -1) {\r\n content = context.source.slice(contentStart);\r\n advanceBy(context, context.source.length);\r\n }\r\n else {\r\n content = context.source.slice(contentStart, closeIndex);\r\n advanceBy(context, closeIndex + 1);\r\n }\r\n return {\r\n type: 3 /* COMMENT */,\r\n content,\r\n loc: getSelection(context, start)\r\n };\r\n}\r\nfunction parseElement(context, ancestors) {\r\n // Start tag.\r\n const wasInPre = context.inPre;\r\n const wasInVPre = context.inVPre;\r\n const parent = last(ancestors);\r\n const element = parseTag(context, 0 /* Start */, parent);\r\n const isPreBoundary = context.inPre && !wasInPre;\r\n const isVPreBoundary = context.inVPre && !wasInVPre;\r\n if (element.isSelfClosing || context.options.isVoidTag(element.tag)) {\r\n // #4030 self-closing <pre> tag\r\n if (isPreBoundary) {\r\n context.inPre = false;\r\n }\r\n if (isVPreBoundary) {\r\n context.inVPre = false;\r\n }\r\n return element;\r\n }\r\n // Children.\r\n ancestors.push(element);\r\n const mode = context.options.getTextMode(element, parent);\r\n const children = parseChildren(context, mode, ancestors);\r\n ancestors.pop();\r\n // 2.x inline-template compat\r\n {\r\n const inlineTemplateProp = element.props.find(p => p.type === 6 /* ATTRIBUTE */ && p.name === 'inline-template');\r\n if (inlineTemplateProp &&\r\n checkCompatEnabled(\"COMPILER_INLINE_TEMPLATE\" /* COMPILER_INLINE_TEMPLATE */, context, inlineTemplateProp.loc)) {\r\n const loc = getSelection(context, element.loc.end);\r\n inlineTemplateProp.value = {\r\n type: 2 /* TEXT */,\r\n content: loc.source,\r\n loc\r\n };\r\n }\r\n }\r\n element.children = children;\r\n // End tag.\r\n if (startsWithEndTagOpen(context.source, element.tag)) {\r\n parseTag(context, 1 /* End */, parent);\r\n }\r\n else {\r\n emitError(context, 24 /* X_MISSING_END_TAG */, 0, element.loc.start);\r\n if (context.source.length === 0 && element.tag.toLowerCase() === 'script') {\r\n const first = children[0];\r\n if (first && startsWith(first.loc.source, '<!--')) {\r\n emitError(context, 8 /* EOF_IN_SCRIPT_HTML_COMMENT_LIKE_TEXT */);\r\n }\r\n }\r\n }\r\n element.loc = getSelection(context, element.loc.start);\r\n if (isPreBoundary) {\r\n context.inPre = false;\r\n }\r\n if (isVPreBoundary) {\r\n context.inVPre = false;\r\n }\r\n return element;\r\n}\r\nconst isSpecialTemplateDirective = /*#__PURE__*/ makeMap(`if,else,else-if,for,slot`);\r\nfunction parseTag(context, type, parent) {\r\n // Tag open.\r\n const start = getCursor(context);\r\n const match = /^<\\/?([a-z][^\\t\\r\\n\\f />]*)/i.exec(context.source);\r\n const tag = match[1];\r\n const ns = context.options.getNamespace(tag, parent);\r\n advanceBy(context, match[0].length);\r\n advanceSpaces(context);\r\n // save current state in case we need to re-parse attributes with v-pre\r\n const cursor = getCursor(context);\r\n const currentSource = context.source;\r\n // check <pre> tag\r\n if (context.options.isPreTag(tag)) {\r\n context.inPre = true;\r\n }\r\n // Attributes.\r\n let props = parseAttributes(context, type);\r\n // check v-pre\r\n if (type === 0 /* Start */ &&\r\n !context.inVPre &&\r\n props.some(p => p.type === 7 /* DIRECTIVE */ && p.name === 'pre')) {\r\n context.inVPre = true;\r\n // reset context\r\n extend(context, cursor);\r\n context.source = currentSource;\r\n // re-parse attrs and filter out v-pre itself\r\n props = parseAttributes(context, type).filter(p => p.name !== 'v-pre');\r\n }\r\n // Tag close.\r\n let isSelfClosing = false;\r\n if (context.source.length === 0) {\r\n emitError(context, 9 /* EOF_IN_TAG */);\r\n }\r\n else {\r\n isSelfClosing = startsWith(context.source, '/>');\r\n if (type === 1 /* End */ && isSelfClosing) {\r\n emitError(context, 4 /* END_TAG_WITH_TRAILING_SOLIDUS */);\r\n }\r\n advanceBy(context, isSelfClosing ? 2 : 1);\r\n }\r\n if (type === 1 /* End */) {\r\n return;\r\n }\r\n // 2.x deprecation checks\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n isCompatEnabled(\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */, context)) {\r\n let hasIf = false;\r\n let hasFor = false;\r\n for (let i = 0; i < props.length; i++) {\r\n const p = props[i];\r\n if (p.type === 7 /* DIRECTIVE */) {\r\n if (p.name === 'if') {\r\n hasIf = true;\r\n }\r\n else if (p.name === 'for') {\r\n hasFor = true;\r\n }\r\n }\r\n if (hasIf && hasFor) {\r\n warnDeprecation(\"COMPILER_V_IF_V_FOR_PRECEDENCE\" /* COMPILER_V_IF_V_FOR_PRECEDENCE */, context, getSelection(context, start));\r\n break;\r\n }\r\n }\r\n }\r\n let tagType = 0 /* ELEMENT */;\r\n if (!context.inVPre) {\r\n if (tag === 'slot') {\r\n tagType = 2 /* SLOT */;\r\n }\r\n else if (tag === 'template') {\r\n if (props.some(p => p.type === 7 /* DIRECTIVE */ && isSpecialTemplateDirective(p.name))) {\r\n tagType = 3 /* TEMPLATE */;\r\n }\r\n }\r\n else if (isComponent(tag, props, context)) {\r\n tagType = 1 /* COMPONENT */;\r\n }\r\n }\r\n return {\r\n type: 1 /* ELEMENT */,\r\n ns,\r\n tag,\r\n tagType,\r\n props,\r\n isSelfClosing,\r\n children: [],\r\n loc: getSelection(context, start),\r\n codegenNode: undefined // to be created during transform phase\r\n };\r\n}\r\nfunction isComponent(tag, props, context) {\r\n const options = context.options;\r\n if (options.isCustomElement(tag)) {\r\n return false;\r\n }\r\n if (tag === 'component' ||\r\n /^[A-Z]/.test(tag) ||\r\n isCoreComponent(tag) ||\r\n (options.isBuiltInComponent && options.isBuiltInComponent(tag)) ||\r\n (options.isNativeTag && !options.isNativeTag(tag))) {\r\n return true;\r\n }\r\n // at this point the tag should be a native tag, but check for potential \"is\"\r\n // casting\r\n for (let i = 0; i < props.length; i++) {\r\n const p = props[i];\r\n if (p.type === 6 /* ATTRIBUTE */) {\r\n if (p.name === 'is' && p.value) {\r\n if (p.value.content.startsWith('vue:')) {\r\n return true;\r\n }\r\n else if (checkCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context, p.loc)) {\r\n return true;\r\n }\r\n }\r\n }\r\n else {\r\n // directive\r\n // v-is (TODO Deprecate)\r\n if (p.name === 'is') {\r\n return true;\r\n }\r\n else if (\r\n // :is on plain element - only treat as component in compat mode\r\n p.name === 'bind' &&\r\n isBindKey(p.arg, 'is') &&\r\n true &&\r\n checkCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context, p.loc)) {\r\n return true;\r\n }\r\n }\r\n }\r\n}\r\nfunction parseAttributes(context, type) {\r\n const props = [];\r\n const attributeNames = new Set();\r\n while (context.source.length > 0 &&\r\n !startsWith(context.source, '>') &&\r\n !startsWith(context.source, '/>')) {\r\n if (startsWith(context.source, '/')) {\r\n emitError(context, 22 /* UNEXPECTED_SOLIDUS_IN_TAG */);\r\n advanceBy(context, 1);\r\n advanceSpaces(context);\r\n continue;\r\n }\r\n if (type === 1 /* End */) {\r\n emitError(context, 3 /* END_TAG_WITH_ATTRIBUTES */);\r\n }\r\n const attr = parseAttribute(context, attributeNames);\r\n // Trim whitespace between class\r\n // https://github.com/vuejs/vue-next/issues/4251\r\n if (attr.type === 6 /* ATTRIBUTE */ &&\r\n attr.value &&\r\n attr.name === 'class') {\r\n attr.value.content = attr.value.content.replace(/\\s+/g, ' ').trim();\r\n }\r\n if (type === 0 /* Start */) {\r\n props.push(attr);\r\n }\r\n if (/^[^\\t\\r\\n\\f />]/.test(context.source)) {\r\n emitError(context, 15 /* MISSING_WHITESPACE_BETWEEN_ATTRIBUTES */);\r\n }\r\n advanceSpaces(context);\r\n }\r\n return props;\r\n}\r\nfunction parseAttribute(context, nameSet) {\r\n // Name.\r\n const start = getCursor(context);\r\n const match = /^[^\\t\\r\\n\\f />][^\\t\\r\\n\\f />=]*/.exec(context.source);\r\n const name = match[0];\r\n if (nameSet.has(name)) {\r\n emitError(context, 2 /* DUPLICATE_ATTRIBUTE */);\r\n }\r\n nameSet.add(name);\r\n if (name[0] === '=') {\r\n emitError(context, 19 /* UNEXPECTED_EQUALS_SIGN_BEFORE_ATTRIBUTE_NAME */);\r\n }\r\n {\r\n const pattern = /[\"'<]/g;\r\n let m;\r\n while ((m = pattern.exec(name))) {\r\n emitError(context, 17 /* UNEXPECTED_CHARACTER_IN_ATTRIBUTE_NAME */, m.index);\r\n }\r\n }\r\n advanceBy(context, name.length);\r\n // Value\r\n let value = undefined;\r\n if (/^[\\t\\r\\n\\f ]*=/.test(context.source)) {\r\n advanceSpaces(context);\r\n advanceBy(context, 1);\r\n advanceSpaces(context);\r\n value = parseAttributeValue(context);\r\n if (!value) {\r\n emitError(context, 13 /* MISSING_ATTRIBUTE_VALUE */);\r\n }\r\n }\r\n const loc = getSelection(context, start);\r\n if (!context.inVPre && /^(v-[A-Za-z0-9-]|:|\\.|@|#)/.test(name)) {\r\n const match = /(?:^v-([a-z0-9-]+))?(?:(?::|^\\.|^@|^#)(\\[[^\\]]+\\]|[^\\.]+))?(.+)?$/i.exec(name);\r\n let isPropShorthand = startsWith(name, '.');\r\n let dirName = match[1] ||\r\n (isPropShorthand || startsWith(name, ':')\r\n ? 'bind'\r\n : startsWith(name, '@')\r\n ? 'on'\r\n : 'slot');\r\n let arg;\r\n if (match[2]) {\r\n const isSlot = dirName === 'slot';\r\n const startOffset = name.lastIndexOf(match[2]);\r\n const loc = getSelection(context, getNewPosition(context, start, startOffset), getNewPosition(context, start, startOffset + match[2].length + ((isSlot && match[3]) || '').length));\r\n let content = match[2];\r\n let isStatic = true;\r\n if (content.startsWith('[')) {\r\n isStatic = false;\r\n if (!content.endsWith(']')) {\r\n emitError(context, 27 /* X_MISSING_DYNAMIC_DIRECTIVE_ARGUMENT_END */);\r\n content = content.slice(1);\r\n }\r\n else {\r\n content = content.slice(1, content.length - 1);\r\n }\r\n }\r\n else if (isSlot) {\r\n // #1241 special case for v-slot: vuetify relies extensively on slot\r\n // names containing dots. v-slot doesn't have any modifiers and Vue 2.x\r\n // supports such usage so we are keeping it consistent with 2.x.\r\n content += match[3] || '';\r\n }\r\n arg = {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n content,\r\n isStatic,\r\n constType: isStatic\r\n ? 3 /* CAN_STRINGIFY */\r\n : 0 /* NOT_CONSTANT */,\r\n loc\r\n };\r\n }\r\n if (value && value.isQuoted) {\r\n const valueLoc = value.loc;\r\n valueLoc.start.offset++;\r\n valueLoc.start.column++;\r\n valueLoc.end = advancePositionWithClone(valueLoc.start, value.content);\r\n valueLoc.source = valueLoc.source.slice(1, -1);\r\n }\r\n const modifiers = match[3] ? match[3].slice(1).split('.') : [];\r\n if (isPropShorthand)\r\n modifiers.push('prop');\r\n // 2.x compat v-bind:foo.sync -> v-model:foo\r\n if (dirName === 'bind' && arg) {\r\n if (modifiers.includes('sync') &&\r\n checkCompatEnabled(\"COMPILER_V_BIND_SYNC\" /* COMPILER_V_BIND_SYNC */, context, loc, arg.loc.source)) {\r\n dirName = 'model';\r\n modifiers.splice(modifiers.indexOf('sync'), 1);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && modifiers.includes('prop')) {\r\n checkCompatEnabled(\"COMPILER_V_BIND_PROP\" /* COMPILER_V_BIND_PROP */, context, loc);\r\n }\r\n }\r\n return {\r\n type: 7 /* DIRECTIVE */,\r\n name: dirName,\r\n exp: value && {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n content: value.content,\r\n isStatic: false,\r\n // Treat as non-constant by default. This can be potentially set to\r\n // other values by `transformExpression` to make it eligible for hoisting.\r\n constType: 0 /* NOT_CONSTANT */,\r\n loc: value.loc\r\n },\r\n arg,\r\n modifiers,\r\n loc\r\n };\r\n }\r\n // missing directive name or illegal directive name\r\n if (!context.inVPre && startsWith(name, 'v-')) {\r\n emitError(context, 26 /* X_MISSING_DIRECTIVE_NAME */);\r\n }\r\n return {\r\n type: 6 /* ATTRIBUTE */,\r\n name,\r\n value: value && {\r\n type: 2 /* TEXT */,\r\n content: value.content,\r\n loc: value.loc\r\n },\r\n loc\r\n };\r\n}\r\nfunction parseAttributeValue(context) {\r\n const start = getCursor(context);\r\n let content;\r\n const quote = context.source[0];\r\n const isQuoted = quote === `\"` || quote === `'`;\r\n if (isQuoted) {\r\n // Quoted value.\r\n advanceBy(context, 1);\r\n const endIndex = context.source.indexOf(quote);\r\n if (endIndex === -1) {\r\n content = parseTextData(context, context.source.length, 4 /* ATTRIBUTE_VALUE */);\r\n }\r\n else {\r\n content = parseTextData(context, endIndex, 4 /* ATTRIBUTE_VALUE */);\r\n advanceBy(context, 1);\r\n }\r\n }\r\n else {\r\n // Unquoted\r\n const match = /^[^\\t\\r\\n\\f >]+/.exec(context.source);\r\n if (!match) {\r\n return undefined;\r\n }\r\n const unexpectedChars = /[\"'<=`]/g;\r\n let m;\r\n while ((m = unexpectedChars.exec(match[0]))) {\r\n emitError(context, 18 /* UNEXPECTED_CHARACTER_IN_UNQUOTED_ATTRIBUTE_VALUE */, m.index);\r\n }\r\n content = parseTextData(context, match[0].length, 4 /* ATTRIBUTE_VALUE */);\r\n }\r\n return { content, isQuoted, loc: getSelection(context, start) };\r\n}\r\nfunction parseInterpolation(context, mode) {\r\n const [open, close] = context.options.delimiters;\r\n const closeIndex = context.source.indexOf(close, open.length);\r\n if (closeIndex === -1) {\r\n emitError(context, 25 /* X_MISSING_INTERPOLATION_END */);\r\n return undefined;\r\n }\r\n const start = getCursor(context);\r\n advanceBy(context, open.length);\r\n const innerStart = getCursor(context);\r\n const innerEnd = getCursor(context);\r\n const rawContentLength = closeIndex - open.length;\r\n const rawContent = context.source.slice(0, rawContentLength);\r\n const preTrimContent = parseTextData(context, rawContentLength, mode);\r\n const content = preTrimContent.trim();\r\n const startOffset = preTrimContent.indexOf(content);\r\n if (startOffset > 0) {\r\n advancePositionWithMutation(innerStart, rawContent, startOffset);\r\n }\r\n const endOffset = rawContentLength - (preTrimContent.length - content.length - startOffset);\r\n advancePositionWithMutation(innerEnd, rawContent, endOffset);\r\n advanceBy(context, close.length);\r\n return {\r\n type: 5 /* INTERPOLATION */,\r\n content: {\r\n type: 4 /* SIMPLE_EXPRESSION */,\r\n isStatic: false,\r\n // Set `isConstant` to false by default and will decide in transformExpression\r\n constType: 0 /* NOT_CONSTANT */,\r\n content,\r\n loc: getSelection(context, innerStart, innerEnd)\r\n },\r\n loc: getSelection(context, start)\r\n };\r\n}\r\nfunction parseText(context, mode) {\r\n const endTokens = mode === 3 /* CDATA */ ? [']]>'] : ['<', context.options.delimiters[0]];\r\n let endIndex = context.source.length;\r\n for (let i = 0; i < endTokens.length; i++) {\r\n const index = context.source.indexOf(endTokens[i], 1);\r\n if (index !== -1 && endIndex > index) {\r\n endIndex = index;\r\n }\r\n }\r\n const start = getCursor(context);\r\n const content = parseTextData(context, endIndex, mode);\r\n return {\r\n type: 2 /* TEXT */,\r\n content,\r\n loc: getSelection(context, start)\r\n };\r\n}\r\n/**\r\n * Get text data with a given length from the current location.\r\n * This translates HTML entities in the text data.\r\n */\r\nfunction parseTextData(context, length, mode) {\r\n const rawText = context.source.slice(0, length);\r\n advanceBy(context, length);\r\n if (mode === 2 /* RAWTEXT */ ||\r\n mode === 3 /* CDATA */ ||\r\n rawText.indexOf('&') === -1) {\r\n return rawText;\r\n }\r\n else {\r\n // DATA or RCDATA containing \"&\"\". Entity decoding required.\r\n return context.options.decodeEntities(rawText, mode === 4 /* ATTRIBUTE_VALUE */);\r\n }\r\n}\r\nfunction getCursor(context) {\r\n const { column, line, offset } = context;\r\n return { column, line, offset };\r\n}\r\nfunction getSelection(context, start, end) {\r\n end = end || getCursor(context);\r\n return {\r\n start,\r\n end,\r\n source: context.originalSource.slice(start.offset, end.offset)\r\n };\r\n}\r\nfunction last(xs) {\r\n return xs[xs.length - 1];\r\n}\r\nfunction startsWith(source, searchString) {\r\n return source.startsWith(searchString);\r\n}\r\nfunction advanceBy(context, numberOfCharacters) {\r\n const { source } = context;\r\n advancePositionWithMutation(context, source, numberOfCharacters);\r\n context.source = source.slice(numberOfCharacters);\r\n}\r\nfunction advanceSpaces(context) {\r\n const match = /^[\\t\\r\\n\\f ]+/.exec(context.source);\r\n if (match) {\r\n advanceBy(context, match[0].length);\r\n }\r\n}\r\nfunction getNewPosition(context, start, numberOfCharacters) {\r\n return advancePositionWithClone(start, context.originalSource.slice(start.offset, numberOfCharacters), numberOfCharacters);\r\n}\r\nfunction emitError(context, code, offset, loc = getCursor(context)) {\r\n if (offset) {\r\n loc.offset += offset;\r\n loc.column += offset;\r\n }\r\n context.options.onError(createCompilerError(code, {\r\n start: loc,\r\n end: loc,\r\n source: ''\r\n }));\r\n}\r\nfunction isEnd(context, mode, ancestors) {\r\n const s = context.source;\r\n switch (mode) {\r\n case 0 /* DATA */:\r\n if (startsWith(s, '</')) {\r\n // TODO: probably bad performance\r\n for (let i = ancestors.length - 1; i >= 0; --i) {\r\n if (startsWithEndTagOpen(s, ancestors[i].tag)) {\r\n return true;\r\n }\r\n }\r\n }\r\n break;\r\n case 1 /* RCDATA */:\r\n case 2 /* RAWTEXT */: {\r\n const parent = last(ancestors);\r\n if (parent && startsWithEndTagOpen(s, parent.tag)) {\r\n return true;\r\n }\r\n break;\r\n }\r\n case 3 /* CDATA */:\r\n if (startsWith(s, ']]>')) {\r\n return true;\r\n }\r\n break;\r\n }\r\n return !s;\r\n}\r\nfunction startsWithEndTagOpen(source, tag) {\r\n return (startsWith(source, '</') &&\r\n source.slice(2, 2 + tag.length).toLowerCase() === tag.toLowerCase() &&\r\n /[\\t\\r\\n\\f />]/.test(source[2 + tag.length] || '>'));\r\n}\n\nfunction hoistStatic(root, context) {\r\n walk(root, context, \r\n // Root node is unfortunately non-hoistable due to potential parent\r\n // fallthrough attributes.\r\n isSingleElementRoot(root, root.children[0]));\r\n}\r\nfunction isSingleElementRoot(root, child) {\r\n const { children } = root;\r\n return (children.length === 1 &&\r\n child.type === 1 /* ELEMENT */ &&\r\n !isSlotOutlet(child));\r\n}\r\nfunction walk(node, context, doNotHoistNode = false) {\r\n // Some transforms, e.g. transformAssetUrls from @vue/compiler-sfc, replaces\r\n // static bindings with expressions. These expressions are guaranteed to be\r\n // constant so they are still eligible for hoisting, but they are only\r\n // available at runtime and therefore cannot be evaluated ahead of time.\r\n // This is only a concern for pre-stringification (via transformHoist by\r\n // @vue/compiler-dom), but doing it here allows us to perform only one full\r\n // walk of the AST and allow `stringifyStatic` to stop walking as soon as its\r\n // stringification threshold is met.\r\n let canStringify = true;\r\n const { children } = node;\r\n const originalCount = children.length;\r\n let hoistedCount = 0;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n // only plain elements & text calls are eligible for hoisting.\r\n if (child.type === 1 /* ELEMENT */ &&\r\n child.tagType === 0 /* ELEMENT */) {\r\n const constantType = doNotHoistNode\r\n ? 0 /* NOT_CONSTANT */\r\n : getConstantType(child, context);\r\n if (constantType > 0 /* NOT_CONSTANT */) {\r\n if (constantType < 3 /* CAN_STRINGIFY */) {\r\n canStringify = false;\r\n }\r\n if (constantType >= 2 /* CAN_HOIST */) {\r\n child.codegenNode.patchFlag =\r\n -1 /* HOISTED */ + ((process.env.NODE_ENV !== 'production') ? ` /* HOISTED */` : ``);\r\n child.codegenNode = context.hoist(child.codegenNode);\r\n hoistedCount++;\r\n continue;\r\n }\r\n }\r\n else {\r\n // node may contain dynamic children, but its props may be eligible for\r\n // hoisting.\r\n const codegenNode = child.codegenNode;\r\n if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n const flag = getPatchFlag(codegenNode);\r\n if ((!flag ||\r\n flag === 512 /* NEED_PATCH */ ||\r\n flag === 1 /* TEXT */) &&\r\n getGeneratedPropsConstantType(child, context) >=\r\n 2 /* CAN_HOIST */) {\r\n const props = getNodeProps(child);\r\n if (props) {\r\n codegenNode.props = context.hoist(props);\r\n }\r\n }\r\n if (codegenNode.dynamicProps) {\r\n codegenNode.dynamicProps = context.hoist(codegenNode.dynamicProps);\r\n }\r\n }\r\n }\r\n }\r\n else if (child.type === 12 /* TEXT_CALL */) {\r\n const contentType = getConstantType(child.content, context);\r\n if (contentType > 0) {\r\n if (contentType < 3 /* CAN_STRINGIFY */) {\r\n canStringify = false;\r\n }\r\n if (contentType >= 2 /* CAN_HOIST */) {\r\n child.codegenNode = context.hoist(child.codegenNode);\r\n hoistedCount++;\r\n }\r\n }\r\n }\r\n // walk further\r\n if (child.type === 1 /* ELEMENT */) {\r\n const isComponent = child.tagType === 1 /* COMPONENT */;\r\n if (isComponent) {\r\n context.scopes.vSlot++;\r\n }\r\n walk(child, context);\r\n if (isComponent) {\r\n context.scopes.vSlot--;\r\n }\r\n }\r\n else if (child.type === 11 /* FOR */) {\r\n // Do not hoist v-for single child because it has to be a block\r\n walk(child, context, child.children.length === 1);\r\n }\r\n else if (child.type === 9 /* IF */) {\r\n for (let i = 0; i < child.branches.length; i++) {\r\n // Do not hoist v-if single child because it has to be a block\r\n walk(child.branches[i], context, child.branches[i].children.length === 1);\r\n }\r\n }\r\n }\r\n if (canStringify && hoistedCount && context.transformHoist) {\r\n context.transformHoist(children, context, node);\r\n }\r\n // all children were hoisted - the entire children array is hoistable.\r\n if (hoistedCount &&\r\n hoistedCount === originalCount &&\r\n node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 0 /* ELEMENT */ &&\r\n node.codegenNode &&\r\n node.codegenNode.type === 13 /* VNODE_CALL */ &&\r\n isArray(node.codegenNode.children)) {\r\n node.codegenNode.children = context.hoist(createArrayExpression(node.codegenNode.children));\r\n }\r\n}\r\nfunction getConstantType(node, context) {\r\n const { constantCache } = context;\r\n switch (node.type) {\r\n case 1 /* ELEMENT */:\r\n if (node.tagType !== 0 /* ELEMENT */) {\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n const cached = constantCache.get(node);\r\n if (cached !== undefined) {\r\n return cached;\r\n }\r\n const codegenNode = node.codegenNode;\r\n if (codegenNode.type !== 13 /* VNODE_CALL */) {\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n const flag = getPatchFlag(codegenNode);\r\n if (!flag) {\r\n let returnType = 3 /* CAN_STRINGIFY */;\r\n // Element itself has no patch flag. However we still need to check:\r\n // 1. Even for a node with no patch flag, it is possible for it to contain\r\n // non-hoistable expressions that refers to scope variables, e.g. compiler\r\n // injected keys or cached event handlers. Therefore we need to always\r\n // check the codegenNode's props to be sure.\r\n const generatedPropsType = getGeneratedPropsConstantType(node, context);\r\n if (generatedPropsType === 0 /* NOT_CONSTANT */) {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n if (generatedPropsType < returnType) {\r\n returnType = generatedPropsType;\r\n }\r\n // 2. its children.\r\n for (let i = 0; i < node.children.length; i++) {\r\n const childType = getConstantType(node.children[i], context);\r\n if (childType === 0 /* NOT_CONSTANT */) {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n if (childType < returnType) {\r\n returnType = childType;\r\n }\r\n }\r\n // 3. if the type is not already CAN_SKIP_PATCH which is the lowest non-0\r\n // type, check if any of the props can cause the type to be lowered\r\n // we can skip can_patch because it's guaranteed by the absence of a\r\n // patchFlag.\r\n if (returnType > 1 /* CAN_SKIP_PATCH */) {\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 7 /* DIRECTIVE */ && p.name === 'bind' && p.exp) {\r\n const expType = getConstantType(p.exp, context);\r\n if (expType === 0 /* NOT_CONSTANT */) {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n if (expType < returnType) {\r\n returnType = expType;\r\n }\r\n }\r\n }\r\n }\r\n // only svg/foreignObject could be block here, however if they are\r\n // static then they don't need to be blocks since there will be no\r\n // nested updates.\r\n if (codegenNode.isBlock) {\r\n context.removeHelper(OPEN_BLOCK);\r\n context.removeHelper(getVNodeBlockHelper(context.inSSR, codegenNode.isComponent));\r\n codegenNode.isBlock = false;\r\n context.helper(getVNodeHelper(context.inSSR, codegenNode.isComponent));\r\n }\r\n constantCache.set(node, returnType);\r\n return returnType;\r\n }\r\n else {\r\n constantCache.set(node, 0 /* NOT_CONSTANT */);\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n case 2 /* TEXT */:\r\n case 3 /* COMMENT */:\r\n return 3 /* CAN_STRINGIFY */;\r\n case 9 /* IF */:\r\n case 11 /* FOR */:\r\n case 10 /* IF_BRANCH */:\r\n return 0 /* NOT_CONSTANT */;\r\n case 5 /* INTERPOLATION */:\r\n case 12 /* TEXT_CALL */:\r\n return getConstantType(node.content, context);\r\n case 4 /* SIMPLE_EXPRESSION */:\r\n return node.constType;\r\n case 8 /* COMPOUND_EXPRESSION */:\r\n let returnType = 3 /* CAN_STRINGIFY */;\r\n for (let i = 0; i < node.children.length; i++) {\r\n const child = node.children[i];\r\n if (isString(child) || isSymbol(child)) {\r\n continue;\r\n }\r\n const childType = getConstantType(child, context);\r\n if (childType === 0 /* NOT_CONSTANT */) {\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n else if (childType < returnType) {\r\n returnType = childType;\r\n }\r\n }\r\n return returnType;\r\n default:\r\n if ((process.env.NODE_ENV !== 'production')) ;\r\n return 0 /* NOT_CONSTANT */;\r\n }\r\n}\r\nconst allowHoistedHelperSet = new Set([\r\n NORMALIZE_CLASS,\r\n NORMALIZE_STYLE,\r\n NORMALIZE_PROPS,\r\n GUARD_REACTIVE_PROPS\r\n]);\r\nfunction getConstantTypeOfHelperCall(value, context) {\r\n if (value.type === 14 /* JS_CALL_EXPRESSION */ &&\r\n !isString(value.callee) &&\r\n allowHoistedHelperSet.has(value.callee)) {\r\n const arg = value.arguments[0];\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n return getConstantType(arg, context);\r\n }\r\n else if (arg.type === 14 /* JS_CALL_EXPRESSION */) {\r\n // in the case of nested helper call, e.g. `normalizeProps(guardReactiveProps(exp))`\r\n return getConstantTypeOfHelperCall(arg, context);\r\n }\r\n }\r\n return 0 /* NOT_CONSTANT */;\r\n}\r\nfunction getGeneratedPropsConstantType(node, context) {\r\n let returnType = 3 /* CAN_STRINGIFY */;\r\n const props = getNodeProps(node);\r\n if (props && props.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n const { properties } = props;\r\n for (let i = 0; i < properties.length; i++) {\r\n const { key, value } = properties[i];\r\n const keyType = getConstantType(key, context);\r\n if (keyType === 0 /* NOT_CONSTANT */) {\r\n return keyType;\r\n }\r\n if (keyType < returnType) {\r\n returnType = keyType;\r\n }\r\n let valueType;\r\n if (value.type === 4 /* SIMPLE_EXPRESSION */) {\r\n valueType = getConstantType(value, context);\r\n }\r\n else if (value.type === 14 /* JS_CALL_EXPRESSION */) {\r\n // some helper calls can be hoisted,\r\n // such as the `normalizeProps` generated by the compiler for pre-normalize class,\r\n // in this case we need to respect the ConstantType of the helper's argments\r\n valueType = getConstantTypeOfHelperCall(value, context);\r\n }\r\n else {\r\n valueType = 0 /* NOT_CONSTANT */;\r\n }\r\n if (valueType === 0 /* NOT_CONSTANT */) {\r\n return valueType;\r\n }\r\n if (valueType < returnType) {\r\n returnType = valueType;\r\n }\r\n }\r\n }\r\n return returnType;\r\n}\r\nfunction getNodeProps(node) {\r\n const codegenNode = node.codegenNode;\r\n if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n return codegenNode.props;\r\n }\r\n}\r\nfunction getPatchFlag(node) {\r\n const flag = node.patchFlag;\r\n return flag ? parseInt(flag, 10) : undefined;\r\n}\n\nfunction createTransformContext(root, { filename = '', prefixIdentifiers = false, hoistStatic = false, cacheHandlers = false, nodeTransforms = [], directiveTransforms = {}, transformHoist = null, isBuiltInComponent = NOOP, isCustomElement = NOOP, expressionPlugins = [], scopeId = null, slotted = true, ssr = false, inSSR = false, ssrCssVars = ``, bindingMetadata = EMPTY_OBJ, inline = false, isTS = false, onError = defaultOnError, onWarn = defaultOnWarn, compatConfig }) {\r\n const nameMatch = filename.replace(/\\?.*$/, '').match(/([^/\\\\]+)\\.\\w+$/);\r\n const context = {\r\n // options\r\n selfName: nameMatch && capitalize(camelize$1(nameMatch[1])),\r\n prefixIdentifiers,\r\n hoistStatic,\r\n cacheHandlers,\r\n nodeTransforms,\r\n directiveTransforms,\r\n transformHoist,\r\n isBuiltInComponent,\r\n isCustomElement,\r\n expressionPlugins,\r\n scopeId,\r\n slotted,\r\n ssr,\r\n inSSR,\r\n ssrCssVars,\r\n bindingMetadata,\r\n inline,\r\n isTS,\r\n onError,\r\n onWarn,\r\n compatConfig,\r\n // state\r\n root,\r\n helpers: new Map(),\r\n components: new Set(),\r\n directives: new Set(),\r\n hoists: [],\r\n imports: [],\r\n constantCache: new Map(),\r\n temps: 0,\r\n cached: 0,\r\n identifiers: Object.create(null),\r\n scopes: {\r\n vFor: 0,\r\n vSlot: 0,\r\n vPre: 0,\r\n vOnce: 0\r\n },\r\n parent: null,\r\n currentNode: root,\r\n childIndex: 0,\r\n inVOnce: false,\r\n // methods\r\n helper(name) {\r\n const count = context.helpers.get(name) || 0;\r\n context.helpers.set(name, count + 1);\r\n return name;\r\n },\r\n removeHelper(name) {\r\n const count = context.helpers.get(name);\r\n if (count) {\r\n const currentCount = count - 1;\r\n if (!currentCount) {\r\n context.helpers.delete(name);\r\n }\r\n else {\r\n context.helpers.set(name, currentCount);\r\n }\r\n }\r\n },\r\n helperString(name) {\r\n return `_${helperNameMap[context.helper(name)]}`;\r\n },\r\n replaceNode(node) {\r\n /* istanbul ignore if */\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (!context.currentNode) {\r\n throw new Error(`Node being replaced is already removed.`);\r\n }\r\n if (!context.parent) {\r\n throw new Error(`Cannot replace root node.`);\r\n }\r\n }\r\n context.parent.children[context.childIndex] = context.currentNode = node;\r\n },\r\n removeNode(node) {\r\n if ((process.env.NODE_ENV !== 'production') && !context.parent) {\r\n throw new Error(`Cannot remove root node.`);\r\n }\r\n const list = context.parent.children;\r\n const removalIndex = node\r\n ? list.indexOf(node)\r\n : context.currentNode\r\n ? context.childIndex\r\n : -1;\r\n /* istanbul ignore if */\r\n if ((process.env.NODE_ENV !== 'production') && removalIndex < 0) {\r\n throw new Error(`node being removed is not a child of current parent`);\r\n }\r\n if (!node || node === context.currentNode) {\r\n // current node removed\r\n context.currentNode = null;\r\n context.onNodeRemoved();\r\n }\r\n else {\r\n // sibling node removed\r\n if (context.childIndex > removalIndex) {\r\n context.childIndex--;\r\n context.onNodeRemoved();\r\n }\r\n }\r\n context.parent.children.splice(removalIndex, 1);\r\n },\r\n onNodeRemoved: () => { },\r\n addIdentifiers(exp) {\r\n },\r\n removeIdentifiers(exp) {\r\n },\r\n hoist(exp) {\r\n if (isString(exp))\r\n exp = createSimpleExpression(exp);\r\n context.hoists.push(exp);\r\n const identifier = createSimpleExpression(`_hoisted_${context.hoists.length}`, false, exp.loc, 2 /* CAN_HOIST */);\r\n identifier.hoisted = exp;\r\n return identifier;\r\n },\r\n cache(exp, isVNode = false) {\r\n return createCacheExpression(context.cached++, exp, isVNode);\r\n }\r\n };\r\n {\r\n context.filters = new Set();\r\n }\r\n return context;\r\n}\r\nfunction transform(root, options) {\r\n const context = createTransformContext(root, options);\r\n traverseNode(root, context);\r\n if (options.hoistStatic) {\r\n hoistStatic(root, context);\r\n }\r\n if (!options.ssr) {\r\n createRootCodegen(root, context);\r\n }\r\n // finalize meta information\r\n root.helpers = [...context.helpers.keys()];\r\n root.components = [...context.components];\r\n root.directives = [...context.directives];\r\n root.imports = context.imports;\r\n root.hoists = context.hoists;\r\n root.temps = context.temps;\r\n root.cached = context.cached;\r\n {\r\n root.filters = [...context.filters];\r\n }\r\n}\r\nfunction createRootCodegen(root, context) {\r\n const { helper } = context;\r\n const { children } = root;\r\n if (children.length === 1) {\r\n const child = children[0];\r\n // if the single child is an element, turn it into a block.\r\n if (isSingleElementRoot(root, child) && child.codegenNode) {\r\n // single element root is never hoisted so codegenNode will never be\r\n // SimpleExpressionNode\r\n const codegenNode = child.codegenNode;\r\n if (codegenNode.type === 13 /* VNODE_CALL */) {\r\n makeBlock(codegenNode, context);\r\n }\r\n root.codegenNode = codegenNode;\r\n }\r\n else {\r\n // - single <slot/>, IfNode, ForNode: already blocks.\r\n // - single text node: always patched.\r\n // root codegen falls through via genNode()\r\n root.codegenNode = child;\r\n }\r\n }\r\n else if (children.length > 1) {\r\n // root has multiple nodes - return a fragment block.\r\n let patchFlag = 64 /* STABLE_FRAGMENT */;\r\n let patchFlagText = PatchFlagNames[64 /* STABLE_FRAGMENT */];\r\n // check if the fragment actually contains a single valid child with\r\n // the rest being comments\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n children.filter(c => c.type !== 3 /* COMMENT */).length === 1) {\r\n patchFlag |= 2048 /* DEV_ROOT_FRAGMENT */;\r\n patchFlagText += `, ${PatchFlagNames[2048 /* DEV_ROOT_FRAGMENT */]}`;\r\n }\r\n root.codegenNode = createVNodeCall(context, helper(FRAGMENT), undefined, root.children, patchFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${patchFlagText} */` : ``), undefined, undefined, true, undefined, false /* isComponent */);\r\n }\r\n else ;\r\n}\r\nfunction traverseChildren(parent, context) {\r\n let i = 0;\r\n const nodeRemoved = () => {\r\n i--;\r\n };\r\n for (; i < parent.children.length; i++) {\r\n const child = parent.children[i];\r\n if (isString(child))\r\n continue;\r\n context.parent = parent;\r\n context.childIndex = i;\r\n context.onNodeRemoved = nodeRemoved;\r\n traverseNode(child, context);\r\n }\r\n}\r\nfunction traverseNode(node, context) {\r\n context.currentNode = node;\r\n // apply transform plugins\r\n const { nodeTransforms } = context;\r\n const exitFns = [];\r\n for (let i = 0; i < nodeTransforms.length; i++) {\r\n const onExit = nodeTransforms[i](node, context);\r\n if (onExit) {\r\n if (isArray(onExit)) {\r\n exitFns.push(...onExit);\r\n }\r\n else {\r\n exitFns.push(onExit);\r\n }\r\n }\r\n if (!context.currentNode) {\r\n // node was removed\r\n return;\r\n }\r\n else {\r\n // node may have been replaced\r\n node = context.currentNode;\r\n }\r\n }\r\n switch (node.type) {\r\n case 3 /* COMMENT */:\r\n if (!context.ssr) {\r\n // inject import for the Comment symbol, which is needed for creating\r\n // comment nodes with `createVNode`\r\n context.helper(CREATE_COMMENT);\r\n }\r\n break;\r\n case 5 /* INTERPOLATION */:\r\n // no need to traverse, but we need to inject toString helper\r\n if (!context.ssr) {\r\n context.helper(TO_DISPLAY_STRING);\r\n }\r\n break;\r\n // for container types, further traverse downwards\r\n case 9 /* IF */:\r\n for (let i = 0; i < node.branches.length; i++) {\r\n traverseNode(node.branches[i], context);\r\n }\r\n break;\r\n case 10 /* IF_BRANCH */:\r\n case 11 /* FOR */:\r\n case 1 /* ELEMENT */:\r\n case 0 /* ROOT */:\r\n traverseChildren(node, context);\r\n break;\r\n }\r\n // exit transforms\r\n context.currentNode = node;\r\n let i = exitFns.length;\r\n while (i--) {\r\n exitFns[i]();\r\n }\r\n}\r\nfunction createStructuralDirectiveTransform(name, fn) {\r\n const matches = isString(name)\r\n ? (n) => n === name\r\n : (n) => name.test(n);\r\n return (node, context) => {\r\n if (node.type === 1 /* ELEMENT */) {\r\n const { props } = node;\r\n // structural directive transforms are not concerned with slots\r\n // as they are handled separately in vSlot.ts\r\n if (node.tagType === 3 /* TEMPLATE */ && props.some(isVSlot)) {\r\n return;\r\n }\r\n const exitFns = [];\r\n for (let i = 0; i < props.length; i++) {\r\n const prop = props[i];\r\n if (prop.type === 7 /* DIRECTIVE */ && matches(prop.name)) {\r\n // structural directives are removed to avoid infinite recursion\r\n // also we remove them *before* applying so that it can further\r\n // traverse itself in case it moves the node around\r\n props.splice(i, 1);\r\n i--;\r\n const onExit = fn(node, prop, context);\r\n if (onExit)\r\n exitFns.push(onExit);\r\n }\r\n }\r\n return exitFns;\r\n }\r\n };\r\n}\n\nconst PURE_ANNOTATION = `/*#__PURE__*/`;\r\nfunction createCodegenContext(ast, { mode = 'function', prefixIdentifiers = mode === 'module', sourceMap = false, filename = `template.vue.html`, scopeId = null, optimizeImports = false, runtimeGlobalName = `Vue`, runtimeModuleName = `vue`, ssrRuntimeModuleName = 'vue/server-renderer', ssr = false, isTS = false, inSSR = false }) {\r\n const context = {\r\n mode,\r\n prefixIdentifiers,\r\n sourceMap,\r\n filename,\r\n scopeId,\r\n optimizeImports,\r\n runtimeGlobalName,\r\n runtimeModuleName,\r\n ssrRuntimeModuleName,\r\n ssr,\r\n isTS,\r\n inSSR,\r\n source: ast.loc.source,\r\n code: ``,\r\n column: 1,\r\n line: 1,\r\n offset: 0,\r\n indentLevel: 0,\r\n pure: false,\r\n map: undefined,\r\n helper(key) {\r\n return `_${helperNameMap[key]}`;\r\n },\r\n push(code, node) {\r\n context.code += code;\r\n },\r\n indent() {\r\n newline(++context.indentLevel);\r\n },\r\n deindent(withoutNewLine = false) {\r\n if (withoutNewLine) {\r\n --context.indentLevel;\r\n }\r\n else {\r\n newline(--context.indentLevel);\r\n }\r\n },\r\n newline() {\r\n newline(context.indentLevel);\r\n }\r\n };\r\n function newline(n) {\r\n context.push('\\n' + ` `.repeat(n));\r\n }\r\n return context;\r\n}\r\nfunction generate(ast, options = {}) {\r\n const context = createCodegenContext(ast, options);\r\n if (options.onContextCreated)\r\n options.onContextCreated(context);\r\n const { mode, push, prefixIdentifiers, indent, deindent, newline, scopeId, ssr } = context;\r\n const hasHelpers = ast.helpers.length > 0;\r\n const useWithBlock = !prefixIdentifiers && mode !== 'module';\r\n // preambles\r\n // in setup() inline mode, the preamble is generated in a sub context\r\n // and returned separately.\r\n const preambleContext = context;\r\n {\r\n genFunctionPreamble(ast, preambleContext);\r\n }\r\n // enter render function\r\n const functionName = ssr ? `ssrRender` : `render`;\r\n const args = ssr ? ['_ctx', '_push', '_parent', '_attrs'] : ['_ctx', '_cache'];\r\n const signature = args.join(', ');\r\n {\r\n push(`function ${functionName}(${signature}) {`);\r\n }\r\n indent();\r\n if (useWithBlock) {\r\n push(`with (_ctx) {`);\r\n indent();\r\n // function mode const declarations should be inside with block\r\n // also they should be renamed to avoid collision with user properties\r\n if (hasHelpers) {\r\n push(`const { ${ast.helpers\r\n .map(s => `${helperNameMap[s]}: _${helperNameMap[s]}`)\r\n .join(', ')} } = _Vue`);\r\n push(`\\n`);\r\n newline();\r\n }\r\n }\r\n // generate asset resolution statements\r\n if (ast.components.length) {\r\n genAssets(ast.components, 'component', context);\r\n if (ast.directives.length || ast.temps > 0) {\r\n newline();\r\n }\r\n }\r\n if (ast.directives.length) {\r\n genAssets(ast.directives, 'directive', context);\r\n if (ast.temps > 0) {\r\n newline();\r\n }\r\n }\r\n if (ast.filters && ast.filters.length) {\r\n newline();\r\n genAssets(ast.filters, 'filter', context);\r\n newline();\r\n }\r\n if (ast.temps > 0) {\r\n push(`let `);\r\n for (let i = 0; i < ast.temps; i++) {\r\n push(`${i > 0 ? `, ` : ``}_temp${i}`);\r\n }\r\n }\r\n if (ast.components.length || ast.directives.length || ast.temps) {\r\n push(`\\n`);\r\n newline();\r\n }\r\n // generate the VNode tree expression\r\n if (!ssr) {\r\n push(`return `);\r\n }\r\n if (ast.codegenNode) {\r\n genNode(ast.codegenNode, context);\r\n }\r\n else {\r\n push(`null`);\r\n }\r\n if (useWithBlock) {\r\n deindent();\r\n push(`}`);\r\n }\r\n deindent();\r\n push(`}`);\r\n return {\r\n ast,\r\n code: context.code,\r\n preamble: ``,\r\n // SourceMapGenerator does have toJSON() method but it's not in the types\r\n map: context.map ? context.map.toJSON() : undefined\r\n };\r\n}\r\nfunction genFunctionPreamble(ast, context) {\r\n const { ssr, prefixIdentifiers, push, newline, runtimeModuleName, runtimeGlobalName, ssrRuntimeModuleName } = context;\r\n const VueBinding = runtimeGlobalName;\r\n const aliasHelper = (s) => `${helperNameMap[s]}: _${helperNameMap[s]}`;\r\n // Generate const declaration for helpers\r\n // In prefix mode, we place the const declaration at top so it's done\r\n // only once; But if we not prefixing, we place the declaration inside the\r\n // with block so it doesn't incur the `in` check cost for every helper access.\r\n if (ast.helpers.length > 0) {\r\n {\r\n // \"with\" mode.\r\n // save Vue in a separate variable to avoid collision\r\n push(`const _Vue = ${VueBinding}\\n`);\r\n // in \"with\" mode, helpers are declared inside the with block to avoid\r\n // has check cost, but hoists are lifted out of the function - we need\r\n // to provide the helper here.\r\n if (ast.hoists.length) {\r\n const staticHelpers = [\r\n CREATE_VNODE,\r\n CREATE_ELEMENT_VNODE,\r\n CREATE_COMMENT,\r\n CREATE_TEXT,\r\n CREATE_STATIC\r\n ]\r\n .filter(helper => ast.helpers.includes(helper))\r\n .map(aliasHelper)\r\n .join(', ');\r\n push(`const { ${staticHelpers} } = _Vue\\n`);\r\n }\r\n }\r\n }\r\n genHoists(ast.hoists, context);\r\n newline();\r\n push(`return `);\r\n}\r\nfunction genAssets(assets, type, { helper, push, newline, isTS }) {\r\n const resolver = helper(type === 'filter'\r\n ? RESOLVE_FILTER\r\n : type === 'component'\r\n ? RESOLVE_COMPONENT\r\n : RESOLVE_DIRECTIVE);\r\n for (let i = 0; i < assets.length; i++) {\r\n let id = assets[i];\r\n // potential component implicit self-reference inferred from SFC filename\r\n const maybeSelfReference = id.endsWith('__self');\r\n if (maybeSelfReference) {\r\n id = id.slice(0, -6);\r\n }\r\n push(`const ${toValidAssetId(id, type)} = ${resolver}(${JSON.stringify(id)}${maybeSelfReference ? `, true` : ``})${isTS ? `!` : ``}`);\r\n if (i < assets.length - 1) {\r\n newline();\r\n }\r\n }\r\n}\r\nfunction genHoists(hoists, context) {\r\n if (!hoists.length) {\r\n return;\r\n }\r\n context.pure = true;\r\n const { push, newline, helper, scopeId, mode } = context;\r\n newline();\r\n for (let i = 0; i < hoists.length; i++) {\r\n const exp = hoists[i];\r\n if (exp) {\r\n push(`const _hoisted_${i + 1} = ${``}`);\r\n genNode(exp, context);\r\n newline();\r\n }\r\n }\r\n context.pure = false;\r\n}\r\nfunction isText$1(n) {\r\n return (isString(n) ||\r\n n.type === 4 /* SIMPLE_EXPRESSION */ ||\r\n n.type === 2 /* TEXT */ ||\r\n n.type === 5 /* INTERPOLATION */ ||\r\n n.type === 8 /* COMPOUND_EXPRESSION */);\r\n}\r\nfunction genNodeListAsArray(nodes, context) {\r\n const multilines = nodes.length > 3 ||\r\n (((process.env.NODE_ENV !== 'production')) && nodes.some(n => isArray(n) || !isText$1(n)));\r\n context.push(`[`);\r\n multilines && context.indent();\r\n genNodeList(nodes, context, multilines);\r\n multilines && context.deindent();\r\n context.push(`]`);\r\n}\r\nfunction genNodeList(nodes, context, multilines = false, comma = true) {\r\n const { push, newline } = context;\r\n for (let i = 0; i < nodes.length; i++) {\r\n const node = nodes[i];\r\n if (isString(node)) {\r\n push(node);\r\n }\r\n else if (isArray(node)) {\r\n genNodeListAsArray(node, context);\r\n }\r\n else {\r\n genNode(node, context);\r\n }\r\n if (i < nodes.length - 1) {\r\n if (multilines) {\r\n comma && push(',');\r\n newline();\r\n }\r\n else {\r\n comma && push(', ');\r\n }\r\n }\r\n }\r\n}\r\nfunction genNode(node, context) {\r\n if (isString(node)) {\r\n context.push(node);\r\n return;\r\n }\r\n if (isSymbol(node)) {\r\n context.push(context.helper(node));\r\n return;\r\n }\r\n switch (node.type) {\r\n case 1 /* ELEMENT */:\r\n case 9 /* IF */:\r\n case 11 /* FOR */:\r\n (process.env.NODE_ENV !== 'production') &&\r\n assert(node.codegenNode != null, `Codegen node is missing for element/if/for node. ` +\r\n `Apply appropriate transforms first.`);\r\n genNode(node.codegenNode, context);\r\n break;\r\n case 2 /* TEXT */:\r\n genText(node, context);\r\n break;\r\n case 4 /* SIMPLE_EXPRESSION */:\r\n genExpression(node, context);\r\n break;\r\n case 5 /* INTERPOLATION */:\r\n genInterpolation(node, context);\r\n break;\r\n case 12 /* TEXT_CALL */:\r\n genNode(node.codegenNode, context);\r\n break;\r\n case 8 /* COMPOUND_EXPRESSION */:\r\n genCompoundExpression(node, context);\r\n break;\r\n case 3 /* COMMENT */:\r\n genComment(node, context);\r\n break;\r\n case 13 /* VNODE_CALL */:\r\n genVNodeCall(node, context);\r\n break;\r\n case 14 /* JS_CALL_EXPRESSION */:\r\n genCallExpression(node, context);\r\n break;\r\n case 15 /* JS_OBJECT_EXPRESSION */:\r\n genObjectExpression(node, context);\r\n break;\r\n case 17 /* JS_ARRAY_EXPRESSION */:\r\n genArrayExpression(node, context);\r\n break;\r\n case 18 /* JS_FUNCTION_EXPRESSION */:\r\n genFunctionExpression(node, context);\r\n break;\r\n case 19 /* JS_CONDITIONAL_EXPRESSION */:\r\n genConditionalExpression(node, context);\r\n break;\r\n case 20 /* JS_CACHE_EXPRESSION */:\r\n genCacheExpression(node, context);\r\n break;\r\n case 21 /* JS_BLOCK_STATEMENT */:\r\n genNodeList(node.body, context, true, false);\r\n break;\r\n // SSR only types\r\n case 22 /* JS_TEMPLATE_LITERAL */:\r\n break;\r\n case 23 /* JS_IF_STATEMENT */:\r\n break;\r\n case 24 /* JS_ASSIGNMENT_EXPRESSION */:\r\n break;\r\n case 25 /* JS_SEQUENCE_EXPRESSION */:\r\n break;\r\n case 26 /* JS_RETURN_STATEMENT */:\r\n break;\r\n /* istanbul ignore next */\r\n case 10 /* IF_BRANCH */:\r\n // noop\r\n break;\r\n default:\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n assert(false, `unhandled codegen node type: ${node.type}`);\r\n // make sure we exhaust all possible types\r\n const exhaustiveCheck = node;\r\n return exhaustiveCheck;\r\n }\r\n }\r\n}\r\nfunction genText(node, context) {\r\n context.push(JSON.stringify(node.content), node);\r\n}\r\nfunction genExpression(node, context) {\r\n const { content, isStatic } = node;\r\n context.push(isStatic ? JSON.stringify(content) : content, node);\r\n}\r\nfunction genInterpolation(node, context) {\r\n const { push, helper, pure } = context;\r\n if (pure)\r\n push(PURE_ANNOTATION);\r\n push(`${helper(TO_DISPLAY_STRING)}(`);\r\n genNode(node.content, context);\r\n push(`)`);\r\n}\r\nfunction genCompoundExpression(node, context) {\r\n for (let i = 0; i < node.children.length; i++) {\r\n const child = node.children[i];\r\n if (isString(child)) {\r\n context.push(child);\r\n }\r\n else {\r\n genNode(child, context);\r\n }\r\n }\r\n}\r\nfunction genExpressionAsPropertyKey(node, context) {\r\n const { push } = context;\r\n if (node.type === 8 /* COMPOUND_EXPRESSION */) {\r\n push(`[`);\r\n genCompoundExpression(node, context);\r\n push(`]`);\r\n }\r\n else if (node.isStatic) {\r\n // only quote keys if necessary\r\n const text = isSimpleIdentifier(node.content)\r\n ? node.content\r\n : JSON.stringify(node.content);\r\n push(text, node);\r\n }\r\n else {\r\n push(`[${node.content}]`, node);\r\n }\r\n}\r\nfunction genComment(node, context) {\r\n const { push, helper, pure } = context;\r\n if (pure) {\r\n push(PURE_ANNOTATION);\r\n }\r\n push(`${helper(CREATE_COMMENT)}(${JSON.stringify(node.content)})`, node);\r\n}\r\nfunction genVNodeCall(node, context) {\r\n const { push, helper, pure } = context;\r\n const { tag, props, children, patchFlag, dynamicProps, directives, isBlock, disableTracking, isComponent } = node;\r\n if (directives) {\r\n push(helper(WITH_DIRECTIVES) + `(`);\r\n }\r\n if (isBlock) {\r\n push(`(${helper(OPEN_BLOCK)}(${disableTracking ? `true` : ``}), `);\r\n }\r\n if (pure) {\r\n push(PURE_ANNOTATION);\r\n }\r\n const callHelper = isBlock\r\n ? getVNodeBlockHelper(context.inSSR, isComponent)\r\n : getVNodeHelper(context.inSSR, isComponent);\r\n push(helper(callHelper) + `(`, node);\r\n genNodeList(genNullableArgs([tag, props, children, patchFlag, dynamicProps]), context);\r\n push(`)`);\r\n if (isBlock) {\r\n push(`)`);\r\n }\r\n if (directives) {\r\n push(`, `);\r\n genNode(directives, context);\r\n push(`)`);\r\n }\r\n}\r\nfunction genNullableArgs(args) {\r\n let i = args.length;\r\n while (i--) {\r\n if (args[i] != null)\r\n break;\r\n }\r\n return args.slice(0, i + 1).map(arg => arg || `null`);\r\n}\r\n// JavaScript\r\nfunction genCallExpression(node, context) {\r\n const { push, helper, pure } = context;\r\n const callee = isString(node.callee) ? node.callee : helper(node.callee);\r\n if (pure) {\r\n push(PURE_ANNOTATION);\r\n }\r\n push(callee + `(`, node);\r\n genNodeList(node.arguments, context);\r\n push(`)`);\r\n}\r\nfunction genObjectExpression(node, context) {\r\n const { push, indent, deindent, newline } = context;\r\n const { properties } = node;\r\n if (!properties.length) {\r\n push(`{}`, node);\r\n return;\r\n }\r\n const multilines = properties.length > 1 ||\r\n (((process.env.NODE_ENV !== 'production')) &&\r\n properties.some(p => p.value.type !== 4 /* SIMPLE_EXPRESSION */));\r\n push(multilines ? `{` : `{ `);\r\n multilines && indent();\r\n for (let i = 0; i < properties.length; i++) {\r\n const { key, value } = properties[i];\r\n // key\r\n genExpressionAsPropertyKey(key, context);\r\n push(`: `);\r\n // value\r\n genNode(value, context);\r\n if (i < properties.length - 1) {\r\n // will only reach this if it's multilines\r\n push(`,`);\r\n newline();\r\n }\r\n }\r\n multilines && deindent();\r\n push(multilines ? `}` : ` }`);\r\n}\r\nfunction genArrayExpression(node, context) {\r\n genNodeListAsArray(node.elements, context);\r\n}\r\nfunction genFunctionExpression(node, context) {\r\n const { push, indent, deindent } = context;\r\n const { params, returns, body, newline, isSlot } = node;\r\n if (isSlot) {\r\n // wrap slot functions with owner context\r\n push(`_${helperNameMap[WITH_CTX]}(`);\r\n }\r\n push(`(`, node);\r\n if (isArray(params)) {\r\n genNodeList(params, context);\r\n }\r\n else if (params) {\r\n genNode(params, context);\r\n }\r\n push(`) => `);\r\n if (newline || body) {\r\n push(`{`);\r\n indent();\r\n }\r\n if (returns) {\r\n if (newline) {\r\n push(`return `);\r\n }\r\n if (isArray(returns)) {\r\n genNodeListAsArray(returns, context);\r\n }\r\n else {\r\n genNode(returns, context);\r\n }\r\n }\r\n else if (body) {\r\n genNode(body, context);\r\n }\r\n if (newline || body) {\r\n deindent();\r\n push(`}`);\r\n }\r\n if (isSlot) {\r\n if (node.isNonScopedSlot) {\r\n push(`, undefined, true`);\r\n }\r\n push(`)`);\r\n }\r\n}\r\nfunction genConditionalExpression(node, context) {\r\n const { test, consequent, alternate, newline: needNewline } = node;\r\n const { push, indent, deindent, newline } = context;\r\n if (test.type === 4 /* SIMPLE_EXPRESSION */) {\r\n const needsParens = !isSimpleIdentifier(test.content);\r\n needsParens && push(`(`);\r\n genExpression(test, context);\r\n needsParens && push(`)`);\r\n }\r\n else {\r\n push(`(`);\r\n genNode(test, context);\r\n push(`)`);\r\n }\r\n needNewline && indent();\r\n context.indentLevel++;\r\n needNewline || push(` `);\r\n push(`? `);\r\n genNode(consequent, context);\r\n context.indentLevel--;\r\n needNewline && newline();\r\n needNewline || push(` `);\r\n push(`: `);\r\n const isNested = alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */;\r\n if (!isNested) {\r\n context.indentLevel++;\r\n }\r\n genNode(alternate, context);\r\n if (!isNested) {\r\n context.indentLevel--;\r\n }\r\n needNewline && deindent(true /* without newline */);\r\n}\r\nfunction genCacheExpression(node, context) {\r\n const { push, helper, indent, deindent, newline } = context;\r\n push(`_cache[${node.index}] || (`);\r\n if (node.isVNode) {\r\n indent();\r\n push(`${helper(SET_BLOCK_TRACKING)}(-1),`);\r\n newline();\r\n }\r\n push(`_cache[${node.index}] = `);\r\n genNode(node.value, context);\r\n if (node.isVNode) {\r\n push(`,`);\r\n newline();\r\n push(`${helper(SET_BLOCK_TRACKING)}(1),`);\r\n newline();\r\n push(`_cache[${node.index}]`);\r\n deindent();\r\n }\r\n push(`)`);\r\n}\n\nfunction walkIdentifiers(root, onIdentifier, includeAll = false, parentStack = [], knownIds = Object.create(null)) {\r\n {\r\n return;\r\n }\r\n}\r\nfunction isReferencedIdentifier(id, parent, parentStack) {\r\n {\r\n return false;\r\n }\r\n}\r\nfunction isInDestructureAssignment(parent, parentStack) {\r\n if (parent &&\r\n (parent.type === 'ObjectProperty' || parent.type === 'ArrayPattern')) {\r\n let i = parentStack.length;\r\n while (i--) {\r\n const p = parentStack[i];\r\n if (p.type === 'AssignmentExpression') {\r\n return true;\r\n }\r\n else if (p.type !== 'ObjectProperty' && !p.type.endsWith('Pattern')) {\r\n break;\r\n }\r\n }\r\n }\r\n return false;\r\n}\r\nfunction walkFunctionParams(node, onIdent) {\r\n for (const p of node.params) {\r\n for (const id of extractIdentifiers(p)) {\r\n onIdent(id);\r\n }\r\n }\r\n}\r\nfunction walkBlockDeclarations(block, onIdent) {\r\n for (const stmt of block.body) {\r\n if (stmt.type === 'VariableDeclaration') {\r\n if (stmt.declare)\r\n continue;\r\n for (const decl of stmt.declarations) {\r\n for (const id of extractIdentifiers(decl.id)) {\r\n onIdent(id);\r\n }\r\n }\r\n }\r\n else if (stmt.type === 'FunctionDeclaration' ||\r\n stmt.type === 'ClassDeclaration') {\r\n if (stmt.declare || !stmt.id)\r\n continue;\r\n onIdent(stmt.id);\r\n }\r\n }\r\n}\r\nfunction extractIdentifiers(param, nodes = []) {\r\n switch (param.type) {\r\n case 'Identifier':\r\n nodes.push(param);\r\n break;\r\n case 'MemberExpression':\r\n let object = param;\r\n while (object.type === 'MemberExpression') {\r\n object = object.object;\r\n }\r\n nodes.push(object);\r\n break;\r\n case 'ObjectPattern':\r\n for (const prop of param.properties) {\r\n if (prop.type === 'RestElement') {\r\n extractIdentifiers(prop.argument, nodes);\r\n }\r\n else {\r\n extractIdentifiers(prop.value, nodes);\r\n }\r\n }\r\n break;\r\n case 'ArrayPattern':\r\n param.elements.forEach(element => {\r\n if (element)\r\n extractIdentifiers(element, nodes);\r\n });\r\n break;\r\n case 'RestElement':\r\n extractIdentifiers(param.argument, nodes);\r\n break;\r\n case 'AssignmentPattern':\r\n extractIdentifiers(param.left, nodes);\r\n break;\r\n }\r\n return nodes;\r\n}\r\nconst isFunctionType = (node) => {\r\n return /Function(?:Expression|Declaration)$|Method$/.test(node.type);\r\n};\r\nconst isStaticProperty = (node) => node &&\r\n (node.type === 'ObjectProperty' || node.type === 'ObjectMethod') &&\r\n !node.computed;\r\nconst isStaticPropertyKey = (node, parent) => isStaticProperty(parent) && parent.key === node;\n\n// these keywords should not appear inside expressions, but operators like\r\n// typeof, instanceof and in are allowed\r\nconst prohibitedKeywordRE = new RegExp('\\\\b' +\r\n ('do,if,for,let,new,try,var,case,else,with,await,break,catch,class,const,' +\r\n 'super,throw,while,yield,delete,export,import,return,switch,default,' +\r\n 'extends,finally,continue,debugger,function,arguments,typeof,void')\r\n .split(',')\r\n .join('\\\\b|\\\\b') +\r\n '\\\\b');\r\n// strip strings in expressions\r\nconst stripStringRE = /'(?:[^'\\\\]|\\\\.)*'|\"(?:[^\"\\\\]|\\\\.)*\"|`(?:[^`\\\\]|\\\\.)*\\$\\{|\\}(?:[^`\\\\]|\\\\.)*`|`(?:[^`\\\\]|\\\\.)*`/g;\r\n/**\r\n * Validate a non-prefixed expression.\r\n * This is only called when using the in-browser runtime compiler since it\r\n * doesn't prefix expressions.\r\n */\r\nfunction validateBrowserExpression(node, context, asParams = false, asRawStatements = false) {\r\n const exp = node.content;\r\n // empty expressions are validated per-directive since some directives\r\n // do allow empty expressions.\r\n if (!exp.trim()) {\r\n return;\r\n }\r\n try {\r\n new Function(asRawStatements\r\n ? ` ${exp} `\r\n : `return ${asParams ? `(${exp}) => {}` : `(${exp})`}`);\r\n }\r\n catch (e) {\r\n let message = e.message;\r\n const keywordMatch = exp\r\n .replace(stripStringRE, '')\r\n .match(prohibitedKeywordRE);\r\n if (keywordMatch) {\r\n message = `avoid using JavaScript keyword as property name: \"${keywordMatch[0]}\"`;\r\n }\r\n context.onError(createCompilerError(44 /* X_INVALID_EXPRESSION */, node.loc, undefined, message));\r\n }\r\n}\n\nconst transformExpression = (node, context) => {\r\n if (node.type === 5 /* INTERPOLATION */) {\r\n node.content = processExpression(node.content, context);\r\n }\r\n else if (node.type === 1 /* ELEMENT */) {\r\n // handle directives on element\r\n for (let i = 0; i < node.props.length; i++) {\r\n const dir = node.props[i];\r\n // do not process for v-on & v-for since they are special handled\r\n if (dir.type === 7 /* DIRECTIVE */ && dir.name !== 'for') {\r\n const exp = dir.exp;\r\n const arg = dir.arg;\r\n // do not process exp if this is v-on:arg - we need special handling\r\n // for wrapping inline statements.\r\n if (exp &&\r\n exp.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n !(dir.name === 'on' && arg)) {\r\n dir.exp = processExpression(exp, context, \r\n // slot args must be processed as function params\r\n dir.name === 'slot');\r\n }\r\n if (arg && arg.type === 4 /* SIMPLE_EXPRESSION */ && !arg.isStatic) {\r\n dir.arg = processExpression(arg, context);\r\n }\r\n }\r\n }\r\n }\r\n};\r\n// Important: since this function uses Node.js only dependencies, it should\r\n// always be used with a leading !true check so that it can be\r\n// tree-shaken from the browser build.\r\nfunction processExpression(node, context, \r\n// some expressions like v-slot props & v-for aliases should be parsed as\r\n// function params\r\nasParams = false, \r\n// v-on handler values may contain multiple statements\r\nasRawStatements = false, localVars = Object.create(context.identifiers)) {\r\n {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n // simple in-browser validation (same logic in 2.x)\r\n validateBrowserExpression(node, context, asParams, asRawStatements);\r\n }\r\n return node;\r\n }\r\n}\n\nconst transformIf = createStructuralDirectiveTransform(/^(if|else|else-if)$/, (node, dir, context) => {\r\n return processIf(node, dir, context, (ifNode, branch, isRoot) => {\r\n // #1587: We need to dynamically increment the key based on the current\r\n // node's sibling nodes, since chained v-if/else branches are\r\n // rendered at the same depth\r\n const siblings = context.parent.children;\r\n let i = siblings.indexOf(ifNode);\r\n let key = 0;\r\n while (i-- >= 0) {\r\n const sibling = siblings[i];\r\n if (sibling && sibling.type === 9 /* IF */) {\r\n key += sibling.branches.length;\r\n }\r\n }\r\n // Exit callback. Complete the codegenNode when all children have been\r\n // transformed.\r\n return () => {\r\n if (isRoot) {\r\n ifNode.codegenNode = createCodegenNodeForBranch(branch, key, context);\r\n }\r\n else {\r\n // attach this branch's codegen node to the v-if root.\r\n const parentCondition = getParentCondition(ifNode.codegenNode);\r\n parentCondition.alternate = createCodegenNodeForBranch(branch, key + ifNode.branches.length - 1, context);\r\n }\r\n };\r\n });\r\n});\r\n// target-agnostic transform used for both Client and SSR\r\nfunction processIf(node, dir, context, processCodegen) {\r\n if (dir.name !== 'else' &&\r\n (!dir.exp || !dir.exp.content.trim())) {\r\n const loc = dir.exp ? dir.exp.loc : node.loc;\r\n context.onError(createCompilerError(28 /* X_V_IF_NO_EXPRESSION */, dir.loc));\r\n dir.exp = createSimpleExpression(`true`, false, loc);\r\n }\r\n if ((process.env.NODE_ENV !== 'production') && true && dir.exp) {\r\n validateBrowserExpression(dir.exp, context);\r\n }\r\n if (dir.name === 'if') {\r\n const branch = createIfBranch(node, dir);\r\n const ifNode = {\r\n type: 9 /* IF */,\r\n loc: node.loc,\r\n branches: [branch]\r\n };\r\n context.replaceNode(ifNode);\r\n if (processCodegen) {\r\n return processCodegen(ifNode, branch, true);\r\n }\r\n }\r\n else {\r\n // locate the adjacent v-if\r\n const siblings = context.parent.children;\r\n const comments = [];\r\n let i = siblings.indexOf(node);\r\n while (i-- >= -1) {\r\n const sibling = siblings[i];\r\n if ((process.env.NODE_ENV !== 'production') && sibling && sibling.type === 3 /* COMMENT */) {\r\n context.removeNode(sibling);\r\n comments.unshift(sibling);\r\n continue;\r\n }\r\n if (sibling &&\r\n sibling.type === 2 /* TEXT */ &&\r\n !sibling.content.trim().length) {\r\n context.removeNode(sibling);\r\n continue;\r\n }\r\n if (sibling && sibling.type === 9 /* IF */) {\r\n // Check if v-else was followed by v-else-if\r\n if (dir.name === 'else-if' &&\r\n sibling.branches[sibling.branches.length - 1].condition === undefined) {\r\n context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, node.loc));\r\n }\r\n // move the node to the if node's branches\r\n context.removeNode();\r\n const branch = createIfBranch(node, dir);\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n comments.length &&\r\n // #3619 ignore comments if the v-if is direct child of <transition>\r\n !(context.parent &&\r\n context.parent.type === 1 /* ELEMENT */ &&\r\n isBuiltInType(context.parent.tag, 'transition'))) {\r\n branch.children = [...comments, ...branch.children];\r\n }\r\n // check if user is forcing same key on different branches\r\n if ((process.env.NODE_ENV !== 'production') || !true) {\r\n const key = branch.userKey;\r\n if (key) {\r\n sibling.branches.forEach(({ userKey }) => {\r\n if (isSameKey(userKey, key)) {\r\n context.onError(createCompilerError(29 /* X_V_IF_SAME_KEY */, branch.userKey.loc));\r\n }\r\n });\r\n }\r\n }\r\n sibling.branches.push(branch);\r\n const onExit = processCodegen && processCodegen(sibling, branch, false);\r\n // since the branch was removed, it will not be traversed.\r\n // make sure to traverse here.\r\n traverseNode(branch, context);\r\n // call on exit\r\n if (onExit)\r\n onExit();\r\n // make sure to reset currentNode after traversal to indicate this\r\n // node has been removed.\r\n context.currentNode = null;\r\n }\r\n else {\r\n context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, node.loc));\r\n }\r\n break;\r\n }\r\n }\r\n}\r\nfunction createIfBranch(node, dir) {\r\n return {\r\n type: 10 /* IF_BRANCH */,\r\n loc: node.loc,\r\n condition: dir.name === 'else' ? undefined : dir.exp,\r\n children: node.tagType === 3 /* TEMPLATE */ && !findDir(node, 'for')\r\n ? node.children\r\n : [node],\r\n userKey: findProp(node, `key`)\r\n };\r\n}\r\nfunction createCodegenNodeForBranch(branch, keyIndex, context) {\r\n if (branch.condition) {\r\n return createConditionalExpression(branch.condition, createChildrenCodegenNode(branch, keyIndex, context), \r\n // make sure to pass in asBlock: true so that the comment node call\r\n // closes the current block.\r\n createCallExpression(context.helper(CREATE_COMMENT), [\r\n (process.env.NODE_ENV !== 'production') ? '\"v-if\"' : '\"\"',\r\n 'true'\r\n ]));\r\n }\r\n else {\r\n return createChildrenCodegenNode(branch, keyIndex, context);\r\n }\r\n}\r\nfunction createChildrenCodegenNode(branch, keyIndex, context) {\r\n const { helper } = context;\r\n const keyProperty = createObjectProperty(`key`, createSimpleExpression(`${keyIndex}`, false, locStub, 2 /* CAN_HOIST */));\r\n const { children } = branch;\r\n const firstChild = children[0];\r\n const needFragmentWrapper = children.length !== 1 || firstChild.type !== 1 /* ELEMENT */;\r\n if (needFragmentWrapper) {\r\n if (children.length === 1 && firstChild.type === 11 /* FOR */) {\r\n // optimize away nested fragments when child is a ForNode\r\n const vnodeCall = firstChild.codegenNode;\r\n injectProp(vnodeCall, keyProperty, context);\r\n return vnodeCall;\r\n }\r\n else {\r\n let patchFlag = 64 /* STABLE_FRAGMENT */;\r\n let patchFlagText = PatchFlagNames[64 /* STABLE_FRAGMENT */];\r\n // check if the fragment actually contains a single valid child with\r\n // the rest being comments\r\n if ((process.env.NODE_ENV !== 'production') &&\r\n children.filter(c => c.type !== 3 /* COMMENT */).length === 1) {\r\n patchFlag |= 2048 /* DEV_ROOT_FRAGMENT */;\r\n patchFlagText += `, ${PatchFlagNames[2048 /* DEV_ROOT_FRAGMENT */]}`;\r\n }\r\n return createVNodeCall(context, helper(FRAGMENT), createObjectExpression([keyProperty]), children, patchFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${patchFlagText} */` : ``), undefined, undefined, true, false, false /* isComponent */, branch.loc);\r\n }\r\n }\r\n else {\r\n const ret = firstChild.codegenNode;\r\n const vnodeCall = getMemoedVNodeCall(ret);\r\n // Change createVNode to createBlock.\r\n if (vnodeCall.type === 13 /* VNODE_CALL */) {\r\n makeBlock(vnodeCall, context);\r\n }\r\n // inject branch key\r\n injectProp(vnodeCall, keyProperty, context);\r\n return ret;\r\n }\r\n}\r\nfunction isSameKey(a, b) {\r\n if (!a || a.type !== b.type) {\r\n return false;\r\n }\r\n if (a.type === 6 /* ATTRIBUTE */) {\r\n if (a.value.content !== b.value.content) {\r\n return false;\r\n }\r\n }\r\n else {\r\n // directive\r\n const exp = a.exp;\r\n const branchExp = b.exp;\r\n if (exp.type !== branchExp.type) {\r\n return false;\r\n }\r\n if (exp.type !== 4 /* SIMPLE_EXPRESSION */ ||\r\n exp.isStatic !== branchExp.isStatic ||\r\n exp.content !== branchExp.content) {\r\n return false;\r\n }\r\n }\r\n return true;\r\n}\r\nfunction getParentCondition(node) {\r\n while (true) {\r\n if (node.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n if (node.alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n node = node.alternate;\r\n }\r\n else {\r\n return node;\r\n }\r\n }\r\n else if (node.type === 20 /* JS_CACHE_EXPRESSION */) {\r\n node = node.value;\r\n }\r\n }\r\n}\n\nconst transformFor = createStructuralDirectiveTransform('for', (node, dir, context) => {\r\n const { helper, removeHelper } = context;\r\n return processFor(node, dir, context, forNode => {\r\n // create the loop render function expression now, and add the\r\n // iterator on exit after all children have been traversed\r\n const renderExp = createCallExpression(helper(RENDER_LIST), [\r\n forNode.source\r\n ]);\r\n const memo = findDir(node, 'memo');\r\n const keyProp = findProp(node, `key`);\r\n const keyExp = keyProp &&\r\n (keyProp.type === 6 /* ATTRIBUTE */\r\n ? createSimpleExpression(keyProp.value.content, true)\r\n : keyProp.exp);\r\n const keyProperty = keyProp ? createObjectProperty(`key`, keyExp) : null;\r\n const isStableFragment = forNode.source.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n forNode.source.constType > 0 /* NOT_CONSTANT */;\r\n const fragmentFlag = isStableFragment\r\n ? 64 /* STABLE_FRAGMENT */\r\n : keyProp\r\n ? 128 /* KEYED_FRAGMENT */\r\n : 256 /* UNKEYED_FRAGMENT */;\r\n forNode.codegenNode = createVNodeCall(context, helper(FRAGMENT), undefined, renderExp, fragmentFlag +\r\n ((process.env.NODE_ENV !== 'production') ? ` /* ${PatchFlagNames[fragmentFlag]} */` : ``), undefined, undefined, true /* isBlock */, !isStableFragment /* disableTracking */, false /* isComponent */, node.loc);\r\n return () => {\r\n // finish the codegen now that all children have been traversed\r\n let childBlock;\r\n const isTemplate = isTemplateNode(node);\r\n const { children } = forNode;\r\n // check <template v-for> key placement\r\n if (((process.env.NODE_ENV !== 'production') || !true) && isTemplate) {\r\n node.children.some(c => {\r\n if (c.type === 1 /* ELEMENT */) {\r\n const key = findProp(c, 'key');\r\n if (key) {\r\n context.onError(createCompilerError(33 /* X_V_FOR_TEMPLATE_KEY_PLACEMENT */, key.loc));\r\n return true;\r\n }\r\n }\r\n });\r\n }\r\n const needFragmentWrapper = children.length !== 1 || children[0].type !== 1 /* ELEMENT */;\r\n const slotOutlet = isSlotOutlet(node)\r\n ? node\r\n : isTemplate &&\r\n node.children.length === 1 &&\r\n isSlotOutlet(node.children[0])\r\n ? node.children[0] // api-extractor somehow fails to infer this\r\n : null;\r\n if (slotOutlet) {\r\n // <slot v-for=\"...\"> or <template v-for=\"...\"><slot/></template>\r\n childBlock = slotOutlet.codegenNode;\r\n if (isTemplate && keyProperty) {\r\n // <template v-for=\"...\" :key=\"...\"><slot/></template>\r\n // we need to inject the key to the renderSlot() call.\r\n // the props for renderSlot is passed as the 3rd argument.\r\n injectProp(childBlock, keyProperty, context);\r\n }\r\n }\r\n else if (needFragmentWrapper) {\r\n // <template v-for=\"...\"> with text or multi-elements\r\n // should generate a fragment block for each loop\r\n childBlock = createVNodeCall(context, helper(FRAGMENT), keyProperty ? createObjectExpression([keyProperty]) : undefined, node.children, 64 /* STABLE_FRAGMENT */ +\r\n ((process.env.NODE_ENV !== 'production')\r\n ? ` /* ${PatchFlagNames[64 /* STABLE_FRAGMENT */]} */`\r\n : ``), undefined, undefined, true, undefined, false /* isComponent */);\r\n }\r\n else {\r\n // Normal element v-for. Directly use the child's codegenNode\r\n // but mark it as a block.\r\n childBlock = children[0]\r\n .codegenNode;\r\n if (isTemplate && keyProperty) {\r\n injectProp(childBlock, keyProperty, context);\r\n }\r\n if (childBlock.isBlock !== !isStableFragment) {\r\n if (childBlock.isBlock) {\r\n // switch from block to vnode\r\n removeHelper(OPEN_BLOCK);\r\n removeHelper(getVNodeBlockHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n else {\r\n // switch from vnode to block\r\n removeHelper(getVNodeHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n }\r\n childBlock.isBlock = !isStableFragment;\r\n if (childBlock.isBlock) {\r\n helper(OPEN_BLOCK);\r\n helper(getVNodeBlockHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n else {\r\n helper(getVNodeHelper(context.inSSR, childBlock.isComponent));\r\n }\r\n }\r\n if (memo) {\r\n const loop = createFunctionExpression(createForLoopParams(forNode.parseResult, [\r\n createSimpleExpression(`_cached`)\r\n ]));\r\n loop.body = createBlockStatement([\r\n createCompoundExpression([`const _memo = (`, memo.exp, `)`]),\r\n createCompoundExpression([\r\n `if (_cached`,\r\n ...(keyExp ? [` && _cached.key === `, keyExp] : []),\r\n ` && ${context.helperString(IS_MEMO_SAME)}(_cached, _memo)) return _cached`\r\n ]),\r\n createCompoundExpression([`const _item = `, childBlock]),\r\n createSimpleExpression(`_item.memo = _memo`),\r\n createSimpleExpression(`return _item`)\r\n ]);\r\n renderExp.arguments.push(loop, createSimpleExpression(`_cache`), createSimpleExpression(String(context.cached++)));\r\n }\r\n else {\r\n renderExp.arguments.push(createFunctionExpression(createForLoopParams(forNode.parseResult), childBlock, true /* force newline */));\r\n }\r\n };\r\n });\r\n});\r\n// target-agnostic transform used for both Client and SSR\r\nfunction processFor(node, dir, context, processCodegen) {\r\n if (!dir.exp) {\r\n context.onError(createCompilerError(31 /* X_V_FOR_NO_EXPRESSION */, dir.loc));\r\n return;\r\n }\r\n const parseResult = parseForExpression(\r\n // can only be simple expression because vFor transform is applied\r\n // before expression transform.\r\n dir.exp, context);\r\n if (!parseResult) {\r\n context.onError(createCompilerError(32 /* X_V_FOR_MALFORMED_EXPRESSION */, dir.loc));\r\n return;\r\n }\r\n const { addIdentifiers, removeIdentifiers, scopes } = context;\r\n const { source, value, key, index } = parseResult;\r\n const forNode = {\r\n type: 11 /* FOR */,\r\n loc: dir.loc,\r\n source,\r\n valueAlias: value,\r\n keyAlias: key,\r\n objectIndexAlias: index,\r\n parseResult,\r\n children: isTemplateNode(node) ? node.children : [node]\r\n };\r\n context.replaceNode(forNode);\r\n // bookkeeping\r\n scopes.vFor++;\r\n const onExit = processCodegen && processCodegen(forNode);\r\n return () => {\r\n scopes.vFor--;\r\n if (onExit)\r\n onExit();\r\n };\r\n}\r\nconst forAliasRE = /([\\s\\S]*?)\\s+(?:in|of)\\s+([\\s\\S]*)/;\r\n// This regex doesn't cover the case if key or index aliases have destructuring,\r\n// but those do not make sense in the first place, so this works in practice.\r\nconst forIteratorRE = /,([^,\\}\\]]*)(?:,([^,\\}\\]]*))?$/;\r\nconst stripParensRE = /^\\(|\\)$/g;\r\nfunction parseForExpression(input, context) {\r\n const loc = input.loc;\r\n const exp = input.content;\r\n const inMatch = exp.match(forAliasRE);\r\n if (!inMatch)\r\n return;\r\n const [, LHS, RHS] = inMatch;\r\n const result = {\r\n source: createAliasExpression(loc, RHS.trim(), exp.indexOf(RHS, LHS.length)),\r\n value: undefined,\r\n key: undefined,\r\n index: undefined\r\n };\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.source, context);\r\n }\r\n let valueContent = LHS.trim().replace(stripParensRE, '').trim();\r\n const trimmedOffset = LHS.indexOf(valueContent);\r\n const iteratorMatch = valueContent.match(forIteratorRE);\r\n if (iteratorMatch) {\r\n valueContent = valueContent.replace(forIteratorRE, '').trim();\r\n const keyContent = iteratorMatch[1].trim();\r\n let keyOffset;\r\n if (keyContent) {\r\n keyOffset = exp.indexOf(keyContent, trimmedOffset + valueContent.length);\r\n result.key = createAliasExpression(loc, keyContent, keyOffset);\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.key, context, true);\r\n }\r\n }\r\n if (iteratorMatch[2]) {\r\n const indexContent = iteratorMatch[2].trim();\r\n if (indexContent) {\r\n result.index = createAliasExpression(loc, indexContent, exp.indexOf(indexContent, result.key\r\n ? keyOffset + keyContent.length\r\n : trimmedOffset + valueContent.length));\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.index, context, true);\r\n }\r\n }\r\n }\r\n }\r\n if (valueContent) {\r\n result.value = createAliasExpression(loc, valueContent, trimmedOffset);\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(result.value, context, true);\r\n }\r\n }\r\n return result;\r\n}\r\nfunction createAliasExpression(range, content, offset) {\r\n return createSimpleExpression(content, false, getInnerRange(range, offset, content.length));\r\n}\r\nfunction createForLoopParams({ value, key, index }, memoArgs = []) {\r\n return createParamsList([value, key, index, ...memoArgs]);\r\n}\r\nfunction createParamsList(args) {\r\n let i = args.length;\r\n while (i--) {\r\n if (args[i])\r\n break;\r\n }\r\n return args\r\n .slice(0, i + 1)\r\n .map((arg, i) => arg || createSimpleExpression(`_`.repeat(i + 1), false));\r\n}\n\nconst defaultFallback = createSimpleExpression(`undefined`, false);\r\n// A NodeTransform that:\r\n// 1. Tracks scope identifiers for scoped slots so that they don't get prefixed\r\n// by transformExpression. This is only applied in non-browser builds with\r\n// { prefixIdentifiers: true }.\r\n// 2. Track v-slot depths so that we know a slot is inside another slot.\r\n// Note the exit callback is executed before buildSlots() on the same node,\r\n// so only nested slots see positive numbers.\r\nconst trackSlotScopes = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ &&\r\n (node.tagType === 1 /* COMPONENT */ ||\r\n node.tagType === 3 /* TEMPLATE */)) {\r\n // We are only checking non-empty v-slot here\r\n // since we only care about slots that introduce scope variables.\r\n const vSlot = findDir(node, 'slot');\r\n if (vSlot) {\r\n vSlot.exp;\r\n context.scopes.vSlot++;\r\n return () => {\r\n context.scopes.vSlot--;\r\n };\r\n }\r\n }\r\n};\r\n// A NodeTransform that tracks scope identifiers for scoped slots with v-for.\r\n// This transform is only applied in non-browser builds with { prefixIdentifiers: true }\r\nconst trackVForSlotScopes = (node, context) => {\r\n let vFor;\r\n if (isTemplateNode(node) &&\r\n node.props.some(isVSlot) &&\r\n (vFor = findDir(node, 'for'))) {\r\n const result = (vFor.parseResult = parseForExpression(vFor.exp, context));\r\n if (result) {\r\n const { value, key, index } = result;\r\n const { addIdentifiers, removeIdentifiers } = context;\r\n value && addIdentifiers(value);\r\n key && addIdentifiers(key);\r\n index && addIdentifiers(index);\r\n return () => {\r\n value && removeIdentifiers(value);\r\n key && removeIdentifiers(key);\r\n index && removeIdentifiers(index);\r\n };\r\n }\r\n }\r\n};\r\nconst buildClientSlotFn = (props, children, loc) => createFunctionExpression(props, children, false /* newline */, true /* isSlot */, children.length ? children[0].loc : loc);\r\n// Instead of being a DirectiveTransform, v-slot processing is called during\r\n// transformElement to build the slots object for a component.\r\nfunction buildSlots(node, context, buildSlotFn = buildClientSlotFn) {\r\n context.helper(WITH_CTX);\r\n const { children, loc } = node;\r\n const slotsProperties = [];\r\n const dynamicSlots = [];\r\n // If the slot is inside a v-for or another v-slot, force it to be dynamic\r\n // since it likely uses a scope variable.\r\n let hasDynamicSlots = context.scopes.vSlot > 0 || context.scopes.vFor > 0;\r\n // 1. Check for slot with slotProps on component itself.\r\n // <Comp v-slot=\"{ prop }\"/>\r\n const onComponentSlot = findDir(node, 'slot', true);\r\n if (onComponentSlot) {\r\n const { arg, exp } = onComponentSlot;\r\n if (arg && !isStaticExp(arg)) {\r\n hasDynamicSlots = true;\r\n }\r\n slotsProperties.push(createObjectProperty(arg || createSimpleExpression('default', true), buildSlotFn(exp, children, loc)));\r\n }\r\n // 2. Iterate through children and check for template slots\r\n // <template v-slot:foo=\"{ prop }\">\r\n let hasTemplateSlots = false;\r\n let hasNamedDefaultSlot = false;\r\n const implicitDefaultChildren = [];\r\n const seenSlotNames = new Set();\r\n for (let i = 0; i < children.length; i++) {\r\n const slotElement = children[i];\r\n let slotDir;\r\n if (!isTemplateNode(slotElement) ||\r\n !(slotDir = findDir(slotElement, 'slot', true))) {\r\n // not a <template v-slot>, skip.\r\n if (slotElement.type !== 3 /* COMMENT */) {\r\n implicitDefaultChildren.push(slotElement);\r\n }\r\n continue;\r\n }\r\n if (onComponentSlot) {\r\n // already has on-component slot - this is incorrect usage.\r\n context.onError(createCompilerError(37 /* X_V_SLOT_MIXED_SLOT_USAGE */, slotDir.loc));\r\n break;\r\n }\r\n hasTemplateSlots = true;\r\n const { children: slotChildren, loc: slotLoc } = slotElement;\r\n const { arg: slotName = createSimpleExpression(`default`, true), exp: slotProps, loc: dirLoc } = slotDir;\r\n // check if name is dynamic.\r\n let staticSlotName;\r\n if (isStaticExp(slotName)) {\r\n staticSlotName = slotName ? slotName.content : `default`;\r\n }\r\n else {\r\n hasDynamicSlots = true;\r\n }\r\n const slotFunction = buildSlotFn(slotProps, slotChildren, slotLoc);\r\n // check if this slot is conditional (v-if/v-for)\r\n let vIf;\r\n let vElse;\r\n let vFor;\r\n if ((vIf = findDir(slotElement, 'if'))) {\r\n hasDynamicSlots = true;\r\n dynamicSlots.push(createConditionalExpression(vIf.exp, buildDynamicSlot(slotName, slotFunction), defaultFallback));\r\n }\r\n else if ((vElse = findDir(slotElement, /^else(-if)?$/, true /* allowEmpty */))) {\r\n // find adjacent v-if\r\n let j = i;\r\n let prev;\r\n while (j--) {\r\n prev = children[j];\r\n if (prev.type !== 3 /* COMMENT */) {\r\n break;\r\n }\r\n }\r\n if (prev && isTemplateNode(prev) && findDir(prev, 'if')) {\r\n // remove node\r\n children.splice(i, 1);\r\n i--;\r\n // attach this slot to previous conditional\r\n let conditional = dynamicSlots[dynamicSlots.length - 1];\r\n while (conditional.alternate.type === 19 /* JS_CONDITIONAL_EXPRESSION */) {\r\n conditional = conditional.alternate;\r\n }\r\n conditional.alternate = vElse.exp\r\n ? createConditionalExpression(vElse.exp, buildDynamicSlot(slotName, slotFunction), defaultFallback)\r\n : buildDynamicSlot(slotName, slotFunction);\r\n }\r\n else {\r\n context.onError(createCompilerError(30 /* X_V_ELSE_NO_ADJACENT_IF */, vElse.loc));\r\n }\r\n }\r\n else if ((vFor = findDir(slotElement, 'for'))) {\r\n hasDynamicSlots = true;\r\n const parseResult = vFor.parseResult ||\r\n parseForExpression(vFor.exp, context);\r\n if (parseResult) {\r\n // Render the dynamic slots as an array and add it to the createSlot()\r\n // args. The runtime knows how to handle it appropriately.\r\n dynamicSlots.push(createCallExpression(context.helper(RENDER_LIST), [\r\n parseResult.source,\r\n createFunctionExpression(createForLoopParams(parseResult), buildDynamicSlot(slotName, slotFunction), true /* force newline */)\r\n ]));\r\n }\r\n else {\r\n context.onError(createCompilerError(32 /* X_V_FOR_MALFORMED_EXPRESSION */, vFor.loc));\r\n }\r\n }\r\n else {\r\n // check duplicate static names\r\n if (staticSlotName) {\r\n if (seenSlotNames.has(staticSlotName)) {\r\n context.onError(createCompilerError(38 /* X_V_SLOT_DUPLICATE_SLOT_NAMES */, dirLoc));\r\n continue;\r\n }\r\n seenSlotNames.add(staticSlotName);\r\n if (staticSlotName === 'default') {\r\n hasNamedDefaultSlot = true;\r\n }\r\n }\r\n slotsProperties.push(createObjectProperty(slotName, slotFunction));\r\n }\r\n }\r\n if (!onComponentSlot) {\r\n const buildDefaultSlotProperty = (props, children) => {\r\n const fn = buildSlotFn(props, children, loc);\r\n if (context.compatConfig) {\r\n fn.isNonScopedSlot = true;\r\n }\r\n return createObjectProperty(`default`, fn);\r\n };\r\n if (!hasTemplateSlots) {\r\n // implicit default slot (on component)\r\n slotsProperties.push(buildDefaultSlotProperty(undefined, children));\r\n }\r\n else if (implicitDefaultChildren.length &&\r\n // #3766\r\n // with whitespace: 'preserve', whitespaces between slots will end up in\r\n // implicitDefaultChildren. Ignore if all implicit children are whitespaces.\r\n implicitDefaultChildren.some(node => isNonWhitespaceContent(node))) {\r\n // implicit default slot (mixed with named slots)\r\n if (hasNamedDefaultSlot) {\r\n context.onError(createCompilerError(39 /* X_V_SLOT_EXTRANEOUS_DEFAULT_SLOT_CHILDREN */, implicitDefaultChildren[0].loc));\r\n }\r\n else {\r\n slotsProperties.push(buildDefaultSlotProperty(undefined, implicitDefaultChildren));\r\n }\r\n }\r\n }\r\n const slotFlag = hasDynamicSlots\r\n ? 2 /* DYNAMIC */\r\n : hasForwardedSlots(node.children)\r\n ? 3 /* FORWARDED */\r\n : 1 /* STABLE */;\r\n let slots = createObjectExpression(slotsProperties.concat(createObjectProperty(`_`, \r\n // 2 = compiled but dynamic = can skip normalization, but must run diff\r\n // 1 = compiled and static = can skip normalization AND diff as optimized\r\n createSimpleExpression(slotFlag + ((process.env.NODE_ENV !== 'production') ? ` /* ${slotFlagsText[slotFlag]} */` : ``), false))), loc);\r\n if (dynamicSlots.length) {\r\n slots = createCallExpression(context.helper(CREATE_SLOTS), [\r\n slots,\r\n createArrayExpression(dynamicSlots)\r\n ]);\r\n }\r\n return {\r\n slots,\r\n hasDynamicSlots\r\n };\r\n}\r\nfunction buildDynamicSlot(name, fn) {\r\n return createObjectExpression([\r\n createObjectProperty(`name`, name),\r\n createObjectProperty(`fn`, fn)\r\n ]);\r\n}\r\nfunction hasForwardedSlots(children) {\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n switch (child.type) {\r\n case 1 /* ELEMENT */:\r\n if (child.tagType === 2 /* SLOT */ ||\r\n hasForwardedSlots(child.children)) {\r\n return true;\r\n }\r\n break;\r\n case 9 /* IF */:\r\n if (hasForwardedSlots(child.branches))\r\n return true;\r\n break;\r\n case 10 /* IF_BRANCH */:\r\n case 11 /* FOR */:\r\n if (hasForwardedSlots(child.children))\r\n return true;\r\n break;\r\n }\r\n }\r\n return false;\r\n}\r\nfunction isNonWhitespaceContent(node) {\r\n if (node.type !== 2 /* TEXT */ && node.type !== 12 /* TEXT_CALL */)\r\n return true;\r\n return node.type === 2 /* TEXT */\r\n ? !!node.content.trim()\r\n : isNonWhitespaceContent(node.content);\r\n}\n\n// some directive transforms (e.g. v-model) may return a symbol for runtime\r\n// import, which should be used instead of a resolveDirective call.\r\nconst directiveImportMap = new WeakMap();\r\n// generate a JavaScript AST for this element's codegen\r\nconst transformElement = (node, context) => {\r\n // perform the work on exit, after all child expressions have been\r\n // processed and merged.\r\n return function postTransformElement() {\r\n node = context.currentNode;\r\n if (!(node.type === 1 /* ELEMENT */ &&\r\n (node.tagType === 0 /* ELEMENT */ ||\r\n node.tagType === 1 /* COMPONENT */))) {\r\n return;\r\n }\r\n const { tag, props } = node;\r\n const isComponent = node.tagType === 1 /* COMPONENT */;\r\n // The goal of the transform is to create a codegenNode implementing the\r\n // VNodeCall interface.\r\n let vnodeTag = isComponent\r\n ? resolveComponentType(node, context)\r\n : `\"${tag}\"`;\r\n const isDynamicComponent = isObject(vnodeTag) && vnodeTag.callee === RESOLVE_DYNAMIC_COMPONENT;\r\n let vnodeProps;\r\n let vnodeChildren;\r\n let vnodePatchFlag;\r\n let patchFlag = 0;\r\n let vnodeDynamicProps;\r\n let dynamicPropNames;\r\n let vnodeDirectives;\r\n let shouldUseBlock = \r\n // dynamic component may resolve to plain elements\r\n isDynamicComponent ||\r\n vnodeTag === TELEPORT ||\r\n vnodeTag === SUSPENSE ||\r\n (!isComponent &&\r\n // <svg> and <foreignObject> must be forced into blocks so that block\r\n // updates inside get proper isSVG flag at runtime. (#639, #643)\r\n // This is technically web-specific, but splitting the logic out of core\r\n // leads to too much unnecessary complexity.\r\n (tag === 'svg' ||\r\n tag === 'foreignObject' ||\r\n // #938: elements with dynamic keys should be forced into blocks\r\n findProp(node, 'key', true)));\r\n // props\r\n if (props.length > 0) {\r\n const propsBuildResult = buildProps(node, context);\r\n vnodeProps = propsBuildResult.props;\r\n patchFlag = propsBuildResult.patchFlag;\r\n dynamicPropNames = propsBuildResult.dynamicPropNames;\r\n const directives = propsBuildResult.directives;\r\n vnodeDirectives =\r\n directives && directives.length\r\n ? createArrayExpression(directives.map(dir => buildDirectiveArgs(dir, context)))\r\n : undefined;\r\n }\r\n // children\r\n if (node.children.length > 0) {\r\n if (vnodeTag === KEEP_ALIVE) {\r\n // Although a built-in component, we compile KeepAlive with raw children\r\n // instead of slot functions so that it can be used inside Transition\r\n // or other Transition-wrapping HOCs.\r\n // To ensure correct updates with block optimizations, we need to:\r\n // 1. Force keep-alive into a block. This avoids its children being\r\n // collected by a parent block.\r\n shouldUseBlock = true;\r\n // 2. Force keep-alive to always be updated, since it uses raw children.\r\n patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n if ((process.env.NODE_ENV !== 'production') && node.children.length > 1) {\r\n context.onError(createCompilerError(45 /* X_KEEP_ALIVE_INVALID_CHILDREN */, {\r\n start: node.children[0].loc.start,\r\n end: node.children[node.children.length - 1].loc.end,\r\n source: ''\r\n }));\r\n }\r\n }\r\n const shouldBuildAsSlots = isComponent &&\r\n // Teleport is not a real component and has dedicated runtime handling\r\n vnodeTag !== TELEPORT &&\r\n // explained above.\r\n vnodeTag !== KEEP_ALIVE;\r\n if (shouldBuildAsSlots) {\r\n const { slots, hasDynamicSlots } = buildSlots(node, context);\r\n vnodeChildren = slots;\r\n if (hasDynamicSlots) {\r\n patchFlag |= 1024 /* DYNAMIC_SLOTS */;\r\n }\r\n }\r\n else if (node.children.length === 1 && vnodeTag !== TELEPORT) {\r\n const child = node.children[0];\r\n const type = child.type;\r\n // check for dynamic text children\r\n const hasDynamicTextChild = type === 5 /* INTERPOLATION */ ||\r\n type === 8 /* COMPOUND_EXPRESSION */;\r\n if (hasDynamicTextChild &&\r\n getConstantType(child, context) === 0 /* NOT_CONSTANT */) {\r\n patchFlag |= 1 /* TEXT */;\r\n }\r\n // pass directly if the only child is a text node\r\n // (plain / interpolation / expression)\r\n if (hasDynamicTextChild || type === 2 /* TEXT */) {\r\n vnodeChildren = child;\r\n }\r\n else {\r\n vnodeChildren = node.children;\r\n }\r\n }\r\n else {\r\n vnodeChildren = node.children;\r\n }\r\n }\r\n // patchFlag & dynamicPropNames\r\n if (patchFlag !== 0) {\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n if (patchFlag < 0) {\r\n // special flags (negative and mutually exclusive)\r\n vnodePatchFlag = patchFlag + ` /* ${PatchFlagNames[patchFlag]} */`;\r\n }\r\n else {\r\n // bitwise flags\r\n const flagNames = Object.keys(PatchFlagNames)\r\n .map(Number)\r\n .filter(n => n > 0 && patchFlag & n)\r\n .map(n => PatchFlagNames[n])\r\n .join(`, `);\r\n vnodePatchFlag = patchFlag + ` /* ${flagNames} */`;\r\n }\r\n }\r\n else {\r\n vnodePatchFlag = String(patchFlag);\r\n }\r\n if (dynamicPropNames && dynamicPropNames.length) {\r\n vnodeDynamicProps = stringifyDynamicPropNames(dynamicPropNames);\r\n }\r\n }\r\n node.codegenNode = createVNodeCall(context, vnodeTag, vnodeProps, vnodeChildren, vnodePatchFlag, vnodeDynamicProps, vnodeDirectives, !!shouldUseBlock, false /* disableTracking */, isComponent, node.loc);\r\n };\r\n};\r\nfunction resolveComponentType(node, context, ssr = false) {\r\n let { tag } = node;\r\n // 1. dynamic component\r\n const isExplicitDynamic = isComponentTag(tag);\r\n const isProp = findProp(node, 'is');\r\n if (isProp) {\r\n if (isExplicitDynamic ||\r\n (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context))) {\r\n const exp = isProp.type === 6 /* ATTRIBUTE */\r\n ? isProp.value && createSimpleExpression(isProp.value.content, true)\r\n : isProp.exp;\r\n if (exp) {\r\n return createCallExpression(context.helper(RESOLVE_DYNAMIC_COMPONENT), [\r\n exp\r\n ]);\r\n }\r\n }\r\n else if (isProp.type === 6 /* ATTRIBUTE */ &&\r\n isProp.value.content.startsWith('vue:')) {\r\n // <button is=\"vue:xxx\">\r\n // if not <component>, only is value that starts with \"vue:\" will be\r\n // treated as component by the parse phase and reach here, unless it's\r\n // compat mode where all is values are considered components\r\n tag = isProp.value.content.slice(4);\r\n }\r\n }\r\n // 1.5 v-is (TODO: Deprecate)\r\n const isDir = !isExplicitDynamic && findDir(node, 'is');\r\n if (isDir && isDir.exp) {\r\n return createCallExpression(context.helper(RESOLVE_DYNAMIC_COMPONENT), [\r\n isDir.exp\r\n ]);\r\n }\r\n // 2. built-in components (Teleport, Transition, KeepAlive, Suspense...)\r\n const builtIn = isCoreComponent(tag) || context.isBuiltInComponent(tag);\r\n if (builtIn) {\r\n // built-ins are simply fallthroughs / have special handling during ssr\r\n // so we don't need to import their runtime equivalents\r\n if (!ssr)\r\n context.helper(builtIn);\r\n return builtIn;\r\n }\r\n // 5. user component (resolve)\r\n context.helper(RESOLVE_COMPONENT);\r\n context.components.add(tag);\r\n return toValidAssetId(tag, `component`);\r\n}\r\nfunction buildProps(node, context, props = node.props, ssr = false) {\r\n const { tag, loc: elementLoc } = node;\r\n const isComponent = node.tagType === 1 /* COMPONENT */;\r\n let properties = [];\r\n const mergeArgs = [];\r\n const runtimeDirectives = [];\r\n // patchFlag analysis\r\n let patchFlag = 0;\r\n let hasRef = false;\r\n let hasClassBinding = false;\r\n let hasStyleBinding = false;\r\n let hasHydrationEventBinding = false;\r\n let hasDynamicKeys = false;\r\n let hasVnodeHook = false;\r\n const dynamicPropNames = [];\r\n const analyzePatchFlag = ({ key, value }) => {\r\n if (isStaticExp(key)) {\r\n const name = key.content;\r\n const isEventHandler = isOn(name);\r\n if (!isComponent &&\r\n isEventHandler &&\r\n // omit the flag for click handlers because hydration gives click\r\n // dedicated fast path.\r\n name.toLowerCase() !== 'onclick' &&\r\n // omit v-model handlers\r\n name !== 'onUpdate:modelValue' &&\r\n // omit onVnodeXXX hooks\r\n !isReservedProp(name)) {\r\n hasHydrationEventBinding = true;\r\n }\r\n if (isEventHandler && isReservedProp(name)) {\r\n hasVnodeHook = true;\r\n }\r\n if (value.type === 20 /* JS_CACHE_EXPRESSION */ ||\r\n ((value.type === 4 /* SIMPLE_EXPRESSION */ ||\r\n value.type === 8 /* COMPOUND_EXPRESSION */) &&\r\n getConstantType(value, context) > 0)) {\r\n // skip if the prop is a cached handler or has constant value\r\n return;\r\n }\r\n if (name === 'ref') {\r\n hasRef = true;\r\n }\r\n else if (name === 'class') {\r\n hasClassBinding = true;\r\n }\r\n else if (name === 'style') {\r\n hasStyleBinding = true;\r\n }\r\n else if (name !== 'key' && !dynamicPropNames.includes(name)) {\r\n dynamicPropNames.push(name);\r\n }\r\n // treat the dynamic class and style binding of the component as dynamic props\r\n if (isComponent &&\r\n (name === 'class' || name === 'style') &&\r\n !dynamicPropNames.includes(name)) {\r\n dynamicPropNames.push(name);\r\n }\r\n }\r\n else {\r\n hasDynamicKeys = true;\r\n }\r\n };\r\n for (let i = 0; i < props.length; i++) {\r\n // static attribute\r\n const prop = props[i];\r\n if (prop.type === 6 /* ATTRIBUTE */) {\r\n const { loc, name, value } = prop;\r\n let valueNode = createSimpleExpression(value ? value.content : '', true, value ? value.loc : loc);\r\n if (name === 'ref') {\r\n hasRef = true;\r\n }\r\n // skip is on <component>, or is=\"vue:xxx\"\r\n if (name === 'is' &&\r\n (isComponentTag(tag) ||\r\n (value && value.content.startsWith('vue:')) ||\r\n (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context)))) {\r\n continue;\r\n }\r\n properties.push(createObjectProperty(createSimpleExpression(name, true, getInnerRange(loc, 0, name.length)), valueNode));\r\n }\r\n else {\r\n // directives\r\n const { name, arg, exp, loc } = prop;\r\n const isVBind = name === 'bind';\r\n const isVOn = name === 'on';\r\n // skip v-slot - it is handled by its dedicated transform.\r\n if (name === 'slot') {\r\n if (!isComponent) {\r\n context.onError(createCompilerError(40 /* X_V_SLOT_MISPLACED */, loc));\r\n }\r\n continue;\r\n }\r\n // skip v-once/v-memo - they are handled by dedicated transforms.\r\n if (name === 'once' || name === 'memo') {\r\n continue;\r\n }\r\n // skip v-is and :is on <component>\r\n if (name === 'is' ||\r\n (isVBind &&\r\n isBindKey(arg, 'is') &&\r\n (isComponentTag(tag) ||\r\n (isCompatEnabled(\"COMPILER_IS_ON_ELEMENT\" /* COMPILER_IS_ON_ELEMENT */, context))))) {\r\n continue;\r\n }\r\n // skip v-on in SSR compilation\r\n if (isVOn && ssr) {\r\n continue;\r\n }\r\n // special case for v-bind and v-on with no argument\r\n if (!arg && (isVBind || isVOn)) {\r\n hasDynamicKeys = true;\r\n if (exp) {\r\n if (properties.length) {\r\n mergeArgs.push(createObjectExpression(dedupeProperties(properties), elementLoc));\r\n properties = [];\r\n }\r\n if (isVBind) {\r\n {\r\n // 2.x v-bind object order compat\r\n if ((process.env.NODE_ENV !== 'production')) {\r\n const hasOverridableKeys = mergeArgs.some(arg => {\r\n if (arg.type === 15 /* JS_OBJECT_EXPRESSION */) {\r\n return arg.properties.some(({ key }) => {\r\n if (key.type !== 4 /* SIMPLE_EXPRESSION */ ||\r\n !key.isStatic) {\r\n return true;\r\n }\r\n return (key.content !== 'class' &&\r\n key.content !== 'style' &&\r\n !isOn(key.content));\r\n });\r\n }\r\n else {\r\n // dynamic expression\r\n return true;\r\n }\r\n });\r\n if (hasOverridableKeys) {\r\n checkCompatEnabled(\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */, context, loc);\r\n }\r\n }\r\n if (isCompatEnabled(\"COMPILER_V_BIND_OBJECT_ORDER\" /* COMPILER_V_BIND_OBJECT_ORDER */, context)) {\r\n mergeArgs.unshift(exp);\r\n continue;\r\n }\r\n }\r\n mergeArgs.push(exp);\r\n }\r\n else {\r\n // v-on=\"obj\" -> toHandlers(obj)\r\n mergeArgs.push({\r\n type: 14 /* JS_CALL_EXPRESSION */,\r\n loc,\r\n callee: context.helper(TO_HANDLERS),\r\n arguments: [exp]\r\n });\r\n }\r\n }\r\n else {\r\n context.onError(createCompilerError(isVBind\r\n ? 34 /* X_V_BIND_NO_EXPRESSION */\r\n : 35 /* X_V_ON_NO_EXPRESSION */, loc));\r\n }\r\n continue;\r\n }\r\n const directiveTransform = context.directiveTransforms[name];\r\n if (directiveTransform) {\r\n // has built-in directive transform.\r\n const { props, needRuntime } = directiveTransform(prop, node, context);\r\n !ssr && props.forEach(analyzePatchFlag);\r\n properties.push(...props);\r\n if (needRuntime) {\r\n runtimeDirectives.push(prop);\r\n if (isSymbol(needRuntime)) {\r\n directiveImportMap.set(prop, needRuntime);\r\n }\r\n }\r\n }\r\n else {\r\n // no built-in transform, this is a user custom directive.\r\n runtimeDirectives.push(prop);\r\n }\r\n }\r\n if (prop.type === 6 /* ATTRIBUTE */ &&\r\n prop.name === 'ref' &&\r\n context.scopes.vFor > 0 &&\r\n checkCompatEnabled(\"COMPILER_V_FOR_REF\" /* COMPILER_V_FOR_REF */, context, prop.loc)) {\r\n properties.push(createObjectProperty(createSimpleExpression('refInFor', true), createSimpleExpression('true', false)));\r\n }\r\n }\r\n let propsExpression = undefined;\r\n // has v-bind=\"object\" or v-on=\"object\", wrap with mergeProps\r\n if (mergeArgs.length) {\r\n if (properties.length) {\r\n mergeArgs.push(createObjectExpression(dedupeProperties(properties), elementLoc));\r\n }\r\n if (mergeArgs.length > 1) {\r\n propsExpression = createCallExpression(context.helper(MERGE_PROPS), mergeArgs, elementLoc);\r\n }\r\n else {\r\n // single v-bind with nothing else - no need for a mergeProps call\r\n propsExpression = mergeArgs[0];\r\n }\r\n }\r\n else if (properties.length) {\r\n propsExpression = createObjectExpression(dedupeProperties(properties), elementLoc);\r\n }\r\n // patchFlag analysis\r\n if (hasDynamicKeys) {\r\n patchFlag |= 16 /* FULL_PROPS */;\r\n }\r\n else {\r\n if (hasClassBinding && !isComponent) {\r\n patchFlag |= 2 /* CLASS */;\r\n }\r\n if (hasStyleBinding && !isComponent) {\r\n patchFlag |= 4 /* STYLE */;\r\n }\r\n if (dynamicPropNames.length) {\r\n patchFlag |= 8 /* PROPS */;\r\n }\r\n if (hasHydrationEventBinding) {\r\n patchFlag |= 32 /* HYDRATE_EVENTS */;\r\n }\r\n }\r\n if ((patchFlag === 0 || patchFlag === 32 /* HYDRATE_EVENTS */) &&\r\n (hasRef || hasVnodeHook || runtimeDirectives.length > 0)) {\r\n patchFlag |= 512 /* NEED_PATCH */;\r\n }\r\n // pre-normalize props, SSR is skipped for now\r\n if (!context.inSSR && propsExpression) {\r\n switch (propsExpression.type) {\r\n case 15 /* JS_OBJECT_EXPRESSION */:\r\n // means that there is no v-bind,\r\n // but still need to deal with dynamic key binding\r\n let classKeyIndex = -1;\r\n let styleKeyIndex = -1;\r\n let hasDynamicKey = false;\r\n for (let i = 0; i < propsExpression.properties.length; i++) {\r\n const key = propsExpression.properties[i].key;\r\n if (isStaticExp(key)) {\r\n if (key.content === 'class') {\r\n classKeyIndex = i;\r\n }\r\n else if (key.content === 'style') {\r\n styleKeyIndex = i;\r\n }\r\n }\r\n else if (!key.isHandlerKey) {\r\n hasDynamicKey = true;\r\n }\r\n }\r\n const classProp = propsExpression.properties[classKeyIndex];\r\n const styleProp = propsExpression.properties[styleKeyIndex];\r\n // no dynamic key\r\n if (!hasDynamicKey) {\r\n if (classProp && !isStaticExp(classProp.value)) {\r\n classProp.value = createCallExpression(context.helper(NORMALIZE_CLASS), [classProp.value]);\r\n }\r\n if (styleProp &&\r\n !isStaticExp(styleProp.value) &&\r\n // the static style is compiled into an object,\r\n // so use `hasStyleBinding` to ensure that it is a dynamic style binding\r\n (hasStyleBinding ||\r\n // v-bind:style and style both exist,\r\n // v-bind:style with static literal object\r\n styleProp.value.type === 17 /* JS_ARRAY_EXPRESSION */)) {\r\n styleProp.value = createCallExpression(context.helper(NORMALIZE_STYLE), [styleProp.value]);\r\n }\r\n }\r\n else {\r\n // dynamic key binding, wrap with `normalizeProps`\r\n propsExpression = createCallExpression(context.helper(NORMALIZE_PROPS), [propsExpression]);\r\n }\r\n break;\r\n case 14 /* JS_CALL_EXPRESSION */:\r\n // mergeProps call, do nothing\r\n break;\r\n default:\r\n // single v-bind\r\n propsExpression = createCallExpression(context.helper(NORMALIZE_PROPS), [\r\n createCallExpression(context.helper(GUARD_REACTIVE_PROPS), [\r\n propsExpression\r\n ])\r\n ]);\r\n break;\r\n }\r\n }\r\n return {\r\n props: propsExpression,\r\n directives: runtimeDirectives,\r\n patchFlag,\r\n dynamicPropNames\r\n };\r\n}\r\n// Dedupe props in an object literal.\r\n// Literal duplicated attributes would have been warned during the parse phase,\r\n// however, it's possible to encounter duplicated `onXXX` handlers with different\r\n// modifiers. We also need to merge static and dynamic class / style attributes.\r\n// - onXXX handlers / style: merge into array\r\n// - class: merge into single expression with concatenation\r\nfunction dedupeProperties(properties) {\r\n const knownProps = new Map();\r\n const deduped = [];\r\n for (let i = 0; i < properties.length; i++) {\r\n const prop = properties[i];\r\n // dynamic keys are always allowed\r\n if (prop.key.type === 8 /* COMPOUND_EXPRESSION */ || !prop.key.isStatic) {\r\n deduped.push(prop);\r\n continue;\r\n }\r\n const name = prop.key.content;\r\n const existing = knownProps.get(name);\r\n if (existing) {\r\n if (name === 'style' || name === 'class' || isOn(name)) {\r\n mergeAsArray(existing, prop);\r\n }\r\n // unexpected duplicate, should have emitted error during parse\r\n }\r\n else {\r\n knownProps.set(name, prop);\r\n deduped.push(prop);\r\n }\r\n }\r\n return deduped;\r\n}\r\nfunction mergeAsArray(existing, incoming) {\r\n if (existing.value.type === 17 /* JS_ARRAY_EXPRESSION */) {\r\n existing.value.elements.push(incoming.value);\r\n }\r\n else {\r\n existing.value = createArrayExpression([existing.value, incoming.value], existing.loc);\r\n }\r\n}\r\nfunction buildDirectiveArgs(dir, context) {\r\n const dirArgs = [];\r\n const runtime = directiveImportMap.get(dir);\r\n if (runtime) {\r\n // built-in directive with runtime\r\n dirArgs.push(context.helperString(runtime));\r\n }\r\n else {\r\n {\r\n // inject statement for resolving directive\r\n context.helper(RESOLVE_DIRECTIVE);\r\n context.directives.add(dir.name);\r\n dirArgs.push(toValidAssetId(dir.name, `directive`));\r\n }\r\n }\r\n const { loc } = dir;\r\n if (dir.exp)\r\n dirArgs.push(dir.exp);\r\n if (dir.arg) {\r\n if (!dir.exp) {\r\n dirArgs.push(`void 0`);\r\n }\r\n dirArgs.push(dir.arg);\r\n }\r\n if (Object.keys(dir.modifiers).length) {\r\n if (!dir.arg) {\r\n if (!dir.exp) {\r\n dirArgs.push(`void 0`);\r\n }\r\n dirArgs.push(`void 0`);\r\n }\r\n const trueExpression = createSimpleExpression(`true`, false, loc);\r\n dirArgs.push(createObjectExpression(dir.modifiers.map(modifier => createObjectProperty(modifier, trueExpression)), loc));\r\n }\r\n return createArrayExpression(dirArgs, dir.loc);\r\n}\r\nfunction stringifyDynamicPropNames(props) {\r\n let propsNamesString = `[`;\r\n for (let i = 0, l = props.length; i < l; i++) {\r\n propsNamesString += JSON.stringify(props[i]);\r\n if (i < l - 1)\r\n propsNamesString += ', ';\r\n }\r\n return propsNamesString + `]`;\r\n}\r\nfunction isComponentTag(tag) {\r\n return tag === 'component' || tag === 'Component';\r\n}\n\n(process.env.NODE_ENV !== 'production')\r\n ? Object.freeze({})\r\n : {};\r\n(process.env.NODE_ENV !== 'production') ? Object.freeze([]) : [];\r\nconst cacheStringFunction = (fn) => {\r\n const cache = Object.create(null);\r\n return ((str) => {\r\n const hit = cache[str];\r\n return hit || (cache[str] = fn(str));\r\n });\r\n};\r\nconst camelizeRE = /-(\\w)/g;\r\n/**\r\n * @private\r\n */\r\nconst camelize = cacheStringFunction((str) => {\r\n return str.replace(camelizeRE, (_, c) => (c ? c.toUpperCase() : ''));\r\n});\n\nconst transformSlotOutlet = (node, context) => {\r\n if (isSlotOutlet(node)) {\r\n const { children, loc } = node;\r\n const { slotName, slotProps } = processSlotOutlet(node, context);\r\n const slotArgs = [\r\n context.prefixIdentifiers ? `_ctx.$slots` : `$slots`,\r\n slotName,\r\n '{}',\r\n 'undefined',\r\n 'true'\r\n ];\r\n let expectedLen = 2;\r\n if (slotProps) {\r\n slotArgs[2] = slotProps;\r\n expectedLen = 3;\r\n }\r\n if (children.length) {\r\n slotArgs[3] = createFunctionExpression([], children, false, false, loc);\r\n expectedLen = 4;\r\n }\r\n if (context.scopeId && !context.slotted) {\r\n expectedLen = 5;\r\n }\r\n slotArgs.splice(expectedLen); // remove unused arguments\r\n node.codegenNode = createCallExpression(context.helper(RENDER_SLOT), slotArgs, loc);\r\n }\r\n};\r\nfunction processSlotOutlet(node, context) {\r\n let slotName = `\"default\"`;\r\n let slotProps = undefined;\r\n const nonNameProps = [];\r\n for (let i = 0; i < node.props.length; i++) {\r\n const p = node.props[i];\r\n if (p.type === 6 /* ATTRIBUTE */) {\r\n if (p.value) {\r\n if (p.name === 'name') {\r\n slotName = JSON.stringify(p.value.content);\r\n }\r\n else {\r\n p.name = camelize(p.name);\r\n nonNameProps.push(p);\r\n }\r\n }\r\n }\r\n else {\r\n if (p.name === 'bind' && isBindKey(p.arg, 'name')) {\r\n if (p.exp)\r\n slotName = p.exp;\r\n }\r\n else {\r\n if (p.name === 'bind' && p.arg && isStaticExp(p.arg)) {\r\n p.arg.content = camelize(p.arg.content);\r\n }\r\n nonNameProps.push(p);\r\n }\r\n }\r\n }\r\n if (nonNameProps.length > 0) {\r\n const { props, directives } = buildProps(node, context, nonNameProps);\r\n slotProps = props;\r\n if (directives.length) {\r\n context.onError(createCompilerError(36 /* X_V_SLOT_UNEXPECTED_DIRECTIVE_ON_SLOT_OUTLET */, directives[0].loc));\r\n }\r\n }\r\n return {\r\n slotName,\r\n slotProps\r\n };\r\n}\n\nconst fnExpRE = /^\\s*([\\w$_]+|(async\\s*)?\\([^)]*?\\))\\s*=>|^\\s*(async\\s+)?function(?:\\s+[\\w$]+)?\\s*\\(/;\r\nconst transformOn = (dir, node, context, augmentor) => {\r\n const { loc, modifiers, arg } = dir;\r\n if (!dir.exp && !modifiers.length) {\r\n context.onError(createCompilerError(35 /* X_V_ON_NO_EXPRESSION */, loc));\r\n }\r\n let eventName;\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n if (arg.isStatic) {\r\n const rawName = arg.content;\r\n // for all event listeners, auto convert it to camelCase. See issue #2249\r\n eventName = createSimpleExpression(toHandlerKey(camelize$1(rawName)), true, arg.loc);\r\n }\r\n else {\r\n // #2388\r\n eventName = createCompoundExpression([\r\n `${context.helperString(TO_HANDLER_KEY)}(`,\r\n arg,\r\n `)`\r\n ]);\r\n }\r\n }\r\n else {\r\n // already a compound expression.\r\n eventName = arg;\r\n eventName.children.unshift(`${context.helperString(TO_HANDLER_KEY)}(`);\r\n eventName.children.push(`)`);\r\n }\r\n // handler processing\r\n let exp = dir.exp;\r\n if (exp && !exp.content.trim()) {\r\n exp = undefined;\r\n }\r\n let shouldCache = context.cacheHandlers && !exp && !context.inVOnce;\r\n if (exp) {\r\n const isMemberExp = isMemberExpression(exp.content);\r\n const isInlineStatement = !(isMemberExp || fnExpRE.test(exp.content));\r\n const hasMultipleStatements = exp.content.includes(`;`);\r\n if ((process.env.NODE_ENV !== 'production') && true) {\r\n validateBrowserExpression(exp, context, false, hasMultipleStatements);\r\n }\r\n if (isInlineStatement || (shouldCache && isMemberExp)) {\r\n // wrap inline statement in a function expression\r\n exp = createCompoundExpression([\r\n `${isInlineStatement\r\n ? `$event`\r\n : `${``}(...args)`} => ${hasMultipleStatements ? `{` : `(`}`,\r\n exp,\r\n hasMultipleStatements ? `}` : `)`\r\n ]);\r\n }\r\n }\r\n let ret = {\r\n props: [\r\n createObjectProperty(eventName, exp || createSimpleExpression(`() => {}`, false, loc))\r\n ]\r\n };\r\n // apply extended compiler augmentor\r\n if (augmentor) {\r\n ret = augmentor(ret);\r\n }\r\n if (shouldCache) {\r\n // cache handlers so that it's always the same handler being passed down.\r\n // this avoids unnecessary re-renders when users use inline handlers on\r\n // components.\r\n ret.props[0].value = context.cache(ret.props[0].value);\r\n }\r\n // mark the key as handler for props normalization check\r\n ret.props.forEach(p => (p.key.isHandlerKey = true));\r\n return ret;\r\n};\n\n// v-bind without arg is handled directly in ./transformElements.ts due to it affecting\r\n// codegen for the entire props object. This transform here is only for v-bind\r\n// *with* args.\r\nconst transformBind = (dir, _node, context) => {\r\n const { exp, modifiers, loc } = dir;\r\n const arg = dir.arg;\r\n if (arg.type !== 4 /* SIMPLE_EXPRESSION */) {\r\n arg.children.unshift(`(`);\r\n arg.children.push(`) || \"\"`);\r\n }\r\n else if (!arg.isStatic) {\r\n arg.content = `${arg.content} || \"\"`;\r\n }\r\n // .sync is replaced by v-model:arg\r\n if (modifiers.includes('camel')) {\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n if (arg.isStatic) {\r\n arg.content = camelize$1(arg.content);\r\n }\r\n else {\r\n arg.content = `${context.helperString(CAMELIZE)}(${arg.content})`;\r\n }\r\n }\r\n else {\r\n arg.children.unshift(`${context.helperString(CAMELIZE)}(`);\r\n arg.children.push(`)`);\r\n }\r\n }\r\n if (!context.inSSR) {\r\n if (modifiers.includes('prop')) {\r\n injectPrefix(arg, '.');\r\n }\r\n if (modifiers.includes('attr')) {\r\n injectPrefix(arg, '^');\r\n }\r\n }\r\n if (!exp ||\r\n (exp.type === 4 /* SIMPLE_EXPRESSION */ && !exp.content.trim())) {\r\n context.onError(createCompilerError(34 /* X_V_BIND_NO_EXPRESSION */, loc));\r\n return {\r\n props: [createObjectProperty(arg, createSimpleExpression('', true, loc))]\r\n };\r\n }\r\n return {\r\n props: [createObjectProperty(arg, exp)]\r\n };\r\n};\r\nconst injectPrefix = (arg, prefix) => {\r\n if (arg.type === 4 /* SIMPLE_EXPRESSION */) {\r\n if (arg.isStatic) {\r\n arg.content = prefix + arg.content;\r\n }\r\n else {\r\n arg.content = `\\`${prefix}\\${${arg.content}}\\``;\r\n }\r\n }\r\n else {\r\n arg.children.unshift(`'${prefix}' + (`);\r\n arg.children.push(`)`);\r\n }\r\n};\n\n// Merge adjacent text nodes and expressions into a single expression\r\n// e.g. <div>abc {{ d }} {{ e }}</div> should have a single expression node as child.\r\nconst transformText = (node, context) => {\r\n if (node.type === 0 /* ROOT */ ||\r\n node.type === 1 /* ELEMENT */ ||\r\n node.type === 11 /* FOR */ ||\r\n node.type === 10 /* IF_BRANCH */) {\r\n // perform the transform on node exit so that all expressions have already\r\n // been processed.\r\n return () => {\r\n const children = node.children;\r\n let currentContainer = undefined;\r\n let hasText = false;\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (isText(child)) {\r\n hasText = true;\r\n for (let j = i + 1; j < children.length; j++) {\r\n const next = children[j];\r\n if (isText(next)) {\r\n if (!currentContainer) {\r\n currentContainer = children[i] = {\r\n type: 8 /* COMPOUND_EXPRESSION */,\r\n loc: child.loc,\r\n children: [child]\r\n };\r\n }\r\n // merge adjacent text node into current\r\n currentContainer.children.push(` + `, next);\r\n children.splice(j, 1);\r\n j--;\r\n }\r\n else {\r\n currentContainer = undefined;\r\n break;\r\n }\r\n }\r\n }\r\n }\r\n if (!hasText ||\r\n // if this is a plain element with a single text child, leave it\r\n // as-is since the runtime has dedicated fast path for this by directly\r\n // setting textContent of the element.\r\n // for component root it's always normalized anyway.\r\n (children.length === 1 &&\r\n (node.type === 0 /* ROOT */ ||\r\n (node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 0 /* ELEMENT */ &&\r\n // #3756\r\n // custom directives can potentially add DOM elements arbitrarily,\r\n // we need to avoid setting textContent of the element at runtime\r\n // to avoid accidentally overwriting the DOM elements added\r\n // by the user through custom directives.\r\n !node.props.find(p => p.type === 7 /* DIRECTIVE */ &&\r\n !context.directiveTransforms[p.name]) &&\r\n // in compat mode, <template> tags with no special directives\r\n // will be rendered as a fragment so its children must be\r\n // converted into vnodes.\r\n !(node.tag === 'template'))))) {\r\n return;\r\n }\r\n // pre-convert text nodes into createTextVNode(text) calls to avoid\r\n // runtime normalization.\r\n for (let i = 0; i < children.length; i++) {\r\n const child = children[i];\r\n if (isText(child) || child.type === 8 /* COMPOUND_EXPRESSION */) {\r\n const callArgs = [];\r\n // createTextVNode defaults to single whitespace, so if it is a\r\n // single space the code could be an empty call to save bytes.\r\n if (child.type !== 2 /* TEXT */ || child.content !== ' ') {\r\n callArgs.push(child);\r\n }\r\n // mark dynamic text with flag so it gets patched inside a block\r\n if (!context.ssr &&\r\n getConstantType(child, context) === 0 /* NOT_CONSTANT */) {\r\n callArgs.push(1 /* TEXT */ +\r\n ((process.env.NODE_ENV !== 'production') ? ` /* ${PatchFlagNames[1 /* TEXT */]} */` : ``));\r\n }\r\n children[i] = {\r\n type: 12 /* TEXT_CALL */,\r\n content: child,\r\n loc: child.loc,\r\n codegenNode: createCallExpression(context.helper(CREATE_TEXT), callArgs)\r\n };\r\n }\r\n }\r\n };\r\n }\r\n};\n\nconst seen = new WeakSet();\r\nconst transformOnce = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ && findDir(node, 'once', true)) {\r\n if (seen.has(node) || context.inVOnce) {\r\n return;\r\n }\r\n seen.add(node);\r\n context.inVOnce = true;\r\n context.helper(SET_BLOCK_TRACKING);\r\n return () => {\r\n context.inVOnce = false;\r\n const cur = context.currentNode;\r\n if (cur.codegenNode) {\r\n cur.codegenNode = context.cache(cur.codegenNode, true /* isVNode */);\r\n }\r\n };\r\n }\r\n};\n\nconst transformModel = (dir, node, context) => {\r\n const { exp, arg } = dir;\r\n if (!exp) {\r\n context.onError(createCompilerError(41 /* X_V_MODEL_NO_EXPRESSION */, dir.loc));\r\n return createTransformProps();\r\n }\r\n const rawExp = exp.loc.source;\r\n const expString = exp.type === 4 /* SIMPLE_EXPRESSION */ ? exp.content : rawExp;\r\n // im SFC <script setup> inline mode, the exp may have been transformed into\r\n // _unref(exp)\r\n context.bindingMetadata[rawExp];\r\n const maybeRef = !true /* SETUP_CONST */;\r\n if (!expString.trim() ||\r\n (!isMemberExpression(expString) && !maybeRef)) {\r\n context.onError(createCompilerError(42 /* X_V_MODEL_MALFORMED_EXPRESSION */, exp.loc));\r\n return createTransformProps();\r\n }\r\n const propName = arg ? arg : createSimpleExpression('modelValue', true);\r\n const eventName = arg\r\n ? isStaticExp(arg)\r\n ? `onUpdate:${arg.content}`\r\n : createCompoundExpression(['\"onUpdate:\" + ', arg])\r\n : `onUpdate:modelValue`;\r\n let assignmentExp;\r\n const eventArg = context.isTS ? `($event: any)` : `$event`;\r\n {\r\n assignmentExp = createCompoundExpression([\r\n `${eventArg} => ((`,\r\n exp,\r\n `) = $event)`\r\n ]);\r\n }\r\n const props = [\r\n // modelValue: foo\r\n createObjectProperty(propName, dir.exp),\r\n // \"onUpdate:modelValue\": $event => (foo = $event)\r\n createObjectProperty(eventName, assignmentExp)\r\n ];\r\n // modelModifiers: { foo: true, \"bar-baz\": true }\r\n if (dir.modifiers.length && node.tagType === 1 /* COMPONENT */) {\r\n const modifiers = dir.modifiers\r\n .map(m => (isSimpleIdentifier(m) ? m : JSON.stringify(m)) + `: true`)\r\n .join(`, `);\r\n const modifiersKey = arg\r\n ? isStaticExp(arg)\r\n ? `${arg.content}Modifiers`\r\n : createCompoundExpression([arg, ' + \"Modifiers\"'])\r\n : `modelModifiers`;\r\n props.push(createObjectProperty(modifiersKey, createSimpleExpression(`{ ${modifiers} }`, false, dir.loc, 2 /* CAN_HOIST */)));\r\n }\r\n return createTransformProps(props);\r\n};\r\nfunction createTransformProps(props = []) {\r\n return { props };\r\n}\n\nconst validDivisionCharRE = /[\\w).+\\-_$\\]]/;\r\nconst transformFilter = (node, context) => {\r\n if (!isCompatEnabled(\"COMPILER_FILTER\" /* COMPILER_FILTERS */, context)) {\r\n return;\r\n }\r\n if (node.type === 5 /* INTERPOLATION */) {\r\n // filter rewrite is applied before expression transform so only\r\n // simple expressions are possible at this stage\r\n rewriteFilter(node.content, context);\r\n }\r\n if (node.type === 1 /* ELEMENT */) {\r\n node.props.forEach((prop) => {\r\n if (prop.type === 7 /* DIRECTIVE */ &&\r\n prop.name !== 'for' &&\r\n prop.exp) {\r\n rewriteFilter(prop.exp, context);\r\n }\r\n });\r\n }\r\n};\r\nfunction rewriteFilter(node, context) {\r\n if (node.type === 4 /* SIMPLE_EXPRESSION */) {\r\n parseFilter(node, context);\r\n }\r\n else {\r\n for (let i = 0; i < node.children.length; i++) {\r\n const child = node.children[i];\r\n if (typeof child !== 'object')\r\n continue;\r\n if (child.type === 4 /* SIMPLE_EXPRESSION */) {\r\n parseFilter(child, context);\r\n }\r\n else if (child.type === 8 /* COMPOUND_EXPRESSION */) {\r\n rewriteFilter(node, context);\r\n }\r\n else if (child.type === 5 /* INTERPOLATION */) {\r\n rewriteFilter(child.content, context);\r\n }\r\n }\r\n }\r\n}\r\nfunction parseFilter(node, context) {\r\n const exp = node.content;\r\n let inSingle = false;\r\n let inDouble = false;\r\n let inTemplateString = false;\r\n let inRegex = false;\r\n let curly = 0;\r\n let square = 0;\r\n let paren = 0;\r\n let lastFilterIndex = 0;\r\n let c, prev, i, expression, filters = [];\r\n for (i = 0; i < exp.length; i++) {\r\n prev = c;\r\n c = exp.charCodeAt(i);\r\n if (inSingle) {\r\n if (c === 0x27 && prev !== 0x5c)\r\n inSingle = false;\r\n }\r\n else if (inDouble) {\r\n if (c === 0x22 && prev !== 0x5c)\r\n inDouble = false;\r\n }\r\n else if (inTemplateString) {\r\n if (c === 0x60 && prev !== 0x5c)\r\n inTemplateString = false;\r\n }\r\n else if (inRegex) {\r\n if (c === 0x2f && prev !== 0x5c)\r\n inRegex = false;\r\n }\r\n else if (c === 0x7c && // pipe\r\n exp.charCodeAt(i + 1) !== 0x7c &&\r\n exp.charCodeAt(i - 1) !== 0x7c &&\r\n !curly &&\r\n !square &&\r\n !paren) {\r\n if (expression === undefined) {\r\n // first filter, end of expression\r\n lastFilterIndex = i + 1;\r\n expression = exp.slice(0, i).trim();\r\n }\r\n else {\r\n pushFilter();\r\n }\r\n }\r\n else {\r\n switch (c) {\r\n case 0x22:\r\n inDouble = true;\r\n break; // \"\r\n case 0x27:\r\n inSingle = true;\r\n break; // '\r\n case 0x60:\r\n inTemplateString = true;\r\n break; // `\r\n case 0x28:\r\n paren++;\r\n break; // (\r\n case 0x29:\r\n paren--;\r\n break; // )\r\n case 0x5b:\r\n square++;\r\n break; // [\r\n case 0x5d:\r\n square--;\r\n break; // ]\r\n case 0x7b:\r\n curly++;\r\n break; // {\r\n case 0x7d:\r\n curly--;\r\n break; // }\r\n }\r\n if (c === 0x2f) {\r\n // /\r\n let j = i - 1;\r\n let p;\r\n // find first non-whitespace prev char\r\n for (; j >= 0; j--) {\r\n p = exp.charAt(j);\r\n if (p !== ' ')\r\n break;\r\n }\r\n if (!p || !validDivisionCharRE.test(p)) {\r\n inRegex = true;\r\n }\r\n }\r\n }\r\n }\r\n if (expression === undefined) {\r\n expression = exp.slice(0, i).trim();\r\n }\r\n else if (lastFilterIndex !== 0) {\r\n pushFilter();\r\n }\r\n function pushFilter() {\r\n filters.push(exp.slice(lastFilterIndex, i).trim());\r\n lastFilterIndex = i + 1;\r\n }\r\n if (filters.length) {\r\n (process.env.NODE_ENV !== 'production') &&\r\n warnDeprecation(\"COMPILER_FILTER\" /* COMPILER_FILTERS */, context, node.loc);\r\n for (i = 0; i < filters.length; i++) {\r\n expression = wrapFilter(expression, filters[i], context);\r\n }\r\n node.content = expression;\r\n }\r\n}\r\nfunction wrapFilter(exp, filter, context) {\r\n context.helper(RESOLVE_FILTER);\r\n const i = filter.indexOf('(');\r\n if (i < 0) {\r\n context.filters.add(filter);\r\n return `${toValidAssetId(filter, 'filter')}(${exp})`;\r\n }\r\n else {\r\n const name = filter.slice(0, i);\r\n const args = filter.slice(i + 1);\r\n context.filters.add(name);\r\n return `${toValidAssetId(name, 'filter')}(${exp}${args !== ')' ? ',' + args : args}`;\r\n }\r\n}\n\nconst seen$1 = new WeakSet();\r\nconst transformMemo = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */) {\r\n const dir = findDir(node, 'memo');\r\n if (!dir || seen$1.has(node)) {\r\n return;\r\n }\r\n seen$1.add(node);\r\n return () => {\r\n const codegenNode = node.codegenNode ||\r\n context.currentNode.codegenNode;\r\n if (codegenNode && codegenNode.type === 13 /* VNODE_CALL */) {\r\n // non-component sub tree should be turned into a block\r\n if (node.tagType !== 1 /* COMPONENT */) {\r\n makeBlock(codegenNode, context);\r\n }\r\n node.codegenNode = createCallExpression(context.helper(WITH_MEMO), [\r\n dir.exp,\r\n createFunctionExpression(undefined, codegenNode),\r\n `_cache`,\r\n String(context.cached++)\r\n ]);\r\n }\r\n };\r\n }\r\n};\n\nfunction getBaseTransformPreset(prefixIdentifiers) {\r\n return [\r\n [\r\n transformOnce,\r\n transformIf,\r\n transformMemo,\r\n transformFor,\r\n ...([transformFilter] ),\r\n ...((process.env.NODE_ENV !== 'production')\r\n ? [transformExpression]\r\n : []),\r\n transformSlotOutlet,\r\n transformElement,\r\n trackSlotScopes,\r\n transformText\r\n ],\r\n {\r\n on: transformOn,\r\n bind: transformBind,\r\n model: transformModel\r\n }\r\n ];\r\n}\r\n// we name it `baseCompile` so that higher order compilers like\r\n// @vue/compiler-dom can export `compile` while re-exporting everything else.\r\nfunction baseCompile(template, options = {}) {\r\n const onError = options.onError || defaultOnError;\r\n const isModuleMode = options.mode === 'module';\r\n /* istanbul ignore if */\r\n {\r\n if (options.prefixIdentifiers === true) {\r\n onError(createCompilerError(46 /* X_PREFIX_ID_NOT_SUPPORTED */));\r\n }\r\n else if (isModuleMode) {\r\n onError(createCompilerError(47 /* X_MODULE_MODE_NOT_SUPPORTED */));\r\n }\r\n }\r\n const prefixIdentifiers = !true ;\r\n if (options.cacheHandlers) {\r\n onError(createCompilerError(48 /* X_CACHE_HANDLER_NOT_SUPPORTED */));\r\n }\r\n if (options.scopeId && !isModuleMode) {\r\n onError(createCompilerError(49 /* X_SCOPE_ID_NOT_SUPPORTED */));\r\n }\r\n const ast = isString(template) ? baseParse(template, options) : template;\r\n const [nodeTransforms, directiveTransforms] = getBaseTransformPreset();\r\n transform(ast, extend({}, options, {\r\n prefixIdentifiers,\r\n nodeTransforms: [\r\n ...nodeTransforms,\r\n ...(options.nodeTransforms || []) // user transforms\r\n ],\r\n directiveTransforms: extend({}, directiveTransforms, options.directiveTransforms || {} // user transforms\r\n )\r\n }));\r\n return generate(ast, extend({}, options, {\r\n prefixIdentifiers\r\n }));\r\n}\n\nconst noopDirectiveTransform = () => ({ props: [] });\n\nexport { BASE_TRANSITION, CAMELIZE, CAPITALIZE, CREATE_BLOCK, CREATE_COMMENT, CREATE_ELEMENT_BLOCK, CREATE_ELEMENT_VNODE, CREATE_SLOTS, CREATE_STATIC, CREATE_TEXT, CREATE_VNODE, FRAGMENT, GUARD_REACTIVE_PROPS, IS_MEMO_SAME, IS_REF, KEEP_ALIVE, MERGE_PROPS, NORMALIZE_CLASS, NORMALIZE_PROPS, NORMALIZE_STYLE, OPEN_BLOCK, POP_SCOPE_ID, PUSH_SCOPE_ID, RENDER_LIST, RENDER_SLOT, RESOLVE_COMPONENT, RESOLVE_DIRECTIVE, RESOLVE_DYNAMIC_COMPONENT, RESOLVE_FILTER, SET_BLOCK_TRACKING, SUSPENSE, TELEPORT, TO_DISPLAY_STRING, TO_HANDLERS, TO_HANDLER_KEY, UNREF, WITH_CTX, WITH_DIRECTIVES, WITH_MEMO, advancePositionWithClone, advancePositionWithMutation, assert, baseCompile, baseParse, buildProps, buildSlots, checkCompatEnabled, createArrayExpression, createAssignmentExpression, createBlockStatement, createCacheExpression, createCallExpression, createCompilerError, createCompoundExpression, createConditionalExpression, createForLoopParams, createFunctionExpression, createIfStatement, createInterpolation, createObjectExpression, createObjectProperty, createReturnStatement, createRoot, createSequenceExpression, createSimpleExpression, createStructuralDirectiveTransform, createTemplateLiteral, createTransformContext, createVNodeCall, extractIdentifiers, findDir, findProp, generate, getBaseTransformPreset, getInnerRange, getMemoedVNodeCall, getVNodeBlockHelper, getVNodeHelper, hasDynamicKeyVBind, hasScopeRef, helperNameMap, injectProp, isBindKey, isBuiltInType, isCoreComponent, isFunctionType, isInDestructureAssignment, isMemberExpression, isMemberExpressionBrowser, isMemberExpressionNode, isReferencedIdentifier, isSimpleIdentifier, isSlotOutlet, isStaticExp, isStaticProperty, isStaticPropertyKey, isTemplateNode, isText, isVSlot, locStub, makeBlock, noopDirectiveTransform, processExpression, processFor, processIf, processSlotOutlet, registerRuntimeHelpers, resolveComponentType, toValidAssetId, trackSlotScopes, trackVForSlotScopes, transform, transformBind, transformElement, transformExpression, transformModel, transformOn, traverseNode, walkBlockDeclarations, walkFunctionParams, walkIdentifiers, warnDeprecation };\n","import { registerRuntimeHelpers, isBuiltInType, createSimpleExpression, createCompilerError, createObjectProperty, createCallExpression, TO_DISPLAY_STRING, transformModel as transformModel$1, findProp, hasDynamicKeyVBind, transformOn as transformOn$1, createCompoundExpression, isStaticExp, checkCompatEnabled, noopDirectiveTransform, baseCompile, baseParse } from '@vue/compiler-core';\nexport * from '@vue/compiler-core';\nimport { isVoidTag, isHTMLTag, isSVGTag, makeMap, parseStringStyle, capitalize, extend } from '@vue/shared';\n\nconst V_MODEL_RADIO = Symbol((process.env.NODE_ENV !== 'production') ? `vModelRadio` : ``);\r\nconst V_MODEL_CHECKBOX = Symbol((process.env.NODE_ENV !== 'production') ? `vModelCheckbox` : ``);\r\nconst V_MODEL_TEXT = Symbol((process.env.NODE_ENV !== 'production') ? `vModelText` : ``);\r\nconst V_MODEL_SELECT = Symbol((process.env.NODE_ENV !== 'production') ? `vModelSelect` : ``);\r\nconst V_MODEL_DYNAMIC = Symbol((process.env.NODE_ENV !== 'production') ? `vModelDynamic` : ``);\r\nconst V_ON_WITH_MODIFIERS = Symbol((process.env.NODE_ENV !== 'production') ? `vOnModifiersGuard` : ``);\r\nconst V_ON_WITH_KEYS = Symbol((process.env.NODE_ENV !== 'production') ? `vOnKeysGuard` : ``);\r\nconst V_SHOW = Symbol((process.env.NODE_ENV !== 'production') ? `vShow` : ``);\r\nconst TRANSITION = Symbol((process.env.NODE_ENV !== 'production') ? `Transition` : ``);\r\nconst TRANSITION_GROUP = Symbol((process.env.NODE_ENV !== 'production') ? `TransitionGroup` : ``);\r\nregisterRuntimeHelpers({\r\n [V_MODEL_RADIO]: `vModelRadio`,\r\n [V_MODEL_CHECKBOX]: `vModelCheckbox`,\r\n [V_MODEL_TEXT]: `vModelText`,\r\n [V_MODEL_SELECT]: `vModelSelect`,\r\n [V_MODEL_DYNAMIC]: `vModelDynamic`,\r\n [V_ON_WITH_MODIFIERS]: `withModifiers`,\r\n [V_ON_WITH_KEYS]: `withKeys`,\r\n [V_SHOW]: `vShow`,\r\n [TRANSITION]: `Transition`,\r\n [TRANSITION_GROUP]: `TransitionGroup`\r\n});\n\n/* eslint-disable no-restricted-globals */\r\nlet decoder;\r\nfunction decodeHtmlBrowser(raw, asAttr = false) {\r\n if (!decoder) {\r\n decoder = document.createElement('div');\r\n }\r\n if (asAttr) {\r\n decoder.innerHTML = `<div foo=\"${raw.replace(/\"/g, '&quot;')}\">`;\r\n return decoder.children[0].getAttribute('foo');\r\n }\r\n else {\r\n decoder.innerHTML = raw;\r\n return decoder.textContent;\r\n }\r\n}\n\nconst isRawTextContainer = /*#__PURE__*/ makeMap('style,iframe,script,noscript', true);\r\nconst parserOptions = {\r\n isVoidTag,\r\n isNativeTag: tag => isHTMLTag(tag) || isSVGTag(tag),\r\n isPreTag: tag => tag === 'pre',\r\n decodeEntities: decodeHtmlBrowser ,\r\n isBuiltInComponent: (tag) => {\r\n if (isBuiltInType(tag, `Transition`)) {\r\n return TRANSITION;\r\n }\r\n else if (isBuiltInType(tag, `TransitionGroup`)) {\r\n return TRANSITION_GROUP;\r\n }\r\n },\r\n // https://html.spec.whatwg.org/multipage/parsing.html#tree-construction-dispatcher\r\n getNamespace(tag, parent) {\r\n let ns = parent ? parent.ns : 0 /* HTML */;\r\n if (parent && ns === 2 /* MATH_ML */) {\r\n if (parent.tag === 'annotation-xml') {\r\n if (tag === 'svg') {\r\n return 1 /* SVG */;\r\n }\r\n if (parent.props.some(a => a.type === 6 /* ATTRIBUTE */ &&\r\n a.name === 'encoding' &&\r\n a.value != null &&\r\n (a.value.content === 'text/html' ||\r\n a.value.content === 'application/xhtml+xml'))) {\r\n ns = 0 /* HTML */;\r\n }\r\n }\r\n else if (/^m(?:[ions]|text)$/.test(parent.tag) &&\r\n tag !== 'mglyph' &&\r\n tag !== 'malignmark') {\r\n ns = 0 /* HTML */;\r\n }\r\n }\r\n else if (parent && ns === 1 /* SVG */) {\r\n if (parent.tag === 'foreignObject' ||\r\n parent.tag === 'desc' ||\r\n parent.tag === 'title') {\r\n ns = 0 /* HTML */;\r\n }\r\n }\r\n if (ns === 0 /* HTML */) {\r\n if (tag === 'svg') {\r\n return 1 /* SVG */;\r\n }\r\n if (tag === 'math') {\r\n return 2 /* MATH_ML */;\r\n }\r\n }\r\n return ns;\r\n },\r\n // https://html.spec.whatwg.org/multipage/parsing.html#parsing-html-fragments\r\n getTextMode({ tag, ns }) {\r\n if (ns === 0 /* HTML */) {\r\n if (tag === 'textarea' || tag === 'title') {\r\n return 1 /* RCDATA */;\r\n }\r\n if (isRawTextContainer(tag)) {\r\n return 2 /* RAWTEXT */;\r\n }\r\n }\r\n return 0 /* DATA */;\r\n }\r\n};\n\n// Parse inline CSS strings for static style attributes into an object.\r\n// This is a NodeTransform since it works on the static `style` attribute and\r\n// converts it into a dynamic equivalent:\r\n// style=\"color: red\" -> :style='{ \"color\": \"red\" }'\r\n// It is then processed by `transformElement` and included in the generated\r\n// props.\r\nconst transformStyle = node => {\r\n if (node.type === 1 /* ELEMENT */) {\r\n node.props.forEach((p, i) => {\r\n if (p.type === 6 /* ATTRIBUTE */ && p.name === 'style' && p.value) {\r\n // replace p with an expression node\r\n node.props[i] = {\r\n type: 7 /* DIRECTIVE */,\r\n name: `bind`,\r\n arg: createSimpleExpression(`style`, true, p.loc),\r\n exp: parseInlineCSS(p.value.content, p.loc),\r\n modifiers: [],\r\n loc: p.loc\r\n };\r\n }\r\n });\r\n }\r\n};\r\nconst parseInlineCSS = (cssText, loc) => {\r\n const normalized = parseStringStyle(cssText);\r\n return createSimpleExpression(JSON.stringify(normalized), false, loc, 3 /* CAN_STRINGIFY */);\r\n};\n\nfunction createDOMCompilerError(code, loc) {\r\n return createCompilerError(code, loc, (process.env.NODE_ENV !== 'production') || !true ? DOMErrorMessages : undefined);\r\n}\r\nconst DOMErrorMessages = {\r\n [50 /* X_V_HTML_NO_EXPRESSION */]: `v-html is missing expression.`,\r\n [51 /* X_V_HTML_WITH_CHILDREN */]: `v-html will override element children.`,\r\n [52 /* X_V_TEXT_NO_EXPRESSION */]: `v-text is missing expression.`,\r\n [53 /* X_V_TEXT_WITH_CHILDREN */]: `v-text will override element children.`,\r\n [54 /* X_V_MODEL_ON_INVALID_ELEMENT */]: `v-model can only be used on <input>, <textarea> and <select> elements.`,\r\n [55 /* X_V_MODEL_ARG_ON_ELEMENT */]: `v-model argument is not supported on plain elements.`,\r\n [56 /* X_V_MODEL_ON_FILE_INPUT_ELEMENT */]: `v-model cannot be used on file inputs since they are read-only. Use a v-on:change listener instead.`,\r\n [57 /* X_V_MODEL_UNNECESSARY_VALUE */]: `Unnecessary value binding used alongside v-model. It will interfere with v-model's behavior.`,\r\n [58 /* X_V_SHOW_NO_EXPRESSION */]: `v-show is missing expression.`,\r\n [59 /* X_TRANSITION_INVALID_CHILDREN */]: `<Transition> expects exactly one child element or component.`,\r\n [60 /* X_IGNORED_SIDE_EFFECT_TAG */]: `Tags with side effect (<script> and <style>) are ignored in client component templates.`\r\n};\n\nconst transformVHtml = (dir, node, context) => {\r\n const { exp, loc } = dir;\r\n if (!exp) {\r\n context.onError(createDOMCompilerError(50 /* X_V_HTML_NO_EXPRESSION */, loc));\r\n }\r\n if (node.children.length) {\r\n context.onError(createDOMCompilerError(51 /* X_V_HTML_WITH_CHILDREN */, loc));\r\n node.children.length = 0;\r\n }\r\n return {\r\n props: [\r\n createObjectProperty(createSimpleExpression(`innerHTML`, true, loc), exp || createSimpleExpression('', true))\r\n ]\r\n };\r\n};\n\nconst transformVText = (dir, node, context) => {\r\n const { exp, loc } = dir;\r\n if (!exp) {\r\n context.onError(createDOMCompilerError(52 /* X_V_TEXT_NO_EXPRESSION */, loc));\r\n }\r\n if (node.children.length) {\r\n context.onError(createDOMCompilerError(53 /* X_V_TEXT_WITH_CHILDREN */, loc));\r\n node.children.length = 0;\r\n }\r\n return {\r\n props: [\r\n createObjectProperty(createSimpleExpression(`textContent`, true), exp\r\n ? createCallExpression(context.helperString(TO_DISPLAY_STRING), [exp], loc)\r\n : createSimpleExpression('', true))\r\n ]\r\n };\r\n};\n\nconst transformModel = (dir, node, context) => {\r\n const baseResult = transformModel$1(dir, node, context);\r\n // base transform has errors OR component v-model (only need props)\r\n if (!baseResult.props.length || node.tagType === 1 /* COMPONENT */) {\r\n return baseResult;\r\n }\r\n if (dir.arg) {\r\n context.onError(createDOMCompilerError(55 /* X_V_MODEL_ARG_ON_ELEMENT */, dir.arg.loc));\r\n }\r\n function checkDuplicatedValue() {\r\n const value = findProp(node, 'value');\r\n if (value) {\r\n context.onError(createDOMCompilerError(57 /* X_V_MODEL_UNNECESSARY_VALUE */, value.loc));\r\n }\r\n }\r\n const { tag } = node;\r\n const isCustomElement = context.isCustomElement(tag);\r\n if (tag === 'input' ||\r\n tag === 'textarea' ||\r\n tag === 'select' ||\r\n isCustomElement) {\r\n let directiveToUse = V_MODEL_TEXT;\r\n let isInvalidType = false;\r\n if (tag === 'input' || isCustomElement) {\r\n const type = findProp(node, `type`);\r\n if (type) {\r\n if (type.type === 7 /* DIRECTIVE */) {\r\n // :type=\"foo\"\r\n directiveToUse = V_MODEL_DYNAMIC;\r\n }\r\n else if (type.value) {\r\n switch (type.value.content) {\r\n case 'radio':\r\n directiveToUse = V_MODEL_RADIO;\r\n break;\r\n case 'checkbox':\r\n directiveToUse = V_MODEL_CHECKBOX;\r\n break;\r\n case 'file':\r\n isInvalidType = true;\r\n context.onError(createDOMCompilerError(56 /* X_V_MODEL_ON_FILE_INPUT_ELEMENT */, dir.loc));\r\n break;\r\n default:\r\n // text type\r\n (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n break;\r\n }\r\n }\r\n }\r\n else if (hasDynamicKeyVBind(node)) {\r\n // element has bindings with dynamic keys, which can possibly contain\r\n // \"type\".\r\n directiveToUse = V_MODEL_DYNAMIC;\r\n }\r\n else {\r\n // text type\r\n (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n }\r\n }\r\n else if (tag === 'select') {\r\n directiveToUse = V_MODEL_SELECT;\r\n }\r\n else {\r\n // textarea\r\n (process.env.NODE_ENV !== 'production') && checkDuplicatedValue();\r\n }\r\n // inject runtime directive\r\n // by returning the helper symbol via needRuntime\r\n // the import will replaced a resolveDirective call.\r\n if (!isInvalidType) {\r\n baseResult.needRuntime = context.helper(directiveToUse);\r\n }\r\n }\r\n else {\r\n context.onError(createDOMCompilerError(54 /* X_V_MODEL_ON_INVALID_ELEMENT */, dir.loc));\r\n }\r\n // native vmodel doesn't need the `modelValue` props since they are also\r\n // passed to the runtime as `binding.value`. removing it reduces code size.\r\n baseResult.props = baseResult.props.filter(p => !(p.key.type === 4 /* SIMPLE_EXPRESSION */ &&\r\n p.key.content === 'modelValue'));\r\n return baseResult;\r\n};\n\nconst isEventOptionModifier = /*#__PURE__*/ makeMap(`passive,once,capture`);\r\nconst isNonKeyModifier = /*#__PURE__*/ makeMap(\r\n// event propagation management\r\n`stop,prevent,self,` +\r\n // system modifiers + exact\r\n `ctrl,shift,alt,meta,exact,` +\r\n // mouse\r\n `middle`);\r\n// left & right could be mouse or key modifiers based on event type\r\nconst maybeKeyModifier = /*#__PURE__*/ makeMap('left,right');\r\nconst isKeyboardEvent = /*#__PURE__*/ makeMap(`onkeyup,onkeydown,onkeypress`, true);\r\nconst resolveModifiers = (key, modifiers, context, loc) => {\r\n const keyModifiers = [];\r\n const nonKeyModifiers = [];\r\n const eventOptionModifiers = [];\r\n for (let i = 0; i < modifiers.length; i++) {\r\n const modifier = modifiers[i];\r\n if (modifier === 'native' &&\r\n checkCompatEnabled(\"COMPILER_V_ON_NATIVE\" /* COMPILER_V_ON_NATIVE */, context, loc)) {\r\n eventOptionModifiers.push(modifier);\r\n }\r\n else if (isEventOptionModifier(modifier)) {\r\n // eventOptionModifiers: modifiers for addEventListener() options,\r\n // e.g. .passive & .capture\r\n eventOptionModifiers.push(modifier);\r\n }\r\n else {\r\n // runtimeModifiers: modifiers that needs runtime guards\r\n if (maybeKeyModifier(modifier)) {\r\n if (isStaticExp(key)) {\r\n if (isKeyboardEvent(key.content)) {\r\n keyModifiers.push(modifier);\r\n }\r\n else {\r\n nonKeyModifiers.push(modifier);\r\n }\r\n }\r\n else {\r\n keyModifiers.push(modifier);\r\n nonKeyModifiers.push(modifier);\r\n }\r\n }\r\n else {\r\n if (isNonKeyModifier(modifier)) {\r\n nonKeyModifiers.push(modifier);\r\n }\r\n else {\r\n keyModifiers.push(modifier);\r\n }\r\n }\r\n }\r\n }\r\n return {\r\n keyModifiers,\r\n nonKeyModifiers,\r\n eventOptionModifiers\r\n };\r\n};\r\nconst transformClick = (key, event) => {\r\n const isStaticClick = isStaticExp(key) && key.content.toLowerCase() === 'onclick';\r\n return isStaticClick\r\n ? createSimpleExpression(event, true)\r\n : key.type !== 4 /* SIMPLE_EXPRESSION */\r\n ? createCompoundExpression([\r\n `(`,\r\n key,\r\n `) === \"onClick\" ? \"${event}\" : (`,\r\n key,\r\n `)`\r\n ])\r\n : key;\r\n};\r\nconst transformOn = (dir, node, context) => {\r\n return transformOn$1(dir, node, context, baseResult => {\r\n const { modifiers } = dir;\r\n if (!modifiers.length)\r\n return baseResult;\r\n let { key, value: handlerExp } = baseResult.props[0];\r\n const { keyModifiers, nonKeyModifiers, eventOptionModifiers } = resolveModifiers(key, modifiers, context, dir.loc);\r\n // normalize click.right and click.middle since they don't actually fire\r\n if (nonKeyModifiers.includes('right')) {\r\n key = transformClick(key, `onContextmenu`);\r\n }\r\n if (nonKeyModifiers.includes('middle')) {\r\n key = transformClick(key, `onMouseup`);\r\n }\r\n if (nonKeyModifiers.length) {\r\n handlerExp = createCallExpression(context.helper(V_ON_WITH_MODIFIERS), [\r\n handlerExp,\r\n JSON.stringify(nonKeyModifiers)\r\n ]);\r\n }\r\n if (keyModifiers.length &&\r\n // if event name is dynamic, always wrap with keys guard\r\n (!isStaticExp(key) || isKeyboardEvent(key.content))) {\r\n handlerExp = createCallExpression(context.helper(V_ON_WITH_KEYS), [\r\n handlerExp,\r\n JSON.stringify(keyModifiers)\r\n ]);\r\n }\r\n if (eventOptionModifiers.length) {\r\n const modifierPostfix = eventOptionModifiers.map(capitalize).join('');\r\n key = isStaticExp(key)\r\n ? createSimpleExpression(`${key.content}${modifierPostfix}`, true)\r\n : createCompoundExpression([`(`, key, `) + \"${modifierPostfix}\"`]);\r\n }\r\n return {\r\n props: [createObjectProperty(key, handlerExp)]\r\n };\r\n });\r\n};\n\nconst transformShow = (dir, node, context) => {\r\n const { exp, loc } = dir;\r\n if (!exp) {\r\n context.onError(createDOMCompilerError(58 /* X_V_SHOW_NO_EXPRESSION */, loc));\r\n }\r\n return {\r\n props: [],\r\n needRuntime: context.helper(V_SHOW)\r\n };\r\n};\n\nconst warnTransitionChildren = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 1 /* COMPONENT */) {\r\n const component = context.isBuiltInComponent(node.tag);\r\n if (component === TRANSITION) {\r\n return () => {\r\n if (node.children.length && hasMultipleChildren(node)) {\r\n context.onError(createDOMCompilerError(59 /* X_TRANSITION_INVALID_CHILDREN */, {\r\n start: node.children[0].loc.start,\r\n end: node.children[node.children.length - 1].loc.end,\r\n source: ''\r\n }));\r\n }\r\n };\r\n }\r\n }\r\n};\r\nfunction hasMultipleChildren(node) {\r\n // #1352 filter out potential comment nodes.\r\n const children = (node.children = node.children.filter(c => c.type !== 3 /* COMMENT */ &&\r\n !(c.type === 2 /* TEXT */ && !c.content.trim())));\r\n const child = children[0];\r\n return (children.length !== 1 ||\r\n child.type === 11 /* FOR */ ||\r\n (child.type === 9 /* IF */ && child.branches.some(hasMultipleChildren)));\r\n}\n\nconst ignoreSideEffectTags = (node, context) => {\r\n if (node.type === 1 /* ELEMENT */ &&\r\n node.tagType === 0 /* ELEMENT */ &&\r\n (node.tag === 'script' || node.tag === 'style')) {\r\n context.onError(createDOMCompilerError(60 /* X_IGNORED_SIDE_EFFECT_TAG */, node.loc));\r\n context.removeNode();\r\n }\r\n};\n\nconst DOMNodeTransforms = [\r\n transformStyle,\r\n ...((process.env.NODE_ENV !== 'production') ? [warnTransitionChildren] : [])\r\n];\r\nconst DOMDirectiveTransforms = {\r\n cloak: noopDirectiveTransform,\r\n html: transformVHtml,\r\n text: transformVText,\r\n model: transformModel,\r\n on: transformOn,\r\n show: transformShow\r\n};\r\nfunction compile(template, options = {}) {\r\n return baseCompile(template, extend({}, parserOptions, options, {\r\n nodeTransforms: [\r\n // ignore <script> and <tag>\r\n // this is not put inside DOMNodeTransforms because that list is used\r\n // by compiler-ssr to generate vnode fallback branches\r\n ignoreSideEffectTags,\r\n ...DOMNodeTransforms,\r\n ...(options.nodeTransforms || [])\r\n ],\r\n directiveTransforms: extend({}, DOMDirectiveTransforms, options.directiveTransforms || {}),\r\n transformHoist: null \r\n }));\r\n}\r\nfunction parse(template, options = {}) {\r\n return baseParse(template, extend({}, parserOptions, options));\r\n}\n\nexport { DOMDirectiveTransforms, DOMNodeTransforms, TRANSITION, TRANSITION_GROUP, V_MODEL_CHECKBOX, V_MODEL_DYNAMIC, V_MODEL_RADIO, V_MODEL_SELECT, V_MODEL_TEXT, V_ON_WITH_KEYS, V_ON_WITH_MODIFIERS, V_SHOW, compile, createDOMCompilerError, parse, parserOptions, transformStyle };\n","import * as runtimeDom from '@vue/runtime-dom';\nimport { initCustomFormatter, warn, registerRuntimeCompiler } from '@vue/runtime-dom';\nexport * from '@vue/runtime-dom';\nimport { compile } from '@vue/compiler-dom';\nimport { isString, NOOP, extend, generateCodeFrame } from '@vue/shared';\n\nfunction initDev() {\r\n {\r\n initCustomFormatter();\r\n }\r\n}\n\n// This entry is the \"full-build\" that includes both the runtime\r\nif ((process.env.NODE_ENV !== 'production')) {\r\n initDev();\r\n}\r\nconst compileCache = Object.create(null);\r\nfunction compileToFunction(template, options) {\r\n if (!isString(template)) {\r\n if (template.nodeType) {\r\n template = template.innerHTML;\r\n }\r\n else {\r\n (process.env.NODE_ENV !== 'production') && warn(`invalid template option: `, template);\r\n return NOOP;\r\n }\r\n }\r\n const key = template;\r\n const cached = compileCache[key];\r\n if (cached) {\r\n return cached;\r\n }\r\n if (template[0] === '#') {\r\n const el = document.querySelector(template);\r\n if ((process.env.NODE_ENV !== 'production') && !el) {\r\n warn(`Template element not found or is empty: ${template}`);\r\n }\r\n // __UNSAFE__\r\n // Reason: potential execution of JS expressions in in-DOM template.\r\n // The user must make sure the in-DOM template is trusted. If it's rendered\r\n // by the server, the template should not contain any user data.\r\n template = el ? el.innerHTML : ``;\r\n }\r\n const { code } = compile(template, extend({\r\n hoistStatic: true,\r\n onError: (process.env.NODE_ENV !== 'production') ? onError : undefined,\r\n onWarn: (process.env.NODE_ENV !== 'production') ? e => onError(e, true) : NOOP\r\n }, options));\r\n function onError(err, asWarning = false) {\r\n const message = asWarning\r\n ? err.message\r\n : `Template compilation error: ${err.message}`;\r\n const codeFrame = err.loc &&\r\n generateCodeFrame(template, err.loc.start.offset, err.loc.end.offset);\r\n warn(codeFrame ? `${message}\\n${codeFrame}` : message);\r\n }\r\n // The wildcard import results in a huge object with every export\r\n // with keys that cannot be mangled, and can be quite heavy size-wise.\r\n // In the global build we know `Vue` is available globally so we can avoid\r\n // the wildcard object.\r\n const render = (new Function('Vue', code)(runtimeDom));\r\n render._rc = true;\r\n return (compileCache[key] = render);\r\n}\r\nregisterRuntimeCompiler(compileToFunction);\n\nexport { compileToFunction as compile };\n","import { HOOK_PLUGIN_SETTINGS_SET } from './const';\nexport class ApiProxy {\n constructor(plugin, hook) {\n this.target = null;\n this.targetQueue = [];\n this.onQueue = [];\n this.plugin = plugin;\n this.hook = hook;\n const defaultSettings = {};\n if (plugin.settings) {\n for (const id in plugin.settings) {\n const item = plugin.settings[id];\n defaultSettings[id] = item.defaultValue;\n }\n }\n const localSettingsSaveId = `__vue-devtools-plugin-settings__${plugin.id}`;\n let currentSettings = { ...defaultSettings };\n try {\n const raw = localStorage.getItem(localSettingsSaveId);\n const data = JSON.parse(raw);\n Object.assign(currentSettings, data);\n }\n catch (e) {\n // noop\n }\n this.fallbacks = {\n getSettings() {\n return currentSettings;\n },\n setSettings(value) {\n try {\n localStorage.setItem(localSettingsSaveId, JSON.stringify(value));\n }\n catch (e) {\n // noop\n }\n currentSettings = value;\n },\n };\n hook.on(HOOK_PLUGIN_SETTINGS_SET, (pluginId, value) => {\n if (pluginId === this.plugin.id) {\n this.fallbacks.setSettings(value);\n }\n });\n this.proxiedOn = new Proxy({}, {\n get: (_target, prop) => {\n if (this.target) {\n return this.target.on[prop];\n }\n else {\n return (...args) => {\n this.onQueue.push({\n method: prop,\n args,\n });\n };\n }\n },\n });\n this.proxiedTarget = new Proxy({}, {\n get: (_target, prop) => {\n if (this.target) {\n return this.target[prop];\n }\n else if (prop === 'on') {\n return this.proxiedOn;\n }\n else if (Object.keys(this.fallbacks).includes(prop)) {\n return (...args) => {\n this.targetQueue.push({\n method: prop,\n args,\n resolve: () => { },\n });\n return this.fallbacks[prop](...args);\n };\n }\n else {\n return (...args) => {\n return new Promise(resolve => {\n this.targetQueue.push({\n method: prop,\n args,\n resolve,\n });\n });\n };\n }\n },\n });\n }\n async setRealTarget(target) {\n this.target = target;\n for (const item of this.onQueue) {\n this.target.on[item.method](...item.args);\n }\n for (const item of this.targetQueue) {\n item.resolve(await this.target[item.method](...item.args));\n }\n }\n}\n","export function noop() {}\nexport var extend = Object.assign;\nexport var inBrowser = typeof window !== 'undefined'; // eslint-disable-next-line\n\nexport function get(object, path) {\n var keys = path.split('.');\n var result = object;\n keys.forEach(key => {\n var _result$key;\n\n result = (_result$key = result[key]) != null ? _result$key : '';\n });\n return result;\n}\nexport function pick(obj, keys, ignoreUndefined) {\n return keys.reduce((ret, key) => {\n if (!ignoreUndefined || obj[key] !== undefined) {\n ret[key] = obj[key];\n }\n\n return ret;\n }, {});\n}","var uncurryThis = require('../internals/function-uncurry-this');\n\nmodule.exports = uncurryThis([].slice);\n","import { createVNode as _createVNode, mergeProps as _mergeProps } from \"vue\";\nimport { extend, isObject, inBrowser, withInstall } from '../utils';\nimport { mountComponent, usePopupState } from '../utils/mount-component';\nimport VanNotify from './Notify';\nvar timer;\nvar instance;\n\nvar parseOptions = message => isObject(message) ? message : {\n message\n};\n\nfunction initInstance() {\n ({\n instance\n } = mountComponent({\n setup() {\n var {\n state,\n toggle\n } = usePopupState();\n return () => _createVNode(VanNotify, _mergeProps(state, {\n \"onUpdate:show\": toggle\n }), null);\n }\n\n }));\n}\n\nfunction Notify(options) {\n if (!inBrowser) {\n return;\n }\n\n if (!instance) {\n initInstance();\n }\n\n options = extend({}, Notify.currentOptions, parseOptions(options));\n instance.open(options);\n clearTimeout(timer);\n\n if (options.duration > 0) {\n timer = window.setTimeout(Notify.clear, options.duration);\n }\n\n return instance;\n}\n\nvar getDefaultOptions = () => ({\n type: 'danger',\n color: undefined,\n message: '',\n onClose: undefined,\n onClick: undefined,\n onOpened: undefined,\n duration: 3000,\n className: '',\n lockScroll: false,\n background: undefined\n});\n\nNotify.clear = () => {\n if (instance) {\n instance.toggle(false);\n }\n};\n\nNotify.currentOptions = getDefaultOptions();\n\nNotify.setDefaultOptions = options => {\n extend(Notify.currentOptions, options);\n};\n\nNotify.resetDefaultOptions = () => {\n Notify.currentOptions = getDefaultOptions();\n};\n\nNotify.Component = withInstall(VanNotify);\n\nNotify.install = app => {\n app.use(Notify.Component);\n app.config.globalProperties.$notify = Notify;\n};\n\nexport { Notify };","import { createVNode as _createVNode } from \"vue\";\nimport { defineComponent } from 'vue';\nimport { extend, numericProp, unknownProp, makeStringProp, createNamespace } from '../utils';\nimport { Popup } from '../popup';\nimport { popupSharedProps } from '../popup/shared';\nvar [name, bem] = createNamespace('notify');\nvar notifyProps = extend({}, popupSharedProps, {\n type: makeStringProp('danger'),\n color: String,\n message: numericProp,\n className: unknownProp,\n background: String,\n lockScroll: Boolean\n});\nexport default defineComponent({\n name,\n props: notifyProps,\n emits: ['update:show'],\n\n setup(props, _ref) {\n var {\n emit,\n slots\n } = _ref;\n\n var updateShow = show => emit('update:show', show);\n\n return () => _createVNode(Popup, {\n \"show\": props.show,\n \"class\": [bem([props.type]), props.className],\n \"style\": {\n color: props.color,\n background: props.background\n },\n \"overlay\": false,\n \"position\": \"top\",\n \"duration\": 0.2,\n \"lockScroll\": props.lockScroll,\n \"onUpdate:show\": updateShow\n }, {\n default: () => [slots.default ? slots.default() : props.message]\n });\n }\n\n});","import { Notify } from './function-call';\nexport default Notify;\nexport { Notify };","var global = require('../internals/global');\nvar TO_STRING_TAG_SUPPORT = require('../internals/to-string-tag-support');\nvar isCallable = require('../internals/is-callable');\nvar classofRaw = require('../internals/classof-raw');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\n\nvar TO_STRING_TAG = wellKnownSymbol('toStringTag');\nvar Object = global.Object;\n\n// ES3 wrong here\nvar CORRECT_ARGUMENTS = classofRaw(function () { return arguments; }()) == 'Arguments';\n\n// fallback for IE11 Script Access Denied error\nvar tryGet = function (it, key) {\n try {\n return it[key];\n } catch (error) { /* empty */ }\n};\n\n// getting tag from ES6+ `Object.prototype.toString`\nmodule.exports = TO_STRING_TAG_SUPPORT ? classofRaw : function (it) {\n var O, tag, result;\n return it === undefined ? 'Undefined' : it === null ? 'Null'\n // @@toStringTag case\n : typeof (tag = tryGet(O = Object(it), TO_STRING_TAG)) == 'string' ? tag\n // builtinTag case\n : CORRECT_ARGUMENTS ? classofRaw(O)\n // ES3 arguments fallback\n : (result = classofRaw(O)) == 'Object' && isCallable(O.callee) ? 'Arguments' : result;\n};\n","/**\n * prop type helpers\n * help us to write less code and reduce bundle size\n */\nexport var unknownProp = null;\nexport var numericProp = [Number, String];\nexport var truthProp = {\n type: Boolean,\n default: true\n};\nexport var makeRequiredProp = type => ({\n type,\n required: true\n});\nexport var makeArrayProp = () => ({\n type: Array,\n default: () => []\n});\nexport var makeNumberProp = defaultVal => ({\n type: Number,\n default: defaultVal\n});\nexport var makeNumericProp = defaultVal => ({\n type: numericProp,\n default: defaultVal\n});\nexport var makeStringProp = defaultVal => ({\n type: String,\n default: defaultVal\n});","var shared = require('../internals/shared');\nvar uid = require('../internals/uid');\n\nvar keys = shared('keys');\n\nmodule.exports = function (key) {\n return keys[key] || (keys[key] = uid(key));\n};\n","import { truthProp, unknownProp, numericProp } from '../utils';\nexport var popupSharedProps = {\n // whether to show popup\n show: Boolean,\n // z-index\n zIndex: numericProp,\n // whether to show overlay\n overlay: truthProp,\n // transition duration\n duration: numericProp,\n // teleport\n teleport: [String, Object],\n // prevent body scroll\n lockScroll: truthProp,\n // whether to lazy render\n lazyRender: truthProp,\n // callback function before close\n beforeClose: Function,\n // overlay custom style\n overlayStyle: Object,\n // overlay custom class name\n overlayClass: unknownProp,\n // Initial rendering animation\n transitionAppear: Boolean,\n // whether to close popup when overlay is clicked\n closeOnClickOverlay: truthProp\n};\nexport var popupSharedPropKeys = Object.keys(popupSharedProps);","'use strict';\nvar $ = require('../internals/export');\nvar global = require('../internals/global');\nvar isArray = require('../internals/is-array');\nvar isConstructor = require('../internals/is-constructor');\nvar isObject = require('../internals/is-object');\nvar toAbsoluteIndex = require('../internals/to-absolute-index');\nvar lengthOfArrayLike = require('../internals/length-of-array-like');\nvar toIndexedObject = require('../internals/to-indexed-object');\nvar createProperty = require('../internals/create-property');\nvar wellKnownSymbol = require('../internals/well-known-symbol');\nvar arrayMethodHasSpeciesSupport = require('../internals/array-method-has-species-support');\nvar un$Slice = require('../internals/array-slice');\n\nvar HAS_SPECIES_SUPPORT = arrayMethodHasSpeciesSupport('slice');\n\nvar SPECIES = wellKnownSymbol('species');\nvar Array = global.Array;\nvar max = Math.max;\n\n// `Array.prototype.slice` method\n// https://tc39.es/ecma262/#sec-array.prototype.slice\n// fallback for not array-like ES3 strings and DOM objects\n$({ target: 'Array', proto: true, forced: !HAS_SPECIES_SUPPORT }, {\n slice: function slice(start, end) {\n var O = toIndexedObject(this);\n var length = lengthOfArrayLike(O);\n var k = toAbsoluteIndex(start, length);\n var fin = toAbsoluteIndex(end === undefined ? length : end, length);\n // inline `ArraySpeciesCreate` for usage native `Array#slice` where it's possible\n var Constructor, result, n;\n if (isArray(O)) {\n Constructor = O.constructor;\n // cross-realm fallback\n if (isConstructor(Constructor) && (Constructor === Array || isArray(Constructor.prototype))) {\n Constructor = undefined;\n } else if (isObject(Constructor)) {\n Constructor = Constructor[SPECIES];\n if (Constructor === null) Constructor = undefined;\n }\n if (Constructor === Array || Constructor === undefined) {\n return un$Slice(O, k, fin);\n }\n }\n result = new (Constructor === undefined ? Array : Constructor)(max(fin - k, 0));\n for (n = 0; k < fin; k++, n++) if (k in O) createProperty(result, n, O[k]);\n result.length = n;\n return result;\n }\n});\n","// toObject with fallback for non-array-like ES3 strings\nvar IndexedObject = require('../internals/indexed-object');\nvar requireObjectCoercible = require('../internals/require-object-coercible');\n\nmodule.exports = function (it) {\n return IndexedObject(requireObjectCoercible(it));\n};\n","var fails = require('../internals/fails');\nvar global = require('../internals/global');\n\n// babel-minify and Closure Compiler transpiles RegExp('.', 's') -> /./s and it causes SyntaxError\nvar $RegExp = global.RegExp;\n\nmodule.exports = fails(function () {\n var re = $RegExp('.', 's');\n return !(re.dotAll && re.exec('\\n') && re.flags === 's');\n});\n","// iterable DOM collections\n// flag - `iterable` interface - 'entries', 'keys', 'values', 'forEach' methods\nmodule.exports = {\n CSSRuleList: 0,\n CSSStyleDeclaration: 0,\n CSSValueList: 0,\n ClientRectList: 0,\n DOMRectList: 0,\n DOMStringList: 0,\n DOMTokenList: 1,\n DataTransferItemList: 0,\n FileList: 0,\n HTMLAllCollection: 0,\n HTMLCollection: 0,\n HTMLFormElement: 0,\n HTMLSelectElement: 0,\n MediaList: 0,\n MimeTypeArray: 0,\n NamedNodeMap: 0,\n NodeList: 1,\n PaintRequestList: 0,\n Plugin: 0,\n PluginArray: 0,\n SVGLengthList: 0,\n SVGNumberList: 0,\n SVGPathSegList: 0,\n SVGPointList: 0,\n SVGStringList: 0,\n SVGTransformList: 0,\n SourceBufferList: 0,\n StyleSheetList: 0,\n TextTrackCueList: 0,\n TextTrackList: 0,\n TouchList: 0\n};\n","/* eslint-disable es/no-symbol -- required for testing */\nvar NATIVE_SYMBOL = require('../internals/native-symbol');\n\nmodule.exports = NATIVE_SYMBOL\n && !Symbol.sham\n && typeof Symbol.iterator == 'symbol';\n","import { isDef, isObject } from './validate';\nvar {\n hasOwnProperty\n} = Object.prototype;\n\nfunction assignKey(to, from, key) {\n var val = from[key];\n\n if (!isDef(val)) {\n return;\n }\n\n if (!hasOwnProperty.call(to, key) || !isObject(val)) {\n to[key] = val;\n } else {\n // eslint-disable-next-line no-use-before-define\n to[key] = deepAssign(Object(to[key]), val);\n }\n}\n\nexport function deepAssign(to, from) {\n Object.keys(from).forEach(key => {\n assignKey(to, from, key);\n });\n return to;\n}","export default {\n name: '姓名',\n tel: '电话',\n save: '保存',\n confirm: '确认',\n cancel: '取消',\n delete: '删除',\n loading: '加载中...',\n noCoupon: '暂无优惠券',\n nameEmpty: '请填写姓名',\n telInvalid: '请填写正确的电话',\n vanCalendar: {\n end: '结束',\n start: '开始',\n title: '日期选择',\n confirm: '确定',\n startEnd: '开始/结束',\n weekdays: ['日', '一', '二', '三', '四', '五', '六'],\n monthTitle: (year, month) => year + \"\\u5E74\" + month + \"\\u6708\",\n rangePrompt: maxRange => \"\\u6700\\u591A\\u9009\\u62E9 \" + maxRange + \" \\u5929\"\n },\n vanCascader: {\n select: '请选择'\n },\n vanContactCard: {\n addText: '添加联系人'\n },\n vanContactList: {\n addText: '新建联系人'\n },\n vanPagination: {\n prev: '上一页',\n next: '下一页'\n },\n vanPullRefresh: {\n pulling: '下拉即可刷新...',\n loosing: '释放即可刷新...'\n },\n vanSubmitBar: {\n label: '合计:'\n },\n vanCoupon: {\n unlimited: '无使用门槛',\n discount: discount => discount + \"\\u6298\",\n condition: condition => \"\\u6EE1\" + condition + \"\\u5143\\u53EF\\u7528\"\n },\n vanCouponCell: {\n title: '优惠券',\n count: count => count + \"\\u5F20\\u53EF\\u7528\"\n },\n vanCouponList: {\n exchange: '兑换',\n close: '不使用优惠券',\n enable: '可用',\n disabled: '不可用',\n placeholder: '请输入优惠码'\n },\n vanAddressEdit: {\n area: '地区',\n postal: '邮政编码',\n areaEmpty: '请选择地区',\n addressEmpty: '请填写详细地址',\n postalEmpty: '邮政编码不正确',\n defaultAddress: '设为默认收货地址'\n },\n vanAddressEditDetail: {\n label: '详细地址',\n placeholder: '街道门牌信息'\n },\n vanAddressList: {\n add: '新增地址'\n }\n};","import { ref, reactive } from 'vue';\nimport { deepAssign } from '../utils/deep-assign';\nimport defaultMessages from './lang/zh-CN';\nvar lang = ref('zh-CN');\nvar messages = reactive({\n 'zh-CN': defaultMessages\n});\nexport var Locale = {\n messages() {\n return messages[lang.value];\n },\n\n use(newLang, newMessages) {\n lang.value = newLang;\n this.add({\n [newLang]: newMessages\n });\n },\n\n add(newMessages) {\n if (newMessages === void 0) {\n newMessages = {};\n }\n\n deepAssign(messages, newMessages);\n }\n\n};\nexport default Locale;","import { get } from './basic';\nimport { camelize } from './format';\nimport { isFunction } from './validate';\nimport locale from '../locale';\nexport function createTranslate(name) {\n var prefix = camelize(name) + '.';\n return function (path) {\n var messages = locale.messages();\n var message = get(messages, prefix + path) || get(messages, path);\n\n for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) {\n args[_key - 1] = arguments[_key];\n }\n\n return isFunction(message) ? message(...args) : message;\n };\n}\n\nfunction genBem(name, mods) {\n if (!mods) {\n return '';\n }\n\n if (typeof mods === 'string') {\n return \" \" + name + \"--\" + mods;\n }\n\n if (Array.isArray(mods)) {\n return mods.reduce((ret, item) => ret + genBem(name, item), '');\n }\n\n return Object.keys(mods).reduce((ret, key) => ret + (mods[key] ? genBem(name, key) : ''), '');\n}\n/**\n * bem helper\n * b() // 'button'\n * b('text') // 'button__text'\n * b({ disabled }) // 'button button--disabled'\n * b('text', { disabled }) // 'button__text button__text--disabled'\n * b(['disabled', 'primary']) // 'button button--disabled button--primary'\n */\n\n\nexport function createBEM(name) {\n return (el, mods) => {\n if (el && typeof el !== 'string') {\n mods = el;\n el = '';\n }\n\n el = el ? name + \"__\" + el : name;\n return \"\" + el + genBem(el, mods);\n };\n}\nexport function createNamespace(name) {\n var prefixedName = \"van-\" + name;\n return [prefixedName, createBEM(prefixedName), createTranslate(prefixedName)];\n}","var global = require('../internals/global');\n\nmodule.exports = global.Promise;\n"],"sourceRoot":""}