We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0862570 commit d6a7e6fCopy full SHA for d6a7e6f
helix-term/src/ui/completion.rs
@@ -92,8 +92,11 @@ impl menu::Item for CompletionItem {
92
value, ..
93
}) => value,
94
};
95
- Color::from_hex(text)
+ // Language servers which send Color completion items tend to include a 6
96
+ // digit hex code at the end for the color. The extra 1 digit is for the '#'
97
+ text.get(text.len().checked_sub(7)?..)
98
})
99
+ .and_then(Color::from_hex)
100
.map_or("color".into(), |color| {
101
Spans::from(vec![
102
Span::raw("color "),
0 commit comments