feat(parser): parse "Задания для выполнения" column"

Now schedule can show the data in column "Задание для выполнения" under "Материалы" button
This commit is contained in:
kilyabin
2026-03-02 14:43:16 +04:00
parent da7b4fe812
commit e6ba2e0334
3 changed files with 49 additions and 16 deletions

View File

@@ -10,11 +10,12 @@ import { Lesson } from '@/shared/model/lesson'
import Link from 'next/link'
import { BiLink } from 'react-icons/bi'
export function ResourcesDialog({ open, onClose, teacherName, resources }: {
export function ResourcesDialog({ open, onClose, teacherName, resources, homework }: {
open: boolean
onClose: () => any
teacherName?: string
resources: Lesson['resources']
homework?: string
}) {
const teacherPronouns = teachers.find(t => t.name === teacherName)?.pronouns
@@ -38,6 +39,11 @@ export function ResourcesDialog({ open, onClose, teacherName, resources }: {
)}
</DialogHeader>
<div className="grid gap-4 py-4">
{homework && homework.trim() && (
<div className="text-sm whitespace-pre-wrap break-words">
{homework}
</div>
)}
{resources.map((resource, i) => <Resource resource={resource} key={i} />)}
</div>
</DialogContent>