MCPcopy Create free account
hub / github.com/codeaashu/claude-code / useHasSelection

Function useHasSelection

src/ink/hooks/use-selection.ts:97–104  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

95 * fullscreen mode (selection is only available in alt-screen).
96 */
97export function useHasSelection(): boolean {
98 useContext(StdinContext)
99 const ink = instances.get(process.stdout)
100 return useSyncExternalStore(
101 ink ? ink.subscribeToSelectionChange : NO_SUBSCRIBE,
102 ink ? ink.hasTextSelection : ALWAYS_FALSE,
103 )
104}
105

Callers 1

ModeIndicatorFunction · 0.85

Calls 1

getMethod · 0.65

Tested by

no test coverage detected