@lax-wp/design-system 0.2.9 → 0.2.12
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/components/data-display/modal/Modal.d.ts +5 -17
- package/dist/index.d.ts +1 -1
- package/dist/index.es.js +537 -577
- package/dist/index.umd.js +63 -63
- package/package.json +1 -1
|
@@ -1,13 +1,9 @@
|
|
|
1
1
|
import { type ModalProps as AntDModalProps } from "antd";
|
|
2
2
|
import type { ReactNode } from "react";
|
|
3
3
|
/**
|
|
4
|
-
* Modal
|
|
4
|
+
* Custom props extending Ant Design Modal props
|
|
5
5
|
*/
|
|
6
|
-
export
|
|
7
|
-
/**
|
|
8
|
-
* Props for the Modal component
|
|
9
|
-
*/
|
|
10
|
-
export interface ModalProps extends Omit<AntDModalProps, "title" | "footer"> {
|
|
6
|
+
export interface ModalProps extends AntDModalProps {
|
|
11
7
|
/** Whether to show only the body content without header */
|
|
12
8
|
onlyBody?: boolean;
|
|
13
9
|
/** Whether to add spacing to the body */
|
|
@@ -30,24 +26,16 @@ export interface ModalProps extends Omit<AntDModalProps, "title" | "footer"> {
|
|
|
30
26
|
noPadding?: boolean;
|
|
31
27
|
/** Close handler */
|
|
32
28
|
onClose?: () => void;
|
|
33
|
-
/** Modal title - can be string or ReactNode */
|
|
34
|
-
title?: string | ReactNode;
|
|
35
|
-
/** Footer content */
|
|
36
|
-
footer?: ReactNode;
|
|
37
|
-
/** Modal size */
|
|
38
|
-
size?: ModalSize;
|
|
39
29
|
}
|
|
40
30
|
/**
|
|
41
31
|
* Modal component for displaying overlay content
|
|
42
32
|
*
|
|
43
33
|
* @example
|
|
44
34
|
* ```tsx
|
|
45
|
-
* <Modal open={isOpen}
|
|
35
|
+
* <Modal open={isOpen} onCancel={() => setIsOpen(false)} title="Example Modal">
|
|
46
36
|
* <p>Modal content goes here</p>
|
|
47
37
|
* </Modal>
|
|
48
38
|
* ```
|
|
49
39
|
*/
|
|
50
|
-
export declare const Modal:
|
|
51
|
-
|
|
52
|
-
displayName: string;
|
|
53
|
-
};
|
|
40
|
+
export declare const Modal: (props: ModalProps) => import("react").ReactPortal;
|
|
41
|
+
export default Modal;
|
package/dist/index.d.ts
CHANGED
|
@@ -29,7 +29,7 @@ export type { StatusColorMappingProps, StatusColor, } from "./components/data-di
|
|
|
29
29
|
export { Badge } from "./components/data-display/badge/Badge";
|
|
30
30
|
export type { BadgeProps, BadgeStatus, BadgeAppearance, BadgeSize, } from "./components/data-display/badge/Badge";
|
|
31
31
|
export { Modal } from "./components/data-display/modal/Modal";
|
|
32
|
-
export type { ModalProps,
|
|
32
|
+
export type { ModalProps, } from "./components/data-display/modal/Modal";
|
|
33
33
|
export { Tag } from "./components/data-display/tag/Tag";
|
|
34
34
|
export type { TagProps, TagSize, TagColor, ThemeMode, UploadHandler, } from "./components/data-display/tag/Tag";
|
|
35
35
|
export { LabelValue } from "./components/data-display/label-value/LabelValue";
|