use keymap state for layer visibility (#26246)
This commit is contained in:
parent
18b9cec50d
commit
8dd6448c90
1 changed files with 418 additions and 222 deletions
|
|
@ -89,6 +89,7 @@ type Opts = {
|
|||
renderer?: HostPluginApi["renderer"]
|
||||
attention?: AttentionOpts
|
||||
event?: HostPluginApi["event"]
|
||||
mode?: HostPluginApi["mode"]
|
||||
count?: Count
|
||||
keymap?: HostPluginApi["keymap"]
|
||||
tuiConfig?: Partial<HostPluginApi["tuiConfig"]>
|
||||
|
|
@ -237,6 +238,10 @@ export function createTuiPluginApi(opts: Opts = {}): HostPluginApi {
|
|||
},
|
||||
},
|
||||
keymap,
|
||||
mode: opts.mode ?? {
|
||||
current: () => "base",
|
||||
push: () => () => {},
|
||||
},
|
||||
route: {
|
||||
register: () => {
|
||||
if (count) count.route_add += 1
|
||||
|
|
|
|||
Loading…
Reference in a new issue