@adia-ai/web-modules 0.3.3 → 0.3.4

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.
Files changed (54) hide show
  1. package/CHANGELOG.md +36 -0
  2. package/chat/chat-shell/chat-shell.examples.html +85 -0
  3. package/chat/chat-shell/chat-shell.html +42 -0
  4. package/editor/editor-shell/editor-shell.examples.html +71 -0
  5. package/editor/editor-shell/editor-shell.html +42 -0
  6. package/package.json +1 -1
  7. package/shell/admin-command/admin-command.a2ui.json +102 -0
  8. package/shell/admin-command/admin-command.examples.html +83 -0
  9. package/shell/admin-command/admin-command.html +42 -0
  10. package/shell/admin-command/admin-command.js +161 -0
  11. package/shell/admin-command/admin-command.test.js +115 -0
  12. package/shell/admin-command/admin-command.yaml +102 -0
  13. package/shell/admin-content/admin-content.a2ui.json +73 -0
  14. package/shell/admin-content/admin-content.examples.html +33 -0
  15. package/shell/admin-content/admin-content.html +42 -0
  16. package/shell/admin-content/admin-content.yaml +63 -0
  17. package/shell/admin-page/admin-page.a2ui.json +74 -0
  18. package/shell/admin-page/admin-page.examples.html +37 -0
  19. package/shell/admin-page/admin-page.html +42 -0
  20. package/shell/admin-page/admin-page.yaml +61 -0
  21. package/shell/admin-page-body/admin-page-body.a2ui.json +62 -0
  22. package/shell/admin-page-body/admin-page-body.examples.html +34 -0
  23. package/shell/admin-page-body/admin-page-body.html +42 -0
  24. package/shell/admin-page-body/admin-page-body.yaml +49 -0
  25. package/shell/admin-page-header/admin-page-header.a2ui.json +62 -0
  26. package/shell/admin-page-header/admin-page-header.examples.html +34 -0
  27. package/shell/admin-page-header/admin-page-header.html +42 -0
  28. package/shell/admin-page-header/admin-page-header.yaml +47 -0
  29. package/shell/admin-scroll/admin-scroll.a2ui.json +62 -0
  30. package/shell/admin-scroll/admin-scroll.examples.html +31 -0
  31. package/shell/admin-scroll/admin-scroll.html +42 -0
  32. package/shell/admin-scroll/admin-scroll.yaml +51 -0
  33. package/shell/admin-shell/admin-shell.a2ui.json +0 -10
  34. package/shell/admin-shell/admin-shell.css +1 -0
  35. package/shell/admin-shell/admin-shell.examples.html +61 -5
  36. package/shell/admin-shell/admin-shell.js +165 -121
  37. package/shell/admin-shell/admin-shell.yaml +6 -6
  38. package/shell/admin-shell/css/admin-shell.bespoke.css +198 -0
  39. package/shell/admin-shell/css/admin-shell.tokens.css +10 -0
  40. package/shell/admin-sidebar/admin-sidebar.a2ui.json +138 -0
  41. package/shell/admin-sidebar/admin-sidebar.examples.html +76 -0
  42. package/shell/admin-sidebar/admin-sidebar.html +47 -0
  43. package/shell/admin-sidebar/admin-sidebar.js +227 -0
  44. package/shell/admin-sidebar/admin-sidebar.test.js +123 -0
  45. package/shell/admin-sidebar/admin-sidebar.yaml +140 -0
  46. package/shell/admin-statusbar/admin-statusbar.a2ui.json +81 -0
  47. package/shell/admin-statusbar/admin-statusbar.examples.html +29 -0
  48. package/shell/admin-statusbar/admin-statusbar.html +42 -0
  49. package/shell/admin-statusbar/admin-statusbar.yaml +68 -0
  50. package/shell/admin-topbar/admin-topbar.a2ui.json +83 -0
  51. package/shell/admin-topbar/admin-topbar.examples.html +31 -0
  52. package/shell/admin-topbar/admin-topbar.html +42 -0
  53. package/shell/admin-topbar/admin-topbar.yaml +75 -0
  54. package/shell/index.js +2 -0
@@ -0,0 +1,68 @@
1
+ # Edit this file; run `npm run build:components` to regenerate a2ui.json.
2
+ $schema: ../../../../scripts/schemas/component.yaml.schema.json
3
+ name: AdminStatusbar
4
+ tag: admin-statusbar
5
+ component: AdminStatusbar
6
+ category: layout
7
+ version: 1
8
+ description: |
9
+ Module-tier shell bottom chrome bar. CSS-only — no behavior, no JS.
10
+ Same shape as <admin-topbar> (icon + heading + description + action
11
+ clusters via slot vocabulary), conventionally used for read-only
12
+ status — connection state, sync indicator, footer metadata.
13
+
14
+ Replaces legacy <footer-ui> usage at shell-tier. Both still work per
15
+ ADR-0023 backwards-compat.
16
+
17
+ props: {}
18
+
19
+ events: {}
20
+
21
+ slots:
22
+ default:
23
+ description: >-
24
+ Default content — status text or inline children.
25
+ icon:
26
+ description: >-
27
+ Leading glyph (icon-ui or img).
28
+ heading:
29
+ description: >-
30
+ Primary label.
31
+ description:
32
+ description: >-
33
+ Secondary metadata.
34
+ action:
35
+ description: >-
36
+ Trailing control cluster.
37
+ action-leading:
38
+ description: >-
39
+ Leading control cluster.
40
+
41
+ states:
42
+ - name: idle
43
+ description: Default, the only state.
44
+
45
+ traits: []
46
+
47
+ a2ui:
48
+ rules:
49
+ - >-
50
+ admin-statusbar replaces <footer-ui> at shell-tier. Same slot
51
+ vocabulary as <admin-topbar>; visual treatment differs (the
52
+ shell css applies a top-border instead of bottom).
53
+
54
+ keywords:
55
+ - admin-statusbar
56
+ - statusbar
57
+ - footer-bar
58
+ - app-footer
59
+ - status-line
60
+
61
+ synonyms:
62
+ statusbar: [status-line, footer-bar, app-footer]
63
+
64
+ related:
65
+ - AdminShell
66
+ - AdminContent
67
+ - AdminTopbar
68
+ - Footer
@@ -0,0 +1,83 @@
1
+ {
2
+ "$schema": "https://json-schema.org/draft/2020-12/schema",
3
+ "$id": "https://adiaui.dev/a2ui/v0_9/components/AdminTopbar.json",
4
+ "title": "AdminTopbar",
5
+ "description": "Module-tier shell top chrome bar. CSS-only — no behavior, no JS.\nSits at the top of <admin-content>, <admin-sidebar>, or any chrome\nregion. Provides the canonical icon + heading + description +\naction-clusters layout via slot vocabulary.\n\nReplaces the legacy <header-ui> usage at shell-tier. Both still work\nper ADR-0023 backwards-compat; new code should prefer <admin-topbar>\nfor shell-tier chrome bars (use <header-ui> for primitive containers\nlike Card / Drawer / Modal).\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": "AdminTopbar"
18
+ }
19
+ },
20
+ "required": [
21
+ "component"
22
+ ],
23
+ "unevaluatedProperties": false,
24
+ "x-adiaui": {
25
+ "anti_patterns": [],
26
+ "category": "layout",
27
+ "events": {},
28
+ "examples": [],
29
+ "keywords": [
30
+ "admin-topbar",
31
+ "topbar",
32
+ "chrome-bar",
33
+ "app-header",
34
+ "shell-header"
35
+ ],
36
+ "name": "AdminTopbar",
37
+ "related": [
38
+ "AdminShell",
39
+ "AdminContent",
40
+ "AdminSidebar",
41
+ "AdminStatusbar",
42
+ "Header"
43
+ ],
44
+ "slots": {
45
+ "description": {
46
+ "description": "Secondary metadata. Muted + smaller font."
47
+ },
48
+ "default": {
49
+ "description": "Default content — typically a breadcrumb, page title, or ad-hoc inline children. Use named slots for canonical clusters."
50
+ },
51
+ "action": {
52
+ "description": "Trailing control cluster (buttons, menus, etc.). The first [slot=\"action\"] child pushes itself + siblings to the end; subsequent siblings flow with gap."
53
+ },
54
+ "action-leading": {
55
+ "description": "Leading control cluster (back button, menu trigger, etc.). Pairs with [slot=\"action\"] for dual-cluster chrome."
56
+ },
57
+ "heading": {
58
+ "description": "Primary label. Medium-weight + strong fg."
59
+ },
60
+ "icon": {
61
+ "description": "Leading glyph (icon-ui or img). Muted color, flex-aligned."
62
+ }
63
+ },
64
+ "states": [
65
+ {
66
+ "description": "Default, the only state.",
67
+ "name": "idle"
68
+ }
69
+ ],
70
+ "synonyms": {
71
+ "topbar": [
72
+ "appbar",
73
+ "app-header",
74
+ "header-bar",
75
+ "navbar"
76
+ ]
77
+ },
78
+ "tag": "admin-topbar",
79
+ "tokens": {},
80
+ "traits": [],
81
+ "version": 1
82
+ }
83
+ }
@@ -0,0 +1,31 @@
1
+ <header>
2
+ <div>
3
+ <h1>Admin Topbar</h1>
4
+ <div data-actions>
5
+ <tag-ui size="sm">admin-topbar</tag-ui>
6
+ <tag-ui size="sm" variant="ghost">CSS-only</tag-ui>
7
+ </div>
8
+ </div>
9
+ <p>Module-tier shell top chrome bar. Provides icon + heading + description + action-clusters layout via slot vocabulary.</p>
10
+ </header>
11
+
12
+ <section data-section>
13
+ <h2 variant="section">Role</h2>
14
+ <p>This is a CSS-only structural stub — no JavaScript, no behavior. The shell host (<code>&lt;admin-shell&gt;</code>) styles it via tag-presence. Authors compose it with sibling bespoke children to express semantic shell-tier structure.</p>
15
+ </section>
16
+
17
+ <section data-section>
18
+ <h2 variant="section">Composition</h2>
19
+ <p>Typical placement inside <code>&lt;admin-shell&gt;</code>:</p>
20
+ <code-ui language="html">&lt;admin-topbar&gt;
21
+ &lt;icon-ui slot="icon" name="house"&gt;&lt;/icon-ui&gt;
22
+ &lt;span slot="heading"&gt;Dashboard&lt;/span&gt;
23
+ &lt;span slot="description"&gt;Workspace overview&lt;/span&gt;
24
+ &lt;button-ui slot="action" variant="ghost"&gt;Settings&lt;/button-ui&gt;
25
+ &lt;/admin-topbar&gt;</code-ui>
26
+ </section>
27
+
28
+ <section data-section>
29
+ <h2 variant="section">Slot vocabulary</h2>
30
+ <p>See the <a href="../admin-shell/admin-shell.html"><code>admin-shell</code></a> demo for the full composition pattern. CSS-only stubs declare slot intent; the parent shell handles layout.</p>
31
+ </section>
@@ -0,0 +1,42 @@
1
+ <!DOCTYPE html>
2
+ <html lang="en" data-theme="auto">
3
+ <head>
4
+ <meta charset="utf-8">
5
+ <meta name="viewport" content="width=device-width, initial-scale=1">
6
+ <title>Admin Topbar — AdiaUI</title>
7
+
8
+ <link rel="stylesheet" href="../../../web-components/styles/resets.css">
9
+ <link rel="stylesheet" href="../../../web-components/styles/tokens.css">
10
+ <link rel="stylesheet" href="../admin-shell/admin-shell.css">
11
+ <link rel="stylesheet" href="../../../web-components/components/code/code.css">
12
+ <link rel="stylesheet" href="../../../web-components/components/tag/tag.css">
13
+
14
+ <script type="module" src="../admin-shell/admin-shell.js"></script>
15
+ <script type="module" src="../../../web-components/components/code/code.js"></script>
16
+ <script type="module" src="../../../web-components/components/tag/tag.js"></script>
17
+
18
+ <style>
19
+ :where(html, body) { margin: 0; min-height: 100vh; background: var(--a-bg); color: var(--a-fg); font-family: var(--a-font); }
20
+ main { max-width: 960px; margin-inline: auto; padding: var(--a-space-6) var(--a-space-5); }
21
+ </style>
22
+ </head>
23
+ <body>
24
+
25
+ <main id="demo-root">
26
+ <p>Loading examples…</p>
27
+ </main>
28
+
29
+ <script type="module">
30
+ const root = document.getElementById('demo-root');
31
+ try {
32
+ const res = await fetch('./admin-topbar.examples.html');
33
+ if (!res.ok) throw new Error(`fetch failed (${res.status})`);
34
+ root.innerHTML = await res.text();
35
+ } catch (err) {
36
+ root.innerHTML = `<p style="color:var(--a-danger-strong);">Failed to load admin-topbar.examples.html — ${err.message}</p>`;
37
+ console.error('[admin-topbar.html]', err);
38
+ }
39
+ </script>
40
+
41
+ </body>
42
+ </html>
@@ -0,0 +1,75 @@
1
+ # Edit this file; run `npm run build:components` to regenerate a2ui.json.
2
+ $schema: ../../../../scripts/schemas/component.yaml.schema.json
3
+ name: AdminTopbar
4
+ tag: admin-topbar
5
+ component: AdminTopbar
6
+ category: layout
7
+ version: 1
8
+ description: |
9
+ Module-tier shell top chrome bar. CSS-only — no behavior, no JS.
10
+ Sits at the top of <admin-content>, <admin-sidebar>, or any chrome
11
+ region. Provides the canonical icon + heading + description +
12
+ action-clusters layout via slot vocabulary.
13
+
14
+ Replaces the legacy <header-ui> usage at shell-tier. Both still work
15
+ per ADR-0023 backwards-compat; new code should prefer <admin-topbar>
16
+ for shell-tier chrome bars (use <header-ui> for primitive containers
17
+ like Card / Drawer / Modal).
18
+
19
+ props: {}
20
+
21
+ events: {}
22
+
23
+ slots:
24
+ default:
25
+ description: >-
26
+ Default content — typically a breadcrumb, page title, or
27
+ ad-hoc inline children. Use named slots for canonical clusters.
28
+ icon:
29
+ description: >-
30
+ Leading glyph (icon-ui or img). Muted color, flex-aligned.
31
+ heading:
32
+ description: >-
33
+ Primary label. Medium-weight + strong fg.
34
+ description:
35
+ description: >-
36
+ Secondary metadata. Muted + smaller font.
37
+ action:
38
+ description: >-
39
+ Trailing control cluster (buttons, menus, etc.). The first
40
+ [slot="action"] child pushes itself + siblings to the end;
41
+ subsequent siblings flow with gap.
42
+ action-leading:
43
+ description: >-
44
+ Leading control cluster (back button, menu trigger, etc.).
45
+ Pairs with [slot="action"] for dual-cluster chrome.
46
+
47
+ states:
48
+ - name: idle
49
+ description: Default, the only state.
50
+
51
+ traits: []
52
+
53
+ a2ui:
54
+ rules:
55
+ - >-
56
+ admin-topbar replaces <header-ui> at shell-tier — use it for
57
+ chrome bars inside admin-shell, admin-content, admin-sidebar.
58
+ Use <header-ui> for primitive containers (Card / Drawer / Modal).
59
+
60
+ keywords:
61
+ - admin-topbar
62
+ - topbar
63
+ - chrome-bar
64
+ - app-header
65
+ - shell-header
66
+
67
+ synonyms:
68
+ topbar: [appbar, app-header, header-bar, navbar]
69
+
70
+ related:
71
+ - AdminShell
72
+ - AdminContent
73
+ - AdminSidebar
74
+ - AdminStatusbar
75
+ - Header
package/shell/index.js CHANGED
@@ -1 +1,3 @@
1
1
  export { AdminShell } from './admin-shell/admin-shell.js';
2
+ export { AdminSidebar } from './admin-sidebar/admin-sidebar.js';
3
+ export { AdminCommand } from './admin-command/admin-command.js';