UNPKG

@progress/kendo-themes-html

Version:

A collection of HTML helpers used for developing Kendo UI themes

2 lines (1 loc) 24.5 kB
var Lt=Object.create;var ae=Object.defineProperty;var At=Object.getOwnPropertyDescriptor;var yt=Object.getOwnPropertyNames;var wt=Object.getPrototypeOf,Ot=Object.prototype.hasOwnProperty;var St=(e,t)=>{for(var o in t)ae(e,o,{get:t[o],enumerable:!0})},De=(e,t,o,s)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of yt(t))!Ot.call(e,r)&&r!==o&&ae(e,r,{get:()=>t[r],enumerable:!(s=At(t,r))||s.enumerable});return e};var Tt=(e,t,o)=>(o=e!=null?Lt(wt(e)):{},De(t||!e||!e.__esModule?ae(o,"default",{value:e,enumerable:!0}):o,e)),Bt=e=>De(ae({},"__esModule",{value:!0}),e);var Oo={};St(Oo,{FILE_BOX_CLASSNAME:()=>Ue,FileBox:()=>X,default:()=>wo});module.exports=Bt(Oo);var l=(...e)=>e.filter(t=>t!==!0&&!!t).map(t=>Array.isArray(t)?l(...t):typeof t=="object"?Object.keys(t).map((o,s)=>t[s]||t[o]&&o||null).filter(o=>o!==null).join(" "):t).filter(t=>!!t).join(" ");var H=(e,t)=>l({[`${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.themeColor}`]:t.themeColor},{"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-rounded-none":t.rounded==="none"}),J=(e,t)=>{let{valid:o,invalid:s,hover:r,focus:u,checked:i,active:c,selected:h,disabled:x,indeterminate:d,loading:f,empty:b,readonly:R,highlighted:D,...B}=t;return l({"k-valid":o,"k-invalid":s,"k-hover":r,"k-focus":u,"k-checked":i,"k-active":c,"k-selected":h,"k-disabled":x,"k-indeterminate":d&&!i,"k-loading":f,"k-empty":b,"k-readonly":R,"k-highlighted":D},Object.keys(B).reduce((v,w)=>(w.startsWith("k-")?v[w]=B[w]:v[`k-${w}`]=B[w],v),{}))};function He(e,t){if(!t)return{};let o=Array.isArray(t)?t:[t];return Object.fromEntries(o.map(s=>[`k-${s}`,!0]))}var a={undefined:void 0,xsmall:"xsmall",small:"small",medium:"medium",large:"large",xlarge:"xlarge",xxlarge:"xxlarge",xxxlarge:"xxxlarge"},L={undefined:void 0,none:"none",small:"small",medium:"medium",large:"large",full:"full"},A={undefined:void 0,solid:"solid",flat:"flat",outline:"outline",clear:"clear",link:"link"},K={undefined:void 0,outline:"outline",solid:"solid",duotone:"duotone"},n={undefined:void 0,inherit:"inherit",base:"base",primary:"primary",secondary:"secondary",tertiary:"tertiary",info:"info",success:"success",warning:"warning",error:"error",inverse:"inverse"},p={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",generating:"generating",expanded:"expanded"};var te=require("react/jsx-runtime"),pe="k-font-icon",Ct=[],_t={size:[a.undefined,a.xsmall,a.small,a.medium,a.large,a.xlarge,a.xxlarge,a.xxxlarge],themeColor:[n.undefined,n.base,n.primary,n.secondary,n.tertiary,n.success,n.warning,n.error,n.info]},Pt={},oe=e=>{let{size:t,themeColor:o,icon:s,rotate:r,flip:u,...i}=e;return s?(0,te.jsx)("span",{...i,className:l(e.className,pe,H(pe,{size:t}),{[`k-i-${s}`]:s,[`k-color-${o}`]:o,[`k-rotate-${r}`]:r,"k-flip-h":u==="h"||u==="both","k-flip-v":u==="v"||u==="both"}),"aria-hidden":"true"}):(0,te.jsx)(te.Fragment,{})};oe.states=Ct;oe.options=_t;oe.className=pe;oe.defaultOptions=Pt;var Fe=oe;var q=require("react/jsx-runtime"),de="k-svg-icon",Rt=[],Kt={size:[a.undefined,a.xsmall,a.small,a.medium,a.large,a.xlarge,a.xxlarge,a.xxxlarge],themeColor:[n.undefined,n.base,n.primary,n.secondary,n.tertiary,n.success,n.warning,n.error,n.info],variant:[K.outline,K.solid,K.duotone]},fe={viewBox:"0 0 24 24",variant:K.outline},ne=e=>{var f,b;let{size:t,themeColor:o,rotate:s,flip:r,viewBox:u=fe.viewBox,variant:i=fe.variant,icon:c,...h}=e;if(!c)return(0,q.jsx)(q.Fragment,{});if(c==="none")return(0,q.jsx)("span",{...h,className:l(e.className,de,H("k-icon",{size:t}),"k-none"),"aria-hidden":"true"});let x=typeof c=="object"&&c.name&&c.name,d=typeof c=="object"?i&&((f=c.variants)==null?void 0:f[i])||((b=c.variants)==null?void 0:b.outline)||c.content:void 0;return(0,q.jsx)("span",{...h,className:l(e.className,de,H("k-icon",{size:t}),{[`k-svg-i-${x}`]:x,[`k-color-${o}`]:o,[`k-rotate-${s}`]:s,"k-flip-h":r==="h"||r==="both","k-flip-v":r==="v"||r==="both"}),"aria-hidden":"true",children:(0,q.jsx)("svg",{"aria-hidden":!0,focusable:!1,xmlns:"http://www.w3.org/2000/svg",viewBox:typeof c=="object"?c.viewBox:u,dangerouslySetInnerHTML:d!==void 0?{__html:d}:void 0,children:c?void 0:e.children})})};ne.states=Rt;ne.options=Kt;ne.className=de;ne.defaultOptions=fe;var be=ne;var xe=Tt(require("@progress/kendo-svg-icons"));var $e="icon",Ve="icons";var Ge=require("react");var Xe=require("react"),We=(0,Xe.createContext)({iconsType:"svg"});var F=require("react/jsx-runtime"),ie="k-icon",zt=e=>e.replace(/([-_][a-z0-9])/gi,t=>t.toUpperCase().replace("-","").replace("_","")),Ut=[],Dt={size:[a.undefined,a.xsmall,a.small,a.medium,a.large,a.xlarge,a.xxlarge,a.xxxlarge],themeColor:[n.undefined,n.base,n.primary,n.secondary,n.tertiary,n.success,n.warning,n.error,n.info],variant:[K.outline,K.solid,K.duotone]},le={viewBox:"0 0 24 24",type:"svg",variant:K.outline},M=e=>{let{iconsType:t}=(0,Ge.useContext)(We),{size:o,themeColor:s,icon:r,type:u=t||le.type,rotate:i,flip:c,viewBox:h=le.viewBox,variant:x=le.variant,...d}=e;if(!r)return(0,F.jsx)(F.Fragment,{});if((t||u)==="svg"){if(r==="none")return(0,F.jsx)(be,{...d,className:l(e.className,ie),icon:r,size:o,variant:x});let b=xe[r]?r:zt(`${r}-icon`);return xe[b]?(0,F.jsx)(be,{...d,className:l(e.className,ie),icon:xe[b],size:o,themeColor:s,rotate:i,flip:c,viewBox:h,variant:x}):(0,F.jsx)(F.Fragment,{})}return(0,F.jsx)(Fe,{...d,className:l(e.className,ie),icon:r,size:o,themeColor:s,rotate:i,flip:c})};M.states=Ut;M.options=Dt;M.defaultOptions=le;M.className=ie;M.moduleName=$e;M.folderName=Ve;M.ariaSpec={selector:".k-icon, .k-svg-icon",rules:[{selector:".k-icon, .k-svg-icon",attribute:"aria-hidden=true",usage:"Hides the icon element and all its children from assistive technologies."}]};var Me="button",Je=Me;var O=require("react/jsx-runtime"),re="k-button",Ht=["icon-button"],Ft=[p.hover,p.focus,p.active,p.selected,p.disabled,p.generating],$t={size:[a.undefined,a.xsmall,a.small,a.medium,a.large],rounded:[L.undefined,L.none,L.small,L.medium,L.large,L.full],fillMode:[A.undefined,A.solid,A.flat,A.outline,A.clear,A.link],themeColor:[n.undefined,n.base,n.primary,n.secondary,n.tertiary,n.success,n.warning,n.error,n.info,n.inverse]},he={showArrow:!1,arrowIconName:"chevron-down"},m=e=>{let{as:t="button",size:o,rounded:s,fillMode:r,themeColor:u,showArrow:i=he.showArrow,arrowIconName:c=he.arrowIconName,variant:h,hover:x,focus:d,active:f,selected:b,disabled:R,togglable:D,ariaDisabled:B,icon:v,iconSize:w,text:W,iconClassName:It,className:vt,...kt}=e,gt=v!=null,Et=e.children!==void 0;return(0,O.jsxs)(t,{className:l(vt,re,He(re,h),H(re,{size:o,rounded:s,fillMode:r,themeColor:u}),J(re,{hover:x,focus:d,active:f,disabled:R||B,selected:b}),{"k-icon-button":!W&&!Et&&gt}),"aria-pressed":D?b?"true":"false":void 0,...kt,"aria-disabled":B?"true":void 0,disabled:R||void 0,children:[typeof v=="string"&&v&&(0,O.jsx)(M,{className:l(It,"k-button-icon"),icon:v,size:w}),v&&typeof v!="string"&&(0,O.jsx)(O.Fragment,{children:v}),W?(0,O.jsxs)(O.Fragment,{children:[W&&(0,O.jsx)("span",{className:"k-button-text",children:W}),e.children]}):e.children&&(0,O.jsx)("span",{className:"k-button-text",children:e.children}),i&&(0,O.jsx)("span",{className:"k-menu-button-arrow k-button-arrow",children:(0,O.jsx)(M,{icon:c})})]})};m.states=Ft;m.options=$t;m.variants=Ht;m.className=re;m.defaultOptions=he;m.moduleName=Me;m.folderName=Je;m.ariaSpec={selector:".k-button",rules:[{selector:".k-button",attribute:"role=button or nodeName=button",usage:"The button role is implicit from the native <button> element."},{selector:".k-button",attribute:"aria-label (when icon-only)",usage:"Required for icon-only buttons that have no visible text."},{selector:".k-button",attribute:"aria-pressed (when togglable)",usage:"Indicates the pressed state of a toggle button."},{selector:".k-button",attribute:"disabled (when disabled)",usage:"Rendered when the button is disabled."}]};var Qe=require("react/jsx-runtime"),qe=e=>(0,Qe.jsx)(m,{icon:"folder",...e,"aria-label":e["aria-label"]||"Folder",children:void 0});var Ze=require("react/jsx-runtime"),Ye=e=>(0,Ze.jsx)(m,{icon:"folder",children:"Button",...e});var et=require("react/jsx-runtime"),je=e=>(0,et.jsx)(m,{children:"Button",...e});var ue=require("react/jsx-runtime"),Vt=m.options,Xt=m.states,Wt={...m.defaultOptions,variant:"text"},Gt=[{name:"icon-only",title:"Icon Only"},{name:"icon-and-text",title:"Icon & Text"},{name:"text",title:"Text"}],Jt=[],Y=e=>{let{variant:t,...o}=e;switch(t){case"icon-only":return(0,ue.jsx)(qe,{...o,icon:"star"});case"icon-and-text":return(0,ue.jsx)(Ye,{...o,icon:"star",children:"Button"});default:return(0,ue.jsx)(je,{...o,children:"Button"})}};Y.options=Vt;Y.states=Xt;Y.variants=Gt;Y.defaultOptions=Wt;Y.modifiers=Jt;Y.className=m.className;var Ne="menu-button",tt=Ne;var nt=require("react/jsx-runtime"),ot="k-menu-button",qt=[p.hover,p.focus,p.active,p.selected,p.disabled],Qt={size:[a.undefined,a.xsmall,a.small,a.medium,a.large],rounded:[L.undefined,L.none,L.small,L.medium,L.large,L.full],fillMode:[A.undefined,A.solid,A.flat,A.outline,A.clear,A.link],themeColor:[n.undefined,n.base,n.primary,n.secondary,n.tertiary,n.success,n.warning,n.error,n.info,n.inverse]},Ie={showArrow:!0,arrowIconName:"chevron-down"},y=e=>{let{size:t,rounded:o,fillMode:s,themeColor:r,hover:u,focus:i,active:c,selected:h,disabled:x,icon:d,text:f,showArrow:b=Ie.showArrow,arrowIconName:R=Ie.arrowIconName,expanded:D,...B}=e;return(0,nt.jsx)(m,{...B,className:l(e.className,ot),text:f,size:t,rounded:o,fillMode:s,themeColor:r,hover:u,focus:i,active:c,selected:h,disabled:x,ariaDisabled:x||void 0,icon:d,showArrow:b,arrowIconName:R,"aria-expanded":D?"true":"false",...!f&&d&&!e["aria-label"]&&{"aria-label":"Menu"}})};y.states=qt;y.options=Qt;y.className=ot;y.defaultOptions=Ie;y.moduleName=Ne;y.folderName=tt;y.ariaSpec={selector:".k-menu-button",rules:[{selector:".k-menu-button",attribute:"role=button or nodeName=button",usage:"Omitted if the button DOM element is used."},{selector:".k-menu-button",attribute:"aria-label (when icon-only)",usage:"Required when no text is visible in the button."},{selector:".k-menu-button",attribute:"aria-expanded=true/false",usage:"Announces the state of the popup visibility."},{selector:".k-menu-button",attribute:"aria-controls=.k-menu-group id (when open)",usage:"Points to the popup element. Builds a relationship between the button and the popup."},{selector:".k-menu-button.k-disabled",attribute:"aria-disabled=true",usage:"Rendered only when the button is disabled."},{selector:".k-menu-group",attribute:"role=list",usage:"Announces the list role of the popup."},{selector:".k-menu-item",attribute:"role=listitem",usage:"Announces the listitem role of the popup items."}]};var Yt=require("react/jsx-runtime");var Zt=require("react/jsx-runtime");var jt=require("react/jsx-runtime");var S="menu",C=S;var $=require("react/jsx-runtime"),ve="k-menu-item",eo=[p.hover,p.focus,p.active,p.selected,p.disabled],to={},rt={iconPosition:"before"},k=e=>{let{hover:t,focus:o,active:s,selected:r,disabled:u,icon:i,text:c,first:h,last:x,showArrow:d,arrowIconName:f,iconPosition:b=rt.iconPosition,dir:R,children:D,expanded:B,...v}=e,w=f;return w||(w=R==="rtl"?"chevron-left":"chevron-right"),(0,$.jsxs)("li",{...v,className:l(e.className,ve,"k-item",J(ve,{focus:o,disabled:u,hover:t,active:s,selected:r}),{"k-first":h,"k-last":x}),role:"menuitem",...d&&{"aria-haspopup":"menu"},...d&&{"aria-expanded":B?"true":"false"},...u&&{"aria-disabled":"true"},...o&&{tabIndex:0},children:[(0,$.jsxs)("span",{className:l("k-link k-menu-link"),children:[i&&b==="before"&&(0,$.jsx)(M,{className:"k-menu-link-icon",icon:i}),(0,$.jsx)("span",{className:"k-menu-link-text",children:c}),i&&b==="after"&&(0,$.jsx)(M,{className:"k-menu-link-icon",icon:i}),d&&(0,$.jsx)("span",{className:"k-menu-expand-arrow","aria-hidden":"true",children:(0,$.jsx)(M,{icon:w})})]}),D]})};k.states=eo;k.options=to;k.className=ve;k.defaultOptions=rt;k.moduleName=S;k.folderName=C;var V=require("react/jsx-runtime"),ke="k-menu-item",oo=[p.hover,p.focus,p.active,p.selected,p.disabled],no={},ge={dir:"ltr",iconPosition:"before"},g=e=>{let{hover:t,focus:o,active:s,selected:r,disabled:u,icon:i,text:c,first:h,last:x,showArrow:d,arrowIconName:f,iconPosition:b=ge.iconPosition,dir:R=ge.dir,children:D,popup:B,expanded:v,...w}=e,W=f;return W||(W=R==="rtl"?"chevron-left":"chevron-right"),(0,V.jsxs)("li",{role:"menuitem",...w,className:l(e.className,ke,"k-item",J(ke,{focus:o,disabled:u}),{"k-first":h,"k-last":x}),...d&&{"aria-haspopup":"menu"},...d&&{"aria-expanded":v?"true":"false"},...u&&{"aria-disabled":"true"},...o&&{tabIndex:0},children:[(0,V.jsxs)("span",{className:l("k-link k-menu-link",J("k-menu-link",{hover:t,active:s,selected:r,disabled:u})),children:[i&&b==="before"&&(0,V.jsx)(M,{className:"k-menu-link-icon",icon:i}),(0,V.jsx)("span",{className:"k-menu-link-text",children:c}),i&&b==="after"&&(0,V.jsx)(M,{className:"k-menu-link-icon",icon:i}),d&&(0,V.jsx)("span",{className:"k-menu-expand-arrow","aria-hidden":"true",children:(0,V.jsx)(M,{icon:W})})]}),D,B]})};g.states=oo;g.options=no;g.className=ke;g.defaultOptions=ge;g.moduleName=S;g.folderName=C;var it=require("react/jsx-runtime"),st="k-menu-scroll-wrapper",ro=[],so={},ao={},Q=e=>{let{className:t,children:o,orientation:s,...r}=e;return(0,it.jsx)("div",{...r,className:l(t,st,{"k-menu-scroll-wrapper-vertical":s==="vertical"}),children:o})};Q.states=ro;Q.options=so;Q.className=st;Q.defaultOptions=ao;Q.moduleName=S;Q.folderName=C;var at=Q;var I=require("react/jsx-runtime"),Ee="k-menu",io=[],lo={},ce={orientation:"horizontal",header:!0,scrollButtonsPosition:"around"},N=e=>{let{children:t,orientation:o=ce.orientation,header:s=ce.header,scrollable:r,scrollButtonsPosition:u=ce.scrollButtonsPosition,wrapperStyles:i,dir:c,popup:h,contextMenu:x,...d}=e,f={horizontal:{prev:c!=="rtl"?"left":"right",next:c!=="rtl"?"right":"left"},vertical:{prev:"up",next:"down"}},b=(0,I.jsx)("ul",{dir:c,...d,className:l(e.className,"k-reset",Ee,{[`${Ee}-${o}`]:o,"k-header":s}),role:x?"menu":"menubar",...o==="vertical"&&{"aria-orientation":"vertical"},children:t});return(0,I.jsxs)(I.Fragment,{children:[r?(0,I.jsxs)(at,{orientation:o,style:i,dir:e.dir,children:[u==="start"&&(0,I.jsxs)(I.Fragment,{children:[(0,I.jsx)(m,{fillMode:"flat",icon:`chevron-${f[o].prev}`,className:"k-menu-scroll-button k-menu-scroll-button-prev",tabIndex:-1,"aria-label":"Scroll previous"}),(0,I.jsx)(m,{fillMode:"flat",icon:`chevron-${f[o].next}`,className:"k-menu-scroll-button k-menu-scroll-button-next",tabIndex:-1,"aria-label":"Scroll next"})]}),u==="around"&&(0,I.jsx)(m,{fillMode:"flat",icon:`chevron-${f[o].prev}`,className:"k-menu-scroll-button k-menu-scroll-button-prev",tabIndex:-1,"aria-label":"Scroll previous"}),b,u==="end"&&(0,I.jsxs)(I.Fragment,{children:[(0,I.jsx)(m,{fillMode:"flat",icon:`chevron-${f[o].prev}`,className:"k-menu-scroll-button k-menu-scroll-button-prev",tabIndex:-1,"aria-label":"Scroll previous"}),(0,I.jsx)(m,{fillMode:"flat",icon:`chevron-${f[o].next}`,className:"k-menu-scroll-button k-menu-scroll-button-next",tabIndex:-1,"aria-label":"Scroll next"})]}),u==="around"&&(0,I.jsx)(m,{fillMode:"flat",icon:`chevron-${f[o].next}`,className:"k-menu-scroll-button k-menu-scroll-button-next",tabIndex:-1,"aria-label":"Scroll next"})]}):b,h]})};N.states=io;N.options=lo;N.className=Ee;N.defaultOptions=ce;N.moduleName=S;N.folderName=C;N.ariaSpec={selector:".k-menu",rules:[{selector:".k-menu:not(.k-context-menu)",attribute:"role=menubar",usage:"Announces the Menu menubar role."},{selector:".k-menu.k-menu-vertical",attribute:"aria-orientation=vertical",usage:"Announces the Menu orientation when vertical."},{selector:".k-menu-item",attribute:"role=menuitem",usage:"Announces the Menu item role."},{selector:".k-menu-item",attribute:"aria-haspopup=menu (when present)",usage:"Indicates a popup menu is associated with the item."},{selector:".k-menu-item",attribute:"aria-expanded=true/false (when present)",usage:"Indicates whether the submenu is expanded."},{selector:".k-menu-item.k-disabled",attribute:"aria-disabled=true",usage:"Informs assistive technologies that a Menu item is disabled."},{selector:".k-menu-expand-arrow",attribute:"aria-hidden=true",usage:"Expand arrow elements are hidden from assistive technologies."},{selector:".k-menu-popup .k-menu-group",attribute:"role=menu",usage:"The role of the nested menu displayed in a popup."},{selector:".k-menu-scroll-button",attribute:"tabindex=-1",usage:"Scroll buttons are removed from the tab sequence."},{selector:".k-menu-scroll-button",attribute:"aria-label",usage:"Scroll buttons have an accessible label."},{selector:".k-menu-item.k-focus",attribute:"tabindex=0",usage:"The focused item has tabindex 0."},{selector:".k-menu-item",attribute:"aria-controls=ul.k-menu-group id (when present)",usage:"Points to the ID of the submenu. Only present when the item controls a submenu element."},{selector:".k-menu-popup .k-menu-group",attribute:"id",usage:"Each nested menu has a deterministic id linked to the parent aria-controls."}]};var ut=require("react/jsx-runtime"),Le="k-separator",lt={orientation:"horizontal"},Z=e=>{let{orientation:t=lt.orientation,...o}=e;return(0,ut.jsx)("li",{...o,className:l(e.className,"k-item",Le,{[`${Le}-${t}`]:t}),role:"separator"})};Z.className=Le;Z.defaultOptions=lt;Z.moduleName=S;Z.folderName=C;var mt=require("react/jsx-runtime");var ct=require("react/jsx-runtime"),Ae="k-menu-group",uo=[],mo={size:[a.undefined,a.small,a.medium,a.large]},co={},_=e=>{let{children:t,size:o,...s}=e;return(0,ct.jsx)("ul",{role:"menu",...s,className:l(e.className,Ae,H(Ae,{size:o})),children:t})};_.states=uo;_.options=mo;_.className=Ae;_.defaultOptions=co;_.moduleName=S;_.folderName=C;var P=require("react/jsx-runtime"),ye=e=>(0,P.jsx)(N,{children:(0,P.jsxs)(P.Fragment,{children:[(0,P.jsx)(k,{first:!0,text:"Item 1"}),(0,P.jsx)(k,{showArrow:!0,arrowIconName:"chevron-down",text:"Item 2"}),(0,P.jsx)(k,{showArrow:!0,arrowIconName:"chevron-down",text:"Item 3"}),(0,P.jsx)(k,{text:"Item 4"}),(0,P.jsx)(k,{last:!0,text:"Item 5"})]}),...e});var we="popup",pt=we;var Se=require("react/jsx-runtime"),dt="k-animation-container",po=[],fo={},Oe={positionMode:"absolute",shown:!0},G=e=>{let{positionMode:t=Oe.positionMode,shown:o=Oe.shown,animationStyle:s,offset:r,...u}=e;return(0,Se.jsx)("div",{...u,style:{...r,...e.style},className:l(e.className,dt,{"k-animation-container-shown":o,"k-animation-container-fixed":t==="fixed"}),children:(0,Se.jsx)("div",{className:"k-child-animation-container",style:s,children:e.children})})};G.states=po;G.options=fo;G.className=dt;G.defaultOptions=Oe;G.moduleName=we;G.folderName=pt;var Te="popup",ft=Te;var Be=require("react/jsx-runtime"),bt="k-popup",bo=[],xo={},xt={positionMode:"absolute"},T=e=>{let{offset:t,positionMode:o=xt.positionMode,animationStyle:s,containerClassName:r,containerRole:u,containerAriaLabel:i,...c}=e;return(0,Be.jsx)(G,{positionMode:o,offset:t,animationStyle:s,className:r,role:u,"aria-label":i,children:(0,Be.jsx)("div",{...c,className:l(e.className,bt),children:e.children})})};T.states=bo;T.options=xo;T.className=bt;T.defaultOptions=xt;T.moduleName=Te;T.folderName=ft;T.ariaSpec={selector:".k-popup",rules:[{selector:".k-animation-container",attribute:"role (when appended to body)",usage:'Container gets role="region" when appended to document body. Popup is a building block \u2014 ARIA semantics come from consuming components.'}]};var Ce=require("react/jsx-runtime");var _e=require("react/jsx-runtime");var Pe=require("react/jsx-runtime");var Re=require("react/jsx-runtime");var z=require("react/jsx-runtime"),Mo={...N.options,scrollable:{type:"boolean"}},ho=N.states,Mt={...N.defaultOptions,variant:"horizontal"},No=[{name:"horizontal",title:"Horizontal"},{name:"vertical",title:"Vertical"}],Io=[{name:"opened",title:"Opened"}],j=e=>{let{variant:t,modifiers:o,...s}={...Mt,...e},r={},u=t==="vertical"?{left:"200px",top:"30px"}:{left:"90px",top:"auto"};return Object.keys(o||{}).forEach(i=>{i==="opened"&&(r.opened=!!(o!=null&&o[i]),r.popup=o!=null&&o[i]?(0,z.jsx)(T,{className:"k-menu-popup",offset:u,children:(0,z.jsxs)(_,{children:[(0,z.jsx)(g,{text:"Item 1"}),(0,z.jsx)(g,{text:"Item 2"}),(0,z.jsx)(Z,{}),(0,z.jsx)(g,{text:"Item 3"})]})}):null)}),t==="vertical"?(0,z.jsx)(ye,{...s,...r,orientation:"vertical",style:{width:"200px"}}):(0,z.jsx)(ye,{...s,...r})};j.options=Mo;j.states=ho;j.variants=No;j.defaultOptions=Mt;j.modifiers=Io;j.className=N.className;var Ke=require("react/jsx-runtime");var vo=require("react/jsx-runtime");var E=require("react/jsx-runtime"),ko=m.states,ht={...m.defaultOptions,variant:"text"},go=m.options,Eo=[{name:"icon-only",title:"Icon Only"},{name:"icon-and-text",title:"Icon & Text"},{name:"text",title:"Text"}],Lo=[{name:"opened",title:"Opened"}],ee=e=>{let{variant:t,modifiers:o,...s}={...ht,...e},r={},u=(0,E.jsx)(T,{className:"k-menu-popup",children:(0,E.jsxs)(_,{size:s.size,children:[(0,E.jsx)(g,{first:!0,text:"Menu Item"}),(0,E.jsx)(g,{text:"Menu Item"}),(0,E.jsx)(g,{last:!0,text:"Menu Item"})]})}),i;switch(t){case"icon-only":i=(0,E.jsx)("div",{children:(0,E.jsx)(y,{...s,...r,icon:"star"})});break;case"icon-and-text":i=(0,E.jsx)("div",{children:(0,E.jsx)(y,{...s,...r,icon:"star",children:"Dropdown Button"})});break;default:i=(0,E.jsx)("div",{children:(0,E.jsx)(y,{...s,...r,children:"Dropdown Button"})});break}return(0,E.jsxs)(E.Fragment,{children:[i,(o==null?void 0:o.opened)&&u]})};ee.options=go;ee.states=ko;ee.variants=Eo;ee.defaultOptions=ht;ee.modifiers=Lo;ee.className=y.className;var ze="file-box",Nt=ze;var U=require("react/jsx-runtime"),Ue="k-file-box",Ao=[p.selected],yo={},se={icon:"file-pdf",name:"FileName.pdf",size:"2MB",showButton:"true"},X=e=>{let{icon:t=se.icon,name:o=se.name,size:s=se.size,status:r,deleted:u,removeButton:i,showButton:c=se.showButton,...h}=e,x=[o,s].filter(Boolean).join(" ");return(0,U.jsxs)("li",{role:"listitem",tabIndex:0,"aria-label":x||void 0,...h,className:l(Ue,e.className,{"k-file-deleted":u}),children:[(0,U.jsx)(M,{icon:t,size:"xlarge","aria-hidden":"true"}),(0,U.jsxs)("div",{className:"k-file-info",children:[o&&(0,U.jsx)("span",{className:"k-file-name",children:o}),s&&(0,U.jsx)("span",{className:"k-file-size",children:s}),r&&(0,U.jsx)("span",{className:"k-file-status",children:r})]}),c&&(i?(0,U.jsx)(m,{as:"span",icon:"x-circle",fillMode:"flat",size:"xsmall","aria-hidden":"true"}):(0,U.jsx)(y,{icon:"more-vertical",fillMode:"flat",size:"xsmall",showArrow:!1,"aria-label":"File actions"}))]})};X.states=Ao;X.options=yo;X.className=Ue;X.defaultOptions=se;X.moduleName=ze;X.folderName=Nt;X.ariaSpec={selector:".k-file-box-wrapper",rules:[{selector:".k-file-box-wrapper",attribute:"role=list",usage:"Explicitly sets the UL role to list."},{selector:".k-file-box-wrapper",attribute:"aria-label",usage:'Provides an accessible name for the file list (e.g. "Attached files").'},{selector:".k-file-box-wrapper .k-files-scroll",attribute:"role=presentation",usage:"The scrollable container between the list and its items is presentational, ensuring the list\u2192listitem relationship is preserved in the accessibility tree."},{selector:".k-file-box-wrapper .k-file-box",attribute:"role=listitem",usage:"Explicitly sets the LI role to listitem."},{selector:".k-file-box-wrapper .k-file-box",attribute:"tabindex",usage:"Makes the file box focusable. Uses roving tabindex: 0 for the focused item, -1 for the rest."},{selector:".k-file-box-wrapper .k-file-box",attribute:"aria-label",usage:'Provides an accessible name describing the file. Can include the file name and size (e.g. "FileName.pdf 2MB").'},{selector:".k-file-box-wrapper .k-file-box .k-icon",attribute:"aria-hidden=true",usage:"The file type icon is decorative and hidden from screen readers."},{selector:".k-file-box-wrapper .k-file-box span.k-button",attribute:"aria-hidden=true",usage:"The remove button is rendered as a decorative span and hidden from screen readers. File removal is handled by keyboard interaction on the listitem itself."}]};var wo=X;