@atlaskit/blanket 13.3.5 → 14.0.1
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 +22 -0
- package/dist/cjs/blanket.compiled.css +8 -0
- package/dist/cjs/blanket.js +24 -38
- package/dist/es2019/blanket.compiled.css +8 -0
- package/dist/es2019/blanket.js +16 -39
- package/dist/esm/blanket.compiled.css +8 -0
- package/dist/esm/blanket.js +19 -39
- package/package.json +9 -8
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,27 @@
|
|
|
1
1
|
# @atlaskit/blanket
|
|
2
2
|
|
|
3
|
+
## 14.0.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 14.0.0
|
|
10
|
+
|
|
11
|
+
### Major Changes
|
|
12
|
+
|
|
13
|
+
- [#176786](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/176786)
|
|
14
|
+
[`30a4108a8fe56`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/30a4108a8fe56) -
|
|
15
|
+
Migrated from `@emotion/react` to `@compiled/react` in order to improve performance, align with
|
|
16
|
+
the rest of the Atlaskit techstack, and support React 18 Streaming SSR. Please note, in order to
|
|
17
|
+
use this version of `@atlaskit/blanket`, you will need to ensure that your bundler is configured
|
|
18
|
+
to handle `.css` imports correctly.
|
|
19
|
+
|
|
20
|
+
Most bundlers come with built-in support for `.css` imports, so you may not need to do anything.
|
|
21
|
+
If you are using a different bundler, please refer to the documentation for that bundler to
|
|
22
|
+
understand how to handle `.css` imports. For more information on the migration, please refer to
|
|
23
|
+
[RFC-73 Migrating our components to Compiled CSS-in-JS](https://community.developer.atlassian.com/t/rfc-73-migrating-our-components-to-compiled-css-in-js/85953).
|
|
24
|
+
|
|
3
25
|
## 13.3.5
|
|
4
26
|
|
|
5
27
|
### Patch Changes
|
package/dist/cjs/blanket.js
CHANGED
|
@@ -1,43 +1,35 @@
|
|
|
1
|
+
/* blanket.tsx generated by @compiled/babel-plugin v0.35.0 */
|
|
1
2
|
"use strict";
|
|
2
3
|
|
|
3
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
5
|
+
var _typeof = require("@babel/runtime/helpers/typeof");
|
|
4
6
|
Object.defineProperty(exports, "__esModule", {
|
|
5
7
|
value: true
|
|
6
8
|
});
|
|
7
9
|
exports.default = void 0;
|
|
10
|
+
require("./blanket.compiled.css");
|
|
11
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
12
|
+
var React = _react;
|
|
13
|
+
var _runtime = require("@compiled/react/runtime");
|
|
8
14
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
9
|
-
var _react = require("react");
|
|
10
|
-
var _react2 = require("@emotion/react");
|
|
11
15
|
var _usePlatformLeafEventHandler = require("@atlaskit/analytics-next/usePlatformLeafEventHandler");
|
|
12
16
|
var _noop = _interopRequireDefault(require("@atlaskit/ds-lib/noop"));
|
|
13
17
|
var _colors = require("@atlaskit/theme/colors");
|
|
14
18
|
var _constants = require("@atlaskit/theme/constants");
|
|
19
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
|
|
20
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
15
21
|
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; }
|
|
16
|
-
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; }
|
|
17
|
-
* @jsxRuntime classic
|
|
18
|
-
* @jsx jsx
|
|
19
|
-
*/ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
22
|
+
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; }
|
|
20
23
|
var packageName = "@atlaskit/blanket";
|
|
21
|
-
var packageVersion = "
|
|
24
|
+
var packageVersion = "14.0.1";
|
|
22
25
|
var analyticsAttributes = {
|
|
23
26
|
componentName: 'blanket',
|
|
24
27
|
packageName: packageName,
|
|
25
28
|
packageVersion: packageVersion
|
|
26
29
|
};
|
|
27
|
-
var baseStyles =
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
inset: 0,
|
|
31
|
-
backgroundColor: "var(--ds-blanket, ".concat(_colors.N100A, ")"),
|
|
32
|
-
overflowY: 'auto',
|
|
33
|
-
pointerEvents: 'initial'
|
|
34
|
-
});
|
|
35
|
-
var shouldAllowClickThroughStyles = (0, _react2.css)({
|
|
36
|
-
pointerEvents: 'none'
|
|
37
|
-
});
|
|
38
|
-
var invisibleStyles = (0, _react2.css)({
|
|
39
|
-
backgroundColor: 'transparent'
|
|
40
|
-
});
|
|
30
|
+
var baseStyles = null;
|
|
31
|
+
var shouldAllowClickThroughStyles = null;
|
|
32
|
+
var invisibleStyles = null;
|
|
41
33
|
|
|
42
34
|
/**
|
|
43
35
|
* __Blanket__
|
|
@@ -69,23 +61,17 @@ var Blanket = /*#__PURE__*/(0, _react.memo)( /*#__PURE__*/(0, _react.forwardRef)
|
|
|
69
61
|
var onMouseDown = (0, _react.useCallback)(function (e) {
|
|
70
62
|
mouseDownTarget.current = e.target;
|
|
71
63
|
}, []);
|
|
72
|
-
return (
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
onClick: onClick,
|
|
84
|
-
onMouseDown: onMouseDown,
|
|
85
|
-
"data-testid": testId,
|
|
86
|
-
ref: ref
|
|
87
|
-
}, children)
|
|
88
|
-
);
|
|
64
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
65
|
+
role: "presentation",
|
|
66
|
+
onClick: onClick,
|
|
67
|
+
onMouseDown: onMouseDown,
|
|
68
|
+
"data-testid": testId,
|
|
69
|
+
ref: ref,
|
|
70
|
+
className: (0, _runtime.ax)(["_1r04idpf _kqsw1n9t _1pbybfng _bfhk705f _18m91wug _lcxv1wug", shouldAllowClickThrough && "_lcxvglyw", !isTinted && "_bfhk18uv"]),
|
|
71
|
+
style: {
|
|
72
|
+
"--_10avjlk": (0, _runtime.ix)("var(--ds-blanket, ".concat(_colors.N100A, ")"))
|
|
73
|
+
}
|
|
74
|
+
}, children);
|
|
89
75
|
}));
|
|
90
76
|
Blanket.displayName = 'Blanket';
|
|
91
77
|
var _default = exports.default = Blanket;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
|
|
2
|
+
._1r04idpf{inset:0}._18m91wug{overflow-y:auto}
|
|
3
|
+
._1pbybfng{z-index:500}
|
|
4
|
+
._bfhk10ak{background-color:var(--ds-blanket,rgba(9,30,66,.54))}
|
|
5
|
+
._bfhk18uv{background-color:initial}
|
|
6
|
+
._kqsw1n9t{position:fixed}
|
|
7
|
+
._lcxv1wug{pointer-events:auto}
|
|
8
|
+
._lcxvglyw{pointer-events:none}
|
package/dist/es2019/blanket.js
CHANGED
|
@@ -1,36 +1,22 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
*
|
|
4
|
-
|
|
1
|
+
/* blanket.tsx generated by @compiled/babel-plugin v0.35.0 */
|
|
2
|
+
import "./blanket.compiled.css";
|
|
3
|
+
import * as React from 'react';
|
|
4
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
5
5
|
import { forwardRef, memo, useCallback, useRef } from 'react';
|
|
6
|
-
|
|
7
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
|
-
import { css, jsx } from '@emotion/react';
|
|
9
6
|
import { usePlatformLeafEventHandler } from '@atlaskit/analytics-next/usePlatformLeafEventHandler';
|
|
10
7
|
import noop from '@atlaskit/ds-lib/noop';
|
|
11
8
|
import { N100A } from '@atlaskit/theme/colors';
|
|
12
9
|
import { layers } from '@atlaskit/theme/constants';
|
|
13
10
|
const packageName = "@atlaskit/blanket";
|
|
14
|
-
const packageVersion = "
|
|
11
|
+
const packageVersion = "14.0.1";
|
|
15
12
|
const analyticsAttributes = {
|
|
16
13
|
componentName: 'blanket',
|
|
17
14
|
packageName,
|
|
18
15
|
packageVersion
|
|
19
16
|
};
|
|
20
|
-
const baseStyles =
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
inset: 0,
|
|
24
|
-
backgroundColor: `var(--ds-blanket, ${N100A})`,
|
|
25
|
-
overflowY: 'auto',
|
|
26
|
-
pointerEvents: 'initial'
|
|
27
|
-
});
|
|
28
|
-
const shouldAllowClickThroughStyles = css({
|
|
29
|
-
pointerEvents: 'none'
|
|
30
|
-
});
|
|
31
|
-
const invisibleStyles = css({
|
|
32
|
-
backgroundColor: 'transparent'
|
|
33
|
-
});
|
|
17
|
+
const baseStyles = null;
|
|
18
|
+
const shouldAllowClickThroughStyles = null;
|
|
19
|
+
const invisibleStyles = null;
|
|
34
20
|
|
|
35
21
|
/**
|
|
36
22
|
* __Blanket__
|
|
@@ -59,23 +45,14 @@ const Blanket = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Blanket({
|
|
|
59
45
|
const onMouseDown = useCallback(e => {
|
|
60
46
|
mouseDownTarget.current = e.target;
|
|
61
47
|
}, []);
|
|
62
|
-
return (
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
jsx("div", {
|
|
71
|
-
role: "presentation",
|
|
72
|
-
css: [baseStyles, shouldAllowClickThrough && shouldAllowClickThroughStyles, !isTinted && invisibleStyles],
|
|
73
|
-
onClick: onClick,
|
|
74
|
-
onMouseDown: onMouseDown,
|
|
75
|
-
"data-testid": testId,
|
|
76
|
-
ref: ref
|
|
77
|
-
}, children)
|
|
78
|
-
);
|
|
48
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
49
|
+
role: "presentation",
|
|
50
|
+
onClick: onClick,
|
|
51
|
+
onMouseDown: onMouseDown,
|
|
52
|
+
"data-testid": testId,
|
|
53
|
+
ref: ref,
|
|
54
|
+
className: ax(["_1r04idpf _kqsw1n9t _1pbybfng _bfhk10ak _18m91wug _lcxv1wug", shouldAllowClickThrough && "_lcxvglyw", !isTinted && "_bfhk18uv"])
|
|
55
|
+
}, children);
|
|
79
56
|
}));
|
|
80
57
|
Blanket.displayName = 'Blanket';
|
|
81
58
|
export default Blanket;
|
package/dist/esm/blanket.js
CHANGED
|
@@ -1,39 +1,25 @@
|
|
|
1
|
+
/* blanket.tsx generated by @compiled/babel-plugin v0.35.0 */
|
|
1
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
|
+
import "./blanket.compiled.css";
|
|
4
|
+
import * as React from 'react';
|
|
5
|
+
import { ax, ix } from "@compiled/react/runtime";
|
|
2
6
|
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
7
|
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
|
-
/**
|
|
5
|
-
* @jsxRuntime classic
|
|
6
|
-
* @jsx jsx
|
|
7
|
-
*/
|
|
8
8
|
import { forwardRef, memo, useCallback, useRef } from 'react';
|
|
9
|
-
|
|
10
|
-
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
11
|
-
import { css, jsx } from '@emotion/react';
|
|
12
9
|
import { usePlatformLeafEventHandler } from '@atlaskit/analytics-next/usePlatformLeafEventHandler';
|
|
13
10
|
import noop from '@atlaskit/ds-lib/noop';
|
|
14
11
|
import { N100A } from '@atlaskit/theme/colors';
|
|
15
12
|
import { layers } from '@atlaskit/theme/constants';
|
|
16
13
|
var packageName = "@atlaskit/blanket";
|
|
17
|
-
var packageVersion = "
|
|
14
|
+
var packageVersion = "14.0.1";
|
|
18
15
|
var analyticsAttributes = {
|
|
19
16
|
componentName: 'blanket',
|
|
20
17
|
packageName: packageName,
|
|
21
18
|
packageVersion: packageVersion
|
|
22
19
|
};
|
|
23
|
-
var baseStyles =
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
inset: 0,
|
|
27
|
-
backgroundColor: "var(--ds-blanket, ".concat(N100A, ")"),
|
|
28
|
-
overflowY: 'auto',
|
|
29
|
-
pointerEvents: 'initial'
|
|
30
|
-
});
|
|
31
|
-
var shouldAllowClickThroughStyles = css({
|
|
32
|
-
pointerEvents: 'none'
|
|
33
|
-
});
|
|
34
|
-
var invisibleStyles = css({
|
|
35
|
-
backgroundColor: 'transparent'
|
|
36
|
-
});
|
|
20
|
+
var baseStyles = null;
|
|
21
|
+
var shouldAllowClickThroughStyles = null;
|
|
22
|
+
var invisibleStyles = null;
|
|
37
23
|
|
|
38
24
|
/**
|
|
39
25
|
* __Blanket__
|
|
@@ -65,23 +51,17 @@ var Blanket = /*#__PURE__*/memo( /*#__PURE__*/forwardRef(function Blanket(_ref,
|
|
|
65
51
|
var onMouseDown = useCallback(function (e) {
|
|
66
52
|
mouseDownTarget.current = e.target;
|
|
67
53
|
}, []);
|
|
68
|
-
return (
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
onClick: onClick,
|
|
80
|
-
onMouseDown: onMouseDown,
|
|
81
|
-
"data-testid": testId,
|
|
82
|
-
ref: ref
|
|
83
|
-
}, children)
|
|
84
|
-
);
|
|
54
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
55
|
+
role: "presentation",
|
|
56
|
+
onClick: onClick,
|
|
57
|
+
onMouseDown: onMouseDown,
|
|
58
|
+
"data-testid": testId,
|
|
59
|
+
ref: ref,
|
|
60
|
+
className: ax(["_1r04idpf _kqsw1n9t _1pbybfng _bfhk705f _18m91wug _lcxv1wug", shouldAllowClickThrough && "_lcxvglyw", !isTinted && "_bfhk18uv"]),
|
|
61
|
+
style: {
|
|
62
|
+
"--_10avjlk": ix("var(--ds-blanket, ".concat(N100A, ")"))
|
|
63
|
+
}
|
|
64
|
+
}, children);
|
|
85
65
|
}));
|
|
86
66
|
Blanket.displayName = 'Blanket';
|
|
87
67
|
export default Blanket;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/blanket",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "14.0.1",
|
|
4
4
|
"description": "A blanket covers the underlying UI for a layered component, such as a modal dialog or a tooltip.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -30,7 +30,7 @@
|
|
|
30
30
|
"runReact18": true,
|
|
31
31
|
"website": {
|
|
32
32
|
"name": "Blanket",
|
|
33
|
-
"category": "
|
|
33
|
+
"category": "Overlays and layering"
|
|
34
34
|
}
|
|
35
35
|
},
|
|
36
36
|
"af:exports": {
|
|
@@ -38,13 +38,14 @@
|
|
|
38
38
|
"./types": "./src/entry-points/types.tsx"
|
|
39
39
|
},
|
|
40
40
|
"dependencies": {
|
|
41
|
-
"@atlaskit/analytics-next": "^10.
|
|
41
|
+
"@atlaskit/analytics-next": "^10.2.0",
|
|
42
42
|
"@atlaskit/codemod-utils": "^4.2.0",
|
|
43
|
-
"@atlaskit/
|
|
43
|
+
"@atlaskit/css": "^0.7.0",
|
|
44
|
+
"@atlaskit/ds-lib": "^3.3.0",
|
|
44
45
|
"@atlaskit/theme": "^14.0.0",
|
|
45
|
-
"@atlaskit/tokens": "^
|
|
46
|
+
"@atlaskit/tokens": "^3.0.0",
|
|
46
47
|
"@babel/runtime": "^7.0.0",
|
|
47
|
-
"@
|
|
48
|
+
"@compiled/react": "^0.18.1"
|
|
48
49
|
},
|
|
49
50
|
"peerDependencies": {
|
|
50
51
|
"react": "^16.8.0 || ^17.0.0 || ^18.0.0"
|
|
@@ -52,9 +53,9 @@
|
|
|
52
53
|
"devDependencies": {
|
|
53
54
|
"@af/accessibility-testing": "*",
|
|
54
55
|
"@af/integration-testing": "*",
|
|
55
|
-
"@atlaskit/layering": "^0.
|
|
56
|
+
"@atlaskit/layering": "^1.0.0",
|
|
56
57
|
"@atlaskit/ssr": "*",
|
|
57
|
-
"@atlaskit/toggle": "^
|
|
58
|
+
"@atlaskit/toggle": "^14.0.0",
|
|
58
59
|
"@atlaskit/visual-regression": "*",
|
|
59
60
|
"@testing-library/dom": "^10.1.0",
|
|
60
61
|
"@testing-library/react": "^12.1.5",
|