MCPcopy
hub / github.com/darkreader/darkreader / restoreHighlights

Function restoreHighlights

src/background/ui-highlights.ts:25–29  ·  view source on GitHub ↗
(keys: string[])

Source from the content-addressed store, hash-verified

23}
24
25async function restoreHighlights(keys: string[]): Promise<void> {
26 const hiddenHighlights = await getHiddenHighlights();
27 const update = Array.from(new Set([...hiddenHighlights.filter((h) => !keys.includes(h))]));
28 await writeLocalStorage({[KEY_UI_HIDDEN_HIGHLIGHTS]: update});
29}
30
31export default {
32 getHighlightsToShow,

Callers

nothing calls this directly

Calls 2

writeLocalStorageFunction · 0.90
getHiddenHighlightsFunction · 0.85

Tested by

no test coverage detected