clarify label when empty string
This commit is contained in:
@@ -125,12 +125,15 @@
|
||||
|
||||
function parseStringItems(resolvedConfigItems: string[]) {
|
||||
return resolvedConfigItems?.map((item) => {
|
||||
if (!item || typeof item !== 'string') {
|
||||
if (item === null || item === undefined || typeof item !== 'string') {
|
||||
console.error(
|
||||
'When not labeled, MultiSelect component items should be an array of strings.'
|
||||
)
|
||||
return 'not string'
|
||||
}
|
||||
if (item === '') {
|
||||
return 'empty string'
|
||||
}
|
||||
return item
|
||||
})
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user