@gobolt/genesis 0.0.10 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +8 -2
- package/dist/AntdIcon-nCNB0J1E.js +192 -0
- package/dist/CheckCircleFilled-BKgizvyl.js +13 -0
- package/dist/{CheckOutlined-CeTKr6II.js → CheckOutlined-cEBrx_Ag.js} +2 -2
- package/dist/ClockCircleOutlined-BaXQuLIn.js +13 -0
- package/dist/{CloseCircleFilled-DXCxlIQL.js → CloseCircleFilled-B9e7yFwo.js} +2 -2
- package/dist/{CloseOutlined-ClXDNn82.js → CloseOutlined-ogxnm7Oy.js} +2 -2
- package/dist/{Compact-CGY560JF.js → Compact-Du9689ax.js} +41 -44
- package/dist/{ContextIsolator-D5x2Ih51.js → ContextIsolator-BmfhJgG0.js} +2 -2
- package/dist/{PurePanel-BqPLRtc2.js → DownOutlined-Dcq69ZKM.js} +42 -40
- package/dist/{index-C8haFnXI.js → EllipsisOutlined-DGMph0Bj.js} +138 -135
- package/dist/ExclamationCircleFilled-BHELVsTg.js +13 -0
- package/dist/Keyframes-C9_aCDvn.js +17 -0
- package/dist/{LoadingOutlined-8EnJdZ7I.js → LoadingOutlined-C1qu6ymP.js} +6 -6
- package/dist/MinusCircleOutlined-Shz0RRQV.js +37 -0
- package/dist/{Overflow-PBZD-PFm.js → Overflow-DWf4XIal.js} +62 -61
- package/dist/{SearchOutlined-BP3Z2K6j.js → SearchOutlined-DNj-7b_h.js} +2 -2
- package/dist/Skeleton-BVN4pcVe.js +560 -0
- package/dist/TextArea-Bkf9hh7l.js +708 -0
- package/dist/Typography-CoZ5qD-t.js +705 -0
- package/dist/_baseIsEqual-L0-w1QRI.js +598 -0
- package/dist/_commonjsHelpers-BkfeUUK-.js +28 -0
- package/dist/asyncToGenerator-CKP9bEZn.js +312 -0
- package/dist/{button-CDQgO1OK.js → button-BwqpCxVM.js} +127 -116
- package/dist/clsx-OuTLNxxd.js +16 -0
- package/dist/components/Avatar/Avatar.d.ts +12 -0
- package/dist/components/Avatar/Avatar.js +61 -0
- package/dist/components/Avatar/__stories__/Avatar.stories.d.ts +8 -0
- package/dist/components/Avatar/__tests__/Avatar.test.d.ts +1 -0
- package/dist/components/Avatar/__tests__/Avatar.test.js +17 -0
- package/dist/components/Avatar/index.d.ts +2 -0
- package/dist/components/Avatar/index.js +4 -0
- package/dist/components/Avatar/styles.d.ts +18 -0
- package/dist/components/Avatar/styles.js +326 -0
- package/dist/components/Badge/Badge.d.ts +5 -3
- package/dist/components/Badge/Badge.js +67 -100
- package/dist/components/Badge/__stories__/Badge.stories.d.ts +5 -4
- package/dist/components/Badge/__tests__/Badge.test.js +9 -10
- package/dist/components/Badge/styles.d.ts +12 -3
- package/dist/components/Badge/styles.js +30 -27
- package/dist/components/Breadcrumb/Breadcrumb.js +2 -2
- package/dist/components/Breadcrumb/__tests__/Breadcrumb.test.js +1 -1
- package/dist/components/Breadcrumb/styles.js +239 -2260
- package/dist/components/Button/Button.d.ts +4 -3
- package/dist/components/Button/Button.js +10 -6
- package/dist/components/Button/__stories__/Button.stories.d.ts +3 -0
- package/dist/components/Button/__tests__/Button.test.js +1 -1
- package/dist/components/Button/styles.d.ts +2 -2
- package/dist/components/Button/styles.js +20 -17
- package/dist/components/Card/Card.d.ts +9 -0
- package/dist/components/Card/Card.js +16 -0
- package/dist/components/Card/__stories__/Card.stories.d.ts +7 -0
- package/dist/components/Card/__tests__/Card.test.d.ts +1 -0
- package/dist/components/Card/__tests__/Card.test.js +16 -0
- package/dist/components/Card/index.d.ts +2 -0
- package/dist/components/Card/index.js +4 -0
- package/dist/components/Card/styles.d.ts +16 -0
- package/dist/components/Card/styles.js +12 -0
- package/dist/components/Checkbox/Checkbox.d.ts +1 -2
- package/dist/components/Checkbox/Checkbox.js +28 -16
- package/dist/components/Checkbox/__tests__/Checkbox.test.js +1 -1
- package/dist/components/Checkbox/styles.js +22 -457
- package/dist/components/Dashboard/Dashboard.d.ts +5 -0
- package/dist/components/Dashboard/Dashboard.js +5 -0
- package/dist/components/Dashboard/__mocks__/dashboard-data.d.ts +14 -0
- package/dist/components/Dashboard/__mocks__/dashboard-data.js +186 -0
- package/dist/components/Dashboard/__stories__/Dashboard.stories.d.ts +7 -0
- package/dist/components/Dashboard/__stories__/DashboardLayoutContent.d.ts +2 -0
- package/dist/components/Dashboard/__stories__/DashboardLayoutContent.js +948 -0
- package/dist/components/Dashboard/__stories__/DashboardLayoutHeader.d.ts +2 -0
- package/dist/components/Dashboard/__stories__/DashboardLayoutHeader.js +85 -0
- package/dist/components/Dashboard/__stories__/DashboardLayoutStory.d.ts +13 -0
- package/dist/components/Dashboard/__stories__/DashboardLayoutStory.js +22 -0
- package/dist/components/Dashboard/__stories__/charts/LineChart.d.ts +12 -0
- package/dist/components/Dashboard/__stories__/charts/LineChart.js +536 -0
- package/dist/components/Dashboard/__tests__/Dashboard.test.d.ts +1 -0
- package/dist/components/Dashboard/__tests__/Dashboard.test.js +16 -0
- package/dist/components/Dashboard/index.d.ts +2 -0
- package/dist/components/Dashboard/index.js +4 -0
- package/dist/components/Dashboard/styles.d.ts +14 -0
- package/dist/components/Dashboard/styles.js +11 -0
- package/dist/components/DatePicker/DatePicker.d.ts +6 -0
- package/dist/components/DatePicker/DatePicker.js +5 -0
- package/dist/components/DatePicker/__stories__/DatePicker.stories.d.ts +10 -0
- package/dist/components/DatePicker/__tests__/DatePicker.test.d.ts +1 -0
- package/dist/components/DatePicker/__tests__/DatePicker.test.js +19 -0
- package/dist/components/DatePicker/index.d.ts +2 -0
- package/dist/components/DatePicker/index.js +4 -0
- package/dist/components/DateRangePicker/DateRangePicker.d.ts +5 -0
- package/dist/components/DateRangePicker/DateRangePicker.js +5 -0
- package/dist/components/DateRangePicker/__stories__/DateRangePicker.stories.d.ts +9 -0
- package/dist/components/DateRangePicker/__tests__/DateRangePicker.test.d.ts +1 -0
- package/dist/components/DateRangePicker/__tests__/DateRangePicker.test.js +23 -0
- package/dist/components/DateRangePicker/index.d.ts +2 -0
- package/dist/components/DateRangePicker/index.js +4 -0
- package/dist/components/ErrorBoundary/ErrorBoundary.d.ts +19 -0
- package/dist/components/ErrorBoundary/ErrorBoundary.js +72 -0
- package/dist/components/ErrorBoundary/__stories__/ErrorBoundary.stories.d.ts +8 -0
- package/dist/components/ErrorBoundary/__tests__/ErrorBoundary.test.d.ts +1 -0
- package/dist/components/ErrorBoundary/__tests__/ErrorBoundary.test.js +25 -0
- package/dist/components/ErrorBoundary/index.d.ts +2 -0
- package/dist/components/ErrorBoundary/index.js +4 -0
- package/dist/components/ErrorBoundary/styles.d.ts +14 -0
- package/dist/components/ErrorBoundary/styles.js +11 -0
- package/dist/components/ErrorBoundaryFallback/ErrorBoundaryFallback.d.ts +2 -2
- package/dist/components/ErrorBoundaryFallback/ErrorBoundaryFallback.js +33 -18
- package/dist/components/ErrorBoundaryFallback/__stories__/ErrorBoundaryFallback.stories.d.ts +1 -1
- package/dist/components/ErrorBoundaryFallback/styles.js +17 -15
- package/dist/components/Form/Form.js +3 -3
- package/dist/components/Form/__stories__/FormStory.js +127 -50
- package/dist/components/Form/__tests__/form.test.js +2 -2
- package/dist/components/Form/index.js +1 -1
- package/dist/components/Form/styles.js +1 -1
- package/dist/components/Glyph/Glyph.d.ts +4 -0
- package/dist/components/Glyph/Glyph.js +9 -0
- package/dist/components/Glyph/__stories__/Glyph.stories.d.ts +7 -0
- package/dist/components/Glyph/index.d.ts +2 -0
- package/dist/components/Glyph/index.js +4 -0
- package/dist/components/Glyph/styles.d.ts +14 -0
- package/dist/components/Glyph/styles.js +11 -0
- package/dist/components/Input/Input.d.ts +1 -2
- package/dist/components/Input/Input.js +14 -10
- package/dist/components/Input/__tests__/Input.test.js +1 -1
- package/dist/components/Input/styles.js +58 -466
- package/dist/components/Layout/Content/Content.d.ts +11 -0
- package/dist/components/Layout/Content/Content.js +32 -0
- package/dist/components/Layout/Content/ResponsiveContent.d.ts +7 -0
- package/dist/components/Layout/Content/ResponsiveContent.js +81 -0
- package/dist/components/Layout/Content/index.d.ts +2 -0
- package/dist/components/Layout/Content/index.js +4 -0
- package/dist/components/Layout/Content/styles.d.ts +11 -0
- package/dist/components/Layout/Content/styles.js +16 -0
- package/dist/components/Layout/Layout.d.ts +8 -0
- package/dist/components/Layout/Layout.js +6 -0
- package/dist/components/Layout/MainLayout/MainLayout.d.ts +10 -0
- package/dist/components/Layout/MainLayout/MainLayout.js +28 -0
- package/dist/components/Layout/MainLayout/__stories__/MainLayout.stories.d.ts +9 -0
- package/dist/components/Layout/MainLayout/index.d.ts +2 -0
- package/dist/components/Layout/MainLayout/index.js +4 -0
- package/dist/components/Layout/MainLayout/styles.d.ts +4 -0
- package/dist/components/Layout/MainLayout/styles.js +69 -0
- package/dist/components/Layout/__stories__/Layout.stories.d.ts +7 -0
- package/dist/components/Layout/__tests__/Layout.test.d.ts +1 -0
- package/dist/components/Layout/__tests__/Layout.test.js +14 -0
- package/dist/components/Layout/index.d.ts +2 -0
- package/dist/components/Layout/index.js +4 -0
- package/dist/components/Message/Message.d.ts +6 -4
- package/dist/components/Message/Message.js +70 -43
- package/dist/components/Message/__tests__/Message.test.js +1 -1
- package/dist/components/Message/styles.d.ts +1 -0
- package/dist/components/Message/styles.js +15 -11
- package/dist/components/Notification/Notification.js +145 -120
- package/dist/components/Notification/NotificationBadge/NotificationBadge.d.ts +6 -0
- package/dist/components/Notification/NotificationBadge/NotificationBadge.js +49 -0
- package/dist/components/Notification/NotificationBadge/__stories__/NotificationBadge.stories.d.ts +13 -0
- package/dist/components/Notification/NotificationBadge/__tests__/NotificationBadge.test.d.ts +1 -0
- package/dist/components/Notification/NotificationBadge/__tests__/NotificationBadge.test.js +18 -0
- package/dist/components/Notification/NotificationBadge/index.d.ts +2 -0
- package/dist/components/Notification/NotificationBadge/index.js +4 -0
- package/dist/components/Notification/NotificationBadge/styles.d.ts +3 -0
- package/dist/components/Notification/NotificationBadge/styles.js +34 -0
- package/dist/components/Notification/__tests__/Notification.test.js +1 -1
- package/dist/components/Notification/styles.d.ts +1 -1
- package/dist/components/Notification/styles.js +1 -1
- package/dist/components/Popover/Popover.d.ts +10 -0
- package/dist/components/Popover/Popover.js +21 -0
- package/dist/components/Popover/__stories__/Popover.stories.d.ts +7 -0
- package/dist/components/Popover/__tests__/Popover.test.d.ts +1 -0
- package/dist/components/Popover/__tests__/Popover.test.js +40 -0
- package/dist/components/Popover/index.d.ts +2 -0
- package/dist/components/Popover/index.js +4 -0
- package/dist/components/Popover/styles.d.ts +15 -0
- package/dist/components/Popover/styles.js +6 -0
- package/dist/components/Progress/Progress.d.ts +18 -0
- package/dist/components/Progress/Progress.js +91 -0
- package/dist/components/Progress/Progress.util.d.ts +4 -0
- package/dist/components/Progress/Progress.util.js +62 -0
- package/dist/components/Progress/ProgressText.d.ts +11 -0
- package/dist/components/Progress/ProgressText.js +67 -0
- package/dist/components/Progress/__stories__/Progress.stories.d.ts +12 -0
- package/dist/components/Progress/__tests__/Progress.test.d.ts +1 -0
- package/dist/components/Progress/__tests__/Progress.test.js +21 -0
- package/dist/components/Progress/index.d.ts +2 -0
- package/dist/components/Progress/index.js +4 -0
- package/dist/components/Progress/styles.d.ts +17 -0
- package/dist/components/Progress/styles.js +793 -0
- package/dist/components/Radio/Radio.js +22 -6
- package/dist/components/Radio/RadioGroup.js +1 -1
- package/dist/components/Radio/__tests__/RadioGroup.test.js +1 -1
- package/dist/components/Radio/index.d.ts +1 -0
- package/dist/components/Row/Row.d.ts +14 -0
- package/dist/components/Row/Row.js +38 -0
- package/dist/components/Row/RowActions/RowActions.d.ts +9 -0
- package/dist/components/Row/RowActions/RowActions.js +59 -0
- package/dist/components/Row/RowActions/styles.d.ts +2 -0
- package/dist/components/Row/RowActions/styles.js +32 -0
- package/dist/components/Row/RowLabelValue/RowLabelValue.d.ts +11 -0
- package/dist/components/Row/RowLabelValue/RowLabelValue.js +62 -0
- package/dist/components/Row/RowLabelValue/RowSkeleton.d.ts +3 -0
- package/dist/components/Row/RowLabelValue/RowSkeleton.js +24 -0
- package/dist/components/Row/RowLabelValue/styles.d.ts +15 -0
- package/dist/components/Row/RowLabelValue/styles.js +25 -0
- package/dist/components/Row/__stories__/Row.stories.d.ts +13 -0
- package/dist/components/Row/__tests__/Row.test.d.ts +1 -0
- package/dist/components/Row/__tests__/Row.test.js +16 -0
- package/dist/components/Row/index.d.ts +2 -0
- package/dist/components/Row/index.js +4 -0
- package/dist/components/Row/styles.d.ts +15 -0
- package/dist/components/Row/styles.js +15 -0
- package/dist/components/SegmentedControls/SegmentedControls.d.ts +12 -0
- package/dist/components/SegmentedControls/SegmentedControls.js +26 -0
- package/dist/components/SegmentedControls/__stories__/SegmentedControls.stories.d.ts +9 -0
- package/dist/components/SegmentedControls/__tests__/SegmentedControls.test.d.ts +1 -0
- package/dist/components/SegmentedControls/__tests__/SegmentedControls.test.js +24 -0
- package/dist/components/SegmentedControls/index.d.ts +2 -0
- package/dist/components/SegmentedControls/index.js +4 -0
- package/dist/components/SegmentedControls/styles.d.ts +12 -0
- package/dist/components/SegmentedControls/styles.js +511 -0
- package/dist/components/Select/Select.d.ts +2 -4
- package/dist/components/Select/Select.js +12 -11
- package/dist/components/Select/__tests__/Select.test.js +1 -1
- package/dist/components/Select/styles.js +39 -3654
- package/dist/components/Shapes/Shapes.d.ts +6 -0
- package/dist/components/Shapes/Shapes.js +8 -0
- package/dist/components/Shapes/__stories__/Shapes.stories.d.ts +9 -0
- package/dist/components/Shapes/__tests__/Shapes.test.d.ts +1 -0
- package/dist/components/Shapes/__tests__/Shapes.test.js +16 -0
- package/dist/components/Shapes/index.d.ts +2 -0
- package/dist/components/Shapes/index.js +4 -0
- package/dist/components/Shapes/variants/Circle.d.ts +5 -0
- package/dist/components/Shapes/variants/Circle.js +23 -0
- package/dist/components/Shapes/variants/Rectangle.d.ts +5 -0
- package/dist/components/Shapes/variants/Rectangle.js +23 -0
- package/dist/components/Shapes/variants/Triangle.d.ts +5 -0
- package/dist/components/Shapes/variants/Triangle.js +23 -0
- package/dist/components/Switch/Switch.d.ts +9 -0
- package/dist/components/Switch/Switch.js +22 -0
- package/dist/components/Switch/__stories__/Switch.stories.d.ts +8 -0
- package/dist/components/Switch/__tests__/Switch.test.d.ts +1 -0
- package/dist/components/Switch/__tests__/Switch.test.js +25 -0
- package/dist/components/Switch/index.d.ts +2 -0
- package/dist/components/Switch/index.js +4 -0
- package/dist/components/Switch/styles.d.ts +9 -0
- package/dist/components/Switch/styles.js +456 -0
- package/dist/components/Table/Table.d.ts +15 -0
- package/dist/components/Table/Table.js +23 -0
- package/dist/components/Table/__mocks__/table-mocks.d.ts +20 -0
- package/dist/components/Table/__mocks__/table-mocks.js +321 -0
- package/dist/components/Table/__stories__/Table.stories.d.ts +7 -0
- package/dist/components/Table/__tests__/Table.test.d.ts +1 -0
- package/dist/components/Table/__tests__/Table.test.js +34 -0
- package/dist/components/Table/index.d.ts +2 -0
- package/dist/components/Table/index.js +4 -0
- package/dist/components/Table/styles.d.ts +8 -0
- package/dist/components/Table/styles.js +6 -0
- package/dist/components/Tabs/Tabs.d.ts +10 -0
- package/dist/components/Tabs/Tabs.js +23 -0
- package/dist/components/Tabs/__stories__/Tabs.stories.d.ts +8 -0
- package/dist/components/Tabs/__tests__/Tabs.test.d.ts +1 -0
- package/dist/components/Tabs/__tests__/Tabs.test.js +37 -0
- package/dist/components/Tabs/index.d.ts +2 -0
- package/dist/components/Tabs/index.js +4 -0
- package/dist/components/Tabs/styles.d.ts +12 -0
- package/dist/components/Tabs/styles.js +102 -0
- package/dist/components/Tile/Tile.d.ts +10 -0
- package/dist/components/Tile/Tile.js +21 -0
- package/dist/components/Tile/__stories__/Tile.stories.d.ts +7 -0
- package/dist/components/Tile/__tests__/Tile.test.d.ts +1 -0
- package/dist/components/Tile/__tests__/Tile.test.js +21 -0
- package/dist/components/Tile/index.d.ts +2 -0
- package/dist/components/Tile/index.js +4 -0
- package/dist/components/Tile/styles.d.ts +11 -0
- package/dist/components/Tile/styles.js +12 -0
- package/dist/components/Toast/Toast.js +23 -6
- package/dist/components/Toast/__tests__/Toast.test.js +2 -2
- package/dist/components/Toast/index.js +1 -1
- package/dist/components/Toast/styles.d.ts +0 -1
- package/dist/components/Toast/styles.js +14 -23
- package/dist/components/Tooltip/Tooltip.d.ts +7 -0
- package/dist/components/Tooltip/Tooltip.js +50 -0
- package/dist/components/Tooltip/__stories__/Tooltip.stories.d.ts +7 -0
- package/dist/components/Tooltip/__tests__/Tooltip.test.d.ts +1 -0
- package/dist/components/Tooltip/__tests__/Tooltip.test.js +25 -0
- package/dist/components/Tooltip/index.d.ts +2 -0
- package/dist/components/Tooltip/index.js +4 -0
- package/dist/components/Tooltip/styles.d.ts +20 -0
- package/dist/components/Tooltip/styles.js +11 -0
- package/dist/components/Typography/Typography.d.ts +5 -1
- package/dist/components/Typography/Typography.js +2 -2
- package/dist/components/Typography/__stories__/Typography.stories.d.ts +1 -0
- package/dist/components/Typography/__tests__/Typography.test.js +2 -2
- package/dist/components/Typography/index.js +1 -1
- package/dist/components/Typography/styles.d.ts +1 -0
- package/dist/components/Typography/styles.js +53 -17
- package/dist/components/index.d.ts +35 -1
- package/dist/components/index.js +58 -24
- package/dist/constants/index.d.ts +4 -0
- package/dist/constants/index.js +4 -2
- package/dist/{context-BMW3aJEf.js → context-DIFtNa4d.js} +230 -233
- package/dist/dropdown-Dp_PTQ2u.js +2045 -0
- package/dist/generateCategoricalChart-7ceYaiZ2.js +15597 -0
- package/dist/genesis/GenesisThemeBreakdown.js +101 -43
- package/dist/genesis/labs/Lab.stories.d.ts +6 -0
- package/dist/genesis/styles.js +7 -2923
- package/dist/iconBase-LROS5hdG.js +112 -0
- package/dist/index-BPVue1Yd.js +445 -0
- package/dist/{index-bKlRxQp4.js → index-BQM5OniU.js} +12 -12
- package/dist/index-BRUI9igj.js +11 -0
- package/dist/index-B_1Ge8na.js +1846 -0
- package/dist/{index-oK7z6jnz.js → index-BbTV2Cw5.js} +8641 -8798
- package/dist/index-BeGv28kJ.js +5173 -0
- package/dist/{index-1CBpubM3.js → index-BpZSuIUV.js} +45 -42
- package/dist/index-BvOLXELm.js +102 -0
- package/dist/index-CLSrpQRW.js +416 -0
- package/dist/index-CbVOl2U6.js +288 -0
- package/dist/index-D0U6r5O7.js +780 -0
- package/dist/index-DEu2PVzQ.js +538 -0
- package/dist/index-DLdU7Tpd.js +183 -0
- package/dist/index-DNQ-jnBx.js +3321 -0
- package/dist/index-DOsPeIWJ.js +1000 -0
- package/dist/{index-C0SmxWLS.js → index-DRGX1Wem.js} +136 -143
- package/dist/index-DWjq9XYj.js +899 -0
- package/dist/index.js +65 -31
- package/dist/interface/address.d.ts +10 -0
- package/dist/interface/address.js +1 -0
- package/dist/interface/appointment.d.ts +57 -0
- package/dist/interface/appointment.js +5 -0
- package/dist/interface/appointmentV2.d.ts +65 -0
- package/dist/interface/appointmentV2.js +1 -0
- package/dist/interface/appointmentsState.d.ts +21 -0
- package/dist/interface/appointmentsState.js +1 -0
- package/dist/interface/common.d.ts +2 -0
- package/dist/interface/common.js +1 -0
- package/dist/interface/completionData.d.ts +18 -0
- package/dist/interface/completionData.js +1 -0
- package/dist/interface/deliveryPartner.d.ts +25 -0
- package/dist/interface/deliveryPartner.js +1 -0
- package/dist/interface/organization.d.ts +9 -0
- package/dist/interface/organization.js +1 -0
- package/dist/interface/pagination.d.ts +8 -0
- package/dist/interface/pagination.js +1 -0
- package/dist/interface/roles.d.ts +9 -0
- package/dist/interface/roles.js +1 -0
- package/dist/interface/route.d.ts +73 -0
- package/dist/interface/route.js +1 -0
- package/dist/interface/routeAnalysis.d.ts +108 -0
- package/dist/interface/routeAnalysis.js +1 -0
- package/dist/interface/routeAutomationJob.d.ts +95 -0
- package/dist/interface/routeAutomationJob.js +10 -0
- package/dist/interface/routeAutomationLog.d.ts +10 -0
- package/dist/interface/routeAutomationLog.js +1 -0
- package/dist/interface/routeEvent.d.ts +55 -0
- package/dist/interface/routeEvent.js +5 -0
- package/dist/interface/serviceArea.d.ts +18 -0
- package/dist/interface/serviceArea.js +1 -0
- package/dist/interface/util.d.ts +3 -0
- package/dist/interface/util.js +1 -0
- package/dist/interface/vehicle.d.ts +120 -0
- package/dist/interface/vehicle.js +1 -0
- package/dist/interface/workOrder.d.ts +22 -0
- package/dist/interface/workOrder.js +1 -0
- package/dist/isVisible-D3-B85BJ.js +22 -0
- package/dist/{magic-string.es-D2FWSwU3.js → magic-string.es-BKBb7z-1.js} +1 -1
- package/dist/motion-CUN72xsH.js +33 -0
- package/dist/omit-B_u6A-HL.js +9 -0
- package/dist/{pickAttrs-B0YTfcV1.js → pickAttrs-CleuMJFR.js} +1 -1
- package/dist/{warning-C63HNL9U.js → presets-Djh_L_6R.js} +333 -356
- package/dist/providers/BreakpointThemeProvider.d.ts +9 -0
- package/dist/providers/BreakpointThemeProvider.js +21 -0
- package/dist/providers/GenesisProvider.js +3 -3
- package/dist/providers/ToastProvider.js +22 -6
- package/dist/providers/index.js +1 -1
- package/dist/providers/useGenesis.js +2 -2
- package/dist/responsiveObserver-dCkpy7Cb.js +73 -0
- package/dist/roundedArrow-DI_Q-xdU.js +65 -0
- package/dist/setup-CUbCc8fQ.js +24706 -0
- package/dist/setup.types-dBtAXXGp.js +8824 -0
- package/dist/shadow-BoMGMNn3.js +13 -0
- package/dist/styleChecker-Cotu61d0.js +21 -0
- package/dist/styles/design-tokens/border-tokens/BorderTokenList.js +29 -13
- package/dist/styles/design-tokens/sizing-tokens/SizingTokenList.d.ts +1 -3
- package/dist/styles/design-tokens/sizing-tokens/SizingTokenList.js +37 -16
- package/dist/styles/design-tokens/sizing-tokens/index.stories.d.ts +0 -1
- package/dist/styles/theme/genesis-theme.js +398 -331
- package/dist/styles/theme/genesis-theme.types.d.ts +53 -12
- package/dist/styles/theme/theme-tree/ThemeTree.d.ts +1 -0
- package/dist/styles/theme/theme-tree/ThemeTree.js +1652 -0
- package/dist/styles/theme/theme-tree/ThemeTree.stories.d.ts +6 -0
- package/dist/styles-CWdUpZom.js +289 -0
- package/dist/{styles-CT_fyXBd.js → styles-D1vKDy9V.js} +587 -643
- package/dist/styles-qerRs7Rn.js +9196 -0
- package/dist/test/setup.d.ts +2 -3
- package/dist/test/setup.js +87 -4
- package/dist/test/setup.types.d.ts +7 -0
- package/dist/test/setup.types.js +1 -0
- package/dist/toArray-U3Az44CO.js +11 -0
- package/dist/useBreakpoint-TkMv121M.js +22 -0
- package/dist/useCSSVarCls-Dau77fzS.js +11 -0
- package/dist/useIcons-Ck4JP1m9.js +321 -0
- package/dist/useId-D2tzlufo.js +26 -0
- package/dist/useLocale-CTfNpakL.js +16 -0
- package/dist/useMergedState-D6toxSxh.js +23 -0
- package/dist/useSize-DSq4r6zy.js +9 -0
- package/dist/{useVariants-DvhXfgJY.js → useVariants-DrLzUVLU.js} +3 -3
- package/dist/useZIndex-DhyHuZTN.js +44 -0
- package/dist/utils/icon-util.d.ts +2 -0
- package/dist/utils/icon-util.js +89 -0
- package/package.json +27 -15
- package/dist/AntdIcon-BoLh1dP8.js +0 -202
- package/dist/ExclamationCircleFilled-C0Kj5KQV.js +0 -21
- package/dist/TextArea-DKwCct3i.js +0 -1690
- package/dist/Typography-aGoDUl4R.js +0 -710
- package/dist/index-BZAhCB_K.js +0 -97
- package/dist/index-CfDY25LP.js +0 -873
- package/dist/index-DPW8XdWj.js +0 -952
- package/dist/isVisible-A-IfeFoT.js +0 -367
- package/dist/providers/ThemeProvider.d.ts +0 -9
- package/dist/providers/ThemeProvider.js +0 -21
- package/dist/setup-BvfREoHl.js +0 -33891
- package/dist/useLocale-DT-z_vQ6.js +0 -16
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/ASN.d.ts +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/ASN.js +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Appointment.d.ts +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Appointment.js +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Inventory.d.ts +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Inventory.js +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Parcel.d.ts +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Parcel.js +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Product.d.ts +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Product.js +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Route.d.ts +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Route.js +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Shipment.d.ts +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/Shipment.js +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/ShoppingCart.d.ts +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/ShoppingCart.js +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/System.d.ts +0 -0
- /package/dist/components/{Badge → Notification/NotificationBadge}/icons/System.js +0 -0
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import { jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { Avatar as a } from "./styles.js";
|
|
3
|
+
import "../Badge/styles.js";
|
|
4
|
+
import "../../providers/BreakpointThemeProvider.js";
|
|
5
|
+
import { a as e } from "../../Typography-CoZ5qD-t.js";
|
|
6
|
+
import "../Breadcrumb/styles.js";
|
|
7
|
+
import "../Button/styles.js";
|
|
8
|
+
import "../Card/styles.js";
|
|
9
|
+
import "../Checkbox/styles.js";
|
|
10
|
+
import "react";
|
|
11
|
+
import "../ErrorBoundaryFallback/styles.js";
|
|
12
|
+
import "../Input/styles.js";
|
|
13
|
+
import "../Layout/Content/styles.js";
|
|
14
|
+
import "../Message/styles.js";
|
|
15
|
+
import "../Notification/NotificationBadge/styles.js";
|
|
16
|
+
import "../Notification/styles.js";
|
|
17
|
+
import "../../styles-CWdUpZom.js";
|
|
18
|
+
import "../Progress/styles.js";
|
|
19
|
+
import "../../styles/global-styles.js";
|
|
20
|
+
import "../Row/styles.js";
|
|
21
|
+
import "../Row/RowLabelValue/styles.js";
|
|
22
|
+
import "../Row/RowActions/styles.js";
|
|
23
|
+
import "../SegmentedControls/styles.js";
|
|
24
|
+
import "../Select/styles.js";
|
|
25
|
+
import "../Switch/styles.js";
|
|
26
|
+
import "../../styles-qerRs7Rn.js";
|
|
27
|
+
import "../Tabs/styles.js";
|
|
28
|
+
import "../Tile/styles.js";
|
|
29
|
+
import "../Toast/styles.js";
|
|
30
|
+
import "../Tooltip/styles.js";
|
|
31
|
+
const M = ({
|
|
32
|
+
size: r = 64,
|
|
33
|
+
shape: o = "circle",
|
|
34
|
+
imageUrl: i,
|
|
35
|
+
altText: p,
|
|
36
|
+
children: m,
|
|
37
|
+
backgroundColor: s = "#00282B"
|
|
38
|
+
}) => typeof m == "string" ? /* @__PURE__ */ t(
|
|
39
|
+
a,
|
|
40
|
+
{
|
|
41
|
+
"data-testid": "avatar",
|
|
42
|
+
shape: o,
|
|
43
|
+
size: r,
|
|
44
|
+
src: i,
|
|
45
|
+
alt: p,
|
|
46
|
+
style: { backgroundColor: s },
|
|
47
|
+
children: /* @__PURE__ */ t(e, { variant: "body2", color: "white", style: { fontWeight: 600 }, children: m })
|
|
48
|
+
}
|
|
49
|
+
) : /* @__PURE__ */ t(
|
|
50
|
+
a,
|
|
51
|
+
{
|
|
52
|
+
"data-testid": "avatar",
|
|
53
|
+
shape: o,
|
|
54
|
+
size: r,
|
|
55
|
+
src: i,
|
|
56
|
+
alt: p
|
|
57
|
+
}
|
|
58
|
+
);
|
|
59
|
+
export {
|
|
60
|
+
M as default
|
|
61
|
+
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Meta, StoryObj } from '@storybook/react';
|
|
2
|
+
import { default as Avatar } from '../Avatar';
|
|
3
|
+
|
|
4
|
+
declare const meta: Meta<typeof Avatar>;
|
|
5
|
+
export default meta;
|
|
6
|
+
type Story = StoryObj<typeof Avatar>;
|
|
7
|
+
export declare const ImageStory: Story;
|
|
8
|
+
export declare const SmallerTextStory: Story;
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { jsx as a } from "react/jsx-runtime";
|
|
2
|
+
import { a as s } from "../../../setup-CUbCc8fQ.js";
|
|
3
|
+
import i from "../Avatar.js";
|
|
4
|
+
describe("<Avatar />", () => {
|
|
5
|
+
let t;
|
|
6
|
+
beforeEach(() => {
|
|
7
|
+
t = {
|
|
8
|
+
imageUrl: "https://lh4.googleusercontent.com/XC0gixA6JwMn7vvYsT2qtoOKPfJuUDKnS0KsCWS2eY0EKg4bgmd46vwQ6MDt29haf-KG8iZ40M1D1pXfPUUWSAtr_Udn0fgdljQDn3qlDHf4yhUUpopObnszdpH6z5oYiA=w1280",
|
|
9
|
+
altText: "User Avatar"
|
|
10
|
+
};
|
|
11
|
+
});
|
|
12
|
+
const r = () => s(/* @__PURE__ */ a(i, { ...t }));
|
|
13
|
+
it("should render avatar image correctly", () => {
|
|
14
|
+
const { getByRole: o } = r(), e = o("img");
|
|
15
|
+
expect(e).toHaveAttribute("src", t.imageUrl), expect(e).toHaveAttribute("alt", t.altText);
|
|
16
|
+
});
|
|
17
|
+
});
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { GenesisTheme } from '../../styles/theme/genesis-theme.types';
|
|
2
|
+
|
|
3
|
+
interface StyledAvatarProps {
|
|
4
|
+
theme?: GenesisTheme;
|
|
5
|
+
type?: "primary" | "secondary";
|
|
6
|
+
state?: "active" | "disabled";
|
|
7
|
+
}
|
|
8
|
+
export declare const getGenesisClass: ({ colors, borderRadius, sizing }: {
|
|
9
|
+
colors: any;
|
|
10
|
+
borderRadius: any;
|
|
11
|
+
sizing: any;
|
|
12
|
+
}, type?: string, state?: string) => string;
|
|
13
|
+
export declare const Avatar: import('styled-components/dist/types').IStyledComponentBase<"web", import('styled-components/dist/types').Substitute<Omit<import('antd').AvatarProps & import('react').RefAttributes<HTMLSpanElement>, "ref"> & {
|
|
14
|
+
ref?: import('react').Ref<HTMLSpanElement>;
|
|
15
|
+
}, StyledAvatarProps>> & string & Omit<import('react').ForwardRefExoticComponent<import('antd').AvatarProps & import('react').RefAttributes<HTMLSpanElement>> & {
|
|
16
|
+
Group: import('react').FC<import('antd/es/avatar').GroupProps>;
|
|
17
|
+
}, keyof import('react').Component<any, {}, any>>;
|
|
18
|
+
export {};
|
|
@@ -0,0 +1,326 @@
|
|
|
1
|
+
import { d as re } from "../../styled-components.browser.esm-CZ1XM4o4.js";
|
|
2
|
+
import * as n from "react";
|
|
3
|
+
import { e as T } from "../../presets-Djh_L_6R.js";
|
|
4
|
+
import { R as oe } from "../../index-BQM5OniU.js";
|
|
5
|
+
import { j as se, m as ae, k as ie, f as ce, t as le, C as D, g as X } from "../../index-BbTV2Cw5.js";
|
|
6
|
+
import { r as de } from "../../responsiveObserver-dCkpy7Cb.js";
|
|
7
|
+
import { u as q } from "../../useCSSVarCls-Dau77fzS.js";
|
|
8
|
+
import { u as ue } from "../../useSize-DSq4r6zy.js";
|
|
9
|
+
import { u as fe } from "../../useBreakpoint-TkMv121M.js";
|
|
10
|
+
import "../../index-DLdU7Tpd.js";
|
|
11
|
+
import { t as me } from "../../toArray-U3Az44CO.js";
|
|
12
|
+
import { c as pe } from "../../reactNode-sKPeiqPL.js";
|
|
13
|
+
import { a as ge } from "../../index-CbVOl2U6.js";
|
|
14
|
+
const B = /* @__PURE__ */ n.createContext({}), ve = (e) => {
|
|
15
|
+
const {
|
|
16
|
+
antCls: r,
|
|
17
|
+
componentCls: o,
|
|
18
|
+
iconCls: t,
|
|
19
|
+
avatarBg: i,
|
|
20
|
+
avatarColor: z,
|
|
21
|
+
containerSize: h,
|
|
22
|
+
containerSizeLG: y,
|
|
23
|
+
containerSizeSM: v,
|
|
24
|
+
textFontSize: g,
|
|
25
|
+
textFontSizeLG: x,
|
|
26
|
+
textFontSizeSM: N,
|
|
27
|
+
borderRadius: u,
|
|
28
|
+
borderRadiusLG: f,
|
|
29
|
+
borderRadiusSM: O,
|
|
30
|
+
lineWidth: j,
|
|
31
|
+
lineType: R
|
|
32
|
+
} = e, E = (s, m, P) => ({
|
|
33
|
+
width: s,
|
|
34
|
+
height: s,
|
|
35
|
+
borderRadius: "50%",
|
|
36
|
+
[`&${o}-square`]: {
|
|
37
|
+
borderRadius: P
|
|
38
|
+
},
|
|
39
|
+
[`&${o}-icon`]: {
|
|
40
|
+
fontSize: m,
|
|
41
|
+
[`> ${t}`]: {
|
|
42
|
+
margin: 0
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
});
|
|
46
|
+
return {
|
|
47
|
+
[o]: Object.assign(Object.assign(Object.assign(Object.assign({}, ie(e)), {
|
|
48
|
+
position: "relative",
|
|
49
|
+
display: "inline-flex",
|
|
50
|
+
justifyContent: "center",
|
|
51
|
+
alignItems: "center",
|
|
52
|
+
overflow: "hidden",
|
|
53
|
+
color: z,
|
|
54
|
+
whiteSpace: "nowrap",
|
|
55
|
+
textAlign: "center",
|
|
56
|
+
verticalAlign: "middle",
|
|
57
|
+
background: i,
|
|
58
|
+
border: `${ce(j)} ${R} transparent`,
|
|
59
|
+
"&-image": {
|
|
60
|
+
background: "transparent"
|
|
61
|
+
},
|
|
62
|
+
[`${r}-image-img`]: {
|
|
63
|
+
display: "block"
|
|
64
|
+
}
|
|
65
|
+
}), E(h, g, u)), {
|
|
66
|
+
"&-lg": Object.assign({}, E(y, x, f)),
|
|
67
|
+
"&-sm": Object.assign({}, E(v, N, O)),
|
|
68
|
+
"> img": {
|
|
69
|
+
display: "block",
|
|
70
|
+
width: "100%",
|
|
71
|
+
height: "100%",
|
|
72
|
+
objectFit: "cover"
|
|
73
|
+
}
|
|
74
|
+
})
|
|
75
|
+
};
|
|
76
|
+
}, Se = (e) => {
|
|
77
|
+
const {
|
|
78
|
+
componentCls: r,
|
|
79
|
+
groupBorderColor: o,
|
|
80
|
+
groupOverlapping: t,
|
|
81
|
+
groupSpace: i
|
|
82
|
+
} = e;
|
|
83
|
+
return {
|
|
84
|
+
[`${r}-group`]: {
|
|
85
|
+
display: "inline-flex",
|
|
86
|
+
[r]: {
|
|
87
|
+
borderColor: o
|
|
88
|
+
},
|
|
89
|
+
"> *:not(:first-child)": {
|
|
90
|
+
marginInlineStart: t
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
[`${r}-group-popover`]: {
|
|
94
|
+
[`${r} + ${r}`]: {
|
|
95
|
+
marginInlineStart: i
|
|
96
|
+
}
|
|
97
|
+
}
|
|
98
|
+
};
|
|
99
|
+
}, he = (e) => {
|
|
100
|
+
const {
|
|
101
|
+
controlHeight: r,
|
|
102
|
+
controlHeightLG: o,
|
|
103
|
+
controlHeightSM: t,
|
|
104
|
+
fontSize: i,
|
|
105
|
+
fontSizeLG: z,
|
|
106
|
+
fontSizeXL: h,
|
|
107
|
+
fontSizeHeading3: y,
|
|
108
|
+
marginXS: v,
|
|
109
|
+
marginXXS: g,
|
|
110
|
+
colorBorderBg: x
|
|
111
|
+
} = e;
|
|
112
|
+
return {
|
|
113
|
+
containerSize: r,
|
|
114
|
+
containerSizeLG: o,
|
|
115
|
+
containerSizeSM: t,
|
|
116
|
+
textFontSize: Math.round((z + h) / 2),
|
|
117
|
+
textFontSizeLG: y,
|
|
118
|
+
textFontSizeSM: i,
|
|
119
|
+
groupSpace: g,
|
|
120
|
+
groupOverlapping: -v,
|
|
121
|
+
groupBorderColor: x
|
|
122
|
+
};
|
|
123
|
+
}, U = se("Avatar", (e) => {
|
|
124
|
+
const {
|
|
125
|
+
colorTextLightSolid: r,
|
|
126
|
+
colorTextPlaceholder: o
|
|
127
|
+
} = e, t = ae(e, {
|
|
128
|
+
avatarBg: o,
|
|
129
|
+
avatarColor: r
|
|
130
|
+
});
|
|
131
|
+
return [ve(t), Se(t)];
|
|
132
|
+
}, he);
|
|
133
|
+
var ye = function(e, r) {
|
|
134
|
+
var o = {};
|
|
135
|
+
for (var t in e) Object.prototype.hasOwnProperty.call(e, t) && r.indexOf(t) < 0 && (o[t] = e[t]);
|
|
136
|
+
if (e != null && typeof Object.getOwnPropertySymbols == "function") for (var i = 0, t = Object.getOwnPropertySymbols(e); i < t.length; i++)
|
|
137
|
+
r.indexOf(t[i]) < 0 && Object.prototype.propertyIsEnumerable.call(e, t[i]) && (o[t[i]] = e[t[i]]);
|
|
138
|
+
return o;
|
|
139
|
+
};
|
|
140
|
+
const xe = (e, r) => {
|
|
141
|
+
const [o, t] = n.useState(1), [i, z] = n.useState(!1), [h, y] = n.useState(!0), v = n.useRef(null), g = n.useRef(null), x = le(r, v), {
|
|
142
|
+
getPrefixCls: N,
|
|
143
|
+
avatar: u
|
|
144
|
+
} = n.useContext(D), f = n.useContext(B), O = () => {
|
|
145
|
+
if (!g.current || !v.current)
|
|
146
|
+
return;
|
|
147
|
+
const c = g.current.offsetWidth, l = v.current.offsetWidth;
|
|
148
|
+
if (c !== 0 && l !== 0) {
|
|
149
|
+
const {
|
|
150
|
+
gap: S = 4
|
|
151
|
+
} = e;
|
|
152
|
+
S * 2 < l && t(l - S * 2 < c ? (l - S * 2) / c : 1);
|
|
153
|
+
}
|
|
154
|
+
};
|
|
155
|
+
n.useEffect(() => {
|
|
156
|
+
z(!0);
|
|
157
|
+
}, []), n.useEffect(() => {
|
|
158
|
+
y(!0), t(1);
|
|
159
|
+
}, [e.src]), n.useEffect(O, [e.gap]);
|
|
160
|
+
const j = () => {
|
|
161
|
+
const {
|
|
162
|
+
onError: c
|
|
163
|
+
} = e;
|
|
164
|
+
(c == null ? void 0 : c()) !== !1 && y(!1);
|
|
165
|
+
}, {
|
|
166
|
+
prefixCls: R,
|
|
167
|
+
shape: E,
|
|
168
|
+
size: s,
|
|
169
|
+
src: m,
|
|
170
|
+
srcSet: P,
|
|
171
|
+
icon: p,
|
|
172
|
+
className: A,
|
|
173
|
+
rootClassName: M,
|
|
174
|
+
alt: V,
|
|
175
|
+
draggable: _,
|
|
176
|
+
children: C,
|
|
177
|
+
crossOrigin: $
|
|
178
|
+
} = e, b = ye(e, ["prefixCls", "shape", "size", "src", "srcSet", "icon", "className", "rootClassName", "alt", "draggable", "children", "crossOrigin"]), a = ue((c) => {
|
|
179
|
+
var l, S;
|
|
180
|
+
return (S = (l = s ?? (f == null ? void 0 : f.size)) !== null && l !== void 0 ? l : c) !== null && S !== void 0 ? S : "default";
|
|
181
|
+
}), w = Object.keys(typeof a == "object" ? a || {} : {}).some((c) => ["xs", "sm", "md", "lg", "xl", "xxl"].includes(c)), G = fe(w), L = n.useMemo(() => {
|
|
182
|
+
if (typeof a != "object")
|
|
183
|
+
return {};
|
|
184
|
+
const c = de.find((S) => G[S]), l = a[c];
|
|
185
|
+
return l ? {
|
|
186
|
+
width: l,
|
|
187
|
+
height: l,
|
|
188
|
+
fontSize: l && (p || C) ? l / 2 : 18
|
|
189
|
+
} : {};
|
|
190
|
+
}, [G, a]);
|
|
191
|
+
if (process.env.NODE_ENV !== "production") {
|
|
192
|
+
const c = X("Avatar");
|
|
193
|
+
process.env.NODE_ENV !== "production" && c(!(typeof p == "string" && p.length > 2), "breaking", `\`icon\` is using ReactNode instead of string naming in v4. Please check \`${p}\` at https://ant.design/components/icon`);
|
|
194
|
+
}
|
|
195
|
+
const d = N("avatar", R), I = q(d), [K, Q, Y] = U(d, I), Z = T({
|
|
196
|
+
[`${d}-lg`]: a === "large",
|
|
197
|
+
[`${d}-sm`]: a === "small"
|
|
198
|
+
}), W = /* @__PURE__ */ n.isValidElement(m), ee = E || (f == null ? void 0 : f.shape) || "circle", te = T(d, Z, u == null ? void 0 : u.className, `${d}-${ee}`, {
|
|
199
|
+
[`${d}-image`]: W || m && h,
|
|
200
|
+
[`${d}-icon`]: !!p
|
|
201
|
+
}, Y, I, A, M, Q), ne = typeof a == "number" ? {
|
|
202
|
+
width: a,
|
|
203
|
+
height: a,
|
|
204
|
+
fontSize: p ? a / 2 : 18
|
|
205
|
+
} : {};
|
|
206
|
+
let k;
|
|
207
|
+
if (typeof m == "string" && h)
|
|
208
|
+
k = /* @__PURE__ */ n.createElement("img", {
|
|
209
|
+
src: m,
|
|
210
|
+
draggable: _,
|
|
211
|
+
srcSet: P,
|
|
212
|
+
onError: j,
|
|
213
|
+
alt: V,
|
|
214
|
+
crossOrigin: $
|
|
215
|
+
});
|
|
216
|
+
else if (W)
|
|
217
|
+
k = m;
|
|
218
|
+
else if (p)
|
|
219
|
+
k = p;
|
|
220
|
+
else if (i || o !== 1) {
|
|
221
|
+
const c = `scale(${o})`, l = {
|
|
222
|
+
msTransform: c,
|
|
223
|
+
WebkitTransform: c,
|
|
224
|
+
transform: c
|
|
225
|
+
};
|
|
226
|
+
k = /* @__PURE__ */ n.createElement(oe, {
|
|
227
|
+
onResize: O
|
|
228
|
+
}, /* @__PURE__ */ n.createElement("span", {
|
|
229
|
+
className: `${d}-string`,
|
|
230
|
+
ref: g,
|
|
231
|
+
style: Object.assign({}, l)
|
|
232
|
+
}, C));
|
|
233
|
+
} else
|
|
234
|
+
k = /* @__PURE__ */ n.createElement("span", {
|
|
235
|
+
className: `${d}-string`,
|
|
236
|
+
style: {
|
|
237
|
+
opacity: 0
|
|
238
|
+
},
|
|
239
|
+
ref: g
|
|
240
|
+
}, C);
|
|
241
|
+
return delete b.onError, delete b.gap, K(/* @__PURE__ */ n.createElement("span", Object.assign({}, b, {
|
|
242
|
+
style: Object.assign(Object.assign(Object.assign(Object.assign({}, ne), L), u == null ? void 0 : u.style), b.style),
|
|
243
|
+
className: te,
|
|
244
|
+
ref: x
|
|
245
|
+
}), k));
|
|
246
|
+
}, F = /* @__PURE__ */ n.forwardRef(xe);
|
|
247
|
+
process.env.NODE_ENV !== "production" && (F.displayName = "Avatar");
|
|
248
|
+
const H = (e) => {
|
|
249
|
+
const {
|
|
250
|
+
size: r,
|
|
251
|
+
shape: o
|
|
252
|
+
} = n.useContext(B), t = n.useMemo(() => ({
|
|
253
|
+
size: e.size || r,
|
|
254
|
+
shape: e.shape || o
|
|
255
|
+
}), [e.size, e.shape, r, o]);
|
|
256
|
+
return /* @__PURE__ */ n.createElement(B.Provider, {
|
|
257
|
+
value: t
|
|
258
|
+
}, e.children);
|
|
259
|
+
}, Ce = (e) => {
|
|
260
|
+
var r, o, t, i;
|
|
261
|
+
const {
|
|
262
|
+
getPrefixCls: z,
|
|
263
|
+
direction: h
|
|
264
|
+
} = n.useContext(D), {
|
|
265
|
+
prefixCls: y,
|
|
266
|
+
className: v,
|
|
267
|
+
rootClassName: g,
|
|
268
|
+
style: x,
|
|
269
|
+
maxCount: N,
|
|
270
|
+
maxStyle: u,
|
|
271
|
+
size: f,
|
|
272
|
+
shape: O,
|
|
273
|
+
maxPopoverPlacement: j,
|
|
274
|
+
maxPopoverTrigger: R,
|
|
275
|
+
children: E,
|
|
276
|
+
max: s
|
|
277
|
+
} = e;
|
|
278
|
+
if (process.env.NODE_ENV !== "production") {
|
|
279
|
+
const a = X("Avatar.Group");
|
|
280
|
+
a.deprecated(!N, "maxCount", "max={{ count: number }}"), a.deprecated(!u, "maxStyle", "max={{ style: CSSProperties }}"), a.deprecated(!j, "maxPopoverPlacement", "max={{ popover: PopoverProps }}"), a.deprecated(!R, "maxPopoverTrigger", "max={{ popover: PopoverProps }}");
|
|
281
|
+
}
|
|
282
|
+
const m = z("avatar", y), P = `${m}-group`, p = q(m), [A, M, V] = U(m, p), _ = T(P, {
|
|
283
|
+
[`${P}-rtl`]: h === "rtl"
|
|
284
|
+
}, V, p, v, g, M), C = me(E).map((a, w) => pe(a, {
|
|
285
|
+
// eslint-disable-next-line react/no-array-index-key
|
|
286
|
+
key: `avatar-key-${w}`
|
|
287
|
+
})), $ = (s == null ? void 0 : s.count) || N, b = C.length;
|
|
288
|
+
if ($ && $ < b) {
|
|
289
|
+
const a = C.slice(0, $), w = C.slice($, b), G = (s == null ? void 0 : s.style) || u, L = ((r = s == null ? void 0 : s.popover) === null || r === void 0 ? void 0 : r.trigger) || R || "hover", d = ((o = s == null ? void 0 : s.popover) === null || o === void 0 ? void 0 : o.placement) || j || "top", I = Object.assign(Object.assign({
|
|
290
|
+
content: w
|
|
291
|
+
}, s == null ? void 0 : s.popover), {
|
|
292
|
+
classNames: {
|
|
293
|
+
root: T(`${P}-popover`, (i = (t = s == null ? void 0 : s.popover) === null || t === void 0 ? void 0 : t.classNames) === null || i === void 0 ? void 0 : i.root)
|
|
294
|
+
},
|
|
295
|
+
placement: d,
|
|
296
|
+
trigger: L
|
|
297
|
+
});
|
|
298
|
+
return a.push(/* @__PURE__ */ n.createElement(ge, Object.assign({
|
|
299
|
+
key: "avatar-popover-key",
|
|
300
|
+
destroyTooltipOnHide: !0
|
|
301
|
+
}, I), /* @__PURE__ */ n.createElement(F, {
|
|
302
|
+
style: G
|
|
303
|
+
}, `+${b - $}`))), A(/* @__PURE__ */ n.createElement(H, {
|
|
304
|
+
shape: O,
|
|
305
|
+
size: f
|
|
306
|
+
}, /* @__PURE__ */ n.createElement("div", {
|
|
307
|
+
className: _,
|
|
308
|
+
style: x
|
|
309
|
+
}, a)));
|
|
310
|
+
}
|
|
311
|
+
return A(/* @__PURE__ */ n.createElement(H, {
|
|
312
|
+
shape: O,
|
|
313
|
+
size: f
|
|
314
|
+
}, /* @__PURE__ */ n.createElement("div", {
|
|
315
|
+
className: _,
|
|
316
|
+
style: x
|
|
317
|
+
}, C)));
|
|
318
|
+
}, J = F;
|
|
319
|
+
J.Group = Ce;
|
|
320
|
+
const be = ({ colors: e, borderRadius: r, sizing: o }, t = "primary", i = "active") => "", Ge = re(J)`
|
|
321
|
+
${({ theme: e, type: r, state: o }) => be(e, r, o)}
|
|
322
|
+
`;
|
|
323
|
+
export {
|
|
324
|
+
Ge as Avatar,
|
|
325
|
+
be as getGenesisClass
|
|
326
|
+
};
|
|
@@ -1,6 +1,8 @@
|
|
|
1
|
+
export type State = "success" | "warning" | "error" | "info" | "generic" | "hollow";
|
|
1
2
|
export interface BadgeProps {
|
|
2
|
-
|
|
3
|
-
|
|
3
|
+
label?: string;
|
|
4
|
+
isDisabled?: boolean;
|
|
5
|
+
state?: State;
|
|
4
6
|
}
|
|
5
|
-
declare const Badge: ({
|
|
7
|
+
declare const Badge: ({ label, state, isDisabled, ...rest }: BadgeProps) => import("react/jsx-runtime").JSX.Element;
|
|
6
8
|
export default Badge;
|
|
@@ -1,103 +1,70 @@
|
|
|
1
|
-
import { jsx as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import {
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
return /* @__PURE__ */
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
return /* @__PURE__ */ r(d, { style: { color: e, fontSize: s } });
|
|
68
|
-
case t.info:
|
|
69
|
-
default:
|
|
70
|
-
return /* @__PURE__ */ r(m, { style: { color: e, fontSize: s } });
|
|
71
|
-
}
|
|
72
|
-
}, j = (o) => {
|
|
73
|
-
switch (o) {
|
|
74
|
-
case n.appointment:
|
|
75
|
-
return /* @__PURE__ */ r(g, {});
|
|
76
|
-
case n.asn:
|
|
77
|
-
return /* @__PURE__ */ r(v, {});
|
|
78
|
-
case n.inventory:
|
|
79
|
-
return /* @__PURE__ */ r(C, {});
|
|
80
|
-
case n.parcel:
|
|
81
|
-
return /* @__PURE__ */ r(h, {});
|
|
82
|
-
case n.product:
|
|
83
|
-
return /* @__PURE__ */ r(S, {});
|
|
84
|
-
case n.route:
|
|
85
|
-
return /* @__PURE__ */ r(I, {});
|
|
86
|
-
case n.shipment:
|
|
87
|
-
return /* @__PURE__ */ r(z, {});
|
|
88
|
-
case n.shoppingCart:
|
|
89
|
-
return /* @__PURE__ */ r(y, {});
|
|
90
|
-
case n.system:
|
|
91
|
-
default:
|
|
92
|
-
return /* @__PURE__ */ r(B, {});
|
|
93
|
-
}
|
|
94
|
-
}, oe = ({ badge: o = n.product, state: e = t.info }) => {
|
|
95
|
-
const a = F(), f = A(e, a);
|
|
96
|
-
return /* @__PURE__ */ r(R, { children: /* @__PURE__ */ p(w, { "data-testid": "Badge", children: [
|
|
97
|
-
/* @__PURE__ */ r(E, { "data-testid": "BadgeState", color: f, children: O(e, f) }),
|
|
98
|
-
j(o)
|
|
99
|
-
] }) });
|
|
1
|
+
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
+
import { Badge as e } from "./styles.js";
|
|
3
|
+
import "../Avatar/styles.js";
|
|
4
|
+
import "../Breadcrumb/styles.js";
|
|
5
|
+
import "../../providers/BreakpointThemeProvider.js";
|
|
6
|
+
import { u as a, a as d } from "../../Typography-CoZ5qD-t.js";
|
|
7
|
+
import "../Button/styles.js";
|
|
8
|
+
import "../Card/styles.js";
|
|
9
|
+
import "../Checkbox/styles.js";
|
|
10
|
+
import "react";
|
|
11
|
+
import "../ErrorBoundaryFallback/styles.js";
|
|
12
|
+
import "../Input/styles.js";
|
|
13
|
+
import "../Layout/Content/styles.js";
|
|
14
|
+
import "../Message/styles.js";
|
|
15
|
+
import "../Notification/NotificationBadge/styles.js";
|
|
16
|
+
import { getBadgeStateIcon as s } from "../../utils/icon-util.js";
|
|
17
|
+
import "../Notification/styles.js";
|
|
18
|
+
import "../../styles-CWdUpZom.js";
|
|
19
|
+
import "../Progress/styles.js";
|
|
20
|
+
import "../../styles/global-styles.js";
|
|
21
|
+
import "../Row/styles.js";
|
|
22
|
+
import "../Row/RowLabelValue/styles.js";
|
|
23
|
+
import "../Row/RowActions/styles.js";
|
|
24
|
+
import "../SegmentedControls/styles.js";
|
|
25
|
+
import "../Select/styles.js";
|
|
26
|
+
import "../Switch/styles.js";
|
|
27
|
+
import "../../styles-qerRs7Rn.js";
|
|
28
|
+
import "../Tabs/styles.js";
|
|
29
|
+
import "../Tile/styles.js";
|
|
30
|
+
import "../Toast/styles.js";
|
|
31
|
+
import "../Tooltip/styles.js";
|
|
32
|
+
const n = !1, O = ({ label: r, state: o = "info", isDisabled: t, ...p }) => {
|
|
33
|
+
const { theme: i } = a();
|
|
34
|
+
return r ? /* @__PURE__ */ m(
|
|
35
|
+
e,
|
|
36
|
+
{
|
|
37
|
+
label: r,
|
|
38
|
+
role: "badge",
|
|
39
|
+
state: o,
|
|
40
|
+
disabled: t,
|
|
41
|
+
...p,
|
|
42
|
+
children: /* @__PURE__ */ m(
|
|
43
|
+
d,
|
|
44
|
+
{
|
|
45
|
+
variant: "label2",
|
|
46
|
+
color: t ? i.colors.status.disabled.default : i.colors.status[o].onsurface,
|
|
47
|
+
isDisabled: t,
|
|
48
|
+
children: r
|
|
49
|
+
}
|
|
50
|
+
)
|
|
51
|
+
}
|
|
52
|
+
) : /* @__PURE__ */ m(
|
|
53
|
+
e,
|
|
54
|
+
{
|
|
55
|
+
label: r,
|
|
56
|
+
role: "badge",
|
|
57
|
+
state: o,
|
|
58
|
+
disabled: t,
|
|
59
|
+
...p,
|
|
60
|
+
children: s(
|
|
61
|
+
o,
|
|
62
|
+
i.colors.status[o].onsurface,
|
|
63
|
+
n
|
|
64
|
+
)
|
|
65
|
+
}
|
|
66
|
+
);
|
|
100
67
|
};
|
|
101
68
|
export {
|
|
102
|
-
|
|
69
|
+
O as default
|
|
103
70
|
};
|
|
@@ -6,8 +6,9 @@ export default meta;
|
|
|
6
6
|
type Story = StoryObj<typeof Badge>;
|
|
7
7
|
export declare const Default: Story;
|
|
8
8
|
export declare const Success: Story;
|
|
9
|
-
export declare const Warning: Story;
|
|
10
|
-
export declare const Removed: Story;
|
|
11
|
-
export declare const Progress: Story;
|
|
12
9
|
export declare const Error: Story;
|
|
13
|
-
export declare const
|
|
10
|
+
export declare const Warning: Story;
|
|
11
|
+
export declare const Generic: Story;
|
|
12
|
+
export declare const Hollow: Story;
|
|
13
|
+
export declare const Disabled: Story;
|
|
14
|
+
export declare const Icon: Story;
|