@cuemath/leap 2.9.11-as1 → 2.9.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/illustrations/illustrations.js +0 -9
- package/dist/assets/illustrations/illustrations.js.map +1 -1
- package/dist/assets/line-icons/icons/bin2.js +8 -7
- package/dist/assets/line-icons/icons/bin2.js.map +1 -1
- package/dist/assets/line-icons/icons/chevron-left.js.map +1 -1
- package/dist/assets/lottie/lottie.js +1 -9
- package/dist/assets/lottie/lottie.js.map +1 -1
- package/dist/constants/api.js +2 -3
- package/dist/constants/api.js.map +1 -1
- package/dist/features/analytics-events/platform-events-student.js +3 -3
- package/dist/features/analytics-events/platform-events-student.js.map +1 -1
- package/dist/features/analytics-events/whitelist-events.js +11 -13
- package/dist/features/analytics-events/whitelist-events.js.map +1 -1
- package/dist/features/chapters/chapters-list/chapter-item/chapter-item-styled.js +33 -99
- package/dist/features/chapters/chapters-list/chapter-item/chapter-item-styled.js.map +1 -1
- package/dist/features/chapters/chapters-list/chapter-item/chapter-item.js +49 -92
- package/dist/features/chapters/chapters-list/chapter-item/chapter-item.js.map +1 -1
- package/dist/features/chapters/chapters-list/chapters-list-styled.js +5 -5
- package/dist/features/chapters/chapters-list/chapters-list-styled.js.map +1 -1
- package/dist/features/chapters/chapters-list/chapters-list.js +70 -64
- package/dist/features/chapters/chapters-list/chapters-list.js.map +1 -1
- package/dist/features/communication/pub-sub/constants.js +6 -12
- package/dist/features/communication/pub-sub/constants.js.map +1 -1
- package/dist/features/journey/comps/coachmark/coachmark.js +24 -24
- package/dist/features/journey/comps/coachmark/coachmark.js.map +1 -1
- package/dist/features/journey/journey-id/journey-id-student.js +1 -1
- package/dist/features/journey/journey-id/journey-id-student.js.map +1 -1
- package/dist/features/journey/use-journey/journey-context-provider.js +28 -36
- package/dist/features/journey/use-journey/journey-context-provider.js.map +1 -1
- package/dist/features/journey/use-journey/journey-styled.js +5 -10
- package/dist/features/journey/use-journey/journey-styled.js.map +1 -1
- package/dist/features/milestone/create/api/goal-submit.js +1 -1
- package/dist/features/milestone/create/api/goal-submit.js.map +1 -1
- package/dist/features/milestone/create/comps/chapter-item/chapter-item.js +49 -42
- package/dist/features/milestone/create/comps/chapter-item/chapter-item.js.map +1 -1
- package/dist/features/milestone/create/comps/chapters-selection-step/chapters-selection-step-styled.js +4 -12
- package/dist/features/milestone/create/comps/chapters-selection-step/chapters-selection-step-styled.js.map +1 -1
- package/dist/features/milestone/create/comps/chapters-selection-step/chapters-selection-step.js +105 -128
- package/dist/features/milestone/create/comps/chapters-selection-step/chapters-selection-step.js.map +1 -1
- package/dist/features/milestone/create/comps/milestone-progress-v2/milestone-progress-v2.js +92 -0
- package/dist/features/milestone/create/comps/milestone-progress-v2/milestone-progress-v2.js.map +1 -0
- package/dist/features/milestone/create/comps/milestone-progress-v2/styled.js +25 -0
- package/dist/features/milestone/create/comps/milestone-progress-v2/styled.js.map +1 -0
- package/dist/features/milestone/create/comps/sheets-list/sheets-list-styled.js +20 -14
- package/dist/features/milestone/create/comps/sheets-list/sheets-list-styled.js.map +1 -1
- package/dist/features/milestone/create/comps/sheets-list/sheets-list.js +50 -26
- package/dist/features/milestone/create/comps/sheets-list/sheets-list.js.map +1 -1
- package/dist/features/milestone/create/milestone-create.js +43 -49
- package/dist/features/milestone/create/milestone-create.js.map +1 -1
- package/dist/features/milestone/create/utils/index.js +38 -33
- package/dist/features/milestone/create/utils/index.js.map +1 -1
- package/dist/features/milestone/edit/comps/edit-milestone-modal/api/get-milestone.js +1 -1
- package/dist/features/milestone/edit/comps/edit-milestone-modal/api/get-milestone.js.map +1 -1
- package/dist/features/milestone/edit/comps/edit-milestone-modal/api/patch-goal-plan.js +1 -1
- package/dist/features/milestone/edit/comps/edit-milestone-modal/api/patch-goal-plan.js.map +1 -1
- package/dist/features/milestone/edit/comps/edit-milestone-modal/index.js +53 -51
- package/dist/features/milestone/edit/comps/edit-milestone-modal/index.js.map +1 -1
- package/dist/features/milestone/edit/goal-drafts/goal-draft-edit-container.js +40 -42
- package/dist/features/milestone/edit/goal-drafts/goal-draft-edit-container.js.map +1 -1
- package/dist/features/milestone/edit/goal-edit-container.js +62 -64
- package/dist/features/milestone/edit/goal-edit-container.js.map +1 -1
- package/dist/features/milestone/edit/goal-edit-helpers.js +53 -50
- package/dist/features/milestone/edit/goal-edit-helpers.js.map +1 -1
- package/dist/features/milestone/edit/milestone-edit-container.js +52 -54
- package/dist/features/milestone/edit/milestone-edit-container.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/api/get-milestone-resources.js +1 -1
- package/dist/features/milestone/milestone-list-container/api/get-milestone-resources.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/api/get-milestones.js +17 -9
- package/dist/features/milestone/milestone-list-container/api/get-milestones.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/api/get-tests-list.js +1 -1
- package/dist/features/milestone/milestone-list-container/api/get-tests-list.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-list.js +105 -138
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-list.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/context-menu-helper/menu-element-styled.js +13 -0
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/context-menu-helper/menu-element-styled.js.map +1 -0
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/context-menu-helper/menu-element.js +38 -0
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/context-menu-helper/menu-element.js.map +1 -0
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/goals/goal-action-ctas.js +123 -107
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/goals/goal-action-ctas.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-info.js +176 -157
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-info.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-tabs/milestone-tabs-styled.js +10 -24
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-tabs/milestone-tabs-styled.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-tabs/milestone-tabs.js +86 -80
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-tabs/milestone-tabs.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-utils.js +22 -10
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-utils.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-widget-status.js +53 -0
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-widget-status.js.map +1 -0
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-widget-styled.js +37 -70
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-widget-styled.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-widget.js +176 -114
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/milestone-widget.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/outcome/outcome-info.js +25 -0
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/outcome/outcome-info.js.map +1 -0
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/outcome/outcome-rank.js +16 -29
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/outcome/outcome-rank.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/outcome/outcome-styled.js +25 -17
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/outcome/outcome-styled.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/outcome/outcome.js +35 -23
- package/dist/features/milestone/milestone-list-container/milestone-list/milestone-widget/outcome/outcome.js.map +1 -1
- package/dist/features/milestone/milestone-list-container/milestone-list-container.js +113 -110
- package/dist/features/milestone/milestone-list-container/milestone-list-container.js.map +1 -1
- package/dist/features/milestone/milestone-resources/resources-assign/api/goal-resource-assign.js +1 -1
- package/dist/features/milestone/milestone-resources/resources-assign/api/goal-resource-assign.js.map +1 -1
- package/dist/features/milestone/milestone-resources/resources-assign/resources-assign.js +8 -8
- package/dist/features/milestone/milestone-resources/resources-assign/resources-assign.js.map +1 -1
- package/dist/features/milestone/milestone-resources/resources-list/resources-list-styled.js +1 -1
- package/dist/features/milestone/milestone-resources/resources-list/resources-list-styled.js.map +1 -1
- package/dist/features/milestone/milestone-resources/resources-list/resources-list.js +113 -116
- package/dist/features/milestone/milestone-resources/resources-list/resources-list.js.map +1 -1
- package/dist/features/milestone/milestone-tests/tests-creation/api/test-sheet-assign.js +5 -5
- package/dist/features/milestone/milestone-tests/tests-creation/api/test-sheet-assign.js.map +1 -1
- package/dist/features/milestone/milestone-tests/tests-creation/test-stages/chapter-selection/chapter-item/chapter-item.js.map +1 -1
- package/dist/features/milestone/milestone-tests/tests-creation/tests-creation.js +50 -46
- package/dist/features/milestone/milestone-tests/tests-creation/tests-creation.js.map +1 -1
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheet-item/test-sheet-item-cta.js +71 -0
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheet-item/test-sheet-item-cta.js.map +1 -0
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheet-item/test-sheet-item-styled.js +31 -0
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheet-item/test-sheet-item-styled.js.map +1 -0
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheet-item/test-sheet-item-utils.js +38 -0
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheet-item/test-sheet-item-utils.js.map +1 -0
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheet-item/test-sheet-item.js +79 -0
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheet-item/test-sheet-item.js.map +1 -0
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheets-list-styled.js +18 -0
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheets-list-styled.js.map +1 -0
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheets-list.js +51 -0
- package/dist/features/milestone/milestone-tests/tests-list/test-sheets-list/test-sheets-list.js.map +1 -0
- package/dist/features/milestone/milestone-tests/tests-list/tests-list-styled.js +11 -0
- package/dist/features/milestone/milestone-tests/tests-list/tests-list-styled.js.map +1 -0
- package/dist/features/milestone/milestone-tests/tests-list/tests-list.js +135 -0
- package/dist/features/milestone/milestone-tests/tests-list/tests-list.js.map +1 -0
- package/dist/features/post-game-stats/digital-meter/constants.js +11 -11
- package/dist/features/post-game-stats/digital-meter/constants.js.map +1 -1
- package/dist/features/post-game-stats/digital-meter/digital-meter-styled.js +15 -16
- package/dist/features/post-game-stats/digital-meter/digital-meter-styled.js.map +1 -1
- package/dist/features/sheets/resources-list/resource-item/styled.js +1 -1
- package/dist/features/sheets/resources-list/resource-item/styled.js.map +1 -1
- package/dist/features/sheets/sheets-list/sheet-item/reward-n-actions/teacher-actions/teacher-actions-constant.js +3 -4
- package/dist/features/sheets/sheets-list/sheet-item/reward-n-actions/teacher-actions/teacher-actions-constant.js.map +1 -1
- package/dist/features/trial-session/comps/learning-plan/index.js.map +1 -1
- package/dist/features/ui/animated-arc/animated-arc-constants.js +3 -2
- package/dist/features/ui/animated-arc/animated-arc-constants.js.map +1 -1
- package/dist/features/ui/animated-arc/animated-arc-styled.js +7 -7
- package/dist/features/ui/animated-arc/animated-arc-styled.js.map +1 -1
- package/dist/features/ui/arrow-tooltip/arrow-tooltip.js +29 -30
- package/dist/features/ui/arrow-tooltip/arrow-tooltip.js.map +1 -1
- package/dist/features/ui/constants/z-index.js +1 -1
- package/dist/features/ui/constants/z-index.js.map +1 -1
- package/dist/features/ui/context-menu/context-menu-styled.js +14 -28
- package/dist/features/ui/context-menu/context-menu-styled.js.map +1 -1
- package/dist/features/ui/context-menu/context-menu.js +17 -25
- package/dist/features/ui/context-menu/context-menu.js.map +1 -1
- package/dist/features/ui/lottie-animation/lottie-animation.js +24 -32
- package/dist/features/ui/lottie-animation/lottie-animation.js.map +1 -1
- package/dist/features/ui/theme/button.js +7 -24
- package/dist/features/ui/theme/button.js.map +1 -1
- package/dist/index.d.ts +34 -341
- package/dist/index.js +425 -447
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/dist/assets/line-icons/icons/exclamation.js +0 -26
- package/dist/assets/line-icons/icons/exclamation.js.map +0 -1
- package/dist/assets/line-icons/icons/home2.js +0 -25
- package/dist/assets/line-icons/icons/home2.js.map +0 -1
- package/dist/assets/line-icons/icons/important.js +0 -23
- package/dist/assets/line-icons/icons/important.js.map +0 -1
- package/dist/assets/line-icons/icons/skip-colored.js +0 -43
- package/dist/assets/line-icons/icons/skip-colored.js.map +0 -1
- package/dist/assets/line-icons/icons/status.js +0 -41
- package/dist/assets/line-icons/icons/status.js.map +0 -1
- package/dist/features/chapters-v2/api/chapter.js +0 -10
- package/dist/features/chapters-v2/api/chapter.js.map +0 -1
- package/dist/features/chapters-v2/chapter-details/block-sections/block-section-view.js +0 -112
- package/dist/features/chapters-v2/chapter-details/block-sections/block-section-view.js.map +0 -1
- package/dist/features/chapters-v2/chapter-details/block-sections/block-sections-styled.js +0 -35
- package/dist/features/chapters-v2/chapter-details/block-sections/block-sections-styled.js.map +0 -1
- package/dist/features/chapters-v2/chapter-details/block-sections/block-sections.js +0 -83
- package/dist/features/chapters-v2/chapter-details/block-sections/block-sections.js.map +0 -1
- package/dist/features/chapters-v2/chapter-details/chapter-banner/chapter-banner-styled.js +0 -90
- package/dist/features/chapters-v2/chapter-details/chapter-banner/chapter-banner-styled.js.map +0 -1
- package/dist/features/chapters-v2/chapter-details/chapter-banner/chapter-banner.js +0 -98
- package/dist/features/chapters-v2/chapter-details/chapter-banner/chapter-banner.js.map +0 -1
- package/dist/features/chapters-v2/chapter-details/chapter-details-styled.js +0 -51
- package/dist/features/chapters-v2/chapter-details/chapter-details-styled.js.map +0 -1
- package/dist/features/chapters-v2/chapter-details/chapter-details.js +0 -129
- package/dist/features/chapters-v2/chapter-details/chapter-details.js.map +0 -1
- package/dist/features/chapters-v2/comps/node-card/border-path-animation.js +0 -13
- package/dist/features/chapters-v2/comps/node-card/border-path-animation.js.map +0 -1
- package/dist/features/chapters-v2/comps/node-card/node-card-styled.js +0 -159
- package/dist/features/chapters-v2/comps/node-card/node-card-styled.js.map +0 -1
- package/dist/features/chapters-v2/comps/node-card/node-card-tags.js +0 -16
- package/dist/features/chapters-v2/comps/node-card/node-card-tags.js.map +0 -1
- package/dist/features/chapters-v2/comps/node-card/node-card.js +0 -12
- package/dist/features/chapters-v2/comps/node-card/node-card.js.map +0 -1
- package/dist/features/chapters-v2/comps/node-card/node-menu-options/node-menu-option.js +0 -30
- package/dist/features/chapters-v2/comps/node-card/node-menu-options/node-menu-option.js.map +0 -1
- package/dist/features/chapters-v2/comps/node-card/node-menu-options/node-menu-options-styled.js +0 -32
- package/dist/features/chapters-v2/comps/node-card/node-menu-options/node-menu-options-styled.js.map +0 -1
- package/dist/features/chapters-v2/comps/node-card/node-menu-options/node-menu-options.js +0 -9
- package/dist/features/chapters-v2/comps/node-card/node-menu-options/node-menu-options.js.map +0 -1
- package/dist/features/chapters-v2/comps/node-card/student-actions/student-actions.js +0 -189
- package/dist/features/chapters-v2/comps/node-card/student-actions/student-actions.js.map +0 -1
- package/dist/features/chapters-v2/comps/node-card/teacher-actions/teacher-actions.js +0 -194
- package/dist/features/chapters-v2/comps/node-card/teacher-actions/teacher-actions.js.map +0 -1
- package/dist/features/chapters-v2/comps/tag/tag-styled.js +0 -13
- package/dist/features/chapters-v2/comps/tag/tag-styled.js.map +0 -1
- package/dist/features/chapters-v2/comps/tag/tag.js +0 -28
- package/dist/features/chapters-v2/comps/tag/tag.js.map +0 -1
- package/dist/features/chapters-v2/constants/block-constants.js +0 -20
- package/dist/features/chapters-v2/constants/block-constants.js.map +0 -1
- package/dist/features/chapters-v2/constants/node-constants.js +0 -14
- package/dist/features/chapters-v2/constants/node-constants.js.map +0 -1
- package/dist/features/chapters-v2/utils/index.js +0 -45
- package/dist/features/chapters-v2/utils/index.js.map +0 -1
- package/dist/features/chapters-v2/utils/node-card-utils.js +0 -169
- package/dist/features/chapters-v2/utils/node-card-utils.js.map +0 -1
- package/dist/features/homework/card-menu-option.js +0 -28
- package/dist/features/homework/card-menu-option.js.map +0 -1
- package/dist/features/homework/card-menu-options.js +0 -22
- package/dist/features/homework/card-menu-options.js.map +0 -1
- package/dist/features/homework/card-title.js +0 -16
- package/dist/features/homework/card-title.js.map +0 -1
- package/dist/features/homework/homework-analytics-events.js +0 -10
- package/dist/features/homework/homework-analytics-events.js.map +0 -1
- package/dist/features/homework/homework-card-view.js +0 -143
- package/dist/features/homework/homework-card-view.js.map +0 -1
- package/dist/features/homework/homework-card.js +0 -245
- package/dist/features/homework/homework-card.js.map +0 -1
- package/dist/features/homework/hw-card-list/api/get-homeworks.js +0 -10
- package/dist/features/homework/hw-card-list/api/get-homeworks.js.map +0 -1
- package/dist/features/homework/hw-card-list/hw-card-list-styled.js +0 -63
- package/dist/features/homework/hw-card-list/hw-card-list-styled.js.map +0 -1
- package/dist/features/homework/hw-card-list/hw-card-list-view.js +0 -157
- package/dist/features/homework/hw-card-list/hw-card-list-view.js.map +0 -1
- package/dist/features/homework/hw-card-list/hw-card-list.js +0 -67
- package/dist/features/homework/hw-card-list/hw-card-list.js.map +0 -1
- package/dist/features/homework/node-progress.js +0 -29
- package/dist/features/homework/node-progress.js.map +0 -1
- package/dist/features/homework/styles.js +0 -130
- package/dist/features/homework/styles.js.map +0 -1
- package/dist/features/homework/utils.js +0 -48
- package/dist/features/homework/utils.js.map +0 -1
- package/dist/features/journey/hooks/use-chapter-journey.js +0 -173
- package/dist/features/journey/hooks/use-chapter-journey.js.map +0 -1
- package/dist/features/journey/hooks/use-home-page-journey/home-page-homeworks-mock.js +0 -268
- package/dist/features/journey/hooks/use-home-page-journey/home-page-homeworks-mock.js.map +0 -1
- package/dist/features/journey/hooks/use-home-page-journey/recent-chapters-mock.js +0 -513
- package/dist/features/journey/hooks/use-home-page-journey/recent-chapters-mock.js.map +0 -1
- package/dist/features/journey/hooks/use-home-page-journey/styles.js +0 -23
- package/dist/features/journey/hooks/use-home-page-journey/styles.js.map +0 -1
- package/dist/features/journey/hooks/use-home-page-journey/tooltip-item.js +0 -22
- package/dist/features/journey/hooks/use-home-page-journey/tooltip-item.js.map +0 -1
- package/dist/features/journey/hooks/use-home-page-journey/use-home-page-journey.js +0 -270
- package/dist/features/journey/hooks/use-home-page-journey/use-home-page-journey.js.map +0 -1
- package/dist/features/journey/journey-id/journey-id-teacher.js +0 -5
- package/dist/features/journey/journey-id/journey-id-teacher.js.map +0 -1
- package/dist/features/journey/mocks/chapter-page-journey-mock-data.js +0 -584
- package/dist/features/journey/mocks/chapter-page-journey-mock-data.js.map +0 -1
- package/dist/features/milestone/milestone-tests/test-list-v2/test-list-container.js +0 -165
- package/dist/features/milestone/milestone-tests/test-list-v2/test-list-container.js.map +0 -1
- package/dist/features/milestone/milestone-tests/test-list-v2/test-list-view-styled.js +0 -25
- package/dist/features/milestone/milestone-tests/test-list-v2/test-list-view-styled.js.map +0 -1
- package/dist/features/milestone/milestone-tests/test-list-v2/test-list-view.js +0 -87
- package/dist/features/milestone/milestone-tests/test-list-v2/test-list-view.js.map +0 -1
- package/dist/features/recent-chapters/api/get-recent-chapters.js +0 -9
- package/dist/features/recent-chapters/api/get-recent-chapters.js.map +0 -1
- package/dist/features/recent-chapters/recent-chapters-styled.js +0 -16
- package/dist/features/recent-chapters/recent-chapters-styled.js.map +0 -1
- package/dist/features/recent-chapters/recent-chapters.js +0 -39
- package/dist/features/recent-chapters/recent-chapters.js.map +0 -1
- package/dist/features/sheet-v2/resource-list/resource-list.js +0 -45
- package/dist/features/sheet-v2/resource-list/resource-list.js.map +0 -1
- package/dist/features/ui/animated-arc/constants.js +0 -5
- package/dist/features/ui/animated-arc/constants.js.map +0 -1
- package/dist/node_modules/date-fns/differenceInDays.js +0 -17
- package/dist/node_modules/date-fns/differenceInDays.js.map +0 -1
- package/dist/static/chapter-header-bg-2.c8d96894.svg +0 -1
- package/dist/static/competitive-arena.b9c40801.json +0 -1
- package/dist/static/learn.71b13323.json +0 -1
- package/dist/static/node-custom-test-bg.d3b757be.svg +0 -1
- package/dist/static/node-learn-bg.b61f815c.svg +0 -1
- package/dist/static/node-practice-bg.16cbaf2a.svg +0 -1
- package/dist/static/node-project-bg.e6a33e28.svg +0 -1
- package/dist/static/node-puzzle-bg.3422135c.svg +0 -1
- package/dist/static/node-recap-bg.546154e4.svg +0 -1
- package/dist/static/node-test-prep-bg.42c0b9c4.svg +0 -1
- package/dist/static/node-video-bg.3df3f73a.svg +0 -1
- package/dist/static/practice.158dd488.json +0 -1
- package/dist/static/project.eb665827.json +0 -1
- package/dist/static/puzzle.b298c7e4.json +0 -1
- package/dist/static/recap.0dd2c1e2.json +0 -1
- package/dist/static/test.803d6036.json +0 -1
- package/dist/static/video.b41451e2.json +0 -1
@@ -1,101 +1,58 @@
|
|
1
|
-
import {
|
2
|
-
import { memo as
|
3
|
-
import
|
4
|
-
import
|
5
|
-
import A from "../../../ui/
|
6
|
-
import
|
7
|
-
|
8
|
-
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
image_hue: C
|
14
|
-
} = i, { mandatory: $, optional: f } = u || {}, { completed: s = 0, total: c = 0 } = $ || {}, { total: I = 0 } = f || {}, [x, y] = b(!1), t = S(null), p = s > 0 ? Math.floor((s / c || 1) * 100) : 0, r = c + I, w = W(() => {
|
15
|
-
if (r === 0)
|
16
|
-
return null;
|
17
|
-
a(i, o);
|
18
|
-
}, [i, o, a, r]);
|
1
|
+
import { jsxs as c, jsx as o } from "react/jsx-runtime";
|
2
|
+
import { memo as C, useState as x, useRef as w, useCallback as T, useLayoutEffect as _ } from "react";
|
3
|
+
import { useTheme as y } from "styled-components";
|
4
|
+
import j from "../../../milestone/create/comps/milestone-progress-v2/milestone-progress-v2.js";
|
5
|
+
import A from "../../../ui/arrow-tooltip/arrow-tooltip.js";
|
6
|
+
import I from "../../../ui/layout/flex-view.js";
|
7
|
+
import { ChapterItemWrapper as L, ChapterImage as b, ChapterName as H } from "./chapter-item-styled.js";
|
8
|
+
const V = C(
|
9
|
+
({ milestoneId: t, userType: m, chapter: s, onChapterClick: a, itemIndex: i }) => {
|
10
|
+
const p = y(), { gutter: r } = p.layout, f = !!((i + 1) % 2), { name: l, image_url: h, user_chapter_progress: n } = s, { total_core_sheets: u } = n, [d, g] = x(!1), e = w(null), $ = T(() => {
|
11
|
+
a(s, t);
|
12
|
+
}, [s, t, a]);
|
19
13
|
return _(() => {
|
20
|
-
|
21
|
-
}, [
|
22
|
-
|
14
|
+
e.current && e.current.scrollHeight > e.current.clientHeight && g(!0);
|
15
|
+
}, [e]), /* @__PURE__ */ c(
|
16
|
+
L,
|
23
17
|
{
|
24
|
-
|
25
|
-
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
|
57
|
-
$progressCircle: !0,
|
58
|
-
$progress: p * 2.98,
|
59
|
-
r: "47",
|
60
|
-
cx: "48",
|
61
|
-
cy: "48"
|
62
|
-
}
|
63
|
-
)
|
64
|
-
] }) }),
|
65
|
-
/* @__PURE__ */ e(V, { src: g, alt: "Chapter Image" }),
|
66
|
-
p === 100 && /* @__PURE__ */ e(X, { children: /* @__PURE__ */ e(k, { width: 20, height: 20 }) })
|
67
|
-
]
|
68
|
-
}
|
69
|
-
),
|
70
|
-
/* @__PURE__ */ e(A, { $justifyContent: "center", $alignItems: "center", children: /* @__PURE__ */ e(
|
71
|
-
h,
|
72
|
-
{
|
73
|
-
renderAs: "primary",
|
74
|
-
position: "bottom",
|
75
|
-
tooltipItem: l,
|
76
|
-
hidden: !x,
|
77
|
-
widthX: 21.75,
|
78
|
-
zIndex: 5,
|
79
|
-
children: /* @__PURE__ */ e(
|
80
|
-
z,
|
81
|
-
{
|
82
|
-
ref: t,
|
83
|
-
$renderAs: "ab2",
|
84
|
-
$color: "BLACK_T_87",
|
85
|
-
$align: "center",
|
86
|
-
children: l
|
87
|
-
}
|
88
|
-
)
|
89
|
-
}
|
90
|
-
) })
|
91
|
-
]
|
92
|
-
}
|
93
|
-
)
|
18
|
+
$justifyContent: "flex-start",
|
19
|
+
$gap: r * 1.25,
|
20
|
+
$gutter: r * 1.25,
|
21
|
+
$flexDirection: "row",
|
22
|
+
$flexColumnGap: r,
|
23
|
+
$shouldHaveLeftBorder: f,
|
24
|
+
onClick: $,
|
25
|
+
id: `milestone-chapter-${t}-${i}`,
|
26
|
+
className: "goal-widget-chapter-item",
|
27
|
+
children: [
|
28
|
+
/* @__PURE__ */ o(b, { src: h, alt: "Chapter Image" }),
|
29
|
+
/* @__PURE__ */ c(I, { $justifyContent: "center", $flexRowGap: r * 0.75, children: [
|
30
|
+
/* @__PURE__ */ o(
|
31
|
+
A,
|
32
|
+
{
|
33
|
+
renderAs: "primary",
|
34
|
+
position: "bottom",
|
35
|
+
tooltipItem: l,
|
36
|
+
hidden: !d,
|
37
|
+
widthX: 21.75,
|
38
|
+
children: /* @__PURE__ */ o(H, { ref: e, $renderAs: "ab2", $color: "BLACK_T_87", children: l })
|
39
|
+
}
|
40
|
+
),
|
41
|
+
!!u && /* @__PURE__ */ o(
|
42
|
+
j,
|
43
|
+
{
|
44
|
+
userType: m,
|
45
|
+
milestoneId: t,
|
46
|
+
progressInfo: n
|
47
|
+
}
|
48
|
+
)
|
49
|
+
] })
|
50
|
+
]
|
94
51
|
}
|
95
52
|
);
|
96
53
|
}
|
97
54
|
);
|
98
55
|
export {
|
99
|
-
|
56
|
+
V as default
|
100
57
|
};
|
101
58
|
//# sourceMappingURL=chapter-item.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"chapter-item.js","sources":["../../../../../src/features/chapters/chapters-list/chapter-item/chapter-item.tsx"],"sourcesContent":["import type { IChapterItemProps } from './chapter-item-types';\nimport type { FC } from 'react';\n\nimport { useCallback, useLayoutEffect, useRef, useState, memo } from 'react';\n\nimport
|
1
|
+
{"version":3,"file":"chapter-item.js","sources":["../../../../../src/features/chapters/chapters-list/chapter-item/chapter-item.tsx"],"sourcesContent":["import type { IChapterItemProps } from './chapter-item-types';\nimport type { FC } from 'react';\n\nimport { useCallback, useLayoutEffect, useRef, useState, memo } from 'react';\nimport { useTheme } from 'styled-components';\n\nimport MilestoneProgressInfoV2 from '../../../milestone/create/comps/milestone-progress-v2/milestone-progress-v2';\nimport ArrowTooltip from '../../../ui/arrow-tooltip/arrow-tooltip';\nimport FlexView from '../../../ui/layout/flex-view';\nimport * as Styled from './chapter-item-styled';\n\nconst ChapterItem: FC<IChapterItemProps> = memo(\n ({ milestoneId, userType, chapter, onChapterClick, itemIndex }) => {\n const theme = useTheme();\n const { gutter } = theme.layout;\n const isOddIndex = !!((itemIndex + 1) % 2);\n const { name, image_url: imageUrl, user_chapter_progress: chapterStats } = chapter;\n const { total_core_sheets: totalLessons } = chapterStats;\n const [showTitleTooltip, setShowTitleTooltip] = useState(false);\n const titleTextRef = useRef<HTMLDivElement>(null);\n\n const handleOnChapterClick = useCallback(() => {\n onChapterClick(chapter, milestoneId);\n }, [chapter, milestoneId, onChapterClick]);\n\n useLayoutEffect(() => {\n if (\n titleTextRef.current &&\n titleTextRef.current.scrollHeight > titleTextRef.current.clientHeight\n ) {\n setShowTitleTooltip(true);\n }\n }, [titleTextRef]);\n\n return (\n <Styled.ChapterItemWrapper\n $justifyContent={'flex-start'}\n $gap={gutter * 1.25}\n $gutter={gutter * 1.25}\n $flexDirection=\"row\"\n $flexColumnGap={gutter}\n $shouldHaveLeftBorder={isOddIndex}\n onClick={handleOnChapterClick}\n id={`milestone-chapter-${milestoneId}-${itemIndex}`}\n className=\"goal-widget-chapter-item\"\n >\n <Styled.ChapterImage src={imageUrl} alt=\"Chapter Image\" />\n <FlexView $justifyContent=\"center\" $flexRowGap={gutter * 0.75}>\n <ArrowTooltip\n renderAs=\"primary\"\n position=\"bottom\"\n tooltipItem={name}\n hidden={!showTitleTooltip}\n widthX={21.75}\n >\n <Styled.ChapterName ref={titleTextRef} $renderAs=\"ab2\" $color=\"BLACK_T_87\">\n {name}\n </Styled.ChapterName>\n </ArrowTooltip>\n {!!totalLessons && (\n <MilestoneProgressInfoV2\n userType={userType}\n milestoneId={milestoneId}\n progressInfo={chapterStats}\n />\n )}\n </FlexView>\n </Styled.ChapterItemWrapper>\n );\n },\n);\n\nexport default ChapterItem;\n"],"names":["ChapterItem","memo","milestoneId","userType","chapter","onChapterClick","itemIndex","theme","useTheme","gutter","isOddIndex","name","imageUrl","chapterStats","totalLessons","showTitleTooltip","setShowTitleTooltip","useState","titleTextRef","useRef","handleOnChapterClick","useCallback","useLayoutEffect","jsxs","Styled.ChapterItemWrapper","jsx","Styled.ChapterImage","FlexView","ArrowTooltip","Styled.ChapterName","MilestoneProgressInfoV2"],"mappings":";;;;;;;AAWA,MAAMA,IAAqCC;AAAA,EACzC,CAAC,EAAE,aAAAC,GAAa,UAAAC,GAAU,SAAAC,GAAS,gBAAAC,GAAgB,WAAAC,QAAgB;AACjE,UAAMC,IAAQC,KACR,EAAE,QAAAC,EAAO,IAAIF,EAAM,QACnBG,IAAa,CAAC,GAAGJ,IAAY,KAAK,IAClC,EAAE,MAAAK,GAAM,WAAWC,GAAU,uBAAuBC,EAAiB,IAAAT,GACrE,EAAE,mBAAmBU,EAAiB,IAAAD,GACtC,CAACE,GAAkBC,CAAmB,IAAIC,EAAS,EAAK,GACxDC,IAAeC,EAAuB,IAAI,GAE1CC,IAAuBC,EAAY,MAAM;AAC7C,MAAAhB,EAAeD,GAASF,CAAW;AAAA,IAClC,GAAA,CAACE,GAASF,GAAaG,CAAc,CAAC;AAEzC,WAAAiB,EAAgB,MAAM;AACpB,MACEJ,EAAa,WACbA,EAAa,QAAQ,eAAeA,EAAa,QAAQ,gBAEzDF,EAAoB,EAAI;AAAA,IAC1B,GACC,CAACE,CAAY,CAAC,GAGf,gBAAAK;AAAA,MAACC;AAAAA,MAAA;AAAA,QACC,iBAAiB;AAAA,QACjB,MAAMf,IAAS;AAAA,QACf,SAASA,IAAS;AAAA,QAClB,gBAAe;AAAA,QACf,gBAAgBA;AAAA,QAChB,uBAAuBC;AAAA,QACvB,SAASU;AAAA,QACT,IAAI,qBAAqBlB,CAAW,IAAII,CAAS;AAAA,QACjD,WAAU;AAAA,QAEV,UAAA;AAAA,UAAA,gBAAAmB,EAACC,GAAA,EAAoB,KAAKd,GAAU,KAAI,iBAAgB;AAAA,4BACvDe,GAAS,EAAA,iBAAgB,UAAS,aAAalB,IAAS,MACvD,UAAA;AAAA,YAAA,gBAAAgB;AAAA,cAACG;AAAA,cAAA;AAAA,gBACC,UAAS;AAAA,gBACT,UAAS;AAAA,gBACT,aAAajB;AAAA,gBACb,QAAQ,CAACI;AAAA,gBACT,QAAQ;AAAA,gBAER,UAAA,gBAAAU,EAACI,GAAA,EAAmB,KAAKX,GAAc,WAAU,OAAM,QAAO,cAC3D,UACHP,EAAA,CAAA;AAAA,cAAA;AAAA,YACF;AAAA,YACC,CAAC,CAACG,KACD,gBAAAW;AAAA,cAACK;AAAA,cAAA;AAAA,gBACC,UAAA3B;AAAA,gBACA,aAAAD;AAAA,gBACA,cAAcW;AAAA,cAAA;AAAA,YAChB;AAAA,UAAA,GAEJ;AAAA,QAAA;AAAA,MAAA;AAAA,IAAA;AAAA,EAGN;AACF;"}
|
@@ -1,15 +1,14 @@
|
|
1
1
|
import r from "styled-components";
|
2
2
|
import { MILESTONE_WIDGET_MIN_HEIGHT as o } from "../../milestone/constants.js";
|
3
|
-
import
|
4
|
-
const s = r(
|
3
|
+
import p from "../../ui/layout/flex-view.js";
|
4
|
+
const s = r(p)`
|
5
5
|
position: relative;
|
6
6
|
min-height: ${o}px;
|
7
7
|
`, n = r.div`
|
8
8
|
display: grid;
|
9
|
-
grid-template-columns: repeat(
|
9
|
+
grid-template-columns: repeat(2, 1fr);
|
10
10
|
align-content: start;
|
11
|
-
|
12
|
-
r.div(({ theme: t }) => `
|
11
|
+
`, d = r.div(({ theme: t }) => `
|
13
12
|
position: absolute;
|
14
13
|
bottom: ${t.layout.gutter}px;
|
15
14
|
right: ${t.layout.gutter}px;
|
@@ -17,6 +16,7 @@ r.div(({ theme: t }) => `
|
|
17
16
|
border-radius: 50%;
|
18
17
|
`);
|
19
18
|
export {
|
19
|
+
d as AddChapterIconWrapper,
|
20
20
|
s as ChaptersListContainer,
|
21
21
|
n as ChaptersWrapper
|
22
22
|
};
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"chapters-list-styled.js","sources":["../../../../src/features/chapters/chapters-list/chapters-list-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport { MILESTONE_WIDGET_MIN_HEIGHT } from '../../milestone/constants';\nimport FlexView from '../../ui/layout/flex-view';\n\nconst ChaptersListContainer = styled(FlexView)`\n position: relative;\n min-height: ${MILESTONE_WIDGET_MIN_HEIGHT}px;\n`;\n\nconst ChaptersWrapper = styled.div`\n display: grid;\n grid-template-columns: repeat(
|
1
|
+
{"version":3,"file":"chapters-list-styled.js","sources":["../../../../src/features/chapters/chapters-list/chapters-list-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport { MILESTONE_WIDGET_MIN_HEIGHT } from '../../milestone/constants';\nimport FlexView from '../../ui/layout/flex-view';\n\nconst ChaptersListContainer = styled(FlexView)`\n position: relative;\n min-height: ${MILESTONE_WIDGET_MIN_HEIGHT}px;\n`;\n\nconst ChaptersWrapper = styled.div`\n display: grid;\n grid-template-columns: repeat(2, 1fr);\n align-content: start;\n`;\n\nconst AddChapterIconWrapper = styled.div(({ theme }) => {\n return `\n position: absolute;\n bottom: ${theme.layout.gutter}px;\n right: ${theme.layout.gutter}px;\n box-shadow: 0px 10px 20px 0px ${theme.colors.BLACK_T_20};\n border-radius: 50%;\n `;\n});\n\nexport { ChaptersListContainer, ChaptersWrapper, AddChapterIconWrapper };\n"],"names":["ChaptersListContainer","styled","FlexView","MILESTONE_WIDGET_MIN_HEIGHT","ChaptersWrapper","AddChapterIconWrapper","theme"],"mappings":";;;AAKM,MAAAA,IAAwBC,EAAOC,CAAQ;AAAA;AAAA,gBAE7BC,CAA2B;AAAA,GAGrCC,IAAkBH,EAAO;AAAA;AAAA;AAAA;AAAA,GAMzBI,IAAwBJ,EAAO,IAAI,CAAC,EAAE,OAAAK,QACnC;AAAA;AAAA,cAEKA,EAAM,OAAO,MAAM;AAAA,aACpBA,EAAM,OAAO,MAAM;AAAA,oCACIA,EAAM,OAAO,UAAU;AAAA;AAAA,GAG1D;"}
|
@@ -1,78 +1,84 @@
|
|
1
|
-
import { jsxs as
|
2
|
-
import { memo as
|
1
|
+
import { jsxs as i, jsx as r, Fragment as T } from "react/jsx-runtime";
|
2
|
+
import { memo as b, useCallback as y } from "react";
|
3
3
|
import { IMAGES as g } from "../../../assets/images/images.js";
|
4
|
-
import k from "
|
5
|
-
import x from "../../ui/
|
4
|
+
import k from "../../../assets/line-icons/icons/plus2.js";
|
5
|
+
import x from "../../ui/arrow-tooltip/arrow-tooltip.js";
|
6
|
+
import E from "../../ui/buttons/button/button.js";
|
7
|
+
import I from "../../ui/buttons/icon-button/icon-button.js";
|
6
8
|
import { useUIContext as $ } from "../../ui/context/context.js";
|
7
|
-
import
|
8
|
-
import
|
9
|
-
import
|
10
|
-
import { ChaptersListContainer as
|
11
|
-
const
|
12
|
-
({ milestoneId: t, canUpdatePlan:
|
13
|
-
const { isGoalCreation:
|
14
|
-
|
9
|
+
import d from "../../ui/separator/separator.js";
|
10
|
+
import L from "../../ui/text/text.js";
|
11
|
+
import X from "./chapter-item/chapter-item.js";
|
12
|
+
import { ChaptersListContainer as h, ChaptersWrapper as M, AddChapterIconWrapper as S } from "./chapters-list-styled.js";
|
13
|
+
const j = b(
|
14
|
+
({ milestoneId: t, canUpdatePlan: n, chapters: a, ...C }) => {
|
15
|
+
const { isGoalCreation: s, userType: o, onChapterClick: f, onAddChapter: e, isMilestoneActive: p } = C, A = o === "TEACHER" && e && n, { onClick: c } = $(), m = y(() => {
|
16
|
+
c({
|
15
17
|
label: "add_chapter_icon",
|
16
18
|
props: {
|
17
19
|
milestone_id: t
|
18
20
|
}
|
19
|
-
}), e == null || e({ milestoneId: t, isGoalCreation:
|
20
|
-
}, [t,
|
21
|
-
return
|
22
|
-
|
23
|
-
|
24
|
-
|
21
|
+
}), e == null || e({ milestoneId: t, isGoalCreation: s });
|
22
|
+
}, [t, s, e, c]);
|
23
|
+
return a.length ? /* @__PURE__ */ i(h, { children: [
|
24
|
+
/* @__PURE__ */ r(M, { children: a.map((l, u) => {
|
25
|
+
const { id: _ } = l;
|
26
|
+
return /* @__PURE__ */ r(
|
27
|
+
X,
|
28
|
+
{
|
29
|
+
milestoneId: t,
|
30
|
+
userType: o,
|
31
|
+
chapter: l,
|
32
|
+
onChapterClick: f,
|
33
|
+
itemIndex: u
|
34
|
+
},
|
35
|
+
_
|
36
|
+
);
|
37
|
+
}) }),
|
38
|
+
A && /* @__PURE__ */ r(S, { children: /* @__PURE__ */ r(
|
39
|
+
I,
|
25
40
|
{
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
)
|
33
|
-
|
34
|
-
|
35
|
-
{
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
43
|
-
|
44
|
-
/* @__PURE__ */ r(
|
45
|
-
|
41
|
+
Icon: k,
|
42
|
+
renderAs: "secondary",
|
43
|
+
size: "small",
|
44
|
+
analyticsLabel: "add_chapter_icon",
|
45
|
+
onClick: m
|
46
|
+
}
|
47
|
+
) })
|
48
|
+
] }) : /* @__PURE__ */ i(h, { $gapX: 6.75, $alignItems: "center", $justifyContent: "center", children: [
|
49
|
+
/* @__PURE__ */ r("img", { src: g.EMPTY_MIX_TESTS, alt: "empty_mix_tests" }),
|
50
|
+
/* @__PURE__ */ r(d, { heightX: 2 }),
|
51
|
+
o === "TEACHER" ? /* @__PURE__ */ i(T, { children: [
|
52
|
+
/* @__PURE__ */ r(
|
53
|
+
x,
|
54
|
+
{
|
55
|
+
renderAs: "primary",
|
56
|
+
position: "bottom",
|
57
|
+
hidden: p,
|
58
|
+
tooltipItem: "Plan is completed",
|
59
|
+
children: /* @__PURE__ */ r(
|
60
|
+
E,
|
46
61
|
{
|
62
|
+
widthX: 10,
|
47
63
|
renderAs: "primary",
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
|
55
|
-
|
56
|
-
shape: "square",
|
57
|
-
size: "small",
|
58
|
-
label: "Add chapter",
|
59
|
-
onClick: f,
|
60
|
-
disabled: !a || !c,
|
61
|
-
analyticsProps: {
|
62
|
-
milestone_id: t
|
63
|
-
}
|
64
|
-
}
|
65
|
-
)
|
64
|
+
shape: "square",
|
65
|
+
size: "small",
|
66
|
+
label: "Add chapter",
|
67
|
+
onClick: m,
|
68
|
+
disabled: !p || !n,
|
69
|
+
analyticsProps: {
|
70
|
+
milestone_id: t
|
71
|
+
}
|
66
72
|
}
|
67
|
-
)
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
}
|
72
|
-
);
|
73
|
+
)
|
74
|
+
}
|
75
|
+
),
|
76
|
+
/* @__PURE__ */ r(d, { heightX: 2 })
|
77
|
+
] }) : /* @__PURE__ */ r(L, { $renderAs: "ab2-bold", $color: "BLACK_T_87", children: "Wait for the teacher to add a chapter" })
|
78
|
+
] });
|
73
79
|
}
|
74
|
-
),
|
80
|
+
), K = j;
|
75
81
|
export {
|
76
|
-
|
82
|
+
K as default
|
77
83
|
};
|
78
84
|
//# sourceMappingURL=chapters-list.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"chapters-list.js","sources":["../../../../src/features/chapters/chapters-list/chapters-list.tsx"],"sourcesContent":["import type { IChaptersListProps } from './chapters-list-types';\nimport type { FC } from 'react';\n\nimport { memo, useCallback } from 'react';\n\nimport { IMAGES } from '../../../assets/images/images';\nimport ArrowTooltip from '../../ui/arrow-tooltip/arrow-tooltip';\nimport Button from '../../ui/buttons/button/button';\nimport { useUIContext } from '../../ui/context/context';\nimport Separator from '../../ui/separator/separator';\nimport Text from '../../ui/text/text';\nimport ChapterItem from './chapter-item/chapter-item';\nimport * as Styled from './chapters-list-styled';\n\nconst ChaptersList: FC<IChaptersListProps> = memo(\n ({ milestoneId, canUpdatePlan, chapters, ...restChaptersList }) => {\n const { isGoalCreation, userType, onChapterClick, onAddChapter, isMilestoneActive } =\n restChaptersList;\n\n const { onClick: trackOnClick } = useUIContext();\n\n const handleOnAddChapter = useCallback(() => {\n trackOnClick({\n label: 'add_chapter_icon',\n props: {\n milestone_id: milestoneId,\n },\n });\n onAddChapter?.({ milestoneId, isGoalCreation });\n }, [milestoneId, isGoalCreation, onAddChapter, trackOnClick]);\n\n if (!chapters.length) {\n return (\n <Styled.ChaptersListContainer
|
1
|
+
{"version":3,"file":"chapters-list.js","sources":["../../../../src/features/chapters/chapters-list/chapters-list.tsx"],"sourcesContent":["import type { IChaptersListProps } from './chapters-list-types';\nimport type { FC } from 'react';\n\nimport { memo, useCallback } from 'react';\n\nimport { IMAGES } from '../../../assets/images/images';\nimport Plus2Icon from '../../../assets/line-icons/icons/plus2';\nimport ArrowTooltip from '../../ui/arrow-tooltip/arrow-tooltip';\nimport Button from '../../ui/buttons/button/button';\nimport IconButton from '../../ui/buttons/icon-button/icon-button';\nimport { useUIContext } from '../../ui/context/context';\nimport Separator from '../../ui/separator/separator';\nimport Text from '../../ui/text/text';\nimport ChapterItem from './chapter-item/chapter-item';\nimport * as Styled from './chapters-list-styled';\n\nconst ChaptersList: FC<IChaptersListProps> = memo(\n ({ milestoneId, canUpdatePlan, chapters, ...restChaptersList }) => {\n const { isGoalCreation, userType, onChapterClick, onAddChapter, isMilestoneActive } =\n restChaptersList;\n\n const canAddChapter = userType === 'TEACHER' && onAddChapter && canUpdatePlan;\n const { onClick: trackOnClick } = useUIContext();\n\n const handleOnAddChapter = useCallback(() => {\n trackOnClick({\n label: 'add_chapter_icon',\n props: {\n milestone_id: milestoneId,\n },\n });\n onAddChapter?.({ milestoneId, isGoalCreation });\n }, [milestoneId, isGoalCreation, onAddChapter, trackOnClick]);\n\n if (!chapters.length) {\n return (\n <Styled.ChaptersListContainer $gapX={6.75} $alignItems=\"center\" $justifyContent=\"center\">\n <img src={IMAGES.EMPTY_MIX_TESTS} alt=\"empty_mix_tests\" />\n <Separator heightX={2} />\n {userType === 'TEACHER' ? (\n <>\n <ArrowTooltip\n renderAs=\"primary\"\n position=\"bottom\"\n hidden={isMilestoneActive}\n tooltipItem=\"Plan is completed\"\n >\n <Button\n widthX={10}\n renderAs=\"primary\"\n shape=\"square\"\n size=\"small\"\n label=\"Add chapter\"\n onClick={handleOnAddChapter}\n disabled={!isMilestoneActive || !canUpdatePlan}\n analyticsProps={{\n milestone_id: milestoneId,\n }}\n />\n </ArrowTooltip>\n <Separator heightX={2} />\n </>\n ) : (\n <Text $renderAs=\"ab2-bold\" $color=\"BLACK_T_87\">\n Wait for the teacher to add a chapter\n </Text>\n )}\n </Styled.ChaptersListContainer>\n );\n }\n\n return (\n <Styled.ChaptersListContainer>\n <Styled.ChaptersWrapper>\n {chapters.map((chapter, idx) => {\n const { id } = chapter;\n\n return (\n <ChapterItem\n key={id}\n milestoneId={milestoneId}\n userType={userType}\n chapter={chapter}\n onChapterClick={onChapterClick}\n itemIndex={idx}\n />\n );\n })}\n </Styled.ChaptersWrapper>\n {canAddChapter && (\n <Styled.AddChapterIconWrapper>\n <IconButton\n Icon={Plus2Icon}\n renderAs=\"secondary\"\n size=\"small\"\n analyticsLabel=\"add_chapter_icon\"\n onClick={handleOnAddChapter}\n />\n </Styled.AddChapterIconWrapper>\n )}\n </Styled.ChaptersListContainer>\n );\n },\n);\n\nexport default ChaptersList;\n"],"names":["ChaptersList","memo","milestoneId","canUpdatePlan","chapters","restChaptersList","isGoalCreation","userType","onChapterClick","onAddChapter","isMilestoneActive","canAddChapter","trackOnClick","useUIContext","handleOnAddChapter","useCallback","jsxs","Styled.ChaptersListContainer","jsx","Styled.ChaptersWrapper","chapter","idx","id","ChapterItem","Styled.AddChapterIconWrapper","IconButton","Plus2Icon","IMAGES","Separator","Fragment","ArrowTooltip","Button","Text","ChaptersList$1"],"mappings":";;;;;;;;;;;;AAgBA,MAAMA,IAAuCC;AAAA,EAC3C,CAAC,EAAE,aAAAC,GAAa,eAAAC,GAAe,UAAAC,GAAU,GAAGC,QAAuB;AACjE,UAAM,EAAE,gBAAAC,GAAgB,UAAAC,GAAU,gBAAAC,GAAgB,cAAAC,GAAc,mBAAAC,EAC9D,IAAAL,GAEIM,IAAgBJ,MAAa,aAAaE,KAAgBN,GAC1D,EAAE,SAASS,EAAa,IAAIC,EAAa,GAEzCC,IAAqBC,EAAY,MAAM;AAC9B,MAAAH,EAAA;AAAA,QACX,OAAO;AAAA,QACP,OAAO;AAAA,UACL,cAAcV;AAAA,QAChB;AAAA,MAAA,CACD,GACcO,KAAA,QAAAA,EAAA,EAAE,aAAAP,GAAa,gBAAAI,EAAA;AAAA,OAC7B,CAACJ,GAAaI,GAAgBG,GAAcG,CAAY,CAAC;AAExD,WAACR,EAAS,SAsCZ,gBAAAY,EAACC,GAAA,EACC,UAAA;AAAA,MAAA,gBAAAC,EAACC,GAAA,EACE,YAAS,IAAI,CAACC,GAASC,MAAQ;AACxB,cAAA,EAAE,IAAAC,EAAO,IAAAF;AAGb,eAAA,gBAAAF;AAAA,UAACK;AAAA,UAAA;AAAA,YAEC,aAAArB;AAAA,YACA,UAAAK;AAAA,YACA,SAAAa;AAAA,YACA,gBAAAZ;AAAA,YACA,WAAWa;AAAA,UAAA;AAAA,UALNC;AAAA,QAAA;AAAA,MAQV,CAAA,GACH;AAAA,MACCX,KACC,gBAAAO,EAACM,GAAA,EACC,UAAA,gBAAAN;AAAA,QAACO;AAAA,QAAA;AAAA,UACC,MAAMC;AAAA,UACN,UAAS;AAAA,UACT,MAAK;AAAA,UACL,gBAAe;AAAA,UACf,SAASZ;AAAA,QAAA;AAAA,MAAA,GAEb;AAAA,IAEJ,EAAA,CAAA,IAhEE,gBAAAE,EAACC,GAAA,EAA6B,OAAO,MAAM,aAAY,UAAS,iBAAgB,UAC9E,UAAA;AAAA,MAAA,gBAAAC,EAAC,OAAI,EAAA,KAAKS,EAAO,iBAAiB,KAAI,mBAAkB;AAAA,MACxD,gBAAAT,EAACU,GAAU,EAAA,SAAS,EAAG,CAAA;AAAA,MACtBrB,MAAa,YAEV,gBAAAS,EAAAa,GAAA,EAAA,UAAA;AAAA,QAAA,gBAAAX;AAAA,UAACY;AAAA,UAAA;AAAA,YACC,UAAS;AAAA,YACT,UAAS;AAAA,YACT,QAAQpB;AAAA,YACR,aAAY;AAAA,YAEZ,UAAA,gBAAAQ;AAAA,cAACa;AAAA,cAAA;AAAA,gBACC,QAAQ;AAAA,gBACR,UAAS;AAAA,gBACT,OAAM;AAAA,gBACN,MAAK;AAAA,gBACL,OAAM;AAAA,gBACN,SAASjB;AAAA,gBACT,UAAU,CAACJ,KAAqB,CAACP;AAAA,gBACjC,gBAAgB;AAAA,kBACd,cAAcD;AAAA,gBAChB;AAAA,cAAA;AAAA,YACF;AAAA,UAAA;AAAA,QACF;AAAA,QACA,gBAAAgB,EAACU,GAAU,EAAA,SAAS,EAAG,CAAA;AAAA,MAAA,EAAA,CACzB,IAEC,gBAAAV,EAAAc,GAAA,EAAK,WAAU,YAAW,QAAO,cAAa,UAE/C,yCAAA;AAAA,IAEJ,EAAA,CAAA;AAAA,EAmCN;AACF,GAEAC,IAAejC;"}
|
@@ -7,15 +7,13 @@ const E = {
|
|
7
7
|
EXTRA_PRACTICE_ASSIGNED: "EXTRA_PRACTICE_ASSIGNED",
|
8
8
|
CHANGE_LOCATION: "CHANGE_LOCATION",
|
9
9
|
SHEET_STARTED: "SHEET_STARTED",
|
10
|
-
SHEET_UNASSIGNED: "SHEET_UNASSIGNED"
|
11
|
-
SHEET_REATTEMPTED: "SHEET_REATTEMPTED",
|
12
|
-
INVALIDATE_CHAPTER_ON_CHANGE_ATTEMPT_LOCATION: "INVALIDATE_CHAPTER_ON_CHANGE_ATTEMPT_LOCATION"
|
10
|
+
SHEET_UNASSIGNED: "SHEET_UNASSIGNED"
|
13
11
|
}, S = {
|
14
12
|
GOAL_CREATED: "GOAL_CREATED",
|
15
13
|
GOAL_EDITED: "GOAL_EDITED",
|
16
14
|
GOAL_DELETED: "GOAL_DELETED",
|
17
15
|
GOAL_OUTCOME_ADDED: "GOAL_OUTCOME_ADDED"
|
18
|
-
},
|
16
|
+
}, _ = {
|
19
17
|
MILESTONE_NAME_UPDATED: "MILESTONE_NAME_UPDATED",
|
20
18
|
MILESTONE_DATE_UPDATED: "MILESTONE_DATE_UPDATED",
|
21
19
|
MILESTONE_DELETED: "MILESTONE_DELETED",
|
@@ -25,16 +23,12 @@ const E = {
|
|
25
23
|
MILESTONE_RESOURCE_RESET: "MILESTONE_RESOURCE_RESET",
|
26
24
|
PAST_MILESTONE_OUTCOME_ADDED: "PAST_MILESTONE_OUTCOME_ADDED",
|
27
25
|
MILESTONE_TEST_ASSIGNED: "MILESTONE_TEST_ASSIGNED"
|
28
|
-
},
|
29
|
-
HOMEWORK_UNASSIGN: "HOMEWORK_UNASSIGN",
|
30
|
-
INVALIDATE_HOMEWORK: "INVALIDATE_HOMEWORK"
|
31
|
-
}, A = {
|
26
|
+
}, T = {
|
32
27
|
...E,
|
33
|
-
...
|
34
|
-
...S
|
35
|
-
..._
|
28
|
+
..._,
|
29
|
+
...S
|
36
30
|
};
|
37
31
|
export {
|
38
|
-
|
32
|
+
T as EVENTS
|
39
33
|
};
|
40
34
|
//# sourceMappingURL=constants.js.map
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"constants.js","sources":["../../../../src/features/communication/pub-sub/constants.ts"],"sourcesContent":["const CHAPTER_SHEET_EVENTS = {\n CHAPTER_UPDATED: 'CHAPTER_UPDATED',\n LESSONS_MARKED_AS_FAMILIAR: 'LESSONS_MARKED_AS_FAMILIAR',\n LESSONS_MARKED_AS_IRRELEVANT: 'LESSONS_MARKED_AS_IRRELEVANT',\n LESSONS_PROGRESS_RESET: 'LESSONS_PROGRESS_RESET',\n UNLOCK_SHEETS: 'UNLOCK_SHEETS',\n EXTRA_PRACTICE_ASSIGNED: 'EXTRA_PRACTICE_ASSIGNED',\n CHANGE_LOCATION: 'CHANGE_LOCATION',\n SHEET_STARTED: 'SHEET_STARTED',\n SHEET_UNASSIGNED: 'SHEET_UNASSIGNED',\n
|
1
|
+
{"version":3,"file":"constants.js","sources":["../../../../src/features/communication/pub-sub/constants.ts"],"sourcesContent":["const CHAPTER_SHEET_EVENTS = {\n CHAPTER_UPDATED: 'CHAPTER_UPDATED',\n LESSONS_MARKED_AS_FAMILIAR: 'LESSONS_MARKED_AS_FAMILIAR',\n LESSONS_MARKED_AS_IRRELEVANT: 'LESSONS_MARKED_AS_IRRELEVANT',\n LESSONS_PROGRESS_RESET: 'LESSONS_PROGRESS_RESET',\n UNLOCK_SHEETS: 'UNLOCK_SHEETS',\n EXTRA_PRACTICE_ASSIGNED: 'EXTRA_PRACTICE_ASSIGNED',\n CHANGE_LOCATION: 'CHANGE_LOCATION',\n SHEET_STARTED: 'SHEET_STARTED',\n SHEET_UNASSIGNED: 'SHEET_UNASSIGNED',\n} as const;\n\nconst GOAL_EVENTS = {\n GOAL_CREATED: 'GOAL_CREATED',\n GOAL_EDITED: 'GOAL_EDITED',\n GOAL_DELETED: 'GOAL_DELETED',\n GOAL_OUTCOME_ADDED: 'GOAL_OUTCOME_ADDED',\n} as const;\n\nconst MILESTONE_EVENTS = {\n MILESTONE_NAME_UPDATED: 'MILESTONE_NAME_UPDATED',\n MILESTONE_DATE_UPDATED: 'MILESTONE_DATE_UPDATED',\n MILESTONE_DELETED: 'MILESTONE_DELETED',\n MILESTONE_EDITED: 'MILESTONE_EDITED',\n MILESTONE_RESOURCE_ASSIGNED: 'MILESTONE_RESOURCE_ASSIGNED',\n MILESTONE_RESOURCE_UNASSIGNED: 'MILESTONE_RESOURCE_UNASSIGNED',\n MILESTONE_RESOURCE_RESET: 'MILESTONE_RESOURCE_RESET',\n PAST_MILESTONE_OUTCOME_ADDED: 'PAST_MILESTONE_OUTCOME_ADDED',\n MILESTONE_TEST_ASSIGNED: 'MILESTONE_TEST_ASSIGNED',\n} as const;\n\nconst EVENTS = {\n ...CHAPTER_SHEET_EVENTS,\n ...MILESTONE_EVENTS,\n ...GOAL_EVENTS,\n};\n\nexport { EVENTS };\n"],"names":["CHAPTER_SHEET_EVENTS","GOAL_EVENTS","MILESTONE_EVENTS","EVENTS"],"mappings":"AAAA,MAAMA,IAAuB;AAAA,EAC3B,iBAAiB;AAAA,EACjB,4BAA4B;AAAA,EAC5B,8BAA8B;AAAA,EAC9B,wBAAwB;AAAA,EACxB,eAAe;AAAA,EACf,yBAAyB;AAAA,EACzB,iBAAiB;AAAA,EACjB,eAAe;AAAA,EACf,kBAAkB;AACpB,GAEMC,IAAc;AAAA,EAClB,cAAc;AAAA,EACd,aAAa;AAAA,EACb,cAAc;AAAA,EACd,oBAAoB;AACtB,GAEMC,IAAmB;AAAA,EACvB,wBAAwB;AAAA,EACxB,wBAAwB;AAAA,EACxB,mBAAmB;AAAA,EACnB,kBAAkB;AAAA,EAClB,6BAA6B;AAAA,EAC7B,+BAA+B;AAAA,EAC/B,0BAA0B;AAAA,EAC1B,8BAA8B;AAAA,EAC9B,yBAAyB;AAC3B,GAEMC,IAAS;AAAA,EACb,GAAGH;AAAA,EACH,GAAGE;AAAA,EACH,GAAGD;AACL;"}
|
@@ -1,43 +1,43 @@
|
|
1
|
-
import { jsx as
|
2
|
-
import { useMemo as
|
1
|
+
import { jsx as o, jsxs as g, Fragment as f } from "react/jsx-runtime";
|
2
|
+
import { useMemo as p } from "react";
|
3
3
|
import m from "../../../ui/arrow-tooltip/arrow-tooltip.js";
|
4
|
-
import
|
5
|
-
import { BLUR_OVERLAY_Z_INDEX as T, IndicatorType as
|
6
|
-
import { CoachmarkBody as
|
7
|
-
import { toolTipGetXCoordinates as
|
4
|
+
import y from "../../../ui/nudge/nudge.js";
|
5
|
+
import { BLUR_OVERLAY_Z_INDEX as T, IndicatorType as d } from "../../use-journey/constants.js";
|
6
|
+
import { CoachmarkBody as P, ClonedElementWrapper as s } from "./coachmark-styled.js";
|
7
|
+
import { toolTipGetXCoordinates as $ } from "./coachmark-utils.js";
|
8
8
|
const H = ({ coachmark: t }) => {
|
9
|
-
const i = t.originalElementToHighlightRef.current, { top: r = 0, left: n = 0, height: h = 0, width: C = 0 } = (i == null ? void 0 : i.getBoundingClientRect()) || {}, l =
|
10
|
-
const
|
9
|
+
const i = t.originalElementToHighlightRef.current, { top: r = 0, left: n = 0, height: h = 0, width: C = 0 } = (i == null ? void 0 : i.getBoundingClientRect()) || {}, l = p(() => () => i ? window.getComputedStyle(i).position === "absolute" : !1, [i]), u = p(() => {
|
10
|
+
const e = t.indicator;
|
11
11
|
return {
|
12
12
|
width: 264,
|
13
13
|
// Can be over ridden
|
14
|
-
tooltipXCoOrdinates:
|
14
|
+
tooltipXCoOrdinates: $(e.position) + (e.tooltipXCoOrdinates ?? 0),
|
15
15
|
// For absolutely positioned elements
|
16
16
|
zIndex: T + 1,
|
17
|
-
...
|
18
|
-
tooltipItem: /* @__PURE__ */
|
17
|
+
...e,
|
18
|
+
tooltipItem: /* @__PURE__ */ o(P, { children: e.tooltipItem }),
|
19
19
|
alwaysVisible: !0,
|
20
20
|
renderAs: "primary",
|
21
21
|
// Deprecate this
|
22
22
|
borderWidth: 1,
|
23
|
-
arrowColor:
|
24
|
-
borderColor:
|
25
|
-
type:
|
23
|
+
arrowColor: "WHITE",
|
24
|
+
borderColor: "WHITE",
|
25
|
+
type: d.TOOLTIP,
|
26
26
|
isAnimated: !0
|
27
27
|
};
|
28
|
-
}, [t.indicator]), I =
|
29
|
-
const
|
28
|
+
}, [t.indicator]), I = p(() => {
|
29
|
+
const e = t.indicator;
|
30
30
|
return {
|
31
|
-
...
|
32
|
-
nudgePointerX: n + (
|
33
|
-
nudgePointerY: r + (
|
31
|
+
...e,
|
32
|
+
nudgePointerX: n + (e.nudgePointerX ?? 0),
|
33
|
+
nudgePointerY: r + (e.nudgePointerY ?? 0)
|
34
34
|
};
|
35
35
|
}, [t.indicator, n, r]);
|
36
|
-
return !i || !t.isActive ? null : t.type ===
|
36
|
+
return !i || !t.isActive ? null : t.type === d.TOOLTIP ? l() ? /* @__PURE__ */ g(f, { children: [
|
37
37
|
t.elementToHighlight,
|
38
|
-
/* @__PURE__ */
|
39
|
-
] }) : /* @__PURE__ */
|
40
|
-
/* @__PURE__ */
|
38
|
+
/* @__PURE__ */ o(s, { $position: "absolute", $top: r, $left: n, children: /* @__PURE__ */ o(m, { ...u, children: /* @__PURE__ */ o("div", { style: { height: h, width: C } }) }) })
|
39
|
+
] }) : /* @__PURE__ */ o(s, { $position: "absolute", $top: r, $left: n, children: /* @__PURE__ */ o(m, { ...u, children: t.elementToHighlight }) }) : t.type === d.NUDGE ? /* @__PURE__ */ g(f, { children: [
|
40
|
+
/* @__PURE__ */ o(
|
41
41
|
s,
|
42
42
|
{
|
43
43
|
$top: l() ? 0 : r,
|
@@ -46,7 +46,7 @@ const H = ({ coachmark: t }) => {
|
|
46
46
|
children: t.elementToHighlight
|
47
47
|
}
|
48
48
|
),
|
49
|
-
/* @__PURE__ */
|
49
|
+
/* @__PURE__ */ o(y, { zIndex: T + 1, ...I })
|
50
50
|
] }) : null;
|
51
51
|
};
|
52
52
|
export {
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"coachmark.js","sources":["../../../../../src/features/journey/comps/coachmark/coachmark.tsx"],"sourcesContent":["import type { IArrowTooltipProps } from '../../../ui/arrow-tooltip/arrow-tooltip-types';\nimport type { INudgeProps } from '../../../ui/nudge/nudge-types';\nimport type { ICoachmarkProps } from '../../use-journey/journey-context-types';\n\nimport React, { useMemo } from 'react';\n\nimport ArrowTooltip from '../../../ui/arrow-tooltip/arrow-tooltip';\nimport Nudge from '../../../ui/nudge/nudge';\nimport { BLUR_OVERLAY_Z_INDEX, IndicatorType } from '../../use-journey/constants';\nimport * as S from './coachmark-styled';\nimport { toolTipGetXCoordinates } from './coachmark-utils';\n\nexport const Coachmark: React.FC<{ coachmark: ICoachmarkProps }> = ({ coachmark }) => {\n const targetElement = coachmark.originalElementToHighlightRef.current;\n const { top = 0, left = 0, height = 0, width = 0 } = targetElement?.getBoundingClientRect() || {};\n\n const isAbsolute = useMemo(() => {\n return () => {\n if (!targetElement) return false;\n\n return window.getComputedStyle(targetElement).position === 'absolute';\n };\n }, [targetElement]);\n\n const tooltipProps = useMemo(() => {\n const arrowToolTipProps = coachmark.indicator as IArrowTooltipProps;\n\n return {\n width: 264, // Can be over ridden\n tooltipXCoOrdinates:\n toolTipGetXCoordinates(arrowToolTipProps.position) +\n (arrowToolTipProps.tooltipXCoOrdinates ?? 0), // For absolutely positioned elements\n zIndex: BLUR_OVERLAY_Z_INDEX + 1,\n ...arrowToolTipProps,\n tooltipItem: <S.CoachmarkBody>{arrowToolTipProps.tooltipItem}</S.CoachmarkBody>,\n alwaysVisible: true,\n renderAs: 'primary', // Deprecate this\n borderWidth: 1,\n arrowColor:
|
1
|
+
{"version":3,"file":"coachmark.js","sources":["../../../../../src/features/journey/comps/coachmark/coachmark.tsx"],"sourcesContent":["import type { IArrowTooltipProps } from '../../../ui/arrow-tooltip/arrow-tooltip-types';\nimport type { INudgeProps } from '../../../ui/nudge/nudge-types';\nimport type { ICoachmarkProps } from '../../use-journey/journey-context-types';\n\nimport React, { useMemo } from 'react';\n\nimport ArrowTooltip from '../../../ui/arrow-tooltip/arrow-tooltip';\nimport Nudge from '../../../ui/nudge/nudge';\nimport { BLUR_OVERLAY_Z_INDEX, IndicatorType } from '../../use-journey/constants';\nimport * as S from './coachmark-styled';\nimport { toolTipGetXCoordinates } from './coachmark-utils';\n\nexport const Coachmark: React.FC<{ coachmark: ICoachmarkProps }> = ({ coachmark }) => {\n const targetElement = coachmark.originalElementToHighlightRef.current;\n const { top = 0, left = 0, height = 0, width = 0 } = targetElement?.getBoundingClientRect() || {};\n\n const isAbsolute = useMemo(() => {\n return () => {\n if (!targetElement) return false;\n\n return window.getComputedStyle(targetElement).position === 'absolute';\n };\n }, [targetElement]);\n\n const tooltipProps = useMemo(() => {\n const arrowToolTipProps = coachmark.indicator as IArrowTooltipProps;\n\n return {\n width: 264, // Can be over ridden\n tooltipXCoOrdinates:\n toolTipGetXCoordinates(arrowToolTipProps.position) +\n (arrowToolTipProps.tooltipXCoOrdinates ?? 0), // For absolutely positioned elements\n zIndex: BLUR_OVERLAY_Z_INDEX + 1,\n ...arrowToolTipProps,\n tooltipItem: <S.CoachmarkBody>{arrowToolTipProps.tooltipItem}</S.CoachmarkBody>,\n alwaysVisible: true,\n renderAs: 'primary', // Deprecate this\n borderWidth: 1,\n arrowColor: 'WHITE',\n borderColor: 'WHITE',\n type: IndicatorType.TOOLTIP,\n isAnimated: true,\n } as IArrowTooltipProps;\n }, [coachmark.indicator]);\n\n const nudgeProps = useMemo(() => {\n const props: INudgeProps = coachmark.indicator as INudgeProps;\n\n return {\n ...props,\n nudgePointerX: left + (props.nudgePointerX ?? 0),\n nudgePointerY: top + (props.nudgePointerY ?? 0),\n };\n }, [coachmark.indicator, left, top]);\n\n if (!targetElement || !coachmark.isActive) {\n return null;\n }\n\n if (coachmark.type === IndicatorType.TOOLTIP) {\n if (isAbsolute()) {\n return (\n <>\n {coachmark.elementToHighlight}\n <S.ClonedElementWrapper $position=\"absolute\" $top={top} $left={left}>\n <ArrowTooltip {...tooltipProps}>\n <div style={{ height, width }} />\n </ArrowTooltip>\n </S.ClonedElementWrapper>\n </>\n );\n }\n\n return (\n <S.ClonedElementWrapper $position=\"absolute\" $top={top} $left={left}>\n <ArrowTooltip {...tooltipProps}>{coachmark.elementToHighlight}</ArrowTooltip>\n </S.ClonedElementWrapper>\n );\n }\n\n if (coachmark.type === IndicatorType.NUDGE) {\n return (\n <>\n <S.ClonedElementWrapper\n $top={isAbsolute() ? 0 : top}\n $left={isAbsolute() ? 0 : left}\n $position={isAbsolute() ? 'relative' : 'absolute'}\n >\n {coachmark.elementToHighlight}\n </S.ClonedElementWrapper>\n <Nudge zIndex={BLUR_OVERLAY_Z_INDEX + 1} {...nudgeProps} />\n </>\n );\n }\n\n return null;\n};\n"],"names":["Coachmark","coachmark","targetElement","top","left","height","width","isAbsolute","useMemo","tooltipProps","arrowToolTipProps","toolTipGetXCoordinates","BLUR_OVERLAY_Z_INDEX","jsx","S.CoachmarkBody","IndicatorType","nudgeProps","props","jsxs","Fragment","S.ClonedElementWrapper","ArrowTooltip","Nudge"],"mappings":";;;;;;;AAYO,MAAMA,IAAsD,CAAC,EAAE,WAAAC,QAAgB;AAC9E,QAAAC,IAAgBD,EAAU,8BAA8B,SACxD,EAAE,KAAAE,IAAM,GAAG,MAAAC,IAAO,GAAG,QAAAC,IAAS,GAAG,OAAAC,IAAQ,EAAE,KAAIJ,KAAA,gBAAAA,EAAe,4BAA2B,CAAA,GAEzFK,IAAaC,EAAQ,MAClB,MACAN,IAEE,OAAO,iBAAiBA,CAAa,EAAE,aAAa,aAFhC,IAI5B,CAACA,CAAa,CAAC,GAEZO,IAAeD,EAAQ,MAAM;AACjC,UAAME,IAAoBT,EAAU;AAE7B,WAAA;AAAA,MACL,OAAO;AAAA;AAAA,MACP,qBACEU,EAAuBD,EAAkB,QAAQ,KAChDA,EAAkB,uBAAuB;AAAA;AAAA,MAC5C,QAAQE,IAAuB;AAAA,MAC/B,GAAGF;AAAA,MACH,aAAc,gBAAAG,EAAAC,GAAA,EAAiB,YAAkB,aAAY;AAAA,MAC7D,eAAe;AAAA,MACf,UAAU;AAAA;AAAA,MACV,aAAa;AAAA,MACb,YAAY;AAAA,MACZ,aAAa;AAAA,MACb,MAAMC,EAAc;AAAA,MACpB,YAAY;AAAA,IAAA;AAAA,EACd,GACC,CAACd,EAAU,SAAS,CAAC,GAElBe,IAAaR,EAAQ,MAAM;AAC/B,UAAMS,IAAqBhB,EAAU;AAE9B,WAAA;AAAA,MACL,GAAGgB;AAAA,MACH,eAAeb,KAAQa,EAAM,iBAAiB;AAAA,MAC9C,eAAed,KAAOc,EAAM,iBAAiB;AAAA,IAAA;AAAA,KAE9C,CAAChB,EAAU,WAAWG,GAAMD,CAAG,CAAC;AAEnC,SAAI,CAACD,KAAiB,CAACD,EAAU,WACxB,OAGLA,EAAU,SAASc,EAAc,UAC/BR,MAGG,gBAAAW,EAAAC,GAAA,EAAA,UAAA;AAAA,IAAUlB,EAAA;AAAA,IACX,gBAAAY,EAACO,GAAA,EAAuB,WAAU,YAAW,MAAMjB,GAAK,OAAOC,GAC7D,UAAA,gBAAAS,EAACQ,KAAc,GAAGZ,GAChB,4BAAC,OAAI,EAAA,OAAO,EAAE,QAAAJ,GAAQ,OAAAC,EAAA,GAAS,EAAA,CACjC,EACF,CAAA;AAAA,EACF,EAAA,CAAA,sBAKDc,GAAA,EAAuB,WAAU,YAAW,MAAMjB,GAAK,OAAOC,GAC7D,4BAACiB,GAAc,EAAA,GAAGZ,GAAe,UAAAR,EAAU,oBAAmB,EAChE,CAAA,IAIAA,EAAU,SAASc,EAAc,QAG/B,gBAAAG,EAAAC,GAAA,EAAA,UAAA;AAAA,IAAA,gBAAAN;AAAA,MAACO;AAAAA,MAAA;AAAA,QACC,MAAMb,MAAe,IAAIJ;AAAA,QACzB,OAAOI,MAAe,IAAIH;AAAA,QAC1B,WAAWG,MAAe,aAAa;AAAA,QAEtC,UAAUN,EAAA;AAAA,MAAA;AAAA,IACb;AAAA,sBACCqB,GAAM,EAAA,QAAQV,IAAuB,GAAI,GAAGI,GAAY;AAAA,EAC3D,EAAA,CAAA,IAIG;AACT;"}
|
@@ -1,4 +1,4 @@
|
|
1
|
-
var E = /* @__PURE__ */ ((R) => (R.CIRCLE_ACTIVITIES_INTRO_JOURNEY = "CIRCLE_ACTIVITIES_INTRO_JOURNEY", R.CIRCLE_LEADERBOARD_INTRO_JOURNEY = "CIRCLE_LEADERBOARD_INTRO_JOURNEY", R.CIRCLE_POINTS_REWARD_JOURNEY = "CIRCLE_POINTS_REWARD_JOURNEY", R.CIRCLE_STREAK_UPDATE_JOURNEY = "CIRCLE_STREAK_UPDATE_JOURNEY", R.CIRCLE_TUTORIAL_JOURNEY = "CIRCLE_TUTORIAL_JOURNEY", R.CIRCLE_TABLES_INTRO_JOURNEY = "CIRCLE_TABLES_INTRO_JOURNEY", R.CIRCLE_STREAK_REDUCTION_JOURNEY = "CIRCLE_STREAK_REDUCTION_JOURNEY", R
|
1
|
+
var E = /* @__PURE__ */ ((R) => (R.CIRCLE_ACTIVITIES_INTRO_JOURNEY = "CIRCLE_ACTIVITIES_INTRO_JOURNEY", R.CIRCLE_LEADERBOARD_INTRO_JOURNEY = "CIRCLE_LEADERBOARD_INTRO_JOURNEY", R.CIRCLE_POINTS_REWARD_JOURNEY = "CIRCLE_POINTS_REWARD_JOURNEY", R.CIRCLE_STREAK_UPDATE_JOURNEY = "CIRCLE_STREAK_UPDATE_JOURNEY", R.CIRCLE_TUTORIAL_JOURNEY = "CIRCLE_TUTORIAL_JOURNEY", R.CIRCLE_TABLES_INTRO_JOURNEY = "CIRCLE_TABLES_INTRO_JOURNEY", R.CIRCLE_STREAK_REDUCTION_JOURNEY = "CIRCLE_STREAK_REDUCTION_JOURNEY", R))(E || {});
|
2
2
|
export {
|
3
3
|
E as JOURNEY_ID_STUDENT
|
4
4
|
};
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"journey-id-student.js","sources":["../../../../src/features/journey/journey-id/journey-id-student.ts"],"sourcesContent":["export enum JOURNEY_ID_STUDENT {\n CIRCLE_ACTIVITIES_INTRO_JOURNEY = 'CIRCLE_ACTIVITIES_INTRO_JOURNEY',\n CIRCLE_LEADERBOARD_INTRO_JOURNEY = 'CIRCLE_LEADERBOARD_INTRO_JOURNEY',\n CIRCLE_POINTS_REWARD_JOURNEY = 'CIRCLE_POINTS_REWARD_JOURNEY',\n CIRCLE_STREAK_UPDATE_JOURNEY = 'CIRCLE_STREAK_UPDATE_JOURNEY',\n CIRCLE_TUTORIAL_JOURNEY = 'CIRCLE_TUTORIAL_JOURNEY',\n CIRCLE_TABLES_INTRO_JOURNEY = 'CIRCLE_TABLES_INTRO_JOURNEY',\n\n // TODO: Deprecate bottom journeys, they are not actually journeys\n CIRCLE_STREAK_REDUCTION_JOURNEY = 'CIRCLE_STREAK_REDUCTION_JOURNEY',\n
|
1
|
+
{"version":3,"file":"journey-id-student.js","sources":["../../../../src/features/journey/journey-id/journey-id-student.ts"],"sourcesContent":["export enum JOURNEY_ID_STUDENT {\n CIRCLE_ACTIVITIES_INTRO_JOURNEY = 'CIRCLE_ACTIVITIES_INTRO_JOURNEY',\n CIRCLE_LEADERBOARD_INTRO_JOURNEY = 'CIRCLE_LEADERBOARD_INTRO_JOURNEY',\n CIRCLE_POINTS_REWARD_JOURNEY = 'CIRCLE_POINTS_REWARD_JOURNEY',\n CIRCLE_STREAK_UPDATE_JOURNEY = 'CIRCLE_STREAK_UPDATE_JOURNEY',\n CIRCLE_TUTORIAL_JOURNEY = 'CIRCLE_TUTORIAL_JOURNEY',\n CIRCLE_TABLES_INTRO_JOURNEY = 'CIRCLE_TABLES_INTRO_JOURNEY',\n\n // TODO: Deprecate bottom journeys, they are not actually journeys\n CIRCLE_STREAK_REDUCTION_JOURNEY = 'CIRCLE_STREAK_REDUCTION_JOURNEY',\n}\n"],"names":["JOURNEY_ID_STUDENT"],"mappings":"AAAY,IAAAA,sBAAAA,OACVA,EAAA,kCAAkC,mCAClCA,EAAA,mCAAmC,oCACnCA,EAAA,+BAA+B,gCAC/BA,EAAA,+BAA+B,gCAC/BA,EAAA,0BAA0B,2BAC1BA,EAAA,8BAA8B,+BAG9BA,EAAA,kCAAkC,mCATxBA,IAAAA,KAAA,CAAA,CAAA;"}
|