@adia-ai/web-components 0.6.34 → 0.6.36
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 +71 -0
- package/color/index.js +1 -1
- package/components/accordion/accordion-item.yaml +2 -2
- package/components/accordion/accordion.js +1 -1
- package/components/action-list/action-item.yaml +2 -2
- package/components/action-list/action-list.js +1 -1
- package/components/agent-artifact/{class.js → agent-artifact.class.js} +1 -1
- package/components/agent-artifact/agent-artifact.js +1 -1
- package/components/agent-feedback-bar/agent-feedback-bar.js +1 -1
- package/components/agent-questions/agent-questions.js +1 -1
- package/components/agent-reasoning/agent-reasoning.js +1 -1
- package/components/agent-suggestions/agent-suggestions.js +1 -1
- package/components/alert/alert.a2ui.json +64 -1
- package/components/alert/{class.js → alert.class.js} +189 -2
- package/components/alert/alert.css +78 -0
- package/components/alert/alert.d.ts +14 -0
- package/components/alert/alert.js +1 -1
- package/components/alert/alert.test.js +184 -0
- package/components/alert/alert.yaml +114 -1
- package/components/avatar/avatar-group.yaml +2 -2
- package/components/avatar/avatar.js +1 -1
- package/components/badge/badge.js +1 -1
- package/components/block/block.js +1 -1
- package/components/breadcrumb/breadcrumb.js +1 -1
- package/components/button/button.js +1 -1
- package/components/calendar-grid/calendar-grid.a2ui.json +10 -0
- package/components/calendar-grid/{class.js → calendar-grid.class.js} +30 -4
- package/components/calendar-grid/calendar-grid.css +20 -0
- package/components/calendar-grid/calendar-grid.d.ts +4 -0
- package/components/calendar-grid/calendar-grid.js +1 -1
- package/components/calendar-grid/calendar-grid.yaml +20 -0
- package/components/calendar-picker/calendar-picker.js +1 -1
- package/components/card/card.js +1 -1
- package/components/chart/chart.js +1 -1
- package/components/chart-legend/chart-legend.js +1 -1
- package/components/chat-thread/chat-input.a2ui.json +1 -1
- package/components/chat-thread/chat-input.js +6 -1
- package/components/chat-thread/chat-input.yaml +4 -1
- package/components/chat-thread/chat-thread.js +1 -1
- package/components/check/check.js +1 -1
- package/components/code/code.js +1 -1
- package/components/col/col.js +1 -1
- package/components/color-input/color-input.js +1 -1
- package/components/color-picker/color-picker.js +1 -1
- package/components/combobox/combobox.css +12 -0
- package/components/combobox/combobox.js +1 -1
- package/components/command/command.js +1 -1
- package/components/date-range-picker/{class.js → date-range-picker.class.js} +19 -3
- package/components/date-range-picker/date-range-picker.css +55 -6
- package/components/date-range-picker/date-range-picker.js +1 -1
- package/components/datetime-picker/{class.js → datetime-picker.class.js} +1 -1
- package/components/datetime-picker/datetime-picker.css +7 -1
- package/components/datetime-picker/datetime-picker.js +1 -1
- package/components/demo-toggle/demo-toggle.js +1 -1
- package/components/description-list/description-list.js +1 -1
- package/components/divider/divider.js +1 -1
- package/components/drawer/drawer.js +1 -1
- package/components/embed/embed.js +1 -1
- package/components/empty-state/empty-state.js +1 -1
- package/components/feed/feed.js +1 -1
- package/components/field/field.js +1 -1
- package/components/field/field.test.js +1 -1
- package/components/fields/fields.js +1 -1
- package/components/grid/grid.js +1 -1
- package/components/heatmap/heatmap.js +1 -1
- package/components/icon/icon.js +1 -1
- package/components/image/image.js +1 -1
- package/components/index.js +3 -0
- package/components/inline-message/inline-message.a2ui.json +143 -0
- package/components/inline-message/inline-message.class.js +169 -0
- package/components/inline-message/inline-message.css +75 -0
- package/components/inline-message/inline-message.d.ts +31 -0
- package/components/inline-message/inline-message.examples.md +19 -0
- package/components/inline-message/inline-message.js +17 -0
- package/components/inline-message/inline-message.test.js +203 -0
- package/components/inline-message/inline-message.yaml +205 -0
- package/components/input/input.css +16 -2
- package/components/input/input.js +1 -1
- package/components/input/input.test.js +40 -0
- package/components/input/input.yaml +5 -4
- package/components/inspector/inspector.js +1 -1
- package/components/integration-card/integration-card.js +1 -1
- package/components/kbd/kbd.js +1 -1
- package/components/link/link.js +1 -1
- package/components/list/list-item.yaml +2 -2
- package/components/list/list.js +1 -1
- package/components/list-window/list-window.js +1 -1
- package/components/loading-overlay/loading-overlay.a2ui.json +176 -0
- package/components/loading-overlay/loading-overlay.class.js +203 -0
- package/components/loading-overlay/loading-overlay.css +81 -0
- package/components/loading-overlay/loading-overlay.d.ts +24 -0
- package/components/loading-overlay/loading-overlay.examples.md +50 -0
- package/components/loading-overlay/loading-overlay.js +17 -0
- package/components/loading-overlay/loading-overlay.test.js +257 -0
- package/components/loading-overlay/loading-overlay.yaml +260 -0
- package/components/menu/menu-divider.yaml +1 -1
- package/components/menu/menu-item.yaml +1 -1
- package/components/menu/menu.a2ui.json +3 -0
- package/components/menu/menu.js +1 -1
- package/components/menu/menu.yaml +7 -0
- package/components/modal/{class.js → modal.class.js} +12 -1
- package/components/modal/modal.css +11 -1
- package/components/modal/modal.js +1 -1
- package/components/nav/nav.js +1 -1
- package/components/nav-group/nav-group.js +1 -1
- package/components/nav-item/nav-item.js +1 -1
- package/components/noodles/noodles.js +1 -1
- package/components/option-card/option-card.js +1 -1
- package/components/otp-input/otp-input.js +1 -1
- package/components/page/page.js +1 -1
- package/components/pagination/pagination.js +1 -1
- package/components/pane/pane.js +1 -1
- package/components/pipeline-status/pipeline-status.js +1 -1
- package/components/popover/popover.a2ui.json +8 -1
- package/components/popover/popover.js +1 -1
- package/components/popover/popover.yaml +14 -1
- package/components/progress/progress.js +1 -1
- package/components/progress-row/progress-row.js +1 -1
- package/components/radio/radio.js +1 -1
- package/components/range/range.js +1 -1
- package/components/rating/rating.js +1 -1
- package/components/richtext/richtext.js +1 -1
- package/components/row/row.js +1 -1
- package/components/search/{class.js → search.class.js} +2 -0
- package/components/search/search.js +1 -1
- package/components/segment/segment.js +1 -1
- package/components/segmented/segmented.js +1 -1
- package/components/select/select.a2ui.json +58 -4
- package/components/select/{class.js → select.class.js} +415 -6
- package/components/select/select.css +158 -0
- package/components/select/select.d.ts +31 -1
- package/components/select/select.js +1 -1
- package/components/select/select.test.js +202 -0
- package/components/select/select.yaml +126 -5
- package/components/skeleton/skeleton.js +1 -1
- package/components/slider/slider.js +1 -1
- package/components/spinner/spinner.a2ui.json +3 -2
- package/components/spinner/{class.js → spinner.class.js} +33 -3
- package/components/spinner/spinner.css +91 -35
- package/components/spinner/spinner.d.ts +2 -2
- package/components/spinner/spinner.js +1 -1
- package/components/spinner/spinner.test.js +49 -11
- package/components/spinner/spinner.yaml +9 -1
- package/components/stack/stack.js +1 -1
- package/components/step-progress/step-progress.js +1 -1
- package/components/stepper/stepper-item.yaml +1 -1
- package/components/stepper/stepper.js +1 -1
- package/components/stream/stream.js +1 -1
- package/components/swatch/swatch.js +1 -1
- package/components/swiper/swiper.js +1 -1
- package/components/switch/switch.js +1 -1
- package/components/table/table.css +1 -1
- package/components/table/table.js +1 -1
- package/components/table-toolbar/{class.js → table-toolbar.class.js} +2 -1
- package/components/table-toolbar/table-toolbar.js +1 -1
- package/components/tabs/tab.yaml +2 -2
- package/components/tabs/tabs.js +1 -1
- package/components/tag/tag.a2ui.json +9 -0
- package/components/tag/{class.js → tag.class.js} +8 -1
- package/components/tag/tag.css +84 -20
- package/components/tag/tag.js +1 -1
- package/components/tag/tag.test.js +75 -1
- package/components/tag/tag.yaml +14 -0
- package/components/tags-input/tags-input.a2ui.json +337 -0
- package/components/tags-input/tags-input.class.js +783 -0
- package/components/tags-input/tags-input.css +210 -0
- package/components/tags-input/tags-input.d.ts +120 -0
- package/components/tags-input/tags-input.examples.md +92 -0
- package/components/tags-input/tags-input.js +17 -0
- package/components/tags-input/tags-input.test.js +368 -0
- package/components/tags-input/tags-input.yaml +367 -0
- package/components/text/text.js +1 -1
- package/components/textarea/textarea.a2ui.json +1 -1
- package/components/textarea/textarea.css +10 -1
- package/components/textarea/textarea.js +1 -1
- package/components/textarea/textarea.yaml +11 -8
- package/components/time-picker/time-picker.js +1 -1
- package/components/timeline/timeline-item.yaml +2 -2
- package/components/timeline/{class.js → timeline.class.js} +1 -1
- package/components/timeline/timeline.js +1 -1
- package/components/toast/toast.js +1 -1
- package/components/toggle-group/toggle-group.js +1 -1
- package/components/toggle-group/toggle-option.yaml +1 -1
- package/components/toggle-scheme/toggle-scheme.js +1 -1
- package/components/toolbar/toolbar-group.yaml +1 -1
- package/components/toolbar/toolbar.js +1 -1
- package/components/tooltip/tooltip.js +1 -1
- package/components/tree/tree-item.yaml +1 -1
- package/components/tree/tree.js +1 -1
- package/components/upload/upload.js +1 -1
- package/core/provider.js +19 -2
- package/dist/web-components.min.css +1 -1
- package/dist/web-components.min.js +112 -90
- package/package.json +3 -3
- package/styles/components.css +3 -0
- /package/components/accordion/{class.js → accordion.class.js} +0 -0
- /package/components/action-list/{class.js → action-list.class.js} +0 -0
- /package/components/agent-feedback-bar/{class.js → agent-feedback-bar.class.js} +0 -0
- /package/components/agent-questions/{class.js → agent-questions.class.js} +0 -0
- /package/components/agent-reasoning/{class.js → agent-reasoning.class.js} +0 -0
- /package/components/agent-suggestions/{class.js → agent-suggestions.class.js} +0 -0
- /package/components/avatar/{class.js → avatar.class.js} +0 -0
- /package/components/badge/{class.js → badge.class.js} +0 -0
- /package/components/block/{class.js → block.class.js} +0 -0
- /package/components/breadcrumb/{class.js → breadcrumb.class.js} +0 -0
- /package/components/button/{class.js → button.class.js} +0 -0
- /package/components/calendar-picker/{class.js → calendar-picker.class.js} +0 -0
- /package/components/card/{class.js → card.class.js} +0 -0
- /package/components/chart/{class.js → chart.class.js} +0 -0
- /package/components/chart-legend/{class.js → chart-legend.class.js} +0 -0
- /package/components/chat-thread/{class.js → chat-thread.class.js} +0 -0
- /package/components/check/{class.js → check.class.js} +0 -0
- /package/components/code/{class.js → code.class.js} +0 -0
- /package/components/col/{class.js → col.class.js} +0 -0
- /package/components/color-input/{class.js → color-input.class.js} +0 -0
- /package/components/color-picker/{class.js → color-picker.class.js} +0 -0
- /package/components/combobox/{class.js → combobox.class.js} +0 -0
- /package/components/command/{class.js → command.class.js} +0 -0
- /package/components/demo-toggle/{class.js → demo-toggle.class.js} +0 -0
- /package/components/description-list/{class.js → description-list.class.js} +0 -0
- /package/components/divider/{class.js → divider.class.js} +0 -0
- /package/components/drawer/{class.js → drawer.class.js} +0 -0
- /package/components/embed/{class.js → embed.class.js} +0 -0
- /package/components/empty-state/{class.js → empty-state.class.js} +0 -0
- /package/components/feed/{class.js → feed.class.js} +0 -0
- /package/components/field/{class.js → field.class.js} +0 -0
- /package/components/fields/{class.js → fields.class.js} +0 -0
- /package/components/grid/{class.js → grid.class.js} +0 -0
- /package/components/heatmap/{class.js → heatmap.class.js} +0 -0
- /package/components/icon/{class.js → icon.class.js} +0 -0
- /package/components/image/{class.js → image.class.js} +0 -0
- /package/components/input/{class.js → input.class.js} +0 -0
- /package/components/inspector/{class.js → inspector.class.js} +0 -0
- /package/components/integration-card/{class.js → integration-card.class.js} +0 -0
- /package/components/kbd/{class.js → kbd.class.js} +0 -0
- /package/components/link/{class.js → link.class.js} +0 -0
- /package/components/list/{class.js → list.class.js} +0 -0
- /package/components/list-window/{class.js → list-window.class.js} +0 -0
- /package/components/menu/{class.js → menu.class.js} +0 -0
- /package/components/nav/{class.js → nav.class.js} +0 -0
- /package/components/nav-group/{class.js → nav-group.class.js} +0 -0
- /package/components/nav-item/{class.js → nav-item.class.js} +0 -0
- /package/components/noodles/{class.js → noodles.class.js} +0 -0
- /package/components/option-card/{class.js → option-card.class.js} +0 -0
- /package/components/otp-input/{class.js → otp-input.class.js} +0 -0
- /package/components/page/{class.js → page.class.js} +0 -0
- /package/components/pagination/{class.js → pagination.class.js} +0 -0
- /package/components/pane/{class.js → pane.class.js} +0 -0
- /package/components/pipeline-status/{class.js → pipeline-status.class.js} +0 -0
- /package/components/popover/{class.js → popover.class.js} +0 -0
- /package/components/progress/{class.js → progress.class.js} +0 -0
- /package/components/progress-row/{class.js → progress-row.class.js} +0 -0
- /package/components/radio/{class.js → radio.class.js} +0 -0
- /package/components/range/{class.js → range.class.js} +0 -0
- /package/components/rating/{class.js → rating.class.js} +0 -0
- /package/components/richtext/{class.js → richtext.class.js} +0 -0
- /package/components/row/{class.js → row.class.js} +0 -0
- /package/components/segment/{class.js → segment.class.js} +0 -0
- /package/components/segmented/{class.js → segmented.class.js} +0 -0
- /package/components/skeleton/{class.js → skeleton.class.js} +0 -0
- /package/components/slider/{class.js → slider.class.js} +0 -0
- /package/components/stack/{class.js → stack.class.js} +0 -0
- /package/components/step-progress/{class.js → step-progress.class.js} +0 -0
- /package/components/stepper/{class.js → stepper.class.js} +0 -0
- /package/components/stream/{class.js → stream.class.js} +0 -0
- /package/components/swatch/{class.js → swatch.class.js} +0 -0
- /package/components/swiper/{class.js → swiper.class.js} +0 -0
- /package/components/switch/{class.js → switch.class.js} +0 -0
- /package/components/table/{class.js → table.class.js} +0 -0
- /package/components/tabs/{class.js → tabs.class.js} +0 -0
- /package/components/text/{class.js → text.class.js} +0 -0
- /package/components/textarea/{class.js → textarea.class.js} +0 -0
- /package/components/time-picker/{class.js → time-picker.class.js} +0 -0
- /package/components/toast/{class.js → toast.class.js} +0 -0
- /package/components/toggle-group/{class.js → toggle-group.class.js} +0 -0
- /package/components/toggle-scheme/{class.js → toggle-scheme.class.js} +0 -0
- /package/components/toolbar/{class.js → toolbar.class.js} +0 -0
- /package/components/tooltip/{class.js → tooltip.class.js} +0 -0
- /package/components/tree/{class.js → tree.class.js} +0 -0
- /package/components/upload/{class.js → upload.class.js} +0 -0
|
@@ -42,6 +42,26 @@ props:
|
|
|
42
42
|
type: boolean
|
|
43
43
|
default: false
|
|
44
44
|
reflect: true
|
|
45
|
+
rangeStart:
|
|
46
|
+
description: >-
|
|
47
|
+
Start of a date range (ISO YYYY-MM-DD). When both rangeStart and
|
|
48
|
+
rangeEnd are set + ordered, day cells strictly between the
|
|
49
|
+
endpoints get `[data-in-range]` stamped for visual continuity.
|
|
50
|
+
Used by `<date-range-picker-ui>` which pushes the same from/to
|
|
51
|
+
onto both calendar panes. Endpoints themselves render via the
|
|
52
|
+
`value` prop's `[data-selected]` state.
|
|
53
|
+
type: string
|
|
54
|
+
default: ''
|
|
55
|
+
reflect: true
|
|
56
|
+
attribute: range-start
|
|
57
|
+
rangeEnd:
|
|
58
|
+
description: >-
|
|
59
|
+
End of a date range (ISO YYYY-MM-DD). See `rangeStart` for the
|
|
60
|
+
full contract.
|
|
61
|
+
type: string
|
|
62
|
+
default: ''
|
|
63
|
+
reflect: true
|
|
64
|
+
attribute: range-end
|
|
45
65
|
events:
|
|
46
66
|
change:
|
|
47
67
|
description: User selected a date. detail.value is the ISO string.
|
package/components/card/card.js
CHANGED
|
@@ -62,7 +62,7 @@
|
|
|
62
62
|
"composes": [],
|
|
63
63
|
"events": {
|
|
64
64
|
"submit": {
|
|
65
|
-
"description": "Fires when the user presses Enter (without Shift) in the textarea OR clicks the built-in send button. The composer suppresses submission while `[loading]` is set.",
|
|
65
|
+
"description": "Fires when the user presses Enter (without Shift) in the textarea OR clicks the built-in send button. Unconditional — there is no [submit-on-enter] opt-in or opt-out attribute; Enter→submit is delegated from the inner <textarea-ui> which always emits a `submit` event on Enter without Shift. The composer suppresses submission while `[loading]` is set.",
|
|
66
66
|
"detail": {
|
|
67
67
|
"model": {
|
|
68
68
|
"description": "Currently selected model value (empty if no model picker).",
|
|
@@ -29,7 +29,12 @@ import { UIElement } from '../../core/element.js';
|
|
|
29
29
|
* can draft a follow-up while the model is still responding.
|
|
30
30
|
*
|
|
31
31
|
* Events:
|
|
32
|
-
* submit — user pressed Enter
|
|
32
|
+
* submit — user pressed Enter (without Shift) in the textarea or
|
|
33
|
+
* clicked the built-in send button (detail: { text, model,
|
|
34
|
+
* attachments }). Unconditional — Enter→submit is delegated
|
|
35
|
+
* from the inner <textarea-ui> which always emits a
|
|
36
|
+
* `submit` event on Enter without Shift. There is no
|
|
37
|
+
* [submit-on-enter] opt-in/opt-out attribute.
|
|
33
38
|
*
|
|
34
39
|
* Note:
|
|
35
40
|
* Composite wrapper, not a form field itself. The inner textarea-ui is
|
|
@@ -101,7 +101,10 @@ events:
|
|
|
101
101
|
submit:
|
|
102
102
|
description: >-
|
|
103
103
|
Fires when the user presses Enter (without Shift) in the textarea
|
|
104
|
-
OR clicks the built-in send button.
|
|
104
|
+
OR clicks the built-in send button. Unconditional — there is no
|
|
105
|
+
[submit-on-enter] opt-in or opt-out attribute; Enter→submit is
|
|
106
|
+
delegated from the inner <textarea-ui> which always emits a
|
|
107
|
+
`submit` event on Enter without Shift. The composer suppresses
|
|
105
108
|
submission while `[loading]` is set.
|
|
106
109
|
detail:
|
|
107
110
|
text:
|
package/components/code/code.js
CHANGED
package/components/col/col.js
CHANGED
|
@@ -130,11 +130,23 @@
|
|
|
130
130
|
line-height: 1.4;
|
|
131
131
|
white-space: nowrap;
|
|
132
132
|
overflow: hidden;
|
|
133
|
+
/* Positioning context for the [data-empty]::before placeholder pseudo
|
|
134
|
+
(kept out of inline flow so the caret renders at content-start). */
|
|
135
|
+
position: relative;
|
|
133
136
|
}
|
|
137
|
+
/* Empty-state placeholder. Absolutely positioned (NOT inline) so an
|
|
138
|
+
in-flow pseudo box doesn't push the caret-at-position-0 to the right
|
|
139
|
+
of the placeholder text after type-then-delete. Same pattern
|
|
140
|
+
input-ui + textarea-ui + tags-input-ui use. */
|
|
134
141
|
[data-input][data-empty]::before {
|
|
135
142
|
content: attr(data-placeholder);
|
|
136
143
|
color: var(--combobox-placeholder-fg, var(--combobox-placeholder-fg-default));
|
|
137
144
|
pointer-events: none;
|
|
145
|
+
position: absolute;
|
|
146
|
+
inset: 0;
|
|
147
|
+
padding: inherit;
|
|
148
|
+
display: flex;
|
|
149
|
+
align-items: center;
|
|
138
150
|
}
|
|
139
151
|
|
|
140
152
|
[data-clear] {
|
|
@@ -338,7 +338,7 @@ export class UIDateRangePicker extends UIFormElement {
|
|
|
338
338
|
this.#triggerRef.addEventListener('click', this.#onTriggerClick);
|
|
339
339
|
// Register keydown in CAPTURE phase so we set the keyboard-origin
|
|
340
340
|
// flag BEFORE <button-ui>'s own keydown handler synthesizes a
|
|
341
|
-
// click via `this.click()` (see button/class.js:148).
|
|
341
|
+
// click via `this.click()` (see button/button.class.js:148).
|
|
342
342
|
this.#triggerRef.addEventListener('keydown', this.#onTriggerKey, true);
|
|
343
343
|
this.#popoverRef.addEventListener('click', this.#onPopoverClick);
|
|
344
344
|
this.#popoverRef.addEventListener('keydown', this.#onPopoverKey);
|
|
@@ -433,15 +433,31 @@ export class UIDateRangePicker extends UIFormElement {
|
|
|
433
433
|
// Cascade min/max + selection state into the calendar panes.
|
|
434
434
|
const range = parseRange(this.value);
|
|
435
435
|
const pending = this.#pending;
|
|
436
|
+
// Effective endpoints — pending (mid-click) takes precedence over
|
|
437
|
+
// value. Push the SAME from/to onto BOTH grids so each independently
|
|
438
|
+
// lights up its in-range cells via `[data-in-range]`. Without this,
|
|
439
|
+
// only the two endpoint cells got `[data-selected]` and the days
|
|
440
|
+
// between them rendered as plain background — the "fill the cells
|
|
441
|
+
// between start and end dates" trap.
|
|
442
|
+
const effFrom = pending?.from || range?.from || '';
|
|
443
|
+
const effTo = pending?.to || range?.to || '';
|
|
444
|
+
const setRangeAttrs = (cal) => {
|
|
445
|
+
if (effFrom) cal.setAttribute('range-start', effFrom);
|
|
446
|
+
else cal.removeAttribute('range-start');
|
|
447
|
+
if (effTo) cal.setAttribute('range-end', effTo);
|
|
448
|
+
else cal.removeAttribute('range-end');
|
|
449
|
+
};
|
|
436
450
|
if (this.#calFromRef) {
|
|
437
451
|
if (this.min) this.#calFromRef.setAttribute('min', this.min);
|
|
438
452
|
if (this.max) this.#calFromRef.setAttribute('max', this.max);
|
|
439
453
|
this.#calFromRef.value = pending?.from || range?.from || '';
|
|
454
|
+
setRangeAttrs(this.#calFromRef);
|
|
440
455
|
}
|
|
441
456
|
if (this.#calToRef) {
|
|
442
457
|
if (this.min) this.#calToRef.setAttribute('min', this.min);
|
|
443
458
|
if (this.max) this.#calToRef.setAttribute('max', this.max);
|
|
444
459
|
this.#calToRef.value = pending?.to || range?.to || '';
|
|
460
|
+
setRangeAttrs(this.#calToRef);
|
|
445
461
|
}
|
|
446
462
|
|
|
447
463
|
// Render the preset rail (unless overridden by [slot="presets"] or
|
|
@@ -469,7 +485,7 @@ export class UIDateRangePicker extends UIFormElement {
|
|
|
469
485
|
// Matches select-ui + calendar-picker-ui's anchorPopover pattern.
|
|
470
486
|
this.#anchorCleanup?.();
|
|
471
487
|
this.#anchorCleanup = anchorPopover(this.#triggerRef, this.#popoverRef, {
|
|
472
|
-
placement: this.getAttribute('placement') || 'bottom
|
|
488
|
+
placement: this.getAttribute('placement') || 'bottom',
|
|
473
489
|
gap: 4,
|
|
474
490
|
});
|
|
475
491
|
document.addEventListener('pointerdown', this.#onOutside);
|
|
@@ -544,7 +560,7 @@ export class UIDateRangePicker extends UIFormElement {
|
|
|
544
560
|
|
|
545
561
|
// Flag set by #onTriggerKey to mark the *next* click as keyboard-originated.
|
|
546
562
|
// <button-ui> calls `this.click()` from its own Enter/Space keydown handler
|
|
547
|
-
// (see button/class.js:148), so the click that follows a keyboard press is
|
|
563
|
+
// (see button/button.class.js:148), so the click that follows a keyboard press is
|
|
548
564
|
// synthetic. We use this flag to disambiguate the `trigger:` field on the
|
|
549
565
|
// `open` event.
|
|
550
566
|
#keyboardOpen = false;
|
|
@@ -33,10 +33,26 @@
|
|
|
33
33
|
--date-range-picker-selected-fg-default: var(--a-accent-fg);
|
|
34
34
|
--date-range-picker-preview-bg-default: var(--a-accent-muted);
|
|
35
35
|
|
|
36
|
-
/* Trigger
|
|
36
|
+
/* Trigger — mirrors the canonical trigger surface used by
|
|
37
|
+
<select-ui> and <calendar-picker-ui> so consumers see a
|
|
38
|
+
consistent open-picker chrome across the input/picker family.
|
|
39
|
+
The values are deliberately the same tokens select/calendar
|
|
40
|
+
cascade onto their own `--*-trigger-*` aliases. */
|
|
37
41
|
--date-range-picker-trigger-min-width-default: 14em;
|
|
38
|
-
|
|
39
|
-
|
|
42
|
+
--date-range-picker-trigger-height-default: var(--a-size);
|
|
43
|
+
--date-range-picker-trigger-px-default: var(--a-ui-px);
|
|
44
|
+
--date-range-picker-trigger-gap-default: var(--a-space-1);
|
|
45
|
+
--date-range-picker-trigger-radius-default: var(--a-radius);
|
|
46
|
+
--date-range-picker-trigger-bg-default: var(--a-ui-bg);
|
|
47
|
+
--date-range-picker-trigger-bg-hover-default: var(--a-ui-bg-hover);
|
|
48
|
+
--date-range-picker-trigger-fg-default: var(--a-ui-text-subtle);
|
|
49
|
+
--date-range-picker-trigger-border-default: var(--a-ui-border);
|
|
50
|
+
--date-range-picker-trigger-border-hover-default: var(--a-ui-border-hover);
|
|
51
|
+
--date-range-picker-trigger-focus-ring-default: var(--a-focus-ring);
|
|
52
|
+
|
|
53
|
+
/* Popover-internal padding (NOT the trigger — kept distinct from
|
|
54
|
+
--date-range-picker-trigger-px to avoid the historical conflation
|
|
55
|
+
that made the trigger render with --a-space-3 vertical inflation). */
|
|
40
56
|
--date-range-picker-px-default: var(--a-space-3);
|
|
41
57
|
--date-range-picker-py-default: var(--a-space-2);
|
|
42
58
|
|
|
@@ -46,19 +62,52 @@
|
|
|
46
62
|
}
|
|
47
63
|
|
|
48
64
|
/* ── Block 2 — BASE ── */
|
|
65
|
+
/* Host is a transparent inline wrapper — trigger button-ui paints its
|
|
66
|
+
own surface. Mirrors the datetime-picker decision (2026-05-24): a host
|
|
67
|
+
background paint creates an off-axis rectangle inside field-ui because
|
|
68
|
+
the field-ui's value-cell expands beyond the inline-block host. */
|
|
49
69
|
:scope {
|
|
50
70
|
box-sizing: border-box;
|
|
51
71
|
position: relative;
|
|
52
72
|
display: inline-block;
|
|
53
|
-
background: var(--date-range-picker-bg, var(--date-range-picker-bg-default));
|
|
54
73
|
color: var(--date-range-picker-fg, var(--date-range-picker-fg-default));
|
|
55
74
|
font-size: var(--a-ui-size);
|
|
56
75
|
}
|
|
57
76
|
|
|
58
|
-
/*
|
|
59
|
-
|
|
77
|
+
/* ── Trigger ──
|
|
78
|
+
Canonical trigger surface matching <select-ui> + <calendar-picker-ui>:
|
|
79
|
+
flex row, --a-size min-height, --a-ui-px padding, --a-radius corner,
|
|
80
|
+
--a-ui-border outline. The trigger is a <button-ui slot="trigger">
|
|
81
|
+
stamped by date-range-picker.class.js — these rules override button-ui's defaults at
|
|
82
|
+
equal specificity so the picker trigger reads as part of the
|
|
83
|
+
input/picker family rather than a generic button. */
|
|
60
84
|
:scope > [slot="trigger"] {
|
|
61
85
|
min-width: var(--date-range-picker-trigger-min-width, var(--date-range-picker-trigger-min-width-default));
|
|
86
|
+
min-height: var(--date-range-picker-trigger-height, var(--date-range-picker-trigger-height-default));
|
|
87
|
+
padding: 0 var(--date-range-picker-trigger-px, var(--date-range-picker-trigger-px-default));
|
|
88
|
+
gap: var(--date-range-picker-trigger-gap, var(--date-range-picker-trigger-gap-default));
|
|
89
|
+
border-radius: var(--date-range-picker-trigger-radius, var(--date-range-picker-trigger-radius-default));
|
|
90
|
+
border: 1px solid var(--date-range-picker-trigger-border, var(--date-range-picker-trigger-border-default));
|
|
91
|
+
background: var(--date-range-picker-trigger-bg, var(--date-range-picker-trigger-bg-default));
|
|
92
|
+
color: var(--date-range-picker-trigger-fg, var(--date-range-picker-trigger-fg-default));
|
|
93
|
+
/* Justify content so leading icon + label sit at start, trailing
|
|
94
|
+
caret at end — same shape select-ui's trigger uses via
|
|
95
|
+
`justify-content: space-between` on a [leading|display|caret]
|
|
96
|
+
slot triplet. button-ui's natural alignment is `center`; our
|
|
97
|
+
leading+text+trailing layout reads better as space-between. */
|
|
98
|
+
justify-content: space-between;
|
|
99
|
+
line-height: 1;
|
|
100
|
+
transition:
|
|
101
|
+
border-color var(--date-range-picker-duration, var(--date-range-picker-duration-default)) var(--date-range-picker-easing, var(--date-range-picker-easing-default)),
|
|
102
|
+
background var(--date-range-picker-duration, var(--date-range-picker-duration-default)) var(--date-range-picker-easing, var(--date-range-picker-easing-default));
|
|
103
|
+
}
|
|
104
|
+
:scope > [slot="trigger"]:hover {
|
|
105
|
+
border-color: var(--date-range-picker-trigger-border-hover, var(--date-range-picker-trigger-border-hover-default));
|
|
106
|
+
background: var(--date-range-picker-trigger-bg-hover, var(--date-range-picker-trigger-bg-hover-default));
|
|
107
|
+
}
|
|
108
|
+
:scope:focus-visible { outline: none; }
|
|
109
|
+
:scope:focus-visible > [slot="trigger"] {
|
|
110
|
+
box-shadow: var(--date-range-picker-trigger-focus-ring, var(--date-range-picker-trigger-focus-ring-default));
|
|
62
111
|
}
|
|
63
112
|
|
|
64
113
|
/* States */
|
|
@@ -293,7 +293,7 @@ export class UIDatetimePicker extends UIFormElement {
|
|
|
293
293
|
this.#ensureParts();
|
|
294
294
|
this.#triggerRef.addEventListener('click', this.#onTriggerClick);
|
|
295
295
|
// Capture-phase so we flag keyboard-origin BEFORE <button-ui>'s
|
|
296
|
-
// own keydown synthesizes the click (button/class.js:148).
|
|
296
|
+
// own keydown synthesizes the click (button/button.class.js:148).
|
|
297
297
|
this.#triggerRef.addEventListener('keydown', this.#onTriggerKey, true);
|
|
298
298
|
this.#popoverRef.addEventListener('click', this.#onPopoverClick);
|
|
299
299
|
this.#popoverRef.addEventListener('keydown', this.#onPopoverKey);
|
|
@@ -38,11 +38,17 @@
|
|
|
38
38
|
}
|
|
39
39
|
|
|
40
40
|
/* ── Block 2 — BASE ── */
|
|
41
|
+
/* Host is a transparent inline wrapper. Painting `background` on the host
|
|
42
|
+
used to create an off-axis rectangle behind the trigger when the host
|
|
43
|
+
sat inside a field-ui (the field-ui's value-cell expanded but the
|
|
44
|
+
inline-block host only sized to its child). Trigger button-ui paints
|
|
45
|
+
its own surface — host stays transparent.
|
|
46
|
+
2026-05-24 QA: "odd background colors and block element container for
|
|
47
|
+
inline trigger" — consumer report on /site/components/datetime-picker. */
|
|
41
48
|
:scope {
|
|
42
49
|
box-sizing: border-box;
|
|
43
50
|
position: relative;
|
|
44
51
|
display: inline-block;
|
|
45
|
-
background: var(--datetime-picker-bg, var(--datetime-picker-bg-default));
|
|
46
52
|
color: var(--datetime-picker-fg, var(--datetime-picker-fg-default));
|
|
47
53
|
font-size: var(--a-ui-size);
|
|
48
54
|
}
|
package/components/feed/feed.js
CHANGED
|
@@ -10,7 +10,7 @@
|
|
|
10
10
|
*/
|
|
11
11
|
|
|
12
12
|
import { defineIfFree } from '../../core/register.js';
|
|
13
|
-
import { UIFeedContainer, UIFeedItem, UIFeed } from './class.js';
|
|
13
|
+
import { UIFeedContainer, UIFeedItem, UIFeed } from './feed.class.js';
|
|
14
14
|
|
|
15
15
|
defineIfFree('feed-ui', UIFeedContainer);
|
|
16
16
|
defineIfFree('feed-item-ui', UIFeedItem);
|
|
@@ -201,7 +201,7 @@ describe('field-ui', () => {
|
|
|
201
201
|
// The CSS rule must be present in the source; this test documents intent
|
|
202
202
|
// rather than measuring computed style (which requires a real browser for @scope).
|
|
203
203
|
const fieldCssSource = document.head.innerHTML + document.body.innerHTML;
|
|
204
|
-
// Accept if either the stylesheet is found OR the class.js property is declared.
|
|
204
|
+
// Accept if either the stylesheet is found OR the field.class.js property is declared.
|
|
205
205
|
const hasAlignProp = f => f.align !== undefined;
|
|
206
206
|
const f = mount('<field-ui label="X"><input /></field-ui>');
|
|
207
207
|
expect(hasAlignProp(f)).toBe(true);
|
package/components/grid/grid.js
CHANGED
package/components/icon/icon.js
CHANGED
package/components/index.js
CHANGED
|
@@ -62,7 +62,9 @@ export { UIProgress } from './progress/progress.js';
|
|
|
62
62
|
export { UIStepProgress } from './step-progress/step-progress.js';
|
|
63
63
|
export { UISkeleton } from './skeleton/skeleton.js';
|
|
64
64
|
export { UISpinner } from './spinner/spinner.js';
|
|
65
|
+
export { UILoadingOverlay } from './loading-overlay/loading-overlay.js';
|
|
65
66
|
export { UIAlert } from './alert/alert.js';
|
|
67
|
+
export { UIInlineMessage } from './inline-message/inline-message.js';
|
|
66
68
|
export { UIKbd } from './kbd/kbd.js';
|
|
67
69
|
export { UITag } from './tag/tag.js';
|
|
68
70
|
export { UISwatch } from './swatch/swatch.js';
|
|
@@ -90,6 +92,7 @@ export { UIOtpInput } from './otp-input/otp-input.js';
|
|
|
90
92
|
export { UIImage } from './image/image.js';
|
|
91
93
|
export { UISearch } from './search/search.js';
|
|
92
94
|
export { UICombobox } from './combobox/combobox.js';
|
|
95
|
+
export { UITagsInput } from './tags-input/tags-input.js';
|
|
93
96
|
export { UIStat } from './stat/stat.js';
|
|
94
97
|
export { UIProgressRow } from './progress-row/progress-row.js';
|
|
95
98
|
export { UIActionList, UIActionItem } from './action-list/action-list.js';
|