@cuemath/leap 2.8.21-rj-16 → 2.8.21
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/images/images.js +0 -12
- package/dist/assets/images/images.js.map +1 -1
- package/dist/features/chapters/chapter/chapter.js +43 -45
- package/dist/features/chapters/chapter/chapter.js.map +1 -1
- package/dist/features/chapters/chapter/comps/core-lessons/core-lessons.js +21 -23
- package/dist/features/chapters/chapter/comps/core-lessons/core-lessons.js.map +1 -1
- package/dist/features/circle-games/game-launcher/use-game-launcher-journey/use-game-launcher-journey.js +3 -3
- package/dist/features/circle-games/game-launcher/use-game-launcher-journey/use-game-launcher-journey.js.map +1 -1
- package/dist/features/milestone/constants.js +18 -53
- package/dist/features/milestone/constants.js.map +1 -1
- package/dist/features/milestone/create/comps/chapters-selection-step/chapters-selection-step-styled.js +4 -16
- package/dist/features/milestone/create/comps/chapters-selection-step/chapters-selection-step-styled.js.map +1 -1
- package/dist/features/milestone/create/milestone-create-constants.js.map +1 -1
- package/dist/features/milestone/create/milestone-create-container.js +47 -56
- package/dist/features/milestone/create/milestone-create-container.js.map +1 -1
- package/dist/features/milestone/create/milestone-create-helpers.js +113 -132
- package/dist/features/milestone/create/milestone-create-helpers.js.map +1 -1
- package/dist/features/milestone/create/milestone-create-hooks.js +90 -92
- package/dist/features/milestone/create/milestone-create-hooks.js.map +1 -1
- package/dist/features/milestone/create/milestone-create-styled.js +20 -34
- package/dist/features/milestone/create/milestone-create-styled.js.map +1 -1
- package/dist/features/milestone/create/milestone-create.js +53 -72
- package/dist/features/milestone/create/milestone-create.js.map +1 -1
- package/dist/features/milestone/create/submit-modal/use-submit-milestone.js +46 -53
- package/dist/features/milestone/create/submit-modal/use-submit-milestone.js.map +1 -1
- package/dist/features/milestone/create/utils/index.js.map +1 -1
- package/dist/features/milestone/edit/comps/delete-milestone/styled.js +8 -11
- package/dist/features/milestone/edit/comps/delete-milestone/styled.js.map +1 -1
- package/dist/features/milestone/edit/comps/edit-milestone-modal/edit-milestone.js +82 -79
- package/dist/features/milestone/edit/comps/edit-milestone-modal/edit-milestone.js.map +1 -1
- package/dist/features/milestone/edit/comps/edit-milestone-modal/index.js +112 -136
- package/dist/features/milestone/edit/comps/edit-milestone-modal/index.js.map +1 -1
- package/dist/features/milestone/{drafts/goal-edit → edit/goal-drafts}/goal-draft-edit-container.js +22 -24
- package/dist/features/milestone/edit/goal-drafts/goal-draft-edit-container.js.map +1 -0
- package/dist/features/milestone/edit/goal-drafts/goal-draft-edit-helpers.js +17 -0
- package/dist/features/milestone/edit/goal-drafts/goal-draft-edit-helpers.js.map +1 -0
- package/dist/features/milestone/edit/goal-edit-helpers.js +5 -6
- package/dist/features/milestone/edit/goal-edit-helpers.js.map +1 -1
- package/dist/features/milestone/edit/milestone-edit-helpers.js +16 -17
- package/dist/features/milestone/edit/milestone-edit-helpers.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-list.js +46 -48
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-list.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list-container.js +58 -60
- package/dist/features/milestone/milestone-list-container/milestone-list-container.js.map +1 -1
- package/dist/features/milestone/outcome/comps/past-milestone/past-milestone-container.js +39 -41
- package/dist/features/milestone/outcome/comps/past-milestone/past-milestone-container.js.map +1 -1
- package/dist/index.d.ts +7 -125
- package/dist/index.js +244 -258
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/constants/urls.js +0 -5
- package/dist/constants/urls.js.map +0 -1
- package/dist/features/milestone/drafts/create/draft-create-container.js +0 -54
- package/dist/features/milestone/drafts/create/draft-create-container.js.map +0 -1
- package/dist/features/milestone/drafts/edit/draft-edit-container.js +0 -77
- package/dist/features/milestone/drafts/edit/draft-edit-container.js.map +0 -1
- package/dist/features/milestone/drafts/edit/draft-edit-helpers.js +0 -69
- package/dist/features/milestone/drafts/edit/draft-edit-helpers.js.map +0 -1
- package/dist/features/milestone/drafts/goal-edit/goal-draft-edit-container.js.map +0 -1
- package/dist/features/milestone/drafts/review/draft-review-container.js +0 -76
- package/dist/features/milestone/drafts/review/draft-review-container.js.map +0 -1
- package/dist/features/milestone/edit/comps/delete-milestone/add-remove-nudge.js +0 -48
- package/dist/features/milestone/edit/comps/delete-milestone/add-remove-nudge.js.map +0 -1
- package/dist/features/milestone/edit/comps/edit-milestone-modal/edit-milestone-modal-styled.js +0 -23
- package/dist/features/milestone/edit/comps/edit-milestone-modal/edit-milestone-modal-styled.js.map +0 -1
- package/dist/features/milestone/edit/comps/edit-milestone-modal/share-screen.js +0 -68
- package/dist/features/milestone/edit/comps/edit-milestone-modal/share-screen.js.map +0 -1
- package/dist/features/milestone/help-modals/index.js +0 -22
- package/dist/features/milestone/help-modals/index.js.map +0 -1
- package/dist/features/milestone/help-modals/milestone-lesson.js +0 -17
- package/dist/features/milestone/help-modals/milestone-lesson.js.map +0 -1
- package/dist/features/milestone/help-modals/milestone-list.js +0 -17
- package/dist/features/milestone/help-modals/milestone-list.js.map +0 -1
- package/dist/features/milestone/help-modals/utils.js +0 -20
- package/dist/features/milestone/help-modals/utils.js.map +0 -1
- package/dist/features/milestone/intro-modal/index.js +0 -24
- package/dist/features/milestone/intro-modal/index.js.map +0 -1
- package/dist/features/notifications/api/notification.js +0 -13
- package/dist/features/notifications/api/notification.js.map +0 -1
- package/dist/features/notifications/use-student-journey.js +0 -20
- package/dist/features/notifications/use-student-journey.js.map +0 -1
- package/dist/features/sheets/constants/lessons.js +0 -28
- package/dist/features/sheets/constants/lessons.js.map +0 -1
- package/dist/features/ui/modals/info-modal/index.js +0 -117
- package/dist/features/ui/modals/info-modal/index.js.map +0 -1
- package/dist/static/goal_creation_helper.d45e4d58.png +0 -0
- package/dist/static/help_banner1.ddb0ef0f.png +0 -0
- package/dist/static/help_banner2.40979ed0.png +0 -0
- package/dist/static/help_banner3.532099c7.png +0 -0
- package/dist/static/help_banner4.90a6fd4d.png +0 -0
- package/dist/static/help_banner5.2a9efb39.png +0 -0
- package/dist/static/help_banner6.94fe9589.png +0 -0
- package/dist/static/milestone_intro_slide1.1537493e.png +0 -0
- package/dist/static/milestone_intro_slide2.b791c159.png +0 -0
- package/dist/static/milestone_intro_slide3.f7d63a11.png +0 -0
- package/dist/static/milestone_intro_slide4.f8da4e46.png +0 -0
- package/dist/static/milestone_intro_slide5.ea5d12d2.png +0 -0
@@ -14,23 +14,11 @@ const t = window.VITE_PUBLIC_URL ? window.VITE_PUBLIC_URL : "/", a = {
|
|
14
14
|
DVI: `${t}static/dvi.fc7b32a5.png`,
|
15
15
|
EKA: `${t}static/eka.b10a06fa.png`,
|
16
16
|
EMPTY_MIX_TESTS: `${t}static/empty_mix_tests.1d251f07.png`,
|
17
|
-
GOAL_CREATION_HELPER: `${t}static/goal_creation_helper.d45e4d58.png`,
|
18
17
|
GREAT: `${t}static/great.2a5dcc34.png`,
|
19
|
-
HELP_BANNER1: `${t}static/help_banner1.ddb0ef0f.png`,
|
20
|
-
HELP_BANNER2: `${t}static/help_banner2.40979ed0.png`,
|
21
|
-
HELP_BANNER3: `${t}static/help_banner3.532099c7.png`,
|
22
|
-
HELP_BANNER4: `${t}static/help_banner4.90a6fd4d.png`,
|
23
|
-
HELP_BANNER5: `${t}static/help_banner5.2a9efb39.png`,
|
24
|
-
HELP_BANNER6: `${t}static/help_banner6.94fe9589.png`,
|
25
18
|
HEXO: `${t}static/hexo.eab4b9f5.png`,
|
26
19
|
KUDOS: `${t}static/kudos.b7e2aeb6.png`,
|
27
20
|
LEARNING_PLAN: `${t}static/learning-plan.72d64a61.png`,
|
28
21
|
LESSON_OVERVIEW_BANNER: `${t}static/lesson-overview-banner.f5404af6.png`,
|
29
|
-
MILESTONE_INTRO_SLIDE1: `${t}static/milestone_intro_slide1.1537493e.png`,
|
30
|
-
MILESTONE_INTRO_SLIDE2: `${t}static/milestone_intro_slide2.b791c159.png`,
|
31
|
-
MILESTONE_INTRO_SLIDE3: `${t}static/milestone_intro_slide3.f7d63a11.png`,
|
32
|
-
MILESTONE_INTRO_SLIDE4: `${t}static/milestone_intro_slide4.f8da4e46.png`,
|
33
|
-
MILESTONE_INTRO_SLIDE5: `${t}static/milestone_intro_slide5.ea5d12d2.png`,
|
34
22
|
NO_INFO: `${t}static/no-info.f4bfe437.png`,
|
35
23
|
OCTO: `${t}static/octo.3020bd93.png`,
|
36
24
|
PLAYSTORE: `${t}static/playstore.9beb7c15.png`,
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"images.js","sources":["../../../src/assets/images/images.ts"],"sourcesContent":["const PREFIX = window.VITE_PUBLIC_URL ? window.VITE_PUBLIC_URL : '/';\n\n// Must be alphabetical order\nconst IMAGES = {\n ACHIEVEMENT_BG: `${PREFIX}static/achievement_bg.0d0555ac.png`,\n APPSTORE: `${PREFIX}static/appstore.4c121cf5.png`,\n ASHTA: `${PREFIX}static/ashta.0d3926b2.png`,\n AWESOME: `${PREFIX}static/awesome.8e1cf046.png`,\n BADGE_SUCCESS: `${PREFIX}static/badge_success.2f6c8e65.png`,\n BG_EMPTY_RESOURCES: `${PREFIX}static/bg_empty_resources.63b187fd.png`,\n CHATVA: `${PREFIX}static/chatva.d0c57a95.png`,\n CONGRATS: `${PREFIX}static/congrats.75718de8.png`,\n COOL: `${PREFIX}static/cool.1893941c.png`,\n COSA: `${PREFIX}static/cosa.46c0c49b.png`,\n DEFAULT_CHAPTER: `${PREFIX}static/default-chapter.8ede1160.png`,\n DODA: `${PREFIX}static/doda.3103971c.png`,\n DVI: `${PREFIX}static/dvi.fc7b32a5.png`,\n EKA: `${PREFIX}static/eka.b10a06fa.png`,\n EMPTY_MIX_TESTS: `${PREFIX}static/empty_mix_tests.1d251f07.png`,\n
|
1
|
+
{"version":3,"file":"images.js","sources":["../../../src/assets/images/images.ts"],"sourcesContent":["const PREFIX = window.VITE_PUBLIC_URL ? window.VITE_PUBLIC_URL : '/';\n\n// Must be alphabetical order\nconst IMAGES = {\n ACHIEVEMENT_BG: `${PREFIX}static/achievement_bg.0d0555ac.png`,\n APPSTORE: `${PREFIX}static/appstore.4c121cf5.png`,\n ASHTA: `${PREFIX}static/ashta.0d3926b2.png`,\n AWESOME: `${PREFIX}static/awesome.8e1cf046.png`,\n BADGE_SUCCESS: `${PREFIX}static/badge_success.2f6c8e65.png`,\n BG_EMPTY_RESOURCES: `${PREFIX}static/bg_empty_resources.63b187fd.png`,\n CHATVA: `${PREFIX}static/chatva.d0c57a95.png`,\n CONGRATS: `${PREFIX}static/congrats.75718de8.png`,\n COOL: `${PREFIX}static/cool.1893941c.png`,\n COSA: `${PREFIX}static/cosa.46c0c49b.png`,\n DEFAULT_CHAPTER: `${PREFIX}static/default-chapter.8ede1160.png`,\n DODA: `${PREFIX}static/doda.3103971c.png`,\n DVI: `${PREFIX}static/dvi.fc7b32a5.png`,\n EKA: `${PREFIX}static/eka.b10a06fa.png`,\n EMPTY_MIX_TESTS: `${PREFIX}static/empty_mix_tests.1d251f07.png`,\n GREAT: `${PREFIX}static/great.2a5dcc34.png`,\n HEXO: `${PREFIX}static/hexo.eab4b9f5.png`,\n KUDOS: `${PREFIX}static/kudos.b7e2aeb6.png`,\n LEARNING_PLAN: `${PREFIX}static/learning-plan.72d64a61.png`,\n LESSON_OVERVIEW_BANNER: `${PREFIX}static/lesson-overview-banner.f5404af6.png`,\n NO_INFO: `${PREFIX}static/no-info.f4bfe437.png`,\n OCTO: `${PREFIX}static/octo.3020bd93.png`,\n PLAYSTORE: `${PREFIX}static/playstore.9beb7c15.png`,\n PUZZLE_CARD_EASY: `${PREFIX}static/puzzle_card_easy.7d9439b5.png`,\n PUZZLE_CARD_HARD: `${PREFIX}static/puzzle_card_hard.185a19c4.png`,\n PUZZLE_CARD_MEDIUM: `${PREFIX}static/puzzle_card_medium.17daef9c.png`,\n SHARED: `${PREFIX}static/shared.3af01b49.png`,\n SHEET_REFERENCE: `${PREFIX}static/sheet-reference.9da7a09f.png`,\n SPIRAL_PATTERN: `${PREFIX}static/spiral_pattern.9fd3e6e9.png`,\n TETRA: `${PREFIX}static/tetra.354ff2b9.png`,\n WOW: `${PREFIX}static/wow.864fbb02.png`,\n ZODASA: `${PREFIX}static/zodasa.336c3bb0.png`,\n};\n\nexport { IMAGES };\n"],"names":["PREFIX","IMAGES"],"mappings":"AAAA,MAAMA,IAAS,OAAO,kBAAkB,OAAO,kBAAkB,KAG3DC,IAAS;AAAA,EACb,gBAAgB,GAAGD,CAAM;AAAA,EACzB,UAAU,GAAGA,CAAM;AAAA,EACnB,OAAO,GAAGA,CAAM;AAAA,EAChB,SAAS,GAAGA,CAAM;AAAA,EAClB,eAAe,GAAGA,CAAM;AAAA,EACxB,oBAAoB,GAAGA,CAAM;AAAA,EAC7B,QAAQ,GAAGA,CAAM;AAAA,EACjB,UAAU,GAAGA,CAAM;AAAA,EACnB,MAAM,GAAGA,CAAM;AAAA,EACf,MAAM,GAAGA,CAAM;AAAA,EACf,iBAAiB,GAAGA,CAAM;AAAA,EAC1B,MAAM,GAAGA,CAAM;AAAA,EACf,KAAK,GAAGA,CAAM;AAAA,EACd,KAAK,GAAGA,CAAM;AAAA,EACd,iBAAiB,GAAGA,CAAM;AAAA,EAC1B,OAAO,GAAGA,CAAM;AAAA,EAChB,MAAM,GAAGA,CAAM;AAAA,EACf,OAAO,GAAGA,CAAM;AAAA,EAChB,eAAe,GAAGA,CAAM;AAAA,EACxB,wBAAwB,GAAGA,CAAM;AAAA,EACjC,SAAS,GAAGA,CAAM;AAAA,EAClB,MAAM,GAAGA,CAAM;AAAA,EACf,WAAW,GAAGA,CAAM;AAAA,EACpB,kBAAkB,GAAGA,CAAM;AAAA,EAC3B,kBAAkB,GAAGA,CAAM;AAAA,EAC3B,oBAAoB,GAAGA,CAAM;AAAA,EAC7B,QAAQ,GAAGA,CAAM;AAAA,EACjB,iBAAiB,GAAGA,CAAM;AAAA,EAC1B,gBAAgB,GAAGA,CAAM;AAAA,EACzB,OAAO,GAAGA,CAAM;AAAA,EAChB,KAAK,GAAGA,CAAM;AAAA,EACd,QAAQ,GAAGA,CAAM;AACnB;"}
|
@@ -1,24 +1,24 @@
|
|
1
1
|
import { jsxs as g, jsx as e } from "react/jsx-runtime";
|
2
|
-
import { memo as
|
3
|
-
import { ILLUSTRATIONS as
|
2
|
+
import { memo as F, useCallback as C } from "react";
|
3
|
+
import { ILLUSTRATIONS as O } from "../../../assets/illustrations/illustrations.js";
|
4
4
|
import _ from "../../ui/layout/flex-view.js";
|
5
5
|
import U from "../../ui/separator/separator.js";
|
6
|
-
import
|
7
|
-
import
|
8
|
-
import
|
9
|
-
import { ContentWrapper as
|
10
|
-
const
|
11
|
-
({ name:
|
6
|
+
import H from "./comps/chapter-banner/chapter-banner.js";
|
7
|
+
import M from "./comps/core-lessons/core-lessons.js";
|
8
|
+
import Q from "./comps/supplementary-resources/supplementary-resources.js";
|
9
|
+
import { ContentWrapper as W, LoaderWrapper as X } from "./styled.js";
|
10
|
+
const j = F(
|
11
|
+
({ name: S, sheets_data: $, user_type: n, loading: a, ...k }) => {
|
12
12
|
const {
|
13
13
|
user_chapter_progress: s,
|
14
14
|
is_defocused: r,
|
15
15
|
image_url: w,
|
16
16
|
image_hue: i,
|
17
17
|
teacherId: x,
|
18
|
-
onCreateExtraPractice:
|
18
|
+
onCreateExtraPractice: t,
|
19
19
|
onStart: p,
|
20
|
-
onResume:
|
21
|
-
onReattempt:
|
20
|
+
onResume: m,
|
21
|
+
onReattempt: l,
|
22
22
|
onPreview: c,
|
23
23
|
onReview: u,
|
24
24
|
onReset: h,
|
@@ -27,28 +27,27 @@ const D = O(
|
|
27
27
|
onUnlock: L,
|
28
28
|
onMarkRelevant: P,
|
29
29
|
onMarkIrrelevant: E,
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
} = S, v = C(() => {
|
38
|
-
if (typeof t != "function")
|
39
|
-
throw new Error("onLearningPlanFAQClick must be a function");
|
40
|
-
t();
|
41
|
-
}, [t]), F = C(() => {
|
30
|
+
onUnAssignSheet: I,
|
31
|
+
onLearningPlanFAQClick: o
|
32
|
+
} = k, {
|
33
|
+
lessons: R,
|
34
|
+
supplementary_sheets_group_sort_order: y,
|
35
|
+
supplementary_sheets_grouped: A
|
36
|
+
} = $, b = C(() => {
|
42
37
|
if (typeof o != "function")
|
43
|
-
throw new Error("
|
38
|
+
throw new Error("onLearningPlanFAQClick must be a function");
|
44
39
|
o();
|
45
|
-
}, [o])
|
46
|
-
|
47
|
-
|
40
|
+
}, [o]), v = C(() => {
|
41
|
+
if (typeof t != "function")
|
42
|
+
throw new Error("onCreateExtraPractice must be a function");
|
43
|
+
t();
|
44
|
+
}, [t]);
|
45
|
+
return /* @__PURE__ */ g(W, { $disablePointerEvents: a, $alignItems: "center", $width: "100%", children: [
|
46
|
+
a && /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e("img", { src: O.LOADER_1, alt: "loader" }) }),
|
48
47
|
/* @__PURE__ */ e(
|
49
|
-
|
48
|
+
H,
|
50
49
|
{
|
51
|
-
name:
|
50
|
+
name: S,
|
52
51
|
userChapterProgress: s,
|
53
52
|
isDefocused: r,
|
54
53
|
imageUrl: w,
|
@@ -56,55 +55,54 @@ const D = O(
|
|
56
55
|
}
|
57
56
|
),
|
58
57
|
/* @__PURE__ */ e(_, { $widthX: 47.5, $flexGapX: 2, children: /* @__PURE__ */ e(
|
59
|
-
|
58
|
+
M,
|
60
59
|
{
|
61
60
|
userType: n,
|
62
|
-
lessons:
|
61
|
+
lessons: R,
|
63
62
|
userChapterProgress: s,
|
64
63
|
isDefocused: r,
|
65
64
|
lessonItemColorHue: i,
|
66
|
-
handleOnLearningPlanFAQClick:
|
65
|
+
handleOnLearningPlanFAQClick: b,
|
67
66
|
onChangeLocation: d,
|
68
67
|
onPreview: c,
|
69
68
|
onReset: h,
|
70
69
|
onReview: u,
|
71
70
|
onStart: p,
|
72
|
-
onReattempt:
|
73
|
-
onResume:
|
71
|
+
onReattempt: l,
|
72
|
+
onResume: m,
|
74
73
|
onMarkAsFamiliar: f,
|
75
74
|
onMarkIrrelevant: E,
|
76
|
-
onMarkRelevant: P
|
77
|
-
onHelpClick: I
|
75
|
+
onMarkRelevant: P
|
78
76
|
}
|
79
77
|
) }),
|
80
78
|
/* @__PURE__ */ g(_, { $width: "100%", $flexGapX: 2, $background: "WHITE_3", $alignItems: "center", children: [
|
81
79
|
/* @__PURE__ */ e(
|
82
|
-
|
80
|
+
Q,
|
83
81
|
{
|
84
82
|
userType: n,
|
85
83
|
teacherId: x,
|
86
|
-
groupedSupplementarySheets:
|
87
|
-
groupedSupplementarySheetsSortOrder:
|
84
|
+
groupedSupplementarySheets: A,
|
85
|
+
groupedSupplementarySheetsSortOrder: y,
|
88
86
|
isDefocused: r,
|
89
|
-
handleOnCreateExtraPractice:
|
87
|
+
handleOnCreateExtraPractice: v,
|
90
88
|
onChangeLocation: d,
|
91
89
|
onPreview: c,
|
92
90
|
onReset: h,
|
93
91
|
onReview: u,
|
94
92
|
onStart: p,
|
95
|
-
onReattempt:
|
96
|
-
onResume:
|
93
|
+
onReattempt: l,
|
94
|
+
onResume: m,
|
97
95
|
onMarkAsFamiliar: f,
|
98
96
|
onUnlock: L,
|
99
|
-
onUnAssignSheet:
|
97
|
+
onUnAssignSheet: I
|
100
98
|
}
|
101
99
|
),
|
102
100
|
/* @__PURE__ */ e(U, { height: 1 })
|
103
101
|
] })
|
104
102
|
] });
|
105
103
|
}
|
106
|
-
),
|
104
|
+
), K = j;
|
107
105
|
export {
|
108
|
-
|
106
|
+
K as default
|
109
107
|
};
|
110
108
|
//# sourceMappingURL=chapter.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"chapter.js","sources":["../../../../src/features/chapters/chapter/chapter.tsx"],"sourcesContent":["import type { IChapterProps } from './chapter-types';\n\nimport { useCallback, type FC, memo } from 'react';\n\nimport { ILLUSTRATIONS } from '../../../assets/illustrations/illustrations';\nimport FlexView from '../../ui/layout/flex-view';\nimport Separator from '../../ui/separator/separator';\nimport ChapterBanner from './comps/chapter-banner/chapter-banner';\nimport CoreLessons from './comps/core-lessons/core-lessons';\nimport SupplementaryResources from './comps/supplementary-resources/supplementary-resources';\nimport * as Styled from './styled';\n\nconst Chapter: FC<IChapterProps> = memo(\n ({ name, sheets_data: sheetData, user_type: userType, loading, ...restChapterProps }) => {\n const {\n user_chapter_progress: userChapterProgress,\n is_defocused: isDefocused,\n image_url: imageUrl,\n image_hue: imageHue,\n teacherId,\n onCreateExtraPractice,\n onStart,\n onResume,\n onReattempt,\n onPreview,\n onReview,\n onReset,\n onChangeLocation,\n onMarkAsFamiliar,\n onUnlock,\n onMarkRelevant,\n onMarkIrrelevant,\n
|
1
|
+
{"version":3,"file":"chapter.js","sources":["../../../../src/features/chapters/chapter/chapter.tsx"],"sourcesContent":["import type { IChapterProps } from './chapter-types';\n\nimport { useCallback, type FC, memo } from 'react';\n\nimport { ILLUSTRATIONS } from '../../../assets/illustrations/illustrations';\nimport FlexView from '../../ui/layout/flex-view';\nimport Separator from '../../ui/separator/separator';\nimport ChapterBanner from './comps/chapter-banner/chapter-banner';\nimport CoreLessons from './comps/core-lessons/core-lessons';\nimport SupplementaryResources from './comps/supplementary-resources/supplementary-resources';\nimport * as Styled from './styled';\n\nconst Chapter: FC<IChapterProps> = memo(\n ({ name, sheets_data: sheetData, user_type: userType, loading, ...restChapterProps }) => {\n const {\n user_chapter_progress: userChapterProgress,\n is_defocused: isDefocused,\n image_url: imageUrl,\n image_hue: imageHue,\n teacherId,\n onCreateExtraPractice,\n onStart,\n onResume,\n onReattempt,\n onPreview,\n onReview,\n onReset,\n onChangeLocation,\n onMarkAsFamiliar,\n onUnlock,\n onMarkRelevant,\n onMarkIrrelevant,\n onUnAssignSheet,\n onLearningPlanFAQClick,\n } = restChapterProps;\n\n const {\n lessons,\n supplementary_sheets_group_sort_order: groupedSupplementarySheetsSortOrder,\n supplementary_sheets_grouped: groupedSupplementarySheets,\n } = sheetData;\n\n const handleOnLearningPlanFAQClick = useCallback(() => {\n if (typeof onLearningPlanFAQClick !== 'function') {\n throw new Error('onLearningPlanFAQClick must be a function');\n }\n\n onLearningPlanFAQClick();\n }, [onLearningPlanFAQClick]);\n\n const handleOnCreateExtraPractice = useCallback(() => {\n if (typeof onCreateExtraPractice !== 'function') {\n throw new Error('onCreateExtraPractice must be a function');\n }\n\n onCreateExtraPractice();\n }, [onCreateExtraPractice]);\n\n return (\n <Styled.ContentWrapper $disablePointerEvents={loading} $alignItems=\"center\" $width=\"100%\">\n {loading && (\n <Styled.LoaderWrapper>\n <img src={ILLUSTRATIONS.LOADER_1} alt=\"loader\" />\n </Styled.LoaderWrapper>\n )}\n\n <ChapterBanner\n name={name}\n userChapterProgress={userChapterProgress}\n isDefocused={isDefocused}\n imageUrl={imageUrl}\n backgroundColor={`${imageHue}_1`}\n />\n <FlexView $widthX={47.5} $flexGapX={2}>\n <CoreLessons\n userType={userType}\n lessons={lessons}\n userChapterProgress={userChapterProgress}\n isDefocused={isDefocused}\n lessonItemColorHue={imageHue}\n handleOnLearningPlanFAQClick={handleOnLearningPlanFAQClick}\n onChangeLocation={onChangeLocation}\n onPreview={onPreview}\n onReset={onReset}\n onReview={onReview}\n onStart={onStart}\n onReattempt={onReattempt}\n onResume={onResume}\n onMarkAsFamiliar={onMarkAsFamiliar}\n onMarkIrrelevant={onMarkIrrelevant}\n onMarkRelevant={onMarkRelevant}\n />\n </FlexView>\n\n <FlexView $width=\"100%\" $flexGapX={2} $background=\"WHITE_3\" $alignItems=\"center\">\n <SupplementaryResources\n userType={userType}\n teacherId={teacherId}\n groupedSupplementarySheets={groupedSupplementarySheets}\n groupedSupplementarySheetsSortOrder={groupedSupplementarySheetsSortOrder}\n isDefocused={isDefocused}\n handleOnCreateExtraPractice={handleOnCreateExtraPractice}\n onChangeLocation={onChangeLocation}\n onPreview={onPreview}\n onReset={onReset}\n onReview={onReview}\n onStart={onStart}\n onReattempt={onReattempt}\n onResume={onResume}\n onMarkAsFamiliar={onMarkAsFamiliar}\n onUnlock={onUnlock}\n onUnAssignSheet={onUnAssignSheet}\n />\n\n <Separator height={1} />\n </FlexView>\n </Styled.ContentWrapper>\n );\n },\n);\n\nexport default Chapter;\n"],"names":["Chapter","memo","name","sheetData","userType","loading","restChapterProps","userChapterProgress","isDefocused","imageUrl","imageHue","teacherId","onCreateExtraPractice","onStart","onResume","onReattempt","onPreview","onReview","onReset","onChangeLocation","onMarkAsFamiliar","onUnlock","onMarkRelevant","onMarkIrrelevant","onUnAssignSheet","onLearningPlanFAQClick","lessons","groupedSupplementarySheetsSortOrder","groupedSupplementarySheets","handleOnLearningPlanFAQClick","useCallback","handleOnCreateExtraPractice","jsxs","Styled.ContentWrapper","jsx","Styled.LoaderWrapper","ILLUSTRATIONS","ChapterBanner","FlexView","CoreLessons","SupplementaryResources","Separator","Chapter$1"],"mappings":";;;;;;;;;AAYA,MAAMA,IAA6BC;AAAA,EACjC,CAAC,EAAE,MAAAC,GAAM,aAAaC,GAAW,WAAWC,GAAU,SAAAC,GAAS,GAAGC,QAAuB;AACjF,UAAA;AAAA,MACJ,uBAAuBC;AAAA,MACvB,cAAcC;AAAA,MACd,WAAWC;AAAA,MACX,WAAWC;AAAA,MACX,WAAAC;AAAA,MACA,uBAAAC;AAAA,MACA,SAAAC;AAAA,MACA,UAAAC;AAAA,MACA,aAAAC;AAAA,MACA,WAAAC;AAAA,MACA,UAAAC;AAAA,MACA,SAAAC;AAAA,MACA,kBAAAC;AAAA,MACA,kBAAAC;AAAA,MACA,UAAAC;AAAA,MACA,gBAAAC;AAAA,MACA,kBAAAC;AAAA,MACA,iBAAAC;AAAA,MACA,wBAAAC;AAAA,IACE,IAAAnB,GAEE;AAAA,MACJ,SAAAoB;AAAA,MACA,uCAAuCC;AAAA,MACvC,8BAA8BC;AAAA,IAC5B,IAAAzB,GAEE0B,IAA+BC,EAAY,MAAM;AACjD,UAAA,OAAOL,KAA2B;AAC9B,cAAA,IAAI,MAAM,2CAA2C;AAGtC,MAA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AAA,YACA,6BAAAuB;AAAA,YACA,kBAAAZ;AAAA,YACA,WAAAH;AAAA,YACA,SAAAE;AAAA,YACA,UAAAD;AAAA,YACA,SAAAJ;AAAA,YACA,aAAAE;AAAA,YACA,UAAAD;AAAA,YACA,kBAAAM;AAAA,YACA,UAAAC;AAAA,YACA,iBAAAG;AAAA,UAAA;AAAA,QACF;AAAA,QAEA,gBAAAU,EAACO,GAAU,EAAA,QAAQ,EAAG,CAAA;AAAA,MAAA,GACxB;AAAA,IACF,EAAA,CAAA;AAAA,EAEJ;AACF,GAEAC,IAAe1C;"}
|
@@ -1,35 +1,34 @@
|
|
1
1
|
import { jsxs as e, jsx as o } from "react/jsx-runtime";
|
2
|
-
import { memo as
|
3
|
-
import { useTheme as
|
2
|
+
import { memo as R } from "react";
|
3
|
+
import { useTheme as $ } from "styled-components";
|
4
4
|
import v from "../../../../sheets/lessons-list/lessons-list.js";
|
5
5
|
import w from "../../../../ui/layout/flex-view.js";
|
6
|
-
import
|
7
|
-
import { CoreLessonContainer as
|
8
|
-
const
|
6
|
+
import k from "../../../../ui/text/text.js";
|
7
|
+
import { CoreLessonContainer as A } from "./core-lessons-styled.js";
|
8
|
+
const T = R(
|
9
9
|
({ lessons: t, userChapterProgress: r, userType: s, ...n }) => {
|
10
10
|
const {
|
11
11
|
lessonItemColorHue: a,
|
12
12
|
onStart: i,
|
13
|
-
onResume:
|
14
|
-
onReattempt:
|
13
|
+
onResume: m,
|
14
|
+
onReattempt: l,
|
15
15
|
onPreview: c,
|
16
16
|
onReview: p,
|
17
17
|
onReset: f,
|
18
18
|
onChangeLocation: h,
|
19
|
-
onMarkAsFamiliar:
|
20
|
-
onMarkRelevant:
|
21
|
-
onMarkIrrelevant:
|
22
|
-
|
23
|
-
} = n, d = k(), { total_core_sheets: R } = r;
|
19
|
+
onMarkAsFamiliar: u,
|
20
|
+
onMarkRelevant: x,
|
21
|
+
onMarkIrrelevant: C
|
22
|
+
} = n, L = $(), { total_core_sheets: d } = r;
|
24
23
|
return /* @__PURE__ */ e(
|
25
|
-
|
24
|
+
A,
|
26
25
|
{
|
27
|
-
$flexGap:
|
26
|
+
$flexGap: L.layout.gutter * 1.5,
|
28
27
|
"data-testid": "lessons-container",
|
29
28
|
children: [
|
30
|
-
/* @__PURE__ */ o(w, { $flexDirection: "row", $alignItems: "center", $justifyContent: "space-between", children: /* @__PURE__ */ e(
|
29
|
+
/* @__PURE__ */ o(w, { $flexDirection: "row", $alignItems: "center", $justifyContent: "space-between", children: /* @__PURE__ */ e(k, { $renderAs: "ac4-black", $color: "REAL_BLACK_60", children: [
|
31
30
|
"lessons (",
|
32
|
-
|
31
|
+
d || "-",
|
33
32
|
")"
|
34
33
|
] }) }),
|
35
34
|
/* @__PURE__ */ o(
|
@@ -39,17 +38,16 @@ const F = $(
|
|
39
38
|
lessons: t,
|
40
39
|
userType: s,
|
41
40
|
lessonItemColorHue: a,
|
42
|
-
onMarkAsFamiliar:
|
41
|
+
onMarkAsFamiliar: u,
|
43
42
|
onChangeLocation: h,
|
44
43
|
onReset: f,
|
45
44
|
onStart: i,
|
46
|
-
onResume:
|
47
|
-
onMarkIrrelevant:
|
48
|
-
onMarkRelevant:
|
45
|
+
onResume: m,
|
46
|
+
onMarkIrrelevant: C,
|
47
|
+
onMarkRelevant: x,
|
49
48
|
onPreview: c,
|
50
49
|
onReview: p,
|
51
|
-
onReattempt:
|
52
|
-
onHelpClick: L
|
50
|
+
onReattempt: l
|
53
51
|
}
|
54
52
|
)
|
55
53
|
]
|
@@ -58,6 +56,6 @@ const F = $(
|
|
58
56
|
}
|
59
57
|
);
|
60
58
|
export {
|
61
|
-
|
59
|
+
T as default
|
62
60
|
};
|
63
61
|
//# sourceMappingURL=core-lessons.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"core-lessons.js","sources":["../../../../../../src/features/chapters/chapter/comps/core-lessons/core-lessons.tsx"],"sourcesContent":["import type { ICoreLessonsProps } from './core-lessons-types';\nimport type { FC } from 'react';\n\nimport { memo } from 'react';\nimport { useTheme } from 'styled-components';\n\nimport LessonsList from '../../../../sheets/lessons-list/lessons-list';\nimport FlexView from '../../../../ui/layout/flex-view';\nimport Text from '../../../../ui/text/text';\nimport * as Styled from './core-lessons-styled';\n\nconst CoreLessons: FC<ICoreLessonsProps> = memo(\n ({ lessons, userChapterProgress, userType, ...restCoreLessonsProps }) => {\n const {\n lessonItemColorHue,\n onStart,\n onResume,\n onReattempt,\n onPreview,\n onReview,\n onReset,\n onChangeLocation,\n onMarkAsFamiliar,\n onMarkRelevant,\n onMarkIrrelevant,\n
|
1
|
+
{"version":3,"file":"core-lessons.js","sources":["../../../../../../src/features/chapters/chapter/comps/core-lessons/core-lessons.tsx"],"sourcesContent":["import type { ICoreLessonsProps } from './core-lessons-types';\nimport type { FC } from 'react';\n\nimport { memo } from 'react';\nimport { useTheme } from 'styled-components';\n\nimport LessonsList from '../../../../sheets/lessons-list/lessons-list';\nimport FlexView from '../../../../ui/layout/flex-view';\nimport Text from '../../../../ui/text/text';\nimport * as Styled from './core-lessons-styled';\n\nconst CoreLessons: FC<ICoreLessonsProps> = memo(\n ({ lessons, userChapterProgress, userType, ...restCoreLessonsProps }) => {\n const {\n lessonItemColorHue,\n onStart,\n onResume,\n onReattempt,\n onPreview,\n onReview,\n onReset,\n onChangeLocation,\n onMarkAsFamiliar,\n onMarkRelevant,\n onMarkIrrelevant,\n } = restCoreLessonsProps;\n\n const theme = useTheme();\n\n const { total_core_sheets: totalCoreSheets } = userChapterProgress;\n\n return (\n <Styled.CoreLessonContainer\n $flexGap={theme.layout.gutter * 1.5}\n data-testid=\"lessons-container\"\n >\n <FlexView $flexDirection=\"row\" $alignItems=\"center\" $justifyContent=\"space-between\">\n <Text $renderAs=\"ac4-black\" $color=\"REAL_BLACK_60\">\n lessons ({totalCoreSheets || '-'})\n </Text>\n </FlexView>\n\n <LessonsList\n emptyLessonsText=\"No core lessons available for this chapter\"\n lessons={lessons}\n userType={userType}\n lessonItemColorHue={lessonItemColorHue}\n onMarkAsFamiliar={onMarkAsFamiliar}\n onChangeLocation={onChangeLocation}\n onReset={onReset}\n onStart={onStart}\n onResume={onResume}\n onMarkIrrelevant={onMarkIrrelevant}\n onMarkRelevant={onMarkRelevant}\n onPreview={onPreview}\n onReview={onReview}\n onReattempt={onReattempt}\n />\n </Styled.CoreLessonContainer>\n );\n },\n);\n\nexport default CoreLessons;\n"],"names":["CoreLessons","memo","lessons","userChapterProgress","userType","restCoreLessonsProps","lessonItemColorHue","onStart","onResume","onReattempt","onPreview","onReview","onReset","onChangeLocation","onMarkAsFamiliar","onMarkRelevant","onMarkIrrelevant","theme","useTheme","totalCoreSheets","jsxs","Styled.CoreLessonContainer","jsx","FlexView","Text","LessonsList"],"mappings":";;;;;;;AAWA,MAAMA,IAAqCC;AAAA,EACzC,CAAC,EAAE,SAAAC,GAAS,qBAAAC,GAAqB,UAAAC,GAAU,GAAGC,QAA2B;AACjE,UAAA;AAAA,MACJ,oBAAAC;AAAA,MACA,SAAAC;AAAA,MACA,UAAAC;AAAA,MACA,aAAAC;AAAA,MACA,WAAAC;AAAA,MACA,UAAAC;AAAA,MACA,SAAAC;AAAA,MACA,kBAAAC;AAAA,MACA,kBAAAC;AAAA,MACA,gBAAAC;AAAA,MACA,kBAAAC;AAAA,IACE,IAAAX,GAEEY,IAAQC,KAER,EAAE,mBAAmBC,EAAoB,IAAAhB;AAG7C,WAAA,gBAAAiB;AAAA,MAACC;AAAAA,MAAA;AAAA,QACC,UAAUJ,EAAM,OAAO,SAAS;AAAA,QAChC,eAAY;AAAA,QAEZ,UAAA;AAAA,UAAA,gBAAAK,EAACC,GAAS,EAAA,gBAAe,OAAM,aAAY,UAAS,iBAAgB,iBAClE,UAAA,gBAAAH,EAACI,GAAK,EAAA,WAAU,aAAY,QAAO,iBAAgB,UAAA;AAAA,YAAA;AAAA,YACvCL,KAAmB;AAAA,YAAI;AAAA,UAAA,EAAA,CACnC,EACF,CAAA;AAAA,UAEA,gBAAAG;AAAA,YAACG;AAAA,YAAA;AAAA,cACC,kBAAiB;AAAA,cACjB,SAAAvB;AAAA,cACA,UAAAE;AAAA,cACA,oBAAAE;AAAA,cACA,kBAAAQ;AAAA,cACA,kBAAAD;AAAA,cACA,SAAAD;AAAA,cACA,SAAAL;AAAA,cACA,UAAAC;AAAA,cACA,kBAAAQ;AAAA,cACA,gBAAAD;AAAA,cACA,WAAAL;AAAA,cACA,UAAAC;AAAA,cACA,aAAAF;AAAA,YAAA;AAAA,UACF;AAAA,QAAA;AAAA,MAAA;AAAA,IAAA;AAAA,EAGN;AACF;"}
|
@@ -78,7 +78,7 @@ const Se = ({
|
|
78
78
|
backgroundColor: "BLUE_4",
|
79
79
|
width: 264,
|
80
80
|
tooltipItem: /* @__PURE__ */ e(I, { children: /* @__PURE__ */ e(d, { $renderAs: "ab2-bold", children: "Get faster & stay ahead in school. Practice 3 new skills everyday." }) }),
|
81
|
-
tooltipXCoOrdinates: g.width,
|
81
|
+
tooltipXCoOrdinates: g.width + 50,
|
82
82
|
tooltipYCoOrdinates: g.height / 2
|
83
83
|
}
|
84
84
|
},
|
@@ -119,7 +119,7 @@ const Se = ({
|
|
119
119
|
backgroundColor: "ORANGE_4",
|
120
120
|
width: 264,
|
121
121
|
tooltipItem: /* @__PURE__ */ e(I, { children: /* @__PURE__ */ e(d, { $renderAs: "ab2-bold", children: "Train to think deeper & plan ahead. Play 3 new games everyday." }) }),
|
122
|
-
tooltipXCoOrdinates: p.width,
|
122
|
+
tooltipXCoOrdinates: p.width + 50,
|
123
123
|
tooltipYCoOrdinates: p.height / 2
|
124
124
|
}
|
125
125
|
},
|
@@ -159,7 +159,7 @@ const Se = ({
|
|
159
159
|
backgroundColor: "PURPLE_4",
|
160
160
|
width: 264,
|
161
161
|
tooltipItem: /* @__PURE__ */ e(I, { children: /* @__PURE__ */ e(d, { $renderAs: "ab2-bold", children: "Think in new ways & stay sharp. Solve 3 new puzzles everyday." }) }),
|
162
|
-
tooltipXCoOrdinates: A.width,
|
162
|
+
tooltipXCoOrdinates: A.width + 50,
|
163
163
|
tooltipYCoOrdinates: A.height / 2
|
164
164
|
}
|
165
165
|
},
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"use-game-launcher-journey.js","sources":["../../../../../src/features/circle-games/game-launcher/use-game-launcher-journey/use-game-launcher-journey.tsx"],"sourcesContent":["import type { TJourneyId } from '../../../journey/journey-id/journey-id-types';\nimport type { ICoachmarkProps } from '../../../journey/use-journey/journey-context-types';\nimport type { IArrowTooltipProps } from '../../../ui/arrow-tooltip/arrow-tooltip-types';\nimport type { INudgeProps } from '../../../ui/nudge/nudge-types';\nimport type { TColorNames } from '../../../ui/types';\nimport type { ICarouselRefs } from '../comps/carousel/carousel-types';\nimport type { ISegmentedGameCardRefs } from '../comps/segmented-game-card/segmented-game-card-types';\nimport type {\n IProject,\n Puzzle,\n} from '../dal/use-get-circle-home-details-dal/use-get-circle-home-dal-types';\nimport type { IUseGameLauncherJourneyProps } from './use-game-launcher-journey-types';\n\nimport { useCallback, useMemo, useRef } from 'react';\n\nimport NextIcon from '../../../../assets/line-icons/icons/next';\nimport { PLATFORM_EVENTS_STUDENT as AnalyticsLabel } from '../../../analytics-events/platform-events-student';\nimport { IndicatorType } from '../../../journey/use-journey/constants';\nimport { useJourney } from '../../../journey/use-journey/use-journey';\nimport IconButton from '../../../ui/buttons/icon-button/icon-button';\nimport { useUIContext } from '../../../ui/context/context';\nimport FlexView from '../../../ui/layout/flex-view';\nimport Text from '../../../ui/text/text';\nimport { CIRCLE_ONBOARDING_ANALYTICS_STEPS as ActionEvent } from '../../enum/circle-onboarding-steps';\nimport { ProjectType } from '../../games/web-view/enums';\nimport { useCircleSounds } from '../../hooks/use-circle-sounds/use-circle-sounds';\nimport { SegmentedGameCard } from '../comps/segmented-game-card/segmented-game-card';\nimport { GAME_LAUNCHER_ANALYTICS_EVENTS } from '../game-launcher-analytics-events';\nimport {\n GO_TO_NEXT_SLIDE_AFTER_MS,\n SHOW_LABEL_HIGHLIGHT_AFTER_MS,\n SHOW_NUDGE_AFTER_MS,\n} from './constants';\n\nexport const useGameLauncherJourney = ({\n onSegmentClick,\n setCarouselIndex,\n onJourneyComplete,\n}: IUseGameLauncherJourneyProps) => {\n const carouselNextBtnRef = useRef<ICarouselRefs>(null);\n const gameRefs = useRef<ISegmentedGameCardRefs>(null);\n const puzzleRefs = useRef<ISegmentedGameCardRefs>(null);\n const lessonRefs = useRef<ISegmentedGameCardRefs>(null);\n\n const isJourneyInProgress = useRef(false);\n\n const { playButtonSound } = useCircleSounds();\n const { nextCoachmark, setJourney } = useJourney();\n const { onEvent: trackAnalytics } = useUIContext();\n\n const trackEventViewed = useCallback(\n (step: ActionEvent) => {\n trackAnalytics(AnalyticsLabel.ONBOARDING_STEP_VIEWED, {\n step,\n });\n },\n [trackAnalytics],\n );\n const trackEventCompleted = useCallback(\n (step: ActionEvent) => {\n trackAnalytics(AnalyticsLabel.ONBOARDING_STEP_COMPLETED, {\n step,\n });\n },\n [trackAnalytics],\n );\n\n const goToNextCard = useCallback(\n (\n analyticsLabelViewed: ActionEvent,\n refOfNextSlide: ISegmentedGameCardRefs,\n color: TColorNames,\n journeyId: TJourneyId,\n isFirstSlide: boolean = false,\n ) => {\n if (!isFirstSlide) {\n playButtonSound();\n setCarouselIndex((prev: number) => prev + 1);\n nextCoachmark(journeyId, false, GO_TO_NEXT_SLIDE_AFTER_MS);\n }\n\n trackEventViewed(analyticsLabelViewed);\n\n const animateLabelTimer = setTimeout(() => {\n clearTimeout(animateLabelTimer);\n refOfNextSlide.startLabelAnimation(color);\n }, SHOW_LABEL_HIGHLIGHT_AFTER_MS);\n\n nextCoachmark(journeyId, true, SHOW_NUDGE_AFTER_MS);\n },\n [nextCoachmark, playButtonSound, setCarouselIndex, trackEventViewed],\n );\n\n const endJourney = useCallback(\n (puzzlesData: Puzzle, journeyId: TJourneyId) => {\n onSegmentClick(puzzlesData, ProjectType.PUZZLE);\n trackEventCompleted(ActionEvent.PUZZLE_ACTIVITY);\n nextCoachmark(journeyId);\n onJourneyComplete(journeyId);\n },\n [nextCoachmark, onJourneyComplete, onSegmentClick, trackEventCompleted],\n );\n\n const startJourney = useCallback(\n (puzzlesData: IProject<Puzzle>, isLessonAvailable: boolean, journeyId: TJourneyId) => {\n if (isJourneyInProgress.current) {\n return;\n }\n\n // If element refs are not available return, this is just for type safety\n if (\n !carouselNextBtnRef?.current?.nextBtnRef.current ||\n !puzzleRefs?.current?.segmentedCardWrapperRef.current ||\n !gameRefs?.current?.labelRef.current ||\n !puzzleRefs?.current?.labelRef.current ||\n !puzzlesData\n ) {\n return;\n }\n\n isJourneyInProgress.current = true;\n const lessonLabelDims = lessonRefs.current?.labelRef?.current?.getBoundingClientRect() || {\n height: 0,\n width: 0,\n };\n const gameLabelDims = gameRefs.current?.labelRef?.current?.getBoundingClientRect() || {\n height: 0,\n width: 0,\n };\n const puzzleLabelDims = puzzleRefs.current?.labelRef?.current?.getBoundingClientRect() || {\n height: 0,\n width: 0,\n };\n\n const launcherDims =\n puzzleRefs.current?.segmentedCardWrapperRef?.current?.getBoundingClientRect() || {\n height: 0,\n width: 0,\n };\n\n let lessonSteps: ICoachmarkProps[] = [];\n\n if (isLessonAvailable && lessonRefs.current) {\n lessonSteps = [\n {\n originalElementToHighlightRef: lessonRefs.current.labelRef,\n isActive: false,\n type: IndicatorType.TOOLTIP,\n elementToHighlight: <></>,\n indicator: {\n position: 'right',\n backgroundColor: 'BLUE_4',\n width: 264,\n tooltipItem: (\n <FlexView>\n <Text $renderAs=\"ab2-bold\">\n Get faster & stay ahead in school. Practice 3 new skills everyday.\n </Text>\n </FlexView>\n ),\n tooltipXCoOrdinates: lessonLabelDims.width,\n tooltipYCoOrdinates: lessonLabelDims.height / 2,\n } as IArrowTooltipProps,\n },\n {\n originalElementToHighlightRef: carouselNextBtnRef.current?.nextBtnRef,\n isActive: false,\n type: IndicatorType.NUDGE,\n elementToHighlight: (\n <IconButton\n renderAs=\"secondary\"\n Icon={NextIcon}\n onClick={() =>\n goToNextCard(\n ActionEvent.GAMES_ACTIVITY,\n gameRefs.current as ISegmentedGameCardRefs,\n 'ORANGE_4',\n journeyId,\n )\n }\n analyticsLabel={GAME_LAUNCHER_ANALYTICS_EVENTS.JOURNEY_NEXT_ACTIVITY}\n />\n ),\n indicator: {\n nudge: 'click',\n content: (\n <Text $renderAs=\"ab1\" $color=\"WHITE\">\n Click to proceed\n </Text>\n ),\n nudgePointerX: 0,\n nudgePointerY: 0,\n } as INudgeProps,\n },\n ];\n }\n\n const gameSteps: ICoachmarkProps[] = [\n {\n originalElementToHighlightRef: gameRefs.current.labelRef,\n isActive: false,\n type: IndicatorType.TOOLTIP,\n elementToHighlight: <></>,\n indicator: {\n position: 'right',\n backgroundColor: 'ORANGE_4',\n width: 264,\n tooltipItem: (\n <FlexView>\n <Text $renderAs=\"ab2-bold\">\n Train to think deeper & plan ahead. Play 3 new games everyday.\n </Text>\n </FlexView>\n ),\n tooltipXCoOrdinates: gameLabelDims.width,\n tooltipYCoOrdinates: gameLabelDims.height / 2,\n } as IArrowTooltipProps,\n },\n {\n originalElementToHighlightRef: carouselNextBtnRef.current.nextBtnRef,\n isActive: false,\n type: IndicatorType.NUDGE,\n elementToHighlight: (\n <IconButton\n renderAs=\"secondary\"\n Icon={NextIcon}\n onClick={() =>\n goToNextCard(\n ActionEvent.PUZZLE_ACTIVITY,\n puzzleRefs.current as ISegmentedGameCardRefs,\n 'PURPLE_4',\n journeyId,\n )\n }\n analyticsLabel={GAME_LAUNCHER_ANALYTICS_EVENTS.JOURNEY_NEXT_ACTIVITY}\n />\n ),\n indicator: {\n nudge: 'click',\n content: (\n <Text $renderAs=\"ab1\" $color=\"WHITE\">\n Click to proceed\n </Text>\n ),\n nudgePointerX: 0,\n nudgePointerY: 0,\n } as INudgeProps,\n },\n ];\n\n const puzzleSteps: ICoachmarkProps[] = [\n {\n originalElementToHighlightRef: puzzleRefs.current.labelRef,\n isActive: false,\n type: IndicatorType.TOOLTIP,\n elementToHighlight: <></>,\n indicator: {\n position: 'right',\n backgroundColor: 'PURPLE_4',\n width: 264,\n tooltipItem: (\n <FlexView>\n <Text $renderAs=\"ab2-bold\">\n Think in new ways & stay sharp. Solve 3 new puzzles everyday.\n </Text>\n </FlexView>\n ),\n tooltipXCoOrdinates: puzzleLabelDims.width,\n tooltipYCoOrdinates: puzzleLabelDims.height / 2,\n } as IArrowTooltipProps,\n },\n {\n originalElementToHighlightRef: puzzleRefs.current.segmentedCardWrapperRef,\n isActive: false,\n type: IndicatorType.NUDGE,\n elementToHighlight: (\n <SegmentedGameCard\n label={''} // This is intentionally left blank to avoid showing the label\n value={puzzlesData.data.filter(puzzle => puzzle.solved).length}\n maxValue={puzzlesData.data.length}\n initialValue={puzzlesData.initialProgressValue}\n data={puzzlesData.data.map(puzzle => ({\n card: puzzle.cardLottie,\n name: '', // We dont want to show the name of the puzzle in onboarding\n isCompleted: puzzle.solved,\n onPress: () => endJourney(puzzle, journeyId),\n }))}\n />\n ),\n indicator: {\n nudge: 'click',\n content: (\n <Text $renderAs=\"ab1\" $color=\"WHITE\">\n Click to solve a puzzle\n </Text>\n ),\n nudgePointerX: launcherDims.width * 0.6,\n nudgePointerY: launcherDims.height * 0.4,\n } as INudgeProps,\n },\n ];\n\n setJourney(journeyId, [...lessonSteps, ...gameSteps, ...puzzleSteps]);\n\n nextCoachmark(journeyId);\n if (isLessonAvailable && lessonRefs.current) {\n goToNextCard(ActionEvent.SKILL_ACTIVITY, lessonRefs.current, 'BLUE_4', journeyId, true);\n } else {\n goToNextCard(ActionEvent.GAMES_ACTIVITY, gameRefs.current, 'ORANGE_4', journeyId, true);\n }\n },\n [endJourney, goToNextCard, nextCoachmark, setJourney],\n );\n\n const data = useMemo(\n () => ({\n gameRefs,\n puzzleRefs,\n lessonRefs,\n carouselNextBtnRef,\n isJourneyInProgress,\n startJourney,\n }),\n [startJourney],\n );\n\n return data;\n};\n"],"names":["useGameLauncherJourney","onSegmentClick","setCarouselIndex","onJourneyComplete","carouselNextBtnRef","useRef","gameRefs","puzzleRefs","lessonRefs","isJourneyInProgress","playButtonSound","useCircleSounds","nextCoachmark","setJourney","useJourney","trackAnalytics","useUIContext","trackEventViewed","useCallback","step","AnalyticsLabel","trackEventCompleted","goToNextCard","analyticsLabelViewed","refOfNextSlide","color","journeyId","isFirstSlide","prev","GO_TO_NEXT_SLIDE_AFTER_MS","animateLabelTimer","SHOW_LABEL_HIGHLIGHT_AFTER_MS","SHOW_NUDGE_AFTER_MS","endJourney","puzzlesData","ProjectType","ActionEvent","startJourney","isLessonAvailable","_a","_b","_c","_d","lessonLabelDims","_g","_f","_e","gameLabelDims","_j","_i","_h","puzzleLabelDims","_m","_l","_k","launcherDims","_p","_o","_n","lessonSteps","IndicatorType","jsx","Fragment","FlexView","Text","_q","IconButton","NextIcon","GAME_LAUNCHER_ANALYTICS_EVENTS","gameSteps","puzzleSteps","SegmentedGameCard","puzzle","useMemo"],"mappings":";;;;;;;;;;;;;;;;AAkCO,MAAMA,KAAyB,CAAC;AAAA,EACrC,gBAAAC;AAAA,EACA,kBAAAC;AAAA,EACA,mBAAAC;AACF,MAAoC;AAC5B,QAAAC,IAAqBC,EAAsB,IAAI,GAC/CC,IAAWD,EAA+B,IAAI,GAC9CE,IAAaF,EAA+B,IAAI,GAChDG,IAAaH,EAA+B,IAAI,GAEhDI,IAAsBJ,EAAO,EAAK,GAElC,EAAE,iBAAAK,MAAoBC,MACtB,EAAE,eAAAC,GAAe,YAAAC,EAAW,IAAIC,GAAW,GAC3C,EAAE,SAASC,EAAe,IAAIC,GAAa,GAE3CC,IAAmBC;AAAA,IACvB,CAACC,MAAsB;AACrB,MAAAJ,EAAeK,EAAe,wBAAwB;AAAA,QACpD,MAAAD;AAAA,MAAA,CACD;AAAA,IACH;AAAA,IACA,CAACJ,CAAc;AAAA,EAAA,GAEXM,IAAsBH;AAAA,IAC1B,CAACC,MAAsB;AACrB,MAAAJ,EAAeK,EAAe,2BAA2B;AAAA,QACvD,MAAAD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,IAAW,GAAGC,EAAW,CAAC,GAEpE1D,EAAcc,CAAS,GACnBY,KAAqB9B,EAAW,UAClCc,EAAac,EAAY,gBAAgB5B,EAAW,SAAS,UAAUkB,GAAW,EAAI,IAEtFJ,EAAac,EAAY,gBAAgB9B,EAAS,SAAS,YAAYoB,GAAW,EAAI;AAAA,IAE1F;AAAA,IACA,CAACO,GAAYX,GAAcV,GAAeC,CAAU;AAAA,EAAA;AAe/C,SAZM4D;AAAA,IACX,OAAO;AAAA,MACL,UAAAnE;AAAA,MACA,YAAAC;AAAA,MACA,YAAAC;AAAA,MACA,oBAAAJ;AAAA,MACA,qBAAAK;AAAA,MACA,cAAA4B;AAAA,IAAA;AAAA,IAEF,CAACA,CAAY;AAAA,EAAA;AAIjB;"}
|
1
|
+
{"version":3,"file":"use-game-launcher-journey.js","sources":["../../../../../src/features/circle-games/game-launcher/use-game-launcher-journey/use-game-launcher-journey.tsx"],"sourcesContent":["import type { TJourneyId } from '../../../journey/journey-id/journey-id-types';\nimport type { ICoachmarkProps } from '../../../journey/use-journey/journey-context-types';\nimport type { IArrowTooltipProps } from '../../../ui/arrow-tooltip/arrow-tooltip-types';\nimport type { INudgeProps } from '../../../ui/nudge/nudge-types';\nimport type { TColorNames } from '../../../ui/types';\nimport type { ICarouselRefs } from '../comps/carousel/carousel-types';\nimport type { ISegmentedGameCardRefs } from '../comps/segmented-game-card/segmented-game-card-types';\nimport type {\n IProject,\n Puzzle,\n} from '../dal/use-get-circle-home-details-dal/use-get-circle-home-dal-types';\nimport type { IUseGameLauncherJourneyProps } from './use-game-launcher-journey-types';\n\nimport { useCallback, useMemo, useRef } from 'react';\n\nimport NextIcon from '../../../../assets/line-icons/icons/next';\nimport { PLATFORM_EVENTS_STUDENT as AnalyticsLabel } from '../../../analytics-events/platform-events-student';\nimport { IndicatorType } from '../../../journey/use-journey/constants';\nimport { useJourney } from '../../../journey/use-journey/use-journey';\nimport IconButton from '../../../ui/buttons/icon-button/icon-button';\nimport { useUIContext } from '../../../ui/context/context';\nimport FlexView from '../../../ui/layout/flex-view';\nimport Text from '../../../ui/text/text';\nimport { CIRCLE_ONBOARDING_ANALYTICS_STEPS as ActionEvent } from '../../enum/circle-onboarding-steps';\nimport { ProjectType } from '../../games/web-view/enums';\nimport { useCircleSounds } from '../../hooks/use-circle-sounds/use-circle-sounds';\nimport { SegmentedGameCard } from '../comps/segmented-game-card/segmented-game-card';\nimport { GAME_LAUNCHER_ANALYTICS_EVENTS } from '../game-launcher-analytics-events';\nimport {\n GO_TO_NEXT_SLIDE_AFTER_MS,\n SHOW_LABEL_HIGHLIGHT_AFTER_MS,\n SHOW_NUDGE_AFTER_MS,\n} from './constants';\n\nexport const useGameLauncherJourney = ({\n onSegmentClick,\n setCarouselIndex,\n onJourneyComplete,\n}: IUseGameLauncherJourneyProps) => {\n const carouselNextBtnRef = useRef<ICarouselRefs>(null);\n const gameRefs = useRef<ISegmentedGameCardRefs>(null);\n const puzzleRefs = useRef<ISegmentedGameCardRefs>(null);\n const lessonRefs = useRef<ISegmentedGameCardRefs>(null);\n\n const isJourneyInProgress = useRef(false);\n\n const { playButtonSound } = useCircleSounds();\n const { nextCoachmark, setJourney } = useJourney();\n const { onEvent: trackAnalytics } = useUIContext();\n\n const trackEventViewed = useCallback(\n (step: ActionEvent) => {\n trackAnalytics(AnalyticsLabel.ONBOARDING_STEP_VIEWED, {\n step,\n });\n },\n [trackAnalytics],\n );\n const trackEventCompleted = useCallback(\n (step: ActionEvent) => {\n trackAnalytics(AnalyticsLabel.ONBOARDING_STEP_COMPLETED, {\n step,\n });\n },\n [trackAnalytics],\n );\n\n const goToNextCard = useCallback(\n (\n analyticsLabelViewed: ActionEvent,\n refOfNextSlide: ISegmentedGameCardRefs,\n color: TColorNames,\n journeyId: TJourneyId,\n isFirstSlide: boolean = false,\n ) => {\n if (!isFirstSlide) {\n playButtonSound();\n setCarouselIndex((prev: number) => prev + 1);\n nextCoachmark(journeyId, false, GO_TO_NEXT_SLIDE_AFTER_MS);\n }\n\n trackEventViewed(analyticsLabelViewed);\n\n const animateLabelTimer = setTimeout(() => {\n clearTimeout(animateLabelTimer);\n refOfNextSlide.startLabelAnimation(color);\n }, SHOW_LABEL_HIGHLIGHT_AFTER_MS);\n\n nextCoachmark(journeyId, true, SHOW_NUDGE_AFTER_MS);\n },\n [nextCoachmark, playButtonSound, setCarouselIndex, trackEventViewed],\n );\n\n const endJourney = useCallback(\n (puzzlesData: Puzzle, journeyId: TJourneyId) => {\n onSegmentClick(puzzlesData, ProjectType.PUZZLE);\n trackEventCompleted(ActionEvent.PUZZLE_ACTIVITY);\n nextCoachmark(journeyId);\n onJourneyComplete(journeyId);\n },\n [nextCoachmark, onJourneyComplete, onSegmentClick, trackEventCompleted],\n );\n\n const startJourney = useCallback(\n (puzzlesData: IProject<Puzzle>, isLessonAvailable: boolean, journeyId: TJourneyId) => {\n if (isJourneyInProgress.current) {\n return;\n }\n\n // If element refs are not available return, this is just for type safety\n if (\n !carouselNextBtnRef?.current?.nextBtnRef.current ||\n !puzzleRefs?.current?.segmentedCardWrapperRef.current ||\n !gameRefs?.current?.labelRef.current ||\n !puzzleRefs?.current?.labelRef.current ||\n !puzzlesData\n ) {\n return;\n }\n\n isJourneyInProgress.current = true;\n const lessonLabelDims = lessonRefs.current?.labelRef?.current?.getBoundingClientRect() || {\n height: 0,\n width: 0,\n };\n const gameLabelDims = gameRefs.current?.labelRef?.current?.getBoundingClientRect() || {\n height: 0,\n width: 0,\n };\n const puzzleLabelDims = puzzleRefs.current?.labelRef?.current?.getBoundingClientRect() || {\n height: 0,\n width: 0,\n };\n\n const launcherDims =\n puzzleRefs.current?.segmentedCardWrapperRef?.current?.getBoundingClientRect() || {\n height: 0,\n width: 0,\n };\n\n let lessonSteps: ICoachmarkProps[] = [];\n\n if (isLessonAvailable && lessonRefs.current) {\n lessonSteps = [\n {\n originalElementToHighlightRef: lessonRefs.current.labelRef,\n isActive: false,\n type: IndicatorType.TOOLTIP,\n elementToHighlight: <></>,\n indicator: {\n position: 'right',\n backgroundColor: 'BLUE_4',\n width: 264,\n tooltipItem: (\n <FlexView>\n <Text $renderAs=\"ab2-bold\">\n Get faster & stay ahead in school. Practice 3 new skills everyday.\n </Text>\n </FlexView>\n ),\n tooltipXCoOrdinates: lessonLabelDims.width + 50,\n tooltipYCoOrdinates: lessonLabelDims.height / 2,\n } as IArrowTooltipProps,\n },\n {\n originalElementToHighlightRef: carouselNextBtnRef.current?.nextBtnRef,\n isActive: false,\n type: IndicatorType.NUDGE,\n elementToHighlight: (\n <IconButton\n renderAs=\"secondary\"\n Icon={NextIcon}\n onClick={() =>\n goToNextCard(\n ActionEvent.GAMES_ACTIVITY,\n gameRefs.current as ISegmentedGameCardRefs,\n 'ORANGE_4',\n journeyId,\n )\n }\n analyticsLabel={GAME_LAUNCHER_ANALYTICS_EVENTS.JOURNEY_NEXT_ACTIVITY}\n />\n ),\n indicator: {\n nudge: 'click',\n content: (\n <Text $renderAs=\"ab1\" $color=\"WHITE\">\n Click to proceed\n </Text>\n ),\n nudgePointerX: 0,\n nudgePointerY: 0,\n } as INudgeProps,\n },\n ];\n }\n\n const gameSteps: ICoachmarkProps[] = [\n {\n originalElementToHighlightRef: gameRefs.current.labelRef,\n isActive: false,\n type: IndicatorType.TOOLTIP,\n elementToHighlight: <></>,\n indicator: {\n position: 'right',\n backgroundColor: 'ORANGE_4',\n width: 264,\n tooltipItem: (\n <FlexView>\n <Text $renderAs=\"ab2-bold\">\n Train to think deeper & plan ahead. Play 3 new games everyday.\n </Text>\n </FlexView>\n ),\n tooltipXCoOrdinates: gameLabelDims.width + 50,\n tooltipYCoOrdinates: gameLabelDims.height / 2,\n } as IArrowTooltipProps,\n },\n {\n originalElementToHighlightRef: carouselNextBtnRef.current.nextBtnRef,\n isActive: false,\n type: IndicatorType.NUDGE,\n elementToHighlight: (\n <IconButton\n renderAs=\"secondary\"\n Icon={NextIcon}\n onClick={() =>\n goToNextCard(\n ActionEvent.PUZZLE_ACTIVITY,\n puzzleRefs.current as ISegmentedGameCardRefs,\n 'PURPLE_4',\n journeyId,\n )\n }\n analyticsLabel={GAME_LAUNCHER_ANALYTICS_EVENTS.JOURNEY_NEXT_ACTIVITY}\n />\n ),\n indicator: {\n nudge: 'click',\n content: (\n <Text $renderAs=\"ab1\" $color=\"WHITE\">\n Click to proceed\n </Text>\n ),\n nudgePointerX: 0,\n nudgePointerY: 0,\n } as INudgeProps,\n },\n ];\n\n const puzzleSteps: ICoachmarkProps[] = [\n {\n originalElementToHighlightRef: puzzleRefs.current.labelRef,\n isActive: false,\n type: IndicatorType.TOOLTIP,\n elementToHighlight: <></>,\n indicator: {\n position: 'right',\n backgroundColor: 'PURPLE_4',\n width: 264,\n tooltipItem: (\n <FlexView>\n <Text $renderAs=\"ab2-bold\">\n Think in new ways & stay sharp. Solve 3 new puzzles everyday.\n </Text>\n </FlexView>\n ),\n tooltipXCoOrdinates: puzzleLabelDims.width + 50,\n tooltipYCoOrdinates: puzzleLabelDims.height / 2,\n } as IArrowTooltipProps,\n },\n {\n originalElementToHighlightRef: puzzleRefs.current.segmentedCardWrapperRef,\n isActive: false,\n type: IndicatorType.NUDGE,\n elementToHighlight: (\n <SegmentedGameCard\n label={''} // This is intentionally left blank to avoid showing the label\n value={puzzlesData.data.filter(puzzle => puzzle.solved).length}\n maxValue={puzzlesData.data.length}\n initialValue={puzzlesData.initialProgressValue}\n data={puzzlesData.data.map(puzzle => ({\n card: puzzle.cardLottie,\n name: '', // We dont want to show the name of the puzzle in onboarding\n isCompleted: puzzle.solved,\n onPress: () => endJourney(puzzle, journeyId),\n }))}\n />\n ),\n indicator: {\n nudge: 'click',\n content: (\n <Text $renderAs=\"ab1\" $color=\"WHITE\">\n Click to solve a puzzle\n </Text>\n ),\n nudgePointerX: launcherDims.width * 0.6,\n nudgePointerY: launcherDims.height * 0.4,\n } as INudgeProps,\n },\n ];\n\n setJourney(journeyId, [...lessonSteps, ...gameSteps, ...puzzleSteps]);\n\n nextCoachmark(journeyId);\n if (isLessonAvailable && lessonRefs.current) {\n goToNextCard(ActionEvent.SKILL_ACTIVITY, lessonRefs.current, 'BLUE_4', journeyId, true);\n } else {\n goToNextCard(ActionEvent.GAMES_ACTIVITY, gameRefs.current, 'ORANGE_4', journeyId, true);\n }\n },\n [endJourney, goToNextCard, nextCoachmark, setJourney],\n );\n\n const data = useMemo(\n () => ({\n gameRefs,\n puzzleRefs,\n lessonRefs,\n carouselNextBtnRef,\n isJourneyInProgress,\n startJourney,\n }),\n [startJourney],\n );\n\n return data;\n};\n"],"names":["useGameLauncherJourney","onSegmentClick","setCarouselIndex","onJourneyComplete","carouselNextBtnRef","useRef","gameRefs","puzzleRefs","lessonRefs","isJourneyInProgress","playButtonSound","useCircleSounds","nextCoachmark","setJourney","useJourney","trackAnalytics","useUIContext","trackEventViewed","useCallback","step","AnalyticsLabel","trackEventCompleted","goToNextCard","analyticsLabelViewed","refOfNextSlide","color","journeyId","isFirstSlide","prev","GO_TO_NEXT_SLIDE_AFTER_MS","animateLabelTimer","SHOW_LABEL_HIGHLIGHT_AFTER_MS","SHOW_NUDGE_AFTER_MS","endJourney","puzzlesData","ProjectType","ActionEvent","startJourney","isLessonAvailable","_a","_b","_c","_d","lessonLabelDims","_g","_f","_e","gameLabelDims","_j","_i","_h","puzzleLabelDims","_m","_l","_k","launcherDims","_p","_o","_n","lessonSteps","IndicatorType","jsx","Fragment","FlexView","Text","_q","IconButton","NextIcon","GAME_LAUNCHER_ANALYTICS_EVENTS","gameSteps","puzzleSteps","SegmentedGameCard","puzzle","useMemo"],"mappings":";;;;;;;;;;;;;;;;AAkCO,MAAMA,KAAyB,CAAC;AAAA,EACrC,gBAAAC;AAAA,EACA,kBAAAC;AAAA,EACA,mBAAAC;AACF,MAAoC;AAC5B,QAAAC,IAAqBC,EAAsB,IAAI,GAC/CC,IAAWD,EAA+B,IAAI,GAC9CE,IAAaF,EAA+B,IAAI,GAChDG,IAAaH,EAA+B,IAAI,GAEhDI,IAAsBJ,EAAO,EAAK,GA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M;AAAA;AAAA,gBACN,aAAaA,EAAO;AAAA,gBACpB,SAAS,MAAMvC,EAAWuC,GAAQ9C,CAAS;AAAA,cAAA,EAC3C;AAAA,YAAA;AAAA,UACJ;AAAA,UAEF,WAAW;AAAA,YACT,OAAO;AAAA,YACP,SACG,gBAAAmC,EAAAG,GAAA,EAAK,WAAU,OAAM,QAAO,SAAQ,UAErC,2BAAA;AAAA,YAEF,eAAeT,EAAa,QAAQ;AAAA,YACpC,eAAeA,EAAa,SAAS;AAAA,UACvC;AAAA,QACF;AAAA,MAAA;AAGS,MAAA1C,EAAAa,GAAW,CAAC,GAAGiC,GAAa,GAAGU,IAAW,GAAGC,EAAW,CAAC,GAEpE1D,EAAcc,CAAS,GACnBY,KAAqB9B,EAAW,UAClCc,EAAac,EAAY,gBAAgB5B,EAAW,SAAS,UAAUkB,GAAW,EAAI,IAEtFJ,EAAac,EAAY,gBAAgB9B,EAAS,SAAS,YAAYoB,GAAW,EAAI;AAAA,IAE1F;AAAA,IACA,CAACO,GAAYX,GAAcV,GAAeC,CAAU;AAAA,EAAA;AAe/C,SAZM4D;AAAA,IACX,OAAO;AAAA,MACL,UAAAnE;AAAA,MACA,YAAAC;AAAA,MACA,YAAAC;AAAA,MACA,oBAAAJ;AAAA,MACA,qBAAAK;AAAA,MACA,cAAA4B;AAAA,IAAA;AAAA,IAEF,CAACA,CAAY;AAAA,EAAA;AAIjB;"}
|
@@ -1,76 +1,41 @@
|
|
1
|
-
|
2
|
-
import { S3_LINK as e } from "../../constants/urls.js";
|
3
|
-
const r = 365 * 24 * 60 * 60, n = r * 1e3, S = `${e}/2025/24_Jan/INTRO_Goal+Creator+with+music+N.mp4`, l = [
|
4
|
-
{
|
5
|
-
modalHeader: "Where did the remaining chapters go?",
|
6
|
-
modalSubHeader: "They are not removed. They are just not a part of this learning plan.",
|
7
|
-
modalAnalyticsLabel: "WHERE_CHAPTERS",
|
8
|
-
header: "😮 Where did the remaining chapters go? More questions?",
|
9
|
-
videoSrc: `${e}/2024/10_Oct/Where+did+the+remaining+chapters+go+final.mp4`,
|
10
|
-
subHeaderStart: "Look no more.",
|
11
|
-
imgSrc: a.HELP_BANNER1,
|
12
|
-
hue: "YELLOW"
|
13
|
-
},
|
14
|
-
{
|
15
|
-
modalHeader: "Can we have more than 1 learning plan?",
|
16
|
-
modalSubHeader: "For sure! There can be multiple learning plans simultaneously that the student is preparing for.",
|
17
|
-
modalAnalyticsLabel: "MORE_THAN_1_MS",
|
18
|
-
header: "🤔 Can we have more than 1 learning plan? More questions?",
|
19
|
-
videoSrc: `${e}/2024/10_Oct/Can+we+create+more+than+1+learning+plan+final.mp4`,
|
20
|
-
subHeaderStart: "For sure.",
|
21
|
-
imgSrc: a.HELP_BANNER2,
|
22
|
-
hue: "BLUE"
|
23
|
-
},
|
24
|
-
{
|
25
|
-
modalHeader: "Which chapter should I add to the learning plan?",
|
26
|
-
modalSubHeader: "Add chapters relevant to the upcoming test",
|
27
|
-
modalAnalyticsLabel: "WHICH_CHAPTER_ADD",
|
28
|
-
header: "🤔 Which chapter should I add to the learning plan? More questions?",
|
29
|
-
videoSrc: `${e}/2024/10_Oct/Which+Chapter+should+I+add+to+the+learning+plan+final.mp4`,
|
30
|
-
subHeaderStart: "Clear all your doubts.",
|
31
|
-
imgSrc: a.HELP_BANNER3,
|
32
|
-
hue: "ORANGE"
|
33
|
-
}
|
34
|
-
], s = 480, o = {
|
1
|
+
const S = 31536e3, T = 31536e6, _ = 480, E = {
|
35
2
|
SAT_DEMO: "SAT-DEMO",
|
36
3
|
SAT_MATH: "SAT-MATH",
|
37
4
|
SAT_ENGLISH: "SAT-ENGLISH",
|
38
5
|
SAT_TESTS: "SAT-TESTS"
|
39
|
-
},
|
6
|
+
}, A = {
|
40
7
|
MATH: "MATH",
|
41
8
|
CODING: "CODING",
|
42
9
|
SCIENCE: "SCIENCE",
|
43
10
|
ELA: "ELA",
|
44
11
|
ELP: "ELP",
|
45
|
-
...
|
46
|
-
},
|
12
|
+
...E
|
13
|
+
}, o = {
|
47
14
|
SCHOOL_SUCCESS: "SCHOOL_SUCCESS",
|
48
15
|
TEST_PREP: "TEST_PREP",
|
49
16
|
ENRICHMENT: "ENRICHMENT"
|
50
|
-
},
|
17
|
+
}, e = {
|
51
18
|
LEVEL: "Level",
|
52
19
|
FOCUS: "Focus",
|
53
20
|
BEHAVIOR: "Behaviors"
|
54
|
-
},
|
21
|
+
}, N = {
|
55
22
|
"no-test": "School Success goals",
|
56
23
|
"non-standardized": "Test Prep goals",
|
57
24
|
standardized: "Enrichment goals"
|
58
|
-
},
|
25
|
+
}, s = {
|
59
26
|
CHAPTER_EXIT_WARNING: "Going back will clear your currently selected chapters. Do you wish to proceed?",
|
60
27
|
GOAL_CHANGE_WARNING: "Choosing a different goal will clear your currently selected chapters. Do you wish to proceed?"
|
61
|
-
},
|
28
|
+
}, O = 60, c = 88;
|
62
29
|
export {
|
63
|
-
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
T as TEST_TYPE_TO_TEST_NAME,
|
74
|
-
c as WARNING_MESSAGES
|
30
|
+
A as COURSE_STREAMS,
|
31
|
+
o as GOAL_CATEGORY,
|
32
|
+
c as GOAL_FOOTER_HEIGHT,
|
33
|
+
O as GOAL_HEADER_HEIGHT,
|
34
|
+
_ as MILESTONE_WIDGET_MIN_HEIGHT,
|
35
|
+
T as ONE_YEAR_TIMESTAMP_IN_MILLISECONDS,
|
36
|
+
S as ONE_YEAR_TIMESTAMP_IN_SECONDS,
|
37
|
+
e as PREFERENCE_CATEGORY,
|
38
|
+
N as TEST_TYPE_TO_TEST_NAME,
|
39
|
+
s as WARNING_MESSAGES
|
75
40
|
};
|
76
41
|
//# sourceMappingURL=constants.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"constants.js","sources":["../../../src/features/milestone/constants.ts"],"sourcesContent":["
|
1
|
+
{"version":3,"file":"constants.js","sources":["../../../src/features/milestone/constants.ts"],"sourcesContent":["const ONE_YEAR_TIMESTAMP_IN_SECONDS = 365 * 24 * 60 * 60;\nconst ONE_YEAR_TIMESTAMP_IN_MILLISECONDS = ONE_YEAR_TIMESTAMP_IN_SECONDS * 1000;\n\nconst MILESTONE_WIDGET_MIN_HEIGHT = 480;\n\nconst SAT_COURSES = {\n SAT_DEMO: 'SAT-DEMO',\n SAT_MATH: 'SAT-MATH',\n SAT_ENGLISH: 'SAT-ENGLISH',\n SAT_TESTS: 'SAT-TESTS',\n} as const;\n\nconst COURSE_STREAMS = {\n MATH: 'MATH',\n CODING: 'CODING',\n SCIENCE: 'SCIENCE',\n ELA: 'ELA',\n ELP: 'ELP',\n ...SAT_COURSES,\n} as const;\n\nconst ENROLLMENT_TYPES = {\n ONLINE: 'ONLINE',\n PLUS: 'PLUS',\n REGULAR: 'REGULAR',\n HYBRID: 'HYBRID',\n HYBRID_PLUS: 'HYBRID_PLUS',\n ARMY: 'ARMY',\n CLASS_K5: 'CLASS_K5',\n OLYMPIAD: 'OLYMPIAD',\n HIGH: 'HIGH',\n GROUP_CLASS: 'GROUP_CLASS',\n CUECENTER: 'CUECENTER',\n} as const;\n\nconst GOAL_CATEGORY = {\n SCHOOL_SUCCESS: 'SCHOOL_SUCCESS',\n TEST_PREP: 'TEST_PREP',\n ENRICHMENT: 'ENRICHMENT',\n} as const;\n\nconst PREFERENCE_CATEGORY = {\n LEVEL: 'Level',\n FOCUS: 'Focus',\n BEHAVIOR: 'Behaviors',\n} as const;\n\nconst TEST_TYPE_TO_TEST_NAME = {\n 'no-test': 'School Success goals',\n 'non-standardized': 'Test Prep goals',\n 'standardized': 'Enrichment goals',\n};\n\nconst WARNING_MESSAGES = {\n CHAPTER_EXIT_WARNING:\n 'Going back will clear your currently selected chapters. Do you wish to proceed?',\n GOAL_CHANGE_WARNING:\n 'Choosing a different goal will clear your currently selected chapters. Do you wish to proceed?',\n};\n\nconst GOAL_HEADER_HEIGHT = 60;\nconst GOAL_FOOTER_HEIGHT = 88;\n\nexport {\n ONE_YEAR_TIMESTAMP_IN_SECONDS,\n ONE_YEAR_TIMESTAMP_IN_MILLISECONDS,\n MILESTONE_WIDGET_MIN_HEIGHT,\n COURSE_STREAMS,\n GOAL_CATEGORY,\n GOAL_HEADER_HEIGHT,\n GOAL_FOOTER_HEIGHT,\n WARNING_MESSAGES,\n TEST_TYPE_TO_TEST_NAME,\n PREFERENCE_CATEGORY,\n ENROLLMENT_TYPES,\n};\n"],"names":["ONE_YEAR_TIMESTAMP_IN_SECONDS","ONE_YEAR_TIMESTAMP_IN_MILLISECONDS","MILESTONE_WIDGET_MIN_HEIGHT","SAT_COURSES","COURSE_STREAMS","GOAL_CATEGORY","PREFERENCE_CATEGORY","TEST_TYPE_TO_TEST_NAME","WARNING_MESSAGES","GOAL_HEADER_HEIGHT","GOAL_FOOTER_HEIGHT"],"mappings":"AAAM,MAAAA,IAAgC,SAChCC,IAAqC,SAErCC,IAA8B,KAE9BC,IAAc;AAAA,EAClB,UAAU;AAAA,EACV,UAAU;AAAA,EACV,aAAa;AAAA,EACb,WAAW;AACb,GAEMC,IAAiB;AAAA,EACrB,MAAM;AAAA,EACN,QAAQ;AAAA,EACR,SAAS;AAAA,EACT,KAAK;AAAA,EACL,KAAK;AAAA,EACL,GAAGD;AACL,GAgBME,IAAgB;AAAA,EACpB,gBAAgB;AAAA,EAChB,WAAW;AAAA,EACX,YAAY;AACd,GAEMC,IAAsB;AAAA,EAC1B,OAAO;AAAA,EACP,OAAO;AAAA,EACP,UAAU;AACZ,GAEMC,IAAyB;AAAA,EAC7B,WAAW;AAAA,EACX,oBAAoB;AAAA,EACpB,cAAgB;AAClB,GAEMC,IAAmB;AAAA,EACvB,sBACE;AAAA,EACF,qBACE;AACJ,GAEMC,IAAqB,IACrBC,IAAqB;"}
|
@@ -1,19 +1,7 @@
|
|
1
|
-
import
|
2
|
-
import
|
3
|
-
|
4
|
-
|
5
|
-
flex: 1;
|
6
|
-
text-align: center;
|
7
|
-
margin-top: 72px;
|
8
|
-
margin-bottom: 52px;
|
9
|
-
`;
|
10
|
-
t.img`
|
11
|
-
margin-bottom: 8px;
|
12
|
-
width: 80px;
|
13
|
-
height: 80px;
|
14
|
-
`;
|
15
|
-
const e = t(o)(({ theme: p }) => `
|
16
|
-
box-shadow: 0px 10px 20px 0px ${p.colors.BLACK_T_20};
|
1
|
+
import r from "styled-components";
|
2
|
+
import p from "../../../../ui/layout/flex-view.js";
|
3
|
+
const e = r(p)(({ theme: o }) => `
|
4
|
+
box-shadow: 0px 10px 20px 0px ${o.colors.BLACK_T_20};
|
17
5
|
`);
|
18
6
|
export {
|
19
7
|
e as ButtonWrapper
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"chapters-selection-step-styled.js","sources":["../../../../../../src/features/milestone/create/comps/chapters-selection-step/chapters-selection-step-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport FlexView from '../../../../ui/layout/flex-view';\n\nconst
|
1
|
+
{"version":3,"file":"chapters-selection-step-styled.js","sources":["../../../../../../src/features/milestone/create/comps/chapters-selection-step/chapters-selection-step-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport FlexView from '../../../../ui/layout/flex-view';\n\nconst ButtonWrapper = styled(FlexView)(({ theme }) => {\n return `\n box-shadow: 0px 10px 20px 0px ${theme.colors.BLACK_T_20};\n `;\n});\n\nexport { ButtonWrapper };\n"],"names":["ButtonWrapper","styled","FlexView","theme"],"mappings":";;AAIA,MAAMA,IAAgBC,EAAOC,CAAQ,EAAE,CAAC,EAAE,OAAAC,QACjC;AAAA,oCAC2BA,EAAM,OAAO,UAAU;AAAA,GAE1D;"}
|