@ai-matrx/design-system 0.11.4 → 0.11.6

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/dist/styles.css CHANGED
@@ -782,48 +782,6 @@
782
782
  var(--matrx-glass-border-color);
783
783
  }
784
784
 
785
- /* -----------------------------------------------------------------------
786
- .matrx-dialog-footer — THE STICKY FOOTER'S GEOMETRY, in one place.
787
-
788
- This used to be a string of Tailwind utilities on `DialogFooter` and
789
- `AlertDialogFooter`, and one of them — a NEGATIVE BOTTOM MARGIN used to
790
- bleed the footer over the card's bottom padding — silently clipped the
791
- thing the destructive-actions law exists to make readable (0.11.3, feedback
792
- bf8fb00b). The mechanism, measured in Chrome at 1280x800:
793
-
794
- a `position: sticky` element is CLAMPED to its containing block (here
795
- the grid area / flex line the card gives it). A negative bottom margin
796
- makes the footer's BORDER box taller than that area by exactly
797
- `--dialog-pad`, so the browser yanks the whole footer UP by that amount.
798
- With `--dialog-pad: 1.5rem` and `gap-4` that is 24px up against a 16px
799
- gap: an 8px overlap in which the opaque footer painted over the last
800
- line of the consequence — at EVERY description length, and unreachable
801
- by scrolling, because the card's `scrollHeight === clientHeight`.
802
-
803
- The bleed is now bought without a negative block margin: the footer owns
804
- the card's BOTTOM padding (`padding-bottom`), the card gives it up (see
805
- the reservation rule below), and only the INLINE bleed stays a negative
806
- margin — sticky clamps the block axis, never the inline one.
807
-
808
- `--dialog-pad-bottom` lets a card ask for more than `--dialog-pad` at the
809
- bottom edge; the mobile sheet uses it for the home-indicator safe area.
810
- ----------------------------------------------------------------------- */
811
- .matrx-dialog-footer {
812
- position: sticky;
813
- bottom: 0;
814
- z-index: 10;
815
- padding-top: 0.75rem;
816
- margin-inline: calc(var(--dialog-pad, 0px) * -1);
817
- padding-inline: var(--dialog-pad, 0px);
818
- padding-bottom: var(--dialog-pad-bottom, var(--dialog-pad, 0px));
819
- }
820
-
821
- /* The sheet's bottom edge is the phone's bottom edge — the footer has to
822
- clear the home indicator, which is what the card's `pb-safe` used to do
823
- before the footer took the bottom padding over. Same `max()` floor. */
824
- .matrx-mobile-sheet {
825
- --dialog-pad-bottom: max(0.75rem, env(safe-area-inset-bottom, 0px));
826
- }
827
785
 
828
786
  /* ────────────────────────────────────────────────────────────────────────
829
787
  .matrx-dialog-card — THE FOOTER RESERVATION.
@@ -831,8 +789,18 @@
831
789
  A card that contains a sticky footer gives its bottom padding TO that
832
790
  footer, so the footer's box is exactly as tall as the space the card
833
791
  allocated it. That is what keeps `position: sticky` from clamping the
834
- footer upward over the preceding row (the 0.11.3 defect; see
835
- `.matrx-dialog-footer` above for the measured mechanism).
792
+ footer upward over the preceding row.
793
+
794
+ THE MECHANISM (measured in Chrome at 1280x800, 0.11.2). The footer used to
795
+ bleed over this padding with `mb-[calc(var(--dialog-pad,0px)*-1)]`. A
796
+ negative bottom margin makes an element's BORDER box taller than the grid
797
+ area (or flex line) its parent allocated it, and `position: sticky` CLAMPS a
798
+ box to its containing block — so the browser yanked the whole footer UP by
799
+ `--dialog-pad` (24px) against a `gap-4` (16px). The 8px difference was
800
+ opaque footer painted over the last line of the consequence copy, at EVERY
801
+ description length, and unreachable: the card's
802
+ `scrollHeight === clientHeight`, so nothing could scroll it into view.
803
+ Feedback `bf8fb00b`.
836
804
 
837
805
  Two consequences worth stating out loud:
838
806
  • a card with NO footer keeps its full padding — the reservation is
@@ -844,14 +812,33 @@
844
812
  the actions.
845
813
 
846
814
  Deliberately UNLAYERED: it has to beat the card's own `p-6` / `p-4 pb-safe`
847
- utilities, which live in `@layer utilities` (and in this package's own
848
- layer, for `pb-safe`). Unlayered beats every layered rule regardless of
849
- specificity — the same reason the sheet density restatement below is.
815
+ utilities, which live in `@layer utilities`. Unlayered beats every layered
816
+ rule regardless of specificity the same reason the sheet density
817
+ restatement below is.
818
+
819
+ And deliberately ONE-SIDED: the FOOTER's geometry stays Tailwind utilities
820
+ on the element, never a rule, so a caller's `className` still overrides its
821
+ padding through tailwind-merge exactly as it always has. Only the card half,
822
+ which no caller addresses, is CSS.
850
823
  ──────────────────────────────────────────────────────────────────────── */
851
- .matrx-dialog-card:has(> .matrx-dialog-footer) {
824
+ .matrx-dialog-card:has(> [data-slot="dialog-footer"]),
825
+ .matrx-dialog-card:has(> [data-slot="alert-dialog-footer"]) {
852
826
  padding-bottom: 0;
853
827
  }
854
828
 
829
+ /* The mobile sheet's bottom edge IS the phone's bottom edge. Its card used to
830
+ buy the home-indicator clearance with `pb-safe`; the reservation above hands
831
+ that padding to the footer, so the floor has to be restated HERE or the
832
+ actions land under the indicator. `max()` so the sheet's own `--dialog-pad`
833
+ (1rem) still applies on a device with no inset.
834
+
835
+ This is the ONE place a shipped rule overrides a caller's footer padding, and
836
+ it is a safety floor rather than taste — exactly what `.pb-safe` was doing on
837
+ this element's parent before. */
838
+ .matrx-mobile-sheet > [data-slot="dialog-footer"] {
839
+ padding-bottom: max(var(--dialog-pad, 0px), env(safe-area-inset-bottom, 0px));
840
+ }
841
+
855
842
  /* ────────────────────────────────────────────────────────────────────────
856
843
  .matrx-mobile-sheet — ONE mobile density for any desktop panel hosted in a
857
844
  bottom sheet (TabbedBottomSheet sets it; see that file's header).
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@ai-matrx/design-system",
3
- "version": "0.11.4",
3
+ "version": "0.11.6",
4
4
  "description": "AI Matrx semantic React primitives shared across Vite, Next.js, desktop, and customer-built applications.",
5
5
  "type": "module",
6
6
  "license": "MIT",