@adia-ai/web-components 0.8.46 → 0.8.47
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 +9 -0
- package/components/nav/nav.css +7 -3
- package/components/nav-group/nav-group.css +38 -41
- package/components/nav-item/nav-item.css +11 -5
- package/components/preview/preview.class.js +12 -2
- package/components/table-toolbar/table-toolbar.a2ui.json +10 -0
- package/components/table-toolbar/table-toolbar.class.js +70 -7
- package/components/table-toolbar/table-toolbar.css +100 -3
- package/components/table-toolbar/table-toolbar.d.ts +2 -0
- package/components/table-toolbar/table-toolbar.examples.md +41 -41
- package/components/table-toolbar/table-toolbar.yaml +14 -0
- package/core/anchor.js +21 -1
- package/custom-elements.json +7 -0
- package/dist/host.min.css +1 -1
- package/dist/host.sheet.js +1 -1
- package/dist/theme-provider.min.js +2 -2
- package/dist/web-components.min.css +1 -1
- package/dist/web-components.min.js +31 -31
- package/dist/web-components.sheet.js +1 -1
- package/package.json +1 -1
- package/styles/colors/material-static.css +276 -234
package/core/anchor.js
CHANGED
|
@@ -122,7 +122,27 @@ function anchorNative(anchor, popover, { placement, gap, matchWidth }) {
|
|
|
122
122
|
popover.style.left = '';
|
|
123
123
|
|
|
124
124
|
return () => {
|
|
125
|
-
|
|
125
|
+
// Ownership-guarded restore (bug, found live): a trigger element that
|
|
126
|
+
// is ITSELF a popover's own `[slot="trigger"]` can become the anchor
|
|
127
|
+
// for a SECOND, nested popover opened from inside the first (menu-ui's
|
|
128
|
+
// dropdown item dispatching `action`, which table-toolbar-ui's overflow
|
|
129
|
+
// "More" trigger handles by re-anchoring a filter/sort/columns panel to
|
|
130
|
+
// that SAME element). Anchor-name assignment here is a blind overwrite,
|
|
131
|
+
// never a set/append — so whichever `anchorPopover()` call's cleanup
|
|
132
|
+
// runs LAST always wins, even when it's cleaning up a DIFFERENT,
|
|
133
|
+
// already-superseded anchor-name than the one currently on the element.
|
|
134
|
+
// menu-ui's own close (`render()`'s reactive `#hide()`, scheduled async
|
|
135
|
+
// — reordering the synchronous call site doesn't change when this
|
|
136
|
+
// runs) fires after the nested popover's `anchorPopover()` has already
|
|
137
|
+
// claimed the trigger, and unconditionally restoring `prevAnchorName`
|
|
138
|
+
// clobbered that fresh claim back to empty — the nested popover's own
|
|
139
|
+
// `position-anchor` was left pointing at a name resolving to nothing,
|
|
140
|
+
// rendering unpositioned at the viewport origin instead of near its
|
|
141
|
+
// trigger. Only restore when this cleanup's OWN name is still the
|
|
142
|
+
// current value — i.e., nobody has claimed the anchor since; otherwise
|
|
143
|
+
// leave it alone, since undoing someone else's still-active claim is
|
|
144
|
+
// never correct regardless of call order.
|
|
145
|
+
if (anchor.style.anchorName === name) anchor.style.anchorName = prevAnchorName;
|
|
126
146
|
for (const [k, v] of Object.entries(prevStyles)) popover.style[k] = v;
|
|
127
147
|
};
|
|
128
148
|
}
|
package/custom-elements.json
CHANGED
|
@@ -10044,6 +10044,13 @@
|
|
|
10044
10044
|
},
|
|
10045
10045
|
"description": "id-ref of the table-ui to control. Falls back to the first sibling table-ui within the same parent when omitted."
|
|
10046
10046
|
},
|
|
10047
|
+
{
|
|
10048
|
+
"name": "size",
|
|
10049
|
+
"type": {
|
|
10050
|
+
"text": "string"
|
|
10051
|
+
},
|
|
10052
|
+
"description": "Toolbar scale, via sizing.css's universal [size=\"sm|md|lg\"] ambient tokens. Not table-toolbar-specific chrome — the same attribute that scales any component. Set it once on the toolbar instead of on each slotted scope/actions-leading/actions control individually; anything slotted with no [size] of its own inherits the ambient value. Default (empty) = md."
|
|
10053
|
+
},
|
|
10047
10054
|
{
|
|
10048
10055
|
"name": "text",
|
|
10049
10056
|
"type": {
|