---
title: "Frame"
description: "Free-form box: layout and look all from style."
---

> Documentation Index
> Fetch the complete documentation index at: https://gistui.com/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# Frame

```gistui
root = Frame(Text("BOARDING PASS", style:{size:11, tracking:2, color:"muted"}), Text("SFO → NRT", style:{size:32, weight:700}), style:{layout:"column", gap:6, pad:24, radius:16, fill:"accent/15", stroke:"accent/40"})
```

`Frame` is for the rare design the components cannot express. Everything comes from `style`.

## Signature

This is the line a model reads in the system prompt.

```gistui
Frame(...children, style:{…})
```

- **Group:** Layout
- **Children:** Yes: any component or text
- **Positional arguments:** none

## Props

| Prop | Type | How to write it | Notes |
|---|---|---|---|
| `style` | object | named: `style:…` | see Custom design |

## Use your own component

Keep the name and schema, swap what is drawn. The prompt and the model's output do not change.

### React

```tsx
import { ui } from "@gistui/react/ui";

const lib = ui.extend({ Frame: MyFrame });
<GistUI library={lib} stream={response.body} />;
```
### Vue

```vue
<GistUI :source="answer" :components="{ Frame: MyFrame }" />
```
### Svelte

```svelte
<GistUI source={answer} components={{ Frame: MyFrame }} />
```
### Solid

```tsx
<GistUI source={answer()} components={{ Frame: MyFrame }} />
```
### Vanilla

```ts
import { ui } from "@gistui/vanilla/ui";

const lib = ui.extend({ Frame: (ctx) => ({ el: myElement(ctx) }) });
```

See [Custom components](/docs/guides/custom-components/) for the full contract. Style hook: `[data-gistui="Frame"]`.

Source: https://gistui.com/docs/components/layout/frame/index.mdx
