Commit Graph
540 Commits
Author SHA1 Message Date
BFlat 33d4cb3cda Merge pull request #2615 from denisg0mes/selection-colors-style-picker
M7: a Selection colors row's Styles button opens the style picker
2026-11-29 15:50:05 +07:00
Denis Gomes 4e31dda79c Merge main: the row's style picker keeps library styles and Create style
Main's Selection colors Styles menu (style_items, create_form) is the
menu this branch replaces with the style picker, so the merge keeps the
picker and drops the menu, with main's focus change inside create_form.
What the menu offered stays in the picker opened from a row: this file's
paint styles and each enabled library's published ones under its name,
Create style for the row's paint (selection.createColorStyle, left out
where create_refusal refuses), colour variables, and Detach.

The picker test now also checks that a library's unpublished style is not
offered, as the menu's test did. "No color styles" goes from he.toml too,
which main added with the key.
2026-11-28 15:03:47 -05:00
Bryton CooperandClaude Opus 5.5 37ff872305 collab-net: serve pinned TLS for app sessions hosted on the network (#1131)
An app hosting a live session for other machines sent the session token
in the clear over plain ws://. Such a host now serves TLS with an
ephemeral self-signed Ed25519 certificate (DER written by hand with ring,
no new crates), and its invite links pin the certificate's SHA-256
(`cert=`, URL-safe base64): figcraft://join?server=wss://…&cert=… and
wss://…/?cert=…

- tls: the shared session is a rustls::Connection (client or server),
  keeping the split reader/writer locking; `accept` answers a server
  handshake by the hello deadline; `handshake_pinned` uses a verifier
  that compares the end-entity certificate's SHA-256 in constant time
  and still checks the TLS 1.2/1.3 handshake signature, refusing any
  other certificate before the Hello with a clear reason.
- invite: Endpoint::cert (None for Endpoint::plain), Endpoint::pinned;
  a malformed pin, one on ws://, or two that disagree is an error that
  never echoes the link. The pin stays out of the WebSocket request URL.
  An automation allowlist entry allows only its own pin.
- host/hub: HostConfig::tls, Host::cert_sha256, Host::endpoint; the hub
  carries the server config to each connection. Hosting::serve (the
  server) is unchanged.
- link: NetLink::host serves TLS for non-loopback binds without a join
  code. Join-code (short) shares stay plain ws://: a 20-symbol code has
  no room for the pin, and its joiners share the token with the link.
- web: the browser refuses a pinned link with a clear reason.

Tests: pinned join and edit sync both ways, a plain client against a
TLS host, a host presenting another certificate (refused, not admitted),
the request carrying neither token nor pin, link round trips and
malformed cert= values.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-28 11:43:29 -07:00
bflatastic ba151a7087 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	ROADMAP.md
2026-11-28 21:16:34 +07:00
bflatastic fa8cb7a382 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	ROADMAP.md
#	crates/mcp/src/tools.rs
#	docs/mcp.md
2026-11-28 20:32:18 +07:00
bflatastic 9ae491f9ea Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	ROADMAP.md
#	docs/components-parity.md
2026-11-28 20:28:39 +07:00
BFlat 97bc1da390 Merge pull request #2693 from storytold/fix/2178-sizing-side-effect-warnings
M2: node.set reports the sizing it changes on other layers and variants their set clips (#2178, #2182)
2026-11-28 18:22:52 +07:00
bflatastic 225d6810bb M7: variables export and import as DTCG design tokens (#1687)
variable.export {format: "dtcg", mode?} writes a group per collection and
a token per variable, nested by the parts of its name: colours as
colorSpace/components objects, numbers as px dimensions or plain numbers
where they are used unitless, aliases as {group.token}, colour
calculations as the colour they show. Strings, booleans, every mode's
value and scopes go under $extensions, so the file reads back whole;
`mode` picks the mode written as $value. Variables > Export offers it,
saved as .tokens.json.

variable.import reads a file holding a $value as tokens: top-level groups
are collections, types are handed down from groups, and color, dimension
(px, rem at 16 px), number, fontWeight, duration, fontFamily, strings,
booleans and aliases become variables, merged as the variables JSON is.
A plain file fills the default mode of the same-named collection.
Composite tokens are skipped and counted in the warnings.
2026-11-28 18:08:53 +07:00
bflatastic fdf0224808 M1: node.create makes a layer with its children in one command (#2185)
node.create (and the MCP create_node tool) takes children: node.create
params made inside the new layer, each with its own children, in one
command and one undo step. The result mirrors the tree, so a batch step
names any layer in it with a field path (children/1/id). A refused
child names its place (children[1].children[0]: ...) and nothing is
made.
2026-11-28 17:52:17 +07:00
BFlat 5330237381 Merge pull request #2686 from B-uchi/pr/docs-design-review-prompt
docs: the Prompts table lists design_review
2026-11-28 17:50:26 +07:00
BFlat 179f7cffff Merge pull request #2681 from Oni-zerone/claude/magical-archimedes-li1vu4
mcp: create_node and set_properties take fields and outline
2026-11-28 17:43:52 +07:00
bflatastic 22fe0ceda1 M2: node.set reports the sizing it changes on other layers and variants its set clips (#2178, #2182)
An edit that turned another layer Fixed (a child set to Fill turning its
hugging parent Fixed, a frame set to Hug turning the children that filled
it Fixed) only showed the canvas notice, so a script got no hint why a
frame stopped growing. node.set now lists each such layer in `warnings`
with its id, name, key and old sizing.

A variant grown or moved past a component set that clips and has no auto
layout keeps being cut off (the set is sized only when variants are
combined or added). node.set now names such a variant in `warnings` and
points at layout.add on the set.
2026-11-28 17:33:14 +07:00
bflatastic fd24ba3d55 Merge remote-tracking branch 'origin/main' into HEAD 2026-11-28 17:03:08 +07:00
bflatastic c57f63a41f Merge remote-tracking branch 'origin/main' into HEAD 2026-11-28 17:02:28 +07:00
B-uchi 6a14526181 docs: the Prompts table lists design_review
The design_review prompt came with the design review commands (#2194),
but the Prompts table in docs/mcp.md never listed it, so the table
showed six of the seven prompts. It now has a row, in prompts/list
order, with its one argument.
2026-11-28 10:27:21 +01:00
B-uchi 6e12172667 docs: implement_design in the MCP guide and the ROADMAP
A row in the Prompts table, a short "Building from a design" section
after visual verification saying which tools the prompt uses, and the
ROADMAP row.
2026-11-28 10:20:02 +01:00
Claude facf27218f mcp: create_node and set_properties take fields and outline
The layers these two tools return can now be cut to the keys an agent
needs, with the same `fields` and `outline` options get_node and
inspect_document take. The options are checked before the edit runs, so
a bad one changes nothing, and without them the result is unchanged.

Closes #2535.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01KudydNWQDXESHDpVmpiqZh
2026-11-28 08:26:42 +00:00
bflatastic 2161144dad Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	ROADMAP.md
2026-11-28 15:06:05 +07:00
BFlat f9bfabad36 Merge pull request #2573 from imanderson/feat/automation-allow-server-join
MCP: allow confined sessions to join an approved server
2026-11-28 15:01:23 +07:00
FredApps bc9c97c7d2 Merge branch 'main' into uno/U1-01-layer-code 2026-11-28 08:11:36 +01:00
FredApps 1f73395b90 Merge branch 'main' into feat/automation-allow-server-join 2026-11-28 08:11:36 +01:00
FredApps a8c90689b0 Merge branch 'main' into feat/variables-json-text-styles-2173 2026-11-28 08:11:36 +01:00
FredApps f278b428cb Merge branch 'main' into feat/automation-allow-server-join
main moved figcraft-cli to RFC-0018 (#2645): main.rs is a thin wrapper and the
dispatch lives in lib.rs, so mcp_roots, the --automation-allow-server handling
and its test move there; headless mcp is checked before the fonts are scanned.
2026-11-28 08:01:38 +01:00
FredApps bb7e878e69 Merge branch 'main' into feat/variables-json-text-styles-2173 2026-11-28 07:40:43 +01:00
FredApps 9562640d75 Merge branch 'main' into uno/U1-01-layer-code 2026-11-28 07:40:32 +01:00
FredApps 4caba4a7d3 Merge branch 'main' into pr/visual-compare 2026-11-28 07:26:27 +01:00
bflatastic d20a121f23 M12: boards: code blocks from the toolbar and the ` key, a language menu, and handles on the left and right edges only (#2237, step 2) 2026-11-28 10:54:57 +07:00
bflatastic e07c9944eb M4: superscript and subscript per range of characters (text.style textPosition, Type settings while editing, text styles, CSS) (#2338) 2026-11-28 08:06:10 +07:00
B-uchi d8b49294d1 M8: a clean comparison says what it checked
A layer is listed only once 2% of the pixels it owns differ, so a few
stray pixels on a large background give `total` 0, and changedPercent,
rounded to one decimal, reads 0 for them. The docs said a clean result
meant no compared pixel differed by more than the tolerance; they now
give the 2% rule and what it leaves out, and the compare_design
description says an empty list doesn't mean every pixel matches.
2026-11-27 18:12:39 +01:00
B-uchi cbd785b4ad docs: visual verification says what a clean result covers and names the frame
The example now passes the frame's `id`; a clean result is described as covering only the area
compared and the layers looked at; `truncated.matchedByBox` is explained. The test of the
differences cap asserts that the list is shorter than the count rather than the cap's value, and
uses a small frame (it took several seconds).
2026-11-27 13:47:49 +01:00
B-uchi f4b6e0d885 M8: visual compare refuses a layer that isn't a frame, component or instance
`inspect.compare` checked only how many targets it had and that the target had a size, so with a
rectangle selected it compared the page against the rectangle, used the rectangle as the viewport,
and returned a result that looked like a real answer. A page is built from a frame, a component or
an instance of one: any other layer, named outright or selected, is now refused before the capture
is read, with what it is and what to pick. The command's and the tool's descriptions and the docs
say so.
2026-11-27 13:19:44 +01:00
B-uchi d53d02b7cd M8: an agent can compare a capture of the page it built with the frame
An agent building a page can't see whether it matches the design. `inspect.compare` and the MCP
tool `compare_design` take a capture the agent's own browser tools made and compare it with a
frame, on this computer. A browser's text and antialiasing never match pixel for pixel, so the
answer isn't one score: it is the layers that differ, each on the deepest layer it belongs to and
largest first, as a position difference (with its offset), a colour difference (expected and
actual) or a content difference. Text is held to twice the tolerance. A capture at 2x is the same
design: the frame's width sets the density.

Explicit targets are validated, and one frame is compared at a time. Parameters of the wrong type
are refused, and so are a path and data together. The capture is size-checked before it is
decoded, the comparison scale is bounded by the larger of the frame and the capture, the layer walk
is iterative and capped (`truncated` says so), and only the 100 differences listed are searched
for a move.
2026-11-27 12:10:51 +01:00
BFlat ffb0676467 Merge pull request #2397 from gmrmad1/fix/2180-create-font-warnings
Text: creating text warns when its font style draws in another face (#2180)
2026-11-27 16:56:59 +07:00
bflatastic 4b99b1930e Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	ROADMAP.md
#	contributors/people.toml
2026-11-27 16:25:37 +07:00
bflatastic 38862eabd0 Merge remote-tracking branch 'origin/main' into HEAD 2026-11-27 16:11:19 +07:00
bflatastic ed640c7449 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	ROADMAP.md
2026-11-27 15:53:31 +07:00
bflatastic 1ce3cd9cfa Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	docs/components-parity.md
2026-11-27 15:47:02 +07:00
bflatastic 0ddaf822fa Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	ROADMAP.md
#	docs/prototyping-parity.md
2026-11-27 15:33:29 +07:00
bflatastic d61e0d6978 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	ROADMAP.md
#	crates/engine/src/lib.rs
2026-11-27 15:27:12 +07:00
bflatastic 43ea030d4f Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	docs/components-parity.md
2026-11-27 15:22:26 +07:00
bflatastic d6dee9dbb0 Merge remote-tracking branch 'origin/main' into HEAD 2026-11-27 15:21:14 +07:00
bflatastic b6257d6969 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	docs/components-parity.md
2026-11-27 15:20:33 +07:00
bflatastic 1c5f6f60d0 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	docs/ui-parity.md
2026-11-27 14:40:03 +07:00
bflatastic 8ed8860632 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	docs/components-parity.md
2026-11-27 14:39:29 +07:00
bflatastic 522c55e62f Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	crates/engine/src/design_context_tests.rs
#	crates/ui-egui/src/panels/dev_mode.rs
#	docs/dev-mode-parity.md
2026-11-27 14:39:13 +07:00
BFlat 075e5a21c8 Merge pull request #2613 from denisg0mes/paste-library-main-as-instance
M3: a main pasted from its library file into another file is an instance of it
2026-11-27 14:39:11 +07:00
bflatastic 2fd043874a M3: variables can be sorted and reordered in the Local variables window (#2633) 2026-11-27 14:38:15 +07:00
bflatastic bb02b6ff09 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	docs/ui-parity.md
2026-11-27 14:38:04 +07:00
bflatastic e167b6b452 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	crates/mcp/tests/it/main.rs
2026-11-27 14:26:51 +07:00
bflatastic 85c760b094 Merge remote-tracking branch 'origin/main' into HEAD
# Conflicts:
#	docs/components-parity.md
2026-11-27 14:24:56 +07:00