@platform-blocks/ui 0.1.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/LICENSE +21 -0
- package/README.md +44 -0
- package/lib/cjs/index.js +35531 -0
- package/lib/cjs/index.js.map +1 -0
- package/lib/components/Accessibility/AccessibilityDemo.d.ts +5 -0
- package/lib/components/Accessibility/AccessibilityHelpers.d.ts +49 -0
- package/lib/components/Accessibility/AccessibilityTesting.d.ts +24 -0
- package/lib/components/Accessibility/AccessibleComponents.d.ts +20 -0
- package/lib/components/Accessibility/index.d.ts +2 -0
- package/lib/components/Accordion/Accordion.d.ts +9 -0
- package/lib/components/Accordion/AccordionItem.d.ts +23 -0
- package/lib/components/Accordion/defaults.d.ts +13 -0
- package/lib/components/Accordion/hooks/useAccordionItemAnimation.d.ts +17 -0
- package/lib/components/Accordion/hooks/useMeasuredHeight.d.ts +8 -0
- package/lib/components/Accordion/index.d.ts +5 -0
- package/lib/components/Accordion/styles.d.ts +17 -0
- package/lib/components/Accordion/tokens.d.ts +12 -0
- package/lib/components/Accordion/types.d.ts +180 -0
- package/lib/components/Alert/Alert.d.ts +2 -0
- package/lib/components/Alert/index.d.ts +2 -0
- package/lib/components/Alert/types.d.ts +25 -0
- package/lib/components/AppShell/AppShell.d.ts +48 -0
- package/lib/components/AppShell/BottomAppBar.d.ts +3 -0
- package/lib/components/AppShell/MobileMenu.d.ts +10 -0
- package/lib/components/AppShell/StatusBarManager.d.ts +7 -0
- package/lib/components/AppShell/app-layout/AppLayoutProvider.d.ts +8 -0
- package/lib/components/AppShell/app-layout/AppLayoutRenderer.d.ts +5 -0
- package/lib/components/AppShell/app-layout/context.d.ts +4 -0
- package/lib/components/AppShell/app-layout/defineAppLayout.d.ts +2 -0
- package/lib/components/AppShell/app-layout/index.d.ts +5 -0
- package/lib/components/AppShell/app-layout/types.d.ts +120 -0
- package/lib/components/AppShell/context.d.ts +44 -0
- package/lib/components/AppShell/defaults.d.ts +6 -0
- package/lib/components/AppShell/hooks/useBreakpoint.d.ts +9 -0
- package/lib/components/AppShell/hooks/useResponsiveValue.d.ts +2 -0
- package/lib/components/AppShell/index.d.ts +12 -0
- package/lib/components/AppShell/meta.schema.d.ts +14 -0
- package/lib/components/AppShell/types.d.ts +228 -0
- package/lib/components/AppStoreBadge/AppStoreBadge.d.ts +5 -0
- package/lib/components/AppStoreBadge/ConvenienceComponents.d.ts +88 -0
- package/lib/components/AppStoreBadge/examples/usage-examples.d.ts +4 -0
- package/lib/components/AppStoreBadge/index.d.ts +3 -0
- package/lib/components/AppStoreBadge/types.d.ts +36 -0
- package/lib/components/AppStoreButton/AppStoreButton.d.ts +5 -0
- package/lib/components/AppStoreButton/ConvenienceComponents.d.ts +8 -0
- package/lib/components/AppStoreButton/index.d.ts +3 -0
- package/lib/components/AppStoreButton/types.d.ts +36 -0
- package/lib/components/AudioPlayer/AudioPlayer.d.ts +3 -0
- package/lib/components/AudioPlayer/AudioPlayerDemo.d.ts +2 -0
- package/lib/components/AudioPlayer/index.d.ts +2 -0
- package/lib/components/AudioPlayer/types.d.ts +232 -0
- package/lib/components/AutoComplete/AutoComplete.d.ts +6 -0
- package/lib/components/AutoComplete/index.d.ts +2 -0
- package/lib/components/AutoComplete/types.d.ts +120 -0
- package/lib/components/Avatar/Avatar.d.ts +3 -0
- package/lib/components/Avatar/AvatarGroup.d.ts +3 -0
- package/lib/components/Avatar/index.d.ts +3 -0
- package/lib/components/Avatar/types.d.ts +30 -0
- package/lib/components/Badge/Badge.d.ts +4 -0
- package/lib/components/Badge/index.d.ts +3 -0
- package/lib/components/Badge/types.d.ts +26 -0
- package/lib/components/Block/Block.d.ts +36 -0
- package/lib/components/Block/index.d.ts +2 -0
- package/lib/components/Block/types.d.ts +102 -0
- package/lib/components/Block/utils.d.ts +28 -0
- package/lib/components/Blockquote/Blockquote.d.ts +3 -0
- package/lib/components/Blockquote/BlockquoteAttribution.d.ts +3 -0
- package/lib/components/Blockquote/BlockquoteAuthor.d.ts +3 -0
- package/lib/components/Blockquote/BlockquoteMeta.d.ts +3 -0
- package/lib/components/Blockquote/BlockquoteSource.d.ts +3 -0
- package/lib/components/Blockquote/index.d.ts +6 -0
- package/lib/components/Blockquote/styles.d.ts +80 -0
- package/lib/components/Blockquote/types.d.ts +74 -0
- package/lib/components/BrandButton/BrandButton.d.ts +3 -0
- package/lib/components/BrandButton/index.d.ts +2 -0
- package/lib/components/BrandButton/types.d.ts +23 -0
- package/lib/components/BrandIcon/BrandIcon.d.ts +27 -0
- package/lib/components/BrandIcon/brands.d.ts +520 -0
- package/lib/components/BrandIcon/index.d.ts +2 -0
- package/lib/components/Breadcrumbs/Breadcrumbs.d.ts +6 -0
- package/lib/components/Breadcrumbs/index.d.ts +2 -0
- package/lib/components/Breadcrumbs/types.d.ts +35 -0
- package/lib/components/Button/Button.d.ts +3 -0
- package/lib/components/Button/SoundButton.d.ts +22 -0
- package/lib/components/Button/defaults.d.ts +7 -0
- package/lib/components/Button/index.d.ts +2 -0
- package/lib/components/Button/styles/resolver.d.ts +7 -0
- package/lib/components/Button/tokens.d.ts +16 -0
- package/lib/components/Button/types.d.ts +67 -0
- package/lib/components/Calendar/Calendar.d.ts +3 -0
- package/lib/components/Calendar/Day.d.ts +3 -0
- package/lib/components/Calendar/Month.d.ts +3 -0
- package/lib/components/Calendar/MonthPicker.d.ts +2 -0
- package/lib/components/Calendar/YearPicker.d.ts +2 -0
- package/lib/components/Calendar/index.d.ts +8 -0
- package/lib/components/Calendar/types.d.ts +92 -0
- package/lib/components/Calendar/utils.d.ts +31 -0
- package/lib/components/Can/Can.d.ts +30 -0
- package/lib/components/Can/PermissionDemo.d.ts +2 -0
- package/lib/components/Can/ability.d.ts +89 -0
- package/lib/components/Can/builder.d.ts +113 -0
- package/lib/components/Can/context.d.ts +25 -0
- package/lib/components/Can/index.d.ts +6 -0
- package/lib/components/Can/types.d.ts +228 -0
- package/lib/components/Card/Card.d.ts +3 -0
- package/lib/components/Card/index.d.ts +2 -0
- package/lib/components/Card/types.d.ts +15 -0
- package/lib/components/Carousel/Carousel.d.ts +4 -0
- package/lib/components/Carousel/index.d.ts +2 -0
- package/lib/components/Carousel/styles.d.ts +21 -0
- package/lib/components/Carousel/types.d.ts +51 -0
- package/lib/components/Checkbox/Checkbox.d.ts +4 -0
- package/lib/components/Checkbox/index.d.ts +2 -0
- package/lib/components/Checkbox/styles.d.ts +71 -0
- package/lib/components/Checkbox/types.d.ts +52 -0
- package/lib/components/Chip/Chip.d.ts +4 -0
- package/lib/components/Chip/index.d.ts +3 -0
- package/lib/components/Chip/types.d.ts +22 -0
- package/lib/components/CodeBlock/CodeBlock.d.ts +16 -0
- package/lib/components/CodeBlock/index.d.ts +3 -0
- package/lib/components/CodeBlock/type.d.ts +40 -0
- package/lib/components/CodeBlock/types.d.ts +44 -0
- package/lib/components/CodeBlock/utils.d.ts +38 -0
- package/lib/components/ColorPicker/ColorPicker.d.ts +8 -0
- package/lib/components/ColorPicker/index.d.ts +2 -0
- package/lib/components/ColorPicker/styles.d.ts +35 -0
- package/lib/components/ColorPicker/types.d.ts +69 -0
- package/lib/components/ColorPicker/utils.d.ts +8 -0
- package/lib/components/ColorSwatch/ColorSwatch.d.ts +6 -0
- package/lib/components/ColorSwatch/index.d.ts +2 -0
- package/lib/components/ColorSwatch/types.d.ts +29 -0
- package/lib/components/Container/Container.d.ts +3 -0
- package/lib/components/Container/index.d.ts +2 -0
- package/lib/components/Container/types.d.ts +31 -0
- package/lib/components/ContextMenu/ContextMenu.d.ts +5 -0
- package/lib/components/ContextMenu/index.d.ts +2 -0
- package/lib/components/ContextMenu/types.d.ts +36 -0
- package/lib/components/CopyButton/CopyButton.d.ts +10 -0
- package/lib/components/CopyButton/index.d.ts +2 -0
- package/lib/components/CopyButton/types.d.ts +37 -0
- package/lib/components/DataTable/AdvancedFilterControl.d.ts +10 -0
- package/lib/components/DataTable/ColumnSettings.d.ts +16 -0
- package/lib/components/DataTable/DataTable.d.ts +5 -0
- package/lib/components/DataTable/hooks/useColumnSettings.d.ts +12 -0
- package/lib/components/DataTable/hooks/useDataTableState.d.ts +41 -0
- package/lib/components/DataTable/hooks/useRowSelection.d.ts +40 -0
- package/lib/components/DataTable/index.d.ts +1 -0
- package/lib/components/DataTable/types.d.ts +223 -0
- package/lib/components/DatePicker/DatePicker.d.ts +4 -0
- package/lib/components/DatePicker/index.d.ts +8 -0
- package/lib/components/DatePicker/types.d.ts +47 -0
- package/lib/components/DatePicker/utils.d.ts +30 -0
- package/lib/components/DatePickerInput/DatePickerInput.d.ts +4 -0
- package/lib/components/DatePickerInput/index.d.ts +2 -0
- package/lib/components/DatePickerInput/types.d.ts +41 -0
- package/lib/components/Dialog/Dialog.d.ts +3 -0
- package/lib/components/Dialog/DialogContext.d.ts +11 -0
- package/lib/components/Dialog/DialogRenderer.d.ts +2 -0
- package/lib/components/Dialog/hooks/useSimpleDialog.d.ts +25 -0
- package/lib/components/Dialog/index.d.ts +6 -0
- package/lib/components/Dialog/types.d.ts +35 -0
- package/lib/components/Disclaimer/Disclaimer.d.ts +11 -0
- package/lib/components/Disclaimer/disclaimerUtils.d.ts +21 -0
- package/lib/components/Disclaimer/index.d.ts +6 -0
- package/lib/components/Disclaimer/withDisclaimer.d.ts +13 -0
- package/lib/components/Divider/Divider.d.ts +2 -0
- package/lib/components/Divider/index.d.ts +2 -0
- package/lib/components/Divider/types.d.ts +22 -0
- package/lib/components/EmojiPicker/EmojiPicker.d.ts +6 -0
- package/lib/components/EmojiPicker/index.d.ts +2 -0
- package/lib/components/EmojiPicker/types.d.ts +29 -0
- package/lib/components/FileInput/FileInput.d.ts +3 -0
- package/lib/components/FileInput/index.d.ts +2 -0
- package/lib/components/FileInput/types.d.ts +82 -0
- package/lib/components/Flex/Flex.d.ts +38 -0
- package/lib/components/Flex/helpers.d.ts +13 -0
- package/lib/components/Flex/index.d.ts +2 -0
- package/lib/components/FloatingActions/FloatingActions.d.ts +29 -0
- package/lib/components/FloatingActions/index.d.ts +2 -0
- package/lib/components/Form/FormBase.d.ts +3 -0
- package/lib/components/Form/FormContext.d.ts +16 -0
- package/lib/components/Form/FormError.d.ts +3 -0
- package/lib/components/Form/FormField.d.ts +3 -0
- package/lib/components/Form/FormInput.d.ts +3 -0
- package/lib/components/Form/FormLabel.d.ts +3 -0
- package/lib/components/Form/FormSubmit.d.ts +3 -0
- package/lib/components/Form/OptimizedForm.d.ts +22 -0
- package/lib/components/Form/index.d.ts +9 -0
- package/lib/components/Form/types.d.ts +104 -0
- package/lib/components/FormLayout/FormField.d.ts +3 -0
- package/lib/components/FormLayout/FormGroup.d.ts +3 -0
- package/lib/components/FormLayout/FormLayout.d.ts +3 -0
- package/lib/components/FormLayout/FormSection.d.ts +3 -0
- package/lib/components/FormLayout/index.d.ts +5 -0
- package/lib/components/FormLayout/types.d.ts +31 -0
- package/lib/components/Forms/ContactForm.d.ts +3 -0
- package/lib/components/Forms/ForgotPasswordForm.d.ts +3 -0
- package/lib/components/Forms/LoginForm.d.ts +3 -0
- package/lib/components/Forms/SignupForm.d.ts +3 -0
- package/lib/components/Forms/index.d.ts +5 -0
- package/lib/components/Forms/types.d.ts +89 -0
- package/lib/components/Gallery/Gallery.d.ts +3 -0
- package/lib/components/Gallery/GalleryControls.d.ts +3 -0
- package/lib/components/Gallery/GalleryMetadata.d.ts +3 -0
- package/lib/components/Gallery/GalleryNew.d.ts +3 -0
- package/lib/components/Gallery/GalleryThumbnails.d.ts +3 -0
- package/lib/components/Gallery/index.d.ts +5 -0
- package/lib/components/Gallery/types.d.ts +68 -0
- package/lib/components/Gauge/Gauge.d.ts +41 -0
- package/lib/components/Gauge/index.d.ts +9 -0
- package/lib/components/Gauge/styles.d.ts +57 -0
- package/lib/components/Gauge/types.d.ts +210 -0
- package/lib/components/Gauge/utils.d.ts +72 -0
- package/lib/components/GradientText/GradientText.d.ts +46 -0
- package/lib/components/GradientText/index.d.ts +2 -0
- package/lib/components/GradientText/types.d.ts +39 -0
- package/lib/components/Grid/Grid.d.ts +11 -0
- package/lib/components/Grid/index.d.ts +2 -0
- package/lib/components/Grid/types.d.ts +32 -0
- package/lib/components/HoverCard/HoverCard.d.ts +2 -0
- package/lib/components/HoverCard/index.d.ts +2 -0
- package/lib/components/HoverCard/types.d.ts +53 -0
- package/lib/components/Icon/Icon.d.ts +6 -0
- package/lib/components/Icon/icons/actions.d.ts +2 -0
- package/lib/components/Icon/icons/data.d.ts +2 -0
- package/lib/components/Icon/icons/multimedia.d.ts +2 -0
- package/lib/components/Icon/icons/navigation.d.ts +2 -0
- package/lib/components/Icon/icons/platforms.d.ts +2 -0
- package/lib/components/Icon/icons/status.d.ts +2 -0
- package/lib/components/Icon/icons/ui.d.ts +2 -0
- package/lib/components/Icon/index.d.ts +2 -0
- package/lib/components/Icon/registry.d.ts +6 -0
- package/lib/components/Icon/types.d.ts +40 -0
- package/lib/components/IconButton/IconButton.d.ts +3 -0
- package/lib/components/IconButton/index.d.ts +2 -0
- package/lib/components/IconButton/types.d.ts +45 -0
- package/lib/components/Image/Image.d.ts +3 -0
- package/lib/components/Image/index.d.ts +2 -0
- package/lib/components/Image/types.d.ts +57 -0
- package/lib/components/Indicator/Indicator.d.ts +7 -0
- package/lib/components/Indicator/index.d.ts +2 -0
- package/lib/components/Indicator/types.d.ts +13 -0
- package/lib/components/Input/Input.d.ts +6 -0
- package/lib/components/Input/InputBase.d.ts +17 -0
- package/lib/components/Input/OptimizedInput.d.ts +19 -0
- package/lib/components/Input/PasswordInput.d.ts +3 -0
- package/lib/components/Input/index.d.ts +5 -0
- package/lib/components/Input/styles.d.ts +85 -0
- package/lib/components/Input/types.d.ts +120 -0
- package/lib/components/Input/validation/index.d.ts +14 -0
- package/lib/components/Input/validation/optimized.d.ts +33 -0
- package/lib/components/KeyCap/KeyCap.d.ts +6 -0
- package/lib/components/KeyCap/index.d.ts +3 -0
- package/lib/components/KeyCap/styles.d.ts +11 -0
- package/lib/components/KeyCap/types.d.ts +54 -0
- package/lib/components/Layout/Layout.d.ts +18 -0
- package/lib/components/Layout/index.d.ts +1 -0
- package/lib/components/Link/Link.d.ts +31 -0
- package/lib/components/Link/index.d.ts +2 -0
- package/lib/components/ListGroup/ListGroup.d.ts +19 -0
- package/lib/components/ListGroup/index.d.ts +2 -0
- package/lib/components/ListGroup/types.d.ts +26 -0
- package/lib/components/Loader/Loader.d.ts +8 -0
- package/lib/components/Loader/index.d.ts +2 -0
- package/lib/components/Loader/types.d.ts +18 -0
- package/lib/components/LoadingOverlay/LoadingOverlay.d.ts +3 -0
- package/lib/components/LoadingOverlay/index.d.ts +2 -0
- package/lib/components/LoadingOverlay/types.d.ts +16 -0
- package/lib/components/Lottie/Lottie.d.ts +30 -0
- package/lib/components/Lottie/index.d.ts +2 -0
- package/lib/components/Markdown/Markdown.d.ts +66 -0
- package/lib/components/Markdown/index.d.ts +1 -0
- package/lib/components/Masonry/Masonry.d.ts +7 -0
- package/lib/components/Masonry/index.d.ts +2 -0
- package/lib/components/Masonry/types.d.ts +39 -0
- package/lib/components/Menu/Menu.d.ts +29 -0
- package/lib/components/Menu/index.d.ts +2 -0
- package/lib/components/Menu/styles.d.ts +13 -0
- package/lib/components/Menu/types.d.ts +71 -0
- package/lib/components/MenuItemButton/MenuItemButton.d.ts +39 -0
- package/lib/components/MenuItemButton/index.d.ts +2 -0
- package/lib/components/MiniCalendar/MiniCalendar.d.ts +3 -0
- package/lib/components/MiniCalendar/index.d.ts +1 -0
- package/lib/components/MonthPicker/MonthPicker.d.ts +3 -0
- package/lib/components/MonthPicker/index.d.ts +2 -0
- package/lib/components/MonthPicker/types.d.ts +26 -0
- package/lib/components/MonthPickerInput/MonthPickerInput.d.ts +4 -0
- package/lib/components/MonthPickerInput/index.d.ts +2 -0
- package/lib/components/MonthPickerInput/types.d.ts +30 -0
- package/lib/components/Navigation/DrawerNavigator.d.ts +7 -0
- package/lib/components/Navigation/NavigationContainer.d.ts +11 -0
- package/lib/components/Navigation/NavigationContext.d.ts +11 -0
- package/lib/components/Navigation/Screen.d.ts +6 -0
- package/lib/components/Navigation/StackNavigator.d.ts +7 -0
- package/lib/components/Navigation/index.d.ts +6 -0
- package/lib/components/Navigation/types.d.ts +70 -0
- package/lib/components/NavigationProgress/NavigationProgress.d.ts +4 -0
- package/lib/components/NavigationProgress/defaults.d.ts +8 -0
- package/lib/components/NavigationProgress/hooks/useNavigationProgressState.d.ts +1 -0
- package/lib/components/NavigationProgress/index.d.ts +2 -0
- package/lib/components/NavigationProgress/styles/resolver.d.ts +1 -0
- package/lib/components/NavigationProgress/tokens.d.ts +4 -0
- package/lib/components/NavigationProgress/types.d.ts +30 -0
- package/lib/components/NumberInput/NumberInput.d.ts +5 -0
- package/lib/components/NumberInput/index.d.ts +2 -0
- package/lib/components/NumberInput/types.d.ts +76 -0
- package/lib/components/Overlay/Overlay.d.ts +4 -0
- package/lib/components/Overlay/index.d.ts +2 -0
- package/lib/components/Overlay/types.d.ts +27 -0
- package/lib/components/Pagination/Pagination.d.ts +6 -0
- package/lib/components/Pagination/index.d.ts +2 -0
- package/lib/components/Pagination/types.d.ts +58 -0
- package/lib/components/PhoneInput/PhoneInput.d.ts +3 -0
- package/lib/components/PhoneInput/index.d.ts +2 -0
- package/lib/components/PhoneInput/types.d.ts +27 -0
- package/lib/components/PinInput/PinInput.d.ts +6 -0
- package/lib/components/PinInput/index.d.ts +2 -0
- package/lib/components/PinInput/types.d.ts +41 -0
- package/lib/components/PressAnimation/PressAnimation.d.ts +29 -0
- package/lib/components/PressAnimation/index.d.ts +2 -0
- package/lib/components/Progress/Progress.d.ts +11 -0
- package/lib/components/Progress/index.d.ts +2 -0
- package/lib/components/Progress/types.d.ts +48 -0
- package/lib/components/QRCode/QRCode.d.ts +11 -0
- package/lib/components/QRCode/QRCodeSVG.d.ts +6 -0
- package/lib/components/QRCode/core/buildMatrix.d.ts +11 -0
- package/lib/components/QRCode/core/encoder.d.ts +12 -0
- package/lib/components/QRCode/core/mask.d.ts +2 -0
- package/lib/components/QRCode/core/mode.d.ts +6 -0
- package/lib/components/QRCode/core/reedSolomon.d.ts +1 -0
- package/lib/components/QRCode/core/tables.d.ts +24 -0
- package/lib/components/QRCode/index.d.ts +3 -0
- package/lib/components/QRCode/optimizations.d.ts +20 -0
- package/lib/components/QRCode/types.d.ts +76 -0
- package/lib/components/Radio/Radio.d.ts +10 -0
- package/lib/components/Radio/index.d.ts +2 -0
- package/lib/components/Radio/styles.d.ts +81 -0
- package/lib/components/Radio/types.d.ts +79 -0
- package/lib/components/Rating/Rating.d.ts +2 -0
- package/lib/components/Rating/index.d.ts +2 -0
- package/lib/components/Rating/types.d.ts +35 -0
- package/lib/components/Reveal/Reveal.d.ts +4 -0
- package/lib/components/Reveal/index.d.ts +2 -0
- package/lib/components/Reveal/types.d.ts +53 -0
- package/lib/components/RichTextEditor/RichTextEditor.d.ts +3 -0
- package/lib/components/RichTextEditor/index.d.ts +2 -0
- package/lib/components/RichTextEditor/styles.d.ts +61 -0
- package/lib/components/RichTextEditor/types.d.ts +150 -0
- package/lib/components/Search/Search.d.ts +6 -0
- package/lib/components/Search/index.d.ts +2 -0
- package/lib/components/Search/test-component.d.ts +3 -0
- package/lib/components/Search/types.d.ts +27 -0
- package/lib/components/SegmentedControl/SegmentedControl.d.ts +6 -0
- package/lib/components/SegmentedControl/index.d.ts +2 -0
- package/lib/components/SegmentedControl/types.d.ts +62 -0
- package/lib/components/Select/Select.d.ts +6 -0
- package/lib/components/Select/Select.types.d.ts +31 -0
- package/lib/components/Select/index.d.ts +2 -0
- package/lib/components/Select/types.d.ts +25 -0
- package/lib/components/ShimmerText/ShimmerText.d.ts +33 -0
- package/lib/components/ShimmerText/index.d.ts +2 -0
- package/lib/components/ShimmerText/types.d.ts +33 -0
- package/lib/components/Skeleton/Skeleton.d.ts +2 -0
- package/lib/components/Skeleton/index.d.ts +2 -0
- package/lib/components/Skeleton/types.d.ts +30 -0
- package/lib/components/Slider/Slider.d.ts +10 -0
- package/lib/components/Slider/SliderCore.d.ts +57 -0
- package/lib/components/Slider/index.d.ts +2 -0
- package/lib/components/Slider/types.d.ts +133 -0
- package/lib/components/Space/Space.d.ts +4 -0
- package/lib/components/Space/index.d.ts +2 -0
- package/lib/components/Space/types.d.ts +17 -0
- package/lib/components/Spoiler/Spoiler.d.ts +5 -0
- package/lib/components/Spoiler/index.d.ts +2 -0
- package/lib/components/Spoiler/types.d.ts +40 -0
- package/lib/components/Spotlight/DirectSpotlightState.d.ts +41 -0
- package/lib/components/Spotlight/Spotlight.d.ts +19 -0
- package/lib/components/Spotlight/SpotlightController.d.ts +13 -0
- package/lib/components/Spotlight/SpotlightStore.d.ts +32 -0
- package/lib/components/Spotlight/SpotlightTypes.d.ts +29 -0
- package/lib/components/Spotlight/index.d.ts +6 -0
- package/lib/components/Spotlight/types.d.ts +66 -0
- package/lib/components/Stepper/Stepper.d.ts +12 -0
- package/lib/components/Stepper/index.d.ts +2 -0
- package/lib/components/Stepper/types.d.ts +68 -0
- package/lib/components/Switch/Switch.d.ts +6 -0
- package/lib/components/Switch/index.d.ts +2 -0
- package/lib/components/Switch/styles.d.ts +85 -0
- package/lib/components/Switch/types.d.ts +54 -0
- package/lib/components/Table/Table.d.ts +115 -0
- package/lib/components/Table/index.d.ts +1 -0
- package/lib/components/TableOfContents/TableOfContents.d.ts +3 -0
- package/lib/components/TableOfContents/index.d.ts +2 -0
- package/lib/components/TableOfContents/types.d.ts +77 -0
- package/lib/components/Tabs/Tabs.d.ts +3 -0
- package/lib/components/Tabs/index.d.ts +2 -0
- package/lib/components/Tabs/types.d.ts +182 -0
- package/lib/components/Text/Text.d.ts +51 -0
- package/lib/components/Text/aliases.d.ts +22 -0
- package/lib/components/Text/index.d.ts +2 -0
- package/lib/components/TextArea/TextArea.d.ts +6 -0
- package/lib/components/TextArea/index.d.ts +2 -0
- package/lib/components/TextArea/meta/index.d.ts +97 -0
- package/lib/components/TextArea/styles.d.ts +95 -0
- package/lib/components/TextArea/types.d.ts +33 -0
- package/lib/components/TimePicker/TimePicker.d.ts +3 -0
- package/lib/components/TimePicker/index.d.ts +2 -0
- package/lib/components/TimePicker/types.d.ts +32 -0
- package/lib/components/TimePickerInput/index.d.ts +2 -0
- package/lib/components/Timeline/Timeline.d.ts +13 -0
- package/lib/components/Timeline/index.d.ts +2 -0
- package/lib/components/Timeline/types.d.ts +53 -0
- package/lib/components/Title/Title.d.ts +10 -0
- package/lib/components/Title/index.d.ts +2 -0
- package/lib/components/Title/types.d.ts +55 -0
- package/lib/components/Toast/Toast.d.ts +8 -0
- package/lib/components/Toast/ToastProvider.d.ts +88 -0
- package/lib/components/Toast/index.d.ts +3 -0
- package/lib/components/Toast/types.d.ts +78 -0
- package/lib/components/Toggle/Toggle.d.ts +10 -0
- package/lib/components/Toggle/ToggleBar.d.ts +42 -0
- package/lib/components/Toggle/index.d.ts +4 -0
- package/lib/components/Toggle/types.d.ts +68 -0
- package/lib/components/Tooltip/Tooltip.d.ts +2 -0
- package/lib/components/Tooltip/index.d.ts +2 -0
- package/lib/components/Tooltip/types.d.ts +44 -0
- package/lib/components/Tree/Tree.d.ts +5 -0
- package/lib/components/Tree/index.d.ts +2 -0
- package/lib/components/Tree/types.d.ts +65 -0
- package/lib/components/Video/NativeVideoPlayer.d.ts +33 -0
- package/lib/components/Video/Video.d.ts +3 -0
- package/lib/components/Video/VideoControls.d.ts +17 -0
- package/lib/components/Video/VideoTimeline.d.ts +12 -0
- package/lib/components/Video/YouTubePlayer.d.ts +44 -0
- package/lib/components/Video/index.d.ts +2 -0
- package/lib/components/Video/types.d.ts +145 -0
- package/lib/components/Waveform/Waveform.d.ts +3 -0
- package/lib/components/Waveform/WaveformSkeleton.d.ts +9 -0
- package/lib/components/Waveform/index.d.ts +4 -0
- package/lib/components/Waveform/styles.d.ts +53 -0
- package/lib/components/Waveform/types.d.ts +124 -0
- package/lib/components/Waveform/utils.d.ts +95 -0
- package/lib/components/YearPicker/YearPicker.d.ts +3 -0
- package/lib/components/YearPicker/index.d.ts +2 -0
- package/lib/components/YearPicker/types.d.ts +24 -0
- package/lib/components/YearPickerInput/YearPickerInput.d.ts +4 -0
- package/lib/components/YearPickerInput/index.d.ts +2 -0
- package/lib/components/YearPickerInput/types.d.ts +26 -0
- package/lib/components/_internal/FieldHeader.d.ts +21 -0
- package/lib/components/index.d.ts +164 -0
- package/lib/components/optimized.d.ts +74 -0
- package/lib/components/types.d.ts +57 -0
- package/lib/contexts/TitleRegistryContext.d.ts +20 -0
- package/lib/contexts/index.d.ts +1 -0
- package/lib/core/accessibility/advancedHooks.d.ts +82 -0
- package/lib/core/accessibility/constants.d.ts +85 -0
- package/lib/core/accessibility/context.d.ts +5 -0
- package/lib/core/accessibility/hooks.d.ts +33 -0
- package/lib/core/accessibility/index.d.ts +6 -0
- package/lib/core/accessibility/types.d.ts +35 -0
- package/lib/core/accessibility/utils.d.ts +56 -0
- package/lib/core/animations/index.d.ts +2 -0
- package/lib/core/animations/transitions.d.ts +31 -0
- package/lib/core/components/ClearButton.d.ts +15 -0
- package/lib/core/components/InputContainer.d.ts +19 -0
- package/lib/core/design-tokens.d.ts +292 -0
- package/lib/core/factory/factory.d.ts +33 -0
- package/lib/core/factory/index.d.ts +4 -0
- package/lib/core/factory/polymorphicFactory.d.ts +38 -0
- package/lib/core/haptics/HapticsProvider.d.ts +14 -0
- package/lib/core/hooks/useDropdownPositioning.d.ts +61 -0
- package/lib/core/hooks/usePopoverPositioning.d.ts +33 -0
- package/lib/core/i18n/I18nContext.d.ts +8 -0
- package/lib/core/i18n/index.d.ts +2 -0
- package/lib/core/i18n/types.d.ts +22 -0
- package/lib/core/index.d.ts +15 -0
- package/lib/core/interactive-states.d.ts +41 -0
- package/lib/core/motion/ReducedMotionProvider.d.ts +10 -0
- package/lib/core/motion/motionTokens.d.ts +12 -0
- package/lib/core/providers/DirectionProvider.d.ts +88 -0
- package/lib/core/providers/OverlayProvider.d.ts +40 -0
- package/lib/core/providers/OverlayRenderer.d.ts +7 -0
- package/lib/core/providers/index.d.ts +5 -0
- package/lib/core/responsive/index.d.ts +22 -0
- package/lib/core/sound/context.d.ts +21 -0
- package/lib/core/sound/hooks.d.ts +214 -0
- package/lib/core/sound/index.d.ts +5 -0
- package/lib/core/sound/mockContext.d.ts +21 -0
- package/lib/core/sound/sounds.d.ts +17 -0
- package/lib/core/sound/types.d.ts +79 -0
- package/lib/core/style-factory.d.ts +23 -0
- package/lib/core/theme/CSSVariables.d.ts +9 -0
- package/lib/core/theme/PlatformBlocksProvider.d.ts +52 -0
- package/lib/core/theme/ThemeModeProvider.d.ts +42 -0
- package/lib/core/theme/ThemeProvider.d.ts +19 -0
- package/lib/core/theme/breakpoints.d.ts +34 -0
- package/lib/core/theme/darkTheme.d.ts +2 -0
- package/lib/core/theme/defaultTheme.d.ts +2 -0
- package/lib/core/theme/index.d.ts +12 -0
- package/lib/core/theme/radius.d.ts +132 -0
- package/lib/core/theme/shadow.d.ts +119 -0
- package/lib/core/theme/sizes.d.ts +185 -0
- package/lib/core/theme/types.d.ts +190 -0
- package/lib/core/theme/unified-sizing.d.ts +65 -0
- package/lib/core/theme/useColorScheme.d.ts +6 -0
- package/lib/core/theme/utils.d.ts +9 -0
- package/lib/core/unified-styles.d.ts +12 -0
- package/lib/core/utils/UniversalCSS.d.ts +14 -0
- package/lib/core/utils/debounce.d.ts +16 -0
- package/lib/core/utils/hash.d.ts +4 -0
- package/lib/core/utils/index.d.ts +38 -0
- package/lib/core/utils/layout.d.ts +44 -0
- package/lib/core/utils/performance.d.ts +30 -0
- package/lib/core/utils/positioning-enhanced.d.ts +88 -0
- package/lib/core/utils/rtl.d.ts +174 -0
- package/lib/core/utils/shadow.d.ts +13 -0
- package/lib/core/utils/spacing.d.ts +56 -0
- package/lib/core/utils/universal.d.ts +47 -0
- package/lib/core/utils/universalSimple.d.ts +37 -0
- package/lib/core/utils/withUniversalProps.d.ts +26 -0
- package/lib/esm/index.js +35209 -0
- package/lib/esm/index.js.map +1 -0
- package/lib/hooks/index.d.ts +6 -0
- package/lib/hooks/useClipboard.d.ts +20 -0
- package/lib/hooks/useHaptics.d.ts +22 -0
- package/lib/hooks/useHotkeys.d.ts +42 -0
- package/lib/hooks/useMaskedInput.d.ts +35 -0
- package/lib/hooks/useScrollSpy.d.ts +38 -0
- package/lib/hooks/useTitleRegistration.d.ts +14 -0
- package/lib/index.d.ts +220 -0
- package/lib/utils/index.d.ts +1 -0
- package/lib/utils/mask.d.ts +138 -0
- package/package.json +148 -0
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
export interface Breakpoints {
|
|
2
|
+
/** Base breakpoint (0px) */
|
|
3
|
+
base: number;
|
|
4
|
+
/** Small phones / narrow screens */
|
|
5
|
+
sm: number;
|
|
6
|
+
/** Tablets / small desktop */
|
|
7
|
+
md: number;
|
|
8
|
+
/** Large desktop */
|
|
9
|
+
lg: number;
|
|
10
|
+
/** Wide screens */
|
|
11
|
+
xl: number;
|
|
12
|
+
}
|
|
13
|
+
export declare const DEFAULT_BREAKPOINTS: Breakpoints;
|
|
14
|
+
export type ResponsiveProp<T> = T | {
|
|
15
|
+
base?: T;
|
|
16
|
+
sm?: T;
|
|
17
|
+
md?: T;
|
|
18
|
+
lg?: T;
|
|
19
|
+
xl?: T;
|
|
20
|
+
};
|
|
21
|
+
/**
|
|
22
|
+
* Resolves a responsive prop value based on the current width and breakpoints
|
|
23
|
+
* @param value - The responsive prop value to resolve
|
|
24
|
+
* @param width - The current width to check against breakpoints
|
|
25
|
+
* @param breakpoints - The breakpoints configuration to use
|
|
26
|
+
* @returns The resolved value for the current width
|
|
27
|
+
*/
|
|
28
|
+
export declare function resolveResponsiveProp<T>(value: ResponsiveProp<T> | undefined, width: number, breakpoints?: Breakpoints): T | undefined;
|
|
29
|
+
/**
|
|
30
|
+
* Returns the first defined value from the provided arguments
|
|
31
|
+
* @param vals - Values to check for defined state
|
|
32
|
+
* @returns The first defined value or undefined if none are defined
|
|
33
|
+
*/
|
|
34
|
+
export declare function pickFirstDefined<T>(...vals: (T | undefined)[]): T | undefined;
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export type { PlatformBlocksTheme, PlatformBlocksThemeOverride } from './types';
|
|
2
|
+
export { DEFAULT_THEME } from './defaultTheme';
|
|
3
|
+
export { DARK_THEME } from './darkTheme';
|
|
4
|
+
export { mergeTheme, createTheme } from './utils';
|
|
5
|
+
export { PlatformBlocksThemeProvider, useTheme, useSafePlatformBlocksTheme } from './ThemeProvider';
|
|
6
|
+
export { CSSVariables } from './CSSVariables';
|
|
7
|
+
export { useColorScheme } from './useColorScheme';
|
|
8
|
+
export type { ColorScheme } from './useColorScheme';
|
|
9
|
+
export type { PlatformBlocksThemeProviderProps } from './ThemeProvider';
|
|
10
|
+
export * from './sizes';
|
|
11
|
+
export * from './radius';
|
|
12
|
+
export * from './shadow';
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
import { SizeValue } from './sizes';
|
|
2
|
+
export type RadiusValue = SizeValue | 'none' | 'full' | 'chip';
|
|
3
|
+
/**
|
|
4
|
+
* Enhanced radius scale with special values
|
|
5
|
+
*/
|
|
6
|
+
export declare const RADIUS_SCALE: {
|
|
7
|
+
readonly none: 0;
|
|
8
|
+
readonly xs: 2;
|
|
9
|
+
readonly sm: 4;
|
|
10
|
+
readonly md: 6;
|
|
11
|
+
readonly lg: 8;
|
|
12
|
+
readonly xl: 30;
|
|
13
|
+
readonly '2xl': 16;
|
|
14
|
+
readonly '3xl': 20;
|
|
15
|
+
readonly full: 9999;
|
|
16
|
+
readonly chip: 9999;
|
|
17
|
+
};
|
|
18
|
+
/**
|
|
19
|
+
* Get border radius value from radius token or number
|
|
20
|
+
* @param value - Radius value (string token, number, or special value)
|
|
21
|
+
* @param componentHeight - Height of component for chip/full calculation
|
|
22
|
+
* @returns Resolved border radius as number
|
|
23
|
+
*/
|
|
24
|
+
export declare function getBorderRadius(value: RadiusValue | undefined, componentHeight?: number): number;
|
|
25
|
+
/**
|
|
26
|
+
* Get component-specific default radius
|
|
27
|
+
*/
|
|
28
|
+
export declare const COMPONENT_RADIUS_DEFAULTS: {
|
|
29
|
+
readonly button: RadiusValue;
|
|
30
|
+
readonly card: RadiusValue;
|
|
31
|
+
readonly chip: RadiusValue;
|
|
32
|
+
readonly input: RadiusValue;
|
|
33
|
+
readonly modal: RadiusValue;
|
|
34
|
+
readonly tooltip: RadiusValue;
|
|
35
|
+
readonly alert: RadiusValue;
|
|
36
|
+
readonly badge: RadiusValue;
|
|
37
|
+
readonly indicator: RadiusValue;
|
|
38
|
+
readonly codeBlock: RadiusValue;
|
|
39
|
+
readonly progress: RadiusValue;
|
|
40
|
+
readonly switch: RadiusValue;
|
|
41
|
+
readonly checkbox: RadiusValue;
|
|
42
|
+
readonly radio: RadiusValue;
|
|
43
|
+
readonly slider: RadiusValue;
|
|
44
|
+
};
|
|
45
|
+
/**
|
|
46
|
+
* Border radius props interface for components
|
|
47
|
+
*/
|
|
48
|
+
export interface BorderRadiusProps {
|
|
49
|
+
/** Border radius value - supports size tokens, numbers, and special values */
|
|
50
|
+
radius?: RadiusValue;
|
|
51
|
+
}
|
|
52
|
+
/**
|
|
53
|
+
* Get the default radius for a specific component type
|
|
54
|
+
*/
|
|
55
|
+
export declare function getComponentDefaultRadius(componentType: keyof typeof COMPONENT_RADIUS_DEFAULTS): RadiusValue;
|
|
56
|
+
/**
|
|
57
|
+
* Create border radius styles object for React Native
|
|
58
|
+
*/
|
|
59
|
+
export declare function createRadiusStyles(radius: RadiusValue | undefined, componentHeight?: number, componentType?: keyof typeof COMPONENT_RADIUS_DEFAULTS): {
|
|
60
|
+
borderRadius: number;
|
|
61
|
+
borderTopLeftRadius: number;
|
|
62
|
+
borderTopRightRadius: number;
|
|
63
|
+
borderBottomLeftRadius: number;
|
|
64
|
+
borderBottomRightRadius: number;
|
|
65
|
+
};
|
|
66
|
+
/**
|
|
67
|
+
* Border radius utilities for specific corners
|
|
68
|
+
*/
|
|
69
|
+
export interface CornerRadiusProps extends BorderRadiusProps {
|
|
70
|
+
/** Top-left corner radius */
|
|
71
|
+
radiusTopLeft?: RadiusValue;
|
|
72
|
+
/** Top-right corner radius */
|
|
73
|
+
radiusTopRight?: RadiusValue;
|
|
74
|
+
/** Bottom-left corner radius */
|
|
75
|
+
radiusBottomLeft?: RadiusValue;
|
|
76
|
+
/** Bottom-right corner radius */
|
|
77
|
+
radiusBottomRight?: RadiusValue;
|
|
78
|
+
/** Top corners radius (overrides individual top corners) */
|
|
79
|
+
radiusTop?: RadiusValue;
|
|
80
|
+
/** Bottom corners radius (overrides individual bottom corners) */
|
|
81
|
+
radiusBottom?: RadiusValue;
|
|
82
|
+
/** Left corners radius (overrides individual left corners) */
|
|
83
|
+
radiusLeft?: RadiusValue;
|
|
84
|
+
/** Right corners radius (overrides individual right corners) */
|
|
85
|
+
radiusRight?: RadiusValue;
|
|
86
|
+
}
|
|
87
|
+
/**
|
|
88
|
+
* Create advanced border radius styles with individual corner control
|
|
89
|
+
*/
|
|
90
|
+
export declare function createAdvancedRadiusStyles(props: CornerRadiusProps, componentHeight?: number, componentType?: keyof typeof COMPONENT_RADIUS_DEFAULTS): {
|
|
91
|
+
borderTopLeftRadius: number;
|
|
92
|
+
borderTopRightRadius: number;
|
|
93
|
+
borderBottomLeftRadius: number;
|
|
94
|
+
borderBottomRightRadius: number;
|
|
95
|
+
borderRadius: number;
|
|
96
|
+
};
|
|
97
|
+
declare const _default: {
|
|
98
|
+
getBorderRadius: typeof getBorderRadius;
|
|
99
|
+
createRadiusStyles: typeof createRadiusStyles;
|
|
100
|
+
createAdvancedRadiusStyles: typeof createAdvancedRadiusStyles;
|
|
101
|
+
RADIUS_SCALE: {
|
|
102
|
+
readonly none: 0;
|
|
103
|
+
readonly xs: 2;
|
|
104
|
+
readonly sm: 4;
|
|
105
|
+
readonly md: 6;
|
|
106
|
+
readonly lg: 8;
|
|
107
|
+
readonly xl: 30;
|
|
108
|
+
readonly '2xl': 16;
|
|
109
|
+
readonly '3xl': 20;
|
|
110
|
+
readonly full: 9999;
|
|
111
|
+
readonly chip: 9999;
|
|
112
|
+
};
|
|
113
|
+
COMPONENT_RADIUS_DEFAULTS: {
|
|
114
|
+
readonly button: RadiusValue;
|
|
115
|
+
readonly card: RadiusValue;
|
|
116
|
+
readonly chip: RadiusValue;
|
|
117
|
+
readonly input: RadiusValue;
|
|
118
|
+
readonly modal: RadiusValue;
|
|
119
|
+
readonly tooltip: RadiusValue;
|
|
120
|
+
readonly alert: RadiusValue;
|
|
121
|
+
readonly badge: RadiusValue;
|
|
122
|
+
readonly indicator: RadiusValue;
|
|
123
|
+
readonly codeBlock: RadiusValue;
|
|
124
|
+
readonly progress: RadiusValue;
|
|
125
|
+
readonly switch: RadiusValue;
|
|
126
|
+
readonly checkbox: RadiusValue;
|
|
127
|
+
readonly radio: RadiusValue;
|
|
128
|
+
readonly slider: RadiusValue;
|
|
129
|
+
};
|
|
130
|
+
getComponentDefaultRadius: typeof getComponentDefaultRadius;
|
|
131
|
+
};
|
|
132
|
+
export default _default;
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
import { SizeValue } from './sizes';
|
|
2
|
+
import { PlatformBlocksTheme } from './types';
|
|
3
|
+
export type ShadowValue = SizeValue | 'none';
|
|
4
|
+
/**
|
|
5
|
+
* Shadow props interface for components
|
|
6
|
+
*/
|
|
7
|
+
export interface ShadowProps {
|
|
8
|
+
/** Shadow value - supports size tokens and 'none' */
|
|
9
|
+
shadow?: ShadowValue;
|
|
10
|
+
}
|
|
11
|
+
/**
|
|
12
|
+
* Get shadow value from shadow token
|
|
13
|
+
* @param value - Shadow value (string token or 'none')
|
|
14
|
+
* @param theme - PlatformBlocks theme object
|
|
15
|
+
* @returns Resolved shadow string or undefined for none
|
|
16
|
+
*/
|
|
17
|
+
export declare function getShadowValue(value: ShadowValue | undefined, theme: PlatformBlocksTheme): string | undefined;
|
|
18
|
+
/**
|
|
19
|
+
* Component-specific default shadows
|
|
20
|
+
*/
|
|
21
|
+
export declare const COMPONENT_SHADOW_DEFAULTS: {
|
|
22
|
+
readonly button: ShadowValue;
|
|
23
|
+
readonly badge: ShadowValue;
|
|
24
|
+
readonly card: ShadowValue;
|
|
25
|
+
readonly chip: ShadowValue;
|
|
26
|
+
readonly modal: ShadowValue;
|
|
27
|
+
readonly tooltip: ShadowValue;
|
|
28
|
+
readonly alert: ShadowValue;
|
|
29
|
+
readonly dialog: ShadowValue;
|
|
30
|
+
readonly dropdown: ShadowValue;
|
|
31
|
+
readonly popover: ShadowValue;
|
|
32
|
+
readonly toast: ShadowValue;
|
|
33
|
+
readonly fab: ShadowValue;
|
|
34
|
+
readonly appBar: ShadowValue;
|
|
35
|
+
readonly drawer: ShadowValue;
|
|
36
|
+
};
|
|
37
|
+
/**
|
|
38
|
+
* Get the default shadow for a specific component type
|
|
39
|
+
*/
|
|
40
|
+
export declare function getComponentDefaultShadow(componentType: keyof typeof COMPONENT_SHADOW_DEFAULTS): ShadowValue;
|
|
41
|
+
/**
|
|
42
|
+
* Create shadow styles object for React Native
|
|
43
|
+
*/
|
|
44
|
+
export declare function createShadowStyles(shadow: ShadowValue | undefined, theme: PlatformBlocksTheme, componentType?: keyof typeof COMPONENT_SHADOW_DEFAULTS): {
|
|
45
|
+
boxShadow?: undefined;
|
|
46
|
+
shadowOffset?: undefined;
|
|
47
|
+
shadowRadius?: undefined;
|
|
48
|
+
shadowColor?: undefined;
|
|
49
|
+
shadowOpacity?: undefined;
|
|
50
|
+
elevation?: undefined;
|
|
51
|
+
} | {
|
|
52
|
+
boxShadow: string;
|
|
53
|
+
shadowOffset?: undefined;
|
|
54
|
+
shadowRadius?: undefined;
|
|
55
|
+
shadowColor?: undefined;
|
|
56
|
+
shadowOpacity?: undefined;
|
|
57
|
+
elevation?: undefined;
|
|
58
|
+
} | {
|
|
59
|
+
shadowOffset: {
|
|
60
|
+
width: number;
|
|
61
|
+
height: number;
|
|
62
|
+
};
|
|
63
|
+
shadowRadius: number;
|
|
64
|
+
shadowColor: string;
|
|
65
|
+
shadowOpacity: number;
|
|
66
|
+
elevation: number;
|
|
67
|
+
boxShadow?: undefined;
|
|
68
|
+
};
|
|
69
|
+
/**
|
|
70
|
+
* Utility to get shadow styles with theme context
|
|
71
|
+
*/
|
|
72
|
+
export declare function useShadowStyles(shadow: ShadowValue | undefined, theme: PlatformBlocksTheme, componentType?: keyof typeof COMPONENT_SHADOW_DEFAULTS): {
|
|
73
|
+
boxShadow?: undefined;
|
|
74
|
+
shadowOffset?: undefined;
|
|
75
|
+
shadowRadius?: undefined;
|
|
76
|
+
shadowColor?: undefined;
|
|
77
|
+
shadowOpacity?: undefined;
|
|
78
|
+
elevation?: undefined;
|
|
79
|
+
} | {
|
|
80
|
+
boxShadow: string;
|
|
81
|
+
shadowOffset?: undefined;
|
|
82
|
+
shadowRadius?: undefined;
|
|
83
|
+
shadowColor?: undefined;
|
|
84
|
+
shadowOpacity?: undefined;
|
|
85
|
+
elevation?: undefined;
|
|
86
|
+
} | {
|
|
87
|
+
shadowOffset: {
|
|
88
|
+
width: number;
|
|
89
|
+
height: number;
|
|
90
|
+
};
|
|
91
|
+
shadowRadius: number;
|
|
92
|
+
shadowColor: string;
|
|
93
|
+
shadowOpacity: number;
|
|
94
|
+
elevation: number;
|
|
95
|
+
boxShadow?: undefined;
|
|
96
|
+
};
|
|
97
|
+
declare const _default: {
|
|
98
|
+
getShadowValue: typeof getShadowValue;
|
|
99
|
+
createShadowStyles: typeof createShadowStyles;
|
|
100
|
+
useShadowStyles: typeof useShadowStyles;
|
|
101
|
+
COMPONENT_SHADOW_DEFAULTS: {
|
|
102
|
+
readonly button: ShadowValue;
|
|
103
|
+
readonly badge: ShadowValue;
|
|
104
|
+
readonly card: ShadowValue;
|
|
105
|
+
readonly chip: ShadowValue;
|
|
106
|
+
readonly modal: ShadowValue;
|
|
107
|
+
readonly tooltip: ShadowValue;
|
|
108
|
+
readonly alert: ShadowValue;
|
|
109
|
+
readonly dialog: ShadowValue;
|
|
110
|
+
readonly dropdown: ShadowValue;
|
|
111
|
+
readonly popover: ShadowValue;
|
|
112
|
+
readonly toast: ShadowValue;
|
|
113
|
+
readonly fab: ShadowValue;
|
|
114
|
+
readonly appBar: ShadowValue;
|
|
115
|
+
readonly drawer: ShadowValue;
|
|
116
|
+
};
|
|
117
|
+
getComponentDefaultShadow: typeof getComponentDefaultShadow;
|
|
118
|
+
};
|
|
119
|
+
export default _default;
|
|
@@ -0,0 +1,185 @@
|
|
|
1
|
+
export type SizeValue = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | '3xl' | number;
|
|
2
|
+
export interface SizeScale {
|
|
3
|
+
xs: number;
|
|
4
|
+
sm: number;
|
|
5
|
+
md: number;
|
|
6
|
+
lg: number;
|
|
7
|
+
xl: number;
|
|
8
|
+
'2xl': number;
|
|
9
|
+
'3xl': number;
|
|
10
|
+
}
|
|
11
|
+
export declare const SIZE_SCALES: {
|
|
12
|
+
readonly fontSize: {
|
|
13
|
+
readonly xs: 10;
|
|
14
|
+
readonly sm: 12;
|
|
15
|
+
readonly md: 14;
|
|
16
|
+
readonly lg: 16;
|
|
17
|
+
readonly xl: 18;
|
|
18
|
+
readonly '2xl': 20;
|
|
19
|
+
readonly '3xl': 24;
|
|
20
|
+
};
|
|
21
|
+
readonly spacing: {
|
|
22
|
+
readonly xs: 4;
|
|
23
|
+
readonly sm: 8;
|
|
24
|
+
readonly md: 12;
|
|
25
|
+
readonly lg: 16;
|
|
26
|
+
readonly xl: 20;
|
|
27
|
+
readonly '2xl': 24;
|
|
28
|
+
readonly '3xl': 32;
|
|
29
|
+
};
|
|
30
|
+
readonly iconSize: {
|
|
31
|
+
readonly xs: 12;
|
|
32
|
+
readonly sm: 16;
|
|
33
|
+
readonly md: 20;
|
|
34
|
+
readonly lg: 24;
|
|
35
|
+
readonly xl: 28;
|
|
36
|
+
readonly '2xl': 32;
|
|
37
|
+
readonly '3xl': 40;
|
|
38
|
+
};
|
|
39
|
+
readonly height: {
|
|
40
|
+
readonly xs: 28;
|
|
41
|
+
readonly sm: 32;
|
|
42
|
+
readonly md: 36;
|
|
43
|
+
readonly lg: 44;
|
|
44
|
+
readonly xl: 52;
|
|
45
|
+
readonly '2xl': 60;
|
|
46
|
+
readonly '3xl': 68;
|
|
47
|
+
};
|
|
48
|
+
readonly radius: {
|
|
49
|
+
readonly xs: 2;
|
|
50
|
+
readonly sm: 4;
|
|
51
|
+
readonly md: 6;
|
|
52
|
+
readonly lg: 8;
|
|
53
|
+
readonly xl: 12;
|
|
54
|
+
readonly '2xl': 16;
|
|
55
|
+
readonly '3xl': 20;
|
|
56
|
+
};
|
|
57
|
+
readonly lineHeight: {
|
|
58
|
+
readonly xs: 1.2;
|
|
59
|
+
readonly sm: 1.3;
|
|
60
|
+
readonly md: 1.4;
|
|
61
|
+
readonly lg: 1.5;
|
|
62
|
+
readonly xl: 1.6;
|
|
63
|
+
readonly '2xl': 1.7;
|
|
64
|
+
readonly '3xl': 1.8;
|
|
65
|
+
};
|
|
66
|
+
};
|
|
67
|
+
/**
|
|
68
|
+
* Resolves a size value to a number
|
|
69
|
+
* @param value - Size value (string token or number)
|
|
70
|
+
* @param scale - Which scale to use for string tokens
|
|
71
|
+
* @param unit - Unit to append (default: no unit for React Native)
|
|
72
|
+
* @returns Resolved size as number or string with unit
|
|
73
|
+
*/
|
|
74
|
+
export declare function resolveSize(value: SizeValue | undefined, scale: keyof typeof SIZE_SCALES, unit?: 'px' | 'rem' | 'em' | ''): number | string;
|
|
75
|
+
/**
|
|
76
|
+
* Get font size from size value
|
|
77
|
+
*/
|
|
78
|
+
export declare function getFontSize(size: SizeValue | undefined): number;
|
|
79
|
+
/**
|
|
80
|
+
* Get spacing from size value
|
|
81
|
+
*/
|
|
82
|
+
export declare function getSpacing(size: SizeValue | undefined): number;
|
|
83
|
+
/**
|
|
84
|
+
* Get icon size from size value
|
|
85
|
+
*/
|
|
86
|
+
export declare function getIconSize(size: SizeValue | undefined): number;
|
|
87
|
+
/**
|
|
88
|
+
* Get height from size value
|
|
89
|
+
*/
|
|
90
|
+
export declare function getHeight(size: SizeValue | undefined): number;
|
|
91
|
+
/**
|
|
92
|
+
* Get border radius from size value
|
|
93
|
+
*/
|
|
94
|
+
export declare function getRadius(size: SizeValue | undefined): number;
|
|
95
|
+
/**
|
|
96
|
+
* Get line height from size value
|
|
97
|
+
* For numeric values, returns a reasonable line height multiplier
|
|
98
|
+
* For string values, uses the predefined line height scale
|
|
99
|
+
*/
|
|
100
|
+
export declare function getLineHeight(size: SizeValue | undefined): number;
|
|
101
|
+
export declare const COMPONENT_SIZES: {
|
|
102
|
+
readonly button: {
|
|
103
|
+
readonly xs: {
|
|
104
|
+
readonly fontSize: "xs";
|
|
105
|
+
readonly spacing: "xs";
|
|
106
|
+
readonly height: "xs";
|
|
107
|
+
};
|
|
108
|
+
readonly sm: {
|
|
109
|
+
readonly fontSize: "sm";
|
|
110
|
+
readonly spacing: "sm";
|
|
111
|
+
readonly height: "sm";
|
|
112
|
+
};
|
|
113
|
+
readonly md: {
|
|
114
|
+
readonly fontSize: "md";
|
|
115
|
+
readonly spacing: "md";
|
|
116
|
+
readonly height: "md";
|
|
117
|
+
};
|
|
118
|
+
readonly lg: {
|
|
119
|
+
readonly fontSize: "lg";
|
|
120
|
+
readonly spacing: "lg";
|
|
121
|
+
readonly height: "lg";
|
|
122
|
+
};
|
|
123
|
+
readonly xl: {
|
|
124
|
+
readonly fontSize: "xl";
|
|
125
|
+
readonly spacing: "xl";
|
|
126
|
+
readonly height: "xl";
|
|
127
|
+
};
|
|
128
|
+
readonly '2xl': {
|
|
129
|
+
readonly fontSize: "2xl";
|
|
130
|
+
readonly spacing: "2xl";
|
|
131
|
+
readonly height: "2xl";
|
|
132
|
+
};
|
|
133
|
+
readonly '3xl': {
|
|
134
|
+
readonly fontSize: "3xl";
|
|
135
|
+
readonly spacing: "3xl";
|
|
136
|
+
readonly height: "3xl";
|
|
137
|
+
};
|
|
138
|
+
};
|
|
139
|
+
readonly chip: {
|
|
140
|
+
readonly xs: {
|
|
141
|
+
readonly fontSize: "xs";
|
|
142
|
+
readonly spacing: "xs";
|
|
143
|
+
readonly height: "xs";
|
|
144
|
+
};
|
|
145
|
+
readonly sm: {
|
|
146
|
+
readonly fontSize: "xs";
|
|
147
|
+
readonly spacing: "sm";
|
|
148
|
+
readonly height: "sm";
|
|
149
|
+
};
|
|
150
|
+
readonly md: {
|
|
151
|
+
readonly fontSize: "sm";
|
|
152
|
+
readonly spacing: "sm";
|
|
153
|
+
readonly height: "md";
|
|
154
|
+
};
|
|
155
|
+
readonly lg: {
|
|
156
|
+
readonly fontSize: "sm";
|
|
157
|
+
readonly spacing: "md";
|
|
158
|
+
readonly height: "lg";
|
|
159
|
+
};
|
|
160
|
+
readonly xl: {
|
|
161
|
+
readonly fontSize: "md";
|
|
162
|
+
readonly spacing: "md";
|
|
163
|
+
readonly height: "xl";
|
|
164
|
+
};
|
|
165
|
+
readonly '2xl': {
|
|
166
|
+
readonly fontSize: "lg";
|
|
167
|
+
readonly spacing: "lg";
|
|
168
|
+
readonly height: "2xl";
|
|
169
|
+
};
|
|
170
|
+
readonly '3xl': {
|
|
171
|
+
readonly fontSize: "xl";
|
|
172
|
+
readonly spacing: "xl";
|
|
173
|
+
readonly height: "3xl";
|
|
174
|
+
};
|
|
175
|
+
};
|
|
176
|
+
readonly badge: {
|
|
177
|
+
readonly xs: 8;
|
|
178
|
+
readonly sm: 10;
|
|
179
|
+
readonly md: 14;
|
|
180
|
+
readonly lg: 18;
|
|
181
|
+
readonly xl: 22;
|
|
182
|
+
readonly '2xl': 26;
|
|
183
|
+
readonly '3xl': 30;
|
|
184
|
+
};
|
|
185
|
+
};
|
|
@@ -0,0 +1,190 @@
|
|
|
1
|
+
export type SizeValue = 'xs' | 'sm' | 'md' | 'lg' | 'xl' | '2xl' | '3xl';
|
|
2
|
+
export type ColorValue = string;
|
|
3
|
+
export type SpacingValue = SizeValue | 'auto' | '0' | number;
|
|
4
|
+
import type { DESIGN_TOKENS } from '../design-tokens';
|
|
5
|
+
export interface SpacingProps {
|
|
6
|
+
/** Margin on all sides */
|
|
7
|
+
m?: SpacingValue;
|
|
8
|
+
/** Margin top */
|
|
9
|
+
mt?: SpacingValue;
|
|
10
|
+
/** Margin right */
|
|
11
|
+
mr?: SpacingValue;
|
|
12
|
+
/** Margin bottom */
|
|
13
|
+
mb?: SpacingValue;
|
|
14
|
+
/** Margin left */
|
|
15
|
+
ml?: SpacingValue;
|
|
16
|
+
/** Margin horizontal (left and right) */
|
|
17
|
+
mx?: SpacingValue;
|
|
18
|
+
/** Margin vertical (top and bottom) */
|
|
19
|
+
my?: SpacingValue;
|
|
20
|
+
/** Padding on all sides */
|
|
21
|
+
p?: SpacingValue;
|
|
22
|
+
/** Padding top */
|
|
23
|
+
pt?: SpacingValue;
|
|
24
|
+
/** Padding right */
|
|
25
|
+
pr?: SpacingValue;
|
|
26
|
+
/** Padding bottom */
|
|
27
|
+
pb?: SpacingValue;
|
|
28
|
+
/** Padding left */
|
|
29
|
+
pl?: SpacingValue;
|
|
30
|
+
/** Padding horizontal (left and right) */
|
|
31
|
+
px?: SpacingValue;
|
|
32
|
+
/** Padding vertical (top and bottom) */
|
|
33
|
+
py?: SpacingValue;
|
|
34
|
+
}
|
|
35
|
+
export interface PlatformBlocksTheme {
|
|
36
|
+
/** Primary color used for buttons, links, etc. */
|
|
37
|
+
primaryColor: string;
|
|
38
|
+
/** Color scheme */
|
|
39
|
+
colorScheme: 'light' | 'dark';
|
|
40
|
+
/** Design tokens for consistent styling */
|
|
41
|
+
designTokens?: typeof DESIGN_TOKENS;
|
|
42
|
+
/** Colors palette */
|
|
43
|
+
colors: {
|
|
44
|
+
primary: string[];
|
|
45
|
+
secondary: string[];
|
|
46
|
+
tertiary: string[];
|
|
47
|
+
surface: string[];
|
|
48
|
+
success: string[];
|
|
49
|
+
warning: string[];
|
|
50
|
+
error: string[];
|
|
51
|
+
gray: string[];
|
|
52
|
+
highlight: string[];
|
|
53
|
+
pink?: string[];
|
|
54
|
+
purple?: string[];
|
|
55
|
+
violet?: string[];
|
|
56
|
+
cyan?: string[];
|
|
57
|
+
lime?: string[];
|
|
58
|
+
sky?: string[];
|
|
59
|
+
amber?: string[];
|
|
60
|
+
indigo?: string[];
|
|
61
|
+
teal?: string[];
|
|
62
|
+
};
|
|
63
|
+
/** Semantic text colors */
|
|
64
|
+
text: {
|
|
65
|
+
/** Primary text color (high contrast) */
|
|
66
|
+
primary: string;
|
|
67
|
+
/** Secondary text color (medium contrast) */
|
|
68
|
+
secondary: string;
|
|
69
|
+
/** Muted text color (low contrast) */
|
|
70
|
+
muted: string;
|
|
71
|
+
/** Disabled text color (very low contrast) */
|
|
72
|
+
disabled: string;
|
|
73
|
+
/** Link text color (typically primary color) */
|
|
74
|
+
link: string;
|
|
75
|
+
/** Text color intended for use on top of primary[5] backgrounds */
|
|
76
|
+
onPrimary?: string;
|
|
77
|
+
};
|
|
78
|
+
/** Semantic background & surface colors */
|
|
79
|
+
backgrounds: {
|
|
80
|
+
/** Main app/page background */
|
|
81
|
+
base: string;
|
|
82
|
+
/** Subtle background sections (stripes, alternate rows) */
|
|
83
|
+
subtle: string;
|
|
84
|
+
/** Standard surface (cards, containers) */
|
|
85
|
+
surface: string;
|
|
86
|
+
/** Elevated surface (modals, popovers) */
|
|
87
|
+
elevated: string;
|
|
88
|
+
/** Border / hairline color for separators */
|
|
89
|
+
border: string;
|
|
90
|
+
};
|
|
91
|
+
/** Semantic interactive state colors */
|
|
92
|
+
states?: {
|
|
93
|
+
focusRing?: string;
|
|
94
|
+
textSelection?: string;
|
|
95
|
+
highlightText?: string;
|
|
96
|
+
highlightBackground?: string;
|
|
97
|
+
};
|
|
98
|
+
/** Font family */
|
|
99
|
+
fontFamily: string;
|
|
100
|
+
/** Font sizes - extended with new size system */
|
|
101
|
+
fontSizes: {
|
|
102
|
+
xs: string;
|
|
103
|
+
sm: string;
|
|
104
|
+
md: string;
|
|
105
|
+
lg: string;
|
|
106
|
+
xl: string;
|
|
107
|
+
'2xl': string;
|
|
108
|
+
'3xl': string;
|
|
109
|
+
};
|
|
110
|
+
/** Spacing values - extended with new size system */
|
|
111
|
+
spacing: {
|
|
112
|
+
xs: string;
|
|
113
|
+
sm: string;
|
|
114
|
+
md: string;
|
|
115
|
+
lg: string;
|
|
116
|
+
xl: string;
|
|
117
|
+
'2xl': string;
|
|
118
|
+
'3xl': string;
|
|
119
|
+
};
|
|
120
|
+
/** Border radius values - extended with new size system */
|
|
121
|
+
radii: {
|
|
122
|
+
xs: string;
|
|
123
|
+
sm: string;
|
|
124
|
+
md: string;
|
|
125
|
+
lg: string;
|
|
126
|
+
xl: string;
|
|
127
|
+
'2xl': string;
|
|
128
|
+
'3xl': string;
|
|
129
|
+
};
|
|
130
|
+
/** Shadows */
|
|
131
|
+
shadows: {
|
|
132
|
+
xs: string;
|
|
133
|
+
sm: string;
|
|
134
|
+
md: string;
|
|
135
|
+
lg: string;
|
|
136
|
+
xl: string;
|
|
137
|
+
};
|
|
138
|
+
/** Breakpoints for responsive design */
|
|
139
|
+
breakpoints: {
|
|
140
|
+
xs: string;
|
|
141
|
+
sm: string;
|
|
142
|
+
md: string;
|
|
143
|
+
lg: string;
|
|
144
|
+
xl: string;
|
|
145
|
+
};
|
|
146
|
+
/** Motion tokens for animations */
|
|
147
|
+
motion: {
|
|
148
|
+
/** Easing functions */
|
|
149
|
+
easing: {
|
|
150
|
+
ease: string;
|
|
151
|
+
easeIn: string;
|
|
152
|
+
easeOut: string;
|
|
153
|
+
easeInOut: string;
|
|
154
|
+
spring: string;
|
|
155
|
+
};
|
|
156
|
+
/** Duration tokens */
|
|
157
|
+
duration: {
|
|
158
|
+
instant: string;
|
|
159
|
+
fast: string;
|
|
160
|
+
normal: string;
|
|
161
|
+
slow: string;
|
|
162
|
+
};
|
|
163
|
+
};
|
|
164
|
+
/** Semantic color aliases */
|
|
165
|
+
semantic: {
|
|
166
|
+
/** Accent color (usually primary[6]) */
|
|
167
|
+
accent: string;
|
|
168
|
+
/** Default border color */
|
|
169
|
+
borderDefault: string;
|
|
170
|
+
/** Subtle border color */
|
|
171
|
+
borderSubtle: string;
|
|
172
|
+
/** Elevated surface color */
|
|
173
|
+
surfaceElevated: string;
|
|
174
|
+
/** Card surface color */
|
|
175
|
+
surfaceCard: string;
|
|
176
|
+
/** Focus outline color */
|
|
177
|
+
focusRing: string;
|
|
178
|
+
};
|
|
179
|
+
/** Component default props and styles (override point) */
|
|
180
|
+
components: Record<string, ComponentTokenOverride>;
|
|
181
|
+
/** Any additional custom theme properties */
|
|
182
|
+
other: Record<string, any>;
|
|
183
|
+
}
|
|
184
|
+
export type PlatformBlocksThemeOverride = Partial<PlatformBlocksTheme>;
|
|
185
|
+
export interface ComponentTokenOverride {
|
|
186
|
+
defaults?: Record<string, any>;
|
|
187
|
+
variants?: Record<string, any>;
|
|
188
|
+
sizes?: Record<string, any>;
|
|
189
|
+
[key: string]: any;
|
|
190
|
+
}
|