@adia-ai/web-components 0.0.28 → 0.0.29
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/README.md +4 -8
- package/a2ui/index.js +1 -1
- package/components/canvas/canvas.js +1 -1
- package/components/feed/feed.css +9 -0
- package/components/feed/feed.js +118 -9
- package/components/toast/toast.js +48 -178
- package/index.css +3 -2
- package/index.js +15 -7
- package/package.json +1 -5
- package/patterns/a2ui-root/a2ui-root.a2ui.json +0 -125
- package/patterns/a2ui-root/a2ui-root.js +0 -191
- package/patterns/a2ui-root/a2ui-root.yaml +0 -87
- package/patterns/adia-chat/adia-chat.a2ui.json +0 -149
- package/patterns/adia-chat/adia-chat.css +0 -10
- package/patterns/adia-chat/adia-chat.js +0 -297
- package/patterns/adia-chat/adia-chat.yaml +0 -118
- package/patterns/adia-chat/css/adia-chat.empty.css +0 -12
- package/patterns/adia-chat/css/adia-chat.layout.css +0 -60
- package/patterns/adia-chat/css/adia-chat.markdown.css +0 -74
- package/patterns/adia-chat/css/adia-chat.messages.css +0 -87
- package/patterns/adia-chat/css/adia-chat.streaming.css +0 -30
- package/patterns/adia-chat/css/adia-chat.tokens.css +0 -95
- package/patterns/adia-editor/adia-editor.a2ui.json +0 -73
- package/patterns/adia-editor/adia-editor.css +0 -6
- package/patterns/adia-editor/adia-editor.js +0 -56
- package/patterns/adia-editor/adia-editor.yaml +0 -59
- package/patterns/adia-editor/css/adia-editor.layout.css +0 -171
- package/patterns/adia-editor/css/adia-editor.tokens.css +0 -28
- package/patterns/app-nav/app-nav.a2ui.json +0 -89
- package/patterns/app-nav/app-nav.css +0 -92
- package/patterns/app-nav/app-nav.js +0 -112
- package/patterns/app-nav/app-nav.yaml +0 -54
- package/patterns/app-nav-group/app-nav-group.a2ui.json +0 -82
- package/patterns/app-nav-group/app-nav-group.css +0 -264
- package/patterns/app-nav-group/app-nav-group.js +0 -116
- package/patterns/app-nav-group/app-nav-group.yaml +0 -59
- package/patterns/app-nav-item/app-nav-item.a2ui.json +0 -83
- package/patterns/app-nav-item/app-nav-item.css +0 -162
- package/patterns/app-nav-item/app-nav-item.js +0 -42
- package/patterns/app-nav-item/app-nav-item.yaml +0 -62
- package/patterns/app-shell/app-shell.a2ui.json +0 -129
- package/patterns/app-shell/app-shell.css +0 -14
- package/patterns/app-shell/app-shell.js +0 -251
- package/patterns/app-shell/app-shell.yaml +0 -89
- package/patterns/app-shell/css/app-shell.collapsed.css +0 -86
- package/patterns/app-shell/css/app-shell.helpers.css +0 -42
- package/patterns/app-shell/css/app-shell.main.css +0 -172
- package/patterns/app-shell/css/app-shell.shell.css +0 -44
- package/patterns/app-shell/css/app-shell.sidebar.css +0 -161
- package/patterns/app-shell/css/app-shell.templates.css +0 -214
- package/patterns/app-shell/css/app-shell.tokens.css +0 -119
- package/patterns/gen-ui/gen-ui.a2ui.json +0 -72
- package/patterns/gen-ui/gen-ui.css +0 -83
- package/patterns/gen-ui/gen-ui.js +0 -136
- package/patterns/gen-ui/gen-ui.yaml +0 -43
- package/patterns/index.js +0 -11
- package/patterns/section-nav/section-nav.a2ui.json +0 -91
- package/patterns/section-nav/section-nav.css +0 -60
- package/patterns/section-nav/section-nav.js +0 -42
- package/patterns/section-nav/section-nav.yaml +0 -58
- package/patterns/section-nav-group/section-nav-group.a2ui.json +0 -95
- package/patterns/section-nav-group/section-nav-group.css +0 -74
- package/patterns/section-nav-group/section-nav-group.js +0 -84
- package/patterns/section-nav-group/section-nav-group.yaml +0 -66
- package/patterns/section-nav-item/section-nav-item.a2ui.json +0 -97
- package/patterns/section-nav-item/section-nav-item.css +0 -106
- package/patterns/section-nav-item/section-nav-item.js +0 -66
- package/patterns/section-nav-item/section-nav-item.yaml +0 -70
- package/styles/layouts/admin.css +0 -7
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
/* ═══════════════════════════════════════════════════════════════
|
|
2
|
-
adia-chat-ui — Design tokens
|
|
3
|
-
═══════════════════════════════════════════════════════════════ */
|
|
4
|
-
|
|
5
|
-
:where(adia-chat-ui) {
|
|
6
|
-
/* Layout */
|
|
7
|
-
--chat-bg: var(--a-canvas-0);
|
|
8
|
-
--chat-border: unset;
|
|
9
|
-
--chat-radius: unset;
|
|
10
|
-
|
|
11
|
-
/* Header */
|
|
12
|
-
--chat-header-height: var(--a-chrome-app-header-height);
|
|
13
|
-
--chat-header-px: var(--a-space-4);
|
|
14
|
-
--chat-header-gap: var(--a-space-2);
|
|
15
|
-
--chat-header-border: 1px solid var(--a-border-subtle);
|
|
16
|
-
|
|
17
|
-
/* Messages area */
|
|
18
|
-
--chat-messages-px: var(--a-space-4);
|
|
19
|
-
--chat-messages-py: var(--a-space-4);
|
|
20
|
-
--chat-messages-gap: var(--a-space-3);
|
|
21
|
-
--chat-message-max-width: 85%;
|
|
22
|
-
|
|
23
|
-
/* User bubble */
|
|
24
|
-
--chat-user-bg: var(--a-primary);
|
|
25
|
-
--chat-user-fg: var(--a-primary-fg);
|
|
26
|
-
--chat-user-radius: var(--a-radius-md);
|
|
27
|
-
--chat-user-tail-radius: var(--a-radius-sm);
|
|
28
|
-
--chat-user-px: var(--a-space-3);
|
|
29
|
-
--chat-user-py: var(--a-space-1);
|
|
30
|
-
|
|
31
|
-
/* Assistant bubble */
|
|
32
|
-
--chat-assistant-bg: var(--a-canvas-2);
|
|
33
|
-
--chat-assistant-fg: var(--a-fg);
|
|
34
|
-
--chat-assistant-radius: var(--a-radius-lg);
|
|
35
|
-
--chat-assistant-tail-radius: var(--a-radius-sm);
|
|
36
|
-
--chat-assistant-px: var(--a-space-3);
|
|
37
|
-
--chat-assistant-py: var(--a-space-1);
|
|
38
|
-
|
|
39
|
-
/* Avatar */
|
|
40
|
-
--chat-avatar-size: 1.75rem;
|
|
41
|
-
--chat-avatar-bg: var(--chat-assistant-bg);
|
|
42
|
-
--chat-avatar-fg: var(--chat-assistant-fg);
|
|
43
|
-
--chat-avatar-font: var(--a-ui-sm);
|
|
44
|
-
--chat-avatar-weight: var(--a-weight-semibold);
|
|
45
|
-
|
|
46
|
-
/* Streaming cursor */
|
|
47
|
-
--chat-cursor-width: 2px;
|
|
48
|
-
--chat-cursor-color: currentColor;
|
|
49
|
-
--chat-cursor-speed: 0.8s;
|
|
50
|
-
|
|
51
|
-
/* Footer / input area */
|
|
52
|
-
--chat-footer-px: var(--a-space-3);
|
|
53
|
-
--chat-footer-py: var(--a-space-3);
|
|
54
|
-
|
|
55
|
-
/* Message actions */
|
|
56
|
-
--chat-actions-gap: var(--a-space-1);
|
|
57
|
-
|
|
58
|
-
/* Code blocks inside messages */
|
|
59
|
-
--chat-code-bg: var(--a-canvas-2);
|
|
60
|
-
--chat-code-radius: var(--a-radius-md);
|
|
61
|
-
|
|
62
|
-
/* Typography */
|
|
63
|
-
--chat-font-size: var(--a-ui-size);
|
|
64
|
-
--chat-line-height: var(--a-leading-normal);
|
|
65
|
-
--chat-weight-semibold: var(--a-weight-semibold);
|
|
66
|
-
|
|
67
|
-
/* Header typography */
|
|
68
|
-
--chat-header-name-font: var(--a-ui-lg);
|
|
69
|
-
--chat-header-status-font: var(--a-ui-md);
|
|
70
|
-
--chat-header-status-fg: var(--a-fg-muted);
|
|
71
|
-
|
|
72
|
-
/* Error */
|
|
73
|
-
--chat-error-gap: var(--a-space-2);
|
|
74
|
-
--chat-error-fg: var(--a-danger-strong);
|
|
75
|
-
--chat-error-font: var(--a-ui-sm);
|
|
76
|
-
|
|
77
|
-
/* Message actions */
|
|
78
|
-
--chat-actions-duration: var(--a-duration-fast);
|
|
79
|
-
--chat-actions-easing: var(--a-easing);
|
|
80
|
-
|
|
81
|
-
/* Avatar */
|
|
82
|
-
--chat-avatar-radius: var(--a-radius-full);
|
|
83
|
-
|
|
84
|
-
/* Streaming — thinking */
|
|
85
|
-
--chat-thinking-fg: var(--a-fg-muted);
|
|
86
|
-
|
|
87
|
-
/* Markdown — inline code */
|
|
88
|
-
--chat-code-inline-radius: var(--a-radius-sm);
|
|
89
|
-
--chat-code-inline-family: var(--a-font-family-code);
|
|
90
|
-
|
|
91
|
-
/* Markdown — pre blocks */
|
|
92
|
-
--chat-code-block-px: var(--a-space-3);
|
|
93
|
-
--chat-code-block-my: var(--a-space-2);
|
|
94
|
-
--chat-code-block-font: var(--a-ui-sm);
|
|
95
|
-
}
|
|
@@ -1,73 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
-
"$id": "https://adiaui.dev/a2ui/v0_9/components/Editor.json",
|
|
4
|
-
"title": "Editor",
|
|
5
|
-
"description": "Behavior-only editor shell for design-tool layouts. Author provides the\nstructural DOM — header (topbar), [data-editor-body] with pane-ui children\n([data-left], [data-right]), [data-canvas] for the central surface, and\na footer (statusbar). adia-editor wires select-ui[data-options] for\nJSON-parsed option lists.\n",
|
|
6
|
-
"type": "object",
|
|
7
|
-
"allOf": [
|
|
8
|
-
{
|
|
9
|
-
"$ref": "common_types.json#/$defs/ComponentCommon"
|
|
10
|
-
},
|
|
11
|
-
{
|
|
12
|
-
"$ref": "common_types.json#/$defs/CatalogComponentCommon"
|
|
13
|
-
}
|
|
14
|
-
],
|
|
15
|
-
"properties": {
|
|
16
|
-
"component": {
|
|
17
|
-
"const": "Editor"
|
|
18
|
-
}
|
|
19
|
-
},
|
|
20
|
-
"required": [
|
|
21
|
-
"component"
|
|
22
|
-
],
|
|
23
|
-
"unevaluatedProperties": false,
|
|
24
|
-
"x-adiaui": {
|
|
25
|
-
"anti_patterns": [],
|
|
26
|
-
"category": "container",
|
|
27
|
-
"events": {},
|
|
28
|
-
"examples": [],
|
|
29
|
-
"keywords": [
|
|
30
|
-
"adia-editor",
|
|
31
|
-
"editor",
|
|
32
|
-
"design-tool",
|
|
33
|
-
"canvas-shell"
|
|
34
|
-
],
|
|
35
|
-
"name": "AdiaEditorElement",
|
|
36
|
-
"related": [
|
|
37
|
-
"Pane",
|
|
38
|
-
"Select",
|
|
39
|
-
"Toolbar"
|
|
40
|
-
],
|
|
41
|
-
"slots": {
|
|
42
|
-
"description": {
|
|
43
|
-
"description": "Secondary metadata inside <header> or <footer> — document name, artboard size, zoom level, etc. Muted color, --a-ui-sm size."
|
|
44
|
-
},
|
|
45
|
-
"default": {
|
|
46
|
-
"description": "Author provides header, [data-editor-body] wrapping pane-ui[data-left], [data-canvas], pane-ui[data-right], and an optional footer."
|
|
47
|
-
},
|
|
48
|
-
"action": {
|
|
49
|
-
"description": "Trailing control cluster inside <header> or <footer>. The first [slot=\"action\"] child pushes itself (and siblings) to the end of the bar; subsequent [slot=\"action\"] siblings flow with gap."
|
|
50
|
-
},
|
|
51
|
-
"action-leading": {
|
|
52
|
-
"description": "Leading (inline-start) control cluster inside <header> or <footer>. Pairs with [slot=\"action\"] to produce a dual-cluster bar with space-between alignment (e.g. Back ↔ Cancel/Next, Discard ↔ Publish). Replaces the legacy <span data-spacer> hack."
|
|
53
|
-
},
|
|
54
|
-
"heading": {
|
|
55
|
-
"description": "Primary label inside <header> or <footer>. Rendered with --editor-title-weight + the strong foreground token."
|
|
56
|
-
},
|
|
57
|
-
"icon": {
|
|
58
|
-
"description": "Leading glyph inside <header> or <footer> — status dot, app icon, zoom badge, etc. Muted color, size-aware."
|
|
59
|
-
}
|
|
60
|
-
},
|
|
61
|
-
"states": [
|
|
62
|
-
{
|
|
63
|
-
"description": "Default.",
|
|
64
|
-
"name": "idle"
|
|
65
|
-
}
|
|
66
|
-
],
|
|
67
|
-
"synonyms": {},
|
|
68
|
-
"tag": "adia-editor-ui",
|
|
69
|
-
"tokens": {},
|
|
70
|
-
"traits": [],
|
|
71
|
-
"version": 1
|
|
72
|
-
}
|
|
73
|
-
}
|
|
@@ -1,56 +0,0 @@
|
|
|
1
|
-
import { AdiaElement } from '../../core/element.js';
|
|
2
|
-
|
|
3
|
-
/**
|
|
4
|
-
* <adia-editor-ui> — Editor layout pattern.
|
|
5
|
-
*
|
|
6
|
-
* Behavior-only orchestrator for design tool UIs:
|
|
7
|
-
* topbar, navigator pane, center canvas, inspector pane, bottombar.
|
|
8
|
-
*
|
|
9
|
-
* Structure:
|
|
10
|
-
* <adia-editor-ui>
|
|
11
|
-
* <header>
|
|
12
|
-
* <span data-title>Editor</span>
|
|
13
|
-
* <span data-spacer></span>
|
|
14
|
-
* <button-ui icon="gear" variant="ghost" size="sm"></button-ui>
|
|
15
|
-
* </header>
|
|
16
|
-
* <div data-editor-body>
|
|
17
|
-
* <pane-ui data-left resizable>
|
|
18
|
-
* <header>Navigator</header>
|
|
19
|
-
* <section>...tree, layers...</section>
|
|
20
|
-
* </pane-ui>
|
|
21
|
-
* <div data-canvas>
|
|
22
|
-
* ...canvas content...
|
|
23
|
-
* </div>
|
|
24
|
-
* <pane-ui data-right resizable>
|
|
25
|
-
* <header>Inspector</header>
|
|
26
|
-
* <section>...form fields...</section>
|
|
27
|
-
* <footer>...actions...</footer>
|
|
28
|
-
* </pane-ui>
|
|
29
|
-
* </div>
|
|
30
|
-
* <footer>
|
|
31
|
-
* <span>Ready</span>
|
|
32
|
-
* <span data-spacer></span>
|
|
33
|
-
* <span>100%</span>
|
|
34
|
-
* </footer>
|
|
35
|
-
* </adia-editor-ui>
|
|
36
|
-
*/
|
|
37
|
-
class AdiaEditorElement extends AdiaElement {
|
|
38
|
-
static template = () => null;
|
|
39
|
-
|
|
40
|
-
connected() {
|
|
41
|
-
// Wire select options if present
|
|
42
|
-
this.#wireSelects();
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
#wireSelects() {
|
|
46
|
-
for (const sel of this.querySelectorAll('select-ui[data-options]')) {
|
|
47
|
-
try {
|
|
48
|
-
const opts = JSON.parse(sel.getAttribute('data-options'));
|
|
49
|
-
sel.options = opts;
|
|
50
|
-
} catch { /* skip invalid */ }
|
|
51
|
-
}
|
|
52
|
-
}
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
customElements.define('adia-editor-ui', AdiaEditorElement);
|
|
56
|
-
export { AdiaEditorElement };
|
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
$schema: ../../../../scripts/schemas/component.yaml.schema.json
|
|
2
|
-
name: AdiaEditorElement
|
|
3
|
-
tag: adia-editor-ui
|
|
4
|
-
component: Editor
|
|
5
|
-
category: container
|
|
6
|
-
version: 1
|
|
7
|
-
description: |
|
|
8
|
-
Behavior-only editor shell for design-tool layouts. Author provides the
|
|
9
|
-
structural DOM — header (topbar), [data-editor-body] with pane-ui children
|
|
10
|
-
([data-left], [data-right]), [data-canvas] for the central surface, and
|
|
11
|
-
a footer (statusbar). adia-editor wires select-ui[data-options] for
|
|
12
|
-
JSON-parsed option lists.
|
|
13
|
-
|
|
14
|
-
props: {} # Pure wrapper — no own props.
|
|
15
|
-
|
|
16
|
-
events: {} # Child interactions bubble through.
|
|
17
|
-
|
|
18
|
-
slots:
|
|
19
|
-
default:
|
|
20
|
-
description: >-
|
|
21
|
-
Author provides header, [data-editor-body] wrapping pane-ui[data-left],
|
|
22
|
-
[data-canvas], pane-ui[data-right], and an optional footer.
|
|
23
|
-
icon:
|
|
24
|
-
description: >-
|
|
25
|
-
Leading glyph inside <header> or <footer> — status dot, app icon,
|
|
26
|
-
zoom badge, etc. Muted color, size-aware.
|
|
27
|
-
heading:
|
|
28
|
-
description: >-
|
|
29
|
-
Primary label inside <header> or <footer>. Rendered with
|
|
30
|
-
--editor-title-weight + the strong foreground token.
|
|
31
|
-
description:
|
|
32
|
-
description: >-
|
|
33
|
-
Secondary metadata inside <header> or <footer> — document name,
|
|
34
|
-
artboard size, zoom level, etc. Muted color, --a-ui-sm size.
|
|
35
|
-
action:
|
|
36
|
-
description: >-
|
|
37
|
-
Trailing control cluster inside <header> or <footer>. The first
|
|
38
|
-
[slot="action"] child pushes itself (and siblings) to the end of
|
|
39
|
-
the bar; subsequent [slot="action"] siblings flow with gap.
|
|
40
|
-
action-leading:
|
|
41
|
-
description: >-
|
|
42
|
-
Leading (inline-start) control cluster inside <header> or <footer>.
|
|
43
|
-
Pairs with [slot="action"] to produce a dual-cluster bar with
|
|
44
|
-
space-between alignment (e.g. Back ↔ Cancel/Next, Discard ↔
|
|
45
|
-
Publish). Replaces the legacy <span data-spacer> hack.
|
|
46
|
-
|
|
47
|
-
states:
|
|
48
|
-
- name: idle
|
|
49
|
-
description: Default.
|
|
50
|
-
|
|
51
|
-
traits: []
|
|
52
|
-
|
|
53
|
-
a2ui:
|
|
54
|
-
rules:
|
|
55
|
-
- adia-editor is a layout skeleton. Children must follow the documented
|
|
56
|
-
structural DOM; the element wires behavior, not content.
|
|
57
|
-
|
|
58
|
-
keywords: [adia-editor, editor, design-tool, canvas-shell]
|
|
59
|
-
related: [Pane, Select, Toolbar]
|
|
@@ -1,171 +0,0 @@
|
|
|
1
|
-
/* ═══════════════════════════════════════════════════════════════
|
|
2
|
-
adia-editor-ui — Layout
|
|
3
|
-
|
|
4
|
-
Structure:
|
|
5
|
-
adia-editor-ui
|
|
6
|
-
header — topbar
|
|
7
|
-
[data-editor-body] — flex row: pane | canvas | pane
|
|
8
|
-
pane-ui — left navigator
|
|
9
|
-
[data-canvas] — center canvas
|
|
10
|
-
pane-ui — right inspector
|
|
11
|
-
footer — bottombar
|
|
12
|
-
═══════════════════════════════════════════════════════════════ */
|
|
13
|
-
|
|
14
|
-
adia-editor-ui {
|
|
15
|
-
box-sizing: border-box;
|
|
16
|
-
display: flex;
|
|
17
|
-
flex-direction: column;
|
|
18
|
-
height: 100%;
|
|
19
|
-
overflow: hidden;
|
|
20
|
-
background: var(--editor-bg);
|
|
21
|
-
}
|
|
22
|
-
|
|
23
|
-
/* ── Top bar ──
|
|
24
|
-
Slot contract (shared with > footer below):
|
|
25
|
-
[slot="icon"] leading glyph (status dot, app icon, etc.)
|
|
26
|
-
[slot="heading"] primary label; strong-weight token
|
|
27
|
-
[slot="description"] secondary metadata; muted
|
|
28
|
-
[slot="action"] trailing control cluster; first pushes to end
|
|
29
|
-
Authors may also place raw inline content (spans, buttons) directly
|
|
30
|
-
— those flow in source order. `[data-title]` / `<span data-spacer>`
|
|
31
|
-
are kept working for one release as deprecated hooks; migrate to
|
|
32
|
-
slots. */
|
|
33
|
-
adia-editor-ui > header {
|
|
34
|
-
display: flex;
|
|
35
|
-
align-items: center;
|
|
36
|
-
gap: var(--editor-bar-gap);
|
|
37
|
-
min-height: var(--editor-bar-height);
|
|
38
|
-
padding: 0 var(--editor-bar-px);
|
|
39
|
-
border-bottom: var(--editor-border);
|
|
40
|
-
font-size: var(--editor-bar-font);
|
|
41
|
-
color: var(--editor-bar-fg);
|
|
42
|
-
flex-shrink: 0;
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
adia-editor-ui > header [data-title],
|
|
46
|
-
adia-editor-ui > header > [slot="heading"] {
|
|
47
|
-
font-weight: var(--editor-title-weight);
|
|
48
|
-
color: var(--editor-bar-fg-strong);
|
|
49
|
-
}
|
|
50
|
-
|
|
51
|
-
adia-editor-ui > header > [slot="icon"] {
|
|
52
|
-
display: flex;
|
|
53
|
-
align-items: center;
|
|
54
|
-
flex-shrink: 0;
|
|
55
|
-
color: var(--editor-bar-fg);
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
adia-editor-ui > header > [slot="description"] {
|
|
59
|
-
color: var(--editor-bar-fg);
|
|
60
|
-
font-size: var(--a-ui-sm);
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
adia-editor-ui > header > [slot="action"] {
|
|
64
|
-
display: flex;
|
|
65
|
-
align-items: center;
|
|
66
|
-
gap: var(--editor-bar-gap);
|
|
67
|
-
flex-shrink: 0;
|
|
68
|
-
margin-inline-start: auto;
|
|
69
|
-
}
|
|
70
|
-
|
|
71
|
-
adia-editor-ui > header > [slot="action"] ~ [slot="action"] {
|
|
72
|
-
margin-inline-start: 0;
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
/* Dual-cluster: leading group on inline-start, trailing cluster on inline-end. */
|
|
76
|
-
adia-editor-ui > header > [slot="action-leading"] {
|
|
77
|
-
display: flex;
|
|
78
|
-
align-items: center;
|
|
79
|
-
gap: var(--editor-bar-gap);
|
|
80
|
-
flex-shrink: 0;
|
|
81
|
-
margin-inline-end: auto;
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
/* ── Body: pane | canvas | pane ── */
|
|
85
|
-
adia-editor-ui > [data-editor-body] {
|
|
86
|
-
display: flex;
|
|
87
|
-
flex: 1;
|
|
88
|
-
min-width: 0;
|
|
89
|
-
min-height: 0;
|
|
90
|
-
}
|
|
91
|
-
|
|
92
|
-
/* ── Canvas ── */
|
|
93
|
-
adia-editor-ui [data-canvas] {
|
|
94
|
-
flex: 1;
|
|
95
|
-
min-width: 0;
|
|
96
|
-
display: flex;
|
|
97
|
-
align-items: center;
|
|
98
|
-
justify-content: center;
|
|
99
|
-
background: var(--editor-canvas-bg);
|
|
100
|
-
color: var(--editor-canvas-fg);
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
/* ── Panes ── */
|
|
104
|
-
adia-editor-ui pane-ui {
|
|
105
|
-
--pane-radius: 0;
|
|
106
|
-
height: 100%;
|
|
107
|
-
flex-shrink: 0;
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
adia-editor-ui pane-ui[data-left] {
|
|
111
|
-
width: var(--editor-pane-width-left);
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
adia-editor-ui pane-ui[data-right] {
|
|
115
|
-
width: var(--editor-pane-width-right);
|
|
116
|
-
}
|
|
117
|
-
|
|
118
|
-
/* ── Bottom bar ──
|
|
119
|
-
Same slot contract as > header above (icon / heading / description
|
|
120
|
-
/ action). Statusbar is structurally identical to the topbar —
|
|
121
|
-
both are 36px-min chrome bands with left-aligned label content and
|
|
122
|
-
a trailing action cluster. */
|
|
123
|
-
adia-editor-ui > footer {
|
|
124
|
-
display: flex;
|
|
125
|
-
align-items: center;
|
|
126
|
-
gap: var(--editor-bar-gap);
|
|
127
|
-
min-height: var(--editor-bar-height);
|
|
128
|
-
padding: 0 var(--editor-bar-px);
|
|
129
|
-
border-top: var(--editor-border);
|
|
130
|
-
font-size: var(--editor-bar-font);
|
|
131
|
-
color: var(--editor-bar-fg);
|
|
132
|
-
flex-shrink: 0;
|
|
133
|
-
}
|
|
134
|
-
|
|
135
|
-
adia-editor-ui > footer > [slot="heading"] {
|
|
136
|
-
font-weight: var(--editor-title-weight);
|
|
137
|
-
color: var(--editor-bar-fg-strong);
|
|
138
|
-
}
|
|
139
|
-
|
|
140
|
-
adia-editor-ui > footer > [slot="icon"] {
|
|
141
|
-
display: flex;
|
|
142
|
-
align-items: center;
|
|
143
|
-
flex-shrink: 0;
|
|
144
|
-
color: var(--editor-bar-fg);
|
|
145
|
-
}
|
|
146
|
-
|
|
147
|
-
adia-editor-ui > footer > [slot="description"] {
|
|
148
|
-
color: var(--editor-bar-fg);
|
|
149
|
-
font-size: var(--a-ui-sm);
|
|
150
|
-
}
|
|
151
|
-
|
|
152
|
-
adia-editor-ui > footer > [slot="action"] {
|
|
153
|
-
display: flex;
|
|
154
|
-
align-items: center;
|
|
155
|
-
gap: var(--editor-bar-gap);
|
|
156
|
-
flex-shrink: 0;
|
|
157
|
-
margin-inline-start: auto;
|
|
158
|
-
}
|
|
159
|
-
|
|
160
|
-
adia-editor-ui > footer > [slot="action"] ~ [slot="action"] {
|
|
161
|
-
margin-inline-start: 0;
|
|
162
|
-
}
|
|
163
|
-
|
|
164
|
-
/* Dual-cluster: leading group on inline-start, trailing cluster on inline-end. */
|
|
165
|
-
adia-editor-ui > footer > [slot="action-leading"] {
|
|
166
|
-
display: flex;
|
|
167
|
-
align-items: center;
|
|
168
|
-
gap: var(--editor-bar-gap);
|
|
169
|
-
flex-shrink: 0;
|
|
170
|
-
margin-inline-end: auto;
|
|
171
|
-
}
|
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
/* ═══════════════════════════════════════════════════════════════
|
|
2
|
-
adia-editor-ui — Design tokens
|
|
3
|
-
═══════════════════════════════════════════════════════════════ */
|
|
4
|
-
|
|
5
|
-
:where(adia-editor-ui) {
|
|
6
|
-
/* Shell */
|
|
7
|
-
--editor-bg: var(--a-canvas-0);
|
|
8
|
-
--editor-border: 1px solid var(--a-border-subtle);
|
|
9
|
-
|
|
10
|
-
/* Top/bottom bars */
|
|
11
|
-
--editor-bar-height: var(--a-chrome-pane-header-height);
|
|
12
|
-
--editor-bar-px: var(--a-space-3);
|
|
13
|
-
--editor-bar-gap: var(--a-space-2);
|
|
14
|
-
--editor-bar-font: var(--a-ui-size);
|
|
15
|
-
--editor-bar-fg: var(--a-fg-subtle);
|
|
16
|
-
--editor-bar-fg-strong: var(--a-fg);
|
|
17
|
-
|
|
18
|
-
/* Canvas */
|
|
19
|
-
--editor-canvas-bg: var(--a-bg);
|
|
20
|
-
--editor-canvas-fg: var(--a-fg-muted);
|
|
21
|
-
|
|
22
|
-
/* Typography */
|
|
23
|
-
--editor-title-weight: var(--a-weight-medium);
|
|
24
|
-
|
|
25
|
-
/* Panes */
|
|
26
|
-
--editor-pane-width-left: 240px;
|
|
27
|
-
--editor-pane-width-right: 280px;
|
|
28
|
-
}
|
|
@@ -1,89 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
-
"$id": "https://adiaui.dev/a2ui/v0_9/components/AppNav.json",
|
|
4
|
-
"title": "AppNav",
|
|
5
|
-
"description": "Collapsible navigation sidebar. Manages selection state across\napp-nav-item-ui children and opens popover menus for app-nav-group-ui\nchildren when collapsed.\n",
|
|
6
|
-
"type": "object",
|
|
7
|
-
"allOf": [
|
|
8
|
-
{
|
|
9
|
-
"$ref": "common_types.json#/$defs/ComponentCommon"
|
|
10
|
-
},
|
|
11
|
-
{
|
|
12
|
-
"$ref": "common_types.json#/$defs/CatalogComponentCommon"
|
|
13
|
-
}
|
|
14
|
-
],
|
|
15
|
-
"properties": {
|
|
16
|
-
"collapsed": {
|
|
17
|
-
"description": "When true, labels and badges hide; only icons show. Groups use popovers instead of inline expansion.",
|
|
18
|
-
"type": "boolean",
|
|
19
|
-
"default": false
|
|
20
|
-
},
|
|
21
|
-
"component": {
|
|
22
|
-
"const": "AppNav"
|
|
23
|
-
},
|
|
24
|
-
"divider": {
|
|
25
|
-
"description": "Render auto-dividers between groups.",
|
|
26
|
-
"type": "boolean",
|
|
27
|
-
"default": false
|
|
28
|
-
}
|
|
29
|
-
},
|
|
30
|
-
"required": [
|
|
31
|
-
"component"
|
|
32
|
-
],
|
|
33
|
-
"unevaluatedProperties": false,
|
|
34
|
-
"x-adiaui": {
|
|
35
|
-
"anti_patterns": [],
|
|
36
|
-
"category": "nav",
|
|
37
|
-
"events": {
|
|
38
|
-
"nav-select": {
|
|
39
|
-
"description": "Fired when a child app-nav-item-ui is selected (via click or the .select() method).",
|
|
40
|
-
"detail": {
|
|
41
|
-
"item": "HTMLElement",
|
|
42
|
-
"text": "string",
|
|
43
|
-
"value": "string"
|
|
44
|
-
}
|
|
45
|
-
}
|
|
46
|
-
},
|
|
47
|
-
"examples": [],
|
|
48
|
-
"keywords": [
|
|
49
|
-
"app-nav",
|
|
50
|
-
"sidebar",
|
|
51
|
-
"navigation",
|
|
52
|
-
"nav",
|
|
53
|
-
"menu"
|
|
54
|
-
],
|
|
55
|
-
"name": "AdiaAppNav",
|
|
56
|
-
"related": [
|
|
57
|
-
"AppShell",
|
|
58
|
-
"AppNavGroup",
|
|
59
|
-
"AppNavItem"
|
|
60
|
-
],
|
|
61
|
-
"slots": {
|
|
62
|
-
"default": {
|
|
63
|
-
"description": "app-nav-group-ui and app-nav-item-ui children."
|
|
64
|
-
}
|
|
65
|
-
},
|
|
66
|
-
"states": [
|
|
67
|
-
{
|
|
68
|
-
"description": "Default, interactive.",
|
|
69
|
-
"name": "idle"
|
|
70
|
-
},
|
|
71
|
-
{
|
|
72
|
-
"description": "Narrow-width mode; groups open popovers instead of expanding.",
|
|
73
|
-
"attribute": "collapsed",
|
|
74
|
-
"name": "collapsed"
|
|
75
|
-
}
|
|
76
|
-
],
|
|
77
|
-
"synonyms": {
|
|
78
|
-
"sidebar": [
|
|
79
|
-
"app-nav",
|
|
80
|
-
"nav",
|
|
81
|
-
"navigation"
|
|
82
|
-
]
|
|
83
|
-
},
|
|
84
|
-
"tag": "app-nav-ui",
|
|
85
|
-
"tokens": {},
|
|
86
|
-
"traits": [],
|
|
87
|
-
"version": 1
|
|
88
|
-
}
|
|
89
|
-
}
|
|
@@ -1,92 +0,0 @@
|
|
|
1
|
-
/* ═══════════════════════════════════════════
|
|
2
|
-
NAV-UI — root container
|
|
3
|
-
═══════════════════════════════════════════ */
|
|
4
|
-
|
|
5
|
-
@scope (app-nav-ui) {
|
|
6
|
-
:where(:scope) {
|
|
7
|
-
--nav-width: auto;
|
|
8
|
-
--nav-width-collapsed: 48px;
|
|
9
|
-
--nav-bg: transparent;
|
|
10
|
-
--nav-border: var(--a-border-subtle);
|
|
11
|
-
--nav-font-size: var(--a-ui-size);
|
|
12
|
-
--nav-gap: var(--a-space-1);
|
|
13
|
-
--nav-px: var(--a-space-2);
|
|
14
|
-
--nav-py: var(--a-space-2);
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
:scope {
|
|
18
|
-
box-sizing: border-box;
|
|
19
|
-
display: flex;
|
|
20
|
-
flex-direction: column;
|
|
21
|
-
gap: var(--nav-gap);
|
|
22
|
-
width: var(--nav-width);
|
|
23
|
-
padding: var(--nav-py) var(--nav-px);
|
|
24
|
-
background: var(--nav-bg);
|
|
25
|
-
font-size: var(--nav-font-size);
|
|
26
|
-
overflow-y: auto;
|
|
27
|
-
overflow-x: hidden;
|
|
28
|
-
scrollbar-width: none;
|
|
29
|
-
transition: width var(--nav-duration) var(--nav-easing);
|
|
30
|
-
}
|
|
31
|
-
|
|
32
|
-
:scope::-webkit-scrollbar { display: none; }
|
|
33
|
-
|
|
34
|
-
:scope[collapsed] {
|
|
35
|
-
width: var(--nav-width-collapsed);
|
|
36
|
-
--nav-px: var(--a-space-1);
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
@container sidebar (max-width: 96px) {
|
|
40
|
-
:scope {
|
|
41
|
-
--nav-px: var(--a-space-1);
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
/* Group headings */
|
|
46
|
-
[data-nav-label] {
|
|
47
|
-
display: block;
|
|
48
|
-
padding: var(--nav-label-py) var(--nav-label-px);
|
|
49
|
-
font-size: var(--nav-label-font-size);
|
|
50
|
-
font-weight: var(--nav-label-weight);
|
|
51
|
-
color: var(--nav-label-fg);
|
|
52
|
-
text-transform: uppercase;
|
|
53
|
-
letter-spacing: 0.06em;
|
|
54
|
-
white-space: nowrap;
|
|
55
|
-
overflow: hidden;
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
/* Dividers */
|
|
59
|
-
[data-nav-divider] {
|
|
60
|
-
border: none;
|
|
61
|
-
height: 1px;
|
|
62
|
-
background: var(--nav-divider-bg);
|
|
63
|
-
margin: var(--nav-divider-my) 0;
|
|
64
|
-
}
|
|
65
|
-
|
|
66
|
-
/* Auto-dividers between groups when <app-nav-ui divider>. Keeps explicit
|
|
67
|
-
<hr data-nav-divider> working for hand-placed dividers. */
|
|
68
|
-
:scope[divider] > app-nav-group-ui + app-nav-group-ui,
|
|
69
|
-
:scope[divider] > app-nav-item-ui + app-nav-group-ui,
|
|
70
|
-
:scope[divider] > app-nav-group-ui + app-nav-item-ui {
|
|
71
|
-
border-top: 1px solid var(--nav-divider-bg);
|
|
72
|
-
margin-top: var(--nav-divider-my);
|
|
73
|
-
padding-top: var(--nav-divider-my);
|
|
74
|
-
}
|
|
75
|
-
|
|
76
|
-
/* Spacer — pushes items below to bottom */
|
|
77
|
-
[data-nav-spacer] {
|
|
78
|
-
flex: 1;
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
/* Collapsed: hide labels, dividers, spacer keeps working */
|
|
82
|
-
:scope[collapsed] [data-nav-label],
|
|
83
|
-
:scope[collapsed] [data-nav-divider] {
|
|
84
|
-
display: none;
|
|
85
|
-
}
|
|
86
|
-
|
|
87
|
-
@container sidebar (max-width: 96px) {
|
|
88
|
-
[data-nav-label], [data-nav-divider] {
|
|
89
|
-
display: none;
|
|
90
|
-
}
|
|
91
|
-
}
|
|
92
|
-
}
|