Computed flow layout, and mobile written into the design
The canvas lays itself out: a layered graph, left to right on a desktop and top to bottom on a phone, with room reserved for the value each edge carries. Nodes cannot be dragged and `NodeDef.position` is gone from the document — a graph nobody can arrange is one worth keeping small, which is what keeps flows atomic. Endpoints join the same layout, so their lanes and the localStorage that remembered where they were dragged go too. Mobile, per the new Responsive section of DESIGN-GUIDELINES.md: the dock caps its width and wraps instead of running off the screen, the dashboard stacks into one column rather than shrinking a wall panel to a fifth of its size, and Home stops widening its grid track past the viewport. A Playwright project at a phone's width fails the build when a screen no longer fits. Along the way: publish is the checkmark that was already there rather than a button that appears and disappears, with discard beside it on both the flow and the dashboard; the brain reveals a neuron's name on the first tap; and the port sparklines get room to breathe. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01VDSXaRhvqHYNevgDGmNAto
This commit is contained in:
@@ -1306,13 +1306,6 @@ export const NodeDef_InputSchema = {
|
||||
title: 'Title',
|
||||
default: ''
|
||||
},
|
||||
position: {
|
||||
'$ref': '#/components/schemas/Position',
|
||||
default: {
|
||||
x: 0,
|
||||
y: 0
|
||||
}
|
||||
},
|
||||
params: {
|
||||
additionalProperties: true,
|
||||
type: 'object',
|
||||
@@ -1360,7 +1353,11 @@ export const NodeDef_InputSchema = {
|
||||
type: 'object',
|
||||
required: ['id'],
|
||||
title: 'NodeDef',
|
||||
description: 'A node as stored: identity, placement, configuration and ports.'
|
||||
description: `A node as stored: identity, configuration and ports.
|
||||
|
||||
Deliberately no canvas position. The editor lays a flow out itself, so
|
||||
where a node sits is a fact about the drawing rather than about the flow —
|
||||
and a graph nobody can arrange is one worth keeping small.`
|
||||
} as const;
|
||||
|
||||
export const NodeDef_OutputSchema = {
|
||||
@@ -1379,13 +1376,6 @@ export const NodeDef_OutputSchema = {
|
||||
title: 'Title',
|
||||
default: ''
|
||||
},
|
||||
position: {
|
||||
'$ref': '#/components/schemas/Position',
|
||||
default: {
|
||||
x: 0,
|
||||
y: 0
|
||||
}
|
||||
},
|
||||
params: {
|
||||
additionalProperties: true,
|
||||
type: 'object',
|
||||
@@ -1433,7 +1423,11 @@ export const NodeDef_OutputSchema = {
|
||||
type: 'object',
|
||||
required: ['id'],
|
||||
title: 'NodeDef',
|
||||
description: 'A node as stored: identity, placement, configuration and ports.'
|
||||
description: `A node as stored: identity, configuration and ports.
|
||||
|
||||
Deliberately no canvas position. The editor lays a flow out itself, so
|
||||
where a node sits is a fact about the drawing rather than about the flow —
|
||||
and a graph nobody can arrange is one worth keeping small.`
|
||||
} as const;
|
||||
|
||||
export const NodeSourceSchema = {
|
||||
@@ -1782,24 +1776,6 @@ export const PlacementSchema = {
|
||||
description: "Where a widget sits in its section's grid, in grid units."
|
||||
} as const;
|
||||
|
||||
export const PositionSchema = {
|
||||
properties: {
|
||||
x: {
|
||||
type: 'number',
|
||||
title: 'X',
|
||||
default: 0
|
||||
},
|
||||
y: {
|
||||
type: 'number',
|
||||
title: 'Y',
|
||||
default: 0
|
||||
}
|
||||
},
|
||||
type: 'object',
|
||||
title: 'Position',
|
||||
description: 'Where a node sits on the canvas.'
|
||||
} as const;
|
||||
|
||||
export const PrivateUserCreateSchema = {
|
||||
properties: {
|
||||
email: {
|
||||
|
||||
Reference in New Issue
Block a user