@atlaskit/ds-explorations 0.0.3 → 0.1.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.
Files changed (114) hide show
  1. package/CHANGELOG.md +32 -0
  2. package/dist/cjs/components/box.partial.js +355 -185
  3. package/dist/cjs/components/inline.partial.js +124 -0
  4. package/dist/cjs/components/interaction-surface.partial.js +253 -0
  5. package/dist/cjs/components/stack.partial.js +116 -0
  6. package/dist/cjs/components/surface-provider.js +31 -0
  7. package/dist/cjs/components/text.partial.js +152 -49
  8. package/dist/cjs/components/types.js +5 -0
  9. package/dist/cjs/constants.js +3 -0
  10. package/dist/cjs/index.js +50 -3
  11. package/dist/cjs/internal/color-map.js +42 -0
  12. package/dist/cjs/internal/role-to-element.js +36 -0
  13. package/dist/cjs/version.json +1 -1
  14. package/dist/es2019/components/box.partial.js +259 -113
  15. package/dist/es2019/components/inline.partial.js +111 -0
  16. package/dist/es2019/components/interaction-surface.partial.js +243 -0
  17. package/dist/es2019/components/stack.partial.js +106 -0
  18. package/dist/es2019/components/surface-provider.js +20 -0
  19. package/dist/es2019/components/text.partial.js +122 -35
  20. package/dist/es2019/components/types.js +1 -0
  21. package/dist/es2019/constants.js +3 -0
  22. package/dist/es2019/index.js +6 -1
  23. package/dist/es2019/internal/color-map.js +34 -0
  24. package/dist/es2019/internal/role-to-element.js +28 -0
  25. package/dist/es2019/version.json +1 -1
  26. package/dist/esm/components/box.partial.js +274 -109
  27. package/dist/esm/components/inline.partial.js +110 -0
  28. package/dist/esm/components/interaction-surface.partial.js +242 -0
  29. package/dist/esm/components/stack.partial.js +105 -0
  30. package/dist/esm/components/surface-provider.js +20 -0
  31. package/dist/esm/components/text.partial.js +132 -34
  32. package/dist/esm/components/types.js +1 -0
  33. package/dist/esm/constants.js +3 -0
  34. package/dist/esm/index.js +6 -1
  35. package/dist/esm/internal/color-map.js +34 -0
  36. package/dist/esm/internal/role-to-element.js +28 -0
  37. package/dist/esm/version.json +1 -1
  38. package/dist/types/components/box.partial.d.ts +157 -76
  39. package/dist/types/components/inline.partial.d.ts +52 -0
  40. package/dist/types/components/interaction-surface.partial.d.ts +45 -0
  41. package/dist/types/components/stack.partial.d.ts +47 -0
  42. package/dist/types/components/surface-provider.d.ts +15 -0
  43. package/dist/types/components/text.partial.d.ts +100 -28
  44. package/dist/types/components/types.d.ts +13 -0
  45. package/dist/types/constants.d.ts +3 -0
  46. package/dist/types/index.d.ts +8 -2
  47. package/dist/types/internal/color-map.d.ts +34 -0
  48. package/dist/types/internal/role-to-element.d.ts +32 -0
  49. package/examples/00-basic.tsx +18 -1
  50. package/examples/01-box.tsx +126 -2
  51. package/examples/02-text.tsx +76 -2
  52. package/examples/03-stack.tsx +125 -0
  53. package/examples/04-inline.tsx +134 -0
  54. package/examples/{03-badge.tsx → 05-badge.tsx} +4 -4
  55. package/examples/{04-section-message.tsx → 06-section-message.tsx} +6 -6
  56. package/examples/{05-comment.tsx → 07-comment.tsx} +11 -9
  57. package/examples/08-lozenge.tsx +29 -0
  58. package/examples/99-interactions.tsx +175 -0
  59. package/package.json +8 -5
  60. package/report.api.md +457 -4
  61. package/scripts/__tests__/__snapshots__/codegen.test.tsx.snap +244 -50
  62. package/scripts/__tests__/codegen.test.tsx +5 -0
  63. package/scripts/codegen-styles.tsx +46 -10
  64. package/scripts/color-codegen-template.tsx +34 -12
  65. package/scripts/color-map-template.tsx +52 -0
  66. package/scripts/interaction-codegen.tsx +109 -0
  67. package/scripts/spacing-codegen-template.tsx +9 -1
  68. package/scripts/utils.tsx +5 -1
  69. package/src/components/__tests__/unit/box.test.tsx +50 -0
  70. package/src/components/__tests__/unit/inline.test.tsx +43 -0
  71. package/src/components/__tests__/unit/interaction-suface.test.tsx +70 -0
  72. package/src/components/__tests__/unit/stack.test.tsx +31 -0
  73. package/src/components/__tests__/unit/text.test.tsx +33 -0
  74. package/src/components/__tests__/visual-regression/__image_snapshots__/box-snapshot-test-tsx-box-basic-example-should-match-production-example-1-snap.png +3 -0
  75. package/src/components/__tests__/visual-regression/__image_snapshots__/box-snapshot-test-tsx-box-example-with-alignment-should-match-snapshot-1-snap.png +3 -0
  76. 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 +3 -0
  77. 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 +3 -0
  78. package/src/components/__tests__/visual-regression/__image_snapshots__/box-snapshot-test-tsx-box-example-with-background-and-padding-should-match-snapshot-1-snap.png +3 -0
  79. package/src/components/__tests__/visual-regression/__image_snapshots__/box-snapshot-test-tsx-box-example-with-background-color-should-match-snapshot-1-snap.png +3 -0
  80. package/src/components/__tests__/visual-regression/__image_snapshots__/box-snapshot-test-tsx-box-example-with-border-color-should-match-snapshot-1-snap.png +3 -0
  81. package/src/components/__tests__/visual-regression/__image_snapshots__/box-snapshot-test-tsx-box-example-with-border-should-match-snapshot-1-snap.png +3 -0
  82. package/src/components/__tests__/visual-regression/__image_snapshots__/inline-snapshot-test-tsx-inline-alignment-example-should-match-snapshot-1-snap.png +3 -0
  83. package/src/components/__tests__/visual-regression/__image_snapshots__/inline-snapshot-test-tsx-inline-spacing-example-should-match-snapshot-1-snap.png +3 -0
  84. package/src/components/__tests__/visual-regression/__image_snapshots__/stack-snapshot-test-tsx-stack-alignment-example-should-match-snapshot-1-snap.png +3 -0
  85. package/src/components/__tests__/visual-regression/__image_snapshots__/stack-snapshot-test-tsx-stack-spacing-example-should-match-snapshot-1-snap.png +3 -0
  86. package/src/components/__tests__/visual-regression/__image_snapshots__/text-snapshot-test-tsx-text-example-with-font-sizes-should-match-snapshot-1-snap.png +3 -0
  87. package/src/components/__tests__/visual-regression/__image_snapshots__/text-snapshot-test-tsx-text-example-with-font-weights-should-match-snapshot-1-snap.png +3 -0
  88. package/src/components/__tests__/visual-regression/__image_snapshots__/text-snapshot-test-tsx-text-example-with-line-heights-should-match-snapshot-1-snap.png +3 -0
  89. package/src/components/__tests__/visual-regression/__image_snapshots__/text-snapshot-test-tsx-text-example-with-testing-should-match-snapshot-1-snap.png +3 -0
  90. package/src/components/__tests__/visual-regression/box-snapshot-test.tsx +33 -0
  91. package/src/components/__tests__/visual-regression/inline-snapshot-test.tsx +28 -0
  92. package/src/components/__tests__/visual-regression/stack-snapshot-test.tsx +28 -0
  93. package/src/components/__tests__/visual-regression/text-snapshot-test.tsx +31 -0
  94. package/src/components/box.partial.tsx +305 -127
  95. package/src/components/inline.partial.tsx +120 -0
  96. package/src/components/interaction-surface.partial.tsx +237 -0
  97. package/src/components/stack.partial.tsx +104 -0
  98. package/src/components/surface-provider.tsx +25 -0
  99. package/src/components/text.partial.tsx +149 -38
  100. package/src/components/types.tsx +15 -0
  101. package/src/constants.tsx +3 -0
  102. package/src/index.tsx +8 -1
  103. package/src/internal/color-map.tsx +34 -0
  104. package/src/internal/role-to-element.tsx +34 -0
  105. package/dist/cjs/components/inline.js +0 -45
  106. package/dist/cjs/components/stack.js +0 -33
  107. package/dist/es2019/components/inline.js +0 -31
  108. package/dist/es2019/components/stack.js +0 -22
  109. package/dist/esm/components/inline.js +0 -30
  110. package/dist/esm/components/stack.js +0 -21
  111. package/dist/types/components/inline.d.ts +0 -19
  112. package/dist/types/components/stack.d.ts +0 -16
  113. package/src/components/inline.tsx +0 -49
  114. package/src/components/stack.tsx +0 -30
@@ -1,64 +1,167 @@
1
1
  "use strict";
2
2
 
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
3
5
  Object.defineProperty(exports, "__esModule", {
4
6
  value: true
5
7
  });
6
8
  exports.default = void 0;
7
9
 
8
- var _core = require("@emotion/core");
10
+ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
11
+
12
+ var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
13
+
14
+ var _react = require("@emotion/react");
15
+
16
+ var _tinyInvariant = _interopRequireDefault(require("tiny-invariant"));
17
+
18
+ var _colorMap = require("../internal/color-map");
9
19
 
10
- /** @jsx jsx */
11
- // These values are pulled from @atlaskit/theme
12
- var fontSize = 14;
13
- var fontSizeExtraSmall = 11;
14
- var fontSizeSmall = 12;
20
+ var _surfaceProvider = require("./surface-provider");
21
+
22
+ function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object); enumerableOnly && (symbols = symbols.filter(function (sym) { return Object.getOwnPropertyDescriptor(object, sym).enumerable; })), keys.push.apply(keys, symbols); } return keys; }
23
+
24
+ function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = null != arguments[i] ? arguments[i] : {}; i % 2 ? ownKeys(Object(source), !0).forEach(function (key) { (0, _defineProperty2.default)(target, key, source[key]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) { Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key)); }); } return target; }
25
+
26
+ var asAllowlist = ['span', 'div', 'p'];
15
27
  var fontFamily = "-apple-system, BlinkMacSystemFont, 'Segoe UI', 'Roboto', 'Oxygen', 'Ubuntu', 'Fira Sans', 'Droid Sans', 'Helvetica Neue', sans-serif";
16
28
  var fontSizeMap = {
17
- extraSmall: (0, _core.css)({
18
- fontSize: fontSizeExtraSmall
29
+ '11px': (0, _react.css)({
30
+ fontSize: '11px'
19
31
  }),
20
- small: (0, _core.css)({
21
- fontSize: fontSizeSmall
32
+ '12px': (0, _react.css)({
33
+ fontSize: '12px'
22
34
  }),
23
- normal: (0, _core.css)({
24
- fontSize: fontSize
35
+ '14px': (0, _react.css)({
36
+ fontSize: '14px'
25
37
  })
26
38
  };
39
+ // NOTE: can't use numbers as keys or Constellation won't build. Weird one.
27
40
  var fontWeightMap = {
28
- 400: (0, _core.css)({
41
+ '400': (0, _react.css)({
29
42
  fontWeight: 400
30
43
  }),
31
- 500: (0, _core.css)({
44
+ '500': (0, _react.css)({
32
45
  fontWeight: 500
46
+ }),
47
+ '700': (0, _react.css)({
48
+ fontWeight: 700
49
+ })
50
+ };
51
+ var lineHeightMap = {
52
+ '12px': (0, _react.css)({
53
+ lineHeight: '12px'
54
+ }),
55
+ '16px': (0, _react.css)({
56
+ lineHeight: '16px'
57
+ }),
58
+ '20px': (0, _react.css)({
59
+ lineHeight: '20px'
60
+ }),
61
+ '24px': (0, _react.css)({
62
+ lineHeight: '24px'
63
+ }),
64
+ '28px': (0, _react.css)({
65
+ lineHeight: '28px'
66
+ }),
67
+ '32px': (0, _react.css)({
68
+ lineHeight: '32px'
69
+ }),
70
+ '40px': (0, _react.css)({
71
+ lineHeight: '40px'
33
72
  })
34
73
  };
35
- var baseStyles = (0, _core.css)({
74
+ var textAlignMap = {
75
+ center: (0, _react.css)({
76
+ textAlign: 'center'
77
+ }),
78
+ end: (0, _react.css)({
79
+ textAlign: 'end'
80
+ }),
81
+ start: (0, _react.css)({
82
+ textAlign: 'start'
83
+ })
84
+ };
85
+ var textTransformMap = {
86
+ none: (0, _react.css)({
87
+ textTransform: 'none'
88
+ }),
89
+ lowercase: (0, _react.css)({
90
+ textTransform: 'lowercase'
91
+ }),
92
+ uppercase: (0, _react.css)({
93
+ textTransform: 'uppercase'
94
+ })
95
+ };
96
+ var verticalAlignMap = {
97
+ top: (0, _react.css)({
98
+ verticalAlign: 'top'
99
+ }),
100
+ middle: (0, _react.css)({
101
+ verticalAlign: 'middle'
102
+ }),
103
+ bottom: (0, _react.css)({
104
+ verticalAlign: 'bottom'
105
+ })
106
+ };
107
+ var baseStyles = (0, _react.css)({
108
+ boxSizing: 'border-box',
36
109
  fontFamily: fontFamily
37
110
  });
111
+ var truncateStyles = (0, _react.css)({
112
+ overflow: 'hidden',
113
+ textOverflow: 'ellipsis',
114
+ whiteSpace: 'nowrap'
115
+ });
38
116
  /**
39
117
  * __Text__
40
118
  *
41
- * A text {description}.
119
+ * Text is a primitive component that has the Atlassian Design System's design guidelines baked in.
120
+ * This includes considerations for text attributes such as color, font size, font weight, and line height.
121
+ * It renders a `span` by default.
42
122
  *
43
123
  * @internal
44
124
  */
45
125
 
46
- function Text(_ref) {
126
+ var Text = function Text(_ref) {
127
+ var _colorMap$surface;
128
+
47
129
  var _ref$as = _ref.as,
48
130
  Component = _ref$as === void 0 ? 'span' : _ref$as,
49
131
  children = _ref.children,
50
- color = _ref.color,
132
+ colorTuple = _ref.color,
51
133
  fontSize = _ref.fontSize,
52
- fontWeight = _ref.fontWeight;
53
- return (0, _core.jsx)(Component, {
54
- css: [baseStyles, color && textColorMap[color], fontSize && fontSizeMap[fontSize], fontWeight && fontWeightMap[fontWeight]]
134
+ fontWeight = _ref.fontWeight,
135
+ lineHeight = _ref.lineHeight,
136
+ _ref$shouldTruncate = _ref.shouldTruncate,
137
+ shouldTruncate = _ref$shouldTruncate === void 0 ? false : _ref$shouldTruncate,
138
+ textAlign = _ref.textAlign,
139
+ textTransform = _ref.textTransform,
140
+ verticalAlign = _ref.verticalAlign,
141
+ testId = _ref.testId,
142
+ UNSAFE_style = _ref.UNSAFE_style;
143
+ var surface = (0, _surfaceProvider.useSurface)(); // @ts-ignore
144
+
145
+ var _ref2 = colorTuple || [],
146
+ _ref3 = (0, _slicedToArray2.default)(_ref2, 2),
147
+ _ref3$ = _ref3[0],
148
+ color = _ref3$ === void 0 ? (_colorMap$surface = _colorMap.colorMap[surface]) !== null && _colorMap$surface !== void 0 ? _colorMap$surface : 'color.text' : _ref3$,
149
+ fallback = _ref3[1];
150
+
151
+ (0, _tinyInvariant.default)(asAllowlist.includes(Component), "@atlaskit/ds-explorations: Text received an invalid \"as\" value of \"".concat(Component, "\""));
152
+ return (0, _react.jsx)(Component, {
153
+ style: _objectSpread(_objectSpread({}, UNSAFE_style), fallback && {
154
+ '--ds-co-fb': fallback
155
+ }),
156
+ 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]],
157
+ "data-testid": testId
55
158
  }, children);
56
- }
159
+ };
57
160
 
58
161
  var _default = Text;
59
162
  /**
60
163
  * THIS SECTION WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
61
- * @codegen <<SignedSource::85816aeddf2947ff7678c0c551db336c>>
164
+ * @codegen <<SignedSource::140ffff6e1310c1c37e2067e2c232b92>>
62
165
  * @codegenId colors
63
166
  * @codegenCommand yarn codegen-styles
64
167
  * @codegenParams ["text"]
@@ -66,44 +169,44 @@ var _default = Text;
66
169
 
67
170
  exports.default = _default;
68
171
  var textColorMap = {
69
- default: (0, _core.css)({
70
- color: "var(--ds-text, #172B4D)"
172
+ 'color.text': (0, _react.css)({
173
+ color: "var(--ds-text, var(--ds-co-fb))"
71
174
  }),
72
- subtle: (0, _core.css)({
73
- color: "var(--ds-text-subtle, #44546F)"
175
+ subtle: (0, _react.css)({
176
+ color: "var(--ds-text-subtle, var(--ds-co-fb))"
74
177
  }),
75
- subtlest: (0, _core.css)({
76
- color: "var(--ds-text-subtlest, #626F86)"
178
+ subtlest: (0, _react.css)({
179
+ color: "var(--ds-text-subtlest, var(--ds-co-fb))"
77
180
  }),
78
- disabled: (0, _core.css)({
79
- color: "var(--ds-text-disabled, #091E424F)"
181
+ disabled: (0, _react.css)({
182
+ color: "var(--ds-text-disabled, var(--ds-co-fb))"
80
183
  }),
81
- inverse: (0, _core.css)({
82
- color: "var(--ds-text-inverse, #FFFFFF)"
184
+ inverse: (0, _react.css)({
185
+ color: "var(--ds-text-inverse, var(--ds-co-fb))"
83
186
  }),
84
- brand: (0, _core.css)({
85
- color: "var(--ds-text-brand, #0C66E4)"
187
+ brand: (0, _react.css)({
188
+ color: "var(--ds-text-brand, var(--ds-co-fb))"
86
189
  }),
87
- selected: (0, _core.css)({
88
- color: "var(--ds-text-selected, #0C66E4)"
190
+ selected: (0, _react.css)({
191
+ color: "var(--ds-text-selected, var(--ds-co-fb))"
89
192
  }),
90
- danger: (0, _core.css)({
91
- color: "var(--ds-text-danger, #AE2A19)"
193
+ danger: (0, _react.css)({
194
+ color: "var(--ds-text-danger, var(--ds-co-fb))"
92
195
  }),
93
- warning: (0, _core.css)({
94
- color: "var(--ds-text-warning, #974F0C)"
196
+ warning: (0, _react.css)({
197
+ color: "var(--ds-text-warning, var(--ds-co-fb))"
95
198
  }),
96
- 'warning.inverse': (0, _core.css)({
97
- color: "var(--ds-text-warning-inverse, #172B4D)"
199
+ 'warning.inverse': (0, _react.css)({
200
+ color: "var(--ds-text-warning-inverse, var(--ds-co-fb))"
98
201
  }),
99
- success: (0, _core.css)({
100
- color: "var(--ds-text-success, #216E4E)"
202
+ success: (0, _react.css)({
203
+ color: "var(--ds-text-success, var(--ds-co-fb))"
101
204
  }),
102
- discovery: (0, _core.css)({
103
- color: "var(--ds-text-discovery, #5E4DB2)"
205
+ discovery: (0, _react.css)({
206
+ color: "var(--ds-text-discovery, var(--ds-co-fb))"
104
207
  }),
105
- information: (0, _core.css)({
106
- color: "var(--ds-text-information, #0055CC)"
208
+ information: (0, _react.css)({
209
+ color: "var(--ds-text-information, var(--ds-co-fb))"
107
210
  })
108
211
  };
109
212
  /**
@@ -0,0 +1,5 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
@@ -5,13 +5,16 @@ Object.defineProperty(exports, "__esModule", {
5
5
  });
6
6
  exports.SPACING_SCALE = void 0;
7
7
  var SPACING_SCALE = {
8
+ 'sp-0': 0,
8
9
  'sp-25': 2,
9
10
  'sp-50': 4,
10
11
  'sp-75': 6,
11
12
  'sp-100': 8,
13
+ 'sp-150': 12,
12
14
  'sp-200': 16,
13
15
  'sp-300': 24,
14
16
  'sp-400': 32,
17
+ 'sp-500': 40,
15
18
  'sp-600': 48,
16
19
  'sp-800': 64
17
20
  };
package/dist/cjs/index.js CHANGED
@@ -1,8 +1,55 @@
1
1
  "use strict";
2
2
 
3
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
+
3
5
  Object.defineProperty(exports, "__esModule", {
4
6
  value: true
5
7
  });
6
- exports.default = void 0;
7
- var _default = {};
8
- exports.default = _default;
8
+ Object.defineProperty(exports, "UNSAFE_Box", {
9
+ enumerable: true,
10
+ get: function get() {
11
+ return _box.default;
12
+ }
13
+ });
14
+ Object.defineProperty(exports, "UNSAFE_Inline", {
15
+ enumerable: true,
16
+ get: function get() {
17
+ return _inline.default;
18
+ }
19
+ });
20
+ Object.defineProperty(exports, "UNSAFE_InteractionSurface", {
21
+ enumerable: true,
22
+ get: function get() {
23
+ return _interactionSurface.default;
24
+ }
25
+ });
26
+ Object.defineProperty(exports, "UNSAFE_SPACING_SCALE", {
27
+ enumerable: true,
28
+ get: function get() {
29
+ return _constants.SPACING_SCALE;
30
+ }
31
+ });
32
+ Object.defineProperty(exports, "UNSAFE_Stack", {
33
+ enumerable: true,
34
+ get: function get() {
35
+ return _stack.default;
36
+ }
37
+ });
38
+ Object.defineProperty(exports, "UNSAFE_Text", {
39
+ enumerable: true,
40
+ get: function get() {
41
+ return _text.default;
42
+ }
43
+ });
44
+
45
+ var _box = _interopRequireDefault(require("./components/box.partial"));
46
+
47
+ var _text = _interopRequireDefault(require("./components/text.partial"));
48
+
49
+ var _inline = _interopRequireDefault(require("./components/inline.partial"));
50
+
51
+ var _stack = _interopRequireDefault(require("./components/stack.partial"));
52
+
53
+ var _interactionSurface = _interopRequireDefault(require("./components/interaction-surface.partial"));
54
+
55
+ var _constants = require("./constants");
@@ -0,0 +1,42 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.colorMap = void 0;
7
+
8
+ /**
9
+ * THIS FILE WAS CREATED VIA CODEGEN DO NOT MODIFY {@see http://go/af-codegen}
10
+ *
11
+ * Some artifact
12
+ *
13
+ * @codegen <<SignedSource::8f568e4f0837f7af4a10429e060ad059>>
14
+ * @codegenCommand yarn codegen-styles
15
+ */
16
+ var colorMap = {
17
+ 'neutral.bold': 'inverse',
18
+ 'neutral.bold.hovered': 'inverse',
19
+ 'neutral.bold.pressed': 'inverse',
20
+ 'brand.bold': 'inverse',
21
+ 'brand.bold.hovered': 'inverse',
22
+ 'brand.bold.pressed': 'inverse',
23
+ 'selected.bold': 'inverse',
24
+ 'selected.bold.hovered': 'inverse',
25
+ 'selected.bold.pressed': 'inverse',
26
+ 'danger.bold': 'inverse',
27
+ 'danger.bold.hovered': 'inverse',
28
+ 'danger.bold.pressed': 'inverse',
29
+ 'warning.bold': 'warning.inverse',
30
+ 'warning.bold.hovered': 'warning.inverse',
31
+ 'warning.bold.pressed': 'warning.inverse',
32
+ 'success.bold': 'inverse',
33
+ 'success.bold.hovered': 'inverse',
34
+ 'success.bold.pressed': 'inverse',
35
+ 'discovery.bold': 'inverse',
36
+ 'discovery.bold.hovered': 'inverse',
37
+ 'discovery.bold.pressed': 'inverse',
38
+ 'information.bold': 'inverse',
39
+ 'information.bold.hovered': 'inverse',
40
+ 'information.bold.pressed': 'inverse'
41
+ };
42
+ exports.colorMap = colorMap;
@@ -0,0 +1,36 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.default = void 0;
7
+
8
+ /**
9
+ * Adapted straight from react-mui, with a small change.
10
+ * @see https://www.unpkg.com/browse/react-gui@0.2.1/src/modules/getAccessibilityElementWithSideEffect.js
11
+ */
12
+ var roleToElementType = {
13
+ article: 'article',
14
+ banner: 'header',
15
+ blockquote: 'blockquote',
16
+ button: 'button',
17
+ code: 'code',
18
+ complementary: 'aside',
19
+ contentinfo: 'footer',
20
+ deletion: 'del',
21
+ emphasis: 'em',
22
+ figure: 'figure',
23
+ insertion: 'ins',
24
+ form: 'form',
25
+ link: 'a',
26
+ list: 'ul',
27
+ listitem: 'li',
28
+ main: 'main',
29
+ navigation: 'nav',
30
+ region: 'section',
31
+ strong: 'strong',
32
+ presentation: 'div',
33
+ group: 'fieldset'
34
+ };
35
+ var _default = roleToElementType;
36
+ exports.default = _default;
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/ds-explorations",
3
- "version": "0.0.3",
3
+ "version": "0.1.2",
4
4
  "sideEffects": false
5
5
  }