@atlaskit/ds-explorations 1.6.4 → 2.0.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 (67) hide show
  1. package/CHANGELOG.md +24 -0
  2. package/dist/cjs/components/box.partial.js +48 -45
  3. package/dist/cjs/components/inline.partial.js +15 -15
  4. package/dist/cjs/components/interaction-surface.partial.js +2 -2
  5. package/dist/cjs/components/stack.partial.js +15 -15
  6. package/dist/cjs/components/text.partial.js +88 -58
  7. package/dist/cjs/internal/color-map.js +2 -2
  8. package/dist/cjs/internal/spacing-scale.js +2 -2
  9. package/dist/cjs/version.json +1 -1
  10. package/dist/es2019/components/box.partial.js +48 -45
  11. package/dist/es2019/components/inline.partial.js +15 -15
  12. package/dist/es2019/components/interaction-surface.partial.js +2 -2
  13. package/dist/es2019/components/stack.partial.js +15 -15
  14. package/dist/es2019/components/text.partial.js +87 -57
  15. package/dist/es2019/internal/color-map.js +2 -2
  16. package/dist/es2019/internal/spacing-scale.js +2 -2
  17. package/dist/es2019/version.json +1 -1
  18. package/dist/esm/components/box.partial.js +48 -45
  19. package/dist/esm/components/inline.partial.js +15 -15
  20. package/dist/esm/components/interaction-surface.partial.js +2 -2
  21. package/dist/esm/components/stack.partial.js +15 -15
  22. package/dist/esm/components/text.partial.js +87 -57
  23. package/dist/esm/internal/color-map.js +2 -2
  24. package/dist/esm/internal/spacing-scale.js +2 -2
  25. package/dist/esm/version.json +1 -1
  26. package/dist/types/components/box.partial.d.ts +46 -45
  27. package/dist/types/components/inline.partial.d.ts +15 -15
  28. package/dist/types/components/stack.partial.d.ts +15 -15
  29. package/dist/types/components/text.partial.d.ts +45 -25
  30. package/dist/types/internal/color-map.d.ts +2 -2
  31. package/dist/types/internal/spacing-scale.d.ts +2 -2
  32. package/examples/00-basic.tsx +3 -3
  33. package/examples/01-box.tsx +18 -18
  34. package/examples/02-text-advanced.tsx +9 -9
  35. package/examples/02-text.tsx +36 -16
  36. package/examples/03-stack.tsx +26 -26
  37. package/examples/04-inline.tsx +26 -26
  38. package/examples/05-badge.tsx +2 -2
  39. package/examples/06-section-message.tsx +6 -6
  40. package/examples/07-comment.tsx +5 -5
  41. package/examples/08-lozenge.tsx +4 -4
  42. package/examples/99-interactions.tsx +16 -16
  43. package/package.json +1 -1
  44. package/report.api.md +90 -85
  45. package/scripts/codegen-styles.tsx +27 -0
  46. package/scripts/spacing-codegen-template.tsx +3 -4
  47. package/scripts/spacing-scale-template.tsx +3 -5
  48. package/scripts/typography-codegen-template.tsx +80 -0
  49. package/src/components/__tests__/unit/inline.test.tsx +3 -3
  50. package/src/components/__tests__/unit/stack.test.tsx +2 -2
  51. package/src/components/__tests__/unit/text.test.tsx +3 -3
  52. package/src/components/__tests__/visual-regression/__image_snapshots__/box-snapshot-test-tsx-box-example-with-background-and-padding-block-should-match-snapshot-1-snap.png +2 -2
  53. package/src/components/__tests__/visual-regression/__image_snapshots__/box-snapshot-test-tsx-box-example-with-background-and-padding-inline-should-match-snapshot-1-snap.png +2 -2
  54. package/src/components/__tests__/visual-regression/__image_snapshots__/box-snapshot-test-tsx-box-example-with-background-and-padding-should-match-snapshot-1-snap.png +2 -2
  55. package/src/components/__tests__/visual-regression/__image_snapshots__/inline-snapshot-test-tsx-inline-spacing-example-should-match-snapshot-1-snap.png +2 -2
  56. package/src/components/__tests__/visual-regression/__image_snapshots__/stack-snapshot-test-tsx-stack-spacing-example-should-match-snapshot-1-snap.png +2 -2
  57. package/src/components/__tests__/visual-regression/__image_snapshots__/text-snapshot-test-tsx-text-example-with-font-sizes-should-match-snapshot-1-snap.png +2 -2
  58. package/src/components/__tests__/visual-regression/__image_snapshots__/text-snapshot-test-tsx-text-example-with-font-weights-should-match-snapshot-1-snap.png +2 -2
  59. package/src/components/__tests__/visual-regression/__image_snapshots__/text-snapshot-test-tsx-text-example-with-line-heights-should-match-snapshot-1-snap.png +2 -2
  60. package/src/components/box.partial.tsx +46 -45
  61. package/src/components/inline.partial.tsx +15 -15
  62. package/src/components/interaction-surface.partial.tsx +2 -2
  63. package/src/components/stack.partial.tsx +15 -15
  64. package/src/components/text.partial.tsx +103 -34
  65. package/src/internal/color-map.tsx +2 -2
  66. package/src/internal/spacing-scale.tsx +15 -15
  67. package/tmp/api-report-tmp.d.ts +90 -85
package/CHANGELOG.md CHANGED
@@ -1,5 +1,29 @@
1
1
  # @atlaskit/ds-explorations
2
2
 
3
+ ## 2.0.0
4
+
5
+ ### Major Changes
6
+
7
+ - [`544c409d79f`](https://bitbucket.org/atlassian/atlassian-frontend/commits/544c409d79f) - **Breaking Change**
8
+
9
+ ### `Text`
10
+
11
+ fontSize, fontWeight, and lineHeight APIs have changed due to typography tokens being introduced. The new values for fontSize and lineHeight follow a scale whereas fontWeight accepts keyword values.
12
+
13
+ ### `Box`
14
+
15
+ `padding`, `paddingBlock`, and `paddingInline` prop values now follow the pattern `space.x` instead of `scale.x` to align with spacing tokens.
16
+
17
+ ### `Inline` and `Stack`
18
+
19
+ `gap` prop values now follow the pattern `space.x` instead of `scale.x` to align with spacing tokens.
20
+
21
+ ## 1.7.0
22
+
23
+ ### Minor Changes
24
+
25
+ - [`642298a54dc`](https://bitbucket.org/atlassian/atlassian-frontend/commits/642298a54dc) - Box - Allow `display` prop to take `inline-block`.
26
+
3
27
  ## 1.6.4
4
28
 
5
29
  ### Patch Changes
@@ -183,6 +183,9 @@ var displayMap = {
183
183
  }),
184
184
  inlineFlex: (0, _react2.css)({
185
185
  display: 'inline-flex'
186
+ }),
187
+ inlineBlock: (0, _react2.css)({
188
+ display: 'inline-block'
186
189
  })
187
190
  };
188
191
  var positionMap = {
@@ -279,141 +282,141 @@ var heightMap = {
279
282
 
280
283
  /**
281
284
  * THIS SECTION WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
282
- * @codegen <<SignedSource::cbecbcc7b02d1d58fdd794542eb54d50>>
285
+ * @codegen <<SignedSource::99c5403dd8b57b15bf1240cc456b6b16>>
283
286
  * @codegenId spacing
284
287
  * @codegenCommand yarn codegen-styles
285
288
  * @codegenParams ["padding", "paddingBlock", "paddingInline"]
286
289
  * @codegenDependency ../../../tokens/src/artifacts/tokens-raw/atlassian-spacing.tsx <<SignedSource::a2b43f8447798dfdd9c6223bd22b78c7>>
287
290
  */
288
291
  var paddingMap = {
289
- 'scale.0': (0, _react2.css)({
292
+ 'space.0': (0, _react2.css)({
290
293
  padding: "var(--ds-space-0, 0px)"
291
294
  }),
292
- 'scale.025': (0, _react2.css)({
295
+ 'space.025': (0, _react2.css)({
293
296
  padding: "var(--ds-space-025, 2px)"
294
297
  }),
295
- 'scale.050': (0, _react2.css)({
298
+ 'space.050': (0, _react2.css)({
296
299
  padding: "var(--ds-space-050, 4px)"
297
300
  }),
298
- 'scale.075': (0, _react2.css)({
301
+ 'space.075': (0, _react2.css)({
299
302
  padding: "var(--ds-space-075, 6px)"
300
303
  }),
301
- 'scale.100': (0, _react2.css)({
304
+ 'space.100': (0, _react2.css)({
302
305
  padding: "var(--ds-space-100, 8px)"
303
306
  }),
304
- 'scale.1000': (0, _react2.css)({
307
+ 'space.1000': (0, _react2.css)({
305
308
  padding: "var(--ds-space-1000, 80px)"
306
309
  }),
307
- 'scale.150': (0, _react2.css)({
310
+ 'space.150': (0, _react2.css)({
308
311
  padding: "var(--ds-space-150, 12px)"
309
312
  }),
310
- 'scale.200': (0, _react2.css)({
313
+ 'space.200': (0, _react2.css)({
311
314
  padding: "var(--ds-space-200, 16px)"
312
315
  }),
313
- 'scale.250': (0, _react2.css)({
316
+ 'space.250': (0, _react2.css)({
314
317
  padding: "var(--ds-space-250, 20px)"
315
318
  }),
316
- 'scale.300': (0, _react2.css)({
319
+ 'space.300': (0, _react2.css)({
317
320
  padding: "var(--ds-space-300, 24px)"
318
321
  }),
319
- 'scale.400': (0, _react2.css)({
322
+ 'space.400': (0, _react2.css)({
320
323
  padding: "var(--ds-space-400, 32px)"
321
324
  }),
322
- 'scale.500': (0, _react2.css)({
325
+ 'space.500': (0, _react2.css)({
323
326
  padding: "var(--ds-space-500, 40px)"
324
327
  }),
325
- 'scale.600': (0, _react2.css)({
328
+ 'space.600': (0, _react2.css)({
326
329
  padding: "var(--ds-space-600, 48px)"
327
330
  }),
328
- 'scale.800': (0, _react2.css)({
331
+ 'space.800': (0, _react2.css)({
329
332
  padding: "var(--ds-space-800, 64px)"
330
333
  })
331
334
  };
332
335
  var paddingBlockMap = {
333
- 'scale.0': (0, _react2.css)({
336
+ 'space.0': (0, _react2.css)({
334
337
  paddingBlock: "var(--ds-space-0, 0px)"
335
338
  }),
336
- 'scale.025': (0, _react2.css)({
339
+ 'space.025': (0, _react2.css)({
337
340
  paddingBlock: "var(--ds-space-025, 2px)"
338
341
  }),
339
- 'scale.050': (0, _react2.css)({
342
+ 'space.050': (0, _react2.css)({
340
343
  paddingBlock: "var(--ds-space-050, 4px)"
341
344
  }),
342
- 'scale.075': (0, _react2.css)({
345
+ 'space.075': (0, _react2.css)({
343
346
  paddingBlock: "var(--ds-space-075, 6px)"
344
347
  }),
345
- 'scale.100': (0, _react2.css)({
348
+ 'space.100': (0, _react2.css)({
346
349
  paddingBlock: "var(--ds-space-100, 8px)"
347
350
  }),
348
- 'scale.1000': (0, _react2.css)({
351
+ 'space.1000': (0, _react2.css)({
349
352
  paddingBlock: "var(--ds-space-1000, 80px)"
350
353
  }),
351
- 'scale.150': (0, _react2.css)({
354
+ 'space.150': (0, _react2.css)({
352
355
  paddingBlock: "var(--ds-space-150, 12px)"
353
356
  }),
354
- 'scale.200': (0, _react2.css)({
357
+ 'space.200': (0, _react2.css)({
355
358
  paddingBlock: "var(--ds-space-200, 16px)"
356
359
  }),
357
- 'scale.250': (0, _react2.css)({
360
+ 'space.250': (0, _react2.css)({
358
361
  paddingBlock: "var(--ds-space-250, 20px)"
359
362
  }),
360
- 'scale.300': (0, _react2.css)({
363
+ 'space.300': (0, _react2.css)({
361
364
  paddingBlock: "var(--ds-space-300, 24px)"
362
365
  }),
363
- 'scale.400': (0, _react2.css)({
366
+ 'space.400': (0, _react2.css)({
364
367
  paddingBlock: "var(--ds-space-400, 32px)"
365
368
  }),
366
- 'scale.500': (0, _react2.css)({
369
+ 'space.500': (0, _react2.css)({
367
370
  paddingBlock: "var(--ds-space-500, 40px)"
368
371
  }),
369
- 'scale.600': (0, _react2.css)({
372
+ 'space.600': (0, _react2.css)({
370
373
  paddingBlock: "var(--ds-space-600, 48px)"
371
374
  }),
372
- 'scale.800': (0, _react2.css)({
375
+ 'space.800': (0, _react2.css)({
373
376
  paddingBlock: "var(--ds-space-800, 64px)"
374
377
  })
375
378
  };
376
379
  var paddingInlineMap = {
377
- 'scale.0': (0, _react2.css)({
380
+ 'space.0': (0, _react2.css)({
378
381
  paddingInline: "var(--ds-space-0, 0px)"
379
382
  }),
380
- 'scale.025': (0, _react2.css)({
383
+ 'space.025': (0, _react2.css)({
381
384
  paddingInline: "var(--ds-space-025, 2px)"
382
385
  }),
383
- 'scale.050': (0, _react2.css)({
386
+ 'space.050': (0, _react2.css)({
384
387
  paddingInline: "var(--ds-space-050, 4px)"
385
388
  }),
386
- 'scale.075': (0, _react2.css)({
389
+ 'space.075': (0, _react2.css)({
387
390
  paddingInline: "var(--ds-space-075, 6px)"
388
391
  }),
389
- 'scale.100': (0, _react2.css)({
392
+ 'space.100': (0, _react2.css)({
390
393
  paddingInline: "var(--ds-space-100, 8px)"
391
394
  }),
392
- 'scale.1000': (0, _react2.css)({
395
+ 'space.1000': (0, _react2.css)({
393
396
  paddingInline: "var(--ds-space-1000, 80px)"
394
397
  }),
395
- 'scale.150': (0, _react2.css)({
398
+ 'space.150': (0, _react2.css)({
396
399
  paddingInline: "var(--ds-space-150, 12px)"
397
400
  }),
398
- 'scale.200': (0, _react2.css)({
401
+ 'space.200': (0, _react2.css)({
399
402
  paddingInline: "var(--ds-space-200, 16px)"
400
403
  }),
401
- 'scale.250': (0, _react2.css)({
404
+ 'space.250': (0, _react2.css)({
402
405
  paddingInline: "var(--ds-space-250, 20px)"
403
406
  }),
404
- 'scale.300': (0, _react2.css)({
407
+ 'space.300': (0, _react2.css)({
405
408
  paddingInline: "var(--ds-space-300, 24px)"
406
409
  }),
407
- 'scale.400': (0, _react2.css)({
410
+ 'space.400': (0, _react2.css)({
408
411
  paddingInline: "var(--ds-space-400, 32px)"
409
412
  }),
410
- 'scale.500': (0, _react2.css)({
413
+ 'space.500': (0, _react2.css)({
411
414
  paddingInline: "var(--ds-space-500, 40px)"
412
415
  }),
413
- 'scale.600': (0, _react2.css)({
416
+ 'space.600': (0, _react2.css)({
414
417
  paddingInline: "var(--ds-space-600, 48px)"
415
418
  }),
416
- 'scale.800': (0, _react2.css)({
419
+ 'space.800': (0, _react2.css)({
417
420
  paddingInline: "var(--ds-space-800, 64px)"
418
421
  })
419
422
  };
@@ -424,11 +427,11 @@ var paddingInlineMap = {
424
427
 
425
428
  /**
426
429
  * THIS SECTION WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
427
- * @codegen <<SignedSource::a9e4bc0092d25e3209c53182183c49f2>>
430
+ * @codegen <<SignedSource::201c8a6c6ff88ac47cdb02365c643ff2>>
428
431
  * @codegenId colors
429
432
  * @codegenCommand yarn codegen-styles
430
433
  * @codegenParams ["border", "background", "shadow"]
431
- * @codegenDependency ../../../tokens/src/artifacts/tokens-raw/atlassian-light.tsx <<SignedSource::ae0b86bfc4c093b614a97d5bcf328dd0>>
434
+ * @codegenDependency ../../../tokens/src/artifacts/tokens-raw/atlassian-light.tsx <<SignedSource::db7a1282630a6e5b9424b807614086af>>
432
435
  */
433
436
  var borderColorMap = {
434
437
  'color.border': (0, _react2.css)({
@@ -120,7 +120,7 @@ Inline.displayName = 'Inline';
120
120
  var _default = Inline;
121
121
  /**
122
122
  * THIS SECTION WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
123
- * @codegen <<SignedSource::3bb74c0e18d35310a98408ecd49c1526>>
123
+ * @codegen <<SignedSource::0a2a4380b534d14cdad759ff2d33a6c8>>
124
124
  * @codegenId spacing
125
125
  * @codegenCommand yarn codegen-styles
126
126
  * @codegenParams ["columnGap"]
@@ -129,46 +129,46 @@ var _default = Inline;
129
129
 
130
130
  exports.default = _default;
131
131
  var columnGapMap = {
132
- 'scale.0': (0, _react2.css)({
132
+ 'space.0': (0, _react2.css)({
133
133
  columnGap: "var(--ds-space-0, 0px)"
134
134
  }),
135
- 'scale.025': (0, _react2.css)({
135
+ 'space.025': (0, _react2.css)({
136
136
  columnGap: "var(--ds-space-025, 2px)"
137
137
  }),
138
- 'scale.050': (0, _react2.css)({
138
+ 'space.050': (0, _react2.css)({
139
139
  columnGap: "var(--ds-space-050, 4px)"
140
140
  }),
141
- 'scale.075': (0, _react2.css)({
141
+ 'space.075': (0, _react2.css)({
142
142
  columnGap: "var(--ds-space-075, 6px)"
143
143
  }),
144
- 'scale.100': (0, _react2.css)({
144
+ 'space.100': (0, _react2.css)({
145
145
  columnGap: "var(--ds-space-100, 8px)"
146
146
  }),
147
- 'scale.1000': (0, _react2.css)({
147
+ 'space.1000': (0, _react2.css)({
148
148
  columnGap: "var(--ds-space-1000, 80px)"
149
149
  }),
150
- 'scale.150': (0, _react2.css)({
150
+ 'space.150': (0, _react2.css)({
151
151
  columnGap: "var(--ds-space-150, 12px)"
152
152
  }),
153
- 'scale.200': (0, _react2.css)({
153
+ 'space.200': (0, _react2.css)({
154
154
  columnGap: "var(--ds-space-200, 16px)"
155
155
  }),
156
- 'scale.250': (0, _react2.css)({
156
+ 'space.250': (0, _react2.css)({
157
157
  columnGap: "var(--ds-space-250, 20px)"
158
158
  }),
159
- 'scale.300': (0, _react2.css)({
159
+ 'space.300': (0, _react2.css)({
160
160
  columnGap: "var(--ds-space-300, 24px)"
161
161
  }),
162
- 'scale.400': (0, _react2.css)({
162
+ 'space.400': (0, _react2.css)({
163
163
  columnGap: "var(--ds-space-400, 32px)"
164
164
  }),
165
- 'scale.500': (0, _react2.css)({
165
+ 'space.500': (0, _react2.css)({
166
166
  columnGap: "var(--ds-space-500, 40px)"
167
167
  }),
168
- 'scale.600': (0, _react2.css)({
168
+ 'space.600': (0, _react2.css)({
169
169
  columnGap: "var(--ds-space-600, 48px)"
170
170
  }),
171
- 'scale.800': (0, _react2.css)({
171
+ 'space.800': (0, _react2.css)({
172
172
  columnGap: "var(--ds-space-800, 64px)"
173
173
  })
174
174
  };
@@ -58,11 +58,11 @@ var InteractionSurface = function InteractionSurface(_ref) {
58
58
  var _default = InteractionSurface;
59
59
  /**
60
60
  * THIS SECTION WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
61
- * @codegen <<SignedSource::8b4cdc5491507aa9045f9b3bd8b9ce84>>
61
+ * @codegen <<SignedSource::46f9477bc75d77a16327328d1b49c35f>>
62
62
  * @codegenId interactions
63
63
  * @codegenCommand yarn codegen-styles
64
64
  * @codegenParams ["background"]
65
- * @codegenDependency ../../../tokens/src/artifacts/tokens-raw/atlassian-light.tsx <<SignedSource::ae0b86bfc4c093b614a97d5bcf328dd0>>
65
+ * @codegenDependency ../../../tokens/src/artifacts/tokens-raw/atlassian-light.tsx <<SignedSource::db7a1282630a6e5b9424b807614086af>>
66
66
  */
67
67
 
68
68
  exports.default = _default;
@@ -84,7 +84,7 @@ Stack.displayName = 'Stack';
84
84
  var _default = Stack;
85
85
  /**
86
86
  * THIS SECTION WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
87
- * @codegen <<SignedSource::e574cf3d5b059f96c6158508fae4a064>>
87
+ * @codegen <<SignedSource::ac9028ae231558f3eedd10f0db04a8fe>>
88
88
  * @codegenId spacing
89
89
  * @codegenCommand yarn codegen-styles
90
90
  * @codegenParams ["rowGap"]
@@ -93,46 +93,46 @@ var _default = Stack;
93
93
 
94
94
  exports.default = _default;
95
95
  var rowGapMap = {
96
- 'scale.0': (0, _react2.css)({
96
+ 'space.0': (0, _react2.css)({
97
97
  rowGap: "var(--ds-space-0, 0px)"
98
98
  }),
99
- 'scale.025': (0, _react2.css)({
99
+ 'space.025': (0, _react2.css)({
100
100
  rowGap: "var(--ds-space-025, 2px)"
101
101
  }),
102
- 'scale.050': (0, _react2.css)({
102
+ 'space.050': (0, _react2.css)({
103
103
  rowGap: "var(--ds-space-050, 4px)"
104
104
  }),
105
- 'scale.075': (0, _react2.css)({
105
+ 'space.075': (0, _react2.css)({
106
106
  rowGap: "var(--ds-space-075, 6px)"
107
107
  }),
108
- 'scale.100': (0, _react2.css)({
108
+ 'space.100': (0, _react2.css)({
109
109
  rowGap: "var(--ds-space-100, 8px)"
110
110
  }),
111
- 'scale.1000': (0, _react2.css)({
111
+ 'space.1000': (0, _react2.css)({
112
112
  rowGap: "var(--ds-space-1000, 80px)"
113
113
  }),
114
- 'scale.150': (0, _react2.css)({
114
+ 'space.150': (0, _react2.css)({
115
115
  rowGap: "var(--ds-space-150, 12px)"
116
116
  }),
117
- 'scale.200': (0, _react2.css)({
117
+ 'space.200': (0, _react2.css)({
118
118
  rowGap: "var(--ds-space-200, 16px)"
119
119
  }),
120
- 'scale.250': (0, _react2.css)({
120
+ 'space.250': (0, _react2.css)({
121
121
  rowGap: "var(--ds-space-250, 20px)"
122
122
  }),
123
- 'scale.300': (0, _react2.css)({
123
+ 'space.300': (0, _react2.css)({
124
124
  rowGap: "var(--ds-space-300, 24px)"
125
125
  }),
126
- 'scale.400': (0, _react2.css)({
126
+ 'space.400': (0, _react2.css)({
127
127
  rowGap: "var(--ds-space-400, 32px)"
128
128
  }),
129
- 'scale.500': (0, _react2.css)({
129
+ 'space.500': (0, _react2.css)({
130
130
  rowGap: "var(--ds-space-500, 40px)"
131
131
  }),
132
- 'scale.600': (0, _react2.css)({
132
+ 'space.600': (0, _react2.css)({
133
133
  rowGap: "var(--ds-space-600, 48px)"
134
134
  }),
135
- 'scale.800': (0, _react2.css)({
135
+ 'space.800': (0, _react2.css)({
136
136
  rowGap: "var(--ds-space-800, 64px)"
137
137
  })
138
138
  };
@@ -21,56 +21,6 @@ var _surfaceProvider = require("./surface-provider");
21
21
 
22
22
  var _excluded = ["children"];
23
23
  var asAllowlist = ['span', 'div', 'p', 'strong'];
24
- var fontFamily = "-apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif";
25
- var fontSizeMap = {
26
- '11px': (0, _react2.css)({
27
- fontSize: '11px'
28
- }),
29
- '12px': (0, _react2.css)({
30
- fontSize: '12px'
31
- }),
32
- '14px': (0, _react2.css)({
33
- fontSize: '14px'
34
- })
35
- };
36
- // NOTE: can't use numbers as keys or Constellation won't build. Weird one.
37
- var fontWeightMap = {
38
- '400': (0, _react2.css)({
39
- fontWeight: 400
40
- }),
41
- '500': (0, _react2.css)({
42
- fontWeight: 500
43
- }),
44
- '600': (0, _react2.css)({
45
- fontWeight: 600
46
- }),
47
- '700': (0, _react2.css)({
48
- fontWeight: 700
49
- })
50
- };
51
- var lineHeightMap = {
52
- '12px': (0, _react2.css)({
53
- lineHeight: '12px'
54
- }),
55
- '16px': (0, _react2.css)({
56
- lineHeight: '16px'
57
- }),
58
- '20px': (0, _react2.css)({
59
- lineHeight: '20px'
60
- }),
61
- '24px': (0, _react2.css)({
62
- lineHeight: '24px'
63
- }),
64
- '28px': (0, _react2.css)({
65
- lineHeight: '28px'
66
- }),
67
- '32px': (0, _react2.css)({
68
- lineHeight: '32px'
69
- }),
70
- '40px': (0, _react2.css)({
71
- lineHeight: '40px'
72
- })
73
- };
74
24
  var textAlignMap = {
75
25
  center: (0, _react2.css)({
76
26
  textAlign: 'center'
@@ -106,9 +56,8 @@ var verticalAlignMap = {
106
56
  };
107
57
  var baseStyles = (0, _react2.css)({
108
58
  boxSizing: 'border-box',
109
- margin: '0px',
110
- padding: '0px',
111
- fontFamily: fontFamily
59
+ margin: "var(--ds-space-0, 0px)",
60
+ padding: "var(--ds-space-0, 0px)"
112
61
  });
113
62
  var truncateStyles = (0, _react2.css)({
114
63
  overflow: 'hidden',
@@ -178,7 +127,7 @@ var Text = function Text(_ref) {
178
127
 
179
128
  var component = (0, _react2.jsx)(Component, {
180
129
  style: UNSAFE_style,
181
- css: [baseStyles, color && textColorMap[color], fontSize && fontSizeMap[fontSize], fontWeight && fontWeightMap[fontWeight], lineHeight && lineHeightMap[lineHeight], shouldTruncate && truncateStyles, textAlign && textAlignMap[textAlign], textTransform && textTransformMap[textTransform], verticalAlign && verticalAlignMap[verticalAlign]],
130
+ css: [baseStyles, fontFamilyMap.sans, color && textColorMap[color], fontSize && fontSizeMap[fontSize], fontWeight && fontWeightMap[fontWeight], lineHeight && lineHeightMap[lineHeight], shouldTruncate && truncateStyles, textAlign && textAlignMap[textAlign], textTransform && textTransformMap[textTransform], verticalAlign && verticalAlignMap[verticalAlign]],
182
131
  "data-testid": testId,
183
132
  id: id
184
133
  }, children);
@@ -191,14 +140,95 @@ var Text = function Text(_ref) {
191
140
  var _default = Text;
192
141
  /**
193
142
  * THIS SECTION WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
194
- * @codegen <<SignedSource::61daf1362fce18ffbc609fc6cb456484>>
195
- * @codegenId colors
143
+ * @codegen <<SignedSource::bd36caff8bedb3bdc89b6f2311c6160a>>
144
+ * @codegenId typography
196
145
  * @codegenCommand yarn codegen-styles
197
- * @codegenParams ["text"]
198
- * @codegenDependency ../../../tokens/src/artifacts/tokens-raw/atlassian-light.tsx <<SignedSource::ae0b86bfc4c093b614a97d5bcf328dd0>>
146
+ * @codegenParams ["fontSize", "fontWeight", "fontFamily", "lineHeight"]
147
+ * @codegenDependency ../../../tokens/src/artifacts/tokens-raw/atlassian-typography.tsx <<SignedSource::39bc8db0f376f5635a25be0137792642>>
199
148
  */
200
149
 
201
150
  exports.default = _default;
151
+ var fontSizeMap = {
152
+ 'size.050': (0, _react2.css)({
153
+ fontSize: "var(--ds-font-size-050, 11px)"
154
+ }),
155
+ 'size.075': (0, _react2.css)({
156
+ fontSize: "var(--ds-font-size-075, 12px)"
157
+ }),
158
+ 'size.100': (0, _react2.css)({
159
+ fontSize: "var(--ds-font-size-100, 14px)"
160
+ }),
161
+ 'size.200': (0, _react2.css)({
162
+ fontSize: "var(--ds-font-size-200, 16px)"
163
+ }),
164
+ 'size.300': (0, _react2.css)({
165
+ fontSize: "var(--ds-font-size-300, 20px)"
166
+ }),
167
+ 'size.400': (0, _react2.css)({
168
+ fontSize: "var(--ds-font-size-400, 24px)"
169
+ }),
170
+ 'size.500': (0, _react2.css)({
171
+ fontSize: "var(--ds-font-size-500, 29px)"
172
+ }),
173
+ 'size.600': (0, _react2.css)({
174
+ fontSize: "var(--ds-font-size-600, 35px)"
175
+ })
176
+ };
177
+ var fontWeightMap = {
178
+ bold: (0, _react2.css)({
179
+ fontWeight: "var(--ds-font-weight-bold, 700)"
180
+ }),
181
+ medium: (0, _react2.css)({
182
+ fontWeight: "var(--ds-font-weight-medium, 500)"
183
+ }),
184
+ regular: (0, _react2.css)({
185
+ fontWeight: "var(--ds-font-weight-regular, 400)"
186
+ }),
187
+ semibold: (0, _react2.css)({
188
+ fontWeight: "var(--ds-font-weight-semibold, 600)"
189
+ })
190
+ };
191
+ var fontFamilyMap = {
192
+ monospace: (0, _react2.css)({
193
+ fontFamily: "var(--ds-font-family-monospace, \"SFMono-Medium\", \"SF Mono\", \"Segoe UI Mono\", \"Roboto Mono\", \"Ubuntu Mono\", Menlo, Consolas, Courier, monospace)"
194
+ }),
195
+ sans: (0, _react2.css)({
196
+ fontFamily: "var(--ds-font-family-sans, -apple-system, BlinkMacSystemFont, \"Segoe UI\", \"Roboto\", \"Oxygen\", \"Ubuntu\", \"Fira Sans\", \"Droid Sans\", \"Helvetica Neue\", sans-serif)"
197
+ })
198
+ };
199
+ var lineHeightMap = {
200
+ 'lineHeight.100': (0, _react2.css)({
201
+ lineHeight: "var(--ds-font-lineHeight-100, 16px)"
202
+ }),
203
+ 'lineHeight.200': (0, _react2.css)({
204
+ lineHeight: "var(--ds-font-lineHeight-200, 20px)"
205
+ }),
206
+ 'lineHeight.300': (0, _react2.css)({
207
+ lineHeight: "var(--ds-font-lineHeight-300, 24px)"
208
+ }),
209
+ 'lineHeight.400': (0, _react2.css)({
210
+ lineHeight: "var(--ds-font-lineHeight-400, 28px)"
211
+ }),
212
+ 'lineHeight.500': (0, _react2.css)({
213
+ lineHeight: "var(--ds-font-lineHeight-500, 32px)"
214
+ }),
215
+ 'lineHeight.600': (0, _react2.css)({
216
+ lineHeight: "var(--ds-font-lineHeight-600, 40px)"
217
+ })
218
+ };
219
+
220
+ /**
221
+ * @codegenEnd
222
+ */
223
+
224
+ /**
225
+ * THIS SECTION WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
226
+ * @codegen <<SignedSource::d88a2527302fee634bec7ae405e9217b>>
227
+ * @codegenId colors
228
+ * @codegenCommand yarn codegen-styles
229
+ * @codegenParams ["text"]
230
+ * @codegenDependency ../../../tokens/src/artifacts/tokens-raw/atlassian-light.tsx <<SignedSource::db7a1282630a6e5b9424b807614086af>>
231
+ */
202
232
  var textColorMap = {
203
233
  'color.text': (0, _react2.css)({
204
234
  color: "var(--ds-text, #172B4D)"
@@ -10,9 +10,9 @@ exports.default = void 0;
10
10
  *
11
11
  * The color map is used to map a background color token to a matching text color that will meet contrast.
12
12
  *
13
- * @codegen <<SignedSource::dc79858789f08b7f160d8d6db9779b22>>
13
+ * @codegen <<SignedSource::55412dc750db330e0a2a51918237e29f>>
14
14
  * @codegenCommand yarn codegen-styles
15
- * @codegenDependency ../../../tokens/src/artifacts/tokens-raw/atlassian-light.tsx <<SignedSource::ae0b86bfc4c093b614a97d5bcf328dd0>>
15
+ * @codegenDependency ../../../tokens/src/artifacts/tokens-raw/atlassian-light.tsx <<SignedSource::db7a1282630a6e5b9424b807614086af>>
16
16
  */
17
17
  var _default = {
18
18
  'neutral.bold': 'inverse',
@@ -10,8 +10,8 @@ exports.spacingScale = void 0;
10
10
  *
11
11
  * Internal codegen of the spacing scale values. Only used for internal examples.
12
12
  *
13
- * @codegen <<SignedSource::d351e41acd06f256fb46554409694f31>>
13
+ * @codegen <<SignedSource::885d6c601dfa9fccaf33a7bd461ef59d>>
14
14
  * @codegenCommand yarn codegen-styles
15
15
  */
16
- var spacingScale = ['scale.0', 'scale.025', 'scale.050', 'scale.075', 'scale.100', 'scale.150', 'scale.200', 'scale.250', 'scale.300', 'scale.400', 'scale.500', 'scale.600', 'scale.800', 'scale.1000'];
16
+ var spacingScale = ['space.0', 'space.025', 'space.050', 'space.075', 'space.100', 'space.150', 'space.200', 'space.250', 'space.300', 'space.400', 'space.500', 'space.600', 'space.800', 'space.1000'];
17
17
  exports.spacingScale = spacingScale;
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/ds-explorations",
3
- "version": "1.6.4",
3
+ "version": "2.0.0",
4
4
  "sideEffects": false
5
5
  }