fix: remove key replicate

This commit is contained in:
Joel
2024-04-02 18:30:48 +08:00
parent 1c004e0df6
commit 716936e37a
2 changed files with 4 additions and 4 deletions

View File

@ -47,7 +47,7 @@ const useKeyValueList = (value: string, onChange: (value: string) => void, noFil
}] = useBoolean(true)
return {
list: list.length === 0 ? [{ key: '', value: '' }] : list, // no item can not add new item
list: list.length === 0 ? [{ id: uniqueId(UNIQUE_ID_PREFIX), key: '', value: '' }] : list, // no item can not add new item
setList,
addItem,
isKeyValueEdit,