Getting startedComponentsDesign tokensThemingTheme synthesizerFrameworksAccessibilityUtilitiesServer renderingBrowser supportContributingChangelogApp ShellAspect GridAuth ShellCenterContainerDashboard GridFloat BarInsetMasonryPage HeaderPage LayoutResizableResponsive SwitcherSectionSettings LayoutSplit PaneStatus BarStickyToolbarAnchor NavBottom NavBreadcrumbBreadcrumb MenuCommand BarDrawerFooterLinkMenubarNavigation MenuPage IndicatorPaginationRailScroll IndicatorScroll SpyScroll To TopSidebarSkip LinkStepper NavTabsTop BarTree ViewAccordionAspect RatioAvatarAvatar GroupCardCarouselCollapsibleColor SwatchCTA BannerDividerEmpty StateFeature CardIconImageImage CompareImage HotspotsInfinite ScrollLightboxMarqueeQR CodeScroll AreaSkeletonSpinnerStackVideoVirtual ListActivity HeatmapAnimated NumberBadgeBar ListChartClockComparisonCountdown TimerData GridDescription ListDiffGaugeJSON TreeKanbanLevel MeterListMeterSparklineStatStepperTagTimelineUptimeValue CardWaveformBlockquoteCode BlockCode GroupGradient TextHighlightKbdKeyboard MapMarkdownNumber FormatProseTerminalTextTime AgoTruncateTypewriterButtonButton GroupCalendarCheckboxChipColor PickerComboboxCopy ButtonDate PickerDate Range PickerField ListFieldsetFile UploadFormHotkeyIcon ButtonImage CropperInline EditInputInput GroupKnobLabelMasked InputMulti SelectNumber InputPassword InputPin InputRadio GroupRange SliderRatingSearchSegmented ControlSelectSignature PadSliderSortable ListSwitch GroupTag InputTextareaTheme ToggleTime PickerToggleTransfer ListTree SelectAlertAnnouncementBannerCommand PaletteConfirmConnection StatusContext MenuConversationDialogDropdown MenuHover CardLoading OverlayNotification PanelPopoverProgressSheetToastTooltip
ARC UIARC Radiant Components
v4.9DocsComponentsTokensSynthesizer
Getting startedFrameworksServer renderingDesign tokensThemingTheme synthesizerTypographyUtilitiesAll componentsAccessibilityBrowser supportChangelogContributingStatsApp ShellAspect GridAuth ShellCenterContainerDashboard GridFloat BarInsetMasonryPage HeaderPage LayoutResizableResponsive SwitcherSectionSettings LayoutSplit PaneStatus BarStickyToolbarAnchor NavBottom NavBreadcrumbBreadcrumb MenuCommand BarDrawerFooterLinkMenubarNavigation MenuPage IndicatorPaginationRailScroll IndicatorScroll SpyScroll To TopSidebarSkip LinkStepper NavTabsTop BarTree ViewAccordionAspect RatioAvatarAvatar GroupCardCarouselCollapsibleColor SwatchCTA BannerDividerEmpty StateFeature CardIconImageImage CompareImage HotspotsInfinite ScrollLightboxMarqueeQR CodeScroll AreaSkeletonSpinnerStackVideoVirtual ListActivity HeatmapAnimated NumberBadgeBar ListChartClockComparisonCountdown TimerData GridDescription ListDiffGaugeJSON TreeKanbanLevel MeterListMeterSparklineStatStepperTagTimelineUptimeValue CardWaveformBlockquoteCode BlockCode GroupGradient TextHighlightKbdKeyboard MapMarkdownNumber FormatProseTerminalTextTime AgoTruncateTypewriterButtonButton GroupCalendarCheckboxChipColor PickerComboboxCopy ButtonDate PickerDate Range PickerField ListFieldsetFile UploadFormHotkeyIcon ButtonImage CropperInline EditInputInput GroupKnobLabelMasked InputMulti SelectNumber InputPassword InputPin InputRadio GroupRange SliderRatingSearchSegmented ControlSelectSignature PadSliderSortable ListSwitch GroupTag InputTextareaTheme ToggleTime PickerToggleTransfer ListTree SelectAlertAnnouncementBannerCommand PaletteConfirmConnection StatusContext MenuConversationDialogDropdown MenuHover CardLoading OverlayNotification PanelPopoverProgressSheetToastTooltip

Theming

ARC UI's colors come from CSS custom properties. One attribute switches the mode, and overriding tokens gives you a theme of your own.

How themes work

The data-theme attribute on <html> sets the mode. There are three:

Darkdata-theme="dark"The default. Near-black surfaces with blue and violet accents.Lightdata-theme="light"Light backgrounds, with darker accents for contrast.Autodata-theme="auto"Follows the OS setting through prefers-color-scheme.

Components restyle as soon as the attribute changes. On this site, the toggle in the top bar changes it.

Dark mode

Dark is the default, so the attribute is optional.

The background tokens, rendered on this page:

--bg-deep--bg-surface--bg-card--bg-elevated

Light mode

In light mode, shadows are tinted with the accent colors instead of black.

Auto mode

Auto follows the OS setting through prefers-color-scheme. To keep a visitor's own choice across visits, store it and restore it on load:

arc-theme-toggle does this for you. It stores the choice in localStorage under arc-theme.

Fixed regions

.theme-fixed-dark and .theme-fixed-light keep a subtree in one scheme whatever the page theme is, for regions like a nav, a footer or a command bar. The class applies the same scheme the library generates for :root, so a pinned region has the contrast that scheme was tuned for.

On a page in the same scheme, a pinned region matches the page: a dark nav on a dark page is near-black. On a page in the other scheme it stops short, because near-black against near-white would be the hardest edge on the page. It uses a deep color derived from your accent instead. This site's top bar and footer work this way, and in light mode they're deep blue.

That color takes its hue from --accent-primary and its lightness from the scheme, so overriding your accent recolors pinned regions too. A teal accent gives a deep teal nav, and a gray one stays gray. A browser without relative color syntax keeps the default blue in pinned regions.

Custom themes

Gradients, glows and focus rings read the accent tokens through var(). Override the two accents and their -rgb triplets (used for transparency) and those follow:

The button below applies those four lines to this page:

Apply the override
When you override accent or background tokens, keep text at 4.5:1 contrast and UI elements at 3:1.

Theme Synthesizer

The Theme Synthesizer edits colors, fonts, type sizes, spacing, radii, layout sizes and durations with a live preview. It exportsarc-theme.css with only the tokens you changed, to load afterbase.css.

See also