MCPcopy Create free account
hub / github.com/ZenNotes/zennotes / shouldYieldToHomeNav

Function shouldYieldToHomeNav

packages/app-core/src/lib/vim-nav.ts:29–38  ·  view source on GitHub ↗
(
  target: HTMLElement | null | undefined,
  isLeaderKey: boolean,
  leaderPending: boolean
)

Source from the content-addressed store, hash-verified

27 * (no note open). (#273)
28 */
29export function shouldYieldToHomeNav(
30 target: HTMLElement | null | undefined,
31 isLeaderKey: boolean,
32 leaderPending: boolean
33): boolean {
34 if (!target?.closest('[data-home-nav]')) return false
35 // Keep leader input flowing through to VimNav's leader handling.
36 if (isLeaderKey || leaderPending) return false
37 return true
38}
39
40// ---------------------------------------------------------------------------
41// Panel types & navigation

Callers 2

handlerFunction · 0.90
vim-nav.test.tsFile · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected