moreShopAdmin/dist/assets/@vueuse.fbc6a400.js

2 lines
16 KiB
JavaScript

import{g as be,e as he,f as ce,i as Pe,n as fe,j as Se,r as O,u as Ee,w as S,s as de,k as pe,l as W,b as T}from"./@vue.18505fe0.js";var $e=Object.defineProperty,Fe=Object.defineProperties,Ie=Object.getOwnPropertyDescriptors,J=Object.getOwnPropertySymbols,je=Object.prototype.hasOwnProperty,Ce=Object.prototype.propertyIsEnumerable,q=(e,t,r)=>t in e?$e(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Ne=(e,t)=>{for(var r in t||(t={}))je.call(t,r)&&q(e,r,t[r]);if(J)for(var r of J(t))Ce.call(t,r)&&q(e,r,t[r]);return e},Te=(e,t)=>Fe(e,Ie(t));function Tt(e,t){var r;const n=de();return pe(()=>{n.value=e()},Te(Ne({},t),{flush:(r=t==null?void 0:t.flush)!=null?r:"sync"})),W(n)}var H;const A=typeof window<"u",De=e=>typeof e<"u",ve=e=>typeof e=="function",Ae=e=>typeof e=="string",D=()=>{},Me=A&&((H=window==null?void 0:window.navigator)==null?void 0:H.userAgent)&&/iP(ad|hone|od)/.test(window.navigator.userAgent);function E(e){return typeof e=="function"?e():Ee(e)}function z(e,t){function r(...n){return new Promise((a,o)=>{Promise.resolve(e(()=>t.apply(this,n),{fn:t,thisArg:this,args:n})).then(a).catch(o)})}return r}const me=e=>e();function Re(e,t={}){let r,n,a=D;const o=s=>{clearTimeout(s),a(),a=D};return s=>{const u=E(e),c=E(t.maxWait);return r&&o(r),u<=0||c!==void 0&&c<=0?(n&&(o(n),n=null),Promise.resolve(s())):new Promise((d,v)=>{a=t.rejectOnCancel?v:d,c&&!n&&(n=setTimeout(()=>{r&&o(r),n=null,d(s())},c)),r=setTimeout(()=>{n&&o(n),n=null,d(s())},u)})}}function xe(e,t=!0,r=!0,n=!1){let a=0,o,i=!0,s=D,u;const c=()=>{o&&(clearTimeout(o),o=void 0,s(),s=D)};return v=>{const l=E(e),f=Date.now()-a,p=()=>u=v();return c(),l<=0?(a=Date.now(),p()):(f>l&&(r||!i)?(a=Date.now(),p()):t&&(u=new Promise((_,$)=>{s=n?$:_,o=setTimeout(()=>{a=Date.now(),i=!0,_(p()),c()},Math.max(0,l-f))})),!r&&!o&&(o=setTimeout(()=>i=!0,l)),i=!1,u)}}function ke(e=me){const t=O(!0);function r(){t.value=!1}function n(){t.value=!0}const a=(...o)=>{t.value&&e(...o)};return{isActive:W(t),pause:r,resume:n,eventFilter:a}}function Ve(e){return e}function M(e){return be()?(he(e),!0):!1}function Le(e,t=200,r={}){return z(Re(t,r),e)}function Dt(e,t=200,r={}){const n=O(e.value),a=Le(()=>{n.value=e.value},t,r);return S(e,()=>a()),n}function At(e,t=200,r=!1,n=!0,a=!1){return z(xe(t,r,n,a),e)}function We(e){return typeof e=="function"?T(e):O(e)}function Q(e,t=!0){ce()?Pe(e):t?e():fe(e)}function Mt(e,t,r={}){const{immediate:n=!0}=r,a=O(!1);let o=null;function i(){o&&(clearTimeout(o),o=null)}function s(){a.value=!1,i()}function u(...c){i(),a.value=!0,o=setTimeout(()=>{a.value=!1,o=null,e(...c)},E(t))}return n&&(a.value=!0,A&&u()),M(s),{isPending:W(a),start:u,stop:s}}function Rt(e=!1,t={}){const{truthyValue:r=!0,falsyValue:n=!1}=t,a=Se(e),o=O(e);function i(s){if(arguments.length)return o.value=s,o.value;{const u=E(r);return o.value=o.value===u?E(n):u,o.value}}return a?i:[o,i]}var B=Object.getOwnPropertySymbols,ze=Object.prototype.hasOwnProperty,Qe=Object.prototype.propertyIsEnumerable,Je=(e,t)=>{var r={};for(var n in e)ze.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&B)for(var n of B(e))t.indexOf(n)<0&&Qe.call(e,n)&&(r[n]=e[n]);return r};function qe(e,t,r={}){const n=r,{eventFilter:a=me}=n,o=Je(n,["eventFilter"]);return S(e,z(a,t),o)}var He=Object.defineProperty,Be=Object.defineProperties,Ue=Object.getOwnPropertyDescriptors,R=Object.getOwnPropertySymbols,_e=Object.prototype.hasOwnProperty,Oe=Object.prototype.propertyIsEnumerable,U=(e,t,r)=>t in e?He(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Ge=(e,t)=>{for(var r in t||(t={}))_e.call(t,r)&&U(e,r,t[r]);if(R)for(var r of R(t))Oe.call(t,r)&&U(e,r,t[r]);return e},Ke=(e,t)=>Be(e,Ue(t)),Xe=(e,t)=>{var r={};for(var n in e)_e.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&R)for(var n of R(e))t.indexOf(n)<0&&Oe.call(e,n)&&(r[n]=e[n]);return r};function Ye(e,t,r={}){const n=r,{eventFilter:a}=n,o=Xe(n,["eventFilter"]),{eventFilter:i,pause:s,resume:u,isActive:c}=ke(a);return{stop:qe(e,t,Ke(Ge({},o),{eventFilter:i})),pause:s,resume:u,isActive:c}}function I(e){var t;const r=E(e);return(t=r==null?void 0:r.$el)!=null?t:r}const h=A?window:void 0,ge=A?window.document:void 0;A&&window.navigator;A&&window.location;function P(...e){let t,r,n,a;if(Ae(e[0])||Array.isArray(e[0])?([r,n,a]=e,t=h):[t,r,n,a]=e,!t)return D;Array.isArray(r)||(r=[r]),Array.isArray(n)||(n=[n]);const o=[],i=()=>{o.forEach(d=>d()),o.length=0},s=(d,v,l,f)=>(d.addEventListener(v,l,f),()=>d.removeEventListener(v,l,f)),u=S(()=>[I(t),E(a)],([d,v])=>{i(),d&&o.push(...r.flatMap(l=>n.map(f=>s(d,l,f,v))))},{immediate:!0,flush:"post"}),c=()=>{u(),i()};return M(c),c}let G=!1;function xt(e,t,r={}){const{window:n=h,ignore:a=[],capture:o=!0,detectIframe:i=!1}=r;if(!n)return;Me&&!G&&(G=!0,Array.from(n.document.body.children).forEach(l=>l.addEventListener("click",D)));let s=!0;const u=l=>a.some(f=>{if(typeof f=="string")return Array.from(n.document.querySelectorAll(f)).some(p=>p===l.target||l.composedPath().includes(p));{const p=I(f);return p&&(l.target===p||l.composedPath().includes(p))}}),d=[P(n,"click",l=>{const f=I(e);if(!(!f||f===l.target||l.composedPath().includes(f))){if(l.detail===0&&(s=!u(l)),!s){s=!0;return}t(l)}},{passive:!0,capture:o}),P(n,"pointerdown",l=>{const f=I(e);f&&(s=!l.composedPath().includes(f)&&!u(l))},{passive:!0}),i&&P(n,"blur",l=>{var f;const p=I(e);((f=n.document.activeElement)==null?void 0:f.tagName)==="IFRAME"&&!(p!=null&&p.contains(n.document.activeElement))&&t(l)})].filter(Boolean);return()=>d.forEach(l=>l())}function x(e,t=!1){const r=O(),n=()=>r.value=Boolean(e());return n(),Q(n,t),r}function Ze(e,t={}){const{window:r=h}=t,n=x(()=>r&&"matchMedia"in r&&typeof r.matchMedia=="function");let a;const o=O(!1),i=()=>{!a||("removeEventListener"in a?a.removeEventListener("change",s):a.removeListener(s))},s=()=>{!n.value||(i(),a=r.matchMedia(We(e).value),o.value=a.matches,"addEventListener"in a?a.addEventListener("change",s):a.addListener(s))};return pe(s),M(()=>i()),o}function et(e){return JSON.parse(JSON.stringify(e))}const V=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{},L="__vueuse_ssr_handlers__";V[L]=V[L]||{};const tt=V[L];function we(e,t){return tt[e]||t}function rt(e){return e==null?"any":e instanceof Set?"set":e instanceof Map?"map":e instanceof Date?"date":typeof e=="boolean"?"boolean":typeof e=="string"?"string":typeof e=="object"?"object":Number.isNaN(e)?"any":"number"}var nt=Object.defineProperty,K=Object.getOwnPropertySymbols,at=Object.prototype.hasOwnProperty,ot=Object.prototype.propertyIsEnumerable,X=(e,t,r)=>t in e?nt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,Y=(e,t)=>{for(var r in t||(t={}))at.call(t,r)&&X(e,r,t[r]);if(K)for(var r of K(t))ot.call(t,r)&&X(e,r,t[r]);return e};const st={boolean:{read:e=>e==="true",write:e=>String(e)},object:{read:e=>JSON.parse(e),write:e=>JSON.stringify(e)},number:{read:e=>Number.parseFloat(e),write:e=>String(e)},any:{read:e=>e,write:e=>String(e)},string:{read:e=>e,write:e=>String(e)},map:{read:e=>new Map(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e.entries()))},set:{read:e=>new Set(JSON.parse(e)),write:e=>JSON.stringify(Array.from(e))},date:{read:e=>new Date(e),write:e=>e.toISOString()}},Z="vueuse-storage";function it(e,t,r,n={}){var a;const{flush:o="pre",deep:i=!0,listenToStorageChanges:s=!0,writeDefaults:u=!0,mergeDefaults:c=!1,shallow:d,window:v=h,eventFilter:l,onError:f=m=>{console.error(m)}}=n,p=(d?de:O)(t);if(!r)try{r=we("getDefaultStorage",()=>{var m;return(m=h)==null?void 0:m.localStorage})()}catch(m){f(m)}if(!r)return p;const _=E(t),$=rt(_),g=(a=n.serializer)!=null?a:st[$],{pause:w,resume:y}=Ye(p,()=>j(p.value),{flush:o,deep:i,eventFilter:l});return v&&s&&(P(v,"storage",F),P(v,Z,k)),F(),p;function j(m){try{if(m==null)r.removeItem(e);else{const b=g.write(m),C=r.getItem(e);C!==b&&(r.setItem(e,b),v&&v.dispatchEvent(new CustomEvent(Z,{detail:{key:e,oldValue:C,newValue:b,storageArea:r}})))}}catch(b){f(b)}}function N(m){const b=m?m.newValue:r.getItem(e);if(b==null)return u&&_!==null&&r.setItem(e,g.write(_)),_;if(!m&&c){const C=g.read(b);return ve(c)?c(C,_):$==="object"&&!Array.isArray(C)?Y(Y({},_),C):C}else return typeof b!="string"?b:g.read(b)}function k(m){F(m.detail)}function F(m){if(!(m&&m.storageArea!==r)){if(m&&m.key==null){p.value=_;return}if(!(m&&m.key!==e)){w();try{p.value=N(m)}catch(b){f(b)}finally{m?fe(y):y()}}}}}function ye(e){return Ze("(prefers-color-scheme: dark)",e)}var lt=Object.defineProperty,ee=Object.getOwnPropertySymbols,ut=Object.prototype.hasOwnProperty,ct=Object.prototype.propertyIsEnumerable,te=(e,t,r)=>t in e?lt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,ft=(e,t)=>{for(var r in t||(t={}))ut.call(t,r)&&te(e,r,t[r]);if(ee)for(var r of ee(t))ct.call(t,r)&&te(e,r,t[r]);return e};function dt(e={}){const{selector:t="html",attribute:r="class",initialValue:n="auto",window:a=h,storage:o,storageKey:i="vueuse-color-scheme",listenToStorageChanges:s=!0,storageRef:u,emitAuto:c}=e,d=ft({auto:"",light:"light",dark:"dark"},e.modes||{}),v=ye({window:a}),l=T(()=>v.value?"dark":"light"),f=u||(i==null?O(n):it(i,n,o,{window:a,listenToStorageChanges:s})),p=T({get(){return f.value==="auto"&&!c?l.value:f.value},set(w){f.value=w}}),_=we("updateHTMLAttrs",(w,y,j)=>{const N=a==null?void 0:a.document.querySelector(w);if(!!N)if(y==="class"){const k=j.split(/\s/g);Object.values(d).flatMap(F=>(F||"").split(/\s/g)).filter(Boolean).forEach(F=>{k.includes(F)?N.classList.add(F):N.classList.remove(F)})}else N.setAttribute(y,j)});function $(w){var y;const j=w==="auto"?l.value:w;_(t,r,(y=d[j])!=null?y:j)}function g(w){e.onChanged?e.onChanged(w,$):$(w)}return S(p,g,{flush:"post",immediate:!0}),c&&S(l,()=>g(p.value),{flush:"post"}),Q(()=>g(p.value)),p}function kt(e,t,{window:r=h,initialValue:n=""}={}){const a=O(n),o=T(()=>{var i;return I(t)||((i=r==null?void 0:r.document)==null?void 0:i.documentElement)});return S([o,()=>E(e)],([i,s])=>{var u;if(i&&r){const c=(u=r.getComputedStyle(i).getPropertyValue(s))==null?void 0:u.trim();a.value=c||n}},{immediate:!0}),S(a,i=>{var s;(s=o.value)!=null&&s.style&&o.value.style.setProperty(E(e),i)}),a}var pt=Object.defineProperty,vt=Object.defineProperties,mt=Object.getOwnPropertyDescriptors,re=Object.getOwnPropertySymbols,_t=Object.prototype.hasOwnProperty,Ot=Object.prototype.propertyIsEnumerable,ne=(e,t,r)=>t in e?pt(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,gt=(e,t)=>{for(var r in t||(t={}))_t.call(t,r)&&ne(e,r,t[r]);if(re)for(var r of re(t))Ot.call(t,r)&&ne(e,r,t[r]);return e},wt=(e,t)=>vt(e,mt(t));function Vt(e={}){const{valueDark:t="dark",valueLight:r="",window:n=h}=e,a=dt(wt(gt({},e),{onChanged:(s,u)=>{var c;e.onChanged?(c=e.onChanged)==null||c.call(e,s==="dark"):u(s)},modes:{dark:t,light:r}})),o=ye({window:n});return T({get(){return a.value==="dark"},set(s){s===o.value?a.value="auto":a.value=s?"dark":"light"}})}function Lt({document:e=ge}={}){if(!e)return O("visible");const t=O(e.visibilityState);return P(e,"visibilitychange",()=>{t.value=e.visibilityState}),t}var ae=Object.getOwnPropertySymbols,yt=Object.prototype.hasOwnProperty,bt=Object.prototype.propertyIsEnumerable,ht=(e,t)=>{var r={};for(var n in e)yt.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&ae)for(var n of ae(e))t.indexOf(n)<0&&bt.call(e,n)&&(r[n]=e[n]);return r};function Wt(e,t,r={}){const n=r,{window:a=h}=n,o=ht(n,["window"]);let i;const s=x(()=>a&&"ResizeObserver"in a),u=()=>{i&&(i.disconnect(),i=void 0)},c=S(()=>I(e),v=>{u(),s.value&&a&&v&&(i=new ResizeObserver(t),i.observe(v,o))},{immediate:!0,flush:"post"}),d=()=>{u(),c()};return M(d),{isSupported:s,stop:d}}const oe=[["requestFullscreen","exitFullscreen","fullscreenElement","fullscreenEnabled","fullscreenchange","fullscreenerror"],["webkitRequestFullscreen","webkitExitFullscreen","webkitFullscreenElement","webkitFullscreenEnabled","webkitfullscreenchange","webkitfullscreenerror"],["webkitRequestFullScreen","webkitCancelFullScreen","webkitCurrentFullScreenElement","webkitCancelFullScreen","webkitfullscreenchange","webkitfullscreenerror"],["mozRequestFullScreen","mozCancelFullScreen","mozFullScreenElement","mozFullScreenEnabled","mozfullscreenchange","mozfullscreenerror"],["msRequestFullscreen","msExitFullscreen","msFullscreenElement","msFullscreenEnabled","MSFullscreenChange","MSFullscreenError"]];function zt(e,t={}){const{document:r=ge,autoExit:n=!1}=t,a=e||(r==null?void 0:r.querySelector("html")),o=O(!1);let i=oe[0];const s=x(()=>{if(r){for(const _ of oe)if(_[1]in r)return i=_,!0}else return!1;return!1}),[u,c,d,,v]=i;async function l(){!s.value||(r!=null&&r[d]&&await r[c](),o.value=!1)}async function f(){if(!s.value)return;await l();const _=I(a);_&&(await _[u](),o.value=!0)}async function p(){o.value?await l():await f()}return r&&P(r,v,()=>{o.value=!!(r!=null&&r[d])},!1),n&&M(l),{isSupported:s,isFullscreen:o,enter:f,exit:l,toggle:p}}var se=Object.getOwnPropertySymbols,Pt=Object.prototype.hasOwnProperty,St=Object.prototype.propertyIsEnumerable,Et=(e,t)=>{var r={};for(var n in e)Pt.call(e,n)&&t.indexOf(n)<0&&(r[n]=e[n]);if(e!=null&&se)for(var n of se(e))t.indexOf(n)<0&&St.call(e,n)&&(r[n]=e[n]);return r};function Qt(e,t,r={}){const n=r,{window:a=h}=n,o=Et(n,["window"]);let i;const s=x(()=>a&&"MutationObserver"in a),u=()=>{i&&(i.disconnect(),i=void 0)},c=S(()=>I(e),v=>{u(),s.value&&a&&v&&(i=new MutationObserver(t),i.observe(v,o))},{immediate:!0}),d=()=>{u(),c()};return M(d),{isSupported:s,stop:d}}var ie;(function(e){e.UP="UP",e.RIGHT="RIGHT",e.DOWN="DOWN",e.LEFT="LEFT",e.NONE="NONE"})(ie||(ie={}));var $t=Object.defineProperty,le=Object.getOwnPropertySymbols,Ft=Object.prototype.hasOwnProperty,It=Object.prototype.propertyIsEnumerable,ue=(e,t,r)=>t in e?$t(e,t,{enumerable:!0,configurable:!0,writable:!0,value:r}):e[t]=r,jt=(e,t)=>{for(var r in t||(t={}))Ft.call(t,r)&&ue(e,r,t[r]);if(le)for(var r of le(t))It.call(t,r)&&ue(e,r,t[r]);return e};const Ct={easeInSine:[.12,0,.39,0],easeOutSine:[.61,1,.88,1],easeInOutSine:[.37,0,.63,1],easeInQuad:[.11,0,.5,0],easeOutQuad:[.5,1,.89,1],easeInOutQuad:[.45,0,.55,1],easeInCubic:[.32,0,.67,0],easeOutCubic:[.33,1,.68,1],easeInOutCubic:[.65,0,.35,1],easeInQuart:[.5,0,.75,0],easeOutQuart:[.25,1,.5,1],easeInOutQuart:[.76,0,.24,1],easeInQuint:[.64,0,.78,0],easeOutQuint:[.22,1,.36,1],easeInOutQuint:[.83,0,.17,1],easeInExpo:[.7,0,.84,0],easeOutExpo:[.16,1,.3,1],easeInOutExpo:[.87,0,.13,1],easeInCirc:[.55,0,1,.45],easeOutCirc:[0,.55,.45,1],easeInOutCirc:[.85,0,.15,1],easeInBack:[.36,0,.66,-.56],easeOutBack:[.34,1.56,.64,1],easeInOutBack:[.68,-.6,.32,1.6]};jt({linear:Ve},Ct);function Jt(e,t,r,n={}){var a,o,i;const{clone:s=!1,passive:u=!1,eventName:c,deep:d=!1,defaultValue:v}=n,l=ce(),f=r||(l==null?void 0:l.emit)||((a=l==null?void 0:l.$emit)==null?void 0:a.bind(l))||((i=(o=l==null?void 0:l.proxy)==null?void 0:o.$emit)==null?void 0:i.bind(l==null?void 0:l.proxy));let p=c;t||(t="modelValue"),p=c||p||`update:${t.toString()}`;const _=g=>s?ve(s)?s(g):et(g):g,$=()=>De(e[t])?_(e[t]):v;if(u){const g=$(),w=O(g);return S(()=>e[t],y=>w.value=_(y)),S(w,y=>{(y!==e[t]||d)&&f(p,y)},{deep:d}),w}else return T({get(){return $()},set(g){f(p,g)}})}function qt({window:e=h}={}){if(!e)return O(!1);const t=O(e.document.hasFocus());return P(e,"blur",()=>{t.value=!1}),P(e,"focus",()=>{t.value=!0}),t}function Ht(e={}){const{window:t=h,initialWidth:r=1/0,initialHeight:n=1/0,listenOrientation:a=!0,includeScrollbar:o=!0}=e,i=O(r),s=O(n),u=()=>{t&&(o?(i.value=t.innerWidth,s.value=t.innerHeight):(i.value=t.document.documentElement.clientWidth,s.value=t.document.documentElement.clientHeight))};return u(),Q(u),P("resize",u,{passive:!0}),a&&P("orientationchange",u,{passive:!0}),{width:i,height:s}}export{Wt as a,I as b,kt as c,Mt as d,At as e,Qt as f,Lt as g,qt as h,A as i,Tt as j,Jt as k,zt as l,Vt as m,Rt as n,xt as o,Ht as p,Dt as r,M as t,P as u};