@quidgest/ui 0.5.3 → 0.5.5
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 +1960 -1360
- package/dist/ui.esm.js +275 -274
- package/dist/ui.esm.js.map +1 -1
- package/dist/ui.js +4 -4
- package/dist/ui.js.map +1 -1
- package/dist/ui.min.js +89 -87
- package/dist/ui.min.js.map +1 -1
- package/dist/ui.scss +1 -1
- package/package.json +2 -1
package/dist/ui.min.js
CHANGED
|
@@ -1,19 +1,22 @@
|
|
|
1
1
|
!function(e,t){"object"==typeof exports&&typeof module<"u"?t(exports,require("vue")):"function"==typeof define&&define.amd?define(["exports","vue"],t):t((e=typeof globalThis<"u"?globalThis:e||self)["Quidgest UI"]={},e.Vue)}(this,(function(e,t){"use strict"
|
|
2
|
-
function o(e){return null!==e&&"object"==typeof e&&!Array.isArray(e)}function
|
|
3
|
-
for(const t in e)
|
|
2
|
+
function o(e){return null==e||("string"==typeof e||Array.isArray(e)?0===e.length:"object"==typeof e&&0===Object.keys(e).length)}function n(e){return null!==e&&"object"==typeof e&&!Array.isArray(e)}function l(e={},t={}){const o={}
|
|
3
|
+
for(const t in e)o[t]=e[t]
|
|
4
4
|
for(const a in t){const r=e[a],i=t[a]
|
|
5
|
-
|
|
6
|
-
function
|
|
7
|
-
|
|
8
|
-
function
|
|
5
|
+
n(r)&&n(i)?o[a]=l(r,i):o[a]=i}return o}const a="q-defaults"
|
|
6
|
+
function r(e){if(o(e))return
|
|
7
|
+
const n=i(),r=t.ref(e),s=t.computed((()=>o(r.value)?n.value:l(n.value,r.value)))
|
|
8
|
+
t.provide(a,s)}function i(){const e=t.inject(a,void 0)
|
|
9
|
+
if(!e)throw new Error("[Quidgest UI] Could not find defaults instance")
|
|
10
|
+
return e}const s={primary:"#00a1f8",primaryLight:"#e5f6ff",primaryDark:"#0079ba",secondary:"#11294d",secondaryLight:"#707f94",secondaryDark:"#040a13",highlight:"#DF640A",background:"#fff",container:"#fff",info:"#17a2b8",infoLight:"#bceff7",infoDark:"#11798a",success:"#28a745",successLight:"#c2f0cd",successDark:"#1e7d34",warning:"#ffa900",warningLight:"#ffeabf",warningDark:"#bf7f00",danger:"#b71c1c",dangerLight:"#f5bebe",dangerDark:"#891515",onBackground:"#1e2436",onPrimary:"#fff",onSecondary:"#fff",onHighlight:"#fff",onSuccess:"#fff",onWarning:"#fff",onDanger:"#fff",onInfo:"#fff"},c={primary:"#018BD2",primaryLight:"#cce7f6",primaryDark:"#006fac",secondary:"#11294d",secondaryLight:"#707f94",secondaryDark:"#040a13",highlight:"#FFAD54",background:"#1e2436",container:"#21323d",info:"#3DB6D1",infoLight:"#5aa2bc",infoDark:"#0c616a",success:"#00C781",successLight:"#6bae78",successDark:"#0f3b16",warning:"#FFD860",warningLight:"#ffd07a",warningDark:"#cc8000",danger:"#FC4B6C",dangerLight:"#FF7A88",dangerDark:"#B21929",onBackground:"#fff",onPrimary:"#fff",onSecondary:"#fff",onHighlight:"#fff",onSuccess:"#fff",onWarning:"#fff",onDanger:"#fff",onInfo:"#fff"}
|
|
11
|
+
function d(e){if(!/^#([a-fA-F0-9]{6}|[a-fA-F0-9]{3})$/.test(e))throw new Error("Invalid color format")
|
|
9
12
|
4===e.length&&(e="#"+e[1]+e[1]+e[2]+e[2]+e[3]+e[3])
|
|
10
|
-
return{r:parseInt(e.slice(1,3),16),g:parseInt(e.slice(3,5),16),b:parseInt(e.slice(5,7),16)}}function
|
|
13
|
+
return{r:parseInt(e.slice(1,3),16),g:parseInt(e.slice(3,5),16),b:parseInt(e.slice(5,7),16)}}function u(e,t){if(t<0||t>100)throw new Error("Amount must be in the range [0, 100]")
|
|
11
14
|
if(0===t)return e
|
|
12
|
-
const o=
|
|
13
|
-
return o.l=o.l+n*(100-o.l),
|
|
15
|
+
const o=m(e),n=t/100
|
|
16
|
+
return o.l=o.l+n*(100-o.l),h(o)}function f(e,t){if(t<0||t>100)throw new Error("Amount must be in the range [0, 100]")
|
|
14
17
|
if(0===t)return e
|
|
15
|
-
const o=
|
|
16
|
-
return o.l=o.l-n*o.l,
|
|
18
|
+
const o=m(e),n=t/100
|
|
19
|
+
return o.l=o.l-n*o.l,h(o)}function p(e){return`#${e.r.toString(16).padStart(2,"0")}${e.g.toString(16).padStart(2,"0")}${e.b.toString(16).padStart(2,"0")}`}function m(e){const t=e.r/255,o=e.g/255,n=e.b/255,l=Math.max(t,o,n),a=Math.min(t,o,n)
|
|
17
20
|
let r,i=0
|
|
18
21
|
const s=(l+a)/2
|
|
19
22
|
if(l===a)i=r=0
|
|
@@ -22,56 +25,58 @@ switch(r=s>.5?e/(2-l-a):e/(l+a),l){case t:i=(o-n)/e+(o<n?6:0)
|
|
|
22
25
|
break
|
|
23
26
|
case o:i=(n-t)/e+2
|
|
24
27
|
break
|
|
25
|
-
case n:i=(t-o)/e+4}i/=6}return{h:Math.round(360*i),s:Math.round(100*r),l:Math.round(100*s)}}function
|
|
28
|
+
case n:i=(t-o)/e+4}i/=6}return{h:Math.round(360*i),s:Math.round(100*r),l:Math.round(100*s)}}function h(e){const t=e.h/360,o=e.s/100,n=e.l/100
|
|
26
29
|
let l,a,r
|
|
27
30
|
if(0===o)l=a=r=n
|
|
28
31
|
else{const e=n<.5?n*(1+o):n+o-n*o,i=2*n-e
|
|
29
|
-
l=
|
|
30
|
-
function
|
|
31
|
-
if(o)for(const e of o.themes){const t="light"===e.mode?
|
|
32
|
+
l=v(i,e,t+1/3),a=v(i,e,t),r=v(i,e,t-1/3)}return{r:Math.round(255*l),g:Math.round(255*a),b:Math.round(255*r)}}function v(e,t,o){return o<0&&(o+=1),o>1&&(o-=1),o<1/6?e+6*(t-e)*o:o<.5?t:o<2/3?e+(t-e)*(2/3-o)*6:e}const y="q-theme"
|
|
33
|
+
function g(e,o){let n=null
|
|
34
|
+
if(o)for(const e of o.themes){const t="light"===e.mode?s:c
|
|
32
35
|
if(e.colors){let t
|
|
33
36
|
for(t in e.colors){const o=e.colors[t]
|
|
34
|
-
if(o&&!t.startsWith("on")&&!t.endsWith("Light")&&!t.endsWith("Dark")){const n=
|
|
35
|
-
l in e.colors||(e.colors[l]=
|
|
36
|
-
n={name:e,mode:"light",colors:
|
|
37
|
+
if(o&&!t.startsWith("on")&&!t.endsWith("Light")&&!t.endsWith("Dark")){const n=d(o),l=`${t}Light`,a=`${t}Dark`
|
|
38
|
+
l in e.colors||(e.colors[l]=p(u(n,85))),a in e.colors||(e.colors[a]=p(f(n,25)))}}}e.colors=k(t,e.colors),e.name===o.defaultTheme&&(n=e)}else{const e="default"
|
|
39
|
+
n={name:e,mode:"light",colors:s},o={defaultTheme:e,themes:[n]}}if(n){const l=t.ref({activeTheme:n.name,themes:o.themes})
|
|
37
40
|
t.watch((()=>l.value.activeTheme),(e=>{const t=l.value.themes.find((t=>t.name===e))
|
|
38
|
-
t&&function(e){let t=document.getElementById(
|
|
39
|
-
t||(t=document.createElement("style"),t.type="text/css",t.id=
|
|
41
|
+
t&&function(e){let t=document.getElementById(y)
|
|
42
|
+
t||(t=document.createElement("style"),t.type="text/css",t.id=y,document.head.appendChild(t))
|
|
40
43
|
let o,n=":root {\n"
|
|
41
44
|
for(o in e){const t=e[o]
|
|
42
|
-
if(t){n+=` ${
|
|
43
|
-
const e=
|
|
44
|
-
n+=` ${
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
if(!e)throw new Error("[framework] useDefaults must be called from inside a setup function")
|
|
45
|
+
if(t){n+=` ${b(o)}: ${t};\n`
|
|
46
|
+
const e=d(t)
|
|
47
|
+
n+=` ${b(o)}-rgb: ${e.r} ${e.g} ${e.b};\n`}}n+="}",t.textContent=n}(t.colors)}),{immediate:!0}),e.provide(y,l)}}function k(e,t={}){return{...e,...t}}function b(e){return e?`--q-theme-${e.replace(/([A-Z])/g,"-$1").replace(/^-/,"").toLowerCase()}`:""}const w=[t.createElementVNode("svg",{viewBox:"25 25 50 50"},[t.createElementVNode("circle",{class:"path",cx:"50",cy:"50",r:"20",fill:"none",stroke:"currentColor","stroke-width":"5","stroke-miterlimit":"10"})],-1)]
|
|
48
|
+
function B(e){const n=e.setup
|
|
49
|
+
return n&&(e.setup=(e,l)=>{const a=function(){const e=t.getCurrentInstance()
|
|
50
|
+
if(!e)throw new Error("[Quidgest UI] useDefaults must be called from inside a setup function")
|
|
49
51
|
const o=e.type.name??e.type.__name
|
|
50
|
-
if(!o)throw new Error("[
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
if(
|
|
55
|
-
const
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
52
|
+
if(!o)throw new Error("[Quidgest UI] Could not determine component name")
|
|
53
|
+
const n=i()
|
|
54
|
+
return t.computed((()=>{var e
|
|
55
|
+
return null==(e=n.value)?void 0:e[o]}))}()
|
|
56
|
+
if(o(a.value))return n(e,l)
|
|
57
|
+
const r=t.getCurrentInstance()
|
|
58
|
+
if(null===r)return n(e,l)
|
|
59
|
+
const s=new Proxy(e,{get(e,t){var o
|
|
60
|
+
const n=Reflect.get(e,t),l=null==(o=a.value)?void 0:o[t]
|
|
61
|
+
return"class"===t||"style"===t?[l,n].filter((e=>null!=e)):"string"!=typeof t||function(e,t){var o
|
|
62
|
+
return typeof(null==(o=e.props)?void 0:o[t])<"u"}(r.vnode,t)?n:l??n}})
|
|
63
|
+
return n(s,l)}),e}const C=B(t.defineComponent({__name:"QSpinnerLoader",props:{size:{default:48}},setup(e){const o=e,n=t.computed((()=>({"font-size":48!==o.size?`${o.size}px`:void 0})))
|
|
64
|
+
return(e,o)=>(t.openBlock(),t.createElementBlock("div",{class:"q-spinner-loader",style:t.normalizeStyle(n.value)},w,4))}})),S=["disabled","onClick"],_={key:0,class:"q-btn__spinner"},E={class:"q-btn__content"},x=B(t.defineComponent({__name:"QButton",props:{active:{type:Boolean},bStyle:{default:"secondary"},label:{default:""},disabled:{type:Boolean},iconOnRight:{type:Boolean},borderless:{type:Boolean},elevated:{type:Boolean},block:{type:Boolean},loading:{type:Boolean},size:{default:"regular"}},emits:["click"],setup(e,{emit:o}){const n=e,l=t.computed((()=>n.disabled||n.loading))
|
|
60
65
|
function a(e){l.value||o("click",e)}const r=t.computed((()=>{const e=t.computed((()=>n.bStyle?`q-btn--${n.bStyle}`:void 0)),o=t.computed((()=>"regular"!==n.size?`q-btn--${n.size}`:void 0))
|
|
61
66
|
return["q-btn",e.value,o.value,{"q-btn--active":n.active,"q-btn--borderless":n.borderless,"q-btn--elevated":n.elevated,"q-btn--block":n.block,"q-btn--loading":n.loading}]}))
|
|
62
|
-
return(e,o)=>(t.openBlock(),t.createElementBlock("button",{type:"button",class:t.normalizeClass(r.value),disabled:l.value,onClick:t.withModifiers(a,["stop","prevent"])},[e.loading?(t.openBlock(),t.createElementBlock("div",
|
|
63
|
-
|
|
67
|
+
return(e,o)=>(t.openBlock(),t.createElementBlock("button",{type:"button",class:t.normalizeClass(r.value),disabled:l.value,onClick:t.withModifiers(a,["stop","prevent"])},[e.loading?(t.openBlock(),t.createElementBlock("div",_,[t.createVNode(t.unref(C),{size:23})])):t.createCommentVNode("",!0),t.createElementVNode("span",E,[e.iconOnRight?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createTextVNode(t.toDisplayString(n.label),1)],64)):t.createCommentVNode("",!0),t.renderSlot(e.$slots,"default"),e.iconOnRight?t.createCommentVNode("",!0):(t.openBlock(),t.createElementBlock(t.Fragment,{key:1},[t.createTextVNode(t.toDisplayString(n.label),1)],64))])],10,S))}})),V=B(t.defineComponent({__name:"QButtonGroup",props:{bStyle:{},disabled:{type:Boolean},borderless:{type:Boolean},elevated:{type:Boolean}},setup(e){const o=e
|
|
68
|
+
r({QButton:{bStyle:t.toRef(o,"bStyle"),disabled:t.toRef(o,"disabled"),borderless:t.toRef(o,"borderless"),elevated:!1}})
|
|
64
69
|
const n=t.computed((()=>["q-btn-group",{"q-btn-group--elevated":o.elevated}]))
|
|
65
|
-
return(e,o)=>(t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(n.value)},[t.renderSlot(e.$slots,"default")],2))}})
|
|
70
|
+
return(e,o)=>(t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(n.value)},[t.renderSlot(e.$slots,"default")],2))}})),$=B(t.defineComponent({__name:"QButtonToggle",props:{modelValue:{},options:{},disabled:{type:Boolean},borderless:{type:Boolean},elevated:{type:Boolean},mandatory:{type:Boolean}},emits:["update:modelValue"],setup(e,{emit:o}){const n=e,l=t.ref(n.modelValue)
|
|
66
71
|
t.watch((()=>n.modelValue),(e=>l.value=e))
|
|
67
72
|
const a=t.computed({get:()=>l.value,set(e){l.value=e,o("update:modelValue",e)}})
|
|
68
|
-
return(e,o)=>(t.openBlock(),t.createBlock(t.unref(
|
|
69
|
-
case"font":return
|
|
70
|
-
case"img":return
|
|
73
|
+
return(e,o)=>(t.openBlock(),t.createBlock(t.unref(V),{"b-style":"secondary",disabled:n.disabled,borderless:n.borderless,elevated:n.elevated},{default:t.withCtx((()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(n.options,(o=>(t.openBlock(),t.createBlock(t.unref(x),{key:o.key,title:o.title,label:o.label,active:a.value===o.key,onClick:e=>function(e){a.value!==e.key||n.mandatory?a.value=e.key:a.value=void 0}(o)},{default:t.withCtx((()=>[t.renderSlot(e.$slots,o.key)])),_:2},1032,["title","label","active","onClick"])))),128))])),_:3},8,["disabled","borderless","elevated"]))}})),q=t.defineComponent({__name:"QIcon",props:{name:{},type:{default:"svg"},size:{default:void 0}},setup(e){const o=e,n=t.computed((()=>{switch(o.type){case"svg":return M
|
|
74
|
+
case"font":return A
|
|
75
|
+
case"img":return F
|
|
71
76
|
default:return}}))
|
|
72
|
-
return(e,l)=>(t.openBlock(),t.createBlock(t.resolveDynamicComponent(n.value),{icon:o.name,size:o.size},null,8,["icon","size"]))}}),
|
|
73
|
-
return(e,a)=>o.icon?(t.openBlock(),t.createElementBlock("i",{key:0,class:t.normalizeClass(["q-icon","q-icon__font",n.value,`${o.library}-${o.icon}`]),style:t.normalizeStyle(l.value)},null,6)):t.createCommentVNode("",!0)}}),
|
|
74
|
-
return(e,l)=>o.icon?(t.openBlock(),t.createElementBlock("img",{key:0,src:o.icon,class:"q-icon",style:t.normalizeStyle(n.value)},null,12,
|
|
77
|
+
return(e,l)=>(t.openBlock(),t.createBlock(t.resolveDynamicComponent(n.value),{icon:o.name,size:o.size},null,8,["icon","size"]))}}),L=t.defineComponent({__name:"QIconFont",props:{icon:{},library:{default:"glyphicons"},variant:{default:""},size:{default:void 0}},setup(e){const o=e,n=t.computed((()=>o.variant?`${o.library}-${o.variant}`:o.library)),l=t.computed((()=>({"font-size":void 0!==o.size?`${o.size}px`:void 0})))
|
|
78
|
+
return(e,a)=>o.icon?(t.openBlock(),t.createElementBlock("i",{key:0,class:t.normalizeClass(["q-icon","q-icon__font",n.value,`${o.library}-${o.icon}`]),style:t.normalizeStyle(l.value)},null,6)):t.createCommentVNode("",!0)}}),z=["src"],D=t.defineComponent({__name:"QIconImg",props:{icon:{},size:{}},setup(e){const o=e,n=t.computed((()=>({"font-size":void 0!==o.size?`${o.size}px`:void 0})))
|
|
79
|
+
return(e,l)=>o.icon?(t.openBlock(),t.createElementBlock("img",{key:0,src:o.icon,class:"q-icon",style:t.normalizeStyle(n.value)},null,12,z)):t.createCommentVNode("",!0)}}),I={},N=t.defineComponent({name:"InlineSvg",emits:["loaded","unloaded","error"],inheritAttrs:!1,render(){if(!this.svgElSource)return null
|
|
75
80
|
const e=this.getSvgContent(this.svgElSource)
|
|
76
81
|
if(!e)return t.h("div",this.$attrs)
|
|
77
82
|
const o={}
|
|
@@ -79,24 +84,22 @@ return this.copySvgAttrs(o,this.svgElSource),this.copySvgAttrs(o,e),this.copyCom
|
|
|
79
84
|
if(o)for(const t of o)e[t.name]=t.value},copyComponentAttrs(e,t){for(const[o,n]of Object.entries(t))!1!==n&&null!=n&&(e[o]=n)},getSvgContent(e){return this.symbol&&!(e=e.getElementById(this.symbol))?null:(this.transformSource&&(e=e.cloneNode(!0),e=this.transformSource(e)),this.title&&(this.transformSource||(e=e.cloneNode(!0)),function(e,t){const o=e.getElementsByTagName("title")
|
|
80
85
|
if(o.length)o[0].textContent=t
|
|
81
86
|
else{const o=document.createElementNS("http://www.w3.org/2000/svg","title")
|
|
82
|
-
o.textContent=t,e.insertBefore(o,e.firstChild)}}(e,this.title)),e)},async getSource(e){try{
|
|
87
|
+
o.textContent=t,e.insertBefore(o,e.firstChild)}}(e,this.title)),e)},async getSource(e){try{I[e]||(I[e]=function(e){if(e.getIsPending)return e
|
|
83
88
|
let t=!0
|
|
84
89
|
const o=e.then((e=>(t=!1,e)),(e=>{throw t=!1,e}))
|
|
85
|
-
return o.getIsPending=()=>t,o}(this.download(e))),this.svgElSource&&
|
|
86
|
-
const t=await
|
|
87
|
-
this.svgElSource=t,await this.$nextTick(),this.$emit("loaded",this.$el)}catch(t){this.svgElSource&&(this.svgElSource=null,this.$emit("unloaded")),delete
|
|
90
|
+
return o.getIsPending=()=>t,o}(this.download(e))),this.svgElSource&&I[e].getIsPending()&&!this.keepDuringLoading&&(this.svgElSource=null,this.$emit("unloaded"))
|
|
91
|
+
const t=await I[e]
|
|
92
|
+
this.svgElSource=t,await this.$nextTick(),this.$emit("loaded",this.$el)}catch(t){this.svgElSource&&(this.svgElSource=null,this.$emit("unloaded")),delete I[e],this.$emit("error",t)}},async download(e){const t=await fetch(e)
|
|
88
93
|
if(!t.ok)throw new Error("Error loading SVG")
|
|
89
94
|
const o=await t.text(),n=(new DOMParser).parseFromString(o,"text/xml").getElementsByTagName("svg")[0]
|
|
90
95
|
if(!n)throw new Error("Loaded file is not a valid SVG")
|
|
91
96
|
return n}},watch:{src(e){this.getSource(e)}}})
|
|
92
|
-
const
|
|
93
|
-
return(e,a)=>n.icon?(t.openBlock(),t.createBlock(t.unref(N),{key:0,class:"q-icon q-icon__svg",src:n.bundle,symbol:n.icon,style:t.normalizeStyle(l.value),onLoaded:a[0]||(a[0]=e=>o("loaded",e)),onUnloaded:a[1]||(a[1]=e=>o("unloaded",e))},null,8,["src","symbol","style"])):t.createCommentVNode("",!0)}})
|
|
94
|
-
|
|
95
|
-
const
|
|
96
|
-
return(e,n)=>(t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["q-input",`q-input--${o.size}`,{"q-input--readonly":o.readonly,"q-input--disabled":o.disabled}])},[e.$slots.prepend?(t.openBlock(),t.createElementBlock("div",I,[t.renderSlot(e.$slots,"prepend")])):t.createCommentVNode("",!0),t.renderSlot(e.$slots,"default"),e.$slots.append?(t.openBlock(),t.createElementBlock("div",Q,[t.renderSlot(e.$slots,"append")])):t.createCommentVNode("",!0)],2))}}),F={class:"q-line-loader"}
|
|
97
|
-
const M=((e,t)=>{const o=e.__vccOpts||e
|
|
97
|
+
const Q=t.defineComponent({__name:"QIconSvg",props:{icon:{},bundle:{default:""},size:{default:void 0}},emits:["loaded","unloaded"],setup(e,{emit:o}){const n=e,l=t.computed((()=>({"font-size":void 0!==n.size?`${n.size}px`:void 0})))
|
|
98
|
+
return(e,a)=>n.icon?(t.openBlock(),t.createBlock(t.unref(N),{key:0,class:"q-icon q-icon__svg",src:n.bundle,symbol:n.icon,style:t.normalizeStyle(l.value),onLoaded:a[0]||(a[0]=e=>o("loaded",e)),onUnloaded:a[1]||(a[1]=e=>o("unloaded",e))},null,8,["src","symbol","style"])):t.createCommentVNode("",!0)}}),T=B(q),A=B(L),F=B(D),M=B(Q),P={key:0,class:"q-input__prepend"},O={key:1,class:"q-input__append"},R=B(t.defineComponent({__name:"QInput",props:{size:{default:"medium"},readonly:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1}},setup(e){const o=e
|
|
99
|
+
return(e,n)=>(t.openBlock(),t.createElementBlock("div",{class:t.normalizeClass(["q-input",`q-input--${o.size}`,{"q-input--readonly":o.readonly,"q-input--disabled":o.disabled}])},[e.$slots.prepend?(t.openBlock(),t.createElementBlock("div",P,[t.renderSlot(e.$slots,"prepend")])):t.createCommentVNode("",!0),t.renderSlot(e.$slots,"default"),e.$slots.append?(t.openBlock(),t.createElementBlock("div",O,[t.renderSlot(e.$slots,"append")])):t.createCommentVNode("",!0)],2))}})),H={class:"q-line-loader"}
|
|
100
|
+
const U=B(((e,t)=>{const o=e.__vccOpts||e
|
|
98
101
|
for(const[e,n]of t)o[e]=n
|
|
99
|
-
return o})({},[["render",function(e,o){return t.openBlock(),t.createElementBlock("div",
|
|
102
|
+
return o})({},[["render",function(e,o){return t.openBlock(),t.createElementBlock("div",H)}]])),j=t.defineComponent({__name:"QList",props:{modelValue:{type:[String,Number,Boolean,Symbol],default:void 0},items:{},groups:{default:()=>[]},itemValue:{default:"key"},itemLabel:{default:"label"},disabled:{type:Boolean}},emits:["update:modelValue"],setup(e,{expose:o,emit:n}){const l=e,a=t.ref(l.modelValue),r=t.computed((()=>i.value.length>1?"div":"ul")),i=t.computed((()=>l.groups.length?l.groups:[{title:""}])),s=t.ref(null)
|
|
100
103
|
function c(e){a.value=e,n("update:modelValue",e)}function d(){let e=0
|
|
101
104
|
a.value&&(e=l.items.findIndex((e=>e[l.itemValue]===a.value))),p(e)}function u(e){switch(["ArrowDown","ArrowUp","Home","End"].includes(e.key)&&e.preventDefault(),e.key){case"ArrowDown":f("next")
|
|
102
105
|
break
|
|
@@ -112,15 +115,15 @@ break
|
|
|
112
115
|
case"last":p(-1)}}function p(e){var t
|
|
113
116
|
null==(t=m().at(e))||t.focus()}function m(){var e
|
|
114
117
|
const t=null==(e=s.value)?void 0:e.querySelectorAll("li")
|
|
115
|
-
return t?Array.from(t).filter((e=>-1!==e.tabIndex)):[]}function h(e){return e?l.items.filter((t=>t.group===e)):l.items}return t.watch((()=>l.modelValue),(e=>{a.value=e})),o({focusItem:p}),(e,o)=>(t.openBlock(),t.createBlock(t.resolveDynamicComponent(r.value),{ref_key:"listRef",ref:s,class:t.normalizeClass(["q-list",{"q-list--disabled":l.disabled}]),role:"listbox",tabindex:l.disabled?-1:0,onFocus:d,onKeydown:u},{default:t.withCtx((()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(i.value,(e=>(t.openBlock(),t.createBlock(t.unref(
|
|
116
|
-
function l(){n.disabled||o("select",n.value)}function a(e){"Tab"===e.key&&l(),("Enter"===e.key||" "===e.key)&&(e.preventDefault(),e.stopPropagation(),l())}return(e,o)=>(t.openBlock(),t.createElementBlock("li",{role:"option",tabindex:n.disabled?void 0:-2,class:t.normalizeClass(["q-list-item",{"q-list-item--disabled":n.disabled,"q-list-item--selected":n.selected,"q-list-item--highlighted":n.highlighted}]),"aria-label":n.label,"aria-selected":n.disabled?void 0:n.selected,onKeydown:a,onClick:t.withModifiers(l,["stop","prevent"])},[n.icon?(t.openBlock(),t.createBlock(t.unref(
|
|
117
|
-
let
|
|
118
|
-
const
|
|
119
|
-
return(e,n)=>o.title?(t.openBlock(),t.createElementBlock("ul",{key:1,class:"q-list-item-group",role:"group","aria-labelledby":o.id},[o.title?(t.openBlock(),t.createElementBlock("li",{key:0,id:o.id,class:"q-list-item-group__title",role:"presentation"},t.toDisplayString(o.title),9,
|
|
120
|
-
function
|
|
118
|
+
return t?Array.from(t).filter((e=>-1!==e.tabIndex)):[]}function h(e){return e?l.items.filter((t=>t.group===e)):l.items}return t.watch((()=>l.modelValue),(e=>{a.value=e})),o({focusItem:p}),(e,o)=>(t.openBlock(),t.createBlock(t.resolveDynamicComponent(r.value),{ref_key:"listRef",ref:s,class:t.normalizeClass(["q-list",{"q-list--disabled":l.disabled}]),role:"listbox",tabindex:l.disabled?-1:0,onFocus:d,onKeydown:u},{default:t.withCtx((()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(i.value,(e=>(t.openBlock(),t.createBlock(t.unref(oe),t.mergeProps({key:e.title},e),{default:t.withCtx((()=>[(t.openBlock(!0),t.createElementBlock(t.Fragment,null,t.renderList(h(e.title),(e=>(t.openBlock(),t.createBlock(t.unref(te),{key:e[l.itemValue],value:e[l.itemValue],label:e[l.itemLabel],icon:e.icon,disabled:l.disabled||e.disabled,selected:a.value===e[l.itemValue],onSelect:c},null,8,["value","label","icon","disabled","selected"])))),128))])),_:2},1040)))),128))])),_:1},40,["class","tabindex"]))}}),W=["tabindex","aria-label","aria-selected","onClick"],G={check:{name:"check"}},K=t.defineComponent({__name:"QListItem",props:{value:{type:[String,Number,Boolean,Symbol]},label:{},icon:{default:void 0},selected:{type:Boolean,default:!1},highlighted:{type:Boolean,default:!1},icons:{default:()=>G},disabled:{type:Boolean,default:!1}},emits:["select"],setup(e,{emit:o}){const n=e
|
|
119
|
+
function l(){n.disabled||o("select",n.value)}function a(e){"Tab"===e.key&&l(),("Enter"===e.key||" "===e.key)&&(e.preventDefault(),e.stopPropagation(),l())}return(e,o)=>(t.openBlock(),t.createElementBlock("li",{role:"option",tabindex:n.disabled?void 0:-2,class:t.normalizeClass(["q-list-item",{"q-list-item--disabled":n.disabled,"q-list-item--selected":n.selected,"q-list-item--highlighted":n.highlighted}]),"aria-label":n.label,"aria-selected":n.disabled?void 0:n.selected,onKeydown:a,onClick:t.withModifiers(l,["stop","prevent"])},[n.icon?(t.openBlock(),t.createBlock(t.unref(T),t.normalizeProps(t.mergeProps({key:0},n.icon)),null,16)):t.createCommentVNode("",!0),t.createTextVNode(" "+t.toDisplayString(n.label)+" ",1),n.selected?(t.openBlock(),t.createBlock(t.unref(T),t.mergeProps({key:1},n.icons.check,{class:"q-list-item__check"}),null,16)):t.createCommentVNode("",!0)],42,W))}})
|
|
120
|
+
let X=0
|
|
121
|
+
const Y=["aria-labelledby"],Z=["id"],J=t.defineComponent({__name:"QListItemGroup",props:{id:{default:()=>"uid-"+ ++X},title:{default:""},disabled:{type:Boolean,default:!1}},setup(e){const o=e
|
|
122
|
+
return(e,n)=>o.title?(t.openBlock(),t.createElementBlock("ul",{key:1,class:"q-list-item-group",role:"group","aria-labelledby":o.id},[o.title?(t.openBlock(),t.createElementBlock("li",{key:0,id:o.id,class:"q-list-item-group__title",role:"presentation"},t.toDisplayString(o.title),9,Z)):t.createCommentVNode("",!0),t.renderSlot(e.$slots,"default")],8,Y)):t.renderSlot(e.$slots,"default",{key:0})}}),ee=B(j),te=B(K),oe=B(J)
|
|
123
|
+
function ne(e,t,o="right",n){const l=e.getBoundingClientRect(),a=l.x+window.scrollX,r=l.y+window.scrollY,i=null==t?void 0:t.getBoundingClientRect(),s=(null==i?void 0:i.width)??0,c=(null==i?void 0:i.height)??0
|
|
121
124
|
let d=o
|
|
122
|
-
i&&!
|
|
123
|
-
for(const l of n[o])if(
|
|
125
|
+
i&&!le(l,i,d)&&(d=function(e,t,o){const n={top:["bottom","left","right"],bottom:["top","left","right"],left:["right","top","bottom"],right:["left","top","bottom"]}
|
|
126
|
+
for(const l of n[o])if(le(e,t,l))return l
|
|
124
127
|
return o}(l,i,d))
|
|
125
128
|
const u={x:0,y:0,placement:d}
|
|
126
129
|
switch(d){case"top":u.x="anchor"===n?a:a+(l.width-s)/2,u.y=r-c
|
|
@@ -129,15 +132,14 @@ case"bottom":u.x="anchor"===n?a:a+(l.width-s)/2,u.y=r+l.height
|
|
|
129
132
|
break
|
|
130
133
|
case"left":u.x=a-s,u.y=r+l.height/2-c/2
|
|
131
134
|
break
|
|
132
|
-
case"right":u.x=a+l.width,u.y=r+l.height/2-c/2}return"anchor"===n&&(u.width=l.width),u}function
|
|
133
|
-
switch(o){case"top":n=
|
|
135
|
+
case"right":u.x=a+l.width,u.y=r+l.height/2-c/2}return"anchor"===n&&(u.width=l.width),u}function le(e,t,o){let n=!1,l=!1
|
|
136
|
+
switch(o){case"top":n=re(e,t),l=e.top>t.height
|
|
134
137
|
break
|
|
135
|
-
case"bottom":n=
|
|
138
|
+
case"bottom":n=re(e,t),l=window.innerHeight-e.top-e.height>t.height
|
|
136
139
|
break
|
|
137
|
-
case"left":n=e.left>t.width,l=
|
|
140
|
+
case"left":n=e.left>t.width,l=ae(e,t)
|
|
138
141
|
break
|
|
139
|
-
case"right":n=window.innerWidth-e.left-e.width>t.width,l=
|
|
140
|
-
const ee={key:0,class:"q-overlay__arrow"},te=t.defineComponent({__name:"QOverlay",props:{modelValue:{type:Boolean},anchor:{},appearance:{default:"regular"},arrow:{type:Boolean,default:!1},attach:{default:"body"},contentClasses:{default:()=>[]},delay:{default:500},disabled:{type:Boolean},offset:{default:8},placement:{default:"right"},spy:{type:Boolean,default:!1},transition:{default:"fade"},trigger:{default:"click"},width:{default:"auto"}},emits:["enter","leave"],setup(e,{emit:o}){const n=e,l=t.computed((()=>["q-overlay",`q-overlay--${a.placement}`,{"q-overlay--inverted":"inverted"===n.appearance},...n.contentClasses])),a=t.reactive({visible:n.modelValue,top:0,left:0,width:0,placement:n.placement}),r=t.computed((()=>a.visible&&!n.disabled))
|
|
142
|
+
case"right":n=window.innerWidth-e.left-e.width>t.width,l=ae(e,t)}return n&&l}function ae(e,t){return window.innerHeight-e.top-e.height/2>t.height/2&&e.top+e.height/2>t.height/2}function re(e,t){return window.innerWidth-e.left-e.width/2>t.width/2&&e.left+e.width/2>t.width/2}function ie(e){return"string"==typeof e?document.querySelector(e):e&&"$el"in e?e.$el:e}const se={key:0,class:"q-overlay__arrow"},ce=B(t.defineComponent({__name:"QOverlay",props:{modelValue:{type:Boolean},anchor:{},appearance:{default:"regular"},arrow:{type:Boolean,default:!1},attach:{default:"body"},contentClasses:{default:()=>[]},delay:{default:500},disabled:{type:Boolean},offset:{default:8},placement:{default:"right"},spy:{type:Boolean,default:!1},transition:{default:"fade"},trigger:{default:"click"},width:{default:"auto"}},emits:["enter","leave"],setup(e,{emit:o}){const n=e,l=t.computed((()=>["q-overlay",`q-overlay--${a.placement}`,{"q-overlay--inverted":"inverted"===n.appearance},...n.contentClasses])),a=t.reactive({visible:n.modelValue,top:0,left:0,width:0,placement:n.placement}),r=t.computed((()=>a.visible&&!n.disabled))
|
|
141
143
|
t.watch((()=>n.modelValue),(()=>a.visible=n.modelValue))
|
|
142
144
|
const i=t.computed((()=>{let e=0,t=0
|
|
143
145
|
switch(a.placement){case"top":t=-(n.offset||0)
|
|
@@ -148,35 +150,35 @@ case"left":e=-(n.offset||0)
|
|
|
148
150
|
break
|
|
149
151
|
case"right":e=n.offset||0}const o={top:`${a.top+t}px`,left:`${a.left+e}px`}
|
|
150
152
|
return void 0!==a.width&&["top","bottom"].includes(a.placement)&&(o.width=`${a.width}px`),o})),s=t.ref(null)
|
|
151
|
-
function c(){const e=
|
|
152
|
-
if(e){const t=
|
|
153
|
+
function c(){const e=ie(n.anchor)
|
|
154
|
+
if(e){const t=ne(e,s.value,n.placement,n.width)
|
|
153
155
|
a.left=t.x,a.top=t.y,a.width=t.width,a.placement=t.placement}}let d,u,f
|
|
154
156
|
function p(){const e="hover"===n.trigger?n.delay:0
|
|
155
|
-
d||(d=window.setTimeout((()=>a.visible=!0),e))}function m(){clearTimeout(d),d=void 0,a.visible=!1}function h(){r.value?m():p()}function v(){
|
|
156
|
-
e&&(window.addEventListener("scroll",c),window.addEventListener("resize",c),u=new MutationObserver(c),u.observe(e,{attributes:!1,childList:!0,characterData:!0,subtree:!0}),c())})),n.spy&&v()}function g(){window.removeEventListener("scroll",c),window.removeEventListener("resize",c),null==u||u.disconnect(),n.spy&&(clearTimeout(f),f=void 0)}return t.watch([()=>r.value,()=>n.placement],c),t.onBeforeUnmount(g),t.onMounted(c),t.watch((()=>n.disabled),(e=>{e||t.nextTick((()=>{const e=
|
|
157
|
+
d||(d=window.setTimeout((()=>a.visible=!0),e))}function m(){clearTimeout(d),d=void 0,a.visible=!1}function h(){r.value?m():p()}function v(){ie(n.anchor)?(c(),f=window.setTimeout(v,100)):m()}function y(){t.nextTick((()=>{const e=ie(n.anchor)
|
|
158
|
+
e&&(window.addEventListener("scroll",c),window.addEventListener("resize",c),u=new MutationObserver(c),u.observe(e,{attributes:!1,childList:!0,characterData:!0,subtree:!0}),c())})),n.spy&&v()}function g(){window.removeEventListener("scroll",c),window.removeEventListener("resize",c),null==u||u.disconnect(),n.spy&&(clearTimeout(f),f=void 0)}return t.watch([()=>r.value,()=>n.placement],c),t.onBeforeUnmount(g),t.onMounted(c),t.watch((()=>n.disabled),(e=>{e||t.nextTick((()=>{const e=ie(n.anchor)
|
|
157
159
|
if(e)switch(n.trigger){case"click":e.addEventListener("click",h)
|
|
158
160
|
break
|
|
159
|
-
case"hover":e.addEventListener("mouseenter",p),e.addEventListener("mouseleave",m)}}))}),{immediate:!0}),t.watch((()=>r.value),(e=>{e?y():g()}),{immediate:!0}),(e,a)=>(t.openBlock(),t.createElementBlock(t.Fragment,null,[t.renderSlot(e.$slots,"trigger",{open:r.value}),(t.openBlock(),t.createBlock(t.Teleport,{to:n.attach},[t.createVNode(t.Transition,{name:n.transition,appear:"",onEnter:a[0]||(a[0]=e=>o("enter")),onLeave:a[1]||(a[1]=e=>o("leave"))},{default:t.withCtx((()=>[r.value?(t.openBlock(),t.createElementBlock("div",{key:0,class:t.normalizeClass(l.value),style:t.normalizeStyle(i.value)},[t.createElementVNode("div",{class:t.normalizeClass(["q-overlay__content"]),ref_key:"overlay",ref:s},[n.arrow?(t.openBlock(),t.createElementBlock("div",
|
|
160
|
-
return(e,n)=>(t.openBlock(),t.createBlock(t.unref(
|
|
161
|
-
t.arg?e===n||e.contains(n)||n.closest(t.arg)||t.value(o,e):e===n||e.contains(n)||t.value(o,e)},document.addEventListener("click",e.clickOutsideEvent)},unmounted(e){document.removeEventListener("click",e.clickOutsideEvent)}},
|
|
161
|
+
case"hover":e.addEventListener("mouseenter",p),e.addEventListener("mouseleave",m)}}))}),{immediate:!0}),t.watch((()=>r.value),(e=>{e?y():g()}),{immediate:!0}),(e,a)=>(t.openBlock(),t.createElementBlock(t.Fragment,null,[t.renderSlot(e.$slots,"trigger",{open:r.value}),(t.openBlock(),t.createBlock(t.Teleport,{to:n.attach},[t.createVNode(t.Transition,{name:n.transition,appear:"",onEnter:a[0]||(a[0]=e=>o("enter")),onLeave:a[1]||(a[1]=e=>o("leave"))},{default:t.withCtx((()=>[r.value?(t.openBlock(),t.createElementBlock("div",{key:0,class:t.normalizeClass(l.value),style:t.normalizeStyle(i.value)},[t.createElementVNode("div",{class:t.normalizeClass(["q-overlay__content"]),ref_key:"overlay",ref:s},[n.arrow?(t.openBlock(),t.createElementBlock("div",se)):t.createCommentVNode("",!0),t.renderSlot(e.$slots,"default")],512)],6)):t.createCommentVNode("",!0)])),_:3},8,["name"])],8,["to"]))],64))}})),de={key:0,class:"q-popover__header"},ue={key:1,class:"q-popover__body"},fe=["innerHTML"],pe={key:1},me=B(t.defineComponent({__name:"QPopover",props:{modelValue:{type:Boolean},anchor:{},arrow:{type:Boolean,default:!0},attach:{default:"body"},disabled:{type:Boolean},html:{type:Boolean,default:!0},placement:{default:"right"},spy:{type:Boolean,default:!0},text:{},title:{}},setup(e){const o=e
|
|
162
|
+
return(e,n)=>(t.openBlock(),t.createBlock(t.unref(ce),{"model-value":o.modelValue,trigger:"click",anchor:o.anchor,arrow:o.arrow,attach:o.attach,"content-classes":["q-popover"],disabled:o.disabled,placement:o.placement,spy:o.spy},{default:t.withCtx((()=>[o.title||e.$slots.header?(t.openBlock(),t.createElementBlock("h3",de,[t.createTextVNode(t.toDisplayString(o.title)+" ",1),t.renderSlot(e.$slots,"header")])):t.createCommentVNode("",!0),o.text||e.$slots.body?(t.openBlock(),t.createElementBlock("div",ue,[o.html?(t.openBlock(),t.createElementBlock("span",{key:0,innerHTML:o.text},null,8,fe)):(t.openBlock(),t.createElementBlock("span",pe,t.toDisplayString(o.text),1)),t.renderSlot(e.$slots,"body")])):t.createCommentVNode("",!0)])),_:3},8,["model-value","anchor","arrow","attach","disabled","placement","spy"]))}})),he={mounted(e,t){e.clickOutsideEvent=function(o){const n=o.target
|
|
163
|
+
t.arg?e===n||e.contains(n)||n.closest(t.arg)||t.value(o,e):e===n||e.contains(n)||t.value(o,e)},document.addEventListener("click",e.clickOutsideEvent)},unmounted(e){document.removeEventListener("click",e.clickOutsideEvent)}},ve={key:1,class:"q-select__placeholder"},ye={placeholder:"Choose..."},ge={chevron:{name:"chevron-down"},clear:{name:"close"}},ke=B(t.defineComponent({__name:"QSelect",props:{modelValue:{type:[String,Number,Boolean,Symbol],default:void 0},clearable:{type:Boolean,default:!1},readonly:{type:Boolean},disabled:{type:Boolean,default:!1},loading:{type:Boolean,default:!1},icons:{default:()=>ge},items:{},groups:{default:()=>[]},itemValue:{default:"key"},itemLabel:{default:"label"},size:{default:"medium"},texts:{default:()=>ye}},emits:["update:modelValue","before-show","before-hide","show","hide"],setup(e,{emit:o}){const n=e,l=t.ref(n.modelValue),a=t.ref(!1),r=t.ref(""),i=t.ref(null),s=t.ref(null),c=t.ref(null),d=t.computed((()=>{var e
|
|
162
164
|
return null==(e=n.items)?void 0:e.find((e=>e[n.itemValue]===l.value))})),u=t.computed((()=>d.value?d.value[n.itemLabel]:"")),f=t.computed((()=>n.clearable&&!n.readonly&&!n.disabled&&!n.loading))
|
|
163
165
|
function p(){f.value&&(l.value=void 0,o("update:modelValue",l.value),v())}function m(){n.readonly||n.disabled||(a.value?v():a.value||(o("before-show"),a.value=!0))}function h(e){var t
|
|
164
166
|
null!=(t=i.value)&&t.$el.contains(e.target)||v()}function v(){a.value&&(o("before-hide"),a.value=!1)}let y
|
|
165
167
|
function g(e){if(e.key&&!n.readonly&&!n.disabled){if(window.clearTimeout(y),["Enter"," ","ArrowDown","ArrowUp","Home","End"].includes(e.key)&&(e.preventDefault(),e.stopPropagation()),["Enter"," "].includes(e.key)&&(a.value=!0),["Escape","Tab"].includes(e.key)&&(a.value?a.value=!1:n.clearable&&"Escape"===e.key&&p()),"Delete"===e.key&&n.clearable&&p(),/^[a-z]$/i.test(e.key)){r.value+=e.key.toLowerCase()
|
|
166
|
-
for(let e=0;e<n.items.length;e++)if(n.items[e][n.itemLabel].toLowerCase().startsWith(r.value)){
|
|
168
|
+
for(let e=0;e<n.items.length;e++)if(n.items[e][n.itemLabel].toLowerCase().startsWith(r.value)){w(e)
|
|
167
169
|
break}}y=window.setTimeout((function(){r.value=""}),500)}}function k(){var e
|
|
168
170
|
null==(e=s.value)||e.$el.focus(),o("show")}function b(){var e
|
|
169
|
-
null==(e=i.value)||e.$el.focus(),o("hide")}function
|
|
171
|
+
null==(e=i.value)||e.$el.focus(),o("hide")}function w(e){var t
|
|
170
172
|
null==(t=s.value)||t.focusItem(e)}return t.watch((()=>n.modelValue),(e=>{l.value=e})),(e,o)=>{var r,y
|
|
171
|
-
return t.openBlock(),t.createElementBlock(t.Fragment,null,[t.createVNode(t.unref(
|
|
172
|
-
return[t.createVNode(t.unref(
|
|
173
|
-
return(e,n)=>(t.openBlock(),t.createBlock(t.unref(
|
|
174
|
-
e.QButton=
|
|
173
|
+
return t.openBlock(),t.createElementBlock(t.Fragment,null,[t.createVNode(t.unref(R),{ref_key:"inputRef",ref:i,role:"combobox",tabindex:"0",class:t.normalizeClass(["q-select",{"q-select--readonly":n.readonly,"q-select--disabled":n.disabled,"q-select--expanded":a.value}]),readonly:"",disabled:n.disabled,"aria-expanded":a.value,"aria-haspopup":"listbox",size:n.size,onClick:m,onKeydown:t.withModifiers(g,["stop"])},t.createSlots({append:t.withCtx((()=>[f.value&&l.value?(t.openBlock(),t.createBlock(t.unref(T),t.mergeProps({key:0},n.icons.clear,{class:"q-select__clear",onClick:t.withModifiers(p,["stop","prevent"])}),null,16,["onClick"])):t.createCommentVNode("",!0),n.readonly||n.disabled?t.createCommentVNode("",!0):(t.openBlock(),t.createBlock(t.unref(T),t.mergeProps({key:1},n.icons.chevron,{class:"q-select__chevron"}),null,16))])),default:t.withCtx((()=>[l.value?(t.openBlock(),t.createElementBlock(t.Fragment,{key:0},[t.createTextVNode(t.toDisplayString(u.value),1)],64)):(t.openBlock(),t.createElementBlock("span",ve,t.toDisplayString(e.texts.placeholder),1))])),_:2},[null!=(r=d.value)&&r.icon?{name:"prepend",fn:t.withCtx((()=>{var e
|
|
174
|
+
return[t.createVNode(t.unref(T),t.normalizeProps(t.guardReactiveProps(null==(e=d.value)?void 0:e.icon)),null,16)]})),key:"0"}:void 0]),1032,["class","disabled","aria-expanded","size","onKeydown"]),t.createVNode(t.unref(ce),{"model-value":a.value,spy:"",trigger:"manual",placement:"bottom",width:"anchor",offset:2,anchor:null==(y=i.value)?void 0:y.$el,onEnter:k,onLeave:b},{default:t.withCtx((()=>[t.withDirectives((t.openBlock(),t.createElementBlock("div",{ref_key:"contentRef",ref:c,class:"q-select__body"},[t.renderSlot(e.$slots,"body.prepend"),n.loading?(t.openBlock(),t.createBlock(t.unref(C),{key:0,class:"q-select__loader",size:24})):(t.openBlock(),t.createBlock(t.unref(ee),{key:1,ref_key:"listRef",ref:s,class:"q-select__items",modelValue:l.value,"onUpdate:modelValue":[o[0]||(o[0]=e=>l.value=e),v],items:n.items,groups:e.groups,"item-label":n.itemLabel,"item-value":n.itemValue,onKeydown:t.withModifiers(g,["stop"])},null,8,["modelValue","items","groups","item-label","item-value","onKeydown"])),t.renderSlot(e.$slots,"body.append")])),[[t.unref(he),h]])])),_:3},8,["model-value","anchor"])],64)}}})),be=["innerHTML"],we={key:1},Be=B(t.defineComponent({__name:"QTooltip",props:{modelValue:{type:Boolean},anchor:{},appearance:{default:"inverted"},arrow:{type:Boolean,default:!0},attach:{default:"body"},delay:{default:500},disabled:{type:Boolean},html:{type:Boolean,default:!0},placement:{default:"right"},text:{},trigger:{default:"hover"}},setup(e){const o=e
|
|
175
|
+
return(e,n)=>(t.openBlock(),t.createBlock(t.unref(ce),{"model-value":o.modelValue,anchor:o.anchor,appearance:o.appearance,arrow:o.arrow,attach:o.attach,"content-classes":["q-tooltip"],delay:o.delay,disabled:o.disabled,placement:o.placement,trigger:o.trigger},{default:t.withCtx((()=>[o.html?(t.openBlock(),t.createElementBlock("span",{key:0,innerHTML:o.text},null,8,be)):(t.openBlock(),t.createElementBlock("span",we,t.toDisplayString(o.text),1))])),_:1},8,["model-value","anchor","appearance","arrow","attach","delay","disabled","placement","trigger"]))}}))
|
|
176
|
+
e.QButton=x,e.QButtonGroup=V,e.QButtonToggle=$,e.QIcon=T,e.QIconFont=A,e.QIconImg=F,e.QIconSvg=M,e.QInput=R,e.QLineLoader=U,e.QList=ee,e.QListItem=te,e.QListItemGroup=oe,e.QOverlay=ce,e.QPopover=me,e.QSelect=ke,e.QSpinnerLoader=C,e.QTooltip=Be,e.clickOutside=he,e.createFramework=function(e={}){return{install:t=>{const o=e.components||{}
|
|
175
177
|
for(const e in o)t.component(e,o[e])
|
|
176
178
|
const n=e.directives||{}
|
|
177
179
|
for(const e in n)t.directive(e,n[e])
|
|
178
|
-
const
|
|
179
|
-
t.provide(l
|
|
180
|
-
if(!e)throw new Error("[
|
|
180
|
+
const l=e.defaults||{}
|
|
181
|
+
t.provide(a,l),g(t,e.themes)}}},e.defaultDarkColorScheme=c,e.defaultLightColorScheme=s,e.useTheme=function(){const e=t.inject(y)
|
|
182
|
+
if(!e)throw new Error("[Quidgest UI] Could not find theme instance")
|
|
181
183
|
return e},Object.defineProperty(e,Symbol.toStringTag,{value:"Module"})}))
|
|
182
184
|
//# sourceMappingURL=ui.min.js.map
|