@adia-ai/web-components 0.5.7 → 0.5.9
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/USAGE.md +218 -0
- package/components/accordion/accordion.d.ts +22 -1
- package/components/action-list/action-list.d.ts +14 -1
- package/components/agent-artifact/agent-artifact.d.ts +1 -1
- package/components/agent-feedback-bar/agent-feedback-bar.d.ts +1 -1
- package/components/agent-questions/agent-questions.d.ts +1 -1
- package/components/agent-reasoning/agent-reasoning.d.ts +1 -1
- package/components/agent-suggestions/agent-suggestions.d.ts +1 -1
- package/components/agent-trace/agent-trace.d.ts +1 -1
- package/components/alert/alert.d.ts +1 -1
- package/components/avatar/avatar.d.ts +8 -1
- package/components/badge/badge.d.ts +1 -1
- package/components/block/block.d.ts +1 -1
- package/components/breadcrumb/breadcrumb.d.ts +1 -1
- package/components/button/button.d.ts +1 -1
- package/components/canvas/canvas.d.ts +1 -1
- package/components/card/card.d.ts +1 -1
- package/components/chart/chart.d.ts +1 -1
- package/components/chart-legend/chart-legend.d.ts +1 -1
- package/components/chat-thread/chat-thread.d.ts +40 -1
- package/components/code/code.css +1 -1
- package/components/col/col.a2ui.json +4 -4
- package/components/col/col.d.ts +2 -2
- package/components/col/col.yaml +2 -2
- package/components/command/command.d.ts +1 -1
- package/components/demo-toggle/demo-toggle.a2ui.json +3 -1
- package/components/demo-toggle/demo-toggle.d.ts +1 -1
- package/components/demo-toggle/demo-toggle.yaml +2 -0
- package/components/description-list/description-list.d.ts +1 -1
- package/components/divider/divider.d.ts +1 -1
- package/components/drawer/drawer.d.ts +1 -1
- package/components/embed/embed.d.ts +1 -1
- package/components/empty-state/class.js +10 -4
- package/components/empty-state/empty-state.a2ui.json +5 -0
- package/components/empty-state/empty-state.css +36 -0
- package/components/empty-state/empty-state.d.ts +6 -1
- package/components/empty-state/empty-state.test.js +77 -0
- package/components/empty-state/empty-state.yaml +9 -0
- package/components/feed/feed.css +2 -2
- package/components/feed/feed.d.ts +29 -5
- package/components/field/field.d.ts +1 -1
- package/components/fields/fields.a2ui.json +3 -1
- package/components/fields/fields.d.ts +1 -1
- package/components/fields/fields.yaml +2 -0
- package/components/grid/grid.d.ts +1 -1
- package/components/heatmap/heatmap.d.ts +1 -1
- package/components/icon/icon.d.ts +1 -1
- package/components/image/image.d.ts +1 -1
- package/components/input/class.js +2 -1
- package/components/input/input.a2ui.json +5 -0
- package/components/input/input.test.js +99 -0
- package/components/input/input.yaml +14 -0
- package/components/inspector/inspector.d.ts +1 -1
- package/components/kbd/kbd.d.ts +1 -1
- package/components/link/link.d.ts +1 -1
- package/components/list/list.d.ts +10 -1
- package/components/menu/menu-divider.a2ui.json +41 -0
- package/components/menu/menu-divider.yaml +15 -0
- package/components/menu/menu-item.a2ui.json +77 -0
- package/components/menu/menu-item.yaml +45 -0
- package/components/menu/menu.d.ts +17 -1
- package/components/modal/modal.d.ts +1 -1
- package/components/nav/nav.a2ui.json +6 -1
- package/components/nav/nav.css +1 -1
- package/components/nav/nav.d.ts +1 -1
- package/components/nav/nav.yaml +6 -0
- package/components/nav-group/nav-group.a2ui.json +5 -1
- package/components/nav-group/nav-group.css +1 -1
- package/components/nav-group/nav-group.d.ts +1 -1
- package/components/nav-group/nav-group.yaml +5 -0
- package/components/nav-item/nav-item.a2ui.json +4 -1
- package/components/nav-item/nav-item.css +1 -1
- package/components/nav-item/nav-item.d.ts +1 -1
- package/components/nav-item/nav-item.yaml +4 -0
- package/components/noodles/noodles.d.ts +1 -1
- package/components/page/page.d.ts +1 -1
- package/components/pagination/pagination.d.ts +1 -1
- package/components/pane/pane.d.ts +1 -1
- package/components/pipeline-status/pipeline-status.d.ts +1 -1
- package/components/popover/popover.d.ts +1 -1
- package/components/progress/progress.d.ts +1 -1
- package/components/progress-row/progress-row.d.ts +1 -1
- package/components/range/range.css +1 -1
- package/components/richtext/richtext.a2ui.json +4 -4
- package/components/richtext/richtext.d.ts +2 -2
- package/components/richtext/richtext.yaml +2 -2
- package/components/row/row.d.ts +1 -1
- package/components/segment/segment.d.ts +1 -1
- package/components/select/class.js +28 -0
- package/components/select/select.css +1 -1
- package/components/select/select.yaml +28 -0
- package/components/skeleton/skeleton.d.ts +1 -1
- package/components/slider/class.js +20 -50
- package/components/slider/slider.css +1 -1
- package/components/stack/stack.d.ts +1 -1
- package/components/step-progress/step-progress.d.ts +1 -1
- package/components/stepper/stepper-item.a2ui.json +74 -0
- package/components/stepper/stepper-item.yaml +45 -0
- package/components/stepper/stepper.d.ts +13 -1
- package/components/stream/stream.d.ts +1 -1
- package/components/swatch/swatch.css +1 -1
- package/components/swatch/swatch.d.ts +1 -1
- package/components/swiper/swiper.d.ts +1 -1
- package/components/switch/switch.css +1 -1
- package/components/table/table.d.ts +1 -1
- package/components/table-toolbar/table-toolbar.d.ts +1 -1
- package/components/tabs/tabs.d.ts +12 -1
- package/components/tag/tag.d.ts +1 -1
- package/components/text/text.d.ts +1 -1
- package/components/textarea/class.js +7 -1
- package/components/textarea/textarea.a2ui.json +5 -0
- package/components/textarea/textarea.yaml +14 -0
- package/components/timeline/timeline.d.ts +20 -1
- package/components/toast/class.js +9 -0
- package/components/toast/toast.d.ts +9 -5
- package/components/toast/toast.yaml +16 -0
- package/components/toggle-group/toggle-group.d.ts +12 -1
- package/components/toggle-group/toggle-option.a2ui.json +61 -0
- package/components/toggle-group/toggle-option.yaml +33 -0
- package/components/toggle-scheme/toggle-scheme.d.ts +1 -1
- package/components/toolbar/toolbar-group.a2ui.json +41 -0
- package/components/toolbar/toolbar-group.yaml +16 -0
- package/components/toolbar/toolbar.d.ts +4 -1
- package/components/tooltip/tooltip.css +2 -2
- package/components/tooltip/tooltip.d.ts +1 -1
- package/components/tree/tree.css +1 -1
- package/components/tree/tree.d.ts +18 -1
- package/core/form.js +93 -0
- package/core/signals.d.ts +28 -0
- package/index.d.ts +2 -2
- package/package.json +1 -1
- package/styles/colors/semantics.css +6 -0
- package/styles/tokens.css +3 -0
- package/styles/typography.css +5 -1
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
{
|
|
2
|
+
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
+
"$id": "https://adiaui.dev/a2ui/v0_9/components/MenuItem.json",
|
|
4
|
+
"title": "MenuItem",
|
|
5
|
+
"description": "Child of `<menu-ui>`. One actionable row inside a menu, with optional leading icon + label + value.",
|
|
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": "MenuItem"
|
|
18
|
+
},
|
|
19
|
+
"disabled": {
|
|
20
|
+
"description": "Disabled state — blocks pointer + keyboard activation.",
|
|
21
|
+
"type": "boolean",
|
|
22
|
+
"default": false
|
|
23
|
+
},
|
|
24
|
+
"icon": {
|
|
25
|
+
"description": "Optional leading Phosphor icon name.",
|
|
26
|
+
"type": "string",
|
|
27
|
+
"default": ""
|
|
28
|
+
},
|
|
29
|
+
"text": {
|
|
30
|
+
"description": "Item label text.",
|
|
31
|
+
"type": "string",
|
|
32
|
+
"default": ""
|
|
33
|
+
},
|
|
34
|
+
"value": {
|
|
35
|
+
"description": "Stable identifier emitted via the parent menu's `select` event.",
|
|
36
|
+
"type": "string",
|
|
37
|
+
"default": ""
|
|
38
|
+
},
|
|
39
|
+
"variant": {
|
|
40
|
+
"description": "Semantic variant.",
|
|
41
|
+
"type": "string",
|
|
42
|
+
"enum": [
|
|
43
|
+
"default",
|
|
44
|
+
"danger"
|
|
45
|
+
],
|
|
46
|
+
"default": "default"
|
|
47
|
+
}
|
|
48
|
+
},
|
|
49
|
+
"required": [
|
|
50
|
+
"component"
|
|
51
|
+
],
|
|
52
|
+
"unevaluatedProperties": false,
|
|
53
|
+
"x-adiaui": {
|
|
54
|
+
"anti_patterns": [],
|
|
55
|
+
"category": "navigation",
|
|
56
|
+
"composes": [],
|
|
57
|
+
"events": {},
|
|
58
|
+
"examples": [],
|
|
59
|
+
"keywords": [],
|
|
60
|
+
"name": "UIMenuItem",
|
|
61
|
+
"related": [],
|
|
62
|
+
"slots": {
|
|
63
|
+
"icon": {
|
|
64
|
+
"description": "Custom leading element override; falls through to `[icon]` prop if not slotted."
|
|
65
|
+
},
|
|
66
|
+
"text": {
|
|
67
|
+
"description": "Custom label content; falls through to `[text]` prop if not slotted."
|
|
68
|
+
}
|
|
69
|
+
},
|
|
70
|
+
"states": [],
|
|
71
|
+
"synonyms": {},
|
|
72
|
+
"tag": "menu-item-ui",
|
|
73
|
+
"tokens": {},
|
|
74
|
+
"traits": [],
|
|
75
|
+
"version": 1
|
|
76
|
+
}
|
|
77
|
+
}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
# Edit this file; run `npm run build:components` to regenerate a2ui.json.
|
|
2
|
+
#
|
|
3
|
+
# §228 (v0.5.9): authored to close the §229 baseline class-export-undeclared
|
|
4
|
+
# drift for UIMenuItem. The item ships as a sibling class in menu/class.js
|
|
5
|
+
# + is registered alongside UIMenu + UIMenuDivider.
|
|
6
|
+
|
|
7
|
+
# Child component of <menu-ui>. Surface only inside that parent.
|
|
8
|
+
$schema: ../../../../scripts/schemas/component.yaml.schema.json
|
|
9
|
+
name: UIMenuItem
|
|
10
|
+
tag: menu-item-ui
|
|
11
|
+
component: MenuItem
|
|
12
|
+
category: navigation
|
|
13
|
+
version: 1
|
|
14
|
+
description: |-
|
|
15
|
+
Child of `<menu-ui>`. One actionable row inside a menu, with optional leading icon + label + value.
|
|
16
|
+
|
|
17
|
+
props:
|
|
18
|
+
icon:
|
|
19
|
+
description: Optional leading Phosphor icon name.
|
|
20
|
+
type: string
|
|
21
|
+
default: ""
|
|
22
|
+
text:
|
|
23
|
+
description: Item label text.
|
|
24
|
+
type: string
|
|
25
|
+
default: ""
|
|
26
|
+
value:
|
|
27
|
+
description: Stable identifier emitted via the parent menu's `select` event.
|
|
28
|
+
type: string
|
|
29
|
+
default: ""
|
|
30
|
+
variant:
|
|
31
|
+
description: Semantic variant.
|
|
32
|
+
type: string
|
|
33
|
+
default: default
|
|
34
|
+
enum:
|
|
35
|
+
- default
|
|
36
|
+
- danger
|
|
37
|
+
disabled:
|
|
38
|
+
description: Disabled state — blocks pointer + keyboard activation.
|
|
39
|
+
type: boolean
|
|
40
|
+
default: false
|
|
41
|
+
slots:
|
|
42
|
+
icon:
|
|
43
|
+
description: Custom leading element override; falls through to `[icon]` prop if not slotted.
|
|
44
|
+
text:
|
|
45
|
+
description: Custom label content; falls through to `[text]` prop if not slotted.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/menu
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -36,3 +36,19 @@ export class UIMenu extends UIElement {
|
|
|
36
36
|
): void;
|
|
37
37
|
addEventListener(type: 'action', listener: (ev: MenuActionEvent) => unknown, options?: boolean | AddEventListenerOptions): void;
|
|
38
38
|
}
|
|
39
|
+
|
|
40
|
+
export class UIMenuDivider extends UIElement {
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
export class UIMenuItem extends UIElement {
|
|
44
|
+
/** Disabled state — blocks pointer + keyboard activation. */
|
|
45
|
+
disabled: boolean;
|
|
46
|
+
/** Optional leading Phosphor icon name. */
|
|
47
|
+
icon: string;
|
|
48
|
+
/** Item label text. */
|
|
49
|
+
text: string;
|
|
50
|
+
/** Stable identifier emitted via the parent menu's `select` event. */
|
|
51
|
+
value: string;
|
|
52
|
+
/** Semantic variant. */
|
|
53
|
+
variant: 'default' | 'danger';
|
|
54
|
+
}
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/modal
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -48,7 +48,12 @@
|
|
|
48
48
|
"x-adiaui": {
|
|
49
49
|
"anti_patterns": [],
|
|
50
50
|
"category": "layout",
|
|
51
|
-
"composes": [
|
|
51
|
+
"composes": [
|
|
52
|
+
"nav-group-ui",
|
|
53
|
+
"nav-item-ui",
|
|
54
|
+
"icon-ui",
|
|
55
|
+
"popover-ui"
|
|
56
|
+
],
|
|
52
57
|
"events": {
|
|
53
58
|
"nav-select": {
|
|
54
59
|
"description": "Bubbles from <nav-item-ui> children when one is selected. Detail: { item, text, value }.",
|
package/components/nav/nav.css
CHANGED
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
/* Primary-variant collapse */
|
|
18
18
|
--nav-width: auto;
|
|
19
19
|
--nav-width-collapsed: 48px;
|
|
20
|
-
--nav-duration: var(--a-duration-base
|
|
20
|
+
--nav-duration: var(--a-duration); /* §230-bundle (v0.5.9): canonical mid-tier duration (250ms). Was orphaned --a-duration-base. */
|
|
21
21
|
--nav-easing: var(--a-easing, ease);
|
|
22
22
|
|
|
23
23
|
/* Group-heading kicker */
|
package/components/nav/nav.d.ts
CHANGED
|
@@ -12,7 +12,7 @@ and a [heading] kicker rendered via CSS.
|
|
|
12
12
|
* @see https://ui-kit.exe.xyz/site/components/nav
|
|
13
13
|
*
|
|
14
14
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
15
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
15
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
16
16
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
17
17
|
* regenerate; or hand-author this file fully if rich event types are
|
|
18
18
|
* needed beyond what the yaml `events:` block can express.
|
package/components/nav/nav.yaml
CHANGED
|
@@ -58,7 +58,11 @@
|
|
|
58
58
|
"x-adiaui": {
|
|
59
59
|
"anti_patterns": [],
|
|
60
60
|
"category": "layout",
|
|
61
|
-
"composes": [
|
|
61
|
+
"composes": [
|
|
62
|
+
"icon-ui",
|
|
63
|
+
"badge-ui",
|
|
64
|
+
"nav-item-ui"
|
|
65
|
+
],
|
|
62
66
|
"events": {
|
|
63
67
|
"group-toggle": {
|
|
64
68
|
"description": "Fired when the header toggles via click/keyboard. Detail: { text, open }.",
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
--nav-group-font-size: var(--a-ui-size);
|
|
10
10
|
--nav-group-font-size-sm: var(--a-ui-sm);
|
|
11
11
|
--nav-group-font-size-lg: var(--a-ui-lg);
|
|
12
|
-
--nav-group-font-weight: var(--a-
|
|
12
|
+
--nav-group-font-weight: var(--a-weight-normal);
|
|
13
13
|
--nav-group-fg: var(--a-fg);
|
|
14
14
|
--nav-group-fg-hover: var(--a-fg-strong);
|
|
15
15
|
--nav-group-fg-muted: var(--a-fg-muted);
|
|
@@ -12,7 +12,7 @@ when [collapsible] (default true).
|
|
|
12
12
|
* @see https://ui-kit.exe.xyz/site/components/nav-group
|
|
13
13
|
*
|
|
14
14
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
15
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
15
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
16
16
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
17
17
|
* regenerate; or hand-author this file fully if rich event types are
|
|
18
18
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -63,7 +63,10 @@
|
|
|
63
63
|
"x-adiaui": {
|
|
64
64
|
"anti_patterns": [],
|
|
65
65
|
"category": "layout",
|
|
66
|
-
"composes": [
|
|
66
|
+
"composes": [
|
|
67
|
+
"icon-ui",
|
|
68
|
+
"badge-ui"
|
|
69
|
+
],
|
|
67
70
|
"events": {
|
|
68
71
|
"nav-select": {
|
|
69
72
|
"description": "Bubbles when the item is activated. Detail: { item, text, value }.",
|
|
@@ -39,7 +39,7 @@ nav-item-ui[selected] [slot="icon"]:empty::before {
|
|
|
39
39
|
--nav-item-font-size: var(--a-ui-size);
|
|
40
40
|
--nav-item-font-size-sm: var(--a-ui-sm);
|
|
41
41
|
--nav-item-font-size-lg: var(--a-ui-lg);
|
|
42
|
-
--nav-item-font-weight: var(--a-
|
|
42
|
+
--nav-item-font-weight: var(--a-weight-normal);
|
|
43
43
|
--nav-item-fg: var(--a-ui-text-subtle);
|
|
44
44
|
--nav-item-fg-hover: var(--a-ui-text-hover);
|
|
45
45
|
--nav-item-fg-selected: var(--a-ui-text-selected);
|
|
@@ -12,7 +12,7 @@ bubbles a `nav-select` event.
|
|
|
12
12
|
* @see https://ui-kit.exe.xyz/site/components/nav-item
|
|
13
13
|
*
|
|
14
14
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
15
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
15
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
16
16
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
17
17
|
* regenerate; or hand-author this file fully if rich event types are
|
|
18
18
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/noodles
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -10,7 +10,7 @@ primitives (`<header-ui>`, `<section-ui>`, `<footer-ui>`); the page's
|
|
|
10
10
|
* @see https://ui-kit.exe.xyz/site/components/page
|
|
11
11
|
*
|
|
12
12
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
13
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
13
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
14
14
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
15
15
|
* regenerate; or hand-author this file fully if rich event types are
|
|
16
16
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/pagination
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/pane
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/pipeline-status
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/popover
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/progress
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/progress-row
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -13,7 +13,7 @@ range-ui:not([disabled]) [slot="field"]:hover [data-layer="fill"] {
|
|
|
13
13
|
--range-fill-bg-hover: var(--a-ui-bg-hover);
|
|
14
14
|
--range-fill-bg-active: var(--a-ui-bg-active);
|
|
15
15
|
--range-fill-bg-disabled: var(--a-canvas-muted);
|
|
16
|
-
--range-fill-fg: var(--a-
|
|
16
|
+
--range-fill-fg: var(--a-fg);
|
|
17
17
|
--range-fill-fg-disabled: var(--a-ui-text-disabled);
|
|
18
18
|
--range-fill-label-fg: var(--a-ui-text-subtle);
|
|
19
19
|
--range-border: var(--a-ui-border);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
|
3
|
-
"$id": "https://adiaui.dev/a2ui/v0_9/components/
|
|
4
|
-
"title": "
|
|
3
|
+
"$id": "https://adiaui.dev/a2ui/v0_9/components/RichText.json",
|
|
4
|
+
"title": "RichText",
|
|
5
5
|
"description": "Renders markdown to styled HTML.",
|
|
6
6
|
"type": "object",
|
|
7
7
|
"allOf": [
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
],
|
|
15
15
|
"properties": {
|
|
16
16
|
"component": {
|
|
17
|
-
"const": "
|
|
17
|
+
"const": "RichText"
|
|
18
18
|
},
|
|
19
19
|
"markdown": {
|
|
20
20
|
"description": "Component property: markdown.",
|
|
@@ -61,7 +61,7 @@
|
|
|
61
61
|
"keywords": [
|
|
62
62
|
"richtext"
|
|
63
63
|
],
|
|
64
|
-
"name": "
|
|
64
|
+
"name": "UIRichText",
|
|
65
65
|
"related": [],
|
|
66
66
|
"slots": {
|
|
67
67
|
"default": {
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/richtext
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
|
|
13
13
|
import { UIElement } from '../../core/element.js';
|
|
14
14
|
|
|
15
|
-
export class
|
|
15
|
+
export class UIRichText extends UIElement {
|
|
16
16
|
/** Component property: markdown. */
|
|
17
17
|
markdown: string;
|
|
18
18
|
/** Source URL (image, iframe, etc.). */
|
package/components/row/row.d.ts
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/row
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/segment
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|
|
@@ -26,6 +26,14 @@ export class UISelect extends UIFormElement {
|
|
|
26
26
|
// (slot 11). Per FEEDBACK-06 §4 + FEEDBACK-07 §4.
|
|
27
27
|
static requiredIcons = ['caret-up-down'];
|
|
28
28
|
|
|
29
|
+
// §225 (v0.5.9, FEEDBACK-10 §3): once-per-element console.warn dedup when
|
|
30
|
+
// consumer authors children that aren't native <option>/<optgroup>. The
|
|
31
|
+
// common authoring mistake is reaching for <select-option> (mirroring the
|
|
32
|
+
// <*-ui> naming convention), which #parseOptions silently ignores. Matches
|
|
33
|
+
// v0.5.5 §184 §8 button-ui safety-net + v0.5.7 §201 color-picker WeakSet
|
|
34
|
+
// pattern. WeakSet so the warn doesn't pin the element from GC.
|
|
35
|
+
static #warnedNonOption = new WeakSet();
|
|
36
|
+
|
|
29
37
|
static properties = {
|
|
30
38
|
...UIFormElement.properties,
|
|
31
39
|
placeholder: { type: String, default: 'Select...', reflect: true },
|
|
@@ -201,6 +209,8 @@ export class UISelect extends UIFormElement {
|
|
|
201
209
|
/** Parse <option> and <optgroup> children into internal model. */
|
|
202
210
|
#parseOptions() {
|
|
203
211
|
this.#options = [];
|
|
212
|
+
// §225 (v0.5.9): track unknown-child-tag names so we can warn once per element.
|
|
213
|
+
const unknownTags = new Set();
|
|
204
214
|
for (const child of this.children) {
|
|
205
215
|
if (child.tagName === 'OPTGROUP') {
|
|
206
216
|
const group = { label: child.label || child.getAttribute('label') || '', options: [] };
|
|
@@ -210,9 +220,27 @@ export class UISelect extends UIFormElement {
|
|
|
210
220
|
this.#options.push(group);
|
|
211
221
|
} else if (child.tagName === 'OPTION') {
|
|
212
222
|
this.#options.push({ value: child.value, label: child.textContent.trim(), disabled: child.disabled });
|
|
223
|
+
} else if (
|
|
224
|
+
// §225: skip [slot="display"] / [slot="listbox"] / [slot="action"] etc. — these are
|
|
225
|
+
// stamped by the component itself, not consumer-authored options. Anything other
|
|
226
|
+
// than a slot-bearing child OR <option>/<optgroup> is a likely authoring mistake.
|
|
227
|
+
!child.hasAttribute('slot')
|
|
228
|
+
) {
|
|
229
|
+
unknownTags.add(child.tagName.toLowerCase());
|
|
213
230
|
}
|
|
214
231
|
}
|
|
215
232
|
for (const child of [...this.querySelectorAll('option, optgroup')]) child.remove();
|
|
233
|
+
// §225 (v0.5.9): warn once per element when consumer authored non-<option> children.
|
|
234
|
+
if (unknownTags.size > 0 && !UISelect.#warnedNonOption.has(this)) {
|
|
235
|
+
UISelect.#warnedNonOption.add(this);
|
|
236
|
+
// eslint-disable-next-line no-console
|
|
237
|
+
console.warn(
|
|
238
|
+
`<select-ui>: ignoring unrecognized child element(s) [${[...unknownTags].join(', ')}]. ` +
|
|
239
|
+
`Consumer-authored children must be native <option> or <optgroup>, NOT <select-option> ` +
|
|
240
|
+
`or other <*-ui> shapes. Or set element.options = [...] programmatically. ` +
|
|
241
|
+
`(Once-per-element warn; see select.yaml usage: for details.)`,
|
|
242
|
+
);
|
|
243
|
+
}
|
|
216
244
|
}
|
|
217
245
|
|
|
218
246
|
set options(list) {
|
|
@@ -314,7 +314,7 @@ select-ui[divider] [role="group"] + [role="group"] {
|
|
|
314
314
|
select-ui > [slot="hint"] {
|
|
315
315
|
display: block;
|
|
316
316
|
margin-top: var(--select-hint-mt, var(--a-space-1));
|
|
317
|
-
font-size: var(--select-hint-size, var(--a-
|
|
317
|
+
font-size: var(--select-hint-size, var(--a-ui-xs));
|
|
318
318
|
color: var(--select-hint-fg, var(--a-fg-muted));
|
|
319
319
|
line-height: var(--select-hint-lh, 1.4);
|
|
320
320
|
}
|
|
@@ -117,6 +117,34 @@ props:
|
|
|
117
117
|
events:
|
|
118
118
|
change:
|
|
119
119
|
description: Fired when selected value changes
|
|
120
|
+
usage: |-
|
|
121
|
+
§225 (v0.5.9) — Consumer-authored children must be native `<option>` or
|
|
122
|
+
`<optgroup>`. The `#parseOptions()` walker reads only those two tag names;
|
|
123
|
+
other shapes (including hypothetical `<select-option>` mirroring the `<*-ui>`
|
|
124
|
+
convention) are silently ignored. v0.5.9 adds a once-per-element
|
|
125
|
+
`console.warn` to surface the authoring mistake at runtime.
|
|
126
|
+
|
|
127
|
+
Two canonical paths:
|
|
128
|
+
|
|
129
|
+
```html
|
|
130
|
+
<!-- Path 1: native option children -->
|
|
131
|
+
<select-ui name="role" label="Role">
|
|
132
|
+
<option value="user">User</option>
|
|
133
|
+
<option value="admin">Admin</option>
|
|
134
|
+
<optgroup label="Special">
|
|
135
|
+
<option value="ghost">Ghost</option>
|
|
136
|
+
</optgroup>
|
|
137
|
+
</select-ui>
|
|
138
|
+
|
|
139
|
+
<!-- Path 2: programmatic .options property -->
|
|
140
|
+
<select-ui id="role" name="role" label="Role"></select-ui>
|
|
141
|
+
<script>
|
|
142
|
+
document.getElementById('role').options = [
|
|
143
|
+
{ value: 'user', label: 'User' },
|
|
144
|
+
{ value: 'admin', label: 'Admin' },
|
|
145
|
+
];
|
|
146
|
+
</script>
|
|
147
|
+
```
|
|
120
148
|
slots:
|
|
121
149
|
label:
|
|
122
150
|
description: Label element above the trigger
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
* @see https://ui-kit.exe.xyz/site/components/skeleton
|
|
5
5
|
*
|
|
6
6
|
* Type declarations generated by scripts/build/dts-codegen.mjs from
|
|
7
|
-
* the component's `.a2ui.json` sidecar. Edit the source `.yaml`,
|
|
7
|
+
* the component's `.a2ui.json` sidecar(s). Edit the source `.yaml`,
|
|
8
8
|
* run `npm run build:components`, then `npm run codegen:dts` to
|
|
9
9
|
* regenerate; or hand-author this file fully if rich event types are
|
|
10
10
|
* needed beyond what the yaml `events:` block can express.
|