material-plus-ui 1.2.0 → 1.3.1
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/README.md +23 -2
- package/dist/components/accordion/MPAccordion.d.ts +1 -1
- package/dist/components/accordion/MPAccordion.js +2 -1
- package/dist/components/accordion/index.d.ts +2 -2
- package/dist/components/accordion/index.js +1 -1
- package/dist/components/alert/MPAlert.d.ts +1 -1
- package/dist/components/alert/MPAlert.js +2 -1
- package/dist/components/alert/index.d.ts +2 -2
- package/dist/components/alert/index.js +1 -1
- package/dist/components/animate-appear/MPAnimateAppear.d.ts +1 -1
- package/dist/components/animate-appear/MPAnimateAppear.js +2 -1
- package/dist/components/animate-appear/index.d.ts +2 -2
- package/dist/components/animate-appear/index.js +1 -1
- package/dist/components/animate-blink/MPAnimateBlink.d.ts +1 -1
- package/dist/components/animate-blink/MPAnimateBlink.js +1 -1
- package/dist/components/animate-blink/index.d.ts +2 -2
- package/dist/components/animate-blink/index.js +1 -1
- package/dist/components/animate-fade/MPAnimateFade.d.ts +1 -1
- package/dist/components/animate-fade/MPAnimateFade.js +1 -1
- package/dist/components/animate-fade/index.d.ts +2 -2
- package/dist/components/animate-fade/index.js +1 -1
- package/dist/components/animate-grow/MPAnimateGrow.d.ts +1 -1
- package/dist/components/animate-grow/MPAnimateGrow.js +1 -1
- package/dist/components/animate-grow/index.d.ts +2 -2
- package/dist/components/animate-grow/index.js +1 -1
- package/dist/components/animate-headline/MPAnimateHeadline.d.ts +1 -1
- package/dist/components/animate-headline/MPAnimateHeadline.js +2 -1
- package/dist/components/animate-headline/index.d.ts +2 -2
- package/dist/components/animate-headline/index.js +1 -1
- package/dist/components/animate-lighting/MPAnimateLighting.d.ts +1 -1
- package/dist/components/animate-lighting/MPAnimateLighting.js +1 -1
- package/dist/components/animate-lighting/index.d.ts +2 -2
- package/dist/components/animate-lighting/index.js +1 -1
- package/dist/components/animate-marquee/MPAnimateMarquee.d.ts +1 -1
- package/dist/components/animate-marquee/MPAnimateMarquee.js +2 -1
- package/dist/components/animate-marquee/index.d.ts +2 -2
- package/dist/components/animate-marquee/index.js +1 -1
- package/dist/components/animate-rotate/MPAnimateRotate.d.ts +1 -1
- package/dist/components/animate-rotate/MPAnimateRotate.js +1 -1
- package/dist/components/animate-rotate/index.d.ts +2 -2
- package/dist/components/animate-rotate/index.js +1 -1
- package/dist/components/animate-slide/MPAnimateSlide.d.ts +1 -1
- package/dist/components/animate-slide/MPAnimateSlide.js +1 -1
- package/dist/components/animate-slide/index.d.ts +2 -2
- package/dist/components/animate-slide/index.js +1 -1
- package/dist/components/animate-typing/MPAnimateTyping.d.ts +1 -1
- package/dist/components/animate-typing/MPAnimateTyping.js +2 -1
- package/dist/components/animate-typing/index.d.ts +2 -2
- package/dist/components/animate-typing/index.js +1 -1
- package/dist/components/animate-zoom/MPAnimateZoom.d.ts +1 -1
- package/dist/components/animate-zoom/MPAnimateZoom.js +1 -1
- package/dist/components/animate-zoom/index.d.ts +2 -2
- package/dist/components/animate-zoom/index.js +1 -1
- package/dist/components/aspect-ratio/MPAspectRatio.d.ts +1 -1
- package/dist/components/aspect-ratio/MPAspectRatio.js +1 -1
- package/dist/components/aspect-ratio/index.d.ts +2 -2
- package/dist/components/aspect-ratio/index.js +1 -1
- package/dist/components/avatar/MPAvatar.d.ts +1 -1
- package/dist/components/avatar/MPAvatar.js +2 -1
- package/dist/components/avatar/index.d.ts +2 -2
- package/dist/components/avatar/index.js +1 -1
- package/dist/components/badge/MPBadge.d.ts +1 -1
- package/dist/components/badge/MPBadge.js +2 -1
- package/dist/components/badge/index.d.ts +2 -2
- package/dist/components/badge/index.js +1 -1
- package/dist/components/blockquote/MPBlockquote.d.ts +1 -1
- package/dist/components/blockquote/MPBlockquote.js +2 -1
- package/dist/components/blockquote/index.d.ts +2 -2
- package/dist/components/blockquote/index.js +1 -1
- package/dist/components/bottom-navigation/MPBottomNavigation.d.ts +1 -1
- package/dist/components/bottom-navigation/MPBottomNavigation.js +2 -1
- package/dist/components/bottom-navigation/index.d.ts +2 -2
- package/dist/components/bottom-navigation/index.js +1 -1
- package/dist/components/box/MPBox.d.ts +1 -1
- package/dist/components/box/MPBox.js +1 -1
- package/dist/components/box/index.d.ts +2 -2
- package/dist/components/box/index.js +1 -1
- package/dist/components/breadcrumb/MPBreadcrumb.d.ts +1 -1
- package/dist/components/breadcrumb/MPBreadcrumb.js +2 -1
- package/dist/components/breadcrumb/index.d.ts +2 -2
- package/dist/components/breadcrumb/index.js +1 -1
- package/dist/components/button/MPButton.d.ts +1 -1
- package/dist/components/button/MPButton.js +2 -1
- package/dist/components/button/index.d.ts +2 -2
- package/dist/components/button/index.js +1 -1
- package/dist/components/button-group/MPButtonGroup.d.ts +1 -1
- package/dist/components/button-group/MPButtonGroup.js +2 -1
- package/dist/components/button-group/index.d.ts +2 -2
- package/dist/components/button-group/index.js +1 -1
- package/dist/components/card/MPCard.d.ts +1 -1
- package/dist/components/card/MPCard.js +2 -1
- package/dist/components/card/index.d.ts +2 -2
- package/dist/components/card/index.js +1 -1
- package/dist/components/carousel/MPCarousel.d.ts +1 -1
- package/dist/components/carousel/MPCarousel.js +2 -1
- package/dist/components/carousel/index.d.ts +2 -2
- package/dist/components/carousel/index.js +1 -1
- package/dist/components/chat-bubble/MPChatBubble.d.ts +1 -1
- package/dist/components/chat-bubble/MPChatBubble.js +2 -1
- package/dist/components/chat-bubble/index.d.ts +2 -2
- package/dist/components/chat-bubble/index.js +1 -1
- package/dist/components/checkbox/MPCheckbox.d.ts +1 -1
- package/dist/components/checkbox/MPCheckbox.js +2 -1
- package/dist/components/checkbox/index.d.ts +2 -2
- package/dist/components/checkbox/index.js +1 -1
- package/dist/components/chip/MPChip.d.ts +1 -1
- package/dist/components/chip/MPChip.js +2 -1
- package/dist/components/chip/index.d.ts +2 -2
- package/dist/components/chip/index.js +1 -1
- package/dist/components/collapsible/MPCollapsible.d.ts +1 -1
- package/dist/components/collapsible/MPCollapsible.js +2 -1
- package/dist/components/collapsible/index.d.ts +2 -2
- package/dist/components/collapsible/index.js +1 -1
- package/dist/components/color-picker/MPColorPicker.d.ts +2 -2
- package/dist/components/color-picker/MPColorPicker.js +2 -1
- package/dist/components/color-picker/index.d.ts +2 -2
- package/dist/components/color-picker/index.js +1 -1
- package/dist/components/combobox/MPCombobox.d.ts +1 -1
- package/dist/components/combobox/MPCombobox.js +2 -1
- package/dist/components/combobox/index.d.ts +2 -2
- package/dist/components/combobox/index.js +1 -1
- package/dist/components/container/MPContainer.d.ts +1 -1
- package/dist/components/container/MPContainer.js +1 -1
- package/dist/components/container/index.d.ts +2 -2
- package/dist/components/container/index.js +1 -1
- package/dist/components/date-picker/MPDatePicker.d.ts +3 -3
- package/dist/components/date-picker/MPDatePicker.js +2 -1
- package/dist/components/date-picker/index.d.ts +2 -2
- package/dist/components/date-picker/index.js +1 -1
- package/dist/components/date-range-picker/MPDateRangePicker.d.ts +3 -3
- package/dist/components/date-range-picker/MPDateRangePicker.js +2 -1
- package/dist/components/date-range-picker/index.d.ts +2 -2
- package/dist/components/date-range-picker/index.js +1 -1
- package/dist/components/date-time-picker/MPDateTimePicker.d.ts +4 -4
- package/dist/components/date-time-picker/MPDateTimePicker.js +2 -1
- package/dist/components/date-time-picker/index.d.ts +2 -2
- package/dist/components/date-time-picker/index.js +1 -1
- package/dist/components/dialog/MPDialog.d.ts +1 -1
- package/dist/components/dialog/MPDialog.js +2 -1
- package/dist/components/dialog/index.d.ts +2 -2
- package/dist/components/dialog/index.js +1 -1
- package/dist/components/divider/MPDivider.d.ts +1 -1
- package/dist/components/divider/MPDivider.js +2 -1
- package/dist/components/divider/index.d.ts +2 -2
- package/dist/components/divider/index.js +1 -1
- package/dist/components/drawer/MPDrawer.d.ts +1 -1
- package/dist/components/drawer/MPDrawer.js +2 -1
- package/dist/components/drawer/index.d.ts +2 -2
- package/dist/components/drawer/index.js +1 -1
- package/dist/components/empty/MPEmpty.d.ts +1 -1
- package/dist/components/empty/MPEmpty.js +2 -1
- package/dist/components/empty/index.d.ts +2 -2
- package/dist/components/empty/index.js +1 -1
- package/dist/components/file-picker/MPFilePicker.d.ts +1 -1
- package/dist/components/file-picker/MPFilePicker.js +2 -1
- package/dist/components/file-picker/index.d.ts +2 -2
- package/dist/components/file-picker/index.js +1 -1
- package/dist/components/floating-action-button/MPFloatingActionButton.d.ts +1 -1
- package/dist/components/floating-action-button/MPFloatingActionButton.js +2 -1
- package/dist/components/floating-action-button/index.d.ts +2 -2
- package/dist/components/floating-action-button/index.js +1 -1
- package/dist/components/grid/MPGrid.d.ts +1 -1
- package/dist/components/grid/MPGrid.js +2 -1
- package/dist/components/grid/index.d.ts +2 -2
- package/dist/components/grid/index.js +1 -1
- package/dist/components/highlight/MPHighlight.d.ts +2 -2
- package/dist/components/highlight/MPHighlight.js +2 -1
- package/dist/components/highlight/index.d.ts +2 -2
- package/dist/components/highlight/index.js +1 -1
- package/dist/components/icon/MPIcon.d.ts +1 -1
- package/dist/components/icon/MPIcon.js +2 -1
- package/dist/components/icon/index.d.ts +2 -2
- package/dist/components/icon/index.js +1 -1
- package/dist/components/icon-button/MPIconButton.d.ts +1 -1
- package/dist/components/icon-button/MPIconButton.js +2 -1
- package/dist/components/icon-button/index.d.ts +2 -2
- package/dist/components/icon-button/index.js +1 -1
- package/dist/components/list/MPList.d.ts +1 -1
- package/dist/components/list/MPList.js +2 -1
- package/dist/components/list/index.d.ts +2 -2
- package/dist/components/list/index.js +1 -1
- package/dist/components/locale/MPLocaleProvider.d.ts +1 -1
- package/dist/components/locale/MPLocaleProvider.js +2 -1
- package/dist/components/locale/index.d.ts +2 -2
- package/dist/components/locale/index.js +1 -1
- package/dist/components/menu/MPMenu.d.ts +1 -1
- package/dist/components/menu/MPMenu.js +2 -1
- package/dist/components/menu/index.d.ts +2 -2
- package/dist/components/menu/index.js +1 -1
- package/dist/components/number-field/MPNumberField.d.ts +1 -1
- package/dist/components/number-field/MPNumberField.js +2 -1
- package/dist/components/number-field/index.d.ts +2 -2
- package/dist/components/number-field/index.js +1 -1
- package/dist/components/otp-field/MPOtpField.d.ts +1 -1
- package/dist/components/otp-field/MPOtpField.js +2 -1
- package/dist/components/otp-field/index.d.ts +2 -2
- package/dist/components/otp-field/index.js +1 -1
- package/dist/components/overlay/MPOverlay.d.ts +1 -1
- package/dist/components/overlay/MPOverlay.js +2 -1
- package/dist/components/overlay/index.d.ts +2 -2
- package/dist/components/overlay/index.js +1 -1
- package/dist/components/pagination/MPPagination.d.ts +2 -2
- package/dist/components/pagination/MPPagination.js +2 -1
- package/dist/components/pagination/index.d.ts +2 -2
- package/dist/components/pagination/index.js +1 -1
- package/dist/components/panes/MPPanes.d.ts +1 -1
- package/dist/components/panes/MPPanes.js +2 -1
- package/dist/components/panes/index.d.ts +2 -2
- package/dist/components/panes/index.js +1 -1
- package/dist/components/pill/MPPill.d.ts +1 -1
- package/dist/components/pill/MPPill.js +2 -1
- package/dist/components/pill/index.d.ts +2 -2
- package/dist/components/pill/index.js +1 -1
- package/dist/components/popover/MPPopover.d.ts +1 -1
- package/dist/components/popover/MPPopover.js +2 -1
- package/dist/components/popover/index.d.ts +2 -2
- package/dist/components/popover/index.js +1 -1
- package/dist/components/progress-box/MPProgressBox.d.ts +2 -2
- package/dist/components/progress-box/MPProgressBox.js +2 -1
- package/dist/components/progress-box/index.d.ts +2 -2
- package/dist/components/progress-box/index.js +1 -1
- package/dist/components/progress-circular/MPProgressCircular.d.ts +2 -2
- package/dist/components/progress-circular/MPProgressCircular.js +2 -1
- package/dist/components/progress-circular/index.d.ts +2 -2
- package/dist/components/progress-circular/index.js +1 -1
- package/dist/components/progress-linear/MPProgressLinear.d.ts +2 -2
- package/dist/components/progress-linear/MPProgressLinear.js +2 -1
- package/dist/components/progress-linear/index.d.ts +2 -2
- package/dist/components/progress-linear/index.js +1 -1
- package/dist/components/radio-group/MPRadioGroup.d.ts +1 -1
- package/dist/components/radio-group/MPRadioGroup.js +2 -1
- package/dist/components/radio-group/index.d.ts +2 -2
- package/dist/components/radio-group/index.js +1 -1
- package/dist/components/rating/MPRating.d.ts +2 -2
- package/dist/components/rating/MPRating.js +2 -1
- package/dist/components/rating/index.d.ts +2 -2
- package/dist/components/rating/index.js +1 -1
- package/dist/components/segmented-button/MPSegmentedButton.d.ts +1 -1
- package/dist/components/segmented-button/MPSegmentedButton.js +2 -1
- package/dist/components/segmented-button/index.d.ts +2 -2
- package/dist/components/segmented-button/index.js +1 -1
- package/dist/components/select/MPSelect.d.ts +1 -1
- package/dist/components/select/MPSelect.js +2 -1
- package/dist/components/select/index.d.ts +2 -2
- package/dist/components/select/index.js +1 -1
- package/dist/components/shortcut/MPShortcut.d.ts +1 -1
- package/dist/components/shortcut/MPShortcut.js +2 -1
- package/dist/components/shortcut/index.d.ts +2 -2
- package/dist/components/shortcut/index.js +1 -1
- package/dist/components/skeleton/MPSkeleton.d.ts +1 -1
- package/dist/components/skeleton/MPSkeleton.js +2 -1
- package/dist/components/skeleton/index.d.ts +2 -2
- package/dist/components/skeleton/index.js +1 -1
- package/dist/components/slider/MPSlider.d.ts +1 -1
- package/dist/components/slider/MPSlider.js +2 -1
- package/dist/components/slider/index.d.ts +2 -2
- package/dist/components/slider/index.js +1 -1
- package/dist/components/snackbar/MPSnackbar.d.ts +1 -1
- package/dist/components/snackbar/MPSnackbar.js +2 -1
- package/dist/components/snackbar/index.d.ts +2 -2
- package/dist/components/snackbar/index.js +1 -1
- package/dist/components/spoiler/MPSpoiler.d.ts +1 -1
- package/dist/components/spoiler/MPSpoiler.js +2 -1
- package/dist/components/spoiler/index.d.ts +2 -2
- package/dist/components/spoiler/index.js +1 -1
- package/dist/components/switch/MPSwitch.d.ts +1 -1
- package/dist/components/switch/MPSwitch.js +2 -1
- package/dist/components/switch/index.d.ts +2 -2
- package/dist/components/switch/index.js +1 -1
- package/dist/components/table/MPTable.d.ts +1 -1
- package/dist/components/table/MPTable.js +2 -1
- package/dist/components/table/index.d.ts +2 -2
- package/dist/components/table/index.js +1 -1
- package/dist/components/tabs/MPTabs.d.ts +1 -1
- package/dist/components/tabs/MPTabs.js +2 -1
- package/dist/components/tabs/index.d.ts +2 -2
- package/dist/components/tabs/index.js +1 -1
- package/dist/components/text-field/MPTextField.d.ts +2 -2
- package/dist/components/text-field/MPTextField.js +2 -1
- package/dist/components/text-field/index.d.ts +2 -2
- package/dist/components/text-field/index.js +1 -1
- package/dist/components/text-link/MPTextLink.d.ts +1 -1
- package/dist/components/text-link/MPTextLink.js +2 -1
- package/dist/components/text-link/index.d.ts +2 -2
- package/dist/components/text-link/index.js +1 -1
- package/dist/components/time-picker/MPTimePicker.d.ts +3 -3
- package/dist/components/time-picker/MPTimePicker.js +2 -1
- package/dist/components/time-picker/index.d.ts +2 -2
- package/dist/components/time-picker/index.js +1 -1
- package/dist/components/timeline/MPTimeline.d.ts +1 -1
- package/dist/components/timeline/MPTimeline.js +2 -1
- package/dist/components/timeline/index.d.ts +2 -2
- package/dist/components/timeline/index.js +1 -1
- package/dist/components/tooltip/MPTooltip.d.ts +1 -1
- package/dist/components/tooltip/MPTooltip.js +2 -1
- package/dist/components/tooltip/index.d.ts +2 -2
- package/dist/components/tooltip/index.js +1 -1
- package/dist/components/typography/MPTypography.d.ts +1 -1
- package/dist/components/typography/MPTypography.js +2 -1
- package/dist/components/typography/index.d.ts +2 -2
- package/dist/components/typography/index.js +1 -1
- package/dist/constants/glyphs.d.ts +62 -0
- package/dist/constants/glyphs.js +2 -0
- package/dist/constants/icons.d.ts +31 -60
- package/dist/constants/icons.js +1 -1
- package/dist/index.d.ts +78 -77
- package/dist/index.js +1 -1
- package/dist/internal/Calendar.d.ts +3 -3
- package/dist/internal/Calendar.js +2 -1
- package/dist/internal/FieldOutline.d.ts +1 -1
- package/dist/internal/FieldOutline.js +2 -1
- package/dist/internal/Picker.d.ts +2 -2
- package/dist/internal/Picker.js +2 -1
- package/dist/internal/StateLayer.js +1 -0
- package/dist/internal/SupportingText.js +2 -1
- package/dist/internal/WidthSizer.js +1 -0
- package/dist/internal/accent.d.ts +1 -1
- package/dist/internal/animate.d.ts +1 -1
- package/dist/internal/animate.js +1 -0
- package/dist/internal/button-group.d.ts +1 -1
- package/dist/internal/button-group.js +2 -1
- package/dist/internal/date.d.ts +1 -1
- package/dist/internal/i18n.d.ts +100 -5
- package/dist/internal/i18n.js +1 -1
- package/dist/internal/locale.d.ts +8 -3
- package/dist/internal/locale.js +2 -1
- package/dist/internal/menu.d.ts +1 -1
- package/dist/internal/menu.js +2 -1
- package/dist/internal/messages/alert.d.ts +3 -0
- package/dist/internal/messages/alert.js +1 -0
- package/dist/internal/messages/chat.d.ts +3 -0
- package/dist/internal/messages/chat.js +1 -0
- package/dist/internal/messages/common.d.ts +3 -0
- package/dist/internal/messages/common.js +1 -0
- package/dist/internal/messages/empty.d.ts +3 -0
- package/dist/internal/messages/empty.js +1 -0
- package/dist/internal/messages/pagination.d.ts +3 -0
- package/dist/internal/messages/pagination.js +1 -0
- package/dist/internal/messages/picker.d.ts +3 -0
- package/dist/internal/messages/picker.js +1 -0
- package/dist/internal/messages/rating.d.ts +3 -0
- package/dist/internal/messages/rating.js +1 -0
- package/dist/internal/messages/spoiler.d.ts +3 -0
- package/dist/internal/messages/spoiler.js +1 -0
- package/dist/internal/messages/text-field.d.ts +3 -0
- package/dist/internal/messages/text-field.js +1 -0
- package/dist/internal/progress.d.ts +1 -1
- package/dist/internal/scale.d.ts +1 -1
- package/dist/internal/surface.d.ts +1 -1
- package/dist/internal/surface.js +1 -1
- package/dist/locales/ar.d.ts +17 -0
- package/dist/locales/ar.js +1 -0
- package/dist/locales/de.d.ts +17 -0
- package/dist/locales/de.js +1 -0
- package/dist/locales/es.d.ts +17 -0
- package/dist/locales/es.js +1 -0
- package/dist/locales/fr.d.ts +17 -0
- package/dist/locales/fr.js +1 -0
- package/dist/locales/hi.d.ts +17 -0
- package/dist/locales/hi.js +1 -0
- package/dist/locales/id.d.ts +17 -0
- package/dist/locales/id.js +1 -0
- package/dist/locales/index.d.ts +89 -0
- package/dist/locales/index.js +1 -0
- package/dist/locales/it.d.ts +17 -0
- package/dist/locales/it.js +1 -0
- package/dist/locales/ja.d.ts +17 -0
- package/dist/locales/ja.js +1 -0
- package/dist/locales/ko.d.ts +17 -0
- package/dist/locales/ko.js +1 -0
- package/dist/locales/nl.d.ts +17 -0
- package/dist/locales/nl.js +1 -0
- package/dist/locales/pl.d.ts +17 -0
- package/dist/locales/pl.js +1 -0
- package/dist/locales/pt.d.ts +17 -0
- package/dist/locales/pt.js +1 -0
- package/dist/locales/ru.d.ts +17 -0
- package/dist/locales/ru.js +1 -0
- package/dist/locales/th.d.ts +17 -0
- package/dist/locales/th.js +1 -0
- package/dist/locales/tr.d.ts +17 -0
- package/dist/locales/tr.js +1 -0
- package/dist/locales/vi.d.ts +17 -0
- package/dist/locales/vi.js +1 -0
- package/dist/locales/zh-hans.d.ts +21 -0
- package/dist/locales/zh-hans.js +1 -0
- package/dist/locales/zh-hant.d.ts +20 -0
- package/dist/locales/zh-hant.js +1 -0
- package/dist/styles/accordion.css +2 -0
- package/dist/styles/alert.css +2 -0
- package/dist/styles/animate-appear.css +2 -0
- package/dist/styles/animate-blink.css +2 -0
- package/dist/styles/animate-fade.css +2 -0
- package/dist/styles/animate-grow.css +2 -0
- package/dist/styles/animate-headline.css +2 -0
- package/dist/styles/animate-lighting.css +2 -0
- package/dist/styles/animate-marquee.css +2 -0
- package/dist/styles/animate-rotate.css +2 -0
- package/dist/styles/animate-slide.css +2 -0
- package/dist/styles/animate-typing.css +2 -0
- package/dist/styles/animate-zoom.css +2 -0
- package/dist/styles/aspect-ratio.css +2 -0
- package/dist/styles/avatar.css +2 -0
- package/dist/styles/badge.css +2 -0
- package/dist/styles/blockquote.css +2 -0
- package/dist/styles/bottom-navigation.css +2 -0
- package/dist/styles/box.css +2 -0
- package/dist/styles/breadcrumb.css +2 -0
- package/dist/styles/button-group.css +2 -0
- package/dist/styles/button.css +2 -0
- package/dist/styles/card.css +2 -0
- package/dist/styles/carousel.css +2 -0
- package/dist/styles/chat-bubble.css +2 -0
- package/dist/styles/checkbox.css +2 -0
- package/dist/styles/chip.css +2 -0
- package/dist/styles/collapsible.css +2 -0
- package/dist/styles/color-picker.css +2 -0
- package/dist/styles/combobox.css +2 -0
- package/dist/styles/container.css +2 -0
- package/dist/styles/date-picker.css +2 -0
- package/dist/styles/date-range-picker.css +2 -0
- package/dist/styles/date-time-picker.css +2 -0
- package/dist/styles/dialog.css +2 -0
- package/dist/styles/divider.css +2 -0
- package/dist/styles/drawer.css +2 -0
- package/dist/styles/empty.css +2 -0
- package/dist/styles/file-picker.css +2 -0
- package/dist/styles/floating-action-button.css +2 -0
- package/dist/styles/grid.css +2 -0
- package/dist/styles/highlight.css +2 -0
- package/dist/styles/icon-button.css +2 -0
- package/dist/styles/icon.css +2 -0
- package/dist/styles/list.css +2 -0
- package/dist/styles/locale.css +2 -0
- package/dist/styles/menu.css +2 -0
- package/dist/styles/number-field.css +2 -0
- package/dist/styles/otp-field.css +2 -0
- package/dist/styles/overlay.css +2 -0
- package/dist/styles/pagination.css +2 -0
- package/dist/styles/panes.css +2 -0
- package/dist/styles/pill.css +2 -0
- package/dist/styles/popover.css +2 -0
- package/dist/styles/progress-box.css +2 -0
- package/dist/styles/progress-circular.css +2 -0
- package/dist/styles/progress-linear.css +2 -0
- package/dist/styles/radio-group.css +2 -0
- package/dist/styles/rating.css +2 -0
- package/dist/styles/segmented-button.css +2 -0
- package/dist/styles/select.css +2 -0
- package/dist/styles/shortcut.css +2 -0
- package/dist/styles/skeleton.css +2 -0
- package/dist/styles/slider.css +2 -0
- package/dist/styles/snackbar.css +2 -0
- package/dist/styles/spoiler.css +2 -0
- package/dist/styles/switch.css +2 -0
- package/dist/styles/table.css +2 -0
- package/dist/styles/tabs.css +2 -0
- package/dist/styles/text-field.css +2 -0
- package/dist/styles/text-link.css +2 -0
- package/dist/styles/time-picker.css +2 -0
- package/dist/styles/timeline.css +2 -0
- package/dist/styles/tokens.css +2 -0
- package/dist/styles/tooltip.css +2 -0
- package/dist/styles/typography.css +2 -0
- package/package.json +31 -10
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as e,jsxs as t}from"react/jsx-runtime";import*as a from"react";import{accentSlots as r}from"../../internal/accent.js";import{hasContent as n,META_TEXT as i,SHEET_PAD as l}from"../../internal/scale.js";const o={xs:"text-mp-body-medium",sm:"text-mp-body-large",md:"text-mp-title-large",lg:"text-mp-headline-small",xl:"text-mp-headline-medium"},c="border-s-2 [border-inline-start-color:var(--_mp-accent)]",s={filled:"bg-(--_mp-accent) text-(--_mp-on-accent)",tonal:"bg-(--_mp-accent-container) text-(--_mp-on-accent-container)",elevated:"shadow-mp-1 bg-mp-surface-container-low text-mp-on-surface",outlined:"border-mp-outline-variant border border-s-2 bg-transparent text-mp-on-surface",text:"bg-transparent text-mp-on-surface"};function m(){return e("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",className:"size-full",children:e("path",{d:"M6.4 3.6c-2.3.9-3.7 2.8-3.7 5.1 0 2 1.2 3.3 2.8 3.3 1.4 0 2.5-1 2.5-2.4 0-1.3-.9-2.2-2.1-2.2-.2 0-.4 0-.6.1.3-1 1.1-1.8 2.2-2.3l-1.1-1.6ZM13.3 3.6c-2.3.9-3.7 2.8-3.7 5.1 0 2 1.2 3.3 2.8 3.3 1.4 0 2.5-1 2.5-2.4 0-1.3-.9-2.2-2.1-2.2-.2 0-.4 0-.6.1.3-1 1.1-1.8 2.2-2.3l-1.1-1.6Z",fill:"currentColor"})})}export const MPBlockquote=/*@__PURE__*/a.forwardRef(function({variant:a="text",size:d="md",color:p="primary",author:u,source:f,cite:x,icon:h,className:b,style:g,children:v,...y},N){const j=n(u)||n(f),w=void 0===h?e(m,{}):h,z="text"!==a,_=["mp-blockquote flex flex-col",o[d],c,z?"rounded-mp-md rounded-s-none":"",s[a],z?l[d]:"ps-4",b??""].filter(Boolean).join(" "),k=t("blockquote",{cite:x,children:[n(w)?e("span",{"aria-hidden":"true",className:"mb-1 block size-[2em] opacity-38",children:w}):null,v]}),q={...r(p),...g};return j?t("figure",{ref:N,"data-mp-size":d,"data-mp-variant":a,className:_,style:q,...y,children:[k,t("figcaption",{className:["mt-2 flex flex-wrap items-baseline gap-x-1.5",z?"opacity-80":"text-mp-on-surface-variant",i].join(" "),children:[n(u)?t("span",{className:"font-medium",children:[e("span",{"aria-hidden":"true",children:"— "}),u]}):null,n(f)?e("cite",{className:"not-italic",children:f}):null]})]}):e("div",{ref:N,"data-mp-size":d,"data-mp-variant":a,className:_,style:q,...y,children:k})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPBlockquote } from './MPBlockquote';
|
|
2
|
-
export type { MPBlockquoteProps } from './MPBlockquote';
|
|
1
|
+
export { MPBlockquote } from './MPBlockquote.js';
|
|
2
|
+
export type { MPBlockquoteProps } from './MPBlockquote.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPBlockquote}from"./MPBlockquote";
|
|
1
|
+
export{MPBlockquote}from"./MPBlockquote.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { useRender } from '@base-ui/react/use-render';
|
|
3
|
-
import type { MPPosition, MPSize } from '../../types';
|
|
3
|
+
import type { MPPosition, MPSize } from '../../types.js';
|
|
4
4
|
/** A destination's value. The same restraint `MPTabs` puts on a tab's. */
|
|
5
5
|
export type MPBottomNavigationValue = string | number;
|
|
6
6
|
/**
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as e,jsxs as t,Fragment as a}from"react/jsx-runtime";import*as l from"react";import{useRender as n}from"@base-ui/react/use-render";import{MPStateLayer as o}from"../../internal/StateLayer.js";import{hasContent as s}from"../../internal/scale.js";import{VISUALLY_HIDDEN as i}from"../../internal/visually-hidden.js";const r=/*@__PURE__*/l.createContext({value:null,change:()=>{},size:"md",labels:"all",disabled:!1}),m={xs:"h-14",sm:"h-16",md:"h-20",lg:"h-22",xl:"h-24"},d={xs:{box:"h-6 w-12",open:"w-12",shut:"w-6"},sm:{box:"h-7 w-14",open:"w-14",shut:"w-7"},md:{box:"h-8 w-16",open:"w-16",shut:"w-8"},lg:{box:"h-9 w-18",open:"w-18",shut:"w-9"},xl:{box:"h-10 w-20",open:"w-20",shut:"w-10"}},u={xs:20,sm:22,md:24,lg:26,xl:28},c={xs:"text-mp-label-small",sm:"text-mp-label-small",md:"text-mp-label-medium",lg:"text-mp-label-medium",xl:"text-mp-label-large"},p={xs:"gap-0.5",sm:"gap-0.5",md:"gap-1",lg:"gap-1",xl:"gap-1.5"},f={static:"",absolute:"absolute inset-x-0 bottom-0 z-30",sticky:"sticky bottom-0 z-30",fixed:"fixed inset-x-0 bottom-0 z-40"};export const MPBottomNavigation=/*@__PURE__*/l.forwardRef(function({value:t,defaultValue:a=null,onValueChange:o,position:s="fixed",labels:i="all",size:d="md",divider:u=!1,safeArea:c=!0,disabled:p=!1,label:b,render:x,className:h,children:v,...g},w){const[y,z]=l.useState(a),j=void 0!==t,N=j?t:y,k=l.useCallback(e=>{j||z(e),o?.(e)},[j,o]),C=l.useMemo(()=>({value:N??null,change:k,size:d,labels:i,disabled:p}),[N,k,d,i,p]);return n({render:x??e("nav",{}),ref:w,props:{"aria-label":b,"data-mp-size":d,className:["mp-bottom-navigation bg-mp-surface-container text-mp-on-surface box-border w-full",u?"border-mp-outline-variant border-t":"",f[s],c?"pb-[env(safe-area-inset-bottom)]":"",h??""].filter(Boolean).join(" "),children:e(r.Provider,{value:C,children:e("div",{className:`flex w-full items-stretch ${m[d]}`,children:v})}),...g}})});export const MPBottomNavigationItem=/*@__PURE__*/l.forwardRef(function({value:n,icon:m,activeIcon:f,href:b,disabled:x=!1,className:h,children:v,onClick:g,...w},y){const z=l.useContext(r),j=x||z.disabled,N=null!==z.value&&z.value===n,k="all"===z.labels||"selected"===z.labels&&N,C=["mp-bottom-navigation__item group flex min-w-0 flex-1 flex-col items-center justify-center","box-border appearance-none bg-transparent px-1 font-[inherit] no-underline select-none",p[z.size],"outline-mp-secondary focus-visible:outline-2 focus-visible:-outline-offset-2","focus-visible:outline-solid outline-none",j?"text-mp-on-surface/38 cursor-default":N?"text-mp-on-surface cursor-pointer":"text-mp-on-surface-variant cursor-pointer",h??""].filter(Boolean).join(" "),B=t(a,{children:[s(m)||s(f)?t("span",{className:["relative flex shrink-0 items-center justify-center overflow-hidden","rounded-mp-full","transition-[color] duration-(--mp-sys-motion-duration-short4)",d[z.size].box,N&&!j?"text-mp-on-secondary-container":""].filter(Boolean).join(" "),children:[j?null:e("span",{"aria-hidden":"true",className:["pointer-events-none absolute inset-y-0 left-1/2 -translate-x-1/2","rounded-mp-full bg-mp-secondary-container","transition-[width,opacity] duration-(--mp-sys-motion-duration-short4)","ease-mp-standard",N?`${d[z.size].open} opacity-100`:`${d[z.size].shut} opacity-0`].join(" ")}),j?null:e(o,{}),e("span",{className:"relative flex items-center justify-center",style:{width:u[z.size],height:u[z.size]},children:N?f??m:m})]}):null,s(v)?e("span",{className:k?`max-w-full truncate ${c[z.size]}`:i,children:v}):null]}),$=e=>{j?e.preventDefault():(z.change(n),g?.(e))};return b?e("a",{ref:y,href:j?void 0:b,"aria-current":N?"page":void 0,"aria-disabled":j||void 0,className:C,onClick:$,...w,children:B}):e("button",{ref:y,type:"button",disabled:j,"aria-current":N?"page":void 0,className:C,onClick:$,...w,children:B})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPBottomNavigation, MPBottomNavigationItem } from './MPBottomNavigation';
|
|
2
|
-
export type { MPBottomNavigationItemProps, MPBottomNavigationLabels, MPBottomNavigationProps, MPBottomNavigationValue } from './MPBottomNavigation';
|
|
1
|
+
export { MPBottomNavigation, MPBottomNavigationItem } from './MPBottomNavigation.js';
|
|
2
|
+
export type { MPBottomNavigationItemProps, MPBottomNavigationLabels, MPBottomNavigationProps, MPBottomNavigationValue } from './MPBottomNavigation.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPBottomNavigation,MPBottomNavigationItem}from"./MPBottomNavigation";
|
|
1
|
+
export{MPBottomNavigation,MPBottomNavigationItem}from"./MPBottomNavigation.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
2
|
import { useRender } from '@base-ui/react/use-render';
|
|
3
|
-
import type { MPSize, MPVariant } from '../../types';
|
|
3
|
+
import type { MPSize, MPVariant } from '../../types.js';
|
|
4
4
|
export interface MPBoxProps extends React.ComponentPropsWithoutRef<'div'> {
|
|
5
5
|
/**
|
|
6
6
|
* How much surface the sheet paints.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import*as r from"react";import{useRender as e}from"@base-ui/react/use-render";import{SHEET_PAD as a}from"../../internal/scale";import{CONTAINER_SURFACE as o}from"../../internal/surface";export const MPBox
|
|
1
|
+
import*as r from"react";import{useRender as e}from"@base-ui/react/use-render";import{SHEET_PAD as a}from"../../internal/scale.js";import{CONTAINER_SURFACE as o}from"../../internal/surface.js";export const MPBox=/*@__PURE__*/r.forwardRef(function({variant:r="outlined",size:n="md",padded:t=!0,render:d,className:i,children:m,...s},p){return e({render:d,ref:p,props:{"data-mp-size":n,"data-mp-variant":r,className:["mp-box rounded-mp-md block","box-border",t?a[n]:"",o[r],"text-mp-on-surface",i??""].filter(Boolean).join(" "),children:m,...s}})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPBox } from './MPBox';
|
|
2
|
-
export type { MPBoxProps } from './MPBox';
|
|
1
|
+
export { MPBox } from './MPBox.js';
|
|
2
|
+
export type { MPBoxProps } from './MPBox.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPBox}from"./MPBox";
|
|
1
|
+
export{MPBox}from"./MPBox.js";
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as e,jsxs as n,Fragment as t}from"react/jsx-runtime";import*as r from"react";import{MPIcon as o}from"../icon/MPIcon.js";import{ArrowRightIcon as i,ChevronRightIcon as a,MoreIcon as s}from"../../constants/icons.js";import{accentSlots as l}from"../../internal/accent.js";import{CONTROL_GAP as c,hasContent as m,PROSE_TEXT as d}from"../../internal/scale.js";const u=/*@__PURE__*/r.createContext({size:"md",last:!1,position:null}),p={xs:"gap-1",sm:"gap-1.5",md:"gap-2",lg:"gap-2.5",xl:"gap-3"},h={xs:"rounded-mp-xs",sm:"rounded-mp-xs",md:"rounded-mp-xs",lg:"rounded-mp-sm",xl:"rounded-mp-sm"};const f=["chevron","arrow","slash","dot"];export const MPBreadcrumb=/*@__PURE__*/r.forwardRef(function({size:t="md",color:c="primary",separator:m="chevron",maxItems:h,itemsBeforeCollapse:x=1,itemsAfterCollapse:b=1,expandable:v=!0,label:g="Breadcrumb",expandLabel:N="Show hidden steps",structuredData:y=!1,className:j,style:k,children:B,...w},z){const[C,P]=r.useState(!1),M=r.Children.toArray(B).filter(r.isValidElement),I=M.length,S=M.some(e=>!0===e.props.current),L=!C&&!y&&void 0!==h&&I>Math.max(h,1)&&I-x-b>1?[...M.slice(0,Math.max(0,x)),null,...M.slice(I-Math.max(0,b))]:M,_="string"==typeof(A=m)&&f.includes(A)?function(n){switch(n){case"chevron":return e(o,{icon:a,size:"1.1em",className:"rtl:rotate-180"});case"arrow":return e(o,{icon:i,size:"1em",className:"rtl:rotate-180"});case"slash":return e("span",{"aria-hidden":"true",children:"/"});case"dot":return e("span",{"aria-hidden":"true",children:"·"});default:return null}}(m):m;var A;const E=r.useMemo(()=>Array.from({length:L.length},(e,n)=>({size:t,last:!S&&n===L.length-1,position:y?n+1:null})),[t,S,L.length,y]),F=["rounded-mp-xs text-mp-on-surface-variant inline-flex items-center px-0.5","appearance-none border-0 bg-transparent font-[inherit]","transition-[background-color,color] duration-(--mp-sys-motion-duration-short4)",v?["cursor-pointer hover:bg-(--_mp-accent-container) hover:text-(--_mp-on-accent-container)","outline-mp-secondary focus-visible:outline-2 focus-visible:outline-offset-1","focus-visible:outline-solid outline-none"].join(" "):""].filter(Boolean).join(" ");return e("nav",{ref:z,"aria-label":g,"data-mp-size":t,className:["mp-breadcrumb flex",d[t],j??""].filter(Boolean).join(" "),style:{...l(c),...k},...w,children:e("ol",{role:"list",itemScope:y||void 0,itemType:y?"https://schema.org/BreadcrumbList":void 0,className:`flex list-none flex-wrap items-center p-0 ${p[t]}`,children:L.map((t,i)=>n(r.Fragment,{children:[i>0?e("li",{"aria-hidden":"true",className:"text-mp-on-surface-variant flex shrink-0 items-center select-none",children:_}):null,t?e(u.Provider,{value:E[i],children:t}):e("li",{className:"flex shrink-0 items-center",children:v?e("button",{type:"button",className:F,"aria-label":N,onClick:()=>P(!0),children:e(o,{icon:s,size:"1.1em"})}):e("span",{className:F,"aria-hidden":"true",children:e(o,{icon:s,size:"1.1em"})})})]},t?t.key??i:"fold"))})})});export const MPBreadcrumbItem=/*@__PURE__*/r.forwardRef(function({href:o,onClick:i,startIcon:a,endIcon:s,current:l,disabled:d=!1,className:p,children:f,...x},b){const{size:v,last:g,position:N}=r.useContext(u),y=l??g,j=Boolean(o||i)&&!y&&!d,k=null!==N,B=["inline-flex min-w-0 items-center px-1 no-underline","appearance-none border-0 bg-transparent font-[inherit] text-[inherit]",c[v],h[v],"transition-[background-color,color] duration-(--mp-sys-motion-duration-short4)",d?"text-mp-on-surface/38 cursor-default":y?"text-mp-on-surface font-medium":j?["text-mp-on-surface-variant cursor-pointer","hover:bg-(--_mp-accent-container) hover:text-(--_mp-on-accent-container)","outline-mp-secondary focus-visible:outline-2 focus-visible:outline-offset-1","focus-visible:outline-solid outline-none"].join(" "):"text-mp-on-surface-variant"].filter(Boolean).join(" "),w=n(t,{children:[m(a)?e("span",{className:"flex h-[1lh] shrink-0 items-center",children:a}):null,e("span",{className:"truncate",itemProp:k?"name":void 0,children:f}),m(s)?e("span",{className:"flex h-[1lh] shrink-0 items-center",children:s}):null]});return n("li",{ref:b,itemProp:k?"itemListElement":void 0,itemScope:k||void 0,itemType:k?"https://schema.org/ListItem":void 0,className:["flex min-w-0 items-center",p??""].filter(Boolean).join(" "),...x,children:[k?e("meta",{itemProp:"position",content:String(N)}):null,j&&o?e("a",{href:o,itemProp:k?"item":void 0,className:B,onClick:i,children:w}):j?e("button",{type:"button",className:B,onClick:i,children:w}):e("span",{className:B,"aria-current":y?"page":void 0,"aria-disabled":d||void 0,children:w})]})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPBreadcrumb, MPBreadcrumbItem } from './MPBreadcrumb';
|
|
2
|
-
export type { MPBreadcrumbItemProps, MPBreadcrumbProps, MPBreadcrumbSeparator } from './MPBreadcrumb';
|
|
1
|
+
export { MPBreadcrumb, MPBreadcrumbItem } from './MPBreadcrumb.js';
|
|
2
|
+
export type { MPBreadcrumbItemProps, MPBreadcrumbProps, MPBreadcrumbSeparator } from './MPBreadcrumb.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPBreadcrumb,MPBreadcrumbItem}from"./MPBreadcrumb";
|
|
1
|
+
export{MPBreadcrumb,MPBreadcrumbItem}from"./MPBreadcrumb.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import type { MPColor, MPStyleProps, MPVariant } from '../../types';
|
|
2
|
+
import type { MPColor, MPStyleProps, MPVariant } from '../../types.js';
|
|
3
3
|
export interface MPButtonProps extends MPStyleProps, Omit<React.ComponentPropsWithoutRef<'button'>, 'color'> {
|
|
4
4
|
/**
|
|
5
5
|
* How much surface the button paints.
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as e,jsxs as o}from"react/jsx-runtime";import*as t from"react";import{Button as n}from"@base-ui/react/button";import{MPIcon as r}from"../icon/MPIcon.js";import{SpinnerIcon as a}from"../../constants/icons.js";import{accentSlots as i}from"../../internal/accent.js";import{MPButtonGroupContext as s}from"../../internal/button-group.js";import{useMPLocale as l,useMPMessages as c}from"../../internal/locale.js";import{COMMON as m}from"../../internal/messages/common.js";import{MPStateLayer as p}from"../../internal/StateLayer.js";import{CONTROL_GAP as d,CONTROL_HEIGHT as u,CONTROL_ICON as f,CONTROL_PAD_X as b,CONTROL_SQUARE as g,CONTROL_TEXT as x,hasContent as v}from"../../internal/scale.js";const h={filled:"bg-(--_mp-accent) text-(--_mp-on-accent)",tonal:"bg-(--_mp-accent-container) text-(--_mp-on-accent-container)",elevated:"shadow-mp-1 hover:shadow-mp-2 bg-mp-surface-container-low text-(--_mp-accent)",outlined:"border-mp-outline border bg-transparent text-(--_mp-accent)",text:"bg-transparent text-(--_mp-accent)"},j={filled:"bg-mp-on-surface/12 text-mp-on-surface/38",tonal:"bg-mp-on-surface/12 text-mp-on-surface/38",elevated:"bg-mp-on-surface/12 text-mp-on-surface/38 shadow-none",outlined:"border-mp-on-surface/12 border bg-transparent text-mp-on-surface/38",text:"bg-transparent text-mp-on-surface/38"};export const MPButton=/*@__PURE__*/t.forwardRef(function({variant:w,size:y,color:_,disabled:k,startIcon:z,endIcon:B,loading:C=!1,loadingLabel:I,locale:N,fullWidth:P=!1,type:L="button",className:M,style:D,children:R,onClick:S,...W},$){const q=l(N),A=c(m,q),E=t.useContext(s),F=w??E?.variant??"filled",G=y??E?.size??"md",H=_??E?.color??"primary",J=k??E?.disabled??!1,K=!v(R);return o(n,{ref:$,type:L,disabled:J,"aria-busy":C||void 0,"aria-disabled":C||void 0,"data-mp-size":G,"data-mp-variant":F,"data-loading":C||void 0,className:["mp-button group relative inline-flex shrink-0 items-center justify-center","rounded-mp-full box-border overflow-hidden align-middle whitespace-nowrap select-none","cursor-pointer appearance-none font-[inherit]","outline-mp-secondary focus-visible:outline-2 focus-visible:outline-offset-2","focus-visible:outline-solid outline-none","transition-[background-color,border-color,box-shadow,color]","duration-(--mp-sys-motion-duration-short4)",u[G],x[G],d[G],K?`${g[G]} px-0`:b[G],J?j[F]:h[F],J?"cursor-default":"",C?"cursor-progress":"",P?"w-full":"",M??""].filter(Boolean).join(" "),style:{...i(H),...D},onClick:e=>{if(C)return e.preventDefault(),void e.stopPropagation();S?.(e)},...W,children:[J?null:e(p,{}),C?e(r,{icon:a,size:f[G],label:I??A.loading,className:"animate-spin"}):z,R,B]})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPButton } from './MPButton';
|
|
2
|
-
export type { MPButtonProps } from './MPButton';
|
|
1
|
+
export { MPButton } from './MPButton.js';
|
|
2
|
+
export type { MPButtonProps } from './MPButton.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPButton}from"./MPButton";
|
|
1
|
+
export{MPButton}from"./MPButton.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import type { MPColor, MPOrientation, MPStyleProps, MPVariant } from '../../types';
|
|
2
|
+
import type { MPColor, MPOrientation, MPStyleProps, MPVariant } from '../../types.js';
|
|
3
3
|
export interface MPButtonGroupProps extends MPStyleProps, Omit<React.ComponentPropsWithoutRef<'div'>, 'color'> {
|
|
4
4
|
/**
|
|
5
5
|
* Which way the buttons run.
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as o}from"react/jsx-runtime";import*as r from"react";import{MPButtonGroupContext as e}from"../../internal/button-group.js";const t={horizontal:"[&>*:not(:first-child)]:rounded-s-mp-sm [&>*:not(:last-child)]:rounded-e-mp-sm",vertical:"[&>*:not(:first-child)]:rounded-t-mp-sm [&>*:not(:last-child)]:rounded-b-mp-sm"};export const MPButtonGroup=/*@__PURE__*/r.forwardRef(function({variant:i,size:l,color:n,disabled:a,orientation:s="horizontal",fullWidth:d=!1,className:c,children:m,...u},f){const p=r.useMemo(()=>({variant:i,size:l,color:n,disabled:a}),[i,l,n,a]);return o(e.Provider,{value:p,children:o("div",{ref:f,role:"group","data-mp-orientation":s,className:["mp-button-group inline-flex gap-0.5 align-middle","vertical"===s?"flex-col":"flex-row",t[s],"[&>*]:relative [&>*:focus-visible]:z-10",d?"flex w-full [&>*]:flex-1":"",c??""].filter(Boolean).join(" "),...u,children:m})})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPButtonGroup } from './MPButtonGroup';
|
|
2
|
-
export type { MPButtonGroupProps } from './MPButtonGroup';
|
|
1
|
+
export { MPButtonGroup } from './MPButtonGroup.js';
|
|
2
|
+
export type { MPButtonGroupProps } from './MPButtonGroup.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPButtonGroup}from"./MPButtonGroup";
|
|
1
|
+
export{MPButtonGroup}from"./MPButtonGroup.js";
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as e,jsxs as l,Fragment as a}from"react/jsx-runtime";import*as r from"react";import{MPBox as n}from"../box/MPBox.js";import{hasContent as i,META_TEXT as o,PROSE_TEXT as t,SHEET_GAP as s,SHEET_PAD_X as c,SHEET_PAD_Y as d,SHEET_TITLE as m}from"../../internal/scale.js";export const MPCard=/*@__PURE__*/r.forwardRef(function({size:r="md",title:f,subtitle:u,headerAction:p,media:x,footer:h,dividers:_=!1,className:v,children:N,...j},w){const b=c[r],k=d[r],$=_?`${b} ${k}`:b,g=i(f)||i(u)||i(p),y=i(x),B=[g?{key:"header",className:"mp-card__header flex items-start gap-3",content:l(a,{children:[i(f)||i(u)?l("div",{className:"flex min-w-0 flex-1 flex-col",children:[i(f)?e("div",{className:`mp-card__title ${m[r]}`,children:f}):null,i(u)?e("div",{className:`text-mp-on-surface-variant ${o}`,children:u}):null]}):null,i(p)?e("div",{className:"ms-auto shrink-0",children:p}):null]})}:null,i(N)?{key:"content",className:`mp-card__body min-w-0 ${t[r]}`,content:N}:null,i(h)?{key:"footer",className:"mp-card__footer flex flex-wrap items-center gap-2",content:h}:null].filter(e=>null!==e);return l(n,{ref:w,size:r,padded:!1,className:["mp-card flex flex-col",y?"overflow-hidden":"",v??""].filter(Boolean).join(" "),...j,children:[y?e("div",{className:"mp-card__media [&_img]:block [&_img]:w-full [&_video]:block [&_video]:w-full",children:x}):null,B.length>0?e("div",{className:["flex min-w-0 flex-col",_?"":`${k} ${s[r]}`].filter(Boolean).join(" "),children:B.map((l,a)=>e("div",{className:[$,l.className,_&&a>0?"border-mp-outline-variant border-t":""].filter(Boolean).join(" "),children:l.content},l.key))}):null]})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPCard } from './MPCard';
|
|
2
|
-
export type { MPCardProps } from './MPCard';
|
|
1
|
+
export { MPCard } from './MPCard.js';
|
|
2
|
+
export type { MPCardProps } from './MPCard.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPCard}from"./MPCard";
|
|
1
|
+
export{MPCard}from"./MPCard.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import type { MPColor, MPSize, MPVariant } from '../../types';
|
|
2
|
+
import type { MPColor, MPSize, MPVariant } from '../../types.js';
|
|
3
3
|
export interface MPCarouselProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'color' | 'defaultValue' | 'onChange'> {
|
|
4
4
|
/** Which slide is showing, counted from 0. Use with `onValueChange`. */
|
|
5
5
|
value?: number;
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as e,jsxs as r}from"react/jsx-runtime";import*as t from"react";import{MPIconButton as n}from"../icon-button/MPIconButton.js";import{MPIcon as o}from"../icon/MPIcon.js";import{ChevronLeftIcon as a,ChevronRightIcon as i}from"../../constants/icons.js";import{accentSlots as s}from"../../internal/accent.js";import{CONTROL_ICON as l}from"../../internal/scale.js";import{CONTAINER_SURFACE as c}from"../../internal/surface.js";import{VISUALLY_HIDDEN as u}from"../../internal/visually-hidden.js";const d={xs:"start-1 end-1",sm:"start-1.5 end-1.5",md:"start-2 end-2",lg:"start-3 end-3",xl:"start-4 end-4"},m={xs:{rest:"h-1 w-1",current:"h-1 w-3",gap:"gap-1"},sm:{rest:"h-1 w-1",current:"h-1 w-3.5",gap:"gap-1"},md:{rest:"h-1.5 w-1.5",current:"h-1.5 w-4",gap:"gap-1.5"},lg:{rest:"h-1.5 w-1.5",current:"h-1.5 w-5",gap:"gap-2"},xl:{rest:"h-2 w-2",current:"h-2 w-6",gap:"gap-2"}},f=(e,r)=>`Slide ${e} of ${r}`;export const MPCarousel=/*@__PURE__*/t.forwardRef(function({value:p,defaultValue:h=0,onValueChange:b,loop:v=!0,autoPlay:w=!1,interval:g=5e3,arrows:x=!0,indicators:j=!0,variant:N="outlined",size:y="md",color:M="primary",label:k="Carousel",previousLabel:R="Previous slide",nextLabel:C="Next slide",slideLabel:P=f,className:z,style:I,children:$,...L},E){const S=t.Children.toArray($),T=S.length,[A,B]=t.useState(h),F=Math.min(Math.max(p??A,0),Math.max(T-1,0)),V=t.useRef(null),W=t.useRef([]),q=t.useRef(!1),_=t.useRef(!1),D=t.useRef(!1),[G,H]=t.useState(!1),J=t.useRef(F),K=t.useRef(b);J.current=F,K.current=b;const O=t.useCallback((e,r=!1)=>{if(0===T)return;const t=v?(e%T+T)%T:Math.min(Math.max(e,0),T-1);q.current=r,void 0===p&&B(t),t!==J.current&&K.current?.(t)},[T,v,p]);t.useEffect(()=>{if(q.current)return void(q.current=!1);if(!_.current)return void(_.current=!0);W.current[F]?.scrollIntoView({block:"nearest",inline:"start"}),D.current=!0;const e=window.setTimeout(()=>{D.current=!1},700);return()=>window.clearTimeout(e)},[F]),t.useEffect(()=>{if(!w||G||T<2)return;if(window.matchMedia?.("(prefers-reduced-motion: reduce)").matches)return;const e=window.setInterval(()=>{document.hidden||O(J.current+1)},g);return()=>window.clearInterval(e)},[w,G,T,g,O]);const Q=t.useRef(0);t.useEffect(()=>()=>cancelAnimationFrame(Q.current),[]);const U=F<=0,X=F>=T-1;return r("div",{ref:E,role:"region","aria-roledescription":"carousel","aria-label":k,"data-mp-size":y,"data-mp-variant":N,className:["mp-carousel flex w-full flex-col",z??""].filter(Boolean).join(" "),style:{...s(M),...I},onPointerEnter:()=>H(!0),onPointerLeave:()=>H(!1),onFocus:()=>H(!0),onBlur:e=>{e.currentTarget.contains(e.relatedTarget)||H(!1)},...L,children:[r("div",{className:["relative min-w-0 overflow-hidden","rounded-mp-md box-border",c[N],"text-mp-on-surface"].join(" "),children:[e("div",{ref:V,tabIndex:0,role:"group","aria-label":k,className:["flex min-w-0 snap-x snap-mandatory overflow-x-auto scroll-smooth","motion-reduce:scroll-auto","[scrollbar-width:none] [&::-webkit-scrollbar]:hidden","outline-mp-secondary focus-visible:outline-2 focus-visible:-outline-offset-2","focus-visible:outline-solid outline-none"].join(" "),onScroll:()=>{Q.current||(Q.current=requestAnimationFrame(()=>{Q.current=0;const e=V.current;if(!e||0===e.clientWidth||D.current)return;const r=Math.round(Math.abs(e.scrollLeft)/e.clientWidth);r!==J.current&&r>=0&&r<T&&O(r,!0)}))},children:S.map((r,t)=>e("div",{ref:e=>{W.current[t]=e,W.current.length=T},role:"group","aria-roledescription":"slide","aria-label":P(t+1,T),className:"w-full shrink-0 grow-0 basis-full snap-start",children:r},t))}),x&&T>1?r("div",{className:`pointer-events-none absolute inset-y-0 flex items-center ${d[y]}`,children:[e(n,{variant:"filled",size:y,color:M,label:R,disabled:!v&&U,className:"pointer-events-auto",icon:e(o,{icon:a,size:l[y],className:"rtl:rotate-180"}),onClick:()=>O(F-1)}),e("span",{className:"flex-1"}),e(n,{variant:"filled",size:y,color:M,label:C,disabled:!v&&X,className:"pointer-events-auto",icon:e(o,{icon:i,size:l[y],className:"rtl:rotate-180"}),onClick:()=>O(F+1)})]}):null]}),j&&T>1?e("div",{className:`flex shrink-0 items-center justify-center pt-2 ${m[y].gap}`,children:S.map((r,t)=>e("button",{type:"button","aria-label":P(t+1,T),"aria-current":t===F?"true":void 0,className:["rounded-mp-full cursor-pointer appearance-none border-0 p-0","transition-[width,background-color] duration-(--mp-sys-motion-duration-short4)","ease-mp-standard motion-reduce:transition-none","outline-mp-secondary focus-visible:outline-2 focus-visible:outline-offset-2","focus-visible:outline-solid outline-none",t===F?`${m[y].current} bg-(--_mp-accent)`:`${m[y].rest} bg-mp-outline-variant hover:bg-mp-outline`].join(" "),onClick:()=>O(t)},t))}):null,e("span",{className:u,"aria-live":w?"off":"polite",children:T>0?P(F+1,T):""})]})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPCarousel } from './MPCarousel';
|
|
2
|
-
export type { MPCarouselProps } from './MPCarousel';
|
|
1
|
+
export { MPCarousel } from './MPCarousel.js';
|
|
2
|
+
export type { MPCarouselProps } from './MPCarousel.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPCarousel}from"./MPCarousel";
|
|
1
|
+
export{MPCarousel}from"./MPCarousel.js";
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as e,jsxs as n}from"react/jsx-runtime";import*as r from"react";import{MPIcon as a}from"../icon/MPIcon.js";import{CheckIcon as l,ClockIcon as t,ErrorIcon as i,LinkIcon as s}from"../../constants/icons.js";import{accentSlots as o}from"../../internal/accent.js";import{useMPLocale as c,useMPMessages as m}from"../../internal/locale.js";import{CHAT as d}from"../../internal/messages/chat.js";import{hasContent as p,META_TEXT as u,PROSE_TEXT as f}from"../../internal/scale.js";import{VISUALLY_HIDDEN as h}from"../../internal/visually-hidden.js";const b={xs:"px-2 py-1",sm:"px-2.5 py-1.5",md:"px-3 py-2",lg:"px-3.5 py-2.5",xl:"px-4 py-3"},x={start:"[border-start-start-radius:var(--mp-sys-shape-corner-extra-small)]",end:"[border-start-end-radius:var(--mp-sys-shape-corner-extra-small)]"},v={filled:"bg-(--_mp-accent) text-(--_mp-on-accent)",tonal:"bg-(--_mp-accent-container) text-(--_mp-on-accent-container)",elevated:"shadow-mp-1 bg-mp-surface-container-low text-mp-on-surface",outlined:"border-mp-outline-variant border bg-transparent text-mp-on-surface",text:"bg-mp-surface-container-low text-mp-on-surface"};function g(){return n("svg",{viewBox:"0 0 16 16",fill:"none","aria-hidden":"true",className:"size-full",children:[e("path",{d:"m1.5 8.5 2.75 2.75L9.5 6",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round"}),e("path",{d:"M7 10.75 8.25 12l5.25-5.25",stroke:"currentColor",strokeWidth:"1.75",strokeLinecap:"round",strokeLinejoin:"round"})]})}const N={sending:e(a,{icon:t,size:"1.15em"}),sent:e(a,{icon:l,size:"1.15em"}),delivered:e("span",{className:"block size-[1.15em]",children:e(g,{})}),read:e("span",{className:"block size-[1.15em]",children:e(g,{})}),failed:e(a,{icon:i,size:"1.15em"})},w={sending:"text-mp-on-surface-variant",sent:"text-mp-on-surface-variant",delivered:"text-mp-on-surface-variant",read:"text-(--_mp-accent)",failed:"text-mp-error"},y=/*@__PURE__*/["rounded-mp-sm block overflow-hidden border no-underline","[border-color:color-mix(in_oklab,currentColor_18%,transparent)]","[background-color:color-mix(in_oklab,currentColor_7%,transparent)]","hover:[background-color:color-mix(in_oklab,currentColor_12%,transparent)]","transition-[background-color] duration-(--mp-sys-motion-duration-short4) ease-mp-standard","outline-mp-secondary focus-visible:outline-2 focus-visible:outline-offset-2","focus-visible:outline-solid outline-none"].join(" "),k=/*@__PURE__*/["shrink-0 opacity-0","transition-opacity duration-(--mp-sys-motion-duration-short4) ease-mp-standard","group-hover/bubble:opacity-100 group-focus-within/bubble:opacity-100","[@media(hover:none)]:opacity-100"].join(" ");export const MPChatBubble=/*@__PURE__*/r.forwardRef(function({side:r="start",name:a,time:l,avatar:t,status:i,statusLabel:s,typing:g=!1,media:y,preview:z,actions:C,locale:L,variant:B="tonal",size:$="md",color:M="primary",className:P,style:W,children:I,...R},T){const q=c(L),A=m(d,q),D="end"===r,E=p(a)||p(l),F=g||p(I)||Boolean(z);return n("div",{ref:T,"data-mp-size":$,"data-mp-variant":B,"data-mp-side":r,className:["mp-chat-bubble group/bubble flex w-full items-start gap-2",D?"flex-row-reverse":"",P??""].filter(Boolean).join(" "),style:{...o(M),...W},...R,children:[p(t)?e("div",{className:"shrink-0",children:t}):null,n("div",{className:["flex min-w-0 max-w-[min(100%,32rem)] flex-col gap-1",D?"items-end":"items-start"].join(" "),children:[E?n("div",{className:`flex items-baseline gap-2 ${u}`,children:[p(a)?e("span",{className:"font-medium",children:a}):null,p(l)?e("span",{className:"text-mp-on-surface-variant",children:l}):null]}):null,n("div",{className:"flex min-w-0 items-center gap-1 "+(D?"flex-row-reverse":""),children:[n("div",{className:["mp-chat-bubble__sheet rounded-mp-xl flex min-w-0 flex-col overflow-hidden","box-border",x[r],v[B],f[$]].join(" "),children:[p(y)?e("div",{className:"[&_img]:block [&_img]:w-full [&_video]:block [&_video]:w-full",children:y}):null,F?n("div",{className:`flex min-w-0 flex-col gap-2 ${b[$]}`,children:[g?e(_,{label:A.typing}):p(I)?e("div",{className:"min-w-0 break-words whitespace-pre-line",children:I}):null,z?e(j,{preview:z}):null]}):null]}),p(C)?e("div",{className:k,children:C}):null]}),i?n("div",{className:`flex items-center gap-1 ${u} ${w[i]}`,children:[N[i],e("span",{className:h,children:s??A[i]})]}):null]})]})});function _({label:r}){return n("div",{className:"flex items-center gap-1 py-[0.35em]",role:"status",children:[[0,1,2].map(n=>e("span",{"aria-hidden":"true",className:"mp-chat-typing size-[0.45em] rounded-full bg-current",style:{"--_mp-index":n}},n)),e("span",{className:h,children:r})]})}function j({preview:r}){const{url:l,title:t,description:i,image:o,site:c,newTab:m=!1}=r;return n("a",{href:l,target:m?"_blank":void 0,rel:m?"noopener noreferrer":void 0,className:y,children:[o?e("img",{src:o,alt:"",className:"block h-28 w-full object-cover"}):null,n("div",{className:"flex flex-col gap-0.5 p-2",children:[p(c)?n("span",{className:"flex items-center gap-1 text-[0.85em] opacity-70",children:[e(a,{icon:s,size:"1em"}),e("span",{className:"truncate",children:c})]}):null,p(t)?e("span",{className:"font-medium",children:t}):null,p(i)?e("span",{className:"line-clamp-2 text-[0.9em] opacity-80",children:i}):null]})]})}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPChatBubble } from './MPChatBubble';
|
|
2
|
-
export type { MPChatBubblePreview, MPChatBubbleProps, MPChatBubbleSide, MPChatBubbleStatus } from './MPChatBubble';
|
|
1
|
+
export { MPChatBubble } from './MPChatBubble.js';
|
|
2
|
+
export type { MPChatBubblePreview, MPChatBubbleProps, MPChatBubbleSide, MPChatBubbleStatus } from './MPChatBubble.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPChatBubble}from"./MPChatBubble";
|
|
1
|
+
export{MPChatBubble}from"./MPChatBubble.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import type { MPColor, MPSize } from '../../types';
|
|
2
|
+
import type { MPColor, MPSize } from '../../types.js';
|
|
3
3
|
export interface MPCheckboxProps {
|
|
4
4
|
/** Whether the box is ticked. Use with `onCheckedChange` for a controlled box. */
|
|
5
5
|
checked?: boolean;
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as e,jsxs as a}from"react/jsx-runtime";import*as r from"react";import{Checkbox as t}from"@base-ui/react/checkbox";import{Field as n}from"@base-ui/react/field";import{MPIcon as o}from"../icon/MPIcon.js";import{CheckIcon as i,RemoveIcon as s}from"../../constants/icons.js";import{accentSlots as c}from"../../internal/accent.js";import{MPStateLayer as d}from"../../internal/StateLayer.js";import{MPSupportingText as l}from"../../internal/SupportingText.js";import{PROSE_TEXT as m,hasContent as p}from"../../internal/scale.js";const h={xs:{box:"size-3.5",halo:"size-8",glyph:12},sm:{box:"size-4",halo:"size-9",glyph:14},md:{box:"size-[18px]",halo:"size-10",glyph:16},lg:{box:"size-5",halo:"size-11",glyph:18},xl:{box:"size-[22px]",halo:"size-12",glyph:20}};export const MPCheckbox=/*@__PURE__*/r.forwardRef(function({checked:u,defaultChecked:f,onCheckedChange:b,indeterminate:x=!1,label:g,description:y,errorMessage:k,size:j="md",color:z="primary",required:_=!1,disabled:v=!1,readOnly:C=!1,name:N,value:M,id:I},R){const q=p(k),w=q?"error":z,L=h[j],O=r.useId(),P=I??O;return e(n.Root,{className:"mp-checkbox inline-block align-top",disabled:v,invalid:q,"data-mp-size":j,style:c(w),children:a("div",{className:["flex items-start gap-3",m[j]].join(" "),children:[e("span",{className:"flex h-[1lh] shrink-0 items-center",children:a(t.Root,{ref:R,id:P,name:N,value:M,checked:u,defaultChecked:f,indeterminate:x,required:_,disabled:v,readOnly:C,onCheckedChange:e=>b?.(e),className:["mp-checkbox__tick group relative inline-flex shrink-0 items-center","box-border justify-center border-2 p-0","rounded-[calc(var(--mp-sys-shape-corner-extra-small)/2)]","appearance-none bg-transparent font-[inherit] outline-none","transition-[background-color,border-color]","duration-(--mp-sys-motion-duration-short4)",L.box,v?["border-mp-on-surface/38 cursor-default","data-checked:bg-mp-on-surface/38 data-checked:border-transparent","data-indeterminate:bg-mp-on-surface/38 data-indeterminate:border-transparent"].join(" "):[C?"cursor-default":"cursor-pointer",q?"border-mp-error":"border-mp-on-surface-variant","data-checked:border-transparent data-checked:bg-(--_mp-accent)","data-checked:text-(--_mp-on-accent)","data-indeterminate:border-transparent data-indeterminate:bg-(--_mp-accent)","data-indeterminate:text-(--_mp-on-accent)"].join(" ")].join(" "),children:[v?null:e(d,{layer:["top-1/2 left-1/2 -translate-x-1/2 -translate-y-1/2 rounded-full",L.halo,"bg-mp-on-surface","group-data-checked:bg-(--_mp-accent)","group-data-indeterminate:bg-(--_mp-accent)"].join(" ")}),e(t.Indicator,{className:["flex items-center justify-center","transition-[opacity,scale] duration-(--mp-sys-motion-duration-short4)","ease-mp-standard","data-starting-style:scale-60 data-starting-style:opacity-0","data-ending-style:scale-60 data-ending-style:opacity-0"].join(" "),children:e(o,{icon:x?s:i,size:L.glyph,strokeWidth:3})})]})}),p(g)||p(y)||q?a("span",{className:"flex min-w-0 flex-col gap-0.5",children:[p(g)?a(n.Label,{htmlFor:P,className:["leading-[1.4]",v?"text-mp-on-surface/38 cursor-default":C?"text-mp-on-surface":"text-mp-on-surface cursor-pointer"].join(" "),children:[g,_?e("span",{"aria-hidden":"true",children:" *"}):null]}):null,e(l,{description:y,errorMessage:k})]}):null]})})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPCheckbox } from './MPCheckbox';
|
|
2
|
-
export type { MPCheckboxProps } from './MPCheckbox';
|
|
1
|
+
export { MPCheckbox } from './MPCheckbox.js';
|
|
2
|
+
export type { MPCheckboxProps } from './MPCheckbox.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPCheckbox}from"./MPCheckbox";
|
|
1
|
+
export{MPCheckbox}from"./MPCheckbox.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import type { MPColor, MPSize, MPVariant } from '../../types';
|
|
2
|
+
import type { MPColor, MPSize, MPVariant } from '../../types.js';
|
|
3
3
|
export interface MPChipProps extends Omit<React.ComponentPropsWithoutRef<'span'>, 'color'> {
|
|
4
4
|
/**
|
|
5
5
|
* How much surface the chip paints.
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as e,Fragment as t,jsxs as n}from"react/jsx-runtime";import*as o from"react";import{MPIcon as a}from"../icon/MPIcon.js";import{CloseIcon as r}from"../../constants/icons.js";import{accentSlots as i}from"../../internal/accent.js";import{useMPLocale as s,useMPMessages as l}from"../../internal/locale.js";import{COMMON as c}from"../../internal/messages/common.js";import{hasContent as m}from"../../internal/scale.js";import{MPStateLayer as p}from"../../internal/StateLayer.js";const d={xs:"h-6",sm:"h-7",md:"h-8",lg:"h-10",xl:"h-12"},u={xs:"text-mp-label-medium",sm:"text-mp-label-medium",md:"text-mp-label-large",lg:"text-mp-label-large",xl:"text-mp-title-medium"},f={xs:"px-2",sm:"px-3",md:"px-4",lg:"px-5",xl:"px-6"},x={xs:"gap-1",sm:"gap-1.5",md:"gap-2",lg:"gap-2",xl:"gap-2.5"},b={xs:"rounded-mp-xs",sm:"rounded-mp-sm",md:"rounded-mp-sm",lg:"rounded-mp-sm",xl:"rounded-mp-md"},g={filled:"bg-(--_mp-accent) text-(--_mp-on-accent)",tonal:"bg-(--_mp-accent-container) text-(--_mp-on-accent-container)",elevated:"shadow-mp-1 bg-mp-surface-container-low text-mp-on-surface-variant",outlined:"border-mp-outline text-mp-on-surface-variant border bg-transparent",text:"text-mp-on-surface-variant bg-transparent"},h={filled:"bg-(--_mp-accent) text-(--_mp-on-accent)",tonal:"bg-(--_mp-accent-container) text-(--_mp-on-accent-container)",elevated:"shadow-mp-1 bg-(--_mp-accent-container) text-(--_mp-on-accent-container)",outlined:"border-mp-outline bg-(--_mp-accent-container) text-(--_mp-on-accent-container) border",text:"bg-(--_mp-accent-container) text-(--_mp-on-accent-container)"},v={filled:"bg-mp-on-surface/12 text-mp-on-surface/38",tonal:"bg-mp-on-surface/12 text-mp-on-surface/38",elevated:"bg-mp-on-surface/12 text-mp-on-surface/38 shadow-none",outlined:"border-mp-on-surface/12 text-mp-on-surface/38 border bg-transparent",text:"bg-transparent text-mp-on-surface/38"},y=/*@__PURE__*/["ms-0.5 -me-1 inline-flex shrink-0 cursor-pointer items-center justify-center","rounded-mp-full size-[1.35em] opacity-70","transition-opacity duration-(--mp-sys-motion-duration-short4)","hover:opacity-100 focus-visible:opacity-100","outline-mp-secondary focus-visible:outline-2 focus-visible:outline-offset-1","focus-visible:outline-solid outline-none","disabled:cursor-default disabled:opacity-38"].join(" "),_=/*@__PURE__*/["group relative flex min-w-0 flex-1 cursor-pointer items-center justify-center","self-stretch rounded-[inherit] font-[inherit] text-[inherit]","appearance-none border-0 bg-transparent","outline-mp-secondary focus-visible:outline-2 focus-visible:outline-offset-2","focus-visible:outline-solid outline-none"].join(" ");export const MPChip=/*@__PURE__*/o.forwardRef(function({variant:o="outlined",size:j="md",color:w="primary",startIcon:k,endIcon:N,count:z,onDelete:C,deleteLabel:I,locale:$,selected:B,disabled:L=!1,className:M,style:P,children:D,onClick:F,...R},S){const q=s($),A=l(c,q),E=Boolean(F)&&!L,G=["mp-chip relative inline-flex max-w-full shrink-0 items-center","box-border overflow-hidden align-middle leading-none whitespace-nowrap select-none","transition-[background-color,border-color,box-shadow,color]","duration-(--mp-sys-motion-duration-short4)",d[j],u[j],x[j],b[j],L?v[o]:B?h[o]:g[o],E?"ps-0":f[j],C?"pe-2":E?"pe-0":"",M??""].filter(Boolean).join(" "),H=n(t,{children:[k,m(D)?e("span",{className:"min-w-0 truncate",children:D}):null,N,m(z)?e("span",{className:["rounded-mp-full ms-0.5 inline-flex shrink-0 items-center justify-center px-1.5 py-px","text-[0.85em] leading-none font-medium tabular-nums","filled"===o?"bg-(--_mp-on-accent)/20 text-(--_mp-on-accent)":"bg-(--_mp-accent-container) text-(--_mp-on-accent-container)"].join(" "),children:z}):null]});return n("span",{ref:S,"data-mp-size":j,"data-mp-variant":o,"data-selected":B||void 0,className:G,style:{...i(w),...P},"aria-disabled":!(!L||E)||void 0,...R,children:[E?n("button",{type:"button","aria-pressed":B,className:`${_} ${x[j]} ${f[j]}`,onClick:F,children:[e(p,{}),H]}):H,C?e("button",{type:"button","aria-label":I??A.remove,disabled:L,className:y,onClick:C,children:e(a,{icon:r,size:"1em"})}):null]})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPChip } from './MPChip';
|
|
2
|
-
export type { MPChipProps } from './MPChip';
|
|
1
|
+
export { MPChip } from './MPChip.js';
|
|
2
|
+
export type { MPChipProps } from './MPChip.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPChip}from"./MPChip";
|
|
1
|
+
export{MPChip}from"./MPChip.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import type { MPSize, MPVariant } from '../../types';
|
|
2
|
+
import type { MPSize, MPVariant } from '../../types.js';
|
|
3
3
|
export interface MPCollapsibleProps extends Omit<React.ComponentPropsWithoutRef<'div'>, 'title' | 'onChange'> {
|
|
4
4
|
/** Whether the panel is showing. Use with `onOpenChange` for a controlled one. */
|
|
5
5
|
open?: boolean;
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as e,jsxs as n}from"react/jsx-runtime";import*as t from"react";import{Collapsible as a}from"@base-ui/react/collapsible";import{MPIcon as i}from"../icon/MPIcon.js";import{ChevronDownIcon as r}from"../../constants/icons.js";import{MPStateLayer as o}from"../../internal/StateLayer.js";import{CONTROL_GAP as s,CONTROL_ICON as l,hasContent as c,META_TEXT as d,PROSE_TEXT as m,SHEET_PAD_X as p,SHEET_PAD_Y as u,SHEET_TITLE as f}from"../../internal/scale.js";import{CONTAINER_SURFACE as h}from"../../internal/surface.js";const x=/*@__PURE__*/["h-(--collapsible-panel-height) overflow-hidden","transition-[height] duration-(--mp-sys-motion-duration-short4) ease-mp-standard","motion-reduce:transition-none","data-starting-style:h-0 data-ending-style:h-0"].join(" "),b={xs:"pb-2.5",sm:"pb-3",md:"pb-4",lg:"pb-5",xl:"pb-6"};export const MPCollapsible=/*@__PURE__*/t.forwardRef(function({open:t,defaultOpen:g=!1,onOpenChange:v,title:j,subtitle:N,startIcon:w,action:y,trigger:k,indicator:M=!0,disabled:O=!1,padded:z=!0,variant:C="outlined",size:P="md",hiddenUntilFound:$=!1,keepMounted:B=!1,className:F,children:I,...R},T){const U=p[P],L=u[P];return n(a.Root,{ref:T,open:t,defaultOpen:g,onOpenChange:e=>v?.(e),disabled:O,"data-mp-size":P,"data-mp-variant":C,className:["mp-collapsible rounded-mp-md flex w-full flex-col overflow-hidden",h[C],"text-mp-on-surface",F??""].filter(Boolean).join(" "),...R,children:[k?e(a.Trigger,{render:k}):n("div",{className:"flex w-full items-center",children:[n(a.Trigger,{className:["group relative flex min-w-0 flex-1 cursor-pointer items-center text-start","appearance-none border-0 bg-transparent font-[inherit] text-inherit",U,L,s[P],"outline-mp-secondary focus-visible:outline-2 focus-visible:-outline-offset-2","focus-visible:outline-solid outline-none","disabled:text-mp-on-surface/38 disabled:cursor-default"].join(" "),children:[e(o,{}),c(w)?e("span",{className:"text-mp-on-surface-variant flex h-[1lh] shrink-0 items-center",children:w}):null,n("span",{className:"flex min-w-0 flex-1 flex-col",children:[c(j)?e("span",{className:`truncate ${f[P]}`,children:j}):null,c(N)?e("span",{className:`text-mp-on-surface-variant truncate ${d}`,children:N}):null]}),M?e("span",{className:["text-mp-on-surface-variant flex h-[1lh] shrink-0 items-center","transition-[rotate] duration-(--mp-sys-motion-duration-short4)","ease-mp-standard motion-reduce:transition-none","group-data-panel-open:rotate-180"].join(" "),children:e(i,{icon:r,size:l[P]})}):null]}),c(y)?e("span",{className:`flex shrink-0 items-center ${U}`,children:y}):null]}),e(a.Panel,{hiddenUntilFound:$,keepMounted:B,className:x,children:e("div",{className:["min-w-0",m[P],"text-mp-on-surface-variant",z?U:"",z?k?L:b[P]:""].filter(Boolean).join(" "),children:I})})]})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPCollapsible } from './MPCollapsible';
|
|
2
|
-
export type { MPCollapsibleProps } from './MPCollapsible';
|
|
1
|
+
export { MPCollapsible } from './MPCollapsible.js';
|
|
2
|
+
export type { MPCollapsibleProps } from './MPCollapsible.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPCollapsible}from"./MPCollapsible";
|
|
1
|
+
export{MPCollapsible}from"./MPCollapsible.js";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import type { MPColorFormat } from '../../internal/color';
|
|
3
|
-
import type { MPStyleProps } from '../../types';
|
|
2
|
+
import type { MPColorFormat } from '../../internal/color.js';
|
|
3
|
+
import type { MPStyleProps } from '../../types.js';
|
|
4
4
|
/** The names for the parts of the picker that have no text on them. */
|
|
5
5
|
export interface MPColorPickerLabels {
|
|
6
6
|
/** The saturation/brightness square. */
|
|
@@ -1 +1,2 @@
|
|
|
1
|
-
|
|
1
|
+
"use client";
|
|
2
|
+
import{jsx as e,jsxs as a}from"react/jsx-runtime";import*as r from"react";import{Field as n}from"@base-ui/react/field";import{Popover as t}from"@base-ui/react/popover";import{MPIcon as l}from"../icon/MPIcon.js";import{CheckIcon as o,CloseIcon as i}from"../../constants/icons.js";import{MPFieldLabel as s,MPFieldOutline as u,useFloatingLabel as c}from"../../internal/FieldOutline.js";import{MPStateLayer as d}from"../../internal/StateLayer.js";import{MPSupportingText as p}from"../../internal/SupportingText.js";import{CONTROL_ICON as h,META_TEXT as m,PROSE_TEXT as f,STACK_GAP as g,hasContent as v}from"../../internal/scale.js";import{FADE as b,PORTAL_LAYER as x}from"../../internal/surface.js";import{CHECKER_BACKGROUND as y,DEFAULT_SWATCHES as w,clamp as N,cssColor as j,formatColor as k,parseColor as C,readableInk as _}from"../../internal/color.js";const z={area:"Saturation and brightness",hue:"Hue",alpha:"Opacity",value:"Colour value",swatches:"Swatches",clear:"Clear",empty:"No colour"},P={xs:"w-40",sm:"w-44",md:"w-52",lg:"w-60",xl:"w-72"},$={xs:"h-24",sm:"h-28",md:"h-32",lg:"h-40",xl:"h-48"},M={xs:"h-2.5",sm:"h-3",md:"h-3.5",lg:"h-4",xl:"h-5"},T={xs:"gap-2",sm:"gap-2.5",md:"gap-3",lg:"gap-3.5",xl:"gap-4"},I={xs:12,sm:14,md:16,lg:18,xl:20},O={xs:{padding:"px-2",height:"h-8"},sm:{padding:"px-3",height:"h-10"},md:{padding:"px-4",height:"h-14"},lg:{padding:"px-4",height:"h-16"},xl:{padding:"px-5",height:"h-18"}},S="border-mp-outline-variant relative overflow-hidden border",A=/*@__PURE__*/["pointer-events-none absolute rounded-full border-2 border-white","[box-shadow:0_0_0_1px_rgb(0_0_0/0.35),0_1px_3px_rgb(0_0_0/0.4)]"].join(" ");function B(e,a,r){return{x:0===e.width?0:N((a-e.left)/e.width,0,1),y:0===e.height?0:N((r-e.top)/e.height,0,1)}}function D(e){const a=e.shiftKey?10:1;switch(e.key){case"ArrowLeft":return{x:-a,y:0};case"ArrowRight":return{x:a,y:0};case"ArrowUp":return{x:0,y:a};case"ArrowDown":return{x:0,y:-a};default:return null}}function L({hsv:n,alphaValue:t,onChange:i,text:s,onTextChange:u,withAlpha:c,swatches:d,editable:p,size:h,inert:f,labels:g}){const v=I[h],b=-v/2,x=j({h:n.h,s:100,v:100}),w=j(n),z=r.useRef(null),O=e=>({onPointerDown:a=>{if(f)return;const r=a.currentTarget.getBoundingClientRect();z.current=r,a.currentTarget.setPointerCapture(a.pointerId),e(B(r,a.clientX,a.clientY))},onPointerMove:a=>{const r=z.current;!f&&r&&a.currentTarget.hasPointerCapture(a.pointerId)&&e(B(r,a.clientX,a.clientY))},onPointerUp:()=>{z.current=null},onPointerCancel:()=>{z.current=null}}),L=(e,a,r,n)=>({role:"slider",tabIndex:f?-1:0,"aria-label":e,"aria-valuemin":0,"aria-valuemax":r,"aria-valuenow":Math.round(a),"aria-orientation":"horizontal","aria-disabled":f||void 0,onKeyDown:e=>{const a=D(e);!f&&a&&0!==a.x&&(e.preventDefault(),n(a.x))}}),R=/*@__PURE__*/["outline-mp-secondary focus-visible:outline-2 focus-visible:outline-offset-2","focus-visible:outline-solid outline-none"].join(" "),q=r.useMemo(()=>d?d.map(e=>{const a=C(e);return{swatch:e,parsed:a,hex:null===a?null:k(a.hsv,a.alpha,"hex")}}):[],[d]),V=k(n,t,"hex");return a("div",{className:`mp-color-picker__panel flex flex-col ${P[h]} ${T[h]}`,children:[e("div",{...O(({x:e,y:a})=>i({hsv:{h:n.h,s:100*e,v:100*(1-a)},alpha:t})),role:"slider",tabIndex:f?-1:0,"aria-label":g.area,"aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":Math.round(n.s),"aria-valuetext":`${Math.round(n.s)}%, ${Math.round(n.v)}%`,"aria-disabled":f||void 0,onKeyDown:e=>{const a=D(e);!f&&a&&(e.preventDefault(),i({hsv:{h:n.h,s:N(n.s+a.x,0,100),v:N(n.v+a.y,0,100)},alpha:t}))},className:[S,"rounded-mp-sm",$[h],R,f?"cursor-default":"cursor-crosshair touch-none"].join(" "),style:{backgroundColor:x,backgroundImage:"linear-gradient(to top, #000000, rgb(0 0 0 / 0)), linear-gradient(to right, #ffffff, rgb(255 255 255 / 0))"},children:e("span",{className:A,style:{width:v,height:v,left:`${n.s}%`,top:100-n.v+"%",marginLeft:b,marginTop:b,backgroundColor:w}})}),e("div",{...O(({x:e})=>i({hsv:{...n,h:360*e},alpha:t})),...L(g.hue,n.h,360,e=>i({hsv:{...n,h:(n.h+2*e+360)%360},alpha:t})),className:[S,"rounded-mp-full",M[h],R,f?"cursor-default":"cursor-pointer touch-none"].join(" "),style:{backgroundImage:"linear-gradient(to right, #ff0000 0%, #ffff00 16.66%, #00ff00 33.33%, #00ffff 50%, #0000ff 66.66%, #ff00ff 83.33%, #ff0000 100%)"},children:e("span",{className:A,style:{width:v,height:v,left:n.h/360*100+"%",top:"50%",marginLeft:b,marginTop:b,backgroundColor:x}})}),c?a("div",{...O(({x:e})=>i({hsv:n,alpha:e})),...L(g.alpha,100*t,100,e=>i({hsv:n,alpha:N(t+e/100,0,1)})),className:[S,"rounded-mp-full",M[h],R,f?"cursor-default":"cursor-pointer touch-none"].join(" "),style:y,children:[e("span",{"aria-hidden":"true",className:"absolute inset-0",style:{backgroundImage:`linear-gradient(to right, ${j(n,0)}, ${w})`}}),e("span",{className:A,style:{width:v,height:v,left:100*t+"%",top:"50%",marginLeft:b,marginTop:b,backgroundColor:j(n,t)}})]}):null,p?a("div",{className:`flex items-center ${T[h]}`,children:[e("span",{"aria-hidden":"true",className:"border-mp-outline-variant shrink-0 rounded-full border",style:{width:v+8,height:v+8,...y},children:e("span",{className:"block size-full rounded-full",style:{backgroundColor:j(n,t)}})}),e("input",{type:"text",value:s,readOnly:f,spellCheck:!1,autoComplete:"off","aria-label":g.value,onChange:e=>u(e.target.value),className:["rounded-mp-xs border-mp-outline text-mp-on-surface min-w-0 flex-1 border","bg-transparent px-2 py-1 font-mono lowercase",m,"focus-visible:border-mp-primary outline-none"].join(" ")})]}):null,q.length>0?e("div",{role:"group","aria-label":g.swatches,className:"grid grid-cols-8 gap-1",children:q.map(({swatch:a,parsed:r,hex:n},t)=>{const s=null!==r&&n===V;return e("button",{type:"button",disabled:f,"aria-label":a,"aria-pressed":s,onClick:()=>{r&&i({hsv:r.hsv,alpha:r.alpha})},className:["border-mp-outline-variant flex aspect-square items-center justify-center","rounded-full border","transition-[box-shadow] duration-(--mp-sys-motion-duration-short4)","ease-mp-standard",R,f?"cursor-default":"hover:shadow-mp-1 cursor-pointer"].join(" "),style:{backgroundColor:a},children:e("span",{"aria-hidden":"true",className:["transition-opacity duration-(--mp-sys-motion-duration-short4)","ease-mp-standard",s?"opacity-100":"opacity-0"].join(" "),style:r?{color:_(r.hsv)}:void 0,children:e(l,{icon:o,size:12})})},`${t}:${a}`)})}):null]})}const R={h:202,s:100,v:61};export const MPColorPicker=/*@__PURE__*/r.forwardRef(function({value:o,defaultValue:N="#00639b",onValueChange:_,format:P="hex",alpha:$=!1,swatches:M=w,inline:T=!1,editable:I=!0,label:S,floatingLabel:A=!0,description:B,errorMessage:D,required:q=!1,disabled:V=!1,readOnly:K=!1,clearable:F=!1,name:U,open:X,defaultOpen:Y=!1,onOpenChange:E,labels:H,size:W="md",fullWidth:G=!1,id:J,className:Q,style:Z},ee){const ae=r.useMemo(()=>({...z,...H}),[H]),re=v(D),ne=O[W],te=r.useId(),le=J??te,[oe,ie]=r.useState(N),se=o??oe,[ue,ce]=r.useState(Y),de=X??ue,[pe,he]=r.useState(()=>C(se)??{hsv:R,alpha:1}),[me,fe]=r.useState(()=>se),ge=k(pe.hsv,$?pe.alpha:1,P),ve=""===se;r.useEffect(()=>{const e=C(se);e?k(e.hsv,$?e.alpha:1,P)!==ge&&(fe(se),he(e)):fe(se)},[se,ge,$,P]);const be=V||K,xe=F&&!be&&!ve,{shrunk:ye,focusProps:we}=c({floating:A&&v(S),filled:!ve,pinned:de}),Ne=(e,a)=>{he(e);const r=k(e.hsv,$?e.alpha:1,P);fe(a??r),void 0===o&&ie(r),_?.(r)},je=e(L,{hsv:pe.hsv,alphaValue:pe.alpha,onChange:Ne,text:me,onTextChange:e=>{fe(e);const a=C(e);a&&Ne(a,e)},withAlpha:$,swatches:M,editable:I,size:W,inert:be,labels:ae}),ke=e("span",{"aria-hidden":"true",className:"border-mp-outline-variant block size-5 shrink-0 rounded-full border",style:y,children:e("span",{className:"block size-full rounded-full",style:{backgroundColor:ve?"transparent":j(pe.hsv,$?pe.alpha:1)}})}),Ce=U?e("input",{type:"hidden",name:U,value:ve?"":ge}):null;return T?a("div",{ref:ee,"data-mp-size":W,className:["mp-color-picker flex flex-col",g[W],Q??""].filter(Boolean).join(" "),style:Z,children:[v(S)?a("span",{className:[m,V?"text-mp-on-surface/38":"text-mp-on-surface-variant"].join(" "),children:[S,q?e("span",{"aria-hidden":"true",children:" *"}):null]}):null,je,v(D)?e("span",{className:`${m} text-mp-error`,children:D}):v(B)?e("span",{className:`${m} text-mp-on-surface-variant`,children:B}):null,Ce]}):a(n.Root,{ref:ee,disabled:V,invalid:re,"data-mp-size":W,className:["mp-color-picker group flex-col align-top",G?"flex w-full":"inline-flex w-fit",Q??""].filter(Boolean).join(" "),style:Z,...we,children:[a(t.Root,{open:de,onOpenChange:e=>{void 0===X&&ce(e),E?.(e)},children:[a("div",{className:"relative w-full",children:[a(t.Trigger,{id:le,disabled:V,nativeButton:!0,className:["relative flex w-full items-center gap-2 select-none","appearance-none bg-transparent font-[inherit] outline-none",ne.padding,xe?"pe-10":"",ne.height,f[W],V?"text-mp-on-surface/38 cursor-default":"text-mp-on-surface "+(K?"cursor-default":"cursor-pointer")].filter(Boolean).join(" "),children:[ve&&!ye?null:ke,e("span",{className:["min-w-0 flex-1 truncate text-start",ve?"text-mp-on-surface-variant":""].filter(Boolean).join(" "),children:ve?ye?ae.empty:null:ge})]}),xe?a("button",{type:"button","aria-label":ae.clear,onClick:()=>{void 0===o&&ie(""),fe(""),_?.("")},className:["group/clear rounded-mp-full text-mp-on-surface-variant absolute inset-y-0","end-1 my-auto flex size-8 cursor-pointer items-center justify-center","outline-mp-secondary focus-visible:outline-2 focus-visible:outline-offset-1","focus-visible:outline-solid outline-none"].join(" "),children:[e(d,{className:"group-hover/clear:opacity-8 group-focus-visible/clear:opacity-10"}),e(l,{icon:i,size:h[W]})]}):null,e(u,{label:S,required:q,notched:ye}),v(S)?e(s,{size:W,label:S,required:q,htmlFor:le,shrunk:ye}):null]}),e(t.Portal,{children:e(t.Positioner,{className:x,sideOffset:4,align:"start",children:e(t.Popup,{className:["mp-color-picker__popup rounded-mp-md shadow-mp-2 bg-mp-surface-container","text-mp-on-surface p-3 outline-none",f[W],b].join(" "),children:je})})})]}),e(p,{description:B,errorMessage:D,className:ne.padding}),Ce]})});
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { MPColorPicker } from './MPColorPicker';
|
|
2
|
-
export type { MPColorPickerLabels, MPColorPickerProps } from './MPColorPicker';
|
|
1
|
+
export { MPColorPicker } from './MPColorPicker.js';
|
|
2
|
+
export type { MPColorPickerLabels, MPColorPickerProps } from './MPColorPicker.js';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export{MPColorPicker}from"./MPColorPicker";
|
|
1
|
+
export{MPColorPicker}from"./MPColorPicker.js";
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as React from 'react';
|
|
2
|
-
import type { MPStyleProps } from '../../types';
|
|
2
|
+
import type { MPStyleProps } from '../../types.js';
|
|
3
3
|
/**
|
|
4
4
|
* What a combobox's value may be — the same two types `MPSelect` submits, and for
|
|
5
5
|
* the same reason: a form control's value is what a form sends, and every escape
|