Skip to content

Commit 5ec0e1a

Browse files
authored
docs: update TOKENS_STUDIO.md release pipeline (css-bundle + exports-map) (#5278)
1 parent 7bff44b commit 5ec0e1a

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

documentation/agent-instructions/TOKENS_STUDIO.md

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -92,8 +92,9 @@ Classify every command before running it:
9292

9393
1. **Trigger:** the outbound **CI Trigger** in Studio (Integrations → CI Triggers, `eds-tokens-release`) sends a `repository_dispatch` event (type `tokens-release`) to this repo on `release.created`. It can be fired manually with its **Test** button.
9494
2. **Auth:** the workflow authenticates back to Studio via GitHub OIDC against the inbound **CI Integration** (Integrations → CI Integration (Inbound); subject pattern `repo:equinor/design-system:ref:refs/heads/main`, read-only). The outbound trigger and the inbound integration are **separate configs** — a 403 `No matching CI integration found` from `studio ... --ci` means the _inbound_ integration is missing or misconfigured, no matter how healthy the trigger looks.
95-
3. **Steps:** `studio tokens pull` (raw token sets → `src/tokens/<alias>/`), `studio exports run` for the two saved configurations — `EDS-CSS` (css) and `EDS-DTCG` (dtcg), referenced by ID — into `src/tokens/css/` and `src/tokens/dtcg/`, then `pnpm run generate:ts-tokens` which combines DTCG structure with evaluated CSS values into TS modules in `src/tokens/ts/` (see the script header in `packages/eds-tokens/scripts/generate-ts-tokens.mjs` for the mechanics, including CSS Color 4 gamut mapping).
96-
4. **Output:** all three directories are committed to the release PR. They are **generated — never edit them by hand**, and they are not yet wired into the package `exports` map.
95+
3. **Steps:** `studio tokens pull` (raw token sets → `src/tokens/<alias>/`), `studio exports run` for the two saved configurations — `EDS-CSS` (css) and `EDS-DTCG` (dtcg), referenced by ID — into `src/tokens/css/` and `src/tokens/dtcg/`, then `pnpm run generate:ts-tokens` which combines DTCG structure with evaluated CSS values into TS modules in `src/tokens/ts/` (see the script header in `packages/eds-tokens/scripts/generate-ts-tokens.mjs` for the mechanics, including CSS Color 4 gamut mapping), and finally `pnpm run generate:css-bundle`, which widens the semantic layer to `:root, [data-color-scheme]` (`scripts/widen-semantic-scope.mjs`, #5226) and concatenates the CSS export into a single committed bundle at `src/tokens/css/variables.css` (plain concatenation, deliberately not minified).
96+
4. **Output:** all four outputs (raw sets, CSS including the bundle, DTCG, TS) are committed to the release PR. They are **generated — never edit them by hand**. On every beta publish, `publish_tokens.yaml` injects them into the package `exports` map as `./next/css/*`, `./next/dtcg/*` and `./next/ts/*` (additively, alongside the stable legacy specifiers — see [`documentation/adr/0009-temporary-next-subpaths-for-eds-tokens-beta.md`](../adr/0009-temporary-next-subpaths-for-eds-tokens-beta.md)), so consumers on the beta line import e.g. `@equinor/eds-tokens/next/css/variables.css`. Storybook loads the beta bundle for the `/next` migration (#5224) — via a relative path locally, since the `./next/*` exports exist only at publish time.
97+
5. **Cadence:** merging the `tokens-studio-release` PR makes release-please add an `eds-tokens` bump to its release PR; merging _that_ publishes `3.0.0-beta.N` to the `beta` dist-tag via `publish_tokens.yaml` — see [`documentation/how-to/BETA_RELEASE_GUIDE.md`](../how-to/BETA_RELEASE_GUIDE.md) § "`@equinor/eds-tokens`: Whole Package in Beta".
9798

9899
## Backup & recovery
99100

0 commit comments

Comments
 (0)