@hed-hog/lms 0.0.364 → 0.0.366
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/bitcode-wallet/bitcode-wallet.service.d.ts +1 -0
- package/dist/bitcode-wallet/bitcode-wallet.service.d.ts.map +1 -1
- package/dist/bitcode-wallet/bitcode-wallet.service.js +22 -3
- package/dist/bitcode-wallet/bitcode-wallet.service.js.map +1 -1
- package/dist/class-group/class-group.controller.d.ts +1 -0
- package/dist/class-group/class-group.controller.d.ts.map +1 -1
- package/dist/class-group/class-group.service.d.ts +1 -0
- package/dist/class-group/class-group.service.d.ts.map +1 -1
- package/dist/course/course-export-scorm12-worker.service.d.ts +21 -0
- package/dist/course/course-export-scorm12-worker.service.d.ts.map +1 -0
- package/dist/course/course-export-scorm12-worker.service.js +109 -0
- package/dist/course/course-export-scorm12-worker.service.js.map +1 -0
- package/dist/course/course-export-scorm12.service.d.ts +42 -0
- package/dist/course/course-export-scorm12.service.d.ts.map +1 -0
- package/dist/course/course-export-scorm12.service.js +628 -0
- package/dist/course/course-export-scorm12.service.js.map +1 -0
- package/dist/course/course-export.service.d.ts +84 -0
- package/dist/course/course-export.service.d.ts.map +1 -0
- package/dist/course/course-export.service.js +237 -0
- package/dist/course/course-export.service.js.map +1 -0
- package/dist/course/course-structure.controller.d.ts +20 -10
- package/dist/course/course-structure.controller.d.ts.map +1 -1
- package/dist/course/course-structure.controller.js +20 -4
- package/dist/course/course-structure.controller.js.map +1 -1
- package/dist/course/course-structure.service.d.ts +12 -4
- package/dist/course/course-structure.service.d.ts.map +1 -1
- package/dist/course/course-structure.service.js +98 -23
- package/dist/course/course-structure.service.js.map +1 -1
- package/dist/course/course-video-agent-pipeline.service.d.ts +70 -0
- package/dist/course/course-video-agent-pipeline.service.d.ts.map +1 -0
- package/dist/course/course-video-agent-pipeline.service.js +398 -0
- package/dist/course/course-video-agent-pipeline.service.js.map +1 -0
- package/dist/course/course-video-hls.service.d.ts +71 -0
- package/dist/course/course-video-hls.service.d.ts.map +1 -0
- package/dist/course/course-video-hls.service.js +784 -0
- package/dist/course/course-video-hls.service.js.map +1 -0
- package/dist/course/course.controller.d.ts +47 -13
- package/dist/course/course.controller.d.ts.map +1 -1
- package/dist/course/course.controller.js +40 -26
- package/dist/course/course.controller.js.map +1 -1
- package/dist/course/course.mcp-tools.js +1 -1
- package/dist/course/course.mcp-tools.js.map +1 -1
- package/dist/course/course.module.d.ts.map +1 -1
- package/dist/course/course.module.js +16 -0
- package/dist/course/course.module.js.map +1 -1
- package/dist/course/course.service.d.ts +8 -9
- package/dist/course/course.service.d.ts.map +1 -1
- package/dist/course/course.service.js +93 -50
- package/dist/course/course.service.js.map +1 -1
- package/dist/course/dto/cleanup-course-storage.dto.d.ts +1 -1
- package/dist/course/dto/cleanup-course-storage.dto.d.ts.map +1 -1
- package/dist/course/dto/cleanup-course-storage.dto.js +1 -0
- package/dist/course/dto/cleanup-course-storage.dto.js.map +1 -1
- package/dist/course/dto/cleanup-upload-history.dto.d.ts +1 -1
- package/dist/course/dto/cleanup-upload-history.dto.d.ts.map +1 -1
- package/dist/course/dto/cleanup-upload-history.dto.js +1 -1
- package/dist/course/dto/cleanup-upload-history.dto.js.map +1 -1
- package/dist/course/dto/create-course-bulk-job.dto.d.ts +2 -1
- package/dist/course/dto/create-course-bulk-job.dto.d.ts.map +1 -1
- package/dist/course/dto/create-course-bulk-job.dto.js +6 -1
- package/dist/course/dto/create-course-bulk-job.dto.js.map +1 -1
- package/dist/course/dto/create-course-export.dto.d.ts +14 -0
- package/dist/course/dto/create-course-export.dto.d.ts.map +1 -0
- package/dist/course/dto/create-course-export.dto.js +71 -0
- package/dist/course/dto/create-course-export.dto.js.map +1 -0
- package/dist/course/dto/create-course-structure-lesson.dto.d.ts +2 -2
- package/dist/course/dto/create-course-structure-lesson.dto.d.ts.map +1 -1
- package/dist/course/dto/create-course-structure-lesson.dto.js +3 -2
- package/dist/course/dto/create-course-structure-lesson.dto.js.map +1 -1
- package/dist/course/ffmpeg.util.d.ts +10 -0
- package/dist/course/ffmpeg.util.d.ts.map +1 -0
- package/dist/course/ffmpeg.util.js +79 -0
- package/dist/course/ffmpeg.util.js.map +1 -0
- package/dist/course/lms-bulk-upload-automation.service.d.ts +18 -1
- package/dist/course/lms-bulk-upload-automation.service.d.ts.map +1 -1
- package/dist/course/lms-bulk-upload-automation.service.js +106 -8
- package/dist/course/lms-bulk-upload-automation.service.js.map +1 -1
- package/dist/course/lms-bulk-upload-infra.service.d.ts +1 -0
- package/dist/course/lms-bulk-upload-infra.service.d.ts.map +1 -1
- package/dist/course/lms-bulk-upload-infra.service.js +32 -8
- package/dist/course/lms-bulk-upload-infra.service.js.map +1 -1
- package/dist/course/lms-bulk-upload.controller.d.ts +30 -3
- package/dist/course/lms-bulk-upload.controller.d.ts.map +1 -1
- package/dist/course/lms-bulk-upload.controller.js +43 -2
- package/dist/course/lms-bulk-upload.controller.js.map +1 -1
- package/dist/course/lms-bulk-upload.service.d.ts +11 -0
- package/dist/course/lms-bulk-upload.service.d.ts.map +1 -1
- package/dist/course/lms-bulk-upload.service.js +59 -6
- package/dist/course/lms-bulk-upload.service.js.map +1 -1
- package/dist/course/lms-setting.controller.d.ts +2 -1
- package/dist/course/lms-setting.controller.d.ts.map +1 -1
- package/dist/course/lms-setting.controller.js +4 -2
- package/dist/course/lms-setting.controller.js.map +1 -1
- package/dist/course/scorm12-schemas.d.ts +4 -0
- package/dist/course/scorm12-schemas.d.ts.map +1 -0
- package/dist/course/scorm12-schemas.js +9 -0
- package/dist/course/scorm12-schemas.js.map +1 -0
- package/dist/enterprise/training/training-admin.controller.d.ts +2 -0
- package/dist/enterprise/training/training-admin.controller.d.ts.map +1 -1
- package/dist/enterprise/training/training-admin.service.d.ts +2 -0
- package/dist/enterprise/training/training-admin.service.d.ts.map +1 -1
- package/dist/enterprise/training/training-student.service.d.ts +51 -0
- package/dist/enterprise/training/training-student.service.d.ts.map +1 -1
- package/dist/enterprise/training/training-student.service.js +217 -4
- package/dist/enterprise/training/training-student.service.js.map +1 -1
- package/dist/evaluation/evaluation.service.d.ts +18 -0
- package/dist/evaluation/evaluation.service.d.ts.map +1 -1
- package/dist/evaluation/evaluation.service.js +125 -0
- package/dist/evaluation/evaluation.service.js.map +1 -1
- package/dist/exam/dto/create-standalone-question.dto.d.ts +12 -0
- package/dist/exam/dto/create-standalone-question.dto.d.ts.map +1 -0
- package/dist/exam/dto/create-standalone-question.dto.js +70 -0
- package/dist/exam/dto/create-standalone-question.dto.js.map +1 -0
- package/dist/exam/exam.module.d.ts.map +1 -1
- package/dist/exam/exam.module.js +2 -1
- package/dist/exam/exam.module.js.map +1 -1
- package/dist/exam/exam.service.d.ts +21 -0
- package/dist/exam/exam.service.d.ts.map +1 -1
- package/dist/exam/exam.service.js +80 -0
- package/dist/exam/exam.service.js.map +1 -1
- package/dist/exam/question.controller.d.ts +27 -0
- package/dist/exam/question.controller.d.ts.map +1 -0
- package/dist/exam/question.controller.js +53 -0
- package/dist/exam/question.controller.js.map +1 -0
- package/dist/lesson-xp-map/lesson-xp-ai-calculation.service.d.ts +4 -0
- package/dist/lesson-xp-map/lesson-xp-ai-calculation.service.d.ts.map +1 -1
- package/dist/lesson-xp-map/lesson-xp-ai-calculation.service.js +161 -25
- package/dist/lesson-xp-map/lesson-xp-ai-calculation.service.js.map +1 -1
- package/dist/libraries/lms/tsconfig.tsbuildinfo +1 -1
- package/dist/lms-commerce-access.subscriber.d.ts +11 -0
- package/dist/lms-commerce-access.subscriber.d.ts.map +1 -0
- package/dist/lms-commerce-access.subscriber.js +74 -0
- package/dist/lms-commerce-access.subscriber.js.map +1 -0
- package/dist/lms.module.d.ts.map +1 -1
- package/dist/lms.module.js +16 -5
- package/dist/lms.module.js.map +1 -1
- package/dist/platforma/dto/heartbeat.dto.d.ts +9 -0
- package/dist/platforma/dto/heartbeat.dto.d.ts.map +1 -0
- package/dist/platforma/dto/heartbeat.dto.js +50 -0
- package/dist/platforma/dto/heartbeat.dto.js.map +1 -0
- package/dist/platforma/handlers/emit-certificate.handler.d.ts +27 -0
- package/dist/platforma/handlers/emit-certificate.handler.d.ts.map +1 -0
- package/dist/platforma/handlers/emit-certificate.handler.js +117 -0
- package/dist/platforma/handlers/emit-certificate.handler.js.map +1 -0
- package/dist/platforma/handlers/lesson-heartbeat.handler.d.ts +31 -0
- package/dist/platforma/handlers/lesson-heartbeat.handler.d.ts.map +1 -0
- package/dist/platforma/handlers/lesson-heartbeat.handler.js +281 -0
- package/dist/platforma/handlers/lesson-heartbeat.handler.js.map +1 -0
- package/dist/platforma/platforma-heartbeat.service.d.ts +10 -0
- package/dist/platforma/platforma-heartbeat.service.d.ts.map +1 -0
- package/dist/platforma/platforma-heartbeat.service.js +50 -0
- package/dist/platforma/platforma-heartbeat.service.js.map +1 -0
- package/dist/platforma/platforma-performance.service.d.ts +121 -0
- package/dist/platforma/platforma-performance.service.d.ts.map +1 -0
- package/dist/platforma/platforma-performance.service.js +500 -0
- package/dist/platforma/platforma-performance.service.js.map +1 -0
- package/dist/platforma/platforma-search.service.d.ts +21 -0
- package/dist/platforma/platforma-search.service.d.ts.map +1 -0
- package/dist/platforma/platforma-search.service.js +64 -0
- package/dist/platforma/platforma-search.service.js.map +1 -0
- package/dist/platforma/platforma-video.service.d.ts +39 -0
- package/dist/platforma/platforma-video.service.d.ts.map +1 -0
- package/dist/platforma/platforma-video.service.js +301 -0
- package/dist/platforma/platforma-video.service.js.map +1 -0
- package/dist/platforma/platforma.controller.d.ts +209 -1
- package/dist/platforma/platforma.controller.d.ts.map +1 -1
- package/dist/platforma/platforma.controller.js +208 -2
- package/dist/platforma/platforma.controller.js.map +1 -1
- package/dist/realtime/lms-realtime.controller.d.ts +2 -0
- package/dist/realtime/lms-realtime.controller.d.ts.map +1 -1
- package/dist/realtime/lms-realtime.controller.js +31 -0
- package/dist/realtime/lms-realtime.controller.js.map +1 -1
- package/dist/realtime/lms-realtime.service.d.ts +1 -1
- package/dist/realtime/lms-realtime.service.d.ts.map +1 -1
- package/dist/realtime/lms-realtime.service.js.map +1 -1
- package/dist/student-xp/dto/grant-skill-card-xp.dto.d.ts +5 -0
- package/dist/student-xp/dto/grant-skill-card-xp.dto.d.ts.map +1 -0
- package/dist/student-xp/dto/grant-skill-card-xp.dto.js +26 -0
- package/dist/student-xp/dto/grant-skill-card-xp.dto.js.map +1 -0
- package/dist/student-xp/student-xp.controller.d.ts +15 -0
- package/dist/student-xp/student-xp.controller.d.ts.map +1 -1
- package/dist/student-xp/student-xp.controller.js +24 -0
- package/dist/student-xp/student-xp.controller.js.map +1 -1
- package/dist/student-xp/student-xp.service.d.ts +16 -0
- package/dist/student-xp/student-xp.service.d.ts.map +1 -1
- package/dist/student-xp/student-xp.service.js +51 -1
- package/dist/student-xp/student-xp.service.js.map +1 -1
- package/hedhog/data/evaluation_topic.yaml +17 -0
- package/hedhog/data/menu.yaml +0 -17
- package/hedhog/data/queue_definition.yaml +48 -0
- package/hedhog/data/route.yaml +94 -124
- package/hedhog/data/setting_group.yaml +19 -19
- package/hedhog/frontend/app/bulk-upload-sessions/page.tsx.ejs +337 -41
- package/hedhog/frontend/app/certificates/models/page.tsx.ejs +182 -29
- package/hedhog/frontend/app/classes/_components/classes-calendar-view.tsx.ejs +277 -0
- package/hedhog/frontend/app/classes/page.tsx.ejs +127 -20
- package/hedhog/frontend/app/courses/[id]/page.tsx.ejs +69 -4
- package/hedhog/frontend/app/courses/[id]/structure/_components/course-export-sheet.tsx.ejs +420 -0
- package/hedhog/frontend/app/courses/[id]/structure/_components/course-exports-tab.tsx.ejs +308 -0
- package/hedhog/frontend/app/courses/[id]/structure/_components/course-overview-tab.tsx.ejs +158 -45
- package/hedhog/frontend/app/courses/[id]/structure/_components/course-xp-overview-tab.tsx.ejs +13 -13
- package/hedhog/frontend/app/courses/[id]/structure/_components/detail-lesson-xp-tab.tsx.ejs +11 -23
- package/hedhog/frontend/app/courses/[id]/structure/_components/detail-lesson.tsx.ejs +51 -63
- package/hedhog/frontend/app/courses/[id]/structure/_components/detail-panel.tsx.ejs +8 -3
- package/hedhog/frontend/app/courses/[id]/structure/_components/detail-session.tsx.ejs +31 -8
- package/hedhog/frontend/app/courses/[id]/structure/_components/drag-overlay.tsx.ejs +16 -9
- package/hedhog/frontend/app/courses/[id]/structure/_components/editor-course.tsx.ejs +201 -401
- package/hedhog/frontend/app/courses/[id]/structure/_components/editor-lesson.tsx.ejs +378 -690
- package/hedhog/frontend/app/courses/[id]/structure/_components/mock-data.ts.ejs +1 -2
- package/hedhog/frontend/app/courses/[id]/structure/_components/tree-row-lesson.tsx.ejs +3 -9
- package/hedhog/frontend/app/courses/[id]/structure/_components/types.ts.ejs +1 -1
- package/hedhog/frontend/app/courses/[id]/structure/_components/xp-premium-pills.tsx.ejs +1 -8
- package/hedhog/frontend/app/courses/[id]/structure/_data/adapters/course-structure.adapter.ts.ejs +6 -10
- package/hedhog/frontend/app/courses/[id]/structure/_data/services/course-structure.service.ts.ejs +49 -0
- package/hedhog/frontend/app/courses/[id]/structure/_data/types/api-course.types.ts.ejs +4 -3
- package/hedhog/frontend/app/courses/[id]/structure/_data/use-course-content-overview.ts.ejs +2 -1
- package/hedhog/frontend/app/courses/[id]/structure/_data/use-course-exports.ts.ejs +106 -0
- package/hedhog/frontend/app/courses/[id]/structure/_data/use-course-structure-mutations.ts.ejs +28 -1
- package/hedhog/frontend/app/courses/[id]/structure/_data/use-lms-settings-query.ts.ejs +0 -2
- package/hedhog/frontend/app/courses/page.tsx.ejs +85 -9
- package/hedhog/frontend/app/enterprise/[id]/page.tsx.ejs +6 -0
- package/hedhog/frontend/app/enterprise/_components/enterprise-classes-calendar-tab.tsx.ejs +264 -0
- package/hedhog/frontend/app/enterprise/page.tsx.ejs +104 -47
- package/hedhog/frontend/app/exams/page.tsx.ejs +38 -4
- package/hedhog/frontend/app/instructors/page.tsx.ejs +87 -46
- package/hedhog/frontend/app/paths/page.tsx.ejs +38 -4
- package/hedhog/frontend/app/training/page.tsx.ejs +38 -4
- package/hedhog/frontend/messages/en.json +44 -28
- package/hedhog/frontend/messages/pt.json +47 -29
- package/hedhog/table/course_enrollment.yaml +3 -0
- package/hedhog/table/course_export.yaml +62 -0
- package/hedhog/table/lesson_view_event.yaml +66 -0
- package/package.json +14 -9
- package/src/bitcode-wallet/bitcode-wallet.service.ts +43 -4
- package/src/course/course-export-scorm12-worker.service.ts +124 -0
- package/src/course/course-export-scorm12.service.ts +668 -0
- package/src/course/course-export.service.ts +280 -0
- package/src/course/course-structure.controller.ts +16 -2
- package/src/course/course-structure.service.ts +100 -7
- package/src/course/course-video-agent-pipeline.service.ts +471 -0
- package/src/course/course-video-hls.service.ts +966 -0
- package/src/course/course.controller.ts +33 -19
- package/src/course/course.mcp-tools.ts +1 -1
- package/src/course/course.module.ts +16 -0
- package/src/course/course.service.ts +119 -61
- package/src/course/dto/cleanup-course-storage.dto.ts +1 -0
- package/src/course/dto/cleanup-upload-history.dto.ts +1 -1
- package/src/course/dto/create-course-bulk-job.dto.ts +7 -3
- package/src/course/dto/create-course-export.dto.ts +56 -0
- package/src/course/dto/create-course-structure-lesson.dto.ts +4 -3
- package/src/course/ffmpeg.util.ts +65 -0
- package/src/course/lms-bulk-upload-automation.service.ts +156 -6
- package/src/course/lms-bulk-upload-infra.service.ts +39 -6
- package/src/course/lms-bulk-upload.controller.ts +32 -2
- package/src/course/lms-bulk-upload.service.ts +70 -7
- package/src/course/lms-setting.controller.ts +4 -2
- package/src/course/scorm12-schemas.ts +9 -0
- package/src/enterprise/training/training-student.service.ts +221 -2
- package/src/evaluation/evaluation.service.ts +123 -0
- package/src/exam/dto/create-standalone-question.dto.ts +66 -0
- package/src/exam/exam.module.ts +2 -1
- package/src/exam/exam.service.ts +86 -0
- package/src/exam/question.controller.ts +28 -0
- package/src/lesson-xp-map/lesson-xp-ai-calculation.service.ts +205 -31
- package/src/lms-commerce-access.subscriber.ts +88 -0
- package/src/lms.module.ts +16 -5
- package/src/platforma/dto/heartbeat.dto.ts +30 -0
- package/src/platforma/handlers/emit-certificate.handler.ts +117 -0
- package/src/platforma/handlers/lesson-heartbeat.handler.ts +343 -0
- package/src/platforma/platforma-heartbeat.service.ts +33 -0
- package/src/platforma/platforma-performance.service.ts +606 -0
- package/src/platforma/platforma-search.service.ts +48 -0
- package/src/platforma/platforma-video.service.ts +346 -0
- package/src/platforma/platforma.controller.ts +137 -1
- package/src/platforma/platforma.service.ts +268 -268
- package/src/realtime/lms-realtime.controller.ts +27 -1
- package/src/realtime/lms-realtime.service.ts +2 -1
- package/src/student-xp/dto/grant-skill-card-xp.dto.ts +10 -0
- package/src/student-xp/student-xp.controller.ts +18 -2
- package/src/student-xp/student-xp.service.ts +84 -2
- package/hedhog/data/video_resolution_profile.yaml +0 -7
- package/hedhog/frontend/app/video-resolution-profiles/page.tsx.ejs +0 -607
- package/hedhog/table/course_video_resolution_profile.yaml +0 -22
- package/hedhog/table/video_resolution_profile.yaml +0 -18
- package/src/video-resolution-profile/dto/create-video-resolution-profile.dto.ts +0 -16
- package/src/video-resolution-profile/dto/update-video-resolution-profile.dto.ts +0 -16
- package/src/video-resolution-profile/video-resolution-profile.controller.ts +0 -62
- package/src/video-resolution-profile/video-resolution-profile.mcp-tools.ts +0 -128
- package/src/video-resolution-profile/video-resolution-profile.module.ts +0 -13
- package/src/video-resolution-profile/video-resolution-profile.service.ts +0 -117
|
@@ -435,7 +435,7 @@ export function LessonXpTab({
|
|
|
435
435
|
icon={<Cpu className="size-4 text-sky-600" />}
|
|
436
436
|
total={xpMap.totalXp}
|
|
437
437
|
items={areaDistribution}
|
|
438
|
-
toneClassName="
|
|
438
|
+
toneClassName=""
|
|
439
439
|
/>
|
|
440
440
|
<DistributionCard
|
|
441
441
|
title="Skills"
|
|
@@ -443,7 +443,7 @@ export function LessonXpTab({
|
|
|
443
443
|
icon={<Zap className="size-4 text-emerald-600" />}
|
|
444
444
|
total={xpMap.totalXp}
|
|
445
445
|
items={skillDistribution}
|
|
446
|
-
toneClassName="
|
|
446
|
+
toneClassName=""
|
|
447
447
|
/>
|
|
448
448
|
<TimelineCard
|
|
449
449
|
segmentViews={segmentViews}
|
|
@@ -670,7 +670,7 @@ function TimelineCard({
|
|
|
670
670
|
|
|
671
671
|
return (
|
|
672
672
|
<Card className="min-w-0 overflow-hidden border-border/70 bg-card/95 py-0 gap-0! shadow-[0_18px_40px_-32px_rgba(15,23,42,0.45)] xl:col-span-2">
|
|
673
|
-
<CardHeader className="border-b border-border/60
|
|
673
|
+
<CardHeader className="border-b border-border/60 pt-3 pb-1.5!">
|
|
674
674
|
<div className="flex items-center justify-between gap-3">
|
|
675
675
|
<div>
|
|
676
676
|
<CardTitle className="text-sm font-semibold">
|
|
@@ -761,7 +761,7 @@ function LearningTypesCard({ items }: { items: DistributionItem[] }) {
|
|
|
761
761
|
|
|
762
762
|
return (
|
|
763
763
|
<Card className="min-w-0 overflow-hidden border-border/70 bg-card/95 py-0 gap-0! shadow-[0_18px_40px_-32px_rgba(15,23,42,0.45)] xl:col-span-2">
|
|
764
|
-
<CardHeader className="border-b border-border/60
|
|
764
|
+
<CardHeader className="border-b border-border/60 pt-3 pb-1.5!">
|
|
765
765
|
<div className="flex items-center justify-between gap-3">
|
|
766
766
|
<CardTitle className="text-sm font-semibold">
|
|
767
767
|
Tipos de aprendizado
|
|
@@ -775,7 +775,7 @@ function LearningTypesCard({ items }: { items: DistributionItem[] }) {
|
|
|
775
775
|
{items.map((item) => (
|
|
776
776
|
<div
|
|
777
777
|
key={item.id}
|
|
778
|
-
className="flex h-full flex-col justify-start gap-1.5 rounded-xl border border-border/60 bg-muted/20 px-2.5 py-2 text-xs shadow-sm transition-all duration-200 hover:-translate-y-0.5 hover:border-
|
|
778
|
+
className="flex h-full flex-col justify-start gap-1.5 rounded-xl border border-border/60 bg-muted/20 px-2.5 py-2 text-xs shadow-sm transition-all duration-200 hover:-translate-y-0.5 hover:border-border/80 hover:bg-background/95 hover:shadow-md"
|
|
779
779
|
>
|
|
780
780
|
<div className="flex flex-wrap items-center justify-between gap-2">
|
|
781
781
|
<span className="min-w-0 flex-1 font-medium">{item.label}</span>
|
|
@@ -813,7 +813,7 @@ function SegmentsSection({
|
|
|
813
813
|
}) {
|
|
814
814
|
return (
|
|
815
815
|
<Card className="min-w-0 overflow-hidden border-border/70 bg-card/95 py-0 gap-0! shadow-[0_18px_40px_-32px_rgba(15,23,42,0.45)]">
|
|
816
|
-
<CardHeader className="border-b border-border/60
|
|
816
|
+
<CardHeader className="border-b border-border/60 pt-3 pb-1.5!">
|
|
817
817
|
<div className="flex items-center justify-between gap-3">
|
|
818
818
|
<CardTitle className="text-sm font-semibold">
|
|
819
819
|
Segmentos ({segments.length})
|
|
@@ -829,14 +829,14 @@ function SegmentsSection({
|
|
|
829
829
|
<div
|
|
830
830
|
key={segment.id}
|
|
831
831
|
className={cn(
|
|
832
|
-
'flex flex-col gap-2 rounded-2xl border border-border/60 bg-
|
|
832
|
+
'flex flex-col gap-2 rounded-2xl border border-border/60 bg-card/90 px-3 py-2.5 text-xs shadow-[0_16px_30px_-24px_rgba(15,23,42,0.45)] transition-all duration-200 hover:-translate-y-0.5 hover:border-border/80 hover:shadow-[0_20px_36px_-24px_rgba(15,23,42,0.52)]',
|
|
833
833
|
!segment.shouldGrantXp && 'opacity-50'
|
|
834
834
|
)}
|
|
835
835
|
>
|
|
836
836
|
<div className="flex flex-wrap items-start justify-between gap-2">
|
|
837
837
|
<div className="flex min-w-0 flex-col gap-1">
|
|
838
838
|
<div className="flex flex-wrap items-center gap-1.5">
|
|
839
|
-
<span className="rounded-full border border-
|
|
839
|
+
<span className="rounded-full border border-border/60 bg-muted/30 px-2 py-0.5 text-[10px] font-semibold uppercase tracking-[0.14em] text-muted-foreground">
|
|
840
840
|
{segment.label}
|
|
841
841
|
</span>
|
|
842
842
|
<span className="rounded-full border border-border/60 bg-background/90 px-2 py-0.5 font-mono text-[10px] text-muted-foreground shadow-sm transition-all duration-200 hover:border-border hover:bg-background hover:text-foreground hover:shadow-md">
|
|
@@ -856,7 +856,7 @@ function SegmentsSection({
|
|
|
856
856
|
</div>
|
|
857
857
|
|
|
858
858
|
<div className="flex flex-wrap items-center justify-end gap-1.5">
|
|
859
|
-
<span className="rounded-full border border-
|
|
859
|
+
<span className="rounded-full border border-border/60 bg-muted/30 px-2 py-0.5 text-[10px] font-semibold uppercase tracking-[0.14em] text-muted-foreground">
|
|
860
860
|
{segment.xpValue} XP
|
|
861
861
|
</span>
|
|
862
862
|
<DifficultyBadge difficulty={segment.difficulty} />
|
|
@@ -1031,14 +1031,7 @@ function MetricPill({
|
|
|
1031
1031
|
value: string;
|
|
1032
1032
|
tone?: 'default' | 'sky' | 'emerald' | 'violet';
|
|
1033
1033
|
}) {
|
|
1034
|
-
const toneClassName =
|
|
1035
|
-
tone === 'sky'
|
|
1036
|
-
? 'border-sky-500/15 bg-sky-500/10 text-sky-700 dark:text-sky-300'
|
|
1037
|
-
: tone === 'emerald'
|
|
1038
|
-
? 'border-emerald-500/15 bg-emerald-500/10 text-emerald-700 dark:text-emerald-300'
|
|
1039
|
-
: tone === 'violet'
|
|
1040
|
-
? 'border-violet-500/15 bg-violet-500/10 text-violet-700 dark:text-violet-300'
|
|
1041
|
-
: 'border-border/60 bg-muted/40 text-foreground';
|
|
1034
|
+
const toneClassName = 'border-border/60 bg-muted/40 text-foreground';
|
|
1042
1035
|
|
|
1043
1036
|
return (
|
|
1044
1037
|
<div
|
|
@@ -1069,12 +1062,7 @@ function SegmentBreakdownGroup({
|
|
|
1069
1062
|
color: string;
|
|
1070
1063
|
}>;
|
|
1071
1064
|
}) {
|
|
1072
|
-
const toneClassName =
|
|
1073
|
-
tone === 'sky'
|
|
1074
|
-
? 'border-sky-500/15 bg-sky-500/8'
|
|
1075
|
-
: tone === 'emerald'
|
|
1076
|
-
? 'border-emerald-500/15 bg-emerald-500/8'
|
|
1077
|
-
: 'border-violet-500/15 bg-violet-500/8';
|
|
1065
|
+
const toneClassName = 'border-border/60 bg-muted/20';
|
|
1078
1066
|
|
|
1079
1067
|
if (!items.length) {
|
|
1080
1068
|
return null;
|
|
@@ -11,7 +11,6 @@ import {
|
|
|
11
11
|
ExternalLink,
|
|
12
12
|
FileText,
|
|
13
13
|
HelpCircle,
|
|
14
|
-
Layers,
|
|
15
14
|
Loader2,
|
|
16
15
|
Mic,
|
|
17
16
|
Paperclip,
|
|
@@ -25,8 +24,8 @@ import {
|
|
|
25
24
|
useStartTranscriptionMutation,
|
|
26
25
|
useTranscriptionSegmentsQuery,
|
|
27
26
|
} from '../_data/use-transcription-segments';
|
|
28
|
-
import { useStructureStore } from './store';
|
|
29
27
|
import { LessonXpTab } from './detail-lesson-xp-tab';
|
|
28
|
+
import { useStructureStore } from './store';
|
|
30
29
|
import type { LessonType } from './types';
|
|
31
30
|
|
|
32
31
|
const LESSON_TYPE_CONFIG: Record<
|
|
@@ -51,12 +50,6 @@ const LESSON_TYPE_CONFIG: Record<
|
|
|
51
50
|
bg: 'bg-amber-500/10',
|
|
52
51
|
label: 'Quiz',
|
|
53
52
|
},
|
|
54
|
-
exercicio: {
|
|
55
|
-
icon: Layers,
|
|
56
|
-
color: 'text-rose-500',
|
|
57
|
-
bg: 'bg-rose-500/10',
|
|
58
|
-
label: 'Exercício',
|
|
59
|
-
},
|
|
60
53
|
};
|
|
61
54
|
|
|
62
55
|
const VIDEO_PROVIDER_LABELS: Record<string, string> = {
|
|
@@ -86,7 +79,9 @@ export function DetailLesson({ lessonId }: DetailLessonProps) {
|
|
|
86
79
|
|
|
87
80
|
const { data: segments = [], isLoading: segmentsLoading } =
|
|
88
81
|
useTranscriptionSegmentsQuery(
|
|
89
|
-
activeTab === 'transcription' || activeTab === 'xp'
|
|
82
|
+
activeTab === 'transcription' || activeTab === 'xp'
|
|
83
|
+
? (lesson?.id ?? null)
|
|
84
|
+
: null
|
|
90
85
|
);
|
|
91
86
|
|
|
92
87
|
const queryClient = useQueryClient();
|
|
@@ -97,7 +92,9 @@ export function DetailLesson({ lessonId }: DetailLessonProps) {
|
|
|
97
92
|
startTranscription({
|
|
98
93
|
onSuccess: () => {
|
|
99
94
|
toast.success('Transcrição iniciada!');
|
|
100
|
-
queryClient.invalidateQueries({
|
|
95
|
+
queryClient.invalidateQueries({
|
|
96
|
+
queryKey: ['lesson-transcription-segments', lesson?.id],
|
|
97
|
+
});
|
|
101
98
|
},
|
|
102
99
|
onError: (err) => {
|
|
103
100
|
toast.error(err.message || 'Erro ao iniciar a transcrição.');
|
|
@@ -243,64 +240,55 @@ export function DetailLesson({ lessonId }: DetailLessonProps) {
|
|
|
243
240
|
</Section>
|
|
244
241
|
</>
|
|
245
242
|
)}
|
|
246
|
-
|
|
247
|
-
{!lesson.publicDescription &&
|
|
248
|
-
!lesson.privateDescription &&
|
|
249
|
-
lesson.type === 'exercicio' && (
|
|
250
|
-
<div className="flex flex-col items-center gap-2 py-8 text-center">
|
|
251
|
-
<Layers className="size-8 text-muted-foreground/40" />
|
|
252
|
-
<p className="text-sm text-muted-foreground">
|
|
253
|
-
Sem informações adicionais nesta aula.
|
|
254
|
-
</p>
|
|
255
|
-
</div>
|
|
256
|
-
)}
|
|
257
243
|
</div>
|
|
258
244
|
</TabsContent>
|
|
259
245
|
|
|
260
246
|
{/* ── Transcrição ───────────────────────────────────────────────────── */}
|
|
261
|
-
{lmsSettings.transcriptionEnabled &&
|
|
262
|
-
|
|
263
|
-
|
|
264
|
-
|
|
265
|
-
|
|
266
|
-
<
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
{segmentsLoading ? (
|
|
281
|
-
<div className="p-4 text-sm text-muted-foreground">
|
|
282
|
-
Carregando transcrição...
|
|
247
|
+
{lmsSettings.transcriptionEnabled && (
|
|
248
|
+
<TabsContent
|
|
249
|
+
value="transcription"
|
|
250
|
+
className="flex-1 overflow-y-auto px-4 pb-4 mt-3"
|
|
251
|
+
>
|
|
252
|
+
<div className="flex justify-end mb-3">
|
|
253
|
+
<Button
|
|
254
|
+
size="sm"
|
|
255
|
+
variant="outline"
|
|
256
|
+
onClick={handleStartTranscription}
|
|
257
|
+
disabled={isStarting}
|
|
258
|
+
>
|
|
259
|
+
{isStarting ? (
|
|
260
|
+
<Loader2 className="size-4 mr-2 animate-spin" />
|
|
261
|
+
) : (
|
|
262
|
+
<Mic className="size-4 mr-2" />
|
|
263
|
+
)}
|
|
264
|
+
Iniciar transcrição
|
|
265
|
+
</Button>
|
|
283
266
|
</div>
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
267
|
+
{segmentsLoading ? (
|
|
268
|
+
<div className="p-4 text-sm text-muted-foreground">
|
|
269
|
+
Carregando transcrição...
|
|
270
|
+
</div>
|
|
271
|
+
) : segments.length ? (
|
|
272
|
+
<div className="space-y-1.5 p-3">
|
|
273
|
+
{segments.map((seg) => (
|
|
274
|
+
<div key={seg.id} className="flex gap-3 text-sm">
|
|
275
|
+
<span className="shrink-0 font-mono text-xs text-muted-foreground w-24">
|
|
276
|
+
[{formatSeconds(seg.startSeconds)} –{' '}
|
|
277
|
+
{formatSeconds(seg.endSeconds)}]
|
|
278
|
+
</span>
|
|
279
|
+
<span className="leading-relaxed">{seg.text}</span>
|
|
280
|
+
</div>
|
|
281
|
+
))}
|
|
282
|
+
</div>
|
|
283
|
+
) : (
|
|
284
|
+
<EmptyState
|
|
285
|
+
icon={<FileText className="size-8 text-muted-foreground/40" />}
|
|
286
|
+
>
|
|
287
|
+
Transcrição não disponível para esta aula.
|
|
288
|
+
</EmptyState>
|
|
289
|
+
)}
|
|
290
|
+
</TabsContent>
|
|
291
|
+
)}
|
|
304
292
|
|
|
305
293
|
{/* ── XP da Aula ────────────────────────────────────────────────────── */}
|
|
306
294
|
<TabsContent
|
|
@@ -10,7 +10,12 @@ import { EditorLesson } from './editor-lesson';
|
|
|
10
10
|
import { EditorSession } from './editor-session';
|
|
11
11
|
import { useStructureStore } from './store';
|
|
12
12
|
|
|
13
|
-
|
|
13
|
+
interface DetailPanelProps {
|
|
14
|
+
defaultTab?: string;
|
|
15
|
+
onTabChange?: (tab: string) => void;
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export const DetailPanel = memo(function DetailPanel({ defaultTab, onTabChange }: DetailPanelProps) {
|
|
14
19
|
const t = useTranslations('lms.CoursesPage.StructurePage');
|
|
15
20
|
const { activeItemId, activeItemType, selectedIds } = useStructureStore();
|
|
16
21
|
|
|
@@ -47,7 +52,7 @@ export const DetailPanel = memo(function DetailPanel() {
|
|
|
47
52
|
}
|
|
48
53
|
|
|
49
54
|
if (activeItemType === 'course') {
|
|
50
|
-
return <EditorCourse />;
|
|
55
|
+
return <EditorCourse defaultTab={defaultTab} onTabChange={onTabChange} />;
|
|
51
56
|
}
|
|
52
57
|
|
|
53
58
|
if (activeItemType === 'session') {
|
|
@@ -55,7 +60,7 @@ export const DetailPanel = memo(function DetailPanel() {
|
|
|
55
60
|
}
|
|
56
61
|
|
|
57
62
|
if (activeItemType === 'lesson') {
|
|
58
|
-
return <EditorLesson lessonId={activeItemId} />;
|
|
63
|
+
return <EditorLesson lessonId={activeItemId} defaultTab={defaultTab} onTabChange={onTabChange} />;
|
|
59
64
|
}
|
|
60
65
|
|
|
61
66
|
return null;
|
|
@@ -18,10 +18,24 @@ const LESSON_TYPE_CONFIG: Record<
|
|
|
18
18
|
LessonType,
|
|
19
19
|
{ icon: LucideIcon; color: string; label: string; bg: string }
|
|
20
20
|
> = {
|
|
21
|
-
video:
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
21
|
+
video: {
|
|
22
|
+
icon: Video,
|
|
23
|
+
color: 'text-blue-500',
|
|
24
|
+
label: 'Vídeo',
|
|
25
|
+
bg: 'bg-blue-500/10',
|
|
26
|
+
},
|
|
27
|
+
post: {
|
|
28
|
+
icon: FileText,
|
|
29
|
+
color: 'text-emerald-500',
|
|
30
|
+
label: 'Post',
|
|
31
|
+
bg: 'bg-emerald-500/10',
|
|
32
|
+
},
|
|
33
|
+
questao: {
|
|
34
|
+
icon: HelpCircle,
|
|
35
|
+
color: 'text-amber-500',
|
|
36
|
+
label: 'Quiz',
|
|
37
|
+
bg: 'bg-amber-500/10',
|
|
38
|
+
},
|
|
25
39
|
};
|
|
26
40
|
|
|
27
41
|
interface DetailSessionProps {
|
|
@@ -29,8 +43,14 @@ interface DetailSessionProps {
|
|
|
29
43
|
}
|
|
30
44
|
|
|
31
45
|
export function DetailSession({ sessionId }: DetailSessionProps) {
|
|
32
|
-
const session = useStructureStore((s) =>
|
|
33
|
-
|
|
46
|
+
const session = useStructureStore((s) =>
|
|
47
|
+
s.sessions.find((ss) => ss.id === sessionId)
|
|
48
|
+
);
|
|
49
|
+
const lessons = useStructureStore((s) =>
|
|
50
|
+
s.lessons
|
|
51
|
+
.filter((l) => l.sessionId === sessionId)
|
|
52
|
+
.sort((a, b) => a.order - b.order)
|
|
53
|
+
);
|
|
34
54
|
const selectItem = useStructureStore((s) => s.selectItem);
|
|
35
55
|
|
|
36
56
|
if (!session) return null;
|
|
@@ -157,7 +177,10 @@ function LessonListItem({
|
|
|
157
177
|
{lesson.duration}min
|
|
158
178
|
</span>
|
|
159
179
|
</div>
|
|
160
|
-
<Badge
|
|
180
|
+
<Badge
|
|
181
|
+
variant="outline"
|
|
182
|
+
className="text-[0.55rem] px-1 py-0 h-4 shrink-0"
|
|
183
|
+
>
|
|
161
184
|
{lesson.code}
|
|
162
185
|
</Badge>
|
|
163
186
|
</button>
|
|
@@ -171,4 +194,4 @@ function StatCard({ label, value }: { label: string; value: string | number }) {
|
|
|
171
194
|
<span className="text-[0.65rem] text-muted-foreground">{label}</span>
|
|
172
195
|
</div>
|
|
173
196
|
);
|
|
174
|
-
}
|
|
197
|
+
}
|
|
@@ -1,8 +1,14 @@
|
|
|
1
1
|
'use client';
|
|
2
2
|
|
|
3
|
-
import { DragOverlay as DndDragOverlay } from '@dnd-kit/core';
|
|
4
3
|
import { cn } from '@/lib/utils';
|
|
5
|
-
import {
|
|
4
|
+
import { DragOverlay as DndDragOverlay } from '@dnd-kit/core';
|
|
5
|
+
import {
|
|
6
|
+
FileText,
|
|
7
|
+
GripVertical,
|
|
8
|
+
HelpCircle,
|
|
9
|
+
Layers,
|
|
10
|
+
Video,
|
|
11
|
+
} from 'lucide-react';
|
|
6
12
|
import type { FlatItem } from './types';
|
|
7
13
|
|
|
8
14
|
interface DragOverlayContentProps {
|
|
@@ -11,13 +17,12 @@ interface DragOverlayContentProps {
|
|
|
11
17
|
|
|
12
18
|
function DragOverlayContent({ item }: DragOverlayContentProps) {
|
|
13
19
|
const isSession = item.type === 'session';
|
|
14
|
-
const isLesson
|
|
20
|
+
const isLesson = item.type === 'lesson';
|
|
15
21
|
|
|
16
22
|
const lessonIconMap = {
|
|
17
|
-
video:
|
|
18
|
-
post:
|
|
19
|
-
questao:
|
|
20
|
-
exercicio: <Layers className="size-3.5 text-rose-500 shrink-0" />,
|
|
23
|
+
video: <Video className="size-3.5 text-blue-500 shrink-0" />,
|
|
24
|
+
post: <FileText className="size-3.5 text-emerald-500 shrink-0" />,
|
|
25
|
+
questao: <HelpCircle className="size-3.5 text-amber-500 shrink-0" />,
|
|
21
26
|
} as const;
|
|
22
27
|
|
|
23
28
|
return (
|
|
@@ -31,7 +36,9 @@ function DragOverlayContent({ item }: DragOverlayContentProps) {
|
|
|
31
36
|
>
|
|
32
37
|
<GripVertical className="size-3.5 text-muted-foreground/60 shrink-0" />
|
|
33
38
|
|
|
34
|
-
{isSession &&
|
|
39
|
+
{isSession && (
|
|
40
|
+
<Layers className="size-3.5 text-muted-foreground shrink-0" />
|
|
41
|
+
)}
|
|
35
42
|
{isLesson && item.type === 'lesson' && lessonIconMap[item.data.type]}
|
|
36
43
|
|
|
37
44
|
<span className="truncate font-medium text-xs">{item.data.title}</span>
|
|
@@ -49,4 +56,4 @@ export function TreeDragOverlay({ activeItem }: TreeDragOverlayProps) {
|
|
|
49
56
|
{activeItem ? <DragOverlayContent item={activeItem} /> : null}
|
|
50
57
|
</DndDragOverlay>
|
|
51
58
|
);
|
|
52
|
-
}
|
|
59
|
+
}
|