diff --git a/apps/web/src/components/interviews/dashboard/InterviewsDashboardPage.tsx b/apps/web/src/components/interviews/dashboard/InterviewsDashboardPage.tsx index b6fdb5bdc..2b7b0cb4c 100644 --- a/apps/web/src/components/interviews/dashboard/InterviewsDashboardPage.tsx +++ b/apps/web/src/components/interviews/dashboard/InterviewsDashboardPage.tsx @@ -61,12 +61,10 @@ export default function InterviewsDashboardPage({ }: Props) { const user = useUser(); const isLoggedIn = defaultLoggedIn || !!user; - const { data: questionsProgress } = trpc.questionProgress.getAll.useQuery( - undefined, - { + const { data: questionsProgress, isLoading: isQuestionsProgressLoading } = + trpc.questionProgress.getAll.useQuery(undefined, { enabled: isLoggedIn, - }, - ); + }); const { data: questionListSessions } = trpc.questionLists.getActiveSessions.useQuery(undefined, { @@ -113,6 +111,7 @@ export default function InterviewsDashboardPage({ diff --git a/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardContributionsHeatmapCard.tsx b/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardContributionsHeatmapCard.tsx index c00b598ea..ecc8b282c 100644 --- a/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardContributionsHeatmapCard.tsx +++ b/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardContributionsHeatmapCard.tsx @@ -64,6 +64,10 @@ export default function InterviewsDashboardContributionsHeatmapCard({ /> }> diff --git a/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardProgressSection.tsx b/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardProgressSection.tsx index 23ef1d700..9a59c2fc1 100644 --- a/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardProgressSection.tsx +++ b/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardProgressSection.tsx @@ -13,6 +13,7 @@ import InterviewsDashboardSolvedProblemsCard from './InterviewsDashboardSolvedPr type Props = Readonly<{ contributions?: Record; isContributionsLoading: boolean; + isQuestionProgressLoading: boolean; questions: { codingQuestions: ReadonlyArray; quizQuestions: ReadonlyArray; @@ -28,6 +29,7 @@ export default function InterviewsDashboardProgressSection({ questions, contributions, isContributionsLoading, + isQuestionProgressLoading, }: Props) { return (
@@ -40,6 +42,7 @@ export default function InterviewsDashboardProgressSection({
diff --git a/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardSolvedProblemsCard.tsx b/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardSolvedProblemsCard.tsx index 86e7602f0..7e739a070 100644 --- a/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardSolvedProblemsCard.tsx +++ b/apps/web/src/components/interviews/dashboard/progress/InterviewsDashboardSolvedProblemsCard.tsx @@ -23,6 +23,7 @@ import { import Tooltip from '~/components/ui/Tooltip'; type Props = Readonly<{ + isQuestionProgressLoading: boolean; questions: { codingQuestions: ReadonlyArray; quizQuestions: ReadonlyArray; @@ -36,6 +37,7 @@ type Props = Readonly<{ export default function InterviewsDashboardSolvedProblemsCard({ questions, questionsProgress, + isQuestionProgressLoading, }: Props) { const intl = useIntl(); @@ -212,13 +214,23 @@ export default function InterviewsDashboardSolvedProblemsCard({ /> }> {completedCount} - + {label} - - + + {completed} /{total} @@ -252,12 +276,13 @@ export default function InterviewsDashboardSolvedProblemsCard({ backgroundClass={themeBackgroundLineEmphasizedColor} heightClass="h-1.5" label={label} - progressClass={ + progressClass={clsx( getProgressBarGradient({ total, value: completed, - }).className - } + }).className, + ['transition-all duration-1000 ease-in-out'], + )} total={total} value={completed} />