@progress/kendo-themes-html
Version:
A collection of HTML helpers used for developing Kendo UI themes
2 lines (1 loc) • 21.1 kB
JavaScript
var bt=Object.create;var re=Object.defineProperty;var Nt=Object.getOwnPropertyDescriptor;var It=Object.getOwnPropertyNames;var vt=Object.getPrototypeOf,kt=Object.prototype.hasOwnProperty;var gt=(e,t)=>{for(var o in t)re(e,o,{get:t[o],enumerable:!0})},Pe=(e,t,o,s)=>{if(t&&typeof t=="object"||typeof t=="function")for(let n of It(t))!kt.call(e,n)&&n!==o&&re(e,n,{get:()=>t[n],enumerable:!(s=Nt(t,n))||s.enumerable});return e};var Et=(e,t,o)=>(o=e!=null?bt(vt(e)):{},Pe(t||!e||!e.__esModule?re(o,"default",{value:e,enumerable:!0}):o,e)),At=e=>Pe(re({},"__esModule",{value:!0}),e);var ho={};gt(ho,{ContextMenuDemo:()=>V,default:()=>Mo});module.exports=At(ho);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 R=(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"}),W=(e,t)=>{let{valid:o,invalid:s,hover:n,focus:l,checked:m,active:u,selected:g,disabled:k,indeterminate:d,loading:h,empty:f,readonly:H,highlighted:X,...w}=t;return i({"k-valid":o,"k-invalid":s,"k-hover":n,"k-focus":l,"k-checked":m,"k-active":u,"k-selected":g,"k-disabled":k,"k-indeterminate":d&&!m,"k-loading":h,"k-empty":f,"k-readonly":H,"k-highlighted":X},Object.keys(w).reduce((I,E)=>(E.startsWith("k-")?I[E]=w[E]:I[`k-${E}`]=w[E],I),{}))};function Re(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"},G={undefined:void 0,none:"none",small:"small",medium:"medium",large:"large",full:"full"},J={undefined:void 0,solid:"solid",flat:"flat",outline:"outline",clear:"clear",link:"link"},T={undefined:void 0,outline:"outline",solid:"solid",duotone:"duotone"},r={undefined:void 0,inherit:"inherit",base:"base",primary:"primary",secondary:"secondary",tertiary:"tertiary",info:"info",success:"success",warning:"warning",error:"error",inverse:"inverse"},x={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 j=require("react/jsx-runtime"),me="k-font-icon",Lt=[],yt={size:[a.undefined,a.xsmall,a.small,a.medium,a.large,a.xlarge,a.xxlarge,a.xxxlarge],themeColor:[r.undefined,r.base,r.primary,r.secondary,r.tertiary,r.success,r.warning,r.error,r.info]},Ot={},ee=e=>{let{size:t,themeColor:o,icon:s,rotate:n,flip:l,...m}=e;return s?(0,j.jsx)("span",{...m,className:i(e.className,me,R(me,{size:t}),{[`k-i-${s}`]:s,[`k-color-${o}`]:o,[`k-rotate-${n}`]:n,"k-flip-h":l==="h"||l==="both","k-flip-v":l==="v"||l==="both"}),"aria-hidden":"true"}):(0,j.jsx)(j.Fragment,{})};ee.states=Lt;ee.options=yt;ee.className=me;ee.defaultOptions=Ot;var Ke=ee;var q=require("react/jsx-runtime"),ue="k-svg-icon",St=[],Ct={size:[a.undefined,a.xsmall,a.small,a.medium,a.large,a.xlarge,a.xxlarge,a.xxxlarge],themeColor:[r.undefined,r.base,r.primary,r.secondary,r.tertiary,r.success,r.warning,r.error,r.info],variant:[T.outline,T.solid,T.duotone]},ce={viewBox:"0 0 24 24",variant:T.outline},te=e=>{var h,f;let{size:t,themeColor:o,rotate:s,flip:n,viewBox:l=ce.viewBox,variant:m=ce.variant,icon:u,...g}=e;if(!u)return(0,q.jsx)(q.Fragment,{});if(u==="none")return(0,q.jsx)("span",{...g,className:i(e.className,ue,R("k-icon",{size:t}),"k-none"),"aria-hidden":"true"});let k=typeof u=="object"&&u.name&&u.name,d=typeof u=="object"?m&&((h=u.variants)==null?void 0:h[m])||((f=u.variants)==null?void 0:f.outline)||u.content:void 0;return(0,q.jsx)("span",{...g,className:i(e.className,ue,R("k-icon",{size:t}),{[`k-svg-i-${k}`]:k,[`k-color-${o}`]:o,[`k-rotate-${s}`]:s,"k-flip-h":n==="h"||n==="both","k-flip-v":n==="v"||n==="both"}),"aria-hidden":"true",children:(0,q.jsx)("svg",{"aria-hidden":!0,focusable:!1,xmlns:"http://www.w3.org/2000/svg",viewBox:typeof u=="object"?u.viewBox:l,dangerouslySetInnerHTML:d!==void 0?{__html:d}:void 0,children:u?void 0:e.children})})};te.states=St;te.options=Ct;te.className=ue;te.defaultOptions=ce;var pe=te;var de=Et(require("@progress/kendo-svg-icons"));var Be="icon",Ue="icons";var De=require("react");var He=require("react"),ze=(0,He.createContext)({iconsType:"svg"});var K=require("react/jsx-runtime"),ae="k-icon",wt=e=>e.replace(/([-_][a-z0-9])/gi,t=>t.toUpperCase().replace("-","").replace("_","")),Tt=[],_t={size:[a.undefined,a.xsmall,a.small,a.medium,a.large,a.xlarge,a.xxlarge,a.xxxlarge],themeColor:[r.undefined,r.base,r.primary,r.secondary,r.tertiary,r.success,r.warning,r.error,r.info],variant:[T.outline,T.solid,T.duotone]},se={viewBox:"0 0 24 24",type:"svg",variant:T.outline},b=e=>{let{iconsType:t}=(0,De.useContext)(ze),{size:o,themeColor:s,icon:n,type:l=t||se.type,rotate:m,flip:u,viewBox:g=se.viewBox,variant:k=se.variant,...d}=e;if(!n)return(0,K.jsx)(K.Fragment,{});if((t||l)==="svg"){if(n==="none")return(0,K.jsx)(pe,{...d,className:i(e.className,ae),icon:n,size:o,variant:k});let f=de[n]?n:wt(`${n}-icon`);return de[f]?(0,K.jsx)(pe,{...d,className:i(e.className,ae),icon:de[f],size:o,themeColor:s,rotate:m,flip:u,viewBox:g,variant:k}):(0,K.jsx)(K.Fragment,{})}return(0,K.jsx)(Ke,{...d,className:i(e.className,ae),icon:n,size:o,themeColor:s,rotate:m,flip:u})};b.states=Tt;b.options=_t;b.defaultOptions=se;b.className=ae;b.moduleName=Be;b.folderName=Ue;b.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 A="menu",y=A;var B=require("react/jsx-runtime"),fe="k-menu-item",Pt=[x.hover,x.focus,x.active,x.selected,x.disabled],Rt={},$e={iconPosition:"before"},v=e=>{let{hover:t,focus:o,active:s,selected:n,disabled:l,icon:m,text:u,first:g,last:k,showArrow:d,arrowIconName:h,iconPosition:f=$e.iconPosition,dir:H,children:X,expanded:w,...I}=e,E=h;return E||(E=H==="rtl"?"chevron-left":"chevron-right"),(0,B.jsxs)("li",{...I,className:i(e.className,fe,"k-item",W(fe,{focus:o,disabled:l,hover:t,active:s,selected:n}),{"k-first":g,"k-last":k}),role:"menuitem",...d&&{"aria-haspopup":"menu"},...d&&{"aria-expanded":w?"true":"false"},...l&&{"aria-disabled":"true"},...o&&{tabIndex:0},children:[(0,B.jsxs)("span",{className:i("k-link k-menu-link"),children:[m&&f==="before"&&(0,B.jsx)(b,{className:"k-menu-link-icon",icon:m}),(0,B.jsx)("span",{className:"k-menu-link-text",children:u}),m&&f==="after"&&(0,B.jsx)(b,{className:"k-menu-link-icon",icon:m}),d&&(0,B.jsx)("span",{className:"k-menu-expand-arrow","aria-hidden":"true",children:(0,B.jsx)(b,{icon:E})})]}),X]})};v.states=Pt;v.options=Rt;v.className=fe;v.defaultOptions=$e;v.moduleName=A;v.folderName=y;var U=require("react/jsx-runtime"),xe="k-menu-item",Kt=[x.hover,x.focus,x.active,x.selected,x.disabled],Bt={},Me={dir:"ltr",iconPosition:"before"},M=e=>{let{hover:t,focus:o,active:s,selected:n,disabled:l,icon:m,text:u,first:g,last:k,showArrow:d,arrowIconName:h,iconPosition:f=Me.iconPosition,dir:H=Me.dir,children:X,popup:w,expanded:I,...E}=e,z=h;return z||(z=H==="rtl"?"chevron-left":"chevron-right"),(0,U.jsxs)("li",{role:"menuitem",...E,className:i(e.className,xe,"k-item",W(xe,{focus:o,disabled:l}),{"k-first":g,"k-last":k}),...d&&{"aria-haspopup":"menu"},...d&&{"aria-expanded":I?"true":"false"},...l&&{"aria-disabled":"true"},...o&&{tabIndex:0},children:[(0,U.jsxs)("span",{className:i("k-link k-menu-link",W("k-menu-link",{hover:t,active:s,selected:n,disabled:l})),children:[m&&f==="before"&&(0,U.jsx)(b,{className:"k-menu-link-icon",icon:m}),(0,U.jsx)("span",{className:"k-menu-link-text",children:u}),m&&f==="after"&&(0,U.jsx)(b,{className:"k-menu-link-icon",icon:m}),d&&(0,U.jsx)("span",{className:"k-menu-expand-arrow","aria-hidden":"true",children:(0,U.jsx)(b,{icon:z})})]}),X,w]})};M.states=Kt;M.options=Bt;M.className=xe;M.defaultOptions=Me;M.moduleName=A;M.folderName=y;var he="button",Fe=he;var L=require("react/jsx-runtime"),oe="k-button",Ut=["icon-button"],Ht=[x.hover,x.focus,x.active,x.selected,x.disabled,x.generating],zt={size:[a.undefined,a.xsmall,a.small,a.medium,a.large],rounded:[G.undefined,G.none,G.small,G.medium,G.large,G.full],fillMode:[J.undefined,J.solid,J.flat,J.outline,J.clear,J.link],themeColor:[r.undefined,r.base,r.primary,r.secondary,r.tertiary,r.success,r.warning,r.error,r.info,r.inverse]},be={showArrow:!1,arrowIconName:"chevron-down"},c=e=>{let{as:t="button",size:o,rounded:s,fillMode:n,themeColor:l,showArrow:m=be.showArrow,arrowIconName:u=be.arrowIconName,variant:g,hover:k,focus:d,active:h,selected:f,disabled:H,togglable:X,ariaDisabled:w,icon:I,iconSize:E,text:z,iconClassName:dt,className:ft,...xt}=e,Mt=I!=null,ht=e.children!==void 0;return(0,L.jsxs)(t,{className:i(ft,oe,Re(oe,g),R(oe,{size:o,rounded:s,fillMode:n,themeColor:l}),W(oe,{hover:k,focus:d,active:h,disabled:H||w,selected:f}),{"k-icon-button":!z&&!ht&&Mt}),"aria-pressed":X?f?"true":"false":void 0,...xt,"aria-disabled":w?"true":void 0,disabled:H||void 0,children:[typeof I=="string"&&I&&(0,L.jsx)(b,{className:i(dt,"k-button-icon"),icon:I,size:E}),I&&typeof I!="string"&&(0,L.jsx)(L.Fragment,{children:I}),z?(0,L.jsxs)(L.Fragment,{children:[z&&(0,L.jsx)("span",{className:"k-button-text",children:z}),e.children]}):e.children&&(0,L.jsx)("span",{className:"k-button-text",children:e.children}),m&&(0,L.jsx)("span",{className:"k-menu-button-arrow k-button-arrow",children:(0,L.jsx)(b,{icon:u})})]})};c.states=Ht;c.options=zt;c.variants=Ut;c.className=oe;c.defaultOptions=be;c.moduleName=he;c.folderName=Fe;c.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 Xe=require("react/jsx-runtime"),Ve=e=>(0,Xe.jsx)(c,{icon:"folder",...e,"aria-label":e["aria-label"]||"Folder",children:void 0});var Ge=require("react/jsx-runtime"),We=e=>(0,Ge.jsx)(c,{icon:"folder",children:"Button",...e});var qe=require("react/jsx-runtime"),Je=e=>(0,qe.jsx)(c,{children:"Button",...e});var ie=require("react/jsx-runtime"),Dt=c.options,$t=c.states,Ft={...c.defaultOptions,variant:"text"},Vt=[{name:"icon-only",title:"Icon Only"},{name:"icon-and-text",title:"Icon & Text"},{name:"text",title:"Text"}],Xt=[],Y=e=>{let{variant:t,...o}=e;switch(t){case"icon-only":return(0,ie.jsx)(Ve,{...o,icon:"star"});case"icon-and-text":return(0,ie.jsx)(We,{...o,icon:"star",children:"Button"});default:return(0,ie.jsx)(Je,{...o,children:"Button"})}};Y.options=Dt;Y.states=$t;Y.variants=Vt;Y.defaultOptions=Ft;Y.modifiers=Xt;Y.className=c.className;var Ze=require("react/jsx-runtime"),Qe="k-menu-scroll-wrapper",Wt=[],Gt={},Jt={},Q=e=>{let{className:t,children:o,orientation:s,...n}=e;return(0,Ze.jsx)("div",{...n,className:i(t,Qe,{"k-menu-scroll-wrapper-vertical":s==="vertical"}),children:o})};Q.states=Wt;Q.options=Gt;Q.className=Qe;Q.defaultOptions=Jt;Q.moduleName=A;Q.folderName=y;var Ye=Q;var N=require("react/jsx-runtime"),Ne="k-menu",qt=[],Qt={},le={orientation:"horizontal",header:!0,scrollButtonsPosition:"around"},p=e=>{let{children:t,orientation:o=le.orientation,header:s=le.header,scrollable:n,scrollButtonsPosition:l=le.scrollButtonsPosition,wrapperStyles:m,dir:u,popup:g,contextMenu:k,...d}=e,h={horizontal:{prev:u!=="rtl"?"left":"right",next:u!=="rtl"?"right":"left"},vertical:{prev:"up",next:"down"}},f=(0,N.jsx)("ul",{dir:u,...d,className:i(e.className,"k-reset",Ne,{[`${Ne}-${o}`]:o,"k-header":s}),role:k?"menu":"menubar",...o==="vertical"&&{"aria-orientation":"vertical"},children:t});return(0,N.jsxs)(N.Fragment,{children:[n?(0,N.jsxs)(Ye,{orientation:o,style:m,dir:e.dir,children:[l==="start"&&(0,N.jsxs)(N.Fragment,{children:[(0,N.jsx)(c,{fillMode:"flat",icon:`chevron-${h[o].prev}`,className:"k-menu-scroll-button k-menu-scroll-button-prev",tabIndex:-1,"aria-label":"Scroll previous"}),(0,N.jsx)(c,{fillMode:"flat",icon:`chevron-${h[o].next}`,className:"k-menu-scroll-button k-menu-scroll-button-next",tabIndex:-1,"aria-label":"Scroll next"})]}),l==="around"&&(0,N.jsx)(c,{fillMode:"flat",icon:`chevron-${h[o].prev}`,className:"k-menu-scroll-button k-menu-scroll-button-prev",tabIndex:-1,"aria-label":"Scroll previous"}),f,l==="end"&&(0,N.jsxs)(N.Fragment,{children:[(0,N.jsx)(c,{fillMode:"flat",icon:`chevron-${h[o].prev}`,className:"k-menu-scroll-button k-menu-scroll-button-prev",tabIndex:-1,"aria-label":"Scroll previous"}),(0,N.jsx)(c,{fillMode:"flat",icon:`chevron-${h[o].next}`,className:"k-menu-scroll-button k-menu-scroll-button-next",tabIndex:-1,"aria-label":"Scroll next"})]}),l==="around"&&(0,N.jsx)(c,{fillMode:"flat",icon:`chevron-${h[o].next}`,className:"k-menu-scroll-button k-menu-scroll-button-next",tabIndex:-1,"aria-label":"Scroll next"})]}):f,g]})};p.states=qt;p.options=Qt;p.className=Ne;p.defaultOptions=le;p.moduleName=A;p.folderName=y;p.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 et=require("react/jsx-runtime"),Ie="k-separator",je={orientation:"horizontal"},D=e=>{let{orientation:t=je.orientation,...o}=e;return(0,et.jsx)("li",{...o,className:i(e.className,"k-item",Ie,{[`${Ie}-${t}`]:t}),role:"separator"})};D.className=Ie;D.defaultOptions=je;D.moduleName=A;D.folderName=y;var tt=require("react/jsx-runtime");var ot=require("react/jsx-runtime"),ve="k-menu-group",Yt=[],Zt={size:[a.undefined,a.small,a.medium,a.large]},jt={},O=e=>{let{children:t,size:o,...s}=e;return(0,ot.jsx)("ul",{role:"menu",...s,className:i(e.className,ve,R(ve,{size:o})),children:t})};O.states=Yt;O.options=Zt;O.className=ve;O.defaultOptions=jt;O.moduleName=A;O.folderName=y;var S=require("react/jsx-runtime"),ke=e=>(0,S.jsx)(p,{children:(0,S.jsxs)(S.Fragment,{children:[(0,S.jsx)(v,{first:!0,text:"Item 1"}),(0,S.jsx)(v,{showArrow:!0,arrowIconName:"chevron-down",text:"Item 2"}),(0,S.jsx)(v,{showArrow:!0,arrowIconName:"chevron-down",text:"Item 3"}),(0,S.jsx)(v,{text:"Item 4"}),(0,S.jsx)(v,{last:!0,text:"Item 5"})]}),...e});var ge="popup",nt=ge;var Ae=require("react/jsx-runtime"),rt="k-animation-container",eo=[],to={},Ee={positionMode:"absolute",shown:!0},$=e=>{let{positionMode:t=Ee.positionMode,shown:o=Ee.shown,animationStyle:s,offset:n,...l}=e;return(0,Ae.jsx)("div",{...l,style:{...n,...e.style},className:i(e.className,rt,{"k-animation-container-shown":o,"k-animation-container-fixed":t==="fixed"}),children:(0,Ae.jsx)("div",{className:"k-child-animation-container",style:s,children:e.children})})};$.states=eo;$.options=to;$.className=rt;$.defaultOptions=Ee;$.moduleName=ge;$.folderName=nt;var Le="popup",at=Le;var ye=require("react/jsx-runtime"),st="k-popup",oo=[],no={},it={positionMode:"absolute"},_=e=>{let{offset:t,positionMode:o=it.positionMode,animationStyle:s,containerClassName:n,containerRole:l,containerAriaLabel:m,...u}=e;return(0,ye.jsx)($,{positionMode:o,offset:t,animationStyle:s,className:n,role:l,"aria-label":m,children:(0,ye.jsx)("div",{...u,className:i(e.className,st),children:e.children})})};_.states=oo;_.options=no;_.className=st;_.defaultOptions=it;_.moduleName=Le;_.folderName=at;_.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 Oe=require("react/jsx-runtime");var Se=require("react/jsx-runtime");var Ce=require("react/jsx-runtime");var we=require("react/jsx-runtime");var P=require("react/jsx-runtime"),ro={...p.options,scrollable:{type:"boolean"}},ao=p.states,lt={...p.defaultOptions,variant:"horizontal"},so=[{name:"horizontal",title:"Horizontal"},{name:"vertical",title:"Vertical"}],io=[{name:"opened",title:"Opened"}],Z=e=>{let{variant:t,modifiers:o,...s}={...lt,...e},n={},l=t==="vertical"?{left:"200px",top:"30px"}:{left:"90px",top:"auto"};return Object.keys(o||{}).forEach(m=>{m==="opened"&&(n.opened=!!(o!=null&&o[m]),n.popup=o!=null&&o[m]?(0,P.jsx)(_,{className:"k-menu-popup",offset:l,children:(0,P.jsxs)(O,{children:[(0,P.jsx)(M,{text:"Item 1"}),(0,P.jsx)(M,{text:"Item 2"}),(0,P.jsx)(D,{}),(0,P.jsx)(M,{text:"Item 3"})]})}):null)}),t==="vertical"?(0,P.jsx)(ke,{...s,...n,orientation:"vertical",style:{width:"200px"}}):(0,P.jsx)(ke,{...s,...n})};Z.options=ro;Z.states=ao;Z.variants=so;Z.defaultOptions=lt;Z.modifiers=io;Z.className=p.className;var Te="context-menu",mt=Te;var ct=require("react/jsx-runtime"),ut="k-context-menu",lo=[],mo={},uo={},C=e=>{let{children:t,...o}=e;return(0,ct.jsx)(O,{...o,className:i(e.className,ut),role:"menu",children:t})};C.states=lo;C.options=mo;C.className=ut;C.defaultOptions=uo;C.moduleName=Te;C.folderName=mt;C.ariaSpec={selector:".k-context-menu",rules:[{selector:".k-context-menu",attribute:"role=menu",usage:"The context menu implements the menu role."},{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-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."},{selector:".k-menu-popup .k-menu-group",attribute:"id",usage:"Each nested menu has an id linked to parent aria-controls."}]};var ne=require("react/jsx-runtime"),_e=e=>(0,ne.jsx)(C,{children:[(0,ne.jsx)(M,{first:!0,text:"Item 1",showArrow:!0},"menu-item-1"),(0,ne.jsx)(M,{text:"Item 2"},"menu-item-2"),(0,ne.jsx)(M,{last:!0,text:"Item 3"},"menu-item-3")],...e});var F=require("react/jsx-runtime"),co=p.options,po=p.states,pt={...p.defaultOptions,variant:"normal"},fo=[{name:"normal",title:"Normal"},{name:"separators",title:"With separator"}],xo=[],V=e=>{let{variant:t,...o}={...pt,...e};return t==="separators"?(0,F.jsxs)(_e,{...o,style:{width:"130px"},children:[(0,F.jsx)(M,{first:!0,text:"Item 1",showArrow:!0},"menu-item-1"),(0,F.jsx)(D,{}),(0,F.jsx)(M,{text:"Item 2"},"menu-item-2"),(0,F.jsx)(M,{last:!0,text:"Item 3"},"menu-item-3")]}):(0,F.jsx)(_e,{...o,style:{width:"130px"}})};V.options=co;V.states=po;V.variants=fo;V.defaultOptions=pt;V.modifiers=xo;V.className=C.className;var Mo=V;