@mt-gloss/ui 0.1.35 → 0.1.37
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/{Expandable-BKqvjtRQ.js → Expandable-Dojb6oU2.js} +3 -3
- package/catalog.js +2 -2
- package/index.js +591 -590
- package/lib/primitives/dashboard/ChartControlBar/useFilterLayout.d.ts +21 -0
- package/lib/primitives/dashboard/SnapOutline/SnapOutline.d.ts +11 -2
- package/lib/primitives/dashboard/gridMotionPrimitives.d.ts +1 -1
- package/package.json +1 -1
- package/ui.css +1 -1
|
@@ -32,6 +32,27 @@ export interface Geometry {
|
|
|
32
32
|
* Uses ResizeObserver and window resize to track geometry changes.
|
|
33
33
|
* Returns pill positions, filter tray positions, and track rectangles.
|
|
34
34
|
*
|
|
35
|
+
* ## Optional dimension group
|
|
36
|
+
*
|
|
37
|
+
* The dimension (entity-type) TabGroup is optional. Consumers may hide it via a
|
|
38
|
+
* feature flag (e.g. a per-userType template that disables the entity selector).
|
|
39
|
+
* When `dimensionGroupRef.current` is null the hook STILL measures and emits
|
|
40
|
+
* valid geometry for the remaining groups:
|
|
41
|
+
*
|
|
42
|
+
* - `tracks` contains 2 entries (metric + entity) instead of 3.
|
|
43
|
+
* - `entityPill`, `entityFilter.left`, `entityFilter.width` are zeroed —
|
|
44
|
+
* dimension-driven filter is unreachable when its trigger is absent.
|
|
45
|
+
* - Item-related geometry (item pill + item filter) is still computed correctly
|
|
46
|
+
* because those are derived from the entity group + entity tab refs, neither
|
|
47
|
+
* of which depends on the dimension group.
|
|
48
|
+
*
|
|
49
|
+
* Historical note (2026-04-23): the hook previously early-returned whenever
|
|
50
|
+
* `dg` was null, leaving geometry frozen at `DEFAULT_GEO` (empty tracks, zero
|
|
51
|
+
* filter widths). That caused the entire control-bar shell + item-filter
|
|
52
|
+
* popover to disappear for personas that legitimately hid the dimension group.
|
|
53
|
+
* The null-dg path is now a first-class supported configuration. See debug
|
|
54
|
+
* session `.planning/debug/chart-control-bar-regression.md` for full trace.
|
|
55
|
+
*
|
|
35
56
|
* @example
|
|
36
57
|
* ```tsx
|
|
37
58
|
* import { useFilterLayout } from '@mt-gloss/ui';
|
|
@@ -18,11 +18,20 @@ export interface SnapOutlineProps {
|
|
|
18
18
|
*
|
|
19
19
|
* Renders a `position: absolute` 2px solid border rectangle, translated to the
|
|
20
20
|
* target cell via `translate({left}px, {top}px)` where:
|
|
21
|
-
* - `
|
|
22
|
-
* - `
|
|
21
|
+
* - `absCol = cell.section * 3 + cell.col` (section offset applied)
|
|
22
|
+
* - `left = absCol * (colWidth + gap)`
|
|
23
|
+
* - `top = cell.row * (rowHeight + gap)`
|
|
23
24
|
* - `width = colSpan * colWidth + (colSpan - 1) * gap`
|
|
24
25
|
* - `height = rowHeight`
|
|
25
26
|
*
|
|
27
|
+
* COORDINATE CONTRACT: `cell.col` is SECTION-RELATIVE (0..2). The absolute grid
|
|
28
|
+
* column is computed here by adding `cell.section * 3`. Producers (useDragFeedback)
|
|
29
|
+
* emit section-relative col so predictCascade + snap outline share the same type.
|
|
30
|
+
* Prior to the `large-card-drop-positioning` debug fix (2026-04-22), this
|
|
31
|
+
* component treated `cell.col` as absolute, causing the outline to stick to
|
|
32
|
+
* section 1 regardless of cursor section — and to straddle the section boundary
|
|
33
|
+
* when a wide card hovered near the right of section 1.
|
|
34
|
+
*
|
|
26
35
|
* Transitions the transform at `${transitionMs ?? 120}ms cubic-bezier(0.4, 0, 0.2, 1)`.
|
|
27
36
|
* Under `prefers-reduced-motion: reduce`, `transition: none !important` strips
|
|
28
37
|
* the slide (SCSS-level override; see snap-outline.scss).
|
|
@@ -35,7 +35,7 @@ export declare const swingReveal: {
|
|
|
35
35
|
readonly exitDurationMs: 140;
|
|
36
36
|
readonly enterEasing: "cubic-bezier(0.34, 1.56, 0.64, 1)";
|
|
37
37
|
readonly exitEasing: "cubic-bezier(0.4, 0, 1, 1)";
|
|
38
|
-
readonly translateOffsetPx:
|
|
38
|
+
readonly translateOffsetPx: 8;
|
|
39
39
|
};
|
|
40
40
|
/** MOTION-05 — Rejection kinesthetic: ghost shiver on invalid drop. */
|
|
41
41
|
export declare const rejectionFeedback: {
|