In some cases, a JSDoc summary can end with a :. We should change this by backtracking to a . if one is present and only show the content until then, else still show the summary as-is.
The relevant part of the codebase is
|
fn walk_node_title<'a>(node: &'a AstNode<'a>) { |
|
for child in node.children() { |
|
if matches!( |
|
child.data.borrow().value, |
|
NodeValue::Document |
|
| NodeValue::Paragraph |
|
| NodeValue::Heading(_) |
|
| NodeValue::Text(_) |
|
| NodeValue::Code(_) |
|
| NodeValue::HtmlInline(_) |
|
| NodeValue::Emph |
|
| NodeValue::Strong |
|
| NodeValue::Strikethrough |
|
| NodeValue::Superscript |
|
| NodeValue::Link(_) |
|
| NodeValue::Math(_) |
|
| NodeValue::Escaped |
|
| NodeValue::WikiLink(_) |
|
| NodeValue::Underline |
|
) { |
|
walk_node_title(child); |
|
} else { |
|
// delete the node |
|
child.detach(); |
|
} |
|
} |
|
} |
In some cases, a JSDoc summary can end with a
:. We should change this by backtracking to a.if one is present and only show the content until then, else still show the summary as-is.The relevant part of the codebase is
deno_doc/src/html/jsdoc.rs
Lines 392 to 418 in 93f4ce3