Skip to content

Commit

Permalink
fix(PaymentCard): correctly export type for getCardData function
Browse files Browse the repository at this point in the history
  • Loading branch information
langz committed Sep 29, 2023
1 parent ef881a8 commit cfaacdb
Showing 1 changed file with 15 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,18 @@ export interface PaymentCardRawData {
productType: ProductType;
bankAxept: BankAxeptType;
}

export interface CardDesign {
name: string;
cardStyle: string;
bankLogo: any;
visa: any;
mastercard: any;
bankAxept: any;
saga: any;
privateBanking: any;
}

export type PaymentCardChildren =
| string
| React.ReactNode
Expand Down Expand Up @@ -109,6 +121,8 @@ export default class PaymentCard extends React.Component<
static defaultProps: object;
render(): JSX.Element;
}
export const getCardData = (product_code: string) => PaymentCardRawData;
export const getCardData: (
product_code: string
) => Omit<PaymentCardRawData, 'cardDesign'> & { cardDesign: CardDesign };
export const formatCardNumber = (cardNumber: string, digits?: number) =>
string;

0 comments on commit cfaacdb

Please sign in to comment.