├── .editorconfig ├── .eslintrc.js ├── .gitattributes ├── .github └── workflows │ └── publish.yml ├── .gitignore ├── .vscode ├── extensions.json └── settings.json ├── LICENSE.md ├── README.md ├── demo ├── index.html ├── index.js └── style.css ├── dev ├── index.html ├── index.ts └── style.css ├── package-lock.json ├── package.json ├── src ├── binding.ts ├── index.ts └── time.ts ├── tsconfig.eslint.json ├── tsconfig.json └── webpack ├── demo.config.js ├── dev.config.js └── prod.config.js /.editorconfig: -------------------------------------------------------------------------------- 1 | [*.{js,jsx,ts,tsx,vue}] 2 | indent_style = space 3 | indent_size = 2 4 | trim_trailing_whitespace = true 5 | insert_final_newline = true 6 | -------------------------------------------------------------------------------- /.eslintrc.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | extends: 'standard-with-typescript', 3 | parserOptions: { 4 | ecmaVersion: 2020, 5 | project: './tsconfig.eslint.json' 6 | }, 7 | ignorePatterns: [ 8 | 'dist/**/*', 9 | 'demo/**/*' 10 | ], 11 | rules: { 12 | 'no-void': 'off', 13 | 'object-curly-spacing': ['error', 'always'], 14 | '@typescript-eslint/no-namespace': 'off', 15 | '@typescript-eslint/explicit-function-return-type': 'off', 16 | '@typescript-eslint/explicit-module-boundary-types': 'off', 17 | '@typescript-eslint/no-dynamic-delete': 'off' 18 | } 19 | } 20 | -------------------------------------------------------------------------------- /.gitattributes: -------------------------------------------------------------------------------- 1 | # Auto detect text files and perform LF normalization 2 | * text=auto -------------------------------------------------------------------------------- /.github/workflows/publish.yml: -------------------------------------------------------------------------------- 1 | on: 2 | push: 3 | branches: 4 | - main 5 | 6 | name: Publish 7 | 8 | jobs: 9 | publish: 10 | name: Build and Publish 11 | runs-on: ubuntu-latest 12 | steps: 13 | - name: Checkout the repository 14 | uses: actions/checkout@v3 15 | 16 | - name: Use Node.js v19 17 | uses: actions/setup-node@v3 18 | with: 19 | node-version: 19 20 | cache: 'npm' 21 | 22 | - name: Check if version has been updated 23 | id: check 24 | uses: EndBug/version-check@v1.2.0 25 | with: 26 | diff-search: true 27 | 28 | - name: Log when changed 29 | if: steps.check.outputs.changed == 'true' 30 | run: 'echo "Version change found! New version: ${{ steps.check.outputs.version }} (${{ steps.check.outputs.type }})"' 31 | 32 | - name: Install Dependencies 33 | if: steps.check.outputs.changed == 'true' 34 | run: npm ci 35 | 36 | - name: Build 37 | if: steps.check.outputs.changed == 'true' 38 | run: npm run build 39 | 40 | - name: Publish to NPM 41 | if: steps.check.outputs.changed == 'true' 42 | run: npm publish --provenance --access public 43 | env: 44 | NPM_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }} 45 | 46 | - name: Build Demo 47 | if: steps.check.outputs.changed == 'true' 48 | run: npm run demo 49 | 50 | - name: Push Demo 51 | if: steps.check.outputs.changed == 'true' 52 | uses: JamesIves/github-pages-deploy-action@v4 53 | with: 54 | BRANCH: demo 55 | FOLDER: demo 56 | CLEAN: true 57 | COMMIT_MESSAGE: v${{ steps.check.outputs.version }} 58 | 59 | - name: Create Release 60 | if: steps.check.outputs.changed == 'true' 61 | uses: actions/create-release@v1 62 | env: 63 | GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} 64 | with: 65 | tag_name: v${{ steps.check.outputs.version }} 66 | release_name: Release v${{ steps.check.outputs.version }} 67 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # Folder view configuration files 2 | .DS_Store 3 | Desktop.ini 4 | 5 | # Thumbnail cache files 6 | ._* 7 | Thumbs.db 8 | 9 | # Temp files 10 | ~* 11 | 12 | # Files that might appear on external disks 13 | .Spotlight-V100 14 | .Trashes 15 | 16 | # npm logs and deps 17 | node_modules/ 18 | npm-debug.log 19 | npm-debug.log.* 20 | 21 | # Ignore the dist directory 22 | dist/* 23 | 24 | # Keep gitkeep files 25 | !.gitkeep -------------------------------------------------------------------------------- /.vscode/extensions.json: -------------------------------------------------------------------------------- 1 | { 2 | "recommendations": [ 3 | "coenraads.bracket-pair-colorizer-2", 4 | "streetsidesoftware.code-spell-checker", 5 | "eamodio.gitlens", 6 | "eg2.vscode-npm-script", 7 | "dbaeumer.vscode-eslint", 8 | "pflannery.vscode-versionlens" 9 | ] 10 | } -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | // Place your settings in this file to overwrite default and user settings. 2 | { 3 | "editor.tabSize": 2, 4 | "editor.insertSpaces": true, 5 | "editor.detectIndentation": false, 6 | "editor.formatOnType": true, 7 | "editor.formatOnPaste": false, 8 | "editor.formatOnSave": true, 9 | "editor.codeActionsOnSave": { 10 | "source.fixAll": "explicit" 11 | }, 12 | "search.exclude": { 13 | "**/dist": true, 14 | "**/node_modules": true 15 | }, 16 | "typescript.format.enable": false, 17 | "typescript.validate.enable": true, 18 | "typescript.format.insertSpaceAfterConstructor": true, 19 | "typescript.format.insertSpaceBeforeFunctionParenthesis": true, 20 | "eslint.format.enable": true, 21 | "cSpell.words": [ 22 | "disableable" 23 | ] 24 | } -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | The MIT License (MIT) 2 | 3 | Copyright (c) 2021 Zachary Cardoza 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: 6 | 7 | The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. 8 | 9 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. 10 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Vue Click 2 | ![Publish](https://github.com/nerdoza/vue-click/workflows/Publish/badge.svg) 3 | 4 | Vue 3 plugin for advanced click directive. 5 | 6 | ### [🖱️ Demo Page](https://nerdoza.github.io/vue-click/) 7 | 8 | # Installation 9 | 10 | ## Npm 11 | 12 | ```bash 13 | npm install --save vue-click 14 | ``` 15 | 16 | Install the plugin into Vue: 17 | 18 | ```javascript 19 | import { createApp } from 'vue' 20 | import VueClick from 'vue-click' 21 | 22 | const app = createApp({/* App Config */}) 23 | app.use(VueClick) 24 | app.mount('#app') 25 | ``` 26 | 27 | ## CDN 28 | 29 | This package is available from the [**JSDELIVR**](https://www.jsdelivr.com/) and [**UNPKG**](https://unpkg.com/) content delivery networks (CDNs) and utilizes the [**UMD**](https://github.com/umdjs/umd#readme) module system so it's ready to use directly in the browser without a build step. 30 | 31 | ```html 32 | 33 | 34 | 39 | 40 | ``` 41 | 42 | # Usage 43 | 44 | ## Directive 45 | 46 | Use the `v-click` directive very similarly to how you would use `v-on:click`: 47 | 48 | ```html 49 |

20 | 21 |
22 |

Native Click

23 |
24 |
25 |

Click

26 |
27 |
28 |

Double Click

31 |
32 |
33 |

Hold

35 |
36 |
37 |

Press

39 |
40 |
41 |

Release

43 |
44 |
45 |

Once

48 |
49 |
50 |

Throttle

53 |
54 |
55 |

Debounce

58 |
59 |
60 |

Arguments

63 |
64 |
65 |

Supported Combos

66 |
67 |
68 |

⚠ Unsupported Combos

69 | 71 |
72 | 73 | 74 | 75 | -------------------------------------------------------------------------------- /demo/index.js: -------------------------------------------------------------------------------- 1 | (()=>{"use strict";var e={d:(t,n)=>{for(var o in n)e.o(n,o)&&!e.o(t,o)&&Object.defineProperty(t,o,{enumerable:!0,get:n[o]})}};e.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),e.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),e.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var t={};function n(e,t){const n=Object.create(null),o=e.split(",");for(let e=0;e!!n[e.toLowerCase()]:e=>!!n[e]}e.r(t),e.d(t,{BaseTransition:()=>oo,Comment:()=>sr,Fragment:()=>or,KeepAlive:()=>po,Static:()=>ir,Suspense:()=>gn,Teleport:()=>Jo,Text:()=>rr,Transition:()=>Hs,TransitionGroup:()=>si,callWithAsyncErrorHandling:()=>Nt,callWithErrorHandling:()=>Ot,camelize:()=>z,capitalize:()=>G,cloneVNode:()=>Sr,computed:()=>cs,createApp:()=>Ii,createBlock:()=>hr,createCommentVNode:()=>Er,createHydrationRenderer:()=>Do,createRenderer:()=>Uo,createSSRApp:()=>Mi,createSlots:()=>ys,createStaticVNode:()=>wr,createTextVNode:()=>Cr,createVNode:()=>xr,customRef:()=>_t,defineAsyncComponent:()=>Ao,defineComponent:()=>Fo,defineEmit:()=>us,defineProps:()=>as,devtools:()=>Yt,getCurrentInstance:()=>qr,getTransitionRawChildren:()=>ao,h:()=>ds,handleError:()=>$t,hydrate:()=>Ai,initCustomFormatter:()=>ms,inject:()=>Lr,isProxy:()=>st,isReactive:()=>ot,isReadonly:()=>rt,isRef:()=>at,isRuntimeOnly:()=>es,isVNode:()=>mr,markRaw:()=>lt,mergeProps:()=>Nr,nextTick:()=>zt,onActivated:()=>ho,onBeforeMount:()=>Un,onBeforeUnmount:()=>zn,onBeforeUpdate:()=>jn,onDeactivated:()=>mo,onErrorCaptured:()=>qn,onMounted:()=>Dn,onRenderTracked:()=>Gn,onRenderTriggered:()=>Wn,onUnmounted:()=>Kn,onUpdated:()=>Hn,openBlock:()=>ar,popScopeId:()=>Nn,provide:()=>$r,proxyRefs:()=>vt,pushScopeId:()=>On,queuePostFlushCb:()=>qt,reactive:()=>Xe,readonly:()=>et,ref:()=>ut,registerRuntimeCompiler:()=>ts,render:()=>Fi,renderList:()=>gs,renderSlot:()=>Cn,resolveComponent:()=>Qo,resolveDirective:()=>er,resolveDynamicComponent:()=>Yo,resolveTransitionHooks:()=>so,setBlockTracking:()=>fr,setDevtoolsHook:()=>en,setTransitionHooks:()=>co,shallowReactive:()=>Ye,shallowReadonly:()=>tt,shallowRef:()=>pt,ssrContextKey:()=>fs,ssrUtils:()=>bs,toDisplayString:()=>m,toHandlerKey:()=>q,toHandlers:()=>vs,toRaw:()=>it,toRef:()=>St,toRefs:()=>bt,transformVNodeArgs:()=>vr,triggerRef:()=>ht,unref:()=>mt,useContext:()=>ps,useCssModule:()=>Rs,useCssVars:()=>Bs,useSSRContext:()=>hs,useTransitionState:()=>to,vModelCheckbox:()=>fi,vModelDynamic:()=>bi,vModelRadio:()=>mi,vModelSelect:()=>gi,vModelText:()=>di,vShow:()=>ki,version:()=>_s,warn:()=>Et,watch:()=>Qn,watchEffect:()=>Jn,withCtx:()=>En,withDirectives:()=>Eo,withKeys:()=>Ti,withModifiers:()=>wi,withScopeId:()=>$n});const o=n("Infinity,undefined,NaN,isFinite,isNaN,parseFloat,parseInt,decodeURI,decodeURIComponent,encodeURI,encodeURIComponent,Math,Number,Date,Array,Object,Boolean,String,RegExp,Map,Set,JSON,Intl,BigInt"),r=n("itemscope,allowfullscreen,formnovalidate,ismap,nomodule,novalidate,readonly");function s(e){if(O(e)){const t={};for(let n=0;n{if(e){const n=e.split(l);n.length>1&&(t[n[0].trim()]=n[1].trim())}})),t}function a(e){let t="";if(V(e))t=e;else if(O(e))for(let n=0;nf(e,t)))}const m=e=>null==e?"":A(e)?JSON.stringify(e,g,2):String(e),g=(e,t)=>N(t)?{[`Map(${t.size})`]:[...t.entries()].reduce(((e,[t,n])=>(e[`${t} =>`]=n,e)),{})}:$(t)?{[`Set(${t.size})`]:[...t.values()]}:!A(t)||O(t)||B(t)?t:String(t),v={},y=[],_=()=>{},b=()=>!1,x=/^on[^a-z]/,S=e=>x.test(e),C=e=>e.startsWith("onUpdate:"),w=Object.assign,E=(e,t)=>{const n=e.indexOf(t);n>-1&&e.splice(n,1)},T=Object.prototype.hasOwnProperty,k=(e,t)=>T.call(e,t),O=Array.isArray,N=e=>"[object Map]"===R(e),$=e=>"[object Set]"===R(e),L=e=>e instanceof Date,P=e=>"function"==typeof e,V=e=>"string"==typeof e,F=e=>"symbol"==typeof e,A=e=>null!==e&&"object"==typeof e,I=e=>A(e)&&P(e.then)&&P(e.catch),M=Object.prototype.toString,R=e=>M.call(e),B=e=>"[object Object]"===R(e),U=e=>V(e)&&"NaN"!==e&&"-"!==e[0]&&""+parseInt(e,10)===e,D=n(",key,ref,onVnodeBeforeMount,onVnodeMounted,onVnodeBeforeUpdate,onVnodeUpdated,onVnodeBeforeUnmount,onVnodeUnmounted"),j=e=>{const t=Object.create(null);return n=>t[n]||(t[n]=e(n))},H=/-(\w)/g,z=j((e=>e.replace(H,((e,t)=>t?t.toUpperCase():"")))),K=/\B([A-Z])/g,W=j((e=>e.replace(K,"-$1").toLowerCase())),G=j((e=>e.charAt(0).toUpperCase()+e.slice(1))),q=j((e=>e?`on${G(e)}`:"")),J=(e,t)=>e!==t&&(e==e||t==t),Z=(e,t)=>{for(let n=0;n{Object.defineProperty(e,t,{configurable:!0,enumerable:!1,value:n})},X=e=>{const t=parseFloat(e);return isNaN(t)?e:t};let Y;const ee=()=>Y||(Y="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:void 0!==e.g?e.g:{}),te=new WeakMap,ne=[];let oe;const re=Symbol(""),se=Symbol("");function ie(e,t=v){(function(e){return e&&!0===e._isEffect})(e)&&(e=e.raw);const n=function(e,t){const n=function(){if(!n.active)return t.scheduler?void 0:e();if(!ne.includes(n)){ae(n);try{return pe.push(ue),ue=!0,ne.push(n),oe=n,e()}finally{ne.pop(),fe(),oe=ne[ne.length-1]}}};return n.id=ce++,n.allowRecurse=!!t.allowRecurse,n._isEffect=!0,n.active=!0,n.raw=e,n.deps=[],n.options=t,n}(e,t);return t.lazy||n(),n}function le(e){e.active&&(ae(e),e.options.onStop&&e.options.onStop(),e.active=!1)}let ce=0;function ae(e){const{deps:t}=e;if(t.length){for(let n=0;n{e&&e.forEach((e=>{(e!==oe||e.allowRecurse)&&l.add(e)}))};if("clear"===t)i.forEach(c);else if("length"===n&&O(e))i.forEach(((e,t)=>{("length"===t||t>=o)&&c(e)}));else switch(void 0!==n&&c(i.get(n)),t){case"add":O(e)?U(n)&&c(i.get("length")):(c(i.get(re)),N(e)&&c(i.get(se)));break;case"delete":O(e)||(c(i.get(re)),N(e)&&c(i.get(se)));break;case"set":N(e)&&c(i.get(re))}l.forEach((e=>{e.options.scheduler?e.options.scheduler(e):e()}))}const ge=n("__proto__,__v_isRef,__isVue"),ve=new Set(Object.getOwnPropertyNames(Symbol).map((e=>Symbol[e])).filter(F)),ye=Ce(),_e=Ce(!1,!0),be=Ce(!0),xe=Ce(!0,!0),Se={};function Ce(e=!1,t=!1){return function(n,o,r){if("__v_isReactive"===o)return!e;if("__v_isReadonly"===o)return e;if("__v_raw"===o&&r===(e?Qe:Ze).get(n))return n;const s=O(n);if(!e&&s&&k(Se,o))return Reflect.get(Se,o,r);const i=Reflect.get(n,o,r);return(F(o)?ve.has(o):ge(o))?i:(e||he(n,0,o),t?i:at(i)?s&&U(o)?i:i.value:A(i)?e?et(i):Xe(i):i)}}function we(e=!1){return function(t,n,o,r){const s=t[n];if(!e&&(o=it(o),!O(t)&&at(s)&&!at(o)))return s.value=o,!0;const i=O(t)&&U(n)?Number(n){const t=Array.prototype[e];Se[e]=function(...e){const n=it(this);for(let e=0,t=this.length;e{const t=Array.prototype[e];Se[e]=function(...e){de();const n=t.apply(this,e);return fe(),n}}));const Ee={get:ye,set:we(),deleteProperty:function(e,t){const n=k(e,t),o=(e[t],Reflect.deleteProperty(e,t));return o&&n&&me(e,"delete",t,void 0),o},has:function(e,t){const n=Reflect.has(e,t);return F(t)&&ve.has(t)||he(e,0,t),n},ownKeys:function(e){return he(e,0,O(e)?"length":re),Reflect.ownKeys(e)}},Te={get:be,set:(e,t)=>!0,deleteProperty:(e,t)=>!0},ke=w({},Ee,{get:_e,set:we(!0)}),Oe=w({},Te,{get:xe}),Ne=e=>A(e)?Xe(e):e,$e=e=>A(e)?et(e):e,Le=e=>e,Pe=e=>Reflect.getPrototypeOf(e);function Ve(e,t,n=!1,o=!1){const r=it(e=e.__v_raw),s=it(t);t!==s&&!n&&he(r,0,t),!n&&he(r,0,s);const{has:i}=Pe(r),l=n?$e:o?Le:Ne;return i.call(r,t)?l(e.get(t)):i.call(r,s)?l(e.get(s)):void 0}function Fe(e,t=!1){const n=this.__v_raw,o=it(n),r=it(e);return e!==r&&!t&&he(o,0,e),!t&&he(o,0,r),e===r?n.has(e):n.has(e)||n.has(r)}function Ae(e,t=!1){return e=e.__v_raw,!t&&he(it(e),0,re),Reflect.get(e,"size",e)}function Ie(e){e=it(e);const t=it(this);return Pe(t).has.call(t,e)||(t.add(e),me(t,"add",e,e)),this}function Me(e,t){t=it(t);const n=it(this),{has:o,get:r}=Pe(n);let s=o.call(n,e);s||(e=it(e),s=o.call(n,e));const i=r.call(n,e);return n.set(e,t),s?J(t,i)&&me(n,"set",e,t):me(n,"add",e,t),this}function Re(e){const t=it(this),{has:n,get:o}=Pe(t);let r=n.call(t,e);r||(e=it(e),r=n.call(t,e)),o&&o.call(t,e);const s=t.delete(e);return r&&me(t,"delete",e,void 0),s}function Be(){const e=it(this),t=0!==e.size,n=e.clear();return t&&me(e,"clear",void 0,void 0),n}function Ue(e,t){return function(n,o){const r=this,s=r.__v_raw,i=it(s),l=e?$e:t?Le:Ne;return!e&&he(i,0,re),s.forEach(((e,t)=>n.call(o,l(e),l(t),r)))}}function De(e,t,n){return function(...o){const r=this.__v_raw,s=it(r),i=N(s),l="entries"===e||e===Symbol.iterator&&i,c="keys"===e&&i,a=r[e](...o),u=t?$e:n?Le:Ne;return!t&&he(s,0,c?se:re),{next(){const{value:e,done:t}=a.next();return t?{value:e,done:t}:{value:l?[u(e[0]),u(e[1])]:u(e),done:t}},[Symbol.iterator](){return this}}}}function je(e){return function(...t){return"delete"!==e&&this}}const He={get(e){return Ve(this,e)},get size(){return Ae(this)},has:Fe,add:Ie,set:Me,delete:Re,clear:Be,forEach:Ue(!1,!1)},ze={get(e){return Ve(this,e,!1,!0)},get size(){return Ae(this)},has:Fe,add:Ie,set:Me,delete:Re,clear:Be,forEach:Ue(!1,!0)},Ke={get(e){return Ve(this,e,!0)},get size(){return Ae(this,!0)},has(e){return Fe.call(this,e,!0)},add:je("add"),set:je("set"),delete:je("delete"),clear:je("clear"),forEach:Ue(!0,!1)};function We(e,t){const n=t?ze:e?Ke:He;return(t,o,r)=>"__v_isReactive"===o?!e:"__v_isReadonly"===o?e:"__v_raw"===o?t:Reflect.get(k(n,o)&&o in t?n:t,o,r)}["keys","values","entries",Symbol.iterator].forEach((e=>{He[e]=De(e,!1,!1),Ke[e]=De(e,!0,!1),ze[e]=De(e,!1,!0)}));const Ge={get:We(!1,!1)},qe={get:We(!1,!0)},Je={get:We(!0,!1)},Ze=new WeakMap,Qe=new WeakMap;function Xe(e){return e&&e.__v_isReadonly?e:nt(e,!1,Ee,Ge)}function Ye(e){return nt(e,!1,ke,qe)}function et(e){return nt(e,!0,Te,Je)}function tt(e){return nt(e,!0,Oe,Je)}function nt(e,t,n,o){if(!A(e))return e;if(e.__v_raw&&(!t||!e.__v_isReactive))return e;const r=t?Qe:Ze,s=r.get(e);if(s)return s;const i=(l=e).__v_skip||!Object.isExtensible(l)?0:function(e){switch(e){case"Object":case"Array":return 1;case"Map":case"Set":case"WeakMap":case"WeakSet":return 2;default:return 0}}((e=>R(e).slice(8,-1))(l));var l;if(0===i)return e;const c=new Proxy(e,2===i?o:n);return r.set(e,c),c}function ot(e){return rt(e)?ot(e.__v_raw):!(!e||!e.__v_isReactive)}function rt(e){return!(!e||!e.__v_isReadonly)}function st(e){return ot(e)||rt(e)}function it(e){return e&&it(e.__v_raw)||e}function lt(e){return Q(e,"__v_skip",!0),e}const ct=e=>A(e)?Xe(e):e;function at(e){return Boolean(e&&!0===e.__v_isRef)}function ut(e){return ft(e)}function pt(e){return ft(e,!0)}class dt{constructor(e,t=!1){this._rawValue=e,this._shallow=t,this.__v_isRef=!0,this._value=t?e:ct(e)}get value(){return he(it(this),0,"value"),this._value}set value(e){J(it(e),this._rawValue)&&(this._rawValue=e,this._value=this._shallow?e:ct(e),me(it(this),"set","value",e))}}function ft(e,t=!1){return at(e)?e:new dt(e,t)}function ht(e){me(it(e),"set","value",void 0)}function mt(e){return at(e)?e.value:e}const gt={get:(e,t,n)=>mt(Reflect.get(e,t,n)),set:(e,t,n,o)=>{const r=e[t];return at(r)&&!at(n)?(r.value=n,!0):Reflect.set(e,t,n,o)}};function vt(e){return ot(e)?e:new Proxy(e,gt)}class yt{constructor(e){this.__v_isRef=!0;const{get:t,set:n}=e((()=>he(this,0,"value")),(()=>me(this,"set","value")));this._get=t,this._set=n}get value(){return this._get()}set value(e){this._set(e)}}function _t(e){return new yt(e)}function bt(e){const t=O(e)?new Array(e.length):{};for(const n in e)t[n]=St(e,n);return t}class xt{constructor(e,t){this._object=e,this._key=t,this.__v_isRef=!0}get value(){return this._object[this._key]}set value(e){this._object[this._key]=e}}function St(e,t){return at(e[t])?e[t]:new xt(e,t)}class Ct{constructor(e,t,n){this._setter=t,this._dirty=!0,this.__v_isRef=!0,this.effect=ie(e,{lazy:!0,scheduler:()=>{this._dirty||(this._dirty=!0,me(it(this),"set","value"))}}),this.__v_isReadonly=n}get value(){return this._dirty&&(this._value=this.effect(),this._dirty=!1),he(it(this),0,"value"),this._value}set value(e){this._setter(e)}}const wt=[];function Et(e,...t){de();const n=wt.length?wt[wt.length-1].component:null,o=n&&n.appContext.config.warnHandler,r=function(){let e=wt[wt.length-1];if(!e)return[];const t=[];for(;e;){const n=t[0];n&&n.vnode===e?n.recurseCount++:t.push({vnode:e,recurseCount:0});const o=e.component&&e.component.parent;e=o&&o.vnode}return t}();if(o)Ot(o,n,11,[e+t.join(""),n&&n.proxy,r.map((({vnode:e})=>`at <${ls(n,e.type)}>`)).join("\n"),r]);else{const n=[`[Vue warn]: ${e}`,...t];r.length&&n.push("\n",...function(e){const t=[];return e.forEach(((e,n)=>{t.push(...0===n?[]:["\n"],...function({vnode:e,recurseCount:t}){const n=t>0?`... (${t} recursive calls)`:"",o=!!e.component&&null==e.component.parent,r=` at <${ls(e.component,e.type,o)}`,s=">"+n;return e.props?[r,...Tt(e.props),s]:[r+s]}(e))})),t}(r)),console.warn(...n)}fe()}function Tt(e){const t=[],n=Object.keys(e);return n.slice(0,3).forEach((n=>{t.push(...kt(n,e[n]))})),n.length>3&&t.push(" ..."),t}function kt(e,t,n){return V(t)?(t=JSON.stringify(t),n?t:[`${e}=${t}`]):"number"==typeof t||"boolean"==typeof t||null==t?n?t:[`${e}=${t}`]:at(t)?(t=kt(e,it(t.value),!0),n?t:[`${e}=Ref<`,t,">"]):P(t)?[`${e}=fn${t.name?`<${t.name}>`:""}`]:(t=it(t),n?t:[`${e}=`,t])}function Ot(e,t,n,o){let r;try{r=o?e(...o):e()}catch(e){$t(e,t,n)}return r}function Nt(e,t,n,o){if(P(e)){const r=Ot(e,t,n,o);return r&&I(r)&&r.catch((e=>{$t(e,t,n)})),r}const r=[];for(let s=0;s>>1;Qt(Vt[e])-1?Vt.splice(t,0,e):Vt.push(e),Wt()}}function Wt(){Lt||Pt||(Pt=!0,jt=Dt.then(Xt))}function Gt(e,t,n,o){O(e)?n.push(...e):t&&t.includes(e,e.allowRecurse?o+1:o)||n.push(e),Wt()}function qt(e){Gt(e,Bt,Rt,Ut)}function Jt(e,t=null){if(At.length){for(Ht=t,It=[...new Set(At)],At.length=0,Mt=0;MtQt(e)-Qt(t))),Ut=0;Utnull==e.id?1/0:e.id;function Xt(e){Pt=!1,Lt=!0,Jt(e),Vt.sort(((e,t)=>Qt(e)-Qt(t)));try{for(Ft=0;Ft{Yt&&Yt.emit(e,t.appContext.app,t.uid,t.parent?t.parent.uid:void 0,t)}}function sn(e,t,...n){const o=e.vnode.props||v;let r=n;const s=t.startsWith("update:"),i=s&&t.slice(7);if(i&&i in o){const e=`${"modelValue"===i?"model":i}Modifiers`,{number:t,trim:s}=o[e]||v;s?r=n.map((e=>e.trim())):t&&(r=n.map(X))}__VUE_PROD_DEVTOOLS__&&function(e,t,n){Yt&&Yt.emit("component:emit",e.appContext.app,e,t,n)}(e,t,r);let l=q(z(t)),c=o[l];!c&&s&&(l=q(W(t)),c=o[l]),c&&Nt(c,e,6,r);const a=o[l+"Once"];if(a){if(e.emitted){if(e.emitted[l])return}else(e.emitted={})[l]=!0;Nt(a,e,6,r)}}function ln(e,t,n=!1){if(!t.deopt&&void 0!==e.__emits)return e.__emits;const o=e.emits;let r={},s=!1;if(__VUE_OPTIONS_API__&&!P(e)){const o=e=>{s=!0,w(r,ln(e,t,!0))};!n&&t.mixins.length&&t.mixins.forEach(o),e.extends&&o(e.extends),e.mixins&&e.mixins.forEach(o)}return o||s?(O(o)?o.forEach((e=>r[e]=null)):w(r,o),e.__emits=r):e.__emits=null}function cn(e,t){return!(!e||!S(t))&&(t=t.slice(2).replace(/Once$/,""),k(e,t[0].toLowerCase()+t.slice(1))||k(e,W(t))||k(e,t))}let an=null;function un(e){an=e}function pn(e){const{type:t,vnode:n,proxy:o,withProxy:r,props:s,propsOptions:[i],slots:l,attrs:c,emit:a,render:u,renderCache:p,data:d,setupState:f,ctx:h}=e;let m;an=e;try{let e;if(4&n.shapeFlag){const t=r||o;m=Tr(u.call(t,t,p,s,f,d,h)),e=c}else{const n=t;m=Tr(n.length>1?n(s,{attrs:c,slots:l,emit:a}):n(s,null)),e=t.props?c:dn(c)}let g=m;if(!1!==t.inheritAttrs&&e){const t=Object.keys(e),{shapeFlag:n}=g;t.length&&(1&n||6&n)&&(i&&t.some(C)&&(e=fn(e,i)),g=Sr(g,e))}n.dirs&&(g.dirs=g.dirs?g.dirs.concat(n.dirs):n.dirs),n.transition&&(g.transition=n.transition),m=g}catch(t){$t(t,e,1),m=xr(sr)}return an=null,m}const dn=e=>{let t;for(const n in e)("class"===n||"style"===n||S(n))&&((t||(t={}))[n]=e[n]);return t},fn=(e,t)=>{const n={};for(const o in e)C(o)&&o.slice(9)in t||(n[o]=e[o]);return n};function hn(e,t,n){const o=Object.keys(t);if(o.length!==Object.keys(e).length)return!0;for(let r=0;r0?(c(null,e.ssFallback,t,n,o,null,s),bn(p,e.ssFallback)):p.resolve()}(t,n,o,r,s,i,l,c):function(e,t,n,o,r,s,{p:i,um:l,o:{createElement:c}}){const a=t.suspense=e.suspense;a.vnode=t,t.el=e.el;const u=t.ssContent,p=t.ssFallback,{activeBranch:d,pendingBranch:f,isInFallback:h,isHydrating:m}=a;if(f)a.pendingBranch=u,gr(u,f)?(i(f,u,a.hiddenContainer,null,r,a,s),a.deps<=0?a.resolve():h&&(i(d,p,n,o,r,null,s),bn(a,p))):(a.pendingId++,m?(a.isHydrating=!1,a.activeBranch=f):l(f,r,a),a.deps=0,a.effects.length=0,a.hiddenContainer=c("div"),h?(i(null,u,a.hiddenContainer,null,r,a,s),a.deps<=0?a.resolve():(i(d,p,n,o,r,null,s),bn(a,p))):d&&gr(u,d)?(i(d,u,n,o,r,a,s),a.resolve(!0)):(i(null,u,a.hiddenContainer,null,r,a,s),a.deps<=0&&a.resolve()));else if(d&&gr(u,d))i(d,u,n,o,r,a,s),bn(a,u);else{const e=t.props&&t.props.onPending;if(P(e)&&e(),a.pendingBranch=u,a.pendingId++,i(null,u,a.hiddenContainer,null,r,a,s),a.deps<=0)a.resolve();else{const{timeout:e,pendingId:t}=a;e>0?setTimeout((()=>{a.pendingId===t&&a.fallback(p)}),e):0===e&&a.fallback(p)}}}(e,t,n,o,r,i,c)},hydrate:function(e,t,n,o,r,s,i,l){const c=t.suspense=vn(t,o,n,e.parentNode,document.createElement("div"),null,r,s,i,!0),a=l(e,c.pendingBranch=t.ssContent,n,c,s);return 0===c.deps&&c.resolve(),a},create:vn};function vn(e,t,n,o,r,s,i,l,c,a=!1){const{p:u,m:p,um:d,n:f,o:{parentNode:h,remove:m}}=c,g=X(e.props&&e.props.timeout),v={vnode:e,parent:t,parentComponent:n,isSVG:i,container:o,hiddenContainer:r,anchor:s,deps:0,pendingId:0,timeout:"number"==typeof g?g:-1,activeBranch:null,pendingBranch:null,isInFallback:!0,isHydrating:a,isUnmounted:!1,effects:[],resolve(e=!1){const{vnode:t,activeBranch:n,pendingBranch:o,pendingId:r,effects:s,parentComponent:i,container:l}=v;if(v.isHydrating)v.isHydrating=!1;else if(!e){const e=n&&o.transition&&"out-in"===o.transition.mode;e&&(n.transition.afterLeave=()=>{r===v.pendingId&&p(o,l,t,0)});let{anchor:t}=v;n&&(t=f(n),d(n,i,v,!0)),e||p(o,l,t,0)}bn(v,o),v.pendingBranch=null,v.isInFallback=!1;let c=v.parent,a=!1;for(;c;){if(c.pendingBranch){c.effects.push(...s),a=!0;break}c=c.parent}a||qt(s),v.effects=[];const u=t.props&&t.props.onResolve;P(u)&&u()},fallback(e){if(!v.pendingBranch)return;const{vnode:t,activeBranch:n,parentComponent:o,container:r,isSVG:s}=v,i=t.props&&t.props.onFallback;P(i)&&i();const l=f(n),c=()=>{v.isInFallback&&(u(null,e,r,l,o,null,s),bn(v,e))},a=e.transition&&"out-in"===e.transition.mode;a&&(n.transition.afterLeave=c),d(n,o,null,!0),v.isInFallback=!0,a||c()},move(e,t,n){v.activeBranch&&p(v.activeBranch,e,t,n),v.container=e},next:()=>v.activeBranch&&f(v.activeBranch),registerDep(e,t){const n=!!v.pendingBranch;n&&v.deps++;const o=e.vnode.el;e.asyncDep.catch((t=>{$t(t,e,0)})).then((r=>{if(e.isUnmounted||v.isUnmounted||v.pendingId!==e.suspenseId)return;e.asyncResolved=!0;const{vnode:s}=e;Yr(e,r),o&&(s.el=o);const c=!o&&e.subTree.el;t(e,s,h(o||e.subTree.el),o?null:f(e.subTree),v,i,l),c&&m(c),mn(e,s.el),n&&0==--v.deps&&v.resolve()}))},unmount(e,t){v.isUnmounted=!0,v.activeBranch&&d(v.activeBranch,n,e,t),v.pendingBranch&&d(v.pendingBranch,n,e,t)}};return v}function yn(e){return P(e)&&(e=e()),O(e)&&(e=function(e){let t;for(let n=0;nxn+=e;function Cn(e,t,n={},o){let r=e[t];xn++,ar();const s=r&&wn(r(n)),i=hr(or,{key:n.key||`_${t}`},s||(o?o():[]),s&&1===e._?64:-2);return xn--,i}function wn(e){return e.some((e=>!mr(e)||e.type!==sr&&!(e.type===or&&!wn(e.children))))?e:null}function En(e,t=an){if(!t)return e;const n=(...n)=>{xn||ar(!0);const o=an;un(t);const r=e(...n);return un(o),xn||ur(),r};return n._c=!0,n}let Tn=null;const kn=[];function On(e){kn.push(Tn=e)}function Nn(){kn.pop(),Tn=kn[kn.length-1]||null}function $n(e){return t=>En((function(){On(e);const n=t.apply(this,arguments);return Nn(),n}))}function Ln(e,t,n,o){const[r,s]=e.propsOptions;if(t)for(const s in t){const i=t[s];if(D(s))continue;let l;r&&k(r,l=z(s))?n[l]=i:cn(e.emitsOptions,s)||(o[s]=i)}if(s){const t=it(n);for(let o=0;o{i=!0;const[n,o]=Vn(e,t,!0);w(r,n),o&&s.push(...o)};!n&&t.mixins.length&&t.mixins.forEach(o),e.extends&&o(e.extends),e.mixins&&e.mixins.forEach(o)}if(!o&&!i)return e.__props=y;if(O(o))for(let e=0;e-1,i[1]=n<0||e-1||k(i,"default"))&&s.push(t)}}}return e.__props=[r,s]}function Fn(e){return"$"!==e[0]}function An(e){const t=e&&e.toString().match(/^\s*function (\w+)/);return t?t[1]:""}function In(e,t){return An(e)===An(t)}function Mn(e,t){if(O(t)){for(let n=0,o=t.length;n{if(n.isUnmounted)return;de(),Jr(n);const r=Nt(t,n,e,o);return Jr(null),fe(),r});return o?r.unshift(s):r.push(s),s}}const Bn=e=>(t,n=Gr)=>!Xr&&Rn(e,t,n),Un=Bn("bm"),Dn=Bn("m"),jn=Bn("bu"),Hn=Bn("u"),zn=Bn("bum"),Kn=Bn("um"),Wn=Bn("rtg"),Gn=Bn("rtc"),qn=(e,t=Gr)=>{Rn("ec",e,t)};function Jn(e,t){return Xn(e,null,t)}const Zn={};function Qn(e,t,n){return Xn(e,t,n)}function Xn(e,t,{immediate:n,deep:o,flush:r,onTrack:s,onTrigger:i}=v,l=Gr){let c,a,u=!1;if(at(e)?(c=()=>e.value,u=!!e._shallow):ot(e)?(c=()=>e,o=!0):c=O(e)?()=>e.map((e=>at(e)?e.value:ot(e)?eo(e):P(e)?Ot(e,l,2,[l&&l.proxy]):void 0)):P(e)?t?()=>Ot(e,l,2,[l&&l.proxy]):()=>{if(!l||!l.isUnmounted)return a&&a(),Ot(e,l,3,[p])}:_,t&&o){const e=c;c=()=>eo(e())}const p=e=>{a=m.options.onStop=()=>{Ot(e,l,4)}};let d=O(e)?[]:Zn;const f=()=>{if(m.active)if(t){const e=m();(o||u||J(e,d))&&(a&&a(),Nt(t,l,3,[e,d===Zn?void 0:d,p]),d=e)}else m()};let h;f.allowRecurse=!!t,h="sync"===r?f:"post"===r?()=>Ro(f,l&&l.suspense):()=>{!l||l.isMounted?function(e){Gt(e,It,At,Mt)}(f):f()};const m=ie(c,{lazy:!0,onTrack:s,onTrigger:i,scheduler:h});return rs(m,l),t?n?f():d=m():"post"===r?Ro(m,l&&l.suspense):m(),()=>{le(m),l&&E(l.effects,m)}}function Yn(e,t,n){const o=this.proxy;return Xn(V(e)?()=>o[e]:e.bind(o),t.bind(o),n,this)}function eo(e,t=new Set){if(!A(e)||t.has(e))return e;if(t.add(e),at(e))eo(e.value,t);else if(O(e))for(let n=0;n{eo(e,t)}));else for(const n in e)eo(e[n],t);return e}function to(){const e={isMounted:!1,isLeaving:!1,isUnmounting:!1,leavingVNodes:new Map};return Dn((()=>{e.isMounted=!0})),zn((()=>{e.isUnmounting=!0})),e}const no=[Function,Array],oo={name:"BaseTransition",props:{mode:String,appear:Boolean,persisted:Boolean,onBeforeEnter:no,onEnter:no,onAfterEnter:no,onEnterCancelled:no,onBeforeLeave:no,onLeave:no,onAfterLeave:no,onLeaveCancelled:no,onBeforeAppear:no,onAppear:no,onAfterAppear:no,onAppearCancelled:no},setup(e,{slots:t}){const n=qr(),o=to();let r;return()=>{const s=t.default&&ao(t.default(),!0);if(!s||!s.length)return;const i=it(e),{mode:l}=i,c=s[0];if(o.isLeaving)return io(c);const a=lo(c);if(!a)return io(c);const u=so(a,i,o,n);co(a,u);const p=n.subTree,d=p&&lo(p);let f=!1;const{getTransitionKey:h}=a.type;if(h){const e=h();void 0===r?r=e:e!==r&&(r=e,f=!0)}if(d&&d.type!==sr&&(!gr(a,d)||f)){const e=so(d,i,o,n);if(co(d,e),"out-in"===l)return o.isLeaving=!0,e.afterLeave=()=>{o.isLeaving=!1,n.update()},io(c);"in-out"===l&&(e.delayLeave=(e,t,n)=>{ro(o,d)[String(d.key)]=d,e._leaveCb=()=>{t(),e._leaveCb=void 0,delete u.delayedLeave},u.delayedLeave=n})}return c}}};function ro(e,t){const{leavingVNodes:n}=e;let o=n.get(t.type);return o||(o=Object.create(null),n.set(t.type,o)),o}function so(e,t,n,o){const{appear:r,mode:s,persisted:i=!1,onBeforeEnter:l,onEnter:c,onAfterEnter:a,onEnterCancelled:u,onBeforeLeave:p,onLeave:d,onAfterLeave:f,onLeaveCancelled:h,onBeforeAppear:m,onAppear:g,onAfterAppear:v,onAppearCancelled:y}=t,_=String(e.key),b=ro(n,e),x=(e,t)=>{e&&Nt(e,o,9,t)},S={mode:s,persisted:i,beforeEnter(t){let o=l;if(!n.isMounted){if(!r)return;o=m||l}t._leaveCb&&t._leaveCb(!0);const s=b[_];s&&gr(e,s)&&s.el._leaveCb&&s.el._leaveCb(),x(o,[t])},enter(e){let t=c,o=a,s=u;if(!n.isMounted){if(!r)return;t=g||c,o=v||a,s=y||u}let i=!1;const l=e._enterCb=t=>{i||(i=!0,x(t?s:o,[e]),S.delayedLeave&&S.delayedLeave(),e._enterCb=void 0)};t?(t(e,l),t.length<=1&&l()):l()},leave(t,o){const r=String(e.key);if(t._enterCb&&t._enterCb(!0),n.isUnmounting)return o();x(p,[t]);let s=!1;const i=t._leaveCb=n=>{s||(s=!0,o(),x(n?h:f,[t]),t._leaveCb=void 0,b[r]===e&&delete b[r])};b[r]=e,d?(d(t,i),d.length<=1&&i()):i()},clone:e=>so(e,t,n,o)};return S}function io(e){if(uo(e))return(e=Sr(e)).children=null,e}function lo(e){return uo(e)?e.children?e.children[0]:void 0:e}function co(e,t){6&e.shapeFlag&&e.component?co(e.component.subTree,t):128&e.shapeFlag?(e.ssContent.transition=t.clone(e.ssContent),e.ssFallback.transition=t.clone(e.ssFallback)):e.transition=t}function ao(e,t=!1){let n=[],o=0;for(let r=0;r1)for(let e=0;ee.type.__isKeepAlive,po={name:"KeepAlive",__isKeepAlive:!0,props:{include:[String,RegExp,Array],exclude:[String,RegExp,Array],max:[String,Number]},setup(e,{slots:t}){const n=new Map,o=new Set;let r=null;const s=qr(),i=s.suspense,l=s.ctx,{renderer:{p:c,m:a,um:u,o:{createElement:p}}}=l,d=p("div");function f(e){yo(e),u(e,s,i)}function h(e){n.forEach(((t,n)=>{const o=is(t.type);!o||e&&e(o)||m(n)}))}function m(e){const t=n.get(e);r&&t.type===r.type?r&&yo(r):f(t),n.delete(e),o.delete(e)}l.activate=(e,t,n,o,r)=>{const s=e.component;a(e,t,n,0,i),c(s.vnode,e,t,n,s,i,o,r),Ro((()=>{s.isDeactivated=!1,s.a&&Z(s.a);const t=e.props&&e.props.onVnodeMounted;t&&Ho(t,s.parent,e)}),i)},l.deactivate=e=>{const t=e.component;a(e,d,null,1,i),Ro((()=>{t.da&&Z(t.da);const n=e.props&&e.props.onVnodeUnmounted;n&&Ho(n,t.parent,e),t.isDeactivated=!0}),i)},Qn((()=>[e.include,e.exclude]),(([e,t])=>{e&&h((t=>fo(e,t))),t&&h((e=>!fo(t,e)))}),{flush:"post",deep:!0});let g=null;const v=()=>{null!=g&&n.set(g,_o(s.subTree))};return Dn(v),Hn(v),zn((()=>{n.forEach((e=>{const{subTree:t,suspense:n}=s,o=_o(t);if(e.type!==o.type)f(e);else{yo(o);const e=o.component.da;e&&Ro(e,n)}}))})),()=>{if(g=null,!t.default)return null;const s=t.default(),i=s[0];if(s.length>1)return r=null,s;if(!mr(i)||!(4&i.shapeFlag||128&i.shapeFlag))return r=null,i;let l=_o(i);const c=l.type,a=is(c),{include:u,exclude:p,max:d}=e;if(u&&(!a||!fo(u,a))||p&&a&&fo(p,a))return r=l,i;const f=null==l.key?c:l.key,h=n.get(f);return l.el&&(l=Sr(l),128&i.shapeFlag&&(i.ssContent=l)),g=f,h?(l.el=h.el,l.component=h.component,l.transition&&co(l,l.transition),l.shapeFlag|=512,o.delete(f),o.add(f)):(o.add(f),d&&o.size>parseInt(d,10)&&m(o.values().next().value)),l.shapeFlag|=256,r=l,i}}};function fo(e,t){return O(e)?e.some((e=>fo(e,t))):V(e)?e.split(",").indexOf(t)>-1:!!e.test&&e.test(t)}function ho(e,t){go(e,"a",t)}function mo(e,t){go(e,"da",t)}function go(e,t,n=Gr){const o=e.__wdc||(e.__wdc=()=>{let t=n;for(;t;){if(t.isDeactivated)return;t=t.parent}e()});if(Rn(t,o,n),n){let e=n.parent;for(;e&&e.parent;)uo(e.parent.vnode)&&vo(o,t,n,e),e=e.parent}}function vo(e,t,n,o){const r=Rn(t,e,o,!0);Kn((()=>{E(o[t],r)}),n)}function yo(e){let t=e.shapeFlag;256&t&&(t-=256),512&t&&(t-=512),e.shapeFlag=t}function _o(e){return 128&e.shapeFlag?e.ssContent:e}const bo=e=>"_"===e[0]||"$stable"===e,xo=e=>O(e)?e.map(Tr):[Tr(e)],So=(e,t,n)=>En((e=>xo(t(e))),n),Co=(e,t)=>{const n=e._ctx;for(const o in e){if(bo(o))continue;const r=e[o];if(P(r))t[o]=So(0,r,n);else if(null!=r){const e=xo(r);t[o]=()=>e}}},wo=(e,t)=>{const n=xo(t);e.slots.default=()=>n};function Eo(e,t){if(null===an)return e;const n=an.proxy,o=e.dirs||(e.dirs=[]);for(let e=0;e(s.has(e)||(e&&P(e.install)?(s.add(e),e.install(l,...t)):P(e)&&(s.add(e),e(l,...t))),l),mixin:e=>(__VUE_OPTIONS_API__&&(r.mixins.includes(e)||(r.mixins.push(e),(e.props||e.emits)&&(r.deopt=!0))),l),component:(e,t)=>t?(r.components[e]=t,l):r.components[e],directive:(e,t)=>t?(r.directives[e]=t,l):r.directives[e],mount(s,c){if(!i){const a=xr(n,o);return a.appContext=r,c&&t?t(a,s):e(a,s),i=!0,l._container=s,s.__vue_app__=l,__VUE_PROD_DEVTOOLS__&&function(e,t){Yt&&Yt.emit("app:init",e,t,{Fragment:or,Text:rr,Comment:sr,Static:ir})}(l,_s),a.component.proxy}},unmount(){i&&(e(null,l._container),__VUE_PROD_DEVTOOLS__&&function(e){Yt&&Yt.emit("app:unmount",e)}(l),delete l._container.__vue_app__)},provide:(e,t)=>(r.provides[e]=t,l)};return l}}let $o=!1;const Lo=e=>/svg/.test(e.namespaceURI)&&"foreignObject"!==e.tagName,Po=e=>8===e.nodeType;function Vo(e){const{mt:t,p:n,o:{patchProp:o,nextSibling:r,parentNode:s,remove:i,insert:l,createComment:c}}=e,a=(n,o,i,l,c=!1)=>{const m=Po(n)&&"["===n.data,g=()=>f(n,o,i,l,m),{type:v,ref:y,shapeFlag:_}=o,b=n.nodeType;o.el=n;let x=null;switch(v){case rr:3!==b?x=g():(n.data!==o.children&&($o=!0,n.data=o.children),x=r(n));break;case sr:x=8!==b||m?g():r(n);break;case ir:if(1===b){x=n;const e=!o.children.length;for(let t=0;t{t(o,e,null,i,l,Lo(e),c)},u=o.type.__asyncLoader;u?u().then(a):a(),x=m?h(n):r(n)}else 64&_?x=8!==b?g():o.type.hydrate(n,o,i,l,c,e,p):128&_&&(x=o.type.hydrate(n,o,i,l,Lo(s(n)),c,e,a))}return null!=y&&Bo(y,null,l,o),x},u=(e,t,n,r,s)=>{s=s||!!t.dynamicChildren;const{props:l,patchFlag:c,shapeFlag:a,dirs:u}=t;if(-1!==c){if(u&&To(t,null,n,"created"),l)if(!s||16&c||32&c)for(const t in l)!D(t)&&S(t)&&o(e,t,null,l[t]);else l.onClick&&o(e,"onClick",null,l.onClick);let d;if((d=l&&l.onVnodeBeforeMount)&&Ho(d,n,t),u&&To(t,null,n,"beforeMount"),((d=l&&l.onVnodeMounted)||u)&&_n((()=>{d&&Ho(d,n,t),u&&To(t,null,n,"mounted")}),r),16&a&&(!l||!l.innerHTML&&!l.textContent)){let o=p(e.firstChild,t,e,n,r,s);for(;o;){$o=!0;const e=o;o=o.nextSibling,i(e)}}else 8&a&&e.textContent!==t.children&&($o=!0,e.textContent=t.children)}return e.nextSibling},p=(e,t,o,r,s,i)=>{i=i||!!t.dynamicChildren;const l=t.children,c=l.length;for(let t=0;t{const a=s(e),u=p(r(e),t,a,n,o,i);return u&&Po(u)&&"]"===u.data?r(t.anchor=u):($o=!0,l(t.anchor=c("]"),a,u),u)},f=(e,t,o,l,c)=>{if($o=!0,t.el=null,c){const t=h(e);for(;;){const n=r(e);if(!n||n===t)break;i(n)}}const a=r(e),u=s(e);return i(e),n(null,t,u,a,o,l,Lo(u)),a},h=e=>{let t=0;for(;e;)if((e=r(e))&&Po(e)&&("["===e.data&&t++,"]"===e.data)){if(0===t)return r(e);t--}return e};return[(e,t)=>{$o=!1,a(t.firstChild,e,null,null),Zt(),$o&&console.error("Hydration completed but contains mismatches.")},a]}function Fo(e){return P(e)?{setup:e,name:e.name}:e}function Ao(e){P(e)&&(e={loader:e});const{loader:t,loadingComponent:n,errorComponent:o,delay:r=200,timeout:s,suspensible:i=!0,onError:l}=e;let c,a=null,u=0;const p=()=>{let e;return a||(e=a=t().catch((e=>{if(e=e instanceof Error?e:new Error(String(e)),l)return new Promise(((t,n)=>{l(e,(()=>t((u++,a=null,p()))),(()=>n(e)),u+1)}));throw e})).then((t=>e!==a&&a?a:(t&&(t.__esModule||"Module"===t[Symbol.toStringTag])&&(t=t.default),c=t,t))))};return Fo({__asyncLoader:p,name:"AsyncComponentWrapper",setup(){const e=Gr;if(c)return()=>Io(c,e);const t=t=>{a=null,$t(t,e,13,!o)};if(i&&e.suspense)return p().then((t=>()=>Io(t,e))).catch((e=>(t(e),()=>o?xr(o,{error:e}):null)));const l=ut(!1),u=ut(),d=ut(!!r);return r&&setTimeout((()=>{d.value=!1}),r),null!=s&&setTimeout((()=>{if(!l.value&&!u.value){const e=new Error(`Async component timed out after ${s}ms.`);t(e),u.value=e}}),s),p().then((()=>{l.value=!0})).catch((e=>{t(e),u.value=e})),()=>l.value&&c?Io(c,e):u.value&&o?xr(o,{error:u.value}):n&&!d.value?xr(n):void 0}})}function Io(e,{vnode:{ref:t,props:n,children:o}}){const r=xr(e,n,o);return r.ref=t,r}const Mo={scheduler:Kt,allowRecurse:!0},Ro=_n,Bo=(e,t,n,o)=>{if(O(e))return void e.forEach(((e,r)=>Bo(e,t&&(O(t)?t[r]:t),n,o)));let r;r=!o||o.type.__asyncLoader?null:4&o.shapeFlag?o.component.exposed||o.component.proxy:o.el;const{i:s,r:i}=e,l=t&&t.r,c=s.refs===v?s.refs={}:s.refs,a=s.setupState;if(null!=l&&l!==i&&(V(l)?(c[l]=null,k(a,l)&&(a[l]=null)):at(l)&&(l.value=null)),V(i)){const e=()=>{c[i]=r,k(a,i)&&(a[i]=r)};r?(e.id=-1,Ro(e,n)):e()}else if(at(i)){const e=()=>{i.value=r};r?(e.id=-1,Ro(e,n)):e()}else P(i)&&Ot(i,s,12,[r,c])};function Uo(e){return jo(e)}function Do(e){return jo(e,Vo)}function jo(e,t){if(function(){let e=!1;"boolean"!=typeof __VUE_OPTIONS_API__&&(e=!0,ee().__VUE_OPTIONS_API__=!0),"boolean"!=typeof __VUE_PROD_DEVTOOLS__&&(e=!0,ee().__VUE_PROD_DEVTOOLS__=!1)}(),__VUE_PROD_DEVTOOLS__){const e=ee();e.__VUE__=!0,en(e.__VUE_DEVTOOLS_GLOBAL_HOOK__)}const{insert:n,remove:o,patchProp:r,forcePatchProp:s,createElement:i,createText:l,createComment:c,setText:a,setElementText:u,parentNode:p,nextSibling:d,setScopeId:f=_,cloneNode:h,insertStaticContent:m}=e,g=(e,t,n,o=null,r=null,s=null,i=!1,l=!1)=>{e&&!gr(e,t)&&(o=Y(e),K(e,r,s,!0),e=null),-2===t.patchFlag&&(l=!1,t.dynamicChildren=null);const{type:c,ref:a,shapeFlag:u}=t;switch(c){case rr:b(e,t,n,o);break;case sr:x(e,t,n,o);break;case ir:null==e&&S(t,n,o,i);break;case or:P(e,t,n,o,r,s,i,l);break;default:1&u?C(e,t,n,o,r,s,i,l):6&u?V(e,t,n,o,r,s,i,l):(64&u||128&u)&&c.process(e,t,n,o,r,s,i,l,ne)}null!=a&&r&&Bo(a,e&&e.ref,s,t)},b=(e,t,o,r)=>{if(null==e)n(t.el=l(t.children),o,r);else{const n=t.el=e.el;t.children!==e.children&&a(n,t.children)}},x=(e,t,o,r)=>{null==e?n(t.el=c(t.children||""),o,r):t.el=e.el},S=(e,t,n,o)=>{[e.el,e.anchor]=m(e.children,t,n,o)},C=(e,t,n,o,r,s,i,l)=>{i=i||"svg"===t.type,null==e?E(t,n,o,r,s,i,l):N(e,t,r,s,i,l)},E=(e,t,o,s,l,c,a)=>{let p,d;const{type:f,props:m,shapeFlag:g,transition:v,scopeId:y,patchFlag:_,dirs:b}=e;if(e.el&&void 0!==h&&-1===_)p=e.el=h(e.el);else{if(p=e.el=i(e.type,c,m&&m.is),8&g?u(p,e.children):16&g&&O(e.children,p,null,s,l,c&&"foreignObject"!==f,a||!!e.dynamicChildren),b&&To(e,null,s,"created"),m){for(const t in m)D(t)||r(p,t,null,m[t],c,e.children,s,l,X);(d=m.onVnodeBeforeMount)&&Ho(d,s,e)}T(p,y,e,s)}__VUE_PROD_DEVTOOLS__&&(Object.defineProperty(p,"__vnode",{value:e,enumerable:!1}),Object.defineProperty(p,"__vueParentComponent",{value:s,enumerable:!1})),b&&To(e,null,s,"beforeMount");const x=(!l||l&&!l.pendingBranch)&&v&&!v.persisted;x&&v.beforeEnter(p),n(p,t,o),((d=m&&m.onVnodeMounted)||x||b)&&Ro((()=>{d&&Ho(d,s,e),x&&v.enter(p),b&&To(e,null,s,"mounted")}),l)},T=(e,t,n,o)=>{if(t&&f(e,t),o){const r=o.type.__scopeId;r&&r!==t&&f(e,r+"-s"),n===o.subTree&&T(e,o.vnode.scopeId,o.vnode,o.parent)}},O=(e,t,n,o,r,s,i,l=0)=>{for(let c=l;c{const c=t.el=e.el;let{patchFlag:a,dynamicChildren:p,dirs:d}=t;a|=16&e.patchFlag;const f=e.props||v,h=t.props||v;let m;if((m=h.onVnodeBeforeUpdate)&&Ho(m,n,t,e),d&&To(t,e,n,"beforeUpdate"),a>0){if(16&a)L(c,t,f,h,n,o,i);else if(2&a&&f.class!==h.class&&r(c,"class",null,h.class,i),4&a&&r(c,"style",f.style,h.style,i),8&a){const l=t.dynamicProps;for(let t=0;t{m&&Ho(m,n,t,e),d&&To(t,e,n,"updated")}),o)},$=(e,t,n,o,r,s)=>{for(let i=0;i{if(n!==o){for(const a in o){if(D(a))continue;const u=o[a],p=n[a];(u!==p||s&&s(e,a))&&r(e,a,p,u,c,t.children,i,l,X)}if(n!==v)for(const s in n)D(s)||s in o||r(e,s,n[s],null,c,t.children,i,l,X)}},P=(e,t,o,r,s,i,c,a)=>{const u=t.el=e?e.el:l(""),p=t.anchor=e?e.anchor:l("");let{patchFlag:d,dynamicChildren:f}=t;d>0&&(a=!0),null==e?(n(u,o,r),n(p,o,r),O(t.children,o,p,s,i,c,a)):d>0&&64&d&&f&&e.dynamicChildren?($(e.dynamicChildren,f,o,s,i,c),(null!=t.key||s&&t===s.subTree)&&zo(e,t,!0)):B(e,t,o,p,s,i,c,a)},V=(e,t,n,o,r,s,i,l)=>{null==e?512&t.shapeFlag?r.ctx.activate(t,n,o,i,l):F(t,n,o,r,s,i,l):A(e,t,l)},F=(e,t,n,o,r,s,i)=>{const l=e.component=function(e,t,n){const o=e.type,r=(t?t.appContext:e.appContext)||Kr,s={uid:Wr++,vnode:e,type:o,parent:t,appContext:r,root:null,next:null,subTree:null,update:null,render:null,proxy:null,exposed:null,withProxy:null,effects:null,provides:t?t.provides:Object.create(r.provides),accessCache:null,renderCache:[],components:null,directives:null,propsOptions:Vn(o,r),emitsOptions:ln(o,r),emit:null,emitted:null,ctx:v,data:v,props:v,attrs:v,slots:v,refs:v,setupState:v,setupContext:null,suspense:n,suspenseId:n?n.pendingId:0,asyncDep:null,asyncResolved:!1,isMounted:!1,isUnmounted:!1,isDeactivated:!1,bc:null,c:null,bm:null,m:null,bu:null,u:null,um:null,bum:null,da:null,a:null,rtg:null,rtc:null,ec:null};return s.ctx={_:s},s.root=t?t.root:s,s.emit=sn.bind(null,s),s}(e,o,r);if(uo(e)&&(l.ctx.renderer=ne),function(e,t=!1){Xr=t;const{props:n,children:o}=e.vnode,r=Zr(e);(function(e,t,n,o=!1){const r={},s={};Q(s,yr,1),Ln(e,t,r,s),n?e.props=o?r:Ye(r):e.type.props?e.props=r:e.props=s,e.attrs=s})(e,n,r,t),((e,t)=>{if(32&e.vnode.shapeFlag){const n=t._;n?(e.slots=t,Q(t,"_",n)):Co(t,e.slots={})}else e.slots={},t&&wo(e,t);Q(e.slots,yr,1)})(e,o);r&&function(e,t){const n=e.type;e.accessCache=Object.create(null),e.proxy=new Proxy(e.ctx,Hr);const{setup:o}=n;if(o){const n=e.setupContext=o.length>1?os(e):null;Gr=e,de();const r=Ot(o,e,0,[e.props,n]);if(fe(),Gr=null,I(r)){if(t)return r.then((t=>{Yr(e,t)}));e.asyncDep=r}else Yr(e,r)}else ns(e)}(e,t);Xr=!1}(l),l.asyncDep){if(r&&r.registerDep(l,M),!e.el){const e=l.subTree=xr(sr);x(null,e,t,n)}}else M(l,e,t,n,r,s,i)},A=(e,t,n)=>{const o=t.component=e.component;if(function(e,t,n){const{props:o,children:r,component:s}=e,{props:i,children:l,patchFlag:c}=t,a=s.emitsOptions;if(t.dirs||t.transition)return!0;if(!(n&&c>=0))return!(!r&&!l||l&&l.$stable)||o!==i&&(o?!i||hn(o,i,a):!!i);if(1024&c)return!0;if(16&c)return o?hn(o,i,a):!!i;if(8&c){const e=t.dynamicProps;for(let t=0;t-1&&Vt.splice(t,1)}(o.update),o.update()}else t.component=e.component,t.el=e.el,o.vnode=t},M=(e,t,n,o,r,s,i)=>{e.update=ie((function(){if(e.isMounted){let t,{next:n,bu:o,u:l,parent:c,vnode:a}=e,u=n;n?(n.el=a.el,R(e,n,i)):n=a,o&&Z(o),(t=n.props&&n.props.onVnodeBeforeUpdate)&&Ho(t,c,n,a);const d=pn(e),f=e.subTree;e.subTree=d,g(f,d,p(f.el),Y(f),e,r,s),n.el=d.el,null===u&&mn(e,d.el),l&&Ro(l,r),(t=n.props&&n.props.onVnodeUpdated)&&Ro((()=>{Ho(t,c,n,a)}),r),__VUE_PROD_DEVTOOLS__&&nn(e)}else{let i;const{el:l,props:c}=t,{bm:a,m:u,parent:p}=e;a&&Z(a),(i=c&&c.onVnodeBeforeMount)&&Ho(i,p,t);const d=e.subTree=pn(e);if(l&&re?re(t.el,d,e,r):(g(null,d,n,o,e,r,s),t.el=d.el),u&&Ro(u,r),i=c&&c.onVnodeMounted){const e=t;Ro((()=>{Ho(i,p,e)}),r)}const{a:f}=e;f&&256&t.shapeFlag&&Ro(f,r),e.isMounted=!0,__VUE_PROD_DEVTOOLS__&&tn(e),t=n=o=null}}),Mo)},R=(e,t,n)=>{t.component=e;const o=e.vnode.props;e.vnode=t,e.next=null,function(e,t,n,o){const{props:r,attrs:s,vnode:{patchFlag:i}}=e,l=it(r),[c]=e.propsOptions;if(!(o||i>0)||16&i){let o;Ln(e,t,r,s);for(const s in l)t&&(k(t,s)||(o=W(s))!==s&&k(t,o))||(c?!n||void 0===n[s]&&void 0===n[o]||(r[s]=Pn(c,t||v,s,void 0,e)):delete r[s]);if(s!==l)for(const e in s)t&&k(t,e)||delete s[e]}else if(8&i){const n=e.vnode.dynamicProps;for(let o=0;o{const{vnode:n,slots:o}=e;let r=!0,s=v;if(32&n.shapeFlag){const e=t._;e?1===e?r=!1:w(o,t):(r=!t.$stable,Co(t,o)),s=t}else t&&(wo(e,t),s={default:1});if(r)for(const e in o)bo(e)||e in s||delete o[e]})(e,t.children),Jt(void 0,e.update)},B=(e,t,n,o,r,s,i,l=!1)=>{const c=e&&e.children,a=e?e.shapeFlag:0,p=t.children,{patchFlag:d,shapeFlag:f}=t;if(d>0){if(128&d)return void j(c,p,n,o,r,s,i,l);if(256&d)return void U(c,p,n,o,r,s,i,l)}8&f?(16&a&&X(c,r,s),p!==c&&u(n,p)):16&a?16&f?j(c,p,n,o,r,s,i,l):X(c,r,s,!0):(8&a&&u(n,""),16&f&&O(p,n,o,r,s,i,l))},U=(e,t,n,o,r,s,i,l)=>{t=t||y;const c=(e=e||y).length,a=t.length,u=Math.min(c,a);let p;for(p=0;pa?X(e,r,s,!0,!1,u):O(t,n,o,r,s,i,l,u)},j=(e,t,n,o,r,s,i,l)=>{let c=0;const a=t.length;let u=e.length-1,p=a-1;for(;c<=u&&c<=p;){const o=e[c],a=t[c]=l?kr(t[c]):Tr(t[c]);if(!gr(o,a))break;g(o,a,n,null,r,s,i,l),c++}for(;c<=u&&c<=p;){const o=e[u],c=t[p]=l?kr(t[p]):Tr(t[p]);if(!gr(o,c))break;g(o,c,n,null,r,s,i,l),u--,p--}if(c>u){if(c<=p){const e=p+1,u=ep)for(;c<=u;)K(e[c],r,s,!0),c++;else{const d=c,f=c,h=new Map;for(c=f;c<=p;c++){const e=t[c]=l?kr(t[c]):Tr(t[c]);null!=e.key&&h.set(e.key,c)}let m,v=0;const _=p-f+1;let b=!1,x=0;const S=new Array(_);for(c=0;c<_;c++)S[c]=0;for(c=d;c<=u;c++){const o=e[c];if(v>=_){K(o,r,s,!0);continue}let a;if(null!=o.key)a=h.get(o.key);else for(m=f;m<=p;m++)if(0===S[m-f]&&gr(o,t[m])){a=m;break}void 0===a?K(o,r,s,!0):(S[a-f]=c+1,a>=x?x=a:b=!0,g(o,t[a],n,null,r,s,i,l),v++)}const C=b?function(e){const t=e.slice(),n=[0];let o,r,s,i,l;const c=e.length;for(o=0;o0&&(t[o]=n[s-1]),n[s]=o)}}for(s=n.length,i=n[s-1];s-- >0;)n[s]=i,i=t[i];return n}(S):y;for(m=C.length-1,c=_-1;c>=0;c--){const e=f+c,l=t[e],u=e+1{const{el:i,type:l,transition:c,children:a,shapeFlag:u}=e;if(6&u)H(e.component.subTree,t,o,r);else if(128&u)e.suspense.move(t,o,r);else if(64&u)l.move(e,t,o,ne);else if(l!==or)if(l!==ir)if(2!==r&&1&u&&c)if(0===r)c.beforeEnter(i),n(i,t,o),Ro((()=>c.enter(i)),s);else{const{leave:e,delayLeave:r,afterLeave:s}=c,l=()=>n(i,t,o),a=()=>{e(i,(()=>{l(),s&&s()}))};r?r(i,l,a):a()}else n(i,t,o);else(({el:e,anchor:t},o,r)=>{let s;for(;e&&e!==t;)s=d(e),n(e,o,r),e=s;n(t,o,r)})(e,t,o);else{n(i,t,o);for(let e=0;e{const{type:s,props:i,ref:l,children:c,dynamicChildren:a,shapeFlag:u,patchFlag:p,dirs:d}=e;if(null!=l&&Bo(l,null,n,null),256&u)return void t.ctx.deactivate(e);const f=1&u&&d;let h;if((h=i&&i.onVnodeBeforeUnmount)&&Ho(h,t,e),6&u)J(e.component,n,o);else{if(128&u)return void e.suspense.unmount(n,o);f&&To(e,null,t,"beforeUnmount"),a&&(s!==or||p>0&&64&p)?X(a,t,n,!1,!0):(s===or&&(128&p||256&p)||!r&&16&u)&&X(c,t,n),64&u&&(o||!Ko(e.props))&&e.type.remove(e,ne),o&&G(e)}((h=i&&i.onVnodeUnmounted)||f)&&Ro((()=>{h&&Ho(h,t,e),f&&To(e,null,t,"unmounted")}),n)},G=e=>{const{type:t,el:n,anchor:r,transition:s}=e;if(t===or)return void q(n,r);if(t===ir)return void(({el:e,anchor:t})=>{let n;for(;e&&e!==t;)n=d(e),o(e),e=n;o(t)})(e);const i=()=>{o(n),s&&!s.persisted&&s.afterLeave&&s.afterLeave()};if(1&e.shapeFlag&&s&&!s.persisted){const{leave:t,delayLeave:o}=s,r=()=>t(n,i);o?o(e.el,i,r):r()}else i()},q=(e,t)=>{let n;for(;e!==t;)n=d(e),o(e),e=n;o(t)},J=(e,t,n)=>{const{bum:o,effects:r,update:s,subTree:i,um:l}=e;if(o&&Z(o),r)for(let e=0;e{e.isUnmounted=!0}),t),t&&t.pendingBranch&&!t.isUnmounted&&e.asyncDep&&!e.asyncResolved&&e.suspenseId===t.pendingId&&(t.deps--,0===t.deps&&t.resolve()),__VUE_PROD_DEVTOOLS__&&on(e)},X=(e,t,n,o=!1,r=!1,s=0)=>{for(let i=s;i6&e.shapeFlag?Y(e.component.subTree):128&e.shapeFlag?e.suspense.next():d(e.anchor||e.el),te=(e,t)=>{null==e?t._vnode&&K(t._vnode,null,null,!0):g(t._vnode||null,e,t),Zt(),t._vnode=e},ne={p:g,um:K,m:H,r:G,mt:F,mc:O,pc:B,pbc:$,n:Y,o:e};let oe,re;return t&&([oe,re]=t(ne)),{render:te,hydrate:oe,createApp:No(te,oe)}}function Ho(e,t,n,o=null){Nt(e,t,7,[n,o])}function zo(e,t,n=!1){const o=e.children,r=t.children;if(O(o)&&O(r))for(let e=0;ee&&(e.disabled||""===e.disabled),Wo=e=>"undefined"!=typeof SVGElement&&e instanceof SVGElement,Go=(e,t)=>{const n=e&&e.to;if(V(n)){if(t){return t(n)}return null}return n};function qo(e,t,n,{o:{insert:o},m:r},s=2){0===s&&o(e.targetAnchor,t,n);const{el:i,anchor:l,shapeFlag:c,children:a,props:u}=e,p=2===s;if(p&&o(i,t,n),(!p||Ko(u))&&16&c)for(let e=0;e{16&v&&a(y,e,t,r,s,i,l)};g?m(n,c):u&&m(u,p)}else{t.el=e.el;const o=t.anchor=e.anchor,a=t.target=e.target,d=t.targetAnchor=e.targetAnchor,h=Ko(e.props),m=h?n:a,v=h?o:d;if(i=i||Wo(a),t.dynamicChildren?(p(e.dynamicChildren,t.dynamicChildren,m,r,s,i),zo(e,t,!0)):l||u(e,t,m,v,r,s,i),g)h||qo(t,n,o,c,1);else if((t.props&&t.props.to)!==(e.props&&e.props.to)){const e=t.target=Go(t.props,f);e&&qo(t,e,null,c,0)}else h&&qo(t,a,d,c,1)}},remove(e,{r:t,o:{remove:n}}){const{shapeFlag:o,children:r,anchor:s}=e;if(n(s),16&o)for(let e=0;e0&&cr&&cr.push(s),s}function mr(e){return!!e&&!0===e.__v_isVNode}function gr(e,t){return e.type===t.type&&e.key===t.key}function vr(e){pr=e}const yr="__vInternal",_r=({key:e})=>null!=e?e:null,br=({ref:e})=>null!=e?V(e)||at(e)||P(e)?{i:an,r:e}:e:null,xr=function(e,t=null,n=null,o=0,r=null,i=!1){if(e&&e!==Xo||(e=sr),mr(e)){const o=Sr(e,t,!0);return n&&Or(o,n),o}if(l=e,P(l)&&"__vccOpts"in l&&(e=e.__vccOpts),t){(st(t)||yr in t)&&(t=w({},t));let{class:e,style:n}=t;e&&!V(e)&&(t.class=a(e)),A(n)&&(st(n)&&!O(n)&&(n=w({},n)),t.style=s(n))}var l;const c=V(e)?1:(e=>e.__isSuspense)(e)?128:(e=>e.__isTeleport)(e)?64:A(e)?4:P(e)?2:0,u={__v_isVNode:!0,__v_skip:!0,type:e,props:t,key:t&&_r(t),ref:t&&br(t),scopeId:Tn,children:null,component:null,suspense:null,ssContent:null,ssFallback:null,dirs:null,transition:null,el:null,anchor:null,target:null,targetAnchor:null,staticCount:0,shapeFlag:c,patchFlag:o,dynamicProps:r,dynamicChildren:null,appContext:null};if(Or(u,n),128&c){const{content:e,fallback:t}=function(e){const{shapeFlag:t,children:n}=e;let o,r;return 32&t?(o=yn(n.default),r=yn(n.fallback)):(o=yn(n),r=Tr(null)),{content:o,fallback:r}}(u);u.ssContent=e,u.ssFallback=t}return dr>0&&!i&&cr&&(o>0||6&c)&&32!==o&&cr.push(u),u};function Sr(e,t,n=!1){const{props:o,ref:r,patchFlag:s,children:i}=e,l=t?Nr(o||{},t):o;return{__v_isVNode:!0,__v_skip:!0,type:e.type,props:l,key:l&&_r(l),ref:t&&t.ref?n&&r?O(r)?r.concat(br(t)):[r,br(t)]:br(t):r,scopeId:e.scopeId,children:i,target:e.target,targetAnchor:e.targetAnchor,staticCount:e.staticCount,shapeFlag:e.shapeFlag,patchFlag:t&&e.type!==or?-1===s?16:16|s:s,dynamicProps:e.dynamicProps,dynamicChildren:e.dynamicChildren,appContext:e.appContext,dirs:e.dirs,transition:e.transition,component:e.component,suspense:e.suspense,ssContent:e.ssContent&&Sr(e.ssContent),ssFallback:e.ssFallback&&Sr(e.ssFallback),el:e.el,anchor:e.anchor}}function Cr(e=" ",t=0){return xr(rr,null,e,t)}function wr(e,t){const n=xr(ir,null,e);return n.staticCount=t,n}function Er(e="",t=!1){return t?(ar(),hr(sr,null,e)):xr(sr,null,e)}function Tr(e){return null==e||"boolean"==typeof e?xr(sr):O(e)?xr(or,null,e):"object"==typeof e?null===e.el?e:Sr(e):xr(rr,null,String(e))}function kr(e){return null===e.el?e:Sr(e)}function Or(e,t){let n=0;const{shapeFlag:o}=e;if(null==t)t=null;else if(O(t))n=16;else if("object"==typeof t){if(1&o||64&o){const n=t.default;return void(n&&(n._c&&Sn(1),Or(e,n()),n._c&&Sn(-1)))}{n=32;const o=t._;o||yr in t?3===o&&an&&(1024&an.vnode.patchFlag?(t._=2,e.patchFlag|=1024):t._=1):t._ctx=an}}else P(t)?(t={default:t,_ctx:an},n=32):(t=String(t),64&o?(n=16,t=[Cr(t)]):n=8);e.children=t,e.shapeFlag|=n}function Nr(...e){const t=w({},e[0]);for(let n=1;n1)return n&&P(t)?t():t}}let Pr=!1;function Vr(e,t,n=[],o=[],r=[],s=!1){const{mixins:i,extends:l,data:c,computed:a,methods:u,watch:p,provide:d,inject:f,components:h,directives:m,beforeMount:g,mounted:y,beforeUpdate:b,updated:x,activated:S,deactivated:C,beforeDestroy:E,beforeUnmount:T,destroyed:k,unmounted:N,render:$,renderTracked:L,renderTriggered:V,errorCaptured:F,expose:I}=t,M=e.proxy,R=e.ctx,B=e.appContext.mixins;if(s&&$&&e.render===_&&(e.render=$),s||(Pr=!0,Fr("beforeCreate","bc",t,e,B),Pr=!1,Mr(e,B,n,o,r)),l&&Vr(e,l,n,o,r,!0),i&&Mr(e,i,n,o,r),f)if(O(f))for(let e=0;eRr(e,t,M))),c&&Rr(e,c,M)),a)for(const e in a){const t=a[e],n=cs({get:P(t)?t.bind(M,M):P(t.get)?t.get.bind(M,M):_,set:!P(t)&&P(t.set)?t.set.bind(M):_});Object.defineProperty(R,e,{enumerable:!0,configurable:!0,get:()=>n.value,set:e=>n.value=e})}if(p&&o.push(p),!s&&o.length&&o.forEach((e=>{for(const t in e)Br(e[t],R,M,t)})),d&&r.push(d),!s&&r.length&&r.forEach((e=>{const t=P(e)?e.call(M):e;Reflect.ownKeys(t).forEach((e=>{$r(e,t[e])}))})),s&&(h&&w(e.components||(e.components=w({},e.type.components)),h),m&&w(e.directives||(e.directives=w({},e.type.directives)),m)),s||Fr("created","c",t,e,B),g&&Un(g.bind(M)),y&&Dn(y.bind(M)),b&&jn(b.bind(M)),x&&Hn(x.bind(M)),S&&ho(S.bind(M)),C&&mo(C.bind(M)),F&&qn(F.bind(M)),L&&Gn(L.bind(M)),V&&Wn(V.bind(M)),T&&zn(T.bind(M)),N&&Kn(N.bind(M)),O(I))if(s);else if(I.length){const t=e.exposed||(e.exposed=vt({}));I.forEach((e=>{t[e]=St(M,e)}))}else e.exposed||(e.exposed=v)}function Fr(e,t,n,o,r){Ir(e,t,r,o);const{extends:s,mixins:i}=n;s&&Ar(e,t,s,o),i&&Ir(e,t,i,o);const l=n[e];l&&Nt(l.bind(o.proxy),o,t)}function Ar(e,t,n,o){n.extends&&Ar(e,t,n.extends,o);const r=n[e];r&&Nt(r.bind(o.proxy),o,t)}function Ir(e,t,n,o){for(let r=0;r{let t=e;for(let e=0;en[o];if(V(e)){const n=t[e];P(n)&&Qn(r,n)}else if(P(e))Qn(r,e.bind(n));else if(A(e))if(O(e))e.forEach((e=>Br(e,t,n,o)));else{const o=P(e.handler)?e.handler.bind(n):t[e.handler];P(o)&&Qn(r,o,e)}}function Ur(e,t,n){const o=n.appContext.config.optionMergeStrategies,{mixins:r,extends:s}=t;s&&Ur(e,s,n),r&&r.forEach((t=>Ur(e,t,n)));for(const r in t)o&&k(o,r)?e[r]=o[r](e[r],t[r],n.proxy,r):e[r]=t[r]}const Dr=e=>e?Zr(e)?e.exposed?e.exposed:e.proxy:Dr(e.parent):null,jr=w(Object.create(null),{$:e=>e,$el:e=>e.vnode.el,$data:e=>e.data,$props:e=>e.props,$attrs:e=>e.attrs,$slots:e=>e.slots,$refs:e=>e.refs,$parent:e=>Dr(e.parent),$root:e=>Dr(e.root),$emit:e=>e.emit,$options:e=>__VUE_OPTIONS_API__?function(e){const t=e.type,{__merged:n,mixins:o,extends:r}=t;if(n)return n;const s=e.appContext.mixins;if(!s.length&&!o&&!r)return t;const i={};return s.forEach((t=>Ur(i,t,e))),Ur(i,t,e),t.__merged=i}(e):e.type,$forceUpdate:e=>()=>Kt(e.update),$nextTick:e=>zt.bind(e.proxy),$watch:e=>__VUE_OPTIONS_API__?Yn.bind(e):_}),Hr={get({_:e},t){const{ctx:n,setupState:o,data:r,props:s,accessCache:i,type:l,appContext:c}=e;if("__v_skip"===t)return!0;let a;if("$"!==t[0]){const l=i[t];if(void 0!==l)switch(l){case 0:return o[t];case 1:return r[t];case 3:return n[t];case 2:return s[t]}else{if(o!==v&&k(o,t))return i[t]=0,o[t];if(r!==v&&k(r,t))return i[t]=1,r[t];if((a=e.propsOptions[0])&&k(a,t))return i[t]=2,s[t];if(n!==v&&k(n,t))return i[t]=3,n[t];__VUE_OPTIONS_API__&&Pr||(i[t]=4)}}const u=jr[t];let p,d;return u?("$attrs"===t&&he(e,0,t),u(e)):(p=l.__cssModules)&&(p=p[t])?p:n!==v&&k(n,t)?(i[t]=3,n[t]):(d=c.config.globalProperties,k(d,t)?d[t]:void 0)},set({_:e},t,n){const{data:o,setupState:r,ctx:s}=e;if(r!==v&&k(r,t))r[t]=n;else if(o!==v&&k(o,t))o[t]=n;else if(k(e.props,t))return!1;return!("$"===t[0]&&t.slice(1)in e||(s[t]=n,0))},has({_:{data:e,setupState:t,accessCache:n,ctx:o,appContext:r,propsOptions:s}},i){let l;return void 0!==n[i]||e!==v&&k(e,i)||t!==v&&k(t,i)||(l=s[0])&&k(l,i)||k(o,i)||k(jr,i)||k(r.config.globalProperties,i)}},zr=w({},Hr,{get(e,t){if(t!==Symbol.unscopables)return Hr.get(e,t,e)},has:(e,t)=>"_"!==t[0]&&!o(t)}),Kr=ko();let Wr=0,Gr=null;const qr=()=>Gr||an,Jr=e=>{Gr=e};function Zr(e){return 4&e.vnode.shapeFlag}let Qr,Xr=!1;function Yr(e,t,n){P(t)?e.render=t:A(t)&&(__VUE_PROD_DEVTOOLS__&&(e.devtoolsRawSetupState=t),e.setupState=vt(t)),ns(e)}const es=()=>!Qr;function ts(e){Qr=e}function ns(e,t){const n=e.type;e.render||(Qr&&n.template&&!n.render&&(n.render=Qr(n.template,{isCustomElement:e.appContext.config.isCustomElement,delimiters:n.delimiters})),e.render=n.render||_,e.render._rc&&(e.withProxy=new Proxy(e.ctx,zr))),__VUE_OPTIONS_API__&&(Gr=e,de(),Vr(e,n),fe(),Gr=null)}function os(e){return{attrs:e.attrs,slots:e.slots,emit:e.emit,expose:t=>{e.exposed=vt(t)}}}function rs(e,t=Gr){t&&(t.effects||(t.effects=[])).push(e)}const ss=/(?:^|[-_])(\w)/g;function is(e){return P(e)&&e.displayName||e.name}function ls(e,t,n=!1){let o=is(t);if(!o&&t.__file){const e=t.__file.match(/([^/\\]+)\.\w+$/);e&&(o=e[1])}if(!o&&e&&e.parent){const n=e=>{for(const n in e)if(e[n]===t)return n};o=n(e.components||e.parent.type.components)||n(e.appContext.components)}return o?o.replace(ss,(e=>e.toUpperCase())).replace(/[-_]/g,""):n?"App":"Anonymous"}function cs(e){const t=function(e){let t,n;return P(e)?(t=e,n=_):(t=e.get,n=e.set),new Ct(t,n,P(e)||!e.set)}(e);return rs(t.effect),t}function as(){return null}function us(){return null}function ps(){const e=qr();return e.setupContext||(e.setupContext=os(e))}function ds(e,t,n){const o=arguments.length;return 2===o?A(t)&&!O(t)?mr(t)?xr(e,null,[t]):xr(e,t):xr(e,null,t):(o>3?n=Array.prototype.slice.call(arguments,2):3===o&&mr(n)&&(n=[n]),xr(e,t,n))}const fs=Symbol(""),hs=()=>{{const e=Lr(fs);return e||Et("Server rendering context not provided. Make sure to only call useSSRContext() conditionally in the server build."),e}};function ms(){}function gs(e,t){let n;if(O(e)||V(e)){n=new Array(e.length);for(let o=0,r=e.length;o{t.insertBefore(e,n||null)},remove:e=>{const t=e.parentNode;t&&t.removeChild(e)},createElement:(e,t,n)=>t?Ss.createElementNS(xs,e):Ss.createElement(e,n?{is:n}:void 0),createText:e=>Ss.createTextNode(e),createComment:e=>Ss.createComment(e),setText:(e,t)=>{e.nodeValue=t},setElementText:(e,t)=>{e.textContent=t},parentNode:e=>e.parentNode,nextSibling:e=>e.nextSibling,querySelector:e=>Ss.querySelector(e),setScopeId(e,t){e.setAttribute(t,"")},cloneNode:e=>e.cloneNode(!0),insertStaticContent(e,t,n,o){const r=o?ws||(ws=Ss.createElementNS(xs,"svg")):Cs||(Cs=Ss.createElement("div"));r.innerHTML=e;const s=r.firstChild;let i=s,l=i;for(;i;)l=i,Es.insert(i,t,n),i=r.firstChild;return[s,l]}},Ts=/\s*!important$/;function ks(e,t,n){if(O(n))n.forEach((n=>ks(e,t,n)));else if(t.startsWith("--"))e.setProperty(t,n);else{const o=function(e,t){const n=Ns[t];if(n)return n;let o=z(t);if("filter"!==o&&o in e)return Ns[t]=o;o=G(o);for(let n=0;ndocument.createEvent("Event").timeStamp&&(Ls=()=>performance.now());let Ps=0;const Vs=Promise.resolve(),Fs=()=>{Ps=0};function As(e,t,n,o){e.addEventListener(t,n,o)}const Is=/(?:Once|Passive|Capture)$/,Ms=/^on[a-z]/;function Rs(e="$style"){{const t=qr();if(!t)return v;const n=t.type.__cssModules;if(!n)return v;return n[e]||v}}function Bs(e){const t=qr();if(!t)return;const n=()=>Us(t.subTree,e(t.proxy));Dn((()=>Jn(n,{flush:"post"}))),Hn(n)}function Us(e,t){if(128&e.shapeFlag){const n=e.suspense;e=n.activeBranch,n.pendingBranch&&!n.isHydrating&&n.effects.push((()=>{Us(n.activeBranch,t)}))}for(;e.component;)e=e.component.subTree;if(1&e.shapeFlag&&e.el){const n=e.el.style;for(const e in t)n.setProperty(`--${e}`,t[e])}else e.type===or&&e.children.forEach((e=>Us(e,t)))}const Ds="transition",js="animation",Hs=(e,{slots:t})=>ds(oo,Ws(e),t);Hs.displayName="Transition";const zs={name:String,type:String,css:{type:Boolean,default:!0},duration:[String,Number,Object],enterFromClass:String,enterActiveClass:String,enterToClass:String,appearFromClass:String,appearActiveClass:String,appearToClass:String,leaveFromClass:String,leaveActiveClass:String,leaveToClass:String},Ks=Hs.props=w({},oo.props,zs);function Ws(e){let{name:t="v",type:n,css:o=!0,duration:r,enterFromClass:s=`${t}-enter-from`,enterActiveClass:i=`${t}-enter-active`,enterToClass:l=`${t}-enter-to`,appearFromClass:c=s,appearActiveClass:a=i,appearToClass:u=l,leaveFromClass:p=`${t}-leave-from`,leaveActiveClass:d=`${t}-leave-active`,leaveToClass:f=`${t}-leave-to`}=e;const h={};for(const t in e)t in zs||(h[t]=e[t]);if(!o)return h;const m=function(e){if(null==e)return null;if(A(e))return[Gs(e.enter),Gs(e.leave)];{const t=Gs(e);return[t,t]}}(r),g=m&&m[0],v=m&&m[1],{onBeforeEnter:y,onEnter:_,onEnterCancelled:b,onLeave:x,onLeaveCancelled:S,onBeforeAppear:C=y,onAppear:E=_,onAppearCancelled:T=b}=h,k=(e,t,n)=>{Js(e,t?u:l),Js(e,t?a:i),n&&n()},O=(e,t)=>{Js(e,f),Js(e,d),t&&t()},N=e=>(t,o)=>{const r=e?E:_,i=()=>k(t,e,o);r&&r(t,i),Zs((()=>{Js(t,e?c:s),qs(t,e?u:l),r&&r.length>1||Xs(t,n,g,i)}))};return w(h,{onBeforeEnter(e){y&&y(e),qs(e,s),qs(e,i)},onBeforeAppear(e){C&&C(e),qs(e,c),qs(e,a)},onEnter:N(!1),onAppear:N(!0),onLeave(e,t){const o=()=>O(e,t);qs(e,p),ni(),qs(e,d),Zs((()=>{Js(e,p),qs(e,f),x&&x.length>1||Xs(e,n,v,o)})),x&&x(e,o)},onEnterCancelled(e){k(e,!1),b&&b(e)},onAppearCancelled(e){k(e,!0),T&&T(e)},onLeaveCancelled(e){O(e),S&&S(e)}})}function Gs(e){return X(e)}function qs(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.add(t))),(e._vtc||(e._vtc=new Set)).add(t)}function Js(e,t){t.split(/\s+/).forEach((t=>t&&e.classList.remove(t)));const{_vtc:n}=e;n&&(n.delete(t),n.size||(e._vtc=void 0))}function Zs(e){requestAnimationFrame((()=>{requestAnimationFrame(e)}))}let Qs=0;function Xs(e,t,n,o){const r=e._endId=++Qs,s=()=>{r===e._endId&&o()};if(n)return setTimeout(s,n);const{type:i,timeout:l,propCount:c}=Ys(e,t);if(!i)return o();const a=i+"end";let u=0;const p=()=>{e.removeEventListener(a,d),s()},d=t=>{t.target===e&&++u>=c&&p()};setTimeout((()=>{u(n[e]||"").split(", "),r=o("transitionDelay"),s=o("transitionDuration"),i=ei(r,s),l=o("animationDelay"),c=o("animationDuration"),a=ei(l,c);let u=null,p=0,d=0;return t===Ds?i>0&&(u=Ds,p=i,d=s.length):t===js?a>0&&(u=js,p=a,d=c.length):(p=Math.max(i,a),u=p>0?i>a?Ds:js:null,d=u?u===Ds?s.length:c.length:0),{type:u,timeout:p,propCount:d,hasTransform:u===Ds&&/\b(transform|all)(,|$)/.test(n.transitionProperty)}}function ei(e,t){for(;e.lengthti(t)+ti(e[n]))))}function ti(e){return 1e3*Number(e.slice(0,-1).replace(",","."))}function ni(){return document.body.offsetHeight}const oi=new WeakMap,ri=new WeakMap,si={name:"TransitionGroup",props:w({},Ks,{tag:String,moveClass:String}),setup(e,{slots:t}){const n=qr(),o=to();let r,s;return Hn((()=>{if(!r.length)return;const t=e.moveClass||`${e.name||"v"}-move`;if(!function(e,t,n){const o=e.cloneNode();e._vtc&&e._vtc.forEach((e=>{e.split(/\s+/).forEach((e=>e&&o.classList.remove(e)))})),n.split(/\s+/).forEach((e=>e&&o.classList.add(e))),o.style.display="none";const r=1===t.nodeType?t:t.parentNode;r.appendChild(o);const{hasTransform:s}=Ys(o);return r.removeChild(o),s}(r[0].el,n.vnode.el,t))return;r.forEach(ii),r.forEach(li);const o=r.filter(ci);ni(),o.forEach((e=>{const n=e.el,o=n.style;qs(n,t),o.transform=o.webkitTransform=o.transitionDuration="";const r=n._moveCb=e=>{e&&e.target!==n||e&&!/transform$/.test(e.propertyName)||(n.removeEventListener("transitionend",r),n._moveCb=null,Js(n,t))};n.addEventListener("transitionend",r)}))})),()=>{const i=it(e),l=Ws(i),c=i.tag||or;r=s,s=t.default?ao(t.default()):[];for(let e=0;e{const t=e.props["onUpdate:modelValue"];return O(t)?e=>Z(t,e):t};function ui(e){e.target.composing=!0}function pi(e){const t=e.target;t.composing&&(t.composing=!1,function(e,t){const n=document.createEvent("HTMLEvents");n.initEvent("input",!0,!0),e.dispatchEvent(n)}(t))}const di={created(e,{modifiers:{lazy:t,trim:n,number:o}},r){e._assign=ai(r);const s=o||"number"===e.type;As(e,t?"change":"input",(t=>{if(t.target.composing)return;let o=e.value;n?o=o.trim():s&&(o=X(o)),e._assign(o)})),n&&As(e,"change",(()=>{e.value=e.value.trim()})),t||(As(e,"compositionstart",ui),As(e,"compositionend",pi),As(e,"change",pi))},mounted(e,{value:t}){e.value=null==t?"":t},beforeUpdate(e,{value:t,modifiers:{trim:n,number:o}},r){if(e._assign=ai(r),e.composing)return;if(document.activeElement===e){if(n&&e.value.trim()===t)return;if((o||"number"===e.type)&&X(e.value)===t)return}const s=null==t?"":t;e.value!==s&&(e.value=s)}},fi={created(e,t,n){e._assign=ai(n),As(e,"change",(()=>{const t=e._modelValue,n=yi(e),o=e.checked,r=e._assign;if(O(t)){const e=h(t,n),s=-1!==e;if(o&&!s)r(t.concat(n));else if(!o&&s){const n=[...t];n.splice(e,1),r(n)}}else if($(t)){const e=new Set(t);o?e.add(n):e.delete(n),r(e)}else r(_i(e,o))}))},mounted:hi,beforeUpdate(e,t,n){e._assign=ai(n),hi(e,t,n)}};function hi(e,{value:t,oldValue:n},o){e._modelValue=t,O(t)?e.checked=h(t,o.props.value)>-1:$(t)?e.checked=t.has(o.props.value):t!==n&&(e.checked=f(t,_i(e,!0)))}const mi={created(e,{value:t},n){e.checked=f(t,n.props.value),e._assign=ai(n),As(e,"change",(()=>{e._assign(yi(e))}))},beforeUpdate(e,{value:t,oldValue:n},o){e._assign=ai(o),t!==n&&(e.checked=f(t,o.props.value))}},gi={created(e,{value:t,modifiers:{number:n}},o){const r=$(t);As(e,"change",(()=>{const t=Array.prototype.filter.call(e.options,(e=>e.selected)).map((e=>n?X(yi(e)):yi(e)));e._assign(e.multiple?r?new Set(t):t:t[0])})),e._assign=ai(o)},mounted(e,{value:t}){vi(e,t)},beforeUpdate(e,t,n){e._assign=ai(n)},updated(e,{value:t}){vi(e,t)}};function vi(e,t){const n=e.multiple;if(!n||O(t)||$(t)){for(let o=0,r=e.options.length;o-1:r.selected=t.has(s);else if(f(yi(r),t))return void(e.selectedIndex=o)}n||(e.selectedIndex=-1)}}function yi(e){return"_value"in e?e._value:e.value}function _i(e,t){const n=t?"_trueValue":"_falseValue";return n in e?e[n]:t}const bi={created(e,t,n){xi(e,t,n,null,"created")},mounted(e,t,n){xi(e,t,n,null,"mounted")},beforeUpdate(e,t,n,o){xi(e,t,n,o,"beforeUpdate")},updated(e,t,n,o){xi(e,t,n,o,"updated")}};function xi(e,t,n,o,r){let s;switch(e.tagName){case"SELECT":s=gi;break;case"TEXTAREA":s=di;break;default:switch(n.props&&n.props.type){case"checkbox":s=fi;break;case"radio":s=mi;break;default:s=di}}const i=s[r];i&&i(e,t,n,o)}const Si=["ctrl","shift","alt","meta"],Ci={stop:e=>e.stopPropagation(),prevent:e=>e.preventDefault(),self:e=>e.target!==e.currentTarget,ctrl:e=>!e.ctrlKey,shift:e=>!e.shiftKey,alt:e=>!e.altKey,meta:e=>!e.metaKey,left:e=>"button"in e&&0!==e.button,middle:e=>"button"in e&&1!==e.button,right:e=>"button"in e&&2!==e.button,exact:(e,t)=>Si.some((n=>e[`${n}Key`]&&!t.includes(n)))},wi=(e,t)=>(n,...o)=>{for(let e=0;en=>{if(!("key"in n))return;const o=W(n.key);return t.some((e=>e===o||Ei[e]===o))?e(n):void 0},ki={beforeMount(e,{value:t},{transition:n}){e._vod="none"===e.style.display?"":e.style.display,n&&t?n.beforeEnter(e):Oi(e,t)},mounted(e,{value:t},{transition:n}){n&&t&&n.enter(e)},updated(e,{value:t,oldValue:n},{transition:o}){!t!=!n&&(o?t?(o.beforeEnter(e),Oi(e,!0),o.enter(e)):o.leave(e,(()=>{Oi(e,!1)})):Oi(e,t))},beforeUnmount(e,{value:t}){Oi(e,t)}};function Oi(e,t){e.style.display=t?e._vod:"none"}const Ni=w({patchProp:(e,t,n,o,s=!1,i,l,c,a)=>{switch(t){case"class":!function(e,t,n){if(null==t&&(t=""),n)e.setAttribute("class",t);else{const n=e._vtc;n&&(t=(t?[t,...n]:[...n]).join(" ")),e.className=t}}(e,o,s);break;case"style":!function(e,t,n){const o=e.style;if(n)if(V(n)){if(t!==n){const t=o.display;o.cssText=n,"_vod"in e&&(o.display=t)}}else{for(const e in n)ks(o,e,n[e]);if(t&&!V(t))for(const e in t)null==n[e]&&ks(o,e,"")}else e.removeAttribute("style")}(e,n,o);break;default:S(t)?C(t)||function(e,t,n,o,r=null){const s=e._vei||(e._vei={}),i=s[t];if(o&&i)i.value=o;else{const[n,l]=function(e){let t;if(Is.test(e)){let n;for(t={};n=e.match(Is);)e=e.slice(0,e.length-n[0].length),t[n[0].toLowerCase()]=!0}return[W(e.slice(2)),t]}(t);o?As(e,n,s[t]=function(e,t){const n=e=>{(e.timeStamp||Ls())>=n.attached-1&&Nt(function(e,t){if(O(t)){const n=e.stopImmediatePropagation;return e.stopImmediatePropagation=()=>{n.call(e),e._stopped=!0},t.map((e=>t=>!t._stopped&&e(t)))}return t}(e,n.value),t,5,[e])};return n.value=e,n.attached=Ps||(Vs.then(Fs),Ps=Ls()),n}(o,r),l):i&&(function(e,t,n,o){e.removeEventListener(t,n,o)}(e,n,i,l),s[t]=void 0)}}(e,t,0,o,l):function(e,t,n,o){return o?"innerHTML"===t||!!(t in e&&Ms.test(t)&&P(n)):"spellcheck"!==t&&"draggable"!==t&&("form"!==t&&(("list"!==t||"INPUT"!==e.tagName)&&(("type"!==t||"TEXTAREA"!==e.tagName)&&((!Ms.test(t)||!V(n))&&t in e))))}(e,t,o,s)?function(e,t,n,o,r,s,i){if("innerHTML"===t||"textContent"===t)return o&&i(o,r,s),void(e[t]=null==n?"":n);if("value"!==t||"PROGRESS"===e.tagName){if(""===n||null==n){const o=typeof e[t];if(""===n&&"boolean"===o)return void(e[t]=!0);if(null==n&&"string"===o)return e[t]="",void e.removeAttribute(t);if("number"===o)return e[t]=0,void e.removeAttribute(t)}try{e[t]=n}catch(e){}}else{e._value=n;const t=null==n?"":n;e.value!==t&&(e.value=t)}}(e,t,o,i,l,c,a):("true-value"===t?e._trueValue=o:"false-value"===t&&(e._falseValue=o),function(e,t,n,o){if(o&&t.startsWith("xlink:"))null==n?e.removeAttributeNS($s,t.slice(6,t.length)):e.setAttributeNS($s,t,n);else{const o=r(t);null==n||o&&!1===n?e.removeAttribute(t):e.setAttribute(t,o?"":n)}}(e,t,o,s))}},forcePatchProp:(e,t)=>"value"===t},Es);let $i,Li=!1;function Pi(){return $i||($i=Uo(Ni))}function Vi(){return $i=Li?$i:Do(Ni),Li=!0,$i}const Fi=(...e)=>{Pi().render(...e)},Ai=(...e)=>{Vi().hydrate(...e)},Ii=(...e)=>{const t=Pi().createApp(...e),{mount:n}=t;return t.mount=e=>{const o=Ri(e);if(!o)return;const r=t._component;P(r)||r.render||r.template||(r.template=o.innerHTML),o.innerHTML="";const s=n(o);return o instanceof Element&&(o.removeAttribute("v-cloak"),o.setAttribute("data-v-app","")),s},t},Mi=(...e)=>{const t=Vi().createApp(...e),{mount:n}=t;return t.mount=e=>{const t=Ri(e);if(t)return n(t,!0)},t};function Ri(e){return V(e)?document.querySelector(e):e}function Bi(e){throw e}function Ui(e,t,n,o){const r=new SyntaxError(String(e));return r.code=e,r.loc=t,r}const Di=Symbol(""),ji=Symbol(""),Hi=Symbol(""),zi=Symbol(""),Ki=Symbol(""),Wi=Symbol(""),Gi=Symbol(""),qi=Symbol(""),Ji=Symbol(""),Zi=Symbol(""),Qi=Symbol(""),Xi=Symbol(""),Yi=Symbol(""),el=Symbol(""),tl=Symbol(""),nl=Symbol(""),ol=Symbol(""),rl=Symbol(""),sl=Symbol(""),il=Symbol(""),ll=Symbol(""),cl=Symbol(""),al=Symbol(""),ul=Symbol(""),pl=Symbol(""),dl=Symbol(""),fl=Symbol(""),hl=Symbol(""),ml=Symbol(""),gl=Symbol(""),vl=Symbol(""),yl={[Di]:"Fragment",[ji]:"Teleport",[Hi]:"Suspense",[zi]:"KeepAlive",[Ki]:"BaseTransition",[Wi]:"openBlock",[Gi]:"createBlock",[qi]:"createVNode",[Ji]:"createCommentVNode",[Zi]:"createTextVNode",[Qi]:"createStaticVNode",[Xi]:"resolveComponent",[Yi]:"resolveDynamicComponent",[el]:"resolveDirective",[tl]:"withDirectives",[nl]:"renderList",[ol]:"renderSlot",[rl]:"createSlots",[sl]:"toDisplayString",[il]:"mergeProps",[ll]:"toHandlers",[cl]:"camelize",[al]:"capitalize",[ul]:"toHandlerKey",[pl]:"setBlockTracking",[dl]:"pushScopeId",[fl]:"popScopeId",[hl]:"withScopeId",[ml]:"withCtx",[gl]:"unref",[vl]:"isRef"},_l={source:"",start:{line:1,column:1,offset:0},end:{line:1,column:1,offset:0}};function bl(e,t,n,o,r,s,i,l=!1,c=!1,a=_l){return e&&(l?(e.helper(Wi),e.helper(Gi)):e.helper(qi),i&&e.helper(tl)),{type:13,tag:t,props:n,children:o,patchFlag:r,dynamicProps:s,directives:i,isBlock:l,disableTracking:c,loc:a}}function xl(e,t=_l){return{type:17,loc:t,elements:e}}function Sl(e,t=_l){return{type:15,loc:t,properties:e}}function Cl(e,t){return{type:16,loc:_l,key:V(e)?wl(e,!0):e,value:t}}function wl(e,t,n=_l,o=0){return{type:4,loc:n,content:e,isStatic:t,constType:t?3:o}}function El(e,t=_l){return{type:8,loc:t,children:e}}function Tl(e,t=[],n=_l){return{type:14,loc:n,callee:e,arguments:t}}function kl(e,t,n=!1,o=!1,r=_l){return{type:18,params:e,returns:t,newline:n,isSlot:o,loc:r}}function Ol(e,t,n,o=!0){return{type:19,test:e,consequent:t,alternate:n,newline:o,loc:_l}}const Nl=e=>4===e.type&&e.isStatic,$l=(e,t)=>e===t||e===W(t);function Ll(e){return $l(e,"Teleport")?ji:$l(e,"Suspense")?Hi:$l(e,"KeepAlive")?zi:$l(e,"BaseTransition")?Ki:void 0}const Pl=/^\d|[^\$\w]/,Vl=e=>!Pl.test(e),Fl=/^[A-Za-z_$][\w$]*(?:\s*\.\s*[A-Za-z_$][\w$]*|\[[^\]]+\])*$/,Al=e=>!!e&&Fl.test(e.trim());function Il(e,t,n){const o={source:e.source.substr(t,n),start:Ml(e.start,e.source,t),end:e.end};return null!=n&&(o.end=Ml(e.start,e.source,t+n)),o}function Ml(e,t,n=t.length){return Rl(w({},e),t,n)}function Rl(e,t,n=t.length){let o=0,r=-1;for(let e=0;e4===e.key.type&&e.key.content===n))}e||r.properties.unshift(t),o=r}else o=Tl(n.helper(il),[Sl([t]),r]);13===e.type?e.props=o:e.arguments[2]=o}function Gl(e,t){return`_${t}_${e.replace(/[^\w]/g,"_")}`}const ql=/&(gt|lt|amp|apos|quot);/g,Jl={gt:">",lt:"<",amp:"&",apos:"'",quot:'"'},Zl={delimiters:["{{","}}"],getNamespace:()=>0,getTextMode:()=>0,isVoidTag:b,isPreTag:b,isCustomElement:b,decodeEntities:e=>e.replace(ql,((e,t)=>Jl[t])),onError:Bi,comments:!1};function Ql(e,t,n){const o=dc(n),r=o?o.ns:0,s=[];for(;!yc(e,t,n);){const i=e.source;let l;if(0===t||1===t)if(!e.inVPre&&fc(i,e.options.delimiters[0]))l=lc(e,t);else if(0===t&&"<"===i[0])if(1===i.length)vc(e,5,1);else if("!"===i[1])fc(i,"\x3c!--")?l=ec(e):fc(i,""===i[2]){vc(e,14,2),hc(e,3);continue}if(/[a-z]/i.test(i[2])){vc(e,23),rc(e,1,o);continue}vc(e,12,2),l=tc(e)}else/[a-z]/i.test(i[1])?l=nc(e,n):"?"===i[1]?(vc(e,21,1),l=tc(e)):vc(e,12,1);if(l||(l=cc(e,t)),O(l))for(let e=0;e/.exec(e.source);if(o){o.index<=3&&vc(e,0),o[1]&&vc(e,10),n=e.source.slice(4,o.index);const t=e.source.slice(0,o.index);let r=1,s=0;for(;-1!==(s=t.indexOf("\x3c!--",r));)hc(e,s-r+1),s+4");return-1===r?(o=e.source.slice(n),hc(e,e.source.length)):(o=e.source.slice(n,r),hc(e,r+1)),{type:3,content:o,loc:pc(e,t)}}function nc(e,t){const n=e.inPre,o=e.inVPre,r=dc(t),s=rc(e,0,r),i=e.inPre&&!n,l=e.inVPre&&!o;if(s.isSelfClosing||e.options.isVoidTag(s.tag))return s;t.push(s);const c=e.options.getTextMode(s,r),a=Ql(e,c,t);if(t.pop(),s.children=a,_c(e.source,s.tag))rc(e,1,r);else if(vc(e,24,0,s.loc.start),0===e.source.length&&"script"===s.tag.toLowerCase()){const t=a[0];t&&fc(t.loc.source,"\x3c!--")&&vc(e,8)}return s.loc=pc(e,s.loc.start),i&&(e.inPre=!1),l&&(e.inVPre=!1),s}const oc=n("if,else,else-if,for,slot");function rc(e,t,n){const o=uc(e),r=/^<\/?([a-z][^\t\r\n\f />]*)/i.exec(e.source),s=r[1],i=e.options.getNamespace(s,n);hc(e,r[0].length),mc(e);const l=uc(e),c=e.source;let a=sc(e,t);e.options.isPreTag(s)&&(e.inPre=!0),!e.inVPre&&a.some((e=>7===e.type&&"pre"===e.name))&&(e.inVPre=!0,w(e,l),e.source=c,a=sc(e,t).filter((e=>"v-pre"!==e.name)));let u=!1;0===e.source.length?vc(e,9):(u=fc(e.source,"/>"),1===t&&u&&vc(e,4),hc(e,u?2:1));let p=0;const d=e.options;if(!e.inVPre&&!d.isCustomElement(s)){const e=a.some((e=>7===e.type&&"is"===e.name));d.isNativeTag&&!e?d.isNativeTag(s)||(p=1):(e||Ll(s)||d.isBuiltInComponent&&d.isBuiltInComponent(s)||/^[A-Z]/.test(s)||"component"===s)&&(p=1),"slot"===s?p=2:"template"===s&&a.some((e=>7===e.type&&oc(e.name)))&&(p=3)}return{type:1,ns:i,tag:s,tagType:p,props:a,isSelfClosing:u,children:[],loc:pc(e,o),codegenNode:void 0}}function sc(e,t){const n=[],o=new Set;for(;e.source.length>0&&!fc(e.source,">")&&!fc(e.source,"/>");){if(fc(e.source,"/")){vc(e,22),hc(e,1),mc(e);continue}1===t&&vc(e,3);const r=ic(e,o);0===t&&n.push(r),/^[^\t\r\n\f />]/.test(e.source)&&vc(e,15),mc(e)}return n}function ic(e,t){const n=uc(e),o=/^[^\t\r\n\f />][^\t\r\n\f />=]*/.exec(e.source)[0];t.has(o)&&vc(e,2),t.add(o),"="===o[0]&&vc(e,19);{const t=/["'<]/g;let n;for(;n=t.exec(o);)vc(e,17,n.index)}let r;hc(e,o.length),/^[\t\r\n\f ]*=/.test(e.source)&&(mc(e),hc(e,1),mc(e),r=function(e){const t=uc(e);let n;const o=e.source[0],r='"'===o||"'"===o;if(r){hc(e,1);const t=e.source.indexOf(o);-1===t?n=ac(e,e.source.length,4):(n=ac(e,t,4),hc(e,1))}else{const t=/^[^\t\r\n\f >]+/.exec(e.source);if(!t)return;const o=/["'<=`]/g;let r;for(;r=o.exec(t[0]);)vc(e,18,r.index);n=ac(e,t[0].length,4)}return{content:n,isQuoted:r,loc:pc(e,t)}}(e),r||vc(e,13));const s=pc(e,n);if(!e.inVPre&&/^(v-|:|@|#)/.test(o)){const t=/(?:^v-([a-z0-9-]+))?(?:(?::|^@|^#)(\[[^\]]+\]|[^\.]+))?(.+)?$/i.exec(o),i=t[1]||(fc(o,":")?"bind":fc(o,"@")?"on":"slot");let l;if(t[2]){const r="slot"===i,s=o.indexOf(t[2]),c=pc(e,gc(e,n,s),gc(e,n,s+t[2].length+(r&&t[3]||"").length));let a=t[2],u=!0;a.startsWith("[")?(u=!1,a.endsWith("]")||vc(e,26),a=a.substr(1,a.length-2)):r&&(a+=t[3]||""),l={type:4,content:a,isStatic:u,constType:u?3:0,loc:c}}if(r&&r.isQuoted){const e=r.loc;e.start.offset++,e.start.column++,e.end=Ml(e.start,r.content),e.source=e.source.slice(1,-1)}return{type:7,name:i,exp:r&&{type:4,content:r.content,isStatic:!1,constType:0,loc:r.loc},arg:l,modifiers:t[3]?t[3].substr(1).split("."):[],loc:s}}return{type:6,name:o,value:r&&{type:2,content:r.content,loc:r.loc},loc:s}}function lc(e,t){const[n,o]=e.options.delimiters,r=e.source.indexOf(o,n.length);if(-1===r)return void vc(e,25);const s=uc(e);hc(e,n.length);const i=uc(e),l=uc(e),c=r-n.length,a=e.source.slice(0,c),u=ac(e,c,t),p=u.trim(),d=u.indexOf(p);return d>0&&Rl(i,a,d),Rl(l,a,c-(u.length-p.length-d)),hc(e,o.length),{type:5,content:{type:4,isStatic:!1,constType:0,content:p,loc:pc(e,i,l)},loc:pc(e,s)}}function cc(e,t){const n=["<",e.options.delimiters[0]];3===t&&n.push("]]>");let o=e.source.length;for(let t=0;tr&&(o=r)}const r=uc(e);return{type:2,content:ac(e,o,t),loc:pc(e,r)}}function ac(e,t,n){const o=e.source.slice(0,t);return hc(e,t),2===n||3===n||-1===o.indexOf("&")?o:e.options.decodeEntities(o,4===n)}function uc(e){const{column:t,line:n,offset:o}=e;return{column:t,line:n,offset:o}}function pc(e,t,n){return{start:t,end:n=n||uc(e),source:e.originalSource.slice(t.offset,n.offset)}}function dc(e){return e[e.length-1]}function fc(e,t){return e.startsWith(t)}function hc(e,t){const{source:n}=e;Rl(e,n,t),e.source=n.slice(t)}function mc(e){const t=/^[\t\r\n\f ]+/.exec(e.source);t&&hc(e,t[0].length)}function gc(e,t,n){return Ml(t,e.originalSource.slice(t.offset,n),n)}function vc(e,t,n,o=uc(e)){n&&(o.offset+=n,o.column+=n),e.options.onError(Ui(t,{start:o,end:o,source:""}))}function yc(e,t,n){const o=e.source;switch(t){case 0:if(fc(o,"=0;--e)if(_c(o,n[e].tag))return!0;break;case 1:case 2:{const e=dc(n);if(e&&_c(o,e.tag))return!0;break}case 3:if(fc(o,"]]>"))return!0}return!o}function _c(e,t){return fc(e,"]/.test(e[2+t.length]||">")}function bc(e,t){Sc(e,t,xc(e,e.children[0]))}function xc(e,t){const{children:n}=e;return 1===n.length&&1===t.type&&!Kl(t)}function Sc(e,t,n=!1){let o=!1,r=!0;const{children:s}=e;for(let e=0;e0){if(e<3&&(r=!1),e>=2){i.codegenNode.patchFlag="-1",i.codegenNode=t.hoist(i.codegenNode),o=!0;continue}}else{const e=i.codegenNode;if(13===e.type){const n=Tc(e);if((!n||512===n||1===n)&&wc(i,t)>=2){const n=Ec(i);n&&(e.props=t.hoist(n))}}}}else if(12===i.type){const e=Cc(i.content,t);e>0&&(e<3&&(r=!1),e>=2&&(i.codegenNode=t.hoist(i.codegenNode),o=!0))}if(1===i.type)Sc(i,t);else if(11===i.type)Sc(i,t,1===i.children.length);else if(9===i.type)for(let e=0;e1)for(let r=0;r(x.helpers.add(e),e),helperString:e=>`_${yl[x.helper(e)]}`,replaceNode(e){x.parent.children[x.childIndex]=x.currentNode=e},removeNode(e){const t=x.parent.children,n=e?t.indexOf(e):x.currentNode?x.childIndex:-1;e&&e!==x.currentNode?x.childIndex>n&&(x.childIndex--,x.onNodeRemoved()):(x.currentNode=null,x.onNodeRemoved()),x.parent.children.splice(n,1)},onNodeRemoved:()=>{},addIdentifiers(e){},removeIdentifiers(e){},hoist(e){x.hoists.push(e);const t=wl(`_hoisted_${x.hoists.length}`,!1,e.loc,2);return t.hoisted=e,t},cache:(e,t=!1)=>function(e,t,n=!1){return{type:20,index:e,value:t,isVNode:n,loc:_l}}(++x.cached,e,t)};return x}(e,t);Oc(e,n),t.hoistStatic&&bc(e,n),t.ssr||function(e,t){const{helper:n}=t,{children:o}=e;if(1===o.length){const t=o[0];if(xc(e,t)&&t.codegenNode){const o=t.codegenNode;13===o.type&&(o.isBlock=!0,n(Wi),n(Gi)),e.codegenNode=o}else e.codegenNode=t}else if(o.length>1){let o=64;e.codegenNode=bl(t,n(Di),void 0,e.children,o+"",void 0,void 0,!0)}}(e,n),e.helpers=[...n.helpers],e.components=[...n.components],e.directives=[...n.directives],e.imports=n.imports,e.hoists=n.hoists,e.temps=n.temps,e.cached=n.cached}function Oc(e,t){t.currentNode=e;const{nodeTransforms:n}=t,o=[];for(let r=0;r{n--};for(;nt===e:t=>e.test(t);return(e,o)=>{if(1===e.type){const{props:r}=e;if(3===e.tagType&&r.some(Hl))return;const s=[];for(let i=0;i3||!1;t.push("["),n&&t.indent(),Vc(e,t,n),n&&t.deindent(),t.push("]")}function Vc(e,t,n=!1,o=!0){const{push:r,newline:s}=t;for(let i=0;ie||"null"))}([s,i,l,c,a]),t),n(")"),p&&n(")"),u&&(n(", "),Fc(u,t),n(")"))}(e,t);break;case 14:!function(e,t){const{push:n,helper:o,pure:r}=t,s=V(e.callee)?e.callee:o(e.callee);r&&n($c),n(s+"(",e),Vc(e.arguments,t),n(")")}(e,t);break;case 15:!function(e,t){const{push:n,indent:o,deindent:r,newline:s}=t,{properties:i}=e;if(!i.length)return void n("{}",e);const l=i.length>1||!1;n(l?"{":"{ "),l&&o();for(let e=0;e "),(u||a)&&(n("{"),o()),c?(u&&n("return "),O(c)?Pc(c,t):Fc(c,t)):a&&Fc(a,t),(u||a)&&(r(),n("}")),p&&n(")")}(e,t);break;case 19:!function(e,t){const{test:n,consequent:o,alternate:r,newline:s}=e,{push:i,indent:l,deindent:c,newline:a}=t;if(4===n.type){const e=!Vl(n.content);e&&i("("),Ac(n,t),e&&i(")")}else i("("),Fc(n,t),i(")");s&&l(),t.indentLevel++,s||i(" "),i("? "),Fc(o,t),t.indentLevel--,s&&a(),s||i(" "),i(": ");const u=19===r.type;u||t.indentLevel++,Fc(r,t),u||t.indentLevel--,s&&c(!0)}(e,t);break;case 20:!function(e,t){const{push:n,helper:o,indent:r,deindent:s,newline:i}=t;n(`_cache[${e.index}] || (`),e.isVNode&&(r(),n(`${o(pl)}(-1),`),i()),n(`_cache[${e.index}] = `),Fc(e.value,t),e.isVNode&&(n(","),i(),n(`${o(pl)}(1),`),i(),n(`_cache[${e.index}]`),s()),n(")")}(e,t)}}function Ac(e,t){const{content:n,isStatic:o}=e;t.push(o?JSON.stringify(n):n,e)}function Ic(e,t){for(let n=0;nfunction(e,t,n,o){if(!("else"===t.name||t.exp&&t.exp.content.trim())){const o=t.exp?t.exp.loc:e.loc;n.onError(Ui(27,t.loc)),t.exp=wl("true",!1,o)}if("if"===t.name){const r=Bc(e,t),s={type:9,loc:e.loc,branches:[r]};if(n.replaceNode(s),o)return o(s,r,!0)}else{const r=n.parent.children;let s=r.indexOf(e);for(;s-- >=-1;){const i=r[s];if(!i||2!==i.type||i.content.trim().length){if(i&&9===i.type){n.removeNode();const r=Bc(e,t);i.branches.push(r);const s=o&&o(i,r,!1);Oc(r,n),s&&s(),n.currentNode=null}else n.onError(Ui(29,e.loc));break}n.removeNode(i)}}}(e,t,n,((e,t,o)=>{const r=n.parent.children;let s=r.indexOf(e),i=0;for(;s-- >=0;){const e=r[s];e&&9===e.type&&(i+=e.branches.length)}return()=>{o?e.codegenNode=Uc(t,i,n):(function(e){for(;;)if(19===e.type){if(19!==e.alternate.type)return e;e=e.alternate}else 20===e.type&&(e=e.value)}(e.codegenNode)).alternate=Uc(t,i+e.branches.length-1,n)}}))));function Bc(e,t){return{type:10,loc:e.loc,condition:"else"===t.name?void 0:t.exp,children:3!==e.tagType||Bl(e,"for")?[e]:e.children,userKey:Ul(e,"key")}}function Uc(e,t,n){return e.condition?Ol(e.condition,Dc(e,t,n),Tl(n.helper(Ji),['""',"true"])):Dc(e,t,n)}function Dc(e,t,n){const{helper:o}=n,r=Cl("key",wl(`${t}`,!1,_l,2)),{children:s}=e,i=s[0];if(1!==s.length||1!==i.type){if(1===s.length&&11===i.type){const e=i.codegenNode;return Wl(e,r,n),e}return bl(n,o(Di),Sl([r]),s,"64",void 0,void 0,!0,!1,e.loc)}{const e=i.codegenNode;return 13===e.type&&(e.isBlock=!0,o(Wi),o(Gi)),Wl(e,r,n),e}}const jc=Nc("for",((e,t,n)=>{const{helper:o}=n;return function(e,t,n,o){if(!t.exp)return void n.onError(Ui(30,t.loc));const r=Wc(t.exp);if(!r)return void n.onError(Ui(31,t.loc));const{addIdentifiers:s,removeIdentifiers:i,scopes:l}=n,{source:c,value:a,key:u,index:p}=r,d={type:11,loc:t.loc,source:c,valueAlias:a,keyAlias:u,objectIndexAlias:p,parseResult:r,children:zl(e)?e.children:[e]};n.replaceNode(d),l.vFor++;const f=o&&o(d);return()=>{l.vFor--,f&&f()}}(e,t,n,(t=>{const r=Tl(o(nl),[t.source]),s=Ul(e,"key"),i=s?Cl("key",6===s.type?wl(s.value.content,!0):s.exp):null,l=4===t.source.type&&t.source.constType>0,c=l?64:s?128:256;return t.codegenNode=bl(n,o(Di),void 0,r,c+"",void 0,void 0,!0,!l,e.loc),()=>{let s;const c=zl(e),{children:a}=t,u=1!==a.length||1!==a[0].type,p=Kl(e)?e:c&&1===e.children.length&&Kl(e.children[0])?e.children[0]:null;p?(s=p.codegenNode,c&&i&&Wl(s,i,n)):u?s=bl(n,o(Di),i?Sl([i]):void 0,e.children,"64",void 0,void 0,!0):(s=a[0].codegenNode,c&&i&&Wl(s,i,n),s.isBlock=!l,s.isBlock?(o(Wi),o(Gi)):o(qi)),r.arguments.push(kl(qc(t.parseResult),s,!0))}}))})),Hc=/([\s\S]*?)\s+(?:in|of)\s+([\s\S]*)/,zc=/,([^,\}\]]*)(?:,([^,\}\]]*))?$/,Kc=/^\(|\)$/g;function Wc(e,t){const n=e.loc,o=e.content,r=o.match(Hc);if(!r)return;const[,s,i]=r,l={source:Gc(n,i.trim(),o.indexOf(i,s.length)),value:void 0,key:void 0,index:void 0};let c=s.trim().replace(Kc,"").trim();const a=s.indexOf(c),u=c.match(zc);if(u){c=c.replace(zc,"").trim();const e=u[1].trim();let t;if(e&&(t=o.indexOf(e,a+c.length),l.key=Gc(n,e,t)),u[2]){const r=u[2].trim();r&&(l.index=Gc(n,r,o.indexOf(r,l.key?t+e.length:a+c.length)))}}return c&&(l.value=Gc(n,c,a)),l}function Gc(e,t,n){return wl(t,!1,Il(e,n,t.length))}function qc({value:e,key:t,index:n}){const o=[];return e&&o.push(e),t&&(e||o.push(wl("_",!1)),o.push(t)),n&&(t||(e||o.push(wl("_",!1)),o.push(wl("__",!1))),o.push(n)),o}const Jc=wl("undefined",!1),Zc=(e,t)=>{if(1===e.type&&(1===e.tagType||3===e.tagType)){const n=Bl(e,"slot");if(n)return n.exp,t.scopes.vSlot++,()=>{t.scopes.vSlot--}}},Qc=(e,t,n)=>kl(e,t,!1,!0,t.length?t[0].loc:n);function Xc(e,t,n=Qc){t.helper(ml);const{children:o,loc:r}=e,s=[],i=[],l=(e,t)=>Cl("default",n(e,t,r));let c=t.scopes.vSlot>0||t.scopes.vFor>0;const a=Bl(e,"slot",!0);if(a){const{arg:e,exp:t}=a;e&&!Nl(e)&&(c=!0),s.push(Cl(e||wl("default",!0),n(t,o,r)))}let u=!1,p=!1;const d=[],f=new Set;for(let e=0;e{if(1===e.type&&(0===e.tagType||1===e.tagType))return function(){const{tag:n,props:o}=e,r=1===e.tagType,s=r?function(e,t,n=!1){const{tag:o}=e,r="component"===e.tag?Ul(e,"is"):Bl(e,"is");if(r){const e=6===r.type?r.value&&wl(r.value.content,!0):r.exp;if(e)return Tl(t.helper(Yi),[e])}const s=Ll(o)||t.isBuiltInComponent(o);return s?(n||t.helper(s),s):(t.helper(Xi),t.components.add(o),Gl(o,"component"))}(e,t):`"${n}"`;let i,l,c,a,u,p,d=0,f=A(s)&&s.callee===Yi||s===ji||s===Hi||!r&&("svg"===n||"foreignObject"===n||Ul(e,"key",!0));if(o.length>0){const n=oa(e,t);i=n.props,d=n.patchFlag,u=n.dynamicPropNames;const o=n.directives;p=o&&o.length?xl(o.map((e=>function(e,t){const n=[],o=ta.get(e);o?n.push(t.helperString(o)):(t.helper(el),t.directives.add(e.name),n.push(Gl(e.name,"directive")));const{loc:r}=e;if(e.exp&&n.push(e.exp),e.arg&&(e.exp||n.push("void 0"),n.push(e.arg)),Object.keys(e.modifiers).length){e.arg||(e.exp||n.push("void 0"),n.push("void 0"));const t=wl("true",!1,r);n.push(Sl(e.modifiers.map((e=>Cl(e,t))),r))}return xl(n,e.loc)}(e,t)))):void 0}if(e.children.length>0)if(s===zi&&(f=!0,d|=1024),r&&s!==ji&&s!==zi){const{slots:n,hasDynamicSlots:o}=Xc(e,t);l=n,o&&(d|=1024)}else if(1===e.children.length&&s!==ji){const n=e.children[0],o=n.type,r=5===o||8===o;r&&0===Cc(n,t)&&(d|=1),l=r||2===o?n:e.children}else l=e.children;0!==d&&(c=String(d),u&&u.length&&(a=function(e){let t="[";for(let n=0,o=e.length;n{if(Nl(e)){const o=e.content,r=S(o);if(i||!r||"onclick"===o.toLowerCase()||"onUpdate:modelValue"===o||D(o)||(h=!0),r&&D(o)&&(g=!0),20===n.type||(4===n.type||8===n.type)&&Cc(n,t)>0)return;"ref"===o?p=!0:"class"!==o||i?"style"!==o||i?"key"===o||v.includes(o)||v.push(o):f=!0:d=!0}else m=!0};for(let u=0;u1?Tl(t.helper(il),c,s):c[0]):l.length&&(_=Sl(ra(l),s)),m?u|=16:(d&&(u|=2),f&&(u|=4),v.length&&(u|=8),h&&(u|=32)),0!==u&&32!==u||!(p||g||a.length>0)||(u|=512),{props:_,directives:a,patchFlag:u,dynamicPropNames:v}}function ra(e){const t=new Map,n=[];for(let o=0;o{const t=Object.create(null);return e=>t[e]||(t[e]=(e=>e.replace(ia,((e,t)=>t?t.toUpperCase():"")))(e))})(),ca=(e,t)=>{if(Kl(e)){const{children:n,loc:o}=e,{slotName:r,slotProps:s}=function(e,t){let n,o='"default"';const r=[];for(let t=0;t0){const{props:o,directives:s}=oa(e,t,r);n=o,s.length&&t.onError(Ui(35,s[0].loc))}return{slotName:o,slotProps:n}}(e,t),i=[t.prefixIdentifiers?"_ctx.$slots":"$slots",r];s&&i.push(s),n.length&&(s||i.push("{}"),i.push(kl([],n,!1,!1,o))),e.codegenNode=Tl(t.helper(ol),i,o)}},aa=/^\s*([\w$_]+|\([^)]*?\))\s*=>|^\s*function(?:\s+[\w$]+)?\s*\(/,ua=(e,t,n,o)=>{const{loc:r,modifiers:s,arg:i}=e;let l;if(e.exp||s.length||n.onError(Ui(34,r)),4===i.type)if(i.isStatic){const e=i.content;l=wl(q(z(e)),!0,i.loc)}else l=El([`${n.helperString(ul)}(`,i,")"]);else l=i,l.children.unshift(`${n.helperString(ul)}(`),l.children.push(")");let c=e.exp;c&&!c.content.trim()&&(c=void 0);let a=n.cacheHandlers&&!c;if(c){const e=Al(c.content),t=!(e||aa.test(c.content)),n=c.content.includes(";");(t||a&&e)&&(c=El([`${t?"$event":"(...args)"} => ${n?"{":"("}`,c,n?"}":")"]))}let u={props:[Cl(l,c||wl("() => {}",!1,r))]};return o&&(u=o(u)),a&&(u.props[0].value=n.cache(u.props[0].value)),u},pa=(e,t,n)=>{const{exp:o,modifiers:r,loc:s}=e,i=e.arg;return 4!==i.type?(i.children.unshift("("),i.children.push(') || ""')):i.isStatic||(i.content=`${i.content} || ""`),r.includes("camel")&&(4===i.type?i.isStatic?i.content=z(i.content):i.content=`${n.helperString(cl)}(${i.content})`:(i.children.unshift(`${n.helperString(cl)}(`),i.children.push(")"))),!o||4===o.type&&!o.content.trim()?(n.onError(Ui(33,s)),{props:[Cl(i,wl("",!0,s))]}):{props:[Cl(i,o)]}},da=(e,t)=>{if(0===e.type||1===e.type||11===e.type||10===e.type)return()=>{const n=e.children;let o,r=!1;for(let e=0;e{if(1===e.type&&Bl(e,"once",!0)){if(fa.has(e))return;return fa.add(e),t.helper(pl),()=>{const e=t.currentNode;e.codegenNode&&(e.codegenNode=t.cache(e.codegenNode,!0))}}},ma=(e,t,n)=>{const{exp:o,arg:r}=e;if(!o)return n.onError(Ui(40,e.loc)),ga();const s=o.loc.source,i=4===o.type?o.content:s;if(n.bindingMetadata[s],!Al(i))return n.onError(Ui(41,o.loc)),ga();const l=r||wl("modelValue",!0),c=r?Nl(r)?`onUpdate:${r.content}`:El(['"onUpdate:" + ',r]):"onUpdate:modelValue";let a;a=El([(n.isTS?"($event: any)":"$event")+" => (",o," = $event)"]);const u=[Cl(l,e.exp),Cl(c,a)];if(e.modifiers.length&&1===t.tagType){const t=e.modifiers.map((e=>(Vl(e)?e:JSON.stringify(e))+": true")).join(", "),n=r?Nl(r)?`${r.content}Modifiers`:El([r,' + "Modifiers"']):"modelModifiers";u.push(Cl(n,wl(`{ ${t} }`,!1,e.loc,2)))}return ga(u)};function ga(e=[]){return{props:e}}function va(e,t={}){const n=t.onError||Bi,o="module"===t.mode;!0===t.prefixIdentifiers?n(Ui(45)):o&&n(Ui(46)),t.cacheHandlers&&n(Ui(47)),t.scopeId&&!o&&n(Ui(48));const r=V(e)?function(e,t={}){const n=function(e,t){const n=w({},Zl);for(const e in t)n[e]=t[e]||Zl[e];return{options:n,column:1,line:1,offset:0,originalSource:e,source:e,inPre:!1,inVPre:!1}}(e,t),o=uc(n);return function(e,t=_l){return{type:0,children:e,helpers:[],components:[],directives:[],hoists:[],imports:[],cached:0,temps:0,codegenNode:void 0,loc:t}}(Ql(n,0,[]),pc(n,o))}(e,t):e,[s,i]=[[ha,Rc,jc,ca,na,Zc,da],{on:ua,bind:pa,model:ma}];return kc(r,w({},t,{prefixIdentifiers:!1,nodeTransforms:[...s,...t.nodeTransforms||[]],directiveTransforms:w({},i,t.directiveTransforms||{})})),function(e,t={}){const n=function(e,{mode:t="function",prefixIdentifiers:n="module"===t,sourceMap:o=!1,filename:r="template.vue.html",scopeId:s=null,optimizeImports:i=!1,runtimeGlobalName:l="Vue",runtimeModuleName:c="vue",ssr:a=!1}){const u={mode:t,prefixIdentifiers:n,sourceMap:o,filename:r,scopeId:s,optimizeImports:i,runtimeGlobalName:l,runtimeModuleName:c,ssr:a,source:e.loc.source,code:"",column:1,line:1,offset:0,indentLevel:0,pure:!1,map:void 0,helper:e=>`_${yl[e]}`,push(e,t){u.code+=e},indent(){p(++u.indentLevel)},deindent(e=!1){e?--u.indentLevel:p(--u.indentLevel)},newline(){p(u.indentLevel)}};function p(e){u.push("\n"+" ".repeat(e))}return u}(e,t);t.onContextCreated&&t.onContextCreated(n);const{mode:o,push:r,prefixIdentifiers:s,indent:i,deindent:l,newline:c,scopeId:a,ssr:u}=n,p=e.helpers.length>0,d=!s&&"module"!==o;if(function(e,t){const{ssr:n,prefixIdentifiers:o,push:r,newline:s,runtimeModuleName:i,runtimeGlobalName:l}=t,c=l,a=e=>`${yl[e]}: _${yl[e]}`;e.helpers.length>0&&(r(`const _Vue = ${c}\n`),e.hoists.length)&&r(`const { ${[qi,Ji,Zi,Qi].filter((t=>e.helpers.includes(t))).map(a).join(", ")} } = _Vue\n`),function(e,t){if(!e.length)return;t.pure=!0;const{push:n,newline:o,helper:r,scopeId:s,mode:i}=t;o(),e.forEach(((e,r)=>{e&&(n(`const _hoisted_${r+1} = `),Fc(e,t),o())})),t.pure=!1}(e.hoists,t),s(),r("return ")}(e,n),r(`function ${u?"ssrRender":"render"}(${(u?["_ctx","_push","_parent","_attrs"]:["_ctx","_cache"]).join(", ")}) {`),i(),d&&(r("with (_ctx) {"),i(),p&&(r(`const { ${e.helpers.map((e=>`${yl[e]}: _${yl[e]}`)).join(", ")} } = _Vue`),r("\n"),c())),e.components.length&&(Lc(e.components,"component",n),(e.directives.length||e.temps>0)&&c()),e.directives.length&&(Lc(e.directives,"directive",n),e.temps>0&&c()),e.temps>0){r("let ");for(let t=0;t0?", ":""}_temp${t}`)}return(e.components.length||e.directives.length||e.temps)&&(r("\n"),c()),u||r("return "),e.codegenNode?Fc(e.codegenNode,n):r("null"),d&&(l(),r("}")),l(),r("}"),{ast:e,code:n.code,preamble:"",map:n.map?n.map.toJSON():void 0}}(r,w({},t,{prefixIdentifiers:!1}))}const ya=Symbol(""),_a=Symbol(""),ba=Symbol(""),xa=Symbol(""),Sa=Symbol(""),Ca=Symbol(""),wa=Symbol(""),Ea=Symbol(""),Ta=Symbol(""),ka=Symbol("");var Oa;let Na;Oa={[ya]:"vModelRadio",[_a]:"vModelCheckbox",[ba]:"vModelText",[xa]:"vModelSelect",[Sa]:"vModelDynamic",[Ca]:"withModifiers",[wa]:"withKeys",[Ea]:"vShow",[Ta]:"Transition",[ka]:"TransitionGroup"},Object.getOwnPropertySymbols(Oa).forEach((e=>{yl[e]=Oa[e]}));const $a=n("style,iframe,script,noscript",!0),La={isVoidTag:d,isNativeTag:e=>u(e)||p(e),isPreTag:e=>"pre"===e,decodeEntities:function(e){return(Na||(Na=document.createElement("div"))).innerHTML=e,Na.textContent},isBuiltInComponent:e=>$l(e,"Transition")?Ta:$l(e,"TransitionGroup")?ka:void 0,getNamespace(e,t){let n=t?t.ns:0;if(t&&2===n)if("annotation-xml"===t.tag){if("svg"===e)return 1;t.props.some((e=>6===e.type&&"encoding"===e.name&&null!=e.value&&("text/html"===e.value.content||"application/xhtml+xml"===e.value.content)))&&(n=0)}else/^m(?:[ions]|text)$/.test(t.tag)&&"mglyph"!==e&&"malignmark"!==e&&(n=0);else t&&1===n&&("foreignObject"!==t.tag&&"desc"!==t.tag&&"title"!==t.tag||(n=0));if(0===n){if("svg"===e)return 1;if("math"===e)return 2}return n},getTextMode({tag:e,ns:t}){if(0===t){if("textarea"===e||"title"===e)return 1;if($a(e))return 2}return 0}},Pa=(e,t)=>{const n=c(e);return wl(JSON.stringify(n),!1,t,3)};function Va(e,t){return Ui(e,t)}const Fa=n("passive,once,capture"),Aa=n("stop,prevent,self,ctrl,shift,alt,meta,exact,middle"),Ia=n("left,right"),Ma=n("onkeyup,onkeydown,onkeypress",!0),Ra=(e,t)=>Nl(e)&&"onclick"===e.content.toLowerCase()?wl(t,!0):4!==e.type?El(["(",e,`) === "onClick" ? "${t}" : (`,e,")"]):e,Ba=(e,t)=>{1!==e.type||0!==e.tagType||"script"!==e.tag&&"style"!==e.tag||(t.onError(Va(59,e.loc)),t.removeNode())},Ua=[e=>{1===e.type&&e.props.forEach(((t,n)=>{6===t.type&&"style"===t.name&&t.value&&(e.props[n]={type:7,name:"bind",arg:wl("style",!0,t.loc),exp:Pa(t.value.content,t.loc),modifiers:[],loc:t.loc})}))}],Da={cloak:()=>({props:[]}),html:(e,t,n)=>{const{exp:o,loc:r}=e;return o||n.onError(Va(49,r)),t.children.length&&(n.onError(Va(50,r)),t.children.length=0),{props:[Cl(wl("innerHTML",!0,r),o||wl("",!0))]}},text:(e,t,n)=>{const{exp:o,loc:r}=e;return o||n.onError(Va(51,r)),t.children.length&&(n.onError(Va(52,r)),t.children.length=0),{props:[Cl(wl("textContent",!0),o?Tl(n.helperString(sl),[o],r):wl("",!0))]}},model:(e,t,n)=>{const o=ma(e,t,n);if(!o.props.length||1===t.tagType)return o;e.arg&&n.onError(Va(54,e.arg.loc));const{tag:r}=t,s=n.isCustomElement(r);if("input"===r||"textarea"===r||"select"===r||s){let i=ba,l=!1;if("input"===r||s){const o=Ul(t,"type");if(o){if(7===o.type)i=Sa;else if(o.value)switch(o.value.content){case"radio":i=ya;break;case"checkbox":i=_a;break;case"file":l=!0,n.onError(Va(55,e.loc))}}else(function(e){return e.props.some((e=>!(7!==e.type||"bind"!==e.name||e.arg&&4===e.arg.type&&e.arg.isStatic)))})(t)&&(i=Sa)}else"select"===r&&(i=xa);l||(o.needRuntime=n.helper(i))}else n.onError(Va(53,e.loc));return o.props=o.props.filter((e=>!(4===e.key.type&&"modelValue"===e.key.content))),o},on:(e,t,n)=>ua(e,0,n,(t=>{const{modifiers:o}=e;if(!o.length)return t;let{key:r,value:s}=t.props[0];const{keyModifiers:i,nonKeyModifiers:l,eventOptionModifiers:c}=((e,t)=>{const n=[],o=[],r=[];for(let s=0;s{const{exp:o,loc:r}=e;return o||n.onError(Va(57,r)),{props:[],needRuntime:n.helper(Ea)}}},ja=Object.create(null);ts((function(e,n){if(!V(e)){if(!e.nodeType)return _;e=e.innerHTML}const o=e,r=ja[o];if(r)return r;if("#"===e[0]){const t=document.querySelector(e);e=t?t.innerHTML:""}const{code:s}=function(e,t={}){return va(e,w({},La,t,{nodeTransforms:[Ba,...Ua,...t.nodeTransforms||[]],directiveTransforms:w({},Da,t.directiveTransforms||{}),transformHoist:null}))}(e,w({hoistStatic:!0,onError(e){throw e}},n)),i=new Function("Vue",s)(t);return i._rc=!0,ja[o]=i}));var Ha,za,Ka=/^(\d+)?(m|s|ms)?$/i,Wa=function(e){var t;void 0===e&&(e="");var n=Ka.exec(e);if(null!==n&&n.length>=3){var o=parseFloat(n[1]);switch((null!==(t=n[2])&&void 0!==t?t:"ms").toLowerCase()){case"m":return 6e4*o;case"s":return 1e3*o;case"ms":return o}}return null};!function(e){e.Single="single",e.Double="double",e.Hold="hold",e.Press="press",e.Release="release"}(Ha||(Ha={})),function(e){e.Once="once",e.Throttle="throttle",e.Debounce="debounce"}(za||(za={}));var Ga=function(e,t){return Object.keys(e).filter((function(n){return Object(e)[n]===t})).length>0},qa=300,Ja={mounted:function(e,t){var n=function(e){var t,n={behavior:Ha.Single,modifier:null,time:null,argument:null,once:!1,dispatch:function(){}};for(var o in e.modifiers){var r=o.split(":");void 0!==r[1]&&(n.argument=r[1]),void 0===(t=r[0])&&(t=""),Ka.test(t)?n.time=Wa(r[0]):Ga(Ha,r[0])?n.behavior=r[0]:Ga(za,r[0])&&(n.modifier=r[0])}return void 0!==e.arg&&(n.argument=e.arg),"function"==typeof e.value&&(n.dispatch=function(){return e.value(n.argument)}),n}(t),o=function(){return n.dispatch()};switch(n.modifier){case za.Once:o=function(e){return function(t){t(),e.dispatch()}}(n);break;case za.Throttle:o=function(e){var t,n=null!==(t=e.time)&&void 0!==t?t:qa,o=null;return function(){null===o?e.dispatch():clearTimeout(o),o=window.setTimeout((function(){o=null}),n)}}(n);break;case za.Debounce:o=function(e){var t,n=null!==(t=e.time)&&void 0!==t?t:qa,o=null;return function(){null!==o&&clearTimeout(o),o=window.setTimeout((function(){o=null,e.dispatch()}),n)}}(n)}switch(n.behavior){case Ha.Single:!function(e,t,n){var o,r=null,s=function(t){t.isTrusted&&(t.preventDefault(),"mousedown"===t.type||"touchstart"===t.type?(null!==r&&clearTimeout(r),r=window.setTimeout((function(){null!==r&&(clearTimeout(r),r=null)}),300)):"mouseup"!==t.type&&"touchend"!==t.type||null===r||(clearTimeout(r),r=null,n((function(){e.removeEventListener("touchstart",s),e.removeEventListener("touchend",s),e.removeEventListener("mousedown",s),e.removeEventListener("mouseup",s),delete e.dataset.vcBindClick}))))};e.addEventListener("touchstart",s),e.addEventListener("touchend",s),e.addEventListener("mousedown",s),e.addEventListener("mouseup",s),e.dataset.vcBindClick=null!==(o=t.modifier)&&void 0!==o?o:""}(e,n,o);break;case Ha.Double:!function(e,t,n){var o,r,s=null!==(o=t.time)&&void 0!==o?o:qa,i=null,l=0,c=function(t){t.isTrusted&&(t.preventDefault(),"mousedown"===t.type||"touchstart"===t.type?(null!==i&&clearTimeout(i),i=window.setTimeout((function(){null!==i&&(clearTimeout(i),i=null,l=0)}),300)):"mouseup"!==t.type&&"touchend"!==t.type||null===i||(clearTimeout(i),i=null,0===l?(l++,i=window.setTimeout((function(){null!==i&&(clearTimeout(i),i=null,l=0)}),s)):(l=0,n((function(){e.removeEventListener("touchstart",c),e.removeEventListener("touchend",c),e.removeEventListener("mousedown",c),e.removeEventListener("mouseup",c),delete e.dataset.vcBindDouble})))))};e.addEventListener("touchstart",c),e.addEventListener("touchend",c),e.addEventListener("mousedown",c),e.addEventListener("mouseup",c),e.dataset.vcBindDouble=null!==(r=t.modifier)&&void 0!==r?r:""}(e,n,o);break;case Ha.Hold:!function(e,t,n){var o,r,s=null!==(o=t.time)&&void 0!==o?o:qa,i=null,l=function(t){t.isTrusted&&(t.preventDefault(),"mousedown"===t.type||"touchstart"===t.type?i=window.setTimeout((function(){n((function(){e.removeEventListener("touchstart",l),e.removeEventListener("touchend",l),e.removeEventListener("mousedown",l),e.removeEventListener("mouseup",l),delete e.dataset.vcBindHold}))}),s):"mouseup"!==t.type&&"touchend"!==t.type||null===i||(clearTimeout(i),i=null))};e.addEventListener("touchstart",l),e.addEventListener("touchend",l),e.addEventListener("mousedown",l),e.addEventListener("mouseup",l),e.dataset.vcBindHold=null!==(r=t.modifier)&&void 0!==r?r:""}(e,n,o);break;case Ha.Press:!function(e,t,n){var o,r=function(t){t.isTrusted&&(t.preventDefault(),n((function(){e.removeEventListener("touchend",r),e.removeEventListener("mousedown",r),delete e.dataset.vcBindPress})))};e.addEventListener("touchstart",r),e.addEventListener("mousedown",r),e.dataset.vcBindPress=null!==(o=t.modifier)&&void 0!==o?o:""}(e,n,o);break;case Ha.Release:!function(e,t,n){var o,r="vcBindRelease",s=function(t){t.isTrusted&&(t.preventDefault(),n((function(){e.removeEventListener("touchend",s),e.removeEventListener("mouseup",s),delete e.dataset[r]})))};e.addEventListener("touchend",s),e.addEventListener("mouseup",s),e.dataset[r]=null!==(o=t.modifier)&&void 0!==o?o:""}(e,n,o)}}};const Za={install:function(e){e.directive("click",Ja)}};var Qa=Ii({data:function(){return{count:0}},methods:{click:function(e){var t=1;"number"==typeof e&&(t=e),"string"==typeof e&&(t=parseInt(e,10)),this.count+=t},reset:function(){this.count=0}}});Qa.use(Za),Qa.mount("#app")})(); -------------------------------------------------------------------------------- /demo/style.css: -------------------------------------------------------------------------------- 1 | html, body { 2 | margin: 0; 3 | font-family: "Courier New", Courier, monospace; 4 | background: #f8f8ff; 5 | } 6 | 7 | #app { 8 | display: flex; 9 | flex-direction: column; 10 | flex-wrap: wrap; 11 | align-items: flex-start; 12 | height: 100vh; 13 | } 14 | 15 | #app > div:first-child > h1 { 16 | font-size: 2.5rem; 17 | display: block; 18 | margin: 1rem 1rem 0; 19 | } 20 | 21 | #app > div:first-child > a { 22 | font-weight: bold; 23 | margin: 0 1rem; 24 | } 25 | 26 | #app > div:first-child > p { 27 | font-weight: bold; 28 | } 29 | 30 | #app > div:first-child > p > button { 31 | padding: 0; 32 | margin: 0; 33 | display: inline-block; 34 | border: none; 35 | background-color: transparent; 36 | font-weight: bold; 37 | } 38 | 39 | button, p { 40 | font-size: 1rem; 41 | display: block; 42 | margin: 1rem; 43 | } 44 | 45 | button { 46 | padding: 0.5rem 1rem; 47 | color: rgba(0, 0, 0, 0.8); 48 | border: 1px solid rgba(0, 0, 0, 0.2); 49 | background-color: rgba(0, 0, 0, 0.05); 50 | text-decoration: none; 51 | border-radius: 2px; 52 | cursor: pointer; 53 | user-select: none; 54 | -moz-user-select: none; 55 | -khtml-user-select: none; 56 | -webkit-user-select: none; 57 | -o-user-select: none; 58 | -webkit-tap-highlight-color: transparent; 59 | touch-action: manipulation; 60 | } 61 | 62 | button:focus { 63 | outline: none; 64 | } 65 | 66 | button:active { 67 | outline: none; 68 | box-shadow: inset 0px 0px 5px rgba(0, 0, 0, 0.2); 69 | } 70 | 71 | button[data-vc-bind-click] { 72 | background-color: aquamarine; 73 | } 74 | 75 | button[data-vc-bind-double] { 76 | background-color: aqua; 77 | } 78 | 79 | button[data-vc-bind-hold] { 80 | background-color: lightcyan; 81 | } 82 | 83 | button[data-vc-bind-press] { 84 | background-color: lavender; 85 | } 86 | 87 | button[data-vc-bind-release] { 88 | background-color: lavenderblush; 89 | } -------------------------------------------------------------------------------- /dev/index.html: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | 10 | 11 | Vue-Click Demo 12 | 13 | 14 | 15 |
16 |
17 |

Vue-Click Demo

18 | GitHub Repo 19 |

Click Count: {{ count }}

20 |
21 |
22 |

Native Click

23 | 24 |
25 |
26 |

Click

27 | 28 |
29 |
30 |

Double Click

31 | 32 | 33 | 34 |
35 |
36 |

Hold

37 | 38 | 39 |
40 |
41 |

Press

42 | 43 | 44 |
45 |
46 |

Release

47 | 48 | 49 |
50 |
51 |

Once

52 | 53 | 54 | 55 |
56 |
57 |

Throttle

58 | 59 | 60 | 61 |
62 |
63 |

Debounce

64 | 65 | 66 | 67 |
68 |
69 |

Arguments

70 | 71 | 72 | 73 |
74 |
75 |

Disabled

76 | 77 | 78 |
79 |
80 |

Supported Combos

81 | 82 |
83 |
84 |

⚠ Unsupported Combos

85 | 86 | 87 | 88 | 89 |
90 |
91 | 92 | 93 | -------------------------------------------------------------------------------- /dev/index.ts: -------------------------------------------------------------------------------- 1 | import { createApp } from 'vue' 2 | import VueClick from '../src' 3 | 4 | const app = createApp({ 5 | data () { 6 | return { count: 0 } 7 | }, 8 | methods: { 9 | click (arg?: string | number | MouseEvent) { 10 | let incrementAmount = 1 11 | 12 | if (typeof arg === 'number') { 13 | incrementAmount = arg 14 | } 15 | 16 | if (typeof arg === 'string') { 17 | incrementAmount = parseInt(arg, 10) 18 | } 19 | 20 | (this.count as number) += incrementAmount 21 | }, 22 | reset () { 23 | this.count = 0 24 | } 25 | } 26 | }) 27 | 28 | app.use(VueClick) 29 | app.mount('#app') 30 | -------------------------------------------------------------------------------- /dev/style.css: -------------------------------------------------------------------------------- 1 | html, body { 2 | margin: 0; 3 | font-family: "Courier New", Courier, monospace; 4 | background: ghostwhite; 5 | height: 100%; 6 | width: 100%; 7 | } 8 | 9 | #app { 10 | display: flex; 11 | flex-direction: column; 12 | flex-wrap: wrap; 13 | align-items: flex-start; 14 | height: 100%; 15 | width: 50%; 16 | } 17 | 18 | #app > div:first-child > h1 { 19 | font-size: 2.5rem; 20 | display: block; 21 | margin: 1rem 1rem 0; 22 | } 23 | 24 | #app > div:first-child > a { 25 | font-weight: bold; 26 | margin: 0 1rem; 27 | } 28 | 29 | #app > div:first-child > p { 30 | font-weight: bold; 31 | } 32 | 33 | #app > div:first-child > p > button { 34 | padding: 0; 35 | margin: 0; 36 | display: inline-block; 37 | border: none; 38 | background-color: transparent; 39 | font-weight: bold; 40 | } 41 | 42 | p, 43 | button { 44 | font-size: 1rem; 45 | display: block; 46 | margin: 1rem; 47 | } 48 | 49 | button { 50 | padding: 0.5rem 1rem; 51 | color: rgba(0, 0, 0, 0.8); 52 | border: 1px solid rgba(0, 0, 0, 0.2); 53 | background-color: rgba(0, 0, 0, 0.05); 54 | text-decoration: none; 55 | border-radius: 2px; 56 | cursor: pointer; 57 | user-select: none; 58 | -moz-user-select: none; 59 | -khtml-user-select: none; 60 | -webkit-user-select: none; 61 | -o-user-select: none; 62 | -webkit-tap-highlight-color: transparent; 63 | touch-action: none; 64 | } 65 | 66 | button:focus { 67 | outline: none; 68 | } 69 | 70 | button:active, 71 | button[data-vc-state-active] { 72 | outline: none; 73 | box-shadow: inset 0px 0px 8px rgba(0, 0, 0, 0.4); 74 | } 75 | 76 | button:disabled, 77 | button[data-vc-state-deactivated] { 78 | background: ghostwhite !important; 79 | cursor: inherit; 80 | outline: none; 81 | box-shadow: none; 82 | } 83 | 84 | button[data-vc-bind-click] { 85 | background-color: aquamarine; 86 | } 87 | 88 | button[data-vc-bind-double] { 89 | background-color: aqua; 90 | } 91 | 92 | button[data-vc-bind-hold] { 93 | background-color: lightcyan; 94 | } 95 | 96 | button[data-vc-bind-press] { 97 | background-color: lavender; 98 | } 99 | 100 | button[data-vc-bind-release] { 101 | background-color: lavenderblush; 102 | } -------------------------------------------------------------------------------- /package.json: -------------------------------------------------------------------------------- 1 | { 2 | "name": "vue-click", 3 | "version": "2.1.8", 4 | "private": false, 5 | "description": "Vue plugin for advanced click directive.", 6 | "author": "Zachary Cardoza", 7 | "license": "MIT", 8 | "keywords": [ 9 | "vue", 10 | "click", 11 | "throttle", 12 | "debounce" 13 | ], 14 | "publishConfig": { 15 | "access": "public" 16 | }, 17 | "bugs": { 18 | "url": "https://github.com/nerdoza/vue-click/issues" 19 | }, 20 | "homepage": "https://github.com/nerdoza/vue-click#readme", 21 | "repository": { 22 | "type": "git", 23 | "url": "https://github.com/nerdoza/vue-click.git" 24 | }, 25 | "main": "dist/index.js", 26 | "types": "dist/index.d.ts", 27 | "files": [ 28 | "dist/index.js", 29 | "dist/index.d.ts" 30 | ], 31 | "scripts": { 32 | "build": "webpack --config webpack/prod.config.js", 33 | "lint": "eslint .", 34 | "dev": "webpack serve --config webpack/dev.config.js", 35 | "start": "npm run dev", 36 | "demo": "webpack --config webpack/demo.config.js" 37 | }, 38 | "dependencies": {}, 39 | "devDependencies": { 40 | "@typescript-eslint/eslint-plugin": "^5.43.0", 41 | "@typescript-eslint/parser": "^5.43.0", 42 | "clean-webpack-plugin": "^3.0.0", 43 | "copy-webpack-plugin": "^8.0.0", 44 | "dts-bundle": "^0.7.3", 45 | "eslint": "^8.28.0", 46 | "eslint-config-standard-with-typescript": "^23.0.0", 47 | "eslint-plugin-import": "^2.26.0", 48 | "eslint-plugin-node": "^11.1.0", 49 | "eslint-plugin-promise": "^6.1.1", 50 | "eslint-plugin-standard": "^5.0.0", 51 | "html-webpack-plugin": "^5.5.0", 52 | "ts-loader": "^9.4.1", 53 | "typescript": "^4.9.3", 54 | "vue": "^3.2.45", 55 | "webpack": "^5.75.0", 56 | "webpack-cli": "^5.0.0", 57 | "webpack-dev-server": "^4.11.1" 58 | } 59 | } -------------------------------------------------------------------------------- /src/binding.ts: -------------------------------------------------------------------------------- 1 | import { DirectiveBinding } from 'vue' 2 | import { TimeParser, IsTime } from './time' 3 | 4 | export enum Behavior { 5 | Single = 'single', 6 | Double = 'double', 7 | Hold = 'hold', 8 | Press = 'press', 9 | Release = 'release' 10 | } 11 | 12 | export enum Modifier { 13 | Once = 'once', 14 | Throttle = 'throttle', 15 | Debounce = 'debounce' 16 | } 17 | 18 | export interface BindingOptions { 19 | behavior: Behavior 20 | modifier: Modifier | null 21 | time: number | null 22 | argument: string | null 23 | once: boolean 24 | dispatch: Function | (() => void) 25 | } 26 | 27 | const enumHasValue = (enumerator: object, value: string) => { 28 | return Object.keys(enumerator).filter(key => Object(enumerator)[key] === value).length > 0 29 | } 30 | 31 | export const ParseBinding = (binding: DirectiveBinding) => { 32 | const result: BindingOptions = { 33 | behavior: Behavior.Single, 34 | modifier: null, 35 | time: null, 36 | argument: null, 37 | once: false, 38 | dispatch: () => { } 39 | } 40 | 41 | for (const modKey in binding.modifiers) { 42 | const mods = modKey.split(':') 43 | if (typeof mods[1] !== 'undefined') { 44 | result.argument = mods[1] 45 | } 46 | 47 | if (IsTime(mods[0])) { 48 | result.time = TimeParser(mods[0]) 49 | } else if (enumHasValue(Behavior, mods[0])) { 50 | result.behavior = mods[0] as Behavior 51 | } else if (enumHasValue(Modifier, mods[0])) { 52 | result.modifier = mods[0] as Modifier 53 | } 54 | } 55 | 56 | if (typeof binding.arg !== 'undefined') { 57 | result.argument = binding.arg 58 | } 59 | 60 | if (typeof binding.value === 'function') { 61 | result.dispatch = () => binding.value(result.argument) 62 | } 63 | 64 | return result 65 | } 66 | -------------------------------------------------------------------------------- /src/index.ts: -------------------------------------------------------------------------------- 1 | import { Directive } from 'vue' 2 | import { ParseBinding, Behavior, Modifier, BindingOptions } from './binding' 3 | 4 | const defaultEventTimeout = 300 5 | const dataBindingPrefix = 'vcBind' 6 | const dataBindClickPostfix = 'Click' 7 | const dataBindDoublePostfix = 'Double' 8 | const dataBindHoldPostfix = 'Hold' 9 | const dataBindPressPostfix = 'Press' 10 | const dataBindReleasePostfix = 'Release' 11 | const dataStatePrefix = 'vcState' 12 | const dataStateActivePostfix = 'Active' 13 | const dataStateDeactivatedPostfix = 'Deactivated' 14 | 15 | /** 16 | * @summary `eventOptions` will evaluate as `true` on older browsers, which is consistent behavior so no polyfill is required. 17 | * @see https://github.com/WICG/EventListenerOptions/blob/gh-pages/explainer.md 18 | */ 19 | const eventOptions: AddEventListenerOptions = { 20 | capture: true, 21 | passive: false 22 | } 23 | 24 | const bindClassStates = (el: HTMLElement) => { 25 | if ( 26 | typeof el.dataset[dataBindingPrefix + dataBindClickPostfix] !== 'undefined' || 27 | typeof el.dataset[dataBindingPrefix + dataBindDoublePostfix] !== 'undefined' || 28 | typeof el.dataset[dataBindingPrefix + dataBindHoldPostfix] !== 'undefined' || 29 | typeof el.dataset[dataBindingPrefix + dataBindPressPostfix] !== 'undefined' || 30 | typeof el.dataset[dataBindingPrefix + dataBindReleasePostfix] !== 'undefined' 31 | ) { 32 | return () => {} 33 | } 34 | 35 | const eventCallback = (event: MouseEvent | TouchEvent) => { 36 | if (event.type === 'mousedown' || event.type === 'touchstart') { 37 | el.dataset[dataStatePrefix + dataStateActivePostfix] = '' 38 | } else { 39 | delete (el.dataset[dataStatePrefix + dataStateActivePostfix]) 40 | } 41 | } 42 | 43 | el.addEventListener('touchstart', eventCallback, eventOptions) 44 | el.addEventListener('touchend', eventCallback, eventOptions) 45 | el.addEventListener('mousedown', eventCallback, eventOptions) 46 | el.addEventListener('mouseup', eventCallback, eventOptions) 47 | 48 | return () => { 49 | el.removeEventListener('touchstart', eventCallback, eventOptions) 50 | el.removeEventListener('touchend', eventCallback, eventOptions) 51 | el.removeEventListener('mousedown', eventCallback, eventOptions) 52 | el.removeEventListener('mouseup', eventCallback, eventOptions) 53 | el.dataset[dataStatePrefix + dataStateDeactivatedPostfix] = '' 54 | } 55 | } 56 | 57 | const singleBehavior = (el: HTMLElement, bindingOptions: BindingOptions, onEvent: (removeBinding: () => void) => void) => { 58 | const dataBinding = dataBindingPrefix + dataBindClickPostfix 59 | const clickTimeout = defaultEventTimeout 60 | let clickState: number | null = null 61 | 62 | const eventCallback = (event: MouseEvent | TouchEvent) => { 63 | if (event.isTrusted) { 64 | if (event.cancelable) { 65 | event.preventDefault() 66 | } 67 | 68 | if (event.type === 'mousedown' || event.type === 'touchstart') { 69 | if (clickState !== null) { 70 | clearTimeout(clickState) 71 | } 72 | clickState = window.setTimeout(() => { 73 | if (clickState !== null) { 74 | clearTimeout(clickState) 75 | clickState = null 76 | } 77 | }, clickTimeout) 78 | } else if ((event.type === 'mouseup' || event.type === 'touchend') && clickState !== null) { 79 | clearTimeout(clickState) 80 | clickState = null 81 | 82 | onEvent(() => { 83 | unbindClasses() 84 | el.removeEventListener('touchstart', eventCallback, eventOptions) 85 | el.removeEventListener('touchend', eventCallback, eventOptions) 86 | el.removeEventListener('mousedown', eventCallback, eventOptions) 87 | el.removeEventListener('mouseup', eventCallback, eventOptions) 88 | delete (el.dataset[dataBinding]) 89 | }) 90 | } 91 | } 92 | } 93 | 94 | const unbindClasses = bindClassStates(el) 95 | el.addEventListener('touchstart', eventCallback, eventOptions) 96 | el.addEventListener('touchend', eventCallback, eventOptions) 97 | el.addEventListener('mousedown', eventCallback, eventOptions) 98 | el.addEventListener('mouseup', eventCallback, eventOptions) 99 | el.dataset[dataBinding] = bindingOptions.modifier ?? '' 100 | } 101 | 102 | const doubleBehavior = (el: HTMLElement, bindingOptions: BindingOptions, onEvent: (removeBinding: () => void) => void) => { 103 | const dataBinding = dataBindingPrefix + dataBindDoublePostfix 104 | const clickTimeout = defaultEventTimeout 105 | const doubleClickTimeout = bindingOptions.time ?? defaultEventTimeout 106 | let clickState: number | null = null 107 | let clickCount: number = 0 108 | 109 | const eventCallback = (event: MouseEvent | TouchEvent) => { 110 | if (event.isTrusted) { 111 | if (event.cancelable) { 112 | event.preventDefault() 113 | } 114 | 115 | if (event.type === 'mousedown' || event.type === 'touchstart') { 116 | if (clickState !== null) { 117 | clearTimeout(clickState) 118 | } 119 | clickState = window.setTimeout(() => { 120 | if (clickState !== null) { 121 | clearTimeout(clickState) 122 | clickState = null 123 | clickCount = 0 124 | } 125 | }, clickTimeout) 126 | } else if ((event.type === 'mouseup' || event.type === 'touchend') && clickState !== null) { 127 | clearTimeout(clickState) 128 | clickState = null 129 | if (clickCount === 0) { 130 | clickCount++ 131 | clickState = window.setTimeout(() => { 132 | if (clickState !== null) { 133 | clearTimeout(clickState) 134 | clickState = null 135 | clickCount = 0 136 | } 137 | }, doubleClickTimeout) 138 | } else { 139 | clickCount = 0 140 | onEvent(() => { 141 | unbindClasses() 142 | el.removeEventListener('touchstart', eventCallback, eventOptions) 143 | el.removeEventListener('touchend', eventCallback, eventOptions) 144 | el.removeEventListener('mousedown', eventCallback, eventOptions) 145 | el.removeEventListener('mouseup', eventCallback, eventOptions) 146 | delete (el.dataset[dataBinding]) 147 | }) 148 | } 149 | } 150 | } 151 | } 152 | 153 | const unbindClasses = bindClassStates(el) 154 | el.addEventListener('touchstart', eventCallback, eventOptions) 155 | el.addEventListener('touchend', eventCallback, eventOptions) 156 | el.addEventListener('mousedown', eventCallback, eventOptions) 157 | el.addEventListener('mouseup', eventCallback, eventOptions) 158 | el.dataset[dataBinding] = bindingOptions.modifier ?? '' 159 | } 160 | 161 | const holdBehavior = (el: HTMLElement, bindingOptions: BindingOptions, onEvent: (removeBinding: () => void) => void) => { 162 | const dataBinding = dataBindingPrefix + dataBindHoldPostfix 163 | const holdTimeout = bindingOptions.time ?? defaultEventTimeout 164 | let holdState: number | null = null 165 | 166 | const eventCallback = (event: MouseEvent | TouchEvent) => { 167 | if (event.isTrusted) { 168 | if (event.cancelable) { 169 | event.preventDefault() 170 | } 171 | 172 | if (event.type === 'mousedown' || event.type === 'touchstart') { 173 | holdState = window.setTimeout(() => { 174 | onEvent(() => { 175 | unbindClasses() 176 | el.removeEventListener('touchstart', eventCallback, eventOptions) 177 | el.removeEventListener('touchend', eventCallback, eventOptions) 178 | el.removeEventListener('mousedown', eventCallback, eventOptions) 179 | el.removeEventListener('mouseup', eventCallback, eventOptions) 180 | delete (el.dataset[dataBinding]) 181 | }) 182 | }, holdTimeout) 183 | } else if ((event.type === 'mouseup' || event.type === 'touchend') && holdState !== null) { 184 | clearTimeout(holdState) 185 | holdState = null 186 | } 187 | } 188 | } 189 | 190 | const unbindClasses = bindClassStates(el) 191 | el.addEventListener('touchstart', eventCallback, eventOptions) 192 | el.addEventListener('touchend', eventCallback, eventOptions) 193 | el.addEventListener('mousedown', eventCallback, eventOptions) 194 | el.addEventListener('mouseup', eventCallback, eventOptions) 195 | el.dataset[dataBinding] = bindingOptions.modifier ?? '' 196 | } 197 | 198 | const pressBehavior = (el: HTMLElement, bindingOptions: BindingOptions, onEvent: (removeBinding: () => void) => void) => { 199 | const dataBinding = dataBindingPrefix + dataBindPressPostfix 200 | const eventCallback = (event: MouseEvent | TouchEvent) => { 201 | if (event.isTrusted) { 202 | if (event.cancelable) { 203 | event.preventDefault() 204 | } 205 | 206 | onEvent(() => { 207 | unbindClasses() 208 | el.removeEventListener('touchend', eventCallback, eventOptions) 209 | el.removeEventListener('mousedown', eventCallback, eventOptions) 210 | delete (el.dataset[dataBinding]) 211 | }) 212 | } 213 | } 214 | 215 | const unbindClasses = bindClassStates(el) 216 | el.addEventListener('touchstart', eventCallback, eventOptions) 217 | el.addEventListener('mousedown', eventCallback, eventOptions) 218 | el.dataset[dataBinding] = bindingOptions.modifier ?? '' 219 | } 220 | 221 | const releaseBehavior = (el: HTMLElement, bindingOptions: BindingOptions, onEvent: (removeBinding: () => void) => void) => { 222 | const dataBinding = dataBindingPrefix + dataBindReleasePostfix 223 | const eventCallback = (event: MouseEvent | TouchEvent) => { 224 | if (event.isTrusted) { 225 | if (event.cancelable) { 226 | event.preventDefault() 227 | } 228 | 229 | onEvent(() => { 230 | unbindClasses() 231 | el.removeEventListener('touchend', eventCallback, eventOptions) 232 | el.removeEventListener('mouseup', eventCallback, eventOptions) 233 | delete (el.dataset[dataBinding]) 234 | }) 235 | } 236 | } 237 | 238 | const unbindClasses = bindClassStates(el) 239 | el.addEventListener('touchend', eventCallback, eventOptions) 240 | el.addEventListener('mouseup', eventCallback, eventOptions) 241 | el.dataset[dataBinding] = bindingOptions.modifier ?? '' 242 | } 243 | 244 | const onceModifier = (bindingOptions: BindingOptions) => { 245 | return (removeBinding: () => void) => { 246 | removeBinding() 247 | bindingOptions.dispatch() 248 | } 249 | } 250 | 251 | const throttleModifier = (bindingOptions: BindingOptions) => { 252 | const throttleTime = bindingOptions.time ?? defaultEventTimeout 253 | let throttledState: number | null = null 254 | 255 | return () => { 256 | if (throttledState === null) { 257 | bindingOptions.dispatch() 258 | } else { 259 | clearTimeout(throttledState) 260 | } 261 | throttledState = window.setTimeout(() => { throttledState = null }, throttleTime) 262 | } 263 | } 264 | 265 | const debounceModifier = (bindingOptions: BindingOptions) => { 266 | const debounceTime = bindingOptions.time ?? defaultEventTimeout 267 | let debouncedState: number | null = null 268 | 269 | return () => { 270 | if (debouncedState !== null) { 271 | clearTimeout(debouncedState) 272 | } 273 | 274 | debouncedState = window.setTimeout(() => { 275 | debouncedState = null 276 | bindingOptions.dispatch() 277 | }, debounceTime) 278 | } 279 | } 280 | 281 | export const ClickDirective: Directive = { 282 | mounted (el, binding) { 283 | const bindingOptions = ParseBinding(binding) 284 | let dispatch: (removeBinding: () => void) => void = () => bindingOptions.dispatch() 285 | 286 | switch (bindingOptions.modifier) { 287 | case Modifier.Once: 288 | dispatch = onceModifier(bindingOptions) 289 | break 290 | case Modifier.Throttle: 291 | dispatch = throttleModifier(bindingOptions) 292 | break 293 | case Modifier.Debounce: 294 | dispatch = debounceModifier(bindingOptions) 295 | break 296 | } 297 | 298 | const disableableDispatch: (removeBinding: () => void) => void = (removeBinding) => { 299 | if (el.disabled !== true) { 300 | dispatch(removeBinding) 301 | } 302 | } 303 | 304 | switch (bindingOptions.behavior) { 305 | case Behavior.Single: 306 | singleBehavior(el, bindingOptions, disableableDispatch) 307 | break 308 | case Behavior.Double: 309 | doubleBehavior(el, bindingOptions, disableableDispatch) 310 | break 311 | case Behavior.Hold: 312 | holdBehavior(el, bindingOptions, disableableDispatch) 313 | break 314 | case Behavior.Press: 315 | pressBehavior(el, bindingOptions, disableableDispatch) 316 | break 317 | case Behavior.Release: 318 | releaseBehavior(el, bindingOptions, disableableDispatch) 319 | break 320 | } 321 | } 322 | } 323 | 324 | export default { 325 | install: (app: any) => { 326 | app.directive('click', ClickDirective) 327 | } 328 | } 329 | -------------------------------------------------------------------------------- /src/time.ts: -------------------------------------------------------------------------------- 1 | const timeSplitRegex = /^(\d+)?(m|s|ms)?$/i 2 | 3 | export const IsTime = (arg: string = '') => { 4 | return timeSplitRegex.test(arg) 5 | } 6 | 7 | export const TimeParser = (timeString: string = '') => { 8 | const match = timeSplitRegex.exec(timeString) 9 | 10 | if (match !== null && match.length >= 3) { 11 | const numericSegment = parseFloat(match[1]) 12 | 13 | switch ((match[2] ?? 'ms').toLowerCase()) { 14 | case 'm': 15 | return numericSegment * 60000 16 | case 's': 17 | return numericSegment * 1000 18 | case 'ms': 19 | return numericSegment 20 | } 21 | } 22 | 23 | return null 24 | } 25 | -------------------------------------------------------------------------------- /tsconfig.eslint.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig.json", 3 | "include": [ 4 | "./src/**/*", 5 | "./dev/**/*", 6 | "./node_modules/@types" 7 | ], 8 | "exclude": [ 9 | "./node_modules", 10 | "./dist", 11 | "./demo" 12 | ] 13 | } -------------------------------------------------------------------------------- /tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "target": "es5", 4 | "module": "esnext", 5 | "moduleResolution": "node", 6 | "outDir": "./dist/types", 7 | "declaration": true, 8 | "sourceMap": true, 9 | "strict": true, 10 | "newLine": "lf", 11 | "removeComments": true, 12 | "noImplicitAny": true, 13 | "noUnusedLocals": true, 14 | "typeRoots": [ 15 | "./node_modules/@types" 16 | ], 17 | "lib": [ 18 | "dom", 19 | "es2017" 20 | ] 21 | }, 22 | "include": [ 23 | "./src/**/*", 24 | "./node_modules/@types" 25 | ], 26 | "exclude": [ 27 | "./node_modules", 28 | "./dist", 29 | "./demo", 30 | "./dev" 31 | ] 32 | } -------------------------------------------------------------------------------- /webpack/demo.config.js: -------------------------------------------------------------------------------- 1 | const path = require('path') 2 | const HtmlWebpackPlugin = require('html-webpack-plugin') 3 | const CopyPlugin = require('copy-webpack-plugin') 4 | 5 | const DIST = path.resolve(__dirname, '../demo') 6 | 7 | module.exports = { 8 | mode: 'production', 9 | entry: './dev/index.ts', 10 | module: { 11 | rules: [ 12 | { 13 | test: /\.tsx?$/, 14 | use: 'ts-loader', 15 | exclude: /node_modules/ 16 | }, 17 | { 18 | test: /\.css$/i, 19 | use: ['style-loader', 'css-loader'] 20 | } 21 | ] 22 | }, 23 | resolve: { 24 | extensions: ['.tsx', '.ts', '.js'], 25 | alias: { 26 | vue: 'vue/dist/vue.esm-bundler.js' 27 | } 28 | }, 29 | plugins: [ 30 | new HtmlWebpackPlugin({ 31 | template: './dev/index.html' 32 | }), 33 | new CopyPlugin({ 34 | patterns: [ 35 | { from: './dev/style.css', to: path.resolve(DIST, 'style.css') } 36 | ] 37 | }) 38 | ], 39 | output: { 40 | hashFunction: 'xxhash64', 41 | filename: 'index.js', 42 | path: DIST 43 | } 44 | } 45 | -------------------------------------------------------------------------------- /webpack/dev.config.js: -------------------------------------------------------------------------------- 1 | const HtmlWebpackPlugin = require('html-webpack-plugin') 2 | const webpack = require('webpack') 3 | 4 | module.exports = { 5 | mode: 'development', 6 | entry: './dev/index.ts', 7 | module: { 8 | rules: [ 9 | { 10 | test: /\.tsx?$/, 11 | use: 'ts-loader', 12 | exclude: /node_modules/ 13 | } 14 | ] 15 | }, 16 | resolve: { 17 | extensions: ['.tsx', '.ts', '.js'], 18 | alias: { 19 | vue: 'vue/dist/vue.esm-bundler.js' 20 | } 21 | }, 22 | devtool: 'inline-source-map', 23 | devServer: { 24 | host: '0.0.0.0', 25 | static: { 26 | directory: './dev' 27 | }, 28 | hot: true 29 | }, 30 | plugins: [ 31 | new HtmlWebpackPlugin({ 32 | template: './dev/index.html' 33 | }), 34 | new webpack.HotModuleReplacementPlugin() 35 | ], 36 | output: { 37 | hashFunction: 'xxhash64', 38 | filename: 'index.js' 39 | } 40 | } 41 | -------------------------------------------------------------------------------- /webpack/prod.config.js: -------------------------------------------------------------------------------- 1 | const fs = require('fs') 2 | const path = require('path') 3 | const { CleanWebpackPlugin } = require('clean-webpack-plugin') 4 | 5 | const DIST = path.resolve(__dirname, '../dist') 6 | 7 | function DtsBundlePlugin (options) { this.options = options } 8 | DtsBundlePlugin.prototype.apply = function (compiler) { 9 | compiler.hooks.afterEmit.tap('DtsBundlePlugin', () => { 10 | require('dts-bundle').bundle(this.options) 11 | replace(this.options.out, [ 12 | { 13 | search: /^\/\/.*\r?\n/gm, 14 | replace: '' 15 | }, 16 | { 17 | search: /^[\t ]*\r?\n/gm, 18 | replace: '' 19 | }, 20 | { 21 | search: /^\}(?:\r?\n|\r)(?!$)/gm, 22 | replace: '}\n\n' 23 | } 24 | ]) 25 | }) 26 | } 27 | 28 | function replace (file, rules) { 29 | const src = path.resolve(file) 30 | let template = fs.readFileSync(src, 'utf8') 31 | 32 | template = rules.reduce( 33 | (template, rule) => template.replace(rule.search, rule.replace), 34 | template 35 | ) 36 | 37 | fs.writeFileSync(src, template) 38 | } 39 | 40 | module.exports = { 41 | mode: 'production', 42 | entry: './src/index.ts', 43 | module: { 44 | rules: [ 45 | { 46 | test: /\.tsx?$/, 47 | use: 'ts-loader', 48 | exclude: /node_modules/ 49 | } 50 | ] 51 | }, 52 | resolve: { 53 | extensions: ['.tsx', '.ts', '.js'] 54 | }, 55 | plugins: [ 56 | new CleanWebpackPlugin({ 57 | cleanOnceBeforeBuildPatterns: [DIST], 58 | cleanAfterEveryBuildPatterns: [path.join(DIST, 'types')] 59 | }), 60 | new DtsBundlePlugin({ 61 | name: 'VueClick', 62 | main: path.join(DIST, 'types/index.d.ts'), 63 | out: path.join(DIST, 'index.d.ts'), 64 | removeSource: true, 65 | newLine: 'lf', 66 | indent: ' ', 67 | outputAsModuleFolder: true 68 | }) 69 | ], 70 | output: { 71 | hashFunction: 'xxhash64', 72 | filename: 'index.js', 73 | path: DIST, 74 | libraryTarget: 'umd', 75 | library: 'VueClick' 76 | } 77 | } 78 | --------------------------------------------------------------------------------