Repository navigation
Dark theme for the reconnect dialog - #19
Merged
Merged
Conversation
The dialog still had the template's light styling. It now uses the app's theme variables, and its buttons look like the app's primary buttons.
|
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.



The reconnect dialog ("Rejoining the server…", "Failed to rejoin. Please retry or reload the page.") still had the
Blazor template's light styling: a white box, light blue buttons and a blue spinner on the dark app.
Changes
Only
ReconnectModal.razor.css; the markup andReconnectModal.razor.jsare unchanged.var(--card)background,var(--line)border,var(--text)text (without it the browser's defaultdialog text colour, which is dark, applies), 16px corners, darker shadow. The width shrinks on narrow phones
(
min(20rem, 100% - 32px)).var(--muted).rgba(0,0,0,.6), as the app's.overlay..btn.primary(accent green, white text, 14px corners). Pressing dims the button instead ofthe template's blue hover colour, which sticks after a tap on a phone. The focus ring is the theme's text colour,
so it shows on the dark background.
var(--accent).Contrast: white on the accent green is about 3.4:1. The button text is 1.1rem bold (18.7px with the app's 17px
base), which counts as large text in WCAG, so 3:1 applies. This replaces the template's white on
#6b9ed2, whichwas accepted in SonarCloud as S7924.
Testing
CSS only; bUnit doesn't render styles. Checked with screenshots at phone size (390×844) in headless Edge, before
and after, for every state of the dialog (rejoining, retrying, failed, paused, resume failed), shown by setting the
dialog's state classes the way Blazor does. Still to check on a real phone.