@doist/reactist 10.0.0 → 11.2.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/dist/reactist.cjs.development.js +3031 -1700
- package/dist/reactist.cjs.development.js.map +1 -1
- package/dist/reactist.cjs.production.min.js +1 -1
- package/dist/reactist.cjs.production.min.js.map +1 -1
- package/es/_virtual/_rollupPluginBabelHelpers.js +34 -20
- package/es/_virtual/_rollupPluginBabelHelpers.js.map +1 -1
- package/es/components/{button/button.js → deprecated-button/deprecated-button.js} +8 -3
- package/es/components/deprecated-button/deprecated-button.js.map +1 -0
- package/es/components/{button → deprecated-button}/index.js +1 -1
- package/es/components/{avatar → deprecated-button}/index.js.map +0 -0
- package/es/components/{loading/loading.js → deprecated-loading/deprecated-loading.js} +3 -1
- package/es/components/deprecated-loading/deprecated-loading.js.map +1 -0
- package/es/components/{modal/modal.js → deprecated-modal/deprecated-modal.js} +14 -6
- package/es/components/deprecated-modal/deprecated-modal.js.map +1 -0
- package/es/components/{modal → deprecated-modal}/index.js +1 -1
- package/es/components/deprecated-modal/index.js.map +1 -0
- package/es/components/dropdown/dropdown.js +5 -3
- package/es/components/dropdown/dropdown.js.map +1 -1
- package/es/components/key-capturer/key-capturer.js +1 -1
- package/es/components/key-capturer/key-capturer.js.map +1 -1
- package/es/components/keyboard-shortcut/keyboard-shortcut.js +3 -2
- package/es/components/keyboard-shortcut/keyboard-shortcut.js.map +1 -1
- package/es/components/menu/menu.js +53 -30
- package/es/components/menu/menu.js.map +1 -1
- package/es/components/notification/notification.js +9 -4
- package/es/components/notification/notification.js.map +1 -1
- package/es/components/popover/popover.js +1 -1
- package/es/components/popover/popover.js.map +1 -1
- package/es/components/popover/positioning-utils.js.map +1 -1
- package/es/components/progress-bar/progress-bar.js +8 -2
- package/es/components/progress-bar/progress-bar.js.map +1 -1
- package/es/components/select/select.js +4 -2
- package/es/components/select/select.js.map +1 -1
- package/es/components/time/time-utils.js.map +1 -1
- package/es/components/time/time.js +1 -1
- package/es/components/time/time.js.map +1 -1
- package/es/components/tooltip/tooltip.js +4 -2
- package/es/components/tooltip/tooltip.js.map +1 -1
- package/es/hooks/use-previous/use-previous.js +26 -0
- package/es/hooks/use-previous/use-previous.js.map +1 -0
- package/es/index.js +32 -13
- package/es/index.js.map +1 -1
- package/es/new-components/alert/alert.js +48 -0
- package/es/new-components/alert/alert.js.map +1 -0
- package/es/new-components/alert/alert.module.css.js +4 -0
- package/es/new-components/alert/alert.module.css.js.map +1 -0
- package/es/{components → new-components}/avatar/avatar.js +14 -8
- package/es/new-components/avatar/avatar.js.map +1 -0
- package/es/new-components/avatar/avatar.module.css.js +4 -0
- package/es/new-components/avatar/avatar.module.css.js.map +1 -0
- package/es/{components → new-components}/avatar/utils.js +0 -0
- package/es/new-components/avatar/utils.js.map +1 -0
- package/es/new-components/base-button/base-button.js +74 -0
- package/es/new-components/base-button/base-button.js.map +1 -0
- package/es/new-components/base-button/base-button.module.css.js +4 -0
- package/es/new-components/base-button/base-button.module.css.js.map +1 -0
- package/es/new-components/base-field/base-field.js +65 -0
- package/es/new-components/base-field/base-field.js.map +1 -0
- package/es/new-components/base-field/base-field.module.css.js +4 -0
- package/es/new-components/base-field/base-field.module.css.js.map +1 -0
- package/es/new-components/box/box.js +74 -0
- package/es/new-components/box/box.js.map +1 -0
- package/es/new-components/box/box.module.css.js +4 -0
- package/es/new-components/box/box.module.css.js.map +1 -0
- package/es/new-components/box/margin.module.css.js +4 -0
- package/es/new-components/box/margin.module.css.js.map +1 -0
- package/es/new-components/box/padding.module.css.js +4 -0
- package/es/new-components/box/padding.module.css.js.map +1 -0
- package/es/new-components/box/width.module.css.js +4 -0
- package/es/new-components/box/width.module.css.js.map +1 -0
- package/es/new-components/button/button.js +41 -0
- package/es/new-components/button/button.js.map +1 -0
- package/es/new-components/button-link/button-link.js +42 -0
- package/es/new-components/button-link/button-link.js.map +1 -0
- package/es/new-components/checkbox-field/checkbox-field.js +88 -0
- package/es/new-components/checkbox-field/checkbox-field.js.map +1 -0
- package/es/new-components/checkbox-field/checkbox-field.module.css.js +4 -0
- package/es/new-components/checkbox-field/checkbox-field.module.css.js.map +1 -0
- package/es/new-components/checkbox-field/checkbox-icon.js +61 -0
- package/es/new-components/checkbox-field/checkbox-icon.js.map +1 -0
- package/es/new-components/columns/columns.js +59 -0
- package/es/new-components/columns/columns.js.map +1 -0
- package/es/new-components/columns/columns.module.css.js +4 -0
- package/es/new-components/columns/columns.module.css.js.map +1 -0
- package/es/new-components/common-helpers.js +24 -0
- package/es/new-components/common-helpers.js.map +1 -0
- package/es/new-components/divider/divider.js +21 -0
- package/es/new-components/divider/divider.js.map +1 -0
- package/es/new-components/divider/divider.module.css.js +4 -0
- package/es/new-components/divider/divider.module.css.js.map +1 -0
- package/es/new-components/heading/heading.js +37 -0
- package/es/new-components/heading/heading.js.map +1 -0
- package/es/new-components/heading/heading.module.css.js +4 -0
- package/es/new-components/heading/heading.module.css.js.map +1 -0
- package/es/new-components/hidden/hidden.js +55 -0
- package/es/new-components/hidden/hidden.js.map +1 -0
- package/es/new-components/hidden/hidden.module.css.js +4 -0
- package/es/new-components/hidden/hidden.module.css.js.map +1 -0
- package/es/new-components/hidden-visually/hidden-visually.js +22 -0
- package/es/new-components/hidden-visually/hidden-visually.js.map +1 -0
- package/es/new-components/hidden-visually/hidden-visually.module.css.js +4 -0
- package/es/new-components/hidden-visually/hidden-visually.module.css.js.map +1 -0
- package/es/new-components/icons/alert-icon.js +77 -0
- package/es/new-components/icons/alert-icon.js.map +1 -0
- package/es/new-components/icons/close-icon.js +15 -0
- package/es/new-components/icons/close-icon.js.map +1 -0
- package/es/new-components/icons/password-hidden-icon.js +29 -0
- package/es/new-components/icons/password-hidden-icon.js.map +1 -0
- package/es/new-components/icons/password-visible-icon.js +22 -0
- package/es/new-components/icons/password-visible-icon.js.map +1 -0
- package/es/new-components/inline/inline.js +36 -0
- package/es/new-components/inline/inline.js.map +1 -0
- package/es/new-components/inline/inline.module.css.js +4 -0
- package/es/new-components/inline/inline.module.css.js.map +1 -0
- package/es/new-components/loading/loading.js +37 -0
- package/es/new-components/loading/loading.js.map +1 -0
- package/es/new-components/modal/modal.js +220 -0
- package/es/new-components/modal/modal.js.map +1 -0
- package/es/new-components/modal/modal.module.css.js +4 -0
- package/es/new-components/modal/modal.module.css.js.map +1 -0
- package/es/new-components/notice/notice.js +30 -0
- package/es/new-components/notice/notice.js.map +1 -0
- package/es/new-components/notice/notice.module.css.js +4 -0
- package/es/new-components/notice/notice.module.css.js.map +1 -0
- package/es/new-components/password-field/password-field.js +76 -0
- package/es/new-components/password-field/password-field.js.map +1 -0
- package/es/new-components/password-field/password-field.module.css.js +4 -0
- package/es/new-components/password-field/password-field.module.css.js.map +1 -0
- package/es/new-components/responsive-props.js +75 -0
- package/es/new-components/responsive-props.js.map +1 -0
- package/es/new-components/select-field/select-field.js +53 -0
- package/es/new-components/select-field/select-field.js.map +1 -0
- package/es/new-components/select-field/select-field.module.css.js +4 -0
- package/es/new-components/select-field/select-field.module.css.js.map +1 -0
- package/es/new-components/spinner/spinner.js +26 -0
- package/es/new-components/spinner/spinner.js.map +1 -0
- package/es/new-components/spinner/spinner.module.css.js +4 -0
- package/es/new-components/spinner/spinner.module.css.js.map +1 -0
- package/es/new-components/stack/stack.js +42 -0
- package/es/new-components/stack/stack.js.map +1 -0
- package/es/new-components/stack/stack.module.css.js +4 -0
- package/es/new-components/stack/stack.module.css.js.map +1 -0
- package/es/new-components/switch-field/switch-field.js +96 -0
- package/es/new-components/switch-field/switch-field.js.map +1 -0
- package/es/new-components/switch-field/switch-field.module.css.js +4 -0
- package/es/new-components/switch-field/switch-field.module.css.js.map +1 -0
- package/es/new-components/tabs/tabs.js +147 -0
- package/es/new-components/tabs/tabs.js.map +1 -0
- package/es/new-components/tabs/tabs.module.css.js +4 -0
- package/es/new-components/tabs/tabs.module.css.js.map +1 -0
- package/es/new-components/text/text.js +36 -0
- package/es/new-components/text/text.js.map +1 -0
- package/es/new-components/text/text.module.css.js +4 -0
- package/es/new-components/text/text.module.css.js.map +1 -0
- package/es/new-components/text-area/text-area.js +34 -0
- package/es/new-components/text-area/text-area.js.map +1 -0
- package/es/new-components/text-area/text-area.module.css.js +4 -0
- package/es/new-components/text-area/text-area.module.css.js.map +1 -0
- package/es/new-components/text-field/text-field.js +41 -0
- package/es/new-components/text-field/text-field.js.map +1 -0
- package/es/new-components/text-field/text-field.module.css.js +4 -0
- package/es/new-components/text-field/text-field.module.css.js.map +1 -0
- package/es/new-components/text-link/text-link.js +27 -0
- package/es/new-components/text-link/text-link.js.map +1 -0
- package/es/new-components/text-link/text-link.module.css.js +4 -0
- package/es/new-components/text-link/text-link.module.css.js.map +1 -0
- package/es/utils/polymorphism.js +17 -0
- package/es/utils/polymorphism.js.map +1 -0
- package/lib/_virtual/_rollupPluginBabelHelpers.js +1 -1
- package/lib/components/{avatar/utils.test.d.ts → checkbox/checkbox.test.d.ts} +0 -0
- package/lib/components/color-picker/color-picker.test.d.ts +1 -0
- package/lib/components/{button/button.d.ts → deprecated-button/deprecated-button.d.ts} +7 -1
- package/lib/components/deprecated-button/deprecated-button.js +2 -0
- package/lib/components/deprecated-button/deprecated-button.js.map +1 -0
- package/lib/components/deprecated-button/deprecated-button.test.d.ts +1 -0
- package/lib/components/deprecated-button/index.d.ts +4 -0
- package/lib/components/{avatar → deprecated-button}/index.js +1 -1
- package/lib/components/{avatar → deprecated-button}/index.js.map +0 -0
- package/lib/components/{loading/loading.d.ts → deprecated-loading/deprecated-loading.d.ts} +2 -1
- package/lib/components/{loading/loading.js → deprecated-loading/deprecated-loading.js} +1 -1
- package/lib/components/deprecated-loading/deprecated-loading.js.map +1 -0
- package/lib/components/deprecated-loading/deprecated-loading.test.d.ts +1 -0
- package/lib/components/deprecated-loading/index.d.ts +1 -0
- package/lib/components/{modal/modal.d.ts → deprecated-modal/deprecated-modal.d.ts} +7 -2
- package/lib/components/deprecated-modal/deprecated-modal.js +2 -0
- package/lib/components/deprecated-modal/deprecated-modal.js.map +1 -0
- package/lib/components/deprecated-modal/deprecated-modal.test.d.ts +1 -0
- package/lib/components/{modal → deprecated-modal}/index.d.ts +2 -2
- package/lib/components/deprecated-modal/index.js +2 -0
- package/lib/components/deprecated-modal/index.js.map +1 -0
- package/lib/components/dropdown/dropdown.js +1 -1
- package/lib/components/dropdown/dropdown.js.map +1 -1
- package/lib/components/dropdown/dropdown.test.d.ts +1 -0
- package/lib/components/input/input.test.d.ts +1 -0
- package/lib/components/key-capturer/key-capturer.js +1 -1
- package/lib/components/key-capturer/key-capturer.test.d.ts +1 -0
- package/lib/components/keyboard-shortcut/keyboard-shortcut.js +1 -1
- package/lib/components/keyboard-shortcut/keyboard-shortcut.js.map +1 -1
- package/lib/components/keyboard-shortcut/keyboard-shortcut.test.d.ts +1 -0
- package/lib/components/menu/menu.d.ts +8 -10
- package/lib/components/menu/menu.js +1 -1
- package/lib/components/menu/menu.js.map +1 -1
- package/lib/components/menu/menu.test.d.ts +1 -0
- package/lib/components/notification/notification.d.ts +4 -2
- package/lib/components/notification/notification.js +1 -1
- package/lib/components/notification/notification.js.map +1 -1
- package/lib/components/notification/notification.test.d.ts +1 -0
- package/lib/components/popover/popover.js +1 -1
- package/lib/components/popover/popover.test.d.ts +1 -0
- package/lib/components/progress-bar/progress-bar.d.ts +3 -1
- package/lib/components/progress-bar/progress-bar.js +1 -1
- package/lib/components/progress-bar/progress-bar.js.map +1 -1
- package/lib/components/progress-bar/progress-bar.test.d.ts +1 -0
- package/lib/components/select/select.js +1 -1
- package/lib/components/select/select.js.map +1 -1
- package/lib/components/select/select.test.d.ts +1 -0
- package/lib/components/time/time.js +1 -1
- package/lib/components/time/time.test.d.ts +1 -0
- package/lib/components/tooltip/tooltip.js +1 -1
- package/lib/components/tooltip/tooltip.js.map +1 -1
- package/lib/components/tooltip/tooltip.test.d.ts +1 -0
- package/lib/hooks/use-previous/index.d.ts +1 -0
- package/lib/hooks/use-previous/use-previous.d.ts +15 -0
- package/lib/hooks/use-previous/use-previous.js +2 -0
- package/lib/hooks/use-previous/use-previous.js.map +1 -0
- package/lib/index.d.ts +33 -13
- package/lib/index.js +1 -1
- package/lib/new-components/alert/alert.d.ts +17 -0
- package/lib/new-components/alert/alert.js +2 -0
- package/lib/new-components/alert/alert.js.map +1 -0
- package/lib/new-components/alert/alert.module.css.js +2 -0
- package/lib/new-components/alert/alert.module.css.js.map +1 -0
- package/lib/new-components/alert/alert.test.d.ts +1 -0
- package/lib/new-components/alert/index.d.ts +1 -0
- package/lib/{components → new-components}/avatar/avatar.d.ts +6 -3
- package/lib/new-components/avatar/avatar.js +2 -0
- package/lib/new-components/avatar/avatar.js.map +1 -0
- package/lib/new-components/avatar/avatar.module.css.js +2 -0
- package/lib/new-components/avatar/avatar.module.css.js.map +1 -0
- package/lib/new-components/avatar/avatar.test.d.ts +1 -0
- package/lib/new-components/avatar/index.d.ts +1 -0
- package/lib/{components → new-components}/avatar/utils.d.ts +0 -0
- package/lib/{components → new-components}/avatar/utils.js +0 -0
- package/lib/new-components/avatar/utils.js.map +1 -0
- package/lib/new-components/avatar/utils.test.d.ts +1 -0
- package/lib/new-components/base-button/base-button.d.ts +69 -0
- package/lib/new-components/base-button/base-button.js +2 -0
- package/lib/new-components/base-button/base-button.js.map +1 -0
- package/lib/new-components/base-button/base-button.module.css.js +2 -0
- package/lib/new-components/base-button/base-button.module.css.js.map +1 -0
- package/lib/new-components/base-button/index.d.ts +1 -0
- package/lib/new-components/base-field/base-field.d.ts +64 -0
- package/lib/new-components/base-field/base-field.js +2 -0
- package/lib/new-components/base-field/base-field.js.map +1 -0
- package/lib/new-components/base-field/base-field.module.css.js +2 -0
- package/lib/new-components/base-field/base-field.module.css.js.map +1 -0
- package/lib/new-components/base-field/index.d.ts +1 -0
- package/lib/new-components/box/box.d.ts +58 -0
- package/lib/new-components/box/box.js +2 -0
- package/lib/new-components/box/box.js.map +1 -0
- package/lib/new-components/box/box.module.css.js +2 -0
- package/lib/new-components/box/box.module.css.js.map +1 -0
- package/lib/new-components/box/box.test.d.ts +1 -0
- package/lib/new-components/box/index.d.ts +1 -0
- package/lib/new-components/box/margin.module.css.js +2 -0
- package/lib/new-components/box/margin.module.css.js.map +1 -0
- package/lib/new-components/box/padding.module.css.js +2 -0
- package/lib/new-components/box/padding.module.css.js.map +1 -0
- package/lib/new-components/box/width.module.css.js +2 -0
- package/lib/new-components/box/width.module.css.js.map +1 -0
- package/lib/new-components/button/button.d.ts +50 -0
- package/lib/new-components/button/button.js +2 -0
- package/lib/new-components/button/button.js.map +1 -0
- package/lib/new-components/button/button.test.d.ts +1 -0
- package/lib/new-components/button/index.d.ts +1 -0
- package/lib/new-components/button-link/button-link-story-wrapper.d.ts +7 -0
- package/lib/new-components/button-link/button-link.d.ts +15 -0
- package/lib/new-components/button-link/button-link.js +2 -0
- package/lib/new-components/button-link/button-link.js.map +1 -0
- package/lib/new-components/button-link/button-link.test.d.ts +1 -0
- package/lib/new-components/button-link/index.d.ts +1 -0
- package/lib/new-components/checkbox-field/checkbox-field.d.ts +21 -0
- package/lib/new-components/checkbox-field/checkbox-field.js +2 -0
- package/lib/new-components/checkbox-field/checkbox-field.js.map +1 -0
- package/lib/new-components/checkbox-field/checkbox-field.module.css.js +2 -0
- package/lib/new-components/checkbox-field/checkbox-field.module.css.js.map +1 -0
- package/lib/new-components/checkbox-field/checkbox-field.test.d.ts +1 -0
- package/lib/new-components/checkbox-field/checkbox-icon.d.ts +8 -0
- package/lib/new-components/checkbox-field/checkbox-icon.js +2 -0
- package/lib/new-components/checkbox-field/checkbox-icon.js.map +1 -0
- package/lib/new-components/checkbox-field/index.d.ts +1 -0
- package/lib/new-components/columns/columns.d.ts +20 -0
- package/lib/new-components/columns/columns.js +2 -0
- package/lib/new-components/columns/columns.js.map +1 -0
- package/lib/new-components/columns/columns.module.css.js +2 -0
- package/lib/new-components/columns/columns.module.css.js.map +1 -0
- package/lib/new-components/columns/columns.test.d.ts +1 -0
- package/lib/new-components/columns/index.d.ts +1 -0
- package/lib/new-components/common-helpers.d.ts +2 -0
- package/lib/new-components/common-helpers.js +2 -0
- package/lib/new-components/common-helpers.js.map +1 -0
- package/lib/new-components/common-types.d.ts +23 -0
- package/lib/new-components/divider/divider.d.ts +8 -0
- package/lib/new-components/divider/divider.js +2 -0
- package/lib/new-components/divider/divider.js.map +1 -0
- package/lib/new-components/divider/divider.module.css.js +2 -0
- package/lib/new-components/divider/divider.module.css.js.map +1 -0
- package/lib/new-components/divider/index.d.ts +1 -0
- package/lib/new-components/heading/heading.d.ts +115 -0
- package/lib/new-components/heading/heading.js +2 -0
- package/lib/new-components/heading/heading.js.map +1 -0
- package/lib/new-components/heading/heading.module.css.js +2 -0
- package/lib/new-components/heading/heading.module.css.js.map +1 -0
- package/lib/new-components/heading/heading.test.d.ts +1 -0
- package/lib/new-components/heading/index.d.ts +1 -0
- package/lib/new-components/hidden/hidden.d.ts +49 -0
- package/lib/new-components/hidden/hidden.js +2 -0
- package/lib/new-components/hidden/hidden.js.map +1 -0
- package/lib/new-components/hidden/hidden.module.css.js +2 -0
- package/lib/new-components/hidden/hidden.module.css.js.map +1 -0
- package/lib/new-components/hidden/hidden.test.d.ts +1 -0
- package/lib/new-components/hidden/index.d.ts +1 -0
- package/lib/new-components/hidden-visually/hidden-visually.d.ts +11 -0
- package/lib/new-components/hidden-visually/hidden-visually.js +2 -0
- package/lib/new-components/hidden-visually/hidden-visually.js.map +1 -0
- package/lib/new-components/hidden-visually/hidden-visually.module.css.js +2 -0
- package/lib/new-components/hidden-visually/hidden-visually.module.css.js.map +1 -0
- package/lib/new-components/hidden-visually/hidden-visually.test.d.ts +1 -0
- package/lib/new-components/hidden-visually/index.d.ts +1 -0
- package/lib/new-components/icons/alert-icon.d.ts +6 -0
- package/lib/new-components/icons/alert-icon.js +2 -0
- package/lib/new-components/icons/alert-icon.js.map +1 -0
- package/lib/new-components/icons/close-icon.d.ts +3 -0
- package/lib/new-components/icons/close-icon.js +2 -0
- package/lib/new-components/icons/close-icon.js.map +1 -0
- package/lib/new-components/icons/password-hidden-icon.d.ts +3 -0
- package/lib/new-components/icons/password-hidden-icon.js +2 -0
- package/lib/new-components/icons/password-hidden-icon.js.map +1 -0
- package/lib/new-components/icons/password-visible-icon.d.ts +3 -0
- package/lib/new-components/icons/password-visible-icon.js +2 -0
- package/lib/new-components/icons/password-visible-icon.js.map +1 -0
- package/lib/new-components/inline/index.d.ts +1 -0
- package/lib/new-components/inline/inline.d.ts +12 -0
- package/lib/new-components/inline/inline.js +2 -0
- package/lib/new-components/inline/inline.js.map +1 -0
- package/lib/new-components/inline/inline.module.css.js +2 -0
- package/lib/new-components/inline/inline.module.css.js.map +1 -0
- package/lib/new-components/inline/inline.test.d.ts +1 -0
- package/lib/new-components/loading/index.d.ts +1 -0
- package/lib/new-components/loading/loading.d.ts +27 -0
- package/lib/new-components/loading/loading.js +2 -0
- package/lib/new-components/loading/loading.js.map +1 -0
- package/lib/new-components/loading/loading.test.d.ts +1 -0
- package/lib/new-components/modal/index.d.ts +1 -0
- package/lib/new-components/modal/modal-stories-components.d.ts +35 -0
- package/lib/new-components/modal/modal.d.ts +156 -0
- package/lib/new-components/modal/modal.js +2 -0
- package/lib/new-components/modal/modal.js.map +1 -0
- package/lib/new-components/modal/modal.module.css.js +2 -0
- package/lib/new-components/modal/modal.module.css.js.map +1 -0
- package/lib/new-components/modal/modal.test.d.ts +1 -0
- package/lib/new-components/notice/index.d.ts +1 -0
- package/lib/new-components/notice/notice.d.ts +10 -0
- package/lib/new-components/notice/notice.js +2 -0
- package/lib/new-components/notice/notice.js.map +1 -0
- package/lib/new-components/notice/notice.module.css.js +2 -0
- package/lib/new-components/notice/notice.module.css.js.map +1 -0
- package/lib/new-components/notice/notice.test.d.ts +1 -0
- package/lib/new-components/password-field/index.d.ts +1 -0
- package/lib/new-components/password-field/password-field.d.ts +8 -0
- package/lib/new-components/password-field/password-field.js +2 -0
- package/lib/new-components/password-field/password-field.js.map +1 -0
- package/lib/new-components/password-field/password-field.module.css.js +2 -0
- package/lib/new-components/password-field/password-field.module.css.js.map +1 -0
- package/lib/new-components/password-field/password-field.test.d.ts +1 -0
- package/lib/new-components/responsive-props.d.ts +44 -0
- package/lib/new-components/responsive-props.js +2 -0
- package/lib/new-components/responsive-props.js.map +1 -0
- package/lib/new-components/select-field/index.d.ts +1 -0
- package/lib/new-components/select-field/select-field.d.ts +6 -0
- package/lib/new-components/select-field/select-field.js +2 -0
- package/lib/new-components/select-field/select-field.js.map +1 -0
- package/lib/new-components/select-field/select-field.module.css.js +2 -0
- package/lib/new-components/select-field/select-field.module.css.js.map +1 -0
- package/lib/new-components/select-field/select-field.test.d.ts +1 -0
- package/lib/new-components/spinner/index.d.ts +1 -0
- package/lib/new-components/spinner/spinner.d.ts +5 -0
- package/lib/new-components/spinner/spinner.js +2 -0
- package/lib/new-components/spinner/spinner.js.map +1 -0
- package/lib/new-components/spinner/spinner.module.css.js +2 -0
- package/lib/new-components/spinner/spinner.module.css.js.map +1 -0
- package/lib/new-components/stack/index.d.ts +1 -0
- package/lib/new-components/stack/stack.d.ts +15 -0
- package/lib/new-components/stack/stack.js +2 -0
- package/lib/new-components/stack/stack.js.map +1 -0
- package/lib/new-components/stack/stack.module.css.js +2 -0
- package/lib/new-components/stack/stack.module.css.js.map +1 -0
- package/lib/new-components/stack/stack.test.d.ts +1 -0
- package/lib/new-components/switch-field/index.d.ts +1 -0
- package/lib/new-components/switch-field/switch-field.d.ts +13 -0
- package/lib/new-components/switch-field/switch-field.js +2 -0
- package/lib/new-components/switch-field/switch-field.js.map +1 -0
- package/lib/new-components/switch-field/switch-field.module.css.js +2 -0
- package/lib/new-components/switch-field/switch-field.module.css.js.map +1 -0
- package/lib/new-components/switch-field/switch-field.test.d.ts +1 -0
- package/lib/new-components/tabs/index.d.ts +1 -0
- package/lib/new-components/tabs/tabs.d.ts +92 -0
- package/lib/new-components/tabs/tabs.js +2 -0
- package/lib/new-components/tabs/tabs.js.map +1 -0
- package/lib/new-components/tabs/tabs.module.css.js +2 -0
- package/lib/new-components/tabs/tabs.module.css.js.map +1 -0
- package/lib/new-components/tabs/tabs.test.d.ts +1 -0
- package/lib/new-components/test-helpers.d.ts +9 -0
- package/lib/new-components/text/index.d.ts +1 -0
- package/lib/new-components/text/text.d.ts +47 -0
- package/lib/new-components/text/text.js +2 -0
- package/lib/new-components/text/text.js.map +1 -0
- package/lib/new-components/text/text.module.css.js +2 -0
- package/lib/new-components/text/text.module.css.js.map +1 -0
- package/lib/new-components/text/text.test.d.ts +1 -0
- package/lib/new-components/text-area/index.d.ts +1 -0
- package/lib/new-components/text-area/text-area.d.ts +8 -0
- package/lib/new-components/text-area/text-area.js +2 -0
- package/lib/new-components/text-area/text-area.js.map +1 -0
- package/lib/new-components/text-area/text-area.module.css.js +2 -0
- package/lib/new-components/text-area/text-area.module.css.js.map +1 -0
- package/lib/new-components/text-field/index.d.ts +1 -0
- package/lib/new-components/text-field/text-field.d.ts +9 -0
- package/lib/new-components/text-field/text-field.js +2 -0
- package/lib/new-components/text-field/text-field.js.map +1 -0
- package/lib/new-components/text-field/text-field.module.css.js +2 -0
- package/lib/new-components/text-field/text-field.module.css.js.map +1 -0
- package/lib/new-components/text-field/text-field.test.d.ts +1 -0
- package/lib/new-components/text-link/index.d.ts +1 -0
- package/lib/new-components/text-link/text-link.d.ts +5 -0
- package/lib/new-components/text-link/text-link.js +2 -0
- package/lib/new-components/text-link/text-link.js.map +1 -0
- package/lib/new-components/text-link/text-link.module.css.js +2 -0
- package/lib/new-components/text-link/text-link.module.css.js.map +1 -0
- package/lib/utils/polymorphism.d.ts +151 -0
- package/lib/utils/polymorphism.js +2 -0
- package/lib/utils/polymorphism.js.map +1 -0
- package/package.json +25 -16
- package/styles/alert.css +9 -0
- package/styles/alert.module.css.css +1 -0
- package/styles/avatar.css +5 -1
- package/styles/avatar.module.css.css +1 -0
- package/styles/base-button.css +7 -0
- package/styles/base-button.module.css.css +1 -0
- package/styles/base-field.css +8 -0
- package/styles/base-field.module.css.css +1 -0
- package/styles/box.css +4 -0
- package/styles/box.module.css.css +1 -0
- package/styles/checkbox-field.css +6 -0
- package/styles/checkbox-field.module.css.css +1 -0
- package/styles/color-picker.css +2 -2
- package/styles/columns.css +5 -0
- package/styles/columns.module.css.css +1 -0
- package/styles/{button.css → deprecated-button.css} +2 -2
- package/styles/deprecated-loading.css +1 -0
- package/styles/deprecated-modal.css +1 -0
- package/styles/divider.css +5 -0
- package/styles/divider.module.css.css +1 -0
- package/styles/dropdown.css +3 -3
- package/styles/heading.css +5 -0
- package/styles/heading.module.css.css +1 -0
- package/styles/hidden-visually.css +5 -0
- package/styles/hidden-visually.module.css.css +1 -0
- package/styles/hidden.css +5 -0
- package/styles/hidden.module.css.css +1 -0
- package/styles/inline.css +5 -0
- package/styles/inline.module.css.css +1 -0
- package/styles/loading.css +5 -1
- package/styles/margin.module.css.css +1 -0
- package/styles/menu.css +1 -1
- package/styles/modal.css +11 -1
- package/styles/modal.module.css.css +1 -0
- package/styles/notice.css +6 -0
- package/styles/notice.module.css.css +1 -0
- package/styles/padding.module.css.css +1 -0
- package/styles/password-field.css +11 -0
- package/styles/password-field.module.css.css +1 -0
- package/styles/progress-bar.css +5 -0
- package/styles/reactist.css +34 -12
- package/styles/select-field.css +9 -0
- package/styles/select-field.module.css.css +1 -0
- package/styles/spinner.module.css.css +1 -0
- package/styles/stack.css +6 -0
- package/styles/stack.module.css.css +1 -0
- package/styles/switch-field.css +10 -0
- package/styles/switch-field.module.css.css +1 -0
- package/styles/tabs.css +6 -1
- package/styles/tabs.module.css.css +1 -0
- package/styles/text-area.css +9 -0
- package/styles/text-area.module.css.css +1 -0
- package/styles/text-field.css +9 -0
- package/styles/text-field.module.css.css +1 -0
- package/styles/text-link.css +5 -0
- package/styles/text-link.module.css.css +1 -0
- package/styles/text.css +5 -0
- package/styles/text.module.css.css +1 -0
- package/styles/time.css +2 -2
- package/styles/width.module.css.css +1 -0
- package/es/components/avatar/avatar.js.map +0 -1
- package/es/components/avatar/index.js +0 -6
- package/es/components/avatar/utils.js.map +0 -1
- package/es/components/button/button.js.map +0 -1
- package/es/components/button/index.js.map +0 -1
- package/es/components/error-message/error-message.js +0 -90
- package/es/components/error-message/error-message.js.map +0 -1
- package/es/components/error-message/index.js +0 -6
- package/es/components/error-message/index.js.map +0 -1
- package/es/components/icon/icon.js +0 -96
- package/es/components/icon/icon.js.map +0 -1
- package/es/components/icon/index.js +0 -6
- package/es/components/icon/index.js.map +0 -1
- package/es/components/icons/ThinQuestionMarkIcon.svg.js +0 -24
- package/es/components/icons/ThinQuestionMarkIcon.svg.js.map +0 -1
- package/es/components/icons/ThreeDotsIcon.svg.js +0 -40
- package/es/components/icons/ThreeDotsIcon.svg.js.map +0 -1
- package/es/components/loading/index.js +0 -6
- package/es/components/loading/index.js.map +0 -1
- package/es/components/loading/loading.js.map +0 -1
- package/es/components/menu/type-helpers.js +0 -9
- package/es/components/menu/type-helpers.js.map +0 -1
- package/es/components/modal/index.js.map +0 -1
- package/es/components/modal/modal.js.map +0 -1
- package/es/components/range-input/index.js +0 -6
- package/es/components/range-input/index.js.map +0 -1
- package/es/components/range-input/range-input.js +0 -55
- package/es/components/range-input/range-input.js.map +0 -1
- package/es/components/tabs/tabs.js +0 -123
- package/es/components/tabs/tabs.js.map +0 -1
- package/es/components/tip/index.js +0 -6
- package/es/components/tip/index.js.map +0 -1
- package/es/components/tip/tip.js +0 -30
- package/es/components/tip/tip.js.map +0 -1
- package/lib/components/avatar/avatar.js +0 -2
- package/lib/components/avatar/avatar.js.map +0 -1
- package/lib/components/avatar/index.d.ts +0 -2
- package/lib/components/avatar/utils.js.map +0 -1
- package/lib/components/button/button.js +0 -2
- package/lib/components/button/button.js.map +0 -1
- package/lib/components/button/index.d.ts +0 -4
- package/lib/components/button/index.js +0 -2
- package/lib/components/button/index.js.map +0 -1
- package/lib/components/error-message/error-message.d.ts +0 -23
- package/lib/components/error-message/error-message.js +0 -2
- package/lib/components/error-message/error-message.js.map +0 -1
- package/lib/components/error-message/index.d.ts +0 -2
- package/lib/components/error-message/index.js +0 -2
- package/lib/components/error-message/index.js.map +0 -1
- package/lib/components/icon/icon.d.ts +0 -31
- package/lib/components/icon/icon.js +0 -2
- package/lib/components/icon/icon.js.map +0 -1
- package/lib/components/icon/index.d.ts +0 -2
- package/lib/components/icon/index.js +0 -2
- package/lib/components/icon/index.js.map +0 -1
- package/lib/components/icons/ThinQuestionMarkIcon.svg.js +0 -2
- package/lib/components/icons/ThinQuestionMarkIcon.svg.js.map +0 -1
- package/lib/components/icons/ThreeDotsIcon.svg.js +0 -2
- package/lib/components/icons/ThreeDotsIcon.svg.js.map +0 -1
- package/lib/components/loading/index.d.ts +0 -2
- package/lib/components/loading/index.js +0 -2
- package/lib/components/loading/index.js.map +0 -1
- package/lib/components/loading/loading.js.map +0 -1
- package/lib/components/menu/type-helpers.d.ts +0 -25
- package/lib/components/menu/type-helpers.js +0 -2
- package/lib/components/menu/type-helpers.js.map +0 -1
- package/lib/components/modal/index.js +0 -2
- package/lib/components/modal/index.js.map +0 -1
- package/lib/components/modal/modal.js +0 -2
- package/lib/components/modal/modal.js.map +0 -1
- package/lib/components/range-input/index.d.ts +0 -2
- package/lib/components/range-input/index.js +0 -2
- package/lib/components/range-input/index.js.map +0 -1
- package/lib/components/range-input/range-input.d.ts +0 -25
- package/lib/components/range-input/range-input.js +0 -2
- package/lib/components/range-input/range-input.js.map +0 -1
- package/lib/components/tabs/index.d.ts +0 -1
- package/lib/components/tabs/tabs.d.ts +0 -33
- package/lib/components/tabs/tabs.js +0 -2
- package/lib/components/tabs/tabs.js.map +0 -1
- package/lib/components/tip/index.d.ts +0 -2
- package/lib/components/tip/index.js +0 -2
- package/lib/components/tip/index.js.map +0 -1
- package/lib/components/tip/tip.d.ts +0 -20
- package/lib/components/tip/tip.js +0 -2
- package/lib/components/tip/tip.js.map +0 -1
- package/styles/error-message.css +0 -1
- package/styles/icon.css +0 -2
- package/styles/range-input.css +0 -1
- package/styles/tip.css +0 -4
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"time.js","sources":["../../../src/components/time/time.tsx"],"sourcesContent":["import React from 'react'\n\nimport { Tooltip } from '../tooltip'\nimport { TimeUtils, TimeConfig } from './time-utils'\n\nimport './time.less'\n\nconst DELAY = 60000\n\ntype Props = {\n /** UNIX timestamp of the time to display. */\n time?: number\n /** Configuration for localization. */\n config?: TimeConfig\n /** Additional css class applied to the time element. */\n className?: string\n tooltipOnHover?: boolean\n /** Refresh the component every DELAY seconds. */\n refresh?: boolean\n /** If you don't want to use the default time format on the tooltip use this prop to supply a custom text */\n tooltip?: React.ReactNode\n /** When hovering over time it expands to short absolute version. */\n expandOnHover?: boolean\n /** When hovering over time it expands to the full absolute version. */\n expandFullyOnHover?: boolean\n}\n\ntype State = {\n hovered: boolean\n mouseX?: number\n mouseY?: number\n}\n\nclass Time extends React.Component<Props, State> {\n public static displayName: string\n public static defaultProps: Props\n\n constructor(props: Props) {\n super(props)\n this.refreshInterval = undefined\n\n this.state = {\n hovered: false,\n mouseX: undefined,\n mouseY: undefined,\n }\n }\n\n componentDidMount() {\n if (this.props.refresh) {\n this._refresh()\n }\n }\n\n componentDidUpdate(prevProps: Props) {\n if (!prevProps.refresh && this.props.refresh) {\n this._refresh()\n }\n\n if (prevProps.refresh && !this.props.refresh) {\n if (this.refreshInterval) {\n clearTimeout(this.refreshInterval)\n }\n }\n }\n\n componentWillUnmount() {\n if (this.refreshInterval) {\n clearTimeout(this.refreshInterval)\n }\n }\n\n refreshInterval?: ReturnType<typeof setTimeout>\n\n _setHovered(hovered: boolean, event: React.MouseEvent) {\n const { mouseX, mouseY } = this.state\n const { clientX, clientY } = event\n if (clientX !== mouseX || clientY !== mouseY) {\n // mouse has moved\n this.setState(() => ({\n hovered,\n mouseX: clientX,\n mouseY: clientY,\n }))\n }\n }\n\n _renderTime(config: Props['config']) {\n if (!this.props.time) {\n return\n }\n if (this.state.hovered) {\n if (this.props.expandFullyOnHover && !this.props.tooltipOnHover) {\n return TimeUtils.formatTimeLong(this.props.time, config)\n }\n if (this.props.expandOnHover && !this.props.tooltipOnHover) {\n return TimeUtils.formatTime(this.props.time, config)\n }\n }\n return TimeUtils.timeAgo(this.props.time, config)\n }\n\n _refresh() {\n this.refreshInterval = setInterval(() => {\n this.forceUpdate()\n }, DELAY)\n }\n\n render() {\n let className = 'reactist_time'\n if (this.props.className) {\n className = this.props.className\n }\n\n const timeComponent = this._renderTime(this.props.config)\n\n return (\n <time\n className={className}\n onMouseEnter={(event) => this._setHovered(true, event)}\n onMouseLeave={(event) => this._setHovered(false, event)}\n >\n {this.props.tooltipOnHover ? (\n <Tooltip\n content={\n this.props.tooltip ||\n (this.props.time &&\n TimeUtils.formatTimeLong(this.props.time, this.props.config))\n }\n >\n <span>{timeComponent}</span>\n </Tooltip>\n ) : (\n timeComponent\n )}\n </time>\n )\n }\n}\nTime.displayName = 'Time'\n\nTime.defaultProps = {\n expandOnHover: false,\n expandFullyOnHover: false,\n tooltipOnHover: false,\n refresh: true,\n config: {\n locale: 'en',\n daysSuffix: 'd',\n hoursSuffix: 'h',\n minutesSuffix: 'm',\n momentsAgo: 'moments ago',\n },\n}\n\nexport { Time }\n"],"names":["DELAY","Time","props","refreshInterval","undefined","state","hovered","mouseX","mouseY","componentDidMount","refresh","_refresh","componentDidUpdate","prevProps","clearTimeout","componentWillUnmount","_setHovered","event","clientX","clientY","setState","_renderTime","config","time","expandFullyOnHover","tooltipOnHover","TimeUtils","formatTimeLong","expandOnHover","formatTime","timeAgo","setInterval","forceUpdate","render","className","timeComponent","React","onMouseEnter","onMouseLeave","Tooltip","content","tooltip","Component","displayName","defaultProps","locale","daysSuffix","hoursSuffix","minutesSuffix","momentsAgo"],"mappings":";;;;;AAOA,IAAMA,KAAK,GAAG,KAAd;;IA0BMC;;;AAIF,gBAAYC,KAAZ;;;AACI,wCAAMA,KAAN;AACA,UAAKC,eAAL,GAAuBC,SAAvB;AAEA,UAAKC,KAAL,GAAa;AACTC,MAAAA,OAAO,EAAE,KADA;AAETC,MAAAA,MAAM,EAAEH,SAFC;AAGTI,MAAAA,MAAM,EAAEJ;AAHC,KAAb;;AAKH;;;;SAEDK,oBAAA;AACI,QAAI,KAAKP,KAAL,CAAWQ,OAAf,EAAwB;AACpB,WAAKC,QAAL;AACH;AACJ;;SAEDC,qBAAA,4BAAmBC,SAAnB;AACI,QAAI,CAACA,SAAS,CAACH,OAAX,IAAsB,KAAKR,KAAL,CAAWQ,OAArC,EAA8C;AAC1C,WAAKC,QAAL;AACH;;AAED,QAAIE,SAAS,CAACH,OAAV,IAAqB,CAAC,KAAKR,KAAL,CAAWQ,OAArC,EAA8C;AAC1C,UAAI,KAAKP,eAAT,EAA0B;AACtBW,QAAAA,YAAY,CAAC,KAAKX,eAAN,CAAZ;AACH;AACJ;AACJ;;SAEDY,uBAAA;AACI,QAAI,KAAKZ,eAAT,EAA0B;AACtBW,MAAAA,YAAY,CAAC,KAAKX,eAAN,CAAZ;AACH;AACJ;;SAIDa,cAAA,qBAAYV,OAAZ,EAA8BW,KAA9B;
|
|
1
|
+
{"version":3,"file":"time.js","sources":["../../../src/components/time/time.tsx"],"sourcesContent":["import React from 'react'\n\nimport { Tooltip } from '../tooltip'\nimport { TimeUtils, TimeConfig } from './time-utils'\n\nimport './time.less'\n\nconst DELAY = 60000\n\ntype Props = {\n /** UNIX timestamp of the time to display. */\n time?: number\n /** Configuration for localization. */\n config?: TimeConfig\n /** Additional css class applied to the time element. */\n className?: string\n tooltipOnHover?: boolean\n /** Refresh the component every DELAY seconds. */\n refresh?: boolean\n /** If you don't want to use the default time format on the tooltip use this prop to supply a custom text */\n tooltip?: React.ReactNode\n /** When hovering over time it expands to short absolute version. */\n expandOnHover?: boolean\n /** When hovering over time it expands to the full absolute version. */\n expandFullyOnHover?: boolean\n}\n\ntype State = {\n hovered: boolean\n mouseX?: number\n mouseY?: number\n}\n\nclass Time extends React.Component<Props, State> {\n public static displayName: string\n public static defaultProps: Props\n\n constructor(props: Props) {\n super(props)\n this.refreshInterval = undefined\n\n this.state = {\n hovered: false,\n mouseX: undefined,\n mouseY: undefined,\n }\n }\n\n componentDidMount() {\n if (this.props.refresh) {\n this._refresh()\n }\n }\n\n componentDidUpdate(prevProps: Props) {\n if (!prevProps.refresh && this.props.refresh) {\n this._refresh()\n }\n\n if (prevProps.refresh && !this.props.refresh) {\n if (this.refreshInterval) {\n clearTimeout(this.refreshInterval)\n }\n }\n }\n\n componentWillUnmount() {\n if (this.refreshInterval) {\n clearTimeout(this.refreshInterval)\n }\n }\n\n refreshInterval?: ReturnType<typeof setTimeout>\n\n _setHovered(hovered: boolean, event: React.MouseEvent) {\n const { mouseX, mouseY } = this.state\n const { clientX, clientY } = event\n if (clientX !== mouseX || clientY !== mouseY) {\n // mouse has moved\n this.setState(() => ({\n hovered,\n mouseX: clientX,\n mouseY: clientY,\n }))\n }\n }\n\n _renderTime(config: Props['config']) {\n if (!this.props.time) {\n return\n }\n if (this.state.hovered) {\n if (this.props.expandFullyOnHover && !this.props.tooltipOnHover) {\n return TimeUtils.formatTimeLong(this.props.time, config)\n }\n if (this.props.expandOnHover && !this.props.tooltipOnHover) {\n return TimeUtils.formatTime(this.props.time, config)\n }\n }\n return TimeUtils.timeAgo(this.props.time, config)\n }\n\n _refresh() {\n this.refreshInterval = setInterval(() => {\n this.forceUpdate()\n }, DELAY)\n }\n\n render() {\n let className = 'reactist_time'\n if (this.props.className) {\n className = this.props.className\n }\n\n const timeComponent = this._renderTime(this.props.config)\n\n return (\n <time\n className={className}\n onMouseEnter={(event) => this._setHovered(true, event)}\n onMouseLeave={(event) => this._setHovered(false, event)}\n >\n {this.props.tooltipOnHover ? (\n <Tooltip\n content={\n this.props.tooltip ||\n (this.props.time &&\n TimeUtils.formatTimeLong(this.props.time, this.props.config))\n }\n >\n <span>{timeComponent}</span>\n </Tooltip>\n ) : (\n timeComponent\n )}\n </time>\n )\n }\n}\nTime.displayName = 'Time'\n\nTime.defaultProps = {\n expandOnHover: false,\n expandFullyOnHover: false,\n tooltipOnHover: false,\n refresh: true,\n config: {\n locale: 'en',\n daysSuffix: 'd',\n hoursSuffix: 'h',\n minutesSuffix: 'm',\n momentsAgo: 'moments ago',\n },\n}\n\nexport { Time }\n"],"names":["DELAY","Time","props","refreshInterval","undefined","state","hovered","mouseX","mouseY","componentDidMount","refresh","_refresh","componentDidUpdate","prevProps","clearTimeout","componentWillUnmount","_setHovered","event","clientX","clientY","setState","_renderTime","config","time","expandFullyOnHover","tooltipOnHover","TimeUtils","formatTimeLong","expandOnHover","formatTime","timeAgo","setInterval","forceUpdate","render","className","timeComponent","React","onMouseEnter","onMouseLeave","Tooltip","content","tooltip","Component","displayName","defaultProps","locale","daysSuffix","hoursSuffix","minutesSuffix","momentsAgo"],"mappings":";;;;;AAOA,IAAMA,KAAK,GAAG,KAAd;;IA0BMC;;;AAIF,gBAAYC,KAAZ;;;AACI,wCAAMA,KAAN;AACA,UAAKC,eAAL,GAAuBC,SAAvB;AAEA,UAAKC,KAAL,GAAa;AACTC,MAAAA,OAAO,EAAE,KADA;AAETC,MAAAA,MAAM,EAAEH,SAFC;AAGTI,MAAAA,MAAM,EAAEJ;AAHC,KAAb;;AAKH;;;;SAEDK,oBAAA;AACI,QAAI,KAAKP,KAAL,CAAWQ,OAAf,EAAwB;AACpB,WAAKC,QAAL;AACH;AACJ;;SAEDC,qBAAA,4BAAmBC,SAAnB;AACI,QAAI,CAACA,SAAS,CAACH,OAAX,IAAsB,KAAKR,KAAL,CAAWQ,OAArC,EAA8C;AAC1C,WAAKC,QAAL;AACH;;AAED,QAAIE,SAAS,CAACH,OAAV,IAAqB,CAAC,KAAKR,KAAL,CAAWQ,OAArC,EAA8C;AAC1C,UAAI,KAAKP,eAAT,EAA0B;AACtBW,QAAAA,YAAY,CAAC,KAAKX,eAAN,CAAZ;AACH;AACJ;AACJ;;SAEDY,uBAAA;AACI,QAAI,KAAKZ,eAAT,EAA0B;AACtBW,MAAAA,YAAY,CAAC,KAAKX,eAAN,CAAZ;AACH;AAC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HT;AAIJC,IAAAA,aAAa,EAAE,GAJX;AAKJC,IAAAA,UAAU,EAAE;AALR;AALQ,CAApB;;;;"}
|
|
@@ -1,8 +1,10 @@
|
|
|
1
|
+
import { objectWithoutPropertiesLoose as _objectWithoutPropertiesLoose, objectSpread2 as _objectSpread2 } from '../../_virtual/_rollupPluginBabelHelpers.js';
|
|
1
2
|
import React__default from 'react';
|
|
2
3
|
import classNames from 'classnames';
|
|
3
|
-
import { objectWithoutPropertiesLoose as _objectWithoutPropertiesLoose, objectSpread2 as _objectSpread2 } from '../../_virtual/_rollupPluginBabelHelpers.js';
|
|
4
4
|
import { TooltipReference, Tooltip as Tooltip$1, useTooltipState } from 'reakit/Tooltip';
|
|
5
5
|
|
|
6
|
+
var _excluded = ["children", "content", "position", "gapSize", "className"];
|
|
7
|
+
|
|
6
8
|
var SHOW_DELAY = 500;
|
|
7
9
|
var HIDE_DELAY = 100;
|
|
8
10
|
|
|
@@ -29,7 +31,7 @@ function Tooltip(_ref) {
|
|
|
29
31
|
_ref$gapSize = _ref.gapSize,
|
|
30
32
|
gapSize = _ref$gapSize === void 0 ? 3 : _ref$gapSize,
|
|
31
33
|
className = _ref.className,
|
|
32
|
-
props = _objectWithoutPropertiesLoose(_ref,
|
|
34
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
33
35
|
|
|
34
36
|
var tooltip = useDelayedTooltipState({
|
|
35
37
|
placement: position,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tooltip.js","sources":["../../../src/components/tooltip/tooltip.tsx"],"sourcesContent":["import React from 'react'\nimport classNames from 'classnames'\n\nimport {\n useTooltipState,\n TooltipInitialState,\n Tooltip as ReakitTooltip,\n TooltipReference,\n TooltipProps as ReakitTooltipProps,\n} from 'reakit/Tooltip'\nimport { PopoverState } from 'reakit/Popover'\n\nimport './tooltip.less'\n\ntype TooltipProps = Omit<ReakitTooltipProps, 'children'> & {\n children: React.ReactNode\n content: React.ReactNode | (() => React.ReactNode)\n position?: PopoverState['placement']\n gapSize?: number\n}\n\n// These are exported to be used in the tests, they are not meant to be exported publicly\nexport const SHOW_DELAY = 500\nexport const HIDE_DELAY = 100\n\nfunction useDelayedTooltipState(initialState: TooltipInitialState) {\n const tooltipState = useTooltipState(initialState)\n const delay = useDelay()\n return React.useMemo(\n () => ({\n ...tooltipState,\n show: delay(() => tooltipState.show(), SHOW_DELAY),\n hide: delay(() => tooltipState.hide(), HIDE_DELAY),\n }),\n [delay, tooltipState],\n )\n}\n\nfunction Tooltip({\n children,\n content,\n position = 'top',\n gapSize = 3,\n className,\n ...props\n}: TooltipProps) {\n const tooltip = useDelayedTooltipState({ placement: position, gutter: gapSize })\n\n const child = React.Children.only<React.ReactElement>(children as React.ReactElement)\n if (!content) {\n return child\n }\n\n /**\n * Prevents the tooltip from automatically firing on focus all the time. This is to prevent\n * tooltips from showing when the trigger element is focused back after a popover or dialog that\n * it opened was closed. See link below for more details.\n * @see https://github.com/reakit/reakit/discussions/749\n */\n function handleFocus(event: React.FocusEvent) {\n // If focus is not followed by a key up event, does it mean that it's not\n // an intentional keyboard focus? Not sure but it seems to work.\n // This may be resolved soon in an upcoming version of reakit:\n // https://github.com/reakit/reakit/issues/750\n function handleKeyUp(e: Event) {\n const eventKey = (e as KeyboardEvent).key\n if (eventKey !== 'Escape' && eventKey !== 'Enter' && eventKey !== 'Space') {\n tooltip.show()\n }\n }\n event.currentTarget.addEventListener('keyup', handleKeyUp, { once: true })\n // Prevent tooltip.show from being called by TooltipReference\n event.preventDefault()\n // eslint-disable-next-line @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access\n if (typeof child.props.onFocus === 'function') child.props.onFocus(event)\n }\n\n return (\n <>\n <TooltipReference\n {...tooltip}\n // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-member-access, @typescript-eslint/no-unsafe-assignment\n ref={(child as any).ref}\n {...child.props}\n onFocus={handleFocus}\n >\n {(referenceProps) => React.cloneElement(child, referenceProps)}\n </TooltipReference>\n {tooltip.visible ? (\n <ReakitTooltip\n {...tooltip}\n {...props}\n className={classNames('reactist_tooltip', className)}\n >\n {typeof content === 'function' ? content() : content}\n </ReakitTooltip>\n ) : null}\n </>\n )\n}\n\nexport type { TooltipProps }\nexport { Tooltip }\n\n//\n// Internal helpers\n//\n\n/**\n * Returns a function offering the same interface as setTimeout, but cleans up on unmount.\n *\n * The timeout state is shared, and only one delayed function can be active at any given time. If\n * a new delayed function is called while another one was waiting for its time to run, that older\n * invocation is cleared and it never runs.\n *\n * This is suitable for our use case here, but probably not the most intuitive thing in general.\n * That's why this is not made a shared util or something like it.\n */\nfunction useDelay() {\n const timeoutRef = React.useRef<ReturnType<typeof setTimeout>>()\n\n const clearTimeouts = React.useCallback(function clearTimeouts() {\n if (timeoutRef.current != null) {\n clearTimeout(timeoutRef.current)\n }\n }, [])\n\n // Runs clearTimeouts when the component is unmounted\n React.useEffect(() => clearTimeouts, [clearTimeouts])\n\n return React.useCallback(\n function delay(fn: () => void, delay: number) {\n return () => {\n clearTimeouts()\n timeoutRef.current = setTimeout(fn, delay)\n }\n },\n [clearTimeouts],\n )\n}\n"],"names":["SHOW_DELAY","HIDE_DELAY","useDelayedTooltipState","initialState","tooltipState","useTooltipState","delay","useDelay","React","useMemo","show","hide","Tooltip","children","content","position","gapSize","className","props","tooltip","placement","gutter","child","Children","only","handleFocus","event","handleKeyUp","e","eventKey","key","currentTarget","addEventListener","once","preventDefault","onFocus","TooltipReference","ref","referenceProps","cloneElement","visible","ReakitTooltip","classNames","timeoutRef","useRef","clearTimeouts","useCallback","current","clearTimeout","useEffect","fn","setTimeout"],"mappings":"
|
|
1
|
+
{"version":3,"file":"tooltip.js","sources":["../../../src/components/tooltip/tooltip.tsx"],"sourcesContent":["import React from 'react'\nimport classNames from 'classnames'\n\nimport {\n useTooltipState,\n TooltipInitialState,\n Tooltip as ReakitTooltip,\n TooltipReference,\n TooltipProps as ReakitTooltipProps,\n} from 'reakit/Tooltip'\nimport { PopoverState } from 'reakit/Popover'\n\nimport './tooltip.less'\n\ntype TooltipProps = Omit<ReakitTooltipProps, 'children'> & {\n children: React.ReactNode\n content: React.ReactNode | (() => React.ReactNode)\n position?: PopoverState['placement']\n gapSize?: number\n}\n\n// These are exported to be used in the tests, they are not meant to be exported publicly\nexport const SHOW_DELAY = 500\nexport const HIDE_DELAY = 100\n\nfunction useDelayedTooltipState(initialState: TooltipInitialState) {\n const tooltipState = useTooltipState(initialState)\n const delay = useDelay()\n return React.useMemo(\n () => ({\n ...tooltipState,\n show: delay(() => tooltipState.show(), SHOW_DELAY),\n hide: delay(() => tooltipState.hide(), HIDE_DELAY),\n }),\n [delay, tooltipState],\n )\n}\n\nfunction Tooltip({\n children,\n content,\n position = 'top',\n gapSize = 3,\n className,\n ...props\n}: TooltipProps) {\n const tooltip = useDelayedTooltipState({ placement: position, gutter: gapSize })\n\n const child = React.Children.only<React.ReactElement>(children as React.ReactElement)\n if (!content) {\n return child\n }\n\n /**\n * Prevents the tooltip from automatically firing on focus all the time. This is to prevent\n * tooltips from showing when the trigger element is focused back after a popover or dialog that\n * it opened was closed. See link below for more details.\n * @see https://github.com/reakit/reakit/discussions/749\n */\n function handleFocus(event: React.FocusEvent) {\n // If focus is not followed by a key up event, does it mean that it's not\n // an intentional keyboard focus? Not sure but it seems to work.\n // This may be resolved soon in an upcoming version of reakit:\n // https://github.com/reakit/reakit/issues/750\n function handleKeyUp(e: Event) {\n const eventKey = (e as KeyboardEvent).key\n if (eventKey !== 'Escape' && eventKey !== 'Enter' && eventKey !== 'Space') {\n tooltip.show()\n }\n }\n event.currentTarget.addEventListener('keyup', handleKeyUp, { once: true })\n // Prevent tooltip.show from being called by TooltipReference\n event.preventDefault()\n // eslint-disable-next-line @typescript-eslint/no-unsafe-call, @typescript-eslint/no-unsafe-member-access\n if (typeof child.props.onFocus === 'function') child.props.onFocus(event)\n }\n\n return (\n <>\n <TooltipReference\n {...tooltip}\n // eslint-disable-next-line @typescript-eslint/no-explicit-any, @typescript-eslint/no-unsafe-member-access, @typescript-eslint/no-unsafe-assignment\n ref={(child as any).ref}\n {...child.props}\n onFocus={handleFocus}\n >\n {(referenceProps) => React.cloneElement(child, referenceProps)}\n </TooltipReference>\n {tooltip.visible ? (\n <ReakitTooltip\n {...tooltip}\n {...props}\n className={classNames('reactist_tooltip', className)}\n >\n {typeof content === 'function' ? content() : content}\n </ReakitTooltip>\n ) : null}\n </>\n )\n}\n\nexport type { TooltipProps }\nexport { Tooltip }\n\n//\n// Internal helpers\n//\n\n/**\n * Returns a function offering the same interface as setTimeout, but cleans up on unmount.\n *\n * The timeout state is shared, and only one delayed function can be active at any given time. If\n * a new delayed function is called while another one was waiting for its time to run, that older\n * invocation is cleared and it never runs.\n *\n * This is suitable for our use case here, but probably not the most intuitive thing in general.\n * That's why this is not made a shared util or something like it.\n */\nfunction useDelay() {\n const timeoutRef = React.useRef<ReturnType<typeof setTimeout>>()\n\n const clearTimeouts = React.useCallback(function clearTimeouts() {\n if (timeoutRef.current != null) {\n clearTimeout(timeoutRef.current)\n }\n }, [])\n\n // Runs clearTimeouts when the component is unmounted\n React.useEffect(() => clearTimeouts, [clearTimeouts])\n\n return React.useCallback(\n function delay(fn: () => void, delay: number) {\n return () => {\n clearTimeouts()\n timeoutRef.current = setTimeout(fn, delay)\n }\n },\n [clearTimeouts],\n )\n}\n"],"names":["SHOW_DELAY","HIDE_DELAY","useDelayedTooltipState","initialState","tooltipState","useTooltipState","delay","useDelay","React","useMemo","show","hide","Tooltip","children","content","position","gapSize","className","props","tooltip","placement","gutter","child","Children","only","handleFocus","event","handleKeyUp","e","eventKey","key","currentTarget","addEventListener","once","preventDefault","onFocus","TooltipReference","ref","referenceProps","cloneElement","visible","ReakitTooltip","classNames","timeoutRef","useRef","clearTimeouts","useCallback","current","clearTimeout","useEffect","fn","setTimeout"],"mappings":";;;;;;;IAsBaA,UAAU,GAAG;IACbC,UAAU,GAAG;;AAE1B,SAASC,sBAAT,CAAg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OAAX,GAAqBI,UAAU,CAACD,EAAD,EAAK5C,KAAL,CAA/B;AACH,KAHD;AAIH,GANE,EAOH,CAACuC,aAAD,CAPG,CAAP;AASH;;;;"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { useRef, useEffect } from 'react';
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* usePrevious tracks the change of the given value -
|
|
5
|
+
* when a given value has been changed from a previous call,
|
|
6
|
+
* it will return the value prior to the change.
|
|
7
|
+
*
|
|
8
|
+
* Example:
|
|
9
|
+
*
|
|
10
|
+
* const [x, setX] = useState(1)
|
|
11
|
+
* const prevX = usePrevious(x)
|
|
12
|
+
*
|
|
13
|
+
* Suppose `setX(2)` is called, then in the next component render
|
|
14
|
+
* x = 2 and prevX = 1
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
function usePrevious(value) {
|
|
18
|
+
var ref = useRef(null);
|
|
19
|
+
useEffect(function () {
|
|
20
|
+
ref.current = value;
|
|
21
|
+
}, [value]);
|
|
22
|
+
return ref.current;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
export { usePrevious };
|
|
26
|
+
//# sourceMappingURL=use-previous.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-previous.js","sources":["../../../src/hooks/use-previous/use-previous.ts"],"sourcesContent":["import * as React from 'react'\n\n/**\n * usePrevious tracks the change of the given value -\n * when a given value has been changed from a previous call,\n * it will return the value prior to the change.\n *\n * Example:\n *\n * const [x, setX] = useState(1)\n * const prevX = usePrevious(x)\n *\n * Suppose `setX(2)` is called, then in the next component render\n * x = 2 and prevX = 1\n */\nfunction usePrevious<T>(value: T): T | null {\n const ref = React.useRef<T | null>(null)\n\n React.useEffect(() => {\n ref.current = value\n }, [value])\n\n return ref.current\n}\n\nexport { usePrevious }\n"],"names":["usePrevious","value","ref","React","current"],"mappings":";;AAEA;;;;;;;;;;;;;;AAaA,SAASA,WAAT,CAAwBC,KAAxB;AACI,MAAMC,GAAG,GAAGC,MAAA,CAAuB,IAAvB,CAAZ;AAEAA,EAAAA,SAAA,CAAgB;AACZD,IAAAA,GAAG,CAACE,OAAJ,GAAcH,KAAd;AACH,GAFD,EAEG,CAACA,KAAD,CAFH;AAIA,SAAOC,GAAG,CAACE,OAAX;AACH;;;;"}
|
package/es/index.js
CHANGED
|
@@ -1,25 +1,44 @@
|
|
|
1
|
-
export {
|
|
1
|
+
export { Box } from './new-components/box/box.js';
|
|
2
|
+
export { Column, Columns } from './new-components/columns/columns.js';
|
|
3
|
+
export { Divider } from './new-components/divider/divider.js';
|
|
4
|
+
export { Inline } from './new-components/inline/inline.js';
|
|
5
|
+
export { Stack } from './new-components/stack/stack.js';
|
|
6
|
+
export { Hidden } from './new-components/hidden/hidden.js';
|
|
7
|
+
export { HiddenVisually } from './new-components/hidden-visually/hidden-visually.js';
|
|
2
8
|
export { Tooltip } from './components/tooltip/tooltip.js';
|
|
3
|
-
export {
|
|
9
|
+
export { Button } from './new-components/button/button.js';
|
|
10
|
+
export { Alert } from './new-components/alert/alert.js';
|
|
11
|
+
export { Loading } from './new-components/loading/loading.js';
|
|
12
|
+
export { Notice } from './new-components/notice/notice.js';
|
|
13
|
+
export { Heading } from './new-components/heading/heading.js';
|
|
14
|
+
export { Text } from './new-components/text/text.js';
|
|
15
|
+
export { ButtonLink } from './new-components/button-link/button-link.js';
|
|
16
|
+
export { TextLink } from './new-components/text-link/text-link.js';
|
|
17
|
+
export { CheckboxField } from './new-components/checkbox-field/checkbox-field.js';
|
|
18
|
+
export { PasswordField } from './new-components/password-field/password-field.js';
|
|
19
|
+
export { SelectField } from './new-components/select-field/select-field.js';
|
|
20
|
+
export { SwitchField } from './new-components/switch-field/switch-field.js';
|
|
21
|
+
export { TextArea } from './new-components/text-area/text-area.js';
|
|
22
|
+
export { TextField } from './new-components/text-field/text-field.js';
|
|
23
|
+
export { usePrevious } from './hooks/use-previous/use-previous.js';
|
|
24
|
+
export { Tab, TabAwareSlot, TabList, TabPanel, Tabs } from './new-components/tabs/tabs.js';
|
|
25
|
+
export { Modal, ModalActions, ModalBody, ModalCloseButton, ModalFooter, ModalHeader } from './new-components/modal/modal.js';
|
|
26
|
+
export { Avatar } from './new-components/avatar/avatar.js';
|
|
4
27
|
export { default as Checkbox } from './components/checkbox/index.js';
|
|
28
|
+
export { default as DeprecatedButton } from './components/deprecated-button/index.js';
|
|
5
29
|
export { default as Dropdown } from './components/dropdown/index.js';
|
|
6
30
|
export { COLORS } from './components/color-picker/color-picker.js';
|
|
7
31
|
export { default as ColorPicker } from './components/color-picker/index.js';
|
|
8
|
-
export { default as ErrorMessage } from './components/error-message/index.js';
|
|
9
|
-
export { default as Icon } from './components/icon/index.js';
|
|
10
32
|
export { default as Input } from './components/input/index.js';
|
|
33
|
+
export { default as KeyboardShortcut } from './components/keyboard-shortcut/index.js';
|
|
11
34
|
export { SUPPORTED_KEYS } from './components/key-capturer/key-capturer.js';
|
|
12
35
|
export { default as KeyCapturer } from './components/key-capturer/index.js';
|
|
13
|
-
export { default as
|
|
14
|
-
export { default as Loading } from './components/loading/index.js';
|
|
15
|
-
export { Menu, MenuButton, MenuGroup, MenuItem, MenuList, SubMenu } from './components/menu/menu.js';
|
|
16
|
-
export { default as Modal } from './components/modal/index.js';
|
|
17
|
-
export { Notification } from './components/notification/notification.js';
|
|
36
|
+
export { default as Popover } from './components/popover/index.js';
|
|
18
37
|
export { default as ProgressBar } from './components/progress-bar/index.js';
|
|
19
|
-
export { default as RangeInput } from './components/range-input/index.js';
|
|
20
38
|
export { default as Select } from './components/select/index.js';
|
|
21
|
-
export { Tab, Tabs } from './components/tabs/tabs.js';
|
|
22
39
|
export { default as Time } from './components/time/index.js';
|
|
23
|
-
export {
|
|
24
|
-
export {
|
|
40
|
+
export { Notification } from './components/notification/notification.js';
|
|
41
|
+
export { Menu, MenuButton, MenuGroup, MenuItem, MenuList, SubMenu } from './components/menu/menu.js';
|
|
42
|
+
export { default as DeprecatedModal } from './components/deprecated-modal/index.js';
|
|
43
|
+
export { Loading as DeprecatedLoading } from './components/deprecated-loading/deprecated-loading.js';
|
|
25
44
|
//# sourceMappingURL=index.js.map
|
package/es/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"index.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { createElement } from 'react';
|
|
2
|
+
import { getClassNames } from '../responsive-props.js';
|
|
3
|
+
import { Box } from '../box/box.js';
|
|
4
|
+
import { Columns, Column } from '../columns/columns.js';
|
|
5
|
+
import { Button } from '../button/button.js';
|
|
6
|
+
import { AlertIcon } from '../icons/alert-icon.js';
|
|
7
|
+
import { CloseIcon } from '../icons/close-icon.js';
|
|
8
|
+
import styles from './alert.module.css.js';
|
|
9
|
+
|
|
10
|
+
function Alert(_ref) {
|
|
11
|
+
var id = _ref.id,
|
|
12
|
+
children = _ref.children,
|
|
13
|
+
tone = _ref.tone,
|
|
14
|
+
closeLabel = _ref.closeLabel,
|
|
15
|
+
onClose = _ref.onClose;
|
|
16
|
+
return /*#__PURE__*/createElement(Box, {
|
|
17
|
+
id: id,
|
|
18
|
+
role: "alert",
|
|
19
|
+
"aria-live": "polite",
|
|
20
|
+
borderRadius: "standard",
|
|
21
|
+
className: [styles.container, getClassNames(styles, 'tone', tone)]
|
|
22
|
+
}, /*#__PURE__*/createElement(Columns, {
|
|
23
|
+
space: "small",
|
|
24
|
+
alignY: "top"
|
|
25
|
+
}, /*#__PURE__*/createElement(Column, {
|
|
26
|
+
width: "content"
|
|
27
|
+
}, /*#__PURE__*/createElement(AlertIcon, {
|
|
28
|
+
tone: tone
|
|
29
|
+
})), /*#__PURE__*/createElement(Column, null, /*#__PURE__*/createElement(Box, {
|
|
30
|
+
paddingY: "xsmall",
|
|
31
|
+
paddingRight: onClose != null && closeLabel != null ? undefined : 'small'
|
|
32
|
+
}, children)), onClose != null && closeLabel != null ? /*#__PURE__*/createElement(Column, {
|
|
33
|
+
width: "content"
|
|
34
|
+
}, /*#__PURE__*/createElement(Button, {
|
|
35
|
+
variant: "quaternary",
|
|
36
|
+
size: "small",
|
|
37
|
+
onClick: onClose,
|
|
38
|
+
"aria-label": closeLabel,
|
|
39
|
+
icon: /*#__PURE__*/createElement(CloseIcon, null),
|
|
40
|
+
style: {
|
|
41
|
+
// @ts-expect-error not sure how to make TypeScript understand custom CSS properties
|
|
42
|
+
'--reactist-btn-hover-fill': 'transparent'
|
|
43
|
+
}
|
|
44
|
+
})) : null));
|
|
45
|
+
}
|
|
46
|
+
|
|
47
|
+
export { Alert };
|
|
48
|
+
//# sourceMappingURL=alert.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"alert.js","sources":["../../../src/new-components/alert/alert.tsx"],"sourcesContent":["import * as React from 'react'\nimport { AlertTone } from '../common-types'\nimport { getClassNames } from '../responsive-props'\nimport { Box } from '../box'\nimport { Button } from '../button'\nimport { Columns, Column } from '../columns'\n\nimport { AlertIcon } from '../icons/alert-icon'\nimport { CloseIcon } from '../icons/close-icon'\n\nimport styles from './alert.module.css'\n\ntype AllOrNone<T> = T | { [K in keyof T]?: never }\n\ntype AlertCloseProps = AllOrNone<{\n closeLabel: string\n onClose: () => void\n}>\n\ntype AlertProps = {\n id?: string\n children: React.ReactNode\n tone: AlertTone\n} & AlertCloseProps\n\nfunction Alert({ id, children, tone, closeLabel, onClose }: AlertProps) {\n return (\n <Box\n id={id}\n role=\"alert\"\n aria-live=\"polite\"\n borderRadius=\"standard\"\n className={[styles.container, getClassNames(styles, 'tone', tone)]}\n >\n <Columns space=\"small\" alignY=\"top\">\n <Column width=\"content\">\n <AlertIcon tone={tone} />\n </Column>\n <Column>\n <Box\n paddingY=\"xsmall\"\n paddingRight={onClose != null && closeLabel != null ? undefined : 'small'}\n >\n {children}\n </Box>\n </Column>\n {onClose != null && closeLabel != null ? (\n <Column width=\"content\">\n <Button\n variant=\"quaternary\"\n size=\"small\"\n onClick={onClose}\n aria-label={closeLabel}\n icon={<CloseIcon />}\n style={{\n // @ts-expect-error not sure how to make TypeScript understand custom CSS properties\n '--reactist-btn-hover-fill': 'transparent',\n }}\n />\n </Column>\n ) : null}\n </Columns>\n </Box>\n )\n}\n\nexport { Alert }\nexport type { AlertProps }\n"],"names":["Alert","id","children","tone","closeLabel","onClose","React","Box","role","borderRadius","className","styles","container","getClassNames","Columns","space","alignY","Column","width","AlertIcon","paddingY","paddingRight","undefined","Button","variant","size","onClick","icon","CloseIcon","style"],"mappings":";;;;;;;;;AAyBA,SAASA,KAAT;MAAiBC,UAAAA;MAAIC,gBAAAA;MAAUC,YAAAA;MAAMC,kBAAAA;MAAYC,eAAAA;AAC7C,sBACIC,aAAA,CAACC,GAAD;AACIN,IAAAA,EAAE,EAAEA;AACJO,IAAAA,IAAI,EAAC;iBACK;AACVC,IAAAA,YAAY,EAAC;AACbC,IAAAA,SAAS,EAAE,CAACC,MAAM,CAACC,SAAR,EAAmBC,aAAa,CAACF,MAAD,EAAS,MAAT,EAAiBR,IAAjB,CAAhC;GALf,eAOIG,aAAA,CAACQ,OAAD;AAASC,IAAAA,KAAK,EAAC;AAAQC,IAAAA,MAAM,EAAC;GAA9B,eACIV,aAAA,CAACW,MAAD;AAAQC,IAAAA,KAAK,EAAC;GAAd,eACIZ,aAAA,CAACa,SAAD;AAAWhB,IAAAA,IAAI,EAAEA;GAAjB,CADJ,CADJ,eAIIG,aAAA,CAACW,MAAD,MAAA,eACIX,aAAA,CAACC,GAAD;AACIa,IAAAA,QAAQ,EAAC;AACTC,IAAAA,YAAY,EAAEhB,OAAO,IAAI,IAAX,IAAmBD,UAAU,IAAI,IAAjC,GAAwCkB,SAAxC,GAAoD;GAFtE,EAIKpB,QAJL,CADJ,CAJJ,EAYKG,OAAO,IAAI,IAAX,IAAmBD,UAAU,IAAI,IAAjC,gBACGE,aAAA,CAACW,MAAD;AAAQC,IAAAA,KAAK,EAAC;GAAd,eACIZ,aAAA,CAACiB,MAAD;AACIC,IAAAA,OAAO,EAAC;AACRC,IAAAA,IAAI,EAAC;AACLC,IAAAA,OAAO,EAAErB;kBACGD;AACZuB,IAAAA,IAAI,eAAErB,aAAA,CAACsB,SAAD,MAAA;AACNC,IAAAA,KAAK,EAAE;AACH;AACA,mCAA6B;AAF1B;GANX,CADJ,CADH,GAcG,IA1BR,CAPJ,CADJ;AAsCH;;;;"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"alert.module.css.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|
|
@@ -1,9 +1,12 @@
|
|
|
1
|
+
import { objectWithoutPropertiesLoose as _objectWithoutPropertiesLoose } from '../../_virtual/_rollupPluginBabelHelpers.js';
|
|
1
2
|
import React__default from 'react';
|
|
2
|
-
import
|
|
3
|
+
import { getClassNames } from '../responsive-props.js';
|
|
4
|
+
import { Box } from '../box/box.js';
|
|
3
5
|
import { getInitials, emailToIndex } from './utils.js';
|
|
6
|
+
import styles from './avatar.module.css.js';
|
|
4
7
|
|
|
8
|
+
var _excluded = ["user", "avatarUrl", "size", "className", "colorList", "exceptionallySetClassName"];
|
|
5
9
|
var AVATAR_COLORS = ['#fcc652', '#e9952c', '#e16b2d', '#d84b40', '#e8435a', '#e5198a', '#ad3889', '#86389c', '#a8a8a8', '#98be2f', '#5d9d50', '#5f9f85', '#5bbcb6', '#32a3bf', '#2bafeb', '#2d88c3', '#3863cc', '#5e5e5e'];
|
|
6
|
-
var AVATAR_SIZES = ['xxs', 'xs', 's', 'm', 'l', 'xl', 'xxl', 'xxxl'];
|
|
7
10
|
|
|
8
11
|
function Avatar(_ref) {
|
|
9
12
|
var user = _ref.user,
|
|
@@ -12,20 +15,23 @@ function Avatar(_ref) {
|
|
|
12
15
|
size = _ref$size === void 0 ? 'l' : _ref$size,
|
|
13
16
|
className = _ref.className,
|
|
14
17
|
_ref$colorList = _ref.colorList,
|
|
15
|
-
colorList = _ref$colorList === void 0 ? AVATAR_COLORS : _ref$colorList
|
|
18
|
+
colorList = _ref$colorList === void 0 ? AVATAR_COLORS : _ref$colorList,
|
|
19
|
+
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
20
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
21
|
+
|
|
16
22
|
var userInitials = getInitials(user.name) || getInitials(user.email);
|
|
17
|
-
var avatarSize = size
|
|
18
|
-
var avatarClass = classNames("reactist_avatar reactist_avatar_size--" + avatarSize, className);
|
|
23
|
+
var avatarSize = size ? size : 'l';
|
|
19
24
|
var style = avatarUrl ? {
|
|
20
25
|
backgroundImage: "url(" + avatarUrl + ")",
|
|
21
26
|
textIndent: '-9999px'
|
|
22
27
|
} : {
|
|
23
28
|
backgroundColor: colorList[emailToIndex(user.email, colorList.length)]
|
|
24
29
|
};
|
|
25
|
-
|
|
26
|
-
|
|
30
|
+
var sizeClassName = getClassNames(styles, 'size', avatarSize);
|
|
31
|
+
return /*#__PURE__*/React__default.createElement(Box, Object.assign({
|
|
32
|
+
className: [className, styles.avatar, sizeClassName, exceptionallySetClassName],
|
|
27
33
|
style: style
|
|
28
|
-
}, userInitials);
|
|
34
|
+
}, props), userInitials);
|
|
29
35
|
}
|
|
30
36
|
|
|
31
37
|
Avatar.displayName = 'Avatar';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"avatar.js","sources":["../../../src/new-components/avatar/avatar.tsx"],"sourcesContent":["import React from 'react'\n\nimport { getInitials, emailToIndex } from './utils'\n\nimport { getClassNames, ResponsiveProp } from '../responsive-props'\nimport styles from './avatar.module.css'\nimport { Box } from '../box'\n\nconst AVATAR_COLORS = [\n '#fcc652',\n '#e9952c',\n '#e16b2d',\n '#d84b40',\n '#e8435a',\n '#e5198a',\n '#ad3889',\n '#86389c',\n '#a8a8a8',\n '#98be2f',\n '#5d9d50',\n '#5f9f85',\n '#5bbcb6',\n '#32a3bf',\n '#2bafeb',\n '#2d88c3',\n '#3863cc',\n '#5e5e5e',\n]\n\ntype AvatarSize = 'xxs' | 'xs' | 's' | 'm' | 'l' | 'xl' | 'xxl' | 'xxxl'\n\ntype Props = {\n /** @deprecated Please use `exceptionallySetClassName` */\n className?: string\n exceptionallySetClassName?: string\n /** @deprecated */\n colorList?: string[]\n size?: ResponsiveProp<AvatarSize>\n avatarUrl?: string\n user: { name?: string; email: string }\n}\n\nfunction Avatar({\n user,\n avatarUrl,\n size = 'l',\n className,\n colorList = AVATAR_COLORS,\n exceptionallySetClassName,\n ...props\n}: Props) {\n const userInitials = getInitials(user.name) || getInitials(user.email)\n const avatarSize = size ? size : 'l'\n\n const style = avatarUrl\n ? {\n backgroundImage: `url(${avatarUrl})`,\n textIndent: '-9999px', // hide the initials\n }\n : {\n backgroundColor: colorList[emailToIndex(user.email, colorList.length)],\n }\n\n const sizeClassName = getClassNames(styles, 'size', avatarSize)\n\n return (\n <Box\n className={[className, styles.avatar, sizeClassName, exceptionallySetClassName]}\n style={style}\n {...props}\n >\n {userInitials}\n </Box>\n )\n}\nAvatar.displayName = 'Avatar'\n\nexport { Avatar }\n"],"names":["AVATAR_COLORS","Avatar","user","avatarUrl","size","className","colorList","exceptionallySetClassName","props","userInitials","getInitials","name","email","avatarSize","style","backgroundImage","textIndent","backgroundColor","emailToIndex","length","sizeClassName","getClassNames","styles","React","Box","avatar","displayName"],"mappings":";;;;;;;;AAQA,IAAMA,aAAa,GAAG,CAClB,SADkB,EAElB,SAFkB,EAGlB,SAHkB,EAIlB,SAJkB,EAKlB,SALkB,EAMlB,SANkB,EAOlB,SAPkB,EAQlB,SARkB,EASlB,SATkB,EAUlB,SAVkB,EAWlB,SAXkB,EAYlB,SAZkB,EAalB,SAbkB,EAclB,SAdkB,EAelB,SAfkB,EAgBlB,SAhBkB,EAiBlB,SAjBkB,EAkBlB,SAlBkB,CAAtB;;AAkCA,SAASC,MAAT;MACIC,YAAAA;MACAC,iBAAAA;uBACAC;MAAAA,8BAAO;MACPC,iBAAAA;4BACAC;MAAAA,wCAAYN;MACZO,iCAAAA;MACGC;;AAEH,MAAMC,YAAY,GAAGC,WAAW,CAACR,IAAI,CAACS,IAAN,CAAX,IAA0BD,WAAW,CAACR,IAAI,CAACU,KAAN,CAA1D;AACA,MAAMC,UAAU,GAAGT,IAAI,GAAGA,IAAH,GAAU,GAAjC;AAEA,MAAMU,KAAK,GAAGX,SAAS,GACjB;AACIY,IAAAA,eAAe,WAASZ,SAAT,MADnB;AAEIa,IAAAA,UAAU,EAAE;AAFhB,GADiB,GAKjB;AACIC,IAAAA,eAAe,EAAEX,SAAS,CAACY,YAAY,CAAChB,IAAI,CAACU,KAAN,EAAaN,SAAS,CAACa,MAAvB,CAAb;AAD9B,GALN;AASA,MAAMC,aAAa,GAAGC,aAAa,CAACC,MAAD,EAAS,MAAT,EAAiBT,UAAjB,CAAnC;AAEA,sBACIU,4BAAA,CAACC,GAAD;AACInB,IAAAA,SAAS,EAAE,CAACA,SAAD,EAAYiB,MAAM,CAACG,MAAnB,EAA2BL,aAA3B,EAA0Cb,yBAA1C;AACXO,IAAAA,KAAK,EAAEA;KACHN,MAHR,EAKKC,YALL,CADJ;AASH;;AACDR,MAAM,CAACyB,WAAP,GAAqB,QAArB;;;;"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
var modules_08f3eeac = {"avatar":"_38a1be89","size-xxs":"d32e92ae","size-xs":"_0667d719","size-s":"cf529fcf","size-m":"_6e268eab","size-l":"d64c62cf","size-xl":"_44fb77de","size-xxl":"_01f85e0e","size-xxxl":"_41a5fe19","tablet-size-xxs":"_6ab1577d","tablet-size-xs":"b52a4963","tablet-size-s":"_714a8419","tablet-size-m":"_81cd4d51","tablet-size-l":"bf0a4edb","tablet-size-xl":"e4f0dabd","tablet-size-xxl":"_67ea065d","tablet-size-xxxl":"_2af7f76f","desktop-size-xxs":"_759081dc","desktop-size-xs":"_8290d1c1","desktop-size-s":"_48ea172d","desktop-size-m":"_758f6641","desktop-size-l":"f9ada088","desktop-size-xl":"d3bb7470","desktop-size-xxl":"_9a312ee3","desktop-size-xxxl":"a1d30c23"};
|
|
2
|
+
|
|
3
|
+
export default modules_08f3eeac;
|
|
4
|
+
//# sourceMappingURL=avatar.module.css.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"avatar.module.css.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|
|
File without changes
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"utils.js","sources":["../../../src/new-components/avatar/utils.ts"],"sourcesContent":["function getInitials(name?: string) {\n if (!name) {\n return ''\n }\n\n const seed = name.trim().split(' ')\n const firstInitial = seed[0]\n const lastInitial = seed[seed.length - 1]\n\n let initials = firstInitial[0]\n // Better readable this way.\n // eslint-disable-next-line @typescript-eslint/prefer-string-starts-ends-with\n if (firstInitial[0] !== lastInitial[0]) {\n initials += lastInitial[0]\n }\n return initials.toUpperCase()\n}\n\nfunction emailToIndex(email: string, maxIndex: number) {\n const seed = email.split('@')[0]\n const hash = seed.charCodeAt(0) + seed.charCodeAt(seed.length - 1) || 0\n return hash % maxIndex\n}\n\nexport { getInitials, emailToIndex }\n"],"names":["getInitials","name","seed","trim","split","firstInitial","lastInitial","length","initials","toUpperCase","emailToIndex","email","maxIndex","hash","charCodeAt"],"mappings":"AAAA,SAASA,WAAT,CAAqBC,IAArB;AACI,MAAI,CAACA,IAAL,EAAW;AACP,WAAO,EAAP;AACH;;AAED,MAAMC,IAAI,GAAGD,IAAI,CAACE,IAAL,GAAYC,KAAZ,CAAkB,GAAlB,CAAb;AACA,MAAMC,YAAY,GAAGH,IAAI,CAAC,CAAD,CAAzB;AACA,MAAMI,WAAW,GAAGJ,IAAI,CAACA,IAAI,CAACK,MAAL,GAAc,CAAf,CAAxB;AAEA,MAAIC,QAAQ,GAAGH,YAAY,CAAC,CAAD,CAA3B;AAEA;;AACA,MAAIA,YAAY,CAAC,CAAD,CAAZ,KAAoBC,WAAW,CAAC,CAAD,CAAnC,EAAwC;AACpCE,IAAAA,QAAQ,IAAIF,WAAW,CAAC,CAAD,CAAvB;AACH;;AACD,SAAOE,QAAQ,CAACC,WAAT,EAAP;AACH;;AAED,SAASC,YAAT,CAAsBC,KAAtB,EAAqCC,QAArC;AACI,MAAMV,IAAI,GAAGS,KAAK,CAACP,KAAN,CAAY,GAAZ,EAAiB,CAAjB,CAAb;AACA,MAAMS,IAAI,GAAGX,IAAI,CAACY,UAAL,CAAgB,CAAhB,IAAqBZ,IAAI,CAACY,UAAL,CAAgBZ,IAAI,CAACK,MAAL,GAAc,CAA9B,CAArB,IAAyD,CAAtE;AACA,SAAOM,IAAI,GAAGD,QAAd;AACH;;;;"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import { objectWithoutPropertiesLoose as _objectWithoutPropertiesLoose } from '../../_virtual/_rollupPluginBabelHelpers.js';
|
|
2
|
+
import { createElement, Fragment } from 'react';
|
|
3
|
+
import { polymorphicComponent } from '../../utils/polymorphism.js';
|
|
4
|
+
import { Box } from '../box/box.js';
|
|
5
|
+
import { Tooltip } from '../../components/tooltip/tooltip.js';
|
|
6
|
+
import { Spinner } from '../spinner/spinner.js';
|
|
7
|
+
import styles from './base-button.module.css.js';
|
|
8
|
+
|
|
9
|
+
var _excluded = ["as", "variant", "tone", "size", "disabled", "loading", "tooltip", "tooltipGapSize", "onClick", "exceptionallySetClassName", "children", "startIcon", "endIcon", "icon"];
|
|
10
|
+
|
|
11
|
+
function preventDefault(event) {
|
|
12
|
+
event.preventDefault();
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* The component that powers `Button` and `ButtonLink`, where the button styling logic and some
|
|
16
|
+
* common functionality resides. This component is internal to Reactist.
|
|
17
|
+
*
|
|
18
|
+
* 🎨 [Figma](https://www.figma.com/file/LYlWNzvhMDh907l07mPPQk/Product-Web?node-id=4693%3A175143)
|
|
19
|
+
*
|
|
20
|
+
* @see Button
|
|
21
|
+
* @see ButtonLink
|
|
22
|
+
*/
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
var BaseButton = /*#__PURE__*/polymorphicComponent(function BaseButton(_ref, ref) {
|
|
26
|
+
var _ref$as = _ref.as,
|
|
27
|
+
as = _ref$as === void 0 ? 'div' : _ref$as,
|
|
28
|
+
variant = _ref.variant,
|
|
29
|
+
_ref$tone = _ref.tone,
|
|
30
|
+
tone = _ref$tone === void 0 ? 'normal' : _ref$tone,
|
|
31
|
+
_ref$size = _ref.size,
|
|
32
|
+
size = _ref$size === void 0 ? 'normal' : _ref$size,
|
|
33
|
+
_ref$disabled = _ref.disabled,
|
|
34
|
+
disabled = _ref$disabled === void 0 ? false : _ref$disabled,
|
|
35
|
+
_ref$loading = _ref.loading,
|
|
36
|
+
loading = _ref$loading === void 0 ? false : _ref$loading,
|
|
37
|
+
tooltip = _ref.tooltip,
|
|
38
|
+
tooltipGapSize = _ref.tooltipGapSize,
|
|
39
|
+
onClick = _ref.onClick,
|
|
40
|
+
exceptionallySetClassName = _ref.exceptionallySetClassName,
|
|
41
|
+
children = _ref.children,
|
|
42
|
+
startIcon = _ref.startIcon,
|
|
43
|
+
endIcon = _ref.endIcon,
|
|
44
|
+
icon = _ref.icon,
|
|
45
|
+
props = _objectWithoutPropertiesLoose(_ref, _excluded);
|
|
46
|
+
|
|
47
|
+
var isDisabled = loading || disabled;
|
|
48
|
+
var buttonElement = /*#__PURE__*/createElement(Box, Object.assign({}, props, {
|
|
49
|
+
as: as,
|
|
50
|
+
ref: ref,
|
|
51
|
+
"aria-disabled": isDisabled,
|
|
52
|
+
onClick: isDisabled ? preventDefault : onClick,
|
|
53
|
+
className: [exceptionallySetClassName, styles.baseButton, styles["variant-" + variant], styles["tone-" + tone], styles["size-" + size], icon ? styles.iconButton : null, disabled ? styles.disabled : null]
|
|
54
|
+
}), icon ? loading && /*#__PURE__*/createElement(Spinner, null) || icon : /*#__PURE__*/createElement(Fragment, null, startIcon ? /*#__PURE__*/createElement(Box, {
|
|
55
|
+
display: "flex",
|
|
56
|
+
className: styles.startIcon,
|
|
57
|
+
"aria-hidden": true
|
|
58
|
+
}, loading && !endIcon ? /*#__PURE__*/createElement(Spinner, null) : startIcon) : null, children ? /*#__PURE__*/createElement("span", {
|
|
59
|
+
className: styles.label
|
|
60
|
+
}, children) : null, endIcon || loading && !startIcon ? /*#__PURE__*/createElement(Box, {
|
|
61
|
+
display: "flex",
|
|
62
|
+
className: styles.endIcon,
|
|
63
|
+
"aria-hidden": true
|
|
64
|
+
}, loading ? /*#__PURE__*/createElement(Spinner, null) : endIcon) : null)); // If it's an icon-only button, make sure it uses the aria-label as tooltip if no tooltip was provided
|
|
65
|
+
|
|
66
|
+
var tooltipContent = icon ? tooltip !== null && tooltip !== void 0 ? tooltip : props['aria-label'] : tooltip;
|
|
67
|
+
return tooltipContent ? /*#__PURE__*/createElement(Tooltip, {
|
|
68
|
+
content: tooltipContent,
|
|
69
|
+
gapSize: tooltipGapSize
|
|
70
|
+
}, buttonElement) : buttonElement;
|
|
71
|
+
});
|
|
72
|
+
|
|
73
|
+
export { BaseButton };
|
|
74
|
+
//# sourceMappingURL=base-button.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"base-button.js","sources":["../../../src/new-components/base-button/base-button.tsx"],"sourcesContent":["import * as React from 'react'\nimport { Tooltip, TooltipProps } from '../../components/tooltip'\nimport { polymorphicComponent } from '../../utils/polymorphism'\nimport { Box } from '../box'\nimport { Spinner } from '../spinner'\nimport styles from './base-button.module.css'\n\nfunction preventDefault(event: React.SyntheticEvent) {\n event.preventDefault()\n}\n\ntype ButtonVariant = 'primary' | 'secondary' | 'tertiary' | 'quaternary'\ntype ButtonTone = 'normal' | 'destructive'\ntype ButtonSize = 'small' | 'normal' | 'large'\ntype IconElement = React.ReactChild\n\ntype CommonProps = {\n /**\n * The button's variant.\n */\n variant: ButtonVariant\n /**\n * The button's tone.\n * @default 'normal'\n */\n tone?: ButtonTone\n /**\n * The button's size.\n * @default 'normal'\n */\n size?: ButtonSize\n /**\n * Whether the button is disabled or not.\n * @default false\n */\n disabled?: boolean\n /**\n * Whether the button is busy/loading.\n *\n * A button in this state is functionally and semantically disabled. Visually is does not look\n * dimmed (as disabled buttons normally do), but it shows a loading spinner instead.\n *\n * @default false\n */\n loading?: boolean\n /**\n * A tooltip linked to the button element.\n */\n tooltip?: TooltipProps['content']\n /**\n * The distance between the button element and the linked tooltip.\n */\n tooltipGapSize?: TooltipProps['gapSize']\n}\n\ntype IconButtonProps = {\n icon: IconElement\n 'aria-label': string\n children?: never\n startIcon?: never\n endIcon?: never\n}\n\ntype LabelledButtonProps = {\n children: NonNullable<React.ReactNode>\n startIcon?: IconElement\n endIcon?: IconElement\n icon?: never\n}\n\nexport type BaseButtonProps = CommonProps & (IconButtonProps | LabelledButtonProps)\n\n/**\n * The component that powers `Button` and `ButtonLink`, where the button styling logic and some\n * common functionality resides. This component is internal to Reactist.\n *\n * 🎨 [Figma](https://www.figma.com/file/LYlWNzvhMDh907l07mPPQk/Product-Web?node-id=4693%3A175143)\n *\n * @see Button\n * @see ButtonLink\n */\nexport const BaseButton = polymorphicComponent<'div', BaseButtonProps>(function BaseButton(\n {\n as = 'div',\n variant,\n tone = 'normal',\n size = 'normal',\n disabled = false,\n loading = false,\n tooltip,\n tooltipGapSize,\n onClick,\n exceptionallySetClassName,\n children,\n startIcon,\n endIcon,\n icon,\n ...props\n },\n ref,\n) {\n const isDisabled = loading || disabled\n const buttonElement = (\n <Box\n {...props}\n as={as}\n ref={ref}\n aria-disabled={isDisabled}\n onClick={isDisabled ? preventDefault : onClick}\n className={[\n exceptionallySetClassName,\n styles.baseButton,\n styles[`variant-${variant}`],\n styles[`tone-${tone}`],\n styles[`size-${size}`],\n icon ? styles.iconButton : null,\n disabled ? styles.disabled : null,\n ]}\n >\n {icon ? (\n (loading && <Spinner />) || icon\n ) : (\n <>\n {startIcon ? (\n <Box display=\"flex\" className={styles.startIcon} aria-hidden>\n {loading && !endIcon ? <Spinner /> : startIcon}\n </Box>\n ) : null}\n {children ? <span className={styles.label}>{children}</span> : null}\n {endIcon || (loading && !startIcon) ? (\n <Box display=\"flex\" className={styles.endIcon} aria-hidden>\n {loading ? <Spinner /> : endIcon}\n </Box>\n ) : null}\n </>\n )}\n </Box>\n )\n\n // If it's an icon-only button, make sure it uses the aria-label as tooltip if no tooltip was provided\n const tooltipContent = icon ? tooltip ?? props['aria-label'] : tooltip\n return tooltipContent ? (\n <Tooltip content={tooltipContent} gapSize={tooltipGapSize}>\n {buttonElement}\n </Tooltip>\n ) : (\n buttonElement\n )\n})\n"],"names":["preventDefault","event","BaseButton","polymorphicComponent","ref","as","variant","tone","size","disabled","loading","tooltip","tooltipGapSize","onClick","exceptionallySetClassName","children","startIcon","endIcon","icon","props","isDisabled","buttonElement","React","Box","className","styles","baseButton","iconButton","Spinner","display","label","tooltipContent","Tooltip","content","gapSize"],"mappings":";;;;;;;;;;AAOA,SAASA,cAAT,CAAwBC,KAAxB;AACIA,EAAAA,KAAK,CAACD,cAAN;AACH;AA+DD;;;;;;;;;;;IASaE,UAAU,gBAAGC,oBAAoB,CAAyB,SAASD,UAAT,OAkBnEE,GAlBmE;qBAE/DC;MAAAA,0BAAK;MACLC,eAAAA;uBACAC;MAAAA,8BAAO;uBACPC;MAAAA,8BAAO;2BACPC;MAAAA,sCAAW;0BACXC;MAAAA,oCAAU;MACVC,eAAAA;MACAC,sBAAAA;MACAC,eAAAA;MACAC,iCAAAA;MACAC,gBAAAA;MACAC,iBAAAA;MACAC,eAAAA;MACAC,YAAAA;MACGC;;AAIP,MAAMC,UAAU,GAAGV,OAAO,IAAID,QAA9B;AACA,MAAMY,aAAa,gBACfC,aAAA,CAACC,GAAD,oBACQJ;AACJd,IAAAA,EAAE,EAAEA;AACJD,IAAAA,GAAG,EAAEA;qBACUgB;AACfP,IAAAA,OAAO,EAAEO,UAAU,GAAGpB,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,aALJ;AAOH,CAnE6C;;;;"}
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
var modules_b9569bce = {"label":"_1f20c88a","baseButton":"_623015f3","size-small":"_062de645","size-normal":"_55e2a6a9","size-large":"cab32a7c","disabled":"e71c191a","iconButton":"_368efc16","startIcon":"d35389c1","endIcon":"_900d41d8","variant-primary":"_7c95e162","variant-secondary":"_9cb889aa","variant-tertiary":"_611b5b28","variant-quaternary":"_80c2bb84","tone-destructive":"ee13c455"};
|
|
2
|
+
|
|
3
|
+
export default modules_b9569bce;
|
|
4
|
+
//# sourceMappingURL=base-button.module.css.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"base-button.module.css.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;"}
|
|
@@ -0,0 +1,65 @@
|
|
|
1
|
+
import { createElement } from 'react';
|
|
2
|
+
import { Box } from '../box/box.js';
|
|
3
|
+
import { Stack } from '../stack/stack.js';
|
|
4
|
+
import { Text } from '../text/text.js';
|
|
5
|
+
import { useId } from '../common-helpers.js';
|
|
6
|
+
import styles from './base-field.module.css.js';
|
|
7
|
+
|
|
8
|
+
function FieldHint(props) {
|
|
9
|
+
return /*#__PURE__*/createElement(Text, Object.assign({
|
|
10
|
+
as: "p",
|
|
11
|
+
tone: "secondary",
|
|
12
|
+
size: "copy"
|
|
13
|
+
}, props));
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
function BaseField(_ref) {
|
|
17
|
+
var label = _ref.label,
|
|
18
|
+
secondaryLabel = _ref.secondaryLabel,
|
|
19
|
+
auxiliaryLabel = _ref.auxiliaryLabel,
|
|
20
|
+
hint = _ref.hint,
|
|
21
|
+
className = _ref.className,
|
|
22
|
+
children = _ref.children,
|
|
23
|
+
maxWidth = _ref.maxWidth,
|
|
24
|
+
hidden = _ref.hidden,
|
|
25
|
+
originalAriaDescribedBy = _ref['aria-describedby'],
|
|
26
|
+
originalId = _ref.id;
|
|
27
|
+
var id = useId(originalId);
|
|
28
|
+
var hintId = useId();
|
|
29
|
+
var ariaDescribedBy = originalAriaDescribedBy !== null && originalAriaDescribedBy !== void 0 ? originalAriaDescribedBy : hint ? hintId : undefined;
|
|
30
|
+
return /*#__PURE__*/createElement(Stack, {
|
|
31
|
+
space: "small"
|
|
32
|
+
}, /*#__PURE__*/createElement(Box, {
|
|
33
|
+
className: [className, styles.container],
|
|
34
|
+
maxWidth: maxWidth,
|
|
35
|
+
hidden: hidden
|
|
36
|
+
}, /*#__PURE__*/createElement(Box, {
|
|
37
|
+
as: "span",
|
|
38
|
+
display: "flex",
|
|
39
|
+
justifyContent: "spaceBetween",
|
|
40
|
+
alignItems: "flexEnd",
|
|
41
|
+
paddingBottom: "small"
|
|
42
|
+
}, /*#__PURE__*/createElement(Text, {
|
|
43
|
+
size: "body",
|
|
44
|
+
as: "label",
|
|
45
|
+
htmlFor: id
|
|
46
|
+
}, label ? /*#__PURE__*/createElement("span", {
|
|
47
|
+
className: styles.primaryLabel
|
|
48
|
+
}, label) : null, secondaryLabel ? /*#__PURE__*/createElement("span", {
|
|
49
|
+
className: styles.secondaryLabel
|
|
50
|
+
}, "\xA0(", secondaryLabel, ")") : null), auxiliaryLabel ? /*#__PURE__*/createElement(Box, {
|
|
51
|
+
className: styles.auxiliaryLabel,
|
|
52
|
+
paddingLeft: "small"
|
|
53
|
+
}, auxiliaryLabel) : null), children(ariaDescribedBy ? {
|
|
54
|
+
id: id,
|
|
55
|
+
'aria-describedby': ariaDescribedBy
|
|
56
|
+
} : {
|
|
57
|
+
id: id
|
|
58
|
+
})), hint ? /*#__PURE__*/createElement(FieldHint, {
|
|
59
|
+
hidden: hidden,
|
|
60
|
+
id: hintId
|
|
61
|
+
}, hint) : null);
|
|
62
|
+
}
|
|
63
|
+
|
|
64
|
+
export { BaseField, FieldHint };
|
|
65
|
+
//# sourceMappingURL=base-field.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"base-field.js","sources":["../../../src/new-components/base-field/base-field.tsx"],"sourcesContent":["import * as React from 'react'\nimport { Box, BoxProps } from '../box'\nimport { useId } from '../common-helpers'\nimport { Text } from '../text'\nimport { WithEnhancedClassName } from '../common-types'\nimport styles from './base-field.module.css'\nimport { Stack } from '../stack'\n\ntype FieldHintProps = {\n id: string\n children: React.ReactNode\n hidden?: boolean\n}\n\nfunction FieldHint(props: FieldHintProps) {\n return <Text as=\"p\" tone=\"secondary\" size=\"copy\" {...props} />\n}\n\n//\n// BaseField\n//\n\ntype HtmlInputProps<T extends HTMLElement> = React.DetailedHTMLProps<\n React.InputHTMLAttributes<T>,\n T\n>\n\ntype BaseFieldProps = WithEnhancedClassName &\n Pick<HtmlInputProps<HTMLInputElement>, 'id' | 'hidden' | 'aria-describedby'> & {\n /**\n * The main label for this field element.\n *\n * Avoid providing interactive elements in the label. Prefer `auxiliaryLabel` for that.\n *\n * @see secondaryLabel\n * @see auxiliaryLabel\n */\n label: React.ReactNode\n /**\n * An optional secondary label for this field element. It is combined with the `label` to\n * form the field's entire accessible name (unless the field label is overriden by using\n * `aria-label` or `aria-labelledby`).\n *\n * Avoid providing interactive elements in the label. Prefer `auxiliaryLabel` for that.\n *\n * @see label\n * @see auxiliaryLabel\n */\n secondaryLabel?: React.ReactNode\n /**\n * An optional extra element to be placed to the right of the main and secondary labels.\n *\n * This extra element is not included in the accessible name of the field element. Its only\n * purpose is either visual, or functional (if you include interactive elements in it).\n *\n * @see label\n * @see secondaryLabel\n */\n auxiliaryLabel?: React.ReactNode\n /**\n * A hint or help-like content associated as the accessible description of the field. It is\n * generally rendered below it, and with a visual style that reduces its prominence (i.e.\n * as secondary text).\n */\n hint?: React.ReactNode\n /**\n * The maximum width that the input field can expand to.\n */\n maxWidth?: BoxProps['maxWidth']\n /**\n * Used internally by components composed using `BaseField`. It is not exposed as part of\n * the public props of such components.\n */\n children: (props: { id: string; 'aria-describedby'?: string }) => React.ReactNode\n }\n\ntype FieldComponentProps<T extends HTMLElement> = Omit<BaseFieldProps, 'children' | 'className'> &\n Omit<HtmlInputProps<T>, 'className' | 'style'>\n\nfunction BaseField({\n label,\n secondaryLabel,\n auxiliaryLabel,\n hint,\n className,\n children,\n maxWidth,\n hidden,\n 'aria-describedby': originalAriaDescribedBy,\n id: originalId,\n}: BaseFieldProps & WithEnhancedClassName) {\n const id = useId(originalId)\n const hintId = useId()\n\n const ariaDescribedBy = originalAriaDescribedBy ?? (hint ? hintId : undefined)\n\n return (\n <Stack space=\"small\">\n <Box className={[className, styles.container]} maxWidth={maxWidth} hidden={hidden}>\n <Box\n as=\"span\"\n display=\"flex\"\n justifyContent=\"spaceBetween\"\n alignItems=\"flexEnd\"\n paddingBottom=\"small\"\n >\n <Text size=\"body\" as=\"label\" htmlFor={id}>\n {label ? <span className={styles.primaryLabel}>{label}</span> : null}\n {secondaryLabel ? (\n <span className={styles.secondaryLabel}> ({secondaryLabel})</span>\n ) : null}\n </Text>\n {auxiliaryLabel ? (\n <Box className={styles.auxiliaryLabel} paddingLeft=\"small\">\n {auxiliaryLabel}\n </Box>\n ) : null}\n </Box>\n {children(ariaDescribedBy ? { id, 'aria-describedby': ariaDescribedBy } : { id })}\n </Box>\n {hint ? (\n <FieldHint hidden={hidden} id={hintId}>\n {hint}\n </FieldHint>\n ) : null}\n </Stack>\n )\n}\n\nexport { BaseField, FieldHint }\nexport type { FieldComponentProps }\n"],"names":["FieldHint","props","React","Text","as","tone","size","BaseField","label","secondaryLabel","auxiliaryLabel","hint","className","children","maxWidth","hidden","originalAriaDescribedBy","originalId","id","useId","hintId","ariaDescribedBy","undefined","Stack","space","Box","styles","container","display","justifyContent","alignItems","paddingBottom","htmlFor","primaryLabel","paddingLeft"],"mappings":";;;;;;;AAcA,SAASA,SAAT,CAAmBC,KAAnB;AACI,sBAAOC,aAAA,CAACC,IAAD;AAAMC,IAAAA,EAAE,EAAC;AAAIC,IAAAA,IAAI,EAAC;AAAYC,IAAAA,IAAI,EAAC;KAAWL,MAA9C,CAAP;AACH;;AA+DD,SA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