// This skill generates interactive comparison table MicroSims for educational content. Use this skill when users need to create side-by-side comparisons of items with star ratings (1-5 scale), difficulty badges (Easy/Medium/Hard), logos, hover tooltips, and description columns. The skill creates a complete MicroSim package with HTML, CSS, logos directory, index.md documentation, and metadata.json, then updates mkdocs.yml navigation.
| name | comparison-table-generator |
| description | This skill generates interactive comparison table MicroSims for educational content. Use this skill when users need to create side-by-side comparisons of items with star ratings (1-5 scale), difficulty badges (Easy/Medium/Hard), logos, hover tooltips, and description columns. The skill creates a complete MicroSim package with HTML, CSS, logos directory, index.md documentation, and metadata.json, then updates mkdocs.yml navigation. |
This skill generates interactive comparison table MicroSims that allow students to compare multiple items across several criteria. Each table includes color-coded star ratings, difficulty/category badges, logos, hover tooltips with descriptions, and a responsive design. The output follows the microsim-standardization skill standards including proper index.md documentation, metadata.json with Dublin Core elements, and mkdocs.yml navigation updates.
Use this skill when:
Ask the user for the following information:
linux-distro-comparison)Create the MicroSim directory at docs/sims/[microsim-name]/ with:
docs/sims/[microsim-name]/
├── index.md # Documentation page
├── main.html # Interactive comparison table
├── style.css # Styling with star colors, badges, tooltips
├── metadata.json # Dublin Core metadata
└── logos/ # SVG logo files for each item
├── item1.svg
├── item2.svg
└── ...
Use the template in assets/main-template.html as the base. Key customization points:
<title> and <h2> elements<thead> columns<tr> with:
data-tooltip attribute containing the item description.distro-cell classStar Rating Pattern:
<!-- 4 out of 5 stars (yellow-green) -->
<td class="rating">
<span class="stars stars-4">★★★★</span>
<span class="stars-empty">★</span>
</td>
Star color classes:
stars-5: Green (#22c55e) - Excellentstars-4: Yellow-green (#84cc16) - Very Goodstars-3: Orange (#f59e0b) - Good/Averagestars-2: Red-orange (#f97316) - Below Averagestars-1: Red (#ef4444) - PoorFirst Row Note: The first row's tooltip automatically appears BELOW instead of above to avoid being hidden by the header.
Copy the template from assets/style-template.css. The CSS includes:
Customization may be needed for:
Use the template in assets/index-template.md to create documentation that includes:
Create Dublin Core metadata following the schema in assets/metadata-schema.json:
{
"title": "Comparison Table Title",
"description": "Interactive comparison table showing...",
"creator": "Author Name",
"date": "YYYY-MM-DD",
"subject": ["comparison", "keyword1", "keyword2"],
"type": "Interactive Simulation",
"format": "text/html",
"language": "en-US",
"rights": "CC BY 4.0",
"educationalLevel": "High School",
"learningResourceType": "comparison table",
"library": "CSS (no JavaScript library)"
}
Place SVG logo files in the logos/ subdirectory:
debian.svg, arch-linux.svg)If logos are not provided, prompt the user to:
Add the new MicroSim to the site navigation in mkdocs.yml:
nav: sectionnav:
- Simulations:
- Comparison Table Name: sims/microsim-name/index.md
After creating all files:
mkdocs serve to preview the resultTo use categories other than Easy/Medium/Hard:
.difficulty patternThe default uses semantic colors (green=good, red=poor). To customize:
.stars-1 through .stars-5 in style.cssThe template supports:
For new column types, add appropriate CSS classes.
Complete HTML template for the comparison table with:
Complete CSS stylesheet including:
Documentation template following microsim-standardization standards:
JSON Schema for validating metadata.json files (copied from microsim-standardization skill).
Sample metadata.json with all Dublin Core fields.