Layout
Page layouts
Ready-made page layouts for lists, forms, settings and dashboards, built from AppList, AppForm, AppSettings and PageShell.
<script>
import { AppList, AppForm, AppSettings, PageShell } from "@codeatlasdev/ui";
</script>
These layouts fill the content area of the app shell and manage their own scrolling, so give them a parent with a fixed or flexible height. AppForm has its own page, see AppForm.
AppList
Pass data and the layout handles search, filters and pagination.
| User | Role | Status |
|---|---|---|
AL Ana Lima ana@acme.com | Admin | Active |
CM Carlos Melo carlos@apex.io | Editor | Active |
DK Diana Kwan diana@nova.dev | Viewer | Inactive |
ES Eduardo S. edu@mesh.ai | Editor | Active |
Code
AppSettings
Side navigation plus content. The active tab is managed internally.
Workspace
Code
PageShell
A scrollable container for dashboards and non-CRUD pages.
Revenue
$118k
↑+23.4%Users
24.8k
↑+8.1%Growth
34%
↑+5.6%Uptime
99.9%
↑+0.1%Chart or data table goes here
Code
AppList props
| Prop | Type | Default | Description |
|---|---|---|---|
title | string | – | Page title. |
description | string | – | Subtitle. Derived from the list count when omitted in data mode. |
data | T[] | – | Full dataset. When set, AppList manages search, filters and pagination. |
searchKeys | (keyof T)[] | – | Fields included in text search. Defaults to all string fields. |
perPage | number | 20 | Rows per page. |
idKey | keyof T | 'id' | Row identifier field. |
searchPlaceholder | string | – | Placeholder of the search input. |
ofLabel | string | 'of' | Word between the numbers in the count and page info. |
filters | Snippet<[ListCtx]> | – | Extra filter controls after the search input. |
children | Snippet<[ListCtx]> | Snippet | – | Table or grid content. Receives the list context in data mode. |
actions | Snippet | – | Top-right slot for the primary action. |
toolbar | Snippet | – | Manual toolbar, used only without data. |
empty | Snippet<[ListCtx]> | Snippet | – | Shown when filtered rows are zero. |
footer | Snippet | – | Manual footer, used only without data. |
maxWidth | string | – | Maximum width of the content. |
class | string | '' | Extra class names. |
AppSettings props
| Prop | Type | Default | Description |
|---|---|---|---|
title | string | – | Page title. |
description | string | – | Subtitle. |
tabs | { value, label, icon?, badge?, danger? }[] | – | Side navigation entries. |
defaultTab | string | – | Initial tab. Defaults to the first. |
activeTab | string | – | Bindable active tab for external control. |
onTabChange | (value: string) => void | – | Called when the tab changes. |
actions | Snippet | – | Top-right slot for save and cancel buttons. |
children | Snippet<[string]> | – | Content. Receives the active tab value. |
class | string | '' | Extra class names. |