← Commit history

demo: send libraryName as well as library - the symbol handler reads only libraryName, so the library constraint was silently dropped

John Lauer ·240a740a47 ·2mo ago ·parent 446575a
1 file changed +5−5
web-control-demo.html+5−5
@@ -1638,12 +1638,12 @@ for (const w of mine) {       var steps = [         { cmd: "kicad_show_symbol", label: "symbol", pick: "symbol editor",           expect: function () { return PART.kicadLib + ":" + (PART.kicadSymbolName || PART.name); },-          args: function () { return { symbolName: PART.kicadSymbolName || PART.name, library: PART.kicadLib }; } },+          args: function () { return { symbolName: PART.kicadSymbolName || PART.name, libraryName: PART.kicadLib, library: PART.kicadLib }; } },         { cmd: "kicad_show_footprint", label: "footprint", pick: "footprint editor",           expect: function () { return PART.kicadLib + ":" + (PART.kicadFootprintName || PART.name); },-          args: function () { return { footprintName: PART.kicadFootprintName || PART.name, library: PART.kicadLib }; } },+          args: function () { return { footprintName: PART.kicadFootprintName || PART.name, libraryName: PART.kicadLib, library: PART.kicadLib }; } },         { cmd: "kicad_show_3d_chip", label: "3D model", pick: "3d viewer",-          args: function () { return { footprintName: PART.kicadFootprintName || PART.name, library: PART.kicadLib }; } }+          args: function () { return { footprintName: PART.kicadFootprintName || PART.name, libraryName: PART.kicadLib, library: PART.kicadLib }; } }       ];       return steps.reduce(function (chain, st) {         return chain.then(function () {@@ -1814,8 +1814,8 @@ for (const w of mine) {   // kicad-bridge #26 closed via the Win32 menu tier in 0.9.99).   [     { label: function () { return "Symbol (" + PART.name + ")"; }, cmd: "kicad_show_symbol", args: function () { return { symbolName: PART.kicadSymbolName || PART.name, libraryName: PART.kicadLib }; }, stage: stageKicadPart, pick: "symbol editor", note: "installs the part from its wiki page, then shows JUST the symbol" },-    { label: function () { return "Footprint (" + PART.name + ")"; }, cmd: "kicad_show_footprint", args: function () { return { footprintName: PART.kicadFootprintName || PART.name, library: PART.kicadLib }; }, stage: stageKicadPart, pick: "footprint editor", note: "just the land pattern: pads + courtyard" },-    { label: function () { return "3D chip (" + PART.name + ")"; }, cmd: "kicad_show_3d_chip", args: function () { return { footprintName: PART.kicadFootprintName || PART.name, library: PART.kicadLib }; }, stage: stageKicadPart, pick: "3d viewer", note: "the part's STEP model on its footprint" },+    { label: function () { return "Footprint (" + PART.name + ")"; }, cmd: "kicad_show_footprint", args: function () { return { footprintName: PART.kicadFootprintName || PART.name, libraryName: PART.kicadLib, library: PART.kicadLib }; }, stage: stageKicadPart, pick: "footprint editor", note: "just the land pattern: pads + courtyard" },+    { label: function () { return "3D chip (" + PART.name + ")"; }, cmd: "kicad_show_3d_chip", args: function () { return { footprintName: PART.kicadFootprintName || PART.name, libraryName: PART.kicadLib, library: PART.kicadLib }; }, stage: stageKicadPart, pick: "3d viewer", note: "the part's STEP model on its footprint" },     { label: function () { return "Library (" + PART.name + " in '" + PART.kicadLib + "') - proves all 3"; }, cmd: "kicad_show_library", proof: true, stage: stageKicadPart, note: "a library IS a symbol + a footprint + a 3D model, so this opens all three and captures one screenshot of each. It reports N/3, and only 3/3 is a pass - a library with a symbol but no 3D model is not a working library." },     { label: function () { return "Schematic (just the " + PART.name + ")"; }, cmd: "kicad_show_schematic", args: function () { return { filePath: (PART.kicadProject || {}).schPath }; }, stage: stageKicadProject, pick: "schematic editor", note: "the generated single-component schematic (kicad_make_part_project)" },     { label: "2D board (part placed, tight edge cuts)", cmd: "kicad_show_2d_board", args: function () { return { filePath: (PART.kicadProject || {}).pcbPath }; }, stage: stageKicadProject, pick: "pcb editor", note: "the part-dominant board" },