@hero-design/rn 7.19.0 → 7.20.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.
Files changed (171) hide show
  1. package/.eslintrc.json +6 -1
  2. package/.turbo/turbo-build.log +2 -2
  3. package/es/index.js +572 -194
  4. package/lib/index.js +572 -193
  5. package/package.json +4 -4
  6. package/src/components/Alert/StyledAlert.tsx +5 -5
  7. package/src/components/Alert/__tests__/__snapshots__/index.spec.tsx.snap +140 -19
  8. package/src/components/Alert/__tests__/index.spec.tsx +21 -0
  9. package/src/components/Alert/index.tsx +13 -6
  10. package/src/components/Avatar/StyledAvatar.tsx +2 -1
  11. package/src/components/Avatar/index.tsx +2 -1
  12. package/src/components/Box/StyledBox.tsx +54 -0
  13. package/src/components/Box/__tests__/__snapshots__/index.spec.tsx.snap +605 -0
  14. package/src/components/Box/__tests__/helpers.spec.ts +14 -0
  15. package/src/components/Box/__tests__/index.spec.tsx +155 -0
  16. package/src/components/Box/config.ts +201 -0
  17. package/src/components/Box/helpers.ts +10 -0
  18. package/src/components/Box/index.tsx +13 -0
  19. package/src/components/Box/types.ts +38 -0
  20. package/src/components/Calendar/__tests__/index.spec.tsx +13 -17
  21. package/src/components/Card/DataCard/StyledDataCard.tsx +8 -2
  22. package/src/components/Card/DataCard/__tests__/StyledDataCard.spec.tsx +1 -0
  23. package/src/components/Card/DataCard/__tests__/__snapshots__/StyledDataCard.spec.tsx.snap +16 -0
  24. package/src/components/Card/DataCard/index.tsx +1 -1
  25. package/src/components/Card/StyledCard.tsx +12 -19
  26. package/src/components/Card/__tests__/__snapshots__/index.spec.tsx.snap +147 -0
  27. package/src/components/Card/__tests__/index.spec.tsx +18 -0
  28. package/src/components/Card/index.tsx +6 -1
  29. package/src/components/Drawer/DragableDrawer/helpers.ts +3 -4
  30. package/src/components/FAB/ActionGroup/index.tsx +6 -8
  31. package/src/components/RichTextEditor/__tests__/RichTextEditor.spec.tsx +4 -8
  32. package/src/components/SectionHeading/__tests__/__snapshots__/StyledHeading.spec.tsx.snap +1 -1
  33. package/src/components/SectionHeading/__tests__/__snapshots__/index.spec.tsx.snap +4 -4
  34. package/src/components/Select/MultiSelect/__tests__/__snapshots__/OptionList.spec.tsx.snap +22 -20
  35. package/src/components/Select/MultiSelect/__tests__/__snapshots__/index.spec.tsx.snap +4 -4
  36. package/src/components/Select/SingleSelect/__tests__/__snapshots__/OptionList.spec.tsx.snap +22 -20
  37. package/src/components/Select/SingleSelect/__tests__/__snapshots__/index.spec.tsx.snap +4 -4
  38. package/src/components/Spinner/AnimatedSpinner.tsx +7 -7
  39. package/src/components/Spinner/StyledSpinner.tsx +24 -19
  40. package/src/components/Spinner/__tests__/AnimatedSpinner.spec.tsx +1 -1
  41. package/src/components/Spinner/__tests__/StyledSpinner.spec.tsx +32 -16
  42. package/src/components/Spinner/__tests__/__snapshots__/AnimatedSpinner.spec.tsx.snap +14 -12
  43. package/src/components/Spinner/__tests__/__snapshots__/StyledSpinner.spec.tsx.snap +273 -31
  44. package/src/components/Spinner/__tests__/__snapshots__/index.spec.tsx.snap +14 -12
  45. package/src/components/Spinner/index.tsx +10 -2
  46. package/src/components/Tabs/ScrollableTabs.tsx +9 -4
  47. package/src/components/Tabs/StyledScrollableTabs.tsx +6 -5
  48. package/src/components/Tabs/StyledTabs.tsx +6 -0
  49. package/src/components/Tabs/TabWithBadge.tsx +68 -0
  50. package/src/components/Tabs/__tests__/ScrollableTabs.spec.tsx +13 -0
  51. package/src/components/Tabs/__tests__/TabWithBadge.spec.tsx +48 -0
  52. package/src/components/Tabs/__tests__/__snapshots__/ScrollableTabs.spec.tsx.snap +205 -43
  53. package/src/components/Tabs/__tests__/__snapshots__/TabWithBadge.spec.tsx.snap +165 -0
  54. package/src/components/Tabs/__tests__/__snapshots__/index.spec.tsx.snap +135 -34
  55. package/src/components/Tabs/__tests__/index.spec.tsx +12 -0
  56. package/src/components/Tabs/index.tsx +11 -4
  57. package/src/components/Tag/StyledTag.tsx +1 -11
  58. package/src/components/Tag/__tests__/__snapshots__/Tag.spec.tsx.snap +4 -4
  59. package/src/components/Tag/index.tsx +2 -2
  60. package/src/components/TextInput/__tests__/index.spec.tsx +10 -14
  61. package/src/components/Toast/StyledToast.tsx +13 -7
  62. package/src/components/Toast/Toast.tsx +34 -9
  63. package/src/components/Toast/ToastProvider.tsx +15 -12
  64. package/src/components/Toast/__tests__/Toast.spec.tsx +17 -0
  65. package/src/components/Toast/__tests__/__snapshots__/Toast.spec.tsx.snap +299 -19
  66. package/src/components/Toast/types.ts +15 -1
  67. package/src/components/Typography/Text/StyledText.tsx +7 -1
  68. package/src/components/Typography/Text/__tests__/StyledText.spec.tsx +1 -0
  69. package/src/components/Typography/Text/__tests__/__snapshots__/StyledText.spec.tsx.snap +22 -0
  70. package/src/components/Typography/Text/index.tsx +7 -1
  71. package/src/index.ts +2 -0
  72. package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +76 -23
  73. package/src/theme/components/.eslintrc.json +10 -0
  74. package/src/theme/components/alert.ts +5 -1
  75. package/src/theme/components/avatar.ts +2 -0
  76. package/src/theme/components/card.ts +6 -7
  77. package/src/theme/components/sectionHeading.ts +1 -1
  78. package/src/theme/components/spinner.ts +19 -7
  79. package/src/theme/components/tabs.ts +3 -2
  80. package/src/theme/components/tag.ts +13 -13
  81. package/src/theme/components/toast.ts +17 -3
  82. package/src/theme/components/typography.ts +2 -0
  83. package/src/theme/global/colors/swag.ts +23 -0
  84. package/src/theme/global/colors/types.ts +23 -0
  85. package/src/theme/global/colors/work.ts +5 -0
  86. package/tsconfig.json +4 -15
  87. package/types/components/Accordion/StyledAccordion.d.ts +14 -14
  88. package/types/components/Alert/StyledAlert.d.ts +16 -16
  89. package/types/components/Alert/index.d.ts +1 -1
  90. package/types/components/Avatar/StyledAvatar.d.ts +16 -16
  91. package/types/components/Avatar/index.d.ts +2 -2
  92. package/types/components/Badge/StyledBadge.d.ts +7 -7
  93. package/types/components/BottomNavigation/StyledBottomNavigation.d.ts +21 -21
  94. package/types/components/BottomSheet/Header.d.ts +1 -1
  95. package/types/components/BottomSheet/StyledBottomSheet.d.ts +19 -19
  96. package/types/components/Box/StyledBox.d.ts +15 -0
  97. package/types/components/Box/__tests__/helpers.spec.d.ts +1 -0
  98. package/types/components/Box/__tests__/index.spec.d.ts +1 -0
  99. package/types/components/Box/config.d.ts +170 -0
  100. package/types/components/Box/helpers.d.ts +1 -0
  101. package/types/components/Box/index.d.ts +5 -0
  102. package/types/components/Box/types.d.ts +31 -0
  103. package/types/components/Button/LoadingIndicator/StyledLoadingIndicator.d.ts +7 -7
  104. package/types/components/Button/StyledButton.d.ts +16 -16
  105. package/types/components/Button/UtilityButton/StyledUtilityButton.d.ts +8 -8
  106. package/types/components/Calendar/StyledCalendar.d.ts +25 -25
  107. package/types/components/Calendar/helpers.d.ts +2 -2
  108. package/types/components/Card/DataCard/StyledDataCard.d.ts +7 -7
  109. package/types/components/Card/DataCard/index.d.ts +1 -1
  110. package/types/components/Card/StyledCard.d.ts +7 -6
  111. package/types/components/Card/index.d.ts +5 -1
  112. package/types/components/Checkbox/StyledCheckbox.d.ts +10 -10
  113. package/types/components/Collapse/StyledCollapse.d.ts +8 -8
  114. package/types/components/ContentNavigator/StyledContentNavigator.d.ts +5 -5
  115. package/types/components/DatePicker/StyledDatePicker.d.ts +3 -3
  116. package/types/components/Divider/StyledDivider.d.ts +5 -5
  117. package/types/components/Drawer/StyledDrawer.d.ts +19 -19
  118. package/types/components/Empty/StyledEmpty.d.ts +12 -12
  119. package/types/components/FAB/ActionGroup/StyledActionGroup.d.ts +11 -11
  120. package/types/components/FAB/ActionGroup/StyledActionItem.d.ts +7 -7
  121. package/types/components/FAB/StyledFAB.d.ts +8 -8
  122. package/types/components/Icon/HeroIcon/index.d.ts +3 -3
  123. package/types/components/List/StyledBasicListItem.d.ts +14 -14
  124. package/types/components/List/StyledListItem.d.ts +23 -23
  125. package/types/components/PinInput/StyledPinInput.d.ts +30 -30
  126. package/types/components/Progress/StyledProgressBar.d.ts +5 -5
  127. package/types/components/Progress/StyledProgressCircle.d.ts +18 -18
  128. package/types/components/Radio/StyledRadio.d.ts +9 -9
  129. package/types/components/RichTextEditor/EditorToolbar.d.ts +1 -1
  130. package/types/components/RichTextEditor/MentionList.d.ts +1 -1
  131. package/types/components/RichTextEditor/StyledRichTextEditor.d.ts +6 -6
  132. package/types/components/RichTextEditor/StyledToolbar.d.ts +9 -9
  133. package/types/components/RichTextEditor/index.d.ts +2 -2
  134. package/types/components/SectionHeading/StyledHeading.d.ts +9 -9
  135. package/types/components/Select/MultiSelect/Option.d.ts +1 -1
  136. package/types/components/Select/SingleSelect/Option.d.ts +1 -1
  137. package/types/components/Select/StyledSelect.d.ts +11 -11
  138. package/types/components/Select/helpers.d.ts +1 -1
  139. package/types/components/Spinner/AnimatedSpinner.d.ts +3 -1
  140. package/types/components/Spinner/StyledSpinner.d.ts +14 -12
  141. package/types/components/Spinner/index.d.ts +5 -1
  142. package/types/components/Switch/StyledSwitch.d.ts +5 -5
  143. package/types/components/Tabs/StyledScrollableTabs.d.ts +24 -22
  144. package/types/components/Tabs/StyledTabs.d.ts +26 -20
  145. package/types/components/Tabs/TabWithBadge.d.ts +17 -0
  146. package/types/components/Tabs/__tests__/TabWithBadge.spec.d.ts +1 -0
  147. package/types/components/Tabs/index.d.ts +3 -1
  148. package/types/components/Tag/StyledTag.d.ts +6 -6
  149. package/types/components/Tag/index.d.ts +1 -1
  150. package/types/components/TextInput/StyledTextInput.d.ts +44 -44
  151. package/types/components/TextInput/index.d.ts +5 -5
  152. package/types/components/TimePicker/StyledTimePicker.d.ts +3 -3
  153. package/types/components/Toast/StyledToast.d.ts +19 -18
  154. package/types/components/Toast/types.d.ts +2 -1
  155. package/types/components/Toolbar/StyledToolbar.d.ts +9 -9
  156. package/types/components/Typography/Text/StyledText.d.ts +4 -4
  157. package/types/components/Typography/Text/index.d.ts +1 -1
  158. package/types/index.d.ts +2 -1
  159. package/types/testHelpers/renderWithTheme.d.ts +1 -1
  160. package/types/theme/ThemeSwitcher.d.ts +1 -1
  161. package/types/theme/components/alert.d.ts +5 -1
  162. package/types/theme/components/avatar.d.ts +2 -0
  163. package/types/theme/components/card.d.ts +6 -7
  164. package/types/theme/components/spinner.d.ts +17 -5
  165. package/types/theme/components/tabs.d.ts +1 -0
  166. package/types/theme/components/tag.d.ts +2 -2
  167. package/types/theme/components/toast.d.ts +18 -2
  168. package/types/theme/components/typography.d.ts +2 -0
  169. package/types/theme/global/colors/types.d.ts +17 -0
  170. package/types/theme/global/index.d.ts +17 -0
  171. package/types/utils/hooks.d.ts +1 -1
@@ -2,6 +2,7 @@ import React from 'react';
2
2
  import { View } from 'react-native';
3
3
  import renderWithTheme from '../../../testHelpers/renderWithTheme';
4
4
  import Card from '..';
5
+ import Typography from '../../Typography';
5
6
 
6
7
  describe('Card', () => {
7
8
  it('renders basic card', () => {
@@ -27,4 +28,21 @@ describe('Card', () => {
27
28
  expect(queryAllByTestId('child-view')).toHaveLength(1);
28
29
  expect(queryAllByTestId('data-card-indicator')).toHaveLength(1);
29
30
  });
31
+
32
+ it.each`
33
+ intent
34
+ ${undefined}
35
+ ${'primary'}
36
+ ${'success'}
37
+ ${'info'}
38
+ `('renders correctly when intent is $intent', ({ intent }) => {
39
+ const { toJSON, getByText } = renderWithTheme(
40
+ <Card intent={intent}>
41
+ <Typography.Text>Card Content</Typography.Text>
42
+ </Card>
43
+ );
44
+
45
+ expect(getByText('Card Content')).toBeDefined();
46
+ expect(toJSON()).toMatchSnapshot();
47
+ });
30
48
  });
@@ -9,6 +9,10 @@ interface CardProps extends ViewProps {
9
9
  * Card's content.
10
10
  */
11
11
  children?: ReactNode;
12
+ /**
13
+ * Visual intent color to apply to card.
14
+ */
15
+ intent?: 'primary' | 'success' | 'warning';
12
16
  /**
13
17
  * Card type.
14
18
  * This is now deprecated. If you want to use "data" variant, please use Card.Data instead.
@@ -27,10 +31,11 @@ interface CardProps extends ViewProps {
27
31
 
28
32
  const Card = ({
29
33
  variant = 'basic',
34
+ intent,
30
35
  children,
31
36
  ...nativeProps
32
37
  }: CardProps): JSX.Element => (
33
- <StyledCard {...nativeProps} themeVariant={variant}>
38
+ <StyledCard {...nativeProps} themeVariant={variant} themeIntent={intent}>
34
39
  {variant === 'data' && <LeftDataCard testID="data-card-indicator" />}
35
40
  {children}
36
41
  </StyledCard>
@@ -17,10 +17,9 @@ export const calculateSnapPointsData = (
17
17
  snapPoints: number[]
18
18
  ): SnapPointsData => {
19
19
  const filteredSnapPoints = snapPoints.filter(value => value >= minimumHeight);
20
- const snapPointsOffsetValues = [
21
- minimumHeight,
22
- ...filteredSnapPoints,
23
- ].map(value => getOffset(height, value));
20
+ const snapPointsOffsetValues = [minimumHeight, ...filteredSnapPoints].map(
21
+ value => getOffset(height, value)
22
+ );
24
23
  const uniqSnapPointOffsetValues = Array.from(
25
24
  new Set([...snapPointsOffsetValues, 0])
26
25
  );
@@ -97,19 +97,17 @@ const ActionGroup = ({
97
97
  outputRange: [400, 0],
98
98
  }
99
99
  );
100
- const interpolatedBackdropOpacityAnimation = tranlateXAnimation.current.interpolate(
101
- {
100
+ const interpolatedBackdropOpacityAnimation =
101
+ tranlateXAnimation.current.interpolate({
102
102
  inputRange: [0, 1],
103
103
  outputRange: [0, 0.9],
104
- }
105
- );
104
+ });
106
105
 
107
- const interpolatedActionGroupOpacityAnimation = tranlateXAnimation.current.interpolate(
108
- {
106
+ const interpolatedActionGroupOpacityAnimation =
107
+ tranlateXAnimation.current.interpolate({
109
108
  inputRange: [0, 1],
110
109
  outputRange: [0, 1],
111
- }
112
- );
110
+ });
113
111
 
114
112
  return (
115
113
  <StyledContainer testID={testID} pointerEvents="box-none" style={style}>
@@ -126,8 +126,7 @@ describe('RichTextEditor', () => {
126
126
  });
127
127
  onMessageOfLatestRendering({
128
128
  nativeEvent: {
129
- data:
130
- '{"type": "@hero-editor/webview/mention-search", "data" : {}}',
129
+ data: '{"type": "@hero-editor/webview/mention-search", "data" : {}}',
131
130
  },
132
131
  });
133
132
  expect(emittedEvents).toMatchObject(['called']);
@@ -142,8 +141,7 @@ describe('RichTextEditor', () => {
142
141
  it('should call onChange', () => {
143
142
  onMessageOfLatestRendering({
144
143
  nativeEvent: {
145
- data:
146
- '{"type": "@hero-editor/webview/editor-change", "data" : { "value": "text"}}',
144
+ data: '{"type": "@hero-editor/webview/editor-change", "data" : { "value": "text"}}',
147
145
  },
148
146
  });
149
147
  expect(onChangeMock).lastCalledWith('text');
@@ -158,8 +156,7 @@ describe('RichTextEditor', () => {
158
156
  it('should call onCursorChange', () => {
159
157
  onMessageOfLatestRendering({
160
158
  nativeEvent: {
161
- data:
162
- '{"type": "@hero-editor/webview/cursor-change", "data" : { "position": 32}}',
159
+ data: '{"type": "@hero-editor/webview/cursor-change", "data" : { "position": 32}}',
163
160
  },
164
161
  });
165
162
  expect(onCursorChangeMock).lastCalledWith({ position: 32 });
@@ -171,8 +168,7 @@ describe('RichTextEditor', () => {
171
168
  act(() => {
172
169
  onMessageOfLatestRendering({
173
170
  nativeEvent: {
174
- data:
175
- '{"type": "@hero-editor/webview/editor-layout", "data" : { "width": 320, "height": 480}}',
171
+ data: '{"type": "@hero-editor/webview/editor-layout", "data" : { "width": 320, "height": 480}}',
176
172
  },
177
173
  });
178
174
  });
@@ -6,7 +6,7 @@ exports[`StyledHeading renders correct style 1`] = `
6
6
  Array [
7
7
  Object {
8
8
  "alignContent": "center",
9
- "backgroundColor": "#e8e9ea",
9
+ "backgroundColor": "#f6f6f7",
10
10
  "display": "flex",
11
11
  "flexDirection": "row",
12
12
  "justifyContent": "space-between",
@@ -6,7 +6,7 @@ exports[`SectionHeading allows to customise the icon 1`] = `
6
6
  Array [
7
7
  Object {
8
8
  "alignContent": "center",
9
- "backgroundColor": "#e8e9ea",
9
+ "backgroundColor": "#f6f6f7",
10
10
  "display": "flex",
11
11
  "flexDirection": "row",
12
12
  "justifyContent": "space-between",
@@ -83,7 +83,7 @@ exports[`SectionHeading render icon correctly 1`] = `
83
83
  Array [
84
84
  Object {
85
85
  "alignContent": "center",
86
- "backgroundColor": "#e8e9ea",
86
+ "backgroundColor": "#f6f6f7",
87
87
  "display": "flex",
88
88
  "flexDirection": "row",
89
89
  "justifyContent": "space-between",
@@ -161,7 +161,7 @@ exports[`SectionHeading render right children correctly 1`] = `
161
161
  Array [
162
162
  Object {
163
163
  "alignContent": "center",
164
- "backgroundColor": "#e8e9ea",
164
+ "backgroundColor": "#f6f6f7",
165
165
  "display": "flex",
166
166
  "flexDirection": "row",
167
167
  "justifyContent": "space-between",
@@ -227,7 +227,7 @@ exports[`SectionHeading renders correctly 1`] = `
227
227
  Array [
228
228
  Object {
229
229
  "alignContent": "center",
230
- "backgroundColor": "#e8e9ea",
230
+ "backgroundColor": "#f6f6f7",
231
231
  "display": "flex",
232
232
  "flexDirection": "row",
233
233
  "justifyContent": "space-between",
@@ -74,7 +74,7 @@ exports[`OptionList render isLoading correctly 1`] = `
74
74
  Array [
75
75
  Object {
76
76
  "alignContent": "center",
77
- "backgroundColor": "#e8e9ea",
77
+ "backgroundColor": "#f6f6f7",
78
78
  "display": "flex",
79
79
  "flexDirection": "row",
80
80
  "justifyContent": "space-between",
@@ -323,7 +323,7 @@ exports[`OptionList render isLoading correctly 1`] = `
323
323
  Array [
324
324
  Object {
325
325
  "alignContent": "center",
326
- "backgroundColor": "#e8e9ea",
326
+ "backgroundColor": "#f6f6f7",
327
327
  "display": "flex",
328
328
  "flexDirection": "row",
329
329
  "justifyContent": "space-between",
@@ -713,6 +713,7 @@ exports[`OptionList render isLoading correctly 1`] = `
713
713
  ]
714
714
  }
715
715
  themePosition="top"
716
+ themeSize="medium"
716
717
  >
717
718
  <View
718
719
  collapsable={false}
@@ -720,16 +721,16 @@ exports[`OptionList render isLoading correctly 1`] = `
720
721
  style={
721
722
  Array [
722
723
  Object {
723
- "backgroundColor": "#8505a2",
724
- "borderRadius": 8,
724
+ "backgroundColor": "#795e90",
725
+ "borderRadius": 999,
725
726
  "height": 16,
726
- "opacity": 1,
727
727
  "width": 16,
728
728
  },
729
729
  Object {},
730
730
  ]
731
731
  }
732
732
  themePosition="topLeft"
733
+ themeSize="medium"
733
734
  />
734
735
  <View
735
736
  collapsable={false}
@@ -737,17 +738,17 @@ exports[`OptionList render isLoading correctly 1`] = `
737
738
  style={
738
739
  Array [
739
740
  Object {
740
- "backgroundColor": "#8505a2",
741
- "borderRadius": 8,
741
+ "backgroundColor": "#a08cb0",
742
+ "borderRadius": 999,
742
743
  "height": 16,
743
744
  "marginLeft": 8,
744
- "opacity": 0.7,
745
745
  "width": 16,
746
746
  },
747
747
  Object {},
748
748
  ]
749
749
  }
750
750
  themePosition="topRight"
751
+ themeSize="medium"
751
752
  />
752
753
  </View>
753
754
  <View
@@ -763,6 +764,7 @@ exports[`OptionList render isLoading correctly 1`] = `
763
764
  ]
764
765
  }
765
766
  themePosition="bottom"
767
+ themeSize="medium"
766
768
  >
767
769
  <View
768
770
  collapsable={false}
@@ -770,16 +772,16 @@ exports[`OptionList render isLoading correctly 1`] = `
770
772
  style={
771
773
  Array [
772
774
  Object {
773
- "backgroundColor": "#8505a2",
774
- "borderRadius": 8,
775
+ "backgroundColor": "#d9d1df",
776
+ "borderRadius": 999,
775
777
  "height": 16,
776
- "opacity": 0.5,
777
778
  "width": 16,
778
779
  },
779
780
  Object {},
780
781
  ]
781
782
  }
782
783
  themePosition="bottomLeft"
784
+ themeSize="medium"
783
785
  />
784
786
  <View
785
787
  collapsable={false}
@@ -787,17 +789,17 @@ exports[`OptionList render isLoading correctly 1`] = `
787
789
  style={
788
790
  Array [
789
791
  Object {
790
- "backgroundColor": "#8505a2",
791
- "borderRadius": 8,
792
+ "backgroundColor": "#ece8ef",
793
+ "borderRadius": 999,
792
794
  "height": 16,
793
795
  "marginLeft": 8,
794
- "opacity": 0.3,
795
796
  "width": 16,
796
797
  },
797
798
  Object {},
798
799
  ]
799
800
  }
800
801
  themePosition="bottomRight"
802
+ themeSize="medium"
801
803
  />
802
804
  </View>
803
805
  </View>
@@ -871,7 +873,7 @@ exports[`OptionList renders correctly 1`] = `
871
873
  Array [
872
874
  Object {
873
875
  "alignContent": "center",
874
- "backgroundColor": "#e8e9ea",
876
+ "backgroundColor": "#f6f6f7",
875
877
  "display": "flex",
876
878
  "flexDirection": "row",
877
879
  "justifyContent": "space-between",
@@ -1120,7 +1122,7 @@ exports[`OptionList renders correctly 1`] = `
1120
1122
  Array [
1121
1123
  Object {
1122
1124
  "alignContent": "center",
1123
- "backgroundColor": "#e8e9ea",
1125
+ "backgroundColor": "#f6f6f7",
1124
1126
  "display": "flex",
1125
1127
  "flexDirection": "row",
1126
1128
  "justifyContent": "space-between",
@@ -1518,7 +1520,7 @@ exports[`OptionList trigger onPress correctly on changing selection 1`] = `
1518
1520
  Array [
1519
1521
  Object {
1520
1522
  "alignContent": "center",
1521
- "backgroundColor": "#e8e9ea",
1523
+ "backgroundColor": "#f6f6f7",
1522
1524
  "display": "flex",
1523
1525
  "flexDirection": "row",
1524
1526
  "justifyContent": "space-between",
@@ -1767,7 +1769,7 @@ exports[`OptionList trigger onPress correctly on changing selection 1`] = `
1767
1769
  Array [
1768
1770
  Object {
1769
1771
  "alignContent": "center",
1770
- "backgroundColor": "#e8e9ea",
1772
+ "backgroundColor": "#f6f6f7",
1771
1773
  "display": "flex",
1772
1774
  "flexDirection": "row",
1773
1775
  "justifyContent": "space-between",
@@ -2190,7 +2192,7 @@ exports[`OptionList trigger onPress correctly on select additional value 1`] = `
2190
2192
  Array [
2191
2193
  Object {
2192
2194
  "alignContent": "center",
2193
- "backgroundColor": "#e8e9ea",
2195
+ "backgroundColor": "#f6f6f7",
2194
2196
  "display": "flex",
2195
2197
  "flexDirection": "row",
2196
2198
  "justifyContent": "space-between",
@@ -2439,7 +2441,7 @@ exports[`OptionList trigger onPress correctly on select additional value 1`] = `
2439
2441
  Array [
2440
2442
  Object {
2441
2443
  "alignContent": "center",
2442
- "backgroundColor": "#e8e9ea",
2444
+ "backgroundColor": "#f6f6f7",
2443
2445
  "display": "flex",
2444
2446
  "flexDirection": "row",
2445
2447
  "justifyContent": "space-between",
@@ -450,7 +450,7 @@ Array [
450
450
  Array [
451
451
  Object {
452
452
  "alignContent": "center",
453
- "backgroundColor": "#e8e9ea",
453
+ "backgroundColor": "#f6f6f7",
454
454
  "display": "flex",
455
455
  "flexDirection": "row",
456
456
  "justifyContent": "space-between",
@@ -853,7 +853,7 @@ Array [
853
853
  Array [
854
854
  Object {
855
855
  "alignContent": "center",
856
- "backgroundColor": "#e8e9ea",
856
+ "backgroundColor": "#f6f6f7",
857
857
  "display": "flex",
858
858
  "flexDirection": "row",
859
859
  "justifyContent": "space-between",
@@ -6337,7 +6337,7 @@ Array [
6337
6337
  Array [
6338
6338
  Object {
6339
6339
  "alignContent": "center",
6340
- "backgroundColor": "#e8e9ea",
6340
+ "backgroundColor": "#f6f6f7",
6341
6341
  "display": "flex",
6342
6342
  "flexDirection": "row",
6343
6343
  "justifyContent": "space-between",
@@ -6561,7 +6561,7 @@ Array [
6561
6561
  Array [
6562
6562
  Object {
6563
6563
  "alignContent": "center",
6564
- "backgroundColor": "#e8e9ea",
6564
+ "backgroundColor": "#f6f6f7",
6565
6565
  "display": "flex",
6566
6566
  "flexDirection": "row",
6567
6567
  "justifyContent": "space-between",
@@ -74,7 +74,7 @@ exports[`OptionList render isLoading correctly 1`] = `
74
74
  Array [
75
75
  Object {
76
76
  "alignContent": "center",
77
- "backgroundColor": "#e8e9ea",
77
+ "backgroundColor": "#f6f6f7",
78
78
  "display": "flex",
79
79
  "flexDirection": "row",
80
80
  "justifyContent": "space-between",
@@ -298,7 +298,7 @@ exports[`OptionList render isLoading correctly 1`] = `
298
298
  Array [
299
299
  Object {
300
300
  "alignContent": "center",
301
- "backgroundColor": "#e8e9ea",
301
+ "backgroundColor": "#f6f6f7",
302
302
  "display": "flex",
303
303
  "flexDirection": "row",
304
304
  "justifyContent": "space-between",
@@ -688,6 +688,7 @@ exports[`OptionList render isLoading correctly 1`] = `
688
688
  ]
689
689
  }
690
690
  themePosition="top"
691
+ themeSize="medium"
691
692
  >
692
693
  <View
693
694
  collapsable={false}
@@ -695,16 +696,16 @@ exports[`OptionList render isLoading correctly 1`] = `
695
696
  style={
696
697
  Array [
697
698
  Object {
698
- "backgroundColor": "#8505a2",
699
- "borderRadius": 8,
699
+ "backgroundColor": "#795e90",
700
+ "borderRadius": 999,
700
701
  "height": 16,
701
- "opacity": 1,
702
702
  "width": 16,
703
703
  },
704
704
  Object {},
705
705
  ]
706
706
  }
707
707
  themePosition="topLeft"
708
+ themeSize="medium"
708
709
  />
709
710
  <View
710
711
  collapsable={false}
@@ -712,17 +713,17 @@ exports[`OptionList render isLoading correctly 1`] = `
712
713
  style={
713
714
  Array [
714
715
  Object {
715
- "backgroundColor": "#8505a2",
716
- "borderRadius": 8,
716
+ "backgroundColor": "#a08cb0",
717
+ "borderRadius": 999,
717
718
  "height": 16,
718
719
  "marginLeft": 8,
719
- "opacity": 0.7,
720
720
  "width": 16,
721
721
  },
722
722
  Object {},
723
723
  ]
724
724
  }
725
725
  themePosition="topRight"
726
+ themeSize="medium"
726
727
  />
727
728
  </View>
728
729
  <View
@@ -738,6 +739,7 @@ exports[`OptionList render isLoading correctly 1`] = `
738
739
  ]
739
740
  }
740
741
  themePosition="bottom"
742
+ themeSize="medium"
741
743
  >
742
744
  <View
743
745
  collapsable={false}
@@ -745,16 +747,16 @@ exports[`OptionList render isLoading correctly 1`] = `
745
747
  style={
746
748
  Array [
747
749
  Object {
748
- "backgroundColor": "#8505a2",
749
- "borderRadius": 8,
750
+ "backgroundColor": "#d9d1df",
751
+ "borderRadius": 999,
750
752
  "height": 16,
751
- "opacity": 0.5,
752
753
  "width": 16,
753
754
  },
754
755
  Object {},
755
756
  ]
756
757
  }
757
758
  themePosition="bottomLeft"
759
+ themeSize="medium"
758
760
  />
759
761
  <View
760
762
  collapsable={false}
@@ -762,17 +764,17 @@ exports[`OptionList render isLoading correctly 1`] = `
762
764
  style={
763
765
  Array [
764
766
  Object {
765
- "backgroundColor": "#8505a2",
766
- "borderRadius": 8,
767
+ "backgroundColor": "#ece8ef",
768
+ "borderRadius": 999,
767
769
  "height": 16,
768
770
  "marginLeft": 8,
769
- "opacity": 0.3,
770
771
  "width": 16,
771
772
  },
772
773
  Object {},
773
774
  ]
774
775
  }
775
776
  themePosition="bottomRight"
777
+ themeSize="medium"
776
778
  />
777
779
  </View>
778
780
  </View>
@@ -846,7 +848,7 @@ exports[`OptionList renders correctly 1`] = `
846
848
  Array [
847
849
  Object {
848
850
  "alignContent": "center",
849
- "backgroundColor": "#e8e9ea",
851
+ "backgroundColor": "#f6f6f7",
850
852
  "display": "flex",
851
853
  "flexDirection": "row",
852
854
  "justifyContent": "space-between",
@@ -1070,7 +1072,7 @@ exports[`OptionList renders correctly 1`] = `
1070
1072
  Array [
1071
1073
  Object {
1072
1074
  "alignContent": "center",
1073
- "backgroundColor": "#e8e9ea",
1075
+ "backgroundColor": "#f6f6f7",
1074
1076
  "display": "flex",
1075
1077
  "flexDirection": "row",
1076
1078
  "justifyContent": "space-between",
@@ -1468,7 +1470,7 @@ exports[`OptionList trigger onPress correctly on select new value 1`] = `
1468
1470
  Array [
1469
1471
  Object {
1470
1472
  "alignContent": "center",
1471
- "backgroundColor": "#e8e9ea",
1473
+ "backgroundColor": "#f6f6f7",
1472
1474
  "display": "flex",
1473
1475
  "flexDirection": "row",
1474
1476
  "justifyContent": "space-between",
@@ -1692,7 +1694,7 @@ exports[`OptionList trigger onPress correctly on select new value 1`] = `
1692
1694
  Array [
1693
1695
  Object {
1694
1696
  "alignContent": "center",
1695
- "backgroundColor": "#e8e9ea",
1697
+ "backgroundColor": "#f6f6f7",
1696
1698
  "display": "flex",
1697
1699
  "flexDirection": "row",
1698
1700
  "justifyContent": "space-between",
@@ -2090,7 +2092,7 @@ exports[`OptionList trigger onPress correctly on unselect current value 1`] = `
2090
2092
  Array [
2091
2093
  Object {
2092
2094
  "alignContent": "center",
2093
- "backgroundColor": "#e8e9ea",
2095
+ "backgroundColor": "#f6f6f7",
2094
2096
  "display": "flex",
2095
2097
  "flexDirection": "row",
2096
2098
  "justifyContent": "space-between",
@@ -2314,7 +2316,7 @@ exports[`OptionList trigger onPress correctly on unselect current value 1`] = `
2314
2316
  Array [
2315
2317
  Object {
2316
2318
  "alignContent": "center",
2317
- "backgroundColor": "#e8e9ea",
2319
+ "backgroundColor": "#f6f6f7",
2318
2320
  "display": "flex",
2319
2321
  "flexDirection": "row",
2320
2322
  "justifyContent": "space-between",
@@ -449,7 +449,7 @@ Array [
449
449
  Array [
450
450
  Object {
451
451
  "alignContent": "center",
452
- "backgroundColor": "#e8e9ea",
452
+ "backgroundColor": "#f6f6f7",
453
453
  "display": "flex",
454
454
  "flexDirection": "row",
455
455
  "justifyContent": "space-between",
@@ -852,7 +852,7 @@ Array [
852
852
  Array [
853
853
  Object {
854
854
  "alignContent": "center",
855
- "backgroundColor": "#e8e9ea",
855
+ "backgroundColor": "#f6f6f7",
856
856
  "display": "flex",
857
857
  "flexDirection": "row",
858
858
  "justifyContent": "space-between",
@@ -5898,7 +5898,7 @@ Array [
5898
5898
  Array [
5899
5899
  Object {
5900
5900
  "alignContent": "center",
5901
- "backgroundColor": "#e8e9ea",
5901
+ "backgroundColor": "#f6f6f7",
5902
5902
  "display": "flex",
5903
5903
  "flexDirection": "row",
5904
5904
  "justifyContent": "space-between",
@@ -6122,7 +6122,7 @@ Array [
6122
6122
  Array [
6123
6123
  Object {
6124
6124
  "alignContent": "center",
6125
- "backgroundColor": "#e8e9ea",
6125
+ "backgroundColor": "#f6f6f7",
6126
6126
  "display": "flex",
6127
6127
  "flexDirection": "row",
6128
6128
  "justifyContent": "space-between",
@@ -7,7 +7,7 @@ const AnimatedRow = Animated.createAnimatedComponent(StyledSpinnerRow);
7
7
 
8
8
  const AnimatedDot = Animated.createAnimatedComponent(StyledSpinnerDot);
9
9
 
10
- const AnimatedSpinner = () => {
10
+ const AnimatedSpinner = ({ size = 'medium' }: { size: 'small' | 'medium' }) => {
11
11
  const rotateAnimation = useRef<Animated.Value>(new Animated.Value(0));
12
12
 
13
13
  useEffect(() => {
@@ -40,13 +40,13 @@ const AnimatedSpinner = () => {
40
40
  },
41
41
  ])}
42
42
  >
43
- <AnimatedRow themePosition="top">
44
- <AnimatedDot themePosition="topLeft" />
45
- <AnimatedDot themePosition="topRight" />
43
+ <AnimatedRow themePosition="top" themeSize={size}>
44
+ <AnimatedDot themePosition="topLeft" themeSize={size} />
45
+ <AnimatedDot themePosition="topRight" themeSize={size} />
46
46
  </AnimatedRow>
47
- <AnimatedRow themePosition="bottom">
48
- <AnimatedDot themePosition="bottomLeft" />
49
- <AnimatedDot themePosition="bottomRight" />
47
+ <AnimatedRow themePosition="bottom" themeSize={size}>
48
+ <AnimatedDot themePosition="bottomLeft" themeSize={size} />
49
+ <AnimatedDot themePosition="bottomRight" themeSize={size} />
50
50
  </AnimatedRow>
51
51
  </Animated.View>
52
52
  );