NORY-47: configure default values for JSON inputs
This commit is contained in:
parent
a7c13d27f5
commit
9a2e349340
1 changed files with 4 additions and 2 deletions
|
@ -34,8 +34,10 @@ export function IdentityTraitForm({ schema, identity }: IdentityTraitFormProps)
|
|||
resolver: zodResolver(zodIdentitySchema),
|
||||
defaultValues: {
|
||||
...currentIdentity.traits,
|
||||
metadata_public: currentIdentity.metadata_public ? JSON.stringify(currentIdentity.metadata_public) : '',
|
||||
metadata_admin: currentIdentity.metadata_admin ? JSON.stringify(currentIdentity.metadata_admin) : '',
|
||||
metadata_public: currentIdentity.metadata_public ?
|
||||
JSON.stringify(currentIdentity.metadata_public) : '{}',
|
||||
metadata_admin: currentIdentity.metadata_admin ?
|
||||
JSON.stringify(currentIdentity.metadata_admin) : '{}',
|
||||
},
|
||||
});
|
||||
|
||||
|
|
Loading…
Add table
Reference in a new issue