- const prefix = uiState.name.replace('id', '');
- return (prefix ? changeCase.param(prefix) + '-' : '') + guid(5);
+ // if there is only one key property and we were given a
+ // unique name (probably because creating a list entry
+ // property) then use the unique name otherwise make one up.
+ if (parentMeta.key.length > 1 || !uniqueName) {
+ const prefix = uiState.name.replace('id', '');
+ uniqueName = (prefix ? changeCase.param(prefix) + '-' : '') + guid(5);
+ }
+ return uniqueName;