map: キーマップレイヤーを並び順と独立した名前で識別する

レイヤーを切り替える動作も名前で参照し、番号へは出力時に並び順から
変換する。並べ替えや挿入で参照先がずれないようにするため。
スキーマのlayerからidを外し、MAP内で一意なnameを識別子とする。

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01CBmwYrXocgCoFJfxVcKSGH
This commit is contained in:
2026-09-23 14:51:21 +09:00
co-authored by Claude Opus 5.5
parent 54f292b08e
commit 63da6e77d8
2 changed files with 11 additions and 3 deletions
+5 -3
View File
@@ -646,10 +646,12 @@ ELC・IDX・MAPはどれもPHYを参照する。ELCはIDXを参照せず、MAP
"$defs": {
"layer": {
"type": "object",
"required": ["id", "name", "keymap"],
"required": ["name", "keymap"],
"properties": {
"id": { "type": "integer", "minimum": 0 },
"name": { "type": "string" },
"name": {
"type": "string",
"description": "Layer identifier, unique within the MAP. Layer order is the array order"
},
"keymap": {
"type": "array",
"items": {