From 19f3dc9a0560ee85efe52d9be0ec935061d1469b Mon Sep 17 00:00:00 2001 From: Maxime Perrault <166825146+maximeperraultdev@users.noreply.github.com> Date: Tue, 9 Jul 2024 10:13:00 +0200 Subject: [PATCH] Revert "fix(components): add $ to isHidden" This reverts commit bcdd45f14c91cd8e385c0d28be659549a91e7687. --- src/elements/Label.tsx | 16 ++++++++-------- src/fields/CheckPicker.tsx | 2 +- src/fields/MultiCascader/index.tsx | 2 +- src/fields/MultiSelect.tsx | 2 +- src/fields/NumberInput.tsx | 2 +- src/fields/PhoneInput.tsx | 2 +- src/fields/Search.tsx | 2 +- src/fields/Select.tsx | 2 +- src/fields/TextInput.tsx | 2 +- src/fields/Textarea.tsx | 2 +- src/fields/Toggle/index.tsx | 2 +- stories/elements/Label.stories.tsx | 4 ++-- 12 files changed, 20 insertions(+), 20 deletions(-) diff --git a/src/elements/Label.tsx b/src/elements/Label.tsx index 8eac78f53..5d6949440 100644 --- a/src/elements/Label.tsx +++ b/src/elements/Label.tsx @@ -4,10 +4,10 @@ import styled from 'styled-components' import type { LabelHTMLAttributes } from 'react' export type LabelProps = LabelHTMLAttributes & { - $isHidden?: boolean | undefined $isRequired?: boolean | undefined disabled?: boolean | undefined hasError?: boolean | undefined + isHidden?: boolean | undefined } export const Label = styled.label.attrs(props => ({ className: classnames('Element-Label', props.className) @@ -26,13 +26,13 @@ export const Label = styled.label.attrs(props => ({ color: ${p.theme.color.maximumRed}; }`} ${p => - p.$isHidden && + p.isHidden && ` - position:absolute; - left:-10000px; - top:auto; - width:1px; - height:1px; - overflow:hidden; + position:absolute; + left:-10000px; + top:auto; + width:1px; + height:1px; + overflow:hidden; `} ` diff --git a/src/fields/CheckPicker.tsx b/src/fields/CheckPicker.tsx index d6b2e1187..3f3f657df 100644 --- a/src/fields/CheckPicker.tsx +++ b/src/fields/CheckPicker.tsx @@ -127,7 +127,7 @@ export function CheckPicker({ return ( -