Skip to content

Commit

Permalink
fix: test_cases
Browse files Browse the repository at this point in the history
  • Loading branch information
amina-deriv committed Jul 4, 2023
1 parent e1068f3 commit c796ad3
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions packages/components/src/components/input/input.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -102,6 +102,7 @@ const Input = React.forwardRef<HTMLInputElement & HTMLTextAreaElement, TInputPro
};

const has_footer = !!has_character_counter || (!!hint && !!is_relative_hint);
const field_placeholder = label ? '' : placeholder;

return (
<InputWrapper has_footer={has_footer}>
Expand Down Expand Up @@ -135,7 +136,7 @@ const Input = React.forwardRef<HTMLInputElement & HTMLTextAreaElement, TInputPro
disabled={disabled}
id={input_id}
maxLength={maxLength}
placeholder={label ? '' : placeholder}
placeholder={field_placeholder}
/>
) : (
<input
Expand All @@ -154,7 +155,7 @@ const Input = React.forwardRef<HTMLInputElement & HTMLTextAreaElement, TInputPro
id={input_id}
aria-label={label as string}
maxLength={maxLength}
placeholder={label ? '' : placeholder}
placeholder={field_placeholder}
/>
)}
{trailing_icon &&
Expand Down

0 comments on commit c796ad3

Please sign in to comment.