jfs-components 0.0.74 → 0.0.78
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/CHANGELOG.md +109 -0
- package/lib/commonjs/components/Accordion/Accordion.js +55 -55
- package/lib/commonjs/components/ActionFooter/ActionFooter.js +193 -82
- package/lib/commonjs/components/Avatar/Avatar.js +20 -0
- package/lib/commonjs/components/Badge/Badge.js +23 -0
- package/lib/commonjs/components/Button/Button.js +37 -0
- package/lib/commonjs/components/Checkbox/Checkbox.js +21 -9
- package/lib/commonjs/components/DropdownInput/DropdownInput.js +30 -16
- package/lib/commonjs/components/ExpandableCheckbox/ExpandableCheckbox.js +167 -0
- package/lib/commonjs/components/FormField/FormField.js +14 -1
- package/lib/commonjs/components/FullscreenModal/FullscreenModal.js +355 -0
- package/lib/commonjs/components/IconButton/IconButton.js +20 -0
- package/lib/commonjs/components/Image/Image.js +26 -1
- package/lib/commonjs/components/ListItem/ListItem.js +25 -10
- package/lib/commonjs/components/LottiePlayer/LottiePlayer.js +116 -0
- package/lib/commonjs/components/LottiePlayer/LottiePlayer.web.js +82 -0
- package/lib/commonjs/components/LottiePlayer/loadNativeLottieView.js +74 -0
- package/lib/commonjs/components/LottiePlayer/loadWebLottieView.js +50 -0
- package/lib/commonjs/components/MessageField/MessageField.js +318 -0
- package/lib/commonjs/components/NavArrow/NavArrow.js +58 -17
- package/lib/commonjs/components/PageHero/PageHero.js +41 -5
- package/lib/commonjs/components/RechargeCard/RechargeCard.js +32 -17
- package/lib/commonjs/components/Stepper/Step.js +47 -60
- package/lib/commonjs/components/Stepper/StepLabel.js +40 -10
- package/lib/commonjs/components/Stepper/Stepper.js +15 -17
- package/lib/commonjs/components/SuggestiveSearch/SuggestiveSearch.js +487 -0
- package/lib/commonjs/components/Text/Text.js +31 -1
- package/lib/commonjs/components/TextInput/TextInput.js +16 -1
- package/lib/commonjs/components/Title/Title.js +10 -2
- package/lib/commonjs/components/index.js +35 -0
- package/lib/commonjs/design-tokens/Coin Variables-variables-full.json +1 -1
- package/lib/commonjs/icons/Icon.js +16 -0
- package/lib/commonjs/icons/registry.js +1 -1
- package/lib/commonjs/index.js +12 -0
- package/lib/commonjs/skeleton/Skeleton.js +234 -0
- package/lib/commonjs/skeleton/SkeletonGroup.js +140 -0
- package/lib/commonjs/skeleton/index.js +58 -0
- package/lib/commonjs/skeleton/shimmer-tokens.js +189 -0
- package/lib/commonjs/skeleton/useReducedMotion.js +64 -0
- package/lib/module/components/Accordion/Accordion.js +56 -56
- package/lib/module/components/ActionFooter/ActionFooter.js +193 -83
- package/lib/module/components/Avatar/Avatar.js +19 -0
- package/lib/module/components/Badge/Badge.js +23 -0
- package/lib/module/components/Button/Button.js +37 -0
- package/lib/module/components/Checkbox/Checkbox.js +22 -10
- package/lib/module/components/DropdownInput/DropdownInput.js +30 -16
- package/lib/module/components/ExpandableCheckbox/ExpandableCheckbox.js +161 -0
- package/lib/module/components/FormField/FormField.js +16 -3
- package/lib/module/components/FullscreenModal/FullscreenModal.js +350 -0
- package/lib/module/components/IconButton/IconButton.js +20 -0
- package/lib/module/components/Image/Image.js +25 -1
- package/lib/module/components/ListItem/ListItem.js +25 -10
- package/lib/module/components/LottiePlayer/LottiePlayer.js +111 -0
- package/lib/module/components/LottiePlayer/LottiePlayer.web.js +77 -0
- package/lib/module/components/LottiePlayer/loadNativeLottieView.js +69 -0
- package/lib/module/components/LottiePlayer/loadWebLottieView.js +45 -0
- package/lib/module/components/MessageField/MessageField.js +313 -0
- package/lib/module/components/NavArrow/NavArrow.js +59 -18
- package/lib/module/components/PageHero/PageHero.js +41 -5
- package/lib/module/components/RechargeCard/RechargeCard.js +33 -17
- package/lib/module/components/Stepper/Step.js +48 -61
- package/lib/module/components/Stepper/StepLabel.js +40 -10
- package/lib/module/components/Stepper/Stepper.js +15 -17
- package/lib/module/components/SuggestiveSearch/SuggestiveSearch.js +481 -0
- package/lib/module/components/Text/Text.js +31 -1
- package/lib/module/components/TextInput/TextInput.js +17 -2
- package/lib/module/components/Title/Title.js +10 -2
- package/lib/module/components/index.js +5 -0
- package/lib/module/design-tokens/Coin Variables-variables-full.json +1 -1
- package/lib/module/icons/Icon.js +16 -0
- package/lib/module/icons/registry.js +1 -1
- package/lib/module/index.js +2 -1
- package/lib/module/skeleton/Skeleton.js +229 -0
- package/lib/module/skeleton/SkeletonGroup.js +133 -0
- package/lib/module/skeleton/index.js +6 -0
- package/lib/module/skeleton/shimmer-tokens.js +181 -0
- package/lib/module/skeleton/useReducedMotion.js +61 -0
- package/lib/typescript/src/components/Accordion/Accordion.d.ts +14 -20
- package/lib/typescript/src/components/ActionFooter/ActionFooter.d.ts +26 -21
- package/lib/typescript/src/components/Avatar/Avatar.d.ts +7 -1
- package/lib/typescript/src/components/Badge/Badge.d.ts +7 -1
- package/lib/typescript/src/components/Button/Button.d.ts +8 -1
- package/lib/typescript/src/components/ExpandableCheckbox/ExpandableCheckbox.d.ts +63 -0
- package/lib/typescript/src/components/FullscreenModal/FullscreenModal.d.ts +99 -0
- package/lib/typescript/src/components/IconButton/IconButton.d.ts +7 -1
- package/lib/typescript/src/components/Image/Image.d.ts +8 -1
- package/lib/typescript/src/components/LottiePlayer/LottiePlayer.d.ts +85 -0
- package/lib/typescript/src/components/LottiePlayer/LottiePlayer.web.d.ts +28 -0
- package/lib/typescript/src/components/LottiePlayer/loadNativeLottieView.d.ts +11 -0
- package/lib/typescript/src/components/LottiePlayer/loadWebLottieView.d.ts +11 -0
- package/lib/typescript/src/components/MessageField/MessageField.d.ts +81 -0
- package/lib/typescript/src/components/NavArrow/NavArrow.d.ts +10 -5
- package/lib/typescript/src/components/PageHero/PageHero.d.ts +31 -5
- package/lib/typescript/src/components/Stepper/Step.d.ts +4 -1
- package/lib/typescript/src/components/Stepper/StepLabel.d.ts +4 -1
- package/lib/typescript/src/components/Stepper/Stepper.d.ts +3 -1
- package/lib/typescript/src/components/SuggestiveSearch/SuggestiveSearch.d.ts +123 -0
- package/lib/typescript/src/components/Text/Text.d.ts +20 -1
- package/lib/typescript/src/components/index.d.ts +8 -3
- package/lib/typescript/src/icons/Icon.d.ts +7 -1
- package/lib/typescript/src/icons/registry.d.ts +1 -1
- package/lib/typescript/src/index.d.ts +1 -0
- package/lib/typescript/src/skeleton/Skeleton.d.ts +60 -0
- package/lib/typescript/src/skeleton/SkeletonGroup.d.ts +78 -0
- package/lib/typescript/src/skeleton/index.d.ts +5 -0
- package/lib/typescript/src/skeleton/shimmer-tokens.d.ts +160 -0
- package/lib/typescript/src/skeleton/useReducedMotion.d.ts +15 -0
- package/package.json +11 -1
- package/src/components/Accordion/Accordion.tsx +113 -73
- package/src/components/ActionFooter/ActionFooter.tsx +210 -92
- package/src/components/Avatar/Avatar.tsx +26 -0
- package/src/components/Badge/Badge.tsx +27 -0
- package/src/components/Button/Button.tsx +40 -0
- package/src/components/Checkbox/Checkbox.tsx +22 -9
- package/src/components/DropdownInput/DropdownInput.tsx +67 -39
- package/src/components/ExpandableCheckbox/ExpandableCheckbox.tsx +237 -0
- package/src/components/FormField/FormField.tsx +19 -3
- package/src/components/FullscreenModal/FullscreenModal.tsx +414 -0
- package/src/components/IconButton/IconButton.tsx +27 -0
- package/src/components/Image/Image.tsx +25 -0
- package/src/components/ListItem/ListItem.tsx +21 -10
- package/src/components/LottiePlayer/LottiePlayer.tsx +145 -0
- package/src/components/LottiePlayer/LottiePlayer.web.tsx +94 -0
- package/src/components/LottiePlayer/loadNativeLottieView.tsx +87 -0
- package/src/components/LottiePlayer/loadWebLottieView.tsx +64 -0
- package/src/components/MessageField/MessageField.tsx +543 -0
- package/src/components/NavArrow/NavArrow.tsx +81 -17
- package/src/components/PageHero/PageHero.tsx +61 -4
- package/src/components/RechargeCard/RechargeCard.tsx +32 -24
- package/src/components/Stepper/Step.tsx +52 -51
- package/src/components/Stepper/StepLabel.tsx +46 -9
- package/src/components/Stepper/Stepper.tsx +20 -15
- package/src/components/SuggestiveSearch/SuggestiveSearch.tsx +756 -0
- package/src/components/Text/Text.tsx +54 -0
- package/src/components/TextInput/TextInput.tsx +14 -1
- package/src/components/Title/Title.tsx +13 -2
- package/src/components/index.ts +8 -3
- package/src/design-tokens/Coin Variables-variables-full.json +1 -1
- package/src/icons/Icon.tsx +17 -0
- package/src/icons/registry.ts +1 -1
- package/src/index.ts +1 -0
- package/src/skeleton/Skeleton.tsx +298 -0
- package/src/skeleton/SkeletonGroup.tsx +193 -0
- package/src/skeleton/index.ts +10 -0
- package/src/skeleton/shimmer-tokens.ts +221 -0
- package/src/skeleton/useReducedMotion.ts +72 -0
|
@@ -6,11 +6,14 @@ export type StepProps = {
|
|
|
6
6
|
modes?: Record<string, any>;
|
|
7
7
|
style?: ViewStyle;
|
|
8
8
|
index?: number;
|
|
9
|
+
showLine?: boolean;
|
|
9
10
|
connectorStyle?: ViewStyle;
|
|
10
11
|
title?: string;
|
|
11
12
|
supportingText?: string;
|
|
13
|
+
metaText?: string;
|
|
12
14
|
subtitle?: boolean;
|
|
15
|
+
meta?: boolean;
|
|
13
16
|
status?: StepStatus;
|
|
14
17
|
};
|
|
15
|
-
export declare function Step({ children, modes, style, index, connectorStyle, title, supportingText, subtitle, status, }: StepProps): import("react/jsx-runtime").JSX.Element;
|
|
18
|
+
export declare function Step({ children, modes, style, index, showLine, connectorStyle, title, supportingText, metaText, subtitle, meta, status, }: StepProps): import("react/jsx-runtime").JSX.Element;
|
|
16
19
|
//# sourceMappingURL=Step.d.ts.map
|
|
@@ -2,8 +2,11 @@ import { type ViewStyle } from 'react-native';
|
|
|
2
2
|
export type StepLabelProps = {
|
|
3
3
|
title?: string;
|
|
4
4
|
supportingText?: string;
|
|
5
|
+
metaText?: string;
|
|
6
|
+
subtitle?: boolean;
|
|
7
|
+
meta?: boolean;
|
|
5
8
|
modes?: Record<string, any>;
|
|
6
9
|
style?: ViewStyle;
|
|
7
10
|
};
|
|
8
|
-
export declare function StepLabel({ title, supportingText, modes, style, }: StepLabelProps): import("react/jsx-runtime").JSX.Element;
|
|
11
|
+
export declare function StepLabel({ title, supportingText, metaText, subtitle, meta, modes, style, }: StepLabelProps): import("react/jsx-runtime").JSX.Element;
|
|
9
12
|
//# sourceMappingURL=StepLabel.d.ts.map
|
|
@@ -3,7 +3,9 @@ import { type ViewStyle } from 'react-native';
|
|
|
3
3
|
import { Step } from './Step';
|
|
4
4
|
import { StepLabel } from './StepLabel';
|
|
5
5
|
export { Step, StepLabel };
|
|
6
|
-
type
|
|
6
|
+
export type { StepProps, StepStatus } from './Step';
|
|
7
|
+
export type { StepLabelProps } from './StepLabel';
|
|
8
|
+
export type StepperProps = {
|
|
7
9
|
children?: React.ReactNode;
|
|
8
10
|
modes?: Record<string, any>;
|
|
9
11
|
style?: ViewStyle;
|
|
@@ -0,0 +1,123 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { type StyleProp, type TextInputProps as RNTextInputProps, type TextStyle, type ViewStyle } from 'react-native';
|
|
3
|
+
export type SuggestiveSearchOptionValue = string | number;
|
|
4
|
+
export type SuggestiveSearchOption = {
|
|
5
|
+
/** Stable, unique value used to identify the suggestion. */
|
|
6
|
+
value: SuggestiveSearchOptionValue;
|
|
7
|
+
/** Human-readable label shown in the suggestion list and the input. */
|
|
8
|
+
label: string;
|
|
9
|
+
/** Whether the suggestion is non-selectable. */
|
|
10
|
+
disabled?: boolean;
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* Suggestions accept either a bare string (used as both value and label) or a
|
|
14
|
+
* full `{ value, label }` option object for richer data.
|
|
15
|
+
*/
|
|
16
|
+
export type SuggestiveSearchItem = string | SuggestiveSearchOption;
|
|
17
|
+
export type SuggestiveSearchProps = {
|
|
18
|
+
/** Label rendered above the input. */
|
|
19
|
+
label?: string;
|
|
20
|
+
/** Placeholder text shown when the query is empty. */
|
|
21
|
+
placeholder?: string;
|
|
22
|
+
/**
|
|
23
|
+
* Suggestions to filter against the current query. May be bare strings or
|
|
24
|
+
* `{ value, label }` objects.
|
|
25
|
+
*/
|
|
26
|
+
items?: SuggestiveSearchItem[];
|
|
27
|
+
/**
|
|
28
|
+
* Current query text (controlled). When `undefined` the component manages
|
|
29
|
+
* its own query state internally.
|
|
30
|
+
*/
|
|
31
|
+
inputValue?: string;
|
|
32
|
+
/** Initial query text for uncontrolled mode. */
|
|
33
|
+
defaultInputValue?: string;
|
|
34
|
+
/** Called whenever the query text changes (typing or selection). */
|
|
35
|
+
onInputChange?: (text: string) => void;
|
|
36
|
+
/**
|
|
37
|
+
* Currently selected suggestion value (controlled). When `undefined` the
|
|
38
|
+
* component tracks the selection internally.
|
|
39
|
+
*/
|
|
40
|
+
value?: SuggestiveSearchOptionValue | null;
|
|
41
|
+
/** Initial selected value for uncontrolled mode. */
|
|
42
|
+
defaultValue?: SuggestiveSearchOptionValue | null;
|
|
43
|
+
/** Called when a suggestion is chosen. */
|
|
44
|
+
onValueChange?: (value: SuggestiveSearchOptionValue | null, option?: SuggestiveSearchOption) => void;
|
|
45
|
+
/**
|
|
46
|
+
* Custom predicate deciding whether an option matches the current query.
|
|
47
|
+
* Defaults to a case-insensitive substring match on the label.
|
|
48
|
+
*/
|
|
49
|
+
filter?: (query: string, option: SuggestiveSearchOption) => boolean;
|
|
50
|
+
/**
|
|
51
|
+
* Minimum number of characters required before suggestions are shown.
|
|
52
|
+
* @default 1
|
|
53
|
+
*/
|
|
54
|
+
minChars?: number;
|
|
55
|
+
/** Caps the number of suggestions rendered. Defaults to no limit. */
|
|
56
|
+
maxResults?: number;
|
|
57
|
+
/**
|
|
58
|
+
* Highlights the matched substring of each suggestion in bold.
|
|
59
|
+
* @default true
|
|
60
|
+
*/
|
|
61
|
+
highlightMatch?: boolean;
|
|
62
|
+
/**
|
|
63
|
+
* Message shown when the query has matched no suggestions. When omitted,
|
|
64
|
+
* the dropdown simply stays hidden on an empty result set.
|
|
65
|
+
*/
|
|
66
|
+
emptyMessage?: string;
|
|
67
|
+
/** Custom renderer for a suggestion row (overrides the default label). */
|
|
68
|
+
renderItem?: (option: SuggestiveSearchOption, meta: {
|
|
69
|
+
query: string;
|
|
70
|
+
isSelected: boolean;
|
|
71
|
+
}) => React.ReactNode;
|
|
72
|
+
/** Controlled open state of the suggestion dropdown. */
|
|
73
|
+
open?: boolean;
|
|
74
|
+
/** Initial open state for uncontrolled mode. */
|
|
75
|
+
defaultOpen?: boolean;
|
|
76
|
+
/** Called whenever the open state changes. */
|
|
77
|
+
onOpenChange?: (open: boolean) => void;
|
|
78
|
+
/**
|
|
79
|
+
* Maximum height of the suggestion list before it becomes scrollable.
|
|
80
|
+
* @default 240
|
|
81
|
+
*/
|
|
82
|
+
menuMaxHeight?: number;
|
|
83
|
+
/**
|
|
84
|
+
* Vertical gap between the input and the suggestion dropdown.
|
|
85
|
+
* @default 6
|
|
86
|
+
*/
|
|
87
|
+
menuOffset?: number;
|
|
88
|
+
/** Renders a required asterisk next to the label. */
|
|
89
|
+
isRequired?: boolean;
|
|
90
|
+
/** Disables interaction and dims the field. */
|
|
91
|
+
isDisabled?: boolean;
|
|
92
|
+
/** Marks the field as invalid and shows `errorMessage`. */
|
|
93
|
+
isInvalid?: boolean;
|
|
94
|
+
/** Renders the field as read-only (non-interactive, not dimmed). */
|
|
95
|
+
isReadOnly?: boolean;
|
|
96
|
+
/** Helper text displayed below the input. */
|
|
97
|
+
supportText?: string;
|
|
98
|
+
/** Replaces `supportText` when `isInvalid` is true. */
|
|
99
|
+
errorMessage?: string;
|
|
100
|
+
/** Modes for design token resolution. */
|
|
101
|
+
modes?: Record<string, any>;
|
|
102
|
+
/** Style overrides for the outermost wrapper. */
|
|
103
|
+
style?: StyleProp<ViewStyle>;
|
|
104
|
+
/** Style overrides for the input row. */
|
|
105
|
+
inputStyle?: StyleProp<ViewStyle>;
|
|
106
|
+
/** Style overrides for the input text. */
|
|
107
|
+
inputTextStyle?: StyleProp<TextStyle>;
|
|
108
|
+
/** Style overrides for the suggestion dropdown container. */
|
|
109
|
+
menuStyle?: StyleProp<ViewStyle>;
|
|
110
|
+
/** Accessibility label. Defaults to the visible label / placeholder. */
|
|
111
|
+
accessibilityLabel?: string;
|
|
112
|
+
/** Accessibility hint. */
|
|
113
|
+
accessibilityHint?: string;
|
|
114
|
+
/** Called when the input receives focus. */
|
|
115
|
+
onFocus?: RNTextInputProps['onFocus'];
|
|
116
|
+
/** Called when the input loses focus. */
|
|
117
|
+
onBlur?: RNTextInputProps['onBlur'];
|
|
118
|
+
/** Test identifier. */
|
|
119
|
+
testID?: string;
|
|
120
|
+
};
|
|
121
|
+
declare function SuggestiveSearch({ label, placeholder, items, inputValue, defaultInputValue, onInputChange, value, defaultValue, onValueChange, filter, minChars, maxResults, highlightMatch, emptyMessage, renderItem, open, defaultOpen, onOpenChange, menuMaxHeight, menuOffset, isRequired, isDisabled, isInvalid, isReadOnly, supportText, errorMessage, modes: propModes, style, inputStyle, inputTextStyle, menuStyle, accessibilityLabel, accessibilityHint, onFocus, onBlur, testID, }: SuggestiveSearchProps): import("react/jsx-runtime").JSX.Element;
|
|
122
|
+
export default SuggestiveSearch;
|
|
123
|
+
//# sourceMappingURL=SuggestiveSearch.d.ts.map
|
|
@@ -20,7 +20,26 @@ export type TextProps = {
|
|
|
20
20
|
style?: StyleProp<TextStyle>;
|
|
21
21
|
/** Number of lines to limit the text to. */
|
|
22
22
|
numberOfLines?: number;
|
|
23
|
+
/**
|
|
24
|
+
* Explicit per-instance loading override. When `true`, this `Text` renders
|
|
25
|
+
* a skeleton placeholder regardless of any surrounding `<SkeletonGroup>`.
|
|
26
|
+
* When `false`, the surrounding group is ignored for this instance. When
|
|
27
|
+
* omitted, the surrounding group's `loading` flag wins.
|
|
28
|
+
*/
|
|
29
|
+
loading?: boolean;
|
|
30
|
+
/**
|
|
31
|
+
* Optional width used while the skeleton is showing. Numbers are dp;
|
|
32
|
+
* `'100%'` (etc.) is a valid RN dimension. Defaults to a character-count
|
|
33
|
+
* heuristic based on the resolved font size and the supplied content.
|
|
34
|
+
*/
|
|
35
|
+
skeletonWidth?: number | `${number}%`;
|
|
36
|
+
/**
|
|
37
|
+
* Optional explicit line count for the skeleton placeholder. Defaults to
|
|
38
|
+
* `numberOfLines ?? 1`. Useful when `numberOfLines` is intentionally
|
|
39
|
+
* unbounded but you want a sensible multi-line placeholder.
|
|
40
|
+
*/
|
|
41
|
+
skeletonLines?: number;
|
|
23
42
|
};
|
|
24
|
-
declare function Text({ text, children, textAlign, modes, style, numberOfLines, }: TextProps): import("react/jsx-runtime").JSX.Element;
|
|
43
|
+
declare function Text({ text, children, textAlign, modes, style, numberOfLines, loading, skeletonWidth, skeletonLines, }: TextProps): import("react/jsx-runtime").JSX.Element;
|
|
25
44
|
export default Text;
|
|
26
45
|
//# sourceMappingURL=Text.d.ts.map
|
|
@@ -24,9 +24,11 @@ export { default as Divider, type DividerProps, type DividerDirection } from './
|
|
|
24
24
|
export { default as Drawer } from './Drawer/Drawer';
|
|
25
25
|
export { default as Dropdown, DropdownItem, type DropdownProps, type DropdownItemProps } from './Dropdown/Dropdown';
|
|
26
26
|
export { default as DropdownInput, type DropdownInputProps, type DropdownInputOption, type DropdownInputOptionValue } from './DropdownInput/DropdownInput';
|
|
27
|
+
export { default as SuggestiveSearch, type SuggestiveSearchProps, type SuggestiveSearchOption, type SuggestiveSearchOptionValue, type SuggestiveSearchItem } from './SuggestiveSearch/SuggestiveSearch';
|
|
27
28
|
export { default as CardCTA, type CardCTAProps, type CardCTAType } from './CardCTA/CardCTA';
|
|
28
29
|
export { default as DebitCard, type DebitCardProps } from './DebitCard/DebitCard';
|
|
29
30
|
export { default as FilterBar } from './FilterBar/FilterBar';
|
|
31
|
+
export { default as FullscreenModal, type FullscreenModalProps } from './FullscreenModal/FullscreenModal';
|
|
30
32
|
export { default as Form, type FormProps } from './Form/Form';
|
|
31
33
|
export { useFormContext } from './Form/Form';
|
|
32
34
|
export { default as FormField, type FormFieldProps, type FormFieldType } from './FormField/FormField';
|
|
@@ -47,9 +49,11 @@ export { default as LinearMeter, type LinearMeterProps } from './LinearMeter/Lin
|
|
|
47
49
|
export { default as LinearProgress, type LinearProgressProps } from './LinearProgress/LinearProgress';
|
|
48
50
|
export { default as ListGroup } from './ListGroup/ListGroup';
|
|
49
51
|
export { default as LottieIntroBlock, type LottieIntroBlockProps } from './LottieIntroBlock/LottieIntroBlock';
|
|
52
|
+
export { default as LottiePlayer, type LottiePlayerProps, type LottieAnimationSource } from './LottiePlayer/LottiePlayer';
|
|
50
53
|
export { default as ListItem } from './ListItem/ListItem';
|
|
51
54
|
export { default as MediaCard, type MediaCardProps } from './MediaCard/MediaCard';
|
|
52
55
|
export { default as MerchantProfile, type MerchantProfileProps } from './MerchantProfile/MerchantProfile';
|
|
56
|
+
export { default as MessageField, type MessageFieldProps, type MessageFieldState } from './MessageField/MessageField';
|
|
53
57
|
export { default as MetricLegendItem, type MetricLegendItemProps } from './MetricLegendItem/MetricLegendItem';
|
|
54
58
|
export { default as MoneyValue } from './MoneyValue/MoneyValue';
|
|
55
59
|
export { default as NoteInput, type NoteInputProps } from './NoteInput/NoteInput';
|
|
@@ -59,9 +63,9 @@ export { default as Numpad, type NumpadProps, type NumpadKeyValue } from './Nump
|
|
|
59
63
|
export { default as Title, type TitleProps } from './Title/Title';
|
|
60
64
|
export { default as Screen, type ScreenProps } from './Screen/Screen';
|
|
61
65
|
export { default as Section } from './Section/Section';
|
|
62
|
-
export { default as Stepper } from './Stepper/Stepper';
|
|
63
|
-
export { Step } from './Stepper/Step';
|
|
64
|
-
export { StepLabel } from './Stepper/StepLabel';
|
|
66
|
+
export { default as Stepper, type StepperProps } from './Stepper/Stepper';
|
|
67
|
+
export { Step, type StepProps, type StepStatus } from './Stepper/Step';
|
|
68
|
+
export { StepLabel, type StepLabelProps } from './Stepper/StepLabel';
|
|
65
69
|
export { default as TextInput } from './TextInput/TextInput';
|
|
66
70
|
export { default as StatusHero, type StatusHeroProps } from './StatusHero/StatusHero';
|
|
67
71
|
export { default as ThreadHero, type ThreadHeroProps } from './ThreadHero/ThreadHero';
|
|
@@ -73,6 +77,7 @@ export { default as UpiHandle } from './UpiHandle/UpiHandle';
|
|
|
73
77
|
export { default as VStack, type VStackProps } from './VStack/VStack';
|
|
74
78
|
export { default as ChipGroup, type ChipGroupProps } from './ChipGroup/ChipGroup';
|
|
75
79
|
export { default as EmptyState, type EmptyStateProps } from './EmptyState/EmptyState';
|
|
80
|
+
export { default as ExpandableCheckbox, type ExpandableCheckboxProps } from './ExpandableCheckbox/ExpandableCheckbox';
|
|
76
81
|
export { default as Accordion, type AccordionProps } from './Accordion/Accordion';
|
|
77
82
|
export { default as AccordionCheckbox, type AccordionCheckboxProps } from './AccordionCheckbox/AccordionCheckbox';
|
|
78
83
|
export { default as ActionTile, type ActionTileProps } from './ActionTile/ActionTile';
|
|
@@ -18,6 +18,12 @@ type IconProps = AccessibilityProps & {
|
|
|
18
18
|
size?: number;
|
|
19
19
|
color?: string;
|
|
20
20
|
style?: StyleProp<ViewStyle>;
|
|
21
|
+
/**
|
|
22
|
+
* Explicit per-instance loading override. When `true`, renders a square
|
|
23
|
+
* skeleton at the icon's size; when `false`, the surrounding
|
|
24
|
+
* `<SkeletonGroup>` is ignored. Defaults to inheriting from the group.
|
|
25
|
+
*/
|
|
26
|
+
loading?: boolean;
|
|
21
27
|
};
|
|
22
28
|
/**
|
|
23
29
|
* Generic Icon component.
|
|
@@ -43,6 +49,6 @@ type IconProps = AccessibilityProps & {
|
|
|
43
49
|
* <Icon source={BrandLogo} size={24} color="red" />
|
|
44
50
|
* ```
|
|
45
51
|
*/
|
|
46
|
-
declare function Icon({ name, source, size, color, style, ...rest }: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
52
|
+
declare function Icon({ name, source, size, color, style, loading, ...rest }: IconProps): import("react/jsx-runtime").JSX.Element;
|
|
47
53
|
export default Icon;
|
|
48
54
|
//# sourceMappingURL=Icon.d.ts.map
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* Auto-generated from SVG files in src/icons/
|
|
5
5
|
* DO NOT EDIT MANUALLY - Run "npm run icons:generate" to regenerate
|
|
6
6
|
*
|
|
7
|
-
* Generated: 2026-05-
|
|
7
|
+
* Generated: 2026-05-29T10:37:24.494Z
|
|
8
8
|
*/
|
|
9
9
|
export declare const iconRegistry: Record<string, {
|
|
10
10
|
path: string;
|
|
@@ -0,0 +1,60 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { type DimensionValue, type StyleProp, type ViewStyle } from 'react-native';
|
|
3
|
+
import { type SkeletonKind } from './shimmer-tokens';
|
|
4
|
+
export interface SkeletonProps {
|
|
5
|
+
/**
|
|
6
|
+
* Visual category — controls only the corner-radius token. Sizes are still
|
|
7
|
+
* supplied via `width`/`height`. Defaults to `'other'`.
|
|
8
|
+
*/
|
|
9
|
+
kind?: SkeletonKind;
|
|
10
|
+
/** Width of the rectangular placeholder. Numbers are dp, strings are RN dimensions. */
|
|
11
|
+
width?: DimensionValue;
|
|
12
|
+
/** Height of the rectangular placeholder. */
|
|
13
|
+
height?: DimensionValue;
|
|
14
|
+
/**
|
|
15
|
+
* Optional style overrides merged onto the base layer (e.g. `marginTop`,
|
|
16
|
+
* `alignSelf`). Avoid `backgroundColor` and `borderRadius` here — use the
|
|
17
|
+
* design tokens instead so the system stays consistent.
|
|
18
|
+
*/
|
|
19
|
+
style?: StyleProp<ViewStyle>;
|
|
20
|
+
/**
|
|
21
|
+
* Modes for token resolution (forwarded to `getVariableByName`). Most
|
|
22
|
+
* consumers can omit this — defaults work for every standard mode.
|
|
23
|
+
*/
|
|
24
|
+
modes?: Record<string, any>;
|
|
25
|
+
}
|
|
26
|
+
/**
|
|
27
|
+
* Atomic skeleton placeholder. Renders a base rectangle (background colour +
|
|
28
|
+
* radius per kind) plus an animated overlay that produces the shimmer.
|
|
29
|
+
*
|
|
30
|
+
* Two visual modes share the same engine:
|
|
31
|
+
*
|
|
32
|
+
* - Normal mode (gradient: true): a soft 135° band translates diagonally
|
|
33
|
+
* across the box end-to-end. Its alpha inside the moving band varies
|
|
34
|
+
* 33% → 100% → 33% via gradient stops. The sawtooth clock travels from
|
|
35
|
+
* fully off-screen (−overshoot) to fully off-screen (+overshoot) so the
|
|
36
|
+
* transparent gradient tails clear the box before the loop resets.
|
|
37
|
+
*
|
|
38
|
+
* - Reduced-motion mode (gradient: false): a solid white overlay covers the
|
|
39
|
+
* box and pulses opacity 33% → 100% → 33% in place, with no translation,
|
|
40
|
+
* ease-in-out timing and no stagger.
|
|
41
|
+
*
|
|
42
|
+
* Critical for cross-platform consistency:
|
|
43
|
+
*
|
|
44
|
+
* - The SVG gradient uses `gradientUnits="userSpaceOnUse"` with absolute
|
|
45
|
+
* pixel coordinates that have Δx === Δy. This guarantees the visual angle
|
|
46
|
+
* is exactly 45° in screen pixels (= 135° CSS) on ANY aspect ratio. With
|
|
47
|
+
* the default `objectBoundingBox` units, the gradient line is normalised
|
|
48
|
+
* to the box and tilts off-angle on non-square boxes.
|
|
49
|
+
*
|
|
50
|
+
* - The whole animated overlay sits inside a clipping parent (`overflow:
|
|
51
|
+
* hidden` + `borderRadius`). Translating an `Animated.View` is GPU-cheap
|
|
52
|
+
* on both iOS/Android (Reanimated UI thread) and on web (CSS transforms).
|
|
53
|
+
*
|
|
54
|
+
* - The SVG `id` for the gradient is per-instance (`useId`) so multiple
|
|
55
|
+
* skeletons on a web page don't collide on `url(#…)` resolution.
|
|
56
|
+
*/
|
|
57
|
+
declare function SkeletonImpl({ kind, width, height, style, modes, }: SkeletonProps): import("react/jsx-runtime").JSX.Element;
|
|
58
|
+
declare const Skeleton: React.MemoExoticComponent<typeof SkeletonImpl>;
|
|
59
|
+
export default Skeleton;
|
|
60
|
+
//# sourceMappingURL=Skeleton.d.ts.map
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
2
|
+
import { type SharedValue } from 'react-native-reanimated';
|
|
3
|
+
/**
|
|
4
|
+
* Shape of the value carried by the SkeletonContext.
|
|
5
|
+
*
|
|
6
|
+
* The provider owns ONE Reanimated shared value per group; every child
|
|
7
|
+
* `<Skeleton>` reads it on the UI thread and computes its own opacity from
|
|
8
|
+
* `(clock + perItemPhaseOffset)`. That keeps per-skeleton work bounded to a
|
|
9
|
+
* single `useAnimatedStyle` and avoids per-block JS timers.
|
|
10
|
+
*/
|
|
11
|
+
export interface SkeletonContextValue {
|
|
12
|
+
/** Whether the surrounding group is currently in loading state. */
|
|
13
|
+
active: boolean;
|
|
14
|
+
/**
|
|
15
|
+
* Whether reduced-motion treatment should be applied. May be auto-detected
|
|
16
|
+
* from the OS or explicitly overridden via the `reducedMotion` prop on
|
|
17
|
+
* `<SkeletonGroup>`.
|
|
18
|
+
*/
|
|
19
|
+
reducedMotion: boolean;
|
|
20
|
+
/**
|
|
21
|
+
* Shared phase value driven on the UI thread. Sawtooth: ramps linearly
|
|
22
|
+
* (or eased) from 0 -> 1 over one `SHIMMER.*.durationMs` period, then
|
|
23
|
+
* jumps back to 0 and repeats. Sawtooth is required so that the moving
|
|
24
|
+
* shimmer band sweeps from end to end at a constant heading and resets
|
|
25
|
+
* cleanly; a ping-pong clock would produce a discontinuity in
|
|
26
|
+
* `(clock + phaseOffset) % 1` at the apex, which translates to a visible
|
|
27
|
+
* jump in the band's position when stagger offsets are non-zero.
|
|
28
|
+
*/
|
|
29
|
+
clock: SharedValue<number>;
|
|
30
|
+
/**
|
|
31
|
+
* Atomically registers a child skeleton and returns its registration index.
|
|
32
|
+
* The order is stable for the life of the parent group; the counter is held
|
|
33
|
+
* in a ref so React's render lifecycle doesn't reshuffle it.
|
|
34
|
+
*/
|
|
35
|
+
nextIndex(): number;
|
|
36
|
+
}
|
|
37
|
+
export interface SkeletonGroupProps {
|
|
38
|
+
/** When true, descendant skeleton-aware primitives render placeholders. */
|
|
39
|
+
loading: boolean;
|
|
40
|
+
/**
|
|
41
|
+
* Override the auto-detected reduced-motion preference. Pass `undefined` to
|
|
42
|
+
* use the system value (default). Pass `true`/`false` to force.
|
|
43
|
+
*/
|
|
44
|
+
reducedMotion?: boolean;
|
|
45
|
+
children?: ReactNode;
|
|
46
|
+
}
|
|
47
|
+
/**
|
|
48
|
+
* Provider that flips an entire subtree into "loading" mode and supplies the
|
|
49
|
+
* shared shimmer clock + stagger index source to every descendant skeleton.
|
|
50
|
+
*
|
|
51
|
+
* Usage:
|
|
52
|
+
* ```tsx
|
|
53
|
+
* <SkeletonGroup loading={!data}>
|
|
54
|
+
* <Card>...JFS primitives auto-skeletonize...</Card>
|
|
55
|
+
* </SkeletonGroup>
|
|
56
|
+
* ```
|
|
57
|
+
*
|
|
58
|
+
* Nesting is supported — an inner `<SkeletonGroup>` fully overrides the
|
|
59
|
+
* outer one for its subtree (its own clock, its own index counter).
|
|
60
|
+
*/
|
|
61
|
+
export declare function SkeletonGroup({ loading, reducedMotion: reducedMotionOverride, children, }: SkeletonGroupProps): import("react/jsx-runtime").JSX.Element;
|
|
62
|
+
/**
|
|
63
|
+
* Internal hook used by skeleton-aware primitives (and by `<Skeleton>`
|
|
64
|
+
* itself) to read the surrounding context.
|
|
65
|
+
*
|
|
66
|
+
* Always returns a non-null value: when called outside any provider, the
|
|
67
|
+
* returned object has `active: false` so the consumer falls through to its
|
|
68
|
+
* normal render path. The fallback clock is a no-op shared value so any
|
|
69
|
+
* direct `<Skeleton>` usage outside a group still has something safe to read.
|
|
70
|
+
*/
|
|
71
|
+
export declare function useSkeleton(): SkeletonContextValue;
|
|
72
|
+
/**
|
|
73
|
+
* Convenience wrapper around `useSkeleton().nextIndex()` that pins the
|
|
74
|
+
* returned value across re-renders. Each `<Skeleton>` calls this once on
|
|
75
|
+
* mount; subsequent renders re-use the same index from the closure.
|
|
76
|
+
*/
|
|
77
|
+
export declare function useStaggerIndex(): number;
|
|
78
|
+
//# sourceMappingURL=SkeletonGroup.d.ts.map
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
export { default as Skeleton, type SkeletonProps } from './Skeleton';
|
|
2
|
+
export { SkeletonGroup, useSkeleton, useStaggerIndex, type SkeletonGroupProps, type SkeletonContextValue, } from './SkeletonGroup';
|
|
3
|
+
export { useReducedMotion } from './useReducedMotion';
|
|
4
|
+
export { SHIMMER, SKELETON_TOKEN, SKELETON_FALLBACK, type SkeletonKind } from './shimmer-tokens';
|
|
5
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Single source of truth for the skeleton shimmer behaviour spec.
|
|
3
|
+
*
|
|
4
|
+
* The two modes mirror the documented design behaviour:
|
|
5
|
+
*
|
|
6
|
+
* Normal:
|
|
7
|
+
* - 1.5s linear sawtooth cycle (band sweeps end-to-end then resets)
|
|
8
|
+
* - 135° gradient (top-left -> bottom-right), fixed angle on any aspect
|
|
9
|
+
* ratio via SVG userSpaceOnUse coordinates
|
|
10
|
+
* - Band alpha animates 33% -> 100% -> 33% across the band core;
|
|
11
|
+
* transparent fades at the gradient edges hide the sawtooth reset
|
|
12
|
+
* - 50–100ms per-item stagger
|
|
13
|
+
*
|
|
14
|
+
* Reduced motion (system-level OS toggle):
|
|
15
|
+
* - 3.0s ease-in-out cycle
|
|
16
|
+
* - No translation — solid white overlay opacity pulses 33% -> 100% in
|
|
17
|
+
* place (`opacityRange` below is consumed in this path)
|
|
18
|
+
* - No gradient
|
|
19
|
+
* - No stagger
|
|
20
|
+
*
|
|
21
|
+
* Centralising the spec here keeps `Skeleton.tsx` purely presentational and
|
|
22
|
+
* lets us tune the behaviour in one place if design ever updates it.
|
|
23
|
+
*/
|
|
24
|
+
export type SkeletonKind = 'text' | 'image' | 'badge' | 'other';
|
|
25
|
+
export interface ShimmerModeSpec {
|
|
26
|
+
durationMs: number;
|
|
27
|
+
/** Per-item delay range. Min/max in milliseconds. */
|
|
28
|
+
staggerMsRange: readonly [number, number];
|
|
29
|
+
gradient: boolean;
|
|
30
|
+
/** Opacity range applied to the moving "blob" overlay. */
|
|
31
|
+
opacityRange: readonly [number, number];
|
|
32
|
+
}
|
|
33
|
+
export declare const SHIMMER: {
|
|
34
|
+
readonly normal: {
|
|
35
|
+
durationMs: number;
|
|
36
|
+
staggerMsRange: readonly [50, 100];
|
|
37
|
+
gradient: true;
|
|
38
|
+
opacityRange: readonly [0.33, 1];
|
|
39
|
+
};
|
|
40
|
+
readonly reduced: {
|
|
41
|
+
durationMs: number;
|
|
42
|
+
staggerMsRange: readonly [0, 0];
|
|
43
|
+
gradient: false;
|
|
44
|
+
opacityRange: readonly [0.33, 1];
|
|
45
|
+
};
|
|
46
|
+
/**
|
|
47
|
+
* Gradient angle in degrees, measured the CSS way: 0deg points "up", 90deg
|
|
48
|
+
* "right", 135deg therefore points down-right (top-left corner to
|
|
49
|
+
* bottom-right corner).
|
|
50
|
+
*/
|
|
51
|
+
readonly gradientAngleDeg: 135;
|
|
52
|
+
/**
|
|
53
|
+
* Hard cap on the cumulative stagger delay so very long lists don't drift
|
|
54
|
+
* out forever; the wave wraps after this many ms.
|
|
55
|
+
*/
|
|
56
|
+
readonly maxStaggerMs: 600;
|
|
57
|
+
};
|
|
58
|
+
/**
|
|
59
|
+
* Token names — referenced via `getVariableByName(...)` so the existing
|
|
60
|
+
* design-token resolver does its job (caching, mode resolution, etc.).
|
|
61
|
+
*
|
|
62
|
+
* The four tokens already live in the Figma export at
|
|
63
|
+
* `src/design-tokens/Coin Variables-variables-full.json`:
|
|
64
|
+
*
|
|
65
|
+
* - `bg/defaultSkeleton` -> base color for every skeleton block
|
|
66
|
+
* - `cornerRadius/defaultSkeleton` -> text & "other" (pill: 9999)
|
|
67
|
+
* - `cornerRadius/imageSkeleton` -> images (10)
|
|
68
|
+
* - `cornerRadius/badgeSkeleton` -> badges (4)
|
|
69
|
+
*/
|
|
70
|
+
export declare const SKELETON_TOKEN: {
|
|
71
|
+
readonly background: "bg/defaultSkeleton";
|
|
72
|
+
readonly radius: {
|
|
73
|
+
text: string;
|
|
74
|
+
image: string;
|
|
75
|
+
badge: string;
|
|
76
|
+
other: string;
|
|
77
|
+
};
|
|
78
|
+
};
|
|
79
|
+
/**
|
|
80
|
+
* Fallback constants used when the token resolver is unavailable (tests,
|
|
81
|
+
* SSR, etc.). Match the current Figma values.
|
|
82
|
+
*/
|
|
83
|
+
export declare const SKELETON_FALLBACK: {
|
|
84
|
+
readonly backgroundColor: "rgb(245, 245, 246)";
|
|
85
|
+
readonly radius: {
|
|
86
|
+
text: number;
|
|
87
|
+
image: number;
|
|
88
|
+
badge: number;
|
|
89
|
+
other: number;
|
|
90
|
+
};
|
|
91
|
+
};
|
|
92
|
+
/**
|
|
93
|
+
* Compute a stable per-item delay from a 0-based registration index.
|
|
94
|
+
*
|
|
95
|
+
* We pick the midpoint of the documented range (75ms) so the cascade is
|
|
96
|
+
* deterministic for snapshot tests and visually identical between renders.
|
|
97
|
+
* The total delay is then wrapped at `maxStaggerMs` so deep lists don't
|
|
98
|
+
* drift past the cap.
|
|
99
|
+
*/
|
|
100
|
+
export declare function staggerDelayMs(index: number, mode: ShimmerModeSpec): number;
|
|
101
|
+
/** One stop on the moving shimmer gradient (offset 0–1 along the 135° axis). */
|
|
102
|
+
export interface ShimmerGradientStop {
|
|
103
|
+
offset: number;
|
|
104
|
+
opacity: number;
|
|
105
|
+
}
|
|
106
|
+
/**
|
|
107
|
+
* Gradient stops for the normal-mode moving band. The peak sits at 0.5; fully
|
|
108
|
+
* transparent tails at 0 and 1. The 0.30 / 0.70 stops mark where the band
|
|
109
|
+
* reaches the documented 33 % alpha.
|
|
110
|
+
*/
|
|
111
|
+
export declare const SHIMMER_GRADIENT_STOPS: readonly ShimmerGradientStop[];
|
|
112
|
+
/** Offset (0–1) of the brightest point on the gradient line. */
|
|
113
|
+
export declare function gradientPeakOffset(stops?: readonly ShimmerGradientStop[]): number;
|
|
114
|
+
/**
|
|
115
|
+
* How far the gradient extends from the peak to a fully transparent stop,
|
|
116
|
+
* expressed as a fraction of the gradient line (0–1). With the default stops
|
|
117
|
+
* this is 0.5 (peak at 0.5, transparent at 0 and 1).
|
|
118
|
+
*
|
|
119
|
+
* This value drives the overshoot: the band must travel this fraction of a
|
|
120
|
+
* full corner-to-corner sweep *beyond* each corner so the soft transparent
|
|
121
|
+
* tails fully clear the box before the sawtooth reset.
|
|
122
|
+
*/
|
|
123
|
+
export declare function gradientTransparentExtent(stops?: readonly ShimmerGradientStop[]): number;
|
|
124
|
+
export interface ShimmerMotionGeometry {
|
|
125
|
+
/** Square overlay side length (gradient is painted on this). */
|
|
126
|
+
overlaySize: number;
|
|
127
|
+
/** Padding to centre the overlay on the box. */
|
|
128
|
+
padX: number;
|
|
129
|
+
padY: number;
|
|
130
|
+
/** Translation (k, k) when the band is fully off-screen before entry. */
|
|
131
|
+
kStart: number;
|
|
132
|
+
/** Translation (k, k) when the band is fully off-screen after exit. */
|
|
133
|
+
kEnd: number;
|
|
134
|
+
/**
|
|
135
|
+
* Normalised overshoot on each side of the corner-to-corner sweep. A value
|
|
136
|
+
* of 0.5 means the travel extends 50 % past each corner; at reset the
|
|
137
|
+
* clock jumps from `1 + overshoot` to `-overshoot` while the box still
|
|
138
|
+
* shows only the base skeleton colour.
|
|
139
|
+
*/
|
|
140
|
+
overshootFraction: number;
|
|
141
|
+
/** k distance from peak-at-TL to peak-at-BR. */
|
|
142
|
+
cornerTravelK: number;
|
|
143
|
+
/** k distance from peak to fully transparent tail on the gradient. */
|
|
144
|
+
fadeBeyondPeakK: number;
|
|
145
|
+
}
|
|
146
|
+
/**
|
|
147
|
+
* Derive the moving-shimmer geometry from box size, overlay size, and the
|
|
148
|
+
* gradient stop layout.
|
|
149
|
+
*
|
|
150
|
+
* Coordinate model (135° / down-right):
|
|
151
|
+
* - Peak stripe world diagonal sum: (W + H) / 2 + 2k
|
|
152
|
+
* - Gradient offset 0 → 1 spans 2 × overlaySize in diagonal-sum units
|
|
153
|
+
* - Transparent tail beyond peak: fadeExtent × 2 × overlaySize / 2
|
|
154
|
+
* = fadeExtent × overlaySize in k units
|
|
155
|
+
*
|
|
156
|
+
* The sawtooth clock maps linearly kStart → kEnd so t = 0 and t = 1 both
|
|
157
|
+
* land with the entire gradient outside the box — no jitter on reset.
|
|
158
|
+
*/
|
|
159
|
+
export declare function computeShimmerMotion(width: number, height: number, overlaySize: number, stops?: readonly ShimmerGradientStop[]): ShimmerMotionGeometry | null;
|
|
160
|
+
//# sourceMappingURL=shimmer-tokens.d.ts.map
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Cross-platform "prefers reduced motion" hook.
|
|
3
|
+
*
|
|
4
|
+
* - Native: reads `AccessibilityInfo.isReduceMotionEnabled()` and subscribes
|
|
5
|
+
* to `reduceMotionChanged` events so the value stays live as the user
|
|
6
|
+
* toggles the OS setting.
|
|
7
|
+
* - Web: uses `window.matchMedia('(prefers-reduced-motion: reduce)')`,
|
|
8
|
+
* subscribing to its `change` event.
|
|
9
|
+
* - Anywhere either API is missing: returns `false` (no reduction).
|
|
10
|
+
*
|
|
11
|
+
* The hook never throws — every native API access is defensively guarded so
|
|
12
|
+
* the skeleton system stays safe in tests, SSR, and constrained sandboxes.
|
|
13
|
+
*/
|
|
14
|
+
export declare function useReducedMotion(): boolean;
|
|
15
|
+
//# sourceMappingURL=useReducedMotion.d.ts.map
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "jfs-components",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.78",
|
|
4
4
|
"description": "React Native Jio Finance Components Library",
|
|
5
5
|
"author": "sunshuaiqi@gmail.com",
|
|
6
6
|
"license": "MIT",
|
|
@@ -94,9 +94,19 @@
|
|
|
94
94
|
},
|
|
95
95
|
"peerDependencies": {
|
|
96
96
|
"@react-native-community/blur": ">=4.4.0",
|
|
97
|
+
"lottie-react": ">=2.4.0",
|
|
98
|
+
"lottie-react-native": ">=7.0.0",
|
|
97
99
|
"react": "*",
|
|
98
100
|
"react-native": "*"
|
|
99
101
|
},
|
|
102
|
+
"peerDependenciesMeta": {
|
|
103
|
+
"lottie-react": {
|
|
104
|
+
"optional": true
|
|
105
|
+
},
|
|
106
|
+
"lottie-react-native": {
|
|
107
|
+
"optional": true
|
|
108
|
+
}
|
|
109
|
+
},
|
|
100
110
|
"devDependencies": {
|
|
101
111
|
"@babel/core": "^7.28.5",
|
|
102
112
|
"@babel/parser": "^7.28.5",
|