Skip to main content

Fluent Skin

Concept​

Milestone: v1, built alongside M3 to M8 (ADR-38)

Fluent ships in v0.1 with Minimal, on Kotlin and Flutter. Each milestone adds the Fluent renderers for its components; Acrylic comes with the overlays (M6) and Mica with the navigation chrome (M8). Graft, the author's desktop git client, is its first app.

1. Why​

FluentSkin renders Camouflage in Microsoft's Fluent 2 dialect: calm neutral surfaces, 4 px corners, subtle hover states, a brand color used sparingly, and the Acrylic and Mica materials on Windows. It's the natural dialect for desktop apps (Windows especially) and for enterprise tools. Structurally it's close to Minimal and Material, so it mostly swaps the surface treatment, feedback and proportions, which is the reuse the architecture was designed for.

2. Shape​

Interaction feedback: Subtle. Hover and pressed shift the background one or two neutral steps (Fluent's …Hover / …Pressed tokens). The focus indicator is Fluent's double stroke (2 px dark outer + 1 px light inner).

Surface treatments:

  • Solid: the default everywhere.
  • Acrylic: blur + noise texture + tint, for menus, flyouts and dialogs.
  • Mica: a wallpaper-tinted window background. It's desktop-only, and falls back to Solid elsewhere.

3. API​

fun fluentSkin(surface: FluentSurface = Solid): CamoSkin // Solid | Acrylic | Mica
fun fluentTheme(brand: Color = FluentBrandBlue, dark: Boolean = false, fontFamily: FontFamily? = null): CamoTheme

Starter theme: the Fluent 2 neutral ramp → surfaces (neutralBackground1..6), neutralForeground1..3 → onSurface/onSurfaceVariant, neutralStroke1/2 → outline/outlineVariant, and the brand ramp (from the brand color, Fluent's 16-step ramp) → the primary family. Status: danger/success/warning palettes, and info from the brand. Typography: Segoe UI Variable on Windows, the platform font elsewhere (not bundled; an app may add its own via fluentTheme(fontFamily = …)), with Fluent's type ramp (caption1 12, body1 14, subtitle2 16 semibold, subtitle1 20, title3 24, title2 28, title1 32, largeTitle 40, display 68). Values are taken from Fluent's published token set at implementation time.

3.1 Dialect alignment​

AppearanceFluent rendering
SolidPrimary button: brand fill, white text
SoftDefault/Secondary button: neutralBackground1 + neutralStroke1 border
Raised→ Soft
OutlineOutline button: transparent + stroke
GhostSubtle / Transparent button
LinkLink
ToneFluent
Error / Success / Warningdanger / success / warning palettes
Infobrand (Fluent has no separate info palette)

3.2 Component mapping​

ComponentFluent equivalentRendering
CamoButton / IconButtonButton (+ icon-only)32 tall (medium), radius 4
CamoFab–a circular primary button (guidance: use a command bar instead)
CamoTextFieldInput + Field32 tall, radius 4, bottom-accent stroke (brand on focus), label above
CamoCheckbox / Switch / RadioCheckbox / Switch / Radio16 box, 40 × 20 switch, brand when on
CamoSegmentedControl– (TabList or ToggleButtons)toggle-button group
CamoSliderSlider4 px rail, 20 thumb with an inner dot
CamoDatePickerDatePicker / Calendarstyle Calendar in an Acrylic flyout
CamoTimePickerTimePickerstyle Fields
CamoStepperSpinButtonlayout Split (field with ▲▼)
CamoSearchFieldSearchBoxInput + search icon + dismiss
CamoSelectDropdown / Comboboxfield + listbox flyout (Acrylic)
CamoCardCardradius 8, shadow4, neutralBackground1
CamoAccordionAccordionchevron at the start (indicatorPosition Start)
CamoListItemList40–56 rows, subtle selection
CamoChipTag / InteractionTagradius 4 tags, dismissible
CamoBadgeBadge / CounterBadgebrand or danger, rounded
CamoAvatarAvatar / Personacircle, brand-tinted initials, presence badge
CamoProgressProgressBar / Spinner2 px bar, a brand spinner
CamoSnackbarToasta bottom-end toast card; showToneIcon true
CamoBannerMessageBaran intent-colored bar with an icon and actions
CamoDialogDialogradius 8, shadow64, title 20 semibold, actions end-aligned, optional ✕ (DialogTheme.showCloseButton), shown only when dismissible
CamoBottomSheetDrawer (bottom)→ an overlay drawer from the bottom, showHandle default false
CamoMenuMenuAcrylic flyout, 32 items, radius 4, checkPosition Leading
CamoTooltipTooltipneutral or inverted, radius 4
CamoTopBar(app header)48 tall, title start-aligned
CamoTabsTabLista rounded brand underline, 2 px, as wide as the tab's content; no divider
CamoNavigationBar–a 56 bottom bar with a 2 px brand line on the selected item (for mobile)
CamoNavigationRail / DrawerNav (collapsed / expanded)48 rail (icons only), 260 pane, items 40, indicator Line (a brand start-edge line), subtle selected row
CamoPagedListListno pull gesture on desktop (refresh from a command); Spinner for loading more
CamoSkeletonSkeletonshimmer, Fluent's skeleton colors
CamoDividerDivider1 px neutralStroke2
CamoPopoverPopover / TeachingPopoverradius 8, shadow16, an arrow (showArrow true), title 14 semibold, optional close
CamoSideSheetDrawer (side, inline / overlay)320, surfaceContainer, radius 8 overlay corners, shadow64 when overlay; the standard form is the inline drawer
CamoToolbarToolbar44 tall, subtle ghost buttons 32, dividers between groups; overflow as a menu button
CamoButtonGroup(button set)connected: radius 4 outer, 0 inner, 1 px strokes; selected = subtle brand fill (Toggle button)
CamoSplitButtonSplitButton / MenuButtonradius 4, a 1 px divider, chevron 12; onClick = null draws a MenuButton
CamoDataTableDataGridheader 40 neutralForeground2, rows 44 with neutralStroke2 dividers, hover neutralBackground1Hover, the selected row subtleBackgroundSelected
CamoTreeTreerows 32, indent 20, a chevron 12, a selected fill, optional guide lines
CamoCarouselCarousela card strip, radius 8, nav buttons and a dot indicator
CamoImageImageradius 4 by role, a neutralBackground3 placeholder, 150 ms fade
CamoRatingRating20 dp stars in brandForeground1, a hover preview
CamoFileUploaderFile uploadera dashed neutralStroke1 zone, radius 8, brand border on drag, rows with a progress bar
CamoPaginationPaginationbuttons 32 radius 4, the current page a brand-filled button, chevron arrows
CamoBreadcrumbBreadcrumbbodyMedium, chevron separators, an overflow menu button, the current item semibold
CamoProgressStepsProgress indicatorbrand circles 24, a check for complete steps, neutralStroke1 connectors

4. Build steps​

By milestone (ADR-38). Every step runs Kotlin first, then Flutter.

  1. M3: Subtle feedback, the double-stroke focus, and the Solid surface with Fluent's shadow ramp; fluentTheme from the Fluent token set (brand ramp + neutrals), snapshot-pinned; the density option (small 24 / medium 32 heights, through component themes); the renderers for text, icon, surface, divider, button and icon button.
  2. M4: the theme swap demo also switches skin (Minimal ⇄ Fluent) live.
  3. M5: the input renderers (text field with the bottom-accent stroke, checkbox, switch, radio, segmented control, slider, search field, date and time pickers, stepper in Split layout) and the form.
  4. M6: the structure and overlay renderers, and the Acrylic surface (blur + noise + tint) for menus, flyouts, the select's listbox, the date picker's calendar and dialogs.
  5. M7: chip, badge, avatar, progress, snackbar (Toast) and banner (MessageBar) renderers.
  6. M8: tabs, navigation bar, rail and drawer (Nav), FAB, and the Mica window backdrop (Windows desktop; Solid elsewhere).

Most proportions differ from Minimal, but the structures stay close to it.

Done when

  • M3: the M3 renderers pass the behavior and no-literals tests with Solid, at both densities.
  • M5 to M8: every renderer added in the milestone passes the same tests.
  • M6: Acrylic menus, flyouts and dialogs on desktop, with a Solid fallback where blur isn't available.
  • M8: all 39 renderers done; Mica on the Windows desktop sample.

5. Edge cases​

CaseDecided behavior
Mica on non-Windows platformsFalls back to Solid (a documented, silent fallback).
Fluent's compact density on desktop vs touch on mobileUses a density option via component themes: small 24 and medium 32 on desktop (the sizes Graft uses), 40 on touch. See Theme.
High contrast mode (Windows)Uses the platform's high-contrast colors when the OS reports it.
Changed in the M6 build (2026-10-28)
  • Acrylic is built without a third-party library (ruling 2026-10-28): it applies at elevation Level4 and up (flyouts, menus, dialogs, sheets), so cards stay Solid; Fluent's popup panel moved from Level3 to Level4 (shadow16, Fluent's flyout depth).
  • Kotlin: FluentBackdrop records the app into a graphics layer; an Acrylic surface draws it blurred (30 dp) behind itself with the platform blur effect, then the 75% tint and a 2% noise. While the backdrop is recording, a surface inside it draws its fallback instead of itself, and where blur isn't supported (Android below 12) or there's no backdrop it falls back to tint and noise over a solid fill. FluentPreview(surface = …) wraps previews in the backdrop.
  • Flutter: FluentAcrylic is a BackdropFilter (σ 15) with the same tint and noise; fluentSkin(surface: FluentSurface.acrylic).
  • Fluent's dialog and sheet scrim is Smoke: colors.scrim (black) at Fluent 2's colorBackgroundOverlay alpha, 40% in light and 50% in dark, instead of Minimal's value.
  • Flutter's Acrylic dialogs and sheets sample the page undimmed, like Kotlin's: the overlay routes paint the scrim with a hole where the overlay sits (the barrier stays, clear, for taps), and the frames animate the overlay in themselves, so the scrim never slides or scales.
  • Mica beyond Windows (an M8 option, not decided): Mica is drawn by the Windows 11 compositor from the wallpaper, so no other platform has it. macOS has a close cousin (vibrancy, NSVisualEffectView), Android 12+ can show the wallpaper blurred behind a full-screen window (an approximation), Linux depends on the compositor, and iOS and web can't see behind the window at all. Decided in M8: Solid elsewhere (below).
Changed in the M8 build (2026-10-29)
  • fluentTheme(density: null) now follows the input: Medium with a pointer, Touch with fingers (a rule that keeps a brand's other button overrides). An explicit density wins.
  • The toast is bottom-end on wider windows and centered on a compact one.
  • Acrylic's fallback chain (ADR-42) is data-driven: the own blur, then tint and noise over a solid fill without backdropBlur, then the opaque Solid surface with Reduce Transparency; goldens cover each step.
Changed in the M8 build (2026-11-01)
  • FluentSurface.Mica / fluentSkin(surface: mica) is a surface treatment with a fallback chain (ADR-42): where the platform reports CamoCapabilities.windowMaterial (Windows 11 on the desktop JVM), the base layers (elevation below Level2: the window background and the navigation chrome) draw nothing, so the backdrop the app enabled on its window shows through. Everywhere else, and with Reduce Transparency, they are the opaque Fluent surface. Raised surfaces (cards, flyouts, dialogs) are always Solid.
  • Camouflage does not draw Mica and does not set up the window backdrop: the app enables Mica on its window (and drops its opaque window background). Choosing the Mica surface is the opt-in. Flutter reports no window material by itself, so the app passes capabilities.windowMaterial through the provider's environment where it sets the backdrop up.
  • Not verified on Windows in this build (there is no Windows machine in the loop): the chain is tested through the capabilities, with the fallback goldens on the other platforms.
  • Mica beyond Windows stays Solid (macOS vibrancy and Android's blurred wallpaper are not approximated).

Implementation​

Milestone: v1, built alongside M3 to M8 (ADR-38)

Read the base note first: Fluent Skin. This note adds the Compose Multiplatform plan: the module, the feedback and focus wiring, the three surface treatments, and what each milestone builds.

1. Why​

:camouflage-skin-fluent renders every component in Fluent 2, the second v1 skin next to Minimal (Minimal Skin). Like Minimal, it draws everything on Compose foundation and camouflage-core's public API, with no Material artifact. It's the first skin with platform-specific work: a backdrop blur for Acrylic, and Windows window interop for Mica. Graft, a Compose Desktop app, is its first user.

2. Shape​

Module and dependencies

Source setDepends onWhy
commonMainprojects.camouflageCore (as api)the contract and the theme
commonMaina multiplatform backdrop-blur library, e.g. Haze (dev.chrisbanes.haze)Acrylic: Compose has no backdrop blur of its own (Open for review)
jvmMainnet.java.dev.jna:jna-platformMica: DwmSetWindowAttribute on Windows 11
commonTestprojects.camouflageSkinTestingbehavior and no-literals checks

No material3, no material-ripple: ./gradlew :camouflage-skin-fluent:dependencies must show neither.

3. API​

public val FluentSkin: CamoSkin = fluentSkin()

public enum class FluentSurface { Solid, Acrylic, Mica } // Mica = Acrylic flyouts + a Mica window backdrop

public fun fluentSkin(surface: FluentSurface = FluentSurface.Solid): CamoSkin = CamoSkin(
name = "fluent",
surfaceTreatment = if (surface == FluentSurface.Solid) FluentSolid else FluentAcrylic,
feedback = Subtle,
text = FluentTextRenderer, icon = FluentIconRenderer, surface = FluentSurfaceRenderer, divider = FluentDividerRenderer,
button = FluentButtonRenderer, iconButton = FluentIconButtonRenderer,
// M5 to M8 add the rest; until then they're DebugSkin's, so the skin is usable from M3.
)

public enum class FluentDensity { Small, Medium, Touch } // control heights 24 / 32 / 40

public fun fluentTheme(
brand: Color = FluentBrandBlue, // #0F6CBD
dark: Boolean = false,
density: FluentDensity = FluentDensity.Medium,
fontFamily: FontFamily? = null, // Segoe UI Variable on Windows by default; never bundled (ADR-33)
): CamoTheme

@Composable public fun FluentBackdrop(content: @Composable () -> Unit) // the Acrylic blur source (M6)
@Composable public fun FluentPreview(dark: Boolean = false, content: @Composable () -> Unit) // for @Preview, like MinimalPreview

3.1 Tokens and feedback​

Fluent's states are explicit token steps (neutralBackground1 → …Hover → …Pressed), not an overlay. fluentTheme carries them as a typed token set (ADR-32):

public data class FluentTokens(
val neutralBackground1Hover: Color, val neutralBackground1Pressed: Color,
val brandBackgroundHover: Color, val brandBackgroundPressed: Color,
val strokeFocus1: Color, // inner, light
val strokeFocus2: Color, // outer, dark
// … the remaining …Hover / …Pressed / …Selected steps the renderers read
) : CamoTokenSet<FluentTokens> {
override fun lerp(other: FluentTokens, t: Float): FluentTokens // animated theme switches blend it like the core groups
}
  • The state steps are drawn by Fluent's renderers (an indication can't recolor a fill another modifier drew): each renderer picks the hover or pressed token from theme.tokens<FluentTokens>() for the default tone, and steps a status tone's fill 8% / 16% toward its content color (Fluent has no status hover tokens). Subtle is the IndicationNodeFactory for the focus indicator; no ripple, no overlay alpha.
  • FluentTokens also carries brandBackground and neutralForegroundOnBrand: in dark mode the role primary is the brand foreground (brand[100], readable as text), while a filled primary button uses brandBackground (brand[70]) with white text.
  • The focus indicator is a separate draw node: a 2 dp strokeFocus2 outer stroke and a 1 dp strokeFocus1 inner stroke, shown only for keyboard focus.
  • Under another theme (no FluentTokens), Subtle falls back to a 4% / 8% onSurface overlay, so FluentSkin still works with a brand theme that wasn't built from fluentTheme.

3.2 Surface treatments​

  • FluentSolid: background(color, shape) plus Fluent's two-layer shadows (key + ambient) from elevation: shadow2, 4, 8, 16, 28, 64 via Modifier.dropShadow. Level0 and Level1 have none; cards use shadow4, flyouts shadow16, dialogs shadow64.
  • FluentAcrylic: for flyouts, menus, the select's listbox, the date picker's calendar and dialogs; other containers stay Solid. It blurs the backdrop (30 dp), adds a luminosity tint and a noise layer (a small noise bitmap generated once at runtime, drawn at 2%; nothing is bundled). It needs the app's content marked as the blur source: apps wrap their root content in FluentBackdrop { … }, and FluentPreview does it for previews (core never knows about it).
  • Mica (jvmMain only): FrameWindowScope.FluentMica() calls DwmSetWindowAttribute(hwnd, DWMWA_SYSTEMBACKDROP_TYPE, DWMSBT_MAINWINDOW) and extends the frame into the client area, then makes the Level0 background transparent so the backdrop shows. It's a no-op (Solid) on other platforms and on Windows before 11.

3.3 Density​

density sets the component themes' heights: Medium 32 (buttons, fields, menu items 32; list rows 40), Small 24, Touch 40. An app that mixes sizes, like Graft (small toolbars, medium dialogs), scopes a nested CamouflageProvider with fluentTheme(density = Small)'s component themes around the toolbar.

4. Build steps​

  1. M3: the module (add it to settings.gradle.kts, the BOM and srctool.layers at layer 1); FluentTokens and fluentTheme from Fluent's published token set (brand ramp + neutrals), with a snapshot test pinning the values; FluentSolid; Subtle and the double-stroke focus; the density presets; the M3 renderers (text, icon, surface, divider, button, icon button).
  2. M4: the sample's theme swap also switches skin, Minimal ⇄ Fluent.
  3. M5: the input renderers and the form.
  4. M6: the structure and overlay renderers; FluentAcrylic and FluentBackdrop.
  5. M7: chip, badge, avatar, progress, snackbar and banner renderers.
  6. M8: tabs, navigation bar, rail and drawer, FAB; FluentMica on the JVM desktop sample.
  7. Every milestone: assertRendererAppliesBehavior on each new clickable renderer, the no-literals test per renderer, and screenshot goldens (Testing).

Done when

  • :camouflage-skin-fluent has no Material dependency, and checkModuleLayers passes with it at layer 1.
  • Every renderer passes the behavior and no-literals tests, at Medium and Small density.
  • Acrylic menus and dialogs render on desktop, Android 12+ and iOS, and fall back to Solid where blur isn't available.
  • Mica shows on the Windows 11 desktop sample.
  • Goldens are recorded for Android and desktop, and iOS where Roborazzi supports it.

5. Edge cases​

CaseDecided behavior
Blur unavailable (Android below 12)Acrylic draws its tint and noise over a Solid fill, which is Fluent's own fallback.
Acrylic inside a popupVerify at M6 that the blur source reaches popups on every target. If it doesn't on one, that target uses Solid flyouts.
Mica on macOS, Linux, Windows 10Solid. The call is guarded by an OS-version check.
Mica and window decorationsThe backdrop shows only where the window's own background is transparent. Verify at M8 whether that works with a decorated Compose window, or needs an undecorated window with an app title bar (Graft already draws its own).
FluentSkin with a non-Fluent themeWorks: renderers read core's roles, and Subtle falls back to an overlay (§3.1).
A brand on FluentBuild the brand's theme from fluentTheme(brand = …), then override its roles and component themes. Overriding only the roles of the default fluentTheme() leaves FluentTokens (the filled primary, hover and pressed steps) in Fluent blue; the M4 sample showed it.
Windows high-contrast modeUses the OS high-contrast colors when the platform reports it (base note).
Changed in the M6 build (2026-10-28)
  • Haze is not used (open question closed by the 2026-10-28 ruling): see the base note's build changes for the in-house backdrop blur.