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

Function isMultiSelectEnumSchema

src/utils/mcp/elicitationValidation.ts:52–62  ·  view source on GitHub ↗
(
  schema: PrimitiveSchemaDefinition,
)

Source from the content-addressed store, hash-verified

50 * Check if schema is a multi-select enum (`type: "array"` with `items.enum` or `items.anyOf`)
51 */
52export function isMultiSelectEnumSchema(
53 schema: PrimitiveSchemaDefinition,
54): schema is MultiSelectEnumSchema {
55 return (
56 schema.type === 'array' &&
57 'items' in schema &&
58 typeof schema.items === 'object' &&
59 schema.items !== null &&
60 ('enum' in schema.items || 'anyOf' in schema.items)
61 )
62}
63
64/**
65 * Get values from a multi-select enum schema

Callers 4

validateMultiSelectFunction · 0.85
handleNavigationFunction · 0.85
ElicitationFormDialogFunction · 0.85
renderFormFieldsFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected