Dark mode#2859
Open
merv1n34k wants to merge 9 commits intoTabbycatDebate:developfrom
Open
Conversation
- Update bootstrap to ^5.3, remove popper.js dependency
- Restructure SCSS imports for BS5 (add variables-dark, maps, root,
containers, helpers, utilities/api; remove print, custom-forms)
- Replace all theme-color() calls with direct $variable references
- Rename data attributes: data-toggle→data-bs-toggle,
data-dismiss→data-bs-dismiss, data-target→data-bs-target,
data-parent→data-bs-parent
- Rename CSS classes: ml-/mr-→ms-/me-, pl-/pr-→ps-/pe-,
float-left/right→float-start/end, text-left/right→text-start/end,
badge-{color}→text-bg-{color}, no-gutters→g-0,
font-weight-*→fw-*, text-monospace→font-monospace,
close→btn-close, custom-select→form-select
- Remove × spans from btn-close buttons (BS5 uses CSS)
- Rewrite Bootstrap JS API: tooltips, alerts, modals use native
BS5 API instead of jQuery plugin methods
- Align bootstrap-custom.scss imports with BS5 structure (remove input-group, move utilities before root per BS5 order) - Replace removed alert-variant mixin and theme-color-level() in layout.scss with simple color inheritance - Rename $table-cell-padding to $table-cell-padding-y in allocations - Fix @extend .pl-3 to .ps-3, remove redundant .gap-3 definition
- Add data-bs-theme attribute to <html> with early inline script to prevent flash of unstyled content - Theme toggle button in navbar cycles: light → dark → auto (system) using sun/moon/monitor feather icons - Preference persisted to localStorage, auto mode follows OS prefers-color-scheme and reacts to OS changes - Dark mode SCSS overrides for Tabbycat-specific colors (tables, sidebar, drag-and-drop, navbar, popovers, outline buttons)
Makes the toggle accessible on all pages including admin views.
Member
|
Have any screenshots of the allocation screens and tooltips? From the present screenshots, I think padding needs to be worked on for the forms, and some minor colour adjustments. |
Contributor
Author
|
Yeah, padding is wrong for sure, I'm debugging it currently I'll add mode screenshots later In general, how do you like it? BS5 removed many BS4 classes, so I think at least for now I will generate shims to revert original look, and we potentially could update templates on later versions Also, how about new checkboxes? Personally, I like the new look more |
- Add .btn-block, .card-deck, .card-columns shims in BS4-compat block - Force white text on .btn-success/.btn-warning/.btn-info (BS5 picks black via color-contrast; flip back to BS4 white). In dark mode the lightened backgrounds need black text instead, so override there too. - Provide CSS-var fallbacks on .list-group-item so orphan items (inside .card without .list-group parent) render with BS4 padding/border/color - Strip card-edge borders on list-group-item children of .card to match BS4 list-group-flush-style separation - Tint BS5.3 focus ring with the primary brand color
Replace #fff/$white/#000/$alt-bg references with var(--bs-body-bg) and var(--bs-body-color) so allocation, drag-and-drop, table, and nav surfaces follow the active theme. Switch bg-white utility usage in DragAndDropDebate and item-submit to bs5 bg-body. Drop the now-unused $alt-bg and $navbar-light-bg variables and remove redundant dark-mode overrides that the source files now handle directly.
Contributor
Author
Contributor
Author
|
Hey @tienne-B! Any updates? |
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.
















Hey!
Closes #2794.
This is a huge feature and in current state the PR is not ready, as many things should be reviewed due to BS5 breaking changes in style.
What was done
sedreplacements), removed poppler.js from dep, now internal in BS5, removed jQuery for BS4 and wired native BS5 JavaScript API.What should be done
Any help and reviews would be appreciated, more pages to be reviewed and improved.





