Skip to content

Commit bb3abd5

Browse files
Remove redundant CSS variables from Footer component
Following the same pattern as NavBar, removed CSS variables that were: - Set to hardcoded static color values in JSX - Had identical fallback values in CSS - Not derived from theme.ts - Never changed at runtime (hardcoded in original styled-components) Removed redundant variables: - --footer-top-bg (was '#424242', now plain CSS) - --footer-bottom-bg (was '#3b3b3b', now plain CSS) These colors were hardcoded in the original styled-components (not from theme), so they should be plain CSS values, not CSS variables. Kept theme-derived variables (correct usage): - --footer-text-color (from theme.color.text.label) - --footer-social-icon-bg (from theme.color.primary.gray.light) - --footer-social-icon-color (computed hex value) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
1 parent 2500e7d commit bb3abd5

2 files changed

Lines changed: 5 additions & 20 deletions

File tree

src/app/components/Footer/Footer.css

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,7 @@
4242

4343
/* Top section */
4444
.footer-top {
45-
background-color: var(--footer-top-bg, #424242);
45+
background-color: #424242;
4646
}
4747

4848
/* Top section responsive padding */
@@ -348,7 +348,7 @@
348348
font-weight: normal;
349349
letter-spacing: normal;
350350
line-height: normal;
351-
background-color: var(--footer-bottom-bg, #3b3b3b);
351+
background-color: #3b3b3b;
352352
}
353353

354354
@media (min-width: 37.6em) {

src/app/components/Footer/index.tsx

Lines changed: 3 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -368,12 +368,7 @@ const NormalFooter = ({
368368
data-analytics-region='footer'
369369
>
370370
<div className="footer-inner">
371-
<div
372-
className="footer-top"
373-
style={{
374-
'--footer-top-bg': '#424242',
375-
} as React.CSSProperties}
376-
>
371+
<div className="footer-top">
377372
<div className="footer-top-boxed">
378373
<h2 className="footer-heading">
379374
<BareMessage id='i18n:footer:heading' />
@@ -384,12 +379,7 @@ const NormalFooter = ({
384379
<Column3 />
385380
</div>
386381
</div>
387-
<div
388-
className="footer-bottom"
389-
style={{
390-
'--footer-bottom-bg': '#3b3b3b',
391-
} as React.CSSProperties}
392-
>
382+
<div className="footer-bottom">
393383
<div className="footer-bottom-boxed">
394384
<Copyrights values={getValues()} />
395385
<SocialDirectory />
@@ -533,12 +523,7 @@ const PortalFooter = ({
533523
data-testid='portal-footer'
534524
>
535525
<div className="footer-inner">
536-
<div
537-
className="footer-bottom"
538-
style={{
539-
'--footer-bottom-bg': '#3b3b3b',
540-
} as React.CSSProperties}
541-
>
526+
<div className="footer-bottom">
542527
<div className="footer-portal-bottom-boxed">
543528
<PortalColumn1 />
544529
<PortalColumn2 portalName={portalName} />

0 commit comments

Comments
 (0)