coursecode 0.1.0
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/LICENSE +21 -0
- package/README.md +322 -0
- package/THIRD_PARTY_NOTICES.md +22 -0
- package/bin/cli.js +331 -0
- package/framework/assets/logo-coursecode-black.svg +14 -0
- package/framework/assets/logo-coursecode-white.svg +14 -0
- package/framework/assets/logo-coursecode.svg +14 -0
- package/framework/css/01-base.css +160 -0
- package/framework/css/02-layout.css +499 -0
- package/framework/css/accessibility.css +834 -0
- package/framework/css/components/accordions.css +710 -0
- package/framework/css/components/assessments.css +520 -0
- package/framework/css/components/audio-player.css +570 -0
- package/framework/css/components/badges.css +80 -0
- package/framework/css/components/breadcrumbs.css +87 -0
- package/framework/css/components/buttons.css +707 -0
- package/framework/css/components/callouts.css +1280 -0
- package/framework/css/components/cards.css +475 -0
- package/framework/css/components/carousel.css +193 -0
- package/framework/css/components/checkbox-group.css +123 -0
- package/framework/css/components/checklist.css +203 -0
- package/framework/css/components/collapse.css +96 -0
- package/framework/css/components/comparison.css +33 -0
- package/framework/css/components/content-image.css +36 -0
- package/framework/css/components/document-gallery.css +425 -0
- package/framework/css/components/dropdown.css +115 -0
- package/framework/css/components/embed-frame.css +142 -0
- package/framework/css/components/engagement.css +412 -0
- package/framework/css/components/features.css +35 -0
- package/framework/css/components/flip-cards.css +253 -0
- package/framework/css/components/footer.css +353 -0
- package/framework/css/components/forms.css +294 -0
- package/framework/css/components/hero.css +216 -0
- package/framework/css/components/images.css +528 -0
- package/framework/css/components/interactive-timeline.css +274 -0
- package/framework/css/components/intro-cards.css +30 -0
- package/framework/css/components/lightbox.css +666 -0
- package/framework/css/components/loading.css +65 -0
- package/framework/css/components/modals.css +235 -0
- package/framework/css/components/notifications.css +107 -0
- package/framework/css/components/quote.css +150 -0
- package/framework/css/components/sidebar.css +684 -0
- package/framework/css/components/slide-header.css +52 -0
- package/framework/css/components/spinner.css +62 -0
- package/framework/css/components/stats.css +44 -0
- package/framework/css/components/steps.css +232 -0
- package/framework/css/components/tables.css +90 -0
- package/framework/css/components/tabs.css +347 -0
- package/framework/css/components/timeline.css +154 -0
- package/framework/css/components/toggle.css +95 -0
- package/framework/css/components/tooltip.css +226 -0
- package/framework/css/components/video-player.css +438 -0
- package/framework/css/design-tokens.css +707 -0
- package/framework/css/framework.css +86 -0
- package/framework/css/interactions/accessibility.css +75 -0
- package/framework/css/interactions/base.css +92 -0
- package/framework/css/interactions/drag-drop.css +295 -0
- package/framework/css/interactions/fill-in-the-blank.css +236 -0
- package/framework/css/interactions/hotspots.css +69 -0
- package/framework/css/interactions/index.css +45 -0
- package/framework/css/interactions/interactive-image.css +359 -0
- package/framework/css/interactions/likert.css +126 -0
- package/framework/css/interactions/matching.css +354 -0
- package/framework/css/interactions/numeric-input.css +78 -0
- package/framework/css/interactions/sequencing.css +378 -0
- package/framework/css/interactions/true-false.css +177 -0
- package/framework/css/layouts/article.css +258 -0
- package/framework/css/layouts/base.css +30 -0
- package/framework/css/layouts/canvas.css +38 -0
- package/framework/css/layouts/focused.css +236 -0
- package/framework/css/layouts/index.css +29 -0
- package/framework/css/layouts/presentation.css +191 -0
- package/framework/css/layouts/traditional.css +52 -0
- package/framework/css/responsive.css +439 -0
- package/framework/css/utilities/accessibility-utils.css +59 -0
- package/framework/css/utilities/animations.css +419 -0
- package/framework/css/utilities/borders.css +72 -0
- package/framework/css/utilities/colors.css +76 -0
- package/framework/css/utilities/container.css +46 -0
- package/framework/css/utilities/decorative.css +442 -0
- package/framework/css/utilities/display.css +257 -0
- package/framework/css/utilities/flexbox.css +80 -0
- package/framework/css/utilities/grid.css +69 -0
- package/framework/css/utilities/icons.css +534 -0
- package/framework/css/utilities/lists.css +190 -0
- package/framework/css/utilities/spacing.css +167 -0
- package/framework/css/utilities/tables.css +81 -0
- package/framework/css/utilities/typography.css +159 -0
- package/framework/css/utilities/visibility.css +117 -0
- package/framework/docs/COURSE_AUTHORING_GUIDE.md +1773 -0
- package/framework/docs/COURSE_OUTLINE_GUIDE.md +725 -0
- package/framework/docs/COURSE_OUTLINE_TEMPLATE.md +161 -0
- package/framework/docs/DATA_MODEL.md +409 -0
- package/framework/docs/FRAMEWORK_GUIDE.md +1088 -0
- package/framework/docs/USER_GUIDE.md +583 -0
- package/framework/docs/examples/cloudflare-channel-relay.js +169 -0
- package/framework/docs/examples/cloudflare-data-worker.js +102 -0
- package/framework/docs/examples/cloudflare-error-worker.js +228 -0
- package/framework/index.html +175 -0
- package/framework/js/app/AppActions.js +410 -0
- package/framework/js/app/AppState.js +225 -0
- package/framework/js/app/AppUI.js +616 -0
- package/framework/js/assessment/AssessmentActions.js +615 -0
- package/framework/js/assessment/AssessmentFactory.js +471 -0
- package/framework/js/assessment/AssessmentState.js +322 -0
- package/framework/js/assessment/AssessmentUI.js +451 -0
- package/framework/js/automation/api-engagement.js +196 -0
- package/framework/js/automation/api-interactions.js +167 -0
- package/framework/js/automation/api.js +242 -0
- package/framework/js/automation/index.js +41 -0
- package/framework/js/components/interactions/drag-drop.js +884 -0
- package/framework/js/components/interactions/fill-in.js +535 -0
- package/framework/js/components/interactions/hotspot.js +702 -0
- package/framework/js/components/interactions/interaction-base.js +511 -0
- package/framework/js/components/interactions/likert.js +301 -0
- package/framework/js/components/interactions/matching.js +699 -0
- package/framework/js/components/interactions/multiple-choice.js +377 -0
- package/framework/js/components/interactions/numeric.js +271 -0
- package/framework/js/components/interactions/sequencing.js +423 -0
- package/framework/js/components/interactions/true-false.js +241 -0
- package/framework/js/components/ui-components/accordion.js +442 -0
- package/framework/js/components/ui-components/alert.js +88 -0
- package/framework/js/components/ui-components/audio-player.js +1193 -0
- package/framework/js/components/ui-components/callout.js +121 -0
- package/framework/js/components/ui-components/carousel.js +145 -0
- package/framework/js/components/ui-components/checkbox-group.js +87 -0
- package/framework/js/components/ui-components/checklist.js +40 -0
- package/framework/js/components/ui-components/collapse.js +114 -0
- package/framework/js/components/ui-components/comparison.js +30 -0
- package/framework/js/components/ui-components/conditional-display.js +150 -0
- package/framework/js/components/ui-components/content-image.js +41 -0
- package/framework/js/components/ui-components/dropdown.js +262 -0
- package/framework/js/components/ui-components/embed-frame.js +274 -0
- package/framework/js/components/ui-components/features.js +33 -0
- package/framework/js/components/ui-components/flip-card.js +230 -0
- package/framework/js/components/ui-components/form-validator.js +76 -0
- package/framework/js/components/ui-components/hero.js +49 -0
- package/framework/js/components/ui-components/index.js +12 -0
- package/framework/js/components/ui-components/interactive-image.js +235 -0
- package/framework/js/components/ui-components/interactive-timeline.js +285 -0
- package/framework/js/components/ui-components/intro-cards.js +35 -0
- package/framework/js/components/ui-components/lightbox.js +652 -0
- package/framework/js/components/ui-components/modal.js +386 -0
- package/framework/js/components/ui-components/notifications.js +145 -0
- package/framework/js/components/ui-components/progress.js +88 -0
- package/framework/js/components/ui-components/quote.js +41 -0
- package/framework/js/components/ui-components/stats.js +33 -0
- package/framework/js/components/ui-components/steps.js +41 -0
- package/framework/js/components/ui-components/tabs.js +255 -0
- package/framework/js/components/ui-components/timeline.js +42 -0
- package/framework/js/components/ui-components/toggle-group.js +73 -0
- package/framework/js/components/ui-components/tooltip.js +458 -0
- package/framework/js/components/ui-components/value-display.js +133 -0
- package/framework/js/components/ui-components/video-player.js +686 -0
- package/framework/js/core/component-catalog.js +121 -0
- package/framework/js/core/event-bus.js +178 -0
- package/framework/js/core/interaction-catalog.js +149 -0
- package/framework/js/dev/runtime-linter.js +1725 -0
- package/framework/js/drivers/cmi5-driver.js +768 -0
- package/framework/js/drivers/driver-factory.js +77 -0
- package/framework/js/drivers/driver-interface.js +110 -0
- package/framework/js/drivers/http-driver-base.js +241 -0
- package/framework/js/drivers/lti-driver.js +508 -0
- package/framework/js/drivers/proxy-driver.js +444 -0
- package/framework/js/drivers/scorm-12-driver.js +560 -0
- package/framework/js/drivers/scorm-2004-driver.js +775 -0
- package/framework/js/drivers/scorm-driver-base.js +112 -0
- package/framework/js/engagement/engagement-manager.js +404 -0
- package/framework/js/engagement/engagement-progress.js +191 -0
- package/framework/js/engagement/engagement-trackers.js +215 -0
- package/framework/js/engagement/requirement-strategies.js +268 -0
- package/framework/js/main.js +727 -0
- package/framework/js/managers/accessibility-manager.js +499 -0
- package/framework/js/managers/assessment-manager.js +230 -0
- package/framework/js/managers/audio-manager.js +944 -0
- package/framework/js/managers/comment-manager.js +88 -0
- package/framework/js/managers/flag-manager.js +86 -0
- package/framework/js/managers/interaction-manager.js +254 -0
- package/framework/js/managers/interaction-registry.js +96 -0
- package/framework/js/managers/objective-manager.js +423 -0
- package/framework/js/managers/score-manager.js +441 -0
- package/framework/js/managers/video-manager.js +536 -0
- package/framework/js/navigation/Breadcrumbs.js +234 -0
- package/framework/js/navigation/NavigationActions.js +1132 -0
- package/framework/js/navigation/NavigationState.js +276 -0
- package/framework/js/navigation/NavigationUI.js +574 -0
- package/framework/js/navigation/document-gallery.js +357 -0
- package/framework/js/navigation/navigation-helpers.js +175 -0
- package/framework/js/navigation/navigation-validators.js +174 -0
- package/framework/js/state/index.js +8 -0
- package/framework/js/state/lms-connection.js +482 -0
- package/framework/js/state/lms-error-utils.js +58 -0
- package/framework/js/state/state-commits.js +200 -0
- package/framework/js/state/state-domains.js +86 -0
- package/framework/js/state/state-manager.js +502 -0
- package/framework/js/state/state-validation.js +311 -0
- package/framework/js/state/transaction-log.js +41 -0
- package/framework/js/state/xapi-statement-service.js +325 -0
- package/framework/js/utilities/access-control.js +99 -0
- package/framework/js/utilities/breakpoint-manager.js +315 -0
- package/framework/js/utilities/canvas-slide.js +35 -0
- package/framework/js/utilities/conditional-display.js +388 -0
- package/framework/js/utilities/course-channel.js +214 -0
- package/framework/js/utilities/course-helpers.js +420 -0
- package/framework/js/utilities/data-reporter.js +273 -0
- package/framework/js/utilities/error-reporter.js +313 -0
- package/framework/js/utilities/hotspot-helper.js +341 -0
- package/framework/js/utilities/icons.js +348 -0
- package/framework/js/utilities/logger.js +92 -0
- package/framework/js/utilities/markdown-renderer.js +45 -0
- package/framework/js/utilities/scroll-tracker.js +68 -0
- package/framework/js/utilities/ui-initializer.js +146 -0
- package/framework/js/utilities/utilities.js +293 -0
- package/framework/js/utilities/view-manager.js +227 -0
- package/framework/js/validation/html-validators.js +422 -0
- package/framework/js/validation/scorm-validators.js +438 -0
- package/framework/js/vendor/pipwerks.js +931 -0
- package/framework/scripts/generate-narration.js +629 -0
- package/framework/scripts/tts-providers/azure-provider.js +178 -0
- package/framework/scripts/tts-providers/base-provider.js +81 -0
- package/framework/scripts/tts-providers/deepgram-provider.js +135 -0
- package/framework/scripts/tts-providers/elevenlabs-provider.js +148 -0
- package/framework/scripts/tts-providers/google-provider.js +272 -0
- package/framework/scripts/tts-providers/index.js +158 -0
- package/framework/scripts/tts-providers/openai-provider.js +143 -0
- package/framework/version.json +63 -0
- package/lib/authoring-api.js +919 -0
- package/lib/build-linter.js +450 -0
- package/lib/build-packaging.js +186 -0
- package/lib/build.js +88 -0
- package/lib/cloud.js +691 -0
- package/lib/convert.js +341 -0
- package/lib/course-parser.js +936 -0
- package/lib/course-writer.js +258 -0
- package/lib/create.js +248 -0
- package/lib/css-index.js +237 -0
- package/lib/dev.js +51 -0
- package/lib/export-content.js +1246 -0
- package/lib/headless-browser.js +413 -0
- package/lib/import.js +377 -0
- package/lib/index.js +80 -0
- package/lib/info.js +79 -0
- package/lib/interaction-formatters.js +568 -0
- package/lib/manifest/cmi5-manifest.js +63 -0
- package/lib/manifest/lti-tool-config.js +53 -0
- package/lib/manifest/manifest-factory.js +99 -0
- package/lib/manifest/scorm-12-manifest.js +61 -0
- package/lib/manifest/scorm-2004-manifest.js +94 -0
- package/lib/manifest/scorm-proxy-manifest.js +104 -0
- package/lib/manifest-parser.js +96 -0
- package/lib/mcp-prompts.js +753 -0
- package/lib/mcp-server.js +316 -0
- package/lib/narration.js +53 -0
- package/lib/pdf-structure.js +142 -0
- package/lib/preview-export.js +231 -0
- package/lib/preview-routes-api.js +662 -0
- package/lib/preview-routes-editing.js +159 -0
- package/lib/preview-routes-lms.js +230 -0
- package/lib/preview-server.js +564 -0
- package/lib/project-utils.js +269 -0
- package/lib/proxy-templates/proxy.html +68 -0
- package/lib/proxy-templates/scorm-bridge.js +112 -0
- package/lib/scaffold.js +193 -0
- package/lib/schema-extractor.js +361 -0
- package/lib/slide-source-editor.js +586 -0
- package/lib/stub-player/app-viewer.js +195 -0
- package/lib/stub-player/app.js +370 -0
- package/lib/stub-player/catalog-panel.js +312 -0
- package/lib/stub-player/config-panel.js +1303 -0
- package/lib/stub-player/content-generator.js +586 -0
- package/lib/stub-player/content-viewer.js +173 -0
- package/lib/stub-player/debug-panel.js +420 -0
- package/lib/stub-player/edit-mode.js +922 -0
- package/lib/stub-player/edit-utils.js +400 -0
- package/lib/stub-player/header-bar.js +354 -0
- package/lib/stub-player/interaction-editor.js +210 -0
- package/lib/stub-player/interactions-panel.js +565 -0
- package/lib/stub-player/lms-api.js +1094 -0
- package/lib/stub-player/login-screen.js +74 -0
- package/lib/stub-player/outline-mode.js +689 -0
- package/lib/stub-player/styles/_assessments-panel.css +245 -0
- package/lib/stub-player/styles/_base.css +89 -0
- package/lib/stub-player/styles/_catalog-icons.css +96 -0
- package/lib/stub-player/styles/_catalog-panel.css +291 -0
- package/lib/stub-player/styles/_config-panel.css +636 -0
- package/lib/stub-player/styles/_content-viewer.css +834 -0
- package/lib/stub-player/styles/_debug-panel.css +576 -0
- package/lib/stub-player/styles/_edit-mode.css +128 -0
- package/lib/stub-player/styles/_header-bar.css +343 -0
- package/lib/stub-player/styles/_interaction-editor.css +140 -0
- package/lib/stub-player/styles/_interactions-panel.css +1038 -0
- package/lib/stub-player/styles/_login-screen.css +102 -0
- package/lib/stub-player/styles/_outline-mode.css +752 -0
- package/lib/stub-player/styles.css +15 -0
- package/lib/stub-player.js +160 -0
- package/lib/test-data-reporting.js +176 -0
- package/lib/test-error-reporting.js +146 -0
- package/lib/token.js +86 -0
- package/lib/upgrade.js +257 -0
- package/lib/validation-rules.js +517 -0
- package/lib/vite-plugin-content-discovery.js +296 -0
- package/package.json +108 -0
- package/schemas/XMLSchema.dtd +402 -0
- package/schemas/adlcp_v1p3.xsd +111 -0
- package/schemas/adlnav_v1p3.xsd +61 -0
- package/schemas/adlseq_v1p3.xsd +93 -0
- package/schemas/common/anyElement.xsd +27 -0
- package/schemas/common/dataTypes.xsd +138 -0
- package/schemas/common/elementNames.xsd +767 -0
- package/schemas/common/elementTypes.xsd +786 -0
- package/schemas/common/rootElement.xsd +31 -0
- package/schemas/common/vocabTypes.xsd +345 -0
- package/schemas/common/vocabValues.xsd +257 -0
- package/schemas/datatypes.dtd +203 -0
- package/schemas/ims_xml.xsd +35 -0
- package/schemas/imscp_v1p1.xsd +368 -0
- package/schemas/imsss_v1p0.xsd +67 -0
- package/schemas/imsss_v1p0auxresource.xsd +19 -0
- package/schemas/imsss_v1p0control.xsd +20 -0
- package/schemas/imsss_v1p0delivery.xsd +17 -0
- package/schemas/imsss_v1p0limit.xsd +47 -0
- package/schemas/imsss_v1p0objective.xsd +67 -0
- package/schemas/imsss_v1p0random.xsd +16 -0
- package/schemas/imsss_v1p0rollup.xsd +46 -0
- package/schemas/imsss_v1p0seqrule.xsd +108 -0
- package/schemas/imsss_v1p0util.xsd +94 -0
- package/schemas/license.txt +17 -0
- package/schemas/lom.xsd +102 -0
- package/schemas/lomCustom.xsd +62 -0
- package/schemas/lomLoose.xsd +62 -0
- package/schemas/lomStrict.xsd +62 -0
- package/schemas/xml.xsd +81 -0
- package/template/.env.example +92 -0
- package/template/course/assets/audio/example-intro.mp3 +0 -0
- package/template/course/assets/audio/example-ui-demo--compact-player.mp3 +0 -0
- package/template/course/assets/audio/example-ui-demo--demo-modal.mp3 +0 -0
- package/template/course/assets/audio/example-ui-demo--full-player.mp3 +0 -0
- package/template/course/assets/docs/example_md_1.md +39 -0
- package/template/course/assets/docs/example_md_2.md +41 -0
- package/template/course/assets/docs/example_pdf_1_thumbnail.png +0 -0
- package/template/course/assets/docs/example_pdf_2.pdf +0 -0
- package/template/course/assets/images/course-architecture.svg +36 -0
- package/template/course/assets/images/logo.svg +14 -0
- package/template/course/assets/widgets/counter-demo.html +190 -0
- package/template/course/assets/widgets/gravity-painter.html +384 -0
- package/template/course/course-config.js +539 -0
- package/template/course/icons.js +19 -0
- package/template/course/interactions/PLUGIN_GUIDE.md +97 -0
- package/template/course/slides/example-course-structure.js +138 -0
- package/template/course/slides/example-final-exam.js +144 -0
- package/template/course/slides/example-finishing.js +127 -0
- package/template/course/slides/example-interactions-showcase.js +615 -0
- package/template/course/slides/example-preview-tour.js +129 -0
- package/template/course/slides/example-remedial.js +143 -0
- package/template/course/slides/example-summary.js +103 -0
- package/template/course/slides/example-ui-showcase.js +1805 -0
- package/template/course/slides/example-welcome.js +123 -0
- package/template/course/slides/example-workflow.js +140 -0
- package/template/course/theme.css +165 -0
- package/template/eslint.config.js +47 -0
- package/template/package.json +28 -0
- package/template/vite.config.js +339 -0
|
@@ -0,0 +1,138 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Course Structure slide - Understanding your course files and folders
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
const { iconManager } = CourseCode;
|
|
6
|
+
|
|
7
|
+
export const slide = {
|
|
8
|
+
render(_root, _context) {
|
|
9
|
+
const container = document.createElement('div');
|
|
10
|
+
container.innerHTML = `
|
|
11
|
+
<div class="stack-lg">
|
|
12
|
+
|
|
13
|
+
<!-- Header -->
|
|
14
|
+
<header class="slide-header">
|
|
15
|
+
<h1>Your Course Files</h1>
|
|
16
|
+
<p>A quick tour of where everything lives in your course project.</p>
|
|
17
|
+
</header>
|
|
18
|
+
|
|
19
|
+
<!-- Folder Structure -->
|
|
20
|
+
<section class="card no-hover">
|
|
21
|
+
<h2 class="text-lg font-bold border-bottom pb-2 mb-4">${iconManager.getIcon('folder')} Project Structure</h2>
|
|
22
|
+
<div class="cols-2 gap-6">
|
|
23
|
+
<div>
|
|
24
|
+
<pre class="bg-gray-100 p-4 rounded text-sm"><code>my-course/
|
|
25
|
+
├── course/ ← <strong>Your content</strong>
|
|
26
|
+
│ ├── course-config.js
|
|
27
|
+
│ ├── slides/
|
|
28
|
+
│ ├── assets/
|
|
29
|
+
│ ├── theme.css
|
|
30
|
+
│ └── references/
|
|
31
|
+
│
|
|
32
|
+
└── framework/ ← <strong>Don't edit</strong>
|
|
33
|
+
└── docs/</code></pre>
|
|
34
|
+
</div>
|
|
35
|
+
<div class="stack-md">
|
|
36
|
+
<div class="callout callout--success callout--compact">
|
|
37
|
+
<strong>course/</strong> - All your content goes here. This is the only folder you'll work with.
|
|
38
|
+
</div>
|
|
39
|
+
<div class="callout callout--compact">
|
|
40
|
+
<strong>framework/</strong> - System files. Your AI assistant uses the docs inside, but you don't need to touch it.
|
|
41
|
+
</div>
|
|
42
|
+
</div>
|
|
43
|
+
</div>
|
|
44
|
+
</section>
|
|
45
|
+
|
|
46
|
+
<!-- Key Files -->
|
|
47
|
+
<section class="card no-hover">
|
|
48
|
+
<h2 class="text-lg font-bold border-bottom pb-2 mb-4">${iconManager.getIcon('file')} Key Files</h2>
|
|
49
|
+
|
|
50
|
+
<div class="accordion" id="files-accordion" data-component="accordion" data-mode="single">
|
|
51
|
+
|
|
52
|
+
<div data-title="course-config.js - Course Settings" data-icon="settings">
|
|
53
|
+
<div class="stack-sm">
|
|
54
|
+
<p>This file controls your entire course structure:</p>
|
|
55
|
+
<ul class="list-styled">
|
|
56
|
+
<li><strong>Metadata</strong> - Title, description, version</li>
|
|
57
|
+
<li><strong>Structure</strong> - Order of slides, sections, and assessments</li>
|
|
58
|
+
<li><strong>Objectives</strong> - Learning goals to track</li>
|
|
59
|
+
<li><strong>Navigation</strong> - How learners move through content</li>
|
|
60
|
+
<li><strong>Engagement</strong> - What learners must complete</li>
|
|
61
|
+
</ul>
|
|
62
|
+
<p class="text-sm text-muted">Your AI assistant will create and modify this file for you.</p>
|
|
63
|
+
</div>
|
|
64
|
+
</div>
|
|
65
|
+
|
|
66
|
+
<div data-title="slides/ - Your Slide Files" data-icon="layers">
|
|
67
|
+
<div class="stack-sm">
|
|
68
|
+
<p>Each slide in your course is a separate file in this folder.</p>
|
|
69
|
+
<ul class="list-styled">
|
|
70
|
+
<li>One file per slide (e.g., <code>intro.js</code>, <code>module-1.js</code>)</li>
|
|
71
|
+
<li>Contains the content: HTML, text, and interactions</li>
|
|
72
|
+
<li>AI generates these based on your outline</li>
|
|
73
|
+
</ul>
|
|
74
|
+
</div>
|
|
75
|
+
</div>
|
|
76
|
+
|
|
77
|
+
<div data-title="assets/ - Media Files" data-icon="image">
|
|
78
|
+
<div class="stack-sm">
|
|
79
|
+
<p>All your media lives here, organized by type:</p>
|
|
80
|
+
<ul class="list-styled">
|
|
81
|
+
<li><strong>images/</strong> - Photos, diagrams, icons</li>
|
|
82
|
+
<li><strong>audio/</strong> - Narration and sound effects</li>
|
|
83
|
+
<li><strong>video/</strong> - Video files (or use YouTube/Vimeo links)</li>
|
|
84
|
+
</ul>
|
|
85
|
+
</div>
|
|
86
|
+
</div>
|
|
87
|
+
|
|
88
|
+
<div data-title="theme.css - Branding" data-icon="palette">
|
|
89
|
+
<div class="stack-sm">
|
|
90
|
+
<p>Customize your course appearance:</p>
|
|
91
|
+
<ul class="list-styled">
|
|
92
|
+
<li>Brand colors (primary, accent, backgrounds)</li>
|
|
93
|
+
<li>Fonts and typography</li>
|
|
94
|
+
<li>Spacing and sizing adjustments</li>
|
|
95
|
+
</ul>
|
|
96
|
+
<p class="text-sm text-muted">We'll cover theming in detail later.</p>
|
|
97
|
+
</div>
|
|
98
|
+
</div>
|
|
99
|
+
|
|
100
|
+
<div data-title="references/ - Source Materials" data-icon="file-text">
|
|
101
|
+
<div class="stack-sm">
|
|
102
|
+
<p>Place your existing content here for conversion:</p>
|
|
103
|
+
<ul class="list-styled">
|
|
104
|
+
<li>PDFs, Word docs, PowerPoints</li>
|
|
105
|
+
<li>Run <code>coursecode convert</code> to process them</li>
|
|
106
|
+
<li>Converted markdown appears in <code>references/converted/</code></li>
|
|
107
|
+
</ul>
|
|
108
|
+
</div>
|
|
109
|
+
</div>
|
|
110
|
+
|
|
111
|
+
</div>
|
|
112
|
+
</section>
|
|
113
|
+
|
|
114
|
+
<!-- Slides vs Sections -->
|
|
115
|
+
<section class="card no-hover">
|
|
116
|
+
<h2 class="text-lg font-bold border-bottom pb-2 mb-4">${iconManager.getIcon('git-branch')} Slides, Sections, and Assessments</h2>
|
|
117
|
+
<div class="cols-3 gap-4">
|
|
118
|
+
<div class="callout callout--info">
|
|
119
|
+
<h3 class="font-bold mb-2">Slides</h3>
|
|
120
|
+
<p class="text-sm">Individual screens of content. Each has its own file and can contain text, media, and interactions.</p>
|
|
121
|
+
</div>
|
|
122
|
+
<div class="callout callout--success">
|
|
123
|
+
<h3 class="font-bold mb-2">Sections</h3>
|
|
124
|
+
<p class="text-sm">Groups of related slides. Appear as expandable folders in the navigation menu.</p>
|
|
125
|
+
</div>
|
|
126
|
+
<div class="callout callout--warning">
|
|
127
|
+
<h3 class="font-bold mb-2">Assessments</h3>
|
|
128
|
+
<p class="text-sm">Graded quizzes. Scores are tracked and reported to your LMS.</p>
|
|
129
|
+
</div>
|
|
130
|
+
</div>
|
|
131
|
+
</section>
|
|
132
|
+
|
|
133
|
+
</div>
|
|
134
|
+
`;
|
|
135
|
+
|
|
136
|
+
return container;
|
|
137
|
+
}
|
|
138
|
+
};
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* FRAMEWORK EXAMPLE SLIDE
|
|
3
|
+
* This is a template example demonstrating assessment patterns. You can keep it as a reference or delete it.
|
|
4
|
+
* See COURSE_AUTHORING_GUIDE.md for full documentation.
|
|
5
|
+
*/
|
|
6
|
+
|
|
7
|
+
const { AssessmentManager } = CourseCode;
|
|
8
|
+
// Standardized named export for assessment configuration.
|
|
9
|
+
// This object is imported by the framework during initialization.
|
|
10
|
+
export const config = {
|
|
11
|
+
// CORE IDENTITY
|
|
12
|
+
id: 'example-final-exam', // Unique SCORM-safe assessment key
|
|
13
|
+
title: 'CourseCode Knowledge Check', // Learner-facing heading
|
|
14
|
+
icon: 'target', // Optional icon name (from framework icon set) displayed before title
|
|
15
|
+
description: `
|
|
16
|
+
<p class="mb-3">Test your understanding of <strong>CourseCode fundamentals</strong>.</p>
|
|
17
|
+
<ul style="list-style: disc; display: inline-block; text-align: left;" class="text-sm">
|
|
18
|
+
<li>LMS standards (SCORM & cmi5)</li>
|
|
19
|
+
<li>Essential CLI commands</li>
|
|
20
|
+
</ul>
|
|
21
|
+
`, // Optional HTML description shown below title
|
|
22
|
+
containerId: 'assessment-container', // DOM node id for rendering
|
|
23
|
+
|
|
24
|
+
// ASSESSMENT BEHAVIOR & CONSTRAINTS
|
|
25
|
+
settings: {
|
|
26
|
+
passingScore: 50, // Minimum % to pass (cmi5: LMS masteryScore can override)
|
|
27
|
+
allowReview: true, // Allow review screen before submission
|
|
28
|
+
showProgress: true, // Display progress bar with question count
|
|
29
|
+
allowRetake: true, // Permit retake flow when learner fails
|
|
30
|
+
randomizeQuestions: false, // Shuffle question order (works with questions array OR questionBanks)
|
|
31
|
+
randomizeOnRetake: true, // Re-randomize on retake (default: true). Set false to keep same questions/order across attempts
|
|
32
|
+
attemptsBeforeRemedial: 1, // After 1 failures, present remedial content (null = disabled)
|
|
33
|
+
attemptsBeforeRestart: 2, // After 2 failures, require course restart (null = disabled, must be > attemptsBeforeRemedial)
|
|
34
|
+
remedialSlideIds: ['example-remedial'] // Slide IDs to navigate to for remedial review (required when attemptsBeforeRemedial is set)
|
|
35
|
+
},
|
|
36
|
+
|
|
37
|
+
// ===== TEMPLATE EXAMPLE: Question Banks =====
|
|
38
|
+
// Uncomment and modify the below to use randomized question banks.
|
|
39
|
+
// This is an advanced feature for courses with multiple question pools.
|
|
40
|
+
// See SCORM_TEMPLATE_README.md for full documentation.
|
|
41
|
+
// =============================================
|
|
42
|
+
// questionBanks: [
|
|
43
|
+
// {
|
|
44
|
+
// id: 'safety-fundamentals',
|
|
45
|
+
// questions: [/* 20 safety questions */],
|
|
46
|
+
// selectCount: 5 // Select 5 random questions from this bank
|
|
47
|
+
// },
|
|
48
|
+
// {
|
|
49
|
+
// id: 'technical-procedures',
|
|
50
|
+
// questions: [/* 30 technical questions */],
|
|
51
|
+
// selectCount: 10 // Select 10 random questions from this bank
|
|
52
|
+
// }
|
|
53
|
+
// ],
|
|
54
|
+
// Note: When using questionBanks, questions are selected on first start and persist through refresh.
|
|
55
|
+
// With randomizeOnRetake: true, new selection occurs on each retake.
|
|
56
|
+
// With randomizeQuestions: true, selected questions are shuffled together.
|
|
57
|
+
|
|
58
|
+
// LEARNER EXPERIENCE
|
|
59
|
+
review: {
|
|
60
|
+
requireAllAnswered: false // Permit submission with unanswered questions
|
|
61
|
+
},
|
|
62
|
+
|
|
63
|
+
// RESULTS
|
|
64
|
+
resultsDisplay: {
|
|
65
|
+
detailLevel: 'detailed', // Render full question-by-question breakdown
|
|
66
|
+
showScore: true, // Display numeric score summary
|
|
67
|
+
showPassFail: true, // Indicate pass or fail status
|
|
68
|
+
showTimeSpent: true, // Show total time spent on assessment
|
|
69
|
+
showQuestions: true, // List each question in results view
|
|
70
|
+
showCorrectAnswers: true, // Reveal correct answers when learner is right
|
|
71
|
+
showIncorrectAnswers: true, // Reveal correct answers when learner is wrong
|
|
72
|
+
showUserResponses: true, // Display learner responses for each question
|
|
73
|
+
showCorrectness: true // Tag questions as correct or incorrect
|
|
74
|
+
},
|
|
75
|
+
|
|
76
|
+
// COMPLETION & PROGRESSION LOGIC
|
|
77
|
+
completionRequirements: {
|
|
78
|
+
requireSubmission: true, // Assessment must be submitted
|
|
79
|
+
requirePass: true, // Assessment must be passed (score >= passingScore)
|
|
80
|
+
blockNavigation: true // Block leaving slide until requirements are met
|
|
81
|
+
},
|
|
82
|
+
};
|
|
83
|
+
|
|
84
|
+
// Standardized named export for the slide component.
|
|
85
|
+
export const slide = {
|
|
86
|
+
assessmentId: config.id,
|
|
87
|
+
render(_root, context = {}) {
|
|
88
|
+
// Defensive: ensure context is always an object (handles null/undefined cases)
|
|
89
|
+
const safeContext = context || {};
|
|
90
|
+
const overrides = safeContext.assessmentConfig || {};
|
|
91
|
+
const containerId = overrides.containerId || config.containerId;
|
|
92
|
+
|
|
93
|
+
// Create and return container element
|
|
94
|
+
const slideContainer = document.createElement('div');
|
|
95
|
+
slideContainer.innerHTML = `<div id="${containerId}"></div>`;
|
|
96
|
+
|
|
97
|
+
// Define assessment questions using InteractionTypes format
|
|
98
|
+
const questions = [
|
|
99
|
+
{
|
|
100
|
+
type: 'multiple-choice',
|
|
101
|
+
id: 'coursecode-fundamentals',
|
|
102
|
+
prompt: 'Which LMS standard does CourseCode support for tracking learner progress?',
|
|
103
|
+
weight: 1,
|
|
104
|
+
choices: [
|
|
105
|
+
{ value: 'scorm', text: 'SCORM 1.2, SCORM 2004, and cmi5', correct: true },
|
|
106
|
+
{ value: 'pdf', text: 'PDF exports only', correct: false },
|
|
107
|
+
{ value: 'html', text: 'Static HTML with no tracking', correct: false },
|
|
108
|
+
{ value: 'video', text: 'Video-only formats', correct: false }
|
|
109
|
+
],
|
|
110
|
+
correctAnswer: 'scorm',
|
|
111
|
+
feedback: {
|
|
112
|
+
correct: 'Correct! CourseCode supports SCORM 1.2, SCORM 2004, and cmi5 standards.',
|
|
113
|
+
incorrect: 'CourseCode supports multiple LMS standards: SCORM 1.2, SCORM 2004, and cmi5 for comprehensive tracking.'
|
|
114
|
+
}
|
|
115
|
+
},
|
|
116
|
+
{
|
|
117
|
+
type: 'fill-in',
|
|
118
|
+
id: 'coursecode-commands',
|
|
119
|
+
prompt: 'Complete the CourseCode CLI commands:',
|
|
120
|
+
weight: 1,
|
|
121
|
+
blanks: [
|
|
122
|
+
{ label: 'To create a new course, run', correct: 'coursecode create', placeholder: 'command' },
|
|
123
|
+
{ label: 'To start development mode, run', correct: 'coursecode dev', placeholder: 'command' },
|
|
124
|
+
{ label: 'To build for production, run', correct: 'coursecode build', placeholder: 'command' }
|
|
125
|
+
],
|
|
126
|
+
caseSensitive: false,
|
|
127
|
+
feedback: {
|
|
128
|
+
correct: 'Perfect! You know the essential CourseCode CLI commands.',
|
|
129
|
+
incorrect: 'The main commands are: coursecode create, coursecode dev, and coursecode build.'
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
];
|
|
133
|
+
|
|
134
|
+
const assessment = AssessmentManager.createAssessment(
|
|
135
|
+
{ ...config, questions },
|
|
136
|
+
overrides
|
|
137
|
+
);
|
|
138
|
+
|
|
139
|
+
const container = slideContainer.querySelector(`#${containerId}`);
|
|
140
|
+
assessment.render(container, safeContext);
|
|
141
|
+
|
|
142
|
+
return slideContainer;
|
|
143
|
+
}
|
|
144
|
+
};
|
|
@@ -0,0 +1,127 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Finishing slide - Theming, branding, and deployment
|
|
3
|
+
*/
|
|
4
|
+
|
|
5
|
+
const { iconManager } = CourseCode;
|
|
6
|
+
|
|
7
|
+
export const slide = {
|
|
8
|
+
render(_root, _context) {
|
|
9
|
+
const container = document.createElement('div');
|
|
10
|
+
container.innerHTML = `
|
|
11
|
+
<div class="stack-lg">
|
|
12
|
+
|
|
13
|
+
<!-- Header -->
|
|
14
|
+
<header class="slide-header">
|
|
15
|
+
<h1>Finishing Your Course</h1>
|
|
16
|
+
<p>Customize the look, then build and deploy to your LMS.</p>
|
|
17
|
+
</header>
|
|
18
|
+
|
|
19
|
+
<!-- Theming Section -->
|
|
20
|
+
<section class="card no-hover">
|
|
21
|
+
<h2 class="text-lg font-bold border-bottom pb-2 mb-4">${iconManager.getIcon('palette')} Theming and Branding</h2>
|
|
22
|
+
<div class="cols-2 gap-6">
|
|
23
|
+
<div class="stack-md">
|
|
24
|
+
<p>Edit <code>course/theme.css</code> to customize your course appearance:</p>
|
|
25
|
+
<ul class="list-styled">
|
|
26
|
+
<li><strong>Primary color</strong> - Buttons, links, accents</li>
|
|
27
|
+
<li><strong>Secondary color</strong> - Alternate highlights</li>
|
|
28
|
+
<li><strong>Background colors</strong> - Page and card backgrounds</li>
|
|
29
|
+
<li><strong>Fonts</strong> - Headings and body text</li>
|
|
30
|
+
</ul>
|
|
31
|
+
</div>
|
|
32
|
+
<div class="callout callout--info callout--compact">
|
|
33
|
+
<strong>${iconManager.getIcon('message-square')} AI Prompt:</strong>
|
|
34
|
+
<p class="text-sm mt-2 font-mono">"Update theme.css to use [your brand color] as the primary color, with [font name] for headings."</p>
|
|
35
|
+
</div>
|
|
36
|
+
</div>
|
|
37
|
+
</section>
|
|
38
|
+
|
|
39
|
+
<!-- Logo and Branding -->
|
|
40
|
+
<section class="card no-hover">
|
|
41
|
+
<h2 class="text-lg font-bold border-bottom pb-2 mb-4">${iconManager.getIcon('image')} Adding Your Logo</h2>
|
|
42
|
+
<div class="stack-md">
|
|
43
|
+
<p>Place your logo in <code>course/assets/images/</code>, then update course-config.js:</p>
|
|
44
|
+
<div class="cols-2 gap-4">
|
|
45
|
+
<pre class="bg-gray-100 p-3 rounded text-sm"><code>branding: {
|
|
46
|
+
logo: './course/assets/images/your-logo.svg',
|
|
47
|
+
logoAlt: 'Your Company',
|
|
48
|
+
companyName: 'Your Company',
|
|
49
|
+
courseTitle: 'Course Name'
|
|
50
|
+
}</code></pre>
|
|
51
|
+
<div class="callout callout--compact">
|
|
52
|
+
<strong>Tip:</strong> SVG logos work best because they scale perfectly at any size.
|
|
53
|
+
</div>
|
|
54
|
+
</div>
|
|
55
|
+
</div>
|
|
56
|
+
</section>
|
|
57
|
+
|
|
58
|
+
<!-- Deployment -->
|
|
59
|
+
<section class="card no-hover">
|
|
60
|
+
<h2 class="text-lg font-bold border-bottom pb-2 mb-4">${iconManager.getIcon('package')} Deploying Your Course</h2>
|
|
61
|
+
<div class="stack-md">
|
|
62
|
+
<p>When your course is ready, build a package for your LMS:</p>
|
|
63
|
+
<pre class="bg-gray-100 p-3 rounded"><code>coursecode build</code></pre>
|
|
64
|
+
|
|
65
|
+
<h3 class="font-bold mt-4">Choosing a Format</h3>
|
|
66
|
+
<p class="text-sm">Your LMS requires a specific format. If you're unsure, ask your LMS admin or try SCORM 1.2.</p>
|
|
67
|
+
<table class="table table-striped">
|
|
68
|
+
<thead>
|
|
69
|
+
<tr>
|
|
70
|
+
<th>Format</th>
|
|
71
|
+
<th>What It Is</th>
|
|
72
|
+
<th>Command</th>
|
|
73
|
+
</tr>
|
|
74
|
+
</thead>
|
|
75
|
+
<tbody>
|
|
76
|
+
<tr>
|
|
77
|
+
<td><strong>cmi5</strong></td>
|
|
78
|
+
<td>Modern standard, rich data</td>
|
|
79
|
+
<td><code>coursecode build</code> (default)</td>
|
|
80
|
+
</tr>
|
|
81
|
+
<tr>
|
|
82
|
+
<td><strong>SCORM 2004</strong></td>
|
|
83
|
+
<td>Enterprise standard</td>
|
|
84
|
+
<td><code>coursecode build --format scorm2004</code></td>
|
|
85
|
+
</tr>
|
|
86
|
+
<tr>
|
|
87
|
+
<td><strong>SCORM 1.2</strong></td>
|
|
88
|
+
<td>Most compatible</td>
|
|
89
|
+
<td><code>coursecode build --format scorm1.2</code></td>
|
|
90
|
+
</tr>
|
|
91
|
+
</tbody>
|
|
92
|
+
</table>
|
|
93
|
+
|
|
94
|
+
<h3 class="font-bold mt-4">CDN Deployment (Advanced)</h3>
|
|
95
|
+
<p class="text-sm">For frequent updates, host on a CDN and upload a tiny proxy to your LMS. Changes go live instantly without re-uploading. Ask your AI about <code>scorm1.2-proxy</code> or <code>cmi5-remote</code> formats.</p>
|
|
96
|
+
</div>
|
|
97
|
+
</section>
|
|
98
|
+
|
|
99
|
+
<!-- Sharing Previews -->
|
|
100
|
+
<section class="card no-hover">
|
|
101
|
+
<h2 class="text-lg font-bold border-bottom pb-2 mb-4">${iconManager.getIcon('share-2')} Sharing for Review</h2>
|
|
102
|
+
<div class="cols-2 gap-6">
|
|
103
|
+
<div class="stack-sm">
|
|
104
|
+
<p>Share your course with stakeholders before LMS deployment:</p>
|
|
105
|
+
<pre class="bg-gray-100 p-3 rounded"><code>coursecode preview --export</code></pre>
|
|
106
|
+
<p>Creates a folder you can upload to any web host (Netlify, GitHub Pages, etc.). Add password protection and other options with flags.</p>
|
|
107
|
+
</div>
|
|
108
|
+
<div class="stack-sm">
|
|
109
|
+
<p><strong>Export content for SME review:</strong></p>
|
|
110
|
+
<pre class="bg-gray-100 p-3 rounded"><code>coursecode export-content -o review.md</code></pre>
|
|
111
|
+
<p class="text-sm text-muted">Extracts all slide text, interactions, and questions into a single document for subject matter expert review.</p>
|
|
112
|
+
</div>
|
|
113
|
+
</div>
|
|
114
|
+
</section>
|
|
115
|
+
|
|
116
|
+
<!-- Next Steps -->
|
|
117
|
+
<div class="callout callout--success">
|
|
118
|
+
<h3 class="font-bold">${iconManager.getIcon('check-circle')} You're Ready!</h3>
|
|
119
|
+
<p>You now know the basics of creating courses with CourseCode. Explore the UI Showcase and Interactions Showcase to see what components are available, then take the assessment to test your knowledge.</p>
|
|
120
|
+
</div>
|
|
121
|
+
|
|
122
|
+
</div>
|
|
123
|
+
`;
|
|
124
|
+
|
|
125
|
+
return container;
|
|
126
|
+
}
|
|
127
|
+
};
|