ENGLISH·COURSE API
    Preparing search index...
    • The visual of the theme switch: a pill track with a sun and a moon, and a thumb that slides to the theme in use with a slight overshoot.

      Parameters

      • isDark: { isDark: boolean; className?: string }

        Whether the thumb sits at the dark end

      Returns Element

      Purely presentational and hidden from assistive technology — the control wearing it (ThemeToggle, the avatar menu's theme item) owns the role, the checked state and the accessible name.

      The thumb carries the icon of the active theme, crossfading and turning as it slides. Every transition is dropped under prefers-reduced-motion.

      44px wide, so the switch alone fits the header's phone width budget.