@gobolt/genesis 0.3.26 → 0.3.28
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/README.md +1 -1
- package/dist/bundle.css +1205 -0
- package/dist/components/Avatar/Avatar.d.ts +16 -0
- package/dist/components/Avatar/index.d.ts +2 -0
- package/dist/components/{TableWithControls/components/Tooltip → Avatar}/styles.d.ts +1 -1
- package/dist/components/Badge/index.d.ts +2 -2
- package/dist/components/Badge/styles.d.ts +3 -12
- package/dist/components/Breadcrumb/Breadcrumb.d.ts +7 -0
- package/dist/components/Breadcrumb/index.d.ts +4 -0
- package/dist/components/Breadcrumb/styles.d.ts +5 -0
- package/dist/components/Button/Button.d.ts +3 -3
- package/dist/components/Button/IconButton.d.ts +1 -1
- package/dist/components/Button/icon-button-styles.d.ts +1 -12
- package/dist/components/Button/index.d.ts +4 -4
- package/dist/components/Button/styles.d.ts +1 -16
- package/dist/components/Card/Card.d.ts +9 -0
- package/dist/components/Card/index.d.ts +2 -0
- package/dist/components/Card/styles.d.ts +6 -0
- package/dist/components/Chat/Chat.d.ts +18 -0
- package/dist/components/Chat/Message.d.ts +8 -0
- package/dist/components/Chat/index.d.ts +2 -0
- package/dist/components/Checkbox/Checkbox.d.ts +9 -0
- package/dist/components/Checkbox/index.d.ts +2 -0
- package/dist/components/Checkbox/styles.d.ts +10 -0
- package/dist/components/DatePicker/DatePicker.d.ts +4 -0
- package/dist/components/DatePicker/index.d.ts +2 -0
- package/dist/components/DateRangePicker/DateRangePicker.d.ts +4 -0
- package/dist/components/DateRangePicker/index.d.ts +2 -0
- package/dist/components/ErrorBoundary/ErrorBoundary.d.ts +19 -0
- package/dist/components/ErrorBoundary/index.d.ts +2 -0
- package/dist/components/ErrorBoundaryFallback/ErrorBoundaryFallback.d.ts +8 -0
- package/dist/components/ErrorBoundaryFallback/index.d.ts +2 -0
- package/dist/components/ErrorBoundaryFallback/styles.d.ts +1 -0
- package/dist/components/Form/Form.d.ts +25 -0
- package/dist/components/Form/index.d.ts +2 -0
- package/dist/components/Form/styles.d.ts +2 -0
- package/dist/components/Glyph/custom/UnitNumber.d.ts +5 -0
- package/dist/components/Input/Input.d.ts +4 -4
- package/dist/components/Input/index.d.ts +2 -2
- package/dist/components/Input/styles.d.ts +1 -18
- package/dist/components/Insights/BarChart/BarChart.d.ts +31 -0
- package/dist/components/Insights/BarChart/index.d.ts +2 -0
- package/dist/components/Insights/BarChart/styles.d.ts +2 -0
- package/dist/components/Insights/DonutChart/DonutChart.d.ts +19 -0
- package/dist/components/Insights/DonutChart/index.d.ts +2 -0
- package/dist/components/Insights/DonutChart/styles.d.ts +2 -0
- package/dist/components/Insights/LineChart/LineChart.d.ts +23 -0
- package/dist/components/Insights/LineChart/index.d.ts +2 -0
- package/dist/components/Insights/LineChart/styles.d.ts +2 -0
- package/dist/components/Insights/common-settings.d.ts +75 -0
- package/dist/components/Insights/index.d.ts +6 -0
- package/dist/components/Layout/Content/Content.d.ts +10 -0
- package/dist/components/Layout/Content/index.d.ts +2 -0
- package/dist/components/Layout/Content/styles.d.ts +4 -0
- package/dist/components/Layout/Layout.d.ts +8 -0
- package/dist/components/Layout/index.d.ts +2 -0
- package/dist/components/Message/Message.d.ts +14 -0
- package/dist/components/Message/index.d.ts +2 -0
- package/dist/components/Message/styles.d.ts +3 -0
- package/dist/components/Notification/Notification.d.ts +17 -0
- package/dist/components/Notification/NotificationBadge/NotificationBadge.d.ts +6 -0
- package/dist/components/Notification/NotificationBadge/icons/ASN.d.ts +2 -0
- package/dist/components/Notification/NotificationBadge/icons/Appointment.d.ts +2 -0
- package/dist/components/Notification/NotificationBadge/icons/Inventory.d.ts +2 -0
- package/dist/components/Notification/NotificationBadge/icons/Parcel.d.ts +2 -0
- package/dist/components/Notification/NotificationBadge/icons/Product.d.ts +2 -0
- package/dist/components/Notification/NotificationBadge/icons/Route.d.ts +2 -0
- package/dist/components/Notification/NotificationBadge/icons/Shipment.d.ts +2 -0
- package/dist/components/Notification/NotificationBadge/icons/ShoppingCart.d.ts +2 -0
- package/dist/components/Notification/NotificationBadge/icons/System.d.ts +2 -0
- package/dist/components/Notification/NotificationBadge/styles.d.ts +3 -0
- package/dist/components/Notification/NotificationRightChevron.d.ts +2 -0
- package/dist/components/Notification/index.d.ts +2 -0
- package/dist/components/Notification/styles.d.ts +5 -0
- package/dist/components/Popover/Popover.d.ts +10 -0
- package/dist/components/Popover/index.d.ts +2 -0
- package/dist/components/Popover/styles.d.ts +2 -0
- package/dist/components/Progress/Progress.d.ts +18 -0
- package/dist/components/Progress/Progress.util.d.ts +3 -0
- package/dist/components/Progress/ProgressText.d.ts +10 -0
- package/dist/components/Progress/index.d.ts +2 -0
- package/dist/components/Progress/styles.d.ts +4 -0
- package/dist/components/Radio/Radio.d.ts +10 -0
- package/dist/components/Radio/RadioGroup.d.ts +12 -0
- package/dist/components/Radio/index.d.ts +4 -0
- package/dist/components/Radio/states/RadioChecked.d.ts +2 -0
- package/dist/components/Radio/states/RadioCheckedDisabled.d.ts +2 -0
- package/dist/components/Radio/states/RadioCheckedFocussed.d.ts +2 -0
- package/dist/components/Radio/states/RadioCheckedHover.d.ts +2 -0
- package/dist/components/Radio/states/RadioUnchecked.d.ts +2 -0
- package/dist/components/Radio/states/RadioUncheckedDisabled.d.ts +2 -0
- package/dist/components/Radio/states/RadioUncheckedFocussed.d.ts +2 -0
- package/dist/components/Radio/states/RadioUncheckedHover.d.ts +2 -0
- package/dist/components/Row/Row.d.ts +13 -0
- package/dist/components/Row/RowActions/RowActions.d.ts +9 -0
- package/dist/components/Row/RowActions/styles.d.ts +1 -0
- package/dist/components/Row/RowLabelValue/RowLabelValue.d.ts +10 -0
- package/dist/components/Row/RowLabelValue/RowSkeleton.d.ts +3 -0
- package/dist/components/Row/RowLabelValue/styles.d.ts +5 -0
- package/dist/components/Row/index.d.ts +2 -0
- package/dist/components/Row/styles.d.ts +6 -0
- package/dist/components/SegmentedControls/SegmentedControls.d.ts +12 -0
- package/dist/components/SegmentedControls/index.d.ts +2 -0
- package/dist/components/SegmentedControls/styles.d.ts +3 -0
- package/dist/components/Select/Select.d.ts +4 -4
- package/dist/components/Select/SelectTrigger.d.ts +3 -3
- package/dist/components/Select/index.d.ts +2 -2
- package/dist/components/Shapes/Shapes.d.ts +6 -0
- package/dist/components/Shapes/index.d.ts +2 -0
- package/dist/components/Shapes/variants/Circle.d.ts +5 -0
- package/dist/components/Shapes/variants/Rectangle.d.ts +5 -0
- package/dist/components/Shapes/variants/Triangle.d.ts +5 -0
- package/dist/components/Switch/Switch.d.ts +9 -0
- package/dist/components/Switch/index.d.ts +2 -0
- package/dist/components/Switch/styles.d.ts +2 -0
- package/dist/components/Table/Table.d.ts +3 -4
- package/dist/components/Table/TableControls/CustomPagination.d.ts +2 -2
- package/dist/components/Table/TableControls/PaginationNumber.d.ts +1 -1
- package/dist/components/Table/TableControls/PrimaryTableControlsRow.d.ts +4 -2
- package/dist/components/Table/TableControls/SecondaryTableControlsRow.d.ts +1 -1
- package/dist/components/Table/TableControls/TableControls.d.ts +3 -3
- package/dist/components/Table/TableControls/index.d.ts +2 -2
- package/dist/components/Table/TablePagination.d.ts +2 -2
- package/dist/components/Table/__mocks__/table-mocks.d.ts +1 -1
- package/dist/components/Table/index.d.ts +6 -6
- package/dist/components/Table/styles.d.ts +3 -17
- package/dist/components/Table/useTable.d.ts +6 -2
- package/dist/components/TableWithControls/TableWithControls.d.ts +2 -2
- package/dist/components/TableWithControls/index.d.ts +3 -3
- package/dist/components/TableWithControls/useTableWithControls.d.ts +7 -5
- package/dist/components/Tabs/Tabs.d.ts +50 -0
- package/dist/components/Tabs/index.d.ts +2 -0
- package/dist/components/Tabs/styles.d.ts +3 -0
- package/dist/components/Tile/Tile.d.ts +10 -0
- package/dist/components/Tile/index.d.ts +2 -0
- package/dist/components/Tile/styles.d.ts +4 -0
- package/dist/components/Toast/Toast.d.ts +13 -0
- package/dist/components/Toast/index.d.ts +2 -0
- package/dist/components/Toast/styles.d.ts +3 -0
- package/dist/components/Tooltip/Tooltip.d.ts +6 -1
- package/dist/components/Tooltip/index.d.ts +2 -2
- package/dist/components/Tooltip/styles.d.ts +1 -14
- package/dist/components/Typography/Typography.d.ts +2 -2
- package/dist/components/Typography/index.d.ts +2 -2
- package/dist/components/Typography/styles.d.ts +3 -21
- package/dist/components/UtilityButton/UtilityButton.d.ts +1 -1
- package/dist/components/UtilityButton/index.d.ts +2 -2
- package/dist/components/index.d.ts +74 -7
- package/dist/index.cjs +84795 -0
- package/dist/index.d.ts +6 -10
- package/dist/index.js +84778 -9
- package/dist/providers/BreakpointProvider.d.ts +7 -0
- package/dist/providers/GenesisProvider.d.ts +7 -0
- package/dist/providers/ToastProvider.d.ts +12 -0
- package/dist/providers/index.d.ts +2 -0
- package/dist/providers/useGenesis.d.ts +7 -0
- package/dist/styles/global-styles.d.ts +1 -0
- package/dist/styles/theme/genesis-theme.d.ts +1 -79
- package/dist/styles/theme/index.d.ts +2 -2
- package/dist/types/index.d.ts +1 -0
- package/dist/utils/user-util.d.ts +2 -0
- package/package.json +25 -31
- package/dist/components/Badge/Badge.js +0 -51
- package/dist/components/Badge/index.js +0 -1
- package/dist/components/Badge/styles.js +0 -21
- package/dist/components/Button/Button.js +0 -36
- package/dist/components/Button/IconButton.js +0 -32
- package/dist/components/Button/__stories__/Button.stories.d.ts +0 -12
- package/dist/components/Button/__stories__/Button.stories.js +0 -154
- package/dist/components/Button/__stories__/IconButton.stories.d.ts +0 -8
- package/dist/components/Button/__stories__/IconButton.stories.js +0 -133
- package/dist/components/Button/__stories__/UtilityButton.stories.d.ts +0 -8
- package/dist/components/Button/__stories__/UtilityButton.stories.js +0 -71
- package/dist/components/Button/__tests__/Button.test.js +0 -19
- package/dist/components/Button/components/Button/Button.d.ts +0 -16
- package/dist/components/Button/components/Button/Button.js +0 -13
- package/dist/components/Button/components/Button/styles.d.ts +0 -1
- package/dist/components/Button/components/Button/styles.js +0 -118
- package/dist/components/Button/constants/index.d.ts +0 -163
- package/dist/components/Button/constants/index.js +0 -89
- package/dist/components/Button/icon-button-styles.js +0 -23
- package/dist/components/Button/index.js +0 -2
- package/dist/components/Button/styles.js +0 -60
- package/dist/components/Button/styles.ts +0 -176
- package/dist/components/Input/Input.js +0 -57
- package/dist/components/Input/index.js +0 -1
- package/dist/components/Input/styles.js +0 -76
- package/dist/components/Select/Select.js +0 -199
- package/dist/components/Select/SelectTrigger.js +0 -89
- package/dist/components/Select/index.js +0 -1
- package/dist/components/Table/Table/Table.d.ts +0 -51
- package/dist/components/Table/Table/Table.js +0 -14
- package/dist/components/Table/Table/TableControls/CustomPagination.d.ts +0 -13
- package/dist/components/Table/Table/TableControls/CustomPagination.js +0 -158
- package/dist/components/Table/Table/TableControls/PaginationNumber.d.ts +0 -7
- package/dist/components/Table/Table/TableControls/PaginationNumber.js +0 -30
- package/dist/components/Table/Table/styles.d.ts +0 -14
- package/dist/components/Table/Table/styles.js +0 -64
- package/dist/components/Table/Table/useTable.d.ts +0 -26
- package/dist/components/Table/Table/useTable.js +0 -141
- package/dist/components/Table/Table.js +0 -33
- package/dist/components/Table/TableControls/CustomPagination.js +0 -174
- package/dist/components/Table/TableControls/PaginationNumber.js +0 -46
- package/dist/components/Table/TableControls/PrimaryTableControlsRow.js +0 -78
- package/dist/components/Table/TableControls/SecondaryTableControlsRow.js +0 -65
- package/dist/components/Table/TableControls/TableControls.js +0 -14
- package/dist/components/Table/TableControls/TableControls.tsx +0 -51
- package/dist/components/Table/TableControls/__stories__/CustomPaginationStandalone.stories.d.ts +0 -9
- package/dist/components/Table/TableControls/__stories__/CustomPaginationStandalone.stories.js +0 -58
- package/dist/components/Table/TableControls/__stories__/PaginationNumber.stories.d.ts +0 -7
- package/dist/components/Table/TableControls/__stories__/PaginationNumber.stories.js +0 -37
- package/dist/components/Table/TableControls/__stories__/TableControls.stories.d.ts +0 -6
- package/dist/components/Table/TableControls/__stories__/TableControls.stories.js +0 -106
- package/dist/components/Table/TableControls/__tests__/CustomPagination.test.d.ts +0 -1
- package/dist/components/Table/TableControls/__tests__/CustomPagination.test.js +0 -82
- package/dist/components/Table/TableControls/__tests__/TableControls.test.d.ts +0 -1
- package/dist/components/Table/TableControls/__tests__/TableControls.test.js +0 -74
- package/dist/components/Table/TableControls/index.js +0 -1
- package/dist/components/Table/TableControls/styles.d.ts +0 -13
- package/dist/components/Table/TableControls/styles.js +0 -16
- package/dist/components/Table/TablePagination.js +0 -28
- package/dist/components/Table/Typography/Typography.d.ts +0 -17
- package/dist/components/Table/Typography/Typography.js +0 -16
- package/dist/components/Table/Typography/index.d.ts +0 -2
- package/dist/components/Table/Typography/index.js +0 -1
- package/dist/components/Table/Typography/styles.d.ts +0 -3
- package/dist/components/Table/Typography/styles.js +0 -54
- package/dist/components/Table/__mocks__/table-mocks.js +0 -310
- package/dist/components/Table/__stories__/GenesisTable.stories.d.ts +0 -5
- package/dist/components/Table/__stories__/GenesisTable.stories.js +0 -23
- package/dist/components/Table/__stories__/Table.stories.d.ts +0 -8
- package/dist/components/Table/__stories__/Table.stories.js +0 -188
- package/dist/components/Table/__tests__/table.test.d.ts +0 -1
- package/dist/components/Table/__tests__/table.test.js +0 -47
- package/dist/components/Table/index.js +0 -3
- package/dist/components/Table/styles.js +0 -20
- package/dist/components/Table/useTable.js +0 -238
- package/dist/components/TableWithControls/TableWithControls.js +0 -21
- package/dist/components/TableWithControls/__stories__/TableWithControls.stories.d.ts +0 -6
- package/dist/components/TableWithControls/__stories__/TableWithControls.stories.js +0 -178
- package/dist/components/TableWithControls/__stories__/TableWithControlsStory.d.ts +0 -1
- package/dist/components/TableWithControls/__stories__/TableWithControlsStory.js +0 -55
- package/dist/components/TableWithControls/__tests__/TableWithControls.test.d.ts +0 -1
- package/dist/components/TableWithControls/__tests__/TableWithControls.test.js +0 -41
- package/dist/components/TableWithControls/components/Badge/Badge.d.ts +0 -16
- package/dist/components/TableWithControls/components/Badge/Badge.js +0 -28
- package/dist/components/TableWithControls/components/Badge/index.d.ts +0 -2
- package/dist/components/TableWithControls/components/Badge/index.js +0 -1
- package/dist/components/TableWithControls/components/Badge/styles.d.ts +0 -4
- package/dist/components/TableWithControls/components/Badge/styles.js +0 -46
- package/dist/components/TableWithControls/components/Button/Button.d.ts +0 -16
- package/dist/components/TableWithControls/components/Button/Button.js +0 -13
- package/dist/components/TableWithControls/components/Button/IconButton.d.ts +0 -8
- package/dist/components/TableWithControls/components/Button/IconButton.js +0 -9
- package/dist/components/TableWithControls/components/Button/icon-button-styles.d.ts +0 -1
- package/dist/components/TableWithControls/components/Button/icon-button-styles.js +0 -76
- package/dist/components/TableWithControls/components/Button/index.d.ts +0 -4
- package/dist/components/TableWithControls/components/Button/index.js +0 -2
- package/dist/components/TableWithControls/components/Button/styles.d.ts +0 -1
- package/dist/components/TableWithControls/components/Button/styles.js +0 -118
- package/dist/components/TableWithControls/components/Input/Input.d.ts +0 -13
- package/dist/components/TableWithControls/components/Input/Input.js +0 -34
- package/dist/components/TableWithControls/components/Input/index.d.ts +0 -2
- package/dist/components/TableWithControls/components/Input/index.js +0 -1
- package/dist/components/TableWithControls/components/Input/styles.d.ts +0 -1
- package/dist/components/TableWithControls/components/Input/styles.js +0 -180
- package/dist/components/TableWithControls/components/Select/Select.d.ts +0 -26
- package/dist/components/TableWithControls/components/Select/Select.js +0 -175
- package/dist/components/TableWithControls/components/Select/SelectTrigger.d.ts +0 -23
- package/dist/components/TableWithControls/components/Select/SelectTrigger.js +0 -103
- package/dist/components/TableWithControls/components/Select/index.d.ts +0 -2
- package/dist/components/TableWithControls/components/Select/index.js +0 -1
- package/dist/components/TableWithControls/components/Table/Table.d.ts +0 -51
- package/dist/components/TableWithControls/components/Table/Table.js +0 -14
- package/dist/components/TableWithControls/components/Table/TableControls/CustomPagination.d.ts +0 -13
- package/dist/components/TableWithControls/components/Table/TableControls/CustomPagination.js +0 -158
- package/dist/components/TableWithControls/components/Table/TableControls/PaginationNumber.d.ts +0 -7
- package/dist/components/TableWithControls/components/Table/TableControls/PaginationNumber.js +0 -30
- package/dist/components/TableWithControls/components/Table/TableControls/PrimaryTableControlsRow.d.ts +0 -18
- package/dist/components/TableWithControls/components/Table/TableControls/PrimaryTableControlsRow.js +0 -77
- package/dist/components/TableWithControls/components/Table/TableControls/SecondaryTableControlsRow.d.ts +0 -11
- package/dist/components/TableWithControls/components/Table/TableControls/SecondaryTableControlsRow.js +0 -43
- package/dist/components/TableWithControls/components/Table/TableControls/TableControls.d.ts +0 -14
- package/dist/components/TableWithControls/components/Table/TableControls/TableControls.js +0 -13
- package/dist/components/TableWithControls/components/Table/TableControls/index.d.ts +0 -2
- package/dist/components/TableWithControls/components/Table/TableControls/index.js +0 -1
- package/dist/components/TableWithControls/components/Table/TablePagination.d.ts +0 -13
- package/dist/components/TableWithControls/components/Table/TablePagination.js +0 -11
- package/dist/components/TableWithControls/components/Table/__mocks__/table-mocks.d.ts +0 -20
- package/dist/components/TableWithControls/components/Table/__mocks__/table-mocks.js +0 -301
- package/dist/components/TableWithControls/components/Table/index.d.ts +0 -6
- package/dist/components/TableWithControls/components/Table/index.js +0 -3
- package/dist/components/TableWithControls/components/Table/styles.d.ts +0 -14
- package/dist/components/TableWithControls/components/Table/styles.js +0 -64
- package/dist/components/TableWithControls/components/Table/useTable.d.ts +0 -26
- package/dist/components/TableWithControls/components/Table/useTable.js +0 -141
- package/dist/components/TableWithControls/components/TableWithControls/TableWithControls.d.ts +0 -12
- package/dist/components/TableWithControls/components/TableWithControls/TableWithControls.js +0 -20
- package/dist/components/TableWithControls/components/TableWithControls/useTableWithControls.d.ts +0 -29
- package/dist/components/TableWithControls/components/TableWithControls/useTableWithControls.js +0 -136
- package/dist/components/TableWithControls/components/Tooltip/Tooltip.d.ts +0 -7
- package/dist/components/TableWithControls/components/Tooltip/Tooltip.js +0 -8
- package/dist/components/TableWithControls/components/Tooltip/index.d.ts +0 -2
- package/dist/components/TableWithControls/components/Tooltip/index.js +0 -1
- package/dist/components/TableWithControls/components/Tooltip/styles.js +0 -26
- package/dist/components/TableWithControls/components/Typography/Typography.d.ts +0 -17
- package/dist/components/TableWithControls/components/Typography/Typography.js +0 -16
- package/dist/components/TableWithControls/components/Typography/index.d.ts +0 -2
- package/dist/components/TableWithControls/components/Typography/index.js +0 -1
- package/dist/components/TableWithControls/components/Typography/styles.d.ts +0 -3
- package/dist/components/TableWithControls/components/Typography/styles.js +0 -54
- package/dist/components/TableWithControls/components/UtilityButton/UtilityButton.d.ts +0 -5
- package/dist/components/TableWithControls/components/UtilityButton/UtilityButton.js +0 -9
- package/dist/components/TableWithControls/components/UtilityButton/index.d.ts +0 -2
- package/dist/components/TableWithControls/components/UtilityButton/index.js +0 -1
- package/dist/components/TableWithControls/components/shared/DropdownChevron.d.ts +0 -2
- package/dist/components/TableWithControls/components/shared/DropdownChevron.js +0 -7
- package/dist/components/TableWithControls/constants/index.d.ts +0 -163
- package/dist/components/TableWithControls/constants/index.js +0 -89
- package/dist/components/TableWithControls/index.js +0 -2
- package/dist/components/TableWithControls/types/events.d.ts +0 -22
- package/dist/components/TableWithControls/types/events.js +0 -1
- package/dist/components/TableWithControls/useTableWithControls.js +0 -117
- package/dist/components/TableWithControls/utils/icon-util.d.ts +0 -3
- package/dist/components/TableWithControls/utils/icon-util.js +0 -116
- package/dist/components/Tooltip/Tooltip.js +0 -9
- package/dist/components/Tooltip/index.js +0 -1
- package/dist/components/Tooltip/styles.js +0 -17
- package/dist/components/Typography/Typography.js +0 -39
- package/dist/components/Typography/index.js +0 -1
- package/dist/components/Typography/styles.js +0 -37
- package/dist/components/UtilityButton/UtilityButton.js +0 -32
- package/dist/components/UtilityButton/components/Button/Button.d.ts +0 -16
- package/dist/components/UtilityButton/components/Button/Button.js +0 -13
- package/dist/components/UtilityButton/components/Button/IconButton.d.ts +0 -8
- package/dist/components/UtilityButton/components/Button/IconButton.js +0 -9
- package/dist/components/UtilityButton/components/Button/icon-button-styles.d.ts +0 -1
- package/dist/components/UtilityButton/components/Button/icon-button-styles.js +0 -76
- package/dist/components/UtilityButton/components/Button/index.d.ts +0 -4
- package/dist/components/UtilityButton/components/Button/index.js +0 -2
- package/dist/components/UtilityButton/components/Button/styles.d.ts +0 -1
- package/dist/components/UtilityButton/components/Button/styles.js +0 -118
- package/dist/components/UtilityButton/components/UtilityButton/UtilityButton.d.ts +0 -5
- package/dist/components/UtilityButton/components/UtilityButton/UtilityButton.js +0 -9
- package/dist/components/UtilityButton/constants/index.d.ts +0 -163
- package/dist/components/UtilityButton/constants/index.js +0 -89
- package/dist/components/UtilityButton/index.js +0 -1
- package/dist/components/index.js +0 -7
- package/dist/components/shared/DropdownChevron.js +0 -18
- package/dist/constants/index.js +0 -89
- package/dist/interface/address.d.ts +0 -10
- package/dist/interface/address.js +0 -1
- package/dist/interface/appointment.d.ts +0 -56
- package/dist/interface/appointment.js +0 -23
- package/dist/styles/design-tokens/variables.d.ts +0 -706
- package/dist/styles/design-tokens/variables.js +0 -707
- package/dist/styles/theme/genesis-theme.js +0 -1512
- package/dist/styles/theme/genesis-theme.types.d.ts +0 -263
- package/dist/styles/theme/genesis-theme.types.js +0 -6
- package/dist/styles/theme/index.js +0 -1
- package/dist/test/setup.d.ts +0 -6
- package/dist/test/setup.js +0 -53
- package/dist/test/setup.types.d.ts +0 -7
- package/dist/test/setup.types.js +0 -1
- package/dist/types/events.d.ts +0 -22
- package/dist/types/events.js +0 -1
- package/dist/utils/icon-util.js +0 -119
- package/dist/utils/styled.d.ts +0 -1
- package/dist/utils/styled.js +0 -44
- /package/dist/{components/Button/__tests__/Button.test.d.ts → styles/theme/genesis-theme.test.d.ts} +0 -0
package/dist/components/TableWithControls/components/Table/TableControls/PrimaryTableControlsRow.js
DELETED
|
@@ -1,77 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import UtilityButton from "../../UtilityButton";
|
|
3
|
-
import IconButton from "../../Button/IconButton";
|
|
4
|
-
import Select from "../../Select";
|
|
5
|
-
import Typography from "../../Typography";
|
|
6
|
-
import Input from "../../Input";
|
|
7
|
-
import { HiMiniAdjustmentsVertical } from "react-icons/hi2";
|
|
8
|
-
import { HiSearch } from "react-icons/hi";
|
|
9
|
-
import { HiOutlineSortAscending, HiOutlineSortDescending, } from "react-icons/hi";
|
|
10
|
-
import { FiSettings } from "react-icons/fi";
|
|
11
|
-
const PrimaryTableControlsRow = ({ sortOptions, searchByPlaceholder = "", searchField = "address", isSortedAscending = true, searchValue = "", selectedSortOption = "", onChange, }) => {
|
|
12
|
-
const onInputChange = (actionEvent) => {
|
|
13
|
-
onChange?.({
|
|
14
|
-
event: "inputChange",
|
|
15
|
-
payload: actionEvent.payload,
|
|
16
|
-
});
|
|
17
|
-
};
|
|
18
|
-
const onSortChange = (value) => {
|
|
19
|
-
const sortActionEvent = {
|
|
20
|
-
event: "primarySortChange",
|
|
21
|
-
payload: { value },
|
|
22
|
-
};
|
|
23
|
-
onChange?.(sortActionEvent);
|
|
24
|
-
};
|
|
25
|
-
const onFilterClick = () => {
|
|
26
|
-
const filterActionEvent = {
|
|
27
|
-
event: "filterClick",
|
|
28
|
-
payload: {},
|
|
29
|
-
};
|
|
30
|
-
onChange?.(filterActionEvent);
|
|
31
|
-
};
|
|
32
|
-
const onSettingsClick = () => {
|
|
33
|
-
const settingsActionEvent = {
|
|
34
|
-
event: "settingsClick",
|
|
35
|
-
payload: {},
|
|
36
|
-
};
|
|
37
|
-
onChange?.(settingsActionEvent);
|
|
38
|
-
};
|
|
39
|
-
const onOrderClick = () => {
|
|
40
|
-
const ascendingActionEvent = {
|
|
41
|
-
event: "orderClick",
|
|
42
|
-
payload: {
|
|
43
|
-
value: isSortedAscending ? "desc" : "asc",
|
|
44
|
-
},
|
|
45
|
-
};
|
|
46
|
-
onChange?.(ascendingActionEvent);
|
|
47
|
-
};
|
|
48
|
-
return (_jsxs("div", { style: {
|
|
49
|
-
display: "flex",
|
|
50
|
-
justifyContent: "space-between",
|
|
51
|
-
alignItems: "center",
|
|
52
|
-
width: "100%",
|
|
53
|
-
minWidth: 800,
|
|
54
|
-
marginBottom: 16,
|
|
55
|
-
}, children: [_jsxs("div", { style: { display: "flex" }, children: [_jsx(Input, { size: "normal", placeholder: searchByPlaceholder, prefix: _jsx(HiSearch, {}), style: {
|
|
56
|
-
padding: "5px 8px",
|
|
57
|
-
}, value: searchValue, onChange: onInputChange }), onFilterClick && (_jsx("div", { style: { marginLeft: 16 }, children: _jsx(UtilityButton, { isIconButton: true, icon: _jsx(HiMiniAdjustmentsVertical, { color: "#222222" }), onClick: onFilterClick }) })), onSettingsClick && (_jsx("div", { style: { marginLeft: 16 }, children: _jsx(UtilityButton, { isIconButton: true, icon: _jsx(FiSettings, { color: "#222222" }), onClick: onSettingsClick }) }))] }), _jsxs("div", { style: {
|
|
58
|
-
display: "flex",
|
|
59
|
-
alignItems: "center",
|
|
60
|
-
width: 300,
|
|
61
|
-
justifyContent: "flex-end",
|
|
62
|
-
marginLeft: "auto",
|
|
63
|
-
}, children: [_jsx(Typography, { variant: "body1", color: "#6C6C6C", style: {
|
|
64
|
-
width: 70,
|
|
65
|
-
flexShrink: 0,
|
|
66
|
-
textAlign: "right",
|
|
67
|
-
paddingRight: 4,
|
|
68
|
-
marginRight: 8,
|
|
69
|
-
}, children: "Sort by" }), sortOptions && onSortChange ? (_jsx(Select, { options: sortOptions, defaultValue: sortOptions[0].value, value: selectedSortOption, variant: "simple", onChange: onSortChange, style: {
|
|
70
|
-
width: 180,
|
|
71
|
-
flexShrink: 0,
|
|
72
|
-
} })) : null, _jsx("div", { style: {
|
|
73
|
-
marginLeft: 8,
|
|
74
|
-
flexShrink: 0,
|
|
75
|
-
}, children: _jsx(IconButton, { icon: isSortedAscending ? (_jsx(HiOutlineSortDescending, { size: 20 })) : (_jsx(HiOutlineSortAscending, { size: 20 })), onClick: onOrderClick }) })] })] }));
|
|
76
|
-
};
|
|
77
|
-
export default PrimaryTableControlsRow;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import type { Change } from "../Table";
|
|
2
|
-
export type Groups = {
|
|
3
|
-
[key: string]: string[];
|
|
4
|
-
};
|
|
5
|
-
export interface SecondaryTableControlsRowProps {
|
|
6
|
-
groups: Groups | null;
|
|
7
|
-
totalRecords: number | null;
|
|
8
|
-
onChange?: Change;
|
|
9
|
-
}
|
|
10
|
-
declare const SecondaryTableControlsRow: ({ groups, totalRecords, onChange, }: SecondaryTableControlsRowProps) => import("react/jsx-runtime").JSX.Element;
|
|
11
|
-
export default SecondaryTableControlsRow;
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, Fragment as _Fragment, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import Badge from "../../Badge";
|
|
3
|
-
import Typography from "../../Typography";
|
|
4
|
-
import Tooltip from "../../Tooltip";
|
|
5
|
-
import { getIcon } from "../../../utils/icon-util";
|
|
6
|
-
const GroupItem = ({ title, items, onGroupItemClick }) => {
|
|
7
|
-
if (items.length === 0)
|
|
8
|
-
return null;
|
|
9
|
-
return (_jsxs(_Fragment, { children: [_jsx(Tooltip, { tip: title, children: _jsx("div", { style: {
|
|
10
|
-
display: "flex",
|
|
11
|
-
justifyContent: "center",
|
|
12
|
-
alignItems: "center",
|
|
13
|
-
width: 24,
|
|
14
|
-
height: 24,
|
|
15
|
-
}, children: getIcon(title) }) }), _jsx("div", { style: { display: "flex", gap: 4 }, children: items.map((item) => (_jsx(Badge, { label: item, hasClose: true, state: "generic", size: "small", onClick: () => onGroupItemClick(title, item) }, item.toString()))) })] }));
|
|
16
|
-
};
|
|
17
|
-
const GroupsRow = ({ groups, onGroupItemClick }) => {
|
|
18
|
-
if (!groups)
|
|
19
|
-
return null;
|
|
20
|
-
const groupArray = Object.entries(groups).map(([title, items]) => ({
|
|
21
|
-
title,
|
|
22
|
-
items,
|
|
23
|
-
}));
|
|
24
|
-
return (_jsx("div", { style: { display: "flex", gap: 4 }, children: groupArray.length > 0
|
|
25
|
-
? groupArray.map((group) => (_jsx(GroupItem, { title: group.title, items: group.items, onGroupItemClick: onGroupItemClick }, group.title)))
|
|
26
|
-
: null }));
|
|
27
|
-
};
|
|
28
|
-
const SecondaryTableControlsRow = ({ groups, totalRecords, onChange, }) => {
|
|
29
|
-
const onGroupItemClick = (title, item) => {
|
|
30
|
-
const groupItemClickEvent = {
|
|
31
|
-
event: "groupItemClick",
|
|
32
|
-
payload: { title, item },
|
|
33
|
-
};
|
|
34
|
-
onChange?.(groupItemClickEvent);
|
|
35
|
-
};
|
|
36
|
-
return (_jsxs("div", { style: {
|
|
37
|
-
display: "flex",
|
|
38
|
-
justifyContent: "space-between",
|
|
39
|
-
alignItems: "flex-end",
|
|
40
|
-
marginTop: 8,
|
|
41
|
-
}, children: [_jsx(GroupsRow, { groups: groups, onGroupItemClick: onGroupItemClick }), totalRecords > 0 ? (_jsx(Typography, { variant: "body2", color: "#6C6C6C", children: `${totalRecords} results` })) : null] }));
|
|
42
|
-
};
|
|
43
|
-
export default SecondaryTableControlsRow;
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import type { PrimaryTableControlsRowProps } from "./PrimaryTableControlsRow";
|
|
2
|
-
import type { SecondaryTableControlsRowProps } from "./SecondaryTableControlsRow";
|
|
3
|
-
import type { ActionEvent, TableEventPayload } from "../../../types/events";
|
|
4
|
-
export type TableControlsData = {
|
|
5
|
-
primaryTableRowData: PrimaryTableControlsRowProps;
|
|
6
|
-
secondaryTableRowData?: SecondaryTableControlsRowProps;
|
|
7
|
-
};
|
|
8
|
-
export interface TableControlsProps {
|
|
9
|
-
primaryTableRowData: PrimaryTableControlsRowProps;
|
|
10
|
-
secondaryTableRowData?: SecondaryTableControlsRowProps;
|
|
11
|
-
onChange: (event: ActionEvent<TableEventPayload>) => void;
|
|
12
|
-
}
|
|
13
|
-
declare const TableControls: ({ primaryTableRowData, secondaryTableRowData, onChange, }: TableControlsProps) => import("react/jsx-runtime").JSX.Element;
|
|
14
|
-
export default TableControls;
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import PrimaryTableControlsRow from "./PrimaryTableControlsRow";
|
|
3
|
-
import SecondaryTableControlsRow from "./SecondaryTableControlsRow";
|
|
4
|
-
const TableControls = ({ primaryTableRowData, secondaryTableRowData, onChange, }) => {
|
|
5
|
-
const onPrimaryChange = (actionEvent) => {
|
|
6
|
-
onChange(actionEvent);
|
|
7
|
-
};
|
|
8
|
-
const onSecondaryChange = (actionEvent) => {
|
|
9
|
-
onChange(actionEvent);
|
|
10
|
-
};
|
|
11
|
-
return (_jsxs("div", { "data-testid": "TableControls", style: { margin: "16px 0px" }, children: [_jsx(PrimaryTableControlsRow, { sortOptions: primaryTableRowData.sortOptions, searchByPlaceholder: primaryTableRowData.searchByPlaceholder, isSortedAscending: primaryTableRowData.isSortedAscending, onChange: onPrimaryChange, searchValue: primaryTableRowData.searchValue, selectedSortOption: primaryTableRowData.selectedSortOption }), secondaryTableRowData ? (_jsx(SecondaryTableControlsRow, { groups: secondaryTableRowData.groups, totalRecords: secondaryTableRowData.totalRecords, onChange: onSecondaryChange })) : null] }));
|
|
12
|
-
};
|
|
13
|
-
export default TableControls;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
export { default } from "./TableControls";
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import { PaginationStyle } from "./TableControls/CustomPagination";
|
|
2
|
-
import type { ColumnType } from "antd/es/table";
|
|
3
|
-
export interface TablePaginationProps<T> {
|
|
4
|
-
columns: ColumnType<T>[];
|
|
5
|
-
dataSource: T[];
|
|
6
|
-
rowSelection?: any;
|
|
7
|
-
onChange?: (...arguments_: any[]) => void;
|
|
8
|
-
paginationStyle?: PaginationStyle;
|
|
9
|
-
pageSize?: number;
|
|
10
|
-
isMainContentCell?: boolean;
|
|
11
|
-
}
|
|
12
|
-
declare const TablePagination: <T extends Record<string, any>>({ columns, dataSource, rowSelection, onChange, paginationStyle, pageSize, isMainContentCell, }: TablePaginationProps<T>) => import("react/jsx-runtime").JSX.Element;
|
|
13
|
-
export default TablePagination;
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
2
|
-
import { useState } from "react";
|
|
3
|
-
import Table from "./Table";
|
|
4
|
-
import CustomPagination, { PaginationStyle, } from "./TableControls/CustomPagination";
|
|
5
|
-
const TablePagination = ({ columns, dataSource, rowSelection, onChange, paginationStyle = PaginationStyle.SIMPLE, pageSize = 10, isMainContentCell, }) => {
|
|
6
|
-
const [current, setCurrent] = useState(1);
|
|
7
|
-
const total = dataSource.length;
|
|
8
|
-
const paginatedData = dataSource.slice((current - 1) * pageSize, current * pageSize);
|
|
9
|
-
return (_jsxs("div", { style: { display: "flex", flexDirection: "column", gap: "0px" }, children: [_jsx(Table, { columns: columns, dataSource: paginatedData, rowSelection: rowSelection, onChange: onChange, pagination: false, isMainContentCell: isMainContentCell }), _jsx("div", { style: { display: "flex", justifyContent: "flex-end", marginTop: 16 }, children: _jsx(CustomPagination, { paginationStyle: paginationStyle, current: current, total: total, pageSize: pageSize, onChange: setCurrent }) })] }));
|
|
10
|
-
};
|
|
11
|
-
export default TablePagination;
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { ColumnsType } from "antd/es/table";
|
|
2
|
-
export interface AppointmentWithSimpleAddress {
|
|
3
|
-
id: string;
|
|
4
|
-
number: string;
|
|
5
|
-
timerange: string;
|
|
6
|
-
status: AppointmentStatus;
|
|
7
|
-
address: {
|
|
8
|
-
nickname: string;
|
|
9
|
-
address: string;
|
|
10
|
-
};
|
|
11
|
-
job_subtype: "delivery" | "pickup";
|
|
12
|
-
}
|
|
13
|
-
export interface MockDataSource {
|
|
14
|
-
appointments: AppointmentWithSimpleAddress[];
|
|
15
|
-
}
|
|
16
|
-
type AppointmentStatus = "scheduled" | "completed" | "cancelled" | "in_progress";
|
|
17
|
-
export declare const mockColumns: ColumnsType<AppointmentWithSimpleAddress>;
|
|
18
|
-
export declare const mockColumnsWithSortDisabled: ColumnsType<AppointmentWithSimpleAddress>;
|
|
19
|
-
export declare const mockDataSource: MockDataSource;
|
|
20
|
-
export {};
|
|
@@ -1,301 +0,0 @@
|
|
|
1
|
-
import { Badge } from "@gobolt/genesis/components";
|
|
2
|
-
import React from "react";
|
|
3
|
-
// Helper function for title case
|
|
4
|
-
const startCase = (string_) => {
|
|
5
|
-
if (string_) {
|
|
6
|
-
return string_
|
|
7
|
-
.replaceAll(/([A-Z])/g, " $1")
|
|
8
|
-
.replace(/^./, (s) => s.toUpperCase());
|
|
9
|
-
}
|
|
10
|
-
return string_;
|
|
11
|
-
};
|
|
12
|
-
export const mockColumns = [
|
|
13
|
-
{
|
|
14
|
-
key: "number",
|
|
15
|
-
title: "Id",
|
|
16
|
-
dataIndex: "number",
|
|
17
|
-
},
|
|
18
|
-
{
|
|
19
|
-
key: "timeslot",
|
|
20
|
-
title: "Timeslot",
|
|
21
|
-
dataIndex: "timerange",
|
|
22
|
-
},
|
|
23
|
-
{
|
|
24
|
-
key: "status",
|
|
25
|
-
title: "Status",
|
|
26
|
-
dataIndex: "status",
|
|
27
|
-
render: (status) => {
|
|
28
|
-
const colorStateMap = {
|
|
29
|
-
in_progress: "warning",
|
|
30
|
-
scheduled: "generic",
|
|
31
|
-
completed: "success",
|
|
32
|
-
};
|
|
33
|
-
const statusLabel = status === "in_progress" ? "in progress" : status;
|
|
34
|
-
return React.createElement(Badge, {
|
|
35
|
-
label: startCase(statusLabel),
|
|
36
|
-
state: colorStateMap[status],
|
|
37
|
-
});
|
|
38
|
-
},
|
|
39
|
-
},
|
|
40
|
-
{
|
|
41
|
-
key: "address",
|
|
42
|
-
title: "Address",
|
|
43
|
-
render: (appointment) => {
|
|
44
|
-
const { address: { nickname, address }, } = appointment;
|
|
45
|
-
return nickname ? `${nickname} (${address})` : address;
|
|
46
|
-
},
|
|
47
|
-
},
|
|
48
|
-
{
|
|
49
|
-
title: "Type",
|
|
50
|
-
dataIndex: "job_subtype",
|
|
51
|
-
render: (jobSubtype) => {
|
|
52
|
-
const colorStateMap = {
|
|
53
|
-
delivery: "info",
|
|
54
|
-
pickup: "success",
|
|
55
|
-
};
|
|
56
|
-
return React.createElement(Badge, {
|
|
57
|
-
label: startCase(jobSubtype),
|
|
58
|
-
state: colorStateMap[jobSubtype],
|
|
59
|
-
});
|
|
60
|
-
},
|
|
61
|
-
},
|
|
62
|
-
];
|
|
63
|
-
// Note: it's important that we don't show the Ant Design sorting since it controlled via the table controls
|
|
64
|
-
export const mockColumnsWithSortDisabled = mockColumns.map((column) => ({
|
|
65
|
-
...column,
|
|
66
|
-
}));
|
|
67
|
-
export const mockDataSource = {
|
|
68
|
-
appointments: [
|
|
69
|
-
{
|
|
70
|
-
id: "1",
|
|
71
|
-
number: "1",
|
|
72
|
-
timerange: "9:00 AM - 10:00 AM",
|
|
73
|
-
status: "in_progress",
|
|
74
|
-
address: {
|
|
75
|
-
nickname: "Home",
|
|
76
|
-
address: "123 Main St",
|
|
77
|
-
},
|
|
78
|
-
job_subtype: "delivery",
|
|
79
|
-
},
|
|
80
|
-
{
|
|
81
|
-
id: "2",
|
|
82
|
-
number: "2",
|
|
83
|
-
timerange: "10:00 AM - 11:00 AM",
|
|
84
|
-
status: "scheduled",
|
|
85
|
-
address: {
|
|
86
|
-
nickname: "Work",
|
|
87
|
-
address: "456 Elm St",
|
|
88
|
-
},
|
|
89
|
-
job_subtype: "pickup",
|
|
90
|
-
},
|
|
91
|
-
{
|
|
92
|
-
id: "3",
|
|
93
|
-
number: "3",
|
|
94
|
-
timerange: "11:00 AM - 12:00 PM",
|
|
95
|
-
status: "scheduled",
|
|
96
|
-
address: {
|
|
97
|
-
nickname: "Store",
|
|
98
|
-
address: "789 Oak St",
|
|
99
|
-
},
|
|
100
|
-
job_subtype: "delivery",
|
|
101
|
-
},
|
|
102
|
-
{
|
|
103
|
-
id: "4",
|
|
104
|
-
number: "4",
|
|
105
|
-
timerange: "1:00 PM - 2:00 PM",
|
|
106
|
-
status: "scheduled",
|
|
107
|
-
address: {
|
|
108
|
-
nickname: "Office",
|
|
109
|
-
address: "321 Pine St",
|
|
110
|
-
},
|
|
111
|
-
job_subtype: "pickup",
|
|
112
|
-
},
|
|
113
|
-
{
|
|
114
|
-
id: "5",
|
|
115
|
-
number: "5",
|
|
116
|
-
timerange: "2:00 PM - 3:00 PM",
|
|
117
|
-
status: "scheduled",
|
|
118
|
-
address: {
|
|
119
|
-
nickname: "Library",
|
|
120
|
-
address: "555 Book Lane",
|
|
121
|
-
},
|
|
122
|
-
job_subtype: "delivery",
|
|
123
|
-
},
|
|
124
|
-
{
|
|
125
|
-
id: "6",
|
|
126
|
-
number: "6",
|
|
127
|
-
timerange: "3:00 PM - 4:00 PM",
|
|
128
|
-
status: "scheduled",
|
|
129
|
-
address: {
|
|
130
|
-
nickname: "Gym",
|
|
131
|
-
address: "777 Fitness Ave",
|
|
132
|
-
},
|
|
133
|
-
job_subtype: "pickup",
|
|
134
|
-
},
|
|
135
|
-
{
|
|
136
|
-
id: "7",
|
|
137
|
-
number: "7",
|
|
138
|
-
timerange: "4:00 PM - 5:00 PM",
|
|
139
|
-
status: "scheduled",
|
|
140
|
-
address: {
|
|
141
|
-
nickname: "Mall",
|
|
142
|
-
address: "888 Shopping Center",
|
|
143
|
-
},
|
|
144
|
-
job_subtype: "delivery",
|
|
145
|
-
},
|
|
146
|
-
{
|
|
147
|
-
id: "8",
|
|
148
|
-
number: "8",
|
|
149
|
-
timerange: "9:00 AM - 10:00 AM",
|
|
150
|
-
status: "completed",
|
|
151
|
-
address: {
|
|
152
|
-
nickname: "School",
|
|
153
|
-
address: "999 Education Rd",
|
|
154
|
-
},
|
|
155
|
-
job_subtype: "pickup",
|
|
156
|
-
},
|
|
157
|
-
{
|
|
158
|
-
id: "9",
|
|
159
|
-
number: "9",
|
|
160
|
-
timerange: "10:00 AM - 11:00 AM",
|
|
161
|
-
status: "scheduled",
|
|
162
|
-
address: {
|
|
163
|
-
nickname: "Restaurant",
|
|
164
|
-
address: "111 Food Court",
|
|
165
|
-
},
|
|
166
|
-
job_subtype: "delivery",
|
|
167
|
-
},
|
|
168
|
-
{
|
|
169
|
-
id: "10",
|
|
170
|
-
number: "10",
|
|
171
|
-
timerange: "11:00 AM - 12:00 PM",
|
|
172
|
-
status: "scheduled",
|
|
173
|
-
address: {
|
|
174
|
-
nickname: "Park",
|
|
175
|
-
address: "222 Green Ave",
|
|
176
|
-
},
|
|
177
|
-
job_subtype: "pickup",
|
|
178
|
-
},
|
|
179
|
-
{
|
|
180
|
-
id: "11",
|
|
181
|
-
number: "11",
|
|
182
|
-
timerange: "1:00 PM - 2:00 PM",
|
|
183
|
-
status: "scheduled",
|
|
184
|
-
address: {
|
|
185
|
-
nickname: "Beach",
|
|
186
|
-
address: "333 Shore Dr",
|
|
187
|
-
},
|
|
188
|
-
job_subtype: "delivery",
|
|
189
|
-
},
|
|
190
|
-
{
|
|
191
|
-
id: "12",
|
|
192
|
-
number: "12",
|
|
193
|
-
timerange: "2:00 PM - 3:00 PM",
|
|
194
|
-
status: "scheduled",
|
|
195
|
-
address: {
|
|
196
|
-
nickname: "Hotel",
|
|
197
|
-
address: "444 Stay Blvd",
|
|
198
|
-
},
|
|
199
|
-
job_subtype: "pickup",
|
|
200
|
-
},
|
|
201
|
-
{
|
|
202
|
-
id: "13",
|
|
203
|
-
number: "13",
|
|
204
|
-
timerange: "3:00 PM - 4:00 PM",
|
|
205
|
-
status: "scheduled",
|
|
206
|
-
address: {
|
|
207
|
-
nickname: "Airport",
|
|
208
|
-
address: "666 Flight Way",
|
|
209
|
-
},
|
|
210
|
-
job_subtype: "delivery",
|
|
211
|
-
},
|
|
212
|
-
{
|
|
213
|
-
id: "14",
|
|
214
|
-
number: "14",
|
|
215
|
-
timerange: "4:00 PM - 5:00 PM",
|
|
216
|
-
status: "cancelled",
|
|
217
|
-
address: {
|
|
218
|
-
nickname: "Stadium",
|
|
219
|
-
address: "777 Sports Complex",
|
|
220
|
-
},
|
|
221
|
-
job_subtype: "pickup",
|
|
222
|
-
},
|
|
223
|
-
{
|
|
224
|
-
id: "15",
|
|
225
|
-
number: "15",
|
|
226
|
-
timerange: "9:00 AM - 10:00 AM",
|
|
227
|
-
status: "scheduled",
|
|
228
|
-
address: {
|
|
229
|
-
nickname: "Theater",
|
|
230
|
-
address: "888 Show Ave",
|
|
231
|
-
},
|
|
232
|
-
job_subtype: "delivery",
|
|
233
|
-
},
|
|
234
|
-
{
|
|
235
|
-
id: "16",
|
|
236
|
-
number: "16",
|
|
237
|
-
timerange: "10:00 AM - 11:00 AM",
|
|
238
|
-
status: "scheduled",
|
|
239
|
-
address: {
|
|
240
|
-
nickname: "Museum",
|
|
241
|
-
address: "999 History Lane",
|
|
242
|
-
},
|
|
243
|
-
job_subtype: "pickup",
|
|
244
|
-
},
|
|
245
|
-
{
|
|
246
|
-
id: "17",
|
|
247
|
-
number: "17",
|
|
248
|
-
timerange: "11:00 AM - 12:00 PM",
|
|
249
|
-
status: "scheduled",
|
|
250
|
-
address: {
|
|
251
|
-
nickname: "Zoo",
|
|
252
|
-
address: "123 Animal Park",
|
|
253
|
-
},
|
|
254
|
-
job_subtype: "delivery",
|
|
255
|
-
},
|
|
256
|
-
{
|
|
257
|
-
id: "18",
|
|
258
|
-
number: "18",
|
|
259
|
-
timerange: "1:00 PM - 2:00 PM",
|
|
260
|
-
status: "scheduled",
|
|
261
|
-
address: {
|
|
262
|
-
nickname: "Bank",
|
|
263
|
-
address: "456 Money St",
|
|
264
|
-
},
|
|
265
|
-
job_subtype: "pickup",
|
|
266
|
-
},
|
|
267
|
-
{
|
|
268
|
-
id: "19",
|
|
269
|
-
number: "19",
|
|
270
|
-
timerange: "2:00 PM - 3:00 PM",
|
|
271
|
-
status: "scheduled",
|
|
272
|
-
address: {
|
|
273
|
-
nickname: "Post Office",
|
|
274
|
-
address: "789 Mail Road",
|
|
275
|
-
},
|
|
276
|
-
job_subtype: "delivery",
|
|
277
|
-
},
|
|
278
|
-
{
|
|
279
|
-
id: "20",
|
|
280
|
-
number: "20",
|
|
281
|
-
timerange: "3:00 PM - 4:00 PM",
|
|
282
|
-
status: "scheduled",
|
|
283
|
-
address: {
|
|
284
|
-
nickname: "Church",
|
|
285
|
-
address: "321 Faith Street",
|
|
286
|
-
},
|
|
287
|
-
job_subtype: "pickup",
|
|
288
|
-
},
|
|
289
|
-
{
|
|
290
|
-
id: "21",
|
|
291
|
-
number: "21",
|
|
292
|
-
timerange: "4:00 PM - 5:00 PM",
|
|
293
|
-
status: "scheduled",
|
|
294
|
-
address: {
|
|
295
|
-
nickname: "Pharmacy",
|
|
296
|
-
address: "654 Health Ave",
|
|
297
|
-
},
|
|
298
|
-
job_subtype: "delivery",
|
|
299
|
-
},
|
|
300
|
-
],
|
|
301
|
-
};
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
export { default } from "./TablePagination";
|
|
2
|
-
export { default as Table } from "./Table";
|
|
3
|
-
export type { TableProps } from "./Table";
|
|
4
|
-
export type { TablePaginationProps } from "./TablePagination";
|
|
5
|
-
export { useTable } from "./useTable";
|
|
6
|
-
export type { UseTableConfig } from "./useTable";
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import { TableProps } from "antd";
|
|
2
|
-
import { type GenesisTheme } from "@gobolt/genesis/styles/theme/genesis-theme.types";
|
|
3
|
-
export interface StyledTableProps<T = any> extends TableProps<T> {
|
|
4
|
-
theme?: GenesisTheme;
|
|
5
|
-
$isMainContentCell?: boolean;
|
|
6
|
-
}
|
|
7
|
-
export declare const getGenesisClass: ({ colors, borderRadius, sizing, typography, components }: {
|
|
8
|
-
colors: any;
|
|
9
|
-
borderRadius: any;
|
|
10
|
-
sizing: any;
|
|
11
|
-
typography: any;
|
|
12
|
-
components: any;
|
|
13
|
-
}, $isMainContentCell: any) => string;
|
|
14
|
-
export declare const Table: any;
|
|
@@ -1,64 +0,0 @@
|
|
|
1
|
-
import styled from "@gobolt/genesis/utils/styled";
|
|
2
|
-
import { Table as AntTable } from "antd";
|
|
3
|
-
export const getGenesisClass = ({ colors, borderRadius, sizing, typography, components }, $isMainContentCell) => {
|
|
4
|
-
// Log the hovered color and the entire tableCell object
|
|
5
|
-
return `
|
|
6
|
-
&.ant-table-wrapper {
|
|
7
|
-
// Add your custom styles here
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
.ant-table {
|
|
11
|
-
// Add your custom table styles here
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
.ant-table-cell {
|
|
15
|
-
font-size: ${$isMainContentCell ? "16px" : "14px"} !important;
|
|
16
|
-
color: ${$isMainContentCell
|
|
17
|
-
? colors.onsurface.copy
|
|
18
|
-
: colors.onsurface["copy-light"]} !important;
|
|
19
|
-
background-color: ${components.tableCell.surface} !important;
|
|
20
|
-
transition: background-color 0.2s ease;
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.ant-table-tbody > tr:hover > td,
|
|
24
|
-
.ant-table-tbody > tr:hover > .ant-table-cell {
|
|
25
|
-
background-color: ${components.tableCell.hover} !important;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.ant-table-cell-selected {
|
|
29
|
-
background-color: ${components.tableCell.selected} !important;
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
.ant-table-thead > tr > th {
|
|
33
|
-
// Add your custom header styles here
|
|
34
|
-
font-family: 'Inter', sans-serif;
|
|
35
|
-
font-size: ${$isMainContentCell ? "16px" : "14px"} !important;
|
|
36
|
-
font-weight: 400;
|
|
37
|
-
color: ${$isMainContentCell
|
|
38
|
-
? colors.onsurface.copy
|
|
39
|
-
: colors.onsurface["copy-light"]} !important;
|
|
40
|
-
}
|
|
41
|
-
|
|
42
|
-
.ant-table-tbody > tr {
|
|
43
|
-
// Add your custom row styles here
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
.ant-table-tbody > tr > td {
|
|
47
|
-
// Add your custom cell styles here
|
|
48
|
-
font-family: 'Inter', sans-serif;
|
|
49
|
-
font-size: 14px;
|
|
50
|
-
color: ${colors.onsurface["copy-light"]};
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
.ant-table-tbody > tr.ant-table-row-selected > td,
|
|
54
|
-
.ant-table-tbody > tr.ant-table-row-selected > .ant-table-cell {
|
|
55
|
-
background-color: ${components.tableCell.selected} !important;
|
|
56
|
-
color: #fff !important;
|
|
57
|
-
}
|
|
58
|
-
`;
|
|
59
|
-
};
|
|
60
|
-
export const Table = styled(AntTable) `
|
|
61
|
-
${({ theme, $isMainContentCell }) => {
|
|
62
|
-
return getGenesisClass(theme, $isMainContentCell);
|
|
63
|
-
}}
|
|
64
|
-
`;
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import type { ColumnsType } from "antd/es/table";
|
|
2
|
-
import type { SelectionType } from "./Table";
|
|
3
|
-
export type UseTableConfig = {
|
|
4
|
-
columns: ColumnsType<any>;
|
|
5
|
-
filters?: Record<string, any>;
|
|
6
|
-
fetchUrl?: string;
|
|
7
|
-
fetchOptions?: RequestInit;
|
|
8
|
-
selectionType?: SelectionType;
|
|
9
|
-
simulateDelay?: number;
|
|
10
|
-
disableRowSelection?: (record: any) => unknown;
|
|
11
|
-
disableAutoFetch?: boolean;
|
|
12
|
-
dataSource?: any[];
|
|
13
|
-
};
|
|
14
|
-
export declare const useTable: <T extends Record<string, any>>(useTableConfig: any) => {
|
|
15
|
-
isLoading: boolean;
|
|
16
|
-
rowSelection: {
|
|
17
|
-
type: SelectionType;
|
|
18
|
-
onChange: (selectedRowKeys: React.Key[], selectedRows: T[]) => void;
|
|
19
|
-
getCheckboxProps: (record: any) => unknown;
|
|
20
|
-
};
|
|
21
|
-
selectedRows: T[];
|
|
22
|
-
updateDataSource: (newDataSource: T[]) => void;
|
|
23
|
-
dataSource: T[];
|
|
24
|
-
columns: ColumnsType<T>;
|
|
25
|
-
error: Error | null;
|
|
26
|
-
};
|