Conversation
maelle
reviewed
May 10, 2024
|
|
||
| * If you adjust any colours from the default theme (including the syntax highlighting theme), you should double check that the contrast between the background and foreground doesn't make any text difficult to read. A good place to start is running a representative page of your site through <https://wave.webaim.org>. | ||
|
|
||
| * The default colour of the development version label makes a slightly too low contrast against the pale grey background of the navbar. This colour comes from the bootstrap "danger" colour, so you can fix it by overriding that variable in your `_pkgdown.yml`: |
Collaborator
There was a problem hiding this comment.
Could there be another solution to this, for instance pkgdown setting it if it is not set by the configuration and if there is no Bootswatch theme?
Member
Author
There was a problem hiding this comment.
Possibly, but the idea of just randomly patching one colour from the theme seems unappealing to me, especially since it only affects dev sites and that the purpose of the red is just to highlight that you're looking at a dev version, the text is not actually that important, and the contrast isn't that bad.
Co-authored-by: Maëlle Salmon <maelle.salmon@yahoo.se>
SebKrantz
pushed a commit
to SebKrantz/pkgdown
that referenced
this pull request
Jun 1, 2024
Including advice fixing the colour contrast issue caused by using the danger colour on a light navbar background (and apply that advice to pkgdown itself) Fixes r-lib#2344. Fixes r-lib#2283.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Including advice fixing the colour contrast issue caused by using the danger colour on a light navbar background (and apply that advice to pkgdown itself)
Fixes #2344. Fixes #2283.