Skip to content

Commit

Permalink
Remove paymentMethods props
Browse files Browse the repository at this point in the history
  • Loading branch information
rustam-cb committed Jan 16, 2025
1 parent 7850ac4 commit f785493
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 18 deletions.
3 changes: 1 addition & 2 deletions src/fund/components/FundCard.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,6 @@ export function FundCard({
headerText,
country = 'US',
subdivision,
paymentMethods = DEFAULT_PAYMENT_METHODS,
children = <DefaultFundCardContent />,
className,
onError,
Expand All @@ -29,7 +28,7 @@ export function FundCard({
return (
<FundCardProvider
asset={assetSymbol}
paymentMethods={paymentMethods}
paymentMethods={DEFAULT_PAYMENT_METHODS}
headerText={headerText}
buttonText={buttonText}
country={country}
Expand Down
28 changes: 12 additions & 16 deletions src/fund/types.ts
Original file line number Diff line number Diff line change
Expand Up @@ -320,10 +320,6 @@ export type FundCardPropsReact = {
buttonText?: string;
country: string;
subdivision?: string;
/**
* Payment methods to display in the dropdown
*/
paymentMethods?: PaymentMethodReact[];
className?: string;
} & LifecycleEvents;

Expand Down Expand Up @@ -410,17 +406,17 @@ export type LifecycleStatusUpdate = LifecycleStatus extends infer T
? { statusName: N } & (N extends 'init' // statusData required in statusName "init"
? { statusData: D }
: AllKeysInShared<D> extends true // is statusData is LifecycleStatusDataShared, make optional
? {
statusData?: PartialKeys<
D,
keyof D & keyof LifecycleStatusDataShared
>;
} // make all keys in LifecycleStatusDataShared optional
: {
statusData: PartialKeys<
D,
keyof D & keyof LifecycleStatusDataShared
>;
})
? {
statusData?: PartialKeys<
D,
keyof D & keyof LifecycleStatusDataShared
>;
} // make all keys in LifecycleStatusDataShared optional
: {
statusData: PartialKeys<
D,
keyof D & keyof LifecycleStatusDataShared
>;
})
: never
: never;

0 comments on commit f785493

Please sign in to comment.