diff options
| author | it-fixcomart <it@fixcomart.co.id> | 2024-09-23 16:13:10 +0700 |
|---|---|---|
| committer | it-fixcomart <it@fixcomart.co.id> | 2024-09-23 16:13:10 +0700 |
| commit | c0a72c10864ee5e70ebfba4718be25eba910ccf0 (patch) | |
| tree | 81e7264957b943b00f36e45593653e0dfb848fb7 /src/lib/auth | |
| parent | f404f9801db1f234ae03ec9c9542ba5d4aa1bf46 (diff) | |
<iman> update mobile view
Diffstat (limited to 'src/lib/auth')
| -rw-r--r-- | src/lib/auth/components/SwitchAccount.jsx | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/src/lib/auth/components/SwitchAccount.jsx b/src/lib/auth/components/SwitchAccount.jsx index e737ef6a..18c6076f 100644 --- a/src/lib/auth/components/SwitchAccount.jsx +++ b/src/lib/auth/components/SwitchAccount.jsx @@ -13,7 +13,9 @@ import { useRegisterStore } from '~/modules/register/stores/useRegisterStore.ts' import { registerUser } from '~/services/auth'; import { useMutation } from 'react-query'; import { isValid } from 'zod'; +import useDevice from '@/core/hooks/useDevice'; const SwitchAccount = () => { + const { isDesktop, isMobile } = useDevice(); const auth = useAuth(); const [isOpen, setIsOpen] = useState(true); const toggle = () => setIsOpen(!isOpen); @@ -130,7 +132,11 @@ const SwitchAccount = () => { onClick={toggle} className='p-4 flex items-center text-left w-full' > - <div className='flex flex-row items-center bg-slate-50'> + <div + className={`flex ${ + isDesktop ? 'flex-row' : 'flex-col gap-y-2' + } items-start justify-start bg-slate-50`} + > <div className='flex font-semibold mr-2'>Informasi Bisnis</div> <div className='text-red-500 text-xs'> *Perubahan akun tidak dapat diubah kembali @@ -176,7 +182,7 @@ const SwitchAccount = () => { </RadioGroup> </div> <FormBisnis - type='profil' + type={isDesktop ? 'profil' : 'bisnis'} required={isTerdaftar} isPKP={isPKP} chekValid={notValid} |
