@bluemarble/bm-components 2.4.5 → 2.4.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/index.d.cts CHANGED
@@ -451,7 +451,8 @@ interface IBaseDialogInstanceProviderProps {
451
451
  name: symbol;
452
452
  }
453
453
 
454
- interface IBaseDialogContainerProps extends Omit<TModalProps, 'children' | 'open' | 'onClose'> {
454
+ interface IBaseDialogContainerProps {
455
+ BoxProps?: BoxProps;
455
456
  children: React__default.ReactNode | ((props: {
456
457
  close: () => void;
457
458
  }) => React__default.ReactNode);
package/dist/index.d.ts CHANGED
@@ -451,7 +451,8 @@ interface IBaseDialogInstanceProviderProps {
451
451
  name: symbol;
452
452
  }
453
453
 
454
- interface IBaseDialogContainerProps extends Omit<TModalProps, 'children' | 'open' | 'onClose'> {
454
+ interface IBaseDialogContainerProps {
455
+ BoxProps?: BoxProps;
455
456
  children: React__default.ReactNode | ((props: {
456
457
  close: () => void;
457
458
  }) => React__default.ReactNode);
package/dist/index.js CHANGED
@@ -4500,7 +4500,7 @@ function useBaseDialogInstance() {
4500
4500
  }
4501
4501
 
4502
4502
  // src/components/BaseDialog/BaseDialog.tsx
4503
- import { Box as Box8, Button as Button4 } from "@mui/material";
4503
+ import { Box as Box8, Button as Button4, Modal as Modal2 } from "@mui/material";
4504
4504
 
4505
4505
  // src/components/BaseDialog/BaseDialogHeader.tsx
4506
4506
  import React28 from "react";
@@ -4545,7 +4545,23 @@ var BaseDialogContainer = ({
4545
4545
  }) => {
4546
4546
  const { name } = useBaseDialogInstance();
4547
4547
  const { isOpened, close: closeDialog } = useBaseDialog();
4548
- return /* @__PURE__ */ React29.createElement(Modal, { open: isOpened(name), onClose: () => closeDialog(name), ...rest }, children instanceof Function ? children({ close: () => closeDialog(name) }) : children);
4548
+ return /* @__PURE__ */ React29.createElement(Modal2, { open: isOpened(name), onClose: () => closeDialog(name), ...rest }, /* @__PURE__ */ React29.createElement(
4549
+ Box8,
4550
+ {
4551
+ ...rest?.BoxProps,
4552
+ sx: {
4553
+ outline: "none",
4554
+ backgroundColor: "background.paper",
4555
+ position: "absolute",
4556
+ top: "50%",
4557
+ left: "50%",
4558
+ transform: "translate(-50%, -50%)",
4559
+ borderRadius: 1,
4560
+ ...rest?.BoxProps?.sx
4561
+ }
4562
+ },
4563
+ children
4564
+ ));
4549
4565
  };
4550
4566
  var BaseDialogBody = (props) => {
4551
4567
  return /* @__PURE__ */ React29.createElement(Box8, { px: 2, pb: 2, width: "100vw", maxWidth: 650, ...props }, props.children);