MCPcopy Index your code
hub / github.com/codeaashu/claude-code / getMultiSelectLabel

Function getMultiSelectLabel

src/utils/mcp/elicitationValidation.ts:93–99  ·  view source on GitHub ↗
(
  schema: MultiSelectEnumSchema,
  value: string,
)

Source from the content-addressed store, hash-verified

91 * Get label for a specific value in a multi-select enum
92 */
93export function getMultiSelectLabel(
94 schema: MultiSelectEnumSchema,
95 value: string,
96): string {
97 const index = getMultiSelectValues(schema).indexOf(value)
98 return index >= 0 ? (getMultiSelectLabels(schema)[index] ?? value) : value
99}
100
101/**
102 * Get enum values from EnumSchema (handles both legacy `enum` and new `oneOf` formats)

Callers 2

ElicitationFormDialogFunction · 0.85
renderFormFieldsFunction · 0.85

Calls 2

getMultiSelectValuesFunction · 0.85
getMultiSelectLabelsFunction · 0.85

Tested by

no test coverage detected