@hero-design/rn 7.24.0 → 7.25.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.
Files changed (253) hide show
  1. package/.turbo/turbo-build.log +2 -2
  2. package/assets/fonts/hero-icons-mobile.ttf +0 -0
  3. package/es/index.js +844 -751
  4. package/lib/assets/fonts/hero-icons-mobile.ttf +0 -0
  5. package/lib/index.js +845 -749
  6. package/package.json +6 -5
  7. package/rollup.config.js +1 -1
  8. package/src/components/Accordion/__tests__/__snapshots__/AccordionItem.spec.tsx.snap +4 -4
  9. package/src/components/Accordion/__tests__/__snapshots__/index.spec.tsx.snap +6 -6
  10. package/src/components/Attachment/StyledAttachment.tsx +44 -0
  11. package/src/components/Attachment/__tests__/__snapshots__/index.spec.tsx.snap +158 -0
  12. package/src/components/Attachment/__tests__/index.spec.tsx +59 -0
  13. package/src/components/Attachment/index.tsx +77 -0
  14. package/src/components/Avatar/__tests__/__snapshots__/StyledAvatar.spec.tsx.snap +3 -3
  15. package/src/components/Avatar/__tests__/__snapshots__/index.spec.tsx.snap +2 -2
  16. package/src/components/Badge/Status.tsx +1 -1
  17. package/src/components/Badge/StyledBadge.tsx +8 -1
  18. package/src/components/Badge/__tests__/Badge.spec.tsx +9 -0
  19. package/src/components/Badge/__tests__/__snapshots__/Badge.spec.tsx.snap +44 -0
  20. package/src/components/Badge/index.tsx +1 -1
  21. package/src/components/BottomNavigation/__tests__/__snapshots__/index.spec.tsx.snap +3 -3
  22. package/src/components/BottomSheet/Header.tsx +2 -1
  23. package/src/components/BottomSheet/__tests__/__snapshots__/index.spec.tsx.snap +52 -52
  24. package/src/components/BottomSheet/index.tsx +4 -4
  25. package/src/components/Button/Button.tsx +0 -11
  26. package/src/components/Button/LoadingIndicator/__tests__/__snapshots__/StyledLoadingIndicator.spec.tsx.snap +4 -4
  27. package/src/components/Button/LoadingIndicator/__tests__/__snapshots__/index.spec.tsx.snap +12 -12
  28. package/src/components/Button/LoadingIndicator/index.tsx +1 -1
  29. package/src/components/Button/StyledButton.tsx +24 -63
  30. package/src/components/Button/UtilityButton/__tests__/index.spec.tsx +2 -2
  31. package/src/components/Button/__tests__/Button.spec.tsx +10 -5
  32. package/src/components/Button/__tests__/StyledButton.spec.tsx +0 -70
  33. package/src/components/Button/__tests__/__snapshots__/StyledButton.spec.tsx.snap +301 -1206
  34. package/src/components/Calendar/CalendarRowItem.tsx +1 -4
  35. package/src/components/Calendar/__tests__/__snapshots__/CalendarRowItem.spec.tsx.snap +5 -5
  36. package/src/components/Calendar/index.tsx +4 -3
  37. package/src/components/Card/DataCard/__tests__/__snapshots__/StyledDataCard.spec.tsx.snap +1 -1
  38. package/src/components/Card/__tests__/__snapshots__/StyledCard.spec.tsx.snap +1 -1
  39. package/src/components/Card/__tests__/__snapshots__/index.spec.tsx.snap +1 -1
  40. package/src/components/Checkbox/StyledCheckbox.tsx +7 -5
  41. package/src/components/Checkbox/__tests__/__snapshots__/StyledCheckbox.spec.tsx.snap +4 -12
  42. package/src/components/Checkbox/__tests__/__snapshots__/index.spec.tsx.snap +95 -42
  43. package/src/components/Checkbox/index.tsx +4 -2
  44. package/src/components/ContentNavigator/__tests__/__snapshots__/index.spec.tsx.snap +2 -2
  45. package/src/components/ContentNavigator/index.tsx +2 -1
  46. package/src/components/DatePicker/__tests__/__snapshots__/DatePickerAndroid.spec.tsx.snap +1 -0
  47. package/src/components/DatePicker/__tests__/__snapshots__/DatePickerIOS.spec.tsx.snap +28 -27
  48. package/src/components/Drawer/DragableDrawer/index.tsx +0 -2
  49. package/src/components/Empty/__tests__/__snapshots__/index.spec.tsx.snap +2 -2
  50. package/src/components/FAB/ActionGroup/__tests__/__snapshots__/index.spec.tsx.snap +12 -12
  51. package/src/components/FAB/__tests__/__snapshots__/StyledFAB.spec.tsx.snap +1 -1
  52. package/src/components/FAB/__tests__/__snapshots__/index.spec.tsx.snap +3 -3
  53. package/src/components/Icon/HeroIcon/glyphMap.json +1 -1
  54. package/src/components/Icon/HeroIcon/index.tsx +5 -1
  55. package/src/components/Icon/IconList.ts +30 -3
  56. package/src/components/Icon/__tests__/__snapshots__/index.spec.tsx.snap +1 -1
  57. package/src/components/List/BasicListItem.tsx +13 -8
  58. package/src/components/List/ListItem.tsx +8 -6
  59. package/src/components/List/StyledBasicListItem.tsx +2 -2
  60. package/src/components/List/StyledListItem.tsx +2 -2
  61. package/src/components/List/__tests__/__snapshots__/BasicListItem.spec.tsx.snap +24 -36
  62. package/src/components/List/__tests__/__snapshots__/ListItem.spec.tsx.snap +39 -59
  63. package/src/components/List/__tests__/__snapshots__/StyledBasicListItem.spec.tsx.snap +40 -44
  64. package/src/components/List/__tests__/__snapshots__/StyledListItem.spec.tsx.snap +50 -50
  65. package/src/components/PinInput/__tests__/__snapshots__/PinCell.spec.tsx.snap +6 -6
  66. package/src/components/PinInput/__tests__/__snapshots__/index.spec.tsx.snap +21 -21
  67. package/src/components/Progress/ProgressBar.tsx +1 -1
  68. package/src/components/Progress/ProgressCircle.tsx +1 -1
  69. package/src/components/Progress/__tests__/__snapshots__/index.spec.js.snap +10 -10
  70. package/src/components/Progress/types.ts +7 -1
  71. package/src/components/Radio/__tests__/__snapshots__/Radio.spec.tsx.snap +20 -32
  72. package/src/components/Radio/__tests__/__snapshots__/RadioGroup.spec.tsx.snap +30 -48
  73. package/src/components/RefreshControl/__tests__/index.spec.tsx +1 -3
  74. package/src/components/RefreshControl/index.tsx +4 -2
  75. package/src/components/RichTextEditor/MentionList.tsx +12 -3
  76. package/src/components/RichTextEditor/RichTextEditor.tsx +3 -4
  77. package/src/components/RichTextEditor/__tests__/__snapshots__/RichTextEditor.spec.tsx.snap +4 -4
  78. package/src/components/SectionHeading/__tests__/__snapshots__/index.spec.tsx.snap +1 -1
  79. package/src/components/Select/MultiSelect/__tests__/__snapshots__/Option.spec.tsx.snap +13 -20
  80. package/src/components/Select/MultiSelect/__tests__/__snapshots__/OptionList.spec.tsx.snap +146 -234
  81. package/src/components/Select/MultiSelect/__tests__/__snapshots__/index.spec.tsx.snap +430 -650
  82. package/src/components/Select/SingleSelect/__tests__/__snapshots__/Option.spec.tsx.snap +11 -18
  83. package/src/components/Select/SingleSelect/__tests__/__snapshots__/OptionList.spec.tsx.snap +136 -224
  84. package/src/components/Select/SingleSelect/__tests__/__snapshots__/index.spec.tsx.snap +409 -629
  85. package/src/components/Select/StyledOptionList.tsx +0 -1
  86. package/src/components/Select/__tests__/__snapshots__/StyledSelect.spec.tsx.snap +1 -1
  87. package/src/components/Spinner/StyledSpinner.tsx +1 -2
  88. package/src/components/Spinner/__tests__/__snapshots__/AnimatedSpinner.spec.tsx.snap +4 -4
  89. package/src/components/Spinner/__tests__/__snapshots__/StyledSpinner.spec.tsx.snap +16 -16
  90. package/src/components/Spinner/__tests__/__snapshots__/index.spec.tsx.snap +4 -4
  91. package/src/components/Swipeable/__tests__/__snapshots__/SwipeableAction.spec.tsx.snap +1 -1
  92. package/src/components/Swipeable/index.tsx +14 -2
  93. package/src/components/Switch/SelectorSwitch/Option.tsx +1 -5
  94. package/src/components/Switch/SelectorSwitch/__tests__/__snapshots__/Option.spec.tsx.snap +3 -3
  95. package/src/components/Switch/SelectorSwitch/__tests__/__snapshots__/index.spec.tsx.snap +3 -3
  96. package/src/components/Switch/SelectorSwitch/__tests__/index.spec.tsx +1 -0
  97. package/src/components/Switch/SelectorSwitch/index.tsx +4 -1
  98. package/src/components/Switch/__tests__/__snapshots__/StyledSwitch.spec.tsx.snap +1 -1
  99. package/src/components/Tabs/StyledTabs.tsx +1 -1
  100. package/src/components/Tabs/__tests__/__snapshots__/ScrollableTabs.spec.tsx.snap +1 -1
  101. package/src/components/Tabs/__tests__/__snapshots__/index.spec.tsx.snap +1 -1
  102. package/src/components/Tag/__tests__/__snapshots__/Tag.spec.tsx.snap +2 -2
  103. package/src/components/TextInput/StyledTextInput.tsx +1 -0
  104. package/src/components/TextInput/__tests__/__snapshots__/StyledTextInput.spec.tsx.snap +11 -10
  105. package/src/components/TextInput/__tests__/__snapshots__/index.spec.tsx.snap +27 -14
  106. package/src/components/TextInput/index.tsx +1 -0
  107. package/src/components/TimePicker/__tests__/__snapshots__/TimePickerAndroid.spec.tsx.snap +1 -0
  108. package/src/components/TimePicker/__tests__/__snapshots__/TimePickerIOS.spec.tsx.snap +28 -27
  109. package/src/components/Toast/Toast.tsx +0 -3
  110. package/src/components/Toast/ToastProvider.tsx +1 -0
  111. package/src/components/Toast/__tests__/index.spec.tsx +1 -1
  112. package/src/components/Toolbar/__tests__/__snapshots__/ToolbarGroup.spec.tsx.snap +12 -12
  113. package/src/components/Toolbar/__tests__/__snapshots__/ToolbarItem.spec.tsx.snap +6 -6
  114. package/src/components/Typography/Text/__tests__/__snapshots__/StyledText.spec.tsx.snap +4 -4
  115. package/src/emotion.d.ts +1 -0
  116. package/src/index.ts +6 -0
  117. package/src/theme/ThemeSwitcher.tsx +7 -1
  118. package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +87 -74
  119. package/src/theme/__tests__/ensureCompatibleWithV7.spec.tsx +13 -0
  120. package/src/theme/components/alert.ts +1 -1
  121. package/src/theme/components/attachment.ts +28 -0
  122. package/src/theme/components/avatar.ts +1 -1
  123. package/src/theme/components/badge.ts +2 -1
  124. package/src/theme/components/bottomNavigation.ts +1 -1
  125. package/src/theme/components/bottomSheet.ts +2 -2
  126. package/src/theme/components/button.ts +4 -20
  127. package/src/theme/components/calendar.ts +3 -3
  128. package/src/theme/components/card.ts +1 -1
  129. package/src/theme/components/checkbox.ts +2 -2
  130. package/src/theme/components/divider.ts +1 -1
  131. package/src/theme/components/drawer.ts +2 -2
  132. package/src/theme/components/empty.ts +3 -3
  133. package/src/theme/components/fab.ts +7 -7
  134. package/src/theme/components/icon.ts +4 -4
  135. package/src/theme/components/list.ts +0 -2
  136. package/src/theme/components/pinInput.ts +4 -4
  137. package/src/theme/components/progress.ts +6 -5
  138. package/src/theme/components/radio.ts +1 -1
  139. package/src/theme/components/richTextEditor.ts +2 -2
  140. package/src/theme/components/slider.ts +2 -2
  141. package/src/theme/components/switch.ts +4 -4
  142. package/src/theme/components/tabs.ts +6 -5
  143. package/src/theme/components/tag.ts +2 -2
  144. package/src/theme/components/textInput.ts +23 -28
  145. package/src/theme/components/toast.ts +3 -3
  146. package/src/theme/components/toolbar.ts +3 -3
  147. package/src/theme/components/typography.ts +7 -7
  148. package/src/theme/getTheme.ts +4 -1
  149. package/src/theme/global/colors/eBens.ts +23 -0
  150. package/src/theme/global/colors/global.ts +15 -6
  151. package/src/theme/global/colors/jobs.ts +15 -9
  152. package/src/theme/global/colors/legacySystemPalette.ts +6 -6
  153. package/src/theme/global/colors/swag.ts +32 -53
  154. package/src/theme/global/colors/types.ts +35 -15
  155. package/src/theme/global/colors/wallet.ts +23 -0
  156. package/src/theme/global/colors/work.ts +15 -9
  157. package/src/theme/global/index.ts +4 -0
  158. package/src/theme/index.ts +4 -0
  159. package/src/utils/functions.ts +2 -0
  160. package/src/utils/scale.ts +1 -1
  161. package/tsconfig.json +8 -2
  162. package/types/components/Accordion/StyledAccordion.d.ts +14 -14
  163. package/types/components/Alert/StyledAlert.d.ts +15 -15
  164. package/types/components/Attachment/StyledAttachment.d.ts +28 -0
  165. package/types/components/Attachment/index.d.ts +37 -0
  166. package/types/components/Avatar/StyledAvatar.d.ts +15 -15
  167. package/types/components/Avatar/index.d.ts +1 -1
  168. package/types/components/Badge/Status.d.ts +1 -1
  169. package/types/components/Badge/StyledBadge.d.ts +8 -8
  170. package/types/components/Badge/index.d.ts +1 -1
  171. package/types/components/BottomNavigation/StyledBottomNavigation.d.ts +21 -21
  172. package/types/components/BottomSheet/Header.d.ts +1 -1
  173. package/types/components/BottomSheet/StyledBottomSheet.d.ts +22 -22
  174. package/types/components/Box/StyledBox.d.ts +4 -4
  175. package/types/components/Button/LoadingIndicator/StyledLoadingIndicator.d.ts +7 -7
  176. package/types/components/Button/StyledButton.d.ts +15 -18
  177. package/types/components/Button/UtilityButton/StyledUtilityButton.d.ts +8 -8
  178. package/types/components/Calendar/StyledCalendar.d.ts +25 -25
  179. package/types/components/Calendar/helpers.d.ts +2 -2
  180. package/types/components/Card/DataCard/StyledDataCard.d.ts +6 -6
  181. package/types/components/Card/StyledCard.d.ts +7 -7
  182. package/types/components/Checkbox/StyledCheckbox.d.ts +16 -10
  183. package/types/components/Collapse/StyledCollapse.d.ts +8 -8
  184. package/types/components/ContentNavigator/StyledContentNavigator.d.ts +5 -5
  185. package/types/components/ContentNavigator/index.d.ts +2 -1
  186. package/types/components/DatePicker/StyledDatePicker.d.ts +3 -3
  187. package/types/components/Divider/StyledDivider.d.ts +5 -5
  188. package/types/components/Drawer/StyledDrawer.d.ts +19 -19
  189. package/types/components/Empty/StyledEmpty.d.ts +9 -9
  190. package/types/components/FAB/ActionGroup/StyledActionGroup.d.ts +11 -11
  191. package/types/components/FAB/ActionGroup/StyledActionItem.d.ts +7 -7
  192. package/types/components/FAB/StyledFAB.d.ts +8 -8
  193. package/types/components/Icon/HeroIcon/index.d.ts +3 -3
  194. package/types/components/Icon/IconList.d.ts +1 -1
  195. package/types/components/Icon/index.d.ts +1 -1
  196. package/types/components/Icon/utils.d.ts +1 -1
  197. package/types/components/List/StyledBasicListItem.d.ts +16 -16
  198. package/types/components/List/StyledListItem.d.ts +25 -25
  199. package/types/components/PinInput/StyledPinInput.d.ts +30 -30
  200. package/types/components/Progress/ProgressBar.d.ts +1 -1
  201. package/types/components/Progress/ProgressCircle.d.ts +1 -1
  202. package/types/components/Progress/StyledProgressBar.d.ts +5 -5
  203. package/types/components/Progress/StyledProgressCircle.d.ts +18 -18
  204. package/types/components/Progress/types.d.ts +1 -1
  205. package/types/components/Radio/StyledRadio.d.ts +9 -9
  206. package/types/components/RefreshControl/index.d.ts +1 -2
  207. package/types/components/RichTextEditor/EditorToolbar.d.ts +1 -1
  208. package/types/components/RichTextEditor/MentionList.d.ts +1 -1
  209. package/types/components/RichTextEditor/StyledRichTextEditor.d.ts +6 -6
  210. package/types/components/RichTextEditor/StyledToolbar.d.ts +9 -9
  211. package/types/components/RichTextEditor/index.d.ts +2 -2
  212. package/types/components/SectionHeading/StyledHeading.d.ts +9 -9
  213. package/types/components/Select/MultiSelect/Option.d.ts +1 -1
  214. package/types/components/Select/SingleSelect/Option.d.ts +1 -1
  215. package/types/components/Select/StyledSelect.d.ts +11 -11
  216. package/types/components/Select/helpers.d.ts +1 -1
  217. package/types/components/Spinner/StyledSpinner.d.ts +12 -12
  218. package/types/components/Swipeable/StyledSwipeable.d.ts +3 -3
  219. package/types/components/Swipeable/index.d.ts +7 -3
  220. package/types/components/Switch/SelectorSwitch/Option.d.ts +3 -1
  221. package/types/components/Switch/SelectorSwitch/StyledSelectorSwitch.d.ts +9 -9
  222. package/types/components/Switch/StyledSwitch.d.ts +5 -5
  223. package/types/components/Tabs/StyledScrollableTabs.d.ts +23 -23
  224. package/types/components/Tabs/StyledTabs.d.ts +22 -22
  225. package/types/components/Tag/StyledTag.d.ts +6 -6
  226. package/types/components/TextInput/StyledTextInput.d.ts +44 -44
  227. package/types/components/TextInput/index.d.ts +5 -5
  228. package/types/components/TimePicker/StyledTimePicker.d.ts +3 -3
  229. package/types/components/Toast/StyledToast.d.ts +17 -17
  230. package/types/components/Toolbar/StyledToolbar.d.ts +9 -9
  231. package/types/components/Typography/Text/StyledText.d.ts +3 -3
  232. package/types/index.d.ts +3 -2
  233. package/types/testHelpers/renderWithTheme.d.ts +1 -1
  234. package/types/theme/ThemeSwitcher.d.ts +2 -2
  235. package/types/theme/components/attachment.d.ts +21 -0
  236. package/types/theme/components/badge.d.ts +1 -0
  237. package/types/theme/components/button.d.ts +0 -15
  238. package/types/theme/components/list.d.ts +0 -1
  239. package/types/theme/components/progress.d.ts +1 -0
  240. package/types/theme/components/tabs.d.ts +1 -0
  241. package/types/theme/components/tag.d.ts +2 -2
  242. package/types/theme/components/textInput.d.ts +0 -5
  243. package/types/theme/getTheme.d.ts +2 -0
  244. package/types/theme/global/colors/eBens.d.ts +3 -0
  245. package/types/theme/global/colors/types.d.ts +23 -16
  246. package/types/theme/global/colors/wallet.d.ts +3 -0
  247. package/types/theme/global/index.d.ts +26 -12
  248. package/types/theme/index.d.ts +2 -2
  249. package/types/utils/functions.d.ts +1 -0
  250. package/types/utils/hooks.d.ts +1 -1
  251. package/assets/fonts/hero-icons.ttf +0 -0
  252. package/lib/assets/fonts/hero-icons.ttf +0 -0
  253. package/src/components/Icon/HeroIcon/fonts/hero-icons.ttf +0 -0
@@ -45,7 +45,6 @@ const StyledOptionList = <V, T extends OptionType<V>>({
45
45
  keyExtractor={keyExtractor}
46
46
  onEndReachedThreshold={0.1}
47
47
  onEndReached={() => setOnEndReachedCalled(true)}
48
- onScrollToIndexFailed={() => {}}
49
48
  onMomentumScrollBegin={() => {
50
49
  if (onEndReached && onEndReachedCalled && !loading) onEndReached();
51
50
  setOnEndReachedCalled(false);
@@ -13,7 +13,7 @@ exports[`FooterText has correct style 1`] = `
13
13
  },
14
14
  Array [
15
15
  Object {
16
- "color": "#401960",
16
+ "color": "#795e90",
17
17
  },
18
18
  undefined,
19
19
  ],
@@ -28,8 +28,7 @@ const StyledSpinnerDot = styled(View)<{
28
28
  themeIntent: 'primary' | 'inverted';
29
29
  }>(({ themePosition, themeSize, themeIntent, theme }) => {
30
30
  const themeStyling = () => {
31
- const backgroundColor =
32
- theme.__hd__.spinner.colors.dot[themeIntent];
31
+ const backgroundColor = theme.__hd__.spinner.colors.dot[themeIntent];
33
32
  const dotPadding = theme.__hd__.spinner.space.spinnerDotPadding[themeSize];
34
33
 
35
34
  switch (themePosition) {
@@ -35,7 +35,7 @@ exports[`AnimatedSpinner renders correctly 1`] = `
35
35
  style={
36
36
  Array [
37
37
  Object {
38
- "backgroundColor": "#001f23",
38
+ "backgroundColor": "#401960",
39
39
  "borderRadius": 999,
40
40
  "height": 16,
41
41
  "opacity": 0.9,
@@ -54,7 +54,7 @@ exports[`AnimatedSpinner renders correctly 1`] = `
54
54
  style={
55
55
  Array [
56
56
  Object {
57
- "backgroundColor": "#001f23",
57
+ "backgroundColor": "#401960",
58
58
  "borderRadius": 999,
59
59
  "height": 16,
60
60
  "marginLeft": 8,
@@ -90,7 +90,7 @@ exports[`AnimatedSpinner renders correctly 1`] = `
90
90
  style={
91
91
  Array [
92
92
  Object {
93
- "backgroundColor": "#001f23",
93
+ "backgroundColor": "#401960",
94
94
  "borderRadius": 999,
95
95
  "height": 16,
96
96
  "opacity": 0.45,
@@ -109,7 +109,7 @@ exports[`AnimatedSpinner renders correctly 1`] = `
109
109
  style={
110
110
  Array [
111
111
  Object {
112
- "backgroundColor": "#001f23",
112
+ "backgroundColor": "#401960",
113
113
  "borderRadius": 999,
114
114
  "height": 16,
115
115
  "marginLeft": 8,
@@ -47,7 +47,7 @@ exports[`StyledSpinnerContainer renders correctly when intent is $themeIntent, a
47
47
  style={
48
48
  Array [
49
49
  Object {
50
- "backgroundColor": "#001f23",
50
+ "backgroundColor": "#401960",
51
51
  "borderRadius": 999,
52
52
  "height": 8,
53
53
  "opacity": 0.9,
@@ -66,7 +66,7 @@ exports[`StyledSpinnerContainer renders correctly when intent is $themeIntent, a
66
66
  style={
67
67
  Array [
68
68
  Object {
69
- "backgroundColor": "#001f23",
69
+ "backgroundColor": "#401960",
70
70
  "borderRadius": 999,
71
71
  "height": 8,
72
72
  "marginLeft": 4,
@@ -102,7 +102,7 @@ exports[`StyledSpinnerContainer renders correctly when intent is $themeIntent, a
102
102
  style={
103
103
  Array [
104
104
  Object {
105
- "backgroundColor": "#001f23",
105
+ "backgroundColor": "#401960",
106
106
  "borderRadius": 999,
107
107
  "height": 8,
108
108
  "opacity": 0.45,
@@ -121,7 +121,7 @@ exports[`StyledSpinnerContainer renders correctly when intent is $themeIntent, a
121
121
  style={
122
122
  Array [
123
123
  Object {
124
- "backgroundColor": "#001f23",
124
+ "backgroundColor": "#401960",
125
125
  "borderRadius": 999,
126
126
  "height": 8,
127
127
  "marginLeft": 4,
@@ -327,7 +327,7 @@ exports[`StyledSpinnerContainer renders correctly when intent is $themeIntent, a
327
327
  style={
328
328
  Array [
329
329
  Object {
330
- "backgroundColor": "#001f23",
330
+ "backgroundColor": "#401960",
331
331
  "borderRadius": 999,
332
332
  "height": 16,
333
333
  "opacity": 0.9,
@@ -346,7 +346,7 @@ exports[`StyledSpinnerContainer renders correctly when intent is $themeIntent, a
346
346
  style={
347
347
  Array [
348
348
  Object {
349
- "backgroundColor": "#001f23",
349
+ "backgroundColor": "#401960",
350
350
  "borderRadius": 999,
351
351
  "height": 16,
352
352
  "marginLeft": 8,
@@ -382,7 +382,7 @@ exports[`StyledSpinnerContainer renders correctly when intent is $themeIntent, a
382
382
  style={
383
383
  Array [
384
384
  Object {
385
- "backgroundColor": "#001f23",
385
+ "backgroundColor": "#401960",
386
386
  "borderRadius": 999,
387
387
  "height": 16,
388
388
  "opacity": 0.45,
@@ -401,7 +401,7 @@ exports[`StyledSpinnerContainer renders correctly when intent is $themeIntent, a
401
401
  style={
402
402
  Array [
403
403
  Object {
404
- "backgroundColor": "#001f23",
404
+ "backgroundColor": "#401960",
405
405
  "borderRadius": 999,
406
406
  "height": 16,
407
407
  "marginLeft": 8,
@@ -585,7 +585,7 @@ exports[`StyledSpinnerDot renders correctly when position is bottomLeft, size is
585
585
  style={
586
586
  Array [
587
587
  Object {
588
- "backgroundColor": "#001f23",
588
+ "backgroundColor": "#401960",
589
589
  "borderRadius": 999,
590
590
  "height": 16,
591
591
  "opacity": 0.45,
@@ -625,7 +625,7 @@ exports[`StyledSpinnerDot renders correctly when position is bottomLeft, size is
625
625
  style={
626
626
  Array [
627
627
  Object {
628
- "backgroundColor": "#001f23",
628
+ "backgroundColor": "#401960",
629
629
  "borderRadius": 999,
630
630
  "height": 8,
631
631
  "opacity": 0.45,
@@ -666,7 +666,7 @@ exports[`StyledSpinnerDot renders correctly when position is bottomRight, size i
666
666
  style={
667
667
  Array [
668
668
  Object {
669
- "backgroundColor": "#001f23",
669
+ "backgroundColor": "#401960",
670
670
  "borderRadius": 999,
671
671
  "height": 16,
672
672
  "marginLeft": 8,
@@ -708,7 +708,7 @@ exports[`StyledSpinnerDot renders correctly when position is bottomRight, size i
708
708
  style={
709
709
  Array [
710
710
  Object {
711
- "backgroundColor": "#001f23",
711
+ "backgroundColor": "#401960",
712
712
  "borderRadius": 999,
713
713
  "height": 8,
714
714
  "marginLeft": 4,
@@ -749,7 +749,7 @@ exports[`StyledSpinnerDot renders correctly when position is topLeft, size is me
749
749
  style={
750
750
  Array [
751
751
  Object {
752
- "backgroundColor": "#001f23",
752
+ "backgroundColor": "#401960",
753
753
  "borderRadius": 999,
754
754
  "height": 16,
755
755
  "opacity": 0.9,
@@ -789,7 +789,7 @@ exports[`StyledSpinnerDot renders correctly when position is topLeft, size is sm
789
789
  style={
790
790
  Array [
791
791
  Object {
792
- "backgroundColor": "#001f23",
792
+ "backgroundColor": "#401960",
793
793
  "borderRadius": 999,
794
794
  "height": 8,
795
795
  "opacity": 0.9,
@@ -830,7 +830,7 @@ exports[`StyledSpinnerDot renders correctly when position is topRight, size is m
830
830
  style={
831
831
  Array [
832
832
  Object {
833
- "backgroundColor": "#001f23",
833
+ "backgroundColor": "#401960",
834
834
  "borderRadius": 999,
835
835
  "height": 16,
836
836
  "marginLeft": 8,
@@ -872,7 +872,7 @@ exports[`StyledSpinnerDot renders correctly when position is topRight, size is s
872
872
  style={
873
873
  Array [
874
874
  Object {
875
- "backgroundColor": "#001f23",
875
+ "backgroundColor": "#401960",
876
876
  "borderRadius": 999,
877
877
  "height": 8,
878
878
  "marginLeft": 4,
@@ -56,7 +56,7 @@ exports[`Spinner renders correctly 1`] = `
56
56
  style={
57
57
  Array [
58
58
  Object {
59
- "backgroundColor": "#001f23",
59
+ "backgroundColor": "#401960",
60
60
  "borderRadius": 999,
61
61
  "height": 16,
62
62
  "opacity": 0.9,
@@ -75,7 +75,7 @@ exports[`Spinner renders correctly 1`] = `
75
75
  style={
76
76
  Array [
77
77
  Object {
78
- "backgroundColor": "#001f23",
78
+ "backgroundColor": "#401960",
79
79
  "borderRadius": 999,
80
80
  "height": 16,
81
81
  "marginLeft": 8,
@@ -111,7 +111,7 @@ exports[`Spinner renders correctly 1`] = `
111
111
  style={
112
112
  Array [
113
113
  Object {
114
- "backgroundColor": "#001f23",
114
+ "backgroundColor": "#401960",
115
115
  "borderRadius": 999,
116
116
  "height": 16,
117
117
  "opacity": 0.45,
@@ -130,7 +130,7 @@ exports[`Spinner renders correctly 1`] = `
130
130
  style={
131
131
  Array [
132
132
  Object {
133
- "backgroundColor": "#001f23",
133
+ "backgroundColor": "#401960",
134
134
  "borderRadius": 999,
135
135
  "height": 16,
136
136
  "marginLeft": 8,
@@ -58,7 +58,7 @@ exports[`rendering renders correctly when intent is primary 1`] = `
58
58
  onStartShouldSetResponder={[Function]}
59
59
  style={
60
60
  Object {
61
- "backgroundColor": "#001f23",
61
+ "backgroundColor": "#401960",
62
62
  "flex": 1,
63
63
  "opacity": 1,
64
64
  }
@@ -1,6 +1,11 @@
1
- import React, { ReactNode, useCallback, useEffect, useRef } from 'react';
1
+ import React, {
2
+ ComponentProps,
3
+ ReactNode,
4
+ useCallback,
5
+ useEffect,
6
+ useRef,
7
+ } from 'react';
2
8
  import { Animated, useWindowDimensions } from 'react-native';
3
- import type { SwipeableProps as RnghSwipeableProps } from 'react-native-gesture-handler/Swipeable';
4
9
  import {
5
10
  Swipeable as RnghSwipeable,
6
11
  GestureHandlerRootView,
@@ -9,6 +14,9 @@ import {
9
14
  import SwipeableAction from './SwipeableAction';
10
15
 
11
16
  type State = 'closed' | 'leftOpen' | 'rightOpen';
17
+ // We are supporting both v1 and v2 of RNGH at the same time.
18
+ // SwipeableProps is only exported in v2, so we have to use ComponentProps.
19
+ type RnghSwipeableProps = ComponentProps<typeof RnghSwipeable>;
12
20
  export interface SwipeableProps
13
21
  extends Pick<
14
22
  RnghSwipeableProps,
@@ -53,6 +61,10 @@ export interface SwipeableProps
53
61
  * By default, it will take up the whole width of the device.
54
62
  */
55
63
  rightActionsWidth?: number;
64
+ /**
65
+ * Testing ID of the component
66
+ */
67
+ testID?: string;
56
68
  }
57
69
 
58
70
  const renderActions = (
@@ -46,11 +46,7 @@ const Option = <T,>({
46
46
  return (
47
47
  <StyledTextWrapper>
48
48
  <OptionContent
49
- content={
50
- <Typography.Text fontSize="large" intent="inverted">
51
- {text}
52
- </Typography.Text>
53
- }
49
+ content={<Typography.Text fontSize="large">{text}</Typography.Text>}
54
50
  badge={badge}
55
51
  />
56
52
  </StyledTextWrapper>
@@ -67,7 +67,7 @@ exports[`Option renders correctly when selected 1`] = `
67
67
  Array [
68
68
  Object {
69
69
  "alignItems": "center",
70
- "backgroundColor": "#401960",
70
+ "backgroundColor": "#ffffff",
71
71
  "borderRadius": 999,
72
72
  "flex": 1,
73
73
  "justifyContent": "center",
@@ -88,7 +88,7 @@ exports[`Option renders correctly when selected 1`] = `
88
88
  style={
89
89
  Array [
90
90
  Object {
91
- "color": "#ffffff",
91
+ "color": "#001f23",
92
92
  "fontFamily": "BeVietnamPro-Regular",
93
93
  "fontSize": 16,
94
94
  "letterSpacing": 0.48,
@@ -99,7 +99,7 @@ exports[`Option renders correctly when selected 1`] = `
99
99
  }
100
100
  themeFontSize="large"
101
101
  themeFontWeight="regular"
102
- themeIntent="inverted"
102
+ themeIntent="body"
103
103
  >
104
104
  My Dashboard
105
105
  </Text>
@@ -30,7 +30,7 @@ exports[`SelectorSwitch renders correctly 1`] = `
30
30
  Array [
31
31
  Object {
32
32
  "alignItems": "center",
33
- "backgroundColor": "#401960",
33
+ "backgroundColor": "#ffffff",
34
34
  "borderRadius": 999,
35
35
  "flex": 1,
36
36
  "justifyContent": "center",
@@ -43,7 +43,7 @@ exports[`SelectorSwitch renders correctly 1`] = `
43
43
  style={
44
44
  Array [
45
45
  Object {
46
- "color": "#ffffff",
46
+ "color": "#001f23",
47
47
  "fontFamily": "BeVietnamPro-Regular",
48
48
  "fontSize": 16,
49
49
  "letterSpacing": 0.48,
@@ -54,7 +54,7 @@ exports[`SelectorSwitch renders correctly 1`] = `
54
54
  }
55
55
  themeFontSize="large"
56
56
  themeFontWeight="regular"
57
- themeIntent="inverted"
57
+ themeIntent="body"
58
58
  >
59
59
  My Dashboard
60
60
  </Text>
@@ -23,6 +23,7 @@ describe('SelectorSwitch', () => {
23
23
  },
24
24
  ]}
25
25
  value="employee"
26
+ onPress={jest.fn()}
26
27
  />
27
28
  );
28
29
 
@@ -47,7 +47,10 @@ const SelectorSwitch = <T,>({
47
47
  style,
48
48
  testID,
49
49
  }: SelectorSwitchProps<T>): ReactElement => (
50
- <TouchableWithoutFeedback onPress={() => onPress(value)} testID={testID}>
50
+ <TouchableWithoutFeedback
51
+ onPress={onPress !== undefined ? () => onPress(value) : undefined}
52
+ testID={testID}
53
+ >
51
54
  <StyledWrapper style={style}>
52
55
  {options.map((opt, index) => (
53
56
  // eslint-disable-next-line react/no-array-index-key
@@ -42,7 +42,7 @@ exports[`StyledWrapper renders correct style with variant disabled-checked 1`] =
42
42
  style={
43
43
  Array [
44
44
  Object {
45
- "backgroundColor": "#a08cb0",
45
+ "backgroundColor": "#ece8ef",
46
46
  "borderRadius": 999,
47
47
  "display": "flex",
48
48
  "height": 32,
@@ -39,7 +39,7 @@ const StyledIndicator = styled(Animated.View)<{ themeWidth: number }>(
39
39
  ({ theme, themeWidth }) => ({
40
40
  width: themeWidth,
41
41
  height: theme.__hd__.tabs.sizes.indicator,
42
- backgroundColor: theme.__hd__.tabs.colors.text,
42
+ backgroundColor: theme.__hd__.tabs.colors.indicator,
43
43
  position: 'absolute',
44
44
  bottom: 0,
45
45
  })
@@ -239,7 +239,7 @@ exports[`Tabs.Scroll renders correctly 1`] = `
239
239
  nativeID="animatedComponent"
240
240
  style={
241
241
  Object {
242
- "backgroundColor": "#e6e9e9",
242
+ "backgroundColor": "#ccd2d3",
243
243
  "borderRadius": 8,
244
244
  "flex": 1,
245
245
  "transform": Array [
@@ -405,7 +405,7 @@ exports[`Tabs renders correctly 1`] = `
405
405
  nativeID="animatedComponent"
406
406
  style={
407
407
  Object {
408
- "backgroundColor": "#001f23",
408
+ "backgroundColor": "#401960",
409
409
  "bottom": 0,
410
410
  "height": 2,
411
411
  "position": "absolute",
@@ -44,7 +44,7 @@ exports[`Tag has archived style when intent is primary 1`] = `
44
44
  Array [
45
45
  Object {
46
46
  "backgroundColor": undefined,
47
- "borderColor": "#001f23",
47
+ "borderColor": "#401960",
48
48
  "borderRadius": 4,
49
49
  "borderWidth": 1,
50
50
  "paddingHorizontal": 8,
@@ -59,7 +59,7 @@ exports[`Tag has archived style when intent is primary 1`] = `
59
59
  style={
60
60
  Array [
61
61
  Object {
62
- "color": "#001f23",
62
+ "color": "#401960",
63
63
  "fontFamily": "BeVietnamPro-SemiBold",
64
64
  "fontSize": 12,
65
65
  "includeFontPadding": false,
@@ -89,6 +89,7 @@ const StyledTextInput = styled(TextInput)(({ theme }) => ({
89
89
  alignSelf: 'stretch',
90
90
  flexGrow: 2,
91
91
  marginHorizontal: theme.__hd__.textInput.space.inputHorizontalMargin,
92
+ paddingVertical: 0,
92
93
  }));
93
94
 
94
95
  const StyledBorderBackDrop = styled(View)<{
@@ -125,7 +125,7 @@ exports[`Label renders correctly with themeVariant readonly 1`] = `
125
125
  },
126
126
  Array [
127
127
  Object {
128
- "color": "#bfc1c5",
128
+ "color": "#808f91",
129
129
  },
130
130
  undefined,
131
131
  ],
@@ -302,7 +302,7 @@ exports[`LabelInsideTextInput renders correctly with themeVariant readonly 1`] =
302
302
  Object {
303
303
  "alignContent": "center",
304
304
  "alignItems": "center",
305
- "color": "#bfc1c5",
305
+ "color": "#808f91",
306
306
  "fontSize": 14,
307
307
  "textAlignVertical": "center",
308
308
  },
@@ -332,7 +332,7 @@ exports[`StyledAsteriskLabel renders correctly with themeVariant default 1`] = `
332
332
  },
333
333
  Array [
334
334
  Object {
335
- "color": "#f46363",
335
+ "color": "#de350b",
336
336
  },
337
337
  undefined,
338
338
  ],
@@ -388,7 +388,7 @@ exports[`StyledAsteriskLabel renders correctly with themeVariant error 1`] = `
388
388
  },
389
389
  Array [
390
390
  Object {
391
- "color": "#f46363",
391
+ "color": "#de350b",
392
392
  },
393
393
  undefined,
394
394
  ],
@@ -416,7 +416,7 @@ exports[`StyledAsteriskLabel renders correctly with themeVariant filled 1`] = `
416
416
  },
417
417
  Array [
418
418
  Object {
419
- "color": "#f46363",
419
+ "color": "#de350b",
420
420
  },
421
421
  undefined,
422
422
  ],
@@ -464,7 +464,7 @@ exports[`StyledBorderBackDrop renders correctly when focused 1`] = `
464
464
  style={
465
465
  Array [
466
466
  Object {
467
- "borderColor": "#f46363",
467
+ "borderColor": "#de350b",
468
468
  "borderRadius": 8,
469
469
  "borderWidth": 2,
470
470
  "bottom": 0,
@@ -530,7 +530,7 @@ exports[`StyledBorderBackDrop renders correctly with themeVariant error 1`] = `
530
530
  style={
531
531
  Array [
532
532
  Object {
533
- "borderColor": "#f46363",
533
+ "borderColor": "#de350b",
534
534
  "borderRadius": 8,
535
535
  "borderWidth": 1,
536
536
  "bottom": 0,
@@ -604,7 +604,7 @@ exports[`StyledErrorMessage renders correctly 1`] = `
604
604
  },
605
605
  Array [
606
606
  Object {
607
- "color": "#f46363",
607
+ "color": "#de350b",
608
608
  "fontSize": 12,
609
609
  "marginLeft": 4,
610
610
  },
@@ -752,7 +752,7 @@ exports[`StyledMaxLengthMessage renders correctly with themeVariant error 1`] =
752
752
  Array [
753
753
  Object {
754
754
  "alignSelf": "flex-end",
755
- "color": "#f46363",
755
+ "color": "#de350b",
756
756
  "flex": 1,
757
757
  "flexGrow": 1,
758
758
  "fontSize": 12,
@@ -820,7 +820,7 @@ exports[`StyledMaxLengthMessage renders correctly with themeVariant readonly 1`]
820
820
  Array [
821
821
  Object {
822
822
  "alignSelf": "flex-end",
823
- "color": "#bfc1c5",
823
+ "color": "#808f91",
824
824
  "flex": 1,
825
825
  "flexGrow": 1,
826
826
  "fontSize": 12,
@@ -849,6 +849,7 @@ exports[`StyledTextInput renders correctly 1`] = `
849
849
  "flexGrow": 2,
850
850
  "fontSize": 14,
851
851
  "marginHorizontal": 8,
852
+ "paddingVertical": 0,
852
853
  "textAlignVertical": "center",
853
854
  },
854
855
  undefined,