@conveyorhq/arrow-ds 1.62.0 → 2.0.0-beta.10
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/package.json +3 -2
- package/public/components/Avatar/Avatar.d.ts +2 -1
- package/public/components/Avatar/Avatar.js +8 -4
- package/public/components/DateRangePicker/CustomDateRangeInput.js +3 -2
- package/public/components/Drawer/Drawer.js +4 -2
- package/public/components/MarkdownEditor/MarkdownEditor.js +1 -2
- package/public/components/MarkdownEditor/MarkdownHelp.js +4 -7
- package/public/components/MenuRenderer/MenuRenderer.js +2 -2
- package/public/components/Modal/Modal.d.ts +8 -4
- package/public/components/Modal/Modal.js +23 -60
- package/public/components/Overlay/Overlay.js +2 -2
- package/public/components/Popover/Popover.js +4 -4
- package/public/components/SelectNew/hooks/useSelectLayout.js +2 -2
- package/public/components/Stack/Stack.js +1 -1
- package/public/components/Table/FilterDropdown.js +4 -4
- package/public/components/Toast/Toast.d.ts +3 -3
- package/public/components/Toast/Toast.js +6 -2
- package/public/components/Tooltip/Tooltip.d.ts +8 -4
- package/public/components/Tooltip/Tooltip.js +96 -97
- package/public/css/styles.css +2959 -4517
- package/public/css/styles.min.css +1 -1
- package/public/css/styles.min.css.map +1 -1
- package/public/hooks/index.d.ts +1 -0
- package/public/hooks/index.js +3 -1
- package/public/hooks/useCopyToClipboard.d.ts +1 -0
- package/public/hooks/useCopyToClipboard.js +49 -0
- package/public/index.d.ts +1 -22
- package/public/index.js +2 -23
- package/public/storybook-components/ComponentHeading.js +1 -3
- package/public/types/index.d.ts +0 -16
- package/public/types/index.js +1 -20
- package/public/utilities/index.d.ts +1 -0
- package/public/utilities/index.js +3 -1
- package/public/utilities/mergeEventHandlers.d.ts +3 -0
- package/public/utilities/mergeEventHandlers.js +13 -0
- package/src/components/Accordion/Accordion.story.mdx +6 -7
- package/src/components/Avatar/Avatar.tsx +42 -39
- package/src/components/Banner/Banner.story.mdx +4 -12
- package/src/components/Card/Card.story.mdx +11 -36
- package/src/components/DateRangePicker/CustomDateRangeInput.tsx +25 -32
- package/src/components/DateRangePicker/index.css +0 -4
- package/src/components/Drawer/Drawer.story.mdx +68 -70
- package/src/components/Drawer/Drawer.tsx +9 -8
- package/src/components/Drawer/index.css +26 -1
- package/src/components/Frame/Frame.story.mdx +6 -1
- package/src/components/MarkdownEditor/MarkdownEditor.tsx +2 -3
- package/src/components/MarkdownEditor/MarkdownHelp.tsx +7 -10
- package/src/components/MarkdownEditor/index.css +5 -1
- package/src/components/MenuRenderer/MenuRenderer.tsx +1 -1
- package/src/components/Modal/Modal.story.mdx +135 -3
- package/src/components/Modal/Modal.tsx +69 -100
- package/src/components/Modal/index.css +2 -2
- package/src/components/Overlay/Overlay.tsx +2 -3
- package/src/components/Overlay/index.css +2 -1
- package/src/components/Popover/Popover.tsx +1 -1
- package/src/components/Select/Select.story.mdx +9 -10
- package/src/components/Select/SelectPopover.tsx +1 -1
- package/src/components/SelectNew/hooks/useSelectLayout.ts +1 -1
- package/src/components/Stack/Stack.tsx +1 -1
- package/src/components/Stack/index.css +0 -416
- package/src/components/Table/FilterDropdown.tsx +1 -1
- package/src/components/Toast/Toast.story.mdx +1 -1
- package/src/components/Toast/Toast.tsx +14 -10
- package/src/components/Toast/index.css +2 -2
- package/src/components/Tooltip/Tooltip.story.mdx +270 -126
- package/src/components/Tooltip/Tooltip.tsx +197 -114
- package/src/components/Tooltip/index.css +18 -13
- package/src/css/components.css +0 -13
- package/src/hooks/index.ts +1 -0
- package/src/hooks/useCopyToClipboard.ts +61 -0
- package/src/index.ts +1 -22
- package/src/storybook-components/ComponentHeading.tsx +1 -16
- package/src/types/index.ts +0 -28
- package/src/utilities/index.ts +1 -0
- package/src/utilities/mergeEventHandlers.ts +20 -0
- package/public/components/Absolute/Absolute.d.ts +0 -2
- package/public/components/Absolute/Absolute.js +0 -14
- package/public/components/Absolute/index.d.ts +0 -1
- package/public/components/Absolute/index.js +0 -5
- package/public/components/Appbar/Appbar.d.ts +0 -61
- package/public/components/Appbar/Appbar.js +0 -44
- package/public/components/Appbar/AppbarClaimProfileButton.d.ts +0 -2
- package/public/components/Appbar/AppbarClaimProfileButton.js +0 -10
- package/public/components/Appbar/AppbarDropdownIcon.d.ts +0 -1
- package/public/components/Appbar/AppbarDropdownIcon.js +0 -10
- package/public/components/Appbar/AppbarLogInButton.d.ts +0 -2
- package/public/components/Appbar/AppbarLogInButton.js +0 -25
- package/public/components/Appbar/AppbarLogo.d.ts +0 -2
- package/public/components/Appbar/AppbarLogo.js +0 -31
- package/public/components/Appbar/AppbarOrganization.d.ts +0 -17
- package/public/components/Appbar/AppbarOrganization.js +0 -35
- package/public/components/Appbar/AppbarProductMenu.d.ts +0 -13
- package/public/components/Appbar/AppbarProductMenu.js +0 -67
- package/public/components/Appbar/AppbarTabMarker.d.ts +0 -1
- package/public/components/Appbar/AppbarTabMarker.js +0 -11
- package/public/components/Appbar/AppbarTabs.d.ts +0 -10
- package/public/components/Appbar/AppbarTabs.js +0 -42
- package/public/components/Appbar/AppbarUser.d.ts +0 -27
- package/public/components/Appbar/AppbarUser.js +0 -76
- package/public/components/Appbar/config.d.ts +0 -7
- package/public/components/Appbar/config.js +0 -13
- package/public/components/Appbar/context.d.ts +0 -10
- package/public/components/Appbar/context.js +0 -16
- package/public/components/Appbar/index.d.ts +0 -1
- package/public/components/Appbar/index.js +0 -13
- package/public/components/AptibleLogo/AptibleLogo.d.ts +0 -7
- package/public/components/AptibleLogo/AptibleLogo.js +0 -25
- package/public/components/AptibleLogo/index.d.ts +0 -1
- package/public/components/AptibleLogo/index.js +0 -5
- package/public/components/ArrowButton/ArrowButton.d.ts +0 -9
- package/public/components/ArrowButton/ArrowButton.js +0 -22
- package/public/components/ArrowButton/index.d.ts +0 -1
- package/public/components/ArrowButton/index.js +0 -13
- package/public/components/ArrowLink/ArrowLink.d.ts +0 -9
- package/public/components/ArrowLink/ArrowLink.js +0 -21
- package/public/components/ArrowLink/index.d.ts +0 -1
- package/public/components/ArrowLink/index.js +0 -13
- package/public/components/Aside/Aside.d.ts +0 -14
- package/public/components/Aside/Aside.js +0 -28
- package/public/components/Aside/index.d.ts +0 -1
- package/public/components/Aside/index.js +0 -13
- package/public/components/Combobox/Combobox.d.ts +0 -2
- package/public/components/Combobox/Combobox.js +0 -75
- package/public/components/Combobox/ComboboxMulti.d.ts +0 -2
- package/public/components/Combobox/ComboboxMulti.js +0 -57
- package/public/components/Combobox/index.d.ts +0 -2
- package/public/components/Combobox/index.js +0 -14
- package/public/components/Combobox/ui.d.ts +0 -73
- package/public/components/Combobox/ui.js +0 -97
- package/public/components/Combobox/useSelect.d.ts +0 -60
- package/public/components/Combobox/useSelect.js +0 -239
- package/public/components/Fixed/Fixed.d.ts +0 -2
- package/public/components/Fixed/Fixed.js +0 -14
- package/public/components/Fixed/index.d.ts +0 -1
- package/public/components/Fixed/index.js +0 -5
- package/public/components/IntegrationLogo/IntegrationLogo.d.ts +0 -10
- package/public/components/IntegrationLogo/IntegrationLogo.js +0 -35
- package/public/components/IntegrationLogo/IntegrationLogoSvg.d.ts +0 -9
- package/public/components/IntegrationLogo/IntegrationLogoSvg.js +0 -56
- package/public/components/IntegrationLogo/index.d.ts +0 -1
- package/public/components/IntegrationLogo/index.js +0 -13
- package/public/components/IntegrationLogo/svg/addigy.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/addigy.js +0 -17
- package/public/components/IntegrationLogo/svg/aws.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/aws.js +0 -22
- package/public/components/IntegrationLogo/svg/bamboohr.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/bamboohr.js +0 -18
- package/public/components/IntegrationLogo/svg/bitbucket.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/bitbucket.js +0 -18
- package/public/components/IntegrationLogo/svg/conveyor.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/conveyor.js +0 -20
- package/public/components/IntegrationLogo/svg/default.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/default.js +0 -13
- package/public/components/IntegrationLogo/svg/deploy.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/deploy.js +0 -17
- package/public/components/IntegrationLogo/svg/docusign.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/docusign.js +0 -32
- package/public/components/IntegrationLogo/svg/events-api.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/events-api.js +0 -26
- package/public/components/IntegrationLogo/svg/gcp.d.ts +0 -3
- package/public/components/IntegrationLogo/svg/gcp.js +0 -15
- package/public/components/IntegrationLogo/svg/github.d.ts +0 -3
- package/public/components/IntegrationLogo/svg/github.js +0 -12
- package/public/components/IntegrationLogo/svg/gitlab.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/gitlab.js +0 -19
- package/public/components/IntegrationLogo/svg/gsuite.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/gsuite.js +0 -15
- package/public/components/IntegrationLogo/svg/index.d.ts +0 -23
- package/public/components/IntegrationLogo/svg/index.js +0 -58
- package/public/components/IntegrationLogo/svg/jamf.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/jamf.js +0 -20
- package/public/components/IntegrationLogo/svg/jira.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/jira.js +0 -21
- package/public/components/IntegrationLogo/svg/jumpcloud.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/jumpcloud.js +0 -28
- package/public/components/IntegrationLogo/svg/okta.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/okta.js +0 -16
- package/public/components/IntegrationLogo/svg/onelogin.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/onelogin.js +0 -18
- package/public/components/IntegrationLogo/svg/salesforce.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/salesforce.js +0 -20
- package/public/components/IntegrationLogo/svg/servicenow.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/servicenow.js +0 -14
- package/public/components/IntegrationLogo/svg/slack.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/slack.js +0 -19
- package/public/components/IntegrationLogo/svg/wrapper.d.ts +0 -11
- package/public/components/IntegrationLogo/svg/wrapper.js +0 -13
- package/public/components/IntegrationLogo/svg/zoom.d.ts +0 -2
- package/public/components/IntegrationLogo/svg/zoom.js +0 -23
- package/public/components/Meta/Meta.d.ts +0 -6
- package/public/components/Meta/Meta.js +0 -21
- package/public/components/Meta/Meta.story.d.ts +0 -1
- package/public/components/Meta/Meta.story.js +0 -39
- package/public/components/Meta/index.d.ts +0 -1
- package/public/components/Meta/index.js +0 -5
- package/public/components/Pagination/Pagination.d.ts +0 -9
- package/public/components/Pagination/Pagination.js +0 -36
- package/public/components/Pagination/index.d.ts +0 -1
- package/public/components/Pagination/index.js +0 -13
- package/public/components/ProductIcon/ProductIcon.d.ts +0 -7
- package/public/components/ProductIcon/ProductIcon.js +0 -31
- package/public/components/ProductIcon/ProductIconComply.d.ts +0 -2
- package/public/components/ProductIcon/ProductIconComply.js +0 -11
- package/public/components/ProductIcon/ProductIconDeploy.d.ts +0 -2
- package/public/components/ProductIcon/ProductIconDeploy.js +0 -11
- package/public/components/ProductIcon/ProductIconExchange.d.ts +0 -2
- package/public/components/ProductIcon/ProductIconExchange.js +0 -11
- package/public/components/ProductIcon/ProductIconTrustCenter.d.ts +0 -2
- package/public/components/ProductIcon/ProductIconTrustCenter.js +0 -11
- package/public/components/ProductIcon/index.d.ts +0 -1
- package/public/components/ProductIcon/index.js +0 -5
- package/public/components/PropertyDiff/PropertyDiff.d.ts +0 -7
- package/public/components/PropertyDiff/PropertyDiff.js +0 -22
- package/public/components/PropertyDiff/index.d.ts +0 -1
- package/public/components/PropertyDiff/index.js +0 -13
- package/public/components/Relative/Relative.d.ts +0 -2
- package/public/components/Relative/Relative.js +0 -14
- package/public/components/Relative/index.d.ts +0 -1
- package/public/components/Relative/index.js +0 -5
- package/public/components/SearchFilter/SearchFilter.d.ts +0 -17
- package/public/components/SearchFilter/SearchFilter.js +0 -103
- package/public/components/SearchFilter/index.d.ts +0 -1
- package/public/components/SearchFilter/index.js +0 -13
- package/public/components/StatusLabel/StatusLabel.d.ts +0 -16
- package/public/components/StatusLabel/StatusLabel.js +0 -40
- package/public/components/StatusLabel/index.d.ts +0 -1
- package/public/components/StatusLabel/index.js +0 -13
- package/public/components/StatusPanel/StatusPanel.d.ts +0 -11
- package/public/components/StatusPanel/StatusPanel.js +0 -24
- package/public/components/StatusPanel/index.d.ts +0 -1
- package/public/components/StatusPanel/index.js +0 -13
- package/public/components/Sticky/Sticky.d.ts +0 -2
- package/public/components/Sticky/Sticky.js +0 -14
- package/public/components/Sticky/index.d.ts +0 -1
- package/public/components/Sticky/index.js +0 -5
- package/public/components/TopBar/TopBar.d.ts +0 -14
- package/public/components/TopBar/TopBar.js +0 -24
- package/public/components/TopBar/TopBarBreadcrumbs.d.ts +0 -10
- package/public/components/TopBar/TopBarBreadcrumbs.js +0 -34
- package/public/components/TopBar/TopBarSubNav.d.ts +0 -2
- package/public/components/TopBar/TopBarSubNav.js +0 -16
- package/public/components/TopBar/TopBarSubNavItem.d.ts +0 -5
- package/public/components/TopBar/TopBarSubNavItem.js +0 -17
- package/public/components/TopBar/index.d.ts +0 -1
- package/public/components/TopBar/index.js +0 -13
- package/public/components/VendorLogo/VendorLogo.d.ts +0 -21
- package/public/components/VendorLogo/VendorLogo.js +0 -57
- package/public/components/VendorLogo/index.d.ts +0 -1
- package/public/components/VendorLogo/index.js +0 -13
- package/src/components/Absolute/Absolute.story.mdx +0 -34
- package/src/components/Absolute/Absolute.tsx +0 -12
- package/src/components/Absolute/index.ts +0 -1
- package/src/components/Appbar/Appbar.story.mdx +0 -207
- package/src/components/Appbar/Appbar.tsx +0 -124
- package/src/components/Appbar/AppbarClaimProfileButton.tsx +0 -13
- package/src/components/Appbar/AppbarDropdownIcon.tsx +0 -6
- package/src/components/Appbar/AppbarLogInButton.tsx +0 -27
- package/src/components/Appbar/AppbarLogo.tsx +0 -43
- package/src/components/Appbar/AppbarOrganization.tsx +0 -96
- package/src/components/Appbar/AppbarProductMenu.tsx +0 -125
- package/src/components/Appbar/AppbarTabMarker.tsx +0 -5
- package/src/components/Appbar/AppbarTabs.tsx +0 -46
- package/src/components/Appbar/AppbarUser.tsx +0 -179
- package/src/components/Appbar/config.ts +0 -12
- package/src/components/Appbar/context.ts +0 -20
- package/src/components/Appbar/index.css +0 -294
- package/src/components/Appbar/index.ts +0 -1
- package/src/components/AptibleLogo/AptibleLogo.story.mdx +0 -42
- package/src/components/AptibleLogo/AptibleLogo.tsx +0 -45
- package/src/components/AptibleLogo/index.ts +0 -1
- package/src/components/ArrowButton/ArrowButton.story.mdx +0 -121
- package/src/components/ArrowButton/ArrowButton.tsx +0 -57
- package/src/components/ArrowButton/index.css +0 -42
- package/src/components/ArrowButton/index.ts +0 -1
- package/src/components/ArrowLink/ArrowLink.story.mdx +0 -75
- package/src/components/ArrowLink/ArrowLink.tsx +0 -45
- package/src/components/ArrowLink/index.ts +0 -1
- package/src/components/Aside/Aside.story.mdx +0 -72
- package/src/components/Aside/Aside.tsx +0 -68
- package/src/components/Aside/index.css +0 -11
- package/src/components/Aside/index.ts +0 -1
- package/src/components/Combobox/Combobox.story.mdx +0 -205
- package/src/components/Combobox/Combobox.tsx +0 -165
- package/src/components/Combobox/ComboboxMulti.tsx +0 -169
- package/src/components/Combobox/TODO.md +0 -33
- package/src/components/Combobox/index.css +0 -97
- package/src/components/Combobox/index.ts +0 -2
- package/src/components/Combobox/ui.tsx +0 -211
- package/src/components/Combobox/useSelect.ts +0 -347
- package/src/components/Fixed/Fixed.story.mdx +0 -34
- package/src/components/Fixed/Fixed.tsx +0 -12
- package/src/components/Fixed/index.ts +0 -1
- package/src/components/IntegrationLogo/IntegrationLogo.story.mdx +0 -167
- package/src/components/IntegrationLogo/IntegrationLogo.tsx +0 -59
- package/src/components/IntegrationLogo/IntegrationLogoSvg.tsx +0 -85
- package/src/components/IntegrationLogo/index.ts +0 -1
- package/src/components/IntegrationLogo/svg/addigy.tsx +0 -23
- package/src/components/IntegrationLogo/svg/aws.tsx +0 -52
- package/src/components/IntegrationLogo/svg/bamboohr.tsx +0 -34
- package/src/components/IntegrationLogo/svg/bitbucket.tsx +0 -37
- package/src/components/IntegrationLogo/svg/conveyor.tsx +0 -41
- package/src/components/IntegrationLogo/svg/default.tsx +0 -11
- package/src/components/IntegrationLogo/svg/deploy.tsx +0 -29
- package/src/components/IntegrationLogo/svg/docusign.tsx +0 -102
- package/src/components/IntegrationLogo/svg/events-api.tsx +0 -75
- package/src/components/IntegrationLogo/svg/gcp.tsx +0 -26
- package/src/components/IntegrationLogo/svg/github.tsx +0 -14
- package/src/components/IntegrationLogo/svg/gitlab.tsx +0 -40
- package/src/components/IntegrationLogo/svg/gsuite.tsx +0 -24
- package/src/components/IntegrationLogo/svg/index.ts +0 -23
- package/src/components/IntegrationLogo/svg/jamf.tsx +0 -36
- package/src/components/IntegrationLogo/svg/jira.tsx +0 -44
- package/src/components/IntegrationLogo/svg/jumpcloud.tsx +0 -86
- package/src/components/IntegrationLogo/svg/okta.tsx +0 -28
- package/src/components/IntegrationLogo/svg/onelogin.tsx +0 -34
- package/src/components/IntegrationLogo/svg/salesforce.tsx +0 -39
- package/src/components/IntegrationLogo/svg/servicenow.tsx +0 -18
- package/src/components/IntegrationLogo/svg/slack.tsx +0 -40
- package/src/components/IntegrationLogo/svg/wrapper.tsx +0 -35
- package/src/components/IntegrationLogo/svg/zoom.tsx +0 -51
- package/src/components/Meta/Meta.md +0 -14
- package/src/components/Meta/Meta.story.tsx +0 -24
- package/src/components/Meta/Meta.tsx +0 -29
- package/src/components/Meta/index.ts +0 -1
- package/src/components/Pagination/Pagination.story.mdx +0 -48
- package/src/components/Pagination/Pagination.tsx +0 -81
- package/src/components/Pagination/index.css +0 -41
- package/src/components/Pagination/index.ts +0 -1
- package/src/components/ProductIcon/ProductIcon.story.mdx +0 -50
- package/src/components/ProductIcon/ProductIcon.tsx +0 -48
- package/src/components/ProductIcon/ProductIconComply.tsx +0 -17
- package/src/components/ProductIcon/ProductIconDeploy.tsx +0 -17
- package/src/components/ProductIcon/ProductIconExchange.tsx +0 -17
- package/src/components/ProductIcon/ProductIconTrustCenter.tsx +0 -17
- package/src/components/ProductIcon/index.css +0 -13
- package/src/components/ProductIcon/index.ts +0 -1
- package/src/components/PropertyDiff/PropertDiff.story.mdx +0 -52
- package/src/components/PropertyDiff/PropertyDiff.tsx +0 -51
- package/src/components/PropertyDiff/index.css +0 -33
- package/src/components/PropertyDiff/index.ts +0 -1
- package/src/components/Relative/Relative.story.mdx +0 -34
- package/src/components/Relative/Relative.tsx +0 -12
- package/src/components/Relative/index.ts +0 -1
- package/src/components/SearchFilter/SearchFilter.story.mdx +0 -201
- package/src/components/SearchFilter/SearchFilter.tsx +0 -190
- package/src/components/SearchFilter/index.css +0 -83
- package/src/components/SearchFilter/index.ts +0 -1
- package/src/components/StatusLabel/StatusLabel.story.mdx +0 -325
- package/src/components/StatusLabel/StatusLabel.tsx +0 -121
- package/src/components/StatusLabel/index.css +0 -26
- package/src/components/StatusLabel/index.ts +0 -1
- package/src/components/StatusPanel/StatusPanel.story.mdx +0 -118
- package/src/components/StatusPanel/StatusPanel.tsx +0 -54
- package/src/components/StatusPanel/index.css +0 -52
- package/src/components/StatusPanel/index.ts +0 -1
- package/src/components/Sticky/Sticky.story.mdx +0 -34
- package/src/components/Sticky/Sticky.tsx +0 -12
- package/src/components/Sticky/index.ts +0 -1
- package/src/components/TopBar/TopBar.story.mdx +0 -157
- package/src/components/TopBar/TopBar.tsx +0 -43
- package/src/components/TopBar/TopBarBreadcrumbs.tsx +0 -82
- package/src/components/TopBar/TopBarSubNav.tsx +0 -22
- package/src/components/TopBar/TopBarSubNavItem.tsx +0 -24
- package/src/components/TopBar/index.css +0 -93
- package/src/components/TopBar/index.ts +0 -1
- package/src/components/VendorLogo/VendorLogo.story.mdx +0 -215
- package/src/components/VendorLogo/VendorLogo.tsx +0 -123
- package/src/components/VendorLogo/index.css +0 -46
- package/src/components/VendorLogo/index.ts +0 -1
- package/src/docs/brand-components/BrandButton.story.mdx +0 -106
- package/src/docs/brand-components/BrandCheckbox.story.mdx +0 -66
- package/src/docs/brand-components/BrandFormGroup.story.mdx +0 -79
- package/src/docs/brand-components/BrandRadio.story.mdx +0 -48
- package/src/docs/brand-components/BrandTextArea.story.mdx +0 -44
- package/src/recipes/TopBarNavigation.story.mdx +0 -114
- package/src/templates/Index.story.mdx +0 -177
|
@@ -1,81 +1,110 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
Object.defineProperty(o, k2, { enumerable: true, get: function() { return m[k]; } });
|
|
5
|
-
}) : (function(o, m, k, k2) {
|
|
6
|
-
if (k2 === undefined) k2 = k;
|
|
7
|
-
o[k2] = m[k];
|
|
8
|
-
}));
|
|
9
|
-
var __setModuleDefault = (this && this.__setModuleDefault) || (Object.create ? (function(o, v) {
|
|
10
|
-
Object.defineProperty(o, "default", { enumerable: true, value: v });
|
|
11
|
-
}) : function(o, v) {
|
|
12
|
-
o["default"] = v;
|
|
13
|
-
});
|
|
14
|
-
var __importStar = (this && this.__importStar) || function (mod) {
|
|
15
|
-
if (mod && mod.__esModule) return mod;
|
|
16
|
-
var result = {};
|
|
17
|
-
if (mod != null) for (var k in mod) if (k !== "default" && Object.prototype.hasOwnProperty.call(mod, k)) __createBinding(result, mod, k);
|
|
18
|
-
__setModuleDefault(result, mod);
|
|
19
|
-
return result;
|
|
20
|
-
};
|
|
21
2
|
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
22
3
|
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
23
4
|
};
|
|
24
5
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
25
6
|
exports.Tooltip = void 0;
|
|
26
|
-
const react_1 =
|
|
27
|
-
const
|
|
28
|
-
const
|
|
29
|
-
const hooks_1 = require("../../hooks");
|
|
30
|
-
const Popover_1 = require("../Popover");
|
|
7
|
+
const react_1 = __importDefault(require("react"));
|
|
8
|
+
const Overlay_1 = __importDefault(require("react-overlays/Overlay"));
|
|
9
|
+
const auto_id_1 = require("@reach/auto-id");
|
|
31
10
|
const types_1 = require("../../types");
|
|
32
|
-
const
|
|
33
|
-
const
|
|
34
|
-
const
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
const
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
react_1.useEffect(() => {
|
|
42
|
-
if (isVisibleProp) {
|
|
43
|
-
onOpen();
|
|
11
|
+
const hooks_1 = require("../../hooks");
|
|
12
|
+
const utilities_1 = require("../../utilities");
|
|
13
|
+
const tokens_1 = require("../../style-dictionary/dist/tokens");
|
|
14
|
+
const Box_1 = require("../Box");
|
|
15
|
+
const cn = utilities_1.bemHOF("Tooltip");
|
|
16
|
+
const TooltipArrow = react_1.default.forwardRef(({ placement, style }, forwaredRef) => {
|
|
17
|
+
const generatePositionStyles = () => {
|
|
18
|
+
if (placement.startsWith("top")) {
|
|
19
|
+
return { bottom: `-${tokens_1.tokens.spacing[1]}`, left: 0 };
|
|
44
20
|
}
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
};
|
|
55
|
-
}
|
|
56
|
-
const
|
|
21
|
+
if (placement.startsWith("right")) {
|
|
22
|
+
return { left: `-${tokens_1.tokens.spacing[1]}`, top: 0 };
|
|
23
|
+
}
|
|
24
|
+
if (placement.startsWith("bottom")) {
|
|
25
|
+
return { top: `-${tokens_1.tokens.spacing[1]}`, left: 0 };
|
|
26
|
+
}
|
|
27
|
+
if (placement.startsWith("left")) {
|
|
28
|
+
return { right: `-${tokens_1.tokens.spacing[1]}`, top: 0 };
|
|
29
|
+
}
|
|
30
|
+
return {};
|
|
31
|
+
};
|
|
32
|
+
const positionStyles = generatePositionStyles();
|
|
33
|
+
return (react_1.default.createElement(Box_1.Box, { ref: forwaredRef, className: cn({ e: "arrow" }), style: {
|
|
34
|
+
...style,
|
|
35
|
+
...positionStyles,
|
|
36
|
+
} },
|
|
37
|
+
react_1.default.createElement(Box_1.Box, null)));
|
|
38
|
+
});
|
|
39
|
+
const Tooltip = ({ children, content, placement = "auto", delay = 200, }) => {
|
|
40
|
+
const { isOpen, onOpen, onClose } = hooks_1.useDisclosure();
|
|
41
|
+
const triggerRef = react_1.default.useRef(null);
|
|
42
|
+
const rootRef = react_1.default.useRef(null);
|
|
43
|
+
const id = `ads-tooltip-${auto_id_1.useId()}`;
|
|
44
|
+
const isHoveringTriggerRef = react_1.default.useRef(false);
|
|
45
|
+
const isHoveringPopoverRef = react_1.default.useRef(false);
|
|
46
|
+
const triggerTimoutRef = react_1.default.useRef(null);
|
|
47
|
+
const popoverTimoutRef = react_1.default.useRef(null);
|
|
48
|
+
const onHide = () => {
|
|
57
49
|
if (!isHoveringPopoverRef.current) {
|
|
58
50
|
onClose();
|
|
59
51
|
}
|
|
60
52
|
};
|
|
61
|
-
const
|
|
62
|
-
|
|
53
|
+
const onHideDelay = () => {
|
|
54
|
+
isHoveringTriggerRef.current = false;
|
|
55
|
+
isHoveringPopoverRef.current = false;
|
|
56
|
+
if (isOpen) {
|
|
57
|
+
const popoverTimeout = setTimeout(onHide, delay);
|
|
58
|
+
popoverTimoutRef.current = popoverTimeout;
|
|
59
|
+
}
|
|
60
|
+
};
|
|
61
|
+
const onShow = () => {
|
|
62
|
+
if (!isOpen) {
|
|
63
|
+
onOpen();
|
|
64
|
+
}
|
|
65
|
+
};
|
|
66
|
+
const onShowDelay = () => {
|
|
67
|
+
isHoveringTriggerRef.current = true;
|
|
68
|
+
isHoveringPopoverRef.current = true;
|
|
63
69
|
if (!isOpen) {
|
|
64
70
|
const referenceTimeout = setTimeout(() => {
|
|
65
|
-
if (
|
|
71
|
+
if (isHoveringTriggerRef.current) {
|
|
66
72
|
onOpen();
|
|
67
73
|
}
|
|
68
74
|
}, delay);
|
|
69
|
-
|
|
75
|
+
triggerTimoutRef.current = referenceTimeout;
|
|
70
76
|
}
|
|
71
77
|
};
|
|
72
|
-
|
|
73
|
-
|
|
78
|
+
react_1.default.useEffect(() => {
|
|
79
|
+
return () => {
|
|
80
|
+
if (triggerTimoutRef.current) {
|
|
81
|
+
clearTimeout(triggerTimoutRef.current);
|
|
82
|
+
}
|
|
83
|
+
if (popoverTimoutRef.current) {
|
|
84
|
+
clearTimeout(popoverTimoutRef.current);
|
|
85
|
+
}
|
|
86
|
+
};
|
|
87
|
+
});
|
|
88
|
+
hooks_1.useKeyPress(types_1.KEY_CODE.ESC, () => {
|
|
74
89
|
if (isOpen) {
|
|
75
|
-
|
|
76
|
-
popoverTimoutRef.current = popoverTimeout;
|
|
90
|
+
onHide();
|
|
77
91
|
}
|
|
78
|
-
};
|
|
92
|
+
});
|
|
93
|
+
const triggerProps = ({ onMouseEnter, onMouseLeave, onMouseDown, onFocus, onBlur, onKeyDown, ...rest }) => ({
|
|
94
|
+
ref: triggerRef,
|
|
95
|
+
"aria-describedby": isOpen ? id : undefined,
|
|
96
|
+
onMouseEnter: utilities_1.mergeEventHandlers(onMouseEnter, onShowDelay),
|
|
97
|
+
onMouseLeave: utilities_1.mergeEventHandlers(onMouseLeave, onHideDelay),
|
|
98
|
+
onMouseDown: utilities_1.mergeEventHandlers(onMouseDown, onHideDelay),
|
|
99
|
+
onFocus: utilities_1.mergeEventHandlers(onFocus, onShow),
|
|
100
|
+
onBlur: utilities_1.mergeEventHandlers(onBlur, onHide),
|
|
101
|
+
onKeyDown: utilities_1.mergeEventHandlers(onKeyDown, (event) => {
|
|
102
|
+
if (event.key === "Enter" || event.key === " ") {
|
|
103
|
+
onHide();
|
|
104
|
+
}
|
|
105
|
+
}),
|
|
106
|
+
...rest,
|
|
107
|
+
});
|
|
79
108
|
const handlePopoverMouseEnter = () => {
|
|
80
109
|
if (!isHoveringPopoverRef.current) {
|
|
81
110
|
isHoveringPopoverRef.current = true;
|
|
@@ -84,48 +113,18 @@ const Tooltip = (props) => {
|
|
|
84
113
|
const handlePopoverMouseLeave = () => {
|
|
85
114
|
isHoveringPopoverRef.current = false;
|
|
86
115
|
if (isOpen) {
|
|
87
|
-
const popoverTimeout = setTimeout(
|
|
116
|
+
const popoverTimeout = setTimeout(onHide, delay);
|
|
88
117
|
popoverTimoutRef.current = popoverTimeout;
|
|
89
118
|
}
|
|
90
119
|
};
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
if (typeof referenceElement.props.onMouseEnter === "function") {
|
|
101
|
-
referenceElement.props.onMouseEnter();
|
|
102
|
-
}
|
|
103
|
-
},
|
|
104
|
-
onMouseLeave: () => {
|
|
105
|
-
handleMouseLeave();
|
|
106
|
-
if (typeof referenceElement.props.onMouseLeave === "function") {
|
|
107
|
-
referenceElement.props.onMouseLeave();
|
|
108
|
-
}
|
|
109
|
-
},
|
|
110
|
-
onFocus: () => {
|
|
111
|
-
handleMouseEnter();
|
|
112
|
-
if (typeof referenceElement.props.onFocus === "function") {
|
|
113
|
-
referenceElement.props.onFocus();
|
|
114
|
-
}
|
|
115
|
-
},
|
|
116
|
-
onBlur: () => {
|
|
117
|
-
handleMouseLeave();
|
|
118
|
-
if (typeof referenceElement.props.onBlur === "function") {
|
|
119
|
-
referenceElement.props.onBlur();
|
|
120
|
-
}
|
|
121
|
-
},
|
|
122
|
-
tabIndex: 0,
|
|
123
|
-
})
|
|
124
|
-
: referenceElement;
|
|
125
|
-
const context = react_1.useMemo(() => ({
|
|
126
|
-
isOpen,
|
|
127
|
-
}), [isOpen]);
|
|
128
|
-
return children ? (react_1.default.createElement(context_1.TooltipContext.Provider, { value: context },
|
|
129
|
-
react_1.default.createElement(Popover_1.Popover, Object.assign({ showArrow: true, isVisible: isOpen, referenceElement: referenceElementWithMouseHandlers, placement: placement, className: classnames_1.default(bem_1.bem(cn), className), onMouseEnter: !isVisibleProp ? handlePopoverMouseEnter : undefined, onMouseLeave: !isVisibleProp ? handlePopoverMouseLeave : undefined, style: style }, rest), children))) : (referenceElement);
|
|
120
|
+
return content ? (react_1.default.createElement(Box_1.Box, { ref: rootRef },
|
|
121
|
+
react_1.default.cloneElement(react_1.default.Children.only(children), {
|
|
122
|
+
...triggerProps(children.props),
|
|
123
|
+
}),
|
|
124
|
+
content && (react_1.default.createElement(Overlay_1.default, { rootClose: true, show: isOpen, offset: [0, 8], onHide: onHide, container: rootRef, target: triggerRef, placement: placement, flip: placement && placement.indexOf("auto") !== -1 }, ({ props: contentProps, arrowProps, placement: overlayPlacement, }) => {
|
|
125
|
+
return (react_1.default.createElement(Box_1.Box, Object.assign({ id: id, className: cn(), "data-component": "tooltip", onMouseEnter: handlePopoverMouseEnter, onMouseLeave: handlePopoverMouseLeave }, contentProps),
|
|
126
|
+
react_1.default.createElement(TooltipArrow, { ref: arrowProps.ref, placement: overlayPlacement, style: arrowProps.style }),
|
|
127
|
+
content));
|
|
128
|
+
})))) : (children);
|
|
130
129
|
};
|
|
131
130
|
exports.Tooltip = Tooltip;
|