@utilitywarehouse/hearth-react-native 0.8.1 → 0.9.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/.storybook/preview.tsx +1 -0
- package/.turbo/turbo-build.log +1 -1
- package/.turbo/turbo-lint.log +1 -1
- package/CHANGELOG.md +24 -0
- package/build/components/Banner/Banner.js +49 -10
- package/build/components/Banner/Banner.props.d.ts +4 -9
- package/build/components/BottomSheet/BottomSheetHandle.js +8 -0
- package/build/components/Card/Card.props.d.ts +1 -0
- package/build/components/Card/CardRoot.d.ts +1 -1
- package/build/components/Card/CardRoot.js +28 -1
- package/build/components/HighlightBanner/HighlightBanner.props.d.ts +1 -1
- package/build/components/List/List.js +1 -1
- package/build/components/List/ListAction/ListActionTrailingIcon.js +2 -2
- package/build/components/Menu/Menu.context.d.ts +5 -0
- package/build/components/Menu/Menu.context.js +9 -0
- package/build/components/Menu/Menu.d.ts +4 -0
- package/build/components/Menu/Menu.js +25 -0
- package/build/components/Menu/Menu.props.d.ts +21 -0
- package/build/components/Menu/Menu.props.js +1 -0
- package/build/components/Menu/MenuItem.d.ts +18 -0
- package/build/components/Menu/MenuItem.js +115 -0
- package/build/components/Menu/MenuItem.props.d.ts +27 -0
- package/build/components/Menu/MenuItem.props.js +1 -0
- package/build/components/Menu/MenuTrigger.d.ts +9 -0
- package/build/components/Menu/MenuTrigger.js +11 -0
- package/build/components/Menu/MenuTrigger.props.d.ts +12 -0
- package/build/components/Menu/MenuTrigger.props.js +1 -0
- package/build/components/Menu/index.d.ts +7 -0
- package/build/components/Menu/index.js +4 -0
- package/build/components/Modal/Modal.d.ts +1 -1
- package/build/components/Modal/Modal.js +32 -30
- package/build/components/Modal/Modal.props.d.ts +1 -0
- package/build/components/Modal/Modal.web.d.ts +1 -1
- package/build/components/Modal/Modal.web.js +25 -25
- package/build/components/RadioCard/RadioCardGroup.context.d.ts +12 -0
- package/build/components/RadioCard/RadioCardGroup.context.js +3 -0
- package/build/components/RadioCard/RadioCardGroup.js +15 -10
- package/build/components/RadioCard/RadioCardLabel.d.ts +1 -1
- package/build/components/RadioCard/RadioCardLabel.js +7 -1
- package/build/components/RadioCard/RadioCardRoot.js +13 -0
- package/build/components/index.d.ts +1 -0
- package/build/components/index.js +1 -0
- package/build/core/themes.d.ts +40 -0
- package/build/core/themes.js +20 -0
- package/build/tokens/components/dark/index.d.ts +3 -1
- package/build/tokens/components/dark/index.js +3 -1
- package/build/tokens/components/dark/input.d.ts +3 -0
- package/build/tokens/components/dark/input.js +3 -0
- package/build/tokens/components/dark/modal.d.ts +7 -4
- package/build/tokens/components/dark/modal.js +7 -4
- package/build/tokens/components/dark/rating.d.ts +8 -0
- package/build/tokens/components/dark/rating.js +7 -0
- package/build/tokens/components/dark/table.d.ts +0 -3
- package/build/tokens/components/dark/table.js +0 -3
- package/build/tokens/components/dark/time-picker.d.ts +29 -0
- package/build/tokens/components/dark/time-picker.js +28 -0
- package/build/tokens/components/dark/timeline.d.ts +27 -0
- package/build/tokens/components/dark/timeline.js +26 -0
- package/build/tokens/components/light/index.d.ts +3 -1
- package/build/tokens/components/light/index.js +3 -1
- package/build/tokens/components/light/input.d.ts +3 -0
- package/build/tokens/components/light/input.js +3 -0
- package/build/tokens/components/light/modal.d.ts +7 -4
- package/build/tokens/components/light/modal.js +7 -4
- package/build/tokens/components/light/rating.d.ts +8 -0
- package/build/tokens/components/light/rating.js +7 -0
- package/build/tokens/components/light/table.d.ts +0 -3
- package/build/tokens/components/light/table.js +0 -3
- package/build/tokens/components/light/time-picker.d.ts +29 -0
- package/build/tokens/components/light/time-picker.js +28 -0
- package/build/tokens/components/light/timeline.d.ts +27 -0
- package/build/tokens/components/light/timeline.js +26 -0
- package/docs/adding-shadows.mdx +43 -0
- package/docs/components/AllComponents.web.tsx +33 -0
- package/docs/components/BackToTopButton.tsx +1 -1
- package/package.json +3 -3
- package/src/components/Banner/Banner.docs.mdx +20 -11
- package/src/components/Banner/Banner.props.ts +4 -9
- package/src/components/Banner/Banner.stories.tsx +17 -4
- package/src/components/Banner/Banner.tsx +92 -37
- package/src/components/BottomSheet/BottomSheetHandle.tsx +12 -0
- package/src/components/Card/Card.docs.mdx +20 -1
- package/src/components/Card/Card.props.ts +9 -0
- package/src/components/Card/Card.stories.tsx +39 -0
- package/src/components/Card/CardRoot.tsx +29 -0
- package/src/components/Checkbox/CheckboxGroup.stories.tsx +19 -1
- package/src/components/DatePickerInput/DatePickerInput.docs.mdx +1 -1
- package/src/components/HighlightBanner/HighlightBanner.docs.mdx +1 -1
- package/src/components/HighlightBanner/HighlightBanner.props.ts +1 -0
- package/src/components/HighlightBanner/HighlightBanner.stories.tsx +15 -1
- package/src/components/List/List.tsx +5 -3
- package/src/components/List/ListAction/ListActionTrailingIcon.tsx +2 -2
- package/src/components/Menu/Menu.context.ts +15 -0
- package/src/components/Menu/Menu.docs.mdx +158 -0
- package/src/components/Menu/Menu.props.ts +24 -0
- package/src/components/Menu/Menu.stories.tsx +292 -0
- package/src/components/Menu/Menu.tsx +54 -0
- package/src/components/Menu/MenuItem.props.ts +29 -0
- package/src/components/Menu/MenuItem.tsx +145 -0
- package/src/components/Menu/MenuTrigger.props.ts +14 -0
- package/src/components/Menu/MenuTrigger.tsx +20 -0
- package/src/components/Menu/index.ts +7 -0
- package/src/components/Modal/Modal.docs.mdx +34 -5
- package/src/components/Modal/Modal.props.ts +1 -0
- package/src/components/Modal/Modal.stories.tsx +46 -0
- package/src/components/Modal/Modal.tsx +37 -33
- package/src/components/Modal/Modal.web.tsx +27 -27
- package/src/components/Radio/RadioGroup.stories.tsx +18 -0
- package/src/components/RadioCard/RadioCardGroup.context.ts +16 -0
- package/src/components/RadioCard/RadioCardGroup.stories.tsx +24 -0
- package/src/components/RadioCard/RadioCardGroup.tsx +28 -19
- package/src/components/RadioCard/RadioCardLabel.tsx +12 -1
- package/src/components/RadioCard/RadioCardRoot.tsx +15 -0
- package/src/components/index.ts +1 -0
- package/src/core/themes.ts +20 -0
- package/src/tokens/components/dark/index.ts +3 -1
- package/src/tokens/components/dark/input.ts +3 -0
- package/src/tokens/components/dark/modal.ts +7 -4
- package/src/tokens/components/dark/rating.ts +8 -0
- package/src/tokens/components/dark/table.ts +0 -3
- package/src/tokens/components/dark/time-picker.ts +29 -0
- package/src/tokens/components/dark/timeline.ts +27 -0
- package/src/tokens/components/light/index.ts +3 -1
- package/src/tokens/components/light/input.ts +3 -0
- package/src/tokens/components/light/modal.ts +7 -4
- package/src/tokens/components/light/rating.ts +8 -0
- package/src/tokens/components/light/table.ts +0 -3
- package/src/tokens/components/light/time-picker.ts +29 -0
- package/src/tokens/components/light/timeline.ts +27 -0
- package/build/tokens/components/dark/dialog.d.ts +0 -25
- package/build/tokens/components/dark/dialog.js +0 -24
- package/build/tokens/components/light/dialog.d.ts +0 -25
- package/build/tokens/components/light/dialog.js +0 -24
- package/src/tokens/components/dark/dialog.ts +0 -25
- package/src/tokens/components/light/dialog.ts +0 -25
|
@@ -12,7 +12,7 @@ import { Button } from '../Button';
|
|
|
12
12
|
import { Heading } from '../Heading';
|
|
13
13
|
import { Spinner } from '../Spinner';
|
|
14
14
|
import { UnstyledIconButton } from '../UnstyledIconButton';
|
|
15
|
-
const Modal = ({ ref, children, heading, description, showCloseButton = true, primaryButtonText, secondaryButtonText, onPressPrimaryButton, onPressCloseButton, onPressSecondaryButton, closeOnPrimaryButtonPress = true, closeOnSecondaryButtonPress = true, loading, image, primaryButtonProps, secondaryButtonProps, closeButtonProps,
|
|
15
|
+
const Modal = ({ ref, children, heading, description, showCloseButton = true, primaryButtonText, secondaryButtonText, onPressPrimaryButton, onPressCloseButton, onPressSecondaryButton, closeOnPrimaryButtonPress = true, closeOnSecondaryButtonPress = true, loading, fullscreen = false, image, primaryButtonProps, secondaryButtonProps, closeButtonProps, inNavModal = false, ...props }) => {
|
|
16
16
|
const bottomSheetModalRef = useRef(null);
|
|
17
17
|
const viewRef = useRef(null);
|
|
18
18
|
const scrollViewRef = useRef(null);
|
|
@@ -20,7 +20,7 @@ const Modal = ({ ref, children, heading, description, showCloseButton = true, pr
|
|
|
20
20
|
const backgroundOpacity = useSharedValue(0);
|
|
21
21
|
const pretendContentTranslateY = useSharedValue(20);
|
|
22
22
|
const triggerCloseAnimation = useCallback(() => {
|
|
23
|
-
if (Platform.OS === 'android' &&
|
|
23
|
+
if (Platform.OS === 'android' && inNavModal) {
|
|
24
24
|
pretendContentTranslateY.value = withTiming(20, {
|
|
25
25
|
duration: 50,
|
|
26
26
|
easing: Easing.in(Easing.quad),
|
|
@@ -30,14 +30,14 @@ const Modal = ({ ref, children, heading, description, showCloseButton = true, pr
|
|
|
30
30
|
easing: Easing.in(Easing.quad),
|
|
31
31
|
});
|
|
32
32
|
}
|
|
33
|
-
}, [Platform.OS,
|
|
33
|
+
}, [Platform.OS, inNavModal, pretendContentTranslateY, backgroundOpacity]);
|
|
34
34
|
useImperativeHandle(ref, () => ({
|
|
35
35
|
...bottomSheetModalRef.current,
|
|
36
36
|
triggerCloseAnimation,
|
|
37
37
|
}));
|
|
38
|
-
// Trigger animations on render for
|
|
38
|
+
// Trigger animations on render for inNavModal Android modal
|
|
39
39
|
useEffect(() => {
|
|
40
|
-
if (Platform.OS === 'android' &&
|
|
40
|
+
if (Platform.OS === 'android' && inNavModal) {
|
|
41
41
|
backgroundOpacity.value = withDelay(300, withTiming(1, {
|
|
42
42
|
duration: 200,
|
|
43
43
|
easing: Easing.out(Easing.quad),
|
|
@@ -47,11 +47,11 @@ const Modal = ({ ref, children, heading, description, showCloseButton = true, pr
|
|
|
47
47
|
easing: Easing.out(Easing.quad),
|
|
48
48
|
}));
|
|
49
49
|
}
|
|
50
|
-
}, [
|
|
50
|
+
}, [inNavModal, backgroundOpacity, pretendContentTranslateY]);
|
|
51
51
|
const animatedBackgroundStyle = useAnimatedStyle(() => ({
|
|
52
52
|
backgroundColor: hexWithOpacity(theme.components.overlay.backgroundColor, backgroundOpacity.value * (theme.components.overlay.opacity / 100)),
|
|
53
53
|
}));
|
|
54
|
-
const
|
|
54
|
+
const animatedInNavModalStyle = useAnimatedStyle(() => ({
|
|
55
55
|
backgroundColor: hexWithOpacity(theme.components.overlay.backgroundColor, backgroundOpacity.value * (theme.components.overlay.opacity / 100)),
|
|
56
56
|
}));
|
|
57
57
|
const animatedPretendContentStyle = useAnimatedStyle(() => ({
|
|
@@ -99,12 +99,15 @@ const Modal = ({ ref, children, heading, description, showCloseButton = true, pr
|
|
|
99
99
|
};
|
|
100
100
|
styles.useVariants({ loading });
|
|
101
101
|
const content = (_jsx(_Fragment, { children: loading ? (_jsxs(View, { style: styles.loadingContainer, accessible: Platform.OS === 'android' ? true : undefined, accessibilityLabel: Platform.OS === 'android' ? 'Loading' : undefined, screenReaderFocusable: true, ref: viewRef, children: [_jsx(Spinner, { size: "lg" }), _jsx(Heading, { size: "lg", textAlign: "center", children: "Loading..." })] })) : (_jsxs(View, { style: styles.container, accessible: Platform.OS === 'android' ? true : undefined, accessibilityLabel: Platform.OS === 'android' ? 'Modal content' : undefined, screenReaderFocusable: true, ref: viewRef, children: [_jsxs(View, { style: styles.header, children: [_jsxs(View, { style: styles.headerTextContent, children: [heading && !image ? (_jsx(Heading, { size: "lg", accessible: true, children: heading })) : null, description && !image ? _jsx(BodyText, { accessible: true, children: description }) : null] }), showCloseButton ? (_jsx(UnstyledIconButton, { icon: CloseMediumIcon, onPress: handleCloseButtonPress, accessibilityLabel: "Close modal", ...closeButtonProps })) : null] }), image ? (_jsxs(View, { style: styles.imageContainer, children: [_jsx(Image, { style: styles.image, ...image }), _jsxs(View, { style: styles.textContent, children: [heading ? (_jsx(Heading, { size: "lg", textAlign: "center", accessible: true, children: heading })) : null, description ? (_jsx(BodyText, { textAlign: "center", accessible: true, children: description })) : null] })] })) : null, children, _jsxs(View, { style: styles.footer, children: [onPressPrimaryButton && primaryButtonText ? (_jsx(Button, { onPress: handlePrimaryButtonPress, text: primaryButtonText, ...primaryButtonProps, variant: primaryButtonProps?.variant ?? 'solid', colorScheme: primaryButtonProps?.colorScheme ?? 'highlight' })) : null, onPressSecondaryButton && secondaryButtonText ? (_jsx(Button, { onPress: handleSecondaryButtonPress, text: secondaryButtonText, ...secondaryButtonProps, variant: secondaryButtonProps?.variant ?? 'outline', colorScheme: secondaryButtonProps?.colorScheme ?? 'functional' })) : null] })] })) }));
|
|
102
|
-
return
|
|
102
|
+
return inNavModal ? (_jsxs(View, { style: { flex: 1, backgroundColor: theme.color.background.primary }, children: [Platform.OS === 'android' ? (_jsx(Animated.View, { style: [styles.androidContainer, animatedBackgroundStyle], children: _jsx(Animated.View, { style: [styles.pretendContent, animatedPretendContentStyle] }) })) : null, _jsx(Animated.View, { style: [styles.inNavModalContainer, Platform.OS === 'android' && animatedInNavModalStyle], children: _jsx(View, { style: styles.inNavModalContent, children: content }) })] })) : (_jsxs(BottomSheetModal, { ref: bottomSheetModalRef, enableDynamicSizing: true, snapPoints: image || fullscreen ? ['90%'] : props.snapPoints, showHandle: typeof loading !== 'undefined' && loading ? false : props.showHandle, accessible: false, style: styles.modal, ...props, onChange: handleChange, children: [loading ? _jsx(View, { style: styles.loadingTop }) : null, _jsx(BottomSheetScrollView, { contentContainerStyle: styles.container, ref: scrollViewRef, children: content })] }));
|
|
103
103
|
};
|
|
104
104
|
const styles = StyleSheet.create((theme, rt) => ({
|
|
105
|
+
modal: {
|
|
106
|
+
gap: theme.components.modal.content.gap - theme.components.bottomSheet.gap,
|
|
107
|
+
},
|
|
105
108
|
container: {
|
|
106
109
|
flex: 1,
|
|
107
|
-
gap: theme.components.
|
|
110
|
+
gap: theme.components.modal.gap,
|
|
108
111
|
variants: {
|
|
109
112
|
loading: {
|
|
110
113
|
true: {
|
|
@@ -115,11 +118,11 @@ const styles = StyleSheet.create((theme, rt) => ({
|
|
|
115
118
|
},
|
|
116
119
|
header: {
|
|
117
120
|
flexDirection: 'row',
|
|
118
|
-
gap: theme.components.
|
|
121
|
+
gap: theme.components.modal.gap,
|
|
119
122
|
},
|
|
120
123
|
headerTextContent: {
|
|
121
124
|
flex: 1,
|
|
122
|
-
gap: theme.components.
|
|
125
|
+
gap: theme.components.modal.content.gap,
|
|
123
126
|
},
|
|
124
127
|
image: {
|
|
125
128
|
width: 260,
|
|
@@ -127,52 +130,51 @@ const styles = StyleSheet.create((theme, rt) => ({
|
|
|
127
130
|
},
|
|
128
131
|
imageContainer: {
|
|
129
132
|
alignItems: 'center',
|
|
130
|
-
justifyContent: 'center',
|
|
131
133
|
flex: 1,
|
|
132
134
|
},
|
|
133
135
|
textContent: {
|
|
134
|
-
gap: theme.components.
|
|
136
|
+
gap: theme.components.modal.content.gap,
|
|
135
137
|
},
|
|
136
138
|
loadingTop: {
|
|
137
|
-
borderTopLeftRadius: theme.components.
|
|
138
|
-
borderTopRightRadius: theme.components.
|
|
139
|
+
borderTopLeftRadius: theme.components.modal.borderRadius,
|
|
140
|
+
borderTopRightRadius: theme.components.modal.borderRadius,
|
|
139
141
|
height: 16,
|
|
140
142
|
backgroundColor: theme.color.surface.neutral.strong,
|
|
141
143
|
},
|
|
142
144
|
loadingContainer: {
|
|
143
|
-
borderTopLeftRadius: theme.components.
|
|
144
|
-
borderTopRightRadius: theme.components.
|
|
145
|
+
borderTopLeftRadius: theme.components.modal.borderRadius,
|
|
146
|
+
borderTopRightRadius: theme.components.modal.borderRadius,
|
|
145
147
|
flex: 1,
|
|
146
148
|
alignItems: 'center',
|
|
147
149
|
justifyContent: 'center',
|
|
148
150
|
minHeight: 140,
|
|
149
|
-
gap: theme.components.
|
|
151
|
+
gap: theme.components.modal.content.gap,
|
|
150
152
|
},
|
|
151
153
|
footer: {
|
|
152
|
-
gap: theme.components.
|
|
154
|
+
gap: theme.components.modal.action.gap,
|
|
153
155
|
},
|
|
154
|
-
|
|
156
|
+
inNavModalContainer: {
|
|
155
157
|
flex: 1,
|
|
156
158
|
...(Platform.OS === 'ios' ? { backgroundColor: theme.components.overlay.backgroundColor } : {}),
|
|
157
159
|
},
|
|
158
|
-
|
|
160
|
+
inNavModalContent: {
|
|
159
161
|
flex: 1,
|
|
160
|
-
borderTopLeftRadius: theme.components.
|
|
161
|
-
borderTopRightRadius: theme.components.
|
|
162
|
+
borderTopLeftRadius: theme.components.modal.borderRadius,
|
|
163
|
+
borderTopRightRadius: theme.components.modal.borderRadius,
|
|
162
164
|
backgroundColor: theme.color.surface.neutral.strong,
|
|
163
|
-
gap: theme.components.
|
|
164
|
-
padding: theme.components.
|
|
165
|
-
paddingBottom: theme.components.
|
|
165
|
+
gap: theme.components.modal.gap,
|
|
166
|
+
padding: theme.components.modal.padding,
|
|
167
|
+
paddingBottom: theme.components.modal.padding + rt.insets.bottom,
|
|
166
168
|
},
|
|
167
169
|
androidContainer: {
|
|
168
170
|
height: rt.insets.top + 18,
|
|
169
|
-
paddingLeft: theme.components.
|
|
170
|
-
paddingRight: theme.components.
|
|
171
|
+
paddingLeft: theme.components.modal.padding,
|
|
172
|
+
paddingRight: theme.components.modal.padding,
|
|
171
173
|
justifyContent: 'flex-end',
|
|
172
174
|
},
|
|
173
175
|
pretendContent: {
|
|
174
|
-
borderTopLeftRadius: theme.components.
|
|
175
|
-
borderTopRightRadius: theme.components.
|
|
176
|
+
borderTopLeftRadius: theme.components.modal.borderRadius,
|
|
177
|
+
borderTopRightRadius: theme.components.modal.borderRadius,
|
|
176
178
|
height: 12,
|
|
177
179
|
backgroundColor: theme.components.parts.modalStack.backgroundColorCardTop,
|
|
178
180
|
},
|
|
@@ -3,5 +3,5 @@ import ModalProps from './Modal.props';
|
|
|
3
3
|
type Modal<T = any> = BottomSheetModalMethods<T> & {
|
|
4
4
|
triggerCloseAnimation?: () => void;
|
|
5
5
|
};
|
|
6
|
-
declare const Modal: ({ ref, children, heading, description, showCloseButton, primaryButtonText, secondaryButtonText, onPressPrimaryButton, onPressCloseButton, onPressSecondaryButton, closeOnPrimaryButtonPress, closeOnSecondaryButtonPress, loading, image, primaryButtonProps, secondaryButtonProps, closeButtonProps,
|
|
6
|
+
declare const Modal: ({ ref, children, heading, description, showCloseButton, primaryButtonText, secondaryButtonText, onPressPrimaryButton, onPressCloseButton, onPressSecondaryButton, closeOnPrimaryButtonPress, closeOnSecondaryButtonPress, loading, image, primaryButtonProps, secondaryButtonProps, closeButtonProps, inNavModal, ...props }: ModalProps) => import("react/jsx-runtime").JSX.Element;
|
|
7
7
|
export default Modal;
|
|
@@ -12,7 +12,7 @@ import { Button } from '../Button';
|
|
|
12
12
|
import { Heading } from '../Heading';
|
|
13
13
|
import { Spinner } from '../Spinner';
|
|
14
14
|
import { UnstyledIconButton } from '../UnstyledIconButton';
|
|
15
|
-
const Modal = ({ ref, children, heading, description, showCloseButton = true, primaryButtonText, secondaryButtonText, onPressPrimaryButton, onPressCloseButton, onPressSecondaryButton, closeOnPrimaryButtonPress = true, closeOnSecondaryButtonPress = true, loading, image, primaryButtonProps, secondaryButtonProps, closeButtonProps,
|
|
15
|
+
const Modal = ({ ref, children, heading, description, showCloseButton = true, primaryButtonText, secondaryButtonText, onPressPrimaryButton, onPressCloseButton, onPressSecondaryButton, closeOnPrimaryButtonPress = true, closeOnSecondaryButtonPress = true, loading, image, primaryButtonProps, secondaryButtonProps, closeButtonProps, inNavModal = false, ...props }) => {
|
|
16
16
|
const bottomSheetModalRef = useRef(null);
|
|
17
17
|
const viewRef = useRef(null);
|
|
18
18
|
const scrollViewRef = useRef(null);
|
|
@@ -20,7 +20,7 @@ const Modal = ({ ref, children, heading, description, showCloseButton = true, pr
|
|
|
20
20
|
const backgroundOpacity = useSharedValue(0);
|
|
21
21
|
const pretendContentTranslateY = useSharedValue(20);
|
|
22
22
|
const triggerCloseAnimation = useCallback(() => {
|
|
23
|
-
if (Platform.OS === 'android' &&
|
|
23
|
+
if (Platform.OS === 'android' && inNavModal) {
|
|
24
24
|
pretendContentTranslateY.value = withTiming(20, {
|
|
25
25
|
duration: 50,
|
|
26
26
|
easing: Easing.in(Easing.quad),
|
|
@@ -30,14 +30,14 @@ const Modal = ({ ref, children, heading, description, showCloseButton = true, pr
|
|
|
30
30
|
easing: Easing.in(Easing.quad),
|
|
31
31
|
});
|
|
32
32
|
}
|
|
33
|
-
}, [Platform.OS,
|
|
33
|
+
}, [Platform.OS, inNavModal, pretendContentTranslateY, backgroundOpacity]);
|
|
34
34
|
useImperativeHandle(ref, () => ({
|
|
35
35
|
...bottomSheetModalRef.current,
|
|
36
36
|
triggerCloseAnimation,
|
|
37
37
|
}));
|
|
38
|
-
// Trigger animations on render for
|
|
38
|
+
// Trigger animations on render for inNavModal Android modal
|
|
39
39
|
useEffect(() => {
|
|
40
|
-
if (Platform.OS === 'android' &&
|
|
40
|
+
if (Platform.OS === 'android' && inNavModal) {
|
|
41
41
|
backgroundOpacity.value = withDelay(300, withTiming(1, {
|
|
42
42
|
duration: 200,
|
|
43
43
|
easing: Easing.out(Easing.quad),
|
|
@@ -47,11 +47,11 @@ const Modal = ({ ref, children, heading, description, showCloseButton = true, pr
|
|
|
47
47
|
easing: Easing.out(Easing.quad),
|
|
48
48
|
}));
|
|
49
49
|
}
|
|
50
|
-
}, [
|
|
50
|
+
}, [inNavModal, backgroundOpacity, pretendContentTranslateY]);
|
|
51
51
|
const animatedBackgroundStyle = useAnimatedStyle(() => ({
|
|
52
52
|
backgroundColor: hexWithOpacity(theme.components.overlay.backgroundColor, backgroundOpacity.value * (theme.components.overlay.opacity / 100)),
|
|
53
53
|
}));
|
|
54
|
-
const
|
|
54
|
+
const animatedInNavModalStyle = useAnimatedStyle(() => ({
|
|
55
55
|
backgroundColor: hexWithOpacity(theme.components.overlay.backgroundColor, backgroundOpacity.value * (theme.components.overlay.opacity / 100)),
|
|
56
56
|
}));
|
|
57
57
|
const animatedPretendContentStyle = useAnimatedStyle(() => ({
|
|
@@ -98,20 +98,20 @@ const Modal = ({ ref, children, heading, description, showCloseButton = true, pr
|
|
|
98
98
|
}
|
|
99
99
|
};
|
|
100
100
|
const content = (_jsx(_Fragment, { children: loading ? (_jsxs(View, { style: styles.loadingContainer, accessible: Platform.OS === 'android' ? true : undefined, accessibilityLabel: Platform.OS === 'android' ? 'Loading' : undefined, screenReaderFocusable: true, ref: viewRef, children: [_jsx(Spinner, { size: "lg" }), _jsx(Heading, { size: "lg", textAlign: "center", children: "Loading..." })] })) : (_jsxs(View, { style: styles.container, accessible: Platform.OS === 'android' ? true : undefined, accessibilityLabel: Platform.OS === 'android' ? 'Modal content' : undefined, screenReaderFocusable: true, ref: viewRef, children: [_jsxs(View, { style: styles.header, children: [_jsxs(View, { style: styles.headerTextContent, children: [heading && !image ? (_jsx(Heading, { size: "lg", accessible: true, children: heading })) : null, description && !image ? _jsx(BodyText, { accessible: true, children: description }) : null] }), showCloseButton ? (_jsx(UnstyledIconButton, { icon: CloseMediumIcon, onPress: handleCloseButtonPress, accessibilityLabel: "Close modal", ...closeButtonProps })) : null] }), image ? (_jsxs(View, { style: styles.imageContainer, children: [_jsx(Image, { style: styles.image, ...image }), _jsxs(View, { style: styles.textContent, children: [heading ? (_jsx(Heading, { size: "lg", textAlign: "center", accessible: true, children: heading })) : null, description ? (_jsx(BodyText, { textAlign: "center", accessible: true, children: description })) : null] })] })) : null, children, _jsxs(View, { style: styles.footer, children: [onPressPrimaryButton && primaryButtonText ? (_jsx(Button, { onPress: handlePrimaryButtonPress, text: primaryButtonText, ...primaryButtonProps, variant: primaryButtonProps?.variant ?? 'solid', colorScheme: primaryButtonProps?.colorScheme ?? 'highlight' })) : null, onPressSecondaryButton && secondaryButtonText ? (_jsx(Button, { onPress: handleSecondaryButtonPress, text: secondaryButtonText, ...secondaryButtonProps, variant: secondaryButtonProps?.variant ?? 'outline', colorScheme: secondaryButtonProps?.colorScheme ?? 'functional' })) : null] })] })) }));
|
|
101
|
-
return
|
|
101
|
+
return inNavModal ? (_jsxs(View, { style: { flex: 1, backgroundColor: theme.color.background.primary }, children: [Platform.OS === 'android' ? (_jsx(Animated.View, { style: [styles.androidContainer, animatedBackgroundStyle], children: _jsx(Animated.View, { style: [styles.pretendContent, animatedPretendContentStyle] }) })) : null, _jsx(Animated.View, { style: [styles.inNavModalContainer, Platform.OS === 'android' && animatedInNavModalStyle], children: _jsx(View, { style: styles.inNavModalContent, children: content }) })] })) : (_jsx(BottomSheetModal, { ref: bottomSheetModalRef, enableDynamicSizing: true, snapPoints: image ? ['90%'] : props.snapPoints, showHandle: typeof loading !== 'undefined' && loading ? false : props.showHandle, accessible: false, ...props, onChange: handleChange, children: _jsx(BottomSheetScrollView, { contentContainerStyle: styles.container, ref: scrollViewRef, children: content }) }));
|
|
102
102
|
};
|
|
103
103
|
const styles = StyleSheet.create((theme, rt) => ({
|
|
104
104
|
container: {
|
|
105
105
|
flex: 1,
|
|
106
|
-
gap: theme.components.
|
|
106
|
+
gap: theme.components.modal.gap,
|
|
107
107
|
},
|
|
108
108
|
header: {
|
|
109
109
|
flexDirection: 'row',
|
|
110
|
-
gap: theme.components.
|
|
110
|
+
gap: theme.components.modal.gap,
|
|
111
111
|
},
|
|
112
112
|
headerTextContent: {
|
|
113
113
|
flex: 1,
|
|
114
|
-
gap: theme.components.
|
|
114
|
+
gap: theme.components.modal.content.gap,
|
|
115
115
|
},
|
|
116
116
|
image: {
|
|
117
117
|
width: 260,
|
|
@@ -123,40 +123,40 @@ const styles = StyleSheet.create((theme, rt) => ({
|
|
|
123
123
|
flex: 1,
|
|
124
124
|
},
|
|
125
125
|
textContent: {
|
|
126
|
-
gap: theme.components.
|
|
126
|
+
gap: theme.components.modal.content.gap,
|
|
127
127
|
},
|
|
128
128
|
loadingContainer: {
|
|
129
129
|
flex: 1,
|
|
130
130
|
alignItems: 'center',
|
|
131
131
|
justifyContent: 'center',
|
|
132
132
|
minHeight: 140,
|
|
133
|
-
gap: theme.components.
|
|
133
|
+
gap: theme.components.modal.content.gap,
|
|
134
134
|
},
|
|
135
135
|
footer: {
|
|
136
|
-
gap: theme.components.
|
|
136
|
+
gap: theme.components.modal.action.gap,
|
|
137
137
|
},
|
|
138
|
-
|
|
138
|
+
inNavModalContainer: {
|
|
139
139
|
flex: 1,
|
|
140
140
|
...(Platform.OS === 'ios' ? { backgroundColor: theme.components.overlay.backgroundColor } : {}),
|
|
141
141
|
},
|
|
142
|
-
|
|
142
|
+
inNavModalContent: {
|
|
143
143
|
flex: 1,
|
|
144
|
-
borderTopLeftRadius: theme.components.
|
|
145
|
-
borderTopRightRadius: theme.components.
|
|
144
|
+
borderTopLeftRadius: theme.components.modal.borderRadius,
|
|
145
|
+
borderTopRightRadius: theme.components.modal.borderRadius,
|
|
146
146
|
backgroundColor: theme.color.surface.neutral.strong,
|
|
147
|
-
gap: theme.components.
|
|
148
|
-
padding: theme.components.
|
|
149
|
-
paddingBottom: theme.components.
|
|
147
|
+
gap: theme.components.modal.gap,
|
|
148
|
+
padding: theme.components.modal.padding,
|
|
149
|
+
paddingBottom: theme.components.modal.padding + rt.insets.bottom,
|
|
150
150
|
},
|
|
151
151
|
androidContainer: {
|
|
152
152
|
height: rt.insets.top + 18,
|
|
153
|
-
paddingLeft: theme.components.
|
|
154
|
-
paddingRight: theme.components.
|
|
153
|
+
paddingLeft: theme.components.modal.padding,
|
|
154
|
+
paddingRight: theme.components.modal.padding,
|
|
155
155
|
justifyContent: 'flex-end',
|
|
156
156
|
},
|
|
157
157
|
pretendContent: {
|
|
158
|
-
borderTopLeftRadius: theme.components.
|
|
159
|
-
borderTopRightRadius: theme.components.
|
|
158
|
+
borderTopLeftRadius: theme.components.modal.borderRadius,
|
|
159
|
+
borderTopRightRadius: theme.components.modal.borderRadius,
|
|
160
160
|
height: 12,
|
|
161
161
|
backgroundColor: theme.components.parts.modalStack.backgroundColorCardTop,
|
|
162
162
|
},
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export declare const RadioCardGroupContext: import("react").Context<{
|
|
2
|
+
flexDirection?: "row" | "column" | "row-reverse" | "column-reverse";
|
|
3
|
+
flexWrap?: "nowrap" | "wrap" | "wrap-reverse";
|
|
4
|
+
justifyContent?: "flex-start" | "flex-end" | "center" | "space-between" | "space-around" | "space-evenly";
|
|
5
|
+
alignItems?: "flex-start" | "flex-end" | "center" | "stretch" | "baseline";
|
|
6
|
+
}>;
|
|
7
|
+
export declare const useRadioCardGroupContext: () => {
|
|
8
|
+
flexDirection?: "row" | "column" | "row-reverse" | "column-reverse";
|
|
9
|
+
flexWrap?: "nowrap" | "wrap" | "wrap-reverse";
|
|
10
|
+
justifyContent?: "flex-start" | "flex-end" | "center" | "space-between" | "space-around" | "space-evenly";
|
|
11
|
+
alignItems?: "flex-start" | "flex-end" | "center" | "stretch" | "baseline";
|
|
12
|
+
};
|
|
@@ -1,18 +1,23 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { useMemo } from 'react';
|
|
2
3
|
import { View } from 'react-native';
|
|
3
4
|
import { StyleSheet } from 'react-native-unistyles';
|
|
4
5
|
import { Grid } from '../Grid';
|
|
6
|
+
import { RadioCardGroupContext } from './RadioCardGroup.context';
|
|
5
7
|
const RadioCardGroup = ({ children, gap = '200', style, flexDirection = 'row', flexWrap, justifyContent, alignItems, columns, ...props }) => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
8
|
+
const context = useMemo(() => {
|
|
9
|
+
return { flexDirection, flexWrap, justifyContent, alignItems };
|
|
10
|
+
}, [flexDirection, flexWrap, justifyContent, alignItems]);
|
|
11
|
+
return columns ? (_jsx(RadioCardGroupContext.Provider, { value: context, children: _jsx(Grid, { ...props, gap: gap, columns: columns, style: style, children: children }) })) : (_jsx(RadioCardGroupContext.Provider, { value: context, children: _jsx(View, { ...props, style: [
|
|
12
|
+
styles.containerGap(gap),
|
|
13
|
+
{
|
|
14
|
+
flexDirection,
|
|
15
|
+
flexWrap,
|
|
16
|
+
justifyContent,
|
|
17
|
+
alignItems,
|
|
18
|
+
},
|
|
19
|
+
style,
|
|
20
|
+
], children: children }) }));
|
|
16
21
|
};
|
|
17
22
|
const styles = StyleSheet.create(theme => ({
|
|
18
23
|
containerGap: (gap) => ({
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import LabelProps from '../Label/Label.props';
|
|
2
2
|
declare const RadioCardLabel: {
|
|
3
|
-
({ children, ...props }: LabelProps): import("react/jsx-runtime").JSX.Element;
|
|
3
|
+
({ children, style, ...props }: LabelProps): import("react/jsx-runtime").JSX.Element;
|
|
4
4
|
displayName: string;
|
|
5
5
|
};
|
|
6
6
|
export default RadioCardLabel;
|
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
import { jsx as _jsx } from "react/jsx-runtime";
|
|
2
|
+
import { StyleSheet } from 'react-native-unistyles';
|
|
2
3
|
import { Label } from '../Label';
|
|
3
|
-
const RadioCardLabel = ({ children, ...props }) => _jsx(Label, { ...props, children: children });
|
|
4
|
+
const RadioCardLabel = ({ children, style, ...props }) => (_jsx(Label, { ...props, style: [styles.label, style], children: children }));
|
|
5
|
+
const styles = StyleSheet.create({
|
|
6
|
+
label: {
|
|
7
|
+
flexShrink: 1,
|
|
8
|
+
},
|
|
9
|
+
});
|
|
4
10
|
RadioCardLabel.displayName = 'RadioCardLabel';
|
|
5
11
|
export default RadioCardLabel;
|
|
@@ -3,14 +3,17 @@ import { useMemo } from 'react';
|
|
|
3
3
|
import { StyleSheet } from 'react-native-unistyles';
|
|
4
4
|
import { Pressable } from 'react-native';
|
|
5
5
|
import { RadioCardContext } from './RadioCard.context';
|
|
6
|
+
import { useRadioCardGroupContext } from './RadioCardGroup.context';
|
|
6
7
|
const RadioCardRoot = ({ children, style, states, ...props }) => {
|
|
7
8
|
const { checked, active } = states ?? {};
|
|
9
|
+
const { flexDirection } = useRadioCardGroupContext() ?? {};
|
|
8
10
|
const value = useMemo(() => ({
|
|
9
11
|
checked,
|
|
10
12
|
active,
|
|
11
13
|
}), [checked, active]);
|
|
12
14
|
styles.useVariants({
|
|
13
15
|
selected: checked,
|
|
16
|
+
flexDirection,
|
|
14
17
|
});
|
|
15
18
|
return (_jsx(RadioCardContext.Provider, { value: value, children: _jsx(Pressable, { ...props, style: [styles.container, style], children: children }) }));
|
|
16
19
|
};
|
|
@@ -37,6 +40,16 @@ const styles = StyleSheet.create(theme => ({
|
|
|
37
40
|
margin: -theme.components.card.selectable.borderWidthSelected / 2,
|
|
38
41
|
},
|
|
39
42
|
},
|
|
43
|
+
flexDirection: {
|
|
44
|
+
row: {},
|
|
45
|
+
column: {
|
|
46
|
+
width: '100%',
|
|
47
|
+
},
|
|
48
|
+
'row-reverse': {},
|
|
49
|
+
'column-reverse': {
|
|
50
|
+
width: '100%',
|
|
51
|
+
},
|
|
52
|
+
},
|
|
40
53
|
},
|
|
41
54
|
_web: {
|
|
42
55
|
'_focus-visible': {
|
package/build/core/themes.d.ts
CHANGED
|
@@ -2,6 +2,16 @@ import { DimensionValue } from 'react-native';
|
|
|
2
2
|
import { components } from '../tokens';
|
|
3
3
|
export declare const lightTheme: {
|
|
4
4
|
readonly helpers: {
|
|
5
|
+
shadow: {
|
|
6
|
+
functional: string;
|
|
7
|
+
brand: string;
|
|
8
|
+
energy: string;
|
|
9
|
+
broadband: string;
|
|
10
|
+
mobile: string;
|
|
11
|
+
insurance: string;
|
|
12
|
+
cashback: string;
|
|
13
|
+
pig: string;
|
|
14
|
+
};
|
|
5
15
|
focusVisible: {
|
|
6
16
|
outlineStyle: string;
|
|
7
17
|
outlineWidth: number;
|
|
@@ -1352,6 +1362,16 @@ export declare const lightTheme: {
|
|
|
1352
1362
|
};
|
|
1353
1363
|
export declare const darkTheme: {
|
|
1354
1364
|
readonly helpers: {
|
|
1365
|
+
shadow: {
|
|
1366
|
+
functional: string;
|
|
1367
|
+
brand: string;
|
|
1368
|
+
energy: string;
|
|
1369
|
+
broadband: string;
|
|
1370
|
+
mobile: string;
|
|
1371
|
+
insurance: string;
|
|
1372
|
+
cashback: string;
|
|
1373
|
+
pig: string;
|
|
1374
|
+
};
|
|
1355
1375
|
focusVisible: {
|
|
1356
1376
|
outlineStyle: string;
|
|
1357
1377
|
outlineWidth: number;
|
|
@@ -2714,6 +2734,16 @@ export declare const darkTheme: {
|
|
|
2714
2734
|
export declare const themes: {
|
|
2715
2735
|
readonly light: {
|
|
2716
2736
|
readonly helpers: {
|
|
2737
|
+
shadow: {
|
|
2738
|
+
functional: string;
|
|
2739
|
+
brand: string;
|
|
2740
|
+
energy: string;
|
|
2741
|
+
broadband: string;
|
|
2742
|
+
mobile: string;
|
|
2743
|
+
insurance: string;
|
|
2744
|
+
cashback: string;
|
|
2745
|
+
pig: string;
|
|
2746
|
+
};
|
|
2717
2747
|
focusVisible: {
|
|
2718
2748
|
outlineStyle: string;
|
|
2719
2749
|
outlineWidth: number;
|
|
@@ -4064,6 +4094,16 @@ export declare const themes: {
|
|
|
4064
4094
|
};
|
|
4065
4095
|
readonly dark: {
|
|
4066
4096
|
readonly helpers: {
|
|
4097
|
+
shadow: {
|
|
4098
|
+
functional: string;
|
|
4099
|
+
brand: string;
|
|
4100
|
+
energy: string;
|
|
4101
|
+
broadband: string;
|
|
4102
|
+
mobile: string;
|
|
4103
|
+
insurance: string;
|
|
4104
|
+
cashback: string;
|
|
4105
|
+
pig: string;
|
|
4106
|
+
};
|
|
4067
4107
|
focusVisible: {
|
|
4068
4108
|
outlineStyle: string;
|
|
4069
4109
|
outlineWidth: number;
|
package/build/core/themes.js
CHANGED
|
@@ -254,6 +254,16 @@ const shared = {
|
|
|
254
254
|
};
|
|
255
255
|
const lightHelpers = {
|
|
256
256
|
...shared.helpers,
|
|
257
|
+
shadow: {
|
|
258
|
+
functional: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${light.shadow.default}`,
|
|
259
|
+
brand: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${light.shadow.brand}`,
|
|
260
|
+
energy: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${light.shadow.energy}`,
|
|
261
|
+
broadband: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${light.shadow.broadband}`,
|
|
262
|
+
mobile: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${light.shadow.mobile}`,
|
|
263
|
+
insurance: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${light.shadow.insurance}`,
|
|
264
|
+
cashback: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${light.shadow.cashback}`,
|
|
265
|
+
pig: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${light.shadow.pig}`,
|
|
266
|
+
},
|
|
257
267
|
focusVisible: {
|
|
258
268
|
outlineStyle: 'solid',
|
|
259
269
|
outlineWidth: 2,
|
|
@@ -286,6 +296,16 @@ export const lightTheme = {
|
|
|
286
296
|
};
|
|
287
297
|
const darkHelpers = {
|
|
288
298
|
...shared.helpers,
|
|
299
|
+
shadow: {
|
|
300
|
+
functional: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${dark.shadow.default}`,
|
|
301
|
+
brand: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${dark.shadow.brand}`,
|
|
302
|
+
energy: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${dark.shadow.energy}`,
|
|
303
|
+
broadband: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${dark.shadow.broadband}`,
|
|
304
|
+
mobile: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${dark.shadow.mobile}`,
|
|
305
|
+
insurance: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${dark.shadow.insurance}`,
|
|
306
|
+
cashback: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${dark.shadow.cashback}`,
|
|
307
|
+
pig: `${shadow.mobile.md.x}px ${shadow.mobile.md.y}px ${shadow.mobile.md.spread}px ${dark.shadow.pig}`,
|
|
308
|
+
},
|
|
289
309
|
focusVisible: {
|
|
290
310
|
outlineStyle: 'solid',
|
|
291
311
|
outlineWidth: 2,
|
|
@@ -17,7 +17,6 @@ export { default as carouselControl } from './carousel-control';
|
|
|
17
17
|
export { default as checkbox } from './checkbox';
|
|
18
18
|
export { default as datePicker } from './date-picker';
|
|
19
19
|
export { default as descriptionList } from './description-list';
|
|
20
|
-
export { default as dialog } from './dialog';
|
|
21
20
|
export { default as divider } from './divider';
|
|
22
21
|
export { default as drawer } from './drawer';
|
|
23
22
|
export { default as expandableCard } from './expandable-card';
|
|
@@ -40,6 +39,7 @@ export { default as pill } from './pill';
|
|
|
40
39
|
export { default as progressBar } from './progress-bar';
|
|
41
40
|
export { default as progressStepper } from './progress-stepper';
|
|
42
41
|
export { default as radio } from './radio';
|
|
42
|
+
export { default as rating } from './rating';
|
|
43
43
|
export { default as sectionHeader } from './section-header';
|
|
44
44
|
export { default as segmentedControl } from './segmented-control';
|
|
45
45
|
export { default as select } from './select';
|
|
@@ -48,6 +48,8 @@ export { default as spinner } from './spinner';
|
|
|
48
48
|
export { default as switch } from './switch';
|
|
49
49
|
export { default as table } from './table';
|
|
50
50
|
export { default as tabs } from './tabs';
|
|
51
|
+
export { default as timePicker } from './time-picker';
|
|
52
|
+
export { default as timeline } from './timeline';
|
|
51
53
|
export { default as toast } from './toast';
|
|
52
54
|
export { default as toggleButton } from './toggle-button';
|
|
53
55
|
export { default as tooltip } from './tooltip';
|
|
@@ -17,7 +17,6 @@ export { default as carouselControl } from './carousel-control';
|
|
|
17
17
|
export { default as checkbox } from './checkbox';
|
|
18
18
|
export { default as datePicker } from './date-picker';
|
|
19
19
|
export { default as descriptionList } from './description-list';
|
|
20
|
-
export { default as dialog } from './dialog';
|
|
21
20
|
export { default as divider } from './divider';
|
|
22
21
|
export { default as drawer } from './drawer';
|
|
23
22
|
export { default as expandableCard } from './expandable-card';
|
|
@@ -40,6 +39,7 @@ export { default as pill } from './pill';
|
|
|
40
39
|
export { default as progressBar } from './progress-bar';
|
|
41
40
|
export { default as progressStepper } from './progress-stepper';
|
|
42
41
|
export { default as radio } from './radio';
|
|
42
|
+
export { default as rating } from './rating';
|
|
43
43
|
export { default as sectionHeader } from './section-header';
|
|
44
44
|
export { default as segmentedControl } from './segmented-control';
|
|
45
45
|
export { default as select } from './select';
|
|
@@ -48,6 +48,8 @@ export { default as spinner } from './spinner';
|
|
|
48
48
|
export { default as switch } from './switch';
|
|
49
49
|
export { default as table } from './table';
|
|
50
50
|
export { default as tabs } from './tabs';
|
|
51
|
+
export { default as timePicker } from './time-picker';
|
|
52
|
+
export { default as timeline } from './timeline';
|
|
51
53
|
export { default as toast } from './toast';
|
|
52
54
|
export { default as toggleButton } from './toggle-button';
|
|
53
55
|
export { default as tooltip } from './tooltip';
|
|
@@ -10,17 +10,20 @@ declare const _default: {
|
|
|
10
10
|
readonly gap: 12;
|
|
11
11
|
};
|
|
12
12
|
readonly gap: 24;
|
|
13
|
-
readonly
|
|
13
|
+
readonly heading: {
|
|
14
|
+
readonly gap: 24;
|
|
15
|
+
};
|
|
16
|
+
readonly illustration: {
|
|
17
|
+
readonly padding: 48;
|
|
18
|
+
};
|
|
19
|
+
readonly padding: 24;
|
|
14
20
|
readonly mobile: {
|
|
15
|
-
readonly padding: 16;
|
|
16
21
|
readonly width: 360;
|
|
17
22
|
};
|
|
18
23
|
readonly tablet: {
|
|
19
|
-
readonly padding: 48;
|
|
20
24
|
readonly width: 504;
|
|
21
25
|
};
|
|
22
26
|
readonly desktop: {
|
|
23
|
-
readonly padding: 48;
|
|
24
27
|
readonly width: 680;
|
|
25
28
|
};
|
|
26
29
|
};
|