jfs-components 0.0.3 → 0.0.5
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/lib/commonjs/Containers.js +16 -7
- package/lib/commonjs/Containers.js.map +1 -1
- package/lib/commonjs/components/Accordion/Accordion.js +217 -0
- package/lib/commonjs/components/Accordion/Accordion.js.map +1 -0
- package/lib/commonjs/components/Accordion/Accordion.mdx +123 -0
- package/lib/commonjs/components/ActionFooter/ActionFooter.mdx +1 -0
- package/lib/commonjs/components/ActionTile/ActionTile.js +93 -0
- package/lib/commonjs/components/ActionTile/ActionTile.js.map +1 -0
- package/lib/commonjs/components/ActionTile/ActionTile.mdx +54 -0
- package/lib/commonjs/components/ActionTile/index.js +14 -0
- package/lib/commonjs/components/ActionTile/index.js.map +1 -0
- package/lib/commonjs/components/CtaCard/CtaCard.js +122 -0
- package/lib/commonjs/components/CtaCard/CtaCard.js.map +1 -0
- package/lib/commonjs/components/CtaCard/CtaCard.mdx +65 -0
- package/lib/commonjs/components/CtaCard/index.js +14 -0
- package/lib/commonjs/components/CtaCard/index.js.map +1 -0
- package/lib/commonjs/components/Introduction.mdx +0 -1
- package/lib/commonjs/components/ThreadHero/ThreadHero.js +114 -0
- package/lib/commonjs/components/ThreadHero/ThreadHero.js.map +1 -0
- package/lib/commonjs/components/ThreadHero/ThreadHero.mdx +69 -0
- package/lib/commonjs/components/TransactionBubble/TransactionBubble.js +101 -0
- package/lib/commonjs/components/TransactionBubble/TransactionBubble.js.map +1 -0
- package/lib/commonjs/components/TransactionBubble/TransactionBubble.mdx +40 -0
- package/lib/commonjs/components/TransactionDetails/TransactionDetails.js +177 -0
- package/lib/commonjs/components/TransactionDetails/TransactionDetails.js.map +1 -0
- package/lib/commonjs/components/TransactionDetails/TransactionDetails.mdx +98 -0
- package/lib/commonjs/components/TransactionStatus/TransactionStatus.js +82 -0
- package/lib/commonjs/components/TransactionStatus/TransactionStatus.js.map +1 -0
- package/lib/commonjs/components/TransactionStatus/TransactionStatus.mdx +41 -0
- package/lib/commonjs/components/index.js +35 -0
- package/lib/commonjs/components/index.js.map +1 -1
- package/lib/commonjs/design-tokens/JFSThemeProvider.js +64 -0
- package/lib/commonjs/design-tokens/JFSThemeProvider.js.map +1 -0
- package/lib/commonjs/design-tokens/figma-variables-resolver.js +3 -9
- package/lib/commonjs/design-tokens/index.js +11 -0
- package/lib/commonjs/design-tokens/index.js.map +1 -1
- package/lib/commonjs/icons/registry.js +1 -1
- package/lib/module/Containers.js +15 -7
- package/lib/module/Containers.js.map +1 -1
- package/lib/module/components/Accordion/Accordion.js +212 -0
- package/lib/module/components/Accordion/Accordion.js.map +1 -0
- package/lib/module/components/Accordion/Accordion.mdx +123 -0
- package/lib/module/components/ActionFooter/ActionFooter.mdx +1 -0
- package/lib/module/components/ActionTile/ActionTile.js +88 -0
- package/lib/module/components/ActionTile/ActionTile.js.map +1 -0
- package/lib/module/components/ActionTile/ActionTile.mdx +54 -0
- package/lib/module/components/ActionTile/index.js +4 -0
- package/lib/module/components/ActionTile/index.js.map +1 -0
- package/lib/module/components/CtaCard/CtaCard.js +117 -0
- package/lib/module/components/CtaCard/CtaCard.js.map +1 -0
- package/lib/module/components/CtaCard/CtaCard.mdx +65 -0
- package/lib/module/components/CtaCard/index.js +4 -0
- package/lib/module/components/CtaCard/index.js.map +1 -0
- package/lib/module/components/Introduction.mdx +0 -1
- package/lib/module/components/ThreadHero/ThreadHero.js +109 -0
- package/lib/module/components/ThreadHero/ThreadHero.js.map +1 -0
- package/lib/module/components/ThreadHero/ThreadHero.mdx +69 -0
- package/lib/module/components/TransactionBubble/TransactionBubble.js +96 -0
- package/lib/module/components/TransactionBubble/TransactionBubble.js.map +1 -0
- package/lib/module/components/TransactionBubble/TransactionBubble.mdx +40 -0
- package/lib/module/components/TransactionDetails/TransactionDetails.js +174 -0
- package/lib/module/components/TransactionDetails/TransactionDetails.js.map +1 -0
- package/lib/module/components/TransactionDetails/TransactionDetails.mdx +98 -0
- package/lib/module/components/TransactionStatus/TransactionStatus.js +77 -0
- package/lib/module/components/TransactionStatus/TransactionStatus.js.map +1 -0
- package/lib/module/components/TransactionStatus/TransactionStatus.mdx +41 -0
- package/lib/module/components/index.js +5 -0
- package/lib/module/components/index.js.map +1 -1
- package/lib/module/design-tokens/JFSThemeProvider.js +57 -0
- package/lib/module/design-tokens/JFSThemeProvider.js.map +1 -0
- package/lib/module/design-tokens/index.js +1 -0
- package/lib/module/design-tokens/index.js.map +1 -1
- package/lib/module/icons/registry.js +1 -1
- package/lib/typescript/Containers.d.ts +2 -1
- package/lib/typescript/Containers.d.ts.map +1 -1
- package/lib/typescript/components/Accordion/Accordion.d.ts +58 -0
- package/lib/typescript/components/Accordion/Accordion.d.ts.map +1 -0
- package/lib/typescript/components/ActionTile/ActionTile.d.ts +26 -0
- package/lib/typescript/components/ActionTile/ActionTile.d.ts.map +1 -0
- package/lib/typescript/components/ActionTile/index.d.ts +2 -0
- package/lib/typescript/components/ActionTile/index.d.ts.map +1 -0
- package/lib/typescript/components/CtaCard/CtaCard.d.ts +61 -0
- package/lib/typescript/components/CtaCard/CtaCard.d.ts.map +1 -0
- package/lib/typescript/components/CtaCard/index.d.ts +2 -0
- package/lib/typescript/components/CtaCard/index.d.ts.map +1 -0
- package/lib/typescript/components/ThreadHero/ThreadHero.d.ts +21 -0
- package/lib/typescript/components/ThreadHero/ThreadHero.d.ts.map +1 -0
- package/lib/typescript/components/TransactionBubble/TransactionBubble.d.ts +24 -0
- package/lib/typescript/components/TransactionBubble/TransactionBubble.d.ts.map +1 -0
- package/lib/typescript/components/TransactionDetails/TransactionDetails.d.ts +57 -0
- package/lib/typescript/components/TransactionDetails/TransactionDetails.d.ts.map +1 -0
- package/lib/typescript/components/TransactionStatus/TransactionStatus.d.ts +16 -0
- package/lib/typescript/components/TransactionStatus/TransactionStatus.d.ts.map +1 -0
- package/lib/typescript/components/index.d.ts +5 -0
- package/lib/typescript/components/index.d.ts.map +1 -1
- package/lib/typescript/design-tokens/JFSThemeProvider.d.ts +44 -0
- package/lib/typescript/design-tokens/JFSThemeProvider.d.ts.map +1 -0
- package/lib/typescript/design-tokens/index.d.ts +1 -0
- package/lib/typescript/design-tokens/index.d.ts.map +1 -1
- package/lib/typescript/icons/registry.d.ts +1 -1
- package/package.json +3 -4
- package/src/Containers.tsx +15 -0
- package/src/components/.token-metadata.json +161 -0
- package/src/components/Accordion/Accordion.mdx +123 -0
- package/src/components/Accordion/Accordion.tsx +279 -0
- package/src/components/ActionFooter/ActionFooter.mdx +1 -0
- package/src/components/ActionTile/ActionTile.mdx +54 -0
- package/src/components/ActionTile/ActionTile.tsx +100 -0
- package/src/components/ActionTile/index.ts +1 -0
- package/src/components/CtaCard/CtaCard.mdx +65 -0
- package/src/components/CtaCard/CtaCard.tsx +185 -0
- package/src/components/CtaCard/index.ts +1 -0
- package/src/components/Divider/Divider.tsx +1 -0
- package/src/components/Introduction.mdx +0 -1
- package/src/components/NavArrow/NavArrow.tsx +1 -0
- package/src/components/ThreadHero/ThreadHero.mdx +69 -0
- package/src/components/ThreadHero/ThreadHero.tsx +124 -0
- package/src/components/TransactionBubble/TransactionBubble.mdx +40 -0
- package/src/components/TransactionBubble/TransactionBubble.tsx +113 -0
- package/src/components/TransactionDetails/TransactionDetails.mdx +98 -0
- package/src/components/TransactionDetails/TransactionDetails.tsx +236 -0
- package/src/components/TransactionStatus/TransactionStatus.mdx +41 -0
- package/src/components/TransactionStatus/TransactionStatus.tsx +94 -0
- package/src/components/index.ts +5 -0
- package/src/design-tokens/JFSThemeProvider.tsx +79 -0
- package/src/design-tokens/index.ts +1 -0
- package/src/icons/registry.ts +1 -1
- package/src/Containers.ts +0 -8
|
@@ -1,2 +1,3 @@
|
|
|
1
|
-
|
|
1
|
+
import { type ViewProps } from 'react-native';
|
|
2
|
+
export declare const storyContainer: (props: ViewProps) => import("react/jsx-runtime").JSX.Element;
|
|
2
3
|
//# sourceMappingURL=Containers.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Containers.d.ts","sourceRoot":"","sources":["../../src/Containers.
|
|
1
|
+
{"version":3,"file":"Containers.d.ts","sourceRoot":"","sources":["../../src/Containers.tsx"],"names":[],"mappings":"AACA,OAAO,EAAoB,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAEhE,eAAO,MAAM,cAAc,GAAI,OAAO,SAAS,4CAE9C,CAAC"}
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { View, type StyleProp, type ViewStyle, type AccessibilityState } from 'react-native';
|
|
3
|
+
import { type WebAccessibilityProps } from '../../utils/web-platform-utils';
|
|
4
|
+
export type AccordionProps = {
|
|
5
|
+
/** The accordion header title */
|
|
6
|
+
title?: string;
|
|
7
|
+
/** Initial expanded state. Defaults to false (collapsed) */
|
|
8
|
+
defaultExpanded?: boolean;
|
|
9
|
+
/** Controlled expanded state. When provided, the component becomes controlled */
|
|
10
|
+
expanded?: boolean;
|
|
11
|
+
/** Callback fired when the accordion's expanded state changes */
|
|
12
|
+
onExpandedChange?: (expanded: boolean) => void;
|
|
13
|
+
/** Whether the accordion is disabled */
|
|
14
|
+
disabled?: boolean;
|
|
15
|
+
/** Content to display when the accordion is expanded (Figma Slot: 'content') */
|
|
16
|
+
children?: React.ReactNode;
|
|
17
|
+
/** Modes object passed to getVariableByName for all design tokens */
|
|
18
|
+
modes?: Record<string, any>;
|
|
19
|
+
/** Optional container style overrides */
|
|
20
|
+
style?: StyleProp<ViewStyle>;
|
|
21
|
+
/** Accessibility label for screen readers. If not provided, uses title */
|
|
22
|
+
accessibilityLabel?: string;
|
|
23
|
+
/** Additional accessibility hint for screen readers */
|
|
24
|
+
accessibilityHint?: string;
|
|
25
|
+
/** Additional accessibility state information */
|
|
26
|
+
accessibilityState?: AccessibilityState;
|
|
27
|
+
/** Web-specific accessibility props (only used on web platform) */
|
|
28
|
+
webAccessibilityProps?: WebAccessibilityProps;
|
|
29
|
+
} & React.ComponentProps<typeof View>;
|
|
30
|
+
/**
|
|
31
|
+
* Accordion component that mirrors the Figma "Accordion" component.
|
|
32
|
+
*
|
|
33
|
+
* This component supports:
|
|
34
|
+
* - **Expandable/collapsible content** with smooth animation
|
|
35
|
+
* - **States**: Idle, Hover, Open, Disabled
|
|
36
|
+
* - **Slot** for custom content
|
|
37
|
+
* - **Design-token driven styling** via `getVariableByName` and `modes`
|
|
38
|
+
*
|
|
39
|
+
* Wherever the Figma layer name contains "Slot", this component exposes a
|
|
40
|
+
* dedicated React "slot" prop:
|
|
41
|
+
* - Slot "content" → `children`
|
|
42
|
+
*
|
|
43
|
+
* @component
|
|
44
|
+
* @param {Object} props
|
|
45
|
+
* @param {string} [props.title='Accordion title'] - The accordion header title
|
|
46
|
+
* @param {boolean} [props.defaultExpanded=false] - Initial expanded state
|
|
47
|
+
* @param {boolean} [props.expanded] - Controlled expanded state
|
|
48
|
+
* @param {Function} [props.onExpandedChange] - Callback fired when expanded state changes
|
|
49
|
+
* @param {boolean} [props.disabled=false] - Whether the accordion is disabled
|
|
50
|
+
* @param {React.ReactNode} [props.children] - Content to display when expanded
|
|
51
|
+
* @param {Object} [props.modes={}] - Modes object passed to `getVariableByName` for all design tokens
|
|
52
|
+
* @param {Object} [props.style] - Optional container style overrides
|
|
53
|
+
* @param {string} [props.accessibilityLabel] - Accessibility label for the accordion. If not provided, uses title
|
|
54
|
+
* @param {string} [props.accessibilityHint] - Additional accessibility hint for screen readers
|
|
55
|
+
*/
|
|
56
|
+
declare function Accordion({ title, defaultExpanded, expanded: controlledExpanded, onExpandedChange, disabled, children, modes, style, accessibilityLabel, accessibilityHint, accessibilityState, webAccessibilityProps, ...rest }: AccordionProps): import("react/jsx-runtime").JSX.Element;
|
|
57
|
+
export default Accordion;
|
|
58
|
+
//# sourceMappingURL=Accordion.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"Accordion.d.ts","sourceRoot":"","sources":["../../../../src/components/Accordion/Accordion.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L,kBAAkB,EAClB,iBAAiB,EACjB,kBAAkB,EAClB,qBAAqB,EACrB,GAAG,IAAI,EACR,EAAE,cAAc,2CA8IhB;AAED,eAAe,SAAS,CAAA"}
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { type ViewStyle } from 'react-native';
|
|
3
|
+
export type ActionTileProps = {
|
|
4
|
+
/** Label text, e.g. "Cards" */
|
|
5
|
+
label?: string;
|
|
6
|
+
/**
|
|
7
|
+
* Icon component slot.
|
|
8
|
+
* Expects an IconCapsule or compatible component.
|
|
9
|
+
* Modes will be passed to this slot if it's a valid React element.
|
|
10
|
+
*/
|
|
11
|
+
icon?: React.ReactNode;
|
|
12
|
+
/** Modes for design token resolution */
|
|
13
|
+
modes?: Record<string, any>;
|
|
14
|
+
/** Optional container style */
|
|
15
|
+
style?: ViewStyle;
|
|
16
|
+
/** Callback when tile is pressed */
|
|
17
|
+
onPress?: () => void;
|
|
18
|
+
};
|
|
19
|
+
/**
|
|
20
|
+
* ActionTile component from Figma design.
|
|
21
|
+
* Displays an icon (defaulting to IconCapsule) and a label.
|
|
22
|
+
*
|
|
23
|
+
* @component
|
|
24
|
+
*/
|
|
25
|
+
export default function ActionTile({ label, icon, modes, style, onPress, }: ActionTileProps): import("react/jsx-runtime").JSX.Element;
|
|
26
|
+
//# sourceMappingURL=ActionTile.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ActionTile.d.ts","sourceRoot":"","sources":["../../../../src/components/ActionTile/ActionTile.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAc,KAAK,SAAS,EAAoC,MAAM,cAAc,CAAA;AAI3F,MAAM,MAAM,eAAe,GAAG;IAC1B,+BAA+B;IAC/B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd;;;;OAIG;IACH,IAAI,CAAC,EAAE,KAAK,CAAC,SAAS,CAAA;IACtB,wCAAwC;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC3B,+BAA+B;IAC/B,KAAK,CAAC,EAAE,SAAS,CAAA;IACjB,oCAAoC;IACpC,OAAO,CAAC,EAAE,MAAM,IAAI,CAAA;CACvB,CAAA;AAED;;;;;GAKG;AACH,MAAM,CAAC,OAAO,UAAU,UAAU,CAAC,EAC/B,KAAe,EACf,IAAI,EACJ,KAAU,EACV,KAAK,EACL,OAAO,GACV,EAAE,eAAe,2CAiEjB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/ActionTile/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,cAAc,CAAA"}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { type StyleProp, type ViewStyle } from 'react-native';
|
|
3
|
+
type CtaCardProps = {
|
|
4
|
+
/**
|
|
5
|
+
* Title text for the card
|
|
6
|
+
*/
|
|
7
|
+
title?: string;
|
|
8
|
+
/**
|
|
9
|
+
* Body text for the card
|
|
10
|
+
*/
|
|
11
|
+
body?: string;
|
|
12
|
+
/**
|
|
13
|
+
* Name of the icon to display in the IconCapsule (if iconSlot is not provided)
|
|
14
|
+
*/
|
|
15
|
+
iconName?: string;
|
|
16
|
+
/**
|
|
17
|
+
* Label for the button (if buttonSlot is not provided)
|
|
18
|
+
*/
|
|
19
|
+
buttonLabel?: string;
|
|
20
|
+
/**
|
|
21
|
+
* Callback for the button press (if buttonSlot is not provided)
|
|
22
|
+
*/
|
|
23
|
+
onPressButton?: () => void;
|
|
24
|
+
/**
|
|
25
|
+
* Modes object for design token resolution
|
|
26
|
+
*/
|
|
27
|
+
modes?: Record<string, any>;
|
|
28
|
+
/**
|
|
29
|
+
* Optional custom slot for the icon area.
|
|
30
|
+
* If provided, overrides the default IconCapsule.
|
|
31
|
+
* `modes` will be automatically passed to this slot if it's a valid React element.
|
|
32
|
+
*/
|
|
33
|
+
iconSlot?: React.ReactNode;
|
|
34
|
+
/**
|
|
35
|
+
* Optional custom slot for the title area.
|
|
36
|
+
* If provided, overrides the default title Text.
|
|
37
|
+
* `modes` will be automatically passed to this slot if it's a valid React element.
|
|
38
|
+
*/
|
|
39
|
+
titleSlot?: React.ReactNode;
|
|
40
|
+
/**
|
|
41
|
+
* Optional custom slot for the body area.
|
|
42
|
+
* If provided, overrides the default body Text.
|
|
43
|
+
* `modes` will be automatically passed to this slot if it's a valid React element.
|
|
44
|
+
*/
|
|
45
|
+
bodySlot?: React.ReactNode;
|
|
46
|
+
/**
|
|
47
|
+
* Optional custom slot for the button area.
|
|
48
|
+
* If provided, overrides the default Button.
|
|
49
|
+
* `modes` will be automatically passed to this slot if it's a valid React element.
|
|
50
|
+
*/
|
|
51
|
+
buttonSlot?: React.ReactNode;
|
|
52
|
+
style?: StyleProp<ViewStyle>;
|
|
53
|
+
};
|
|
54
|
+
/**
|
|
55
|
+
* CtaCard component that maps directly to the Figma design using design tokens.
|
|
56
|
+
*
|
|
57
|
+
* @component
|
|
58
|
+
*/
|
|
59
|
+
declare function CtaCard({ title, body, iconName, buttonLabel, onPressButton, modes, iconSlot, titleSlot, bodySlot, buttonSlot, style, }: CtaCardProps): import("react/jsx-runtime").JSX.Element;
|
|
60
|
+
export default CtaCard;
|
|
61
|
+
//# sourceMappingURL=CtaCard.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"CtaCard.d.ts","sourceRoot":"","sources":["../../../../src/components/CtaCard/CtaCard.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAC;AAC1B,OAAO,EAAc,KAAK,SAAS,EAAE,KAAK,SAAS,EAAkB,MAAM,cAAc,CAAC;AAK1F,KAAK,YAAY,GAAG;IAChB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;;OAEG;IACH,aAAa,CAAC,EAAE,MAAM,IAAI,CAAC;IAC3B;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC5B;;;;OAIG;IACH,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B;;;;OAIG;IACH,SAAS,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC5B;;;;OAIG;IACH,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAC3B;;;;OAIG;IACH,UAAU,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;IAE7B,KAAK,CAAC,EAAE,SAAS,CAAC,SAAS,CAAC,CAAC;CAChC,CAAC;AAEF;;;;GAIG;AACH,iBAAS,OAAO,CAAC,EACb,KAAiC,EACjC,IAAyC,EACzC,QAA0B,EAC1B,WAA2B,EAC3B,aAAa,EACb,KAAU,EACV,QAAQ,EACR,SAAS,EACT,QAAQ,EACR,UAAU,EACV,KAAK,GACR,EAAE,YAAY,2CA0Gd;AAED,eAAe,OAAO,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/components/CtaCard/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,WAAW,CAAC"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
import { type ReactNode } from 'react';
|
|
2
|
+
import { type ViewStyle } from 'react-native';
|
|
3
|
+
export type ThreadHeroProps = {
|
|
4
|
+
/** Title text, e.g. "Subhash Rajan" */
|
|
5
|
+
title?: string;
|
|
6
|
+
/** Subtitle text, e.g. "Banking name: SHIVASHANKAR RAJAN" */
|
|
7
|
+
subtitle?: string;
|
|
8
|
+
/** Optional caption text below the details, e.g. "+91 00000 00000" */
|
|
9
|
+
caption?: string;
|
|
10
|
+
/** Slot for Avatar component */
|
|
11
|
+
renderAvatar?: ReactNode;
|
|
12
|
+
/** Modes for design token resolution */
|
|
13
|
+
modes?: Record<string, any>;
|
|
14
|
+
/** Optional container style */
|
|
15
|
+
style?: ViewStyle;
|
|
16
|
+
};
|
|
17
|
+
/**
|
|
18
|
+
* ThreadHero component displaying a central identity with avatar, title, subtitle, and caption.
|
|
19
|
+
*/
|
|
20
|
+
export default function ThreadHero({ title, subtitle, caption, renderAvatar, modes, style, }: ThreadHeroProps): import("react/jsx-runtime").JSX.Element;
|
|
21
|
+
//# sourceMappingURL=ThreadHero.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ThreadHero.d.ts","sourceRoot":"","sources":["../../../../src/components/ThreadHero/ThreadHero.tsx"],"names":[],"mappings":"AAAA,OAAc,EAAgC,KAAK,SAAS,EAAE,MAAM,OAAO,CAAA;AAC3E,OAAO,EAAc,KAAK,SAAS,EAAkB,MAAM,cAAc,CAAA;AAGzE,MAAM,MAAM,eAAe,GAAG;IAC1B,uCAAuC;IACvC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,6DAA6D;IAC7D,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,sEAAsE;IACtE,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,gCAAgC;IAChC,YAAY,CAAC,EAAE,SAAS,CAAA;IACxB,wCAAwC;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC3B,+BAA+B;IAC/B,KAAK,CAAC,EAAE,SAAS,CAAA;CACpB,CAAA;AAED;;GAEG;AACH,MAAM,CAAC,OAAO,UAAU,UAAU,CAAC,EAC/B,KAAuB,EACvB,QAA6C,EAC7C,OAAO,EACP,YAAY,EACZ,KAAU,EACV,KAAK,GACR,EAAE,eAAe,2CA8FjB"}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { type ViewStyle } from 'react-native';
|
|
2
|
+
export type TransactionBubbleProps = {
|
|
3
|
+
/** Description text, e.g. "Payment to Uber India" */
|
|
4
|
+
description?: string;
|
|
5
|
+
/** Money amount */
|
|
6
|
+
amount?: string | number;
|
|
7
|
+
/** Currency code or symbol */
|
|
8
|
+
currency?: string;
|
|
9
|
+
/** Transaction status text, e.g. "Expired" */
|
|
10
|
+
status?: string;
|
|
11
|
+
/** Date/time string associated with status */
|
|
12
|
+
statusDate?: string;
|
|
13
|
+
/** Modes for design token resolution */
|
|
14
|
+
modes?: Record<string, any>;
|
|
15
|
+
/** Optional container style */
|
|
16
|
+
style?: ViewStyle;
|
|
17
|
+
};
|
|
18
|
+
/**
|
|
19
|
+
* TransactionBubble component displaying transaction details in a bubble card.
|
|
20
|
+
*
|
|
21
|
+
* @component
|
|
22
|
+
*/
|
|
23
|
+
export default function TransactionBubble({ description, amount, currency, status, statusDate, modes, style, }: TransactionBubbleProps): import("react/jsx-runtime").JSX.Element;
|
|
24
|
+
//# sourceMappingURL=TransactionBubble.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TransactionBubble.d.ts","sourceRoot":"","sources":["../../../../src/components/TransactionBubble/TransactionBubble.tsx"],"names":[],"mappings":"AACA,OAAO,EAAc,KAAK,SAAS,EAAkB,MAAM,cAAc,CAAA;AAMzE,MAAM,MAAM,sBAAsB,GAAG;IACjC,qDAAqD;IACrD,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB,mBAAmB;IACnB,MAAM,CAAC,EAAE,MAAM,GAAG,MAAM,CAAA;IACxB,8BAA8B;IAC9B,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,8CAA8C;IAC9C,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,8CAA8C;IAC9C,UAAU,CAAC,EAAE,MAAM,CAAA;IACnB,wCAAwC;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC3B,+BAA+B;IAC/B,KAAK,CAAC,EAAE,SAAS,CAAA;CACpB,CAAA;AAED;;;;GAIG;AACH,MAAM,CAAC,OAAO,UAAU,iBAAiB,CAAC,EACtC,WAAqC,EACrC,MAAa,EACb,QAAc,EACd,MAAkB,EAClB,UAA0B,EAC1B,KAAU,EACV,KAAK,GACR,EAAE,sBAAsB,2CA2ExB"}
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { View, type StyleProp, type ViewStyle, type TextStyle } from 'react-native';
|
|
3
|
+
export type TransactionDetailsItemProps = {
|
|
4
|
+
/** The label text displayed above the value (e.g., "UPI transaction ID") */
|
|
5
|
+
label?: string;
|
|
6
|
+
/** The value text displayed below the label (e.g., "101674916166") */
|
|
7
|
+
value?: string;
|
|
8
|
+
/** Modes object passed to `getVariableByName` for design token resolution */
|
|
9
|
+
modes?: Record<string, any>;
|
|
10
|
+
/** Optional container style overrides */
|
|
11
|
+
style?: StyleProp<ViewStyle>;
|
|
12
|
+
/** Optional label text style overrides */
|
|
13
|
+
labelStyle?: StyleProp<TextStyle>;
|
|
14
|
+
/** Optional value text style overrides */
|
|
15
|
+
valueStyle?: StyleProp<TextStyle>;
|
|
16
|
+
/** Accessibility label for screen readers */
|
|
17
|
+
accessibilityLabel?: string;
|
|
18
|
+
} & React.ComponentProps<typeof View>;
|
|
19
|
+
export type TransactionDetailsProps = {
|
|
20
|
+
/** Slot for TransactionDetails.Item children */
|
|
21
|
+
children?: React.ReactNode;
|
|
22
|
+
/** Modes object passed to `getVariableByName` for design token resolution */
|
|
23
|
+
modes?: Record<string, any>;
|
|
24
|
+
/** Optional container style overrides */
|
|
25
|
+
style?: StyleProp<ViewStyle>;
|
|
26
|
+
/** Accessibility label for screen readers */
|
|
27
|
+
accessibilityLabel?: string;
|
|
28
|
+
} & React.ComponentProps<typeof View>;
|
|
29
|
+
/**
|
|
30
|
+
* TransactionDetails component that displays a list of transaction detail items.
|
|
31
|
+
*
|
|
32
|
+
* This component serves as a container for TransactionDetails.Item children, applying consistent
|
|
33
|
+
* spacing and padding as defined by Figma design tokens.
|
|
34
|
+
*
|
|
35
|
+
* @component
|
|
36
|
+
* @param {Object} props
|
|
37
|
+
* @param {React.ReactNode} [props.children] - TransactionDetails.Item children to render.
|
|
38
|
+
* @param {Object} [props.modes={}] - Modes object passed to `getVariableByName` for design tokens.
|
|
39
|
+
* @param {Object} [props.style] - Optional container style overrides.
|
|
40
|
+
* @param {string} [props.accessibilityLabel] - Accessibility label for screen readers.
|
|
41
|
+
*
|
|
42
|
+
* @example
|
|
43
|
+
* ```tsx
|
|
44
|
+
* <TransactionDetails modes={{ 'Color Mode': 'Light' }}>
|
|
45
|
+
* <TransactionDetails.Item label="UPI transaction ID" value="101674916166" />
|
|
46
|
+
* <TransactionDetails.Item label="From" value="JioFinance • shivashankar@okjio" />
|
|
47
|
+
* <TransactionDetails.Item label="To" value="JioFinance • shivashankar@okjio" />
|
|
48
|
+
* <TransactionDetails.Item label="Payment method" value="UPI" />
|
|
49
|
+
* </TransactionDetails>
|
|
50
|
+
* ```
|
|
51
|
+
*/
|
|
52
|
+
declare function TransactionDetails({ children, modes, style, accessibilityLabel, ...rest }: TransactionDetailsProps): import("react/jsx-runtime").JSX.Element;
|
|
53
|
+
declare namespace TransactionDetails {
|
|
54
|
+
var Item: ({ label, value, modes, style, labelStyle, valueStyle, accessibilityLabel, ...rest }: TransactionDetailsItemProps) => import("react/jsx-runtime").JSX.Element;
|
|
55
|
+
}
|
|
56
|
+
export default TransactionDetails;
|
|
57
|
+
//# sourceMappingURL=TransactionDetails.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TransactionDetails.d.ts","sourceRoot":"","sources":["../../../../src/components/TransactionDetails/TransactionDetails.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,MAAM,OAAO,CAAA;AACzB,OAAO,EAAE,IAAI,EAAQ,KAAK,SAAS,EAAE,KAA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{ type ViewStyle } from 'react-native';
|
|
2
|
+
export type TransactionStatusProps = {
|
|
3
|
+
/** Status text, e.g. "Expired" */
|
|
4
|
+
status?: string;
|
|
5
|
+
/** Date text, e.g. "20 Mar 2025" */
|
|
6
|
+
date?: string;
|
|
7
|
+
/** Modes for design token resolution */
|
|
8
|
+
modes?: Record<string, any>;
|
|
9
|
+
/** Optional container style */
|
|
10
|
+
style?: ViewStyle;
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* TransactionStatus component displaying status icon, label, and date.
|
|
14
|
+
*/
|
|
15
|
+
export default function TransactionStatus({ status, date, modes, style, }: TransactionStatusProps): import("react/jsx-runtime").JSX.Element;
|
|
16
|
+
//# sourceMappingURL=TransactionStatus.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TransactionStatus.d.ts","sourceRoot":"","sources":["../../../../src/components/TransactionStatus/TransactionStatus.tsx"],"names":[],"mappings":"AACA,OAAO,EAAc,KAAK,SAAS,EAAkB,MAAM,cAAc,CAAA;AAsCzE,MAAM,MAAM,sBAAsB,GAAG;IACjC,kCAAkC;IAClC,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,oCAAoC;IACpC,IAAI,CAAC,EAAE,MAAM,CAAA;IACb,wCAAwC;IACxC,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;IAC3B,+BAA+B;IAC/B,KAAK,CAAC,EAAE,SAAS,CAAA;CACpB,CAAA;AAED;;GAEG;AACH,MAAM,CAAC,OAAO,UAAU,iBAAiB,CAAC,EACtC,MAAkB,EAClB,IAAoB,EACpB,KAAU,EACV,KAAK,GACR,EAAE,sBAAsB,2CAmCxB"}
|
|
@@ -11,6 +11,7 @@ export { default as CardFeedback } from './CardFeedback/CardFeedback';
|
|
|
11
11
|
export { default as Disclaimer } from './Disclaimer/Disclaimer';
|
|
12
12
|
export { default as Divider, type DividerProps, type DividerDirection } from './Divider/Divider';
|
|
13
13
|
export { default as Drawer } from './Drawer/Drawer';
|
|
14
|
+
export { default as CtaCard } from './CtaCard/CtaCard';
|
|
14
15
|
export { default as FilterBar } from './FilterBar/FilterBar';
|
|
15
16
|
export { default as IconButton } from './IconButton/IconButton';
|
|
16
17
|
export { default as IconCapsule } from './IconCapsule/IconCapsule';
|
|
@@ -27,6 +28,10 @@ export { default as Stepper } from './Stepper/Stepper';
|
|
|
27
28
|
export { Step } from './Stepper/Step';
|
|
28
29
|
export { StepLabel } from './Stepper/StepLabel';
|
|
29
30
|
export { default as TextInput } from './TextInput/TextInput';
|
|
31
|
+
export { default as ThreadHero, type ThreadHeroProps } from './ThreadHero/ThreadHero';
|
|
30
32
|
export { Tooltip } from './Tooltip/Tooltip';
|
|
33
|
+
export { default as TransactionBubble } from './TransactionBubble/TransactionBubble';
|
|
34
|
+
export { default as TransactionDetails } from './TransactionDetails/TransactionDetails';
|
|
35
|
+
export { default as TransactionStatus } from './TransactionStatus/TransactionStatus';
|
|
31
36
|
export { default as UpiHandle } from './UpiHandle/UpiHandle';
|
|
32
37
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/index.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,OAAO,IAAI,YAAY,EAAE,KAAK,iBAAiB,EAAE,MAAM,6BAA6B,CAAC;AAC9F,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,MAAM,iBAAiB,CAAC;AACpD,OAAO,EAAE,OAAO,IAAI,MAAM,EAAE,KAAK,WAAW,EAAE,MAAM,iBAAiB,CAAC;AACtE,OAAO,EAAE,OAAO,IAAI,WAAW,EAAE,MAAM,2BAA2B,CAAC;AACnE,OAAO,EAAE,OAAO,IAAI,KAAK,EAAE,MAAM,eAAe,CAAC;AACjD,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,uBAAuB,CAAC;AAC7D,OAAO,EAAE,OAAO,IAAI,aAA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AAe,EAAE,MAAM,yBAAyB,CAAC;AACtF,OAAO,EAAE,OAAO,EAAE,MAAM,mBAAmB,CAAC;AAC5C,OAAO,EAAE,OAAO,IAAI,iBAAiB,EAAE,MAAM,uCAAuC,CAAC;AACrF,OAAO,EAAE,OAAO,IAAI,kBAAkB,EAAE,MAAM,yCAAyC,CAAC;AACxF,OAAO,EAAE,OAAO,IAAI,iBAAiB,EAAE,MAAM,uCAAuC,CAAC;AACrF,OAAO,EAAE,OAAO,IAAI,SAAS,EAAE,MAAM,uBAAuB,CAAC"}
|
|
@@ -0,0 +1,44 @@
|
|
|
1
|
+
import React, { ReactNode } from 'react';
|
|
2
|
+
/**
|
|
3
|
+
* Shape of the TokenContext
|
|
4
|
+
*/
|
|
5
|
+
interface TokenContextType {
|
|
6
|
+
/**
|
|
7
|
+
* Current active modes map
|
|
8
|
+
* @example { 'Color Mode': 'Dark', 'Platform': 'mobile' }
|
|
9
|
+
*/
|
|
10
|
+
modes: Record<string, any>;
|
|
11
|
+
/**
|
|
12
|
+
* Helper to resolve variable by name using the current context modes.
|
|
13
|
+
*/
|
|
14
|
+
getVariable: (name: string) => any;
|
|
15
|
+
}
|
|
16
|
+
interface JFSThemeProviderProps {
|
|
17
|
+
/**
|
|
18
|
+
* Modes to apply globally.
|
|
19
|
+
* Can be used to set 'Color Mode', 'Platform', 'Density', etc.
|
|
20
|
+
*/
|
|
21
|
+
modes?: Record<string, any>;
|
|
22
|
+
children: ReactNode;
|
|
23
|
+
}
|
|
24
|
+
/**
|
|
25
|
+
* Provider component for the JFS Design System.
|
|
26
|
+
* Wraps your application or a subtree to provide global configuration for design tokens.
|
|
27
|
+
*
|
|
28
|
+
* @example
|
|
29
|
+
* <JFSThemeProvider modes={{ 'Color Mode': 'Dark', 'Platform': 'web' }}>
|
|
30
|
+
* <App />
|
|
31
|
+
* </JFSThemeProvider>
|
|
32
|
+
*/
|
|
33
|
+
export declare const JFSThemeProvider: React.FC<JFSThemeProviderProps>;
|
|
34
|
+
/**
|
|
35
|
+
* Hook to access the current design token context.
|
|
36
|
+
*
|
|
37
|
+
* returns {
|
|
38
|
+
* modes: Record<string, any> - The current active modes
|
|
39
|
+
* getVariable: (name: string) => any - Function to resolve a token value
|
|
40
|
+
* }
|
|
41
|
+
*/
|
|
42
|
+
export declare const useTokens: () => TokenContextType;
|
|
43
|
+
export {};
|
|
44
|
+
//# sourceMappingURL=JFSThemeProvider.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"JFSThemeProvider.d.ts","sourceRoot":"","sources":["../../../src/design-tokens/JFSThemeProvider.tsx"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,EAA6B,SAAS,EAAW,MAAM,OAAO,CAAC;AAG7E;;GAEG;AACH,UAAU,gBAAgB;IACtB;;;OAGG;IACH,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC3B;;OAEG;IACH,WAAW,EAAE,CAAC,IAAI,EAAE,MAAM,KAAK,GAAG,CAAC;CACtC;AAID,UAAU,qBAAqB;IAC3B;;;OAGG;IACH,KAAK,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAC;IAC5B,QAAQ,EAAE,SAAS,CAAC;CACvB;AAED;;;;;;;;GAQG;AACH,eAAO,MAAM,gBAAgB,EAAE,KAAK,CAAC,EAAE,CAAC,qBAAqB,CAmB5D,CAAC;AAEF;;;;;;;GAOG;AACH,eAAO,MAAM,SAAS,QAAO,gBAU5B,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/design-tokens/index.ts"],"names":[],"mappings":"AAAA,cAAc,4BAA4B,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/design-tokens/index.ts"],"names":[],"mappings":"AAAA,cAAc,4BAA4B,CAAC;AAC3C,cAAc,oBAAoB,CAAC"}
|
|
@@ -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-01-
|
|
7
|
+
* Generated: 2026-01-22T08:22:14.301Z
|
|
8
8
|
*/
|
|
9
9
|
export declare const iconRegistry: Record<string, {
|
|
10
10
|
path: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "jfs-components",
|
|
3
|
-
"version": "0.0.
|
|
3
|
+
"version": "0.0.5",
|
|
4
4
|
"description": "React Native Jio Finance Components Library",
|
|
5
5
|
"author": "sunshuaiqi@gmail.com",
|
|
6
6
|
"license": "MIT",
|
|
@@ -77,8 +77,7 @@
|
|
|
77
77
|
},
|
|
78
78
|
"peerDependencies": {
|
|
79
79
|
"react": "*",
|
|
80
|
-
"react-native": "*"
|
|
81
|
-
"styled-components": "*"
|
|
80
|
+
"react-native": "*"
|
|
82
81
|
},
|
|
83
82
|
"devDependencies": {
|
|
84
83
|
"@babel/core": "^7.28.5",
|
|
@@ -95,6 +94,7 @@
|
|
|
95
94
|
"@react-native/metro-config": "0.82.1",
|
|
96
95
|
"@storybook/addon-docs": "^10.0.8",
|
|
97
96
|
"@storybook/addon-links": "^10.0.8",
|
|
97
|
+
"@storybook/blocks": "^8.6.14",
|
|
98
98
|
"@storybook/manager-api": "^8.6.14",
|
|
99
99
|
"@storybook/react-native": "^10.0.7",
|
|
100
100
|
"@storybook/react-webpack5": "^10.0.8",
|
|
@@ -104,7 +104,6 @@
|
|
|
104
104
|
"@typescript-eslint/eslint-plugin": "^8.50.0",
|
|
105
105
|
"@typescript-eslint/parser": "^8.50.0",
|
|
106
106
|
"babel-loader": "^10.0.0",
|
|
107
|
-
"babel-plugin-styled-components": "^2.1.4",
|
|
108
107
|
"eslint": "^9.39.1",
|
|
109
108
|
"eslint-plugin-import": "^2.32.0",
|
|
110
109
|
"eslint-plugin-jsx-a11y": "^6.10.2",
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import { View, StyleSheet, type ViewProps } from 'react-native';
|
|
3
|
+
|
|
4
|
+
export const storyContainer = (props: ViewProps) => (
|
|
5
|
+
<View style= { styles.container } { ...props } />
|
|
6
|
+
);
|
|
7
|
+
|
|
8
|
+
const styles = StyleSheet.create({
|
|
9
|
+
container: {
|
|
10
|
+
height: '100%',
|
|
11
|
+
width: '100%',
|
|
12
|
+
alignItems: 'center',
|
|
13
|
+
justifyContent: 'center',
|
|
14
|
+
},
|
|
15
|
+
});
|