(schema: MultiSelectEnumSchema)
| 78 | * Get display labels from a multi-select enum schema |
| 79 | */ |
| 80 | export function getMultiSelectLabels(schema: MultiSelectEnumSchema): string[] { |
| 81 | if ('anyOf' in schema.items) { |
| 82 | return schema.items.anyOf.map(item => item.title) |
| 83 | } |
| 84 | if ('enum' in schema.items) { |
| 85 | return schema.items.enum |
| 86 | } |
| 87 | return [] |
| 88 | } |
| 89 | |
| 90 | /** |
| 91 | * Get label for a specific value in a multi-select enum |
no outgoing calls
no test coverage detected