Make completion docs scrollable
This commit is contained in:
parent
e8be14e5d6
commit
ca88717f0c
1 changed files with 15 additions and 11 deletions
|
@ -1064,18 +1064,22 @@ impl CompletionsMenu {
|
||||||
.languages()
|
.languages()
|
||||||
.clone();
|
.clone();
|
||||||
let language = self.buffer.read(cx).language().map(Arc::clone);
|
let language = self.buffer.read(cx).language().map(Arc::clone);
|
||||||
|
|
||||||
|
enum CompletionDocsMarkdown {}
|
||||||
Some(
|
Some(
|
||||||
crate::markdown::render_markdown(
|
Flex::column()
|
||||||
&content.value,
|
.scrollable::<CompletionDocsMarkdown>(0, None, cx)
|
||||||
®istry,
|
.with_child(crate::markdown::render_markdown(
|
||||||
&language,
|
&content.value,
|
||||||
&style,
|
®istry,
|
||||||
cx,
|
&language,
|
||||||
)
|
&style,
|
||||||
.constrained()
|
cx,
|
||||||
.with_width(alongside_docs_width)
|
))
|
||||||
.contained()
|
.constrained()
|
||||||
.with_style(alongside_docs_container_style),
|
.with_width(alongside_docs_width)
|
||||||
|
.contained()
|
||||||
|
.with_style(alongside_docs_container_style),
|
||||||
)
|
)
|
||||||
} else {
|
} else {
|
||||||
None
|
None
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue