@utilitywarehouse/hearth-react-native 0.4.1 → 0.5.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 (205) hide show
  1. package/.turbo/turbo-build.log +1 -1
  2. package/.turbo/turbo-lint.log +1 -1
  3. package/CHANGELOG.md +54 -0
  4. package/build/components/Alert/AlertTitle.js +6 -6
  5. package/build/components/Badge/Badge.js +3 -3
  6. package/build/components/Badge/Badge.props.d.ts +1 -0
  7. package/build/components/Button/ButtonRoot.js +4 -0
  8. package/build/components/Button/ButtonText.js +2 -2
  9. package/build/components/Card/CardRoot.js +1 -1
  10. package/build/components/Carousel/Carousel.context.d.ts +4 -0
  11. package/build/components/Carousel/Carousel.context.js +4 -0
  12. package/build/components/Carousel/Carousel.d.ts +6 -0
  13. package/build/components/Carousel/Carousel.js +278 -0
  14. package/build/components/Carousel/Carousel.props.d.ts +65 -0
  15. package/build/components/Carousel/Carousel.props.js +1 -0
  16. package/build/components/Carousel/CarouselControlItem.d.ts +24 -0
  17. package/build/components/Carousel/CarouselControlItem.js +64 -0
  18. package/build/components/Carousel/CarouselControls.d.ts +4 -0
  19. package/build/components/Carousel/CarouselControls.js +74 -0
  20. package/build/components/Carousel/CarouselItem.d.ts +6 -0
  21. package/build/components/Carousel/CarouselItem.js +38 -0
  22. package/build/components/Carousel/index.d.ts +5 -0
  23. package/build/components/Carousel/index.js +5 -0
  24. package/build/components/Checkbox/CheckboxTextContent.d.ts +1 -1
  25. package/build/components/Checkbox/CheckboxTextContent.js +9 -2
  26. package/build/components/CurrencyInput/CurrencyInput.d.ts +1 -1
  27. package/build/components/CurrencyInput/CurrencyInput.js +3 -3
  28. package/build/components/CurrencyInput/CurrencyInput.props.d.ts +2 -2
  29. package/build/components/DescriptionList/DescriptionList.d.ts +1 -1
  30. package/build/components/DescriptionList/DescriptionList.js +2 -2
  31. package/build/components/DescriptionList/DescriptionList.props.d.ts +1 -8
  32. package/build/components/DescriptionList/DescriptionListItem.d.ts +1 -1
  33. package/build/components/DescriptionList/DescriptionListItem.js +4 -3
  34. package/build/components/DescriptionList/DescriptionListItem.props.d.ts +3 -8
  35. package/build/components/IndicatorIconButton/IndicatorIconButton.d.ts +6 -0
  36. package/build/components/IndicatorIconButton/IndicatorIconButton.js +26 -0
  37. package/build/components/IndicatorIconButton/IndicatorIconButton.props.d.ts +8 -0
  38. package/build/components/IndicatorIconButton/IndicatorIconButton.props.js +1 -0
  39. package/build/components/IndicatorIconButton/index.d.ts +2 -0
  40. package/build/components/IndicatorIconButton/index.js +1 -0
  41. package/build/components/Link/LinkText.js +3 -3
  42. package/build/components/List/List.context.d.ts +0 -2
  43. package/build/components/List/List.d.ts +1 -1
  44. package/build/components/List/List.js +5 -5
  45. package/build/components/List/List.props.d.ts +1 -9
  46. package/build/components/List/ListAction/ListAction.d.ts +18 -0
  47. package/build/components/List/ListAction/ListAction.js +103 -0
  48. package/build/components/List/ListAction/ListAction.props.d.ts +8 -0
  49. package/build/components/List/ListAction/ListAction.props.js +1 -0
  50. package/build/components/List/ListAction/ListActionContent.d.ts +6 -0
  51. package/build/components/List/ListAction/ListActionContent.js +14 -0
  52. package/build/components/List/ListAction/ListActionText.d.ts +6 -0
  53. package/build/components/List/ListAction/ListActionText.js +7 -0
  54. package/build/components/List/ListAction/ListActionTrailingContent.d.ts +6 -0
  55. package/build/components/List/ListAction/ListActionTrailingContent.js +5 -0
  56. package/build/components/List/ListAction/ListActionTrailingIcon.d.ts +9 -0
  57. package/build/components/List/ListAction/ListActionTrailingIcon.js +18 -0
  58. package/build/components/List/ListAction/index.d.ts +6 -0
  59. package/build/components/List/ListAction/index.js +5 -0
  60. package/build/components/List/ListItem/ListItem.context.d.ts +1 -1
  61. package/build/components/List/ListItem/ListItem.props.d.ts +9 -5
  62. package/build/components/List/ListItem/ListItemRoot.d.ts +1 -1
  63. package/build/components/List/ListItem/ListItemRoot.js +10 -12
  64. package/build/components/List/ListItem/index.d.ts +4 -4
  65. package/build/components/List/ListItem/index.js +3 -3
  66. package/build/components/List/index.d.ts +1 -0
  67. package/build/components/List/index.js +1 -0
  68. package/build/components/ProgressStepper/ProgressStep.d.ts +10 -0
  69. package/build/components/ProgressStepper/ProgressStep.js +100 -0
  70. package/build/components/ProgressStepper/ProgressStepper.d.ts +6 -0
  71. package/build/components/ProgressStepper/ProgressStepper.js +22 -0
  72. package/build/components/ProgressStepper/ProgressStepper.props.d.ts +22 -0
  73. package/build/components/ProgressStepper/ProgressStepper.props.js +1 -0
  74. package/build/components/ProgressStepper/ProgressStepperRoot.d.ts +6 -0
  75. package/build/components/ProgressStepper/ProgressStepperRoot.js +16 -0
  76. package/build/components/ProgressStepper/index.d.ts +3 -0
  77. package/build/components/ProgressStepper/index.js +2 -0
  78. package/build/components/Radio/RadioTextContent.d.ts +1 -1
  79. package/build/components/Radio/RadioTextContent.js +9 -2
  80. package/build/components/SectionHeader/SectionHeader.d.ts +1 -1
  81. package/build/components/SectionHeader/SectionHeader.js +6 -3
  82. package/build/components/SectionHeader/SectionHeader.props.d.ts +9 -16
  83. package/build/components/SectionHeader/SectionHeaderTrailingContent.d.ts +6 -0
  84. package/build/components/SectionHeader/SectionHeaderTrailingContent.js +13 -0
  85. package/build/components/SectionHeader/index.d.ts +1 -0
  86. package/build/components/SectionHeader/index.js +1 -0
  87. package/build/components/Tabs/Tab.js +2 -2
  88. package/build/components/ToggleButton/ToggleButtonText.js +2 -2
  89. package/build/components/UnstyledIconButton/UnstyledIconButton.props.d.ts +4 -1
  90. package/build/components/index.d.ts +3 -0
  91. package/build/components/index.js +3 -0
  92. package/build/core/themes.d.ts +12 -24
  93. package/build/tokens/components/dark/button.d.ts +1 -1
  94. package/build/tokens/components/dark/button.js +1 -1
  95. package/build/tokens/components/dark/dialog.d.ts +1 -0
  96. package/build/tokens/components/dark/dialog.js +1 -0
  97. package/build/tokens/components/dark/illustrations.d.ts +1 -0
  98. package/build/tokens/components/dark/illustrations.js +1 -0
  99. package/build/tokens/components/dark/toast.d.ts +4 -1
  100. package/build/tokens/components/dark/toast.js +4 -1
  101. package/build/tokens/components/light/button.d.ts +1 -1
  102. package/build/tokens/components/light/button.js +1 -1
  103. package/build/tokens/components/light/dialog.d.ts +1 -0
  104. package/build/tokens/components/light/dialog.js +1 -0
  105. package/build/tokens/components/light/illustrations.d.ts +1 -0
  106. package/build/tokens/components/light/illustrations.js +1 -0
  107. package/build/tokens/components/light/toast.d.ts +4 -1
  108. package/build/tokens/components/light/toast.js +4 -1
  109. package/build/tokens/layout.d.ts +6 -12
  110. package/build/tokens/layout.js +3 -6
  111. package/build/utils/getFlattenedColorValue.js +2 -19
  112. package/build/utils/index.d.ts +1 -0
  113. package/build/utils/index.js +1 -0
  114. package/build/utils/styleUtils.d.ts +0 -4
  115. package/build/utils/styleUtils.js +0 -50
  116. package/build/utils/themeValueHelpers.d.ts +17 -0
  117. package/build/utils/themeValueHelpers.js +54 -0
  118. package/docs/components/AllComponents.web.tsx +86 -4
  119. package/docs/components/BadgeList.tsx +20 -56
  120. package/docs/components/SwitchList.tsx +4 -8
  121. package/docs/getting-started.mdx +37 -13
  122. package/docs/introduction.mdx +51 -6
  123. package/package.json +7 -7
  124. package/src/components/Alert/AlertTitle.tsx +7 -7
  125. package/src/components/Badge/Badge.props.ts +1 -0
  126. package/src/components/Badge/Badge.tsx +3 -2
  127. package/src/components/Button/ButtonRoot.tsx +4 -0
  128. package/src/components/Button/ButtonText.tsx +3 -3
  129. package/src/components/Card/CardRoot.tsx +2 -0
  130. package/src/components/Carousel/Carousel.context.tsx +8 -0
  131. package/src/components/Carousel/Carousel.docs.mdx +389 -0
  132. package/src/components/Carousel/Carousel.props.ts +89 -0
  133. package/src/components/Carousel/Carousel.stories.tsx +317 -0
  134. package/src/components/Carousel/Carousel.tsx +444 -0
  135. package/src/components/Carousel/CarouselControlItem.tsx +87 -0
  136. package/src/components/Carousel/CarouselControls.tsx +150 -0
  137. package/src/components/Carousel/CarouselItem.tsx +68 -0
  138. package/src/components/Carousel/index.ts +6 -0
  139. package/src/components/Checkbox/CheckboxTextContent.tsx +11 -3
  140. package/src/components/CurrencyInput/CurrencyInput.docs.mdx +4 -4
  141. package/src/components/CurrencyInput/CurrencyInput.props.ts +2 -2
  142. package/src/components/CurrencyInput/CurrencyInput.stories.tsx +17 -15
  143. package/src/components/CurrencyInput/CurrencyInput.tsx +3 -3
  144. package/src/components/DescriptionList/DescriptionList.docs.mdx +24 -27
  145. package/src/components/DescriptionList/DescriptionList.props.ts +1 -8
  146. package/src/components/DescriptionList/DescriptionList.stories.tsx +13 -19
  147. package/src/components/DescriptionList/DescriptionList.tsx +2 -14
  148. package/src/components/DescriptionList/DescriptionListItem.props.ts +3 -8
  149. package/src/components/DescriptionList/DescriptionListItem.tsx +13 -21
  150. package/src/components/IndicatorIconButton/IndicatorIconButton.docs.mdx +85 -0
  151. package/src/components/IndicatorIconButton/IndicatorIconButton.props.ts +12 -0
  152. package/src/components/IndicatorIconButton/IndicatorIconButton.stories.tsx +142 -0
  153. package/src/components/IndicatorIconButton/IndicatorIconButton.tsx +36 -0
  154. package/src/components/IndicatorIconButton/index.tsx +2 -0
  155. package/src/components/Link/LinkText.tsx +4 -4
  156. package/src/components/List/List.context.ts +0 -1
  157. package/src/components/List/List.docs.mdx +376 -179
  158. package/src/components/List/List.props.ts +1 -9
  159. package/src/components/List/List.stories.tsx +289 -38
  160. package/src/components/List/List.tsx +5 -26
  161. package/src/components/List/ListAction/ListAction.props.ts +10 -0
  162. package/src/components/List/ListAction/ListAction.tsx +133 -0
  163. package/src/components/List/ListAction/ListActionContent.tsx +21 -0
  164. package/src/components/List/ListAction/ListActionText.tsx +14 -0
  165. package/src/components/List/ListAction/ListActionTrailingContent.tsx +9 -0
  166. package/src/components/List/ListAction/ListActionTrailingIcon.tsx +32 -0
  167. package/src/components/List/ListAction/index.ts +6 -0
  168. package/src/components/List/ListItem/ListItem.context.ts +1 -1
  169. package/src/components/List/ListItem/ListItem.props.ts +9 -5
  170. package/src/components/List/ListItem/ListItemRoot.tsx +18 -14
  171. package/src/components/List/ListItem/index.ts +4 -4
  172. package/src/components/List/index.ts +1 -0
  173. package/src/components/ProgressStepper/ProgressStep.tsx +134 -0
  174. package/src/components/ProgressStepper/ProgressStepper.docs.mdx +87 -0
  175. package/src/components/ProgressStepper/ProgressStepper.props.ts +27 -0
  176. package/src/components/ProgressStepper/ProgressStepper.stories.tsx +108 -0
  177. package/src/components/ProgressStepper/ProgressStepper.tsx +26 -0
  178. package/src/components/ProgressStepper/ProgressStepperRoot.tsx +32 -0
  179. package/src/components/ProgressStepper/index.ts +3 -0
  180. package/src/components/Radio/RadioTextContent.tsx +11 -3
  181. package/src/components/SectionHeader/SectionHeader.props.ts +9 -16
  182. package/src/components/SectionHeader/SectionHeader.stories.tsx +28 -18
  183. package/src/components/SectionHeader/SectionHeader.tsx +18 -19
  184. package/src/components/SectionHeader/SectionHeaderTrailingContent.tsx +20 -0
  185. package/src/components/SectionHeader/Sectionheader.docs.mdx +9 -24
  186. package/src/components/SectionHeader/index.ts +1 -0
  187. package/src/components/Switch/Switch.docs.mdx +0 -4
  188. package/src/components/Tabs/Tab.tsx +4 -2
  189. package/src/components/ToggleButton/ToggleButtonText.tsx +3 -3
  190. package/src/components/UnstyledIconButton/UnstyledIconButton.props.ts +2 -1
  191. package/src/components/index.ts +3 -0
  192. package/src/tokens/components/dark/button.ts +1 -1
  193. package/src/tokens/components/dark/dialog.ts +1 -0
  194. package/src/tokens/components/dark/illustrations.ts +1 -0
  195. package/src/tokens/components/dark/toast.ts +4 -1
  196. package/src/tokens/components/light/button.ts +1 -1
  197. package/src/tokens/components/light/dialog.ts +1 -0
  198. package/src/tokens/components/light/illustrations.ts +1 -0
  199. package/src/tokens/components/light/toast.ts +4 -1
  200. package/src/tokens/layout.ts +3 -6
  201. package/src/utils/getFlattenedColorValue.ts +2 -21
  202. package/src/utils/getStyleValue.ts +0 -3
  203. package/src/utils/index.ts +1 -0
  204. package/src/utils/styleUtils.ts +0 -57
  205. package/src/utils/themeValueHelpers.ts +60 -0
@@ -2,6 +2,7 @@ import { Meta, StoryObj } from '@storybook/react-vite';
2
2
  import { SettingsMediumIcon } from '@utilitywarehouse/hearth-react-native-icons';
3
3
  import { VariantTitle } from '../../../docs/components';
4
4
  import { Flex } from '../Flex';
5
+ import { Link } from '../Link';
5
6
  import SectionHeader from './SectionHeader';
6
7
 
7
8
  const meta = {
@@ -16,15 +17,10 @@ const meta = {
16
17
  control: 'text',
17
18
  description: 'The heading supporting text to be displayed.',
18
19
  },
19
- linkText: {
20
- control: 'text',
21
- description: 'Link text to display',
22
- },
23
20
  },
24
21
  args: {
25
22
  heading: 'This is the section heading',
26
23
  helperText: 'Helper text',
27
- linkText: 'See more',
28
24
  },
29
25
  } satisfies Meta<typeof SectionHeader>;
30
26
 
@@ -33,13 +29,7 @@ type Story = StoryObj<typeof meta>;
33
29
 
34
30
  export const Playground: Story = {
35
31
  render: () => {
36
- return (
37
- <SectionHeader
38
- heading="This is the section heading"
39
- helperText="Helper text"
40
- linkText="See more"
41
- />
42
- );
32
+ return <SectionHeader heading="This is the section heading" helperText="Helper text" />;
43
33
  },
44
34
  };
45
35
 
@@ -51,23 +41,43 @@ export const KitchenSink: Story = {
51
41
  return (
52
42
  <Flex space="xl" direction="column" style={{ width: '100%' }}>
53
43
  <VariantTitle title="Default SectionHeader with helper text and link">
54
- <SectionHeader heading="Heading" helperText="Helper text" linkText="See more" />
44
+ <SectionHeader
45
+ heading="Heading"
46
+ helperText="Helper text"
47
+ trailingContent={<Link>See more</Link>}
48
+ />
55
49
  </VariantTitle>
56
50
  <VariantTitle title="SectionHeader with icon on the left of the link ">
57
51
  <SectionHeader
58
52
  heading="Heading"
59
53
  helperText="Helper text"
60
- linkText="Settings"
61
- linkIcon={SettingsMediumIcon}
62
- linkIconPosition="left"
54
+ trailingContent={
55
+ <Link icon={SettingsMediumIcon} iconPosition="left">
56
+ Settings
57
+ </Link>
58
+ }
63
59
  />
64
60
  </VariantTitle>
65
61
  <VariantTitle title="SectionHeader with no icon">
66
62
  <SectionHeader
67
63
  heading="Heading"
68
64
  helperText="Helper text"
69
- linkText="Call to action"
70
- linkShowIcon={false}
65
+ trailingContent={<Link showIcon={false}>Call to action</Link>}
66
+ />
67
+ </VariantTitle>
68
+ <VariantTitle title="SectionHeader with badge">
69
+ <SectionHeader
70
+ heading="Heading"
71
+ helperText="Helper text"
72
+ badge={{ text: "I'm a badge" }}
73
+ />
74
+ </VariantTitle>
75
+ <VariantTitle title="SectionHeader with badge and link">
76
+ <SectionHeader
77
+ heading="Heading"
78
+ helperText="Helper text"
79
+ trailingContent={<Link>Show more</Link>}
80
+ badge={{ text: 'New' }}
71
81
  />
72
82
  </VariantTitle>
73
83
  </Flex>
@@ -1,23 +1,22 @@
1
+ import { ErrorCircleSmallIcon } from '@utilitywarehouse/hearth-react-native-icons';
1
2
  import { View } from 'react-native';
2
3
  import { StyleSheet } from 'react-native-unistyles';
3
- import { Link } from '../Link';
4
+ import { Badge } from '../Badge';
5
+ import { Helper } from '../Helper';
4
6
  import SectionHeaderProps from './SectionHeader.props';
5
7
  import SectionHeaderTitle from './SectionHeaderHeading';
6
8
  import SectionHeaderHelperText from './SectionHeaderHelperText';
7
9
  import SectionHeaderTextContent from './SectionHeaderTextContent';
10
+ import SectionHeaderTrailingContent from './SectionHeaderTrailingContent';
8
11
 
9
12
  const SectionHeader = ({
10
13
  heading,
11
14
  helperText,
12
15
  children,
13
16
  style,
14
- linkHref,
15
- linkIcon,
16
- linkIconPosition,
17
- linkOnPress,
18
- linkShowIcon,
19
- linkTarget,
20
- linkText,
17
+ trailingContent,
18
+ badge,
19
+ invalidText,
21
20
  ...props
22
21
  }: SectionHeaderProps) => {
23
22
  return (
@@ -29,18 +28,18 @@ const SectionHeader = ({
29
28
  <SectionHeaderTextContent>
30
29
  <SectionHeaderTitle>{heading}</SectionHeaderTitle>
31
30
  {!!helperText && <SectionHeaderHelperText>{helperText}</SectionHeaderHelperText>}
31
+ {!!invalidText && (
32
+ <Helper
33
+ validationStatus="invalid"
34
+ showIcon
35
+ icon={ErrorCircleSmallIcon}
36
+ text={invalidText || ''}
37
+ />
38
+ )}
32
39
  </SectionHeaderTextContent>
33
- {!!linkText && (
34
- <Link
35
- href={linkHref}
36
- onPress={linkOnPress}
37
- icon={linkIcon}
38
- showIcon={linkShowIcon}
39
- iconPosition={linkIconPosition}
40
- target={linkTarget}
41
- >
42
- {linkText}
43
- </Link>
40
+ {!!badge && <Badge {...badge} />}
41
+ {!!trailingContent && (
42
+ <SectionHeaderTrailingContent>{trailingContent}</SectionHeaderTrailingContent>
44
43
  )}
45
44
  </>
46
45
  )}
@@ -0,0 +1,20 @@
1
+ import { View, type ViewProps } from 'react-native';
2
+ import { StyleSheet } from 'react-native-unistyles';
3
+
4
+ const SectionHeaderTrailingContent = ({ children, ...props }: ViewProps) => {
5
+ return (
6
+ <View {...props} style={[styles.container, props.style]}>
7
+ {children}
8
+ </View>
9
+ );
10
+ };
11
+
12
+ SectionHeaderTrailingContent.displayName = 'SectionHeaderTrailingContent';
13
+
14
+ const styles = StyleSheet.create({
15
+ container: {
16
+ alignSelf: 'flex-start',
17
+ },
18
+ });
19
+
20
+ export default SectionHeaderTrailingContent;
@@ -26,7 +26,7 @@ Use the `Section Header` component to help define and separate content within a
26
26
 
27
27
  ## Anatomy
28
28
 
29
- Section Header consists of: Heading, Helper Text and Link
29
+ Section Header consists of: Heading, Helper Text, a Badge (optional) and a trailing content (optional, usually a Link or Button).
30
30
 
31
31
  ### Heading
32
32
 
@@ -42,41 +42,26 @@ A helper text property is included in the component to be able to add helper tex
42
42
 
43
43
  Use helper text when users need extra clarity or explanation before engaging with the section.
44
44
 
45
- ### Link
46
-
47
- The Section Header component includes an optional Link that provides users with a related navigation option.
48
-
49
- Use the Link to provide a shortcut to additional details or a more comprehensive view.
50
-
51
- Use when users may need to navigate away or view extended content (e.g. view all)
52
-
53
45
  ## Usage
54
46
 
55
47
  <UsageWrap>
56
- <SectionHeader heading="Heading" helperText="Helper text" linkText="See more" />
48
+ <SectionHeader heading="Heading" helperText="Helper text" />
57
49
  </UsageWrap>
58
50
 
59
51
  ```tsx
60
52
  import { SectionHeader } from '@utilitywarehouse/hearth-react-native';
61
53
 
62
- const MyComponent = () => (
63
- <SectionHeader heading="Heading" helperText="Helper text" linkText="See more" />
64
- );
54
+ const MyComponent = () => <SectionHeader heading="Heading" helperText="Helper text" />;
65
55
  ```
66
56
 
67
57
  ## Props
68
58
 
69
- | Name | Type | Default | Description |
70
- | ---------------- | -------------------------------------------- | ---------- | ------------------------------------------------------ |
71
- | heading | `string` | | The text to display in the heading of the list. |
72
- | helperText | `string` | | The helper text to display in the heading of the list. |
73
- | linkText | `string` | | The text for the link in the heading. |
74
- | linkHref | `string` | | The href for the link in the heading. |
75
- | linkOnPress | `() => void` | | Callback function when the link is pressed. |
76
- | linkTarget | `'_blank' \| '_self' \| '_parent' \| '_top'` | `'_blank'` | Target for the link in the heading. |
77
- | linkIcon | `ComponentType` | | Icon for the link. |
78
- | linkIconPosition | `'left' \| 'right'` | `'right'` | Position of the icon in the link. |
79
- | linkShowIcon | `boolean` | `true` | Whether to show the icon in the link. |
59
+ | Name | Type | Default | Description |
60
+ | --------------- | ----------------- | ------- | ------------------------------------------------------ |
61
+ | heading | `string` | | The text to display in the heading of the list. |
62
+ | helperText | `string` | | The helper text to display in the heading of the list. |
63
+ | trailingContent | `React.ReactNode` | | Optional content to display on the right side. |
64
+ | badge | `BadgeProps` | | Optional badge to display next to the heading. |
80
65
 
81
66
  ## Variants
82
67
 
@@ -2,3 +2,4 @@ export { default as SectionHeader } from './SectionHeader';
2
2
  export { default as SectionHeaderHeading } from './SectionHeaderHeading';
3
3
  export { default as SectionHeaderHelperText } from './SectionHeaderHelperText';
4
4
  export { default as SectionHeaderTextContent } from './SectionHeaderTextContent';
5
+ export { default as SectionHeaderTrailingContent } from './SectionHeaderTrailingContent';
@@ -137,7 +137,6 @@ const SwitchList = () => {
137
137
  <ListItem
138
138
  text="Notifications"
139
139
  helperText="Allow notifications"
140
- divider
141
140
  leadingContent={<ListItemIcon as={BellMediumIcon} />}
142
141
  trailingContent={
143
142
  <Switch value={notifications} onValueChange={setNotifications} size="small" />
@@ -147,7 +146,6 @@ const SwitchList = () => {
147
146
  <ListItem
148
147
  text="Secure ID"
149
148
  helperText="Use secure ID"
150
- divider
151
149
  leadingContent={<ListItemIcon as={LockMediumIcon} />}
152
150
  trailingContent={<Switch value={secureId} onValueChange={setSecureId} size="small" />}
153
151
  onPress={() => setSecureId(!secureId)}
@@ -155,7 +153,6 @@ const SwitchList = () => {
155
153
  <ListItem
156
154
  text="Location"
157
155
  helperText="Allow location"
158
- divider
159
156
  leadingContent={<ListItemIcon as={LocationMediumIcon} />}
160
157
  trailingContent={<Switch value={location} onValueChange={setLocation} size="small" />}
161
158
  onPress={() => setLocation(!location)}
@@ -163,7 +160,6 @@ const SwitchList = () => {
163
160
  <ListItem
164
161
  text="Dark mode"
165
162
  helperText="Enable dark mode"
166
- divider
167
163
  leadingContent={<ListItemIcon as={EyeMediumIcon} />}
168
164
  trailingContent={<Switch value={darkMode} onValueChange={setDarkMode} size="small" />}
169
165
  onPress={() => setDarkMode(!darkMode)}
@@ -1,12 +1,12 @@
1
1
  import { useCallback, useRef } from 'react';
2
2
  import { Platform, Pressable, View } from 'react-native';
3
3
  import { StyleSheet } from 'react-native-unistyles';
4
- import { DetailText } from '../DetailText';
5
4
  import { Icon } from '../Icon';
6
5
  import type TabProps from './Tab.props';
7
6
  import { useTabsContext } from './Tabs.context';
8
7
 
9
8
  import { createPressable } from '@gluestack-ui/pressable';
9
+ import { BodyText } from '../BodyText';
10
10
 
11
11
  const Tab = ({
12
12
  value,
@@ -54,7 +54,9 @@ const Tab = ({
54
54
  >
55
55
  <View style={styles.content}>
56
56
  {icon ? <Icon as={icon} /> : null}
57
- <DetailText size={size}>{children}</DetailText>
57
+ <BodyText size={size} weight="semibold">
58
+ {children}
59
+ </BodyText>
58
60
  </View>
59
61
  </Pressable>
60
62
  );
@@ -1,13 +1,13 @@
1
1
  import { type TextProps } from 'react-native';
2
2
  import { StyleSheet } from 'react-native-unistyles';
3
- import { DetailText } from '../DetailText';
3
+ import { BodyText } from '../BodyText';
4
4
 
5
5
  const ToggleButtonText = ({ children, toggled, ...props }: TextProps & { toggled: boolean }) => {
6
6
  styles.useVariants({ toggled });
7
7
  return (
8
- <DetailText size="md" {...props} style={[styles.text, props.style]}>
8
+ <BodyText size="md" weight="semibold" {...props} style={[styles.text, props.style]}>
9
9
  {children}
10
- </DetailText>
10
+ </BodyText>
11
11
  );
12
12
  };
13
13
 
@@ -1,5 +1,6 @@
1
1
  import type { ComponentType } from 'react';
2
2
  import type { PressableProps, ViewProps } from 'react-native';
3
+ import { ColorValue } from '../../types';
3
4
 
4
5
  export type UnstyledIconButtonProps = {
5
6
  /*
@@ -29,5 +30,5 @@ export type UnstyledIconButtonProps = {
29
30
  */
30
31
  inverted?: boolean;
31
32
  children?: React.ReactNode;
32
- iconStyle?: ViewProps['style'];
33
+ iconStyle?: ViewProps['style'] & { color?: ColorValue };
33
34
  } & PressableProps;
@@ -7,6 +7,7 @@ export * from './BottomSheet';
7
7
  export * from './Box';
8
8
  export * from './Button';
9
9
  export * from './Card';
10
+ export * from './Carousel';
10
11
  export * from './Center';
11
12
  export * from './Checkbox';
12
13
  export * from './CurrencyInput';
@@ -24,12 +25,14 @@ export * from './HTMLElements';
24
25
  export * from './Icon';
25
26
  export * from './IconButton';
26
27
  export * from './IconContainer';
28
+ export * from './IndicatorIconButton';
27
29
  export * from './InlineLink';
28
30
  export * from './Input';
29
31
  export * from './Label';
30
32
  export * from './Link';
31
33
  export * from './List';
32
34
  export * from './Modal';
35
+ export * from './ProgressStepper';
33
36
  export * from './Radio';
34
37
  export * from './RadioCard';
35
38
  export * from './SectionHeader';
@@ -10,7 +10,7 @@ export default {
10
10
  paddingHorizontal: 16,
11
11
  paddingVertical: 12,
12
12
  },
13
- minWidth: 80,
13
+ minWidth: 30,
14
14
  shadowColor: '#101010',
15
15
  sm: {
16
16
  paddingHorizontal: 16,
@@ -9,6 +9,7 @@ export default {
9
9
  borderRadius: 16,
10
10
  content: {
11
11
  gap: 12,
12
+ paddingBottom: 12,
12
13
  },
13
14
  gap: 24,
14
15
  padding: 24,
@@ -3,5 +3,6 @@
3
3
  */
4
4
 
5
5
  export default {
6
+ colorMode: 'dark',
6
7
  mode: 'dark',
7
8
  } as const;
@@ -5,6 +5,9 @@
5
5
  export default {
6
6
  backgroundColor: '#3f3f3f',
7
7
  borderRadius: 8,
8
- gapHorizontal: 8,
8
+ gapHorizontal: 16,
9
9
  padding: 14,
10
+ stack: {
11
+ gapHorizontal: 8,
12
+ },
10
13
  } as const;
@@ -10,7 +10,7 @@ export default {
10
10
  paddingHorizontal: 16,
11
11
  paddingVertical: 12,
12
12
  },
13
- minWidth: 80,
13
+ minWidth: 30,
14
14
  shadowColor: '#101010',
15
15
  sm: {
16
16
  paddingHorizontal: 16,
@@ -9,6 +9,7 @@ export default {
9
9
  borderRadius: 16,
10
10
  content: {
11
11
  gap: 12,
12
+ paddingBottom: 12,
12
13
  },
13
14
  gap: 24,
14
15
  padding: 24,
@@ -3,5 +3,6 @@
3
3
  */
4
4
 
5
5
  export default {
6
+ colorMode: 'light',
6
7
  mode: 'light',
7
8
  } as const;
@@ -5,6 +5,9 @@
5
5
  export default {
6
6
  backgroundColor: '#101010',
7
7
  borderRadius: 8,
8
- gapHorizontal: 8,
8
+ gapHorizontal: 16,
9
9
  padding: 14,
10
+ stack: {
11
+ gapHorizontal: 8,
12
+ },
10
13
  } as const;
@@ -8,8 +8,8 @@ export const mobile = {
8
8
  minWidth: 320,
9
9
  },
10
10
  container: {
11
+ margin: 16,
11
12
  paddingBottom: 32,
12
- paddingHorizontal: 16,
13
13
  paddingTop: 24,
14
14
  width: 360,
15
15
  },
@@ -18,7 +18,6 @@ export const mobile = {
18
18
  columnWidth: 64,
19
19
  gridSize: 8,
20
20
  gutter: 16,
21
- margin: 16,
22
21
  },
23
22
  spacing: {
24
23
  '2xl': 28,
@@ -38,8 +37,8 @@ export const tablet = {
38
37
  minWidth: 740,
39
38
  },
40
39
  container: {
40
+ margin: 32,
41
41
  paddingBottom: 32,
42
- paddingHorizontal: 32,
43
42
  paddingTop: 24,
44
43
  width: 744,
45
44
  },
@@ -48,7 +47,6 @@ export const tablet = {
48
47
  columnWidth: 64,
49
48
  gridSize: 8,
50
49
  gutter: 24,
51
- margin: 32,
52
50
  },
53
51
  spacing: {
54
52
  '2xl': 28,
@@ -68,8 +66,8 @@ export const desktop = {
68
66
  minWidth: 992,
69
67
  },
70
68
  container: {
69
+ margin: 32,
71
70
  paddingBottom: 48,
72
- paddingHorizontal: 32,
73
71
  paddingTop: 32,
74
72
  width: 1096,
75
73
  },
@@ -78,7 +76,6 @@ export const desktop = {
78
76
  columnWidth: 64,
79
77
  gridSize: 8,
80
78
  gutter: 24,
81
- margin: 32,
82
79
  },
83
80
  spacing: {
84
81
  '2xl': 40,
@@ -1,4 +1,5 @@
1
1
  import { ColorValue } from '../types';
2
+ import { resolveThemeValue } from './themeValueHelpers';
2
3
 
3
4
  type ThemeColor = string | { [key: string]: string | ThemeColor };
4
5
 
@@ -8,25 +9,5 @@ export default function getFlattenedColorValue(
8
9
  ): ColorValue {
9
10
  if (!value) return undefined;
10
11
 
11
- if (colors?.[value] && typeof colors?.[value] === 'string') {
12
- return colors?.[value] as ColorValue;
13
- }
14
-
15
- // Extract trailing digits as shade
16
- const shadeMatch = value.match(/\d+$/);
17
-
18
- if (!shadeMatch) return value as ColorValue;
19
- const shade = shadeMatch[0];
20
- const base = value.slice(0, -shade.length);
21
-
22
- if (shade && typeof base !== 'string') return value as ColorValue;
23
-
24
- const colorEntry = colors?.[base];
25
-
26
- if (typeof colorEntry === 'object') {
27
- return (colorEntry[shade] ?? value) as ColorValue;
28
- } else if (typeof colorEntry === 'string') {
29
- return colorEntry as ColorValue;
30
- }
31
- return value as ColorValue;
12
+ return resolveThemeValue(value, colors) as ColorValue;
32
13
  }
@@ -1,6 +1,3 @@
1
-
2
-
3
-
4
1
  const getStyleValue = (value: any, type: Record<string, any>) => {
5
2
  if (typeof value === 'string') {
6
3
  const key = value;
@@ -5,3 +5,4 @@ export { default as getStyleValue } from './getStyleValue';
5
5
  export { default as hexWithOpacity } from './hexWithOpacity';
6
6
  export { default as isEqual } from './isEqual';
7
7
  export * from './styleUtils';
8
+ export * from './themeValueHelpers';
@@ -231,60 +231,3 @@ export const viewStyleProps = new Set<string>([
231
231
  // Z-index
232
232
  'zIndex',
233
233
  ]);
234
-
235
- /**
236
- * Helper function to convert camelCase back to nested object path
237
- * e.g., feedbackDangerSurfaceDefault -> ['feedback', 'danger', 'surface', 'default']
238
- */
239
- const camelCaseToPath = (camelCased: string): string[] => {
240
- // Split on uppercase letters but keep them
241
- const parts = camelCased.split(/(?=[A-Z])/).map(part => part.toLowerCase());
242
- return parts;
243
- };
244
-
245
- /**
246
- * Helper function to get nested value from object using path array
247
- */
248
- const getNestedValue = (obj: any, path: string[]): any => {
249
- return path.reduce((current, key) => {
250
- return current && typeof current === 'object' ? current[key] : undefined;
251
- }, obj);
252
- };
253
-
254
- /**
255
- * Helper function to resolve a theme value
256
- */
257
- export const resolveThemeValue = (value: any, themeMapping: any): any => {
258
- if (typeof value !== 'string' || !themeMapping || typeof themeMapping !== 'object') {
259
- return value;
260
- }
261
-
262
- // First, try direct lookup for simple values
263
- if (themeMapping[value] !== undefined) {
264
- return themeMapping[value];
265
- }
266
-
267
- // Try camelCase to nested path conversion (e.g., feedbackDangerSurfaceDefault)
268
- if (/^[a-z][a-zA-Z]*$/.test(value)) {
269
- // Only camelCase strings without numbers
270
- const path = camelCaseToPath(value);
271
- const nestedValue = getNestedValue(themeMapping, path);
272
- if (nestedValue !== undefined) {
273
- return nestedValue;
274
- }
275
- }
276
-
277
- // Then, try the existing numeric suffix pattern (e.g., broadbandBlue100)
278
- const shadeMatch = value.match(/\d+$/);
279
- if (shadeMatch) {
280
- const shade = shadeMatch[0];
281
- const base = value.slice(0, -shade.length);
282
- const nested = themeMapping[base];
283
- if (nested && typeof nested === 'object') {
284
- return nested[shade] ?? value;
285
- }
286
- }
287
-
288
- // If none of the approaches work, return the original value
289
- return value;
290
- };
@@ -0,0 +1,60 @@
1
+ /**
2
+ * Helper function to convert camelCase back to nested object path
3
+ * e.g., feedbackDangerSurfaceDefault -> ['feedback', 'danger', 'surface', 'default']
4
+ */
5
+ export const camelCaseToPath = (camelCased: string): string[] => {
6
+ // Split on uppercase letters but keep them
7
+ const parts = camelCased.split(/(?=[A-Z])/).map(part => part.toLowerCase());
8
+ return parts;
9
+ };
10
+
11
+ /**
12
+ * Helper function to get nested value from object using path array
13
+ */
14
+ export const getNestedValue = (obj: any, path: string[]): any => {
15
+ return path.reduce((current, key) => {
16
+ return current && typeof current === 'object' ? current[key] : undefined;
17
+ }, obj);
18
+ };
19
+
20
+ /**
21
+ * Helper function to resolve a theme value
22
+ * Supports:
23
+ * - Direct lookup (value -> themeMapping[value])
24
+ * - Camel case to nested path (feedbackDangerSurfaceDefault -> themeMapping.feedback.danger.surface.default)
25
+ * - Numeric suffix pattern (broadbandBlue100 -> themeMapping.broadbandBlue[100])
26
+ */
27
+ export const resolveThemeValue = (value: any, themeMapping: any): any => {
28
+ if (typeof value !== 'string' || !themeMapping || typeof themeMapping !== 'object') {
29
+ return value;
30
+ }
31
+
32
+ // First, try direct lookup for simple values
33
+ if (themeMapping[value] !== undefined) {
34
+ return themeMapping[value];
35
+ }
36
+
37
+ // Try camelCase to nested path conversion (e.g., feedbackDangerSurfaceDefault)
38
+ if (/^[a-z][a-zA-Z]*$/.test(value)) {
39
+ // Only camelCase strings without numbers
40
+ const path = camelCaseToPath(value);
41
+ const nestedValue = getNestedValue(themeMapping, path);
42
+ if (nestedValue !== undefined) {
43
+ return nestedValue;
44
+ }
45
+ }
46
+
47
+ // Then, try the existing numeric suffix pattern (e.g., broadbandBlue100)
48
+ const shadeMatch = value.match(/\d+$/);
49
+ if (shadeMatch) {
50
+ const shade = shadeMatch[0];
51
+ const base = value.slice(0, -shade.length);
52
+ const nested = themeMapping[base];
53
+ if (nested && typeof nested === 'object') {
54
+ return nested[shade] ?? value;
55
+ }
56
+ }
57
+
58
+ // If none of the approaches work, return the original value
59
+ return value;
60
+ };