@hero-design/rn 8.73.1 → 8.74.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 (35) hide show
  1. package/.turbo/turbo-build.log +3 -3
  2. package/CHANGELOG.md +6 -0
  3. package/es/index.js +6 -3
  4. package/lib/index.js +6 -3
  5. package/package.json +1 -1
  6. package/src/components/Icon/HeroIcon/index.tsx +3 -1
  7. package/src/components/Icon/__tests__/__snapshots__/index.spec.tsx.snap +405 -0
  8. package/src/components/Icon/__tests__/index.spec.tsx +14 -2
  9. package/src/components/Icon/index.tsx +2 -1
  10. package/src/components/Typography/Body/__tests__/__snapshots__/index.spec.tsx.snap +51 -0
  11. package/src/components/Typography/Body/__tests__/index.spec.tsx +1 -0
  12. package/src/components/Typography/Body/index.tsx +2 -1
  13. package/src/components/Typography/Caption/__tests__/__snapshots__/index.spec.tsx.snap +50 -0
  14. package/src/components/Typography/Caption/__tests__/index.spec.tsx +1 -0
  15. package/src/components/Typography/Caption/index.tsx +2 -1
  16. package/src/components/Typography/Label/__tests__/__snapshots__/index.spec.tsx.snap +48 -0
  17. package/src/components/Typography/Label/__tests__/index.spec.tsx +1 -0
  18. package/src/components/Typography/Label/index.tsx +2 -1
  19. package/src/components/Typography/Title/__tests__/__snapshots__/index.spec.tsx.snap +51 -0
  20. package/src/components/Typography/Title/__tests__/index.spec.tsx +1 -0
  21. package/src/components/Typography/Title/index.tsx +2 -1
  22. package/src/components/Typography/types.ts +2 -1
  23. package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +2 -0
  24. package/src/theme/components/icon.ts +1 -0
  25. package/src/theme/components/typography.ts +1 -0
  26. package/stats/8.74.0/rn-stats.html +4842 -0
  27. package/types/components/Icon/HeroIcon/index.d.ts +1 -1
  28. package/types/components/Icon/index.d.ts +1 -1
  29. package/types/components/Typography/Body/index.d.ts +1 -1
  30. package/types/components/Typography/Caption/index.d.ts +1 -1
  31. package/types/components/Typography/Label/index.d.ts +1 -1
  32. package/types/components/Typography/Title/index.d.ts +1 -1
  33. package/types/components/Typography/types.d.ts +1 -1
  34. package/types/theme/components/icon.d.ts +1 -0
  35. package/types/theme/components/typography.d.ts +1 -0
@@ -30,7 +30,8 @@ export interface CaptionProps extends NativeTextProps {
30
30
  | 'danger'
31
31
  | 'inverted'
32
32
  | 'archived'
33
- | 'disabled';
33
+ | 'disabled'
34
+ | 'muted';
34
35
  /**
35
36
  * Additional style.
36
37
  */
@@ -288,6 +288,54 @@ exports[`Label has inverted intent style 1`] = `
288
288
  </View>
289
289
  `;
290
290
 
291
+ exports[`Label has muted intent style 1`] = `
292
+ <View
293
+ style={
294
+ {
295
+ "flex": 1,
296
+ }
297
+ }
298
+ >
299
+ <Text
300
+ allowFontScaling={false}
301
+ style={
302
+ [
303
+ {
304
+ "color": "#4d6265",
305
+ "fontSize": 10,
306
+ "letterSpacing": 0,
307
+ "lineHeight": 14,
308
+ },
309
+ undefined,
310
+ ]
311
+ }
312
+ themeIntent="muted"
313
+ >
314
+ This is a test
315
+ </Text>
316
+ <View
317
+ pointerEvents="box-none"
318
+ position="bottom"
319
+ style={
320
+ [
321
+ {
322
+ "bottom": 0,
323
+ "elevation": 9999,
324
+ "flexDirection": "column-reverse",
325
+ "left": 0,
326
+ "paddingHorizontal": 24,
327
+ "paddingVertical": 16,
328
+ "position": "absolute",
329
+ "right": 0,
330
+ "top": 0,
331
+ },
332
+ undefined,
333
+ ]
334
+ }
335
+ />
336
+ </View>
337
+ `;
338
+
291
339
  exports[`Label has primary intent style 1`] = `
292
340
  <View
293
341
  style={
@@ -22,6 +22,7 @@ describe('Label', () => {
22
22
  ${'inverted'}
23
23
  ${'archived'}
24
24
  ${'disabled'}
25
+ ${'muted'}
25
26
  `('has $intent intent style', ({ intent }) => {
26
27
  const { toJSON } = renderWithTheme(
27
28
  <Label intent={intent}>This is a test</Label>
@@ -26,7 +26,8 @@ export interface LabelProps extends NativeTextProps {
26
26
  | 'danger'
27
27
  | 'inverted'
28
28
  | 'archived'
29
- | 'disabled';
29
+ | 'disabled'
30
+ | 'muted';
30
31
  /**
31
32
  * Additional style.
32
33
  */
@@ -918,6 +918,57 @@ exports[`Title has inverted intent style 1`] = `
918
918
  </View>
919
919
  `;
920
920
 
921
+ exports[`Title has muted intent style 1`] = `
922
+ <View
923
+ style={
924
+ {
925
+ "flex": 1,
926
+ }
927
+ }
928
+ >
929
+ <Text
930
+ allowFontScaling={false}
931
+ style={
932
+ [
933
+ {
934
+ "color": "#4d6265",
935
+ "fontFamily": "BeVietnamPro-Regular",
936
+ "fontSize": 42,
937
+ "letterSpacing": 0,
938
+ "lineHeight": 50,
939
+ },
940
+ undefined,
941
+ ]
942
+ }
943
+ themeIntent="muted"
944
+ themeLevel="h1"
945
+ themeTypeface="neutral"
946
+ >
947
+ This is a test
948
+ </Text>
949
+ <View
950
+ pointerEvents="box-none"
951
+ position="bottom"
952
+ style={
953
+ [
954
+ {
955
+ "bottom": 0,
956
+ "elevation": 9999,
957
+ "flexDirection": "column-reverse",
958
+ "left": 0,
959
+ "paddingHorizontal": 24,
960
+ "paddingVertical": 16,
961
+ "position": "absolute",
962
+ "right": 0,
963
+ "top": 0,
964
+ },
965
+ undefined,
966
+ ]
967
+ }
968
+ />
969
+ </View>
970
+ `;
971
+
921
972
  exports[`Title has primary intent style 1`] = `
922
973
  <View
923
974
  style={
@@ -22,6 +22,7 @@ describe('Title', () => {
22
22
  ${'inverted'}
23
23
  ${'archived'}
24
24
  ${'disabled'}
25
+ ${'muted'}
25
26
  `('has $intent intent style', ({ intent }) => {
26
27
  const { toJSON } = renderWithTheme(
27
28
  <Title intent={intent}>This is a test</Title>
@@ -26,7 +26,8 @@ export interface TitleProps extends NativeTextProps {
26
26
  | 'danger'
27
27
  | 'inverted'
28
28
  | 'archived'
29
- | 'disabled';
29
+ | 'disabled'
30
+ | 'muted';
30
31
  /**
31
32
  * Additional style.
32
33
  */
@@ -15,4 +15,5 @@ export type ThemeIntent =
15
15
  | 'danger'
16
16
  | 'inverted'
17
17
  | 'archived'
18
- | 'disabled';
18
+ | 'disabled'
19
+ | 'muted';
@@ -596,6 +596,7 @@ exports[`theme returns correct theme object 1`] = `
596
596
  "disabledText": "#bfc1c5",
597
597
  "info": "#b5c3fd",
598
598
  "invertedText": "#ffffff",
599
+ "muted": "#4d6265",
599
600
  "primary": "#401960",
600
601
  "secondary": "#795e90",
601
602
  "success": "#5ace7d",
@@ -1310,6 +1311,7 @@ exports[`theme returns correct theme object 1`] = `
1310
1311
  "disabled": "#bfc1c5",
1311
1312
  "info": "#355bfb",
1312
1313
  "inverted": "#ffffff",
1314
+ "muted": "#4d6265",
1313
1315
  "primary": "#401960",
1314
1316
  "secondary": "#795e90",
1315
1317
  "subdued": "#4d6265",
@@ -11,6 +11,7 @@ const getIconTheme = (theme: GlobalTheme) => {
11
11
  warning: theme.colors.warning,
12
12
  disabledText: theme.colors.disabledOnDefaultGlobalSurface,
13
13
  invertedText: theme.colors.onDarkGlobalSurface,
14
+ muted: theme.colors.mutedOnDefaultGlobalSurface,
14
15
  };
15
16
 
16
17
  const sizes = {
@@ -13,6 +13,7 @@ const getTypographyTheme = (theme: GlobalTheme) => {
13
13
  inverted: theme.colors.onDarkGlobalSurface,
14
14
  archived: theme.colors.onArchivedSurface,
15
15
  disabled: theme.colors.disabledOnDefaultGlobalSurface,
16
+ muted: theme.colors.mutedOnDefaultGlobalSurface,
16
17
  };
17
18
 
18
19
  const fontSizes = {