@atlaskit/tooltip 17.8.6 → 17.8.8

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.
package/CHANGELOG.md CHANGED
@@ -1,47 +1,59 @@
1
1
  # @atlaskit/tooltip
2
2
 
3
+ ## 17.8.8
4
+
5
+ ### Patch Changes
6
+
7
+ - [#40650](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/40650) [`07aa588c8a4`](https://bitbucket.org/atlassian/atlassian-frontend/commits/07aa588c8a4) - Reverts the fix to text descender cut-off, due to incompatibilities with Firefox and Safari.
8
+
9
+ ## 17.8.7
10
+
11
+ ### Patch Changes
12
+
13
+ - [#40904](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/40904) [`f5731d7c0ca`](https://bitbucket.org/atlassian/atlassian-frontend/commits/f5731d7c0ca) - Improve the performance of the tooltip trigger's ref setter function by ensuring the `useCallback` only regenerates a new reference when absolutely needed (rather than on every render).
14
+
3
15
  ## 17.8.6
4
16
 
5
17
  ### Patch Changes
6
18
 
7
- - [`fd6bb9c9184`](https://bitbucket.org/atlassian/atlassian-frontend/commits/fd6bb9c9184) - Delete version.json
19
+ - [#38162](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/38162) [`fd6bb9c9184`](https://bitbucket.org/atlassian/atlassian-frontend/commits/fd6bb9c9184) - Delete version.json
8
20
  - Updated dependencies
9
21
 
10
22
  ## 17.8.5
11
23
 
12
24
  ### Patch Changes
13
25
 
14
- - [`56b444b56a8`](https://bitbucket.org/atlassian/atlassian-frontend/commits/56b444b56a8) - Fix a bug where text descenders were cut off at high zoom levels on Windows
26
+ - [#38209](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/38209) [`56b444b56a8`](https://bitbucket.org/atlassian/atlassian-frontend/commits/56b444b56a8) - Fix a bug where text descenders were cut off at high zoom levels on Windows
15
27
 
16
28
  ## 17.8.4
17
29
 
18
30
  ### Patch Changes
19
31
 
20
- - [`4ae083a7e66`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4ae083a7e66) - Use `@af/accessibility-testing` for default jest-axe config and jest-axe import in accessibility testing.
32
+ - [#36754](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/36754) [`4ae083a7e66`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4ae083a7e66) - Use `@af/accessibility-testing` for default jest-axe config and jest-axe import in accessibility testing.
21
33
 
22
34
  ## 17.8.3
23
35
 
24
36
  ### Patch Changes
25
37
 
26
- - [`599bfe90ee3`](https://bitbucket.org/atlassian/atlassian-frontend/commits/599bfe90ee3) - Internal change to use shape tokens. There is no expected visual change.
38
+ - [#35441](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/35441) [`599bfe90ee3`](https://bitbucket.org/atlassian/atlassian-frontend/commits/599bfe90ee3) - Internal change to use shape tokens. There is no expected visual change.
27
39
 
28
40
  ## 17.8.2
29
41
 
30
42
  ### Patch Changes
31
43
 
32
- - [`9d00501a414`](https://bitbucket.org/atlassian/atlassian-frontend/commits/9d00501a414) - Ensure legacy types are published for TS 4.5-4.8
44
+ - [#33793](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33793) [`9d00501a414`](https://bitbucket.org/atlassian/atlassian-frontend/commits/9d00501a414) - Ensure legacy types are published for TS 4.5-4.8
33
45
 
34
46
  ## 17.8.1
35
47
 
36
48
  ### Patch Changes
37
49
 
38
- - [`41fae2c6f68`](https://bitbucket.org/atlassian/atlassian-frontend/commits/41fae2c6f68) - Upgrade Typescript from `4.5.5` to `4.9.5`
50
+ - [#33649](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33649) [`41fae2c6f68`](https://bitbucket.org/atlassian/atlassian-frontend/commits/41fae2c6f68) - Upgrade Typescript from `4.5.5` to `4.9.5`
39
51
 
40
52
  ## 17.8.0
41
53
 
42
54
  ### Minor Changes
43
55
 
44
- - [`56507598609`](https://bitbucket.org/atlassian/atlassian-frontend/commits/56507598609) - Skip minor dependency bump
56
+ - [#33258](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/33258) [`56507598609`](https://bitbucket.org/atlassian/atlassian-frontend/commits/56507598609) - Skip minor dependency bump
45
57
 
46
58
  ### Patch Changes
47
59
 
@@ -51,19 +63,19 @@
51
63
 
52
64
  ### Patch Changes
53
65
 
54
- - [`4ba10567310`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4ba10567310) - Internal changes.
66
+ - [#32211](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/32211) [`4ba10567310`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4ba10567310) - Internal changes.
55
67
 
56
68
  ## 17.7.0
57
69
 
58
70
  ### Minor Changes
59
71
 
60
- - [`03114fe5942`](https://bitbucket.org/atlassian/atlassian-frontend/commits/03114fe5942) - [ux] Ensures tooltips are read correctly on screen readers.
72
+ - [#30248](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/30248) [`03114fe5942`](https://bitbucket.org/atlassian/atlassian-frontend/commits/03114fe5942) - [ux] Ensures tooltips are read correctly on screen readers.
61
73
 
62
74
  ## 17.6.9
63
75
 
64
76
  ### Patch Changes
65
77
 
66
- - [`6cb57eb428d`](https://bitbucket.org/atlassian/atlassian-frontend/commits/6cb57eb428d) - Update examples for Tooltip to use render props API to aid in eventual deprecation of wrapping children.
78
+ - [#29470](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/29470) [`6cb57eb428d`](https://bitbucket.org/atlassian/atlassian-frontend/commits/6cb57eb428d) - Update examples for Tooltip to use render props API to aid in eventual deprecation of wrapping children.
67
79
  - Updated dependencies
68
80
 
69
81
  ## 17.6.8
@@ -76,13 +88,13 @@
76
88
 
77
89
  ### Patch Changes
78
90
 
79
- - [`18aeca8c199`](https://bitbucket.org/atlassian/atlassian-frontend/commits/18aeca8c199) - Internal change to update token references. There is no expected behaviour or visual change.
91
+ - [#29390](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/29390) [`18aeca8c199`](https://bitbucket.org/atlassian/atlassian-frontend/commits/18aeca8c199) - Internal change to update token references. There is no expected behaviour or visual change.
80
92
 
81
93
  ## 17.6.6
82
94
 
83
95
  ### Patch Changes
84
96
 
85
- - [`4ee60bafc6d`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4ee60bafc6d) - ED-16603: Remove tooltips from VR tests and make them opt in. To opt-in, add `allowedSideEffects` when loading the page.
97
+ - [#29227](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/29227) [`4ee60bafc6d`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4ee60bafc6d) - ED-16603: Remove tooltips from VR tests and make them opt in. To opt-in, add `allowedSideEffects` when loading the page.
86
98
 
87
99
  ## 17.6.5
88
100
 
@@ -100,7 +112,7 @@
100
112
 
101
113
  ### Patch Changes
102
114
 
103
- - [`4fd77eaf22b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4fd77eaf22b) - Align TriggerProps with the actual output, and make data-testid explicit
115
+ - [#27313](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/27313) [`4fd77eaf22b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4fd77eaf22b) - Align TriggerProps with the actual output, and make data-testid explicit
104
116
 
105
117
  ## 17.6.2
106
118
 
@@ -112,44 +124,44 @@
112
124
 
113
125
  ### Patch Changes
114
126
 
115
- - [`9827dcb82b8`](https://bitbucket.org/atlassian/atlassian-frontend/commits/9827dcb82b8) - No-op change to introduce spacing tokens to design system components.
127
+ - [#26303](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/26303) [`9827dcb82b8`](https://bitbucket.org/atlassian/atlassian-frontend/commits/9827dcb82b8) - No-op change to introduce spacing tokens to design system components.
116
128
 
117
129
  ## 17.6.0
118
130
 
119
131
  ### Minor Changes
120
132
 
121
- - [`15f0ad7aaa3`](https://bitbucket.org/atlassian/atlassian-frontend/commits/15f0ad7aaa3) - Updates `@emotion/core` to `@emotion/react`; v10 to v11. There is no expected behavior change.
133
+ - [#24710](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/24710) [`15f0ad7aaa3`](https://bitbucket.org/atlassian/atlassian-frontend/commits/15f0ad7aaa3) - Updates `@emotion/core` to `@emotion/react`; v10 to v11. There is no expected behavior change.
122
134
 
123
135
  ## 17.5.17
124
136
 
125
137
  ### Patch Changes
126
138
 
127
- - [`8cc2f888c83`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8cc2f888c83) - Upgrade Typescript from `4.3.5` to `4.5.5`
139
+ - [#24874](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/24874) [`8cc2f888c83`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8cc2f888c83) - Upgrade Typescript from `4.3.5` to `4.5.5`
128
140
 
129
141
  ## 17.5.16
130
142
 
131
143
  ### Patch Changes
132
144
 
133
- - [`8d4228767b0`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8d4228767b0) - Upgrade Typescript from `4.2.4` to `4.3.5`.
145
+ - [#24492](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/24492) [`8d4228767b0`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8d4228767b0) - Upgrade Typescript from `4.2.4` to `4.3.5`.
134
146
 
135
147
  ## 17.5.15
136
148
 
137
149
  ### Patch Changes
138
150
 
139
- - [`338ba1a1500`](https://bitbucket.org/atlassian/atlassian-frontend/commits/338ba1a1500) - [ux] Improves accuracy of Tooltip placement relative to the mouse when using `position="mouse"`
151
+ - [#22691](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/22691) [`338ba1a1500`](https://bitbucket.org/atlassian/atlassian-frontend/commits/338ba1a1500) - [ux] Improves accuracy of Tooltip placement relative to the mouse when using `position="mouse"`
140
152
 
141
153
  ## 17.5.14
142
154
 
143
155
  ### Patch Changes
144
156
 
145
- - [`13a202fde6b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/13a202fde6b) - Fixes a bug where undefined test IDs were being added to Tooltip wrappers when no test ID was set
157
+ - [#23381](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/23381) [`13a202fde6b`](https://bitbucket.org/atlassian/atlassian-frontend/commits/13a202fde6b) - Fixes a bug where undefined test IDs were being added to Tooltip wrappers when no test ID was set
146
158
  - Updated dependencies
147
159
 
148
160
  ## 17.5.13
149
161
 
150
162
  ### Patch Changes
151
163
 
152
- - [`45ebe7af434`](https://bitbucket.org/atlassian/atlassian-frontend/commits/45ebe7af434) - Moved to using declarative entrypoints internally. Public API is unchanged.
164
+ - [#22642](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/22642) [`45ebe7af434`](https://bitbucket.org/atlassian/atlassian-frontend/commits/45ebe7af434) - Moved to using declarative entrypoints internally. Public API is unchanged.
153
165
  - [`4efc76f8a72`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4efc76f8a72) - [ux] Fixes a bug where tooltip entrance and exit direction animations were not working since version 12.1.7, after upgrading `react-popper`.
154
166
 
155
167
  This involved adding a wrapper `<div>` around the tooltip to separate the positioning and animation styles. The wrapper can be identified in tests using `testId` with the pattern `{testId}--wrapper`.
@@ -160,7 +172,7 @@
160
172
 
161
173
  ### Patch Changes
162
174
 
163
- - [`8a5bdb3c844`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8a5bdb3c844) - Upgrading internal dependency (bind-event-listener) for improved internal types
175
+ - [#22614](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/22614) [`8a5bdb3c844`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8a5bdb3c844) - Upgrading internal dependency (bind-event-listener) for improved internal types
164
176
 
165
177
  ## 17.5.11
166
178
 
@@ -178,13 +190,13 @@
178
190
 
179
191
  ### Patch Changes
180
192
 
181
- - [`2e7bbdfd813`](https://bitbucket.org/atlassian/atlassian-frontend/commits/2e7bbdfd813) - Upgrading internal dependency 'bind-event-listener' to 2.1.0 for improved types
193
+ - [#21242](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/21242) [`2e7bbdfd813`](https://bitbucket.org/atlassian/atlassian-frontend/commits/2e7bbdfd813) - Upgrading internal dependency 'bind-event-listener' to 2.1.0 for improved types
182
194
 
183
195
  ## 17.5.8
184
196
 
185
197
  ### Patch Changes
186
198
 
187
- - [`cb2392f6d33`](https://bitbucket.org/atlassian/atlassian-frontend/commits/cb2392f6d33) - Upgrade to TypeScript 4.2.4
199
+ - [#20650](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/20650) [`cb2392f6d33`](https://bitbucket.org/atlassian/atlassian-frontend/commits/cb2392f6d33) - Upgrade to TypeScript 4.2.4
188
200
 
189
201
  ## 17.5.7
190
202
 
@@ -202,7 +214,7 @@
202
214
 
203
215
  ### Patch Changes
204
216
 
205
- - [`d0eed99c3e3`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d0eed99c3e3) - ED-14264 Moved styles to emotion css
217
+ - [#19019](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/19019) [`d0eed99c3e3`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d0eed99c3e3) - ED-14264 Moved styles to emotion css
206
218
  - [`6007e4f9a97`](https://bitbucket.org/atlassian/atlassian-frontend/commits/6007e4f9a97) - Internal styling has been refactored in preparation for @compiled/react
207
219
  - Updated dependencies
208
220
 
@@ -210,7 +222,7 @@
210
222
 
211
223
  ### Patch Changes
212
224
 
213
- - [`19d72473dfb`](https://bitbucket.org/atlassian/atlassian-frontend/commits/19d72473dfb) - The no-unsafe-design-token-usage eslint rule now respects the new token naming conventions when auto-fixing by correctly formatting token ids.
225
+ - [#16752](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/16752) [`19d72473dfb`](https://bitbucket.org/atlassian/atlassian-frontend/commits/19d72473dfb) - The no-unsafe-design-token-usage eslint rule now respects the new token naming conventions when auto-fixing by correctly formatting token ids.
214
226
  - Updated dependencies
215
227
 
216
228
  ## 17.5.3
@@ -223,7 +235,7 @@
223
235
 
224
236
  ### Patch Changes
225
237
 
226
- - [`f460cc7c411`](https://bitbucket.org/atlassian/atlassian-frontend/commits/f460cc7c411) - Builds for this package now pass through a tokens babel plugin, removing runtime invocations of the tokens() function and improving bundle size.
238
+ - [#15998](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/15998) [`f460cc7c411`](https://bitbucket.org/atlassian/atlassian-frontend/commits/f460cc7c411) - Builds for this package now pass through a tokens babel plugin, removing runtime invocations of the tokens() function and improving bundle size.
227
239
  - Updated dependencies
228
240
 
229
241
  ## 17.5.1
@@ -236,7 +248,7 @@
236
248
 
237
249
  ### Minor Changes
238
250
 
239
- - [`cf853e39278`](https://bitbucket.org/atlassian/atlassian-frontend/commits/cf853e39278) - Added the render props support to the Tooltip component. Linked the tooltip text to the trigger using aria-describedby for users with assistive technologies.
251
+ - [#14319](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/14319) [`cf853e39278`](https://bitbucket.org/atlassian/atlassian-frontend/commits/cf853e39278) - Added the render props support to the Tooltip component. Linked the tooltip text to the trigger using aria-describedby for users with assistive technologies.
240
252
 
241
253
  ### Patch Changes
242
254
 
@@ -252,7 +264,7 @@
252
264
 
253
265
  ### Minor Changes
254
266
 
255
- - [`45e06ed2420`](https://bitbucket.org/atlassian/atlassian-frontend/commits/45e06ed2420) - Instrumented Tooltip with the new theming package, `@atlaskit/tokens`.
267
+ - [#13302](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/13302) [`45e06ed2420`](https://bitbucket.org/atlassian/atlassian-frontend/commits/45e06ed2420) - Instrumented Tooltip with the new theming package, `@atlaskit/tokens`.
256
268
  Tokens will be visible only in applications configured to use the new Tokens API (currently in alpha).
257
269
  These changes are intended to be interoperable with the legacy theme implementation. Legacy dark mode users should expect no visual or breaking changes.
258
270
 
@@ -264,13 +276,13 @@
264
276
 
265
277
  ### Patch Changes
266
278
 
267
- - [`378d1cef00f`](https://bitbucket.org/atlassian/atlassian-frontend/commits/378d1cef00f) - Bump `@atlaskit/theme` to version `^11.3.0`.
279
+ - [#12880](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/12880) [`378d1cef00f`](https://bitbucket.org/atlassian/atlassian-frontend/commits/378d1cef00f) - Bump `@atlaskit/theme` to version `^11.3.0`.
268
280
 
269
281
  ## 17.3.0
270
282
 
271
283
  ### Minor Changes
272
284
 
273
- - [`152d0955271`](https://bitbucket.org/atlassian/atlassian-frontend/commits/152d0955271) - Impelemented hiding the tooltip when escape pressed
285
+ - [#12328](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/12328) [`152d0955271`](https://bitbucket.org/atlassian/atlassian-frontend/commits/152d0955271) - Impelemented hiding the tooltip when escape pressed
274
286
  - [`a5d452bcb30`](https://bitbucket.org/atlassian/atlassian-frontend/commits/a5d452bcb30) - [ux] Tooltip now stays visible when hovering over it, previously it would disappear. This is one of the many accessibility improvements we're rolling out to the Atlassian Design System.
275
287
 
276
288
  ### Patch Changes
@@ -281,7 +293,7 @@
281
293
 
282
294
  ### Patch Changes
283
295
 
284
- - [`d6f7ff383cf`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d6f7ff383cf) - Updates to development dependency `storybook-addon-performance`
296
+ - [#12167](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/12167) [`d6f7ff383cf`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d6f7ff383cf) - Updates to development dependency `storybook-addon-performance`
285
297
 
286
298
  ## 17.2.1
287
299
 
@@ -293,7 +305,7 @@
293
305
 
294
306
  ### Minor Changes
295
307
 
296
- - [`8386261266c`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8386261266c) - Tooltip `content` now supports an optional render props API.
308
+ - [#9083](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/9083) [`8386261266c`](https://bitbucket.org/atlassian/atlassian-frontend/commits/8386261266c) - Tooltip `content` now supports an optional render props API.
297
309
  This API provides an `update` function which can be called to manually recalculate the position of the tooltip.
298
310
 
299
311
  This `update` function is useful if you are changing the content of the tooltip while it is being displayed.
@@ -308,19 +320,19 @@
308
320
 
309
321
  ### Patch Changes
310
322
 
311
- - [`79c23df6340`](https://bitbucket.org/atlassian/atlassian-frontend/commits/79c23df6340) - Use injected package name and version for analytics instead of version.json.
323
+ - [#8644](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/8644) [`79c23df6340`](https://bitbucket.org/atlassian/atlassian-frontend/commits/79c23df6340) - Use injected package name and version for analytics instead of version.json.
312
324
 
313
325
  ## 17.1.2
314
326
 
315
327
  ### Patch Changes
316
328
 
317
- - [`d3265f19be`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d3265f19be) - Transpile packages using babel rather than tsc
329
+ - [#5857](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/5857) [`d3265f19be`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d3265f19be) - Transpile packages using babel rather than tsc
318
330
 
319
331
  ## 17.1.1
320
332
 
321
333
  ### Patch Changes
322
334
 
323
- - [`d36905cfe9`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d36905cfe9) - Fixed incorrect function signature for onShow and onHide props, and added improved typing for these props.
335
+ - [#5693](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/5693) [`d36905cfe9`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d36905cfe9) - Fixed incorrect function signature for onShow and onHide props, and added improved typing for these props.
324
336
 
325
337
  - **old:** analyticsEvent was the first argument
326
338
  - **change:** analyticsEvent became the second argument unintentionally (bug introduced 17.0.0)
@@ -334,13 +346,13 @@
334
346
 
335
347
  ### Minor Changes
336
348
 
337
- - [`4a9b4d8808`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4a9b4d8808) - DS-7523 Extends Tooltip to accept strategy as prop
349
+ - [#5516](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/5516) [`4a9b4d8808`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4a9b4d8808) - DS-7523 Extends Tooltip to accept strategy as prop
338
350
 
339
351
  ## 17.0.3
340
352
 
341
353
  ### Patch Changes
342
354
 
343
- - [`5f58283e1f`](https://bitbucket.org/atlassian/atlassian-frontend/commits/5f58283e1f) - Export types using Typescript's new "export type" syntax to satisfy Typescript's --isolatedModules compiler option.
355
+ - [#5497](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/5497) [`5f58283e1f`](https://bitbucket.org/atlassian/atlassian-frontend/commits/5f58283e1f) - Export types using Typescript's new "export type" syntax to satisfy Typescript's --isolatedModules compiler option.
344
356
  This requires version 3.8 of Typescript, read more about how we handle Typescript versions here: https://atlaskit.atlassian.com/get-started
345
357
  Also add `typescript` to `devDependencies` to denote version that the package was built with.
346
358
 
@@ -354,13 +366,13 @@
354
366
 
355
367
  ### Patch Changes
356
368
 
357
- - [`18f7ccbbfc`](https://bitbucket.org/atlassian/atlassian-frontend/commits/18f7ccbbfc) - Fixing tooltip prop documentation
369
+ - [#4853](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/4853) [`18f7ccbbfc`](https://bitbucket.org/atlassian/atlassian-frontend/commits/18f7ccbbfc) - Fixing tooltip prop documentation
358
370
 
359
371
  ## 17.0.0
360
372
 
361
373
  ### Major Changes
362
374
 
363
- - [`83586f015e`](https://bitbucket.org/atlassian/atlassian-frontend/commits/83586f015e) - Tooltip has been refactored to improve performance and be compliant with the lite-mode specification.
375
+ - [#4424](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/4424) [`83586f015e`](https://bitbucket.org/atlassian/atlassian-frontend/commits/83586f015e) - Tooltip has been refactored to improve performance and be compliant with the lite-mode specification.
364
376
 
365
377
  - Removed `react-transition-group` in favor of `@atlaskit/motion` to reduce bundle size
366
378
  - Removed `react-node-resolver` because of its use of `React.findDOMNode` which has been marked as deprecated by the React team (more below...)
@@ -384,7 +396,7 @@
384
396
 
385
397
  ### Patch Changes
386
398
 
387
- - [`6c525a8229`](https://bitbucket.org/atlassian/atlassian-frontend/commits/6c525a8229) - Upgraded to TypeScript 3.9.6 and tslib to 2.0.0
399
+ - [#3885](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/3885) [`6c525a8229`](https://bitbucket.org/atlassian/atlassian-frontend/commits/6c525a8229) - Upgraded to TypeScript 3.9.6 and tslib to 2.0.0
388
400
 
389
401
  Since tslib is a dependency for all our packages we recommend that products also follow this tslib upgrade
390
402
  to prevent duplicates of tslib being bundled.
@@ -399,19 +411,19 @@
399
411
 
400
412
  ### Patch Changes
401
413
 
402
- - [`954cc87b62`](https://bitbucket.org/atlassian/atlassian-frontend/commits/954cc87b62) - The readme and package information has been updated to point to the new design system website.
414
+ - [#3293](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/3293) [`954cc87b62`](https://bitbucket.org/atlassian/atlassian-frontend/commits/954cc87b62) - The readme and package information has been updated to point to the new design system website.
403
415
 
404
416
  ## 16.0.1
405
417
 
406
418
  ### Patch Changes
407
419
 
408
- - [`db053b24d8`](https://bitbucket.org/atlassian/atlassian-frontend/commits/db053b24d8) - Update all the theme imports to be tree-shakable
420
+ - [#3428](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/3428) [`db053b24d8`](https://bitbucket.org/atlassian/atlassian-frontend/commits/db053b24d8) - Update all the theme imports to be tree-shakable
409
421
 
410
422
  ## 16.0.0
411
423
 
412
424
  ### Major Changes
413
425
 
414
- - [`87f4720f27`](https://bitbucket.org/atlassian/atlassian-frontend/commits/87f4720f27) - Officially dropping IE11 support, from this version onwards there are no warranties of the package working in IE11.
426
+ - [#3335](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/3335) [`87f4720f27`](https://bitbucket.org/atlassian/atlassian-frontend/commits/87f4720f27) - Officially dropping IE11 support, from this version onwards there are no warranties of the package working in IE11.
415
427
  For more information see: https://community.developer.atlassian.com/t/atlaskit-to-drop-support-for-internet-explorer-11-from-1st-july-2020/39534
416
428
 
417
429
  ### Patch Changes
@@ -422,13 +434,13 @@
422
434
 
423
435
  ### Patch Changes
424
436
 
425
- - [`54a9514fcf`](https://bitbucket.org/atlassian/atlassian-frontend/commits/54a9514fcf) - Build and supporting files will no longer be published to npm
437
+ - [#2866](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/2866) [`54a9514fcf`](https://bitbucket.org/atlassian/atlassian-frontend/commits/54a9514fcf) - Build and supporting files will no longer be published to npm
426
438
 
427
439
  ## 15.2.8
428
440
 
429
441
  ### Patch Changes
430
442
 
431
- - [`4560b65a4f`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4560b65a4f) - upgrade react-transition-group to latest
443
+ - [#2677](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/2677) [`4560b65a4f`](https://bitbucket.org/atlassian/atlassian-frontend/commits/4560b65a4f) - upgrade react-transition-group to latest
432
444
 
433
445
  ## 15.2.7
434
446
 
@@ -26,13 +26,13 @@ var _TooltipContainer = _interopRequireDefault(require("./TooltipContainer"));
26
26
  var _utilities = require("./utilities");
27
27
  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); }
28
28
  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; }
29
- 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; }
30
- 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; } /** @jsx jsx */
29
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
30
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } /** @jsx jsx */
31
31
  var tooltipZIndex = _constants.layers.tooltip();
32
32
  var analyticsAttributes = {
33
33
  componentName: 'tooltip',
34
34
  packageName: "@atlaskit/tooltip",
35
- packageVersion: "17.8.6"
35
+ packageVersion: "17.8.8"
36
36
  };
37
37
 
38
38
  // Inverts motion direction
@@ -97,20 +97,18 @@ function Tooltip(_ref) {
97
97
  setState = _useState2[1];
98
98
  var targetRef = (0, _react.useRef)(null);
99
99
  var containerRef = (0, _react.useRef)(null);
100
+ var hasFunctionalChildren = typeof children === 'function'; // Stored to keep our `setRef` callback cleaner.
100
101
  var setRef = (0, _react.useCallback)(function (node) {
101
102
  if (!node) {
102
103
  return;
103
104
  }
104
- if (typeof children === 'function') {
105
- // @ts-ignore - React Ref typing is too strict for this use case
105
+ if (hasFunctionalChildren) {
106
106
  targetRef.current = node;
107
107
  } else {
108
- // @ts-ignore - React Ref typing is too strict for this use case
109
108
  containerRef.current = node;
110
- // @ts-ignore - React Ref typing is too strict for this use case
111
109
  targetRef.current = node.firstChild;
112
110
  }
113
- }, [children]);
111
+ }, [hasFunctionalChildren]);
114
112
 
115
113
  // Putting a few things into refs so that we don't have to break memoization
116
114
  var lastState = (0, _react.useRef)(state);
@@ -204,7 +202,7 @@ function Tooltip(_ref) {
204
202
  }, [abort, done, start]);
205
203
  var hideTooltipOnEsc = (0, _react.useCallback)(function () {
206
204
  var _apiRef$current;
207
- (_apiRef$current = apiRef.current) === null || _apiRef$current === void 0 ? void 0 : _apiRef$current.requestHide({
205
+ (_apiRef$current = apiRef.current) === null || _apiRef$current === void 0 || _apiRef$current.requestHide({
208
206
  isImmediate: true
209
207
  });
210
208
  }, [apiRef]);
@@ -419,29 +417,25 @@ function Tooltip(_ref) {
419
417
  duration: state === 'show-immediate' ? 0 : _durations.mediumDurationMs
420
418
  }, function (_ref5) {
421
419
  var className = _ref5.className;
422
- return (
423
- // eslint-disable-next-line jsx-a11y/mouse-events-have-key-events
424
- (0, _react2.jsx)(Container, {
425
- ref: ref
426
- /**
427
- * "Tooltip" classname is a hook used by tests to manipulate
428
- * and hide tooltips, including in VR snapshots
429
- **/,
430
- className: "Tooltip ".concat(className),
431
- style: style,
432
- truncate: truncate,
433
- placement: tooltipPosition,
434
- testId: testId,
435
- onMouseOut: onMouseOut,
436
- onMouseOver: onMouseOverTooltip,
437
- id: tooltipId
438
- }, typeof content === 'function' ? content({
439
- update: update
440
- }) : content)
441
- );
420
+ return (0, _react2.jsx)(Container, {
421
+ ref: ref
422
+ /**
423
+ * "Tooltip" classname is a hook used by tests to manipulate
424
+ * and hide tooltips, including in VR snapshots
425
+ **/,
426
+ className: "Tooltip ".concat(className),
427
+ style: style,
428
+ truncate: truncate,
429
+ placement: tooltipPosition,
430
+ testId: testId,
431
+ onMouseOut: onMouseOut,
432
+ onMouseOver: onMouseOverTooltip,
433
+ id: tooltipId
434
+ }, typeof content === 'function' ? content({
435
+ update: update
436
+ }) : content);
442
437
  }));
443
438
  })) : null);
444
439
  }
445
440
  Tooltip.displayName = 'Tooltip';
446
- var _default = Tooltip;
447
- exports.default = _default;
441
+ var _default = exports.default = Tooltip;
@@ -16,8 +16,8 @@ var baseStyles = (0, _react2.css)({
16
16
  boxSizing: 'border-box',
17
17
  maxWidth: '240px',
18
18
  padding: "var(--ds-space-025, 2px)".concat(" ", "var(--ds-space-075, 6px)"),
19
- top: "var(--ds-space-0, 0px)",
20
- left: "var(--ds-space-0, 0px)",
19
+ insetBlockStart: "var(--ds-space-0, 0px)",
20
+ insetInlineStart: "var(--ds-space-0, 0px)",
21
21
  borderRadius: "var(--ds-border-radius, 3px)",
22
22
  fontSize: "var(--ds-font-size-075, 12px)",
23
23
  lineHeight: 1.3,
@@ -26,15 +26,9 @@ var baseStyles = (0, _react2.css)({
26
26
  });
27
27
  var truncateStyles = (0, _react2.css)({
28
28
  maxWidth: '420px',
29
+ overflow: 'hidden',
29
30
  textOverflow: 'ellipsis',
30
- whiteSpace: 'nowrap',
31
- // Use "clip" overflow to allow ellipses on x-axis without clipping descenders
32
- '@supports not (overflow-x: clip)': {
33
- overflow: 'hidden'
34
- },
35
- '@supports (overflow-x: clip)': {
36
- overflowX: 'clip'
37
- }
31
+ whiteSpace: 'nowrap'
38
32
  });
39
33
  var lightStyles = (0, _react2.css)({
40
34
  backgroundColor: "var(--ds-background-neutral-bold, ".concat(_colors.N800, ")"),
@@ -56,22 +50,18 @@ var TooltipContainer = /*#__PURE__*/(0, _react.forwardRef)(function TooltipConta
56
50
  id = _ref.id;
57
51
  return (0, _react2.jsx)(_components.default.Consumer, null, function (_ref2) {
58
52
  var mode = _ref2.mode;
59
- return (
60
- // eslint-disable-next-line jsx-a11y/mouse-events-have-key-events
61
- (0, _react2.jsx)(_TooltipPrimitive.default, {
62
- ref: ref,
63
- style: style,
64
- className: className,
65
- placement: placement,
66
- testId: testId,
67
- id: id,
68
- onMouseOut: onMouseOut,
69
- onMouseOver: onMouseOver,
70
- css: [baseStyles, truncate ? truncateStyles : null, mode === 'light' ? lightStyles : darkStyles]
71
- }, children)
72
- );
53
+ return (0, _react2.jsx)(_TooltipPrimitive.default, {
54
+ ref: ref,
55
+ style: style,
56
+ className: className,
57
+ placement: placement,
58
+ testId: testId,
59
+ id: id,
60
+ onMouseOut: onMouseOut,
61
+ onMouseOver: onMouseOver,
62
+ css: [baseStyles, truncate ? truncateStyles : null, mode === 'light' ? lightStyles : darkStyles]
63
+ }, children);
73
64
  });
74
65
  });
75
66
  TooltipContainer.displayName = 'TooltipContainer';
76
- var _default = TooltipContainer;
77
- exports.default = _default;
67
+ var _default = exports.default = TooltipContainer;
@@ -9,8 +9,8 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
9
9
  var _react = require("react");
10
10
  var _react2 = require("@emotion/react");
11
11
  var _constants = require("@atlaskit/theme/constants");
12
- 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; }
13
- 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; } /** @jsx jsx */
12
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
13
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; } /** @jsx jsx */
14
14
  var VAR_PRIMITIVE_ZINDEX = 'tooltipPrimitiveZindex';
15
15
  var primitiveStyles = (0, _react2.css)({
16
16
  zindex: "var(".concat(VAR_PRIMITIVE_ZINDEX, ")"),
@@ -42,5 +42,4 @@ var TooltipPrimitive = /*#__PURE__*/(0, _react.forwardRef)(function TooltipPrimi
42
42
  }, children));
43
43
  });
44
44
  TooltipPrimitive.displayName = 'TooltipPrimitive';
45
- var _default = TooltipPrimitive;
46
- exports.default = _default;
45
+ var _default = exports.default = TooltipPrimitive;
@@ -20,7 +20,7 @@ const tooltipZIndex = layers.tooltip();
20
20
  const analyticsAttributes = {
21
21
  componentName: 'tooltip',
22
22
  packageName: "@atlaskit/tooltip",
23
- packageVersion: "17.8.6"
23
+ packageVersion: "17.8.8"
24
24
  };
25
25
 
26
26
  // Inverts motion direction
@@ -72,20 +72,18 @@ function Tooltip({
72
72
  const [state, setState] = useState('hide');
73
73
  const targetRef = useRef(null);
74
74
  const containerRef = useRef(null);
75
+ const hasFunctionalChildren = typeof children === 'function'; // Stored to keep our `setRef` callback cleaner.
75
76
  const setRef = useCallback(node => {
76
77
  if (!node) {
77
78
  return;
78
79
  }
79
- if (typeof children === 'function') {
80
- // @ts-ignore - React Ref typing is too strict for this use case
80
+ if (hasFunctionalChildren) {
81
81
  targetRef.current = node;
82
82
  } else {
83
- // @ts-ignore - React Ref typing is too strict for this use case
84
83
  containerRef.current = node;
85
- // @ts-ignore - React Ref typing is too strict for this use case
86
84
  targetRef.current = node.firstChild;
87
85
  }
88
- }, [children]);
86
+ }, [hasFunctionalChildren]);
89
87
 
90
88
  // Putting a few things into refs so that we don't have to break memoization
91
89
  const lastState = useRef(state);
@@ -398,9 +396,7 @@ function Tooltip({
398
396
  duration: state === 'show-immediate' ? 0 : mediumDurationMs
399
397
  }, ({
400
398
  className
401
- }) =>
402
- // eslint-disable-next-line jsx-a11y/mouse-events-have-key-events
403
- jsx(Container, {
399
+ }) => jsx(Container, {
404
400
  ref: ref
405
401
  /**
406
402
  * "Tooltip" classname is a hook used by tests to manipulate
@@ -8,8 +8,8 @@ const baseStyles = css({
8
8
  boxSizing: 'border-box',
9
9
  maxWidth: '240px',
10
10
  padding: `${"var(--ds-space-025, 2px)"} ${"var(--ds-space-075, 6px)"}`,
11
- top: "var(--ds-space-0, 0px)",
12
- left: "var(--ds-space-0, 0px)",
11
+ insetBlockStart: "var(--ds-space-0, 0px)",
12
+ insetInlineStart: "var(--ds-space-0, 0px)",
13
13
  borderRadius: "var(--ds-border-radius, 3px)",
14
14
  fontSize: "var(--ds-font-size-075, 12px)",
15
15
  lineHeight: 1.3,
@@ -18,15 +18,9 @@ const baseStyles = css({
18
18
  });
19
19
  const truncateStyles = css({
20
20
  maxWidth: '420px',
21
+ overflow: 'hidden',
21
22
  textOverflow: 'ellipsis',
22
- whiteSpace: 'nowrap',
23
- // Use "clip" overflow to allow ellipses on x-axis without clipping descenders
24
- '@supports not (overflow-x: clip)': {
25
- overflow: 'hidden'
26
- },
27
- '@supports (overflow-x: clip)': {
28
- overflowX: 'clip'
29
- }
23
+ whiteSpace: 'nowrap'
30
24
  });
31
25
  const lightStyles = css({
32
26
  backgroundColor: `var(--ds-background-neutral-bold, ${N800})`,
@@ -49,9 +43,7 @@ const TooltipContainer = /*#__PURE__*/forwardRef(function TooltipContainer({
49
43
  }, ref) {
50
44
  return jsx(GlobalTheme.Consumer, null, ({
51
45
  mode
52
- }) =>
53
- // eslint-disable-next-line jsx-a11y/mouse-events-have-key-events
54
- jsx(TooltipPrimitive, {
46
+ }) => jsx(TooltipPrimitive, {
55
47
  ref: ref,
56
48
  style: style,
57
49
  className: className,
@@ -1,8 +1,8 @@
1
1
  import _extends from "@babel/runtime/helpers/extends";
2
2
  import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
3
3
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
4
- 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; }
5
- 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) { _defineProperty(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; }
4
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
5
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
6
6
  /** @jsx jsx */
7
7
 
8
8
  import React, { useCallback, useEffect, useRef, useState } from 'react';
@@ -24,7 +24,7 @@ var tooltipZIndex = layers.tooltip();
24
24
  var analyticsAttributes = {
25
25
  componentName: 'tooltip',
26
26
  packageName: "@atlaskit/tooltip",
27
- packageVersion: "17.8.6"
27
+ packageVersion: "17.8.8"
28
28
  };
29
29
 
30
30
  // Inverts motion direction
@@ -89,20 +89,18 @@ function Tooltip(_ref) {
89
89
  setState = _useState2[1];
90
90
  var targetRef = useRef(null);
91
91
  var containerRef = useRef(null);
92
+ var hasFunctionalChildren = typeof children === 'function'; // Stored to keep our `setRef` callback cleaner.
92
93
  var setRef = useCallback(function (node) {
93
94
  if (!node) {
94
95
  return;
95
96
  }
96
- if (typeof children === 'function') {
97
- // @ts-ignore - React Ref typing is too strict for this use case
97
+ if (hasFunctionalChildren) {
98
98
  targetRef.current = node;
99
99
  } else {
100
- // @ts-ignore - React Ref typing is too strict for this use case
101
100
  containerRef.current = node;
102
- // @ts-ignore - React Ref typing is too strict for this use case
103
101
  targetRef.current = node.firstChild;
104
102
  }
105
- }, [children]);
103
+ }, [hasFunctionalChildren]);
106
104
 
107
105
  // Putting a few things into refs so that we don't have to break memoization
108
106
  var lastState = useRef(state);
@@ -196,7 +194,7 @@ function Tooltip(_ref) {
196
194
  }, [abort, done, start]);
197
195
  var hideTooltipOnEsc = useCallback(function () {
198
196
  var _apiRef$current;
199
- (_apiRef$current = apiRef.current) === null || _apiRef$current === void 0 ? void 0 : _apiRef$current.requestHide({
197
+ (_apiRef$current = apiRef.current) === null || _apiRef$current === void 0 || _apiRef$current.requestHide({
200
198
  isImmediate: true
201
199
  });
202
200
  }, [apiRef]);
@@ -411,26 +409,23 @@ function Tooltip(_ref) {
411
409
  duration: state === 'show-immediate' ? 0 : mediumDurationMs
412
410
  }, function (_ref5) {
413
411
  var className = _ref5.className;
414
- return (
415
- // eslint-disable-next-line jsx-a11y/mouse-events-have-key-events
416
- jsx(Container, {
417
- ref: ref
418
- /**
419
- * "Tooltip" classname is a hook used by tests to manipulate
420
- * and hide tooltips, including in VR snapshots
421
- **/,
422
- className: "Tooltip ".concat(className),
423
- style: style,
424
- truncate: truncate,
425
- placement: tooltipPosition,
426
- testId: testId,
427
- onMouseOut: onMouseOut,
428
- onMouseOver: onMouseOverTooltip,
429
- id: tooltipId
430
- }, typeof content === 'function' ? content({
431
- update: update
432
- }) : content)
433
- );
412
+ return jsx(Container, {
413
+ ref: ref
414
+ /**
415
+ * "Tooltip" classname is a hook used by tests to manipulate
416
+ * and hide tooltips, including in VR snapshots
417
+ **/,
418
+ className: "Tooltip ".concat(className),
419
+ style: style,
420
+ truncate: truncate,
421
+ placement: tooltipPosition,
422
+ testId: testId,
423
+ onMouseOut: onMouseOut,
424
+ onMouseOver: onMouseOverTooltip,
425
+ id: tooltipId
426
+ }, typeof content === 'function' ? content({
427
+ update: update
428
+ }) : content);
434
429
  }));
435
430
  })) : null);
436
431
  }
@@ -8,8 +8,8 @@ var baseStyles = css({
8
8
  boxSizing: 'border-box',
9
9
  maxWidth: '240px',
10
10
  padding: "var(--ds-space-025, 2px)".concat(" ", "var(--ds-space-075, 6px)"),
11
- top: "var(--ds-space-0, 0px)",
12
- left: "var(--ds-space-0, 0px)",
11
+ insetBlockStart: "var(--ds-space-0, 0px)",
12
+ insetInlineStart: "var(--ds-space-0, 0px)",
13
13
  borderRadius: "var(--ds-border-radius, 3px)",
14
14
  fontSize: "var(--ds-font-size-075, 12px)",
15
15
  lineHeight: 1.3,
@@ -18,15 +18,9 @@ var baseStyles = css({
18
18
  });
19
19
  var truncateStyles = css({
20
20
  maxWidth: '420px',
21
+ overflow: 'hidden',
21
22
  textOverflow: 'ellipsis',
22
- whiteSpace: 'nowrap',
23
- // Use "clip" overflow to allow ellipses on x-axis without clipping descenders
24
- '@supports not (overflow-x: clip)': {
25
- overflow: 'hidden'
26
- },
27
- '@supports (overflow-x: clip)': {
28
- overflowX: 'clip'
29
- }
23
+ whiteSpace: 'nowrap'
30
24
  });
31
25
  var lightStyles = css({
32
26
  backgroundColor: "var(--ds-background-neutral-bold, ".concat(N800, ")"),
@@ -48,20 +42,17 @@ var TooltipContainer = /*#__PURE__*/forwardRef(function TooltipContainer(_ref, r
48
42
  id = _ref.id;
49
43
  return jsx(GlobalTheme.Consumer, null, function (_ref2) {
50
44
  var mode = _ref2.mode;
51
- return (
52
- // eslint-disable-next-line jsx-a11y/mouse-events-have-key-events
53
- jsx(TooltipPrimitive, {
54
- ref: ref,
55
- style: style,
56
- className: className,
57
- placement: placement,
58
- testId: testId,
59
- id: id,
60
- onMouseOut: onMouseOut,
61
- onMouseOver: onMouseOver,
62
- css: [baseStyles, truncate ? truncateStyles : null, mode === 'light' ? lightStyles : darkStyles]
63
- }, children)
64
- );
45
+ return jsx(TooltipPrimitive, {
46
+ ref: ref,
47
+ style: style,
48
+ className: className,
49
+ placement: placement,
50
+ testId: testId,
51
+ id: id,
52
+ onMouseOut: onMouseOut,
53
+ onMouseOver: onMouseOver,
54
+ css: [baseStyles, truncate ? truncateStyles : null, mode === 'light' ? lightStyles : darkStyles]
55
+ }, children);
65
56
  });
66
57
  });
67
58
  TooltipContainer.displayName = 'TooltipContainer';
@@ -1,6 +1,6 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
- 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; }
3
- 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) { _defineProperty(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; }
2
+ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
3
+ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
4
4
  /** @jsx jsx */
5
5
  import { forwardRef } from 'react';
6
6
  import { css, jsx } from '@emotion/react';
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/tooltip",
3
- "version": "17.8.6",
3
+ "version": "17.8.8",
4
4
  "description": "A tooltip is a floating, non-actionable label used to explain a user interface element or feature.",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -41,11 +41,11 @@
41
41
  "dependencies": {
42
42
  "@atlaskit/analytics-next": "^9.1.0",
43
43
  "@atlaskit/ds-lib": "^2.2.0",
44
- "@atlaskit/motion": "^1.4.0",
44
+ "@atlaskit/motion": "^1.5.0",
45
45
  "@atlaskit/popper": "^5.5.0",
46
46
  "@atlaskit/portal": "^4.3.0",
47
- "@atlaskit/theme": "^12.5.0",
48
- "@atlaskit/tokens": "^1.15.0",
47
+ "@atlaskit/theme": "^12.6.0",
48
+ "@atlaskit/tokens": "^1.26.0",
49
49
  "@babel/runtime": "^7.0.0",
50
50
  "@emotion/react": "^11.7.1",
51
51
  "bind-event-listener": "^2.1.1",
@@ -57,7 +57,7 @@
57
57
  },
58
58
  "devDependencies": {
59
59
  "@af/accessibility-testing": "*",
60
- "@atlaskit/button": "^16.9.0",
60
+ "@atlaskit/button": "^16.10.0",
61
61
  "@atlaskit/ssr": "*",
62
62
  "@atlaskit/visual-regression": "*",
63
63
  "@atlassian/atlassian-frontend-prettier-config-1.0.1": "npm:@atlassian/atlassian-frontend-prettier-config@1.0.1",