@erpsquad/common 1.8.46 → 1.8.48
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_virtual/index/index.esm10.js +3 -3
- package/dist/_virtual/index/index.esm11.js +3 -3
- package/dist/_virtual/index/index.esm2.js +2 -4
- package/dist/_virtual/index/index.esm2.js.map +1 -1
- package/dist/_virtual/index/index.esm3.js +4 -2
- package/dist/_virtual/index/index.esm3.js.map +1 -1
- package/dist/_virtual/index/index.esm4.js +1 -1
- package/dist/_virtual/index/index.esm5.js +3 -3
- package/dist/_virtual/index/index.esm6.js +3 -3
- package/dist/_virtual/index/index.esm7.js +3 -3
- package/dist/_virtual/index/index.esm8.js +3 -3
- package/dist/_virtual/index/index.esm9.js +3 -3
- package/dist/_virtual/index/index10.js +1 -1
- package/dist/_virtual/index/index11.js +1 -1
- package/dist/_virtual/index/index2.js +1 -1
- package/dist/_virtual/index/index3.js +1 -1
- package/dist/_virtual/index/index4.js +1 -1
- package/dist/_virtual/index/index5.js +1 -1
- package/dist/_virtual/index/index6.js +1 -1
- package/dist/_virtual/index/index7.js +1 -1
- package/dist/_virtual/index/index8.js +1 -1
- package/dist/_virtual/index/index9.js +1 -1
- package/dist/assets/index.d.ts +0 -1
- package/dist/components/activityLog/activity-log/index.esm.js +104 -0
- package/dist/components/activityLog/activity-log/index.esm.js.map +1 -0
- package/dist/components/activityLog/activity-log/index.js +14 -0
- package/dist/components/activityLog/activity-log/index.js.map +1 -0
- package/dist/components/charts/barChart/barChart/index.esm.js +148 -0
- package/dist/components/charts/barChart/barChart/index.esm.js.map +1 -0
- package/dist/components/charts/barChart/barChart/index.js +2 -0
- package/dist/components/charts/barChart/barChart/index.js.map +1 -0
- package/dist/components/charts/donut-chart/donut-chart/index.esm.js.map +1 -1
- package/dist/components/charts/donut-chart/donut-chart/index.js.map +1 -1
- package/dist/components/charts/donut-chart/donut-chart.d.ts +1 -2
- package/dist/components/charts/donutChart/DonutChart/index.esm.js +97 -0
- package/dist/components/charts/donutChart/DonutChart/index.esm.js.map +1 -0
- package/dist/components/charts/donutChart/DonutChart/index.js +5 -0
- package/dist/components/charts/donutChart/DonutChart/index.js.map +1 -0
- package/dist/components/charts/index.d.ts +11 -0
- package/dist/components/charts/line-chart/area-lineChart/index.esm.js +55 -0
- package/dist/components/charts/line-chart/area-lineChart/index.esm.js.map +1 -0
- package/dist/components/charts/line-chart/area-lineChart/index.js +2 -0
- package/dist/components/charts/line-chart/area-lineChart/index.js.map +1 -0
- package/dist/components/charts/line-chart/line-chart/index.esm.js +108 -0
- package/dist/components/charts/line-chart/line-chart/index.esm.js.map +1 -0
- package/dist/components/charts/line-chart/line-chart/index.js +2 -0
- package/dist/components/charts/line-chart/line-chart/index.js.map +1 -0
- package/dist/components/confirm-modal/confirm-modal/index.esm.js.map +1 -1
- package/dist/components/confirm-modal/confirm-modal/index.js.map +1 -1
- package/dist/components/confirm-modal/confirm-modal.d.ts +1 -2
- package/dist/components/confirm-modal/index.d.ts +1 -0
- package/dist/components/editor/custom-editor/index.esm.js +96 -67
- package/dist/components/editor/custom-editor/index.esm.js.map +1 -1
- package/dist/components/editor/custom-editor/index.js +3 -3
- package/dist/components/editor/custom-editor/index.js.map +1 -1
- package/dist/components/editor/custom-editor.d.ts +12 -8
- package/dist/components/footer/footer/index.esm.js +1 -1
- package/dist/components/footer/footer/index.js +2 -2
- package/dist/components/footer/footer/index.js.map +1 -1
- package/dist/components/form-control/form-parser/form-parser/index.esm.js +1 -1
- package/dist/components/form-control/form-parser/form-parser/index.js +4 -4
- package/dist/components/form-control/form-parser/form-parser/index.js.map +1 -1
- package/dist/components/grid/grid-card/grid-card/index.esm.js +4 -2
- package/dist/components/grid/grid-card/grid-card/index.esm.js.map +1 -1
- package/dist/components/grid/grid-card/grid-card/index.js +10 -11
- package/dist/components/grid/grid-card/grid-card/index.js.map +1 -1
- package/dist/components/grid/grid-card/grid-card.d.ts +10 -1
- package/dist/components/index.d.ts +294 -98
- package/dist/components/index.esm.js +582 -193
- package/dist/components/index.esm.js.map +1 -1
- package/dist/components/index.js +1 -1
- package/dist/components/inventory-reports-title-bar/component/reportFilter.d.ts +3 -2
- package/dist/components/inventory-reports-title-bar/inventory-reports-title-bar/index.esm.js +1 -1
- package/dist/components/inventory-reports-title-bar/inventory-reports-title-bar/index.js +1 -1
- package/dist/components/inventory-reports-title-bar/inventory-reports-title-bar/index.js.map +1 -1
- package/dist/components/inventory-reports-title-bar/redux/reducer/index.esm.js +0 -2
- package/dist/components/inventory-reports-title-bar/redux/reducer/index.esm.js.map +1 -1
- package/dist/components/inventory-reports-title-bar/redux/reducer/index.js +1 -1
- package/dist/components/inventory-reports-title-bar/redux/reducer/index.js.map +1 -1
- package/dist/components/list/list/index.esm.js +3 -2
- package/dist/components/list/list/index.esm.js.map +1 -1
- package/dist/components/list/list/index.js +2 -2
- package/dist/components/list/list/index.js.map +1 -1
- package/dist/components/list/list.d.ts +2 -1
- package/dist/components/listing/listing/index.esm.js +1 -1
- package/dist/components/listing/listing/index.js +1 -1
- package/dist/components/listing/listing/index.js.map +1 -1
- package/dist/components/material-table/aggregation-fns/index/index.esm.js +10 -0
- package/dist/components/material-table/aggregation-fns/index/index.esm.js.map +1 -1
- package/dist/components/material-table/aggregation-fns/index/index.js +1 -1
- package/dist/components/material-table/aggregation-fns/index/index.js.map +1 -1
- package/dist/components/material-table/components/number-aggregation/index.esm.js +134 -0
- package/dist/components/material-table/components/number-aggregation/index.esm.js.map +1 -0
- package/dist/components/material-table/components/number-aggregation/index.js +5 -0
- package/dist/components/material-table/components/number-aggregation/index.js.map +1 -0
- package/dist/components/module-button/module-button/index.esm.js +3 -2
- package/dist/components/module-button/module-button/index.esm.js.map +1 -1
- package/dist/components/module-button/module-button/index.js +4 -4
- package/dist/components/module-button/module-button/index.js.map +1 -1
- package/dist/components/module-button/module-button.d.ts +10 -1
- package/dist/components/mulitline/multiline/index.esm.js +3 -2
- package/dist/components/mulitline/multiline/index.esm.js.map +1 -1
- package/dist/components/mulitline/multiline/index.js +9 -9
- package/dist/components/mulitline/multiline/index.js.map +1 -1
- package/dist/components/mulitline/multiline.d.ts +2 -2
- package/dist/components/page-navigator/page-navigator/index.esm.js +4 -3
- package/dist/components/page-navigator/page-navigator/index.esm.js.map +1 -1
- package/dist/components/page-navigator/page-navigator/index.js +5 -5
- package/dist/components/page-navigator/page-navigator/index.js.map +1 -1
- package/dist/components/page-navigator/page-navigator.d.ts +3 -3
- package/dist/components/parties-modal/parties-modal/index.esm.js +4 -3
- package/dist/components/parties-modal/parties-modal/index.esm.js.map +1 -1
- package/dist/components/parties-modal/parties-modal/index.js +13 -13
- package/dist/components/parties-modal/parties-modal/index.js.map +1 -1
- package/dist/components/parties-modal/parties-modal.d.ts +3 -3
- package/dist/components/reports-title-bar/report-buttons/report-buttons/index.esm.js +60 -0
- package/dist/components/reports-title-bar/report-buttons/report-buttons/index.esm.js.map +1 -0
- package/dist/components/reports-title-bar/report-buttons/report-buttons/index.js +2 -0
- package/dist/components/reports-title-bar/report-buttons/report-buttons/index.js.map +1 -0
- package/dist/components/reports-title-bar/reports-title-bar/index.esm.js +736 -0
- package/dist/components/reports-title-bar/reports-title-bar/index.esm.js.map +1 -0
- package/dist/components/reports-title-bar/reports-title-bar/index.js +39 -0
- package/dist/components/reports-title-bar/reports-title-bar/index.js.map +1 -0
- package/dist/components/rfq-response/item-response-details/index.esm.js +40 -48
- package/dist/components/rfq-response/item-response-details/index.esm.js.map +1 -1
- package/dist/components/rfq-response/item-response-details/index.js +4 -4
- package/dist/components/rfq-response/item-response-details/index.js.map +1 -1
- package/dist/components/rfq-response/item-response-details.d.ts +2 -1
- package/dist/components/schedule-report/utils/common/index.esm.js +1 -1
- package/dist/components/select/controller/chip-or-placeholder/index.esm.js +25 -0
- package/dist/components/select/controller/chip-or-placeholder/index.esm.js.map +1 -0
- package/dist/components/select/controller/chip-or-placeholder/index.js +2 -0
- package/dist/components/select/controller/chip-or-placeholder/index.js.map +1 -0
- package/dist/components/select/controller/controller-select/index.esm.js +165 -0
- package/dist/components/select/controller/controller-select/index.esm.js.map +1 -0
- package/dist/components/select/controller/controller-select/index.js +10 -0
- package/dist/components/select/controller/controller-select/index.js.map +1 -0
- package/dist/components/tab-bar-ui/tab-bar-ui/index.esm.js +4 -10
- package/dist/components/tab-bar-ui/tab-bar-ui/index.esm.js.map +1 -1
- package/dist/components/tab-bar-ui/tab-bar-ui/index.js +3 -3
- package/dist/components/tab-bar-ui/tab-bar-ui/index.js.map +1 -1
- package/dist/components/tab-bar-ui/tab-bar-ui.d.ts +3 -3
- package/dist/components/tabs/tabs/index.esm.js +3 -2
- package/dist/components/tabs/tabs/index.esm.js.map +1 -1
- package/dist/components/tabs/tabs/index.js +3 -3
- package/dist/components/tabs/tabs/index.js.map +1 -1
- package/dist/components/tabs/tabs.d.ts +2 -2
- package/dist/hooks/index.esm.js +4 -4
- package/dist/hooks/index.js +1 -1
- package/dist/hooks/use-translations/index.esm.js +4 -3
- package/dist/hooks/use-translations/index.esm.js.map +1 -1
- package/dist/hooks/use-translations/index.js +1 -1
- package/dist/hooks/use-translations/index.js.map +1 -1
- package/dist/hooks/use-translations.d.ts +2 -1
- package/dist/hooks/useCheckSkuAndName/index.esm.js +5 -4
- package/dist/hooks/useCheckSkuAndName/index.esm.js.map +1 -1
- package/dist/hooks/useCheckSkuAndName/index.js +1 -1
- package/dist/hooks/useCheckSkuAndName/index.js.map +1 -1
- package/dist/hooks/useCheckSkuAndName.d.ts +4 -2
- package/dist/index.esm.js +696 -268
- package/dist/index.esm.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/layout/fullScreen/fullScreen/index.esm.js +5 -3
- package/dist/layout/fullScreen/fullScreen/index.esm.js.map +1 -1
- package/dist/layout/fullScreen/fullScreen/index.js +3 -3
- package/dist/layout/fullScreen/fullScreen/index.js.map +1 -1
- package/dist/layout/fullScreen/fullScreen.d.ts +5 -1
- package/dist/layout/index.esm.js +4 -4
- package/dist/layout/index.js +1 -1
- package/dist/layout/sidebarScreen/sidebarScreen/index.esm.js +72 -50
- package/dist/layout/sidebarScreen/sidebarScreen/index.esm.js.map +1 -1
- package/dist/layout/sidebarScreen/sidebarScreen/index.js +4 -4
- package/dist/layout/sidebarScreen/sidebarScreen/index.js.map +1 -1
- package/dist/layout/sidebarScreen/sidebarScreen.d.ts +3 -3
- package/dist/node_modules/@asseinfo/react-kanban/dist/index/index.esm.js +1 -1
- package/dist/node_modules/@asseinfo/react-kanban/dist/index/index.js +1 -1
- package/dist/node_modules/@mui/icons-material/esm/Remove/index.esm.js +9 -0
- package/dist/node_modules/@mui/icons-material/esm/Remove/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/icons-material/esm/Remove/index.js +2 -0
- package/dist/node_modules/@mui/icons-material/esm/Remove/index.js.map +1 -0
- package/dist/node_modules/@mui/icons-material/utils/createSvgIcon/index.esm.js +1 -1
- package/dist/node_modules/@mui/icons-material/utils/createSvgIcon/index.js +1 -1
- package/dist/node_modules/@mui/lab/TimelineItem/TimelineItem/index.esm.js +1 -1
- package/dist/node_modules/@mui/lab/TimelineItem/TimelineItem/index.js +2 -2
- package/dist/node_modules/@mui/material/AccordionActions/AccordionActions/index.esm.js +95 -0
- package/dist/node_modules/@mui/material/AccordionActions/AccordionActions/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/AccordionActions/AccordionActions/index.js +3 -0
- package/dist/node_modules/@mui/material/AccordionActions/AccordionActions/index.js.map +1 -0
- package/dist/node_modules/@mui/material/AccordionActions/accordionActionsClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/AccordionActions/accordionActionsClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/AccordionActions/accordionActionsClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/AccordionActions/accordionActionsClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Avatar/avatarClasses/index.esm.js +3 -2
- package/dist/node_modules/@mui/material/Avatar/avatarClasses/index.esm.js.map +1 -1
- package/dist/node_modules/@mui/material/Avatar/avatarClasses/index.js +1 -1
- package/dist/node_modules/@mui/material/Avatar/avatarClasses/index.js.map +1 -1
- package/dist/node_modules/@mui/material/AvatarGroup/AvatarGroup/index.esm.js +201 -0
- package/dist/node_modules/@mui/material/AvatarGroup/AvatarGroup/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/AvatarGroup/AvatarGroup/index.js +3 -0
- package/dist/node_modules/@mui/material/AvatarGroup/AvatarGroup/index.js.map +1 -0
- package/dist/node_modules/@mui/material/AvatarGroup/avatarGroupClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/AvatarGroup/avatarGroupClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/AvatarGroup/avatarGroupClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/AvatarGroup/avatarGroupClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/BottomNavigation/BottomNavigation/index.esm.js +125 -0
- package/dist/node_modules/@mui/material/BottomNavigation/BottomNavigation/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/BottomNavigation/BottomNavigation/index.js +4 -0
- package/dist/node_modules/@mui/material/BottomNavigation/BottomNavigation/index.js.map +1 -0
- package/dist/node_modules/@mui/material/BottomNavigation/bottomNavigationClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/BottomNavigation/bottomNavigationClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/BottomNavigation/bottomNavigationClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/BottomNavigation/bottomNavigationClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/BottomNavigationAction/BottomNavigationAction/index.esm.js +170 -0
- package/dist/node_modules/@mui/material/BottomNavigationAction/BottomNavigationAction/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/BottomNavigationAction/BottomNavigationAction/index.js +3 -0
- package/dist/node_modules/@mui/material/BottomNavigationAction/BottomNavigationAction/index.js.map +1 -0
- package/dist/node_modules/@mui/material/BottomNavigationAction/bottomNavigationActionClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/BottomNavigationAction/bottomNavigationActionClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/BottomNavigationAction/bottomNavigationActionClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/BottomNavigationAction/bottomNavigationActionClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/CardActionArea/CardActionArea/index.esm.js +120 -0
- package/dist/node_modules/@mui/material/CardActionArea/CardActionArea/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/CardActionArea/CardActionArea/index.js +3 -0
- package/dist/node_modules/@mui/material/CardActionArea/CardActionArea/index.js.map +1 -0
- package/dist/node_modules/@mui/material/CardActionArea/cardActionAreaClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/CardActionArea/cardActionAreaClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/CardActionArea/cardActionAreaClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/CardActionArea/cardActionAreaClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/CardActions/CardActions/index.esm.js +92 -0
- package/dist/node_modules/@mui/material/CardActions/CardActions/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/CardActions/CardActions/index.js +3 -0
- package/dist/node_modules/@mui/material/CardActions/CardActions/index.js.map +1 -0
- package/dist/node_modules/@mui/material/CardActions/cardActionsClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/CardActions/cardActionsClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/CardActions/cardActionsClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/CardActions/cardActionsClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/CardHeader/CardHeader/index.esm.js +196 -0
- package/dist/node_modules/@mui/material/CardHeader/CardHeader/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/CardHeader/CardHeader/index.js +2 -0
- package/dist/node_modules/@mui/material/CardHeader/CardHeader/index.js.map +1 -0
- package/dist/node_modules/@mui/material/CardHeader/cardHeaderClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/CardHeader/cardHeaderClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/CardHeader/cardHeaderClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/CardHeader/cardHeaderClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/DialogContentText/DialogContentText/index.esm.js +76 -0
- package/dist/node_modules/@mui/material/DialogContentText/DialogContentText/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/DialogContentText/DialogContentText/index.js +3 -0
- package/dist/node_modules/@mui/material/DialogContentText/DialogContentText/index.js.map +1 -0
- package/dist/node_modules/@mui/material/DialogContentText/dialogContentTextClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/DialogContentText/dialogContentTextClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/DialogContentText/dialogContentTextClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/DialogContentText/dialogContentTextClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Fab/Fab/index.esm.js +231 -0
- package/dist/node_modules/@mui/material/Fab/Fab/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Fab/Fab/index.js +3 -0
- package/dist/node_modules/@mui/material/Fab/Fab/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Fab/fabClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/Fab/fabClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Fab/fabClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/Fab/fabClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Hidden/Hidden/index.esm.js +135 -0
- package/dist/node_modules/@mui/material/Hidden/Hidden/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Hidden/Hidden/index.js +2 -0
- package/dist/node_modules/@mui/material/Hidden/Hidden/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Hidden/HiddenCss/index.esm.js +176 -0
- package/dist/node_modules/@mui/material/Hidden/HiddenCss/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Hidden/HiddenCss/index.js +3 -0
- package/dist/node_modules/@mui/material/Hidden/HiddenCss/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Hidden/HiddenJs/index.esm.js +119 -0
- package/dist/node_modules/@mui/material/Hidden/HiddenJs/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Hidden/HiddenJs/index.js +2 -0
- package/dist/node_modules/@mui/material/Hidden/HiddenJs/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Hidden/hiddenCssClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/Hidden/hiddenCssClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Hidden/hiddenCssClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/Hidden/hiddenCssClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Hidden/withWidth/index.esm.js +92 -0
- package/dist/node_modules/@mui/material/Hidden/withWidth/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Hidden/withWidth/index.js +2 -0
- package/dist/node_modules/@mui/material/Hidden/withWidth/index.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageList/ImageList/index.esm.js +156 -0
- package/dist/node_modules/@mui/material/ImageList/ImageList/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageList/ImageList/index.js +3 -0
- package/dist/node_modules/@mui/material/ImageList/ImageList/index.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageList/ImageListContext/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/ImageList/ImageListContext/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageList/ImageListContext/index.js +2 -0
- package/dist/node_modules/@mui/material/ImageList/ImageListContext/index.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageList/imageListClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/ImageList/imageListClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageList/imageListClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/ImageList/imageListClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageListItem/ImageListItem/index.esm.js +173 -0
- package/dist/node_modules/@mui/material/ImageListItem/ImageListItem/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageListItem/ImageListItem/index.js +3 -0
- package/dist/node_modules/@mui/material/ImageListItem/ImageListItem/index.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageListItem/imageListItemClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/ImageListItem/imageListItemClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageListItem/imageListItemClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/ImageListItem/imageListItemClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageListItemBar/ImageListItemBar/index.esm.js +222 -0
- package/dist/node_modules/@mui/material/ImageListItemBar/ImageListItemBar/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageListItemBar/ImageListItemBar/index.js +3 -0
- package/dist/node_modules/@mui/material/ImageListItemBar/ImageListItemBar/index.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageListItemBar/imageListItemBarClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/ImageListItemBar/imageListItemBarClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/ImageListItemBar/imageListItemBarClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/ImageListItemBar/imageListItemBarClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/MobileStepper/MobileStepper/index.esm.js +216 -0
- package/dist/node_modules/@mui/material/MobileStepper/MobileStepper/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/MobileStepper/MobileStepper/index.js +3 -0
- package/dist/node_modules/@mui/material/MobileStepper/MobileStepper/index.js.map +1 -0
- package/dist/node_modules/@mui/material/MobileStepper/mobileStepperClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/MobileStepper/mobileStepperClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/MobileStepper/mobileStepperClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/MobileStepper/mobileStepperClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/NativeSelect/NativeSelect/index.esm.js +126 -0
- package/dist/node_modules/@mui/material/NativeSelect/NativeSelect/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/NativeSelect/NativeSelect/index.js +3 -0
- package/dist/node_modules/@mui/material/NativeSelect/NativeSelect/index.js.map +1 -0
- package/dist/node_modules/@mui/material/NativeSelect/nativeSelectClasses/index.esm.js +1 -1
- package/dist/node_modules/@mui/material/NativeSelect/nativeSelectClasses/index.js +1 -1
- package/dist/node_modules/@mui/material/NativeSelect/nativeSelectClasses/index.js.map +1 -1
- package/dist/node_modules/@mui/material/NoSsr/NoSsr/index.esm.js +55 -0
- package/dist/node_modules/@mui/material/NoSsr/NoSsr/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/NoSsr/NoSsr/index.js +2 -0
- package/dist/node_modules/@mui/material/NoSsr/NoSsr/index.js.map +1 -0
- package/dist/node_modules/@mui/material/OutlinedInput/outlinedInputClasses/index.esm.js +1 -1
- package/dist/node_modules/@mui/material/OutlinedInput/outlinedInputClasses/index.js +1 -1
- package/dist/node_modules/@mui/material/Popover/Popover/index.esm.js +1 -1
- package/dist/node_modules/@mui/material/Popover/Popover/index.js +1 -1
- package/dist/node_modules/@mui/material/Rating/Rating/index.esm.js +638 -0
- package/dist/node_modules/@mui/material/Rating/Rating/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Rating/Rating/index.js +7 -0
- package/dist/node_modules/@mui/material/Rating/Rating/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Rating/ratingClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/Rating/ratingClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Rating/ratingClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/Rating/ratingClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/ScopedCssBaseline/ScopedCssBaseline/index.esm.js +105 -0
- package/dist/node_modules/@mui/material/ScopedCssBaseline/ScopedCssBaseline/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/ScopedCssBaseline/ScopedCssBaseline/index.js +3 -0
- package/dist/node_modules/@mui/material/ScopedCssBaseline/ScopedCssBaseline/index.js.map +1 -0
- package/dist/node_modules/@mui/material/ScopedCssBaseline/scopedCssBaselineClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/ScopedCssBaseline/scopedCssBaselineClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/ScopedCssBaseline/scopedCssBaselineClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/ScopedCssBaseline/scopedCssBaselineClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Snackbar/Snackbar/index.esm.js +1 -1
- package/dist/node_modules/@mui/material/Snackbar/Snackbar/index.js +1 -1
- package/dist/node_modules/@mui/material/SpeedDial/SpeedDial/index.esm.js +453 -0
- package/dist/node_modules/@mui/material/SpeedDial/SpeedDial/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/SpeedDial/SpeedDial/index.js +4 -0
- package/dist/node_modules/@mui/material/SpeedDial/SpeedDial/index.js.map +1 -0
- package/dist/node_modules/@mui/material/SpeedDial/speedDialClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/SpeedDial/speedDialClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/SpeedDial/speedDialClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/SpeedDial/speedDialClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/SpeedDialAction/SpeedDialAction/index.esm.js +245 -0
- package/dist/node_modules/@mui/material/SpeedDialAction/SpeedDialAction/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/SpeedDialAction/SpeedDialAction/index.js +2 -0
- package/dist/node_modules/@mui/material/SpeedDialAction/SpeedDialAction/index.js.map +1 -0
- package/dist/node_modules/@mui/material/SpeedDialAction/speedDialActionClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/SpeedDialAction/speedDialActionClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/SpeedDialAction/speedDialActionClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/SpeedDialAction/speedDialActionClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/SpeedDialIcon/SpeedDialIcon/index.esm.js +137 -0
- package/dist/node_modules/@mui/material/SpeedDialIcon/SpeedDialIcon/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/SpeedDialIcon/SpeedDialIcon/index.js +4 -0
- package/dist/node_modules/@mui/material/SpeedDialIcon/SpeedDialIcon/index.js.map +1 -0
- package/dist/node_modules/@mui/material/SpeedDialIcon/speedDialIconClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/SpeedDialIcon/speedDialIconClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/SpeedDialIcon/speedDialIconClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/SpeedDialIcon/speedDialIconClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Step/Step/index.esm.js +169 -0
- package/dist/node_modules/@mui/material/Step/Step/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Step/Step/index.js +3 -0
- package/dist/node_modules/@mui/material/Step/Step/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Step/StepContext/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/Step/StepContext/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Step/StepContext/index.js +2 -0
- package/dist/node_modules/@mui/material/Step/StepContext/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Step/stepClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/Step/stepClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Step/stepClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/Step/stepClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/StepButton/StepButton/index.esm.js +132 -0
- package/dist/node_modules/@mui/material/StepButton/StepButton/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/StepButton/StepButton/index.js +3 -0
- package/dist/node_modules/@mui/material/StepButton/StepButton/index.js.map +1 -0
- package/dist/node_modules/@mui/material/StepButton/stepButtonClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/StepButton/stepButtonClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/StepButton/stepButtonClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/StepButton/stepButtonClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/StepConnector/StepConnector/index.esm.js +136 -0
- package/dist/node_modules/@mui/material/StepConnector/StepConnector/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/StepConnector/StepConnector/index.js +3 -0
- package/dist/node_modules/@mui/material/StepConnector/StepConnector/index.js.map +1 -0
- package/dist/node_modules/@mui/material/StepConnector/stepConnectorClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/StepConnector/stepConnectorClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/StepConnector/stepConnectorClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/StepConnector/stepConnectorClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/StepContent/StepContent/index.esm.js +152 -0
- package/dist/node_modules/@mui/material/StepContent/StepContent/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/StepContent/StepContent/index.js +2 -0
- package/dist/node_modules/@mui/material/StepContent/StepContent/index.js.map +1 -0
- package/dist/node_modules/@mui/material/StepContent/stepContentClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/StepContent/stepContentClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/StepContent/stepContentClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/StepContent/stepContentClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/StepIcon/StepIcon/index.esm.js +161 -0
- package/dist/node_modules/@mui/material/StepIcon/StepIcon/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/StepIcon/StepIcon/index.js +2 -0
- package/dist/node_modules/@mui/material/StepIcon/StepIcon/index.js.map +1 -0
- package/dist/node_modules/@mui/material/StepIcon/stepIconClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/StepIcon/stepIconClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/StepIcon/stepIconClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/StepIcon/stepIconClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/StepLabel/StepLabel/index.esm.js +239 -0
- package/dist/node_modules/@mui/material/StepLabel/StepLabel/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/StepLabel/StepLabel/index.js +3 -0
- package/dist/node_modules/@mui/material/StepLabel/StepLabel/index.js.map +1 -0
- package/dist/node_modules/@mui/material/StepLabel/stepLabelClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/StepLabel/stepLabelClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/StepLabel/stepLabelClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/StepLabel/stepLabelClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Stepper/Stepper/index.esm.js +155 -0
- package/dist/node_modules/@mui/material/Stepper/Stepper/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Stepper/Stepper/index.js +3 -0
- package/dist/node_modules/@mui/material/Stepper/Stepper/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Stepper/StepperContext/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/Stepper/StepperContext/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Stepper/StepperContext/index.js +2 -0
- package/dist/node_modules/@mui/material/Stepper/StepperContext/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Stepper/stepperClasses/index.esm.js +10 -0
- package/dist/node_modules/@mui/material/Stepper/stepperClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Stepper/stepperClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/Stepper/stepperClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/SwipeableDrawer/SwipeArea/index.esm.js +82 -0
- package/dist/node_modules/@mui/material/SwipeableDrawer/SwipeArea/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/SwipeableDrawer/SwipeArea/index.js +3 -0
- package/dist/node_modules/@mui/material/SwipeableDrawer/SwipeArea/index.js.map +1 -0
- package/dist/node_modules/@mui/material/SwipeableDrawer/SwipeableDrawer/index.esm.js +538 -0
- package/dist/node_modules/@mui/material/SwipeableDrawer/SwipeableDrawer/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/SwipeableDrawer/SwipeableDrawer/index.js +2 -0
- package/dist/node_modules/@mui/material/SwipeableDrawer/SwipeableDrawer/index.js.map +1 -0
- package/dist/node_modules/@mui/material/TablePagination/TablePagination/index.esm.js +443 -0
- package/dist/node_modules/@mui/material/TablePagination/TablePagination/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/TablePagination/TablePagination/index.js +3 -0
- package/dist/node_modules/@mui/material/TablePagination/TablePagination/index.js.map +1 -0
- package/dist/node_modules/@mui/material/TablePagination/TablePaginationActions/index.esm.js +179 -0
- package/dist/node_modules/@mui/material/TablePagination/TablePaginationActions/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/TablePagination/TablePaginationActions/index.js +3 -0
- package/dist/node_modules/@mui/material/TablePagination/TablePaginationActions/index.js.map +1 -0
- package/dist/node_modules/@mui/material/TablePagination/tablePaginationClasses/index.esm.js +11 -0
- package/dist/node_modules/@mui/material/TablePagination/tablePaginationClasses/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/TablePagination/tablePaginationClasses/index.js +2 -0
- package/dist/node_modules/@mui/material/TablePagination/tablePaginationClasses/index.js.map +1 -0
- package/dist/node_modules/@mui/material/Tabs/Tabs/index.esm.js +1 -1
- package/dist/node_modules/@mui/material/Tabs/Tabs/index.js +1 -1
- package/dist/node_modules/@mui/material/Zoom/Zoom/index.esm.js +196 -0
- package/dist/node_modules/@mui/material/Zoom/Zoom/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/Zoom/Zoom/index.js +3 -0
- package/dist/node_modules/@mui/material/Zoom/Zoom/index.js.map +1 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Add/index.esm.js +9 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Add/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Add/index.js +2 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Add/index.js.map +1 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/CheckCircle/index.esm.js +9 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/CheckCircle/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/CheckCircle/index.js +2 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/CheckCircle/index.js.map +1 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Star/index.esm.js +9 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Star/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Star/index.js +2 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Star/index.js.map +1 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/StarBorder/index.esm.js +9 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/StarBorder/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/StarBorder/index.js +2 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/StarBorder/index.js.map +1 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Warning/index.esm.js +9 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Warning/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Warning/index.js +2 -0
- package/dist/node_modules/@mui/material/internal/svg-icons/Warning/index.js.map +1 -0
- package/dist/node_modules/@mui/material/useScrollTrigger/useScrollTrigger/index.esm.js +51 -0
- package/dist/node_modules/@mui/material/useScrollTrigger/useScrollTrigger/index.esm.js.map +1 -0
- package/dist/node_modules/@mui/material/useScrollTrigger/useScrollTrigger/index.js +2 -0
- package/dist/node_modules/@mui/material/useScrollTrigger/useScrollTrigger/index.js.map +1 -0
- package/dist/node_modules/@mui/system/colorManipulator/index.esm.js +2 -2
- package/dist/node_modules/@mui/system/colorManipulator/index.js +1 -1
- package/dist/node_modules/@mui/system/colorManipulator/index.js.map +1 -1
- package/dist/node_modules/@mui/system/createStyled/index.esm.js +6 -6
- package/dist/node_modules/@mui/system/createStyled/index.js +1 -1
- package/dist/node_modules/@mui/system/createStyled/index.js.map +1 -1
- package/dist/node_modules/@mui/system/esm/Stack/createStack/index.esm.js +1 -1
- package/dist/node_modules/@mui/system/esm/Stack/createStack/index.js +2 -2
- package/dist/node_modules/@mui/system/useThemeWithoutDefault/index.esm.js +1 -1
- package/dist/node_modules/@mui/system/useThemeWithoutDefault/index.js +1 -1
- package/dist/node_modules/d3-axis/src/axis/index.esm.js +5 -1
- package/dist/node_modules/d3-axis/src/axis/index.esm.js.map +1 -1
- package/dist/node_modules/d3-axis/src/axis/index.js +1 -1
- package/dist/node_modules/d3-axis/src/axis/index.js.map +1 -1
- package/dist/redux/hooks/index.esm.js +1 -1
- package/dist/src/assets/index.d.ts +0 -1
- package/dist/src/components/charts/donut-chart/donut-chart.d.ts +1 -2
- package/dist/src/components/charts/index.d.ts +11 -0
- package/dist/src/components/confirm-modal/confirm-modal.d.ts +1 -2
- package/dist/src/components/confirm-modal/index.d.ts +1 -0
- package/dist/src/components/editor/custom-editor.d.ts +12 -8
- package/dist/src/components/grid/grid-card/grid-card.d.ts +10 -1
- package/dist/src/components/index.d.ts +229 -94
- package/dist/src/components/inventory-reports-title-bar/component/reportFilter.d.ts +3 -2
- package/dist/src/components/list/list.d.ts +2 -1
- package/dist/src/components/module-button/module-button.d.ts +10 -1
- package/dist/src/components/mulitline/multiline.d.ts +2 -2
- package/dist/src/components/page-navigator/page-navigator.d.ts +3 -3
- package/dist/src/components/parties-modal/parties-modal.d.ts +3 -3
- package/dist/src/components/rfq-response/item-response-details.d.ts +2 -1
- package/dist/src/components/tab-bar-ui/tab-bar-ui.d.ts +3 -3
- package/dist/src/components/tabs/tabs.d.ts +2 -2
- package/dist/src/hooks/use-translations.d.ts +2 -1
- package/dist/src/hooks/useCheckSkuAndName.d.ts +4 -2
- package/dist/src/layout/fullScreen/fullScreen.d.ts +5 -1
- package/dist/src/layout/sidebarScreen/sidebarScreen.d.ts +3 -3
- package/dist/src/views/afterAuth/dashboard/dashboard.d.ts +2 -1
- package/dist/src/views/afterAuth/index.d.ts +1 -0
- package/dist/src/views/beforeAuth/index.d.ts +0 -1
- package/dist/src/views/form-builder/element-edit-forms/column-width.d.ts +5 -3
- package/dist/src/views/index.d.ts +1 -0
- package/dist/style.css +77 -71
- package/dist/utils/common/index.esm.js +1 -1
- package/dist/views/afterAuth/dashboard/dashboard/index.esm.js +5 -4
- package/dist/views/afterAuth/dashboard/dashboard/index.esm.js.map +1 -1
- package/dist/views/afterAuth/dashboard/dashboard/index.js +3 -3
- package/dist/views/afterAuth/dashboard/dashboard/index.js.map +1 -1
- package/dist/views/afterAuth/dashboard/dashboard.d.ts +2 -1
- package/dist/views/afterAuth/dashboard/redux/reducer/index.esm.js +0 -6
- package/dist/views/afterAuth/dashboard/redux/reducer/index.esm.js.map +1 -1
- package/dist/views/afterAuth/dashboard/redux/reducer/index.js +1 -1
- package/dist/views/afterAuth/dashboard/redux/reducer/index.js.map +1 -1
- package/dist/views/afterAuth/index.d.ts +1 -0
- package/dist/views/afterAuth/page-view/page-view/index.esm.js +101 -0
- package/dist/views/afterAuth/page-view/page-view/index.esm.js.map +1 -0
- package/dist/views/afterAuth/page-view/page-view/index.js +6 -0
- package/dist/views/afterAuth/page-view/page-view/index.js.map +1 -0
- package/dist/views/afterAuth/page-view/redux/actionCreator/index.esm.js +13 -0
- package/dist/views/afterAuth/page-view/redux/actionCreator/index.esm.js.map +1 -0
- package/dist/views/afterAuth/page-view/redux/actionCreator/index.js +2 -0
- package/dist/views/afterAuth/page-view/redux/actionCreator/index.js.map +1 -0
- package/dist/views/afterAuth/page-view/redux/reducer/index.esm.js +63 -0
- package/dist/views/afterAuth/page-view/redux/reducer/index.esm.js.map +1 -0
- package/dist/views/afterAuth/page-view/redux/reducer/index.js +2 -0
- package/dist/views/afterAuth/page-view/redux/reducer/index.js.map +1 -0
- package/dist/views/afterAuth/page-view/redux/state/index.esm.js +31 -0
- package/dist/views/afterAuth/page-view/redux/state/index.esm.js.map +1 -0
- package/dist/views/afterAuth/page-view/redux/state/index.js +2 -0
- package/dist/views/afterAuth/page-view/redux/state/index.js.map +1 -0
- package/dist/views/afterAuth/page-view/utils/default-data/index.esm.js +137 -0
- package/dist/views/afterAuth/page-view/utils/default-data/index.esm.js.map +1 -0
- package/dist/views/afterAuth/page-view/utils/default-data/index.js +2 -0
- package/dist/views/afterAuth/page-view/utils/default-data/index.js.map +1 -0
- package/dist/views/afterAuth/page-view/utils/local-data/index.esm.js +137 -0
- package/dist/views/afterAuth/page-view/utils/local-data/index.esm.js.map +1 -0
- package/dist/views/afterAuth/page-view/utils/local-data/index.js +2 -0
- package/dist/views/afterAuth/page-view/utils/local-data/index.js.map +1 -0
- package/dist/views/beforeAuth/index.d.ts +0 -1
- package/dist/views/form-builder/custom-form/index.esm.js +1151 -0
- package/dist/views/form-builder/custom-form/index.esm.js.map +1 -0
- package/dist/views/form-builder/custom-form/index.js +30 -0
- package/dist/views/form-builder/custom-form/index.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/checkbox/index.esm.js +327 -0
- package/dist/views/form-builder/element-edit-forms/checkbox/index.esm.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/checkbox/index.js +30 -0
- package/dist/views/form-builder/element-edit-forms/checkbox/index.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/column-width/index.esm.js +93 -0
- package/dist/views/form-builder/element-edit-forms/column-width/index.esm.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/column-width/index.js +4 -0
- package/dist/views/form-builder/element-edit-forms/column-width/index.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/column-width.d.ts +5 -3
- package/dist/views/form-builder/element-edit-forms/field-select/index.esm.js +89 -0
- package/dist/views/form-builder/element-edit-forms/field-select/index.esm.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/field-select/index.js +3 -0
- package/dist/views/form-builder/element-edit-forms/field-select/index.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/section/index.esm.js +222 -0
- package/dist/views/form-builder/element-edit-forms/section/index.esm.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/section/index.js +15 -0
- package/dist/views/form-builder/element-edit-forms/section/index.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/select/index.esm.js +318 -0
- package/dist/views/form-builder/element-edit-forms/select/index.esm.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/select/index.js +25 -0
- package/dist/views/form-builder/element-edit-forms/select/index.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/table-form/index.esm.js +111 -0
- package/dist/views/form-builder/element-edit-forms/table-form/index.esm.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/table-form/index.js +5 -0
- package/dist/views/form-builder/element-edit-forms/table-form/index.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/text/index.esm.js +559 -0
- package/dist/views/form-builder/element-edit-forms/text/index.esm.js.map +1 -0
- package/dist/views/form-builder/element-edit-forms/text/index.js +31 -0
- package/dist/views/form-builder/element-edit-forms/text/index.js.map +1 -0
- package/dist/views/form-builder/field_properties/index.esm.js +216 -0
- package/dist/views/form-builder/field_properties/index.esm.js.map +1 -0
- package/dist/views/form-builder/field_properties/index.js +2 -0
- package/dist/views/form-builder/field_properties/index.js.map +1 -0
- package/dist/views/form-builder/form-fields/index.esm.js +355 -0
- package/dist/views/form-builder/form-fields/index.esm.js.map +1 -0
- package/dist/views/form-builder/form-fields/index.js +24 -0
- package/dist/views/form-builder/form-fields/index.js.map +1 -0
- package/dist/views/form-builder/redux/actionCreator/index.esm.js +1 -1
- package/dist/views/form-builder/redux/reducer/index.esm.js +6 -1
- package/dist/views/form-builder/redux/reducer/index.esm.js.map +1 -1
- package/dist/views/form-builder/redux/reducer/index.js +1 -1
- package/dist/views/form-builder/redux/reducer/index.js.map +1 -1
- package/dist/views/form-builder/utils/common/index.esm.js +285 -0
- package/dist/views/form-builder/utils/common/index.esm.js.map +1 -0
- package/dist/views/form-builder/utils/common/index.js +2 -0
- package/dist/views/form-builder/utils/common/index.js.map +1 -0
- package/dist/views/index.d.ts +1 -0
- package/dist/views/index.esm.js +94 -49
- package/dist/views/index.esm.js.map +1 -1
- package/dist/views/index.js +1 -1
- package/package.json +2 -1
- package/dist/components/examples/FlexibleReduxExample/index.esm.js +0 -154
- package/dist/components/examples/FlexibleReduxExample/index.esm.js.map +0 -1
- package/dist/components/examples/FlexibleReduxExample/index.js +0 -19
- package/dist/components/examples/FlexibleReduxExample/index.js.map +0 -1
- package/dist/components/footer/index.esm.js +0 -71
- package/dist/components/footer/index.esm.js.map +0 -1
- package/dist/components/footer/index.js +0 -7
- package/dist/components/footer/index.js.map +0 -1
- package/dist/components/header/header-enhanced/index.esm.js +0 -405
- package/dist/components/header/header-enhanced/index.esm.js.map +0 -1
- package/dist/components/header/header-enhanced/index.js +0 -33
- package/dist/components/header/header-enhanced/index.js.map +0 -1
- package/dist/components/header copy/index.esm.js +0 -131
- package/dist/components/header copy/index.esm.js.map +0 -1
- package/dist/components/header copy/index.js +0 -11
- package/dist/components/header copy/index.js.map +0 -1
- package/dist/components/inventory-reports-title-bar/component/reportFilter/index.esm.js +0 -400
- package/dist/components/inventory-reports-title-bar/component/reportFilter/index.esm.js.map +0 -1
- package/dist/components/inventory-reports-title-bar/component/reportFilter/index.js +0 -41
- package/dist/components/inventory-reports-title-bar/component/reportFilter/index.js.map +0 -1
- package/dist/components/share-modal/share-modal-enhanced/index.esm.js +0 -288
- package/dist/components/share-modal/share-modal-enhanced/index.esm.js.map +0 -1
- package/dist/components/share-modal/share-modal-enhanced/index.js +0 -24
- package/dist/components/share-modal/share-modal-enhanced/index.js.map +0 -1
- package/dist/views/beforeAuth/login/index/index.esm.js +0 -209
- package/dist/views/beforeAuth/login/index/index.esm.js.map +0 -1
- package/dist/views/beforeAuth/login/index/index.js +0 -20
- package/dist/views/beforeAuth/login/index/index.js.map +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../../src/components/select/controller/chip-or-placeholder.tsx"],"sourcesContent":["import { Close } from \"@mui/icons-material\";\r\nimport { ChipProps } from \"@mui/material\";\r\nimport Chip from \"../../chip/chip\";\r\nimport Typography from \"../../typography/typography\";\r\n\r\ninterface ChipOrPlaceholderProps {\r\n data: string[];\r\n placeholder: string;\r\n onDelete?: () => void;\r\n chipProps?: Omit<ChipProps, \"label\">;\r\n}\r\n\r\nconst ChipOrPlaceholder: React.FC<ChipOrPlaceholderProps> = ({\r\n data,\r\n placeholder,\r\n onDelete,\r\n chipProps,\r\n}) => (\r\n <>\r\n {data.length ? (\r\n <Chip\r\n variant=\"outlined\"\r\n type=\"normal\"\r\n label={`${data.length} Selected`}\r\n deleteIcon={<Close fontSize=\"large\" />}\r\n onDelete={onDelete}\r\n onMouseDown={(event) => event.stopPropagation()}\r\n {...chipProps}\r\n />\r\n ) : (\r\n <Typography color=\"inherit\" type=\"s3\">\r\n {placeholder}\r\n </Typography>\r\n )}\r\n </>\r\n);\r\n\r\nexport default ChipOrPlaceholder;\r\n"],"names":["data","placeholder","onDelete","chipProps","jsx","Fragment","children","length","Chip","variant","type","label","deleteIcon","Close","fontSize","onMouseDown","event","stopPropagation","Typography","color"],"mappings":"kSAY4D,EAC1DA,OACAC,cACAC,WACAC,8BAEAC,EAAAA,IAAAC,EAAAA,SAAA,CACGC,WAAKC,sBACJH,EAAAA,IAACI,EAAAA,KAAA,CACCC,QAAQ,WACRC,KAAK,SACLC,MAAO,GAAGX,EAAKO,kBACfK,4BAAYR,IAACS,EAAAA,QAAA,CAAMC,SAAS,UAC5BZ,WACAa,YAAcC,GAAUA,EAAMC,qBAC1Bd,yBAGLe,aAAA,CAAWC,MAAM,UAAUT,KAAK,KAC9BJ"}
|
|
@@ -0,0 +1,165 @@
|
|
|
1
|
+
import { jsx, jsxs, Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { Controller } from "react-hook-form";
|
|
3
|
+
import { Select } from "../../select/index.esm.js";
|
|
4
|
+
import { Checkbox } from "../../../checkbox/checkbox/index.esm.js";
|
|
5
|
+
import { Typography } from "../../../typography/typography/index.esm.js";
|
|
6
|
+
import { Chip } from "../../../chip/chip/index.esm.js";
|
|
7
|
+
import { MoreIcon } from "../../../icons/more/index.esm.js";
|
|
8
|
+
import ChipOrPlaceholder from "../chip-or-placeholder/index.esm.js";
|
|
9
|
+
/* empty css */
|
|
10
|
+
import FormHelperText from "../../../../node_modules/@mui/material/FormHelperText/FormHelperText/index.esm.js";
|
|
11
|
+
import MenuItem from "../../../../node_modules/@mui/material/MenuItem/MenuItem/index.esm.js";
|
|
12
|
+
import Box from "../../../../node_modules/@mui/material/Box/Box/index.esm.js";
|
|
13
|
+
const SelectedItems = ({
|
|
14
|
+
data,
|
|
15
|
+
options
|
|
16
|
+
}) => {
|
|
17
|
+
const displayTitle = data.map(
|
|
18
|
+
(selectedItem) => {
|
|
19
|
+
var _a;
|
|
20
|
+
return ((_a = options.find((option) => option.value === selectedItem)) == null ? void 0 : _a.text) || selectedItem;
|
|
21
|
+
}
|
|
22
|
+
);
|
|
23
|
+
return /* @__PURE__ */ jsxs(
|
|
24
|
+
Typography,
|
|
25
|
+
{
|
|
26
|
+
type: "s4",
|
|
27
|
+
color: "inherit",
|
|
28
|
+
sx: { display: "flex", gap: 1, alignItems: "center", mt: 0.5 },
|
|
29
|
+
children: [
|
|
30
|
+
displayTitle.slice(0.4).join(", "),
|
|
31
|
+
data.length > 4 && /* @__PURE__ */ jsx(Chip, { variant: "outlined", type: "normal", label: /* @__PURE__ */ jsx(MoreIcon, {}) })
|
|
32
|
+
]
|
|
33
|
+
}
|
|
34
|
+
);
|
|
35
|
+
};
|
|
36
|
+
const generateMenuItems = ({
|
|
37
|
+
options,
|
|
38
|
+
multiple,
|
|
39
|
+
placeholder,
|
|
40
|
+
with_checkboxes,
|
|
41
|
+
onChange,
|
|
42
|
+
values
|
|
43
|
+
}) => {
|
|
44
|
+
const items = [];
|
|
45
|
+
if (!multiple) {
|
|
46
|
+
items.push(
|
|
47
|
+
/* @__PURE__ */ jsx(MenuItem, { disabled: true, value: "", children: /* @__PURE__ */ jsx("em", { children: placeholder }) })
|
|
48
|
+
);
|
|
49
|
+
}
|
|
50
|
+
const handleParentChange = (parentValue, childOptions) => {
|
|
51
|
+
const childValues = childOptions.map((child) => child.value);
|
|
52
|
+
const isParentSelected = values.includes(parentValue);
|
|
53
|
+
const updatedValues = isParentSelected ? values.filter((value) => value !== parentValue && !childValues.includes(value)) : [...values, parentValue, ...childValues];
|
|
54
|
+
onChange(updatedValues);
|
|
55
|
+
};
|
|
56
|
+
options.forEach((option) => {
|
|
57
|
+
items.push(
|
|
58
|
+
/* @__PURE__ */ jsx(
|
|
59
|
+
MenuItem,
|
|
60
|
+
{
|
|
61
|
+
value: option.value,
|
|
62
|
+
className: (option == null ? void 0 : option.isGroup) ? "select--MenuItemHeader" : "",
|
|
63
|
+
children: /* @__PURE__ */ jsxs(Box, { sx: { display: "flex", gap: 1 }, children: [
|
|
64
|
+
multiple && with_checkboxes && // <Checkbox checked={values?.indexOf((option.value)) > -1} />
|
|
65
|
+
/* @__PURE__ */ jsx(
|
|
66
|
+
Checkbox,
|
|
67
|
+
{
|
|
68
|
+
checked: (values == null ? void 0 : values.indexOf(option.value)) > -1,
|
|
69
|
+
onChange: () => handleParentChange(option.value, option.options || [])
|
|
70
|
+
}
|
|
71
|
+
),
|
|
72
|
+
/* @__PURE__ */ jsx(Typography, { type: "s4", color: "inherit", children: option.text })
|
|
73
|
+
] })
|
|
74
|
+
}
|
|
75
|
+
)
|
|
76
|
+
);
|
|
77
|
+
if ((option == null ? void 0 : option.isGroup) && Array.isArray(option == null ? void 0 : option.options)) {
|
|
78
|
+
option.options.forEach((opt) => {
|
|
79
|
+
items.push(
|
|
80
|
+
/* @__PURE__ */ jsx(MenuItem, { value: opt.value, sx: { pl: 5 }, children: /* @__PURE__ */ jsxs(Box, { sx: { display: "flex", gap: 1 }, children: [
|
|
81
|
+
multiple && with_checkboxes && /* @__PURE__ */ jsx(Checkbox, { checked: (values == null ? void 0 : values.indexOf(opt.value)) > -1 }),
|
|
82
|
+
/* @__PURE__ */ jsx(Typography, { type: "s4", color: "inherit", children: opt.text })
|
|
83
|
+
] }) })
|
|
84
|
+
);
|
|
85
|
+
});
|
|
86
|
+
}
|
|
87
|
+
});
|
|
88
|
+
return items;
|
|
89
|
+
};
|
|
90
|
+
const ControllerSelect = ({
|
|
91
|
+
name,
|
|
92
|
+
fieldArrayName,
|
|
93
|
+
options,
|
|
94
|
+
label,
|
|
95
|
+
placeholder,
|
|
96
|
+
formControl,
|
|
97
|
+
position,
|
|
98
|
+
required,
|
|
99
|
+
size = "small",
|
|
100
|
+
multiple,
|
|
101
|
+
disabled,
|
|
102
|
+
searchPlaceholder,
|
|
103
|
+
handleSearch,
|
|
104
|
+
classes,
|
|
105
|
+
with_checkboxes,
|
|
106
|
+
onChipRemove
|
|
107
|
+
}) => {
|
|
108
|
+
return /* @__PURE__ */ jsx(
|
|
109
|
+
Controller,
|
|
110
|
+
{
|
|
111
|
+
control: formControl,
|
|
112
|
+
name: `${fieldArrayName}.${name}`,
|
|
113
|
+
render: ({ field, fieldState: { error } }) => /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
114
|
+
/* @__PURE__ */ jsx(
|
|
115
|
+
Select,
|
|
116
|
+
{
|
|
117
|
+
fullWidth: true,
|
|
118
|
+
name,
|
|
119
|
+
dataPosition: position,
|
|
120
|
+
dataName: `${fieldArrayName}.${name}`,
|
|
121
|
+
placeholder,
|
|
122
|
+
label,
|
|
123
|
+
value: field.value || (multiple ? [] : ""),
|
|
124
|
+
defaultValue: "",
|
|
125
|
+
onChange: (e) => {
|
|
126
|
+
var _a, _b, _c;
|
|
127
|
+
return multiple && ((_b = (_a = e.target) == null ? void 0 : _a.value.filter((i) => i)) == null ? void 0 : _b.length) > 0 || !multiple && ((_c = e.target) == null ? void 0 : _c.value) ? field.onChange(e.target.value) : field.onChange("");
|
|
128
|
+
},
|
|
129
|
+
required: Boolean(required),
|
|
130
|
+
size,
|
|
131
|
+
multiple: Boolean(multiple),
|
|
132
|
+
disabled: Boolean(disabled),
|
|
133
|
+
searchPlaceholder,
|
|
134
|
+
handleSearch,
|
|
135
|
+
className: classes,
|
|
136
|
+
variant: "outlined",
|
|
137
|
+
error: Boolean(error),
|
|
138
|
+
renderValue: (selected) => /* @__PURE__ */ jsx(Fragment, { children: Array.isArray(selected) ? /* @__PURE__ */ jsx(
|
|
139
|
+
ChipOrPlaceholder,
|
|
140
|
+
{
|
|
141
|
+
data: selected,
|
|
142
|
+
placeholder,
|
|
143
|
+
onDelete: onChipRemove
|
|
144
|
+
}
|
|
145
|
+
) : selected || placeholder }),
|
|
146
|
+
children: generateMenuItems({
|
|
147
|
+
options,
|
|
148
|
+
multiple: Boolean(multiple),
|
|
149
|
+
placeholder,
|
|
150
|
+
values: field.value,
|
|
151
|
+
with_checkboxes: Boolean(with_checkboxes),
|
|
152
|
+
onChange: field.onChange
|
|
153
|
+
})
|
|
154
|
+
}
|
|
155
|
+
),
|
|
156
|
+
error && /* @__PURE__ */ jsx(FormHelperText, { error: true, children: error.message }),
|
|
157
|
+
multiple && Array.isArray(field == null ? void 0 : field.value) && /* @__PURE__ */ jsx(SelectedItems, { data: field.value, options })
|
|
158
|
+
] })
|
|
159
|
+
}
|
|
160
|
+
);
|
|
161
|
+
};
|
|
162
|
+
export {
|
|
163
|
+
ControllerSelect as default
|
|
164
|
+
};
|
|
165
|
+
//# sourceMappingURL=index.esm.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.esm.js","sources":["../../../../../src/components/select/controller/controller-select.tsx"],"sourcesContent":["import { Control, Controller, FieldValue } from \"react-hook-form\";\nimport { Box, FormHelperText, MenuItem, SelectProps } from \"@mui/material\";\n\nimport Select from '../select';\nimport Checkbox from '../../checkbox/checkbox';\nimport Typography from '../../typography/typography';\nimport Chip from '../../chip/chip';\nimport MoreIcon from '../../icons/more';\nimport { MenuItemProps } from '@mui/material';\nimport { ReactElement } from 'react';\nimport ChipOrPlaceholder from './chip-or-placeholder';\nimport './controller-select.scss';\n\ninterface IControllerSelect {\n name: string;\n label: string;\n options: any;\n placeholder: string;\n formControl: Control<FieldValue<any>, any>;\n fieldArrayName?: string;\n position?: string;\n required?: boolean;\n size?: SelectProps[\"size\"];\n multiple?: boolean;\n disabled?: boolean;\n searchPlaceholder?: string;\n handleSearch?: () => void;\n classes?: string;\n with_checkboxes?: boolean;\n onChipRemove?: () => void;\n}\n\nexport interface IOption {\n\ttext: string;\n\tvalue: string | number;\n\tisGroup?: boolean;\n\tparent?: string;\n\toptions?: { text: string; value: string }[];\n}\n\ninterface IMenuItems extends MenuItemProps {\n\toptions: IOption[];\n\tmultiple: boolean;\n\tplaceholder: string;\n\twith_checkboxes: boolean;\n onChange: (value: string[]) => void\n\tvalues: string | string[];\n}\n\nconst SelectedItems = ({\n\tdata,\n\toptions\n}: {\n\tdata: string[];\n\toptions: IOption[];\n}) => {\n\tconst displayTitle = data.map(\n\t\t(selectedItem) =>\n\t\t\toptions.find((option: any) => option.value === selectedItem)?.text ||\n\t\t\tselectedItem\n\t);\n\n\treturn (\n\t\t<Typography\n\t\t\ttype='s4'\n\t\t\tcolor='inherit'\n\t\t\tsx={{ display: 'flex', gap: 1, alignItems: 'center', mt: 0.5 }}>\n\t\t\t{displayTitle.slice(0.4).join(', ')}\n\t\t\t{data.length > 4 && (\n\t\t\t\t<Chip variant='outlined' type='normal' label={<MoreIcon />} />\n\t\t\t)}\n\t\t</Typography>\n\t);\n};\n\nconst generateMenuItems = ({\n\toptions,\n\tmultiple,\n\tplaceholder,\n\twith_checkboxes,\n onChange,\n\tvalues\n}: IMenuItems) => {\n\tconst items: ReactElement[] = [];\n\tif (!multiple) {\n\t\titems.push(\n\t\t\t<MenuItem disabled value=''>\n\t\t\t\t<em>{placeholder}</em>\n\t\t\t</MenuItem>\n\t\t);\n\t}\n\n const handleParentChange = (parentValue: string, childOptions: IOption[]) => {\n const childValues = childOptions.map((child) => child.value);\n\n const isParentSelected = values.includes(parentValue);\n const updatedValues = isParentSelected\n ? values.filter((value) => value !== parentValue && !childValues.includes(value))\n : [...values, parentValue, ...childValues];\n\n onChange(updatedValues);\n };\n\n\toptions.forEach((option) => {\n\t\titems.push(\n\t\t\t<MenuItem\n\t\t\t\tvalue={option.value}\n\t\t\t\tclassName={option?.isGroup ? 'select--MenuItemHeader' : ''}>\n\t\t\t\t<Box sx={{ display: 'flex', gap: 1 }}>\n\t\t\t\t\t{multiple && with_checkboxes && (\n\t\t\t\t\t\t// <Checkbox checked={values?.indexOf((option.value)) > -1} />\n <Checkbox checked={values?.indexOf((option.value)) > -1}\n onChange={() => handleParentChange(option.value, option.options || [])}\n />\n\t\t\t\t\t)}\n\t\t\t\t\t<Typography type='s4' color='inherit'>\n\t\t\t\t\t\t{option.text}\n\t\t\t\t\t</Typography>\n\t\t\t\t</Box>\n\t\t\t</MenuItem>\n\t\t);\n\t\tif (option?.isGroup && Array.isArray(option?.options)) {\n\t\t\toption.options.forEach((opt) => {\n\t\t\t\titems.push(\n\t\t\t\t\t<MenuItem value={opt.value} sx={{ pl: 5 }}>\n\t\t\t\t\t\t<Box sx={{ display: 'flex', gap: 1 }}>\n\t\t\t\t\t\t\t{multiple && with_checkboxes && (\n\t\t\t\t\t\t\t\t<Checkbox checked={values?.indexOf(opt.value) > -1} />\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t<Typography type='s4' color='inherit'>\n\t\t\t\t\t\t\t\t{opt.text}\n\t\t\t\t\t\t\t</Typography>\n\t\t\t\t\t\t</Box>\n\t\t\t\t\t</MenuItem>\n\t\t\t\t);\n\t\t\t});\n\t\t}\n\t});\n\n\treturn items;\n};\n\nconst ControllerSelect: React.FC<IControllerSelect> = ({\n name,\n fieldArrayName,\n options,\n label,\n placeholder,\n formControl,\n position,\n required,\n size = \"small\",\n multiple,\n disabled,\n searchPlaceholder,\n handleSearch,\n classes,\n with_checkboxes,\n onChipRemove,\n}) => {\n return (\n <Controller\n control={formControl}\n name={`${fieldArrayName}.${name}`}\n render={({ field, fieldState: { error } }) => (\n <>\n <Select\n fullWidth\n name={name}\n dataPosition={position}\n dataName={`${fieldArrayName}.${name}`}\n placeholder={placeholder}\n label={label}\n value={field.value || (multiple ? [] : \"\")}\n defaultValue=\"\"\n onChange={(e:any)=>(multiple&&e.target?.value.filter((i:any)=>i)?.length>0||!multiple&&(e.target?.value))?field.onChange(e.target.value):field.onChange(\"\")}\n required={Boolean(required)}\n size={size}\n multiple={Boolean(multiple)}\n disabled={Boolean(disabled)}\n searchPlaceholder={searchPlaceholder}\n handleSearch={handleSearch}\n className={classes}\n variant=\"outlined\"\n error={Boolean(error)}\n renderValue={(selected: string | string[]) => (\n <>\n {Array.isArray(selected) ? (\n <ChipOrPlaceholder\n data={selected}\n placeholder={placeholder}\n onDelete={onChipRemove}\n />\n ) : (\n selected || placeholder\n )}\n </>\n )}\n >\n {generateMenuItems({\n options,\n multiple: Boolean(multiple),\n placeholder: placeholder,\n values: field.value,\n with_checkboxes: Boolean(with_checkboxes),\n onChange: field.onChange\n })}\n </Select>\n {error &&\n <FormHelperText error>{error.message}</FormHelperText>\n }\n {multiple && Array.isArray(field?.value) && (\n <SelectedItems data={field.value} options={options} />\n )}\n </>\n )}\n />\n );\n};\n\nexport default ControllerSelect;\n"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),l=require("react-hook-form"),r=,/* empty css */a=,/* empty css */o=,/* empty css */i=,/* empty css */n=,/* empty css */s=;/* empty css */;/* empty css */var t=,/* empty css */d=,/* empty css */u=;/* empty css */const c=({data:l,options:r})=>{const a=l.map(e=>{var l;return(null==(l=r.find(l=>l.value===e))?void 0:l.text)||e});/* @__PURE__ */
|
|
2
|
+
return e.jsxs(o.Typography,{type:"s4",color:"inherit",sx:{display:"flex",gap:1,alignItems:"center",mt:.5},children:[a.slice(.4).join(", "),l.length>4&&/* @__PURE__ */e.jsx(i.Chip,{variant:"outlined",type:"normal",label:/* @__PURE__ */e.jsx(n.MoreIcon,{})})]})},h=({options:l,multiple:r,placeholder:i,with_checkboxes:n,onChange:s,values:t})=>{const c=[];return r||c.push(
|
|
3
|
+
/* @__PURE__ */e.jsx(d.default,{disabled:!0,value:"",children:/* @__PURE__ */e.jsx("em",{children:i})})),l.forEach(l=>{c.push(
|
|
4
|
+
/* @__PURE__ */e.jsx(d.default,{value:l.value,className:(null==l?void 0:l.isGroup)?"select--MenuItemHeader":"",children:/* @__PURE__ */e.jsxs(u.default,{sx:{display:"flex",gap:1},children:[r&&n&&
|
|
5
|
+
/* @__PURE__ */e.jsx(a.Checkbox,{checked:(null==t?void 0:t.indexOf(l.value))>-1,onChange:()=>((e,l)=>{const r=l.map(e=>e.value),a=t.includes(e)?t.filter(l=>l!==e&&!r.includes(l)):[...t,e,...r];s(a)})(l.value,l.options||[])}),
|
|
6
|
+
/* @__PURE__ */e.jsx(o.Typography,{type:"s4",color:"inherit",children:l.text})]})})),(null==l?void 0:l.isGroup)&&Array.isArray(null==l?void 0:l.options)&&l.options.forEach(l=>{c.push(
|
|
7
|
+
/* @__PURE__ */e.jsx(d.default,{value:l.value,sx:{pl:5},children:/* @__PURE__ */e.jsxs(u.default,{sx:{display:"flex",gap:1},children:[r&&n&&/* @__PURE__ */e.jsx(a.Checkbox,{checked:(null==t?void 0:t.indexOf(l.value))>-1}),
|
|
8
|
+
/* @__PURE__ */e.jsx(o.Typography,{type:"s4",color:"inherit",children:l.text})]})}))})}),c};exports.default=({name:a,fieldArrayName:o,options:i,label:n,placeholder:d,formControl:u,position:p,required:x,size:m="small",multiple:v,disabled:j,searchPlaceholder:f,handleSearch:y,classes:g,with_checkboxes:b,onChipRemove:q})=>/* @__PURE__ */e.jsx(l.Controller,{control:u,name:`${o}.${a}`,render:({field:l,fieldState:{error:u}})=>/* @__PURE__ */e.jsxs(e.Fragment,{children:[
|
|
9
|
+
/* @__PURE__ */e.jsx(r.Select,{fullWidth:!0,name:a,dataPosition:p,dataName:`${o}.${a}`,placeholder:d,label:n,value:l.value||(v?[]:""),defaultValue:"",onChange:e=>{var r,a,o;return v&&(null==(a=null==(r=e.target)?void 0:r.value.filter(e=>e))?void 0:a.length)>0||!v&&(null==(o=e.target)?void 0:o.value)?l.onChange(e.target.value):l.onChange("")},required:Boolean(x),size:m,multiple:Boolean(v),disabled:Boolean(j),searchPlaceholder:f,handleSearch:y,className:g,variant:"outlined",error:Boolean(u),renderValue:l=>/* @__PURE__ */e.jsx(e.Fragment,{children:Array.isArray(l)?/* @__PURE__ */e.jsx(s.default,{data:l,placeholder:d,onDelete:q}):l||d}),children:h({options:i,multiple:Boolean(v),placeholder:d,values:l.value,with_checkboxes:Boolean(b),onChange:l.onChange})}),u&&/* @__PURE__ */e.jsx(t.default,{error:!0,children:u.message}),v&&Array.isArray(null==l?void 0:l.value)&&/* @__PURE__ */e.jsx(c,{data:l.value,options:i})]})});
|
|
10
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../../src/components/select/controller/controller-select.tsx"],"sourcesContent":["import { Control, Controller, FieldValue } from \"react-hook-form\";\nimport { Box, FormHelperText, MenuItem, SelectProps } from \"@mui/material\";\n\nimport Select from '../select';\nimport Checkbox from '../../checkbox/checkbox';\nimport Typography from '../../typography/typography';\nimport Chip from '../../chip/chip';\nimport MoreIcon from '../../icons/more';\nimport { MenuItemProps } from '@mui/material';\nimport { ReactElement } from 'react';\nimport ChipOrPlaceholder from './chip-or-placeholder';\nimport './controller-select.scss';\n\ninterface IControllerSelect {\n name: string;\n label: string;\n options: any;\n placeholder: string;\n formControl: Control<FieldValue<any>, any>;\n fieldArrayName?: string;\n position?: string;\n required?: boolean;\n size?: SelectProps[\"size\"];\n multiple?: boolean;\n disabled?: boolean;\n searchPlaceholder?: string;\n handleSearch?: () => void;\n classes?: string;\n with_checkboxes?: boolean;\n onChipRemove?: () => void;\n}\n\nexport interface IOption {\n\ttext: string;\n\tvalue: string | number;\n\tisGroup?: boolean;\n\tparent?: string;\n\toptions?: { text: string; value: string }[];\n}\n\ninterface IMenuItems extends MenuItemProps {\n\toptions: IOption[];\n\tmultiple: boolean;\n\tplaceholder: string;\n\twith_checkboxes: boolean;\n onChange: (value: string[]) => void\n\tvalues: string | string[];\n}\n\nconst SelectedItems = ({\n\tdata,\n\toptions\n}: {\n\tdata: string[];\n\toptions: IOption[];\n}) => {\n\tconst displayTitle = data.map(\n\t\t(selectedItem) =>\n\t\t\toptions.find((option: any) => option.value === selectedItem)?.text ||\n\t\t\tselectedItem\n\t);\n\n\treturn (\n\t\t<Typography\n\t\t\ttype='s4'\n\t\t\tcolor='inherit'\n\t\t\tsx={{ display: 'flex', gap: 1, alignItems: 'center', mt: 0.5 }}>\n\t\t\t{displayTitle.slice(0.4).join(', ')}\n\t\t\t{data.length > 4 && (\n\t\t\t\t<Chip variant='outlined' type='normal' label={<MoreIcon />} />\n\t\t\t)}\n\t\t</Typography>\n\t);\n};\n\nconst generateMenuItems = ({\n\toptions,\n\tmultiple,\n\tplaceholder,\n\twith_checkboxes,\n onChange,\n\tvalues\n}: IMenuItems) => {\n\tconst items: ReactElement[] = [];\n\tif (!multiple) {\n\t\titems.push(\n\t\t\t<MenuItem disabled value=''>\n\t\t\t\t<em>{placeholder}</em>\n\t\t\t</MenuItem>\n\t\t);\n\t}\n\n const handleParentChange = (parentValue: string, childOptions: IOption[]) => {\n const childValues = childOptions.map((child) => child.value);\n\n const isParentSelected = values.includes(parentValue);\n const updatedValues = isParentSelected\n ? values.filter((value) => value !== parentValue && !childValues.includes(value))\n : [...values, parentValue, ...childValues];\n\n onChange(updatedValues);\n };\n\n\toptions.forEach((option) => {\n\t\titems.push(\n\t\t\t<MenuItem\n\t\t\t\tvalue={option.value}\n\t\t\t\tclassName={option?.isGroup ? 'select--MenuItemHeader' : ''}>\n\t\t\t\t<Box sx={{ display: 'flex', gap: 1 }}>\n\t\t\t\t\t{multiple && with_checkboxes && (\n\t\t\t\t\t\t// <Checkbox checked={values?.indexOf((option.value)) > -1} />\n <Checkbox checked={values?.indexOf((option.value)) > -1}\n onChange={() => handleParentChange(option.value, option.options || [])}\n />\n\t\t\t\t\t)}\n\t\t\t\t\t<Typography type='s4' color='inherit'>\n\t\t\t\t\t\t{option.text}\n\t\t\t\t\t</Typography>\n\t\t\t\t</Box>\n\t\t\t</MenuItem>\n\t\t);\n\t\tif (option?.isGroup && Array.isArray(option?.options)) {\n\t\t\toption.options.forEach((opt) => {\n\t\t\t\titems.push(\n\t\t\t\t\t<MenuItem value={opt.value} sx={{ pl: 5 }}>\n\t\t\t\t\t\t<Box sx={{ display: 'flex', gap: 1 }}>\n\t\t\t\t\t\t\t{multiple && with_checkboxes && (\n\t\t\t\t\t\t\t\t<Checkbox checked={values?.indexOf(opt.value) > -1} />\n\t\t\t\t\t\t\t)}\n\t\t\t\t\t\t\t<Typography type='s4' color='inherit'>\n\t\t\t\t\t\t\t\t{opt.text}\n\t\t\t\t\t\t\t</Typography>\n\t\t\t\t\t\t</Box>\n\t\t\t\t\t</MenuItem>\n\t\t\t\t);\n\t\t\t});\n\t\t}\n\t});\n\n\treturn items;\n};\n\nconst ControllerSelect: React.FC<IControllerSelect> = ({\n name,\n fieldArrayName,\n options,\n label,\n placeholder,\n formControl,\n position,\n required,\n size = \"small\",\n multiple,\n disabled,\n searchPlaceholder,\n handleSearch,\n classes,\n with_checkboxes,\n onChipRemove,\n}) => {\n return (\n <Controller\n control={formControl}\n name={`${fieldArrayName}.${name}`}\n render={({ field, fieldState: { error } }) => (\n <>\n <Select\n fullWidth\n name={name}\n dataPosition={position}\n dataName={`${fieldArrayName}.${name}`}\n placeholder={placeholder}\n label={label}\n value={field.value || (multiple ? [] : \"\")}\n defaultValue=\"\"\n onChange={(e:any)=>(multiple&&e.target?.value.filter((i:any)=>i)?.length>0||!multiple&&(e.target?.value))?field.onChange(e.target.value):field.onChange(\"\")}\n required={Boolean(required)}\n size={size}\n multiple={Boolean(multiple)}\n disabled={Boolean(disabled)}\n searchPlaceholder={searchPlaceholder}\n handleSearch={handleSearch}\n className={classes}\n variant=\"outlined\"\n error={Boolean(error)}\n renderValue={(selected: string | string[]) => (\n <>\n {Array.isArray(selected) ? (\n <ChipOrPlaceholder\n data={selected}\n placeholder={placeholder}\n onDelete={onChipRemove}\n />\n ) : (\n selected || placeholder\n )}\n </>\n )}\n >\n {generateMenuItems({\n options,\n multiple: Boolean(multiple),\n placeholder: placeholder,\n values: field.value,\n with_checkboxes: Boolean(with_checkboxes),\n onChange: field.onChange\n })}\n </Select>\n {error &&\n <FormHelperText error>{error.message}</FormHelperText>\n }\n {multiple && Array.isArray(field?.value) && (\n <SelectedItems data={field.value} options={options} />\n )}\n </>\n )}\n />\n );\n};\n\nexport default ControllerSelect;\n"],"names":["SelectedItems","data","options","displayTitle","map","selectedItem","_a","find","option","value","text","jsxs","Typography","type","color","sx","display","gap","alignItems","mt","children","slice","join","length","jsx","Chip","variant","label","MoreIcon","generateMenuItems","multiple","placeholder","with_checkboxes","onChange","values","items","push","MenuItem","disabled","forEach","className","isGroup","Box","Checkbox","checked","indexOf","parentValue","childOptions","childValues","child","updatedValues","includes","filter","handleParentChange","Array","isArray","opt","pl","name","fieldArrayName","formControl","position","required","size","searchPlaceholder","handleSearch","classes","onChipRemove","Controller","control","render","field","fieldState","error","Fragment","Select","fullWidth","dataPosition","dataName","defaultValue","e","_b","target","i","_c","Boolean","renderValue","selected","ChipOrPlaceholder","onDelete","FormHelperText","message"],"mappings":"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"}
|
|
@@ -9,15 +9,8 @@ import TabContext from "../../../node_modules/@mui/lab/TabContext/TabContext/ind
|
|
|
9
9
|
import TabList from "../../../node_modules/@mui/lab/TabList/TabList/index.esm.js";
|
|
10
10
|
import Tab from "../../../node_modules/@mui/material/Tab/Tab/index.esm.js";
|
|
11
11
|
import TabPanel from "../../../node_modules/@mui/lab/TabPanel/TabPanel/index.esm.js";
|
|
12
|
-
|
|
13
|
-
const {
|
|
14
|
-
tabs,
|
|
15
|
-
onEditTabTitle,
|
|
16
|
-
activeTabValue,
|
|
17
|
-
setActiveTabValue,
|
|
18
|
-
handleTabChange,
|
|
19
|
-
handleRemoveTab
|
|
20
|
-
} = props;
|
|
12
|
+
const TabBarUi = (props) => {
|
|
13
|
+
const { tabs, onEditTabTitle, activeTabValue, setActiveTabValue, handleTabChange, handleRemoveTab } = props;
|
|
21
14
|
const [value, setValue] = useState(0);
|
|
22
15
|
const [editableTabId, setEditableTabId] = useState(null);
|
|
23
16
|
const handleChange = (event, newValue) => {
|
|
@@ -78,8 +71,9 @@ function TabBarUi(props) {
|
|
|
78
71
|
(tab, index) => tab.content && /* @__PURE__ */ jsx(TabPanel, { value: index, children: value === index && tab.content }, tab.tab_order)
|
|
79
72
|
)
|
|
80
73
|
] }) });
|
|
81
|
-
}
|
|
74
|
+
};
|
|
82
75
|
export {
|
|
76
|
+
TabBarUi,
|
|
83
77
|
TabBarUi as default
|
|
84
78
|
};
|
|
85
79
|
//# sourceMappingURL=index.esm.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.esm.js","sources":["../../../../src/components/tab-bar-ui/tab-bar-ui.tsx"],"sourcesContent":["import React, { ReactNode, useEffect, useState } from \"react\";\nimport { Box } from \"@mui/material\";\nimport Tab from \"@mui/material/Tab\";\n\nimport TabContext from \"@mui/lab/TabContext\";\nimport TabList from \"@mui/lab/TabList\";\nimport TabPanel from \"@mui/lab/TabPanel\";\nimport CloseIcon from \"@mui/icons-material/Close\";\n\nimport \"./tab-bar-ui.scss\";\nimport TextField from \"../text-field/text-field\";\nimport images from \"../../assets/images\";\n\ninterface TabItem {\n tab_order: number;\n title: string;\n content?: string | ReactNode;\n data?: any;\n remove_tab?: boolean;\n tabIcon?: string;\n}\
|
|
1
|
+
{"version":3,"file":"index.esm.js","sources":["../../../../src/components/tab-bar-ui/tab-bar-ui.tsx"],"sourcesContent":["import React, { ReactNode, useEffect, useState } from \"react\";\nimport { Box } from \"@mui/material\";\nimport Tab from \"@mui/material/Tab\";\n\nimport TabContext from \"@mui/lab/TabContext\";\nimport TabList from \"@mui/lab/TabList\";\nimport TabPanel from \"@mui/lab/TabPanel\";\nimport CloseIcon from \"@mui/icons-material/Close\";\n\nimport \"./tab-bar-ui.scss\";\nimport TextField from \"../text-field/text-field\";\nimport images from \"../../assets/images\";\n\ninterface TabItem {\n tab_order: number;\n title: string;\n content?: string | ReactNode;\n data?: any;\n remove_tab?: boolean;\n tabIcon?: string;\n}\nexport interface ITabProps {\n tabs: TabItem[];\n activeTabValue?: number;\n setActiveTabValue?: React.Dispatch<React.SetStateAction<number | undefined>>;\n onEditTabTitle?: (tabId: number, newTitle: string) => void;\n handleTabChange?: () => void;\n handleRemoveTab?: (tabId: number) => void;\n}\n\nexport const TabBarUi = (props: TabProps) => {\n const { tabs, onEditTabTitle, activeTabValue, setActiveTabValue, handleTabChange, handleRemoveTab } = props;\n const [value, setValue] = useState(0);\n const [editableTabId, setEditableTabId] = useState<number | null>(null);\n const handleChange = (event: React.SyntheticEvent, newValue: number) => {\n setValue(newValue);\n setActiveTabValue && setActiveTabValue(newValue);\n handleTabChange && handleTabChange();\n };\n\n const handleTabDoubleClick = (tabId: number) => {\n setEditableTabId(tabId);\n };\n\n const handleEditTabTitle = (\n event: React.ChangeEvent<HTMLInputElement>,\n tabId: number,\n ) => {\n onEditTabTitle && onEditTabTitle(tabId, event.target.value);\n };\n\n useEffect(() => {\n if (setActiveTabValue && Boolean(tabs?.length)) setActiveTabValue(value);\n // eslint-disable-next-line\n }, [tabs]);\n\n return (\n <Box>\n <TabContext value={activeTabValue ?? value}>\n <Box>\n <TabList\n className=\"account-payble-tabsui-wrap\"\n onChange={handleChange}\n >\n {tabs.map((tab: TabItem) => (\n <Tab\n className=\"account-payble-tab-items\"\n key={tab.tab_order}\n label={\n onEditTabTitle && editableTabId === tab.tab_order ? (\n <TextField\n value={tab.title}\n autoFocus\n onBlur={() => setEditableTabId(null)}\n onChange={(e: any) =>\n handleEditTabTitle(e, tab.tab_order)\n }\n />\n ) : handleRemoveTab ? (\n <div className=\"Tabs--Title\">\n <div>{tab.title}</div>\n {!tab.remove_tab && (\n <CloseIcon\n style={{ fontSize: \"15px\", cursor: \"pointer\" }}\n onClick={() => {\n handleRemoveTab(tab.tab_order);\n }}\n />\n )}\n </div>\n ) : (\n <div className=\"text-display\">\n <img src={images.common[tab.tabIcon]} />\n {tab.title}\n </div>\n )\n }\n wrapped\n onDoubleClick={() => handleTabDoubleClick(tab.tab_order)}\n />\n ))}\n </TabList>\n </Box>\n {tabs.map(\n (tab: TabItem, index: number) =>\n tab.content && (\n <TabPanel value={index} key={tab.tab_order}>\n {value === index && tab.content}\n </TabPanel>\n ),\n )}\n </TabContext>\n </Box>\n );\n};\n\nexport default TabBarUi;\n"],"names":["CloseIcon"],"mappings":";;;;;;;;;;;AA8BO,MAAM,WAAW,CAAC,UAAoB;AAC3C,QAAM,EAAE,MAAM,gBAAgB,gBAAgB,mBAAmB,iBAAiB,oBAAoB;AACtG,QAAM,CAAC,OAAO,QAAQ,IAAI,SAAS,CAAC;AACpC,QAAM,CAAC,eAAe,gBAAgB,IAAI,SAAwB,IAAI;AACtE,QAAM,eAAe,CAAC,OAA6B,aAAqB;AACtE,aAAS,QAAQ;AACjB,yBAAqB,kBAAkB,QAAQ;AAC/C,uBAAmB,gBAAA;AAAA,EACrB;AAEA,QAAM,uBAAuB,CAAC,UAAkB;AAC9C,qBAAiB,KAAK;AAAA,EACxB;AAEA,QAAM,qBAAqB,CACzB,OACA,UACG;AACH,sBAAkB,eAAe,OAAO,MAAM,OAAO,KAAK;AAAA,EAC5D;AAEA,YAAU,MAAM;AACd,QAAI,qBAAqB,QAAQ,6BAAM,MAAM,qBAAqB,KAAK;AAAA,EAEzE,GAAG,CAAC,IAAI,CAAC;AAET,6BACG,KAAA,EACC,UAAA,qBAAC,YAAA,EAAW,OAAO,kBAAkB,OACnC,UAAA;AAAA,IAAA,oBAAC,KAAA,EACC,UAAA;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,WAAU;AAAA,QACV,UAAU;AAAA,QAET,UAAA,KAAK,IAAI,CAAC,QACT;AAAA,UAAC;AAAA,UAAA;AAAA,YACC,WAAU;AAAA,YAEV,OACE,kBAAkB,kBAAkB,IAAI,YACtC;AAAA,cAAC;AAAA,cAAA;AAAA,gBACC,OAAO,IAAI;AAAA,gBACX,WAAS;AAAA,gBACT,QAAQ,MAAM,iBAAiB,IAAI;AAAA,gBACnC,UAAU,CAAC,MACT,mBAAmB,GAAG,IAAI,SAAS;AAAA,cAAA;AAAA,YAAA,IAGrC,kBACF,qBAAC,OAAA,EAAI,WAAU,eACb,UAAA;AAAA,cAAA,oBAAC,OAAA,EAAK,cAAI,MAAA,CAAM;AAAA,cACf,CAAC,IAAI,cACJ;AAAA,gBAACA;AAAAA,gBAAA;AAAA,kBACC,OAAO,EAAE,UAAU,QAAQ,QAAQ,UAAA;AAAA,kBACnC,SAAS,MAAM;AACb,oCAAgB,IAAI,SAAS;AAAA,kBAC/B;AAAA,gBAAA;AAAA,cAAA;AAAA,YACF,EAAA,CAEJ,IAEA,qBAAC,OAAA,EAAI,WAAU,gBACb,UAAA;AAAA,cAAA,oBAAC,SAAI,KAAK,OAAO,OAAO,IAAI,OAAO,GAAG;AAAA,cACrC,IAAI;AAAA,YAAA,GACP;AAAA,YAGJ,SAAO;AAAA,YACP,eAAe,MAAM,qBAAqB,IAAI,SAAS;AAAA,UAAA;AAAA,UA/BlD,IAAI;AAAA,QAAA,CAiCZ;AAAA,MAAA;AAAA,IAAA,GAEL;AAAA,IACC,KAAK;AAAA,MACJ,CAAC,KAAc,UACb,IAAI,WACF,oBAAC,UAAA,EAAS,OAAO,OACd,UAAA,UAAU,SAAS,IAAI,QAAA,GADG,IAAI,SAEjC;AAAA,IAAA;AAAA,EAEN,EAAA,CACF,EAAA,CACF;AAEJ;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),a=require("react"),t=;/* empty css */;/* empty css */var r=,/* empty css */i=,/* empty css */l=,/* empty css */s=,/* empty css */n=,/* empty css */
|
|
2
|
-
/* @__PURE__ */e.jsx(l.default,{children:/* @__PURE__ */e.jsx(n.default,{className:"account-payble-tabsui-wrap",onChange:(e,a)=>{
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),a=require("react"),t=;/* empty css */;/* empty css */var r=,/* empty css */i=,/* empty css */l=,/* empty css */s=,/* empty css */n=,/* empty css */d=,/* empty css */u=;/* empty css */const o=o=>{const{tabs:b,onEditTabTitle:c,activeTabValue:x,setActiveTabValue:m,handleTabChange:j,handleRemoveTab:v}=o,[T,_]=a.useState(0),[f,h]=a.useState(null);return a.useEffect(()=>{m&&Boolean(null==b?void 0:b.length)&&m(T)},[b]),/* @__PURE__ */e.jsx(l.default,{children:/* @__PURE__ */e.jsxs(s.default,{value:x??T,children:[
|
|
2
|
+
/* @__PURE__ */e.jsx(l.default,{children:/* @__PURE__ */e.jsx(n.default,{className:"account-payble-tabsui-wrap",onChange:(e,a)=>{_(a),m&&m(a),j&&j()},children:b.map(a=>/* @__PURE__ */e.jsx(d.default,{className:"account-payble-tab-items",label:c&&f===a.tab_order?/* @__PURE__ */e.jsx(r.TextField,{value:a.title,autoFocus:!0,onBlur:()=>h(null),onChange:e=>{return t=e,r=a.tab_order,void(c&&c(r,t.target.value));var t,r}}):v?/* @__PURE__ */e.jsxs("div",{className:"Tabs--Title",children:[
|
|
3
3
|
/* @__PURE__ */e.jsx("div",{children:a.title}),!a.remove_tab&&/* @__PURE__ */e.jsx(t.default,{style:{fontSize:"15px",cursor:"pointer"},onClick:()=>{v(a.tab_order)}})]}):/* @__PURE__ */e.jsxs("div",{className:"text-display",children:[
|
|
4
|
-
/* @__PURE__ */e.jsx("img",{src:i.images.common[a.tabIcon]}),a.title]}),wrapped:!0,onDoubleClick:()=>{return e=a.tab_order,void h(e);var e}},a.tab_order))})}),
|
|
4
|
+
/* @__PURE__ */e.jsx("img",{src:i.images.common[a.tabIcon]}),a.title]}),wrapped:!0,onDoubleClick:()=>{return e=a.tab_order,void h(e);var e}},a.tab_order))})}),b.map((a,t)=>a.content&&/* @__PURE__ */e.jsx(u.default,{value:t,children:T===t&&a.content},a.tab_order))]})})};exports.TabBarUi=o,exports.default=o;
|
|
5
5
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../../src/components/tab-bar-ui/tab-bar-ui.tsx"],"sourcesContent":["import React, { ReactNode, useEffect, useState } from \"react\";\nimport { Box } from \"@mui/material\";\nimport Tab from \"@mui/material/Tab\";\n\nimport TabContext from \"@mui/lab/TabContext\";\nimport TabList from \"@mui/lab/TabList\";\nimport TabPanel from \"@mui/lab/TabPanel\";\nimport CloseIcon from \"@mui/icons-material/Close\";\n\nimport \"./tab-bar-ui.scss\";\nimport TextField from \"../text-field/text-field\";\nimport images from \"../../assets/images\";\n\ninterface TabItem {\n tab_order: number;\n title: string;\n content?: string | ReactNode;\n data?: any;\n remove_tab?: boolean;\n tabIcon?: string;\n}\
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../src/components/tab-bar-ui/tab-bar-ui.tsx"],"sourcesContent":["import React, { ReactNode, useEffect, useState } from \"react\";\nimport { Box } from \"@mui/material\";\nimport Tab from \"@mui/material/Tab\";\n\nimport TabContext from \"@mui/lab/TabContext\";\nimport TabList from \"@mui/lab/TabList\";\nimport TabPanel from \"@mui/lab/TabPanel\";\nimport CloseIcon from \"@mui/icons-material/Close\";\n\nimport \"./tab-bar-ui.scss\";\nimport TextField from \"../text-field/text-field\";\nimport images from \"../../assets/images\";\n\ninterface TabItem {\n tab_order: number;\n title: string;\n content?: string | ReactNode;\n data?: any;\n remove_tab?: boolean;\n tabIcon?: string;\n}\nexport interface ITabProps {\n tabs: TabItem[];\n activeTabValue?: number;\n setActiveTabValue?: React.Dispatch<React.SetStateAction<number | undefined>>;\n onEditTabTitle?: (tabId: number, newTitle: string) => void;\n handleTabChange?: () => void;\n handleRemoveTab?: (tabId: number) => void;\n}\n\nexport const TabBarUi = (props: TabProps) => {\n const { tabs, onEditTabTitle, activeTabValue, setActiveTabValue, handleTabChange, handleRemoveTab } = props;\n const [value, setValue] = useState(0);\n const [editableTabId, setEditableTabId] = useState<number | null>(null);\n const handleChange = (event: React.SyntheticEvent, newValue: number) => {\n setValue(newValue);\n setActiveTabValue && setActiveTabValue(newValue);\n handleTabChange && handleTabChange();\n };\n\n const handleTabDoubleClick = (tabId: number) => {\n setEditableTabId(tabId);\n };\n\n const handleEditTabTitle = (\n event: React.ChangeEvent<HTMLInputElement>,\n tabId: number,\n ) => {\n onEditTabTitle && onEditTabTitle(tabId, event.target.value);\n };\n\n useEffect(() => {\n if (setActiveTabValue && Boolean(tabs?.length)) setActiveTabValue(value);\n // eslint-disable-next-line\n }, [tabs]);\n\n return (\n <Box>\n <TabContext value={activeTabValue ?? value}>\n <Box>\n <TabList\n className=\"account-payble-tabsui-wrap\"\n onChange={handleChange}\n >\n {tabs.map((tab: TabItem) => (\n <Tab\n className=\"account-payble-tab-items\"\n key={tab.tab_order}\n label={\n onEditTabTitle && editableTabId === tab.tab_order ? (\n <TextField\n value={tab.title}\n autoFocus\n onBlur={() => setEditableTabId(null)}\n onChange={(e: any) =>\n handleEditTabTitle(e, tab.tab_order)\n }\n />\n ) : handleRemoveTab ? (\n <div className=\"Tabs--Title\">\n <div>{tab.title}</div>\n {!tab.remove_tab && (\n <CloseIcon\n style={{ fontSize: \"15px\", cursor: \"pointer\" }}\n onClick={() => {\n handleRemoveTab(tab.tab_order);\n }}\n />\n )}\n </div>\n ) : (\n <div className=\"text-display\">\n <img src={images.common[tab.tabIcon]} />\n {tab.title}\n </div>\n )\n }\n wrapped\n onDoubleClick={() => handleTabDoubleClick(tab.tab_order)}\n />\n ))}\n </TabList>\n </Box>\n {tabs.map(\n (tab: TabItem, index: number) =>\n tab.content && (\n <TabPanel value={index} key={tab.tab_order}>\n {value === index && tab.content}\n </TabPanel>\n ),\n )}\n </TabContext>\n </Box>\n );\n};\n\nexport default TabBarUi;\n"],"names":["TabBarUi","props","tabs","onEditTabTitle","activeTabValue","setActiveTabValue","handleTabChange","handleRemoveTab","value","setValue","useState","editableTabId","setEditableTabId","useEffect","Boolean","length","Box","children","jsxs","TabContext","jsx","TabList","className","onChange","event","newValue","map","tab","Tab","label","tab_order","TextField","title","autoFocus","onBlur","e","handleEditTabTitle","tabId","target","remove_tab","CloseIcon","style","fontSize","cursor","onClick","src","images","common","tabIcon","wrapped","onDoubleClick","handleTabDoubleClick","index","content","TabPanel"],"mappings":"8pBA8BO,MAAMA,EAAYC,IACvB,MAAMC,KAAEA,EAAAC,eAAMA,EAAAC,eAAgBA,oBAAgBC,EAAAC,gBAAmBA,EAAAC,gBAAiBA,GAAoBN,GAC/FO,EAAOC,GAAYC,EAAAA,SAAS,IAC5BC,EAAeC,GAAoBF,EAAAA,SAAwB,MAuBlE,OALAG,EAAAA,UAAU,KACJR,GAAqBS,QAAQ,MAAAZ,OAAA,EAAAA,EAAMa,WAA2BP,IAEjE,CAACN,yBAGDc,EAAAA,QAAA,CACCC,wBAAAC,EAAAA,KAACC,UAAA,CAAWX,MAAOJ,GAAkBI,EACnCS,SAAA;qBAACD,EAAAA,QAAA,CACCC,wBAAAG,EAAAA,IAACC,EAAAA,QAAA,CACCC,UAAU,6BACVC,SA5BW,CAACC,EAA6BC,KACjDhB,EAASgB,GACTpB,GAAqBA,EAAkBoB,GACvCnB,GAAmBA,KA2BVW,SAAAf,EAAKwB,IAAKC,kBACTP,EAAAA,IAACQ,EAAAA,QAAA,CACCN,UAAU,2BAEVO,MACE1B,GAAkBQ,IAAkBgB,EAAIG,yBACtCV,EAAAA,IAACW,EAAAA,UAAA,CACCvB,MAAOmB,EAAIK,MACXC,WAAS,EACTC,OAAQ,IAAMtB,EAAiB,MAC/BW,SAAWY,IACTC,OA9BpBZ,EA8BuCW,EA7BvCE,EA6B0CV,EAAIG,eA3B9C3B,GAAkBA,EAAekC,EAAOb,EAAMc,OAAO9B,QAJ5B,IACzBgB,EACAa,KAgCkB9B,iBACFW,EAAAA,KAAC,MAAA,CAAII,UAAU,cACbL,SAAA;iBAAAG,IAAC,MAAA,CAAKH,WAAIe,SACRL,EAAIY,2BACJnB,EAAAA,IAACoB,EAAAA,QAAA,CACCC,MAAO,CAAEC,SAAU,OAAQC,OAAQ,WACnCC,QAAS,KACPrC,EAAgBoB,EAAIG,gCAM5BZ,EAAAA,KAAC,MAAA,CAAII,UAAU,eACbL,SAAA;eAAAG,MAAC,OAAIyB,IAAKC,EAAAA,OAAOC,OAAOpB,EAAIqB,WAC3BrB,EAAIK,SAIXiB,SAAO,EACPC,cAAe,KAAMC,OA1DLd,EA0D0BV,EAAIG,eAzD1DlB,EAAiByB,GADU,IAACA,IA2BXV,EAAIG,gBAoChB5B,EAAKwB,IACJ,CAACC,EAAcyB,IACbzB,EAAI0B,wBACFjC,EAAAA,IAACkC,EAAAA,QAAA,CAAS9C,MAAO4C,EACdnC,SAAAT,IAAU4C,GAASzB,EAAI0B,SADG1B,EAAIG"}
|
|
@@ -8,7 +8,7 @@ interface TabItem {
|
|
|
8
8
|
remove_tab?: boolean;
|
|
9
9
|
tabIcon?: string;
|
|
10
10
|
}
|
|
11
|
-
interface
|
|
11
|
+
export interface ITabProps {
|
|
12
12
|
tabs: TabItem[];
|
|
13
13
|
activeTabValue?: number;
|
|
14
14
|
setActiveTabValue?: React.Dispatch<React.SetStateAction<number | undefined>>;
|
|
@@ -16,5 +16,5 @@ interface TabProps {
|
|
|
16
16
|
handleTabChange?: () => void;
|
|
17
17
|
handleRemoveTab?: (tabId: number) => void;
|
|
18
18
|
}
|
|
19
|
-
export
|
|
20
|
-
export
|
|
19
|
+
export declare const TabBarUi: (props: TabProps) => import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
export default TabBarUi;
|
|
@@ -11,7 +11,7 @@ import TabList from "../../../node_modules/@mui/lab/TabList/TabList/index.esm.js
|
|
|
11
11
|
import Tab from "../../../node_modules/@mui/material/Tab/Tab/index.esm.js";
|
|
12
12
|
import IconButton from "../../../node_modules/@mui/material/IconButton/IconButton/index.esm.js";
|
|
13
13
|
import TabPanel from "../../../node_modules/@mui/lab/TabPanel/TabPanel/index.esm.js";
|
|
14
|
-
|
|
14
|
+
const TabBar = (props) => {
|
|
15
15
|
const { t } = useTranslation();
|
|
16
16
|
const {
|
|
17
17
|
tabs,
|
|
@@ -68,8 +68,9 @@ function TabBar(props) {
|
|
|
68
68
|
(tab, index) => tab.content && /* @__PURE__ */ jsx(TabPanel, { value: index.toString(), children: value === index && tab.content }, tab.tab_order)
|
|
69
69
|
)
|
|
70
70
|
] }) });
|
|
71
|
-
}
|
|
71
|
+
};
|
|
72
72
|
export {
|
|
73
|
+
TabBar,
|
|
73
74
|
TabBar as default
|
|
74
75
|
};
|
|
75
76
|
//# sourceMappingURL=index.esm.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.esm.js","sources":["../../../../src/components/tabs/tabs.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-unused-vars */\n/* eslint-disable unused-imports/no-unused-vars */\nimport React, { ReactNode, useEffect, useState } from \"react\";\nimport { Box, IconButton } from \"@mui/material\";\nimport Tab from \"@mui/material/Tab\";\nimport TabContext from \"@mui/lab/TabContext\";\nimport TabList from \"@mui/lab/TabList\";\nimport TabPanel from \"@mui/lab/TabPanel\";\nimport CloseIcon from \"@mui/icons-material/Close\";\n\nimport \"./tabs.scss\";\nimport TextField from \"../text-field/text-field\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"../typography/typography\";\n\ninterface TabItem {\n tab_order: number;\n title: string;\n content?: string | ReactNode;\n data?: any;\n remove_tab?: boolean;\n}\nexport interface TabProps {\n tabs: TabItem[];\n activeValue?: number;\n setActiveValue?: React.Dispatch<React.SetStateAction<number | undefined>>;\n onEditTabTitle?: (tabId: number, newTitle: string) => void;\n handleTabChange?: () => void;\n handleRemoveTab?: (tabId: number) => void;\n isFormTabValid?: boolean ;\n isTabViewOnly?: boolean;\n activeTabs?: any[] ;\n setActiveTabs?: React.Dispatch<React.SetStateAction<number | undefined>>;\n containerProps?: any;\n}\n\nexport
|
|
1
|
+
{"version":3,"file":"index.esm.js","sources":["../../../../src/components/tabs/tabs.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-unused-vars */\n/* eslint-disable unused-imports/no-unused-vars */\nimport React, { ReactNode, useEffect, useState } from \"react\";\nimport { Box, IconButton } from \"@mui/material\";\nimport Tab from \"@mui/material/Tab\";\nimport TabContext from \"@mui/lab/TabContext\";\nimport TabList from \"@mui/lab/TabList\";\nimport TabPanel from \"@mui/lab/TabPanel\";\nimport CloseIcon from \"@mui/icons-material/Close\";\n\nimport \"./tabs.scss\";\nimport TextField from \"../text-field/text-field\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"../typography/typography\";\n\ninterface TabItem {\n tab_order: number;\n title: string;\n content?: string | ReactNode;\n data?: any;\n remove_tab?: boolean;\n}\nexport interface TabProps {\n tabs: TabItem[];\n activeValue?: number;\n setActiveValue?: React.Dispatch<React.SetStateAction<number | undefined>>;\n onEditTabTitle?: (tabId: number, newTitle: string) => void;\n handleTabChange?: () => void;\n handleRemoveTab?: (tabId: number) => void;\n isFormTabValid?: boolean ;\n isTabViewOnly?: boolean;\n activeTabs?: any[] ;\n setActiveTabs?: React.Dispatch<React.SetStateAction<number | undefined>>;\n containerProps?: any;\n}\n\nexport const TabBar = (props: TabProps) => {\n const { t } = useTranslation();\n const {\n tabs,\n onEditTabTitle,\n activeValue,\n setActiveValue,\n handleTabChange,\n handleRemoveTab,\n // isFormTabValid , \n isTabViewOnly,\n activeTabs, \n containerProps\n } = props; \n \n const [value, setValue] = useState<number>(activeValue || 0);\n const [editableTabId, setEditableTabId] = useState<number | null>(null);\n useEffect(()=>{\n activeValue && setValue(activeValue);\n\t} , [activeValue])\n\n const handleChange = (_event: React.SyntheticEvent, newValue: number) => {\n setValue(newValue);\n setActiveValue && setActiveValue(newValue);\n handleTabChange && handleTabChange();\n };\n\n const handleTabDoubleClick = (tabId: number) => {\n setEditableTabId(tabId);\n };\n\n const handleEditTabTitle = (\n event: React.ChangeEvent<HTMLInputElement>,\n tabId: number,\n ) => {\n onEditTabTitle && onEditTabTitle(tabId, event.target.value);\n };\n\n // useEffect(() => {\n // if (setActiveValue && Boolean(tabs?.length)) setActiveValue(value);\n // // eslint-disable-next-line\n // }, [tabs]);\n\n return (\n <Box mb={2} {...containerProps}>\n <TabContext value={activeValue ?? value }>\n <Box>\n <TabList className=\"account-payble-tabs-wrap\" onChange={handleChange} variant=\"scrollable\" scrollButtons=\"auto\" aria-label=\"scrollable tabs\" sx={{ overflowX: 'auto', maxWidth: '100%' }}>\n {tabs.map((tab: TabItem, index: any) => (\n <Tab\n className=\"account-payble-tab-items\"\n key={tab.tab_order}\n \n label={\n <Box display='flex' alignItems='center'>\n {\n onEditTabTitle && editableTabId === tab.tab_order ? (\n <TextField\n value={tab.title}\n autoFocus\n onBlur={() => setEditableTabId(null)}\n onChange={(e: any) =>\n handleEditTabTitle(e, tab.tab_order)\n }\n />\n ) : handleRemoveTab ? (\n <div className=\"Tabs--Title\">\n <Typography color='theme.secondary.1000' type='s3'>{t(tab.title)}</Typography>\n {!tab.remove_tab && (\n <IconButton size=\"small\" onClick={(e) => {\n e.preventDefault();\n e.stopPropagation();\n handleRemoveTab(tab.tab_order);\n }}>\n <CloseIcon style={{ fontSize: \"15px\", cursor: \"pointer\" }}/>\n </IconButton>\n )}\n </div>\n ) : (\n <Typography color='theme.secondary.1000' type='s3'>{t(tab.title)}</Typography>\n )\n }\n </Box>\n }\n wrapped\n onDoubleClick={() => handleTabDoubleClick(tab.tab_order)}\n />\n ))}\n </TabList>\n </Box>\n {tabs.map(\n (tab: TabItem, index: number) =>\n tab.content && (\n <TabPanel value={index.toString()} key={tab.tab_order}>\n {value === index && tab.content}\n </TabPanel>\n ),\n )}\n </TabContext>\n </Box>\n );\n}\n\nexport default TabBar;"],"names":["CloseIcon"],"mappings":";;;;;;;;;;;;;AAoCO,MAAM,SAAS,CAAC,UAAoB;AACzC,QAAM,EAAE,EAAA,IAAM,eAAA;AACd,QAAM;AAAA,IACJ;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IACA;AAAA,IAIA;AAAA,EAAA,IACE;AAEJ,QAAM,CAAC,OAAO,QAAQ,IAAI,SAAiB,eAAe,CAAC;AAC3D,QAAM,CAAC,eAAe,gBAAgB,IAAI,SAAwB,IAAI;AACtE,YAAU,MAAI;AACZ,mBAAe,SAAS,WAAW;AAAA,EACtC,GAAI,CAAC,WAAW,CAAC;AAEhB,QAAM,eAAe,CAAC,QAA8B,aAAqB;AACvE,aAAS,QAAQ;AACjB,sBAAkB,eAAe,QAAQ;AACzC,uBAAmB,gBAAA;AAAA,EACrB;AAEA,QAAM,uBAAuB,CAAC,UAAkB;AAC9C,qBAAiB,KAAK;AAAA,EACxB;AAEA,QAAM,qBAAqB,CACzB,OACA,UACG;AACH,sBAAkB,eAAe,OAAO,MAAM,OAAO,KAAK;AAAA,EAC5D;AAOA,SACE,oBAAC,KAAA,EAAI,IAAI,GAAI,GAAG,gBACd,UAAA,qBAAC,YAAA,EAAW,OAAO,eAAe,OAChC,UAAA;AAAA,IAAA,oBAAC,KAAA,EACC,UAAA,oBAAC,SAAA,EAAQ,WAAU,4BAA2B,UAAU,cAAc,SAAQ,cAAa,eAAc,QAAO,cAAW,mBAAkB,IAAI,EAAE,WAAW,QAAQ,UAAU,UAC7K,UAAA,KAAK,IAAI,CAAC,KAAc,UACvB;AAAA,MAAC;AAAA,MAAA;AAAA,QACC,WAAU;AAAA,QAGV,OACE,oBAAC,KAAA,EAAI,SAAQ,QAAO,YAAW,UAEzB,UAAA,kBAAkB,kBAAkB,IAAI,YACtC;AAAA,UAAC;AAAA,UAAA;AAAA,YACC,OAAO,IAAI;AAAA,YACX,WAAS;AAAA,YACT,QAAQ,MAAM,iBAAiB,IAAI;AAAA,YACnC,UAAU,CAAC,MACT,mBAAmB,GAAG,IAAI,SAAS;AAAA,UAAA;AAAA,QAAA,IAGrC,kBACF,qBAAC,OAAA,EAAI,WAAU,eACb,UAAA;AAAA,UAAA,oBAAC,YAAA,EAAW,OAAM,wBAAuB,MAAK,MAAM,UAAA,EAAE,IAAI,KAAK,EAAA,CAAE;AAAA,UAChE,CAAC,IAAI,cACJ,oBAAC,cAAW,MAAK,SAAQ,SAAS,CAAC,MAAM;AACvC,cAAE,eAAA;AACF,cAAE,gBAAA;AACF,4BAAgB,IAAI,SAAS;AAAA,UAC/B,GACE,UAAA,oBAACA,WAAA,EAAU,OAAO,EAAE,UAAU,QAAQ,QAAQ,UAAA,EAAU,CAAE,EAAA,CAC5D;AAAA,QAAA,EAAA,CAEJ,IAEA,oBAAC,YAAA,EAAW,OAAM,wBAAuB,MAAK,MAAM,UAAA,EAAE,IAAI,KAAK,EAAA,CAAE,EAAA,CAGzE;AAAA,QAEF,SAAO;AAAA,QACP,eAAe,MAAM,qBAAqB,IAAI,SAAS;AAAA,MAAA;AAAA,MAlClD,IAAI;AAAA,IAAA,CAoCZ,GACH,EAAA,CACF;AAAA,IACC,KAAK;AAAA,MACJ,CAAC,KAAc,UACb,IAAI,+BACD,UAAA,EAAS,OAAO,MAAM,SAAA,GACpB,UAAA,UAAU,SAAS,IAAI,QAAA,GADc,IAAI,SAE5C;AAAA,IAAA;AAAA,EAEN,EAAA,CACF,EAAA,CACF;AAEJ;"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),a=require("react"),t=;/* empty css */;/* empty css */var r=,/* empty css */l=require("react-i18next"),s=,/* empty css */
|
|
2
|
-
/* @__PURE__ */e.jsx(
|
|
3
|
-
/* @__PURE__ */e.jsx(s.Typography,{color:"theme.secondary.1000",type:"s3",children:b(a.title)}),!a.remove_tab&&/* @__PURE__ */e.jsx(d.default,{size:"small",onClick:e=>{e.preventDefault(),e.stopPropagation(),v(a.tab_order)},children:/* @__PURE__ */e.jsx(t.default,{style:{fontSize:"15px",cursor:"pointer"}})})]}):/* @__PURE__ */e.jsx(s.Typography,{color:"theme.secondary.1000",type:"s3",children:b(a.title)})}),wrapped:!0,onDoubleClick:()=>{return e=a.tab_order,void g(e);var e}},a.tab_order))})}),m.map((a,t)=>a.content&&/* @__PURE__ */e.jsx(c.default,{value:t.toString(),children:y===t&&a.content},a.tab_order))]})})};
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("react/jsx-runtime"),a=require("react"),t=;/* empty css */;/* empty css */var r=,/* empty css */l=require("react-i18next"),s=,/* empty css */o=,/* empty css */i=,/* empty css */n=,/* empty css */u=,/* empty css */d=,/* empty css */c=;/* empty css */const x=x=>{const{t:b}=l.useTranslation(),{tabs:m,onEditTabTitle:p,activeValue:j,setActiveValue:h,handleTabChange:f,handleRemoveTab:v,containerProps:T}=x,[y,_]=a.useState(j||0),[q,g]=a.useState(null);return a.useEffect(()=>{j&&_(j)},[j]),/* @__PURE__ */e.jsx(o.default,{mb:2,...T,children:/* @__PURE__ */e.jsxs(i.default,{value:j??y,children:[
|
|
2
|
+
/* @__PURE__ */e.jsx(o.default,{children:/* @__PURE__ */e.jsx(n.default,{className:"account-payble-tabs-wrap",onChange:(e,a)=>{_(a),h&&h(a),f&&f()},variant:"scrollable",scrollButtons:"auto","aria-label":"scrollable tabs",sx:{overflowX:"auto",maxWidth:"100%"},children:m.map((a,l)=>/* @__PURE__ */e.jsx(u.default,{className:"account-payble-tab-items",label:/* @__PURE__ */e.jsx(o.default,{display:"flex",alignItems:"center",children:p&&q===a.tab_order?/* @__PURE__ */e.jsx(r.TextField,{value:a.title,autoFocus:!0,onBlur:()=>g(null),onChange:e=>{return t=e,r=a.tab_order,void(p&&p(r,t.target.value));var t,r}}):v?/* @__PURE__ */e.jsxs("div",{className:"Tabs--Title",children:[
|
|
3
|
+
/* @__PURE__ */e.jsx(s.Typography,{color:"theme.secondary.1000",type:"s3",children:b(a.title)}),!a.remove_tab&&/* @__PURE__ */e.jsx(d.default,{size:"small",onClick:e=>{e.preventDefault(),e.stopPropagation(),v(a.tab_order)},children:/* @__PURE__ */e.jsx(t.default,{style:{fontSize:"15px",cursor:"pointer"}})})]}):/* @__PURE__ */e.jsx(s.Typography,{color:"theme.secondary.1000",type:"s3",children:b(a.title)})}),wrapped:!0,onDoubleClick:()=>{return e=a.tab_order,void g(e);var e}},a.tab_order))})}),m.map((a,t)=>a.content&&/* @__PURE__ */e.jsx(c.default,{value:t.toString(),children:y===t&&a.content},a.tab_order))]})})};exports.TabBar=x,exports.default=x;
|
|
4
4
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":["../../../../src/components/tabs/tabs.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-unused-vars */\n/* eslint-disable unused-imports/no-unused-vars */\nimport React, { ReactNode, useEffect, useState } from \"react\";\nimport { Box, IconButton } from \"@mui/material\";\nimport Tab from \"@mui/material/Tab\";\nimport TabContext from \"@mui/lab/TabContext\";\nimport TabList from \"@mui/lab/TabList\";\nimport TabPanel from \"@mui/lab/TabPanel\";\nimport CloseIcon from \"@mui/icons-material/Close\";\n\nimport \"./tabs.scss\";\nimport TextField from \"../text-field/text-field\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"../typography/typography\";\n\ninterface TabItem {\n tab_order: number;\n title: string;\n content?: string | ReactNode;\n data?: any;\n remove_tab?: boolean;\n}\nexport interface TabProps {\n tabs: TabItem[];\n activeValue?: number;\n setActiveValue?: React.Dispatch<React.SetStateAction<number | undefined>>;\n onEditTabTitle?: (tabId: number, newTitle: string) => void;\n handleTabChange?: () => void;\n handleRemoveTab?: (tabId: number) => void;\n isFormTabValid?: boolean ;\n isTabViewOnly?: boolean;\n activeTabs?: any[] ;\n setActiveTabs?: React.Dispatch<React.SetStateAction<number | undefined>>;\n containerProps?: any;\n}\n\nexport
|
|
1
|
+
{"version":3,"file":"index.js","sources":["../../../../src/components/tabs/tabs.tsx"],"sourcesContent":["/* eslint-disable @typescript-eslint/no-unused-vars */\n/* eslint-disable unused-imports/no-unused-vars */\nimport React, { ReactNode, useEffect, useState } from \"react\";\nimport { Box, IconButton } from \"@mui/material\";\nimport Tab from \"@mui/material/Tab\";\nimport TabContext from \"@mui/lab/TabContext\";\nimport TabList from \"@mui/lab/TabList\";\nimport TabPanel from \"@mui/lab/TabPanel\";\nimport CloseIcon from \"@mui/icons-material/Close\";\n\nimport \"./tabs.scss\";\nimport TextField from \"../text-field/text-field\";\nimport { useTranslation } from \"react-i18next\";\nimport Typography from \"../typography/typography\";\n\ninterface TabItem {\n tab_order: number;\n title: string;\n content?: string | ReactNode;\n data?: any;\n remove_tab?: boolean;\n}\nexport interface TabProps {\n tabs: TabItem[];\n activeValue?: number;\n setActiveValue?: React.Dispatch<React.SetStateAction<number | undefined>>;\n onEditTabTitle?: (tabId: number, newTitle: string) => void;\n handleTabChange?: () => void;\n handleRemoveTab?: (tabId: number) => void;\n isFormTabValid?: boolean ;\n isTabViewOnly?: boolean;\n activeTabs?: any[] ;\n setActiveTabs?: React.Dispatch<React.SetStateAction<number | undefined>>;\n containerProps?: any;\n}\n\nexport const TabBar = (props: TabProps) => {\n const { t } = useTranslation();\n const {\n tabs,\n onEditTabTitle,\n activeValue,\n setActiveValue,\n handleTabChange,\n handleRemoveTab,\n // isFormTabValid , \n isTabViewOnly,\n activeTabs, \n containerProps\n } = props; \n \n const [value, setValue] = useState<number>(activeValue || 0);\n const [editableTabId, setEditableTabId] = useState<number | null>(null);\n useEffect(()=>{\n activeValue && setValue(activeValue);\n\t} , [activeValue])\n\n const handleChange = (_event: React.SyntheticEvent, newValue: number) => {\n setValue(newValue);\n setActiveValue && setActiveValue(newValue);\n handleTabChange && handleTabChange();\n };\n\n const handleTabDoubleClick = (tabId: number) => {\n setEditableTabId(tabId);\n };\n\n const handleEditTabTitle = (\n event: React.ChangeEvent<HTMLInputElement>,\n tabId: number,\n ) => {\n onEditTabTitle && onEditTabTitle(tabId, event.target.value);\n };\n\n // useEffect(() => {\n // if (setActiveValue && Boolean(tabs?.length)) setActiveValue(value);\n // // eslint-disable-next-line\n // }, [tabs]);\n\n return (\n <Box mb={2} {...containerProps}>\n <TabContext value={activeValue ?? value }>\n <Box>\n <TabList className=\"account-payble-tabs-wrap\" onChange={handleChange} variant=\"scrollable\" scrollButtons=\"auto\" aria-label=\"scrollable tabs\" sx={{ overflowX: 'auto', maxWidth: '100%' }}>\n {tabs.map((tab: TabItem, index: any) => (\n <Tab\n className=\"account-payble-tab-items\"\n key={tab.tab_order}\n \n label={\n <Box display='flex' alignItems='center'>\n {\n onEditTabTitle && editableTabId === tab.tab_order ? (\n <TextField\n value={tab.title}\n autoFocus\n onBlur={() => setEditableTabId(null)}\n onChange={(e: any) =>\n handleEditTabTitle(e, tab.tab_order)\n }\n />\n ) : handleRemoveTab ? (\n <div className=\"Tabs--Title\">\n <Typography color='theme.secondary.1000' type='s3'>{t(tab.title)}</Typography>\n {!tab.remove_tab && (\n <IconButton size=\"small\" onClick={(e) => {\n e.preventDefault();\n e.stopPropagation();\n handleRemoveTab(tab.tab_order);\n }}>\n <CloseIcon style={{ fontSize: \"15px\", cursor: \"pointer\" }}/>\n </IconButton>\n )}\n </div>\n ) : (\n <Typography color='theme.secondary.1000' type='s3'>{t(tab.title)}</Typography>\n )\n }\n </Box>\n }\n wrapped\n onDoubleClick={() => handleTabDoubleClick(tab.tab_order)}\n />\n ))}\n </TabList>\n </Box>\n {tabs.map(\n (tab: TabItem, index: number) =>\n tab.content && (\n <TabPanel value={index.toString()} key={tab.tab_order}>\n {value === index && tab.content}\n </TabPanel>\n ),\n )}\n </TabContext>\n </Box>\n );\n}\n\nexport default TabBar;"],"names":["TabBar","props","t","useTranslation","tabs","onEditTabTitle","activeValue","setActiveValue","handleTabChange","handleRemoveTab","containerProps","value","setValue","useState","editableTabId","setEditableTabId","useEffect","jsx","Box","mb","children","jsxs","TabContext","TabList","className","onChange","_event","newValue","variant","scrollButtons","sx","overflowX","maxWidth","map","tab","index","Tab","label","display","alignItems","tab_order","TextField","title","autoFocus","onBlur","e","handleEditTabTitle","event","tabId","target","Typography","color","type","remove_tab","IconButton","size","onClick","preventDefault","stopPropagation","CloseIcon","style","fontSize","cursor","wrapped","onDoubleClick","handleTabDoubleClick","content","TabPanel","toString"],"mappings":"+wBAoCO,MAAMA,EAAUC,IACrB,MAAMC,EAAEA,GAAMC,oBACRC,KACJA,EAAAC,eACAA,EAAAC,YACAA,EAAAC,eACAA,EAAAC,gBACAA,EAAAC,gBACAA,EAAAC,eAIAA,GACET,GAEGU,EAAOC,GAAYC,EAAAA,SAAiBP,GAAe,IACnDQ,EAAeC,GAAoBF,EAAAA,SAAwB,MA2BlE,OA1BAG,EAAAA,UAAU,KACRV,GAAeM,EAASN,IACvB,CAACA,qBAyBFW,IAACC,EAAAA,QAAA,CAAIC,GAAI,KAAOT,EACdU,wBAAAC,EAAAA,KAACC,EAAAA,QAAA,CAAWX,MAAOL,GAAeK,EAChCS,SAAA;eAAAH,EAAAA,IAACC,EAAAA,QAAA,CACCE,wBAAAH,EAAAA,IAACM,EAAAA,QAAA,CAAQC,UAAU,2BAA2BC,SA1BjC,CAACC,EAA8BC,KAClDf,EAASe,GACTpB,GAAkBA,EAAeoB,GACjCnB,GAAmBA,KAuByDoB,QAAQ,aAAaC,cAAc,OAAO,aAAW,kBAAkBC,GAAI,CAAEC,UAAW,OAAQC,SAAU,QAC7KZ,SAAAhB,EAAK6B,IAAI,CAACC,EAAcC,mBACvBlB,EAAAA,IAACmB,EAAAA,QAAA,CACCZ,UAAU,2BAGVa,qBACEpB,EAAAA,IAACC,EAAAA,QAAA,CAAIoB,QAAQ,OAAOC,WAAW,SAEzBnB,SAAAf,GAAkBS,IAAkBoB,EAAIM,yBACtCvB,EAAAA,IAACwB,EAAAA,UAAA,CACC9B,MAAOuB,EAAIQ,MACXC,WAAS,EACTC,OAAQ,IAAM7B,EAAiB,MAC/BU,SAAWoB,IACTC,OA9B1BC,EA8B6CF,EA7B7CG,EA6BgDd,EAAIM,eA3BpDnC,GAAkBA,EAAe2C,EAAOD,EAAME,OAAOtC,QAJ5B,IACzBoC,EACAC,KAgCwBvC,iBACFY,EAAAA,KAAC,MAAA,CAAIG,UAAU,cACbJ,SAAA;eAAAH,EAAAA,IAACiC,EAAAA,WAAA,CAAWC,MAAM,uBAAuBC,KAAK,KAAMhC,SAAAlB,EAAEgC,EAAIQ,UACxDR,EAAImB,2BACJpC,EAAAA,IAACqC,EAAAA,SAAWC,KAAK,QAAQC,QAAUX,IACjCA,EAAEY,iBACFZ,EAAEa,kBACFjD,EAAgByB,EAAIM,YAEpBpB,wBAAAH,MAAC0C,EAAAA,QAAA,CAAUC,MAAO,CAAEC,SAAU,OAAQC,OAAQ,mCAKpD7C,IAACiC,EAAAA,WAAA,CAAWC,MAAM,uBAAuBC,KAAK,KAAMhC,SAAAlB,EAAEgC,EAAIQ,WAKpEqB,SAAO,EACPC,cAAe,KAAMC,OA1DLjB,EA0D0Bd,EAAIM,eAzD1DzB,EAAiBiC,GADU,IAACA,IAwBXd,EAAIM,gBAuChBpC,EAAK6B,IACJ,CAACC,EAAcC,IACbD,EAAIgC,8BACDC,EAAAA,QAAA,CAASxD,MAAOwB,EAAMiC,WACpBhD,SAAAT,IAAUwB,GAASD,EAAIgC,SADchC,EAAIM"}
|
|
@@ -20,5 +20,5 @@ export interface TabProps {
|
|
|
20
20
|
setActiveTabs?: React.Dispatch<React.SetStateAction<number | undefined>>;
|
|
21
21
|
containerProps?: any;
|
|
22
22
|
}
|
|
23
|
-
export
|
|
24
|
-
export
|
|
23
|
+
export declare const TabBar: (props: TabProps) => import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
export default TabBar;
|
package/dist/hooks/index.esm.js
CHANGED
|
@@ -4,9 +4,9 @@ import { default as default2 } from "./use-deep-memo/index.esm.js";
|
|
|
4
4
|
import { getAvailableSteelTypes, getAvailableTubeTypes, useMaterialCalculations, validateFormValues } from "./use-material-calculations/index.esm.js";
|
|
5
5
|
import { usePages } from "./use-pages/index.esm.js";
|
|
6
6
|
import { usePermissions } from "./use-permissions/index.esm.js";
|
|
7
|
-
import {
|
|
7
|
+
import { useAppTranslations } from "./use-translations/index.esm.js";
|
|
8
8
|
import { useAuth } from "./useAuth/index.esm.js";
|
|
9
|
-
import {
|
|
9
|
+
import { useNameSkuUniquenessCheck } from "./useCheckSkuAndName/index.esm.js";
|
|
10
10
|
import { useDataFetcher } from "./useDataFetcher/index.esm.js";
|
|
11
11
|
import { useLanguage } from "./useLangauge/index.esm.js";
|
|
12
12
|
import { useLanguageFallback, useLanguageState } from "./useLanguageFallback/index.esm.js";
|
|
@@ -26,7 +26,7 @@ export {
|
|
|
26
26
|
recursiveSort,
|
|
27
27
|
removeExtraKeys,
|
|
28
28
|
sortData,
|
|
29
|
-
|
|
29
|
+
useAppTranslations,
|
|
30
30
|
useAuth,
|
|
31
31
|
useDataFetcher,
|
|
32
32
|
default2 as useDeepMemo,
|
|
@@ -36,7 +36,7 @@ export {
|
|
|
36
36
|
useLocationFilter,
|
|
37
37
|
useMaterialCalculations,
|
|
38
38
|
useMultipleLocationFilters,
|
|
39
|
-
|
|
39
|
+
useNameSkuUniquenessCheck,
|
|
40
40
|
usePages,
|
|
41
41
|
usePermissions,
|
|
42
42
|
useReduxIntegration,
|
package/dist/hooks/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./apiHelper/index.js"),s=require("./common/index.js"),r=require("./use-deep-memo/index.js"),t=require("./use-material-calculations/index.js"),a=require("./use-pages/index.js"),u=require("./use-permissions/index.js"),i=require("./use-translations/index.js"),o=require("./useAuth/index.js"),
|
|
1
|
+
"use strict";Object.defineProperty(exports,"__esModule",{value:!0});var e=require("./apiHelper/index.js"),s=require("./common/index.js"),r=require("./use-deep-memo/index.js"),t=require("./use-material-calculations/index.js"),a=require("./use-pages/index.js"),u=require("./use-permissions/index.js"),i=require("./use-translations/index.js"),o=require("./useAuth/index.js"),p=require("./useCheckSkuAndName/index.js"),n=require("./useDataFetcher/index.js"),l=require("./useLangauge/index.js"),x=require("./useLanguageFallback/index.js"),c=require("./useLocationFilter/index.js"),d=require("./useReduxIntegration/index.js");exports.apiHelper=e.apiHelper,exports.apiType=s.apiType,exports.capitalizeWords=s.capitalizeWords,exports.convertEmptyToNull=s.convertEmptyToNull,exports.defaultUserCurrency=s.defaultUserCurrency,exports.formatNumber=s.formatNumber,exports.formatTime=s.formatTime,exports.formateDate=s.formateDate,exports.recursiveSort=s.recursiveSort,exports.removeExtraKeys=s.removeExtraKeys,exports.sortData=s.sortData,exports.valueWithCurrency=s.valueWithCurrency,exports.useDeepMemo=r.default,exports.getAvailableSteelTypes=t.getAvailableSteelTypes,exports.getAvailableTubeTypes=t.getAvailableTubeTypes,exports.useMaterialCalculations=t.useMaterialCalculations,exports.validateFormValues=t.validateFormValues,exports.usePages=a.usePages,exports.usePermissions=u.usePermissions,exports.useAppTranslations=i.useAppTranslations,exports.useAuth=o.useAuth,exports.useNameSkuUniquenessCheck=p.useNameSkuUniquenessCheck,exports.useDataFetcher=n.useDataFetcher,exports.useLanguage=l.useLanguage,exports.useLanguageFallback=x.useLanguageFallback,exports.useLanguageState=x.useLanguageState,exports.useLocationFilter=c.useLocationFilter,exports.useMultipleLocationFilters=c.useMultipleLocationFilters,exports.useReduxIntegration=d.useReduxIntegration;
|
|
2
2
|
//# sourceMappingURL=index.js.map
|
|
@@ -6,7 +6,7 @@ import modules from "../../constants/modules/index.esm.js";
|
|
|
6
6
|
let globalLastLoadedModules = "";
|
|
7
7
|
let globalIsLoading = false;
|
|
8
8
|
let globalInitialLoad = true;
|
|
9
|
-
|
|
9
|
+
const useAppTranslations = () => {
|
|
10
10
|
const [isLoading, setIsLoading] = useState(globalInitialLoad);
|
|
11
11
|
const location = useLocation();
|
|
12
12
|
const { t } = useTranslation();
|
|
@@ -50,8 +50,9 @@ function useAppTranslations() {
|
|
|
50
50
|
}
|
|
51
51
|
}, [location.pathname, t]);
|
|
52
52
|
return { isLoading };
|
|
53
|
-
}
|
|
53
|
+
};
|
|
54
54
|
export {
|
|
55
|
-
useAppTranslations as default
|
|
55
|
+
useAppTranslations as default,
|
|
56
|
+
useAppTranslations
|
|
56
57
|
};
|
|
57
58
|
//# sourceMappingURL=index.esm.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.esm.js","sources":["../../../src/hooks/use-translations.ts"],"sourcesContent":["import { useEffect, useState } from 'react'\r\nimport { useLocation } from 'react-router-dom'\r\nimport { useTranslation } from 'react-i18next'\r\nimport { loadModuleTranslations } from '../utils/translations'\r\nimport modules from '../constants/modules'\r\n\r\n// Global state to prevent duplicate calls across all hook instances\r\nlet globalLastLoadedModules = ''\r\nlet globalIsLoading = false\r\nlet globalInitialLoad = true\r\n\r\nexport
|
|
1
|
+
{"version":3,"file":"index.esm.js","sources":["../../../src/hooks/use-translations.ts"],"sourcesContent":["import { useEffect, useState } from 'react'\r\nimport { useLocation } from 'react-router-dom'\r\nimport { useTranslation } from 'react-i18next'\r\nimport { loadModuleTranslations } from '../utils/translations'\r\nimport modules from '../constants/modules'\r\n\r\n// Global state to prevent duplicate calls across all hook instances\r\nlet globalLastLoadedModules = ''\r\nlet globalIsLoading = false\r\nlet globalInitialLoad = true\r\n\r\nexport const useAppTranslations = () => {\r\n\tconst [isLoading, setIsLoading] = useState(globalInitialLoad)\r\n\tconst location = useLocation()\r\n\tconst { t } = useTranslation()\r\n\r\n\tuseEffect(() => {\r\n\t\tconst erpModules = modules(t)\r\n\t\tconst currentPath = location.pathname.toLowerCase()\r\n\r\n\t\tconst matchedModule = erpModules.find(\r\n\t\t\t(mod) =>\r\n\t\t\t\tmod.link.toLowerCase() === currentPath ||\r\n\t\t\t\tmod.connectedRoutes?.some((route: string) => currentPath.startsWith(route.toLowerCase()))\r\n\t\t)\r\n\r\n\t\tlet modulesToLoad: string[] = []\r\n\r\n\t\tif (matchedModule?.translationModule) {\r\n\t\t\tmodulesToLoad = [...matchedModule.translationModule, 'common']\r\n\t\t} else if (!matchedModule && currentPath === '/dashboard') {\r\n\t\t\tmodulesToLoad = ['common']\r\n\t\t}\r\n\r\n\t\tif (modulesToLoad.length > 0) {\r\n\t\t\tconst moduleKey = [...modulesToLoad].sort().join(',')\r\n\r\n\t\t\t// Skip if same modules are already loaded or currently loading\r\n\t\t\tif (globalLastLoadedModules === moduleKey || globalIsLoading) {\r\n\t\t\t\tif (globalInitialLoad) {\r\n\t\t\t\t\tsetIsLoading(false)\r\n\t\t\t\t\tglobalInitialLoad = false\r\n\t\t\t\t}\r\n\t\t\t\treturn\r\n\t\t\t}\r\n\r\n\t\t\tglobalIsLoading = true\r\n\t\t\tglobalLastLoadedModules = moduleKey\r\n\t\t\tsetIsLoading(true)\r\n\r\n\t\t\tloadModuleTranslations(modulesToLoad).finally(() => {\r\n\t\t\t\tglobalIsLoading = false\r\n\t\t\t\tsetIsLoading(false)\r\n\t\t\t\tglobalInitialLoad = false\r\n\t\t\t})\r\n\t\t} else {\r\n\t\t\t// No modules to load, but still need to handle initial load state\r\n\t\t\tif (globalInitialLoad) {\r\n\t\t\t\tsetIsLoading(false)\r\n\t\t\t\tglobalInitialLoad = false\r\n\t\t\t}\r\n\t\t}\r\n\t}, [location.pathname, t])\r\n\r\n\treturn { isLoading }\r\n};\r\n\r\nexport default useAppTranslations;\r\n"],"names":[],"mappings":";;;;;AAOA,IAAI,0BAA0B;AAC9B,IAAI,kBAAkB;AACtB,IAAI,oBAAoB;AAEjB,MAAM,qBAAqB,MAAM;AACvC,QAAM,CAAC,WAAW,YAAY,IAAI,SAAS,iBAAiB;AAC5D,QAAM,WAAW,YAAA;AACjB,QAAM,EAAE,EAAA,IAAM,eAAA;AAEd,YAAU,MAAM;AACf,UAAM,aAAa,QAAQ,CAAC;AAC5B,UAAM,cAAc,SAAS,SAAS,YAAA;AAEtC,UAAM,gBAAgB,WAAW;AAAA,MAChC,CAAC,QAAA;;AACA,mBAAI,KAAK,YAAA,MAAkB,iBAC3B,SAAI,oBAAJ,mBAAqB,KAAK,CAAC,UAAkB,YAAY,WAAW,MAAM,aAAa;AAAA;AAAA,IAAC;AAG1F,QAAI,gBAA0B,CAAA;AAE9B,QAAI,+CAAe,mBAAmB;AACrC,sBAAgB,CAAC,GAAG,cAAc,mBAAmB,QAAQ;AAAA,IAC9D,WAAW,CAAC,iBAAiB,gBAAgB,cAAc;AAC1D,sBAAgB,CAAC,QAAQ;AAAA,IAC1B;AAEA,QAAI,cAAc,SAAS,GAAG;AAC7B,YAAM,YAAY,CAAC,GAAG,aAAa,EAAE,KAAA,EAAO,KAAK,GAAG;AAGpD,UAAI,4BAA4B,aAAa,iBAAiB;AAC7D,YAAI,mBAAmB;AACtB,uBAAa,KAAK;AAClB,8BAAoB;AAAA,QACrB;AACA;AAAA,MACD;AAEA,wBAAkB;AAClB,gCAA0B;AAC1B,mBAAa,IAAI;AAEjB,6BAAuB,aAAa,EAAE,QAAQ,MAAM;AACnD,0BAAkB;AAClB,qBAAa,KAAK;AAClB,4BAAoB;AAAA,MACrB,CAAC;AAAA,IACF,OAAO;AAEN,UAAI,mBAAmB;AACtB,qBAAa,KAAK;AAClB,4BAAoB;AAAA,MACrB;AAAA,IACD;AAAA,EACD,GAAG,CAAC,SAAS,UAAU,CAAC,CAAC;AAEzB,SAAO,EAAE,UAAA;AACV;"}
|