MCPcopy Create free account
hub / github.com/anomalyco/opencode / commandDisabled

Function commandDisabled

packages/app/src/components/windows-app-menu.tsx:23–27  ·  view source on GitHub ↗
(id: string)

Source from the content-addressed store, hash-verified

21 lastFocused = active instanceof HTMLElement ? active : undefined
22 }
23 const commandDisabled = (id: string) => {
24 const option = props.command.options.find((option) => option.id === id)
25 if (!option) return true
26 return option.disabled ?? false
27 }
28 const runCommand = (id: string) => {
29 if (commandDisabled(id)) return
30 props.command.trigger(id)

Callers 2

runCommandFunction · 0.85
WindowsAppMenuFunction · 0.85

Calls 1

findMethod · 0.65

Tested by

no test coverage detected