Open
Conversation
Owner
|
Thanks Tom - this is really cool - I will try to take a look some time next week! |
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.
This adds a "dark" (light text on dark background) alternate colour scheme for readers like me who get very sore eyes 🥲.
Caveat: this currently depends upon the user's browser/OS "dark mode / light mode" setting via CSS media query (i.e. it defaults to the current light scheme). I plan to make an unobtrusive toggle mode button (sequestered to a branch for now), but I'm just starting this PR tentatively now regardless.
I've had a quick look through every chapter and can't see any glaring layout issues. Bootstrap's CSS selectors can be very convoluted and high-specificity, so content changes that do a bunch of weird container nesting could conceivably break something - but likely would do so anyway.
My main focus was on the book content so I still need to do a quick pass of the auxiliary pages.
I'm not wedded to any of the colour choices; feel free to change whatever there. I tried to follow the spirit and palette, but the dark scheme feels a little more "brown" than "beige/manila". I was quite careful to retain the semantic meaning of the syntax highlighting colours in particular, but I haven't checked every section for CSS selectors squashing each other inappropriately/confusingly.
I have ~zero image editing skills so my crudely-darkened background pattern could do with a bit more subtlety. I cleaned up the cute tiled roof header a little; unfortunately it still sticks out a bit on the dark background.
The two biggest changes are the body content width, which is now defined in
emvalues, and pumping up the 13-14px font size to 16px, which is obviously an opinionated change but I really think it's a good default for more relaxed reading (and scaling with browser zoom should stay proportional / look nice).Regardless of acceptance, thanks for the wonderful book!