@cuemath/leap 3.2.2-aa13 → 3.2.2-aa6

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.
@@ -1,18 +1,18 @@
1
1
  import { jsxs as r, jsx as o } from "react/jsx-runtime";
2
- import { memo as c, Suspense as t } from "react";
3
- import f from "../../../assets/line-icons/icons/cross.js";
2
+ import { memo as h, Suspense as m } from "react";
3
+ import c from "../../../assets/line-icons/icons/cross.js";
4
4
  import p from "../buttons/clickable/clickable.js";
5
- import n from "../loader/app-loader/app-loader.js";
6
- import { ModalContainer as a, SpotlightModal as C, BaseModal as $, CloseButtonContainer as g, BaseModalContent as b } from "./modal-styled.js";
7
- const j = c(({ modal: d, isClosing: e = !1, onClose: s }) => {
8
- const { renderAs: h, element: i, modalWidth: l, isDismissable: m } = d;
9
- return h === "spotlight" ? /* @__PURE__ */ r(a, { $isClosing: e, children: [
5
+ import f from "../loader/app-loader/app-loader.js";
6
+ import { ModalContainer as t, SpotlightModal as C, BaseModal as $, CloseButtonContainer as g, BaseModalContent as u } from "./modal-styled.js";
7
+ const j = h(({ modal: n, isClosing: e = !1, onClose: s }) => {
8
+ const { renderAs: d, element: l, modalWidth: i, isDismissable: a } = n;
9
+ return d === "spotlight" ? /* @__PURE__ */ r(t, { $isClosing: e, children: [
10
10
  /* @__PURE__ */ o(C, { $isClosing: e }),
11
- /* @__PURE__ */ o(t, { fallback: /* @__PURE__ */ o(n, { height: "100vh" }), children: i })
12
- ] }) : /* @__PURE__ */ o(a, { $isClosing: e, children: /* @__PURE__ */ r($, { $isClosing: e, $width: l, children: [
13
- m !== !1 && /* @__PURE__ */ o(g, { $modalWidth: l, children: /* @__PURE__ */ o(p, { label: "Close", onClick: s, children: /* @__PURE__ */ o(f, { width: 40, height: 40 }) }) }),
14
- /* @__PURE__ */ o(b, { $modalWidth: l, children: /* @__PURE__ */ o(t, { fallback: /* @__PURE__ */ o(n, { height: "100vh" }), children: i }) })
15
- ] }) });
11
+ l
12
+ ] }) : /* @__PURE__ */ o(m, { fallback: /* @__PURE__ */ o(f, { height: "100vh" }), children: /* @__PURE__ */ o(t, { $isClosing: e, children: /* @__PURE__ */ r($, { $isClosing: e, $width: i, children: [
13
+ a !== !1 && /* @__PURE__ */ o(g, { $modalWidth: i, children: /* @__PURE__ */ o(p, { label: "Close", onClick: s, children: /* @__PURE__ */ o(c, { width: 40, height: 40 }) }) }),
14
+ /* @__PURE__ */ o(u, { $modalWidth: i, children: l })
15
+ ] }) }) });
16
16
  });
17
17
  export {
18
18
  j as default
@@ -1 +1 @@
1
- {"version":3,"file":"modal.js","sources":["../../../../src/features/ui/modals/modal.tsx"],"sourcesContent":["import type { IModalProps } from './modal-types';\nimport type { FC } from 'react';\n\nimport { memo, Suspense } from 'react';\n\nimport CrossIcon from '../../../assets/line-icons/icons/cross';\nimport Clickable from '../buttons/clickable/clickable';\nimport AppLoader from '../loader/app-loader/app-loader';\nimport * as Styled from './modal-styled';\n\n/**\n * Modal component that renders modal content with close button\n * Handles animation state for entry and exit transitions\n */\nconst Modal: FC<IModalProps> = memo(({ modal, isClosing = false, onClose }) => {\n const { renderAs, element, modalWidth, isDismissable } = modal;\n\n if (renderAs === 'spotlight') {\n return (\n <Styled.ModalContainer $isClosing={isClosing}>\n <Styled.SpotlightModal $isClosing={isClosing} />\n <Suspense fallback={<AppLoader height=\"100vh\" />}>{element}</Suspense>\n </Styled.ModalContainer>\n );\n }\n\n return (\n <Styled.ModalContainer $isClosing={isClosing}>\n <Styled.BaseModal $isClosing={isClosing} $width={modalWidth}>\n {isDismissable !== false && (\n <Styled.CloseButtonContainer $modalWidth={modalWidth}>\n <Clickable label=\"Close\" onClick={onClose}>\n <CrossIcon width={40} height={40} />\n </Clickable>\n </Styled.CloseButtonContainer>\n )}\n <Styled.BaseModalContent $modalWidth={modalWidth}>\n <Suspense fallback={<AppLoader height=\"100vh\" />}>{element}</Suspense>\n </Styled.BaseModalContent>\n </Styled.BaseModal>\n </Styled.ModalContainer>\n );\n});\n\nexport default Modal;\n"],"names":["Modal","memo","modal","isClosing","onClose","renderAs","element","modalWidth","isDismissable","jsxs","Styled.ModalContainer","jsx","Styled.SpotlightModal","Suspense","AppLoader","Styled.BaseModal","Styled.CloseButtonContainer","Clickable","CrossIcon","Styled.BaseModalContent"],"mappings":";;;;;;AAcM,MAAAA,IAAyBC,EAAK,CAAC,EAAE,OAAAC,GAAO,WAAAC,IAAY,IAAO,SAAAC,QAAc;AAC7E,QAAM,EAAE,UAAAC,GAAU,SAAAC,GAAS,YAAAC,GAAY,eAAAC,MAAkBN;AAEzD,SAAIG,MAAa,cAEZ,gBAAAI,EAAAC,GAAA,EAAsB,YAAYP,GACjC,UAAA;AAAA,IAAA,gBAAAQ,EAACC,GAAA,EAAsB,YAAYT,EAAW,CAAA;AAAA,IAC9C,gBAAAQ,EAACE,KAAS,UAAU,gBAAAF,EAACG,KAAU,QAAO,QAAQ,CAAA,GAAK,UAAQR,EAAA,CAAA;AAAA,EAC7D,EAAA,CAAA,IAKD,gBAAAK,EAAAD,GAAA,EAAsB,YAAYP,GACjC,UAAC,gBAAAM,EAAAM,GAAA,EAAiB,YAAYZ,GAAW,QAAQI,GAC9C,UAAA;AAAA,IAAkBC,MAAA,wBAChBQ,GAAA,EAA4B,aAAaT,GACxC,4BAACU,GAAU,EAAA,OAAM,SAAQ,SAASb,GAChC,4BAACc,GAAU,EAAA,OAAO,IAAI,QAAQ,IAAI,GACpC,EACF,CAAA;AAAA,IAED,gBAAAP,EAAAQ,GAAA,EAAwB,aAAaZ,GACpC,UAAA,gBAAAI,EAACE,GAAS,EAAA,4BAAWC,GAAU,EAAA,QAAO,QAAQ,CAAA,GAAK,YAAQ,CAAA,GAC7D;AAAA,EAAA,EACF,CAAA,EACF,CAAA;AAEJ,CAAC;"}
1
+ {"version":3,"file":"modal.js","sources":["../../../../src/features/ui/modals/modal.tsx"],"sourcesContent":["import type { IModalProps } from './modal-types';\nimport type { FC } from 'react';\n\nimport { memo, Suspense } from 'react';\n\nimport CrossIcon from '../../../assets/line-icons/icons/cross';\nimport Clickable from '../buttons/clickable/clickable';\nimport AppLoader from '../loader/app-loader/app-loader';\nimport * as Styled from './modal-styled';\n\n/**\n * Modal component that renders modal content with close button\n * Handles animation state for entry and exit transitions\n */\nconst Modal: FC<IModalProps> = memo(({ modal, isClosing = false, onClose }) => {\n const { renderAs, element, modalWidth, isDismissable } = modal;\n\n if (renderAs === 'spotlight') {\n return (\n <Styled.ModalContainer $isClosing={isClosing}>\n <Styled.SpotlightModal $isClosing={isClosing} />\n {element}\n </Styled.ModalContainer>\n );\n }\n\n return (\n <Suspense fallback={<AppLoader height=\"100vh\" />}>\n <Styled.ModalContainer $isClosing={isClosing}>\n <Styled.BaseModal $isClosing={isClosing} $width={modalWidth}>\n {isDismissable !== false && (\n <Styled.CloseButtonContainer $modalWidth={modalWidth}>\n <Clickable label=\"Close\" onClick={onClose}>\n <CrossIcon width={40} height={40} />\n </Clickable>\n </Styled.CloseButtonContainer>\n )}\n <Styled.BaseModalContent $modalWidth={modalWidth}>{element}</Styled.BaseModalContent>\n </Styled.BaseModal>\n </Styled.ModalContainer>\n </Suspense>\n );\n});\n\nexport default Modal;\n"],"names":["Modal","memo","modal","isClosing","onClose","renderAs","element","modalWidth","isDismissable","jsxs","Styled.ModalContainer","jsx","Styled.SpotlightModal","Suspense","AppLoader","Styled.BaseModal","Styled.CloseButtonContainer","Clickable","CrossIcon","Styled.BaseModalContent"],"mappings":";;;;;;AAcM,MAAAA,IAAyBC,EAAK,CAAC,EAAE,OAAAC,GAAO,WAAAC,IAAY,IAAO,SAAAC,QAAc;AAC7E,QAAM,EAAE,UAAAC,GAAU,SAAAC,GAAS,YAAAC,GAAY,eAAAC,MAAkBN;AAEzD,SAAIG,MAAa,cAEZ,gBAAAI,EAAAC,GAAA,EAAsB,YAAYP,GACjC,UAAA;AAAA,IAAA,gBAAAQ,EAACC,GAAA,EAAsB,YAAYT,EAAW,CAAA;AAAA,IAC7CG;AAAA,EACH,EAAA,CAAA,IAKF,gBAAAK,EAACE,KAAS,UAAU,gBAAAF,EAACG,KAAU,QAAO,SAAQ,GAC5C,UAAC,gBAAAH,EAAAD,GAAA,EAAsB,YAAYP,GACjC,UAAC,gBAAAM,EAAAM,GAAA,EAAiB,YAAYZ,GAAW,QAAQI,GAC9C,UAAA;AAAA,IAAkBC,MAAA,wBAChBQ,GAAA,EAA4B,aAAaT,GACxC,4BAACU,GAAU,EAAA,OAAM,SAAQ,SAASb,GAChC,4BAACc,GAAU,EAAA,OAAO,IAAI,QAAQ,IAAI,GACpC,EACF,CAAA;AAAA,sBAEDC,GAAA,EAAwB,aAAaZ,GAAa,UAAQD,GAAA;AAAA,EAAA,GAC7D,GACF,EACF,CAAA;AAEJ,CAAC;"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cuemath/leap",
3
- "version": "3.2.2-aa13",
3
+ "version": "3.2.2-aa6",
4
4
  "type": "module",
5
5
  "files": [
6
6
  "dist"