@cuemath/leap 3.3.26-m → 3.3.26
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/features/auth/account-selector/account-selector-styled.js +6 -5
- package/dist/features/auth/account-selector/account-selector-styled.js.map +1 -1
- package/dist/features/auth/account-selector/account-selector.js +52 -58
- package/dist/features/auth/account-selector/account-selector.js.map +1 -1
- package/dist/features/auth/account-selector/comps/compact-header/account-selector-header.js +31 -0
- package/dist/features/auth/account-selector/comps/compact-header/account-selector-header.js.map +1 -0
- package/dist/features/auth/comps/auth-page-layout/auth-page-layout-styled.js +1 -1
- package/dist/features/auth/comps/auth-page-layout/auth-page-layout-styled.js.map +1 -1
- package/dist/features/auth/comps/user-list/user-list-styled.js +3 -2
- package/dist/features/auth/comps/user-list/user-list-styled.js.map +1 -1
- package/dist/features/journey/journey-id/journey-id-teacher.js +1 -1
- package/dist/features/journey/journey-id/journey-id-teacher.js.map +1 -1
- package/dist/features/journey/use-journey/constants.js +18 -2
- package/dist/features/journey/use-journey/constants.js.map +1 -1
- package/dist/features/journey/use-journey/use-journey.js +10 -7
- package/dist/features/journey/use-journey/use-journey.js.map +1 -1
- package/dist/features/parent-dashboard/comps/compact-header/compact-header.js +16 -16
- package/dist/features/parent-dashboard/comps/compact-header/compact-header.js.map +1 -1
- package/dist/features/parent-dashboard/comps/parent-dashboard-faqs/parent-dashboard-faqs-constants.js +29 -13
- package/dist/features/parent-dashboard/comps/parent-dashboard-faqs/parent-dashboard-faqs-constants.js.map +1 -1
- package/dist/features/parent-dashboard/comps/pla-first-session-introduction/pla-first-session-introduction.js +21 -19
- package/dist/features/parent-dashboard/comps/pla-first-session-introduction/pla-first-session-introduction.js.map +1 -1
- package/dist/features/parent-dashboard/hooks/use-fetch-parent-home.js +28 -0
- package/dist/features/parent-dashboard/hooks/use-fetch-parent-home.js.map +1 -0
- package/dist/features/parent-dashboard/hooks/use-parent-home-data.js +35 -48
- package/dist/features/parent-dashboard/hooks/use-parent-home-data.js.map +1 -1
- package/dist/features/parent-dashboard/modals/tutor-change/tutor-change-styled.js +11 -9
- package/dist/features/parent-dashboard/modals/tutor-change/tutor-change-styled.js.map +1 -1
- package/dist/features/parent-dashboard/modals/tutor-change/tutor-change.js +6 -6
- package/dist/features/parent-dashboard/modals/tutor-change/tutor-change.js.map +1 -1
- package/dist/features/parent-dashboard/parent-dashboard-styled.js +2 -2
- package/dist/features/parent-dashboard/parent-dashboard-styled.js.map +1 -1
- package/dist/features/parent-dashboard/parent-dashboard-types.js.map +1 -1
- package/dist/features/parent-dashboard/parent-dashboard-view.js +110 -110
- package/dist/features/parent-dashboard/parent-dashboard-view.js.map +1 -1
- package/dist/features/trial-session/comps/pla/upcoming-sessions/upcoming-sessions.js +40 -35
- package/dist/features/trial-session/comps/pla/upcoming-sessions/upcoming-sessions.js.map +1 -1
- package/dist/index.d.ts +78 -7
- package/dist/index.js +117 -113
- package/dist/index.js.map +1 -1
- package/dist/node_modules/decode-uri-component/index.js.map +1 -0
- package/dist/node_modules/query-string/base.js +1 -1
- package/dist/node_modules/uuid/dist/esm-browser/native.js +7 -0
- package/dist/node_modules/uuid/dist/esm-browser/native.js.map +1 -0
- package/dist/node_modules/uuid/dist/esm-browser/rng.js +3 -2
- package/dist/node_modules/uuid/dist/esm-browser/rng.js.map +1 -1
- package/dist/node_modules/uuid/dist/esm-browser/stringify.js +6 -10
- package/dist/node_modules/uuid/dist/esm-browser/stringify.js.map +1 -1
- package/dist/node_modules/uuid/dist/esm-browser/v4.js +12 -9
- package/dist/node_modules/uuid/dist/esm-browser/v4.js.map +1 -1
- package/package.json +1 -1
- package/dist/node_modules/query-string/node_modules/decode-uri-component/index.js.map +0 -1
- package/dist/node_modules/uuid/dist/esm-browser/regex.js +0 -5
- package/dist/node_modules/uuid/dist/esm-browser/regex.js.map +0 -1
- package/dist/node_modules/uuid/dist/esm-browser/validate.js +0 -8
- package/dist/node_modules/uuid/dist/esm-browser/validate.js.map +0 -1
- /package/dist/node_modules/{query-string/node_modules/decode-uri-component → decode-uri-component}/index.js +0 -0
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"pla-first-session-introduction.js","sources":["../../../../../src/features/parent-dashboard/comps/pla-first-session-introduction/pla-first-session-introduction.tsx"],"sourcesContent":["import type { IFirstSessionIntroductionProps } from './pla-first-session-introduction-types';\n\nimport { memo, type FC } from 'react';\n\nimport { ILLUSTRATIONS } from '../../../../assets/illustrations/illustrations';\nimport Button from '../../../ui/buttons/button/button';\nimport Image from '../../../ui/image/image';\nimport FlexView from '../../../ui/layout/flex-view';\nimport Separator from '../../../ui/separator/separator';\nimport Text from '../../../ui/text/text';\nimport useParentHomeData from '../../hooks/use-parent-home-data';\nimport * as Styled from './pla-first-session-introduction-styled';\n\nconst PlaFirstSessionIntroduction: FC<IFirstSessionIntroductionProps> = ({\n studentId,\n onRunSystemCheck,\n}) => {\n const { formattedNextSessionStart } = useParentHomeData(studentId);\n\n return (\n <FlexView $justifyContent=\"center\" $alignItems=\"center\" $height=\"100vh\" $width={'100%'}>\n {formattedNextSessionStart && (\n <FlexView>\n <Text $renderAs=\"ab1\" $color=\"BLACK_1\" $align=\"center\">\n We’re excited for your first session on\n </Text>\n <Separator height={4} />\n <Text $renderAs=\"ab1-bold\" $align=\"center\">\n {formattedNextSessionStart}\n </Text>\n </FlexView>\n )}\n <Separator heightX={2.5} />\n <Styled.ImageWrapper>\n <Image src={ILLUSTRATIONS.LEARNING_PUZZLE_BOT} width=\"100%\" />\n </Styled.ImageWrapper>\n <Separator heightX={3.5} />\n <Text $renderAs=\"ab2\" $color=\"BLACK_1\" $align=\"center\">\n Let's make sure your device is ready for your child's session.\n </Text>\n <Separator heightX={1} />\n <Button\n renderAs=\"primary\"\n label=\"Run a system check\"\n shape=\"square\"\n size=\"small\"\n onClick={onRunSystemCheck}\n />\n </FlexView>\n );\n};\n\nexport default memo(PlaFirstSessionIntroduction);\n"],"names":["PlaFirstSessionIntroduction","studentId","onRunSystemCheck","formattedNextSessionStart","useParentHomeData","jsxs","FlexView","jsx","Text","Separator","Styled.ImageWrapper","Image","ILLUSTRATIONS","Button","plaFirstSessionIntroduction","memo"],"mappings":"
|
|
1
|
+
{"version":3,"file":"pla-first-session-introduction.js","sources":["../../../../../src/features/parent-dashboard/comps/pla-first-session-introduction/pla-first-session-introduction.tsx"],"sourcesContent":["import type { IFirstSessionIntroductionProps } from './pla-first-session-introduction-types';\n\nimport { memo, type FC } from 'react';\n\nimport { ILLUSTRATIONS } from '../../../../assets/illustrations/illustrations';\nimport Button from '../../../ui/buttons/button/button';\nimport Image from '../../../ui/image/image';\nimport FlexView from '../../../ui/layout/flex-view';\nimport Separator from '../../../ui/separator/separator';\nimport Text from '../../../ui/text/text';\nimport useFetchParentHome from '../../hooks/use-fetch-parent-home';\nimport useParentHomeData from '../../hooks/use-parent-home-data';\nimport * as Styled from './pla-first-session-introduction-styled';\n\nconst PlaFirstSessionIntroduction: FC<IFirstSessionIntroductionProps> = ({\n studentId,\n onRunSystemCheck,\n}) => {\n useFetchParentHome(studentId);\n const { formattedNextSessionStart } = useParentHomeData(studentId);\n\n return (\n <FlexView $justifyContent=\"center\" $alignItems=\"center\" $height=\"100vh\" $width={'100%'}>\n {formattedNextSessionStart && (\n <FlexView>\n <Text $renderAs=\"ab1\" $color=\"BLACK_1\" $align=\"center\">\n We’re excited for your first session on\n </Text>\n <Separator height={4} />\n <Text $renderAs=\"ab1-bold\" $align=\"center\">\n {formattedNextSessionStart}\n </Text>\n </FlexView>\n )}\n <Separator heightX={2.5} />\n <Styled.ImageWrapper>\n <Image src={ILLUSTRATIONS.LEARNING_PUZZLE_BOT} width=\"100%\" />\n </Styled.ImageWrapper>\n <Separator heightX={3.5} />\n <Text $renderAs=\"ab2\" $color=\"BLACK_1\" $align=\"center\">\n Let's make sure your device is ready for your child's session.\n </Text>\n <Separator heightX={1} />\n <Button\n renderAs=\"primary\"\n label=\"Run a system check\"\n shape=\"square\"\n size=\"small\"\n onClick={onRunSystemCheck}\n />\n </FlexView>\n );\n};\n\nexport default memo(PlaFirstSessionIntroduction);\n"],"names":["PlaFirstSessionIntroduction","studentId","onRunSystemCheck","useFetchParentHome","formattedNextSessionStart","useParentHomeData","jsxs","FlexView","jsx","Text","Separator","Styled.ImageWrapper","Image","ILLUSTRATIONS","Button","plaFirstSessionIntroduction","memo"],"mappings":";;;;;;;;;;;AAcA,MAAMA,IAAkE,CAAC;AAAA,EACvE,WAAAC;AAAA,EACA,kBAAAC;AACF,MAAM;AACJ,EAAAC,EAAmBF,CAAS;AAC5B,QAAM,EAAE,2BAAAG,EAAA,IAA8BC,EAAkBJ,CAAS;AAG/D,SAAA,gBAAAK,EAACC,KAAS,iBAAgB,UAAS,aAAY,UAAS,SAAQ,SAAQ,QAAQ,QAC7E,UAAA;AAAA,IAAAH,uBACEG,GACC,EAAA,UAAA;AAAA,MAAA,gBAAAC,EAACC,KAAK,WAAU,OAAM,QAAO,WAAU,QAAO,UAAS,UAEvD,0CAAA,CAAA;AAAA,MACA,gBAAAD,EAACE,GAAU,EAAA,QAAQ,EAAG,CAAA;AAAA,wBACrBD,GAAK,EAAA,WAAU,YAAW,QAAO,UAC/B,UACHL,GAAA;AAAA,IAAA,GACF;AAAA,IAEF,gBAAAI,EAACE,GAAU,EAAA,SAAS,IAAK,CAAA;AAAA,IACzB,gBAAAF,EAACG,GAAA,EACC,UAAA,gBAAAH,EAACI,GAAM,EAAA,KAAKC,EAAc,qBAAqB,OAAM,OAAA,CAAO,EAC9D,CAAA;AAAA,IACA,gBAAAL,EAACE,GAAU,EAAA,SAAS,IAAK,CAAA;AAAA,IACzB,gBAAAF,EAACC,KAAK,WAAU,OAAM,QAAO,WAAU,QAAO,UAAS,UAEvD,iEAAA,CAAA;AAAA,IACA,gBAAAD,EAACE,GAAU,EAAA,SAAS,EAAG,CAAA;AAAA,IACvB,gBAAAF;AAAA,MAACM;AAAA,MAAA;AAAA,QACC,UAAS;AAAA,QACT,OAAM;AAAA,QACN,OAAM;AAAA,QACN,MAAK;AAAA,QACL,SAASZ;AAAA,MAAA;AAAA,IACX;AAAA,EACF,EAAA,CAAA;AAEJ,GAEea,IAAAC,EAAKhB,CAA2B;"}
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import { useCallback as n, useEffect as i, useMemo as m } from "react";
|
|
2
|
+
import { useParentHomeGet as f } from "../api/parent-home.js";
|
|
3
|
+
const l = (e) => {
|
|
4
|
+
const {
|
|
5
|
+
get: s,
|
|
6
|
+
data: o,
|
|
7
|
+
isStale: a,
|
|
8
|
+
isProcessing: r,
|
|
9
|
+
isProcessingFailed: c
|
|
10
|
+
} = f(e), t = n(() => {
|
|
11
|
+
e && s(e);
|
|
12
|
+
}, [s, e]);
|
|
13
|
+
return i(() => {
|
|
14
|
+
t();
|
|
15
|
+
}, [t]), i(() => {
|
|
16
|
+
a && t();
|
|
17
|
+
}, [t, a]), m(
|
|
18
|
+
() => ({
|
|
19
|
+
isLoading: r || !o,
|
|
20
|
+
isProcessingFailed: c
|
|
21
|
+
}),
|
|
22
|
+
[r, o, c]
|
|
23
|
+
);
|
|
24
|
+
}, H = l;
|
|
25
|
+
export {
|
|
26
|
+
H as default
|
|
27
|
+
};
|
|
28
|
+
//# sourceMappingURL=use-fetch-parent-home.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-fetch-parent-home.js","sources":["../../../../src/features/parent-dashboard/hooks/use-fetch-parent-home.ts"],"sourcesContent":["import { useCallback, useEffect, useMemo } from 'react';\n\nimport { useParentHomeGet } from '../api/parent-home';\n\n/**\n * This hook is intended only for **triggering** the Parent Home API\n * if it's needed outside the Parent Router.\n * This hook is being called at the level of the Parent Dashboard: <ParentRoutesWrapper />\n * To **consume** the parent home data elsewhere in the app,\n * use the `useParentHomeData()` hook instead.\n */\n\nconst useFetchParentHome = (studentId: string) => {\n const {\n get: getParentHome,\n data,\n isStale,\n isProcessing,\n isProcessingFailed,\n } = useParentHomeGet(studentId);\n\n const fetchData = useCallback(() => {\n studentId && getParentHome(studentId);\n }, [getParentHome, studentId]);\n\n useEffect(() => {\n fetchData();\n }, [fetchData]);\n\n useEffect(() => {\n if (isStale) {\n fetchData();\n }\n }, [fetchData, isStale]);\n\n const result = useMemo(\n () => ({\n isLoading: isProcessing || !data,\n isProcessingFailed,\n }),\n [isProcessing, data, isProcessingFailed],\n );\n\n return result;\n};\n\nexport default useFetchParentHome;\n"],"names":["useFetchParentHome","studentId","getParentHome","data","isStale","isProcessing","isProcessingFailed","useParentHomeGet","fetchData","useCallback","useEffect","useMemo","useFetchParentHome$1"],"mappings":";;AAYA,MAAMA,IAAqB,CAACC,MAAsB;AAC1C,QAAA;AAAA,IACJ,KAAKC;AAAA,IACL,MAAAC;AAAA,IACA,SAAAC;AAAA,IACA,cAAAC;AAAA,IACA,oBAAAC;AAAA,EAAA,IACEC,EAAiBN,CAAS,GAExBO,IAAYC,EAAY,MAAM;AAClC,IAAAR,KAAaC,EAAcD,CAAS;AAAA,EAAA,GACnC,CAACC,GAAeD,CAAS,CAAC;AAE7B,SAAAS,EAAU,MAAM;AACJ,IAAAF;EAAA,GACT,CAACA,CAAS,CAAC,GAEdE,EAAU,MAAM;AACd,IAAIN,KACQI;EACZ,GACC,CAACA,GAAWJ,CAAO,CAAC,GAERO;AAAA,IACb,OAAO;AAAA,MACL,WAAWN,KAAgB,CAACF;AAAA,MAC5B,oBAAAG;AAAA,IAAA;AAAA,IAEF,CAACD,GAAcF,GAAMG,CAAkB;AAAA,EAAA;AAI3C,GAEAM,IAAeZ;"}
|
|
@@ -1,23 +1,12 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { useParentHomeGet as
|
|
3
|
-
import { formatDate as
|
|
4
|
-
const
|
|
5
|
-
const {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
} = P(s), e = H(() => {
|
|
11
|
-
s && n(s);
|
|
12
|
-
}, [n, s]);
|
|
13
|
-
return p(() => {
|
|
14
|
-
e();
|
|
15
|
-
}, [e]), p(() => {
|
|
16
|
-
i && e();
|
|
17
|
-
}, [e, i]), O(() => {
|
|
18
|
-
var d;
|
|
19
|
-
const { teacher_details: r = null, session_details: o } = a ?? {};
|
|
20
|
-
if (!o)
|
|
1
|
+
import { useMemo as M } from "react";
|
|
2
|
+
import { useParentHomeGet as E } from "../api/parent-home.js";
|
|
3
|
+
import { formatDate as H } from "../../../node_modules/date-fns/format.js";
|
|
4
|
+
const O = (r) => {
|
|
5
|
+
const { data: t, isProcessingFailed: n } = E(r);
|
|
6
|
+
return M(() => {
|
|
7
|
+
var m;
|
|
8
|
+
const { teacher_details: o = null, session_details: s } = t ?? {};
|
|
9
|
+
if (!s)
|
|
21
10
|
return {
|
|
22
11
|
sessionDetails: null,
|
|
23
12
|
teacherDetails: null,
|
|
@@ -30,38 +19,36 @@ const k = (s) => {
|
|
|
30
19
|
nextSessionStart: 0,
|
|
31
20
|
upcomingSessions: [],
|
|
32
21
|
showLoading: !0,
|
|
33
|
-
isProcessingFailed:
|
|
34
|
-
fetchData: e
|
|
22
|
+
isProcessingFailed: n
|
|
35
23
|
};
|
|
36
24
|
const {
|
|
37
|
-
completed_sessions:
|
|
38
|
-
next_session_end:
|
|
39
|
-
next_session_start:
|
|
40
|
-
demo_class_status:
|
|
41
|
-
upcoming_sessions:
|
|
42
|
-
student_demo_id:
|
|
43
|
-
user_attempt_id:
|
|
44
|
-
} =
|
|
25
|
+
completed_sessions: e = 0,
|
|
26
|
+
next_session_end: l,
|
|
27
|
+
next_session_start: a,
|
|
28
|
+
demo_class_status: d,
|
|
29
|
+
upcoming_sessions: c = [],
|
|
30
|
+
student_demo_id: u = null,
|
|
31
|
+
user_attempt_id: p = null
|
|
32
|
+
} = s, { first_name: S = "", last_name: _ = "" } = o ?? {}, D = (m = `${S} ${_}`) == null ? void 0 : m.trim(), i = e > 0, f = i && e === 1, h = e > 1, x = H(a, "EEEE, MMM d 'at' h:mm a");
|
|
45
33
|
return {
|
|
46
|
-
sessionDetails:
|
|
47
|
-
teacherDetails:
|
|
48
|
-
teacherName:
|
|
49
|
-
completedSessions:
|
|
50
|
-
nextSessionEnd:
|
|
51
|
-
nextSessionStart:
|
|
52
|
-
classStatus:
|
|
53
|
-
upcomingSessions:
|
|
54
|
-
isDemoDone:
|
|
55
|
-
isOnlyOneSessionCompleted:
|
|
56
|
-
isMoreThanOneSessionCompleted:
|
|
57
|
-
demoId:
|
|
58
|
-
userAttemptId:
|
|
59
|
-
|
|
60
|
-
formattedNextSessionStart: C
|
|
34
|
+
sessionDetails: s,
|
|
35
|
+
teacherDetails: o,
|
|
36
|
+
teacherName: D,
|
|
37
|
+
completedSessions: e,
|
|
38
|
+
nextSessionEnd: l,
|
|
39
|
+
nextSessionStart: a,
|
|
40
|
+
classStatus: d,
|
|
41
|
+
upcomingSessions: c,
|
|
42
|
+
isDemoDone: i,
|
|
43
|
+
isOnlyOneSessionCompleted: f,
|
|
44
|
+
isMoreThanOneSessionCompleted: h,
|
|
45
|
+
demoId: u,
|
|
46
|
+
userAttemptId: p,
|
|
47
|
+
formattedNextSessionStart: x
|
|
61
48
|
};
|
|
62
|
-
}, [
|
|
63
|
-
};
|
|
49
|
+
}, [n, t]);
|
|
50
|
+
}, y = O;
|
|
64
51
|
export {
|
|
65
|
-
|
|
52
|
+
y as default
|
|
66
53
|
};
|
|
67
54
|
//# sourceMappingURL=use-parent-home-data.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"use-parent-home-data.js","sources":["../../../../src/features/parent-dashboard/hooks/use-parent-home-data.ts"],"sourcesContent":["import type { TSession } from '../../trial-session/comps/pla/upcoming-sessions/upcoming-sessions-types';\nimport type { EClassStatus, ISessionDetails, ITeacherDetails } from '../parent-dashboard-types';\n\nimport { format } from 'date-fns';\nimport {
|
|
1
|
+
{"version":3,"file":"use-parent-home-data.js","sources":["../../../../src/features/parent-dashboard/hooks/use-parent-home-data.ts"],"sourcesContent":["import type { TSession } from '../../trial-session/comps/pla/upcoming-sessions/upcoming-sessions-types';\nimport type { EClassStatus, ISessionDetails, ITeacherDetails } from '../parent-dashboard-types';\n\nimport { format } from 'date-fns';\nimport { useMemo } from 'react';\n\nimport { useParentHomeGet } from '../api/parent-home';\n\ninterface IUseParentHomeDataReturn {\n sessionDetails: ISessionDetails | null;\n teacherDetails: ITeacherDetails | null;\n completedSessions: number;\n nextSessionEnd: number;\n nextSessionStart: number;\n classStatus?: EClassStatus | null;\n teacherName?: string;\n upcomingSessions?: TSession[];\n isDemoDone: boolean;\n isOnlyOneSessionCompleted: boolean;\n isMoreThanOneSessionCompleted: boolean;\n showLoading?: boolean;\n demoId?: string | null;\n userAttemptId?: string | null;\n isProcessingFailed?: boolean;\n formattedNextSessionStart?: string;\n}\n/**\n * Hook to consume processed parent home data.\n * - Automatically fetches on mount and when stale using useFetchParentHome() at <ParentRoutesWrapper/>.\n * - Use this to **read** parent home data.\n */\n\nconst useParentHomeData = (studentId: string): IUseParentHomeDataReturn => {\n const { data: parentHomeData, isProcessingFailed } = useParentHomeGet(studentId);\n\n const parentHomeDataMemoised = useMemo(() => {\n const { teacher_details: teacherDetails = null, session_details: sessionDetails } =\n parentHomeData ?? {};\n\n if (!sessionDetails) {\n return {\n sessionDetails: null,\n teacherDetails: null,\n isOnlyOneSessionCompleted: false,\n isMoreThanOneSessionCompleted: false,\n isDemoDone: false,\n isSubscriptionCancelled: false,\n completedSessions: 0,\n nextSessionEnd: 0,\n nextSessionStart: 0,\n upcomingSessions: [],\n showLoading: true,\n isProcessingFailed,\n };\n }\n\n const {\n completed_sessions: completedSessions = 0,\n next_session_end: nextSessionEnd,\n next_session_start: nextSessionStart,\n demo_class_status: classStatus,\n upcoming_sessions: upcomingSessions = [],\n student_demo_id: demoId = null,\n user_attempt_id: userAttemptId = null,\n } = sessionDetails;\n\n const { first_name = '', last_name = '' } = teacherDetails ?? {};\n const teacherName = `${first_name} ${last_name}`?.trim();\n\n const isDemoDone = completedSessions > 0;\n const isOnlyOneSessionCompleted = isDemoDone && completedSessions === 1;\n const isMoreThanOneSessionCompleted = completedSessions > 1;\n\n const formattedNextSessionStart = format(nextSessionStart, \"EEEE, MMM d 'at' h:mm a\");\n\n return {\n sessionDetails,\n teacherDetails,\n teacherName,\n completedSessions,\n nextSessionEnd,\n nextSessionStart,\n classStatus,\n upcomingSessions,\n isDemoDone,\n isOnlyOneSessionCompleted,\n isMoreThanOneSessionCompleted,\n demoId,\n userAttemptId,\n formattedNextSessionStart,\n };\n }, [isProcessingFailed, parentHomeData]);\n\n return parentHomeDataMemoised;\n};\n\nexport default useParentHomeData;\n"],"names":["useParentHomeData","studentId","parentHomeData","isProcessingFailed","useParentHomeGet","useMemo","teacherDetails","sessionDetails","completedSessions","nextSessionEnd","nextSessionStart","classStatus","upcomingSessions","demoId","userAttemptId","first_name","last_name","teacherName","_a","isDemoDone","isOnlyOneSessionCompleted","isMoreThanOneSessionCompleted","formattedNextSessionStart","format","useParentHomeData$1"],"mappings":";;;AAgCA,MAAMA,IAAoB,CAACC,MAAgD;AACzE,QAAM,EAAE,MAAMC,GAAgB,oBAAAC,EAAmB,IAAIC,EAAiBH,CAAS;AA4DxE,SA1DwBI,EAAQ,MAAM;;AACrC,UAAA,EAAE,iBAAiBC,IAAiB,MAAM,iBAAiBC,EAAe,IAC9EL,KAAkB;AAEpB,QAAI,CAACK;AACI,aAAA;AAAA,QACL,gBAAgB;AAAA,QAChB,gBAAgB;AAAA,QAChB,2BAA2B;AAAA,QAC3B,+BAA+B;AAAA,QAC/B,YAAY;AAAA,QACZ,yBAAyB;AAAA,QACzB,mBAAmB;AAAA,QACnB,gBAAgB;AAAA,QAChB,kBAAkB;AAAA,QAClB,kBAAkB,CAAC;AAAA,QACnB,aAAa;AAAA,QACb,oBAAAJ;AAAA,MAAA;AAIE,UAAA;AAAA,MACJ,oBAAoBK,IAAoB;AAAA,MACxC,kBAAkBC;AAAA,MAClB,oBAAoBC;AAAA,MACpB,mBAAmBC;AAAA,MACnB,mBAAmBC,IAAmB,CAAC;AAAA,MACvC,iBAAiBC,IAAS;AAAA,MAC1B,iBAAiBC,IAAgB;AAAA,IAC/B,IAAAP,GAEE,EAAE,YAAAQ,IAAa,IAAI,WAAAC,IAAY,GAAG,IAAIV,KAAkB,IACxDW,KAAcC,IAAA,GAAGH,CAAU,IAAIC,CAAS,OAA1B,gBAAAE,EAA8B,QAE5CC,IAAaX,IAAoB,GACjCY,IAA4BD,KAAcX,MAAsB,GAChEa,IAAgCb,IAAoB,GAEpDc,IAA4BC,EAAOb,GAAkB,yBAAyB;AAE7E,WAAA;AAAA,MACL,gBAAAH;AAAA,MACA,gBAAAD;AAAA,MACA,aAAAW;AAAA,MACA,mBAAAT;AAAA,MACA,gBAAAC;AAAA,MACA,kBAAAC;AAAA,MACA,aAAAC;AAAA,MACA,kBAAAC;AAAA,MACA,YAAAO;AAAA,MACA,2BAAAC;AAAA,MACA,+BAAAC;AAAA,MACA,QAAAR;AAAA,MACA,eAAAC;AAAA,MACA,2BAAAQ;AAAA,IAAA;AAAA,EACF,GACC,CAACnB,GAAoBD,CAAc,CAAC;AAGzC,GAEAsB,IAAexB;"}
|
|
@@ -1,22 +1,24 @@
|
|
|
1
1
|
import o from "styled-components";
|
|
2
2
|
import t from "../../../ui/layout/flex-view.js";
|
|
3
3
|
const s = o(t)`
|
|
4
|
-
max-width: 560px;
|
|
5
4
|
border: ${({ theme: e }) => `1px solid ${e.colors.BLACK_5}`};
|
|
6
|
-
|
|
5
|
+
${({ theme: e }) => e.mediaQueries.minWidthTablet} {
|
|
6
|
+
max-width: 560px;
|
|
7
|
+
}
|
|
8
|
+
`, h = o(t)`
|
|
7
9
|
overflow-y: auto;
|
|
8
10
|
max-height: 468px;
|
|
9
11
|
${({ theme: e }) => e.mediaQueries.minWidthTablet} {
|
|
10
12
|
max-height: unset;
|
|
11
13
|
overflow-y: hidden;
|
|
12
14
|
})}
|
|
13
|
-
`,
|
|
15
|
+
`, m = o(t)`
|
|
14
16
|
padding-top: 0;
|
|
15
17
|
${({ theme: e }) => e.mediaQueries.minWidthTablet} {
|
|
16
18
|
max-height: 300px;
|
|
17
19
|
overflow-y: auto;
|
|
18
20
|
})}
|
|
19
|
-
`,
|
|
21
|
+
`, x = o(t)`
|
|
20
22
|
padding-bottom: 24px;
|
|
21
23
|
${({ theme: e }) => e.mediaQueries.minWidthTablet} {
|
|
22
24
|
border-top: ${({ theme: e }) => `1px solid ${e.colors.BLACK_5}`};
|
|
@@ -25,11 +27,11 @@ const s = o(t)`
|
|
|
25
27
|
`, c = o.textarea(({ theme: e }) => {
|
|
26
28
|
const {
|
|
27
29
|
colors: { WHITE: i, WHITE_T_38: r, BLACK_2: n, BLACK_5: a },
|
|
28
|
-
layout: { gutter:
|
|
30
|
+
layout: { gutter: d }
|
|
29
31
|
} = e;
|
|
30
32
|
return `border: 1px solid ${a};
|
|
31
33
|
width: 100%;
|
|
32
|
-
min-height: ${
|
|
34
|
+
min-height: ${d * 5}px;
|
|
33
35
|
padding: 16px;
|
|
34
36
|
background-color: ${n};
|
|
35
37
|
white-space: pre-line;
|
|
@@ -51,9 +53,9 @@ const s = o(t)`
|
|
|
51
53
|
});
|
|
52
54
|
export {
|
|
53
55
|
s as Container,
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
56
|
+
m as ContentWrapper,
|
|
57
|
+
x as FooterWrapper,
|
|
58
|
+
h as OuterWrapper,
|
|
57
59
|
c as StyledTextArea
|
|
58
60
|
};
|
|
59
61
|
//# sourceMappingURL=tutor-change-styled.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tutor-change-styled.js","sources":["../../../../../src/features/parent-dashboard/modals/tutor-change/tutor-change-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport FlexView from '../../../ui/layout/flex-view';\n\nexport const Container = styled(FlexView)`\n
|
|
1
|
+
{"version":3,"file":"tutor-change-styled.js","sources":["../../../../../src/features/parent-dashboard/modals/tutor-change/tutor-change-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport FlexView from '../../../ui/layout/flex-view';\n\nexport const Container = styled(FlexView)`\n border: ${({ theme }) => `1px solid ${theme.colors.BLACK_5}`};\n ${({ theme }) => theme.mediaQueries.minWidthTablet} {\n max-width: 560px;\n }\n`;\n\nexport const OuterWrapper = styled(FlexView)`\n overflow-y: auto;\n max-height: 468px;\n ${({ theme }) => theme.mediaQueries.minWidthTablet} {\n max-height: unset;\n overflow-y: hidden;\n })}\n`;\n\nexport const ContentWrapper = styled(FlexView)`\n padding-top: 0;\n ${({ theme }) => theme.mediaQueries.minWidthTablet} {\n max-height: 300px;\n overflow-y: auto;\n })}\n`;\n\nexport const FooterWrapper = styled(FlexView)`\n padding-bottom: 24px;\n ${({ theme }) => theme.mediaQueries.minWidthTablet} {\n border-top: ${({ theme }) => `1px solid ${theme.colors.BLACK_5}`};\n padding-bottom: 40px;\n })}\n`;\n\nexport const StyledTextArea = styled.textarea(({ theme }) => {\n const {\n colors: { WHITE, WHITE_T_38, BLACK_2, BLACK_5 },\n layout: { gutter },\n } = theme;\n\n return `border: 1px solid ${BLACK_5};\n width: 100%;\n min-height: ${gutter * 5}px;\n padding: 16px;\n background-color: ${BLACK_2};\n white-space: pre-line;\n font-family: 'Untitled Sans Regular';\n font-weight: 400;\n font-size: 14px;\n line-height: 24px;\n color: ${WHITE};\n resize: none;\n outline: none;\n &::placeholder {\n color: ${WHITE_T_38};\n }\n\n &:focus {\n outline: none;\n }\n`;\n});\n"],"names":["Container","styled","FlexView","theme","OuterWrapper","ContentWrapper","FooterWrapper","StyledTextArea","WHITE","WHITE_T_38","BLACK_2","BLACK_5","gutter"],"mappings":";;AAIa,MAAAA,IAAYC,EAAOC,CAAQ;AAAA,YAC5B,CAAC,EAAE,OAAAC,EAAM,MAAM,aAAaA,EAAM,OAAO,OAAO,EAAE;AAAA,IAC1D,CAAC,EAAE,OAAAA,EAAA,MAAYA,EAAM,aAAa,cAAc;AAAA;AAAA;AAAA,GAKvCC,IAAeH,EAAOC,CAAQ;AAAA;AAAA;AAAA,IAGvC,CAAC,EAAE,OAAAC,EAAA,MAAYA,EAAM,aAAa,cAAc;AAAA;AAAA;AAAA;AAAA,GAMvCE,IAAiBJ,EAAOC,CAAQ;AAAA;AAAA,IAEzC,CAAC,EAAE,OAAAC,EAAA,MAAYA,EAAM,aAAa,cAAc;AAAA;AAAA;AAAA;AAAA,GAMvCG,IAAgBL,EAAOC,CAAQ;AAAA;AAAA,IAExC,CAAC,EAAE,OAAAC,EAAA,MAAYA,EAAM,aAAa,cAAc;AAAA,kBAClC,CAAC,EAAE,OAAAA,EAAM,MAAM,aAAaA,EAAM,OAAO,OAAO,EAAE;AAAA;AAAA;AAAA,GAKvDI,IAAiBN,EAAO,SAAS,CAAC,EAAE,OAAAE,QAAY;AACrD,QAAA;AAAA,IACJ,QAAQ,EAAE,OAAAK,GAAO,YAAAC,GAAY,SAAAC,GAAS,SAAAC,EAAQ;AAAA,IAC9C,QAAQ,EAAE,QAAAC,EAAO;AAAA,EACf,IAAAT;AAEJ,SAAO,qBAAqBQ,CAAO;AAAA;AAAA,gBAErBC,IAAS,CAAC;AAAA;AAAA,sBAEJF,CAAO;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,WAMlBF,CAAK;AAAA;AAAA;AAAA;AAAA,aAIHC,CAAU;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOvB,CAAC;"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { jsxs as i, jsx as r } from "react/jsx-runtime";
|
|
2
|
-
import { memo as R, useState as
|
|
2
|
+
import { memo as R, useState as h, useRef as w, useCallback as u, useEffect as A } from "react";
|
|
3
3
|
import { useTheme as E } from "styled-components";
|
|
4
4
|
import O from "../../../auth/comps/pill-button/pill-button.js";
|
|
5
|
-
import
|
|
5
|
+
import p from "../../../ui/buttons/text-button/text-button.js";
|
|
6
6
|
import I from "../../../ui/layout/flex-view.js";
|
|
7
7
|
import X from "../../../ui/modals/use-modal-actions.js";
|
|
8
8
|
import S from "../../../ui/modals/use-modal-params.js";
|
|
@@ -11,10 +11,10 @@ import { EDeviceType as k } from "../../../ui/theme/constants.js";
|
|
|
11
11
|
import { changeTutorReasons as M, TUTOR_CHANGE_REASON_IDS as v } from "./tutor-change-constants.js";
|
|
12
12
|
import { Container as B, OuterWrapper as H, ContentWrapper as _, StyledTextArea as D, FooterWrapper as y } from "./tutor-change-styled.js";
|
|
13
13
|
const G = () => {
|
|
14
|
-
const { device: f } = E(), [n, C] =
|
|
14
|
+
const { device: f } = E(), [n, C] = h(""), [l, $] = h(""), o = f <= k.MOBILE, { closeModal: c } = X(), a = w(null), { onContinue: m, demoId: d } = S(), x = u((e) => C(e), []), b = u((e) => {
|
|
15
15
|
$(e.target.value);
|
|
16
16
|
}, []), t = n === v.OTHER, T = !n || t && !l.trim(), g = u(() => {
|
|
17
|
-
c(), m(d, n, t ? l : "");
|
|
17
|
+
c(), m({ demoId: d, reason: n, otherReason: t ? l : "" });
|
|
18
18
|
}, [c, m, d, n, t, l]);
|
|
19
19
|
return A(() => {
|
|
20
20
|
var e, s;
|
|
@@ -66,7 +66,7 @@ const G = () => {
|
|
|
66
66
|
$flexColumnGapX: 1.5,
|
|
67
67
|
children: [
|
|
68
68
|
/* @__PURE__ */ r(
|
|
69
|
-
|
|
69
|
+
p,
|
|
70
70
|
{
|
|
71
71
|
label: "Continue",
|
|
72
72
|
onClick: g,
|
|
@@ -74,7 +74,7 @@ const G = () => {
|
|
|
74
74
|
disabled: T
|
|
75
75
|
}
|
|
76
76
|
),
|
|
77
|
-
/* @__PURE__ */ r(
|
|
77
|
+
/* @__PURE__ */ r(p, { label: "Close", onClick: c, color: "WHITE" })
|
|
78
78
|
]
|
|
79
79
|
}
|
|
80
80
|
)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tutor-change.js","sources":["../../../../../src/features/parent-dashboard/modals/tutor-change/tutor-change.tsx"],"sourcesContent":["import type { ITutorChangeModalParams } from './tutor-change-types';\n\nimport { memo, useCallback, useEffect, useRef, useState, type ChangeEvent } from 'react';\nimport { useTheme } from 'styled-components';\n\nimport PillButton from '../../../auth/comps/pill-button/pill-button';\nimport TextButton from '../../../ui/buttons/text-button/text-button';\nimport FlexView from '../../../ui/layout/flex-view';\nimport useModalActions from '../../../ui/modals/use-modal-actions';\nimport useModalParams from '../../../ui/modals/use-modal-params';\nimport Text from '../../../ui/text/text';\nimport { EDeviceType } from '../../../ui/theme/constants';\nimport { TUTOR_CHANGE_REASON_IDS, changeTutorReasons } from './tutor-change-constants';\nimport * as Styled from './tutor-change-styled';\n\nconst TutorChange = () => {\n const { device } = useTheme();\n const [reason, setReason] = useState('');\n const [otherReason, setOtherReason] = useState('');\n const isMobile = device <= EDeviceType.MOBILE;\n const { closeModal } = useModalActions();\n const textAreaRef = useRef<HTMLTextAreaElement | null>(null);\n const { onContinue, demoId } = useModalParams<ITutorChangeModalParams>();\n const handleSelectReason = useCallback((id: string) => setReason(id), []);\n\n const handleOtherReasonChange = useCallback((event: ChangeEvent<HTMLTextAreaElement>) => {\n setOtherReason(event.target.value);\n }, []);\n const isOtherReasonSelected = reason === TUTOR_CHANGE_REASON_IDS.OTHER;\n const isSubmitDisabled = !reason || (isOtherReasonSelected && !otherReason.trim());\n\n const handleContinue = useCallback(() => {\n closeModal();\n onContinue(demoId, reason, isOtherReasonSelected ? otherReason : '');\n }, [closeModal, onContinue, demoId, reason, isOtherReasonSelected, otherReason]);\n\n useEffect(() => {\n if (isOtherReasonSelected && textAreaRef.current) {\n textAreaRef.current?.scrollIntoView({ behavior: 'smooth' });\n textAreaRef.current?.focus();\n }\n }, [isOtherReasonSelected]);\n\n return (\n <Styled.Container $background=\"BLACK_2\" $width=\"100%\" $borderColor=\"BLACK_5\">\n <Styled.OuterWrapper $flex={1}>\n <FlexView $gutterX={isMobile ? 1 : 2.5} $gapX={isMobile ? 1.5 : 2.5}>\n <Text $renderAs=\"ah4-bold\" $renderOnMobileAs=\"ab1-bold\" $color=\"WHITE\">\n What didn't work well with the current tutor?\n </Text>\n </FlexView>\n <Styled.ContentWrapper\n $flex={1}\n $gutterX={isMobile ? 1 : 2.5}\n $gapX={isMobile ? 1 : 2.5}\n $width={'100%'}\n $alignItems=\"flex-start\"\n $flexRowGapX={1}\n >\n {changeTutorReasons.map(({ id, label }) => (\n <PillButton\n selected={reason === id}\n key={id}\n label={label}\n id={id}\n onClick={handleSelectReason}\n isTransparent\n />\n ))}\n {isOtherReasonSelected && (\n <Styled.StyledTextArea\n placeholder=\"Tell us more about your experience...\"\n id=\"text-area\"\n ref={textAreaRef}\n value={otherReason}\n onChange={handleOtherReasonChange}\n />\n )}\n </Styled.ContentWrapper>\n </Styled.OuterWrapper>\n <Styled.FooterWrapper\n $gutterX={isMobile ? 1 : 2.5}\n $gapX={isMobile ? 1 : 2.5}\n $flexDirection=\"row\"\n $flexColumnGapX={1.5}\n >\n <TextButton\n label=\"Continue\"\n onClick={handleContinue}\n color=\"WHITE\"\n disabled={isSubmitDisabled}\n />\n <TextButton label=\"Close\" onClick={closeModal} color=\"WHITE\" />\n </Styled.FooterWrapper>\n </Styled.Container>\n );\n};\n\nexport default memo(TutorChange);\n"],"names":["TutorChange","device","useTheme","reason","setReason","useState","otherReason","setOtherReason","isMobile","EDeviceType","closeModal","useModalActions","textAreaRef","useRef","onContinue","demoId","useModalParams","handleSelectReason","useCallback","id","handleOtherReasonChange","event","isOtherReasonSelected","TUTOR_CHANGE_REASON_IDS","isSubmitDisabled","handleContinue","useEffect","_a","_b","jsxs","Styled.Container","Styled.OuterWrapper","jsx","FlexView","Text","Styled.ContentWrapper","changeTutorReasons","label","PillButton","Styled.StyledTextArea","Styled.FooterWrapper","TextButton","tutorChange","memo"],"mappings":";;;;;;;;;;;;AAeA,MAAMA,IAAc,MAAM;AAClB,QAAA,EAAE,QAAAC,MAAWC,KACb,CAACC,GAAQC,CAAS,IAAIC,EAAS,EAAE,GACjC,CAACC,GAAaC,CAAc,IAAIF,EAAS,EAAE,GAC3CG,IAAWP,KAAUQ,EAAY,QACjC,EAAE,YAAAC,MAAeC,KACjBC,IAAcC,EAAmC,IAAI,GACrD,EAAE,YAAAC,GAAY,QAAAC,EAAO,IAAIC,EAAwC,GACjEC,IAAqBC,EAAY,CAACC,MAAef,EAAUe,CAAE,GAAG,CAAA,CAAE,GAElEC,IAA0BF,EAAY,CAACG,MAA4C;AACxE,IAAAd,EAAAc,EAAM,OAAO,KAAK;AAAA,EACnC,GAAG,CAAE,CAAA,GACCC,IAAwBnB,MAAWoB,EAAwB,OAC3DC,IAAmB,CAACrB,KAAWmB,KAAyB,CAAChB,EAAY,QAErEmB,IAAiBP,EAAY,MAAM;AAC5B,IAAAR,KACXI,
|
|
1
|
+
{"version":3,"file":"tutor-change.js","sources":["../../../../../src/features/parent-dashboard/modals/tutor-change/tutor-change.tsx"],"sourcesContent":["import type { ITutorChangeModalParams } from './tutor-change-types';\n\nimport { memo, useCallback, useEffect, useRef, useState, type ChangeEvent } from 'react';\nimport { useTheme } from 'styled-components';\n\nimport PillButton from '../../../auth/comps/pill-button/pill-button';\nimport TextButton from '../../../ui/buttons/text-button/text-button';\nimport FlexView from '../../../ui/layout/flex-view';\nimport useModalActions from '../../../ui/modals/use-modal-actions';\nimport useModalParams from '../../../ui/modals/use-modal-params';\nimport Text from '../../../ui/text/text';\nimport { EDeviceType } from '../../../ui/theme/constants';\nimport { TUTOR_CHANGE_REASON_IDS, changeTutorReasons } from './tutor-change-constants';\nimport * as Styled from './tutor-change-styled';\n\nconst TutorChange = () => {\n const { device } = useTheme();\n const [reason, setReason] = useState('');\n const [otherReason, setOtherReason] = useState('');\n const isMobile = device <= EDeviceType.MOBILE;\n const { closeModal } = useModalActions();\n const textAreaRef = useRef<HTMLTextAreaElement | null>(null);\n const { onContinue, demoId } = useModalParams<ITutorChangeModalParams>();\n const handleSelectReason = useCallback((id: string) => setReason(id), []);\n\n const handleOtherReasonChange = useCallback((event: ChangeEvent<HTMLTextAreaElement>) => {\n setOtherReason(event.target.value);\n }, []);\n const isOtherReasonSelected = reason === TUTOR_CHANGE_REASON_IDS.OTHER;\n const isSubmitDisabled = !reason || (isOtherReasonSelected && !otherReason.trim());\n\n const handleContinue = useCallback(() => {\n closeModal();\n onContinue({ demoId, reason, otherReason: isOtherReasonSelected ? otherReason : '' });\n }, [closeModal, onContinue, demoId, reason, isOtherReasonSelected, otherReason]);\n\n useEffect(() => {\n if (isOtherReasonSelected && textAreaRef.current) {\n textAreaRef.current?.scrollIntoView({ behavior: 'smooth' });\n textAreaRef.current?.focus();\n }\n }, [isOtherReasonSelected]);\n\n return (\n <Styled.Container $background=\"BLACK_2\" $width=\"100%\" $borderColor=\"BLACK_5\">\n <Styled.OuterWrapper $flex={1}>\n <FlexView $gutterX={isMobile ? 1 : 2.5} $gapX={isMobile ? 1.5 : 2.5}>\n <Text $renderAs=\"ah4-bold\" $renderOnMobileAs=\"ab1-bold\" $color=\"WHITE\">\n What didn't work well with the current tutor?\n </Text>\n </FlexView>\n <Styled.ContentWrapper\n $flex={1}\n $gutterX={isMobile ? 1 : 2.5}\n $gapX={isMobile ? 1 : 2.5}\n $width={'100%'}\n $alignItems=\"flex-start\"\n $flexRowGapX={1}\n >\n {changeTutorReasons.map(({ id, label }) => (\n <PillButton\n selected={reason === id}\n key={id}\n label={label}\n id={id}\n onClick={handleSelectReason}\n isTransparent\n />\n ))}\n {isOtherReasonSelected && (\n <Styled.StyledTextArea\n placeholder=\"Tell us more about your experience...\"\n id=\"text-area\"\n ref={textAreaRef}\n value={otherReason}\n onChange={handleOtherReasonChange}\n />\n )}\n </Styled.ContentWrapper>\n </Styled.OuterWrapper>\n <Styled.FooterWrapper\n $gutterX={isMobile ? 1 : 2.5}\n $gapX={isMobile ? 1 : 2.5}\n $flexDirection=\"row\"\n $flexColumnGapX={1.5}\n >\n <TextButton\n label=\"Continue\"\n onClick={handleContinue}\n color=\"WHITE\"\n disabled={isSubmitDisabled}\n />\n <TextButton label=\"Close\" onClick={closeModal} color=\"WHITE\" />\n </Styled.FooterWrapper>\n </Styled.Container>\n );\n};\n\nexport default memo(TutorChange);\n"],"names":["TutorChange","device","useTheme","reason","setReason","useState","otherReason","setOtherReason","isMobile","EDeviceType","closeModal","useModalActions","textAreaRef","useRef","onContinue","demoId","useModalParams","handleSelectReason","useCallback","id","handleOtherReasonChange","event","isOtherReasonSelected","TUTOR_CHANGE_REASON_IDS","isSubmitDisabled","handleContinue","useEffect","_a","_b","jsxs","Styled.Container","Styled.OuterWrapper","jsx","FlexView","Text","Styled.ContentWrapper","changeTutorReasons","label","PillButton","Styled.StyledTextArea","Styled.FooterWrapper","TextButton","tutorChange","memo"],"mappings":"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"}
|
|
@@ -15,7 +15,7 @@ const a = o(t)`
|
|
|
15
15
|
background: ${r.colors.BLACK_5};
|
|
16
16
|
}
|
|
17
17
|
${r.mediaQueries.minWidthTablet} {
|
|
18
|
-
max-height:
|
|
18
|
+
max-height: 100dvh;
|
|
19
19
|
&::-webkit-scrollbar {
|
|
20
20
|
width: 6px;
|
|
21
21
|
}
|
|
@@ -23,7 +23,7 @@ const a = o(t)`
|
|
|
23
23
|
`
|
|
24
24
|
), c = o(t)`
|
|
25
25
|
overflow: hidden;
|
|
26
|
-
height:
|
|
26
|
+
height: 100dvh;
|
|
27
27
|
`;
|
|
28
28
|
export {
|
|
29
29
|
c as Container,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parent-dashboard-styled.js","sources":["../../../src/features/parent-dashboard/parent-dashboard-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport FlexView from '../ui/layout/flex-view';\n\nexport const MathPracticeWrapper = styled(FlexView)`\n margin: 0 -16px;\n`;\n\nexport const ContentWrapper = styled(FlexView)(\n ({ theme }) => `\n overflow-y: auto;\n &::-webkit-scrollbar {\n width: 3px;\n }\n &::-webkit-scrollbar-track {\n background: ${theme.colors.BLACK_2};\n }\n &::-webkit-scrollbar-thumb {\n background: ${theme.colors.BLACK_5};\n }\n ${theme.mediaQueries.minWidthTablet} {\n max-height:
|
|
1
|
+
{"version":3,"file":"parent-dashboard-styled.js","sources":["../../../src/features/parent-dashboard/parent-dashboard-styled.tsx"],"sourcesContent":["import styled from 'styled-components';\n\nimport FlexView from '../ui/layout/flex-view';\n\nexport const MathPracticeWrapper = styled(FlexView)`\n margin: 0 -16px;\n`;\n\nexport const ContentWrapper = styled(FlexView)(\n ({ theme }) => `\n overflow-y: auto;\n &::-webkit-scrollbar {\n width: 3px;\n }\n &::-webkit-scrollbar-track {\n background: ${theme.colors.BLACK_2};\n }\n &::-webkit-scrollbar-thumb {\n background: ${theme.colors.BLACK_5};\n }\n ${theme.mediaQueries.minWidthTablet} {\n max-height: 100dvh;\n &::-webkit-scrollbar {\n width: 6px;\n }\n }\n`,\n);\n\nexport const Container = styled(FlexView)`\n overflow: hidden;\n height: 100dvh;\n`;\n"],"names":["MathPracticeWrapper","styled","FlexView","ContentWrapper","theme","Container"],"mappings":";;AAIa,MAAAA,IAAsBC,EAAOC,CAAQ;AAAA;AAAA,GAIrCC,IAAiBF,EAAOC,CAAQ;AAAA,EAC3C,CAAC,EAAE,OAAAE,EAAA,MAAY;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,kBAMCA,EAAM,OAAO,OAAO;AAAA;AAAA;AAAA,kBAGpBA,EAAM,OAAO,OAAO;AAAA;AAAA,IAElCA,EAAM,aAAa,cAAc;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA;AAOrC,GAEaC,IAAYJ,EAAOC,CAAQ;AAAA;AAAA;AAAA;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"parent-dashboard-types.js","sources":["../../../src/features/parent-dashboard/parent-dashboard-types.ts"],"sourcesContent":["import type { TSession } from '../trial-session/comps/pla/upcoming-sessions/upcoming-sessions-types';\nimport type { ReactElement } from 'react';\n\nexport enum EClassStatus {\n S_NO_SHOW = 'S_NO_SHOW',\n T_NO_SHOW = 'T_NO_SHOW',\n}\nexport interface ISessionDetails {\n completed_sessions: number;\n next_session_start: number;\n next_session_end: number;\n student_demo_id: string;\n upcoming_sessions: TSession[];\n demo_class_status: EClassStatus | null;\n user_attempt_id?: string;\n}\n\ninterface IDegreeInfo {\n degree_name: string;\n degree_code: string;\n field_of_study: string;\n}\nexport interface ITeacherDetails {\n first_name: string;\n last_name: string;\n years_of_experience: number;\n number_of_students_taught: number;\n lower_grade: string;\n higher_grade: string;\n degree: IDegreeInfo;\n countries: string[];\n teacher_profile_url: string;\n header_image: string;\n}\n\ninterface PaymentMethodDetails {\n brand: string;\n last_4_digits: string;\n type: string;\n exp_month: number;\n exp_year: number;\n}\n\ninterface IBillingDetails {\n amount: number;\n next_due_date: string;\n payment_method_details: PaymentMethodDetails;\n}\n\nexport interface IParentHome {\n session_details: ISessionDetails;\n teacher_details: ITeacherDetails | null;\n billing_details: IBillingDetails;\n}\n\nexport interface IStudentProfileSummary {\n studentLevel: string;\n studentObjectives: string[] | string;\n learningPlan: string[] | string;\n levelPreference?: string;\n}\n\nexport interface IOnViewSummaryParams extends IStudentProfileSummary {\n userAttemptId?: string;\n}\nexport enum ESummaryType {\n STUDENT_PROFILE = 'studentProfile',\n INSIGHTS = 'insights',\n LEARNING_PLAN = 'learningPlan',\n}\n\nexport interface IParentDashboardProps {\n studentName: string;\n studentId: string;\n onRescheduleDemo: (demoId?: string) => void;\n onChangeTutor: (demoId
|
|
1
|
+
{"version":3,"file":"parent-dashboard-types.js","sources":["../../../src/features/parent-dashboard/parent-dashboard-types.ts"],"sourcesContent":["import type { TSession } from '../trial-session/comps/pla/upcoming-sessions/upcoming-sessions-types';\nimport type { ReactElement } from 'react';\n\nexport enum EClassStatus {\n S_NO_SHOW = 'S_NO_SHOW',\n T_NO_SHOW = 'T_NO_SHOW',\n}\nexport interface ISessionDetails {\n completed_sessions: number;\n next_session_start: number;\n next_session_end: number;\n student_demo_id: string;\n upcoming_sessions: TSession[];\n demo_class_status: EClassStatus | null;\n user_attempt_id?: string;\n}\n\ninterface IDegreeInfo {\n degree_name: string;\n degree_code: string;\n field_of_study: string;\n}\nexport interface ITeacherDetails {\n first_name: string;\n last_name: string;\n years_of_experience: number;\n number_of_students_taught: number;\n lower_grade: string;\n higher_grade: string;\n degree: IDegreeInfo;\n countries: string[];\n teacher_profile_url: string;\n header_image: string;\n}\n\ninterface PaymentMethodDetails {\n brand: string;\n last_4_digits: string;\n type: string;\n exp_month: number;\n exp_year: number;\n}\n\ninterface IBillingDetails {\n amount: number;\n next_due_date: string;\n payment_method_details: PaymentMethodDetails;\n}\n\nexport interface IParentHome {\n session_details: ISessionDetails;\n teacher_details: ITeacherDetails | null;\n billing_details: IBillingDetails;\n}\n\nexport interface IStudentProfileSummary {\n studentLevel: string;\n studentObjectives: string[] | string;\n learningPlan: string[] | string;\n levelPreference?: string;\n}\n\nexport interface IOnViewSummaryParams extends IStudentProfileSummary {\n userAttemptId?: string | null;\n}\nexport enum ESummaryType {\n STUDENT_PROFILE = 'studentProfile',\n INSIGHTS = 'insights',\n LEARNING_PLAN = 'learningPlan',\n}\n\nexport interface IParentDashboardProps {\n studentName: string;\n studentId: string;\n onRescheduleDemo: (demoId?: string | null) => void;\n onChangeTutor: (demoId?: string | null) => void;\n onGetStartedAgain?: () => void;\n onViewSummary?: (key: ESummaryType, summaryData: IOnViewSummaryParams) => void;\n onSwitchUser?: () => void;\n canChangeTutor: boolean;\n isSubscriptionCancelled: boolean;\n HeaderAvatar: ReactElement;\n}\n\nexport interface ISpacingConfig {\n small: number;\n medium: number;\n large: number;\n separator: {\n small: number;\n medium: number;\n large: number;\n extraLarge: number;\n };\n}\n"],"names":["EClassStatus","ESummaryType"],"mappings":"AAGY,IAAAA,sBAAAA,OACVA,EAAA,YAAY,aACZA,EAAA,YAAY,aAFFA,IAAAA,KAAA,CAAA,CAAA,GA8DAC,sBAAAA,OACVA,EAAA,kBAAkB,kBAClBA,EAAA,WAAW,YACXA,EAAA,gBAAgB,gBAHNA,IAAAA,KAAA,CAAA,CAAA;"}
|