mirror of
https://github.com/utopia-os/utopia-ui.git
synced 2025-12-13 07:46:10 +00:00
fix simple form issze
This commit is contained in:
parent
627fab28ac
commit
d7a757c75d
@ -130,7 +130,7 @@ export function ProfileForm({ userType }: { userType: string }) {
|
||||
)}
|
||||
|
||||
{template == "simple" &&
|
||||
<SimpleForm item={item} state={state} setState={setState}></SimpleForm>
|
||||
<SimpleForm state={state} setState={setState}></SimpleForm>
|
||||
}
|
||||
|
||||
{template == "tabs" &&
|
||||
|
||||
@ -1,10 +1,16 @@
|
||||
import { TextAreaInput } from "../../Input"
|
||||
import { TextAreaInput } from "../../Input";
|
||||
|
||||
export const SimpleForm = (item, setState) => {
|
||||
export const SimpleForm = ({ state, setState }) => {
|
||||
return (
|
||||
<TextAreaInput placeholder="About me ..." defaultValue={item?.text ? item.text : ""} updateFormValue={(v) => setState(prevState => ({
|
||||
...prevState,
|
||||
text: v
|
||||
}))} containerStyle='tw-mt-8 tw-h-full' inputStyle='tw-h-full' />
|
||||
)
|
||||
}
|
||||
<TextAreaInput
|
||||
placeholder="About me ..."
|
||||
defaultValue={state?.text || ""}
|
||||
updateFormValue={(v) => setState(prevState => ({
|
||||
...prevState,
|
||||
text: v
|
||||
}))}
|
||||
containerStyle='tw-mt-8 tw-h-full'
|
||||
inputStyle='tw-h-full'
|
||||
/>
|
||||
);
|
||||
};
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user