mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-31 20:28:09 +01:00
fix(useFormField): optional property access (#2226)
This commit is contained in:
@@ -18,7 +18,7 @@ export const useFormGroup = (inputProps?: InputProps, config?: any, bind: boolea
|
|||||||
const formInputs = inject<any>('form-inputs', undefined)
|
const formInputs = inject<any>('form-inputs', undefined)
|
||||||
|
|
||||||
if (formGroup) {
|
if (formGroup) {
|
||||||
if (!bind || inputProps.legend) {
|
if (!bind || inputProps?.legend) {
|
||||||
formGroup.inputId.value = undefined
|
formGroup.inputId.value = undefined
|
||||||
} else if (inputProps?.id) {
|
} else if (inputProps?.id) {
|
||||||
// Updates for="..." attribute on label if inputProps.id is provided
|
// Updates for="..." attribute on label if inputProps.id is provided
|
||||||
|
|||||||
Reference in New Issue
Block a user