Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix accessibility issues #1673

Merged
merged 6 commits into from
Oct 14, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
# Documenter.jl changelog

## Unreleased

* ![Bugfix][badge-bugfix] Fix a few accessibility issues. ([#1673][github-1673])

## Version `v0.27.8`

Expand Down Expand Up @@ -919,6 +922,7 @@
[github-1658]: https://github.com/JuliaDocs/Documenter.jl/pull/1658
[github-1661]: https://github.com/JuliaDocs/Documenter.jl/pull/1661
[github-1665]: https://github.com/JuliaDocs/Documenter.jl/pull/1665
[github-1673]: https://github.com/JuliaDocs/Documenter.jl/pull/1673
[github-1687]: https://github.com/JuliaDocs/Documenter.jl/pull/1687
[github-1691]: https://github.com/JuliaDocs/Documenter.jl/pull/1691
[github-1693]: https://github.com/JuliaDocs/Documenter.jl/issues/1693
Expand Down
2 changes: 1 addition & 1 deletion assets/html/scss/documenter-dark.scss
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ $border-width: 1px;
@import "documenter/utilities";
@import "documenter/variables";

$code: #e74c3c;
$code: #ececec;
$code-background: rgba(255, 255, 255, 0.05);

$documenter-docstring-shadow: none;
Expand Down
3 changes: 3 additions & 0 deletions assets/html/scss/documenter-light.scss
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,9 @@ $warning: #ffdd57;
$danger: #da0b00;
$compat: #1db5c9;

// slightly increase contrast over default l: 48%
$grey: hsl(0, 0%, 42%);

@import "documenter/utilities";
@import "documenter/variables";

Expand Down
4 changes: 4 additions & 0 deletions assets/html/scss/documenter/_patches.scss
Original file line number Diff line number Diff line change
Expand Up @@ -79,3 +79,7 @@ html {
-moz-osx-font-smoothing: auto;
-webkit-font-smoothing: auto;
}

li.no-marker {
list-style: none
}
8 changes: 8 additions & 0 deletions assets/html/scss/documenter/components/_docstring.scss
Original file line number Diff line number Diff line change
Expand Up @@ -47,13 +47,21 @@
@extend .tag;
@extend .is-primary;
@extend .is-size-7;

&:focus {
opacity: 1!important;
}
}
}

&:hover > section > a.docs-sourcelink {
opacity: 0.2;
}

&:focus-within > section > a.docs-sourcelink {
opacity: 0.2;
}

& > section:hover a.docs-sourcelink {
opacity: 1;
}
Expand Down
8 changes: 7 additions & 1 deletion assets/html/themes/documenter-dark.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

43 changes: 25 additions & 18 deletions assets/html/themes/documenter-light.css

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion src/Writers/HTMLWriter.jl
Original file line number Diff line number Diff line change
Expand Up @@ -1490,7 +1490,7 @@ end

function domify(lb::ListBuilder)
@tags ul li
ul(map(e -> isa(e, ListBuilder) ? domify(e) : li(e), lb.es))
ul(map(e -> isa(e, ListBuilder) ? li[".no-marker"](domify(e)) : li(e), lb.es))
end

function domify(ctx, navnode, contents::Documents.ContentsNode)
Expand Down