-
Notifications
You must be signed in to change notification settings - Fork 158
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
Update to bootstrap 5. #844
Conversation
The dark theme looks really good!
I actually started something similar a while back on https://github.com/fslaborg/docs-template. the gist is that i used Bulma instead of bootstrap, which is a css only framework and can be customized via sass and variables. It is distributed as If any css variable-based customization would find its way directly into this library, i think that would be the starting point for an actual templating system. That can be installed directly via |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
❤️ this. Left something to consider.
} | ||
} | ||
|
||
toggleTheme() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's worth considering using prefers-color-scheme so we use whatever someone's systems defaults are.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I know it's not as tidy as a toggle button but I think respecting the user's system theme is more important. Some example code: code
I wonder if we should consider "outsourcing" code syntax to something like highlight.js (This is more future work, shouldn't block merging this tho) |
I'm ok with this! |
Thanks all for the feedback. I'm still on the fence about using bootstrap or not. It could make things easier to theme, have fewer dependencies and foresee the light/dark from the start. |
Hi @Freymaurer |
Closing in favour of #861 |
This PR gives the default template a facelift with Bootstrap 5. This update makes it smoother to switch between light and dark modes, thanks to Bootstrap v5.3.
I also borrowed some ideas from Jimmy, which you can check out in this comment.
Take a peek at the new look:
Now, I'm wondering if it's time to rethink our reliance on Bootstrap. Maybe it's more convenient to start fresh with a custom CSS theme using CSS variables for just about everything. This way, we can effortlessly handle light and dark modes from the get-go and maintain it easily. If we decide to tweak the default theme, users can do so by overriding a bunch of CSS variables.
Let's chat about this! Tagging some folks who know this repo: @dsyme, @nhirschey, @baronfel, @kMutagene, and @TheAngryByrd.