Skip to content

Commit d0b5bef

Browse files
authored
Merge pull request #537 from sirasagi62/enable-user-defined-highlights-in-hover-popup
Fix: Add viewer hooks and autocmds to hover popup for consistent highlighting
2 parents cb60188 + 0118386 commit d0b5bef

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

autoload/fern/internal/drawer/hover_popup.vim

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,11 @@ function! s:show() abort
7373
function! s:apply() abort closure
7474
call setbufline('%', 1, line)
7575
call helper.fern.renderer.syntax()
76+
call fern#hook#emit('viewer:syntax', helper)
77+
doautocmd <nomodeline> User FernSyntax
7678
call helper.fern.renderer.highlight()
79+
call fern#hook#emit('viewer:highlight', helper)
80+
doautocmd <nomodeline> User FernHighlight
7781
syntax clear FernRootSymbol
7882
syntax clear FernRootText
7983

0 commit comments

Comments
 (0)