@stack-spot/portal-layout 2.33.1 → 2.34.0

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 CHANGED
@@ -1,5 +1,12 @@
1
1
  # Changelog
2
2
 
3
+ ## [2.34.0](https://github.com/stack-spot/portal-commons/compare/portal-layout@v2.33.1...portal-layout@v2.34.0) (2025-07-21)
4
+
5
+
6
+ ### Features
7
+
8
+ * 3013 csat workflow ([#1269](https://github.com/stack-spot/portal-commons/issues/1269)) ([77baca3](https://github.com/stack-spot/portal-commons/commit/77baca3c360610399795260dc3752191be0324df))
9
+
3
10
  ## [2.33.1](https://github.com/stack-spot/portal-commons/compare/portal-layout@v2.33.0...portal-layout@v2.33.1) (2025-07-16)
4
11
 
5
12
 
@@ -66,7 +66,7 @@ interface Props extends Omit<DialogOptions, 'message'> {
66
66
  /**
67
67
  * Function to run when the confirm button is clicked.
68
68
  */
69
- onConfirm: () => void;
69
+ onConfirm?: () => void;
70
70
  /**
71
71
  * Function to run when the cancel button is clicked.
72
72
  */
@@ -1 +1 @@
1
- {"version":3,"file":"Dialog.d.ts","sourceRoot":"","sources":["../../src/components/Dialog.tsx"],"names":[],"mappings":"AACA,OAAO,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAA;AAE1D,OAAO,EAAE,SAAS,EAAY,MAAM,OAAO,CAAA;AAI3C,UAAU,UAAU;IAClB;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAC3B;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB;AAED,MAAM,WAAW,aAAa;IAC5B;;OAEG;IACH,KAAK,EAAE,MAAM,CAAC;IACd;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB;;OAEG;IACH,QAAQ,CAAC,EAAE,MAAM,IAAI,CAAC;IACtB;;OAEG;IACH,QAAQ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E,MAAM,CAAC;IACjB;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;;;;;OAKG;IACH,UAAU,CAAC,EAAE,KAAK,GAAG,MAAM,GAAG,UAAU,CAAC;IACzC;;;OAGG;IACH,IAAI,CAAC,EAAE,OAAO,GAAG,OAAO,CAAC;IACzB;;;OAGG;IACH,eAAe,CAAC,EAAE,MAAM,GAAG,QAAQ,GAAG,OAAO,GAAG,SAAS,CAAC;IAC1D;;;OAGG;IACH,WAAW,CAAC,EAAE,eAAe,CAAC;CAC/B;AAED,UAAU,KAAM,SAAQ,IAAI,CAAC,aAAa,EAAE,SAAS,CAAC;IACpD;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,IAAI,CAAC;IACvB;;OAEG;IACH,QAAQ,EAAE,MAAM,IAAI,CAAC;CACtB;AASD;;;;GAIG;AACH,eAAO,MAAM,MAAM,GAAI,gIAapB,KAAK,4CAsCP,CAAA"}
@@ -1,5 +1,6 @@
1
1
  import { TypeFormProps } from './index.js';
2
- export declare const showTypeFormModal: ({ title, ...props }: TypeFormProps & {
2
+ export declare const showTypeFormModal: ({ title, onClose, ...props }: TypeFormProps & {
3
3
  title: string;
4
+ onClose?: VoidFunction;
4
5
  }) => void;
5
6
  //# sourceMappingURL=show-typeform-modal.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"show-typeform-modal.d.ts","sourceRoot":"","sources":["../../../src/components/TypeForm/show-typeform-modal.tsx"],"names":[],"mappings":"AACA,OAAO,EAAY,aAAa,EAAE,MAAM,GAAG,CAAA;AAE3C,eAAO,MAAM,iBAAiB,GAAI,qBAAqB,aAAa,GAAG;IAAE,KAAK,EAAE,MAAM,CAAA;CAAE,SAMvF,CAAA"}
1
+ {"version":3,"file":"show-typeform-modal.d.ts","sourceRoot":"","sources":["../../../src/components/TypeForm/show-typeform-modal.tsx"],"names":[],"mappings":"AAGA,OAAO,EAAY,aAAa,EAAE,MAAM,GAAG,CAAA;AAE3C,eAAO,MAAM,iBAAiB,GAAI,8BAA8B,aAAa,GAC7E;IAAE,KAAK,EAAE,MAAM,CAAC;IAAC,OAAO,CAAC,EAAE,YAAY,CAAA;CAAE,SAWxC,CAAA"}
@@ -1,11 +1,9 @@
1
1
  import { jsx as _jsx } from "react/jsx-runtime";
2
+ import { Backdrop, Flex } from '@citric/core';
2
3
  import { overlay } from '../../LayoutOverlayManager.js';
4
+ import { OverlayContent } from '../OverlayContent.js';
3
5
  import { TypeForm } from './index.js';
4
- export const showTypeFormModal = ({ title, ...props }) => {
5
- overlay.showModal({
6
- title: title,
7
- children: _jsx(TypeForm, { ...props }),
8
- size: 'large',
9
- });
6
+ export const showTypeFormModal = ({ title, onClose, ...props }) => {
7
+ overlay.showCustomModal(_jsx(Backdrop, { sx: { width: '100vw', height: '100vh' }, children: _jsx(Flex, { sx: { position: 'absolute', top: '50%', left: '50%', transform: 'translate(-50%, -50%)' }, children: _jsx(OverlayContent, { ...props, onClose: () => onClose?.(), type: "modal", title: title, children: _jsx(TypeForm, { ...props }) }) }) }), { size: 'large', onClose: onClose });
10
8
  };
11
9
  //# sourceMappingURL=show-typeform-modal.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"show-typeform-modal.js","sourceRoot":"","sources":["../../../src/components/TypeForm/show-typeform-modal.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AACpD,OAAO,EAAE,QAAQ,EAAiB,MAAM,GAAG,CAAA;AAE3C,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,EAAE,KAAK,EAAE,GAAG,KAAK,EAAqC,EAAE,EAAE;IAC1F,OAAO,CAAC,SAAS,CAAC;QAChB,KAAK,EAAE,KAAK;QACZ,QAAQ,EAAE,KAAC,QAAQ,OAAK,KAAK,GAAI;QACjC,IAAI,EAAE,OAAO;KACd,CAAC,CAAA;AACJ,CAAC,CAAA"}
1
+ {"version":3,"file":"show-typeform-modal.js","sourceRoot":"","sources":["../../../src/components/TypeForm/show-typeform-modal.tsx"],"names":[],"mappings":";AAAA,OAAO,EAAE,QAAQ,EAAE,IAAI,EAAE,MAAM,cAAc,CAAA;AAC7C,OAAO,EAAE,OAAO,EAAE,MAAM,4BAA4B,CAAA;AACpD,OAAO,EAAE,cAAc,EAAE,MAAM,mBAAmB,CAAA;AAClD,OAAO,EAAE,QAAQ,EAAiB,MAAM,GAAG,CAAA;AAE3C,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAAC,EAAE,KAAK,EAAE,OAAO,EAAE,GAAG,KAAK,EACnB,EAAE,EAAE;IAC3C,OAAO,CAAC,eAAe,CACrB,KAAC,QAAQ,IAAC,EAAE,EAAE,EAAE,KAAK,EAAE,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,YAC/C,KAAC,IAAI,IAAC,EAAE,EAAE,EAAE,QAAQ,EAAE,UAAU,EAAE,GAAG,EAAE,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,SAAS,EAAE,uBAAuB,EAAE,YAC7F,KAAC,cAAc,OAAK,KAAK,EAAE,OAAO,EAAE,GAAG,EAAE,CAAC,OAAO,EAAE,EAAE,EAAE,IAAI,EAAC,OAAO,EAAC,KAAK,EAAE,KAAK,YAC9E,KAAC,QAAQ,OAAK,KAAK,GAAI,GACR,GACZ,GACE,EACX,EAAE,IAAI,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,EAAE,CACpC,CAAA;AACH,CAAC,CAAA"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@stack-spot/portal-layout",
3
- "version": "2.33.1",
3
+ "version": "2.34.0",
4
4
  "type": "module",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
@@ -73,7 +73,7 @@ interface Props extends Omit<DialogOptions, 'message'> {
73
73
  /**
74
74
  * Function to run when the confirm button is clicked.
75
75
  */
76
- onConfirm: () => void,
76
+ onConfirm?: () => void,
77
77
  /**
78
78
  * Function to run when the cancel button is clicked.
79
79
  */
@@ -1,10 +1,18 @@
1
+ import { Backdrop, Flex } from '@citric/core'
1
2
  import { overlay } from '../../LayoutOverlayManager'
3
+ import { OverlayContent } from '../OverlayContent'
2
4
  import { TypeForm, TypeFormProps } from '.'
3
5
 
4
- export const showTypeFormModal = ({ title, ...props }: TypeFormProps & { title: string }) => {
5
- overlay.showModal({
6
- title: title,
7
- children: <TypeForm {...props} />,
8
- size: 'large',
9
- })
6
+ export const showTypeFormModal = ({ title, onClose, ...props }: TypeFormProps &
7
+ { title: string, onClose?: VoidFunction }) => {
8
+ overlay.showCustomModal(
9
+ <Backdrop sx={{ width: '100vw', height: '100vh' }}>
10
+ <Flex sx={{ position: 'absolute', top: '50%', left: '50%', transform: 'translate(-50%, -50%)' }}>
11
+ <OverlayContent {...props} onClose={() => onClose?.()} type="modal" title={title}>
12
+ <TypeForm {...props} />
13
+ </OverlayContent>
14
+ </Flex>
15
+ </Backdrop>,
16
+ { size: 'large', onClose: onClose },
17
+ )
10
18
  }