@ai-matrx/design-system 0.38.0 → 0.38.1

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.
@@ -1613,13 +1613,14 @@ function useIsMobile() {
1613
1613
 
1614
1614
  // src/dialog.tsx
1615
1615
  var import_jsx_runtime15 = require("react/jsx-runtime");
1616
+ var DialogWindowedByDefaultContext = React10.createContext(false);
1616
1617
  var Dialog = ({
1617
1618
  children,
1618
1619
  ...props
1619
1620
  }) => {
1620
1621
  const isMobile = useIsMobile();
1621
1622
  const modal = props.modal ?? isMobile;
1622
- return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(RadixDialogModalProvider, { modal, children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(DialogPrimitive.Root, { ...props, modal, children }) });
1623
+ return /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(DialogWindowedByDefaultContext.Provider, { value: props.modal === void 0, children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(RadixDialogModalProvider, { modal, children: /* @__PURE__ */ (0, import_jsx_runtime15.jsx)(DialogPrimitive.Root, { ...props, modal, children }) }) });
1623
1624
  };
1624
1625
  Dialog.displayName = "Dialog";
1625
1626
  var DialogPortal = ({
@@ -1688,6 +1689,7 @@ var DialogContent = React10.forwardRef(
1688
1689
  const injectedContainer = usePortalContainer(container);
1689
1690
  const asSheet = mobileSheet && isMobile;
1690
1691
  const windowed = !isModal && !asSheet;
1692
+ const windowedByDefault = React10.useContext(DialogWindowedByDefaultContext);
1691
1693
  const [containerEl, setContainerEl] = React10.useState(
1692
1694
  null
1693
1695
  );
@@ -1748,7 +1750,7 @@ var DialogContent = React10.forwardRef(
1748
1750
  // can sit beside a host's floating window manager (which starts at
1749
1751
  // z=1000); staying below that boundary makes a newly focused window
1750
1752
  // usable without coupling the two systems.
1751
- !isModal && "z-[900]",
1753
+ !isModal && !windowedByDefault && "z-[900]",
1752
1754
  // Without an overlay the card needs its own separation from the page.
1753
1755
  windowed && "shadow-2xl ring-1 ring-border/60"
1754
1756
  ),