@ai-matrx/design-system 0.11.4 → 0.11.5
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 +46 -0
- package/dist/index.cjs +41 -14
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +7 -7
- package/dist/index.d.ts +7 -7
- package/dist/index.js +41 -14
- package/dist/index.js.map +1 -1
- package/dist/styles.css +36 -43
- package/package.json +1 -1
package/dist/index.d.cts
CHANGED
|
@@ -182,8 +182,8 @@ declare const AlertDescription: React.ForwardRefExoticComponent<React.HTMLAttrib
|
|
|
182
182
|
* was dragged UP by `--dialog-pad` against the card's `gap-4`, covering the
|
|
183
183
|
* last 8px of the consequence copy at every length, unreachable because the
|
|
184
184
|
* card did not scroll. The bleed is now the card's RESERVATION
|
|
185
|
-
* (
|
|
186
|
-
*
|
|
185
|
+
* (`.matrx-dialog-card` hands its bottom padding to the footer), which
|
|
186
|
+
* sticky has nothing to clamp. See `sticky-footer-geometry.test.tsx`.
|
|
187
187
|
*
|
|
188
188
|
* SEAM INVERSION. The host resolved its portal target through
|
|
189
189
|
* `usePopoutContainer` (its window-panel popout body); here that is the
|
|
@@ -774,11 +774,11 @@ declare function CreatablePicker({ value, options, onSelect, placeholder, search
|
|
|
774
774
|
* `--dialog-pad`. Until 0.11.3 that bleed was a NEGATIVE BLOCK MARGIN,
|
|
775
775
|
* which sticky clamps: the footer was dragged up over the row above it by
|
|
776
776
|
* `--dialog-pad` minus the card gap. The card now RESERVES the footer's
|
|
777
|
-
* block size instead (
|
|
778
|
-
*
|
|
779
|
-
* footer never covers the row above it. Outside a
|
|
780
|
-
* unset, the padding falls back to `0px`,
|
|
781
|
-
* it always was.
|
|
777
|
+
* block size instead (`.matrx-dialog-card` in `styles.css` hands its bottom
|
|
778
|
+
* padding to the footer), so scrolled content never shows through beneath
|
|
779
|
+
* the actions AND the footer never covers the row above it. Outside a
|
|
780
|
+
* DialogContent both variables are unset, the padding falls back to `0px`,
|
|
781
|
+
* and the footer is the plain row it always was.
|
|
782
782
|
*
|
|
783
783
|
* 4. ON MOBILE THE SAME DIALOG IS A BOTTOM SHEET — full width, bottom
|
|
784
784
|
* anchored, height-capped, internally scrollable, safe-area padded. Opt out
|
package/dist/index.d.ts
CHANGED
|
@@ -182,8 +182,8 @@ declare const AlertDescription: React.ForwardRefExoticComponent<React.HTMLAttrib
|
|
|
182
182
|
* was dragged UP by `--dialog-pad` against the card's `gap-4`, covering the
|
|
183
183
|
* last 8px of the consequence copy at every length, unreachable because the
|
|
184
184
|
* card did not scroll. The bleed is now the card's RESERVATION
|
|
185
|
-
* (
|
|
186
|
-
*
|
|
185
|
+
* (`.matrx-dialog-card` hands its bottom padding to the footer), which
|
|
186
|
+
* sticky has nothing to clamp. See `sticky-footer-geometry.test.tsx`.
|
|
187
187
|
*
|
|
188
188
|
* SEAM INVERSION. The host resolved its portal target through
|
|
189
189
|
* `usePopoutContainer` (its window-panel popout body); here that is the
|
|
@@ -774,11 +774,11 @@ declare function CreatablePicker({ value, options, onSelect, placeholder, search
|
|
|
774
774
|
* `--dialog-pad`. Until 0.11.3 that bleed was a NEGATIVE BLOCK MARGIN,
|
|
775
775
|
* which sticky clamps: the footer was dragged up over the row above it by
|
|
776
776
|
* `--dialog-pad` minus the card gap. The card now RESERVES the footer's
|
|
777
|
-
* block size instead (
|
|
778
|
-
*
|
|
779
|
-
* footer never covers the row above it. Outside a
|
|
780
|
-
* unset, the padding falls back to `0px`,
|
|
781
|
-
* it always was.
|
|
777
|
+
* block size instead (`.matrx-dialog-card` in `styles.css` hands its bottom
|
|
778
|
+
* padding to the footer), so scrolled content never shows through beneath
|
|
779
|
+
* the actions AND the footer never covers the row above it. Outside a
|
|
780
|
+
* DialogContent both variables are unset, the padding falls back to `0px`,
|
|
781
|
+
* and the footer is the plain row it always was.
|
|
782
782
|
*
|
|
783
783
|
* 4. ON MOBILE THE SAME DIALOG IS A BOTTOM SHEET — full width, bottom
|
|
784
784
|
* anchored, height-capped, internally scrollable, safe-area padded. Opt out
|
package/dist/index.js
CHANGED
|
@@ -824,7 +824,7 @@ var AlertDialogContent = React7.forwardRef(({ className, children, container, an
|
|
|
824
824
|
// a sticky footer when there is one, so the footer's box matches the
|
|
825
825
|
// space the grid gave it and sticky never clamps it up over the
|
|
826
826
|
// consequence copy.
|
|
827
|
-
"max-h-[85dvh] overflow-y-auto overscroll-contain [--dialog-pad:1.5rem] overflow-x-clip [overflow-wrap:anywhere] [&>*]:min-w-0 [&>*]:max-w-full",
|
|
827
|
+
"max-h-[85dvh] overflow-y-auto overscroll-contain [--dialog-pad:1.5rem] [--dialog-pad-bottom:1.5rem] overflow-x-clip [overflow-wrap:anywhere] [&>*]:min-w-0 [&>*]:max-w-full",
|
|
828
828
|
"sm:rounded-lg",
|
|
829
829
|
animated && MOTION_DIALOG,
|
|
830
830
|
className
|
|
@@ -861,12 +861,25 @@ var AlertDialogFooter = ({
|
|
|
861
861
|
className: cn(
|
|
862
862
|
"flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",
|
|
863
863
|
// Ruling 3/4 — sticky to the card edges so a scrolled body never shows
|
|
864
|
-
// through under the actions, and safe-area padded on a phone.
|
|
865
|
-
//
|
|
866
|
-
//
|
|
867
|
-
//
|
|
868
|
-
//
|
|
869
|
-
|
|
864
|
+
// through under the actions, and safe-area padded on a phone.
|
|
865
|
+
//
|
|
866
|
+
// 🚨 THERE IS NO `mb-[…]` HERE, AND THERE MUST NEVER BE ONE AGAIN
|
|
867
|
+
// (0.11.3, feedback bf8fb00b). The bleed over the card's bottom padding
|
|
868
|
+
// used to be a NEGATIVE BLOCK MARGIN, which makes this box taller than
|
|
869
|
+
// the grid area the card allocates it — and `position: sticky` CLAMPS a
|
|
870
|
+
// box to its containing block, so the browser yanked the footer UP by
|
|
871
|
+
// `--dialog-pad` against the card's `gap-4` and painted 8px of opaque
|
|
872
|
+
// footer over the last line of the consequence, at every length. The
|
|
873
|
+
// card now RESERVES this footer's block size instead (`matrx-dialog-card`
|
|
874
|
+
// in styles.css hands over its `padding-bottom`), so the bleed costs no
|
|
875
|
+
// margin at all. Guard: `sticky-footer-geometry.test.tsx`.
|
|
876
|
+
//
|
|
877
|
+
// These stay UTILITIES rather than a shipped rule so a caller's
|
|
878
|
+
// `className` still wins through tailwind-merge — a shipped rule would
|
|
879
|
+
// have to be unlayered to survive Tailwind preflight (§ THE PREFLIGHT
|
|
880
|
+
// RULE in styles.css) and would then override every caller's padding.
|
|
881
|
+
"sticky bottom-0 z-10 bg-background pt-3",
|
|
882
|
+
"mx-[calc(var(--dialog-pad,0px)*-1)] px-[var(--dialog-pad,0px)] pb-[var(--dialog-pad-bottom,0px)]",
|
|
870
883
|
className
|
|
871
884
|
),
|
|
872
885
|
...props
|
|
@@ -1893,7 +1906,7 @@ var DialogContentPrimitive = React17.forwardRef((props, ref) => {
|
|
|
1893
1906
|
);
|
|
1894
1907
|
});
|
|
1895
1908
|
DialogContentPrimitive.displayName = "DialogContentPrimitive";
|
|
1896
|
-
var DIALOG_DESKTOP_CLASSES2 = `matrx-dialog-card fixed left-[50%] top-[50%] z-[10000] grid min-w-0 w-full max-w-lg ${CENTERED_DIALOG} gap-4 max-h-[85dvh] overflow-y-auto overscroll-contain [--dialog-pad:1.5rem] overflow-x-clip border bg-background p-6 shadow-lg [overflow-wrap:anywhere] [&>*]:min-w-0 [&>*]:max-w-full sm:rounded-lg`;
|
|
1909
|
+
var DIALOG_DESKTOP_CLASSES2 = `matrx-dialog-card fixed left-[50%] top-[50%] z-[10000] grid min-w-0 w-full max-w-lg ${CENTERED_DIALOG} gap-4 max-h-[85dvh] overflow-y-auto overscroll-contain [--dialog-pad:1.5rem] [--dialog-pad-bottom:1.5rem] overflow-x-clip border bg-background p-6 shadow-lg [overflow-wrap:anywhere] [&>*]:min-w-0 [&>*]:max-w-full sm:rounded-lg`;
|
|
1897
1910
|
var DIALOG_MOBILE_SHEET_CLASSES2 = "matrx-mobile-sheet matrx-dialog-card fixed inset-x-0 bottom-0 left-0 right-0 top-auto z-[10000] flex min-w-0 flex-col w-full max-w-full max-h-[90dvh] translate-x-0 translate-y-0 gap-4 [--dialog-pad:1rem] overflow-x-clip border-t bg-background p-4 pb-safe shadow-lg [overflow-wrap:anywhere] [&>*]:min-w-0 [&>*]:max-w-full rounded-t-2xl rounded-b-none overflow-y-auto overscroll-contain";
|
|
1898
1911
|
var DIALOG_MOBILE_SHEET_OVERRIDE2 = "inset-x-0 bottom-0 left-0 right-0 top-auto translate-x-0 translate-y-0 w-full max-w-full max-h-[90dvh] rounded-b-none rounded-t-2xl overflow-y-auto";
|
|
1899
1912
|
var DialogContent = React17.forwardRef(
|
|
@@ -1998,12 +2011,26 @@ var DialogFooter = ({
|
|
|
1998
2011
|
"data-slot": "dialog-footer",
|
|
1999
2012
|
className: cn(
|
|
2000
2013
|
"flex flex-col-reverse sm:flex-row sm:justify-end sm:space-x-2",
|
|
2001
|
-
// Ruling 3 — the
|
|
2002
|
-
//
|
|
2003
|
-
//
|
|
2004
|
-
//
|
|
2005
|
-
// (0.11.3). The
|
|
2006
|
-
|
|
2014
|
+
// Ruling 3/4 — sticky to the card edges so a scrolled body never shows
|
|
2015
|
+
// through under the actions, and safe-area padded on a phone.
|
|
2016
|
+
//
|
|
2017
|
+
// 🚨 THERE IS NO `mb-[…]` HERE, AND THERE MUST NEVER BE ONE AGAIN
|
|
2018
|
+
// (0.11.3, feedback bf8fb00b). The bleed over the card's bottom padding
|
|
2019
|
+
// used to be a NEGATIVE BLOCK MARGIN, which makes this box taller than
|
|
2020
|
+
// the grid area the card allocates it — and `position: sticky` CLAMPS a
|
|
2021
|
+
// box to its containing block, so the browser yanked the footer UP by
|
|
2022
|
+
// `--dialog-pad` against the card's `gap-4` and painted 8px of opaque
|
|
2023
|
+
// footer over the last line of the consequence, at every length. The
|
|
2024
|
+
// card now RESERVES this footer's block size instead (`matrx-dialog-card`
|
|
2025
|
+
// in styles.css hands over its `padding-bottom`), so the bleed costs no
|
|
2026
|
+
// margin at all. Guard: `sticky-footer-geometry.test.tsx`.
|
|
2027
|
+
//
|
|
2028
|
+
// These stay UTILITIES rather than a shipped rule so a caller's
|
|
2029
|
+
// `className` still wins through tailwind-merge — a shipped rule would
|
|
2030
|
+
// have to be unlayered to survive Tailwind preflight (§ THE PREFLIGHT
|
|
2031
|
+
// RULE in styles.css) and would then override every caller's padding.
|
|
2032
|
+
"sticky bottom-0 z-10 bg-background pt-3",
|
|
2033
|
+
"mx-[calc(var(--dialog-pad,0px)*-1)] px-[var(--dialog-pad,0px)] pb-[var(--dialog-pad-bottom,0px)]",
|
|
2007
2034
|
className
|
|
2008
2035
|
),
|
|
2009
2036
|
...props
|