MCPcopy Create free account
hub / github.com/AnukarOP/claude-code-leaked / useSelectionBgColor

Function useSelectionBgColor

source code/hooks/useCopyOnSelect.ts:95–100  ·  view source on GitHub ↗
(selection: Selection)

Source from the content-addressed store, hash-verified

93 * so the selection color tracks the theme live.
94 */
95export function useSelectionBgColor(selection: Selection): void {
96 const [themeName] = useTheme()
97 useEffect(() => {
98 selection.setSelectionBgColor(getTheme(themeName).selectionBg)
99 }, [selection, themeName])
100}

Callers 1

ScrollKeybindingHandlerFunction · 0.85

Calls 3

useThemeFunction · 0.85
getThemeFunction · 0.85
setSelectionBgColorMethod · 0.80

Tested by

no test coverage detected