@adobe/spectrum-tokens 14.2.1 → 14.2.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # [**@adobe/spectrum-tokens**](https://github.com/adobe/spectrum-design-data)
2
2
 
3
+ ## 14.2.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [#741](https://github.com/adobe/spectrum-design-data/pull/741) [`3f05fcf`](https://github.com/adobe/spectrum-design-data/commit/3f05fcffcd8641c822a54c4cdd37ba452dab455c) Thanks [@GarthDB](https://github.com/GarthDB)! - Add naming-exceptions.json and SPEC-007 (name-roundtrip) validation
8
+ rule. Tracks 194 legacy token names that cannot be deterministically
9
+ generated from a structured name object (167 state-position, 27
10
+ compound-state). This infrastructure supports the migration path from
11
+ legacy flat kebab-case names to structured name objects.
12
+
13
+ - [#740](https://github.com/adobe/spectrum-design-data/pull/740) [`956d61a`](https://github.com/adobe/spectrum-design-data/commit/956d61a00f154e7c488edf6916b0ce16945a814c) Thanks [@GarthDB](https://github.com/GarthDB)! - Add `token-file.json` schema for legacy token maps, a validation snapshot, and Moon tasks that run
14
+ the `design-data` CLI (`validate` / `migrate verify`) against `src/` and `schemas/`.
15
+
3
16
  ## 14.2.1
4
17
 
5
18
  ### Patch Changes
package/README.md CHANGED
@@ -8,6 +8,16 @@ Design tokens are directly integrated into our component libraries, UI kits, and
8
8
 
9
9
  Follow the monorepo [setup guide](../../README.md#setup-monorepo-locally).
10
10
 
11
+ ## Design Data validation
12
+
13
+ Moon tasks run the Rust `design-data` CLI against `src/` and `schemas/`:
14
+
15
+ * `moon run tokens:validateDesignData` — JSON Schema (Layer 1) + catalog rules (Layer 2)
16
+ * `moon run tokens:verifyDesignDataSnapshot` — same as above, compared to
17
+ `snapshots/validation-snapshot.json` (update with `design-data migrate snapshot` when outputs change)
18
+
19
+ From the repo root with Rust available, you can also run `cargo run -p design-data-cli --manifest-path sdk/Cargo.toml -- validate ./packages/tokens/src --schema-path ./packages/tokens/schemas`.
20
+
11
21
  ## Generate a Diff from the last release
12
22
 
13
23
  The `pnpm generateDiffResult` script will build the project and compare the tokens in the `dist` directory with the last released version of Spectrum Tokens. It will generate a report of added tokens, deleted tokens, tokens with value changes, and tokens with potential name changes. The script can't guarantee the correct name changes; it compares new tokens and deleted tokens to see if any have the same value and are likely to be token name changes.
package/moon.yml CHANGED
@@ -1,4 +1,4 @@
1
- # Copyright 2024 Adobe. All rights reserved.
1
+ # Copyright 2026 Adobe. All rights reserved.
2
2
  # This file is licensed to you under the Apache License, Version 2.0 (the "License");
3
3
  # you may not use this file except in compliance with the License. You may obtain a copy
4
4
  # of the License at http://www.apache.org/licenses/LICENSE-2.0
@@ -15,6 +15,51 @@ fileGroups:
15
15
  tests:
16
16
  - "test/**/*"
17
17
  tasks:
18
+ validateDesignData:
19
+ command: cargo
20
+ args:
21
+ - run
22
+ - --manifest-path
23
+ - ../../sdk/Cargo.toml
24
+ - --bin
25
+ - design-data
26
+ - --
27
+ - validate
28
+ - ./src
29
+ - --schema-path
30
+ - ./schemas
31
+ - --exceptions-path
32
+ - ./naming-exceptions.json
33
+ platform: system
34
+ inputs:
35
+ - "@globs(sources)"
36
+ - "schemas/**/*.json"
37
+ - "snapshots/**/*.json"
38
+ - "naming-exceptions.json"
39
+ verifyDesignDataSnapshot:
40
+ command: cargo
41
+ args:
42
+ - run
43
+ - --manifest-path
44
+ - ../../sdk/Cargo.toml
45
+ - --bin
46
+ - design-data
47
+ - --
48
+ - migrate
49
+ - verify
50
+ - ./src
51
+ - --snapshot
52
+ - ./snapshots/validation-snapshot.json
53
+ - --schema-path
54
+ - ./schemas
55
+ - --exceptions-path
56
+ - ./naming-exceptions.json
57
+ platform: system
58
+ inputs:
59
+ - "@globs(sources)"
60
+ - "schemas/**/*.json"
61
+ - "snapshots/**/*.json"
62
+ - "naming-exceptions.json"
18
63
  build:
19
64
  deps:
20
65
  - ~:buildTokens
@@ -58,6 +103,7 @@ tasks:
58
103
  - "@globs(sources)"
59
104
  deps:
60
105
  - ~:buildTokens
106
+ - ~:verifyDesignDataSnapshot
61
107
  platform: node
62
108
  test-watch:
63
109
  command: