From 7bfe50ce49a2e7749ef7d7c6c47e21d4e898aeb9 Mon Sep 17 00:00:00 2001 From: Julien Bouquillon Date: Wed, 21 Dec 2022 17:09:22 +0100 Subject: [PATCH] fix(Card): more TS --- src/Card.tsx | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/src/Card.tsx b/src/Card.tsx index 496059beb..5ccd87b57 100644 --- a/src/Card.tsx +++ b/src/Card.tsx @@ -57,16 +57,24 @@ export type CardProps = { string > >; -} & (CardProps.Default | CardProps.Horizontal); +} & (CardProps.Default | CardProps.Horizontal) & + (CardProps.EnlargedLink | CardProps.NotEnlargedLink); export namespace CardProps { export type Default = { horizontal?: never; }; - export type Horizontal = { horizontal: true; }; + export type EnlargedLink = { + enlargeLink: true; + iconId?: FrIconClassName | RiIconClassName; + }; + export type NotEnlargedLink = { + enlargeLink?: false; + iconId?: never; + }; } /** @see */