@retray-dev/ui-kit 2.8.0 → 3.0.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/COMPONENTS.md +71 -15
- package/README.md +23 -3
- package/dist/index.d.mts +16 -5
- package/dist/index.d.ts +16 -5
- package/dist/index.js +441 -327
- package/dist/index.mjs +442 -328
- package/package.json +6 -3
- package/src/assets/fonts/Poppins-Black.ttf +0 -0
- package/src/assets/fonts/Poppins-BlackItalic.ttf +0 -0
- package/src/assets/fonts/Poppins-Bold.ttf +0 -0
- package/src/assets/fonts/Poppins-BoldItalic.ttf +0 -0
- package/src/assets/fonts/Poppins-ExtraBold.ttf +0 -0
- package/src/assets/fonts/Poppins-ExtraBoldItalic.ttf +0 -0
- package/src/assets/fonts/Poppins-ExtraLight.ttf +0 -0
- package/src/assets/fonts/Poppins-ExtraLightItalic.ttf +0 -0
- package/src/assets/fonts/Poppins-Italic.ttf +0 -0
- package/src/assets/fonts/Poppins-Light.ttf +0 -0
- package/src/assets/fonts/Poppins-LightItalic.ttf +0 -0
- package/src/assets/fonts/Poppins-Medium.ttf +0 -0
- package/src/assets/fonts/Poppins-MediumItalic.ttf +0 -0
- package/src/assets/fonts/Poppins-Regular.ttf +0 -0
- package/src/assets/fonts/Poppins-SemiBold.ttf +0 -0
- package/src/assets/fonts/Poppins-SemiBoldItalic.ttf +0 -0
- package/src/assets/fonts/Poppins-Thin.ttf +0 -0
- package/src/assets/fonts/Poppins-ThinItalic.ttf +0 -0
- package/src/components/Accordion/Accordion.tsx +16 -9
- package/src/components/AlertBanner/AlertBanner.tsx +35 -35
- package/src/components/Avatar/Avatar.tsx +1 -1
- package/src/components/Badge/Badge.tsx +12 -8
- package/src/components/Button/Button.tsx +8 -8
- package/src/components/Card/Card.tsx +12 -9
- package/src/components/Checkbox/Checkbox.tsx +8 -8
- package/src/components/Chip/Chip.tsx +22 -6
- package/src/components/ConfirmDialog/ConfirmDialog.tsx +86 -38
- package/src/components/CurrencyDisplay/CurrencyDisplay.tsx +1 -1
- package/src/components/CurrencyInput/CurrencyInput.tsx +11 -4
- package/src/components/EmptyState/EmptyState.tsx +2 -1
- package/src/components/Input/Input.tsx +12 -8
- package/src/components/LabelValue/LabelValue.tsx +4 -3
- package/src/components/ListItem/ListItem.tsx +10 -9
- package/src/components/MonthPicker/MonthPicker.tsx +1 -1
- package/src/components/RadioGroup/RadioGroup.tsx +36 -36
- package/src/components/Select/Select.tsx +17 -19
- package/src/components/Sheet/Sheet.tsx +2 -1
- package/src/components/Slider/Slider.tsx +3 -3
- package/src/components/Spinner/Spinner.tsx +36 -2
- package/src/components/Switch/Switch.tsx +4 -4
- package/src/components/Tabs/Tabs.tsx +9 -16
- package/src/components/Text/Text.tsx +6 -6
- package/src/components/Textarea/Textarea.tsx +8 -6
- package/src/components/Toast/Toast.tsx +27 -21
- package/src/components/Toggle/Toggle.tsx +6 -4
- package/src/fonts.ts +30 -0
- package/src/theme/colors.ts +22 -14
- package/src/theme/types.ts +4 -0
package/dist/index.js
CHANGED
|
@@ -48,33 +48,41 @@ var defaultLight = {
|
|
|
48
48
|
accent: "#e4e4e4",
|
|
49
49
|
accentForeground: "#171717",
|
|
50
50
|
destructive: "#ef4444",
|
|
51
|
-
destructiveForeground: "#
|
|
51
|
+
destructiveForeground: "#ffffff",
|
|
52
52
|
border: "#e5e5e5",
|
|
53
53
|
input: "#e5e5e5",
|
|
54
54
|
ring: "#1a1a1a",
|
|
55
|
-
success: "#
|
|
56
|
-
successForeground: "#
|
|
55
|
+
success: "#1a7a45",
|
|
56
|
+
successForeground: "#ffffff",
|
|
57
|
+
destructiveTint: "#fff5f5",
|
|
58
|
+
destructiveBorder: "#fecaca",
|
|
59
|
+
successTint: "#f0fdf4",
|
|
60
|
+
successBorder: "#bbf7d0"
|
|
57
61
|
};
|
|
58
62
|
var defaultDark = {
|
|
59
|
-
background: "#
|
|
63
|
+
background: "#0f0f0f",
|
|
60
64
|
foreground: "#fafafa",
|
|
61
|
-
card: "#
|
|
65
|
+
card: "#1c1c1c",
|
|
62
66
|
cardForeground: "#fafafa",
|
|
63
67
|
primary: "#fafafa",
|
|
64
|
-
primaryForeground: "#
|
|
65
|
-
secondary: "#
|
|
68
|
+
primaryForeground: "#0f0f0f",
|
|
69
|
+
secondary: "#272727",
|
|
66
70
|
secondaryForeground: "#fafafa",
|
|
67
|
-
muted: "#
|
|
68
|
-
mutedForeground: "#
|
|
69
|
-
accent: "#
|
|
71
|
+
muted: "#272727",
|
|
72
|
+
mutedForeground: "#9a9a9a",
|
|
73
|
+
accent: "#2e2e2e",
|
|
70
74
|
accentForeground: "#fafafa",
|
|
71
75
|
destructive: "#dc2626",
|
|
72
|
-
destructiveForeground: "#
|
|
73
|
-
border: "#
|
|
76
|
+
destructiveForeground: "#ffffff",
|
|
77
|
+
border: "#303030",
|
|
74
78
|
input: "#2a2a2a",
|
|
75
79
|
ring: "#fafafa",
|
|
76
|
-
success: "#
|
|
77
|
-
successForeground: "#
|
|
80
|
+
success: "#166534",
|
|
81
|
+
successForeground: "#ffffff",
|
|
82
|
+
destructiveTint: "#3b0a0a",
|
|
83
|
+
destructiveBorder: "#7f1d1d",
|
|
84
|
+
successTint: "#052e16",
|
|
85
|
+
successBorder: "#166534"
|
|
78
86
|
};
|
|
79
87
|
|
|
80
88
|
// src/theme/ThemeProvider.tsx
|
|
@@ -171,14 +179,14 @@ function renderIcon(name, size, color) {
|
|
|
171
179
|
// src/components/Button/Button.tsx
|
|
172
180
|
var nativeDriver = reactNative.Platform.OS !== "web";
|
|
173
181
|
var containerSizeStyles = {
|
|
174
|
-
sm: { paddingHorizontal: s(
|
|
175
|
-
md: { paddingHorizontal: s(
|
|
176
|
-
lg: { paddingHorizontal: s(
|
|
182
|
+
sm: { paddingHorizontal: s(12), paddingVertical: vs(10), minHeight: 44 },
|
|
183
|
+
md: { paddingHorizontal: s(16), paddingVertical: vs(10), minHeight: 44 },
|
|
184
|
+
lg: { paddingHorizontal: s(20), paddingVertical: vs(12), minHeight: 48 }
|
|
177
185
|
};
|
|
178
186
|
var labelSizeStyles = {
|
|
179
|
-
sm: { fontSize: ms(
|
|
180
|
-
md: { fontSize: ms(
|
|
181
|
-
lg: { fontSize: ms(
|
|
187
|
+
sm: { fontSize: ms(13) },
|
|
188
|
+
md: { fontSize: ms(15) },
|
|
189
|
+
lg: { fontSize: ms(16) }
|
|
182
190
|
};
|
|
183
191
|
var iconSizeMap = { sm: 16, md: 18, lg: 20 };
|
|
184
192
|
function Button({
|
|
@@ -255,7 +263,7 @@ function Button({
|
|
|
255
263
|
}
|
|
256
264
|
var styles = reactNative.StyleSheet.create({
|
|
257
265
|
base: {
|
|
258
|
-
borderRadius:
|
|
266
|
+
borderRadius: 8,
|
|
259
267
|
alignItems: "center",
|
|
260
268
|
justifyContent: "center",
|
|
261
269
|
flexDirection: "row"
|
|
@@ -267,7 +275,7 @@ var styles = reactNative.StyleSheet.create({
|
|
|
267
275
|
opacity: 0.5
|
|
268
276
|
},
|
|
269
277
|
label: {
|
|
270
|
-
|
|
278
|
+
fontFamily: "Poppins-SemiBold"
|
|
271
279
|
},
|
|
272
280
|
labelWithIcon: {
|
|
273
281
|
marginHorizontal: s(8)
|
|
@@ -364,12 +372,12 @@ var styles2 = reactNative.StyleSheet.create({
|
|
|
364
372
|
}
|
|
365
373
|
});
|
|
366
374
|
var variantStyles = {
|
|
367
|
-
h1: { fontSize: ms(40),
|
|
368
|
-
h2: { fontSize: ms(28),
|
|
369
|
-
h3: { fontSize: ms(22),
|
|
370
|
-
body: { fontSize: ms(17),
|
|
371
|
-
caption: { fontSize: ms(13),
|
|
372
|
-
label: { fontSize: ms(15),
|
|
375
|
+
h1: { fontFamily: "Poppins-Bold", fontSize: ms(40), lineHeight: mvs(52) },
|
|
376
|
+
h2: { fontFamily: "Poppins-Bold", fontSize: ms(28), lineHeight: mvs(36) },
|
|
377
|
+
h3: { fontFamily: "Poppins-SemiBold", fontSize: ms(22), lineHeight: mvs(30) },
|
|
378
|
+
body: { fontFamily: "Poppins-Regular", fontSize: ms(17), lineHeight: mvs(26) },
|
|
379
|
+
caption: { fontFamily: "Poppins-Regular", fontSize: ms(13), lineHeight: mvs(20) },
|
|
380
|
+
label: { fontFamily: "Poppins-Medium", fontSize: ms(15), lineHeight: mvs(22) }
|
|
373
381
|
};
|
|
374
382
|
function Text2({ variant = "body", color, style, children, ...props }) {
|
|
375
383
|
const { colors } = useTheme();
|
|
@@ -438,40 +446,44 @@ var styles3 = reactNative.StyleSheet.create({
|
|
|
438
446
|
gap: vs(8)
|
|
439
447
|
},
|
|
440
448
|
label: {
|
|
441
|
-
|
|
442
|
-
|
|
449
|
+
fontFamily: "Poppins-Medium",
|
|
450
|
+
fontSize: ms(13)
|
|
443
451
|
},
|
|
444
452
|
inputWrapper: {
|
|
445
453
|
flexDirection: "row",
|
|
446
454
|
alignItems: "center",
|
|
447
|
-
borderWidth: 1
|
|
455
|
+
borderWidth: 1,
|
|
448
456
|
borderRadius: ms(8),
|
|
449
|
-
paddingHorizontal: s(
|
|
450
|
-
paddingVertical: vs(
|
|
457
|
+
paddingHorizontal: s(14),
|
|
458
|
+
paddingVertical: vs(11)
|
|
451
459
|
},
|
|
452
460
|
input: {
|
|
461
|
+
fontFamily: "Poppins-Regular",
|
|
453
462
|
flex: 1,
|
|
454
|
-
fontSize: ms(
|
|
463
|
+
fontSize: ms(15),
|
|
455
464
|
paddingVertical: 0
|
|
456
465
|
},
|
|
457
466
|
prefixContainer: {
|
|
458
467
|
marginRight: s(8)
|
|
459
468
|
},
|
|
460
469
|
prefixText: {
|
|
461
|
-
|
|
470
|
+
fontFamily: "Poppins-Regular",
|
|
471
|
+
fontSize: ms(15),
|
|
462
472
|
marginRight: s(8)
|
|
463
473
|
},
|
|
464
474
|
suffixContainer: {
|
|
465
475
|
marginLeft: s(8)
|
|
466
476
|
},
|
|
467
477
|
suffixText: {
|
|
468
|
-
|
|
478
|
+
fontFamily: "Poppins-Regular",
|
|
479
|
+
fontSize: ms(15),
|
|
469
480
|
marginLeft: s(8)
|
|
470
481
|
},
|
|
471
482
|
passwordToggle: {
|
|
472
483
|
padding: s(4)
|
|
473
484
|
},
|
|
474
485
|
helperText: {
|
|
486
|
+
fontFamily: "Poppins-Regular",
|
|
475
487
|
fontSize: ms(13)
|
|
476
488
|
}
|
|
477
489
|
});
|
|
@@ -497,31 +509,35 @@ function Badge({ label, children, variant = "default", size = "md", icon, iconNa
|
|
|
497
509
|
default: { backgroundColor: colors.primary },
|
|
498
510
|
secondary: { backgroundColor: colors.secondary },
|
|
499
511
|
destructive: { backgroundColor: colors.destructive },
|
|
500
|
-
outline: { backgroundColor: "transparent", borderWidth: 1, borderColor: colors.border }
|
|
512
|
+
outline: { backgroundColor: "transparent", borderWidth: 1, borderColor: colors.border },
|
|
513
|
+
success: { backgroundColor: colors.success },
|
|
514
|
+
warning: { backgroundColor: "#f59e0b" },
|
|
515
|
+
successOutline: { backgroundColor: colors.successTint, borderWidth: 1, borderColor: colors.successBorder },
|
|
516
|
+
destructiveOutline: { backgroundColor: colors.destructiveTint, borderWidth: 1, borderColor: colors.destructiveBorder }
|
|
501
517
|
}[variant];
|
|
502
518
|
const textColor = {
|
|
503
519
|
default: colors.primaryForeground,
|
|
504
520
|
secondary: colors.secondaryForeground,
|
|
505
521
|
destructive: colors.destructiveForeground,
|
|
506
|
-
outline: colors.foreground
|
|
522
|
+
outline: colors.foreground,
|
|
523
|
+
success: colors.successForeground,
|
|
524
|
+
warning: "#ffffff",
|
|
525
|
+
successOutline: colors.success,
|
|
526
|
+
destructiveOutline: colors.destructive
|
|
507
527
|
}[variant];
|
|
508
528
|
const effectiveIcon = iconName ? renderIcon(iconName, sizeIconSize[size], iconColor ?? textColor) : icon;
|
|
509
529
|
const content = children ?? label;
|
|
510
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles4.container, containerStyle, sizePadding[size], { gap: sizeIconGap[size] }, style] }, effectiveIcon
|
|
530
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles4.container, containerStyle, sizePadding[size], { gap: sizeIconGap[size] }, style] }, effectiveIcon, typeof content === "string" ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles4.label, { color: textColor }, sizeFontSize[size]], allowFontScaling: true }, content) : content);
|
|
511
531
|
}
|
|
512
532
|
var styles4 = reactNative.StyleSheet.create({
|
|
513
533
|
container: {
|
|
514
|
-
borderRadius:
|
|
534
|
+
borderRadius: 9999,
|
|
515
535
|
alignSelf: "flex-start",
|
|
516
536
|
flexDirection: "row",
|
|
517
537
|
alignItems: "center"
|
|
518
538
|
},
|
|
519
|
-
iconContainer: {
|
|
520
|
-
justifyContent: "center",
|
|
521
|
-
alignItems: "center"
|
|
522
|
-
},
|
|
523
539
|
label: {
|
|
524
|
-
|
|
540
|
+
fontFamily: "Poppins-Medium"
|
|
525
541
|
}
|
|
526
542
|
});
|
|
527
543
|
var nativeDriver3 = reactNative.Platform.OS !== "web";
|
|
@@ -613,24 +629,27 @@ var styles5 = reactNative.StyleSheet.create({
|
|
|
613
629
|
borderWidth: 1
|
|
614
630
|
},
|
|
615
631
|
header: {
|
|
616
|
-
padding: s(
|
|
632
|
+
padding: s(16),
|
|
617
633
|
paddingBottom: 0,
|
|
618
|
-
gap: vs(
|
|
634
|
+
gap: vs(4)
|
|
619
635
|
},
|
|
620
636
|
title: {
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
lineHeight: mvs(
|
|
637
|
+
fontFamily: "Poppins-SemiBold",
|
|
638
|
+
fontSize: ms(16),
|
|
639
|
+
lineHeight: mvs(22)
|
|
624
640
|
},
|
|
625
641
|
description: {
|
|
626
|
-
|
|
627
|
-
|
|
642
|
+
fontFamily: "Poppins-Regular",
|
|
643
|
+
fontSize: ms(13),
|
|
644
|
+
lineHeight: mvs(18)
|
|
628
645
|
},
|
|
629
646
|
content: {
|
|
630
|
-
padding: s(
|
|
647
|
+
padding: s(16),
|
|
648
|
+
paddingTop: s(12)
|
|
631
649
|
},
|
|
632
650
|
footer: {
|
|
633
|
-
|
|
651
|
+
paddingHorizontal: s(16),
|
|
652
|
+
paddingBottom: vs(14),
|
|
634
653
|
paddingTop: 0,
|
|
635
654
|
flexDirection: "row",
|
|
636
655
|
alignItems: "center"
|
|
@@ -664,10 +683,35 @@ var sizeMap2 = {
|
|
|
664
683
|
md: "small",
|
|
665
684
|
lg: "large"
|
|
666
685
|
};
|
|
667
|
-
|
|
686
|
+
var labelFontSize = {
|
|
687
|
+
sm: ms(11),
|
|
688
|
+
md: ms(13),
|
|
689
|
+
lg: ms(14)
|
|
690
|
+
};
|
|
691
|
+
function Spinner({ size = "md", color, label, ...props }) {
|
|
668
692
|
const { colors } = useTheme();
|
|
693
|
+
if (label) {
|
|
694
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles7.wrapper }, /* @__PURE__ */ React25__default.default.createElement(reactNative.ActivityIndicator, { size: sizeMap2[size], color: color ?? colors.primary, ...props }), /* @__PURE__ */ React25__default.default.createElement(
|
|
695
|
+
reactNative.Text,
|
|
696
|
+
{
|
|
697
|
+
style: [styles7.label, { color: colors.mutedForeground, fontSize: labelFontSize[size] }],
|
|
698
|
+
allowFontScaling: true
|
|
699
|
+
},
|
|
700
|
+
label
|
|
701
|
+
));
|
|
702
|
+
}
|
|
669
703
|
return /* @__PURE__ */ React25__default.default.createElement(reactNative.ActivityIndicator, { size: sizeMap2[size], color: color ?? colors.primary, ...props });
|
|
670
704
|
}
|
|
705
|
+
var styles7 = reactNative.StyleSheet.create({
|
|
706
|
+
wrapper: {
|
|
707
|
+
alignItems: "center",
|
|
708
|
+
gap: vs(6)
|
|
709
|
+
},
|
|
710
|
+
label: {
|
|
711
|
+
fontFamily: "Poppins-Regular",
|
|
712
|
+
lineHeight: mvs(18)
|
|
713
|
+
}
|
|
714
|
+
});
|
|
671
715
|
function Skeleton({ width = "100%", height = 16, borderRadius = 6, style }) {
|
|
672
716
|
const { colors, colorScheme } = useTheme();
|
|
673
717
|
const shimmerAnim = React25.useRef(new reactNative.Animated.Value(0)).current;
|
|
@@ -692,7 +736,7 @@ function Skeleton({ width = "100%", height = 16, borderRadius = 6, style }) {
|
|
|
692
736
|
reactNative.View,
|
|
693
737
|
{
|
|
694
738
|
style: [
|
|
695
|
-
|
|
739
|
+
styles8.base,
|
|
696
740
|
{ width, height, borderRadius, backgroundColor: colors.muted },
|
|
697
741
|
style
|
|
698
742
|
],
|
|
@@ -709,7 +753,7 @@ function Skeleton({ width = "100%", height = 16, borderRadius = 6, style }) {
|
|
|
709
753
|
))
|
|
710
754
|
);
|
|
711
755
|
}
|
|
712
|
-
var
|
|
756
|
+
var styles8 = reactNative.StyleSheet.create({
|
|
713
757
|
base: {
|
|
714
758
|
overflow: "hidden"
|
|
715
759
|
}
|
|
@@ -738,7 +782,7 @@ function Avatar({ src, fallback, size = "md", style }) {
|
|
|
738
782
|
backgroundColor: colors.muted,
|
|
739
783
|
overflow: "hidden"
|
|
740
784
|
};
|
|
741
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
785
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles9.base, containerStyle, style] }, !showFallback ? /* @__PURE__ */ React25__default.default.createElement(
|
|
742
786
|
reactNative.Image,
|
|
743
787
|
{
|
|
744
788
|
source: { uri: src },
|
|
@@ -748,56 +792,59 @@ function Avatar({ src, fallback, size = "md", style }) {
|
|
|
748
792
|
) : /* @__PURE__ */ React25__default.default.createElement(
|
|
749
793
|
reactNative.Text,
|
|
750
794
|
{
|
|
751
|
-
style: [
|
|
795
|
+
style: [styles9.fallback, { color: colors.mutedForeground, fontSize: fontSizeMap[size] }],
|
|
752
796
|
allowFontScaling: true
|
|
753
797
|
},
|
|
754
798
|
fallback?.slice(0, 2).toUpperCase() ?? "?"
|
|
755
799
|
));
|
|
756
800
|
}
|
|
757
|
-
var
|
|
801
|
+
var styles9 = reactNative.StyleSheet.create({
|
|
758
802
|
base: {
|
|
759
803
|
alignItems: "center",
|
|
760
804
|
justifyContent: "center"
|
|
761
805
|
},
|
|
762
806
|
fallback: {
|
|
763
|
-
|
|
807
|
+
fontFamily: "Poppins-Medium"
|
|
764
808
|
}
|
|
765
809
|
});
|
|
766
810
|
function AlertBanner({ title, description, variant = "default", icon, iconName, iconColor, style }) {
|
|
767
811
|
const { colors } = useTheme();
|
|
768
|
-
const
|
|
769
|
-
const
|
|
770
|
-
const
|
|
771
|
-
const defaultIcon = variant === "success" ? /* @__PURE__ */ React25__default.default.createElement(vectorIcons.FontAwesome5, { name: "check-circle", size: 18, color:
|
|
772
|
-
const effectiveIcon = iconName ? renderIcon(iconName, 18, iconColor ??
|
|
773
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
812
|
+
const bgColor = variant === "destructive" ? colors.destructiveBorder : variant === "success" ? colors.successBorder : colors.card;
|
|
813
|
+
const textColor = variant === "destructive" ? "#991b1b" : variant === "success" ? "#166534" : colors.foreground;
|
|
814
|
+
const borderColor = textColor;
|
|
815
|
+
const defaultIcon = variant === "success" ? /* @__PURE__ */ React25__default.default.createElement(vectorIcons.FontAwesome5, { name: "check-circle", size: 18, color: textColor }) : variant === "destructive" ? /* @__PURE__ */ React25__default.default.createElement(vectorIcons.MaterialIcons, { name: "error-outline", size: 20, color: textColor }) : /* @__PURE__ */ React25__default.default.createElement(vectorIcons.Entypo, { name: "info-with-circle", size: 18, color: textColor });
|
|
816
|
+
const effectiveIcon = iconName ? renderIcon(iconName, 18, iconColor ?? textColor) : icon ?? defaultIcon;
|
|
817
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles10.container, { backgroundColor: bgColor, borderColor }, style] }, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles10.header }, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles10.icon }, effectiveIcon), title ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles10.title, { color: textColor }], allowFontScaling: true }, title) : null), description ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles10.description, { color: textColor, opacity: 0.85 }], allowFontScaling: true }, description) : null);
|
|
774
818
|
}
|
|
775
|
-
var
|
|
819
|
+
var styles10 = reactNative.StyleSheet.create({
|
|
776
820
|
container: {
|
|
777
|
-
flexDirection: "row",
|
|
778
821
|
borderWidth: 1,
|
|
779
822
|
borderRadius: ms(12),
|
|
780
|
-
|
|
781
|
-
|
|
823
|
+
paddingHorizontal: s(14),
|
|
824
|
+
paddingVertical: vs(12),
|
|
825
|
+
gap: vs(8),
|
|
782
826
|
shadowColor: "#000",
|
|
783
|
-
shadowOffset: { width: 0, height:
|
|
784
|
-
shadowOpacity: 0.
|
|
785
|
-
shadowRadius:
|
|
786
|
-
elevation:
|
|
827
|
+
shadowOffset: { width: 0, height: 3 },
|
|
828
|
+
shadowOpacity: 0.1,
|
|
829
|
+
shadowRadius: 8,
|
|
830
|
+
elevation: 5
|
|
831
|
+
},
|
|
832
|
+
header: {
|
|
833
|
+
flexDirection: "row",
|
|
834
|
+
alignItems: "center",
|
|
835
|
+
gap: s(10)
|
|
787
836
|
},
|
|
788
837
|
icon: {
|
|
789
838
|
marginTop: 0
|
|
790
839
|
},
|
|
791
|
-
content: {
|
|
792
|
-
flex: 1,
|
|
793
|
-
gap: vs(4)
|
|
794
|
-
},
|
|
795
840
|
title: {
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
lineHeight: mvs(20)
|
|
841
|
+
fontFamily: "Poppins-Bold",
|
|
842
|
+
fontSize: ms(15),
|
|
843
|
+
lineHeight: mvs(20),
|
|
844
|
+
flex: 1
|
|
799
845
|
},
|
|
800
846
|
description: {
|
|
847
|
+
fontFamily: "Poppins-Regular",
|
|
801
848
|
fontSize: ms(14),
|
|
802
849
|
lineHeight: mvs(20)
|
|
803
850
|
}
|
|
@@ -819,18 +866,18 @@ function Progress({ value = 0, max = 100, style }) {
|
|
|
819
866
|
return /* @__PURE__ */ React25__default.default.createElement(
|
|
820
867
|
reactNative.View,
|
|
821
868
|
{
|
|
822
|
-
style: [
|
|
869
|
+
style: [styles11.track, { backgroundColor: colors.muted }, style],
|
|
823
870
|
onLayout: (e) => setTrackWidth(e.nativeEvent.layout.width)
|
|
824
871
|
},
|
|
825
872
|
/* @__PURE__ */ React25__default.default.createElement(
|
|
826
873
|
reactNative.Animated.View,
|
|
827
874
|
{
|
|
828
|
-
style: [
|
|
875
|
+
style: [styles11.indicator, { width: animatedWidth, backgroundColor: colors.primary }]
|
|
829
876
|
}
|
|
830
877
|
)
|
|
831
878
|
);
|
|
832
879
|
}
|
|
833
|
-
var
|
|
880
|
+
var styles11 = reactNative.StyleSheet.create({
|
|
834
881
|
track: {
|
|
835
882
|
height: vs(8),
|
|
836
883
|
borderRadius: 999,
|
|
@@ -850,8 +897,8 @@ function EmptyState({ icon, iconName, iconColor, title, description, action, siz
|
|
|
850
897
|
reactNative.View,
|
|
851
898
|
{
|
|
852
899
|
style: [
|
|
853
|
-
|
|
854
|
-
isCompact &&
|
|
900
|
+
styles12.container,
|
|
901
|
+
isCompact && styles12.containerCompact,
|
|
855
902
|
{ borderColor: colors.border },
|
|
856
903
|
style
|
|
857
904
|
]
|
|
@@ -860,25 +907,25 @@ function EmptyState({ icon, iconName, iconColor, title, description, action, siz
|
|
|
860
907
|
reactNative.View,
|
|
861
908
|
{
|
|
862
909
|
style: [
|
|
863
|
-
|
|
864
|
-
isCompact &&
|
|
910
|
+
styles12.iconWrapper,
|
|
911
|
+
isCompact && styles12.iconWrapperCompact,
|
|
865
912
|
{ backgroundColor: colors.muted }
|
|
866
913
|
]
|
|
867
914
|
},
|
|
868
915
|
effectiveIcon
|
|
869
916
|
) : null,
|
|
870
|
-
/* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style:
|
|
917
|
+
/* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles12.textWrapper }, /* @__PURE__ */ React25__default.default.createElement(
|
|
871
918
|
reactNative.Text,
|
|
872
919
|
{
|
|
873
|
-
style: [
|
|
920
|
+
style: [styles12.title, isCompact && styles12.titleCompact, { color: colors.foreground }],
|
|
874
921
|
allowFontScaling: true
|
|
875
922
|
},
|
|
876
923
|
title
|
|
877
|
-
), description && !isCompact ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [
|
|
878
|
-
action && !isCompact ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style:
|
|
924
|
+
), description && !isCompact ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles12.description, { color: colors.mutedForeground }], allowFontScaling: true }, description) : null),
|
|
925
|
+
action && !isCompact ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles12.action }, action) : null
|
|
879
926
|
);
|
|
880
927
|
}
|
|
881
|
-
var
|
|
928
|
+
var styles12 = reactNative.StyleSheet.create({
|
|
882
929
|
container: {
|
|
883
930
|
alignItems: "center",
|
|
884
931
|
justifyContent: "center",
|
|
@@ -910,14 +957,15 @@ var styles11 = reactNative.StyleSheet.create({
|
|
|
910
957
|
maxWidth: s(320)
|
|
911
958
|
},
|
|
912
959
|
title: {
|
|
960
|
+
fontFamily: "Poppins-Medium",
|
|
913
961
|
fontSize: ms(18),
|
|
914
|
-
fontWeight: "500",
|
|
915
962
|
textAlign: "center"
|
|
916
963
|
},
|
|
917
964
|
titleCompact: {
|
|
918
965
|
fontSize: ms(15)
|
|
919
966
|
},
|
|
920
967
|
description: {
|
|
968
|
+
fontFamily: "Poppins-Regular",
|
|
921
969
|
fontSize: ms(14),
|
|
922
970
|
lineHeight: mvs(20),
|
|
923
971
|
textAlign: "center"
|
|
@@ -940,14 +988,14 @@ function Textarea({
|
|
|
940
988
|
}) {
|
|
941
989
|
const { colors } = useTheme();
|
|
942
990
|
const [focused, setFocused] = React25.useState(false);
|
|
943
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
991
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles13.container, containerStyle] }, label ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles13.label, { color: colors.foreground }], allowFontScaling: true }, label) : null, /* @__PURE__ */ React25__default.default.createElement(
|
|
944
992
|
reactNative.TextInput,
|
|
945
993
|
{
|
|
946
994
|
multiline: true,
|
|
947
995
|
numberOfLines: rows,
|
|
948
996
|
textAlignVertical: "top",
|
|
949
997
|
style: [
|
|
950
|
-
|
|
998
|
+
styles13.input,
|
|
951
999
|
{
|
|
952
1000
|
borderColor: error ? colors.destructive : focused ? colors.ring ?? colors.primary : colors.border,
|
|
953
1001
|
color: colors.foreground,
|
|
@@ -969,24 +1017,26 @@ function Textarea({
|
|
|
969
1017
|
allowFontScaling: true,
|
|
970
1018
|
...props
|
|
971
1019
|
}
|
|
972
|
-
), error ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [
|
|
1020
|
+
), error ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles13.helperText, { color: colors.destructive }], allowFontScaling: true }, error) : null, !error && hint ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles13.helperText, { color: colors.mutedForeground }], allowFontScaling: true }, hint) : null);
|
|
973
1021
|
}
|
|
974
|
-
var
|
|
1022
|
+
var styles13 = reactNative.StyleSheet.create({
|
|
975
1023
|
container: {
|
|
976
1024
|
gap: vs(8)
|
|
977
1025
|
},
|
|
978
1026
|
label: {
|
|
979
|
-
|
|
980
|
-
|
|
1027
|
+
fontFamily: "Poppins-Medium",
|
|
1028
|
+
fontSize: ms(13)
|
|
981
1029
|
},
|
|
982
1030
|
input: {
|
|
983
|
-
|
|
1031
|
+
fontFamily: "Poppins-Regular",
|
|
1032
|
+
borderWidth: 1,
|
|
984
1033
|
borderRadius: ms(8),
|
|
985
|
-
paddingHorizontal: s(
|
|
986
|
-
paddingVertical: vs(
|
|
987
|
-
fontSize: ms(
|
|
1034
|
+
paddingHorizontal: s(14),
|
|
1035
|
+
paddingVertical: vs(11),
|
|
1036
|
+
fontSize: ms(15)
|
|
988
1037
|
},
|
|
989
1038
|
helperText: {
|
|
1039
|
+
fontFamily: "Poppins-Regular",
|
|
990
1040
|
fontSize: ms(13)
|
|
991
1041
|
}
|
|
992
1042
|
});
|
|
@@ -1005,12 +1055,12 @@ function Checkbox({
|
|
|
1005
1055
|
reactNative.Animated.spring(scale2, { toValue: 0.95, useNativeDriver: nativeDriver4, speed: 40, bounciness: 0 }).start();
|
|
1006
1056
|
};
|
|
1007
1057
|
const handlePressOut = () => {
|
|
1008
|
-
reactNative.Animated.spring(scale2, { toValue: 1, useNativeDriver: nativeDriver4, speed: 40, bounciness:
|
|
1058
|
+
reactNative.Animated.spring(scale2, { toValue: 1, useNativeDriver: nativeDriver4, speed: 40, bounciness: 0 }).start();
|
|
1009
1059
|
};
|
|
1010
|
-
return /* @__PURE__ */ React25__default.default.createElement(
|
|
1060
|
+
return /* @__PURE__ */ React25__default.default.createElement(
|
|
1011
1061
|
reactNative.TouchableOpacity,
|
|
1012
1062
|
{
|
|
1013
|
-
style: [
|
|
1063
|
+
style: [styles14.row, style],
|
|
1014
1064
|
onPress: () => {
|
|
1015
1065
|
selectionAsync();
|
|
1016
1066
|
onCheckedChange?.(!checked);
|
|
@@ -1022,30 +1072,31 @@ function Checkbox({
|
|
|
1022
1072
|
touchSoundDisabled: true
|
|
1023
1073
|
},
|
|
1024
1074
|
/* @__PURE__ */ React25__default.default.createElement(
|
|
1025
|
-
reactNative.View,
|
|
1075
|
+
reactNative.Animated.View,
|
|
1026
1076
|
{
|
|
1027
1077
|
style: [
|
|
1028
|
-
|
|
1078
|
+
styles14.box,
|
|
1029
1079
|
{
|
|
1030
1080
|
borderColor: checked ? colors.primary : colors.border,
|
|
1031
1081
|
backgroundColor: checked ? colors.primary : "transparent",
|
|
1032
|
-
opacity: disabled ? 0.45 : 1
|
|
1082
|
+
opacity: disabled ? 0.45 : 1,
|
|
1083
|
+
transform: [{ scale: scale2 }]
|
|
1033
1084
|
}
|
|
1034
1085
|
]
|
|
1035
1086
|
},
|
|
1036
|
-
checked ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
1087
|
+
checked ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles14.checkmark, { borderColor: colors.primaryForeground }] }) : null
|
|
1037
1088
|
),
|
|
1038
1089
|
label ? /* @__PURE__ */ React25__default.default.createElement(
|
|
1039
1090
|
reactNative.Text,
|
|
1040
1091
|
{
|
|
1041
|
-
style: [
|
|
1092
|
+
style: [styles14.label, { color: disabled ? colors.mutedForeground : colors.foreground }],
|
|
1042
1093
|
allowFontScaling: true
|
|
1043
1094
|
},
|
|
1044
1095
|
label
|
|
1045
1096
|
) : null
|
|
1046
|
-
)
|
|
1097
|
+
);
|
|
1047
1098
|
}
|
|
1048
|
-
var
|
|
1099
|
+
var styles14 = reactNative.StyleSheet.create({
|
|
1049
1100
|
row: {
|
|
1050
1101
|
flexDirection: "row",
|
|
1051
1102
|
alignItems: "center",
|
|
@@ -1054,7 +1105,7 @@ var styles13 = reactNative.StyleSheet.create({
|
|
|
1054
1105
|
box: {
|
|
1055
1106
|
width: s(24),
|
|
1056
1107
|
height: s(24),
|
|
1057
|
-
borderRadius: ms(
|
|
1108
|
+
borderRadius: ms(4),
|
|
1058
1109
|
borderWidth: 1.5,
|
|
1059
1110
|
alignItems: "center",
|
|
1060
1111
|
justifyContent: "center"
|
|
@@ -1067,15 +1118,16 @@ var styles13 = reactNative.StyleSheet.create({
|
|
|
1067
1118
|
transform: [{ rotate: "-45deg" }, { translateY: -1 }]
|
|
1068
1119
|
},
|
|
1069
1120
|
label: {
|
|
1070
|
-
|
|
1071
|
-
|
|
1121
|
+
fontFamily: "Poppins-Regular",
|
|
1122
|
+
fontSize: ms(14),
|
|
1123
|
+
lineHeight: mvs(20)
|
|
1072
1124
|
}
|
|
1073
1125
|
});
|
|
1074
1126
|
var nativeDriver5 = reactNative.Platform.OS !== "web";
|
|
1075
|
-
var TRACK_WIDTH = s(
|
|
1076
|
-
var TRACK_HEIGHT =
|
|
1077
|
-
var THUMB_SIZE = s(
|
|
1078
|
-
var THUMB_OFFSET = s(
|
|
1127
|
+
var TRACK_WIDTH = s(52);
|
|
1128
|
+
var TRACK_HEIGHT = s(30);
|
|
1129
|
+
var THUMB_SIZE = s(24);
|
|
1130
|
+
var THUMB_OFFSET = s(3);
|
|
1079
1131
|
var THUMB_TRAVEL = TRACK_WIDTH - THUMB_SIZE - THUMB_OFFSET * 2;
|
|
1080
1132
|
function Switch({ checked = false, onCheckedChange, disabled, style }) {
|
|
1081
1133
|
const { colors } = useTheme();
|
|
@@ -1109,20 +1161,20 @@ function Switch({ checked = false, onCheckedChange, disabled, style }) {
|
|
|
1109
1161
|
disabled,
|
|
1110
1162
|
activeOpacity: 0.8,
|
|
1111
1163
|
touchSoundDisabled: true,
|
|
1112
|
-
style:
|
|
1164
|
+
style: styles15.wrapper
|
|
1113
1165
|
},
|
|
1114
|
-
/* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: [
|
|
1166
|
+
/* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: [styles15.track, { backgroundColor: trackColor }] }, /* @__PURE__ */ React25__default.default.createElement(
|
|
1115
1167
|
reactNative.Animated.View,
|
|
1116
1168
|
{
|
|
1117
1169
|
style: [
|
|
1118
|
-
|
|
1170
|
+
styles15.thumb,
|
|
1119
1171
|
{ backgroundColor: colors.primaryForeground, transform: [{ translateX }] }
|
|
1120
1172
|
]
|
|
1121
1173
|
}
|
|
1122
1174
|
))
|
|
1123
1175
|
));
|
|
1124
1176
|
}
|
|
1125
|
-
var
|
|
1177
|
+
var styles15 = reactNative.StyleSheet.create({
|
|
1126
1178
|
wrapper: {},
|
|
1127
1179
|
track: {
|
|
1128
1180
|
width: TRACK_WIDTH,
|
|
@@ -1145,6 +1197,7 @@ var styles14 = reactNative.StyleSheet.create({
|
|
|
1145
1197
|
elevation: 2
|
|
1146
1198
|
}
|
|
1147
1199
|
});
|
|
1200
|
+
var nativeDriver6 = reactNative.Platform.OS !== "web";
|
|
1148
1201
|
var sizeStyles = {
|
|
1149
1202
|
sm: { paddingHorizontal: s(12), paddingVertical: vs(8), minWidth: s(40), minHeight: vs(40) },
|
|
1150
1203
|
md: { paddingHorizontal: s(16), paddingVertical: vs(12), minWidth: s(44), minHeight: vs(44) },
|
|
@@ -1180,10 +1233,10 @@ function Toggle({
|
|
|
1180
1233
|
}, [pressed, pressAnim]);
|
|
1181
1234
|
const handlePressIn = () => {
|
|
1182
1235
|
if (disabled) return;
|
|
1183
|
-
reactNative.Animated.spring(scale2, { toValue: 0.95, useNativeDriver:
|
|
1236
|
+
reactNative.Animated.spring(scale2, { toValue: 0.95, useNativeDriver: nativeDriver6, speed: 40, bounciness: 0 }).start();
|
|
1184
1237
|
};
|
|
1185
1238
|
const handlePressOut = () => {
|
|
1186
|
-
reactNative.Animated.spring(scale2, { toValue: 1, useNativeDriver:
|
|
1239
|
+
reactNative.Animated.spring(scale2, { toValue: 1, useNativeDriver: nativeDriver6, speed: 40, bounciness: 4 }).start();
|
|
1187
1240
|
};
|
|
1188
1241
|
const borderColor = pressAnim.interpolate({
|
|
1189
1242
|
inputRange: [0, 1],
|
|
@@ -1215,7 +1268,7 @@ function Toggle({
|
|
|
1215
1268
|
if (custom) return /* @__PURE__ */ React25__default.default.createElement(React25__default.default.Fragment, null, custom);
|
|
1216
1269
|
return /* @__PURE__ */ React25__default.default.createElement(vectorIcons.FontAwesome5, { name: "circle", size: iconSize, color: colors.mutedForeground });
|
|
1217
1270
|
};
|
|
1218
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: [{ transform: [{ scale: scale2 }] }, disabled &&
|
|
1271
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: [{ transform: [{ scale: scale2 }] }, disabled && styles16.disabled, style] }, /* @__PURE__ */ React25__default.default.createElement(
|
|
1219
1272
|
reactNative.TouchableOpacity,
|
|
1220
1273
|
{
|
|
1221
1274
|
onPress: () => {
|
|
@@ -1233,16 +1286,16 @@ function Toggle({
|
|
|
1233
1286
|
reactNative.Animated.View,
|
|
1234
1287
|
{
|
|
1235
1288
|
style: [
|
|
1236
|
-
|
|
1289
|
+
styles16.base,
|
|
1237
1290
|
sizeStyles[size],
|
|
1238
1291
|
{ borderColor, backgroundColor, borderWidth: 2 }
|
|
1239
1292
|
]
|
|
1240
1293
|
},
|
|
1241
|
-
/* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style:
|
|
1294
|
+
/* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles16.inner }, /* @__PURE__ */ React25__default.default.createElement(LeftIcon, null), label ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.Text, { style: [styles16.label, { color: textColor }], allowFontScaling: true }, label) : null)
|
|
1242
1295
|
)
|
|
1243
1296
|
));
|
|
1244
1297
|
}
|
|
1245
|
-
var
|
|
1298
|
+
var styles16 = reactNative.StyleSheet.create({
|
|
1246
1299
|
base: {
|
|
1247
1300
|
borderRadius: ms(8)
|
|
1248
1301
|
},
|
|
@@ -1256,11 +1309,11 @@ var styles15 = reactNative.StyleSheet.create({
|
|
|
1256
1309
|
opacity: 0.45
|
|
1257
1310
|
},
|
|
1258
1311
|
label: {
|
|
1259
|
-
|
|
1260
|
-
|
|
1312
|
+
fontFamily: "Poppins-Medium",
|
|
1313
|
+
fontSize: ms(14)
|
|
1261
1314
|
}
|
|
1262
1315
|
});
|
|
1263
|
-
var
|
|
1316
|
+
var nativeDriver7 = reactNative.Platform.OS !== "web";
|
|
1264
1317
|
function RadioItem({
|
|
1265
1318
|
option,
|
|
1266
1319
|
selected,
|
|
@@ -1270,15 +1323,15 @@ function RadioItem({
|
|
|
1270
1323
|
const scale2 = React25.useRef(new reactNative.Animated.Value(1)).current;
|
|
1271
1324
|
const handlePressIn = () => {
|
|
1272
1325
|
if (option.disabled) return;
|
|
1273
|
-
reactNative.Animated.spring(scale2, { toValue: 0.95, useNativeDriver:
|
|
1326
|
+
reactNative.Animated.spring(scale2, { toValue: 0.95, useNativeDriver: nativeDriver7, speed: 40, bounciness: 0 }).start();
|
|
1274
1327
|
};
|
|
1275
1328
|
const handlePressOut = () => {
|
|
1276
|
-
reactNative.Animated.spring(scale2, { toValue: 1, useNativeDriver:
|
|
1329
|
+
reactNative.Animated.spring(scale2, { toValue: 1, useNativeDriver: nativeDriver7, speed: 40, bounciness: 4 }).start();
|
|
1277
1330
|
};
|
|
1278
|
-
return /* @__PURE__ */ React25__default.default.createElement(
|
|
1331
|
+
return /* @__PURE__ */ React25__default.default.createElement(
|
|
1279
1332
|
reactNative.TouchableOpacity,
|
|
1280
1333
|
{
|
|
1281
|
-
style:
|
|
1334
|
+
style: styles17.row,
|
|
1282
1335
|
onPress: () => {
|
|
1283
1336
|
if (!option.disabled) {
|
|
1284
1337
|
selectionAsync();
|
|
@@ -1292,30 +1345,31 @@ function RadioItem({
|
|
|
1292
1345
|
disabled: option.disabled
|
|
1293
1346
|
},
|
|
1294
1347
|
/* @__PURE__ */ React25__default.default.createElement(
|
|
1295
|
-
reactNative.View,
|
|
1348
|
+
reactNative.Animated.View,
|
|
1296
1349
|
{
|
|
1297
1350
|
style: [
|
|
1298
|
-
|
|
1351
|
+
styles17.radio,
|
|
1299
1352
|
{
|
|
1300
1353
|
borderColor: selected ? colors.primary : colors.border,
|
|
1301
|
-
opacity: option.disabled ? 0.45 : 1
|
|
1354
|
+
opacity: option.disabled ? 0.45 : 1,
|
|
1355
|
+
transform: [{ scale: scale2 }]
|
|
1302
1356
|
}
|
|
1303
1357
|
]
|
|
1304
1358
|
},
|
|
1305
|
-
selected ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
1359
|
+
selected ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles17.dot, { backgroundColor: colors.primary }] }) : null
|
|
1306
1360
|
),
|
|
1307
1361
|
/* @__PURE__ */ React25__default.default.createElement(
|
|
1308
1362
|
reactNative.Text,
|
|
1309
1363
|
{
|
|
1310
1364
|
style: [
|
|
1311
|
-
|
|
1365
|
+
styles17.label,
|
|
1312
1366
|
{ color: option.disabled ? colors.mutedForeground : colors.foreground }
|
|
1313
1367
|
],
|
|
1314
1368
|
allowFontScaling: true
|
|
1315
1369
|
},
|
|
1316
1370
|
option.label
|
|
1317
1371
|
)
|
|
1318
|
-
)
|
|
1372
|
+
);
|
|
1319
1373
|
}
|
|
1320
1374
|
function RadioGroup({
|
|
1321
1375
|
options,
|
|
@@ -1324,7 +1378,7 @@ function RadioGroup({
|
|
|
1324
1378
|
orientation = "vertical",
|
|
1325
1379
|
style
|
|
1326
1380
|
}) {
|
|
1327
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
1381
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles17.container, orientation === "horizontal" && styles17.horizontal, style] }, options.map((option) => /* @__PURE__ */ React25__default.default.createElement(
|
|
1328
1382
|
RadioItem,
|
|
1329
1383
|
{
|
|
1330
1384
|
key: option.value,
|
|
@@ -1334,7 +1388,7 @@ function RadioGroup({
|
|
|
1334
1388
|
}
|
|
1335
1389
|
)));
|
|
1336
1390
|
}
|
|
1337
|
-
var
|
|
1391
|
+
var styles17 = reactNative.StyleSheet.create({
|
|
1338
1392
|
container: {
|
|
1339
1393
|
gap: vs(12)
|
|
1340
1394
|
},
|
|
@@ -1361,11 +1415,12 @@ var styles16 = reactNative.StyleSheet.create({
|
|
|
1361
1415
|
borderRadius: s(5)
|
|
1362
1416
|
},
|
|
1363
1417
|
label: {
|
|
1418
|
+
fontFamily: "Poppins-Regular",
|
|
1364
1419
|
fontSize: ms(14),
|
|
1365
1420
|
lineHeight: mvs(20)
|
|
1366
1421
|
}
|
|
1367
1422
|
});
|
|
1368
|
-
var
|
|
1423
|
+
var nativeDriver8 = reactNative.Platform.OS !== "web";
|
|
1369
1424
|
function TabTrigger({
|
|
1370
1425
|
tab,
|
|
1371
1426
|
isActive,
|
|
@@ -1375,15 +1430,15 @@ function TabTrigger({
|
|
|
1375
1430
|
const { colors } = useTheme();
|
|
1376
1431
|
const scale2 = React25.useRef(new reactNative.Animated.Value(1)).current;
|
|
1377
1432
|
const handlePressIn = () => {
|
|
1378
|
-
reactNative.Animated.spring(scale2, { toValue: 0.95, useNativeDriver:
|
|
1433
|
+
reactNative.Animated.spring(scale2, { toValue: 0.95, useNativeDriver: nativeDriver8, speed: 40, bounciness: 0 }).start();
|
|
1379
1434
|
};
|
|
1380
1435
|
const handlePressOut = () => {
|
|
1381
|
-
reactNative.Animated.spring(scale2, { toValue: 1, useNativeDriver:
|
|
1436
|
+
reactNative.Animated.spring(scale2, { toValue: 1, useNativeDriver: nativeDriver8, speed: 40, bounciness: 4 }).start();
|
|
1382
1437
|
};
|
|
1383
1438
|
return /* @__PURE__ */ React25__default.default.createElement(
|
|
1384
1439
|
reactNative.TouchableOpacity,
|
|
1385
1440
|
{
|
|
1386
|
-
style:
|
|
1441
|
+
style: styles18.trigger,
|
|
1387
1442
|
onPress,
|
|
1388
1443
|
onPressIn: handlePressIn,
|
|
1389
1444
|
onPressOut: handlePressOut,
|
|
@@ -1391,13 +1446,13 @@ function TabTrigger({
|
|
|
1391
1446
|
activeOpacity: 1,
|
|
1392
1447
|
touchSoundDisabled: true
|
|
1393
1448
|
},
|
|
1394
|
-
/* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: { transform: [{ scale: scale2 }] } }, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style:
|
|
1449
|
+
/* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: { transform: [{ scale: scale2 }] } }, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles18.triggerInner }, tab.icon ? typeof tab.icon === "function" ? tab.icon(isActive) : tab.icon : null, /* @__PURE__ */ React25__default.default.createElement(
|
|
1395
1450
|
reactNative.Text,
|
|
1396
1451
|
{
|
|
1397
1452
|
style: [
|
|
1398
|
-
|
|
1453
|
+
styles18.triggerLabel,
|
|
1399
1454
|
{ color: isActive ? colors.foreground : colors.mutedForeground },
|
|
1400
|
-
isActive &&
|
|
1455
|
+
isActive && styles18.activeTriggerLabel
|
|
1401
1456
|
],
|
|
1402
1457
|
allowFontScaling: true
|
|
1403
1458
|
},
|
|
@@ -1446,11 +1501,11 @@ function Tabs({ tabs, value, onValueChange, children, style }) {
|
|
|
1446
1501
|
if (!value) setInternal(v);
|
|
1447
1502
|
onValueChange?.(v);
|
|
1448
1503
|
};
|
|
1449
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style }, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
1504
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style }, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles18.list, { backgroundColor: colors.muted }] }, /* @__PURE__ */ React25__default.default.createElement(
|
|
1450
1505
|
reactNative.Animated.View,
|
|
1451
1506
|
{
|
|
1452
1507
|
style: [
|
|
1453
|
-
|
|
1508
|
+
styles18.pill,
|
|
1454
1509
|
{
|
|
1455
1510
|
backgroundColor: colors.background,
|
|
1456
1511
|
position: "absolute",
|
|
@@ -1489,7 +1544,7 @@ function TabsContent({ value, activeValue, children, style }) {
|
|
|
1489
1544
|
if (value !== activeValue) return null;
|
|
1490
1545
|
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style }, children);
|
|
1491
1546
|
}
|
|
1492
|
-
var
|
|
1547
|
+
var styles18 = reactNative.StyleSheet.create({
|
|
1493
1548
|
list: {
|
|
1494
1549
|
flexDirection: "row",
|
|
1495
1550
|
borderRadius: ms(12),
|
|
@@ -1499,9 +1554,9 @@ var styles17 = reactNative.StyleSheet.create({
|
|
|
1499
1554
|
pill: {},
|
|
1500
1555
|
trigger: {
|
|
1501
1556
|
flex: 1,
|
|
1502
|
-
paddingVertical: vs(
|
|
1503
|
-
paddingHorizontal: s(
|
|
1504
|
-
borderRadius: ms(
|
|
1557
|
+
paddingVertical: vs(7),
|
|
1558
|
+
paddingHorizontal: s(10),
|
|
1559
|
+
borderRadius: ms(6),
|
|
1505
1560
|
alignItems: "center",
|
|
1506
1561
|
justifyContent: "center",
|
|
1507
1562
|
zIndex: 1
|
|
@@ -1510,19 +1565,14 @@ var styles17 = reactNative.StyleSheet.create({
|
|
|
1510
1565
|
flexDirection: "row",
|
|
1511
1566
|
alignItems: "center",
|
|
1512
1567
|
justifyContent: "center",
|
|
1513
|
-
gap: s(
|
|
1514
|
-
},
|
|
1515
|
-
triggerIcon: {
|
|
1516
|
-
marginRight: s(6),
|
|
1517
|
-
alignItems: "center",
|
|
1518
|
-
justifyContent: "center"
|
|
1568
|
+
gap: s(4)
|
|
1519
1569
|
},
|
|
1520
1570
|
triggerLabel: {
|
|
1521
|
-
|
|
1522
|
-
|
|
1571
|
+
fontFamily: "Poppins-Regular",
|
|
1572
|
+
fontSize: ms(13)
|
|
1523
1573
|
},
|
|
1524
1574
|
activeTriggerLabel: {
|
|
1525
|
-
|
|
1575
|
+
fontFamily: "Poppins-Medium"
|
|
1526
1576
|
}
|
|
1527
1577
|
});
|
|
1528
1578
|
function AccordionItemComponent({
|
|
@@ -1555,21 +1605,21 @@ function AccordionItemComponent({
|
|
|
1555
1605
|
const rotationStyle = Animated11.useAnimatedStyle(() => ({
|
|
1556
1606
|
transform: [{ rotate: `${derivedRotation.value * 180}deg` }]
|
|
1557
1607
|
}));
|
|
1558
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
1608
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles19.item, { backgroundColor: colors.card, borderColor: colors.border }] }, /* @__PURE__ */ React25__default.default.createElement(
|
|
1559
1609
|
reactNative.Pressable,
|
|
1560
1610
|
{
|
|
1561
|
-
style: ({ pressed }) => [
|
|
1611
|
+
style: ({ pressed }) => [styles19.trigger, { opacity: pressed ? 0.6 : 1 }],
|
|
1562
1612
|
onPress: () => {
|
|
1563
1613
|
selectionAsync();
|
|
1564
1614
|
onToggle();
|
|
1565
1615
|
}
|
|
1566
1616
|
},
|
|
1567
|
-
/* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [
|
|
1568
|
-
/* @__PURE__ */ React25__default.default.createElement(Animated11__default.default.View, { style: [
|
|
1617
|
+
/* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles19.triggerText, { color: colors.foreground }], allowFontScaling: true }, item.trigger),
|
|
1618
|
+
/* @__PURE__ */ React25__default.default.createElement(Animated11__default.default.View, { style: [styles19.chevron, rotationStyle] }, /* @__PURE__ */ React25__default.default.createElement(vectorIcons.Entypo, { name: "chevron-down", size: 18, color: colors.mutedForeground }))
|
|
1569
1619
|
), /* @__PURE__ */ React25__default.default.createElement(Animated11__default.default.View, { style: bodyStyle }, /* @__PURE__ */ React25__default.default.createElement(
|
|
1570
1620
|
reactNative.View,
|
|
1571
1621
|
{
|
|
1572
|
-
style:
|
|
1622
|
+
style: styles19.content,
|
|
1573
1623
|
onLayout: (e) => {
|
|
1574
1624
|
height.value = e.nativeEvent.layout.height;
|
|
1575
1625
|
}
|
|
@@ -1591,7 +1641,7 @@ function Accordion({ items, type = "single", defaultValue, style }) {
|
|
|
1591
1641
|
);
|
|
1592
1642
|
}
|
|
1593
1643
|
};
|
|
1594
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style }, items.map((item) => /* @__PURE__ */ React25__default.default.createElement(
|
|
1644
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles19.list, style] }, items.map((item) => /* @__PURE__ */ React25__default.default.createElement(
|
|
1595
1645
|
AccordionItemComponent,
|
|
1596
1646
|
{
|
|
1597
1647
|
key: item.value,
|
|
@@ -1601,19 +1651,25 @@ function Accordion({ items, type = "single", defaultValue, style }) {
|
|
|
1601
1651
|
}
|
|
1602
1652
|
)));
|
|
1603
1653
|
}
|
|
1604
|
-
var
|
|
1654
|
+
var styles19 = reactNative.StyleSheet.create({
|
|
1655
|
+
list: {
|
|
1656
|
+
gap: s(6)
|
|
1657
|
+
},
|
|
1605
1658
|
item: {
|
|
1606
|
-
|
|
1659
|
+
borderWidth: 1,
|
|
1660
|
+
borderRadius: ms(10),
|
|
1661
|
+
overflow: "hidden"
|
|
1607
1662
|
},
|
|
1608
1663
|
trigger: {
|
|
1609
1664
|
flexDirection: "row",
|
|
1610
1665
|
justifyContent: "space-between",
|
|
1611
1666
|
alignItems: "center",
|
|
1612
|
-
|
|
1667
|
+
paddingHorizontal: s(14),
|
|
1668
|
+
paddingVertical: vs(12)
|
|
1613
1669
|
},
|
|
1614
1670
|
triggerText: {
|
|
1615
|
-
|
|
1616
|
-
|
|
1671
|
+
fontFamily: "Poppins-Medium",
|
|
1672
|
+
fontSize: ms(14),
|
|
1617
1673
|
flex: 1
|
|
1618
1674
|
},
|
|
1619
1675
|
chevron: {
|
|
@@ -1622,7 +1678,8 @@ var styles18 = reactNative.StyleSheet.create({
|
|
|
1622
1678
|
// position:'absolute' is the key — the inner View escapes the animated wrapper's
|
|
1623
1679
|
// clipped height so onLayout always reports the true content height.
|
|
1624
1680
|
content: {
|
|
1625
|
-
|
|
1681
|
+
paddingHorizontal: s(14),
|
|
1682
|
+
paddingBottom: vs(12),
|
|
1626
1683
|
position: "absolute",
|
|
1627
1684
|
width: "100%"
|
|
1628
1685
|
}
|
|
@@ -1650,7 +1707,7 @@ function Slider({
|
|
|
1650
1707
|
}
|
|
1651
1708
|
onValueChange?.(v);
|
|
1652
1709
|
};
|
|
1653
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
1710
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles20.wrapper, style], accessibilityLabel }, label || showValue ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles20.header }, label ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles20.label, { color: colors.foreground }], allowFontScaling: true }, label) : null, showValue ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles20.valueText, { color: colors.mutedForeground }], allowFontScaling: true }, formatValue2(value)) : null) : null, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: disabled ? styles20.disabled : void 0 }, /* @__PURE__ */ React25__default.default.createElement(
|
|
1654
1711
|
RNSlider__default.default,
|
|
1655
1712
|
{
|
|
1656
1713
|
value,
|
|
@@ -1663,12 +1720,12 @@ function Slider({
|
|
|
1663
1720
|
minimumTrackTintColor: colors.primary,
|
|
1664
1721
|
maximumTrackTintColor: colors.muted,
|
|
1665
1722
|
thumbTintColor: colors.primary,
|
|
1666
|
-
style:
|
|
1723
|
+
style: styles20.slider,
|
|
1667
1724
|
accessibilityLabel
|
|
1668
1725
|
}
|
|
1669
1726
|
)));
|
|
1670
1727
|
}
|
|
1671
|
-
var
|
|
1728
|
+
var styles20 = reactNative.StyleSheet.create({
|
|
1672
1729
|
wrapper: {
|
|
1673
1730
|
gap: vs(8)
|
|
1674
1731
|
},
|
|
@@ -1678,16 +1735,16 @@ var styles19 = reactNative.StyleSheet.create({
|
|
|
1678
1735
|
alignItems: "center"
|
|
1679
1736
|
},
|
|
1680
1737
|
label: {
|
|
1681
|
-
|
|
1682
|
-
|
|
1738
|
+
fontFamily: "Poppins-Medium",
|
|
1739
|
+
fontSize: ms(15)
|
|
1683
1740
|
},
|
|
1684
1741
|
valueText: {
|
|
1685
|
-
|
|
1686
|
-
|
|
1742
|
+
fontFamily: "Poppins-Medium",
|
|
1743
|
+
fontSize: ms(14)
|
|
1687
1744
|
},
|
|
1688
1745
|
slider: {
|
|
1689
1746
|
width: "100%",
|
|
1690
|
-
height: vs(
|
|
1747
|
+
height: vs(60)
|
|
1691
1748
|
},
|
|
1692
1749
|
disabled: {
|
|
1693
1750
|
opacity: 0.45
|
|
@@ -1728,14 +1785,14 @@ function Sheet({
|
|
|
1728
1785
|
snapPoints,
|
|
1729
1786
|
onDismiss: onClose,
|
|
1730
1787
|
backdropComponent: renderBackdrop,
|
|
1731
|
-
backgroundStyle: [
|
|
1732
|
-
handleIndicatorStyle: [
|
|
1788
|
+
backgroundStyle: [styles21.background, { backgroundColor: colors.card }],
|
|
1789
|
+
handleIndicatorStyle: [styles21.handle, { backgroundColor: colors.border }],
|
|
1733
1790
|
enablePanDownToClose: true
|
|
1734
1791
|
},
|
|
1735
|
-
/* @__PURE__ */ React25__default.default.createElement(bottomSheet.BottomSheetView, { style: [
|
|
1792
|
+
/* @__PURE__ */ React25__default.default.createElement(bottomSheet.BottomSheetView, { style: [styles21.content, style] }, title || description ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles21.header }, title ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles21.title, { color: colors.cardForeground }], allowFontScaling: true }, title) : null, description ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles21.description, { color: colors.mutedForeground }], allowFontScaling: true }, description) : null) : null, children)
|
|
1736
1793
|
);
|
|
1737
1794
|
}
|
|
1738
|
-
var
|
|
1795
|
+
var styles21 = reactNative.StyleSheet.create({
|
|
1739
1796
|
background: {
|
|
1740
1797
|
borderTopLeftRadius: ms(16),
|
|
1741
1798
|
borderTopRightRadius: ms(16)
|
|
@@ -1754,10 +1811,11 @@ var styles20 = reactNative.StyleSheet.create({
|
|
|
1754
1811
|
marginBottom: vs(16)
|
|
1755
1812
|
},
|
|
1756
1813
|
title: {
|
|
1757
|
-
|
|
1758
|
-
|
|
1814
|
+
fontFamily: "Poppins-SemiBold",
|
|
1815
|
+
fontSize: ms(18)
|
|
1759
1816
|
},
|
|
1760
1817
|
description: {
|
|
1818
|
+
fontFamily: "Poppins-Regular",
|
|
1761
1819
|
fontSize: ms(14),
|
|
1762
1820
|
lineHeight: mvs(20)
|
|
1763
1821
|
}
|
|
@@ -1765,6 +1823,7 @@ var styles20 = reactNative.StyleSheet.create({
|
|
|
1765
1823
|
var isIOS = reactNative.Platform.OS === "ios";
|
|
1766
1824
|
var isAndroid = reactNative.Platform.OS === "android";
|
|
1767
1825
|
var isWeb2 = reactNative.Platform.OS === "web";
|
|
1826
|
+
var nativeDriver9 = reactNative.Platform.OS !== "web";
|
|
1768
1827
|
function Select({
|
|
1769
1828
|
options,
|
|
1770
1829
|
value,
|
|
@@ -1783,10 +1842,10 @@ function Select({
|
|
|
1783
1842
|
const selected = options.find((o) => o.value === value);
|
|
1784
1843
|
const handlePressIn = () => {
|
|
1785
1844
|
if (disabled) return;
|
|
1786
|
-
reactNative.Animated.spring(scale2, { toValue: 0.95, useNativeDriver:
|
|
1845
|
+
reactNative.Animated.spring(scale2, { toValue: 0.95, useNativeDriver: nativeDriver9, speed: 40, bounciness: 0 }).start();
|
|
1787
1846
|
};
|
|
1788
1847
|
const handlePressOut = () => {
|
|
1789
|
-
reactNative.Animated.spring(scale2, { toValue: 1, useNativeDriver:
|
|
1848
|
+
reactNative.Animated.spring(scale2, { toValue: 1, useNativeDriver: nativeDriver9, speed: 40, bounciness: 4 }).start();
|
|
1790
1849
|
};
|
|
1791
1850
|
const handleOpen = () => {
|
|
1792
1851
|
if (disabled) return;
|
|
@@ -1808,11 +1867,11 @@ function Select({
|
|
|
1808
1867
|
}
|
|
1809
1868
|
setPickerVisible(false);
|
|
1810
1869
|
};
|
|
1811
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
1870
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles22.container, style] }, label ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles22.label, { color: colors.foreground }], allowFontScaling: true }, label) : null, !isWeb2 ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: { transform: [{ scale: scale2 }], opacity: disabled ? 0.45 : 1 } }, /* @__PURE__ */ React25__default.default.createElement(
|
|
1812
1871
|
reactNative.TouchableOpacity,
|
|
1813
1872
|
{
|
|
1814
1873
|
style: [
|
|
1815
|
-
|
|
1874
|
+
styles22.trigger,
|
|
1816
1875
|
{
|
|
1817
1876
|
borderColor: error ? colors.destructive : colors.border,
|
|
1818
1877
|
backgroundColor: colors.background
|
|
@@ -1828,7 +1887,7 @@ function Select({
|
|
|
1828
1887
|
reactNative.Text,
|
|
1829
1888
|
{
|
|
1830
1889
|
style: [
|
|
1831
|
-
|
|
1890
|
+
styles22.triggerText,
|
|
1832
1891
|
{ color: selected ? colors.foreground : colors.mutedForeground }
|
|
1833
1892
|
],
|
|
1834
1893
|
numberOfLines: 1,
|
|
@@ -1845,8 +1904,8 @@ function Select({
|
|
|
1845
1904
|
animationType: "slide",
|
|
1846
1905
|
onRequestClose: handleDismiss
|
|
1847
1906
|
},
|
|
1848
|
-
/* @__PURE__ */ React25__default.default.createElement(reactNative.TouchableOpacity, { style:
|
|
1849
|
-
/* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
1907
|
+
/* @__PURE__ */ React25__default.default.createElement(reactNative.TouchableOpacity, { style: styles22.iosBackdrop, activeOpacity: 1, onPress: handleDismiss }),
|
|
1908
|
+
/* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles22.iosSheet, { backgroundColor: colors.card }] }, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles22.iosToolbar, { borderBottomColor: colors.border }] }, label ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles22.iosToolbarTitle, { color: colors.foreground }], allowFontScaling: true }, label) : /* @__PURE__ */ React25__default.default.createElement(reactNative.View, null), /* @__PURE__ */ React25__default.default.createElement(reactNative.TouchableOpacity, { onPress: handleConfirm, style: styles22.iosDoneBtn, hitSlop: { top: 8, bottom: 8, left: 8, right: 8 } }, /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles22.iosDoneBtnText, { color: colors.primary }], allowFontScaling: true }, "Done"))), /* @__PURE__ */ React25__default.default.createElement(
|
|
1850
1909
|
picker.Picker,
|
|
1851
1910
|
{
|
|
1852
1911
|
selectedValue: pendingValue ?? "",
|
|
@@ -1879,7 +1938,7 @@ function Select({
|
|
|
1879
1938
|
mode: "dialog",
|
|
1880
1939
|
enabled: !disabled,
|
|
1881
1940
|
prompt: label,
|
|
1882
|
-
style:
|
|
1941
|
+
style: styles22.androidHiddenPicker
|
|
1883
1942
|
},
|
|
1884
1943
|
!value ? /* @__PURE__ */ React25__default.default.createElement(picker.Picker.Item, { label: placeholder, value: "", enabled: false }) : null,
|
|
1885
1944
|
options.map((o) => /* @__PURE__ */ React25__default.default.createElement(
|
|
@@ -1902,7 +1961,7 @@ function Select({
|
|
|
1902
1961
|
},
|
|
1903
1962
|
enabled: !disabled,
|
|
1904
1963
|
style: [
|
|
1905
|
-
|
|
1964
|
+
styles22.webPicker,
|
|
1906
1965
|
{
|
|
1907
1966
|
borderColor: error ? colors.destructive : colors.border,
|
|
1908
1967
|
color: selected ? colors.foreground : colors.mutedForeground,
|
|
@@ -1921,38 +1980,35 @@ function Select({
|
|
|
1921
1980
|
enabled: !o.disabled
|
|
1922
1981
|
}
|
|
1923
1982
|
))
|
|
1924
|
-
) : null, error ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [
|
|
1983
|
+
) : null, error ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles22.helperText, { color: colors.destructive }], allowFontScaling: true }, error) : null);
|
|
1925
1984
|
}
|
|
1926
|
-
var
|
|
1985
|
+
var styles22 = reactNative.StyleSheet.create({
|
|
1927
1986
|
container: {
|
|
1928
1987
|
gap: vs(8)
|
|
1929
1988
|
},
|
|
1930
1989
|
label: {
|
|
1931
|
-
|
|
1932
|
-
|
|
1990
|
+
fontFamily: "Poppins-Medium",
|
|
1991
|
+
fontSize: ms(13)
|
|
1933
1992
|
},
|
|
1934
1993
|
trigger: {
|
|
1935
1994
|
flexDirection: "row",
|
|
1936
1995
|
alignItems: "center",
|
|
1937
1996
|
justifyContent: "space-between",
|
|
1938
|
-
borderWidth: 1
|
|
1997
|
+
borderWidth: 1,
|
|
1939
1998
|
borderRadius: ms(8),
|
|
1940
|
-
paddingHorizontal: s(
|
|
1941
|
-
paddingVertical: vs(
|
|
1942
|
-
shadowColor: "#000",
|
|
1943
|
-
shadowOffset: { width: 0, height: 1 },
|
|
1944
|
-
shadowOpacity: 0.04,
|
|
1945
|
-
shadowRadius: 2,
|
|
1946
|
-
elevation: 1
|
|
1999
|
+
paddingHorizontal: s(14),
|
|
2000
|
+
paddingVertical: vs(11)
|
|
1947
2001
|
},
|
|
1948
2002
|
triggerText: {
|
|
1949
|
-
|
|
2003
|
+
fontFamily: "Poppins-Regular",
|
|
2004
|
+
fontSize: ms(15),
|
|
1950
2005
|
flex: 1
|
|
1951
2006
|
},
|
|
1952
2007
|
chevron: {
|
|
1953
2008
|
marginLeft: s(8)
|
|
1954
2009
|
},
|
|
1955
2010
|
helperText: {
|
|
2011
|
+
fontFamily: "Poppins-Regular",
|
|
1956
2012
|
fontSize: ms(13)
|
|
1957
2013
|
},
|
|
1958
2014
|
iosBackdrop: {
|
|
@@ -1973,15 +2029,15 @@ var styles21 = reactNative.StyleSheet.create({
|
|
|
1973
2029
|
borderBottomWidth: 1
|
|
1974
2030
|
},
|
|
1975
2031
|
iosToolbarTitle: {
|
|
1976
|
-
|
|
1977
|
-
|
|
2032
|
+
fontFamily: "Poppins-SemiBold",
|
|
2033
|
+
fontSize: ms(17)
|
|
1978
2034
|
},
|
|
1979
2035
|
iosDoneBtn: {
|
|
1980
2036
|
padding: s(4)
|
|
1981
2037
|
},
|
|
1982
2038
|
iosDoneBtnText: {
|
|
1983
|
-
|
|
1984
|
-
|
|
2039
|
+
fontFamily: "Poppins-SemiBold",
|
|
2040
|
+
fontSize: ms(17)
|
|
1985
2041
|
},
|
|
1986
2042
|
androidHiddenPicker: {
|
|
1987
2043
|
height: 0,
|
|
@@ -1989,11 +2045,11 @@ var styles21 = reactNative.StyleSheet.create({
|
|
|
1989
2045
|
position: "absolute"
|
|
1990
2046
|
},
|
|
1991
2047
|
webPicker: {
|
|
1992
|
-
borderWidth: 1
|
|
2048
|
+
borderWidth: 1,
|
|
1993
2049
|
borderRadius: ms(8),
|
|
1994
|
-
paddingHorizontal: s(
|
|
1995
|
-
paddingVertical: vs(
|
|
1996
|
-
fontSize: ms(
|
|
2050
|
+
paddingHorizontal: s(14),
|
|
2051
|
+
paddingVertical: vs(11),
|
|
2052
|
+
fontSize: ms(15)
|
|
1997
2053
|
}
|
|
1998
2054
|
});
|
|
1999
2055
|
var ToastContext = React25.createContext({
|
|
@@ -2041,19 +2097,21 @@ function ToastNotification({ item, onDismiss }) {
|
|
|
2041
2097
|
opacity: opacity.value,
|
|
2042
2098
|
transform: [{ translateY: translateY.value }, { translateX: translateX.value }]
|
|
2043
2099
|
}));
|
|
2100
|
+
const variant = item.variant ?? "default";
|
|
2044
2101
|
const bgColor = {
|
|
2045
2102
|
default: colors.foreground,
|
|
2046
|
-
destructive: colors.
|
|
2047
|
-
success: colors.
|
|
2048
|
-
}[
|
|
2103
|
+
destructive: colors.destructiveBorder,
|
|
2104
|
+
success: colors.successBorder
|
|
2105
|
+
}[variant];
|
|
2049
2106
|
const textColor = {
|
|
2050
2107
|
default: colors.background,
|
|
2051
|
-
destructive:
|
|
2052
|
-
success:
|
|
2053
|
-
}[
|
|
2054
|
-
const
|
|
2108
|
+
destructive: "#991b1b",
|
|
2109
|
+
success: "#166534"
|
|
2110
|
+
}[variant];
|
|
2111
|
+
const borderColor = textColor;
|
|
2112
|
+
const defaultIcon = variant === "success" ? /* @__PURE__ */ React25__default.default.createElement(vectorIcons.FontAwesome5, { name: "check-circle", size: 18, color: textColor }) : variant === "destructive" ? /* @__PURE__ */ React25__default.default.createElement(vectorIcons.AntDesign, { name: "exclamation-circle", size: 18, color: textColor }) : /* @__PURE__ */ React25__default.default.createElement(vectorIcons.Entypo, { name: "info-with-circle", size: 18, color: textColor });
|
|
2055
2113
|
const leftIcon = item.iconName ? renderIcon(item.iconName, 22, item.iconColor ?? textColor) : item.icon ?? defaultIcon;
|
|
2056
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNativeGestureHandler.GestureDetector, { gesture: panGesture }, /* @__PURE__ */ React25__default.default.createElement(Animated11__default.default.View, { style: [
|
|
2114
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNativeGestureHandler.GestureDetector, { gesture: panGesture }, /* @__PURE__ */ React25__default.default.createElement(Animated11__default.default.View, { style: [styles23.toast, { backgroundColor: bgColor, borderColor }, animatedStyle] }, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles23.leftIconContainer }, leftIcon), /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles23.toastContent }, item.title ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles23.toastTitle, { color: textColor }], allowFontScaling: true }, item.title) : null, item.description ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles23.toastDescription, { color: textColor, opacity: 0.85 }], allowFontScaling: true }, item.description) : null), /* @__PURE__ */ React25__default.default.createElement(reactNative.TouchableOpacity, { onPress: onDismiss, style: styles23.dismissButton, touchSoundDisabled: true }, /* @__PURE__ */ React25__default.default.createElement(vectorIcons.AntDesign, { name: "close-circle", size: 18, color: textColor }))));
|
|
2057
2115
|
}
|
|
2058
2116
|
function ToastProvider({ children }) {
|
|
2059
2117
|
const [toasts, setToasts] = React25.useState([]);
|
|
@@ -2072,9 +2130,9 @@ function ToastProvider({ children }) {
|
|
|
2072
2130
|
const dismiss = React25.useCallback((id) => {
|
|
2073
2131
|
setToasts((prev) => prev.filter((t) => t.id !== id));
|
|
2074
2132
|
}, []);
|
|
2075
|
-
return /* @__PURE__ */ React25__default.default.createElement(ToastContext.Provider, { value: { toast, dismiss } }, children, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
2133
|
+
return /* @__PURE__ */ React25__default.default.createElement(ToastContext.Provider, { value: { toast, dismiss } }, children, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles23.container, reactNative.Platform.OS === "web" && styles23.containerWeb, { top: insets.top + 8 }], pointerEvents: "box-none" }, toasts.map((item) => /* @__PURE__ */ React25__default.default.createElement(ToastNotification, { key: item.id, item, onDismiss: () => dismiss(item.id) }))));
|
|
2076
2134
|
}
|
|
2077
|
-
var
|
|
2135
|
+
var styles23 = reactNative.StyleSheet.create({
|
|
2078
2136
|
container: {
|
|
2079
2137
|
position: "absolute",
|
|
2080
2138
|
left: s(16),
|
|
@@ -2091,30 +2149,32 @@ var styles22 = reactNative.StyleSheet.create({
|
|
|
2091
2149
|
toast: {
|
|
2092
2150
|
flexDirection: "row",
|
|
2093
2151
|
alignItems: "center",
|
|
2094
|
-
borderRadius: ms(
|
|
2095
|
-
|
|
2096
|
-
|
|
2152
|
+
borderRadius: ms(12),
|
|
2153
|
+
borderWidth: 1,
|
|
2154
|
+
paddingHorizontal: s(14),
|
|
2155
|
+
paddingVertical: vs(12),
|
|
2097
2156
|
shadowColor: "#000",
|
|
2098
|
-
shadowOffset: { width: 0, height:
|
|
2099
|
-
shadowOpacity: 0.
|
|
2157
|
+
shadowOffset: { width: 0, height: 3 },
|
|
2158
|
+
shadowOpacity: 0.1,
|
|
2100
2159
|
shadowRadius: 8,
|
|
2101
|
-
elevation:
|
|
2160
|
+
elevation: 5
|
|
2102
2161
|
},
|
|
2103
2162
|
toastContent: {
|
|
2104
2163
|
flex: 1,
|
|
2105
2164
|
gap: vs(4)
|
|
2106
2165
|
},
|
|
2107
2166
|
leftIconContainer: {
|
|
2108
|
-
width: s(
|
|
2167
|
+
width: s(28),
|
|
2109
2168
|
alignItems: "center",
|
|
2110
2169
|
justifyContent: "center",
|
|
2111
|
-
marginRight: s(
|
|
2170
|
+
marginRight: s(10)
|
|
2112
2171
|
},
|
|
2113
2172
|
toastTitle: {
|
|
2114
|
-
|
|
2115
|
-
|
|
2173
|
+
fontFamily: "Poppins-SemiBold",
|
|
2174
|
+
fontSize: ms(15)
|
|
2116
2175
|
},
|
|
2117
2176
|
toastDescription: {
|
|
2177
|
+
fontFamily: "Poppins-Regular",
|
|
2118
2178
|
fontSize: ms(14)
|
|
2119
2179
|
},
|
|
2120
2180
|
dismissButton: {
|
|
@@ -2139,30 +2199,33 @@ function CurrencyInput({
|
|
|
2139
2199
|
hint,
|
|
2140
2200
|
placeholder,
|
|
2141
2201
|
editable,
|
|
2202
|
+
prefixIcon,
|
|
2142
2203
|
containerStyle,
|
|
2143
2204
|
style
|
|
2144
2205
|
}) {
|
|
2145
2206
|
const handleChange = (text) => {
|
|
2146
2207
|
const withoutPrefix = prefix && text.startsWith(prefix) ? text.slice(prefix.length) : text;
|
|
2147
2208
|
const formatted = formatCurrency(withoutPrefix, thousandsSeparator);
|
|
2148
|
-
const display = formatted
|
|
2209
|
+
const display = formatted;
|
|
2149
2210
|
onChangeText?.(display);
|
|
2150
2211
|
const separatorRegex = new RegExp(`\\${thousandsSeparator}`, "g");
|
|
2151
2212
|
const raw = parseFloat(formatted.replace(separatorRegex, "") || "0");
|
|
2152
2213
|
onChangeValue?.(isNaN(raw) ? 0 : raw);
|
|
2153
2214
|
};
|
|
2154
|
-
const inputStyle = size === "large" ? { fontSize: ms(36) } : {};
|
|
2215
|
+
const inputStyle = size === "large" ? { fontFamily: "Poppins-Regular", fontSize: ms(36) } : { fontFamily: "Poppins-Regular" };
|
|
2216
|
+
const displayValue = value && prefix && value.startsWith(prefix) ? value.slice(prefix.length) : value;
|
|
2155
2217
|
return /* @__PURE__ */ React25__default.default.createElement(
|
|
2156
2218
|
Input,
|
|
2157
2219
|
{
|
|
2158
|
-
value,
|
|
2220
|
+
value: displayValue,
|
|
2159
2221
|
onChangeText: handleChange,
|
|
2160
2222
|
keyboardType: "numeric",
|
|
2161
2223
|
label,
|
|
2162
2224
|
error,
|
|
2163
2225
|
hint,
|
|
2164
|
-
placeholder: placeholder ??
|
|
2226
|
+
placeholder: placeholder ?? "0",
|
|
2165
2227
|
editable,
|
|
2228
|
+
prefix: prefixIcon,
|
|
2166
2229
|
containerStyle,
|
|
2167
2230
|
style: [inputStyle, style]
|
|
2168
2231
|
}
|
|
@@ -2183,16 +2246,16 @@ function formatValue(value, prefix, showDecimals) {
|
|
|
2183
2246
|
function CurrencyDisplay({ value, prefix = "$", showDecimals = false, textColor, style }) {
|
|
2184
2247
|
const { colors } = useTheme();
|
|
2185
2248
|
const formatted = formatValue(value, prefix, showDecimals);
|
|
2186
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
2249
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles24.container, style] }, /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles24.amount, { color: textColor ?? colors.foreground }], allowFontScaling: true }, formatted));
|
|
2187
2250
|
}
|
|
2188
|
-
var
|
|
2251
|
+
var styles24 = reactNative.StyleSheet.create({
|
|
2189
2252
|
container: {},
|
|
2190
2253
|
amount: {
|
|
2191
|
-
|
|
2192
|
-
|
|
2254
|
+
fontFamily: "Poppins-Bold",
|
|
2255
|
+
fontSize: ms(56)
|
|
2193
2256
|
}
|
|
2194
2257
|
});
|
|
2195
|
-
var
|
|
2258
|
+
var nativeDriver10 = reactNative.Platform.OS !== "web";
|
|
2196
2259
|
function ListItem({
|
|
2197
2260
|
leftRender,
|
|
2198
2261
|
rightRender,
|
|
@@ -2221,7 +2284,7 @@ function ListItem({
|
|
|
2221
2284
|
if (!onPress || disabled) return;
|
|
2222
2285
|
reactNative.Animated.spring(scale2, {
|
|
2223
2286
|
toValue: 0.97,
|
|
2224
|
-
useNativeDriver:
|
|
2287
|
+
useNativeDriver: nativeDriver10,
|
|
2225
2288
|
speed: 40,
|
|
2226
2289
|
bounciness: 0
|
|
2227
2290
|
}).start();
|
|
@@ -2229,7 +2292,7 @@ function ListItem({
|
|
|
2229
2292
|
const handlePressOut = () => {
|
|
2230
2293
|
reactNative.Animated.spring(scale2, {
|
|
2231
2294
|
toValue: 1,
|
|
2232
|
-
useNativeDriver:
|
|
2295
|
+
useNativeDriver: nativeDriver10,
|
|
2233
2296
|
speed: 40,
|
|
2234
2297
|
bounciness: 4
|
|
2235
2298
|
}).start();
|
|
@@ -2251,10 +2314,10 @@ function ListItem({
|
|
|
2251
2314
|
shadowRadius: 6,
|
|
2252
2315
|
elevation: 2
|
|
2253
2316
|
} : {};
|
|
2254
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: [{ transform: [{ scale: scale2 }] }, disabled &&
|
|
2317
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: [{ transform: [{ scale: scale2 }] }, disabled && styles25.disabled] }, /* @__PURE__ */ React25__default.default.createElement(
|
|
2255
2318
|
reactNative.TouchableOpacity,
|
|
2256
2319
|
{
|
|
2257
|
-
style: [
|
|
2320
|
+
style: [styles25.container, cardStyle, style],
|
|
2258
2321
|
onPress: onPress ? handlePress : void 0,
|
|
2259
2322
|
onPressIn: handlePressIn,
|
|
2260
2323
|
onPressOut: handlePressOut,
|
|
@@ -2262,11 +2325,11 @@ function ListItem({
|
|
|
2262
2325
|
activeOpacity: 1,
|
|
2263
2326
|
touchSoundDisabled: true
|
|
2264
2327
|
},
|
|
2265
|
-
effectiveLeft ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style:
|
|
2266
|
-
/* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style:
|
|
2328
|
+
effectiveLeft ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles25.leftContainer }, effectiveLeft) : null,
|
|
2329
|
+
/* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles25.content }, /* @__PURE__ */ React25__default.default.createElement(
|
|
2267
2330
|
reactNative.Text,
|
|
2268
2331
|
{
|
|
2269
|
-
style: [
|
|
2332
|
+
style: [styles25.title, { color: colors.foreground }, titleStyle],
|
|
2270
2333
|
numberOfLines: 2,
|
|
2271
2334
|
allowFontScaling: true
|
|
2272
2335
|
},
|
|
@@ -2274,7 +2337,7 @@ function ListItem({
|
|
|
2274
2337
|
), subtitle ? /* @__PURE__ */ React25__default.default.createElement(
|
|
2275
2338
|
reactNative.Text,
|
|
2276
2339
|
{
|
|
2277
|
-
style: [
|
|
2340
|
+
style: [styles25.subtitle, { color: colors.mutedForeground }, subtitleStyle],
|
|
2278
2341
|
numberOfLines: 2,
|
|
2279
2342
|
allowFontScaling: true
|
|
2280
2343
|
},
|
|
@@ -2282,16 +2345,16 @@ function ListItem({
|
|
|
2282
2345
|
) : null, caption ? /* @__PURE__ */ React25__default.default.createElement(
|
|
2283
2346
|
reactNative.Text,
|
|
2284
2347
|
{
|
|
2285
|
-
style: [
|
|
2348
|
+
style: [styles25.caption, { color: colors.mutedForeground }, captionStyle],
|
|
2286
2349
|
numberOfLines: 1,
|
|
2287
2350
|
allowFontScaling: true
|
|
2288
2351
|
},
|
|
2289
2352
|
caption
|
|
2290
2353
|
) : null),
|
|
2291
|
-
effectiveRight !== void 0 ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style:
|
|
2354
|
+
effectiveRight !== void 0 ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles25.rightContainer }, typeof effectiveRight === "string" ? /* @__PURE__ */ React25__default.default.createElement(
|
|
2292
2355
|
reactNative.Text,
|
|
2293
2356
|
{
|
|
2294
|
-
style: [
|
|
2357
|
+
style: [styles25.rightText, { color: colors.mutedForeground }],
|
|
2295
2358
|
allowFontScaling: true
|
|
2296
2359
|
},
|
|
2297
2360
|
effectiveRight
|
|
@@ -2300,18 +2363,18 @@ function ListItem({
|
|
|
2300
2363
|
reactNative.View,
|
|
2301
2364
|
{
|
|
2302
2365
|
style: [
|
|
2303
|
-
|
|
2366
|
+
styles25.separator,
|
|
2304
2367
|
{ backgroundColor: colors.border, marginLeft: effectiveLeft ? s(16) + s(44) + s(12) : s(16) }
|
|
2305
2368
|
]
|
|
2306
2369
|
}
|
|
2307
2370
|
) : null);
|
|
2308
2371
|
}
|
|
2309
|
-
var
|
|
2372
|
+
var styles25 = reactNative.StyleSheet.create({
|
|
2310
2373
|
container: {
|
|
2311
2374
|
flexDirection: "row",
|
|
2312
2375
|
alignItems: "center",
|
|
2313
2376
|
paddingHorizontal: s(16),
|
|
2314
|
-
paddingVertical: vs(
|
|
2377
|
+
paddingVertical: vs(10),
|
|
2315
2378
|
gap: s(12)
|
|
2316
2379
|
},
|
|
2317
2380
|
leftContainer: {
|
|
@@ -2326,18 +2389,18 @@ var styles24 = reactNative.StyleSheet.create({
|
|
|
2326
2389
|
gap: vs(4)
|
|
2327
2390
|
},
|
|
2328
2391
|
title: {
|
|
2329
|
-
|
|
2330
|
-
|
|
2331
|
-
lineHeight: mvs(
|
|
2392
|
+
fontFamily: "Poppins-Medium",
|
|
2393
|
+
fontSize: ms(15),
|
|
2394
|
+
lineHeight: mvs(22)
|
|
2332
2395
|
},
|
|
2333
2396
|
subtitle: {
|
|
2334
|
-
|
|
2335
|
-
|
|
2336
|
-
lineHeight: mvs(
|
|
2397
|
+
fontFamily: "Poppins-Regular",
|
|
2398
|
+
fontSize: ms(13),
|
|
2399
|
+
lineHeight: mvs(18)
|
|
2337
2400
|
},
|
|
2338
2401
|
caption: {
|
|
2402
|
+
fontFamily: "Poppins-Regular",
|
|
2339
2403
|
fontSize: ms(12),
|
|
2340
|
-
fontWeight: "400",
|
|
2341
2404
|
lineHeight: mvs(16),
|
|
2342
2405
|
opacity: 0.7
|
|
2343
2406
|
},
|
|
@@ -2348,7 +2411,8 @@ var styles24 = reactNative.StyleSheet.create({
|
|
|
2348
2411
|
maxWidth: s(160)
|
|
2349
2412
|
},
|
|
2350
2413
|
rightText: {
|
|
2351
|
-
|
|
2414
|
+
fontFamily: "Poppins-Regular",
|
|
2415
|
+
fontSize: ms(14)
|
|
2352
2416
|
},
|
|
2353
2417
|
chevron: {
|
|
2354
2418
|
marginLeft: s(4)
|
|
@@ -2361,8 +2425,8 @@ var styles24 = reactNative.StyleSheet.create({
|
|
|
2361
2425
|
opacity: 0.45
|
|
2362
2426
|
}
|
|
2363
2427
|
});
|
|
2364
|
-
var
|
|
2365
|
-
function Chip({ label, selected = false, onPress, style }) {
|
|
2428
|
+
var nativeDriver11 = reactNative.Platform.OS !== "web";
|
|
2429
|
+
function Chip({ label, selected = false, onPress, icon, iconName, style }) {
|
|
2366
2430
|
const { colors } = useTheme();
|
|
2367
2431
|
const scale2 = React25.useRef(new reactNative.Animated.Value(1)).current;
|
|
2368
2432
|
const pressAnim = React25.useRef(new reactNative.Animated.Value(selected ? 1 : 0)).current;
|
|
@@ -2377,7 +2441,7 @@ function Chip({ label, selected = false, onPress, style }) {
|
|
|
2377
2441
|
const handlePressIn = () => {
|
|
2378
2442
|
reactNative.Animated.spring(scale2, {
|
|
2379
2443
|
toValue: 0.95,
|
|
2380
|
-
useNativeDriver:
|
|
2444
|
+
useNativeDriver: nativeDriver11,
|
|
2381
2445
|
speed: 40,
|
|
2382
2446
|
bounciness: 0
|
|
2383
2447
|
}).start();
|
|
@@ -2385,7 +2449,7 @@ function Chip({ label, selected = false, onPress, style }) {
|
|
|
2385
2449
|
const handlePressOut = () => {
|
|
2386
2450
|
reactNative.Animated.spring(scale2, {
|
|
2387
2451
|
toValue: 1,
|
|
2388
|
-
useNativeDriver:
|
|
2452
|
+
useNativeDriver: nativeDriver11,
|
|
2389
2453
|
speed: 40,
|
|
2390
2454
|
bounciness: 4
|
|
2391
2455
|
}).start();
|
|
@@ -2406,7 +2470,8 @@ function Chip({ label, selected = false, onPress, style }) {
|
|
|
2406
2470
|
inputRange: [0, 1],
|
|
2407
2471
|
outputRange: [colors.border, colors.primary]
|
|
2408
2472
|
});
|
|
2409
|
-
|
|
2473
|
+
const resolvedIcon = iconName ? renderIcon(iconName, ms(13), selected ? colors.primaryForeground : colors.foreground) : icon;
|
|
2474
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: [styles26.wrapper, { transform: [{ scale: scale2 }] }, style] }, /* @__PURE__ */ React25__default.default.createElement(
|
|
2410
2475
|
reactNative.TouchableOpacity,
|
|
2411
2476
|
{
|
|
2412
2477
|
onPress: handlePress,
|
|
@@ -2415,7 +2480,7 @@ function Chip({ label, selected = false, onPress, style }) {
|
|
|
2415
2480
|
activeOpacity: 1,
|
|
2416
2481
|
touchSoundDisabled: true
|
|
2417
2482
|
},
|
|
2418
|
-
/* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: [
|
|
2483
|
+
/* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.View, { style: [styles26.chip, { backgroundColor, borderColor }] }, resolvedIcon ? /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles26.chipIcon }, resolvedIcon) : null, /* @__PURE__ */ React25__default.default.createElement(reactNative.Animated.Text, { style: [styles26.label, { color: textColor }], allowFontScaling: true }, label))
|
|
2419
2484
|
));
|
|
2420
2485
|
}
|
|
2421
2486
|
function ChipGroup({ options, value, onValueChange, multiSelect = false, style }) {
|
|
@@ -2440,7 +2505,7 @@ function ChipGroup({ options, value, onValueChange, multiSelect = false, style }
|
|
|
2440
2505
|
}
|
|
2441
2506
|
return optionValue === value;
|
|
2442
2507
|
};
|
|
2443
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
2508
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles26.group, style] }, options.map((opt) => /* @__PURE__ */ React25__default.default.createElement(
|
|
2444
2509
|
Chip,
|
|
2445
2510
|
{
|
|
2446
2511
|
key: opt.value,
|
|
@@ -2450,20 +2515,26 @@ function ChipGroup({ options, value, onValueChange, multiSelect = false, style }
|
|
|
2450
2515
|
}
|
|
2451
2516
|
)));
|
|
2452
2517
|
}
|
|
2453
|
-
var
|
|
2518
|
+
var styles26 = reactNative.StyleSheet.create({
|
|
2454
2519
|
wrapper: {},
|
|
2455
2520
|
chip: {
|
|
2456
2521
|
borderRadius: 999,
|
|
2457
2522
|
paddingHorizontal: s(14),
|
|
2458
|
-
paddingVertical: vs(
|
|
2459
|
-
borderWidth: 1
|
|
2523
|
+
paddingVertical: vs(5),
|
|
2524
|
+
borderWidth: 1,
|
|
2525
|
+
alignItems: "center",
|
|
2526
|
+
justifyContent: "center",
|
|
2527
|
+
flexDirection: "row",
|
|
2528
|
+
gap: s(5)
|
|
2529
|
+
},
|
|
2530
|
+
chipIcon: {
|
|
2460
2531
|
alignItems: "center",
|
|
2461
2532
|
justifyContent: "center"
|
|
2462
2533
|
},
|
|
2463
2534
|
label: {
|
|
2464
|
-
|
|
2465
|
-
|
|
2466
|
-
lineHeight: mvs(
|
|
2535
|
+
fontFamily: "Poppins-Medium",
|
|
2536
|
+
fontSize: ms(13),
|
|
2537
|
+
lineHeight: mvs(18)
|
|
2467
2538
|
},
|
|
2468
2539
|
group: {
|
|
2469
2540
|
flexDirection: "row",
|
|
@@ -2482,43 +2553,85 @@ function ConfirmDialog({
|
|
|
2482
2553
|
onCancel
|
|
2483
2554
|
}) {
|
|
2484
2555
|
const { colors } = useTheme();
|
|
2485
|
-
|
|
2486
|
-
|
|
2556
|
+
const ref = React25.useRef(null);
|
|
2557
|
+
React25.useEffect(() => {
|
|
2558
|
+
if (visible) {
|
|
2559
|
+
impactLight();
|
|
2560
|
+
ref.current?.present();
|
|
2561
|
+
} else {
|
|
2562
|
+
ref.current?.dismiss();
|
|
2563
|
+
}
|
|
2564
|
+
}, [visible]);
|
|
2565
|
+
const renderBackdrop = (props) => /* @__PURE__ */ React25__default.default.createElement(
|
|
2566
|
+
bottomSheet.BottomSheetBackdrop,
|
|
2487
2567
|
{
|
|
2488
|
-
|
|
2489
|
-
|
|
2568
|
+
...props,
|
|
2569
|
+
disappearsOnIndex: -1,
|
|
2570
|
+
appearsOnIndex: 0,
|
|
2571
|
+
pressBehavior: "close"
|
|
2572
|
+
}
|
|
2573
|
+
);
|
|
2574
|
+
return /* @__PURE__ */ React25__default.default.createElement(
|
|
2575
|
+
bottomSheet.BottomSheetModal,
|
|
2576
|
+
{
|
|
2577
|
+
ref,
|
|
2578
|
+
snapPoints: ["35%"],
|
|
2579
|
+
onDismiss: onCancel,
|
|
2580
|
+
backdropComponent: renderBackdrop,
|
|
2581
|
+
backgroundStyle: [styles27.background, { backgroundColor: colors.card }],
|
|
2582
|
+
handleIndicatorStyle: [styles27.handle, { backgroundColor: colors.border }],
|
|
2583
|
+
enablePanDownToClose: true
|
|
2490
2584
|
},
|
|
2491
|
-
/* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [
|
|
2492
|
-
|
|
2493
|
-
|
|
2494
|
-
|
|
2585
|
+
/* @__PURE__ */ React25__default.default.createElement(bottomSheet.BottomSheetView, { style: styles27.content }, /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles27.title, { color: colors.cardForeground }], allowFontScaling: true }, title), description ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles27.description, { color: colors.mutedForeground }], allowFontScaling: true }, description) : null, /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: styles27.actions }, /* @__PURE__ */ React25__default.default.createElement(
|
|
2586
|
+
Button,
|
|
2587
|
+
{
|
|
2588
|
+
label: cancelLabel,
|
|
2589
|
+
variant: "outline",
|
|
2590
|
+
fullWidth: true,
|
|
2591
|
+
onPress: onCancel,
|
|
2592
|
+
icon: /* @__PURE__ */ React25__default.default.createElement(vectorIcons.Feather, { name: "x", size: 15, color: colors.foreground })
|
|
2593
|
+
}
|
|
2594
|
+
), /* @__PURE__ */ React25__default.default.createElement(
|
|
2595
|
+
Button,
|
|
2596
|
+
{
|
|
2597
|
+
label: confirmLabel,
|
|
2598
|
+
variant: confirmVariant,
|
|
2599
|
+
fullWidth: true,
|
|
2600
|
+
onPress: onConfirm,
|
|
2601
|
+
icon: /* @__PURE__ */ React25__default.default.createElement(
|
|
2602
|
+
vectorIcons.Feather,
|
|
2603
|
+
{
|
|
2604
|
+
name: confirmVariant === "destructive" ? "trash-2" : "check",
|
|
2605
|
+
size: 15,
|
|
2606
|
+
color: confirmVariant === "destructive" ? colors.destructiveForeground : colors.primaryForeground
|
|
2607
|
+
}
|
|
2608
|
+
)
|
|
2609
|
+
}
|
|
2610
|
+
)))
|
|
2611
|
+
);
|
|
2495
2612
|
}
|
|
2496
|
-
var
|
|
2497
|
-
|
|
2498
|
-
|
|
2499
|
-
|
|
2500
|
-
justifyContent: "center",
|
|
2501
|
-
alignItems: "center",
|
|
2502
|
-
padding: s(24)
|
|
2613
|
+
var styles27 = reactNative.StyleSheet.create({
|
|
2614
|
+
background: {
|
|
2615
|
+
borderTopLeftRadius: ms(16),
|
|
2616
|
+
borderTopRightRadius: ms(16)
|
|
2503
2617
|
},
|
|
2504
|
-
|
|
2505
|
-
width:
|
|
2506
|
-
|
|
2507
|
-
borderRadius: ms(
|
|
2508
|
-
|
|
2509
|
-
|
|
2510
|
-
|
|
2511
|
-
|
|
2512
|
-
|
|
2513
|
-
shadowRadius: 16,
|
|
2514
|
-
elevation: 8
|
|
2618
|
+
handle: {
|
|
2619
|
+
width: s(36),
|
|
2620
|
+
height: vs(4),
|
|
2621
|
+
borderRadius: ms(2)
|
|
2622
|
+
},
|
|
2623
|
+
content: {
|
|
2624
|
+
paddingHorizontal: s(24),
|
|
2625
|
+
paddingBottom: vs(32),
|
|
2626
|
+
gap: vs(12)
|
|
2515
2627
|
},
|
|
2516
2628
|
title: {
|
|
2629
|
+
fontFamily: "Poppins-SemiBold",
|
|
2517
2630
|
fontSize: ms(18),
|
|
2518
|
-
fontWeight: "600",
|
|
2519
2631
|
lineHeight: mvs(26)
|
|
2520
2632
|
},
|
|
2521
2633
|
description: {
|
|
2634
|
+
fontFamily: "Poppins-Regular",
|
|
2522
2635
|
fontSize: ms(15),
|
|
2523
2636
|
lineHeight: mvs(22)
|
|
2524
2637
|
},
|
|
@@ -2529,9 +2642,9 @@ var styles26 = reactNative.StyleSheet.create({
|
|
|
2529
2642
|
});
|
|
2530
2643
|
function LabelValue({ label, value, style }) {
|
|
2531
2644
|
const { colors } = useTheme();
|
|
2532
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
2645
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles28.container, style] }, /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles28.label, { color: colors.mutedForeground }], allowFontScaling: true }, label), typeof value === "string" ? /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles28.value, { color: colors.foreground }], allowFontScaling: true }, value) : value);
|
|
2533
2646
|
}
|
|
2534
|
-
var
|
|
2647
|
+
var styles28 = reactNative.StyleSheet.create({
|
|
2535
2648
|
container: {
|
|
2536
2649
|
flexDirection: "row",
|
|
2537
2650
|
justifyContent: "space-between",
|
|
@@ -2539,13 +2652,14 @@ var styles27 = reactNative.StyleSheet.create({
|
|
|
2539
2652
|
gap: s(12)
|
|
2540
2653
|
},
|
|
2541
2654
|
label: {
|
|
2655
|
+
fontFamily: "Poppins-Regular",
|
|
2542
2656
|
fontSize: ms(13),
|
|
2543
2657
|
lineHeight: mvs(18)
|
|
2544
2658
|
},
|
|
2545
2659
|
value: {
|
|
2546
|
-
|
|
2547
|
-
|
|
2548
|
-
lineHeight: mvs(
|
|
2660
|
+
fontFamily: "Poppins-Medium",
|
|
2661
|
+
fontSize: ms(14),
|
|
2662
|
+
lineHeight: mvs(20),
|
|
2549
2663
|
textAlign: "right"
|
|
2550
2664
|
}
|
|
2551
2665
|
});
|
|
@@ -2581,19 +2695,19 @@ function MonthPicker({ value, onChange, style }) {
|
|
|
2581
2695
|
onChange({ month: value.month + 1, year: value.year });
|
|
2582
2696
|
}
|
|
2583
2697
|
};
|
|
2584
|
-
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [
|
|
2698
|
+
return /* @__PURE__ */ React25__default.default.createElement(reactNative.View, { style: [styles29.container, style] }, /* @__PURE__ */ React25__default.default.createElement(
|
|
2585
2699
|
reactNative.TouchableOpacity,
|
|
2586
2700
|
{
|
|
2587
|
-
style:
|
|
2701
|
+
style: styles29.arrow,
|
|
2588
2702
|
onPress: handlePrev,
|
|
2589
2703
|
activeOpacity: 0.6,
|
|
2590
2704
|
touchSoundDisabled: true
|
|
2591
2705
|
},
|
|
2592
2706
|
/* @__PURE__ */ React25__default.default.createElement(vectorIcons.Entypo, { name: "chevron-left", size: 22, color: colors.foreground })
|
|
2593
|
-
), /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [
|
|
2707
|
+
), /* @__PURE__ */ React25__default.default.createElement(reactNative.Text, { style: [styles29.label, { color: colors.foreground }], allowFontScaling: true }, MONTH_NAMES[value.month - 1], " ", value.year), /* @__PURE__ */ React25__default.default.createElement(
|
|
2594
2708
|
reactNative.TouchableOpacity,
|
|
2595
2709
|
{
|
|
2596
|
-
style:
|
|
2710
|
+
style: styles29.arrow,
|
|
2597
2711
|
onPress: handleNext,
|
|
2598
2712
|
activeOpacity: 0.6,
|
|
2599
2713
|
touchSoundDisabled: true
|
|
@@ -2601,7 +2715,7 @@ function MonthPicker({ value, onChange, style }) {
|
|
|
2601
2715
|
/* @__PURE__ */ React25__default.default.createElement(vectorIcons.Entypo, { name: "chevron-right", size: 22, color: colors.foreground })
|
|
2602
2716
|
));
|
|
2603
2717
|
}
|
|
2604
|
-
var
|
|
2718
|
+
var styles29 = reactNative.StyleSheet.create({
|
|
2605
2719
|
container: {
|
|
2606
2720
|
flexDirection: "row",
|
|
2607
2721
|
alignItems: "center",
|
|
@@ -2614,8 +2728,8 @@ var styles28 = reactNative.StyleSheet.create({
|
|
|
2614
2728
|
justifyContent: "center"
|
|
2615
2729
|
},
|
|
2616
2730
|
label: {
|
|
2731
|
+
fontFamily: "Poppins-Medium",
|
|
2617
2732
|
fontSize: ms(17),
|
|
2618
|
-
fontWeight: "500",
|
|
2619
2733
|
lineHeight: mvs(24),
|
|
2620
2734
|
textAlign: "center",
|
|
2621
2735
|
minWidth: s(160)
|