@pathscale/ui 1.2.5 → 1.2.7
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/LICENSE +22 -22
- package/README.md +59 -59
- package/dist/components/_shared/index.js +2 -3
- package/dist/components/_shared/overlayPosition.js +5 -5
- package/dist/components/accordion/Accordion.css +158 -158
- package/dist/components/accordion/Accordion.js +44 -44
- package/dist/components/accordion/index.js +2 -9
- package/dist/components/alert/Alert.css +116 -116
- package/dist/components/alert/Alert.js +30 -30
- package/dist/components/alert/index.js +2 -8
- package/dist/components/auth-card/AuthCard.js +20 -20
- package/dist/components/auth-card/index.js +2 -3
- package/dist/components/auth-error-message/AuthErrorMessage.js +12 -12
- package/dist/components/auth-error-message/index.js +2 -3
- package/dist/components/auth-field-group/AuthFieldGroup.js +11 -11
- package/dist/components/auth-field-group/index.js +2 -3
- package/dist/components/auth-footer-links/AuthFooterLinks.js +20 -20
- package/dist/components/auth-footer-links/index.js +2 -3
- package/dist/components/auth-form/AuthForm.js +11 -11
- package/dist/components/auth-form/index.js +2 -3
- package/dist/components/auth-powered-by/AuthPoweredBy.js +15 -26
- package/dist/components/auth-powered-by/index.js +2 -3
- package/dist/components/auth-submit-button/AuthSubmitButton.js +10 -10
- package/dist/components/auth-submit-button/index.js +2 -3
- package/dist/components/auth-success-message/AuthSuccessMessage.js +9 -9
- package/dist/components/auth-success-message/index.js +2 -3
- package/dist/components/avatar/Avatar.css +124 -124
- package/dist/components/avatar/Avatar.js +27 -27
- package/dist/components/avatar/AvatarGroup.js +11 -11
- package/dist/components/avatar/index.js +2 -6
- package/dist/components/badge/Badge.css +164 -164
- package/dist/components/badge/Badge.js +19 -19
- package/dist/components/badge/index.js +6 -9
- package/dist/components/breadcrumbs/Breadcrumbs.css +63 -63
- package/dist/components/breadcrumbs/Breadcrumbs.js +25 -25
- package/dist/components/breadcrumbs/index.js +2 -5
- package/dist/components/button/Button.css +194 -194
- package/dist/components/button/Button.js +22 -22
- package/dist/components/button/index.js +2 -3
- package/dist/components/button-group/ButtonGroup.css +117 -117
- package/dist/components/button-group/ButtonGroup.js +14 -14
- package/dist/components/button-group/context.js +2 -2
- package/dist/components/button-group/index.js +2 -6
- package/dist/components/calendar/Calendar.css +258 -258
- package/dist/components/calendar/Calendar.js +85 -85
- package/dist/components/calendar/index.js +2 -3
- package/dist/components/card/Card.css +110 -110
- package/dist/components/card/Card.js +21 -21
- package/dist/components/card/index.js +2 -8
- package/dist/components/chatbubble/ChatBubble.css +164 -164
- package/dist/components/chatbubble/ChatBubble.js +19 -19
- package/dist/components/chatbubble/ChatBubbleAvatar.js +8 -8
- package/dist/components/chatbubble/ChatBubbleFooter.js +11 -11
- package/dist/components/chatbubble/ChatBubbleHeader.js +8 -8
- package/dist/components/chatbubble/ChatBubbleMessage.js +12 -12
- package/dist/components/chatbubble/ChatBubbleTime.js +11 -11
- package/dist/components/chatbubble/index.js +2 -3
- package/dist/components/checkbox/Checkbox.css +183 -183
- package/dist/components/checkbox/Checkbox.js +29 -29
- package/dist/components/checkbox/index.js +2 -3
- package/dist/components/checkbox-group/CheckboxGroup.css +10 -10
- package/dist/components/checkbox-group/CheckboxGroup.js +16 -16
- package/dist/components/checkbox-group/context.js +2 -2
- package/dist/components/checkbox-group/index.js +3 -4
- package/dist/components/chip/Chip.css +197 -197
- package/dist/components/chip/Chip.js +32 -32
- package/dist/components/chip/index.js +5 -7
- package/dist/components/close-button/CloseButton.css +81 -81
- package/dist/components/close-button/CloseButton.js +22 -22
- package/dist/components/close-button/index.js +2 -3
- package/dist/components/color-area/ColorArea.css +54 -54
- package/dist/components/color-area/ColorArea.js +13 -13
- package/dist/components/color-area/index.js +2 -2
- package/dist/components/color-field/ColorField.css +88 -88
- package/dist/components/color-field/ColorField.js +23 -23
- package/dist/components/color-field/index.js +2 -2
- package/dist/components/color-picker/ColorPicker.css +28 -28
- package/dist/components/color-picker/ColorPicker.js +44 -44
- package/dist/components/color-picker/index.js +2 -8
- package/dist/components/color-slider/ColorSlider.css +57 -57
- package/dist/components/color-slider/ColorSlider.js +21 -21
- package/dist/components/color-slider/index.js +2 -2
- package/dist/components/color-swatch/ColorSwatch.css +84 -84
- package/dist/components/color-swatch/ColorSwatch.js +14 -14
- package/dist/components/color-swatch/index.js +2 -2
- package/dist/components/color-swatch-picker/ColorSwatchPicker.css +12 -12
- package/dist/components/color-swatch-picker/ColorSwatchPicker.js +14 -14
- package/dist/components/color-swatch-picker/index.js +2 -5
- package/dist/components/color-wheel-flower/ColorWheelFlower.css +147 -147
- package/dist/components/color-wheel-flower/ColorWheelFlower.js +83 -83
- package/dist/components/color-wheel-flower/colorWheelFlowerContext.js +3 -3
- package/dist/components/color-wheel-flower/index.js +3 -6
- package/dist/components/combo-box/ComboBox.css +344 -344
- package/dist/components/combo-box/ComboBox.js +90 -90
- package/dist/components/combo-box/index.js +2 -10
- package/dist/components/date-field/DateField.css +215 -215
- package/dist/components/date-field/DateField.js +41 -41
- package/dist/components/date-field/index.js +2 -11
- package/dist/components/date-picker/DatePicker.css +143 -143
- package/dist/components/date-picker/DatePicker.js +40 -40
- package/dist/components/date-picker/index.js +2 -3
- package/dist/components/date-range-picker/DateRangePicker.css +149 -149
- package/dist/components/date-range-picker/DateRangePicker.js +55 -55
- package/dist/components/date-range-picker/index.js +2 -3
- package/dist/components/description/Description.css +10 -10
- package/dist/components/description/Description.js +9 -9
- package/dist/components/description/index.js +2 -5
- package/dist/components/disclosure/Disclosure.css +84 -84
- package/dist/components/disclosure/Disclosure.js +40 -40
- package/dist/components/disclosure/index.js +3 -9
- package/dist/components/disclosure-group/DisclosureGroup.css +9 -9
- package/dist/components/disclosure-group/DisclosureGroup.js +13 -13
- package/dist/components/disclosure-group/index.js +4 -6
- package/dist/components/disclosure-group/useDisclosureGroupNavigation.js +4 -4
- package/dist/components/drawer/Drawer.context.js +3 -3
- package/dist/components/drawer/Drawer.css +463 -463
- package/dist/components/drawer/Drawer.js +107 -107
- package/dist/components/drawer/index.js +2 -15
- package/dist/components/dropdown/Dropdown.css +211 -211
- package/dist/components/dropdown/Dropdown.js +66 -66
- package/dist/components/dropdown/index.js +2 -4
- package/dist/components/empty-state/EmptyState.css +39 -39
- package/dist/components/empty-state/EmptyState.js +25 -25
- package/dist/components/empty-state/index.js +2 -8
- package/dist/components/error-message/ErrorMessage.css +20 -20
- package/dist/components/error-message/ErrorMessage.js +12 -12
- package/dist/components/error-message/index.js +2 -5
- package/dist/components/field-error/FieldError.css +27 -27
- package/dist/components/field-error/FieldError.js +14 -14
- package/dist/components/field-error/index.js +2 -5
- package/dist/components/fieldset/Fieldset.css +30 -30
- package/dist/components/fieldset/Fieldset.js +21 -21
- package/dist/components/fieldset/index.js +2 -8
- package/dist/components/flex/Flex.css +5 -5
- package/dist/components/flex/Flex.js +14 -14
- package/dist/components/flex/index.js +2 -3
- package/dist/components/floating-dock/FloatingDock.css +208 -208
- package/dist/components/floating-dock/FloatingDock.js +76 -76
- package/dist/components/floating-dock/index.js +2 -3
- package/dist/components/footer/Footer.js +11 -11
- package/dist/components/footer/FooterTitle.js +9 -9
- package/dist/components/footer/footer.css +51 -51
- package/dist/components/footer/index.js +2 -3
- package/dist/components/form/FieldErrorMessage.js +8 -8
- package/dist/components/form/Form.css +5 -5
- package/dist/components/form/Form.js +21 -21
- package/dist/components/form/FormField.js +19 -19
- package/dist/components/form/FormSubmitButton.js +11 -11
- package/dist/components/form/index.js +5 -12
- package/dist/components/glass-panel/GlassPanel.css +359 -359
- package/dist/components/glass-panel/GlassPanel.js +29 -29
- package/dist/components/glass-panel/index.js +2 -3
- package/dist/components/glow-card/GlowCard.css +100 -100
- package/dist/components/glow-card/GlowCard.js +10 -10
- package/dist/components/glow-card/index.js +2 -3
- package/dist/components/grid/Grid.css +5 -5
- package/dist/components/grid/Grid.js +15 -15
- package/dist/components/grid/index.js +2 -3
- package/dist/components/header/Header.css +13 -13
- package/dist/components/header/Header.js +12 -12
- package/dist/components/header/index.js +2 -5
- package/dist/components/icon/Icon.css +10 -10
- package/dist/components/icon/Icon.js +8 -8
- package/dist/components/icon/index.js +2 -3
- package/dist/components/immersive-landing/ImmersiveLanding.css +565 -565
- package/dist/components/immersive-landing/ImmersiveLanding.js +44 -44
- package/dist/components/immersive-landing/ImmersiveLandingArrows.js +17 -17
- package/dist/components/immersive-landing/ImmersiveLandingContext.js +3 -3
- package/dist/components/immersive-landing/ImmersiveLandingNavigation.js +36 -36
- package/dist/components/immersive-landing/ImmersiveLandingPage.js +15 -15
- package/dist/components/immersive-landing/components/CookieConsent.js +71 -71
- package/dist/components/immersive-landing/components/FirefoxPWABanner.js +42 -42
- package/dist/components/immersive-landing/components/PWAInstallPrompt.js +40 -40
- package/dist/components/immersive-landing/index.js +7 -14
- package/dist/components/immersive-landing/useImmersiveLanding.js +7 -7
- package/dist/components/input/Input.css +155 -155
- package/dist/components/input/Input.js +48 -48
- package/dist/components/input/index.js +2 -2
- package/dist/components/input-group/InputGroup.css +172 -172
- package/dist/components/input-group/InputGroup.js +33 -33
- package/dist/components/input-group/index.js +2 -9
- package/dist/components/input-otp/InputOTP.css +170 -170
- package/dist/components/input-otp/InputOTP.js +48 -48
- package/dist/components/input-otp/index.js +2 -11
- package/dist/components/join/Join.js +14 -14
- package/dist/components/join/index.js +2 -3
- package/dist/components/kbd/Kbd.css +60 -60
- package/dist/components/kbd/Kbd.js +20 -20
- package/dist/components/kbd/index.js +2 -8
- package/dist/components/label/Label.css +30 -30
- package/dist/components/label/Label.js +9 -9
- package/dist/components/label/index.js +2 -5
- package/dist/components/language-switcher/LanguageSwitcher.css +56 -56
- package/dist/components/language-switcher/LanguageSwitcher.js +26 -26
- package/dist/components/language-switcher/createI18n.js +8 -8
- package/dist/components/language-switcher/index.js +3 -8
- package/dist/components/link/Link.css +131 -131
- package/dist/components/link/Link.js +22 -22
- package/dist/components/link/index.js +2 -5
- package/dist/components/list-box/ListBox.css +148 -148
- package/dist/components/list-box/ListBox.js +17 -17
- package/dist/components/list-box/ListBoxItem.js +32 -32
- package/dist/components/list-box/ListBoxSection.js +13 -13
- package/dist/components/list-box/context.js +2 -2
- package/dist/components/list-box/index.js +9 -15
- package/dist/components/live-chat/LiveChat.css +324 -324
- package/dist/components/live-chat/LiveChatBubble.js +27 -27
- package/dist/components/live-chat/LiveChatPanel.js +62 -62
- package/dist/components/live-chat/index.js +3 -5
- package/dist/components/menu/Menu.css +199 -199
- package/dist/components/menu/Menu.js +25 -30
- package/dist/components/menu/MenuItem.js +38 -38
- package/dist/components/menu/MenuSection.js +13 -13
- package/dist/components/menu/context.js +2 -2
- package/dist/components/menu/index.js +3 -12
- package/dist/components/meter/Meter.css +89 -89
- package/dist/components/meter/Meter.js +31 -31
- package/dist/components/meter/index.js +2 -8
- package/dist/components/modal/Modal.css +320 -320
- package/dist/components/modal/Modal.js +80 -80
- package/dist/components/modal/index.js +2 -13
- package/dist/components/navbar/Navbar.css +110 -110
- package/dist/components/navbar/Navbar.js +18 -18
- package/dist/components/navbar/NavbarRow.js +10 -10
- package/dist/components/navbar/NavbarSection.js +9 -9
- package/dist/components/navbar/NavbarStack.js +10 -10
- package/dist/components/navbar/index.js +2 -3
- package/dist/components/noise-background/NoiseBackground.css +66 -66
- package/dist/components/noise-background/NoiseBackground.js +35 -35
- package/dist/components/noise-background/index.js +2 -3
- package/dist/components/number-field/NumberField.css +198 -198
- package/dist/components/number-field/NumberField.js +42 -42
- package/dist/components/number-field/index.js +2 -9
- package/dist/components/pagination/Pagination.css +121 -121
- package/dist/components/pagination/Pagination.js +34 -34
- package/dist/components/pagination/index.js +2 -3
- package/dist/components/password-field/PasswordField.js +15 -15
- package/dist/components/password-field/index.js +2 -3
- package/dist/components/password-requirements/PasswordRequirements.js +24 -24
- package/dist/components/password-requirements/index.js +2 -3
- package/dist/components/password-rules/index.js +2 -4
- package/dist/components/popover/Popover.css +117 -117
- package/dist/components/popover/Popover.js +50 -50
- package/dist/components/popover/index.js +3 -9
- package/dist/components/progress-bar/ProgressBar.css +104 -104
- package/dist/components/progress-bar/ProgressBar.js +27 -27
- package/dist/components/progress-bar/index.js +2 -3
- package/dist/components/progress-circle/ProgressCircle.css +82 -82
- package/dist/components/progress-circle/ProgressCircle.js +32 -32
- package/dist/components/progress-circle/index.js +2 -3
- package/dist/components/radio/Radio.css +129 -129
- package/dist/components/radio/Radio.js +27 -27
- package/dist/components/radio/index.js +2 -3
- package/dist/components/radio-group/RadioGroup.css +58 -58
- package/dist/components/radio-group/RadioGroup.js +33 -33
- package/dist/components/radio-group/context.js +2 -2
- package/dist/components/radio-group/index.js +3 -4
- package/dist/components/range-calendar/RangeCalendar.css +51 -51
- package/dist/components/range-calendar/RangeCalendar.js +15 -15
- package/dist/components/range-calendar/index.js +2 -3
- package/dist/components/scroll-shadow/ScrollShadow.css +93 -93
- package/dist/components/scroll-shadow/ScrollShadow.js +19 -19
- package/dist/components/scroll-shadow/index.js +2 -3
- package/dist/components/scroll-shadow/useScrollShadow.js +3 -3
- package/dist/components/search-field/SearchField.css +183 -183
- package/dist/components/search-field/SearchField.js +38 -38
- package/dist/components/search-field/index.js +2 -9
- package/dist/components/select/Select.css +284 -284
- package/dist/components/select/Select.js +129 -129
- package/dist/components/select/index.js +2 -3
- package/dist/components/separator/Separator.css +35 -35
- package/dist/components/separator/Separator.js +11 -11
- package/dist/components/separator/index.js +2 -4
- package/dist/components/size-picker/SizePicker.js +17 -17
- package/dist/components/size-picker/index.js +3 -6
- package/dist/components/size-picker/sizeStore.js +3 -3
- package/dist/components/skeleton/Skeleton.css +95 -95
- package/dist/components/skeleton/Skeleton.js +8 -8
- package/dist/components/skeleton/index.js +2 -3
- package/dist/components/slider/Slider.css +122 -122
- package/dist/components/slider/Slider.js +26 -26
- package/dist/components/slider/index.js +2 -3
- package/dist/components/spinner/Spinner.css +131 -131
- package/dist/components/spinner/Spinner.js +19 -19
- package/dist/components/spinner/index.js +2 -5
- package/dist/components/surface/Surface.css +37 -37
- package/dist/components/surface/Surface.js +9 -9
- package/dist/components/surface/index.js +2 -4
- package/dist/components/table/ExpandToggle.js +14 -14
- package/dist/components/table/InlineConfirm.js +11 -11
- package/dist/components/table/MobileListView.js +24 -24
- package/dist/components/table/SortIcon.js +13 -13
- package/dist/components/table/Table.css +426 -426
- package/dist/components/table/Table.js +80 -80
- package/dist/components/table/VirtualSpacerRow.js +8 -8
- package/dist/components/table/index.js +8 -38
- package/dist/components/tabs/Tabs.css +203 -203
- package/dist/components/tabs/Tabs.js +59 -59
- package/dist/components/tabs/index.js +2 -4
- package/dist/components/tag/Tag.css +121 -121
- package/dist/components/tag/Tag.js +40 -40
- package/dist/components/tag/index.js +2 -6
- package/dist/components/tag-group/TagGroup.css +22 -22
- package/dist/components/tag-group/TagGroup.js +20 -20
- package/dist/components/tag-group/context.js +2 -2
- package/dist/components/tag-group/index.js +2 -6
- package/dist/components/text/Text.css +66 -66
- package/dist/components/text/Text.js +9 -9
- package/dist/components/text/index.js +2 -5
- package/dist/components/text-area/TextArea.css +95 -95
- package/dist/components/text-area/TextArea.js +10 -10
- package/dist/components/text-area/index.js +2 -5
- package/dist/components/text-field/TextField.css +33 -33
- package/dist/components/text-field/TextField.js +15 -15
- package/dist/components/text-field/index.js +2 -7
- package/dist/components/textarea/Textarea.js +11 -13
- package/dist/components/textarea/index.js +2 -6
- package/dist/components/theme-color-picker/ThemeColorPicker.js +49 -49
- package/dist/components/theme-color-picker/hueShift.js +3 -3
- package/dist/components/theme-color-picker/index.js +3 -7
- package/dist/components/time-field/TimeField.css +215 -215
- package/dist/components/time-field/TimeField.js +41 -41
- package/dist/components/time-field/index.js +2 -11
- package/dist/components/toast/Toast.css +344 -344
- package/dist/components/toast/Toast.js +98 -98
- package/dist/components/toast/index.js +2 -19
- package/dist/components/toggle/Toggle.css +237 -237
- package/dist/components/toggle/Toggle.js +31 -31
- package/dist/components/toggle/index.js +2 -3
- package/dist/components/toolbar/Toolbar.css +55 -55
- package/dist/components/toolbar/Toolbar.js +10 -10
- package/dist/components/toolbar/index.js +2 -5
- package/dist/components/tooltip/Tooltip.css +153 -153
- package/dist/components/tooltip/Tooltip.js +36 -36
- package/dist/components/tooltip/index.js +2 -7
- package/dist/components/utils.js +6 -7
- package/dist/components/video-preview/VideoPreview.js +15 -15
- package/dist/components/video-preview/index.js +2 -3
- package/dist/hooks/date/useCalendarNavigation.js +18 -18
- package/dist/hooks/date/useCalendarState.js +19 -19
- package/dist/hooks/date/useDateSelection.js +7 -7
- package/dist/hooks/date/usePickerOpenState.js +8 -8
- package/dist/hooks/date/useRangeSelection.js +16 -16
- package/dist/hooks/form/FormContext.js +3 -3
- package/dist/hooks/form/createForm.js +4 -4
- package/dist/hooks/form/index.js +5 -10
- package/dist/hooks/form/useFieldNew.js +10 -10
- package/dist/hooks/layout/index.js +2 -3
- package/dist/hooks/layout/useDesktop.js +4 -4
- package/dist/hooks/table/index.js +9 -18
- package/dist/hooks/table/useAnchoredOverlayPosition.js +4 -4
- package/dist/hooks/table/useTableExpansion.js +4 -4
- package/dist/hooks/table/useTableFiltering.js +8 -8
- package/dist/hooks/table/useTableModel.js +10 -10
- package/dist/hooks/table/useTablePagination.js +4 -4
- package/dist/hooks/table/useTableSelection.js +4 -4
- package/dist/hooks/table/useTableSorting.js +6 -6
- package/dist/index.css +74 -74
- package/dist/index.js +108 -398
- package/dist/lib/refs/index.js +2 -3
- package/dist/lib/refs/mergeRefs.js +2 -2
- package/dist/lib/style/index.js +2 -4
- package/dist/lib/tag/createIsButton.js +4 -4
- package/dist/lib/tag/createTagName.js +2 -2
- package/dist/lib/tag/index.js +3 -7
- package/dist/motion/engine.js +4 -4
- package/dist/motion/index.js +11 -39
- package/dist/motion/popmotion.js +2 -2
- package/dist/motion/presets.js +4 -4
- package/dist/motion/route.js +7 -7
- package/dist/motion/solid/AnimatedCollapse.js +27 -27
- package/dist/motion/solid/MotionDiv.js +13 -13
- package/dist/motion/solid/Presence.js +9 -9
- package/dist/motion/solid/index.js +4 -10
- package/dist/motion/system.js +9 -9
- package/dist/primitives/streaming/index.js +3 -5
- package/dist/primitives/streaming/useStreamingBuffer.js +2 -2
- package/dist/primitives/streaming/useStreamingSubscription.js +7 -7
- package/dist/primitives/virtualizer/index.js +2 -3
- package/dist/primitives/virtualizer/useVirtualRows.js +7 -7
- package/dist/purge-manifest.json +15599 -15825
- package/dist/styles/base/index.css +43 -43
- package/dist/styles/themes/dark.css +141 -141
- package/dist/styles/themes/light.css +143 -143
- package/package.json +41 -34
package/LICENSE
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2025 pathscale
|
|
4
|
-
Copyright (c) 2020 Pouya Saadeghi
|
|
5
|
-
|
|
6
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
7
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
8
|
-
in the Software without restriction, including without limitation the rights
|
|
9
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
10
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
11
|
-
furnished to do so, subject to the following conditions:
|
|
12
|
-
|
|
13
|
-
The above copyright notice and this permission notice shall be included in all
|
|
14
|
-
copies or substantial portions of the Software.
|
|
15
|
-
|
|
16
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
17
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
18
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
19
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
20
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
21
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
22
|
-
SOFTWARE.
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 pathscale
|
|
4
|
+
Copyright (c) 2020 Pouya Saadeghi
|
|
5
|
+
|
|
6
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
7
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
8
|
+
in the Software without restriction, including without limitation the rights
|
|
9
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
10
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
11
|
+
furnished to do so, subject to the following conditions:
|
|
12
|
+
|
|
13
|
+
The above copyright notice and this permission notice shall be included in all
|
|
14
|
+
copies or substantial portions of the Software.
|
|
15
|
+
|
|
16
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
17
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
18
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
19
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
20
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
21
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
22
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,59 +1,59 @@
|
|
|
1
|
-
# @pathscale/ui
|
|
2
|
-
|
|
3
|
-
Highly opinionated SolidJS component library — batteries and kitchen sink
|
|
4
|
-
included, but optimized and shiny.
|
|
5
|
-
|
|
6
|
-
## Install
|
|
7
|
-
|
|
8
|
-
```sh
|
|
9
|
-
bun add @pathscale/ui
|
|
10
|
-
```
|
|
11
|
-
|
|
12
|
-
## Usage
|
|
13
|
-
|
|
14
|
-
```tsx
|
|
15
|
-
import { Button, Flex } from "@pathscale/ui";
|
|
16
|
-
|
|
17
|
-
export const Example = () => (
|
|
18
|
-
<Flex direction="col" gap="sm">
|
|
19
|
-
<Button color="primary">Primary</Button>
|
|
20
|
-
</Flex>
|
|
21
|
-
);
|
|
22
|
-
```
|
|
23
|
-
|
|
24
|
-
## CSS
|
|
25
|
-
|
|
26
|
-
Import the compatibility stylesheet to use `@pathscale/ui` components without
|
|
27
|
-
relying on app-level DaisyUI plugin styles:
|
|
28
|
-
|
|
29
|
-
```ts
|
|
30
|
-
import "@pathscale/ui/dist/styles/compat/daisy-primitives.css";
|
|
31
|
-
import "@pathscale/ui/dist/styles/icons/generated-icons.css";
|
|
32
|
-
```
|
|
33
|
-
|
|
34
|
-
## Motion
|
|
35
|
-
|
|
36
|
-
Shared animation primitives live in `@pathscale/ui/motion`. For setup,
|
|
37
|
-
Popmotion driver enablement, and migration notes, see `docs/motion.md`.
|
|
38
|
-
|
|
39
|
-
## Development
|
|
40
|
-
|
|
41
|
-
```sh
|
|
42
|
-
bun run build
|
|
43
|
-
```
|
|
44
|
-
|
|
45
|
-
Other useful scripts:
|
|
46
|
-
|
|
47
|
-
- `bun run dev`
|
|
48
|
-
- `bun run lint`
|
|
49
|
-
- `bun run format`
|
|
50
|
-
|
|
51
|
-
## Playground Hot Test
|
|
52
|
-
|
|
53
|
-
Run the playground from the repository root and hot-test local library changes without rebuilding:
|
|
54
|
-
|
|
55
|
-
```sh
|
|
56
|
-
bun run playground:dev
|
|
57
|
-
```
|
|
58
|
-
|
|
59
|
-
The playground resolves `@pathscale/ui` to local `src` via Vite aliases, so edits in `/src` and `/src/styles` refresh immediately.
|
|
1
|
+
# @pathscale/ui
|
|
2
|
+
|
|
3
|
+
Highly opinionated SolidJS component library — batteries and kitchen sink
|
|
4
|
+
included, but optimized and shiny.
|
|
5
|
+
|
|
6
|
+
## Install
|
|
7
|
+
|
|
8
|
+
```sh
|
|
9
|
+
bun add @pathscale/ui
|
|
10
|
+
```
|
|
11
|
+
|
|
12
|
+
## Usage
|
|
13
|
+
|
|
14
|
+
```tsx
|
|
15
|
+
import { Button, Flex } from "@pathscale/ui";
|
|
16
|
+
|
|
17
|
+
export const Example = () => (
|
|
18
|
+
<Flex direction="col" gap="sm">
|
|
19
|
+
<Button color="primary">Primary</Button>
|
|
20
|
+
</Flex>
|
|
21
|
+
);
|
|
22
|
+
```
|
|
23
|
+
|
|
24
|
+
## CSS
|
|
25
|
+
|
|
26
|
+
Import the compatibility stylesheet to use `@pathscale/ui` components without
|
|
27
|
+
relying on app-level DaisyUI plugin styles:
|
|
28
|
+
|
|
29
|
+
```ts
|
|
30
|
+
import "@pathscale/ui/dist/styles/compat/daisy-primitives.css";
|
|
31
|
+
import "@pathscale/ui/dist/styles/icons/generated-icons.css";
|
|
32
|
+
```
|
|
33
|
+
|
|
34
|
+
## Motion
|
|
35
|
+
|
|
36
|
+
Shared animation primitives live in `@pathscale/ui/motion`. For setup,
|
|
37
|
+
Popmotion driver enablement, and migration notes, see `docs/motion.md`.
|
|
38
|
+
|
|
39
|
+
## Development
|
|
40
|
+
|
|
41
|
+
```sh
|
|
42
|
+
bun run build
|
|
43
|
+
```
|
|
44
|
+
|
|
45
|
+
Other useful scripts:
|
|
46
|
+
|
|
47
|
+
- `bun run dev`
|
|
48
|
+
- `bun run lint`
|
|
49
|
+
- `bun run format`
|
|
50
|
+
|
|
51
|
+
## Playground Hot Test
|
|
52
|
+
|
|
53
|
+
Run the playground from the repository root and hot-test local library changes without rebuilding:
|
|
54
|
+
|
|
55
|
+
```sh
|
|
56
|
+
bun run playground:dev
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
The playground resolves `@pathscale/ui` to local `src` via Vite aliases, so edits in `/src` and `/src/styles` refresh immediately.
|
|
@@ -1,3 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
export { __webpack_exports__createOverlayPosition as createOverlayPosition };
|
|
1
|
+
import { createOverlayPosition } from "./overlayPosition.js";
|
|
2
|
+
export { createOverlayPosition };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { createEffect, createSignal, onCleanup } from "solid-js";
|
|
2
2
|
const oppositePlacement = {
|
|
3
3
|
top: "bottom",
|
|
4
4
|
bottom: "top",
|
|
@@ -31,11 +31,11 @@ const getCrossAxisCoordinate = (align, triggerStart, triggerSize, overlaySize)=>
|
|
|
31
31
|
};
|
|
32
32
|
const round = (value)=>Math.round(100 * value) / 100;
|
|
33
33
|
const createOverlayPosition = (options)=>{
|
|
34
|
-
const [style, setStyle] =
|
|
34
|
+
const [style, setStyle] = createSignal({
|
|
35
35
|
visibility: "hidden"
|
|
36
36
|
});
|
|
37
|
-
const [resolvedPlacement, setResolvedPlacement] =
|
|
38
|
-
|
|
37
|
+
const [resolvedPlacement, setResolvedPlacement] = createSignal(options.placement());
|
|
38
|
+
createEffect(()=>{
|
|
39
39
|
if (!options.open()) {
|
|
40
40
|
setResolvedPlacement(options.placement());
|
|
41
41
|
setStyle({
|
|
@@ -100,7 +100,7 @@ const createOverlayPosition = (options)=>{
|
|
|
100
100
|
const resizeObserver = "undefined" != typeof ResizeObserver ? new ResizeObserver(schedule) : void 0;
|
|
101
101
|
resizeObserver?.observe(trigger);
|
|
102
102
|
resizeObserver?.observe(overlay);
|
|
103
|
-
|
|
103
|
+
onCleanup(()=>{
|
|
104
104
|
cancelAnimationFrame(frame);
|
|
105
105
|
window.removeEventListener("resize", schedule);
|
|
106
106
|
window.removeEventListener("scroll", schedule, true);
|
|
@@ -1,158 +1,158 @@
|
|
|
1
|
-
@layer components {
|
|
2
|
-
.accordion {
|
|
3
|
-
width: 100%;
|
|
4
|
-
contain: layout style;
|
|
5
|
-
}
|
|
6
|
-
|
|
7
|
-
.accordion__item {
|
|
8
|
-
position: relative;
|
|
9
|
-
border: 0;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
.accordion__item::after {
|
|
13
|
-
content: "";
|
|
14
|
-
position: absolute;
|
|
15
|
-
bottom: 0;
|
|
16
|
-
left: 0;
|
|
17
|
-
height: 1px;
|
|
18
|
-
width: 100%;
|
|
19
|
-
border-radius: 9999px;
|
|
20
|
-
background-color: var(--color-base-300);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
.accordion__item:last-child::after {
|
|
24
|
-
content: none;
|
|
25
|
-
}
|
|
26
|
-
|
|
27
|
-
.accordion__item--hide-separator::after {
|
|
28
|
-
display: none;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
.accordion__item--disabled {
|
|
32
|
-
opacity: 0.65;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.accordion__trigger {
|
|
36
|
-
cursor: pointer;
|
|
37
|
-
display: flex;
|
|
38
|
-
width: 100%;
|
|
39
|
-
align-items: center;
|
|
40
|
-
justify-content: space-between;
|
|
41
|
-
border: 0;
|
|
42
|
-
background-color: transparent;
|
|
43
|
-
padding: 1rem;
|
|
44
|
-
text-align: left;
|
|
45
|
-
font-size: 0.875rem;
|
|
46
|
-
font-weight: 500;
|
|
47
|
-
color: inherit;
|
|
48
|
-
user-select: none;
|
|
49
|
-
transition:
|
|
50
|
-
opacity 150ms ease,
|
|
51
|
-
background-color 150ms ease,
|
|
52
|
-
box-shadow 150ms ease;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
.accordion__trigger:focus-visible,
|
|
56
|
-
.accordion__trigger[data-focus-visible="true"] {
|
|
57
|
-
outline: 2px solid var(--color-base-content);
|
|
58
|
-
outline-offset: 2px;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
.accordion__item--disabled .accordion__trigger,
|
|
62
|
-
.accordion__trigger:disabled,
|
|
63
|
-
.accordion__trigger[aria-disabled="true"] {
|
|
64
|
-
cursor: not-allowed;
|
|
65
|
-
opacity: 0.55;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
@media (hover: hover) {
|
|
69
|
-
.accordion__trigger:hover:not([aria-expanded="true"]):not(:disabled):not(
|
|
70
|
-
[aria-disabled="true"]
|
|
71
|
-
),
|
|
72
|
-
.accordion__trigger[data-hovered="true"]:not(
|
|
73
|
-
[aria-expanded="true"]
|
|
74
|
-
):not(:disabled):not([aria-disabled="true"]) {
|
|
75
|
-
background-color: color-mix(
|
|
76
|
-
in oklab,
|
|
77
|
-
var(--color-base-content),
|
|
78
|
-
transparent 96%
|
|
79
|
-
);
|
|
80
|
-
}
|
|
81
|
-
}
|
|
82
|
-
|
|
83
|
-
.accordion__indicator {
|
|
84
|
-
margin-inline-start: auto;
|
|
85
|
-
height: 1rem;
|
|
86
|
-
width: 1rem;
|
|
87
|
-
flex-shrink: 0;
|
|
88
|
-
opacity: 0.65;
|
|
89
|
-
transition: transform 250ms ease;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
.accordion__indicator--expanded {
|
|
93
|
-
transform: rotate(-180deg);
|
|
94
|
-
}
|
|
95
|
-
|
|
96
|
-
.accordion__content {
|
|
97
|
-
display: grid;
|
|
98
|
-
grid-template-rows: 0fr;
|
|
99
|
-
opacity: 0;
|
|
100
|
-
overflow: hidden;
|
|
101
|
-
transition:
|
|
102
|
-
grid-template-rows 200ms ease,
|
|
103
|
-
opacity 200ms ease;
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
.accordion__content--expanded {
|
|
107
|
-
grid-template-rows: 1fr;
|
|
108
|
-
opacity: 1;
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
.accordion__body {
|
|
112
|
-
min-height: 0;
|
|
113
|
-
overflow: hidden;
|
|
114
|
-
font-size: 0.875rem;
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
.accordion__body-inner {
|
|
118
|
-
padding-inline: 1rem;
|
|
119
|
-
padding-top: 0;
|
|
120
|
-
padding-bottom: 1rem;
|
|
121
|
-
color: color-mix(in oklab, var(--color-base-content), transparent 25%);
|
|
122
|
-
}
|
|
123
|
-
|
|
124
|
-
.accordion--surface {
|
|
125
|
-
border-radius: 1.5rem;
|
|
126
|
-
background-color: var(--color-base-100);
|
|
127
|
-
}
|
|
128
|
-
|
|
129
|
-
.accordion--surface .accordion__item::after {
|
|
130
|
-
left: 3%;
|
|
131
|
-
width: 94%;
|
|
132
|
-
background-color: color-mix(
|
|
133
|
-
in oklab,
|
|
134
|
-
var(--color-base-content),
|
|
135
|
-
transparent 90%
|
|
136
|
-
);
|
|
137
|
-
}
|
|
138
|
-
|
|
139
|
-
.accordion--surface .accordion__item:first-child .accordion__trigger {
|
|
140
|
-
border-top-left-radius: 1.5rem;
|
|
141
|
-
border-top-right-radius: 1.5rem;
|
|
142
|
-
}
|
|
143
|
-
|
|
144
|
-
.accordion--surface
|
|
145
|
-
.accordion__item:last-child:not(.accordion__item--expanded)
|
|
146
|
-
.accordion__trigger {
|
|
147
|
-
border-bottom-left-radius: 1.5rem;
|
|
148
|
-
border-bottom-right-radius: 1.5rem;
|
|
149
|
-
}
|
|
150
|
-
|
|
151
|
-
@media (prefers-reduced-motion: reduce) {
|
|
152
|
-
.accordion__trigger,
|
|
153
|
-
.accordion__indicator,
|
|
154
|
-
.accordion__content {
|
|
155
|
-
transition: none;
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
|
-
}
|
|
1
|
+
@layer components {
|
|
2
|
+
.accordion {
|
|
3
|
+
width: 100%;
|
|
4
|
+
contain: layout style;
|
|
5
|
+
}
|
|
6
|
+
|
|
7
|
+
.accordion__item {
|
|
8
|
+
position: relative;
|
|
9
|
+
border: 0;
|
|
10
|
+
}
|
|
11
|
+
|
|
12
|
+
.accordion__item::after {
|
|
13
|
+
content: "";
|
|
14
|
+
position: absolute;
|
|
15
|
+
bottom: 0;
|
|
16
|
+
left: 0;
|
|
17
|
+
height: 1px;
|
|
18
|
+
width: 100%;
|
|
19
|
+
border-radius: 9999px;
|
|
20
|
+
background-color: var(--color-base-300);
|
|
21
|
+
}
|
|
22
|
+
|
|
23
|
+
.accordion__item:last-child::after {
|
|
24
|
+
content: none;
|
|
25
|
+
}
|
|
26
|
+
|
|
27
|
+
.accordion__item--hide-separator::after {
|
|
28
|
+
display: none;
|
|
29
|
+
}
|
|
30
|
+
|
|
31
|
+
.accordion__item--disabled {
|
|
32
|
+
opacity: 0.65;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.accordion__trigger {
|
|
36
|
+
cursor: pointer;
|
|
37
|
+
display: flex;
|
|
38
|
+
width: 100%;
|
|
39
|
+
align-items: center;
|
|
40
|
+
justify-content: space-between;
|
|
41
|
+
border: 0;
|
|
42
|
+
background-color: transparent;
|
|
43
|
+
padding: 1rem;
|
|
44
|
+
text-align: left;
|
|
45
|
+
font-size: 0.875rem;
|
|
46
|
+
font-weight: 500;
|
|
47
|
+
color: inherit;
|
|
48
|
+
user-select: none;
|
|
49
|
+
transition:
|
|
50
|
+
opacity 150ms ease,
|
|
51
|
+
background-color 150ms ease,
|
|
52
|
+
box-shadow 150ms ease;
|
|
53
|
+
}
|
|
54
|
+
|
|
55
|
+
.accordion__trigger:focus-visible,
|
|
56
|
+
.accordion__trigger[data-focus-visible="true"] {
|
|
57
|
+
outline: 2px solid var(--color-base-content);
|
|
58
|
+
outline-offset: 2px;
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
.accordion__item--disabled .accordion__trigger,
|
|
62
|
+
.accordion__trigger:disabled,
|
|
63
|
+
.accordion__trigger[aria-disabled="true"] {
|
|
64
|
+
cursor: not-allowed;
|
|
65
|
+
opacity: 0.55;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
@media (hover: hover) {
|
|
69
|
+
.accordion__trigger:hover:not([aria-expanded="true"]):not(:disabled):not(
|
|
70
|
+
[aria-disabled="true"]
|
|
71
|
+
),
|
|
72
|
+
.accordion__trigger[data-hovered="true"]:not(
|
|
73
|
+
[aria-expanded="true"]
|
|
74
|
+
):not(:disabled):not([aria-disabled="true"]) {
|
|
75
|
+
background-color: color-mix(
|
|
76
|
+
in oklab,
|
|
77
|
+
var(--color-base-content),
|
|
78
|
+
transparent 96%
|
|
79
|
+
);
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
.accordion__indicator {
|
|
84
|
+
margin-inline-start: auto;
|
|
85
|
+
height: 1rem;
|
|
86
|
+
width: 1rem;
|
|
87
|
+
flex-shrink: 0;
|
|
88
|
+
opacity: 0.65;
|
|
89
|
+
transition: transform 250ms ease;
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
.accordion__indicator--expanded {
|
|
93
|
+
transform: rotate(-180deg);
|
|
94
|
+
}
|
|
95
|
+
|
|
96
|
+
.accordion__content {
|
|
97
|
+
display: grid;
|
|
98
|
+
grid-template-rows: 0fr;
|
|
99
|
+
opacity: 0;
|
|
100
|
+
overflow: hidden;
|
|
101
|
+
transition:
|
|
102
|
+
grid-template-rows 200ms ease,
|
|
103
|
+
opacity 200ms ease;
|
|
104
|
+
}
|
|
105
|
+
|
|
106
|
+
.accordion__content--expanded {
|
|
107
|
+
grid-template-rows: 1fr;
|
|
108
|
+
opacity: 1;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.accordion__body {
|
|
112
|
+
min-height: 0;
|
|
113
|
+
overflow: hidden;
|
|
114
|
+
font-size: 0.875rem;
|
|
115
|
+
}
|
|
116
|
+
|
|
117
|
+
.accordion__body-inner {
|
|
118
|
+
padding-inline: 1rem;
|
|
119
|
+
padding-top: 0;
|
|
120
|
+
padding-bottom: 1rem;
|
|
121
|
+
color: color-mix(in oklab, var(--color-base-content), transparent 25%);
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
.accordion--surface {
|
|
125
|
+
border-radius: 1.5rem;
|
|
126
|
+
background-color: var(--color-base-100);
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
.accordion--surface .accordion__item::after {
|
|
130
|
+
left: 3%;
|
|
131
|
+
width: 94%;
|
|
132
|
+
background-color: color-mix(
|
|
133
|
+
in oklab,
|
|
134
|
+
var(--color-base-content),
|
|
135
|
+
transparent 90%
|
|
136
|
+
);
|
|
137
|
+
}
|
|
138
|
+
|
|
139
|
+
.accordion--surface .accordion__item:first-child .accordion__trigger {
|
|
140
|
+
border-top-left-radius: 1.5rem;
|
|
141
|
+
border-top-right-radius: 1.5rem;
|
|
142
|
+
}
|
|
143
|
+
|
|
144
|
+
.accordion--surface
|
|
145
|
+
.accordion__item:last-child:not(.accordion__item--expanded)
|
|
146
|
+
.accordion__trigger {
|
|
147
|
+
border-bottom-left-radius: 1.5rem;
|
|
148
|
+
border-bottom-right-radius: 1.5rem;
|
|
149
|
+
}
|
|
150
|
+
|
|
151
|
+
@media (prefers-reduced-motion: reduce) {
|
|
152
|
+
.accordion__trigger,
|
|
153
|
+
.accordion__indicator,
|
|
154
|
+
.accordion__content {
|
|
155
|
+
transition: none;
|
|
156
|
+
}
|
|
157
|
+
}
|
|
158
|
+
}
|