mirror of
https://github.com/roc-lang/roc.git
synced 2025-08-03 11:52:19 +00:00
Add github style links to docs sections
This commit is contained in:
parent
ceacc1792d
commit
cc70413e05
3 changed files with 12 additions and 10 deletions
|
@ -146,7 +146,7 @@ fn render_module_documentation(
|
|||
for entry in &module.entries {
|
||||
match entry {
|
||||
DocEntry::DocDef(doc_def) => {
|
||||
// Only redner entries that are exposed
|
||||
// Only render entries that are exposed
|
||||
if all_exposed_symbols.contains(&doc_def.symbol) {
|
||||
buf.push_str("<section>");
|
||||
|
||||
|
@ -154,7 +154,8 @@ fn render_module_documentation(
|
|||
let href = format!("#{name}");
|
||||
let mut content = String::new();
|
||||
|
||||
push_html(&mut content, "a", vec![("href", href.as_str())], name);
|
||||
push_html(&mut content, "a", vec![("href", href.as_str())], "🔗");
|
||||
push_html(&mut content, "strong", vec![], name);
|
||||
|
||||
for type_var in &doc_def.type_vars {
|
||||
content.push(' ');
|
||||
|
|
|
@ -82,16 +82,16 @@ table tr td {
|
|||
}
|
||||
|
||||
.entry-name a {
|
||||
font-weight: bold;
|
||||
color: var(--violet);
|
||||
visibility: hidden;
|
||||
font-size: 12px;
|
||||
margin-left: -7px;
|
||||
margin-right: 4px;
|
||||
vertical-align: top;
|
||||
}
|
||||
|
||||
.entry-name a:visited {
|
||||
color: var(--violet);
|
||||
}
|
||||
|
||||
.entry-name a:hover {
|
||||
color: var(--green);
|
||||
.entry-name:hover a {
|
||||
visibility: visible;
|
||||
text-decoration: none;
|
||||
}
|
||||
|
||||
.pkg-full-name a {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue