@hero-design/rn 8.12.2 → 8.12.3

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.
@@ -1,9 +1,9 @@
1
- @hero-design/rn:build: cache hit, replaying output 11fbf9e3773167e6
2
- @hero-design/rn:build: $ yarn build:js && yarn build:types
3
- @hero-design/rn:build: $ rollup -c
4
- @hero-design/rn:build: 
5
- @hero-design/rn:build: src/index.ts → lib/index.js, es/index.js...
6
- @hero-design/rn:build: (!) Plugin replace: @rollup/plugin-replace: 'preventAssignment' currently defaults to false. It is recommended to set this option to `true`, as the next major version will default this option to `true`.
7
- @hero-design/rn:build: (!) Plugin node-resolve: preferring built-in module 'events' over local alternative at '/root/hero-design/node_modules/events/events.js', pass 'preferBuiltins: false' to disable this behavior or 'preferBuiltins: true' to disable this warning
8
- @hero-design/rn:build: created lib/index.js, es/index.js in 24.8s
9
- @hero-design/rn:build: $ tsc --noEmit false --emitDeclarationOnly --project tsconfig.prod.json
1
+ @hero-design/rn:build: cache hit, replaying output eea1c2ee08c7c3cf
2
+ @hero-design/rn:build: $ yarn build:js && yarn build:types
3
+ @hero-design/rn:build: $ rollup -c
4
+ @hero-design/rn:build: 
5
+ @hero-design/rn:build: src/index.ts → lib/index.js, es/index.js...
6
+ @hero-design/rn:build: (!) Plugin replace: @rollup/plugin-replace: 'preventAssignment' currently defaults to false. It is recommended to set this option to `true`, as the next major version will default this option to `true`.
7
+ @hero-design/rn:build: (!) Plugin node-resolve: preferring built-in module 'events' over local alternative at '/root/hero-design/node_modules/events/events.js', pass 'preferBuiltins: false' to disable this behavior or 'preferBuiltins: true' to disable this warning
8
+ @hero-design/rn:build: created lib/index.js, es/index.js in 31.1s
9
+ @hero-design/rn:build: $ tsc --noEmit false --emitDeclarationOnly --project tsconfig.prod.json
package/es/index.js CHANGED
@@ -969,7 +969,7 @@ var blue$1 = colorScales.blue,
969
969
  purple$1 = colorScales.purple,
970
970
  vermilion$3 = colorScales.vermilion,
971
971
  smalt = colorScales.smalt,
972
- violet$2 = colorScales.violet,
972
+ violet$1 = colorScales.violet,
973
973
  yellow$1 = colorScales.yellow;
974
974
  ({
975
975
  black: '#000000',
@@ -1042,16 +1042,16 @@ var blue$1 = colorScales.blue,
1042
1042
  smaltLight45: smalt.lighten45,
1043
1043
  smaltLight75: smalt.lighten75,
1044
1044
  smaltLight90: smalt.lighten90,
1045
- violet: violet$2.base,
1046
- violetDark15: violet$2.darken15,
1047
- violetDark30: violet$2.darken30,
1048
- violetDark45: violet$2.darken45,
1049
- violetDark60: violet$2.darken60,
1050
- violetDark75: violet$2.darken75,
1051
- violetLight30: violet$2.lighten30,
1052
- violetLight60: violet$2.lighten60,
1053
- violetLight75: violet$2.lighten75,
1054
- violetLight90: violet$2.lighten90,
1045
+ violet: violet$1.base,
1046
+ violetDark15: violet$1.darken15,
1047
+ violetDark30: violet$1.darken30,
1048
+ violetDark45: violet$1.darken45,
1049
+ violetDark60: violet$1.darken60,
1050
+ violetDark75: violet$1.darken75,
1051
+ violetLight30: violet$1.lighten30,
1052
+ violetLight60: violet$1.lighten60,
1053
+ violetLight75: violet$1.lighten75,
1054
+ violetLight90: violet$1.lighten90,
1055
1055
  yellow: yellow$1.base,
1056
1056
  yellowDark15: yellow$1.darken15,
1057
1057
  yellowDark75: yellow$1.darken75,
@@ -1191,8 +1191,8 @@ var currant$1 = colorScales.currant,
1191
1191
  pastelRed = colorScales.pastelRed,
1192
1192
  vermilion = colorScales.vermilion,
1193
1193
  mauve$3 = colorScales.mauve,
1194
- violet1$2 = colorScales.violet1,
1195
- violet$1 = colorScales.violet,
1194
+ violet1$3 = colorScales.violet1,
1195
+ violet$2 = colorScales.violet,
1196
1196
  scarletGum$2 = colorScales.scarletGum;
1197
1197
  var palette$6 = {
1198
1198
  currant: currant$1.base,
@@ -1211,18 +1211,18 @@ var palette$6 = {
1211
1211
  pastelRed: pastelRed.base,
1212
1212
  vermilion: vermilion.base,
1213
1213
  mauve: mauve$3.base,
1214
- violetLight30: violet$1.lighten30,
1215
- violet1: violet1$2.base,
1216
- violet: violet$1.base,
1214
+ violetLight30: violet$2.lighten30,
1215
+ violet1: violet1$3.base,
1216
+ violet: violet$2.base,
1217
1217
  scarletGum: scarletGum$2.base
1218
1218
  };
1219
- var violet$3 = colorScales.violet,
1219
+ var violet1$2 = colorScales.violet1,
1220
1220
  mauve$2 = colorScales.mauve;
1221
1221
  var palette$5 = Object.assign(Object.assign({}, palette$8), {
1222
- violet: violet$3.base,
1223
- violetLight20: violet$3.lighten20,
1224
- violetLight30: violet$3.lighten30,
1225
- violetLight90: violet$3.lighten90,
1222
+ violet: violet1$2.base,
1223
+ violetLight20: violet1$2.lighten20,
1224
+ violetLight30: violet1$2.lighten30,
1225
+ violetLight90: violet1$2.lighten90,
1226
1226
  mauve: mauve$2.base,
1227
1227
  mauveLight80: mauve$2.lighten80
1228
1228
  });
@@ -2869,6 +2869,7 @@ var getTypographyTheme = function getTypographyTheme(theme) {
2869
2869
  archived: theme.colors.onArchivedSurface
2870
2870
  };
2871
2871
  var fontSizes = {
2872
+ xsmall: theme.fontSizes.xsmall,
2872
2873
  small: theme.fontSizes.small,
2873
2874
  medium: theme.fontSizes.medium,
2874
2875
  large: theme.fontSizes.large,
@@ -2880,6 +2881,7 @@ var getTypographyTheme = function getTypographyTheme(theme) {
2880
2881
  '7xlarge': theme.fontSizes['7xlarge']
2881
2882
  };
2882
2883
  var lineHeights = {
2884
+ xsmall: theme.lineHeights.xsmall,
2883
2885
  small: theme.lineHeights.small,
2884
2886
  medium: theme.lineHeights.medium,
2885
2887
  large: theme.lineHeights.large,
package/lib/index.js CHANGED
@@ -998,7 +998,7 @@ var blue$1 = colorScales.blue,
998
998
  purple$1 = colorScales.purple,
999
999
  vermilion$3 = colorScales.vermilion,
1000
1000
  smalt = colorScales.smalt,
1001
- violet$2 = colorScales.violet,
1001
+ violet$1 = colorScales.violet,
1002
1002
  yellow$1 = colorScales.yellow;
1003
1003
  ({
1004
1004
  black: '#000000',
@@ -1071,16 +1071,16 @@ var blue$1 = colorScales.blue,
1071
1071
  smaltLight45: smalt.lighten45,
1072
1072
  smaltLight75: smalt.lighten75,
1073
1073
  smaltLight90: smalt.lighten90,
1074
- violet: violet$2.base,
1075
- violetDark15: violet$2.darken15,
1076
- violetDark30: violet$2.darken30,
1077
- violetDark45: violet$2.darken45,
1078
- violetDark60: violet$2.darken60,
1079
- violetDark75: violet$2.darken75,
1080
- violetLight30: violet$2.lighten30,
1081
- violetLight60: violet$2.lighten60,
1082
- violetLight75: violet$2.lighten75,
1083
- violetLight90: violet$2.lighten90,
1074
+ violet: violet$1.base,
1075
+ violetDark15: violet$1.darken15,
1076
+ violetDark30: violet$1.darken30,
1077
+ violetDark45: violet$1.darken45,
1078
+ violetDark60: violet$1.darken60,
1079
+ violetDark75: violet$1.darken75,
1080
+ violetLight30: violet$1.lighten30,
1081
+ violetLight60: violet$1.lighten60,
1082
+ violetLight75: violet$1.lighten75,
1083
+ violetLight90: violet$1.lighten90,
1084
1084
  yellow: yellow$1.base,
1085
1085
  yellowDark15: yellow$1.darken15,
1086
1086
  yellowDark75: yellow$1.darken75,
@@ -1220,8 +1220,8 @@ var currant$1 = colorScales.currant,
1220
1220
  pastelRed = colorScales.pastelRed,
1221
1221
  vermilion = colorScales.vermilion,
1222
1222
  mauve$3 = colorScales.mauve,
1223
- violet1$2 = colorScales.violet1,
1224
- violet$1 = colorScales.violet,
1223
+ violet1$3 = colorScales.violet1,
1224
+ violet$2 = colorScales.violet,
1225
1225
  scarletGum$2 = colorScales.scarletGum;
1226
1226
  var palette$6 = {
1227
1227
  currant: currant$1.base,
@@ -1240,18 +1240,18 @@ var palette$6 = {
1240
1240
  pastelRed: pastelRed.base,
1241
1241
  vermilion: vermilion.base,
1242
1242
  mauve: mauve$3.base,
1243
- violetLight30: violet$1.lighten30,
1244
- violet1: violet1$2.base,
1245
- violet: violet$1.base,
1243
+ violetLight30: violet$2.lighten30,
1244
+ violet1: violet1$3.base,
1245
+ violet: violet$2.base,
1246
1246
  scarletGum: scarletGum$2.base
1247
1247
  };
1248
- var violet$3 = colorScales.violet,
1248
+ var violet1$2 = colorScales.violet1,
1249
1249
  mauve$2 = colorScales.mauve;
1250
1250
  var palette$5 = Object.assign(Object.assign({}, palette$8), {
1251
- violet: violet$3.base,
1252
- violetLight20: violet$3.lighten20,
1253
- violetLight30: violet$3.lighten30,
1254
- violetLight90: violet$3.lighten90,
1251
+ violet: violet1$2.base,
1252
+ violetLight20: violet1$2.lighten20,
1253
+ violetLight30: violet1$2.lighten30,
1254
+ violetLight90: violet1$2.lighten90,
1255
1255
  mauve: mauve$2.base,
1256
1256
  mauveLight80: mauve$2.lighten80
1257
1257
  });
@@ -2898,6 +2898,7 @@ var getTypographyTheme = function getTypographyTheme(theme) {
2898
2898
  archived: theme.colors.onArchivedSurface
2899
2899
  };
2900
2900
  var fontSizes = {
2901
+ xsmall: theme.fontSizes.xsmall,
2901
2902
  small: theme.fontSizes.small,
2902
2903
  medium: theme.fontSizes.medium,
2903
2904
  large: theme.fontSizes.large,
@@ -2909,6 +2910,7 @@ var getTypographyTheme = function getTypographyTheme(theme) {
2909
2910
  '7xlarge': theme.fontSizes['7xlarge']
2910
2911
  };
2911
2912
  var lineHeights = {
2913
+ xsmall: theme.lineHeights.xsmall,
2912
2914
  small: theme.lineHeights.small,
2913
2915
  medium: theme.lineHeights.medium,
2914
2916
  large: theme.lineHeights.large,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@hero-design/rn",
3
- "version": "8.12.2",
3
+ "version": "8.12.3",
4
4
  "license": "MIT",
5
5
  "main": "lib/index.js",
6
6
  "module": "es/index.js",
@@ -21,7 +21,7 @@
21
21
  "dependencies": {
22
22
  "@emotion/native": "^11.9.3",
23
23
  "@emotion/react": "^11.9.3",
24
- "@hero-design/colors": "8.12.2",
24
+ "@hero-design/colors": "8.12.3",
25
25
  "date-fns": "^2.16.1",
26
26
  "events": "^3.2.0",
27
27
  "hero-editor": "^1.9.21"
@@ -44,7 +44,7 @@
44
44
  "@babel/preset-typescript": "^7.17.12",
45
45
  "@babel/runtime": "^7.18.9",
46
46
  "@emotion/jest": "^11.9.3",
47
- "@hero-design/eslint-plugin": "8.12.2",
47
+ "@hero-design/eslint-plugin": "8.12.3",
48
48
  "@react-native-community/datetimepicker": "^3.5.2",
49
49
  "@react-native-community/slider": "4.1.12",
50
50
  "@rollup/plugin-babel": "^5.3.1",
@@ -60,9 +60,9 @@
60
60
  "@types/react-native": "^0.67.7",
61
61
  "@types/react-native-vector-icons": "^6.4.10",
62
62
  "babel-plugin-inline-import": "^3.0.0",
63
- "eslint-config-hd": "8.12.2",
63
+ "eslint-config-hd": "8.12.3",
64
64
  "jest": "^27.3.1",
65
- "prettier-config-hd": "8.12.2",
65
+ "prettier-config-hd": "8.12.3",
66
66
  "react": "18.0.0",
67
67
  "react-native": "0.69.7",
68
68
  "react-native-gesture-handler": "~2.1.0",
@@ -355,7 +355,7 @@ exports[`Tabs renders correctly 1`] = `
355
355
  themeIntent="body"
356
356
  themeTypeface="neutral"
357
357
  >
358
- Wallet
358
+ Money
359
359
  </Text>
360
360
  <View
361
361
  collapsable={false}
@@ -584,7 +584,7 @@ exports[`Tabs renders correctly 1`] = `
584
584
  }
585
585
  >
586
586
  <Text>
587
- Wallet Screen
587
+ Money Screen
588
588
  </Text>
589
589
  </View>
590
590
  </View>
@@ -35,9 +35,9 @@ const TestTabsComponent = (
35
35
  },
36
36
  },
37
37
  {
38
- key: 'wallet',
39
- activeItem: 'Wallet',
40
- component: <Text>Wallet Screen</Text>,
38
+ key: 'money',
39
+ activeItem: 'Money',
40
+ component: <Text>Money Screen</Text>,
41
41
  badge: {
42
42
  type: 'counter',
43
43
  value: 50,
@@ -82,8 +82,8 @@ describe('Tabs', () => {
82
82
  expect(getByText('Home Screen')).toBeDefined();
83
83
  fireEvent.press(getByText('Move to Work'));
84
84
  expect(getByText('Work Screen')).toBeDefined();
85
- fireEvent.press(getByText('Wallet'));
86
- expect(getByText('Wallet Screen')).toBeDefined();
85
+ fireEvent.press(getByText('Money'));
86
+ expect(getByText('Money Screen')).toBeDefined();
87
87
  expect(getByText('50')).toBeDefined();
88
88
  });
89
89
 
@@ -9,6 +9,7 @@ const FONTWEIGHT_MAP = {
9
9
 
10
10
  const StyledText = styled(Text)<{
11
11
  themeFontSize:
12
+ | 'xsmall'
12
13
  | 'small'
13
14
  | 'medium'
14
15
  | 'large'
@@ -5,6 +5,7 @@ import { StyledText } from '../StyledText';
5
5
  describe('StyledText', () => {
6
6
  it.each`
7
7
  fontSize
8
+ ${'xsmall'}
8
9
  ${'small'}
9
10
  ${'medium'}
10
11
  ${'large'}
@@ -391,6 +391,29 @@ exports[`StyledText has xlarge fontSize style 1`] = `
391
391
  </Text>
392
392
  `;
393
393
 
394
+ exports[`StyledText has xsmall fontSize style 1`] = `
395
+ <Text
396
+ style={
397
+ Array [
398
+ Object {
399
+ "color": "#001f23",
400
+ "fontFamily": "BeVietnamPro-Regular",
401
+ "fontSize": 10,
402
+ "letterSpacing": 0.3,
403
+ "lineHeight": 18,
404
+ },
405
+ undefined,
406
+ ]
407
+ }
408
+ themeFontSize="xsmall"
409
+ themeFontWeight="regular"
410
+ themeIntent="body"
411
+ themeTypeface="neutral"
412
+ >
413
+ This is a test
414
+ </Text>
415
+ `;
416
+
394
417
  exports[`StyledText has xxxlarge fontSize style 1`] = `
395
418
  <Text
396
419
  style={
@@ -16,6 +16,7 @@ export interface TextProps extends NativeTextProps {
16
16
  * Size of the text.
17
17
  */
18
18
  fontSize?:
19
+ | 'xsmall'
19
20
  | 'small'
20
21
  | 'medium'
21
22
  | 'large'
@@ -982,6 +982,7 @@ Object {
982
982
  "medium": 14,
983
983
  "small": 12,
984
984
  "xlarge": 18,
985
+ "xsmall": 10,
985
986
  "xxxlarge": 24,
986
987
  "xxxxlarge": 28,
987
988
  "xxxxxlarge": 32,
@@ -1005,6 +1006,7 @@ Object {
1005
1006
  "medium": 22,
1006
1007
  "small": 20,
1007
1008
  "xlarge": 26,
1009
+ "xsmall": 18,
1008
1010
  "xxxlarge": 32,
1009
1011
  "xxxxlarge": 36,
1010
1012
  "xxxxxlarge": 40,
@@ -15,6 +15,7 @@ const getTypographyTheme = (theme: GlobalTheme) => {
15
15
  };
16
16
 
17
17
  const fontSizes = {
18
+ xsmall: theme.fontSizes.xsmall,
18
19
  small: theme.fontSizes.small,
19
20
  medium: theme.fontSizes.medium,
20
21
  large: theme.fontSizes.large,
@@ -27,6 +28,7 @@ const getTypographyTheme = (theme: GlobalTheme) => {
27
28
  };
28
29
 
29
30
  const lineHeights = {
31
+ xsmall: theme.lineHeights.xsmall,
30
32
  small: theme.lineHeights.small,
31
33
  medium: theme.lineHeights.medium,
32
34
  large: theme.lineHeights.large,
@@ -13,7 +13,7 @@ Object {
13
13
  "disabledOutline": "#bfc1c5",
14
14
  "error": "#f46363",
15
15
  "errorSurface": "#fcebe7",
16
- "highlightedSurface": "#f1e9fb",
16
+ "highlightedSurface": "#f3e6f6",
17
17
  "inactiveOnDefaultGlobalSurface": "#808f91",
18
18
  "inactiveOutline": "#808f91",
19
19
  "info": "#b5c3fd",
@@ -35,10 +35,10 @@ Object {
35
35
  "onSuccessSurface": "#017d6d",
36
36
  "onWarningSurface": "#ffa234",
37
37
  "overlayGlobalSurface": "#000000",
38
- "pressedSurface": "#914edf",
39
- "primary": "#7622d7",
38
+ "pressedSurface": "#9d37b5",
39
+ "primary": "#8505a2",
40
40
  "primaryOutline": "#001f23",
41
- "secondary": "#9f64e3",
41
+ "secondary": "#aa50be",
42
42
  "secondaryOutline": "#e8e9ea",
43
43
  "success": "#5ace7d",
44
44
  "successSurface": "#f0fef4",
@@ -4,7 +4,7 @@ declare const StyledText: import("@emotion/native").StyledComponent<import("reac
4
4
  theme?: import("@emotion/react").Theme | undefined;
5
5
  as?: import("react").ElementType<any> | undefined;
6
6
  } & {
7
- themeFontSize: 'small' | 'medium' | 'large' | 'xlarge' | 'xxxlarge' | 'xxxxlarge' | 'xxxxxlarge' | '6xlarge' | '7xlarge';
7
+ themeFontSize: 'xsmall' | 'small' | 'medium' | 'large' | 'xlarge' | 'xxxlarge' | 'xxxxlarge' | 'xxxxxlarge' | '6xlarge' | '7xlarge';
8
8
  themeFontWeight: 'light' | 'regular' | 'semi-bold';
9
9
  themeIntent: 'body' | 'subdued' | 'primary' | 'secondary' | 'success' | 'info' | 'warning' | 'danger' | 'inverted' | 'archived';
10
10
  themeTypeface: 'neutral' | 'playful';
@@ -8,7 +8,7 @@ export interface TextProps extends NativeTextProps {
8
8
  /**
9
9
  * Size of the text.
10
10
  */
11
- fontSize?: 'small' | 'medium' | 'large' | 'xlarge' | 'xxxlarge' | 'xxxxlarge' | 'xxxxxlarge' | '6xlarge' | '7xlarge';
11
+ fontSize?: 'xsmall' | 'small' | 'medium' | 'large' | 'xlarge' | 'xxxlarge' | 'xxxxlarge' | 'xxxxxlarge' | '6xlarge' | '7xlarge';
12
12
  /**
13
13
  * Font weight of the text.
14
14
  */
@@ -14,6 +14,7 @@ declare const getTypographyTheme: (theme: GlobalTheme) => {
14
14
  };
15
15
  fonts: import("../global/typography").Fonts;
16
16
  fontSizes: {
17
+ xsmall: number;
17
18
  small: number;
18
19
  medium: number;
19
20
  large: number;
@@ -25,6 +26,7 @@ declare const getTypographyTheme: (theme: GlobalTheme) => {
25
26
  '7xlarge': number;
26
27
  };
27
28
  lineHeights: {
29
+ xsmall: number;
28
30
  small: number;
29
31
  medium: number;
30
32
  large: number;