Fix hovering over comments

This commit is contained in:
Laurenz 2023-03-27 17:25:01 +02:00
parent e724d04253
commit b0f87077cc
2 changed files with 4 additions and 0 deletions

View File

@ -30,6 +30,7 @@ description: |
[`location`]($func/locate) type
- Added symbols for double, triple, and quadruple dot accent
- Added smart quotes for Norwegian Bokmål
- Fixed hovering over comments in web app
## March 21, 2023
- Reference and bibliography management

View File

@ -21,6 +21,9 @@ pub fn tooltip(
cursor: usize,
) -> Option<Tooltip> {
let leaf = LinkedNode::new(source.root()).leaf_at(cursor)?;
if leaf.kind().is_trivia() {
return None;
}
named_param_tooltip(world, &leaf)
.or_else(|| font_tooltip(world, &leaf))