@progress/kendo-themes-html
Version:
A collection of HTML helpers used for developing Kendo UI themes
2 lines (1 loc) • 2.22 kB
JavaScript
var o=Object.defineProperty;var g=Object.getOwnPropertyDescriptor;var m=Object.getOwnPropertyNames;var x=Object.prototype.hasOwnProperty;var h=(t,e)=>{for(var l in e)o(t,l,{get:e[l],enumerable:!0})},f=(t,e,l,r)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of m(e))!x.call(t,i)&&i!==l&&o(t,i,{get:()=>e[i],enumerable:!(r=g(e,i))||r.enumerable});return t};var k=t=>f(o({},"__esModule",{value:!0}),t);var L={};h(L,{ListContent:()=>c});module.exports=k(L);var n=(...t)=>t.filter(e=>e!==!0&&!!e).map(e=>Array.isArray(e)?n(...e):typeof e=="object"?Object.keys(e).map((l,r)=>e[r]||e[l]&&l||null).filter(l=>l!==null).join(" "):e).filter(e=>!!e).join(" ");var u=require("react/jsx-runtime"),y="k-list-ul",s=t=>{let{children:e,role:l,id:r,...i}=t;return(0,u.jsx)("ul",{...i,id:r,role:l,className:n(y,t.className),children:e})};s.ariaSpec={selector:".k-list-ul",rules:[{selector:'.k-list-ul[role="listbox"]',attribute:"role=listbox",usage:"For ungrouped lists, the UL has the listbox role."},{selector:'.k-list-ul[role="listbox"]',attribute:"aria-label or aria-labelledby (when has accessible name)",usage:"Accessible name for the listbox."},{selector:'.k-list-ul[role="group"]',attribute:"role=group",usage:"For grouped sublists under a group header."},{selector:'.k-list-ul[role="group"]',attribute:"aria-labelledby (when grouped)",usage:"References the group header ID."}]};var a=require("react/jsx-runtime"),v="k-list-content",c=t=>{let{virtualization:e,grouping:l,"aria-label":r,"aria-labelledby":i,listboxId:d,...b}=t;return(0,a.jsxs)("div",{...b,className:n(v,t.className),role:l?"listbox":void 0,id:l?d:void 0,"aria-label":l?r:void 0,"aria-labelledby":l?i:void 0,children:[l?t.children:(0,a.jsx)(s,{role:"listbox",id:d,"aria-label":r,"aria-labelledby":i,children:t.children}),e&&(0,a.jsx)("div",{className:"k-height-container",children:(0,a.jsx)("div",{})})]})};c.ariaSpec={selector:".k-list-content",rules:[{selector:'.k-list-content[role="listbox"]',attribute:"role=listbox",usage:"For grouped lists, the list content container has the listbox role."},{selector:'.k-list-content[role="listbox"]',attribute:"aria-label or aria-labelledby (when has accessible name)",usage:"Accessible name for the listbox."}]};