@hero-design/rn 8.64.9-alpha.0 → 8.65.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 +5 -0
- package/CHANGELOG.md +6 -0
- package/es/index.js +237 -234
- package/lib/index.js +237 -234
- package/package.json +2 -3
- package/src/components/BottomNavigation/index.tsx +0 -4
- package/src/components/PinInput/StyledPinInput.tsx +0 -1
- package/src/components/PinInput/index.tsx +9 -20
- package/src/theme/components/pinInput.ts +1 -1
- package/stats/8.65.0/rn-stats.html +4842 -0
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
[36m
|
|
2
|
+
[1msrc/index.ts[22m → [1mlib/index.js, es/index.js[22m...[39m
|
|
3
|
+
[1m[33m(!) 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`.[39m[22m
|
|
4
|
+
[1m[33m(!) Plugin node-resolve: preferring built-in module 'events' over local alternative at '/home/runner/work/hero-design/hero-design/node_modules/events/events.js', pass 'preferBuiltins: false' to disable this behavior or 'preferBuiltins: true' to disable this warning[39m[22m
|
|
5
|
+
[32mcreated [1mlib/index.js, es/index.js[22m in [1m1m 0.2s[22m[39m
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
1
|
# @hero-design/rn
|
|
2
2
|
|
|
3
|
+
## 8.65.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#3377](https://github.com/Thinkei/hero-design/pull/3377) [`a05212a0d5c19ecdecca919e706447fb7c1298e5`](https://github.com/Thinkei/hero-design/commit/a05212a0d5c19ecdecca919e706447fb7c1298e5) Thanks [@vinhphan-eh](https://github.com/vinhphan-eh)! - [BottomNavigation] Bring back component
|
|
8
|
+
|
|
3
9
|
## 8.64.8
|
|
4
10
|
|
|
5
11
|
### Patch Changes
|
package/es/index.js
CHANGED
|
@@ -613,156 +613,231 @@ var hexRgb = function hexRgb(hex) {
|
|
|
613
613
|
};
|
|
614
614
|
};
|
|
615
615
|
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
"
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
"
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
705
|
-
|
|
706
|
-
|
|
707
|
-
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
742
|
-
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
616
|
+
function hsl2rgb(hsl) {
|
|
617
|
+
var h = hsl[0] / 360,
|
|
618
|
+
s = hsl[1] / 100,
|
|
619
|
+
l = hsl[2] / 100,
|
|
620
|
+
t1,
|
|
621
|
+
t2,
|
|
622
|
+
t3,
|
|
623
|
+
rgb,
|
|
624
|
+
val;
|
|
625
|
+
if (s == 0) {
|
|
626
|
+
val = l * 255;
|
|
627
|
+
return [val, val, val];
|
|
628
|
+
}
|
|
629
|
+
if (l < 0.5) t2 = l * (1 + s);else t2 = l + s - l * s;
|
|
630
|
+
t1 = 2 * l - t2;
|
|
631
|
+
rgb = [0, 0, 0];
|
|
632
|
+
for (var i = 0; i < 3; i++) {
|
|
633
|
+
t3 = h + 1 / 3 * -(i - 1);
|
|
634
|
+
t3 < 0 && t3++;
|
|
635
|
+
t3 > 1 && t3--;
|
|
636
|
+
if (6 * t3 < 1) val = t1 + (t2 - t1) * 6 * t3;else if (2 * t3 < 1) val = t2;else if (3 * t3 < 2) val = t1 + (t2 - t1) * (2 / 3 - t3) * 6;else val = t1;
|
|
637
|
+
rgb[i] = val * 255;
|
|
638
|
+
}
|
|
639
|
+
return rgb;
|
|
640
|
+
}
|
|
641
|
+
var hsl2rgb_1 = hsl2rgb;
|
|
642
|
+
|
|
643
|
+
function clamp$3(val, min, max) {
|
|
644
|
+
return Math.min(Math.max(val, min), max);
|
|
645
|
+
}
|
|
646
|
+
var clamp_1 = clamp$3;
|
|
647
|
+
|
|
648
|
+
var clamp$2 = clamp_1;
|
|
649
|
+
function componentToHex(c) {
|
|
650
|
+
var value = Math.round(clamp$2(c, 0, 255));
|
|
651
|
+
var hex = value.toString(16);
|
|
652
|
+
return hex.length == 1 ? "0" + hex : hex;
|
|
653
|
+
}
|
|
654
|
+
function rgb2hex(rgb) {
|
|
655
|
+
var alpha = rgb.length === 4 ? componentToHex(rgb[3] * 255) : "";
|
|
656
|
+
return "#" + componentToHex(rgb[0]) + componentToHex(rgb[1]) + componentToHex(rgb[2]) + alpha;
|
|
657
|
+
}
|
|
658
|
+
var rgb2hex_1 = rgb2hex;
|
|
659
|
+
|
|
660
|
+
function rgb2hsl(rgb) {
|
|
661
|
+
var r = rgb[0] / 255,
|
|
662
|
+
g = rgb[1] / 255,
|
|
663
|
+
b = rgb[2] / 255,
|
|
664
|
+
min = Math.min(r, g, b),
|
|
665
|
+
max = Math.max(r, g, b),
|
|
666
|
+
delta = max - min,
|
|
667
|
+
h,
|
|
668
|
+
s,
|
|
669
|
+
l;
|
|
670
|
+
if (max == min) h = 0;else if (r == max) h = (g - b) / delta;else if (g == max) h = 2 + (b - r) / delta;else if (b == max) h = 4 + (r - g) / delta;
|
|
671
|
+
h = Math.min(h * 60, 360);
|
|
672
|
+
if (h < 0) h += 360;
|
|
673
|
+
l = (min + max) / 2;
|
|
674
|
+
if (max == min) s = 0;else if (l <= 0.5) s = delta / (max + min);else s = delta / (2 - max - min);
|
|
675
|
+
return [h, s * 100, l * 100];
|
|
676
|
+
}
|
|
677
|
+
var rgb2hsl_1 = rgb2hsl;
|
|
678
|
+
|
|
679
|
+
function getDefaultExportFromCjs$1(x) {
|
|
680
|
+
return x && x.__esModule && Object.prototype.hasOwnProperty.call(x, 'default') ? x['default'] : x;
|
|
681
|
+
}
|
|
682
|
+
var colorName$1;
|
|
683
|
+
var hasRequiredColorName;
|
|
684
|
+
function requireColorName() {
|
|
685
|
+
if (hasRequiredColorName) return colorName$1;
|
|
686
|
+
hasRequiredColorName = 1;
|
|
687
|
+
colorName$1 = {
|
|
688
|
+
"aliceblue": [240, 248, 255],
|
|
689
|
+
"antiquewhite": [250, 235, 215],
|
|
690
|
+
"aqua": [0, 255, 255],
|
|
691
|
+
"aquamarine": [127, 255, 212],
|
|
692
|
+
"azure": [240, 255, 255],
|
|
693
|
+
"beige": [245, 245, 220],
|
|
694
|
+
"bisque": [255, 228, 196],
|
|
695
|
+
"black": [0, 0, 0],
|
|
696
|
+
"blanchedalmond": [255, 235, 205],
|
|
697
|
+
"blue": [0, 0, 255],
|
|
698
|
+
"blueviolet": [138, 43, 226],
|
|
699
|
+
"brown": [165, 42, 42],
|
|
700
|
+
"burlywood": [222, 184, 135],
|
|
701
|
+
"cadetblue": [95, 158, 160],
|
|
702
|
+
"chartreuse": [127, 255, 0],
|
|
703
|
+
"chocolate": [210, 105, 30],
|
|
704
|
+
"coral": [255, 127, 80],
|
|
705
|
+
"cornflowerblue": [100, 149, 237],
|
|
706
|
+
"cornsilk": [255, 248, 220],
|
|
707
|
+
"crimson": [220, 20, 60],
|
|
708
|
+
"cyan": [0, 255, 255],
|
|
709
|
+
"darkblue": [0, 0, 139],
|
|
710
|
+
"darkcyan": [0, 139, 139],
|
|
711
|
+
"darkgoldenrod": [184, 134, 11],
|
|
712
|
+
"darkgray": [169, 169, 169],
|
|
713
|
+
"darkgreen": [0, 100, 0],
|
|
714
|
+
"darkgrey": [169, 169, 169],
|
|
715
|
+
"darkkhaki": [189, 183, 107],
|
|
716
|
+
"darkmagenta": [139, 0, 139],
|
|
717
|
+
"darkolivegreen": [85, 107, 47],
|
|
718
|
+
"darkorange": [255, 140, 0],
|
|
719
|
+
"darkorchid": [153, 50, 204],
|
|
720
|
+
"darkred": [139, 0, 0],
|
|
721
|
+
"darksalmon": [233, 150, 122],
|
|
722
|
+
"darkseagreen": [143, 188, 143],
|
|
723
|
+
"darkslateblue": [72, 61, 139],
|
|
724
|
+
"darkslategray": [47, 79, 79],
|
|
725
|
+
"darkslategrey": [47, 79, 79],
|
|
726
|
+
"darkturquoise": [0, 206, 209],
|
|
727
|
+
"darkviolet": [148, 0, 211],
|
|
728
|
+
"deeppink": [255, 20, 147],
|
|
729
|
+
"deepskyblue": [0, 191, 255],
|
|
730
|
+
"dimgray": [105, 105, 105],
|
|
731
|
+
"dimgrey": [105, 105, 105],
|
|
732
|
+
"dodgerblue": [30, 144, 255],
|
|
733
|
+
"firebrick": [178, 34, 34],
|
|
734
|
+
"floralwhite": [255, 250, 240],
|
|
735
|
+
"forestgreen": [34, 139, 34],
|
|
736
|
+
"fuchsia": [255, 0, 255],
|
|
737
|
+
"gainsboro": [220, 220, 220],
|
|
738
|
+
"ghostwhite": [248, 248, 255],
|
|
739
|
+
"gold": [255, 215, 0],
|
|
740
|
+
"goldenrod": [218, 165, 32],
|
|
741
|
+
"gray": [128, 128, 128],
|
|
742
|
+
"green": [0, 128, 0],
|
|
743
|
+
"greenyellow": [173, 255, 47],
|
|
744
|
+
"grey": [128, 128, 128],
|
|
745
|
+
"honeydew": [240, 255, 240],
|
|
746
|
+
"hotpink": [255, 105, 180],
|
|
747
|
+
"indianred": [205, 92, 92],
|
|
748
|
+
"indigo": [75, 0, 130],
|
|
749
|
+
"ivory": [255, 255, 240],
|
|
750
|
+
"khaki": [240, 230, 140],
|
|
751
|
+
"lavender": [230, 230, 250],
|
|
752
|
+
"lavenderblush": [255, 240, 245],
|
|
753
|
+
"lawngreen": [124, 252, 0],
|
|
754
|
+
"lemonchiffon": [255, 250, 205],
|
|
755
|
+
"lightblue": [173, 216, 230],
|
|
756
|
+
"lightcoral": [240, 128, 128],
|
|
757
|
+
"lightcyan": [224, 255, 255],
|
|
758
|
+
"lightgoldenrodyellow": [250, 250, 210],
|
|
759
|
+
"lightgray": [211, 211, 211],
|
|
760
|
+
"lightgreen": [144, 238, 144],
|
|
761
|
+
"lightgrey": [211, 211, 211],
|
|
762
|
+
"lightpink": [255, 182, 193],
|
|
763
|
+
"lightsalmon": [255, 160, 122],
|
|
764
|
+
"lightseagreen": [32, 178, 170],
|
|
765
|
+
"lightskyblue": [135, 206, 250],
|
|
766
|
+
"lightslategray": [119, 136, 153],
|
|
767
|
+
"lightslategrey": [119, 136, 153],
|
|
768
|
+
"lightsteelblue": [176, 196, 222],
|
|
769
|
+
"lightyellow": [255, 255, 224],
|
|
770
|
+
"lime": [0, 255, 0],
|
|
771
|
+
"limegreen": [50, 205, 50],
|
|
772
|
+
"linen": [250, 240, 230],
|
|
773
|
+
"magenta": [255, 0, 255],
|
|
774
|
+
"maroon": [128, 0, 0],
|
|
775
|
+
"mediumaquamarine": [102, 205, 170],
|
|
776
|
+
"mediumblue": [0, 0, 205],
|
|
777
|
+
"mediumorchid": [186, 85, 211],
|
|
778
|
+
"mediumpurple": [147, 112, 219],
|
|
779
|
+
"mediumseagreen": [60, 179, 113],
|
|
780
|
+
"mediumslateblue": [123, 104, 238],
|
|
781
|
+
"mediumspringgreen": [0, 250, 154],
|
|
782
|
+
"mediumturquoise": [72, 209, 204],
|
|
783
|
+
"mediumvioletred": [199, 21, 133],
|
|
784
|
+
"midnightblue": [25, 25, 112],
|
|
785
|
+
"mintcream": [245, 255, 250],
|
|
786
|
+
"mistyrose": [255, 228, 225],
|
|
787
|
+
"moccasin": [255, 228, 181],
|
|
788
|
+
"navajowhite": [255, 222, 173],
|
|
789
|
+
"navy": [0, 0, 128],
|
|
790
|
+
"oldlace": [253, 245, 230],
|
|
791
|
+
"olive": [128, 128, 0],
|
|
792
|
+
"olivedrab": [107, 142, 35],
|
|
793
|
+
"orange": [255, 165, 0],
|
|
794
|
+
"orangered": [255, 69, 0],
|
|
795
|
+
"orchid": [218, 112, 214],
|
|
796
|
+
"palegoldenrod": [238, 232, 170],
|
|
797
|
+
"palegreen": [152, 251, 152],
|
|
798
|
+
"paleturquoise": [175, 238, 238],
|
|
799
|
+
"palevioletred": [219, 112, 147],
|
|
800
|
+
"papayawhip": [255, 239, 213],
|
|
801
|
+
"peachpuff": [255, 218, 185],
|
|
802
|
+
"peru": [205, 133, 63],
|
|
803
|
+
"pink": [255, 192, 203],
|
|
804
|
+
"plum": [221, 160, 221],
|
|
805
|
+
"powderblue": [176, 224, 230],
|
|
806
|
+
"purple": [128, 0, 128],
|
|
807
|
+
"rebeccapurple": [102, 51, 153],
|
|
808
|
+
"red": [255, 0, 0],
|
|
809
|
+
"rosybrown": [188, 143, 143],
|
|
810
|
+
"royalblue": [65, 105, 225],
|
|
811
|
+
"saddlebrown": [139, 69, 19],
|
|
812
|
+
"salmon": [250, 128, 114],
|
|
813
|
+
"sandybrown": [244, 164, 96],
|
|
814
|
+
"seagreen": [46, 139, 87],
|
|
815
|
+
"seashell": [255, 245, 238],
|
|
816
|
+
"sienna": [160, 82, 45],
|
|
817
|
+
"silver": [192, 192, 192],
|
|
818
|
+
"skyblue": [135, 206, 235],
|
|
819
|
+
"slateblue": [106, 90, 205],
|
|
820
|
+
"slategray": [112, 128, 144],
|
|
821
|
+
"slategrey": [112, 128, 144],
|
|
822
|
+
"snow": [255, 250, 250],
|
|
823
|
+
"springgreen": [0, 255, 127],
|
|
824
|
+
"steelblue": [70, 130, 180],
|
|
825
|
+
"tan": [210, 180, 140],
|
|
826
|
+
"teal": [0, 128, 128],
|
|
827
|
+
"thistle": [216, 191, 216],
|
|
828
|
+
"tomato": [255, 99, 71],
|
|
829
|
+
"turquoise": [64, 224, 208],
|
|
830
|
+
"violet": [238, 130, 238],
|
|
831
|
+
"wheat": [245, 222, 179],
|
|
832
|
+
"white": [255, 255, 255],
|
|
833
|
+
"whitesmoke": [245, 245, 245],
|
|
834
|
+
"yellow": [255, 255, 0],
|
|
835
|
+
"yellowgreen": [154, 205, 50]
|
|
836
|
+
};
|
|
837
|
+
return colorName$1;
|
|
838
|
+
}
|
|
839
|
+
var colorNameExports = requireColorName();
|
|
840
|
+
var colorName = /*@__PURE__*/getDefaultExportFromCjs$1(colorNameExports);
|
|
766
841
|
var pattern$8 = /^#([a-f0-9]{3,4}|[a-f0-9]{4}(?:[a-f0-9]{2}){1,2})\b$/;
|
|
767
842
|
var hexRe$1 = new RegExp(pattern$8, 'i');
|
|
768
843
|
var float$1 = '-?\\d*(?:\\.\\d+)';
|
|
@@ -783,7 +858,7 @@ var pattern$6$1 = "^\n rgba?\\(\n \\s*".concat(percentage$1, "\n \\s+").c
|
|
|
783
858
|
var rgb4PercentageRe$1 = new RegExp(pattern$6$1);
|
|
784
859
|
var pattern$7$1 = /^transparent$/;
|
|
785
860
|
var transparentRe$1 = new RegExp(pattern$7$1, 'i');
|
|
786
|
-
var clamp$
|
|
861
|
+
var clamp$1 = function clamp$1(num, min, max) {
|
|
787
862
|
return Math.min(Math.max(min, num), max);
|
|
788
863
|
};
|
|
789
864
|
|
|
@@ -791,19 +866,19 @@ var clamp$3 = function clamp$3(num, min, max) {
|
|
|
791
866
|
var parseRGB$1 = function parseRGB$1(num) {
|
|
792
867
|
var n = num;
|
|
793
868
|
if (typeof n !== 'number') n = n.endsWith('%') ? parseFloat(n) * 255 / 100 : parseFloat(n);
|
|
794
|
-
return clamp$
|
|
869
|
+
return clamp$1(Math.round(n), 0, 255);
|
|
795
870
|
};
|
|
796
871
|
|
|
797
872
|
/* 200 => 100, -100 => 0, 50 => 50 */
|
|
798
873
|
var parsePercentage$1 = function parsePercentage$1(percentage) {
|
|
799
|
-
return clamp$
|
|
874
|
+
return clamp$1(parseFloat(percentage), 0, 100);
|
|
800
875
|
};
|
|
801
876
|
|
|
802
877
|
/* '50%' => 5.0, 200 => 1, -10 => 0 */
|
|
803
878
|
function parseAlpha$1(alpha) {
|
|
804
879
|
var a = alpha;
|
|
805
880
|
if (typeof a !== 'number') a = a.endsWith('%') ? parseFloat(a) / 100 : parseFloat(a);
|
|
806
|
-
return clamp$
|
|
881
|
+
return clamp$1(a, 0, 1);
|
|
807
882
|
}
|
|
808
883
|
function getHEX$1(hex) {
|
|
809
884
|
var _hex2Rgb = hexRgb(hex, {
|
|
@@ -871,65 +946,6 @@ var parseCSSColor$1 = function parseCSSColor$1(str) {
|
|
|
871
946
|
if (cn) return getRGB$1([null, cn[0], cn[1], cn[2], 1]);
|
|
872
947
|
return null;
|
|
873
948
|
};
|
|
874
|
-
function hsl2rgb(hsl) {
|
|
875
|
-
var h = hsl[0] / 360,
|
|
876
|
-
s = hsl[1] / 100,
|
|
877
|
-
l = hsl[2] / 100,
|
|
878
|
-
t1,
|
|
879
|
-
t2,
|
|
880
|
-
t3,
|
|
881
|
-
rgb,
|
|
882
|
-
val;
|
|
883
|
-
if (s == 0) {
|
|
884
|
-
val = l * 255;
|
|
885
|
-
return [val, val, val];
|
|
886
|
-
}
|
|
887
|
-
if (l < 0.5) t2 = l * (1 + s);else t2 = l + s - l * s;
|
|
888
|
-
t1 = 2 * l - t2;
|
|
889
|
-
rgb = [0, 0, 0];
|
|
890
|
-
for (var i = 0; i < 3; i++) {
|
|
891
|
-
t3 = h + 1 / 3 * -(i - 1);
|
|
892
|
-
t3 < 0 && t3++;
|
|
893
|
-
t3 > 1 && t3--;
|
|
894
|
-
if (6 * t3 < 1) val = t1 + (t2 - t1) * 6 * t3;else if (2 * t3 < 1) val = t2;else if (3 * t3 < 2) val = t1 + (t2 - t1) * (2 / 3 - t3) * 6;else val = t1;
|
|
895
|
-
rgb[i] = val * 255;
|
|
896
|
-
}
|
|
897
|
-
return rgb;
|
|
898
|
-
}
|
|
899
|
-
var hsl2rgb_1 = hsl2rgb;
|
|
900
|
-
function clamp$2(val, min, max) {
|
|
901
|
-
return Math.min(Math.max(val, min), max);
|
|
902
|
-
}
|
|
903
|
-
var clamp_1 = clamp$2;
|
|
904
|
-
var clamp$1 = clamp_1;
|
|
905
|
-
function componentToHex(c) {
|
|
906
|
-
var value = Math.round(clamp$1(c, 0, 255));
|
|
907
|
-
var hex = value.toString(16);
|
|
908
|
-
return hex.length == 1 ? "0" + hex : hex;
|
|
909
|
-
}
|
|
910
|
-
function rgb2hex(rgb) {
|
|
911
|
-
var alpha = rgb.length === 4 ? componentToHex(rgb[3] * 255) : "";
|
|
912
|
-
return "#" + componentToHex(rgb[0]) + componentToHex(rgb[1]) + componentToHex(rgb[2]) + alpha;
|
|
913
|
-
}
|
|
914
|
-
var rgb2hex_1 = rgb2hex;
|
|
915
|
-
function rgb2hsl(rgb) {
|
|
916
|
-
var r = rgb[0] / 255,
|
|
917
|
-
g = rgb[1] / 255,
|
|
918
|
-
b = rgb[2] / 255,
|
|
919
|
-
min = Math.min(r, g, b),
|
|
920
|
-
max = Math.max(r, g, b),
|
|
921
|
-
delta = max - min,
|
|
922
|
-
h,
|
|
923
|
-
s,
|
|
924
|
-
l;
|
|
925
|
-
if (max == min) h = 0;else if (r == max) h = (g - b) / delta;else if (g == max) h = 2 + (b - r) / delta;else if (b == max) h = 4 + (r - g) / delta;
|
|
926
|
-
h = Math.min(h * 60, 360);
|
|
927
|
-
if (h < 0) h += 360;
|
|
928
|
-
l = (min + max) / 2;
|
|
929
|
-
if (max == min) s = 0;else if (l <= 0.5) s = delta / (max + min);else s = delta / (2 - max - min);
|
|
930
|
-
return [h, s * 100, l * 100];
|
|
931
|
-
}
|
|
932
|
-
var rgb2hsl_1 = rgb2hsl;
|
|
933
949
|
|
|
934
950
|
/**
|
|
935
951
|
* mix-css-color
|
|
@@ -1211,9 +1227,8 @@ var Values = /*#__PURE__*/function () {
|
|
|
1211
1227
|
return Values;
|
|
1212
1228
|
}();
|
|
1213
1229
|
Values.VERSION = 'v2.1.1';
|
|
1214
|
-
var Values$1 = Values;
|
|
1215
1230
|
var mixColor = function mixColor(color) {
|
|
1216
|
-
var colorValues = new Values
|
|
1231
|
+
var colorValues = new Values(color);
|
|
1217
1232
|
return {
|
|
1218
1233
|
tint: function tint(step) {
|
|
1219
1234
|
return colorValues.tint(step).hexString();
|
|
@@ -2885,7 +2900,7 @@ var getPinInputTheme = function getPinInputTheme(theme) {
|
|
|
2885
2900
|
var space = {
|
|
2886
2901
|
spacer: theme.space.medium,
|
|
2887
2902
|
errorMessagePadding: theme.space.xsmall,
|
|
2888
|
-
hiddenInputText: theme.space.
|
|
2903
|
+
hiddenInputText: theme.space.xlarge,
|
|
2889
2904
|
hiddenInputHorrizontalPadding: theme.space.small
|
|
2890
2905
|
};
|
|
2891
2906
|
var radii = {
|
|
@@ -8488,7 +8503,6 @@ var BottomNavigation = function BottomNavigation(_ref) {
|
|
|
8488
8503
|
selectedTabKey = _ref.selectedTabKey,
|
|
8489
8504
|
tabs = _ref.tabs,
|
|
8490
8505
|
nativeProps = _objectWithoutProperties(_ref, _excluded$s);
|
|
8491
|
-
useDeprecation('BottomNavigation is deprecated and will be removed in the next major release. Please remove it.');
|
|
8492
8506
|
var insets = useSafeAreaInsets();
|
|
8493
8507
|
/**
|
|
8494
8508
|
* List of loaded tabs, tabs will be loaded when navigated to.
|
|
@@ -15526,7 +15540,6 @@ var StyledHiddenInput = index$9(TextInput$1)(function (_ref6) {
|
|
|
15526
15540
|
top: 0,
|
|
15527
15541
|
right: 0,
|
|
15528
15542
|
width: themePinLength * cellWidth + (themePinLength - 1) * spacerWidth,
|
|
15529
|
-
overflow: 'hidden',
|
|
15530
15543
|
height: '100%',
|
|
15531
15544
|
fontSize: theme.__hd__.pinInput.fontSizes.hiddenInputText,
|
|
15532
15545
|
letterSpacing: theme.__hd__.pinInput.space.hiddenInputText,
|
|
@@ -15616,6 +15629,7 @@ var PinInput = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
15616
15629
|
error: error
|
|
15617
15630
|
});
|
|
15618
15631
|
var trimmedValue = normalizeValue(value, length);
|
|
15632
|
+
var maskedValueWithExtraSpace = Platform.OS === 'android' && !trimmedValue ? '*' : trimmedValue;
|
|
15619
15633
|
var focus = useCallback(function () {
|
|
15620
15634
|
if (inputRef !== null && inputRef !== void 0 && inputRef.current) {
|
|
15621
15635
|
inputRef.current.focus();
|
|
@@ -15629,20 +15643,13 @@ var PinInput = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
15629
15643
|
}
|
|
15630
15644
|
}, []);
|
|
15631
15645
|
var changeText = useCallback(function (text) {
|
|
15646
|
+
// Prevent user from entering more than the length
|
|
15632
15647
|
var trimmedPin = normalizeValue(text, length);
|
|
15633
|
-
|
|
15634
|
-
if (trimmedValue.length === length && trimmedValue.length <= text.length) {
|
|
15635
|
-
// Slice the text, starting from the length position
|
|
15636
|
-
var slicedText = text.slice(length);
|
|
15637
|
-
onChangeText === null || onChangeText === void 0 || onChangeText(normalizeValue(slicedText, length));
|
|
15638
|
-
} else {
|
|
15639
|
-
// Prevent user from entering more than the length
|
|
15640
|
-
onChangeText === null || onChangeText === void 0 || onChangeText(trimmedPin);
|
|
15641
|
-
}
|
|
15648
|
+
onChangeText === null || onChangeText === void 0 || onChangeText(trimmedPin);
|
|
15642
15649
|
if (trimmedPin.length === length) {
|
|
15643
15650
|
onFulfill === null || onFulfill === void 0 || onFulfill(trimmedPin);
|
|
15644
15651
|
}
|
|
15645
|
-
}, [length, onChangeText, onFulfill
|
|
15652
|
+
}, [length, onChangeText, onFulfill]);
|
|
15646
15653
|
useEffect(function () {
|
|
15647
15654
|
// Must run after animations for keyboard to automatically open
|
|
15648
15655
|
if (autoFocus) {
|
|
@@ -15675,7 +15682,7 @@ var PinInput = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
15675
15682
|
}), /*#__PURE__*/React__default.createElement(StyledErrorMessage, null, error)), /*#__PURE__*/React__default.createElement(StyledHiddenInput, {
|
|
15676
15683
|
themePinLength: length,
|
|
15677
15684
|
ref: inputRef,
|
|
15678
|
-
value:
|
|
15685
|
+
value: maskedValueWithExtraSpace,
|
|
15679
15686
|
onChangeText: changeText,
|
|
15680
15687
|
secureTextEntry: secure,
|
|
15681
15688
|
editable: !disabled,
|
|
@@ -15687,11 +15694,7 @@ var PinInput = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
15687
15694
|
testID: "pin-hidden-input",
|
|
15688
15695
|
textContentType: textContentType,
|
|
15689
15696
|
autoComplete: autoComplete,
|
|
15690
|
-
selectTextOnFocus: false
|
|
15691
|
-
selection: {
|
|
15692
|
-
start: trimmedValue.length,
|
|
15693
|
-
end: trimmedValue.length + 1
|
|
15694
|
-
}
|
|
15697
|
+
selectTextOnFocus: false
|
|
15695
15698
|
}));
|
|
15696
15699
|
});
|
|
15697
15700
|
PinInput.displayName = 'PinInput';
|