diff --git a/packages/dnb-eufemia/src/extensions/payment-card/PaymentCard.tsx b/packages/dnb-eufemia/src/extensions/payment-card/PaymentCard.tsx index 30f5447372f..c014fdccbd5 100644 --- a/packages/dnb-eufemia/src/extensions/payment-card/PaymentCard.tsx +++ b/packages/dnb-eufemia/src/extensions/payment-card/PaymentCard.tsx @@ -43,7 +43,6 @@ const defaultProps = { id: null, customCard: null, - // rawData: null, skeleton: false, className: null, @@ -73,8 +72,7 @@ export default function PaymentCard(props: PaymentCardProps) { digits, id, customCard: cardDesignProp, - // rawData, - // locale, + // locale skeleton, className, children, //eslint-disable-line @@ -94,8 +92,6 @@ export default function PaymentCard(props: PaymentCardProps) { ...cardDesignProp, } - // const cardData: CustomCard = rawData || getCardData(productCode) - const params = { className: classnames( 'dnb-payment-card', @@ -217,12 +213,3 @@ export function getCardDesign(productCode: string): CustomCard { defaultCard(productCode) ) } - -// export const getCardData: (productCode: string) => PaymentCardRawData = ( -// productCode -// ) => { -// const card = cardProducts.find( -// (item) => item.productCode === productCode -// ) -// return card || defaultCard(productCode) -// } diff --git a/packages/dnb-eufemia/src/extensions/payment-card/icons/index.tsx b/packages/dnb-eufemia/src/extensions/payment-card/icons/index.tsx index 3946a83f46b..eb7bfdce2d5 100644 --- a/packages/dnb-eufemia/src/extensions/payment-card/icons/index.tsx +++ b/packages/dnb-eufemia/src/extensions/payment-card/icons/index.tsx @@ -93,7 +93,7 @@ function ProductLogo({ type }: ProductLogoProps) { type PaymentTypeProps = { type: PaymentType - color: string + color?: string } const PaymentTypeLogo = ({ type, color }: PaymentTypeProps) => { diff --git a/packages/dnb-eufemia/src/extensions/payment-card/stories/PaymentCard.stories.tsx b/packages/dnb-eufemia/src/extensions/payment-card/stories/PaymentCard.stories.tsx index 24b3608fedd..3a104c1b389 100644 --- a/packages/dnb-eufemia/src/extensions/payment-card/stories/PaymentCard.stories.tsx +++ b/packages/dnb-eufemia/src/extensions/payment-card/stories/PaymentCard.stories.tsx @@ -26,17 +26,6 @@ const CustomWrapper = styled(Wrapper)` /* empty */ ` -// const customData: PaymentCardRawData = { -// productCode: 'UNDEFINED', -// productName: 'DNB Custom Card', -// displayName: 'Custom card', // Only showed in compact variant -// // cardDesign: 'gold', -// cardDesign: Designs.gold, -// cardType: 'MastercardDefault', -// productType: 'Saga', -// bankAxept: 'BankAxeptWhite', -// } - export const PaymentCards = () => ( @@ -86,6 +75,11 @@ export const PaymentCards = () => ( /> + +

Custom Card

+ +
+