@canonical/design-tokens 0.0.1

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 (36) hide show
  1. package/README.md +42 -0
  2. package/assets.ruleset.json +19 -0
  3. package/package.json +19 -0
  4. package/terrazzo.config.ts +13 -0
  5. package/tokens/canonical/canonical.resolver.json +162 -0
  6. package/tokens/canonical/global/primitive/color.tokens.json +1097 -0
  7. package/tokens/canonical/global/primitive/dimension.tokens.json +571 -0
  8. package/tokens/canonical/global/primitive/number.tokens.json +600 -0
  9. package/tokens/canonical/global/primitive/typography.tokens.json +181 -0
  10. package/tokens/canonical/global/semantic/color/dark.tokens.json +4925 -0
  11. package/tokens/canonical/global/semantic/color/light.tokens.json +4925 -0
  12. package/tokens/canonical/global/semantic/dimension/large.tokens.json +3 -0
  13. package/tokens/canonical/global/semantic/dimension/medium.tokens.json +3 -0
  14. package/tokens/canonical/global/semantic/dimension/small.tokens.json +18 -0
  15. package/tokens/canonical/global/semantic/dimension/xLarge.tokens.json +12 -0
  16. package/tokens/canonical/global/semantic/modifier/anticipation/caution.tokens.json +61 -0
  17. package/tokens/canonical/global/semantic/modifier/anticipation/constructive.tokens.json +74 -0
  18. package/tokens/canonical/global/semantic/modifier/anticipation/destructive.tokens.json +74 -0
  19. package/tokens/canonical/global/semantic/modifier/criticality/error.tokens.json +87 -0
  20. package/tokens/canonical/global/semantic/modifier/criticality/information.tokens.json +61 -0
  21. package/tokens/canonical/global/semantic/modifier/criticality/success.tokens.json +87 -0
  22. package/tokens/canonical/global/semantic/modifier/criticality/warning.tokens.json +87 -0
  23. package/tokens/canonical/global/semantic/modifier/emphasis/branded.tokens.json +87 -0
  24. package/tokens/canonical/global/semantic/modifier/emphasis/highlighted.tokens.json +4 -0
  25. package/tokens/canonical/global/semantic/modifier/emphasis/muted.tokens.json +46 -0
  26. package/tokens/canonical/global/semantic/modifier/importance/primary.tokens.json +4 -0
  27. package/tokens/canonical/global/semantic/modifier/importance/secondary.tokens.json +4 -0
  28. package/tokens/canonical/global/semantic/modifier/importance/tertiary.tokens.json +4 -0
  29. package/tokens/canonical/global/semantic/modifier/surface/layer1.tokens.json +212 -0
  30. package/tokens/canonical/global/semantic/modifier/surface/layer2.tokens.json +212 -0
  31. package/tokens/canonical/global/semantic/modifier/surface/layer3.tokens.json +212 -0
  32. package/tokens/canonical/global/semantic/modifier/typography/apps.tokens.json +778 -0
  33. package/tokens/canonical/global/semantic/modifier/typography/docs.tokens.json +778 -0
  34. package/tokens/canonical/global/semantic/modifier/typography/global.tokens.json +866 -0
  35. package/tokens/canonical/global/semantic/modifier/typography/sites.tokens.json +62 -0
  36. package/tsconfig.json +4 -0
@@ -0,0 +1,62 @@
1
+ {
2
+ "$schema": "https://designtokens.org/schemas/2025.10/format.json",
3
+ "typography": {
4
+ "$type": "typography",
5
+ "heading": {
6
+ "display": {
7
+ "$root": {
8
+ "$value": {
9
+ "fontFamily": "{typography.fontFamily.default}",
10
+ "fontSize": "{dimension.size.fontSize.950}",
11
+ "fontWeight": "{typography.weight.extraLight}",
12
+ "lineHeight": "{number.lineHeight.950}",
13
+ "letterSpacing": "{dimension.letterSpacing.default}"
14
+ },
15
+ "$extensions": {
16
+ "com.canonical.typography": {
17
+ "$value": {
18
+ "letterCase": {
19
+ "$ref": "#/typography/letterCase/default/$extensions/com.canonical.typography/$value"
20
+ },
21
+ "figureStyle": {
22
+ "$ref": "#/typography/figureStyle/oldStyleFigure/$extensions/com.canonical.typography/$value"
23
+ }
24
+ }
25
+ }
26
+ },
27
+ "$description": "Display heading for hero sections and major page titles (84px) (Some properties of this token are not yet supported by the W3C DTCG specification, so they are stored in $extensions and require a token transformer compatible with Canonical design system extensions.)"
28
+ },
29
+ "bold": {
30
+ "$value": {
31
+ "fontFamily": {
32
+ "$ref": "#/typography/heading/display/$root/$value/fontFamily"
33
+ },
34
+ "fontSize": {
35
+ "$ref": "#/typography/heading/display/$root/$value/fontSize"
36
+ },
37
+ "fontWeight": "{typography.weight.regular}",
38
+ "lineHeight": {
39
+ "$ref": "#/typography/heading/display/$root/$value/lineHeight"
40
+ },
41
+ "letterSpacing": {
42
+ "$ref": "#/typography/heading/display/$root/$value/letterSpacing"
43
+ }
44
+ },
45
+ "$extensions": {
46
+ "com.canonical.typography": {
47
+ "$value": {
48
+ "letterCase": {
49
+ "$ref": "#/typography/heading/display/$root/$extensions/com.canonical.typography/$value/letterCase"
50
+ },
51
+ "figureStyle": {
52
+ "$ref": "#/typography/heading/display/$root/$extensions/com.canonical.typography/$value/figureStyle"
53
+ }
54
+ }
55
+ }
56
+ },
57
+ "$description": "Bold variant of display heading for additional emphasis (84px) (Some properties of this token are not yet supported by the W3C DTCG specification, so they are stored in $extensions and require a token transformer compatible with Canonical design system extensions.)"
58
+ }
59
+ }
60
+ }
61
+ }
62
+ }
package/tsconfig.json ADDED
@@ -0,0 +1,4 @@
1
+ {
2
+ "extends": "../../tsconfig.json",
3
+ "include": ["terrazzo.config.ts"]
4
+ }