@cerberus-design/react 0.13.1-next-b2ca1e0 → 0.13.1-next-8e40fb6

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.
Files changed (34) hide show
  1. package/build/legacy/_tsup-dts-rollup.d.cts +3 -13
  2. package/build/legacy/components/Portal.cjs +2 -6
  3. package/build/legacy/components/Portal.cjs.map +1 -1
  4. package/build/legacy/context/confirm-modal.cjs +22 -25
  5. package/build/legacy/context/confirm-modal.cjs.map +1 -1
  6. package/build/legacy/context/cta-modal.cjs +20 -23
  7. package/build/legacy/context/cta-modal.cjs.map +1 -1
  8. package/build/legacy/context/notification-center.cjs +10 -13
  9. package/build/legacy/context/notification-center.cjs.map +1 -1
  10. package/build/legacy/context/prompt-modal.cjs +29 -32
  11. package/build/legacy/context/prompt-modal.cjs.map +1 -1
  12. package/build/legacy/index.cjs +87 -90
  13. package/build/legacy/index.cjs.map +1 -1
  14. package/build/modern/_tsup-dts-rollup.d.ts +3 -13
  15. package/build/modern/{chunk-B3LRHIEG.js → chunk-3XGLNXJJ.js} +2 -2
  16. package/build/modern/{chunk-S6JWPDB4.js → chunk-FBSESDWJ.js} +2 -2
  17. package/build/modern/{chunk-FHS7VVGN.js → chunk-GRUXP3NG.js} +2 -2
  18. package/build/modern/chunk-IQJDVFPP.js +10 -0
  19. package/build/modern/chunk-IQJDVFPP.js.map +1 -0
  20. package/build/modern/{chunk-SRPSJGNI.js → chunk-WFJWCZ7E.js} +2 -2
  21. package/build/modern/components/Portal.js +1 -2
  22. package/build/modern/context/confirm-modal.js +2 -2
  23. package/build/modern/context/cta-modal.js +2 -2
  24. package/build/modern/context/notification-center.js +2 -2
  25. package/build/modern/context/prompt-modal.js +2 -2
  26. package/build/modern/index.js +5 -5
  27. package/package.json +2 -2
  28. package/src/components/Portal.tsx +6 -19
  29. package/build/modern/chunk-K2PSHGS7.js +0 -11
  30. package/build/modern/chunk-K2PSHGS7.js.map +0 -1
  31. /package/build/modern/{chunk-B3LRHIEG.js.map → chunk-3XGLNXJJ.js.map} +0 -0
  32. /package/build/modern/{chunk-S6JWPDB4.js.map → chunk-FBSESDWJ.js.map} +0 -0
  33. /package/build/modern/{chunk-FHS7VVGN.js.map → chunk-GRUXP3NG.js.map} +0 -0
  34. /package/build/modern/{chunk-SRPSJGNI.js.map → chunk-WFJWCZ7E.js.map} +0 -0
@@ -99,12 +99,12 @@ import { PointerSensor } from '@dnd-kit/core';
99
99
  import { PointerSensorOptions } from '@dnd-kit/core';
100
100
  import { PointerSensorProps } from '@dnd-kit/core';
101
101
  import { pointerWithin } from '@dnd-kit/core';
102
+ import { PortalProps as PortalProps_2 } from '@ark-ui/react';
102
103
  import type { Pretty } from '@cerberus/styled-system/types';
103
104
  import { ProgressBarVariantProps } from '@cerberus/styled-system/recipes';
104
105
  import { PropsWithChildren } from 'react';
105
106
  import { radio } from '@cerberus/styled-system/recipes';
106
107
  import { ReactNode } from 'react';
107
- import { ReactPortal } from 'react';
108
108
  import type { RecipeVariantProps } from '@cerberus/styled-system/types';
109
109
  import { rectIntersection } from '@dnd-kit/core';
110
110
  import { RefAttributes } from 'react';
@@ -1920,7 +1920,7 @@ export { pointerWithin }
1920
1920
  * )
1921
1921
  * }
1922
1922
  */
1923
- declare function Portal(props: PropsWithChildren<PortalProps>): ReactPortal;
1923
+ declare const Portal: (props: PropsWithChildren<PortalProps_2>) => JSX_2.Element;
1924
1924
  export { Portal }
1925
1925
  export { Portal as Portal_alias_1 }
1926
1926
 
@@ -1928,17 +1928,7 @@ export { Portal as Portal_alias_1 }
1928
1928
  * This module is the Portal component.
1929
1929
  * @module
1930
1930
  */
1931
- declare interface PortalProps {
1932
- /**
1933
- * The root container to render the children into.
1934
- * @default document.body
1935
- */
1936
- container?: Element | DocumentFragment;
1937
- /**
1938
- * An optional key to use for the Portal component.
1939
- */
1940
- key?: null | string;
1941
- }
1931
+ declare type PortalProps = PortalProps_2;
1942
1932
  export { PortalProps }
1943
1933
  export { PortalProps as PortalProps_alias_1 }
1944
1934
 
@@ -3,7 +3,7 @@ import {
3
3
  } from "./chunk-SXIXDXG3.js";
4
4
  import {
5
5
  Portal
6
- } from "./chunk-K2PSHGS7.js";
6
+ } from "./chunk-IQJDVFPP.js";
7
7
  import {
8
8
  Notification
9
9
  } from "./chunk-7SGPJM66.js";
@@ -159,4 +159,4 @@ export {
159
159
  NotificationCenter,
160
160
  useNotificationCenter
161
161
  };
162
- //# sourceMappingURL=chunk-B3LRHIEG.js.map
162
+ //# sourceMappingURL=chunk-3XGLNXJJ.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  Portal
3
- } from "./chunk-K2PSHGS7.js";
3
+ } from "./chunk-IQJDVFPP.js";
4
4
  import {
5
5
  ModalDescription
6
6
  } from "./chunk-Q7BRMIBR.js";
@@ -240,4 +240,4 @@ export {
240
240
  PromptModal,
241
241
  usePromptModal
242
242
  };
243
- //# sourceMappingURL=chunk-S6JWPDB4.js.map
243
+ //# sourceMappingURL=chunk-FBSESDWJ.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  Portal
3
- } from "./chunk-K2PSHGS7.js";
3
+ } from "./chunk-IQJDVFPP.js";
4
4
  import {
5
5
  ModalDescription
6
6
  } from "./chunk-Q7BRMIBR.js";
@@ -170,4 +170,4 @@ export {
170
170
  ConfirmModal,
171
171
  useConfirmModal
172
172
  };
173
- //# sourceMappingURL=chunk-FHS7VVGN.js.map
173
+ //# sourceMappingURL=chunk-GRUXP3NG.js.map
@@ -0,0 +1,10 @@
1
+ // src/components/Portal.tsx
2
+ import {
3
+ Portal as ArkPortal
4
+ } from "@ark-ui/react";
5
+ var Portal = ArkPortal;
6
+
7
+ export {
8
+ Portal
9
+ };
10
+ //# sourceMappingURL=chunk-IQJDVFPP.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"sources":["../../src/components/Portal.tsx"],"sourcesContent":["import {\n Portal as ArkPortal,\n type PortalProps as ArkPortalProps,\n} from '@ark-ui/react'\n\n/**\n * This module is the Portal component.\n * @module\n */\n\nexport type PortalProps = ArkPortalProps\n\n/**\n * The Portal component is used to render children into a DOM node that exists outside the DOM hierarchy of the parent component.\n * @see https://cerberus.digitalu.design/react/portal\n * @definition [React Portal Docs](https://react.dev/reference/react-dom/createPortal)\n * @example\n * ```tsx\n * 'use client'\n *\n * import { Portal } from '@cerberus/react'\n *\n * function SomeFeatureWithinSSRPage() {\n * return (\n * <Portal>\n * <div>Portal Content outside of the React VDom tree</div>\n * </Portal>\n * )\n * }\n */\nexport const Portal = ArkPortal\n"],"mappings":";AAAA;AAAA,EACE,UAAU;AAAA,OAEL;AA2BA,IAAM,SAAS;","names":[]}
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  Portal
3
- } from "./chunk-K2PSHGS7.js";
3
+ } from "./chunk-IQJDVFPP.js";
4
4
  import {
5
5
  ModalDescription
6
6
  } from "./chunk-Q7BRMIBR.js";
@@ -152,4 +152,4 @@ export {
152
152
  CTAModal,
153
153
  useCTAModal
154
154
  };
155
- //# sourceMappingURL=chunk-SRPSJGNI.js.map
155
+ //# sourceMappingURL=chunk-WFJWCZ7E.js.map
@@ -1,7 +1,6 @@
1
- "use client";
2
1
  import {
3
2
  Portal
4
- } from "../chunk-K2PSHGS7.js";
3
+ } from "../chunk-IQJDVFPP.js";
5
4
  export {
6
5
  Portal
7
6
  };
@@ -2,8 +2,8 @@
2
2
  import {
3
3
  ConfirmModal,
4
4
  useConfirmModal
5
- } from "../chunk-FHS7VVGN.js";
6
- import "../chunk-K2PSHGS7.js";
5
+ } from "../chunk-GRUXP3NG.js";
6
+ import "../chunk-IQJDVFPP.js";
7
7
  import "../chunk-Q7BRMIBR.js";
8
8
  import "../chunk-XY6WL55R.js";
9
9
  import "../chunk-2UXE5PDG.js";
@@ -2,8 +2,8 @@
2
2
  import {
3
3
  CTAModal,
4
4
  useCTAModal
5
- } from "../chunk-SRPSJGNI.js";
6
- import "../chunk-K2PSHGS7.js";
5
+ } from "../chunk-WFJWCZ7E.js";
6
+ import "../chunk-IQJDVFPP.js";
7
7
  import "../chunk-Q7BRMIBR.js";
8
8
  import "../chunk-XY6WL55R.js";
9
9
  import "../chunk-2UXE5PDG.js";
@@ -2,9 +2,9 @@
2
2
  import {
3
3
  NotificationCenter,
4
4
  useNotificationCenter
5
- } from "../chunk-B3LRHIEG.js";
5
+ } from "../chunk-3XGLNXJJ.js";
6
6
  import "../chunk-SXIXDXG3.js";
7
- import "../chunk-K2PSHGS7.js";
7
+ import "../chunk-IQJDVFPP.js";
8
8
  import "../chunk-7SGPJM66.js";
9
9
  import "../chunk-XEW6TJJ4.js";
10
10
  import "../chunk-EXGKZGML.js";
@@ -2,8 +2,8 @@
2
2
  import {
3
3
  PromptModal,
4
4
  usePromptModal
5
- } from "../chunk-S6JWPDB4.js";
6
- import "../chunk-K2PSHGS7.js";
5
+ } from "../chunk-FBSESDWJ.js";
6
+ import "../chunk-IQJDVFPP.js";
7
7
  import "../chunk-Q7BRMIBR.js";
8
8
  import "../chunk-XY6WL55R.js";
9
9
  import "../chunk-2UXE5PDG.js";
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  NotificationCenter,
3
3
  useNotificationCenter
4
- } from "./chunk-B3LRHIEG.js";
4
+ } from "./chunk-3XGLNXJJ.js";
5
5
  import {
6
6
  PromptModal,
7
7
  usePromptModal
8
- } from "./chunk-S6JWPDB4.js";
8
+ } from "./chunk-FBSESDWJ.js";
9
9
  import {
10
10
  ThemeProvider,
11
11
  useThemeContext
@@ -22,11 +22,11 @@ import {
22
22
  import {
23
23
  ConfirmModal,
24
24
  useConfirmModal
25
- } from "./chunk-FHS7VVGN.js";
25
+ } from "./chunk-GRUXP3NG.js";
26
26
  import {
27
27
  CTAModal,
28
28
  useCTAModal
29
- } from "./chunk-SRPSJGNI.js";
29
+ } from "./chunk-WFJWCZ7E.js";
30
30
  import {
31
31
  TabList
32
32
  } from "./chunk-UKPF7JOB.js";
@@ -57,7 +57,7 @@ import {
57
57
  } from "./chunk-SXIXDXG3.js";
58
58
  import {
59
59
  Portal
60
- } from "./chunk-K2PSHGS7.js";
60
+ } from "./chunk-IQJDVFPP.js";
61
61
  import {
62
62
  Radio
63
63
  } from "./chunk-FTPZHG6J.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cerberus-design/react",
3
- "version": "0.13.1-next-b2ca1e0",
3
+ "version": "0.13.1-next-8e40fb6",
4
4
  "description": "The Cerberus Design React component library.",
5
5
  "browserslist": "> 0.25%, not dead",
6
6
  "sideEffects": false,
@@ -27,7 +27,7 @@
27
27
  "react-dom": "^18",
28
28
  "tsup": "^8.1.0",
29
29
  "@cerberus-design/configs": "0.0.0",
30
- "@cerberus-design/styled-system": "0.13.1-next-b2ca1e0"
30
+ "@cerberus-design/styled-system": "0.13.1-next-8e40fb6"
31
31
  },
32
32
  "publishConfig": {
33
33
  "access": "public"
@@ -1,24 +1,14 @@
1
- 'use client'
2
-
3
- import type { PropsWithChildren } from 'react'
4
- import { createPortal } from 'react-dom'
1
+ import {
2
+ Portal as ArkPortal,
3
+ type PortalProps as ArkPortalProps,
4
+ } from '@ark-ui/react'
5
5
 
6
6
  /**
7
7
  * This module is the Portal component.
8
8
  * @module
9
9
  */
10
10
 
11
- export interface PortalProps {
12
- /**
13
- * The root container to render the children into.
14
- * @default document.body
15
- */
16
- container?: Element | DocumentFragment
17
- /**
18
- * An optional key to use for the Portal component.
19
- */
20
- key?: null | string
21
- }
11
+ export type PortalProps = ArkPortalProps
22
12
 
23
13
  /**
24
14
  * The Portal component is used to render children into a DOM node that exists outside the DOM hierarchy of the parent component.
@@ -38,7 +28,4 @@ export interface PortalProps {
38
28
  * )
39
29
  * }
40
30
  */
41
- export function Portal(props: PropsWithChildren<PortalProps>) {
42
- const container = props.container || document.body
43
- return createPortal(props.children, container, props.key)
44
- }
31
+ export const Portal = ArkPortal
@@ -1,11 +0,0 @@
1
- // src/components/Portal.tsx
2
- import { createPortal } from "react-dom";
3
- function Portal(props) {
4
- const container = props.container || document.body;
5
- return createPortal(props.children, container, props.key);
6
- }
7
-
8
- export {
9
- Portal
10
- };
11
- //# sourceMappingURL=chunk-K2PSHGS7.js.map
@@ -1 +0,0 @@
1
- {"version":3,"sources":["../../src/components/Portal.tsx"],"sourcesContent":["'use client'\n\nimport type { PropsWithChildren } from 'react'\nimport { createPortal } from 'react-dom'\n\n/**\n * This module is the Portal component.\n * @module\n */\n\nexport interface PortalProps {\n /**\n * The root container to render the children into.\n * @default document.body\n */\n container?: Element | DocumentFragment\n /**\n * An optional key to use for the Portal component.\n */\n key?: null | string\n}\n\n/**\n * The Portal component is used to render children into a DOM node that exists outside the DOM hierarchy of the parent component.\n * @see https://cerberus.digitalu.design/react/portal\n * @definition [React Portal Docs](https://react.dev/reference/react-dom/createPortal)\n * @example\n * ```tsx\n * 'use client'\n *\n * import { Portal } from '@cerberus/react'\n *\n * function SomeFeatureWithinSSRPage() {\n * return (\n * <Portal>\n * <div>Portal Content outside of the React VDom tree</div>\n * </Portal>\n * )\n * }\n */\nexport function Portal(props: PropsWithChildren<PortalProps>) {\n const container = props.container || document.body\n return createPortal(props.children, container, props.key)\n}\n"],"mappings":";AAGA,SAAS,oBAAoB;AAqCtB,SAAS,OAAO,OAAuC;AAC5D,QAAM,YAAY,MAAM,aAAa,SAAS;AAC9C,SAAO,aAAa,MAAM,UAAU,WAAW,MAAM,GAAG;AAC1D;","names":[]}