diff --git a/src/components/avatar/avatar.tsx b/src/components/avatar/avatar.tsx index 71389b8..584c3c7 100644 --- a/src/components/avatar/avatar.tsx +++ b/src/components/avatar/avatar.tsx @@ -31,7 +31,7 @@ export const Avatar: React.FC = ({ if (props.href) { return ( - + = ({ } return ( - + ); diff --git a/src/components/avatar/avatar.types.ts b/src/components/avatar/avatar.types.ts index 845745f..3728a0e 100644 --- a/src/components/avatar/avatar.types.ts +++ b/src/components/avatar/avatar.types.ts @@ -17,5 +17,5 @@ export type AvatarProps = { imageComponentProps?: { [key: string]: string }; href?: string; onClick?: (e: MouseEvent) => void; - e2e?: string; + testid?: string; }; diff --git a/src/components/button/button.tsx b/src/components/button/button.tsx index ba9b84c..0ca7e8b 100644 --- a/src/components/button/button.tsx +++ b/src/components/button/button.tsx @@ -57,7 +57,7 @@ export const Button: React.FC = ({ href={props.href} className={props.isIconOnly ? iconClasses.join(' ') : baseClasses.join(' ')} aria-label={props.ariaLabel || props.label} - data-e2e={props.e2e} + data-testid={props.testid} > {props.children} @@ -70,7 +70,7 @@ export const Button: React.FC = ({ onClick={props.onClick} aria-label={props.ariaLabel || props.label} className={props.isIconOnly ? iconClasses.join(' ') : baseClasses.join(' ')} - data-e2e={props.e2e} + data-testid={props.testid} > {props.children} diff --git a/src/components/button/button.types.ts b/src/components/button/button.types.ts index 23c9efa..a6f0f73 100644 --- a/src/components/button/button.types.ts +++ b/src/components/button/button.types.ts @@ -25,5 +25,5 @@ export type ButtonProps = { elementType?: React.ElementType; href?: string; ariaLabel?: string; - e2e?: string; + testid?: string; }; diff --git a/src/components/hashtag/hashtag.tsx b/src/components/hashtag/hashtag.tsx index 7c1f29a..2f150e7 100644 --- a/src/components/hashtag/hashtag.tsx +++ b/src/components/hashtag/hashtag.tsx @@ -13,7 +13,7 @@ export const Hashtag: React.FC = ({ size = HashtagSize.L, ...props } return ( - ); diff --git a/src/components/hashtag/hashtag.types.ts b/src/components/hashtag/hashtag.types.ts index 359ffe4..faa61fe 100644 --- a/src/components/hashtag/hashtag.types.ts +++ b/src/components/hashtag/hashtag.types.ts @@ -9,5 +9,5 @@ export type HashtagProps = { label?: string; size?: HashtagSize; onClick: (e: MouseEvent) => void; - e2e?: string; + testid?: string; }; diff --git a/src/components/icon-link/icon-link.tsx b/src/components/icon-link/icon-link.tsx index 3bad05f..b86a1d3 100644 --- a/src/components/icon-link/icon-link.tsx +++ b/src/components/icon-link/icon-link.tsx @@ -31,7 +31,7 @@ export const IconLink: React.FC = ({ elementType: Component = 'a' href={props.href} className={baseClasses.join(' ')} aria-label={props.label} - data-e2e={props.e2e} + data-testid={props.testid} > {props.children} {props.label} diff --git a/src/components/icon-link/icon-link.types.ts b/src/components/icon-link/icon-link.types.ts index b37a7be..b7bd7d5 100644 --- a/src/components/icon-link/icon-link.types.ts +++ b/src/components/icon-link/icon-link.types.ts @@ -13,5 +13,5 @@ export type IconLinkProps = { children?: ReactNode; onClick?: (e: MouseEvent) => void; elementType?: React.ElementType; - e2e?: string; + testid?: string; }; diff --git a/src/components/input/input.tsx b/src/components/input/input.tsx index 73a517d..75aa119 100644 --- a/src/components/input/input.tsx +++ b/src/components/input/input.tsx @@ -56,7 +56,7 @@ export const Input: React.FC = ({ type = InputType.TEXT, ...props }) type={type} placeholder={props.placeholder} className={inputBaseClasses.join(' ')} - data-e2e={props.e2e} + data-testid={props.testid} /> {(props.children || props.hasError) && ( {props.hasError ? : props.children} diff --git a/src/components/input/input.types.ts b/src/components/input/input.types.ts index 0603e6a..d698c0b 100644 --- a/src/components/input/input.types.ts +++ b/src/components/input/input.types.ts @@ -15,5 +15,5 @@ export type InputProps = { onChange?: (e: ChangeEvent) => void; hasError?: boolean; errorMessage?: string; - e2e?: string; + testid?: string; }; diff --git a/src/components/interaction/interaction.tsx b/src/components/interaction/interaction.tsx index e3e5772..38c2f87 100644 --- a/src/components/interaction/interaction.tsx +++ b/src/components/interaction/interaction.tsx @@ -35,7 +35,7 @@ export const Interaction: React.FC = (props) => { }); return ( - ); diff --git a/src/components/interaction/interaction.types.ts b/src/components/interaction/interaction.types.ts index 6ff3899..183fe69 100644 --- a/src/components/interaction/interaction.types.ts +++ b/src/components/interaction/interaction.types.ts @@ -11,5 +11,5 @@ export type InteractionProps = { active?: boolean; onClick: (e: MouseEvent) => void; children?: ReactNode; - e2e?: string; + testid?: string; }; diff --git a/src/components/navigationItem/navigation-item.tsx b/src/components/navigationItem/navigation-item.tsx index 40cb77a..47e4fcf 100644 --- a/src/components/navigationItem/navigation-item.tsx +++ b/src/components/navigationItem/navigation-item.tsx @@ -10,7 +10,7 @@ export const NavigationItem: React.FC = ({ elementType: Com if (props.href) { return (
  • - + {props.children} {props.label} @@ -20,7 +20,7 @@ export const NavigationItem: React.FC = ({ elementType: Com return (
  • - + {props.children} {props.label} diff --git a/src/components/navigationItem/navigation-item.types.ts b/src/components/navigationItem/navigation-item.types.ts index e568c00..dee4f09 100644 --- a/src/components/navigationItem/navigation-item.types.ts +++ b/src/components/navigationItem/navigation-item.types.ts @@ -6,5 +6,5 @@ export type NavigationItemProps = { onClick?: (e: MouseEvent) => void; elementType?: React.ElementType; href?: string; - e2e?: string; + testid?: string; }; diff --git a/src/components/tabs/tabs-item.tsx b/src/components/tabs/tabs-item.tsx index b0d2a72..0ce5e5c 100644 --- a/src/components/tabs/tabs-item.tsx +++ b/src/components/tabs/tabs-item.tsx @@ -11,7 +11,7 @@ export const TabsItem: React.FC = (props) => { } return ( -
  • +
  • {props.label}
  • ); diff --git a/src/components/tabs/tabs.types.ts b/src/components/tabs/tabs.types.ts index 13f8054..38e0f12 100644 --- a/src/components/tabs/tabs.types.ts +++ b/src/components/tabs/tabs.types.ts @@ -8,5 +8,5 @@ export type TabsItemProps = { active: boolean; label: string; onClick?: () => void; - e2e?: string; + testid?: string; }; diff --git a/src/components/text-link/text-link.tsx b/src/components/text-link/text-link.tsx index 6bf7d85..75c7328 100644 --- a/src/components/text-link/text-link.tsx +++ b/src/components/text-link/text-link.tsx @@ -6,7 +6,13 @@ export const TextLink: React.FC = ({ elementType: Component = 'a' 'text-violet-600 border-b-2 border-violet-600 hover:border-violet-200 h-fit text-14 font-semibold cursor-pointer'; return ( - + {props.label} ); diff --git a/src/components/text-link/text-link.types.ts b/src/components/text-link/text-link.types.ts index 3a388b5..711653c 100644 --- a/src/components/text-link/text-link.types.ts +++ b/src/components/text-link/text-link.types.ts @@ -5,5 +5,5 @@ export type TextLinkProps = { href?: string; target?: HTMLAttributeAnchorTarget; elementType?: React.ElementType; - e2e?: string; + testid?: string; }; diff --git a/src/components/textarea/textarea.tsx b/src/components/textarea/textarea.tsx index 6e72d56..d97d563 100644 --- a/src/components/textarea/textarea.tsx +++ b/src/components/textarea/textarea.tsx @@ -43,7 +43,7 @@ export const Textarea: React.FC = ({ rows = 8, ...props }) => { placeholder={props.placeholder} className={textareaBaseClasses.join(' ')} rows={rows} - data-e2e={props.e2e} + data-testid={props.testid} /> {props.hasError && props.errorMessage ?
    {props.errorMessage}
    : ''} diff --git a/src/components/textarea/textarea.types.ts b/src/components/textarea/textarea.types.ts index 3bd9caf..c2e889a 100644 --- a/src/components/textarea/textarea.types.ts +++ b/src/components/textarea/textarea.types.ts @@ -8,5 +8,5 @@ export type TextareaProps = { onChange?: (e: ChangeEvent) => void; hasError?: boolean; errorMessage?: string; - e2e?: string; + testid?: string; };