@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
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { insert, mergeProps, spread, template } from "solid-js/web";
|
|
2
2
|
import "./Card.css";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
var _tmpl$ = /*#__PURE__*/
|
|
3
|
+
import { splitProps } from "solid-js";
|
|
4
|
+
import { twMerge } from "tailwind-merge";
|
|
5
|
+
import { CLASSES } from "./Card.classes.js";
|
|
6
|
+
var _tmpl$ = /*#__PURE__*/ template("<div>");
|
|
7
7
|
const invokeEventHandler = (handler, event)=>{
|
|
8
8
|
if ("function" == typeof handler) return void handler(event);
|
|
9
9
|
if (Array.isArray(handler) && "function" == typeof handler[0]) handler[0](handler[1], event);
|
|
10
10
|
};
|
|
11
11
|
const CardRoot = (props)=>{
|
|
12
|
-
const [local, others] =
|
|
12
|
+
const [local, others] = splitProps(props, [
|
|
13
13
|
"children",
|
|
14
14
|
"class",
|
|
15
15
|
"className",
|
|
@@ -33,8 +33,8 @@ const CardRoot = (props)=>{
|
|
|
33
33
|
};
|
|
34
34
|
return (()=>{
|
|
35
35
|
var _el$ = _tmpl$();
|
|
36
|
-
|
|
37
|
-
class:
|
|
36
|
+
spread(_el$, mergeProps(others, ()=>({
|
|
37
|
+
class: twMerge(CLASSES.Root.base, CLASSES.Root.variant[variant()], local.isHoverable && CLASSES.Root.flag.isHoverable, local.isPressable && CLASSES.Root.flag.isPressable, local.class, local.className)
|
|
38
38
|
}), {
|
|
39
39
|
"data-slot": "card",
|
|
40
40
|
get ["data-variant"] () {
|
|
@@ -60,12 +60,12 @@ const CardRoot = (props)=>{
|
|
|
60
60
|
},
|
|
61
61
|
onKeyDown: handleKeyDown
|
|
62
62
|
}), false, true);
|
|
63
|
-
|
|
63
|
+
insert(_el$, ()=>local.children);
|
|
64
64
|
return _el$;
|
|
65
65
|
})();
|
|
66
66
|
};
|
|
67
67
|
const CardHeader = (props)=>{
|
|
68
|
-
const [local, others] =
|
|
68
|
+
const [local, others] = splitProps(props, [
|
|
69
69
|
"children",
|
|
70
70
|
"class",
|
|
71
71
|
"className",
|
|
@@ -74,8 +74,8 @@ const CardHeader = (props)=>{
|
|
|
74
74
|
]);
|
|
75
75
|
return (()=>{
|
|
76
76
|
var _el$2 = _tmpl$();
|
|
77
|
-
|
|
78
|
-
class:
|
|
77
|
+
spread(_el$2, mergeProps(others, ()=>({
|
|
78
|
+
class: twMerge(CLASSES.Header.base, local.class, local.className)
|
|
79
79
|
}), {
|
|
80
80
|
"data-slot": "card-header",
|
|
81
81
|
get ["data-theme"] () {
|
|
@@ -85,12 +85,12 @@ const CardHeader = (props)=>{
|
|
|
85
85
|
return local.style;
|
|
86
86
|
}
|
|
87
87
|
}), false, true);
|
|
88
|
-
|
|
88
|
+
insert(_el$2, ()=>local.children);
|
|
89
89
|
return _el$2;
|
|
90
90
|
})();
|
|
91
91
|
};
|
|
92
92
|
const CardBody = (props)=>{
|
|
93
|
-
const [local, others] =
|
|
93
|
+
const [local, others] = splitProps(props, [
|
|
94
94
|
"children",
|
|
95
95
|
"class",
|
|
96
96
|
"className",
|
|
@@ -99,8 +99,8 @@ const CardBody = (props)=>{
|
|
|
99
99
|
]);
|
|
100
100
|
return (()=>{
|
|
101
101
|
var _el$3 = _tmpl$();
|
|
102
|
-
|
|
103
|
-
class:
|
|
102
|
+
spread(_el$3, mergeProps(others, ()=>({
|
|
103
|
+
class: twMerge(CLASSES.Body.base, local.class, local.className)
|
|
104
104
|
}), {
|
|
105
105
|
"data-slot": "card-body",
|
|
106
106
|
get ["data-theme"] () {
|
|
@@ -110,12 +110,12 @@ const CardBody = (props)=>{
|
|
|
110
110
|
return local.style;
|
|
111
111
|
}
|
|
112
112
|
}), false, true);
|
|
113
|
-
|
|
113
|
+
insert(_el$3, ()=>local.children);
|
|
114
114
|
return _el$3;
|
|
115
115
|
})();
|
|
116
116
|
};
|
|
117
117
|
const CardFooter = (props)=>{
|
|
118
|
-
const [local, others] =
|
|
118
|
+
const [local, others] = splitProps(props, [
|
|
119
119
|
"children",
|
|
120
120
|
"class",
|
|
121
121
|
"className",
|
|
@@ -124,8 +124,8 @@ const CardFooter = (props)=>{
|
|
|
124
124
|
]);
|
|
125
125
|
return (()=>{
|
|
126
126
|
var _el$4 = _tmpl$();
|
|
127
|
-
|
|
128
|
-
class:
|
|
127
|
+
spread(_el$4, mergeProps(others, ()=>({
|
|
128
|
+
class: twMerge(CLASSES.Footer.base, local.class, local.className)
|
|
129
129
|
}), {
|
|
130
130
|
"data-slot": "card-footer",
|
|
131
131
|
get ["data-theme"] () {
|
|
@@ -135,7 +135,7 @@ const CardFooter = (props)=>{
|
|
|
135
135
|
return local.style;
|
|
136
136
|
}
|
|
137
137
|
}), false, true);
|
|
138
|
-
|
|
138
|
+
insert(_el$4, ()=>local.children);
|
|
139
139
|
return _el$4;
|
|
140
140
|
})();
|
|
141
141
|
};
|
|
@@ -1,8 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
var __webpack_exports__CardBody = __WEBPACK_EXTERNAL_MODULE__Card_js_d67c086a__.CardBody;
|
|
4
|
-
var __webpack_exports__CardFooter = __WEBPACK_EXTERNAL_MODULE__Card_js_d67c086a__.CardFooter;
|
|
5
|
-
var __webpack_exports__CardHeader = __WEBPACK_EXTERNAL_MODULE__Card_js_d67c086a__.CardHeader;
|
|
6
|
-
var __webpack_exports__CardRoot = __WEBPACK_EXTERNAL_MODULE__Card_js_d67c086a__.CardRoot;
|
|
7
|
-
var __webpack_exports__default = __WEBPACK_EXTERNAL_MODULE__Card_js_d67c086a__["default"];
|
|
8
|
-
export { __webpack_exports__Card as Card, __webpack_exports__CardBody as CardBody, __webpack_exports__CardFooter as CardFooter, __webpack_exports__CardHeader as CardHeader, __webpack_exports__CardRoot as CardRoot, __webpack_exports__default as default };
|
|
1
|
+
import external_Card_js_default, { Card, CardBody, CardFooter, CardHeader, CardRoot } from "./Card.js";
|
|
2
|
+
export { Card, CardBody, CardFooter, CardHeader, CardRoot, external_Card_js_default as default };
|
|
@@ -1,164 +1,164 @@
|
|
|
1
|
-
@layer components {
|
|
2
|
-
.chatbubble {
|
|
3
|
-
display: grid;
|
|
4
|
-
grid-auto-rows: min-content;
|
|
5
|
-
column-gap: calc(0.25rem * 3);
|
|
6
|
-
padding-block: calc(0.25rem * 1);
|
|
7
|
-
--mask-chatbubble: url("data:image/svg+xml,%3csvg width='13' height='13' xmlns='http://www.w3.org/2000/svg'%3e%3cpath fill='black' d='M0 11.5004C0 13.0004 2 13.0004 2 13.0004H12H13V0.00036329L12.5 0C12.5 0 11.977 2.09572 11.8581 2.50033C11.6075 3.35237 10.9149 4.22374 9 5.50036C6 7.50036 0 10.0004 0 11.5004Z'/%3e%3c/svg%3e");
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
.chatbubble__header {
|
|
11
|
-
grid-row-start: 1;
|
|
12
|
-
display: flex;
|
|
13
|
-
gap: calc(0.25rem * 1);
|
|
14
|
-
font-size: 0.6875rem;
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
.chatbubble__footer {
|
|
18
|
-
grid-row-start: 3;
|
|
19
|
-
display: flex;
|
|
20
|
-
gap: calc(0.25rem * 1);
|
|
21
|
-
font-size: 0.6875rem;
|
|
22
|
-
opacity: 0.5;
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
.chatbubble__avatar {
|
|
26
|
-
grid-row: span 2 / span 2;
|
|
27
|
-
align-self: flex-end;
|
|
28
|
-
}
|
|
29
|
-
|
|
30
|
-
.chatbubble__message {
|
|
31
|
-
position: relative;
|
|
32
|
-
display: block;
|
|
33
|
-
width: fit-content;
|
|
34
|
-
border-radius: var(--radius-field);
|
|
35
|
-
background-color: var(--color-base-300);
|
|
36
|
-
padding-inline: calc(0.25rem * 4);
|
|
37
|
-
padding-block: calc(0.25rem * 2);
|
|
38
|
-
color: var(--color-base-content);
|
|
39
|
-
grid-row-end: 3;
|
|
40
|
-
min-height: 2rem;
|
|
41
|
-
min-width: 2.5rem;
|
|
42
|
-
max-width: 90%;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
.chatbubble__message:before {
|
|
46
|
-
position: absolute;
|
|
47
|
-
bottom: 0;
|
|
48
|
-
height: calc(0.25rem * 3);
|
|
49
|
-
width: calc(0.25rem * 3);
|
|
50
|
-
background-color: inherit;
|
|
51
|
-
content: "";
|
|
52
|
-
mask-repeat: no-repeat;
|
|
53
|
-
mask-image: var(--mask-chatbubble);
|
|
54
|
-
mask-position: 0 -1px;
|
|
55
|
-
mask-size: 0.8125rem;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
.chatbubble__time {
|
|
59
|
-
font-size: 0.75rem;
|
|
60
|
-
opacity: 0.5;
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
.chatbubble--end {
|
|
64
|
-
place-items: end;
|
|
65
|
-
grid-template-columns: 1fr auto;
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
.chatbubble--end .chatbubble__header {
|
|
69
|
-
grid-column-start: 1;
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
.chatbubble--end .chatbubble__footer {
|
|
73
|
-
grid-column-start: 1;
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
.chatbubble--end .chatbubble__avatar {
|
|
77
|
-
grid-column-start: 2;
|
|
78
|
-
}
|
|
79
|
-
|
|
80
|
-
.chatbubble--end .chatbubble__message {
|
|
81
|
-
grid-column-start: 1;
|
|
82
|
-
border-end-end-radius: 0;
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
.chatbubble--end .chatbubble__message:before {
|
|
86
|
-
transform: rotateY(180deg);
|
|
87
|
-
inset-inline-start: 100%;
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
[dir="rtl"] .chatbubble--end .chatbubble__message:before {
|
|
91
|
-
transform: rotateY(0deg);
|
|
92
|
-
}
|
|
93
|
-
|
|
94
|
-
.chatbubble--start {
|
|
95
|
-
place-items: start;
|
|
96
|
-
grid-template-columns: auto 1fr;
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
.chatbubble--start .chatbubble__header {
|
|
100
|
-
grid-column-start: 2;
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
.chatbubble--start .chatbubble__footer {
|
|
104
|
-
grid-column-start: 2;
|
|
105
|
-
}
|
|
106
|
-
|
|
107
|
-
.chatbubble--start .chatbubble__avatar {
|
|
108
|
-
grid-column-start: 1;
|
|
109
|
-
}
|
|
110
|
-
|
|
111
|
-
.chatbubble--start .chatbubble__message {
|
|
112
|
-
grid-column-start: 2;
|
|
113
|
-
border-end-start-radius: 0;
|
|
114
|
-
}
|
|
115
|
-
|
|
116
|
-
.chatbubble--start .chatbubble__message:before {
|
|
117
|
-
transform: rotateY(0deg);
|
|
118
|
-
inset-inline-start: -0.75rem;
|
|
119
|
-
}
|
|
120
|
-
|
|
121
|
-
[dir="rtl"] .chatbubble--start .chatbubble__message:before {
|
|
122
|
-
transform: rotateY(180deg);
|
|
123
|
-
}
|
|
124
|
-
|
|
125
|
-
.chatbubble__message--neutral {
|
|
126
|
-
background-color: var(--color-base-300);
|
|
127
|
-
color: var(--color-base-content);
|
|
128
|
-
}
|
|
129
|
-
|
|
130
|
-
.chatbubble__message--primary {
|
|
131
|
-
background-color: var(--color-primary);
|
|
132
|
-
color: var(--color-primary-content);
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
.chatbubble__message--secondary {
|
|
136
|
-
background-color: var(--color-secondary);
|
|
137
|
-
color: var(--color-secondary-content);
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
.chatbubble__message--accent {
|
|
141
|
-
background-color: var(--color-accent);
|
|
142
|
-
color: var(--color-accent-content);
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
.chatbubble__message--info {
|
|
146
|
-
background-color: var(--color-info);
|
|
147
|
-
color: var(--color-info-content);
|
|
148
|
-
}
|
|
149
|
-
|
|
150
|
-
.chatbubble__message--success {
|
|
151
|
-
background-color: var(--color-success);
|
|
152
|
-
color: var(--color-success-content);
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
.chatbubble__message--warning {
|
|
156
|
-
background-color: var(--color-warning);
|
|
157
|
-
color: var(--color-warning-content);
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
.chatbubble__message--error {
|
|
161
|
-
background-color: var(--color-error);
|
|
162
|
-
color: var(--color-error-content);
|
|
163
|
-
}
|
|
164
|
-
}
|
|
1
|
+
@layer components {
|
|
2
|
+
.chatbubble {
|
|
3
|
+
display: grid;
|
|
4
|
+
grid-auto-rows: min-content;
|
|
5
|
+
column-gap: calc(0.25rem * 3);
|
|
6
|
+
padding-block: calc(0.25rem * 1);
|
|
7
|
+
--mask-chatbubble: url("data:image/svg+xml,%3csvg width='13' height='13' xmlns='http://www.w3.org/2000/svg'%3e%3cpath fill='black' d='M0 11.5004C0 13.0004 2 13.0004 2 13.0004H12H13V0.00036329L12.5 0C12.5 0 11.977 2.09572 11.8581 2.50033C11.6075 3.35237 10.9149 4.22374 9 5.50036C6 7.50036 0 10.0004 0 11.5004Z'/%3e%3c/svg%3e");
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
.chatbubble__header {
|
|
11
|
+
grid-row-start: 1;
|
|
12
|
+
display: flex;
|
|
13
|
+
gap: calc(0.25rem * 1);
|
|
14
|
+
font-size: 0.6875rem;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
.chatbubble__footer {
|
|
18
|
+
grid-row-start: 3;
|
|
19
|
+
display: flex;
|
|
20
|
+
gap: calc(0.25rem * 1);
|
|
21
|
+
font-size: 0.6875rem;
|
|
22
|
+
opacity: 0.5;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.chatbubble__avatar {
|
|
26
|
+
grid-row: span 2 / span 2;
|
|
27
|
+
align-self: flex-end;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.chatbubble__message {
|
|
31
|
+
position: relative;
|
|
32
|
+
display: block;
|
|
33
|
+
width: fit-content;
|
|
34
|
+
border-radius: var(--radius-field);
|
|
35
|
+
background-color: var(--color-base-300);
|
|
36
|
+
padding-inline: calc(0.25rem * 4);
|
|
37
|
+
padding-block: calc(0.25rem * 2);
|
|
38
|
+
color: var(--color-base-content);
|
|
39
|
+
grid-row-end: 3;
|
|
40
|
+
min-height: 2rem;
|
|
41
|
+
min-width: 2.5rem;
|
|
42
|
+
max-width: 90%;
|
|
43
|
+
}
|
|
44
|
+
|
|
45
|
+
.chatbubble__message:before {
|
|
46
|
+
position: absolute;
|
|
47
|
+
bottom: 0;
|
|
48
|
+
height: calc(0.25rem * 3);
|
|
49
|
+
width: calc(0.25rem * 3);
|
|
50
|
+
background-color: inherit;
|
|
51
|
+
content: "";
|
|
52
|
+
mask-repeat: no-repeat;
|
|
53
|
+
mask-image: var(--mask-chatbubble);
|
|
54
|
+
mask-position: 0 -1px;
|
|
55
|
+
mask-size: 0.8125rem;
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.chatbubble__time {
|
|
59
|
+
font-size: 0.75rem;
|
|
60
|
+
opacity: 0.5;
|
|
61
|
+
}
|
|
62
|
+
|
|
63
|
+
.chatbubble--end {
|
|
64
|
+
place-items: end;
|
|
65
|
+
grid-template-columns: 1fr auto;
|
|
66
|
+
}
|
|
67
|
+
|
|
68
|
+
.chatbubble--end .chatbubble__header {
|
|
69
|
+
grid-column-start: 1;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
.chatbubble--end .chatbubble__footer {
|
|
73
|
+
grid-column-start: 1;
|
|
74
|
+
}
|
|
75
|
+
|
|
76
|
+
.chatbubble--end .chatbubble__avatar {
|
|
77
|
+
grid-column-start: 2;
|
|
78
|
+
}
|
|
79
|
+
|
|
80
|
+
.chatbubble--end .chatbubble__message {
|
|
81
|
+
grid-column-start: 1;
|
|
82
|
+
border-end-end-radius: 0;
|
|
83
|
+
}
|
|
84
|
+
|
|
85
|
+
.chatbubble--end .chatbubble__message:before {
|
|
86
|
+
transform: rotateY(180deg);
|
|
87
|
+
inset-inline-start: 100%;
|
|
88
|
+
}
|
|
89
|
+
|
|
90
|
+
[dir="rtl"] .chatbubble--end .chatbubble__message:before {
|
|
91
|
+
transform: rotateY(0deg);
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
.chatbubble--start {
|
|
95
|
+
place-items: start;
|
|
96
|
+
grid-template-columns: auto 1fr;
|
|
97
|
+
}
|
|
98
|
+
|
|
99
|
+
.chatbubble--start .chatbubble__header {
|
|
100
|
+
grid-column-start: 2;
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
.chatbubble--start .chatbubble__footer {
|
|
104
|
+
grid-column-start: 2;
|
|
105
|
+
}
|
|
106
|
+
|
|
107
|
+
.chatbubble--start .chatbubble__avatar {
|
|
108
|
+
grid-column-start: 1;
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
.chatbubble--start .chatbubble__message {
|
|
112
|
+
grid-column-start: 2;
|
|
113
|
+
border-end-start-radius: 0;
|
|
114
|
+
}
|
|
115
|
+
|
|
116
|
+
.chatbubble--start .chatbubble__message:before {
|
|
117
|
+
transform: rotateY(0deg);
|
|
118
|
+
inset-inline-start: -0.75rem;
|
|
119
|
+
}
|
|
120
|
+
|
|
121
|
+
[dir="rtl"] .chatbubble--start .chatbubble__message:before {
|
|
122
|
+
transform: rotateY(180deg);
|
|
123
|
+
}
|
|
124
|
+
|
|
125
|
+
.chatbubble__message--neutral {
|
|
126
|
+
background-color: var(--color-base-300);
|
|
127
|
+
color: var(--color-base-content);
|
|
128
|
+
}
|
|
129
|
+
|
|
130
|
+
.chatbubble__message--primary {
|
|
131
|
+
background-color: var(--color-primary);
|
|
132
|
+
color: var(--color-primary-content);
|
|
133
|
+
}
|
|
134
|
+
|
|
135
|
+
.chatbubble__message--secondary {
|
|
136
|
+
background-color: var(--color-secondary);
|
|
137
|
+
color: var(--color-secondary-content);
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.chatbubble__message--accent {
|
|
141
|
+
background-color: var(--color-accent);
|
|
142
|
+
color: var(--color-accent-content);
|
|
143
|
+
}
|
|
144
|
+
|
|
145
|
+
.chatbubble__message--info {
|
|
146
|
+
background-color: var(--color-info);
|
|
147
|
+
color: var(--color-info-content);
|
|
148
|
+
}
|
|
149
|
+
|
|
150
|
+
.chatbubble__message--success {
|
|
151
|
+
background-color: var(--color-success);
|
|
152
|
+
color: var(--color-success-content);
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
.chatbubble__message--warning {
|
|
156
|
+
background-color: var(--color-warning);
|
|
157
|
+
color: var(--color-warning-content);
|
|
158
|
+
}
|
|
159
|
+
|
|
160
|
+
.chatbubble__message--error {
|
|
161
|
+
background-color: var(--color-error);
|
|
162
|
+
color: var(--color-error-content);
|
|
163
|
+
}
|
|
164
|
+
}
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import
|
|
1
|
+
import { insert, mergeProps, spread, template } from "solid-js/web";
|
|
2
2
|
import "./ChatBubble.css";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
import
|
|
7
|
-
import
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
var _tmpl$ = /*#__PURE__*/
|
|
3
|
+
import { createMemo, splitProps } from "solid-js";
|
|
4
|
+
import { twMerge } from "tailwind-merge";
|
|
5
|
+
import external_ChatBubbleHeader_js_default from "./ChatBubbleHeader.js";
|
|
6
|
+
import external_ChatBubbleTime_js_default from "./ChatBubbleTime.js";
|
|
7
|
+
import external_ChatBubbleAvatar_js_default from "./ChatBubbleAvatar.js";
|
|
8
|
+
import external_ChatBubbleMessage_js_default from "./ChatBubbleMessage.js";
|
|
9
|
+
import external_ChatBubbleFooter_js_default from "./ChatBubbleFooter.js";
|
|
10
|
+
import { CLASSES } from "./ChatBubble.classes.js";
|
|
11
|
+
var _tmpl$ = /*#__PURE__*/ template("<div>");
|
|
12
12
|
const ChatBubble = (props)=>{
|
|
13
|
-
const [local, others] =
|
|
13
|
+
const [local, others] = splitProps(props, [
|
|
14
14
|
"end",
|
|
15
15
|
"dataTheme",
|
|
16
16
|
"class",
|
|
17
17
|
"className",
|
|
18
18
|
"style"
|
|
19
19
|
]);
|
|
20
|
-
const classes =
|
|
20
|
+
const classes = createMemo(()=>twMerge(CLASSES.base, local.end ? CLASSES.align.end : CLASSES.align.start, local.class, local.className));
|
|
21
21
|
return (()=>{
|
|
22
22
|
var _el$ = _tmpl$();
|
|
23
|
-
|
|
23
|
+
spread(_el$, mergeProps(others, {
|
|
24
24
|
get ["data-theme"] () {
|
|
25
25
|
return local.dataTheme;
|
|
26
26
|
}
|
|
@@ -31,15 +31,15 @@ const ChatBubble = (props)=>{
|
|
|
31
31
|
return local.style;
|
|
32
32
|
}
|
|
33
33
|
}), false, true);
|
|
34
|
-
|
|
34
|
+
insert(_el$, ()=>others.children);
|
|
35
35
|
return _el$;
|
|
36
36
|
})();
|
|
37
37
|
};
|
|
38
38
|
const chatbubble_ChatBubble = Object.assign(ChatBubble, {
|
|
39
|
-
Header:
|
|
40
|
-
Time:
|
|
41
|
-
Avatar:
|
|
42
|
-
Message:
|
|
43
|
-
Footer:
|
|
39
|
+
Header: external_ChatBubbleHeader_js_default,
|
|
40
|
+
Time: external_ChatBubbleTime_js_default,
|
|
41
|
+
Avatar: external_ChatBubbleAvatar_js_default,
|
|
42
|
+
Message: external_ChatBubbleMessage_js_default,
|
|
43
|
+
Footer: external_ChatBubbleFooter_js_default
|
|
44
44
|
});
|
|
45
45
|
export { chatbubble_ChatBubble as default };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
const ChatBubbleAvatar = (props)=>
|
|
1
|
+
import { createComponent, memo, mergeProps } from "solid-js/web";
|
|
2
|
+
import { twMerge } from "tailwind-merge";
|
|
3
|
+
import index_js_default from "../avatar/index.js";
|
|
4
|
+
import { CLASSES } from "./ChatBubble.classes.js";
|
|
5
|
+
const ChatBubbleAvatar = (props)=>createComponent(index_js_default, mergeProps({
|
|
6
6
|
get size () {
|
|
7
7
|
return props.size ?? "sm";
|
|
8
8
|
},
|
|
@@ -13,7 +13,7 @@ const ChatBubbleAvatar = (props)=>(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d
|
|
|
13
13
|
return props.variant;
|
|
14
14
|
}
|
|
15
15
|
}, ()=>({
|
|
16
|
-
class:
|
|
16
|
+
class: twMerge(CLASSES.slot.avatar, props.class, props.className)
|
|
17
17
|
}), {
|
|
18
18
|
get dataTheme () {
|
|
19
19
|
return props.dataTheme;
|
|
@@ -23,7 +23,7 @@ const ChatBubbleAvatar = (props)=>(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d
|
|
|
23
23
|
},
|
|
24
24
|
get children () {
|
|
25
25
|
return [
|
|
26
|
-
|
|
26
|
+
memo(()=>memo(()=>!!props.src)() && createComponent(index_js_default.Image, {
|
|
27
27
|
get src () {
|
|
28
28
|
return props.src;
|
|
29
29
|
},
|
|
@@ -31,7 +31,7 @@ const ChatBubbleAvatar = (props)=>(0, __WEBPACK_EXTERNAL_MODULE_solid_js_web_35d
|
|
|
31
31
|
return props.alt;
|
|
32
32
|
}
|
|
33
33
|
})),
|
|
34
|
-
|
|
34
|
+
createComponent(index_js_default.Fallback, {
|
|
35
35
|
get children () {
|
|
36
36
|
return props.fallback ?? props.alt?.charAt(0) ?? "?";
|
|
37
37
|
}
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
var _tmpl$ = /*#__PURE__*/
|
|
6
|
-
const
|
|
7
|
-
const [local, others] =
|
|
1
|
+
import { mergeProps, spread, template } from "solid-js/web";
|
|
2
|
+
import { splitProps } from "solid-js";
|
|
3
|
+
import { twMerge } from "tailwind-merge";
|
|
4
|
+
import { CLASSES } from "./ChatBubble.classes.js";
|
|
5
|
+
var _tmpl$ = /*#__PURE__*/ template("<div>");
|
|
6
|
+
const ChatBubbleFooter_ChatBubbleFooter = (props)=>{
|
|
7
|
+
const [local, others] = splitProps(props, [
|
|
8
8
|
"class",
|
|
9
9
|
"className"
|
|
10
10
|
]);
|
|
11
11
|
return (()=>{
|
|
12
12
|
var _el$ = _tmpl$();
|
|
13
|
-
|
|
14
|
-
class:
|
|
13
|
+
spread(_el$, mergeProps(others, ()=>({
|
|
14
|
+
class: twMerge(CLASSES.slot.footer, local.class, local.className)
|
|
15
15
|
})), false, false);
|
|
16
16
|
return _el$;
|
|
17
17
|
})();
|
|
18
18
|
};
|
|
19
|
-
const
|
|
20
|
-
export {
|
|
19
|
+
const ChatBubbleFooter = ChatBubbleFooter_ChatBubbleFooter;
|
|
20
|
+
export { ChatBubbleFooter as default };
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
var _tmpl$ = /*#__PURE__*/
|
|
1
|
+
import { mergeProps, spread, template } from "solid-js/web";
|
|
2
|
+
import { splitProps } from "solid-js";
|
|
3
|
+
import { twMerge } from "tailwind-merge";
|
|
4
|
+
import { CLASSES } from "./ChatBubble.classes.js";
|
|
5
|
+
var _tmpl$ = /*#__PURE__*/ template("<div>");
|
|
6
6
|
const ChatBubbleHeader_ChatBubbleHeader = (props)=>{
|
|
7
|
-
const [local, others] =
|
|
7
|
+
const [local, others] = splitProps(props, [
|
|
8
8
|
"class",
|
|
9
9
|
"className"
|
|
10
10
|
]);
|
|
11
11
|
return (()=>{
|
|
12
12
|
var _el$ = _tmpl$();
|
|
13
|
-
|
|
14
|
-
class:
|
|
13
|
+
spread(_el$, mergeProps(others, ()=>({
|
|
14
|
+
class: twMerge(CLASSES.slot.header, local.class, local.className)
|
|
15
15
|
})), false, false);
|
|
16
16
|
return _el$;
|
|
17
17
|
})();
|