tokens-bruecke 2.11.1 → 2.11.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/.github/workflows/release.yml +3 -1
- package/.release-please-manifest.json +1 -1
- package/CHANGELOG.md +19 -0
- package/README.md +20 -8
- package/bin/cli.js +1 -1
- package/global.d.ts +1 -0
- package/package.json +4 -2
|
@@ -14,12 +14,14 @@ jobs:
|
|
|
14
14
|
packages: write # to create NPM package under github registry
|
|
15
15
|
|
|
16
16
|
runs-on: ubuntu-latest
|
|
17
|
+
env:
|
|
18
|
+
FORCE_JAVASCRIPT_ACTIONS_TO_NODE24: true
|
|
17
19
|
steps:
|
|
18
20
|
- uses: googleapis/release-please-action@v4
|
|
19
21
|
id: release
|
|
20
22
|
with:
|
|
21
23
|
token: ${{ secrets.GITHUB_TOKEN }}
|
|
22
|
-
|
|
24
|
+
|
|
23
25
|
- name: Checkout
|
|
24
26
|
uses: actions/checkout@v4
|
|
25
27
|
if: ${{ steps.release.outputs.release_created }}
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [2.10.0](https://github.com/tokens-bruecke/figma-plugin/compare/v2.9.4...v2.10.0) (2026-03-28)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* Add export/import docs and styles warning ([6446d2a](https://github.com/tokens-bruecke/figma-plugin/commit/6446d2ab117f6e5b9270588b886e6903505f36fe))
|
|
9
|
+
* **cli:** add --oauth-token flag to support OAuth authentication ([ccbc16e](https://github.com/tokens-bruecke/figma-plugin/commit/ccbc16e931c653d4a1aa345902aada38c71a0af3))
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
### Bug Fixes
|
|
13
|
+
|
|
14
|
+
* import variables ([1d72235](https://github.com/tokens-bruecke/figma-plugin/commit/1d722358b5e714710df3546727fdaba41427c863))
|
|
15
|
+
* **normilizeType:** return 'string' instead of 'dimension' for percentage opacity ([52085c6](https://github.com/tokens-bruecke/figma-plugin/commit/52085c63d50809f9a25a86c6fad9a26fbfd67427))
|
|
16
|
+
|
|
17
|
+
|
|
18
|
+
### Miscellaneous
|
|
19
|
+
|
|
20
|
+
* format CHANGELOG ([0e2e4b0](https://github.com/tokens-bruecke/figma-plugin/commit/0e2e4b0e2fe655451c36bdd7e54f2fffbfeb3a46))
|
|
21
|
+
|
|
3
22
|
## [2.11.1](https://github.com/tokens-bruecke/figma-plugin/compare/v2.11.0...v2.11.1) (2026-03-28)
|
|
4
23
|
|
|
5
24
|
### Bug Fixes
|
package/README.md
CHANGED
|
@@ -29,6 +29,7 @@ The plugin converts Figma variables into design-tokens JSON that are compatible
|
|
|
29
29
|
- [Use DTCG keys format](#use-dtcg-keys-format)
|
|
30
30
|
- [Include `.value` string for aliases](#include-value-string-for-aliases)
|
|
31
31
|
- [Include Figma metadata](#include-figma-metadata)
|
|
32
|
+
- [Split collections into separate files](#split-collections-into-separate-files)
|
|
32
33
|
- [Use as cli tool](#use-as-cli-tool)
|
|
33
34
|
- [Installation](#installation)
|
|
34
35
|
- [Usage](#usage)
|
|
@@ -246,6 +247,15 @@ Is `off` by default. Allows you to include Figma metadata like `styleId`, `varia
|
|
|
246
247
|
}
|
|
247
248
|
```
|
|
248
249
|
|
|
250
|
+
### Split collections into separate files
|
|
251
|
+
|
|
252
|
+
Is `off` by default. When enabled, each Figma variable collection is exported as its own file instead of a single merged JSON.
|
|
253
|
+
|
|
254
|
+
- **Download JSON** — produces a `design.tokens.zip` archive containing one `{CollectionName}.tokens.json` per collection.
|
|
255
|
+
- **CLI** — writes individual `{CollectionName}.tokens.json` files into the directory specified by `--output`.
|
|
256
|
+
|
|
257
|
+
This is useful when you want to keep component-level token files separate (e.g. `button.tokens.json`, `card.tokens.json`).
|
|
258
|
+
|
|
249
259
|
---
|
|
250
260
|
|
|
251
261
|
## Use as cli tool
|
|
@@ -286,13 +296,14 @@ This will fetch figma variables and export them in `out/tokens.json`
|
|
|
286
296
|
|
|
287
297
|
### Options
|
|
288
298
|
|
|
289
|
-
| Option
|
|
290
|
-
|
|
|
291
|
-
| `--api-key`
|
|
292
|
-
| `--oauth-token`
|
|
293
|
-
| `--file-key`
|
|
294
|
-
| `--output`
|
|
295
|
-
| `--config`
|
|
299
|
+
| Option | Alias | Description | Required |
|
|
300
|
+
| ----------------------- | ----- | --------------------------------------------------------------------- | ------------------------------------------------- |
|
|
301
|
+
| `--api-key` | `-a` | Figma personal access token (PAT) | One of `--api-key` or `--oauth-token` is required |
|
|
302
|
+
| `--oauth-token` | `-t` | Figma OAuth token | One of `--api-key` or `--oauth-token` is required |
|
|
303
|
+
| `--file-key` | `-f` | Figma file key | Yes |
|
|
304
|
+
| `--output` | `-o` | Path to output file, or output directory when `--split-by-collection` | Yes |
|
|
305
|
+
| `--config` | `-c` | Path to configuration file | No |
|
|
306
|
+
| `--split-by-collection` | `-s` | Write each collection as a separate `.tokens.json` file in `--output` | No |
|
|
296
307
|
|
|
297
308
|
> [!TIP]
|
|
298
309
|
> For automated pipelines, `--oauth-token` is preferred over `--api-key`. Personal Access Tokens expire every 90 days and require manual renewal, while OAuth tokens support programmatic refresh for indefinite access.
|
|
@@ -317,7 +328,8 @@ You can use a JSON configuration file to specify the export options for the CLI.
|
|
|
317
328
|
"includeFigmaMetaData": false, // Include Figma metadata like styleId, variableId, etc.
|
|
318
329
|
"usePercentageOpacity": false, // Export opacity as percentage (10%) instead of decimal (0.1)
|
|
319
330
|
"colorMode": "hex", // "hex" | "rgba-object" | "rgba-css" | "hsla-object" | "hsla-css";
|
|
320
|
-
"storeStyleInCollection": "none" // Name of one of your collection or "none" to keep them separated
|
|
331
|
+
"storeStyleInCollection": "none", // Name of one of your collection or "none" to keep them separated
|
|
332
|
+
"splitByCollection": false // Write each collection as a separate .tokens.json file
|
|
321
333
|
}
|
|
322
334
|
```
|
|
323
335
|
|