Windows — Fluent JS behaviour

Windows 11 window chrome

The Win11 window frame: 8px corners, caption buttons at 46×32 with the red close, the snap-layouts menu on maximize hover, and a mica background tinted by the wallpaper.

Documentation

Real scenarios

The component as it is used in a product — not a specimen grid.

The window, fully chromed

Hold the maximize button and the six snap layouts appear; pick a zone and the window flashes into it. The close button glows red under the pointer.

Untitled — Notepad

Product meeting notes — Mehr 7

1. Command bar redesign lands by Mehr 14.
2. Review the acrylic feedback thread.
3. Next call: Tuesday, 10:00.

Ln 4, Col 18 UTF-8 100%

Hold the maximize button for about half a second, then pick a zone — or try minimize and close.

Important props

Important props
Prop Type Default What it does
caption size '46 × 32' The official button hit area; close turns #C42B1C on hover.
radius length '8px' The window corner radius since Windows 11.
snap flyout '6 layouts' Six snap layouts in the flyout; each zone is pickable.

Snippet

<div class="flwin">
    <header class="flwin-title">
        <span>Notepad — یادداشت‌ها</span>
        <div class="flwin-caption">
            <button aria-label="کوچک">▁</button>
            <button aria-label="بزرگ" data-snap>□</button>
            <button aria-label="بستن" data-close>✕</button>
        </div>
    </header>
</div>

<style>
.flwin { border-radius: 8px; overflow: clip; box-shadow: 0 32px 64px #0000004d,
         0 0 0 1px #00000026; background: #f3f3f3; }
.flwin-caption { display: flex; margin-inline-start: auto; }
.flwin-caption button { inline-size: 46px; block-size: 32px; }
.flwin-caption [data-close]:hover { background: #C42B1C; color: #fff; }
</style>