@up42/up-components 0.2.3 → 0.3.0
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.
- package/dist/cjs/index.js +1 -1
- package/dist/cjs/types/components/Box/Box.stories.d.ts +2 -2
- package/dist/cjs/types/components/Button/Button.stories.d.ts +1 -0
- package/dist/cjs/types/components/Checkbox/Checkbox.stories.d.ts +1 -1
- package/dist/cjs/types/components/Chip/Chip.stories.d.ts +1 -1
- package/dist/cjs/types/components/EmptyState/EmptyState.d.ts +3 -3
- package/dist/cjs/types/components/EmptyState/EmptyState.stories.d.ts +3 -3
- package/dist/cjs/types/components/Form/Form.stories.d.ts +5 -0
- package/dist/cjs/types/components/FormCheckbox/FormCheckbox.d.ts +5 -8
- package/dist/cjs/types/components/FormCheckbox/FormCheckbox.stories.d.ts +3 -3
- package/dist/cjs/types/components/FormControl/FormControl.overrides.d.ts +3 -0
- package/dist/cjs/types/components/FormInput/FormInput.d.ts +4 -8
- package/dist/cjs/types/components/FormInput/FormInput.stories.d.ts +6 -3
- package/dist/cjs/types/components/FormLabel/FormLabel.d.ts +8 -0
- package/dist/cjs/types/components/FormLabel/FormLabel.test.d.ts +1 -0
- package/dist/cjs/types/components/FormRadio/FormRadio.d.ts +6 -9
- package/dist/cjs/types/components/FormRadio/FormRadio.stories.d.ts +4 -3
- package/dist/cjs/types/components/FormSelect/FormSelect.d.ts +5 -8
- package/dist/cjs/types/components/FormSelect/FormSelect.stories.d.ts +4 -3
- package/dist/cjs/types/components/FormSwitch/FormSwitch.d.ts +4 -7
- package/dist/cjs/types/components/FormSwitch/FormSwitch.stories.d.ts +1 -1
- package/dist/cjs/types/components/Input/Input.d.ts +3 -6
- package/dist/cjs/types/components/Input/Input.overrides.d.ts +1 -0
- package/dist/cjs/types/components/Radio/Radio.stories.d.ts +1 -1
- package/dist/cjs/types/components/Select/Select.stories.d.ts +3 -3
- package/dist/cjs/types/components/Switch/Switch.d.ts +2 -4
- package/dist/cjs/types/components/Switch/Switch.stories.d.ts +1 -2
- package/dist/cjs/types/components/Table/Table.d.ts +29 -0
- package/dist/cjs/types/components/Table/Table.overrides.d.ts +6 -0
- package/dist/cjs/types/components/Table/Table.stories.d.ts +6 -0
- package/dist/cjs/types/components/Table/Table.test.d.ts +1 -0
- package/dist/cjs/types/components/Tabs/Tabs.stories.d.ts +1 -1
- package/dist/cjs/types/components/Typography/Typography.d.ts +3 -4
- package/dist/cjs/types/components/Typography/Typography.stories.d.ts +1 -1
- package/dist/cjs/types/global/utils/types.d.ts +4 -6
- package/dist/cjs/types/index.d.ts +21 -1
- package/dist/esm/index.js +1 -1
- package/dist/esm/types/components/Box/Box.stories.d.ts +2 -2
- package/dist/esm/types/components/Button/Button.stories.d.ts +1 -0
- package/dist/esm/types/components/Checkbox/Checkbox.stories.d.ts +1 -1
- package/dist/esm/types/components/Chip/Chip.stories.d.ts +1 -1
- package/dist/esm/types/components/EmptyState/EmptyState.d.ts +3 -3
- package/dist/esm/types/components/EmptyState/EmptyState.stories.d.ts +3 -3
- package/dist/esm/types/components/Form/Form.stories.d.ts +5 -0
- package/dist/esm/types/components/FormCheckbox/FormCheckbox.d.ts +5 -8
- package/dist/esm/types/components/FormCheckbox/FormCheckbox.stories.d.ts +3 -3
- package/dist/esm/types/components/FormControl/FormControl.overrides.d.ts +3 -0
- package/dist/esm/types/components/FormInput/FormInput.d.ts +4 -8
- package/dist/esm/types/components/FormInput/FormInput.stories.d.ts +6 -3
- package/dist/esm/types/components/FormLabel/FormLabel.d.ts +8 -0
- package/dist/esm/types/components/FormLabel/FormLabel.test.d.ts +1 -0
- package/dist/esm/types/components/FormRadio/FormRadio.d.ts +6 -9
- package/dist/esm/types/components/FormRadio/FormRadio.stories.d.ts +4 -3
- package/dist/esm/types/components/FormSelect/FormSelect.d.ts +5 -8
- package/dist/esm/types/components/FormSelect/FormSelect.stories.d.ts +4 -3
- package/dist/esm/types/components/FormSwitch/FormSwitch.d.ts +4 -7
- package/dist/esm/types/components/FormSwitch/FormSwitch.stories.d.ts +1 -1
- package/dist/esm/types/components/Input/Input.d.ts +3 -6
- package/dist/esm/types/components/Input/Input.overrides.d.ts +1 -0
- package/dist/esm/types/components/Radio/Radio.stories.d.ts +1 -1
- package/dist/esm/types/components/Select/Select.stories.d.ts +3 -3
- package/dist/esm/types/components/Switch/Switch.d.ts +2 -4
- package/dist/esm/types/components/Switch/Switch.stories.d.ts +1 -2
- package/dist/esm/types/components/Table/Table.d.ts +29 -0
- package/dist/esm/types/components/Table/Table.overrides.d.ts +6 -0
- package/dist/esm/types/components/Table/Table.stories.d.ts +6 -0
- package/dist/esm/types/components/Table/Table.test.d.ts +1 -0
- package/dist/esm/types/components/Tabs/Tabs.stories.d.ts +1 -1
- package/dist/esm/types/components/Typography/Typography.d.ts +3 -4
- package/dist/esm/types/components/Typography/Typography.stories.d.ts +1 -1
- package/dist/esm/types/global/utils/types.d.ts +4 -6
- package/dist/esm/types/index.d.ts +21 -1
- package/dist/index.d.ts +61 -51
- package/package.json +1 -1
- package/dist/cjs/types/components/Select/Select.overrides.d.ts +0 -2
- package/dist/cjs/types/components/index.d.ts +0 -20
- package/dist/esm/types/components/Select/Select.overrides.d.ts +0 -2
- package/dist/esm/types/components/index.d.ts +0 -20
package/dist/esm/index.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{createTheme as e,CssBaseline as r,CircularProgress as o,Chip as t,Avatar as n,Container as i,Grid as a,Box as l,Checkbox as c,FormControl as d,FormLabel as s,FormGroup as f,FormControlLabel as m,FormHelperText as p,Radio as g,RadioGroup as u,Switch as h,Select as b,MenuItem as y,TextField as x,Link as v,SvgIcon as z,Tabs as E,Tab as k}from"@mui/material";export*from"@mui/material";import*as S from"react";import w,{useState as C}from"react";import{ThemeProvider as O,styled as T}from"@mui/material/styles";import M from"@mui/material/Button";import P from"@mui/material/Typography";import W from"@mui/material/InputAdornment";import L from"@mui/material/IconButton";import I from"@mui/icons-material/VisibilityOutlined";import F from"@mui/icons-material/VisibilityOffOutlined";import B from"@mui/icons-material/InfoOutlined";var H={animation:{speed:{normal:"0.5s",fast:"0.08s",slow:"1s"}},color:{background:{light:"#f4f5f7",dark:"#dfe1e6",indigo:"#262a59"},primary:"#262a59",secondary:"#d40fa9",info:"#262a59",error:"#e35656",success:"#aed581",indigo0:"#f4f4f6",indigo10:"#e9e9ee",indigo20:"#bdbfcd",indigo30:"#a8aabd",indigo40:"#9294ac",indigo50:"#7d7f9b",indigo60:"#67698a",indigo70:"#51557a",indigo80:"#3b3f69",indigo90:"#262a59",indigo100:"#161833",pink0:"#fff3ff",pink10:"#fedafd",pink20:"#fdc0fb",pink30:"#f98ef3",pink40:"#f362e8",pink50:"#ec3ed7",pink60:"#d40fa9",pink70:"#b0027c",pink80:"#990165",pink90:"#820050",pink100:"#390325",cyan0:"#f4ffff",cyan10:"#c6ffff",cyan20:"#96ffff",cyan30:"#59effc",cyan40:"#1dd7f0",cyan50:"#20b0c7",cyan60:"#1d8fa4",cyan70:"#167286",cyan80:"#0e5a6d",cyan90:"#064658",cyan100:"#103645",green0:"#f8fff4",green10:"#e2fccc",green20:"#e2fccc",green30:"#aed581",green40:"#8eaf65",green50:"#728f4b",green60:"#5a7533",green70:"#476020",green80:"#374e10",green90:"#2b3f05",green100:"#223300",red0:"#fff7f4",red10:"#ffe4db",red20:"#fcc4bb",red30:"#efa299",red40:"#e67e78",red50:"#e35656",red60:"#b83d3c",red70:"#922524",red80:"#6f1110",red90:"#500404",red100:"#330000",gray0:"#ffffff",gray10:"#f4f5f7",gray20:"#dfe1e6",gray30:"#c1c7d0",gray40:"#a8afba",gray50:"#9399a3",gray60:"#777c85",gray70:"#575b61",gray80:"#3c3e42",gray90:"#222426",gray100:"#121315",border:{default:"#dfe1e6"},shadow:{default:"#121315"},text:{base:"#121315",light:"#9399a3",inverted:"#ffffff",link:{default:"#20b0c7",visited:"#1d8fa4"}}},font:{family:{heading:"'Roboto Condensed', sans-serif",text:"'Source Sans Pro', sans-serif",code:"'Source Code Pro', monospace"},lineHeight:{medium:"1rem",large:"1.5rem",xlarge:"2rem",xxlarge:"3rem"},weight:{normal:400,bold:700}},size:{border:{radius:{default:"6px",small:"4px"},width:"1px"},font:{base:"16px",heading:{default:"1.728rem",small:"1.44rem",xsmall:"1rem"},overline:{large:"1.44rem",default:"0.833rem"},body:{default:"1rem"},caption:{default:"0.833rem",large:"1.44rem"},label:{default:"0.833rem",large:"1.44rem"},minorThird10:"6.192rem",minorThird9:"5.16rem",minorThird8:"4.3rem",minorThird7:"3.583rem",minorThird6:"2.986rem",minorThird5:"2.488rem",minorThird4:"2.074rem",minorThird3:"1.728rem",minorThird2:"1.44rem",minorThird1:"1.2rem",minorThird0:"1rem",minorThirdSub1:"0.833rem",minorThirdSub2:"0.694rem",minorThirdSub3:"0.579rem",minorThirdSub4:"0.482rem",minorThirdSub5:"0.402rem",minorThirdSub6:"0.335rem"},spacingXS:"8px",spacingS:"16px",spacingM:"24px",spacingL:"32px",spacingXL:"40px",spacingXXL:"48px",spacing:{main:"24px",section:"32px",header:"24px",article:"24px",paragraph:"16px",line:"8px",scale1:"1px",scale2:"2px",scale4:"4px",scale6:"6px",scale8:"8px",scale16:"16px",scale24:"24px",scale32:"32px",scale40:"40px",scale48:"48px",scale56:"56px",scale64:"64px",scale72:"72px",scale80:"80px",scale88:"88px",scale96:"96px",scale104:"104px",scale112:"112px",scale120:"120px",scale128:"128px",scale160:"160px",scale208:"208px"}}},j=function(){return j=Object.assign||function(e){for(var r,o=1,t=arguments.length;o<t;o++)for(var n in r=arguments[o])Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n]);return e},j.apply(this,arguments)};function R(e,r){var o={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&r.indexOf(t)<0&&(o[t]=e[t]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(t=Object.getOwnPropertySymbols(e);n<t.length;n++)r.indexOf(t[n])<0&&Object.prototype.propertyIsEnumerable.call(e,t[n])&&(o[t[n]]=e[t[n]])}return o}var $={styleOverrides:{root:{fontSize:"12px",fontWeight:600,fontFamily:H.font.family.text,"& .MuiChip-icon":{width:"12px",height:"12px",marginLeft:H.size.spacing.scale8}},colorDefault:{backgroundColor:H.color.gray10,color:H.color.gray60},colorPrimary:{backgroundColor:H.color.indigo10,color:H.color.indigo80},colorSecondary:{backgroundColor:H.color.pink10,color:H.color.pink80},colorError:{backgroundColor:H.color.red10,color:H.color.error},colorInfo:{backgroundColor:H.color.indigo10,color:H.color.indigo80},colorSuccess:{backgroundColor:H.color.green10,color:H.color.green80}}},A={h1:{fontFamily:H.font.family.heading,fontSize:H.size.font.heading.default,fontWeight:H.font.weight.bold,lineHeight:H.font.lineHeight.xlarge},h2:{fontFamily:H.font.family.heading,fontSize:H.size.font.heading.small,fontWeight:H.font.weight.bold,lineHeight:H.font.lineHeight.xlarge},h3:{fontFamily:H.font.family.heading,fontSize:H.size.font.heading.xsmall,fontWeight:H.font.weight.bold,lineHeight:H.font.lineHeight.large},body1:{fontFamily:H.font.family.text,fontSize:H.size.font.body.default,fontWeight:H.font.weight.normal,lineHeight:H.font.lineHeight.large},body2:{fontFamily:H.font.family.text,fontSize:H.size.font.body.default,fontWeight:H.font.weight.bold,lineHeight:H.font.lineHeight.large},caption:{fontFamily:H.font.family.text,fontSize:H.size.font.caption.default,fontWeight:H.font.weight.normal,lineHeight:H.font.lineHeight.medium},overline:{fontFamily:H.font.family.heading,fontSize:H.size.font.overline.default,letterSpacing:"initial",fontWeight:H.font.weight.bold,color:H.color.gray60}},N={small:"".concat(H.size.spacing.scale4," ").concat(H.size.spacing.scale8),medium:"".concat(H.size.spacing.scale8," ").concat(H.size.spacing.scale16),large:"".concat(H.size.spacing.scale16," ").concat(H.size.spacing.scale32)},q={styleOverrides:{root:{textTransform:"none",lineHeight:H.size.spacing.scale16,fontWeight:H.font.weight.bold,fontFamily:H.font.family.text},contained:{padding:N.medium},containedSizeSmall:{padding:N.small},containedSizeLarge:{padding:N.large},text:{padding:N.medium},textSizeSmall:{padding:N.small},textSizeLarge:{padding:N.large},outlined:{padding:"7px ".concat(H.size.spacing.scale16)},outlinedSizeSmall:{padding:N.small},outlinedSizeLarge:{padding:N.large},sizeSmall:{fontSize:H.size.font.label.default},sizeLarge:{fontSize:H.size.font.label.large},startIcon:{"& svg":{fill:"currentColor",width:"12px",height:"12px"}},endIcon:{"& svg":{fill:"currentColor",width:"12px",height:"12px"}}},defaultProps:{disableFocusRipple:!0},MuiIconButton:{root:{"&&:hover":{backgroundColor:"transparent"}}}},V={styleOverrides:{root:{color:H.color.gray60,backgroundColor:H.color.background.dark},sizeSmall:{padding:"3px"}}},D={styleOverrides:{root:{fontFamily:H.font.family.text,fontSize:H.size.font.label.default,fontWeight:H.font.weight.bold,width:H.size.spacing.scale24,height:H.size.spacing.scale24,"& .MuiSvgIcon-root":{width:H.size.spacing.scale16}},colorDefault:{backgroundColor:H.color.background.dark,"& .MuiSvgIcon-root":{color:H.color.gray60}}}},X={styleOverrides:{root:{paddingTop:4,paddingBottom:4,color:H.color.border.default,"& svg":{width:"16px",height:"16px"},"&&:hover":{backgroundColor:"transparent"}},colorPrimary:{"&$checked":{"&&:hover":{backgroundColor:"transparent"}}},colorSecondary:{"&$checked":{color:H.color.primary},"&$disabled":{opacity:.5}}}},G={styleOverrides:{root:{paddingTop:4,paddingBottom:4,color:H.color.border.default,"& svg":{width:"16px",height:"16px"},"&:hover":{background:"none"}}}},U={styleOverrides:{root:{marginRight:16},colorSecondary:{color:H.color.gray0,"&$checked":{color:H.color.gray0,left:2,"&:hover":{backgroundColor:"transparent"}},"&$disabled":{color:H.color.gray0}},track:{position:"absolute",width:48,height:24,borderRadius:12,opacity:1,left:"calc(50% - 48px/2)",top:"calc(50% - 24px/2)",backgroundColor:H.color.background.light,border:"2px solid ".concat(H.color.border.default),boxSizing:"border-box","$checked$checked + &":{opacity:1,backgroundColor:H.color.primary,border:"2px solid ".concat(H.color.primary)},"$disabled$disabled + &":{opacity:.5,cursor:"not-allowed"}},thumb:{boxShadow:"none"}}},_={styleOverrides:{outlined:{position:"relative",padding:H.size.spacing.scale8,fontSize:H.size.font.label.default,borderRadius:H.size.spacing.scale6,width:"100%","&.Mui-disabled":{backgroundColor:H.color.background.dark,color:H.color.text.light}}}},J={styleOverrides:{root:{input:{padding:H.size.spacing.scale8,fontSize:H.size.font.label.default,height:H.size.spacing.scale16},"& .MuiInputAdornment-root":{button:{padding:"0 ".concat(H.size.spacing.scale8," 0 0"),backgroundColor:"transparent"},svg:{width:H.size.spacing.scale16,height:H.size.spacing.scale16}}}}},K={styleOverrides:{outlined:{notchedOutline:{borderColor:H.color.border.default}},root:{underline:{"&:before":{borderBottom:"none"},"&:after":{borderBottom:"none"},"&:hover":{borderBottom:"none"},"&&:hover::before":{border:"none"}}}}},Q={styleOverrides:{root:{borderBottom:"1px solid ".concat(H.color.gray20)},indicator:{backgroundColor:H.color.primary}}},Y={styleOverrides:{textColorPrimary:{textTransform:"none",minWidth:"auto",fontWeight:700,marginRight:"".concat(H.size.spacing.scale16),fontFamily:H.font.family.text,color:H.color.gray60,padding:"0 0 ".concat(H.size.spacing.scale16," 0"),"&:hover":{color:H.color.primary,opacity:1},"&$selected":{color:H.color.primary},"&:focus":{color:H.color.primary}}},defaultProps:{disableRipple:!0}};H.size.font.body.default,H.font.family.text,H.color.gray100,H.size.font.caption.default;var Z,ee,re,oe,te={styleOverrides:{root:{fontWeight:H.font.weight.bold,lineHeight:H.font.lineHeight.medium,fontFamily:H.font.family.text,fontSize:H.size.font.caption.default,color:H.color.text.base,marginBottom:H.size.spacing.scale8}}},ne=e({typography:j({},A),palette:{background:{default:"#ffffff"},primary:{main:H.color.primary},secondary:{main:H.color.secondary},error:{main:H.color.error},info:{main:H.color.info},success:{main:H.color.success}},components:{MuiButton:q,MuiButtonBase:{defaultProps:{disableRipple:!0,disableTouchRipple:!0}},MuiContainer:{styleOverrides:{maxWidthLg:{"@media (min-width: 1280px)":{maxWidth:"1185px"}}}},MuiIconButton:V,MuiChip:$,MuiInput:K,MuiTextField:J,MuiFormLabel:te,MuiTabs:Q,MuiTab:Y,MuiAvatar:D,MuiCheckbox:X,MuiRadio:G,MuiSwitch:U,MuiSelect:_,MuiLink:{styleOverrides:{root:{cursor:"pointer"}}},MuiDivider:{styleOverrides:{root:{margin:"16px 0"}}},MuiFormControl:{styleOverrides:{root:{width:"100%"}}}}}),ie=function(e){return w.createElement(w.Fragment,null,w.createElement(r,null),w.createElement(O,{theme:ne},e.children))},ae=T(o)(re||(Z=["\n position: absolute;\n width: 100%;\n height: 100%;\n z-index: 2;\n display: flex;\n align-items: center;\n justify-content: center;\n"],ee=["\n position: absolute;\n width: 100%;\n height: 100%;\n z-index: 2;\n display: flex;\n align-items: center;\n justify-content: center;\n"],Object.defineProperty?Object.defineProperty(Z,"raw",{value:ee}):Z.raw=ee,re=Z)),le=function(e){var r=e.color,o=void 0===r?"primary":r,t=e.variant,n=void 0===t?"contained":t,i=e.size,a=void 0===i?"medium":i,l=e.loading,c=e.children,d=R(e,["color","variant","size","loading","children"]);return w.createElement(M,j({size:a,variant:n,color:o,disabled:l},d),w.createElement("span",{style:{opacity:l?0:1}},c),l&&w.createElement(ae,{size:20,color:"inherit"}))},ce=function(e){var r=e.children,o=R(e,["children"]);return w.createElement(P,j({},o),r)},de=function(e){var r=e.label,o=R(e,["label"]);return w.createElement(t,j({size:"small",label:r},o))},se=function(e){var r=e.icon,o=e.firstName,t=void 0===o?"":o,i=e.lastName,a=void 0===i?"":i,l=R(e,["icon","firstName","lastName"]),c="".concat(t.substring(0,1)).concat(a.substring(0,1)).toLocaleUpperCase(),d=c?H.color.secondary:H.color.background.dark;return w.createElement(n,j({sx:j({backgroundColor:d},l.sx)},l),c||r)},fe={small:6,medium:8,large:12,fluid:12},me=function(e){var r=e.component,o=void 0===r?"div":r,t=e.size,n=void 0===t?"large":t,l=e.children,c=R(e,["component","size","children"]),d="fluid"===n;return w.createElement(i,j({component:o,disableGutters:d,maxWidth:!d&&"lg",sx:j({display:"flex",justifyContent:"center"},c.sx)},c),w.createElement(a,{container:!0,justifyContent:"center"},w.createElement(a,{item:!0,md:fe[n]},l)))},pe=function(e){var r=e.children,o=R(e,["children"]);return w.createElement(l,j({},o),r)},ge=function(e){var r=R(e,[]);return w.createElement(c,j({},r))},ue=function(e){var r=e.id,o=e.required,t=void 0===o||o,n=e.data,i=e.label,a=e.error,c=e.helperText;return w.createElement(d,null,w.createElement(s,{component:"label",error:a},i," ",t?"":w.createElement(l,{component:"span",sx:{fontWeight:H.font.weight.normal,color:H.color.text.light}},"(optional)")),w.createElement(f,null,n.map((function(e,o){var t=e.value,n=e.label;return w.createElement(m,{key:o,value:t,label:n||"",sx:{fontSize:H.size.font.base,color:H.color.text.base},control:w.createElement(ge,{color:"primary",inputProps:{"data-testid":"".concat(r,"-").concat(o)}})})}))),a&&w.createElement(p,{sx:{marginLeft:0,marginRight:0},error:a},c))},he=function(e){return w.createElement(g,j({},e))},be=function(e){var r=e.id,o=e.helperText,t=e.label,n=e.error,i=e.required,a=void 0===i||i,c=e.name,f=e.data;return w.createElement(d,{component:"fieldset",error:n},w.createElement(s,{component:"legend"},t," ",a?"":w.createElement(l,{component:"span",sx:{fontWeight:H.font.weight.normal,color:H.color.text.light}},"(optional)")),w.createElement(u,{"aria-label":c,name:c},f.map((function(e,o){var t=e.value,n=e.label;return w.createElement(m,{value:t,key:t,label:n||"",sx:{fontSize:H.size.font.base,color:H.color.text.base},control:w.createElement(he,{color:"primary",inputProps:{"data-testid":"".concat(r,"-").concat(o)}})})}))),n&&w.createElement(p,{sx:{marginLeft:0,marginRight:0}},o))},ye=function(e){return w.createElement(h,j({},e))},xe=function(e){var r=e.id,o=e.label,t=e.checked;return w.createElement(d,null,w.createElement(s,{component:"label"},o),w.createElement(m,{control:w.createElement(ye,{id:r}),label:"".concat(t?"Active":"Inactive")}))},ve=function(e){return w.createElement(b,j({variant:"outlined"},e))},ze=function(e){var r=e.id,o=e.required,t=void 0===o||o,n=e.options,i=e.label,a=e.error,c=e.placeholder,f=e.helperText,m=e.value;return w.createElement(d,null,w.createElement(s,{component:"label",error:a},i," ",t?"":w.createElement(l,{component:"span",sx:{fontWeight:H.font.weight.normal,color:H.color.text.light}},"(optional)")),w.createElement(ve,{id:r,placeholder:c,error:a,value:m},n.map((function(e){return w.createElement(y,{key:e.value,value:e.value},e.text)}))),a&&w.createElement(p,{sx:{marginLeft:0,marginRight:0},error:a},f))},Ee=function(e){var r=e.type,o=R(e,["type"]),t=C(!1),n=t[0],i=t[1],a=j(j({},o.InputProps),"password"===r&&{endAdornment:w.createElement(W,{position:"end"},w.createElement(L,{"aria-label":"toggle password visibility",onClick:function(){return i(!n)},edge:"end"},n?w.createElement(I,null):w.createElement(F,null)))});return w.createElement(x,j({},o,{type:n?"text":r,InputProps:a}))},ke=function(e){var r=e.id,o=e.required,t=void 0===o||o,n=e.label,i=e.error,a=e.helperText,c=R(e,["id","required","label","error","helperText"]);return w.createElement(d,null,w.createElement(s,{component:"label",error:i},n," ",!t&&w.createElement(l,{component:"span",sx:{fontWeight:H.font.weight.normal,color:H.color.text.light}},"(optional)")),w.createElement(Ee,j({},c,{id:r,error:i,inputProps:{"data-testid":r}})),i&&w.createElement(p,{sx:{marginLeft:0,marginRight:0},error:i},a))};function Se(){return Se=Object.assign||function(e){for(var r=1;r<arguments.length;r++){var o=arguments[r];for(var t in o)Object.prototype.hasOwnProperty.call(o,t)&&(e[t]=o[t])}return e},Se.apply(this,arguments)}var we=function(e){return S.createElement("svg",Se({viewBox:"0 0 24 24"},e),oe||(oe=S.createElement("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M12.141 4.894H3.576A1.977 1.977 0 0 0 1.6 6.871v14.494c0 1.09.885 1.976 1.976 1.976h14.495a1.977 1.977 0 0 0 1.976-1.976V12.8M17.412 1.6h4.94a.99.99 0 0 1 .99.988V7.53m-10.883 4.952L23.05 1.89"})))},Ce=function(e){var r,o=e.children,t=e.underline,n=void 0===t?"hover":t,i=e.toParentNavigation,a=R(e,["children","underline","toParentNavigation"]),l=null===(r=a.href)||void 0===r?void 0:r.startsWith("https"),c={variant:"caption",underline:n};return i?w.createElement(v,j({},c,a,{onClick:function(){return e=i,void window.parent.postMessage({type:"NAVIGATION",content:e},"*");var e}}),o):w.createElement(v,j({},c,l&&{target:"_blank",rel:"noopener noreferrer"},a),o,l&&w.createElement(z,{component:we,fontSize:"inherit",sx:{marginLeft:".25em"}}))},Oe=function(e){var r=e.children,o=R(e,["children"]);return w.createElement(E,j({},o),r)},Te=function(e){var r=e.children,o=R(e,["children"]);return w.createElement(k,j({},o),r)},Me=function(e){var r=e.children,o=e.value,t=void 0===o?0:o,n=e.index,i=e.id;return w.createElement(pe,{role:"tabpanel",hidden:t!==n,id:i},r)},Pe=function(e){var r=e.tabs,o=e.nameSpace,t=e.tabContentProps,n=e.tabsProps,i=C(0),a=i[0],l=i[1],c=o?"".concat(o,"-"):"";return w.createElement(w.Fragment,null,w.createElement(Oe,j({},n,{value:a,onChange:function(e,r){l(r)}}),r.map((function(e,r){return w.createElement(Te,{key:"".concat(c,"tab-").concat(r),label:e.label,"aria-controls":"".concat(c,"panel-").concat(r)})}))),w.createElement(pe,j({},t),r.map((function(e,r){var o="".concat(c,"panel-").concat(r);return w.createElement(Me,{key:o,value:a,index:r,id:o,"aria-labelledby":"".concat(c,"tab-").concat(r)},e.content)}))))},We=function(e){var r=e.icon,o=e.title,t=e.subTitle,n=e.action,i=R(e,["icon","title","subTitle","action"]);return w.createElement(l,j({p:4,display:"flex",flexDirection:"column",alignItems:"center"},i),w.createElement(z,{component:null!=r?r:B,sx:{marginBottom:H.size.spacing.scale24,fontSize:H.size.spacing.scale104,color:H.color.gray20}}),w.createElement(ce,{variant:"h1",component:"span",mb:2},o),w.createElement(ce,{variant:"body1",color:H.color.gray60,mb:3},t),n)};export{se as Avatar,pe as Box,le as Button,ge as Checkbox,de as Chip,me as Container,We as EmptyState,ue as FormCheckbox,ke as FormInput,be as FormRadio,ze as FormSelect,xe as FormSwitch,Ee as Input,Ce as Link,he as Radio,ve as Select,ye as Switch,Te as Tab,Pe as TabGroup,Oe as Tabs,ce as Typography,ie as UpComponentsProvider,ne as theme,H as tokens};
|
|
1
|
+
import{createTheme as e,CssBaseline as r,CircularProgress as o,Chip as t,Avatar as n,Container as i,Grid as a,Box as l,Checkbox as c,FormLabel as d,FormControl as s,FormGroup as m,FormControlLabel as f,FormHelperText as u,Radio as p,RadioGroup as g,Switch as h,Select as b,MenuItem as y,TextField as x,Link as v,SvgIcon as E,Tabs as z,Tab as k}from"@mui/material";export*from"@mui/material";import*as T from"react";import S,{useState as w}from"react";import{ThemeProvider as C,styled as O}from"@mui/material/styles";import M from"@mui/material/Button";import F from"@mui/material/Typography";import P from"@mui/material/InputAdornment";import W from"@mui/material/IconButton";import L from"@mui/icons-material/VisibilityOutlined";import B from"@mui/icons-material/VisibilityOffOutlined";import I from"@mui/icons-material/InfoOutlined";import H from"@mui/material/Table";import j from"@mui/material/TableBody";import q from"@mui/material/TableCell";import R from"@mui/material/TableContainer";import $ from"@mui/material/TableHead";import A from"@mui/material/TableRow";import N from"@mui/material/TablePagination";import V from"@mui/material/TableSortLabel";import D from"@mui/material/TableFooter";var X={animation:{speed:{normal:"0.5s",fast:"0.08s",slow:"1s"}},color:{background:{light:"#f4f5f7",dark:"#dfe1e6",indigo:"#262a59"},primary:"#262a59",secondary:"#d40fa9",info:"#262a59",error:"#e35656",success:"#aed581",indigo0:"#f4f4f6",indigo10:"#e9e9ee",indigo20:"#bdbfcd",indigo30:"#a8aabd",indigo40:"#9294ac",indigo50:"#7d7f9b",indigo60:"#67698a",indigo70:"#51557a",indigo80:"#3b3f69",indigo90:"#262a59",indigo100:"#161833",pink0:"#fff3ff",pink10:"#fedafd",pink20:"#fdc0fb",pink30:"#f98ef3",pink40:"#f362e8",pink50:"#ec3ed7",pink60:"#d40fa9",pink70:"#b0027c",pink80:"#990165",pink90:"#820050",pink100:"#390325",cyan0:"#f4ffff",cyan10:"#c6ffff",cyan20:"#96ffff",cyan30:"#59effc",cyan40:"#1dd7f0",cyan50:"#20b0c7",cyan60:"#1d8fa4",cyan70:"#167286",cyan80:"#0e5a6d",cyan90:"#064658",cyan100:"#103645",green0:"#f8fff4",green10:"#e2fccc",green20:"#e2fccc",green30:"#aed581",green40:"#8eaf65",green50:"#728f4b",green60:"#5a7533",green70:"#476020",green80:"#374e10",green90:"#2b3f05",green100:"#223300",red0:"#fff7f4",red10:"#ffe4db",red20:"#fcc4bb",red30:"#efa299",red40:"#e67e78",red50:"#e35656",red60:"#b83d3c",red70:"#922524",red80:"#6f1110",red90:"#500404",red100:"#330000",gray0:"#ffffff",gray10:"#f4f5f7",gray20:"#dfe1e6",gray30:"#c1c7d0",gray40:"#a8afba",gray50:"#9399a3",gray60:"#777c85",gray70:"#575b61",gray80:"#3c3e42",gray90:"#222426",gray100:"#121315",border:{default:"#dfe1e6"},shadow:{default:"#121315"},text:{base:"#121315",light:"#9399a3",inverted:"#ffffff",link:{default:"#20b0c7",visited:"#1d8fa4"}}},font:{family:{heading:"'Roboto Condensed', sans-serif",text:"'Source Sans Pro', sans-serif",code:"'Source Code Pro', monospace"},lineHeight:{medium:"1rem",large:"1.5rem",xlarge:"2rem",xxlarge:"3rem"},weight:{normal:400,bold:700}},size:{border:{radius:{default:"6px",small:"4px"},width:"1px"},font:{base:"16px",heading:{default:"1.728rem",small:"1.44rem",xsmall:"1rem"},overline:{large:"1.44rem",default:"0.833rem"},body:{default:"1rem"},caption:{default:"0.833rem",large:"1.44rem"},label:{default:"0.833rem",large:"1.44rem"},minorThird10:"6.192rem",minorThird9:"5.16rem",minorThird8:"4.3rem",minorThird7:"3.583rem",minorThird6:"2.986rem",minorThird5:"2.488rem",minorThird4:"2.074rem",minorThird3:"1.728rem",minorThird2:"1.44rem",minorThird1:"1.2rem",minorThird0:"1rem",minorThirdSub1:"0.833rem",minorThirdSub2:"0.694rem",minorThirdSub3:"0.579rem",minorThirdSub4:"0.482rem",minorThirdSub5:"0.402rem",minorThirdSub6:"0.335rem"},spacingXS:"8px",spacingS:"16px",spacingM:"24px",spacingL:"32px",spacingXL:"40px",spacingXXL:"48px",spacing:{main:"24px",section:"32px",header:"24px",article:"24px",paragraph:"16px",line:"8px",scale1:"1px",scale2:"2px",scale4:"4px",scale6:"6px",scale8:"8px",scale16:"16px",scale24:"24px",scale32:"32px",scale40:"40px",scale48:"48px",scale56:"56px",scale64:"64px",scale72:"72px",scale80:"80px",scale88:"88px",scale96:"96px",scale104:"104px",scale112:"112px",scale120:"120px",scale128:"128px",scale160:"160px",scale208:"208px"}}},G=function(){return G=Object.assign||function(e){for(var r,o=1,t=arguments.length;o<t;o++)for(var n in r=arguments[o])Object.prototype.hasOwnProperty.call(r,n)&&(e[n]=r[n]);return e},G.apply(this,arguments)};function U(e,r){var o={};for(var t in e)Object.prototype.hasOwnProperty.call(e,t)&&r.indexOf(t)<0&&(o[t]=e[t]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var n=0;for(t=Object.getOwnPropertySymbols(e);n<t.length;n++)r.indexOf(t[n])<0&&Object.prototype.propertyIsEnumerable.call(e,t[n])&&(o[t[n]]=e[t[n]])}return o}var _={styleOverrides:{root:{fontSize:"12px",fontWeight:600,fontFamily:X.font.family.text,"& .MuiChip-icon":{width:"12px",height:"12px",marginLeft:X.size.spacing.scale8}},colorDefault:{backgroundColor:X.color.gray10,color:X.color.gray60},colorPrimary:{backgroundColor:X.color.indigo10,color:X.color.indigo80},colorSecondary:{backgroundColor:X.color.pink10,color:X.color.pink80},colorError:{backgroundColor:X.color.red10,color:X.color.error},colorInfo:{backgroundColor:X.color.indigo10,color:X.color.indigo80},colorSuccess:{backgroundColor:X.color.green10,color:X.color.green80}}},J={h1:{fontFamily:X.font.family.heading,fontSize:X.size.font.heading.default,fontWeight:X.font.weight.bold,lineHeight:X.font.lineHeight.xlarge},h2:{fontFamily:X.font.family.heading,fontSize:X.size.font.heading.small,fontWeight:X.font.weight.bold,lineHeight:X.font.lineHeight.xlarge},h3:{fontFamily:X.font.family.heading,fontSize:X.size.font.heading.xsmall,fontWeight:X.font.weight.bold,lineHeight:X.font.lineHeight.large},body1:{fontFamily:X.font.family.text,fontSize:X.size.font.body.default,fontWeight:X.font.weight.normal,lineHeight:X.font.lineHeight.large},body2:{fontFamily:X.font.family.text,fontSize:X.size.font.body.default,fontWeight:X.font.weight.bold,lineHeight:X.font.lineHeight.large},caption:{fontFamily:X.font.family.text,fontSize:X.size.font.caption.default,fontWeight:X.font.weight.normal,lineHeight:X.font.lineHeight.medium},overline:{fontFamily:X.font.family.heading,fontSize:X.size.font.overline.default,letterSpacing:"initial",fontWeight:X.font.weight.bold,color:X.color.gray60}},K={small:"".concat(X.size.spacing.scale4," ").concat(X.size.spacing.scale8),medium:"".concat(X.size.spacing.scale8," ").concat(X.size.spacing.scale16),large:"".concat(X.size.spacing.scale16," ").concat(X.size.spacing.scale32)},Q={styleOverrides:{root:{textTransform:"none",lineHeight:X.size.spacing.scale16,fontWeight:X.font.weight.bold,fontFamily:X.font.family.text},contained:{padding:K.medium,color:X.color.gray0},containedSuccess:{backgroundColor:X.color.green60},containedSizeSmall:{padding:K.small},containedSizeLarge:{padding:K.large},text:{padding:K.medium},textSizeSmall:{padding:K.small},textSizeLarge:{padding:K.large},outlined:{padding:"7px ".concat(X.size.spacing.scale16)},outlinedSizeSmall:{padding:K.small},outlinedSizeLarge:{padding:K.large},sizeSmall:{fontSize:X.size.font.label.default},sizeLarge:{fontSize:X.size.font.label.large},startIcon:{"& svg":{fill:"currentColor",width:"12px",height:"12px"}},endIcon:{"& svg":{fill:"currentColor",width:"12px",height:"12px"}}},defaultProps:{disableFocusRipple:!0},MuiIconButton:{root:{"&&:hover":{backgroundColor:"transparent"}}}},Y={styleOverrides:{root:{color:X.color.gray60,backgroundColor:X.color.background.dark},sizeSmall:{padding:"3px"}}},Z={styleOverrides:{root:{fontFamily:X.font.family.text,fontSize:X.size.font.label.default,fontWeight:X.font.weight.bold,width:X.size.spacing.scale24,height:X.size.spacing.scale24,"& .MuiSvgIcon-root":{width:X.size.spacing.scale16}},colorDefault:{backgroundColor:X.color.background.dark,"& .MuiSvgIcon-root":{color:X.color.gray60}}}},ee={styleOverrides:{root:{paddingTop:4,paddingBottom:4,color:X.color.border.default,"& svg":{width:"16px",height:"16px"},"&&:hover":{backgroundColor:"transparent"}},colorPrimary:{"&$checked":{"&&:hover":{backgroundColor:"transparent"}}},colorSecondary:{"&$checked":{color:X.color.primary},"&$disabled":{opacity:.5}}}},re={styleOverrides:{root:{paddingTop:4,paddingBottom:4,color:X.color.border.default,"& svg":{width:"16px",height:"16px"},"&:hover":{background:"none"}}}},oe={styleOverrides:{root:{marginRight:16},colorSecondary:{color:X.color.gray0,"&$checked":{color:X.color.gray0,left:2,"&:hover":{backgroundColor:"transparent"}},"&$disabled":{color:X.color.gray0}},track:{position:"absolute",width:48,height:24,borderRadius:12,opacity:1,left:"calc(50% - 48px/2)",top:"calc(50% - 24px/2)",backgroundColor:X.color.background.light,border:"2px solid ".concat(X.color.border.default),boxSizing:"border-box","$checked$checked + &":{opacity:1,backgroundColor:X.color.primary,border:"2px solid ".concat(X.color.primary)},"$disabled$disabled + &":{opacity:.5,cursor:"not-allowed"}},thumb:{boxShadow:"none"}}},te={styleOverrides:{root:{"& .MuiInputAdornment-root":{button:{padding:"0 ".concat(X.size.spacing.scale8," 0 0"),backgroundColor:"transparent"},svg:{width:X.size.spacing.scale16,height:X.size.spacing.scale16}}}}},ne={styleOverrides:{input:{"&.Mui-disabled":{backgroundColor:X.color.background.dark,color:X.color.text.light}}},defaultProps:{size:"small"}},ie={styleOverrides:{outlined:{notchedOutline:{borderColor:X.color.border.default}},root:{underline:{"&:before":{borderBottom:"none"},"&:after":{borderBottom:"none"},"&:hover":{borderBottom:"none"},"&&:hover::before":{border:"none"}}}}},ae={styleOverrides:{root:{width:"100%","& .MuiFormHelperText-root":{marginTop:X.size.spacing.scale8,marginLeft:0}}}},le={styleOverrides:{root:{fontSize:X.size.font.base,color:X.color.text.base}}},ce={styleOverrides:{root:{borderBottom:"1px solid ".concat(X.color.gray20)},indicator:{backgroundColor:X.color.primary}}},de={styleOverrides:{textColorPrimary:{textTransform:"none",minWidth:"auto",fontWeight:700,marginRight:"".concat(X.size.spacing.scale16),fontFamily:X.font.family.text,color:X.color.gray60,padding:"0 0 ".concat(X.size.spacing.scale16," 0"),"&:hover":{color:X.color.primary,opacity:1},"&$selected":{color:X.color.primary},"&:focus":{color:X.color.primary}}},defaultProps:{disableRipple:!0}},se={styleOverrides:{root:{fontWeight:X.font.weight.normal}}},me={styleOverrides:{root:{fontWeight:X.font.weight.normal},head:{fontWeight:X.font.weight.bold}}},fe={styleOverrides:{root:{borderTop:"1px solid ".concat(X.color.border.default)}}},ue={styleOverrides:{root:{borderBottom:"none","& .MuiIconButton-root":{backgroundColor:"transparent"}},selectLabel:{fontWeight:X.font.weight.normal,fontSize:X.size.font.caption.default},displayedRows:{fontWeight:X.font.weight.normal,fontSize:X.size.font.caption.default}}};X.size.font.body.default,X.font.family.text,X.color.gray100,X.size.font.caption.default;var pe,ge,he,be,ye={styleOverrides:{root:{fontWeight:X.font.weight.bold,lineHeight:X.font.lineHeight.medium,fontFamily:X.font.family.text,fontSize:X.size.font.caption.default,color:X.color.text.base,marginBottom:X.size.spacing.scale8}}},xe=e({typography:G({},J),palette:{background:{default:"#ffffff"},primary:{main:X.color.primary},secondary:{main:X.color.secondary},error:{main:X.color.error},info:{main:X.color.info},success:{main:X.color.success}},components:{MuiButton:Q,MuiButtonBase:{defaultProps:{disableRipple:!0,disableTouchRipple:!0}},MuiContainer:{styleOverrides:{maxWidthLg:{"@media (min-width: 1280px)":{maxWidth:"1185px"}}}},MuiIconButton:Y,MuiChip:_,MuiInput:ie,MuiInputBase:ne,MuiFormControl:ae,MuiFormControlLabel:le,MuiTextField:te,MuiFormLabel:ye,MuiTabs:ce,MuiTab:de,MuiAvatar:Z,MuiCheckbox:ee,MuiRadio:re,MuiSwitch:oe,MuiLink:{styleOverrides:{root:{cursor:"pointer"}}},MuiTable:se,MuiTableCell:me,MuiTableRow:{styleOverrides:{root:{"&:last-child td":{borderBottom:0}}}},MuiTableFooter:fe,MuiTablePagination:ue,MuiDivider:{styleOverrides:{root:{margin:"16px 0"}}}}}),ve=function(e){return S.createElement(S.Fragment,null,S.createElement(r,null),S.createElement(C,{theme:xe},e.children))},Ee=O(o)(he||(pe=["\n position: absolute;\n width: 100%;\n height: 100%;\n z-index: 2;\n display: flex;\n align-items: center;\n justify-content: center;\n"],ge=["\n position: absolute;\n width: 100%;\n height: 100%;\n z-index: 2;\n display: flex;\n align-items: center;\n justify-content: center;\n"],Object.defineProperty?Object.defineProperty(pe,"raw",{value:ge}):pe.raw=ge,he=pe)),ze=function(e){var r=e.color,o=void 0===r?"primary":r,t=e.variant,n=void 0===t?"contained":t,i=e.size,a=void 0===i?"medium":i,l=e.loading,c=e.children,d=U(e,["color","variant","size","loading","children"]);return S.createElement(M,G({size:a,variant:n,color:o,disabled:l},d),S.createElement("span",{style:{opacity:l?0:1}},c),l&&S.createElement(Ee,{size:20,color:"inherit"}))},ke=function(e){var r=e.children,o=U(e,["children"]);return S.createElement(F,G({},o),r)},Te=function(e){var r=e.label,o=U(e,["label"]);return S.createElement(t,G({size:"small",label:r},o))},Se=function(e){var r=e.icon,o=e.firstName,t=void 0===o?"":o,i=e.lastName,a=void 0===i?"":i,l=U(e,["icon","firstName","lastName"]),c="".concat(t.substring(0,1)).concat(a.substring(0,1)).toLocaleUpperCase(),d=c?X.color.secondary:X.color.background.dark;return S.createElement(n,G({sx:G({backgroundColor:d},l.sx)},l),c||r)},we={small:6,medium:8,large:12,fluid:12},Ce=function(e){var r=e.component,o=void 0===r?"div":r,t=e.size,n=void 0===t?"large":t,l=e.children,c=U(e,["component","size","children"]),d="fluid"===n;return S.createElement(i,G({component:o,disableGutters:d,maxWidth:!d&&"lg",sx:G({display:"flex",justifyContent:"center"},c.sx)},c),S.createElement(a,{container:!0,justifyContent:"center"},S.createElement(a,{item:!0,md:we[n]},l)))},Oe=function(e){var r=e.children,o=U(e,["children"]);return S.createElement(l,G({},o),r)},Me=function(e){var r=U(e,[]);return S.createElement(c,G({},r))},Fe=function(e){var r=e.label,o=e.htmlFor,t=e.required,n=void 0===t||t;return S.createElement(d,{component:"label",htmlFor:o},r,!n&&S.createElement(l,{ml:1,component:"span",sx:{fontWeight:X.font.weight.normal,color:X.color.text.light}},"(optional)"))},Pe=function(e){var r=e.id,o=e.label,t=e.required,n=e.component,i=void 0===n?"div":n,a=e.disabled,l=e.data,c=e.error,d=e.helperText,p=e.sx,g=U(e,["id","label","required","component","disabled","data","error","helperText","sx"]);return S.createElement(s,{component:i,error:c,disabled:a,sx:p},S.createElement(Fe,{label:o,required:t,htmlFor:r}),S.createElement(m,null,l.map((function(e,o){var t=e.value,n=e.label;return S.createElement(f,{key:o,value:t,label:n||"",control:S.createElement(Me,G({color:"primary",inputProps:{"data-testid":"".concat(r,"-").concat(o)}},g))})}))),c&&S.createElement(u,{error:c},d))},We=function(e){return S.createElement(p,G({},e))},Le=function(e){var r=e.id,o=e.required,t=e.component,n=void 0===t?"div":t,i=e.disabled,a=e.data,l=e.label,c=e.error,d=e.helperText,m=e.sx,p=U(e,["id","required","component","disabled","data","label","error","helperText","sx"]);return S.createElement(s,{component:n,error:c,disabled:i,sx:m},S.createElement(Fe,{label:l,required:o,htmlFor:r}),S.createElement(g,G({},p),a.map((function(e,o){var t=e.value,n=e.label,i=e.message;return S.createElement(S.Fragment,null,S.createElement(f,{value:t,key:t,label:n||"",control:S.createElement(We,{color:"primary",inputProps:{"data-testid":"".concat(r,"-").concat(o)}})}),i&&S.createElement(ke,{variant:"caption",marginLeft:X.size.spacing.scale24,color:X.color.text.light,mb:1},i))}))),c&&d&&S.createElement(u,{error:c},d))},Be=function(e){return S.createElement(h,G({},e))},Ie=function(e){var r=e.component,o=void 0===r?"div":r,t=e.disabled,n=e.label,i=e.error,a=e.sx,l=U(e,["component","disabled","label","error","sx"]);return S.createElement(s,{component:o,error:i,disabled:t,sx:G({mb:2},a)},S.createElement(d,{component:"label"},n),S.createElement(Be,G({},l)))},He=function(e){return S.createElement(b,G({variant:"outlined"},e))},je=function(e){var r=e.id,o=e.required,t=e.component,n=void 0===t?"div":t,i=e.disabled,a=e.label,l=e.error,c=e.helperText,d=e.sx,m=e.options,f=U(e,["id","required","component","disabled","label","error","helperText","sx","options"]);return S.createElement(s,{component:n,error:l,disabled:i,sx:d},S.createElement(Fe,{label:a,required:o,htmlFor:r}),S.createElement(He,G({},f,{error:l,inputProps:{id:r,"data-testid":r}}),m.map((function(e){return S.createElement(y,{key:e.value,value:e.value},e.text)}))),l&&c&&S.createElement(u,{error:l},c))},qe=function(e){var r=e.type,o=U(e,["type"]),t=w(!1),n=t[0],i=t[1],a=G(G({},o.InputProps),"password"===r&&{endAdornment:S.createElement(P,{position:"end"},S.createElement(W,{"aria-label":"toggle password visibility",onClick:function(){return i(!n)},edge:"end"},n?S.createElement(L,null):S.createElement(B,null)))});return S.createElement(x,G({},o,{type:n?"text":r,InputProps:a}))},Re=function(e){var r=e.id,o=e.component,t=void 0===o?"div":o,n=e.required,i=e.disabled,a=e.label,l=e.error,c=e.helperText,d=e.sx,m=U(e,["id","component","required","disabled","label","error","helperText","sx"]);return S.createElement(s,{component:t,error:l,disabled:i,sx:d},S.createElement(Fe,{label:a,required:n,htmlFor:r}),S.createElement(qe,G({},m,{id:r,error:l,inputProps:{"data-testid":r},disabled:i,helperText:c})))};function $e(){return $e=Object.assign||function(e){for(var r=1;r<arguments.length;r++){var o=arguments[r];for(var t in o)Object.prototype.hasOwnProperty.call(o,t)&&(e[t]=o[t])}return e},$e.apply(this,arguments)}var Ae=function(e){return T.createElement("svg",$e({viewBox:"0 0 24 24"},e),be||(be=T.createElement("path",{fill:"none",stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.5,d:"M12.141 4.894H3.576A1.977 1.977 0 0 0 1.6 6.871v14.494c0 1.09.885 1.976 1.976 1.976h14.495a1.977 1.977 0 0 0 1.976-1.976V12.8M17.412 1.6h4.94a.99.99 0 0 1 .99.988V7.53m-10.883 4.952L23.05 1.89"})))},Ne=function(e){var r,o=e.children,t=e.underline,n=void 0===t?"hover":t,i=e.toParentNavigation,a=U(e,["children","underline","toParentNavigation"]),l=null===(r=a.href)||void 0===r?void 0:r.startsWith("https"),c={underline:n};return i?S.createElement(v,G({},c,a,{onClick:function(){return e=i,void window.parent.postMessage({type:"NAVIGATION",content:e},"*");var e}}),o):S.createElement(v,G({},c,l&&{target:"_blank",rel:"noopener noreferrer"},a),o,l&&S.createElement(E,{component:Ae,fontSize:"inherit",sx:{marginLeft:".25em"}}))},Ve=function(e){var r=e.children,o=U(e,["children"]);return S.createElement(z,G({},o),r)},De=function(e){var r=e.children,o=U(e,["children"]);return S.createElement(k,G({},o),r)},Xe=function(e){var r=e.children,o=e.value,t=void 0===o?0:o,n=e.index,i=e.id;return S.createElement(Oe,{role:"tabpanel",hidden:t!==n,id:i},r)},Ge=function(e){var r=e.tabs,o=e.nameSpace,t=e.tabContentProps,n=e.tabsProps,i=w(0),a=i[0],l=i[1],c=o?"".concat(o,"-"):"";return S.createElement(S.Fragment,null,S.createElement(Ve,G({},n,{value:a,onChange:function(e,r){l(r)}}),r.map((function(e,r){return S.createElement(De,{key:"".concat(c,"tab-").concat(r),label:e.label,"aria-controls":"".concat(c,"panel-").concat(r)})}))),S.createElement(Oe,G({},t),r.map((function(e,r){var o="".concat(c,"panel-").concat(r);return S.createElement(Xe,{key:o,value:a,index:r,id:o,"aria-labelledby":"".concat(c,"tab-").concat(r)},e.content)}))))},Ue=function(e){var r=e.icon,o=e.title,t=e.subTitle,n=e.action,i=U(e,["icon","title","subTitle","action"]);return S.createElement(l,G({p:4,display:"flex",flexDirection:"column",alignItems:"center"},i),S.createElement(E,{component:null!=r?r:I,sx:{marginBottom:X.size.spacing.scale24,fontSize:X.size.spacing.scale104,color:X.color.gray20}}),S.createElement(ke,{variant:"h1",component:"span",mb:2},o),S.createElement(ke,{variant:"body1",color:X.color.gray60,mb:3},t),n)},_e=function(e){var r=e.children,o=U(e,["children"]);return S.createElement(H,G({},o),r)},Je=function(e){var r=e.children,o=U(e,["children"]);return S.createElement(j,G({},o),r)},Ke=function(e){var r=e.children,o=U(e,["children"]);return S.createElement(q,G({},o),r)},Qe=function(e){var r=e.children,o=U(e,["children"]);return S.createElement(R,G({},o),r)},Ye=function(e){var r=e.children,o=U(e,["children"]);return S.createElement($,G({},o),r)},Ze=function(e){var r=e.children,o=U(e,["children"]);return S.createElement(A,G({},o),r)},er=function(e){var r=U(e,[]);return S.createElement(N,G({},r))},rr=function(e){var r=e.children,o=U(e,["children"]);return S.createElement(V,G({},o),r)},or=function(e){var r=e.children,o=U(e,["children"]);return S.createElement(D,G({},o),r)};export{Se as Avatar,Oe as Box,ze as Button,Me as Checkbox,Te as Chip,Ce as Container,Ue as EmptyState,Pe as FormCheckbox,Re as FormInput,Le as FormRadio,je as FormSelect,Ie as FormSwitch,qe as Input,Ne as Link,We as Radio,He as Select,Be as Switch,De as Tab,Ge as TabGroup,_e as Table,Je as TableBody,Ke as TableCell,Qe as TableContainer,or as TableFooter,Ye as TableHead,er as TablePagination,Ze as TableRow,rr as TableSortLabel,Ve as Tabs,ke as Typography,ve as UpComponentsProvider,xe as theme,X as tokens};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Story, Meta } from '@storybook/react';
|
|
2
2
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
3
3
|
export default _default;
|
|
4
|
-
export declare const Default: Story<Omit<import("@mui/material").BoxProps<"div", {}>, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation">>;
|
|
5
|
-
export declare const Padding: Story<Omit<import("@mui/material").BoxProps<"div", {}>, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation">>;
|
|
4
|
+
export declare const Default: Story<Omit<import("@mui/material").BoxProps<"div", {}>, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation" | "touchRippleRef">>;
|
|
5
|
+
export declare const Padding: Story<Omit<import("@mui/material").BoxProps<"div", {}>, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation" | "touchRippleRef">>;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { Story, Meta } from '@storybook/react';
|
|
2
2
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
3
3
|
export default _default;
|
|
4
|
-
export declare const Default: Story<Omit<import("@mui/material").CheckboxProps, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation">>;
|
|
4
|
+
export declare const Default: Story<Omit<import("@mui/material").CheckboxProps, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation" | "touchRippleRef">>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { Meta, Story } from '@storybook/react';
|
|
2
2
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
3
3
|
export default _default;
|
|
4
|
-
export declare const Default: Story<Omit<Omit<import("@mui/material").ChipProps<"div", {}>, "size">, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation">>;
|
|
4
|
+
export declare const Default: Story<Omit<Omit<import("@mui/material").ChipProps<"div", {}>, "size">, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation" | "touchRippleRef">>;
|
|
5
5
|
export declare const ColorVariants: Story;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { ElementType, ReactNode } from 'react';
|
|
1
|
+
import React, { ElementType, ReactNode } from 'react';
|
|
2
2
|
import { BaseProps } from '@global/utils/types';
|
|
3
|
-
export declare type EmptyStateProps = BaseProps<{
|
|
3
|
+
export declare type EmptyStateProps<C extends React.ElementType = 'div'> = BaseProps<C, {
|
|
4
4
|
/**
|
|
5
5
|
* Helpful message that conveys the purpose of the screen and the next action to populate the space
|
|
6
6
|
*/
|
|
@@ -18,4 +18,4 @@ export declare type EmptyStateProps = BaseProps<{
|
|
|
18
18
|
*/
|
|
19
19
|
action?: ReactNode;
|
|
20
20
|
}>;
|
|
21
|
-
export declare const EmptyState: ({ icon: Icon, title, subTitle, action, ...props }: EmptyStateProps
|
|
21
|
+
export declare const EmptyState: <C extends React.ElementType<any>>({ icon: Icon, title, subTitle, action, ...props }: EmptyStateProps<C>) => JSX.Element;
|
|
@@ -2,6 +2,6 @@ import { Story, Meta } from '@storybook/react';
|
|
|
2
2
|
import { EmptyStateProps } from './EmptyState';
|
|
3
3
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
4
4
|
export default _default;
|
|
5
|
-
export declare const Default: Story<EmptyStateProps
|
|
6
|
-
export declare const CustomIcon: Story<EmptyStateProps
|
|
7
|
-
export declare const WithAction: Story<EmptyStateProps
|
|
5
|
+
export declare const Default: Story<EmptyStateProps<"div">>;
|
|
6
|
+
export declare const CustomIcon: Story<EmptyStateProps<"div">>;
|
|
7
|
+
export declare const WithAction: Story<EmptyStateProps<"div">>;
|
|
@@ -1,13 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { FormBaseProps } from '@global/utils/types';
|
|
3
3
|
import { CheckboxProps } from '../Checkbox/Checkbox';
|
|
4
|
-
export declare type FormCheckboxProps =
|
|
4
|
+
export declare type FormCheckboxProps<C extends React.ElementType = 'div'> = CheckboxProps & FormBaseProps<C> & {
|
|
5
5
|
data: {
|
|
6
6
|
value: string | number;
|
|
7
7
|
label?: string;
|
|
8
8
|
}[];
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
helperText?: string;
|
|
12
|
-
}>;
|
|
13
|
-
export declare const FormCheckbox: ({ id, required, data, label, error, helperText }: FormCheckboxProps) => JSX.Element;
|
|
9
|
+
};
|
|
10
|
+
export declare const FormCheckbox: <C extends React.ElementType<any>>({ id, label, required, component, disabled, data, error, helperText, sx, ...props }: FormCheckboxProps<C>) => JSX.Element;
|
|
@@ -3,6 +3,6 @@ import { Meta, Story } from '@storybook/react';
|
|
|
3
3
|
import { FormCheckboxProps } from './FormCheckbox';
|
|
4
4
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
5
5
|
export default _default;
|
|
6
|
-
export declare const Primary: Story<React.PropsWithChildren<FormCheckboxProps
|
|
7
|
-
export declare const Required: Story<React.PropsWithChildren<FormCheckboxProps
|
|
8
|
-
export declare const withError: Story<React.PropsWithChildren<FormCheckboxProps
|
|
6
|
+
export declare const Primary: Story<React.PropsWithChildren<FormCheckboxProps<"div">>>;
|
|
7
|
+
export declare const Required: Story<React.PropsWithChildren<FormCheckboxProps<"div">>>;
|
|
8
|
+
export declare const withError: Story<React.PropsWithChildren<FormCheckboxProps<"div">>>;
|
|
@@ -1,9 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { FormBaseProps } from '@global/utils/types';
|
|
3
3
|
import { InputProps } from '../Input/Input';
|
|
4
|
-
export declare type FormInputProps =
|
|
5
|
-
|
|
6
|
-
error?: boolean;
|
|
7
|
-
helperText?: string;
|
|
8
|
-
}>;
|
|
9
|
-
export declare const FormInput: ({ id, required, label, error, helperText, ...props }: FormInputProps) => JSX.Element;
|
|
4
|
+
export declare type FormInputProps<C extends React.ElementType = 'div'> = InputProps & FormBaseProps<C>;
|
|
5
|
+
export declare const FormInput: <C extends React.ElementType<any>>({ id, component, required, disabled, label, error, helperText, sx, ...props }: FormInputProps<C>) => JSX.Element;
|
|
@@ -2,6 +2,9 @@ import { Meta, Story } from '@storybook/react';
|
|
|
2
2
|
import { FormInputProps } from './FormInput';
|
|
3
3
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
4
4
|
export default _default;
|
|
5
|
-
export declare const Primary: Story<FormInputProps
|
|
6
|
-
export declare const Required: Story<FormInputProps
|
|
7
|
-
export declare const
|
|
5
|
+
export declare const Primary: Story<FormInputProps<"div">>;
|
|
6
|
+
export declare const Required: Story<FormInputProps<"div">>;
|
|
7
|
+
export declare const Disabled: Story<FormInputProps<"div">>;
|
|
8
|
+
export declare const withError: Story<FormInputProps<"div">>;
|
|
9
|
+
export declare const Password: Story<FormInputProps<"div">>;
|
|
10
|
+
export declare const withComponents: Story<FormInputProps<"div">>;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { TextFieldProps, FormLabelBaseProps } from '@mui/material';
|
|
3
|
+
export declare type FormLabelProps = {
|
|
4
|
+
label: TextFieldProps['label'];
|
|
5
|
+
required?: TextFieldProps['required'];
|
|
6
|
+
htmlFor: FormLabelBaseProps['htmlFor'];
|
|
7
|
+
};
|
|
8
|
+
export declare const FormLabel: ({ label, htmlFor, required }: FormLabelProps) => JSX.Element;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,14 +1,11 @@
|
|
|
1
|
-
|
|
1
|
+
import React from 'react';
|
|
2
2
|
import { RadioGroupProps } from '@mui/material';
|
|
3
|
-
import {
|
|
4
|
-
export declare type FormRadioProps =
|
|
3
|
+
import { FormBaseProps } from '@global/utils/types';
|
|
4
|
+
export declare type FormRadioProps<C extends React.ElementType = 'div'> = RadioGroupProps & FormBaseProps<C> & {
|
|
5
5
|
data: {
|
|
6
6
|
value: string | number;
|
|
7
7
|
label?: string;
|
|
8
|
+
message?: string;
|
|
8
9
|
}[];
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
error?: boolean;
|
|
12
|
-
required?: boolean;
|
|
13
|
-
}>;
|
|
14
|
-
export declare const FormRadio: ({ id, helperText, label, error, required, name, data }: FormRadioProps) => JSX.Element;
|
|
10
|
+
};
|
|
11
|
+
export declare const FormRadio: ({ id, required, component, disabled, data, label, error, helperText, sx, ...props }: FormRadioProps) => JSX.Element;
|
|
@@ -3,6 +3,7 @@ import { Meta, Story } from '@storybook/react';
|
|
|
3
3
|
import { FormRadioProps } from './FormRadio';
|
|
4
4
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
5
5
|
export default _default;
|
|
6
|
-
export declare const Primary: Story<React.PropsWithChildren<FormRadioProps
|
|
7
|
-
export declare const Required: Story<React.PropsWithChildren<FormRadioProps
|
|
8
|
-
export declare const withError: Story<React.PropsWithChildren<FormRadioProps
|
|
6
|
+
export declare const Primary: Story<React.PropsWithChildren<FormRadioProps<"div">>>;
|
|
7
|
+
export declare const Required: Story<React.PropsWithChildren<FormRadioProps<"div">>>;
|
|
8
|
+
export declare const withError: Story<React.PropsWithChildren<FormRadioProps<"div">>>;
|
|
9
|
+
export declare const withMessage: Story<React.PropsWithChildren<FormRadioProps<"div">>>;
|
|
@@ -1,13 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { FormBaseProps } from '@global/utils/types';
|
|
3
3
|
import { SelectProps } from '../Select/Select';
|
|
4
|
-
export declare type FormSelectProps =
|
|
4
|
+
export declare type FormSelectProps<C extends React.ElementType = 'div'> = SelectProps & FormBaseProps<C> & {
|
|
5
5
|
options: {
|
|
6
6
|
value: string | number;
|
|
7
7
|
text: string;
|
|
8
8
|
}[];
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
helperText?: string;
|
|
12
|
-
}>;
|
|
13
|
-
export declare const FormSelect: ({ id, required, options, label, error, placeholder, helperText, value, }: FormSelectProps) => JSX.Element;
|
|
9
|
+
};
|
|
10
|
+
export declare const FormSelect: ({ id, required, component, disabled, label, error, helperText, sx, options, ...props }: FormSelectProps) => JSX.Element;
|
|
@@ -2,6 +2,7 @@ import { Meta, Story } from '@storybook/react';
|
|
|
2
2
|
import { FormSelectProps } from './FormSelect';
|
|
3
3
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
4
4
|
export default _default;
|
|
5
|
-
export declare const Primary: Story<FormSelectProps
|
|
6
|
-
export declare const Required: Story<FormSelectProps
|
|
7
|
-
export declare const withError: Story<FormSelectProps
|
|
5
|
+
export declare const Primary: Story<FormSelectProps<"div">>;
|
|
6
|
+
export declare const Required: Story<FormSelectProps<"div">>;
|
|
7
|
+
export declare const withError: Story<FormSelectProps<"div">>;
|
|
8
|
+
export declare const disabled: Story<FormSelectProps<"div">>;
|
|
@@ -1,8 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { FormBaseProps } from '@global/utils/types';
|
|
2
3
|
import { SwitchProps } from '../Switch/Switch';
|
|
3
|
-
export
|
|
4
|
-
|
|
5
|
-
id?: string;
|
|
6
|
-
checked?: boolean;
|
|
7
|
-
}
|
|
8
|
-
export declare const FormSwitch: ({ id, label, checked }: FormSwitchProps) => JSX.Element;
|
|
4
|
+
export declare type FormSwitchProps<C extends React.ElementType = 'div'> = SwitchProps & FormBaseProps<C>;
|
|
5
|
+
export declare const FormSwitch: <C extends React.ElementType<any>>({ component, disabled, label, error, sx, ...props }: FormSwitchProps<C>) => JSX.Element;
|
|
@@ -3,4 +3,4 @@ import { Meta, Story } from '@storybook/react';
|
|
|
3
3
|
import { FormSwitchProps } from './FormSwitch';
|
|
4
4
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
5
5
|
export default _default;
|
|
6
|
-
export declare const Primary: Story<React.PropsWithChildren<FormSwitchProps
|
|
6
|
+
export declare const Primary: Story<React.PropsWithChildren<FormSwitchProps<"div">>>;
|
|
@@ -1,7 +1,4 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
2
|
import { TextFieldProps } from '@mui/material';
|
|
3
|
-
|
|
4
|
-
export declare type
|
|
5
|
-
type?: HTMLInputTypeAttribute;
|
|
6
|
-
};
|
|
7
|
-
export declare const Input: ({ type, ...otherProps }: InputProps) => JSX.Element;
|
|
3
|
+
export declare type InputProps = Omit<TextFieldProps, 'maxRows' | 'minRows' | 'multiline' | 'rows' | 'size' | 'variant'>;
|
|
4
|
+
export declare const Input: ({ type, ...props }: InputProps) => JSX.Element;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { Story, Meta } from '@storybook/react';
|
|
2
2
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
3
3
|
export default _default;
|
|
4
|
-
export declare const Default: Story<Omit<import("@mui/material").RadioProps, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation">>;
|
|
4
|
+
export declare const Default: Story<Omit<import("@mui/material").RadioProps, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation" | "touchRippleRef">>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Story, Meta } from '@storybook/react';
|
|
2
2
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
3
3
|
export default _default;
|
|
4
|
-
export declare const Default: Story<Omit<Omit<import("@mui/material").SelectProps<unknown>, "label" | "variant">, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation">>;
|
|
5
|
-
export declare const Disabled: Story<Omit<Omit<import("@mui/material").SelectProps<unknown>, "label" | "variant">, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation">>;
|
|
6
|
-
export declare const Error: Story<Omit<Omit<import("@mui/material").SelectProps<unknown>, "label" | "variant">, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation">>;
|
|
4
|
+
export declare const Default: Story<Omit<Omit<import("@mui/material").SelectProps<unknown>, "label" | "variant">, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation" | "touchRippleRef">>;
|
|
5
|
+
export declare const Disabled: Story<Omit<Omit<import("@mui/material").SelectProps<unknown>, "label" | "variant">, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation" | "touchRippleRef">>;
|
|
6
|
+
export declare const Error: Story<Omit<Omit<import("@mui/material").SelectProps<unknown>, "label" | "variant">, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation" | "touchRippleRef">>;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
-
|
|
1
|
+
/// <reference types="react" />
|
|
2
2
|
import { SwitchProps as MUISwitchProps } from '@mui/material';
|
|
3
3
|
import { MUIGlobalOmit } from '@global/utils/types';
|
|
4
|
-
export declare type SwitchProps = MUIGlobalOmit<MUISwitchProps
|
|
5
|
-
onChange?: (event: React.ChangeEvent<HTMLInputElement>, checked: boolean) => void;
|
|
6
|
-
}>;
|
|
4
|
+
export declare type SwitchProps = MUIGlobalOmit<MUISwitchProps>;
|
|
7
5
|
export declare const Switch: (props: SwitchProps) => JSX.Element;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
import { Story, Meta } from '@storybook/react';
|
|
2
|
-
import { SwitchProps } from './Switch';
|
|
3
2
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
4
3
|
export default _default;
|
|
5
|
-
export declare const Default: Story<SwitchProps
|
|
4
|
+
export declare const Default: Story<Omit<import("@mui/material").SwitchProps, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation" | "touchRippleRef">>;
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/// <reference types="react" />
|
|
2
|
+
import { TableProps as MuiTableProps } from '@mui/material/Table';
|
|
3
|
+
import { TableBodyProps as MuiTableBodyProps } from '@mui/material/TableBody';
|
|
4
|
+
import { TableCellProps as MuiTableCellProps } from '@mui/material/TableCell';
|
|
5
|
+
import { TableContainerProps as MuiTableContainerProps } from '@mui/material/TableContainer';
|
|
6
|
+
import { TableHeadProps as MuiTableHeadProps } from '@mui/material/TableHead';
|
|
7
|
+
import { TableRowProps as MuiTableRowProps } from '@mui/material/TableRow';
|
|
8
|
+
import { TablePaginationProps as MuiTablePaginationProps } from '@mui/material/TablePagination';
|
|
9
|
+
import { TableSortLabelProps as MuiTableSortLabelProps } from '@mui/material/TableSortLabel';
|
|
10
|
+
import { TableFooterProps as MuiTableFooterProps } from '@mui/material/TableFooter';
|
|
11
|
+
import { MUIGlobalOmit } from '@global/utils/types';
|
|
12
|
+
export declare type TableProps = MUIGlobalOmit<MuiTableProps>;
|
|
13
|
+
export declare const Table: ({ children, ...props }: TableProps) => JSX.Element;
|
|
14
|
+
export declare type TableBodyProps = MUIGlobalOmit<MuiTableBodyProps>;
|
|
15
|
+
export declare const TableBody: ({ children, ...props }: TableBodyProps) => JSX.Element;
|
|
16
|
+
export declare type TableCellProps = MUIGlobalOmit<MuiTableCellProps>;
|
|
17
|
+
export declare const TableCell: ({ children, ...props }: TableCellProps) => JSX.Element;
|
|
18
|
+
export declare type TableContainerProps = MUIGlobalOmit<MuiTableContainerProps>;
|
|
19
|
+
export declare const TableContainer: ({ children, ...props }: TableContainerProps) => JSX.Element;
|
|
20
|
+
export declare type TableHeadProps = MUIGlobalOmit<MuiTableHeadProps>;
|
|
21
|
+
export declare const TableHead: ({ children, ...props }: TableHeadProps) => JSX.Element;
|
|
22
|
+
export declare type TableRowProps = MUIGlobalOmit<MuiTableRowProps>;
|
|
23
|
+
export declare const TableRow: ({ children, ...props }: TableRowProps) => JSX.Element;
|
|
24
|
+
export declare type TablePaginationProps = MUIGlobalOmit<MuiTablePaginationProps>;
|
|
25
|
+
export declare const TablePagination: ({ ...props }: TablePaginationProps) => JSX.Element;
|
|
26
|
+
export declare type TableSortLabelProps = MUIGlobalOmit<MuiTableSortLabelProps>;
|
|
27
|
+
export declare const TableSortLabel: ({ children, ...props }: TableSortLabelProps) => JSX.Element;
|
|
28
|
+
export declare type TableFooterProps = MUIGlobalOmit<MuiTableFooterProps>;
|
|
29
|
+
export declare const TableFooter: ({ children, ...props }: TableFooterProps) => JSX.Element;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { OverridesStyleRules } from '@mui/material/styles/overrides';
|
|
2
|
+
export declare const MuiTable: OverridesStyleRules;
|
|
3
|
+
export declare const MuiTableCell: OverridesStyleRules;
|
|
4
|
+
export declare const MuiTableRow: OverridesStyleRules;
|
|
5
|
+
export declare const MuiTableFooter: OverridesStyleRules;
|
|
6
|
+
export declare const MuiTablePagination: OverridesStyleRules;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { Story, Meta } from '@storybook/react';
|
|
2
|
+
import { TableProps } from './Table';
|
|
3
|
+
declare const _default: Meta<import("@storybook/react").Args>;
|
|
4
|
+
export default _default;
|
|
5
|
+
export declare const BasicTable: Story<TableProps>;
|
|
6
|
+
export declare const ComplexTable: Story<TableProps>;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { Story, Meta } from '@storybook/react';
|
|
2
2
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
3
3
|
export default _default;
|
|
4
|
-
export declare const Default: Story<Omit<import("@
|
|
4
|
+
export declare const Default: Story<Omit<import("@mui/material").TabsProps<import("@library").ExtendButtonBase<import("@library").ButtonBaseTypeMap<{}, "button">>, {}>, "disableFocusRipple" | "disableRipple" | "classes" | "tabIndex" | "action" | "centerRipple" | "disableTouchRipple" | "focusRipple" | "focusVisibleClassName" | "LinkComponent" | "TouchRippleProps" | "disableElevation" | "touchRippleRef">>;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { TypographyProps as MUITypographyProps } from '@mui/material/Typography';
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
component?: React.ElementType;
|
|
3
|
+
export declare type TypographyProps<C extends React.ElementType = 'p'> = MUITypographyProps<C, {
|
|
4
|
+
component?: C;
|
|
6
5
|
}>;
|
|
7
|
-
export declare const Typography: ({ children, ...props }: TypographyProps) => JSX.Element;
|
|
6
|
+
export declare const Typography: <C extends React.ElementType<any>>({ children, ...props }: TypographyProps<C>) => JSX.Element;
|
|
@@ -2,5 +2,5 @@ import { Story, Meta } from '@storybook/react';
|
|
|
2
2
|
import { TypographyProps } from './Typography';
|
|
3
3
|
declare const _default: Meta<import("@storybook/react").Args>;
|
|
4
4
|
export default _default;
|
|
5
|
-
export declare const Default: Story<TypographyProps
|
|
5
|
+
export declare const Default: Story<TypographyProps<"p">>;
|
|
6
6
|
export declare const AllVariants: Story;
|
|
@@ -1,7 +1,5 @@
|
|
|
1
|
+
import { BoxProps, TextFieldProps } from '@mui/material';
|
|
1
2
|
import React from 'react';
|
|
2
|
-
|
|
3
|
-
export declare type
|
|
4
|
-
export declare type
|
|
5
|
-
sx?: SxProps<Theme>;
|
|
6
|
-
ref?: React.Ref<unknown>;
|
|
7
|
-
};
|
|
3
|
+
export declare type MUIGlobalOmit<MuiProps, ComponentProps = unknown> = ComponentProps & Omit<MuiProps, 'classes' | 'disableElevation' | 'disableFocusRipple' | 'disableRipple' | 'focusRipple' | 'tabIndex' | 'action' | 'centerRipple' | 'disableTouchRipple' | 'focusVisibleClassName' | 'LinkComponent' | 'TouchRippleProps' | 'touchRippleRef'>;
|
|
4
|
+
export declare type BaseProps<D extends React.ElementType = 'div', P = Record<string, unknown>> = BoxProps<D, P>;
|
|
5
|
+
export declare type FormBaseProps<C extends React.ElementType> = BaseProps<C, Pick<TextFieldProps, 'id' | 'label' | 'required' | 'error' | 'disabled' | 'focused' | 'helperText'>>;
|
|
@@ -3,4 +3,24 @@ export * from '@mui/material';
|
|
|
3
3
|
export { tokens };
|
|
4
4
|
export { UpComponentsProvider } from './global/UpComponentsProvider/UpComponentsProvider';
|
|
5
5
|
export { theme } from './global/theme';
|
|
6
|
-
export { Button,
|
|
6
|
+
export { Button, type ButtonProps } from './components/Button/Button';
|
|
7
|
+
export { Typography, type TypographyProps } from './components/Typography/Typography';
|
|
8
|
+
export { Chip, type ChipProps } from './components/Chip/Chip';
|
|
9
|
+
export { Avatar, type AvatarProps } from './components/Avatar/Avatar';
|
|
10
|
+
export { Container, type ContainerProps } from './components/Container/Container';
|
|
11
|
+
export { Box, type BoxProps } from './components/Box/Box';
|
|
12
|
+
export { Checkbox, type CheckboxProps } from './components/Checkbox/Checkbox';
|
|
13
|
+
export { FormCheckbox, type FormCheckboxProps } from './components/FormCheckbox/FormCheckbox';
|
|
14
|
+
export { Radio, type RadioProps } from './components/Radio/Radio';
|
|
15
|
+
export { FormRadio, type FormRadioProps } from './components/FormRadio/FormRadio';
|
|
16
|
+
export { Switch, type SwitchProps } from './components/Switch/Switch';
|
|
17
|
+
export { FormSwitch, type FormSwitchProps } from './components/FormSwitch/FormSwitch';
|
|
18
|
+
export { Select, type SelectProps } from './components/Select/Select';
|
|
19
|
+
export { FormSelect, type FormSelectProps } from './components/FormSelect/FormSelect';
|
|
20
|
+
export { Input, type InputProps } from './components/Input/Input';
|
|
21
|
+
export { FormInput, type FormInputProps } from './components/FormInput/FormInput';
|
|
22
|
+
export { Link, type LinkProps } from './components/Link/Link';
|
|
23
|
+
export { Tabs, Tab, type TabsProps, type TabProps } from './components/Tabs/Tabs';
|
|
24
|
+
export { TabGroup, type TabGroupProps } from './components/TabGroup/TabGroup';
|
|
25
|
+
export { EmptyState, type EmptyStateProps } from './components/EmptyState/EmptyState';
|
|
26
|
+
export { Table, TableBody, TableCell, TableHead, TableContainer, TableRow, TableFooter, TablePagination, TableSortLabel, type TableProps, type TableBodyProps, type TableCellProps, type TableHeadProps, type TableContainerProps, type TableRowProps, type TableFooterProps, type TablePaginationProps, type TableSortLabelProps, } from './components/Table/Table';
|