@runeya/runeya 1.33.20 → 1.33.22
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/node-red-contrib-runeya.tar +0 -0
- package/package.json +1 -1
- package/public/assets/{App-BVTb2f1U.css → App-BGPtogo-.css} +1 -1
- package/public/assets/App-Bj3c8ECd.js +101 -0
- package/public/assets/Bugs-B6LM8YSZ.js +1 -0
- package/public/assets/Bugs-DZVuTDKA.css +1 -0
- package/public/assets/Configs-CRGDsvnb.js +464 -0
- package/public/assets/Configs-DdBteQMK.css +1 -0
- package/public/assets/CurrentEditor-DI0XEvLu.js +1 -0
- package/public/assets/DynamicComponent-CmXZUvVU.js +1 -0
- package/public/assets/DynamicComponent-DgxRO4Pl.css +1 -0
- package/public/assets/{Editor-Ck3cFVn3.js → Editor-CBZeVePs.js} +7 -7
- package/public/assets/{Editor-BC23IeB6.css → Editor-CPPFMOjb.css} +1 -1
- package/public/assets/Git-Cf-zgTWr.js +11 -0
- package/public/assets/Git-UQIt5ANe.css +1 -0
- package/public/assets/ImportCreate-DZSPN5cY.js +1 -0
- package/public/assets/Index-BJieQWaU.js +1 -0
- package/public/assets/Index-BcFahN3S.css +1 -0
- package/public/assets/Index-BrbegLuT.js +1 -0
- package/public/assets/Index-C3gFkhHj.js +1 -0
- package/public/assets/Index-C66tLKvy.css +1 -0
- package/public/assets/Index-Cd-qd5VG.css +1 -0
- package/public/assets/Index-Cg-pTjT5.js +1 -0
- package/public/assets/Index-CvhWs0kp.css +1 -0
- package/public/assets/Index-D67OAIVa.js +314 -0
- package/public/assets/Index-DZ8CXixy.js +1 -0
- package/public/assets/{Init-Lt-2DFbi.js → Init-BILP6lrr.js} +1 -1
- package/public/assets/{LeftLogo-fTp83qX1.js → LeftLogo-BCYb654E.js} +1 -1
- package/public/assets/Logs-BfqPcp-L.js +74 -0
- package/public/assets/Logs-BhdfGaw5.css +32 -0
- package/public/assets/{Markdown-CNWZoHio.js → Markdown-CuewGlVj.js} +19 -103
- package/public/assets/Modal-CGUZawhK.css +1 -0
- package/public/assets/Modal-DmKdmCtc.js +1 -0
- package/public/assets/Modals-BHTrmB19.js +1 -0
- package/public/assets/NotUpToDate-CnmuPdX-.js +1 -0
- package/public/assets/NotUpToDate-Dh9RbAwK.css +1 -0
- package/public/assets/Npm-HBPCi13F.js +1 -0
- package/public/assets/Npm-KBzO1DYv.css +1 -0
- package/public/assets/Overview-CRtTdDEz.js +1 -0
- package/public/assets/Overview-DZIOmzKx.css +1 -0
- package/public/assets/{Section-BC6pA1HZ.js → Section-OccJuk7A.js} +1 -1
- package/public/assets/{Settings-Dp_ktsgs.js → Settings-CgEyOTsE.js} +6 -6
- package/public/assets/{Settings-BBbk67zT.css → Settings-DUCkJDco.css} +1 -1
- package/public/assets/Spinner-BMGbc3X9.js +1 -0
- package/public/assets/Spinner-BZXOybIg.css +1 -0
- package/public/assets/StackChooser-DBof37zx.js +1 -0
- package/public/assets/{StackChooser-CsNxPvyi.js → StackChooser-PJ4_aCX-.js} +1 -1
- package/public/assets/StackMultiple-CiXqkibR.css +1 -0
- package/public/assets/{StackMultiple-BeZmv6DX.js → StackMultiple-D0bM6dXR.js} +17 -17
- package/public/assets/{StackSingle-DBZX9nN_.css → StackSingle-BVHxvisP.css} +1 -1
- package/public/assets/StackSingle-D1Yk8PXD.js +1 -0
- package/public/assets/{Tabs-fu2myJd9.css → Tabs-BGPqRkjE.css} +1 -1
- package/public/assets/Tabs-DQDvjS5y.js +1 -0
- package/public/assets/Theme-CzHFcMoz.js +1 -0
- package/public/assets/Toolbox-B5KXz4eX.css +1 -0
- package/public/assets/Toolbox-C5XEPDmg.js +1 -0
- package/public/assets/_baseFor-DiPelG4M.js +1 -0
- package/public/assets/_commonjsHelpers-D6-XlEtG.js +1 -0
- package/public/assets/{cssMode-DptFVzSA.js → cssMode-CccHpseG.js} +1 -1
- package/public/assets/currentEditor-DKB6Zox9.js +1 -0
- package/public/assets/dayjs.min-CfWDS3UC.js +1 -0
- package/public/assets/{freemarker2-Nj-3NhAz.js → freemarker2-DSPhVVzD.js} +1 -1
- package/public/assets/fs-CwxHstJI.js +1 -0
- package/public/assets/{handlebars-DccXq6O-.js → handlebars-1zANa-F3.js} +1 -1
- package/public/assets/{html-BFezHwqy.js → html-fsS26eC3.js} +1 -1
- package/public/assets/{htmlMode-8pIWMfce.js → htmlMode-DvnqyT9t.js} +1 -1
- package/public/assets/index-0X67tmWL.js +82 -0
- package/public/assets/index-B3Vh_zdc.js +1454 -0
- package/public/assets/index-B614CRIK.js +201 -0
- package/public/assets/index-BO82C_5u.js +720 -0
- package/public/assets/index-Brqxsm84.js +308 -0
- package/public/assets/index-CILDVkDy.js +310 -0
- package/public/assets/{index--FPUu8lq.css → index-D9v3u7Fv.css} +1 -1
- package/public/assets/index-DcbuCmxJ.js +84 -0
- package/public/assets/{index-DVXSyllr.js → index-G_rNbFve.js} +2 -2
- package/public/assets/index-d75RPzOA.js +176 -0
- package/public/assets/index-uWoKtv9r.js +2 -0
- package/public/assets/{javascript-B0mQdjwH.js → javascript-DRHvp6-v.js} +1 -1
- package/public/assets/json-tree-view-vue3.es-DVJTi2Rq.js +1 -0
- package/public/assets/{jsonMode-BuKXiIei.js → jsonMode-CJHmEzcn.js} +1 -1
- package/public/assets/{liquid-9G58QM1k.js → liquid-V1Od9uns.js} +1 -1
- package/public/assets/lodash-D2RHCRSL.js +27 -0
- package/public/assets/{mdx-DWeREtqy.js → mdx-DlWa4FFs.js} +1 -1
- package/public/assets/{python-BZtttaDe.js → python-DawPqpxL.js} +1 -1
- package/public/assets/{razor-CIhED9yj.js → razor-CrbHGO04.js} +1 -1
- package/public/assets/router-DPuc_QdV.css +1 -0
- package/public/assets/router-Dzu6a_zz.js +103 -0
- package/public/assets/sort-BibmqbFD.js +1 -0
- package/public/assets/{system-IAlLmFx7.js → system-BqvwX5_3.js} +1 -1
- package/public/assets/{tsMode-BMdhWjVC.js → tsMode-Cb1yqXWI.js} +1 -1
- package/public/assets/{typescript-DurNSXGF.js → typescript-CnZCKV3a.js} +1 -1
- package/public/assets/{xml-Ckok0faQ.js → xml-B90p6BQJ.js} +1 -1
- package/public/assets/{yaml-C2OtFevY.js → yaml-Bkk9HYtt.js} +1 -1
- package/public/index.html +1 -1
- package/www.js +144 -131
- package/www.js.map +1 -1
- package/public/assets/App-CxWYnNM-.js +0 -101
- package/public/assets/CurrentEditor-C38cqf-Z.js +0 -1
- package/public/assets/ImportCreate-DFEf3KiI.js +0 -1
- package/public/assets/Overview-BaSpvlXu.css +0 -1
- package/public/assets/Overview-DR4QmO04.js +0 -1
- package/public/assets/StackChooser-vHgodEvA.js +0 -1
- package/public/assets/StackMultiple-Dw-7UAYX.css +0 -1
- package/public/assets/StackSingle-Bza6Vusw.js +0 -1
- package/public/assets/Tabs-DMteuptw.js +0 -1
- package/public/assets/router-BIesWMTV.css +0 -32
- package/public/assets/router-BaBuIyxA.js +0 -4232
|
@@ -0,0 +1,308 @@
|
|
|
1
|
+
import{s as ze,a as Fe,c as te}from"./index-uWoKtv9r.js";import{a as b,o as p,b as V,I as c,bo as Ve,h as O,s as R,g as E,M as Me,bp as Te,y as ge,B as ve,D as be,bq as ne,bf as $,bg as Z,l as B,F as U,q as re,e as j,aJ as J,b5 as Pe,aL as ue,aM as Be,br as Ee,E as D,aq as Ke,ar as xe,as as De,at as Ae,au as He,av as le,aw as Re,bi as je,bd as Ge,bs as Ne,bt as We,aN as N,G as Ue,d as oe,t as A,H as ce,n as ie,f as W,T as qe,aS as $e,J as Ze,m as Je,O as Qe}from"./index-G_rNbFve.js";import{a as ye,b as Oe,d as Xe,e as Ye,c as _e,f as et,g as tt,s as it,R as nt}from"./index-d75RPzOA.js";var Ie={name:"TimesIcon",extends:ye};function st(t,e,i,s,l,n){return p(),b("svg",c({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t.pti()),e[0]||(e[0]=[V("path",{d:"M8.01186 7.00933L12.27 2.75116C12.341 2.68501 12.398 2.60524 12.4375 2.51661C12.4769 2.42798 12.4982 2.3323 12.4999 2.23529C12.5016 2.13827 12.4838 2.0419 12.4474 1.95194C12.4111 1.86197 12.357 1.78024 12.2884 1.71163C12.2198 1.64302 12.138 1.58893 12.0481 1.55259C11.9581 1.51625 11.8617 1.4984 11.7647 1.50011C11.6677 1.50182 11.572 1.52306 11.4834 1.56255C11.3948 1.60204 11.315 1.65898 11.2488 1.72997L6.99067 5.98814L2.7325 1.72997C2.59553 1.60234 2.41437 1.53286 2.22718 1.53616C2.03999 1.53946 1.8614 1.61529 1.72901 1.74767C1.59663 1.88006 1.5208 2.05865 1.5175 2.24584C1.5142 2.43303 1.58368 2.61419 1.71131 2.75116L5.96948 7.00933L1.71131 11.2675C1.576 11.403 1.5 11.5866 1.5 11.7781C1.5 11.9696 1.576 12.1532 1.71131 12.2887C1.84679 12.424 2.03043 12.5 2.2219 12.5C2.41338 12.5 2.59702 12.424 2.7325 12.2887L6.99067 8.03052L11.2488 12.2887C11.3843 12.424 11.568 12.5 11.7594 12.5C11.9509 12.5 12.1346 12.424 12.27 12.2887C12.4053 12.1532 12.4813 11.9696 12.4813 11.7781C12.4813 11.5866 12.4053 11.403 12.27 11.2675L8.01186 7.00933Z",fill:"currentColor"},null,-1)]),16)}Ie.render=st;var we={name:"Portal",props:{appendTo:{type:[String,Object],default:"body"},disabled:{type:Boolean,default:!1}},data:function(){return{mounted:!1}},mounted:function(){this.mounted=Ve()},computed:{inline:function(){return this.disabled||this.appendTo==="self"}}};function lt(t,e,i,s,l,n){return n.inline?O(t.$slots,"default",{key:0}):l.mounted?(p(),R(Me,{key:1,to:i.appendTo},[O(t.$slots,"default")],8,["to"])):E("",!0)}we.render=lt;var Se={name:"BlankIcon",extends:ye};function ot(t,e,i,s,l,n){return p(),b("svg",c({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t.pti()),e[0]||(e[0]=[V("rect",{width:"1",height:"1",fill:"currentColor","fill-opacity":"0"},null,-1)]),16)}Se.render=ot;var rt=Te(),at=ge`
|
|
2
|
+
.p-virtualscroller-loader {
|
|
3
|
+
background: dt('virtualscroller.loader.mask.background');
|
|
4
|
+
color: dt('virtualscroller.loader.mask.color');
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.p-virtualscroller-loading-icon {
|
|
8
|
+
font-size: dt('virtualscroller.loader.icon.size');
|
|
9
|
+
width: dt('virtualscroller.loader.icon.size');
|
|
10
|
+
height: dt('virtualscroller.loader.icon.size');
|
|
11
|
+
}
|
|
12
|
+
`,dt=`
|
|
13
|
+
.p-virtualscroller {
|
|
14
|
+
position: relative;
|
|
15
|
+
overflow: auto;
|
|
16
|
+
contain: strict;
|
|
17
|
+
transform: translateZ(0);
|
|
18
|
+
will-change: scroll-position;
|
|
19
|
+
outline: 0 none;
|
|
20
|
+
}
|
|
21
|
+
|
|
22
|
+
.p-virtualscroller-content {
|
|
23
|
+
position: absolute;
|
|
24
|
+
top: 0;
|
|
25
|
+
left: 0;
|
|
26
|
+
min-height: 100%;
|
|
27
|
+
min-width: 100%;
|
|
28
|
+
will-change: transform;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.p-virtualscroller-spacer {
|
|
32
|
+
position: absolute;
|
|
33
|
+
top: 0;
|
|
34
|
+
left: 0;
|
|
35
|
+
height: 1px;
|
|
36
|
+
width: 1px;
|
|
37
|
+
transform-origin: 0 0;
|
|
38
|
+
pointer-events: none;
|
|
39
|
+
}
|
|
40
|
+
|
|
41
|
+
.p-virtualscroller-loader {
|
|
42
|
+
position: sticky;
|
|
43
|
+
top: 0;
|
|
44
|
+
left: 0;
|
|
45
|
+
width: 100%;
|
|
46
|
+
height: 100%;
|
|
47
|
+
}
|
|
48
|
+
|
|
49
|
+
.p-virtualscroller-loader-mask {
|
|
50
|
+
display: flex;
|
|
51
|
+
align-items: center;
|
|
52
|
+
justify-content: center;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.p-virtualscroller-horizontal > .p-virtualscroller-content {
|
|
56
|
+
display: flex;
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
.p-virtualscroller-inline .p-virtualscroller-content {
|
|
60
|
+
position: static;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.p-virtualscroller .p-virtualscroller-loading {
|
|
64
|
+
transform: none !important;
|
|
65
|
+
min-height: 0;
|
|
66
|
+
position: sticky;
|
|
67
|
+
inset-block-start: 0;
|
|
68
|
+
inset-inline-start: 0;
|
|
69
|
+
}
|
|
70
|
+
`,he=ve.extend({name:"virtualscroller",css:dt,style:at}),ut={name:"BaseVirtualScroller",extends:ze,props:{id:{type:String,default:null},style:null,class:null,items:{type:Array,default:null},itemSize:{type:[Number,Array],default:0},scrollHeight:null,scrollWidth:null,orientation:{type:String,default:"vertical"},numToleratedItems:{type:Number,default:null},delay:{type:Number,default:0},resizeDelay:{type:Number,default:10},lazy:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},loaderDisabled:{type:Boolean,default:!1},columns:{type:Array,default:null},loading:{type:Boolean,default:!1},showSpacer:{type:Boolean,default:!0},showLoader:{type:Boolean,default:!1},tabindex:{type:Number,default:0},inline:{type:Boolean,default:!1},step:{type:Number,default:0},appendOnly:{type:Boolean,default:!1},autoSize:{type:Boolean,default:!1}},style:he,provide:function(){return{$pcVirtualScroller:this,$parentInstance:this}},beforeMount:function(){var e;he.loadCSS({nonce:(e=this.$primevueConfig)===null||e===void 0||(e=e.csp)===null||e===void 0?void 0:e.nonce})}};function X(t){"@babel/helpers - typeof";return X=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},X(t)}function pe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter(function(l){return Object.getOwnPropertyDescriptor(t,l).enumerable})),i.push.apply(i,s)}return i}function Q(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?pe(Object(i),!0).forEach(function(s){Le(t,s,i[s])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):pe(Object(i)).forEach(function(s){Object.defineProperty(t,s,Object.getOwnPropertyDescriptor(i,s))})}return t}function Le(t,e,i){return(e=ct(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function ct(t){var e=ht(t,"string");return X(e)=="symbol"?e:e+""}function ht(t,e){if(X(t)!="object"||!t)return t;var i=t[Symbol.toPrimitive];if(i!==void 0){var s=i.call(t,e);if(X(s)!="object")return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Ce={name:"VirtualScroller",extends:ut,inheritAttrs:!1,emits:["update:numToleratedItems","scroll","scroll-index-change","lazy-load"],data:function(){var e=this.isBoth();return{first:e?{rows:0,cols:0}:0,last:e?{rows:0,cols:0}:0,page:e?{rows:0,cols:0}:0,numItemsInViewport:e?{rows:0,cols:0}:0,lastScrollPos:e?{top:0,left:0}:0,d_numToleratedItems:this.numToleratedItems,d_loading:this.loading,loaderArr:[],spacerStyle:{},contentStyle:{}}},element:null,content:null,lastScrollPos:null,scrollTimeout:null,resizeTimeout:null,defaultWidth:0,defaultHeight:0,defaultContentWidth:0,defaultContentHeight:0,isRangeChanged:!1,lazyLoadState:{},resizeListener:null,resizeObserver:null,initialized:!1,watch:{numToleratedItems:function(e){this.d_numToleratedItems=e},loading:function(e,i){this.lazy&&e!==i&&e!==this.d_loading&&(this.d_loading=e)},items:{handler:function(e,i){(!i||i.length!==(e||[]).length)&&(this.init(),this.calculateAutoSize())},deep:!0},itemSize:function(){this.init(),this.calculateAutoSize()},orientation:function(){this.lastScrollPos=this.isBoth()?{top:0,left:0}:0},scrollHeight:function(){this.init(),this.calculateAutoSize()},scrollWidth:function(){this.init(),this.calculateAutoSize()}},mounted:function(){this.viewInit(),this.lastScrollPos=this.isBoth()?{top:0,left:0}:0,this.lazyLoadState=this.lazyLoadState||{}},updated:function(){!this.initialized&&this.viewInit()},unmounted:function(){this.unbindResizeListener(),this.initialized=!1},methods:{viewInit:function(){ne(this.element)&&(this.setContentEl(this.content),this.init(),this.calculateAutoSize(),this.bindResizeListener(),this.defaultWidth=$(this.element),this.defaultHeight=Z(this.element),this.defaultContentWidth=$(this.content),this.defaultContentHeight=Z(this.content),this.initialized=!0)},init:function(){this.disabled||(this.setSize(),this.calculateOptions(),this.setSpacerSize())},isVertical:function(){return this.orientation==="vertical"},isHorizontal:function(){return this.orientation==="horizontal"},isBoth:function(){return this.orientation==="both"},scrollTo:function(e){this.element&&this.element.scrollTo(e)},scrollToIndex:function(e){var i=this,s=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"auto",l=this.isBoth(),n=this.isHorizontal(),o=l?e.every(function(m){return m>-1}):e>-1;if(o){var a=this.first,d=this.element,u=d.scrollTop,r=u===void 0?0:u,h=d.scrollLeft,y=h===void 0?0:h,L=this.calculateNumItems(),I=L.numToleratedItems,S=this.getContentPosition(),g=this.itemSize,C=function(){var v=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,K=arguments.length>1?arguments[1]:void 0;return v<=K?0:v},k=function(v,K,T){return v*K+T},z=function(){var v=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,K=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return i.scrollTo({left:v,top:K,behavior:s})},f=l?{rows:0,cols:0}:0,x=!1,F=!1;l?(f={rows:C(e[0],I[0]),cols:C(e[1],I[1])},z(k(f.cols,g[1],S.left),k(f.rows,g[0],S.top)),F=this.lastScrollPos.top!==r||this.lastScrollPos.left!==y,x=f.rows!==a.rows||f.cols!==a.cols):(f=C(e,I),n?z(k(f,g,S.left),r):z(y,k(f,g,S.top)),F=this.lastScrollPos!==(n?y:r),x=f!==a),this.isRangeChanged=x,F&&(this.first=f)}},scrollInView:function(e,i){var s=this,l=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"auto";if(i){var n=this.isBoth(),o=this.isHorizontal(),a=n?e.every(function(g){return g>-1}):e>-1;if(a){var d=this.getRenderedRange(),u=d.first,r=d.viewport,h=function(){var C=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,k=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return s.scrollTo({left:C,top:k,behavior:l})},y=i==="to-start",L=i==="to-end";if(y){if(n)r.first.rows-u.rows>e[0]?h(r.first.cols*this.itemSize[1],(r.first.rows-1)*this.itemSize[0]):r.first.cols-u.cols>e[1]&&h((r.first.cols-1)*this.itemSize[1],r.first.rows*this.itemSize[0]);else if(r.first-u>e){var I=(r.first-1)*this.itemSize;o?h(I,0):h(0,I)}}else if(L){if(n)r.last.rows-u.rows<=e[0]+1?h(r.first.cols*this.itemSize[1],(r.first.rows+1)*this.itemSize[0]):r.last.cols-u.cols<=e[1]+1&&h((r.first.cols+1)*this.itemSize[1],r.first.rows*this.itemSize[0]);else if(r.last-u<=e+1){var S=(r.first+1)*this.itemSize;o?h(S,0):h(0,S)}}}}else this.scrollToIndex(e,l)},getRenderedRange:function(){var e=function(h,y){return Math.floor(h/(y||h))},i=this.first,s=0;if(this.element){var l=this.isBoth(),n=this.isHorizontal(),o=this.element,a=o.scrollTop,d=o.scrollLeft;if(l)i={rows:e(a,this.itemSize[0]),cols:e(d,this.itemSize[1])},s={rows:i.rows+this.numItemsInViewport.rows,cols:i.cols+this.numItemsInViewport.cols};else{var u=n?d:a;i=e(u,this.itemSize),s=i+this.numItemsInViewport}}return{first:this.first,last:this.last,viewport:{first:i,last:s}}},calculateNumItems:function(){var e=this.isBoth(),i=this.isHorizontal(),s=this.itemSize,l=this.getContentPosition(),n=this.element?this.element.offsetWidth-l.left:0,o=this.element?this.element.offsetHeight-l.top:0,a=function(y,L){return Math.ceil(y/(L||y))},d=function(y){return Math.ceil(y/2)},u=e?{rows:a(o,s[0]),cols:a(n,s[1])}:a(i?n:o,s),r=this.d_numToleratedItems||(e?[d(u.rows),d(u.cols)]:d(u));return{numItemsInViewport:u,numToleratedItems:r}},calculateOptions:function(){var e=this,i=this.isBoth(),s=this.first,l=this.calculateNumItems(),n=l.numItemsInViewport,o=l.numToleratedItems,a=function(r,h,y){var L=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!1;return e.getLast(r+h+(r<y?2:3)*y,L)},d=i?{rows:a(s.rows,n.rows,o[0]),cols:a(s.cols,n.cols,o[1],!0)}:a(s,n,o);this.last=d,this.numItemsInViewport=n,this.d_numToleratedItems=o,this.$emit("update:numToleratedItems",this.d_numToleratedItems),this.showLoader&&(this.loaderArr=i?Array.from({length:n.rows}).map(function(){return Array.from({length:n.cols})}):Array.from({length:n})),this.lazy&&Promise.resolve().then(function(){var u;e.lazyLoadState={first:e.step?i?{rows:0,cols:s.cols}:0:s,last:Math.min(e.step?e.step:d,((u=e.items)===null||u===void 0?void 0:u.length)||0)},e.$emit("lazy-load",e.lazyLoadState)})},calculateAutoSize:function(){var e=this;this.autoSize&&!this.d_loading&&Promise.resolve().then(function(){if(e.content){var i=e.isBoth(),s=e.isHorizontal(),l=e.isVertical();e.content.style.minHeight=e.content.style.minWidth="auto",e.content.style.position="relative",e.element.style.contain="none";var n=[$(e.element),Z(e.element)],o=n[0],a=n[1];(i||s)&&(e.element.style.width=o<e.defaultWidth?o+"px":e.scrollWidth||e.defaultWidth+"px"),(i||l)&&(e.element.style.height=a<e.defaultHeight?a+"px":e.scrollHeight||e.defaultHeight+"px"),e.content.style.minHeight=e.content.style.minWidth="",e.content.style.position="",e.element.style.contain=""}})},getLast:function(){var e,i,s=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,l=arguments.length>1?arguments[1]:void 0;return this.items?Math.min(l?((e=this.columns||this.items[0])===null||e===void 0?void 0:e.length)||0:((i=this.items)===null||i===void 0?void 0:i.length)||0,s):0},getContentPosition:function(){if(this.content){var e=getComputedStyle(this.content),i=parseFloat(e.paddingLeft)+Math.max(parseFloat(e.left)||0,0),s=parseFloat(e.paddingRight)+Math.max(parseFloat(e.right)||0,0),l=parseFloat(e.paddingTop)+Math.max(parseFloat(e.top)||0,0),n=parseFloat(e.paddingBottom)+Math.max(parseFloat(e.bottom)||0,0);return{left:i,right:s,top:l,bottom:n,x:i+s,y:l+n}}return{left:0,right:0,top:0,bottom:0,x:0,y:0}},setSize:function(){var e=this;if(this.element){var i=this.isBoth(),s=this.isHorizontal(),l=this.element.parentElement,n=this.scrollWidth||"".concat(this.element.offsetWidth||l.offsetWidth,"px"),o=this.scrollHeight||"".concat(this.element.offsetHeight||l.offsetHeight,"px"),a=function(u,r){return e.element.style[u]=r};i||s?(a("height",o),a("width",n)):a("height",o)}},setSpacerSize:function(){var e=this,i=this.items;if(i){var s=this.isBoth(),l=this.isHorizontal(),n=this.getContentPosition(),o=function(d,u,r){var h=arguments.length>3&&arguments[3]!==void 0?arguments[3]:0;return e.spacerStyle=Q(Q({},e.spacerStyle),Le({},"".concat(d),(u||[]).length*r+h+"px"))};s?(o("height",i,this.itemSize[0],n.y),o("width",this.columns||i[1],this.itemSize[1],n.x)):l?o("width",this.columns||i,this.itemSize,n.x):o("height",i,this.itemSize,n.y)}},setContentPosition:function(e){var i=this;if(this.content&&!this.appendOnly){var s=this.isBoth(),l=this.isHorizontal(),n=e?e.first:this.first,o=function(r,h){return r*h},a=function(){var r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:0,h=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0;return i.contentStyle=Q(Q({},i.contentStyle),{transform:"translate3d(".concat(r,"px, ").concat(h,"px, 0)")})};if(s)a(o(n.cols,this.itemSize[1]),o(n.rows,this.itemSize[0]));else{var d=o(n,this.itemSize);l?a(d,0):a(0,d)}}},onScrollPositionChange:function(e){var i=this,s=e.target,l=this.isBoth(),n=this.isHorizontal(),o=this.getContentPosition(),a=function(w,M){return w?w>M?w-M:w:0},d=function(w,M){return Math.floor(w/(M||w))},u=function(w,M,q,_,P,H){return w<=P?P:H?q-_-P:M+P-1},r=function(w,M,q,_,P,H,ee,ke){if(w<=H)return 0;var se=Math.max(0,ee?w<M?q:w-H:w>M?q:w-2*H),de=i.getLast(se,ke);return se>de?de-P:se},h=function(w,M,q,_,P,H){var ee=M+_+2*P;return w>=P&&(ee+=P+1),i.getLast(ee,H)},y=a(s.scrollTop,o.top),L=a(s.scrollLeft,o.left),I=l?{rows:0,cols:0}:0,S=this.last,g=!1,C=this.lastScrollPos;if(l){var k=this.lastScrollPos.top<=y,z=this.lastScrollPos.left<=L;if(!this.appendOnly||this.appendOnly&&(k||z)){var f={rows:d(y,this.itemSize[0]),cols:d(L,this.itemSize[1])},x={rows:u(f.rows,this.first.rows,this.last.rows,this.numItemsInViewport.rows,this.d_numToleratedItems[0],k),cols:u(f.cols,this.first.cols,this.last.cols,this.numItemsInViewport.cols,this.d_numToleratedItems[1],z)};I={rows:r(f.rows,x.rows,this.first.rows,this.last.rows,this.numItemsInViewport.rows,this.d_numToleratedItems[0],k),cols:r(f.cols,x.cols,this.first.cols,this.last.cols,this.numItemsInViewport.cols,this.d_numToleratedItems[1],z,!0)},S={rows:h(f.rows,I.rows,this.last.rows,this.numItemsInViewport.rows,this.d_numToleratedItems[0]),cols:h(f.cols,I.cols,this.last.cols,this.numItemsInViewport.cols,this.d_numToleratedItems[1],!0)},g=I.rows!==this.first.rows||S.rows!==this.last.rows||I.cols!==this.first.cols||S.cols!==this.last.cols||this.isRangeChanged,C={top:y,left:L}}}else{var F=n?L:y,m=this.lastScrollPos<=F;if(!this.appendOnly||this.appendOnly&&m){var v=d(F,this.itemSize),K=u(v,this.first,this.last,this.numItemsInViewport,this.d_numToleratedItems,m);I=r(v,K,this.first,this.last,this.numItemsInViewport,this.d_numToleratedItems,m),S=h(v,I,this.last,this.numItemsInViewport,this.d_numToleratedItems),g=I!==this.first||S!==this.last||this.isRangeChanged,C=F}}return{first:I,last:S,isRangeChanged:g,scrollPos:C}},onScrollChange:function(e){var i=this.onScrollPositionChange(e),s=i.first,l=i.last,n=i.isRangeChanged,o=i.scrollPos;if(n){var a={first:s,last:l};if(this.setContentPosition(a),this.first=s,this.last=l,this.lastScrollPos=o,this.$emit("scroll-index-change",a),this.lazy&&this.isPageChanged(s)){var d,u,r={first:this.step?Math.min(this.getPageByFirst(s)*this.step,(((d=this.items)===null||d===void 0?void 0:d.length)||0)-this.step):s,last:Math.min(this.step?(this.getPageByFirst(s)+1)*this.step:l,((u=this.items)===null||u===void 0?void 0:u.length)||0)},h=this.lazyLoadState.first!==r.first||this.lazyLoadState.last!==r.last;h&&this.$emit("lazy-load",r),this.lazyLoadState=r}}},onScroll:function(e){var i=this;if(this.$emit("scroll",e),this.delay){if(this.scrollTimeout&&clearTimeout(this.scrollTimeout),this.isPageChanged()){if(!this.d_loading&&this.showLoader){var s=this.onScrollPositionChange(e),l=s.isRangeChanged,n=l||(this.step?this.isPageChanged():!1);n&&(this.d_loading=!0)}this.scrollTimeout=setTimeout(function(){i.onScrollChange(e),i.d_loading&&i.showLoader&&(!i.lazy||i.loading===void 0)&&(i.d_loading=!1,i.page=i.getPageByFirst())},this.delay)}}else this.onScrollChange(e)},onResize:function(){var e=this;this.resizeTimeout&&clearTimeout(this.resizeTimeout),this.resizeTimeout=setTimeout(function(){if(ne(e.element)){var i=e.isBoth(),s=e.isVertical(),l=e.isHorizontal(),n=[$(e.element),Z(e.element)],o=n[0],a=n[1],d=o!==e.defaultWidth,u=a!==e.defaultHeight,r=i?d||u:l?d:s?u:!1;r&&(e.d_numToleratedItems=e.numToleratedItems,e.defaultWidth=o,e.defaultHeight=a,e.defaultContentWidth=$(e.content),e.defaultContentHeight=Z(e.content),e.init())}},this.resizeDelay)},bindResizeListener:function(){var e=this;this.resizeListener||(this.resizeListener=this.onResize.bind(this),window.addEventListener("resize",this.resizeListener),window.addEventListener("orientationchange",this.resizeListener),this.resizeObserver=new ResizeObserver(function(){e.onResize()}),this.resizeObserver.observe(this.element))},unbindResizeListener:function(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),window.removeEventListener("orientationchange",this.resizeListener),this.resizeListener=null),this.resizeObserver&&(this.resizeObserver.disconnect(),this.resizeObserver=null)},getOptions:function(e){var i=(this.items||[]).length,s=this.isBoth()?this.first.rows+e:this.first+e;return{index:s,count:i,first:s===0,last:s===i-1,even:s%2===0,odd:s%2!==0}},getLoaderOptions:function(e,i){var s=this.loaderArr.length;return Q({index:e,count:s,first:e===0,last:e===s-1,even:e%2===0,odd:e%2!==0},i)},getPageByFirst:function(e){return Math.floor(((e??this.first)+this.d_numToleratedItems*4)/(this.step||1))},isPageChanged:function(e){return this.step&&!this.lazy?this.page!==this.getPageByFirst(e??this.first):!0},setContentEl:function(e){this.content=e||this.content||be(this.element,'[data-pc-section="content"]')},elementRef:function(e){this.element=e},contentRef:function(e){this.content=e}},computed:{containerClass:function(){return["p-virtualscroller",this.class,{"p-virtualscroller-inline":this.inline,"p-virtualscroller-both p-both-scroll":this.isBoth(),"p-virtualscroller-horizontal p-horizontal-scroll":this.isHorizontal()}]},contentClass:function(){return["p-virtualscroller-content",{"p-virtualscroller-loading":this.d_loading}]},loaderClass:function(){return["p-virtualscroller-loader",{"p-virtualscroller-loader-mask":!this.$slots.loader}]},loadedItems:function(){var e=this;return this.items&&!this.d_loading?this.isBoth()?this.items.slice(this.appendOnly?0:this.first.rows,this.last.rows).map(function(i){return e.columns?i:i.slice(e.appendOnly?0:e.first.cols,e.last.cols)}):this.isHorizontal()&&this.columns?this.items:this.items.slice(this.appendOnly?0:this.first,this.last):[]},loadedRows:function(){return this.d_loading?this.loaderDisabled?this.loaderArr:[]:this.loadedItems},loadedColumns:function(){if(this.columns){var e=this.isBoth(),i=this.isHorizontal();if(e||i)return this.d_loading&&this.loaderDisabled?e?this.loaderArr[0]:this.loaderArr:this.columns.slice(e?this.first.cols:this.first,e?this.last.cols:this.last)}return this.columns}},components:{SpinnerIcon:Oe}},pt=["tabindex"];function ft(t,e,i,s,l,n){var o=B("SpinnerIcon");return t.disabled?(p(),b(U,{key:1},[O(t.$slots,"default"),O(t.$slots,"content",{items:t.items,rows:t.items,columns:n.loadedColumns})],64)):(p(),b("div",c({key:0,ref:n.elementRef,class:n.containerClass,tabindex:t.tabindex,style:t.style,onScroll:e[0]||(e[0]=function(){return n.onScroll&&n.onScroll.apply(n,arguments)})},t.ptmi("root")),[O(t.$slots,"content",{styleClass:n.contentClass,items:n.loadedItems,getItemOptions:n.getOptions,loading:l.d_loading,getLoaderOptions:n.getLoaderOptions,itemSize:t.itemSize,rows:n.loadedRows,columns:n.loadedColumns,contentRef:n.contentRef,spacerStyle:l.spacerStyle,contentStyle:l.contentStyle,vertical:n.isVertical(),horizontal:n.isHorizontal(),both:n.isBoth()},function(){return[V("div",c({ref:n.contentRef,class:n.contentClass,style:l.contentStyle},t.ptm("content")),[(p(!0),b(U,null,re(n.loadedItems,function(a,d){return O(t.$slots,"item",{key:d,item:a,options:n.getOptions(d)})}),128))],16)]}),t.showSpacer?(p(),b("div",c({key:0,class:"p-virtualscroller-spacer",style:l.spacerStyle},t.ptm("spacer")),null,16)):E("",!0),!t.loaderDisabled&&t.showLoader&&l.d_loading?(p(),b("div",c({key:1,class:n.loaderClass},t.ptm("loader")),[t.$slots&&t.$slots.loader?(p(!0),b(U,{key:0},re(l.loaderArr,function(a,d){return O(t.$slots,"loader",{key:d,options:n.getLoaderOptions(d,n.isBoth()&&{numCols:t.d_numItemsInViewport.cols})})}),128)):E("",!0),O(t.$slots,"loadingicon",{},function(){return[j(o,c({spin:"",class:"p-virtualscroller-loading-icon"},t.ptm("loadingIcon")),null,16)]})],16)):E("",!0)],16,pt))}Ce.render=ft;var mt=ge`
|
|
71
|
+
.p-select {
|
|
72
|
+
display: inline-flex;
|
|
73
|
+
cursor: pointer;
|
|
74
|
+
position: relative;
|
|
75
|
+
user-select: none;
|
|
76
|
+
background: dt('select.background');
|
|
77
|
+
border: 1px solid dt('select.border.color');
|
|
78
|
+
transition:
|
|
79
|
+
background dt('select.transition.duration'),
|
|
80
|
+
color dt('select.transition.duration'),
|
|
81
|
+
border-color dt('select.transition.duration'),
|
|
82
|
+
outline-color dt('select.transition.duration'),
|
|
83
|
+
box-shadow dt('select.transition.duration');
|
|
84
|
+
border-radius: dt('select.border.radius');
|
|
85
|
+
outline-color: transparent;
|
|
86
|
+
box-shadow: dt('select.shadow');
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.p-select:not(.p-disabled):hover {
|
|
90
|
+
border-color: dt('select.hover.border.color');
|
|
91
|
+
}
|
|
92
|
+
|
|
93
|
+
.p-select:not(.p-disabled).p-focus {
|
|
94
|
+
border-color: dt('select.focus.border.color');
|
|
95
|
+
box-shadow: dt('select.focus.ring.shadow');
|
|
96
|
+
outline: dt('select.focus.ring.width') dt('select.focus.ring.style') dt('select.focus.ring.color');
|
|
97
|
+
outline-offset: dt('select.focus.ring.offset');
|
|
98
|
+
}
|
|
99
|
+
|
|
100
|
+
.p-select.p-variant-filled {
|
|
101
|
+
background: dt('select.filled.background');
|
|
102
|
+
}
|
|
103
|
+
|
|
104
|
+
.p-select.p-variant-filled:not(.p-disabled):hover {
|
|
105
|
+
background: dt('select.filled.hover.background');
|
|
106
|
+
}
|
|
107
|
+
|
|
108
|
+
.p-select.p-variant-filled:not(.p-disabled).p-focus {
|
|
109
|
+
background: dt('select.filled.focus.background');
|
|
110
|
+
}
|
|
111
|
+
|
|
112
|
+
.p-select.p-invalid {
|
|
113
|
+
border-color: dt('select.invalid.border.color');
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.p-select.p-disabled {
|
|
117
|
+
opacity: 1;
|
|
118
|
+
background: dt('select.disabled.background');
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
.p-select-clear-icon {
|
|
122
|
+
position: absolute;
|
|
123
|
+
top: 50%;
|
|
124
|
+
margin-top: -0.5rem;
|
|
125
|
+
color: dt('select.clear.icon.color');
|
|
126
|
+
inset-inline-end: dt('select.dropdown.width');
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
.p-select-dropdown {
|
|
130
|
+
display: flex;
|
|
131
|
+
align-items: center;
|
|
132
|
+
justify-content: center;
|
|
133
|
+
flex-shrink: 0;
|
|
134
|
+
background: transparent;
|
|
135
|
+
color: dt('select.dropdown.color');
|
|
136
|
+
width: dt('select.dropdown.width');
|
|
137
|
+
border-start-end-radius: dt('select.border.radius');
|
|
138
|
+
border-end-end-radius: dt('select.border.radius');
|
|
139
|
+
}
|
|
140
|
+
|
|
141
|
+
.p-select-label {
|
|
142
|
+
display: block;
|
|
143
|
+
white-space: nowrap;
|
|
144
|
+
overflow: hidden;
|
|
145
|
+
flex: 1 1 auto;
|
|
146
|
+
width: 1%;
|
|
147
|
+
padding: dt('select.padding.y') dt('select.padding.x');
|
|
148
|
+
text-overflow: ellipsis;
|
|
149
|
+
cursor: pointer;
|
|
150
|
+
color: dt('select.color');
|
|
151
|
+
background: transparent;
|
|
152
|
+
border: 0 none;
|
|
153
|
+
outline: 0 none;
|
|
154
|
+
}
|
|
155
|
+
|
|
156
|
+
.p-select-label.p-placeholder {
|
|
157
|
+
color: dt('select.placeholder.color');
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.p-select.p-invalid .p-select-label.p-placeholder {
|
|
161
|
+
color: dt('select.invalid.placeholder.color');
|
|
162
|
+
}
|
|
163
|
+
|
|
164
|
+
.p-select:has(.p-select-clear-icon) .p-select-label {
|
|
165
|
+
padding-inline-end: calc(1rem + dt('select.padding.x'));
|
|
166
|
+
}
|
|
167
|
+
|
|
168
|
+
.p-select.p-disabled .p-select-label {
|
|
169
|
+
color: dt('select.disabled.color');
|
|
170
|
+
}
|
|
171
|
+
|
|
172
|
+
.p-select-label-empty {
|
|
173
|
+
overflow: hidden;
|
|
174
|
+
opacity: 0;
|
|
175
|
+
}
|
|
176
|
+
|
|
177
|
+
input.p-select-label {
|
|
178
|
+
cursor: default;
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
.p-select .p-select-overlay {
|
|
182
|
+
min-width: 100%;
|
|
183
|
+
}
|
|
184
|
+
|
|
185
|
+
.p-select-overlay {
|
|
186
|
+
position: absolute;
|
|
187
|
+
top: 0;
|
|
188
|
+
left: 0;
|
|
189
|
+
background: dt('select.overlay.background');
|
|
190
|
+
color: dt('select.overlay.color');
|
|
191
|
+
border: 1px solid dt('select.overlay.border.color');
|
|
192
|
+
border-radius: dt('select.overlay.border.radius');
|
|
193
|
+
box-shadow: dt('select.overlay.shadow');
|
|
194
|
+
}
|
|
195
|
+
|
|
196
|
+
.p-select-header {
|
|
197
|
+
padding: dt('select.list.header.padding');
|
|
198
|
+
}
|
|
199
|
+
|
|
200
|
+
.p-select-filter {
|
|
201
|
+
width: 100%;
|
|
202
|
+
}
|
|
203
|
+
|
|
204
|
+
.p-select-list-container {
|
|
205
|
+
overflow: auto;
|
|
206
|
+
}
|
|
207
|
+
|
|
208
|
+
.p-select-option-group {
|
|
209
|
+
cursor: auto;
|
|
210
|
+
margin: 0;
|
|
211
|
+
padding: dt('select.option.group.padding');
|
|
212
|
+
background: dt('select.option.group.background');
|
|
213
|
+
color: dt('select.option.group.color');
|
|
214
|
+
font-weight: dt('select.option.group.font.weight');
|
|
215
|
+
}
|
|
216
|
+
|
|
217
|
+
.p-select-list {
|
|
218
|
+
margin: 0;
|
|
219
|
+
padding: 0;
|
|
220
|
+
list-style-type: none;
|
|
221
|
+
padding: dt('select.list.padding');
|
|
222
|
+
gap: dt('select.list.gap');
|
|
223
|
+
display: flex;
|
|
224
|
+
flex-direction: column;
|
|
225
|
+
}
|
|
226
|
+
|
|
227
|
+
.p-select-option {
|
|
228
|
+
cursor: pointer;
|
|
229
|
+
font-weight: normal;
|
|
230
|
+
white-space: nowrap;
|
|
231
|
+
position: relative;
|
|
232
|
+
overflow: hidden;
|
|
233
|
+
display: flex;
|
|
234
|
+
align-items: center;
|
|
235
|
+
padding: dt('select.option.padding');
|
|
236
|
+
border: 0 none;
|
|
237
|
+
color: dt('select.option.color');
|
|
238
|
+
background: transparent;
|
|
239
|
+
transition:
|
|
240
|
+
background dt('select.transition.duration'),
|
|
241
|
+
color dt('select.transition.duration'),
|
|
242
|
+
border-color dt('select.transition.duration'),
|
|
243
|
+
box-shadow dt('select.transition.duration'),
|
|
244
|
+
outline-color dt('select.transition.duration');
|
|
245
|
+
border-radius: dt('select.option.border.radius');
|
|
246
|
+
}
|
|
247
|
+
|
|
248
|
+
.p-select-option:not(.p-select-option-selected):not(.p-disabled).p-focus {
|
|
249
|
+
background: dt('select.option.focus.background');
|
|
250
|
+
color: dt('select.option.focus.color');
|
|
251
|
+
}
|
|
252
|
+
|
|
253
|
+
.p-select-option.p-select-option-selected {
|
|
254
|
+
background: dt('select.option.selected.background');
|
|
255
|
+
color: dt('select.option.selected.color');
|
|
256
|
+
}
|
|
257
|
+
|
|
258
|
+
.p-select-option.p-select-option-selected.p-focus {
|
|
259
|
+
background: dt('select.option.selected.focus.background');
|
|
260
|
+
color: dt('select.option.selected.focus.color');
|
|
261
|
+
}
|
|
262
|
+
|
|
263
|
+
.p-select-option-blank-icon {
|
|
264
|
+
flex-shrink: 0;
|
|
265
|
+
}
|
|
266
|
+
|
|
267
|
+
.p-select-option-check-icon {
|
|
268
|
+
position: relative;
|
|
269
|
+
flex-shrink: 0;
|
|
270
|
+
margin-inline-start: dt('select.checkmark.gutter.start');
|
|
271
|
+
margin-inline-end: dt('select.checkmark.gutter.end');
|
|
272
|
+
color: dt('select.checkmark.color');
|
|
273
|
+
}
|
|
274
|
+
|
|
275
|
+
.p-select-empty-message {
|
|
276
|
+
padding: dt('select.empty.message.padding');
|
|
277
|
+
}
|
|
278
|
+
|
|
279
|
+
.p-select-fluid {
|
|
280
|
+
display: flex;
|
|
281
|
+
width: 100%;
|
|
282
|
+
}
|
|
283
|
+
|
|
284
|
+
.p-select-sm .p-select-label {
|
|
285
|
+
font-size: dt('select.sm.font.size');
|
|
286
|
+
padding-block: dt('select.sm.padding.y');
|
|
287
|
+
padding-inline: dt('select.sm.padding.x');
|
|
288
|
+
}
|
|
289
|
+
|
|
290
|
+
.p-select-sm .p-select-dropdown .p-icon {
|
|
291
|
+
font-size: dt('select.sm.font.size');
|
|
292
|
+
width: dt('select.sm.font.size');
|
|
293
|
+
height: dt('select.sm.font.size');
|
|
294
|
+
}
|
|
295
|
+
|
|
296
|
+
.p-select-lg .p-select-label {
|
|
297
|
+
font-size: dt('select.lg.font.size');
|
|
298
|
+
padding-block: dt('select.lg.padding.y');
|
|
299
|
+
padding-inline: dt('select.lg.padding.x');
|
|
300
|
+
}
|
|
301
|
+
|
|
302
|
+
.p-select-lg .p-select-dropdown .p-icon {
|
|
303
|
+
font-size: dt('select.lg.font.size');
|
|
304
|
+
width: dt('select.lg.font.size');
|
|
305
|
+
height: dt('select.lg.font.size');
|
|
306
|
+
}
|
|
307
|
+
`,gt={root:function(e){var i=e.instance,s=e.props,l=e.state;return["p-select p-component p-inputwrapper",{"p-disabled":s.disabled,"p-invalid":i.$invalid,"p-variant-filled":i.$variant==="filled","p-focus":l.focused,"p-inputwrapper-filled":i.$filled,"p-inputwrapper-focus":l.focused||l.overlayVisible,"p-select-open":l.overlayVisible,"p-select-fluid":i.$fluid,"p-select-sm p-inputfield-sm":s.size==="small","p-select-lg p-inputfield-lg":s.size==="large"}]},label:function(e){var i=e.instance,s=e.props;return["p-select-label",{"p-placeholder":!s.editable&&i.label===s.placeholder,"p-select-label-empty":!s.editable&&!i.$slots.value&&(i.label==="p-emptylabel"||i.label.length===0)}]},clearIcon:"p-select-clear-icon",dropdown:"p-select-dropdown",loadingicon:"p-select-loading-icon",dropdownIcon:"p-select-dropdown-icon",overlay:"p-select-overlay p-component",header:"p-select-header",pcFilter:"p-select-filter",listContainer:"p-select-list-container",list:"p-select-list",optionGroup:"p-select-option-group",optionGroupLabel:"p-select-option-group-label",option:function(e){var i=e.instance,s=e.props,l=e.state,n=e.option,o=e.focusedOption;return["p-select-option",{"p-select-option-selected":i.isSelected(n)&&s.highlightOnSelect,"p-focus":l.focusedOptionIndex===o,"p-disabled":i.isOptionDisabled(n)}]},optionLabel:"p-select-option-label",optionCheckIcon:"p-select-option-check-icon",optionBlankIcon:"p-select-option-blank-icon",emptyMessage:"p-select-empty-message"},vt=ve.extend({name:"select",style:mt,classes:gt}),bt={name:"BaseSelect",extends:Fe,props:{options:Array,optionLabel:[String,Function],optionValue:[String,Function],optionDisabled:[String,Function],optionGroupLabel:[String,Function],optionGroupChildren:[String,Function],scrollHeight:{type:String,default:"14rem"},filter:Boolean,filterPlaceholder:String,filterLocale:String,filterMatchMode:{type:String,default:"contains"},filterFields:{type:Array,default:null},editable:Boolean,placeholder:{type:String,default:null},dataKey:null,showClear:{type:Boolean,default:!1},inputId:{type:String,default:null},inputClass:{type:[String,Object],default:null},inputStyle:{type:Object,default:null},labelId:{type:String,default:null},labelClass:{type:[String,Object],default:null},labelStyle:{type:Object,default:null},panelClass:{type:[String,Object],default:null},overlayStyle:{type:Object,default:null},overlayClass:{type:[String,Object],default:null},panelStyle:{type:Object,default:null},appendTo:{type:[String,Object],default:"body"},loading:{type:Boolean,default:!1},clearIcon:{type:String,default:void 0},dropdownIcon:{type:String,default:void 0},filterIcon:{type:String,default:void 0},loadingIcon:{type:String,default:void 0},resetFilterOnHide:{type:Boolean,default:!1},resetFilterOnClear:{type:Boolean,default:!1},virtualScrollerOptions:{type:Object,default:null},autoOptionFocus:{type:Boolean,default:!1},autoFilterFocus:{type:Boolean,default:!1},selectOnFocus:{type:Boolean,default:!1},focusOnHover:{type:Boolean,default:!0},highlightOnSelect:{type:Boolean,default:!0},checkmark:{type:Boolean,default:!1},filterMessage:{type:String,default:null},selectionMessage:{type:String,default:null},emptySelectionMessage:{type:String,default:null},emptyFilterMessage:{type:String,default:null},emptyMessage:{type:String,default:null},tabindex:{type:Number,default:0},ariaLabel:{type:String,default:null},ariaLabelledby:{type:String,default:null}},style:vt,provide:function(){return{$pcSelect:this,$parentInstance:this}}};function Y(t){"@babel/helpers - typeof";return Y=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Y(t)}function yt(t){return St(t)||wt(t)||It(t)||Ot()}function Ot(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
|
|
308
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function It(t,e){if(t){if(typeof t=="string")return ae(t,e);var i={}.toString.call(t).slice(8,-1);return i==="Object"&&t.constructor&&(i=t.constructor.name),i==="Map"||i==="Set"?Array.from(t):i==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(i)?ae(t,e):void 0}}function wt(t){if(typeof Symbol<"u"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function St(t){if(Array.isArray(t))return ae(t)}function ae(t,e){(e==null||e>t.length)&&(e=t.length);for(var i=0,s=Array(e);i<e;i++)s[i]=t[i];return s}function fe(t,e){var i=Object.keys(t);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(t);e&&(s=s.filter(function(l){return Object.getOwnPropertyDescriptor(t,l).enumerable})),i.push.apply(i,s)}return i}function me(t){for(var e=1;e<arguments.length;e++){var i=arguments[e]!=null?arguments[e]:{};e%2?fe(Object(i),!0).forEach(function(s){G(t,s,i[s])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(i)):fe(Object(i)).forEach(function(s){Object.defineProperty(t,s,Object.getOwnPropertyDescriptor(i,s))})}return t}function G(t,e,i){return(e=Lt(e))in t?Object.defineProperty(t,e,{value:i,enumerable:!0,configurable:!0,writable:!0}):t[e]=i,t}function Lt(t){var e=Ct(t,"string");return Y(e)=="symbol"?e:e+""}function Ct(t,e){if(Y(t)!="object"||!t)return t;var i=t[Symbol.toPrimitive];if(i!==void 0){var s=i.call(t,e);if(Y(s)!="object")return s;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var kt={name:"Select",extends:bt,inheritAttrs:!1,emits:["change","focus","blur","before-show","before-hide","show","hide","filter"],outsideClickListener:null,scrollHandler:null,resizeListener:null,labelClickListener:null,matchMediaOrientationListener:null,overlay:null,list:null,virtualScroller:null,searchTimeout:null,searchValue:null,isModelValueChanged:!1,data:function(){return{clicked:!1,focused:!1,focusedOptionIndex:-1,filterValue:null,overlayVisible:!1,queryOrientation:null}},watch:{modelValue:function(){this.isModelValueChanged=!0},options:function(){this.autoUpdateModel()}},mounted:function(){this.autoUpdateModel(),this.bindLabelClickListener(),this.bindMatchMediaOrientationListener()},updated:function(){this.overlayVisible&&this.isModelValueChanged&&this.scrollInView(this.findSelectedOptionIndex()),this.isModelValueChanged=!1},beforeUnmount:function(){this.unbindOutsideClickListener(),this.unbindResizeListener(),this.unbindLabelClickListener(),this.unbindMatchMediaOrientationListener(),this.scrollHandler&&(this.scrollHandler.destroy(),this.scrollHandler=null),this.overlay&&(le.clear(this.overlay),this.overlay=null)},methods:{getOptionIndex:function(e,i){return this.virtualScrollerDisabled?e:i&&i(e).index},getOptionLabel:function(e){return this.optionLabel?N(e,this.optionLabel):e},getOptionValue:function(e){return this.optionValue?N(e,this.optionValue):e},getOptionRenderKey:function(e,i){return(this.dataKey?N(e,this.dataKey):this.getOptionLabel(e))+"_"+i},getPTItemOptions:function(e,i,s,l){return this.ptm(l,{context:{option:e,index:s,selected:this.isSelected(e),focused:this.focusedOptionIndex===this.getOptionIndex(s,i),disabled:this.isOptionDisabled(e)}})},isOptionDisabled:function(e){return this.optionDisabled?N(e,this.optionDisabled):!1},isOptionGroup:function(e){return this.optionGroupLabel&&e.optionGroup&&e.group},getOptionGroupLabel:function(e){return N(e,this.optionGroupLabel)},getOptionGroupChildren:function(e){return N(e,this.optionGroupChildren)},getAriaPosInset:function(e){var i=this;return(this.optionGroupLabel?e-this.visibleOptions.slice(0,e).filter(function(s){return i.isOptionGroup(s)}).length:e)+1},show:function(e){this.$emit("before-show"),this.overlayVisible=!0,this.focusedOptionIndex=this.focusedOptionIndex!==-1?this.focusedOptionIndex:this.autoOptionFocus?this.findFirstFocusedOptionIndex():this.editable?-1:this.findSelectedOptionIndex(),e&&D(this.$refs.focusInput)},hide:function(e){var i=this,s=function(){i.$emit("before-hide"),i.overlayVisible=!1,i.clicked=!1,i.focusedOptionIndex=-1,i.searchValue="",i.resetFilterOnHide&&(i.filterValue=null),e&&D(i.$refs.focusInput)};setTimeout(function(){s()},0)},onFocus:function(e){this.disabled||(this.focused=!0,this.overlayVisible&&(this.focusedOptionIndex=this.focusedOptionIndex!==-1?this.focusedOptionIndex:this.autoOptionFocus?this.findFirstFocusedOptionIndex():this.editable?-1:this.findSelectedOptionIndex(),this.scrollInView(this.focusedOptionIndex)),this.$emit("focus",e))},onBlur:function(e){var i=this;setTimeout(function(){var s,l;i.focused=!1,i.focusedOptionIndex=-1,i.searchValue="",i.$emit("blur",e),(s=(l=i.formField).onBlur)===null||s===void 0||s.call(l,e)},100)},onKeyDown:function(e){if(this.disabled){e.preventDefault();return}if(Ne())switch(e.code){case"Backspace":this.onBackspaceKey(e,this.editable);break;case"Enter":case"NumpadDecimal":this.onEnterKey(e);break;default:e.preventDefault();return}var i=e.metaKey||e.ctrlKey;switch(e.code){case"ArrowDown":this.onArrowDownKey(e);break;case"ArrowUp":this.onArrowUpKey(e,this.editable);break;case"ArrowLeft":case"ArrowRight":this.onArrowLeftKey(e,this.editable);break;case"Home":this.onHomeKey(e,this.editable);break;case"End":this.onEndKey(e,this.editable);break;case"PageDown":this.onPageDownKey(e);break;case"PageUp":this.onPageUpKey(e);break;case"Space":this.onSpaceKey(e,this.editable);break;case"Enter":case"NumpadEnter":this.onEnterKey(e);break;case"Escape":this.onEscapeKey(e);break;case"Tab":this.onTabKey(e);break;case"Backspace":this.onBackspaceKey(e,this.editable);break;case"ShiftLeft":case"ShiftRight":break;default:!i&&We(e.key)&&(!this.overlayVisible&&this.show(),!this.editable&&this.searchOptions(e,e.key));break}this.clicked=!1},onEditableInput:function(e){var i=e.target.value;this.searchValue="";var s=this.searchOptions(e,i);!s&&(this.focusedOptionIndex=-1),this.updateModel(e,i),!this.overlayVisible&&J(i)&&this.show()},onContainerClick:function(e){this.disabled||this.loading||e.target.tagName==="INPUT"||e.target.getAttribute("data-pc-section")==="clearicon"||e.target.closest('[data-pc-section="clearicon"]')||((!this.overlay||!this.overlay.contains(e.target))&&(this.overlayVisible?this.hide(!0):this.show(!0)),this.clicked=!0)},onClearClick:function(e){this.updateModel(e,null),this.resetFilterOnClear&&(this.filterValue=null)},onFirstHiddenFocus:function(e){var i=e.relatedTarget===this.$refs.focusInput?Ge(this.overlay,':not([data-p-hidden-focusable="true"])'):this.$refs.focusInput;D(i)},onLastHiddenFocus:function(e){var i=e.relatedTarget===this.$refs.focusInput?je(this.overlay,':not([data-p-hidden-focusable="true"])'):this.$refs.focusInput;D(i)},onOptionSelect:function(e,i){var s=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0,l=this.getOptionValue(i);this.updateModel(e,l),s&&this.hide(!0)},onOptionMouseMove:function(e,i){this.focusOnHover&&this.changeFocusedOptionIndex(e,i)},onFilterChange:function(e){var i=e.target.value;this.filterValue=i,this.focusedOptionIndex=-1,this.$emit("filter",{originalEvent:e,value:i}),!this.virtualScrollerDisabled&&this.virtualScroller.scrollToIndex(0)},onFilterKeyDown:function(e){if(!e.isComposing)switch(e.code){case"ArrowDown":this.onArrowDownKey(e);break;case"ArrowUp":this.onArrowUpKey(e,!0);break;case"ArrowLeft":case"ArrowRight":this.onArrowLeftKey(e,!0);break;case"Home":this.onHomeKey(e,!0);break;case"End":this.onEndKey(e,!0);break;case"Enter":case"NumpadEnter":this.onEnterKey(e);break;case"Escape":this.onEscapeKey(e);break;case"Tab":this.onTabKey(e,!0);break}},onFilterBlur:function(){this.focusedOptionIndex=-1},onFilterUpdated:function(){this.overlayVisible&&this.alignOverlay()},onOverlayClick:function(e){rt.emit("overlay-click",{originalEvent:e,target:this.$el})},onOverlayKeyDown:function(e){switch(e.code){case"Escape":this.onEscapeKey(e);break}},onArrowDownKey:function(e){if(!this.overlayVisible)this.show(),this.editable&&this.changeFocusedOptionIndex(e,this.findSelectedOptionIndex());else{var i=this.focusedOptionIndex!==-1?this.findNextOptionIndex(this.focusedOptionIndex):this.clicked?this.findFirstOptionIndex():this.findFirstFocusedOptionIndex();this.changeFocusedOptionIndex(e,i)}e.preventDefault()},onArrowUpKey:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(e.altKey&&!i)this.focusedOptionIndex!==-1&&this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex]),this.overlayVisible&&this.hide(),e.preventDefault();else{var s=this.focusedOptionIndex!==-1?this.findPrevOptionIndex(this.focusedOptionIndex):this.clicked?this.findLastOptionIndex():this.findLastFocusedOptionIndex();this.changeFocusedOptionIndex(e,s),!this.overlayVisible&&this.show(),e.preventDefault()}},onArrowLeftKey:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;i&&(this.focusedOptionIndex=-1)},onHomeKey:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(i){var s=e.currentTarget;e.shiftKey?s.setSelectionRange(0,e.target.selectionStart):(s.setSelectionRange(0,0),this.focusedOptionIndex=-1)}else this.changeFocusedOptionIndex(e,this.findFirstOptionIndex()),!this.overlayVisible&&this.show();e.preventDefault()},onEndKey:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;if(i){var s=e.currentTarget;if(e.shiftKey)s.setSelectionRange(e.target.selectionStart,s.value.length);else{var l=s.value.length;s.setSelectionRange(l,l),this.focusedOptionIndex=-1}}else this.changeFocusedOptionIndex(e,this.findLastOptionIndex()),!this.overlayVisible&&this.show();e.preventDefault()},onPageUpKey:function(e){this.scrollInView(0),e.preventDefault()},onPageDownKey:function(e){this.scrollInView(this.visibleOptions.length-1),e.preventDefault()},onEnterKey:function(e){this.overlayVisible?(this.focusedOptionIndex!==-1&&this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex]),this.hide()):(this.focusedOptionIndex=-1,this.onArrowDownKey(e)),e.preventDefault()},onSpaceKey:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;!i&&this.onEnterKey(e)},onEscapeKey:function(e){this.overlayVisible&&this.hide(!0),e.preventDefault(),e.stopPropagation()},onTabKey:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;i||(this.overlayVisible&&this.hasFocusableElements()?(D(this.$refs.firstHiddenFocusableElementOnOverlay),e.preventDefault()):(this.focusedOptionIndex!==-1&&this.onOptionSelect(e,this.visibleOptions[this.focusedOptionIndex]),this.overlayVisible&&this.hide(this.filter)))},onBackspaceKey:function(e){var i=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;i&&!this.overlayVisible&&this.show()},onOverlayEnter:function(e){var i=this;le.set("overlay",e,this.$primevue.config.zIndex.overlay),Re(e,{position:"absolute",top:"0"}),this.alignOverlay(),this.scrollInView(),this.$attrSelector&&e.setAttribute(this.$attrSelector,""),setTimeout(function(){i.autoFilterFocus&&i.filter&&D(i.$refs.filterInput.$el),i.autoUpdateModel()},1)},onOverlayAfterEnter:function(){this.bindOutsideClickListener(),this.bindScrollListener(),this.bindResizeListener(),this.$emit("show")},onOverlayLeave:function(){var e=this;this.unbindOutsideClickListener(),this.unbindScrollListener(),this.unbindResizeListener(),this.autoFilterFocus&&this.filter&&!this.editable&&this.$nextTick(function(){e.$refs.filterInput&&D(e.$refs.filterInput.$el)}),this.$emit("hide"),this.overlay=null},onOverlayAfterLeave:function(e){le.clear(e)},alignOverlay:function(){this.appendTo==="self"?De(this.overlay,this.$el):this.overlay&&(this.overlay.style.minWidth=Ae(this.$el)+"px",He(this.overlay,this.$el))},bindOutsideClickListener:function(){var e=this;this.outsideClickListener||(this.outsideClickListener=function(i){var s=i.composedPath();e.overlayVisible&&e.overlay&&!s.includes(e.$el)&&!s.includes(e.overlay)&&e.hide()},document.addEventListener("click",this.outsideClickListener,!0))},unbindOutsideClickListener:function(){this.outsideClickListener&&(document.removeEventListener("click",this.outsideClickListener,!0),this.outsideClickListener=null)},bindScrollListener:function(){var e=this;this.scrollHandler||(this.scrollHandler=new xe(this.$refs.container,function(){e.overlayVisible&&e.hide()})),this.scrollHandler.bindScrollListener()},unbindScrollListener:function(){this.scrollHandler&&this.scrollHandler.unbindScrollListener()},bindResizeListener:function(){var e=this;this.resizeListener||(this.resizeListener=function(){e.overlayVisible&&!Ke()&&e.hide()},window.addEventListener("resize",this.resizeListener))},unbindResizeListener:function(){this.resizeListener&&(window.removeEventListener("resize",this.resizeListener),this.resizeListener=null)},bindLabelClickListener:function(){var e=this;if(!this.editable&&!this.labelClickListener){var i=document.querySelector('label[for="'.concat(this.labelId,'"]'));i&&ne(i)&&(this.labelClickListener=function(){D(e.$refs.focusInput)},i.addEventListener("click",this.labelClickListener))}},unbindLabelClickListener:function(){if(this.labelClickListener){var e=document.querySelector('label[for="'.concat(this.labelId,'"]'));e&&ne(e)&&e.removeEventListener("click",this.labelClickListener)}},bindMatchMediaOrientationListener:function(){var e=this;if(!this.matchMediaOrientationListener){var i=matchMedia("(orientation: portrait)");this.queryOrientation=i,this.matchMediaOrientationListener=function(){e.alignOverlay()},this.queryOrientation.addEventListener("change",this.matchMediaOrientationListener)}},unbindMatchMediaOrientationListener:function(){this.matchMediaOrientationListener&&(this.queryOrientation.removeEventListener("change",this.matchMediaOrientationListener),this.queryOrientation=null,this.matchMediaOrientationListener=null)},hasFocusableElements:function(){return Ee(this.overlay,':not([data-p-hidden-focusable="true"])').length>0},isOptionExactMatched:function(e){var i;return this.isValidOption(e)&&typeof this.getOptionLabel(e)=="string"&&((i=this.getOptionLabel(e))===null||i===void 0?void 0:i.toLocaleLowerCase(this.filterLocale))==this.searchValue.toLocaleLowerCase(this.filterLocale)},isOptionStartsWith:function(e){var i;return this.isValidOption(e)&&typeof this.getOptionLabel(e)=="string"&&((i=this.getOptionLabel(e))===null||i===void 0?void 0:i.toLocaleLowerCase(this.filterLocale).startsWith(this.searchValue.toLocaleLowerCase(this.filterLocale)))},isValidOption:function(e){return J(e)&&!(this.isOptionDisabled(e)||this.isOptionGroup(e))},isValidSelectedOption:function(e){return this.isValidOption(e)&&this.isSelected(e)},isSelected:function(e){return Be(this.d_value,this.getOptionValue(e),this.equalityKey)},findFirstOptionIndex:function(){var e=this;return this.visibleOptions.findIndex(function(i){return e.isValidOption(i)})},findLastOptionIndex:function(){var e=this;return ue(this.visibleOptions,function(i){return e.isValidOption(i)})},findNextOptionIndex:function(e){var i=this,s=e<this.visibleOptions.length-1?this.visibleOptions.slice(e+1).findIndex(function(l){return i.isValidOption(l)}):-1;return s>-1?s+e+1:e},findPrevOptionIndex:function(e){var i=this,s=e>0?ue(this.visibleOptions.slice(0,e),function(l){return i.isValidOption(l)}):-1;return s>-1?s:e},findSelectedOptionIndex:function(){var e=this;return this.$filled?this.visibleOptions.findIndex(function(i){return e.isValidSelectedOption(i)}):-1},findFirstFocusedOptionIndex:function(){var e=this.findSelectedOptionIndex();return e<0?this.findFirstOptionIndex():e},findLastFocusedOptionIndex:function(){var e=this.findSelectedOptionIndex();return e<0?this.findLastOptionIndex():e},searchOptions:function(e,i){var s=this;this.searchValue=(this.searchValue||"")+i;var l=-1,n=!1;return J(this.searchValue)&&(l=this.visibleOptions.findIndex(function(o){return s.isOptionExactMatched(o)}),l===-1&&(l=this.visibleOptions.findIndex(function(o){return s.isOptionStartsWith(o)})),l!==-1&&(n=!0),l===-1&&this.focusedOptionIndex===-1&&(l=this.findFirstFocusedOptionIndex()),l!==-1&&this.changeFocusedOptionIndex(e,l)),this.searchTimeout&&clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout(function(){s.searchValue="",s.searchTimeout=null},500),n},changeFocusedOptionIndex:function(e,i){this.focusedOptionIndex!==i&&(this.focusedOptionIndex=i,this.scrollInView(),this.selectOnFocus&&this.onOptionSelect(e,this.visibleOptions[i],!1))},scrollInView:function(){var e=this,i=arguments.length>0&&arguments[0]!==void 0?arguments[0]:-1;this.$nextTick(function(){var s=i!==-1?"".concat(e.$id,"_").concat(i):e.focusedOptionId,l=be(e.list,'li[id="'.concat(s,'"]'));l?l.scrollIntoView&&l.scrollIntoView({block:"nearest",inline:"nearest"}):e.virtualScrollerDisabled||e.virtualScroller&&e.virtualScroller.scrollToIndex(i!==-1?i:e.focusedOptionIndex)})},autoUpdateModel:function(){this.autoOptionFocus&&(this.focusedOptionIndex=this.findFirstFocusedOptionIndex()),this.selectOnFocus&&this.autoOptionFocus&&!this.$filled&&this.onOptionSelect(null,this.visibleOptions[this.focusedOptionIndex],!1)},updateModel:function(e,i){this.writeValue(i,e),this.$emit("change",{originalEvent:e,value:i})},flatOptions:function(e){var i=this;return(e||[]).reduce(function(s,l,n){s.push({optionGroup:l,group:!0,index:n});var o=i.getOptionGroupChildren(l);return o&&o.forEach(function(a){return s.push(a)}),s},[])},overlayRef:function(e){this.overlay=e},listRef:function(e,i){this.list=e,i&&i(e)},virtualScrollerRef:function(e){this.virtualScroller=e}},computed:{visibleOptions:function(){var e=this,i=this.optionGroupLabel?this.flatOptions(this.options):this.options||[];if(this.filterValue){var s=Pe.filter(i,this.searchFields,this.filterValue,this.filterMatchMode,this.filterLocale);if(this.optionGroupLabel){var l=this.options||[],n=[];return l.forEach(function(o){var a=e.getOptionGroupChildren(o),d=a.filter(function(u){return s.includes(u)});d.length>0&&n.push(me(me({},o),{},G({},typeof e.optionGroupChildren=="string"?e.optionGroupChildren:"items",yt(d))))}),this.flatOptions(n)}return s}return i},hasSelectedOption:function(){return this.$filled},label:function(){var e=this.findSelectedOptionIndex();return e!==-1?this.getOptionLabel(this.visibleOptions[e]):this.placeholder||"p-emptylabel"},editableInputValue:function(){var e=this.findSelectedOptionIndex();return e!==-1?this.getOptionLabel(this.visibleOptions[e]):this.d_value||""},equalityKey:function(){return this.optionValue?null:this.dataKey},searchFields:function(){return this.filterFields||[this.optionLabel]},filterResultMessageText:function(){return J(this.visibleOptions)?this.filterMessageText.replaceAll("{0}",this.visibleOptions.length):this.emptyFilterMessageText},filterMessageText:function(){return this.filterMessage||this.$primevue.config.locale.searchMessage||""},emptyFilterMessageText:function(){return this.emptyFilterMessage||this.$primevue.config.locale.emptySearchMessage||this.$primevue.config.locale.emptyFilterMessage||""},emptyMessageText:function(){return this.emptyMessage||this.$primevue.config.locale.emptyMessage||""},selectionMessageText:function(){return this.selectionMessage||this.$primevue.config.locale.selectionMessage||""},emptySelectionMessageText:function(){return this.emptySelectionMessage||this.$primevue.config.locale.emptySelectionMessage||""},selectedMessageText:function(){return this.$filled?this.selectionMessageText.replaceAll("{0}","1"):this.emptySelectionMessageText},focusedOptionId:function(){return this.focusedOptionIndex!==-1?"".concat(this.$id,"_").concat(this.focusedOptionIndex):null},ariaSetSize:function(){var e=this;return this.visibleOptions.filter(function(i){return!e.isOptionGroup(i)}).length},isClearIconVisible:function(){return this.showClear&&this.d_value!=null&&J(this.options)},virtualScrollerDisabled:function(){return!this.virtualScrollerOptions},containerDataP:function(){return te(G({invalid:this.$invalid,disabled:this.disabled,focus:this.focused,fluid:this.$fluid,filled:this.$variant==="filled"},this.size,this.size))},labelDataP:function(){return te(G(G({placeholder:!this.editable&&this.label===this.placeholder,clearable:this.showClear,disabled:this.disabled,editable:this.editable},this.size,this.size),"empty",!this.editable&&!this.$slots.value&&(this.label==="p-emptylabel"||this.label.length===0)))},dropdownIconDataP:function(){return te(G({},this.size,this.size))},overlayDataP:function(){return te(G({},"portal-"+this.appendTo,"portal-"+this.appendTo))}},directives:{ripple:nt},components:{InputText:it,VirtualScroller:Ce,Portal:we,InputIcon:tt,IconField:et,TimesIcon:Ie,ChevronDownIcon:_e,SpinnerIcon:Oe,SearchIcon:Ye,CheckIcon:Xe,BlankIcon:Se}},zt=["id","data-p"],Ft=["name","id","value","placeholder","tabindex","disabled","aria-label","aria-labelledby","aria-expanded","aria-controls","aria-activedescendant","aria-invalid","data-p"],Vt=["name","id","tabindex","aria-label","aria-labelledby","aria-expanded","aria-controls","aria-activedescendant","aria-invalid","aria-disabled","data-p"],Mt=["data-p"],Tt=["id"],Pt=["id"],Bt=["id","aria-label","aria-selected","aria-disabled","aria-setsize","aria-posinset","onMousedown","onMousemove","data-p-selected","data-p-focused","data-p-disabled"];function Et(t,e,i,s,l,n){var o=B("SpinnerIcon"),a=B("InputText"),d=B("SearchIcon"),u=B("InputIcon"),r=B("IconField"),h=B("CheckIcon"),y=B("BlankIcon"),L=B("VirtualScroller"),I=B("Portal"),S=Ue("ripple");return p(),b("div",c({ref:"container",id:t.$id,class:t.cx("root"),onClick:e[12]||(e[12]=function(){return n.onContainerClick&&n.onContainerClick.apply(n,arguments)}),"data-p":n.containerDataP},t.ptmi("root")),[t.editable?(p(),b("input",c({key:0,ref:"focusInput",name:t.name,id:t.labelId||t.inputId,type:"text",class:[t.cx("label"),t.inputClass,t.labelClass],style:[t.inputStyle,t.labelStyle],value:n.editableInputValue,placeholder:t.placeholder,tabindex:t.disabled?-1:t.tabindex,disabled:t.disabled,autocomplete:"off",role:"combobox","aria-label":t.ariaLabel,"aria-labelledby":t.ariaLabelledby,"aria-haspopup":"listbox","aria-expanded":l.overlayVisible,"aria-controls":t.$id+"_list","aria-activedescendant":l.focused?n.focusedOptionId:void 0,"aria-invalid":t.invalid||void 0,onFocus:e[0]||(e[0]=function(){return n.onFocus&&n.onFocus.apply(n,arguments)}),onBlur:e[1]||(e[1]=function(){return n.onBlur&&n.onBlur.apply(n,arguments)}),onKeydown:e[2]||(e[2]=function(){return n.onKeyDown&&n.onKeyDown.apply(n,arguments)}),onInput:e[3]||(e[3]=function(){return n.onEditableInput&&n.onEditableInput.apply(n,arguments)}),"data-p":n.labelDataP},t.ptm("label")),null,16,Ft)):(p(),b("span",c({key:1,ref:"focusInput",name:t.name,id:t.labelId||t.inputId,class:[t.cx("label"),t.inputClass,t.labelClass],style:[t.inputStyle,t.labelStyle],tabindex:t.disabled?-1:t.tabindex,role:"combobox","aria-label":t.ariaLabel||(n.label==="p-emptylabel"?void 0:n.label),"aria-labelledby":t.ariaLabelledby,"aria-haspopup":"listbox","aria-expanded":l.overlayVisible,"aria-controls":t.$id+"_list","aria-activedescendant":l.focused?n.focusedOptionId:void 0,"aria-invalid":t.invalid||void 0,"aria-disabled":t.disabled,onFocus:e[4]||(e[4]=function(){return n.onFocus&&n.onFocus.apply(n,arguments)}),onBlur:e[5]||(e[5]=function(){return n.onBlur&&n.onBlur.apply(n,arguments)}),onKeydown:e[6]||(e[6]=function(){return n.onKeyDown&&n.onKeyDown.apply(n,arguments)}),"data-p":n.labelDataP},t.ptm("label")),[O(t.$slots,"value",{value:t.d_value,placeholder:t.placeholder},function(){var g;return[oe(A(n.label==="p-emptylabel"?" ":(g=n.label)!==null&&g!==void 0?g:"empty"),1)]})],16,Vt)),n.isClearIconVisible?O(t.$slots,"clearicon",{key:2,class:ie(t.cx("clearIcon")),clearCallback:n.onClearClick},function(){return[(p(),R(ce(t.clearIcon?"i":"TimesIcon"),c({ref:"clearIcon",class:[t.cx("clearIcon"),t.clearIcon],onClick:n.onClearClick},t.ptm("clearIcon"),{"data-pc-section":"clearicon"}),null,16,["class","onClick"]))]}):E("",!0),V("div",c({class:t.cx("dropdown")},t.ptm("dropdown")),[t.loading?O(t.$slots,"loadingicon",{key:0,class:ie(t.cx("loadingIcon"))},function(){return[t.loadingIcon?(p(),b("span",c({key:0,class:[t.cx("loadingIcon"),"pi-spin",t.loadingIcon],"aria-hidden":"true"},t.ptm("loadingIcon")),null,16)):(p(),R(o,c({key:1,class:t.cx("loadingIcon"),spin:"","aria-hidden":"true"},t.ptm("loadingIcon")),null,16,["class"]))]}):O(t.$slots,"dropdownicon",{key:1,class:ie(t.cx("dropdownIcon"))},function(){return[(p(),R(ce(t.dropdownIcon?"span":"ChevronDownIcon"),c({class:[t.cx("dropdownIcon"),t.dropdownIcon],"aria-hidden":"true","data-p":n.dropdownIconDataP},t.ptm("dropdownIcon")),null,16,["class","data-p"]))]})],16),j(I,{appendTo:t.appendTo},{default:W(function(){return[j(qe,c({name:"p-connected-overlay",onEnter:n.onOverlayEnter,onAfterEnter:n.onOverlayAfterEnter,onLeave:n.onOverlayLeave,onAfterLeave:n.onOverlayAfterLeave},t.ptm("transition")),{default:W(function(){return[l.overlayVisible?(p(),b("div",c({key:0,ref:n.overlayRef,class:[t.cx("overlay"),t.panelClass,t.overlayClass],style:[t.panelStyle,t.overlayStyle],onClick:e[10]||(e[10]=function(){return n.onOverlayClick&&n.onOverlayClick.apply(n,arguments)}),onKeydown:e[11]||(e[11]=function(){return n.onOverlayKeyDown&&n.onOverlayKeyDown.apply(n,arguments)}),"data-p":n.overlayDataP},t.ptm("overlay")),[V("span",c({ref:"firstHiddenFocusableElementOnOverlay",role:"presentation","aria-hidden":"true",class:"p-hidden-accessible p-hidden-focusable",tabindex:0,onFocus:e[7]||(e[7]=function(){return n.onFirstHiddenFocus&&n.onFirstHiddenFocus.apply(n,arguments)})},t.ptm("hiddenFirstFocusableEl"),{"data-p-hidden-accessible":!0,"data-p-hidden-focusable":!0}),null,16),O(t.$slots,"header",{value:t.d_value,options:n.visibleOptions}),t.filter?(p(),b("div",c({key:0,class:t.cx("header")},t.ptm("header")),[j(r,{unstyled:t.unstyled,pt:t.ptm("pcFilterContainer")},{default:W(function(){return[j(a,{ref:"filterInput",type:"text",value:l.filterValue,onVnodeMounted:n.onFilterUpdated,onVnodeUpdated:n.onFilterUpdated,class:ie(t.cx("pcFilter")),placeholder:t.filterPlaceholder,variant:t.variant,unstyled:t.unstyled,role:"searchbox",autocomplete:"off","aria-owns":t.$id+"_list","aria-activedescendant":n.focusedOptionId,onKeydown:n.onFilterKeyDown,onBlur:n.onFilterBlur,onInput:n.onFilterChange,pt:t.ptm("pcFilter"),formControl:{novalidate:!0}},null,8,["value","onVnodeMounted","onVnodeUpdated","class","placeholder","variant","unstyled","aria-owns","aria-activedescendant","onKeydown","onBlur","onInput","pt"]),j(u,{unstyled:t.unstyled,pt:t.ptm("pcFilterIconContainer")},{default:W(function(){return[O(t.$slots,"filtericon",{},function(){return[t.filterIcon?(p(),b("span",c({key:0,class:t.filterIcon},t.ptm("filterIcon")),null,16)):(p(),R(d,$e(c({key:1},t.ptm("filterIcon"))),null,16))]})]}),_:3},8,["unstyled","pt"])]}),_:3},8,["unstyled","pt"]),V("span",c({role:"status","aria-live":"polite",class:"p-hidden-accessible"},t.ptm("hiddenFilterResult"),{"data-p-hidden-accessible":!0}),A(n.filterResultMessageText),17)],16)):E("",!0),V("div",c({class:t.cx("listContainer"),style:{"max-height":n.virtualScrollerDisabled?t.scrollHeight:""}},t.ptm("listContainer")),[j(L,c({ref:n.virtualScrollerRef},t.virtualScrollerOptions,{items:n.visibleOptions,style:{height:t.scrollHeight},tabindex:-1,disabled:n.virtualScrollerDisabled,pt:t.ptm("virtualScroller")}),Ze({content:W(function(g){var C=g.styleClass,k=g.contentRef,z=g.items,f=g.getItemOptions,x=g.contentStyle,F=g.itemSize;return[V("ul",c({ref:function(v){return n.listRef(v,k)},id:t.$id+"_list",class:[t.cx("list"),C],style:x,role:"listbox"},t.ptm("list")),[(p(!0),b(U,null,re(z,function(m,v){return p(),b(U,{key:n.getOptionRenderKey(m,n.getOptionIndex(v,f))},[n.isOptionGroup(m)?(p(),b("li",c({key:0,id:t.$id+"_"+n.getOptionIndex(v,f),style:{height:F?F+"px":void 0},class:t.cx("optionGroup"),role:"option",ref_for:!0},t.ptm("optionGroup")),[O(t.$slots,"optiongroup",{option:m.optionGroup,index:n.getOptionIndex(v,f)},function(){return[V("span",c({class:t.cx("optionGroupLabel"),ref_for:!0},t.ptm("optionGroupLabel")),A(n.getOptionGroupLabel(m.optionGroup)),17)]})],16,Pt)):Je((p(),b("li",c({key:1,id:t.$id+"_"+n.getOptionIndex(v,f),class:t.cx("option",{option:m,focusedOption:n.getOptionIndex(v,f)}),style:{height:F?F+"px":void 0},role:"option","aria-label":n.getOptionLabel(m),"aria-selected":n.isSelected(m),"aria-disabled":n.isOptionDisabled(m),"aria-setsize":n.ariaSetSize,"aria-posinset":n.getAriaPosInset(n.getOptionIndex(v,f)),onMousedown:function(T){return n.onOptionSelect(T,m)},onMousemove:function(T){return n.onOptionMouseMove(T,n.getOptionIndex(v,f))},onClick:e[8]||(e[8]=Qe(function(){},["stop"])),"data-p-selected":!t.checkmark&&n.isSelected(m),"data-p-focused":l.focusedOptionIndex===n.getOptionIndex(v,f),"data-p-disabled":n.isOptionDisabled(m),ref_for:!0},n.getPTItemOptions(m,f,v,"option")),[t.checkmark?(p(),b(U,{key:0},[n.isSelected(m)?(p(),R(h,c({key:0,class:t.cx("optionCheckIcon"),ref_for:!0},t.ptm("optionCheckIcon")),null,16,["class"])):(p(),R(y,c({key:1,class:t.cx("optionBlankIcon"),ref_for:!0},t.ptm("optionBlankIcon")),null,16,["class"]))],64)):E("",!0),O(t.$slots,"option",{option:m,selected:n.isSelected(m),index:n.getOptionIndex(v,f)},function(){return[V("span",c({class:t.cx("optionLabel"),ref_for:!0},t.ptm("optionLabel")),A(n.getOptionLabel(m)),17)]})],16,Bt)),[[S]])],64)}),128)),l.filterValue&&(!z||z&&z.length===0)?(p(),b("li",c({key:0,class:t.cx("emptyMessage"),role:"option"},t.ptm("emptyMessage"),{"data-p-hidden-accessible":!0}),[O(t.$slots,"emptyfilter",{},function(){return[oe(A(n.emptyFilterMessageText),1)]})],16)):!t.options||t.options&&t.options.length===0?(p(),b("li",c({key:1,class:t.cx("emptyMessage"),role:"option"},t.ptm("emptyMessage"),{"data-p-hidden-accessible":!0}),[O(t.$slots,"empty",{},function(){return[oe(A(n.emptyMessageText),1)]})],16)):E("",!0)],16,Tt)]}),_:2},[t.$slots.loader?{name:"loader",fn:W(function(g){var C=g.options;return[O(t.$slots,"loader",{options:C})]}),key:"0"}:void 0]),1040,["items","style","disabled","pt"])],16),O(t.$slots,"footer",{value:t.d_value,options:n.visibleOptions}),!t.options||t.options&&t.options.length===0?(p(),b("span",c({key:1,role:"status","aria-live":"polite",class:"p-hidden-accessible"},t.ptm("hiddenEmptyMessage"),{"data-p-hidden-accessible":!0}),A(n.emptyMessageText),17)):E("",!0),V("span",c({role:"status","aria-live":"polite",class:"p-hidden-accessible"},t.ptm("hiddenSelectedMessage"),{"data-p-hidden-accessible":!0}),A(n.selectedMessageText),17),V("span",c({ref:"lastHiddenFocusableElementOnOverlay",role:"presentation","aria-hidden":"true",class:"p-hidden-accessible p-hidden-focusable",tabindex:0,onFocus:e[9]||(e[9]=function(){return n.onLastHiddenFocus&&n.onLastHiddenFocus.apply(n,arguments)})},t.ptm("hiddenLastFocusableEl"),{"data-p-hidden-accessible":!0,"data-p-hidden-focusable":!0}),null,16)],16,Mt)):E("",!0)]}),_:3},16,["onEnter","onAfterEnter","onLeave","onAfterLeave"])]}),_:3},8,["appendTo"])],16,zt)}kt.render=Et;export{rt as O,we as a,Ie as b,Ce as c,kt as s};
|