@marioschmidt/design-system-tokens 1.0.30 โ†’ 1.0.31

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 (181) hide show
  1. package/README.md +443 -67
  2. package/dist/android/brands/advertorial/semantic/effects/effects-dark.xml +1 -1
  3. package/dist/android/brands/advertorial/semantic/effects/effects-light.xml +1 -1
  4. package/dist/android/brands/bild/semantic/effects/effects-dark.xml +1 -1
  5. package/dist/android/brands/bild/semantic/effects/effects-light.xml +1 -1
  6. package/dist/android/brands/sportbild/semantic/effects/effects-dark.xml +1 -1
  7. package/dist/android/brands/sportbild/semantic/effects/effects-light.xml +1 -1
  8. package/dist/android/res/values/brands/bild/semantic/color/colormode-dark.xml +1 -0
  9. package/dist/android/res/values/brands/bild/semantic/color/colormode-light.xml +1 -0
  10. package/dist/android/res/values/brands/sportbild/semantic/color/colormode-dark.xml +1 -0
  11. package/dist/android/res/values/brands/sportbild/semantic/color/colormode-light.xml +1 -0
  12. package/dist/css/brands/advertorial/density/density-compact.css +1 -1
  13. package/dist/css/brands/advertorial/density/density-default.css +1 -1
  14. package/dist/css/brands/advertorial/density/density-spacious.css +1 -1
  15. package/dist/css/brands/advertorial/overrides/brandtokenmapping.css +1 -1
  16. package/dist/css/brands/advertorial/semantic/breakpoints/breakpoint-lg-1024px-regular.css +1 -1
  17. package/dist/css/brands/advertorial/semantic/breakpoints/breakpoint-md-600px.css +1 -1
  18. package/dist/css/brands/advertorial/semantic/breakpoints/breakpoint-sm-390px-compact.css +1 -1
  19. package/dist/css/brands/advertorial/semantic/breakpoints/breakpoint-xs-320px.css +1 -1
  20. package/dist/css/brands/advertorial/semantic/effects/effects-dark.css +1 -1
  21. package/dist/css/brands/advertorial/semantic/effects/effects-light.css +1 -1
  22. package/dist/css/brands/advertorial/semantic/typography/typography-lg.css +1 -1
  23. package/dist/css/brands/advertorial/semantic/typography/typography-md.css +1 -1
  24. package/dist/css/brands/advertorial/semantic/typography/typography-sm.css +1 -1
  25. package/dist/css/brands/advertorial/semantic/typography/typography-xs.css +1 -1
  26. package/dist/css/brands/bild/density/density-compact.css +1 -1
  27. package/dist/css/brands/bild/density/density-default.css +1 -1
  28. package/dist/css/brands/bild/density/density-spacious.css +1 -1
  29. package/dist/css/brands/bild/overrides/brandcolormapping.css +1 -1
  30. package/dist/css/brands/bild/overrides/brandtokenmapping.css +1 -1
  31. package/dist/css/brands/bild/semantic/breakpoints/breakpoint-lg-1024px-regular.css +1 -1
  32. package/dist/css/brands/bild/semantic/breakpoints/breakpoint-md-600px.css +1 -1
  33. package/dist/css/brands/bild/semantic/breakpoints/breakpoint-sm-390px-compact.css +1 -1
  34. package/dist/css/brands/bild/semantic/breakpoints/breakpoint-xs-320px.css +1 -1
  35. package/dist/css/brands/bild/semantic/color/colormode-dark.css +5 -1
  36. package/dist/css/brands/bild/semantic/color/colormode-light.css +5 -1
  37. package/dist/css/brands/bild/semantic/effects/effects-dark.css +1 -1
  38. package/dist/css/brands/bild/semantic/effects/effects-light.css +1 -1
  39. package/dist/css/brands/bild/semantic/typography/typography-lg.css +1 -1
  40. package/dist/css/brands/bild/semantic/typography/typography-md.css +1 -1
  41. package/dist/css/brands/bild/semantic/typography/typography-sm.css +1 -1
  42. package/dist/css/brands/bild/semantic/typography/typography-xs.css +1 -1
  43. package/dist/css/brands/sportbild/density/density-compact.css +1 -1
  44. package/dist/css/brands/sportbild/density/density-default.css +1 -1
  45. package/dist/css/brands/sportbild/density/density-spacious.css +1 -1
  46. package/dist/css/brands/sportbild/overrides/brandcolormapping.css +1 -1
  47. package/dist/css/brands/sportbild/overrides/brandtokenmapping.css +1 -1
  48. package/dist/css/brands/sportbild/semantic/breakpoints/breakpoint-lg-1024px-regular.css +1 -1
  49. package/dist/css/brands/sportbild/semantic/breakpoints/breakpoint-md-600px.css +1 -1
  50. package/dist/css/brands/sportbild/semantic/breakpoints/breakpoint-sm-390px-compact.css +1 -1
  51. package/dist/css/brands/sportbild/semantic/breakpoints/breakpoint-xs-320px.css +1 -1
  52. package/dist/css/brands/sportbild/semantic/color/colormode-dark.css +5 -1
  53. package/dist/css/brands/sportbild/semantic/color/colormode-light.css +5 -1
  54. package/dist/css/brands/sportbild/semantic/effects/effects-dark.css +1 -1
  55. package/dist/css/brands/sportbild/semantic/effects/effects-light.css +1 -1
  56. package/dist/css/brands/sportbild/semantic/typography/typography-lg.css +1 -1
  57. package/dist/css/brands/sportbild/semantic/typography/typography-md.css +1 -1
  58. package/dist/css/brands/sportbild/semantic/typography/typography-sm.css +1 -1
  59. package/dist/css/brands/sportbild/semantic/typography/typography-xs.css +1 -1
  60. package/dist/css/shared/colorprimitive.css +1 -1
  61. package/dist/css/shared/fontprimitive.css +1 -1
  62. package/dist/css/shared/sizeprimitive.css +1 -1
  63. package/dist/css/shared/spaceprimitive.css +1 -1
  64. package/dist/flutter/brands/bild/semantic/color/colormode-dark.dart +2 -0
  65. package/dist/flutter/brands/bild/semantic/color/colormode-light.dart +2 -0
  66. package/dist/flutter/brands/sportbild/semantic/color/colormode-dark.dart +2 -0
  67. package/dist/flutter/brands/sportbild/semantic/color/colormode-light.dart +2 -0
  68. package/dist/ios/brands/bild/semantic/color/ColormodeDark.swift +2 -0
  69. package/dist/ios/brands/bild/semantic/color/ColormodeLight.swift +2 -0
  70. package/dist/ios/brands/sportbild/semantic/color/ColormodeDark.swift +2 -0
  71. package/dist/ios/brands/sportbild/semantic/color/ColormodeLight.swift +2 -0
  72. package/dist/js/brands/advertorial/density/density-compact.js +1 -1
  73. package/dist/js/brands/advertorial/density/density-default.js +1 -1
  74. package/dist/js/brands/advertorial/density/density-spacious.js +1 -1
  75. package/dist/js/brands/advertorial/overrides/brandtokenmapping.js +1 -1
  76. package/dist/js/brands/advertorial/semantic/breakpoints/breakpoint-lg-1024px-regular.js +1 -1
  77. package/dist/js/brands/advertorial/semantic/breakpoints/breakpoint-md-600px.js +1 -1
  78. package/dist/js/brands/advertorial/semantic/breakpoints/breakpoint-sm-390px-compact.js +1 -1
  79. package/dist/js/brands/advertorial/semantic/breakpoints/breakpoint-xs-320px.js +1 -1
  80. package/dist/js/brands/advertorial/semantic/effects/effects-dark.js +1 -1
  81. package/dist/js/brands/advertorial/semantic/effects/effects-light.js +1 -1
  82. package/dist/js/brands/advertorial/semantic/typography/typography-lg.js +1 -1
  83. package/dist/js/brands/advertorial/semantic/typography/typography-md.js +1 -1
  84. package/dist/js/brands/advertorial/semantic/typography/typography-sm.js +1 -1
  85. package/dist/js/brands/advertorial/semantic/typography/typography-xs.js +1 -1
  86. package/dist/js/brands/bild/density/density-compact.js +1 -1
  87. package/dist/js/brands/bild/density/density-default.js +1 -1
  88. package/dist/js/brands/bild/density/density-spacious.js +1 -1
  89. package/dist/js/brands/bild/overrides/brandcolormapping.js +1 -1
  90. package/dist/js/brands/bild/overrides/brandtokenmapping.js +1 -1
  91. package/dist/js/brands/bild/semantic/breakpoints/breakpoint-lg-1024px-regular.js +1 -1
  92. package/dist/js/brands/bild/semantic/breakpoints/breakpoint-md-600px.js +1 -1
  93. package/dist/js/brands/bild/semantic/breakpoints/breakpoint-sm-390px-compact.js +1 -1
  94. package/dist/js/brands/bild/semantic/breakpoints/breakpoint-xs-320px.js +1 -1
  95. package/dist/js/brands/bild/semantic/color/colormode-dark.js +3 -1
  96. package/dist/js/brands/bild/semantic/color/colormode-light.js +3 -1
  97. package/dist/js/brands/bild/semantic/effects/effects-dark.js +1 -1
  98. package/dist/js/brands/bild/semantic/effects/effects-light.js +1 -1
  99. package/dist/js/brands/bild/semantic/typography/typography-lg.js +1 -1
  100. package/dist/js/brands/bild/semantic/typography/typography-md.js +1 -1
  101. package/dist/js/brands/bild/semantic/typography/typography-sm.js +1 -1
  102. package/dist/js/brands/bild/semantic/typography/typography-xs.js +1 -1
  103. package/dist/js/brands/sportbild/density/density-compact.js +1 -1
  104. package/dist/js/brands/sportbild/density/density-default.js +1 -1
  105. package/dist/js/brands/sportbild/density/density-spacious.js +1 -1
  106. package/dist/js/brands/sportbild/overrides/brandcolormapping.js +1 -1
  107. package/dist/js/brands/sportbild/overrides/brandtokenmapping.js +1 -1
  108. package/dist/js/brands/sportbild/semantic/breakpoints/breakpoint-lg-1024px-regular.js +1 -1
  109. package/dist/js/brands/sportbild/semantic/breakpoints/breakpoint-md-600px.js +1 -1
  110. package/dist/js/brands/sportbild/semantic/breakpoints/breakpoint-sm-390px-compact.js +1 -1
  111. package/dist/js/brands/sportbild/semantic/breakpoints/breakpoint-xs-320px.js +1 -1
  112. package/dist/js/brands/sportbild/semantic/color/colormode-dark.js +3 -1
  113. package/dist/js/brands/sportbild/semantic/color/colormode-light.js +3 -1
  114. package/dist/js/brands/sportbild/semantic/effects/effects-dark.js +1 -1
  115. package/dist/js/brands/sportbild/semantic/effects/effects-light.js +1 -1
  116. package/dist/js/brands/sportbild/semantic/typography/typography-lg.js +1 -1
  117. package/dist/js/brands/sportbild/semantic/typography/typography-md.js +1 -1
  118. package/dist/js/brands/sportbild/semantic/typography/typography-sm.js +1 -1
  119. package/dist/js/brands/sportbild/semantic/typography/typography-xs.js +1 -1
  120. package/dist/js/shared/colorprimitive.js +1 -1
  121. package/dist/js/shared/fontprimitive.js +1 -1
  122. package/dist/js/shared/sizeprimitive.js +1 -1
  123. package/dist/js/shared/spaceprimitive.js +1 -1
  124. package/dist/json/brands/bild/semantic/color/colormode-dark.json +37 -0
  125. package/dist/json/brands/bild/semantic/color/colormode-light.json +37 -0
  126. package/dist/json/brands/sportbild/semantic/color/colormode-dark.json +37 -0
  127. package/dist/json/brands/sportbild/semantic/color/colormode-light.json +37 -0
  128. package/dist/manifest.json +1 -1
  129. package/dist/scss/brands/advertorial/density/density-compact.scss +1 -1
  130. package/dist/scss/brands/advertorial/density/density-default.scss +1 -1
  131. package/dist/scss/brands/advertorial/density/density-spacious.scss +1 -1
  132. package/dist/scss/brands/advertorial/overrides/brandtokenmapping.scss +1 -1
  133. package/dist/scss/brands/advertorial/semantic/breakpoints/breakpoint-lg-1024px-regular.scss +1 -1
  134. package/dist/scss/brands/advertorial/semantic/breakpoints/breakpoint-md-600px.scss +1 -1
  135. package/dist/scss/brands/advertorial/semantic/breakpoints/breakpoint-sm-390px-compact.scss +1 -1
  136. package/dist/scss/brands/advertorial/semantic/breakpoints/breakpoint-xs-320px.scss +1 -1
  137. package/dist/scss/brands/advertorial/semantic/effects/effects-dark.scss +1 -1
  138. package/dist/scss/brands/advertorial/semantic/effects/effects-light.scss +1 -1
  139. package/dist/scss/brands/advertorial/semantic/typography/typography-lg.scss +1 -1
  140. package/dist/scss/brands/advertorial/semantic/typography/typography-md.scss +1 -1
  141. package/dist/scss/brands/advertorial/semantic/typography/typography-sm.scss +1 -1
  142. package/dist/scss/brands/advertorial/semantic/typography/typography-xs.scss +1 -1
  143. package/dist/scss/brands/bild/density/density-compact.scss +1 -1
  144. package/dist/scss/brands/bild/density/density-default.scss +1 -1
  145. package/dist/scss/brands/bild/density/density-spacious.scss +1 -1
  146. package/dist/scss/brands/bild/overrides/brandcolormapping.scss +1 -1
  147. package/dist/scss/brands/bild/overrides/brandtokenmapping.scss +1 -1
  148. package/dist/scss/brands/bild/semantic/breakpoints/breakpoint-lg-1024px-regular.scss +1 -1
  149. package/dist/scss/brands/bild/semantic/breakpoints/breakpoint-md-600px.scss +1 -1
  150. package/dist/scss/brands/bild/semantic/breakpoints/breakpoint-sm-390px-compact.scss +1 -1
  151. package/dist/scss/brands/bild/semantic/breakpoints/breakpoint-xs-320px.scss +1 -1
  152. package/dist/scss/brands/bild/semantic/color/colormode-dark.scss +3 -1
  153. package/dist/scss/brands/bild/semantic/color/colormode-light.scss +3 -1
  154. package/dist/scss/brands/bild/semantic/effects/effects-dark.scss +1 -1
  155. package/dist/scss/brands/bild/semantic/effects/effects-light.scss +1 -1
  156. package/dist/scss/brands/bild/semantic/typography/typography-lg.scss +1 -1
  157. package/dist/scss/brands/bild/semantic/typography/typography-md.scss +1 -1
  158. package/dist/scss/brands/bild/semantic/typography/typography-sm.scss +1 -1
  159. package/dist/scss/brands/bild/semantic/typography/typography-xs.scss +1 -1
  160. package/dist/scss/brands/sportbild/density/density-compact.scss +1 -1
  161. package/dist/scss/brands/sportbild/density/density-default.scss +1 -1
  162. package/dist/scss/brands/sportbild/density/density-spacious.scss +1 -1
  163. package/dist/scss/brands/sportbild/overrides/brandcolormapping.scss +1 -1
  164. package/dist/scss/brands/sportbild/overrides/brandtokenmapping.scss +1 -1
  165. package/dist/scss/brands/sportbild/semantic/breakpoints/breakpoint-lg-1024px-regular.scss +1 -1
  166. package/dist/scss/brands/sportbild/semantic/breakpoints/breakpoint-md-600px.scss +1 -1
  167. package/dist/scss/brands/sportbild/semantic/breakpoints/breakpoint-sm-390px-compact.scss +1 -1
  168. package/dist/scss/brands/sportbild/semantic/breakpoints/breakpoint-xs-320px.scss +1 -1
  169. package/dist/scss/brands/sportbild/semantic/color/colormode-dark.scss +3 -1
  170. package/dist/scss/brands/sportbild/semantic/color/colormode-light.scss +3 -1
  171. package/dist/scss/brands/sportbild/semantic/effects/effects-dark.scss +1 -1
  172. package/dist/scss/brands/sportbild/semantic/effects/effects-light.scss +1 -1
  173. package/dist/scss/brands/sportbild/semantic/typography/typography-lg.scss +1 -1
  174. package/dist/scss/brands/sportbild/semantic/typography/typography-md.scss +1 -1
  175. package/dist/scss/brands/sportbild/semantic/typography/typography-sm.scss +1 -1
  176. package/dist/scss/brands/sportbild/semantic/typography/typography-xs.scss +1 -1
  177. package/dist/scss/shared/colorprimitive.scss +1 -1
  178. package/dist/scss/shared/fontprimitive.scss +1 -1
  179. package/dist/scss/shared/sizeprimitive.scss +1 -1
  180. package/dist/scss/shared/spaceprimitive.scss +1 -1
  181. package/package.json +1 -1
package/README.md CHANGED
@@ -26,23 +26,39 @@ This token pipeline processes the multi-layer, multi-brand architecture of the B
26
26
  - **Composite Tokens**: Typography, Effects
27
27
 
28
28
  ```
29
- Custom Figma Plugin Export (JSON)
30
- โ†“
31
- Preprocessing (scripts/preprocess-plugin-tokens.js)
32
- โ€ข Complete alias resolution (no {Alias.Path} syntax)
33
- โ€ข Context-aware resolution: Brand ร— Breakpoint ร— ColorMode
34
- โ€ข Mode name matching (robust against ID changes)
35
- โ€ข FontWeight bug fixes ("700px" โ†’ 700)
36
- โ†“
37
- Style Dictionary v4 (scripts/build-tokens-v2.js)
38
- โ€ข Multi-platform output (7 formats)
39
- โ€ข Brand-specific builds
40
- โ€ข Composite token support (Typography, Effects)
41
- โ†“
42
- Output Files (dist/)
43
- โ€ข css/, scss/, js/, json/, ios/, android/, flutter/
44
- โ€ข shared/ (primitives) + brands/{brand}/ (brand-specific)
45
- โ€ข 52/52 successful builds
29
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
30
+ โ”‚ Figma Plugin Export (src/design-tokens/) โ”‚
31
+ โ”‚ โ€ข bild-design-system-raw-data.json โ”‚
32
+ โ”‚ โ€ข Contains aliases and Figma structure โ”‚
33
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
34
+ โ†“
35
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
36
+ โ”‚ Preprocessing (scripts/preprocess-*.js) โ”‚
37
+ โ”‚ โ€ข Complete alias resolution โ”‚
38
+ โ”‚ โ€ข Context-aware: Brand ร— Breakpoint ร— Mode โ”‚
39
+ โ”‚ โ€ข FontWeight bug fixes ("700px" โ†’ 700) โ”‚
40
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
41
+ โ†“
42
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
43
+ โ”‚ Intermediate Format (tokens/) โ”‚
44
+ โ”‚ โ€ข 68 JSON files (Style Dictionary format) โ”‚
45
+ โ”‚ โ€ข Tracked in Git (preprocessed source) โ”‚
46
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
47
+ โ†“
48
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
49
+ โ”‚ Style Dictionary v4 (scripts/build-*.js) โ”‚
50
+ โ”‚ โ€ข Multi-platform output (7 formats) โ”‚
51
+ โ”‚ โ€ข Brand-specific builds (3 brands) โ”‚
52
+ โ”‚ โ€ข Composite tokens (Typography, Effects) โ”‚
53
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
54
+ โ†“
55
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
56
+ โ”‚ Build Artifacts (dist/) โ”‚
57
+ โ”‚ โ€ข NOT tracked in Git โ”‚
58
+ โ”‚ โ€ข Generated locally or in CI โ”‚
59
+ โ”‚ โ€ข Available as GitHub Actions artifacts โ”‚
60
+ โ”‚ โ€ข 52/52 successful builds (353 files) โ”‚
61
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
46
62
  ```
47
63
 
48
64
  ---
@@ -408,7 +424,7 @@ final headline1 = Typography.headline1; // TypographyToken
408
424
  .
409
425
  โ”œโ”€โ”€ src/
410
426
  โ”‚ โ””โ”€โ”€ design-tokens/
411
- โ”‚ โ””โ”€โ”€ bild-design-system-raw-data.json # Custom Figma Plugin export
427
+ โ”‚ โ””โ”€โ”€ bild-design-system-raw-data.json # Custom Figma Plugin export (raw data)
412
428
  โ”‚
413
429
  โ”œโ”€โ”€ scripts/
414
430
  โ”‚ โ”œโ”€โ”€ preprocess-plugin-tokens.js # Preprocessing (965 lines)
@@ -431,21 +447,100 @@ final headline1 = Typography.headline1; // TypographyToken
431
447
  โ”‚ โ€ข iOS Swift typography format
432
448
  โ”‚ โ€ข Android typography XML format
433
449
  โ”‚
434
- โ”œโ”€โ”€ tokens/ # Generated (gitignored)
450
+ โ”œโ”€โ”€ tokens/ # Intermediate files (tracked in Git)
435
451
  โ”‚ โ”œโ”€โ”€ shared/ # Primitives (4 files)
436
- โ”‚ โ””โ”€โ”€ brands/ # Brand-specific (3 brands)
452
+ โ”‚ โ””โ”€โ”€ brands/ # Brand-specific (64 files)
437
453
  โ”‚ โ”œโ”€โ”€ bild/
438
454
  โ”‚ โ”œโ”€โ”€ sportbild/
439
455
  โ”‚ โ””โ”€โ”€ advertorial/
456
+ โ”‚ ๐Ÿ“ Purpose: Preprocessed Style Dictionary format
457
+ โ”‚ โœ… Aliases resolved, bugs fixed, ready for SD build
440
458
  โ”‚
441
- โ”œโ”€โ”€ dist/ # Generated (gitignored)
459
+ โ”œโ”€โ”€ dist/ # Build artifacts (NOT in Git)
442
460
  โ”‚ โ”œโ”€โ”€ css/, scss/, js/, json/ # Web platforms
443
461
  โ”‚ โ”œโ”€โ”€ ios/, android/, flutter/ # Native platforms
444
462
  โ”‚ โ””โ”€โ”€ manifest.json # Build metadata
463
+ โ”‚ ๐Ÿ“ Generated locally or in CI/CD
464
+ โ”‚ โฌ‡๏ธ Available as GitHub Actions artifacts (30 days)
445
465
  โ”‚
446
466
  โ””โ”€โ”€ README.md
447
467
  ```
448
468
 
469
+ ### Token Processing Pipeline
470
+
471
+ The token transformation happens in three stages:
472
+
473
+ ```
474
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
475
+ โ”‚ 1๏ธโƒฃ Figma Export (Raw Data) โ”‚
476
+ โ”‚ src/design-tokens/bild-design-system-raw-data.json โ”‚
477
+ โ”‚ โ€ข Figma Variable Visualizer plugin export โ”‚
478
+ โ”‚ โ€ข Contains aliases: {type: "VARIABLE_ALIAS", id: "..."} โ”‚
479
+ โ”‚ โ€ข FontWeight bugs: "700px" instead of 700 โ”‚
480
+ โ”‚ โ€ข Complex Collections & Modes structure โ”‚
481
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
482
+ โ†“
483
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
484
+ โ”‚ 2๏ธโƒฃ Preprocessing (Intermediate Format) โ”‚
485
+ โ”‚ tokens/ โ”‚
486
+ โ”‚ โ€ข All aliases resolved to final values โ”‚
487
+ โ”‚ โ€ข FontWeight bugs fixed โ”‚
488
+ โ”‚ โ€ข Organized by Brand ร— Mode ร— Collection โ”‚
489
+ โ”‚ โ€ข Style Dictionary format: {"$value": "...", "$type": "..."} โ”‚
490
+ โ”‚ โ€ข 68 JSON files (4 shared + 64 brand-specific) โ”‚
491
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
492
+ โ†“
493
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
494
+ โ”‚ 3๏ธโƒฃ Style Dictionary Build (Platform Outputs) โ”‚
495
+ โ”‚ dist/ โ”‚
496
+ โ”‚ โ€ข 7 platforms: CSS, SCSS, JS, JSON, iOS, Android, Flutter โ”‚
497
+ โ”‚ โ€ข 52 total builds (4 shared + 30 brand + 12 typo + 6 fx) โ”‚
498
+ โ”‚ โ€ข Ready-to-use platform-specific formats โ”‚
499
+ โ”‚ โ€ข NOT tracked in Git (available as CI artifacts) โ”‚
500
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
501
+ ```
502
+
503
+ ### Why the `tokens/` Intermediate Step?
504
+
505
+ **Problem:** Figma export format is not directly usable by Style Dictionary:
506
+ - โŒ Aliases like `{type: "VARIABLE_ALIAS", id: "VariableID:123"}`
507
+ - โŒ Complex Collections & Modes structure
508
+ - โŒ Bugs like `"700px"` for FontWeight
509
+
510
+ **Solution:** Preprocessing creates clean Style Dictionary input:
511
+ - โœ… All aliases resolved: `{"$value": "#DD0000", "$type": "color"}`
512
+ - โœ… Bugs fixed: `700` (not `"700px"`)
513
+ - โœ… Organized structure ready for multi-platform build
514
+
515
+ **Example:**
516
+
517
+ ```javascript
518
+ // BEFORE (Figma raw data - src/design-tokens/)
519
+ {
520
+ "variables": [{
521
+ "name": "Component/Background",
522
+ "valuesByMode": {
523
+ "mode123": { "type": "VARIABLE_ALIAS", "id": "VariableID:456" }
524
+ }
525
+ }]
526
+ }
527
+
528
+ // AFTER (Preprocessed - tokens/)
529
+ {
530
+ "Component": {
531
+ "Background": {
532
+ "$value": "#DD0000",
533
+ "$type": "color"
534
+ }
535
+ }
536
+ }
537
+
538
+ // FINAL (Build output - dist/)
539
+ // CSS: --component-background: #DD0000;
540
+ // SCSS: $component-background: #DD0000;
541
+ // JS: export const ComponentBackground = "#DD0000";
542
+ ```
543
+
449
544
  ### Custom Figma Plugin Export
450
545
 
451
546
  The pipeline expects a JSON export from a custom Figma plugin with the following structure:
@@ -481,30 +576,33 @@ The pipeline expects a JSON export from a custom Figma plugin with the following
481
576
 
482
577
  ### Development Workflow
483
578
 
579
+ #### Local Development
580
+
484
581
  1. **Export from Figma**
485
- - Use custom Figma plugin
582
+ - Use custom Figma plugin (Variable Visualizer)
583
+ - Configure target branch: `figma-tokens` (recommended)
486
584
  - Export as `bild-design-system-raw-data.json`
487
585
 
488
- 2. **Place JSON**
489
- - Save to `src/design-tokens/`
586
+ 2. **Figma Plugin Push**
587
+ - Plugin automatically pushes to configured branch
588
+ - โœ… **Recommended**: Push to `figma-tokens` branch
589
+ - Creates automatic Pull Request with build artifacts
490
590
 
491
- 3. **Preprocess**
591
+ 3. **Local Build (Optional)**
492
592
  ```bash
493
- npm run preprocess
494
- ```
495
- - Resolves all aliases to final values
496
- - Creates intermediate token files in `tokens/`
497
- - Output: 68 JSON files (4 shared + 64 brand-specific)
593
+ # Full build (preprocessing + build)
594
+ npm run build
498
595
 
499
- 4. **Build**
500
- ```bash
501
- npm run build:tokens
596
+ # Or run steps separately:
597
+ npm run preprocess # Step 1: Resolve aliases, fix bugs
598
+ npm run build:tokens # Step 2: Generate platform outputs
502
599
  ```
503
- - Transforms to all 7 platforms
600
+ - Resolves all aliases to final values
601
+ - Creates intermediate files in `tokens/` (68 files)
602
+ - Transforms to all 7 platforms in `dist/` (353 files)
504
603
  - **52/52 builds successful**
505
- - โš ๏ธ Warnings about token collisions (LetterSpacing) are expected but non-critical
506
604
 
507
- 5. **Verify**
605
+ 4. **Verify Locally**
508
606
  ```bash
509
607
  # Check brand-specific values
510
608
  grep "bild-red" dist/css/brands/bild/semantic/color/colormode-light.css
@@ -519,56 +617,225 @@ The pipeline expects a JSON export from a custom Figma plugin with the following
519
617
  # Expected: css/, scss/, js/, json/, ios/, android/, flutter/, manifest.json
520
618
  ```
521
619
 
620
+ #### Figma Export Target Branches
621
+
622
+ | Target Branch | Build Runs | PR Created | NPM Publish | Use Case |
623
+ |---------------|------------|------------|-------------|----------|
624
+ | **figma-tokens** | โœ… Yes | โœ… Automatic | โœ… After merge | **Recommended** - Full workflow with review |
625
+ | **main** | โœ… Yes | โŒ No | โœ… **Immediate** | โš ๏ธ Direct publish without review |
626
+ | **claude/*** | โœ… Yes | โŒ Manual | โŒ No | Development/Testing |
627
+ | **other** | โŒ No | โŒ No | โŒ No | Not configured |
628
+
629
+ **Best Practice:** Always export to `figma-tokens` branch for automatic PR creation and review before publishing.
630
+
522
631
  ---
523
632
 
524
633
  ## ๐Ÿ”„ CI/CD Integration
525
634
 
635
+ ### Overview
636
+
637
+ The CI/CD pipeline uses **GitHub Actions Artifacts** for distributing build outputs. The `dist/` folder is **NOT tracked in Git** - instead, it's generated in CI and made available for download.
638
+
639
+ **Key Benefits:**
640
+ - โœ… No merge conflicts on generated files
641
+ - โœ… Clean Git history (only source files)
642
+ - โœ… PR review via downloadable artifacts
643
+ - โœ… 30-day artifact retention
644
+
645
+ ---
646
+
526
647
  ### GitHub Actions Workflows
527
648
 
528
- #### 1. Build Tokens (`.github/workflows/build-tokens.yml`)
649
+ #### 1. ๐Ÿ”จ Build Tokens (`.github/workflows/build-tokens.yml`)
650
+
651
+ **Purpose:** Validates token builds and creates downloadable artifacts for PR review.
529
652
 
530
653
  **Triggers:**
531
654
  - Push to `main`, `develop`, `claude/**`, `figma-tokens` branches
655
+ - Pull requests to `main` branch
532
656
  - Changes in `src/design-tokens/`, `scripts/`, `build-config/`
533
657
  - Manual workflow dispatch
534
658
 
535
- **Steps:**
659
+ **Workflow Steps:**
660
+ ```
536
661
  1. Checkout repository
537
- 2. Setup Node.js 20
538
- 3. Install dependencies
539
- 4. Run `npm run build`
540
- 5. Commit dist/ folder to feature branches
541
- 6. Upload build artifacts (30 days retention)
662
+ โ†“
663
+ 2. Setup Node.js 20 + Install dependencies
664
+ โ†“
665
+ 3. Run npm run build (preprocessing + build)
666
+ โ†“
667
+ 4. Upload artifacts (dist/, tokens/, logs)
668
+ โ†“
669
+ 5. Comment on PR with download link (if PR)
670
+ โ†“
671
+ 6. Create build summary
672
+ ```
542
673
 
543
674
  **Outputs:**
544
- - Validates build success: 52/52 builds
545
- - Commits dist/ to branch (for PR workflows)
546
- - Creates artifacts: `design-tokens-{sha}.zip`
675
+ - โœ… Validates build success: 52/52 builds
676
+ - ๐Ÿ“ฆ Creates artifact: `design-tokens-{sha}.zip` (30 days)
677
+ - ๐Ÿ’ฌ PR comment with download link (on pull requests)
678
+ - ๐Ÿ“Š Build summary in Actions UI
679
+
680
+ **Artifact Contents:**
681
+ ```
682
+ design-tokens-{sha}.zip
683
+ โ”œโ”€โ”€ dist/ # All platform outputs (353 files)
684
+ โ”‚ โ”œโ”€โ”€ css/, scss/, js/, json/
685
+ โ”‚ โ”œโ”€โ”€ ios/, android/, flutter/
686
+ โ”‚ โ””โ”€โ”€ manifest.json
687
+ โ”œโ”€โ”€ tokens/ # Intermediate files (68 files)
688
+ โ””โ”€โ”€ build-output.log # Build logs
689
+ ```
690
+
691
+ **PR Comment Example:**
692
+ ```markdown
693
+ ## ๐ŸŽจ Design Tokens Build erfolgreich!
547
694
 
548
- #### 2. Auto PR from Figma (`.github/workflows/auto-pr-from-figma.yml`)
695
+ **Build Statistiken:**
696
+ - โœ… Successful Builds: 52/52
697
+ - ๐Ÿ“ฆ Commit: `abc123`
698
+ - ๐ŸŒฒ Branch: `feature-branch`
699
+
700
+ ### ๐Ÿ“ฅ Review der generierten Files:
701
+
702
+ [โฌ‡๏ธ **Download Build Artifacts**](https://github.com/.../actions/runs/123456)
703
+
704
+ **Enthalten:**
705
+ - `dist/css/` - CSS Custom Properties
706
+ - `dist/scss/` - SCSS Variables
707
+ - `dist/js/` - JavaScript ES6
708
+ - `dist/json/` - JSON Data
709
+ - `dist/ios/` - Swift Classes
710
+ - `dist/android/` - Android XML
711
+ - `dist/flutter/` - Flutter Dart
712
+
713
+ ๐Ÿ“Š Datei-Statistiken
714
+ - Total Files: 353
715
+ - CSS Files: 88
716
+ - SCSS Files: 88
717
+ ...
718
+
719
+ ๐Ÿ’ก **Tipp:** Die Artifacts sind 30 Tage verfรผgbar.
720
+ ```
721
+
722
+ ---
723
+
724
+ #### 2. ๐Ÿค– Auto PR from Figma (`.github/workflows/auto-pr-from-figma.yml`)
725
+
726
+ **Purpose:** Automatically creates/updates a Pull Request when Figma exports tokens.
549
727
 
550
728
  **Trigger:**
551
729
  - Push to `figma-tokens` branch (from Figma plugin)
552
730
 
553
- **Workflow:**
731
+ **Recommended Figma Plugin Configuration:**
732
+ ```javascript
733
+ {
734
+ "targetBranch": "figma-tokens",
735
+ "repository": "UXWizard25/vv-token-test-v3",
736
+ "filePath": "src/design-tokens/bild-design-system-raw-data.json"
737
+ }
738
+ ```
739
+
740
+ **Complete Workflow:**
554
741
  ```
555
- Figma Plugin Push โ†’ figma-tokens branch
556
- โ†“
557
- Build Tokens (52/52)
558
- โ†“
559
- Commit dist/ to branch
560
- โ†“
561
- Create/Update Pull Request
562
- โ†“
563
- Merge to main
564
- โ†“
565
- Publish to NPM (automatic)
742
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
743
+ โ”‚ 1. Figma Plugin Export โ”‚
744
+ โ”‚ โ€ข Designer clicks "Export" in Figma โ”‚
745
+ โ”‚ โ€ข Plugin pushes JSON to figma-tokens branch โ”‚
746
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
747
+ โ†“
748
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
749
+ โ”‚ 2. Workflow Triggers โ”‚
750
+ โ”‚ โ€ข auto-pr-from-figma.yml starts โ”‚
751
+ โ”‚ โ€ข Runs npm run build (52/52 builds) โ”‚
752
+ โ”‚ โ€ข Uploads artifacts (design-tokens-{sha}.zip) โ”‚
753
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
754
+ โ†“
755
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
756
+ โ”‚ 3. Pull Request Created โ”‚
757
+ โ”‚ โ€ข Title: "๐ŸŽจ Update design tokens from Figma" โ”‚
758
+ โ”‚ โ€ข Body: Build stats + artifact download link โ”‚
759
+ โ”‚ โ€ข Compares figma-tokens โ†’ main โ”‚
760
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
761
+ โ†“
762
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
763
+ โ”‚ 4. Review Process โ”‚
764
+ โ”‚ โ€ข Team reviews source changes (JSON diff) โ”‚
765
+ โ”‚ โ€ข Downloads artifacts to verify outputs โ”‚
766
+ โ”‚ โ€ข Checks CSS, SCSS, platform-specific files โ”‚
767
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
768
+ โ†“
769
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
770
+ โ”‚ 5. Merge to main โ”‚
771
+ โ”‚ โ€ข PR approved and merged โ”‚
772
+ โ”‚ โ€ข publish-on-merge.yml triggers โ”‚
773
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
774
+ โ†“
775
+ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”
776
+ โ”‚ 6. NPM Package Published โ”‚
777
+ โ”‚ โ€ข Fresh dist/ build โ”‚
778
+ โ”‚ โ€ข Version bump (patch) โ”‚
779
+ โ”‚ โ€ข Published to npm registry โ”‚
780
+ โ”‚ โ€ข GitHub Release created โ”‚
781
+ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜
782
+ ```
783
+
784
+ **PR Body Format:**
785
+ ```markdown
786
+ ## ๐ŸŽจ Design Token Update
787
+
788
+ This PR contains updated design tokens from Figma Variable Visualizer.
789
+
790
+ ### โœ… Build Results
791
+ - **Build Status:** Success
792
+ - **Successful Builds:** 52/52
793
+ - **Warnings:** 0
794
+
795
+ ### ๐Ÿ“ฅ Review Generated Files
796
+ [โฌ‡๏ธ **Download Build Artifacts**](https://github.com/.../actions/runs/123)
797
+
798
+ The generated `dist/` files are available as build artifacts (30 days retention).
799
+
800
+ ### ๐Ÿ“ Changed Files
801
+ **Files Changed:** 1
802
+ - src/design-tokens/bild-design-system-raw-data.json
803
+
804
+ ### ๐Ÿš€ What Happens After Merge?
805
+ 1. โœ… Tokens will be rebuilt
806
+ 2. โœ… Package version will be bumped (patch)
807
+ 3. โœ… Package will be published to npm
808
+ 4. โœ… GitHub Release will be created
566
809
  ```
567
810
 
568
- **PR Format:**
569
- - Title: "chore: update design tokens from Figma"
570
- - Body: Build statistics, changed files, diff summary
571
- - Auto-assigns reviewers
811
+ ---
812
+
813
+ #### 3. ๐Ÿ“ฆ Publish on Merge (`.github/workflows/publish-on-merge.yml`)
814
+
815
+ **Purpose:** Automatically publishes package to npm when PR is merged to main.
816
+
817
+ **Trigger:**
818
+ - Push to `main` branch
819
+ - Changes in `src/design-tokens/`, `scripts/`, `build-config/`, `package.json`
820
+
821
+ **Steps:**
822
+ 1. Rebuild tokens (fresh dist/)
823
+ 2. Bump version (patch)
824
+ 3. Publish to npm
825
+ 4. Create GitHub Release
826
+ 5. Tag with version
827
+
828
+ ---
829
+
830
+ ### Workflow Comparison
831
+
832
+ | Workflow | Trigger | Builds dist/ | Commits dist/ | Creates PR | Publishes NPM |
833
+ |----------|---------|--------------|---------------|------------|---------------|
834
+ | **build-tokens.yml** | Push/PR to tracked branches | โœ… Yes | โŒ No (artifacts only) | โŒ No | โŒ No |
835
+ | **auto-pr-from-figma.yml** | Push to `figma-tokens` | โœ… Yes | โŒ No (artifacts only) | โœ… Yes | โŒ No |
836
+ | **publish-on-merge.yml** | Merge to `main` | โœ… Yes (fresh) | โŒ No | โŒ No | โœ… Yes |
837
+
838
+ ---
572
839
 
573
840
  ### Manual Workflow Dispatch
574
841
 
@@ -576,14 +843,69 @@ Publish to NPM (automatic)
576
843
  1. Go to **Actions** tab
577
844
  2. Select **"Build Design Tokens"**
578
845
  3. Click **"Run workflow"**
846
+ 4. Download artifacts from run details
579
847
 
580
848
  **Via GitHub CLI:**
581
849
  ```bash
850
+ # Trigger build
582
851
  gh workflow run build-tokens.yml
852
+
853
+ # List recent runs
854
+ gh run list --workflow=build-tokens.yml
855
+
856
+ # Download artifacts from specific run
857
+ gh run download <run-id>
858
+ ```
859
+
860
+ ---
861
+
862
+ ### Reviewing Build Artifacts
863
+
864
+ **Method 1: Via PR Comment Link**
865
+ 1. Open Pull Request
866
+ 2. Find bot comment "๐ŸŽจ Design Tokens Build erfolgreich!"
867
+ 3. Click "Download Build Artifacts"
868
+ 4. Extract ZIP and review files locally
869
+
870
+ **Method 2: Via Actions Tab**
871
+ 1. Go to repository Actions tab
872
+ 2. Click on workflow run
873
+ 3. Scroll to "Artifacts" section
874
+ 4. Download `design-tokens-{sha}.zip`
875
+
876
+ **Method 3: Via GitHub CLI**
877
+ ```bash
878
+ # List artifacts for a run
879
+ gh run view <run-id>
880
+
881
+ # Download all artifacts
882
+ gh run download <run-id>
883
+
884
+ # Extract and review
885
+ unzip design-tokens-*.zip
886
+ ls dist/
583
887
  ```
584
888
 
585
889
  ---
586
890
 
891
+ ### Branch Protection & Artifact Workflow
892
+
893
+ **Why dist/ is not in Git:**
894
+ - Generated files cause merge conflicts (353 files ร— multiple developers)
895
+ - Unnecessary repository bloat (~15 MB per commit)
896
+ - Source of truth is `src/design-tokens/` (single JSON file)
897
+ - Style Dictionary can regenerate dist/ deterministically
898
+
899
+ **How to review changes without dist/ in Git:**
900
+ 1. Source changes visible in PR diff (JSON file)
901
+ 2. Build artifacts downloadable from Actions (30 days)
902
+ 3. Local testing: `npm run build` generates dist/
903
+ 4. CI validates all builds pass (52/52)
904
+
905
+ This approach follows modern best practices used by design systems like Shopify Polaris, GitHub Primer, and Adobe Spectrum.
906
+
907
+ ---
908
+
587
909
  ## ๐Ÿงช Testing & Verification
588
910
 
589
911
  ### Build Verification
@@ -719,14 +1041,31 @@ npm install
719
1041
 
720
1042
  ### Missing dist/ Folder
721
1043
 
722
- **Problem:** dist/ folder not visible after build
1044
+ **Problem:** dist/ folder not visible in repository or after clone
723
1045
 
724
- **Solution:** dist/ is gitignored. It's generated locally or in CI/CD:
1046
+ **Explanation:** The `dist/` folder is **intentionally not tracked in Git** (as of v2.1.0). This prevents merge conflicts and keeps the repository clean.
1047
+
1048
+ **Solutions:**
1049
+
1050
+ **Option 1: Generate Locally**
725
1051
  ```bash
726
1052
  npm run build
727
1053
  ls dist/ # Should show css/, scss/, js/, json/, ios/, android/, flutter/
728
1054
  ```
729
1055
 
1056
+ **Option 2: Download from CI Artifacts**
1057
+ 1. Go to repository **Actions** tab
1058
+ 2. Find the latest workflow run for your branch
1059
+ 3. Download `design-tokens-{sha}.zip` from Artifacts section
1060
+ 4. Extract the `dist/` folder
1061
+
1062
+ **Option 3: From Pull Request**
1063
+ 1. Find the PR you're interested in
1064
+ 2. Look for bot comment with artifact download link
1065
+ 3. Download and extract
1066
+
1067
+ **Note:** The `dist/` folder is automatically included in npm packages. If you install via npm, the dist/ folder will be in `node_modules/@marioschmidt/design-system-tokens/dist/`.
1068
+
730
1069
  ### Wrong Platform Outputs
731
1070
 
732
1071
  **Problem:** Some platforms missing files
@@ -780,7 +1119,45 @@ All platforms should build successfully: 52/52
780
1119
 
781
1120
  ## ๐Ÿ“ Changelog
782
1121
 
783
- ### v2.0.0 (Current) - Custom Plugin Migration
1122
+ ### v2.1.0 (Current) - CI Artifacts Workflow
1123
+
1124
+ **โœจ Features:**
1125
+ - **Modern CI/CD**: dist/ no longer tracked in Git (prevents merge conflicts)
1126
+ - **GitHub Actions Artifacts**: Build outputs available as downloadable artifacts (30 days)
1127
+ - **PR Bot Comments**: Automatic comments on PRs with artifact download links
1128
+ - **Build Statistics**: Detailed file counts and build summaries in PR comments
1129
+ - **Figma Branch Workflow**: Documented recommended workflow with `figma-tokens` branch
1130
+
1131
+ **๐Ÿ”ง Changes:**
1132
+ - `dist/` folder now gitignored (removed 353 files from tracking)
1133
+ - `tokens/` folder now tracked in Git (preprocessed intermediate files)
1134
+ - Updated workflows: `build-tokens.yml`, `auto-pr-from-figma.yml`
1135
+ - Removed dist/ commit steps from CI workflows
1136
+ - Added artifact upload and PR comment features
1137
+
1138
+ **๐Ÿ“š Documentation:**
1139
+ - Complete CI/CD Integration section rewrite
1140
+ - Added "Token Processing Pipeline" visualization
1141
+ - Added "Why the tokens/ Intermediate Step?" explanation
1142
+ - Added "Figma Export Target Branches" comparison table
1143
+ - Added "Reviewing Build Artifacts" guide
1144
+ - Translated all German comments in build scripts to English
1145
+
1146
+ **๐ŸŽฏ Benefits:**
1147
+ - โœ… No more merge conflicts on generated files
1148
+ - โœ… Cleaner Git history (only source files tracked)
1149
+ - โœ… PR review still possible via downloadable artifacts
1150
+ - โœ… Follows modern best practices (Shopify Polaris, GitHub Primer, Adobe Spectrum)
1151
+ - โœ… Smaller repository size (~15 MB removed per commit)
1152
+
1153
+ **โšก Performance:**
1154
+ - Same build performance: 52/52 builds successful
1155
+ - ~11 seconds total build time
1156
+ - Artifacts upload in ~2-3 seconds
1157
+
1158
+ ---
1159
+
1160
+ ### v2.0.0 - Custom Plugin Migration
784
1161
 
785
1162
  **โœจ Features:**
786
1163
  - Custom Figma Plugin integration (replaces Variable Visualizer)
@@ -797,7 +1174,6 @@ All platforms should build successfully: 52/52
797
1174
  - Mode name matching instead of ID-based (robust against Figma changes)
798
1175
  - YAML syntax fix in GitHub Actions (multi-line commit messages)
799
1176
  - Exit code 0 for successful builds
800
- - dist/ folder commits to feature branches
801
1177
 
802
1178
  **โšก Performance:**
803
1179
  - 52/52 builds successful (up from 30/30)
@@ -1,7 +1,7 @@
1
1
  <?xml version="1.0" encoding="utf-8"?>
2
2
  <!--
3
3
  Effect Tokens - Advertorial / dark
4
- Generated on: 2025-11-25T11:00:36.488Z
4
+ Generated on: 2025-11-25T11:42:23.401Z
5
5
  Do not edit directly!
6
6
 
7
7
  NOTE: Android shadows are complex and platform-specific.
@@ -1,7 +1,7 @@
1
1
  <?xml version="1.0" encoding="utf-8"?>
2
2
  <!--
3
3
  Effect Tokens - Advertorial / light
4
- Generated on: 2025-11-25T11:00:36.446Z
4
+ Generated on: 2025-11-25T11:42:23.351Z
5
5
  Do not edit directly!
6
6
 
7
7
  NOTE: Android shadows are complex and platform-specific.
@@ -1,7 +1,7 @@
1
1
  <?xml version="1.0" encoding="utf-8"?>
2
2
  <!--
3
3
  Effect Tokens - Bild / dark
4
- Generated on: 2025-11-25T11:00:36.309Z
4
+ Generated on: 2025-11-25T11:42:23.220Z
5
5
  Do not edit directly!
6
6
 
7
7
  NOTE: Android shadows are complex and platform-specific.
@@ -1,7 +1,7 @@
1
1
  <?xml version="1.0" encoding="utf-8"?>
2
2
  <!--
3
3
  Effect Tokens - Bild / light
4
- Generated on: 2025-11-25T11:00:36.263Z
4
+ Generated on: 2025-11-25T11:42:23.172Z
5
5
  Do not edit directly!
6
6
 
7
7
  NOTE: Android shadows are complex and platform-specific.
@@ -1,7 +1,7 @@
1
1
  <?xml version="1.0" encoding="utf-8"?>
2
2
  <!--
3
3
  Effect Tokens - Sportbild / dark
4
- Generated on: 2025-11-25T11:00:36.394Z
4
+ Generated on: 2025-11-25T11:42:23.306Z
5
5
  Do not edit directly!
6
6
 
7
7
  NOTE: Android shadows are complex and platform-specific.