Examples
Pick one and it runs in the notch at the top of this page. The code is the whole thing.
Usage
States and size
The notch is always in one of four states. A message isn't a separate thing: it's the notch peeking. Pick a state and the notch at the top goes there; the green dot follows what it's really doing. The expanded notch fits its content by default, or give it an exact width, height and radius.
Peek
Call it from anywhere: a button, a background job, the main process. A peek can carry a button (Undo), a reply field, or a level that moves in place.
Split island
By default the notch shows one activity, the one that matters most. Turn on split and a second can sit in a small bubble beside it instead of waiting behind, like the iPhone's Dynamic Island. Like a compact side, the bubble steps aside for menu bar items.
Drag and drop
Drag files, links or text onto the notch and it opens into a drop target. Any activity can take drops; in Electron you get the paths on disk, and the main process hears about them too. Try it on the notch at the top of this page.
Style
Fill the notch with any colour or gradient, and give peeks an accent. The band across the camera always stays black, because the hardware is. In SwiftUI it can also be a real material that blurs the desktop behind it.
Motion
Opening overshoots a touch so it feels alive; closing settles without one so it feels decisive. Shape either curve and the notch at the top uses it straight away. Both platforms run the same physics, so the numbers you land on mean the same thing in SwiftUI.
Many components, one notch
Any component can start an activity. The highest priority is shown, and when it ends the notch falls back to the next. On this page, Now Playing is always running underneath the examples.
Accessibility
Press Tab and the notch at the top takes focus: Enter opens it and moves focus inside, Escape closes it and brings focus back. Every peek is read out by screen readers, and VoiceOver in SwiftUI. Give activities a label so they're announced by name. In SwiftUI, expand(focus: true) hands the keyboard to the notch from a shortcut. With reduced motion on, the springs settle without bouncing.
Every option is in the documentation.