@pautena/react-design-system 0.11.0 → 0.11.2

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.
Files changed (38) hide show
  1. package/dist/cjs/index.js +4 -4
  2. package/dist/cjs/index.js.map +1 -1
  3. package/dist/cjs/types/components/containers/list-panel/list-panel.d.ts +2 -1
  4. package/dist/cjs/types/components/data-display/header/header-title.d.ts +9 -0
  5. package/dist/cjs/types/components/data-display/header/header.types.d.ts +10 -2
  6. package/dist/cjs/types/components/data-display/header/index.d.ts +1 -0
  7. package/dist/cjs/types/components/inputs/action/action-header.d.ts +7 -0
  8. package/dist/cjs/types/components/inputs/action/action.d.ts +18 -0
  9. package/dist/cjs/types/components/inputs/action/index.d.ts +2 -0
  10. package/dist/cjs/types/components/inputs/index.d.ts +1 -0
  11. package/dist/esm/index.js +4 -4
  12. package/dist/esm/index.js.map +1 -1
  13. package/dist/esm/types/components/containers/list-panel/list-panel.d.ts +2 -1
  14. package/dist/esm/types/components/data-display/header/header-title.d.ts +9 -0
  15. package/dist/esm/types/components/data-display/header/header.types.d.ts +10 -2
  16. package/dist/esm/types/components/data-display/header/index.d.ts +1 -0
  17. package/dist/esm/types/components/inputs/action/action-header.d.ts +7 -0
  18. package/dist/esm/types/components/inputs/action/action.d.ts +18 -0
  19. package/dist/esm/types/components/inputs/action/index.d.ts +2 -0
  20. package/dist/esm/types/components/inputs/index.d.ts +1 -0
  21. package/dist/index.d.ts +48 -6
  22. package/package.json +1 -1
  23. package/src/components/containers/list-panel/list-panel.test.tsx +1 -1
  24. package/src/components/containers/list-panel/list-panel.tsx +6 -5
  25. package/src/components/data-display/header/header-title.tsx +51 -0
  26. package/src/components/data-display/header/header.stories.tsx +40 -1
  27. package/src/components/data-display/header/header.test.tsx +62 -7
  28. package/src/components/data-display/header/header.tsx +7 -8
  29. package/src/components/data-display/header/header.types.ts +10 -2
  30. package/src/components/data-display/header/index.ts +1 -0
  31. package/src/components/inputs/action/action-header.test.tsx +11 -0
  32. package/src/components/inputs/action/action-header.tsx +30 -0
  33. package/src/components/inputs/action/action.stories.tsx +77 -0
  34. package/src/components/inputs/action/action.test.tsx +97 -0
  35. package/src/components/inputs/action/action.tsx +86 -0
  36. package/src/components/inputs/action/index.ts +2 -0
  37. package/src/components/inputs/index.ts +1 -0
  38. package/src/components/inputs/inputs.stories.mdx +1 -0
@@ -7,6 +7,7 @@ export interface ListPanelItem {
7
7
  export type ListPanelProps = PropsWithChildren<{
8
8
  defaultSelectedItem?: string;
9
9
  items: ListPanelItem[];
10
+ colBreakpoint?: number;
10
11
  onSelectedItemChange?: (id: string) => void;
11
12
  }>;
12
- export declare const ListPanel: ({ items, defaultSelectedItem, children, onSelectedItemChange, }: ListPanelProps) => JSX.Element;
13
+ export declare const ListPanel: ({ items, defaultSelectedItem, colBreakpoint, children, onSelectedItemChange, }: ListPanelProps) => JSX.Element;
@@ -0,0 +1,9 @@
1
+ import { PropsWithChildren } from "react";
2
+ export type HeaderTitleProps = PropsWithChildren<{
3
+ loading?: boolean;
4
+ }>;
5
+ export declare const HeaderTitle: ({ loading, children }: HeaderTitleProps) => JSX.Element;
6
+ export type HeaderSubtitleProps = PropsWithChildren<{
7
+ loading?: boolean;
8
+ }>;
9
+ export declare const HeaderSubtitle: ({ loading, children }: HeaderSubtitleProps) => JSX.Element;
@@ -38,11 +38,19 @@ export type HeaderProps = {
38
38
  /**
39
39
  * Title of the header
40
40
  */
41
- title: string;
41
+ title?: string | ReactElement;
42
+ /**
43
+ * Show a loading indicator in the title position
44
+ */
45
+ loadingTitle?: boolean;
42
46
  /**
43
47
  * Subtitle of the header
44
48
  */
45
- subtitle?: string;
49
+ subtitle?: string | ReactElement;
50
+ /**
51
+ * Show a loading indicator in the subtitle position
52
+ */
53
+ loadingSubtitle?: boolean;
46
54
  /**
47
55
  * Color palete used to render the component
48
56
  */
@@ -1,2 +1,3 @@
1
1
  export * from "./header";
2
2
  export * from "./header.types";
3
+ export * from "./header-title";
@@ -0,0 +1,7 @@
1
+ type Variant = "primary" | "error" | "warning" | "success";
2
+ export interface ActionHeaderProps {
3
+ variant?: Variant;
4
+ title: string;
5
+ }
6
+ export declare const ActionHeader: ({ title, variant }: ActionHeaderProps) => JSX.Element;
7
+ export {};
@@ -0,0 +1,18 @@
1
+ import { Variant } from "@mui/material/styles/createTypography";
2
+ import { ReactElement } from "react";
3
+ export type ActionVariant = "primary" | "error" | "warning" | "success";
4
+ export interface ActionProps {
5
+ variant: ActionVariant;
6
+ title: string;
7
+ description?: string | ReactElement;
8
+ descriptionVariant?: Variant;
9
+ helperText?: string;
10
+ helperTextVariant?: Variant;
11
+ buttonText: string;
12
+ confirmable?: boolean;
13
+ confirmTitle?: string;
14
+ confirmDescription?: string;
15
+ passphrase?: string;
16
+ onAction: () => void;
17
+ }
18
+ export declare const Action: ({ variant, title, description, descriptionVariant, buttonText, helperText, helperTextVariant, confirmable, passphrase, confirmTitle, confirmDescription, onAction, }: ActionProps) => JSX.Element;
@@ -0,0 +1,2 @@
1
+ export * from "./action";
2
+ export * from "./action-header";
@@ -4,3 +4,4 @@ export * from "./autocomplete";
4
4
  export * from "./date-range-picker";
5
5
  export * from "./date-range-calendar";
6
6
  export * from "./text-field";
7
+ export * from "./action";
package/dist/esm/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import{InputAdornment as e,Button as t,useTheme as n,IconButton as r,Box as o,Typography as a,Tooltip as i,TextField as l,Paper as c,Switch as u,Grid as s,Rating as d,Badge as m,Link as f,Snackbar as p,Alert as v,AlertTitle as y,Container as h,Breadcrumbs as g,Tabs as b,Tab as E,CircularProgress as x,LinearProgress as C,List as S,ListItemButton as w,ListItemText as k,styled as T,drawerClasses as I,Drawer as O,Divider as P,paperClasses as $,ListSubheader as z,ListItemIcon as R,Collapse as j,Popover as A,ListItemAvatar as W,Avatar as N,AppBar as M,Toolbar as D,FormControl as V,InputLabel as F,Select as _,Stack as L,outlinedInputClasses as B,inputLabelClasses as q,circularProgressClasses as H,linearProgressClasses as U,autocompleteClasses as Y,iconButtonClasses as J,OutlinedInput as X,FormHelperText as G,Autocomplete as K,TableHead as Q,TableRow as Z,TableCell as ee,TableSortLabel as te,TableContainer as ne,Table as re,TableBody as oe,Skeleton as ae,alertClasses as ie,Dialog as le,DialogTitle as ce,DialogContent as ue,DialogActions as se,FormControlLabel as de,Checkbox as me,MenuItem as fe,Menu as pe}from"@mui/material";import*as ve from"react";import ye,{useState as he,useRef as ge,useEffect as be,forwardRef as Ee,createContext as xe,useContext as Ce,useId as Se,useMemo as we}from"react";import ke from"@mui/icons-material/Check";import Te from"@mui/icons-material/Clear";import Ie from"@mui/icons-material/Edit";import Oe from"@mui/icons-material/Close";import{format as Pe,isAfter as $e,isSameDay as ze,startOfWeek as Re,endOfWeek as je}from"date-fns";import{DateTimePicker as Ae,TimePicker as We,DatePicker as Ne,DateCalendar as Me,PickersDay as De,DesktopDatePicker as Ve}from"@mui/x-date-pickers";import{Link as Fe,useLocation as _e,useNavigate as Le,useParams as Be,Routes as qe,Route as He}from"react-router-dom";import{blueGrey as Ue,grey as Ye}from"@mui/material/colors";import Je from"markdown-to-jsx";import Xe from"@mui/icons-material/ContentCopy";import Ge from"@mui/icons-material/ChevronLeft";import Ke from"@mui/icons-material/ExpandMore";import Qe from"@mui/icons-material/ChevronRight";import Ze from"@mui/icons-material/Menu";import{LoadingButton as et}from"@mui/lab";import tt from"@mui/icons-material/Event";import{isBefore as nt}from"date-fns/esm";import rt from"@mui/icons-material/Search";import{loremIpsum as ot}from"lorem-ipsum";import at from"@mui/icons-material/ExpandLess";import it from"@mui/icons-material/ReportProblem";import{DataGrid as lt}from"@mui/x-data-grid";import ct from"@mui/icons-material/MoreVert";var ut=function(n){var r=n.onClickCancel,o=n.onClickSubmit,a=n.sx;return ye.createElement(e,{position:"end",sx:a},ye.createElement(t,{variant:"contained",size:"small",color:"error","aria-label":"cancel button",startIcon:ye.createElement(Te,{sx:{fontSize:12}}),onClick:r,sx:{paddingRight:0,minWidth:0,marginRight:1}}),ye.createElement(t,{variant:"contained",size:"small",color:"primary","aria-label":"submit button",startIcon:ye.createElement(ke,{sx:{fontSize:12}}),onClick:o,sx:{paddingRight:0,minWidth:0}}))},st=function(e,t){var n=he(!1),r=n[0],o=n[1],a=he(e),i=a[0],l=a[1],c=function(){o(!1),l(e)};return{isEditing:r,cancelEdit:c,editValue:i,setEditValue:l,startEdit:function(){o(!0)},submitEdit:function(){t(i),c()}}},dt=function(e){var t=e.dense,o=e.onClick,a=n().typography;return ye.createElement(r,{size:"small",onClick:o,sx:{ml:t?.5:1},"aria-label":"edit button"},ye.createElement(Ie,{sx:{fontSize:a.pxToRem(t?18:24)}}))},mt="-",ft=function(e){return"label-".concat(e.replace(/ /g,"-"))},pt=function(e){var t=e.label,r=e.hideLabel,l=e.tooltip,c=e.tooltipEnterDelay,u=void 0===c?2e3:c,s=e.children,d=e.dense,m=e.sx,f=n().typography,p=ft(t);return ye.createElement(o,{width:1,lineHeight:d?0:void 0,sx:m},!r&&ye.createElement(a,{variant:d?"caption":"subtitle2",role:"label",id:p,lineHeight:d?f.pxToRem(15):void 0},t),l?ye.createElement(i,{title:l,placement:"top",enterDelay:u},s):s)},vt=function(e){var t=e.label,n=e.value,r=e.placeholder,o=void 0===r?mt:r,i=e.editable,c=e.dense,u=e.onEdit,s=void 0===u?function(){return null}:u,d=ge(null),m=st(null==n?void 0:n.toString(),s),f=m.isEditing,p=m.editValue,v=m.startEdit,y=m.cancelEdit,h=m.setEditValue,g=m.submitEdit,b=ft(t),E=(null==n?void 0:n.toString())||o,x=function(e){"Enter"===e.key&&s(e.target.value)};return be((function(){var e;return null===(e=d.current)||void 0===e||e.addEventListener("keypress",x),function(){var e;return null===(e=d.current)||void 0===e?void 0:e.removeEventListener("keypress",x)}}),[d.current]),ye.createElement(pt,{hideLabel:f,label:t,tooltip:E,dense:c},f?ye.createElement(l,{inputRef:d,value:p,label:t,size:"small",onChange:function(e){return h(e.target.value)},InputProps:{endAdornment:ye.createElement(ut,{onClickCancel:y,onClickSubmit:g})},sx:{marginY:c?0:1}}):ye.createElement(a,{variant:c?"body1":"h5",noWrap:!0,"aria-labelledby":b},E,i&&ye.createElement(dt,{dense:c,onClick:v})))},yt=function(e){var t=e.children;return ye.createElement(c,{sx:{p:2}},t)},ht=function(e){var t=e.label,r=e.value,i=e.placeholder,l=void 0===i?mt:i,c=e.editable,s=e.dense,d=e.onEdit,m=void 0===d?function(){return null}:d,f=ft(t),p=n().typography,v=st(r,m),y=v.isEditing,h=v.editValue,g=v.startEdit,b=v.cancelEdit,E=v.setEditValue,x=v.submitEdit,C={fontSize:s?p.h6.fontSize:p.h5.fontSize};return ye.createElement(pt,{label:t,dense:s},y?ye.createElement(o,{display:"flex",alignItems:"center"},ye.createElement(u,{size:s?"small":"medium",checked:h,onChange:function(e){return E(e.target.checked)}}),ye.createElement(ut,{onClickCancel:b,onClickSubmit:x})):ye.createElement(o,{display:"flex",alignItems:"center","aria-labelledby":f,role:"checkbox","aria-checked":r},void 0===r?ye.createElement(a,{variant:"h5"},l):r?ye.createElement(ke,{color:"success",sx:C}):ye.createElement(Oe,{color:"error",sx:C}),c&&ye.createElement(dt,{dense:s,onClick:g})))},gt=function(){return gt=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},gt.apply(this,arguments)};function bt(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}function Et(e,t,n){if(n||2===arguments.length)for(var r,o=0,a=t.length;o<a;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}"function"==typeof SuppressedError&&SuppressedError;var xt=function(e){var t=e.label,n=e.value,r=e.format,i=e.placeholder,c=void 0===i?mt:i,u=e.editable,s=e.editInputType,d=void 0===s?"datetime":s,m=e.dense,f=e.onEdit,p=st(n,void 0===f?function(){return null}:f),v=p.isEditing,y=p.editValue,h=p.startEdit,g=p.cancelEdit,b=p.setEditValue,E=p.submitEdit,x=ft(t),C=n&&Pe(n,r)||c,S="datetime"===d?Ae:"time"===d?We:Ne;return ye.createElement(pt,{label:t,hideLabel:v,tooltip:C,dense:m,sx:{display:"flex",flexDirection:"column"}},v?ye.createElement(S,{value:y,format:r,label:t,onChange:function(e){return b(e||void 0)},slots:{textField:function(e){var t;return ye.createElement(l,gt({},e,{size:"small",InputProps:gt(gt({},e.InputProps),{endAdornment:ye.createElement(ye.Fragment,null,null===(t=e.InputProps)||void 0===t?void 0:t.endAdornment,ye.createElement(ut,{onClickCancel:g,onClickSubmit:E,sx:{ml:2}})),sx:{marginY:m?.2:1}})}))}}}):ye.createElement(o,{display:"flex",alignItems:"center"},ye.createElement(a,{variant:m?"body1":"h5",noWrap:!0,"aria-labelledby":x},C),u&&ye.createElement(dt,{dense:m,onClick:h})))},Ct=function(e){var t=void 0===e?{}:e,r=t.lightWeight,o=void 0===r?100:r,a=t.darkWeight,i=void 0===a?900:a,l=n().palette;return"light"===l.mode?l.grey[o]:l.grey[i]},St=function(e){var t=e.title,r=e.subtitle,i=e.centered,l=e.children,u=e.dense,d=n().typography,m=Ct({lightWeight:200,darkWeight:800});return ye.createElement(c,{sx:{paddingBottom:u?0:1}},ye.createElement(o,{bgcolor:m,px:u?1:2,py:u?.5:1,lineHeight:u?0:void 0},ye.createElement(a,{variant:u?"body1":"h6",role:"heading","aria-level":1},t),r&&ye.createElement(a,{variant:u?"caption":"body2",role:"heading","aria-level":2,lineHeight:u?d.pxToRem(15):void 0},r)),ye.createElement(s,{container:!0,padding:1,rowSpacing:u?1:2,justifyContent:i?"center":"flex-start"},l))},wt=function(e){var t=e.label,n=e.value,r=void 0===n?0:n,a=e.maxRating,i=void 0===a?5:a,l=e.editable,c=e.dense,u=e.onEdit,s=st(r,void 0===u?function(){return null}:u),m=s.isEditing,f=s.editValue,p=s.startEdit,v=s.cancelEdit,y=s.setEditValue,h=s.submitEdit,g=ft(t);return ye.createElement(pt,{label:t,tooltip:r.toString(),dense:c},ye.createElement(o,{display:"flex",alignItems:"center"},ye.createElement(d,{"aria-labelledby":g,readOnly:!m,max:i,size:c?"small":"medium",value:m?f:r,onChange:function(e,t){Number.isNaN(t)&&e.currentTarget.value?y(parseInt(e.currentTarget.value,10)):t&&y(t)}}),l&&!m&&ye.createElement(dt,{dense:c,onClick:p}),m&&ye.createElement(ut,{onClickCancel:v,onClickSubmit:h})))},kt=function(e,t){return new Array(e).fill(t)},Tt=function(e){var t=Math.floor(Math.random()*e.length);return{index:t,item:e[t]}},It=function(e){void 0===e&&(e=12);var t=function(t,n,r){var o=t[n];return t[n]+=r,t[n]>e?(t[n]=r,!1):(t[n]==e&&(t[n]=0),o>0)};return{xs:0,sm:0,md:0,lg:0,xl:0,increment:function(e){var n=e.xs,r=void 0===n?0:n,o=e.sm,a=void 0===o?0:o,i=e.md,l=void 0===i?0:i,c=e.lg,u=void 0===c?0:c,s=e.xl,d=a||r,m=l||d,f=u||m,p=(void 0===s?0:s)||f;return{xs:t(this,"xs",r),sm:t(this,"sm",d),md:t(this,"md",m),lg:t(this,"lg",f),xl:t(this,"xl",p)}}}},Ot=function(e){var t=new FormData(e.currentTarget),n={};return t.forEach((function(e,t){n[t]=e})),n},Pt={root:"RdsValueItem-root",content:"RdsValueItem-content"},$t=function(e){var t=e.children,n=e.bordered,r=void 0===n||n,a=bt(e,["children","bordered"]),i=function(e,t){var n="solid ".concat(t," 1px"),r="none";if(e){if(Array.isArray(e))return e.map((function(e){return e?n:r}));if("object"==typeof e){var o={};return Object.entries(e).forEach((function(e){var t=e[0],a=e[1];o[t]=a?n:r})),o}return n}}(r,Ct({lightWeight:200,darkWeight:800}));return ye.createElement(s,gt({item:!0,className:Pt.root},a),ye.createElement(o,{className:Pt.content,px:1,borderLeft:i},t))},zt={root:"RdsBullet-root"},Rt=function(e){var t=e.variant,n=void 0===t?"primary":t,r=e.sx;return ye.createElement(m,{color:n,variant:"dot",className:zt.root,role:"bullet","aria-describedby":n,sx:r})},jt={root:"RdsLabel-root"},At=function(e){var t=e.text,r=e.variant,a=void 0===r?"default":r,i=e.textTransform,l=void 0===i?"capitalize":i,c=e.sx,u=n(),s=u.palette,d=u.typography,m={default:"light"===s.mode?s.grey[100]:s.grey[900],primary:s.primary.light,secondary:s.secondary.light,info:s.info.light,warning:s.warning.light,error:s.error.light,success:s.success.light},f={default:s.getContrastText(m.default),primary:s.primary.contrastText,secondary:s.secondary.contrastText,info:s.info.contrastText,warning:s.warning.contrastText,error:s.error.contrastText,success:s.success.contrastText};return ye.createElement(o,{height:24,minWidth:22,display:"inline-flex",justifyContent:"center",alignItems:"center",bgcolor:m[a],color:f[a],fontSize:d.caption.fontSize,fontWeight:d.fontWeightBold,lineHeight:0,textTransform:l,whiteSpace:"nowrap",borderRadius:2,role:"label","aria-label":"".concat(t," ").concat(a," label"),py:0,px:1,sx:gt({cursor:"default"},c)},t)},Wt=Ee((function(e,t){var n=e.href,r=bt(e,["href"]);return ye.createElement(Fe,gt({ref:t,to:n},r))})),Nt=Ee((function(e,t){return ye.createElement(f,gt({},e,{component:Wt}))})),Mt=new Error("NotificationCenterContext.Provider is required and was undefined"),Dt=ye.createContext(void 0),Vt=function(){var e=ye.useContext(Dt);if(void 0===e)throw Mt;return e},Ft=function(e){var t=e.children,n=e.autoHideDuration,r=void 0===n?6e3:n,o=he(void 0),a=o[0],i=o[1],l=he(!1),c=l[0],u=l[1],s=function(){u(!1)};return ye.createElement(Dt.Provider,{value:{show:function(e){i(e),u(!0)},hide:s}},ye.createElement(p,{open:c,autoHideDuration:r,onClose:s,anchorOrigin:{vertical:"top",horizontal:"right"}},ye.createElement(v,{onClose:s,severity:null==a?void 0:a.severity,"aria-label":null==a?void 0:a.severity,sx:{width:"100%"}},(null==a?void 0:a.title)&&ye.createElement(y,null,null==a?void 0:a.title),null==a?void 0:a.message)),t)},_t=function(e,t,n){var r=n.from,o=n.to,a=ge(),i=Vt().show;be((function(){a.current===r&&t===o&&i(e),a.current=t}),[t])},Lt=xe([0,function(){return null}]),Bt=Lt.Provider,qt=function(){return Ce(Lt)},Ht=function(e){var t=e.children,n=e.initialValue,r=he(void 0===n?0:n);return ye.createElement(Bt,{value:r},t)},Ut=function(e){var r=e.title,i=e.subtitle,l=e.preset,c=void 0===l?"default":l,u=e.actionsVariant,s=void 0===u?"outlined":u,d=e.breadcrumbs,m=e.actions,f=e.tabs,p=e.tabsMode,v=void 0===p?"panel":p,y=e.navigationButton,x=_e(),C=n().palette,S=Ct(),w=qt(),k=w[0],T=w[1],I={default:S,primary:C.primary.main,secondary:C.secondary.main,inherit:"inherit",transparent:"transparent"},O=I[c],P={default:C.getContrastText(I.default),primary:C.primary.contrastText,secondary:C.secondary.contrastText,inherit:"inherit",transparent:C.text.primary}[c],$="panel"===v?k:null==f?void 0:f.findIndex((function(e){return e.href===x.pathname}));return ye.createElement(o,{bgcolor:O,color:P},ye.createElement(h,null,ye.createElement(o,{sx:{py:3,display:"flex",flexDirection:"row",justifyContent:"space-between"}},ye.createElement(o,null,y&&ye.createElement(t,{href:y.href,size:"small",color:"inherit",LinkComponent:Nt,startIcon:y.icon,sx:{mb:1}},y.text),(null==d?void 0:d.length)&&ye.createElement(g,{color:"inherit",separator:"›","aria-label":"breadcrumb",sx:{marginTop:1}},d.map((function(e){var t=e.id,n=e.link,r=e.text;return ye.createElement(Nt,{key:t,underline:"hover",color:"inherit",href:n,variant:"body2",role:"link"},r)}))),ye.createElement(a,{variant:"h4",role:"heading","aria-level":1},r),i&&ye.createElement(a,{variant:"body1",role:"heading","aria-level":2},i)),m&&ye.createElement(o,null,m.map((function(e,n){var r=e.disabled,o=e.id,a=e.href,i=e.onClick,l=e.text;return ye.createElement(t,{component:a?Nt:"button",role:"button",color:"inherit",disabled:r,key:o,variant:s,size:"small",href:a,onClick:i,sx:{mr:n!=m.length-1?1:0}},l)})))),f&&ye.createElement(b,{value:$,textColor:"inherit",onChange:"panel"===v?function(e,t){return T(t)}:void 0},f.map((function(e){var t=e.id,n=e.label,r=e.disabled,o=e.href,a={label:n,disabled:r};return"panel"===v?ye.createElement(E,gt({key:t},a)):ye.createElement(E,gt({key:t},a,{component:Nt,href:o}))})))))},Yt={overrides:{h1:{component:a,props:{gutterBottom:!0,variant:"h5"}},h2:{component:a,props:{gutterBottom:!0,variant:"h6"}},h3:{component:a,props:{gutterBottom:!0,variant:"subtitle1"}},h4:{component:a,props:{gutterBottom:!0,variant:"caption",paragraph:!0}},p:{component:a,props:{paragraph:!0}},a:{component:f},li:{component:"li"}}},Jt=function(e){var t=e.content,n=e.options,r=void 0===n?Yt:n;return ye.createElement(Je,{options:r},t)},Xt=function(e){var t,l,u=e.markdown,s=e.content,d=e.spacing,m=void 0===d?0:d,f=e.children,p=e.sx,v=n(),y=v.spacing,h=v.typography;u?t=u||"":Array.isArray(s)?(l=s.map((function(e,t){return ye.createElement(a,{key:t,sx:{pb:m}},e)})),t=s.join("\n")):(l=ye.createElement(a,null,s),t=s||"");var g=u&&ye.createElement(Jt,{content:u});return ye.createElement(c,{sx:gt({position:"relative",pl:2,pr:4,py:1,backgroundColor:Ue[800],color:"white"},p)},ye.createElement(o,{display:"flex",flexDirection:"row"},ye.createElement(o,{width:1},f||g||l),ye.createElement(o,{sx:{position:"absolute",top:y(.5),right:y(.5)}},t&&ye.createElement(r,{"aria-label":"copy board content",color:"inherit",onClick:function(){return navigator.clipboard.writeText(t)}},ye.createElement(i,{title:"Copy"},ye.createElement(Xe,{sx:{fontSize:h.pxToRem(18)}}))))))},Gt=function(e){var t,n=e.label,r=e.value,o=e.placeholder,a=void 0===o?mt:o,i=e.variant,l=ft(n);return t=Array.isArray(r)?r.map((function(e,t){return ye.createElement(At,{text:e.toString()||a,variant:Array.isArray(i)?i[t]:i,key:t})})):ye.createElement(At,{text:(null==r?void 0:r.toString())||a,variant:Array.isArray(i)?i[0]:i}),ye.createElement(pt,{label:n},ye.createElement(s,{container:!0,gap:1,"aria-labelledby":l},t))},Kt=function(){return ye.createElement(o,{width:1,height:1,display:"flex",justifyContent:"center",alignItems:"center"},ye.createElement(x,null))};function Qt(e){var t=e.fetching,n=void 0!==t&&t,r=e.loading,a=void 0!==r&&r,i=e.error,l=e.success,c=e.children,u=Array.isArray(n)?n.some((function(e){return e})):n;return(Array.isArray(a)?a.some((function(e){return e})):a)?ye.createElement(Kt,null):i?ye.createElement(v,{severity:"error",role:"alert","aria-describedby":"error"},i.name&&ye.createElement(y,{role:"heading"},i.name),i.message):ye.createElement(o,null,l&&ye.createElement(v,{severity:"success",role:"alert","aria-describedby":"success",sx:{mb:2}},l.name&&ye.createElement(y,{role:"heading"},l.name),l.message),u&&ye.createElement(C,{sx:{width:1,mb:1}}),c)}var Zt=function(e){var t=e.children;return ye.createElement(h,{component:"main",sx:{py:3,flexGrow:1}},t)};function en(e){var t=e.children,n=e.centerVertical,r=void 0===n||n,a=e.centerHorizontal,i=void 0===a||a,l=e.sx;return ye.createElement(o,{width:1,height:1,sx:gt(gt({},l),{display:"flex",flexDirection:"column",justifyContent:r?"center":"flex-start",alignItems:i?"center":"flex-start"})},t)}var tn=xe(void 0),nn=tn.Provider,rn=function(){return Ce(tn)},on=function(e){var t=e.items,r=e.defaultSelectedItem,o=e.children,a=e.onSelectedItemChange,l=void 0===a?function(){return null}:a,u=Ct(),d=n(),m=d.palette,f=d.typography,p=he(r),v=p[0],y=p[1];return ye.createElement(nn,{value:v},ye.createElement(s,{container:!0,bgcolor:u,height:1},ye.createElement(s,{item:!0,xs:3,pl:1,height:1},ye.createElement(S,{sx:{height:1,overflowY:"auto"}},t.map((function(e){var t=e.id,n=e.text,r=e.tooltip,o=t===v,a=ye.createElement(w,{key:t,dense:!0,selected:o,disableRipple:!0,onClick:function(){return function(e){y(e),l(e)}(t)},"aria-label":n,sx:{backgroundColor:"transparent !important"}},ye.createElement(k,{primary:n,primaryTypographyProps:{fontWeight:o?f.fontWeightBold:void 0,color:o?f.body1.color:Ye[600]}}));return r?ye.createElement(i,{key:t,title:r,enterDelay:1500,placement:"right"},a):a})))),ye.createElement(s,{item:!0,xs:9,pl:2,py:1,pr:1},ye.createElement(c,{elevation:0,sx:{width:1,height:1,backgroundColor:m.background.paper}},o))))},an=xe(void 0),ln=new Error("DrawerContext.Provider is required and was undefined"),cn=function(){var e=Ce(an);if(void 0===e)throw ln;return e},un=function(e){return{width:240,transition:e.transitions.create("width",{easing:e.transitions.easing.sharp,duration:e.transitions.duration.enteringScreen}),overflowX:"hidden"}},sn=function(e){var t;return(t={transition:e.transitions.create("width",{easing:e.transitions.easing.sharp,duration:e.transitions.duration.leavingScreen}),overflowX:"hidden",width:"calc(".concat(e.spacing(7)," + 1px)")})[e.breakpoints.up("sm")]={width:"calc(".concat(e.spacing(8)," + 1px)")},t},dn=T("div")((function(e){var t=e.theme;return gt({display:"flex",alignItems:"center",justifyContent:"flex-end",padding:t.spacing(0,1)},t.mixins.toolbar)})),mn={temporary:!0,mini:!0,persistent:!0,clipped:!1},fn={temporary:"temporary",mini:"permanent",clipped:"permanent",persistent:"persistent"},pn=function(){return{}},vn={mini:function(e,t){var n;return(n={boxSizing:"border-box"})["& .".concat($.root)]={zIndex:t.zIndex.drawer-1},n},temporary:pn,clipped:pn,persistent:pn},yn=function(e){var t,o,a=e.children,i=bt(e,["children"]),l=n(),c=cn(),u=c.state,s=c.switchState,d=c.underAppBar,m=c.close,f=c.drawerWidth,p=c.variant,v=gt(gt(gt({width:f,flexShrink:0,whiteSpace:"nowrap"},"open"===u&&gt(gt({},un(l)),((t={})["& .".concat(I.paper)]=un(l),t))),"open"!==u&&gt(gt({},sn(l)),((o={})["& .".concat(I.paper)]=sn(l),o))),vn[p](u,l));return ye.createElement(O,gt({open:"open"===u,variant:fn[p],role:"menu","aria-hidden":"close"===u,onClose:m,sx:v},i),ye.createElement(dn,null,!d&&mn[p]&&ye.createElement(r,{onClick:s},ye.createElement(Ge,null))),ye.createElement(P,null),a)},hn={temporary:"close",mini:"collapse",clipped:"open",persistent:"close"},gn={temporary:["close","open"],mini:["collapse","open"],clipped:["open","open"],persistent:["close","open"]},bn=function(e){var t=e.children,n=e.initialState,r=e.variant,o=void 0===r?"temporary":r,a=e.drawerWidth,i=void 0===a?240:a,l=e.underAppBar,c=void 0!==l&&l,u=e.selectedItemId,s=e.onStateChange,d=void 0===s?function(){return null}:s,m=he(n||hn[o]),f=m[0],p=m[1],v=function(e){d(e),p(e)};return ye.createElement(an.Provider,{value:{state:f,variant:o,selectedItemId:u,underAppBar:c,drawerWidth:i,switchState:function(){return v(gn[o]["open"===f?0:1])},collapse:function(){return v("collapse")},close:function(){return v("close")},open:function(){return v("open")},setState:p}},t)},En=T(z,{shouldForwardProp:function(e){return"size"!==e}})((function(e){var t=e.size,n=e.theme;return{lineHeight:"small"===t?n.typography.pxToRem(40):void 0}})),xn=function(e,t){return{color:t?e.palette.primary.main:void 0,fontWeight:t?e.typography.fontWeightBold:e.typography.fontWeightMedium}},Cn=function(e){var t=e.text,r=e.icon,o=e.selected,a=e.items,i=e.size,l=void 0===i?"medium":i,c=e.level,u=e.sx,s=void 0===u?{}:u,d=cn().state,m=ge(null),f=n(),p=f.palette,v=f.spacing,y=he(!1),h=y[0],g=y[1],b=xn(n(),o),E=b.color,x=b.fontWeight,C=ye.createElement(S,{component:"div",disablePadding:!0},a.map((function(e){return ye.createElement(Tn,{key:e.id,level:c+1,item:e,size:l})}))),T="collapse"===d&&0===c?{position:"absolute",right:0}:{};return ye.createElement(ye.Fragment,null,ye.createElement(w,{ref:m,selected:o,"aria-label":t,onClick:function(){return g((function(e){return!e}))},dense:"small"===l,sx:gt(gt({},s),{pl:"open"===d?v(2+1.5*c):void 0,backgroundColor:h?p.action.hover:void 0})},r&&ye.createElement(R,{sx:{color:E}},r),ye.createElement(k,{disableTypography:!0,primary:t,sx:{color:E,fontWeight:x,opacity:"collapse"===d&&0===c?0:void 0}}),h&&"open"===d?ye.createElement(Ke,{sx:[{color:E,ml:2},T]}):ye.createElement(Qe,{sx:[{color:E,ml:2},T]})),"open"===d?ye.createElement(j,{in:h,timeout:"auto",unmountOnExit:!0,"aria-label":"".concat(t," collapse submenu")},C):ye.createElement(A,{open:h,PaperProps:{elevation:0,variant:"outlined"},"aria-label":"".concat(t," popover submenu"),anchorEl:m.current,onClose:function(){return g(!1)},anchorOrigin:{vertical:"top",horizontal:"right"}},C))},Sn=T(Nt)((function(e){return{color:e.theme.palette.text.primary}})),wn={minWidth:0,justifyContent:"center",marginRight:"auto"},kn=function(e){var t=e.text,r=e.icon,o=e.avatar,a=e.label,i=e.bullet,l=e.href,c=e.selected,u=e.size,s=void 0===u?"medium":u,d=e.level,m=e.sx,f=cn().state,p=n(),v=xn(p,c),y=v.color,h=v.fontWeight;return ye.createElement(w,{LinkComponent:Sn,dense:"small"===s,"aria-label":t,href:l,selected:c,sx:gt(gt(gt({},m),{pl:"open"===f?p.spacing(2+1.5*d):void 0}),"collapse"===f&&{paddingHorizontal:p.spacing(2.5),justifyContent:"center"})},r&&ye.createElement(R,{sx:gt({color:y},"collapse"===f&&0===d&&wn)},r),o&&ye.createElement(W,{sx:gt({},"collapse"===f&&0===d&&wn)},ye.createElement(N,{alt:o.alt,src:o.src,sx:gt(gt({},"small"===s&&{width:24,height:24}),"collapse"===f&&{width:30,height:30})})),ye.createElement(k,{disableTypography:!0,primary:t,sx:{color:y,fontWeight:h,opacity:"collapse"===f&&0===d?0:void 0}}),a&&"open"===f&&ye.createElement(At,{text:a.text,variant:a.variant,sx:{ml:2}}),i&&"open"===f&&ye.createElement(Rt,{variant:i.variant,sx:{ml:2}}))},Tn=function(e){var t=e.item,n=e.size,r=void 0===n?"medium":n,o=e.level,a=void 0===o?0:o,i=cn().selectedItemId;if("items"in t){var l=t.id,c=t.text,u=t.icon,s=t.items,d=s.some((function(e){return e.id===i}));return ye.createElement(Cn,{size:r,selected:l===i||d,text:c,icon:u,items:s,level:a})}l=t.id,c=t.text,u=t.icon;var m=t.avatar,f=t.label,p=t.bullet,v=t.href;return ye.createElement(kn,{selected:l===i,size:r,text:c,icon:u,avatar:m,label:f,bullet:p,href:v,level:a})},In=function(e){var t=e.title,r=e.items,o=e.size,a=void 0===o?"medium":o,i=cn().state,l=n().spacing;return ye.createElement(ye.Fragment,null,t&&"open"===i&&ye.createElement(En,{size:a,role:"heading"},t),ye.createElement(S,{sx:{paddingTop:"small"===a?l(0):void 0,paddingY:"collapse"===i?0:void 0}},r.map((function(e){return ye.createElement(Tn,{key:e.id,item:e,size:a})}))))},On=function(e){var t=e.nav.items,n=e.size,r=void 0===n?"medium":n;return ye.createElement(ye.Fragment,null,t.map((function(e,t){var n=e.title,o=e.items;return ye.createElement(In,{key:t,title:n,items:o,size:r})})))},Pn={temporary:!1,mini:!0,persistent:!0,clipped:!0},$n={temporary:function(){return!0},mini:function(e){return"open"!==e},persistent:function(){return!0},clipped:function(){return!1}},zn=function(e){var t=e.title,o=e.sx,i=e.children,l=bt(e,["title","sx","children"]),c=n(),u=cn(),s=u.state,d=u.variant,m=u.switchState,f=u.drawerWidth,p=u.underAppBar,v=Pn[d]&&!p&&gt({transition:c.transitions.create(["width","margin"],{easing:c.transitions.easing.sharp,duration:c.transitions.duration.leavingScreen})},"open"===s&&{marginLeft:f,width:"calc(100% - ".concat(f,"px)"),transition:c.transitions.create(["width","margin"],{easing:c.transitions.easing.sharp,duration:c.transitions.duration.enteringScreen})})||{};return ve.createElement(M,gt({position:p?"fixed":void 0},l,{sx:gt(gt(gt({},o),v),{zIndex:function(e){return e.zIndex.drawer+(p?1:0)}})}),ve.createElement(D,null,ve.createElement(r,{color:"inherit","aria-label":"open drawer",onClick:m,edge:"start",sx:{marginRight:5,display:$n[d](s)?void 0:"none"}},ve.createElement(Ze,null)),t&&ve.createElement(a,{variant:"h6",component:"h1",role:"heading","aria-level":1,noWrap:!0},t),i))},Rn={temporary:!1,mini:!0,clipped:!0,persistent:!0},jn=T("div")((function(e){var t=e.theme,r=n().spacing,o=cn(),a=o.drawerWidth,i=o.state,l=o.variant;return{marginLeft:Rn[l]?"open"===i?a:"collapse"===i?r(8):0:0,transition:t.transitions.create("margin",{easing:t.transitions.easing.sharp,duration:t.transitions.duration.leavingScreen})}})),An=function(e){var t=e.children;return ye.createElement(jn,null,ye.createElement(dn,null),t)},Wn={small:15,medium:20},Nn=function(e){var t=e.label,n=e.value,r=e.loading,a=void 0!==r&&r,i=e.fetching,l=void 0!==i&&i,c=e.size,u=void 0===c?"medium":c,s=e.fullWidth,d=void 0!==s&&s,m=e.color,f=e.children,p=e.onChange,v=Se(),y=T(V)((function(){return m?{label:{color:m},".MuiOutlinedInput-notchedOutline":{borderColor:"".concat(m," !important")},".MuiInputBase-root":{color:m},".MuiSelect-icon":{fill:m}}:{}}));return ye.createElement(y,{fullWidth:d},ye.createElement(F,{id:v},t),ye.createElement(_,{labelId:v,id:v,value:n,label:t,onChange:p,disabled:l,size:u,renderValue:function(e){return l?ye.createElement(en,{centerVertical:!0,centerHorizontal:!0},ye.createElement(x,{color:"inherit",size:Wn[u]})):a?ye.createElement(o,{display:"flex",flexDirection:"column"},e,ye.createElement(C,{color:"inherit",sx:{position:"absolute",left:0,right:0,bottom:0}})):e}},f))},Mn=function(e){var t=e.title,n=e.subtitle,r=e.loading,i=e.error,c=e.onSubmitSignIn,u=he(""),s=u[0],d=u[1],m=he(""),f=m[0],p=m[1];return ye.createElement(ye.Fragment,null,ye.createElement(o,{marginBottom:2},ye.createElement(a,{component:"h1",variant:"h4"},t),ye.createElement(a,{variant:"body1"},n)),ye.createElement(o,{component:"form",onSubmit:function(e){var t,n;e.preventDefault(),d(""),p("");var r=new FormData(e.currentTarget),o=null===(t=r.get("email"))||void 0===t?void 0:t.toString(),a=null===(n=r.get("password"))||void 0===n?void 0:n.toString();o||d("Please fill out this field"),a||p("Please fill out this field"),o&&a&&c(o,a)}},i&&ye.createElement(L,{width:"100%",marginTop:1},ye.createElement(v,{variant:"filled",severity:"error"},i.message)),ye.createElement(l,{margin:"normal",fullWidth:!0,id:"email",label:"Email Address",name:"email",autoComplete:"email",autoFocus:!0,disabled:r,type:"email",inputProps:{role:"input"},error:!!s,helperText:s}),ye.createElement(l,{margin:"normal",fullWidth:!0,role:"input",name:"password",label:"Password",type:"password",id:"password",disabled:r,autoComplete:"current-password",inputProps:{role:"input"},error:!!f,helperText:f}),ye.createElement(et,{type:"submit",fullWidth:!0,variant:"contained",loading:r,disabled:r,role:"button",sx:{mt:2}},"Sign In")))};function Dn(e,t){return"production"===process.env.NODE_ENV?()=>null:function(...n){return e(...n)||t(...n)}}var Vn,Fn={exports:{}},_n={exports:{}},Ln={};var Bn,qn,Hn,Un,Yn,Jn,Xn,Gn,Kn,Qn,Zn,er,tr,nr,rr={};
1
+ import{InputAdornment as e,Button as t,useTheme as n,IconButton as r,Box as o,Typography as a,Tooltip as i,TextField as l,Paper as c,Switch as u,Grid as s,Rating as d,Badge as m,Link as f,Snackbar as p,Alert as v,AlertTitle as y,CircularProgress as h,Container as g,Breadcrumbs as b,Tabs as E,Tab as x,LinearProgress as C,List as S,ListItemButton as w,ListItemText as k,styled as T,drawerClasses as I,Drawer as O,Divider as P,paperClasses as $,ListSubheader as z,ListItemIcon as R,Collapse as j,Popover as A,ListItemAvatar as W,Avatar as N,AppBar as M,Toolbar as D,FormControl as V,InputLabel as F,Select as _,Stack as L,outlinedInputClasses as B,inputLabelClasses as q,circularProgressClasses as H,linearProgressClasses as U,autocompleteClasses as Y,iconButtonClasses as J,OutlinedInput as X,FormHelperText as G,Autocomplete as K,Dialog as Q,DialogTitle as Z,DialogContent as ee,DialogActions as te,DialogContentText as ne,TableHead as re,TableRow as oe,TableCell as ae,TableSortLabel as ie,TableContainer as le,Table as ce,TableBody as ue,Skeleton as se,alertClasses as de,FormControlLabel as me,Checkbox as fe,MenuItem as pe,Menu as ve}from"@mui/material";import*as ye from"react";import he,{useState as ge,useRef as be,useEffect as Ee,forwardRef as xe,createContext as Ce,useContext as Se,useId as we,useMemo as ke}from"react";import Te from"@mui/icons-material/Check";import Ie from"@mui/icons-material/Clear";import Oe from"@mui/icons-material/Edit";import Pe from"@mui/icons-material/Close";import{format as $e,isAfter as ze,isSameDay as Re,startOfWeek as je,endOfWeek as Ae}from"date-fns";import{DateTimePicker as We,TimePicker as Ne,DatePicker as Me,DateCalendar as De,PickersDay as Ve,DesktopDatePicker as Fe}from"@mui/x-date-pickers";import{Link as _e,useLocation as Le,useNavigate as Be,useParams as qe,Routes as He,Route as Ue}from"react-router-dom";import{blueGrey as Ye,grey as Je}from"@mui/material/colors";import Xe from"markdown-to-jsx";import Ge from"@mui/icons-material/ContentCopy";import Ke from"@mui/icons-material/ChevronLeft";import Qe from"@mui/icons-material/ExpandMore";import Ze from"@mui/icons-material/ChevronRight";import et from"@mui/icons-material/Menu";import{LoadingButton as tt}from"@mui/lab";import nt from"@mui/icons-material/Event";import{isBefore as rt}from"date-fns/esm";import ot from"@mui/icons-material/Search";import{loremIpsum as at}from"lorem-ipsum";import it from"@mui/icons-material/ExpandLess";import lt from"@mui/icons-material/ReportProblem";import{DataGrid as ct}from"@mui/x-data-grid";import ut from"@mui/icons-material/MoreVert";var st=function(n){var r=n.onClickCancel,o=n.onClickSubmit,a=n.sx;return he.createElement(e,{position:"end",sx:a},he.createElement(t,{variant:"contained",size:"small",color:"error","aria-label":"cancel button",startIcon:he.createElement(Ie,{sx:{fontSize:12}}),onClick:r,sx:{paddingRight:0,minWidth:0,marginRight:1}}),he.createElement(t,{variant:"contained",size:"small",color:"primary","aria-label":"submit button",startIcon:he.createElement(Te,{sx:{fontSize:12}}),onClick:o,sx:{paddingRight:0,minWidth:0}}))},dt=function(e,t){var n=ge(!1),r=n[0],o=n[1],a=ge(e),i=a[0],l=a[1],c=function(){o(!1),l(e)};return{isEditing:r,cancelEdit:c,editValue:i,setEditValue:l,startEdit:function(){o(!0)},submitEdit:function(){t(i),c()}}},mt=function(e){var t=e.dense,o=e.onClick,a=n().typography;return he.createElement(r,{size:"small",onClick:o,sx:{ml:t?.5:1},"aria-label":"edit button"},he.createElement(Oe,{sx:{fontSize:a.pxToRem(t?18:24)}}))},ft="-",pt=function(e){return"label-".concat(e.replace(/ /g,"-"))},vt=function(e){var t=e.label,r=e.hideLabel,l=e.tooltip,c=e.tooltipEnterDelay,u=void 0===c?2e3:c,s=e.children,d=e.dense,m=e.sx,f=n().typography,p=pt(t);return he.createElement(o,{width:1,lineHeight:d?0:void 0,sx:m},!r&&he.createElement(a,{variant:d?"caption":"subtitle2",role:"label",id:p,lineHeight:d?f.pxToRem(15):void 0},t),l?he.createElement(i,{title:l,placement:"top",enterDelay:u},s):s)},yt=function(e){var t=e.label,n=e.value,r=e.placeholder,o=void 0===r?ft:r,i=e.editable,c=e.dense,u=e.onEdit,s=void 0===u?function(){return null}:u,d=be(null),m=dt(null==n?void 0:n.toString(),s),f=m.isEditing,p=m.editValue,v=m.startEdit,y=m.cancelEdit,h=m.setEditValue,g=m.submitEdit,b=pt(t),E=(null==n?void 0:n.toString())||o,x=function(e){"Enter"===e.key&&s(e.target.value)};return Ee((function(){var e;return null===(e=d.current)||void 0===e||e.addEventListener("keypress",x),function(){var e;return null===(e=d.current)||void 0===e?void 0:e.removeEventListener("keypress",x)}}),[d.current]),he.createElement(vt,{hideLabel:f,label:t,tooltip:E,dense:c},f?he.createElement(l,{inputRef:d,value:p,label:t,size:"small",onChange:function(e){return h(e.target.value)},InputProps:{endAdornment:he.createElement(st,{onClickCancel:y,onClickSubmit:g})},sx:{marginY:c?0:1}}):he.createElement(a,{variant:c?"body1":"h5",noWrap:!0,"aria-labelledby":b},E,i&&he.createElement(mt,{dense:c,onClick:v})))},ht=function(e){var t=e.children;return he.createElement(c,{sx:{p:2}},t)},gt=function(e){var t=e.label,r=e.value,i=e.placeholder,l=void 0===i?ft:i,c=e.editable,s=e.dense,d=e.onEdit,m=void 0===d?function(){return null}:d,f=pt(t),p=n().typography,v=dt(r,m),y=v.isEditing,h=v.editValue,g=v.startEdit,b=v.cancelEdit,E=v.setEditValue,x=v.submitEdit,C={fontSize:s?p.h6.fontSize:p.h5.fontSize};return he.createElement(vt,{label:t,dense:s},y?he.createElement(o,{display:"flex",alignItems:"center"},he.createElement(u,{size:s?"small":"medium",checked:h,onChange:function(e){return E(e.target.checked)}}),he.createElement(st,{onClickCancel:b,onClickSubmit:x})):he.createElement(o,{display:"flex",alignItems:"center","aria-labelledby":f,role:"checkbox","aria-checked":r},void 0===r?he.createElement(a,{variant:"h5"},l):r?he.createElement(Te,{color:"success",sx:C}):he.createElement(Pe,{color:"error",sx:C}),c&&he.createElement(mt,{dense:s,onClick:g})))},bt=function(){return bt=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var o in t=arguments[n])Object.prototype.hasOwnProperty.call(t,o)&&(e[o]=t[o]);return e},bt.apply(this,arguments)};function Et(e,t){var n={};for(var r in e)Object.prototype.hasOwnProperty.call(e,r)&&t.indexOf(r)<0&&(n[r]=e[r]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(e);o<r.length;o++)t.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(e,r[o])&&(n[r[o]]=e[r[o]])}return n}function xt(e,t,n){if(n||2===arguments.length)for(var r,o=0,a=t.length;o<a;o++)!r&&o in t||(r||(r=Array.prototype.slice.call(t,0,o)),r[o]=t[o]);return e.concat(r||Array.prototype.slice.call(t))}"function"==typeof SuppressedError&&SuppressedError;var Ct=function(e){var t=e.label,n=e.value,r=e.format,i=e.placeholder,c=void 0===i?ft:i,u=e.editable,s=e.editInputType,d=void 0===s?"datetime":s,m=e.dense,f=e.onEdit,p=dt(n,void 0===f?function(){return null}:f),v=p.isEditing,y=p.editValue,h=p.startEdit,g=p.cancelEdit,b=p.setEditValue,E=p.submitEdit,x=pt(t),C=n&&$e(n,r)||c,S="datetime"===d?We:"time"===d?Ne:Me;return he.createElement(vt,{label:t,hideLabel:v,tooltip:C,dense:m,sx:{display:"flex",flexDirection:"column"}},v?he.createElement(S,{value:y,format:r,label:t,onChange:function(e){return b(e||void 0)},slots:{textField:function(e){var t;return he.createElement(l,bt({},e,{size:"small",InputProps:bt(bt({},e.InputProps),{endAdornment:he.createElement(he.Fragment,null,null===(t=e.InputProps)||void 0===t?void 0:t.endAdornment,he.createElement(st,{onClickCancel:g,onClickSubmit:E,sx:{ml:2}})),sx:{marginY:m?.2:1}})}))}}}):he.createElement(o,{display:"flex",alignItems:"center"},he.createElement(a,{variant:m?"body1":"h5",noWrap:!0,"aria-labelledby":x},C),u&&he.createElement(mt,{dense:m,onClick:h})))},St=function(e){var t=void 0===e?{}:e,r=t.lightWeight,o=void 0===r?100:r,a=t.darkWeight,i=void 0===a?900:a,l=n().palette;return"light"===l.mode?l.grey[o]:l.grey[i]},wt=function(e){var t=e.title,r=e.subtitle,i=e.centered,l=e.children,u=e.dense,d=n().typography,m=St({lightWeight:200,darkWeight:800});return he.createElement(c,{sx:{paddingBottom:u?0:1}},he.createElement(o,{bgcolor:m,px:u?1:2,py:u?.5:1,lineHeight:u?0:void 0},he.createElement(a,{variant:u?"body1":"h6",role:"heading","aria-level":1},t),r&&he.createElement(a,{variant:u?"caption":"body2",role:"heading","aria-level":2,lineHeight:u?d.pxToRem(15):void 0},r)),he.createElement(s,{container:!0,padding:1,rowSpacing:u?1:2,justifyContent:i?"center":"flex-start"},l))},kt=function(e){var t=e.label,n=e.value,r=void 0===n?0:n,a=e.maxRating,i=void 0===a?5:a,l=e.editable,c=e.dense,u=e.onEdit,s=dt(r,void 0===u?function(){return null}:u),m=s.isEditing,f=s.editValue,p=s.startEdit,v=s.cancelEdit,y=s.setEditValue,h=s.submitEdit,g=pt(t);return he.createElement(vt,{label:t,tooltip:r.toString(),dense:c},he.createElement(o,{display:"flex",alignItems:"center"},he.createElement(d,{"aria-labelledby":g,readOnly:!m,max:i,size:c?"small":"medium",value:m?f:r,onChange:function(e,t){Number.isNaN(t)&&e.currentTarget.value?y(parseInt(e.currentTarget.value,10)):t&&y(t)}}),l&&!m&&he.createElement(mt,{dense:c,onClick:p}),m&&he.createElement(st,{onClickCancel:v,onClickSubmit:h})))},Tt=function(e,t){return new Array(e).fill(t)},It=function(e){var t=Math.floor(Math.random()*e.length);return{index:t,item:e[t]}},Ot=function(e){void 0===e&&(e=12);var t=function(t,n,r){var o=t[n];return t[n]+=r,t[n]>e?(t[n]=r,!1):(t[n]==e&&(t[n]=0),o>0)};return{xs:0,sm:0,md:0,lg:0,xl:0,increment:function(e){var n=e.xs,r=void 0===n?0:n,o=e.sm,a=void 0===o?0:o,i=e.md,l=void 0===i?0:i,c=e.lg,u=void 0===c?0:c,s=e.xl,d=a||r,m=l||d,f=u||m,p=(void 0===s?0:s)||f;return{xs:t(this,"xs",r),sm:t(this,"sm",d),md:t(this,"md",m),lg:t(this,"lg",f),xl:t(this,"xl",p)}}}},Pt=function(e){var t=new FormData(e.currentTarget),n={};return t.forEach((function(e,t){n[t]=e})),n},$t={root:"RdsValueItem-root",content:"RdsValueItem-content"},zt=function(e){var t=e.children,n=e.bordered,r=void 0===n||n,a=Et(e,["children","bordered"]),i=function(e,t){var n="solid ".concat(t," 1px"),r="none";if(e){if(Array.isArray(e))return e.map((function(e){return e?n:r}));if("object"==typeof e){var o={};return Object.entries(e).forEach((function(e){var t=e[0],a=e[1];o[t]=a?n:r})),o}return n}}(r,St({lightWeight:200,darkWeight:800}));return he.createElement(s,bt({item:!0,className:$t.root},a),he.createElement(o,{className:$t.content,px:1,borderLeft:i},t))},Rt={root:"RdsBullet-root"},jt=function(e){var t=e.variant,n=void 0===t?"primary":t,r=e.sx;return he.createElement(m,{color:n,variant:"dot",className:Rt.root,role:"bullet","aria-describedby":n,sx:r})},At={root:"RdsLabel-root"},Wt=function(e){var t=e.text,r=e.variant,a=void 0===r?"default":r,i=e.textTransform,l=void 0===i?"capitalize":i,c=e.sx,u=n(),s=u.palette,d=u.typography,m={default:"light"===s.mode?s.grey[100]:s.grey[900],primary:s.primary.light,secondary:s.secondary.light,info:s.info.light,warning:s.warning.light,error:s.error.light,success:s.success.light},f={default:s.getContrastText(m.default),primary:s.primary.contrastText,secondary:s.secondary.contrastText,info:s.info.contrastText,warning:s.warning.contrastText,error:s.error.contrastText,success:s.success.contrastText};return he.createElement(o,{height:24,minWidth:22,display:"inline-flex",justifyContent:"center",alignItems:"center",bgcolor:m[a],color:f[a],fontSize:d.caption.fontSize,fontWeight:d.fontWeightBold,lineHeight:0,textTransform:l,whiteSpace:"nowrap",borderRadius:2,role:"label","aria-label":"".concat(t," ").concat(a," label"),py:0,px:1,sx:bt({cursor:"default"},c)},t)},Nt=xe((function(e,t){var n=e.href,r=Et(e,["href"]);return he.createElement(_e,bt({ref:t,to:n},r))})),Mt=xe((function(e,t){return he.createElement(f,bt({},e,{component:Nt}))})),Dt=new Error("NotificationCenterContext.Provider is required and was undefined"),Vt=he.createContext(void 0),Ft=function(){var e=he.useContext(Vt);if(void 0===e)throw Dt;return e},_t=function(e){var t=e.children,n=e.autoHideDuration,r=void 0===n?6e3:n,o=ge(void 0),a=o[0],i=o[1],l=ge(!1),c=l[0],u=l[1],s=function(){u(!1)};return he.createElement(Vt.Provider,{value:{show:function(e){i(e),u(!0)},hide:s}},he.createElement(p,{open:c,autoHideDuration:r,onClose:s,anchorOrigin:{vertical:"top",horizontal:"right"}},he.createElement(v,{onClose:s,severity:null==a?void 0:a.severity,"aria-label":null==a?void 0:a.severity,sx:{width:"100%"}},(null==a?void 0:a.title)&&he.createElement(y,null,null==a?void 0:a.title),null==a?void 0:a.message)),t)},Lt=function(e,t,n){var r=n.from,o=n.to,a=be(),i=Ft().show;Ee((function(){a.current===r&&t===o&&i(e),a.current=t}),[t])},Bt=Ce([0,function(){return null}]),qt=Bt.Provider,Ht=function(){return Se(Bt)},Ut=function(e){var t=e.children,n=e.initialValue,r=ge(void 0===n?0:n);return he.createElement(qt,{value:r},t)},Yt=function(e){var t=e.loading,r=e.children,o=n().typography;return t?he.createElement(h,{color:"inherit",size:o.h4.fontSize,"aria-label":"title loading"}):"string"==typeof r?he.createElement(a,{variant:"h4",role:"heading","aria-level":1},r):he.createElement(he.Fragment,null,r)},Jt=function(e){var t=e.loading,r=e.children,o=n().typography;return t?he.createElement(h,{color:"inherit",size:o.body1.fontSize,"aria-label":"subtitle loading"}):"string"==typeof r?he.createElement(a,{variant:"body1",role:"heading","aria-level":2},r):he.createElement(he.Fragment,null,r)},Xt=function(e){var r=e.title,a=void 0===r?"":r,i=e.loadingTitle,l=e.subtitle,c=e.loadingSubtitle,u=e.preset,s=void 0===u?"default":u,d=e.actionsVariant,m=void 0===d?"outlined":d,f=e.breadcrumbs,p=e.actions,v=e.tabs,y=e.tabsMode,h=void 0===y?"panel":y,C=e.navigationButton,S=Le(),w=n().palette,k=St(),T=Ht(),I=T[0],O=T[1],P={default:k,primary:w.primary.main,secondary:w.secondary.main,inherit:"inherit",transparent:"transparent"},$=P[s],z={default:w.getContrastText(P.default),primary:w.primary.contrastText,secondary:w.secondary.contrastText,inherit:"inherit",transparent:w.text.primary}[s],R="panel"===h?I:null==v?void 0:v.findIndex((function(e){return e.href===S.pathname}));return he.createElement(o,{bgcolor:$,color:z},he.createElement(g,null,he.createElement(o,{sx:{py:3,display:"flex",flexDirection:"row",justifyContent:"space-between"}},he.createElement(o,null,C&&he.createElement(t,{href:C.href,size:"small",color:"inherit",LinkComponent:Mt,startIcon:C.icon,sx:{mb:1}},C.text),(null==f?void 0:f.length)&&he.createElement(b,{color:"inherit",separator:"›","aria-label":"breadcrumb",sx:{marginTop:1}},f.map((function(e){var t=e.id,n=e.link,r=e.text;return he.createElement(Mt,{key:t,underline:"hover",color:"inherit",href:n,variant:"body2",role:"link"},r)}))),he.createElement(Yt,{loading:i},a),(l||c)&&he.createElement(Jt,{loading:c},l)),p&&he.createElement(o,null,p.map((function(e,n){var r=e.disabled,o=e.id,a=e.href,i=e.onClick,l=e.text;return he.createElement(t,{component:a?Mt:"button",role:"button",color:"inherit",disabled:r,key:o,variant:m,size:"small",href:a,onClick:i,sx:{mr:n!=p.length-1?1:0}},l)})))),v&&he.createElement(E,{value:R,textColor:"inherit",onChange:"panel"===h?function(e,t){return O(t)}:void 0},v.map((function(e){var t=e.id,n=e.label,r=e.disabled,o=e.href,a={label:n,disabled:r};return"panel"===h?he.createElement(x,bt({key:t},a)):he.createElement(x,bt({key:t},a,{component:Mt,href:o}))})))))},Gt={overrides:{h1:{component:a,props:{gutterBottom:!0,variant:"h5"}},h2:{component:a,props:{gutterBottom:!0,variant:"h6"}},h3:{component:a,props:{gutterBottom:!0,variant:"subtitle1"}},h4:{component:a,props:{gutterBottom:!0,variant:"caption",paragraph:!0}},p:{component:a,props:{paragraph:!0}},a:{component:f},li:{component:"li"}}},Kt=function(e){var t=e.content,n=e.options,r=void 0===n?Gt:n;return he.createElement(Xe,{options:r},t)},Qt=function(e){var t,l,u=e.markdown,s=e.content,d=e.spacing,m=void 0===d?0:d,f=e.children,p=e.sx,v=n(),y=v.spacing,h=v.typography;u?t=u||"":Array.isArray(s)?(l=s.map((function(e,t){return he.createElement(a,{key:t,sx:{pb:m}},e)})),t=s.join("\n")):(l=he.createElement(a,null,s),t=s||"");var g=u&&he.createElement(Kt,{content:u});return he.createElement(c,{sx:bt({position:"relative",pl:2,pr:4,py:1,backgroundColor:Ye[800],color:"white"},p)},he.createElement(o,{display:"flex",flexDirection:"row"},he.createElement(o,{width:1},f||g||l),he.createElement(o,{sx:{position:"absolute",top:y(.5),right:y(.5)}},t&&he.createElement(r,{"aria-label":"copy board content",color:"inherit",onClick:function(){return navigator.clipboard.writeText(t)}},he.createElement(i,{title:"Copy"},he.createElement(Ge,{sx:{fontSize:h.pxToRem(18)}}))))))},Zt=function(e){var t,n=e.label,r=e.value,o=e.placeholder,a=void 0===o?ft:o,i=e.variant,l=pt(n);return t=Array.isArray(r)?r.map((function(e,t){return he.createElement(Wt,{text:e.toString()||a,variant:Array.isArray(i)?i[t]:i,key:t})})):he.createElement(Wt,{text:(null==r?void 0:r.toString())||a,variant:Array.isArray(i)?i[0]:i}),he.createElement(vt,{label:n},he.createElement(s,{container:!0,gap:1,"aria-labelledby":l},t))},en=function(){return he.createElement(o,{width:1,height:1,display:"flex",justifyContent:"center",alignItems:"center"},he.createElement(h,null))};function tn(e){var t=e.fetching,n=void 0!==t&&t,r=e.loading,a=void 0!==r&&r,i=e.error,l=e.success,c=e.children,u=Array.isArray(n)?n.some((function(e){return e})):n;return(Array.isArray(a)?a.some((function(e){return e})):a)?he.createElement(en,null):i?he.createElement(v,{severity:"error",role:"alert","aria-describedby":"error"},i.name&&he.createElement(y,{role:"heading"},i.name),i.message):he.createElement(o,null,l&&he.createElement(v,{severity:"success",role:"alert","aria-describedby":"success",sx:{mb:2}},l.name&&he.createElement(y,{role:"heading"},l.name),l.message),u&&he.createElement(C,{sx:{width:1,mb:1}}),c)}var nn=function(e){var t=e.children;return he.createElement(g,{component:"main",sx:{py:3,flexGrow:1}},t)};function rn(e){var t=e.children,n=e.centerVertical,r=void 0===n||n,a=e.centerHorizontal,i=void 0===a||a,l=e.sx;return he.createElement(o,{width:1,height:1,sx:bt(bt({},l),{display:"flex",flexDirection:"column",justifyContent:r?"center":"flex-start",alignItems:i?"center":"flex-start"})},t)}var on=Ce(void 0),an=on.Provider,ln=function(){return Se(on)},cn=function(e){var t=e.items,r=e.defaultSelectedItem,o=e.colBreakpoint,a=void 0===o?3:o,l=e.children,u=e.onSelectedItemChange,d=void 0===u?function(){return null}:u,m=St(),f=n(),p=f.palette,v=f.typography,y=ge(r),h=y[0],g=y[1];return he.createElement(an,{value:h},he.createElement(s,{container:!0,bgcolor:m,height:1},he.createElement(s,{item:!0,xs:a,pl:1,height:1},he.createElement(S,{sx:{height:1,overflowY:"auto"}},t.map((function(e){var t=e.id,n=e.text,r=e.tooltip,o=t===h,a=he.createElement(w,{key:t,dense:!0,selected:o,onClick:function(){return function(e){g(e),d(e)}(t)},"aria-label":n,sx:{backgroundColor:o?"".concat(p.grey[300]," !important"):void 0}},he.createElement(k,{primary:n,primaryTypographyProps:{fontWeight:o?v.fontWeightMedium:void 0,color:o?v.body1.color:Je[600]}}));return r?he.createElement(i,{key:t,title:r,enterDelay:1500,placement:"right"},a):a})))),he.createElement(s,{item:!0,xs:12-a,pl:1,py:1,pr:1},he.createElement(c,{elevation:0,sx:{width:1,height:1,backgroundColor:p.background.paper}},l))))},un=Ce(void 0),sn=new Error("DrawerContext.Provider is required and was undefined"),dn=function(){var e=Se(un);if(void 0===e)throw sn;return e},mn=function(e){return{width:240,transition:e.transitions.create("width",{easing:e.transitions.easing.sharp,duration:e.transitions.duration.enteringScreen}),overflowX:"hidden"}},fn=function(e){var t;return(t={transition:e.transitions.create("width",{easing:e.transitions.easing.sharp,duration:e.transitions.duration.leavingScreen}),overflowX:"hidden",width:"calc(".concat(e.spacing(7)," + 1px)")})[e.breakpoints.up("sm")]={width:"calc(".concat(e.spacing(8)," + 1px)")},t},pn=T("div")((function(e){var t=e.theme;return bt({display:"flex",alignItems:"center",justifyContent:"flex-end",padding:t.spacing(0,1)},t.mixins.toolbar)})),vn={temporary:!0,mini:!0,persistent:!0,clipped:!1},yn={temporary:"temporary",mini:"permanent",clipped:"permanent",persistent:"persistent"},hn=function(){return{}},gn={mini:function(e,t){var n;return(n={boxSizing:"border-box"})["& .".concat($.root)]={zIndex:t.zIndex.drawer-1},n},temporary:hn,clipped:hn,persistent:hn},bn=function(e){var t,o,a=e.children,i=Et(e,["children"]),l=n(),c=dn(),u=c.state,s=c.switchState,d=c.underAppBar,m=c.close,f=c.drawerWidth,p=c.variant,v=bt(bt(bt({width:f,flexShrink:0,whiteSpace:"nowrap"},"open"===u&&bt(bt({},mn(l)),((t={})["& .".concat(I.paper)]=mn(l),t))),"open"!==u&&bt(bt({},fn(l)),((o={})["& .".concat(I.paper)]=fn(l),o))),gn[p](u,l));return he.createElement(O,bt({open:"open"===u,variant:yn[p],role:"menu","aria-hidden":"close"===u,onClose:m,sx:v},i),he.createElement(pn,null,!d&&vn[p]&&he.createElement(r,{onClick:s},he.createElement(Ke,null))),he.createElement(P,null),a)},En={temporary:"close",mini:"collapse",clipped:"open",persistent:"close"},xn={temporary:["close","open"],mini:["collapse","open"],clipped:["open","open"],persistent:["close","open"]},Cn=function(e){var t=e.children,n=e.initialState,r=e.variant,o=void 0===r?"temporary":r,a=e.drawerWidth,i=void 0===a?240:a,l=e.underAppBar,c=void 0!==l&&l,u=e.selectedItemId,s=e.onStateChange,d=void 0===s?function(){return null}:s,m=ge(n||En[o]),f=m[0],p=m[1],v=function(e){d(e),p(e)};return he.createElement(un.Provider,{value:{state:f,variant:o,selectedItemId:u,underAppBar:c,drawerWidth:i,switchState:function(){return v(xn[o]["open"===f?0:1])},collapse:function(){return v("collapse")},close:function(){return v("close")},open:function(){return v("open")},setState:p}},t)},Sn=T(z,{shouldForwardProp:function(e){return"size"!==e}})((function(e){var t=e.size,n=e.theme;return{lineHeight:"small"===t?n.typography.pxToRem(40):void 0}})),wn=function(e,t){return{color:t?e.palette.primary.main:void 0,fontWeight:t?e.typography.fontWeightBold:e.typography.fontWeightMedium}},kn=function(e){var t=e.text,r=e.icon,o=e.selected,a=e.items,i=e.size,l=void 0===i?"medium":i,c=e.level,u=e.sx,s=void 0===u?{}:u,d=dn().state,m=be(null),f=n(),p=f.palette,v=f.spacing,y=ge(!1),h=y[0],g=y[1],b=wn(n(),o),E=b.color,x=b.fontWeight,C=he.createElement(S,{component:"div",disablePadding:!0},a.map((function(e){return he.createElement(Pn,{key:e.id,level:c+1,item:e,size:l})}))),T="collapse"===d&&0===c?{position:"absolute",right:0}:{};return he.createElement(he.Fragment,null,he.createElement(w,{ref:m,selected:o,"aria-label":t,onClick:function(){return g((function(e){return!e}))},dense:"small"===l,sx:bt(bt({},s),{pl:"open"===d?v(2+1.5*c):void 0,backgroundColor:h?p.action.hover:void 0})},r&&he.createElement(R,{sx:{color:E}},r),he.createElement(k,{disableTypography:!0,primary:t,sx:{color:E,fontWeight:x,opacity:"collapse"===d&&0===c?0:void 0}}),h&&"open"===d?he.createElement(Qe,{sx:[{color:E,ml:2},T]}):he.createElement(Ze,{sx:[{color:E,ml:2},T]})),"open"===d?he.createElement(j,{in:h,timeout:"auto",unmountOnExit:!0,"aria-label":"".concat(t," collapse submenu")},C):he.createElement(A,{open:h,PaperProps:{elevation:0,variant:"outlined"},"aria-label":"".concat(t," popover submenu"),anchorEl:m.current,onClose:function(){return g(!1)},anchorOrigin:{vertical:"top",horizontal:"right"}},C))},Tn=T(Mt)((function(e){return{color:e.theme.palette.text.primary}})),In={minWidth:0,justifyContent:"center",marginRight:"auto"},On=function(e){var t=e.text,r=e.icon,o=e.avatar,a=e.label,i=e.bullet,l=e.href,c=e.selected,u=e.size,s=void 0===u?"medium":u,d=e.level,m=e.sx,f=dn().state,p=n(),v=wn(p,c),y=v.color,h=v.fontWeight;return he.createElement(w,{LinkComponent:Tn,dense:"small"===s,"aria-label":t,href:l,selected:c,sx:bt(bt(bt({},m),{pl:"open"===f?p.spacing(2+1.5*d):void 0}),"collapse"===f&&{paddingHorizontal:p.spacing(2.5),justifyContent:"center"})},r&&he.createElement(R,{sx:bt({color:y},"collapse"===f&&0===d&&In)},r),o&&he.createElement(W,{sx:bt({},"collapse"===f&&0===d&&In)},he.createElement(N,{alt:o.alt,src:o.src,sx:bt(bt({},"small"===s&&{width:24,height:24}),"collapse"===f&&{width:30,height:30})})),he.createElement(k,{disableTypography:!0,primary:t,sx:{color:y,fontWeight:h,opacity:"collapse"===f&&0===d?0:void 0}}),a&&"open"===f&&he.createElement(Wt,{text:a.text,variant:a.variant,sx:{ml:2}}),i&&"open"===f&&he.createElement(jt,{variant:i.variant,sx:{ml:2}}))},Pn=function(e){var t=e.item,n=e.size,r=void 0===n?"medium":n,o=e.level,a=void 0===o?0:o,i=dn().selectedItemId;if("items"in t){var l=t.id,c=t.text,u=t.icon,s=t.items,d=s.some((function(e){return e.id===i}));return he.createElement(kn,{size:r,selected:l===i||d,text:c,icon:u,items:s,level:a})}l=t.id,c=t.text,u=t.icon;var m=t.avatar,f=t.label,p=t.bullet,v=t.href;return he.createElement(On,{selected:l===i,size:r,text:c,icon:u,avatar:m,label:f,bullet:p,href:v,level:a})},$n=function(e){var t=e.title,r=e.items,o=e.size,a=void 0===o?"medium":o,i=dn().state,l=n().spacing;return he.createElement(he.Fragment,null,t&&"open"===i&&he.createElement(Sn,{size:a,role:"heading"},t),he.createElement(S,{sx:{paddingTop:"small"===a?l(0):void 0,paddingY:"collapse"===i?0:void 0}},r.map((function(e){return he.createElement(Pn,{key:e.id,item:e,size:a})}))))},zn=function(e){var t=e.nav.items,n=e.size,r=void 0===n?"medium":n;return he.createElement(he.Fragment,null,t.map((function(e,t){var n=e.title,o=e.items;return he.createElement($n,{key:t,title:n,items:o,size:r})})))},Rn={temporary:!1,mini:!0,persistent:!0,clipped:!0},jn={temporary:function(){return!0},mini:function(e){return"open"!==e},persistent:function(){return!0},clipped:function(){return!1}},An=function(e){var t=e.title,o=e.sx,i=e.children,l=Et(e,["title","sx","children"]),c=n(),u=dn(),s=u.state,d=u.variant,m=u.switchState,f=u.drawerWidth,p=u.underAppBar,v=Rn[d]&&!p&&bt({transition:c.transitions.create(["width","margin"],{easing:c.transitions.easing.sharp,duration:c.transitions.duration.leavingScreen})},"open"===s&&{marginLeft:f,width:"calc(100% - ".concat(f,"px)"),transition:c.transitions.create(["width","margin"],{easing:c.transitions.easing.sharp,duration:c.transitions.duration.enteringScreen})})||{};return ye.createElement(M,bt({position:p?"fixed":void 0},l,{sx:bt(bt(bt({},o),v),{zIndex:function(e){return e.zIndex.drawer+(p?1:0)}})}),ye.createElement(D,null,ye.createElement(r,{color:"inherit","aria-label":"open drawer",onClick:m,edge:"start",sx:{marginRight:5,display:jn[d](s)?void 0:"none"}},ye.createElement(et,null)),t&&ye.createElement(a,{variant:"h6",component:"h1",role:"heading","aria-level":1,noWrap:!0},t),i))},Wn={temporary:!1,mini:!0,clipped:!0,persistent:!0},Nn=T("div")((function(e){var t=e.theme,r=n().spacing,o=dn(),a=o.drawerWidth,i=o.state,l=o.variant;return{marginLeft:Wn[l]?"open"===i?a:"collapse"===i?r(8):0:0,transition:t.transitions.create("margin",{easing:t.transitions.easing.sharp,duration:t.transitions.duration.leavingScreen})}})),Mn=function(e){var t=e.children;return he.createElement(Nn,null,he.createElement(pn,null),t)},Dn={small:15,medium:20},Vn=function(e){var t=e.label,n=e.value,r=e.loading,a=void 0!==r&&r,i=e.fetching,l=void 0!==i&&i,c=e.size,u=void 0===c?"medium":c,s=e.fullWidth,d=void 0!==s&&s,m=e.color,f=e.children,p=e.onChange,v=we(),y=T(V)((function(){return m?{label:{color:m},".MuiOutlinedInput-notchedOutline":{borderColor:"".concat(m," !important")},".MuiInputBase-root":{color:m},".MuiSelect-icon":{fill:m}}:{}}));return he.createElement(y,{fullWidth:d},he.createElement(F,{id:v},t),he.createElement(_,{labelId:v,id:v,value:n,label:t,onChange:p,disabled:l,size:u,renderValue:function(e){return l?he.createElement(rn,{centerVertical:!0,centerHorizontal:!0},he.createElement(h,{color:"inherit",size:Dn[u]})):a?he.createElement(o,{display:"flex",flexDirection:"column"},e,he.createElement(C,{color:"inherit",sx:{position:"absolute",left:0,right:0,bottom:0}})):e}},f))},Fn=function(e){var t=e.title,n=e.subtitle,r=e.loading,i=e.error,c=e.onSubmitSignIn,u=ge(""),s=u[0],d=u[1],m=ge(""),f=m[0],p=m[1];return he.createElement(he.Fragment,null,he.createElement(o,{marginBottom:2},he.createElement(a,{component:"h1",variant:"h4"},t),he.createElement(a,{variant:"body1"},n)),he.createElement(o,{component:"form",onSubmit:function(e){var t,n;e.preventDefault(),d(""),p("");var r=new FormData(e.currentTarget),o=null===(t=r.get("email"))||void 0===t?void 0:t.toString(),a=null===(n=r.get("password"))||void 0===n?void 0:n.toString();o||d("Please fill out this field"),a||p("Please fill out this field"),o&&a&&c(o,a)}},i&&he.createElement(L,{width:"100%",marginTop:1},he.createElement(v,{variant:"filled",severity:"error"},i.message)),he.createElement(l,{margin:"normal",fullWidth:!0,id:"email",label:"Email Address",name:"email",autoComplete:"email",autoFocus:!0,disabled:r,type:"email",inputProps:{role:"input"},error:!!s,helperText:s}),he.createElement(l,{margin:"normal",fullWidth:!0,role:"input",name:"password",label:"Password",type:"password",id:"password",disabled:r,autoComplete:"current-password",inputProps:{role:"input"},error:!!f,helperText:f}),he.createElement(tt,{type:"submit",fullWidth:!0,variant:"contained",loading:r,disabled:r,role:"button",sx:{mt:2}},"Sign In")))};function _n(e,t){return"production"===process.env.NODE_ENV?()=>null:function(...n){return e(...n)||t(...n)}}var Ln,Bn={exports:{}},qn={exports:{}},Hn={};var Un,Yn,Jn,Xn,Gn,Kn,Qn,Zn,er,tr,nr,rr,or,ar,ir={};
2
2
  /** @license React v16.13.1
3
3
  * react-is.development.js
4
4
  *
@@ -6,12 +6,12 @@ import{InputAdornment as e,Button as t,useTheme as n,IconButton as r,Box as o,Ty
6
6
  *
7
7
  * This source code is licensed under the MIT license found in the
8
8
  * LICENSE file in the root directory of this source tree.
9
- */function or(){return qn||(qn=1,e=_n,"production"===process.env.NODE_ENV?e.exports=function(){if(Vn)return Ln;Vn=1;var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,s=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,f=e?Symbol.for("react.memo"):60115,p=e?Symbol.for("react.lazy"):60116,v=e?Symbol.for("react.block"):60121,y=e?Symbol.for("react.fundamental"):60117,h=e?Symbol.for("react.responder"):60118,g=e?Symbol.for("react.scope"):60119;function b(e){if("object"==typeof e&&null!==e){var m=e.$$typeof;switch(m){case t:switch(e=e.type){case c:case u:case r:case a:case o:case d:return e;default:switch(e=e&&e.$$typeof){case l:case s:case p:case f:case i:return e;default:return m}}case n:return m}}}function E(e){return b(e)===u}return Ln.AsyncMode=c,Ln.ConcurrentMode=u,Ln.ContextConsumer=l,Ln.ContextProvider=i,Ln.Element=t,Ln.ForwardRef=s,Ln.Fragment=r,Ln.Lazy=p,Ln.Memo=f,Ln.Portal=n,Ln.Profiler=a,Ln.StrictMode=o,Ln.Suspense=d,Ln.isAsyncMode=function(e){return E(e)||b(e)===c},Ln.isConcurrentMode=E,Ln.isContextConsumer=function(e){return b(e)===l},Ln.isContextProvider=function(e){return b(e)===i},Ln.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},Ln.isForwardRef=function(e){return b(e)===s},Ln.isFragment=function(e){return b(e)===r},Ln.isLazy=function(e){return b(e)===p},Ln.isMemo=function(e){return b(e)===f},Ln.isPortal=function(e){return b(e)===n},Ln.isProfiler=function(e){return b(e)===a},Ln.isStrictMode=function(e){return b(e)===o},Ln.isSuspense=function(e){return b(e)===d},Ln.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===r||e===u||e===a||e===o||e===d||e===m||"object"==typeof e&&null!==e&&(e.$$typeof===p||e.$$typeof===f||e.$$typeof===i||e.$$typeof===l||e.$$typeof===s||e.$$typeof===y||e.$$typeof===h||e.$$typeof===g||e.$$typeof===v)},Ln.typeOf=b,Ln}():e.exports=(Bn||(Bn=1,"production"!==process.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,s=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,f=e?Symbol.for("react.memo"):60115,p=e?Symbol.for("react.lazy"):60116,v=e?Symbol.for("react.block"):60121,y=e?Symbol.for("react.fundamental"):60117,h=e?Symbol.for("react.responder"):60118,g=e?Symbol.for("react.scope"):60119;function b(e){if("object"==typeof e&&null!==e){var m=e.$$typeof;switch(m){case t:var v=e.type;switch(v){case c:case u:case r:case a:case o:case d:return v;default:var y=v&&v.$$typeof;switch(y){case l:case s:case p:case f:case i:return y;default:return m}}case n:return m}}}var E=c,x=u,C=l,S=i,w=t,k=s,T=r,I=p,O=f,P=n,$=a,z=o,R=d,j=!1;function A(e){return b(e)===u}rr.AsyncMode=E,rr.ConcurrentMode=x,rr.ContextConsumer=C,rr.ContextProvider=S,rr.Element=w,rr.ForwardRef=k,rr.Fragment=T,rr.Lazy=I,rr.Memo=O,rr.Portal=P,rr.Profiler=$,rr.StrictMode=z,rr.Suspense=R,rr.isAsyncMode=function(e){return j||(j=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),A(e)||b(e)===c},rr.isConcurrentMode=A,rr.isContextConsumer=function(e){return b(e)===l},rr.isContextProvider=function(e){return b(e)===i},rr.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},rr.isForwardRef=function(e){return b(e)===s},rr.isFragment=function(e){return b(e)===r},rr.isLazy=function(e){return b(e)===p},rr.isMemo=function(e){return b(e)===f},rr.isPortal=function(e){return b(e)===n},rr.isProfiler=function(e){return b(e)===a},rr.isStrictMode=function(e){return b(e)===o},rr.isSuspense=function(e){return b(e)===d},rr.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===r||e===u||e===a||e===o||e===d||e===m||"object"==typeof e&&null!==e&&(e.$$typeof===p||e.$$typeof===f||e.$$typeof===i||e.$$typeof===l||e.$$typeof===s||e.$$typeof===y||e.$$typeof===h||e.$$typeof===g||e.$$typeof===v)},rr.typeOf=b}()),rr)),_n.exports;var e}
9
+ */function lr(){return Yn||(Yn=1,e=qn,"production"===process.env.NODE_ENV?e.exports=function(){if(Ln)return Hn;Ln=1;var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,s=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,f=e?Symbol.for("react.memo"):60115,p=e?Symbol.for("react.lazy"):60116,v=e?Symbol.for("react.block"):60121,y=e?Symbol.for("react.fundamental"):60117,h=e?Symbol.for("react.responder"):60118,g=e?Symbol.for("react.scope"):60119;function b(e){if("object"==typeof e&&null!==e){var m=e.$$typeof;switch(m){case t:switch(e=e.type){case c:case u:case r:case a:case o:case d:return e;default:switch(e=e&&e.$$typeof){case l:case s:case p:case f:case i:return e;default:return m}}case n:return m}}}function E(e){return b(e)===u}return Hn.AsyncMode=c,Hn.ConcurrentMode=u,Hn.ContextConsumer=l,Hn.ContextProvider=i,Hn.Element=t,Hn.ForwardRef=s,Hn.Fragment=r,Hn.Lazy=p,Hn.Memo=f,Hn.Portal=n,Hn.Profiler=a,Hn.StrictMode=o,Hn.Suspense=d,Hn.isAsyncMode=function(e){return E(e)||b(e)===c},Hn.isConcurrentMode=E,Hn.isContextConsumer=function(e){return b(e)===l},Hn.isContextProvider=function(e){return b(e)===i},Hn.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},Hn.isForwardRef=function(e){return b(e)===s},Hn.isFragment=function(e){return b(e)===r},Hn.isLazy=function(e){return b(e)===p},Hn.isMemo=function(e){return b(e)===f},Hn.isPortal=function(e){return b(e)===n},Hn.isProfiler=function(e){return b(e)===a},Hn.isStrictMode=function(e){return b(e)===o},Hn.isSuspense=function(e){return b(e)===d},Hn.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===r||e===u||e===a||e===o||e===d||e===m||"object"==typeof e&&null!==e&&(e.$$typeof===p||e.$$typeof===f||e.$$typeof===i||e.$$typeof===l||e.$$typeof===s||e.$$typeof===y||e.$$typeof===h||e.$$typeof===g||e.$$typeof===v)},Hn.typeOf=b,Hn}():e.exports=(Un||(Un=1,"production"!==process.env.NODE_ENV&&function(){var e="function"==typeof Symbol&&Symbol.for,t=e?Symbol.for("react.element"):60103,n=e?Symbol.for("react.portal"):60106,r=e?Symbol.for("react.fragment"):60107,o=e?Symbol.for("react.strict_mode"):60108,a=e?Symbol.for("react.profiler"):60114,i=e?Symbol.for("react.provider"):60109,l=e?Symbol.for("react.context"):60110,c=e?Symbol.for("react.async_mode"):60111,u=e?Symbol.for("react.concurrent_mode"):60111,s=e?Symbol.for("react.forward_ref"):60112,d=e?Symbol.for("react.suspense"):60113,m=e?Symbol.for("react.suspense_list"):60120,f=e?Symbol.for("react.memo"):60115,p=e?Symbol.for("react.lazy"):60116,v=e?Symbol.for("react.block"):60121,y=e?Symbol.for("react.fundamental"):60117,h=e?Symbol.for("react.responder"):60118,g=e?Symbol.for("react.scope"):60119;function b(e){if("object"==typeof e&&null!==e){var m=e.$$typeof;switch(m){case t:var v=e.type;switch(v){case c:case u:case r:case a:case o:case d:return v;default:var y=v&&v.$$typeof;switch(y){case l:case s:case p:case f:case i:return y;default:return m}}case n:return m}}}var E=c,x=u,C=l,S=i,w=t,k=s,T=r,I=p,O=f,P=n,$=a,z=o,R=d,j=!1;function A(e){return b(e)===u}ir.AsyncMode=E,ir.ConcurrentMode=x,ir.ContextConsumer=C,ir.ContextProvider=S,ir.Element=w,ir.ForwardRef=k,ir.Fragment=T,ir.Lazy=I,ir.Memo=O,ir.Portal=P,ir.Profiler=$,ir.StrictMode=z,ir.Suspense=R,ir.isAsyncMode=function(e){return j||(j=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 17+. Update your code to use ReactIs.isConcurrentMode() instead. It has the exact same API.")),A(e)||b(e)===c},ir.isConcurrentMode=A,ir.isContextConsumer=function(e){return b(e)===l},ir.isContextProvider=function(e){return b(e)===i},ir.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},ir.isForwardRef=function(e){return b(e)===s},ir.isFragment=function(e){return b(e)===r},ir.isLazy=function(e){return b(e)===p},ir.isMemo=function(e){return b(e)===f},ir.isPortal=function(e){return b(e)===n},ir.isProfiler=function(e){return b(e)===a},ir.isStrictMode=function(e){return b(e)===o},ir.isSuspense=function(e){return b(e)===d},ir.isValidElementType=function(e){return"string"==typeof e||"function"==typeof e||e===r||e===u||e===a||e===o||e===d||e===m||"object"==typeof e&&null!==e&&(e.$$typeof===p||e.$$typeof===f||e.$$typeof===i||e.$$typeof===l||e.$$typeof===s||e.$$typeof===y||e.$$typeof===h||e.$$typeof===g||e.$$typeof===v)},ir.typeOf=b}()),ir)),qn.exports;var e}
10
10
  /*
11
11
  object-assign
12
12
  (c) Sindre Sorhus
13
13
  @license MIT
14
- */function ar(){if(Un)return Hn;Un=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;return Hn=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(r,o){for(var a,i,l=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(r),c=1;c<arguments.length;c++){for(var u in a=Object(arguments[c]))t.call(a,u)&&(l[u]=a[u]);if(e){i=e(a);for(var s=0;s<i.length;s++)n.call(a,i[s])&&(l[i[s]]=a[i[s]])}}return l},Hn}function ir(){if(Jn)return Yn;Jn=1;return Yn="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}function lr(){return Gn?Xn:(Gn=1,Xn=Function.call.bind(Object.prototype.hasOwnProperty))}if("production"!==process.env.NODE_ENV){var cr=or();Fn.exports=function(){if(er)return Zn;er=1;var e=or(),t=ar(),n=ir(),r=lr(),o=function(){if(Qn)return Kn;Qn=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=ir(),n={},r=lr();e=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function o(o,a,i,l,c){if("production"!==process.env.NODE_ENV)for(var u in o)if(r(o,u)){var s;try{if("function"!=typeof o[u]){var d=Error((l||"React class")+": "+i+" type `"+u+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[u]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw d.name="Invariant Violation",d}s=o[u](a,u,l,i,null,t)}catch(e){s=e}if(!s||s instanceof Error||e((l||"React class")+": type specification of "+i+" `"+u+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof s+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),s instanceof Error&&!(s.message in n)){n[s.message]=!0;var m=c?c():"";e("Failed "+i+" type: "+s.message+(null!=m?m:""))}}}return o.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(n={})},Kn=o}(),a=function(){};function i(){return null}return"production"!==process.env.NODE_ENV&&(a=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),Zn=function(l,c){var u="function"==typeof Symbol&&Symbol.iterator,s="@@iterator",d="<<anonymous>>",m={array:y("array"),bigint:y("bigint"),bool:y("boolean"),func:y("function"),number:y("number"),object:y("object"),string:y("string"),symbol:y("symbol"),any:v(i),arrayOf:function(e){return v((function(t,r,o,a,i){if("function"!=typeof e)return new p("Property `"+i+"` of component `"+o+"` has invalid PropType notation inside arrayOf.");var l=t[r];if(!Array.isArray(l))return new p("Invalid "+a+" `"+i+"` of type `"+b(l)+"` supplied to `"+o+"`, expected an array.");for(var c=0;c<l.length;c++){var u=e(l,c,o,a,i+"["+c+"]",n);if(u instanceof Error)return u}return null}))},element:v((function(e,t,n,r,o){var a=e[t];return l(a)?null:new p("Invalid "+r+" `"+o+"` of type `"+b(a)+"` supplied to `"+n+"`, expected a single ReactElement.")})),elementType:v((function(t,n,r,o,a){var i=t[n];return e.isValidElementType(i)?null:new p("Invalid "+o+" `"+a+"` of type `"+b(i)+"` supplied to `"+r+"`, expected a single ReactElement type.")})),instanceOf:function(e){return v((function(t,n,r,o,a){if(!(t[n]instanceof e)){var i=e.name||d;return new p("Invalid "+o+" `"+a+"` of type `"+((l=t[n]).constructor&&l.constructor.name?l.constructor.name:d)+"` supplied to `"+r+"`, expected instance of `"+i+"`.")}var l;return null}))},node:v((function(e,t,n,r,o){return g(e[t])?null:new p("Invalid "+r+" `"+o+"` supplied to `"+n+"`, expected a ReactNode.")})),objectOf:function(e){return v((function(t,o,a,i,l){if("function"!=typeof e)return new p("Property `"+l+"` of component `"+a+"` has invalid PropType notation inside objectOf.");var c=t[o],u=b(c);if("object"!==u)return new p("Invalid "+i+" `"+l+"` of type `"+u+"` supplied to `"+a+"`, expected an object.");for(var s in c)if(r(c,s)){var d=e(c,s,a,i,l+"."+s,n);if(d instanceof Error)return d}return null}))},oneOf:function(e){return Array.isArray(e)?v((function(t,n,r,o,a){for(var i=t[n],l=0;l<e.length;l++)if(f(i,e[l]))return null;var c=JSON.stringify(e,(function(e,t){return"symbol"===E(t)?String(t):t}));return new p("Invalid "+o+" `"+a+"` of value `"+String(i)+"` supplied to `"+r+"`, expected one of "+c+".")})):("production"!==process.env.NODE_ENV&&a(arguments.length>1?"Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).":"Invalid argument supplied to oneOf, expected an array."),i)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&a("Invalid argument supplied to oneOfType, expected an instance of array."),i;for(var t=0;t<e.length;t++){var o=e[t];if("function"!=typeof o)return a("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+x(o)+" at index "+t+"."),i}return v((function(t,o,a,i,l){for(var c=[],u=0;u<e.length;u++){var s=(0,e[u])(t,o,a,i,l,n);if(null==s)return null;s.data&&r(s.data,"expectedType")&&c.push(s.data.expectedType)}return new p("Invalid "+i+" `"+l+"` supplied to `"+a+"`"+(c.length>0?", expected one of type ["+c.join(", ")+"]":"")+".")}))},shape:function(e){return v((function(t,r,o,a,i){var l=t[r],c=b(l);if("object"!==c)return new p("Invalid "+a+" `"+i+"` of type `"+c+"` supplied to `"+o+"`, expected `object`.");for(var u in e){var s=e[u];if("function"!=typeof s)return h(o,a,i,u,E(s));var d=s(l,u,o,a,i+"."+u,n);if(d)return d}return null}))},exact:function(e){return v((function(o,a,i,l,c){var u=o[a],s=b(u);if("object"!==s)return new p("Invalid "+l+" `"+c+"` of type `"+s+"` supplied to `"+i+"`, expected `object`.");var d=t({},o[a],e);for(var m in d){var f=e[m];if(r(e,m)&&"function"!=typeof f)return h(i,l,c,m,E(f));if(!f)return new p("Invalid "+l+" `"+c+"` key `"+m+"` supplied to `"+i+"`.\nBad object: "+JSON.stringify(o[a],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var v=f(u,m,i,l,c+"."+m,n);if(v)return v}return null}))}};function f(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function p(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function v(e){if("production"!==process.env.NODE_ENV)var t={},r=0;function o(o,i,l,u,s,m,f){if(u=u||d,m=m||l,f!==n){if(c){var v=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw v.name="Invariant Violation",v}if("production"!==process.env.NODE_ENV&&"undefined"!=typeof console){var y=u+":"+l;!t[y]&&r<3&&(a("You are manually calling a React.PropTypes validation function for the `"+m+"` prop on `"+u+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),t[y]=!0,r++)}}return null==i[l]?o?null===i[l]?new p("The "+s+" `"+m+"` is marked as required in `"+u+"`, but its value is `null`."):new p("The "+s+" `"+m+"` is marked as required in `"+u+"`, but its value is `undefined`."):null:e(i,l,u,s,m)}var i=o.bind(null,!1);return i.isRequired=o.bind(null,!0),i}function y(e){return v((function(t,n,r,o,a,i){var l=t[n];return b(l)!==e?new p("Invalid "+o+" `"+a+"` of type `"+E(l)+"` supplied to `"+r+"`, expected `"+e+"`.",{expectedType:e}):null}))}function h(e,t,n,r,o){return new p((e||"React class")+": "+t+" type `"+n+"."+r+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+o+"`.")}function g(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(g);if(null===e||l(e))return!0;var t=function(e){var t=e&&(u&&e[u]||e[s]);if("function"==typeof t)return t}(e);if(!t)return!1;var n,r=t.call(e);if(t!==e.entries){for(;!(n=r.next()).done;)if(!g(n.value))return!1}else for(;!(n=r.next()).done;){var o=n.value;if(o&&!g(o[1]))return!1}return!0;default:return!1}}function b(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function E(e){if(null==e)return""+e;var t=b(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function x(e){var t=E(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return p.prototype=Error.prototype,m.checkPropTypes=o,m.resetWarningCache=o.resetWarningCache,m.PropTypes=m,m},Zn}()(cr.isElement,!0)}else Fn.exports=function(){if(nr)return tr;nr=1;var e=ir();function t(){}function n(){}return n.resetWarningCache=t,tr=function(){function r(t,n,r,o,a,i){if(i!==e){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function o(){return r}r.isRequired=r;var a={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return a.PropTypes=a,a}}()();function ur(e,t,n,r,o){const a=e[t],i=o||t;if(null==a||"undefined"==typeof window)return null;let l;const c=a.type;return"function"!=typeof c||function(e){const{prototype:t={}}=e;return Boolean(t.isReactComponent)}(c)||(l="Did you accidentally use a plain function component for an element instead?"),void 0!==l?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}Dn(Fn.exports.element,ur).isRequired=Dn(Fn.exports.element.isRequired,ur),Dn(Fn.exports.elementType,(function(e,t,n,r,o){const a=e[t],i=o||t;if(null==a||"undefined"==typeof window)return null;let l;return"function"!=typeof a||function(e){const{prototype:t={}}=e;return Boolean(t.isReactComponent)}(a)||(l="Did you accidentally provide a plain function component instead?"),void 0!==l?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element type that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}));var sr,dr={};var mr,fr,pr={};
14
+ */function cr(){if(Xn)return Jn;Xn=1;var e=Object.getOwnPropertySymbols,t=Object.prototype.hasOwnProperty,n=Object.prototype.propertyIsEnumerable;return Jn=function(){try{if(!Object.assign)return!1;var e=new String("abc");if(e[5]="de","5"===Object.getOwnPropertyNames(e)[0])return!1;for(var t={},n=0;n<10;n++)t["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(t).map((function(e){return t[e]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(e){r[e]=e})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(e){return!1}}()?Object.assign:function(r,o){for(var a,i,l=function(e){if(null==e)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(e)}(r),c=1;c<arguments.length;c++){for(var u in a=Object(arguments[c]))t.call(a,u)&&(l[u]=a[u]);if(e){i=e(a);for(var s=0;s<i.length;s++)n.call(a,i[s])&&(l[i[s]]=a[i[s]])}}return l},Jn}function ur(){if(Kn)return Gn;Kn=1;return Gn="SECRET_DO_NOT_PASS_THIS_OR_YOU_WILL_BE_FIRED"}function sr(){return Zn?Qn:(Zn=1,Qn=Function.call.bind(Object.prototype.hasOwnProperty))}if("production"!==process.env.NODE_ENV){var dr=lr();Bn.exports=function(){if(rr)return nr;rr=1;var e=lr(),t=cr(),n=ur(),r=sr(),o=function(){if(tr)return er;tr=1;var e=function(){};if("production"!==process.env.NODE_ENV){var t=ur(),n={},r=sr();e=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}}function o(o,a,i,l,c){if("production"!==process.env.NODE_ENV)for(var u in o)if(r(o,u)){var s;try{if("function"!=typeof o[u]){var d=Error((l||"React class")+": "+i+" type `"+u+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+typeof o[u]+"`.This often happens because of typos such as `PropTypes.function` instead of `PropTypes.func`.");throw d.name="Invariant Violation",d}s=o[u](a,u,l,i,null,t)}catch(e){s=e}if(!s||s instanceof Error||e((l||"React class")+": type specification of "+i+" `"+u+"` is invalid; the type checker function must return `null` or an `Error` but returned a "+typeof s+". You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument)."),s instanceof Error&&!(s.message in n)){n[s.message]=!0;var m=c?c():"";e("Failed "+i+" type: "+s.message+(null!=m?m:""))}}}return o.resetWarningCache=function(){"production"!==process.env.NODE_ENV&&(n={})},er=o}(),a=function(){};function i(){return null}return"production"!==process.env.NODE_ENV&&(a=function(e){var t="Warning: "+e;"undefined"!=typeof console&&console.error(t);try{throw new Error(t)}catch(e){}}),nr=function(l,c){var u="function"==typeof Symbol&&Symbol.iterator,s="@@iterator",d="<<anonymous>>",m={array:y("array"),bigint:y("bigint"),bool:y("boolean"),func:y("function"),number:y("number"),object:y("object"),string:y("string"),symbol:y("symbol"),any:v(i),arrayOf:function(e){return v((function(t,r,o,a,i){if("function"!=typeof e)return new p("Property `"+i+"` of component `"+o+"` has invalid PropType notation inside arrayOf.");var l=t[r];if(!Array.isArray(l))return new p("Invalid "+a+" `"+i+"` of type `"+b(l)+"` supplied to `"+o+"`, expected an array.");for(var c=0;c<l.length;c++){var u=e(l,c,o,a,i+"["+c+"]",n);if(u instanceof Error)return u}return null}))},element:v((function(e,t,n,r,o){var a=e[t];return l(a)?null:new p("Invalid "+r+" `"+o+"` of type `"+b(a)+"` supplied to `"+n+"`, expected a single ReactElement.")})),elementType:v((function(t,n,r,o,a){var i=t[n];return e.isValidElementType(i)?null:new p("Invalid "+o+" `"+a+"` of type `"+b(i)+"` supplied to `"+r+"`, expected a single ReactElement type.")})),instanceOf:function(e){return v((function(t,n,r,o,a){if(!(t[n]instanceof e)){var i=e.name||d;return new p("Invalid "+o+" `"+a+"` of type `"+((l=t[n]).constructor&&l.constructor.name?l.constructor.name:d)+"` supplied to `"+r+"`, expected instance of `"+i+"`.")}var l;return null}))},node:v((function(e,t,n,r,o){return g(e[t])?null:new p("Invalid "+r+" `"+o+"` supplied to `"+n+"`, expected a ReactNode.")})),objectOf:function(e){return v((function(t,o,a,i,l){if("function"!=typeof e)return new p("Property `"+l+"` of component `"+a+"` has invalid PropType notation inside objectOf.");var c=t[o],u=b(c);if("object"!==u)return new p("Invalid "+i+" `"+l+"` of type `"+u+"` supplied to `"+a+"`, expected an object.");for(var s in c)if(r(c,s)){var d=e(c,s,a,i,l+"."+s,n);if(d instanceof Error)return d}return null}))},oneOf:function(e){return Array.isArray(e)?v((function(t,n,r,o,a){for(var i=t[n],l=0;l<e.length;l++)if(f(i,e[l]))return null;var c=JSON.stringify(e,(function(e,t){return"symbol"===E(t)?String(t):t}));return new p("Invalid "+o+" `"+a+"` of value `"+String(i)+"` supplied to `"+r+"`, expected one of "+c+".")})):("production"!==process.env.NODE_ENV&&a(arguments.length>1?"Invalid arguments supplied to oneOf, expected an array, got "+arguments.length+" arguments. A common mistake is to write oneOf(x, y, z) instead of oneOf([x, y, z]).":"Invalid argument supplied to oneOf, expected an array."),i)},oneOfType:function(e){if(!Array.isArray(e))return"production"!==process.env.NODE_ENV&&a("Invalid argument supplied to oneOfType, expected an instance of array."),i;for(var t=0;t<e.length;t++){var o=e[t];if("function"!=typeof o)return a("Invalid argument supplied to oneOfType. Expected an array of check functions, but received "+x(o)+" at index "+t+"."),i}return v((function(t,o,a,i,l){for(var c=[],u=0;u<e.length;u++){var s=(0,e[u])(t,o,a,i,l,n);if(null==s)return null;s.data&&r(s.data,"expectedType")&&c.push(s.data.expectedType)}return new p("Invalid "+i+" `"+l+"` supplied to `"+a+"`"+(c.length>0?", expected one of type ["+c.join(", ")+"]":"")+".")}))},shape:function(e){return v((function(t,r,o,a,i){var l=t[r],c=b(l);if("object"!==c)return new p("Invalid "+a+" `"+i+"` of type `"+c+"` supplied to `"+o+"`, expected `object`.");for(var u in e){var s=e[u];if("function"!=typeof s)return h(o,a,i,u,E(s));var d=s(l,u,o,a,i+"."+u,n);if(d)return d}return null}))},exact:function(e){return v((function(o,a,i,l,c){var u=o[a],s=b(u);if("object"!==s)return new p("Invalid "+l+" `"+c+"` of type `"+s+"` supplied to `"+i+"`, expected `object`.");var d=t({},o[a],e);for(var m in d){var f=e[m];if(r(e,m)&&"function"!=typeof f)return h(i,l,c,m,E(f));if(!f)return new p("Invalid "+l+" `"+c+"` key `"+m+"` supplied to `"+i+"`.\nBad object: "+JSON.stringify(o[a],null," ")+"\nValid keys: "+JSON.stringify(Object.keys(e),null," "));var v=f(u,m,i,l,c+"."+m,n);if(v)return v}return null}))}};function f(e,t){return e===t?0!==e||1/e==1/t:e!=e&&t!=t}function p(e,t){this.message=e,this.data=t&&"object"==typeof t?t:{},this.stack=""}function v(e){if("production"!==process.env.NODE_ENV)var t={},r=0;function o(o,i,l,u,s,m,f){if(u=u||d,m=m||l,f!==n){if(c){var v=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use `PropTypes.checkPropTypes()` to call them. Read more at http://fb.me/use-check-prop-types");throw v.name="Invariant Violation",v}if("production"!==process.env.NODE_ENV&&"undefined"!=typeof console){var y=u+":"+l;!t[y]&&r<3&&(a("You are manually calling a React.PropTypes validation function for the `"+m+"` prop on `"+u+"`. This is deprecated and will throw in the standalone `prop-types` package. You may be seeing this warning due to a third-party PropTypes library. See https://fb.me/react-warning-dont-call-proptypes for details."),t[y]=!0,r++)}}return null==i[l]?o?null===i[l]?new p("The "+s+" `"+m+"` is marked as required in `"+u+"`, but its value is `null`."):new p("The "+s+" `"+m+"` is marked as required in `"+u+"`, but its value is `undefined`."):null:e(i,l,u,s,m)}var i=o.bind(null,!1);return i.isRequired=o.bind(null,!0),i}function y(e){return v((function(t,n,r,o,a,i){var l=t[n];return b(l)!==e?new p("Invalid "+o+" `"+a+"` of type `"+E(l)+"` supplied to `"+r+"`, expected `"+e+"`.",{expectedType:e}):null}))}function h(e,t,n,r,o){return new p((e||"React class")+": "+t+" type `"+n+"."+r+"` is invalid; it must be a function, usually from the `prop-types` package, but received `"+o+"`.")}function g(e){switch(typeof e){case"number":case"string":case"undefined":return!0;case"boolean":return!e;case"object":if(Array.isArray(e))return e.every(g);if(null===e||l(e))return!0;var t=function(e){var t=e&&(u&&e[u]||e[s]);if("function"==typeof t)return t}(e);if(!t)return!1;var n,r=t.call(e);if(t!==e.entries){for(;!(n=r.next()).done;)if(!g(n.value))return!1}else for(;!(n=r.next()).done;){var o=n.value;if(o&&!g(o[1]))return!1}return!0;default:return!1}}function b(e){var t=typeof e;return Array.isArray(e)?"array":e instanceof RegExp?"object":function(e,t){return"symbol"===e||!!t&&("Symbol"===t["@@toStringTag"]||"function"==typeof Symbol&&t instanceof Symbol)}(t,e)?"symbol":t}function E(e){if(null==e)return""+e;var t=b(e);if("object"===t){if(e instanceof Date)return"date";if(e instanceof RegExp)return"regexp"}return t}function x(e){var t=E(e);switch(t){case"array":case"object":return"an "+t;case"boolean":case"date":case"regexp":return"a "+t;default:return t}}return p.prototype=Error.prototype,m.checkPropTypes=o,m.resetWarningCache=o.resetWarningCache,m.PropTypes=m,m},nr}()(dr.isElement,!0)}else Bn.exports=function(){if(ar)return or;ar=1;var e=ur();function t(){}function n(){}return n.resetWarningCache=t,or=function(){function r(t,n,r,o,a,i){if(i!==e){var l=new Error("Calling PropTypes validators directly is not supported by the `prop-types` package. Use PropTypes.checkPropTypes() to call them. Read more at http://fb.me/use-check-prop-types");throw l.name="Invariant Violation",l}}function o(){return r}r.isRequired=r;var a={array:r,bigint:r,bool:r,func:r,number:r,object:r,string:r,symbol:r,any:r,arrayOf:o,element:r,elementType:r,instanceOf:o,node:r,objectOf:o,oneOf:o,oneOfType:o,shape:o,exact:o,checkPropTypes:n,resetWarningCache:t};return a.PropTypes=a,a}}()();function mr(e,t,n,r,o){const a=e[t],i=o||t;if(null==a||"undefined"==typeof window)return null;let l;const c=a.type;return"function"!=typeof c||function(e){const{prototype:t={}}=e;return Boolean(t.isReactComponent)}(c)||(l="Did you accidentally use a plain function component for an element instead?"),void 0!==l?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}_n(Bn.exports.element,mr).isRequired=_n(Bn.exports.element.isRequired,mr),_n(Bn.exports.elementType,(function(e,t,n,r,o){const a=e[t],i=o||t;if(null==a||"undefined"==typeof window)return null;let l;return"function"!=typeof a||function(e){const{prototype:t={}}=e;return Boolean(t.isReactComponent)}(a)||(l="Did you accidentally provide a plain function component instead?"),void 0!==l?new Error(`Invalid ${r} \`${i}\` supplied to \`${n}\`. Expected an element type that can hold a ref. ${l} For more information see https://mui.com/r/caveat-with-refs-guide`):null}));var fr,pr={};var vr,yr,hr={};
15
15
  /**
16
16
  * @license React
17
17
  * react-is.development.js
@@ -20,5 +20,5 @@ object-assign
20
20
  *
21
21
  * This source code is licensed under the MIT license found in the
22
22
  * LICENSE file in the root directory of this source tree.
23
- */fr={exports:{}},"production"===process.env.NODE_ENV?fr.exports=function(){if(sr)return dr;sr=1;var e,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),l=Symbol.for("react.context"),c=Symbol.for("react.server_context"),u=Symbol.for("react.forward_ref"),s=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),m=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen");function v(e){if("object"==typeof e&&null!==e){var p=e.$$typeof;switch(p){case t:switch(e=e.type){case r:case a:case o:case s:case d:return e;default:switch(e=e&&e.$$typeof){case c:case l:case u:case f:case m:case i:return e;default:return p}}case n:return p}}}return e=Symbol.for("react.module.reference"),dr.ContextConsumer=l,dr.ContextProvider=i,dr.Element=t,dr.ForwardRef=u,dr.Fragment=r,dr.Lazy=f,dr.Memo=m,dr.Portal=n,dr.Profiler=a,dr.StrictMode=o,dr.Suspense=s,dr.SuspenseList=d,dr.isAsyncMode=function(){return!1},dr.isConcurrentMode=function(){return!1},dr.isContextConsumer=function(e){return v(e)===l},dr.isContextProvider=function(e){return v(e)===i},dr.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},dr.isForwardRef=function(e){return v(e)===u},dr.isFragment=function(e){return v(e)===r},dr.isLazy=function(e){return v(e)===f},dr.isMemo=function(e){return v(e)===m},dr.isPortal=function(e){return v(e)===n},dr.isProfiler=function(e){return v(e)===a},dr.isStrictMode=function(e){return v(e)===o},dr.isSuspense=function(e){return v(e)===s},dr.isSuspenseList=function(e){return v(e)===d},dr.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===r||t===a||t===o||t===s||t===d||t===p||"object"==typeof t&&null!==t&&(t.$$typeof===f||t.$$typeof===m||t.$$typeof===i||t.$$typeof===l||t.$$typeof===u||t.$$typeof===e||void 0!==t.getModuleId)},dr.typeOf=v,dr}():fr.exports=(mr||(mr=1,"production"!==process.env.NODE_ENV&&function(){var e,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),l=Symbol.for("react.context"),c=Symbol.for("react.server_context"),u=Symbol.for("react.forward_ref"),s=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),m=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen");function v(e){if("object"==typeof e&&null!==e){var p=e.$$typeof;switch(p){case t:var v=e.type;switch(v){case r:case a:case o:case s:case d:return v;default:var y=v&&v.$$typeof;switch(y){case c:case l:case u:case f:case m:case i:return y;default:return p}}case n:return p}}}e=Symbol.for("react.module.reference");var y=l,h=i,g=t,b=u,E=r,x=f,C=m,S=n,w=a,k=o,T=s,I=d,O=!1,P=!1;pr.ContextConsumer=y,pr.ContextProvider=h,pr.Element=g,pr.ForwardRef=b,pr.Fragment=E,pr.Lazy=x,pr.Memo=C,pr.Portal=S,pr.Profiler=w,pr.StrictMode=k,pr.Suspense=T,pr.SuspenseList=I,pr.isAsyncMode=function(e){return O||(O=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1},pr.isConcurrentMode=function(e){return P||(P=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1},pr.isContextConsumer=function(e){return v(e)===l},pr.isContextProvider=function(e){return v(e)===i},pr.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},pr.isForwardRef=function(e){return v(e)===u},pr.isFragment=function(e){return v(e)===r},pr.isLazy=function(e){return v(e)===f},pr.isMemo=function(e){return v(e)===m},pr.isPortal=function(e){return v(e)===n},pr.isProfiler=function(e){return v(e)===a},pr.isStrictMode=function(e){return v(e)===o},pr.isSuspense=function(e){return v(e)===s},pr.isSuspenseList=function(e){return v(e)===d},pr.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===r||t===a||t===o||t===s||t===d||t===p||"object"==typeof t&&null!==t&&(t.$$typeof===f||t.$$typeof===m||t.$$typeof===i||t.$$typeof===l||t.$$typeof===u||t.$$typeof===e||void 0!==t.getModuleId)},pr.typeOf=v}()),pr),"undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")(),Fn.exports.oneOfType([Fn.exports.func,Fn.exports.object]);let vr=0;const yr=ve["useId".toString()];function hr(e){if(void 0!==yr){const t=yr();return null!=e?e:t}return function(e){const[t,n]=ve.useState(e),r=e||t;return ve.useEffect((()=>{null==t&&(vr+=1,n(`mui-${vr}`))}),[t]),r}(e)}const gr={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:-1,overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"};const br=Number.isInteger||function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e};function Er(e,t,n,r){const o=e[t];if(null==o||!br(o)){const e=function(e){const t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":Number.isFinite(e)?e!==Math.floor(e)?"float":"number":"Infinity";case"object":return null===e?"null":e.constructor.name;default:return t}}(o);return new RangeError(`Invalid ${r} \`${t}\` of type \`${e}\` supplied to \`${n}\`, expected \`integer\`.`)}return null}function xr(e,t,...n){return void 0===e[t]?null:Er(e,t,...n)}function Cr(){return null}xr.isRequired=Er,Cr.isRequired=Cr,process.env.NODE_ENV;var Sr=function(t){var n,r=t.id,o=t.label,a=t.InputLabelProps,i=t.InputProps,l=t.fetching,c=t.loading,u=t.helperText,s=t.hexColor,d=t.size,m=t.fullWidth,f=t.sx,p=bt(t,["id","label","InputLabelProps","InputProps","fetching","loading","helperText","hexColor","size","fullWidth","sx"]),v=hr(r),y=u&&v?"".concat(v,"-helper-text"):void 0,h=o&&v?"".concat(v,"-label"):void 0,g=s?((n={})["& .".concat(B.notchedOutline)]={borderColor:"".concat(s," !important")},n["& .".concat(q.root)]={color:s},n["& .".concat(B.input)]={color:s},n["& .".concat(H.root)]={color:s},n["& .".concat(U.bar)]={backgroundColor:s},n["& .".concat(Y.endAdornment," .").concat(J.root)]={color:s},n):{};return ye.createElement(V,{sx:g,fullWidth:m},ye.createElement(F,gt({size:"small"===d?"small":"normal",id:h,htmlFor:v},a),o),ye.createElement(X,gt({},i,{id:v,label:o,size:d,fullWidth:m,endAdornment:ye.createElement(e,{position:"end"},null==i?void 0:i.endAdornment,c?ye.createElement(x,{color:"inherit",size:20,sx:{ml:1}}):null),sx:f},p)),l&&!c&&ye.createElement(C,{color:"inherit",sx:{position:"absolute",left:0,right:0,bottom:0}}),u&&ye.createElement(G,{id:y},u))},wr=function(e){var t=e.label,n=e.loading,r=e.fetching,o=e.options,a=e.helperText,i=e.color,l=e.onChangeValue,c=void 0===l?function(){return null}:l,u=e.sx,s=bt(e,["label","loading","fetching","options","helperText","color","onChangeValue","sx"]),d=n||r;return ye.createElement(K,gt({loading:d,options:r?[]:o,onChange:function(e,t){return c(t)}},s,{renderInput:function(e){return ye.createElement(Sr,gt({},e,{label:t,fullWidth:!0,fetching:r,loading:n,hexColor:i,helperText:a}))},sx:u}))},kr=T(o,{shouldForwardProp:function(e){return"dayIsBetween"!==e&&"isFirstDay"!==e&&"isLastDay"!==e&&"isStartOfWeek"!==e&&"isEndOfWeek"!==e}})((function(e){var t=e.theme,n=e.dayIsBetween,r=e.isFirstDay,o=e.isLastDay;return gt(gt(gt({},(r||o||n)&&{borderRadius:0,backgroundColor:"".concat(t.palette.primary.light,"40"),margin:0}),r&&{borderTopLeftRadius:"50%",borderBottomLeftRadius:"50%"}),o&&{borderTopRightRadius:"50%",borderBottomRightRadius:"50%"})})),Tr=function(e){var t=e.day,n=e.dateRange,r=bt(e,["day","dateRange"]);if(null==n)return ye.createElement(De,gt({day:t},r));var o=n[0],a=n[1],i=!!a&&$e(t,o)&&nt(t,a),l=ze(t,o),c=!!a&&ze(t,a),u=ze(t,Re(t)),s=ze(t,je(t));return ye.createElement(kr,{dayIsBetween:i,isFirstDay:l||i&&u,isLastDay:c||i&&s,"aria-label":Pe(t,"yyyy-MM-dd"),"aria-selected":i||l||c,role:"gridcell"},ye.createElement(De,gt({},r,{day:t,selected:l||c})))},Ir=function(e){var t=e.defaultValue,n=e.onValueChange,r=he(t),o=r[0],a=r[1],i=he(0),l=i[0],c=i[1],u=function(e,t,r){a(e),n(e,t),c(r)};return ye.createElement(Me,{value:null,onChange:function(e){if(e)return 1===l&&e<o[0]||0===l&&o[1]&&e>o[1]?u([e,void 0],0,1):void u([0===l?e:o[0],1===l?e:o[1]],l,0===l?1:0)},slots:{day:Tr},slotProps:{day:{dateRange:o}},"aria-label":"calendar range picker"})},Or=function(t){var n=t.defaultValue,o=t.format,a=t.label,i=t.fullWidth,u=t.onValueChange,s=t.size,d=void 0===s?"medium":s,m=he(!1),f=m[0],p=m[1],v=he(n),y=v[0],h=v[1];return ye.createElement(ye.Fragment,null,ye.createElement(l,{label:a,fullWidth:i,size:d,value:"".concat(Pe(y[0],o)," - ").concat(y[1]?Pe(y[1],o):o.toUpperCase()),InputProps:{endAdornment:ye.createElement(e,{position:"end"},ye.createElement(r,{onClick:function(){return p((function(e){return!e}))},"aria-label":"open calendar"},ye.createElement(tt,null)))}}),ye.createElement(c,null,ye.createElement(j,{in:f,"aria-label":"calendar collapse"},ye.createElement(Ir,{defaultValue:n,onValueChange:function(e,t){h(e),u(e,t),p(t<1)}}))))},Pr=xe([0,function(){return null}]),$r=Pr.Provider,zr=T((function(e){return ye.createElement(b,gt({},e,{TabIndicatorProps:{children:ye.createElement("span",{className:"MuiTabs-indicatorSpan"})}}))}))((function(e){var t=e.theme;return{minHeight:t.spacing(5),"& .MuiTabs-indicator":{display:"flex",justifyContent:"center",backgroundColor:"transparent"},"& .MuiTabs-indicatorSpan":{maxWidth:40,width:"100%",backgroundColor:t.palette.primary.main}}})),Rr=T(E)((function(e){var t=e.theme;return{textTransform:"none",fontWeight:t.typography.fontWeightRegular,marginRight:t.spacing(1),color:t.palette.text.secondary,paddingTop:0,paddingBottom:0,minHeight:t.spacing(5),"&.Mui-selected":{color:t.palette.text.secondary,fontWeight:t.typography.fontWeightBold}}})),jr=function(e){var t=e.children,n=e.tabs,r=e.initialTab,a=void 0===r?0:r,i=e.onChangeTab,l=void 0===i?function(){return null}:i,u=Ct(),s=he(a),d=s[0],m=s[1];return ye.createElement($r,{value:[d,m]},ye.createElement(c,{variant:"outlined"},ye.createElement(o,{bgcolor:u},ye.createElement(zr,{value:d,onChange:function(e,t){m(t),l(n[t],t)}},n.map((function(e){var t=e.text,n=e.icon;return ye.createElement(Rr,{iconPosition:"start",disableRipple:!0,key:t,label:t,icon:n})})))),t))},Ar=function(e){var t=e.index,n=e.children,r=e.sx,a=Ce(Pr)[0],i=a===t;return Array.isArray(t)&&(i=t.includes(a)),i?ye.createElement(o,{sx:r},n):null};function Wr(e){var t=e.children,n=e.index,r=qt()[0],a=r===n;return Array.isArray(n)&&(a=n.includes(r)),ye.createElement("div",{role:"tabpanel",hidden:!a,id:"simple-tabpanel-".concat(n),"aria-labelledby":"simple-tab-".concat(n)},a&&ye.createElement(o,{sx:{p:3}},t))}var Nr=function(e){var t=e.order,n=e.orderBy,r=e.headCells,a=e.onRequestSort;return ye.createElement(Q,null,ye.createElement(Z,null,r.map((function(e){return ye.createElement(ee,{variant:"head",key:String(e.id),padding:e.disablePadding?"none":"normal",sortDirection:n===e.id&&t,sx:{fontWeight:"bold"}},e.sort?ye.createElement(te,{active:n===e.id,direction:n===e.id?t:"asc",onClick:(r=e.id,function(){a(r)})},e.label,n===e.id?ye.createElement(o,{component:"span",sx:gr},"desc"===t?"sorted descending":"sorted ascending"):null):e.label);var r}))))};function Mr(e,t,n){return t[n]<e[n]?-1:t[n]>e[n]?1:0}var Dr=function(t){var n=t.children,r=t.data,a=t.search,i=t.columns,c=t.defaultSort,u=t.defaultOrder,s=void 0===u?"asc":u,d=t.loading,m=void 0!==d&&d,f=he(""),p=f[0],v=f[1],y=he(s),h=y[0],g=y[1],b=he(c),E=b[0],C=b[1],S=r.slice().filter(function(e,t){return function(n){return!t||e.some((function(e){var r=n[e.id];return(null==r?void 0:r.toLowerCase)&&(r=r.toLowerCase()),null==r?void 0:r.toString().includes(t.toLowerCase())}))}}(i,p)).sort(function(e,t){return"desc"===e?function(e,n){return Mr(e,n,t)}:function(e,n){return-Mr(e,n,t)}}(h,E));return ye.createElement(ye.Fragment,null,ye.createElement(o,{sx:{paddingX:1,paddingBottom:2}},a&&ye.createElement(o,{paddingY:2},ye.createElement(l,{fullWidth:!0,placeholder:"Search",InputProps:{role:"search",startAdornment:ye.createElement(e,{position:"start"},ye.createElement(rt,null))},onChange:function(e){return v(e.target.value)}})),ye.createElement(ne,null,ye.createElement(re,null,ye.createElement(Nr,{order:h,orderBy:E,headCells:i,onRequestSort:function(e){g(E===e&&"asc"===h?"desc":"asc"),C(e)}}),ye.createElement(oe,null,m?ye.createElement(Z,null,ye.createElement(ee,{colSpan:i.length,sx:{textAlign:"center"}},ye.createElement(x,null))):0===S.length?ye.createElement(Z,null,ye.createElement(ee,{colSpan:i.length,sx:{textAlign:"center"}},"No data")):n(S))))))};Dr.defaultProps={defaultOrder:"asc"};var Vr,Fr=function(e){var t=e.children,n=e.data,r=e.loading,o=e.columns,a=e.defaultSort,i=e.defaultOrder,l=e.onRequestSort,c=he({orderBy:a,order:i||"asc"}),u=c[0],s=c[1];return ye.createElement(ye.Fragment,null,ye.createElement(ne,null,ye.createElement(re,null,ye.createElement(Nr,{order:u.order,orderBy:u.orderBy,headCells:o,onRequestSort:function(e){s((function(t){var n=t.orderBy,r=t.order,o=n===e&&"asc"===r?"desc":"asc";return l(e,o),{orderBy:e,order:o}}))}}),ye.createElement(oe,null,r?ye.createElement(Z,null,ye.createElement(ee,{colSpan:o.length,sx:{textAlign:"center"}},ye.createElement(x,null))):n.map((function(e,n){return t(e,n)}))))))},_r=function(e){var n=e.title,r=e.subtitle,i=e.icon,l=e.iconSize,c=void 0===l?200:l,u=e.actions;return ye.createElement(o,{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",textAlign:"center"},i&&i({size:c,color:"primary"}),ye.createElement(a,{variant:"h4",role:"heading","aria-level":1},n),ye.createElement(a,{variant:"subtitle1",role:"heading","aria-level":2,sx:{mt:2}},r),u&&ye.createElement(o,{sx:{pt:2}},u.map((function(e,n){var r=e.id,o=e.text,a=e.href,i=e.onClick;return ye.createElement(t,{key:r,role:"button",variant:"contained",href:a,onClick:i,sx:{mr:n<u.length-1?2:0}},o)}))))},Lr=function(e){var t=e.width,n=void 0===t?"100%":t,r=e.animation,a=void 0!==r&&r;return ye.createElement(o,{width:n},ye.createElement(ae,{animation:a,variant:"rectangular",height:118}),ye.createElement(ae,{animation:a,variant:"rectangular",height:16,sx:{my:1}}),ye.createElement(ae,{animation:a,variant:"rectangular",width:"80%",height:16}))},Br=function(e){var t=e.size,n=void 0===t?20:t;return ye.createElement(s,{container:!0,spacing:2},kt(n,0).map((function(e,t){return ye.createElement(s,{item:!0,key:t,xs:4},ye.createElement(Lr,{width:1}))})))},qr=function(e){var t=e.size,n=void 0===t?20:t,r=e.children,o=e.p;return ye.createElement(h,{component:"main",sx:{p:o},"data-testid":"content-placeholder-test"},r,ye.createElement(Br,{size:n}))},Hr=function(e){var t=e.count,n=void 0===t?3:t,r=e.units,o=void 0===r?"paragraph":r,i=e.variant,l=void 0===i?"body1":i;return ye.createElement(a,{variant:l},ot({count:n,units:o}))},Ur=((Vr={})["& .".concat(ie.message)]={width:1},Vr),Yr=Ee((function(e,t){var n=e.severity,a=e.iconMapping,i=e.title,l=e.message,c=e.metadata,u=e.metadataComponent,s=e.onClose,d=e.sx,m=void 0===d?{}:d,f=he(!1),p=f[0],h=f[1];return ye.createElement(v,{ref:t,severity:n,iconMapping:a,onClose:s,action:ye.createElement(o,{display:"flex",flexDirection:"column"},ye.createElement(r,{color:"inherit",onClick:s},ye.createElement(Oe,{fontSize:"small"})),c&&ye.createElement(r,{color:"inherit",onClick:function(){return h((function(e){return!e}))}},p?ye.createElement(at,{fontSize:"small"}):ye.createElement(Ke,{fontSize:"small"}))),sx:gt(gt({},Ur),m)},ye.createElement(o,{sx:{w:1}},i&&ye.createElement(y,null,i),l,c&&ye.createElement(j,{in:p,sx:{mt:2}},ye.createElement(Xt,{content:c},u))))})),Jr=function(e){var n=e.open,a=e.title,i=e.component,l=e.componentProps,c=void 0===l?{}:l,u=e.disabled,s=e.disableAccept,d=e.disableCancel,m=e.actions,f=void 0===m?[]:m,p=e.children,v=e.loading,y=e.cancelable,h=e.callCloseWhenCancel,g=void 0===h||h,b=e.acceptable,E=e.acceptText,C=void 0===E?"Accept":E,S=e.cancelText,w=void 0===S?"Cancel":S,k=e.onAccept,T=e.onCancel,I=void 0===T?function(){return null}:T,O=e.onClose,P=e.acceptType,$=void 0===P?"button":P,z=f.length>0||b||y;return ye.createElement(le,{open:n,onClose:O},ye.createElement(ce,{sx:{display:"flex",alignItems:"center"}},a,v&&!b&&ye.createElement(x,{size:20,sx:{ml:2,color:function(e){return e.palette.grey[500]}}}),ye.createElement(r,{disabled:u,"aria-label":"close",onClick:O,sx:{position:"absolute",right:8,top:8,color:function(e){return e.palette.grey[500]}}},ye.createElement(Oe,null))),ye.createElement(o,gt({component:i},c),ye.createElement(ue,{dividers:!0},p),z&&ye.createElement(se,null,f.map((function(e){var n=e.id,r=e.text,o=e.type,a=void 0===o?"button":o,i=e.onClick,l=e.color,c=void 0===l?"primary":l;return ye.createElement(t,{key:n,type:a,disabled:u,onClick:i,color:c},r)})),y&&ye.createElement(t,{color:"error",disabled:u||d,onClick:function(){I(),g&&O()}},w),b&&ye.createElement(et,{type:$,loading:v,disabled:u||s,onClick:k},C))))},Xr=function(e){var t=e.open,n=e.title,r=e.loading,o=e.disabled,a=e.confirmText,i=void 0===a?"Confirm":a,c=e.cancelText,u=void 0===c?"Cancel":c,s=e.passphrase,d=e.children,m=e.onConfirm,f=e.onCancel,p=he(""),v=p[0],y=p[1],h=!s||v===s;return ye.createElement(Jr,{title:n,loading:r,disabled:r||o,disableAccept:!h,open:t,onClose:f,acceptable:!0,cancelable:!0,callCloseWhenCancel:!1,acceptText:i,cancelText:u,onCancel:f,onAccept:m},d,s&&ye.createElement(l,{size:"small",fullWidth:!0,value:v,onChange:function(e){return y(e.target.value)},placeholder:s}))},Gr=function(e){var t=e.open,n=e.title,r=e.loading,o=e.disabled,a=e.submitText,i=void 0===a?"Submit":a,l=e.cancelText,c=void 0===l?"Cancel":l,u=e.children,s=e.onSubmit,d=e.onCancel;return ye.createElement(Jr,{component:"form",componentProps:{onSubmit:function(e){e.preventDefault(),s(Ot(e))}},title:n,loading:r,disabled:r||o,open:t,onClose:d,callCloseWhenCancel:!1,cancelable:!0,acceptable:!0,cancelText:c,onCancel:d,acceptText:i,acceptType:"submit"},u)},Kr=function(e){void 0===e&&(e=!1);var t=he(e),n=t[0],r=t[1];return{isOpen:n,open:function(){return r(!0)},close:function(){return r(!1)},setIsOpen:r}},Qr=function(e){var t=e.drawerProviderProps,n=e.children,r=n[0],o=n[1],a=n[2];return ye.createElement(bn,gt({},t),r,o,ye.createElement(An,null,a))},Zr=function(){return ye.createElement(it,{color:"error",sx:{width:200,height:200}})},eo=function(e){var t=e.loading,n=e.children,r=e.fetching,a=e.error,i=n[0],l=n[1];return ye.createElement(Ht,null,ye.createElement(o,{display:"flex",flexDirection:"column",height:1},i,r&&ye.createElement(o,{width:1},ye.createElement(C,null)),t&&ye.createElement(Kt,null),a&&ye.createElement(o,{mt:4},ye.createElement(_r,{icon:a.icon||Zr,title:a.title||"There has been an error",subtitle:a.message})),!t&&!a&&l))},to=function(e,t,n){var r=(void 0===n?{}:n).dense,o=e.id,a=e.name,i=e.type,l=t[o];return"boolean"===i?ye.createElement(ht,{dense:r,label:a,value:l}):"date"===i||"time"===i||"datetime"===i?ye.createElement(xt,{dense:r,label:a,value:l,format:e.format}):"object"!=typeof l||Array.isArray(l)?ye.createElement(vt,{dense:r,label:a,value:null==l?void 0:l.toString()}):ye.createElement(vt,{dense:r,label:a,value:JSON.stringify(l)})},no=function(e){var t=e.field,n=t.name,r=t.description,o=t.value,a=e.instance,i=e.dense,l=[{field:"id",headerName:"ID",width:70}];o.forEach((function(e){l.push({field:e.id,headerName:e.name})}));var c=a.map((function(e,t){return gt({id:t},e)}));return ye.createElement(St,{title:n,subtitle:r,dense:i},ye.createElement(s,{item:!0,xs:12},ye.createElement(lt,{rows:c,columns:l,density:i?"compact":"standard",disableRowSelectionOnClick:!0,pageSizeOptions:[5],initialState:{pagination:{paginationModel:{pageSize:5}}},sx:{height:400}})))},ro=function(e){var t=e.field,n=t.name,r=t.description,o=t.value,a=e.instance,i=e.dense,l=It();return ye.createElement(St,{title:n,subtitle:r,dense:i},o.map((function(e){var t=e.id,n=e.xs,r=e.sm,o=e.md,c=e.lg,u=e.xl,s=l.increment(e);return ye.createElement($t,{key:t,xs:n,sm:r,md:o,lg:c,xl:u,bordered:s},to(e,a,{dense:i}))})))},oo=function(e){var t=e.model,n=e.instance,r=e.dense,o=It();return ye.createElement(s,{container:!0,spacing:r?1:2},t.fields.map((function(e){var t=e.id,a=e.type,i=e.xs,l=void 0===i?3:i,c=e.sm,u=void 0===c?0:c,d=e.md,m=void 0===d?0:d,f=e.lg,p=void 0===f?0:f,v=e.xl,y=void 0===v?0:v;if("group"===a)return o.increment({xs:12}),ye.createElement(s,{item:!0,key:t,xs:12},ye.createElement(ro,{field:e,instance:n[t],dense:r}));if("group[]"===a)return o.increment({xs:12}),ye.createElement(s,{item:!0,key:t,xs:12},ye.createElement(no,{field:e,instance:n[t],dense:r}));var h=o.increment(e);return ye.createElement($t,{key:t,xs:l,sm:u,md:m,lg:p,xl:y,bordered:h},to(e,n,{dense:r}))})))},ao={string:"",number:0,boolean:!1,enum:"",multienum:[],date:new Date(1970,0,1,0,0),time:new Date(1970,0,1,0,0),datetime:new Date(1970,0,1,0,0),group:{},"group[]":[],"string[]":[],"number[]":[]},io=function(e,t){return t&&t[e.id]||"default"in e&&e.default||ao[e.type]},lo=function(e,t){void 0===t&&(t=void 0);var n={};return e.fields.forEach((function(e){if("group"===e.type){var r={};e.value.forEach((function(n){r[n.id]=io(n,t&&t[e.id])})),n[e.id]=r}else n[e.id]=io(e,t)})),n},co=function(e){var t=e.field,n=e.path,r=void 0===n?[]:n,a=e.value,i=e.dense,c=e.update,u=e.onChangeValue,d=function(e,t){e.preventDefault();var n=e.target.value;"number"===t&&"string"==typeof n?n=parseInt(e.target.value,10):t.includes("[]")&&(n=e.target.value.split(",")),u(Et(Et([],r,!0),[e.target.name],!1),n)},m=function(e,t){u(Et(Et([],r,!0),[t],!1),e)};Ct({lightWeight:200,darkWeight:800});var f,p=t.id,v=t.type,y=t.name,h=t.description,g=t.updatable,b=void 0===g||g,E=t.required,x=void 0===E||E,C=t.xs,S=t.sm,w=t.md,T=t.lg,I=t.xl,O=!b&&c,P=i?"small":"medium";if("group"===v)f=ye.createElement(St,{title:y,subtitle:h,dense:i},ye.createElement(s,{container:!0,spacing:2,sx:{p:2}},t.value.map((function(e){return ye.createElement(co,{key:e.id,field:e,dense:i,path:Et(Et([],r,!0),[p],!1),value:a[e.id],update:c,onChangeValue:u})}))));else if("boolean"===v)f=ye.createElement(o,{sx:{height:1,display:"flex",alignItems:"center"}},ye.createElement(de,{control:ye.createElement(me,{name:p,size:P,onChange:function(e){e.preventDefault(),u(Et(Et([],r,!0),[e.target.name],!1),e.target.checked)},checked:a,disabled:O}),label:y}));else if("enum"===v)f=ye.createElement(V,{fullWidth:!0},ye.createElement(F,{id:"".concat(p,"-select-label")},y),ye.createElement(_,{labelId:"".concat(p,"-select-label"),id:"".concat(p,"-select"),value:a,label:y,name:p,size:P,onChange:function(e){e.preventDefault(),u(Et(Et([],r,!0),[e.target.name],!1),e.target.value)},required:x,disabled:O},t.value.map((function(e){return ye.createElement(fe,{key:e,value:e},e)}))));else if("multienum"===v)f=ye.createElement(V,{fullWidth:!0},ye.createElement(F,{id:"".concat(p,"-select-label")},y),ye.createElement(_,{labelId:"".concat(p,"-select-label"),id:"".concat(p,"-select"),value:a||[],renderValue:function(e){return e.join(", ")},label:y,name:p,size:P,onChange:function(e){e.preventDefault();var t=e.target.value,n="string"==typeof t?t.split(","):t;u(Et(Et([],r,!0),[e.target.name],!1),n)},required:x,disabled:O,multiple:!0},t.value.map((function(e){return ye.createElement(fe,{key:e,value:e},ye.createElement(me,{checked:(a||[]).includes(e)}),ye.createElement(k,{primary:e}))}))));else if("date"===v)f=ye.createElement(Ve,{label:y,format:t.format,value:a,slotProps:{field:{size:P}},disabled:O,onChange:function(e){return m(e,p)}});else if("time"===v)f=ye.createElement(We,{label:y,format:t.format,value:a,slotProps:{field:{size:P}},disabled:O,onChange:function(e){return m(e,p)}});else if("datetime"===v)f=ye.createElement(Ae,{label:y,format:t.format,value:a,slotProps:{field:{size:P}},disabled:O,onChange:function(e){return m(e,p)}});else{if("group[]"===v)return null;f=v.includes("[]")?ye.createElement(l,{required:x,type:"text",label:y,name:p,size:P,variant:"outlined",helperText:"Use comas to separate multiple values",fullWidth:!0,disabled:O,value:a.join(","),onChange:function(e){return d(e,v)}}):ye.createElement(l,{required:x,type:v,label:y,size:P,name:p,variant:"outlined",fullWidth:!0,value:a,disabled:O,onChange:function(e){return d(e,v)}})}return ye.createElement(s,{item:!0,key:p,xs:C,sm:S,md:w,lg:T,xl:I},f)};function uo(e){return null!=e&&"object"==typeof e&&!0===e["@@functional/placeholder"]}function so(e){return function t(n){return 0===arguments.length||uo(n)?t:e.apply(this,arguments)}}function mo(e){return function t(n,r){switch(arguments.length){case 0:return t;case 1:return uo(n)?t:so((function(t){return e(n,t)}));default:return uo(n)&&uo(r)?t:uo(n)?so((function(t){return e(t,r)})):uo(r)?so((function(t){return e(n,t)})):e(n,r)}}}function fo(e){return function t(n,r,o){switch(arguments.length){case 0:return t;case 1:return uo(n)?t:mo((function(t,r){return e(n,t,r)}));case 2:return uo(n)&&uo(r)?t:uo(n)?mo((function(t,n){return e(t,r,n)})):uo(r)?mo((function(t,r){return e(n,t,r)})):so((function(t){return e(n,r,t)}));default:return uo(n)&&uo(r)&&uo(o)?t:uo(n)&&uo(r)?mo((function(t,n){return e(t,n,o)})):uo(n)&&uo(o)?mo((function(t,n){return e(t,r,n)})):uo(r)&&uo(o)?mo((function(t,r){return e(n,t,r)})):uo(n)?so((function(t){return e(t,r,o)})):uo(r)?so((function(t){return e(n,t,o)})):uo(o)?so((function(t){return e(n,r,t)})):e(n,r,o)}}}var po=Array.isArray||function(e){return null!=e&&e.length>=0&&"[object Array]"===Object.prototype.toString.call(e)};var vo=Number.isInteger||function(e){return e<<0===e};var yo=so((function(e){return null==e})),ho=fo((function e(t,n,r){if(0===t.length)return n;var o=t[0];if(t.length>1){var a=!yo(r)&&function(e,t){return Object.prototype.hasOwnProperty.call(t,e)}(o,r)&&"object"==typeof r[o]?r[o]:vo(t[1])?[]:{};n=e(Array.prototype.slice.call(t,1),n,a)}return function(e,t,n){if(vo(e)&&po(n)){var r=[].concat(n);return r[e]=t,r}var o={};for(var a in n)o[a]=n[a];return o[e]=t,o}(o,n,r)})),go=function(e){var n=e.model,r=e.saveButtonText,o=e.dense,a=e.onSubmit,i=e.initialValues,l=we((function(){return lo(n,i)}),[n,i]),c=he(l),u=c[0],d=c[1],m=function(e,t){d((function(n){return ho(e,t,n)}))};return ye.createElement(s,{container:!0,component:"form",spacing:2,onSubmit:function(e){e.preventDefault(),a(u)}},n.fields.map((function(e){return ye.createElement(co,{key:e.id,dense:o,field:e,value:u[e.id],update:!!i,onChangeValue:m})})),ye.createElement(s,{item:!0,xs:12},ye.createElement(t,{type:"submit",variant:"contained",size:o?"small":"medium"},r)))},bo=function(e,t,n){var r=n.from,o=n.to,a=ge(),i=Le();be((function(){a.current===r&&t===o&&i(e),a.current=t}),[t])},Eo=function(e){var t=e.model,n=e.modelName,r=e.basePath,o=void 0===r?"":r,a=e.submitUpdateItemRequest,i=e.updateItemRequest,l=e.updateItem,c=e.onSubmitUpdateItem,u=e.onRequestUpdateItem,s=Be().id,d=void 0===s?"":s,m=i.loading||a.loading;return be((function(){u(d)}),[d]),_t({title:"Item updated",message:"The item ".concat(d," has been updated successfully"),severity:"success"},!!a.success,{from:!1,to:!0}),bo("".concat(o,"/"),!!a.success,{from:!1,to:!0}),_t({title:"We had an error",message:a.error||"",severity:"error"},!!a.error,{from:!1,to:!0}),ye.createElement(eo,{loading:m},ye.createElement(Ut,{title:"Edit ".concat(d),preset:"default",breadcrumbs:[{id:"list",text:n,link:"".concat(o,"/")},{id:"update",text:"Edit ".concat(d),link:"".concat(o,"/").concat(d,"/update")}]}),ye.createElement(Zt,null,ye.createElement(go,{model:t,initialValues:l,saveButtonText:"Save",onSubmit:c})))},xo=function(e){var t=e.columns,n=e.options,o=e.data,a=e.onClick,i=e.search,l=e.defaultSort,c=e.defaultOrder,u=e.loading,s=Et(Et([],t,!0),[{id:"__options",label:"",disablePadding:!1,numeric:!1,sort:!1}],!1),d=ye.useState(null),m=d[0],f=d[1];return ye.createElement(ye.Fragment,null,ye.createElement(Dr,{columns:s,data:o,search:i,defaultSort:l,defaultOrder:c,loading:u},(function(e){return e.map((function(e,t){return ye.createElement(Z,{key:e.id,onClick:function(){return a&&a(e)},role:"row","aria-rowindex":t,sx:{cursor:a&&"pointer"}},s.map((function(n,r){var o=n.id;return ye.createElement(ee,{role:"cell",scope:"row",key:o.toString(),"aria-rowindex":t,"aria-colindex":r},e[o])})),n&&ye.createElement(ee,null,ye.createElement(r,{"data-testid":"options-".concat(e.id),onClick:function(t){t.stopPropagation(),f({item:e,anchor:t.currentTarget})}},ye.createElement(ct,null))))}))})),n&&ye.createElement(pe,{anchorEl:null==m?void 0:m.anchor,open:!!m,onClose:function(){return f(null)},anchorOrigin:{vertical:"top",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"}},n.map((function(e){var t=e.id,n=e.label,r=e.onClick;return ye.createElement(fe,{key:t,onClick:function(){m&&r(null==m?void 0:m.item),f(null)}},n)}))))},Co=function(e){var t=e.model,n=e.modelName,r=e.listData,o=e.listRequest,a=e.deleteRequest,i=e.basePath,l=void 0===i?"":i,c=e.deleteFeature,u=void 0===c||c,s=e.updateFeature,d=void 0===s||s,m=e.addFeature,f=void 0===m||m,p=e.detailsFeature,v=void 0===p||p,y=e.onRequestList,h=e.onClickDeleteItem,g=Le();be((function(){y()}),[]),_t({title:"Item deleted",message:"The item has been deleted successfully",severity:"success"},!!a.success,{from:!1,to:!0}),_t({title:"We had an error",message:a.error||"",severity:"error"},!!a.error,{from:!1,to:!0});var b=v?function(e){g("".concat(l,"/").concat(e.id))}:void 0,E=function(e,t){"edit"===e?g("".concat(l,"/").concat(t.id,"/update")):h(t)},x=[];d&&x.push({id:"edit",label:"Edit",onClick:function(e){return E("edit",e)}}),u&&x.push({id:"remove",label:"Remove",onClick:function(e){return E("remove",e)}});var C=[];return f&&C.push({id:"add",text:"Add",href:"".concat(l,"/add")}),ye.createElement(eo,{loading:o.loading||a.loading},ye.createElement(Ut,{title:n,preset:"default",actions:C.length>0?C:void 0}),ye.createElement(Zt,null,ye.createElement(xo,{columns:t.fields.filter((function(e){return e.listable})).map((function(e){return{disablePadding:!1,id:e.id,label:e.name,numeric:"number"===e.type,sort:!1}})),data:r,defaultSort:t.fields[0].id,onClick:b,options:x.length>0?x:void 0})))},So=function(e){var t=e.model,n=e.modelName,r=e.basePath,o=void 0===r?"":r,a=e.onSubmitNewItem,i=e.newItemRequest;return _t({message:"Item added successfully",severity:"success"},!!i.success,{from:!1,to:!0}),bo("".concat(o,"/"),!!i.success,{from:!1,to:!0}),_t({title:"We had an error",message:i.error||"",severity:"error"},!!i.error,{from:!1,to:!0}),ye.createElement(eo,{loading:i.loading},ye.createElement(Ut,{title:"Add ".concat(n),preset:"default",breadcrumbs:[{id:"list",text:n,link:"".concat(o,"/")},{id:"add",text:"Add new ".concat(n),link:"".concat(o,"/add")}]}),ye.createElement(Zt,null,ye.createElement(go,{model:t,saveButtonText:"Save",onSubmit:a})))},wo=function(e){var t=e.model,n=e.modelName,r=e.basePath,o=void 0===r?"":r,a=e.onRequestItem,i=e.itemRequest,l=e.detailsItem,c=Be().id,u=void 0===c?"":c;return be((function(){a(u)}),[u]),ye.createElement(eo,{loading:i.loading},ye.createElement(Ut,{title:u,preset:"default",breadcrumbs:[{id:"list",text:n,link:"".concat(o,"/")},{id:"detail",text:u,link:"".concat(o,"/").concat(u)}]}),ye.createElement(Zt,null,l&&ye.createElement(oo,{model:t,instance:l})))},ko=function(e){var t=e.updateFeature,n=void 0===t||t,r=e.addFeature,o=void 0===r||r,a=e.detailsFeature,i=void 0===a||a;return ye.createElement(qe,null,ye.createElement(He,{path:"",element:ye.createElement(Co,gt({},e))}),i&&ye.createElement(He,{path:":id",element:ye.createElement(wo,gt({},e))}),o&&ye.createElement(He,{path:"add",element:ye.createElement(So,gt({},e))}),n&&ye.createElement(He,{path:":id/update",element:ye.createElement(Eo,gt({},e))}))},To={idle:!0},Io={loading:!0},Oo={success:!0};export{wr as Autocomplete,Xt as Board,Jr as BootstrapDialog,Rt as Bullet,en as CenterContainer,Xr as ConfirmDialog,Zt as Content,qr as ContentPlaceholder,Ir as DateRangeCalendar,Or as DateRangePicker,mt as DefaultPlaceholder,yn as Drawer,zn as DrawerAppBar,On as DrawerContent,an as DrawerContext,dn as DrawerHeader,Qr as DrawerLayout,An as DrawerMain,bn as DrawerProvider,In as DrawerSection,En as DrawerSubheader,Fr as EnhancedRemoteTable,Dr as EnhancedTable,Nr as EnhancedTableHead,Yr as ExpandableAlert,Gr as FormDialog,St as GroupValueCard,Ut as Header,eo as HeaderLayout,To as IdleRequest,At as Label,on as ListPanel,tn as ListPanelContext,nn as ListPanelContextProvider,Kt as LoadingArea,Io as LoadingRequest,Hr as LoremIpsumPlaceholder,Jt as Markdown,go as ModelForm,ko as ModelRouter,Dt as NotificationCenterContext,Ft as NotificationCenterProvider,Mt as NotificationCenterProviderUndefinedError,oo as ObjectDetails,_r as Placeholder,Qt as QueryContainer,Nn as Select,Mn as SignIn,Lr as SkeletonCard,Br as SkeletonGrid,Oo as SuccessRequest,jr as TabCard,Ar as TabCardPanel,Lt as TabContext,Bt as TabContextProvider,Wr as TabPanel,Ht as TabProvider,xo as TableList,Sr as TextField,ln as UndefinedProvider,ht as ValueBoolean,yt as ValueCard,xt as ValueDatetime,dt as ValueEditButton,ut as ValueEditButtons,$t as ValueItem,Gt as ValueLabel,wt as ValueRating,vt as ValueText,zt as bulletClasses,xn as getDrawerItemColors,Ot as getFormData,Tt as getRandomItem,jt as labelClasses,Yt as markdownDefaultOptions,kt as newArrayWithSize,It as newBreakpointsCounter,lo as newInstanceFromValuesOrZeroValue,Kr as useDialog,cn as useDrawer,st as useEditableValueDisplay,Ct as useGetDefaultThemeColor,rn as useListPanel,Vt as useNotificationCenter,_t as useNotifyWhenValueChanges,qt as useTab,Pt as valueItemClasses};
23
+ */yr={exports:{}},"production"===process.env.NODE_ENV?yr.exports=function(){if(fr)return pr;fr=1;var e,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),l=Symbol.for("react.context"),c=Symbol.for("react.server_context"),u=Symbol.for("react.forward_ref"),s=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),m=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen");function v(e){if("object"==typeof e&&null!==e){var p=e.$$typeof;switch(p){case t:switch(e=e.type){case r:case a:case o:case s:case d:return e;default:switch(e=e&&e.$$typeof){case c:case l:case u:case f:case m:case i:return e;default:return p}}case n:return p}}}return e=Symbol.for("react.module.reference"),pr.ContextConsumer=l,pr.ContextProvider=i,pr.Element=t,pr.ForwardRef=u,pr.Fragment=r,pr.Lazy=f,pr.Memo=m,pr.Portal=n,pr.Profiler=a,pr.StrictMode=o,pr.Suspense=s,pr.SuspenseList=d,pr.isAsyncMode=function(){return!1},pr.isConcurrentMode=function(){return!1},pr.isContextConsumer=function(e){return v(e)===l},pr.isContextProvider=function(e){return v(e)===i},pr.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},pr.isForwardRef=function(e){return v(e)===u},pr.isFragment=function(e){return v(e)===r},pr.isLazy=function(e){return v(e)===f},pr.isMemo=function(e){return v(e)===m},pr.isPortal=function(e){return v(e)===n},pr.isProfiler=function(e){return v(e)===a},pr.isStrictMode=function(e){return v(e)===o},pr.isSuspense=function(e){return v(e)===s},pr.isSuspenseList=function(e){return v(e)===d},pr.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===r||t===a||t===o||t===s||t===d||t===p||"object"==typeof t&&null!==t&&(t.$$typeof===f||t.$$typeof===m||t.$$typeof===i||t.$$typeof===l||t.$$typeof===u||t.$$typeof===e||void 0!==t.getModuleId)},pr.typeOf=v,pr}():yr.exports=(vr||(vr=1,"production"!==process.env.NODE_ENV&&function(){var e,t=Symbol.for("react.element"),n=Symbol.for("react.portal"),r=Symbol.for("react.fragment"),o=Symbol.for("react.strict_mode"),a=Symbol.for("react.profiler"),i=Symbol.for("react.provider"),l=Symbol.for("react.context"),c=Symbol.for("react.server_context"),u=Symbol.for("react.forward_ref"),s=Symbol.for("react.suspense"),d=Symbol.for("react.suspense_list"),m=Symbol.for("react.memo"),f=Symbol.for("react.lazy"),p=Symbol.for("react.offscreen");function v(e){if("object"==typeof e&&null!==e){var p=e.$$typeof;switch(p){case t:var v=e.type;switch(v){case r:case a:case o:case s:case d:return v;default:var y=v&&v.$$typeof;switch(y){case c:case l:case u:case f:case m:case i:return y;default:return p}}case n:return p}}}e=Symbol.for("react.module.reference");var y=l,h=i,g=t,b=u,E=r,x=f,C=m,S=n,w=a,k=o,T=s,I=d,O=!1,P=!1;hr.ContextConsumer=y,hr.ContextProvider=h,hr.Element=g,hr.ForwardRef=b,hr.Fragment=E,hr.Lazy=x,hr.Memo=C,hr.Portal=S,hr.Profiler=w,hr.StrictMode=k,hr.Suspense=T,hr.SuspenseList=I,hr.isAsyncMode=function(e){return O||(O=!0,console.warn("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.")),!1},hr.isConcurrentMode=function(e){return P||(P=!0,console.warn("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.")),!1},hr.isContextConsumer=function(e){return v(e)===l},hr.isContextProvider=function(e){return v(e)===i},hr.isElement=function(e){return"object"==typeof e&&null!==e&&e.$$typeof===t},hr.isForwardRef=function(e){return v(e)===u},hr.isFragment=function(e){return v(e)===r},hr.isLazy=function(e){return v(e)===f},hr.isMemo=function(e){return v(e)===m},hr.isPortal=function(e){return v(e)===n},hr.isProfiler=function(e){return v(e)===a},hr.isStrictMode=function(e){return v(e)===o},hr.isSuspense=function(e){return v(e)===s},hr.isSuspenseList=function(e){return v(e)===d},hr.isValidElementType=function(t){return"string"==typeof t||"function"==typeof t||t===r||t===a||t===o||t===s||t===d||t===p||"object"==typeof t&&null!==t&&(t.$$typeof===f||t.$$typeof===m||t.$$typeof===i||t.$$typeof===l||t.$$typeof===u||t.$$typeof===e||void 0!==t.getModuleId)},hr.typeOf=v}()),hr),"undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")(),Bn.exports.oneOfType([Bn.exports.func,Bn.exports.object]);let gr=0;const br=ye["useId".toString()];function Er(e){if(void 0!==br){const t=br();return null!=e?e:t}return function(e){const[t,n]=ye.useState(e),r=e||t;return ye.useEffect((()=>{null==t&&(gr+=1,n(`mui-${gr}`))}),[t]),r}(e)}const xr={border:0,clip:"rect(0 0 0 0)",height:"1px",margin:-1,overflow:"hidden",padding:0,position:"absolute",whiteSpace:"nowrap",width:"1px"};const Cr=Number.isInteger||function(e){return"number"==typeof e&&isFinite(e)&&Math.floor(e)===e};function Sr(e,t,n,r){const o=e[t];if(null==o||!Cr(o)){const e=function(e){const t=typeof e;switch(t){case"number":return Number.isNaN(e)?"NaN":Number.isFinite(e)?e!==Math.floor(e)?"float":"number":"Infinity";case"object":return null===e?"null":e.constructor.name;default:return t}}(o);return new RangeError(`Invalid ${r} \`${t}\` of type \`${e}\` supplied to \`${n}\`, expected \`integer\`.`)}return null}function wr(e,t,...n){return void 0===e[t]?null:Sr(e,t,...n)}function kr(){return null}wr.isRequired=Sr,kr.isRequired=kr,process.env.NODE_ENV;var Tr=function(t){var n,r=t.id,o=t.label,a=t.InputLabelProps,i=t.InputProps,l=t.fetching,c=t.loading,u=t.helperText,s=t.hexColor,d=t.size,m=t.fullWidth,f=t.sx,p=Et(t,["id","label","InputLabelProps","InputProps","fetching","loading","helperText","hexColor","size","fullWidth","sx"]),v=Er(r),y=u&&v?"".concat(v,"-helper-text"):void 0,g=o&&v?"".concat(v,"-label"):void 0,b=s?((n={})["& .".concat(B.notchedOutline)]={borderColor:"".concat(s," !important")},n["& .".concat(q.root)]={color:s},n["& .".concat(B.input)]={color:s},n["& .".concat(H.root)]={color:s},n["& .".concat(U.bar)]={backgroundColor:s},n["& .".concat(Y.endAdornment," .").concat(J.root)]={color:s},n):{};return he.createElement(V,{sx:b,fullWidth:m},he.createElement(F,bt({size:"small"===d?"small":"normal",id:g,htmlFor:v},a),o),he.createElement(X,bt({},i,{id:v,label:o,size:d,fullWidth:m,endAdornment:he.createElement(e,{position:"end"},null==i?void 0:i.endAdornment,c?he.createElement(h,{color:"inherit",size:20,sx:{ml:1}}):null),sx:f},p)),l&&!c&&he.createElement(C,{color:"inherit",sx:{position:"absolute",left:0,right:0,bottom:0}}),u&&he.createElement(G,{id:y},u))},Ir=function(e){var t=e.label,n=e.loading,r=e.fetching,o=e.options,a=e.helperText,i=e.color,l=e.onChangeValue,c=void 0===l?function(){return null}:l,u=e.sx,s=Et(e,["label","loading","fetching","options","helperText","color","onChangeValue","sx"]),d=n||r;return he.createElement(K,bt({loading:d,options:r?[]:o,onChange:function(e,t){return c(t)}},s,{renderInput:function(e){return he.createElement(Tr,bt({},e,{label:t,fullWidth:!0,fetching:r,loading:n,hexColor:i,helperText:a}))},sx:u}))},Or=T(o,{shouldForwardProp:function(e){return"dayIsBetween"!==e&&"isFirstDay"!==e&&"isLastDay"!==e&&"isStartOfWeek"!==e&&"isEndOfWeek"!==e}})((function(e){var t=e.theme,n=e.dayIsBetween,r=e.isFirstDay,o=e.isLastDay;return bt(bt(bt({},(r||o||n)&&{borderRadius:0,backgroundColor:"".concat(t.palette.primary.light,"40"),margin:0}),r&&{borderTopLeftRadius:"50%",borderBottomLeftRadius:"50%"}),o&&{borderTopRightRadius:"50%",borderBottomRightRadius:"50%"})})),Pr=function(e){var t=e.day,n=e.dateRange,r=Et(e,["day","dateRange"]);if(null==n)return he.createElement(Ve,bt({day:t},r));var o=n[0],a=n[1],i=!!a&&ze(t,o)&&rt(t,a),l=Re(t,o),c=!!a&&Re(t,a),u=Re(t,je(t)),s=Re(t,Ae(t));return he.createElement(Or,{dayIsBetween:i,isFirstDay:l||i&&u,isLastDay:c||i&&s,"aria-label":$e(t,"yyyy-MM-dd"),"aria-selected":i||l||c,role:"gridcell"},he.createElement(Ve,bt({},r,{day:t,selected:l||c})))},$r=function(e){var t=e.defaultValue,n=e.onValueChange,r=ge(t),o=r[0],a=r[1],i=ge(0),l=i[0],c=i[1],u=function(e,t,r){a(e),n(e,t),c(r)};return he.createElement(De,{value:null,onChange:function(e){if(e)return 1===l&&e<o[0]||0===l&&o[1]&&e>o[1]?u([e,void 0],0,1):void u([0===l?e:o[0],1===l?e:o[1]],l,0===l?1:0)},slots:{day:Pr},slotProps:{day:{dateRange:o}},"aria-label":"calendar range picker"})},zr=function(t){var n=t.defaultValue,o=t.format,a=t.label,i=t.fullWidth,u=t.onValueChange,s=t.size,d=void 0===s?"medium":s,m=ge(!1),f=m[0],p=m[1],v=ge(n),y=v[0],h=v[1];return he.createElement(he.Fragment,null,he.createElement(l,{label:a,fullWidth:i,size:d,value:"".concat($e(y[0],o)," - ").concat(y[1]?$e(y[1],o):o.toUpperCase()),InputProps:{endAdornment:he.createElement(e,{position:"end"},he.createElement(r,{onClick:function(){return p((function(e){return!e}))},"aria-label":"open calendar"},he.createElement(nt,null)))}}),he.createElement(c,null,he.createElement(j,{in:f,"aria-label":"calendar collapse"},he.createElement($r,{defaultValue:n,onValueChange:function(e,t){h(e),u(e,t),p(t<1)}}))))},Rr=function(e){var n=e.open,a=e.title,i=e.component,l=e.componentProps,c=void 0===l?{}:l,u=e.disabled,s=e.disableAccept,d=e.disableCancel,m=e.actions,f=void 0===m?[]:m,p=e.children,v=e.loading,y=e.cancelable,g=e.callCloseWhenCancel,b=void 0===g||g,E=e.acceptable,x=e.acceptText,C=void 0===x?"Accept":x,S=e.cancelText,w=void 0===S?"Cancel":S,k=e.onAccept,T=e.onCancel,I=void 0===T?function(){return null}:T,O=e.onClose,P=e.acceptType,$=void 0===P?"button":P,z=f.length>0||E||y;return he.createElement(Q,{open:n,onClose:O},he.createElement(Z,{sx:{display:"flex",alignItems:"center"}},a,v&&!E&&he.createElement(h,{size:20,sx:{ml:2,color:function(e){return e.palette.grey[500]}}}),he.createElement(r,{disabled:u,"aria-label":"close",onClick:O,sx:{position:"absolute",right:8,top:8,color:function(e){return e.palette.grey[500]}}},he.createElement(Pe,null))),he.createElement(o,bt({component:i},c),he.createElement(ee,{dividers:!0},p),z&&he.createElement(te,null,f.map((function(e){var n=e.id,r=e.text,o=e.type,a=void 0===o?"button":o,i=e.onClick,l=e.color,c=void 0===l?"primary":l;return he.createElement(t,{key:n,type:a,disabled:u,onClick:i,color:c},r)})),y&&he.createElement(t,{color:"error",disabled:u||d,onClick:function(){I(),b&&O()}},w),E&&he.createElement(tt,{type:$,loading:v,disabled:u||s,onClick:k},C))))},jr=function(e){var t=e.open,n=e.title,r=e.loading,o=e.disabled,a=e.confirmText,i=void 0===a?"Confirm":a,c=e.cancelText,u=void 0===c?"Cancel":c,s=e.passphrase,d=e.children,m=e.onConfirm,f=e.onCancel,p=ge(""),v=p[0],y=p[1],h=!s||v===s;return he.createElement(Rr,{title:n,loading:r,disabled:r||o,disableAccept:!h,open:t,onClose:f,acceptable:!0,cancelable:!0,callCloseWhenCancel:!1,acceptText:i,cancelText:u,onCancel:f,onAccept:m},d,s&&he.createElement(l,{size:"small",fullWidth:!0,value:v,onChange:function(e){return y(e.target.value)},placeholder:s}))},Ar=function(e){var t=e.open,n=e.title,r=e.loading,o=e.disabled,a=e.submitText,i=void 0===a?"Submit":a,l=e.cancelText,c=void 0===l?"Cancel":l,u=e.children,s=e.onSubmit,d=e.onCancel;return he.createElement(Rr,{component:"form",componentProps:{onSubmit:function(e){e.preventDefault(),s(Pt(e))}},title:n,loading:r,disabled:r||o,open:t,onClose:d,callCloseWhenCancel:!1,cancelable:!0,acceptable:!0,cancelText:c,onCancel:d,acceptText:i,acceptType:"submit"},u)},Wr=function(e){void 0===e&&(e=!1);var t=ge(e),n=t[0],r=t[1];return{isOpen:n,open:function(){return r(!0)},close:function(){return r(!1)},setIsOpen:r}},Nr=function(e){var t=e.title,r=e.variant,o=void 0===r?"primary":r,i=n().palette,l={primary:void 0,error:"error",warning:i.warning.main,success:i.success.main};return he.createElement(a,{color:l[o],variant:"h4",pb:1,borderBottom:1,borderColor:"grey.300"},t)},Mr=function(e){var n=e.variant,r=void 0===n?"primary":n,o=e.title,i=e.description,l=e.descriptionVariant,c=void 0===l?"body2":l,u=e.buttonText,d=e.helperText,m=e.helperTextVariant,f=void 0===m?"caption":m,p=e.confirmable,v=e.passphrase,y=e.confirmTitle,h=void 0===y?"":y,g=e.confirmDescription,b=void 0===g?"":g,E=e.onAction,x=Wr(),C=x.isOpen,S=x.open,w=x.close;return he.createElement(he.Fragment,null,he.createElement(s,{container:!0,spacing:1},he.createElement(s,{item:!0,xs:12,mb:2},he.createElement(Nr,{title:o})),i&&he.createElement(s,{item:!0,xs:12},he.createElement(a,{variant:c},i)),he.createElement(s,{item:!0,xs:12,mt:1},he.createElement(t,{color:r,variant:"contained",onClick:function(){p?S():E()}},u)),d&&he.createElement(s,{item:!0,xs:12},he.createElement(a,{variant:f},d))),he.createElement(jr,{open:C,title:h,passphrase:v,onCancel:w,onConfirm:function(){E()}},he.createElement(ne,null,b)))},Dr=Ce([0,function(){return null}]),Vr=Dr.Provider,Fr=T((function(e){return he.createElement(E,bt({},e,{TabIndicatorProps:{children:he.createElement("span",{className:"MuiTabs-indicatorSpan"})}}))}))((function(e){var t=e.theme;return{minHeight:t.spacing(5),"& .MuiTabs-indicator":{display:"flex",justifyContent:"center",backgroundColor:"transparent"},"& .MuiTabs-indicatorSpan":{maxWidth:40,width:"100%",backgroundColor:t.palette.primary.main}}})),_r=T(x)((function(e){var t=e.theme;return{textTransform:"none",fontWeight:t.typography.fontWeightRegular,marginRight:t.spacing(1),color:t.palette.text.secondary,paddingTop:0,paddingBottom:0,minHeight:t.spacing(5),"&.Mui-selected":{color:t.palette.text.secondary,fontWeight:t.typography.fontWeightBold}}})),Lr=function(e){var t=e.children,n=e.tabs,r=e.initialTab,a=void 0===r?0:r,i=e.onChangeTab,l=void 0===i?function(){return null}:i,u=St(),s=ge(a),d=s[0],m=s[1];return he.createElement(Vr,{value:[d,m]},he.createElement(c,{variant:"outlined"},he.createElement(o,{bgcolor:u},he.createElement(Fr,{value:d,onChange:function(e,t){m(t),l(n[t],t)}},n.map((function(e){var t=e.text,n=e.icon;return he.createElement(_r,{iconPosition:"start",disableRipple:!0,key:t,label:t,icon:n})})))),t))},Br=function(e){var t=e.index,n=e.children,r=e.sx,a=Se(Dr)[0],i=a===t;return Array.isArray(t)&&(i=t.includes(a)),i?he.createElement(o,{sx:r},n):null};function qr(e){var t=e.children,n=e.index,r=Ht()[0],a=r===n;return Array.isArray(n)&&(a=n.includes(r)),he.createElement("div",{role:"tabpanel",hidden:!a,id:"simple-tabpanel-".concat(n),"aria-labelledby":"simple-tab-".concat(n)},a&&he.createElement(o,{sx:{p:3}},t))}var Hr=function(e){var t=e.order,n=e.orderBy,r=e.headCells,a=e.onRequestSort;return he.createElement(re,null,he.createElement(oe,null,r.map((function(e){return he.createElement(ae,{variant:"head",key:String(e.id),padding:e.disablePadding?"none":"normal",sortDirection:n===e.id&&t,sx:{fontWeight:"bold"}},e.sort?he.createElement(ie,{active:n===e.id,direction:n===e.id?t:"asc",onClick:(r=e.id,function(){a(r)})},e.label,n===e.id?he.createElement(o,{component:"span",sx:xr},"desc"===t?"sorted descending":"sorted ascending"):null):e.label);var r}))))};function Ur(e,t,n){return t[n]<e[n]?-1:t[n]>e[n]?1:0}var Yr=function(t){var n=t.children,r=t.data,a=t.search,i=t.columns,c=t.defaultSort,u=t.defaultOrder,s=void 0===u?"asc":u,d=t.loading,m=void 0!==d&&d,f=ge(""),p=f[0],v=f[1],y=ge(s),g=y[0],b=y[1],E=ge(c),x=E[0],C=E[1],S=r.slice().filter(function(e,t){return function(n){return!t||e.some((function(e){var r=n[e.id];return(null==r?void 0:r.toLowerCase)&&(r=r.toLowerCase()),null==r?void 0:r.toString().includes(t.toLowerCase())}))}}(i,p)).sort(function(e,t){return"desc"===e?function(e,n){return Ur(e,n,t)}:function(e,n){return-Ur(e,n,t)}}(g,x));return he.createElement(he.Fragment,null,he.createElement(o,{sx:{paddingX:1,paddingBottom:2}},a&&he.createElement(o,{paddingY:2},he.createElement(l,{fullWidth:!0,placeholder:"Search",InputProps:{role:"search",startAdornment:he.createElement(e,{position:"start"},he.createElement(ot,null))},onChange:function(e){return v(e.target.value)}})),he.createElement(le,null,he.createElement(ce,null,he.createElement(Hr,{order:g,orderBy:x,headCells:i,onRequestSort:function(e){b(x===e&&"asc"===g?"desc":"asc"),C(e)}}),he.createElement(ue,null,m?he.createElement(oe,null,he.createElement(ae,{colSpan:i.length,sx:{textAlign:"center"}},he.createElement(h,null))):0===S.length?he.createElement(oe,null,he.createElement(ae,{colSpan:i.length,sx:{textAlign:"center"}},"No data")):n(S))))))};Yr.defaultProps={defaultOrder:"asc"};var Jr,Xr=function(e){var t=e.children,n=e.data,r=e.loading,o=e.columns,a=e.defaultSort,i=e.defaultOrder,l=e.onRequestSort,c=ge({orderBy:a,order:i||"asc"}),u=c[0],s=c[1];return he.createElement(he.Fragment,null,he.createElement(le,null,he.createElement(ce,null,he.createElement(Hr,{order:u.order,orderBy:u.orderBy,headCells:o,onRequestSort:function(e){s((function(t){var n=t.orderBy,r=t.order,o=n===e&&"asc"===r?"desc":"asc";return l(e,o),{orderBy:e,order:o}}))}}),he.createElement(ue,null,r?he.createElement(oe,null,he.createElement(ae,{colSpan:o.length,sx:{textAlign:"center"}},he.createElement(h,null))):n.map((function(e,n){return t(e,n)}))))))},Gr=function(e){var n=e.title,r=e.subtitle,i=e.icon,l=e.iconSize,c=void 0===l?200:l,u=e.actions;return he.createElement(o,{display:"flex",flexDirection:"column",justifyContent:"center",alignItems:"center",textAlign:"center"},i&&i({size:c,color:"primary"}),he.createElement(a,{variant:"h4",role:"heading","aria-level":1},n),he.createElement(a,{variant:"subtitle1",role:"heading","aria-level":2,sx:{mt:2}},r),u&&he.createElement(o,{sx:{pt:2}},u.map((function(e,n){var r=e.id,o=e.text,a=e.href,i=e.onClick;return he.createElement(t,{key:r,role:"button",variant:"contained",href:a,onClick:i,sx:{mr:n<u.length-1?2:0}},o)}))))},Kr=function(e){var t=e.width,n=void 0===t?"100%":t,r=e.animation,a=void 0!==r&&r;return he.createElement(o,{width:n},he.createElement(se,{animation:a,variant:"rectangular",height:118}),he.createElement(se,{animation:a,variant:"rectangular",height:16,sx:{my:1}}),he.createElement(se,{animation:a,variant:"rectangular",width:"80%",height:16}))},Qr=function(e){var t=e.size,n=void 0===t?20:t;return he.createElement(s,{container:!0,spacing:2},Tt(n,0).map((function(e,t){return he.createElement(s,{item:!0,key:t,xs:4},he.createElement(Kr,{width:1}))})))},Zr=function(e){var t=e.size,n=void 0===t?20:t,r=e.children,o=e.p;return he.createElement(g,{component:"main",sx:{p:o},"data-testid":"content-placeholder-test"},r,he.createElement(Qr,{size:n}))},eo=function(e){var t=e.count,n=void 0===t?3:t,r=e.units,o=void 0===r?"paragraph":r,i=e.variant,l=void 0===i?"body1":i;return he.createElement(a,{variant:l},at({count:n,units:o}))},to=((Jr={})["& .".concat(de.message)]={width:1},Jr),no=xe((function(e,t){var n=e.severity,a=e.iconMapping,i=e.title,l=e.message,c=e.metadata,u=e.metadataComponent,s=e.onClose,d=e.sx,m=void 0===d?{}:d,f=ge(!1),p=f[0],h=f[1];return he.createElement(v,{ref:t,severity:n,iconMapping:a,onClose:s,action:he.createElement(o,{display:"flex",flexDirection:"column"},he.createElement(r,{color:"inherit",onClick:s},he.createElement(Pe,{fontSize:"small"})),c&&he.createElement(r,{color:"inherit",onClick:function(){return h((function(e){return!e}))}},p?he.createElement(it,{fontSize:"small"}):he.createElement(Qe,{fontSize:"small"}))),sx:bt(bt({},to),m)},he.createElement(o,{sx:{w:1}},i&&he.createElement(y,null,i),l,c&&he.createElement(j,{in:p,sx:{mt:2}},he.createElement(Qt,{content:c},u))))})),ro=function(e){var t=e.drawerProviderProps,n=e.children,r=n[0],o=n[1],a=n[2];return he.createElement(Cn,bt({},t),r,o,he.createElement(Mn,null,a))},oo=function(){return he.createElement(lt,{color:"error",sx:{width:200,height:200}})},ao=function(e){var t=e.loading,n=e.children,r=e.fetching,a=e.error,i=n[0],l=n[1];return he.createElement(Ut,null,he.createElement(o,{display:"flex",flexDirection:"column",height:1},i,r&&he.createElement(o,{width:1},he.createElement(C,null)),t&&he.createElement(en,null),a&&he.createElement(o,{mt:4},he.createElement(Gr,{icon:a.icon||oo,title:a.title||"There has been an error",subtitle:a.message})),!t&&!a&&l))},io=function(e,t,n){var r=(void 0===n?{}:n).dense,o=e.id,a=e.name,i=e.type,l=t[o];return"boolean"===i?he.createElement(gt,{dense:r,label:a,value:l}):"date"===i||"time"===i||"datetime"===i?he.createElement(Ct,{dense:r,label:a,value:l,format:e.format}):"object"!=typeof l||Array.isArray(l)?he.createElement(yt,{dense:r,label:a,value:null==l?void 0:l.toString()}):he.createElement(yt,{dense:r,label:a,value:JSON.stringify(l)})},lo=function(e){var t=e.field,n=t.name,r=t.description,o=t.value,a=e.instance,i=e.dense,l=[{field:"id",headerName:"ID",width:70}];o.forEach((function(e){l.push({field:e.id,headerName:e.name})}));var c=a.map((function(e,t){return bt({id:t},e)}));return he.createElement(wt,{title:n,subtitle:r,dense:i},he.createElement(s,{item:!0,xs:12},he.createElement(ct,{rows:c,columns:l,density:i?"compact":"standard",disableRowSelectionOnClick:!0,pageSizeOptions:[5],initialState:{pagination:{paginationModel:{pageSize:5}}},sx:{height:400}})))},co=function(e){var t=e.field,n=t.name,r=t.description,o=t.value,a=e.instance,i=e.dense,l=Ot();return he.createElement(wt,{title:n,subtitle:r,dense:i},o.map((function(e){var t=e.id,n=e.xs,r=e.sm,o=e.md,c=e.lg,u=e.xl,s=l.increment(e);return he.createElement(zt,{key:t,xs:n,sm:r,md:o,lg:c,xl:u,bordered:s},io(e,a,{dense:i}))})))},uo=function(e){var t=e.model,n=e.instance,r=e.dense,o=Ot();return he.createElement(s,{container:!0,spacing:r?1:2},t.fields.map((function(e){var t=e.id,a=e.type,i=e.xs,l=void 0===i?3:i,c=e.sm,u=void 0===c?0:c,d=e.md,m=void 0===d?0:d,f=e.lg,p=void 0===f?0:f,v=e.xl,y=void 0===v?0:v;if("group"===a)return o.increment({xs:12}),he.createElement(s,{item:!0,key:t,xs:12},he.createElement(co,{field:e,instance:n[t],dense:r}));if("group[]"===a)return o.increment({xs:12}),he.createElement(s,{item:!0,key:t,xs:12},he.createElement(lo,{field:e,instance:n[t],dense:r}));var h=o.increment(e);return he.createElement(zt,{key:t,xs:l,sm:u,md:m,lg:p,xl:y,bordered:h},io(e,n,{dense:r}))})))},so={string:"",number:0,boolean:!1,enum:"",multienum:[],date:new Date(1970,0,1,0,0),time:new Date(1970,0,1,0,0),datetime:new Date(1970,0,1,0,0),group:{},"group[]":[],"string[]":[],"number[]":[]},mo=function(e,t){return t&&t[e.id]||"default"in e&&e.default||so[e.type]},fo=function(e,t){void 0===t&&(t=void 0);var n={};return e.fields.forEach((function(e){if("group"===e.type){var r={};e.value.forEach((function(n){r[n.id]=mo(n,t&&t[e.id])})),n[e.id]=r}else n[e.id]=mo(e,t)})),n},po=function(e){var t=e.field,n=e.path,r=void 0===n?[]:n,a=e.value,i=e.dense,c=e.update,u=e.onChangeValue,d=function(e,t){e.preventDefault();var n=e.target.value;"number"===t&&"string"==typeof n?n=parseInt(e.target.value,10):t.includes("[]")&&(n=e.target.value.split(",")),u(xt(xt([],r,!0),[e.target.name],!1),n)},m=function(e,t){u(xt(xt([],r,!0),[t],!1),e)};St({lightWeight:200,darkWeight:800});var f,p=t.id,v=t.type,y=t.name,h=t.description,g=t.updatable,b=void 0===g||g,E=t.required,x=void 0===E||E,C=t.xs,S=t.sm,w=t.md,T=t.lg,I=t.xl,O=!b&&c,P=i?"small":"medium";if("group"===v)f=he.createElement(wt,{title:y,subtitle:h,dense:i},he.createElement(s,{container:!0,spacing:2,sx:{p:2}},t.value.map((function(e){return he.createElement(po,{key:e.id,field:e,dense:i,path:xt(xt([],r,!0),[p],!1),value:a[e.id],update:c,onChangeValue:u})}))));else if("boolean"===v)f=he.createElement(o,{sx:{height:1,display:"flex",alignItems:"center"}},he.createElement(me,{control:he.createElement(fe,{name:p,size:P,onChange:function(e){e.preventDefault(),u(xt(xt([],r,!0),[e.target.name],!1),e.target.checked)},checked:a,disabled:O}),label:y}));else if("enum"===v)f=he.createElement(V,{fullWidth:!0},he.createElement(F,{id:"".concat(p,"-select-label")},y),he.createElement(_,{labelId:"".concat(p,"-select-label"),id:"".concat(p,"-select"),value:a,label:y,name:p,size:P,onChange:function(e){e.preventDefault(),u(xt(xt([],r,!0),[e.target.name],!1),e.target.value)},required:x,disabled:O},t.value.map((function(e){return he.createElement(pe,{key:e,value:e},e)}))));else if("multienum"===v)f=he.createElement(V,{fullWidth:!0},he.createElement(F,{id:"".concat(p,"-select-label")},y),he.createElement(_,{labelId:"".concat(p,"-select-label"),id:"".concat(p,"-select"),value:a||[],renderValue:function(e){return e.join(", ")},label:y,name:p,size:P,onChange:function(e){e.preventDefault();var t=e.target.value,n="string"==typeof t?t.split(","):t;u(xt(xt([],r,!0),[e.target.name],!1),n)},required:x,disabled:O,multiple:!0},t.value.map((function(e){return he.createElement(pe,{key:e,value:e},he.createElement(fe,{checked:(a||[]).includes(e)}),he.createElement(k,{primary:e}))}))));else if("date"===v)f=he.createElement(Fe,{label:y,format:t.format,value:a,slotProps:{field:{size:P}},disabled:O,onChange:function(e){return m(e,p)}});else if("time"===v)f=he.createElement(Ne,{label:y,format:t.format,value:a,slotProps:{field:{size:P}},disabled:O,onChange:function(e){return m(e,p)}});else if("datetime"===v)f=he.createElement(We,{label:y,format:t.format,value:a,slotProps:{field:{size:P}},disabled:O,onChange:function(e){return m(e,p)}});else{if("group[]"===v)return null;f=v.includes("[]")?he.createElement(l,{required:x,type:"text",label:y,name:p,size:P,variant:"outlined",helperText:"Use comas to separate multiple values",fullWidth:!0,disabled:O,value:a.join(","),onChange:function(e){return d(e,v)}}):he.createElement(l,{required:x,type:v,label:y,size:P,name:p,variant:"outlined",fullWidth:!0,value:a,disabled:O,onChange:function(e){return d(e,v)}})}return he.createElement(s,{item:!0,key:p,xs:C,sm:S,md:w,lg:T,xl:I},f)};function vo(e){return null!=e&&"object"==typeof e&&!0===e["@@functional/placeholder"]}function yo(e){return function t(n){return 0===arguments.length||vo(n)?t:e.apply(this,arguments)}}function ho(e){return function t(n,r){switch(arguments.length){case 0:return t;case 1:return vo(n)?t:yo((function(t){return e(n,t)}));default:return vo(n)&&vo(r)?t:vo(n)?yo((function(t){return e(t,r)})):vo(r)?yo((function(t){return e(n,t)})):e(n,r)}}}function go(e){return function t(n,r,o){switch(arguments.length){case 0:return t;case 1:return vo(n)?t:ho((function(t,r){return e(n,t,r)}));case 2:return vo(n)&&vo(r)?t:vo(n)?ho((function(t,n){return e(t,r,n)})):vo(r)?ho((function(t,r){return e(n,t,r)})):yo((function(t){return e(n,r,t)}));default:return vo(n)&&vo(r)&&vo(o)?t:vo(n)&&vo(r)?ho((function(t,n){return e(t,n,o)})):vo(n)&&vo(o)?ho((function(t,n){return e(t,r,n)})):vo(r)&&vo(o)?ho((function(t,r){return e(n,t,r)})):vo(n)?yo((function(t){return e(t,r,o)})):vo(r)?yo((function(t){return e(n,t,o)})):vo(o)?yo((function(t){return e(n,r,t)})):e(n,r,o)}}}var bo=Array.isArray||function(e){return null!=e&&e.length>=0&&"[object Array]"===Object.prototype.toString.call(e)};var Eo=Number.isInteger||function(e){return e<<0===e};var xo=yo((function(e){return null==e})),Co=go((function e(t,n,r){if(0===t.length)return n;var o=t[0];if(t.length>1){var a=!xo(r)&&function(e,t){return Object.prototype.hasOwnProperty.call(t,e)}(o,r)&&"object"==typeof r[o]?r[o]:Eo(t[1])?[]:{};n=e(Array.prototype.slice.call(t,1),n,a)}return function(e,t,n){if(Eo(e)&&bo(n)){var r=[].concat(n);return r[e]=t,r}var o={};for(var a in n)o[a]=n[a];return o[e]=t,o}(o,n,r)})),So=function(e){var n=e.model,r=e.saveButtonText,o=e.dense,a=e.onSubmit,i=e.initialValues,l=ke((function(){return fo(n,i)}),[n,i]),c=ge(l),u=c[0],d=c[1],m=function(e,t){d((function(n){return Co(e,t,n)}))};return he.createElement(s,{container:!0,component:"form",spacing:2,onSubmit:function(e){e.preventDefault(),a(u)}},n.fields.map((function(e){return he.createElement(po,{key:e.id,dense:o,field:e,value:u[e.id],update:!!i,onChangeValue:m})})),he.createElement(s,{item:!0,xs:12},he.createElement(t,{type:"submit",variant:"contained",size:o?"small":"medium"},r)))},wo=function(e,t,n){var r=n.from,o=n.to,a=be(),i=Be();Ee((function(){a.current===r&&t===o&&i(e),a.current=t}),[t])},ko=function(e){var t=e.model,n=e.modelName,r=e.basePath,o=void 0===r?"":r,a=e.submitUpdateItemRequest,i=e.updateItemRequest,l=e.updateItem,c=e.onSubmitUpdateItem,u=e.onRequestUpdateItem,s=qe().id,d=void 0===s?"":s,m=i.loading||a.loading;return Ee((function(){u(d)}),[d]),Lt({title:"Item updated",message:"The item ".concat(d," has been updated successfully"),severity:"success"},!!a.success,{from:!1,to:!0}),wo("".concat(o,"/"),!!a.success,{from:!1,to:!0}),Lt({title:"We had an error",message:a.error||"",severity:"error"},!!a.error,{from:!1,to:!0}),he.createElement(ao,{loading:m},he.createElement(Xt,{title:"Edit ".concat(d),preset:"default",breadcrumbs:[{id:"list",text:n,link:"".concat(o,"/")},{id:"update",text:"Edit ".concat(d),link:"".concat(o,"/").concat(d,"/update")}]}),he.createElement(nn,null,he.createElement(So,{model:t,initialValues:l,saveButtonText:"Save",onSubmit:c})))},To=function(e){var t=e.columns,n=e.options,o=e.data,a=e.onClick,i=e.search,l=e.defaultSort,c=e.defaultOrder,u=e.loading,s=xt(xt([],t,!0),[{id:"__options",label:"",disablePadding:!1,numeric:!1,sort:!1}],!1),d=he.useState(null),m=d[0],f=d[1];return he.createElement(he.Fragment,null,he.createElement(Yr,{columns:s,data:o,search:i,defaultSort:l,defaultOrder:c,loading:u},(function(e){return e.map((function(e,t){return he.createElement(oe,{key:e.id,onClick:function(){return a&&a(e)},role:"row","aria-rowindex":t,sx:{cursor:a&&"pointer"}},s.map((function(n,r){var o=n.id;return he.createElement(ae,{role:"cell",scope:"row",key:o.toString(),"aria-rowindex":t,"aria-colindex":r},e[o])})),n&&he.createElement(ae,null,he.createElement(r,{"data-testid":"options-".concat(e.id),onClick:function(t){t.stopPropagation(),f({item:e,anchor:t.currentTarget})}},he.createElement(ut,null))))}))})),n&&he.createElement(ve,{anchorEl:null==m?void 0:m.anchor,open:!!m,onClose:function(){return f(null)},anchorOrigin:{vertical:"top",horizontal:"left"},transformOrigin:{vertical:"top",horizontal:"left"}},n.map((function(e){var t=e.id,n=e.label,r=e.onClick;return he.createElement(pe,{key:t,onClick:function(){m&&r(null==m?void 0:m.item),f(null)}},n)}))))},Io=function(e){var t=e.model,n=e.modelName,r=e.listData,o=e.listRequest,a=e.deleteRequest,i=e.basePath,l=void 0===i?"":i,c=e.deleteFeature,u=void 0===c||c,s=e.updateFeature,d=void 0===s||s,m=e.addFeature,f=void 0===m||m,p=e.detailsFeature,v=void 0===p||p,y=e.onRequestList,h=e.onClickDeleteItem,g=Be();Ee((function(){y()}),[]),Lt({title:"Item deleted",message:"The item has been deleted successfully",severity:"success"},!!a.success,{from:!1,to:!0}),Lt({title:"We had an error",message:a.error||"",severity:"error"},!!a.error,{from:!1,to:!0});var b=v?function(e){g("".concat(l,"/").concat(e.id))}:void 0,E=function(e,t){"edit"===e?g("".concat(l,"/").concat(t.id,"/update")):h(t)},x=[];d&&x.push({id:"edit",label:"Edit",onClick:function(e){return E("edit",e)}}),u&&x.push({id:"remove",label:"Remove",onClick:function(e){return E("remove",e)}});var C=[];return f&&C.push({id:"add",text:"Add",href:"".concat(l,"/add")}),he.createElement(ao,{loading:o.loading||a.loading},he.createElement(Xt,{title:n,preset:"default",actions:C.length>0?C:void 0}),he.createElement(nn,null,he.createElement(To,{columns:t.fields.filter((function(e){return e.listable})).map((function(e){return{disablePadding:!1,id:e.id,label:e.name,numeric:"number"===e.type,sort:!1}})),data:r,defaultSort:t.fields[0].id,onClick:b,options:x.length>0?x:void 0})))},Oo=function(e){var t=e.model,n=e.modelName,r=e.basePath,o=void 0===r?"":r,a=e.onSubmitNewItem,i=e.newItemRequest;return Lt({message:"Item added successfully",severity:"success"},!!i.success,{from:!1,to:!0}),wo("".concat(o,"/"),!!i.success,{from:!1,to:!0}),Lt({title:"We had an error",message:i.error||"",severity:"error"},!!i.error,{from:!1,to:!0}),he.createElement(ao,{loading:i.loading},he.createElement(Xt,{title:"Add ".concat(n),preset:"default",breadcrumbs:[{id:"list",text:n,link:"".concat(o,"/")},{id:"add",text:"Add new ".concat(n),link:"".concat(o,"/add")}]}),he.createElement(nn,null,he.createElement(So,{model:t,saveButtonText:"Save",onSubmit:a})))},Po=function(e){var t=e.model,n=e.modelName,r=e.basePath,o=void 0===r?"":r,a=e.onRequestItem,i=e.itemRequest,l=e.detailsItem,c=qe().id,u=void 0===c?"":c;return Ee((function(){a(u)}),[u]),he.createElement(ao,{loading:i.loading},he.createElement(Xt,{title:u,preset:"default",breadcrumbs:[{id:"list",text:n,link:"".concat(o,"/")},{id:"detail",text:u,link:"".concat(o,"/").concat(u)}]}),he.createElement(nn,null,l&&he.createElement(uo,{model:t,instance:l})))},$o=function(e){var t=e.updateFeature,n=void 0===t||t,r=e.addFeature,o=void 0===r||r,a=e.detailsFeature,i=void 0===a||a;return he.createElement(He,null,he.createElement(Ue,{path:"",element:he.createElement(Io,bt({},e))}),i&&he.createElement(Ue,{path:":id",element:he.createElement(Po,bt({},e))}),o&&he.createElement(Ue,{path:"add",element:he.createElement(Oo,bt({},e))}),n&&he.createElement(Ue,{path:":id/update",element:he.createElement(ko,bt({},e))}))},zo={idle:!0},Ro={loading:!0},jo={success:!0};export{Mr as Action,Nr as ActionHeader,Ir as Autocomplete,Qt as Board,Rr as BootstrapDialog,jt as Bullet,rn as CenterContainer,jr as ConfirmDialog,nn as Content,Zr as ContentPlaceholder,$r as DateRangeCalendar,zr as DateRangePicker,ft as DefaultPlaceholder,bn as Drawer,An as DrawerAppBar,zn as DrawerContent,un as DrawerContext,pn as DrawerHeader,ro as DrawerLayout,Mn as DrawerMain,Cn as DrawerProvider,$n as DrawerSection,Sn as DrawerSubheader,Xr as EnhancedRemoteTable,Yr as EnhancedTable,Hr as EnhancedTableHead,no as ExpandableAlert,Ar as FormDialog,wt as GroupValueCard,Xt as Header,ao as HeaderLayout,Jt as HeaderSubtitle,Yt as HeaderTitle,zo as IdleRequest,Wt as Label,cn as ListPanel,on as ListPanelContext,an as ListPanelContextProvider,en as LoadingArea,Ro as LoadingRequest,eo as LoremIpsumPlaceholder,Kt as Markdown,So as ModelForm,$o as ModelRouter,Vt as NotificationCenterContext,_t as NotificationCenterProvider,Dt as NotificationCenterProviderUndefinedError,uo as ObjectDetails,Gr as Placeholder,tn as QueryContainer,Vn as Select,Fn as SignIn,Kr as SkeletonCard,Qr as SkeletonGrid,jo as SuccessRequest,Lr as TabCard,Br as TabCardPanel,Bt as TabContext,qt as TabContextProvider,qr as TabPanel,Ut as TabProvider,To as TableList,Tr as TextField,sn as UndefinedProvider,gt as ValueBoolean,ht as ValueCard,Ct as ValueDatetime,mt as ValueEditButton,st as ValueEditButtons,zt as ValueItem,Zt as ValueLabel,kt as ValueRating,yt as ValueText,Rt as bulletClasses,wn as getDrawerItemColors,Pt as getFormData,It as getRandomItem,At as labelClasses,Gt as markdownDefaultOptions,Tt as newArrayWithSize,Ot as newBreakpointsCounter,fo as newInstanceFromValuesOrZeroValue,Wr as useDialog,dn as useDrawer,dt as useEditableValueDisplay,St as useGetDefaultThemeColor,ln as useListPanel,Ft as useNotificationCenter,Lt as useNotifyWhenValueChanges,Ht as useTab,$t as valueItemClasses};
24
24
  //# sourceMappingURL=index.js.map