@cuemath/leap 3.2.17-j1 → 3.2.17-mb
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/assets/illustrations/illustrations.js +0 -5
- package/dist/assets/illustrations/illustrations.js.map +1 -1
- package/dist/assets/lottie/lottie.js +1 -11
- package/dist/assets/lottie/lottie.js.map +1 -1
- package/dist/features/auth/account-selector/account-selector.js +25 -26
- package/dist/features/auth/account-selector/account-selector.js.map +1 -1
- package/dist/features/auth/comps/auth-page-layout/auth-page-layout.js +14 -20
- package/dist/features/auth/comps/auth-page-layout/auth-page-layout.js.map +1 -1
- package/dist/features/auth/comps/resend-otp/resend-otp.js +47 -54
- package/dist/features/auth/comps/resend-otp/resend-otp.js.map +1 -1
- package/dist/features/auth/comps/tabs/tab-tem/tab-item.js +17 -29
- package/dist/features/auth/comps/tabs/tab-tem/tab-item.js.map +1 -1
- package/dist/features/auth/comps/tabs/tabs-styled.js +10 -22
- package/dist/features/auth/comps/tabs/tabs-styled.js.map +1 -1
- package/dist/features/auth/comps/tabs/tabs.js +5 -5
- package/dist/features/auth/comps/tabs/tabs.js.map +1 -1
- package/dist/features/auth/comps/user-list/user-item/user-item.js +31 -30
- package/dist/features/auth/comps/user-list/user-item/user-item.js.map +1 -1
- package/dist/features/auth/comps/user-list/user-list.js +34 -35
- package/dist/features/auth/comps/user-list/user-list.js.map +1 -1
- package/dist/features/auth/forgot-password/forgot-password-styled.js +15 -14
- package/dist/features/auth/forgot-password/forgot-password-styled.js.map +1 -1
- package/dist/features/auth/login/identifier-otp-form/identifier-otp-form-styled.js +7 -6
- package/dist/features/auth/login/identifier-otp-form/identifier-otp-form-styled.js.map +1 -1
- package/dist/features/auth/login/login-styled.js +9 -8
- package/dist/features/auth/login/login-styled.js.map +1 -1
- package/dist/features/chapters-v2/utils/node-card-utils.js +7 -7
- package/dist/features/chapters-v2/utils/node-card-utils.js.map +1 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/tables-card-styled.js +4 -4
- package/dist/features/circle-games/game-launcher/comps/tables-card/tables-card-styled.js.map +1 -1
- package/dist/features/circle-games/game-launcher/comps/tables-card/tables-card.js +85 -85
- package/dist/features/circle-games/game-launcher/comps/tables-card/tables-card.js.map +1 -1
- package/dist/features/circle-games/game-launcher/hooks/use-game-launcher-journey/use-game-launcher-journey.js +98 -121
- package/dist/features/circle-games/game-launcher/hooks/use-game-launcher-journey/use-game-launcher-journey.js.map +1 -1
- package/dist/features/circle-games/game-launcher/hooks/use-table-infinite-launcher-journey/use-table-infinite-launcher-journey.js +28 -29
- package/dist/features/circle-games/game-launcher/hooks/use-table-infinite-launcher-journey/use-table-infinite-launcher-journey.js.map +1 -1
- package/dist/features/circle-games/game-launcher/hooks/use-table-launcher-journey/use-table-launcher-journey.js +42 -43
- package/dist/features/circle-games/game-launcher/hooks/use-table-launcher-journey/use-table-launcher-journey.js.map +1 -1
- package/dist/features/circle-games/games/tutorial/tutorial.js +35 -43
- package/dist/features/circle-games/games/tutorial/tutorial.js.map +1 -1
- package/dist/features/circle-games/sign-up/comp/grade-input/grade-input-styled.js +2 -2
- package/dist/features/circle-games/sign-up/comp/grade-input/grade-input-styled.js.map +1 -1
- package/dist/features/circle-games/sign-up/comp/grade-input/grade-input.js +1 -1
- package/dist/features/circle-games/sign-up/comp/grade-input/grade-input.js.map +1 -1
- package/dist/features/circle-games/sign-up/comp/username-input/username-input.js +24 -26
- package/dist/features/circle-games/sign-up/comp/username-input/username-input.js.map +1 -1
- package/dist/features/circle-games/sign-up/constants.js +1 -3
- package/dist/features/circle-games/sign-up/constants.js.map +1 -1
- package/dist/features/cue-canvas/hooks/use-canvas-sync-broker.js +42 -42
- package/dist/features/cue-canvas/hooks/use-canvas-sync-broker.js.map +1 -1
- package/dist/features/hooks/use-viewport/use-viewport.js +22 -0
- package/dist/features/hooks/use-viewport/use-viewport.js.map +1 -0
- package/dist/features/journey/comps/coachmark/coachmark.js +27 -29
- package/dist/features/journey/comps/coachmark/coachmark.js.map +1 -1
- package/dist/features/journey/journey-id/journey-id-student.js +2 -2
- package/dist/features/journey/journey-id/journey-id-student.js.map +1 -1
- package/dist/features/journey/use-journey/journey-context-provider.js +72 -73
- package/dist/features/journey/use-journey/journey-context-provider.js.map +1 -1
- package/dist/features/journey/use-journey/journey-styled.js +4 -6
- package/dist/features/journey/use-journey/journey-styled.js.map +1 -1
- package/dist/features/stickers/sticker-data.js +234 -0
- package/dist/features/stickers/sticker-data.js.map +1 -0
- package/dist/features/{ui/sticker-grid/sticker-grid-styles.js → stickers/sticker-selector/sticker-selector-styles.js} +4 -3
- package/dist/features/stickers/sticker-selector/sticker-selector-styles.js.map +1 -0
- package/dist/features/stickers/sticker-selector/sticker-selector.js +25 -0
- package/dist/features/stickers/sticker-selector/sticker-selector.js.map +1 -0
- package/dist/features/stickers/sticker-selector/sticker.js +57 -0
- package/dist/features/stickers/sticker-selector/sticker.js.map +1 -0
- package/dist/features/{ui/stickers/stickers-effects.js → stickers/stickers-effects/effects.js} +6 -6
- package/dist/features/stickers/stickers-effects/effects.js.map +1 -0
- package/dist/features/{ui/stickers/stickers-styled.js → stickers/stickers-effects/stickers-effects-styled.js} +2 -2
- package/dist/features/stickers/stickers-effects/stickers-effects-styled.js.map +1 -0
- package/dist/features/{ui/stickers/stickers-utils.js → stickers/stickers-effects/stickers-effects-utils.js} +6 -6
- package/dist/features/stickers/stickers-effects/stickers-effects-utils.js.map +1 -0
- package/dist/features/stickers/stickers-effects/stickers-effects.js +39 -0
- package/dist/features/stickers/stickers-effects/stickers-effects.js.map +1 -0
- package/dist/features/ui/arrow-tooltip/arrow-tooltip-styled.js +60 -12
- package/dist/features/ui/arrow-tooltip/arrow-tooltip-styled.js.map +1 -1
- package/dist/features/ui/arrow-tooltip/arrow-tooltip.js +77 -72
- package/dist/features/ui/arrow-tooltip/arrow-tooltip.js.map +1 -1
- package/dist/features/ui/error/error.js +27 -65
- package/dist/features/ui/error/error.js.map +1 -1
- package/dist/features/ui/image/image.js +1 -1
- package/dist/features/ui/image/image.js.map +1 -1
- package/dist/features/ui/lottie-animation/lottie-animation.js +29 -25
- package/dist/features/ui/lottie-animation/lottie-animation.js.map +1 -1
- package/dist/features/ui/modals/modal-styled.js +58 -34
- package/dist/features/ui/modals/modal-styled.js.map +1 -1
- package/dist/features/ui/modals/modal.js +14 -40
- package/dist/features/ui/modals/modal.js.map +1 -1
- package/dist/features/ui/nudge/nudge-styled.js +7 -14
- package/dist/features/ui/nudge/nudge-styled.js.map +1 -1
- package/dist/features/ui/nudge/nudge.js +12 -13
- package/dist/features/ui/nudge/nudge.js.map +1 -1
- package/dist/features/ui/streak-icon/streak-icon-styled.js +13 -13
- package/dist/features/ui/streak-icon/streak-icon-styled.js.map +1 -1
- package/dist/features/ui/streak-icon/streak-icon.js +15 -17
- package/dist/features/ui/streak-icon/streak-icon.js.map +1 -1
- package/dist/features/ui/text/text.js +36 -40
- package/dist/features/ui/text/text.js.map +1 -1
- package/dist/features/ui/theme/button.js +78 -78
- package/dist/features/ui/theme/button.js.map +1 -1
- package/dist/features/ui/theme/constants.js +2 -4
- package/dist/features/ui/theme/constants.js.map +1 -1
- package/dist/features/ui/theme/get-device.js +3 -3
- package/dist/features/ui/theme/get-device.js.map +1 -1
- package/dist/features/worksheet/worksheet/constants.js +13 -12
- package/dist/features/worksheet/worksheet/constants.js.map +1 -1
- package/dist/features/worksheet/worksheet/worksheet-question/learnosity-question.js +24 -24
- package/dist/features/worksheet/worksheet/worksheet-question/learnosity-question.js.map +1 -1
- package/dist/features/worksheet/worksheet/worksheet-question/worksheet-question.js +260 -246
- package/dist/features/worksheet/worksheet/worksheet-question/worksheet-question.js.map +1 -1
- package/dist/features/worksheet/worksheet/worksheet-styled.js +28 -37
- package/dist/features/worksheet/worksheet/worksheet-styled.js.map +1 -1
- package/dist/features/worksheet/worksheet/worksheet.js +164 -166
- package/dist/features/worksheet/worksheet/worksheet.js.map +1 -1
- package/dist/index.d.ts +55 -184
- package/dist/index.js +541 -579
- package/dist/index.js.map +1 -1
- package/dist/node_modules/query-string/base.js +1 -1
- package/dist/node_modules/query-string/node_modules/decode-uri-component/index.js.map +1 -0
- package/dist/node_modules/uuid/dist/esm-browser/regex.js +5 -0
- package/dist/node_modules/uuid/dist/esm-browser/regex.js.map +1 -0
- package/dist/node_modules/uuid/dist/esm-browser/rng.js +2 -3
- package/dist/node_modules/uuid/dist/esm-browser/rng.js.map +1 -1
- package/dist/node_modules/uuid/dist/esm-browser/stringify.js +10 -6
- package/dist/node_modules/uuid/dist/esm-browser/stringify.js.map +1 -1
- package/dist/node_modules/uuid/dist/esm-browser/v4.js +9 -12
- package/dist/node_modules/uuid/dist/esm-browser/v4.js.map +1 -1
- package/dist/node_modules/uuid/dist/esm-browser/validate.js +8 -0
- package/dist/node_modules/uuid/dist/esm-browser/validate.js.map +1 -0
- package/dist/static/nudge-tap.5cb30093.json +1057 -0
- package/package.json +1 -1
- package/dist/assets/line-icons/icons/after-noon.js +0 -34
- package/dist/assets/line-icons/icons/after-noon.js.map +0 -1
- package/dist/assets/line-icons/icons/apple-icon-white.js +0 -42
- package/dist/assets/line-icons/icons/apple-icon-white.js.map +0 -1
- package/dist/assets/line-icons/icons/cue-board-filled.js +0 -33
- package/dist/assets/line-icons/icons/cue-board-filled.js.map +0 -1
- package/dist/assets/line-icons/icons/cue-board.js +0 -23
- package/dist/assets/line-icons/icons/cue-board.js.map +0 -1
- package/dist/assets/line-icons/icons/evening.js +0 -35
- package/dist/assets/line-icons/icons/evening.js.map +0 -1
- package/dist/assets/line-icons/icons/hint-fill.js +0 -35
- package/dist/assets/line-icons/icons/hint-fill.js.map +0 -1
- package/dist/assets/line-icons/icons/morning.js +0 -35
- package/dist/assets/line-icons/icons/morning.js.map +0 -1
- package/dist/assets/line-icons/icons/screen-grab-filled.js +0 -35
- package/dist/assets/line-icons/icons/screen-grab-filled.js.map +0 -1
- package/dist/assets/line-icons/icons/screen-grab.js +0 -23
- package/dist/assets/line-icons/icons/screen-grab.js.map +0 -1
- package/dist/assets/line-icons/icons/sticker-filled.js +0 -64
- package/dist/assets/line-icons/icons/sticker-filled.js.map +0 -1
- package/dist/assets/line-icons/icons/sticker.js +0 -46
- package/dist/assets/line-icons/icons/sticker.js.map +0 -1
- package/dist/features/auth/comps/animated-avatar-message/animated-avatar-message-constants.js +0 -9
- package/dist/features/auth/comps/animated-avatar-message/animated-avatar-message-constants.js.map +0 -1
- package/dist/features/auth/comps/animated-avatar-message/animated-avatar-message-styled.js +0 -52
- package/dist/features/auth/comps/animated-avatar-message/animated-avatar-message-styled.js.map +0 -1
- package/dist/features/auth/comps/animated-avatar-message/animated-avatar-message.js +0 -95
- package/dist/features/auth/comps/animated-avatar-message/animated-avatar-message.js.map +0 -1
- package/dist/features/auth/comps/animated-avatar-message/animated-text/animated-text-styled.js +0 -10
- package/dist/features/auth/comps/animated-avatar-message/animated-text/animated-text-styled.js.map +0 -1
- package/dist/features/auth/comps/animated-avatar-message/animated-text/animated-text.js +0 -17
- package/dist/features/auth/comps/animated-avatar-message/animated-text/animated-text.js.map +0 -1
- package/dist/features/auth/comps/linear-progress-bar/linear-progress-bar-styled.js +0 -12
- package/dist/features/auth/comps/linear-progress-bar/linear-progress-bar-styled.js.map +0 -1
- package/dist/features/auth/comps/linear-progress-bar/linear-progress-bar.js +0 -34
- package/dist/features/auth/comps/linear-progress-bar/linear-progress-bar.js.map +0 -1
- package/dist/features/auth/comps/otp-input/otp-input-styled.js +0 -22
- package/dist/features/auth/comps/otp-input/otp-input-styled.js.map +0 -1
- package/dist/features/auth/comps/otp-input/otp-input.js +0 -51
- package/dist/features/auth/comps/otp-input/otp-input.js.map +0 -1
- package/dist/features/auth/comps/pill-button/pill-button-styled.js +0 -44
- package/dist/features/auth/comps/pill-button/pill-button-styled.js.map +0 -1
- package/dist/features/auth/comps/pill-button/pill-button.js +0 -75
- package/dist/features/auth/comps/pill-button/pill-button.js.map +0 -1
- package/dist/features/auth/comps/selectable-info-card/selectable-info-card-styled.js +0 -17
- package/dist/features/auth/comps/selectable-info-card/selectable-info-card-styled.js.map +0 -1
- package/dist/features/auth/comps/selectable-info-card/selectable-info-card.js +0 -67
- package/dist/features/auth/comps/selectable-info-card/selectable-info-card.js.map +0 -1
- package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide-constants.js +0 -19
- package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide-constants.js.map +0 -1
- package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide-styled.js +0 -32
- package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide-styled.js.map +0 -1
- package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide.js +0 -44
- package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide.js.map +0 -1
- package/dist/features/auth/pla-signup/signup-header/signup-header.js +0 -54
- package/dist/features/auth/pla-signup/signup-header/signup-header.js.map +0 -1
- package/dist/features/auth/pla-signup/signup-options/signup-options.js +0 -83
- package/dist/features/auth/pla-signup/signup-options/signup-options.js.map +0 -1
- package/dist/features/puzzles/app/puzzle-app-styled.js +0 -81
- package/dist/features/puzzles/app/puzzle-app-styled.js.map +0 -1
- package/dist/features/puzzles/app/puzzle-app-view.js +0 -120
- package/dist/features/puzzles/app/puzzle-app-view.js.map +0 -1
- package/dist/features/puzzles/app/puzzle-app.js +0 -62
- package/dist/features/puzzles/app/puzzle-app.js.map +0 -1
- package/dist/features/ui/arrow-tooltip/arrow-tooltip-constants.js +0 -6
- package/dist/features/ui/arrow-tooltip/arrow-tooltip-constants.js.map +0 -1
- package/dist/features/ui/arrow-tooltip/comps/tooltip-body-styled.js +0 -63
- package/dist/features/ui/arrow-tooltip/comps/tooltip-body-styled.js.map +0 -1
- package/dist/features/ui/arrow-tooltip/comps/tooltip-body.js +0 -21
- package/dist/features/ui/arrow-tooltip/comps/tooltip-body.js.map +0 -1
- package/dist/features/ui/drawer/drawer-styled.js +0 -34
- package/dist/features/ui/drawer/drawer-styled.js.map +0 -1
- package/dist/features/ui/drawer/drawer.js +0 -42
- package/dist/features/ui/drawer/drawer.js.map +0 -1
- package/dist/features/ui/sticker-grid/sticker-grid-styles.js.map +0 -1
- package/dist/features/ui/sticker-grid/sticker-grid.js +0 -24
- package/dist/features/ui/sticker-grid/sticker-grid.js.map +0 -1
- package/dist/features/ui/sticker-grid/sticker.js +0 -57
- package/dist/features/ui/sticker-grid/sticker.js.map +0 -1
- package/dist/features/ui/stickers/constants.js +0 -6
- package/dist/features/ui/stickers/constants.js.map +0 -1
- package/dist/features/ui/stickers/stickers-effects.js.map +0 -1
- package/dist/features/ui/stickers/stickers-styled.js.map +0 -1
- package/dist/features/ui/stickers/stickers-utils.js.map +0 -1
- package/dist/features/ui/stickers/stickers.js +0 -40
- package/dist/features/ui/stickers/stickers.js.map +0 -1
- package/dist/node_modules/decode-uri-component/index.js.map +0 -1
- package/dist/node_modules/uuid/dist/esm-browser/native.js +0 -7
- package/dist/node_modules/uuid/dist/esm-browser/native.js.map +0 -1
- package/dist/static/animated-avatar.1ad58b1d.json +0 -1
- package/dist/static/animated-avatar.69b07505.json +0 -1
- package/dist/static/animated-avatar.9c560b46.json +0 -1
- package/dist/static/calendar-purple.1a840b41.svg +0 -1
- package/dist/static/flying-disk.c7f6ed39.json +0 -1
- package/dist/static/graduation-cap.3be3340a.json +0 -1
- package/dist/static/handshake.287e7dfb.svg +0 -1
- package/dist/static/light-bulb.c6db0b23.json +0 -1
- package/dist/static/money.332aacf1.svg +0 -1
- package/dist/static/muscle.9bcfb8a7.json +0 -1
- package/dist/static/nudge-tap.0591aef4.json +0 -1
- package/dist/static/parent-avatar.822c7b9b.svg +0 -1
- package/dist/static/pencil.23df9da0.json +0 -1
- package/dist/static/plus-sign.de6af957.json +0 -1
- package/dist/static/racing-car.2cbf864e.json +0 -1
- package/dist/static/rocket.0a3ccab0.json +0 -1
- package/dist/static/shovel.abeec04c.json +0 -1
- package/dist/static/trustpilot.bd3d79e1.svg +0 -1
- /package/dist/node_modules/{decode-uri-component → query-string/node_modules/decode-uri-component}/index.js +0 -0
@@ -1,44 +0,0 @@
|
|
1
|
-
import { jsxs as n, jsx as e } from "react/jsx-runtime";
|
2
|
-
import { useTheme as m } from "styled-components";
|
3
|
-
import t from "../../../ui/layout/flex-view.js";
|
4
|
-
import a from "../../../ui/separator/separator.js";
|
5
|
-
import l from "../../../ui/text/text.js";
|
6
|
-
import { EDeviceType as p } from "../../../ui/theme/constants.js";
|
7
|
-
import { onboardingGuideSteps as s } from "./onboarding-guide-constants.js";
|
8
|
-
import { StepItem as $ } from "./onboarding-guide-styled.js";
|
9
|
-
const d = () => {
|
10
|
-
const { device: c } = m(), r = c <= p.TABLET;
|
11
|
-
return /* @__PURE__ */ n(t, { $flex: 1, $alignItems: "center", $justifyContent: "center", children: [
|
12
|
-
/* @__PURE__ */ e(l, { $whiteSpace: "pre-line", $renderAs: "ah4", $color: "WHITE", $renderOnTabletAs: "ab1", children: "Get started in 3 easy steps!" }),
|
13
|
-
/* @__PURE__ */ e(a, { heightX: r ? 1 : 2.75 }),
|
14
|
-
/* @__PURE__ */ e(t, { $flexDirection: r ? "row" : "column", $flexColumnGapX: 1.5, children: s.map((i, o) => /* @__PURE__ */ n(
|
15
|
-
$,
|
16
|
-
{
|
17
|
-
$flex: 1,
|
18
|
-
$flexDirection: r ? "column" : "row",
|
19
|
-
$flexColumnGapX: 1.5,
|
20
|
-
$flexRowGapX: 0.5,
|
21
|
-
$alignItems: "center",
|
22
|
-
children: [
|
23
|
-
/* @__PURE__ */ e("img", { src: i.icon, alt: `Step ${o + 1}`, width: 56, height: 56 }),
|
24
|
-
/* @__PURE__ */ e(t, { $width: r ? 101 : 210, children: /* @__PURE__ */ e(
|
25
|
-
l,
|
26
|
-
{
|
27
|
-
$whiteSpace: "pre-line",
|
28
|
-
$renderAs: "ab2",
|
29
|
-
$renderOnTabletAs: "ab3",
|
30
|
-
$color: "WHITE",
|
31
|
-
$align: r ? "center" : "left",
|
32
|
-
children: i.title
|
33
|
-
}
|
34
|
-
) })
|
35
|
-
]
|
36
|
-
},
|
37
|
-
o
|
38
|
-
)) })
|
39
|
-
] });
|
40
|
-
}, G = d;
|
41
|
-
export {
|
42
|
-
G as default
|
43
|
-
};
|
44
|
-
//# sourceMappingURL=onboarding-guide.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"onboarding-guide.js","sources":["../../../../../src/features/auth/pla-signup/onboarding-guide/onboarding-guide.tsx"],"sourcesContent":["import { useTheme } from 'styled-components';\n\nimport FlexView from '../../../ui/layout/flex-view';\nimport Separator from '../../../ui/separator/separator';\nimport Text from '../../../ui/text/text';\nimport { EDeviceType } from '../../../ui/theme/constants';\nimport { onboardingGuideSteps } from './onboarding-guide-constants';\nimport * as Styled from './onboarding-guide-styled';\n\nconst OnboardingGuide = () => {\n const { device } = useTheme();\n const isCompact = device <= EDeviceType.TABLET;\n\n return (\n <FlexView $flex={1} $alignItems=\"center\" $justifyContent=\"center\">\n <Text $whiteSpace=\"pre-line\" $renderAs=\"ah4\" $color=\"WHITE\" $renderOnTabletAs=\"ab1\">\n Get started in 3 easy steps!\n </Text>\n <Separator heightX={isCompact ? 1 : 2.75} />\n <FlexView $flexDirection={isCompact ? 'row' : 'column'} $flexColumnGapX={1.5}>\n {onboardingGuideSteps.map((step, index) => (\n <Styled.StepItem\n key={index}\n $flex={1}\n $flexDirection={isCompact ? 'column' : 'row'}\n $flexColumnGapX={1.5}\n $flexRowGapX={0.5}\n $alignItems={'center'}\n >\n <img src={step.icon} alt={`Step ${index + 1}`} width={56} height={56} />\n <FlexView $width={isCompact ? 101 : 210}>\n <Text\n $whiteSpace=\"pre-line\"\n $renderAs=\"ab2\"\n $renderOnTabletAs=\"ab3\"\n $color=\"WHITE\"\n $align={isCompact ? 'center' : 'left'}\n >\n {step.title}\n </Text>\n </FlexView>\n </Styled.StepItem>\n ))}\n </FlexView>\n </FlexView>\n );\n};\n\nexport default OnboardingGuide;\n"],"names":["OnboardingGuide","device","useTheme","isCompact","EDeviceType","FlexView","jsx","Text","Separator","onboardingGuideSteps","step","index","jsxs","Styled.StepItem","OnboardingGuide$1"],"mappings":";;;;;;;;AASA,MAAMA,IAAkB,MAAM;AACtB,QAAA,EAAE,QAAAC,MAAWC,KACbC,IAAYF,KAAUG,EAAY;AAExC,2BACGC,GAAS,EAAA,OAAO,GAAG,aAAY,UAAS,iBAAgB,UACvD,UAAA;AAAA,IAAC,gBAAAC,EAAAC,GAAA,EAAK,aAAY,YAAW,WAAU,OAAM,QAAO,SAAQ,mBAAkB,OAAM,UAEpF,+BAAA,CAAA;AAAA,IACC,gBAAAD,EAAAE,GAAA,EAAU,SAASL,IAAY,IAAI,MAAM;AAAA,IACzC,gBAAAG,EAAAD,GAAA,EAAS,gBAAgBF,IAAY,QAAQ,UAAU,iBAAiB,KACtE,UAAqBM,EAAA,IAAI,CAACC,GAAMC,MAC/B,gBAAAC;AAAA,MAACC;AAAAA,MAAA;AAAA,QAEC,OAAO;AAAA,QACP,gBAAgBV,IAAY,WAAW;AAAA,QACvC,iBAAiB;AAAA,QACjB,cAAc;AAAA,QACd,aAAa;AAAA,QAEb,UAAA;AAAA,UAAA,gBAAAG,EAAC,OAAI,EAAA,KAAKI,EAAK,MAAM,KAAK,QAAQC,IAAQ,CAAC,IAAI,OAAO,IAAI,QAAQ,IAAI;AAAA,UACrE,gBAAAL,EAAAD,GAAA,EAAS,QAAQF,IAAY,MAAM,KAClC,UAAA,gBAAAG;AAAA,YAACC;AAAA,YAAA;AAAA,cACC,aAAY;AAAA,cACZ,WAAU;AAAA,cACV,mBAAkB;AAAA,cAClB,QAAO;AAAA,cACP,QAAQJ,IAAY,WAAW;AAAA,cAE9B,UAAKO,EAAA;AAAA,YAAA;AAAA,UAAA,GAEV;AAAA,QAAA;AAAA,MAAA;AAAA,MAlBKC;AAAA,IAoBR,CAAA,GACH;AAAA,EACF,EAAA,CAAA;AAEJ,GAEAG,IAAed;"}
|
@@ -1,54 +0,0 @@
|
|
1
|
-
import { jsxs as t, jsx as r } from "react/jsx-runtime";
|
2
|
-
import { useTheme as s } from "styled-components";
|
3
|
-
import { ILLUSTRATIONS as o } from "../../../../assets/illustrations/illustrations.js";
|
4
|
-
import i from "../../../ui/image/image.js";
|
5
|
-
import n from "../../../ui/layout/flex-view.js";
|
6
|
-
import c from "../../../ui/separator/separator.js";
|
7
|
-
import l from "../../../ui/text/text.js";
|
8
|
-
import { EDeviceType as a } from "../../../ui/theme/constants.js";
|
9
|
-
const d = () => {
|
10
|
-
const { device: m } = s(), e = m <= a.TABLET;
|
11
|
-
return /* @__PURE__ */ t(
|
12
|
-
n,
|
13
|
-
{
|
14
|
-
$flexDirection: e ? "row" : "column",
|
15
|
-
$alignItems: e ? "center" : "flex-start",
|
16
|
-
$width: "100%",
|
17
|
-
$flexColumnGapX: 1,
|
18
|
-
$justifyContent: e ? "space-between" : "flex-start",
|
19
|
-
children: [
|
20
|
-
/* @__PURE__ */ r(
|
21
|
-
i,
|
22
|
-
{
|
23
|
-
width: e ? 80 : 107,
|
24
|
-
src: o.CIRCLE_CUEMATH_LOGO_WHITE,
|
25
|
-
height: e ? 12 : 16
|
26
|
-
}
|
27
|
-
),
|
28
|
-
!e && /* @__PURE__ */ r(c, { heightX: 1 }),
|
29
|
-
/* @__PURE__ */ t(n, { $flexDirection: "row", $alignItems: "flex-end", children: [
|
30
|
-
/* @__PURE__ */ t(l, { $renderAs: "ab2", $renderOnTabletAs: "ub3", $color: "WHITE", children: [
|
31
|
-
"Rated",
|
32
|
-
" ",
|
33
|
-
/* @__PURE__ */ r(l, { $inline: !0, $renderAs: "ab2-bold", $renderOnTabletAs: "ub3-bold", $color: "WHITE", children: "4.8+" }),
|
34
|
-
" ",
|
35
|
-
"on"
|
36
|
-
] }),
|
37
|
-
" ",
|
38
|
-
/* @__PURE__ */ r(
|
39
|
-
i,
|
40
|
-
{
|
41
|
-
src: o.TRUSTPILOT,
|
42
|
-
width: e ? 80 : 99,
|
43
|
-
height: e ? 20 : 25
|
44
|
-
}
|
45
|
-
)
|
46
|
-
] })
|
47
|
-
]
|
48
|
-
}
|
49
|
-
);
|
50
|
-
}, b = d;
|
51
|
-
export {
|
52
|
-
b as default
|
53
|
-
};
|
54
|
-
//# sourceMappingURL=signup-header.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"signup-header.js","sources":["../../../../../src/features/auth/pla-signup/signup-header/signup-header.tsx"],"sourcesContent":["import { useTheme } from 'styled-components';\n\nimport { ILLUSTRATIONS } from '../../../../assets/illustrations/illustrations';\nimport Image from '../../../ui/image/image';\nimport FlexView from '../../../ui/layout/flex-view';\nimport Separator from '../../../ui/separator/separator';\nimport Text from '../../../ui/text/text';\nimport { EDeviceType } from '../../../ui/theme/constants';\n\nconst SignupHeader = () => {\n const { device } = useTheme();\n const isCompact = device <= EDeviceType.TABLET;\n\n return (\n <FlexView\n $flexDirection={isCompact ? 'row' : 'column'}\n $alignItems={isCompact ? 'center' : 'flex-start'}\n $width=\"100%\"\n $flexColumnGapX={1}\n $justifyContent={isCompact ? 'space-between' : 'flex-start'}\n >\n <Image\n width={isCompact ? 80 : 107}\n src={ILLUSTRATIONS.CIRCLE_CUEMATH_LOGO_WHITE}\n height={isCompact ? 12 : 16}\n />\n {!isCompact && <Separator heightX={1} />}\n <FlexView $flexDirection=\"row\" $alignItems=\"flex-end\">\n <Text $renderAs=\"ab2\" $renderOnTabletAs=\"ub3\" $color=\"WHITE\">\n Rated{' '}\n <Text $inline $renderAs=\"ab2-bold\" $renderOnTabletAs=\"ub3-bold\" $color=\"WHITE\">\n 4.8+\n </Text>{' '}\n on\n </Text>\n \n <Image\n src={ILLUSTRATIONS.TRUSTPILOT}\n width={isCompact ? 80 : 99}\n height={isCompact ? 20 : 25}\n />\n </FlexView>\n </FlexView>\n );\n};\n\nexport default SignupHeader;\n"],"names":["SignupHeader","device","useTheme","isCompact","EDeviceType","jsxs","FlexView","jsx","Image","ILLUSTRATIONS","Separator","Text","SignupHeader$1"],"mappings":";;;;;;;;AASA,MAAMA,IAAe,MAAM;AACnB,QAAA,EAAE,QAAAC,MAAWC,KACbC,IAAYF,KAAUG,EAAY;AAGtC,SAAA,gBAAAC;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,gBAAgBH,IAAY,QAAQ;AAAA,MACpC,aAAaA,IAAY,WAAW;AAAA,MACpC,QAAO;AAAA,MACP,iBAAiB;AAAA,MACjB,iBAAiBA,IAAY,kBAAkB;AAAA,MAE/C,UAAA;AAAA,QAAA,gBAAAI;AAAA,UAACC;AAAA,UAAA;AAAA,YACC,OAAOL,IAAY,KAAK;AAAA,YACxB,KAAKM,EAAc;AAAA,YACnB,QAAQN,IAAY,KAAK;AAAA,UAAA;AAAA,QAC3B;AAAA,QACC,CAACA,KAAc,gBAAAI,EAAAG,GAAA,EAAU,SAAS,EAAG,CAAA;AAAA,QACrC,gBAAAL,EAAAC,GAAA,EAAS,gBAAe,OAAM,aAAY,YACzC,UAAA;AAAA,UAAA,gBAAAD,EAACM,KAAK,WAAU,OAAM,mBAAkB,OAAM,QAAO,SAAQ,UAAA;AAAA,YAAA;AAAA,YACrD;AAAA,YACN,gBAAAJ,EAACI,GAAK,EAAA,SAAO,IAAC,WAAU,YAAW,mBAAkB,YAAW,QAAO,SAAQ,UAE/E,OAAA,CAAA;AAAA,YAAQ;AAAA,YAAI;AAAA,UAAA,GAEd;AAAA,UAAO;AAAA,UAEP,gBAAAJ;AAAA,YAACC;AAAA,YAAA;AAAA,cACC,KAAKC,EAAc;AAAA,cACnB,OAAON,IAAY,KAAK;AAAA,cACxB,QAAQA,IAAY,KAAK;AAAA,YAAA;AAAA,UAC3B;AAAA,QAAA,GACF;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAGN,GAEAS,IAAeZ;"}
|
@@ -1,83 +0,0 @@
|
|
1
|
-
import { jsxs as i, jsx as e } from "react/jsx-runtime";
|
2
|
-
import { memo as b } from "react";
|
3
|
-
import { useTheme as u } from "styled-components";
|
4
|
-
import $ from "../../../../assets/line-icons/icons/apple-icon-white.js";
|
5
|
-
import x from "../../../../assets/line-icons/icons/google-icon.js";
|
6
|
-
import r from "../../../ui/buttons/button/button.js";
|
7
|
-
import A from "../../../ui/buttons/text-button/text-button.js";
|
8
|
-
import t from "../../../ui/layout/flex-view.js";
|
9
|
-
import a from "../../../ui/separator/separator.js";
|
10
|
-
import c from "../../../ui/text/text.js";
|
11
|
-
import { EDeviceType as I } from "../../../ui/theme/constants.js";
|
12
|
-
const k = ({
|
13
|
-
onEmailSignup: m,
|
14
|
-
onAppleSignup: p,
|
15
|
-
onGoogleSignup: d,
|
16
|
-
loadingProvider: l,
|
17
|
-
onGoToLogin: h,
|
18
|
-
title: f
|
19
|
-
}) => {
|
20
|
-
const { device: g } = u(), o = g <= I.TABLET, n = l === "google", s = l === "apple";
|
21
|
-
return /* @__PURE__ */ i(t, { $alignItems: "flex-start", children: [
|
22
|
-
/* @__PURE__ */ e(c, { $renderAs: "ah3-bold", $renderOnMobileAs: "ah4-bold", $color: "WHITE", $whiteSpace: "pre", children: f }),
|
23
|
-
/* @__PURE__ */ e(a, { heightX: o ? 1.5 : 2.5 }),
|
24
|
-
/* @__PURE__ */ i(
|
25
|
-
t,
|
26
|
-
{
|
27
|
-
$flexGapX: 1,
|
28
|
-
$flex: 1,
|
29
|
-
$justifyContent: "center",
|
30
|
-
$alignItems: "flex-start",
|
31
|
-
$width: "100%",
|
32
|
-
children: [
|
33
|
-
/* @__PURE__ */ e(
|
34
|
-
r,
|
35
|
-
{
|
36
|
-
renderAs: "black-dark",
|
37
|
-
Icon: x,
|
38
|
-
width: o ? "100%" : 320,
|
39
|
-
label: "Signup with Google",
|
40
|
-
onClick: d,
|
41
|
-
size: "small",
|
42
|
-
busy: n,
|
43
|
-
disabled: n
|
44
|
-
}
|
45
|
-
),
|
46
|
-
/* @__PURE__ */ e(
|
47
|
-
r,
|
48
|
-
{
|
49
|
-
renderAs: "black-dark",
|
50
|
-
size: "small",
|
51
|
-
width: o ? "100%" : 320,
|
52
|
-
Icon: $,
|
53
|
-
label: "Signup with Apple",
|
54
|
-
onClick: p,
|
55
|
-
busy: s,
|
56
|
-
disabled: s
|
57
|
-
}
|
58
|
-
),
|
59
|
-
/* @__PURE__ */ e(
|
60
|
-
r,
|
61
|
-
{
|
62
|
-
renderAs: "black-dark",
|
63
|
-
size: "small",
|
64
|
-
width: o ? "100%" : 320,
|
65
|
-
label: "Continue with Email",
|
66
|
-
onClick: m
|
67
|
-
}
|
68
|
-
)
|
69
|
-
]
|
70
|
-
}
|
71
|
-
),
|
72
|
-
/* @__PURE__ */ e(a, { heightX: 1.5 }),
|
73
|
-
/* @__PURE__ */ i(t, { $flexDirection: "row", $alignItems: "center", children: [
|
74
|
-
/* @__PURE__ */ e(c, { $renderAs: "ub3", $color: "WHITE", children: "Already have an account?" }),
|
75
|
-
" ",
|
76
|
-
/* @__PURE__ */ e(A, { size: "small", label: "Log In", color: "WHITE", onClick: h })
|
77
|
-
] })
|
78
|
-
] });
|
79
|
-
}, B = b(k);
|
80
|
-
export {
|
81
|
-
B as default
|
82
|
-
};
|
83
|
-
//# sourceMappingURL=signup-options.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"signup-options.js","sources":["../../../../../src/features/auth/pla-signup/signup-options/signup-options.tsx"],"sourcesContent":["import type { ISignupOptionsProps } from './signup-options-types';\n\nimport { memo, type FC } from 'react';\nimport { useTheme } from 'styled-components';\n\nimport AppleIcon from '../../../../assets/line-icons/icons/apple-icon-white';\nimport GoogleIcon from '../../../../assets/line-icons/icons/google-icon';\nimport Button from '../../../ui/buttons/button/button';\nimport TextButton from '../../../ui/buttons/text-button/text-button';\nimport FlexView from '../../../ui/layout/flex-view';\nimport Separator from '../../../ui/separator/separator';\nimport Text from '../../../ui/text/text';\nimport { EDeviceType } from '../../../ui/theme/constants';\n\nconst SignupOptions: FC<ISignupOptionsProps> = ({\n onEmailSignup,\n onAppleSignup,\n onGoogleSignup,\n loadingProvider,\n onGoToLogin,\n title,\n}) => {\n const { device } = useTheme();\n const isCompact = device <= EDeviceType.TABLET;\n const isLoadingGoogle = loadingProvider === 'google';\n const isLoadingApple = loadingProvider === 'apple';\n\n return (\n <FlexView $alignItems=\"flex-start\">\n <Text $renderAs=\"ah3-bold\" $renderOnMobileAs=\"ah4-bold\" $color=\"WHITE\" $whiteSpace=\"pre\">\n {title}\n </Text>\n <Separator heightX={isCompact ? 1.5 : 2.5} />\n <FlexView\n $flexGapX={1}\n $flex={1}\n $justifyContent=\"center\"\n $alignItems=\"flex-start\"\n $width=\"100%\"\n >\n <Button\n renderAs=\"black-dark\"\n Icon={GoogleIcon}\n width={isCompact ? '100%' : 320}\n label=\"Signup with Google\"\n onClick={onGoogleSignup}\n size=\"small\"\n busy={isLoadingGoogle}\n disabled={isLoadingGoogle}\n />\n <Button\n renderAs=\"black-dark\"\n size=\"small\"\n width={isCompact ? '100%' : 320}\n Icon={AppleIcon}\n label=\"Signup with Apple\"\n onClick={onAppleSignup}\n busy={isLoadingApple}\n disabled={isLoadingApple}\n />\n <Button\n renderAs=\"black-dark\"\n size=\"small\"\n width={isCompact ? '100%' : 320}\n label=\"Continue with Email\"\n onClick={onEmailSignup}\n />\n </FlexView>\n <Separator heightX={1.5} />\n <FlexView $flexDirection=\"row\" $alignItems=\"center\">\n <Text $renderAs=\"ub3\" $color=\"WHITE\">\n Already have an account?\n </Text>\n \n <TextButton size=\"small\" label=\"Log In\" color=\"WHITE\" onClick={onGoToLogin} />\n </FlexView>\n </FlexView>\n );\n};\n\nexport default memo(SignupOptions);\n"],"names":["SignupOptions","onEmailSignup","onAppleSignup","onGoogleSignup","loadingProvider","onGoToLogin","title","device","useTheme","isCompact","EDeviceType","isLoadingGoogle","isLoadingApple","jsxs","FlexView","jsx","Text","Separator","Button","GoogleIcon","AppleIcon","TextButton","signupOptions","memo"],"mappings":";;;;;;;;;;;AAcA,MAAMA,IAAyC,CAAC;AAAA,EAC9C,eAAAC;AAAA,EACA,eAAAC;AAAA,EACA,gBAAAC;AAAA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A,SAAS,IAAK,CAAA;AAAA,IACxB,gBAAAJ,EAAAC,GAAA,EAAS,gBAAe,OAAM,aAAY,UACzC,UAAA;AAAA,MAAA,gBAAAC,EAACC,GAAK,EAAA,WAAU,OAAM,QAAO,SAAQ,UAErC,4BAAA;AAAA,MAAO;AAAA,MAEP,gBAAAD,EAACM,KAAW,MAAK,SAAQ,OAAM,UAAS,OAAM,SAAQ,SAAShB,EAAa,CAAA;AAAA,IAAA,GAC9E;AAAA,EACF,EAAA,CAAA;AAEJ,GAEeiB,IAAAC,EAAKvB,CAAa;"}
|
@@ -1,81 +0,0 @@
|
|
1
|
-
import o from "styled-components";
|
2
|
-
import n from "../../../assets/line-icons/icons/hint-fill.js";
|
3
|
-
import l from "../../ui/layout/flex-view.js";
|
4
|
-
import r from "../../ui/text/text.js";
|
5
|
-
import { getPuzzleCardPattern as p } from "../utils/puzzle-pattern.js";
|
6
|
-
const d = o(l)(({ theme: t, $visible: i }) => {
|
7
|
-
const { gutter: e } = t.layout;
|
8
|
-
return i ? `
|
9
|
-
overflow: scroll;
|
10
|
-
padding-top: ${e * 1.5}px;
|
11
|
-
padding-bottom: ${e * 2}px;
|
12
|
-
` : "";
|
13
|
-
}), g = o(l)`
|
14
|
-
position: relative;
|
15
|
-
margin: 0 auto;
|
16
|
-
box-shadow: inset 0px 0px 0px 4px ${({ theme: t, $imageHue: i }) => t.colors[`${i}_4`]};
|
17
|
-
max-width: 343px;
|
18
|
-
width: 100%;
|
19
|
-
min-height: max-content;
|
20
|
-
|
21
|
-
&::before {
|
22
|
-
content: '';
|
23
|
-
position: absolute;
|
24
|
-
top: 0;
|
25
|
-
left: 0;
|
26
|
-
right: 0;
|
27
|
-
bottom: 0;
|
28
|
-
background-image: ${({ $imageHue: t }) => `url(${p(t)})`};
|
29
|
-
background-size: cover;
|
30
|
-
opacity: 0.2;
|
31
|
-
}
|
32
|
-
`, x = o(n)`
|
33
|
-
color: ${({ theme: t }) => t.colors.BLACK_1};
|
34
|
-
|
35
|
-
& .hint-fill-icon-path {
|
36
|
-
fill: ${({ theme: t }) => t.colors.WHITE_1};
|
37
|
-
}
|
38
|
-
`, u = o(r)`
|
39
|
-
& span {
|
40
|
-
font-weight: 700;
|
41
|
-
margin-right: 4px;
|
42
|
-
}
|
43
|
-
`, h = o.div`
|
44
|
-
color: ${({ theme: t }) => t.colors.BLACK};
|
45
|
-
font-size: 14px;
|
46
|
-
line-height: 1.2;
|
47
|
-
font-family: 'Athletics';
|
48
|
-
|
49
|
-
font-weight: 400;
|
50
|
-
font-style: normal;
|
51
|
-
|
52
|
-
em {
|
53
|
-
font-style: italic;
|
54
|
-
}
|
55
|
-
|
56
|
-
ul,
|
57
|
-
ol {
|
58
|
-
list-style-type: initial;
|
59
|
-
padding-left: 32px;
|
60
|
-
}
|
61
|
-
|
62
|
-
ol {
|
63
|
-
list-style-type: decimal;
|
64
|
-
}
|
65
|
-
|
66
|
-
p {
|
67
|
-
margin: 0;
|
68
|
-
}
|
69
|
-
|
70
|
-
li {
|
71
|
-
margin: 4px 0;
|
72
|
-
}
|
73
|
-
`;
|
74
|
-
export {
|
75
|
-
d as PuzzleAppWrapper,
|
76
|
-
g as PuzzleContainer,
|
77
|
-
h as PuzzleQuestionWrapper,
|
78
|
-
u as StyledFeedbackText,
|
79
|
-
x as StyledHintFillIcon
|
80
|
-
};
|
81
|
-
//# sourceMappingURL=puzzle-app-styled.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"puzzle-app-styled.js","sources":["../../../../src/features/puzzles/app/puzzle-app-styled.tsx"],"sourcesContent":["import type { THueNames } from '../../ui/types';\n\nimport styled from 'styled-components';\n\nimport HintFillIcon from '../../../assets/line-icons/icons/hint-fill';\nimport FlexView from '../../ui/layout/flex-view';\nimport Text from '../../ui/text/text';\nimport { getPuzzleCardPattern } from '../utils/puzzle-pattern';\n\nconst PuzzleAppWrapper = styled(FlexView)<{ $visible: boolean }>(({ theme, $visible }) => {\n const { gutter } = theme.layout;\n\n if (!$visible) {\n return ``;\n }\n\n return `\n overflow: scroll;\n padding-top: ${gutter * 1.5}px;\n padding-bottom: ${gutter * 2}px;\n `;\n});\n\nconst PuzzleContainer = styled(FlexView)<{ $imageHue: THueNames; $backgroundOpacity?: number }>`\n position: relative;\n margin: 0 auto;\n box-shadow: inset 0px 0px 0px 4px ${({ theme, $imageHue }) => theme.colors[`${$imageHue}_4`]};\n max-width: 343px;\n width: 100%;\n min-height: max-content;\n\n &::before {\n content: '';\n position: absolute;\n top: 0;\n left: 0;\n right: 0;\n bottom: 0;\n background-image: ${({ $imageHue }) => `url(${getPuzzleCardPattern($imageHue)})`};\n background-size: cover;\n opacity: 0.2;\n }\n`;\n\nconst StyledHintFillIcon = styled(HintFillIcon)`\n color: ${({ theme }) => theme.colors.BLACK_1};\n\n & .hint-fill-icon-path {\n fill: ${({ theme }) => theme.colors.WHITE_1};\n }\n`;\n\nconst StyledFeedbackText = styled(Text)`\n & span {\n font-weight: 700;\n margin-right: 4px;\n }\n`;\n\nconst PuzzleQuestionWrapper = styled.div`\n color: ${({ theme }) => theme.colors.BLACK};\n font-size: 14px;\n line-height: 1.2;\n font-family: 'Athletics';\n\n font-weight: 400;\n font-style: normal;\n\n em {\n font-style: italic;\n }\n\n ul,\n ol {\n list-style-type: initial;\n padding-left: 32px;\n }\n\n ol {\n list-style-type: decimal;\n }\n\n p {\n margin: 0;\n }\n\n li {\n margin: 4px 0;\n }\n`;\n\nexport {\n PuzzleAppWrapper,\n PuzzleContainer,\n StyledFeedbackText,\n StyledHintFillIcon,\n PuzzleQuestionWrapper,\n};\n"],"names":["PuzzleAppWrapper","styled","FlexView","theme","$visible","gutter","PuzzleContainer","$imageHue","getPuzzleCardPattern","StyledHintFillIcon","HintFillIcon","StyledFeedbackText","Text","PuzzleQuestionWrapper"],"mappings":";;;;;AASM,MAAAA,IAAmBC,EAAOC,CAAQ,EAAyB,CAAC,EAAE,OAAAC,GAAO,UAAAC,QAAe;AAClF,QAAA,EAAE,QAAAC,EAAO,IAAIF,EAAM;AAEzB,SAAKC,IAIE;AAAA;AAAA,mBAEUC,IAAS,GAAG;AAAA,sBACTA,IAAS,CAAC;AAAA,MANrB;AAQX,CAAC,GAEKC,IAAkBL,EAAOC,CAAQ;AAAA;AAAA;AAAA,sCAGD,CAAC,EAAE,OAAAC,GAAO,WAAAI,QAAgBJ,EAAM,OAAO,GAAGI,CAAS,IAAI,CAAC;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,wBAYtE,CAAC,EAAE,WAAAA,EAAU,MAAM,OAAOC,EAAqBD,CAAS,CAAC,GAAG;AAAA;AAAA;AAAA;AAAA,GAM9EE,IAAqBR,EAAOS,CAAY;AAAA,WACnC,CAAC,EAAE,OAAAP,EAAA,MAAYA,EAAM,OAAO,OAAO;AAAA;AAAA;AAAA,YAGlC,CAAC,EAAE,OAAAA,EAAA,MAAYA,EAAM,OAAO,OAAO;AAAA;AAAA,GAIzCQ,IAAqBV,EAAOW,CAAI;AAAA;AAAA;AAAA;AAAA;AAAA,GAOhCC,IAAwBZ,EAAO;AAAA,WAC1B,CAAC,EAAE,OAAAE,EAAA,MAAYA,EAAM,OAAO,KAAK;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;"}
|
@@ -1,120 +0,0 @@
|
|
1
|
-
import { jsxs as y, jsx as a } from "react/jsx-runtime";
|
2
|
-
import { memo as A, useRef as S, useCallback as _, useEffect as l, useMemo as $ } from "react";
|
3
|
-
import H from "../../ui/image/image.js";
|
4
|
-
import M from "../../ui/layout/flex-view.js";
|
5
|
-
import x from "../../ui/separator/separator.js";
|
6
|
-
import d from "../../worksheet/constants/events.js";
|
7
|
-
import N from "../../worksheet/worksheet/hooks/use-learnosity.js";
|
8
|
-
import Q from "../../worksheet/worksheet/hooks/use-worksheet-data-helper.js";
|
9
|
-
import { getQuestionsFromItems as V } from "../../worksheet/worksheet/worksheet-helpers.js";
|
10
|
-
import { PuzzleQuestionWrapper as P, PuzzleContainer as R } from "./puzzle-app-styled.js";
|
11
|
-
const F = (u) => {
|
12
|
-
if (!u) return null;
|
13
|
-
const t = u.match(/<img[^>]+src="([^">]+)"/);
|
14
|
-
return t ? t[1] : null;
|
15
|
-
}, L = ({
|
16
|
-
worksheetData: u,
|
17
|
-
loggerRef: t,
|
18
|
-
onWorksheetErrored: n,
|
19
|
-
imageHue: I,
|
20
|
-
onLoaded: p
|
21
|
-
}) => {
|
22
|
-
const { signed_request: g, questions_signed_request: w } = u, z = S(null), {
|
23
|
-
loadingState: i,
|
24
|
-
data: o,
|
25
|
-
error: f
|
26
|
-
} = Q({
|
27
|
-
attemptId: void 0,
|
28
|
-
signedRequest: g,
|
29
|
-
loggerRef: t
|
30
|
-
}), E = _(
|
31
|
-
(s) => {
|
32
|
-
n({
|
33
|
-
code: s.code,
|
34
|
-
message: s.detail
|
35
|
-
});
|
36
|
-
},
|
37
|
-
[n]
|
38
|
-
), { learnosity: r } = N(w, E, t);
|
39
|
-
l(() => {
|
40
|
-
i === "error" && n({
|
41
|
-
message: f ?? "Error loading worksheet"
|
42
|
-
});
|
43
|
-
}, [i, n, f]), l(() => {
|
44
|
-
r && t.current(d.WORKSHEET_V3_LEARNOSITY_INITIALIZED);
|
45
|
-
}, [r, t]), l(() => {
|
46
|
-
r && i === "success" && p && (t.current(d.WORKSHEET_V3_READY), p());
|
47
|
-
}, [r, i, t, p]);
|
48
|
-
const m = $(() => i === "success" && (o != null && o.learnosityItems) ? (t.current(d.WORKSHEET_V3_READY), V(o.learnosityItems, {
|
49
|
-
sectioned: !1,
|
50
|
-
adaptive: !1
|
51
|
-
}).map((e) => ({
|
52
|
-
response_id: e.response_id,
|
53
|
-
type: e.type,
|
54
|
-
stimulus: e.stimulus,
|
55
|
-
template: e.template,
|
56
|
-
stimulus_review: e.stimulus_review,
|
57
|
-
options: e.options,
|
58
|
-
metadata: e.metadata,
|
59
|
-
validation: e.validation
|
60
|
-
// Add other properties as needed
|
61
|
-
}))) : [], [i, o, t]);
|
62
|
-
l(() => {
|
63
|
-
if (r && m.length > 0) {
|
64
|
-
const c = requestAnimationFrame(() => {
|
65
|
-
try {
|
66
|
-
r.renderMath("mathjax");
|
67
|
-
} catch (e) {
|
68
|
-
n({
|
69
|
-
message: `MathJax rendering failed: ${e instanceof Error ? e.message : "Unknown error"}`
|
70
|
-
});
|
71
|
-
}
|
72
|
-
});
|
73
|
-
return () => {
|
74
|
-
cancelAnimationFrame(c);
|
75
|
-
};
|
76
|
-
}
|
77
|
-
}, [r, n, m]);
|
78
|
-
const T = _((s) => {
|
79
|
-
const { stimulus: c = "", template: e = "", response_id: v } = s, h = F(c);
|
80
|
-
return /* @__PURE__ */ y(
|
81
|
-
M,
|
82
|
-
{
|
83
|
-
$background: "TRANSPARENT",
|
84
|
-
$alignItems: "center",
|
85
|
-
className: "puzzle-app-view-question-card",
|
86
|
-
children: [
|
87
|
-
h && /* @__PURE__ */ a(
|
88
|
-
H,
|
89
|
-
{
|
90
|
-
src: h,
|
91
|
-
alt: "Puzzle illustration",
|
92
|
-
width: 183,
|
93
|
-
height: 183,
|
94
|
-
withLoader: !0
|
95
|
-
}
|
96
|
-
),
|
97
|
-
/* @__PURE__ */ a(x, { heightX: 1 }),
|
98
|
-
e && /* @__PURE__ */ a(P, { children: /* @__PURE__ */ a("div", { dangerouslySetInnerHTML: { __html: e } }) })
|
99
|
-
]
|
100
|
-
},
|
101
|
-
v
|
102
|
-
);
|
103
|
-
}, []);
|
104
|
-
return m.length ? /* @__PURE__ */ a(
|
105
|
-
R,
|
106
|
-
{
|
107
|
-
ref: z,
|
108
|
-
$gapX: 1,
|
109
|
-
$gutterX: 1,
|
110
|
-
$imageHue: I,
|
111
|
-
$background: "WHITE_1",
|
112
|
-
className: "puzzle-app-view-container",
|
113
|
-
children: m.map((s) => /* @__PURE__ */ a("div", { children: T(s) }, `question-${s.response_id}`))
|
114
|
-
}
|
115
|
-
) : null;
|
116
|
-
}, U = A(L);
|
117
|
-
export {
|
118
|
-
U as default
|
119
|
-
};
|
120
|
-
//# sourceMappingURL=puzzle-app-view.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"puzzle-app-view.js","sources":["../../../../src/features/puzzles/app/puzzle-app-view.tsx"],"sourcesContent":["import type {\n ILearnosityError,\n ILearnosityQuestion,\n} from '../../worksheet/worksheet/worksheet-types';\nimport type { IPuzzleAppViewProps } from './puzzle-app-types';\nimport type { FC } from 'react';\n\nimport { memo, useCallback, useEffect, useMemo, useRef } from 'react';\n\nimport Image from '../../ui/image/image';\nimport FlexView from '../../ui/layout/flex-view';\nimport Separator from '../../ui/separator/separator';\nimport EVENTS from '../../worksheet/constants/events';\nimport useLearnosity from '../../worksheet/worksheet/hooks/use-learnosity';\nimport useWorksheetDataHelper from '../../worksheet/worksheet/hooks/use-worksheet-data-helper';\nimport { getQuestionsFromItems } from '../../worksheet/worksheet/worksheet-helpers';\nimport * as Styled from './puzzle-app-styled';\n\nconst extractImageFromHTML = (htmlString: string) => {\n if (!htmlString) return null;\n\n const imgMatch = htmlString.match(/<img[^>]+src=\"([^\">]+)\"/);\n\n return imgMatch ? imgMatch[1] : null;\n};\n\nconst PuzzleAppView: FC<IPuzzleAppViewProps> = ({\n worksheetData,\n loggerRef,\n onWorksheetErrored,\n imageHue,\n onLoaded,\n}) => {\n const { signed_request: itemsSignedRequest, questions_signed_request: questionSignedRequest } =\n worksheetData;\n\n // Ref for the container to trigger MathJax rendering\n const containerRef = useRef<HTMLDivElement>(null);\n\n // Get Learnosity items using the signed_request (not questions_signed_request)\n const {\n loadingState,\n data: learnosityData,\n error: worksheetError,\n } = useWorksheetDataHelper({\n attemptId: undefined,\n signedRequest: itemsSignedRequest,\n loggerRef,\n });\n\n const onLearnosityErrored = useCallback(\n (err: ILearnosityError) => {\n onWorksheetErrored({\n code: err.code,\n message: err.detail,\n });\n },\n [onWorksheetErrored],\n );\n\n // Initialize Learnosity using questions_signed_request (needed for interactive questions)\n const { learnosity } = useLearnosity(questionSignedRequest, onLearnosityErrored, loggerRef);\n\n useEffect(() => {\n if (loadingState === 'error') {\n onWorksheetErrored({\n message: worksheetError ?? 'Error loading worksheet',\n });\n }\n }, [loadingState, onWorksheetErrored, worksheetError]);\n\n // Log when learnosity is ready for future interactive features\n useEffect(() => {\n if (learnosity) {\n loggerRef.current(EVENTS.WORKSHEET_V3_LEARNOSITY_INITIALIZED);\n }\n }, [learnosity, loggerRef]);\n\n useEffect(() => {\n if (learnosity && loadingState === 'success' && onLoaded) {\n loggerRef.current(EVENTS.WORKSHEET_V3_READY);\n onLoaded();\n }\n }, [learnosity, loadingState, loggerRef, onLoaded]);\n\n // Memoize questions processing to prevent re-render loops\n const questions = useMemo(() => {\n // Extract questions from Learnosity items when data is loaded successfully\n if (loadingState === 'success' && learnosityData?.learnosityItems) {\n loggerRef.current(EVENTS.WORKSHEET_V3_READY);\n\n // Convert learnosityItems to questions using the worksheet helper\n const worksheetQuestions = getQuestionsFromItems(learnosityData.learnosityItems, {\n sectioned: false,\n adaptive: false,\n });\n\n // Extract just the Learnosity questions from worksheet questions\n const learnosityQuestions: ILearnosityQuestion[] = worksheetQuestions.map(q => ({\n response_id: q.response_id,\n type: q.type,\n stimulus: q.stimulus,\n template: q.template,\n stimulus_review: q.stimulus_review,\n options: q.options,\n metadata: q.metadata,\n validation: q.validation,\n // Add other properties as needed\n }));\n\n return learnosityQuestions;\n }\n\n return [];\n }, [loadingState, learnosityData, loggerRef]);\n\n // Force MathJax rendering after questions are loaded and rendered\n // Similar to how useLearnosityAppend does it\n useEffect(() => {\n if (learnosity && questions.length > 0) {\n // Use requestAnimationFrame to ensure DOM is updated before rendering math\n const renderMath = () => {\n try {\n learnosity.renderMath('mathjax');\n } catch (error) {\n onWorksheetErrored({\n message: `MathJax rendering failed: ${\n error instanceof Error ? error.message : 'Unknown error'\n }`,\n });\n }\n };\n\n const animationId = requestAnimationFrame(renderMath);\n\n return () => {\n cancelAnimationFrame(animationId);\n };\n }\n }, [learnosity, onWorksheetErrored, questions]);\n\n const renderQuestionContent = useCallback((question: ILearnosityQuestion) => {\n const { stimulus = '', template = '', response_id: responseId } = question;\n const imageUrl = extractImageFromHTML(stimulus);\n\n return (\n <FlexView\n $background=\"TRANSPARENT\"\n key={responseId}\n $alignItems=\"center\"\n className=\"puzzle-app-view-question-card\"\n >\n {/* Main Image or Interactive Content */}\n {imageUrl && (\n <Image\n src={imageUrl}\n alt=\"Puzzle illustration\"\n width={183}\n height={183}\n withLoader={true}\n />\n )}\n\n <Separator heightX={1} />\n\n {/* Question HTML Content */}\n {template && (\n <Styled.PuzzleQuestionWrapper>\n <div dangerouslySetInnerHTML={{ __html: template }} />\n </Styled.PuzzleQuestionWrapper>\n )}\n </FlexView>\n );\n }, []);\n\n if (!questions.length) return null;\n\n return (\n <Styled.PuzzleContainer\n ref={containerRef}\n $gapX={1}\n $gutterX={1}\n $imageHue={imageHue}\n $background=\"WHITE_1\"\n className=\"puzzle-app-view-container\"\n >\n {questions.map(question => (\n <div key={`question-${question.response_id}`}>{renderQuestionContent(question)}</div>\n ))}\n </Styled.PuzzleContainer>\n );\n};\n\nexport default memo(PuzzleAppView);\n"],"names":["extractImageFromHTML","htmlString","imgMatch","PuzzleAppView","worksheetData","loggerRef","onWorksheetErrored","imageHue","onLoaded","itemsSignedRequest","questionSignedRequest","containerRef","useRef","loadingState","learnosityData","worksheetError","useWorksheetDataHelper","onLearnosityErrored","useCallback","err","learnosity","useLearnosity","useEffect","EVENTS","questions","useMemo","getQuestionsFromItems","q","animationId","error","renderQuestionContent","question","stimulus","template","responseId","imageUrl","jsxs","FlexView","jsx","Image","Separator","Styled.PuzzleQuestionWrapper","Styled.PuzzleContainer","PuzzleAppView$1","memo"],"mappings":";;;;;;;;;;AAkBA,MAAM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AA;AAAA,UACd;AAAA,UAGF,gBAAAG,EAACE,GAAU,EAAA,SAAS,EAAG,CAAA;AAAA,UAGtBP,KACC,gBAAAK,EAACG,GAAA,EACC,UAAA,gBAAAH,EAAC,OAAI,EAAA,yBAAyB,EAAE,QAAQL,EAAS,EAAA,CAAG,EACtD,CAAA;AAAA,QAAA;AAAA,MAAA;AAAA,MArBGC;AAAA,IAAA;AAAA,EAyBX,GAAG,CAAE,CAAA;AAED,SAACV,EAAU,SAGb,gBAAAc;AAAA,IAACI;AAAAA,IAAA;AAAA,MACC,KAAK/B;AAAA,MACL,OAAO;AAAA,MACP,UAAU;AAAA,MACV,WAAWJ;AAAA,MACX,aAAY;AAAA,MACZ,WAAU;AAAA,MAET,UAAUiB,EAAA,IAAI,CACbO,MAAA,gBAAAO,EAAC,OAA8C,EAAA,UAAAR,EAAsBC,CAAQ,EAAA,GAAnE,YAAYA,EAAS,WAAW,EAAqC,CAChF;AAAA,IAAA;AAAA,EAAA,IAbyB;AAgBhC,GAEeY,IAAAC,EAAKzC,CAAa;"}
|
@@ -1,62 +0,0 @@
|
|
1
|
-
import { jsx as e, jsxs as o, Fragment as W } from "react/jsx-runtime";
|
2
|
-
import { memo as v, useState as h, useRef as P, useCallback as n, useEffect as R } from "react";
|
3
|
-
import y from "../../ui/error/error.js";
|
4
|
-
import d from "../../ui/layout/flex-view.js";
|
5
|
-
import F from "../../ui/loader/app-loader/app-loader.js";
|
6
|
-
import p from "../../ui/text/text.js";
|
7
|
-
import { usePreviewWorksheetGet as I } from "../../worksheet/worksheet-preview/api/get-preview-worksheet.js";
|
8
|
-
import { PuzzleAppWrapper as L, StyledFeedbackText as T, StyledHintFillIcon as D } from "./puzzle-app-styled.js";
|
9
|
-
import G from "./puzzle-app-view.js";
|
10
|
-
const S = ({ itemRef: s, title: m, imageHue: i, feedbackComments: l, tip: f }) => {
|
11
|
-
const [u, g] = h(), [r, $] = h(!1), { isProcessing: k, get: a, data: c, error: w } = I(), z = P(() => null), A = f || "Celebrate persistence more than correct answers - it's a life skill worth building.", t = n(() => {
|
12
|
-
a("test", {
|
13
|
-
action: "review",
|
14
|
-
node_type: "PUZZLE_CARD",
|
15
|
-
items: [s]
|
16
|
-
});
|
17
|
-
}, [a, s]);
|
18
|
-
R(() => {
|
19
|
-
t();
|
20
|
-
}, [t]);
|
21
|
-
const b = n((E) => {
|
22
|
-
g(E.message);
|
23
|
-
}, []), x = n(() => {
|
24
|
-
$(!0);
|
25
|
-
}, []);
|
26
|
-
return u || w ? /* @__PURE__ */ e(y, { height: "100vh", onTryAgain: t }) : k ? /* @__PURE__ */ e(F, { height: "100vh" }) : /* @__PURE__ */ o(
|
27
|
-
L,
|
28
|
-
{
|
29
|
-
className: "puzzle-app-container",
|
30
|
-
$background: `${i}_2`,
|
31
|
-
$alignItems: "center",
|
32
|
-
$flexGapX: 1,
|
33
|
-
$gutterX: 1,
|
34
|
-
$visible: r,
|
35
|
-
$height: "100vh",
|
36
|
-
children: [
|
37
|
-
r && /* @__PURE__ */ e(p, { $renderAs: "ab1-bold", children: m }),
|
38
|
-
c && /* @__PURE__ */ e(
|
39
|
-
G,
|
40
|
-
{
|
41
|
-
onWorksheetErrored: b,
|
42
|
-
worksheetData: c,
|
43
|
-
loggerRef: z,
|
44
|
-
imageHue: i,
|
45
|
-
onLoaded: x
|
46
|
-
}
|
47
|
-
),
|
48
|
-
r && /* @__PURE__ */ e(W, { children: l ? /* @__PURE__ */ o(T, { $renderAs: "ab2", children: [
|
49
|
-
/* @__PURE__ */ e("span", { children: "Tutor Remark:" }),
|
50
|
-
l
|
51
|
-
] }) : /* @__PURE__ */ o(d, { $flexDirection: "row", $alignItems: "center", $flexGap: 8, children: [
|
52
|
-
/* @__PURE__ */ e(d, { $width: 24, $height: 24, children: /* @__PURE__ */ e(D, {}) }),
|
53
|
-
/* @__PURE__ */ e(p, { $renderAs: "ab2", children: A })
|
54
|
-
] }) })
|
55
|
-
]
|
56
|
-
}
|
57
|
-
);
|
58
|
-
}, B = v(S);
|
59
|
-
export {
|
60
|
-
B as default
|
61
|
-
};
|
62
|
-
//# sourceMappingURL=puzzle-app.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"puzzle-app.js","sources":["../../../../src/features/puzzles/app/puzzle-app.tsx"],"sourcesContent":["import type { IPuzzleAppProps } from './puzzle-app-types';\nimport type { FC } from 'react';\n\nimport { memo, useCallback, useEffect, useRef, useState } from 'react';\n\nimport Error from '../../ui/error/error';\nimport FlexView from '../../ui/layout/flex-view';\nimport AppLoader from '../../ui/loader/app-loader/app-loader';\nimport Text from '../../ui/text/text';\nimport { usePreviewWorksheetGet } from '../../worksheet/worksheet-preview/api/get-preview-worksheet';\nimport * as Styled from './puzzle-app-styled';\nimport PuzzleAppView from './puzzle-app-view';\n\nconst PuzzleApp: FC<IPuzzleAppProps> = ({ itemRef, title, imageHue, feedbackComments, tip }) => {\n const [error, setError] = useState<string>();\n const [worksheetRendered, setWorksheetRendered] = useState<boolean>(false);\n\n const { isProcessing, get, data: worksheetData, error: fetchError } = usePreviewWorksheetGet();\n const loggerRef = useRef(() => null);\n\n const tipInfo =\n tip || `Celebrate persistence more than correct answers - it's a life skill worth building.`;\n\n const fetchWorksheet = useCallback(() => {\n get('test', {\n action: 'review',\n node_type: 'PUZZLE_CARD',\n items: [itemRef],\n });\n }, [get, itemRef]);\n\n useEffect(() => {\n fetchWorksheet();\n }, [fetchWorksheet]);\n\n const handleWorksheetErrored = useCallback((err: { code?: number; message: string }) => {\n setError(err.message);\n }, []);\n\n const handleWorksheetLoaded = useCallback(() => {\n setWorksheetRendered(true);\n }, []);\n\n if (error || fetchError) {\n return <Error height=\"100vh\" onTryAgain={fetchWorksheet} />;\n }\n\n if (isProcessing) {\n return <AppLoader height=\"100vh\" />;\n }\n\n return (\n <Styled.PuzzleAppWrapper\n className=\"puzzle-app-container\"\n $background={`${imageHue}_2`}\n $alignItems=\"center\"\n $flexGapX={1}\n $gutterX={1}\n $visible={worksheetRendered}\n $height=\"100vh\"\n >\n {worksheetRendered && <Text $renderAs=\"ab1-bold\">{title}</Text>}\n\n {worksheetData && (\n <PuzzleAppView\n onWorksheetErrored={handleWorksheetErrored}\n worksheetData={worksheetData}\n loggerRef={loggerRef}\n imageHue={imageHue}\n onLoaded={handleWorksheetLoaded}\n />\n )}\n\n {worksheetRendered && (\n <>\n {feedbackComments ? (\n <Styled.StyledFeedbackText $renderAs=\"ab2\">\n <span>Tutor Remark:</span>\n {feedbackComments}\n </Styled.StyledFeedbackText>\n ) : (\n <FlexView $flexDirection=\"row\" $alignItems=\"center\" $flexGap={8}>\n <FlexView $width={24} $height={24}>\n <Styled.StyledHintFillIcon />\n </FlexView>\n <Text $renderAs=\"ab2\">{tipInfo}</Text>\n </FlexView>\n )}\n </>\n )}\n </Styled.PuzzleAppWrapper>\n );\n};\n\nexport default memo(PuzzleApp);\n"],"names":["PuzzleApp","itemRef","title","imageHue","feedbackComments","tip","error","setError","useState","worksheetRendered","setWorksheetRendered","isProcessing","get","worksheetData","fetchError","usePreviewWorksheetGet","loggerRef","useRef","tipInfo","fetchWorksheet","useCallback","useEffect","handleWorksheetErrored","err","handleWorksheetLoaded","jsx","Error","AppLoader","jsxs","Styled.PuzzleAppWrapper","Text","PuzzleAppView","Styled.StyledFeedbackText","FlexView","Styled.StyledHintFillIcon","puzzleApp","memo"],"mappings":";;;;;;;;;AAaA,MAAMA,IAAiC,CAAC,EAAE,SAAAC,GAAS,OAAAC,GAAO,UAAAC,GAAU,kBAAAC,GAAkB,KAAAC,QAAU;AAC9F,QAAM,CAACC,GAAOC,CAAQ,IAAIC,EAAiB,GACrC,CAACC,GAAmBC,CAAoB,IAAIF,EAAkB,EAAK,GAEnE,EAAE,cAAAG,GAAc,KAAAC,GAAK,MAAMC,GAAe,OAAOC,MAAeC,KAChEC,IAAYC,EAAO,MAAM,IAAI,GAE7BC,IACJb,KAAO,uFAEHc,IAAiBC,EAAY,MAAM;AACvC,IAAAR,EAAI,QAAQ;AAAA,MACV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A,EAAS,QAAQ,IAAI,SAAS,IAC7B,UAAC,gBAAAR,EAAAS,GAAA,CAAA,CAA0B,EAC7B,CAAA;AAAA,UACC,gBAAAT,EAAAK,GAAA,EAAK,WAAU,OAAO,UAAQZ,GAAA;AAAA,QAAA,EAAA,CACjC,EAEJ,CAAA;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAIR,GAEeiB,IAAAC,EAAKpC,CAAS;"}
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"arrow-tooltip-constants.js","sources":["../../../../src/features/ui/arrow-tooltip/arrow-tooltip-constants.ts"],"sourcesContent":["export const DEFAULT_ARROW_SIZE = 8;\nexport const THROTTLE_DURATION = 100;\n"],"names":["DEFAULT_ARROW_SIZE","THROTTLE_DURATION"],"mappings":"AAAO,MAAMA,IAAqB,GACrBC,IAAoB;"}
|
@@ -1,63 +0,0 @@
|
|
1
|
-
import w from "styled-components";
|
2
|
-
import y from "../../layout/flex-view.js";
|
3
|
-
import { arrowPosition as T, tooltipPosition as k, animateToolTip as m } from "../arrow-tooltip-util.js";
|
4
|
-
const P = w(y)(({
|
5
|
-
theme: o,
|
6
|
-
$arrowColor: r,
|
7
|
-
$arrowSize: t,
|
8
|
-
$arrowXCoOrdinates: c,
|
9
|
-
$arrowYCoOrdinates: d,
|
10
|
-
$borderColor: p,
|
11
|
-
$isAnimated: x,
|
12
|
-
$position: n,
|
13
|
-
$renderAs: s,
|
14
|
-
$tooltipCoOrdinates: e,
|
15
|
-
$tooltipOffset: f,
|
16
|
-
$tooltipXCoOrdinates: g,
|
17
|
-
$tooltipYCoOrdinates: u,
|
18
|
-
$zIndex: C,
|
19
|
-
$backgroundColor: O
|
20
|
-
}) => {
|
21
|
-
const { gutter: l } = o.layout, { REAL_BLACK_15: $ } = o.colors, { tooltipVariants: a } = o.arrowTooltip;
|
22
|
-
let { backgroundColorName: i } = a[s];
|
23
|
-
const { textColorName: b } = a[s];
|
24
|
-
return i = O || i, `
|
25
|
-
position: fixed;
|
26
|
-
z-index: ${C || 1};
|
27
|
-
padding: ${l * 0.25}px ${l * 0.5}px;
|
28
|
-
color: ${b};
|
29
|
-
box-shadow: 0px 2px 15px 0px ${$};
|
30
|
-
background-color: ${o.colors[i]};
|
31
|
-
border: 1px solid ${p ? o.colors[p] : "transparent"};
|
32
|
-
|
33
|
-
&::after {
|
34
|
-
content: '';
|
35
|
-
position: absolute;
|
36
|
-
height: ${t}px;
|
37
|
-
width: ${t}px;
|
38
|
-
clip-path: polygon(0% 0%, 100% 100%, 0% 100%);
|
39
|
-
background-color: ${r ? o.colors[r] : o.colors[i]};
|
40
|
-
${T({
|
41
|
-
position: n,
|
42
|
-
arrowXCoOrdinates: c,
|
43
|
-
arrowYCoOrdinates: d,
|
44
|
-
arrowSize: t
|
45
|
-
})};
|
46
|
-
}
|
47
|
-
|
48
|
-
${k({
|
49
|
-
position: n,
|
50
|
-
arrowSize: t,
|
51
|
-
tooltipCoOrdinates: e,
|
52
|
-
tooltipOffset: f,
|
53
|
-
tooltipXCoOrdinates: g,
|
54
|
-
tooltipYCoOrdinates: u
|
55
|
-
})};
|
56
|
-
|
57
|
-
${m(x)};
|
58
|
-
`;
|
59
|
-
});
|
60
|
-
export {
|
61
|
-
P as TooltipBody
|
62
|
-
};
|
63
|
-
//# sourceMappingURL=tooltip-body-styled.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"tooltip-body-styled.js","sources":["../../../../../src/features/ui/arrow-tooltip/comps/tooltip-body-styled.ts"],"sourcesContent":["import type { ITooltipBodyProps } from './tooltip-body-types';\n\nimport styled from 'styled-components';\n\nimport FlexView from '../../layout/flex-view';\nimport { animateToolTip, arrowPosition, tooltipPosition } from '../arrow-tooltip-util';\n\nexport const TooltipBody = styled(FlexView)<ITooltipBodyProps>(({\n theme,\n $arrowColor,\n $arrowSize,\n $arrowXCoOrdinates,\n $arrowYCoOrdinates,\n $borderColor,\n $isAnimated,\n $position,\n $renderAs,\n $tooltipCoOrdinates,\n $tooltipOffset,\n $tooltipXCoOrdinates,\n $tooltipYCoOrdinates,\n $zIndex,\n $backgroundColor,\n}) => {\n const { gutter } = theme.layout;\n const { REAL_BLACK_15 } = theme.colors;\n const { tooltipVariants } = theme.arrowTooltip;\n let { backgroundColorName } = tooltipVariants[$renderAs];\n const { textColorName } = tooltipVariants[$renderAs];\n\n backgroundColorName = $backgroundColor || backgroundColorName;\n\n return `\n position: fixed;\n z-index: ${$zIndex || 1};\n padding: ${gutter * 0.25}px ${gutter * 0.5}px;\n color: ${textColorName};\n box-shadow: 0px 2px 15px 0px ${REAL_BLACK_15};\n background-color: ${theme.colors[backgroundColorName]};\n border: 1px solid ${$borderColor ? theme.colors[$borderColor] : 'transparent'};\n\n &::after {\n content: '';\n position: absolute;\n height: ${$arrowSize}px;\n width: ${$arrowSize}px;\n clip-path: polygon(0% 0%, 100% 100%, 0% 100%);\n background-color: ${\n $arrowColor ? theme.colors[$arrowColor] : theme.colors[backgroundColorName]\n };\n ${arrowPosition({\n position: $position,\n arrowXCoOrdinates: $arrowXCoOrdinates,\n arrowYCoOrdinates: $arrowYCoOrdinates,\n arrowSize: $arrowSize,\n })};\n }\n\n ${tooltipPosition({\n position: $position,\n arrowSize: $arrowSize,\n tooltipCoOrdinates: $tooltipCoOrdinates,\n tooltipOffset: $tooltipOffset,\n tooltipXCoOrdinates: $tooltipXCoOrdinates,\n tooltipYCoOrdinates: $tooltipYCoOrdinates,\n })};\n\n ${animateToolTip($isAnimated)};\n `;\n});\n"],"names":["TooltipBody","styled","FlexView","theme","$arrowColor","$arrowSize","$arrowXCoOrdinates","$arrowYCoOrdinates","$borderColor","$isAnimated","$position","$renderAs","$tooltipCoOrdinates","$tooltipOffset","$tooltipXCoOrdinates","$tooltipYCoOrdinates","$zIndex","$backgroundColor","gutter","REAL_BLACK_15","tooltipVariants","backgroundColorName","textColorName","arrowPosition","tooltipPosition","animateToolTip"],"mappings":";;;AAOO,MAAMA,IAAcC,EAAOC,CAAQ,EAA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AC;AAAA;AAAA,MAEAU,EAAehB,CAAW,CAAC;AAAA;AAEjC,CAAC;"}
|
@@ -1,21 +0,0 @@
|
|
1
|
-
import { jsx as t } from "react/jsx-runtime";
|
2
|
-
import { memo as i } from "react";
|
3
|
-
import { useTheme as n } from "styled-components";
|
4
|
-
import l from "../../text/text.js";
|
5
|
-
import { TooltipBody as m } from "./tooltip-body-styled.js";
|
6
|
-
const d = (o) => {
|
7
|
-
const { arrowTooltip: r } = n(), { tooltipVariants: e } = r;
|
8
|
-
return /* @__PURE__ */ t(m, { ...o, children: typeof o.children == "string" ? /* @__PURE__ */ t(
|
9
|
-
l,
|
10
|
-
{
|
11
|
-
$renderAs: o.textVariant || "body3",
|
12
|
-
$color: e[o.$renderAs].textColorName,
|
13
|
-
$align: "center",
|
14
|
-
children: o.children
|
15
|
-
}
|
16
|
-
) : o.children });
|
17
|
-
}, h = i(d);
|
18
|
-
export {
|
19
|
-
h as default
|
20
|
-
};
|
21
|
-
//# sourceMappingURL=tooltip-body.js.map
|
@@ -1 +0,0 @@
|
|
1
|
-
{"version":3,"file":"tooltip-body.js","sources":["../../../../../src/features/ui/arrow-tooltip/comps/tooltip-body.tsx"],"sourcesContent":["import type { ITooltipBodyProps } from './tooltip-body-types';\n\nimport React, { memo } from 'react';\nimport { useTheme } from 'styled-components';\n\nimport Text from '../../text/text';\nimport * as Styled from './tooltip-body-styled';\n\nconst TooltipBody: React.FC<ITooltipBodyProps> = props => {\n const { arrowTooltip } = useTheme();\n const { tooltipVariants } = arrowTooltip;\n\n return (\n <Styled.TooltipBody {...props}>\n {typeof props.children === 'string' ? (\n <Text\n $renderAs={props.textVariant || 'body3'}\n $color={tooltipVariants[props.$renderAs].textColorName}\n $align=\"center\"\n >\n {props.children}\n </Text>\n ) : (\n props.children\n )}\n </Styled.TooltipBody>\n );\n};\n\nexport default memo(TooltipBody);\n"],"names":["TooltipBody","props","arrowTooltip","useTheme","tooltipVariants","jsx","Styled.TooltipBody","Text","TooltipBody$1","memo"],"mappings":";;;;;AAQA,MAAMA,IAA2C,CAASC,MAAA;AAClD,QAAA,EAAE,cAAAC,MAAiBC,KACnB,EAAE,iBAAAC,EAAoB,IAAAF;AAG1B,SAAA,gBAAAG,EAACC,GAAA,EAAoB,GAAGL,GACrB,UAAA,OAAOA,EAAM,YAAa,WACzB,gBAAAI;AAAA,IAACE;AAAA,IAAA;AAAA,MACC,WAAWN,EAAM,eAAe;AAAA,MAChC,QAAQG,EAAgBH,EAAM,SAAS,EAAE;AAAA,MACzC,QAAO;AAAA,MAEN,UAAMA,EAAA;AAAA,IAAA;AAAA,EAAA,IAGTA,EAAM,SAEV,CAAA;AAEJ,GAEeO,IAAAC,EAAKT,CAAW;"}
|