{
  "formatVersion": 1,
  "experienceId": "chess-coach",
  "revision": 1,
  "minHostVersion": "0.1.0",
  "title": "One Good Move",
  "subtitle": "A small lesson for a sharper game.",
  "icon": "grid",
  "tint": "#D9D4CB",
  "runtime": "native",
  "tables": [
    {
      "id": "chess.puzzles",
      "name": "Chess lessons",
      "fields": [
        {
          "name": "title",
          "type": "string",
          "required": true
        },
        {
          "name": "fen",
          "type": "string",
          "required": true
        },
        {
          "name": "moves",
          "type": "json",
          "required": true
        },
        {
          "name": "lesson",
          "type": "string",
          "required": false
        }
      ]
    },
    {
      "id": "chess.progress",
      "name": "Chess progress",
      "fields": [
        {
          "name": "puzzleId",
          "type": "reference",
          "required": true,
          "references": "chess.puzzles"
        },
        {
          "name": "complete",
          "type": "boolean",
          "required": false
        },
        {
          "name": "attempts",
          "type": "number",
          "required": false
        }
      ]
    }
  ],
  "seeds": [
    {
      "tableId": "chess.puzzles",
      "id": "ladder-mate",
      "values": {
        "title": "The final rung",
        "fen": "6k1/7R/6K1/8/8/8/8/R7 w - - 0 1",
        "moves": [
          "a1a8"
        ],
        "lesson": "The king on g6 protects the seventh rank. Send the a-rook to the back rank to finish the ladder."
      }
    },
    {
      "tableId": "chess.puzzles",
      "id": "back-rank",
      "values": {
        "title": "A familiar pattern",
        "fen": "6k1/5ppp/8/8/8/8/5PPP/4R1K1 w - - 0 1",
        "moves": [
          "e1e8"
        ],
        "lesson": "The pawns keep their own king on the back rank. The rook can use the open file."
      }
    }
  ],
  "dataBindings": [
    {
      "tableId": "chess.puzzles",
      "access": "write"
    },
    {
      "tableId": "chess.progress",
      "access": "write"
    }
  ],
  "capabilities": [],
  "connections": [],
  "native": {
    "root": {
      "id": "root",
      "type": "stack",
      "props": {
        "gap": 20
      },
      "children": [
        {
          "id": "intro",
          "type": "stack",
          "props": {},
          "children": [
            {
              "id": "eyebrow",
              "type": "text",
              "props": {
                "text": "MADE FOR YOUR EVERYDAY",
                "variant": "eyebrow"
              }
            },
            {
              "id": "heading",
              "type": "text",
              "props": {
                "text": "Find one good move",
                "variant": "title"
              }
            },
            {
              "id": "description",
              "type": "text",
              "props": {
                "text": "Original lessons, legal moves, and progress that stays with you. No connection needed.",
                "variant": "body"
              }
            }
          ]
        },
        {
          "id": "board",
          "type": "chess",
          "props": {
            "tableId": "chess.puzzles",
            "progressTableId": "chess.progress"
          }
        },
        {
          "id": "lessons",
          "type": "list",
          "props": {
            "title": "In your lesson book",
            "tableId": "chess.puzzles",
            "titleField": "title",
            "detailField": "lesson"
          }
        }
      ]
    }
  },
  "assets": [],
  "releaseNotes": "First edition. Sample content is labeled; your edits stay on this device."
}
