App shell
The frame of an app (Mantine's AppShell): header, navbar, main, aside and footer on wide screens; on phones one column with a bottom bar. The main content scrolls, the bars stay.
The app is a page of its own (open it) in an iframe: its drawers, menus and sheets open inside the device, and the shell picks its layout from the frame's width.
In a raylang app
In a std/ui window opened as full_content (the page under a transparent title bar, macOS), with the native bridge, the header becomes the title bar: at least as tall, with room for the window buttons, and dragging it moves the window (buttons in it stay buttons). With layout="alt" or without a header, the navbar and the main content start below the title bar.
var o = ui.options(1100, 720);
o.kind = "full_content";
let h = ui.open_with("Builds", "ray://app/index.html", o)?;
The bridge also keeps the window's background and title bar in the theme's background, so switching to dark, resizing or reopening never flashes the other theme.
API
For AI agents: this API as Markdown, or every component in llms-full.txt.
<ray-app-shell> · RayAppShell
The layout follows the shell's own width (a phone-sized frame shows the phone layout). Below breakpoint the navbar and the aside take no room (a ray-sidebar there still opens as its drawer) and the bottom slot shows. It fills the window's height (100dvh) unless sized. In a std/ui full_content window (ray-elements/core/raylang.js) the header becomes the title bar: room for the window buttons, and it drags the window; with layout="alt" or no header, the navbar and main start below it.
| Property | Attribute | Type | Default | Description |
|---|---|---|---|---|
layout | layout reflects | default | alt | default | default: the header across the top; alt: the navbar full height, the header beside it. |
breakpoint | breakpoint | string | 48em | Width (px, em or rem) below which it takes the phone layout. |
padding | padding reflects | string | Padding of the main area: xs…xl, a number (px) or a CSS length. |
| Event | Description |
|---|---|
ray-breakpoint | It switched between the wide and the phone layout. |
| Slot | Description |
|---|---|
| (default) | The main content (it scrolls). |
header | Top bar: a ray-app-bar or a header of your own. |
navbar | Side navigation (a ray-sidebar). Wide screens only. |
aside | A panel on the other side (details, an inspector). Wide screens only. |
footer | Under the main content. |
bottom | Phones only: a ray-bottom-nav. |
| Part | Description |
|---|---|
shell | The grid. |
header | The header area. |
navbar | The navbar area. |
main | The scrolling main area. |
aside | The aside area. |
footer | The footer area. |
bottom | The bottom bar area. |