@atlaskit/button 16.0.0 → 16.1.3

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.
@@ -9,6 +9,8 @@ exports.default = void 0;
9
9
 
10
10
  var colors = _interopRequireWildcard(require("@atlaskit/theme/colors"));
11
11
 
12
+ var _tokens = require("@atlaskit/tokens");
13
+
12
14
  function _getRequireWildcardCache(nodeInterop) { if (typeof WeakMap !== "function") return null; var cacheBabelInterop = new WeakMap(); var cacheNodeInterop = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(nodeInterop) { return nodeInterop ? cacheNodeInterop : cacheBabelInterop; })(nodeInterop); }
13
15
 
14
16
  function _interopRequireWildcard(obj, nodeInterop) { if (!nodeInterop && obj && obj.__esModule) { return obj; } if (obj === null || _typeof(obj) !== "object" && typeof obj !== "function") { return { default: obj }; } var cache = _getRequireWildcardCache(nodeInterop); if (cache && cache.has(obj)) { return cache.get(obj); } var newObj = {}; var hasPropertyDescriptor = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var key in obj) { if (key !== "default" && Object.prototype.hasOwnProperty.call(obj, key)) { var desc = hasPropertyDescriptor ? Object.getOwnPropertyDescriptor(obj, key) : null; if (desc && (desc.get || desc.set)) { Object.defineProperty(newObj, key, desc); } else { newObj[key] = obj[key]; } } } newObj.default = obj; if (cache) { cache.set(obj, newObj); } return newObj; }
@@ -21,106 +23,106 @@ var values = {
21
23
  background: {
22
24
  default: {
23
25
  default: {
24
- light: colors.N20A,
25
- dark: colors.DN70
26
+ light: (0, _tokens.token)('color.background.subtleNeutral.resting', colors.N20A),
27
+ dark: (0, _tokens.token)('color.background.subtleNeutral.resting', colors.DN70)
26
28
  },
27
29
  hover: {
28
- light: colors.N30A,
29
- dark: colors.DN60
30
+ light: (0, _tokens.token)('color.background.subtleNeutral.hover', colors.N30A),
31
+ dark: (0, _tokens.token)('color.background.subtleNeutral.hover', colors.DN60)
30
32
  },
31
33
  active: {
32
- light: fadedB75,
33
- dark: colors.B75
34
+ light: (0, _tokens.token)('color.background.subtleNeutral.pressed', fadedB75),
35
+ dark: (0, _tokens.token)('color.background.subtleNeutral.pressed', colors.B75)
34
36
  },
35
37
  disabled: {
36
- light: colors.N20A,
37
- dark: colors.DN70
38
+ light: (0, _tokens.token)('color.background.disabled', colors.N20A),
39
+ dark: (0, _tokens.token)('color.background.disabled', colors.DN70)
38
40
  },
39
41
  selected: {
40
- light: colors.N700,
41
- dark: colors.DN0
42
+ light: (0, _tokens.token)('color.background.selected.resting', colors.N700),
43
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.DN0)
42
44
  },
43
45
  focusSelected: {
44
- light: colors.N700,
45
- dark: colors.DN0
46
+ light: (0, _tokens.token)('color.background.selected.resting', colors.N700),
47
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.DN0)
46
48
  }
47
49
  },
48
50
  primary: {
49
51
  default: {
50
- light: colors.B400,
51
- dark: colors.B100
52
+ light: (0, _tokens.token)('color.background.boldBrand.resting', colors.B400),
53
+ dark: (0, _tokens.token)('color.background.boldBrand.resting', colors.B100)
52
54
  },
53
55
  hover: {
54
- light: colors.B300,
55
- dark: colors.B75
56
+ light: (0, _tokens.token)('color.background.boldBrand.hover', colors.B300),
57
+ dark: (0, _tokens.token)('color.background.boldBrand.hover', colors.B75)
56
58
  },
57
59
  active: {
58
- light: colors.B500,
59
- dark: colors.B200
60
+ light: (0, _tokens.token)('color.background.boldBrand.pressed', colors.B500),
61
+ dark: (0, _tokens.token)('color.background.boldBrand.pressed', colors.B200)
60
62
  },
61
63
  disabled: {
62
- light: colors.N20A,
63
- dark: colors.DN70
64
+ light: (0, _tokens.token)('color.background.disabled', colors.N20A),
65
+ dark: (0, _tokens.token)('color.background.disabled', colors.DN70)
64
66
  },
65
67
  selected: {
66
- light: colors.N700,
67
- dark: colors.DN0
68
+ light: (0, _tokens.token)('color.background.selected.resting', colors.N700),
69
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.DN0)
68
70
  },
69
71
  focusSelected: {
70
- light: colors.N700,
71
- dark: colors.DN0
72
+ light: (0, _tokens.token)('color.background.selected.resting', colors.N700),
73
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.DN0)
72
74
  }
73
75
  },
74
76
  warning: {
75
77
  default: {
76
- light: colors.Y300,
77
- dark: colors.Y300
78
+ light: (0, _tokens.token)('color.background.boldWarning.resting', colors.Y300),
79
+ dark: (0, _tokens.token)('color.background.boldWarning.resting', colors.Y300)
78
80
  },
79
81
  hover: {
80
- light: colors.Y200,
81
- dark: colors.Y200
82
+ light: (0, _tokens.token)('color.background.boldWarning.hover', colors.Y200),
83
+ dark: (0, _tokens.token)('color.background.boldWarning.hover', colors.Y200)
82
84
  },
83
85
  active: {
84
- light: colors.Y400,
85
- dark: colors.Y400
86
+ light: (0, _tokens.token)('color.background.boldWarning.pressed', colors.Y400),
87
+ dark: (0, _tokens.token)('color.background.boldWarning.pressed', colors.Y400)
86
88
  },
87
89
  disabled: {
88
- light: colors.N20A,
89
- dark: colors.DN70
90
+ light: (0, _tokens.token)('color.background.disabled', colors.N20A),
91
+ dark: (0, _tokens.token)('color.background.disabled', colors.DN70)
90
92
  },
91
93
  selected: {
92
- light: colors.Y400,
93
- dark: colors.Y400
94
+ light: (0, _tokens.token)('color.background.selected.resting', colors.Y400),
95
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.Y400)
94
96
  },
95
97
  focusSelected: {
96
- light: colors.Y400,
97
- dark: colors.Y400
98
+ light: (0, _tokens.token)('color.background.selected.resting', colors.Y400),
99
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.Y400)
98
100
  }
99
101
  },
100
102
  danger: {
101
103
  default: {
102
- light: colors.R400,
103
- dark: colors.R400
104
+ light: (0, _tokens.token)('color.background.boldDanger.resting', colors.R400),
105
+ dark: (0, _tokens.token)('color.background.boldDanger.resting', colors.R400)
104
106
  },
105
107
  hover: {
106
- light: colors.R300,
107
- dark: colors.R300
108
+ light: (0, _tokens.token)('color.background.boldDanger.hover', colors.R300),
109
+ dark: (0, _tokens.token)('color.background.boldDanger.hover', colors.R300)
108
110
  },
109
111
  active: {
110
- light: colors.R500,
111
- dark: colors.R500
112
+ light: (0, _tokens.token)('color.background.boldDanger.pressed', colors.R500),
113
+ dark: (0, _tokens.token)('color.background.boldDanger.pressed', colors.R500)
112
114
  },
113
115
  disabled: {
114
- light: colors.N20A,
115
- dark: colors.DN70
116
+ light: (0, _tokens.token)('color.background.disabled', colors.N20A),
117
+ dark: (0, _tokens.token)('color.background.disabled', colors.DN70)
116
118
  },
117
119
  selected: {
118
- light: colors.R500,
119
- dark: colors.R500
120
+ light: (0, _tokens.token)('color.background.selected.resting', colors.R500),
121
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.R500)
120
122
  },
121
123
  focusSelected: {
122
- light: colors.R500,
123
- dark: colors.R500
124
+ light: (0, _tokens.token)('color.background.selected.resting', colors.R500),
125
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.R500)
124
126
  }
125
127
  },
126
128
  link: {
@@ -129,12 +131,12 @@ var values = {
129
131
  dark: 'none'
130
132
  },
131
133
  selected: {
132
- light: colors.N700,
133
- dark: colors.N20
134
+ light: (0, _tokens.token)('color.background.selected.resting', colors.N700),
135
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.N20)
134
136
  },
135
137
  focusSelected: {
136
- light: colors.N700,
137
- dark: colors.N20
138
+ light: (0, _tokens.token)('color.background.selected.resting', colors.N700),
139
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.N20)
138
140
  }
139
141
  },
140
142
  subtle: {
@@ -143,24 +145,24 @@ var values = {
143
145
  dark: 'none'
144
146
  },
145
147
  hover: {
146
- light: colors.N30A,
147
- dark: colors.DN60
148
+ light: (0, _tokens.token)('color.background.transparentNeutral.hover', colors.N30A),
149
+ dark: (0, _tokens.token)('color.background.transparentNeutral.hover', colors.DN60)
148
150
  },
149
151
  active: {
150
- light: fadedB75,
151
- dark: colors.B75
152
+ light: (0, _tokens.token)('color.background.transparentNeutral.pressed', fadedB75),
153
+ dark: (0, _tokens.token)('color.background.transparentNeutral.pressed', colors.B75)
152
154
  },
153
155
  disabled: {
154
156
  light: 'none',
155
157
  dark: 'none'
156
158
  },
157
159
  selected: {
158
- light: colors.N700,
159
- dark: colors.DN0
160
+ light: (0, _tokens.token)('color.background.selected.resting', colors.N700),
161
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.DN0)
160
162
  },
161
163
  focusSelected: {
162
- light: colors.N700,
163
- dark: colors.DN0
164
+ light: (0, _tokens.token)('color.background.selected.resting', colors.N700),
165
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.DN0)
164
166
  }
165
167
  },
166
168
  'subtle-link': {
@@ -169,236 +171,236 @@ var values = {
169
171
  dark: 'none'
170
172
  },
171
173
  selected: {
172
- light: colors.N700,
173
- dark: colors.N20
174
+ light: (0, _tokens.token)('color.background.selected.resting', colors.N700),
175
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.N20)
174
176
  },
175
177
  focusSelected: {
176
- light: colors.N700,
177
- dark: colors.N20
178
+ light: (0, _tokens.token)('color.background.selected.resting', colors.N700),
179
+ dark: (0, _tokens.token)('color.background.selected.resting', colors.N20)
178
180
  }
179
181
  }
180
182
  },
181
183
  boxShadowColor: {
182
184
  default: {
183
185
  focus: {
184
- light: colors.B100,
185
- dark: colors.B75
186
+ light: (0, _tokens.token)('color.border.focus', colors.B100),
187
+ dark: (0, _tokens.token)('color.border.focus', colors.B75)
186
188
  },
187
189
  focusSelected: {
188
- light: colors.B100,
189
- dark: colors.B75
190
+ light: (0, _tokens.token)('color.border.focus', colors.B100),
191
+ dark: (0, _tokens.token)('color.border.focus', colors.B75)
190
192
  }
191
193
  },
192
194
  primary: {
193
195
  focus: {
194
- light: colors.B100,
195
- dark: colors.B75
196
+ light: (0, _tokens.token)('color.border.focus', colors.B100),
197
+ dark: (0, _tokens.token)('color.border.focus', colors.B75)
196
198
  },
197
199
  focusSelected: {
198
- light: colors.B100,
199
- dark: colors.B75
200
+ light: (0, _tokens.token)('color.border.focus', colors.B100),
201
+ dark: (0, _tokens.token)('color.border.focus', colors.B75)
200
202
  }
201
203
  },
202
204
  warning: {
203
205
  focus: {
204
- light: colors.Y500,
205
- dark: colors.Y500
206
+ light: (0, _tokens.token)('color.border.focus', colors.Y500),
207
+ dark: (0, _tokens.token)('color.border.focus', colors.Y500)
206
208
  },
207
209
  focusSelected: {
208
- light: colors.Y500,
209
- dark: colors.Y500
210
+ light: (0, _tokens.token)('color.border.focus', colors.Y500),
211
+ dark: (0, _tokens.token)('color.border.focus', colors.Y500)
210
212
  }
211
213
  },
212
214
  danger: {
213
215
  focus: {
214
- light: colors.R100,
215
- dark: colors.R100
216
+ light: (0, _tokens.token)('color.border.focus', colors.R100),
217
+ dark: (0, _tokens.token)('color.border.focus', colors.R100)
216
218
  },
217
219
  focusSelected: {
218
- light: colors.R100,
219
- dark: colors.R100
220
+ light: (0, _tokens.token)('color.border.focus', colors.R100),
221
+ dark: (0, _tokens.token)('color.border.focus', colors.R100)
220
222
  }
221
223
  },
222
224
  link: {
223
225
  focus: {
224
- light: colors.B100,
225
- dark: colors.B75
226
+ light: (0, _tokens.token)('color.border.focus', colors.B100),
227
+ dark: (0, _tokens.token)('color.border.focus', colors.B75)
226
228
  },
227
229
  focusSelected: {
228
- light: colors.B100,
229
- dark: colors.B75
230
+ light: (0, _tokens.token)('color.border.focus', colors.B100),
231
+ dark: (0, _tokens.token)('color.border.focus', colors.B75)
230
232
  }
231
233
  },
232
234
  subtle: {
233
235
  focus: {
234
- light: colors.B100,
235
- dark: colors.B75
236
+ light: (0, _tokens.token)('color.border.focus', colors.B100),
237
+ dark: (0, _tokens.token)('color.border.focus', colors.B75)
236
238
  },
237
239
  focusSelected: {
238
- light: colors.B100,
239
- dark: colors.B75
240
+ light: (0, _tokens.token)('color.border.focus', colors.B100),
241
+ dark: (0, _tokens.token)('color.border.focus', colors.B75)
240
242
  }
241
243
  },
242
244
  'subtle-link': {
243
245
  focus: {
244
- light: colors.B100,
245
- dark: colors.B75
246
+ light: (0, _tokens.token)('color.border.focus', colors.B100),
247
+ dark: (0, _tokens.token)('color.border.focus', colors.B75)
246
248
  },
247
249
  focusSelected: {
248
- light: colors.B100,
249
- dark: colors.B75
250
+ light: (0, _tokens.token)('color.border.focus', colors.B100),
251
+ dark: (0, _tokens.token)('color.border.focus', colors.B75)
250
252
  }
251
253
  }
252
254
  },
253
255
  color: {
254
256
  default: {
255
257
  default: {
256
- light: colors.N500,
257
- dark: colors.DN400
258
+ light: (0, _tokens.token)('color.text.highEmphasis', colors.N500),
259
+ dark: (0, _tokens.token)('color.text.highEmphasis', colors.DN400)
258
260
  },
259
261
  active: {
260
- light: colors.B400,
261
- dark: colors.B400
262
+ light: (0, _tokens.token)('color.text.highEmphasis', colors.B400),
263
+ dark: (0, _tokens.token)('color.text.highEmphasis', colors.B400)
262
264
  },
263
265
  disabled: {
264
- light: colors.N70,
265
- dark: colors.DN30
266
+ light: (0, _tokens.token)('color.text.disabled', colors.N70),
267
+ dark: (0, _tokens.token)('color.text.disabled', colors.DN30)
266
268
  },
267
269
  selected: {
268
- light: colors.N20,
269
- dark: colors.DN400
270
+ light: (0, _tokens.token)('color.text.selected', colors.N20),
271
+ dark: (0, _tokens.token)('color.text.selected', colors.DN400)
270
272
  },
271
273
  focusSelected: {
272
- light: colors.N20,
273
- dark: colors.DN400
274
+ light: (0, _tokens.token)('color.text.selected', colors.N20),
275
+ dark: (0, _tokens.token)('color.text.selected', colors.DN400)
274
276
  }
275
277
  },
276
278
  primary: {
277
279
  default: {
278
- light: colors.N0,
279
- dark: colors.DN30
280
+ light: (0, _tokens.token)('color.text.onBold', colors.N0),
281
+ dark: (0, _tokens.token)('color.text.onBold', colors.DN30)
280
282
  },
281
283
  disabled: {
282
- light: colors.N70,
283
- dark: colors.DN30
284
+ light: (0, _tokens.token)('color.text.disabled', colors.N70),
285
+ dark: (0, _tokens.token)('color.text.disabled', colors.DN30)
284
286
  },
285
287
  selected: {
286
- light: colors.N20,
287
- dark: colors.DN400
288
+ light: (0, _tokens.token)('color.text.selected', colors.N20),
289
+ dark: (0, _tokens.token)('color.text.selected', colors.DN400)
288
290
  },
289
291
  focusSelected: {
290
- light: colors.N20,
291
- dark: colors.DN400
292
+ light: (0, _tokens.token)('color.text.selected', colors.N20),
293
+ dark: (0, _tokens.token)('color.text.selected', colors.DN400)
292
294
  }
293
295
  },
294
296
  warning: {
295
297
  default: {
296
- light: colors.N800,
297
- dark: colors.N800
298
+ light: (0, _tokens.token)('color.text.onBoldWarning', colors.N800),
299
+ dark: (0, _tokens.token)('color.text.onBoldWarning', colors.N800)
298
300
  },
299
301
  disabled: {
300
- light: colors.N70,
301
- dark: colors.DN30
302
+ light: (0, _tokens.token)('color.text.disabled', colors.N70),
303
+ dark: (0, _tokens.token)('color.text.disabled', colors.DN30)
302
304
  },
303
305
  selected: {
304
- light: colors.N800,
305
- dark: colors.N800
306
+ light: (0, _tokens.token)('color.text.selected', colors.N800),
307
+ dark: (0, _tokens.token)('color.text.selected', colors.N800)
306
308
  },
307
309
  focusSelected: {
308
- light: colors.N800,
309
- dark: colors.N800
310
+ light: (0, _tokens.token)('color.text.selected', colors.N800),
311
+ dark: (0, _tokens.token)('color.text.selected', colors.N800)
310
312
  }
311
313
  },
312
314
  danger: {
313
315
  default: {
314
- light: colors.N0,
315
- dark: colors.N0
316
+ light: (0, _tokens.token)('color.text.onBold', colors.N0),
317
+ dark: (0, _tokens.token)('color.text.onBold', colors.N0)
316
318
  },
317
319
  disabled: {
318
- light: colors.N70,
319
- dark: colors.DN30
320
+ light: (0, _tokens.token)('color.text.disabled', colors.N70),
321
+ dark: (0, _tokens.token)('color.text.disabled', colors.DN30)
320
322
  },
321
323
  selected: {
322
- light: colors.N0,
323
- dark: colors.N0
324
+ light: (0, _tokens.token)('color.text.selected', colors.N0),
325
+ dark: (0, _tokens.token)('color.text.selected', colors.N0)
324
326
  },
325
327
  focusSelected: {
326
- light: colors.N0,
327
- dark: colors.N0
328
+ light: (0, _tokens.token)('color.text.selected', colors.N0),
329
+ dark: (0, _tokens.token)('color.text.selected', colors.N0)
328
330
  }
329
331
  },
330
332
  link: {
331
333
  default: {
332
- light: colors.B400,
333
- dark: colors.B100
334
+ light: (0, _tokens.token)('color.text.link.resting', colors.B400),
335
+ dark: (0, _tokens.token)('color.text.link.resting', colors.B100)
334
336
  },
335
337
  hover: {
336
- light: colors.B300,
337
- dark: colors.B75
338
+ light: (0, _tokens.token)('color.text.link.resting', colors.B300),
339
+ dark: (0, _tokens.token)('color.text.link.resting', colors.B75)
338
340
  },
339
341
  active: {
340
- light: colors.B500,
341
- dark: colors.B200
342
+ light: (0, _tokens.token)('color.text.link.pressed', colors.B500),
343
+ dark: (0, _tokens.token)('color.text.link.pressed', colors.B200)
342
344
  },
343
345
  disabled: {
344
- light: colors.N70,
345
- dark: colors.DN100
346
+ light: (0, _tokens.token)('color.text.disabled', colors.N70),
347
+ dark: (0, _tokens.token)('color.text.disabled', colors.DN100)
346
348
  },
347
349
  selected: {
348
- light: colors.N20,
349
- dark: colors.N700
350
+ light: (0, _tokens.token)('color.text.selected', colors.N20),
351
+ dark: (0, _tokens.token)('color.text.selected', colors.N700)
350
352
  },
351
353
  focusSelected: {
352
- light: colors.N20,
353
- dark: colors.N700
354
+ light: (0, _tokens.token)('color.text.selected', colors.N20),
355
+ dark: (0, _tokens.token)('color.text.selected', colors.N700)
354
356
  }
355
357
  },
356
358
  subtle: {
357
359
  default: {
358
- light: colors.N500,
359
- dark: colors.DN400
360
+ light: (0, _tokens.token)('color.text.highEmphasis', colors.N500),
361
+ dark: (0, _tokens.token)('color.text.highEmphasis', colors.DN400)
360
362
  },
361
363
  active: {
362
- light: colors.B400,
363
- dark: colors.B400
364
+ light: (0, _tokens.token)('color.text.highEmphasis', colors.B400),
365
+ dark: (0, _tokens.token)('color.text.highEmphasis', colors.B400)
364
366
  },
365
367
  disabled: {
366
- light: colors.N70,
367
- dark: colors.DN100
368
+ light: (0, _tokens.token)('color.text.disabled', colors.N70),
369
+ dark: (0, _tokens.token)('color.text.disabled', colors.DN100)
368
370
  },
369
371
  selected: {
370
- light: colors.N20,
371
- dark: colors.DN400
372
+ light: (0, _tokens.token)('color.text.selected', colors.N20),
373
+ dark: (0, _tokens.token)('color.text.selected', colors.DN400)
372
374
  },
373
375
  focusSelected: {
374
- light: colors.N20,
375
- dark: colors.DN400
376
+ light: (0, _tokens.token)('color.text.selected', colors.N20),
377
+ dark: (0, _tokens.token)('color.text.selected', colors.DN400)
376
378
  }
377
379
  },
378
380
  'subtle-link': {
379
381
  default: {
380
- light: colors.N200,
381
- dark: colors.DN400
382
+ light: (0, _tokens.token)('color.text.mediumEmphasis', colors.N200),
383
+ dark: (0, _tokens.token)('color.text.mediumEmphasis', colors.DN400)
382
384
  },
383
385
  hover: {
384
- light: colors.N90,
385
- dark: colors.B50
386
+ light: (0, _tokens.token)('color.text.mediumEmphasis', colors.N90),
387
+ dark: (0, _tokens.token)('color.text.mediumEmphasis', colors.B50)
386
388
  },
387
389
  active: {
388
- light: colors.N400,
389
- dark: colors.DN300
390
+ light: (0, _tokens.token)('color.text.highEmphasis', colors.N400),
391
+ dark: (0, _tokens.token)('color.text.highEmphasis', colors.DN300)
390
392
  },
391
393
  disabled: {
392
- light: colors.N70,
393
- dark: colors.DN100
394
+ light: (0, _tokens.token)('color.text.disabled', colors.N70),
395
+ dark: (0, _tokens.token)('color.text.disabled', colors.DN100)
394
396
  },
395
397
  selected: {
396
- light: colors.N20,
397
- dark: colors.DN400
398
+ light: (0, _tokens.token)('color.text.selected', colors.N20),
399
+ dark: (0, _tokens.token)('color.text.selected', colors.DN400)
398
400
  },
399
401
  focusSelected: {
400
- light: colors.N20,
401
- dark: colors.DN400
402
+ light: (0, _tokens.token)('color.text.selected', colors.N20),
403
+ dark: (0, _tokens.token)('color.text.selected', colors.DN400)
402
404
  }
403
405
  }
404
406
  }
@@ -182,7 +182,7 @@ function getCss(_ref3) {
182
182
  // Giving disabled styles preference over active by listing them after.
183
183
  // Not using '&:disabled' because :disabled is not a valid state for all element types
184
184
  // so we are targeting the attribute
185
- // Attributes have the same specificity a pesudo classes so we are overriding :disabled here
185
+ // Attributes have the same specificity a pseudo classes so we are overriding :disabled here
186
186
  '&[disabled]': _objectSpread(_objectSpread({}, getColors({
187
187
  appearance: appearance,
188
188
  key: 'disabled',
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/button",
3
- "version": "16.0.0",
3
+ "version": "16.1.3",
4
4
  "sideEffects": false
5
5
  }
@@ -8,7 +8,7 @@ const stateToSelectorMap = {
8
8
  disabled: '&[disabled]'
9
9
  }; // Mapping the new clean css back to the legacy theme format.
10
10
  // The legacy theme format has all styles at the top level (no nested selectors)
11
- // and uses `getSpecifiers()` to apply the style to all psudeo states
11
+ // and uses `getSpecifiers()` to apply the style to all pseudo states
12
12
 
13
13
  export function getCustomCss({
14
14
  appearance = 'default',
@@ -28,7 +28,7 @@ export function getCustomCss({
28
28
  shouldFitContainer,
29
29
  isOnlySingleIcon: iconIsOnlyChild
30
30
  }); // we need to disable the default browser focus styles always
31
- // this is because we are not expressing that we can have two pesduo states at a time
31
+ // this is because we are not expressing that we can have two pseudo states at a time
32
32
 
33
33
  result.outline = 'none'; // Pulling relevant styles up to the top level
34
34
 
@@ -61,7 +61,7 @@ export function getCustomCss({
61
61
  });
62
62
  return result;
63
63
  } // This styling approach works by generating a 'style' and applying with maximum specificity
64
- // To do this we are overwriting all psuedo selectors
64
+ // To do this we are overwriting all pseudo selectors
65
65
 
66
66
  export function getSpecifiers(styles) {
67
67
  return {
@@ -5,6 +5,8 @@ import React, { useCallback, useEffect, useRef } from 'react';
5
5
  import { jsx } from '@emotion/core';
6
6
  import { usePlatformLeafEventHandler } from '@atlaskit/analytics-next';
7
7
  import useAutoFocus from '@atlaskit/ds-lib/use-auto-focus';
8
+ import { N500 } from '@atlaskit/theme/colors';
9
+ import { token } from '@atlaskit/tokens';
8
10
  import blockEvents from './block-events';
9
11
  import { getContentStyle, getFadingCss, getIconStyle, overlayCss } from './css';
10
12
 
@@ -69,7 +71,7 @@ export default /*#__PURE__*/React.forwardRef(function ButtonBase(props, ref) {
69
71
  action: 'clicked',
70
72
  componentName: 'button',
71
73
  packageName: "@atlaskit/button",
72
- packageVersion: "16.0.0",
74
+ packageVersion: "16.1.3",
73
75
  analyticsData: analyticsContext
74
76
  }); // Button currently calls preventDefault, which is not standard button behaviour
75
77
 
@@ -91,6 +93,21 @@ export default /*#__PURE__*/React.forwardRef(function ButtonBase(props, ref) {
91
93
  hasOverlay
92
94
  });
93
95
  const isInteractive = !isDisabled && !hasOverlay;
96
+ /** HACK: Spinner needs to have different colours in the "new" tokens design compared to the old design.
97
+ * For now, while we support both, these styles reach into Spinner when a theme is set, applies the right color.
98
+ * Ticket to remove: https://product-fabric.atlassian.net/browse/DSP-2067
99
+ */
100
+
101
+ var spinnerHackCss = {};
102
+
103
+ if (isSelected || isDisabled || appearance === 'warning') {
104
+ spinnerHackCss = {
105
+ '[data-theme] & svg': {
106
+ stroke: isSelected || isDisabled ? token('color.text.mediumEmphasis', N500) : token('color.text.onBoldWarning', N500)
107
+ }
108
+ };
109
+ }
110
+
94
111
  return jsx(Component, _extends({}, rest, {
95
112
  css: [buttonCss, isInteractive ? null : noPointerEventsOnChildrenCss],
96
113
  className: className,
@@ -122,6 +139,6 @@ export default /*#__PURE__*/React.forwardRef(function ButtonBase(props, ref) {
122
139
  spacing
123
140
  })]
124
141
  }, iconAfter) : null, overlay ? jsx("span", {
125
- css: overlayCss
142
+ css: [overlayCss, spinnerHackCss]
126
143
  }, overlay) : null);
127
144
  });