@progress/kendo-themes-html
Version:
A collection of HTML helpers used for developing Kendo UI themes
2 lines (1 loc) • 25 kB
JavaScript
var Dt=Object.create;var ue=Object.defineProperty;var Ut=Object.getOwnPropertyDescriptor;var zt=Object.getOwnPropertyNames;var Ht=Object.getPrototypeOf,Wt=Object.prototype.hasOwnProperty;var $t=(e,t)=>{for(var o in t)ue(e,o,{get:t[o],enumerable:!0})},Ge=(e,t,o,s)=>{if(t&&typeof t=="object"||typeof t=="function")for(let r of zt(t))!Wt.call(e,r)&&r!==o&&ue(e,r,{get:()=>t[r],enumerable:!(s=Ut(t,r))||s.enumerable});return e};var Ft=(e,t,o)=>(o=e!=null?Dt(Ht(e)):{},Ge(t||!e||!e.__esModule?ue(o,"default",{value:e,enumerable:!0}):o,e)),Vt=e=>Ge(ue({},"__esModule",{value:!0}),e);var Zo={};$t(Zo,{WindowDemo:()=>Y,default:()=>Yo});module.exports=Vt(Zo);var i=(...e)=>e.filter(t=>t!==!0&&!!t).map(t=>Array.isArray(t)?i(...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 W=(e,t)=>i({[`${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"}),Z=(e,t)=>{let{valid:o,invalid:s,hover:r,focus:u,checked:l,active:c,selected:p,disabled:b,indeterminate:f,loading:M,empty:x,readonly:D,highlighted:H,...B}=t;return i({"k-valid":o,"k-invalid":s,"k-hover":r,"k-focus":u,"k-checked":l,"k-active":c,"k-selected":p,"k-disabled":b,"k-indeterminate":f&&!l,"k-loading":M,"k-empty":x,"k-readonly":D,"k-highlighted":H},Object.keys(B).reduce((v,O)=>(O.startsWith("k-")?v[O]=B[O]:v[`k-${O}`]=B[O],v),{}))};function Qe(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"},w={undefined:void 0,none:"none",small:"small",medium:"medium",large:"large",full:"full"},E={undefined:void 0,solid:"solid",flat:"flat",outline:"outline",clear:"clear",link:"link"},U={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"},d={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 Ne={};function he(e){return Ne[e]=(Ne[e]||0)+1,`k-${e}-${Ne[e]}`}var Ie="action-buttons",Ye=Ie;var Ze=require("react/jsx-runtime"),ce="k-actions",qt=[],Jt={},ve={alignment:"start",orientation:"horizontal"},J=e=>{let{alignment:t=ve.alignment,orientation:o=ve.orientation,...s}=e;return(0,Ze.jsx)("div",{...s,className:i(ce,{[`${ce}-${t}`]:t,[`${ce}-${o}`]:o},e.className),children:e.children})};J.states=qt;J.options=Jt;J.className=ce;J.defaultOptions=ve;J.moduleName=Ie;J.folderName=Ye;var se=require("react/jsx-runtime"),ge="k-font-icon",Xt=[],Gt={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]},Qt={},ie=e=>{let{size:t,themeColor:o,icon:s,rotate:r,flip:u,...l}=e;return s?(0,se.jsx)("span",{...l,className:i(e.className,ge,W(ge,{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,se.jsx)(se.Fragment,{})};ie.states=Xt;ie.options=Gt;ie.className=ge;ie.defaultOptions=Qt;var je=ie;var j=require("react/jsx-runtime"),Ae="k-svg-icon",Yt=[],Zt={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:[U.outline,U.solid,U.duotone]},ke={viewBox:"0 0 24 24",variant:U.outline},ae=e=>{var M,x;let{size:t,themeColor:o,rotate:s,flip:r,viewBox:u=ke.viewBox,variant:l=ke.variant,icon:c,...p}=e;if(!c)return(0,j.jsx)(j.Fragment,{});if(c==="none")return(0,j.jsx)("span",{...p,className:i(e.className,Ae,W("k-icon",{size:t}),"k-none"),"aria-hidden":"true"});let b=typeof c=="object"&&c.name&&c.name,f=typeof c=="object"?l&&((M=c.variants)==null?void 0:M[l])||((x=c.variants)==null?void 0:x.outline)||c.content:void 0;return(0,j.jsx)("span",{...p,className:i(e.className,Ae,W("k-icon",{size:t}),{[`k-svg-i-${b}`]:b,[`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,j.jsx)("svg",{"aria-hidden":!0,focusable:!1,xmlns:"http://www.w3.org/2000/svg",viewBox:typeof c=="object"?c.viewBox:u,dangerouslySetInnerHTML:f!==void 0?{__html:f}:void 0,children:c?void 0:e.children})})};ae.states=Yt;ae.options=Zt;ae.className=Ae;ae.defaultOptions=ke;var we=ae;var Ee=Ft(require("@progress/kendo-svg-icons"));var et="icon",tt="icons";var rt=require("react");var ot=require("react"),nt=(0,ot.createContext)({iconsType:"svg"});var $=require("react/jsx-runtime"),de="k-icon",jt=e=>e.replace(/([-_][a-z0-9])/gi,t=>t.toUpperCase().replace("-","").replace("_","")),eo=[],to={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:[U.outline,U.solid,U.duotone]},pe={viewBox:"0 0 24 24",type:"svg",variant:U.outline},N=e=>{let{iconsType:t}=(0,rt.useContext)(nt),{size:o,themeColor:s,icon:r,type:u=t||pe.type,rotate:l,flip:c,viewBox:p=pe.viewBox,variant:b=pe.variant,...f}=e;if(!r)return(0,$.jsx)($.Fragment,{});if((t||u)==="svg"){if(r==="none")return(0,$.jsx)(we,{...f,className:i(e.className,de),icon:r,size:o,variant:b});let x=Ee[r]?r:jt(`${r}-icon`);return Ee[x]?(0,$.jsx)(we,{...f,className:i(e.className,de),icon:Ee[x],size:o,themeColor:s,rotate:l,flip:c,viewBox:p,variant:b}):(0,$.jsx)($.Fragment,{})}return(0,$.jsx)(je,{...f,className:i(e.className,de),icon:r,size:o,themeColor:s,rotate:l,flip:c})};N.states=eo;N.options=to;N.defaultOptions=pe;N.className=de;N.moduleName=et;N.folderName=tt;N.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 Le="button",st=Le;var y=require("react/jsx-runtime"),le="k-button",oo=["icon-button"],no=[d.hover,d.focus,d.active,d.selected,d.disabled,d.generating],ro={size:[a.undefined,a.xsmall,a.small,a.medium,a.large],rounded:[w.undefined,w.none,w.small,w.medium,w.large,w.full],fillMode:[E.undefined,E.solid,E.flat,E.outline,E.clear,E.link],themeColor:[n.undefined,n.base,n.primary,n.secondary,n.tertiary,n.success,n.warning,n.error,n.info,n.inverse]},Oe={showArrow:!1,arrowIconName:"chevron-down"},m=e=>{let{as:t="button",size:o,rounded:s,fillMode:r,themeColor:u,showArrow:l=Oe.showArrow,arrowIconName:c=Oe.arrowIconName,variant:p,hover:b,focus:f,active:M,selected:x,disabled:D,togglable:H,ariaDisabled:B,icon:v,iconSize:O,text:q,iconClassName:_t,className:Bt,...Pt}=e,Kt=v!=null,Rt=e.children!==void 0;return(0,y.jsxs)(t,{className:i(Bt,le,Qe(le,p),W(le,{size:o,rounded:s,fillMode:r,themeColor:u}),Z(le,{hover:b,focus:f,active:M,disabled:D||B,selected:x}),{"k-icon-button":!q&&!Rt&&Kt}),"aria-pressed":H?x?"true":"false":void 0,...Pt,"aria-disabled":B?"true":void 0,disabled:D||void 0,children:[typeof v=="string"&&v&&(0,y.jsx)(N,{className:i(_t,"k-button-icon"),icon:v,size:O}),v&&typeof v!="string"&&(0,y.jsx)(y.Fragment,{children:v}),q?(0,y.jsxs)(y.Fragment,{children:[q&&(0,y.jsx)("span",{className:"k-button-text",children:q}),e.children]}):e.children&&(0,y.jsx)("span",{className:"k-button-text",children:e.children}),l&&(0,y.jsx)("span",{className:"k-menu-button-arrow k-button-arrow",children:(0,y.jsx)(N,{icon:c})})]})};m.states=no;m.options=ro;m.variants=oo;m.className=le;m.defaultOptions=Oe;m.moduleName=Le;m.folderName=st;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 at=require("react/jsx-runtime"),it=e=>(0,at.jsx)(m,{icon:"folder",...e,"aria-label":e["aria-label"]||"Folder",children:void 0});var mt=require("react/jsx-runtime"),lt=e=>(0,mt.jsx)(m,{icon:"folder",children:"Button",...e});var ct=require("react/jsx-runtime"),ut=e=>(0,ct.jsx)(m,{children:"Button",...e});var fe=require("react/jsx-runtime"),so=m.options,io=m.states,ao={...m.defaultOptions,variant:"text"},lo=[{name:"icon-only",title:"Icon Only"},{name:"icon-and-text",title:"Icon & Text"},{name:"text",title:"Text"}],mo=[],te=e=>{let{variant:t,...o}=e;switch(t){case"icon-only":return(0,fe.jsx)(it,{...o,icon:"star"});case"icon-and-text":return(0,fe.jsx)(lt,{...o,icon:"star",children:"Button"});default:return(0,fe.jsx)(ut,{...o,children:"Button"})}};te.options=so;te.states=io;te.variants=lo;te.defaultOptions=ao;te.modifiers=mo;te.className=m.className;var ye="menu-button",dt=ye;var ft=require("react/jsx-runtime"),pt="k-menu-button",uo=[d.hover,d.focus,d.active,d.selected,d.disabled],co={size:[a.undefined,a.xsmall,a.small,a.medium,a.large],rounded:[w.undefined,w.none,w.small,w.medium,w.large,w.full],fillMode:[E.undefined,E.solid,E.flat,E.outline,E.clear,E.link],themeColor:[n.undefined,n.base,n.primary,n.secondary,n.tertiary,n.success,n.warning,n.error,n.info,n.inverse]},Te={showArrow:!0,arrowIconName:"chevron-down"},L=e=>{let{size:t,rounded:o,fillMode:s,themeColor:r,hover:u,focus:l,active:c,selected:p,disabled:b,icon:f,text:M,showArrow:x=Te.showArrow,arrowIconName:D=Te.arrowIconName,expanded:H,...B}=e;return(0,ft.jsx)(m,{...B,className:i(e.className,pt),text:M,size:t,rounded:o,fillMode:s,themeColor:r,hover:u,focus:l,active:c,selected:p,disabled:b,ariaDisabled:b||void 0,icon:f,showArrow:x,arrowIconName:D,"aria-expanded":H?"true":"false",...!M&&f&&!e["aria-label"]&&{"aria-label":"Menu"}})};L.states=uo;L.options=co;L.className=pt;L.defaultOptions=Te;L.moduleName=ye;L.folderName=dt;L.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 po=require("react/jsx-runtime");var fo=require("react/jsx-runtime");var Mo=require("react/jsx-runtime");var T="menu",P=T;var F=require("react/jsx-runtime"),Se="k-menu-item",xo=[d.hover,d.focus,d.active,d.selected,d.disabled],bo={},Mt={iconPosition:"before"},g=e=>{let{hover:t,focus:o,active:s,selected:r,disabled:u,icon:l,text:c,first:p,last:b,showArrow:f,arrowIconName:M,iconPosition:x=Mt.iconPosition,dir:D,children:H,expanded:B,...v}=e,O=M;return O||(O=D==="rtl"?"chevron-left":"chevron-right"),(0,F.jsxs)("li",{...v,className:i(e.className,Se,"k-item",Z(Se,{focus:o,disabled:u,hover:t,active:s,selected:r}),{"k-first":p,"k-last":b}),role:"menuitem",...f&&{"aria-haspopup":"menu"},...f&&{"aria-expanded":B?"true":"false"},...u&&{"aria-disabled":"true"},...o&&{tabIndex:0},children:[(0,F.jsxs)("span",{className:i("k-link k-menu-link"),children:[l&&x==="before"&&(0,F.jsx)(N,{className:"k-menu-link-icon",icon:l}),(0,F.jsx)("span",{className:"k-menu-link-text",children:c}),l&&x==="after"&&(0,F.jsx)(N,{className:"k-menu-link-icon",icon:l}),f&&(0,F.jsx)("span",{className:"k-menu-expand-arrow","aria-hidden":"true",children:(0,F.jsx)(N,{icon:O})})]}),H]})};g.states=xo;g.options=bo;g.className=Se;g.defaultOptions=Mt;g.moduleName=T;g.folderName=P;var V=require("react/jsx-runtime"),Ce="k-menu-item",No=[d.hover,d.focus,d.active,d.selected,d.disabled],ho={},_e={dir:"ltr",iconPosition:"before"},A=e=>{let{hover:t,focus:o,active:s,selected:r,disabled:u,icon:l,text:c,first:p,last:b,showArrow:f,arrowIconName:M,iconPosition:x=_e.iconPosition,dir:D=_e.dir,children:H,popup:B,expanded:v,...O}=e,q=M;return q||(q=D==="rtl"?"chevron-left":"chevron-right"),(0,V.jsxs)("li",{role:"menuitem",...O,className:i(e.className,Ce,"k-item",Z(Ce,{focus:o,disabled:u}),{"k-first":p,"k-last":b}),...f&&{"aria-haspopup":"menu"},...f&&{"aria-expanded":v?"true":"false"},...u&&{"aria-disabled":"true"},...o&&{tabIndex:0},children:[(0,V.jsxs)("span",{className:i("k-link k-menu-link",Z("k-menu-link",{hover:t,active:s,selected:r,disabled:u})),children:[l&&x==="before"&&(0,V.jsx)(N,{className:"k-menu-link-icon",icon:l}),(0,V.jsx)("span",{className:"k-menu-link-text",children:c}),l&&x==="after"&&(0,V.jsx)(N,{className:"k-menu-link-icon",icon:l}),f&&(0,V.jsx)("span",{className:"k-menu-expand-arrow","aria-hidden":"true",children:(0,V.jsx)(N,{icon:q})})]}),H,B]})};A.states=No;A.options=ho;A.className=Ce;A.defaultOptions=_e;A.moduleName=T;A.folderName=P;var Nt=require("react/jsx-runtime"),xt="k-menu-scroll-wrapper",Io=[],vo={},go={},ee=e=>{let{className:t,children:o,orientation:s,...r}=e;return(0,Nt.jsx)("div",{...r,className:i(t,xt,{"k-menu-scroll-wrapper-vertical":s==="vertical"}),children:o})};ee.states=Io;ee.options=vo;ee.className=xt;ee.defaultOptions=go;ee.moduleName=T;ee.folderName=P;var bt=ee;var I=require("react/jsx-runtime"),Be="k-menu",Ao=[],ko={},xe={orientation:"horizontal",header:!0,scrollButtonsPosition:"around"},h=e=>{let{children:t,orientation:o=xe.orientation,header:s=xe.header,scrollable:r,scrollButtonsPosition:u=xe.scrollButtonsPosition,wrapperStyles:l,dir:c,popup:p,contextMenu:b,...f}=e,M={horizontal:{prev:c!=="rtl"?"left":"right",next:c!=="rtl"?"right":"left"},vertical:{prev:"up",next:"down"}},x=(0,I.jsx)("ul",{dir:c,...f,className:i(e.className,"k-reset",Be,{[`${Be}-${o}`]:o,"k-header":s}),role:b?"menu":"menubar",...o==="vertical"&&{"aria-orientation":"vertical"},children:t});return(0,I.jsxs)(I.Fragment,{children:[r?(0,I.jsxs)(bt,{orientation:o,style:l,dir:e.dir,children:[u==="start"&&(0,I.jsxs)(I.Fragment,{children:[(0,I.jsx)(m,{fillMode:"flat",icon:`chevron-${M[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-${M[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-${M[o].prev}`,className:"k-menu-scroll-button k-menu-scroll-button-prev",tabIndex:-1,"aria-label":"Scroll previous"}),x,u==="end"&&(0,I.jsxs)(I.Fragment,{children:[(0,I.jsx)(m,{fillMode:"flat",icon:`chevron-${M[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-${M[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-${M[o].next}`,className:"k-menu-scroll-button k-menu-scroll-button-next",tabIndex:-1,"aria-label":"Scroll next"})]}):x,p]})};h.states=Ao;h.options=ko;h.className=Be;h.defaultOptions=xe;h.moduleName=T;h.folderName=P;h.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 It=require("react/jsx-runtime"),Pe="k-separator",ht={orientation:"horizontal"},oe=e=>{let{orientation:t=ht.orientation,...o}=e;return(0,It.jsx)("li",{...o,className:i(e.className,"k-item",Pe,{[`${Pe}-${t}`]:t}),role:"separator"})};oe.className=Pe;oe.defaultOptions=ht;oe.moduleName=T;oe.folderName=P;var vt=require("react/jsx-runtime");var gt=require("react/jsx-runtime"),Ke="k-menu-group",wo=[],Eo={size:[a.undefined,a.small,a.medium,a.large]},Lo={},K=e=>{let{children:t,size:o,...s}=e;return(0,gt.jsx)("ul",{role:"menu",...s,className:i(e.className,Ke,W(Ke,{size:o})),children:t})};K.states=wo;K.options=Eo;K.className=Ke;K.defaultOptions=Lo;K.moduleName=T;K.folderName=P;var R=require("react/jsx-runtime"),Re=e=>(0,R.jsx)(h,{children:(0,R.jsxs)(R.Fragment,{children:[(0,R.jsx)(g,{first:!0,text:"Item 1"}),(0,R.jsx)(g,{showArrow:!0,arrowIconName:"chevron-down",text:"Item 2"}),(0,R.jsx)(g,{showArrow:!0,arrowIconName:"chevron-down",text:"Item 3"}),(0,R.jsx)(g,{text:"Item 4"}),(0,R.jsx)(g,{last:!0,text:"Item 5"})]}),...e});var De="popup",At=De;var ze=require("react/jsx-runtime"),kt="k-animation-container",Oo=[],yo={},Ue={positionMode:"absolute",shown:!0},X=e=>{let{positionMode:t=Ue.positionMode,shown:o=Ue.shown,animationStyle:s,offset:r,...u}=e;return(0,ze.jsx)("div",{...u,style:{...r,...e.style},className:i(e.className,kt,{"k-animation-container-shown":o,"k-animation-container-fixed":t==="fixed"}),children:(0,ze.jsx)("div",{className:"k-child-animation-container",style:s,children:e.children})})};X.states=Oo;X.options=yo;X.className=kt;X.defaultOptions=Ue;X.moduleName=De;X.folderName=At;var He="popup",wt=He;var We=require("react/jsx-runtime"),Et="k-popup",To=[],So={},Lt={positionMode:"absolute"},S=e=>{let{offset:t,positionMode:o=Lt.positionMode,animationStyle:s,containerClassName:r,containerRole:u,containerAriaLabel:l,...c}=e;return(0,We.jsx)(X,{positionMode:o,offset:t,animationStyle:s,className:r,role:u,"aria-label":l,children:(0,We.jsx)("div",{...c,className:i(e.className,Et),children:e.children})})};S.states=To;S.options=So;S.className=Et;S.defaultOptions=Lt;S.moduleName=He;S.folderName=wt;S.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 $e=require("react/jsx-runtime");var Fe=require("react/jsx-runtime");var Ve=require("react/jsx-runtime");var qe=require("react/jsx-runtime");var z=require("react/jsx-runtime"),Co={...h.options,scrollable:{type:"boolean"}},_o=h.states,Ot={...h.defaultOptions,variant:"horizontal"},Bo=[{name:"horizontal",title:"Horizontal"},{name:"vertical",title:"Vertical"}],Po=[{name:"opened",title:"Opened"}],ne=e=>{let{variant:t,modifiers:o,...s}={...Ot,...e},r={},u=t==="vertical"?{left:"200px",top:"30px"}:{left:"90px",top:"auto"};return Object.keys(o||{}).forEach(l=>{l==="opened"&&(r.opened=!!(o!=null&&o[l]),r.popup=o!=null&&o[l]?(0,z.jsx)(S,{className:"k-menu-popup",offset:u,children:(0,z.jsxs)(K,{children:[(0,z.jsx)(A,{text:"Item 1"}),(0,z.jsx)(A,{text:"Item 2"}),(0,z.jsx)(oe,{}),(0,z.jsx)(A,{text:"Item 3"})]})}):null)}),t==="vertical"?(0,z.jsx)(Re,{...s,...r,orientation:"vertical",style:{width:"200px"}}):(0,z.jsx)(Re,{...s,...r})};ne.options=Co;ne.states=_o;ne.variants=Bo;ne.defaultOptions=Ot;ne.modifiers=Po;ne.className=h.className;var Je=require("react/jsx-runtime");var Ko=require("react/jsx-runtime");var k=require("react/jsx-runtime"),Ro=m.states,yt={...m.defaultOptions,variant:"text"},Do=m.options,Uo=[{name:"icon-only",title:"Icon Only"},{name:"icon-and-text",title:"Icon & Text"},{name:"text",title:"Text"}],zo=[{name:"opened",title:"Opened"}],re=e=>{let{variant:t,modifiers:o,...s}={...yt,...e},r={},u=(0,k.jsx)(S,{className:"k-menu-popup",children:(0,k.jsxs)(K,{size:s.size,children:[(0,k.jsx)(A,{first:!0,text:"Menu Item"}),(0,k.jsx)(A,{text:"Menu Item"}),(0,k.jsx)(A,{last:!0,text:"Menu Item"})]})}),l;switch(t){case"icon-only":l=(0,k.jsx)("div",{children:(0,k.jsx)(L,{...s,...r,icon:"star"})});break;case"icon-and-text":l=(0,k.jsx)("div",{children:(0,k.jsx)(L,{...s,...r,icon:"star",children:"Dropdown Button"})});break;default:l=(0,k.jsx)("div",{children:(0,k.jsx)(L,{...s,...r,children:"Dropdown Button"})});break}return(0,k.jsxs)(k.Fragment,{children:[l,(o==null?void 0:o.opened)&&u]})};re.options=Do;re.states=Ro;re.variants=Uo;re.defaultOptions=yt;re.modifiers=zo;re.className=L.className;var me="window",be=me;var St=require("react/jsx-runtime"),Tt="k-window-content",Ho=[],Wo={},$o={},G=e=>{let{children:t,...o}=e;return(0,St.jsx)("div",{...o,className:i(Tt,e.className),children:t})};G.states=Ho;G.options=Wo;G.className=Tt;G.defaultOptions=$o;G.moduleName=me;G.folderName=be;var C=require("react/jsx-runtime"),Xe="k-window",Fo=[],Vo={},qo={},_=e=>{let{title:t,actions:o,minimized:s,actionButtons:r,actionButtonsAlign:u,...l}=e,c=t!==void 0?he("window-title"):void 0;return(0,C.jsxs)("div",{...l,className:i(e.className,Xe,{[`${Xe}-minimized`]:s}),role:"dialog","aria-labelledby":c,children:[(t!==void 0||o)&&(0,C.jsxs)("div",{className:"k-window-titlebar",children:[t!==void 0&&(0,C.jsx)("span",{className:"k-window-title",id:c,children:t}),o&&(0,C.jsx)(C.Fragment,{children:(0,C.jsx)("div",{className:"k-window-titlebar-actions",children:o.map(p=>p==="more-vertical"?(0,C.jsx)(L,{icon:p,fillMode:"flat",size:"xsmall",showArrow:!1,className:"k-window-titlebar-action","aria-label":"More actions"},p):(0,C.jsx)(m,{icon:p,fillMode:"flat",size:"xsmall",className:"k-window-titlebar-action","aria-label":p},p))})})]}),(0,C.jsx)(G,{className:i({"k-hidden":s}),children:e.children}),r&&(0,C.jsx)(J,{alignment:u,className:"k-window-actions",children:r})]})};_.states=Fo;_.options=Vo;_.className=Xe;_.defaultOptions=qo;_.moduleName=me;_.folderName=be;_.ariaSpec={selector:".k-window",rules:[{selector:".k-window:not(.k-dialog)",attribute:"role=dialog",usage:"Announces the dialog role of the component."},{selector:".k-window:not(.k-dialog)",attribute:"aria-labelledby",usage:"Associate the title of the dialog."}]};var Q=require("react/jsx-runtime"),Jo=_.options,Xo=_.states,Ct={..._.defaultOptions,variant:"normal"},Go=[{name:"normal",title:"Normal"},{name:"actions",title:"Actions"}],Qo=[],Y=e=>{let{variant:t,...o}={...Ct,...e};return(0,Q.jsx)(_,{title:"Window",actions:["window-minimize","window","x"],style:{maxWidth:"400px"},actionButtonsAlign:"stretched",actionButtons:t==="actions"?(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(m,{children:"Cancel"}),(0,Q.jsx)(m,{themeColor:"primary",children:"Submit"})]}):void 0,...o,children:"Lorem ipsum dolor sit amet, consectetur adipiscing elit. Ut facilisis hac neque, sapien orci. Dignissim pulvinar commodo lorem pellentesque ornare dictum egestas feugiat fringilla. Proin facilisis mattis sed accumsan orci velit eget."})};Y.options=Jo;Y.states=Xo;Y.variants=Go;Y.defaultOptions=Ct;Y.modifiers=Qo;Y.className=_.className;var Yo=Y;