{ "$schema": "../schemas/code-crispies-module-schema.json", "id": "html-semantic", "title": "Semantic HTML", "mode": "html", "description": "Use meaningful HTML elements to structure content properly.", "difficulty": "beginner", "lessons": [ { "id": "semantic-1", "title": "The
Element", "description": "The <article> element represents self-contained content that could be distributed independently, like a blog post, news article, or comment.

<article>\n  <h2>Article Title</h2>\n  <p>Article content...</p>\n</article>
", "task": "Wrap the blog post content in an <article> element.", "previewHTML": "", "previewBaseCSS": "body { font-family: system-ui, sans-serif; padding: 1rem; } article { padding: 1rem; background: #f9f9f9; border-left: 4px solid steelblue; border-radius: 4px; } h2 { margin: 0 0 8px; color: steelblue; } p { margin: 0; color: #555; line-height: 1.5; }", "sandboxCSS": "", "codePrefix": "", "initialCode": "

My First Post

\n

This is a blog post about learning HTML.

", "codeSuffix": "", "solution": "
\n

My First Post

\n

This is a blog post about learning HTML.

\n
", "previewContainer": "preview-area", "validations": [ { "type": "contains", "value": "
", "message": "Add an opening <article> tag" }, { "type": "contains", "value": "
", "message": "Add a closing </article> tag" } ] }, { "id": "semantic-2", "title": "The
Element", "description": "The <section> element represents a thematic grouping of content, typically with a heading. Use it to divide a page into logical sections.

<section>\n  <h2>Features</h2>\n  <p>Our product features...</p>\n</section>
", "task": "Wrap the features content in a <section> element.", "previewHTML": "", "previewBaseCSS": "body { font-family: system-ui, sans-serif; padding: 1rem; } section { padding: 1rem; background: linear-gradient(135deg, #f5f7fa 0%, #c3cfe2 100%); border-radius: 8px; } h2 { margin: 0 0 12px; } ul { margin: 0; padding-left: 1.5rem; } li { margin: 4px 0; color: #444; }", "sandboxCSS": "", "codePrefix": "", "initialCode": "

Features

\n", "codeSuffix": "", "solution": "
\n

Features

\n
    \n
  • Fast performance
  • \n
  • Easy to use
  • \n
\n
", "previewContainer": "preview-area", "validations": [ { "type": "contains", "value": "
", "message": "Add an opening <section> tag" }, { "type": "contains", "value": "
", "message": "Add a closing </section> tag" } ] }, { "id": "semantic-3", "title": "The