@adia-ai/web-components 0.6.4 → 0.6.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +28 -0
- package/USAGE.md +100 -5
- package/bin/doc.mjs +379 -0
- package/components/accordion/accordion.examples.md +49 -0
- package/components/action-list/action-list.examples.md +33 -0
- package/components/agent-artifact/agent-artifact.examples.md +28 -0
- package/components/agent-feedback-bar/agent-feedback-bar.examples.md +24 -0
- package/components/agent-questions/agent-questions.examples.md +13 -0
- package/components/agent-reasoning/agent-reasoning.examples.md +28 -0
- package/components/agent-suggestions/agent-suggestions.examples.md +19 -0
- package/components/agent-trace/agent-trace.examples.md +19 -0
- package/components/alert/alert.examples.md +19 -0
- package/components/aside/aside.examples.md +38 -0
- package/components/avatar/avatar.examples.md +19 -0
- package/components/badge/badge.examples.md +19 -0
- package/components/block/block.examples.md +29 -0
- package/components/breadcrumb/breadcrumb.examples.md +32 -0
- package/components/button/button.examples.md +19 -0
- package/components/calendar-picker/calendar-picker.examples.md +23 -0
- package/components/canvas/canvas.examples.md +49 -0
- package/components/card/card.examples.md +25 -0
- package/components/chart/chart.examples.md +19 -0
- package/components/chart-legend/chart-legend.examples.md +22 -0
- package/components/chat-thread/chat-thread.examples.md +35 -0
- package/components/check/check.examples.md +19 -0
- package/components/code/code.examples.md +31 -0
- package/components/col/col.examples.md +11 -0
- package/components/color-input/color-input.examples.md +19 -0
- package/components/color-picker/color-picker.examples.md +19 -0
- package/components/command/command.examples.md +58 -0
- package/components/demo-toggle/demo-toggle.examples.md +19 -0
- package/components/description-list/description-list.examples.md +37 -0
- package/components/divider/divider.examples.md +31 -0
- package/components/drawer/drawer.examples.md +63 -0
- package/components/embed/embed.examples.md +19 -0
- package/components/empty-state/empty-state.examples.md +21 -0
- package/components/feed/feed.examples.md +19 -0
- package/components/field/class.js +5 -4
- package/components/field/field.a2ui.json +9 -0
- package/components/field/field.css +10 -0
- package/components/field/field.d.ts +2 -0
- package/components/field/field.examples.md +29 -0
- package/components/field/field.test.js +43 -0
- package/components/field/field.yaml +11 -0
- package/components/fields/fields.examples.md +58 -0
- package/components/footer/footer.examples.md +18 -0
- package/components/grid/grid.examples.md +21 -0
- package/components/header/header.examples.md +32 -0
- package/components/heatmap/heatmap.examples.md +19 -0
- package/components/icon/icon.examples.md +19 -0
- package/components/image/image.examples.md +19 -0
- package/components/input/input.examples.md +21 -0
- package/components/inspector/inspector.examples.md +27 -0
- package/components/kbd/kbd.examples.md +29 -0
- package/components/link/link.examples.md +25 -0
- package/components/list/list.examples.md +33 -0
- package/components/menu/menu.examples.md +37 -0
- package/components/modal/modal.examples.md +43 -0
- package/components/nav/nav.examples.md +39 -0
- package/components/nav-group/nav-group.examples.md +35 -0
- package/components/nav-item/nav-item.examples.md +25 -0
- package/components/noodles/noodles.examples.md +30 -0
- package/components/option-card/option-card.examples.md +47 -0
- package/components/otp-input/otp-input.examples.md +19 -0
- package/components/page/page.examples.md +46 -0
- package/components/pagination/pagination.examples.md +19 -0
- package/components/pane/pane.examples.md +40 -0
- package/components/pipeline-status/pipeline-status.examples.md +19 -0
- package/components/popover/popover.examples.md +34 -0
- package/components/progress/progress.examples.md +19 -0
- package/components/progress-row/progress-row.examples.md +19 -0
- package/components/radio/radio.examples.md +19 -0
- package/components/range/range.examples.md +19 -0
- package/components/rating/rating.examples.md +19 -0
- package/components/richtext/richtext.examples.md +19 -0
- package/components/row/row.examples.md +11 -0
- package/components/search/search.examples.md +19 -0
- package/components/section/section.examples.md +37 -0
- package/components/segment/segment.examples.md +32 -0
- package/components/segmented/segmented.examples.md +31 -0
- package/components/select/select.examples.md +49 -0
- package/components/skeleton/skeleton.examples.md +19 -0
- package/components/slider/slider.examples.md +21 -0
- package/components/stack/stack.examples.md +10 -0
- package/components/stat/stat.examples.md +19 -0
- package/components/step-progress/step-progress.examples.md +19 -0
- package/components/stepper/stepper.examples.md +37 -0
- package/components/stream/stream.examples.md +19 -0
- package/components/swatch/swatch.examples.md +23 -0
- package/components/swiper/swiper.examples.md +139 -0
- package/components/switch/switch.examples.md +19 -0
- package/components/table/table.examples.md +19 -0
- package/components/table-toolbar/table-toolbar.examples.md +12 -0
- package/components/tabs/tabs.examples.md +49 -0
- package/components/tag/tag.examples.md +19 -0
- package/components/text/text.examples.md +19 -0
- package/components/textarea/textarea.examples.md +23 -0
- package/components/timeline/timeline.examples.md +35 -0
- package/components/toast/toast.examples.md +19 -0
- package/components/toggle-group/toggle-group.examples.md +33 -0
- package/components/toggle-scheme/toggle-scheme.examples.md +19 -0
- package/components/toolbar/toolbar.examples.md +46 -0
- package/components/tooltip/tooltip.examples.md +25 -0
- package/components/tree/tree.examples.md +57 -0
- package/components/upload/upload.examples.md +19 -0
- package/custom-elements.json +9012 -0
- package/package.json +7 -1
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# menu — Examples
|
|
2
|
+
|
|
3
|
+
## basic
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<menu-ui>
|
|
7
|
+
<button-ui slot="trigger" text="Actions" variant="outline"></button-ui>
|
|
8
|
+
<menu-item-ui text="Edit" value="edit"></menu-item-ui>
|
|
9
|
+
<menu-item-ui text="Duplicate" value="duplicate"></menu-item-ui>
|
|
10
|
+
<menu-item-ui text="Archive" value="archive"></menu-item-ui>
|
|
11
|
+
</menu-ui>
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## with icons
|
|
15
|
+
|
|
16
|
+
```html
|
|
17
|
+
<menu-ui>
|
|
18
|
+
<button-ui slot="trigger" icon="dots-three-vertical" variant="ghost"></button-ui>
|
|
19
|
+
<menu-item-ui icon="pencil" text="Edit" value="edit"></menu-item-ui>
|
|
20
|
+
<menu-item-ui icon="copy" text="Duplicate" value="duplicate"></menu-item-ui>
|
|
21
|
+
<menu-item-ui icon="download" text="Download" value="download"></menu-item-ui>
|
|
22
|
+
</menu-ui>
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
## with divider
|
|
26
|
+
|
|
27
|
+
```html
|
|
28
|
+
<menu-ui>
|
|
29
|
+
<button-ui slot="trigger" text="File" variant="outline"></button-ui>
|
|
30
|
+
<menu-item-ui icon="file-plus" text="New" value="new"></menu-item-ui>
|
|
31
|
+
<menu-item-ui icon="folder-open" text="Open" value="open"></menu-item-ui>
|
|
32
|
+
<menu-item-ui icon="floppy-disk" text="Save" value="save"></menu-item-ui>
|
|
33
|
+
<menu-divider-ui></menu-divider-ui>
|
|
34
|
+
<menu-item-ui icon="export" text="Export" value="export"></menu-item-ui>
|
|
35
|
+
<menu-item-ui icon="printer" text="Print" value="print"></menu-item-ui>
|
|
36
|
+
</menu-ui>
|
|
37
|
+
```
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
# modal — Examples
|
|
2
|
+
|
|
3
|
+
## basic
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<button-ui text="Open Modal" variant="outline" onclick="this.nextElementSibling.open=true"></button-ui>
|
|
7
|
+
<modal-ui text="Confirm Action">
|
|
8
|
+
<p>Are you sure you want to proceed? This action requires your confirmation.</p>
|
|
9
|
+
<div slot="footer" style="display:flex; gap:var(--a-space-2); justify-content:flex-end;">
|
|
10
|
+
<button-ui text="Cancel" variant="ghost" onclick="this.closest('modal-ui').open=false"></button-ui>
|
|
11
|
+
<button-ui text="Confirm" variant="primary" onclick="this.closest('modal-ui').open=false"></button-ui>
|
|
12
|
+
</div>
|
|
13
|
+
</modal-ui>
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## size
|
|
17
|
+
|
|
18
|
+
```html
|
|
19
|
+
<button-ui text="Small" variant="outline" onclick="this.nextElementSibling.open=true"></button-ui>
|
|
20
|
+
<modal-ui text="Small Modal" size="sm">
|
|
21
|
+
<p>A compact modal for simple confirmations.</p>
|
|
22
|
+
</modal-ui>
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
## text
|
|
26
|
+
|
|
27
|
+
```html
|
|
28
|
+
<button-ui text="With Title" variant="outline" onclick="this.nextElementSibling.open=true"></button-ui>
|
|
29
|
+
<modal-ui text="Edit Profile">
|
|
30
|
+
<div style="display:flex; flex-direction:column; gap:var(--a-space-3);">
|
|
31
|
+
<field-ui label="Name">
|
|
32
|
+
<input-ui placeholder="Your name"></input-ui>
|
|
33
|
+
</field-ui>
|
|
34
|
+
<field-ui label="Email">
|
|
35
|
+
<input-ui placeholder="you@example.com"></input-ui>
|
|
36
|
+
</field-ui>
|
|
37
|
+
</div>
|
|
38
|
+
<div slot="footer" style="display:flex; gap:var(--a-space-2); justify-content:flex-end;">
|
|
39
|
+
<button-ui text="Cancel" variant="ghost" onclick="this.closest('modal-ui').open=false"></button-ui>
|
|
40
|
+
<button-ui text="Save" variant="primary" onclick="this.closest('modal-ui').open=false"></button-ui>
|
|
41
|
+
</div>
|
|
42
|
+
</modal-ui>
|
|
43
|
+
```
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
# nav — Examples
|
|
2
|
+
|
|
3
|
+
## variant — primary
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<nav-ui style="width:240px;height:280px;border:1px solid var(--a-border);border-radius:var(--a-radius-md);padding:var(--a-space-2);">
|
|
7
|
+
<nav-item-ui text="Dashboard" icon="house" value="dashboard" selected></nav-item-ui>
|
|
8
|
+
<nav-item-ui text="Reports" icon="chart-bar" value="reports"></nav-item-ui>
|
|
9
|
+
<nav-group-ui text="Settings" icon="gear">
|
|
10
|
+
<nav-item-ui text="Profile" value="settings/profile"></nav-item-ui>
|
|
11
|
+
<nav-item-ui text="Billing" value="settings/billing"></nav-item-ui>
|
|
12
|
+
<nav-item-ui text="Team" value="settings/team"></nav-item-ui>
|
|
13
|
+
</nav-group-ui>
|
|
14
|
+
</nav-ui>
|
|
15
|
+
```
|
|
16
|
+
|
|
17
|
+
## variant — section
|
|
18
|
+
|
|
19
|
+
```html
|
|
20
|
+
<nav-ui variant="section" heading="Documentation" style="width:240px;">
|
|
21
|
+
<nav-item-ui text="Overview" value="docs/overview" selected></nav-item-ui>
|
|
22
|
+
<nav-item-ui text="Quickstart" value="docs/quickstart"></nav-item-ui>
|
|
23
|
+
<nav-item-ui text="API reference" value="docs/api"></nav-item-ui>
|
|
24
|
+
<nav-item-ui text="Examples" value="docs/examples"></nav-item-ui>
|
|
25
|
+
</nav-ui>
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
## collapsed
|
|
29
|
+
|
|
30
|
+
```html
|
|
31
|
+
<nav-ui collapsed style="width:64px;height:280px;border:1px solid var(--a-border);border-radius:var(--a-radius-md);padding:var(--a-space-2);">
|
|
32
|
+
<nav-item-ui text="Dashboard" icon="house" value="dashboard" selected></nav-item-ui>
|
|
33
|
+
<nav-item-ui text="Reports" icon="chart-bar" value="reports"></nav-item-ui>
|
|
34
|
+
<nav-group-ui text="Settings" icon="gear">
|
|
35
|
+
<nav-item-ui text="Profile" value="settings/profile"></nav-item-ui>
|
|
36
|
+
<nav-item-ui text="Billing" value="settings/billing"></nav-item-ui>
|
|
37
|
+
</nav-group-ui>
|
|
38
|
+
</nav-ui>
|
|
39
|
+
```
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# nav-group — Examples
|
|
2
|
+
|
|
3
|
+
## text + icon
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<nav-ui style="width:240px;border:1px solid var(--a-border);border-radius:var(--a-radius-md);padding:var(--a-space-2);">
|
|
7
|
+
<nav-group-ui text="Settings" icon="gear">
|
|
8
|
+
<nav-item-ui text="Profile" value="settings/profile"></nav-item-ui>
|
|
9
|
+
<nav-item-ui text="Billing" value="settings/billing"></nav-item-ui>
|
|
10
|
+
</nav-group-ui>
|
|
11
|
+
</nav-ui>
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## badge
|
|
15
|
+
|
|
16
|
+
```html
|
|
17
|
+
<nav-ui style="width:240px;border:1px solid var(--a-border);border-radius:var(--a-radius-md);padding:var(--a-space-2);">
|
|
18
|
+
<nav-group-ui text="Notifications" icon="bell" badge="3" open>
|
|
19
|
+
<nav-item-ui text="Mentions" value="notif/mentions"></nav-item-ui>
|
|
20
|
+
<nav-item-ui text="Follows" value="notif/follows"></nav-item-ui>
|
|
21
|
+
</nav-group-ui>
|
|
22
|
+
</nav-ui>
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
## variant — section
|
|
26
|
+
|
|
27
|
+
```html
|
|
28
|
+
<nav-ui variant="section" style="width:240px;">
|
|
29
|
+
<nav-group-ui text="Reference" variant="section">
|
|
30
|
+
<nav-item-ui text="Components" value="ref/components"></nav-item-ui>
|
|
31
|
+
<nav-item-ui text="Tokens" value="ref/tokens"></nav-item-ui>
|
|
32
|
+
<nav-item-ui text="Patterns" value="ref/patterns"></nav-item-ui>
|
|
33
|
+
</nav-group-ui>
|
|
34
|
+
</nav-ui>
|
|
35
|
+
```
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
# nav-item — Examples
|
|
2
|
+
|
|
3
|
+
## text + icon
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<nav-ui style="width:200px;">
|
|
7
|
+
<nav-item-ui text="Dashboard" value="dashboard"></nav-item-ui>
|
|
8
|
+
</nav-ui>
|
|
9
|
+
```
|
|
10
|
+
|
|
11
|
+
## selected
|
|
12
|
+
|
|
13
|
+
```html
|
|
14
|
+
<nav-ui style="width:200px;">
|
|
15
|
+
<nav-item-ui text="Inbox" icon="envelope" value="inbox" selected></nav-item-ui>
|
|
16
|
+
</nav-ui>
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
## disabled
|
|
20
|
+
|
|
21
|
+
```html
|
|
22
|
+
<nav-ui style="width:200px;">
|
|
23
|
+
<nav-item-ui text="Archived" icon="archive" value="archived" disabled></nav-item-ui>
|
|
24
|
+
</nav-ui>
|
|
25
|
+
```
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# noodles — Examples
|
|
2
|
+
|
|
3
|
+
## curve
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<noodles-ui id="noodle-bezier" style="position:relative; width:400px; height:200px; border:1px solid var(--a-border-subtle); border-radius:var(--a-radius-md);">
|
|
7
|
+
<div data-noodle-port="right" style="position:absolute; left:20px; top:30px; padding:var(--a-space-2) var(--a-space-3); background:var(--a-canvas-2); border:1px solid var(--a-border-subtle); border-radius:var(--a-radius-sm);">Node A</div>
|
|
8
|
+
<div data-noodle-port="left right" style="position:absolute; left:160px; top:90px; padding:var(--a-space-2) var(--a-space-3); background:var(--a-canvas-2); border:1px solid var(--a-border-subtle); border-radius:var(--a-radius-sm);">Node B</div>
|
|
9
|
+
<div data-noodle-port="left" style="position:absolute; left:300px; top:40px; padding:var(--a-space-2) var(--a-space-3); background:var(--a-canvas-2); border:1px solid var(--a-border-subtle); border-radius:var(--a-radius-sm);">Node C</div>
|
|
10
|
+
</noodles-ui>
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## editable + show-ports
|
|
14
|
+
|
|
15
|
+
```html
|
|
16
|
+
<noodles-ui id="noodle-editable" editable show-ports style="position:relative; width:400px; height:200px; border:1px solid var(--a-border-subtle); border-radius:var(--a-radius-md);">
|
|
17
|
+
<div data-noodle-port="right bottom" style="position:absolute; left:20px; top:30px; padding:var(--a-space-2) var(--a-space-3); background:var(--a-canvas-2); border:1px solid var(--a-border-subtle); border-radius:var(--a-radius-sm);">Source</div>
|
|
18
|
+
<div data-noodle-port="left right top" style="position:absolute; left:160px; top:100px; padding:var(--a-space-2) var(--a-space-3); background:var(--a-canvas-2); border:1px solid var(--a-border-subtle); border-radius:var(--a-radius-sm);">Middle</div>
|
|
19
|
+
<div data-noodle-port="left top" style="position:absolute; left:300px; top:40px; padding:var(--a-space-2) var(--a-space-3); background:var(--a-canvas-2); border:1px solid var(--a-border-subtle); border-radius:var(--a-radius-sm);">Target</div>
|
|
20
|
+
</noodles-ui>
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
## animated
|
|
24
|
+
|
|
25
|
+
```html
|
|
26
|
+
<noodles-ui id="noodle-animated" animated style="position:relative; width:400px; height:160px; border:1px solid var(--a-border-subtle); border-radius:var(--a-radius-md);">
|
|
27
|
+
<div data-noodle-port="right" style="position:absolute; left:20px; top:50px; padding:var(--a-space-2) var(--a-space-3); background:var(--a-canvas-2); border:1px solid var(--a-border-subtle); border-radius:var(--a-radius-sm);">Start</div>
|
|
28
|
+
<div data-noodle-port="left" style="position:absolute; left:280px; top:50px; padding:var(--a-space-2) var(--a-space-3); background:var(--a-canvas-2); border:1px solid var(--a-border-subtle); border-radius:var(--a-radius-sm);">End</div>
|
|
29
|
+
</noodles-ui>
|
|
30
|
+
```
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
# option-card — Examples
|
|
2
|
+
|
|
3
|
+
## Default
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<col-ui gap="2" role="radiogroup" aria-label="Demo">
|
|
7
|
+
<option-card-ui name="demo-1" value="build" checked heading="I'm building a product" description="Spinning up a new project — design, ship, iterate."></option-card-ui>
|
|
8
|
+
<option-card-ui name="demo-1" value="explore" heading="I'm exploring the product" description="Kicking the tires before bringing a team along."></option-card-ui>
|
|
9
|
+
<option-card-ui name="demo-1" value="migrate" heading="I'm migrating from another tool" description="Moving an existing workspace and want a smooth port."></option-card-ui>
|
|
10
|
+
</col-ui>
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Rich heading slot
|
|
14
|
+
|
|
15
|
+
```html
|
|
16
|
+
<col-ui gap="2" role="radiogroup" aria-label="Plan">
|
|
17
|
+
<option-card-ui name="demo-plan" value="free" description="Up to 5 members · 10 projects · community support">
|
|
18
|
+
<span slot="heading">
|
|
19
|
+
Free
|
|
20
|
+
<text-ui color="subtle" size="sm">· $0/mo</text-ui>
|
|
21
|
+
</span>
|
|
22
|
+
</option-card-ui>
|
|
23
|
+
<option-card-ui name="demo-plan" value="pro" checked description="Unlimited members · advanced charts · 100 GB storage">
|
|
24
|
+
<span slot="heading">
|
|
25
|
+
Pro
|
|
26
|
+
<text-ui color="subtle" size="sm">· $49/mo</text-ui>
|
|
27
|
+
<badge-ui text="14-day trial" variant="accent"></badge-ui>
|
|
28
|
+
</span>
|
|
29
|
+
</option-card-ui>
|
|
30
|
+
<option-card-ui name="demo-plan" value="team" description="Everything in Pro · SSO · audit log · 1 TB storage">
|
|
31
|
+
<span slot="heading">
|
|
32
|
+
Team
|
|
33
|
+
<text-ui color="subtle" size="sm">· $129/mo</text-ui>
|
|
34
|
+
</span>
|
|
35
|
+
</option-card-ui>
|
|
36
|
+
</col-ui>
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
## With leading icon
|
|
40
|
+
|
|
41
|
+
```html
|
|
42
|
+
<col-ui gap="2" role="radiogroup" aria-label="Storage">
|
|
43
|
+
<option-card-ui name="demo-icon" value="local" icon="hard-drive" checked heading="Local storage" description="Files stay on this device. No sync, no upload."></option-card-ui>
|
|
44
|
+
<option-card-ui name="demo-icon" value="cloud" icon="cloud-arrow-up" heading="Cloud storage" description="Files sync across devices and backup automatically."></option-card-ui>
|
|
45
|
+
<option-card-ui name="demo-icon" value="hybrid" icon="arrows-clockwise" heading="Hybrid" description="Cache locally, sync changes to the cloud in the background."></option-card-ui>
|
|
46
|
+
</col-ui>
|
|
47
|
+
```
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# otp-input — Examples
|
|
2
|
+
|
|
3
|
+
## length
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<otp-input-ui></otp-input-ui>
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## disabled
|
|
10
|
+
|
|
11
|
+
```html
|
|
12
|
+
<otp-input-ui disabled></otp-input-ui>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## name
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<otp-input-ui name="otp"></otp-input-ui>
|
|
19
|
+
```
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# page — Examples
|
|
2
|
+
|
|
3
|
+
## Basic usage
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<page-ui max-width="prose" padding="6">
|
|
7
|
+
<header-ui>
|
|
8
|
+
<text-ui variant="title">Welcome back</text-ui>
|
|
9
|
+
</header-ui>
|
|
10
|
+
<section-ui>
|
|
11
|
+
<text-ui>Sign in to continue.</text-ui>
|
|
12
|
+
</section-ui>
|
|
13
|
+
<footer-ui>
|
|
14
|
+
<button-ui text="Sign in" variant="solid" stretch></button-ui>
|
|
15
|
+
</footer-ui>
|
|
16
|
+
</page-ui>
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
## Sticky header
|
|
20
|
+
|
|
21
|
+
```html
|
|
22
|
+
<page-ui max-width="prose" padding="6" sticky-header>
|
|
23
|
+
<header-ui>
|
|
24
|
+
<text-ui variant="title">Long article</text-ui>
|
|
25
|
+
</header-ui>
|
|
26
|
+
<section-ui>
|
|
27
|
+
<!-- long content -->
|
|
28
|
+
</section-ui>
|
|
29
|
+
</page-ui>
|
|
30
|
+
```
|
|
31
|
+
|
|
32
|
+
## Composition with <admin-shell>
|
|
33
|
+
|
|
34
|
+
```html
|
|
35
|
+
<admin-shell>
|
|
36
|
+
<header-ui slot="leading">…</header-ui>
|
|
37
|
+
<aside-ui slot="leading">…</aside-ui>
|
|
38
|
+
<section-ui>
|
|
39
|
+
<page-ui max-width="prose" padding="6">
|
|
40
|
+
<!-- omit [scroll] — the shell scrolls -->
|
|
41
|
+
<header-ui>…</header-ui>
|
|
42
|
+
<section-ui>…</section-ui>
|
|
43
|
+
</page-ui>
|
|
44
|
+
</section-ui>
|
|
45
|
+
</admin-shell>
|
|
46
|
+
```
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# pagination — Examples
|
|
2
|
+
|
|
3
|
+
## basic (5 pages)
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<pagination-ui page="1" total="5"></pagination-ui>
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## variant
|
|
10
|
+
|
|
11
|
+
```html
|
|
12
|
+
<pagination-ui page="3" total="10"></pagination-ui>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## size
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<pagination-ui size="sm" total="100" page="1"></pagination-ui>
|
|
19
|
+
```
|
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
# pane — Examples
|
|
2
|
+
|
|
3
|
+
## basic
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<pane-ui>
|
|
7
|
+
<header>Details</header>
|
|
8
|
+
<section>
|
|
9
|
+
<div data-col>
|
|
10
|
+
<p>This is basic pane content. Click the header to collapse.</p>
|
|
11
|
+
</div>
|
|
12
|
+
</section>
|
|
13
|
+
</pane-ui>
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
## collapsed
|
|
17
|
+
|
|
18
|
+
```html
|
|
19
|
+
<pane-ui collapsed>
|
|
20
|
+
<header>Collapsed Pane</header>
|
|
21
|
+
<section>
|
|
22
|
+
<div data-col>
|
|
23
|
+
<p>This content is hidden until the pane is expanded.</p>
|
|
24
|
+
</div>
|
|
25
|
+
</section>
|
|
26
|
+
</pane-ui>
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
## resizable
|
|
30
|
+
|
|
31
|
+
```html
|
|
32
|
+
<pane-ui resizable min-width="200" max-width="500" style="width:300px;">
|
|
33
|
+
<header>Resizable</header>
|
|
34
|
+
<section>
|
|
35
|
+
<div data-col>
|
|
36
|
+
<p>Drag the right edge to resize this pane between 200px and 500px.</p>
|
|
37
|
+
</div>
|
|
38
|
+
</section>
|
|
39
|
+
</pane-ui>
|
|
40
|
+
```
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# pipeline-status — Examples
|
|
2
|
+
|
|
3
|
+
## stage
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<pipeline-status-ui stage="Building catalog" message="Reading 100 patterns from disk..."></pipeline-status-ui>
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## message
|
|
10
|
+
|
|
11
|
+
```html
|
|
12
|
+
<pipeline-status-ui stage="Running evals" message="32 / 100 intents scored..."></pipeline-status-ui>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## complete
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<pipeline-status-ui stage="Done" message="All 100 intents passed" status="completed"></pipeline-status-ui>
|
|
19
|
+
```
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
# popover — Examples
|
|
2
|
+
|
|
3
|
+
## click trigger
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<popover-ui trigger="click">
|
|
7
|
+
<button-ui slot="trigger" text="Click me" variant="outline"></button-ui>
|
|
8
|
+
<div slot="content" style="padding:var(--a-space-3);">
|
|
9
|
+
<p>This popover opens on click and closes on click outside or Escape.</p>
|
|
10
|
+
</div>
|
|
11
|
+
</popover-ui>
|
|
12
|
+
```
|
|
13
|
+
|
|
14
|
+
## hover trigger
|
|
15
|
+
|
|
16
|
+
```html
|
|
17
|
+
<popover-ui trigger="hover">
|
|
18
|
+
<button-ui slot="trigger" text="Hover me" variant="outline"></button-ui>
|
|
19
|
+
<div slot="content" style="padding:var(--a-space-3);">
|
|
20
|
+
<p>This popover opens on hover and stays open while the pointer is over it.</p>
|
|
21
|
+
</div>
|
|
22
|
+
</popover-ui>
|
|
23
|
+
```
|
|
24
|
+
|
|
25
|
+
## placement
|
|
26
|
+
|
|
27
|
+
```html
|
|
28
|
+
<popover-ui placement="bottom">
|
|
29
|
+
<button-ui slot="trigger" text="Bottom" variant="outline" size="sm"></button-ui>
|
|
30
|
+
<div slot="content" style="padding:var(--a-space-3);">
|
|
31
|
+
<p>Placed below the trigger.</p>
|
|
32
|
+
</div>
|
|
33
|
+
</popover-ui>
|
|
34
|
+
```
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# progress — Examples
|
|
2
|
+
|
|
3
|
+
## value
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<progress-ui value="0" style="width:200px"></progress-ui>
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## indeterminate
|
|
10
|
+
|
|
11
|
+
```html
|
|
12
|
+
<progress-ui style="width:200px"></progress-ui>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## variant
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<progress-ui value="60" variant="bar" style="width:200px"></progress-ui>
|
|
19
|
+
```
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# progress-row — Examples
|
|
2
|
+
|
|
3
|
+
## Basic
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<progress-row-ui label="Storage" value="42"></progress-row-ui>
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## With Meta
|
|
10
|
+
|
|
11
|
+
```html
|
|
12
|
+
<progress-row-ui label="Documents" value="65" meta="6.5 GB / 10 GB"></progress-row-ui>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## Variants
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<progress-row-ui label="Healthy" value="30" meta="30%" variant="success"></progress-row-ui>
|
|
19
|
+
```
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# radio — Examples
|
|
2
|
+
|
|
3
|
+
## checked
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<radio-ui label="Unchecked" name="demo-state"></radio-ui>
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## disabled
|
|
10
|
+
|
|
11
|
+
```html
|
|
12
|
+
<radio-ui label="Disabled Unchecked" name="demo-dis" disabled></radio-ui>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## label
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<radio-ui label="With Label" name="demo-label"></radio-ui>
|
|
19
|
+
```
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# range — Examples
|
|
2
|
+
|
|
3
|
+
## default
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<range-ui value="50"></range-ui>
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## label + value + suffix
|
|
10
|
+
|
|
11
|
+
```html
|
|
12
|
+
<range-ui label="Width" value="200" min="0" max="500" suffix="px"></range-ui>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## min / max / step
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<range-ui label="Font Size" value="16" min="8" max="72" step="1" suffix="px"></range-ui>
|
|
19
|
+
```
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# rating — Examples
|
|
2
|
+
|
|
3
|
+
## Basic
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<rating-ui value="3" readonly></rating-ui>
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## Interactive
|
|
10
|
+
|
|
11
|
+
```html
|
|
12
|
+
<rating-ui value="0" name="rating-basic"></rating-ui>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## icon
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<rating-ui value="4" icon="heart" variant="warning" readonly></rating-ui>
|
|
19
|
+
```
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# richtext — Examples
|
|
2
|
+
|
|
3
|
+
## markdown
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<richtext-ui markdown="# Hello world Welcome to **AdiaUI**. This paragraph was parsed from markdown: - Lists - Render - Cleanly `inline code` and [links](https://example.com) work too."></richtext-ui>
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## src
|
|
10
|
+
|
|
11
|
+
```html
|
|
12
|
+
<richtext-ui src="/README.md"></richtext-ui>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## code blocks
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<richtext-ui markdown="## Example ```js function greet(name) { return `Hello, ${name}!`; } ``` Inline `code` also works."></richtext-ui>
|
|
19
|
+
```
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
# search — Examples
|
|
2
|
+
|
|
3
|
+
## Default
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<search-ui></search-ui>
|
|
7
|
+
```
|
|
8
|
+
|
|
9
|
+
## placeholder
|
|
10
|
+
|
|
11
|
+
```html
|
|
12
|
+
<search-ui placeholder="Find components..."></search-ui>
|
|
13
|
+
```
|
|
14
|
+
|
|
15
|
+
## debounce
|
|
16
|
+
|
|
17
|
+
```html
|
|
18
|
+
<search-ui debounce="100" placeholder="Fast (100ms)"></search-ui>
|
|
19
|
+
```
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
# section — Examples
|
|
2
|
+
|
|
3
|
+
## Basic usage
|
|
4
|
+
|
|
5
|
+
```html
|
|
6
|
+
<card-ui>
|
|
7
|
+
<header-ui>
|
|
8
|
+
<text-ui variant="title">Settings</text-ui>
|
|
9
|
+
</header-ui>
|
|
10
|
+
<section-ui>
|
|
11
|
+
<col-ui gap="md">
|
|
12
|
+
<field-ui label="Name">
|
|
13
|
+
<input-ui name="name"></input-ui>
|
|
14
|
+
</field-ui>
|
|
15
|
+
<field-ui label="Email">
|
|
16
|
+
<input-ui name="email" type="email"></input-ui>
|
|
17
|
+
</field-ui>
|
|
18
|
+
</col-ui>
|
|
19
|
+
</section-ui>
|
|
20
|
+
</card-ui>
|
|
21
|
+
```
|
|
22
|
+
|
|
23
|
+
## Bleed
|
|
24
|
+
|
|
25
|
+
```html
|
|
26
|
+
<card-ui>
|
|
27
|
+
<header-ui>
|
|
28
|
+
<text-ui variant="title">Cover image</text-ui>
|
|
29
|
+
</header-ui>
|
|
30
|
+
<section-ui bleed>
|
|
31
|
+
<img src="cover.jpg" style="width: 100%; display: block;">
|
|
32
|
+
</section-ui>
|
|
33
|
+
<section-ui>
|
|
34
|
+
<text-ui>Caption text inside a normal padded section.</text-ui>
|
|
35
|
+
</section-ui>
|
|
36
|
+
</card-ui>
|
|
37
|
+
```
|