feat: add interactive MCQ and code-sort exercise widgets to tutorial lessons
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -2,6 +2,7 @@ import { DIFFICULTY } from "utils/constants"
|
||||
import { getACRate } from "utils/functions"
|
||||
import http from "utils/http"
|
||||
import {
|
||||
Exercise,
|
||||
Problem,
|
||||
Submission,
|
||||
SubmissionListPayload,
|
||||
@@ -420,3 +421,8 @@ export function getProblemSetUserProgress(
|
||||
) {
|
||||
return http.get(`problemset/${problemSetId}/users_progress`, { params })
|
||||
}
|
||||
|
||||
export async function getExercises(tutorialId: number): Promise<Exercise[]> {
|
||||
const res = await http.get("exercises", { params: { tutorial_id: tutorialId } })
|
||||
return res.data
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user