UNPKG

@progress/kendo-themes-html

Version:

A collection of HTML helpers used for developing Kendo UI themes

2 lines (1 loc) 28.4 kB
var n=(...e)=>e.filter(t=>t!==!0&&!!t).map(t=>Array.isArray(t)?n(...t):typeof t=="object"?Object.keys(t).map((s,a)=>t[a]||t[s]&&s||null).filter(s=>s!==null).join(" "):t).filter(t=>!!t).join(" ");var v=(e,t)=>n({[`${e}-xs`]:t.size==="xsmall",[`${e}-sm`]:t.size==="small",[`${e}-md`]:t.size==="medium",[`${e}-lg`]:t.size==="large",[`${e}-xl`]:t.size==="xlarge",[`${e}-xxl`]:t.size==="xxlarge",[`${e}-xxxl`]:t.size==="xxxlarge"},{[`${e}-${t.fillMode}`]:t.fillMode},{[`${e}-${t.fillMode}-${t.themeColor}`]:t.fillMode&&t.themeColor},{[`${e}-${t.themeColor}`]:t.themeColor&&t.fillMode===void 0},{"k-rounded-sm":t.rounded==="small","k-rounded-md":t.rounded==="medium","k-rounded-lg":t.rounded==="large","k-rounded-full":t.rounded==="full"}),k=(e,t)=>n({"k-valid":t.valid,"k-invalid":t.invalid,"k-hover":t.hover,"k-focus":t.focus,"k-checked":t.checked,"k-active":t.active,"k-selected":t.selected,"k-disabled":t.disabled,"k-indeterminate":t.indeterminate&&!t.checked,"k-loading":t.loading,"k-empty":t.empty,"k-readonly":t.readonly,"k-highlighted":t.highlighted});var i={xsmall:"xsmall",small:"small",medium:"medium",large:"large",xlarge:"xlarge",xxlarge:"xxlarge",xxxlarge:"xxxlarge"},m={small:"small",medium:"medium",large:"large",full:"full"},h={solid:"solid",flat:"flat",outline:"outline",clear:"clear",link:"link"},l={inherit:"inherit",base:"base",primary:"primary",secondary:"secondary",tertiary:"tertiary",info:"info",success:"success",warning:"warning",error:"error",dark:"dark",light:"light",inverse:"inverse"},o={open:"open",hover:"hover",focus:"focus",active:"active",selected:"selected",disabled:"disabled",valid:"valid",invalid:"invalid",loading:"loading",required:"required",empty:"empty",indeterminate:"indeterminate",checked:"checked",readonly:"readonly",highlighted:"highlighted"};import{jsx as So}from"react/jsx-runtime";var No="k-no-data",ue=e=>So("span",{className:n(No,e.className),children:e.children});import{jsx as Y,jsxs as Nt}from"react/jsx-runtime";var De="k-list",yo=[],go={size:[i.small,i.medium,i.large]},St={size:i.medium},z=e=>{let{size:t=St.size,virtualization:s,children:a,optionLabel:r,customValue:p,screenReaders:c,...u}=e,d,f,b,L,N=[];return a?a.map((S,M)=>{S.type===T?(S.props.root===!0?(d=S.props.label,S.props.children.map((C,E)=>{N.push(Y(x,{...C.props},`optChild-${E}-${new Date().getTime()}`))})):S.props.children.forEach((C,E)=>{let A="";E===0&&(A=S.props.label),N.push(Y(x,{className:E===0?"k-first":"",...C.props,groupLabel:A},`groupLabel-${E}-${new Date().getTime()}`))}),f=Y(T,{label:d,virtualization:s,children:N})):S.type===x&&(N.push(Y(x,{...S.props},`${S.type}-${M}`)),b=Y(Z,{virtualization:s,children:N}),c&&(L=Nt(ue,{className:"k-sr-only",children:[N.length," items found."]})))}):L=Y(ue,{children:"No data found."}),Nt("div",{...u,className:n(e.className,De,v(De,{size:t}),{"k-virtual-list":s}),children:[r,p,f,b,L]})};z.states=yo;z.options=go;z.className=De;z.defaultOptions=St;import{jsx as F,jsxs as Co}from"react/jsx-runtime";var Fe="k-list",Io=[],ko={size:[i.small,i.medium,i.large]},yt={size:i.medium},J=e=>{let{size:t=yt.size,virtualization:s,children:a,...r}=e,p,c,u,d=[];return a?a.map((f,b)=>{f.type===T?(f.props.root===!0?(p=f.props.label,f.props.children.map((L,N)=>{d.push(F(x,{...L.props},`optChild-${N}-${new Date().getTime()}`))})):(d.push(F(gt,{...f.props,children:f.props.label},`listChild-${b}`)),f.props.children.map((L,N)=>{d.push(F(x,{...L.props},`fwOptChild-${N}-${new Date().getTime()}`))})),c=F(T,{label:p,virtualization:s,children:d})):f.type===x&&(d.push(F(x,{...f.props},`${f.type}-${b}`)),u=F(Z,{virtualization:s,children:d}))}):u=F(ue,{children:"No data found."}),Co("div",{...r,className:n(e.className,Fe,v(Fe,{size:t}),{"k-virtual-list":s}),children:[c,u]})};J.states=Io;J.options=ko;J.className=Fe;J.defaultOptions=yt;import{jsx as It}from"react/jsx-runtime";var Ie="k-checkbox",Ao=[o.hover,o.focus,o.valid,o.invalid,o.required,o.disabled,o.checked,o.indeterminate],Mo={size:[i.small,i.medium,i.large],rounded:[m.small,m.medium,m.large,m.full]},Je={size:i.medium,rounded:m.medium},V=e=>{let{id:t,checked:s,indeterminate:a,hover:r,focus:p,disabled:c,invalid:u,valid:d,required:f,size:b=Je.size,rounded:L=Je.rounded,...N}=e;return It("span",{className:"k-checkbox-wrap",children:It("input",{...N,id:t,type:"checkbox",defaultChecked:s,required:f,className:n(e.className,Ie,v(Ie,{size:b,rounded:L}),k(Ie,{hover:r,focus:p,disabled:c,invalid:u,valid:d,indeterminate:a,checked:s}))})})};V.states=Ao;V.options=Mo;V.className=Ie;V.defaultOptions=Je;import{jsx as Eo}from"react/jsx-runtime";var kt="k-checkbox-list",To=[],zo={},Ct={layout:"vertical"},j=e=>{let{layout:t=Ct.layout,...s}=e;return Eo("ul",{...s,className:n(e.className,kt,{[`k-list-${t}`]:t}),children:e.children})};j.states=To;j.options=zo;j.className=kt;j.defaultOptions=Ct;import{jsx as Ro}from"react/jsx-runtime";var At="k-checkbox-list-item",Oo=[],Ho={},Ko={},ee=e=>{let{...t}=e;return Ro("li",{...t,className:n(e.className,At),children:e.children})};ee.states=Oo;ee.options=Ho;ee.className=At;ee.defaultOptions=Ko;import{Fragment as ri,jsx as ai,jsxs as li}from"react/jsx-runtime";import{Fragment as ui,jsx as di,jsxs as fi}from"react/jsx-runtime";import{Fragment as Li,jsx as vi,jsxs as Ni}from"react/jsx-runtime";import{Fragment as ki,jsx as Ii,jsxs as Ci}from"react/jsx-runtime";import{jsx as zi}from"react/jsx-runtime";import{jsx as Ki}from"react/jsx-runtime";import{Fragment as Go,jsx as Mt}from"react/jsx-runtime";var Ue="k-icon k-font-icon",Po=[],wo={size:[i.xsmall,i.small,i.medium,i.large,i.xlarge,i.xxlarge,i.xxxlarge],themeColor:[l.base,l.primary,l.secondary,l.tertiary,l.success,l.warning,l.error,l.info,l.light,l.dark]},Vo={},fe=e=>{let{size:t,themeColor:s,icon:a,rotate:r,flip:p,...c}=e;return a?Mt("span",{...c,className:n(e.className,Ue,v(Ue,{size:t}),{[`k-i-${a}`]:a,[`k-color-${s}`]:s,[`k-rotate-${r}`]:r,"k-flip-h":p==="h"||p==="both","k-flip-v":p==="v"||p==="both"})}):Mt(Go,{})};fe.states=Po;fe.options=wo;fe.className=Ue;fe.defaultOptions=Vo;var Tt=fe;import{Fragment as _o,jsx as ke}from"react/jsx-runtime";var We="k-icon k-svg-icon",$o=[],Bo={size:[i.xsmall,i.small,i.medium,i.large,i.xlarge,i.xxlarge,i.xxxlarge],themeColor:[l.base,l.primary,l.secondary,l.tertiary,l.success,l.warning,l.error,l.info,l.light,l.dark]},zt={viewBox:"0 0 24 24"},he=e=>{let{size:t,themeColor:s,rotate:a,flip:r,viewBox:p=zt.viewBox,icon:c,...u}=e;if(!c)return ke(_o,{});c==="none"&&{...u,className:n(e.className,We,"k-none")};let d=typeof c=="object"&&c.name&&c.name;return ke("span",{...u,className:n(e.className,We,v("k-icon",{size:t}),{[`k-svg-i-${d}`]:d,[`k-color-${s}`]:s,[`k-rotate-${a}`]:a,"k-flip-h":r==="h"||r==="both","k-flip-v":r==="v"||r==="both"}),children:ke("svg",{"aria-hidden":!0,focusable:!1,xmlns:"http://www.w3.org/2000/svg",viewBox:typeof c=="object"?c.viewBox:p,dangerouslySetInnerHTML:typeof c=="object"?{__html:c.content}:void 0,children:c?void 0:e.children})})};he.states=$o;he.options=Bo;he.className=We;he.defaultOptions=zt;var Qe=he;import*as Et from"@progress/kendo-svg-icons";import{Fragment as Ot,jsx as xe}from"react/jsx-runtime";var Xo=e=>e.replace(/([-_][a-z0-9])/gi,t=>t.toUpperCase().replace("-","").replace("_","")),Do=[],Fo={size:[i.xsmall,i.small,i.medium,i.large,i.xlarge,i.xxlarge,i.xxxlarge],themeColor:[l.base,l.primary,l.secondary,l.tertiary,l.success,l.warning,l.error,l.info,l.light,l.dark]},Ye={viewBox:"0 0 24 24",type:"svg"},y=e=>{let{size:t,themeColor:s,icon:a,type:r=Ye.type,rotate:p,flip:c,viewBox:u=Ye.viewBox,...d}=e;if(!a)return xe(Ot,{});if(r==="svg"){if(a==="none")return xe(Qe,{...d,icon:a,size:t});let f=Xo(`${a}-icon`);return Et[f]?xe(Qe,{...d,icon:Et[f],size:t,themeColor:s,rotate:p,flip:c,viewBox:u}):xe(Ot,{})}return xe(Tt,{...d,icon:a,size:t,themeColor:s,rotate:p,flip:c})};y.states=Do;y.options=Fo;y.defaultOptions=Ye;import{jsx as Ce,jsxs as Wo}from"react/jsx-runtime";var Ze="k-list-item",Jo=[o.hover,o.focus,o.selected,o.disabled],qo={},Uo={},x=e=>{let{text:t,groupLabel:s,group:a,showIcon:r,iconName:p,showCheckbox:c,checked:u,hover:d,focus:f,selected:b,disabled:L,...N}=e,S=t||e.children;return Wo("li",{...N,className:n(e.className,a?"k-list-group-item":Ze,k(Ze,{hover:d,focus:f,disabled:L,selected:b})),children:[c&&Ce(V,{checked:u}),r&&Ce(y,{icon:p}),Ce("span",{className:"k-list-item-text",children:S}),s&&s!==""&&Ce("div",{className:"k-list-item-group-label",children:s})]})};x.states=Jo;x.options=qo;x.className=Ze;x.defaultOptions=Uo;import{jsx as je,jsxs as Yo}from"react/jsx-runtime";var Qo="k-list-content",Z=e=>{let{virtualization:t,...s}=e;return Yo("div",{...s,className:n(Qo,e.className),children:[je("ul",{className:n("k-list-ul"),children:e.children}),t&&je("div",{className:"k-height-container",children:je("div",{})})]})};import{jsx as Ht}from"react/jsx-runtime";var Zo="k-list-group-sticky-header",Kt=e=>Ht("div",{className:n(Zo,e.className),children:Ht("div",{className:"k-list-header-text",children:e.children})});import{Fragment as jo,jsx as Rt,jsxs as es}from"react/jsx-runtime";var T=e=>{let{virtualization:t,label:s}=e;return es(jo,{children:[s&&Rt(Kt,{children:s}),e.children&&Rt(Z,{virtualization:t,children:e.children})]})};import{jsx as Pt}from"react/jsx-runtime";var ts="k-list-group-item",gt=e=>Pt("li",{className:n(ts,e.className),children:Pt("span",{className:"k-list-item-text",children:e.children})});import{jsx as is}from"react/jsx-runtime";var et="k-list-optionlabel",os=[o.hover,o.focus,o.selected,o.disabled],ss={},ns={},Ae=e=>{let{text:t,hover:s,focus:a,selected:r,disabled:p,...c}=e;return is("div",{...c,className:n(et,k(et,{hover:s,focus:a,selected:r,disabled:p})),children:t})};Ae.states=os;Ae.options=ss;Ae.className=et;Ae.defaultOptions=ns;import{jsx as ps}from"react/jsx-runtime";var tt="k-list-custom-value",as=[o.hover,o.focus,o.selected,o.disabled],rs={},ls={},G=e=>{let{text:t,hover:s,focus:a,selected:r,disabled:p,...c}=e;return ps("div",{...c,className:n(tt,k(tt,{hover:s,focus:a,selected:r,disabled:p})),children:t})};G.states=as;G.options=rs;G.className=tt;G.defaultOptions=ls;import{jsx as Oa}from"react/jsx-runtime";import{jsx as Pa}from"react/jsx-runtime";import{jsx as $a,jsxs as Ba}from"react/jsx-runtime";import{jsx as Fa,jsxs as Ja}from"react/jsx-runtime";import{jsx as Qa}from"react/jsx-runtime";import{jsx as er,jsxs as tr}from"react/jsx-runtime";import{jsx as ir,jsxs as ar}from"react/jsx-runtime";import{jsx as ds}from"react/jsx-runtime";var Me="k-input",cs=[o.hover,o.focus,o.valid,o.invalid,o.required,o.disabled,o.loading,o.readonly],ms={size:[i.small,i.medium,i.large],rounded:[m.small,m.medium,m.large,m.full],fillMode:[h.solid,h.flat,h.outline]},Te={size:i.medium,rounded:i.medium,fillMode:h.solid},I=e=>{let{hover:t,focus:s,disabled:a,invalid:r,valid:p,loading:c,readonly:u,size:d=Te.size,rounded:f=Te.rounded,fillMode:b=Te.fillMode,...L}=e;return ds("span",{...L,className:n(e.className,Me,v(Me,{size:d,rounded:f,fillMode:b}),k(Me,{hover:t,focus:s,disabled:a,invalid:r,valid:p,loading:c,readonly:u}))})};I.states=cs;I.options=ms;I.className=Me;I.defaultOptions=Te;import{jsx as hs}from"react/jsx-runtime";var ze="k-picker",us=[o.hover,o.focus,o.valid,o.invalid,o.required,o.disabled,o.loading,o.readonly],fs={size:[i.small,i.medium,i.large],rounded:[m.small,m.medium,m.large,m.full],fillMode:[h.solid,h.flat,h.outline]},Ee={size:i.medium,rounded:m.medium,fillMode:h.solid},Oe=e=>{let{hover:t,focus:s,disabled:a,invalid:r,valid:p,loading:c,readonly:u,size:d=Ee.size,rounded:f=Ee.rounded,fillMode:b=Ee.fillMode,...L}=e;return hs("span",{...L,className:n(e.className,ze,v(ze,{size:d,rounded:f,fillMode:b}),k(ze,{hover:t,focus:s,disabled:a,invalid:r,valid:p,loading:c,readonly:u})),children:e.children})};Oe.states=us;Oe.options=fs;Oe.className=ze;Oe.defaultOptions=Ee;import{Fragment as vs,jsx as ot}from"react/jsx-runtime";var wt="k-clear-value",xs=[o.disabled,o.loading,o.readonly],bs={},K=e=>{let{disabled:t,loading:s,readonly:a,value:r}=e;return t||a||s||!r?ot(vs,{}):ot("span",{className:n(e.className,wt),children:ot(y,{icon:"x"})})};K.states=xs;K.options=bs;K.className=wt;import{jsx as Ss}from"react/jsx-runtime";var st="k-input-inner",Ls=[],Ns={},He={type:"text",autocomplete:"off",value:"",placeholder:""},R=e=>{let{value:t=He.value,type:s=He.type,placeholder:a=He.placeholder,autocomplete:r=He.autocomplete,...p}=e;return Ss("input",{...p,type:s,className:n(e.className,st,v(st,e)),placeholder:a,autoComplete:r,defaultValue:t})};R.states=Ls;R.options=Ns;R.className=st;import{jsx as Vt,jsxs as Is}from"react/jsx-runtime";var nt="k-input-inner",ys=[],gs={},it=e=>{let{value:t,placeholder:s,showValue:a,valueIcon:r,valueIconName:p,...c}=e;return Is("span",{...c,className:n(e.className,nt,v(nt,e)),children:[r,!r&&p&&Vt(y,{className:"k-input-value-icon",icon:p}),a&&!t&&s,a&&t&&Vt("span",{className:"k-input-value-text",children:t})]})};it.states=ys;it.options=gs;it.className=nt;import{jsx as As}from"react/jsx-runtime";var at="k-input-inner",ks=[],Cs={},Gt={value:"",placeholder:""},rt=e=>{let{value:t=Gt.value,placeholder:s=Gt.placeholder,rows:a,...r}=e;return As("textarea",{...r,className:n(e.className,at,v(at,e)),placeholder:s,rows:a,defaultValue:t})};rt.states=ks;rt.options=Cs;rt.className=at;import{Fragment as Ts,jsx as $t}from"react/jsx-runtime";var Bt="k-input-loading-icon",Ms=[o.disabled,o.loading],$=e=>{let{disabled:t,loading:s}=e;return t||!s?$t(Ts,{}):$t("span",{className:n(e.className,Bt,"k-icon k-i-loading")})};$.states=Ms;$.className=Bt;import{Fragment as Os,jsx as _t}from"react/jsx-runtime";var Xt="k-input-validation-icon",zs=[o.valid,o.invalid,o.disabled,o.loading],Es={},P=e=>{let{valid:t,invalid:s,disabled:a,loading:r}=e,p=s?"warning-circle":"check-circle";return a||r||!!!(t||s)?_t(Os,{}):_t(y,{className:n(Xt),icon:p})};P.states=zs;P.options=Es;P.className=Xt;import{Fragment as Rs,jsx as Dt}from"react/jsx-runtime";var Hs="k-input-prefix",Ks={direction:"horizontal"},Ke=e=>{let{direction:t=Ks.direction,...s}=e;return e.children?Dt("span",{...s,className:n(Hs,e.className,{[`k-input-prefix-${t}`]:t}),children:e.children}):Dt(Rs,{})};import{Fragment as Vs,jsx as Ft}from"react/jsx-runtime";var Ps="k-input-suffix",ws={direction:"horizontal"},Re=e=>{let{direction:t=ws.direction,...s}=e;return e.children?Ft("span",{...s,className:n(Ps,e.className,{[`k-input-suffix-${t}`]:t}),children:e.children}):Ft(Vs,{})};import{jsx as al}from"react/jsx-runtime";import{jsx as cl}from"react/jsx-runtime";import{jsx as $s}from"react/jsx-runtime";var Jt="k-input-separator",Gs={direction:"vertical"},te=e=>{let{direction:t=Gs.direction,...s}=e;return $s("span",{...s,className:n(Jt,e.className,{[`${Jt}-${t}`]:t})})};import{Fragment as Xs,jsx as be,jsxs as qt}from"react/jsx-runtime";var Pe="k-button",Bs=[o.hover,o.focus,o.active,o.selected,o.disabled],_s={size:[i.small,i.medium,i.large],rounded:[m.small,m.medium,m.large,m.full],fillMode:[h.solid,h.flat,h.outline,h.clear,h.link],themeColor:[l.base,l.primary,l.secondary,l.tertiary,l.success,l.warning,l.error,l.info,l.light,l.dark,l.inverse]},q={size:i.medium,rounded:m.medium,fillMode:h.solid,themeColor:l.base,showArrow:!1,arrowIconName:"caret-alt-down"},O=e=>{let{size:t=q.size,rounded:s=q.rounded,fillMode:a=q.fillMode,themeColor:r=q.themeColor,showArrow:p=q.showArrow,arrowIconName:c=q.arrowIconName,hover:u,focus:d,active:f,selected:b,disabled:L,icon:N,text:S,iconClassName:M,...C}=e,E=N!==void 0,A=e.children!==void 0;return qt("button",{...C,className:n(e.className,Pe,v(Pe,{size:t,rounded:s,fillMode:a,themeColor:r}),k(Pe,{hover:u,focus:d,active:f,disabled:L,selected:b}),{"k-icon-button":!S&&!A&&E}),children:[N&&be(y,{className:n(M,"k-button-icon"),icon:N}),S?qt(Xs,{children:[S&&be("span",{className:"k-button-text",children:S}),e.children]}):e.children&&be("span",{className:"k-button-text",children:e.children}),p&&be("span",{className:"k-menu-button-arrow k-button-arrow",children:be(y,{icon:c})})]})};O.states=Bs;O.options=_s;O.className=Pe;O.defaultOptions=q;import{jsx as Rl}from"react/jsx-runtime";import{jsx as Gl}from"react/jsx-runtime";import{jsx as Xl}from"react/jsx-runtime";import{jsx as jl}from"react/jsx-runtime";import{jsx as Ut}from"react/jsx-runtime";var ve="k-avatar";var Ds=[o.hover,o.focus,o.active,o.selected,o.disabled],Fs={size:[i.small,i.medium,i.large],rounded:[m.small,m.medium,m.large,m.full],fillMode:[h.solid,h.flat,h.outline],themeColor:[l.base,l.primary,l.secondary,l.tertiary,l.success,l.warning,l.error,l.info,l.light,l.dark,l.inverse]},U={type:"text",size:i.medium,rounded:m.full,fillMode:h.solid,themeColor:l.primary,border:!1},oe=e=>{let{size:t=U.size,rounded:s=U.rounded,fillMode:a=U.fillMode,themeColor:r=U.themeColor,type:p=U.type,border:c=U.border,...u}=e;return Ut("div",{...u,className:n(e.className,ve,v(ve,{size:t,rounded:s,fillMode:a,themeColor:r}),{[`${ve}-bordered`]:c}),children:Ut("span",{className:`${ve}-${p}`,children:e.children})})};oe.states=Ds;oe.options=Fs;oe.className=ve;oe.defaultOptions=U;import{jsx as ap}from"react/jsx-runtime";import{jsx as cp}from"react/jsx-runtime";import{jsx as fp}from"react/jsx-runtime";import{jsx as se,jsxs as Us}from"react/jsx-runtime";var we="k-chip",Js=[o.hover,o.focus,o.active,o.selected,o.disabled],qs={size:[i.small,i.medium,i.large],rounded:[m.small,m.medium,m.large,m.full],fillMode:[h.solid,h.outline],themeColor:[l.base,l.success,l.warning,l.error,l.info]},ne={size:i.medium,rounded:m.medium,fillMode:h.solid,themeColor:l.base,avatarImage:"/packages/html/assets/avatar.jpg"},Ve=e=>{let{size:t=ne.size,rounded:s=ne.rounded,fillMode:a=ne.fillMode,themeColor:r=ne.themeColor,text:p,icon:c,actions:u,showAvatar:d,avatarImage:f=ne.avatarImage,hover:b,focus:L,active:N,selected:S,disabled:M,...C}=e;return Us("div",{...C,className:n(e.className,we,v(we,{size:t,rounded:s,fillMode:a,themeColor:r}),k(we,{hover:b,focus:L,active:N,disabled:M,selected:S})),children:[c&&se(y,{className:"k-chip-icon",icon:c,size:"small"}),d&&se(oe,{className:"k-chip-avatar",type:"image",children:se("img",{src:f})}),se("span",{className:"k-chip-content",children:e.children?e.children:p&&se("span",{className:"k-chip-label",children:p})}),u&&se("span",{className:"k-chip-actions",children:u})]})};Ve.states=Js;Ve.options=qs;Ve.className=we;Ve.defaultOptions=ne;import{jsx as Ys}from"react/jsx-runtime";var lt="k-chip-list",Ws=[],Qs={size:[i.small,i.medium,i.large]},Qt={size:i.medium},ie=e=>{let{size:t=Qt.size,...s}=e;return Ys("div",{...s,className:n(e.className,lt,v(lt,{size:t})),children:e.children})};ie.states=Ws;ie.options=Qs;ie.className=lt;ie.defaultOptions=Qt;import{jsx as Ep}from"react/jsx-runtime";import{jsx as Rp}from"react/jsx-runtime";import{jsx as Gp}from"react/jsx-runtime";import{jsx as Dp}from"react/jsx-runtime";import{Fragment as Qp,jsx as Wp,jsxs as Yp}from"react/jsx-runtime";import{jsx as Yt}from"react/jsx-runtime";var Zt="k-animation-container",js=[],en={},jt={positionMode:"absolute"},B=e=>{let{positionMode:t=jt.positionMode,animationStyle:s,offset:a,...r}=e;return Yt("div",{...r,style:{...a,...e.style},className:n(e.className,Zt,"k-animation-container-shown",{"k-animation-container-fixed":t==="fixed"}),children:Yt("div",{className:"k-child-animation-container",style:s,children:e.children})})};B.states=js;B.options=en;B.className=Zt;B.defaultOptions=jt;import{jsx as eo}from"react/jsx-runtime";var to="k-popup",tn=[],on={},oo={positionMode:"absolute"},ae=e=>{let{offset:t,positionMode:s=oo.positionMode,animationStyle:a,...r}=e;return eo(B,{positionMode:s,offset:t,animationStyle:a,children:eo("div",{...r,className:n(e.className,to),children:e.children})})};ae.states=tn;ae.options=on;ae.className=to;ae.defaultOptions=oo;import{jsx as an}from"react/jsx-runtime";var $e="k-actions",sn=[],nn={},pt={alignment:"start",orientation:"horizontal"},re=e=>{let{alignment:t=pt.alignment,orientation:s=pt.orientation,...a}=e;return an("div",{...a,className:n($e,{[`${$e}-${t}`]:t,[`${$e}-${s}`]:s},e.className),children:e.children})};re.states=sn;re.options=nn;re.className=$e;re.defaultOptions=pt;import{jsx as ln}from"react/jsx-runtime";var rn="k-actionsheet-footer",so={alignment:"stretched",orientation:"horizontal"},ct=e=>{let{alignment:t=so.alignment,orientation:s=so.orientation,template:a,as:r=a?"div":re,...p}=e;return ln(r,{...p,...!a&&{alignment:t,orientation:s},className:n(e.className,rn),children:e.children})};import{jsx as Le,jsxs as mn}from"react/jsx-runtime";var no="k-searchbox",pn=[o.hover,o.focus,o.valid,o.invalid,o.required,o.disabled,o.loading],cn={size:[i.small,i.medium,i.large],rounded:[m.small,m.medium,m.large,m.full],fillMode:[h.solid,h.flat,h.outline]},mt={showIcon:!0,icon:"search",size:I.defaultOptions.size,rounded:I.defaultOptions.rounded,fillMode:I.defaultOptions.fillMode},le=e=>{let{value:t,placeholder:s,size:a,rounded:r,fillMode:p,hover:c,focus:u,valid:d,invalid:f,required:b,loading:L,disabled:N,showIcon:S=mt.showIcon,icon:M=mt.icon,...C}=e;return mn(I,{...C,size:a,rounded:r,fillMode:p,hover:c,focus:u,valid:d,invalid:f,required:b,loading:L,disabled:N,className:n(e.className,no),children:[S&&Le(y,{className:"k-input-icon",icon:M}),Le(R,{placeholder:s,value:t}),Le($,{...e}),Le(P,{...e}),Le(K,{...e})]})};le.states=pn;le.options=cn;le.className=no;le.defaultOptions=mt;import{jsx as Pc}from"react/jsx-runtime";import{Fragment as io,jsx as _,jsxs as dt}from"react/jsx-runtime";var ao="k-textbox",dn=[o.hover,o.focus,o.valid,o.invalid,o.required,o.disabled,o.loading,o.readonly],un={size:[i.small,i.medium,i.large],rounded:[m.small,m.medium,m.large,m.full],fillMode:[h.solid,h.flat,h.outline]},W={showClearButton:!0,showValidationIcon:!0,size:I.defaultOptions.size,rounded:I.defaultOptions.rounded,fillMode:I.defaultOptions.fillMode,separators:!0},pe=e=>{let{size:t=W.size,rounded:s=W.rounded,fillMode:a=W.fillMode,separators:r=W.separators,showClearButton:p=W.showClearButton,showValidationIcon:c=W.showValidationIcon,prefix:u,suffix:d,type:f,value:b,placeholder:L,hover:N,focus:S,valid:M,invalid:C,required:E,loading:A,disabled:H,readonly:de,...Xe}=e;return dt(I,{...Xe,size:t,rounded:s,fillMode:a,hover:N,focus:S,valid:M,invalid:C,required:E,loading:A,disabled:H,readonly:de,className:n(e.className,ao),children:[u&&dt(io,{children:[_(Ke,{children:u}),r&&_(te,{})]}),_(R,{placeholder:L,value:b,type:f}),c&&_(P,{valid:M,invalid:C,loading:A,disabled:H}),_($,{loading:A,disabled:H}),p&&_(K,{loading:A,disabled:H,readonly:de,value:b}),d&&dt(io,{children:[r&&_(te,{}),_(Re,{children:d})]})]})};pe.states=dn;pe.options=un;pe.className=ao;pe.defaultOptions=W;import{jsx as qc}from"react/jsx-runtime";import{Fragment as jc,jsx as Zc}from"react/jsx-runtime";import{Fragment as am,jsx as im}from"react/jsx-runtime";import{jsx as X,jsxs as ut}from"react/jsx-runtime";var lo="k-actionsheet-titlebar",fn={},D=e=>{let{title:t,subtitle:s,actionsStart:a,actionsEnd:r,filter:p,input:c,inputValue:u,inputPlaceholder:d,adaptive:f,children:b,...L}=e;return ut("div",{...L,className:n(e.className,lo),children:[ut("div",{className:"k-actionsheet-titlebar-group",children:[a&&X("div",{className:"k-actionsheet-actions",children:a}),!b&&ut("div",{className:"k-actionsheet-title",children:[t&&X("div",{className:"k-text-center",children:t}),s&&X("div",{className:"k-actionsheet-subtitle k-text-center",children:s})]}),b&&X("div",{className:"k-actionsheet-title",children:b}),r&&X("div",{className:"k-actionsheet-actions",children:r})]}),(c||p)&&X("div",{className:"k-actionsheet-titlebar-group k-actionsheet-filter",children:c?X(pe,{value:u,placeholder:d,size:f?"large":"medium"}):X(le,{placeholder:"Filter",size:f?"large":"medium"})})]})};D.className=lo;D.defaultOptions=fn;import{jsx as ft,jsxs as vn}from"react/jsx-runtime";var ht="k-actionsheet-view",hn=[],xn={},bn={},ce=e=>{let{adaptive:t,animated:s,children:a,header:r,footer:p,...c}=e,u=r?.type===D&&ft(D,{adaptive:t,...r?.props}),d=p?.type===ct&&ft(ct,{...p?.props});return vn("div",{...c,className:n(e.className,ht,{[`${ht}-animated`]:s}),children:[u,ft("div",{className:"k-actionsheet-content",children:a}),d]})};ce.states=hn;ce.options=xn;ce.className=ht;ce.defaultOptions=bn;import{jsx as Be,jsxs as Sn}from"react/jsx-runtime";var po="k-actionsheet",Ln=[],Nn={},Ne={side:"bottom",fullscreen:!1,adaptive:!1,overlay:!0},Q=e=>{let{side:t=Ne.side,fullscreen:s=Ne.fullscreen,adaptive:a=Ne.adaptive,overlay:r=Ne.overlay,template:p,children:c,header:u,footer:d,...f}=e;return Sn("div",{className:"k-actionsheet-container",children:[r&&Be("div",{className:"k-overlay"}),Be(B,{animationStyle:{[`${s===!0?"top":t}`]:0,[`${s===!0?"width":null}`]:"100%",[`${s===!0?"height":null}`]:"100%",[`${t==="top"||t==="bottom"?"width":null}`]:"100%",[`${t==="left"||t==="right"?"height":null}`]:"100%"},children:Be("div",{...f,className:n(e.className,po,{[`k-actionsheet-${t}`]:s===!1,"k-actionsheet-fullscreen":s===!0,"k-adaptive-actionsheet":a}),children:p||Be(ce,{header:u,footer:d,adaptive:a,...e,children:c})})})]})};Q.states=Ln;Q.options=Nn;Q.className=po;Q.defaultOptions=Ne;import{jsx as zm}from"react/jsx-runtime";import{Fragment as gn,jsx as Se,jsxs as xt}from"react/jsx-runtime";var bt="k-actionsheet-item",yn=[o.hover,o.focus,o.selected,o.disabled],vt=e=>{let{iconName:t,text:s,description:a,hover:r,focus:p,selected:c,disabled:u,...d}=e;return xt("span",{...d,className:n(e.className,bt,k(bt,{hover:r,focus:p,selected:c,disabled:u})),children:[!e.children&&Se(gn,{children:xt("span",{className:"k-actionsheet-action",children:[t&&Se("span",{className:"k-icon-wrap",children:Se(y,{className:"k-actionsheet-item-icon",icon:t})}),xt("span",{className:"k-actionsheet-item-text",children:[s&&Se("span",{className:"k-actionsheet-item-title",children:s}),a&&Se("span",{className:"k-actionsheet-item-description",children:a})]})]})}),e.children]})};vt.states=yn;vt.className=bt;import{jsx as Gm,jsxs as $m}from"react/jsx-runtime";import{jsx as Dm}from"react/jsx-runtime";import{jsx as Um}from"react/jsx-runtime";import{jsx as Zm}from"react/jsx-runtime";import{Fragment as _e,jsx as g,jsxs as me}from"react/jsx-runtime";var mo="k-multiselect",In=[o.hover,o.focus,o.valid,o.invalid,o.required,o.disabled,o.loading,o.readonly],kn={size:[i.small,i.medium,i.large],rounded:[m.small,m.medium,m.large,m.full],fillMode:[h.solid,h.flat,h.outline]},ye={size:I.defaultOptions.size,rounded:I.defaultOptions.rounded,fillMode:I.defaultOptions.fillMode,separators:!0},ge=e=>{let{size:t=ye.size,rounded:s=ye.rounded,fillMode:a=ye.fillMode,separators:r=ye.separators,prefix:p,suffix:c,value:u,placeholder:d,tags:f,popup:b,showArrowButton:L,hover:N,focus:S,valid:M,invalid:C,required:E,loading:A,disabled:H,readonly:de,opened:Xe,adaptive:fo,adaptiveSettings:ho,adaptiveTitle:xo,adaptiveSubtitle:bo,adaptiveCustomValue:vo,...Lo}=e;return me(_e,{children:[me(I,{...Lo,size:t,rounded:s,fillMode:a,hover:N,focus:S,valid:M,invalid:C,required:E,loading:A,disabled:H,readonly:de,className:n(e.className,mo),children:[p&&me(_e,{children:[g(Ke,{children:p}),r&&g(te,{})]}),me("div",{className:"k-input-values",children:[g(ie,{size:t,children:g(_e,{children:f})}),g(R,{placeholder:d,value:u})]}),g(P,{valid:M,invalid:C,loading:A,disabled:H}),g($,{loading:A,disabled:H}),g(K,{loading:A,disabled:H,readonly:de,value:f?"value":""}),c&&me(_e,{children:[r&&g(te,{}),g(Re,{children:c})]}),L&&g(O,{className:"k-input-button",icon:"caret-alt-down",rounded:null,size:t,fillMode:a})]}),Xe&&b&&g(ae,{className:"k-list-container k-multiselect-popup",children:b}),fo&&g(Q,{adaptive:!0,...ho,header:g(D,{actionsEnd:g(O,{icon:"check",themeColor:"primary",size:"large",fillMode:"flat"}),input:!0,inputValue:u,inputPlaceholder:d,title:xo,subtitle:bo}),children:g("div",{className:"k-list-container",children:me(z,{customValue:vo?g(G,{text:`Use "${u}"`}):void 0,size:"large",children:[g(x,{text:"List item"}),g(x,{text:"List item"}),g(x,{text:"List item"})]})})})]})};ge.states=In;ge.options=kn;ge.className=mo;ge.defaultOptions=ye;var uo=ge;import{jsx as w,jsxs as Lt}from"react/jsx-runtime";var gd=({value:e="Custom value",...t})=>w(uo,{value:e,opened:!0,popup:Lt(z,{customValue:w(G,{text:`Use "${e}"`}),children:[Lt(T,{label:"Group 1",root:!0,children:[w(x,{children:"List group 1 item 1"}),w(x,{children:"List group 1 item 2"}),w(x,{children:"List group 1 item 3"})]}),Lt(T,{children:[w(x,{group:!0,children:"Group 2"}),w(x,{children:"List group 1 item 1"}),w(x,{children:"List group 1 item 2"}),w(x,{children:"List group 1 item 3"})]})]}),...t});export{gd as MultiSelectGroupingModernCustomValue};