Skip to content

feat(platforms): platform cascade in render, SPEC-076, platform-owned recipes and componentAliases (5/6) - #1581

Merged
GarthDB merged 18 commits into
next/visual-recipesfrom
feat/platform-cascade-s5
Nov 1, 2026
Merged

GarthDB merged 18 commits into
next/visual-recipesfrom
feat/platform-cascade-s5

Conversation

@GarthDB

@GarthDB GarthDB commented Nov 1, 2026 •

Copy link
Copy Markdown
Member

Squash merge is fine; the next slice is rebased onto the result.

Description

Slice 5 of 6 from #1569, into next/visual-recipes. Stacked on slice 4 (#1580), now merged. It lets a platform manifest drive rendering and makes platform-owned visual recipes loadable and checkable.

  • Render through a platform: design-data render and design-data site accept --platform <id> (or DESIGN_DATA_PLATFORM / default_platform) and apply the Foundation to Platform cascade before building scenes. WASM adds Dataset.applyPlatform(manifest). With no platform selected, output is unchanged.
  • SPEC-076 (warning): every token or relationship binding a recipe resolves on the foundation must also resolve under the platform. design-data validate --platform <id> --visuals-path <dir> names each dropped binding. The iOS manifest drops its include whitelist, which hid the height, padding, font-size and icon-size tokens recipes bind.
  • Platform-owned recipes: a platform's extensions/visuals/<component>.json loads into graph.visuals with layer: Platform and replaces the foundation recipe of the same name. manifest.schema.json accepts componentAliases; SPEC-081 (error) checks aliases. TokenGraph::canonical_component returns the alias target; render, site and WASM do not call it yet.
  • Spec text and rules: component-visuals.md and manifest.md describe platform recipes; rules.yaml adds SPEC-076, SPEC-079 (warning, an error one minor version later, planned), SPEC-080 (info, planned) and SPEC-081. SPEC-077 and SPEC-078 stay reserved by artifact-moves.md.
  • Docs: artifact-moves.md (promoting and demoting one artifact between a platform and the foundation; proposed, not implemented) and proposal 014 (platform-owned visual recipes and the iOS Button).
  • CI: root:validate-platform-recipes (SPEC-079 guard) and its test run in CI; both are added to .github/ci-targets.json (root:test-platform-recipes-guard in .node[], root:validate-platform-recipes in .rust[]).

Changesets (5): render-platform-cascade, platform-recipe-check, platform-recipes-core, platform-recipes-spec-text, artifact-moves.

Dropped from the original range because they are already on main: the override fixes released in #1573 (bbb42746, 7bd60e1d, ac5845ee, c646f953, 89a6018a, 674130ac) and the changeset wrap 22b45707. Their changesets figma-export-override-modes and platform-override-keeps-fields were already released and are not in this PR, so no changeset is consumed twice.

Dropped only in part: the cascade audit test f28fb389. Main has a newer platform_cascade.rs with the other cascade tests, but not render_follows_the_platform_cascade or its fill_of helper. The last commit of this PR (test(sdk): restore the render-follows-the-cascade test and fill_of helper, test only, no changeset) restores those two.

Related Issue

Part of #1569 (sliced under bead p6ga.9).

Motivation and Context

A platform such as iOS owns tokens, components and now recipes, but render and validate only knew the foundation. Applying the cascade first makes the preview match what the platform ships, and SPEC-076 catches recipes that silently draw nothing under a platform. The planned rules and aliases are specified here so slice 6 can build on them.

How Has This Been Tested?

Run in a clean worktree on this branch (macOS):

  • Every commit builds: cargo check --workspace --all-targets at each of the 17 commits.
  • cargo fmt --check, cargo clippy --workspace --all-targets -- -D warnings
  • moon run sdk:test sdk-wasm:test design-data:validate design-data:validate-dataset tokens:verifyLegacyOutput root:validate-platform-recipes root:test-platform-recipes-guard --force: 1710 Rust tests passed (2 skipped), 119 WASM tests passed; the working tree stayed clean, so no snapshot, golden or legacy output changed
  • node tools/changeset-linter/src/cli.js check --fail-on-warnings (15 files, 0 warnings), node .github/scripts/check-ci-coverage.mjs (0 uncovered; it failed before the ci-targets.json commit), pnpm ai:check
  • Root pnpm-lock.yaml diff is empty
  • New tests: sdk/cli/tests/cli_platform.rs, cli_manifest.rs (SPEC-076 through validate --platform), sdk/core/tests/platform_cascade.rs, conformance fixtures invalid/SPEC-076 and invalid/SPEC-081, validate-platform-recipes.test.mjs, and sdk/wasm/test/render.test.js.

Screenshots (if appropriate):

None.

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • I have signed the Adobe Open Source CLA.
  • My code follows the code style of this project.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have read the CONTRIBUTING document.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

Review guide (reading order)

  1. docs/proposals/014-platform-owned-visual-recipes.md (long; the intent), then packages/design-data-spec/spec/component-visuals.md, manifest.md, rules/rules.yaml, schemas/manifest.schema.json.
  2. sdk/core/src/manifest.rs, graph.rs: loading platform visuals, componentAliases, canonical_component.
  3. sdk/core/src/validate/rules/spec076.rs, spec081.rs, validate/mod.rs, and the fixtures conformance/invalid/SPEC-076, SPEC-081.
  4. sdk/cli/src/main.rs, sdk/cli/tests/cli_platform.rs, cli_manifest.rs; then sdk/plugins/site and sdk/wasm/src/dataset.rs, test/render.test.js: render and site through a platform.
  5. platforms/ios/manifest.json, platforms/README.md.
  6. .github/scripts/validate-platform-recipes.mjs, its test and fixtures, moon.yml, .github/ci-targets.json.
  7. packages/design-data-spec/spec/artifact-moves.md, index.md (docs only, independent of the rest).
  8. The five changesets under .changeset/.

test added 16 commits October 31, 2026 18:07
Adds spec/artifact-moves.md and a platforms/README.md section with two worked examples.

SPEC-077, SPEC-078 and lifecycle.moves are proposed, not implemented.
…ga.8.7)

Design for letting a platform ship its own recipes: extensions/visuals,
replace precedence, a button-ios component with a button alias, SPEC-077 to 079,
loading across render, site and WASM, and a first iOS Button slice. Records the
scoped exception that lets platform-owned components bind tokens directly.
SPEC-077 and SPEC-078 are reserved elsewhere.
@changeset-bot

changeset-bot Bot commented Nov 1, 2026 •

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: f077b2a

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 15 packages
Name Type
@adobe/design-data-spec Minor
@adobe/spectrum-design-data Patch
@adobe/design-data-wasm Minor
@adobe/design-data-tui Patch
@adobe/spectrum-component-api-schemas Patch
@adobe/design-data Patch
@adobe/design-system-registry Patch
@adobe/design-data-agent-mcp Patch
@adobe/design-data-mcp Patch
markdown-generator Patch
@adobe/token-corpus-migrate Patch
@adobe/token-naming-audit Patch
s2-tokens-viewer Patch
@adobe/spectrum-design-data-mcp Patch
component-options-editor Patch

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@github-actions

github-actions Bot commented Nov 1, 2026 •

Copy link
Copy Markdown
Contributor

Run report for f077b2a0

Total time: 9m 13s | Comparison time: 26m 11s | Estimated savings: 16m 58s (64.8% faster)

Action Time Status Info
⬛️ SetupProto(0.57.4) 0ms Skipped
🟩 SyncWorkspace 15.5ms Passed
🟩 SyncProject(design-data-spec) 2.6ms Passed
⬛️ SetupToolchain(node:20.17.0) 146.3ms Skipped
🟩 SyncProject(sdk) 188.5ms Passed
🟩 SyncProject(sdk-wasm) 1ms Passed
🟩 SyncProject(design-data) 1.5ms Passed
🟩 SyncProject(root) 0.6ms Passed
🟩 SyncProject(design-data-glue) 0.8ms Passed
🟩 SyncProject(design-data-mcp) 0.9ms Passed
⬛️ SetupToolchain(pnpm:10.17.1) 111.4ms Skipped
⬛️ SetupToolchain(javascript) 0ms Skipped
🟩 SetupEnvironment(javascript) 0.5ms Passed
⬛️ InstallDependencies(javascript) 0.1ms Skipped
⬛️ SetupEnvironment(javascript, sdk) 0.6ms Skipped
⬛️ SetupToolchain(rust:1.88.0) 293.7ms Skipped
🟩 SetupEnvironment(rust, sdk) 131.6ms Passed
⬛️ InstallDependencies(rust, sdk) 2.7ms Skipped
🟩 RunTask(sdk:fmt-check) 1.6s Passed
🟩 InstallDependencies(javascript, sdk) 4.9s Passed
And 14 more...
Expanded report
Action Time Status Info
🟩 RunTask(sdk:codegen-check) 289.2ms Passed
🟩 RunTask(sdk:lint) 1m 1s Passed
🟩 RunTask(sdk:build) 1m 58s Passed
🟩 RunTask(sdk:test-doc) 2m 30s Passed SLOW
🟩 RunTask(sdk-wasm:cache-build) 3m 15s Passed SLOW
🟩 RunTask(root:validate-platforms) 9.8s Passed
🟩 RunTask(root:validate-platform-recipes) 3m 41s Passed SLOW
🟩 RunTask(sdk:test) 7m 30s Passed SLOW
🟩 RunTask(sdk-wasm:site-data) 5m 33s Passed SLOW
🟩 RunTask(sdk-wasm:build) 4m 27s Passed SLOW
🟩 RunTask(design-data-mcp:stage) 1.8s Passed
🟩 RunTask(design-data-agent-mcp:test) 11.9s Passed
🟩 RunTask(sdk-wasm:test) 18.8s Passed
🟩 RunTask(sdk-wasm:ci) 14.5ms Passed
Changed files
.changeset/anatomy-definition-and-review.md
.changeset/artifact-moves.md
.changeset/platform-recipe-check.md
.changeset/platform-recipes-core.md
.changeset/platform-recipes-spec-text.md
.changeset/render-platform-cascade.md
.github/ci-targets.json
.github/scripts/fixtures/platform-recipes-clean.json
.github/scripts/fixtures/platform-recipes-spec079.json
.github/scripts/validate-platform-recipes.mjs
.github/scripts/validate-platform-recipes.test.mjs
docs/proposals/014-platform-owned-visual-recipes.md
moon.yml
packages/design-data-spec/conformance/README.md
packages/design-data-spec/conformance/invalid/SPEC-076/dataset.json
packages/design-data-spec/conformance/invalid/SPEC-076/expected-errors.json
packages/design-data-spec/conformance/invalid/SPEC-076/manifest.json
packages/design-data-spec/conformance/invalid/SPEC-081/dataset.json
packages/design-data-spec/conformance/invalid/SPEC-081/expected-errors.json
packages/design-data-spec/conformance/invalid/SPEC-081/manifest.json
packages/design-data-spec/rules/rules.yaml
packages/design-data-spec/schemas/manifest.schema.json
packages/design-data-spec/spec/artifact-moves.md
packages/design-data-spec/spec/component-visuals.md
packages/design-data-spec/spec/index.md
packages/design-data-spec/spec/manifest.md
platforms/README.md
platforms/ios/manifest.json
sdk/cli/src/main.rs
sdk/cli/tests/cli_manifest.rs
sdk/cli/tests/cli_platform.rs
sdk/core/src/graph.rs
sdk/core/src/lib.rs
sdk/core/src/manifest.rs
sdk/core/src/validate/mod.rs
sdk/core/src/validate/rules/mod.rs
sdk/core/src/validate/rules/spec060.rs
sdk/core/src/validate/rules/spec061.rs
sdk/core/src/validate/rules/spec062.rs
sdk/core/src/validate/rules/spec063.rs
sdk/core/src/validate/rules/spec065.rs
sdk/core/src/validate/rules/spec066.rs
sdk/core/src/validate/rules/spec076.rs
sdk/core/src/validate/rules/spec081.rs
sdk/core/src/validate/rules/visual_util.rs
sdk/core/tests/platform_cascade.rs
sdk/plugins/site/assets/backend.js
sdk/plugins/site/assets/index.html
sdk/plugins/site/src/lib.rs
sdk/wasm/src/dataset.rs
sdk/wasm/test/render.test.js

@github-actions

github-actions Bot commented Nov 1, 2026

Copy link
Copy Markdown
Contributor

🎨 Token Changes Report

Tokens Changed (0)

Original Branch: next/visual-recipes


This comment was automatically generated by the token diff tool. 🤖

@github-actions

github-actions Bot commented Nov 1, 2026

Copy link
Copy Markdown
Contributor

🧩 Component Schema Changes Report

No component schema changes detected.

This comment was automatically generated by the component schema diff tool. 🤖

…lper

f28fb38 was dropped from this slice because main has a newer
platform_cascade.rs. Main has the other cascade tests but not
render_follows_the_platform_cascade or its fill_of helper, so re-apply
those two on top of the current file. They render a widget through the
foundation and a fixture platform and check that an override re-points
the binding, an extension relationship binds an extension token, and a
binding the platform removed reports a diagnostic instead of drawing
nothing.

Test only; no changeset.
@GarthDB
GarthDB force-pushed the feat/platform-cascade-s5 branch from a504c5c to 70bfd03 Compare November 1, 2026 00:30
@GarthDB
GarthDB force-pushed the feat/platform-cascade-s5 branch from 70bfd03 to f077b2a Compare November 1, 2026 00:44
@GarthDB
GarthDB merged commit 129a6fd into next/visual-recipes Nov 1, 2026
9 checks passed
@GarthDB
GarthDB deleted the feat/platform-cascade-s5 branch November 1, 2026 01:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant