@atlaskit/tooltip 19.0.3 → 19.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/dist/cjs/tooltip-container.js +1 -1
- package/dist/cjs/tooltip.js +1 -1
- package/dist/es2019/tooltip-container.js +1 -1
- package/dist/es2019/tooltip.js +1 -1
- package/dist/esm/tooltip-container.js +1 -1
- package/dist/esm/tooltip.js +1 -1
- package/dist/types/tooltip-container.d.ts +1 -1
- package/dist/types/tooltip-primitive.d.ts +1 -1
- package/dist/types-ts4.5/tooltip-container.d.ts +1 -1
- package/dist/types-ts4.5/tooltip-primitive.d.ts +1 -1
- package/package.json +13 -13
- package/__perf__/default.tsx +0 -11
- package/__perf__/examples.tsx +0 -59
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @atlaskit/tooltip
|
|
2
2
|
|
|
3
|
+
## 19.1.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [#109060](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/109060)
|
|
8
|
+
[`4660ec858a305`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/4660ec858a305) -
|
|
9
|
+
Update `React` from v16 to v18
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- Updated dependencies
|
|
14
|
+
|
|
3
15
|
## 19.0.3
|
|
4
16
|
|
|
5
17
|
### Patch Changes
|
package/dist/cjs/tooltip.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* tooltip-container.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* tooltip-container.tsx generated by @compiled/babel-plugin v0.36.0 */
|
|
2
2
|
import "./tooltip-container.compiled.css";
|
|
3
3
|
import * as React from 'react';
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
package/dist/es2019/tooltip.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* tooltip-container.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* tooltip-container.tsx generated by @compiled/babel-plugin v0.36.0 */
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
import "./tooltip-container.compiled.css";
|
|
4
4
|
import * as React from 'react';
|
package/dist/esm/tooltip.js
CHANGED
|
@@ -6,5 +6,5 @@ export interface TooltipContainerProps extends TooltipPrimitiveProps {
|
|
|
6
6
|
* Used as the default tooltip container component for the exported `Tooltip` component.
|
|
7
7
|
* Adds some styles to the tooltip primitive.
|
|
8
8
|
*/
|
|
9
|
-
declare const TooltipContainer: import("react").ForwardRefExoticComponent<
|
|
9
|
+
declare const TooltipContainer: import("react").ForwardRefExoticComponent<Omit<TooltipContainerProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
10
10
|
export default TooltipContainer;
|
|
@@ -19,5 +19,5 @@ export interface TooltipPrimitiveProps {
|
|
|
19
19
|
/**
|
|
20
20
|
* The lower level component for rendering a tooltip.
|
|
21
21
|
*/
|
|
22
|
-
declare const TooltipPrimitive: import("react").ForwardRefExoticComponent<
|
|
22
|
+
declare const TooltipPrimitive: import("react").ForwardRefExoticComponent<Omit<TooltipPrimitiveProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
23
23
|
export default TooltipPrimitive;
|
|
@@ -6,5 +6,5 @@ export interface TooltipContainerProps extends TooltipPrimitiveProps {
|
|
|
6
6
|
* Used as the default tooltip container component for the exported `Tooltip` component.
|
|
7
7
|
* Adds some styles to the tooltip primitive.
|
|
8
8
|
*/
|
|
9
|
-
declare const TooltipContainer: import("react").ForwardRefExoticComponent<
|
|
9
|
+
declare const TooltipContainer: import("react").ForwardRefExoticComponent<Omit<TooltipContainerProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
10
10
|
export default TooltipContainer;
|
|
@@ -19,5 +19,5 @@ export interface TooltipPrimitiveProps {
|
|
|
19
19
|
/**
|
|
20
20
|
* The lower level component for rendering a tooltip.
|
|
21
21
|
*/
|
|
22
|
-
declare const TooltipPrimitive: import("react").ForwardRefExoticComponent<
|
|
22
|
+
declare const TooltipPrimitive: import("react").ForwardRefExoticComponent<Omit<TooltipPrimitiveProps, "ref"> & import("react").RefAttributes<HTMLDivElement>>;
|
|
23
23
|
export default TooltipPrimitive;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/tooltip",
|
|
3
|
-
"version": "19.0
|
|
3
|
+
"version": "19.1.0",
|
|
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,14 +41,14 @@
|
|
|
41
41
|
"./utilities": "./src/utilities.ts"
|
|
42
42
|
},
|
|
43
43
|
"dependencies": {
|
|
44
|
-
"@atlaskit/analytics-next": "^10.
|
|
45
|
-
"@atlaskit/ds-lib": "^3.
|
|
46
|
-
"@atlaskit/layering": "^1.
|
|
47
|
-
"@atlaskit/motion": "^1.
|
|
48
|
-
"@atlaskit/popper": "^6.
|
|
49
|
-
"@atlaskit/portal": "^4.
|
|
50
|
-
"@atlaskit/theme": "^14.
|
|
51
|
-
"@atlaskit/tokens": "^3.
|
|
44
|
+
"@atlaskit/analytics-next": "^10.3.0",
|
|
45
|
+
"@atlaskit/ds-lib": "^3.5.0",
|
|
46
|
+
"@atlaskit/layering": "^1.1.0",
|
|
47
|
+
"@atlaskit/motion": "^1.10.0",
|
|
48
|
+
"@atlaskit/popper": "^6.4.0",
|
|
49
|
+
"@atlaskit/portal": "^4.11.0",
|
|
50
|
+
"@atlaskit/theme": "^14.1.0",
|
|
51
|
+
"@atlaskit/tokens": "^3.3.0",
|
|
52
52
|
"@babel/runtime": "^7.0.0",
|
|
53
53
|
"@compiled/react": "^0.18.1",
|
|
54
54
|
"@emotion/react": "^11.7.1",
|
|
@@ -61,15 +61,15 @@
|
|
|
61
61
|
"devDependencies": {
|
|
62
62
|
"@af/accessibility-testing": "*",
|
|
63
63
|
"@af/integration-testing": "*",
|
|
64
|
-
"@atlaskit/button": "^20.
|
|
65
|
-
"@atlaskit/css": "^0.
|
|
64
|
+
"@atlaskit/button": "^20.4.0",
|
|
65
|
+
"@atlaskit/css": "^0.8.0",
|
|
66
66
|
"@atlaskit/ssr": "*",
|
|
67
67
|
"@atlaskit/visual-regression": "*",
|
|
68
68
|
"@testing-library/dom": "^10.1.0",
|
|
69
|
-
"@testing-library/react": "^
|
|
69
|
+
"@testing-library/react": "^13.4.0",
|
|
70
70
|
"@types/react-redux": "^5.0.0",
|
|
71
71
|
"jest-in-case": "^1.0.2",
|
|
72
|
-
"react-dom": "^
|
|
72
|
+
"react-dom": "^18.2.0",
|
|
73
73
|
"react-redux": "^5.1.2",
|
|
74
74
|
"storybook-addon-performance": "^0.17.3",
|
|
75
75
|
"typescript": "~5.4.2"
|
package/__perf__/default.tsx
DELETED
package/__perf__/examples.tsx
DELETED
|
@@ -1,59 +0,0 @@
|
|
|
1
|
-
import React, { useLayoutEffect } from 'react';
|
|
2
|
-
|
|
3
|
-
import { findByTestId, fireEvent } from '@testing-library/dom';
|
|
4
|
-
import { type InteractionTaskArgs, type PublicInteractionTask } from 'storybook-addon-performance';
|
|
5
|
-
|
|
6
|
-
import Tooltip from '../src';
|
|
7
|
-
|
|
8
|
-
function Child() {
|
|
9
|
-
return <div id="tooltip-reference">New tooltip</div>;
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
function DefaultTooltip() {
|
|
13
|
-
useLayoutEffect(() => {}, []);
|
|
14
|
-
return (
|
|
15
|
-
<Tooltip delay={0} content="Hello World" testId="tooltip">
|
|
16
|
-
<Child />
|
|
17
|
-
</Tooltip>
|
|
18
|
-
);
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
const tooltip = () => <DefaultTooltip />;
|
|
22
|
-
|
|
23
|
-
const interactionTasks: PublicInteractionTask[] = [
|
|
24
|
-
{
|
|
25
|
-
name: 'Display tooltip',
|
|
26
|
-
description: 'Hover over div and wait for tooltip to load',
|
|
27
|
-
run: async ({ container, controls }: InteractionTaskArgs): Promise<void> => {
|
|
28
|
-
const element: HTMLElement | null = container.querySelector('#tooltip-reference');
|
|
29
|
-
if (!element) {
|
|
30
|
-
throw new Error('no div found');
|
|
31
|
-
}
|
|
32
|
-
const parent: HTMLElement | null = container.parentElement;
|
|
33
|
-
if (parent == null) {
|
|
34
|
-
throw new Error('Could not find parent element');
|
|
35
|
-
}
|
|
36
|
-
const tooltip = parent.querySelector('[data-testid="tooltip"]');
|
|
37
|
-
if (tooltip != null) {
|
|
38
|
-
throw new Error('Unexpected tooltip found');
|
|
39
|
-
}
|
|
40
|
-
|
|
41
|
-
await controls.time(async () => {
|
|
42
|
-
fireEvent.mouseOver(element);
|
|
43
|
-
|
|
44
|
-
await findByTestId(parent, 'tooltip');
|
|
45
|
-
});
|
|
46
|
-
},
|
|
47
|
-
},
|
|
48
|
-
];
|
|
49
|
-
|
|
50
|
-
tooltip.story = {
|
|
51
|
-
name: 'Default Tooltip',
|
|
52
|
-
parameters: {
|
|
53
|
-
performance: {
|
|
54
|
-
interactions: interactionTasks,
|
|
55
|
-
},
|
|
56
|
-
},
|
|
57
|
-
};
|
|
58
|
-
|
|
59
|
-
export default tooltip;
|