Repository navigation
Row/column spacing and wrap; keep formula values of any variable type - #40
Merged
Merged
Conversation
A computed variable holds a ${= ...} formula whatever its declared type;
sanitizing turned a list or map variable's formula into an empty value.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01UErtKMSFkZWHUh8DrQMcZW
RowColumnMixin.spacing (default 0) is the gap between consecutive children along the main axis, like Flutter's Row/Column spacing and Figma auto-layout item spacing. RowColumnNode takes it in its constructor and exposes it as a layout field. JSON omits it when 0 and JSON without it loads as 0 for every RowColumnMixin node. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UErtKMSFkZWHUh8DrQMcZW
RowColumnMixin.wrap (default false) makes a row/column lay its children out like Flutter's Wrap: a row wraps horizontally, a column vertically, with spacing between children of a run and RowColumnMixin.runSpacing (default 0) between runs. The doc comment sets the behavior: the main-axis alignment aligns each run, the cross-axis alignment aligns children in their run and the runs in the free space (stretch/baseline act as start), flex children keep their design size, formula-hidden children take no space or gap, and a hugging cross axis is as thick as the runs. RowColumnNode takes both in its constructor and exposes them as layout fields; JSON omits them at their defaults and old JSON loads them as defaults for every RowColumnMixin node. A wrapping RowColumnNode scrolls along its cross axis (through its runs), as its main axis is where it wraps. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UErtKMSFkZWHUh8DrQMcZW
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01UErtKMSFkZWHUh8DrQMcZW
This was referenced Oct 23, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Model changes the editor and SDK need for gaps found while recreating a code-built app (an RV trip planner) in CodelesslyEditor. The editor changes are in the CodelesslyEditor PR on the same branch name, and the runtime changes are in the CodelesslySDK PR.
This PR is intended ONLY to add:
RowColumnMixin.spacing: the gap between children along the main axis (Flutter'sRow/Columnspacing, Figma item spacing).RowColumnMixin.wrapandrunSpacing: children wrap onto further runs, like Flutter'sWrap. The doc comments describe how alignment and flex behave while wrapping.sanitizeValueForVariableTypekeeps a${= ...}formula as the value for every variable type, so a list or map variable can hold one.All new fields default to 0/false and are left out of JSON at their defaults. Older JSON loads unchanged, and nodes that don't use them serialize the same as before.
Tests:
test/row_column_spacing_test.darttest/row_column_wrap_test.darttest/computed_variable_value_test.dartThe full suite passes (303), and
dart analyze libreports no issues.Known Issues
Generated by Claude Code