Fixed
- Oil
<C-t>/<C-s>/<C-h>keybindings intercepted by Obsidian default hotkeys — pressing<C-t>in Oil opened an empty Obsidian tab instead of the file under cursor.<C-s>triggered Obsidian's save and<C-h>triggered search & replace. Root cause: Obsidian's default hotkeys (Ctrl+T= new tab,Ctrl+S= save,Ctrl+H= search & replace) fire at the Electron level before the embeddable editor's vim key handler receives the event. The vim mapping (vim.map('<C-t>', ':oilopentab<CR>', 'normal')) never executed. Fixed by registeringCtrl+T,Ctrl+S,Ctrl+H,Ctrl+L, andCtrl+Con the embeddable editor's ObsidianScope(the same mechanism that already interceptsMod+Enter). Scope-registered keys fire before Obsidian's default hotkeys. Navigation keys (<C-t>,<C-s>,<C-h>) blur the editor before calling the manager action so thesetActiveLeafguard in the embeddable editor allows the new leaf through. Non-navigation keys (<C-l>refresh,<C-c>close) call the manager directly. The ex commands (:oilopent,:oilopensv,:oilopensh,:oilrefresh,:oilclose) continue to work viavim.defineExfor users who prefer typing them. (#93)- Plugin:
src/editors/embeddable-editor.ts(registerScopeKey()method onEmbeddableMarkdownEditorinterface andConcreteEmbeddableEditorclass — delegates to the internal ObsidianScope),src/oil/oil-view.ts(registerOilScopeKeys()— registers 5 Ctrl-key combos on the editor scope with blur-before-navigate for cross-leaf actions)
- Plugin:
Tests
- 1 e2e test in
test/specs/oil-poc.e2e.ts:<C-t>opens file in new tab and focuses it (regression test — verifies active file is the target, active view type is markdown, Oil view still exists, leaf count increased)
Full Changelog: 0.91.0...0.92.0