Every lesson in Nexu is composed of ordered blocks. Each block document lives in theDocumentation Index
Fetch the complete documentation index at: https://mintlify.com/Stivenz3/Nexu/llms.txt
Use this file to discover all available pages before exploring further.
lessons/{lessonId}/blocks/ subcollection and carries a type field that determines both its Firestore content schema and which React component renders it in LessonFlowPage. The four supported block types are video, theory, game, and exam.
All blocks share a common wrapper shape defined by LessonBlock:
video block — VideoBlockContent
The video block embeds a YouTube video and optionally enforces a minimum watch percentage before the learner can proceed.
Firestore content schema
Lesson 1 example (b01_video)
UI component
VideoBlockView renders the YouTube embed. When the video ends (or when minWatchPercent is reached), it signals completion to LessonFlowPage via an onComplete callback.
Progress tracked
In the current Lesson 1 seed,
minWatchPercent is set to 0, so the video block completes as soon as the learner clicks through — no minimum watch time is enforced. Set this to a value like 80 to require 80% of the video to be watched before proceeding.theory block — TheoryBlockContent
Theory blocks deliver normative content — a summary, key points, an optional technical note, and one or more inline questions the learner must answer correctly before advancing.
Firestore content schema
questionId for a single question and questionIds for multiple questions. The service helper getTheoryQuestionIds(content) normalises both cases into a single string[], so the rest of the app never needs to check which field is populated.
Lesson 1 example (b02_modulo_a — single question)
Lesson 1 example (b04_modulo_c — multiple questions)
UI components
TheoryBlockView renders the summary, key points, and technical note. After the learner clicks “Continuar”, LessonFlowPage transitions to the question step and renders InlineQuestionView for each question in sequence. The learner must answer correctly to advance to the next block.
Progress tracked
game block — GameBlockContent
The game block presents a scenario-based error-identification activity. It defines a list of hygiene violations the learner must spot, along with scoring rules and a time limit.
Firestore content schema
Lesson 1 example (b07_game)
UI component
GameBlockView currently renders a placeholder UI: it displays the list of errors defined in the errors array for the learner to identify by clicking. This allows the game block to function end-to-end while the Unity integration is being completed.
Progress tracked
Unity WebGL integration is in progress. The
unityGamePath and unityBuildName fields in GameBlockContent are designed to wire up a Unity WebGL build (e.g. a 3D kitchen scene) when that build is ready. The current GameBlockView uses a placeholder UI — an interactive checklist of the errors defined in the errors array — so the full lesson flow can be completed and tested today.exam block — ExamBlockContent
The exam block is the final gate of every lesson. Rather than rendering inline content, it displays a summary card with the exam parameters and a button that navigates the learner to /leccion/:id/evaluacion (LessonExamPage).
Firestore content schema
Lesson 1 example (b08_exam)
UI
The exam block renders a short summary inLessonFlowPage (question count and passing threshold). Clicking “Iniciar evaluación final” navigates to LessonExamPage at /leccion/:id/evaluacion, which runs the full randomized question flow and calls saveExamResult when the learner submits.
The “Iniciar evaluación final” button is disabled until isExamUnlocked returns true — meaning all non-exam blocks must be completed first.