@retray-dev/ui-kit 12.1.0 → 12.2.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 +98 -4
- package/README.md +4 -4
- package/dist/Accordion.d.mts +6 -0
- package/dist/Accordion.d.ts +6 -0
- package/dist/Accordion.js +16 -0
- package/dist/Accordion.mjs +2 -2
- package/dist/AlertBanner.js +2 -0
- package/dist/AlertBanner.mjs +2 -2
- package/dist/AppHeader.js +2 -0
- package/dist/AppHeader.mjs +3 -3
- package/dist/Avatar.js +2 -0
- package/dist/Avatar.mjs +2 -2
- package/dist/Badge.js +2 -0
- package/dist/Badge.mjs +2 -2
- package/dist/Button.js +17 -17
- package/dist/Button.mjs +2 -2
- package/dist/Card.js +2 -0
- package/dist/Card.mjs +2 -2
- package/dist/CategoryStrip.js +2 -0
- package/dist/CategoryStrip.mjs +2 -2
- package/dist/Checkbox.js +2 -0
- package/dist/Checkbox.mjs +2 -2
- package/dist/Chip.js +2 -0
- package/dist/Chip.mjs +2 -2
- package/dist/ConfirmDialog.js +26 -20
- package/dist/ConfirmDialog.mjs +3 -3
- package/dist/CurrencyDisplay.js +2 -0
- package/dist/CurrencyDisplay.mjs +2 -2
- package/dist/CurrencyInput.js +2 -0
- package/dist/CurrencyInput.mjs +3 -3
- package/dist/DetailRow.js +2 -0
- package/dist/DetailRow.mjs +2 -2
- package/dist/EmptyState.js +17 -17
- package/dist/EmptyState.mjs +3 -3
- package/dist/ErrorBoundary.js +2 -0
- package/dist/ErrorBoundary.mjs +2 -2
- package/dist/Form.js +2 -0
- package/dist/Form.mjs +2 -2
- package/dist/IconButton.js +2 -0
- package/dist/IconButton.mjs +2 -2
- package/dist/IconPicker.js +2 -0
- package/dist/IconPicker.mjs +3 -3
- package/dist/ImageUpload.d.mts +3 -1
- package/dist/ImageUpload.d.ts +3 -1
- package/dist/ImageUpload.js +10 -3
- package/dist/ImageUpload.mjs +3 -3
- package/dist/ImageViewer.js +2 -0
- package/dist/ImageViewer.mjs +4 -4
- package/dist/Input.js +2 -0
- package/dist/Input.mjs +2 -2
- package/dist/LabelValue.js +2 -0
- package/dist/LabelValue.mjs +2 -2
- package/dist/ListGroup.js +2 -0
- package/dist/ListGroup.mjs +2 -2
- package/dist/ListItem.js +2 -0
- package/dist/ListItem.mjs +2 -2
- package/dist/MediaCard.js +2 -0
- package/dist/MediaCard.mjs +2 -2
- package/dist/MenuGroup.js +2 -0
- package/dist/MenuGroup.mjs +2 -2
- package/dist/MenuItem.js +2 -0
- package/dist/MenuItem.mjs +2 -2
- package/dist/MonthPicker.js +2 -0
- package/dist/MonthPicker.mjs +2 -2
- package/dist/NumberStepper.js +2 -0
- package/dist/NumberStepper.mjs +2 -2
- package/dist/PagerDots.js +2 -0
- package/dist/PagerDots.mjs +2 -2
- package/dist/PricingCard.js +17 -17
- package/dist/PricingCard.mjs +4 -4
- package/dist/Progress.js +2 -0
- package/dist/Progress.mjs +2 -2
- package/dist/RadioGroup.js +2 -0
- package/dist/RadioGroup.mjs +2 -2
- package/dist/RetrayProvider.d.mts +1 -1
- package/dist/RetrayProvider.d.ts +1 -1
- package/dist/RetrayProvider.js +2 -0
- package/dist/RetrayProvider.mjs +3 -3
- package/dist/Select.js +2 -0
- package/dist/Select.mjs +2 -2
- package/dist/SelectableCard.d.mts +27 -0
- package/dist/SelectableCard.d.ts +27 -0
- package/dist/SelectableCard.js +511 -0
- package/dist/SelectableCard.mjs +8 -0
- package/dist/SelectableGrid.js +2 -0
- package/dist/SelectableGrid.mjs +2 -2
- package/dist/Separator.js +2 -0
- package/dist/Separator.mjs +2 -2
- package/dist/Sheet.js +11 -3
- package/dist/Sheet.mjs +2 -2
- package/dist/SheetSelect.js +2 -0
- package/dist/SheetSelect.mjs +2 -2
- package/dist/Skeleton.d.mts +3 -1
- package/dist/Skeleton.d.ts +3 -1
- package/dist/Skeleton.js +5 -2
- package/dist/Skeleton.mjs +2 -2
- package/dist/Slider.js +2 -0
- package/dist/Slider.mjs +2 -2
- package/dist/Spinner.js +2 -0
- package/dist/Spinner.mjs +2 -2
- package/dist/Stats.d.mts +4 -1
- package/dist/Stats.d.ts +4 -1
- package/dist/Stats.js +27 -3
- package/dist/Stats.mjs +2 -2
- package/dist/Switch.js +2 -0
- package/dist/Switch.mjs +2 -2
- package/dist/TabBar.js +2 -0
- package/dist/TabBar.mjs +2 -2
- package/dist/Tabs.js +2 -0
- package/dist/Tabs.mjs +2 -2
- package/dist/Text.js +2 -0
- package/dist/Text.mjs +2 -2
- package/dist/Textarea.js +2 -0
- package/dist/Textarea.mjs +2 -2
- package/dist/Toast.js +2 -0
- package/dist/Toast.mjs +2 -2
- package/dist/Toggle.js +2 -0
- package/dist/Toggle.mjs +2 -2
- package/dist/{chunk-JNVAIDLK.mjs → chunk-2BA3JMKK.mjs} +1 -1
- package/dist/{chunk-X26S5EVZ.mjs → chunk-2HFD4IHU.mjs} +1 -1
- package/dist/{chunk-ZHMSAYLT.mjs → chunk-2LG326TT.mjs} +1 -1
- package/dist/chunk-2P2CB235.mjs +236 -0
- package/dist/{chunk-MYZ2EDYU.mjs → chunk-3XCFYSX4.mjs} +1 -1
- package/dist/{chunk-DOGIPOF5.mjs → chunk-4J2PXL36.mjs} +16 -18
- package/dist/{chunk-V6NFJXKO.mjs → chunk-4OORJ2DY.mjs} +1 -1
- package/dist/{chunk-5OLNXP3S.mjs → chunk-4XOB5TTD.mjs} +26 -4
- package/dist/{chunk-P64WHW4A.mjs → chunk-57V2LXCK.mjs} +1 -1
- package/dist/{chunk-HJ46DTJE.mjs → chunk-7AFZWSCI.mjs} +1 -1
- package/dist/{chunk-AQEVCEXV.mjs → chunk-7ELGZ66G.mjs} +1 -1
- package/dist/{chunk-I4V5XZPS.mjs → chunk-AENAVIKT.mjs} +1 -1
- package/dist/{chunk-2CBQKU7H.mjs → chunk-BXF4AMHY.mjs} +1 -1
- package/dist/{chunk-JULSIZDM.mjs → chunk-C43HRKXH.mjs} +1 -1
- package/dist/{chunk-GK4VRMNE.mjs → chunk-CF27NBXO.mjs} +11 -6
- package/dist/{chunk-PGERH3P7.mjs → chunk-DF7JA72E.mjs} +1 -1
- package/dist/{chunk-F4V6XLP4.mjs → chunk-E5UKLSJZ.mjs} +3 -3
- package/dist/{chunk-FUVYSVGR.mjs → chunk-EDLCGYIO.mjs} +1 -1
- package/dist/{chunk-N4ZPVCJH.mjs → chunk-ELGEOM7I.mjs} +1 -1
- package/dist/{chunk-FA2KMTH5.mjs → chunk-F3YTWO3T.mjs} +1 -1
- package/dist/{chunk-3UYAZ7I4.mjs → chunk-GH67YXG6.mjs} +1 -1
- package/dist/{chunk-357YO24D.mjs → chunk-GUTDFUNF.mjs} +1 -1
- package/dist/{chunk-7HSILTC4.mjs → chunk-HC4VVCWY.mjs} +2 -2
- package/dist/{chunk-WOEWGSTU.mjs → chunk-HEDQPK4I.mjs} +1 -1
- package/dist/{chunk-3GEYJ7I5.mjs → chunk-IVSRW4HS.mjs} +1 -1
- package/dist/{chunk-P73V2EKS.mjs → chunk-KSUWPU2F.mjs} +1 -1
- package/dist/{chunk-BCWEHE34.mjs → chunk-LIS6I5UP.mjs} +1 -1
- package/dist/{chunk-J6Q2YJEV.mjs → chunk-LNPKGWBG.mjs} +1 -1
- package/dist/{chunk-DF6DU42P.mjs → chunk-LOBLCFMN.mjs} +1 -1
- package/dist/{chunk-2A2LEFZG.mjs → chunk-LPV4NJJK.mjs} +2 -2
- package/dist/{chunk-FFTYLPSB.mjs → chunk-M3C7XM2M.mjs} +11 -5
- package/dist/{chunk-BQZE3HAW.mjs → chunk-MEPSKGBO.mjs} +1 -1
- package/dist/{chunk-ISY26JQJ.mjs → chunk-MVMGPZN6.mjs} +2 -2
- package/dist/{chunk-265G6A46.mjs → chunk-NHDI3VQB.mjs} +15 -1
- package/dist/{chunk-D3Y2T42P.mjs → chunk-NJG7DHVF.mjs} +1 -1
- package/dist/{chunk-LRM4AVYY.mjs → chunk-NLZY4TXU.mjs} +1 -1
- package/dist/{chunk-OULVKTWL.mjs → chunk-OLVJFKXS.mjs} +1 -1
- package/dist/{chunk-BOVUP27T.mjs → chunk-QDAZGZUF.mjs} +4 -3
- package/dist/{chunk-S3KJCPEJ.mjs → chunk-QOLWA2PW.mjs} +1 -1
- package/dist/{chunk-JCZQOY4O.mjs → chunk-QXDGGOLC.mjs} +12 -6
- package/dist/{chunk-4WFMPFZB.mjs → chunk-RJNLAH76.mjs} +1 -1
- package/dist/{chunk-HLMPMUK2.mjs → chunk-RMRS44MQ.mjs} +1 -1
- package/dist/{chunk-KHYX4IOM.mjs → chunk-SAWUXP3A.mjs} +2 -2
- package/dist/{chunk-2I2AYECM.mjs → chunk-TS7DGUIR.mjs} +1 -1
- package/dist/{chunk-3N2M3WZL.mjs → chunk-UBUXUMER.mjs} +1 -1
- package/dist/{chunk-AKM4EPOT.mjs → chunk-ULGNQPNE.mjs} +1 -1
- package/dist/{chunk-FVTVCJAH.mjs → chunk-UNNRUJTM.mjs} +1 -1
- package/dist/{chunk-DI7CBDL6.mjs → chunk-UQ4742ET.mjs} +1 -1
- package/dist/{chunk-EFLFRAHD.mjs → chunk-VJBUCITV.mjs} +1 -1
- package/dist/{chunk-QSFV2P7O.mjs → chunk-YMYIEVZP.mjs} +1 -1
- package/dist/{chunk-EMUWGDWC.mjs → chunk-YTXRIXNZ.mjs} +2 -0
- package/dist/{chunk-XBAGGKLW.mjs → chunk-ZIMY2QUM.mjs} +2 -2
- package/dist/{chunk-NXI4YDZ2.mjs → chunk-ZR6HSEAB.mjs} +1 -1
- package/dist/{index-wt-orHUi.d.ts → index-CY34hxPN.d.mts} +1 -0
- package/dist/{index-wt-orHUi.d.mts → index-CY34hxPN.d.ts} +1 -0
- package/dist/index.d.mts +3 -2
- package/dist/index.d.ts +3 -2
- package/dist/index.js +733 -453
- package/dist/index.mjs +53 -52
- package/package.json +1 -1
- package/src/components/Accordion/Accordion.tsx +20 -0
- package/src/components/Button/Button.tsx +29 -26
- package/src/components/ConfirmDialog/ConfirmDialog.tsx +10 -3
- package/src/components/ImageUpload/ImageUpload.tsx +10 -3
- package/src/components/SelectableCard/SelectableCard.tsx +304 -0
- package/src/components/SelectableCard/index.ts +1 -0
- package/src/components/Sheet/Sheet.tsx +10 -3
- package/src/components/Skeleton/Skeleton.tsx +5 -2
- package/src/components/Stats/Stats.tsx +35 -7
- package/src/index.ts +1 -0
- package/src/theme/colors.ts +7 -0
- package/src/theme/types.ts +4 -1
package/dist/Skeleton.js
CHANGED
|
@@ -92,6 +92,7 @@ function deriveColors(t, scheme) {
|
|
|
92
92
|
const foregroundMuted = mixWithBackground(t.foreground, bg, 0.62);
|
|
93
93
|
const surface = dark ? lighten(bg, -0.06) : darken(bg, 0.04);
|
|
94
94
|
const surfaceStrong = dark ? lighten(bg, -0.12) : darken(bg, 0.08);
|
|
95
|
+
const skeleton = dark ? lighten(bg, -0.1) : darken(bg, 0.1);
|
|
95
96
|
const destructiveTint = dark ? withAlphaOnDark(t.destructive, 0.15, bg) : withAlphaOnWhite(t.destructive, 0.08);
|
|
96
97
|
const destructiveBorder = dark ? withAlphaOnDark(t.destructive, 0.45, bg) : withAlphaOnWhite(t.destructive, 0.3);
|
|
97
98
|
const successTint = dark ? withAlphaOnDark(t.success, 0.15, bg) : withAlphaOnWhite(t.success, 0.08);
|
|
@@ -104,6 +105,7 @@ function deriveColors(t, scheme) {
|
|
|
104
105
|
foregroundMuted,
|
|
105
106
|
surface,
|
|
106
107
|
surfaceStrong,
|
|
108
|
+
skeleton,
|
|
107
109
|
destructiveTint,
|
|
108
110
|
destructiveBorder,
|
|
109
111
|
successTint,
|
|
@@ -159,12 +161,13 @@ function Skeleton({
|
|
|
159
161
|
borderRadius = 6,
|
|
160
162
|
preset = "base",
|
|
161
163
|
diameter = 40,
|
|
164
|
+
backgroundColor,
|
|
162
165
|
style
|
|
163
166
|
}) {
|
|
164
167
|
const { colors, colorScheme } = useTheme();
|
|
165
168
|
const shimmer = Animated.useSharedValue(0);
|
|
166
169
|
const [containerWidth, setContainerWidth] = React2.useState(300);
|
|
167
|
-
const shimmerHighlight = colorScheme === "dark" ? "rgba(255,255,255,0.08)" : "rgba(
|
|
170
|
+
const shimmerHighlight = colorScheme === "dark" ? "rgba(255,255,255,0.08)" : "rgba(0,0,0,0.07)";
|
|
168
171
|
React2.useEffect(() => {
|
|
169
172
|
shimmer.value = Animated.withRepeat(
|
|
170
173
|
Animated.withTiming(1, { duration: TIMINGS.shimmer.duration, easing: Animated.Easing.linear }),
|
|
@@ -183,7 +186,7 @@ function Skeleton({
|
|
|
183
186
|
{
|
|
184
187
|
style: [
|
|
185
188
|
styles.base,
|
|
186
|
-
{ width: resolvedWidth, height: resolvedHeight, borderRadius: resolvedRadius, backgroundColor: colors.
|
|
189
|
+
{ width: resolvedWidth, height: resolvedHeight, borderRadius: resolvedRadius, backgroundColor: backgroundColor ?? colors.skeleton },
|
|
187
190
|
style
|
|
188
191
|
],
|
|
189
192
|
onLayout: (e) => setContainerWidth(e.nativeEvent.layout.width),
|
package/dist/Skeleton.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { Skeleton } from './chunk-
|
|
1
|
+
export { Skeleton } from './chunk-QDAZGZUF.mjs';
|
|
2
2
|
import './chunk-DVK4G2GT.mjs';
|
|
3
3
|
import './chunk-QY3X2UYR.mjs';
|
|
4
|
-
import './chunk-
|
|
4
|
+
import './chunk-YTXRIXNZ.mjs';
|
|
5
5
|
import './chunk-2CE3TQVY.mjs';
|
|
6
6
|
import './chunk-Y6FXYEAI.mjs';
|
package/dist/Slider.js
CHANGED
|
@@ -150,6 +150,7 @@ function deriveColors(t, scheme) {
|
|
|
150
150
|
const foregroundMuted = mixWithBackground(t.foreground, bg, 0.62);
|
|
151
151
|
const surface = dark ? lighten(bg, -0.06) : darken(bg, 0.04);
|
|
152
152
|
const surfaceStrong = dark ? lighten(bg, -0.12) : darken(bg, 0.08);
|
|
153
|
+
const skeleton = dark ? lighten(bg, -0.1) : darken(bg, 0.1);
|
|
153
154
|
const destructiveTint = dark ? withAlphaOnDark(t.destructive, 0.15, bg) : withAlphaOnWhite(t.destructive, 0.08);
|
|
154
155
|
const destructiveBorder = dark ? withAlphaOnDark(t.destructive, 0.45, bg) : withAlphaOnWhite(t.destructive, 0.3);
|
|
155
156
|
const successTint = dark ? withAlphaOnDark(t.success, 0.15, bg) : withAlphaOnWhite(t.success, 0.08);
|
|
@@ -162,6 +163,7 @@ function deriveColors(t, scheme) {
|
|
|
162
163
|
foregroundMuted,
|
|
163
164
|
surface,
|
|
164
165
|
surfaceStrong,
|
|
166
|
+
skeleton,
|
|
165
167
|
destructiveTint,
|
|
166
168
|
destructiveBorder,
|
|
167
169
|
successTint,
|
package/dist/Slider.mjs
CHANGED
package/dist/Spinner.js
CHANGED
|
@@ -89,6 +89,7 @@ function deriveColors(t, scheme) {
|
|
|
89
89
|
const foregroundMuted = mixWithBackground(t.foreground, bg, 0.62);
|
|
90
90
|
const surface = dark ? lighten(bg, -0.06) : darken(bg, 0.04);
|
|
91
91
|
const surfaceStrong = dark ? lighten(bg, -0.12) : darken(bg, 0.08);
|
|
92
|
+
const skeleton = dark ? lighten(bg, -0.1) : darken(bg, 0.1);
|
|
92
93
|
const destructiveTint = dark ? withAlphaOnDark(t.destructive, 0.15, bg) : withAlphaOnWhite(t.destructive, 0.08);
|
|
93
94
|
const destructiveBorder = dark ? withAlphaOnDark(t.destructive, 0.45, bg) : withAlphaOnWhite(t.destructive, 0.3);
|
|
94
95
|
const successTint = dark ? withAlphaOnDark(t.success, 0.15, bg) : withAlphaOnWhite(t.success, 0.08);
|
|
@@ -101,6 +102,7 @@ function deriveColors(t, scheme) {
|
|
|
101
102
|
foregroundMuted,
|
|
102
103
|
surface,
|
|
103
104
|
surfaceStrong,
|
|
105
|
+
skeleton,
|
|
104
106
|
destructiveTint,
|
|
105
107
|
destructiveBorder,
|
|
106
108
|
successTint,
|
package/dist/Spinner.mjs
CHANGED
package/dist/Stats.d.mts
CHANGED
|
@@ -2,6 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { ViewStyle } from 'react-native';
|
|
3
3
|
|
|
4
4
|
type StatsVariant = 'elevated' | 'outlined' | 'filled';
|
|
5
|
+
type StatsSize = 'default' | 'compact';
|
|
5
6
|
interface StatsProps {
|
|
6
7
|
value: string;
|
|
7
8
|
label: string;
|
|
@@ -10,6 +11,8 @@ interface StatsProps {
|
|
|
10
11
|
iconName?: string;
|
|
11
12
|
iconColor?: string;
|
|
12
13
|
variant?: StatsVariant;
|
|
14
|
+
/** `'compact'` reduces everything proportionally for tight grids. */
|
|
15
|
+
size?: StatsSize;
|
|
13
16
|
onPress?: () => void;
|
|
14
17
|
style?: ViewStyle;
|
|
15
18
|
accessibilityLabel?: string;
|
|
@@ -19,7 +22,7 @@ interface StatsGroupProps {
|
|
|
19
22
|
gap?: number;
|
|
20
23
|
style?: ViewStyle;
|
|
21
24
|
}
|
|
22
|
-
declare function StatsComponent({ value, label, description, icon, iconName, iconColor, variant, onPress, style, accessibilityLabel, }: StatsProps): React.JSX.Element;
|
|
25
|
+
declare function StatsComponent({ value, label, description, icon, iconName, iconColor, variant, size, onPress, style, accessibilityLabel, }: StatsProps): React.JSX.Element;
|
|
23
26
|
declare function StatsGroup({ children, gap, style }: StatsGroupProps): React.JSX.Element;
|
|
24
27
|
declare const Stats: React.NamedExoticComponent<StatsProps> & {
|
|
25
28
|
readonly type: typeof StatsComponent;
|
package/dist/Stats.d.ts
CHANGED
|
@@ -2,6 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { ViewStyle } from 'react-native';
|
|
3
3
|
|
|
4
4
|
type StatsVariant = 'elevated' | 'outlined' | 'filled';
|
|
5
|
+
type StatsSize = 'default' | 'compact';
|
|
5
6
|
interface StatsProps {
|
|
6
7
|
value: string;
|
|
7
8
|
label: string;
|
|
@@ -10,6 +11,8 @@ interface StatsProps {
|
|
|
10
11
|
iconName?: string;
|
|
11
12
|
iconColor?: string;
|
|
12
13
|
variant?: StatsVariant;
|
|
14
|
+
/** `'compact'` reduces everything proportionally for tight grids. */
|
|
15
|
+
size?: StatsSize;
|
|
13
16
|
onPress?: () => void;
|
|
14
17
|
style?: ViewStyle;
|
|
15
18
|
accessibilityLabel?: string;
|
|
@@ -19,7 +22,7 @@ interface StatsGroupProps {
|
|
|
19
22
|
gap?: number;
|
|
20
23
|
style?: ViewStyle;
|
|
21
24
|
}
|
|
22
|
-
declare function StatsComponent({ value, label, description, icon, iconName, iconColor, variant, onPress, style, accessibilityLabel, }: StatsProps): React.JSX.Element;
|
|
25
|
+
declare function StatsComponent({ value, label, description, icon, iconName, iconColor, variant, size, onPress, style, accessibilityLabel, }: StatsProps): React.JSX.Element;
|
|
23
26
|
declare function StatsGroup({ children, gap, style }: StatsGroupProps): React.JSX.Element;
|
|
24
27
|
declare const Stats: React.NamedExoticComponent<StatsProps> & {
|
|
25
28
|
readonly type: typeof StatsComponent;
|
package/dist/Stats.js
CHANGED
|
@@ -162,6 +162,7 @@ function deriveColors(t, scheme) {
|
|
|
162
162
|
const foregroundMuted = mixWithBackground(t.foreground, bg, 0.62);
|
|
163
163
|
const surface = dark ? lighten(bg, -0.06) : darken(bg, 0.04);
|
|
164
164
|
const surfaceStrong = dark ? lighten(bg, -0.12) : darken(bg, 0.08);
|
|
165
|
+
const skeleton = dark ? lighten(bg, -0.1) : darken(bg, 0.1);
|
|
165
166
|
const destructiveTint = dark ? withAlphaOnDark(t.destructive, 0.15, bg) : withAlphaOnWhite(t.destructive, 0.08);
|
|
166
167
|
const destructiveBorder = dark ? withAlphaOnDark(t.destructive, 0.45, bg) : withAlphaOnWhite(t.destructive, 0.3);
|
|
167
168
|
const successTint = dark ? withAlphaOnDark(t.success, 0.15, bg) : withAlphaOnWhite(t.success, 0.08);
|
|
@@ -174,6 +175,7 @@ function deriveColors(t, scheme) {
|
|
|
174
175
|
foregroundMuted,
|
|
175
176
|
surface,
|
|
176
177
|
surfaceStrong,
|
|
178
|
+
skeleton,
|
|
177
179
|
destructiveTint,
|
|
178
180
|
destructiveBorder,
|
|
179
181
|
successTint,
|
|
@@ -301,6 +303,7 @@ function StatsComponent({
|
|
|
301
303
|
iconName,
|
|
302
304
|
iconColor,
|
|
303
305
|
variant = "elevated",
|
|
306
|
+
size = "default",
|
|
304
307
|
onPress,
|
|
305
308
|
style,
|
|
306
309
|
accessibilityLabel
|
|
@@ -319,6 +322,27 @@ function StatsComponent({
|
|
|
319
322
|
onPress();
|
|
320
323
|
};
|
|
321
324
|
const isCompact = containerWidth > 0 && containerWidth < COMPACT_THRESHOLD && !!(icon ?? iconName);
|
|
325
|
+
const sizeStyles = size === "compact" ? {
|
|
326
|
+
valueFontFamily: "Sohne-SemiBold",
|
|
327
|
+
valueFontSize: ms(16),
|
|
328
|
+
valueLineHeight: mvs(20),
|
|
329
|
+
labelFontSize: ms(11),
|
|
330
|
+
labelLineHeight: mvs(14),
|
|
331
|
+
descriptionFontSize: ms(10),
|
|
332
|
+
descriptionLineHeight: mvs(14),
|
|
333
|
+
iconSize: ms(18),
|
|
334
|
+
padding: s(12)
|
|
335
|
+
} : {
|
|
336
|
+
valueFontFamily: "Sohne-Bold",
|
|
337
|
+
valueFontSize: ms(21),
|
|
338
|
+
valueLineHeight: mvs(25),
|
|
339
|
+
labelFontSize: ms(13),
|
|
340
|
+
labelLineHeight: mvs(18),
|
|
341
|
+
descriptionFontSize: ms(12),
|
|
342
|
+
descriptionLineHeight: mvs(16),
|
|
343
|
+
iconSize: ms(20),
|
|
344
|
+
padding: s(16)
|
|
345
|
+
};
|
|
322
346
|
const variantStyle = {
|
|
323
347
|
elevated: {
|
|
324
348
|
backgroundColor: colors.card,
|
|
@@ -343,10 +367,10 @@ function StatsComponent({
|
|
|
343
367
|
}
|
|
344
368
|
}[variant];
|
|
345
369
|
const iconColorResolved = iconColor ?? colors.primary;
|
|
346
|
-
const resolvedIcon = iconName ? renderIcon(iconName,
|
|
370
|
+
const resolvedIcon = iconName ? renderIcon(iconName, sizeStyles.iconSize, iconColorResolved) : icon;
|
|
347
371
|
const iconElement = resolvedIcon ? /* @__PURE__ */ React3__default.default.createElement(reactNative.View, { style: styles.iconWrapper }, resolvedIcon) : null;
|
|
348
|
-
const valueElement = /* @__PURE__ */ React3__default.default.createElement(reactNative.Text, { style: [styles.value, { color: colors.foreground }], allowFontScaling: true }, value);
|
|
349
|
-
const cardContent = /* @__PURE__ */ React3__default.default.createElement(reactNative.View, { style: [styles.card, variantStyle, style], onLayout: handleLayout }, isCompact ? /* @__PURE__ */ React3__default.default.createElement(React3__default.default.Fragment, null, iconElement, /* @__PURE__ */ React3__default.default.createElement(reactNative.View, { style: styles.compactValue }, valueElement), /* @__PURE__ */ React3__default.default.createElement(reactNative.Text, { style: [styles.label, { color: colors.foregroundSubtle }], allowFontScaling: true }, label), description ? /* @__PURE__ */ React3__default.default.createElement(reactNative.Text, { style: [styles.description, { color: colors.foregroundMuted }], allowFontScaling: true }, description) : null) : /* @__PURE__ */ React3__default.default.createElement(React3__default.default.Fragment, null, /* @__PURE__ */ React3__default.default.createElement(reactNative.View, { style: styles.valueRow }, iconElement, valueElement), /* @__PURE__ */ React3__default.default.createElement(reactNative.Text, { style: [styles.label, { color: colors.foregroundSubtle }], allowFontScaling: true }, label), description ? /* @__PURE__ */ React3__default.default.createElement(reactNative.Text, { style: [styles.description, { color: colors.foregroundMuted }], allowFontScaling: true }, description) : null));
|
|
372
|
+
const valueElement = /* @__PURE__ */ React3__default.default.createElement(reactNative.Text, { style: [styles.value, { color: colors.foreground, fontFamily: sizeStyles.valueFontFamily, fontSize: sizeStyles.valueFontSize, lineHeight: sizeStyles.valueLineHeight }], allowFontScaling: true }, value);
|
|
373
|
+
const cardContent = /* @__PURE__ */ React3__default.default.createElement(reactNative.View, { style: [styles.card, variantStyle, { padding: sizeStyles.padding }, style], onLayout: handleLayout }, isCompact ? /* @__PURE__ */ React3__default.default.createElement(React3__default.default.Fragment, null, iconElement, /* @__PURE__ */ React3__default.default.createElement(reactNative.View, { style: styles.compactValue }, valueElement), /* @__PURE__ */ React3__default.default.createElement(reactNative.Text, { style: [styles.label, { color: colors.foregroundSubtle, fontSize: sizeStyles.labelFontSize, lineHeight: sizeStyles.labelLineHeight }], allowFontScaling: true }, label), description ? /* @__PURE__ */ React3__default.default.createElement(reactNative.Text, { style: [styles.description, { color: colors.foregroundMuted, fontSize: sizeStyles.descriptionFontSize, lineHeight: sizeStyles.descriptionLineHeight }], allowFontScaling: true }, description) : null) : /* @__PURE__ */ React3__default.default.createElement(React3__default.default.Fragment, null, /* @__PURE__ */ React3__default.default.createElement(reactNative.View, { style: styles.valueRow }, iconElement, valueElement), /* @__PURE__ */ React3__default.default.createElement(reactNative.Text, { style: [styles.label, { color: colors.foregroundSubtle, fontSize: sizeStyles.labelFontSize, lineHeight: sizeStyles.labelLineHeight }], allowFontScaling: true }, label), description ? /* @__PURE__ */ React3__default.default.createElement(reactNative.Text, { style: [styles.description, { color: colors.foregroundMuted, fontSize: sizeStyles.descriptionFontSize, lineHeight: sizeStyles.descriptionLineHeight }], allowFontScaling: true }, description) : null));
|
|
350
374
|
if (onPress) {
|
|
351
375
|
return /* @__PURE__ */ React3__default.default.createElement(
|
|
352
376
|
PressableCard,
|
package/dist/Stats.mjs
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
export { Stats } from './chunk-
|
|
1
|
+
export { Stats } from './chunk-4XOB5TTD.mjs';
|
|
2
2
|
import './chunk-3DKJ2GIC.mjs';
|
|
3
3
|
import './chunk-EJ7ZPXOH.mjs';
|
|
4
4
|
import './chunk-DVK4G2GT.mjs';
|
|
5
5
|
import './chunk-QY3X2UYR.mjs';
|
|
6
6
|
import './chunk-KA7LTET3.mjs';
|
|
7
|
-
import './chunk-
|
|
7
|
+
import './chunk-YTXRIXNZ.mjs';
|
|
8
8
|
import './chunk-2CE3TQVY.mjs';
|
|
9
9
|
import './chunk-Y6FXYEAI.mjs';
|
package/dist/Switch.js
CHANGED
|
@@ -151,6 +151,7 @@ function deriveColors(t, scheme) {
|
|
|
151
151
|
const foregroundMuted = mixWithBackground(t.foreground, bg, 0.62);
|
|
152
152
|
const surface = dark ? lighten(bg, -0.06) : darken(bg, 0.04);
|
|
153
153
|
const surfaceStrong = dark ? lighten(bg, -0.12) : darken(bg, 0.08);
|
|
154
|
+
const skeleton = dark ? lighten(bg, -0.1) : darken(bg, 0.1);
|
|
154
155
|
const destructiveTint = dark ? withAlphaOnDark(t.destructive, 0.15, bg) : withAlphaOnWhite(t.destructive, 0.08);
|
|
155
156
|
const destructiveBorder = dark ? withAlphaOnDark(t.destructive, 0.45, bg) : withAlphaOnWhite(t.destructive, 0.3);
|
|
156
157
|
const successTint = dark ? withAlphaOnDark(t.success, 0.15, bg) : withAlphaOnWhite(t.success, 0.08);
|
|
@@ -163,6 +164,7 @@ function deriveColors(t, scheme) {
|
|
|
163
164
|
foregroundMuted,
|
|
164
165
|
surface,
|
|
165
166
|
surfaceStrong,
|
|
167
|
+
skeleton,
|
|
166
168
|
destructiveTint,
|
|
167
169
|
destructiveBorder,
|
|
168
170
|
successTint,
|
package/dist/Switch.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { Switch } from './chunk-
|
|
1
|
+
export { Switch } from './chunk-RMRS44MQ.mjs';
|
|
2
2
|
import './chunk-EJ7ZPXOH.mjs';
|
|
3
3
|
import './chunk-DVK4G2GT.mjs';
|
|
4
|
-
import './chunk-
|
|
4
|
+
import './chunk-YTXRIXNZ.mjs';
|
|
5
5
|
import './chunk-2CE3TQVY.mjs';
|
|
6
6
|
import './chunk-Y6FXYEAI.mjs';
|
package/dist/TabBar.js
CHANGED
|
@@ -107,6 +107,7 @@ function deriveColors(t, scheme) {
|
|
|
107
107
|
const foregroundMuted = mixWithBackground(t.foreground, bg, 0.62);
|
|
108
108
|
const surface = dark ? lighten(bg, -0.06) : darken(bg, 0.04);
|
|
109
109
|
const surfaceStrong = dark ? lighten(bg, -0.12) : darken(bg, 0.08);
|
|
110
|
+
const skeleton = dark ? lighten(bg, -0.1) : darken(bg, 0.1);
|
|
110
111
|
const destructiveTint = dark ? withAlphaOnDark(t.destructive, 0.15, bg) : withAlphaOnWhite(t.destructive, 0.08);
|
|
111
112
|
const destructiveBorder = dark ? withAlphaOnDark(t.destructive, 0.45, bg) : withAlphaOnWhite(t.destructive, 0.3);
|
|
112
113
|
const successTint = dark ? withAlphaOnDark(t.success, 0.15, bg) : withAlphaOnWhite(t.success, 0.08);
|
|
@@ -119,6 +120,7 @@ function deriveColors(t, scheme) {
|
|
|
119
120
|
foregroundMuted,
|
|
120
121
|
surface,
|
|
121
122
|
surfaceStrong,
|
|
123
|
+
skeleton,
|
|
122
124
|
destructiveTint,
|
|
123
125
|
destructiveBorder,
|
|
124
126
|
successTint,
|
package/dist/TabBar.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { TabBar } from './chunk-
|
|
1
|
+
export { TabBar } from './chunk-NJG7DHVF.mjs';
|
|
2
2
|
import './chunk-EJ7ZPXOH.mjs';
|
|
3
3
|
import './chunk-KA7LTET3.mjs';
|
|
4
|
-
import './chunk-
|
|
4
|
+
import './chunk-YTXRIXNZ.mjs';
|
|
5
5
|
import './chunk-2CE3TQVY.mjs';
|
|
6
6
|
import './chunk-Y6FXYEAI.mjs';
|
package/dist/Tabs.js
CHANGED
|
@@ -151,6 +151,7 @@ function deriveColors(t, scheme) {
|
|
|
151
151
|
const foregroundMuted = mixWithBackground(t.foreground, bg, 0.62);
|
|
152
152
|
const surface = dark ? lighten(bg, -0.06) : darken(bg, 0.04);
|
|
153
153
|
const surfaceStrong = dark ? lighten(bg, -0.12) : darken(bg, 0.08);
|
|
154
|
+
const skeleton = dark ? lighten(bg, -0.1) : darken(bg, 0.1);
|
|
154
155
|
const destructiveTint = dark ? withAlphaOnDark(t.destructive, 0.15, bg) : withAlphaOnWhite(t.destructive, 0.08);
|
|
155
156
|
const destructiveBorder = dark ? withAlphaOnDark(t.destructive, 0.45, bg) : withAlphaOnWhite(t.destructive, 0.3);
|
|
156
157
|
const successTint = dark ? withAlphaOnDark(t.success, 0.15, bg) : withAlphaOnWhite(t.success, 0.08);
|
|
@@ -163,6 +164,7 @@ function deriveColors(t, scheme) {
|
|
|
163
164
|
foregroundMuted,
|
|
164
165
|
surface,
|
|
165
166
|
surfaceStrong,
|
|
167
|
+
skeleton,
|
|
166
168
|
destructiveTint,
|
|
167
169
|
destructiveBorder,
|
|
168
170
|
successTint,
|
package/dist/Tabs.mjs
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export { Tabs, TabsContent } from './chunk-
|
|
1
|
+
export { Tabs, TabsContent } from './chunk-IVSRW4HS.mjs';
|
|
2
2
|
import './chunk-3DKJ2GIC.mjs';
|
|
3
3
|
import './chunk-EJ7ZPXOH.mjs';
|
|
4
4
|
import './chunk-DVK4G2GT.mjs';
|
|
5
|
-
import './chunk-
|
|
5
|
+
import './chunk-YTXRIXNZ.mjs';
|
|
6
6
|
import './chunk-2CE3TQVY.mjs';
|
|
7
7
|
import './chunk-Y6FXYEAI.mjs';
|
package/dist/Text.js
CHANGED
|
@@ -90,6 +90,7 @@ function deriveColors(t, scheme) {
|
|
|
90
90
|
const foregroundMuted = mixWithBackground(t.foreground, bg, 0.62);
|
|
91
91
|
const surface = dark ? lighten(bg, -0.06) : darken(bg, 0.04);
|
|
92
92
|
const surfaceStrong = dark ? lighten(bg, -0.12) : darken(bg, 0.08);
|
|
93
|
+
const skeleton = dark ? lighten(bg, -0.1) : darken(bg, 0.1);
|
|
93
94
|
const destructiveTint = dark ? withAlphaOnDark(t.destructive, 0.15, bg) : withAlphaOnWhite(t.destructive, 0.08);
|
|
94
95
|
const destructiveBorder = dark ? withAlphaOnDark(t.destructive, 0.45, bg) : withAlphaOnWhite(t.destructive, 0.3);
|
|
95
96
|
const successTint = dark ? withAlphaOnDark(t.success, 0.15, bg) : withAlphaOnWhite(t.success, 0.08);
|
|
@@ -102,6 +103,7 @@ function deriveColors(t, scheme) {
|
|
|
102
103
|
foregroundMuted,
|
|
103
104
|
surface,
|
|
104
105
|
surfaceStrong,
|
|
106
|
+
skeleton,
|
|
105
107
|
destructiveTint,
|
|
106
108
|
destructiveBorder,
|
|
107
109
|
successTint,
|
package/dist/Text.mjs
CHANGED
package/dist/Textarea.js
CHANGED
|
@@ -103,6 +103,7 @@ function deriveColors(t, scheme) {
|
|
|
103
103
|
const foregroundMuted = mixWithBackground(t.foreground, bg, 0.62);
|
|
104
104
|
const surface = dark ? lighten(bg, -0.06) : darken(bg, 0.04);
|
|
105
105
|
const surfaceStrong = dark ? lighten(bg, -0.12) : darken(bg, 0.08);
|
|
106
|
+
const skeleton = dark ? lighten(bg, -0.1) : darken(bg, 0.1);
|
|
106
107
|
const destructiveTint = dark ? withAlphaOnDark(t.destructive, 0.15, bg) : withAlphaOnWhite(t.destructive, 0.08);
|
|
107
108
|
const destructiveBorder = dark ? withAlphaOnDark(t.destructive, 0.45, bg) : withAlphaOnWhite(t.destructive, 0.3);
|
|
108
109
|
const successTint = dark ? withAlphaOnDark(t.success, 0.15, bg) : withAlphaOnWhite(t.success, 0.08);
|
|
@@ -115,6 +116,7 @@ function deriveColors(t, scheme) {
|
|
|
115
116
|
foregroundMuted,
|
|
116
117
|
surface,
|
|
117
118
|
surfaceStrong,
|
|
119
|
+
skeleton,
|
|
118
120
|
destructiveTint,
|
|
119
121
|
destructiveBorder,
|
|
120
122
|
successTint,
|
package/dist/Textarea.mjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
export { Textarea } from './chunk-
|
|
1
|
+
export { Textarea } from './chunk-2BA3JMKK.mjs';
|
|
2
2
|
import './chunk-DVK4G2GT.mjs';
|
|
3
3
|
import './chunk-KA7LTET3.mjs';
|
|
4
|
-
import './chunk-
|
|
4
|
+
import './chunk-YTXRIXNZ.mjs';
|
|
5
5
|
import './chunk-2CE3TQVY.mjs';
|
|
6
6
|
import './chunk-Y6FXYEAI.mjs';
|
package/dist/Toast.js
CHANGED
|
@@ -91,6 +91,7 @@ function deriveColors(t, scheme) {
|
|
|
91
91
|
const foregroundMuted = mixWithBackground(t.foreground, bg, 0.62);
|
|
92
92
|
const surface = dark ? lighten(bg, -0.06) : darken(bg, 0.04);
|
|
93
93
|
const surfaceStrong = dark ? lighten(bg, -0.12) : darken(bg, 0.08);
|
|
94
|
+
const skeleton = dark ? lighten(bg, -0.1) : darken(bg, 0.1);
|
|
94
95
|
const destructiveTint = dark ? withAlphaOnDark(t.destructive, 0.15, bg) : withAlphaOnWhite(t.destructive, 0.08);
|
|
95
96
|
const destructiveBorder = dark ? withAlphaOnDark(t.destructive, 0.45, bg) : withAlphaOnWhite(t.destructive, 0.3);
|
|
96
97
|
const successTint = dark ? withAlphaOnDark(t.success, 0.15, bg) : withAlphaOnWhite(t.success, 0.08);
|
|
@@ -103,6 +104,7 @@ function deriveColors(t, scheme) {
|
|
|
103
104
|
foregroundMuted,
|
|
104
105
|
surface,
|
|
105
106
|
surfaceStrong,
|
|
107
|
+
skeleton,
|
|
106
108
|
destructiveTint,
|
|
107
109
|
destructiveBorder,
|
|
108
110
|
successTint,
|
package/dist/Toast.mjs
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export { ToastProvider, sonnerToast as toast, useToast } from './chunk-
|
|
2
|
-
import './chunk-
|
|
1
|
+
export { ToastProvider, sonnerToast as toast, useToast } from './chunk-YMYIEVZP.mjs';
|
|
2
|
+
import './chunk-YTXRIXNZ.mjs';
|
|
3
3
|
import './chunk-2CE3TQVY.mjs';
|
|
4
4
|
import './chunk-Y6FXYEAI.mjs';
|
package/dist/Toggle.js
CHANGED
|
@@ -164,6 +164,7 @@ function deriveColors(t, scheme) {
|
|
|
164
164
|
const foregroundMuted = mixWithBackground(t.foreground, bg, 0.62);
|
|
165
165
|
const surface = dark ? lighten(bg, -0.06) : darken(bg, 0.04);
|
|
166
166
|
const surfaceStrong = dark ? lighten(bg, -0.12) : darken(bg, 0.08);
|
|
167
|
+
const skeleton = dark ? lighten(bg, -0.1) : darken(bg, 0.1);
|
|
167
168
|
const destructiveTint = dark ? withAlphaOnDark(t.destructive, 0.15, bg) : withAlphaOnWhite(t.destructive, 0.08);
|
|
168
169
|
const destructiveBorder = dark ? withAlphaOnDark(t.destructive, 0.45, bg) : withAlphaOnWhite(t.destructive, 0.3);
|
|
169
170
|
const successTint = dark ? withAlphaOnDark(t.success, 0.15, bg) : withAlphaOnWhite(t.success, 0.08);
|
|
@@ -176,6 +177,7 @@ function deriveColors(t, scheme) {
|
|
|
176
177
|
foregroundMuted,
|
|
177
178
|
surface,
|
|
178
179
|
surfaceStrong,
|
|
180
|
+
skeleton,
|
|
179
181
|
destructiveTint,
|
|
180
182
|
destructiveBorder,
|
|
181
183
|
successTint,
|
package/dist/Toggle.mjs
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export { Toggle } from './chunk-
|
|
1
|
+
export { Toggle } from './chunk-UNNRUJTM.mjs';
|
|
2
2
|
import './chunk-3DKJ2GIC.mjs';
|
|
3
3
|
import './chunk-EJ7ZPXOH.mjs';
|
|
4
4
|
import './chunk-DVK4G2GT.mjs';
|
|
5
5
|
import './chunk-KA7LTET3.mjs';
|
|
6
|
-
import './chunk-
|
|
6
|
+
import './chunk-YTXRIXNZ.mjs';
|
|
7
7
|
import './chunk-2CE3TQVY.mjs';
|
|
8
8
|
import './chunk-Y6FXYEAI.mjs';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { TIMINGS, EASINGS } from './chunk-DVK4G2GT.mjs';
|
|
2
2
|
import { renderIcon } from './chunk-KA7LTET3.mjs';
|
|
3
|
-
import { useTheme } from './chunk-
|
|
3
|
+
import { useTheme } from './chunk-YTXRIXNZ.mjs';
|
|
4
4
|
import { vs, ms, s } from './chunk-2CE3TQVY.mjs';
|
|
5
5
|
import React, { useState, useEffect } from 'react';
|
|
6
6
|
import { Platform, StyleSheet, View, Text, TextInput } from 'react-native';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { renderIcon } from './chunk-KA7LTET3.mjs';
|
|
2
|
-
import { useTheme } from './chunk-
|
|
2
|
+
import { useTheme } from './chunk-YTXRIXNZ.mjs';
|
|
3
3
|
import { mvs, ms, s } from './chunk-2CE3TQVY.mjs';
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { StyleSheet, View, Text } from 'react-native';
|