@hero-design/rn 8.25.3 → 8.26.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.eslintrc.js +2 -1
- package/.turbo/turbo-build.log +8 -9
- package/assets/fonts/hero-icons-mobile.ttf +0 -0
- package/es/index.js +350 -198
- package/lib/assets/fonts/hero-icons-mobile.ttf +0 -0
- package/lib/index.js +350 -198
- package/package.json +6 -5
- package/src/components/FAB/ActionGroup/ActionItem.tsx +6 -1
- package/src/components/FAB/ActionGroup/StyledActionGroup.tsx +17 -3
- package/src/components/FAB/ActionGroup/StyledActionItem.tsx +1 -4
- package/src/components/FAB/ActionGroup/__tests__/__snapshots__/index.spec.tsx.snap +704 -1040
- package/src/components/FAB/ActionGroup/__tests__/index.spec.tsx +9 -15
- package/src/components/FAB/ActionGroup/index.tsx +111 -43
- package/src/components/FAB/AnimatedFABIcon.tsx +5 -3
- package/src/components/FAB/FAB.tsx +16 -3
- package/src/components/FAB/StyledFAB.tsx +10 -3
- package/src/components/FAB/__tests__/__snapshots__/AnimatedFABIcon.spec.tsx.snap +4 -4
- package/src/components/FAB/__tests__/__snapshots__/StyledFAB.spec.tsx.snap +1 -2
- package/src/components/FAB/__tests__/__snapshots__/index.spec.tsx.snap +74 -43
- package/src/components/Icon/HeroIcon/glyphMap.json +1 -1
- package/src/components/Icon/IconList.ts +1 -0
- package/src/components/Switch/SelectorSwitch/Option.tsx +31 -5
- package/src/components/Switch/SelectorSwitch/StyledSelectorSwitch.tsx +18 -4
- package/src/components/Switch/SelectorSwitch/__tests__/__snapshots__/Option.spec.tsx.snap +25 -18
- package/src/components/Switch/SelectorSwitch/__tests__/__snapshots__/index.spec.tsx.snap +49 -18
- package/src/components/Switch/SelectorSwitch/index.tsx +81 -17
- package/src/components/Switch/index.tsx +1 -0
- package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +8 -9
- package/src/theme/components/fab.ts +8 -9
- package/types/components/FAB/ActionGroup/ActionItem.d.ts +1 -0
- package/types/components/FAB/ActionGroup/StyledActionGroup.d.ts +7 -1
- package/types/components/FAB/StyledFAB.d.ts +5 -1
- package/types/components/Icon/IconList.d.ts +1 -1
- package/types/components/Icon/index.d.ts +1 -1
- package/types/components/Icon/utils.d.ts +1 -1
- package/types/components/Switch/SelectorSwitch/Option.d.ts +4 -1
- package/types/components/Switch/SelectorSwitch/StyledSelectorSwitch.d.ts +15 -9
- package/types/components/Switch/SelectorSwitch/index.d.ts +1 -1
- package/types/theme/components/fab.d.ts +5 -6
|
@@ -10,7 +10,7 @@ describe('ActionGroup', () => {
|
|
|
10
10
|
${true}
|
|
11
11
|
${false}
|
|
12
12
|
`('has active $active', ({ active }) => {
|
|
13
|
-
const { toJSON,
|
|
13
|
+
const { toJSON, queryByTestId, queryByText } = renderWithTheme(
|
|
14
14
|
<ActionGroup
|
|
15
15
|
fabTitle="Shout out"
|
|
16
16
|
active={active}
|
|
@@ -39,25 +39,19 @@ describe('ActionGroup', () => {
|
|
|
39
39
|
|
|
40
40
|
expect(toJSON()).toMatchSnapshot();
|
|
41
41
|
|
|
42
|
-
expect(
|
|
43
|
-
expect(
|
|
44
|
-
expect(
|
|
45
|
-
expect(
|
|
46
|
-
expect(
|
|
47
|
-
expect(
|
|
42
|
+
expect(queryByText('What would you like to create?')).toBeDefined();
|
|
43
|
+
expect(queryByText('Shout out')).toBeDefined();
|
|
44
|
+
expect(queryByTestId('speaker-action-item')).toBeDefined();
|
|
45
|
+
expect(queryByTestId('target-action-item')).toBeDefined();
|
|
46
|
+
expect(queryByTestId('plane-action-item')).toBeDefined();
|
|
47
|
+
expect(queryByTestId('health-bag-action-item')).toBeDefined();
|
|
48
48
|
|
|
49
49
|
if (active) {
|
|
50
50
|
// verify action group appears
|
|
51
|
-
expect(
|
|
51
|
+
expect(queryByTestId('action-group')).toHaveStyle({
|
|
52
52
|
transform: [{ translateX: 0 }],
|
|
53
53
|
});
|
|
54
|
-
expect(
|
|
55
|
-
} else {
|
|
56
|
-
// verify action group disappears
|
|
57
|
-
expect(getByTestId('action-group')).toHaveStyle({
|
|
58
|
-
transform: [{ translateX: 400 }],
|
|
59
|
-
});
|
|
60
|
-
expect(getByTestId('back-drop')).toHaveProp('pointerEvents', 'box-none');
|
|
54
|
+
expect(queryByTestId('back-drop')).toHaveProp('pointerEvents', 'auto');
|
|
61
55
|
}
|
|
62
56
|
});
|
|
63
57
|
|
|
@@ -1,16 +1,18 @@
|
|
|
1
|
-
import React, { useEffect, useRef } from 'react';
|
|
2
|
-
import { Animated, View } from 'react-native';
|
|
1
|
+
import React, { useCallback, useEffect, useRef, useState } from 'react';
|
|
3
2
|
import type { StyleProp, ViewStyle } from 'react-native';
|
|
3
|
+
import { Animated, Easing, Modal, Platform, View } from 'react-native';
|
|
4
|
+
import { useTheme } from '../../../theme';
|
|
5
|
+
import type { IconName } from '../../Icon';
|
|
6
|
+
import type { ActionItemProps } from './ActionItem';
|
|
4
7
|
import ActionItem from './ActionItem';
|
|
5
8
|
import {
|
|
9
|
+
StyledActionGroupContainer,
|
|
6
10
|
StyledBackdrop,
|
|
7
11
|
StyledContainer,
|
|
8
12
|
StyledFAB,
|
|
9
13
|
StyledHeaderText,
|
|
10
|
-
|
|
14
|
+
StyledModalView,
|
|
11
15
|
} from './StyledActionGroup';
|
|
12
|
-
import type { IconName } from '../../Icon';
|
|
13
|
-
import type { ActionItemProps } from './ActionItem';
|
|
14
16
|
|
|
15
17
|
type ActionItemsContainerProps = {
|
|
16
18
|
style?: StyleProp<ViewStyle>;
|
|
@@ -19,13 +21,18 @@ type ActionItemsContainerProps = {
|
|
|
19
21
|
const ActionItemsListComponent = ({
|
|
20
22
|
style,
|
|
21
23
|
items,
|
|
22
|
-
}: ActionItemsContainerProps) =>
|
|
23
|
-
|
|
24
|
-
{
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
24
|
+
}: ActionItemsContainerProps) => {
|
|
25
|
+
return (
|
|
26
|
+
<View style={style}>
|
|
27
|
+
{items?.map((itemProp) => (
|
|
28
|
+
<ActionItem
|
|
29
|
+
key={itemProp.key || `${itemProp.icon}_${itemProp.title}`}
|
|
30
|
+
{...itemProp}
|
|
31
|
+
/>
|
|
32
|
+
))}
|
|
33
|
+
</View>
|
|
34
|
+
);
|
|
35
|
+
};
|
|
29
36
|
|
|
30
37
|
export interface ActionGroupProps {
|
|
31
38
|
/**
|
|
@@ -69,6 +76,7 @@ export interface ActionGroupProps {
|
|
|
69
76
|
|
|
70
77
|
testID?: string;
|
|
71
78
|
}
|
|
79
|
+
|
|
72
80
|
const ActionGroup = ({
|
|
73
81
|
headerTitle,
|
|
74
82
|
onPress,
|
|
@@ -79,17 +87,48 @@ const ActionGroup = ({
|
|
|
79
87
|
fabTitle,
|
|
80
88
|
fabIcon = 'add',
|
|
81
89
|
}: ActionGroupProps) => {
|
|
90
|
+
const theme = useTheme();
|
|
91
|
+
// Internal state to control the animation of the action group
|
|
92
|
+
const [visible, setVisibility] = useState(active);
|
|
82
93
|
const tranlateXAnimation = useRef<Animated.Value>(
|
|
83
94
|
new Animated.Value(active ? 1 : 0)
|
|
84
95
|
);
|
|
96
|
+
|
|
97
|
+
useEffect(() => {
|
|
98
|
+
if (active && !visible) {
|
|
99
|
+
setVisibility(true);
|
|
100
|
+
}
|
|
101
|
+
}, [active]);
|
|
102
|
+
|
|
85
103
|
useEffect(() => {
|
|
104
|
+
if (active) {
|
|
105
|
+
const animation = Animated.timing(tranlateXAnimation.current, {
|
|
106
|
+
toValue: 1,
|
|
107
|
+
useNativeDriver: Platform.OS === 'ios' || Platform.OS === 'android',
|
|
108
|
+
easing: Easing.inOut(Easing.cubic),
|
|
109
|
+
});
|
|
110
|
+
|
|
111
|
+
animation.start();
|
|
112
|
+
}
|
|
113
|
+
}, [active]);
|
|
114
|
+
|
|
115
|
+
// Make sure the animation finishes running before closing the modal
|
|
116
|
+
const onInternalFABPress = useCallback(() => {
|
|
117
|
+
if (!onPress) {
|
|
118
|
+
return;
|
|
119
|
+
}
|
|
120
|
+
|
|
86
121
|
const animation = Animated.timing(tranlateXAnimation.current, {
|
|
87
|
-
toValue:
|
|
88
|
-
useNativeDriver:
|
|
122
|
+
toValue: 0,
|
|
123
|
+
useNativeDriver: Platform.OS === 'ios' || Platform.OS === 'android',
|
|
124
|
+
easing: Easing.inOut(Easing.cubic),
|
|
89
125
|
});
|
|
90
126
|
|
|
91
|
-
animation.start()
|
|
92
|
-
|
|
127
|
+
animation.start(() => {
|
|
128
|
+
setVisibility(false);
|
|
129
|
+
onPress();
|
|
130
|
+
});
|
|
131
|
+
}, [visible]);
|
|
93
132
|
|
|
94
133
|
const interpolatedTranlateXAnimation = tranlateXAnimation.current.interpolate(
|
|
95
134
|
{
|
|
@@ -111,34 +150,63 @@ const ActionGroup = ({
|
|
|
111
150
|
|
|
112
151
|
return (
|
|
113
152
|
<StyledContainer testID={testID} pointerEvents="box-none" style={style}>
|
|
114
|
-
<
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
<StyledActionGroupContainer
|
|
120
|
-
pointerEvents={active ? 'auto' : 'none'}
|
|
121
|
-
testID="action-group"
|
|
122
|
-
style={{
|
|
123
|
-
opacity: interpolatedActionGroupOpacityAnimation,
|
|
124
|
-
transform: [{ translateX: interpolatedTranlateXAnimation }],
|
|
125
|
-
}}
|
|
153
|
+
<Modal
|
|
154
|
+
visible={visible}
|
|
155
|
+
transparent
|
|
156
|
+
statusBarTranslucent
|
|
157
|
+
animationType="none"
|
|
126
158
|
>
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
159
|
+
<StyledBackdrop
|
|
160
|
+
style={{
|
|
161
|
+
opacity: interpolatedBackdropOpacityAnimation,
|
|
162
|
+
}}
|
|
163
|
+
testID="back-drop"
|
|
164
|
+
pointerEvents={active ? 'auto' : 'box-none'}
|
|
165
|
+
/>
|
|
166
|
+
|
|
167
|
+
<StyledModalView>
|
|
168
|
+
<StyledActionGroupContainer
|
|
169
|
+
pointerEvents={active ? 'auto' : 'none'}
|
|
170
|
+
testID="action-group"
|
|
171
|
+
style={{
|
|
172
|
+
opacity: interpolatedActionGroupOpacityAnimation,
|
|
173
|
+
transform: [{ translateX: interpolatedTranlateXAnimation }],
|
|
174
|
+
}}
|
|
175
|
+
>
|
|
176
|
+
{!!headerTitle && (
|
|
177
|
+
<StyledHeaderText testID="header-text">
|
|
178
|
+
{headerTitle}
|
|
179
|
+
</StyledHeaderText>
|
|
180
|
+
)}
|
|
181
|
+
<ActionItemsListComponent items={items} />
|
|
182
|
+
</StyledActionGroupContainer>
|
|
183
|
+
|
|
184
|
+
{active && (
|
|
185
|
+
<StyledFAB
|
|
186
|
+
testID="fab"
|
|
187
|
+
icon={fabIcon}
|
|
188
|
+
onPress={onInternalFABPress}
|
|
189
|
+
animated
|
|
190
|
+
active={active}
|
|
191
|
+
title={fabTitle}
|
|
192
|
+
style={{
|
|
193
|
+
marginBottom: theme.__hd__.fab.space.internalFABMarginBottom,
|
|
194
|
+
}}
|
|
195
|
+
/>
|
|
196
|
+
)}
|
|
197
|
+
</StyledModalView>
|
|
198
|
+
</Modal>
|
|
199
|
+
|
|
200
|
+
{!active && (
|
|
201
|
+
<StyledFAB
|
|
202
|
+
testID="fab"
|
|
203
|
+
icon={fabIcon}
|
|
204
|
+
onPress={onPress}
|
|
205
|
+
animated
|
|
206
|
+
active={active}
|
|
207
|
+
title={fabTitle}
|
|
208
|
+
/>
|
|
209
|
+
)}
|
|
142
210
|
</StyledContainer>
|
|
143
211
|
);
|
|
144
212
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import React, { useEffect, useRef } from 'react';
|
|
2
|
-
import { Animated, StyleSheet } from 'react-native';
|
|
2
|
+
import { Animated, Easing, Platform, StyleSheet } from 'react-native';
|
|
3
3
|
import { StyledFABIcon } from './StyledFAB';
|
|
4
4
|
import type { IconProps } from '../Icon';
|
|
5
5
|
|
|
@@ -16,7 +16,9 @@ const AnimatedFABIcon = ({ active, ...iconProps }: Props) => {
|
|
|
16
16
|
useEffect(() => {
|
|
17
17
|
const animation = Animated.timing(rotateAnimation.current, {
|
|
18
18
|
toValue: active ? 1 : 0,
|
|
19
|
-
useNativeDriver:
|
|
19
|
+
useNativeDriver: Platform.OS === 'ios' || Platform.OS === 'android',
|
|
20
|
+
easing: Easing.inOut(Easing.ease),
|
|
21
|
+
duration: 300,
|
|
20
22
|
});
|
|
21
23
|
|
|
22
24
|
animation.start();
|
|
@@ -39,7 +41,7 @@ const AnimatedFABIcon = ({ active, ...iconProps }: Props) => {
|
|
|
39
41
|
},
|
|
40
42
|
])}
|
|
41
43
|
>
|
|
42
|
-
<AnimatedIcons {...iconProps} />
|
|
44
|
+
<AnimatedIcons size="xsmall" {...iconProps} />
|
|
43
45
|
</Animated.View>
|
|
44
46
|
);
|
|
45
47
|
};
|
|
@@ -3,7 +3,12 @@ import type { StyleProp, ViewStyle } from 'react-native';
|
|
|
3
3
|
import { useTheme } from '../../theme';
|
|
4
4
|
import type { IconName } from '../Icon';
|
|
5
5
|
import { AnimatedFABIcon } from './AnimatedFABIcon';
|
|
6
|
-
import {
|
|
6
|
+
import {
|
|
7
|
+
StyledFAB,
|
|
8
|
+
StyledFABIcon,
|
|
9
|
+
StyledFABText,
|
|
10
|
+
StyledIconContainer,
|
|
11
|
+
} from './StyledFAB';
|
|
7
12
|
|
|
8
13
|
export interface FABProps {
|
|
9
14
|
/**
|
|
@@ -54,7 +59,13 @@ const IconOnlyContent = ({
|
|
|
54
59
|
}) => {
|
|
55
60
|
if (animated) {
|
|
56
61
|
return (
|
|
57
|
-
<
|
|
62
|
+
<StyledIconContainer>
|
|
63
|
+
<AnimatedFABIcon
|
|
64
|
+
active={active}
|
|
65
|
+
icon={icon}
|
|
66
|
+
testID="animated-fab-icon"
|
|
67
|
+
/>
|
|
68
|
+
</StyledIconContainer>
|
|
58
69
|
);
|
|
59
70
|
}
|
|
60
71
|
return <StyledFABIcon icon={icon} testID="styled-fab-icon" />;
|
|
@@ -68,7 +79,9 @@ const IconWithTextContent = ({
|
|
|
68
79
|
title?: string;
|
|
69
80
|
}) => (
|
|
70
81
|
<>
|
|
71
|
-
<
|
|
82
|
+
<StyledIconContainer>
|
|
83
|
+
<StyledFABIcon size="xsmall" icon={icon} testID="styled-fab-icon" />
|
|
84
|
+
</StyledIconContainer>
|
|
72
85
|
<StyledFABText>{title}</StyledFABText>
|
|
73
86
|
</>
|
|
74
87
|
);
|
|
@@ -4,6 +4,7 @@ import { TouchableHighlight } from 'react-native';
|
|
|
4
4
|
import type { IconProps } from '../Icon';
|
|
5
5
|
import Icon from '../Icon';
|
|
6
6
|
import Typography from '../Typography';
|
|
7
|
+
import Box from '../Box';
|
|
7
8
|
|
|
8
9
|
const StyledFAB = styled(TouchableHighlight)<TouchableHighlightProps>(
|
|
9
10
|
({ theme }) => ({
|
|
@@ -12,8 +13,7 @@ const StyledFAB = styled(TouchableHighlight)<TouchableHighlightProps>(
|
|
|
12
13
|
alignItems: 'center',
|
|
13
14
|
justifyContent: 'center',
|
|
14
15
|
alignSelf: 'flex-start',
|
|
15
|
-
|
|
16
|
-
paddingVertical: theme.__hd__.fab.space.containerPaddingVertical,
|
|
16
|
+
padding: theme.__hd__.fab.space.containerPadding,
|
|
17
17
|
flexDirection: 'row',
|
|
18
18
|
elevation: theme.__hd__.fab.shadows.elevation,
|
|
19
19
|
shadowColor: theme.__hd__.fab.colors.shadow,
|
|
@@ -40,4 +40,11 @@ const StyledFABText = styled(Typography.Text)<TextProps>(({ theme }) => ({
|
|
|
40
40
|
marginHorizontal: theme.__hd__.fab.space.titleMarginHorizontal,
|
|
41
41
|
}));
|
|
42
42
|
|
|
43
|
-
|
|
43
|
+
const StyledIconContainer = styled(Box)(({ theme }) => ({
|
|
44
|
+
width: theme.__hd__.fab.sizes.iconContainerWidth,
|
|
45
|
+
height: theme.__hd__.fab.sizes.iconContainerHeight,
|
|
46
|
+
justifyContent: 'center',
|
|
47
|
+
alignItems: 'center',
|
|
48
|
+
}));
|
|
49
|
+
|
|
50
|
+
export { StyledFAB, StyledFABIcon, StyledFABText, StyledIconContainer };
|
|
@@ -19,7 +19,7 @@ exports[`AnimatedFABIcon renders correctly when isActive is false 1`] = `
|
|
|
19
19
|
Array [
|
|
20
20
|
Object {
|
|
21
21
|
"color": "#001f23",
|
|
22
|
-
"fontSize":
|
|
22
|
+
"fontSize": 16,
|
|
23
23
|
},
|
|
24
24
|
Array [
|
|
25
25
|
Object {
|
|
@@ -33,7 +33,7 @@ exports[`AnimatedFABIcon renders correctly when isActive is false 1`] = `
|
|
|
33
33
|
]
|
|
34
34
|
}
|
|
35
35
|
themeIntent="text"
|
|
36
|
-
themeSize="
|
|
36
|
+
themeSize="xsmall"
|
|
37
37
|
/>
|
|
38
38
|
</View>
|
|
39
39
|
`;
|
|
@@ -57,7 +57,7 @@ exports[`AnimatedFABIcon renders correctly when isActive is true 1`] = `
|
|
|
57
57
|
Array [
|
|
58
58
|
Object {
|
|
59
59
|
"color": "#001f23",
|
|
60
|
-
"fontSize":
|
|
60
|
+
"fontSize": 16,
|
|
61
61
|
},
|
|
62
62
|
Array [
|
|
63
63
|
Object {
|
|
@@ -71,7 +71,7 @@ exports[`AnimatedFABIcon renders correctly when isActive is true 1`] = `
|
|
|
71
71
|
]
|
|
72
72
|
}
|
|
73
73
|
themeIntent="text"
|
|
74
|
-
themeSize="
|
|
74
|
+
themeSize="xsmall"
|
|
75
75
|
/>
|
|
76
76
|
</View>
|
|
77
77
|
`;
|
|
@@ -21,8 +21,7 @@ exports[`StyledFAB renders correctly 1`] = `
|
|
|
21
21
|
"elevation": 2,
|
|
22
22
|
"flexDirection": "row",
|
|
23
23
|
"justifyContent": "center",
|
|
24
|
-
"
|
|
25
|
-
"paddingVertical": 16,
|
|
24
|
+
"padding": 20,
|
|
26
25
|
"shadowColor": "#001f23",
|
|
27
26
|
"shadowOffset": Object {
|
|
28
27
|
"height": 2,
|
|
@@ -21,8 +21,7 @@ exports[`FAB when animated is false renders StyledFABIcon 1`] = `
|
|
|
21
21
|
"elevation": 2,
|
|
22
22
|
"flexDirection": "row",
|
|
23
23
|
"justifyContent": "center",
|
|
24
|
-
"
|
|
25
|
-
"paddingVertical": 16,
|
|
24
|
+
"padding": 20,
|
|
26
25
|
"shadowColor": "#001f23",
|
|
27
26
|
"shadowOffset": Object {
|
|
28
27
|
"height": 2,
|
|
@@ -84,8 +83,7 @@ exports[`FAB when animated is true renders animatedFABIcon 1`] = `
|
|
|
84
83
|
"elevation": 2,
|
|
85
84
|
"flexDirection": "row",
|
|
86
85
|
"justifyContent": "center",
|
|
87
|
-
"
|
|
88
|
-
"paddingVertical": 16,
|
|
86
|
+
"padding": 20,
|
|
89
87
|
"shadowColor": "#001f23",
|
|
90
88
|
"shadowOffset": Object {
|
|
91
89
|
"height": 2,
|
|
@@ -101,40 +99,57 @@ exports[`FAB when animated is true renders animatedFABIcon 1`] = `
|
|
|
101
99
|
}
|
|
102
100
|
>
|
|
103
101
|
<View
|
|
104
|
-
collapsable={false}
|
|
105
102
|
style={
|
|
106
|
-
|
|
107
|
-
|
|
103
|
+
Array [
|
|
104
|
+
Object {},
|
|
105
|
+
Array [
|
|
108
106
|
Object {
|
|
109
|
-
"
|
|
107
|
+
"alignItems": "center",
|
|
108
|
+
"height": 24,
|
|
109
|
+
"justifyContent": "center",
|
|
110
|
+
"width": 24,
|
|
110
111
|
},
|
|
112
|
+
undefined,
|
|
111
113
|
],
|
|
112
|
-
|
|
114
|
+
]
|
|
113
115
|
}
|
|
114
116
|
>
|
|
115
|
-
<
|
|
116
|
-
|
|
117
|
+
<View
|
|
118
|
+
collapsable={false}
|
|
117
119
|
style={
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
"color": "#001f23",
|
|
121
|
-
"fontSize": 24,
|
|
122
|
-
},
|
|
123
|
-
Array [
|
|
120
|
+
Object {
|
|
121
|
+
"transform": Array [
|
|
124
122
|
Object {
|
|
125
|
-
"
|
|
126
|
-
"lineHeight": 24,
|
|
127
|
-
"textAlign": "center",
|
|
128
|
-
"textAlignVertical": "center",
|
|
123
|
+
"rotate": "0deg",
|
|
129
124
|
},
|
|
130
|
-
Object {},
|
|
131
125
|
],
|
|
132
|
-
|
|
126
|
+
}
|
|
133
127
|
}
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
128
|
+
>
|
|
129
|
+
<HeroIcon
|
|
130
|
+
name="add"
|
|
131
|
+
style={
|
|
132
|
+
Array [
|
|
133
|
+
Object {
|
|
134
|
+
"color": "#001f23",
|
|
135
|
+
"fontSize": 16,
|
|
136
|
+
},
|
|
137
|
+
Array [
|
|
138
|
+
Object {
|
|
139
|
+
"color": "#ffffff",
|
|
140
|
+
"lineHeight": 24,
|
|
141
|
+
"textAlign": "center",
|
|
142
|
+
"textAlignVertical": "center",
|
|
143
|
+
},
|
|
144
|
+
Object {},
|
|
145
|
+
],
|
|
146
|
+
]
|
|
147
|
+
}
|
|
148
|
+
testID="animated-fab-icon"
|
|
149
|
+
themeIntent="text"
|
|
150
|
+
themeSize="xsmall"
|
|
151
|
+
/>
|
|
152
|
+
</View>
|
|
138
153
|
</View>
|
|
139
154
|
</View>
|
|
140
155
|
`;
|
|
@@ -160,8 +175,7 @@ exports[`FAB when title has value renders correctly 1`] = `
|
|
|
160
175
|
"elevation": 2,
|
|
161
176
|
"flexDirection": "row",
|
|
162
177
|
"justifyContent": "center",
|
|
163
|
-
"
|
|
164
|
-
"paddingVertical": 16,
|
|
178
|
+
"padding": 20,
|
|
165
179
|
"shadowColor": "#001f23",
|
|
166
180
|
"shadowOffset": Object {
|
|
167
181
|
"height": 2,
|
|
@@ -176,29 +190,46 @@ exports[`FAB when title has value renders correctly 1`] = `
|
|
|
176
190
|
]
|
|
177
191
|
}
|
|
178
192
|
>
|
|
179
|
-
<
|
|
180
|
-
name="pencil"
|
|
193
|
+
<View
|
|
181
194
|
style={
|
|
182
195
|
Array [
|
|
183
|
-
Object {
|
|
184
|
-
"color": "#001f23",
|
|
185
|
-
"fontSize": 16,
|
|
186
|
-
},
|
|
196
|
+
Object {},
|
|
187
197
|
Array [
|
|
188
198
|
Object {
|
|
189
|
-
"
|
|
190
|
-
"
|
|
191
|
-
"
|
|
192
|
-
"
|
|
199
|
+
"alignItems": "center",
|
|
200
|
+
"height": 24,
|
|
201
|
+
"justifyContent": "center",
|
|
202
|
+
"width": 24,
|
|
193
203
|
},
|
|
194
204
|
undefined,
|
|
195
205
|
],
|
|
196
206
|
]
|
|
197
207
|
}
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
208
|
+
>
|
|
209
|
+
<HeroIcon
|
|
210
|
+
name="pencil"
|
|
211
|
+
style={
|
|
212
|
+
Array [
|
|
213
|
+
Object {
|
|
214
|
+
"color": "#001f23",
|
|
215
|
+
"fontSize": 16,
|
|
216
|
+
},
|
|
217
|
+
Array [
|
|
218
|
+
Object {
|
|
219
|
+
"color": "#ffffff",
|
|
220
|
+
"lineHeight": 24,
|
|
221
|
+
"textAlign": "center",
|
|
222
|
+
"textAlignVertical": "center",
|
|
223
|
+
},
|
|
224
|
+
undefined,
|
|
225
|
+
],
|
|
226
|
+
]
|
|
227
|
+
}
|
|
228
|
+
testID="styled-fab-icon"
|
|
229
|
+
themeIntent="text"
|
|
230
|
+
themeSize="xsmall"
|
|
231
|
+
/>
|
|
232
|
+
</View>
|
|
202
233
|
<Text
|
|
203
234
|
allowFontScaling={false}
|
|
204
235
|
style={
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"activate":59000,"add-emoji":59001,"add-person":59002,"adjustment":59003,"alignment":59004,"antenna":59005,"archive":59006,"assignment-warning":59007,"bank":59008,"bell":59009,"billing":59010,"bolt":59011,"bookmark-added":59012,"bookmark":59013,"box-check":59014,"box":59015,"bpay":59016,"buildings":59017,"cake":59018,"calendar-clock":59019,"calendar":59020,"candy-box-menu":59021,"caret-down-small":59022,"caret-down":59023,"caret-left-small":59024,"caret-left":59025,"caret-right-small":59026,"caret-right":59027,"caret-up-small":59028,"caret-up":59029,"check-radio":59030,"circle-add":59031,"circle-cancel":59032,"circle-check":59033,"circle-down":59034,"circle-info":59035,"circle-left":59036,"circle-ok":59037,"circle-pencil":59038,"circle-question":59039,"circle-remove":59040,"circle-right":59041,"circle-up":59042,"circle-warning":59043,"clock-3":59044,"clock":59045,"cloud-download":59046,"cloud-upload":59047,"cog":59048,"coin":59049,"contacts":59050,"credit-card":59051,"diamond":59052,"direction-arrows":59053,"directory":59054,"document":59055,"dollar-coin-shine":59056,"double-buildings":59057,"edit-template":59058,"envelope":59059,"exclude":59060,"expense":59061,"eye-circle":59062,"eye-invisible":59063,"eye":59064,"face-meh":59065,"face-sad":59066,"face-smiley":59067,"feed":59068,"feedbacks":59069,"file-certified":59070,"file-clone":59071,"file-copy":59072,"file-csv":59073,"file-dispose":59074,"file-doc":59075,"file-excel":59076,"file-export":59077,"file-lock":59078,"file-pdf":59079,"file-powerpoint":59080,"file-search":59081,"file-secured":59082,"file-sheets":59083,"file-slide":59084,"file-verified":59085,"file-word":59086,"file":59087,"filter":59088,"folder-user":59089,"folder":59090,"format-bold":59091,"format-heading1":59092,"format-heading2":59093,"format-italic":59094,"format-list-bulleted":59095,"format-list-numbered":59096,"format-underlined":59097,"funnel-filter":59098,"global-dollar":59099,"globe":59100,"graduation-cap":59101,"graph":59102,"happy-sun":59103,"health-bag":59104,"heart":59105,"home":59106,"image":59107,"import":59108,"incident-siren":59109,"instapay":59110,"list":59111,"loading-2":59112,"loading":59113,"location":59114,"lock":59115,"looks-one":59116,"looks-two":59117,"media-content":59118,"menu":59119,"money-notes":59120,"moneybag":59121,"moon":59122,"multiple-stars":59123,"multiple-users":59124,"node":59125,"open-folder":59126,"paperclip":59127,"payment-summary":59128,"pencil":59129,"phone":59130,"piggy-bank":59131,"plane-up":59132,"plane":59133,"play-circle":59134,"print":59135,"raising-hands":59136,"reply-arrow":59137,"reply":59138,"reschedule":59139,"rostering":59140,"save":59141,"schedule-send":59142,"schedule":59143,"search-person":59144,"send":59145,"speaker-active":59146,"speaker":59147,"star-award":59148,"star-badge":59149,"star-circle":59150,"star-medal":59151,"star":59152,"steps-circle":59153,"stopwatch":59154,"suitcase":59155,"surfing":59156,"survey":59157,"swag-pillar-benefit":59158,"swag-pillar-career":59159,"swag-pillar-money":59160,"swag-pillar-work":59161,"swag":59162,"switch":59163,"tag":59164,"target":59165,"teams":59166,"timesheet":59167,"touch-id":59168,"trash-bin":59169,"unlock":59170,"user":59171,"video-1":59172,"video-2":59173,"wallet":59174,"warning":59175,"activate-outlined":59176,"add-credit-card-outlined":59177,"add-person-outlined":59178,"add-section-outlined":59179,"add-time-outlined":59180,"add":59181,"adjustment-outlined":59182,"alignment-2-outlined":59183,"alignment-outlined":59184,"all-caps":59185,"arrow-down":59186,"arrow-downwards":59187,"arrow-left":59188,"arrow-leftwards":59189,"arrow-right":59190,"arrow-rightwards":59191,"arrow-up":59192,"arrow-upwards":59193,"article-outlined":59194,"at-sign":59195,"auto-graph-outlined":59196,"beer-outlined":59197,"bell-active-outlined":59198,"bell-outlined":59199,"bell-slash-outlined":59200,"billing-outlined":59201,"body-outlined":59202,"bold":59203,"book-outlined":59204,"bookmark-added-outlined":59205,"bookmark-outlined":59206,"box-check-outlined":59207,"box-outlined":59208,"bullet-points":59209,"cake-outlined":59210,"calendar-dates-outlined":59211,"calendar-star-outlined":59212,"call-split-outlined":59213,"camera-outlined":59214,"cancel":59215,"car-forward-outlined":59216,"charging-station-outlined":59217,"chat-bubble-outlined":59218,"chat-unread-outlined":59219,"checkmark":59220,"circle-add-outlined":59221,"circle-cancel-outlined":59222,"circle-down-outlined":59223,"circle-info-outlined":59224,"circle-left-outlined":59225,"circle-ok-outlined":59226,"circle-question-outlined":59227,"circle-remove-outlined":59228,"circle-right-outlined":59229,"circle-up-outlined":59230,"circle-warning-outlined":59231,"clock-2-outlined":59232,"clock-outlined":59233,"cog-outlined":59234,"coin-outlined":59235,"coin-super-outlined":59236,"comment-outlined":59237,"contacts-outlined":59238,"contacts-user-outlined":59239,"credit-card-outlined":59240,"cup-outlined":59241,"dentistry-outlined":59242,"direction-arrows-outlined":59243,"directory-outlined":59244,"document-outlined":59245,"dollar-box-outlined":59246,"dollar-card-outlined":59247,"dollar-coin-shine-outlined":59248,"dollar-credit-card-outlined":59249,"dollar-sign":59250,"double-buildings-outlined":59251,"double-left-arrows":59252,"double-right-arrows":59253,"download-outlined":59254,"edit-template-outlined":
|
|
1
|
+
{"activate":59000,"add-emoji":59001,"add-person":59002,"adjustment":59003,"alignment":59004,"antenna":59005,"archive":59006,"assignment-warning":59007,"bank":59008,"bell":59009,"billing":59010,"bolt":59011,"bookmark-added":59012,"bookmark":59013,"box-check":59014,"box":59015,"bpay":59016,"buildings":59017,"cake":59018,"calendar-clock":59019,"calendar":59020,"candy-box-menu":59021,"caret-down-small":59022,"caret-down":59023,"caret-left-small":59024,"caret-left":59025,"caret-right-small":59026,"caret-right":59027,"caret-up-small":59028,"caret-up":59029,"check-radio":59030,"circle-add":59031,"circle-cancel":59032,"circle-check":59033,"circle-down":59034,"circle-info":59035,"circle-left":59036,"circle-ok":59037,"circle-pencil":59038,"circle-question":59039,"circle-remove":59040,"circle-right":59041,"circle-up":59042,"circle-warning":59043,"clock-3":59044,"clock":59045,"cloud-download":59046,"cloud-upload":59047,"cog":59048,"coin":59049,"contacts":59050,"credit-card":59051,"diamond":59052,"direction-arrows":59053,"directory":59054,"document":59055,"dollar-coin-shine":59056,"double-buildings":59057,"edit-template":59058,"envelope":59059,"exclude":59060,"expense":59061,"eye-circle":59062,"eye-invisible":59063,"eye":59064,"face-meh":59065,"face-sad":59066,"face-smiley":59067,"feed":59068,"feedbacks":59069,"file-certified":59070,"file-clone":59071,"file-copy":59072,"file-csv":59073,"file-dispose":59074,"file-doc":59075,"file-excel":59076,"file-export":59077,"file-lock":59078,"file-pdf":59079,"file-powerpoint":59080,"file-search":59081,"file-secured":59082,"file-sheets":59083,"file-slide":59084,"file-verified":59085,"file-word":59086,"file":59087,"filter":59088,"folder-user":59089,"folder":59090,"format-bold":59091,"format-heading1":59092,"format-heading2":59093,"format-italic":59094,"format-list-bulleted":59095,"format-list-numbered":59096,"format-underlined":59097,"funnel-filter":59098,"global-dollar":59099,"globe":59100,"graduation-cap":59101,"graph":59102,"happy-sun":59103,"health-bag":59104,"heart":59105,"home":59106,"image":59107,"import":59108,"incident-siren":59109,"instapay":59110,"list":59111,"loading-2":59112,"loading":59113,"location":59114,"lock":59115,"looks-one":59116,"looks-two":59117,"media-content":59118,"menu":59119,"money-notes":59120,"moneybag":59121,"moon":59122,"multiple-stars":59123,"multiple-users":59124,"node":59125,"open-folder":59126,"paperclip":59127,"payment-summary":59128,"pencil":59129,"phone":59130,"piggy-bank":59131,"plane-up":59132,"plane":59133,"play-circle":59134,"print":59135,"raising-hands":59136,"reply-arrow":59137,"reply":59138,"reschedule":59139,"rostering":59140,"save":59141,"schedule-send":59142,"schedule":59143,"search-person":59144,"send":59145,"speaker-active":59146,"speaker":59147,"star-award":59148,"star-badge":59149,"star-circle":59150,"star-medal":59151,"star":59152,"steps-circle":59153,"stopwatch":59154,"suitcase":59155,"surfing":59156,"survey":59157,"swag-pillar-benefit":59158,"swag-pillar-career":59159,"swag-pillar-money":59160,"swag-pillar-work":59161,"swag":59162,"switch":59163,"tag":59164,"target":59165,"teams":59166,"timesheet":59167,"touch-id":59168,"trash-bin":59169,"unlock":59170,"user":59171,"video-1":59172,"video-2":59173,"wallet":59174,"warning":59175,"activate-outlined":59176,"add-credit-card-outlined":59177,"add-person-outlined":59178,"add-section-outlined":59179,"add-time-outlined":59180,"add":59181,"adjustment-outlined":59182,"alignment-2-outlined":59183,"alignment-outlined":59184,"all-caps":59185,"arrow-down":59186,"arrow-downwards":59187,"arrow-left":59188,"arrow-leftwards":59189,"arrow-right":59190,"arrow-rightwards":59191,"arrow-up":59192,"arrow-upwards":59193,"article-outlined":59194,"at-sign":59195,"auto-graph-outlined":59196,"beer-outlined":59197,"bell-active-outlined":59198,"bell-outlined":59199,"bell-slash-outlined":59200,"billing-outlined":59201,"body-outlined":59202,"bold":59203,"book-outlined":59204,"bookmark-added-outlined":59205,"bookmark-outlined":59206,"box-check-outlined":59207,"box-outlined":59208,"bullet-points":59209,"cake-outlined":59210,"calendar-dates-outlined":59211,"calendar-star-outlined":59212,"call-split-outlined":59213,"camera-outlined":59214,"cancel":59215,"car-forward-outlined":59216,"charging-station-outlined":59217,"chat-bubble-outlined":59218,"chat-unread-outlined":59219,"checkmark":59220,"circle-add-outlined":59221,"circle-cancel-outlined":59222,"circle-down-outlined":59223,"circle-info-outlined":59224,"circle-left-outlined":59225,"circle-ok-outlined":59226,"circle-question-outlined":59227,"circle-remove-outlined":59228,"circle-right-outlined":59229,"circle-up-outlined":59230,"circle-warning-outlined":59231,"clock-2-outlined":59232,"clock-outlined":59233,"cog-outlined":59234,"coin-outlined":59235,"coin-super-outlined":59236,"comment-outlined":59237,"contacts-outlined":59238,"contacts-user-outlined":59239,"credit-card-outlined":59240,"cup-outlined":59241,"dentistry-outlined":59242,"direction-arrows-outlined":59243,"directory-outlined":59244,"document-outlined":59245,"dollar-box-outlined":59246,"dollar-card-outlined":59247,"dollar-coin-shine-outlined":59248,"dollar-credit-card-outlined":59249,"dollar-sign":59250,"double-buildings-outlined":59251,"double-left-arrows":59252,"double-right-arrows":59253,"download-box-outlined":59254,"download-outlined":59255,"edit-template-outlined":59256,"email-outlined":59257,"enter-arrow":59258,"envelope-outlined":59259,"expense-outlined":59260,"explore-outlined":59261,"external-link":59262,"eye-invisible-outlined":59263,"eye-outlined":59264,"face-id":59265,"face-meh-outlined":59266,"face-open-smiley-outlined":59267,"face-sad-outlined":59268,"face-smiley-outlined":59269,"fastfood-outlined":59270,"feed-outlined":59271,"file-certified-outlined":59272,"file-clone-outlined":59273,"file-copy-outlined":59274,"file-dispose-outlined":59275,"file-dollar-certified-outlined":59276,"file-dollar-outlined":59277,"file-download-outlined":59278,"file-export-outlined":59279,"file-lock-outlined":59280,"file-outlined":59281,"file-search-outlined":59282,"file-secured-outlined":59283,"file-statutory-outlined":59284,"file-verified-outlined":59285,"filter-outlined":59286,"folder-outlined":59287,"folder-user-outlined":59288,"form-outlined":59289,"funnel-filter-outline":59290,"graph-outlined":59291,"hand-holding-user-outlined":59292,"happy-sun-outlined":59293,"health-bag-outlined":59294,"heart-outlined":59295,"home-active-outlined":59296,"home-outlined":59297,"id-card-outlined":59298,"image-outlined":59299,"import-outlined":59300,"instapay-outlined":59301,"italic":59302,"link-1":59303,"link-2":59304,"list-outlined":59305,"live-help-outlined":59306,"location-on-outlined":59307,"location-outlined":59308,"lock-outlined":59309,"locked-file-outlined":59310,"log-out":59311,"media-content-outlined":59312,"menu-close":59313,"menu-expand":59314,"menu-fold-outlined":59315,"menu-unfold-outlined":59316,"moneybag-outlined":59317,"moon-outlined":59318,"more-horizontal":59319,"more-vertical":59320,"multiple-folders-outlined":59321,"multiple-users-outlined":59322,"near-me-outlined":59323,"node-outlined":59324,"number-points":59325,"number":59326,"overview-outlined":59327,"payment-summary-outlined":59328,"payslip-outlined":59329,"pencil-outlined":59330,"percentage":59331,"phone-outlined":59332,"piggy-bank-outlined":59333,"plane-outlined":59334,"play-circle-outlined":59335,"print-outlined":59336,"qr-code-outlined":59337,"qualification-outlined":59338,"re-assign":59339,"redeem":59340,"refresh":59341,"remove":59342,"reply-outlined":59343,"restart":59344,"return-arrow":59345,"rostering-outlined":59346,"save-outlined":59347,"schedule-outlined":59348,"search-outlined":59349,"search-secured-outlined":59350,"send-outlined":59351,"share-1":59352,"share-2":59353,"share-outlined":59354,"show-chart-outlined":59355,"single-down-arrow":59356,"single-left-arrow":59357,"single-right-arrow":59358,"single-up-arrow":59359,"speaker-active-outlined":59360,"speaker-outlined":59361,"star-circle-outlined":59362,"star-outlined":59363,"stopwatch-outlined":59364,"strikethrough":59365,"styler-outlined":59366,"suitcase-clock-outlined":59367,"suitcase-outlined":59368,"survey-outlined":59369,"switch-outlined":59370,"sync":59371,"tag-outlined":59372,"target-outlined":59373,"tennis-outlined":59374,"ticket-outlined":59375,"timesheet-outlined":59376,"today-outlined":59377,"transfer":59378,"trash-bin-outlined":59379,"umbrela-outlined":59380,"unavailable":59381,"underline":59382,"union-outlined":59383,"unlock-outlined":59384,"upload-outlined":59385,"user-circle-outlined":59386,"user-gear-outlined":59387,"user-outlined":59388,"user-rectangle-outlined":59389,"video-1-outlined":59390,"video-2-outlined":59391,"volunteer-outlined":59392,"wallet-outlined":59393}
|