urit-qf-ui 0.1.1 → 0.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.d.ts +1 -0
- package/dist/index.umd.cjs +1 -1
- package/package.json +1 -1
package/dist/index.d.ts
CHANGED
|
@@ -18,3 +18,4 @@ export { UInput, UDict, UToggle, UCascader, UDate, FormRender, TableRender, UFie
|
|
|
18
18
|
export type { FormConfig, FormMeta, FormApi, FormLayout, FieldConfig, FieldRule } from './ts/model';
|
|
19
19
|
export { notify, notifyUtil };
|
|
20
20
|
export { Qf, QfInterface };
|
|
21
|
+
export type { QfOptions } from './qf/interface';
|
package/dist/index.umd.cjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
(function(gt,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(gt=typeof globalThis<"u"?globalThis:gt||self,e(gt.YourOrgUI={},gt.Vue))})(this,function(gt,e){"use strict";var ere=Object.defineProperty;var zB=gt=>{throw TypeError(gt)};var tre=(gt,e,Be)=>e in gt?ere(gt,e,{enumerable:!0,configurable:!0,writable:!0,value:Be}):gt[e]=Be;var Ge=(gt,e,Be)=>tre(gt,typeof e!="symbol"?e+"":e,Be),By=(gt,e,Be)=>e.has(gt)||zB("Cannot "+Be);var he=(gt,e,Be)=>(By(gt,e,"read from private field"),Be?Be.call(gt):e.get(gt)),Rt=(gt,e,Be)=>e.has(gt)?zB("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(gt):e.set(gt,Be),kt=(gt,e,Be,ea)=>(By(gt,e,"write to private field"),ea?ea.call(gt,Be):e.set(gt,Be),Be),ut=(gt,e,Be)=>(By(gt,e,"access private method"),Be);var cu=(gt,e,Be,ea)=>({set _(pu){kt(gt,e,pu,Be)},get _(){return he(gt,e,ea)}});const Be={tab:"Tab",enter:"Enter",space:"Space",left:"ArrowLeft",up:"ArrowUp",right:"ArrowRight",down:"ArrowDown",esc:"Escape",delete:"Delete",backspace:"Backspace",numpadEnter:"NumpadEnter",pageUp:"PageUp",pageDown:"PageDown",home:"Home",end:"End"},ea=["left","center","right"],pu=["year","years","month","months","date","dates","week","quarter","quarters","datetime","datetimerange","daterange","monthrange","yearrange","quarterrange"],hu=["sun","mon","tue","wed","thu","fri","sat"],tt="update:modelValue",it="change",Xt="input",Ay=Symbol("INSTALLED_KEY"),Sr=["","default","small","large"];function Py(t,n){var r;const o=e.shallowRef();return e.watchEffect(()=>{o.value=t()},{...n,flush:(r=n==null?void 0:n.flush)!==null&&r!==void 0?r:"sync"}),e.readonly(o)}function vo(t,n){return e.getCurrentScope()?(e.onScopeDispose(t,n),!0):!1}const mu=new WeakMap,ZB=(...t)=>{var n;const r=t[0],o=(n=e.getCurrentInstance())===null||n===void 0?void 0:n.proxy,a=o??e.getCurrentScope();if(a==null&&!e.hasInjectionContext())throw new Error("injectLocal must be called in setup");return a&&mu.has(a)&&r in mu.get(a)?mu.get(a)[r]:e.inject(...t)},bt=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const e_=t=>typeof t<"u",Vy=t=>t!=null,t_=Object.prototype.toString,n_=t=>t_.call(t)==="[object Object]",xi=(t,n,r)=>Math.min(r,Math.max(n,t)),Nn=()=>{};function My(t,n){function r(...o){return new Promise((a,s)=>{Promise.resolve(t(()=>n.apply(this,o),{fn:n,thisArg:this,args:o})).then(a).catch(s)})}return"cancel"in t&&Object.assign(r,{cancel:t.cancel,flush:t.flush,isPending:t.isPending}),r}function r_(t,n={}){let r,o,a=Nn,s=Nn;const l=e.shallowRef(!1),i=u=>{clearTimeout(u),a(),a=Nn};let c;return Object.assign(u=>{const f=e.toValue(t),p=e.toValue(n.maxWait);return r&&i(r),f<=0||p!==void 0&&p<=0?(o&&(i(o),o=void 0),l.value=!1,Promise.resolve(u())):(l.value=!0,new Promise((h,m)=>{a=n.rejectOnCancel?m:h,s=h,c=u,p&&!o&&(o=setTimeout(()=>{r&&i(r),o=void 0,l.value=!1,h(c())},p)),r=setTimeout(()=>{o&&i(o),o=void 0,l.value=!1,h(u())},f)}))},{cancel:()=>{r&&(i(r),r=void 0),o&&(i(o),o=void 0),l.value=!1,s=Nn},flush:()=>{if(l.value){r&&(clearTimeout(r),r=void 0),o&&(clearTimeout(o),o=void 0),l.value=!1;const u=s;a=Nn,s=Nn,u(c())}},isPending:e.shallowReadonly(l)})}function o_(...t){let n=0,r,o=!0,a=Nn,s,l,i,c,d;!e.isRef(t[0])&&typeof t[0]=="object"?{delay:l,trailing:i=!0,leading:c=!0,rejectOnCancel:d=!1}=t[0]:[l,i=!0,c=!0,d=!1]=t;const u=()=>{r&&(clearTimeout(r),r=void 0,a(),a=Nn)};return p=>{const h=e.toValue(l),m=Date.now()-n,g=()=>s=p();return u(),h<=0?(n=Date.now(),g()):(m>h?(n=Date.now(),(c||!o)&&g()):i&&(s=new Promise((y,b)=>{a=d?b:y,r=setTimeout(()=>{n=Date.now(),o=!0,y(g()),u()},Math.max(0,h-m))})),!c&&!r&&(r=setTimeout(()=>o=!0,h)),o=!1,s)}}function $y(t){return t.endsWith("rem")?Number.parseFloat(t)*16:Number.parseFloat(t)}function qa(t){return Array.isArray(t)?t:[t]}function a_(t){return e.getCurrentInstance()}function l_(t){return e.isRef(t)?e.reactive(new Proxy({},{get(n,r,o){return e.unref(Reflect.get(t.value,r,o))},set(n,r,o){return e.isRef(t.value[r])&&!e.isRef(o)?t.value[r].value=o:t.value[r]=o,!0},deleteProperty(n,r){return Reflect.deleteProperty(t.value,r)},has(n,r){return Reflect.has(t.value,r)},ownKeys(){return Object.keys(t.value)},getOwnPropertyDescriptor(){return{enumerable:!0,configurable:!0}}})):e.reactive(t)}function s_(t){return l_(e.computed(t))}function ql(t,n=200,r={}){return My(r_(n,r),t)}function i_(t,n=200,r={}){const o=e.ref(e.toValue(t)),a=ql(()=>{o.value=t.value},n,r);return e.watch(t,()=>a()),e.shallowReadonly(o)}function Dy(t,n=200,r=!1,o=!0,a=!1){return My(o_(n,r,o,a),t)}function gu(t,n=!0,r){a_()?e.onMounted(t,r):n?t():e.nextTick(t)}function c_(t,n=1e3,r={}){const{immediate:o=!0,immediateCallback:a=!1}=r;let s=null;const l=e.shallowRef(!1);function i(){s&&(clearInterval(s),s=null)}function c(){l.value=!1,i()}function d(){const u=e.toValue(n);u<=0||(l.value=!0,a&&t(),i(),l.value&&(s=setInterval(t,u)))}return o&&bt&&d(),(e.isRef(n)||typeof n=="function")&&vo(e.watch(n,()=>{l.value&&bt&&d()})),vo(c),{isActive:e.shallowReadonly(l),pause:c,resume:d}}function Ya(t,n,r={}){const{immediate:o=!0,immediateCallback:a=!1}=r,s=e.shallowRef(!1);let l;function i(){l&&(clearTimeout(l),l=void 0)}function c(){s.value=!1,i()}function d(...u){a&&t(),i(),s.value=!0,l=setTimeout(()=>{s.value=!1,l=void 0,t(...u)},e.toValue(n))}return o&&(s.value=!0,bt&&d()),vo(c),{isPending:e.shallowReadonly(s),start:d,stop:c}}function d_(t,n,r){return e.watch(t,n,{...r,immediate:!0})}const fr=bt?window:void 0,u_=bt?window.document:void 0;function en(t){var n;const r=e.toValue(t);return(n=r==null?void 0:r.$el)!==null&&n!==void 0?n:r}function St(...t){const n=(o,a,s,l)=>(o.addEventListener(a,s,l),()=>o.removeEventListener(a,s,l)),r=e.computed(()=>{const o=qa(e.toValue(t[0])).filter(a=>a!=null);return o.every(a=>typeof a!="string")?o:void 0});return d_(()=>{var o,a;return[(o=(a=r.value)===null||a===void 0?void 0:a.map(s=>en(s)))!==null&&o!==void 0?o:[fr].filter(s=>s!=null),qa(e.toValue(r.value?t[1]:t[0])),qa(e.unref(r.value?t[2]:t[1])),e.toValue(r.value?t[3]:t[2])]},([o,a,s,l],i,c)=>{if(!(o!=null&&o.length)||!(a!=null&&a.length)||!(s!=null&&s.length))return;const d=n_(l)?{...l}:l,u=o.flatMap(f=>a.flatMap(p=>s.map(h=>n(f,p,h,d))));c(()=>{u.forEach(f=>f())})},{flush:"post"})}function yu(t,n,r={}){const{window:o=fr,ignore:a=[],capture:s=!0,detectIframe:l=!1,controls:i=!1}=r;if(!o)return i?{stop:Nn,cancel:Nn,trigger:Nn}:Nn;let c=!0;const d=y=>e.toValue(a).some(b=>{if(typeof b=="string")return Array.from(o.document.querySelectorAll(b)).some(w=>w===y.target||y.composedPath().includes(w));{const w=en(b);return w&&(y.target===w||y.composedPath().includes(w))}});function u(y){const b=e.toValue(y);return b&&b.$.subTree.shapeFlag===16}function f(y,b){const w=e.toValue(y),S=w.$.subTree&&w.$.subTree.children;return S==null||!Array.isArray(S)?!1:S.some(C=>C.el===b.target||b.composedPath().includes(C.el))}const p=y=>{const b=en(t);if(y.target!=null&&!(!(b instanceof Element)&&u(t)&&f(t,y))&&!(!b||b===y.target||y.composedPath().includes(b))){if("detail"in y&&y.detail===0&&(c=!d(y)),!c){c=!0;return}n(y)}};let h=!1;const m=[St(o,"click",y=>{h||(h=!0,setTimeout(()=>{h=!1},0),p(y))},{passive:!0,capture:s}),St(o,"pointerdown",y=>{const b=en(t);c=!d(y)&&!!(b&&!y.composedPath().includes(b))},{passive:!0}),l&&St(o,"blur",y=>{setTimeout(()=>{const b=en(t);let w=o.document.activeElement;for(;w!=null&&w.shadowRoot;)w=w.shadowRoot.activeElement;(w==null?void 0:w.tagName)==="IFRAME"&&!(b!=null&&b.contains(o.document.activeElement))&&n(y)},0)},{passive:!0})].filter(Boolean),g=()=>m.forEach(y=>y());return i?{stop:g,cancel:()=>{c=!1},trigger:y=>{c=!0,p(y),c=!1}}:g}function f_(){const t=e.shallowRef(!1),n=e.getCurrentInstance();return n&&e.onMounted(()=>{t.value=!0},n),t}function Ni(t){const n=f_();return e.computed(()=>(n.value,!!t()))}function Yl(t,n,r={}){const{window:o=fr,...a}=r;let s;const l=Ni(()=>o&&"MutationObserver"in o),i=()=>{s&&(s.disconnect(),s=void 0)},c=e.watch(e.computed(()=>{const f=qa(e.toValue(t)).map(en).filter(Vy);return new Set(f)}),f=>{i(),l.value&&f.size&&(s=new MutationObserver(n),f.forEach(p=>s.observe(p,a)))},{immediate:!0,flush:"post"}),d=()=>s==null?void 0:s.takeRecords(),u=()=>{c(),i()};return vo(u),{isSupported:l,stop:u,takeRecords:d}}function p_(t,n,r={}){const{window:o=fr,document:a=o==null?void 0:o.document,flush:s="sync"}=r;if(!o||!a)return Nn;let l;const i=u=>{l==null||l(),l=u},c=e.watchEffect(()=>{const u=en(t);if(u){const{stop:f}=Yl(a,p=>{p.map(h=>[...h.removedNodes]).flat().some(h=>h===u||h.contains(u))&&n(p)},{window:o,childList:!0,subtree:!0});i(f)}},{flush:s}),d=()=>{c(),i()};return vo(d),d}function h_(t={}){var n;const{window:r=fr,deep:o=!0,triggerOnRemoval:a=!1}=t,s=(n=t.document)!==null&&n!==void 0?n:r==null?void 0:r.document,l=()=>{let d=s==null?void 0:s.activeElement;if(o)for(var u;d!=null&&d.shadowRoot;)d=d==null||(u=d.shadowRoot)===null||u===void 0?void 0:u.activeElement;return d},i=e.shallowRef(),c=()=>{i.value=l()};if(r){const d={capture:!0,passive:!0};St(r,"blur",u=>{u.relatedTarget===null&&c()},d),St(r,"focus",c,d)}return a&&p_(i,c,{document:s}),c(),i}const m_=Symbol("vueuse-ssr-width");function g_(){const t=e.hasInjectionContext()?ZB(m_,null):null;return typeof t=="number"?t:void 0}function y_(t,n={}){const{window:r=fr,ssrWidth:o=g_()}=n,a=Ni(()=>r&&"matchMedia"in r&&typeof r.matchMedia=="function"),s=e.shallowRef(typeof o=="number"),l=e.shallowRef(),i=e.shallowRef(!1),c=d=>{i.value=d.matches};return e.watchEffect(()=>{if(s.value){s.value=!a.value;const d=e.toValue(t).split(",");i.value=d.some(u=>{const f=u.includes("not all"),p=u.match(/\(\s*min-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/),h=u.match(/\(\s*max-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/);let m=!!(p||h);return p&&m&&(m=o>=$y(p[1])),h&&m&&(m=o<=$y(h[1])),f?!m:m});return}a.value&&(l.value=r.matchMedia(e.toValue(t)),i.value=l.value.matches)}),St(l,"change",c,{passive:!0}),e.computed(()=>i.value)}function b_(t){return JSON.parse(JSON.stringify(t))}function w_(t,n,r={}){const{window:o=fr,initialValue:a,observe:s=!1}=r,l=e.shallowRef(a),i=e.computed(()=>{var d;return en(n)||(o==null||(d=o.document)===null||d===void 0?void 0:d.documentElement)});function c(){const d=e.toValue(t),u=e.toValue(i);if(u&&o&&d){var f;const p=(f=o.getComputedStyle(u).getPropertyValue(d))===null||f===void 0?void 0:f.trim();l.value=p||l.value||a}}return s&&Yl(i,c,{attributeFilter:["style","class"],window:o}),e.watch([i,()=>e.toValue(t)],(d,u)=>{u[0]&&u[1]&&u[0].style.removeProperty(u[1]),c()},{immediate:!0}),e.watch([l,i],([d,u])=>{const f=e.toValue(t);u!=null&&u.style&&f&&(d==null?u.style.removeProperty(f):u.style.setProperty(f,d))},{immediate:!0}),l}function C_(t={}){const{document:n=u_}=t;if(!n)return e.shallowRef("visible");const r=e.shallowRef(n.visibilityState);return St(n,"visibilitychange",()=>{r.value=n.visibilityState},{passive:!0}),r}function Ot(t,n,r={}){const{window:o=fr,...a}=r;let s;const l=Ni(()=>o&&"ResizeObserver"in o),i=()=>{s&&(s.disconnect(),s=void 0)},c=e.watch(e.computed(()=>{const u=e.toValue(t);return Array.isArray(u)?u.map(f=>en(f)):[en(u)]}),u=>{if(i(),l.value&&o){s=new ResizeObserver(n);for(const f of u)f&&s.observe(f,a)}},{immediate:!0,flush:"post"}),d=()=>{i(),c()};return vo(d),{isSupported:l,stop:d}}function Ly(t,n={}){const{reset:r=!0,windowResize:o=!0,windowScroll:a=!0,immediate:s=!0,updateTiming:l="sync"}=n,i=e.shallowRef(0),c=e.shallowRef(0),d=e.shallowRef(0),u=e.shallowRef(0),f=e.shallowRef(0),p=e.shallowRef(0),h=e.shallowRef(0),m=e.shallowRef(0);function g(){const b=en(t);if(!b){r&&(i.value=0,c.value=0,d.value=0,u.value=0,f.value=0,p.value=0,h.value=0,m.value=0);return}const w=b.getBoundingClientRect();i.value=w.height,c.value=w.bottom,d.value=w.left,u.value=w.right,f.value=w.top,p.value=w.width,h.value=w.x,m.value=w.y}function y(){l==="sync"?g():l==="next-frame"&&requestAnimationFrame(()=>g())}return Ot(t,y),e.watch(()=>en(t),b=>!b&&y()),Yl(t,y,{attributeFilter:["style","class"]}),a&&St("scroll",y,{capture:!0,passive:!0}),o&&St("resize",y,{passive:!0}),gu(()=>{s&&y()}),{height:i,bottom:c,left:d,right:u,top:f,width:p,x:h,y:m,update:y}}function Bi(t,n={width:0,height:0},r={}){const{window:o=fr,box:a="content-box"}=r,s=e.computed(()=>{var f;return(f=en(t))===null||f===void 0||(f=f.namespaceURI)===null||f===void 0?void 0:f.includes("svg")}),l=e.shallowRef(n.width),i=e.shallowRef(n.height),{stop:c}=Ot(t,([f])=>{const p=a==="border-box"?f.borderBoxSize:a==="content-box"?f.contentBoxSize:f.devicePixelContentBoxSize;if(o&&s.value){const h=en(t);if(h){const m=h.getBoundingClientRect();l.value=m.width,i.value=m.height}}else if(p){const h=qa(p);l.value=h.reduce((m,{inlineSize:g})=>m+g,0),i.value=h.reduce((m,{blockSize:g})=>m+g,0)}else l.value=f.contentRect.width,i.value=f.contentRect.height},r);gu(()=>{const f=en(t);if(f&&"offsetWidth"in f)if(a==="content-box"&&o){const p=o.getComputedStyle(f),h=Number.parseFloat(p.paddingLeft)+Number.parseFloat(p.paddingRight),m=Number.parseFloat(p.paddingTop)+Number.parseFloat(p.paddingBottom),g=Number.parseFloat(p.borderLeftWidth)+Number.parseFloat(p.borderRightWidth),y=Number.parseFloat(p.borderTopWidth)+Number.parseFloat(p.borderBottomWidth);l.value=f.offsetWidth-h-g,i.value=f.offsetHeight-m-y}else l.value=f.offsetWidth,i.value=f.offsetHeight;else f&&(l.value=n.width,i.value=n.height)});const d=e.watch(()=>en(t),f=>{l.value=f?n.width:0,i.value=f?n.height:0});function u(){c(),d()}return{width:l,height:i,stop:u}}function k_(t,n,r={}){const{root:o,rootMargin:a,threshold:s=0,window:l=fr,immediate:i=!0}=r,c=Ni(()=>l&&"IntersectionObserver"in l),d=e.computed(()=>qa(e.toValue(t)).map(en).filter(Vy));let u=Nn;const f=e.shallowRef(i),p=c.value?e.watch(()=>[d.value,en(o),e.toValue(a),f.value],([m,g,y])=>{if(u(),!f.value||!m.length)return;const b=new IntersectionObserver(n,{root:en(g),rootMargin:y,threshold:s});m.forEach(w=>w&&b.observe(w)),u=()=>{b.disconnect(),u=Nn}},{immediate:i,flush:"post"}):Nn,h=()=>{u(),p(),f.value=!1};return vo(h),{isSupported:c,isActive:f,pause(){u(),f.value=!1},resume(){f.value=!0},stop:h}}function S_(t,n,r,o={}){var a,s;const{clone:l=!1,passive:i=!1,eventName:c,deep:d=!1,defaultValue:u,shouldEmit:f}=o,p=e.getCurrentInstance(),h=(p==null?void 0:p.emit)||(p==null||(a=p.$emit)===null||a===void 0?void 0:a.bind(p))||(p==null||(s=p.proxy)===null||s===void 0||(s=s.$emit)===null||s===void 0?void 0:s.bind(p==null?void 0:p.proxy));let m=c;m=m||`update:${n.toString()}`;const g=w=>l?typeof l=="function"?l(w):b_(w):w,y=()=>e_(t[n])?g(t[n]):u,b=w=>{f?f(w)&&h(m,w):h(m,w)};if(i){const w=e.ref(y());let S=!1;return e.watch(()=>t[n],C=>{S||(S=!0,w.value=g(C),e.nextTick(()=>S=!1))}),e.watch(w,C=>{!S&&(C!==t[n]||d)&&b(C)},{deep:d}),w}else return e.computed({get(){return y()},set(w){b(w)}})}function E_(t={}){const{window:n=fr}=t;if(!n)return e.shallowRef(!1);const r=e.shallowRef(n.document.hasFocus()),o={passive:!0};return St(n,"blur",()=>{r.value=!1},o),St(n,"focus",()=>{r.value=!0},o),r}function bu(t={}){const{window:n=fr,initialWidth:r=Number.POSITIVE_INFINITY,initialHeight:o=Number.POSITIVE_INFINITY,listenOrientation:a=!0,includeScrollbar:s=!0,type:l="inner"}=t,i=e.shallowRef(r),c=e.shallowRef(o),d=()=>{if(n)if(l==="outer")i.value=n.outerWidth,c.value=n.outerHeight;else if(l==="visual"&&n.visualViewport){const{width:f,height:p,scale:h}=n.visualViewport;i.value=Math.round(f*h),c.value=Math.round(p*h)}else s?(i.value=n.innerWidth,c.value=n.innerHeight):(i.value=n.document.documentElement.clientWidth,c.value=n.document.documentElement.clientHeight)};d(),gu(d);const u={passive:!0};return St("resize",d,u),n&&l==="visual"&&n.visualViewport&&St(n.visualViewport,"resize",d,u),a&&e.watch(y_("(orientation: portrait)"),()=>d()),{width:i,height:c}}const _i=()=>bt&&/firefox/i.test(window.navigator.userAgent),zy=()=>bt&&/android/i.test(window.navigator.userAgent);/**
|
|
1
|
+
(function(gt,e){typeof exports=="object"&&typeof module<"u"?e(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],e):(gt=typeof globalThis<"u"?globalThis:gt||self,e(gt.UritQfUI={},gt.Vue))})(this,function(gt,e){"use strict";var ere=Object.defineProperty;var zB=gt=>{throw TypeError(gt)};var tre=(gt,e,Be)=>e in gt?ere(gt,e,{enumerable:!0,configurable:!0,writable:!0,value:Be}):gt[e]=Be;var Ge=(gt,e,Be)=>tre(gt,typeof e!="symbol"?e+"":e,Be),By=(gt,e,Be)=>e.has(gt)||zB("Cannot "+Be);var he=(gt,e,Be)=>(By(gt,e,"read from private field"),Be?Be.call(gt):e.get(gt)),Rt=(gt,e,Be)=>e.has(gt)?zB("Cannot add the same private member more than once"):e instanceof WeakSet?e.add(gt):e.set(gt,Be),kt=(gt,e,Be,ea)=>(By(gt,e,"write to private field"),ea?ea.call(gt,Be):e.set(gt,Be),Be),ut=(gt,e,Be)=>(By(gt,e,"access private method"),Be);var cu=(gt,e,Be,ea)=>({set _(pu){kt(gt,e,pu,Be)},get _(){return he(gt,e,ea)}});const Be={tab:"Tab",enter:"Enter",space:"Space",left:"ArrowLeft",up:"ArrowUp",right:"ArrowRight",down:"ArrowDown",esc:"Escape",delete:"Delete",backspace:"Backspace",numpadEnter:"NumpadEnter",pageUp:"PageUp",pageDown:"PageDown",home:"Home",end:"End"},ea=["left","center","right"],pu=["year","years","month","months","date","dates","week","quarter","quarters","datetime","datetimerange","daterange","monthrange","yearrange","quarterrange"],hu=["sun","mon","tue","wed","thu","fri","sat"],tt="update:modelValue",it="change",Xt="input",Ay=Symbol("INSTALLED_KEY"),Sr=["","default","small","large"];function Py(t,n){var r;const o=e.shallowRef();return e.watchEffect(()=>{o.value=t()},{...n,flush:(r=n==null?void 0:n.flush)!==null&&r!==void 0?r:"sync"}),e.readonly(o)}function vo(t,n){return e.getCurrentScope()?(e.onScopeDispose(t,n),!0):!1}const mu=new WeakMap,ZB=(...t)=>{var n;const r=t[0],o=(n=e.getCurrentInstance())===null||n===void 0?void 0:n.proxy,a=o??e.getCurrentScope();if(a==null&&!e.hasInjectionContext())throw new Error("injectLocal must be called in setup");return a&&mu.has(a)&&r in mu.get(a)?mu.get(a)[r]:e.inject(...t)},bt=typeof window<"u"&&typeof document<"u";typeof WorkerGlobalScope<"u"&&globalThis instanceof WorkerGlobalScope;const e_=t=>typeof t<"u",Vy=t=>t!=null,t_=Object.prototype.toString,n_=t=>t_.call(t)==="[object Object]",xi=(t,n,r)=>Math.min(r,Math.max(n,t)),Nn=()=>{};function My(t,n){function r(...o){return new Promise((a,s)=>{Promise.resolve(t(()=>n.apply(this,o),{fn:n,thisArg:this,args:o})).then(a).catch(s)})}return"cancel"in t&&Object.assign(r,{cancel:t.cancel,flush:t.flush,isPending:t.isPending}),r}function r_(t,n={}){let r,o,a=Nn,s=Nn;const l=e.shallowRef(!1),i=u=>{clearTimeout(u),a(),a=Nn};let c;return Object.assign(u=>{const f=e.toValue(t),p=e.toValue(n.maxWait);return r&&i(r),f<=0||p!==void 0&&p<=0?(o&&(i(o),o=void 0),l.value=!1,Promise.resolve(u())):(l.value=!0,new Promise((h,m)=>{a=n.rejectOnCancel?m:h,s=h,c=u,p&&!o&&(o=setTimeout(()=>{r&&i(r),o=void 0,l.value=!1,h(c())},p)),r=setTimeout(()=>{o&&i(o),o=void 0,l.value=!1,h(u())},f)}))},{cancel:()=>{r&&(i(r),r=void 0),o&&(i(o),o=void 0),l.value=!1,s=Nn},flush:()=>{if(l.value){r&&(clearTimeout(r),r=void 0),o&&(clearTimeout(o),o=void 0),l.value=!1;const u=s;a=Nn,s=Nn,u(c())}},isPending:e.shallowReadonly(l)})}function o_(...t){let n=0,r,o=!0,a=Nn,s,l,i,c,d;!e.isRef(t[0])&&typeof t[0]=="object"?{delay:l,trailing:i=!0,leading:c=!0,rejectOnCancel:d=!1}=t[0]:[l,i=!0,c=!0,d=!1]=t;const u=()=>{r&&(clearTimeout(r),r=void 0,a(),a=Nn)};return p=>{const h=e.toValue(l),m=Date.now()-n,g=()=>s=p();return u(),h<=0?(n=Date.now(),g()):(m>h?(n=Date.now(),(c||!o)&&g()):i&&(s=new Promise((y,b)=>{a=d?b:y,r=setTimeout(()=>{n=Date.now(),o=!0,y(g()),u()},Math.max(0,h-m))})),!c&&!r&&(r=setTimeout(()=>o=!0,h)),o=!1,s)}}function $y(t){return t.endsWith("rem")?Number.parseFloat(t)*16:Number.parseFloat(t)}function qa(t){return Array.isArray(t)?t:[t]}function a_(t){return e.getCurrentInstance()}function l_(t){return e.isRef(t)?e.reactive(new Proxy({},{get(n,r,o){return e.unref(Reflect.get(t.value,r,o))},set(n,r,o){return e.isRef(t.value[r])&&!e.isRef(o)?t.value[r].value=o:t.value[r]=o,!0},deleteProperty(n,r){return Reflect.deleteProperty(t.value,r)},has(n,r){return Reflect.has(t.value,r)},ownKeys(){return Object.keys(t.value)},getOwnPropertyDescriptor(){return{enumerable:!0,configurable:!0}}})):e.reactive(t)}function s_(t){return l_(e.computed(t))}function ql(t,n=200,r={}){return My(r_(n,r),t)}function i_(t,n=200,r={}){const o=e.ref(e.toValue(t)),a=ql(()=>{o.value=t.value},n,r);return e.watch(t,()=>a()),e.shallowReadonly(o)}function Dy(t,n=200,r=!1,o=!0,a=!1){return My(o_(n,r,o,a),t)}function gu(t,n=!0,r){a_()?e.onMounted(t,r):n?t():e.nextTick(t)}function c_(t,n=1e3,r={}){const{immediate:o=!0,immediateCallback:a=!1}=r;let s=null;const l=e.shallowRef(!1);function i(){s&&(clearInterval(s),s=null)}function c(){l.value=!1,i()}function d(){const u=e.toValue(n);u<=0||(l.value=!0,a&&t(),i(),l.value&&(s=setInterval(t,u)))}return o&&bt&&d(),(e.isRef(n)||typeof n=="function")&&vo(e.watch(n,()=>{l.value&&bt&&d()})),vo(c),{isActive:e.shallowReadonly(l),pause:c,resume:d}}function Ya(t,n,r={}){const{immediate:o=!0,immediateCallback:a=!1}=r,s=e.shallowRef(!1);let l;function i(){l&&(clearTimeout(l),l=void 0)}function c(){s.value=!1,i()}function d(...u){a&&t(),i(),s.value=!0,l=setTimeout(()=>{s.value=!1,l=void 0,t(...u)},e.toValue(n))}return o&&(s.value=!0,bt&&d()),vo(c),{isPending:e.shallowReadonly(s),start:d,stop:c}}function d_(t,n,r){return e.watch(t,n,{...r,immediate:!0})}const fr=bt?window:void 0,u_=bt?window.document:void 0;function en(t){var n;const r=e.toValue(t);return(n=r==null?void 0:r.$el)!==null&&n!==void 0?n:r}function St(...t){const n=(o,a,s,l)=>(o.addEventListener(a,s,l),()=>o.removeEventListener(a,s,l)),r=e.computed(()=>{const o=qa(e.toValue(t[0])).filter(a=>a!=null);return o.every(a=>typeof a!="string")?o:void 0});return d_(()=>{var o,a;return[(o=(a=r.value)===null||a===void 0?void 0:a.map(s=>en(s)))!==null&&o!==void 0?o:[fr].filter(s=>s!=null),qa(e.toValue(r.value?t[1]:t[0])),qa(e.unref(r.value?t[2]:t[1])),e.toValue(r.value?t[3]:t[2])]},([o,a,s,l],i,c)=>{if(!(o!=null&&o.length)||!(a!=null&&a.length)||!(s!=null&&s.length))return;const d=n_(l)?{...l}:l,u=o.flatMap(f=>a.flatMap(p=>s.map(h=>n(f,p,h,d))));c(()=>{u.forEach(f=>f())})},{flush:"post"})}function yu(t,n,r={}){const{window:o=fr,ignore:a=[],capture:s=!0,detectIframe:l=!1,controls:i=!1}=r;if(!o)return i?{stop:Nn,cancel:Nn,trigger:Nn}:Nn;let c=!0;const d=y=>e.toValue(a).some(b=>{if(typeof b=="string")return Array.from(o.document.querySelectorAll(b)).some(w=>w===y.target||y.composedPath().includes(w));{const w=en(b);return w&&(y.target===w||y.composedPath().includes(w))}});function u(y){const b=e.toValue(y);return b&&b.$.subTree.shapeFlag===16}function f(y,b){const w=e.toValue(y),S=w.$.subTree&&w.$.subTree.children;return S==null||!Array.isArray(S)?!1:S.some(C=>C.el===b.target||b.composedPath().includes(C.el))}const p=y=>{const b=en(t);if(y.target!=null&&!(!(b instanceof Element)&&u(t)&&f(t,y))&&!(!b||b===y.target||y.composedPath().includes(b))){if("detail"in y&&y.detail===0&&(c=!d(y)),!c){c=!0;return}n(y)}};let h=!1;const m=[St(o,"click",y=>{h||(h=!0,setTimeout(()=>{h=!1},0),p(y))},{passive:!0,capture:s}),St(o,"pointerdown",y=>{const b=en(t);c=!d(y)&&!!(b&&!y.composedPath().includes(b))},{passive:!0}),l&&St(o,"blur",y=>{setTimeout(()=>{const b=en(t);let w=o.document.activeElement;for(;w!=null&&w.shadowRoot;)w=w.shadowRoot.activeElement;(w==null?void 0:w.tagName)==="IFRAME"&&!(b!=null&&b.contains(o.document.activeElement))&&n(y)},0)},{passive:!0})].filter(Boolean),g=()=>m.forEach(y=>y());return i?{stop:g,cancel:()=>{c=!1},trigger:y=>{c=!0,p(y),c=!1}}:g}function f_(){const t=e.shallowRef(!1),n=e.getCurrentInstance();return n&&e.onMounted(()=>{t.value=!0},n),t}function Ni(t){const n=f_();return e.computed(()=>(n.value,!!t()))}function Yl(t,n,r={}){const{window:o=fr,...a}=r;let s;const l=Ni(()=>o&&"MutationObserver"in o),i=()=>{s&&(s.disconnect(),s=void 0)},c=e.watch(e.computed(()=>{const f=qa(e.toValue(t)).map(en).filter(Vy);return new Set(f)}),f=>{i(),l.value&&f.size&&(s=new MutationObserver(n),f.forEach(p=>s.observe(p,a)))},{immediate:!0,flush:"post"}),d=()=>s==null?void 0:s.takeRecords(),u=()=>{c(),i()};return vo(u),{isSupported:l,stop:u,takeRecords:d}}function p_(t,n,r={}){const{window:o=fr,document:a=o==null?void 0:o.document,flush:s="sync"}=r;if(!o||!a)return Nn;let l;const i=u=>{l==null||l(),l=u},c=e.watchEffect(()=>{const u=en(t);if(u){const{stop:f}=Yl(a,p=>{p.map(h=>[...h.removedNodes]).flat().some(h=>h===u||h.contains(u))&&n(p)},{window:o,childList:!0,subtree:!0});i(f)}},{flush:s}),d=()=>{c(),i()};return vo(d),d}function h_(t={}){var n;const{window:r=fr,deep:o=!0,triggerOnRemoval:a=!1}=t,s=(n=t.document)!==null&&n!==void 0?n:r==null?void 0:r.document,l=()=>{let d=s==null?void 0:s.activeElement;if(o)for(var u;d!=null&&d.shadowRoot;)d=d==null||(u=d.shadowRoot)===null||u===void 0?void 0:u.activeElement;return d},i=e.shallowRef(),c=()=>{i.value=l()};if(r){const d={capture:!0,passive:!0};St(r,"blur",u=>{u.relatedTarget===null&&c()},d),St(r,"focus",c,d)}return a&&p_(i,c,{document:s}),c(),i}const m_=Symbol("vueuse-ssr-width");function g_(){const t=e.hasInjectionContext()?ZB(m_,null):null;return typeof t=="number"?t:void 0}function y_(t,n={}){const{window:r=fr,ssrWidth:o=g_()}=n,a=Ni(()=>r&&"matchMedia"in r&&typeof r.matchMedia=="function"),s=e.shallowRef(typeof o=="number"),l=e.shallowRef(),i=e.shallowRef(!1),c=d=>{i.value=d.matches};return e.watchEffect(()=>{if(s.value){s.value=!a.value;const d=e.toValue(t).split(",");i.value=d.some(u=>{const f=u.includes("not all"),p=u.match(/\(\s*min-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/),h=u.match(/\(\s*max-width:\s*(-?\d+(?:\.\d*)?[a-z]+\s*)\)/);let m=!!(p||h);return p&&m&&(m=o>=$y(p[1])),h&&m&&(m=o<=$y(h[1])),f?!m:m});return}a.value&&(l.value=r.matchMedia(e.toValue(t)),i.value=l.value.matches)}),St(l,"change",c,{passive:!0}),e.computed(()=>i.value)}function b_(t){return JSON.parse(JSON.stringify(t))}function w_(t,n,r={}){const{window:o=fr,initialValue:a,observe:s=!1}=r,l=e.shallowRef(a),i=e.computed(()=>{var d;return en(n)||(o==null||(d=o.document)===null||d===void 0?void 0:d.documentElement)});function c(){const d=e.toValue(t),u=e.toValue(i);if(u&&o&&d){var f;const p=(f=o.getComputedStyle(u).getPropertyValue(d))===null||f===void 0?void 0:f.trim();l.value=p||l.value||a}}return s&&Yl(i,c,{attributeFilter:["style","class"],window:o}),e.watch([i,()=>e.toValue(t)],(d,u)=>{u[0]&&u[1]&&u[0].style.removeProperty(u[1]),c()},{immediate:!0}),e.watch([l,i],([d,u])=>{const f=e.toValue(t);u!=null&&u.style&&f&&(d==null?u.style.removeProperty(f):u.style.setProperty(f,d))},{immediate:!0}),l}function C_(t={}){const{document:n=u_}=t;if(!n)return e.shallowRef("visible");const r=e.shallowRef(n.visibilityState);return St(n,"visibilitychange",()=>{r.value=n.visibilityState},{passive:!0}),r}function Ot(t,n,r={}){const{window:o=fr,...a}=r;let s;const l=Ni(()=>o&&"ResizeObserver"in o),i=()=>{s&&(s.disconnect(),s=void 0)},c=e.watch(e.computed(()=>{const u=e.toValue(t);return Array.isArray(u)?u.map(f=>en(f)):[en(u)]}),u=>{if(i(),l.value&&o){s=new ResizeObserver(n);for(const f of u)f&&s.observe(f,a)}},{immediate:!0,flush:"post"}),d=()=>{i(),c()};return vo(d),{isSupported:l,stop:d}}function Ly(t,n={}){const{reset:r=!0,windowResize:o=!0,windowScroll:a=!0,immediate:s=!0,updateTiming:l="sync"}=n,i=e.shallowRef(0),c=e.shallowRef(0),d=e.shallowRef(0),u=e.shallowRef(0),f=e.shallowRef(0),p=e.shallowRef(0),h=e.shallowRef(0),m=e.shallowRef(0);function g(){const b=en(t);if(!b){r&&(i.value=0,c.value=0,d.value=0,u.value=0,f.value=0,p.value=0,h.value=0,m.value=0);return}const w=b.getBoundingClientRect();i.value=w.height,c.value=w.bottom,d.value=w.left,u.value=w.right,f.value=w.top,p.value=w.width,h.value=w.x,m.value=w.y}function y(){l==="sync"?g():l==="next-frame"&&requestAnimationFrame(()=>g())}return Ot(t,y),e.watch(()=>en(t),b=>!b&&y()),Yl(t,y,{attributeFilter:["style","class"]}),a&&St("scroll",y,{capture:!0,passive:!0}),o&&St("resize",y,{passive:!0}),gu(()=>{s&&y()}),{height:i,bottom:c,left:d,right:u,top:f,width:p,x:h,y:m,update:y}}function Bi(t,n={width:0,height:0},r={}){const{window:o=fr,box:a="content-box"}=r,s=e.computed(()=>{var f;return(f=en(t))===null||f===void 0||(f=f.namespaceURI)===null||f===void 0?void 0:f.includes("svg")}),l=e.shallowRef(n.width),i=e.shallowRef(n.height),{stop:c}=Ot(t,([f])=>{const p=a==="border-box"?f.borderBoxSize:a==="content-box"?f.contentBoxSize:f.devicePixelContentBoxSize;if(o&&s.value){const h=en(t);if(h){const m=h.getBoundingClientRect();l.value=m.width,i.value=m.height}}else if(p){const h=qa(p);l.value=h.reduce((m,{inlineSize:g})=>m+g,0),i.value=h.reduce((m,{blockSize:g})=>m+g,0)}else l.value=f.contentRect.width,i.value=f.contentRect.height},r);gu(()=>{const f=en(t);if(f&&"offsetWidth"in f)if(a==="content-box"&&o){const p=o.getComputedStyle(f),h=Number.parseFloat(p.paddingLeft)+Number.parseFloat(p.paddingRight),m=Number.parseFloat(p.paddingTop)+Number.parseFloat(p.paddingBottom),g=Number.parseFloat(p.borderLeftWidth)+Number.parseFloat(p.borderRightWidth),y=Number.parseFloat(p.borderTopWidth)+Number.parseFloat(p.borderBottomWidth);l.value=f.offsetWidth-h-g,i.value=f.offsetHeight-m-y}else l.value=f.offsetWidth,i.value=f.offsetHeight;else f&&(l.value=n.width,i.value=n.height)});const d=e.watch(()=>en(t),f=>{l.value=f?n.width:0,i.value=f?n.height:0});function u(){c(),d()}return{width:l,height:i,stop:u}}function k_(t,n,r={}){const{root:o,rootMargin:a,threshold:s=0,window:l=fr,immediate:i=!0}=r,c=Ni(()=>l&&"IntersectionObserver"in l),d=e.computed(()=>qa(e.toValue(t)).map(en).filter(Vy));let u=Nn;const f=e.shallowRef(i),p=c.value?e.watch(()=>[d.value,en(o),e.toValue(a),f.value],([m,g,y])=>{if(u(),!f.value||!m.length)return;const b=new IntersectionObserver(n,{root:en(g),rootMargin:y,threshold:s});m.forEach(w=>w&&b.observe(w)),u=()=>{b.disconnect(),u=Nn}},{immediate:i,flush:"post"}):Nn,h=()=>{u(),p(),f.value=!1};return vo(h),{isSupported:c,isActive:f,pause(){u(),f.value=!1},resume(){f.value=!0},stop:h}}function S_(t,n,r,o={}){var a,s;const{clone:l=!1,passive:i=!1,eventName:c,deep:d=!1,defaultValue:u,shouldEmit:f}=o,p=e.getCurrentInstance(),h=(p==null?void 0:p.emit)||(p==null||(a=p.$emit)===null||a===void 0?void 0:a.bind(p))||(p==null||(s=p.proxy)===null||s===void 0||(s=s.$emit)===null||s===void 0?void 0:s.bind(p==null?void 0:p.proxy));let m=c;m=m||`update:${n.toString()}`;const g=w=>l?typeof l=="function"?l(w):b_(w):w,y=()=>e_(t[n])?g(t[n]):u,b=w=>{f?f(w)&&h(m,w):h(m,w)};if(i){const w=e.ref(y());let S=!1;return e.watch(()=>t[n],C=>{S||(S=!0,w.value=g(C),e.nextTick(()=>S=!1))}),e.watch(w,C=>{!S&&(C!==t[n]||d)&&b(C)},{deep:d}),w}else return e.computed({get(){return y()},set(w){b(w)}})}function E_(t={}){const{window:n=fr}=t;if(!n)return e.shallowRef(!1);const r=e.shallowRef(n.document.hasFocus()),o={passive:!0};return St(n,"blur",()=>{r.value=!1},o),St(n,"focus",()=>{r.value=!0},o),r}function bu(t={}){const{window:n=fr,initialWidth:r=Number.POSITIVE_INFINITY,initialHeight:o=Number.POSITIVE_INFINITY,listenOrientation:a=!0,includeScrollbar:s=!0,type:l="inner"}=t,i=e.shallowRef(r),c=e.shallowRef(o),d=()=>{if(n)if(l==="outer")i.value=n.outerWidth,c.value=n.outerHeight;else if(l==="visual"&&n.visualViewport){const{width:f,height:p,scale:h}=n.visualViewport;i.value=Math.round(f*h),c.value=Math.round(p*h)}else s?(i.value=n.innerWidth,c.value=n.innerHeight):(i.value=n.document.documentElement.clientWidth,c.value=n.document.documentElement.clientHeight)};d(),gu(d);const u={passive:!0};return St("resize",d,u),n&&l==="visual"&&n.visualViewport&&St(n.visualViewport,"resize",d,u),a&&e.watch(y_("(orientation: portrait)"),()=>d()),{width:i,height:c}}const _i=()=>bt&&/firefox/i.test(window.navigator.userAgent),zy=()=>bt&&/android/i.test(window.navigator.userAgent);/**
|
|
2
2
|
* @vue/shared v3.5.41
|
|
3
3
|
* (c) 2018-present Yuxi (Evan) You and Vue contributors
|
|
4
4
|
* @license MIT
|