@cuemath/leap 3.5.31 → 3.5.32-as11
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 +38 -0
- package/dist/assets/illustrations/illustrations.js.map +1 -1
- package/dist/assets/images/images.js +0 -12
- package/dist/assets/images/images.js.map +1 -1
- package/dist/assets/line-icons/icons/carat-right.js +26 -0
- package/dist/assets/line-icons/icons/carat-right.js.map +1 -0
- package/dist/features/analytics-events/whitelist-events.js +10 -8
- package/dist/features/analytics-events/whitelist-events.js.map +1 -1
- package/dist/features/chapters/chapters-list/chapter-item/chapter-circular-progress/chapter-circular-progress.js +3 -3
- package/dist/features/chapters/chapters-list/chapter-item/chapter-circular-progress/chapter-circular-progress.js.map +1 -1
- package/dist/features/journey/tracking-id/tracking-id-teacher.js +5 -0
- package/dist/features/journey/tracking-id/tracking-id-teacher.js.map +1 -0
- package/dist/features/journey/tracking-id/tracking-ids.js +5 -3
- package/dist/features/journey/tracking-id/tracking-ids.js.map +1 -1
- package/dist/features/timeline/comps/new-progress-intro-modal/new-progress-intro-modal-constants.js +17 -0
- package/dist/features/timeline/comps/new-progress-intro-modal/new-progress-intro-modal-constants.js.map +1 -0
- package/dist/features/timeline/comps/new-progress-intro-modal/new-progress-intro-modal.js +54 -0
- package/dist/features/timeline/comps/new-progress-intro-modal/new-progress-intro-modal.js.map +1 -0
- package/dist/features/timeline/{api → daily-timeline/api}/use-daily-timeline-get.js +2 -2
- package/dist/features/timeline/daily-timeline/api/use-daily-timeline-get.js.map +1 -0
- package/dist/features/timeline/{comps → daily-timeline/comps}/accordion-item/accordion-item.js +6 -6
- package/dist/features/timeline/daily-timeline/comps/accordion-item/accordion-item.js.map +1 -0
- package/dist/features/timeline/daily-timeline/comps/constants.js +22 -0
- package/dist/features/timeline/daily-timeline/comps/constants.js.map +1 -0
- package/dist/features/timeline/{comps → daily-timeline/comps}/daily-timeline-items/daily-timeline-items-styled.js +1 -1
- package/dist/features/timeline/daily-timeline/comps/daily-timeline-items/daily-timeline-items-styled.js.map +1 -0
- package/dist/features/timeline/{comps → daily-timeline/comps}/daily-timeline-items/daily-timeline-items.js +18 -18
- package/dist/features/timeline/daily-timeline/comps/daily-timeline-items/daily-timeline-items.js.map +1 -0
- package/dist/features/timeline/{comps → daily-timeline/comps}/month-break/month-break-styled.js +1 -1
- package/dist/features/timeline/daily-timeline/comps/month-break/month-break-styled.js.map +1 -0
- package/dist/features/timeline/daily-timeline/comps/month-break/month-break.js.map +1 -0
- package/dist/features/timeline/{comps → daily-timeline/comps}/no-activity.js +4 -4
- package/dist/features/timeline/daily-timeline/comps/no-activity.js.map +1 -0
- package/dist/features/timeline/{comps → daily-timeline/comps}/utils.js +5 -5
- package/dist/features/timeline/daily-timeline/comps/utils.js.map +1 -0
- package/dist/features/timeline/{comps → daily-timeline/comps}/year-break/year-break-styled.js +1 -1
- package/dist/features/timeline/daily-timeline/comps/year-break/year-break-styled.js.map +1 -0
- package/dist/features/timeline/{comps → daily-timeline/comps}/year-break/year-break.js +2 -2
- package/dist/features/timeline/daily-timeline/comps/year-break/year-break.js.map +1 -0
- package/dist/features/timeline/{daily-timeline-events.js → daily-timeline/daily-timeline-events.js} +1 -1
- package/dist/features/timeline/daily-timeline/daily-timeline-events.js.map +1 -0
- package/dist/features/timeline/daily-timeline/daily-timeline-styled.js +25 -0
- package/dist/features/timeline/daily-timeline/daily-timeline-styled.js.map +1 -0
- package/dist/features/timeline/daily-timeline/daily-timeline-types.js +7 -0
- package/dist/features/timeline/daily-timeline/daily-timeline-types.js.map +1 -0
- package/dist/features/timeline/{daily-timeline-view.js → daily-timeline/daily-timeline-view.js} +24 -25
- package/dist/features/timeline/daily-timeline/daily-timeline-view.js.map +1 -0
- package/dist/features/timeline/{daily-timeline.js → daily-timeline/daily-timeline.js} +23 -23
- package/dist/features/timeline/daily-timeline/daily-timeline.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/api/use-monthly-timeline-get.js +10 -0
- package/dist/features/timeline/monthly-timeline/api/use-monthly-timeline-get.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/comps/monthly-card/monthly-card.js +87 -0
- package/dist/features/timeline/monthly-timeline/comps/monthly-card/monthly-card.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/comps/monthly-card/monthly-card.styled.js +9 -0
- package/dist/features/timeline/monthly-timeline/comps/monthly-card/monthly-card.styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/constants.js +40 -0
- package/dist/features/timeline/monthly-timeline/constants.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/api/use-monthly-report-api.js +13 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/api/use-monthly-report-api.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/achievements/achievements.js +59 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/achievements/achievements.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/achievements/achievements.styled.js +15 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/achievements/achievements.styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/achievements/constant.js +16 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/achievements/constant.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities-card/activities-card.js +128 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities-card/activities-card.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities-card/activities-card.styled.js +53 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities-card/activities-card.styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities-card-puzzles/activities-card-puzzles.js +75 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities-card-puzzles/activities-card-puzzles.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities-card-puzzles/activities-card-puzzles.styled.js +58 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities-card-puzzles/activities-card-puzzles.styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities-card-puzzles/activity-puzzle-card.js +66 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities-card-puzzles/activity-puzzle-card.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities.js +27 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/activities.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/constants.js +102 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/constants.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/utils.js +9 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/activities/utils.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendance-constants.js +29 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendance-constants.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendance-utils.js +123 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendance-utils.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendance.js +49 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendance.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendance.styled.js +48 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendance.styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendence-view.js +56 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendence-view.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/feedback/feedback-styled.js +9 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/feedback/feedback-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/feedback/feedback.js +85 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/feedback/feedback.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-card/goal-chapter-card.js +48 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-card/goal-chapter-card.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-card/goals-card-styled.js +28 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-card/goals-card-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-card/goals-card.js +118 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-card/goals-card.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-constants.js +30 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-constants.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals.js +22 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/monthly-report-events.js +11 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/monthly-report-events.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/monthly-report-styled.js +14 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/monthly-report-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/monthly-report-types.js +5 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/monthly-report-types.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/monthly-report.js +79 -0
- package/dist/features/timeline/monthly-timeline/monthly-report/monthly-report.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-timeline-styled.js +13 -0
- package/dist/features/timeline/monthly-timeline/monthly-timeline-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-timeline-types.js +6 -0
- package/dist/features/timeline/monthly-timeline/monthly-timeline-types.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-timeline-view.js +28 -0
- package/dist/features/timeline/monthly-timeline/monthly-timeline-view.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/monthly-timeline.js +65 -0
- package/dist/features/timeline/monthly-timeline/monthly-timeline.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/api/use-ptm-report-get.js +9 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/api/use-ptm-report-get.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/key-need/key-need-styled.js +9 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/key-need/key-need-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/key-need/key-need.js +35 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/key-need/key-need.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/parent-support/parent-support.js +53 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/parent-support/parent-support.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/real-world-projects/real-world-projects-styled.js +19 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/real-world-projects/real-world-projects-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/real-world-projects/real-world-projects.js +50 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/real-world-projects/real-world-projects.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/report-card/report-card-styled.js +9 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/report-card/report-card-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/report-card/report-card.js +22 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/report-card/report-card.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/school-support/school-support-styled.js +9 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/school-support/school-support-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/school-support/school-support.js +84 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/school-support/school-support.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/strategies/strategies-constant.js +11 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/strategies/strategies-constant.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/strategies/strategies.js +36 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/strategies/strategies.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/strategy-card/strategy-card-styled.js +55 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/strategy-card/strategy-card-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/strategy-card/strategy-card.js +35 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/strategy-card/strategy-card.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/student-info/student-info-styled.js +21 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/student-info/student-info-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/student-info/student-info.js +21 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/student-info/student-info.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/support-card/support-card-styled.js +9 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/support-card/support-card-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/support-card/support-card.js +30 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/support-card/support-card.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/teacher-observations/teacher-observations-constant.js +9 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/teacher-observations/teacher-observations-constant.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/teacher-observations/teacher-observations.js +56 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/teacher-observations/teacher-observations.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/upcoming-chapters/upcoming-chapters.js +15 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/comps/upcoming-chapters/upcoming-chapters.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/ptm-report-constants.js +16 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/ptm-report-constants.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/ptm-report-helpers.js +8 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/ptm-report-helpers.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/ptm-report-styled.js +11 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/ptm-report-styled.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/ptm-report-types.js +5 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/ptm-report-types.js.map +1 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/ptm-report.js +113 -0
- package/dist/features/timeline/monthly-timeline/ptm-report/ptm-report.js.map +1 -0
- package/dist/features/timeline/timeline-tabs/constants.js +17 -0
- package/dist/features/timeline/timeline-tabs/constants.js.map +1 -0
- package/dist/features/timeline/timeline-tabs/timeline-tabs-types.js +5 -0
- package/dist/features/timeline/timeline-tabs/timeline-tabs-types.js.map +1 -0
- package/dist/features/timeline/timeline-tabs/timeline-tabs.js +28 -0
- package/dist/features/timeline/timeline-tabs/timeline-tabs.js.map +1 -0
- package/dist/features/timeline/timeline-tabs/timeline-tabs.styled.js +37 -0
- package/dist/features/timeline/timeline-tabs/timeline-tabs.styled.js.map +1 -0
- package/dist/index.d.ts +169 -15
- package/dist/index.js +327 -313
- package/dist/index.js.map +1 -1
- package/dist/static/2021.2a1a2ec9.svg +1 -0
- package/dist/static/2022.2091553a.svg +1 -0
- package/dist/static/2023.ed718b4e.svg +1 -0
- package/dist/static/2024.aa60edc5.svg +1 -0
- package/dist/static/2025.014a8ad3.svg +1 -0
- package/dist/static/2026.95d70f27.svg +1 -0
- package/dist/static/2027.fe83a41c.svg +1 -0
- package/dist/static/2028.b1c253ef.svg +1 -0
- package/dist/static/apr.cd56f13d.svg +1 -0
- package/dist/static/aug.3ceade02.svg +1 -0
- package/dist/static/calendar_purple_2.6e8249ef.svg +1 -0
- package/dist/static/clock_purple.c774c9bf.svg +1 -0
- package/dist/static/coding-report-icon.91a1e900.svg +1 -0
- package/dist/static/dec.90729a5e.svg +1 -0
- package/dist/static/elp-icon.d45b457d.svg +1 -0
- package/dist/static/empty-reports.fe92faad.svg +1 -0
- package/dist/static/english-icon.50c2e005.svg +1 -0
- package/dist/static/feb.a9ecd320.svg +1 -0
- package/dist/static/full-report.00112c74.svg +1 -0
- package/dist/static/jan.f8fb9c39.svg +1 -0
- package/dist/static/jul.04a98cf0.svg +1 -0
- package/dist/static/jun.9b6ab6bf.svg +1 -0
- package/dist/static/mar.f8b372ef.svg +1 -0
- package/dist/static/math-fit-grey.c32f37b3.svg +1 -0
- package/dist/static/may.23adae48.svg +1 -0
- package/dist/static/no-report.4158fad3.svg +1 -0
- package/dist/static/node-learn-large-bg.faa03631.svg +1 -0
- package/dist/static/node-puzzle-large-bg.ba23382e.svg +1 -0
- package/dist/static/node-test-large-bg.e9120fd1.svg +1 -0
- package/dist/static/nov.c44e4739.svg +1 -0
- package/dist/static/oct.856b3b3f.svg +1 -0
- package/dist/static/progress_bar_purple.2ff4dfe2.svg +1 -0
- package/dist/static/ptm-report-icon.5089218f.svg +1 -0
- package/dist/static/sat-report-icon.4331be86.svg +1 -0
- package/dist/static/science-report-icon.a0014c40.svg +1 -0
- package/dist/static/sep.2d547b31.svg +1 -0
- package/dist/static/thumps-down.a1192a62.svg +1 -0
- package/dist/static/thumps-up.caa35a98.svg +1 -0
- package/package.json +1 -1
- package/dist/features/timeline/api/use-daily-timeline-get.js.map +0 -1
- package/dist/features/timeline/comps/accordion-item/accordion-item.js.map +0 -1
- package/dist/features/timeline/comps/constants.js +0 -22
- package/dist/features/timeline/comps/constants.js.map +0 -1
- package/dist/features/timeline/comps/daily-timeline-items/daily-timeline-items-styled.js.map +0 -1
- package/dist/features/timeline/comps/daily-timeline-items/daily-timeline-items.js.map +0 -1
- package/dist/features/timeline/comps/month-break/month-break-styled.js.map +0 -1
- package/dist/features/timeline/comps/month-break/month-break.js.map +0 -1
- package/dist/features/timeline/comps/no-activity.js.map +0 -1
- package/dist/features/timeline/comps/utils.js.map +0 -1
- package/dist/features/timeline/comps/year-break/year-break-styled.js.map +0 -1
- package/dist/features/timeline/comps/year-break/year-break.js.map +0 -1
- package/dist/features/timeline/daily-timeline-events.js.map +0 -1
- package/dist/features/timeline/daily-timeline-styled.js +0 -21
- package/dist/features/timeline/daily-timeline-styled.js.map +0 -1
- package/dist/features/timeline/daily-timeline-types.js +0 -7
- package/dist/features/timeline/daily-timeline-types.js.map +0 -1
- package/dist/features/timeline/daily-timeline-view.js.map +0 -1
- package/dist/features/timeline/daily-timeline.js.map +0 -1
- package/dist/static/apr.09a50ff7.png +0 -0
- package/dist/static/aug.7179d37e.png +0 -0
- package/dist/static/dec.09f7e315.png +0 -0
- package/dist/static/feb.9e72504d.png +0 -0
- package/dist/static/jan.da91944a.png +0 -0
- package/dist/static/jul.5a1c4932.png +0 -0
- package/dist/static/jun.62639c2f.png +0 -0
- package/dist/static/mar.f51bcfa6.png +0 -0
- package/dist/static/may.7c542020.png +0 -0
- package/dist/static/nov.058343e7.png +0 -0
- package/dist/static/oct.573ee19d.png +0 -0
- package/dist/static/sep.3ccb6468.png +0 -0
- /package/dist/features/timeline/{comps → daily-timeline/comps}/month-break/month-break.js +0 -0
package/dist/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendence-view.js
ADDED
|
@@ -0,0 +1,56 @@
|
|
|
1
|
+
import { jsx as r, jsxs as i, Fragment as h } from "react/jsx-runtime";
|
|
2
|
+
import { memo as u, useCallback as b } from "react";
|
|
3
|
+
import { IS_APP_RUNNING_IN_RN as f } from "../../../../../../constants/app-config.js";
|
|
4
|
+
import A from "../../../../../ui/arrow-tooltip/arrow-tooltip.js";
|
|
5
|
+
import _ from "../../../../../ui/layout/flex-view.js";
|
|
6
|
+
import s from "../../../../../ui/text/text.js";
|
|
7
|
+
import { MONTH_NAMES as C } from "./attendance-constants.js";
|
|
8
|
+
import { getSnackbarMsg as T, getTooltipContent as I } from "./attendance-utils.js";
|
|
9
|
+
import { TooltipWrapper as S, CalendarDay as N, StatusSymbol as B } from "./attendance.styled.js";
|
|
10
|
+
function w({
|
|
11
|
+
day: e,
|
|
12
|
+
reportMonth: l,
|
|
13
|
+
onDateClick: o,
|
|
14
|
+
isSunday: c,
|
|
15
|
+
isLastRow: m
|
|
16
|
+
}) {
|
|
17
|
+
const t = C[l - 1] || "", p = b(() => {
|
|
18
|
+
o == null || o({
|
|
19
|
+
type: "info",
|
|
20
|
+
message: T((e == null ? void 0 : e.classes) || [], `${t} ${(e == null ? void 0 : e.date) ?? ""}`) ?? "",
|
|
21
|
+
bgColor: (e == null ? void 0 : e.snackbarBg) || "WHITE_5"
|
|
22
|
+
});
|
|
23
|
+
}, [t, e == null ? void 0 : e.classes, e == null ? void 0 : e.date, e == null ? void 0 : e.snackbarBg, o]), n = e != null && e.classes ? I(e.classes, t, e.date) : null;
|
|
24
|
+
return /* @__PURE__ */ r(S, { onClick: p, children: /* @__PURE__ */ r(
|
|
25
|
+
A,
|
|
26
|
+
{
|
|
27
|
+
renderAs: "primary",
|
|
28
|
+
position: "top",
|
|
29
|
+
hidden: f || !(e != null && e.hasClasses),
|
|
30
|
+
backgroundColor: (e == null ? void 0 : e.tooltipBgColor) || "WHITE_5",
|
|
31
|
+
tooltipItem: n ? /* @__PURE__ */ i(_, { children: [
|
|
32
|
+
/* @__PURE__ */ r(s, { $align: "center", $renderAs: "ab3", $color: "BLACK_1", children: n.dateAndTime }),
|
|
33
|
+
n.statusLines.map(($, g) => /* @__PURE__ */ r(s, { $align: "center", $renderAs: "ab3", $color: "BLACK_1", children: $ }, g))
|
|
34
|
+
] }) : "",
|
|
35
|
+
children: /* @__PURE__ */ r(
|
|
36
|
+
N,
|
|
37
|
+
{
|
|
38
|
+
$background: (e == null ? void 0 : e.themeColor) || "WHITE_1",
|
|
39
|
+
$justifyContent: "center",
|
|
40
|
+
$alignItems: "center",
|
|
41
|
+
$isSunday: c,
|
|
42
|
+
$isLastRow: m,
|
|
43
|
+
children: e && /* @__PURE__ */ i(h, { children: [
|
|
44
|
+
/* @__PURE__ */ r(s, { $renderAs: "ab2", $color: "BLACK_T_38", children: e.date }),
|
|
45
|
+
/* @__PURE__ */ r(B, { children: !!e.statusSymbol && e.statusSymbol })
|
|
46
|
+
] })
|
|
47
|
+
}
|
|
48
|
+
)
|
|
49
|
+
}
|
|
50
|
+
) });
|
|
51
|
+
}
|
|
52
|
+
const R = u(w);
|
|
53
|
+
export {
|
|
54
|
+
R as default
|
|
55
|
+
};
|
|
56
|
+
//# sourceMappingURL=attendence-view.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"attendence-view.js","sources":["../../../../../../../src/features/timeline/monthly-timeline/monthly-report/comps/attendance/attendence-view.tsx"],"sourcesContent":["import { memo, useCallback } from 'react';\n\nimport { IS_APP_RUNNING_IN_RN } from '../../../../../../constants/app-config';\nimport ArrowTooltip from '../../../../../ui/arrow-tooltip/arrow-tooltip';\nimport FlexView from '../../../../../ui/layout/flex-view';\nimport Text from '../../../../../ui/text/text';\nimport { MONTH_NAMES } from './attendance-constants';\nimport { getSnackbarMsg, getTooltipContent } from './attendance-utils';\nimport * as Styled from './attendance.styled';\nimport type { ICalenderViewProps } from './attendance-types';\n\nfunction AttendanceView({\n day,\n reportMonth,\n onDateClick,\n isSunday,\n isLastRow,\n}: ICalenderViewProps) {\n const currentMonth = MONTH_NAMES[reportMonth - 1] || '';\n\n const handleClick = useCallback(() => {\n onDateClick?.({\n type: 'info',\n message: getSnackbarMsg(day?.classes || [], `${currentMonth} ${day?.date ?? ''}`) ?? '',\n bgColor: day?.snackbarBg || 'WHITE_5',\n });\n }, [currentMonth, day?.classes, day?.date, day?.snackbarBg, onDateClick]);\n\n const tooltipContent = day?.classes\n ? getTooltipContent(day.classes, currentMonth, day.date)\n : null;\n\n return (\n <Styled.TooltipWrapper onClick={handleClick}>\n <ArrowTooltip\n renderAs=\"primary\"\n position=\"top\"\n hidden={IS_APP_RUNNING_IN_RN || !day?.hasClasses}\n backgroundColor={day?.tooltipBgColor || 'WHITE_5'}\n tooltipItem={\n tooltipContent ? (\n <FlexView>\n <Text $align=\"center\" $renderAs=\"ab3\" $color=\"BLACK_1\">\n {tooltipContent.dateAndTime}\n </Text>\n {tooltipContent.statusLines.map((statusLine, index) => (\n <Text $align=\"center\" $renderAs=\"ab3\" $color=\"BLACK_1\" key={index}>\n {statusLine}\n </Text>\n ))}\n </FlexView>\n ) : (\n ''\n )\n }\n >\n <Styled.CalendarDay\n $background={day?.themeColor || 'WHITE_1'}\n $justifyContent=\"center\"\n $alignItems=\"center\"\n $isSunday={isSunday}\n $isLastRow={isLastRow}\n >\n {day && (\n <>\n <Text $renderAs=\"ab2\" $color=\"BLACK_T_38\">\n {day.date}\n </Text>\n <Styled.StatusSymbol>{!!day.statusSymbol && day.statusSymbol}</Styled.StatusSymbol>\n </>\n )}\n </Styled.CalendarDay>\n </ArrowTooltip>\n </Styled.TooltipWrapper>\n );\n}\n\nexport default memo(AttendanceView);\n"],"names":["AttendanceView","day","reportMonth","onDateClick","isSunday","isLastRow","currentMonth","MONTH_NAMES","handleClick","useCallback","getSnackbarMsg","tooltipContent","getTooltipContent","jsx","Styled.TooltipWrapper","ArrowTooltip","IS_APP_RUNNING_IN_RN","jsxs","FlexView","Text","statusLine","index","Styled.CalendarDay","Fragment","Styled.StatusSymbol","AttendenceView","memo"],"mappings":";;;;;;;;;AAWA,SAASA,EAAe;AAAA,EACtB,KAAAC;AAAA,EACA,a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A,EAAK,eAAc;AAAA,UAChC,iBAAgB;AAAA,UAChB,aAAY;AAAA,UACZ,WAAWG;AAAA,UACX,YAAYC;AAAA,UAEX,eAEG,gBAAAY,EAAAM,GAAA,EAAA,UAAA;AAAA,YAAA,gBAAAV,EAACM,KAAK,WAAU,OAAM,QAAO,cAC1B,YAAI,MACP;AAAA,YACA,gBAAAN,EAACW,GAAA,EAAqB,WAAC,CAACvB,EAAI,gBAAgBA,EAAI,cAAa;AAAA,UAAA,GAC/D;AAAA,QAAA;AAAA,MAEJ;AAAA,IAAA;AAAA,EAEJ,EAAA,CAAA;AAEJ;AAEA,MAAewB,IAAAC,EAAK1B,CAAc;"}
|
package/dist/features/timeline/monthly-timeline/monthly-report/comps/feedback/feedback-styled.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"feedback-styled.js","sources":["../../../../../../../src/features/timeline/monthly-timeline/monthly-report/comps/feedback/feedback-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport FlexView from '../../../../../ui/layout/flex-view';\n\nexport const FeedbackContainer = styled(FlexView)`\n margin: 0 -16px;\n`;\n"],"names":["FeedbackContainer","styled","FlexView"],"mappings":";;AAIa,MAAAA,IAAoBC,EAAOC,CAAQ;AAAA;AAAA;"}
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import { jsxs as a, jsx as t } from "react/jsx-runtime";
|
|
2
|
+
import { memo as b, useCallback as c } from "react";
|
|
3
|
+
import l from "../../../../../ui/layout/flex-view.js";
|
|
4
|
+
import { ILLUSTRATIONS as g } from "../../../../../../assets/illustrations/illustrations.js";
|
|
5
|
+
import f from "../../../../../ui/image/image.js";
|
|
6
|
+
import { invalidateMonthlyReport as u, monthlyReportPatch as A } from "../../api/use-monthly-report-api.js";
|
|
7
|
+
import C from "../../../../../ui/separator/separator.js";
|
|
8
|
+
import P from "../../../../../ui/text/text.js";
|
|
9
|
+
import { FeedbackContainer as R } from "./feedback-styled.js";
|
|
10
|
+
import { useUIContext as X } from "../../../../../ui/context/context.js";
|
|
11
|
+
import { MONTHLY_REPORT_ANALYTICS_EVENTS as p } from "../../monthly-report-events.js";
|
|
12
|
+
const k = ({
|
|
13
|
+
reportId: e,
|
|
14
|
+
studentName: d,
|
|
15
|
+
onFeedback: m,
|
|
16
|
+
studentCourseId: s,
|
|
17
|
+
showSnackbar: h
|
|
18
|
+
}) => {
|
|
19
|
+
const E = c(
|
|
20
|
+
(i, n) => {
|
|
21
|
+
i && h && h({
|
|
22
|
+
type: "error",
|
|
23
|
+
message: "Something went wrong. Please try again.",
|
|
24
|
+
bgColor: "red"
|
|
25
|
+
}), !i && m && (n != null && n.feedback) && (u(e), m(n.feedback, s));
|
|
26
|
+
},
|
|
27
|
+
[m, e, h, s]
|
|
28
|
+
), { onEvent: o } = X(), { patch: $ } = A({
|
|
29
|
+
onComplete: E
|
|
30
|
+
}), r = c(
|
|
31
|
+
(i) => {
|
|
32
|
+
$(e, { feedback: i });
|
|
33
|
+
},
|
|
34
|
+
[e, $]
|
|
35
|
+
), _ = c(() => {
|
|
36
|
+
o(p.REPORT_POSITIVE_FEEDBACK_CLICKED, {
|
|
37
|
+
report_id: e
|
|
38
|
+
}), r("positive");
|
|
39
|
+
}, [r, e, o]), T = c(() => {
|
|
40
|
+
o(p.REPORT_NEGATIVE_FEEDBACK_CLICKED, {
|
|
41
|
+
report_id: e
|
|
42
|
+
}), r("negative");
|
|
43
|
+
}, [r, e, o]);
|
|
44
|
+
return /* @__PURE__ */ a(R, { $gapX: 1.25, $background: "WHITE_3", children: [
|
|
45
|
+
/* @__PURE__ */ t(l, { $gutterX: 1, children: /* @__PURE__ */ a(P, { $renderAs: "ab2-black", $color: "BLACK_1", $align: "center", children: [
|
|
46
|
+
"Are you happy with ",
|
|
47
|
+
d ?? "her",
|
|
48
|
+
" progress?"
|
|
49
|
+
] }) }),
|
|
50
|
+
/* @__PURE__ */ t(C, { heightX: 1.5 }),
|
|
51
|
+
/* @__PURE__ */ a(l, { $flexDirection: "row", $flexGapX: 3, $alignItems: "center", $justifyContent: "center", children: [
|
|
52
|
+
/* @__PURE__ */ t(
|
|
53
|
+
l,
|
|
54
|
+
{
|
|
55
|
+
$widthX: 5,
|
|
56
|
+
$heightX: 5,
|
|
57
|
+
$alignItems: "center",
|
|
58
|
+
$justifyContent: "center",
|
|
59
|
+
$borderRadiusX: 2.5,
|
|
60
|
+
$borderColor: "BLACK_5",
|
|
61
|
+
onClick: _,
|
|
62
|
+
children: /* @__PURE__ */ t(f, { src: g.THUMPS_UP, alt: "UP", width: 32, height: 32 })
|
|
63
|
+
}
|
|
64
|
+
),
|
|
65
|
+
/* @__PURE__ */ t(
|
|
66
|
+
l,
|
|
67
|
+
{
|
|
68
|
+
$widthX: 5,
|
|
69
|
+
$heightX: 5,
|
|
70
|
+
$alignItems: "center",
|
|
71
|
+
$justifyContent: "center",
|
|
72
|
+
$borderColor: "BLACK_5",
|
|
73
|
+
$borderRadiusX: 2.5,
|
|
74
|
+
onClick: T,
|
|
75
|
+
children: /* @__PURE__ */ t(f, { src: g.THUMPS_DOWN, alt: "DOWN", width: 32, height: 32 })
|
|
76
|
+
}
|
|
77
|
+
)
|
|
78
|
+
] }),
|
|
79
|
+
/* @__PURE__ */ t(C, { heightX: 1.5 })
|
|
80
|
+
] });
|
|
81
|
+
}, I = b(k);
|
|
82
|
+
export {
|
|
83
|
+
I as default
|
|
84
|
+
};
|
|
85
|
+
//# sourceMappingURL=feedback.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"feedback.js","sources":["../../../../../../../src/features/timeline/monthly-timeline/monthly-report/comps/feedback/feedback.tsx"],"sourcesContent":["import { memo, useCallback } from 'react';\n\nimport type { IMonthlyReportResponse, TFeedback } from '../../monthly-report-types';\nimport type { IFeedbackTypesProps } from './feedback-types';\nimport FlexView from '../../../../../ui/layout/flex-view';\nimport { ILLUSTRATIONS } from '../../../../../../assets/illustrations/illustrations';\nimport Image from '../../../../../ui/image/image';\nimport { invalidateMonthlyReport, monthlyReportPatch } from '../../api/use-monthly-report-api';\nimport Separator from '../../../../../ui/separator/separator';\nimport Text from '../../../../../ui/text/text';\nimport * as Styled from './feedback-styled';\nimport { useUIContext } from '../../../../../ui/context/context';\nimport { MONTHLY_REPORT_ANALYTICS_EVENTS } from '../../monthly-report-events';\n\nconst Feedback = ({\n reportId,\n studentName,\n onFeedback,\n studentCourseId,\n showSnackbar,\n}: IFeedbackTypesProps) => {\n const onComplete = useCallback(\n (err: string | null, data?: IMonthlyReportResponse) => {\n if (err && showSnackbar) {\n showSnackbar({\n type: 'error',\n message: 'Something went wrong. Please try again.',\n bgColor: 'red',\n });\n }\n\n if (!err && onFeedback && data?.feedback) {\n invalidateMonthlyReport(reportId);\n onFeedback(data.feedback, studentCourseId);\n }\n },\n [onFeedback, reportId, showSnackbar, studentCourseId],\n );\n const { onEvent: trackEvent } = useUIContext();\n\n const { patch: updateMilestone } = monthlyReportPatch({\n onComplete,\n });\n\n const handleFeedback = useCallback(\n (feedback: TFeedback) => {\n updateMilestone(reportId, { feedback });\n },\n [reportId, updateMilestone],\n );\n\n const handlePositiveFeedback = useCallback(() => {\n trackEvent(MONTHLY_REPORT_ANALYTICS_EVENTS.REPORT_POSITIVE_FEEDBACK_CLICKED, {\n report_id: reportId,\n });\n handleFeedback('positive');\n }, [handleFeedback, reportId, trackEvent]);\n\n const handleNegativeFeedback = useCallback(() => {\n trackEvent(MONTHLY_REPORT_ANALYTICS_EVENTS.REPORT_NEGATIVE_FEEDBACK_CLICKED, {\n report_id: reportId,\n });\n handleFeedback('negative');\n }, [handleFeedback, reportId, trackEvent]);\n\n return (\n <Styled.FeedbackContainer $gapX={1.25} $background=\"WHITE_3\">\n <FlexView $gutterX={1}>\n <Text $renderAs=\"ab2-black\" $color=\"BLACK_1\" $align=\"center\">\n Are you happy with {studentName ?? 'her'} progress?\n </Text>\n </FlexView>\n <Separator heightX={1.5} />\n <FlexView $flexDirection=\"row\" $flexGapX={3} $alignItems=\"center\" $justifyContent=\"center\">\n <FlexView\n $widthX={5}\n $heightX={5}\n $alignItems=\"center\"\n $justifyContent=\"center\"\n $borderRadiusX={2.5}\n $borderColor=\"BLACK_5\"\n onClick={handlePositiveFeedback}\n >\n <Image src={ILLUSTRATIONS.THUMPS_UP} alt=\"UP\" width={32} height={32} />\n </FlexView>\n <FlexView\n $widthX={5}\n $heightX={5}\n $alignItems=\"center\"\n $justifyContent=\"center\"\n $borderColor=\"BLACK_5\"\n $borderRadiusX={2.5}\n onClick={handleNegativeFeedback}\n >\n <Image src={ILLUSTRATIONS.THUMPS_DOWN} alt=\"DOWN\" width={32} height={32} />\n </FlexView>\n </FlexView>\n <Separator heightX={1.5} />\n </Styled.FeedbackContainer>\n );\n};\n\nexport default memo(Feedback);\n"],"names":["Feedback","reportId","studentName","onFeedback","studentCourseId","showSnackbar","onComplete","useCallback","err","data","invalidateMonthlyReport","trackEvent","useUIContext","updateMilestone","monthlyReportPatch","handleFeedback","feedback","handlePositiveFeedback","MONTHLY_REPORT_ANALYTICS_EVENTS","handleNegativeFeedback","Styled.FeedbackContainer","jsx","FlexView","jsxs","Text","Separator","Image","ILLUSTRATIONS","Feedback$1","memo"],"mappings":";;;;;;;;;;;AAcA,MAAMA,IAAW,CAAC;AAAA,EAChB,UAAAC;AAAA,EACA,aAAAC;AAAA,EACA,YAAAC;AAAA,EACA,iBAAAC;AAAA,EACA,cAAAC;AACF,MAA2B;AACzB,QAAMC,IAAaC;AAAA,IACjB,CAACC,GAAoBC,MAAkC;AACrD,MAAID,KAAOH,KACIA,EAAA;AAAA,QACX,MAAM;AAAA,QACN,SAAS;AAAA,QACT,SAAS;AAAA,MAAA,CACV,GAGC,CAACG,KAAOL,MAAcM,KAAA,QAAAA,EAAM,cAC9BC,EAAwBT,CAAQ,GACrBE,EAAAM,EAAK,UAAUL,CAAe;AAAA,IAE7C;AAAA,IACA,CAACD,GAAYF,GAAUI,GAAcD,CAAe;AAAA,EAAA,GAEhD,EAAE,S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AKC,EAAc,WAAW,KAAI,MAAK,OAAO,IAAI,QAAQ,GAAI,CAAA;AAAA,QAAA;AAAA,MACvE;AAAA,MACA,gBAAAN;AAAA,QAACC;AAAA,QAAA;AAAA,UACC,SAAS;AAAA,UACT,UAAU;AAAA,UACV,aAAY;AAAA,UACZ,iBAAgB;AAAA,UAChB,cAAa;AAAA,UACb,gBAAgB;AAAA,UAChB,SAASH;AAAA,UAET,UAAA,gBAAAE,EAACK,GAAM,EAAA,KAAKC,EAAc,aAAa,KAAI,QAAO,OAAO,IAAI,QAAQ,GAAI,CAAA;AAAA,QAAA;AAAA,MAC3E;AAAA,IAAA,GACF;AAAA,IACA,gBAAAN,EAACI,GAAU,EAAA,SAAS,IAAK,CAAA;AAAA,EAC3B,EAAA,CAAA;AAEJ,GAEeG,IAAAC,EAAK7B,CAAQ;"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { jsxs as e, jsx as n } from "react/jsx-runtime";
|
|
2
|
+
import i from "../../../../../../ui/text/text.js";
|
|
3
|
+
import c from "../../../../../../ui/layout/flex-view.js";
|
|
4
|
+
import C from "../../../../../../chapters/chapters-list/chapter-item/chapter-circular-progress/chapter-circular-progress.js";
|
|
5
|
+
import { calculateProgress as g } from "../goals-constants.js";
|
|
6
|
+
const E = ({ chapters: t }) => !t || t.length === 0 ? null : t.map((o, u) => {
|
|
7
|
+
const { completed: _, total: a } = o.progress_stat, { completed: $, total: m } = o.previous_progress_stat || {}, r = g(_, a), d = g($ || 0, m || 0), s = r - d, l = o.previous_progress_stat && s > 0 && a === m, f = l ? s : 0, p = r === 100;
|
|
8
|
+
return /* @__PURE__ */ e(
|
|
9
|
+
c,
|
|
10
|
+
{
|
|
11
|
+
$flexDirection: "row",
|
|
12
|
+
$flexGapX: 1,
|
|
13
|
+
$gutterX: 1,
|
|
14
|
+
children: [
|
|
15
|
+
o.image_url && /* @__PURE__ */ n(
|
|
16
|
+
C,
|
|
17
|
+
{
|
|
18
|
+
completionPercentage: l ? d : r,
|
|
19
|
+
imageUrl: o.image_url,
|
|
20
|
+
delta: f,
|
|
21
|
+
imageWidth: 42,
|
|
22
|
+
iconWidth: 16,
|
|
23
|
+
deltaProgressColor: "GREEN_5",
|
|
24
|
+
iconColor: "WHITE",
|
|
25
|
+
iconBackgroundColor: "BLACK_1",
|
|
26
|
+
iconPosition: { top: 0, right: 0 }
|
|
27
|
+
}
|
|
28
|
+
),
|
|
29
|
+
/* @__PURE__ */ e(c, { children: [
|
|
30
|
+
/* @__PURE__ */ n(i, { $renderAs: "ub2", $color: "BLACK_1", children: o.chapter_name }),
|
|
31
|
+
/* @__PURE__ */ e(c, { $flexDirection: "row", $alignItems: "center", $flexGapX: 0.25, children: [
|
|
32
|
+
/* @__PURE__ */ n(i, { $renderAs: "ub3", $color: "BLACK_T_60", children: p ? "Completed" : `${r}% completed` }),
|
|
33
|
+
l && !p && /* @__PURE__ */ e(i, { $renderAs: "ab3", $color: "GREEN_6", children: [
|
|
34
|
+
"(+",
|
|
35
|
+
Math.round(s),
|
|
36
|
+
"%)"
|
|
37
|
+
] })
|
|
38
|
+
] })
|
|
39
|
+
] })
|
|
40
|
+
]
|
|
41
|
+
},
|
|
42
|
+
`${o.chapter_name}-${u}`
|
|
43
|
+
);
|
|
44
|
+
});
|
|
45
|
+
export {
|
|
46
|
+
E as default
|
|
47
|
+
};
|
|
48
|
+
//# sourceMappingURL=goal-chapter-card.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"goal-chapter-card.js","sources":["../../../../../../../../src/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-card/goal-chapter-card.tsx"],"sourcesContent":["import { type FC } from 'react';\n\nimport { type IGoalsCardChaptersProps } from './goals-card-types';\nimport Text from '../../../../../../ui/text/text';\nimport FlexView from '../../../../../../ui/layout/flex-view';\nimport ChapterCircularProgress from '../../../../../../chapters/chapters-list/chapter-item/chapter-circular-progress/chapter-circular-progress';\nimport { calculateProgress } from '../goals-constants';\n\nconst GoalsCardChapters: FC<IGoalsCardChaptersProps> = ({ chapters }) => {\n if (!chapters || chapters.length === 0) {\n return null;\n }\n\n return chapters.map((chapter, i) => {\n const { completed, total } = chapter.progress_stat;\n const { completed: prevCompleted, total: prevTotal } = chapter.previous_progress_stat || {};\n const progress = calculateProgress(completed, total);\n const previousProgress = calculateProgress(prevCompleted || 0, prevTotal || 0);\n const progressDifference = progress - previousProgress;\n const showDelta =\n chapter.previous_progress_stat && progressDifference > 0 && total === prevTotal;\n const delta = showDelta ? progressDifference : 0;\n const isCompoleted = progress === 100;\n\n return (\n <FlexView\n $flexDirection=\"row\"\n $flexGapX={1}\n $gutterX={1}\n key={`${chapter.chapter_name}-${i}`}\n >\n {chapter.image_url && (\n <ChapterCircularProgress\n completionPercentage={showDelta ? previousProgress : progress}\n imageUrl={chapter.image_url}\n delta={delta}\n imageWidth={42}\n iconWidth={16}\n deltaProgressColor=\"GREEN_5\"\n iconColor=\"WHITE\"\n iconBackgroundColor=\"BLACK_1\"\n iconPosition={{ top: 0, right: 0 }}\n />\n )}\n <FlexView>\n <Text $renderAs=\"ub2\" $color=\"BLACK_1\">\n {chapter.chapter_name}\n </Text>\n <FlexView $flexDirection=\"row\" $alignItems=\"center\" $flexGapX={0.25}>\n <Text $renderAs=\"ub3\" $color=\"BLACK_T_60\">\n {isCompoleted ? 'Completed' : `${progress}% completed`}\n </Text>\n {showDelta && !isCompoleted && (\n <Text $renderAs=\"ab3\" $color=\"GREEN_6\">\n (+{Math.round(progressDifference)}%)\n </Text>\n )}\n </FlexView>\n </FlexView>\n </FlexView>\n );\n });\n};\n\nexport default GoalsCardChapters;\n"],"names":["GoalsCardChapters","chapters","chapter","i","completed","total","prevCompleted","prevTotal","progress","calculateProgress","previousProgress","progressDifference","showDelta","delta","isCompoleted","jsxs","FlexView","jsx","ChapterCircularProgress","Text"],"mappings":";;;;;AAQA,MAAMA,IAAiD,CAAC,EAAE,UAAAC,QACpD,CAACA,KAAYA,EAAS,WAAW,IAC5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J;AAAA,QAAA,GACF;AAAA,MAAA;AAAA,IAAA;AAAA,IA7BK,GAAGT,EAAQ,YAAY,IAAIC,CAAC;AAAA,EAAA;AA8BnC,CAEH;"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import o from "styled-components";
|
|
2
|
+
import t from "../../../../../../ui/layout/flex-view.js";
|
|
3
|
+
const p = o(t)`
|
|
4
|
+
position: absolute;
|
|
5
|
+
bottom: 0px;
|
|
6
|
+
left: 0;
|
|
7
|
+
right: 0;
|
|
8
|
+
`, s = o(t)`
|
|
9
|
+
border-top: none;
|
|
10
|
+
`, a = o(t)`
|
|
11
|
+
position: relative;
|
|
12
|
+
&::after {
|
|
13
|
+
content: '';
|
|
14
|
+
position: absolute;
|
|
15
|
+
height: 12px;
|
|
16
|
+
width: 20px;
|
|
17
|
+
left: 10px;
|
|
18
|
+
top: -8px;
|
|
19
|
+
clip-path: polygon(50% 0%, 0% 100%, 100% 100%);
|
|
20
|
+
background-color: ${({ theme: e, $background: r }) => e.colors[r ?? "WHITE_1"]};
|
|
21
|
+
}
|
|
22
|
+
`;
|
|
23
|
+
export {
|
|
24
|
+
s as ChaptersContainer,
|
|
25
|
+
p as ProgressBarContainer,
|
|
26
|
+
a as TagContainer
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=goals-card-styled.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"goals-card-styled.js","sources":["../../../../../../../../src/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-card/goals-card-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport FlexView from '../../../../../../ui/layout/flex-view';\n\nexport const ProgressBarContainer = styled(FlexView)`\n position: absolute;\n bottom: 0px;\n left: 0;\n right: 0;\n`;\n\nexport const ChaptersContainer = styled(FlexView)`\n border-top: none;\n`;\n\nexport const TagContainer = styled(FlexView)`\n position: relative;\n &::after {\n content: '';\n position: absolute;\n height: 12px;\n width: 20px;\n left: 10px;\n top: -8px;\n clip-path: polygon(50% 0%, 0% 100%, 100% 100%);\n background-color: ${({ theme, $background }) => theme.colors[$background ?? 'WHITE_1']};\n }\n`;\n"],"names":["ProgressBarContainer","styled","FlexView","ChaptersContainer","TagContainer","theme","$background"],"mappings":";;AAIa,MAAAA,IAAuBC,EAAOC,CAAQ;AAAA;AAAA;AAAA;AAAA;AAAA,GAOtCC,IAAoBF,EAAOC,CAAQ;AAAA;AAAA,GAInCE,IAAeH,EAAOC,CAAQ;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,wBAUnB,CAAC,EAAE,OAAAG,GAAO,aAAAC,QAAkBD,EAAM,OAAOC,KAAe,SAAS,CAAC;AAAA;AAAA;"}
|
package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-card/goals-card.js
ADDED
|
@@ -0,0 +1,118 @@
|
|
|
1
|
+
import { jsxs as e, jsx as r, Fragment as h } from "react/jsx-runtime";
|
|
2
|
+
import { memo as F, useState as H, useMemo as O, useCallback as W } from "react";
|
|
3
|
+
import { GOAL_CATEGORY_CONFIG as j, calculateProgress as B } from "../goals-constants.js";
|
|
4
|
+
import { ProgressBarContainer as z, TagContainer as y, ChaptersContainer as E } from "./goals-card-styled.js";
|
|
5
|
+
import s from "../../../../../../ui/text/text.js";
|
|
6
|
+
import t from "../../../../../../ui/layout/flex-view.js";
|
|
7
|
+
import m from "../../../../../../ui/separator/separator.js";
|
|
8
|
+
import V from "../../../../../../ui/image/image.js";
|
|
9
|
+
import G from "./goal-chapter-card.js";
|
|
10
|
+
import Y from "../../../../../../ui/linear-progress-bar/linear-progress-bar.js";
|
|
11
|
+
import T from "../../../../../../ui/buttons/text-button/text-button.js";
|
|
12
|
+
const q = ({ category: C, milestone: L, isExpended: o = !1 }) => {
|
|
13
|
+
const [g, v] = H(!1), {
|
|
14
|
+
milestone_name: P,
|
|
15
|
+
user_chapters: p,
|
|
16
|
+
progress_stat: k,
|
|
17
|
+
previous_progress_stat: n
|
|
18
|
+
} = L, { completed: I, total: a } = k, { completed: $, total: u } = n ?? {}, c = B(I, a), f = n && $ && u ? B($, u) : 0, i = c - f, d = !!(n && i > 0 && a === a), x = !!(n && i <= 0 && a !== a), _ = c === 100, K = Math.round(c), S = Math.round(i), b = p.length, D = p.slice(0, 2), A = Math.max(0, b - 2), M = g ? p.slice(2) : [], N = A > 0, l = O(() => j[C], [C]), X = l.icon, w = W(() => {
|
|
19
|
+
v((R) => !R);
|
|
20
|
+
}, []);
|
|
21
|
+
return /* @__PURE__ */ e(t, { children: [
|
|
22
|
+
/* @__PURE__ */ e(
|
|
23
|
+
t,
|
|
24
|
+
{
|
|
25
|
+
$position: "relative",
|
|
26
|
+
$background: l.backgroundColor,
|
|
27
|
+
$borderColor: o ? "WHITE_5" : void 0,
|
|
28
|
+
$gutterX: 1,
|
|
29
|
+
$gapX: 1,
|
|
30
|
+
$height: o ? "auto" : 72,
|
|
31
|
+
children: [
|
|
32
|
+
/* @__PURE__ */ e(t, { $flexDirection: "row", $flexGapX: o ? 1 : 0.5, children: [
|
|
33
|
+
X && /* @__PURE__ */ r(
|
|
34
|
+
V,
|
|
35
|
+
{
|
|
36
|
+
src: X,
|
|
37
|
+
withLoader: !0,
|
|
38
|
+
width: o ? 40 : 32,
|
|
39
|
+
height: o ? 40 : 32,
|
|
40
|
+
alt: l.label
|
|
41
|
+
}
|
|
42
|
+
),
|
|
43
|
+
/* @__PURE__ */ e(t, { children: [
|
|
44
|
+
o && /* @__PURE__ */ e(h, { children: [
|
|
45
|
+
/* @__PURE__ */ r(s, { $renderAs: "ac5", $color: l.labelColor, children: l.label }),
|
|
46
|
+
/* @__PURE__ */ r(m, { heightX: 0.25 })
|
|
47
|
+
] }),
|
|
48
|
+
/* @__PURE__ */ r(s, { $renderAs: "ab2", $color: "BLACK_1", children: P }),
|
|
49
|
+
/* @__PURE__ */ r(m, { heightX: o ? 0.5 : 0.125 }),
|
|
50
|
+
/* @__PURE__ */ e(t, { $flexDirection: "row", $alignItems: "center", $flexGapX: 0.25, children: [
|
|
51
|
+
/* @__PURE__ */ r(s, { $renderAs: "ab3", $color: "BLACK_T_60", children: _ ? "Completed" : `${K}% complete` }),
|
|
52
|
+
d && !_ && /* @__PURE__ */ e(s, { $renderAs: "ab3", $color: "GREEN_6", children: [
|
|
53
|
+
"(+",
|
|
54
|
+
S,
|
|
55
|
+
"%)"
|
|
56
|
+
] })
|
|
57
|
+
] })
|
|
58
|
+
] }),
|
|
59
|
+
/* @__PURE__ */ r(z, { children: /* @__PURE__ */ r(
|
|
60
|
+
Y,
|
|
61
|
+
{
|
|
62
|
+
percentage: d ? f : c,
|
|
63
|
+
delta: d ? i : 0,
|
|
64
|
+
height: 4,
|
|
65
|
+
backgroundColor: "WHITE_5",
|
|
66
|
+
fillColor: "BLACK_1",
|
|
67
|
+
deltaProgressColor: "GREEN_5"
|
|
68
|
+
}
|
|
69
|
+
) })
|
|
70
|
+
] }),
|
|
71
|
+
x && /* @__PURE__ */ e(h, { children: [
|
|
72
|
+
/* @__PURE__ */ r(m, { heightX: 0.875 }),
|
|
73
|
+
/* @__PURE__ */ r(y, { $gapX: 0.5, $gutterX: 1, $background: l.tagColor, children: /* @__PURE__ */ r(s, { $renderAs: "ub3", $color: "BLACK_1", children: "Learning plan was modified — progress updated accordingly." }) })
|
|
74
|
+
] })
|
|
75
|
+
]
|
|
76
|
+
}
|
|
77
|
+
),
|
|
78
|
+
o && b > 0 && /* @__PURE__ */ e(
|
|
79
|
+
E,
|
|
80
|
+
{
|
|
81
|
+
$gapX: 1,
|
|
82
|
+
$flexDirection: "column",
|
|
83
|
+
$flexGapX: 1.25,
|
|
84
|
+
$borderColor: "WHITE_5",
|
|
85
|
+
children: [
|
|
86
|
+
/* @__PURE__ */ r(G, { chapters: D }),
|
|
87
|
+
N && /* @__PURE__ */ e(h, { children: [
|
|
88
|
+
!g && /* @__PURE__ */ r(t, { $gutterX: 4.5, children: /* @__PURE__ */ r(
|
|
89
|
+
T,
|
|
90
|
+
{
|
|
91
|
+
label: `+${A} chapters`,
|
|
92
|
+
size: "regular",
|
|
93
|
+
color: "BLACK_1",
|
|
94
|
+
onClick: w
|
|
95
|
+
}
|
|
96
|
+
) }),
|
|
97
|
+
g && /* @__PURE__ */ e(h, { children: [
|
|
98
|
+
/* @__PURE__ */ r(G, { chapters: M }),
|
|
99
|
+
/* @__PURE__ */ r(t, { $gutterX: 4.5, children: /* @__PURE__ */ r(
|
|
100
|
+
T,
|
|
101
|
+
{
|
|
102
|
+
label: "Show less",
|
|
103
|
+
size: "regular",
|
|
104
|
+
color: "BLACK_1",
|
|
105
|
+
onClick: w
|
|
106
|
+
}
|
|
107
|
+
) })
|
|
108
|
+
] })
|
|
109
|
+
] })
|
|
110
|
+
]
|
|
111
|
+
}
|
|
112
|
+
)
|
|
113
|
+
] });
|
|
114
|
+
}, nr = F(q);
|
|
115
|
+
export {
|
|
116
|
+
nr as default
|
|
117
|
+
};
|
|
118
|
+
//# sourceMappingURL=goals-card.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"goals-card.js","sources":["../../../../../../../../src/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-card/goals-card.tsx"],"sourcesContent":["import { type FC, memo, useCallback, useMemo, useState } from 'react';\n\nimport { type IGoalsCardProps } from '../goals-types';\nimport { calculateProgress, GOAL_CATEGORY_CONFIG } from '../goals-constants';\nimport * as Styled from './goals-card-styled';\nimport Text from '../../../../../../ui/text/text';\nimport FlexView from '../../../../../../ui/layout/flex-view';\nimport Separator from '../../../../../../ui/separator/separator';\nimport Image from '../../../../../../ui/image/image';\nimport GoalsCardChapters from './goal-chapter-card';\nimport LinearProgressBar from '../../../../../../ui/linear-progress-bar/linear-progress-bar';\nimport TextButton from '../../../../../../ui/buttons/text-button/text-button';\n\nconst GoalsCard: FC<IGoalsCardProps> = ({ category, milestone, isExpended = false }) => {\n const [showAllChapters, setShowAllChapters] = useState(false);\n const {\n milestone_name: milestoneName,\n user_chapters: userChapters,\n progress_stat: progressStat,\n previous_progress_stat: prevProgressStat,\n } = milestone;\n const { completed, total } = progressStat;\n const { completed: prevCompleted, total: prevTotal } = prevProgressStat ?? {};\n const currentProgress = calculateProgress(completed, total);\n const previousProgress =\n prevProgressStat && prevCompleted && prevTotal\n ? calculateProgress(prevCompleted, prevTotal)\n : 0;\n\n const progressDifference = currentProgress - previousProgress;\n const showIndicator = Boolean(prevProgressStat && progressDifference > 0 && total === total);\n const showTag = Boolean(prevProgressStat && progressDifference <= 0 && total !== total);\n const isCompleted = currentProgress === 100;\n const roundedProgress = Math.round(currentProgress);\n const roundedDifference = Math.round(progressDifference);\n\n const totalChapters = userChapters.length;\n const visibleChapters = userChapters.slice(0, 2);\n const remainingChapters = Math.max(0, totalChapters - 2);\n const hiddenChapters = showAllChapters ? userChapters.slice(2) : [];\n const hasRemainingChapters = remainingChapters > 0;\n\n const categoryConfig = useMemo(() => GOAL_CATEGORY_CONFIG[category], [category]);\n const icon = categoryConfig.icon;\n\n const handleToggleChapters = useCallback(() => {\n setShowAllChapters(prev => !prev);\n }, []);\n\n return (\n <FlexView>\n <FlexView\n $position=\"relative\"\n $background={categoryConfig.backgroundColor}\n $borderColor={isExpended ? 'WHITE_5' : undefined}\n $gutterX={1}\n $gapX={1}\n $height={isExpended ? 'auto' : 72}\n >\n <FlexView $flexDirection=\"row\" $flexGapX={isExpended ? 1 : 0.5}>\n {icon && (\n <Image\n src={icon}\n withLoader\n width={isExpended ? 40 : 32}\n height={isExpended ? 40 : 32}\n alt={categoryConfig.label}\n />\n )}\n <FlexView>\n {isExpended && (\n <>\n <Text $renderAs=\"ac5\" $color={categoryConfig.labelColor}>\n {categoryConfig.label}\n </Text>\n <Separator heightX={0.25} />\n </>\n )}\n <Text $renderAs=\"ab2\" $color=\"BLACK_1\">\n {milestoneName}\n </Text>\n <Separator heightX={isExpended ? 0.5 : 0.125} />\n <FlexView $flexDirection=\"row\" $alignItems=\"center\" $flexGapX={0.25}>\n <Text $renderAs=\"ab3\" $color=\"BLACK_T_60\">\n {isCompleted ? 'Completed' : `${roundedProgress}% complete`}\n </Text>\n {showIndicator && !isCompleted && (\n <Text $renderAs=\"ab3\" $color=\"GREEN_6\">\n (+{roundedDifference}%)\n </Text>\n )}\n </FlexView>\n </FlexView>\n <Styled.ProgressBarContainer>\n <LinearProgressBar\n percentage={showIndicator ? previousProgress : currentProgress}\n delta={showIndicator ? progressDifference : 0}\n height={4}\n backgroundColor=\"WHITE_5\"\n fillColor=\"BLACK_1\"\n deltaProgressColor=\"GREEN_5\"\n />\n </Styled.ProgressBarContainer>\n </FlexView>\n {showTag && (\n <>\n <Separator heightX={0.875} />\n <Styled.TagContainer $gapX={0.5} $gutterX={1} $background={categoryConfig.tagColor}>\n <Text $renderAs=\"ub3\" $color=\"BLACK_1\">\n Learning plan was modified — progress updated accordingly.\n </Text>\n </Styled.TagContainer>\n </>\n )}\n </FlexView>\n {isExpended && totalChapters > 0 && (\n <Styled.ChaptersContainer\n $gapX={1}\n $flexDirection=\"column\"\n $flexGapX={1.25}\n $borderColor=\"WHITE_5\"\n >\n <GoalsCardChapters chapters={visibleChapters} />\n {hasRemainingChapters && (\n <>\n {!showAllChapters && (\n <FlexView $gutterX={4.5}>\n <TextButton\n label={`+${remainingChapters} chapters`}\n size=\"regular\"\n color=\"BLACK_1\"\n onClick={handleToggleChapters}\n />\n </FlexView>\n )}\n {showAllChapters && (\n <>\n <GoalsCardChapters chapters={hiddenChapters} />\n <FlexView $gutterX={4.5}>\n <TextButton\n label=\"Show less\"\n size=\"regular\"\n color=\"BLACK_1\"\n onClick={handleToggleChapters}\n />\n </FlexView>\n </>\n )}\n </>\n )}\n </Styled.ChaptersContainer>\n )}\n </FlexView>\n );\n};\n\nexport default memo(GoalsCard);\n"],"names":["GoalsCard","category","milestone","isExpended","showAllChapters","setShowAllChapters","useState","milestoneName","userChapters","progressStat","prevProgressStat","completed","total","prevCompleted","prevTotal","currentProgress","calculateProgress","previousProgress","progressDifference","showIndicator","showTag","isCompleted","roundedProgress","roundedDifference","totalChapters","visibleChapters","remainingChapters","hiddenChapters","hasRemainingChapters","categoryConfig","useMemo","GOAL_CATEGORY_CONFIG","icon","handleToggleChapters","useCallback","prev","FlexView","jsxs","jsx","Image","Fragment","Text","Separator","Styled.ProgressBarContainer","LinearProgressBar","Styled.TagContainer","Styled.ChaptersContainer","GoalsCardChapters","TextButton","GoalsCard$1","memo"],"mappings":";;;;;;;;;;;AAaA,MAAMA,IAAiC,CAAC,EAAE,UAAAC,GAAU,WAAAC,GAAW,YAAAC,IAAa,SAAY;AACtF,QAAM,CAACC,GAAiBC,CAAkB,IAAIC,EAAS,EAAK,GACtD;AAAA,IACJ,gBAAgBC;AAAA,IAChB,eAAeC;AAAA,IACf,eAAeC;AAAA,IACf,wBAAwBC;AAAA,EACtB,IAAAR,GACE,EAAE,WAAAS,GAAW,OAAAC,EAAU,IAAAH,GACvB,EAAE,WAAWI,GAAe,OAAOC,EAAU,IAAIJ,KAAoB,IACrEK,IAAkBC,EAAkBL,GAAWC,CAAK,GACpDK,IACJP,KAAoBG,KAAiBC,IACjCE,EAAkBH,GAAeC,CAAS,IAC1C,GAEAI,IAAqBH,IAAkBE,GACvCE,IAAgB,GAAQT,KAAoBQ,IAAqB,KAAKN,MAAUA,IAChFQ,IAAU,GAAQV,KAAoBQ,KAAsB,KAAKN,MAAUA,IAC3ES,IAAcN,MAAoB,KAClCO,IAAkB,KAAK,MAAMP,CAAe,GAC5CQ,IAAoB,KAAK,MAAML,CAAkB,GAEjDM,IAAgBhB,EAAa,QAC7BiB,IAAkBjB,EAAa,MAAM,GAAG,CAAC,GACzCkB,IAAoB,KAAK,IAAI,GAAGF,IAAgB,CAAC,GACjDG,IAAiBvB,IAAkBI,EAAa,MAAM,CAAC,IAAI,IAC3DoB,IAAuBF,IAAoB,GAE3CG,IAAiBC,EAAQ,MAAMC,EAAqB9B,CAAQ,GAAG,CAACA,CAAQ,CAAC,GACzE+B,IAAOH,EAAe,MAEtBI,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,EAAAG,GAAA,EAAA,UAAA;AAAA,cAAC,gBAAAF,EAAAS,GAAA,EAAkB,UAAUpB,EAAgB,CAAA;AAAA,cAC7C,gBAAAW,EAACF,GAAS,EAAA,UAAU,KAClB,UAAA,gBAAAE;AAAA,gBAACU;AAAA,gBAAA;AAAA,kBACC,OAAM;AAAA,kBACN,MAAK;AAAA,kBACL,OAAM;AAAA,kBACN,SAASf;AAAA,gBAAA;AAAA,cAAA,GAEb;AAAA,YAAA,GACF;AAAA,UAAA,GAEJ;AAAA,QAAA;AAAA,MAAA;AAAA,IAEJ;AAAA,EAEJ,EAAA,CAAA;AAEJ,GAEegB,KAAAC,EAAKlD,CAAS;"}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { ILLUSTRATIONS as o } from "../../../../../../assets/illustrations/illustrations.js";
|
|
2
|
+
import { EGoalCategory as l } from "../../../monthly-timeline-types.js";
|
|
3
|
+
const a = {
|
|
4
|
+
[l.SCHOOL_SUCCESS]: {
|
|
5
|
+
label: "School Success",
|
|
6
|
+
icon: o.GRADUATE_ICON_PINK,
|
|
7
|
+
backgroundColor: "PURPLE_1",
|
|
8
|
+
labelColor: "PURPLE_6",
|
|
9
|
+
tagColor: "PURPLE_2"
|
|
10
|
+
},
|
|
11
|
+
[l.ENRICHMENT]: {
|
|
12
|
+
label: "Enrichment",
|
|
13
|
+
icon: o.STAR_ORANGE,
|
|
14
|
+
backgroundColor: "ORANGE_1",
|
|
15
|
+
labelColor: "ORANGE_6",
|
|
16
|
+
tagColor: "ORANGE_2"
|
|
17
|
+
},
|
|
18
|
+
[l.TEST_PREP]: {
|
|
19
|
+
label: "Test Prep",
|
|
20
|
+
icon: o.TROPHY_BLUE,
|
|
21
|
+
backgroundColor: "BLUE_1",
|
|
22
|
+
labelColor: "BLUE_6",
|
|
23
|
+
tagColor: "BLUE_2"
|
|
24
|
+
}
|
|
25
|
+
}, e = (E, r) => r > 0 ? Math.floor(E / r * 100) : 0;
|
|
26
|
+
export {
|
|
27
|
+
a as GOAL_CATEGORY_CONFIG,
|
|
28
|
+
e as calculateProgress
|
|
29
|
+
};
|
|
30
|
+
//# sourceMappingURL=goals-constants.js.map
|
package/dist/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-constants.js.map
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"goals-constants.js","sources":["../../../../../../../src/features/timeline/monthly-timeline/monthly-report/comps/goals/goals-constants.ts"],"sourcesContent":["import { ILLUSTRATIONS } from '../../../../../../assets/illustrations/illustrations';\nimport { EGoalCategory } from '../../../monthly-timeline-types';\n\nexport const GOAL_CATEGORY_CONFIG = {\n [EGoalCategory.SCHOOL_SUCCESS]: {\n label: 'School Success',\n icon: ILLUSTRATIONS.GRADUATE_ICON_PINK,\n backgroundColor: 'PURPLE_1',\n labelColor: 'PURPLE_6',\n tagColor: 'PURPLE_2',\n },\n [EGoalCategory.ENRICHMENT]: {\n label: 'Enrichment',\n icon: ILLUSTRATIONS.STAR_ORANGE,\n backgroundColor: 'ORANGE_1',\n labelColor: 'ORANGE_6',\n tagColor: 'ORANGE_2',\n },\n [EGoalCategory.TEST_PREP]: {\n label: 'Test Prep',\n icon: ILLUSTRATIONS.TROPHY_BLUE,\n backgroundColor: 'BLUE_1',\n labelColor: 'BLUE_6',\n tagColor: 'BLUE_2',\n },\n} as const;\n\nexport const calculateProgress = (completed: number, total: number): number => {\n return total > 0 ? Math.floor((completed / total) * 100) : 0;\n};\n"],"names":["GOAL_CATEGORY_CONFIG","EGoalCategory","ILLUSTRATIONS","calculateProgress","completed","total"],"mappings":";;AAGO,MAAMA,IAAuB;AAAA,EAClC,CAACC,EAAc,cAAc,GAAG;AAAA,IAC9B,OAAO;AAAA,IACP,MAAMC,EAAc;AAAA,IACpB,iBAAiB;AAAA,IACjB,YAAY;AAAA,IACZ,UAAU;AAAA,EACZ;AAAA,EACA,CAACD,EAAc,UAAU,GAAG;AAAA,IAC1B,OAAO;AAAA,IACP,MAAMC,EAAc;AAAA,IACpB,iBAAiB;AAAA,IACjB,YAAY;AAAA,IACZ,UAAU;AAAA,EACZ;AAAA,EACA,CAACD,EAAc,SAAS,GAAG;AAAA,IACzB,OAAO;AAAA,IACP,MAAMC,EAAc;AAAA,IACpB,iBAAiB;AAAA,IACjB,YAAY;AAAA,IACZ,UAAU;AAAA,EACZ;AACF,GAEaC,IAAoB,CAACC,GAAmBC,MAC5CA,IAAQ,IAAI,KAAK,MAAOD,IAAYC,IAAS,GAAG,IAAI;"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import { jsxs as e, jsx as r } from "react/jsx-runtime";
|
|
2
|
+
import f from "./goals-card/goals-card.js";
|
|
3
|
+
import t from "../../../../../ui/layout/flex-view.js";
|
|
4
|
+
import i from "../../../../../ui/text/text.js";
|
|
5
|
+
import m from "../../../../../ui/separator/separator.js";
|
|
6
|
+
const n = ({ milestones: o, isExpended: l = !1 }) => !o || o.length === 0 ? null : /* @__PURE__ */ e(t, { children: [
|
|
7
|
+
/* @__PURE__ */ r(i, { $renderAs: "ab1-bold", $color: "BLACK_1", children: "Goals" }),
|
|
8
|
+
/* @__PURE__ */ r(m, { heightX: 1 }),
|
|
9
|
+
/* @__PURE__ */ r(t, { $flexRowGapX: l ? 1.5 : 0, children: o.map((a) => /* @__PURE__ */ r(
|
|
10
|
+
f,
|
|
11
|
+
{
|
|
12
|
+
category: a.goal_category,
|
|
13
|
+
milestone: a,
|
|
14
|
+
isExpended: l
|
|
15
|
+
},
|
|
16
|
+
a.user_milestone_id
|
|
17
|
+
)) })
|
|
18
|
+
] });
|
|
19
|
+
export {
|
|
20
|
+
n as default
|
|
21
|
+
};
|
|
22
|
+
//# sourceMappingURL=goals.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"goals.js","sources":["../../../../../../../src/features/timeline/monthly-timeline/monthly-report/comps/goals/goals.tsx"],"sourcesContent":["import { type FC } from 'react';\n\nimport { type IGoalsProps } from './goals-types';\nimport GoalsCard from './goals-card/goals-card';\nimport FlexView from '../../../../../ui/layout/flex-view';\nimport Text from '../../../../../ui/text/text';\nimport Separator from '../../../../../ui/separator/separator';\n\nconst Goals: FC<IGoalsProps> = ({ milestones, isExpended = false }) => {\n if (!milestones || milestones.length === 0) {\n return null;\n }\n\n return (\n <FlexView>\n <Text $renderAs=\"ab1-bold\" $color=\"BLACK_1\">\n Goals\n </Text>\n <Separator heightX={1} />\n <FlexView $flexRowGapX={isExpended ? 1.5 : 0}>\n {milestones.map(milestone => (\n <GoalsCard\n key={milestone.user_milestone_id}\n category={milestone.goal_category}\n milestone={milestone}\n isExpended={isExpended}\n />\n ))}\n </FlexView>\n </FlexView>\n );\n};\n\nexport default Goals;\n"],"names":["Goals","milestones","isExpended","FlexView","jsx","Text","Separator","milestone","GoalsCard"],"mappings":";;;;;AAQA,MAAMA,IAAyB,CAAC,EAAE,YAAAC,GAAY,YAAAC,IAAa,SACrD,CAACD,KAAcA,EAAW,WAAW,IAChC,yBAINE,GACC,EAAA,UAAA;AAAA,EAAA,gBAAAC,EAACC,GAAK,EAAA,WAAU,YAAW,QAAO,WAAU,UAE5C,SAAA;AAAA,EACA,gBAAAD,EAACE,GAAU,EAAA,SAAS,EAAG,CAAA;AAAA,EACvB,gBAAAF,EAACD,KAAS,cAAcD,IAAa,MAAM,GACxC,UAAAD,EAAW,IAAI,CACdM,MAAA,gBAAAH;AAAA,IAACI;AAAA,IAAA;AAAA,MAEC,UAAUD,EAAU;AAAA,MACpB,WAAAA;AAAA,MACA,YAAAL;AAAA,IAAA;AAAA,IAHKK,EAAU;AAAA,EAKlB,CAAA,GACH;AACF,EAAA,CAAA;"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { PLUGINS as _ } from "../../../../node_modules/@cuemath/analytics-v2/dist/constants.js";
|
|
2
|
+
var r = /* @__PURE__ */ ((e) => (e.REPORT_NEGATIVE_FEEDBACK_CLICKED = "report_negative_feedback_clicked", e.REPORT_POSITIVE_FEEDBACK_CLICKED = "report_positive_feedback_clicked", e))(r || {});
|
|
3
|
+
const c = {
|
|
4
|
+
report_negative_feedback_clicked: [_.MIXPANEL],
|
|
5
|
+
report_positive_feedback_clicked: [_.MIXPANEL]
|
|
6
|
+
};
|
|
7
|
+
export {
|
|
8
|
+
r as MONTHLY_REPORT_ANALYTICS_EVENTS,
|
|
9
|
+
c as MONTHLY_REPORT_WHITELIST_EVENTS
|
|
10
|
+
};
|
|
11
|
+
//# sourceMappingURL=monthly-report-events.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"monthly-report-events.js","sources":["../../../../../src/features/timeline/monthly-timeline/monthly-report/monthly-report-events.ts"],"sourcesContent":["import { PLUGINS } from '@cuemath/analytics-v2/dist/constants';\n\nexport enum MONTHLY_REPORT_ANALYTICS_EVENTS {\n REPORT_NEGATIVE_FEEDBACK_CLICKED = 'report_negative_feedback_clicked',\n REPORT_POSITIVE_FEEDBACK_CLICKED = 'report_positive_feedback_clicked',\n}\n\nexport const MONTHLY_REPORT_WHITELIST_EVENTS = {\n [MONTHLY_REPORT_ANALYTICS_EVENTS.REPORT_NEGATIVE_FEEDBACK_CLICKED]: [PLUGINS.MIXPANEL],\n [MONTHLY_REPORT_ANALYTICS_EVENTS.REPORT_POSITIVE_FEEDBACK_CLICKED]: [PLUGINS.MIXPANEL],\n};\n"],"names":["MONTHLY_REPORT_ANALYTICS_EVENTS","MONTHLY_REPORT_WHITELIST_EVENTS","PLUGINS"],"mappings":";AAEY,IAAAA,sBAAAA,OACVA,EAAA,mCAAmC,oCACnCA,EAAA,mCAAmC,oCAFzBA,IAAAA,KAAA,CAAA,CAAA;AAKL,MAAMC,IAAkC;AAAA,EAC5C,kCAAmE,CAACC,EAAQ,QAAQ;AAAA,EACpF,kCAAmE,CAACA,EAAQ,QAAQ;AACvF;"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import t from "styled-components";
|
|
2
|
+
const o = t.div`
|
|
3
|
+
display: flex;
|
|
4
|
+
flex-direction: column;
|
|
5
|
+
gap: 40px;
|
|
6
|
+
padding: 0 16px;
|
|
7
|
+
max-width: 512px;
|
|
8
|
+
width: 100%;
|
|
9
|
+
margin: 0 auto;
|
|
10
|
+
`;
|
|
11
|
+
export {
|
|
12
|
+
o as MonthlyReportContainer
|
|
13
|
+
};
|
|
14
|
+
//# sourceMappingURL=monthly-report-styled.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"monthly-report-styled.js","sources":["../../../../../src/features/timeline/monthly-timeline/monthly-report/monthly-report-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nexport const MonthlyReportContainer = styled.div`\n display: flex;\n flex-direction: column;\n gap: 40px;\n padding: 0 16px;\n max-width: 512px;\n width: 100%;\n margin: 0 auto;\n`;\n"],"names":["MonthlyReportContainer","styled"],"mappings":";AAEO,MAAMA,IAAyBC,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
var e = /* @__PURE__ */ ((t) => (t.general = "general", t.legacy = "legacy", t.diagnostic = "diagnostic", t.remedial = "remedial", t.recap = "recap", t.learn = "learn", t.extra_practice = "extra_practice", t.practice = "practice", t.test = "test", t.revision = "revision", t.advanced = "advanced", t.challenge = "challenge", t.video = "video", t.simulation = "simulation", t.note = "note", t.subjective = "subjective", t.deck = "deck", t.puzzle = "puzzle", t.test_series = "test_series", t.activity = "activity", t.project = "project", t.certificate = "certificate", t.ppt_viva = "ppt_viva", t.ppt_content = "ppt_content", t.wb_activity = "wb_activity", t.smart_practice = "smart_practice", t.exit_ticket = "exit_ticket", t.monthly_mastery_test = "monthly_mastery_test", t.supplementary_mastery_test = "supplementary_mastery_test", t.trial_diagnostic = "trial_diagnostic", t.trial_basic = "trial_basic", t.trial_intermediate = "trial_intermediate", t.trial_advanced = "trial_advanced", t.sat_mock_test = "sat_mock_test", t.pdf = "pdf", t))(e || {});
|
|
2
|
+
export {
|
|
3
|
+
e as CARD_TYPE
|
|
4
|
+
};
|
|
5
|
+
//# sourceMappingURL=monthly-report-types.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"monthly-report-types.js","sources":["../../../../../src/features/timeline/monthly-timeline/monthly-report/monthly-report-types.ts"],"sourcesContent":["import { type NODE_TYPES } from '../../../../types/models/worksheet';\nimport { type TCourseStream } from '../../../milestone/create/milestone-create-types';\nimport { type THueNames } from '../../../ui/types';\nimport { type NODE_STATE } from '../../daily-timeline/daily-timeline-types';\nimport { type IUserMilestone } from '../monthly-timeline-types';\n\nexport enum CARD_TYPE {\n 'general' = 'general',\n 'legacy' = 'legacy',\n 'diagnostic' = 'diagnostic',\n 'remedial' = 'remedial',\n 'recap' = 'recap',\n 'learn' = 'learn',\n 'extra_practice' = 'extra_practice',\n 'practice' = 'practice',\n 'test' = 'test',\n 'revision' = 'revision',\n 'advanced' = 'advanced',\n 'challenge' = 'challenge',\n 'video' = 'video',\n 'simulation' = 'simulation',\n 'note' = 'note',\n 'subjective' = 'subjective',\n 'deck' = 'deck',\n 'puzzle' = 'puzzle',\n 'test_series' = 'test_series',\n 'activity' = 'activity',\n 'project' = 'project',\n 'certificate' = 'certificate',\n 'ppt_viva' = 'ppt_viva',\n 'ppt_content' = 'ppt_content',\n 'wb_activity' = 'wb_activity',\n 'smart_practice' = 'smart_practice',\n 'exit_ticket' = 'exit_ticket',\n 'monthly_mastery_test' = 'monthly_mastery_test',\n 'supplementary_mastery_test' = 'supplementary_mastery_test',\n 'trial_diagnostic' = 'trial_diagnostic',\n 'trial_basic' = 'trial_basic',\n 'trial_intermediate' = 'trial_intermediate',\n 'trial_advanced' = 'trial_advanced',\n 'sat_mock_test' = 'sat_mock_test',\n 'pdf' = 'pdf',\n}\n\nexport type ActivitiesByCardType = Partial<{\n [K in CARD_TYPE]: IMonthlyActivity[];\n}>;\n\nexport type TFeedback = 'positive' | 'negative';\n\nexport interface IMonthlyReportResponse {\n course_stream: TCourseStream;\n id: string;\n created_on_ts: number;\n is_deleted: boolean;\n report_date: string;\n report_date_ts: number;\n report_month: number;\n report_year: number;\n student_course_ids: string[];\n user_id: string;\n updated_on_ts: number;\n calendar_data: TCalendarData | null;\n progress_data: {\n user_milestones: IUserMilestone[];\n activities: ActivitiesByCardType;\n user_achievements: IAchievementAsset[];\n };\n feedback: TFeedback | null;\n}\n\nexport interface IProgressStat {\n completed: number;\n total: number;\n}\n\nexport interface IMonthlyActivity {\n id: string;\n node_type: NODE_TYPES;\n card_type: CARD_TYPE;\n card_header: CARD_TYPE | null;\n feedback_comments: string | null;\n state: NODE_STATE;\n title?: string;\n accuracy?: number | null;\n subtext?: string | null;\n is_timed?: boolean;\n image_hue?: THueNames;\n image_url?: string;\n sat_max_score?: number | null;\n sat_total_score?: number | null;\n item_ref?: string | null;\n thumbnail_url?: string;\n user_attempt_id?: string | null;\n tip: string | null;\n user_block_id: string | null;\n user_chapter_id: string | null;\n user_node_id: string | null;\n}\n\nexport interface IAchievementAsset {\n asset_id: string;\n url: string;\n}\n\nexport interface IMonthlyReportProps {\n reportId: string;\n studentName: string;\n onPuzzleClick?: (params: {\n item_ref: IMonthlyActivity['item_ref'];\n feedback_comments: IMonthlyActivity['feedback_comments'];\n image_hue: IMonthlyActivity['image_hue'];\n title: IMonthlyActivity['title'];\n tip: IMonthlyActivity['tip'];\n }) => void;\n showSnackbar?: (params: { type: 'error' | 'info'; message: string; bgColor: string }) => void;\n onFeedback?: (feedback: TFeedback, studentCourseId: string) => void;\n}\n\nexport type TClassType = 'REGULAR' | 'EXTRA';\nexport interface IClassEvent {\n class_type: TClassType;\n is_paused: boolean;\n is_present: boolean;\n status: string;\n tag: string | null;\n theme: string;\n time: number;\n}\n\nexport type TCalendarData = Record<string, IClassEvent[]>;\n"],"names":["CARD_TYPE"],"mappings":"AAMY,IAAAA,sBAAAA,OACVA,EAAA,UAAY,WACZA,EAAA,SAAW,UACXA,EAAA,aAAe,cACfA,EAAA,WAAa,YACbA,EAAA,QAAU,SACVA,EAAA,QAAU,SACVA,EAAA,iBAAmB,kBACnBA,EAAA,WAAa,YACbA,EAAA,OAAS,QACTA,EAAA,WAAa,YACbA,EAAA,WAAa,YACbA,EAAA,YAAc,aACdA,EAAA,QAAU,SACVA,EAAA,aAAe,cACfA,EAAA,OAAS,QACTA,EAAA,aAAe,cACfA,EAAA,OAAS,QACTA,EAAA,SAAW,UACXA,EAAA,cAAgB,eAChBA,EAAA,WAAa,YACbA,EAAA,UAAY,WACZA,EAAA,cAAgB,eAChBA,EAAA,WAAa,YACbA,EAAA,cAAgB,eAChBA,EAAA,cAAgB,eAChBA,EAAA,iBAAmB,kBACnBA,EAAA,cAAgB,eAChBA,EAAA,uBAAyB,wBACzBA,EAAA,6BAA+B,8BAC/BA,EAAA,mBAAqB,oBACrBA,EAAA,cAAgB,eAChBA,EAAA,qBAAuB,sBACvBA,EAAA,iBAAmB,kBACnBA,EAAA,gBAAkB,iBAClBA,EAAA,MAAQ,OAnCEA,IAAAA,KAAA,CAAA,CAAA;"}
|