@uxf/ui 11.74.0 → 11.74.2
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/_file-input-base/file-input-base.d.ts +13 -0
- package/_file-input-base/file-input-base.js +50 -0
- package/_file-input-base/index.d.ts +2 -0
- package/_file-input-base/index.js +5 -0
- package/_input-with-popover/index.d.ts +2 -0
- package/_input-with-popover/index.js +5 -0
- package/_input-with-popover/input-with-popover.d.ts +25 -0
- package/_input-with-popover/input-with-popover.js +93 -0
- package/_private-utils/get-provider-config.d.ts +2 -0
- package/_private-utils/get-provider-config.js +19 -0
- package/accordion/accordion.d.ts +33 -0
- package/accordion/accordion.js +78 -0
- package/accordion/accordion.spec.d.ts +1 -0
- package/accordion/accordion.spec.js +9 -0
- package/accordion/accordion.stories.d.ts +2 -0
- package/accordion/accordion.stories.js +20 -0
- package/accordion/index.d.ts +2 -0
- package/accordion/index.js +5 -0
- package/alert-bubble/alert-bubble.d.ts +10 -0
- package/alert-bubble/alert-bubble.js +22 -0
- package/alert-bubble/alert-bubble.spec.d.ts +1 -0
- package/alert-bubble/alert-bubble.spec.js +9 -0
- package/alert-bubble/alert-bubble.stories.d.ts +2 -0
- package/alert-bubble/alert-bubble.stories.js +43 -0
- package/alert-bubble/index.d.ts +3 -0
- package/alert-bubble/index.js +5 -0
- package/alert-bubble/theme.d.ts +16 -0
- package/alert-bubble/theme.js +2 -0
- package/announcement-bar/announcement-bar.d.ts +9 -0
- package/announcement-bar/announcement-bar.js +40 -0
- package/announcement-bar/announcement-bar.spec.d.ts +1 -0
- package/announcement-bar/announcement-bar.spec.js +9 -0
- package/announcement-bar/announcement-bar.stories.d.ts +2 -0
- package/announcement-bar/announcement-bar.stories.js +36 -0
- package/announcement-bar/index.d.ts +2 -0
- package/announcement-bar/index.js +5 -0
- package/announcement-bar/theme.d.ts +9 -0
- package/announcement-bar/theme.js +2 -0
- package/avatar/avatar.d.ts +6 -0
- package/avatar/avatar.js +35 -0
- package/avatar/avatar.spec.d.ts +1 -0
- package/avatar/avatar.spec.js +9 -0
- package/avatar/avatar.stories.d.ts +2 -0
- package/avatar/avatar.stories.js +13 -0
- package/avatar/index.d.ts +2 -0
- package/avatar/index.js +5 -0
- package/avatar-file-input/avatar-file-input.d.ts +18 -0
- package/avatar-file-input/avatar-file-input.js +71 -0
- package/avatar-file-input/avatar-file-input.spec.d.ts +1 -0
- package/avatar-file-input/avatar-file-input.spec.js +9 -0
- package/avatar-file-input/avatar-file-input.stories.d.ts +2 -0
- package/avatar-file-input/avatar-file-input.stories.js +48 -0
- package/avatar-file-input/index.d.ts +2 -0
- package/avatar-file-input/index.js +5 -0
- package/avatar-file-input/theme.d.ts +5 -0
- package/avatar-file-input/theme.js +2 -0
- package/badge/badge.d.ts +7 -0
- package/badge/badge.js +35 -0
- package/badge/badge.spec.d.ts +1 -0
- package/badge/badge.spec.js +9 -0
- package/badge/badge.stories.d.ts +2 -0
- package/badge/badge.stories.js +32 -0
- package/badge/index.d.ts +3 -0
- package/badge/index.js +5 -0
- package/badge/theme.d.ts +6 -0
- package/badge/theme.js +2 -0
- package/button/button.d.ts +17 -0
- package/button/button.js +50 -0
- package/button/button.spec.d.ts +1 -0
- package/button/button.spec.js +9 -0
- package/button/button.stories.d.ts +4 -0
- package/button/button.stories.js +94 -0
- package/button/index.d.ts +3 -0
- package/button/index.js +5 -0
- package/button/theme.d.ts +22 -0
- package/button/theme.js +2 -0
- package/button-group/button-group.d.ts +6 -0
- package/button-group/button-group.js +13 -0
- package/button-group/button-group.spec.d.ts +1 -0
- package/button-group/button-group.spec.js +9 -0
- package/button-group/button-group.stories.d.ts +2 -0
- package/button-group/button-group.stories.js +34 -0
- package/button-group/index.d.ts +2 -0
- package/button-group/index.js +5 -0
- package/button-list/button-list.d.ts +25 -0
- package/button-list/button-list.js +85 -0
- package/button-list/button-list.spec.d.ts +1 -0
- package/button-list/button-list.spec.js +9 -0
- package/button-list/button-list.stories.d.ts +2 -0
- package/button-list/button-list.stories.js +58 -0
- package/button-list/index.d.ts +2 -0
- package/button-list/index.js +5 -0
- package/calendar/calendar-day-cell.d.ts +10 -0
- package/calendar/calendar-day-cell.js +65 -0
- package/calendar/calendar-navigation.d.ts +9 -0
- package/calendar/calendar-navigation.js +26 -0
- package/calendar/calendar-provider.d.ts +6 -0
- package/calendar/calendar-provider.js +26 -0
- package/calendar/calendar.d.ts +12 -0
- package/calendar/calendar.js +51 -0
- package/calendar/calendar.stories.d.ts +2 -0
- package/calendar/calendar.stories.js +35 -0
- package/calendar/index.d.ts +4 -0
- package/calendar/index.js +7 -0
- package/calendar/utils/get-class-names-from-flags.d.ts +2 -0
- package/calendar/utils/get-class-names-from-flags.js +7 -0
- package/checkbox/checkbox.d.ts +12 -0
- package/checkbox/checkbox.js +54 -0
- package/checkbox/checkbox.spec.d.ts +1 -0
- package/checkbox/checkbox.spec.js +9 -0
- package/checkbox/checkbox.stories.d.ts +2 -0
- package/checkbox/checkbox.stories.js +40 -0
- package/checkbox/index.d.ts +3 -0
- package/checkbox/index.js +5 -0
- package/checkbox/theme.d.ts +5 -0
- package/checkbox/theme.js +2 -0
- package/checkbox-button/checkbox-button.d.ts +9 -0
- package/checkbox-button/checkbox-button.js +39 -0
- package/checkbox-button/checkbox-button.spec.d.ts +1 -0
- package/checkbox-button/checkbox-button.spec.js +9 -0
- package/checkbox-button/checkbox-button.stories.d.ts +2 -0
- package/checkbox-button/checkbox-button.stories.js +38 -0
- package/checkbox-button/index.d.ts +2 -0
- package/checkbox-button/index.js +5 -0
- package/checkbox-input/checkbox-input.d.ts +14 -0
- package/checkbox-input/checkbox-input.js +43 -0
- package/checkbox-input/checkbox-input.spec.d.ts +1 -0
- package/checkbox-input/checkbox-input.spec.js +9 -0
- package/checkbox-input/checkbox-input.stories.d.ts +2 -0
- package/checkbox-input/checkbox-input.stories.js +40 -0
- package/checkbox-input/index.d.ts +2 -0
- package/checkbox-input/index.js +5 -0
- package/checkbox-list/checkbox-list.d.ts +6 -0
- package/checkbox-list/checkbox-list.js +52 -0
- package/checkbox-list/checkbox-list.spec.d.ts +1 -0
- package/checkbox-list/checkbox-list.spec.js +9 -0
- package/checkbox-list/checkbox-list.stories.d.ts +2 -0
- package/checkbox-list/checkbox-list.stories.js +40 -0
- package/checkbox-list/index.d.ts +2 -0
- package/checkbox-list/index.js +5 -0
- package/checkbox-list/types.d.ts +16 -0
- package/checkbox-list/types.js +2 -0
- package/chip/chip.d.ts +13 -0
- package/chip/chip.js +60 -0
- package/chip/chip.spec.d.ts +1 -0
- package/chip/chip.spec.js +9 -0
- package/chip/chip.stories.d.ts +2 -0
- package/chip/chip.stories.js +47 -0
- package/chip/index.d.ts +3 -0
- package/chip/index.js +5 -0
- package/chip/theme.d.ts +25 -0
- package/chip/theme.js +2 -0
- package/chip/translations.d.ts +11 -0
- package/chip/translations.js +12 -0
- package/color-radio/color-radio.d.ts +12 -0
- package/color-radio/color-radio.js +66 -0
- package/color-radio/color-radio.spec.d.ts +1 -0
- package/color-radio/color-radio.spec.js +9 -0
- package/color-radio/color-radio.stories.d.ts +2 -0
- package/color-radio/color-radio.stories.js +25 -0
- package/color-radio/index.d.ts +2 -0
- package/color-radio/index.js +5 -0
- package/color-radio-group/color-radio-group.d.ts +18 -0
- package/color-radio-group/color-radio-group.js +49 -0
- package/color-radio-group/color-radio-group.spec.d.ts +1 -0
- package/color-radio-group/color-radio-group.spec.js +9 -0
- package/color-radio-group/color-radio-group.stories.d.ts +2 -0
- package/color-radio-group/color-radio-group.stories.js +75 -0
- package/color-radio-group/index.d.ts +2 -0
- package/color-radio-group/index.js +5 -0
- package/color-scheme/color-scheme-defaults.d.ts +8 -0
- package/color-scheme/color-scheme-defaults.js +10 -0
- package/color-scheme/get-color-scheme-class-name.d.ts +2 -0
- package/color-scheme/get-color-scheme-class-name.js +13 -0
- package/color-scheme/get-color-scheme.d.ts +2 -0
- package/color-scheme/get-color-scheme.js +16 -0
- package/color-scheme/index.d.ts +5 -0
- package/color-scheme/index.js +13 -0
- package/color-scheme/use-color-scheme.d.ts +2 -0
- package/color-scheme/use-color-scheme.js +15 -0
- package/color-scheme/use-handle-color-scheme.d.ts +9 -0
- package/color-scheme/use-handle-color-scheme.js +23 -0
- package/color-scheme/use-toggle-color-scheme.d.ts +1 -0
- package/color-scheme/use-toggle-color-scheme.js +29 -0
- package/combobox/combobox.d.ts +51 -0
- package/combobox/combobox.js +108 -0
- package/combobox/combobox.spec.d.ts +1 -0
- package/combobox/combobox.spec.js +10 -0
- package/combobox/combobox.stories.d.ts +3 -0
- package/combobox/combobox.stories.js +55 -0
- package/combobox/index.d.ts +2 -0
- package/combobox/index.js +5 -0
- package/combobox/translations.d.ts +17 -0
- package/combobox/translations.js +18 -0
- package/components.d.ts +317 -0
- package/components.js +344 -0
- package/config/icons-config.d.ts +2 -0
- package/config/icons-config.js +5 -0
- package/config/icons.d.ts +127 -0
- package/config/icons.js +30 -0
- package/content/content-schema.d.ts +3 -0
- package/content/content-schema.js +2 -0
- package/content/types.d.ts +27 -0
- package/content/types.js +2 -0
- package/context/context.d.ts +17 -0
- package/context/context.js +5 -0
- package/context/index.d.ts +3 -0
- package/context/index.js +19 -0
- package/context/provider.d.ts +8 -0
- package/context/provider.js +20 -0
- package/context/use-component-context.d.ts +3 -0
- package/context/use-component-context.js +13 -0
- package/create-component-preview-page/create-component-preview-page.d.ts +13 -0
- package/create-component-preview-page/create-component-preview-page.js +43 -0
- package/create-component-preview-page/index.d.ts +2 -0
- package/create-component-preview-page/index.js +18 -0
- package/date-picker/date-picker-content.d.ts +10 -0
- package/date-picker/date-picker-content.js +58 -0
- package/date-picker/date-picker-decade.d.ts +9 -0
- package/date-picker/date-picker-decade.js +91 -0
- package/date-picker/date-picker-month.d.ts +10 -0
- package/date-picker/date-picker-month.js +87 -0
- package/date-picker/date-picker-year.d.ts +9 -0
- package/date-picker/date-picker-year.js +96 -0
- package/date-picker/date-picker.d.ts +20 -0
- package/date-picker/date-picker.js +31 -0
- package/date-picker/date-picker.spec.d.ts +1 -0
- package/date-picker/date-picker.spec.js +9 -0
- package/date-picker/date-picker.stories.d.ts +2 -0
- package/date-picker/date-picker.stories.js +80 -0
- package/date-picker/index.d.ts +3 -0
- package/date-picker/index.js +5 -0
- package/date-picker/translations.d.ts +53 -0
- package/date-picker/translations.js +54 -0
- package/date-picker/types.d.ts +11 -0
- package/date-picker/types.js +2 -0
- package/date-picker-input/date-picker-input.d.ts +23 -0
- package/date-picker-input/date-picker-input.js +88 -0
- package/date-picker-input/date-picker-input.spec.d.ts +1 -0
- package/date-picker-input/date-picker-input.spec.js +9 -0
- package/date-picker-input/date-picker-input.stories.d.ts +2 -0
- package/date-picker-input/date-picker-input.stories.js +55 -0
- package/date-picker-input/index.d.ts +2 -0
- package/date-picker-input/index.js +8 -0
- package/date-range-picker/date-range-picker-content.d.ts +6 -0
- package/date-range-picker/date-range-picker-content.js +56 -0
- package/date-range-picker/date-range-picker-decade.d.ts +9 -0
- package/date-range-picker/date-range-picker-decade.js +95 -0
- package/date-range-picker/date-range-picker-month.d.ts +10 -0
- package/date-range-picker/date-range-picker-month.js +84 -0
- package/date-range-picker/date-range-picker-year.d.ts +9 -0
- package/date-range-picker/date-range-picker-year.js +93 -0
- package/date-range-picker/date-range-picker.d.ts +15 -0
- package/date-range-picker/date-range-picker.js +53 -0
- package/date-range-picker/date-range-picker.spec.d.ts +1 -0
- package/date-range-picker/date-range-picker.spec.js +9 -0
- package/date-range-picker/date-range-picker.stories.d.ts +2 -0
- package/date-range-picker/date-range-picker.stories.js +36 -0
- package/date-range-picker/index.d.ts +3 -0
- package/date-range-picker/index.js +5 -0
- package/date-range-picker/translations.d.ts +53 -0
- package/date-range-picker/translations.js +54 -0
- package/date-range-picker/types.d.ts +5 -0
- package/date-range-picker/types.js +2 -0
- package/date-range-picker-input/date-range-picker-input.d.ts +21 -0
- package/date-range-picker-input/date-range-picker-input.js +62 -0
- package/date-range-picker-input/date-range-picker-input.spec.d.ts +1 -0
- package/date-range-picker-input/date-range-picker-input.spec.js +9 -0
- package/date-range-picker-input/date-range-picker-input.stories.d.ts +2 -0
- package/date-range-picker-input/date-range-picker-input.stories.js +44 -0
- package/date-range-picker-input/index.d.ts +2 -0
- package/date-range-picker-input/index.js +5 -0
- package/datetime-picker/datetime-picker.d.ts +17 -0
- package/datetime-picker/datetime-picker.js +98 -0
- package/datetime-picker/datetime-picker.spec.d.ts +1 -0
- package/datetime-picker/datetime-picker.spec.js +9 -0
- package/datetime-picker/datetime-picker.stories.d.ts +2 -0
- package/datetime-picker/datetime-picker.stories.js +37 -0
- package/datetime-picker/index.d.ts +2 -0
- package/datetime-picker/index.js +7 -0
- package/datetime-picker/translations.d.ts +17 -0
- package/datetime-picker/translations.js +18 -0
- package/datetime-picker-input/datetime-picker-input.d.ts +21 -0
- package/datetime-picker-input/datetime-picker-input.js +85 -0
- package/datetime-picker-input/datetime-picker-input.spec.d.ts +1 -0
- package/datetime-picker-input/datetime-picker-input.spec.js +9 -0
- package/datetime-picker-input/datetime-picker-input.stories.d.ts +2 -0
- package/datetime-picker-input/datetime-picker-input.stories.js +45 -0
- package/datetime-picker-input/get-datetime-string.d.ts +6 -0
- package/datetime-picker-input/get-datetime-string.js +18 -0
- package/datetime-picker-input/index.d.ts +2 -0
- package/datetime-picker-input/index.js +7 -0
- package/dialog/dialog-panel.d.ts +12 -0
- package/dialog/dialog-panel.js +13 -0
- package/dialog/dialog.d.ts +28 -0
- package/dialog/dialog.js +75 -0
- package/dialog/dialog.spec.d.ts +1 -0
- package/dialog/dialog.spec.js +9 -0
- package/dialog/dialog.stories.d.ts +2 -0
- package/dialog/dialog.stories.js +20 -0
- package/dialog/index.d.ts +4 -0
- package/dialog/index.js +7 -0
- package/dialog/theme.d.ts +11 -0
- package/dialog/theme.js +2 -0
- package/dropdown/dropdown.d.ts +13 -0
- package/dropdown/dropdown.js +50 -0
- package/dropdown/dropdown.spec.d.ts +1 -0
- package/dropdown/dropdown.spec.js +9 -0
- package/dropdown/dropdown.stories.d.ts +2 -0
- package/dropdown/dropdown.stories.js +23 -0
- package/dropdown/index.d.ts +2 -0
- package/dropdown/index.js +5 -0
- package/dropzone/dropzone-input.d.ts +24 -0
- package/dropzone/dropzone-input.js +146 -0
- package/dropzone/dropzone-list.d.ts +15 -0
- package/dropzone/dropzone-list.js +81 -0
- package/dropzone/dropzone.spec.d.ts +1 -0
- package/dropzone/dropzone.spec.js +9 -0
- package/dropzone/dropzone.stories.d.ts +2 -0
- package/dropzone/dropzone.stories.js +63 -0
- package/dropzone/handle-rejected-files.d.ts +2 -0
- package/dropzone/handle-rejected-files.js +17 -0
- package/dropzone/index.d.ts +6 -0
- package/dropzone/index.js +6 -0
- package/dropzone/types.d.ts +10 -0
- package/dropzone/types.js +2 -0
- package/error-message/error-message.d.ts +6 -0
- package/error-message/error-message.js +12 -0
- package/error-message/error-message.spec.d.ts +1 -0
- package/error-message/error-message.spec.js +9 -0
- package/error-message/error-message.stories.d.ts +2 -0
- package/error-message/error-message.stories.js +12 -0
- package/error-message/index.d.ts +1 -0
- package/error-message/index.js +5 -0
- package/file-input/file-input.d.ts +15 -0
- package/file-input/file-input.js +72 -0
- package/file-input/file-input.spec.d.ts +1 -0
- package/file-input/file-input.spec.js +9 -0
- package/file-input/file-input.stories.d.ts +2 -0
- package/file-input/file-input.stories.js +43 -0
- package/file-input/index.d.ts +2 -0
- package/file-input/index.js +5 -0
- package/flash-messages/flash-message.d.ts +17 -0
- package/flash-messages/flash-message.js +47 -0
- package/flash-messages/flash-messages-service.d.ts +4 -0
- package/flash-messages/flash-messages-service.js +14 -0
- package/flash-messages/flash-messages.d.ts +8 -0
- package/flash-messages/flash-messages.js +116 -0
- package/flash-messages/flash-messages.spec.d.ts +1 -0
- package/flash-messages/flash-messages.spec.js +9 -0
- package/flash-messages/flash-messages.stories.d.ts +2 -0
- package/flash-messages/flash-messages.stories.js +70 -0
- package/flash-messages/index.d.ts +3 -0
- package/flash-messages/index.js +8 -0
- package/flash-messages/theme.d.ts +6 -0
- package/flash-messages/theme.js +2 -0
- package/form-component/form-component.d.ts +14 -0
- package/form-component/form-component.js +41 -0
- package/form-component/form-component.spec.d.ts +1 -0
- package/form-component/form-component.spec.js +9 -0
- package/form-component/form-component.stories.d.ts +2 -0
- package/form-component/form-component.stories.js +19 -0
- package/form-component/index.d.ts +2 -0
- package/form-component/index.js +5 -0
- package/hooks/use-async-loading.d.ts +4 -0
- package/hooks/use-async-loading.js +31 -0
- package/hooks/use-dropdown.d.ts +39 -0
- package/hooks/use-dropdown.js +28 -0
- package/hooks/use-input-submit.d.ts +4 -0
- package/hooks/use-input-submit.js +39 -0
- package/icon/icon.d.ts +20 -0
- package/icon/icon.js +59 -0
- package/icon/icon.spec.d.ts +1 -0
- package/icon/icon.spec.js +10 -0
- package/icon/icon.stories.d.ts +6 -0
- package/icon/icon.stories.js +43 -0
- package/icon/index.d.ts +3 -0
- package/icon/index.js +5 -0
- package/icon/theme.d.ts +10 -0
- package/icon/theme.js +2 -0
- package/icon/types.d.ts +2 -0
- package/icon/types.js +2 -0
- package/icon-button/icon-button.d.ts +9 -0
- package/icon-button/icon-button.js +36 -0
- package/icon-button/icon-button.spec.d.ts +1 -0
- package/icon-button/icon-button.spec.js +9 -0
- package/icon-button/icon-button.stories.d.ts +2 -0
- package/icon-button/icon-button.stories.js +58 -0
- package/icon-button/index.d.ts +2 -0
- package/icon-button/index.js +5 -0
- package/image-gallery/components/close-button.d.ts +8 -0
- package/image-gallery/components/close-button.js +17 -0
- package/image-gallery/components/dot.d.ts +6 -0
- package/image-gallery/components/dot.js +14 -0
- package/image-gallery/components/gallery.d.ts +15 -0
- package/image-gallery/components/gallery.js +80 -0
- package/image-gallery/components/next-button.d.ts +7 -0
- package/image-gallery/components/next-button.js +14 -0
- package/image-gallery/components/prev-button.d.ts +7 -0
- package/image-gallery/components/prev-button.js +14 -0
- package/image-gallery/context.d.ts +9 -0
- package/image-gallery/context.js +12 -0
- package/image-gallery/image-gallery.d.ts +14 -0
- package/image-gallery/image-gallery.js +58 -0
- package/image-gallery/image-gallery.spec.d.ts +1 -0
- package/image-gallery/image-gallery.spec.js +9 -0
- package/image-gallery/image-gallery.stories.d.ts +2 -0
- package/image-gallery/image-gallery.stories.js +36 -0
- package/image-gallery/image.d.ts +3 -0
- package/image-gallery/image.js +18 -0
- package/image-gallery/index.d.ts +5 -0
- package/image-gallery/index.js +8 -0
- package/image-gallery/translations.d.ts +11 -0
- package/image-gallery/translations.js +12 -0
- package/image-gallery/types.d.ts +9 -0
- package/image-gallery/types.js +2 -0
- package/image-gallery/use-image.d.ts +2 -0
- package/image-gallery/use-image.js +16 -0
- package/info-box/index.d.ts +2 -0
- package/info-box/index.js +5 -0
- package/info-box/info-box.d.ts +15 -0
- package/info-box/info-box.js +61 -0
- package/info-box/info-box.spec.d.ts +1 -0
- package/info-box/info-box.spec.js +9 -0
- package/info-box/info-box.stories.d.ts +2 -0
- package/info-box/info-box.stories.js +20 -0
- package/info-box/theme.d.ts +15 -0
- package/info-box/theme.js +2 -0
- package/info-box/types.d.ts +3 -0
- package/info-box/types.js +2 -0
- package/input/index.d.ts +14 -0
- package/input/index.js +20 -0
- package/input/input-arrow-icon.d.ts +8 -0
- package/input/input-arrow-icon.js +15 -0
- package/input/input-element.d.ts +24 -0
- package/input/input-element.js +33 -0
- package/input/input-left-addon.d.ts +5 -0
- package/input/input-left-addon.js +14 -0
- package/input/input-left-element.d.ts +5 -0
- package/input/input-left-element.js +12 -0
- package/input/input-remove-button.d.ts +5 -0
- package/input/input-remove-button.js +29 -0
- package/input/input-right-addon.d.ts +5 -0
- package/input/input-right-addon.js +14 -0
- package/input/input-right-element.d.ts +5 -0
- package/input/input-right-element.js +12 -0
- package/input/input.d.ts +20 -0
- package/input/input.js +66 -0
- package/input/input.spec.d.ts +1 -0
- package/input/input.spec.js +10 -0
- package/input/input.stories.d.ts +4 -0
- package/input/input.stories.js +90 -0
- package/input/theme.d.ts +10 -0
- package/input/theme.js +2 -0
- package/label/index.d.ts +2 -0
- package/label/index.js +5 -0
- package/label/label.d.ts +12 -0
- package/label/label.js +37 -0
- package/label/label.spec.d.ts +1 -0
- package/label/label.spec.js +9 -0
- package/label/label.stories.d.ts +2 -0
- package/label/label.stories.js +12 -0
- package/layout/index.d.ts +2 -0
- package/layout/index.js +5 -0
- package/layout/layout.d.ts +13 -0
- package/layout/layout.js +46 -0
- package/layout/layout.spec.d.ts +1 -0
- package/layout/layout.spec.js +9 -0
- package/layout/layout.stories.d.ts +2 -0
- package/layout/layout.stories.js +15 -0
- package/layout/translations.d.ts +11 -0
- package/layout/translations.js +12 -0
- package/layout/uxf-logo.d.ts +6 -0
- package/layout/uxf-logo.js +13 -0
- package/lightbox/components/lightbox-close-button.d.ts +6 -0
- package/lightbox/components/lightbox-close-button.js +16 -0
- package/lightbox/components/lightbox-dialog.d.ts +15 -0
- package/lightbox/components/lightbox-dialog.js +49 -0
- package/lightbox/components/lightbox-dot.d.ts +9 -0
- package/lightbox/components/lightbox-dot.js +13 -0
- package/lightbox/components/lightbox-next-button.d.ts +6 -0
- package/lightbox/components/lightbox-next-button.js +16 -0
- package/lightbox/components/lightbox-prev-button.d.ts +6 -0
- package/lightbox/components/lightbox-prev-button.js +16 -0
- package/lightbox/components/use-lightbox-dialog.d.ts +34 -0
- package/lightbox/components/use-lightbox-dialog.js +51 -0
- package/lightbox/context.d.ts +11 -0
- package/lightbox/context.js +17 -0
- package/lightbox/index.d.ts +4 -0
- package/lightbox/index.js +9 -0
- package/lightbox/lightbox.d.ts +14 -0
- package/lightbox/lightbox.js +27 -0
- package/lightbox/lightbox.spec.d.ts +1 -0
- package/lightbox/lightbox.spec.js +9 -0
- package/lightbox/lightbox.stories.d.ts +2 -0
- package/lightbox/lightbox.stories.js +43 -0
- package/lightbox/translations.d.ts +23 -0
- package/lightbox/translations.js +24 -0
- package/lightbox/types.d.ts +20 -0
- package/lightbox/types.js +2 -0
- package/lightbox/use-lightbox-image.d.ts +2 -0
- package/lightbox/use-lightbox-image.js +17 -0
- package/lightbox/use-lightbox.d.ts +11 -0
- package/lightbox/use-lightbox.js +34 -0
- package/list-item/index.d.ts +2 -0
- package/list-item/index.js +5 -0
- package/list-item/list-item.d.ts +10 -0
- package/list-item/list-item.js +45 -0
- package/list-item/list-item.spec.d.ts +1 -0
- package/list-item/list-item.spec.js +9 -0
- package/list-item/list-item.stories.d.ts +2 -0
- package/list-item/list-item.stories.js +28 -0
- package/loader/index.d.ts +2 -0
- package/loader/index.js +5 -0
- package/loader/loader.d.ts +5 -0
- package/loader/loader.js +34 -0
- package/loader/loader.spec.d.ts +1 -0
- package/loader/loader.spec.js +9 -0
- package/loader/loader.stories.d.ts +2 -0
- package/loader/loader.stories.js +16 -0
- package/lozenge/index.d.ts +3 -0
- package/lozenge/index.js +5 -0
- package/lozenge/lozenge.d.ts +7 -0
- package/lozenge/lozenge.js +35 -0
- package/lozenge/lozenge.spec.d.ts +1 -0
- package/lozenge/lozenge.spec.js +9 -0
- package/lozenge/lozenge.stories.d.ts +2 -0
- package/lozenge/lozenge.stories.js +16 -0
- package/lozenge/theme.d.ts +14 -0
- package/lozenge/theme.js +2 -0
- package/message/index.d.ts +3 -0
- package/message/index.js +7 -0
- package/message/message-content.d.ts +20 -0
- package/message/message-content.js +42 -0
- package/message/message-service.d.ts +13 -0
- package/message/message-service.js +30 -0
- package/message/message.d.ts +24 -0
- package/message/message.js +55 -0
- package/message/message.spec.d.ts +1 -0
- package/message/message.spec.js +9 -0
- package/message/message.stories.d.ts +2 -0
- package/message/message.stories.js +71 -0
- package/message/theme.d.ts +12 -0
- package/message/theme.js +2 -0
- package/modal/index.d.ts +4 -0
- package/modal/index.js +11 -0
- package/modal/modal-provider.d.ts +3 -0
- package/modal/modal-provider.js +57 -0
- package/modal/modal-service.d.ts +4 -0
- package/modal/modal-service.js +20 -0
- package/modal/modal.d.ts +3 -0
- package/modal/modal.js +27 -0
- package/modal/modal.spec.d.ts +1 -0
- package/modal/modal.spec.js +9 -0
- package/modal/modal.stories.d.ts +3 -0
- package/modal/modal.stories.js +109 -0
- package/modal/theme.d.ts +4 -0
- package/modal/theme.js +2 -0
- package/modal/types.d.ts +23 -0
- package/modal/types.js +2 -0
- package/modal-dialog/modal-dialog.d.ts +13 -0
- package/modal-dialog/modal-dialog.js +18 -0
- package/modal-dialog/modal-dialog.stories.d.ts +2 -0
- package/modal-dialog/modal-dialog.stories.js +28 -0
- package/modal-header/index.d.ts +2 -0
- package/modal-header/index.js +5 -0
- package/modal-header/modal-header.d.ts +10 -0
- package/modal-header/modal-header.js +27 -0
- package/modal-header/modal-header.spec.d.ts +1 -0
- package/modal-header/modal-header.spec.js +9 -0
- package/modal-header/modal-header.stories.d.ts +2 -0
- package/modal-header/modal-header.stories.js +19 -0
- package/multi-combobox/index.d.ts +2 -0
- package/multi-combobox/index.js +5 -0
- package/multi-combobox/multi-combobox.d.ts +3 -0
- package/multi-combobox/multi-combobox.js +174 -0
- package/multi-combobox/multi-combobox.spec.d.ts +1 -0
- package/multi-combobox/multi-combobox.spec.js +10 -0
- package/multi-combobox/multi-combobox.stories.d.ts +4 -0
- package/multi-combobox/multi-combobox.stories.js +89 -0
- package/multi-combobox/translations.d.ts +29 -0
- package/multi-combobox/translations.js +30 -0
- package/multi-combobox/types.d.ts +48 -0
- package/multi-combobox/types.js +2 -0
- package/multi-select/index.d.ts +2 -0
- package/multi-select/index.js +5 -0
- package/multi-select/multi-select.d.ts +3 -0
- package/multi-select/multi-select.js +138 -0
- package/multi-select/multi-select.spec.d.ts +1 -0
- package/multi-select/multi-select.spec.js +9 -0
- package/multi-select/multi-select.stories.d.ts +3 -0
- package/multi-select/multi-select.stories.js +75 -0
- package/multi-select/translations.d.ts +17 -0
- package/multi-select/translations.js +18 -0
- package/multi-select/types.d.ts +43 -0
- package/multi-select/types.js +2 -0
- package/package.json +2 -2
- package/pagination/index.d.ts +2 -0
- package/pagination/index.js +5 -0
- package/pagination/pagination.d.ts +12 -0
- package/pagination/pagination.js +62 -0
- package/pagination/pagination.spec.d.ts +1 -0
- package/pagination/pagination.spec.js +9 -0
- package/pagination/pagination.stories.d.ts +2 -0
- package/pagination/pagination.stories.js +40 -0
- package/pagination/theme.d.ts +7 -0
- package/pagination/theme.js +2 -0
- package/paper/index.d.ts +2 -0
- package/paper/index.js +5 -0
- package/paper/paper.d.ts +5 -0
- package/paper/paper.js +33 -0
- package/paper/paper.spec.d.ts +1 -0
- package/paper/paper.spec.js +9 -0
- package/paper/paper.stories.d.ts +2 -0
- package/paper/paper.stories.js +13 -0
- package/radio/index.d.ts +3 -0
- package/radio/index.js +5 -0
- package/radio/radio.d.ts +12 -0
- package/radio/radio.js +53 -0
- package/radio/radio.spec.d.ts +1 -0
- package/radio/radio.spec.js +9 -0
- package/radio/radio.stories.d.ts +2 -0
- package/radio/radio.stories.js +29 -0
- package/radio/theme.d.ts +5 -0
- package/radio/theme.js +2 -0
- package/radio-group/index.d.ts +3 -0
- package/radio-group/index.js +5 -0
- package/radio-group/radio-group.d.ts +23 -0
- package/radio-group/radio-group.js +51 -0
- package/radio-group/radio-group.spec.d.ts +1 -0
- package/radio-group/radio-group.spec.js +9 -0
- package/radio-group/radio-group.stories.d.ts +2 -0
- package/radio-group/radio-group.stories.js +55 -0
- package/radio-group/theme.d.ts +7 -0
- package/radio-group/theme.js +2 -0
- package/raster-image/empty-image.d.ts +9 -0
- package/raster-image/empty-image.js +12 -0
- package/raster-image/img-sources.d.ts +17 -0
- package/raster-image/img-sources.js +44 -0
- package/raster-image/index.d.ts +2 -0
- package/raster-image/index.js +5 -0
- package/raster-image/raster-image.d.ts +35 -0
- package/raster-image/raster-image.js +36 -0
- package/raster-image/raster-image.spec.d.ts +1 -0
- package/raster-image/raster-image.spec.js +9 -0
- package/raster-image/raster-image.stories.d.ts +2 -0
- package/raster-image/raster-image.stories.js +12 -0
- package/raster-image/responsive-img-sources.d.ts +15 -0
- package/raster-image/responsive-img-sources.js +19 -0
- package/readmes.d.ts +66 -0
- package/readmes.js +135 -0
- package/select/index.d.ts +2 -0
- package/select/index.js +5 -0
- package/select/select.d.ts +47 -0
- package/select/select.js +103 -0
- package/select/select.spec.d.ts +1 -0
- package/select/select.spec.js +9 -0
- package/select/select.stories.d.ts +3 -0
- package/select/select.stories.js +78 -0
- package/select/translations.d.ts +11 -0
- package/select/translations.js +12 -0
- package/tabs/components/tabs-button-list.d.ts +12 -0
- package/tabs/components/tabs-button-list.js +36 -0
- package/tabs/components/tabs-button.d.ts +17 -0
- package/tabs/components/tabs-button.js +40 -0
- package/tabs/components/tabs-panel.d.ts +11 -0
- package/tabs/components/tabs-panel.js +16 -0
- package/tabs/components/tabs-panels.d.ts +2 -0
- package/tabs/components/tabs-panels.js +10 -0
- package/tabs/components/tabs-root.d.ts +10 -0
- package/tabs/components/tabs-root.js +12 -0
- package/tabs/create-tab-id.d.ts +1 -0
- package/tabs/create-tab-id.js +6 -0
- package/tabs/index.d.ts +2 -0
- package/tabs/index.js +18 -0
- package/tabs/panel-content.d.ts +9 -0
- package/tabs/panel-content.js +35 -0
- package/tabs/panel.d.ts +21 -0
- package/tabs/panel.js +11 -0
- package/tabs/tabs.d.ts +22 -0
- package/tabs/tabs.js +74 -0
- package/tabs/tabs.spec.d.ts +1 -0
- package/tabs/tabs.spec.js +10 -0
- package/tabs/tabs.stories.d.ts +3 -0
- package/tabs/tabs.stories.js +68 -0
- package/tabs/theme.d.ts +4 -0
- package/tabs/theme.js +2 -0
- package/tabs/types.d.ts +2 -0
- package/tabs/types.js +2 -0
- package/text-input/index.d.ts +2 -0
- package/text-input/index.js +5 -0
- package/text-input/text-input.d.ts +33 -0
- package/text-input/text-input.js +51 -0
- package/text-input/text-input.spec.d.ts +1 -0
- package/text-input/text-input.spec.js +9 -0
- package/text-input/text-input.stories.d.ts +3 -0
- package/text-input/text-input.stories.js +64 -0
- package/text-link/index.d.ts +2 -0
- package/text-link/index.js +5 -0
- package/text-link/text-link.d.ts +10 -0
- package/text-link/text-link.js +41 -0
- package/text-link/text-link.spec.d.ts +1 -0
- package/text-link/text-link.spec.js +9 -0
- package/text-link/text-link.stories.d.ts +2 -0
- package/text-link/text-link.stories.js +17 -0
- package/text-link/theme.d.ts +4 -0
- package/text-link/theme.js +2 -0
- package/textarea/index.d.ts +2 -0
- package/textarea/index.js +5 -0
- package/textarea/textarea.d.ts +18 -0
- package/textarea/textarea.js +59 -0
- package/textarea/textarea.spec.d.ts +1 -0
- package/textarea/textarea.spec.js +9 -0
- package/textarea/textarea.stories.d.ts +2 -0
- package/textarea/textarea.stories.js +39 -0
- package/time-picker/index.d.ts +2 -0
- package/time-picker/index.js +5 -0
- package/time-picker/time-picker-hour.d.ts +5 -0
- package/time-picker/time-picker-hour.js +49 -0
- package/time-picker/time-picker-hours.d.ts +2 -0
- package/time-picker/time-picker-hours.js +15 -0
- package/time-picker/time-picker-minute.d.ts +5 -0
- package/time-picker/time-picker-minute.js +49 -0
- package/time-picker/time-picker-minutes.d.ts +2 -0
- package/time-picker/time-picker-minutes.js +15 -0
- package/time-picker/time-picker.d.ts +9 -0
- package/time-picker/time-picker.js +74 -0
- package/time-picker/time-picker.spec.d.ts +1 -0
- package/time-picker/time-picker.spec.js +9 -0
- package/time-picker/time-picker.stories.d.ts +2 -0
- package/time-picker/time-picker.stories.js +36 -0
- package/time-picker/translations.d.ts +17 -0
- package/time-picker/translations.js +18 -0
- package/time-picker-input/index.d.ts +2 -0
- package/time-picker-input/index.js +8 -0
- package/time-picker-input/time-picker-input.d.ts +17 -0
- package/time-picker-input/time-picker-input.js +83 -0
- package/time-picker-input/time-picker-input.spec.d.ts +1 -0
- package/time-picker-input/time-picker-input.spec.js +9 -0
- package/time-picker-input/time-picker-input.stories.d.ts +2 -0
- package/time-picker-input/time-picker-input.stories.js +45 -0
- package/toggle/index.d.ts +3 -0
- package/toggle/index.js +5 -0
- package/toggle/theme.d.ts +10 -0
- package/toggle/theme.js +2 -0
- package/toggle/toggle.d.ts +13 -0
- package/toggle/toggle.js +39 -0
- package/toggle/toggle.spec.d.ts +1 -0
- package/toggle/toggle.spec.js +9 -0
- package/toggle/toggle.stories.d.ts +2 -0
- package/toggle/toggle.stories.js +41 -0
- package/tooltip/index.d.ts +4 -0
- package/tooltip/index.js +7 -0
- package/tooltip/tooltip.d.ts +9 -0
- package/tooltip/tooltip.js +73 -0
- package/tooltip/tooltip.spec.d.ts +1 -0
- package/tooltip/tooltip.spec.js +9 -0
- package/tooltip/tooltip.stories.d.ts +2 -0
- package/tooltip/tooltip.stories.js +38 -0
- package/tooltip/use-tooltip.d.ts +55 -0
- package/tooltip/use-tooltip.js +39 -0
- package/translations/cs.json +61 -0
- package/translations/de.json +61 -0
- package/translations/en.json +61 -0
- package/translations/sk.json +61 -0
- package/tw-tokens/tw-box-shadow.d.ts +12 -0
- package/tw-tokens/tw-box-shadow.js +15 -0
- package/tw-tokens/tw-colors.d.ts +468 -0
- package/tw-tokens/tw-colors.js +471 -0
- package/tw-tokens/tw-containers.d.ts +8 -0
- package/tw-tokens/tw-containers.js +5 -0
- package/tw-tokens/tw-font-size.d.ts +55 -0
- package/tw-tokens/tw-font-size.js +32 -0
- package/tw-tokens/tw-font-weight.d.ts +12 -0
- package/tw-tokens/tw-font-weight.js +15 -0
- package/tw-tokens/tw-line-height.d.ts +17 -0
- package/tw-tokens/tw-line-height.js +20 -0
- package/tw-tokens/tw-screens.d.ts +8 -0
- package/tw-tokens/tw-screens.js +5 -0
- package/tw-tokens/tw-spacing.d.ts +39 -0
- package/tw-tokens/tw-spacing.js +42 -0
- package/tw-tokens/tw-z-index.d.ts +21 -0
- package/tw-tokens/tw-z-index.js +24 -0
- package/types/color.d.ts +2 -0
- package/types/color.js +2 -0
- package/types/file-response.d.ts +6 -0
- package/types/file-response.js +2 -0
- package/types/form-control-props.d.ts +30 -0
- package/types/form-control-props.js +2 -0
- package/types/index.d.ts +3 -0
- package/types/index.js +19 -0
- package/typography/typography.spec.d.ts +1 -0
- package/typography/typography.spec.js +9 -0
- package/typography/typography.stories.d.ts +2 -0
- package/typography/typography.stories.js +23 -0
- package/utils/action.d.ts +3 -0
- package/utils/action.js +10 -0
- package/utils/component-structure-analyzer.d.ts +6 -0
- package/utils/component-structure-analyzer.js +10 -0
- package/utils/files/get-file-icon.d.ts +2 -0
- package/utils/files/get-file-icon.js +18 -0
- package/utils/files/get-file-icon.test.d.ts +1 -0
- package/utils/files/get-file-icon.test.js +22 -0
- package/utils/files/get-file-url.d.ts +2 -0
- package/utils/files/get-file-url.js +6 -0
- package/utils/files/get-file-url.test.d.ts +1 -0
- package/utils/files/get-file-url.test.js +44 -0
- package/utils/get-default-icon-name.d.ts +4 -0
- package/utils/get-default-icon-name.js +19 -0
- package/utils/get-dropzone-state.d.ts +7 -0
- package/utils/get-dropzone-state.js +23 -0
- package/utils/get-dropzone-state.test.d.ts +1 -0
- package/utils/get-dropzone-state.test.js +88 -0
- package/utils/mocks/upload-file.mock.d.ts +3 -0
- package/utils/mocks/upload-file.mock.js +46 -0
- package/utils/mocks/upload-file.mock.test.d.ts +1 -0
- package/utils/mocks/upload-file.mock.test.js +34 -0
- package/utils/next-link.d.ts +22 -0
- package/utils/next-link.js +2 -0
- package/utils/snap-test.d.ts +2 -0
- package/utils/snap-test.js +22 -0
- package/utils/storybook-config.d.ts +49 -0
- package/utils/storybook-config.js +72 -0
- package/utils/validator/validator-exceptions.d.ts +3 -0
- package/utils/validator/validator-exceptions.js +7 -0
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.UxfLogo = void 0;
|
|
7
|
+
const react_1 = __importDefault(require("react"));
|
|
8
|
+
const UxfLogo = (props) => {
|
|
9
|
+
return (react_1.default.createElement("svg", { height: "40", width: "179" },
|
|
10
|
+
react_1.default.createElement("path", { clipRule: "evenodd", d: "M33.563 12.874a9.103 9.103 0 0 0 0-12.874L20.69 12.874l.107.105a9.103 9.103 0 0 0 12.766-.105Zm-20.69-6.437a9.103 9.103 0 0 1 .106 12.766l-.105.107L0 6.437a9.103 9.103 0 0 1 12.874 0ZM40 33.563 27.127 20.69l-.106.107a9.103 9.103 0 0 0 12.98 12.766Zm-20.69-6.437-.107-.105A9.103 9.103 0 0 0 6.437 40l12.874-12.874Z", fill: "#FF4F06", fillRule: "evenodd" }),
|
|
11
|
+
react_1.default.createElement("path", { clipRule: "evenodd", d: "m84.325 7.295 5.133 8.675h.199l5.158-8.675h6.078l-7.768 12.727 7.942 12.727h-6.19l-5.22-8.687h-.199l-5.22 8.687h-6.165l7.967-12.727-7.818-12.727h6.103Zm-24.194 0v16.07c0 .97.214 1.832.64 2.586a4.58 4.58 0 0 0 1.809 1.777c.779.431 1.686.647 2.722.647 1.044 0 1.953-.216 2.728-.647a4.591 4.591 0 0 0 1.802-1.777c.427-.754.64-1.616.64-2.585V7.296h5.382v16.53c0 1.856-.441 3.48-1.324 4.872-.882 1.392-2.115 2.475-3.697 3.25-1.583.775-3.426 1.162-5.531 1.162-2.113 0-3.96-.387-5.543-1.162-1.583-.775-2.813-1.858-3.692-3.25-.878-1.392-1.317-3.016-1.317-4.872V7.296h5.381ZM170.25 13.41c2.411 0 4.311.51 5.698 1.529 1.388 1.019 2.198 2.407 2.43 4.164l-4.847.298a2.555 2.555 0 0 0-.534-1.125 2.942 2.942 0 0 0-1.075-.808c-.444-.203-.972-.304-1.585-.304-.821 0-1.512.172-2.076.515-.563.344-.845.802-.845 1.374 0 .456.182.84.547 1.156.364.315.99.567 1.877.758l3.455.696c1.856.381 3.24.994 4.151 1.84.912.845 1.367 1.955 1.367 3.33 0 1.252-.366 2.35-1.1 3.294-.733.945-1.736 1.68-3.007 2.206-1.272.526-2.737.79-4.394.79-2.527 0-4.539-.529-6.034-1.585-1.496-1.057-2.372-2.496-2.629-4.32l5.208-.273c.157.77.538 1.357 1.143 1.759.605.402 1.38.603 2.324.603.928 0 1.676-.18 2.244-.54.567-.361.855-.827.864-1.4-.009-.48-.212-.875-.609-1.186-.398-.31-1.011-.55-1.84-.715l-3.306-.659c-1.864-.372-3.25-1.019-4.157-1.938-.908-.92-1.361-2.093-1.361-3.518 0-1.226.333-2.283 1-3.17.667-.886 1.608-1.57 2.821-2.05 1.214-.48 2.637-.72 4.27-.72Zm-36.686.373a12.285 12.285 0 0 0-3.051-.373c-1.525 0-2.865.23-4.021.69-1.156.46-2.098 1.114-2.827 1.964-.73.849-1.219 1.854-1.467 3.014l4.897.397c.182-.63.555-1.153 1.119-1.572.563-.418 1.321-.627 2.274-.627.903 0 1.601.215 2.094.646.493.43.74 1.04.74 1.827v.075c0 .405-.153.712-.46.92-.307.206-.8.362-1.479.465-.68.104-1.574.214-2.685.33-.944.09-1.845.248-2.703.472a7.698 7.698 0 0 0-2.293.994 4.727 4.727 0 0 0-1.591 1.74c-.39.721-.584 1.612-.584 2.673 0 1.259.275 2.31.826 3.15a5.147 5.147 0 0 0 2.256 1.902c.953.427 2.038.64 3.257.64.944 0 1.777-.126 2.498-.38a5.55 5.55 0 0 0 1.852-1.055 5.31 5.31 0 0 0 1.23-1.573h.149v2.648h5.022V19.873c0-1.135-.22-2.11-.659-2.927a5.655 5.655 0 0 0-1.796-2.007 8.039 8.039 0 0 0-2.598-1.156Zm-13.424-2.05V7.294h-16.853v25.454h5.381V22.235h10.354v-4.438h-10.354v-6.065h11.472Zm32.603 1.677c1.326 0 2.482.29 3.468.87.986.58 1.753 1.407 2.3 2.48.546 1.073.82 2.35.82 3.834V32.75h-5.295V21.539c.008-1.169-.29-2.082-.895-2.74-.605-.66-1.437-.989-2.498-.989-.713 0-1.34.153-1.883.46a3.166 3.166 0 0 0-1.268 1.336c-.302.584-.458 1.286-.466 2.107V32.75h-5.295V13.659h5.047v3.368H147a5.358 5.358 0 0 1 2.126-2.641c.994-.65 2.2-.976 3.616-.976Zm-20.061 10.782c.286-.087.512-.184.678-.292v2.026c0 .671-.17 1.272-.51 1.802-.34.53-.808.951-1.404 1.262-.597.31-1.285.466-2.064.466-.812 0-1.481-.189-2.007-.566-.526-.377-.789-.925-.789-1.646 0-.497.128-.914.385-1.25.257-.335.617-.602 1.082-.801a6.547 6.547 0 0 1 1.628-.435l.969-.143a24.15 24.15 0 0 0 1.069-.186c.356-.071.677-.15.963-.237Z", fill: props.isDark ? "#140939" : "#FFF", fillRule: "evenodd" })));
|
|
12
|
+
};
|
|
13
|
+
exports.UxfLogo = UxfLogo;
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.LightboxCloseButton = LightboxCloseButton;
|
|
8
|
+
const translations_1 = require("@uxf/core-react/translations");
|
|
9
|
+
const icon_1 = require("@uxf/ui/icon");
|
|
10
|
+
const react_1 = __importDefault(require("react"));
|
|
11
|
+
function LightboxCloseButton(props) {
|
|
12
|
+
const t = (0, translations_1.useUxfTranslation)();
|
|
13
|
+
return (react_1.default.createElement("button", { className: "uxf-lightbox__close-button", onClick: props.onClick, title: t("uxf-ui-lightbox:close") },
|
|
14
|
+
react_1.default.createElement(icon_1.Icon, { className: "uxf-lightbox__close-button-icon", name: "xmarkLarge" })));
|
|
15
|
+
}
|
|
16
|
+
LightboxCloseButton.displayName = "UxfUiLightboxCloseButton";
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import type { Noop } from "@uxf/core/types";
|
|
2
|
+
import React, { type FC } from "react";
|
|
3
|
+
import { type LightboxButtonProps, LightboxImageProps } from "../types";
|
|
4
|
+
export interface LightboxDialogProps {
|
|
5
|
+
CloseButtonElement?: FC<LightboxButtonProps>;
|
|
6
|
+
NextButtonElement?: FC<LightboxButtonProps>;
|
|
7
|
+
PrevButtonElement?: FC<LightboxButtonProps>;
|
|
8
|
+
imageIndex: number;
|
|
9
|
+
images: LightboxImageProps[];
|
|
10
|
+
isBackdropCloseDisabled?: boolean;
|
|
11
|
+
onClose: Noop;
|
|
12
|
+
onNext: Noop;
|
|
13
|
+
onPrev: Noop;
|
|
14
|
+
}
|
|
15
|
+
export declare function LightboxDialog(props: LightboxDialogProps): React.JSX.Element | null;
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.LightboxDialog = LightboxDialog;
|
|
8
|
+
const react_1 = require("@floating-ui/react");
|
|
9
|
+
const show_1 = require("@uxf/core-react/components/show");
|
|
10
|
+
const image_1 = require("@uxf/core/utils/image");
|
|
11
|
+
const is_nil_1 = require("@uxf/core/utils/is-nil");
|
|
12
|
+
const is_not_nil_1 = require("@uxf/core/utils/is-not-nil");
|
|
13
|
+
const raster_image_1 = require("@uxf/ui/raster-image");
|
|
14
|
+
const react_2 = __importDefault(require("react"));
|
|
15
|
+
const lightbox_close_button_1 = require("./lightbox-close-button");
|
|
16
|
+
const lightbox_dot_1 = require("./lightbox-dot");
|
|
17
|
+
const lightbox_next_button_1 = require("./lightbox-next-button");
|
|
18
|
+
const lightbox_prev_button_1 = require("./lightbox-prev-button");
|
|
19
|
+
const use_lightbox_dialog_1 = require("./use-lightbox-dialog");
|
|
20
|
+
function LightboxDialog(props) {
|
|
21
|
+
var _a, _b;
|
|
22
|
+
const { imageCustomContent, imageSrc, swipableHandlers, getFloatingProps, setFloating, floatingContext } = (0, use_lightbox_dialog_1.useLightboxDialog)({
|
|
23
|
+
images: props.images,
|
|
24
|
+
imageIndex: props.imageIndex,
|
|
25
|
+
onClose: props.onClose,
|
|
26
|
+
onNext: props.onNext,
|
|
27
|
+
onPrev: props.onPrev,
|
|
28
|
+
});
|
|
29
|
+
if ((0, is_nil_1.isNil)(imageSrc)) {
|
|
30
|
+
return null;
|
|
31
|
+
}
|
|
32
|
+
return (react_2.default.createElement(react_1.FloatingPortal, null,
|
|
33
|
+
react_2.default.createElement(react_1.FloatingOverlay, { lockScroll: true },
|
|
34
|
+
react_2.default.createElement(react_1.FloatingFocusManager, { context: floatingContext },
|
|
35
|
+
react_2.default.createElement("div", { ...getFloatingProps({ "aria-modal": true, className: "uxf-lightbox", ref: setFloating }) },
|
|
36
|
+
react_2.default.createElement("div", { "aria-hidden": true, className: "uxf-lightbox__backdrop", onClick: !props.isBackdropCloseDisabled ? props.onClose : undefined }),
|
|
37
|
+
(0, is_not_nil_1.isNotNil)(props.CloseButtonElement) ? (react_2.default.createElement(props.CloseButtonElement, { onClick: props.onClose })) : (react_2.default.createElement(lightbox_close_button_1.LightboxCloseButton, { onClick: props.onClose })),
|
|
38
|
+
props.images.length > 1 && (react_2.default.createElement("div", { className: "uxf-lightbox__buttons" },
|
|
39
|
+
(0, is_not_nil_1.isNotNil)(props.PrevButtonElement) ? (react_2.default.createElement(props.PrevButtonElement, { onClick: props.onPrev })) : (react_2.default.createElement(lightbox_prev_button_1.LightboxPrevButton, { onClick: props.onPrev })),
|
|
40
|
+
(0, is_not_nil_1.isNotNil)(props.NextButtonElement) ? (react_2.default.createElement(props.NextButtonElement, { onClick: props.onNext })) : (react_2.default.createElement(lightbox_next_button_1.LightboxNextButton, { onClick: props.onNext })))),
|
|
41
|
+
react_2.default.createElement("div", { className: "uxf-lightbox__content", ...swipableHandlers },
|
|
42
|
+
react_2.default.createElement("div", { className: "uxf-lightbox__inner" },
|
|
43
|
+
react_2.default.createElement(raster_image_1.RasterImage, { alt: "", className: "uxf-lightbox__image", height: typeof imageSrc !== "string" && "height" in imageSrc
|
|
44
|
+
? ((_a = imageSrc.height) !== null && _a !== void 0 ? _a : 0)
|
|
45
|
+
: 0, key: (0, image_1.getImgUniqueIdentifier)(imageSrc), src: imageSrc, width: typeof imageSrc !== "string" && "width" in imageSrc ? ((_b = imageSrc.width) !== null && _b !== void 0 ? _b : 0) : 0 }),
|
|
46
|
+
react_2.default.createElement(show_1.Show, { when: (0, is_not_nil_1.isNotNil)(imageCustomContent) },
|
|
47
|
+
react_2.default.createElement("div", { className: "uxf-lightbox__custom-content" }, imageCustomContent))),
|
|
48
|
+
props.images.length > 1 && (react_2.default.createElement("div", { className: "uxf-lightbox__dots" }, props.images.map((img, index) => (react_2.default.createElement(lightbox_dot_1.LightboxDot, { isActive: index === props.imageIndex, key: (0, image_1.getImgUniqueIdentifier)(img.src) || index })))))))))));
|
|
49
|
+
}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.LightboxDot = LightboxDot;
|
|
7
|
+
const cx_1 = require("@uxf/core/utils/cx");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
|
+
function LightboxDot(props) {
|
|
10
|
+
const className = (0, cx_1.cx)("uxf-lightbox__dot", props.isActive && "uxf-lightbox__dot--active");
|
|
11
|
+
return react_1.default.createElement("div", { className: className });
|
|
12
|
+
}
|
|
13
|
+
LightboxDot.displayName = "UxfUiLightboxDot";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.LightboxNextButton = LightboxNextButton;
|
|
8
|
+
const translations_1 = require("@uxf/core-react/translations");
|
|
9
|
+
const icon_1 = require("@uxf/ui/icon");
|
|
10
|
+
const react_1 = __importDefault(require("react"));
|
|
11
|
+
function LightboxNextButton(props) {
|
|
12
|
+
const t = (0, translations_1.useUxfTranslation)();
|
|
13
|
+
return (react_1.default.createElement("button", { className: "uxf-lightbox__button uxf-lightbox__button--next", onClick: props.onClick, title: t("uxf-ui-lightbox:next") },
|
|
14
|
+
react_1.default.createElement(icon_1.Icon, { className: "uxf-lightbox__button-icon", name: "chevronRight" })));
|
|
15
|
+
}
|
|
16
|
+
LightboxNextButton.displayName = "UxfUiLightboxNextButton";
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.LightboxPrevButton = LightboxPrevButton;
|
|
8
|
+
const translations_1 = require("@uxf/core-react/translations");
|
|
9
|
+
const icon_1 = require("@uxf/ui/icon");
|
|
10
|
+
const react_1 = __importDefault(require("react"));
|
|
11
|
+
function LightboxPrevButton(props) {
|
|
12
|
+
const t = (0, translations_1.useUxfTranslation)();
|
|
13
|
+
return (react_1.default.createElement("button", { className: "uxf-lightbox__button uxf-lightbox__button--prev", onClick: props.onClick, title: t("uxf-ui-lightbox:previous") },
|
|
14
|
+
react_1.default.createElement(icon_1.Icon, { className: "uxf-lightbox__button-icon", name: "chevronLeft" })));
|
|
15
|
+
}
|
|
16
|
+
LightboxPrevButton.displayName = "UxfUiLightboxPrevButton";
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import type { Noop } from "@uxf/core/types";
|
|
2
|
+
import { LightboxImageProps } from "../types";
|
|
3
|
+
export interface UseLightboxDialogProps {
|
|
4
|
+
imageIndex: number;
|
|
5
|
+
images: LightboxImageProps[];
|
|
6
|
+
onClose: Noop;
|
|
7
|
+
onNext: Noop;
|
|
8
|
+
onPrev: Noop;
|
|
9
|
+
}
|
|
10
|
+
export declare function useLightboxDialog(props: UseLightboxDialogProps): {
|
|
11
|
+
floatingContext: {
|
|
12
|
+
x: number;
|
|
13
|
+
y: number;
|
|
14
|
+
placement: import("@floating-ui/utils").Placement;
|
|
15
|
+
strategy: import("@floating-ui/utils").Strategy;
|
|
16
|
+
middlewareData: import("@floating-ui/core").MiddlewareData;
|
|
17
|
+
isPositioned: boolean;
|
|
18
|
+
update: () => void;
|
|
19
|
+
floatingStyles: React.CSSProperties;
|
|
20
|
+
open: boolean;
|
|
21
|
+
onOpenChange: (open: boolean, event?: Event, reason?: import("@floating-ui/react").OpenChangeReason) => void;
|
|
22
|
+
events: import("@floating-ui/react").FloatingEvents;
|
|
23
|
+
dataRef: React.MutableRefObject<import("@floating-ui/react").ContextData>;
|
|
24
|
+
nodeId: string | undefined;
|
|
25
|
+
floatingId: string;
|
|
26
|
+
refs: import("@floating-ui/react").ExtendedRefs<import("@floating-ui/react").ReferenceType>;
|
|
27
|
+
elements: import("@floating-ui/react").ExtendedElements<import("@floating-ui/react").ReferenceType>;
|
|
28
|
+
};
|
|
29
|
+
getFloatingProps: (userProps?: React.HTMLProps<HTMLElement>) => Record<string, unknown>;
|
|
30
|
+
imageCustomContent: import("react").ReactNode;
|
|
31
|
+
imageSrc: import("@uxf/core/utils/resizer").ImageSource | undefined;
|
|
32
|
+
setFloating: ((node: HTMLElement | null) => void) & ((node: HTMLElement | null) => void);
|
|
33
|
+
swipableHandlers: import("@uxf/core-react/swipeable/types").SwipeableHandlers;
|
|
34
|
+
};
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.useLightboxDialog = useLightboxDialog;
|
|
5
|
+
const react_1 = require("@floating-ui/react");
|
|
6
|
+
const use_on_mount_1 = require("@uxf/core-react/hooks/use-on-mount");
|
|
7
|
+
const use_swipeable_1 = require("@uxf/core-react/swipeable/use-swipeable");
|
|
8
|
+
function useLightboxDialog(props) {
|
|
9
|
+
const { refs, context } = (0, react_1.useFloating)();
|
|
10
|
+
const click = (0, react_1.useClick)(context);
|
|
11
|
+
const role = (0, react_1.useRole)(context);
|
|
12
|
+
const dismiss = (0, react_1.useDismiss)(context, { outsidePressEvent: "mousedown" });
|
|
13
|
+
const { getFloatingProps } = (0, react_1.useInteractions)([click, role, dismiss]);
|
|
14
|
+
(0, use_on_mount_1.useOnMount)(() => {
|
|
15
|
+
const onKeyDown = (event) => {
|
|
16
|
+
switch (event.key) {
|
|
17
|
+
case "ArrowRight":
|
|
18
|
+
props.onNext();
|
|
19
|
+
break;
|
|
20
|
+
case "ArrowLeft":
|
|
21
|
+
props.onPrev();
|
|
22
|
+
break;
|
|
23
|
+
case "Escape":
|
|
24
|
+
props.onClose();
|
|
25
|
+
break;
|
|
26
|
+
}
|
|
27
|
+
};
|
|
28
|
+
document.body.style.overflow = "hidden";
|
|
29
|
+
window.addEventListener("keydown", onKeyDown);
|
|
30
|
+
return () => {
|
|
31
|
+
document.body.style.overflow = "auto";
|
|
32
|
+
window.removeEventListener("keydown", onKeyDown);
|
|
33
|
+
};
|
|
34
|
+
});
|
|
35
|
+
const image = props.images.at(props.imageIndex);
|
|
36
|
+
const imageSrc = image === null || image === void 0 ? void 0 : image.src;
|
|
37
|
+
const imageCustomContent = image === null || image === void 0 ? void 0 : image.customContent;
|
|
38
|
+
const swipableHandlers = (0, use_swipeable_1.useSwipeable)({
|
|
39
|
+
onSwipedLeft: () => props.onNext(),
|
|
40
|
+
onSwipedRight: () => props.onPrev(),
|
|
41
|
+
swipeDuration: 500,
|
|
42
|
+
});
|
|
43
|
+
return {
|
|
44
|
+
floatingContext: context,
|
|
45
|
+
getFloatingProps,
|
|
46
|
+
imageCustomContent,
|
|
47
|
+
imageSrc,
|
|
48
|
+
setFloating: refs.setFloating,
|
|
49
|
+
swipableHandlers,
|
|
50
|
+
};
|
|
51
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { LightboxImageProps } from "./types";
|
|
2
|
+
type ContextType = {
|
|
3
|
+
registerImage: (props: LightboxImageProps) => void;
|
|
4
|
+
unregisterImage: (props: LightboxImageProps) => void;
|
|
5
|
+
openLightbox: (props: LightboxImageProps) => void;
|
|
6
|
+
images: LightboxImageProps[];
|
|
7
|
+
currentImageIndex: number | null;
|
|
8
|
+
};
|
|
9
|
+
export declare const LightboxProvider: import("react").Provider<ContextType>;
|
|
10
|
+
export declare const useLightboxContext: () => ContextType;
|
|
11
|
+
export {};
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.useLightboxContext = exports.LightboxProvider = void 0;
|
|
5
|
+
const empty_array_1 = require("@uxf/core/constants/empty-array");
|
|
6
|
+
const noop_1 = require("@uxf/core/utils/noop");
|
|
7
|
+
const react_1 = require("react");
|
|
8
|
+
const LightboxContext = (0, react_1.createContext)({
|
|
9
|
+
registerImage: noop_1.noop,
|
|
10
|
+
unregisterImage: noop_1.noop,
|
|
11
|
+
openLightbox: noop_1.noop,
|
|
12
|
+
images: empty_array_1.EMPTY_ARRAY,
|
|
13
|
+
currentImageIndex: null,
|
|
14
|
+
});
|
|
15
|
+
exports.LightboxProvider = LightboxContext.Provider;
|
|
16
|
+
const useLightboxContext = () => (0, react_1.useContext)(LightboxContext);
|
|
17
|
+
exports.useLightboxContext = useLightboxContext;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.useLightboxImage = exports.useLightbox = exports.Lightbox = void 0;
|
|
4
|
+
var lightbox_1 = require("./lightbox");
|
|
5
|
+
Object.defineProperty(exports, "Lightbox", { enumerable: true, get: function () { return lightbox_1.Lightbox; } });
|
|
6
|
+
var use_lightbox_1 = require("./use-lightbox");
|
|
7
|
+
Object.defineProperty(exports, "useLightbox", { enumerable: true, get: function () { return use_lightbox_1.useLightbox; } });
|
|
8
|
+
var use_lightbox_image_1 = require("./use-lightbox-image");
|
|
9
|
+
Object.defineProperty(exports, "useLightboxImage", { enumerable: true, get: function () { return use_lightbox_image_1.useLightboxImage; } });
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import React, { type FC, ReactNode } from "react";
|
|
2
|
+
import { type LightboxButtonProps, type LightboxCustomDialogProps } from "./types";
|
|
3
|
+
export interface LightboxProps {
|
|
4
|
+
CloseButtonElement?: FC<LightboxButtonProps>;
|
|
5
|
+
DialogElement?: FC<LightboxCustomDialogProps>;
|
|
6
|
+
NextButtonElement?: FC<LightboxButtonProps>;
|
|
7
|
+
PrevButtonElement?: FC<LightboxButtonProps>;
|
|
8
|
+
children: ReactNode;
|
|
9
|
+
isBackdropCloseDisabled?: boolean;
|
|
10
|
+
}
|
|
11
|
+
export declare function Lightbox(props: LightboxProps): React.JSX.Element;
|
|
12
|
+
export declare namespace Lightbox {
|
|
13
|
+
var displayName: string;
|
|
14
|
+
}
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
4
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
5
|
+
};
|
|
6
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
7
|
+
exports.Lightbox = Lightbox;
|
|
8
|
+
const is_not_nil_1 = require("@uxf/core/utils/is-not-nil");
|
|
9
|
+
const react_1 = __importDefault(require("react"));
|
|
10
|
+
const lightbox_dialog_1 = require("./components/lightbox-dialog");
|
|
11
|
+
const context_1 = require("./context");
|
|
12
|
+
const use_lightbox_1 = require("./use-lightbox");
|
|
13
|
+
function Lightbox(props) {
|
|
14
|
+
const { images, unregisterImage, openLightbox, imageIndex, registerImage, onNextImage, onPrevImage, onClose } = (0, use_lightbox_1.useLightbox)();
|
|
15
|
+
const contextValue = {
|
|
16
|
+
registerImage,
|
|
17
|
+
unregisterImage,
|
|
18
|
+
openLightbox,
|
|
19
|
+
images,
|
|
20
|
+
currentImageIndex: imageIndex,
|
|
21
|
+
};
|
|
22
|
+
return (react_1.default.createElement(context_1.LightboxProvider, { value: contextValue },
|
|
23
|
+
props.children,
|
|
24
|
+
(0, is_not_nil_1.isNotNil)(imageIndex) &&
|
|
25
|
+
((0, is_not_nil_1.isNotNil)(props.DialogElement) ? (react_1.default.createElement(props.DialogElement, { imageIndex: imageIndex, images: images, onClose: onClose, onNext: onNextImage, onPrev: onPrevImage })) : (react_1.default.createElement(lightbox_dialog_1.LightboxDialog, { CloseButtonElement: props.CloseButtonElement, NextButtonElement: props.NextButtonElement, PrevButtonElement: props.PrevButtonElement, imageIndex: imageIndex, images: images, isBackdropCloseDisabled: props.isBackdropCloseDisabled, onClose: onClose, onNext: onNextImage, onPrev: onPrevImage })))));
|
|
26
|
+
}
|
|
27
|
+
Lightbox.displayName = "UxfUiLightbox";
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
const react_1 = __importDefault(require("react"));
|
|
7
|
+
const snap_test_1 = require("../utils/snap-test");
|
|
8
|
+
const lightbox_stories_1 = require("./lightbox.stories");
|
|
9
|
+
(0, snap_test_1.snapTest)("render stories", react_1.default.createElement(lightbox_stories_1.Default, null));
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
+
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
+
};
|
|
5
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
+
exports.Default = Default;
|
|
7
|
+
const image_1 = require("@uxf/core/utils/image");
|
|
8
|
+
const react_1 = __importDefault(require("react"));
|
|
9
|
+
const raster_image_1 = require("../raster-image");
|
|
10
|
+
const index_1 = require("./index");
|
|
11
|
+
const IMAGES = [
|
|
12
|
+
{
|
|
13
|
+
src: "/sample-images/sample-1.jpeg",
|
|
14
|
+
title: "Obr. 1",
|
|
15
|
+
customContent: "hello world 1",
|
|
16
|
+
width: 500,
|
|
17
|
+
},
|
|
18
|
+
{
|
|
19
|
+
src: "/sample-images/sample-2.jpg",
|
|
20
|
+
title: "Obr. 2",
|
|
21
|
+
customContent: "hello world 2",
|
|
22
|
+
width: 500,
|
|
23
|
+
},
|
|
24
|
+
{
|
|
25
|
+
src: "/sample-images/sample-3.jpg",
|
|
26
|
+
title: "Obr. 3",
|
|
27
|
+
customContent: "hello world 3",
|
|
28
|
+
width: 500,
|
|
29
|
+
},
|
|
30
|
+
];
|
|
31
|
+
function Image(props) {
|
|
32
|
+
const openLightbox = (0, index_1.useLightboxImage)({
|
|
33
|
+
src: props.src,
|
|
34
|
+
title: props.title,
|
|
35
|
+
customContent: props.customContent,
|
|
36
|
+
});
|
|
37
|
+
return (react_1.default.createElement("button", { onClick: openLightbox },
|
|
38
|
+
react_1.default.createElement(raster_image_1.RasterImage, { alt: "", className: "size-56 cursor-pointer object-cover transition-transform hover:scale-105", src: props.src, width: props.width })));
|
|
39
|
+
}
|
|
40
|
+
function Default() {
|
|
41
|
+
return (react_1.default.createElement(index_1.Lightbox, null,
|
|
42
|
+
react_1.default.createElement("div", { className: "flex-direction flex gap-2" }, IMAGES.map((image) => (react_1.default.createElement(Image, { customContent: image.customContent, key: (0, image_1.getImgUniqueIdentifier)(image.src), src: image.src, title: image.title, width: image.width }))))));
|
|
43
|
+
}
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
readonly "uxf-ui-lightbox": {
|
|
3
|
+
readonly next: {
|
|
4
|
+
readonly cs: "Další";
|
|
5
|
+
readonly en: "Next";
|
|
6
|
+
readonly sk: "Ďalší";
|
|
7
|
+
readonly de: "Weiter";
|
|
8
|
+
};
|
|
9
|
+
readonly close: {
|
|
10
|
+
readonly cs: "Zavřít";
|
|
11
|
+
readonly en: "Close";
|
|
12
|
+
readonly sk: "Zatvoriť";
|
|
13
|
+
readonly de: "Schließen";
|
|
14
|
+
};
|
|
15
|
+
readonly previous: {
|
|
16
|
+
readonly cs: "Předchozí";
|
|
17
|
+
readonly en: "Previous";
|
|
18
|
+
readonly sk: "Predchádzajúci";
|
|
19
|
+
readonly de: "Zurück";
|
|
20
|
+
};
|
|
21
|
+
};
|
|
22
|
+
};
|
|
23
|
+
export default _default;
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.default = {
|
|
4
|
+
"uxf-ui-lightbox": {
|
|
5
|
+
next: {
|
|
6
|
+
cs: "Další",
|
|
7
|
+
en: "Next",
|
|
8
|
+
sk: "Ďalší",
|
|
9
|
+
de: "Weiter",
|
|
10
|
+
},
|
|
11
|
+
close: {
|
|
12
|
+
cs: "Zavřít",
|
|
13
|
+
en: "Close",
|
|
14
|
+
sk: "Zatvoriť",
|
|
15
|
+
de: "Schließen",
|
|
16
|
+
},
|
|
17
|
+
previous: {
|
|
18
|
+
cs: "Předchozí",
|
|
19
|
+
en: "Previous",
|
|
20
|
+
sk: "Predchádzajúci",
|
|
21
|
+
de: "Zurück",
|
|
22
|
+
},
|
|
23
|
+
},
|
|
24
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
import type { Noop } from "@uxf/core/types";
|
|
2
|
+
import { ImageSource } from "@uxf/core/utils/resizer";
|
|
3
|
+
import { type MouseEventHandler, ReactNode } from "react";
|
|
4
|
+
export interface LightboxImageProps {
|
|
5
|
+
alt?: string;
|
|
6
|
+
className?: string;
|
|
7
|
+
customContent?: ReactNode;
|
|
8
|
+
src: ImageSource;
|
|
9
|
+
title?: string;
|
|
10
|
+
}
|
|
11
|
+
export interface LightboxButtonProps {
|
|
12
|
+
onClick: MouseEventHandler;
|
|
13
|
+
}
|
|
14
|
+
export interface LightboxCustomDialogProps {
|
|
15
|
+
imageIndex: number;
|
|
16
|
+
images: LightboxImageProps[];
|
|
17
|
+
onClose: Noop;
|
|
18
|
+
onNext: Noop;
|
|
19
|
+
onPrev: Noop;
|
|
20
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.useLightboxImage = useLightboxImage;
|
|
5
|
+
const use_on_mount_1 = require("@uxf/core-react/hooks/use-on-mount");
|
|
6
|
+
const react_1 = require("react");
|
|
7
|
+
const context_1 = require("./context");
|
|
8
|
+
function useLightboxImage(props) {
|
|
9
|
+
const { registerImage, unregisterImage, openLightbox } = (0, context_1.useLightboxContext)();
|
|
10
|
+
(0, use_on_mount_1.useOnMount)(() => {
|
|
11
|
+
registerImage(props);
|
|
12
|
+
return () => {
|
|
13
|
+
unregisterImage(props);
|
|
14
|
+
};
|
|
15
|
+
});
|
|
16
|
+
return (0, react_1.useCallback)(() => openLightbox(props), [props, openLightbox]);
|
|
17
|
+
}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { LightboxImageProps } from "./types";
|
|
2
|
+
export declare function useLightbox(): {
|
|
3
|
+
onPrevImage: () => void;
|
|
4
|
+
onNextImage: () => void;
|
|
5
|
+
onClose: () => void;
|
|
6
|
+
registerImage: (image: LightboxImageProps) => void;
|
|
7
|
+
unregisterImage: (image: LightboxImageProps) => void;
|
|
8
|
+
openLightbox: (image: LightboxImageProps) => void;
|
|
9
|
+
images: LightboxImageProps[];
|
|
10
|
+
imageIndex: number | null;
|
|
11
|
+
};
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
"use client";
|
|
3
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
4
|
+
exports.useLightbox = useLightbox;
|
|
5
|
+
const empty_array_1 = require("@uxf/core/constants/empty-array");
|
|
6
|
+
const image_1 = require("@uxf/core/utils/image");
|
|
7
|
+
const react_1 = require("react");
|
|
8
|
+
function getModuloIndex(index, length) {
|
|
9
|
+
return index < 0 ? ((index % length) + length) % length : index % length;
|
|
10
|
+
}
|
|
11
|
+
function useLightbox() {
|
|
12
|
+
const [images, setImages] = (0, react_1.useState)(empty_array_1.EMPTY_ARRAY);
|
|
13
|
+
const [imageIndex, setImageIndex] = (0, react_1.useState)(null);
|
|
14
|
+
const registerImageHandler = (0, react_1.useCallback)((image) => setImages((v) => [...v, image]), []);
|
|
15
|
+
const unregisterImageHandler = (0, react_1.useCallback)((image) => setImages((v) => v.filter((u) => (0, image_1.getImgUniqueIdentifier)(u.src) !== (0, image_1.getImgUniqueIdentifier)(image.src))), []);
|
|
16
|
+
const openLightboxHandler = (0, react_1.useCallback)((image) => setImageIndex(images.findIndex((i) => (0, image_1.getImgUniqueIdentifier)(i.src) === (0, image_1.getImgUniqueIdentifier)(image.src))), [images]);
|
|
17
|
+
const showPrevImageHandler = (0, react_1.useCallback)(() => {
|
|
18
|
+
setImageIndex((v) => (v === null ? null : getModuloIndex(v - 1, images.length)));
|
|
19
|
+
}, [images.length]);
|
|
20
|
+
const showNextImageHandler = (0, react_1.useCallback)(() => {
|
|
21
|
+
setImageIndex((v) => (v === null ? null : getModuloIndex(v + 1, images.length)));
|
|
22
|
+
}, [images.length]);
|
|
23
|
+
const closeHandler = (0, react_1.useCallback)(() => setImageIndex(null), []);
|
|
24
|
+
return {
|
|
25
|
+
onPrevImage: showPrevImageHandler,
|
|
26
|
+
onNextImage: showNextImageHandler,
|
|
27
|
+
onClose: closeHandler,
|
|
28
|
+
registerImage: registerImageHandler,
|
|
29
|
+
unregisterImage: unregisterImageHandler,
|
|
30
|
+
openLightbox: openLightboxHandler,
|
|
31
|
+
images,
|
|
32
|
+
imageIndex,
|
|
33
|
+
};
|
|
34
|
+
}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { UseAnchorProps } from "@uxf/core-react/clickable/use-anchor-props";
|
|
2
|
+
import React, { AnchorHTMLAttributes, ReactNode } from "react";
|
|
3
|
+
import { IconName } from "../icon/types";
|
|
4
|
+
import { NextLink } from "../utils/next-link";
|
|
5
|
+
export interface ListItemProps extends Omit<AnchorHTMLAttributes<HTMLAnchorElement>, "type">, UseAnchorProps {
|
|
6
|
+
as?: NextLink | "a";
|
|
7
|
+
endIcon?: IconName;
|
|
8
|
+
endElement?: ReactNode;
|
|
9
|
+
}
|
|
10
|
+
export declare const ListItem: React.ForwardRefExoticComponent<ListItemProps & React.RefAttributes<HTMLAnchorElement>>;
|