@funkit/connect-rn 3.10.1 → 4.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +46 -0
- package/dist/{chunk-4QKU6F5D.js → chunk-OI54J6E6.js} +363 -2
- package/dist/chunk-OI54J6E6.js.map +7 -0
- package/dist/{chunk-THWTURYZ.js → chunk-V4LN3XNI.js} +2 -2
- package/dist/clients/lighter.js +1 -1
- package/dist/clients/nado.js +2 -2
- package/dist/index.d.ts +2 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +2461 -1185
- package/dist/index.js.map +4 -4
- package/dist/src/branding/BrandingContext.d.ts +15 -0
- package/dist/src/branding/BrandingContext.d.ts.map +1 -0
- package/dist/src/components/AttributionWatermark.d.ts +10 -0
- package/dist/src/components/AttributionWatermark.d.ts.map +1 -0
- package/dist/src/components/Grabber.d.ts +7 -1
- package/dist/src/components/Grabber.d.ts.map +1 -1
- package/dist/src/components/PillButton.d.ts +3 -1
- package/dist/src/components/PillButton.d.ts.map +1 -1
- package/dist/src/components/v2/AmountDisplay.d.ts.map +1 -1
- package/dist/src/components/v2/NumPad.d.ts.map +1 -1
- package/dist/src/fiat/FiatStatusScreen.d.ts +19 -0
- package/dist/src/fiat/FiatStatusScreen.d.ts.map +1 -0
- package/dist/src/fiat/SurfaceSlot.d.ts +8 -0
- package/dist/src/fiat/SurfaceSlot.d.ts.map +1 -0
- package/dist/src/fiat/ctaLabel.d.ts +19 -0
- package/dist/src/fiat/ctaLabel.d.ts.map +1 -0
- package/dist/src/fiat/providers/TransakApplePaySurface.d.ts +7 -0
- package/dist/src/fiat/providers/TransakApplePaySurface.d.ts.map +1 -0
- package/dist/src/fiat/renderCaptureSurface.d.ts +12 -0
- package/dist/src/fiat/renderCaptureSurface.d.ts.map +1 -0
- package/dist/src/fiat/stepDetails.d.ts +18 -0
- package/dist/src/fiat/stepDetails.d.ts.map +1 -0
- package/dist/src/flow/DepositAmountStep.d.ts.map +1 -1
- package/dist/src/flow/DepositFlowContent.d.ts +1 -3
- package/dist/src/flow/DepositFlowContent.d.ts.map +1 -1
- package/dist/src/flow/FiatDepositAmountStep.d.ts +9 -0
- package/dist/src/flow/FiatDepositAmountStep.d.ts.map +1 -0
- package/dist/src/flow/FlowSheet.d.ts +34 -5
- package/dist/src/flow/FlowSheet.d.ts.map +1 -1
- package/dist/src/flow/FunkitFlowProvider.d.ts +1 -1
- package/dist/src/flow/FunkitFlowProvider.d.ts.map +1 -1
- package/dist/src/flow/WithdrawalFlowContent.d.ts +1 -4
- package/dist/src/flow/WithdrawalFlowContent.d.ts.map +1 -1
- package/dist/src/flow/depositFlowConfig.d.ts +24 -3
- package/dist/src/flow/depositFlowConfig.d.ts.map +1 -1
- package/dist/src/hooks/useGuardedAmountInput.d.ts.map +1 -1
- package/dist/src/hooks/usePressScale.d.ts +18 -0
- package/dist/src/hooks/usePressScale.d.ts.map +1 -0
- package/dist/src/identity/IdentityContext.d.ts +10 -0
- package/dist/src/identity/IdentityContext.d.ts.map +1 -1
- package/dist/src/providers/FunkitProvider.d.ts +6 -5
- package/dist/src/providers/FunkitProvider.d.ts.map +1 -1
- package/dist/src/providers/NativeCapabilitiesContext.d.ts +43 -0
- package/dist/src/providers/NativeCapabilitiesContext.d.ts.map +1 -0
- package/dist/src/screens/DepositAmountScreen.d.ts +27 -11
- package/dist/src/screens/DepositAmountScreen.d.ts.map +1 -1
- package/dist/src/screens/FeeDetailsScreen.d.ts +36 -0
- package/dist/src/screens/FeeDetailsScreen.d.ts.map +1 -0
- package/dist/src/theme/buildFunkitTheme.d.ts +8 -0
- package/dist/src/theme/buildFunkitTheme.d.ts.map +1 -1
- package/dist/src/theme/restyle.d.ts +264 -0
- package/dist/src/theme/restyle.d.ts.map +1 -1
- package/dist/src/theme/toRestyleTheme.d.ts +24 -0
- package/dist/src/theme/toRestyleTheme.d.ts.map +1 -1
- package/dist/src/theme/tokens.d.ts +4 -1
- package/dist/src/theme/tokens.d.ts.map +1 -1
- package/dist/src/utils/formatAmount.d.ts +5 -0
- package/dist/src/utils/formatAmount.d.ts.map +1 -1
- package/dist/src/utils/numpadInput.d.ts +2 -1
- package/dist/src/utils/numpadInput.d.ts.map +1 -1
- package/dist/src/utils/withAlpha.d.ts +13 -0
- package/dist/src/utils/withAlpha.d.ts.map +1 -0
- package/package.json +6 -4
- package/dist/chunk-4QKU6F5D.js.map +0 -7
- package/dist/src/components/v2/RollingAmount.d.ts +0 -20
- package/dist/src/components/v2/RollingAmount.d.ts.map +0 -1
- /package/dist/{chunk-THWTURYZ.js.map → chunk-V4LN3XNI.js.map} +0 -0
|
@@ -2,15 +2,14 @@ import { type ReactNode } from 'react';
|
|
|
2
2
|
import { type AccountBalanceChipProps } from '../components/v2/AccountBalanceChip';
|
|
3
3
|
import { type QuickAmountOption } from '../components/v2/QuickAmountsRow';
|
|
4
4
|
/**
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
5
|
+
* How much of the screen's foot the action area occupies — the fee line, the
|
|
6
|
+
* submit button and the keypad below them.
|
|
7
|
+
*
|
|
8
|
+
* A drawer opened from the fee line has to cover at least this, or the line
|
|
9
|
+
* that opened it sits stranded above its own drawer. Derived here rather than
|
|
10
|
+
* guessed by the caller, so the two can't drift apart.
|
|
8
11
|
*/
|
|
9
|
-
export
|
|
10
|
-
before: string;
|
|
11
|
-
amount: string;
|
|
12
|
-
after: string;
|
|
13
|
-
}
|
|
12
|
+
export declare function depositActionsHeight(insetBottom: number): number;
|
|
14
13
|
export interface DepositAmountScreenProps {
|
|
15
14
|
title: string;
|
|
16
15
|
/** Brand glyph beside the title (host-supplied). */
|
|
@@ -24,15 +23,32 @@ export interface DepositAmountScreenProps {
|
|
|
24
23
|
quickAmounts?: QuickAmountOption[];
|
|
25
24
|
/** Hard input cap in dollars — the payment source's limit. */
|
|
26
25
|
limitUsd?: string;
|
|
27
|
-
/** The
|
|
28
|
-
fee?:
|
|
26
|
+
/** The full fee line for the entered amount (e.g. `$0.50 fee`). */
|
|
27
|
+
fee?: string;
|
|
28
|
+
/**
|
|
29
|
+
* The shown fee no longer prices the current input (a keystroke invalidated
|
|
30
|
+
* the quote). The fee line fades out and stops answering taps until this
|
|
31
|
+
* clears with the next settled quote.
|
|
32
|
+
*/
|
|
33
|
+
feePending?: boolean;
|
|
34
|
+
/**
|
|
35
|
+
* Opens the fee-details drawer. Omit to leave the fee line as plain text —
|
|
36
|
+
* the ⓘ then says there is more to read when there isn't.
|
|
37
|
+
*/
|
|
38
|
+
onPressFee?: () => void;
|
|
39
|
+
/** Accessible name for the fee line's tap target. */
|
|
40
|
+
feeAccessibilityLabel?: string;
|
|
29
41
|
/** Badge on the fee line's leading side (e.g. an Apple Pay mark). */
|
|
30
42
|
methodBadge?: ReactNode;
|
|
31
43
|
submitLabel: string;
|
|
32
44
|
canSubmit: boolean;
|
|
33
45
|
onSubmit: () => void;
|
|
46
|
+
/** Replaces the submit pill with provider UI. */
|
|
47
|
+
renderSubmit?: () => ReactNode;
|
|
34
48
|
amountAccessibilityLabel: string;
|
|
35
49
|
backspaceAccessibilityLabel: string;
|
|
50
|
+
/** Draw the "powered by Fun" mark at the screen's foot. */
|
|
51
|
+
showAttribution?: boolean;
|
|
36
52
|
}
|
|
37
53
|
/**
|
|
38
54
|
* The V2 deposit surface: a full-height sheet where the amount is the whole
|
|
@@ -43,5 +59,5 @@ export interface DepositAmountScreenProps {
|
|
|
43
59
|
* limit — answers with a side-to-side shake, a brief warning tint and a haptic
|
|
44
60
|
* instead of changing the value.
|
|
45
61
|
*/
|
|
46
|
-
export declare function DepositAmountScreen({ title, brandIcon, accountContext, input, onChangeInput, quickAmounts, limitUsd, fee, methodBadge, submitLabel, canSubmit, onSubmit, amountAccessibilityLabel, backspaceAccessibilityLabel, }: DepositAmountScreenProps): import("react").JSX.Element;
|
|
62
|
+
export declare function DepositAmountScreen({ title, brandIcon, accountContext, input, onChangeInput, quickAmounts, limitUsd, fee, feePending, onPressFee, feeAccessibilityLabel, methodBadge, submitLabel, canSubmit, onSubmit, renderSubmit, amountAccessibilityLabel, backspaceAccessibilityLabel, showAttribution, }: DepositAmountScreenProps): import("react").JSX.Element;
|
|
47
63
|
//# sourceMappingURL=DepositAmountScreen.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"DepositAmountScreen.d.ts","sourceRoot":"","sources":["../../../src/screens/DepositAmountScreen.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,
|
|
1
|
+
{"version":3,"file":"DepositAmountScreen.d.ts","sourceRoot":"","sources":["../../../src/screens/DepositAmountScreen.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAa,MAAM,OAAO,CAAA;AAcjD,OAAO,EAEL,KAAK,uBAAuB,EAC7B,MAAM,qCAAqC,CAAA;AAC5C,OAAO,EACL,KAAK,iBAAiB,EAEvB,MAAM,kCAAkC,CAAA;AAsBzC;;;;;;;GAOG;AACH,wBAAgB,oBAAoB,CAAC,WAAW,EAAE,MAAM,GAAG,MAAM,CAOhE;AAoBD,MAAM,WAAW,wBAAwB;IACvC,KAAK,EAAE,MAAM,CAAA;IACb,oDAAoD;IACpD,SAAS,CAAC,EAAE,SAAS,CAAA;IACrB,4DAA4D;IAC5D,cAAc,CAAC,EAAE,uBAAuB,CAAA;IACxC,6EAA6E;IAC7E,KAAK,EAAE,MAAM,CAAA;IACb,aAAa,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAA;IACtC,0DAA0D;IAC1D,YAAY,CAAC,EAAE,iBAAiB,EAAE,CAAA;IAClC,8DAA8D;IAC9D,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,mEAAmE;IACnE,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ;;;;OAIG;IACH,UAAU,CAAC,EAAE,OAAO,CAAA;IACpB;;;OAGG;IACH,UAAU,CAAC,EAAE,MAAM,IAAI,CAAA;IACvB,qDAAqD;IACrD,qBAAqB,CAAC,EAAE,MAAM,CAAA;IAC9B,qEAAqE;IACrE,WAAW,CAAC,EAAE,SAAS,CAAA;IACvB,WAAW,EAAE,MAAM,CAAA;IACnB,SAAS,EAAE,OAAO,CAAA;IAClB,QAAQ,EAAE,MAAM,IAAI,CAAA;IACpB,iDAAiD;IACjD,YAAY,CAAC,EAAE,MAAM,SAAS,CAAA;IAC9B,wBAAwB,EAAE,MAAM,CAAA;IAChC,2BAA2B,EAAE,MAAM,CAAA;IACnC,2DAA2D;IAC3D,eAAe,CAAC,EAAE,OAAO,CAAA;CAC1B;AAED;;;;;;;;GAQG;AACH,wBAAgB,mBAAmB,CAAC,EAClC,KAAK,EACL,SAAS,EACT,cAAc,EACd,KAAK,EACL,aAAa,EACb,YAAY,EACZ,QAAQ,EACR,GAAG,EACH,UAAkB,EAClB,UAAU,EACV,qBAAqB,EACrB,WAAW,EACX,WAAW,EACX,SAAS,EACT,QAAQ,EACR,YAAY,EACZ,wBAAwB,EACxB,2BAA2B,EAC3B,eAAuB,GACxB,EAAE,wBAAwB,+BAmH1B"}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/** One `label · value` line of the breakdown. */
|
|
2
|
+
export interface FeeDetailsRow {
|
|
3
|
+
label: string;
|
|
4
|
+
value: string;
|
|
5
|
+
/**
|
|
6
|
+
* The summed line the rest add up to — set in the heavier cut, and the only
|
|
7
|
+
* row the design emphasises.
|
|
8
|
+
*/
|
|
9
|
+
isTotal?: boolean;
|
|
10
|
+
}
|
|
11
|
+
export interface FeeDetailsScreenProps {
|
|
12
|
+
/**
|
|
13
|
+
* What the fees are and where they land, in prose. Omitted when the host
|
|
14
|
+
* hasn't named a payment method.
|
|
15
|
+
*/
|
|
16
|
+
summary?: string;
|
|
17
|
+
rows: FeeDetailsRow[];
|
|
18
|
+
onClose: () => void;
|
|
19
|
+
/** Draw the "powered by Fun" mark (the drawer covers the screen's own). */
|
|
20
|
+
showAttribution?: boolean;
|
|
21
|
+
/**
|
|
22
|
+
* Floor for the drawer's height. It is content-sized, and short content would
|
|
23
|
+
* leave the fee line that opened it showing above its own drawer.
|
|
24
|
+
*/
|
|
25
|
+
minHeight?: number;
|
|
26
|
+
}
|
|
27
|
+
/**
|
|
28
|
+
* The fee disclosure drawer. Opened from the fee line on the amount screen, it
|
|
29
|
+
* presents the transaction's top-level cost: a written summary of the fee, then
|
|
30
|
+
* the amount, the fee and what the two come to.
|
|
31
|
+
*
|
|
32
|
+
* Presented as a nested bottom sheet over the amount screen, so it is dismissed
|
|
33
|
+
* by swiping down, tapping the overlayFill, or its own close button.
|
|
34
|
+
*/
|
|
35
|
+
export declare function FeeDetailsScreen({ summary, rows, onClose, showAttribution, minHeight, }: FeeDetailsScreenProps): import("react").JSX.Element;
|
|
36
|
+
//# sourceMappingURL=FeeDetailsScreen.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"FeeDetailsScreen.d.ts","sourceRoot":"","sources":["../../../src/screens/FeeDetailsScreen.tsx"],"names":[],"mappings":"AAyBA,iDAAiD;AACjD,MAAM,WAAW,aAAa;IAC5B,KAAK,EAAE,MAAM,CAAA;IACb,KAAK,EAAE,MAAM,CAAA;IACb;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAA;CAClB;AAED,MAAM,WAAW,qBAAqB;IACpC;;;OAGG;IACH,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,IAAI,EAAE,aAAa,EAAE,CAAA;IACrB,OAAO,EAAE,MAAM,IAAI,CAAA;IACnB,2EAA2E;IAC3E,eAAe,CAAC,EAAE,OAAO,CAAA;IACzB;;;OAGG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;CACnB;AAED;;;;;;;GAOG;AACH,wBAAgB,gBAAgB,CAAC,EAC/B,OAAO,EACP,IAAI,EACJ,OAAO,EACP,eAAuB,EACvB,SAAS,GACV,EAAE,qBAAqB,+BA4CvB"}
|
|
@@ -41,6 +41,7 @@ export declare function buildFunkitTheme(tokens: FunkitTokens): {
|
|
|
41
41
|
error: string;
|
|
42
42
|
hyperlink: string;
|
|
43
43
|
warning: string;
|
|
44
|
+
watermark: string;
|
|
44
45
|
};
|
|
45
46
|
button: {
|
|
46
47
|
primary: {
|
|
@@ -168,6 +169,13 @@ export declare function buildFunkitTheme(tokens: FunkitTokens): {
|
|
|
168
169
|
fontFamily: string;
|
|
169
170
|
fontWeight: "medium" | "normal" | "bold" | "100" | "200" | "300" | "400" | "500" | "600" | "700" | "800" | "900" | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900 | "ultralight" | "thin" | "light" | "regular" | "semibold" | "condensedBold" | "condensed" | "heavy" | "black" | undefined;
|
|
170
171
|
};
|
|
172
|
+
drawerTitle: {
|
|
173
|
+
fontSize: number;
|
|
174
|
+
lineHeight: number;
|
|
175
|
+
letterSpacing: number;
|
|
176
|
+
fontFamily: string;
|
|
177
|
+
fontWeight: "medium" | "normal" | "bold" | "100" | "200" | "300" | "400" | "500" | "600" | "700" | "800" | "900" | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900 | "ultralight" | "thin" | "light" | "regular" | "semibold" | "condensedBold" | "condensed" | "heavy" | "black" | undefined;
|
|
178
|
+
};
|
|
171
179
|
amountInput: {
|
|
172
180
|
fontSize: number;
|
|
173
181
|
fontFamily: string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"buildFunkitTheme.d.ts","sourceRoot":"","sources":["../../../src/theme/buildFunkitTheme.ts"],"names":[],"mappings":"AAEA,OAAO,EAGL,KAAK,YAAY,EAElB,MAAM,UAAU,CAAA;AAYjB;;;;;;;;;;;;GAYG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,YAAY
|
|
1
|
+
{"version":3,"file":"buildFunkitTheme.d.ts","sourceRoot":"","sources":["../../../src/theme/buildFunkitTheme.ts"],"names":[],"mappings":"AAEA,OAAO,EAGL,KAAK,YAAY,EAElB,MAAM,UAAU,CAAA;AAYjB;;;;;;;;;;;;GAYG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,YAAY;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAoHpD"}
|