Files
fabula-ultima-html/data/spells.schema.json
Drew Malzahn 3effb0406e feat: Add template spell picker from spells.yml; polish spell table
- Add yaml-loader; import data/spells.yml at build time
- Add SpellTemplate/SpellsFile types to globals.d.ts
- Add 'Add Template Spell' button that opens a modal picker pre-filling
  all spell fields from the YAML data
- Move spell data files into data/ directory
- Split spell rows into inputs row + full-width notes row (colspan=6)
- Shrink delete column to fit-content; bold spell name input
- Add class column to spell table; change MP cost to free-text input
- Auto-resize spell notes textarea on load and on input
- Add 10px padding between spells for visual separation

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-06-26 17:52:02 -04:00

51 lines
1.6 KiB
JSON

{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"$id": "data/spells.schema.json",
"title": "Spell Sheet",
"description": "A collection of Fabula Ultima spells and arcana entries.",
"type": "object",
"properties": {
"spells": {
"type": "array",
"items": {
"type": "object",
"properties": {
"name": {
"type": "string",
"description": "Name of the spell or arcana."
},
"cost": {
"type": "string",
"minimum": 0,
"description": "MP cost to cast the spell."
},
"targets": {
"type": "string",
"description": "Who or what the spell affects (e.g. \"One creature\", \"All enemies\")."
},
"duration": {
"type": "string",
"description": "How long the spell's effect lasts (e.g. \"Instantaneous\", \"Scene\")."
},
"description": {
"type": "string",
"description": "Full effect description and any special rules for the spell."
},
"class": {
"type": "string",
"enum": ["arcanist", "chimerist", "elementalist", "entropist", "spiritist"],
"description": "The magic-using class this spell belongs to."
},
"offensive": {
"type": "boolean",
"description": "Whether the spell is offensive in nature."
}
},
"required": ["name", "cost", "targets", "duration", "description", "class"],
"additionalProperties": false
}
}
},
"required": ["spells"]
}