CSS cleanup: dead CSS removal, !important reduction, missing CSS, pseudo-element syntax, dead macros - #203
Draft
1aeo wants to merge 4 commits into
Draft
CSS cleanup: dead CSS removal, !important reduction, missing CSS, pseudo-element syntax, dead macros#2031aeo wants to merge 4 commits into
1aeo wants to merge 4 commits into
Conversation
Co-authored-by: 1aeo <1aeo@users.noreply.github.com>
Contributor
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
…udo-element syntax Dead CSS removed (10 selectors from aroi-leaderboards.css): - .aroi-flex-nav, .aroi-nav-spacing, .aroi-primary-nav, .aroi-category-nav - .aroi-compact-nav-row, .aroi-nav-label, .aroi-nav-separator - .aroi-top-margin, .aroi-contact-link Dead CSS removed (1 selector from allium-base.css): - .al-section-title (unused utility) - Annotated .al-box-success/.al-box-info/.al-box-primary as unused but kept to complete the semantic design system set !important reduction (5 declarations across 2 files): - allium-base.css: navbar-collapse desktop override (3 props) — mutually exclusive media queries make !important unnecessary - aroi-leaderboards.css: badge hover box-shadow — higher specificity wins - aroi-leaderboards.css: pagination section hide — higher specificity wins Missing CSS added: - relay-info.css: .row-not-voted (dim non-voting authority rows) - aroi-leaderboards.css: .aroi-validation-table column widths - aroi-leaderboards.css: .aroi-ip-address-table column widths - aroi-leaderboards.css: .pagination-nav styling (matches .pagination-nav-bottom) Pseudo-element syntax (docs mockup): - Updated :before/:after to ::before/::after in authorities-page-mockup.html - Added comment documenting the tooltip CSS duplication with allium-base.css Co-authored-by: 1aeo <1aeo@users.noreply.github.com>
…not-voted opacity - .pagination-nav styling reverted: class only used by dead macros (paginated_ranking_table and top5_paginated_ranking_table are defined but never called). All active call sites use pagination_section macro which only uses .pagination-nav-bottom. - .row-not-voted opacity bumped from 0.5 to 0.55 for better readability of links and status indicators within dimmed authority rows. Co-authored-by: 1aeo <1aeo@users.noreply.github.com>
- Remove paginated_ranking_table macro (defined but never called, 88 lines) - Remove top5_paginated_ranking_table macro (defined but never called, 106 lines) - Remove dead import of top5_paginated_ranking_table from aroi-leaderboards.html - Both macros had latent bugs: pagination IDs (-1-25, -1-5) didn't match the CSS default-show rules ([id$="-1-10"]), so no page would show by default - Fix 4 stale comments in allium-base.css that referenced .html template files instead of the actual .css files where styles were moved: relay-info.html → relay-info.css aroi-leaderboards.html → aroi-leaderboards.css network-health-dashboard.html → network-health.css api-diagnostics.html → api-diagnostics.css Co-authored-by: 1aeo <1aeo@users.noreply.github.com>
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.
CSS Cleanup — Dead CSS, !important reduction, missing CSS, pseudo-element syntax, dead macros
Pure CSS + template housekeeping — no behavioral changes, zero HTML output diff.
Dead CSS Removed (11 selectors)
aroi-leaderboards.css(10 selectors):.aroi-flex-nav,.aroi-nav-spacing(+h4),.aroi-primary-nav,.aroi-category-nav.aroi-compact-nav-row,.aroi-nav-label,.aroi-nav-separator.aroi-top-margin,.aroi-contact-linkallium-base.css(1 selector):.al-section-title.al-box-success/.al-box-info/.al-box-primaryannotated as unused but kept to complete the semantic design system setDead Macros Removed (194 lines)
aroi_macros.html:paginated_ranking_table(88 lines) — defined but never calledtop5_paginated_ranking_table(106 lines) — imported but never called-1-25,-1-5) didn't match the CSS default-show rules ([id$="-1-10"]), so no page would show by default if reactivatedaroi-leaderboards.html!importantReduction (5 → 0 removable; 5 justified keeps)navbar-collapse { display/height/overflow }(3)min-width: 768pxvsmax-width: 767px) — no competing rules.panel-body:hover { box-shadow }.pagination-section:target ~ ...Remaining 5
!importantusages are justified (documented in code comments):!importanton.hidden-xs/.visible-xs:targethighlight (1): Required to override inlinestyle="background:..."attributesMissing CSS Added
.row-not-voted.aroi-validation-table.aroi-ip-address-tablePseudo-element Syntax
:before/:after→::before/::afterinauthorities-page-mockup.htmlallium-base.cssStale Comments Fixed
Fixed 4 comments in
allium-base.cssthat referenced.htmltemplate files instead of the actual.cssfiles where styles were moved:relay-info.html→relay-info.cssaroi-leaderboards.html→aroi-leaderboards.cssnetwork-health-dashboard.html→network-health.cssapi-diagnostics.html→api-diagnostics.cssVerification
Out of Scope (as agreed)
style="..."attributes → separate effortstyle="color: #28a745"to CSS classes