@wordpress/theme 0.3.1-next.6deb34194.0 → 0.4.0

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.
Files changed (41) hide show
  1. package/README.md +82 -18
  2. package/bin/generate-primitive-tokens/index.ts +26 -33
  3. package/bin/terrazzo-plugin-mode-overrides/index.ts +208 -0
  4. package/build/prebuilt/js/design-tokens.js +17 -1
  5. package/build/prebuilt/js/design-tokens.js.map +2 -2
  6. package/build/prebuilt/ts/color-tokens.js +35 -13
  7. package/build/prebuilt/ts/color-tokens.js.map +2 -2
  8. package/build-module/prebuilt/js/design-tokens.js +17 -1
  9. package/build-module/prebuilt/js/design-tokens.js.map +2 -2
  10. package/build-module/prebuilt/ts/color-tokens.js +35 -13
  11. package/build-module/prebuilt/ts/color-tokens.js.map +2 -2
  12. package/build-types/prebuilt/ts/color-tokens.d.ts.map +1 -1
  13. package/docs/ds-tokens.md +18 -2
  14. package/package.json +5 -5
  15. package/src/prebuilt/css/design-tokens.css +18 -2
  16. package/src/prebuilt/js/design-tokens.js +17 -1
  17. package/src/prebuilt/ts/color-tokens.ts +31 -9
  18. package/terrazzo.config.ts +11 -14
  19. package/tokens/border.json +1 -1
  20. package/tokens/color.json +1160 -630
  21. package/tokens/dimension.json +88 -90
  22. package/tokens/elevation.json +1 -1
  23. package/tokens/modes/border.high-dpi.json +15 -0
  24. package/tokens/modes/dimension.comfortable.json +54 -0
  25. package/tokens/modes/dimension.compact.json +54 -0
  26. package/tokens/typography.json +1 -1
  27. package/tsconfig.bin.tsbuildinfo +1 -1
  28. package/tsconfig.src.tsbuildinfo +1 -1
  29. package/bin/terrazzo-plugin-figma-ds-token-manager/index.ts +0 -217
  30. package/bin/terrazzo-plugin-figma-ds-token-manager/lib.ts +0 -1
  31. package/build/prebuilt/json/figma.json +0 -787
  32. package/build/token-id.js +0 -30
  33. package/build/token-id.js.map +0 -7
  34. package/build-module/prebuilt/json/figma.json +0 -787
  35. package/build-module/token-id.js +0 -6
  36. package/build-module/token-id.js.map +0 -7
  37. package/build-types/token-id.d.ts +0 -9
  38. package/build-types/token-id.d.ts.map +0 -1
  39. package/src/prebuilt/json/figma.json +0 -787
  40. package/src/test/token-id.test.ts +0 -12
  41. package/src/token-id.ts +0 -9
package/build/token-id.js DELETED
@@ -1,30 +0,0 @@
1
- var __defProp = Object.defineProperty;
2
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
- var __getOwnPropNames = Object.getOwnPropertyNames;
4
- var __hasOwnProp = Object.prototype.hasOwnProperty;
5
- var __export = (target, all) => {
6
- for (var name in all)
7
- __defProp(target, name, { get: all[name], enumerable: true });
8
- };
9
- var __copyProps = (to, from, except, desc) => {
10
- if (from && typeof from === "object" || typeof from === "function") {
11
- for (let key of __getOwnPropNames(from))
12
- if (!__hasOwnProp.call(to, key) && key !== except)
13
- __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
14
- }
15
- return to;
16
- };
17
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
18
-
19
- // packages/theme/src/token-id.ts
20
- var token_id_exports = {};
21
- __export(token_id_exports, {
22
- publicTokenId: () => publicTokenId
23
- });
24
- module.exports = __toCommonJS(token_id_exports);
25
- var publicTokenId = (id) => id.replace(/\.(normal|resting|semantic|primitive)/g, "");
26
- // Annotate the CommonJS export names for ESM import in node:
27
- 0 && (module.exports = {
28
- publicTokenId
29
- });
30
- //# sourceMappingURL=token-id.js.map
@@ -1,7 +0,0 @@
1
- {
2
- "version": 3,
3
- "sources": ["../src/token-id.ts"],
4
- "sourcesContent": ["/**\n * Normalizes a token ID by removing default states and visibility identifiers,\n * making it human-readable as a publicly-accessible variable name.\n *\n * @param id The token ID to normalize.\n * @return The normalized token ID.\n */\nexport const publicTokenId = ( id: string ) =>\n\tid.replace( /\\.(normal|resting|semantic|primitive)/g, '' );\n"],
5
- "mappings": ";;;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAOO,IAAM,gBAAgB,CAAE,OAC9B,GAAG,QAAS,0CAA0C,EAAG;",
6
- "names": []
7
- }