@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,1151 @@
|
|
|
1
|
+
import { jsx, jsxs, Fragment } from "react/jsx-runtime";
|
|
2
|
+
import { useState, useCallback, createElement, useMemo, useEffect } from "react";
|
|
3
|
+
import { useNavigate, useLocation } from "react-router-dom";
|
|
4
|
+
import { useForm, useFieldArray } from "react-hook-form";
|
|
5
|
+
import { DndProvider } from "react-dnd";
|
|
6
|
+
import { HTML5Backend } from "react-dnd-html5-backend";
|
|
7
|
+
import { useTranslation } from "react-i18next";
|
|
8
|
+
import { enqueueSnackbar } from "../../../node_modules/notistack/notistack.esm/index.esm.js";
|
|
9
|
+
import { DynamicSectionHOC } from "../../../components/form-control/form-builder/form-builder-element/section/index.esm.js";
|
|
10
|
+
import { DynamicButton } from "../../../components/form-control/form-builder/form-builder-element/button/index.esm.js";
|
|
11
|
+
import { TabBar } from "../../../components/tabs/tabs/index.esm.js";
|
|
12
|
+
import { images } from "../../../images/index.esm.js";
|
|
13
|
+
import { FormHeader } from "../../../components/form-header/form-header/index.esm.js";
|
|
14
|
+
import { Typography } from "../../../components/typography/typography/index.esm.js";
|
|
15
|
+
import { formBuilderConversion } from "../../../utils/form-builder-conversion/index.esm.js";
|
|
16
|
+
import { useAppDispatch, useAppSelector } from "../../../redux/hooks/index.esm.js";
|
|
17
|
+
import { formatLabel } from "../../../utils/format-text/index.esm.js";
|
|
18
|
+
import { Toast } from "../../../components/toast/toast/index.esm.js";
|
|
19
|
+
import { Radio } from "../../../components/radio/radio/index.esm.js";
|
|
20
|
+
import { SECTION_TYPES } from "../../../utils/constant/index.esm.js";
|
|
21
|
+
import { ErpLoader } from "../../../components/loaders/erp-loader/index.esm.js";
|
|
22
|
+
import { getErrorMessage } from "../../../utils/common/index.esm.js";
|
|
23
|
+
import { FormParser } from "../../../components/form-control/form-parser/form-parser/index.esm.js";
|
|
24
|
+
import { patchFormDataById, getFormDataById, getFieldsByFormId } from "../redux/actionCreator/index.esm.js";
|
|
25
|
+
import { element } from "../field_properties/index.esm.js";
|
|
26
|
+
import { TextEditForm } from "../element-edit-forms/text/index.esm.js";
|
|
27
|
+
import { SelectEditForm } from "../element-edit-forms/select/index.esm.js";
|
|
28
|
+
import { SectionEditForm } from "../element-edit-forms/section/index.esm.js";
|
|
29
|
+
import { CheckboxEditForm } from "../element-edit-forms/checkbox/index.esm.js";
|
|
30
|
+
import TableEditForm from "../element-edit-forms/table-form/index.esm.js";
|
|
31
|
+
import FormFields from "../form-fields/index.esm.js";
|
|
32
|
+
import { generateModulePath, useFormDataEffect } from "../utils/common/index.esm.js";
|
|
33
|
+
/* empty css */
|
|
34
|
+
import Box from "../../../node_modules/@mui/material/Box/Box/index.esm.js";
|
|
35
|
+
import { EyeOff } from "../../../components/icons/eye-off/index.esm.js";
|
|
36
|
+
import { Eye } from "../../../components/icons/eye/index.esm.js";
|
|
37
|
+
import Grid from "../../../node_modules/@mui/material/Grid/Grid/index.esm.js";
|
|
38
|
+
import RadioGroup from "../../../node_modules/@mui/material/RadioGroup/RadioGroup/index.esm.js";
|
|
39
|
+
import FormControlLabel from "../../../node_modules/@mui/material/FormControlLabel/FormControlLabel/index.esm.js";
|
|
40
|
+
import Add from "../../../node_modules/@mui/icons-material/esm/Add/index.esm.js";
|
|
41
|
+
const DEFAULT_GRID_COLUMNS = 12;
|
|
42
|
+
const DEFAULT_COLUMN_WIDTH = 2;
|
|
43
|
+
const DEFAULT_TAB_TITLE = "data";
|
|
44
|
+
const isValidNumber = (value) => !isNaN(Number(value)) && isFinite(Number(value));
|
|
45
|
+
const deepClone = (obj) => JSON.parse(JSON.stringify(obj));
|
|
46
|
+
const generateUniqueId = (separator = "") => {
|
|
47
|
+
return { uniqueStringId: `${Date.now()}${separator}${Math.random().toString(36).substr(2, 9)}` };
|
|
48
|
+
};
|
|
49
|
+
function CustomForm() {
|
|
50
|
+
const { t } = useTranslation();
|
|
51
|
+
const dispatch = useAppDispatch();
|
|
52
|
+
const navigate = useNavigate();
|
|
53
|
+
const location = useLocation();
|
|
54
|
+
const rowData = location.state ?? [];
|
|
55
|
+
const formBuilder = useAppSelector((state) => state.formBuilder);
|
|
56
|
+
const { control } = useForm({
|
|
57
|
+
reValidateMode: "onBlur"
|
|
58
|
+
});
|
|
59
|
+
const {
|
|
60
|
+
fields: members,
|
|
61
|
+
append,
|
|
62
|
+
remove,
|
|
63
|
+
update,
|
|
64
|
+
move,
|
|
65
|
+
insert
|
|
66
|
+
} = useFieldArray({
|
|
67
|
+
control,
|
|
68
|
+
name: "members"
|
|
69
|
+
});
|
|
70
|
+
const {
|
|
71
|
+
fields: section,
|
|
72
|
+
append: appendSection,
|
|
73
|
+
remove: removeSection,
|
|
74
|
+
update: updateSection
|
|
75
|
+
} = useFieldArray({
|
|
76
|
+
control,
|
|
77
|
+
name: "section"
|
|
78
|
+
});
|
|
79
|
+
const [selectedHoc, setSelectedHoc] = useState("");
|
|
80
|
+
const [activeSection, setActiveSection] = useState();
|
|
81
|
+
const [activeMember, setActiveMember] = useState();
|
|
82
|
+
const [formJSON, setFormJSON] = useState([]);
|
|
83
|
+
const [elementJSON, setElementJSON] = useState(null);
|
|
84
|
+
const [positionEditedElement, setPositionEditedElement] = useState();
|
|
85
|
+
const [sectionFormJSON, setSectionFormJSON] = useState([]);
|
|
86
|
+
const [sectionJSON, setSectionJSON] = useState({});
|
|
87
|
+
const [sectionPositionEditedElement, setSectionPositionEditedElement] = useState();
|
|
88
|
+
const [removeSectionActionPerformed, setRemoveSectionActionPerformed] = useState(false);
|
|
89
|
+
const [removeSectionMembersPerformed, setRemoveSectionMembersPerformed] = useState(false);
|
|
90
|
+
const [removeSectionPosition, setRemoveSectionPosition] = useState();
|
|
91
|
+
const [initialLoading, setInitialLoading] = useState(true);
|
|
92
|
+
const [tabsData, setTabsData] = useState([]);
|
|
93
|
+
const [activeTabValue, setActiveTabValue] = useState(0);
|
|
94
|
+
const [elementSwap, setElementSwap] = useState(false);
|
|
95
|
+
const [modifyAccordion, setModifyAccordion] = useState(false);
|
|
96
|
+
const [toast, setToast] = useState(null);
|
|
97
|
+
const [previewFieldsData, setPreviewFields] = useState(null);
|
|
98
|
+
const [_, setFormParserMethods] = useState();
|
|
99
|
+
let elementPerColumn;
|
|
100
|
+
const currentModule = location.pathname.split("/")[2];
|
|
101
|
+
const path = generateModulePath(currentModule);
|
|
102
|
+
useFormDataEffect(
|
|
103
|
+
formBuilder,
|
|
104
|
+
tabsData,
|
|
105
|
+
activeTabValue,
|
|
106
|
+
{
|
|
107
|
+
removeSection,
|
|
108
|
+
remove,
|
|
109
|
+
setTabsData,
|
|
110
|
+
append,
|
|
111
|
+
appendSection
|
|
112
|
+
}
|
|
113
|
+
);
|
|
114
|
+
const pickPropertyEditForm = useCallback((type) => {
|
|
115
|
+
try {
|
|
116
|
+
if (!type || typeof type !== "string") {
|
|
117
|
+
console.warn("Invalid field type provided to pickPropertyEditForm");
|
|
118
|
+
return /* @__PURE__ */ jsx("div", { className: "text-gray-500 p-4", children: "Select a field to edit" });
|
|
119
|
+
}
|
|
120
|
+
const normalizedType = type.toLowerCase().trim();
|
|
121
|
+
const formGroups = {
|
|
122
|
+
text: [
|
|
123
|
+
"text",
|
|
124
|
+
"number",
|
|
125
|
+
"email",
|
|
126
|
+
"phone",
|
|
127
|
+
"date",
|
|
128
|
+
"time",
|
|
129
|
+
"url",
|
|
130
|
+
"currency",
|
|
131
|
+
"file",
|
|
132
|
+
"geolocation",
|
|
133
|
+
"image",
|
|
134
|
+
"relation",
|
|
135
|
+
"info",
|
|
136
|
+
"tagsinput"
|
|
137
|
+
],
|
|
138
|
+
select: ["select"],
|
|
139
|
+
section: ["section"],
|
|
140
|
+
checkbox: ["checkbox", "togglebutton", "radiobutton"],
|
|
141
|
+
table: ["table"]
|
|
142
|
+
};
|
|
143
|
+
const commonTextProps = {
|
|
144
|
+
element: elementJSON,
|
|
145
|
+
handlePropertyValueUpdate,
|
|
146
|
+
handleWidthChange,
|
|
147
|
+
handleColumnSelect,
|
|
148
|
+
fields: (formBuilder == null ? void 0 : formBuilder.fields) || []
|
|
149
|
+
};
|
|
150
|
+
const commonSelectProps = {
|
|
151
|
+
element: elementJSON,
|
|
152
|
+
handlePropertyValueUpdate,
|
|
153
|
+
handleSelectOptionValueUpdate,
|
|
154
|
+
handleWidthChange,
|
|
155
|
+
handleColumnSelect
|
|
156
|
+
};
|
|
157
|
+
if (formGroups.text.includes(normalizedType)) {
|
|
158
|
+
return /* @__PURE__ */ createElement(
|
|
159
|
+
TextEditForm,
|
|
160
|
+
{
|
|
161
|
+
...commonTextProps,
|
|
162
|
+
key: `text-form-${(elementJSON == null ? void 0 : elementJSON.id) || "default"}`
|
|
163
|
+
}
|
|
164
|
+
);
|
|
165
|
+
}
|
|
166
|
+
if (formGroups.select.includes(normalizedType)) {
|
|
167
|
+
return /* @__PURE__ */ createElement(
|
|
168
|
+
SelectEditForm,
|
|
169
|
+
{
|
|
170
|
+
...commonSelectProps,
|
|
171
|
+
key: `select-form-${(elementJSON == null ? void 0 : elementJSON.id) || "default"}`
|
|
172
|
+
}
|
|
173
|
+
);
|
|
174
|
+
}
|
|
175
|
+
if (formGroups.section.includes(normalizedType)) {
|
|
176
|
+
return /* @__PURE__ */ jsx(
|
|
177
|
+
SectionEditForm,
|
|
178
|
+
{
|
|
179
|
+
element: sectionJSON,
|
|
180
|
+
handlePropertyValueUpdate: handleSectionPropertyValueUpdate
|
|
181
|
+
},
|
|
182
|
+
`section-form-${(sectionJSON == null ? void 0 : sectionJSON.id) || "default"}`
|
|
183
|
+
);
|
|
184
|
+
}
|
|
185
|
+
if (formGroups.checkbox.includes(normalizedType)) {
|
|
186
|
+
return /* @__PURE__ */ createElement(
|
|
187
|
+
CheckboxEditForm,
|
|
188
|
+
{
|
|
189
|
+
...commonSelectProps,
|
|
190
|
+
key: `checkbox-form-${(elementJSON == null ? void 0 : elementJSON.id) || "default"}`
|
|
191
|
+
}
|
|
192
|
+
);
|
|
193
|
+
}
|
|
194
|
+
if (formGroups.table.includes(normalizedType)) {
|
|
195
|
+
return /* @__PURE__ */ jsx(
|
|
196
|
+
TableEditForm,
|
|
197
|
+
{
|
|
198
|
+
element: elementJSON,
|
|
199
|
+
handlePropertyValueUpdate,
|
|
200
|
+
handleColumnsUpdate,
|
|
201
|
+
fields: (formBuilder == null ? void 0 : formBuilder.fields) || []
|
|
202
|
+
},
|
|
203
|
+
`table-form-${(elementJSON == null ? void 0 : elementJSON.id) || "default"}`
|
|
204
|
+
);
|
|
205
|
+
}
|
|
206
|
+
console.warn(`Unknown field type: ${type}`);
|
|
207
|
+
return /* @__PURE__ */ jsxs("div", { className: "text-gray-500 p-4 border border-gray-200 rounded", children: [
|
|
208
|
+
/* @__PURE__ */ jsx("p", { className: "font-medium", children: "Unknown Field Type" }),
|
|
209
|
+
/* @__PURE__ */ jsxs("p", { className: "text-sm mt-1", children: [
|
|
210
|
+
'Field type "',
|
|
211
|
+
type,
|
|
212
|
+
'" is not supported. Please select a valid field to edit.'
|
|
213
|
+
] })
|
|
214
|
+
] });
|
|
215
|
+
} catch (error) {
|
|
216
|
+
console.error("Error in pickPropertyEditForm:", error);
|
|
217
|
+
return /* @__PURE__ */ jsxs("div", { className: "text-red-500 p-4 border border-red-200 rounded bg-red-50", children: [
|
|
218
|
+
/* @__PURE__ */ jsx("p", { className: "font-medium", children: "Error Loading Form" }),
|
|
219
|
+
/* @__PURE__ */ jsx("p", { className: "text-sm mt-1", children: "There was an error loading the property edit form. Please try again." })
|
|
220
|
+
] });
|
|
221
|
+
}
|
|
222
|
+
}, [elementJSON, sectionJSON, formBuilder]);
|
|
223
|
+
const addNewSection = useCallback(() => {
|
|
224
|
+
var _a;
|
|
225
|
+
try {
|
|
226
|
+
if (!((_a = element) == null ? void 0 : _a.section)) {
|
|
227
|
+
console.error("Element section template is not available");
|
|
228
|
+
return;
|
|
229
|
+
}
|
|
230
|
+
const { uniqueStringId: id } = generateUniqueId("-");
|
|
231
|
+
const newSection = {
|
|
232
|
+
...deepClone(element.section),
|
|
233
|
+
id
|
|
234
|
+
};
|
|
235
|
+
if (newSection.switcher_forms) {
|
|
236
|
+
newSection.switcher_forms = newSection.switcher_forms.map((form) => ({
|
|
237
|
+
...form,
|
|
238
|
+
id: generateUniqueId("-").uniqueStringId
|
|
239
|
+
}));
|
|
240
|
+
}
|
|
241
|
+
const newSectionIndex = section.length;
|
|
242
|
+
appendSection(newSection);
|
|
243
|
+
setActiveSection(newSectionIndex);
|
|
244
|
+
setSelectedHoc("section");
|
|
245
|
+
const sectionData = {
|
|
246
|
+
field_type: newSection.field_type,
|
|
247
|
+
section_type: newSection.section_type,
|
|
248
|
+
switcher_forms: newSection.switcher_forms,
|
|
249
|
+
form_switcher_label: newSection.form_switcher_label,
|
|
250
|
+
form_switcher_name: newSection.form_switcher_name,
|
|
251
|
+
label: newSection.label,
|
|
252
|
+
is_accordion: newSection.is_accordion,
|
|
253
|
+
id: newSection.id ?? newSectionIndex
|
|
254
|
+
};
|
|
255
|
+
setSectionJSON(sectionData);
|
|
256
|
+
setSectionPositionEditedElement(newSectionIndex);
|
|
257
|
+
pickPropertyEditForm(newSection.field_type);
|
|
258
|
+
} catch (error) {
|
|
259
|
+
console.error("Error adding new section:", error);
|
|
260
|
+
}
|
|
261
|
+
}, [element, section, appendSection, setActiveSection, setSelectedHoc, setSectionJSON, setSectionPositionEditedElement, pickPropertyEditForm]);
|
|
262
|
+
const handleAddTab = useCallback(() => {
|
|
263
|
+
try {
|
|
264
|
+
const formWithMembers2 = deepClone(sectionFormJSON);
|
|
265
|
+
formWithMembers2.forEach((section2, sectionIndex) => {
|
|
266
|
+
section2.members = members.filter(
|
|
267
|
+
(member) => (member == null ? void 0 : member.section_order) === sectionIndex
|
|
268
|
+
);
|
|
269
|
+
});
|
|
270
|
+
const hasSystemMembers = formWithMembers2.some(
|
|
271
|
+
(section2) => {
|
|
272
|
+
var _a;
|
|
273
|
+
return (_a = section2.members) == null ? void 0 : _a.some((member) => Boolean(member == null ? void 0 : member.is_system_field));
|
|
274
|
+
}
|
|
275
|
+
);
|
|
276
|
+
const shouldRemoveTab = !(tabsData == null ? void 0 : tabsData.length) && hasSystemMembers;
|
|
277
|
+
const newTab = {
|
|
278
|
+
tab_order: tabsData.length + 1,
|
|
279
|
+
title: DEFAULT_TAB_TITLE,
|
|
280
|
+
remove_tab: shouldRemoveTab,
|
|
281
|
+
data: (tabsData == null ? void 0 : tabsData.length) ? [] : formWithMembers2
|
|
282
|
+
};
|
|
283
|
+
setTabsData((prevTabs) => [...prevTabs, newTab]);
|
|
284
|
+
} catch (error) {
|
|
285
|
+
console.error("Error adding new tab:", error);
|
|
286
|
+
}
|
|
287
|
+
}, [sectionFormJSON, members, tabsData, setTabsData]);
|
|
288
|
+
const handleEditTabTitle = useCallback((tabId, newTitle) => {
|
|
289
|
+
try {
|
|
290
|
+
if (!isValidNumber(tabId) || !(newTitle == null ? void 0 : newTitle.trim())) {
|
|
291
|
+
console.error("Invalid tab ID or title provided");
|
|
292
|
+
return;
|
|
293
|
+
}
|
|
294
|
+
setTabsData(
|
|
295
|
+
(prevTabs) => prevTabs.map(
|
|
296
|
+
(tab) => tab.tab_order === tabId ? { ...tab, title: newTitle.trim() } : tab
|
|
297
|
+
)
|
|
298
|
+
);
|
|
299
|
+
} catch (error) {
|
|
300
|
+
console.error("Error editing tab title:", error);
|
|
301
|
+
}
|
|
302
|
+
}, [setTabsData]);
|
|
303
|
+
const handleRemoveTab = useCallback((id) => {
|
|
304
|
+
try {
|
|
305
|
+
if (!isValidNumber(id)) {
|
|
306
|
+
console.error("Invalid tab ID provided");
|
|
307
|
+
return;
|
|
308
|
+
}
|
|
309
|
+
const filteredTabs = tabsData.filter((tab) => tab.tab_order !== id);
|
|
310
|
+
const reorderedTabs = filteredTabs.map((tab) => ({
|
|
311
|
+
...tab,
|
|
312
|
+
tab_order: tab.tab_order > id ? tab.tab_order - 1 : tab.tab_order
|
|
313
|
+
}));
|
|
314
|
+
setTabsData(reorderedTabs);
|
|
315
|
+
if (activeTabValue == id) {
|
|
316
|
+
setActiveTabValue((reorderedTabs == null ? void 0 : reorderedTabs.length) - 1);
|
|
317
|
+
}
|
|
318
|
+
if (reorderedTabs.length > 0) {
|
|
319
|
+
const activeTab = reorderedTabs.find(
|
|
320
|
+
(tab) => tab.tab_order === (activeTabValue ?? 0) + 1
|
|
321
|
+
);
|
|
322
|
+
if (activeTab == null ? void 0 : activeTab.data) {
|
|
323
|
+
const sections = activeTab.data.map(
|
|
324
|
+
({ field_type, label, is_accordion, id: id2, remove_section }) => ({
|
|
325
|
+
field_type,
|
|
326
|
+
label,
|
|
327
|
+
is_accordion,
|
|
328
|
+
id: id2,
|
|
329
|
+
remove_section
|
|
330
|
+
})
|
|
331
|
+
);
|
|
332
|
+
const membersList = activeTab.data.flatMap(
|
|
333
|
+
(section2) => {
|
|
334
|
+
var _a;
|
|
335
|
+
return ((_a = section2.members) == null ? void 0 : _a.map((member) => ({ ...member }))) || [];
|
|
336
|
+
}
|
|
337
|
+
);
|
|
338
|
+
remove();
|
|
339
|
+
removeSection();
|
|
340
|
+
membersList.forEach((member) => append(member));
|
|
341
|
+
sections.forEach((section2) => appendSection(section2));
|
|
342
|
+
}
|
|
343
|
+
} else {
|
|
344
|
+
remove();
|
|
345
|
+
removeSection();
|
|
346
|
+
}
|
|
347
|
+
} catch (error) {
|
|
348
|
+
console.error("Error removing tab:", error);
|
|
349
|
+
}
|
|
350
|
+
}, [tabsData, activeTabValue, setTabsData, remove, removeSection, append, appendSection]);
|
|
351
|
+
const handleElementSelection = useCallback((e) => {
|
|
352
|
+
try {
|
|
353
|
+
const target = e.target;
|
|
354
|
+
const elementPositionIndex = target.dataset.position;
|
|
355
|
+
if (!elementPositionIndex || !isValidNumber(elementPositionIndex)) {
|
|
356
|
+
console.error("Invalid element position index");
|
|
357
|
+
return;
|
|
358
|
+
}
|
|
359
|
+
const positionIndex = Number(elementPositionIndex);
|
|
360
|
+
if (positionIndex < 0 || positionIndex >= formJSON.length) {
|
|
361
|
+
console.error("Element position index out of bounds");
|
|
362
|
+
return;
|
|
363
|
+
}
|
|
364
|
+
setActiveMember(positionIndex);
|
|
365
|
+
const elementDetails = deepClone(formJSON[positionIndex]);
|
|
366
|
+
setPositionEditedElement(positionIndex);
|
|
367
|
+
setElementJSON(elementDetails);
|
|
368
|
+
setSelectedHoc("element");
|
|
369
|
+
} catch (error) {
|
|
370
|
+
console.error("Error selecting element:", error);
|
|
371
|
+
}
|
|
372
|
+
}, [formJSON, setActiveMember, setPositionEditedElement, setElementJSON, setSelectedHoc]);
|
|
373
|
+
const handleSectionSelection = useCallback((e) => {
|
|
374
|
+
try {
|
|
375
|
+
const target = e.target;
|
|
376
|
+
const sectionPositionIndex = target.dataset.position;
|
|
377
|
+
if (!sectionPositionIndex || !isValidNumber(sectionPositionIndex)) {
|
|
378
|
+
console.error("Invalid section position index");
|
|
379
|
+
return;
|
|
380
|
+
}
|
|
381
|
+
const positionIndex = Number(sectionPositionIndex);
|
|
382
|
+
if (positionIndex < 0 || positionIndex >= sectionFormJSON.length) {
|
|
383
|
+
console.error("Section position index out of bounds");
|
|
384
|
+
return;
|
|
385
|
+
}
|
|
386
|
+
setActiveSection(positionIndex);
|
|
387
|
+
const sectionDetails = deepClone(sectionFormJSON[positionIndex]);
|
|
388
|
+
setSectionPositionEditedElement(positionIndex);
|
|
389
|
+
setSectionJSON(sectionDetails);
|
|
390
|
+
setSelectedHoc("section");
|
|
391
|
+
} catch (error) {
|
|
392
|
+
console.error("Error selecting section:", error);
|
|
393
|
+
}
|
|
394
|
+
}, [sectionFormJSON, setActiveSection, setSectionPositionEditedElement, setSectionJSON, setSelectedHoc]);
|
|
395
|
+
const handleAddMember = useCallback((e, otherProperties) => {
|
|
396
|
+
var _a, _b;
|
|
397
|
+
try {
|
|
398
|
+
const target = e.currentTarget;
|
|
399
|
+
const sectionPositionIndex = (_a = target == null ? void 0 : target.dataset) == null ? void 0 : _a.position;
|
|
400
|
+
if (sectionPositionIndex === void 0 || !isValidNumber(sectionPositionIndex)) {
|
|
401
|
+
console.error("Invalid section position index for adding member");
|
|
402
|
+
return;
|
|
403
|
+
}
|
|
404
|
+
const positionIndex = Number(sectionPositionIndex);
|
|
405
|
+
if (positionIndex < 0) {
|
|
406
|
+
console.error("Section position index cannot be negative");
|
|
407
|
+
return;
|
|
408
|
+
}
|
|
409
|
+
if (!((_b = element) == null ? void 0 : _b.text)) {
|
|
410
|
+
console.error("Element text template is not available");
|
|
411
|
+
return;
|
|
412
|
+
}
|
|
413
|
+
const newMember = {
|
|
414
|
+
...deepClone(element.text),
|
|
415
|
+
...otherProperties,
|
|
416
|
+
section_order: positionIndex,
|
|
417
|
+
type: "custom",
|
|
418
|
+
is_new: true,
|
|
419
|
+
custom_width: Math.floor(DEFAULT_GRID_COLUMNS / DEFAULT_COLUMN_WIDTH),
|
|
420
|
+
is_fullwidth: false,
|
|
421
|
+
is_system_field: Boolean(otherProperties == null ? void 0 : otherProperties.is_system_field),
|
|
422
|
+
id: generateUniqueId().uniqueStringId
|
|
423
|
+
};
|
|
424
|
+
setActiveSection(positionIndex);
|
|
425
|
+
append(newMember);
|
|
426
|
+
const elementPositionIndex = members.length;
|
|
427
|
+
setActiveMember(elementPositionIndex);
|
|
428
|
+
setSelectedHoc("element");
|
|
429
|
+
setPositionEditedElement(elementPositionIndex);
|
|
430
|
+
setElementJSON(newMember);
|
|
431
|
+
pickPropertyEditForm(newMember.field_type);
|
|
432
|
+
} catch (error) {
|
|
433
|
+
console.error("Error adding new member:", error);
|
|
434
|
+
}
|
|
435
|
+
}, [element, members, setActiveSection, append, setActiveMember, setSelectedHoc, setPositionEditedElement, setElementJSON, pickPropertyEditForm]);
|
|
436
|
+
const handleSectionPropertyValueUpdate = useCallback((e, overrideValue) => {
|
|
437
|
+
try {
|
|
438
|
+
const { name, type, checked, value } = e.target;
|
|
439
|
+
if (!name) {
|
|
440
|
+
console.error("Property name is required for update");
|
|
441
|
+
return;
|
|
442
|
+
}
|
|
443
|
+
const updatedValue = overrideValue !== void 0 ? overrideValue : type === "checkbox" ? checked : value;
|
|
444
|
+
if (sectionJSON[name] !== updatedValue) {
|
|
445
|
+
setSectionJSON((prev) => ({ ...prev, [name]: updatedValue }));
|
|
446
|
+
}
|
|
447
|
+
} catch (error) {
|
|
448
|
+
console.error("Error updating section property:", error);
|
|
449
|
+
}
|
|
450
|
+
}, [sectionJSON, setSectionJSON]);
|
|
451
|
+
const handleWidthChange = useCallback((newCustomWidth) => {
|
|
452
|
+
try {
|
|
453
|
+
if (!isValidNumber(newCustomWidth) || newCustomWidth < 1 || newCustomWidth > DEFAULT_GRID_COLUMNS) {
|
|
454
|
+
console.error("Invalid width value provided");
|
|
455
|
+
return;
|
|
456
|
+
}
|
|
457
|
+
setElementJSON((prevData) => ({
|
|
458
|
+
...prevData,
|
|
459
|
+
custom_width: newCustomWidth
|
|
460
|
+
}));
|
|
461
|
+
} catch (error) {
|
|
462
|
+
console.error("Error updating width:", error);
|
|
463
|
+
}
|
|
464
|
+
}, [setElementJSON]);
|
|
465
|
+
const handleColumnSelect = useCallback((e) => {
|
|
466
|
+
try {
|
|
467
|
+
const columnValue = Number(e.target.value);
|
|
468
|
+
if (!isValidNumber(columnValue) || columnValue <= 0) {
|
|
469
|
+
console.error("Invalid column value provided");
|
|
470
|
+
return;
|
|
471
|
+
}
|
|
472
|
+
const elementPerColumn2 = Math.floor(DEFAULT_GRID_COLUMNS / columnValue);
|
|
473
|
+
if (elementPerColumn2 <= 0) {
|
|
474
|
+
console.error("Calculated element per column is invalid");
|
|
475
|
+
return;
|
|
476
|
+
}
|
|
477
|
+
members.forEach((field, index) => {
|
|
478
|
+
update(index, { ...field, custom_width: elementPerColumn2 });
|
|
479
|
+
});
|
|
480
|
+
} catch (error) {
|
|
481
|
+
console.error("Error updating column selection:", error);
|
|
482
|
+
}
|
|
483
|
+
}, [members, update]);
|
|
484
|
+
const handlePropertyValueUpdate = useCallback((e, numberValue, val, fieldType) => {
|
|
485
|
+
var _a;
|
|
486
|
+
try {
|
|
487
|
+
const getValue = () => {
|
|
488
|
+
var _a2;
|
|
489
|
+
if (fieldType) return fieldType;
|
|
490
|
+
if (val !== void 0) return val;
|
|
491
|
+
if (numberValue !== void 0) return numberValue;
|
|
492
|
+
return (_a2 = e == null ? void 0 : e.target) == null ? void 0 : _a2.value;
|
|
493
|
+
};
|
|
494
|
+
const value = getValue();
|
|
495
|
+
const elementJSONCopy = deepClone(elementJSON);
|
|
496
|
+
if ((_a = e == null ? void 0 : e.target) == null ? void 0 : _a.name) {
|
|
497
|
+
elementJSONCopy[e.target.name] = e.target.type === "checkbox" ? e.target.checked : value;
|
|
498
|
+
}
|
|
499
|
+
if (fieldType) {
|
|
500
|
+
const { uniqueStringId: uniqueId } = generateUniqueId();
|
|
501
|
+
const copyOfUpdatedElement = {
|
|
502
|
+
...element[fieldType],
|
|
503
|
+
section_form_id: elementJSONCopy == null ? void 0 : elementJSONCopy.section_form_id,
|
|
504
|
+
is_form_switcher_section: elementJSONCopy == null ? void 0 : elementJSONCopy.is_form_switcher_section,
|
|
505
|
+
section_order: elementJSONCopy.section_order,
|
|
506
|
+
id: uniqueId,
|
|
507
|
+
type: "custom",
|
|
508
|
+
is_system_field: Boolean(elementJSONCopy == null ? void 0 : elementJSONCopy.is_system_field),
|
|
509
|
+
is_new: true,
|
|
510
|
+
column_width: (elementJSONCopy == null ? void 0 : elementJSONCopy.column_width) || 6,
|
|
511
|
+
custom_width: (elementJSONCopy == null ? void 0 : elementJSONCopy.custom_width) || 6
|
|
512
|
+
};
|
|
513
|
+
setElementJSON(copyOfUpdatedElement);
|
|
514
|
+
} else if (JSON.stringify(elementJSON) !== JSON.stringify(elementJSONCopy)) {
|
|
515
|
+
setElementJSON({ ...elementJSON, ...elementJSONCopy });
|
|
516
|
+
}
|
|
517
|
+
} catch (error) {
|
|
518
|
+
console.error("Error updating property value:", error);
|
|
519
|
+
}
|
|
520
|
+
}, [elementJSON, element, setElementJSON]);
|
|
521
|
+
const handleSelectOptionValueUpdate = useCallback((options) => {
|
|
522
|
+
try {
|
|
523
|
+
if (!Array.isArray(options)) {
|
|
524
|
+
console.error("Options must be an array");
|
|
525
|
+
return;
|
|
526
|
+
}
|
|
527
|
+
const elementJSONCopy = deepClone(elementJSON);
|
|
528
|
+
elementJSONCopy.options = [...options];
|
|
529
|
+
const { uniqueStringId: uniqueId } = generateUniqueId("-");
|
|
530
|
+
if (JSON.stringify(elementJSON.options) !== JSON.stringify(options)) {
|
|
531
|
+
setElementJSON({ ...elementJSON, ...elementJSONCopy, id: uniqueId });
|
|
532
|
+
}
|
|
533
|
+
} catch (error) {
|
|
534
|
+
console.error("Error updating select options:", error);
|
|
535
|
+
}
|
|
536
|
+
}, [elementJSON, setElementJSON]);
|
|
537
|
+
const handleColumnsUpdate = useCallback((columns) => {
|
|
538
|
+
try {
|
|
539
|
+
if (!Array.isArray(columns)) {
|
|
540
|
+
console.error("Columns must be an array");
|
|
541
|
+
return;
|
|
542
|
+
}
|
|
543
|
+
const elementJSONCopy = deepClone(elementJSON);
|
|
544
|
+
elementJSONCopy.table_columns = [...columns];
|
|
545
|
+
const { uniqueStringId: uniqueId } = generateUniqueId("-");
|
|
546
|
+
if (JSON.stringify(elementJSON.table_columns) !== JSON.stringify(columns)) {
|
|
547
|
+
setElementJSON({ ...elementJSON, ...elementJSONCopy, id: uniqueId });
|
|
548
|
+
}
|
|
549
|
+
} catch (error) {
|
|
550
|
+
console.error("Error updating table columns:", error);
|
|
551
|
+
}
|
|
552
|
+
}, [elementJSON, setElementJSON]);
|
|
553
|
+
const handleRemoveSection = useCallback((sectionIndex) => {
|
|
554
|
+
try {
|
|
555
|
+
if (!isValidNumber(sectionIndex) || sectionIndex < 0 || sectionIndex >= section.length) {
|
|
556
|
+
console.error("Invalid section index for removal");
|
|
557
|
+
return;
|
|
558
|
+
}
|
|
559
|
+
setRemoveSectionPosition(sectionIndex);
|
|
560
|
+
removeSection(sectionIndex);
|
|
561
|
+
const membersToRemove = [];
|
|
562
|
+
members.forEach((member, index) => {
|
|
563
|
+
if ((member == null ? void 0 : member.section_order) === sectionIndex) {
|
|
564
|
+
membersToRemove.push(index);
|
|
565
|
+
}
|
|
566
|
+
});
|
|
567
|
+
membersToRemove.reverse().forEach((memberIndex) => {
|
|
568
|
+
remove(memberIndex);
|
|
569
|
+
});
|
|
570
|
+
setRemoveSectionActionPerformed(true);
|
|
571
|
+
} catch (error) {
|
|
572
|
+
console.error("Error removing section:", error);
|
|
573
|
+
}
|
|
574
|
+
}, [section, members, setRemoveSectionPosition, removeSection, remove, setRemoveSectionActionPerformed]);
|
|
575
|
+
const handleMakeAccordion = useCallback((sectionIndex) => {
|
|
576
|
+
try {
|
|
577
|
+
if (!isValidNumber(sectionIndex) || sectionIndex < 0 || sectionIndex >= section.length) {
|
|
578
|
+
console.error("Invalid section index for accordion conversion");
|
|
579
|
+
return;
|
|
580
|
+
}
|
|
581
|
+
setModifyAccordion(true);
|
|
582
|
+
setSectionPositionEditedElement(sectionIndex);
|
|
583
|
+
setActiveSection(sectionIndex);
|
|
584
|
+
const copyOfSection = {
|
|
585
|
+
...deepClone(section[sectionIndex]),
|
|
586
|
+
is_accordion: true
|
|
587
|
+
};
|
|
588
|
+
updateSection(sectionIndex, copyOfSection);
|
|
589
|
+
setSelectedHoc("section");
|
|
590
|
+
setSectionJSON(copyOfSection);
|
|
591
|
+
pickPropertyEditForm(copyOfSection.field_type);
|
|
592
|
+
} catch (error) {
|
|
593
|
+
console.error("Error making section accordion:", error);
|
|
594
|
+
}
|
|
595
|
+
}, [section, setModifyAccordion, setSectionPositionEditedElement, setActiveSection, updateSection, setSelectedHoc, setSectionJSON, pickPropertyEditForm]);
|
|
596
|
+
const handleTabData = useCallback(() => {
|
|
597
|
+
try {
|
|
598
|
+
const formWithMembers2 = deepClone(sectionFormJSON);
|
|
599
|
+
formWithMembers2.forEach((section2, sectionIndex) => {
|
|
600
|
+
section2.members = members.filter(
|
|
601
|
+
(member) => (member == null ? void 0 : member.section_order) === sectionIndex
|
|
602
|
+
);
|
|
603
|
+
});
|
|
604
|
+
const hasSystemMembers = formWithMembers2.some(
|
|
605
|
+
(section2) => {
|
|
606
|
+
var _a;
|
|
607
|
+
return (_a = section2.members) == null ? void 0 : _a.some((member) => Boolean(member == null ? void 0 : member.is_system_field));
|
|
608
|
+
}
|
|
609
|
+
);
|
|
610
|
+
const activeTabIndex = Number(activeTabValue);
|
|
611
|
+
if (isValidNumber(activeTabIndex) && activeTabIndex >= 0 && activeTabIndex < tabsData.length) {
|
|
612
|
+
const updatedTabsData = [...tabsData];
|
|
613
|
+
updatedTabsData[activeTabIndex] = {
|
|
614
|
+
...updatedTabsData[activeTabIndex],
|
|
615
|
+
data: formWithMembers2,
|
|
616
|
+
remove_tab: hasSystemMembers
|
|
617
|
+
};
|
|
618
|
+
setTabsData(updatedTabsData);
|
|
619
|
+
remove();
|
|
620
|
+
removeSection();
|
|
621
|
+
setActiveMember(void 0);
|
|
622
|
+
setSelectedHoc("");
|
|
623
|
+
setActiveSection(void 0);
|
|
624
|
+
}
|
|
625
|
+
} catch (error) {
|
|
626
|
+
console.error("Error updating tab data:", error);
|
|
627
|
+
}
|
|
628
|
+
}, [sectionFormJSON, members, activeTabValue, tabsData, setTabsData]);
|
|
629
|
+
const formWithMembers = useMemo(() => {
|
|
630
|
+
if (!sectionFormJSON || !members) return null;
|
|
631
|
+
return sectionFormJSON.map((section2, sectionIndex) => ({
|
|
632
|
+
...section2,
|
|
633
|
+
members: members.filter(
|
|
634
|
+
(member) => (member == null ? void 0 : member.section_order) === sectionIndex
|
|
635
|
+
)
|
|
636
|
+
}));
|
|
637
|
+
}, [sectionFormJSON, members]);
|
|
638
|
+
const previewState = useMemo(() => {
|
|
639
|
+
if (!formWithMembers) return null;
|
|
640
|
+
return (tabsData == null ? void 0 : tabsData.length) ? { tab: tabsData } : { section: formWithMembers };
|
|
641
|
+
}, [tabsData, formWithMembers]);
|
|
642
|
+
const previewFields = useMemo(() => {
|
|
643
|
+
if (!previewState) return null;
|
|
644
|
+
return formBuilderConversion(previewState);
|
|
645
|
+
}, [previewState]);
|
|
646
|
+
const showPreview = useCallback(() => {
|
|
647
|
+
if (previewFields) {
|
|
648
|
+
setPreviewFields(previewFields);
|
|
649
|
+
}
|
|
650
|
+
}, [previewFields, setPreviewFields]);
|
|
651
|
+
const hidePreview = useCallback(() => {
|
|
652
|
+
setPreviewFields(null);
|
|
653
|
+
}, []);
|
|
654
|
+
const handleFormUpdate = useCallback(async () => {
|
|
655
|
+
var _a;
|
|
656
|
+
try {
|
|
657
|
+
if (!sectionFormJSON || !Array.isArray(sectionFormJSON)) {
|
|
658
|
+
console.warn("Invalid sectionFormJSON provided");
|
|
659
|
+
return;
|
|
660
|
+
}
|
|
661
|
+
if (!members || !Array.isArray(members)) {
|
|
662
|
+
console.warn("Invalid members array provided");
|
|
663
|
+
return;
|
|
664
|
+
}
|
|
665
|
+
if (!(rowData == null ? void 0 : rowData._id)) {
|
|
666
|
+
console.warn("Missing rowData._id for form update");
|
|
667
|
+
return;
|
|
668
|
+
}
|
|
669
|
+
let formWithMembers2;
|
|
670
|
+
try {
|
|
671
|
+
formWithMembers2 = structuredClone(sectionFormJSON);
|
|
672
|
+
} catch (cloneError) {
|
|
673
|
+
formWithMembers2 = JSON.parse(JSON.stringify(sectionFormJSON));
|
|
674
|
+
}
|
|
675
|
+
formWithMembers2.forEach((section2, sectionIndex) => {
|
|
676
|
+
if (!section2 || typeof section2 !== "object") {
|
|
677
|
+
console.warn(`Invalid section at index ${sectionIndex}`);
|
|
678
|
+
return;
|
|
679
|
+
}
|
|
680
|
+
section2.members = members.filter((member) => {
|
|
681
|
+
return member && typeof member === "object" && typeof member.section_order === "number" && member.section_order === sectionIndex;
|
|
682
|
+
});
|
|
683
|
+
});
|
|
684
|
+
const hasSystemMembers = formWithMembers2.some(
|
|
685
|
+
(section2) => {
|
|
686
|
+
var _a2;
|
|
687
|
+
return (_a2 = section2.members) == null ? void 0 : _a2.some((member) => Boolean(member == null ? void 0 : member.is_system_field));
|
|
688
|
+
}
|
|
689
|
+
);
|
|
690
|
+
const activeTabIndex = Number(activeTabValue);
|
|
691
|
+
let updatedTabsData = [...tabsData];
|
|
692
|
+
if (isValidNumber(activeTabIndex) && activeTabIndex >= 0 && activeTabIndex < tabsData.length) {
|
|
693
|
+
updatedTabsData = [...tabsData];
|
|
694
|
+
updatedTabsData[activeTabIndex] = {
|
|
695
|
+
...updatedTabsData[activeTabIndex],
|
|
696
|
+
data: formWithMembers2,
|
|
697
|
+
remove_tab: hasSystemMembers
|
|
698
|
+
};
|
|
699
|
+
setTabsData(updatedTabsData);
|
|
700
|
+
}
|
|
701
|
+
const state = (updatedTabsData == null ? void 0 : updatedTabsData.length) > 0 ? { tab: updatedTabsData } : { section: formWithMembers2 };
|
|
702
|
+
if (typeof formBuilderConversion !== "function") {
|
|
703
|
+
console.error("formBuilderConversion is not a function");
|
|
704
|
+
return;
|
|
705
|
+
}
|
|
706
|
+
let formBuilderConversionResult;
|
|
707
|
+
try {
|
|
708
|
+
formBuilderConversionResult = formBuilderConversion(state);
|
|
709
|
+
} catch (conversionError) {
|
|
710
|
+
console.error("Error during form builder conversion:", conversionError);
|
|
711
|
+
return;
|
|
712
|
+
}
|
|
713
|
+
if (!formBuilderConversionResult) {
|
|
714
|
+
console.warn("Form builder conversion returned empty result");
|
|
715
|
+
return;
|
|
716
|
+
}
|
|
717
|
+
const updatePayload = {
|
|
718
|
+
gridCol: 2,
|
|
719
|
+
fields: formBuilderConversionResult
|
|
720
|
+
};
|
|
721
|
+
const updateRes = await dispatch(
|
|
722
|
+
patchFormDataById({
|
|
723
|
+
id: rowData._id,
|
|
724
|
+
data: updatePayload
|
|
725
|
+
})
|
|
726
|
+
);
|
|
727
|
+
if (updateRes.meta.requestStatus === "rejected") {
|
|
728
|
+
const m = getErrorMessage((_a = updateRes == null ? void 0 : updateRes.error) == null ? void 0 : _a.message);
|
|
729
|
+
enqueueSnackbar(m, { variant: "error" });
|
|
730
|
+
} else {
|
|
731
|
+
enqueueSnackbar("Form updated successfully", { variant: "success" });
|
|
732
|
+
navigate(path);
|
|
733
|
+
}
|
|
734
|
+
} catch (error) {
|
|
735
|
+
const m = (error == null ? void 0 : error.message) || "Something went wrong while updating the form";
|
|
736
|
+
enqueueSnackbar(m, { variant: "error" });
|
|
737
|
+
}
|
|
738
|
+
}, [
|
|
739
|
+
sectionFormJSON,
|
|
740
|
+
members,
|
|
741
|
+
tabsData,
|
|
742
|
+
rowData == null ? void 0 : rowData._id,
|
|
743
|
+
elementPerColumn,
|
|
744
|
+
dispatch,
|
|
745
|
+
formBuilderConversion
|
|
746
|
+
]);
|
|
747
|
+
const handleDuplicateElement = (index) => {
|
|
748
|
+
const copyOfMember = { ...members[index], type: "custom" };
|
|
749
|
+
copyOfMember && insert(index + 1, copyOfMember);
|
|
750
|
+
setActiveMember(index + 1);
|
|
751
|
+
setSelectedHoc("element");
|
|
752
|
+
setPositionEditedElement(index + 1);
|
|
753
|
+
setElementJSON(copyOfMember);
|
|
754
|
+
pickPropertyEditForm(copyOfMember.field_type);
|
|
755
|
+
};
|
|
756
|
+
const breadCrumbPath = [
|
|
757
|
+
{
|
|
758
|
+
link: path,
|
|
759
|
+
label: "Forms"
|
|
760
|
+
},
|
|
761
|
+
{
|
|
762
|
+
link: "",
|
|
763
|
+
label: formatLabel(rowData == null ? void 0 : rowData.name)
|
|
764
|
+
},
|
|
765
|
+
{
|
|
766
|
+
link: "",
|
|
767
|
+
label: "Edit Form"
|
|
768
|
+
}
|
|
769
|
+
];
|
|
770
|
+
useEffect(() => {
|
|
771
|
+
if (removeSectionActionPerformed) {
|
|
772
|
+
members.forEach((member, index) => {
|
|
773
|
+
if (removeSectionPosition !== void 0 && Boolean(removeSectionPosition == null ? void 0 : removeSectionPosition.toString) && member.section_order > removeSectionPosition) {
|
|
774
|
+
update(index, { ...member, section_order: member.section_order - 1 });
|
|
775
|
+
}
|
|
776
|
+
});
|
|
777
|
+
setRemoveSectionActionPerformed(false);
|
|
778
|
+
setRemoveSectionMembersPerformed(true);
|
|
779
|
+
setRemoveSectionPosition(void 0);
|
|
780
|
+
setSelectedHoc("");
|
|
781
|
+
}
|
|
782
|
+
}, [removeSectionActionPerformed]);
|
|
783
|
+
useEffect(() => {
|
|
784
|
+
formBuilder.isSuccess && navigate(path);
|
|
785
|
+
}, [formBuilder.isSuccess]);
|
|
786
|
+
useEffect(() => {
|
|
787
|
+
if (formBuilder.isError) {
|
|
788
|
+
setToast({
|
|
789
|
+
type: "alert",
|
|
790
|
+
message: formBuilder.error
|
|
791
|
+
});
|
|
792
|
+
}
|
|
793
|
+
}, [formBuilder.error, formBuilder.isError]);
|
|
794
|
+
useEffect(() => {
|
|
795
|
+
if (typeof positionEditedElement !== "number" || typeof positionEditedElement !== "string") {
|
|
796
|
+
const index = Number(positionEditedElement);
|
|
797
|
+
if (formJSON[index]) {
|
|
798
|
+
const copyOfUpdatedFormJson = JSON.parse(
|
|
799
|
+
JSON.stringify(formJSON[index])
|
|
800
|
+
);
|
|
801
|
+
update(index, { ...copyOfUpdatedFormJson });
|
|
802
|
+
}
|
|
803
|
+
}
|
|
804
|
+
}, [formJSON]);
|
|
805
|
+
useEffect(() => {
|
|
806
|
+
const updatedFormJSON = formJSON.map((obj, index) => {
|
|
807
|
+
if (index === Number(positionEditedElement)) {
|
|
808
|
+
return { ...elementJSON };
|
|
809
|
+
} else {
|
|
810
|
+
return { ...obj };
|
|
811
|
+
}
|
|
812
|
+
});
|
|
813
|
+
setFormJSON(updatedFormJSON);
|
|
814
|
+
}, [elementJSON]);
|
|
815
|
+
useEffect(() => {
|
|
816
|
+
if (members.length !== formJSON.length) {
|
|
817
|
+
setFormJSON(JSON.parse(JSON.stringify(members)));
|
|
818
|
+
}
|
|
819
|
+
if (Boolean(elementSwap) && JSON.stringify(members) !== JSON.stringify(formJSON)) {
|
|
820
|
+
setFormJSON(JSON.parse(JSON.stringify(members)));
|
|
821
|
+
setElementSwap(false);
|
|
822
|
+
const newMember = positionEditedElement && members[positionEditedElement];
|
|
823
|
+
newMember && setSelectedHoc("element");
|
|
824
|
+
newMember && setElementJSON(newMember);
|
|
825
|
+
newMember && pickPropertyEditForm(newMember.field_type);
|
|
826
|
+
}
|
|
827
|
+
if (removeSectionMembersPerformed && JSON.stringify(members) !== JSON.stringify(formJSON)) {
|
|
828
|
+
setFormJSON(JSON.parse(JSON.stringify(members)));
|
|
829
|
+
setRemoveSectionMembersPerformed(false);
|
|
830
|
+
}
|
|
831
|
+
}, [members, elementSwap]);
|
|
832
|
+
useEffect(() => {
|
|
833
|
+
if (typeof sectionPositionEditedElement !== "number" || typeof sectionPositionEditedElement !== "string") {
|
|
834
|
+
const index = Number(sectionPositionEditedElement);
|
|
835
|
+
if (sectionFormJSON[index]) {
|
|
836
|
+
const copyOfUpdatedFormJson = JSON.parse(
|
|
837
|
+
JSON.stringify(sectionFormJSON[index])
|
|
838
|
+
);
|
|
839
|
+
updateSection(index, { ...copyOfUpdatedFormJson });
|
|
840
|
+
}
|
|
841
|
+
}
|
|
842
|
+
}, [sectionFormJSON]);
|
|
843
|
+
useEffect(() => {
|
|
844
|
+
const updatedFormJSON = sectionFormJSON.map((obj, index) => {
|
|
845
|
+
if (index === Number(sectionPositionEditedElement)) {
|
|
846
|
+
return { ...obj, ...sectionJSON };
|
|
847
|
+
} else {
|
|
848
|
+
return { ...obj };
|
|
849
|
+
}
|
|
850
|
+
});
|
|
851
|
+
setSectionFormJSON(updatedFormJSON);
|
|
852
|
+
}, [sectionJSON]);
|
|
853
|
+
useEffect(() => {
|
|
854
|
+
if (section.length !== sectionFormJSON.length) {
|
|
855
|
+
setSectionFormJSON(JSON.parse(JSON.stringify(section)));
|
|
856
|
+
}
|
|
857
|
+
if (JSON.stringify(sectionFormJSON) !== JSON.stringify(section) && modifyAccordion) {
|
|
858
|
+
setSectionFormJSON(JSON.parse(JSON.stringify(section)));
|
|
859
|
+
setModifyAccordion(false);
|
|
860
|
+
}
|
|
861
|
+
}, [section]);
|
|
862
|
+
useEffect(() => {
|
|
863
|
+
}, []);
|
|
864
|
+
const handleFormData = useCallback(async () => {
|
|
865
|
+
setInitialLoading(true);
|
|
866
|
+
try {
|
|
867
|
+
if (rowData == null ? void 0 : rowData._id) {
|
|
868
|
+
setTabsData([]);
|
|
869
|
+
await dispatch(getFormDataById(rowData == null ? void 0 : rowData._id));
|
|
870
|
+
await dispatch(getFieldsByFormId({ id: rowData == null ? void 0 : rowData._id }));
|
|
871
|
+
}
|
|
872
|
+
} finally {
|
|
873
|
+
setInitialLoading(false);
|
|
874
|
+
}
|
|
875
|
+
}, [rowData == null ? void 0 : rowData._id]);
|
|
876
|
+
useEffect(() => {
|
|
877
|
+
handleFormData();
|
|
878
|
+
}, [handleFormData]);
|
|
879
|
+
const DEFAULT_FIELD_TYPE = "text";
|
|
880
|
+
const HOC_TYPES = {
|
|
881
|
+
ELEMENT: "element",
|
|
882
|
+
SECTION: "section"
|
|
883
|
+
};
|
|
884
|
+
const hasValidContent = (obj) => {
|
|
885
|
+
return obj && Object.keys(obj).length > 0;
|
|
886
|
+
};
|
|
887
|
+
const EmptyStateMessage = () => /* @__PURE__ */ jsx(Typography, { type: "s5", color: "theme.secondary.800", className: "formSection--Text", children: "Select a field to edit its properties." });
|
|
888
|
+
const getFieldTypeWithFallback = (json, fallback = DEFAULT_FIELD_TYPE) => {
|
|
889
|
+
return (json == null ? void 0 : json.field_type) || fallback;
|
|
890
|
+
};
|
|
891
|
+
const memoizedForm = useMemo(() => {
|
|
892
|
+
if (!selectedHoc) {
|
|
893
|
+
return /* @__PURE__ */ jsx(EmptyStateMessage, {});
|
|
894
|
+
}
|
|
895
|
+
if (selectedHoc === HOC_TYPES.ELEMENT) {
|
|
896
|
+
if (!hasValidContent(members)) {
|
|
897
|
+
console.warn("Element selected but no members data available");
|
|
898
|
+
return /* @__PURE__ */ jsx(EmptyStateMessage, {});
|
|
899
|
+
}
|
|
900
|
+
const fieldType = getFieldTypeWithFallback(elementJSON);
|
|
901
|
+
return pickPropertyEditForm(fieldType);
|
|
902
|
+
}
|
|
903
|
+
if (selectedHoc === HOC_TYPES.SECTION) {
|
|
904
|
+
if (!hasValidContent(section)) {
|
|
905
|
+
console.warn("Section selected but no section data available");
|
|
906
|
+
return /* @__PURE__ */ jsx(EmptyStateMessage, {});
|
|
907
|
+
}
|
|
908
|
+
const fieldType = getFieldTypeWithFallback(sectionJSON);
|
|
909
|
+
return pickPropertyEditForm(fieldType);
|
|
910
|
+
}
|
|
911
|
+
console.warn(`Unknown selectedHoc type: ${selectedHoc}`);
|
|
912
|
+
return /* @__PURE__ */ jsx(EmptyStateMessage, {});
|
|
913
|
+
}, [
|
|
914
|
+
// Core dependencies
|
|
915
|
+
selectedHoc,
|
|
916
|
+
// Data dependencies
|
|
917
|
+
Object.keys(members).length,
|
|
918
|
+
Object.keys(section).length,
|
|
919
|
+
// JSON dependencies with deep comparison consideration
|
|
920
|
+
elementJSON == null ? void 0 : elementJSON.field_type,
|
|
921
|
+
elementJSON == null ? void 0 : elementJSON.field_properties,
|
|
922
|
+
sectionJSON == null ? void 0 : sectionJSON.field_type,
|
|
923
|
+
sectionJSON == null ? void 0 : sectionJSON.field_properties,
|
|
924
|
+
// Function dependency
|
|
925
|
+
pickPropertyEditForm
|
|
926
|
+
]);
|
|
927
|
+
return (
|
|
928
|
+
// <FullScreenLayout className="formSection--Layout">
|
|
929
|
+
/* @__PURE__ */ jsx(Box, { position: "relative", children: initialLoading ? /* @__PURE__ */ jsx(ErpLoader, {}) : /* @__PURE__ */ jsxs(DndProvider, { backend: HTML5Backend, children: [
|
|
930
|
+
/* @__PURE__ */ jsx(FormHeader, { breadCrumbPath, children: /* @__PURE__ */ jsxs("div", { className: "formSection--Buttons", children: [
|
|
931
|
+
/* @__PURE__ */ jsx(
|
|
932
|
+
DynamicButton,
|
|
933
|
+
{
|
|
934
|
+
variant: "outlined",
|
|
935
|
+
className: "formSection--PreviewButton",
|
|
936
|
+
text: "Preview",
|
|
937
|
+
onClick: () => {
|
|
938
|
+
!previewFieldsData ? showPreview() : hidePreview();
|
|
939
|
+
},
|
|
940
|
+
disable: !(members == null ? void 0 : members.length),
|
|
941
|
+
startIcon: previewFieldsData ? /* @__PURE__ */ jsx(EyeOff, {}) : /* @__PURE__ */ jsx(Eye, {})
|
|
942
|
+
}
|
|
943
|
+
),
|
|
944
|
+
/* @__PURE__ */ jsx(
|
|
945
|
+
DynamicButton,
|
|
946
|
+
{
|
|
947
|
+
variant: "contained",
|
|
948
|
+
type: "submit",
|
|
949
|
+
text: "Update",
|
|
950
|
+
onClick: handleFormUpdate,
|
|
951
|
+
disable: previewFieldsData
|
|
952
|
+
}
|
|
953
|
+
)
|
|
954
|
+
] }) }),
|
|
955
|
+
!previewFieldsData ? /* @__PURE__ */ jsxs(Grid, { className: "formSection--Grid", container: true, children: [
|
|
956
|
+
/* @__PURE__ */ jsx(
|
|
957
|
+
Grid,
|
|
958
|
+
{
|
|
959
|
+
item: true,
|
|
960
|
+
xs: 9,
|
|
961
|
+
component: "form",
|
|
962
|
+
sx: {
|
|
963
|
+
position: "relative",
|
|
964
|
+
background: "#F5F6F5",
|
|
965
|
+
padding: "0.75rem"
|
|
966
|
+
},
|
|
967
|
+
children: /* @__PURE__ */ jsxs(Grid, { className: "formSection--GridContainer", children: [
|
|
968
|
+
/* @__PURE__ */ jsxs(Box, { className: "formSection--Tab", children: [
|
|
969
|
+
tabsData && /* @__PURE__ */ jsx(
|
|
970
|
+
TabBar,
|
|
971
|
+
{
|
|
972
|
+
tabs: tabsData,
|
|
973
|
+
onEditTabTitle: handleEditTabTitle,
|
|
974
|
+
activeValue: activeTabValue,
|
|
975
|
+
setActiveValue: setActiveTabValue,
|
|
976
|
+
handleTabChange: () => {
|
|
977
|
+
handleTabData();
|
|
978
|
+
},
|
|
979
|
+
handleRemoveTab,
|
|
980
|
+
containerProps: { mb: 0 }
|
|
981
|
+
}
|
|
982
|
+
),
|
|
983
|
+
/* @__PURE__ */ jsx(
|
|
984
|
+
DynamicButton,
|
|
985
|
+
{
|
|
986
|
+
variant: "outlined",
|
|
987
|
+
text: "Add Tab",
|
|
988
|
+
onClick: handleAddTab,
|
|
989
|
+
style: { color: "#292D32", margin: "0.5rem" }
|
|
990
|
+
}
|
|
991
|
+
)
|
|
992
|
+
] }),
|
|
993
|
+
/* @__PURE__ */ jsxs("div", { className: "formSection--Form", children: [
|
|
994
|
+
section == null ? void 0 : section.map((item, i) => {
|
|
995
|
+
var _a;
|
|
996
|
+
const sectionMembers = members.filter(
|
|
997
|
+
(member) => member.section_order === i
|
|
998
|
+
);
|
|
999
|
+
const isFormSwitcher = item.section_type === SECTION_TYPES.FORM_SWITCH_SECTION;
|
|
1000
|
+
const switchForms = (_a = item == null ? void 0 : item.switcher_forms) == null ? void 0 : _a.map((form) => ({
|
|
1001
|
+
...form,
|
|
1002
|
+
formMembers: members.filter(
|
|
1003
|
+
(member) => member.section_form_id === form.id
|
|
1004
|
+
)
|
|
1005
|
+
}));
|
|
1006
|
+
return /* @__PURE__ */ jsxs(
|
|
1007
|
+
DynamicSectionHOC,
|
|
1008
|
+
{
|
|
1009
|
+
index: i,
|
|
1010
|
+
label: t(item.label),
|
|
1011
|
+
onClick: handleSectionSelection,
|
|
1012
|
+
position: i,
|
|
1013
|
+
fieldArrayName: "section",
|
|
1014
|
+
isFormSwitcher,
|
|
1015
|
+
activeIndex: activeSection === i,
|
|
1016
|
+
removeSection: () => handleRemoveSection(i),
|
|
1017
|
+
handleAccordion: () => handleMakeAccordion(i),
|
|
1018
|
+
handleAddButton: (e) => handleAddMember(e),
|
|
1019
|
+
remove_section: item.remove_section,
|
|
1020
|
+
children: [
|
|
1021
|
+
isFormSwitcher ? /* @__PURE__ */ jsxs("div", { style: { width: "100%" }, children: [
|
|
1022
|
+
/* @__PURE__ */ jsx(Typography, { type: "s5", style: { fontWeight: 500 }, color: "theme.secondary.800", children: item.form_switcher_label }),
|
|
1023
|
+
/* @__PURE__ */ jsx(
|
|
1024
|
+
RadioGroup,
|
|
1025
|
+
{
|
|
1026
|
+
"aria-labelledby": "theme-radio-buttons-group-label",
|
|
1027
|
+
name: item.form_switcher_name || item.form_switcher_label,
|
|
1028
|
+
children: switchForms == null ? void 0 : switchForms.map(({ name, id, formMembers }) => /* @__PURE__ */ jsxs(Fragment, { children: [
|
|
1029
|
+
/* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx(
|
|
1030
|
+
FormControlLabel,
|
|
1031
|
+
{
|
|
1032
|
+
value: name,
|
|
1033
|
+
control: /* @__PURE__ */ jsx(Radio, {}),
|
|
1034
|
+
label: t(name),
|
|
1035
|
+
disabled: true
|
|
1036
|
+
},
|
|
1037
|
+
id
|
|
1038
|
+
) }),
|
|
1039
|
+
/* @__PURE__ */ jsx(Grid, { container: true, sx: { mb: 3 }, children: /* @__PURE__ */ jsx(
|
|
1040
|
+
FormFields,
|
|
1041
|
+
{
|
|
1042
|
+
sectionMembers: formMembers || [],
|
|
1043
|
+
members,
|
|
1044
|
+
activeMember,
|
|
1045
|
+
control,
|
|
1046
|
+
t,
|
|
1047
|
+
element,
|
|
1048
|
+
images,
|
|
1049
|
+
elementJSON,
|
|
1050
|
+
remove,
|
|
1051
|
+
move,
|
|
1052
|
+
handleElementSelection,
|
|
1053
|
+
setElementSwap,
|
|
1054
|
+
handleDuplicateElement,
|
|
1055
|
+
setSelectedHoc,
|
|
1056
|
+
setActiveMember
|
|
1057
|
+
}
|
|
1058
|
+
) }),
|
|
1059
|
+
/* @__PURE__ */ jsx(
|
|
1060
|
+
DynamicButton,
|
|
1061
|
+
{
|
|
1062
|
+
text: "Add",
|
|
1063
|
+
variant: "outlined",
|
|
1064
|
+
className: "formSection--PreviewButton",
|
|
1065
|
+
"data-position": i,
|
|
1066
|
+
onClick: (e) => handleAddMember(e, {
|
|
1067
|
+
section_form_id: id,
|
|
1068
|
+
is_form_switcher_section: true
|
|
1069
|
+
}),
|
|
1070
|
+
startIcon: /* @__PURE__ */ jsx(Add, {})
|
|
1071
|
+
}
|
|
1072
|
+
)
|
|
1073
|
+
] }))
|
|
1074
|
+
}
|
|
1075
|
+
)
|
|
1076
|
+
] }) : null,
|
|
1077
|
+
!isFormSwitcher && /* @__PURE__ */ jsx(
|
|
1078
|
+
FormFields,
|
|
1079
|
+
{
|
|
1080
|
+
sectionMembers: sectionMembers || [],
|
|
1081
|
+
members,
|
|
1082
|
+
activeMember,
|
|
1083
|
+
control,
|
|
1084
|
+
t,
|
|
1085
|
+
element,
|
|
1086
|
+
images,
|
|
1087
|
+
elementJSON,
|
|
1088
|
+
remove,
|
|
1089
|
+
move,
|
|
1090
|
+
handleElementSelection,
|
|
1091
|
+
setElementSwap,
|
|
1092
|
+
handleDuplicateElement,
|
|
1093
|
+
setSelectedHoc,
|
|
1094
|
+
setActiveMember
|
|
1095
|
+
}
|
|
1096
|
+
)
|
|
1097
|
+
]
|
|
1098
|
+
}
|
|
1099
|
+
);
|
|
1100
|
+
}),
|
|
1101
|
+
/* @__PURE__ */ jsx("div", { className: "formSection--Section", children: /* @__PURE__ */ jsx(
|
|
1102
|
+
DynamicButton,
|
|
1103
|
+
{
|
|
1104
|
+
text: "Add a section",
|
|
1105
|
+
variant: "outlined",
|
|
1106
|
+
className: "formSection--PreviewButton",
|
|
1107
|
+
onClick: addNewSection,
|
|
1108
|
+
startIcon: /* @__PURE__ */ jsx(Add, {})
|
|
1109
|
+
}
|
|
1110
|
+
) })
|
|
1111
|
+
] })
|
|
1112
|
+
] })
|
|
1113
|
+
}
|
|
1114
|
+
),
|
|
1115
|
+
/* @__PURE__ */ jsx(
|
|
1116
|
+
Grid,
|
|
1117
|
+
{
|
|
1118
|
+
item: true,
|
|
1119
|
+
xs: 3,
|
|
1120
|
+
className: Boolean(selectedHoc) && ((members == null ? void 0 : members.length) || section.length) ? "formSection--RightGrid" : "formSection--RightGrid formSection--Text",
|
|
1121
|
+
children: memoizedForm
|
|
1122
|
+
}
|
|
1123
|
+
)
|
|
1124
|
+
] }) : /* @__PURE__ */ jsx(
|
|
1125
|
+
FormParser,
|
|
1126
|
+
{
|
|
1127
|
+
data: previewFieldsData || [],
|
|
1128
|
+
handleFormSubmit: (data) => console.log("Preview Data", data),
|
|
1129
|
+
className: "form-container",
|
|
1130
|
+
fieldArrayName: "form-builder-preview",
|
|
1131
|
+
getFormMethods: (methods) => setFormParserMethods({ ...methods })
|
|
1132
|
+
}
|
|
1133
|
+
),
|
|
1134
|
+
/* @__PURE__ */ jsx(
|
|
1135
|
+
Toast,
|
|
1136
|
+
{
|
|
1137
|
+
open: Boolean(toast),
|
|
1138
|
+
type: toast == null ? void 0 : toast.type,
|
|
1139
|
+
message: toast == null ? void 0 : toast.message,
|
|
1140
|
+
handleClose: () => setToast(null),
|
|
1141
|
+
anchorOrigin: { horizontal: "right", vertical: "bottom" }
|
|
1142
|
+
}
|
|
1143
|
+
)
|
|
1144
|
+
] }) })
|
|
1145
|
+
);
|
|
1146
|
+
}
|
|
1147
|
+
export {
|
|
1148
|
+
CustomForm,
|
|
1149
|
+
CustomForm as default
|
|
1150
|
+
};
|
|
1151
|
+
//# sourceMappingURL=index.esm.js.map
|