@gyramais/gyra-design 0.1.7 → 0.1.9

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -33,5 +33,5 @@ object-assign
33
33
  * This source code is licensed under the MIT license found in the
34
34
  * LICENSE file in the root directory of this source tree.
35
35
  */
36
- function(e,t){const r=Cr(e,t);return"production"!==process.env.NODE_ENV?(...t)=>{const n="string"==typeof e?`"${e}"`:"component";return 0===t.length?console.error([`MUI: Seems like you called \`styled(${n})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join("\n")):t.some((e=>void 0===e))&&console.error(`MUI: the styled(${n})(...args) API requires all its args to be defined.`),r(...t)}:r}(e,b({shouldForwardProp:h,label:y},p)),v=(n,...o)=>{const a=o?o.map((e=>{if("function"==typeof e&&e.__emotion_real!==e)return n=>Yn({styledArg:e,props:n,defaultTheme:r,themeId:t});if(E(e)){let t,r=e;return e&&e.variants&&(t=e.variants,delete r.variants,r=r=>{let n=e;return Un(r,Ln(t),t).forEach((e=>{n=x(n,e)})),n}),r}return e})):[];let l=n;if(E(n)){let e;n&&n.variants&&(e=n.variants,delete l.variants,l=t=>{let r=n;return Un(t,Ln(e),e).forEach((e=>{r=x(r,e)})),r})}else"function"==typeof n&&n.__emotion_real!==n&&(l=e=>Yn({styledArg:n,props:e,defaultTheme:r,themeId:t}));s&&f&&a.push((e=>{const n=Kn(b({},e,{defaultTheme:r,themeId:t})),o=((e,t)=>t.components&&t.components[e]&&t.components[e].styleOverrides?t.components[e].styleOverrides:null)(s,n);if(o){const t={};return Object.entries(o).forEach((([r,o])=>{t[r]="function"==typeof o?o(b({},e,{theme:n})):o})),f(e,t)}return null})),s&&!d&&a.push((e=>{const n=Kn(b({},e,{defaultTheme:r,themeId:t}));return((e,t,r,n)=>{var o;const i=null==r||null==(o=r.components)||null==(o=o[n])?void 0:o.variants;return Un(e,t,i)})(e,((e,t)=>{let r=[];return t&&t.components&&t.components[e]&&t.components[e].variants&&(r=t.components[e].variants),Ln(r)})(s,n),n,s)})),m||a.push(i);const u=a.length-o.length;if(Array.isArray(n)&&u>0){const e=new Array(u).fill("");l=[...n,...e],l.raw=[...n.raw,...e]}const p=g(l,...a);if("production"!==process.env.NODE_ENV){let t;s&&(t=`${s}${oe(c||"")}`),void 0===t&&(t=`Styled(${function(e){if(null!=e){if("string"==typeof e)return e;if("function"==typeof e)return re(e,"Component");if("object"==typeof e)switch(e.$$typeof){case ee.ForwardRef:return ne(e,e.render,"ForwardRef");case ee.Memo:return ne(e,e.type,"memo");default:return}}}(e)})`),p.displayName=t}return e.muiName&&(p.muiName=e.muiName),p};return g.withConfig&&(v.withConfig=g.withConfig),v}}({themeId:jo,defaultTheme:Co,rootShouldForwardProp:e=>Bn(e)&&"classes"!==e});function Po(e){return xe("MuiSvgIcon",e)}!function(e,t,r="Mui"){const n={};t.forEach((t=>{n[t]=xe(e,t,r)}))}("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Mo=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],Ro=e=>{const{color:t,fontSize:r,classes:n}=e;return function(e,t,r){const n={};return Object.keys(e).forEach((o=>{n[o]=e[o].reduce(((e,n)=>{if(n){const o=t(n);""!==o&&e.push(o),r&&r[n]&&e.push(r[n])}return e}),[]).join(" ")})),n}({root:["root","inherit"!==t&&`color${oe(t)}`,`fontSize${oe(r)}`]},Po,n)},Vo=Io("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,"inherit"!==r.color&&t[`color${oe(r.color)}`],t[`fontSize${oe(r.fontSize)}`]]}})((({theme:e,ownerState:t})=>{var r,n,o,i,a,s,c,l,u,f,p,d,m;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:null==(r=e.transitions)||null==(n=r.create)?void 0:n.call(r,"fill",{duration:null==(o=e.transitions)||null==(o=o.duration)?void 0:o.shorter}),fontSize:{inherit:"inherit",small:(null==(i=e.typography)||null==(a=i.pxToRem)?void 0:a.call(i,20))||"1.25rem",medium:(null==(s=e.typography)||null==(c=s.pxToRem)?void 0:c.call(s,24))||"1.5rem",large:(null==(l=e.typography)||null==(u=l.pxToRem)?void 0:u.call(l,35))||"2.1875rem"}[t.fontSize],color:null!=(f=null==(p=(e.vars||e).palette)||null==(p=p[t.color])?void 0:p.main)?f:{action:null==(d=(e.vars||e).palette)||null==(d=d.action)?void 0:d.active,disabled:null==(m=(e.vars||e).palette)||null==(m=m.action)?void 0:m.disabled,inherit:void 0}[t.color]}})),Do=e.forwardRef((function(t,r){const n=function({props:e,name:t}){return Jn({props:e,name:t,defaultTheme:Co,themeId:jo})}({props:t,name:"MuiSvgIcon"}),{children:o,className:i,color:c="inherit",component:l="svg",fontSize:u="medium",htmlColor:f,inheritViewBox:p=!1,titleAccess:d,viewBox:m="0 0 24 24"}=n,y=Oe(n,Mo),h=e.isValidElement(o)&&"svg"===o.type,g=b({},n,{color:c,component:l,fontSize:u,instanceFontSize:t.fontSize,inheritViewBox:p,viewBox:m,hasSvgAsChild:h}),v={};p||(v.viewBox=m);const E=Ro(g);return a(Vo,b({as:l,className:ke(E.root,i),focusable:"false",color:f,"aria-hidden":!d||void 0,role:d?"img":void 0,ref:r},v,y,h&&o.props,{ownerState:g,children:[h?o.props.children:o,d?s("title",{children:d}):null]}))}));"production"!==process.env.NODE_ENV&&(Do.propTypes={children:q.node,classes:q.object,className:q.string,color:q.oneOfType([q.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),q.string]),component:q.elementType,fontSize:q.oneOfType([q.oneOf(["inherit","large","medium","small"]),q.string]),htmlColor:q.string,inheritViewBox:q.bool,shapeRendering:q.string,sx:q.oneOfType([q.arrayOf(q.oneOfType([q.func,q.object,q.bool])),q.func,q.object]),titleAccess:q.string,viewBox:q.string}),Do.muiName="SvgIcon";const zo={configure:e=>{"production"!==process.env.NODE_ENV&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join("\n")),Ee.configure(e)}};var Fo,Lo=Object.freeze({__proto__:null,capitalize:oe,createChainedFunction:function(...e){return e.reduce(((e,t)=>null==t?e:function(...r){e.apply(this,r),t.apply(this,r)}),(()=>{}))},createSvgIcon:function(t,r){function n(e,n){return s(Do,b({"data-testid":`${r}Icon`,ref:n},e,{children:t}))}return"production"!==process.env.NODE_ENV&&(n.displayName=`${r}Icon`),n.muiName=Do.muiName,e.memo(e.forwardRef(n))},debounce:function(e,t=166){let r;function n(...n){clearTimeout(r),r=setTimeout((()=>{e.apply(this,n)}),t)}return n.clear=()=>{clearTimeout(r)},n},deprecatedPropType:function(e,t){return"production"===process.env.NODE_ENV?()=>null:(e,r,n,o,i)=>{const a=n||"<<anonymous>>",s=i||r;return void 0!==e[r]?new Error(`The ${o} \`${s}\` of \`${a}\` is deprecated. ${t}`):null}},isMuiElement:function(t,r){var n,o;return e.isValidElement(t)&&-1!==r.indexOf(null!=(n=t.type.muiName)?n:null==(o=t.type)||null==(o=o._payload)||null==(o=o.value)?void 0:o.muiName)},ownerDocument:ie,ownerWindow:function(e){return ie(e).defaultView||window},requirePropFactory:function(e,t){if("production"===process.env.NODE_ENV)return()=>null;const r=t?b({},t.propTypes):null;return t=>(n,o,i,a,s,...c)=>{const l=s||o,u=null==r?void 0:r[l];if(u){const e=u(n,o,i,a,s,...c);if(e)return e}return void 0===n[o]||n[t]?null:new Error(`The prop \`${l}\` of \`${e}\` can only be used together with the \`${t}\` prop.`)}},setRef:ae,unstable_ClassNameGenerator:zo,unstable_useEnhancedEffect:se,unstable_useId:function(t){if(void 0!==le){const e=le();return null!=t?t:e}return function(t){const[r,n]=e.useState(t),o=t||r;return e.useEffect((()=>{null==r&&(ce+=1,n(`mui-${ce}`))}),[r]),o}(t)},unsupportedProp:function(e,t,r,n,o){if("production"===process.env.NODE_ENV)return null;const i=o||t;return void 0!==e[t]?new Error(`The prop \`${i}\` is not supported. Please remove it.`):null},useControlled:function({controlled:t,default:r,name:n,state:o="value"}){const{current:i}=e.useRef(void 0!==t),[a,s]=e.useState(r),c=i?t:a;if("production"!==process.env.NODE_ENV){e.useEffect((()=>{i!==(void 0!==t)&&console.error([`MUI: A component is changing the ${i?"":"un"}controlled ${o} state of ${n} to be ${i?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join("\n"))}),[o,n,t]);const{current:a}=e.useRef(r);e.useEffect((()=>{i||a===r||console.error([`MUI: A component is changing the default ${o} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join("\n"))}),[JSON.stringify(r)])}return[c,e.useCallback((e=>{i||s(e)}),[])]},useEventCallback:function(t){const r=e.useRef(t);return se((()=>{r.current=t})),e.useRef(((...e)=>(0,r.current)(...e))).current},useForkRef:function(...t){return e.useMemo((()=>t.every((e=>null==e))?null:e=>{t.forEach((t=>{ae(t,e)}))}),t)},useIsFocusVisible:function(){const t=e.useCallback((e=>{var t;null!=e&&((t=e.ownerDocument).addEventListener("keydown",me,!0),t.addEventListener("mousedown",ye,!0),t.addEventListener("pointerdown",ye,!0),t.addEventListener("touchstart",ye,!0),t.addEventListener("visibilitychange",he,!0))}),[]),r=e.useRef(!1);return{isFocusVisibleRef:r,onFocus:function(e){return!!ge(e)&&(r.current=!0,!0)},onBlur:function(){return!!r.current&&(pe=!0,window.clearTimeout(ue),ue=window.setTimeout((()=>{pe=!1}),100),r.current=!1,!0)},ref:t}}}),Uo=l(Lo);var Bo=g;Object.defineProperty(y,"__esModule",{value:!0});var Wo=y.default=void 0,Go=Bo((Fo||(Fo=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=Uo}(v)),v)),Ko=i;Wo=y.default=(0,Go.default)((0,Ko.jsx)("path",{d:"M17.6 10.81 16.19 9.4l3.56-3.55 1.41 1.41c-.11.03-3.56 3.55-3.56 3.55M13 3h-2v5h2zm-6.6 7.81L7.81 9.4 4.26 5.84 2.84 7.26c.11.03 3.56 3.55 3.56 3.55M20 14h-3.42c-.77 1.76-2.54 3-4.58 3s-3.81-1.24-4.58-3H4v5h16zm0-2c1.1 0 2 .9 2 2v5c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2v-5c0-1.1.9-2 2-2h5c0 1.66 1.34 3 3 3s3-1.34 3-3z"}),"UpcomingOutlined");var qo=function(e){var r=e.id,n=e.className,i=e.height,a=e.columns,s=void 0===a?[]:a,c=e.data,l=void 0===c?[]:c,u=e.empty,f=void 0===u?{icon:void 0,text:"Tabela vazia"}:u,y=o((function(){var e=s.reduce((function(e,t){return e[t.key]=t,e}),{}),r=Object.keys(e),n=l.reduce((function(n,o,i){var a=[];return r.forEach((function(r){var n=e[r]||{},i=n.render,s=n.align;a.push(t.createElement("td",{key:"".concat(r,"-").concat(JSON.stringify(o)),className:"gyramais-table-align-".concat(s||"center")},i?i(o[r],o):o[r]))})),n.push(t.createElement("tr",{key:"".concat(i,"-").concat(JSON.stringify(o))},a)),n}),[]);return n}),[s,l]);return t.createElement("div",{id:r,className:p("gyramais-table-container",n),style:{maxHeight:i||"fit-content"}},t.createElement("table",null,t.createElement("thead",null,t.createElement("tr",null,s.map((function(e){return t.createElement("th",{key:e.key,className:"gyramais-table-align-".concat(e.align||"center"),style:{width:e.width||"auto"}},e.header)})))),t.createElement("tbody",null,y)),0===l.length&&t.createElement(d,{columns:1,gap:8,className:"gyramais-table-empty-container"},t.createElement(m,{span:1,className:"gyramais-table-empty-icon"},f.icon||t.createElement(Wo,null)),t.createElement(m,{span:1,className:"gyramais-table-empty-text"},f.text)))};export{qo as Table};
36
+ function(e,t){const r=Cr(e,t);return"production"!==process.env.NODE_ENV?(...t)=>{const n="string"==typeof e?`"${e}"`:"component";return 0===t.length?console.error([`MUI: Seems like you called \`styled(${n})()\` without a \`style\` argument.`,'You must provide a `styles` argument: `styled("div")(styleYouForgotToPass)`.'].join("\n")):t.some((e=>void 0===e))&&console.error(`MUI: the styled(${n})(...args) API requires all its args to be defined.`),r(...t)}:r}(e,b({shouldForwardProp:h,label:y},p)),v=(n,...o)=>{const a=o?o.map((e=>{if("function"==typeof e&&e.__emotion_real!==e)return n=>Yn({styledArg:e,props:n,defaultTheme:r,themeId:t});if(E(e)){let t,r=e;return e&&e.variants&&(t=e.variants,delete r.variants,r=r=>{let n=e;return Un(r,Ln(t),t).forEach((e=>{n=x(n,e)})),n}),r}return e})):[];let l=n;if(E(n)){let e;n&&n.variants&&(e=n.variants,delete l.variants,l=t=>{let r=n;return Un(t,Ln(e),e).forEach((e=>{r=x(r,e)})),r})}else"function"==typeof n&&n.__emotion_real!==n&&(l=e=>Yn({styledArg:n,props:e,defaultTheme:r,themeId:t}));s&&f&&a.push((e=>{const n=Kn(b({},e,{defaultTheme:r,themeId:t})),o=((e,t)=>t.components&&t.components[e]&&t.components[e].styleOverrides?t.components[e].styleOverrides:null)(s,n);if(o){const t={};return Object.entries(o).forEach((([r,o])=>{t[r]="function"==typeof o?o(b({},e,{theme:n})):o})),f(e,t)}return null})),s&&!d&&a.push((e=>{const n=Kn(b({},e,{defaultTheme:r,themeId:t}));return((e,t,r,n)=>{var o;const i=null==r||null==(o=r.components)||null==(o=o[n])?void 0:o.variants;return Un(e,t,i)})(e,((e,t)=>{let r=[];return t&&t.components&&t.components[e]&&t.components[e].variants&&(r=t.components[e].variants),Ln(r)})(s,n),n,s)})),m||a.push(i);const u=a.length-o.length;if(Array.isArray(n)&&u>0){const e=new Array(u).fill("");l=[...n,...e],l.raw=[...n.raw,...e]}const p=g(l,...a);if("production"!==process.env.NODE_ENV){let t;s&&(t=`${s}${oe(c||"")}`),void 0===t&&(t=`Styled(${function(e){if(null!=e){if("string"==typeof e)return e;if("function"==typeof e)return re(e,"Component");if("object"==typeof e)switch(e.$$typeof){case ee.ForwardRef:return ne(e,e.render,"ForwardRef");case ee.Memo:return ne(e,e.type,"memo");default:return}}}(e)})`),p.displayName=t}return e.muiName&&(p.muiName=e.muiName),p};return g.withConfig&&(v.withConfig=g.withConfig),v}}({themeId:jo,defaultTheme:Co,rootShouldForwardProp:e=>Bn(e)&&"classes"!==e});function Po(e){return xe("MuiSvgIcon",e)}!function(e,t,r="Mui"){const n={};t.forEach((t=>{n[t]=xe(e,t,r)}))}("MuiSvgIcon",["root","colorPrimary","colorSecondary","colorAction","colorError","colorDisabled","fontSizeInherit","fontSizeSmall","fontSizeMedium","fontSizeLarge"]);const Mo=["children","className","color","component","fontSize","htmlColor","inheritViewBox","titleAccess","viewBox"],Ro=e=>{const{color:t,fontSize:r,classes:n}=e;return function(e,t,r){const n={};return Object.keys(e).forEach((o=>{n[o]=e[o].reduce(((e,n)=>{if(n){const o=t(n);""!==o&&e.push(o),r&&r[n]&&e.push(r[n])}return e}),[]).join(" ")})),n}({root:["root","inherit"!==t&&`color${oe(t)}`,`fontSize${oe(r)}`]},Po,n)},Vo=Io("svg",{name:"MuiSvgIcon",slot:"Root",overridesResolver:(e,t)=>{const{ownerState:r}=e;return[t.root,"inherit"!==r.color&&t[`color${oe(r.color)}`],t[`fontSize${oe(r.fontSize)}`]]}})((({theme:e,ownerState:t})=>{var r,n,o,i,a,s,c,l,u,f,p,d,m;return{userSelect:"none",width:"1em",height:"1em",display:"inline-block",fill:t.hasSvgAsChild?void 0:"currentColor",flexShrink:0,transition:null==(r=e.transitions)||null==(n=r.create)?void 0:n.call(r,"fill",{duration:null==(o=e.transitions)||null==(o=o.duration)?void 0:o.shorter}),fontSize:{inherit:"inherit",small:(null==(i=e.typography)||null==(a=i.pxToRem)?void 0:a.call(i,20))||"1.25rem",medium:(null==(s=e.typography)||null==(c=s.pxToRem)?void 0:c.call(s,24))||"1.5rem",large:(null==(l=e.typography)||null==(u=l.pxToRem)?void 0:u.call(l,35))||"2.1875rem"}[t.fontSize],color:null!=(f=null==(p=(e.vars||e).palette)||null==(p=p[t.color])?void 0:p.main)?f:{action:null==(d=(e.vars||e).palette)||null==(d=d.action)?void 0:d.active,disabled:null==(m=(e.vars||e).palette)||null==(m=m.action)?void 0:m.disabled,inherit:void 0}[t.color]}})),Do=e.forwardRef((function(t,r){const n=function({props:e,name:t}){return Jn({props:e,name:t,defaultTheme:Co,themeId:jo})}({props:t,name:"MuiSvgIcon"}),{children:o,className:i,color:c="inherit",component:l="svg",fontSize:u="medium",htmlColor:f,inheritViewBox:p=!1,titleAccess:d,viewBox:m="0 0 24 24"}=n,y=Oe(n,Mo),h=e.isValidElement(o)&&"svg"===o.type,g=b({},n,{color:c,component:l,fontSize:u,instanceFontSize:t.fontSize,inheritViewBox:p,viewBox:m,hasSvgAsChild:h}),v={};p||(v.viewBox=m);const E=Ro(g);return a(Vo,b({as:l,className:ke(E.root,i),focusable:"false",color:f,"aria-hidden":!d||void 0,role:d?"img":void 0,ref:r},v,y,h&&o.props,{ownerState:g,children:[h?o.props.children:o,d?s("title",{children:d}):null]}))}));"production"!==process.env.NODE_ENV&&(Do.propTypes={children:q.node,classes:q.object,className:q.string,color:q.oneOfType([q.oneOf(["inherit","action","disabled","primary","secondary","error","info","success","warning"]),q.string]),component:q.elementType,fontSize:q.oneOfType([q.oneOf(["inherit","large","medium","small"]),q.string]),htmlColor:q.string,inheritViewBox:q.bool,shapeRendering:q.string,sx:q.oneOfType([q.arrayOf(q.oneOfType([q.func,q.object,q.bool])),q.func,q.object]),titleAccess:q.string,viewBox:q.string}),Do.muiName="SvgIcon";const zo={configure:e=>{"production"!==process.env.NODE_ENV&&console.warn(["MUI: `ClassNameGenerator` import from `@mui/material/utils` is outdated and might cause unexpected issues.","","You should use `import { unstable_ClassNameGenerator } from '@mui/material/className'` instead","","The detail of the issue: https://github.com/mui/material-ui/issues/30011#issuecomment-1024993401","","The updated documentation: https://mui.com/guides/classname-generator/"].join("\n")),Ee.configure(e)}};var Fo,Lo=Object.freeze({__proto__:null,capitalize:oe,createChainedFunction:function(...e){return e.reduce(((e,t)=>null==t?e:function(...r){e.apply(this,r),t.apply(this,r)}),(()=>{}))},createSvgIcon:function(t,r){function n(e,n){return s(Do,b({"data-testid":`${r}Icon`,ref:n},e,{children:t}))}return"production"!==process.env.NODE_ENV&&(n.displayName=`${r}Icon`),n.muiName=Do.muiName,e.memo(e.forwardRef(n))},debounce:function(e,t=166){let r;function n(...n){clearTimeout(r),r=setTimeout((()=>{e.apply(this,n)}),t)}return n.clear=()=>{clearTimeout(r)},n},deprecatedPropType:function(e,t){return"production"===process.env.NODE_ENV?()=>null:(e,r,n,o,i)=>{const a=n||"<<anonymous>>",s=i||r;return void 0!==e[r]?new Error(`The ${o} \`${s}\` of \`${a}\` is deprecated. ${t}`):null}},isMuiElement:function(t,r){var n,o;return e.isValidElement(t)&&-1!==r.indexOf(null!=(n=t.type.muiName)?n:null==(o=t.type)||null==(o=o._payload)||null==(o=o.value)?void 0:o.muiName)},ownerDocument:ie,ownerWindow:function(e){return ie(e).defaultView||window},requirePropFactory:function(e,t){if("production"===process.env.NODE_ENV)return()=>null;const r=t?b({},t.propTypes):null;return t=>(n,o,i,a,s,...c)=>{const l=s||o,u=null==r?void 0:r[l];if(u){const e=u(n,o,i,a,s,...c);if(e)return e}return void 0===n[o]||n[t]?null:new Error(`The prop \`${l}\` of \`${e}\` can only be used together with the \`${t}\` prop.`)}},setRef:ae,unstable_ClassNameGenerator:zo,unstable_useEnhancedEffect:se,unstable_useId:function(t){if(void 0!==le){const e=le();return null!=t?t:e}return function(t){const[r,n]=e.useState(t),o=t||r;return e.useEffect((()=>{null==r&&(ce+=1,n(`mui-${ce}`))}),[r]),o}(t)},unsupportedProp:function(e,t,r,n,o){if("production"===process.env.NODE_ENV)return null;const i=o||t;return void 0!==e[t]?new Error(`The prop \`${i}\` is not supported. Please remove it.`):null},useControlled:function({controlled:t,default:r,name:n,state:o="value"}){const{current:i}=e.useRef(void 0!==t),[a,s]=e.useState(r),c=i?t:a;if("production"!==process.env.NODE_ENV){e.useEffect((()=>{i!==(void 0!==t)&&console.error([`MUI: A component is changing the ${i?"":"un"}controlled ${o} state of ${n} to be ${i?"un":""}controlled.`,"Elements should not switch from uncontrolled to controlled (or vice versa).",`Decide between using a controlled or uncontrolled ${n} element for the lifetime of the component.`,"The nature of the state is determined during the first render. It's considered controlled if the value is not `undefined`.","More info: https://fb.me/react-controlled-components"].join("\n"))}),[o,n,t]);const{current:a}=e.useRef(r);e.useEffect((()=>{i||a===r||console.error([`MUI: A component is changing the default ${o} state of an uncontrolled ${n} after being initialized. To suppress this warning opt to use a controlled ${n}.`].join("\n"))}),[JSON.stringify(r)])}return[c,e.useCallback((e=>{i||s(e)}),[])]},useEventCallback:function(t){const r=e.useRef(t);return se((()=>{r.current=t})),e.useRef(((...e)=>(0,r.current)(...e))).current},useForkRef:function(...t){return e.useMemo((()=>t.every((e=>null==e))?null:e=>{t.forEach((t=>{ae(t,e)}))}),t)},useIsFocusVisible:function(){const t=e.useCallback((e=>{var t;null!=e&&((t=e.ownerDocument).addEventListener("keydown",me,!0),t.addEventListener("mousedown",ye,!0),t.addEventListener("pointerdown",ye,!0),t.addEventListener("touchstart",ye,!0),t.addEventListener("visibilitychange",he,!0))}),[]),r=e.useRef(!1);return{isFocusVisibleRef:r,onFocus:function(e){return!!ge(e)&&(r.current=!0,!0)},onBlur:function(){return!!r.current&&(pe=!0,window.clearTimeout(ue),ue=window.setTimeout((()=>{pe=!1}),100),r.current=!1,!0)},ref:t}}}),Uo=l(Lo);var Bo=g;Object.defineProperty(y,"__esModule",{value:!0});var Wo=y.default=void 0,Go=Bo((Fo||(Fo=1,function(e){"use client";Object.defineProperty(e,"__esModule",{value:!0}),Object.defineProperty(e,"default",{enumerable:!0,get:function(){return t.createSvgIcon}});var t=Uo}(v)),v)),Ko=i;Wo=y.default=(0,Go.default)((0,Ko.jsx)("path",{d:"M17.6 10.81 16.19 9.4l3.56-3.55 1.41 1.41c-.11.03-3.56 3.55-3.56 3.55M13 3h-2v5h2zm-6.6 7.81L7.81 9.4 4.26 5.84 2.84 7.26c.11.03 3.56 3.55 3.56 3.55M20 14h-3.42c-.77 1.76-2.54 3-4.58 3s-3.81-1.24-4.58-3H4v5h16zm0-2c1.1 0 2 .9 2 2v5c0 1.1-.9 2-2 2H4c-1.1 0-2-.9-2-2v-5c0-1.1.9-2 2-2h5c0 1.66 1.34 3 3 3s3-1.34 3-3z"}),"UpcomingOutlined");var qo=function(e){var r=e.id,n=e.className,i=e.height,a=e.columns,s=void 0===a?[]:a,c=e.data,l=void 0===c?[]:c,u=e.empty,f=void 0===u?{icon:void 0,text:"Tabela vazia"}:u,y=o((function(){var e=s.reduce((function(e,t){return e[t.key]=t,e}),{}),r=Object.keys(e),n=l.reduce((function(n,o,i){var a=[];return r.forEach((function(r){var n=e[r]||{},i=n.render,s=n.align;a.push(t.createElement("td",{key:"".concat(r,"-").concat(JSON.stringify(o)),className:"gyramais-table-align-".concat(s||"center")},t.createElement("div",{title:["string","number"].includes(typeof o[r])&&(i?i(o[r],o):o[r])},i?i(o[r],o):o[r])))})),n.push(t.createElement("tr",{key:"".concat(i,"-").concat(JSON.stringify(o))},a)),n}),[]);return n}),[s,l]);return t.createElement("div",{id:r,className:p("gyramais-table-container",n),style:{maxHeight:i||"fit-content"}},t.createElement("table",null,t.createElement("thead",null,t.createElement("tr",null,s.map((function(e){return t.createElement("th",{key:e.key,className:"gyramais-table-align-".concat(e.align||"center"),style:{width:e.width||"max-content"}},e.header)})))),t.createElement("tbody",null,y)),0===l.length&&t.createElement(d,{columns:1,gap:8,className:"gyramais-table-empty-container"},t.createElement(m,{span:1,className:"gyramais-table-empty-icon"},f.icon||t.createElement(Wo,null)),t.createElement(m,{span:1,className:"gyramais-table-empty-text"},f.text)))};export{qo as Table};
37
37
  //# sourceMappingURL=index.js.map