Skip to content

Commit

Permalink
chore: 调整 invalid label 展示, 无数据是展示 -
Browse files Browse the repository at this point in the history
  • Loading branch information
2betop committed Dec 3, 2024
1 parent 8cdf4ab commit c9476d3
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions packages/amis-core/src/utils/labelToString.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@ import isPlainObject from 'lodash/isPlainObject';

export function labelToString(label: any): string {
const type = typeof label;
if (type === 'undefined' || label === null) {
// render placeholder
return '-';
}
if (type === 'string') {
return label;
} else if (type === 'number') {
Expand Down

0 comments on commit c9476d3

Please sign in to comment.