Skip to content

Frame

The structure of a crafted landing page: a centred frame with hairline rules down both sides, sections cut by hairline rows, grid cells that share their borders, tick marks where rules cross, and one full-bleed band that breaks the frame. Border token only, no shadows.

On this page
Used for
  • Landing page structure
  • Hairline grid of feature cells
  • Full-bleed accent band
  • Rows with tick marks
  • Frame for a crafted page

Examples

Closing row
Columns

Installation

npx knowns-ui@latest add frame
For Claude Code, Cursor or Codex: installs it and wires the props to your own data.

Props

FrameRoot maxWidth
string
Default"1200px"
The frame's width. Bleed sections keep their content to this width.
FrameRoot fill
boolean
Defaultfalse
Stretch to the parent's height so the side rules reach the bottom of a short page.
FrameSection tone
"default" | "muted" | "accent" | "dark"
Default"default"
The row's background. Parts inside follow its text, muted text and rule colours.
FrameSection bleed
boolean
Defaultfalse
Break out of the frame for the full page width. Use it once. The content keeps the frame's width.
FrameSection ticks
boolean
Defaultfalse
Ticks where the row's top rule meets the frame rules.
FrameSection pad
"none" | "md" | "lg"
Default"lg"
"none" lets a grid touch the rules.
FrameGrid cols
1 | 2 | 3 | 4
Default3
Columns from the breakpoint up. One column on a phone.
FrameGrid at
"md" | "lg"
Default"md"
Where the columns start: 768px or 1024px.
FrameGrid ticks
boolean
Defaultfalse
A tick where two lines inside the grid cross. Hidden on a phone.
FrameCell pad
"none" | "md" | "lg"
Default"md"
Padding inside the cell.

Cells draw only the lines they share: an end line unless the cell is in the last column, a bottom line unless it is in the last row. The outer edges belong to the frame rules and the section rows, so nothing is drawn twice. Every side is logical, so the frame mirrors in right-to-left. The pure maths lives in frame-utils with tests.

What it handles

  1. 01Centres the page in a frame with a hairline rule down each side, the full height of the content.
  2. 02Cuts the page into rows with a hairline, and gives a row a muted, accent or dark tone that its contents follow.
  3. 03Breaks one row out of the frame to the full page width, keeping its content to the frame's width.
  4. 04Lays cells in one to four columns that share their lines, so no line is drawn twice, and falls to one column on a phone.
  5. 05Marks the crossings of the rules with small ticks, on the rows and inside the grid, and hides the inner ones on a phone.
  6. 06Uses only the border token and logical sides, so it has no shadows and mirrors in right-to-left.

States

First render
Nothing plays. It is layout only
none
Narrow screen
The cells stack in one column and the inner ticks hide
none
Right to left
The rules, lines and ticks mirror
none

Works with

When to use

When to use

  • The structure of a crafted landing page: hairline rules down both sides, rows between sections and boxed cells.
  • A feature grid whose cells share their borders, with ticks where the rules cross.

When not to use

  • Cards with gaps and shadows inside an app: use Card.
  • A plain features row: use Feature Grid.

Using with AI

Use Copy page for AI above to give your assistant this page, Copy prompt under the install command to have it installed and wired to your data, or connect the Knowns UI MCP server and just ask:

  • Add the Knowns UI Frame to my app and wire it to my own data.
  • I need the structure of a crafted landing page: hairline rules down both sides, rows between sections and boxed cells. Set that up with the Knowns UI Frame.
  • Which Frame props do I need for a minimal setup? Show me a short example.

With the server connected, your assistant calls get_component({ name: "frame" }) and search_docs({ query: "frame" }).

Need help?

Stuck on Frame, or found something off? We read every message.