Question Bank

CSS Theming and Custom Properties Quiz

Difficulty: Medium

Three drills on theming with CSS custom properties: declaring a token set, switching themes at runtime, and respecting the OS prefers-color-scheme setting.

Question Bank
/

CSS Theming and Custom Properties Quiz

CSS Theming and Custom Properties Quiz

Three drills on theming with CSS custom properties: declaring a token set, switching themes at runtime, and respecting the OS prefers-color-scheme setting.

Question Bank
Medium
CSS
3 questions
quiz
css-variables
css-responsive-design
accessibility

1,010 views

18

Define a light theme as CSS custom properties scoped to :root, and consume them in a .card rule. Why is this better than hardcoding colors in every component?