@hero-design/rn 7.23.0 → 7.24.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.
- package/.turbo/turbo-build.log +2 -2
- package/assets/fonts/hero-icons.ttf +0 -0
- package/es/index.js +857 -8825
- package/lib/assets/fonts/hero-icons.ttf +0 -0
- package/lib/index.js +858 -8824
- package/package.json +6 -4
- package/rollup.config.js +1 -0
- package/src/components/DatePicker/__tests__/__snapshots__/DatePickerAndroid.spec.tsx.snap +1 -0
- package/src/components/DatePicker/__tests__/__snapshots__/DatePickerIOS.spec.tsx.snap +1 -0
- package/src/components/Empty/index.tsx +1 -2
- package/src/components/Icon/HeroIcon/fonts/hero-icons.ttf +0 -0
- package/src/components/Icon/HeroIcon/glyphMap.json +1 -0
- package/src/components/Icon/HeroIcon/index.tsx +3 -7
- package/src/components/Icon/IconList.ts +8 -5
- package/src/components/Icon/index.tsx +1 -0
- package/src/components/RichTextEditor/RichTextEditor.tsx +1 -4
- package/src/components/RichTextEditor/__tests__/__snapshots__/RichTextEditor.spec.tsx.snap +2 -0
- package/src/components/Select/MultiSelect/__tests__/__snapshots__/OptionList.spec.tsx.snap +8 -4
- package/src/components/Select/MultiSelect/__tests__/__snapshots__/index.spec.tsx.snap +5 -0
- package/src/components/Select/SingleSelect/__tests__/__snapshots__/OptionList.spec.tsx.snap +8 -4
- package/src/components/Select/SingleSelect/__tests__/__snapshots__/index.spec.tsx.snap +5 -0
- package/src/components/Spinner/AnimatedSpinner.tsx +22 -7
- package/src/components/Spinner/StyledSpinner.tsx +16 -11
- package/src/components/Spinner/__tests__/AnimatedSpinner.spec.tsx +3 -1
- package/src/components/Spinner/__tests__/StyledSpinner.spec.tsx +42 -31
- package/src/components/Spinner/__tests__/__snapshots__/AnimatedSpinner.spec.tsx.snap +8 -4
- package/src/components/Spinner/__tests__/__snapshots__/StyledSpinner.spec.tsx.snap +532 -72
- package/src/components/Spinner/__tests__/__snapshots__/index.spec.tsx.snap +8 -4
- package/src/components/Spinner/index.tsx +6 -1
- package/src/components/Swipeable/StyledSwipeable.tsx +11 -0
- package/src/components/Swipeable/SwipeableAction.tsx +45 -0
- package/src/components/Swipeable/__tests__/SwipeableAction.spec.tsx +37 -0
- package/src/components/Swipeable/__tests__/__snapshots__/SwipeableAction.spec.tsx.snap +130 -0
- package/src/components/Swipeable/__tests__/__snapshots__/index.spec.tsx.snap +33 -0
- package/src/components/Swipeable/__tests__/index.spec.tsx +34 -0
- package/src/components/Swipeable/index.tsx +148 -0
- package/src/components/TextInput/StyledTextInput.tsx +6 -12
- package/src/components/TextInput/__tests__/StyledTextInput.spec.tsx +12 -6
- package/src/components/TextInput/__tests__/__snapshots__/StyledTextInput.spec.tsx.snap +22 -138
- package/src/components/TextInput/__tests__/__snapshots__/index.spec.tsx.snap +13 -0
- package/src/components/TextInput/__tests__/index.spec.tsx +114 -124
- package/src/components/TextInput/index.tsx +7 -6
- package/src/components/TimePicker/__tests__/__snapshots__/TimePickerAndroid.spec.tsx.snap +1 -0
- package/src/components/TimePicker/__tests__/__snapshots__/TimePickerIOS.spec.tsx.snap +1 -0
- package/src/index.ts +4 -0
- package/src/theme/__tests__/__snapshots__/index.spec.ts.snap +11 -6
- package/src/theme/components/spinner.ts +4 -1
- package/src/theme/components/swipeable.ts +13 -0
- package/src/theme/components/textInput.ts +0 -5
- package/src/theme/getTheme.ts +3 -0
- package/src/theme/global/colors/jobs.ts +0 -1
- package/src/theme/global/colors/work.ts +0 -2
- package/src/types.ts +2 -0
- package/testUtils/setup.tsx +13 -0
- package/types/components/Empty/index.d.ts +1 -2
- package/types/components/Icon/IconList.d.ts +1 -1
- package/types/components/Icon/index.d.ts +4 -1
- package/types/components/Icon/utils.d.ts +1 -1
- package/types/components/Spinner/AnimatedSpinner.d.ts +2 -1
- package/types/components/Spinner/StyledSpinner.d.ts +1 -0
- package/types/components/Spinner/index.d.ts +5 -1
- package/types/components/Swipeable/StyledSwipeable.d.ts +10 -0
- package/types/components/Swipeable/SwipeableAction.d.ts +27 -0
- package/types/components/Swipeable/index.d.ts +41 -0
- package/types/components/TextInput/StyledTextInput.d.ts +2 -1
- package/types/components/TextInput/index.d.ts +1 -1
- package/types/index.d.ts +3 -2
- package/types/theme/components/spinner.d.ts +4 -1
- package/types/theme/components/swipeable.d.ts +9 -0
- package/types/theme/components/textInput.d.ts +0 -5
- package/types/theme/getTheme.d.ts +2 -0
- package/types/types.d.ts +2 -1
- package/src/components/Icon/HeroIcon/selection.json +0 -7029
|
@@ -112,34 +112,6 @@ exports[`Label renders correctly with themeVariant filled 1`] = `
|
|
|
112
112
|
</Text>
|
|
113
113
|
`;
|
|
114
114
|
|
|
115
|
-
exports[`Label renders correctly with themeVariant focused 1`] = `
|
|
116
|
-
<Text
|
|
117
|
-
style={
|
|
118
|
-
Array [
|
|
119
|
-
Object {
|
|
120
|
-
"color": "#001f23",
|
|
121
|
-
"fontFamily": "BeVietnamPro-Regular",
|
|
122
|
-
"fontSize": 14,
|
|
123
|
-
"letterSpacing": 0.42,
|
|
124
|
-
"lineHeight": 22,
|
|
125
|
-
},
|
|
126
|
-
Array [
|
|
127
|
-
Object {
|
|
128
|
-
"color": "#001f23",
|
|
129
|
-
},
|
|
130
|
-
undefined,
|
|
131
|
-
],
|
|
132
|
-
]
|
|
133
|
-
}
|
|
134
|
-
themeFontSize="medium"
|
|
135
|
-
themeFontWeight="regular"
|
|
136
|
-
themeIntent="body"
|
|
137
|
-
themeVariant="focused"
|
|
138
|
-
>
|
|
139
|
-
Label
|
|
140
|
-
</Text>
|
|
141
|
-
`;
|
|
142
|
-
|
|
143
115
|
exports[`Label renders correctly with themeVariant readonly 1`] = `
|
|
144
116
|
<Text
|
|
145
117
|
style={
|
|
@@ -315,38 +287,6 @@ exports[`LabelInsideTextInput renders correctly with themeVariant filled 1`] = `
|
|
|
315
287
|
</Text>
|
|
316
288
|
`;
|
|
317
289
|
|
|
318
|
-
exports[`LabelInsideTextInput renders correctly with themeVariant focused 1`] = `
|
|
319
|
-
<Text
|
|
320
|
-
style={
|
|
321
|
-
Array [
|
|
322
|
-
Object {
|
|
323
|
-
"color": "#001f23",
|
|
324
|
-
"fontFamily": "BeVietnamPro-Regular",
|
|
325
|
-
"fontSize": 14,
|
|
326
|
-
"letterSpacing": 0.42,
|
|
327
|
-
"lineHeight": 22,
|
|
328
|
-
},
|
|
329
|
-
Array [
|
|
330
|
-
Object {
|
|
331
|
-
"alignContent": "center",
|
|
332
|
-
"alignItems": "center",
|
|
333
|
-
"color": "#001f23",
|
|
334
|
-
"fontSize": 14,
|
|
335
|
-
"textAlignVertical": "center",
|
|
336
|
-
},
|
|
337
|
-
undefined,
|
|
338
|
-
],
|
|
339
|
-
]
|
|
340
|
-
}
|
|
341
|
-
themeFontSize="medium"
|
|
342
|
-
themeFontWeight="regular"
|
|
343
|
-
themeIntent="body"
|
|
344
|
-
themeVariant="focused"
|
|
345
|
-
>
|
|
346
|
-
Label
|
|
347
|
-
</Text>
|
|
348
|
-
`;
|
|
349
|
-
|
|
350
290
|
exports[`LabelInsideTextInput renders correctly with themeVariant readonly 1`] = `
|
|
351
291
|
<Text
|
|
352
292
|
style={
|
|
@@ -491,34 +431,6 @@ exports[`StyledAsteriskLabel renders correctly with themeVariant filled 1`] = `
|
|
|
491
431
|
</Text>
|
|
492
432
|
`;
|
|
493
433
|
|
|
494
|
-
exports[`StyledAsteriskLabel renders correctly with themeVariant focused 1`] = `
|
|
495
|
-
<Text
|
|
496
|
-
style={
|
|
497
|
-
Array [
|
|
498
|
-
Object {
|
|
499
|
-
"color": "#001f23",
|
|
500
|
-
"fontFamily": "BeVietnamPro-Regular",
|
|
501
|
-
"fontSize": 14,
|
|
502
|
-
"letterSpacing": 0.42,
|
|
503
|
-
"lineHeight": 22,
|
|
504
|
-
},
|
|
505
|
-
Array [
|
|
506
|
-
Object {
|
|
507
|
-
"color": "#f46363",
|
|
508
|
-
},
|
|
509
|
-
undefined,
|
|
510
|
-
],
|
|
511
|
-
]
|
|
512
|
-
}
|
|
513
|
-
themeFontSize="medium"
|
|
514
|
-
themeFontWeight="regular"
|
|
515
|
-
themeIntent="body"
|
|
516
|
-
themeVariant="focused"
|
|
517
|
-
>
|
|
518
|
-
*
|
|
519
|
-
</Text>
|
|
520
|
-
`;
|
|
521
|
-
|
|
522
434
|
exports[`StyledAsteriskLabel renders correctly with themeVariant readonly 1`] = `
|
|
523
435
|
<Text
|
|
524
436
|
style={
|
|
@@ -547,14 +459,14 @@ exports[`StyledAsteriskLabel renders correctly with themeVariant readonly 1`] =
|
|
|
547
459
|
</Text>
|
|
548
460
|
`;
|
|
549
461
|
|
|
550
|
-
exports[`StyledBorderBackDrop renders correctly
|
|
462
|
+
exports[`StyledBorderBackDrop renders correctly when focused 1`] = `
|
|
551
463
|
<View
|
|
552
464
|
style={
|
|
553
465
|
Array [
|
|
554
466
|
Object {
|
|
555
|
-
"borderColor": "#
|
|
467
|
+
"borderColor": "#f46363",
|
|
556
468
|
"borderRadius": 8,
|
|
557
|
-
"borderWidth":
|
|
469
|
+
"borderWidth": 2,
|
|
558
470
|
"bottom": 0,
|
|
559
471
|
"left": 0,
|
|
560
472
|
"position": "absolute",
|
|
@@ -564,16 +476,17 @@ exports[`StyledBorderBackDrop renders correctly with themeVariant default 1`] =
|
|
|
564
476
|
undefined,
|
|
565
477
|
]
|
|
566
478
|
}
|
|
567
|
-
|
|
479
|
+
themeFocused={true}
|
|
480
|
+
themeVariant="error"
|
|
568
481
|
/>
|
|
569
482
|
`;
|
|
570
483
|
|
|
571
|
-
exports[`StyledBorderBackDrop renders correctly with themeVariant
|
|
484
|
+
exports[`StyledBorderBackDrop renders correctly with themeVariant default 1`] = `
|
|
572
485
|
<View
|
|
573
486
|
style={
|
|
574
487
|
Array [
|
|
575
488
|
Object {
|
|
576
|
-
"borderColor": "#
|
|
489
|
+
"borderColor": "#001f23",
|
|
577
490
|
"borderRadius": 8,
|
|
578
491
|
"borderWidth": 1,
|
|
579
492
|
"bottom": 0,
|
|
@@ -585,16 +498,17 @@ exports[`StyledBorderBackDrop renders correctly with themeVariant disabled 1`] =
|
|
|
585
498
|
undefined,
|
|
586
499
|
]
|
|
587
500
|
}
|
|
588
|
-
|
|
501
|
+
themeFocused={false}
|
|
502
|
+
themeVariant="default"
|
|
589
503
|
/>
|
|
590
504
|
`;
|
|
591
505
|
|
|
592
|
-
exports[`StyledBorderBackDrop renders correctly with themeVariant
|
|
506
|
+
exports[`StyledBorderBackDrop renders correctly with themeVariant disabled 1`] = `
|
|
593
507
|
<View
|
|
594
508
|
style={
|
|
595
509
|
Array [
|
|
596
510
|
Object {
|
|
597
|
-
"borderColor": "#
|
|
511
|
+
"borderColor": "#bfc1c5",
|
|
598
512
|
"borderRadius": 8,
|
|
599
513
|
"borderWidth": 1,
|
|
600
514
|
"bottom": 0,
|
|
@@ -606,16 +520,17 @@ exports[`StyledBorderBackDrop renders correctly with themeVariant error 1`] = `
|
|
|
606
520
|
undefined,
|
|
607
521
|
]
|
|
608
522
|
}
|
|
609
|
-
|
|
523
|
+
themeFocused={false}
|
|
524
|
+
themeVariant="disabled"
|
|
610
525
|
/>
|
|
611
526
|
`;
|
|
612
527
|
|
|
613
|
-
exports[`StyledBorderBackDrop renders correctly with themeVariant
|
|
528
|
+
exports[`StyledBorderBackDrop renders correctly with themeVariant error 1`] = `
|
|
614
529
|
<View
|
|
615
530
|
style={
|
|
616
531
|
Array [
|
|
617
532
|
Object {
|
|
618
|
-
"borderColor": "#
|
|
533
|
+
"borderColor": "#f46363",
|
|
619
534
|
"borderRadius": 8,
|
|
620
535
|
"borderWidth": 1,
|
|
621
536
|
"bottom": 0,
|
|
@@ -627,18 +542,19 @@ exports[`StyledBorderBackDrop renders correctly with themeVariant filled 1`] = `
|
|
|
627
542
|
undefined,
|
|
628
543
|
]
|
|
629
544
|
}
|
|
630
|
-
|
|
545
|
+
themeFocused={false}
|
|
546
|
+
themeVariant="error"
|
|
631
547
|
/>
|
|
632
548
|
`;
|
|
633
549
|
|
|
634
|
-
exports[`StyledBorderBackDrop renders correctly with themeVariant
|
|
550
|
+
exports[`StyledBorderBackDrop renders correctly with themeVariant filled 1`] = `
|
|
635
551
|
<View
|
|
636
552
|
style={
|
|
637
553
|
Array [
|
|
638
554
|
Object {
|
|
639
555
|
"borderColor": "#001f23",
|
|
640
556
|
"borderRadius": 8,
|
|
641
|
-
"borderWidth":
|
|
557
|
+
"borderWidth": 1,
|
|
642
558
|
"bottom": 0,
|
|
643
559
|
"left": 0,
|
|
644
560
|
"position": "absolute",
|
|
@@ -648,7 +564,8 @@ exports[`StyledBorderBackDrop renders correctly with themeVariant focused 1`] =
|
|
|
648
564
|
undefined,
|
|
649
565
|
]
|
|
650
566
|
}
|
|
651
|
-
|
|
567
|
+
themeFocused={false}
|
|
568
|
+
themeVariant="filled"
|
|
652
569
|
/>
|
|
653
570
|
`;
|
|
654
571
|
|
|
@@ -669,6 +586,7 @@ exports[`StyledBorderBackDrop renders correctly with themeVariant readonly 1`] =
|
|
|
669
586
|
undefined,
|
|
670
587
|
]
|
|
671
588
|
}
|
|
589
|
+
themeFocused={false}
|
|
672
590
|
themeVariant="readonly"
|
|
673
591
|
/>
|
|
674
592
|
`;
|
|
@@ -888,40 +806,6 @@ exports[`StyledMaxLengthMessage renders correctly with themeVariant filled 1`] =
|
|
|
888
806
|
</Text>
|
|
889
807
|
`;
|
|
890
808
|
|
|
891
|
-
exports[`StyledMaxLengthMessage renders correctly with themeVariant focused 1`] = `
|
|
892
|
-
<Text
|
|
893
|
-
style={
|
|
894
|
-
Array [
|
|
895
|
-
Object {
|
|
896
|
-
"color": "#001f23",
|
|
897
|
-
"fontFamily": "BeVietnamPro-Regular",
|
|
898
|
-
"fontSize": 14,
|
|
899
|
-
"letterSpacing": 0.42,
|
|
900
|
-
"lineHeight": 22,
|
|
901
|
-
},
|
|
902
|
-
Array [
|
|
903
|
-
Object {
|
|
904
|
-
"alignSelf": "flex-end",
|
|
905
|
-
"color": "#001f23",
|
|
906
|
-
"flex": 1,
|
|
907
|
-
"flexGrow": 1,
|
|
908
|
-
"fontSize": 12,
|
|
909
|
-
"marginRight": 4,
|
|
910
|
-
"textAlign": "right",
|
|
911
|
-
},
|
|
912
|
-
undefined,
|
|
913
|
-
],
|
|
914
|
-
]
|
|
915
|
-
}
|
|
916
|
-
themeFontSize="medium"
|
|
917
|
-
themeFontWeight="regular"
|
|
918
|
-
themeIntent="body"
|
|
919
|
-
themeVariant="focused"
|
|
920
|
-
>
|
|
921
|
-
100/255
|
|
922
|
-
</Text>
|
|
923
|
-
`;
|
|
924
|
-
|
|
925
809
|
exports[`StyledMaxLengthMessage renders correctly with themeVariant readonly 1`] = `
|
|
926
810
|
<Text
|
|
927
811
|
style={
|
|
@@ -41,6 +41,7 @@ exports[`TextInput defaultValue TextInput is idle renders correctly 1`] = `
|
|
|
41
41
|
undefined,
|
|
42
42
|
]
|
|
43
43
|
}
|
|
44
|
+
themeFocused={false}
|
|
44
45
|
themeVariant="filled"
|
|
45
46
|
/>
|
|
46
47
|
<View
|
|
@@ -295,6 +296,7 @@ exports[`TextInput defaultValue default Value and Value renders correctly with 2
|
|
|
295
296
|
undefined,
|
|
296
297
|
]
|
|
297
298
|
}
|
|
299
|
+
themeFocused={false}
|
|
298
300
|
themeVariant="filled"
|
|
299
301
|
/>
|
|
300
302
|
<View
|
|
@@ -551,6 +553,7 @@ exports[`TextInput disabled renders correctly 1`] = `
|
|
|
551
553
|
undefined,
|
|
552
554
|
]
|
|
553
555
|
}
|
|
556
|
+
themeFocused={false}
|
|
554
557
|
themeVariant="disabled"
|
|
555
558
|
/>
|
|
556
559
|
<View
|
|
@@ -731,6 +734,7 @@ exports[`TextInput error renders correctly 1`] = `
|
|
|
731
734
|
undefined,
|
|
732
735
|
]
|
|
733
736
|
}
|
|
737
|
+
themeFocused={false}
|
|
734
738
|
themeVariant="error"
|
|
735
739
|
/>
|
|
736
740
|
<HeroIcon
|
|
@@ -989,6 +993,7 @@ exports[`TextInput filled renders correctly 1`] = `
|
|
|
989
993
|
undefined,
|
|
990
994
|
]
|
|
991
995
|
}
|
|
996
|
+
themeFocused={false}
|
|
992
997
|
themeVariant="filled"
|
|
993
998
|
/>
|
|
994
999
|
<View
|
|
@@ -1174,6 +1179,7 @@ exports[`TextInput helper text renders correctly 1`] = `
|
|
|
1174
1179
|
undefined,
|
|
1175
1180
|
]
|
|
1176
1181
|
}
|
|
1182
|
+
themeFocused={false}
|
|
1177
1183
|
themeVariant="default"
|
|
1178
1184
|
/>
|
|
1179
1185
|
<HeroIcon
|
|
@@ -1401,6 +1407,7 @@ exports[`TextInput idle renders correctly 1`] = `
|
|
|
1401
1407
|
undefined,
|
|
1402
1408
|
]
|
|
1403
1409
|
}
|
|
1410
|
+
themeFocused={false}
|
|
1404
1411
|
themeVariant="default"
|
|
1405
1412
|
/>
|
|
1406
1413
|
<HeroIcon
|
|
@@ -1590,6 +1597,7 @@ exports[`TextInput idle with suffix and prefix are React Element renders correct
|
|
|
1590
1597
|
undefined,
|
|
1591
1598
|
]
|
|
1592
1599
|
}
|
|
1600
|
+
themeFocused={false}
|
|
1593
1601
|
themeVariant="default"
|
|
1594
1602
|
/>
|
|
1595
1603
|
<HeroIcon
|
|
@@ -1805,6 +1813,7 @@ exports[`TextInput loading renders correctly 1`] = `
|
|
|
1805
1813
|
undefined,
|
|
1806
1814
|
]
|
|
1807
1815
|
}
|
|
1816
|
+
themeFocused={false}
|
|
1808
1817
|
themeVariant="readonly"
|
|
1809
1818
|
/>
|
|
1810
1819
|
<View
|
|
@@ -1962,6 +1971,7 @@ exports[`TextInput max length renders correctly 1`] = `
|
|
|
1962
1971
|
undefined,
|
|
1963
1972
|
]
|
|
1964
1973
|
}
|
|
1974
|
+
themeFocused={false}
|
|
1965
1975
|
themeVariant="error"
|
|
1966
1976
|
/>
|
|
1967
1977
|
<View
|
|
@@ -2235,6 +2245,7 @@ exports[`TextInput placeholder TextInput is idle renders correctly 1`] = `
|
|
|
2235
2245
|
undefined,
|
|
2236
2246
|
]
|
|
2237
2247
|
}
|
|
2248
|
+
themeFocused={false}
|
|
2238
2249
|
themeVariant="default"
|
|
2239
2250
|
/>
|
|
2240
2251
|
<HeroIcon
|
|
@@ -2459,6 +2470,7 @@ exports[`TextInput readonly renders correctly 1`] = `
|
|
|
2459
2470
|
undefined,
|
|
2460
2471
|
]
|
|
2461
2472
|
}
|
|
2473
|
+
themeFocused={false}
|
|
2462
2474
|
themeVariant="readonly"
|
|
2463
2475
|
/>
|
|
2464
2476
|
<View
|
|
@@ -2669,6 +2681,7 @@ exports[`TextInput required renders correctly 1`] = `
|
|
|
2669
2681
|
undefined,
|
|
2670
2682
|
]
|
|
2671
2683
|
}
|
|
2684
|
+
themeFocused={false}
|
|
2672
2685
|
themeVariant="default"
|
|
2673
2686
|
/>
|
|
2674
2687
|
<HeroIcon
|