UNPKG

@progress/kendo-themes-html

Version:

A collection of HTML helpers used for developing Kendo UI themes

2 lines (1 loc) 5.73 kB
var V=Object.create;var I=Object.defineProperty;var j=Object.getOwnPropertyDescriptor;var U=Object.getOwnPropertyNames;var q=Object.getPrototypeOf,J=Object.prototype.hasOwnProperty;var X=(t,e)=>{for(var r in e)I(t,r,{get:e[r],enumerable:!0})},R=(t,e,r,a)=>{if(e&&typeof e=="object"||typeof e=="function")for(let i of U(e))!J.call(t,i)&&i!==r&&I(t,i,{get:()=>e[i],enumerable:!(a=j(e,i))||a.enumerable});return t};var W=(t,e,r)=>(r=t!=null?V(q(t)):{},R(e||!t||!t.__esModule?I(r,"default",{value:t,enumerable:!0}):r,t)),Q=t=>R(I({},"__esModule",{value:!0}),t);var de={};X(de,{GANTTTASKCONTENT_CLASSNAME:()=>$,GanttTaskContent:()=>f,default:()=>ce});module.exports=Q(de);var l=(...t)=>t.filter(e=>e!==!0&&!!e).map(e=>Array.isArray(e)?l(...e):typeof e=="object"?Object.keys(e).map((r,a)=>e[a]||e[r]&&r||null).filter(r=>r!==null).join(" "):e).filter(e=>!!e).join(" ");var y=(t,e)=>l({[`${t}-xs`]:e.size==="xsmall",[`${t}-sm`]:e.size==="small",[`${t}-md`]:e.size==="medium",[`${t}-lg`]:e.size==="large",[`${t}-xl`]:e.size==="xlarge",[`${t}-xxl`]:e.size==="xxlarge",[`${t}-xxxl`]:e.size==="xxxlarge"},{[`${t}-${e.fillMode}`]:e.fillMode},{[`${t}-${e.themeColor}`]:e.themeColor},{"k-rounded-sm":e.rounded==="small","k-rounded-md":e.rounded==="medium","k-rounded-lg":e.rounded==="large","k-rounded-full":e.rounded==="full","k-rounded-none":e.rounded==="none"});var n={undefined:void 0,xsmall:"xsmall",small:"small",medium:"medium",large:"large",xlarge:"xlarge",xxlarge:"xxlarge",xxxlarge:"xxxlarge"};var c={undefined:void 0,outline:"outline",solid:"solid",duotone:"duotone"},o={undefined:void 0,inherit:"inherit",base:"base",primary:"primary",secondary:"secondary",tertiary:"tertiary",info:"info",success:"success",warning:"warning",error:"error",inverse:"inverse"};var N=require("react/jsx-runtime"),A="k-font-icon",Y=[],Z={size:[n.undefined,n.xsmall,n.small,n.medium,n.large,n.xlarge,n.xxlarge,n.xxxlarge],themeColor:[o.undefined,o.base,o.primary,o.secondary,o.tertiary,o.success,o.warning,o.error,o.info]},ee={},C=t=>{let{size:e,themeColor:r,icon:a,rotate:i,flip:p,...x}=t;return a?(0,N.jsx)("span",{...x,className:l(t.className,A,y(A,{size:e}),{[`k-i-${a}`]:a,[`k-color-${r}`]:r,[`k-rotate-${i}`]:i,"k-flip-h":p==="h"||p==="both","k-flip-v":p==="v"||p==="both"}),"aria-hidden":"true"}):(0,N.jsx)(N.Fragment,{})};C.states=Y;C.options=Z;C.className=A;C.defaultOptions=ee;var G=C;var g=require("react/jsx-runtime"),z="k-svg-icon",te=[],oe={size:[n.undefined,n.xsmall,n.small,n.medium,n.large,n.xlarge,n.xxlarge,n.xxxlarge],themeColor:[o.undefined,o.base,o.primary,o.secondary,o.tertiary,o.success,o.warning,o.error,o.info],variant:[c.outline,c.solid,c.duotone]},E={viewBox:"0 0 24 24",variant:c.outline},b=t=>{var S,k;let{size:e,themeColor:r,rotate:a,flip:i,viewBox:p=E.viewBox,variant:x=E.variant,icon:s,...T}=t;if(!s)return(0,g.jsx)(g.Fragment,{});if(s==="none")return(0,g.jsx)("span",{...T,className:l(t.className,z,y("k-icon",{size:e}),"k-none"),"aria-hidden":"true"});let v=typeof s=="object"&&s.name&&s.name,h=typeof s=="object"?x&&((S=s.variants)==null?void 0:S[x])||((k=s.variants)==null?void 0:k.outline)||s.content:void 0;return(0,g.jsx)("span",{...T,className:l(t.className,z,y("k-icon",{size:e}),{[`k-svg-i-${v}`]:v,[`k-color-${r}`]:r,[`k-rotate-${a}`]:a,"k-flip-h":i==="h"||i==="both","k-flip-v":i==="v"||i==="both"}),"aria-hidden":"true",children:(0,g.jsx)("svg",{"aria-hidden":!0,focusable:!1,xmlns:"http://www.w3.org/2000/svg",viewBox:typeof s=="object"?s.viewBox:p,dangerouslySetInnerHTML:h!==void 0?{__html:h}:void 0,children:s?void 0:t.children})})};b.states=te;b.options=oe;b.className=z;b.defaultOptions=E;var _=b;var L=W(require("@progress/kendo-svg-icons"));var B="icon",H="icons";var P=require("react");var F=require("react"),D=(0,F.createContext)({iconsType:"svg"});var d=require("react/jsx-runtime"),M="k-icon",ne=t=>t.replace(/([-_][a-z0-9])/gi,e=>e.toUpperCase().replace("-","").replace("_","")),re=[],ie={size:[n.undefined,n.xsmall,n.small,n.medium,n.large,n.xlarge,n.xxlarge,n.xxxlarge],themeColor:[o.undefined,o.base,o.primary,o.secondary,o.tertiary,o.success,o.warning,o.error,o.info],variant:[c.outline,c.solid,c.duotone]},O={viewBox:"0 0 24 24",type:"svg",variant:c.outline},m=t=>{let{iconsType:e}=(0,P.useContext)(D),{size:r,themeColor:a,icon:i,type:p=e||O.type,rotate:x,flip:s,viewBox:T=O.viewBox,variant:v=O.variant,...h}=t;if(!i)return(0,d.jsx)(d.Fragment,{});if((e||p)==="svg"){if(i==="none")return(0,d.jsx)(_,{...h,className:l(t.className,M),icon:i,size:r,variant:v});let k=L[i]?i:ne(`${i}-icon`);return L[k]?(0,d.jsx)(_,{...h,className:l(t.className,M),icon:L[k],size:r,themeColor:a,rotate:x,flip:s,viewBox:T,variant:v}):(0,d.jsx)(d.Fragment,{})}return(0,d.jsx)(G,{...h,className:l(t.className,M),icon:i,size:r,themeColor:a,rotate:x,flip:s})};m.states=re;m.options=ie;m.defaultOptions=O;m.className=M;m.moduleName=B;m.folderName=H;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 w="gantt",K=w;var u=require("react/jsx-runtime"),$="k-task-content",se=[],ae={},le={},f=t=>{let{content:e,...r}=t;return(0,u.jsxs)("div",{...r,className:l(t.className,$),children:[e&&(0,u.jsx)("div",{className:"k-task-template",children:e}),(0,u.jsx)("span",{className:"k-task-actions","aria-hidden":"true",children:(0,u.jsx)("a",{className:"k-link k-task-delete",children:(0,u.jsx)(m,{icon:"x"})})}),(0,u.jsx)("span",{className:"k-resize-handle k-resize-w","aria-hidden":"true"}),(0,u.jsx)("span",{className:"k-resize-handle k-resize-e","aria-hidden":"true"})]})};f.states=se;f.options=ae;f.className=$;f.defaultOptions=le;f.moduleName=w;f.folderName=K;var ce=f;