mirror of
https://github.com/storytold/gridcraft.git
synced 2026-10-30 05:37:00 -06:00
New Macro (Automate › Macros) and Step Into, Edit and Create in the Macros dialog open a resizable step editor. It works on a draft of the macro and saves it with macro.save. The step list shows each step's number, a breakpoint dot in the gutter (click to set or clear), a category icon, a summary, an error marker and an enabled checkbox; Repeat bodies and If branches are indented under their step, and rows drag to reorder within their list. Add Step opens a command picker (control steps first; commands a macro may never run are left out) and fills in the command's required parameters; Duplicate and Delete act on the selected step. The inspector's Details tab edits the selected step. Reference parameters are reference boxes that take a typed reference or a selection on the grid, with a Rel/Abs switch between a token relative to the example input and an absolute reference, and token suggestions. The Inputs tab sets each input's shape, header and column types (Use current selection as example infers them); the Output tab sets the anchor and the conflict rule. The debug bar has Check (a dry run that colours the grid: inputs blue, writes green, writes over data red), Run, Step, Continue, Run to Here and Stop, which asks whether to keep the changes or undo them. The debugger receives the editor's breakpoints with breakpointsOnly, so a dot cleared while paused takes effect at once; the current step is selected, its parameters are shown as they will run, and its target is outlined on the grid. While a macro is debugged, the status bar says so and Show reopens the editor. List drag and drop lives in a small dnd module. The debugger icons are drawn in code, and the breakpoint and sheet overlay colours are theme tokens covered by the contrast test.