radix-native-ui 0.1.2 → 0.1.3
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 +1 -1
- package/dist/index.cjs +59 -53
- package/dist/index.d.cts +58 -31
- package/dist/index.d.mts +58 -31
- package/dist/index.mjs +59 -54
- package/package.json +16 -16
- package/LICENSE +0 -21
package/dist/index.d.mts
CHANGED
|
@@ -355,6 +355,12 @@ interface Theme extends ThemeTokens {
|
|
|
355
355
|
type ThemeMode = 'light' | 'dark';
|
|
356
356
|
type ThemeAppearance = 'light' | 'dark' | 'inherit';
|
|
357
357
|
type Color = 'white' | 'black' | 'gray' | 'gold' | 'bronze' | 'brown' | 'yellow' | 'amber' | 'orange' | 'tomato' | 'red' | 'ruby' | 'crimson' | 'pink' | 'plum' | 'purple' | 'violet' | 'iris' | 'indigo' | 'blue' | 'cyan' | 'teal' | 'jade' | 'green' | 'grass' | 'lime' | 'mint' | 'sky';
|
|
358
|
+
/**
|
|
359
|
+
* A color value: a theme color token (autocomplete-friendly) or any valid
|
|
360
|
+
* CSS/React Native color string such as '#ff8800' or 'rgba(...).'
|
|
361
|
+
*/
|
|
362
|
+
type ColorToken = Color;
|
|
363
|
+
type ColorValue = ColorToken | (string & {});
|
|
358
364
|
//#endregion
|
|
359
365
|
//#region src/theme/colors.d.ts
|
|
360
366
|
declare const gray: ColorScale;
|
|
@@ -1779,9 +1785,9 @@ declare const Separator: React$1.NamedExoticComponent<SeparatorProps>;
|
|
|
1779
1785
|
*/
|
|
1780
1786
|
type StackDirection = 'horizontal' | 'vertical';
|
|
1781
1787
|
/**
|
|
1782
|
-
* Gap
|
|
1788
|
+
* Gap between children in pixels (same semantics as Flex and Grid).
|
|
1783
1789
|
*/
|
|
1784
|
-
type StackGap =
|
|
1790
|
+
type StackGap = number;
|
|
1785
1791
|
/**
|
|
1786
1792
|
* Align items on cross axis
|
|
1787
1793
|
*/
|
|
@@ -1807,7 +1813,7 @@ interface StackProps {
|
|
|
1807
1813
|
*/
|
|
1808
1814
|
direction?: StackDirection;
|
|
1809
1815
|
/**
|
|
1810
|
-
* Gap between items
|
|
1816
|
+
* Gap between items in pixels
|
|
1811
1817
|
*/
|
|
1812
1818
|
gap?: StackGap;
|
|
1813
1819
|
/**
|
|
@@ -1848,7 +1854,7 @@ interface StackProps {
|
|
|
1848
1854
|
*/
|
|
1849
1855
|
flexShrink?: number;
|
|
1850
1856
|
/**
|
|
1851
|
-
* Padding
|
|
1857
|
+
* Padding in pixels
|
|
1852
1858
|
*/
|
|
1853
1859
|
padding?: StackGap;
|
|
1854
1860
|
/**
|
|
@@ -2052,7 +2058,7 @@ interface TextProps$1 {
|
|
|
2052
2058
|
/**
|
|
2053
2059
|
* Text color
|
|
2054
2060
|
*/
|
|
2055
|
-
color?:
|
|
2061
|
+
color?: ColorValue;
|
|
2056
2062
|
/**
|
|
2057
2063
|
* Whether to truncate text
|
|
2058
2064
|
*/
|
|
@@ -2120,7 +2126,7 @@ interface HeadingProps {
|
|
|
2120
2126
|
/**
|
|
2121
2127
|
* Text color
|
|
2122
2128
|
*/
|
|
2123
|
-
color?:
|
|
2129
|
+
color?: ColorValue;
|
|
2124
2130
|
/**
|
|
2125
2131
|
* Whether to truncate text
|
|
2126
2132
|
*/
|
|
@@ -2154,7 +2160,7 @@ interface StrongProps {
|
|
|
2154
2160
|
/**
|
|
2155
2161
|
* Text color
|
|
2156
2162
|
*/
|
|
2157
|
-
color?:
|
|
2163
|
+
color?: ColorValue;
|
|
2158
2164
|
}
|
|
2159
2165
|
declare const Strong: React$1.NamedExoticComponent<StrongProps & React$1.RefAttributes<Text$1>>;
|
|
2160
2166
|
//#endregion
|
|
@@ -2171,7 +2177,7 @@ interface EmProps {
|
|
|
2171
2177
|
/**
|
|
2172
2178
|
* Text color
|
|
2173
2179
|
*/
|
|
2174
|
-
color?:
|
|
2180
|
+
color?: ColorValue;
|
|
2175
2181
|
}
|
|
2176
2182
|
declare const Em: React$1.NamedExoticComponent<EmProps & React$1.RefAttributes<Text$1>>;
|
|
2177
2183
|
//#endregion
|
|
@@ -2193,7 +2199,7 @@ interface CodeProps {
|
|
|
2193
2199
|
/**
|
|
2194
2200
|
* Text color
|
|
2195
2201
|
*/
|
|
2196
|
-
color?:
|
|
2202
|
+
color?: ColorValue;
|
|
2197
2203
|
/**
|
|
2198
2204
|
* Background color
|
|
2199
2205
|
*/
|
|
@@ -2248,7 +2254,7 @@ interface LinkProps {
|
|
|
2248
2254
|
/**
|
|
2249
2255
|
* Text color
|
|
2250
2256
|
*/
|
|
2251
|
-
color?:
|
|
2257
|
+
color?: ColorValue;
|
|
2252
2258
|
/**
|
|
2253
2259
|
* Whether the link is disabled
|
|
2254
2260
|
*/
|
|
@@ -2278,7 +2284,7 @@ interface BlockquoteProps {
|
|
|
2278
2284
|
/**
|
|
2279
2285
|
* Text color
|
|
2280
2286
|
*/
|
|
2281
|
-
color?:
|
|
2287
|
+
color?: ColorValue;
|
|
2282
2288
|
/**
|
|
2283
2289
|
* Border color
|
|
2284
2290
|
*/
|
|
@@ -2459,6 +2465,27 @@ interface IconButtonProps {
|
|
|
2459
2465
|
}
|
|
2460
2466
|
declare const IconButton: React$1.ForwardRefExoticComponent<IconButtonProps & React$1.RefAttributes<react_native0.View | react_native0.Animated.LegacyRef<react_native0.View>>>;
|
|
2461
2467
|
//#endregion
|
|
2468
|
+
//#region src/utils/size.d.ts
|
|
2469
|
+
/**
|
|
2470
|
+
* Shared size prop normalization.
|
|
2471
|
+
*
|
|
2472
|
+
* The canonical size API is NUMERIC (`size={2}`). String sizes (`size="2"`,
|
|
2473
|
+
* the web Radix Themes convention) are still accepted for compatibility and
|
|
2474
|
+
* will be deprecated in a future release. Components should switch on the
|
|
2475
|
+
* normalized numeric value via `toNumericSize` at their resolution boundaries.
|
|
2476
|
+
*/
|
|
2477
|
+
/**
|
|
2478
|
+
* A size value expressed either as a number or its string literal form.
|
|
2479
|
+
* Example: `SizeInput<1 | 2 | 3>` = `1 | 2 | 3 | '1' | '2' | '3'`
|
|
2480
|
+
*/
|
|
2481
|
+
type SizeInput<N extends number> = N | `${N}`;
|
|
2482
|
+
/**
|
|
2483
|
+
* Normalize a SizeInput to its canonical numeric form.
|
|
2484
|
+
* Returns the value unchanged when already numeric, the parsed number for
|
|
2485
|
+
* legacy string inputs, or `undefined` when absent.
|
|
2486
|
+
*/
|
|
2487
|
+
declare const toNumericSize: <N extends number>(size?: SizeInput<N>) => N | undefined;
|
|
2488
|
+
//#endregion
|
|
2462
2489
|
//#region src/components/forms/TextField.d.ts
|
|
2463
2490
|
interface TextFieldProps extends TextInputProps$1 {
|
|
2464
2491
|
/**
|
|
@@ -2508,7 +2535,7 @@ interface TextFieldProps extends TextInputProps$1 {
|
|
|
2508
2535
|
* Size variant
|
|
2509
2536
|
* @default 2
|
|
2510
2537
|
*/
|
|
2511
|
-
size?:
|
|
2538
|
+
size?: SizeInput<1 | 2 | 3>;
|
|
2512
2539
|
/**
|
|
2513
2540
|
* Whether this is a multiline input
|
|
2514
2541
|
*/
|
|
@@ -2626,7 +2653,7 @@ interface TextAreaProps extends Omit<TextInputProps$1, 'multiline'> {
|
|
|
2626
2653
|
/**
|
|
2627
2654
|
* Size variant
|
|
2628
2655
|
*/
|
|
2629
|
-
size?:
|
|
2656
|
+
size?: SizeInput<1 | 2 | 3>;
|
|
2630
2657
|
/**
|
|
2631
2658
|
* Number of rows
|
|
2632
2659
|
*/
|
|
@@ -2720,7 +2747,7 @@ interface CheckboxProps {
|
|
|
2720
2747
|
* Size variant
|
|
2721
2748
|
* @default 2
|
|
2722
2749
|
*/
|
|
2723
|
-
size?:
|
|
2750
|
+
size?: SizeInput<1 | 2 | 3>;
|
|
2724
2751
|
/**
|
|
2725
2752
|
* Badge variant
|
|
2726
2753
|
* @default 'soft'
|
|
@@ -2775,7 +2802,7 @@ interface CheckboxItem {
|
|
|
2775
2802
|
/**
|
|
2776
2803
|
* Custom color for this item's checkbox
|
|
2777
2804
|
*/
|
|
2778
|
-
color?:
|
|
2805
|
+
color?: Color;
|
|
2779
2806
|
}
|
|
2780
2807
|
interface CheckboxGroupProps {
|
|
2781
2808
|
/**
|
|
@@ -2798,7 +2825,7 @@ interface CheckboxGroupProps {
|
|
|
2798
2825
|
* Size variant for checkboxes
|
|
2799
2826
|
* @default 2
|
|
2800
2827
|
*/
|
|
2801
|
-
size?:
|
|
2828
|
+
size?: SizeInput<1 | 2 | 3>;
|
|
2802
2829
|
/**
|
|
2803
2830
|
* Custom style
|
|
2804
2831
|
*/
|
|
@@ -2815,7 +2842,7 @@ interface CheckboxGroupProps {
|
|
|
2815
2842
|
/**
|
|
2816
2843
|
* Custom color for all checkboxes
|
|
2817
2844
|
*/
|
|
2818
|
-
color?:
|
|
2845
|
+
color?: Color;
|
|
2819
2846
|
}
|
|
2820
2847
|
type StyleProp$2<T> = T | T[];
|
|
2821
2848
|
declare const CheckboxGroup: React$1.ForwardRefExoticComponent<CheckboxGroupProps & React$1.RefAttributes<react_native0.View>>;
|
|
@@ -2825,7 +2852,7 @@ interface CheckboxCardsContextValue {
|
|
|
2825
2852
|
value: string[];
|
|
2826
2853
|
onValueChange: (value: string[]) => void;
|
|
2827
2854
|
variant: 'solid' | 'soft' | 'surface' | 'outline';
|
|
2828
|
-
size:
|
|
2855
|
+
size: SizeInput<1 | 2 | 3>;
|
|
2829
2856
|
color?: Color;
|
|
2830
2857
|
highContrast: boolean;
|
|
2831
2858
|
radius: RadiusSize;
|
|
@@ -2854,7 +2881,7 @@ interface CheckboxCardsRootProps {
|
|
|
2854
2881
|
* Size variant
|
|
2855
2882
|
* @default '2'
|
|
2856
2883
|
*/
|
|
2857
|
-
size?:
|
|
2884
|
+
size?: SizeInput<1 | 2 | 3>;
|
|
2858
2885
|
/**
|
|
2859
2886
|
* Custom color
|
|
2860
2887
|
*/
|
|
@@ -2959,7 +2986,7 @@ interface RadioProps {
|
|
|
2959
2986
|
* Size variant
|
|
2960
2987
|
* @default 2
|
|
2961
2988
|
*/
|
|
2962
|
-
size?:
|
|
2989
|
+
size?: SizeInput<1 | 2 | 3>;
|
|
2963
2990
|
/**
|
|
2964
2991
|
* Custom color for selected state
|
|
2965
2992
|
*/
|
|
@@ -3002,7 +3029,7 @@ interface RadioGroupContextValue {
|
|
|
3002
3029
|
value: string;
|
|
3003
3030
|
onValueChange: (value: string) => void;
|
|
3004
3031
|
disabled: boolean;
|
|
3005
|
-
size:
|
|
3032
|
+
size: SizeInput<1 | 2 | 3>;
|
|
3006
3033
|
color?: Color;
|
|
3007
3034
|
variant: 'solid' | 'soft' | 'surface' | 'outline';
|
|
3008
3035
|
highContrast: boolean;
|
|
@@ -3029,7 +3056,7 @@ interface RadioGroupRootProps {
|
|
|
3029
3056
|
* Size variant for radios
|
|
3030
3057
|
* @default '2'
|
|
3031
3058
|
*/
|
|
3032
|
-
size?:
|
|
3059
|
+
size?: SizeInput<1 | 2 | 3>;
|
|
3033
3060
|
/**
|
|
3034
3061
|
* Custom color for selected state
|
|
3035
3062
|
*/
|
|
@@ -3084,7 +3111,7 @@ interface RadioCardsContextValue {
|
|
|
3084
3111
|
value: string;
|
|
3085
3112
|
onValueChange: (value: string) => void;
|
|
3086
3113
|
variant: 'solid' | 'soft' | 'surface' | 'outline';
|
|
3087
|
-
size:
|
|
3114
|
+
size: SizeInput<1 | 2 | 3>;
|
|
3088
3115
|
color?: Color;
|
|
3089
3116
|
highContrast: boolean;
|
|
3090
3117
|
radius: RadiusSize;
|
|
@@ -3113,7 +3140,7 @@ interface RadioCardsRootProps {
|
|
|
3113
3140
|
* Size variant
|
|
3114
3141
|
* @default '2'
|
|
3115
3142
|
*/
|
|
3116
|
-
size?:
|
|
3143
|
+
size?: SizeInput<1 | 2 | 3>;
|
|
3117
3144
|
/**
|
|
3118
3145
|
* Custom color
|
|
3119
3146
|
*/
|
|
@@ -3219,7 +3246,7 @@ interface SwitchProps {
|
|
|
3219
3246
|
* Size variant
|
|
3220
3247
|
* @default '2'
|
|
3221
3248
|
*/
|
|
3222
|
-
size?:
|
|
3249
|
+
size?: SizeInput<1 | 2 | 3>;
|
|
3223
3250
|
/**
|
|
3224
3251
|
* Badge variant
|
|
3225
3252
|
* @default 'solid'
|
|
@@ -3560,7 +3587,7 @@ interface SliderProps {
|
|
|
3560
3587
|
* Size variant
|
|
3561
3588
|
* @default '2'
|
|
3562
3589
|
*/
|
|
3563
|
-
size?:
|
|
3590
|
+
size?: SizeInput<1 | 2 | 3 | 4>;
|
|
3564
3591
|
/**
|
|
3565
3592
|
* Visual style variant
|
|
3566
3593
|
* @default 'surface'
|
|
@@ -4076,7 +4103,7 @@ interface TooltipContentProps {
|
|
|
4076
4103
|
style?: StyleProp<ViewStyle>;
|
|
4077
4104
|
avoidCollisions?: boolean;
|
|
4078
4105
|
/** Radius variant for the tooltip. Inherits from theme by default. */
|
|
4079
|
-
radius?:
|
|
4106
|
+
radius?: RadiusSize;
|
|
4080
4107
|
}
|
|
4081
4108
|
interface TooltipArrowProps {
|
|
4082
4109
|
size?: number;
|
|
@@ -4094,7 +4121,7 @@ interface SimpleTooltipProps {
|
|
|
4094
4121
|
longPressDuration?: number;
|
|
4095
4122
|
avoidCollisions?: boolean;
|
|
4096
4123
|
/** Radius variant for the tooltip. Inherits from theme by default. */
|
|
4097
|
-
radius?:
|
|
4124
|
+
radius?: RadiusSize;
|
|
4098
4125
|
}
|
|
4099
4126
|
declare const TooltipExport: (({
|
|
4100
4127
|
children,
|
|
@@ -5328,7 +5355,7 @@ interface SkeletonProps {
|
|
|
5328
5355
|
declare const Skeleton: React$1.ForwardRefExoticComponent<SkeletonProps & React$1.RefAttributes<any>>;
|
|
5329
5356
|
//#endregion
|
|
5330
5357
|
//#region src/components/data-display/Table.d.ts
|
|
5331
|
-
type TableSize =
|
|
5358
|
+
type TableSize = SizeInput<1 | 2 | 3>;
|
|
5332
5359
|
interface TableRootProps {
|
|
5333
5360
|
/**
|
|
5334
5361
|
* Table content
|
|
@@ -5761,7 +5788,7 @@ declare const Slot: React$1.ForwardRefExoticComponent<Omit<SlotProps, "ref"> & R
|
|
|
5761
5788
|
//#endregion
|
|
5762
5789
|
//#region src/components/disclosure/Accordion.d.ts
|
|
5763
5790
|
type AccordionType = 'single' | 'multiple';
|
|
5764
|
-
type AccordionSize =
|
|
5791
|
+
type AccordionSize = SizeInput<1 | 2 | 3>;
|
|
5765
5792
|
type Direction = 'ltr' | 'rtl';
|
|
5766
5793
|
interface AccordionRootProps {
|
|
5767
5794
|
/**
|
|
@@ -5930,4 +5957,4 @@ interface ResponsiveInfo {
|
|
|
5930
5957
|
*/
|
|
5931
5958
|
declare const useResponsive: (breakpoints?: ResponsiveBreakpoints) => ResponsiveInfo;
|
|
5932
5959
|
//#endregion
|
|
5933
|
-
export { AbsoluteCenter, type AbsoluteCenterProps, Accordion, AccordionContent, type AccordionContentProps, AccordionHeader, type AccordionHeaderProps, AccordionItem, type AccordionItemProps, AccordionRoot, type AccordionRootProps, type AccordionSize, AccordionTrigger, type AccordionTriggerProps, type AccordionType, RnActivityIndicator as ActivityIndicator, type ActivityIndicatorProps, AlertDialogComponent as AlertDialog, type AlertDialogActionProps, type AlertDialogCancelProps, type AlertDialogContentProps, type AlertDialogDescriptionProps, type AlertDialogOverlayProps, type AlertDialogPortalProps, type AlertDialogProps, type AlertDialogRootProps, type AlertDialogTitleProps, type AlertDialogTriggerProps, AlphaColorScale, type AnchorPosition, AnimatedPressable, type AnimatedPressableProps, AspectRatio, type AspectRatioProps, Avatar, type AvatarFallbackProps, type AvatarProps, Badge, type BadgeProps, BaseColorScale, Blockquote, type BlockquoteProps, BottomSheet, type BottomSheetActionProps, type BottomSheetCloseProps, type BottomSheetContentProps, type BottomSheetDescriptionProps, type BottomSheetFooterProps, type BottomSheetHandleProps, type BottomSheetOverlayProps, type BottomSheetPortalProps, type BottomSheetRootProps, type BottomSheetTitleProps, type BottomSheetTriggerProps, Box, type BoxProps, Button, type ButtonCompoundComponent, ButtonIcon, type ButtonIconProps, ButtonLabel, type ButtonLabelProps, type ButtonProps, type CalculatedPosition, Callout, CalloutIcon, type CalloutIconProps, CalloutRoot, type CalloutRootProps, type CalloutSize, CalloutText, type CalloutTextProps, type CalloutVariant, Card, type CardFooterProps, type CardProps, Center, type CenterAxis, type CenterProps, Checkbox, CheckboxCards, type CheckboxCardsContextValue, CheckboxCardsItem, type CheckboxCardsItemProps, CheckboxCardsRoot, type CheckboxCardsRootProps, CheckboxGroup, type CheckboxGroupProps, type CheckboxItem, type CheckboxProps, Code, type CodeProps, Color, ColorScale, ColorTokens, Container, type ContainerProps, type ContentSize, ContextMenu, type ContextMenuAlign, type ContextMenuCheckboxItemProps, type ContextMenuContentProps, type ContextMenuGroupProps, type ContextMenuItemProps, type ContextMenuLabelProps, type ContextMenuOverlayProps, type ContextMenuPortalProps, type ContextMenuRadioItemProps, type ContextMenuRootProps, type ContextMenuSeparatorProps, type ContextMenuSide, type ContextMenuSize, type ContextMenuTriggerProps, DataList, DataListItem, type DataListItemAlign, type DataListItemProps, DataListLabel, type DataListLabelProps, type DataListOrientation, DataListRoot, type DataListRootProps, type DataListSize, type DataListTrim, DataListValue, type DataListValueProps, Dialog, type DialogActionProps, type DialogCloseProps, type DialogContentProps, type DialogDescriptionProps, type DialogOverlayProps, type DialogPortalProps, type DialogRootProps, type DialogTitleProps, type DialogTriggerProps, DropdownMenu, type DropdownMenuCheckboxItemProps, type DropdownMenuContentProps, type DropdownMenuGroupProps, type DropdownMenuItemProps, type DropdownMenuLabelProps, type DropdownMenuOverlayProps, type DropdownMenuPortalProps, type DropdownMenuRadioItemProps, type DropdownMenuRootProps, type DropdownMenuSeparatorProps, type DropdownMenuSubContentProps, type DropdownMenuSubProps, type DropdownMenuSubTriggerProps, type DropdownMenuTriggerProps, Em, type EmProps, type ExtendedColorScale, FancyList, type FancyListItem, type FancyListProps, RnFlatList as FlatList, type FlatListProps, Flex, type FlexProps, FontScale, FontSize, FontSizeSpec, FontToken, GrayScaleWithAlpha, Grid, type GridProps, HCenter, type HCenterProps, HStack, type HStackProps, Heading, type HeadingProps, IconButton, type IconButtonProps, RnImage as Image, type ImageProps, Inset, type InsetProps, Kbd, type KbdProps, Link, type LinkProps, ManagedPortal, type ManagedPortalProps, Popover, type PopoverAlign, type PopoverAlign as SelectAlign, type PopoverArrowProps, type PopoverCloseProps, type PopoverContentProps, type PopoverDescriptionProps, type PopoverOverlayProps, type PopoverPortalProps, type PopoverRootProps, type PopoverSide, type PopoverSide as SelectSide, type PopoverTitleProps, type PopoverTriggerProps, Portal, type PortalHostProps, type PortalProps, PortalProvider, RnPressable as Pressable, type PressableProps, RnText as PrimitiveText, type TextProps as PrimitiveTextProps, Progress, type ProgressProps, Radio, RadioCards, type RadioCardsContextValue, RadioCardsItem, type RadioCardsItemProps, RadioCardsRoot, type RadioCardsRootProps, RadioGroup, type RadioGroupContextValue, RadioGroupItem, type RadioGroupItemProps, RadioGroupRoot, type RadioGroupRootProps, type RadioProps, RadiusScale, type RadiusSize, type ScreenSize, ScrollArea, type ScrollAreaProps, RnScrollView as ScrollView, type ScrollViewProps, SegmentedControl, type SegmentedControlIconProps, type SegmentedControlItemProps, type SegmentedControlRootProps, type SegmentedControlValueProps, Select, SelectContent, type SelectContentProps, SelectGroup, type SelectGroupProps, SelectItem, type SelectItemProps, SelectLabel, type SelectLabelProps, SelectOverlay, type SelectOverlayProps, SelectPortal, type SelectPortalProps, SelectRoot, type SelectRootProps, SelectSeparator, type SelectSeparatorProps, type SelectSize, SelectTrigger, type SelectTriggerProps, SelectValue, type SelectValueProps, Separator, type SeparatorMarginSize, type SeparatorOrientation, type SeparatorProps, ShadowToken, ShadowTokens, type SidePosition, Sidebar, type SidebarBackdropProps, type SidebarContainerProps, type SidebarContentProps, type SidebarHeaderProps, type SidebarItemProps, type SidebarMainProps, type SidebarOverlayProps, type SidebarPortalProps, type SidebarRootProps, type SidebarSeparatorProps, type SidebarTriggerProps, type SidebarVariant, type SimpleTooltipProps, Skeleton, type SkeletonProps, Slider, type SliderProps, type SliderValue, Slot, type SlotProps, type SnapPoint, SpaceScale, Spacer, type SpacerDirection, type SpacerProps, type SpacerSize, Spinner, type SpinnerProps, Stack, type StackAlign, type StackDirection, type StackGap, type StackJustify, type StackProps, type StackWrap, Strong, type StrongProps, Switch, type SwitchProps, TabNav, type TabNavItemProps, type TabNavProps, Table, type TableBodyProps, type TableCellProps, type TableColumnHeaderCellProps, type TableHeaderProps, type TableRootProps, type TableRowProps, type TableSize, Tabs, type TabsContentProps, type TabsIconProps, type TabsListProps, type TabsRootProps, type TabsTriggerProps, TextComponent as Text, TextArea, type TextAreaProps, TextField, type TextFieldProps, type TextFieldSlotProps, RnTextInput as TextInput, type TextInputProps, type TextProps$1 as TextProps, Theme, ThemeAppearance, ThemeMode, ThemeProvider, ThemeTokens, Toast, type ToastActionProps, type ToastCloseProps, type ToastConfig, type ToastContextValue, type ToastController, type ToastData, type ToastDescriptionProps, type ToastOptions, type ToastPosition, type ToastRootProps, type ToastTitleProps, type ToastVariant, type ToastViewportProps, TooltipExport as Tooltip, type TooltipAlign, type TooltipArrowProps, type TooltipContentProps, type TooltipPortalProps, type TooltipRootProps, type TooltipSide, type TooltipTriggerProps, RnTouchableHighlight as TouchableHighlight, type TouchableHighlightProps, RnTouchableOpacity as TouchableOpacity, type TouchableOpacityProps, TypographyTokens, VCenter, type VCenterProps, VStack, type VStackProps, RnView as View, type ViewProps, VisuallyHidden, type VisuallyHiddenProps, addColorSchemeListener, amber, amberAlpha, black, blackAlpha, blue, blueAlpha, bronze, bronzeAlpha, brown, brownAlpha, calculatePopoverPosition, createTheme, crimson, crimsonAlpha, cyan, cyanAlpha, defaultTheme, fontFamilies, getAccentAlpha, getAccentAlphaScale, getAccentColor, getAccentContrast, getAccentScale, getAccentTextColor, getActiveColors, getColorAlpha, getColorScale, getColorScheme, getContrast, getDisabledColors, getExtendedAccentScale, getFocusColor, getForegroundColor, getGrayAlpha, getGrayScale, getHighContrastBackground, getHighContrastTextColor, getHoverColors, getRadii, getSelectionColor, getShadow, getShadows, getSpace, getThemeColors, getThemeShadow, getTypography, getVariantColors, gold, goldAlpha, grass, grassAlpha, gray, grayAlpha, green, greenAlpha, indigo, indigoAlpha, iris, irisAlpha, jade, jadeAlpha, lime, limeAlpha, mauve, mauveAlpha, mint, mintAlpha, needsDarkText, olive, oliveAlpha, orange, orangeAlpha, pink, pinkAlpha, plum, plumAlpha, purple, purpleAlpha, radii, radiusFactors, red, redAlpha, ruby, rubyAlpha, sage, sageAlpha, sand, sandAlpha, scalingOptions, shadows, sky, skyAlpha, slate, slateAlpha, space, teal, tealAlpha, tomato, tomatoAlpha, typography, useAnchorPosition, useDeviceColorScheme, useHaptics, usePortal, useResponsive, useTheme, useThemeActions, useThemeColors, useThemeContext, useThemeMode, useToast, useToastContext, violet, violetAlpha, white, whiteAlpha, yellow, yellowAlpha };
|
|
5960
|
+
export { AbsoluteCenter, type AbsoluteCenterProps, Accordion, AccordionContent, type AccordionContentProps, AccordionHeader, type AccordionHeaderProps, AccordionItem, type AccordionItemProps, AccordionRoot, type AccordionRootProps, type AccordionSize, AccordionTrigger, type AccordionTriggerProps, type AccordionType, RnActivityIndicator as ActivityIndicator, type ActivityIndicatorProps, AlertDialogComponent as AlertDialog, type AlertDialogActionProps, type AlertDialogCancelProps, type AlertDialogContentProps, type AlertDialogDescriptionProps, type AlertDialogOverlayProps, type AlertDialogPortalProps, type AlertDialogProps, type AlertDialogRootProps, type AlertDialogTitleProps, type AlertDialogTriggerProps, AlphaColorScale, type AnchorPosition, AnimatedPressable, type AnimatedPressableProps, AspectRatio, type AspectRatioProps, Avatar, type AvatarFallbackProps, type AvatarProps, Badge, type BadgeProps, BaseColorScale, Blockquote, type BlockquoteProps, BottomSheet, type BottomSheetActionProps, type BottomSheetCloseProps, type BottomSheetContentProps, type BottomSheetDescriptionProps, type BottomSheetFooterProps, type BottomSheetHandleProps, type BottomSheetOverlayProps, type BottomSheetPortalProps, type BottomSheetRootProps, type BottomSheetTitleProps, type BottomSheetTriggerProps, Box, type BoxProps, Button, type ButtonCompoundComponent, ButtonIcon, type ButtonIconProps, ButtonLabel, type ButtonLabelProps, type ButtonProps, type CalculatedPosition, Callout, CalloutIcon, type CalloutIconProps, CalloutRoot, type CalloutRootProps, type CalloutSize, CalloutText, type CalloutTextProps, type CalloutVariant, Card, type CardFooterProps, type CardProps, Center, type CenterAxis, type CenterProps, Checkbox, CheckboxCards, type CheckboxCardsContextValue, CheckboxCardsItem, type CheckboxCardsItemProps, CheckboxCardsRoot, type CheckboxCardsRootProps, CheckboxGroup, type CheckboxGroupProps, type CheckboxItem, type CheckboxProps, Code, type CodeProps, Color, ColorScale, ColorTokens, ColorValue, Container, type ContainerProps, type ContentSize, ContextMenu, type ContextMenuAlign, type ContextMenuCheckboxItemProps, type ContextMenuContentProps, type ContextMenuGroupProps, type ContextMenuItemProps, type ContextMenuLabelProps, type ContextMenuOverlayProps, type ContextMenuPortalProps, type ContextMenuRadioItemProps, type ContextMenuRootProps, type ContextMenuSeparatorProps, type ContextMenuSide, type ContextMenuSize, type ContextMenuTriggerProps, DataList, DataListItem, type DataListItemAlign, type DataListItemProps, DataListLabel, type DataListLabelProps, type DataListOrientation, DataListRoot, type DataListRootProps, type DataListSize, type DataListTrim, DataListValue, type DataListValueProps, Dialog, type DialogActionProps, type DialogCloseProps, type DialogContentProps, type DialogDescriptionProps, type DialogOverlayProps, type DialogPortalProps, type DialogRootProps, type DialogTitleProps, type DialogTriggerProps, DropdownMenu, type DropdownMenuCheckboxItemProps, type DropdownMenuContentProps, type DropdownMenuGroupProps, type DropdownMenuItemProps, type DropdownMenuLabelProps, type DropdownMenuOverlayProps, type DropdownMenuPortalProps, type DropdownMenuRadioItemProps, type DropdownMenuRootProps, type DropdownMenuSeparatorProps, type DropdownMenuSubContentProps, type DropdownMenuSubProps, type DropdownMenuSubTriggerProps, type DropdownMenuTriggerProps, Em, type EmProps, type ExtendedColorScale, FancyList, type FancyListItem, type FancyListProps, RnFlatList as FlatList, type FlatListProps, Flex, type FlexProps, FontScale, FontSize, FontSizeSpec, FontToken, GrayScaleWithAlpha, Grid, type GridProps, HCenter, type HCenterProps, HStack, type HStackProps, Heading, type HeadingProps, IconButton, type IconButtonProps, RnImage as Image, type ImageProps, Inset, type InsetProps, Kbd, type KbdProps, Link, type LinkProps, ManagedPortal, type ManagedPortalProps, Popover, type PopoverAlign, type PopoverAlign as SelectAlign, type PopoverArrowProps, type PopoverCloseProps, type PopoverContentProps, type PopoverDescriptionProps, type PopoverOverlayProps, type PopoverPortalProps, type PopoverRootProps, type PopoverSide, type PopoverSide as SelectSide, type PopoverTitleProps, type PopoverTriggerProps, Portal, type PortalHostProps, type PortalProps, PortalProvider, RnPressable as Pressable, type PressableProps, RnText as PrimitiveText, type TextProps as PrimitiveTextProps, Progress, type ProgressProps, Radio, RadioCards, type RadioCardsContextValue, RadioCardsItem, type RadioCardsItemProps, RadioCardsRoot, type RadioCardsRootProps, RadioGroup, type RadioGroupContextValue, RadioGroupItem, type RadioGroupItemProps, RadioGroupRoot, type RadioGroupRootProps, type RadioProps, RadiusScale, type RadiusSize, type ScreenSize, ScrollArea, type ScrollAreaProps, RnScrollView as ScrollView, type ScrollViewProps, SegmentedControl, type SegmentedControlIconProps, type SegmentedControlItemProps, type SegmentedControlRootProps, type SegmentedControlValueProps, Select, SelectContent, type SelectContentProps, SelectGroup, type SelectGroupProps, SelectItem, type SelectItemProps, SelectLabel, type SelectLabelProps, SelectOverlay, type SelectOverlayProps, SelectPortal, type SelectPortalProps, SelectRoot, type SelectRootProps, SelectSeparator, type SelectSeparatorProps, type SelectSize, SelectTrigger, type SelectTriggerProps, SelectValue, type SelectValueProps, Separator, type SeparatorMarginSize, type SeparatorOrientation, type SeparatorProps, ShadowToken, ShadowTokens, type SidePosition, Sidebar, type SidebarBackdropProps, type SidebarContainerProps, type SidebarContentProps, type SidebarHeaderProps, type SidebarItemProps, type SidebarMainProps, type SidebarOverlayProps, type SidebarPortalProps, type SidebarRootProps, type SidebarSeparatorProps, type SidebarTriggerProps, type SidebarVariant, type SimpleTooltipProps, SizeInput, Skeleton, type SkeletonProps, Slider, type SliderProps, type SliderValue, Slot, type SlotProps, type SnapPoint, SpaceScale, Spacer, type SpacerDirection, type SpacerProps, type SpacerSize, Spinner, type SpinnerProps, Stack, type StackAlign, type StackDirection, type StackGap, type StackJustify, type StackProps, type StackWrap, Strong, type StrongProps, Switch, type SwitchProps, TabNav, type TabNavItemProps, type TabNavProps, Table, type TableBodyProps, type TableCellProps, type TableColumnHeaderCellProps, type TableHeaderProps, type TableRootProps, type TableRowProps, type TableSize, Tabs, type TabsContentProps, type TabsIconProps, type TabsListProps, type TabsRootProps, type TabsTriggerProps, TextComponent as Text, TextArea, type TextAreaProps, TextField, type TextFieldProps, type TextFieldSlotProps, RnTextInput as TextInput, type TextInputProps, type TextProps$1 as TextProps, Theme, ThemeAppearance, ThemeMode, ThemeProvider, ThemeTokens, Toast, type ToastActionProps, type ToastCloseProps, type ToastConfig, type ToastContextValue, type ToastController, type ToastData, type ToastDescriptionProps, type ToastOptions, type ToastPosition, type ToastRootProps, type ToastTitleProps, type ToastVariant, type ToastViewportProps, TooltipExport as Tooltip, type TooltipAlign, type TooltipArrowProps, type TooltipContentProps, type TooltipPortalProps, type TooltipRootProps, type TooltipSide, type TooltipTriggerProps, RnTouchableHighlight as TouchableHighlight, type TouchableHighlightProps, RnTouchableOpacity as TouchableOpacity, type TouchableOpacityProps, TypographyTokens, VCenter, type VCenterProps, VStack, type VStackProps, RnView as View, type ViewProps, VisuallyHidden, type VisuallyHiddenProps, addColorSchemeListener, amber, amberAlpha, black, blackAlpha, blue, blueAlpha, bronze, bronzeAlpha, brown, brownAlpha, calculatePopoverPosition, createTheme, crimson, crimsonAlpha, cyan, cyanAlpha, defaultTheme, fontFamilies, getAccentAlpha, getAccentAlphaScale, getAccentColor, getAccentContrast, getAccentScale, getAccentTextColor, getActiveColors, getColorAlpha, getColorScale, getColorScheme, getContrast, getDisabledColors, getExtendedAccentScale, getFocusColor, getForegroundColor, getGrayAlpha, getGrayScale, getHighContrastBackground, getHighContrastTextColor, getHoverColors, getRadii, getSelectionColor, getShadow, getShadows, getSpace, getThemeColors, getThemeShadow, getTypography, getVariantColors, gold, goldAlpha, grass, grassAlpha, gray, grayAlpha, green, greenAlpha, indigo, indigoAlpha, iris, irisAlpha, jade, jadeAlpha, lime, limeAlpha, mauve, mauveAlpha, mint, mintAlpha, needsDarkText, olive, oliveAlpha, orange, orangeAlpha, pink, pinkAlpha, plum, plumAlpha, purple, purpleAlpha, radii, radiusFactors, red, redAlpha, ruby, rubyAlpha, sage, sageAlpha, sand, sandAlpha, scalingOptions, shadows, sky, skyAlpha, slate, slateAlpha, space, teal, tealAlpha, toNumericSize, tomato, tomatoAlpha, typography, useAnchorPosition, useDeviceColorScheme, useHaptics, usePortal, useResponsive, useTheme, useThemeActions, useThemeColors, useThemeContext, useThemeMode, useToast, useToastContext, violet, violetAlpha, white, whiteAlpha, yellow, yellowAlpha };
|
package/dist/index.mjs
CHANGED
|
@@ -4483,21 +4483,20 @@ Separator.displayName = "Separator";
|
|
|
4483
4483
|
* </Stack>
|
|
4484
4484
|
*/
|
|
4485
4485
|
const Stack = React.memo(({ children, direction = "vertical", gap, align, justify, wrap = "nowrap", asChild = false, style, width, height, flexGrow, flexShrink, padding, backgroundColor }) => {
|
|
4486
|
-
const theme = useTheme$1();
|
|
4487
4486
|
const stackStyle = useMemo(() => {
|
|
4488
4487
|
const baseStyle = {
|
|
4489
4488
|
display: "flex",
|
|
4490
4489
|
flexDirection: direction === "horizontal" ? "row" : "column",
|
|
4491
4490
|
flexWrap: wrap
|
|
4492
4491
|
};
|
|
4493
|
-
if (gap !== void 0) baseStyle.gap =
|
|
4492
|
+
if (gap !== void 0) baseStyle.gap = gap;
|
|
4494
4493
|
if (align !== void 0) baseStyle.alignItems = align;
|
|
4495
4494
|
if (justify !== void 0) baseStyle.justifyContent = justify;
|
|
4496
4495
|
if (width !== void 0) baseStyle.width = width;
|
|
4497
4496
|
if (height !== void 0) baseStyle.height = height;
|
|
4498
4497
|
if (flexGrow !== void 0) baseStyle.flexGrow = flexGrow;
|
|
4499
4498
|
if (flexShrink !== void 0) baseStyle.flexShrink = flexShrink;
|
|
4500
|
-
if (padding !== void 0) baseStyle.padding =
|
|
4499
|
+
if (padding !== void 0) baseStyle.padding = padding;
|
|
4501
4500
|
if (backgroundColor !== void 0) baseStyle.backgroundColor = backgroundColor;
|
|
4502
4501
|
return baseStyle;
|
|
4503
4502
|
}, [
|
|
@@ -4511,8 +4510,7 @@ const Stack = React.memo(({ children, direction = "vertical", gap, align, justif
|
|
|
4511
4510
|
flexGrow,
|
|
4512
4511
|
flexShrink,
|
|
4513
4512
|
padding,
|
|
4514
|
-
backgroundColor
|
|
4515
|
-
theme.space
|
|
4513
|
+
backgroundColor
|
|
4516
4514
|
]);
|
|
4517
4515
|
return /* @__PURE__ */ jsx(asChild ? Slot : RnView, {
|
|
4518
4516
|
style: [stackStyle, style],
|
|
@@ -5384,8 +5382,8 @@ const TextFieldRoot = React.forwardRef(({ children, ...props }, ref) => {
|
|
|
5384
5382
|
const variantColors = getVariantColors(theme, activeColor, mode, variant || "outline", highContrast || false);
|
|
5385
5383
|
const [isFocused, setIsFocused] = React.useState(false);
|
|
5386
5384
|
const getSizeValues = () => {
|
|
5387
|
-
switch (size) {
|
|
5388
|
-
case
|
|
5385
|
+
switch (Number(size)) {
|
|
5386
|
+
case 1: return {
|
|
5389
5387
|
fontSize: theme.typography.fontSizes[4].fontSize,
|
|
5390
5388
|
paddingVertical: theme.space[2],
|
|
5391
5389
|
paddingHorizontal: theme.space[3],
|
|
@@ -5393,7 +5391,7 @@ const TextFieldRoot = React.forwardRef(({ children, ...props }, ref) => {
|
|
|
5393
5391
|
height: multiline ? void 0 : 36,
|
|
5394
5392
|
slotPadding: theme.space[1]
|
|
5395
5393
|
};
|
|
5396
|
-
case
|
|
5394
|
+
case 3: return {
|
|
5397
5395
|
fontSize: theme.typography.fontSizes[6].fontSize,
|
|
5398
5396
|
paddingVertical: theme.space[4],
|
|
5399
5397
|
paddingHorizontal: theme.space[4],
|
|
@@ -5656,13 +5654,13 @@ const TextAreaRoot = React.forwardRef(({ children, ...props }, ref) => {
|
|
|
5656
5654
|
const variantColors = getVariantColors(theme, activeColor, mode, variant, highContrast);
|
|
5657
5655
|
const accentColorScale = getColorScale(theme, activeColor, mode);
|
|
5658
5656
|
const getSizeValues = () => {
|
|
5659
|
-
switch (size) {
|
|
5660
|
-
case
|
|
5657
|
+
switch (Number(size)) {
|
|
5658
|
+
case 1: return {
|
|
5661
5659
|
fontSize: theme.typography.fontSizes[4].fontSize,
|
|
5662
5660
|
padding: theme.space[2],
|
|
5663
5661
|
height: 100
|
|
5664
5662
|
};
|
|
5665
|
-
case
|
|
5663
|
+
case 3: return {
|
|
5666
5664
|
fontSize: theme.typography.fontSizes[6].fontSize,
|
|
5667
5665
|
padding: theme.space[4],
|
|
5668
5666
|
height: 140
|
|
@@ -5826,8 +5824,8 @@ const Checkbox = React.forwardRef(({ checked, defaultChecked = false, onCheckedC
|
|
|
5826
5824
|
getContrast(theme, activeColor, mode, highContrast);
|
|
5827
5825
|
const variantColors = getVariantColors(theme, activeColor, mode, variant, highContrast);
|
|
5828
5826
|
const getSizeValues = () => {
|
|
5829
|
-
switch (size) {
|
|
5830
|
-
case
|
|
5827
|
+
switch (Number(size)) {
|
|
5828
|
+
case 1: return {
|
|
5831
5829
|
boxSize: 20,
|
|
5832
5830
|
iconSize: 11,
|
|
5833
5831
|
fontSize: theme.typography.fontSizes[1].fontSize,
|
|
@@ -5835,7 +5833,7 @@ const Checkbox = React.forwardRef(({ checked, defaultChecked = false, onCheckedC
|
|
|
5835
5833
|
borderWidth: 1,
|
|
5836
5834
|
height: 2.5
|
|
5837
5835
|
};
|
|
5838
|
-
case
|
|
5836
|
+
case 3: return {
|
|
5839
5837
|
boxSize: 28,
|
|
5840
5838
|
iconSize: 16,
|
|
5841
5839
|
fontSize: theme.typography.fontSizes[3].fontSize,
|
|
@@ -6052,15 +6050,15 @@ const CheckboxCardsItem = React.forwardRef(({ value, side: itemSide, disabled: i
|
|
|
6052
6050
|
getAccentColor(theme, mode);
|
|
6053
6051
|
const variantColors = getVariantColors(theme, color || theme.accentColor, mode, variant, highContrast);
|
|
6054
6052
|
const getSizeValues = () => {
|
|
6055
|
-
switch (size) {
|
|
6056
|
-
case
|
|
6053
|
+
switch (Number(size)) {
|
|
6054
|
+
case 1: return {
|
|
6057
6055
|
padding: theme.space[3],
|
|
6058
6056
|
indicatorSize: 18,
|
|
6059
6057
|
innerIndicatorSize: 6,
|
|
6060
6058
|
borderWidth: 1,
|
|
6061
6059
|
checkHeight: 2.2
|
|
6062
6060
|
};
|
|
6063
|
-
case
|
|
6061
|
+
case 3: return {
|
|
6064
6062
|
padding: theme.space[5],
|
|
6065
6063
|
indicatorSize: 26,
|
|
6066
6064
|
innerIndicatorSize: 10,
|
|
@@ -6159,15 +6157,15 @@ const Radio = React.forwardRef(({ defaultChecked, value, selected, onSelect, dis
|
|
|
6159
6157
|
const [isInternallySelected, setIsInternallySelected] = React.useState(defaultChecked ?? false);
|
|
6160
6158
|
const isSelected = selected !== void 0 ? selected : isInternallySelected;
|
|
6161
6159
|
const getSizeValues = () => {
|
|
6162
|
-
switch (size) {
|
|
6163
|
-
case
|
|
6160
|
+
switch (Number(size)) {
|
|
6161
|
+
case 1: return {
|
|
6164
6162
|
boxSize: 18,
|
|
6165
6163
|
innerSize: 6,
|
|
6166
6164
|
iconSize: 8,
|
|
6167
6165
|
fontSize: theme.typography.fontSizes[1].fontSize,
|
|
6168
6166
|
gap: theme.space[1]
|
|
6169
6167
|
};
|
|
6170
|
-
case
|
|
6168
|
+
case 3: return {
|
|
6171
6169
|
boxSize: 28,
|
|
6172
6170
|
innerSize: 12,
|
|
6173
6171
|
iconSize: 16,
|
|
@@ -6390,14 +6388,14 @@ const RadioCardsItem = React.forwardRef(({ value, side: itemSide, disabled: item
|
|
|
6390
6388
|
getAccentColor(theme, mode);
|
|
6391
6389
|
const variantColors = getVariantColors(theme, color || theme.accentColor, mode, variant, highContrast);
|
|
6392
6390
|
const getSizeValues = () => {
|
|
6393
|
-
switch (size) {
|
|
6394
|
-
case
|
|
6391
|
+
switch (Number(size)) {
|
|
6392
|
+
case 1: return {
|
|
6395
6393
|
padding: theme.space[3],
|
|
6396
6394
|
indicatorSize: 18,
|
|
6397
6395
|
innerIndicatorSize: 8,
|
|
6398
6396
|
borderWidth: 1
|
|
6399
6397
|
};
|
|
6400
|
-
case
|
|
6398
|
+
case 3: return {
|
|
6401
6399
|
padding: theme.space[5],
|
|
6402
6400
|
indicatorSize: 26,
|
|
6403
6401
|
innerIndicatorSize: 12,
|
|
@@ -6525,15 +6523,15 @@ const Switch = React.forwardRef(({ defaultChecked, checked, onCheckedChange, dis
|
|
|
6525
6523
|
}).start();
|
|
6526
6524
|
}, [isChecked]);
|
|
6527
6525
|
const getSizeValues = () => {
|
|
6528
|
-
switch (size) {
|
|
6529
|
-
case
|
|
6526
|
+
switch (Number(size)) {
|
|
6527
|
+
case 1: return {
|
|
6530
6528
|
trackWidth: 32,
|
|
6531
6529
|
trackHeight: 20,
|
|
6532
6530
|
thumbSize: 14,
|
|
6533
6531
|
gap: theme.space[1],
|
|
6534
6532
|
fontSize: theme.typography.fontSizes[1].fontSize
|
|
6535
6533
|
};
|
|
6536
|
-
case
|
|
6534
|
+
case 3: return {
|
|
6537
6535
|
trackWidth: 58,
|
|
6538
6536
|
trackHeight: 32,
|
|
6539
6537
|
thumbSize: 26,
|
|
@@ -7576,18 +7574,18 @@ const Slider = React.forwardRef(({ value: controlledValue, defaultValue, onValue
|
|
|
7576
7574
|
};
|
|
7577
7575
|
const thumbAnimations = useRef(values.map((v) => new Animated.Value(getInitialPosition(v)))).current;
|
|
7578
7576
|
const sizeValues = useMemo(() => {
|
|
7579
|
-
switch (size) {
|
|
7580
|
-
case
|
|
7577
|
+
switch (Number(size)) {
|
|
7578
|
+
case 1: return {
|
|
7581
7579
|
trackHeight: 4,
|
|
7582
7580
|
thumbSize: 16,
|
|
7583
7581
|
fontSize: theme.typography.fontSizes[1].fontSize
|
|
7584
7582
|
};
|
|
7585
|
-
case
|
|
7583
|
+
case 3: return {
|
|
7586
7584
|
trackHeight: 8,
|
|
7587
7585
|
thumbSize: 28,
|
|
7588
7586
|
fontSize: theme.typography.fontSizes[3].fontSize
|
|
7589
7587
|
};
|
|
7590
|
-
case
|
|
7588
|
+
case 4: return {
|
|
7591
7589
|
trackHeight: 10,
|
|
7592
7590
|
thumbSize: 34,
|
|
7593
7591
|
fontSize: theme.typography.fontSizes[4].fontSize
|
|
@@ -12175,11 +12173,9 @@ const PULSE_ANIMATION = {
|
|
|
12175
12173
|
duration: 1e3,
|
|
12176
12174
|
useNativeDriver: true
|
|
12177
12175
|
};
|
|
12178
|
-
const SKELEON_COLORS = {
|
|
12179
|
-
light: "#E5E7EB",
|
|
12180
|
-
dark: "#D1D5DB"
|
|
12181
|
-
};
|
|
12182
12176
|
const Skeleton = React.forwardRef(({ children, loading = true, style, textStyle, width, height, accessibilityLabel = "Loading", testID }, ref) => {
|
|
12177
|
+
const theme = useTheme$1();
|
|
12178
|
+
const grayScale = useThemeMode$1() === "dark" ? theme.colors.gray.dark : theme.colors.gray;
|
|
12183
12179
|
const pulseAnim = useRef(new Animated.Value(0)).current;
|
|
12184
12180
|
useEffect(() => {
|
|
12185
12181
|
const animation = Animated.loop(Animated.sequence([Animated.timing(pulseAnim, {
|
|
@@ -12196,7 +12192,7 @@ const Skeleton = React.forwardRef(({ children, loading = true, style, textStyle,
|
|
|
12196
12192
|
}, [pulseAnim]);
|
|
12197
12193
|
const pulseStyle = { backgroundColor: pulseAnim.interpolate({
|
|
12198
12194
|
inputRange: [0, 1],
|
|
12199
|
-
outputRange: [
|
|
12195
|
+
outputRange: [grayScale[3], grayScale[5]]
|
|
12200
12196
|
}) };
|
|
12201
12197
|
if (!loading) return /* @__PURE__ */ jsx(Fragment, { children });
|
|
12202
12198
|
if (!React.isValidElement(children) && typeof children === "string") return /* @__PURE__ */ jsx(Animated.Text, {
|
|
@@ -12342,12 +12338,12 @@ const TableColumnHeaderCell = React.forwardRef(({ children, width, align = "left
|
|
|
12342
12338
|
const theme = useTheme$1();
|
|
12343
12339
|
const grayScale = useThemeMode$1() === "dark" ? theme.colors.gray.dark : theme.colors.gray;
|
|
12344
12340
|
const getSizePadding = () => {
|
|
12345
|
-
switch (context.size) {
|
|
12346
|
-
case
|
|
12341
|
+
switch (Number(context.size)) {
|
|
12342
|
+
case 1: return {
|
|
12347
12343
|
paddingVertical: theme.space[2],
|
|
12348
12344
|
paddingHorizontal: theme.space[3]
|
|
12349
12345
|
};
|
|
12350
|
-
case
|
|
12346
|
+
case 3: return {
|
|
12351
12347
|
paddingVertical: theme.space[4],
|
|
12352
12348
|
paddingHorizontal: theme.space[5]
|
|
12353
12349
|
};
|
|
@@ -12358,9 +12354,9 @@ const TableColumnHeaderCell = React.forwardRef(({ children, width, align = "left
|
|
|
12358
12354
|
}
|
|
12359
12355
|
};
|
|
12360
12356
|
const getSizeFont = () => {
|
|
12361
|
-
switch (context.size) {
|
|
12362
|
-
case
|
|
12363
|
-
case
|
|
12357
|
+
switch (Number(context.size)) {
|
|
12358
|
+
case 1: return { fontSize: theme.typography.fontSizes[1].fontSize };
|
|
12359
|
+
case 3: return { fontSize: theme.typography.fontSizes[3].fontSize };
|
|
12364
12360
|
default: return { fontSize: theme.typography.fontSizes[2].fontSize };
|
|
12365
12361
|
}
|
|
12366
12362
|
};
|
|
@@ -12397,12 +12393,12 @@ const TableCell = React.forwardRef(({ children, align = "left", style }, ref) =>
|
|
|
12397
12393
|
const theme = useTheme$1();
|
|
12398
12394
|
const grayScale = useThemeMode$1() === "dark" ? theme.colors.gray.dark : theme.colors.gray;
|
|
12399
12395
|
const getSizePadding = () => {
|
|
12400
|
-
switch (context.size) {
|
|
12401
|
-
case
|
|
12396
|
+
switch (Number(context.size)) {
|
|
12397
|
+
case 1: return {
|
|
12402
12398
|
paddingVertical: theme.space[2],
|
|
12403
12399
|
paddingHorizontal: theme.space[3]
|
|
12404
12400
|
};
|
|
12405
|
-
case
|
|
12401
|
+
case 3: return {
|
|
12406
12402
|
paddingVertical: theme.space[4],
|
|
12407
12403
|
paddingHorizontal: theme.space[5]
|
|
12408
12404
|
};
|
|
@@ -12413,9 +12409,9 @@ const TableCell = React.forwardRef(({ children, align = "left", style }, ref) =>
|
|
|
12413
12409
|
}
|
|
12414
12410
|
};
|
|
12415
12411
|
const getSizeFont = () => {
|
|
12416
|
-
switch (context.size) {
|
|
12417
|
-
case
|
|
12418
|
-
case
|
|
12412
|
+
switch (Number(context.size)) {
|
|
12413
|
+
case 1: return { fontSize: theme.typography.fontSizes[1].fontSize };
|
|
12414
|
+
case 3: return { fontSize: theme.typography.fontSizes[3].fontSize };
|
|
12419
12415
|
default: return { fontSize: theme.typography.fontSizes[2].fontSize };
|
|
12420
12416
|
}
|
|
12421
12417
|
};
|
|
@@ -13083,15 +13079,15 @@ const AccordionTrigger = React.forwardRef(({ children, style, icon, hapticFeedba
|
|
|
13083
13079
|
}).start();
|
|
13084
13080
|
}, [open, rotationAnim]);
|
|
13085
13081
|
const getSizeStyles = () => {
|
|
13086
|
-
switch (size) {
|
|
13087
|
-
case
|
|
13082
|
+
switch (Number(size)) {
|
|
13083
|
+
case 1: return {
|
|
13088
13084
|
paddingVertical: theme.space[2],
|
|
13089
13085
|
paddingHorizontal: theme.space[3],
|
|
13090
13086
|
fontSize: theme.typography.fontSizes[1].fontSize,
|
|
13091
13087
|
lineHeight: theme.typography.fontSizes[1].lineHeight,
|
|
13092
13088
|
iconSize: 14
|
|
13093
13089
|
};
|
|
13094
|
-
case
|
|
13090
|
+
case 3: return {
|
|
13095
13091
|
paddingVertical: theme.space[4],
|
|
13096
13092
|
paddingHorizontal: theme.space[5],
|
|
13097
13093
|
fontSize: theme.typography.fontSizes[4].fontSize,
|
|
@@ -13197,9 +13193,9 @@ const AccordionContent = React.forwardRef(({ children, style }, ref) => {
|
|
|
13197
13193
|
const heightAnim = useRef(new Animated.Value(0)).current;
|
|
13198
13194
|
const opacityAnim = useRef(new Animated.Value(0)).current;
|
|
13199
13195
|
const getContentPadding = () => {
|
|
13200
|
-
switch (size) {
|
|
13201
|
-
case
|
|
13202
|
-
case
|
|
13196
|
+
switch (Number(size)) {
|
|
13197
|
+
case 1: return theme.space[2];
|
|
13198
|
+
case 3: return theme.space[5];
|
|
13203
13199
|
default: return theme.space[4];
|
|
13204
13200
|
}
|
|
13205
13201
|
};
|
|
@@ -13326,4 +13322,13 @@ const useResponsive = (breakpoints = defaultBreakpoints) => {
|
|
|
13326
13322
|
};
|
|
13327
13323
|
|
|
13328
13324
|
//#endregion
|
|
13329
|
-
|
|
13325
|
+
//#region src/utils/size.ts
|
|
13326
|
+
/**
|
|
13327
|
+
* Normalize a SizeInput to its canonical numeric form.
|
|
13328
|
+
* Returns the value unchanged when already numeric, the parsed number for
|
|
13329
|
+
* legacy string inputs, or `undefined` when absent.
|
|
13330
|
+
*/
|
|
13331
|
+
const toNumericSize = (size) => size === void 0 ? void 0 : Number(size);
|
|
13332
|
+
|
|
13333
|
+
//#endregion
|
|
13334
|
+
export { AbsoluteCenter, Accordion, AccordionContent, AccordionHeader, AccordionItem, AccordionRoot, AccordionTrigger, RnActivityIndicator as ActivityIndicator, AlertDialogComponent as AlertDialog, AnimatedPressable, AspectRatio, Avatar, Badge, Blockquote, BottomSheet, Box, Button, ButtonIcon, ButtonLabel, Callout, CalloutIcon, CalloutRoot, CalloutText, Card, Center, Checkbox, CheckboxCards, CheckboxCardsItem, CheckboxCardsRoot, CheckboxGroup, Code, Container, ContextMenu, DataList, DataListItem, DataListLabel, DataListRoot, DataListValue, Dialog, DropdownMenu, Em, FancyList, RnFlatList as FlatList, Flex, Grid, HCenter, HStack, Heading, IconButton, RnImage as Image, Inset, Kbd, Link, ManagedPortal, Popover, Portal, PortalProvider, RnPressable as Pressable, RnText as PrimitiveText, Progress, Radio, RadioCards, RadioCardsItem, RadioCardsRoot, RadioGroup, RadioGroupItem, RadioGroupRoot, ScrollArea, RnScrollView as ScrollView, SegmentedControl, Select, SelectContent, SelectGroup, SelectItem, SelectLabel, SelectOverlay, SelectPortal, SelectRoot, SelectSeparator, SelectTrigger, SelectValue, Separator, Sidebar, Skeleton, Slider, Slot, Spacer, Spinner, Stack, Strong, Switch, TabNav, Table, Tabs, TextComponent as Text, TextArea, TextField, RnTextInput as TextInput, ThemeProvider, Toast, TooltipExport as Tooltip, RnTouchableHighlight as TouchableHighlight, RnTouchableOpacity as TouchableOpacity, VCenter, VStack, RnView as View, VisuallyHidden, addColorSchemeListener, amber, amberAlpha, black, blackAlpha, blue, blueAlpha, bronze, bronzeAlpha, brown, brownAlpha, calculatePopoverPosition, createTheme, crimson, crimsonAlpha, cyan, cyanAlpha, defaultTheme, fontFamilies, getAccentAlpha, getAccentAlphaScale, getAccentColor, getAccentContrast, getAccentScale, getAccentTextColor, getActiveColors, getColorAlpha, getColorScale, getColorScheme, getContrast, getDisabledColors, getExtendedAccentScale, getFocusColor, getForegroundColor, getGrayAlpha, getGrayScale, getHighContrastBackground, getHighContrastTextColor, getHoverColors, getRadii, getSelectionColor, getShadow, getShadows, getSpace, getThemeColors, getThemeShadow, getTypography, getVariantColors, gold, goldAlpha, grass, grassAlpha, gray, grayAlpha, green, greenAlpha, indigo, indigoAlpha, iris, irisAlpha, jade, jadeAlpha, lime, limeAlpha, mauve, mauveAlpha, mint, mintAlpha, needsDarkText, olive, oliveAlpha, orange, orangeAlpha, pink, pinkAlpha, plum, plumAlpha, purple, purpleAlpha, radii, radiusFactors, red, redAlpha, ruby, rubyAlpha, sage, sageAlpha, sand, sandAlpha, scalingOptions, shadows, sky, skyAlpha, slate, slateAlpha, space, teal, tealAlpha, toNumericSize, tomato, tomatoAlpha, typography, useAnchorPosition, useDeviceColorScheme, useHaptics, usePortal, useResponsive, useTheme, useThemeActions, useThemeColors, useThemeContext, useThemeMode, useToast, useToastContext, violet, violetAlpha, white, whiteAlpha, yellow, yellowAlpha };
|