@platform-blocks/ui 0.6.1 → 0.7.0
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 +0 -24
- package/lib/cjs/index.js +18 -15
- package/lib/cjs/index.js.map +1 -1
- package/lib/components/Accordion/types.d.ts +5 -5
- package/lib/components/AutoComplete/types.d.ts +3 -3
- package/lib/components/Avatar/types.d.ts +3 -3
- package/lib/components/Badge/types.d.ts +3 -3
- package/lib/components/Block/types.d.ts +2 -2
- package/lib/components/Blockquote/types.d.ts +2 -2
- package/lib/components/Breadcrumbs/types.d.ts +4 -4
- package/lib/components/Calendar/types.d.ts +2 -2
- package/lib/components/Carousel/types.d.ts +3 -3
- package/lib/components/Chip/types.d.ts +3 -3
- package/lib/components/CodeBlock/types.d.ts +4 -4
- package/lib/components/ColorPicker/types.d.ts +4 -4
- package/lib/components/CopyButton/types.d.ts +2 -2
- package/lib/components/DatePicker/types.d.ts +2 -2
- package/lib/components/Divider/types.d.ts +2 -2
- package/lib/components/Grid/types.d.ts +3 -3
- package/lib/components/HoverCard/types.d.ts +2 -2
- package/lib/components/Image/types.d.ts +3 -3
- package/lib/components/Indicator/types.d.ts +2 -2
- package/lib/components/Knob/components/SurfaceLayers.d.ts +2 -2
- package/lib/components/Knob/components/ThumbLayer.d.ts +1 -1
- package/lib/components/Knob/components/TickLayers.d.ts +2 -2
- package/lib/components/Knob/types.d.ts +11 -11
- package/lib/components/ListGroup/types.d.ts +4 -4
- package/lib/components/Loader/types.d.ts +2 -2
- package/lib/components/Masonry/types.d.ts +4 -4
- package/lib/components/Navigation/types.d.ts +2 -2
- package/lib/components/Notice/types.d.ts +2 -2
- package/lib/components/Pagination/types.d.ts +6 -6
- package/lib/components/Progress/types.d.ts +3 -3
- package/lib/components/QRCode/types.d.ts +2 -2
- package/lib/components/Rating/types.d.ts +2 -2
- package/lib/components/Ring/types.d.ts +7 -7
- package/lib/components/SegmentedControl/types.d.ts +4 -4
- package/lib/components/Skeleton/types.d.ts +2 -2
- package/lib/components/Slider/types.d.ts +7 -7
- package/lib/components/Spotlight/types.d.ts +6 -6
- package/lib/components/Tabs/types.d.ts +5 -5
- package/lib/components/Toast/types.d.ts +2 -2
- package/lib/components/Tooltip/types.d.ts +2 -2
- package/lib/components/Video/NativeVideoPlayer.d.ts +2 -2
- package/lib/components/Video/VideoControls.d.ts +2 -2
- package/lib/components/Video/YouTubePlayer.d.ts +2 -2
- package/lib/components/Video/types.d.ts +4 -4
- package/lib/esm/index.js +18 -15
- package/lib/esm/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ReactNode } from 'react';
|
|
2
|
-
import type { ViewStyle, TextStyle } from 'react-native';
|
|
2
|
+
import type { ViewStyle, TextStyle, StyleProp } from 'react-native';
|
|
3
3
|
import type { SizeValue } from '../../core/theme/sizes';
|
|
4
4
|
import type { BorderRadiusProps } from '../../core/theme/radius';
|
|
5
5
|
import type { PlatformBlocksTheme } from '../../core/theme/types';
|
|
@@ -100,19 +100,19 @@ export interface AccordionProps extends SpacingProps, BorderRadiusProps {
|
|
|
100
100
|
/**
|
|
101
101
|
* Root container style override.
|
|
102
102
|
*/
|
|
103
|
-
style?: ViewStyle
|
|
103
|
+
style?: StyleProp<ViewStyle>;
|
|
104
104
|
/**
|
|
105
105
|
* Header row style override applied to each item.
|
|
106
106
|
*/
|
|
107
|
-
headerStyle?: ViewStyle
|
|
107
|
+
headerStyle?: StyleProp<ViewStyle>;
|
|
108
108
|
/**
|
|
109
109
|
* Collapsible content container style override.
|
|
110
110
|
*/
|
|
111
|
-
contentStyle?: ViewStyle
|
|
111
|
+
contentStyle?: StyleProp<ViewStyle>;
|
|
112
112
|
/**
|
|
113
113
|
* Text style applied to the header label.
|
|
114
114
|
*/
|
|
115
|
-
headerTextStyle?: TextStyle
|
|
115
|
+
headerTextStyle?: StyleProp<TextStyle>;
|
|
116
116
|
/**
|
|
117
117
|
* Explicit persistence key. If omitted, an automatic hash key will be generated when uncontrolled.
|
|
118
118
|
*/
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { TextInputProps, ViewStyle } from 'react-native';
|
|
2
|
+
import { TextInputProps, ViewStyle, StyleProp } from 'react-native';
|
|
3
3
|
import { SpacingProps, LayoutProps } from '../../core/utils';
|
|
4
4
|
import type { SizeValue } from '../../core/theme/types';
|
|
5
5
|
import type { RadiusValue } from '../../core/theme/radius';
|
|
@@ -41,7 +41,7 @@ export interface AutoCompleteProps extends SpacingProps, LayoutProps {
|
|
|
41
41
|
/** Callback when the clear button is pressed */
|
|
42
42
|
onClear?: () => void;
|
|
43
43
|
/** Custom style */
|
|
44
|
-
style?: ViewStyle
|
|
44
|
+
style?: StyleProp<ViewStyle>;
|
|
45
45
|
/** Data source for suggestions */
|
|
46
46
|
data?: AutoCompleteOption[];
|
|
47
47
|
/** Async data fetcher */
|
|
@@ -90,7 +90,7 @@ export interface AutoCompleteProps extends SpacingProps, LayoutProps {
|
|
|
90
90
|
source: 'input' | 'modal';
|
|
91
91
|
}) => React.ReactNode;
|
|
92
92
|
/** Optional style override for the selected values container */
|
|
93
|
-
selectedValuesContainerStyle?: ViewStyle
|
|
93
|
+
selectedValuesContainerStyle?: StyleProp<ViewStyle>;
|
|
94
94
|
/** Additional props applied to the default Chip renderer for selected values */
|
|
95
95
|
selectedValueChipProps?: Partial<ChipProps>;
|
|
96
96
|
/** Controls whether the input regains focus after selecting an option */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ViewStyle } from 'react-native';
|
|
2
|
+
import { ViewStyle, StyleProp } from 'react-native';
|
|
3
3
|
import type { ComponentSizeValue } from '../../core/theme/componentSize';
|
|
4
4
|
export interface AvatarProps {
|
|
5
5
|
/** Size of the avatar */
|
|
@@ -17,7 +17,7 @@ export interface AvatarProps {
|
|
|
17
17
|
/** Color override for the status indicator */
|
|
18
18
|
indicatorColor?: string;
|
|
19
19
|
/** Style override for the avatar container */
|
|
20
|
-
style?: ViewStyle
|
|
20
|
+
style?: StyleProp<ViewStyle>;
|
|
21
21
|
/** Accessibility label for the avatar image */
|
|
22
22
|
accessibilityLabel?: string;
|
|
23
23
|
/** Primary label displayed to the right of the avatar (string or custom React node) */
|
|
@@ -33,7 +33,7 @@ export interface AvatarGroupProps {
|
|
|
33
33
|
children: React.ReactNode;
|
|
34
34
|
limit?: number;
|
|
35
35
|
spacing?: number;
|
|
36
|
-
style?: ViewStyle
|
|
36
|
+
style?: StyleProp<ViewStyle>;
|
|
37
37
|
size?: ComponentSizeValue;
|
|
38
38
|
/** Whether to add borders around avatars for separation */
|
|
39
39
|
bordered?: boolean;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ViewStyle, TextStyle } from 'react-native';
|
|
2
|
+
import { ViewStyle, TextStyle, StyleProp } from 'react-native';
|
|
3
3
|
import { type ComponentSizeValue } from '../../core/theme/componentSize';
|
|
4
4
|
import { SpacingProps } from '../../core/utils';
|
|
5
5
|
import { BorderRadiusProps } from '../../core/theme/radius';
|
|
@@ -19,8 +19,8 @@ export interface BadgeProps extends SpacingProps, BorderRadiusProps, ShadowProps
|
|
|
19
19
|
onRemove?: () => void;
|
|
20
20
|
removePosition?: 'left' | 'right';
|
|
21
21
|
disabled?: boolean;
|
|
22
|
-
style?: ViewStyle
|
|
23
|
-
textStyle?: TextStyle
|
|
22
|
+
style?: StyleProp<ViewStyle>;
|
|
23
|
+
textStyle?: StyleProp<TextStyle>;
|
|
24
24
|
radius?: any;
|
|
25
25
|
shadow?: any;
|
|
26
26
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ViewStyle } from 'react-native';
|
|
2
|
+
import { ViewStyle, StyleProp } from 'react-native';
|
|
3
3
|
import type { SpacingProps } from '../../core/utils/spacing';
|
|
4
4
|
import type { PolymorphicFactory } from '../../core/factory';
|
|
5
5
|
/**
|
|
@@ -79,7 +79,7 @@ export interface BlockProps extends SpacingProps, BlockStyleProps {
|
|
|
79
79
|
/** The component to render as */
|
|
80
80
|
component?: React.ElementType;
|
|
81
81
|
/** Custom style object */
|
|
82
|
-
style?: ViewStyle
|
|
82
|
+
style?: StyleProp<ViewStyle>;
|
|
83
83
|
/** Test ID for testing purposes */
|
|
84
84
|
testID?: string;
|
|
85
85
|
/** Accessibility label */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ViewStyle } from 'react-native';
|
|
1
|
+
import type { ViewStyle, StyleProp } from 'react-native';
|
|
2
2
|
import type { SizeValue } from '../../core/theme/types';
|
|
3
3
|
import type { BrandName } from '../BrandIcon/brands';
|
|
4
4
|
export interface BlockquoteAuthor {
|
|
@@ -44,7 +44,7 @@ export interface BlockquoteProps {
|
|
|
44
44
|
alignment?: 'left' | 'center' | 'right';
|
|
45
45
|
border?: boolean;
|
|
46
46
|
shadow?: boolean;
|
|
47
|
-
style?: ViewStyle
|
|
47
|
+
style?: StyleProp<ViewStyle>;
|
|
48
48
|
onPress?: () => void;
|
|
49
49
|
}
|
|
50
50
|
export interface BlockquoteAttributionProps {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { ViewStyle, TextStyle } from 'react-native';
|
|
2
|
+
import { ViewStyle, TextStyle, StyleProp } from 'react-native';
|
|
3
3
|
import { SpacingProps } from '../../core/theme/types';
|
|
4
4
|
import { type ComponentSizeValue } from '../../core/theme/componentSize';
|
|
5
5
|
export interface BreadcrumbItem {
|
|
@@ -26,11 +26,11 @@ export interface BreadcrumbsProps extends SpacingProps {
|
|
|
26
26
|
/** Whether to show icons */
|
|
27
27
|
showIcons?: boolean;
|
|
28
28
|
/** Custom styles */
|
|
29
|
-
style?: ViewStyle
|
|
29
|
+
style?: StyleProp<ViewStyle>;
|
|
30
30
|
/** Custom text styles */
|
|
31
|
-
textStyle?: TextStyle
|
|
31
|
+
textStyle?: StyleProp<TextStyle>;
|
|
32
32
|
/** Custom separator styles */
|
|
33
|
-
separatorStyle?: ViewStyle
|
|
33
|
+
separatorStyle?: StyleProp<ViewStyle>;
|
|
34
34
|
/** Accessibility label */
|
|
35
35
|
accessibilityLabel?: string;
|
|
36
36
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ViewStyle } from 'react-native';
|
|
2
|
+
import { ViewStyle, StyleProp } from 'react-native';
|
|
3
3
|
import { SizeValue } from '../../core/theme/types';
|
|
4
4
|
import type { DisclaimerSupport } from '../_internal/Disclaimer';
|
|
5
5
|
export type CalendarLevel = 'month' | 'year' | 'decade';
|
|
@@ -88,7 +88,7 @@ export interface DayProps {
|
|
|
88
88
|
onMouseEnter?: () => void;
|
|
89
89
|
onMouseLeave?: () => void;
|
|
90
90
|
size?: SizeValue;
|
|
91
|
-
style?: ViewStyle
|
|
91
|
+
style?: StyleProp<ViewStyle>;
|
|
92
92
|
children?: React.ReactNode;
|
|
93
93
|
[key: string]: any;
|
|
94
94
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ViewStyle } from 'react-native';
|
|
2
|
+
import { ViewStyle, StyleProp } from 'react-native';
|
|
3
3
|
import { SpacingProps } from '../../core/utils';
|
|
4
4
|
import type { ResponsiveSize } from '../AppShell/types';
|
|
5
5
|
import type { ComponentSizeValue } from '../../core/theme/componentSize';
|
|
@@ -64,9 +64,9 @@ export interface CarouselProps extends SpacingProps {
|
|
|
64
64
|
/** Callback fired when the active slide changes */
|
|
65
65
|
onSlideChange?: (index: number) => void;
|
|
66
66
|
/** Style override for the carousel container */
|
|
67
|
-
style?: ViewStyle
|
|
67
|
+
style?: StyleProp<ViewStyle>;
|
|
68
68
|
/** Style override applied to each slide item */
|
|
69
|
-
itemStyle?: ViewStyle
|
|
69
|
+
itemStyle?: StyleProp<ViewStyle>;
|
|
70
70
|
/** Enable snapping to individual items */
|
|
71
71
|
snapToItem?: boolean;
|
|
72
72
|
/** Position of navigation arrows relative to the carousel */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ViewStyle, TextStyle } from 'react-native';
|
|
2
|
+
import { ViewStyle, TextStyle, StyleProp } from 'react-native';
|
|
3
3
|
import { SizeValue } from '../../core/theme/sizes';
|
|
4
4
|
import { SpacingProps } from '../../core/utils';
|
|
5
5
|
import { BorderRadiusProps } from '../../core/theme/radius';
|
|
@@ -15,8 +15,8 @@ export interface ChipProps extends SpacingProps, BorderRadiusProps, ShadowProps
|
|
|
15
15
|
onRemove?: () => void;
|
|
16
16
|
removePosition?: 'left' | 'right';
|
|
17
17
|
disabled?: boolean;
|
|
18
|
-
style?: ViewStyle
|
|
19
|
-
textStyle?: TextStyle
|
|
18
|
+
style?: StyleProp<ViewStyle>;
|
|
19
|
+
textStyle?: StyleProp<TextStyle>;
|
|
20
20
|
radius?: any;
|
|
21
21
|
shadow?: any;
|
|
22
22
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ViewStyle, TextStyle } from 'react-native';
|
|
2
|
+
import { ViewStyle, TextStyle, StyleProp } from 'react-native';
|
|
3
3
|
import { SpacingProps } from '../../core/utils';
|
|
4
4
|
export type CodeBlockToken = 'keyword' | 'string' | 'comment' | 'number' | 'function' | 'operator' | 'punctuation' | 'tag' | 'attribute' | 'className';
|
|
5
5
|
export type CodeBlockTextPalette = string | string[] | Partial<Record<CodeBlockToken, string>>;
|
|
@@ -37,11 +37,11 @@ export interface CodeBlockProps extends SpacingProps {
|
|
|
37
37
|
/** Callback when code is copied */
|
|
38
38
|
onCopy?: (code: string) => void;
|
|
39
39
|
/** Custom styles for the code block container and text */
|
|
40
|
-
style?: ViewStyle
|
|
40
|
+
style?: StyleProp<ViewStyle>;
|
|
41
41
|
/** Custom styles for the code text */
|
|
42
|
-
textStyle?: TextStyle
|
|
42
|
+
textStyle?: StyleProp<TextStyle>;
|
|
43
43
|
/** Custom styles for the title text */
|
|
44
|
-
titleStyle?: TextStyle
|
|
44
|
+
titleStyle?: StyleProp<TextStyle>;
|
|
45
45
|
/** Lines to highlight, e.g. ["1", "3-5"] */
|
|
46
46
|
highlightLines?: string[];
|
|
47
47
|
/** Show a spoiler for the code block */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ViewStyle, TextStyle } from 'react-native';
|
|
1
|
+
import { ViewStyle, TextStyle, StyleProp } from 'react-native';
|
|
2
2
|
import { SpacingProps } from '../../core/theme/types';
|
|
3
3
|
import { LayoutProps } from '../../core/utils';
|
|
4
4
|
import { BorderRadiusProps } from '../../core/theme/radius';
|
|
@@ -58,11 +58,11 @@ export interface ColorPickerProps extends SpacingProps, LayoutProps, BorderRadiu
|
|
|
58
58
|
/** Whether dropdown should avoid the on-screen keyboard when visible */
|
|
59
59
|
keyboardAvoidance?: boolean;
|
|
60
60
|
/** Custom style for the container */
|
|
61
|
-
style?: ViewStyle
|
|
61
|
+
style?: StyleProp<ViewStyle>;
|
|
62
62
|
/** Custom style for the preview */
|
|
63
|
-
previewStyle?: ViewStyle
|
|
63
|
+
previewStyle?: StyleProp<ViewStyle>;
|
|
64
64
|
/** Custom style for the input */
|
|
65
|
-
inputStyle?: TextStyle
|
|
65
|
+
inputStyle?: StyleProp<TextStyle>;
|
|
66
66
|
/** Whether the picker should display a clear button */
|
|
67
67
|
clearable?: boolean;
|
|
68
68
|
/** Accessible label for the clear button */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ViewStyle } from 'react-native';
|
|
1
|
+
import { ViewStyle, StyleProp } from 'react-native';
|
|
2
2
|
import type { ComponentSizeValue } from '../../core/theme/componentSize';
|
|
3
3
|
export interface CopyButtonProps {
|
|
4
4
|
/** The text to copy to clipboard */
|
|
@@ -16,7 +16,7 @@ export interface CopyButtonProps {
|
|
|
16
16
|
/** Visual size token */
|
|
17
17
|
size?: ComponentSizeValue;
|
|
18
18
|
/** Style overrides for the button container */
|
|
19
|
-
style?: ViewStyle
|
|
19
|
+
style?: StyleProp<ViewStyle>;
|
|
20
20
|
/** Disable the "copied to clipboard" toast */
|
|
21
21
|
disableToast?: boolean;
|
|
22
22
|
/** Tooltip text */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ViewStyle } from 'react-native';
|
|
1
|
+
import { ViewStyle, StyleProp } from 'react-native';
|
|
2
2
|
import { BaseInputProps } from '../Input/types';
|
|
3
3
|
import { SizeValue } from '../../core/theme/types';
|
|
4
4
|
import type { CalendarProps as CoreCalendarProps, CalendarType, CalendarValue, CalendarLevel } from '../Calendar/types';
|
|
@@ -14,7 +14,7 @@ export interface DatePickerProps {
|
|
|
14
14
|
/** Pass-through customization for underlying Calendar */
|
|
15
15
|
calendarProps?: Partial<CoreCalendarProps>;
|
|
16
16
|
/** Optional container style for the inline calendar */
|
|
17
|
-
style?: ViewStyle
|
|
17
|
+
style?: StyleProp<ViewStyle>;
|
|
18
18
|
/** Test identifier */
|
|
19
19
|
testID?: string;
|
|
20
20
|
/** Accessibility label for the inline calendar region */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ViewStyle, View } from 'react-native';
|
|
2
|
+
import { ViewStyle, View, StyleProp } from 'react-native';
|
|
3
3
|
import { SpacingProps } from '../../core/utils';
|
|
4
4
|
import { SizeValue } from '../../core/theme/sizes';
|
|
5
5
|
export type DividerOrientation = 'horizontal' | 'vertical';
|
|
@@ -13,7 +13,7 @@ export interface DividerProps extends SpacingProps {
|
|
|
13
13
|
size?: SizeValue | number;
|
|
14
14
|
label?: React.ReactNode;
|
|
15
15
|
labelPosition?: 'left' | 'center' | 'right';
|
|
16
|
-
style?: ViewStyle
|
|
16
|
+
style?: StyleProp<ViewStyle>;
|
|
17
17
|
testID?: string;
|
|
18
18
|
}
|
|
19
19
|
export interface DividerFactoryPayload {
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ViewStyle } from 'react-native';
|
|
1
|
+
import type { ViewStyle, StyleProp } from 'react-native';
|
|
2
2
|
import type { SpacingProps } from '../../core/utils/spacing';
|
|
3
3
|
import type { SizeValue } from '../../core/theme/sizes';
|
|
4
4
|
import type { ResponsiveProp } from '../../core/theme/breakpoints';
|
|
@@ -16,7 +16,7 @@ export interface GridProps extends SpacingProps {
|
|
|
16
16
|
/** Children elements */
|
|
17
17
|
children?: React.ReactNode;
|
|
18
18
|
/** Custom styles */
|
|
19
|
-
style?: ViewStyle
|
|
19
|
+
style?: StyleProp<ViewStyle>;
|
|
20
20
|
/** Test ID for testing */
|
|
21
21
|
testID?: string;
|
|
22
22
|
}
|
|
@@ -26,7 +26,7 @@ export interface GridItemProps extends SpacingProps {
|
|
|
26
26
|
/** Children elements */
|
|
27
27
|
children?: React.ReactNode;
|
|
28
28
|
/** Custom styles */
|
|
29
|
-
style?: ViewStyle
|
|
29
|
+
style?: StyleProp<ViewStyle>;
|
|
30
30
|
/** Test ID for testing */
|
|
31
31
|
testID?: string;
|
|
32
32
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ViewStyle, View } from 'react-native';
|
|
2
|
+
import { ViewStyle, View, StyleProp } from 'react-native';
|
|
3
3
|
import { SizeValue } from '../../core/theme/sizes';
|
|
4
4
|
export type HoverCardPosition = 'top' | 'bottom' | 'left' | 'right' | 'auto';
|
|
5
5
|
export type HoverCardShadow = 'none' | 'sm' | 'md' | 'lg';
|
|
@@ -37,7 +37,7 @@ export interface HoverCardProps {
|
|
|
37
37
|
/** Disable interactions */
|
|
38
38
|
disabled?: boolean;
|
|
39
39
|
/** Style override */
|
|
40
|
-
style?: ViewStyle
|
|
40
|
+
style?: StyleProp<ViewStyle>;
|
|
41
41
|
/** Test id */
|
|
42
42
|
testID?: string;
|
|
43
43
|
/** z-index layering */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ViewStyle, ImageStyle } from 'react-native';
|
|
2
|
+
import { ViewStyle, ImageStyle, StyleProp } from 'react-native';
|
|
3
3
|
import { SizeValue, ColorValue, SpacingProps } from '../../core/theme/types';
|
|
4
4
|
import { LayoutProps } from '../../core/utils';
|
|
5
5
|
import { BorderRadiusProps } from '../../core/theme/radius';
|
|
@@ -51,7 +51,7 @@ export interface ImageProps extends BaseComponentProps, Omit<LayoutProps, 'w' |
|
|
|
51
51
|
/** Called when image finishes loading (success or error) */
|
|
52
52
|
onLoadEnd?: () => void;
|
|
53
53
|
/** Container style */
|
|
54
|
-
containerStyle?: ViewStyle
|
|
54
|
+
containerStyle?: StyleProp<ViewStyle>;
|
|
55
55
|
/** Image style overrides */
|
|
56
|
-
imageStyle?: ImageStyle
|
|
56
|
+
imageStyle?: StyleProp<ImageStyle>;
|
|
57
57
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ViewStyle } from 'react-native';
|
|
1
|
+
import type { ViewStyle, StyleProp } from 'react-native';
|
|
2
2
|
import type { SizeValue } from '../../core/theme/types';
|
|
3
3
|
export interface IndicatorProps {
|
|
4
4
|
size?: SizeValue | number;
|
|
@@ -7,7 +7,7 @@ export interface IndicatorProps {
|
|
|
7
7
|
borderWidth?: number;
|
|
8
8
|
placement?: 'top-left' | 'top-right' | 'bottom-left' | 'bottom-right';
|
|
9
9
|
offset?: number;
|
|
10
|
-
style?: ViewStyle
|
|
10
|
+
style?: StyleProp<ViewStyle>;
|
|
11
11
|
children?: React.ReactNode;
|
|
12
12
|
invisible?: boolean;
|
|
13
13
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { ViewStyle } from 'react-native';
|
|
2
|
+
import { ViewStyle, StyleProp } from 'react-native';
|
|
3
3
|
import type { KnobFillStyle } from '../types';
|
|
4
4
|
import type { LayoutState } from '../hooks/useKnobGeometry';
|
|
5
5
|
export type SurfaceLayersProps = {
|
|
@@ -15,7 +15,7 @@ export type SurfaceLayersProps = {
|
|
|
15
15
|
ringThickness: number;
|
|
16
16
|
ringCap: 'butt' | 'round';
|
|
17
17
|
ringShadowStyle: ViewStyle | null;
|
|
18
|
-
trackStyle?: ViewStyle
|
|
18
|
+
trackStyle?: StyleProp<ViewStyle>;
|
|
19
19
|
showContiguousProgress: boolean;
|
|
20
20
|
progressPath: string;
|
|
21
21
|
progressStrokeColor: string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import type { TextStyle } from 'react-native';
|
|
2
|
+
import type { StyleProp, TextStyle } from 'react-native';
|
|
3
3
|
import type { KnobAppearance, KnobMark } from '../types';
|
|
4
4
|
import type { LayoutState } from '../hooks/useKnobGeometry';
|
|
5
5
|
export type TickLayersProps = {
|
|
@@ -21,7 +21,7 @@ export type TickLayersProps = {
|
|
|
21
21
|
displayValue: number;
|
|
22
22
|
activeMark?: KnobMark | null;
|
|
23
23
|
disabled: boolean;
|
|
24
|
-
markLabelStyle?: TextStyle
|
|
24
|
+
markLabelStyle?: StyleProp<TextStyle>;
|
|
25
25
|
labelColor: string;
|
|
26
26
|
};
|
|
27
27
|
export declare const TickLayers: React.FC<TickLayersProps>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { FC, ReactNode } from 'react';
|
|
2
|
-
import type { TextStyle, ViewStyle } from 'react-native';
|
|
2
|
+
import type { TextStyle, ViewStyle, StyleProp } from 'react-native';
|
|
3
3
|
import type { SpacingProps, LayoutProps } from '../../core/utils';
|
|
4
4
|
export interface KnobMark {
|
|
5
5
|
/** Absolute value within the knob range to display */
|
|
@@ -23,17 +23,17 @@ export interface KnobValueLabelConfig {
|
|
|
23
23
|
/** Optional suffix rendered after the value */
|
|
24
24
|
suffix?: ReactNode;
|
|
25
25
|
/** Style overrides for the wrapper */
|
|
26
|
-
containerStyle?: ViewStyle
|
|
26
|
+
containerStyle?: StyleProp<ViewStyle>;
|
|
27
27
|
/** Style overrides for the primary text */
|
|
28
|
-
textStyle?: TextStyle
|
|
28
|
+
textStyle?: StyleProp<TextStyle>;
|
|
29
29
|
/** Secondary readout rendered at an independent slot */
|
|
30
30
|
secondary?: {
|
|
31
31
|
formatter?: (value: number) => ReactNode;
|
|
32
32
|
position?: KnobValueLabelPosition;
|
|
33
33
|
prefix?: ReactNode;
|
|
34
34
|
suffix?: ReactNode;
|
|
35
|
-
containerStyle?: ViewStyle
|
|
36
|
-
textStyle?: TextStyle
|
|
35
|
+
containerStyle?: StyleProp<ViewStyle>;
|
|
36
|
+
textStyle?: StyleProp<TextStyle>;
|
|
37
37
|
};
|
|
38
38
|
}
|
|
39
39
|
export type KnobInteractionMode = 'spin' | 'vertical-slide' | 'horizontal-slide' | 'scroll';
|
|
@@ -109,7 +109,7 @@ export interface KnobThumbStyle {
|
|
|
109
109
|
strokeColor?: string;
|
|
110
110
|
offset?: number;
|
|
111
111
|
glow?: KnobThumbGlow;
|
|
112
|
-
style?: ViewStyle
|
|
112
|
+
style?: StyleProp<ViewStyle>;
|
|
113
113
|
renderThumb?: (context: KnobThumbRenderContext) => ReactNode;
|
|
114
114
|
}
|
|
115
115
|
export type KnobTickSource = 'marks' | 'steps' | 'values';
|
|
@@ -119,7 +119,7 @@ export interface KnobTickLabelConfig {
|
|
|
119
119
|
formatter?: (mark: KnobMark, index: number) => ReactNode;
|
|
120
120
|
position?: 'inner' | 'center' | 'outer';
|
|
121
121
|
offset?: number;
|
|
122
|
-
style?: TextStyle
|
|
122
|
+
style?: StyleProp<TextStyle>;
|
|
123
123
|
}
|
|
124
124
|
export interface KnobTickLayer {
|
|
125
125
|
source?: KnobTickSource;
|
|
@@ -239,13 +239,13 @@ export interface KnobProps extends SpacingProps, LayoutProps {
|
|
|
239
239
|
/** Placement for the external label */
|
|
240
240
|
labelPosition?: 'left' | 'right' | 'top' | 'bottom';
|
|
241
241
|
/** Style overrides for the outer container */
|
|
242
|
-
style?: ViewStyle
|
|
242
|
+
style?: StyleProp<ViewStyle>;
|
|
243
243
|
/** Style overrides for the circular track */
|
|
244
|
-
trackStyle?: ViewStyle
|
|
244
|
+
trackStyle?: StyleProp<ViewStyle>;
|
|
245
245
|
/** Style overrides for the thumb */
|
|
246
|
-
thumbStyle?: ViewStyle
|
|
246
|
+
thumbStyle?: StyleProp<ViewStyle>;
|
|
247
247
|
/** Style overrides for mark labels */
|
|
248
|
-
markLabelStyle?: TextStyle
|
|
248
|
+
markLabelStyle?: StyleProp<TextStyle>;
|
|
249
249
|
/** Accessibility identifier */
|
|
250
250
|
testID?: string;
|
|
251
251
|
/** Screen reader label */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { ViewStyle, TextStyle } from 'react-native';
|
|
1
|
+
import type { ViewStyle, TextStyle, StyleProp } from 'react-native';
|
|
2
2
|
import type { ComponentSizeValue } from '../../core/theme/componentSize';
|
|
3
3
|
export interface ListGroupMetrics {
|
|
4
4
|
paddingVertical: number;
|
|
@@ -14,7 +14,7 @@ export interface ListGroupProps {
|
|
|
14
14
|
radius?: 'sm' | 'md' | 'lg' | number;
|
|
15
15
|
dividers?: boolean;
|
|
16
16
|
insetDividers?: boolean;
|
|
17
|
-
style?: ViewStyle
|
|
17
|
+
style?: StyleProp<ViewStyle>;
|
|
18
18
|
}
|
|
19
19
|
export interface ListGroupItemProps {
|
|
20
20
|
children: React.ReactNode;
|
|
@@ -24,8 +24,8 @@ export interface ListGroupItemProps {
|
|
|
24
24
|
danger?: boolean;
|
|
25
25
|
startSection?: React.ReactNode;
|
|
26
26
|
endSection?: React.ReactNode;
|
|
27
|
-
style?: ViewStyle
|
|
28
|
-
textStyle?: TextStyle
|
|
27
|
+
style?: StyleProp<ViewStyle>;
|
|
28
|
+
textStyle?: StyleProp<TextStyle>;
|
|
29
29
|
}
|
|
30
30
|
export interface ListGroupContextValue {
|
|
31
31
|
size: ComponentSizeValue;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { ViewStyle } from 'react-native';
|
|
1
|
+
import { ViewStyle, StyleProp } from 'react-native';
|
|
2
2
|
import { SizeValue } from '../../core/theme/sizes';
|
|
3
3
|
import { SpacingProps } from '../../core/utils';
|
|
4
4
|
export type LoaderVariant = 'bars' | 'dots' | 'oval';
|
|
@@ -12,7 +12,7 @@ export interface LoaderProps extends SpacingProps {
|
|
|
12
12
|
/** Animation speed in milliseconds */
|
|
13
13
|
speed?: number;
|
|
14
14
|
/** Container style */
|
|
15
|
-
style?: ViewStyle
|
|
15
|
+
style?: StyleProp<ViewStyle>;
|
|
16
16
|
/** Test ID for testing */
|
|
17
17
|
testID?: string;
|
|
18
18
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ReactNode } from 'react';
|
|
2
|
-
import type { ViewStyle } from 'react-native';
|
|
2
|
+
import type { ViewStyle, StyleProp } from 'react-native';
|
|
3
3
|
import type { FlashListProps } from '@shopify/flash-list';
|
|
4
4
|
import type { SpacingProps } from '../../core/utils/spacing';
|
|
5
5
|
import type { SizeValue } from '../../core/theme/sizes';
|
|
@@ -11,7 +11,7 @@ export interface MasonryItem {
|
|
|
11
11
|
/** Optional custom height ratio (default: 1) */
|
|
12
12
|
heightRatio?: number;
|
|
13
13
|
/** Optional custom styling for the item */
|
|
14
|
-
style?: ViewStyle
|
|
14
|
+
style?: StyleProp<ViewStyle>;
|
|
15
15
|
}
|
|
16
16
|
export interface MasonryProps extends SpacingProps {
|
|
17
17
|
/** Array of items to display in masonry layout */
|
|
@@ -25,9 +25,9 @@ export interface MasonryProps extends SpacingProps {
|
|
|
25
25
|
/** Custom item renderer - receives item and index */
|
|
26
26
|
renderItem?: (item: MasonryItem, index: number) => ReactNode;
|
|
27
27
|
/** Content container style */
|
|
28
|
-
contentContainerStyle?: ViewStyle
|
|
28
|
+
contentContainerStyle?: StyleProp<ViewStyle>;
|
|
29
29
|
/** Custom styles */
|
|
30
|
-
style?: ViewStyle
|
|
30
|
+
style?: StyleProp<ViewStyle>;
|
|
31
31
|
/** Test ID for testing */
|
|
32
32
|
testID?: string;
|
|
33
33
|
/** Loading state */
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { ReactNode } from 'react';
|
|
2
|
-
import type { ViewStyle } from 'react-native';
|
|
2
|
+
import type { ViewStyle, StyleProp } from 'react-native';
|
|
3
3
|
export interface NavigationState {
|
|
4
4
|
routes: Route[];
|
|
5
5
|
index: number;
|
|
@@ -46,7 +46,7 @@ export interface DrawerScreenProps extends Omit<ScreenProps, 'options'> {
|
|
|
46
46
|
}
|
|
47
47
|
export interface DrawerNavigatorProps extends NavigatorProps {
|
|
48
48
|
screenOptions?: DrawerOptions;
|
|
49
|
-
drawerStyle?: ViewStyle
|
|
49
|
+
drawerStyle?: StyleProp<ViewStyle>;
|
|
50
50
|
drawerContent?: (props: any) => ReactNode;
|
|
51
51
|
}
|
|
52
52
|
export interface StackOptions extends NavigationOptions {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { View, ViewStyle } from 'react-native';
|
|
2
|
+
import { View, ViewStyle, StyleProp } from 'react-native';
|
|
3
3
|
import { SpacingProps } from '../../core/utils';
|
|
4
4
|
import { BorderRadiusProps } from '../../core/theme/radius';
|
|
5
5
|
export type NoticeVariant = 'light' | 'filled' | 'outline' | 'subtle';
|
|
@@ -16,7 +16,7 @@ export interface NoticeProps extends SpacingProps, BorderRadiusProps {
|
|
|
16
16
|
withCloseButton?: boolean;
|
|
17
17
|
closeButtonLabel?: string;
|
|
18
18
|
onClose?: () => void;
|
|
19
|
-
style?: ViewStyle
|
|
19
|
+
style?: StyleProp<ViewStyle>;
|
|
20
20
|
testID?: string;
|
|
21
21
|
}
|
|
22
22
|
export interface NoticeFactoryPayload {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ReactNode } from 'react';
|
|
2
|
-
import { ViewStyle, TextStyle } from 'react-native';
|
|
2
|
+
import { ViewStyle, TextStyle, StyleProp } from 'react-native';
|
|
3
3
|
import { SpacingProps } from '../../core/theme/types';
|
|
4
4
|
import type { ComponentSizeValue } from '../../core/theme/componentSize';
|
|
5
5
|
export interface PaginationMetrics {
|
|
@@ -41,15 +41,15 @@ export interface PaginationProps extends SpacingProps {
|
|
|
41
41
|
/** Whether pagination is disabled */
|
|
42
42
|
disabled?: boolean;
|
|
43
43
|
/** Custom styles */
|
|
44
|
-
style?: ViewStyle
|
|
44
|
+
style?: StyleProp<ViewStyle>;
|
|
45
45
|
/** Custom button styles */
|
|
46
|
-
buttonStyle?: ViewStyle
|
|
46
|
+
buttonStyle?: StyleProp<ViewStyle>;
|
|
47
47
|
/** Custom active button styles */
|
|
48
|
-
activeButtonStyle?: ViewStyle
|
|
48
|
+
activeButtonStyle?: StyleProp<ViewStyle>;
|
|
49
49
|
/** Custom text styles */
|
|
50
|
-
textStyle?: TextStyle
|
|
50
|
+
textStyle?: StyleProp<TextStyle>;
|
|
51
51
|
/** Custom active text styles */
|
|
52
|
-
activeTextStyle?: TextStyle
|
|
52
|
+
activeTextStyle?: StyleProp<TextStyle>;
|
|
53
53
|
/** Hide pagination when there's only one page */
|
|
54
54
|
hideOnSinglePage?: boolean;
|
|
55
55
|
/** Show page size selector */
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import type { View, Text, ViewStyle } from 'react-native';
|
|
1
|
+
import type { View, Text, ViewStyle, StyleProp } from 'react-native';
|
|
2
2
|
import type { SpacingProps } from '../../core/utils';
|
|
3
3
|
import type { SizeValue } from '../../core/theme/sizes';
|
|
4
4
|
export type ProgressColor = 'primary' | 'secondary' | 'success' | 'warning' | 'error' | 'gray';
|
|
@@ -11,7 +11,7 @@ export interface ProgressProps extends SpacingProps {
|
|
|
11
11
|
animate?: boolean;
|
|
12
12
|
transitionDuration?: number;
|
|
13
13
|
fullWidth?: boolean;
|
|
14
|
-
style?: ViewStyle
|
|
14
|
+
style?: StyleProp<ViewStyle>;
|
|
15
15
|
'aria-label'?: string;
|
|
16
16
|
testID?: string;
|
|
17
17
|
}
|
|
@@ -24,7 +24,7 @@ export interface ProgressRootProps extends SpacingProps {
|
|
|
24
24
|
size?: SizeValue;
|
|
25
25
|
radius?: SizeValue;
|
|
26
26
|
children: React.ReactNode;
|
|
27
|
-
style?: ViewStyle
|
|
27
|
+
style?: StyleProp<ViewStyle>;
|
|
28
28
|
testID?: string;
|
|
29
29
|
}
|
|
30
30
|
export interface ProgressLabelProps {
|