@cuemath/leap 3.3.0 → 3.3.2-2.beta-guru-01

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.
Files changed (399) hide show
  1. package/dist/assets/gif/gif.js +3 -0
  2. package/dist/assets/gif/gif.js.map +1 -1
  3. package/dist/assets/illustrations/illustrations.js +10 -1
  4. package/dist/assets/illustrations/illustrations.js.map +1 -1
  5. package/dist/assets/images/images.js +10 -0
  6. package/dist/assets/images/images.js.map +1 -1
  7. package/dist/assets/line-icons/icons/cue-coin.js +182 -0
  8. package/dist/assets/line-icons/icons/cue-coin.js.map +1 -0
  9. package/dist/assets/line-icons/icons/wins-common-icon.js +26 -0
  10. package/dist/assets/line-icons/icons/wins-common-icon.js.map +1 -0
  11. package/dist/assets/line-icons/icons/wins-epic-icon.js +25 -0
  12. package/dist/assets/line-icons/icons/wins-epic-icon.js.map +1 -0
  13. package/dist/assets/line-icons/icons/wins-legendary-icon.js +25 -0
  14. package/dist/assets/line-icons/icons/wins-legendary-icon.js.map +1 -0
  15. package/dist/assets/line-icons/icons/wins-mystery-icon.js +105 -0
  16. package/dist/assets/line-icons/icons/wins-mystery-icon.js.map +1 -0
  17. package/dist/assets/line-icons/icons/wins-mythic-icon.js +28 -0
  18. package/dist/assets/line-icons/icons/wins-mythic-icon.js.map +1 -0
  19. package/dist/assets/line-icons/icons/wins-rare-icon.js +28 -0
  20. package/dist/assets/line-icons/icons/wins-rare-icon.js.map +1 -0
  21. package/dist/assets/lottie/lottie.js +10 -3
  22. package/dist/assets/lottie/lottie.js.map +1 -1
  23. package/dist/constants/config.js +5 -0
  24. package/dist/constants/config.js.map +1 -0
  25. package/dist/constants/country.js +9 -0
  26. package/dist/constants/country.js.map +1 -1
  27. package/dist/features/auth/comps/auth-page-layout/auth-page-layout.js +6 -6
  28. package/dist/features/auth/comps/auth-page-layout/auth-page-layout.js.map +1 -1
  29. package/dist/features/auth/comps/linear-progress-bar/linear-progress-bar.js +4 -4
  30. package/dist/features/auth/comps/linear-progress-bar/linear-progress-bar.js.map +1 -1
  31. package/dist/features/auth/comps/otp-input/otp-input.js +19 -18
  32. package/dist/features/auth/comps/otp-input/otp-input.js.map +1 -1
  33. package/dist/features/auth/comps/pill-button/pill-button-styled.js +17 -17
  34. package/dist/features/auth/comps/pill-button/pill-button-styled.js.map +1 -1
  35. package/dist/features/auth/comps/pill-button/pill-button.js +26 -24
  36. package/dist/features/auth/comps/pill-button/pill-button.js.map +1 -1
  37. package/dist/features/auth/comps/user-list/user-item/user-item.js +32 -30
  38. package/dist/features/auth/comps/user-list/user-item/user-item.js.map +1 -1
  39. package/dist/features/auth/comps/user-list/user-list.js +20 -19
  40. package/dist/features/auth/comps/user-list/user-list.js.map +1 -1
  41. package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide-constants.js +9 -9
  42. package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide-constants.js.map +1 -1
  43. package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide-styled.js +58 -29
  44. package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide-styled.js.map +1 -1
  45. package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide.js +78 -41
  46. package/dist/features/auth/pla-signup/onboarding-guide/onboarding-guide.js.map +1 -1
  47. package/dist/features/auth/pla-signup/pla-analytics-events.js +5 -4
  48. package/dist/features/auth/pla-signup/pla-analytics-events.js.map +1 -1
  49. package/dist/features/auth/pla-signup/signup-header/signup-header.js +1 -1
  50. package/dist/features/auth/pla-signup/signup-header/signup-header.js.map +1 -1
  51. package/dist/features/auth/signup/circular-step-wrapper/circular-step-wrapper-styled.js +37 -35
  52. package/dist/features/auth/signup/circular-step-wrapper/circular-step-wrapper-styled.js.map +1 -1
  53. package/dist/features/auth/signup/circular-step-wrapper/circular-step-wrapper.js +75 -70
  54. package/dist/features/auth/signup/circular-step-wrapper/circular-step-wrapper.js.map +1 -1
  55. package/dist/features/auth/signup/custom-input-field/custom-input-field.js +55 -50
  56. package/dist/features/auth/signup/custom-input-field/custom-input-field.js.map +1 -1
  57. package/dist/features/auth/signup/custom-input-field/input-wrapper/input-wrapper.js +47 -25
  58. package/dist/features/auth/signup/custom-input-field/input-wrapper/input-wrapper.js.map +1 -1
  59. package/dist/features/auth/signup-unavailable/signup-unavailable-styled.js +16 -0
  60. package/dist/features/auth/signup-unavailable/signup-unavailable-styled.js.map +1 -0
  61. package/dist/features/auth/signup-unavailable/signup-unavailable-view.js +62 -0
  62. package/dist/features/auth/signup-unavailable/signup-unavailable-view.js.map +1 -0
  63. package/dist/features/auth/signup-unavailable/signup-unavailable.js +17 -0
  64. package/dist/features/auth/signup-unavailable/signup-unavailable.js.map +1 -0
  65. package/dist/features/chapters/lpar-chapter/block-section/sat-sheet-item/sat-sheet-summary/question-overview.js +19 -18
  66. package/dist/features/chapters/lpar-chapter/block-section/sat-sheet-item/sat-sheet-summary/question-overview.js.map +1 -1
  67. package/dist/features/chapters/lpar-chapter/block-section/sat-sheet-item/sat-sheet-summary/sat-sheet-summary-styled.js +7 -7
  68. package/dist/features/chapters/lpar-chapter/block-section/sat-sheet-item/sat-sheet-summary/sat-sheet-summary-styled.js.map +1 -1
  69. package/dist/features/chapters/lpar-chapter/block-section/sat-sheet-item/sat-sheet-summary/sat-sheet-summary.js +26 -24
  70. package/dist/features/chapters/lpar-chapter/block-section/sat-sheet-item/sat-sheet-summary/sat-sheet-summary.js.map +1 -1
  71. package/dist/features/chapters/lpar-chapter/block-section/sat-sheet-item/sat-sheet-summary/summary-module.js +15 -13
  72. package/dist/features/chapters/lpar-chapter/block-section/sat-sheet-item/sat-sheet-summary/summary-module.js.map +1 -1
  73. package/dist/features/chapters/lpar-chapter/constants/index.js.map +1 -1
  74. package/dist/features/chapters-v2/chapter-details/block-sections/block-section-view.js +130 -69
  75. package/dist/features/chapters-v2/chapter-details/block-sections/block-section-view.js.map +1 -1
  76. package/dist/features/chapters-v2/chapter-details/block-sections/block-sections.js +43 -33
  77. package/dist/features/chapters-v2/chapter-details/block-sections/block-sections.js.map +1 -1
  78. package/dist/features/chapters-v2/chapter-details/chapter-details.js +137 -95
  79. package/dist/features/chapters-v2/chapter-details/chapter-details.js.map +1 -1
  80. package/dist/features/chapters-v2/comps/node-card/node-card-styled.js +36 -31
  81. package/dist/features/chapters-v2/comps/node-card/node-card-styled.js.map +1 -1
  82. package/dist/features/chapters-v2/comps/sat-mock-test/sat-mock-test-styled.js +22 -0
  83. package/dist/features/chapters-v2/comps/sat-mock-test/sat-mock-test-styled.js.map +1 -0
  84. package/dist/features/chapters-v2/comps/sat-mock-test/sat-mock-test.js +141 -0
  85. package/dist/features/chapters-v2/comps/sat-mock-test/sat-mock-test.js.map +1 -0
  86. package/dist/features/chapters-v2/constants/block-constants.js +7 -5
  87. package/dist/features/chapters-v2/constants/block-constants.js.map +1 -1
  88. package/dist/features/chapters-v2/utils/index.js +22 -12
  89. package/dist/features/chapters-v2/utils/index.js.map +1 -1
  90. package/dist/features/chapters-v2/utils/sat-sheet-utils.js +12 -0
  91. package/dist/features/chapters-v2/utils/sat-sheet-utils.js.map +1 -0
  92. package/dist/features/circle-games/games/web-view/web-view.js +0 -1
  93. package/dist/features/circle-games/games/web-view/web-view.js.map +1 -1
  94. package/dist/features/journey/hooks/use-chapter-page-journey/use-download-block-journey.js +86 -0
  95. package/dist/features/journey/hooks/use-chapter-page-journey/use-download-block-journey.js.map +1 -0
  96. package/dist/features/journey/hooks/use-chapter-page-journey/use-download-node-journey.js +140 -0
  97. package/dist/features/journey/hooks/use-chapter-page-journey/use-download-node-journey.js.map +1 -0
  98. package/dist/features/journey/hooks/use-home-page-journey/home-page-homeworks-mock.js +8 -4
  99. package/dist/features/journey/hooks/use-home-page-journey/home-page-homeworks-mock.js.map +1 -1
  100. package/dist/features/journey/hooks/use-puzzles-journey/use-puzzle-dashboard-journey.js +23 -29
  101. package/dist/features/journey/hooks/use-puzzles-journey/use-puzzle-dashboard-journey.js.map +1 -1
  102. package/dist/features/journey/journey-id/journey-id-student.js +1 -1
  103. package/dist/features/journey/journey-id/journey-id-student.js.map +1 -1
  104. package/dist/features/journey/journey-id/journey-id-teacher.js +2 -2
  105. package/dist/features/journey/journey-id/journey-id-teacher.js.map +1 -1
  106. package/dist/features/journey/mocks/chapter-page-journey-mock-data.js +400 -0
  107. package/dist/features/journey/mocks/chapter-page-journey-mock-data.js.map +1 -1
  108. package/dist/features/milestone/constants.js +13 -10
  109. package/dist/features/milestone/constants.js.map +1 -1
  110. package/dist/features/milestone/create/comps/add-custom-chapter/add-custom-chapter.js +42 -40
  111. package/dist/features/milestone/create/comps/add-custom-chapter/add-custom-chapter.js.map +1 -1
  112. package/dist/features/milestone/create/comps/add-custom-chapter/course-catalog.js +70 -64
  113. package/dist/features/milestone/create/comps/add-custom-chapter/course-catalog.js.map +1 -1
  114. package/dist/features/milestone/create/comps/add-custom-chapter/hooks/use-catalog-helpers.js +54 -29
  115. package/dist/features/milestone/create/comps/add-custom-chapter/hooks/use-catalog-helpers.js.map +1 -1
  116. package/dist/features/milestone/create/comps/chapters-selection-step/chapter-selection-step-v2/chapter-category/chapter-category-container.js +48 -28
  117. package/dist/features/milestone/create/comps/chapters-selection-step/chapter-selection-step-v2/chapter-category/chapter-category-container.js.map +1 -1
  118. package/dist/features/milestone/create/comps/chapters-selection-step/chapters-selection-step.js +79 -76
  119. package/dist/features/milestone/create/comps/chapters-selection-step/chapters-selection-step.js.map +1 -1
  120. package/dist/features/milestone/create/comps/chapters-selection-step/utils.js +97 -94
  121. package/dist/features/milestone/create/comps/chapters-selection-step/utils.js.map +1 -1
  122. package/dist/features/milestone/create/comps/class-details-step/class-details-step.js +160 -143
  123. package/dist/features/milestone/create/comps/class-details-step/class-details-step.js.map +1 -1
  124. package/dist/features/milestone/create/comps/class-details-step/class-details-utils.js +22 -12
  125. package/dist/features/milestone/create/comps/class-details-step/class-details-utils.js.map +1 -1
  126. package/dist/features/milestone/create/comps/goal-completion-date-selector/goal-completion-date-selector.js +6 -6
  127. package/dist/features/milestone/create/comps/test-type-step/test-type-step.js +64 -59
  128. package/dist/features/milestone/create/comps/test-type-step/test-type-step.js.map +1 -1
  129. package/dist/features/milestone/create/milestone-create-container.js +17 -15
  130. package/dist/features/milestone/create/milestone-create-container.js.map +1 -1
  131. package/dist/features/milestone/create/milestone-create-helpers.js +170 -153
  132. package/dist/features/milestone/create/milestone-create-helpers.js.map +1 -1
  133. package/dist/features/milestone/create/milestone-create-styled.js +1 -1
  134. package/dist/features/milestone/create/milestone-create-styled.js.map +1 -1
  135. package/dist/features/milestone/create/milestone-create.js +19 -17
  136. package/dist/features/milestone/create/milestone-create.js.map +1 -1
  137. package/dist/features/milestone/milestone-tests/tests-creation/test-stages/test-preview/test-preview.js +19 -20
  138. package/dist/features/milestone/milestone-tests/tests-creation/test-stages/test-preview/test-preview.js.map +1 -1
  139. package/dist/features/parent-dashboard/api/get-student-profile-summary.js +9 -0
  140. package/dist/features/parent-dashboard/api/get-student-profile-summary.js.map +1 -0
  141. package/dist/features/parent-dashboard/api/parent-home.js +10 -0
  142. package/dist/features/parent-dashboard/api/parent-home.js.map +1 -0
  143. package/dist/features/parent-dashboard/comps/compact-header/compact-header.js +30 -0
  144. package/dist/features/parent-dashboard/comps/compact-header/compact-header.js.map +1 -0
  145. package/dist/features/parent-dashboard/comps/cuemath-app-features/cuemath-app-features-constants.js +25 -0
  146. package/dist/features/parent-dashboard/comps/cuemath-app-features/cuemath-app-features-constants.js.map +1 -0
  147. package/dist/features/parent-dashboard/comps/cuemath-app-features/cuemath-app-features-styled.js +15 -0
  148. package/dist/features/parent-dashboard/comps/cuemath-app-features/cuemath-app-features-styled.js.map +1 -0
  149. package/dist/features/parent-dashboard/comps/cuemath-app-features/cuemath-app-features.js +90 -0
  150. package/dist/features/parent-dashboard/comps/cuemath-app-features/cuemath-app-features.js.map +1 -0
  151. package/dist/features/parent-dashboard/comps/math-practice/math-practice-constants.js +19 -0
  152. package/dist/features/parent-dashboard/comps/math-practice/math-practice-constants.js.map +1 -0
  153. package/dist/features/parent-dashboard/comps/math-practice/math-practice-styled.js +32 -0
  154. package/dist/features/parent-dashboard/comps/math-practice/math-practice-styled.js.map +1 -0
  155. package/dist/features/parent-dashboard/comps/math-practice/math-practice.js +67 -0
  156. package/dist/features/parent-dashboard/comps/math-practice/math-practice.js.map +1 -0
  157. package/dist/features/parent-dashboard/comps/parent-dashboard-faqs/parent-dashboard-faqs-constants.js +42 -0
  158. package/dist/features/parent-dashboard/comps/parent-dashboard-faqs/parent-dashboard-faqs-constants.js.map +1 -0
  159. package/dist/features/parent-dashboard/comps/parent-dashboard-faqs/parent-dashboard-faqs.js +20 -0
  160. package/dist/features/parent-dashboard/comps/parent-dashboard-faqs/parent-dashboard-faqs.js.map +1 -0
  161. package/dist/features/parent-dashboard/comps/pla-first-session-introduction/pla-first-session-introduction-styled.js +10 -0
  162. package/dist/features/parent-dashboard/comps/pla-first-session-introduction/pla-first-session-introduction-styled.js.map +1 -0
  163. package/dist/features/parent-dashboard/comps/pla-first-session-introduction/pla-first-session-introduction.js +42 -0
  164. package/dist/features/parent-dashboard/comps/pla-first-session-introduction/pla-first-session-introduction.js.map +1 -0
  165. package/dist/features/parent-dashboard/hooks/use-parent-home-data.js +67 -0
  166. package/dist/features/parent-dashboard/hooks/use-parent-home-data.js.map +1 -0
  167. package/dist/features/parent-dashboard/hooks/use-student-profile-summary-data.js +24 -0
  168. package/dist/features/parent-dashboard/hooks/use-student-profile-summary-data.js.map +1 -0
  169. package/dist/features/parent-dashboard/hooks/use-switch-user-journey.js +71 -0
  170. package/dist/features/parent-dashboard/hooks/use-switch-user-journey.js.map +1 -0
  171. package/dist/features/parent-dashboard/modals/help-and-support/help-and-support.js +40 -0
  172. package/dist/features/parent-dashboard/modals/help-and-support/help-and-support.js.map +1 -0
  173. package/dist/features/parent-dashboard/modals/student-login-info/student-login-info.js +44 -0
  174. package/dist/features/parent-dashboard/modals/student-login-info/student-login-info.js.map +1 -0
  175. package/dist/features/parent-dashboard/modals/student-profile-summary/student-profile-summary-helpers.js +32 -0
  176. package/dist/features/parent-dashboard/modals/student-profile-summary/student-profile-summary-helpers.js.map +1 -0
  177. package/dist/features/parent-dashboard/modals/student-profile-summary/student-profile-summary-styled.js +12 -0
  178. package/dist/features/parent-dashboard/modals/student-profile-summary/student-profile-summary-styled.js.map +1 -0
  179. package/dist/features/parent-dashboard/modals/student-profile-summary/student-profile-summary.js +44 -0
  180. package/dist/features/parent-dashboard/modals/student-profile-summary/student-profile-summary.js.map +1 -0
  181. package/dist/features/parent-dashboard/modals/trial-report/trial-report-styled.js +13 -0
  182. package/dist/features/parent-dashboard/modals/trial-report/trial-report-styled.js.map +1 -0
  183. package/dist/features/parent-dashboard/modals/trial-report/trial-report.js +28 -0
  184. package/dist/features/parent-dashboard/modals/trial-report/trial-report.js.map +1 -0
  185. package/dist/features/parent-dashboard/modals/tutor-change/tutor-change-constants.js +43 -0
  186. package/dist/features/parent-dashboard/modals/tutor-change/tutor-change-constants.js.map +1 -0
  187. package/dist/features/parent-dashboard/modals/tutor-change/tutor-change-styled.js +59 -0
  188. package/dist/features/parent-dashboard/modals/tutor-change/tutor-change-styled.js.map +1 -0
  189. package/dist/features/parent-dashboard/modals/tutor-change/tutor-change.js +86 -0
  190. package/dist/features/parent-dashboard/modals/tutor-change/tutor-change.js.map +1 -0
  191. package/dist/features/parent-dashboard/parent-dashboard-constants.js +26 -0
  192. package/dist/features/parent-dashboard/parent-dashboard-constants.js.map +1 -0
  193. package/dist/features/parent-dashboard/parent-dashboard-styled.js +33 -0
  194. package/dist/features/parent-dashboard/parent-dashboard-styled.js.map +1 -0
  195. package/dist/features/parent-dashboard/parent-dashboard-types.js +6 -0
  196. package/dist/features/parent-dashboard/parent-dashboard-types.js.map +1 -0
  197. package/dist/features/parent-dashboard/parent-dashboard-view.js +215 -0
  198. package/dist/features/parent-dashboard/parent-dashboard-view.js.map +1 -0
  199. package/dist/features/parent-dashboard/parent-dashboard.js +8 -0
  200. package/dist/features/parent-dashboard/parent-dashboard.js.map +1 -0
  201. package/dist/features/sentry/constants/ignored.js +10 -6
  202. package/dist/features/sentry/constants/ignored.js.map +1 -1
  203. package/dist/features/sheets/constants/sheet.js +23 -10
  204. package/dist/features/sheets/constants/sheet.js.map +1 -1
  205. package/dist/features/sheets/utils/is-v3-worksheet.js +17 -0
  206. package/dist/features/sheets/utils/is-v3-worksheet.js.map +1 -1
  207. package/dist/features/student-details/class-details/class-details-utils.js +6 -6
  208. package/dist/features/trial-session/api/course-stream.js.map +1 -1
  209. package/dist/features/trial-session/comps/about-cuemath/about-cuemath-constants.js +1 -1
  210. package/dist/features/trial-session/comps/about-cuemath/about-cuemath-constants.js.map +1 -1
  211. package/dist/features/trial-session/comps/background-grid/background-grid-utils.js +66 -60
  212. package/dist/features/trial-session/comps/background-grid/background-grid-utils.js.map +1 -1
  213. package/dist/features/trial-session/comps/learning-plan/index.js +62 -88
  214. package/dist/features/trial-session/comps/learning-plan/index.js.map +1 -1
  215. package/dist/features/trial-session/comps/offering-information/offering-information-constants.js +12 -12
  216. package/dist/features/trial-session/comps/offering-information/offering-information-constants.js.map +1 -1
  217. package/dist/features/trial-session/comps/pla/next-steps/next-steps-constants.js +25 -0
  218. package/dist/features/trial-session/comps/pla/next-steps/next-steps-constants.js.map +1 -0
  219. package/dist/features/trial-session/comps/pla/next-steps/next-steps-styled.js +43 -0
  220. package/dist/features/trial-session/comps/pla/next-steps/next-steps-styled.js.map +1 -0
  221. package/dist/features/trial-session/comps/pla/next-steps/next-steps.js +49 -0
  222. package/dist/features/trial-session/comps/pla/next-steps/next-steps.js.map +1 -0
  223. package/dist/features/trial-session/comps/pla/session-status/hooks/use-session-countdown.js +29 -0
  224. package/dist/features/trial-session/comps/pla/session-status/hooks/use-session-countdown.js.map +1 -0
  225. package/dist/features/trial-session/comps/pla/session-status/hooks/use-session-status-config.js +132 -0
  226. package/dist/features/trial-session/comps/pla/session-status/hooks/use-session-status-config.js.map +1 -0
  227. package/dist/features/trial-session/comps/pla/session-status/session-status-constants.js +11 -0
  228. package/dist/features/trial-session/comps/pla/session-status/session-status-constants.js.map +1 -0
  229. package/dist/features/trial-session/comps/pla/session-status/session-status-helpers.js +19 -0
  230. package/dist/features/trial-session/comps/pla/session-status/session-status-helpers.js.map +1 -0
  231. package/dist/features/trial-session/comps/pla/session-status/session-status-styled.js +17 -0
  232. package/dist/features/trial-session/comps/pla/session-status/session-status-styled.js.map +1 -0
  233. package/dist/features/trial-session/comps/pla/session-status/session-status.js +127 -0
  234. package/dist/features/trial-session/comps/pla/session-status/session-status.js.map +1 -0
  235. package/dist/features/trial-session/comps/pla/session-summary/session-summary-constants.js +53 -0
  236. package/dist/features/trial-session/comps/pla/session-summary/session-summary-constants.js.map +1 -0
  237. package/dist/features/trial-session/comps/pla/session-summary/session-summary.js +53 -0
  238. package/dist/features/trial-session/comps/pla/session-summary/session-summary.js.map +1 -0
  239. package/dist/features/trial-session/comps/pla/session-summary/summary-card/summary-card-styled.js +17 -0
  240. package/dist/features/trial-session/comps/pla/session-summary/summary-card/summary-card-styled.js.map +1 -0
  241. package/dist/features/trial-session/comps/pla/session-summary/summary-card/summary-card.js +56 -0
  242. package/dist/features/trial-session/comps/pla/session-summary/summary-card/summary-card.js.map +1 -0
  243. package/dist/features/trial-session/comps/pla/upcoming-sessions/upcoming-sessions-constants.js +5 -0
  244. package/dist/features/trial-session/comps/pla/upcoming-sessions/upcoming-sessions-constants.js.map +1 -0
  245. package/dist/features/trial-session/comps/pla/upcoming-sessions/upcoming-sessions-styled.js +17 -0
  246. package/dist/features/trial-session/comps/pla/upcoming-sessions/upcoming-sessions-styled.js.map +1 -0
  247. package/dist/features/trial-session/comps/pla/upcoming-sessions/upcoming-sessions-types.js +5 -0
  248. package/dist/features/trial-session/comps/pla/upcoming-sessions/upcoming-sessions-types.js.map +1 -0
  249. package/dist/features/trial-session/comps/pla/upcoming-sessions/upcoming-sessions.js +96 -0
  250. package/dist/features/trial-session/comps/pla/upcoming-sessions/upcoming-sessions.js.map +1 -0
  251. package/dist/features/trial-session/comps/school-goals/school-goals.js +25 -24
  252. package/dist/features/trial-session/comps/school-goals/school-goals.js.map +1 -1
  253. package/dist/features/trial-session/comps/session-report/report-404/report-404.js +34 -0
  254. package/dist/features/trial-session/comps/session-report/report-404/report-404.js.map +1 -0
  255. package/dist/features/trial-session/comps/session-report/report-information/report-card.js +41 -0
  256. package/dist/features/trial-session/comps/session-report/report-information/report-card.js.map +1 -0
  257. package/dist/features/trial-session/comps/session-report/report-information/report-information-styled.js +39 -0
  258. package/dist/features/trial-session/comps/session-report/report-information/report-information-styled.js.map +1 -0
  259. package/dist/features/trial-session/comps/session-report/report-information/report-information.js +179 -0
  260. package/dist/features/trial-session/comps/session-report/report-information/report-information.js.map +1 -0
  261. package/dist/features/trial-session/comps/session-report/session-report-styled.js +6 -29
  262. package/dist/features/trial-session/comps/session-report/session-report-styled.js.map +1 -1
  263. package/dist/features/trial-session/comps/session-report/session-report.js +44 -174
  264. package/dist/features/trial-session/comps/session-report/session-report.js.map +1 -1
  265. package/dist/features/trial-session/comps/student-personalization/student-personalization-styled.js +20 -5
  266. package/dist/features/trial-session/comps/student-personalization/student-personalization-styled.js.map +1 -1
  267. package/dist/features/trial-session/comps/student-personalization/student-personalization.js +59 -126
  268. package/dist/features/trial-session/comps/student-personalization/student-personalization.js.map +1 -1
  269. package/dist/features/trial-session/comps/student-profile/constant.js +10 -0
  270. package/dist/features/trial-session/comps/student-profile/constant.js.map +1 -0
  271. package/dist/features/trial-session/comps/student-profile/student-profile-highlights/student-profile-highlights.js +53 -0
  272. package/dist/features/trial-session/comps/student-profile/student-profile-highlights/student-profile-highlights.js.map +1 -0
  273. package/dist/features/trial-session/comps/student-profile/student-profile.js +93 -46
  274. package/dist/features/trial-session/comps/student-profile/student-profile.js.map +1 -1
  275. package/dist/features/trial-session/comps/teacher-intro/teacher-profile/teacher-profile-helpers.js +12 -0
  276. package/dist/features/trial-session/comps/teacher-intro/teacher-profile/teacher-profile-helpers.js.map +1 -0
  277. package/dist/features/trial-session/comps/teacher-intro/teacher-profile/teacher-profile-styled.js +121 -42
  278. package/dist/features/trial-session/comps/teacher-intro/teacher-profile/teacher-profile-styled.js.map +1 -1
  279. package/dist/features/trial-session/comps/teacher-intro/teacher-profile/teacher-profile.js +174 -56
  280. package/dist/features/trial-session/comps/teacher-intro/teacher-profile/teacher-profile.js.map +1 -1
  281. package/dist/features/trial-session/comps/worksheet/worksheet.js +23 -23
  282. package/dist/features/trial-session/comps/worksheet/worksheet.js.map +1 -1
  283. package/dist/features/trial-session/hooks/use-trial-session-navigation.js +65 -63
  284. package/dist/features/trial-session/hooks/use-trial-session-navigation.js.map +1 -1
  285. package/dist/features/trial-session/left-panel/index.js +1 -1
  286. package/dist/features/trial-session/left-panel/index.js.map +1 -1
  287. package/dist/features/trial-session/right-panel/slide-components-map.js +32 -32
  288. package/dist/features/trial-session/right-panel/slide-components-map.js.map +1 -1
  289. package/dist/features/trial-session/trial-session-constants.js +3 -3
  290. package/dist/features/trial-session/trial-session-constants.js.map +1 -1
  291. package/dist/features/trial-session/trial-session-types.js.map +1 -1
  292. package/dist/features/ui/buttons/icon-button/icon-button.js +32 -29
  293. package/dist/features/ui/buttons/icon-button/icon-button.js.map +1 -1
  294. package/dist/features/ui/constants/z-index.js +5 -3
  295. package/dist/features/ui/constants/z-index.js.map +1 -1
  296. package/dist/features/ui/inputs/base-select-input/select-section/select-section.js +12 -11
  297. package/dist/features/ui/inputs/base-select-input/select-section/select-section.js.map +1 -1
  298. package/dist/features/ui/inputs/checkbox-input-list/checkbox-input-list-styled.js +2 -7
  299. package/dist/features/ui/inputs/checkbox-input-list/checkbox-input-list-styled.js.map +1 -1
  300. package/dist/features/ui/inputs/checkbox-input-list/checkbox-input-list.js +29 -27
  301. package/dist/features/ui/inputs/checkbox-input-list/checkbox-input-list.js.map +1 -1
  302. package/dist/features/ui/modals/modal.js +30 -28
  303. package/dist/features/ui/modals/modal.js.map +1 -1
  304. package/dist/features/wins-dashboard/belts-elements-stickers/belts-elements-stickers.js +109 -0
  305. package/dist/features/wins-dashboard/belts-elements-stickers/belts-elements-stickers.js.map +1 -0
  306. package/dist/features/wins-dashboard/belts-elements-stickers/belts.js +95 -0
  307. package/dist/features/wins-dashboard/belts-elements-stickers/belts.js.map +1 -0
  308. package/dist/features/wins-dashboard/belts-elements-stickers/elements.js +184 -0
  309. package/dist/features/wins-dashboard/belts-elements-stickers/elements.js.map +1 -0
  310. package/dist/features/wins-dashboard/belts-elements-stickers/progress-bar-horizontal.js +36 -0
  311. package/dist/features/wins-dashboard/belts-elements-stickers/progress-bar-horizontal.js.map +1 -0
  312. package/dist/features/wins-dashboard/belts-elements-stickers/reward-elements.js +83 -0
  313. package/dist/features/wins-dashboard/belts-elements-stickers/reward-elements.js.map +1 -0
  314. package/dist/features/wins-dashboard/constants.js +161 -0
  315. package/dist/features/wins-dashboard/constants.js.map +1 -0
  316. package/dist/features/wins-dashboard/header/wins-header.js +95 -0
  317. package/dist/features/wins-dashboard/header/wins-header.js.map +1 -0
  318. package/dist/features/wins-dashboard/student-badges/animated-tabbar.js +66 -0
  319. package/dist/features/wins-dashboard/student-badges/animated-tabbar.js.map +1 -0
  320. package/dist/features/wins-dashboard/student-badges/hooks/use-student-badge-list-hook.js +135 -0
  321. package/dist/features/wins-dashboard/student-badges/hooks/use-student-badge-list-hook.js.map +1 -0
  322. package/dist/features/wins-dashboard/student-badges/student-badge.js +168 -0
  323. package/dist/features/wins-dashboard/student-badges/student-badge.js.map +1 -0
  324. package/dist/features/wins-dashboard/student-badges/student-badges-lists.js +137 -0
  325. package/dist/features/wins-dashboard/student-badges/student-badges-lists.js.map +1 -0
  326. package/dist/features/worksheet/worksheet/worksheet-action-bar/worksheet-action-bar.js +86 -90
  327. package/dist/features/worksheet/worksheet/worksheet-action-bar/worksheet-action-bar.js.map +1 -1
  328. package/dist/features/worksheet/worksheet/worksheet-behavior-helper.js +147 -0
  329. package/dist/features/worksheet/worksheet/worksheet-behavior-helper.js.map +1 -0
  330. package/dist/features/worksheet/worksheet/worksheet-container.js +62 -42
  331. package/dist/features/worksheet/worksheet/worksheet-container.js.map +1 -1
  332. package/dist/features/worksheet/worksheet/worksheet-question/worksheet-question.js +197 -199
  333. package/dist/features/worksheet/worksheet/worksheet-question/worksheet-question.js.map +1 -1
  334. package/dist/features/worksheet/worksheet/worksheet-questions-controller/worksheet-questions-controller.js +228 -300
  335. package/dist/features/worksheet/worksheet/worksheet-questions-controller/worksheet-questions-controller.js.map +1 -1
  336. package/dist/features/worksheet/worksheet/worksheet-styled.js +34 -34
  337. package/dist/features/worksheet/worksheet/worksheet-styled.js.map +1 -1
  338. package/dist/features/worksheet/worksheet/worksheet-types.js.map +1 -1
  339. package/dist/features/worksheet/worksheet/worksheet.js +206 -215
  340. package/dist/features/worksheet/worksheet/worksheet.js.map +1 -1
  341. package/dist/features/worksheet/worksheet-preview/dynamic-worksheet-preview/dynamic-worksheet-preview.js +33 -33
  342. package/dist/features/worksheet/worksheet-preview/dynamic-worksheet-preview/dynamic-worksheet-preview.js.map +1 -1
  343. package/dist/features/worksheet/worksheet-preview/hooks/use-worksheet-layout.js +30 -28
  344. package/dist/features/worksheet/worksheet-preview/hooks/use-worksheet-layout.js.map +1 -1
  345. package/dist/features/worksheet/worksheet-preview/worksheet-preview-view.js +69 -73
  346. package/dist/features/worksheet/worksheet-preview/worksheet-preview-view.js.map +1 -1
  347. package/dist/features/worksheet/worksheet-preview/worksheet-preview.js +30 -79
  348. package/dist/features/worksheet/worksheet-preview/worksheet-preview.js.map +1 -1
  349. package/dist/index.d.ts +473 -45
  350. package/dist/index.js +695 -627
  351. package/dist/index.js.map +1 -1
  352. package/dist/node_modules/date-fns/_lib/getRoundingMethod.js +10 -0
  353. package/dist/node_modules/date-fns/_lib/getRoundingMethod.js.map +1 -0
  354. package/dist/node_modules/date-fns/differenceInMilliseconds.js +9 -0
  355. package/dist/node_modules/date-fns/differenceInMilliseconds.js.map +1 -0
  356. package/dist/node_modules/date-fns/differenceInSeconds.js +11 -0
  357. package/dist/node_modules/date-fns/differenceInSeconds.js.map +1 -0
  358. package/dist/node_modules/date-fns/fromUnixTime.js +9 -0
  359. package/dist/node_modules/date-fns/fromUnixTime.js.map +1 -0
  360. package/dist/static/awesome.4239f583.json +1 -0
  361. package/dist/static/black-belt.81b3ebf9.png +0 -0
  362. package/dist/static/blue-belt.508a1b4b.png +0 -0
  363. package/dist/static/{book-checked-green.c275dbd9.svg → book-checked-green.0436b91e.svg} +1 -1
  364. package/dist/static/brown-belt.09bb7e93.png +0 -0
  365. package/dist/static/clapping-hands.17e7ecf0.json +1 -0
  366. package/dist/static/common.9e8ceef1.svg +1 -0
  367. package/dist/static/community-bulb-yellow-2.f89c30f9.svg +1 -0
  368. package/dist/static/cool.cd6921bb.json +1 -0
  369. package/dist/static/epic.37a0265a.svg +1 -0
  370. package/dist/static/error-responsive.9916ff66.json +1 -0
  371. package/dist/static/error.dd744fa5.json +1 -0
  372. package/dist/static/green-belt.5501296f.png +0 -0
  373. package/dist/static/learning-puzzle-bot.6fe93cf6.svg +1 -0
  374. package/dist/static/legendary.f15d09ca.svg +1 -0
  375. package/dist/static/like-button.281a2618.json +1 -0
  376. package/dist/static/mastered-badge.91d25e92.png +0 -0
  377. package/dist/static/mystery.81ada5fb.svg +1 -0
  378. package/dist/static/mythic.58ba0ae0.svg +1 -0
  379. package/dist/static/orange-belt.1fefcc8c.png +0 -0
  380. package/dist/static/personalization.7a6c33e8.svg +1 -0
  381. package/dist/static/personalized-session.b4fd7df8.gif +0 -0
  382. package/dist/static/purple-belt.e15611b4.png +0 -0
  383. package/dist/static/rare.1ffaa311.svg +1 -0
  384. package/dist/static/red-belt.11f841d9.png +0 -0
  385. package/dist/static/regular-practice.b15f24d9.gif +0 -0
  386. package/dist/static/star-strike-emoji.c0b31028.json +1 -0
  387. package/dist/static/stepup.321df6ed.gif +0 -0
  388. package/dist/static/trophy.5ef1853a.json +1 -0
  389. package/dist/static/username-responsive.787b5515.json +1 -0
  390. package/dist/static/username.2c755605.json +1 -0
  391. package/dist/static/white-belt.ea93103e.png +0 -0
  392. package/dist/static/yellow-belt.0c47b8cc.png +0 -0
  393. package/package.json +1 -1
  394. package/dist/features/trial-session/comps/session-report/report-card.js +0 -26
  395. package/dist/features/trial-session/comps/session-report/report-card.js.map +0 -1
  396. package/dist/features/worksheet/worksheet/hooks/use-worksheet-journey.js +0 -28
  397. package/dist/features/worksheet/worksheet/hooks/use-worksheet-journey.js.map +0 -1
  398. package/dist/static/error.cbe1ddde.json +0 -1
  399. package/dist/static/username.9e034d51.json +0 -1
@@ -1,33 +1,35 @@
1
1
  import { jsx as r } from "react/jsx-runtime";
2
- import { useMemo as g, useCallback as I } from "react";
3
- import L from "../../arrow-tooltip/arrow-tooltip.js";
4
- import O from "../checkbox-input/checkbox-input.js";
5
- import { CheckboxInputListWrapper as v, CheckboxOptionWrapper as A } from "./checkbox-input-list-styled.js";
6
- const $ = (h) => {
2
+ import { useMemo as $, useCallback as w } from "react";
3
+ import I from "../../arrow-tooltip/arrow-tooltip.js";
4
+ import O from "../../layout/flex-view.js";
5
+ import v from "../checkbox-input/checkbox-input.js";
6
+ import { CheckboxOptionWrapper as A } from "./checkbox-input-list-styled.js";
7
+ const L = (a) => {
7
8
  const {
8
- size: a,
9
+ size: h,
9
10
  value: o,
10
11
  options: d,
11
- disabled: s,
12
+ disabled: l,
12
13
  renderAs: u,
13
- numColumns: C,
14
- indeterminate: f,
15
- visibleOnCheck: x,
14
+ numColumns: f,
15
+ optionFlexGap: x,
16
+ indeterminate: C,
17
+ visibleOnCheck: b,
16
18
  maximumSelection: e,
17
19
  onChange: i
18
- } = h, c = g(
20
+ } = a, s = $(
19
21
  () => !!(e && e > 1 && o.length >= e),
20
22
  [e, o.length]
21
- ), b = I(
23
+ ), k = w(
22
24
  (t, n) => {
23
- n ? e === 1 ? i([t]) : (!c || !e) && i([...o, t]) : i(o.filter((l) => l !== t));
25
+ n ? e === 1 ? i([t]) : (!s || !e) && i([...o, t]) : i(o.filter((p) => p !== t));
24
26
  },
25
- [e, i, c, o]
27
+ [e, i, s, o]
26
28
  );
27
- return /* @__PURE__ */ r(v, { children: d.map((t) => {
28
- const { id: n, label: l } = t, p = o.includes(n), m = c && !p, k = (s == null ? void 0 : s.includes(n)) || m;
29
- return /* @__PURE__ */ r(A, { $numColumns: C ?? 1, children: /* @__PURE__ */ r(
30
- L,
29
+ return /* @__PURE__ */ r(O, { $flexDirection: "row", $flexGap: x, $flexWrap: !0, children: d.map((t) => {
30
+ const { id: n, label: p } = t, c = o.includes(n), m = s && !c, g = (l == null ? void 0 : l.includes(n)) || m;
31
+ return /* @__PURE__ */ r(A, { $numColumns: f ?? 1, children: /* @__PURE__ */ r(
32
+ I,
31
33
  {
32
34
  renderAs: "primary",
33
35
  position: "top",
@@ -35,23 +37,23 @@ const $ = (h) => {
35
37
  hidden: !m,
36
38
  zIndex: 2,
37
39
  children: /* @__PURE__ */ r(
38
- O,
40
+ v,
39
41
  {
40
42
  value: n,
41
- size: a,
42
- label: l,
43
- checked: p,
43
+ size: h,
44
+ label: p,
45
+ checked: c,
44
46
  renderAs: u,
45
- disabled: k,
46
- onChange: b,
47
- indeterminate: f,
48
- visibleOnCheck: x
47
+ disabled: g,
48
+ onChange: k,
49
+ indeterminate: C,
50
+ visibleOnCheck: b
49
51
  }
50
52
  )
51
53
  }
52
54
  ) }, n);
53
55
  }) });
54
- }, W = $;
56
+ }, W = L;
55
57
  export {
56
58
  W as default
57
59
  };
@@ -1 +1 @@
1
- {"version":3,"file":"checkbox-input-list.js","sources":["../../../../../src/features/ui/inputs/checkbox-input-list/checkbox-input-list.tsx"],"sourcesContent":["import type { ICheckboxInputProps } from './checkbox-input-list-types';\n\nimport { useCallback, useMemo } from 'react';\n\nimport ArrowTooltip from '../../arrow-tooltip/arrow-tooltip';\nimport CheckboxOption from '../checkbox-input/checkbox-input';\nimport * as Styled from './checkbox-input-list-styled';\n\nconst CheckboxInputList = <IDType extends string | number>(props: ICheckboxInputProps<IDType>) => {\n const {\n size,\n value,\n options,\n disabled,\n renderAs,\n numColumns,\n indeterminate,\n visibleOnCheck,\n maximumSelection,\n onChange,\n } = props;\n\n const reachedMaxLength = useMemo(\n () => !!(maximumSelection && maximumSelection > 1 && value.length >= maximumSelection),\n [maximumSelection, value.length],\n );\n\n const handleOnChange = useCallback(\n (selectedValue: IDType, selected: boolean) => {\n if (!selected) {\n onChange(value.filter(val => val !== selectedValue));\n } else {\n if (maximumSelection === 1) {\n onChange([selectedValue]);\n } else if (!reachedMaxLength || !maximumSelection) {\n onChange([...value, selectedValue]);\n }\n }\n },\n [maximumSelection, onChange, reachedMaxLength, value],\n );\n\n return (\n <Styled.CheckboxInputListWrapper>\n {options.map(option => {\n const { id, label } = option;\n\n const checked = value.includes(id);\n const showTooltip = reachedMaxLength && !checked;\n const disableCheck = disabled?.includes(id) || showTooltip;\n\n return (\n <Styled.CheckboxOptionWrapper key={id} $numColumns={numColumns ?? 1}>\n <ArrowTooltip\n renderAs=\"primary\"\n position=\"top\"\n tooltipItem={`${maximumSelection} options already selected`}\n hidden={!showTooltip}\n zIndex={2}\n >\n <CheckboxOption<IDType>\n value={id}\n size={size}\n label={label}\n checked={checked}\n renderAs={renderAs}\n disabled={disableCheck}\n onChange={handleOnChange}\n indeterminate={indeterminate} //* Took this name from Mui.\n visibleOnCheck={visibleOnCheck}\n />\n </ArrowTooltip>\n </Styled.CheckboxOptionWrapper>\n );\n })}\n </Styled.CheckboxInputListWrapper>\n );\n};\n\nexport default CheckboxInputList;\n"],"names":["CheckboxInputList","props","size","value","options","disabled","renderAs","numColumns","indeterminate","visibleOnCheck","maximumSelection","onChange","reachedMaxLength","useMemo","handleOnChange","useCallback","selectedValue","selected","val","Styled.CheckboxInputListWrapper","option","id","label","checked","showTooltip","disableCheck","Styled.CheckboxOptionWrapper","jsx","ArrowTooltip","CheckboxOption","CheckboxInputList$1"],"mappings":";;;;;AAQA,MAAMA,IAAoB,CAAiCC,MAAuC;AAC1F,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UAAUmB;AAAA,YACV,UAAUX;AAAA,YACV,eAAAN;AAAA,YACA,gBAAAC;AAAA,UAAA;AAAA,QACF;AAAA,MAAA;AAAA,IAAA,KAlB+BY,CAoBnC;AAAA,EAEH,CAAA,EACH,CAAA;AAEJ,GAEAS,IAAe9B;"}
1
+ {"version":3,"file":"checkbox-input-list.js","sources":["../../../../../src/features/ui/inputs/checkbox-input-list/checkbox-input-list.tsx"],"sourcesContent":["import type { ICheckboxInputProps } from './checkbox-input-list-types';\n\nimport { useCallback, useMemo } from 'react';\n\nimport ArrowTooltip from '../../arrow-tooltip/arrow-tooltip';\nimport FlexView from '../../layout/flex-view';\nimport CheckboxOption from '../checkbox-input/checkbox-input';\nimport * as Styled from './checkbox-input-list-styled';\n\nconst CheckboxInputList = <IDType extends string | number>(props: ICheckboxInputProps<IDType>) => {\n const {\n size,\n value,\n options,\n disabled,\n renderAs,\n numColumns,\n optionFlexGap,\n indeterminate,\n visibleOnCheck,\n maximumSelection,\n onChange,\n } = props;\n\n const reachedMaxLength = useMemo(\n () => !!(maximumSelection && maximumSelection > 1 && value.length >= maximumSelection),\n [maximumSelection, value.length],\n );\n\n const handleOnChange = useCallback(\n (selectedValue: IDType, selected: boolean) => {\n if (!selected) {\n onChange(value.filter(val => val !== selectedValue));\n } else {\n if (maximumSelection === 1) {\n onChange([selectedValue]);\n } else if (!reachedMaxLength || !maximumSelection) {\n onChange([...value, selectedValue]);\n }\n }\n },\n [maximumSelection, onChange, reachedMaxLength, value],\n );\n\n return (\n <FlexView $flexDirection=\"row\" $flexGap={optionFlexGap} $flexWrap>\n {options.map(option => {\n const { id, label } = option;\n\n const checked = value.includes(id);\n const showTooltip = reachedMaxLength && !checked;\n const disableCheck = disabled?.includes(id) || showTooltip;\n\n return (\n <Styled.CheckboxOptionWrapper key={id} $numColumns={numColumns ?? 1}>\n <ArrowTooltip\n renderAs=\"primary\"\n position=\"top\"\n tooltipItem={`${maximumSelection} options already selected`}\n hidden={!showTooltip}\n zIndex={2}\n >\n <CheckboxOption<IDType>\n value={id}\n size={size}\n label={label}\n checked={checked}\n renderAs={renderAs}\n disabled={disableCheck}\n onChange={handleOnChange}\n indeterminate={indeterminate} //* Took this name from Mui.\n visibleOnCheck={visibleOnCheck}\n />\n </ArrowTooltip>\n </Styled.CheckboxOptionWrapper>\n );\n })}\n </FlexView>\n );\n};\n\nexport default CheckboxInputList;\n"],"names":["CheckboxInputList","props","size","value","options","disabled","renderAs","numColumns","optionFlexGap","indeterminate","visibleOnCheck","maximumSelection","onChange","reachedMaxLength","useMemo","handleOnChange","useCallback","selectedValue","selected","val","jsx","FlexView","option","id","label","checked","showTooltip","disableCheck","Styled.CheckboxOptionWrapper","ArrowTooltip","CheckboxOption","CheckboxInputList$1"],"mappings":";;;;;;AASA,MAAMA,IAAoB,CAAiCC,MAAuC;AAC1F,QAAA;AAAA,IACJ,MAAAC;AAAA,IACA,OAAAC;AAAA,IACA,SAAAC;AAAA,IACA,UAAAC;AAAA,IACA,UAAAC;AAAA,IACA,YAAAC;AAAA,IACA,eAAAC;AAAA,IACA,eAAAC;AAAA,IACA,gBAAAC;AAAA,IACA,kBAAAC;AAAA,IACA,UAAAC;AAAA,EACE,IAAAX,GAEEY,IAAmBC;AAAA,IACvB,MAAM,CAAC,EAAEH,KAAoBA,IAAmB,KAAKR,EAAM,UAAUQ;AAAA,IACrE,CAACA,GAAkBR,EAAM,MAAM;AAAA,EAAA,GAG3BY,IAAiBC;AAAA,IACrB,CAACC,GAAuBC,MAAsB;AAC5C,MAAKA,IAGCP,MAAqB,IACdC,EAAA,CAACK,CAAa,CAAC,KACf,CAACJ,KAAoB,CAACF,MAC/BC,EAAS,CAAC,GAAGT,GAAOc,CAAa,CAAC,IALpCL,EAAST,EAAM,OAAO,CAAOgB,MAAAA,MAAQF,CAAa,CAAC;AAAA,IAQvD;AAAA,IACA,CAACN,GAAkBC,GAAUC,GAAkBV,CAAK;AAAA,EAAA;AAIpD,SAAA,gBAAAiB,EAACC,GAAS,EAAA,gBAAe,OAAM,UAAUb,GAAe,WAAS,IAC9D,UAAQJ,EAAA,IAAI,CAAUkB,MAAA;AACf,UAAA,EAAE,IAAAC,GAAI,OAAAC,EAAU,IAAAF,GAEhBG,IAAUtB,EAAM,SAASoB,CAAE,GAC3BG,IAAcb,KAAoB,CAACY,GACnCE,KAAetB,KAAA,gBAAAA,EAAU,SAASkB,OAAOG;AAE/C,6BACGE,GAAA,EAAsC,aAAarB,KAAc,GAChE,UAAA,gBAAAa;AAAA,MAACS;AAAA,MAAA;AAAA,QACC,UAAS;AAAA,QACT,UAAS;AAAA,QACT,aAAa,GAAGlB,CAAgB;AAAA,QAChC,QAAQ,CAACe;AAAA,QACT,QAAQ;AAAA,QAER,UAAA,gBAAAN;AAAA,UAACU;AAAA,UAAA;AAAA,YACC,OAAOP;AAAA,YACP,MAAArB;AAAA,YACA,OAAAsB;AAAA,YACA,SAAAC;AAAA,YACA,UAAAnB;AAAA,YACA,UAAUqB;AAAA,YACV,UAAUZ;AAAA,YACV,eAAAN;AAAA,YACA,gBAAAC;AAAA,UAAA;AAAA,QACF;AAAA,MAAA;AAAA,IAAA,KAlB+Ba,CAoBnC;AAAA,EAEH,CAAA,EACH,CAAA;AAEJ,GAEAQ,IAAe/B;"}
@@ -1,55 +1,57 @@
1
- import { jsx as r, jsxs as f } from "react/jsx-runtime";
2
- import { captureException as u } from "@sentry/browser";
3
- import { memo as $, useCallback as g, Suspense as n } from "react";
1
+ import { jsx as o, jsxs as f } from "react/jsx-runtime";
2
+ import { captureException as E } from "@sentry/browser";
3
+ import { memo as v, useCallback as b, Suspense as n } from "react";
4
4
  import { ErrorBoundary as a } from "react-error-boundary";
5
- import E from "../../../assets/line-icons/icons/cross.js";
5
+ import { useTheme as x } from "styled-components";
6
+ import B from "../../../assets/line-icons/icons/cross.js";
6
7
  import h from "../error/error.js";
7
- import M from "../buttons/clickable/clickable.js";
8
- import x from "../layout/flex-view.js";
8
+ import S from "../buttons/clickable/clickable.js";
9
+ import W from "../layout/flex-view.js";
9
10
  import c from "../loader/app-loader/app-loader.js";
10
- import { ModalContainer as d, BottomSheetModal as v, ModalLoaderWrapper as C, SpotlightModal as B, BaseModal as S, CloseButtonContainer as W, BaseModalContent as w } from "./modal-styled.js";
11
- const q = $(({ modal: b, isClosing: o = !1, onClose: m }) => {
12
- const { renderAs: s, element: e, modalWidth: l, isDismissable: p } = b, i = g((t) => {
13
- u(t);
14
- }, []), k = g((t) => {
15
- t.stopPropagation();
11
+ import { EDeviceType as w } from "../theme/constants.js";
12
+ import { ModalContainer as d, BottomSheetModal as y, ModalLoaderWrapper as g, SpotlightModal as A, BaseModal as L, CloseButtonContainer as j, BaseModalContent as D } from "./modal-styled.js";
13
+ const N = v(({ modal: u, isClosing: r = !1, onClose: m }) => {
14
+ const { device: C } = x(), k = C <= w.MOBILE, { renderAs: s, element: e, modalWidth: i, isDismissable: p, renderOnMobileAs: M } = u, t = b((l) => {
15
+ E(l);
16
+ }, []), $ = b((l) => {
17
+ l.stopPropagation();
16
18
  }, []);
17
- return s === "bottom-sheet" ? /* @__PURE__ */ r(d, { $isClosing: o, onClick: p ? m : () => null, children: /* @__PURE__ */ r(v, { $isClosing: o, onClick: k, children: /* @__PURE__ */ r(
19
+ return s === "bottom-sheet" || k && M === "bottom-sheet" ? /* @__PURE__ */ o(d, { $isClosing: r, onClick: p ? m : () => null, children: /* @__PURE__ */ o(y, { $isClosing: r, onClick: $, children: /* @__PURE__ */ o(
18
20
  a,
19
21
  {
20
- fallback: /* @__PURE__ */ r(x, { $gap: 24, children: /* @__PURE__ */ r(h, { height: "100%" }) }),
21
- onError: i,
22
- children: /* @__PURE__ */ r(n, { fallback: /* @__PURE__ */ r(c, { height: "50vh" }), children: e })
22
+ fallback: /* @__PURE__ */ o(W, { $gap: 24, children: /* @__PURE__ */ o(h, { height: "100%" }) }),
23
+ onError: t,
24
+ children: /* @__PURE__ */ o(n, { fallback: /* @__PURE__ */ o(c, { height: "50vh" }), children: e })
23
25
  }
24
- ) }) }) : s === "spotlight" ? /* @__PURE__ */ r(d, { $isClosing: o, children: /* @__PURE__ */ r(
26
+ ) }) }) : s === "spotlight" ? /* @__PURE__ */ o(d, { $isClosing: r, children: /* @__PURE__ */ o(
25
27
  a,
26
28
  {
27
- fallback: /* @__PURE__ */ r(C, { children: /* @__PURE__ */ r(h, { height: "100vh" }) }),
28
- onError: i,
29
+ fallback: /* @__PURE__ */ o(g, { children: /* @__PURE__ */ o(h, { height: "100vh" }) }),
30
+ onError: t,
29
31
  children: /* @__PURE__ */ f(
30
32
  n,
31
33
  {
32
- fallback: /* @__PURE__ */ r(C, { children: /* @__PURE__ */ r(c, { height: "100vh" }) }),
34
+ fallback: /* @__PURE__ */ o(g, { children: /* @__PURE__ */ o(c, { height: "100vh" }) }),
33
35
  children: [
34
- /* @__PURE__ */ r(B, { $isClosing: o }),
36
+ /* @__PURE__ */ o(A, { $isClosing: r }),
35
37
  e
36
38
  ]
37
39
  }
38
40
  )
39
41
  }
40
- ) }) : /* @__PURE__ */ r(d, { $isClosing: o, children: /* @__PURE__ */ f(S, { $isClosing: o, $width: l, children: [
41
- p !== !1 && /* @__PURE__ */ r(W, { $modalWidth: l, children: /* @__PURE__ */ r(M, { label: "Close", onClick: m, children: /* @__PURE__ */ r(E, { width: 40, height: 40 }) }) }),
42
- /* @__PURE__ */ r(w, { $modalWidth: l, children: /* @__PURE__ */ r(
42
+ ) }) : /* @__PURE__ */ o(d, { $isClosing: r, children: /* @__PURE__ */ f(L, { $isClosing: r, $width: i, children: [
43
+ p !== !1 && /* @__PURE__ */ o(j, { $modalWidth: i, children: /* @__PURE__ */ o(S, { label: "Close", onClick: m, children: /* @__PURE__ */ o(B, { width: 40, height: 40 }) }) }),
44
+ /* @__PURE__ */ o(D, { $modalWidth: i, children: /* @__PURE__ */ o(
43
45
  a,
44
46
  {
45
- fallback: /* @__PURE__ */ r(h, { height: "50vh", size: "compact" }),
46
- onError: i,
47
- children: /* @__PURE__ */ r(n, { fallback: /* @__PURE__ */ r(c, { height: "50vh" }), children: e })
47
+ fallback: /* @__PURE__ */ o(h, { height: "50vh", size: "compact" }),
48
+ onError: t,
49
+ children: /* @__PURE__ */ o(n, { fallback: /* @__PURE__ */ o(c, { height: "50vh" }), children: e })
48
50
  }
49
51
  ) })
50
52
  ] }) });
51
53
  });
52
54
  export {
53
- q as default
55
+ N as default
54
56
  };
55
57
  //# sourceMappingURL=modal.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"modal.js","sources":["../../../../src/features/ui/modals/modal.tsx"],"sourcesContent":["import type { IModalProps } from './modal-types';\nimport type { FC } from 'react';\n\nimport { captureException } from '@sentry/browser';\nimport { memo, Suspense, useCallback } from 'react';\nimport { ErrorBoundary } from 'react-error-boundary';\n\nimport CrossIcon from '../../../assets/line-icons/icons/cross';\nimport Error from '../../ui/error/error';\nimport Clickable from '../buttons/clickable/clickable';\nimport FlexView from '../layout/flex-view';\nimport AppLoader from '../loader/app-loader/app-loader';\nimport * as Styled from './modal-styled';\n\n/**\n * Modal component that renders modal content with close button\n * Handles animation state for entry and exit transitions\n */\nconst Modal: FC<IModalProps> = memo(({ modal, isClosing = false, onClose }) => {\n const { renderAs, element, modalWidth, isDismissable } = modal;\n\n const sentryCaptureException = useCallback((error: Error) => {\n captureException(error);\n }, []);\n\n const handleStopPropagation = useCallback((e: React.MouseEvent) => {\n e.stopPropagation();\n }, []);\n\n if (renderAs === 'bottom-sheet') {\n return (\n <Styled.ModalContainer $isClosing={isClosing} onClick={isDismissable ? onClose : () => null}>\n <Styled.BottomSheetModal $isClosing={isClosing} onClick={handleStopPropagation}>\n <ErrorBoundary\n fallback={\n <FlexView $gap={24}>\n <Error height=\"100%\" />\n </FlexView>\n }\n onError={sentryCaptureException}\n >\n <Suspense fallback={<AppLoader height=\"50vh\" />}>{element}</Suspense>\n </ErrorBoundary>\n </Styled.BottomSheetModal>\n </Styled.ModalContainer>\n );\n }\n\n if (renderAs === 'spotlight') {\n return (\n <Styled.ModalContainer $isClosing={isClosing}>\n <ErrorBoundary\n fallback={\n <Styled.ModalLoaderWrapper>\n <Error height=\"100vh\" />\n </Styled.ModalLoaderWrapper>\n }\n onError={sentryCaptureException}\n >\n <Suspense\n fallback={\n <Styled.ModalLoaderWrapper>\n <AppLoader height=\"100vh\" />\n </Styled.ModalLoaderWrapper>\n }\n >\n <Styled.SpotlightModal $isClosing={isClosing} />\n {element}\n </Suspense>\n </ErrorBoundary>\n </Styled.ModalContainer>\n );\n }\n\n return (\n <Styled.ModalContainer $isClosing={isClosing}>\n <Styled.BaseModal $isClosing={isClosing} $width={modalWidth}>\n {isDismissable !== false && (\n <Styled.CloseButtonContainer $modalWidth={modalWidth}>\n <Clickable label=\"Close\" onClick={onClose}>\n <CrossIcon width={40} height={40} />\n </Clickable>\n </Styled.CloseButtonContainer>\n )}\n <Styled.BaseModalContent $modalWidth={modalWidth}>\n <ErrorBoundary\n fallback={<Error height=\"50vh\" size=\"compact\" />}\n onError={sentryCaptureException}\n >\n <Suspense fallback={<AppLoader height=\"50vh\" />}>{element}</Suspense>\n </ErrorBoundary>\n </Styled.BaseModalContent>\n </Styled.BaseModal>\n </Styled.ModalContainer>\n );\n});\n\nexport default Modal;\n"],"names":["Modal","memo","modal","isClosing","onClose","renderAs","element","modalWidth","isDismissable","sentryCaptureException","useCallback","error","captureException","handleStopPropagation","e","Styled.ModalContainer","Styled.BottomSheetModal","jsx","ErrorBoundary","FlexView","Error","Suspense","AppLoader","Styled.ModalLoaderWrapper","jsxs","Styled.SpotlightModal","Styled.BaseModal","Styled.CloseButtonContainer","Clickable","CrossIcon","Styled.BaseModalContent"],"mappings":";;;;;;;;;;AAkBM,MAAAA,IAAyBC,EAAK,CAAC,EAAE,OAAAC,GAAO,WAAAC,IAAY,IAAO,SAAAC,QAAc;AAC7E,QAAM,EAAE,UAAAC,GAAU,SAAAC,GAAS,YAAAC,GAAY,eAAAC,MAAkBN,GAEnDO,IAAyBC,EAAY,CAACC,MAAiB;AAC3D,IAAAC,EAA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C,MAAA,wBAChBmB,GAAA,EAA4B,aAAapB,GACxC,4BAACqB,GAAU,EAAA,OAAM,SAAQ,SAASxB,GAChC,4BAACyB,GAAU,EAAA,OAAO,IAAI,QAAQ,IAAI,GACpC,EACF,CAAA;AAAA,IAED,gBAAAZ,EAAAa,GAAA,EAAwB,aAAavB,GACpC,UAAA,gBAAAU;AAAA,MAACC;AAAA,MAAA;AAAA,QACC,UAAW,gBAAAD,EAAAG,GAAA,EAAM,QAAO,QAAO,MAAK,WAAU;AAAA,QAC9C,SAASX;AAAA,QAET,UAAA,gBAAAQ,EAACI,KAAS,UAAU,gBAAAJ,EAACK,KAAU,QAAO,OAAO,CAAA,GAAK,UAAQhB,EAAA,CAAA;AAAA,MAAA;AAAA,IAAA,GAE9D;AAAA,EAAA,EACF,CAAA,EACF,CAAA;AAEJ,CAAC;"}
1
+ {"version":3,"file":"modal.js","sources":["../../../../src/features/ui/modals/modal.tsx"],"sourcesContent":["import type { IModalProps } from './modal-types';\nimport type { FC } from 'react';\n\nimport { captureException } from '@sentry/browser';\nimport { memo, Suspense, useCallback } from 'react';\nimport { ErrorBoundary } from 'react-error-boundary';\nimport { useTheme } from 'styled-components';\n\nimport CrossIcon from '../../../assets/line-icons/icons/cross';\nimport Error from '../../ui/error/error';\nimport Clickable from '../buttons/clickable/clickable';\nimport FlexView from '../layout/flex-view';\nimport AppLoader from '../loader/app-loader/app-loader';\nimport { EDeviceType } from '../theme/constants';\nimport * as Styled from './modal-styled';\n\n/**\n * Modal component that renders modal content with close button\n * Handles animation state for entry and exit transitions\n */\nconst Modal: FC<IModalProps> = memo(({ modal, isClosing = false, onClose }) => {\n const { device } = useTheme();\n const isMobile = device <= EDeviceType.MOBILE;\n const { renderAs, element, modalWidth, isDismissable, renderOnMobileAs } = modal;\n\n const sentryCaptureException = useCallback((error: Error) => {\n captureException(error);\n }, []);\n\n const handleStopPropagation = useCallback((e: React.MouseEvent) => {\n e.stopPropagation();\n }, []);\n\n if (renderAs === 'bottom-sheet' || (isMobile && renderOnMobileAs === 'bottom-sheet')) {\n return (\n <Styled.ModalContainer $isClosing={isClosing} onClick={isDismissable ? onClose : () => null}>\n <Styled.BottomSheetModal $isClosing={isClosing} onClick={handleStopPropagation}>\n <ErrorBoundary\n fallback={\n <FlexView $gap={24}>\n <Error height=\"100%\" />\n </FlexView>\n }\n onError={sentryCaptureException}\n >\n <Suspense fallback={<AppLoader height=\"50vh\" />}>{element}</Suspense>\n </ErrorBoundary>\n </Styled.BottomSheetModal>\n </Styled.ModalContainer>\n );\n }\n\n if (renderAs === 'spotlight') {\n return (\n <Styled.ModalContainer $isClosing={isClosing}>\n <ErrorBoundary\n fallback={\n <Styled.ModalLoaderWrapper>\n <Error height=\"100vh\" />\n </Styled.ModalLoaderWrapper>\n }\n onError={sentryCaptureException}\n >\n <Suspense\n fallback={\n <Styled.ModalLoaderWrapper>\n <AppLoader height=\"100vh\" />\n </Styled.ModalLoaderWrapper>\n }\n >\n <Styled.SpotlightModal $isClosing={isClosing} />\n {element}\n </Suspense>\n </ErrorBoundary>\n </Styled.ModalContainer>\n );\n }\n\n return (\n <Styled.ModalContainer $isClosing={isClosing}>\n <Styled.BaseModal $isClosing={isClosing} $width={modalWidth}>\n {isDismissable !== false && (\n <Styled.CloseButtonContainer $modalWidth={modalWidth}>\n <Clickable label=\"Close\" onClick={onClose}>\n <CrossIcon width={40} height={40} />\n </Clickable>\n </Styled.CloseButtonContainer>\n )}\n <Styled.BaseModalContent $modalWidth={modalWidth}>\n <ErrorBoundary\n fallback={<Error height=\"50vh\" size=\"compact\" />}\n onError={sentryCaptureException}\n >\n <Suspense fallback={<AppLoader height=\"50vh\" />}>{element}</Suspense>\n </ErrorBoundary>\n </Styled.BaseModalContent>\n </Styled.BaseModal>\n </Styled.ModalContainer>\n );\n});\n\nexport default Modal;\n"],"names":["Modal","memo","modal","isClosing","onClose","device","useTheme","isMobile","EDeviceType","renderAs","element","modalWidth","isDismissable","renderOnMobileAs","sentryCaptureException","useCallback","error","captureException","handleStopPropagation","e","Styled.ModalContainer","Styled.BottomSheetModal","jsx","ErrorBoundary","FlexView","Error","Suspense","AppLoader","Styled.ModalLoaderWrapper","jsxs","Styled.SpotlightModal","Styled.BaseModal","Styled.CloseButtonContainer","Clickable","CrossIcon","Styled.BaseModalContent"],"mappings":";;;;;;;;;;;;AAoBM,MAAAA,IAAyBC,EAAK,CAAC,EAAE,OAAAC,GAAO,WAAAC,IAAY,IAAO,SAAAC,QAAc;AACvE,QAAA,EAAE,QAAAC,MAAWC,KACbC,IAAWF,KAAUG,EAAY,QACjC,EAAE,UAAAC,GAAU,SAAAC,GAAS,YAAAC,GAAY,eAAAC,GAAe,kBAAAC,EAAqB,IAAAX,GAErEY,IAAyBC,EAAY,CAACC,MAAiB;AAC3D,IAAAC,EAAiBD,CAAK;AAAA,EACxB,GAAG,CAAE,CAAA,GAECE,IAAwBH,EAAY,CAACI,MAAwB;AACjE,IAAAA,EAAE,gBAAgB;AAAA,EACpB,GAAG,CAAE,CAAA;AAEL,SAAIV,MAAa,kBAAmBF,KAAYM,MAAqB,mCAEhEO,GAAA,EAAsB,YAAYjB,GAAW,SAASS,IAAgBR,IAAU,MAAM,MACrF,4BAACiB,GAAA,EAAwB,YAAYlB,GAAW,SAASe,GACvD,UAAA,gBAAAI;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,4BACGC,GAAS,EAAA,MAAM,IACd,UAAC,gBAAAF,EAAAG,GAAA,EAAM,QAAO,OAAA,CAAO,EACvB,CAAA;AAAA,MAEF,SAASX;AAAA,MAET,UAAA,gBAAAQ,EAACI,KAAS,UAAU,gBAAAJ,EAACK,KAAU,QAAO,OAAO,CAAA,GAAK,UAAQjB,EAAA,CAAA;AAAA,IAAA;AAAA,EAAA,EAE9D,CAAA,EACF,CAAA,IAIAD,MAAa,cAEZ,gBAAAa,EAAAF,GAAA,EAAsB,YAAYjB,GACjC,UAAA,gBAAAmB;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,4BACGK,GAAA,EACC,UAAC,gBAAAN,EAAAG,GAAA,EAAM,QAAO,QAAQ,CAAA,GACxB;AAAA,MAEF,SAASX;AAAA,MAET,UAAA,gBAAAe;AAAA,QAACH;AAAA,QAAA;AAAA,UACC,4BACGE,GAAA,EACC,UAAC,gBAAAN,EAAAK,GAAA,EAAU,QAAO,QAAQ,CAAA,GAC5B;AAAA,UAGF,UAAA;AAAA,YAAA,gBAAAL,EAACQ,GAAA,EAAsB,YAAY3B,EAAW,CAAA;AAAA,YAC7CO;AAAA,UAAA;AAAA,QAAA;AAAA,MACH;AAAA,IAAA;AAAA,EAEJ,EAAA,CAAA,IAKD,gBAAAY,EAAAF,GAAA,EAAsB,YAAYjB,GACjC,UAAC,gBAAA0B,EAAAE,GAAA,EAAiB,YAAY5B,GAAW,QAAQQ,GAC9C,UAAA;AAAA,IAAkBC,MAAA,wBAChBoB,GAAA,EAA4B,aAAarB,GACxC,4BAACsB,GAAU,EAAA,OAAM,SAAQ,SAAS7B,GAChC,4BAAC8B,GAAU,EAAA,OAAO,IAAI,QAAQ,IAAI,GACpC,EACF,CAAA;AAAA,IAED,gBAAAZ,EAAAa,GAAA,EAAwB,aAAaxB,GACpC,UAAA,gBAAAW;AAAA,MAACC;AAAA,MAAA;AAAA,QACC,UAAW,gBAAAD,EAAAG,GAAA,EAAM,QAAO,QAAO,MAAK,WAAU;AAAA,QAC9C,SAASX;AAAA,QAET,UAAA,gBAAAQ,EAACI,KAAS,UAAU,gBAAAJ,EAACK,KAAU,QAAO,OAAO,CAAA,GAAK,UAAQjB,EAAA,CAAA;AAAA,MAAA;AAAA,IAAA,GAE9D;AAAA,EAAA,EACF,CAAA,EACF,CAAA;AAEJ,CAAC;"}
@@ -0,0 +1,109 @@
1
+ import { jsxs as y, jsx as i } from "react/jsx-runtime";
2
+ import { memo as b } from "react";
3
+ import h, { css as a } from "styled-components";
4
+ import A from "../../ui/layout/flex-view.js";
5
+ import l from "../../ui/separator/separator.js";
6
+ import { StickerMap as k, MATH_REWARDS as R, INSTRUCTION_REWARDS as T, SCREEN_SIZES as m } from "../constants.js";
7
+ import D from "./belts.js";
8
+ import p from "./reward-elements.js";
9
+ const _ = h(A)`
10
+ justify-content: space-between;
11
+ margin: 110px 120px;
12
+ margin-bottom: 48px;
13
+ ${({ $containerStyle: t }) => t}
14
+
15
+ ${({ $renderOnTeacher: t }) => t && a`
16
+ margin: 50px auto;
17
+ padding: 0 16px;
18
+ `}
19
+ `, C = (t) => {
20
+ if (!(t && Array.isArray(t) && t.length > 0))
21
+ return { elements: [] };
22
+ const e = {
23
+ elements: []
24
+ };
25
+ return t.forEach((n) => {
26
+ const { aggregate_for: r, aggregates: o } = n || {}, { name: s } = r || {};
27
+ s && [...R, ...T].includes(s) && e.elements.push({ name: s, count: o || 0 });
28
+ }), e;
29
+ }, j = (t) => {
30
+ if (!(t && Array.isArray(t) && t.length > 0))
31
+ return { stickers: [] };
32
+ const e = {};
33
+ return t.forEach((n) => {
34
+ const { badge_id: r, name: o } = n;
35
+ r && o && (e[r] === void 0 ? e[r] = { name: o, count: 1 } : e[r] = { name: o, count: e[r].count + 1 });
36
+ }), { stickers: Object.values(e) };
37
+ }, $ = (t) => t >= m.LAPTOPL ? {
38
+ containerStyle: a`
39
+ margin: 110px auto;
40
+ margin-bottom: 48px;
41
+ max-width: 1040px;
42
+ width: 100%;
43
+ `
44
+ } : t < m.TABLET ? {
45
+ containerStyle: a`
46
+ margin: 110px 40px;
47
+ margin-bottom: 48px;
48
+ flex-direction: column;
49
+ width: 100%;
50
+ `
51
+ } : t < m.LAPTOP ? {
52
+ containerStyle: a`
53
+ max-width: 784px;
54
+ width: 100%;
55
+ margin: 100px auto;
56
+ flex-direction: column;
57
+ `
58
+ } : {
59
+ containerStyle: a`
60
+ display: flex;
61
+ flex-direction: row;
62
+ justify-content: space-between;
63
+ margin: 110px 120px;
64
+ margin-bottom: 48px;
65
+ `
66
+ }, O = ({
67
+ curriculumHomeData: t,
68
+ rewardHomeData: c,
69
+ programStream: e = "MATH",
70
+ currentScreenWidth: n,
71
+ renderOnTeacher: r = !1
72
+ }) => {
73
+ const { data: o } = t || {}, { curriculum_map: s } = o || {}, { belts: u, goals: x } = s || {}, { data: f } = c || {}, { user_rewards: g, user_stickers: d } = f || {}, { elements: w } = C(g || []), { stickers: E } = j(d || []), { containerStyle: S } = $(n) || {};
74
+ return /* @__PURE__ */ y(
75
+ _,
76
+ {
77
+ $flexDirection: "row",
78
+ $justifyContent: "space-between",
79
+ $containerStyle: S,
80
+ $renderOnTeacher: r,
81
+ children: [
82
+ /* @__PURE__ */ i(D, { beltStats: u, goalStats: x, currentScreenWidth: n }),
83
+ /* @__PURE__ */ i(l, { width: 60, height: 30 }),
84
+ /* @__PURE__ */ i(
85
+ p,
86
+ {
87
+ elements: w,
88
+ programStream: e,
89
+ currentScreenWidth: n
90
+ }
91
+ ),
92
+ /* @__PURE__ */ i(l, { width: 60, height: 30 }),
93
+ /* @__PURE__ */ i(
94
+ p,
95
+ {
96
+ elements: E,
97
+ isSticker: !0,
98
+ currentScreenWidth: n,
99
+ lotties: k
100
+ }
101
+ )
102
+ ]
103
+ }
104
+ );
105
+ }, F = b(O);
106
+ export {
107
+ F as default
108
+ };
109
+ //# sourceMappingURL=belts-elements-stickers.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"belts-elements-stickers.js","sources":["../../../../src/features/wins-dashboard/belts-elements-stickers/belts-elements-stickers.tsx"],"sourcesContent":["import React, { memo } from 'react';\nimport styled, { css } from 'styled-components';\n\nimport FlexView from '../../ui/layout/flex-view';\nimport Separator from '../../ui/separator/separator';\nimport { INSTRUCTION_REWARDS, MATH_REWARDS, SCREEN_SIZES, StickerMap } from '../constants';\nimport Belts from './belts';\nimport RewardElements from './reward-elements';\n\ninterface WrapperProps {\n $containerStyle?: ReturnType<typeof css>;\n $renderOnTeacher?: boolean;\n}\n\nconst Wrapper = styled(FlexView)<WrapperProps>`\n justify-content: space-between;\n margin: 110px 120px;\n margin-bottom: 48px;\n ${({ $containerStyle }) => $containerStyle}\n\n ${({ $renderOnTeacher }) =>\n $renderOnTeacher &&\n css`\n margin: 50px auto;\n padding: 0 16px;\n `}\n`;\n\ninterface RewardElement {\n aggregate_for?: { name?: string };\n aggregates?: number;\n}\n\ninterface StickerElement {\n badge_id?: string;\n name?: string;\n}\n\nconst getRewardElements = (\n elements: RewardElement[],\n): { elements: Array<{ name: string; count: number }> } => {\n const isElementsExist = elements && Array.isArray(elements) && elements.length > 0;\n\n if (!isElementsExist) {\n return { elements: [] };\n }\n\n const elementsData = {\n elements: [] as Array<{ name: string; count: number }>,\n };\n\n elements.forEach(item => {\n const { aggregate_for: rewardData, aggregates: totalCount } = item || {};\n const { name } = rewardData || {};\n\n if (name && [...MATH_REWARDS, ...INSTRUCTION_REWARDS].includes(name)) {\n elementsData.elements.push({ name, count: totalCount || 0 });\n }\n });\n\n return elementsData;\n};\n\nconst getRewardStickers = (\n stickers: StickerElement[],\n): { stickers: Array<{ name: string; count: number }> } => {\n const isStickersExist = stickers && Array.isArray(stickers) && stickers.length > 0;\n\n if (!isStickersExist) {\n return { stickers: [] };\n }\n\n const stickersCount: Record<string, { name: string; count: number }> = {};\n\n stickers.forEach(item => {\n const { badge_id: badgeId, name } = item;\n\n if (badgeId && name) {\n if (stickersCount[badgeId] === undefined) {\n stickersCount[badgeId] = { name, count: 1 };\n } else {\n stickersCount[badgeId] = { name, count: stickersCount[badgeId].count + 1 };\n }\n }\n });\n\n return { stickers: Object.values(stickersCount) };\n};\n\nconst getBadgeContainerConfig = (currentScreenWidth: number) => {\n if (currentScreenWidth >= SCREEN_SIZES.LAPTOPL) {\n return {\n containerStyle: css`\n margin: 110px auto;\n margin-bottom: 48px;\n max-width: 1040px;\n width: 100%;\n `,\n };\n }\n\n if (currentScreenWidth < SCREEN_SIZES.TABLET) {\n return {\n containerStyle: css`\n margin: 110px 40px;\n margin-bottom: 48px;\n flex-direction: column;\n width: 100%;\n `,\n };\n }\n\n if (currentScreenWidth < SCREEN_SIZES.LAPTOP) {\n return {\n containerStyle: css`\n max-width: 784px;\n width: 100%;\n margin: 100px auto;\n flex-direction: column;\n `,\n };\n }\n\n return {\n containerStyle: css`\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n margin: 110px 120px;\n margin-bottom: 48px;\n `,\n };\n};\n\n// Types for component props\ninterface CurriculumMap {\n belts?: {\n current_belt_type?: string;\n goals_required?: number;\n };\n goals?: {\n completed_goals: number;\n total_goals: number;\n };\n}\n\ninterface CurriculumHomeData {\n data?: {\n curriculum_map?: CurriculumMap;\n };\n}\n\ninterface RewardHomeData {\n data?: {\n user_rewards?: RewardElement[];\n user_stickers?: StickerElement[];\n };\n}\n\ninterface BeltsElementsStickersProps {\n curriculumHomeData?: CurriculumHomeData;\n rewardHomeData?: RewardHomeData;\n programStream?: string;\n currentScreenWidth: number;\n renderOnTeacher?: boolean;\n}\n\nconst BeltsElementsStickers: React.FC<BeltsElementsStickersProps> = ({\n curriculumHomeData,\n rewardHomeData,\n programStream = 'MATH',\n currentScreenWidth,\n renderOnTeacher = false,\n}) => {\n const { data: curriculumData } = curriculumHomeData || {};\n const { curriculum_map: curriculumMap } = curriculumData || {};\n const { belts: beltStats, goals: goalStats } = curriculumMap || {};\n const { data: rewardHome } = rewardHomeData || {};\n const { user_rewards: rewardElementsData, user_stickers: rewardStickersData } = rewardHome || {};\n const { elements } = getRewardElements(rewardElementsData || []);\n const { stickers } = getRewardStickers(rewardStickersData || []);\n const { containerStyle } = getBadgeContainerConfig(currentScreenWidth) || {};\n\n return (\n <Wrapper\n $flexDirection=\"row\"\n $justifyContent=\"space-between\"\n $containerStyle={containerStyle}\n $renderOnTeacher={renderOnTeacher}\n >\n <Belts beltStats={beltStats} goalStats={goalStats} currentScreenWidth={currentScreenWidth} />\n <Separator width={60} height={30} />\n <RewardElements\n elements={elements}\n programStream={programStream}\n currentScreenWidth={currentScreenWidth}\n />\n <Separator width={60} height={30} />\n <RewardElements\n elements={stickers}\n isSticker\n currentScreenWidth={currentScreenWidth}\n lotties={StickerMap}\n />\n </Wrapper>\n );\n};\n\nexport default memo(BeltsElementsStickers);\n"],"names":["Wrapper","styled","FlexView","$containerStyle","$renderOnTeacher","css","getRewardElements","elements","elementsData","item","rewardData","totalCount","name","MATH_REWARDS","INSTRUCTION_REWARDS","getRewardStickers","stickers","stickersCount","badgeId","getBadgeContainerConfig","currentScreenWidth","SCREEN_SIZES","BeltsElementsStickers","curriculumHomeData","rewardHomeData","programStream","renderOnTeacher","curriculumData","curriculumMap","beltStats","goalStats","rewardHome","rewardElementsData","rewardStickersData","containerStyle","jsxs","jsx","Belts","Separator","RewardElements","StickerMap","beltsElementsStickers","memo"],"mappings":";;;;;;;;AAcA,MAAMA,IAAUC,EAAOC,CAAQ;AAAA;AAAA;AAAA;AAAA,IAI3B,CAAC,EAAE,iBAAAC,EAAgB,MAAMA,CAAe;AAAA;AAAA,IAExC,CAAC,EAAE,kBAAAC,QACHA,KACAC;AAAA;AAAA;AAAA,KAGC;AAAA,GAaCC,IAAoB,CACxBC,MACyD;AAGzD,MAAI,EAFoBA,KAAY,MAAM,QAAQA,CAAQ,KAAKA,EAAS,SAAS;AAGxE,WAAA,EAAE,UAAU,CAAA;AAGrB,QAAMC,IAAe;AAAA,IACnB,UAAU,CAAC;AAAA,EAAA;AAGb,SAAAD,EAAS,QAAQ,CAAQE,MAAA;AACvB,UAAM,EAAE,eAAeC,GAAY,YAAYC,EAAW,IAAIF,KAAQ,IAChE,EAAE,MAAAG,EAAA,IAASF,KAAc;AAE3B,IAAAE,KAAQ,CAAC,GAAGC,GAAc,GAAGC,CAAmB,EAAE,SAASF,CAAI,KACjEJ,EAAa,SAAS,KAAK,EAAE,MAAAI,GAAM,OAAOD,KAAc,GAAG;AAAA,EAC7D,CACD,GAEMH;AACT,GAEMO,IAAoB,CACxBC,MACyD;AAGzD,MAAI,EAFoBA,KAAY,MAAM,QAAQA,CAAQ,KAAKA,EAAS,SAAS;AAGxE,WAAA,EAAE,UAAU,CAAA;AA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E,gBAAAC,EAAe,IAAIf,EAAwBC,CAAkB,KAAK,CAAA;AAGxE,SAAA,gBAAAe;AAAA,IAACnC;AAAA,IAAA;AAAA,MACC,gBAAe;AAAA,MACf,iBAAgB;AAAA,MAChB,iBAAiBkC;AAAA,MACjB,kBAAkBR;AAAA,MAElB,UAAA;AAAA,QAAC,gBAAAU,EAAAC,GAAA,EAAM,WAAAR,GAAsB,WAAAC,GAAsB,oBAAAV,EAAwC,CAAA;AAAA,QAC1F,gBAAAgB,EAAAE,GAAA,EAAU,OAAO,IAAI,QAAQ,IAAI;AAAA,QAClC,gBAAAF;AAAA,UAACG;AAAA,UAAA;AAAA,YACC,UAAAhC;AAAA,YACA,eAAAkB;AAAA,YACA,oBAAAL;AAAA,UAAA;AAAA,QACF;AAAA,QACC,gBAAAgB,EAAAE,GAAA,EAAU,OAAO,IAAI,QAAQ,IAAI;AAAA,QAClC,gBAAAF;AAAA,UAACG;AAAA,UAAA;AAAA,YACC,UAAUvB;AAAA,YACV,WAAS;AAAA,YACT,oBAAAI;AAAA,YACA,SAASoB;AAAA,UAAA;AAAA,QACX;AAAA,MAAA;AAAA,IAAA;AAAA,EAAA;AAGN,GAEeC,IAAAC,EAAKpB,CAAqB;"}
@@ -0,0 +1,95 @@
1
+ import { jsx as t, jsxs as d } from "react/jsx-runtime";
2
+ import { memo as w } from "react";
3
+ import s, { css as c } from "styled-components";
4
+ import E from "../../ui/arrow-tooltip/arrow-tooltip.js";
5
+ import g from "../../ui/layout/flex-view.js";
6
+ import h from "../../ui/separator/separator.js";
7
+ import m from "../../ui/text/text.js";
8
+ import { SCREEN_SIZES as p, getBeltIcon as x } from "../constants.js";
9
+ import u from "./progress-bar-horizontal.js";
10
+ const y = "Black", P = s.div`
11
+ display: flex;
12
+ width: 100%;
13
+ flex-direction: column;
14
+ align-items: center;
15
+ ${({ $currentScreenWidth: e }) => e < p.LAPTOP && c`
16
+ width: 80%;
17
+ flex-direction: row;
18
+ `}
19
+ `, _ = s(g)`
20
+ min-width: 250px;
21
+ ${({ $currentScreenWidth: e }) => e < p.LAPTOP && c`
22
+ min-width: 180px;
23
+ `}
24
+ `, A = s(g)`
25
+ width: 120px;
26
+ align-items: center;
27
+ padding-left: 22px;
28
+ `, b = s.img`
29
+ width: 142px;
30
+ height: 110px;
31
+ ${({ $isBeltsExist: e }) => !e && c`
32
+ filter: grayscale(100%);
33
+ opacity: 20%;
34
+ `};
35
+ ${({ $currentScreenWidth: e }) => e < p.LAPTOP && c`
36
+ width: 104px;
37
+ height: 80px;
38
+ `}
39
+ `, Y = s(g)`
40
+ width: 250px;
41
+ `, C = s(h)`
42
+ ${({ $currentScreenWidth: e }) => e < p.LAPTOP && c`
43
+ height: 52px;
44
+ `}
45
+ `, L = s(m)`
46
+ opacity: ${({ $isBeltsExist: e }) => !e && "50%"};
47
+ `, S = (e, l, o, r) => {
48
+ let i = `${e}/${l} goal mastered`;
49
+ const a = l - e;
50
+ return o ? e === l ? i = "Congrats! You're now a Black Belt" : r ? i = `Next Belt: ${r} ${r > 1 ? "goals" : "goal"} away` : i = e < l ? `Next Belt: ${a} ${a > 1 ? "goals" : "goal"} away` : "Congrats! You're now a Black Belt" : o || (i = "You have no belts earned"), i;
51
+ }, R = () => /* @__PURE__ */ t(m, { $renderAs: "body3", $color: "WHITE", children: "You can't earn belts for the selected program" }), I = ({ beltStats: e, goalStats: l, currentScreenWidth: o }) => {
52
+ const { current_belt_type: r, goals_required: i } = e || {}, { completed_goals: a = 0, total_goals: $ = 1 } = l || {}, n = !!r, f = n ? `${r && r.toUpperCase()} BELT` : "BELTS", B = Math.floor(a * 100 / $), T = S(a, $, n, i);
53
+ return /* @__PURE__ */ t(
54
+ E,
55
+ {
56
+ position: "bottom",
57
+ tooltipItem: R(),
58
+ renderAs: "primary",
59
+ hidden: n,
60
+ children: /* @__PURE__ */ d(P, { $currentScreenWidth: o, children: [
61
+ /* @__PURE__ */ d(_, { $currentScreenWidth: o, children: [
62
+ /* @__PURE__ */ t(m, { $renderAs: "h5", children: f }),
63
+ /* @__PURE__ */ t(h, { height: 24 }),
64
+ /* @__PURE__ */ t(A, { children: /* @__PURE__ */ t(
65
+ b,
66
+ {
67
+ $currentScreenWidth: o,
68
+ $isBeltsExist: n,
69
+ src: n ? x(r || "") : x(y),
70
+ alt: "Belt"
71
+ }
72
+ ) })
73
+ ] }),
74
+ /* @__PURE__ */ d(Y, { children: [
75
+ /* @__PURE__ */ t(C, { $currentScreenWidth: o, height: 38 }),
76
+ /* @__PURE__ */ t(
77
+ u,
78
+ {
79
+ progress: B,
80
+ height: 4,
81
+ backgroundColor: "GREY_1",
82
+ progressColor: n ? "GREY_4" : "GREY_2"
83
+ }
84
+ ),
85
+ /* @__PURE__ */ t(h, { height: 8 }),
86
+ /* @__PURE__ */ t(L, { $isBeltsExist: n, $renderAs: "body3", $color: "GREY_4", children: T })
87
+ ] })
88
+ ] })
89
+ }
90
+ );
91
+ }, F = w(I);
92
+ export {
93
+ F as default
94
+ };
95
+ //# sourceMappingURL=belts.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"belts.js","sources":["../../../../src/features/wins-dashboard/belts-elements-stickers/belts.tsx"],"sourcesContent":["import React, { memo } from 'react';\nimport styled, { css } from 'styled-components';\n\nimport ArrowTooltip from '../../ui/arrow-tooltip/arrow-tooltip';\nimport FlexView from '../../ui/layout/flex-view';\nimport Separator from '../../ui/separator/separator';\nimport Text from '../../ui/text/text';\nimport { getBeltIcon, SCREEN_SIZES } from '../constants';\nimport ProgressBarHorizontal from './progress-bar-horizontal';\n\nconst DEFAULT_BELT_TYPE = 'Black';\n\ninterface ContainerProps {\n $currentScreenWidth: number;\n}\n\nconst Container = styled.div<ContainerProps>`\n display: flex;\n width: 100%;\n flex-direction: column;\n align-items: center;\n ${({ $currentScreenWidth }) =>\n $currentScreenWidth < SCREEN_SIZES.LAPTOP &&\n css`\n width: 80%;\n flex-direction: row;\n `}\n`;\n\ninterface HeaderContainerProps {\n $currentScreenWidth: number;\n}\n\nconst HeaderContainer = styled(FlexView)<HeaderContainerProps>`\n min-width: 250px;\n ${({ $currentScreenWidth }) =>\n $currentScreenWidth < SCREEN_SIZES.LAPTOP &&\n css`\n min-width: 180px;\n `}\n`;\n\nconst ProfileWrapper = styled(FlexView)`\n width: 120px;\n align-items: center;\n padding-left: 22px;\n`;\n\ninterface BeltImgProps {\n $isBeltsExist: boolean;\n $currentScreenWidth: number;\n}\n\nconst BeltImg = styled.img<BeltImgProps>`\n width: 142px;\n height: 110px;\n ${({ $isBeltsExist }) =>\n !$isBeltsExist &&\n css`\n filter: grayscale(100%);\n opacity: 20%;\n `};\n ${({ $currentScreenWidth }) =>\n $currentScreenWidth < SCREEN_SIZES.LAPTOP &&\n css`\n width: 104px;\n height: 80px;\n `}\n`;\n\nconst ProgressBarWrapper = styled(FlexView)`\n width: 250px;\n`;\n\ninterface SeparatorDivProps {\n $currentScreenWidth: number;\n}\n\nconst SeparatorDiv = styled(Separator)<SeparatorDivProps>`\n ${({ $currentScreenWidth }) =>\n $currentScreenWidth < SCREEN_SIZES.LAPTOP &&\n css`\n height: 52px;\n `}\n`;\n\ninterface BeltTextProps {\n $isBeltsExist: boolean;\n}\n\nconst BeltText = styled(Text)<BeltTextProps>`\n opacity: ${({ $isBeltsExist }) => !$isBeltsExist && '50%'};\n`;\n\nconst getBarTitle = (\n completedGoals: number,\n totalGoals: number,\n isBeltsExist: boolean,\n nextBeltGoals?: number,\n): string => {\n let title = `${completedGoals}/${totalGoals} goal mastered`;\n const goalsReq = totalGoals - completedGoals;\n\n if (isBeltsExist) {\n if (completedGoals === totalGoals) {\n title = \"Congrats! You're now a Black Belt\";\n } else if (nextBeltGoals) {\n title = `Next Belt: ${nextBeltGoals} ${nextBeltGoals > 1 ? 'goals' : 'goal'} away`;\n } else {\n title =\n completedGoals < totalGoals\n ? `Next Belt: ${goalsReq} ${goalsReq > 1 ? 'goals' : 'goal'} away`\n : \"Congrats! You're now a Black Belt\";\n }\n } else if (!isBeltsExist) {\n title = 'You have no belts earned';\n }\n\n return title;\n};\n\nconst getToolTipText = () => {\n return (\n <Text $renderAs=\"body3\" $color=\"WHITE\">\n You can&apos;t earn belts for the selected program\n </Text>\n );\n};\n\ninterface BeltStats {\n current_belt_type?: string;\n goals_required?: number;\n}\n\ninterface GoalStats {\n completed_goals: number;\n total_goals: number;\n}\n\ninterface BeltsProps {\n beltStats?: BeltStats | null;\n goalStats?: GoalStats | null;\n currentScreenWidth: number;\n}\n\nconst Belts: React.FC<BeltsProps> = ({ beltStats, goalStats, currentScreenWidth }) => {\n const { current_belt_type: currentBeltType, goals_required: nextBeltGoals } = beltStats || {};\n const { completed_goals: completedGoals = 0, total_goals: totalGoals = 1 } = goalStats || {};\n\n const isBeltsExist = !!currentBeltType;\n const beltTitle = isBeltsExist\n ? `${currentBeltType && currentBeltType.toUpperCase()} BELT`\n : 'BELTS';\n const progress = Math.floor((completedGoals * 100) / totalGoals);\n const barTitle = getBarTitle(completedGoals, totalGoals, isBeltsExist, nextBeltGoals);\n\n return (\n <ArrowTooltip\n position=\"bottom\"\n tooltipItem={getToolTipText()}\n renderAs=\"primary\"\n hidden={isBeltsExist}\n >\n <Container $currentScreenWidth={currentScreenWidth}>\n <HeaderContainer $currentScreenWidth={currentScreenWidth}>\n <Text $renderAs=\"h5\">{beltTitle}</Text>\n <Separator height={24} />\n <ProfileWrapper>\n <BeltImg\n $currentScreenWidth={currentScreenWidth}\n $isBeltsExist={isBeltsExist}\n src={\n !isBeltsExist ? getBeltIcon(DEFAULT_BELT_TYPE) : getBeltIcon(currentBeltType || '')\n }\n alt=\"Belt\"\n />\n </ProfileWrapper>\n </HeaderContainer>\n <ProgressBarWrapper>\n <SeparatorDiv $currentScreenWidth={currentScreenWidth} height={38} />\n <ProgressBarHorizontal\n progress={progress}\n height={4}\n backgroundColor=\"GREY_1\"\n progressColor={isBeltsExist ? 'GREY_4' : 'GREY_2'}\n />\n <Separator height={8} />\n <BeltText $isBeltsExist={isBeltsExist} $renderAs=\"body3\" $color=\"GREY_4\">\n {barTitle}\n </BeltText>\n </ProgressBarWrapper>\n </Container>\n </ArrowTooltip>\n );\n};\n\nexport default memo(Belts);\n"],"names":["DEFAULT_BELT_TYPE","Container","styled","$currentScreenWidth","SCREEN_SIZES","css","HeaderContainer","FlexView","ProfileWrapper","BeltImg","$isBeltsExist","ProgressBarWrapper","SeparatorDiv","Separator","BeltText","Text","getBarTitle","completedGoals","totalGoals","isBeltsExist","nextBeltGoals","title","goalsReq","getToolTipText","Belts","beltStats","goalStats","currentScreenWidth","currentBeltType","beltTitle","progress","barTitle","jsx","ArrowTooltip","jsxs","getBeltIcon","ProgressBarHorizontal","Belts$1","memo"],"mappings":";;;;;;;;;AAUA,MAAMA,IAAoB,SAMpBC,IAAYC,EAAO;AAAA;AAAA;AAAA;AAAA;AAAA,IAKrB,CAAC,EAAE,qBAAAC,EACH,MAAAA,IAAsBC,EAAa,UACnCC;AAAA;AAAA;AAAA,KAGC;AAAA,GAOCC,IAAkBJ,EAAOK,CAAQ;AAAA;AAAA,IAEnC,CAAC,EAAE,qBAAAJ,EACH,MAAAA,IAAsBC,EAAa,UACnCC;AAAA;AAAA,KAEC;AAAA,GAGCG,IAAiBN,EAAOK,CAAQ;AAAA;AAAA;AAAA;AAAA,GAWhCE,IAAUP,EAAO;AAAA;AAAA;AAAA,IAGnB,CAAC,EAAE,eAAAQ,EAAc,MACjB,CAACA,KACDL;AAAA;AAAA;AAAA,KAGC;AAAA,IACD,CAAC,EAAE,qBAAAF,EACH,MAAAA,IAAsBC,EAAa,UACnCC;AAAA;AAAA;AAAA,KAGC;AAAA,GAGCM,IAAqBT,EAAOK,CAAQ;AAAA;AAAA,GAQpCK,IAAeV,EAAOW,CAAS;AAAA,IACjC,CAAC,EAAE,qBAAAV,EACH,MAAAA,IAAsBC,EAAa,UACnCC;AAAA;AAAA,KAEC;AAAA,GAOCS,IAAWZ,EAAOa,CAAI;AAAA,aACf,CAAC,EAAE,eAAAL,EAAA,MAAoB,CAACA,KA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