Reafactor/UI input and displays (#1544)

* WIP

* Text field

* URL

* Finished PhoneInput

* Refactored input sub-folders

* Boolean

* Fix lint

* Fix lint

* Fix useOutsideClick

---------

Co-authored-by: Charles Bochet <charles@twenty.com>
This commit is contained in:
Lucas Bordeau
2023-09-12 02:11:20 +02:00
committed by GitHub
parent 509ffddc57
commit a766c60aa5
90 changed files with 618 additions and 461 deletions

View File

@ -14,7 +14,7 @@ import { currentUserState } from '@/auth/states/currentUserState';
import { ProfilePictureUploader } from '@/settings/profile/components/ProfilePictureUploader';
import { PageHotkeyScope } from '@/types/PageHotkeyScope';
import { MainButton } from '@/ui/button/components/MainButton';
import { TextInput } from '@/ui/input/text/components/TextInput';
import { TextInputSettings } from '@/ui/input/text/components/TextInputSettings';
import { useSnackBar } from '@/ui/snack-bar/hooks/useSnackBar';
import { H2Title } from '@/ui/typography/components/H2Title';
import { useScopedHotkeys } from '@/ui/utilities/hotkey/hooks/useScopedHotkeys';
@ -145,7 +145,7 @@ export function CreateProfile() {
field: { onChange, onBlur, value },
fieldState: { error },
}) => (
<TextInput
<TextInputSettings
autoFocus
label="First Name"
value={value}
@ -165,7 +165,7 @@ export function CreateProfile() {
field: { onChange, onBlur, value },
fieldState: { error },
}) => (
<TextInput
<TextInputSettings
label="Last Name"
value={value}
onBlur={onBlur}

View File

@ -11,7 +11,7 @@ import { Title } from '@/auth/components/Title';
import { WorkspaceLogoUploader } from '@/settings/workspace/components/WorkspaceLogoUploader';
import { PageHotkeyScope } from '@/types/PageHotkeyScope';
import { MainButton } from '@/ui/button/components/MainButton';
import { TextInput } from '@/ui/input/text/components/TextInput';
import { TextInputSettings } from '@/ui/input/text/components/TextInputSettings';
import { useSnackBar } from '@/ui/snack-bar/hooks/useSnackBar';
import { H2Title } from '@/ui/typography/components/H2Title';
import { useScopedHotkeys } from '@/ui/utilities/hotkey/hooks/useScopedHotkeys';
@ -122,7 +122,7 @@ export function CreateWorkspace() {
field: { onChange, onBlur, value },
fieldState: { error },
}) => (
<TextInput
<TextInputSettings
autoFocus
value={value}
placeholder="Apple"