macOS JS behaviour

Corner notifications

The Mac’s corner banners: a glass card with the app icon, title and two-line body that expands on hover to reveal action buttons; more banners stack behind in steps.

Documentation

Real scenarios

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

Corner notifications

Hover (or Tab into) a banner to expand it — the full text and «Reply / Later» appear. Banners stack three deep in steps, «Dismiss all» slides them out and «New banner» slides one back in.

Elm-o Sanat — desktop Banners land at the trailing corner

Important props

Important props
Prop Type Default What it does
banner size '380px' The official banner width with a 38–40px icon.
expand behaviour 'hover' Hover reveals the full text and the actions.
stack layout '3 deep' Up to three banners step behind each other.

Snippet

<div class="mcnotif" data-expanded="false">
    <img class="mcnotif-icon" src="mail.png" alt="">
    <div>
        <b>ایمیل</b>
        <p>سارا: جلسه فردا…‏</p>
    </div>
</div>

<style>
.mcnotif { display: flex; gap: 10px; inline-size: 380px; padding: 12px;
           border-radius: 14px; background: #f2f2f2e6;
           backdrop-filter: blur(30px) saturate(1.5);
           box-shadow: 0 8px 32px #0000002b; }
.mcnotif-icon { inline-size: 38px; aspect-ratio: 1; border-radius: 9px; }
.mcnotif p { margin: 0; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: clip; }
</style>