From b055eafd0c798b19409417dafe5da6bb8bb2537f Mon Sep 17 00:00:00 2001 From: Dominik Jain Date: Tue, 20 Jan 2026 12:23:20 +0100 Subject: [PATCH] Mention reverse order of children in flex layouts --- mcp-server/data/prompts.yml | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/mcp-server/data/prompts.yml b/mcp-server/data/prompts.yml index 5a68671..d93bd35 100644 --- a/mcp-server/data/prompts.yml +++ b/mcp-server/data/prompts.yml @@ -86,7 +86,11 @@ initial_instructions: | * **Flex Layout**: `board.flex` - A flexbox-style layout system - Properties: `dir` (direction), `rowGap`, `columnGap`, `alignItems`, `justifyContent` - Padding: `topPadding`, `rightPadding`, `bottomPadding`, `leftPadding`, or combined `verticalPadding`, `horizontalPadding` - - When a board has flex layout, child positions are controlled by the layout system, not by individual x/y coordinates + - When a board has flex layout, + - child positions are controlled by the layout system, not by individual x/y coordinates; + appending or inserting children automatically positions them according to the layout rules. + - IMPORTANT: The order of the `children` array is reversed, but insertion indices correspond to visual order, + i.e. inserting at index 0 places the child visually first, but the child appears last in the `children` array. - To modify spacing: adjust `rowGap` and `columnGap` properties, not individual child positions - Check with: `if (board.flex) { /* board uses flex layout */ }`