@atlaskit/drawer 7.0.0 → 7.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +26 -0
- package/dist/cjs/components/index.js +1 -1
- package/dist/cjs/components/primitives/content.js +2 -2
- package/dist/cjs/components/primitives/icon-button.js +2 -2
- package/dist/cjs/components/primitives/index.js +12 -7
- package/dist/cjs/components/primitives/sidebar.js +3 -3
- package/dist/cjs/components/transitions.js +7 -4
- package/dist/cjs/version.json +1 -1
- package/dist/es2019/components/index.js +1 -1
- package/dist/es2019/components/primitives/icon-button.js +2 -2
- package/dist/es2019/components/primitives/index.js +1 -1
- package/dist/es2019/components/primitives/sidebar.js +1 -1
- package/dist/es2019/version.json +1 -1
- package/dist/esm/components/index.js +1 -1
- package/dist/esm/components/primitives/content.js +2 -1
- package/dist/esm/components/primitives/icon-button.js +2 -2
- package/dist/esm/components/primitives/index.js +11 -7
- package/dist/esm/components/primitives/sidebar.js +3 -2
- package/dist/esm/components/transitions.js +6 -4
- package/dist/esm/version.json +1 -1
- package/dist/types/components/primitives/content.d.ts +1 -0
- package/package.json +13 -10
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,31 @@
|
|
|
1
1
|
# @atlaskit/drawer
|
|
2
2
|
|
|
3
|
+
## 7.1.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 7.1.1
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [`c55c736ecea`](https://bitbucket.org/atlassian/atlassian-frontend/commits/c55c736ecea) - Patch VULN AFP-3486 AFP-3487 AFP-3488 AFP-3489
|
|
14
|
+
|
|
15
|
+
## 7.1.0
|
|
16
|
+
|
|
17
|
+
### Minor Changes
|
|
18
|
+
|
|
19
|
+
- [`d19fa028010`](https://bitbucket.org/atlassian/atlassian-frontend/commits/d19fa028010) - Instrumented `@atlaskit/drawer` with the new theming package, `@atlaskit/tokens`.
|
|
20
|
+
|
|
21
|
+
New tokens will be visible only in applications configured to use the new Tokens API (currently in alpha). These changes are intended to be interoperable with the legacy theme implementation. Legacy dark mode users should expect no visual or breaking changes.
|
|
22
|
+
|
|
23
|
+
## 7.0.1
|
|
24
|
+
|
|
25
|
+
### Patch Changes
|
|
26
|
+
|
|
27
|
+
- [`3fced6aa641`](https://bitbucket.org/atlassian/atlassian-frontend/commits/3fced6aa641) - Bumped `react-focus-lock` to version `^2.2.1`.
|
|
28
|
+
|
|
3
29
|
## 7.0.0
|
|
4
30
|
|
|
5
31
|
### Major Changes
|
|
@@ -52,7 +52,7 @@ function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflec
|
|
|
52
52
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
53
53
|
|
|
54
54
|
var packageName = "@atlaskit/drawer";
|
|
55
|
-
var packageVersion = "7.
|
|
55
|
+
var packageVersion = "7.1.2";
|
|
56
56
|
|
|
57
57
|
var OnlyChild = function OnlyChild(_ref) {
|
|
58
58
|
var children = _ref.children;
|
|
@@ -15,7 +15,7 @@ var _core = require("@emotion/core");
|
|
|
15
15
|
|
|
16
16
|
var _constants = require("@atlaskit/theme/constants");
|
|
17
17
|
|
|
18
|
-
|
|
18
|
+
var _excluded = ["cssFn"];
|
|
19
19
|
var defaultStyles = {
|
|
20
20
|
flex: 1,
|
|
21
21
|
overflow: 'auto',
|
|
@@ -28,7 +28,7 @@ var contentCSS = function contentCSS() {
|
|
|
28
28
|
|
|
29
29
|
var Content = function Content(_ref) {
|
|
30
30
|
var cssFn = _ref.cssFn,
|
|
31
|
-
props = (0, _objectWithoutProperties2.default)(_ref,
|
|
31
|
+
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
32
32
|
return (
|
|
33
33
|
/**
|
|
34
34
|
* I noticed the implementation at @atlaskit/checkbox would send the props to cssFn rather
|
|
@@ -29,10 +29,10 @@ var iconButtonStyles = (0, _core.css)({
|
|
|
29
29
|
fontSize: 'inherit',
|
|
30
30
|
lineHeight: 1,
|
|
31
31
|
'&:hover': {
|
|
32
|
-
backgroundColor: _colors.N30A
|
|
32
|
+
backgroundColor: "var(--ds-background-transparentNeutral-hover, ".concat(_colors.N30A, ")")
|
|
33
33
|
},
|
|
34
34
|
'&:active': {
|
|
35
|
-
backgroundColor: _colors.B50,
|
|
35
|
+
backgroundColor: "var(--ds-background-transparentNeutral-pressed, ".concat(_colors.B50, ")"),
|
|
36
36
|
outline: 0
|
|
37
37
|
}
|
|
38
38
|
});
|
|
@@ -43,13 +43,18 @@ var _iconButton = _interopRequireDefault(require("./icon-button"));
|
|
|
43
43
|
|
|
44
44
|
var _sidebar = _interopRequireDefault(require("./sidebar"));
|
|
45
45
|
|
|
46
|
+
var _excluded = ["width", "shouldUnmountOnExit", "style"],
|
|
47
|
+
_excluded2 = ["children", "icon", "onClose", "onCloseComplete", "onOpenComplete", "overrides", "testId"],
|
|
48
|
+
_excluded3 = ["component"],
|
|
49
|
+
_excluded4 = ["component"];
|
|
50
|
+
|
|
46
51
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
47
52
|
|
|
48
53
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
49
54
|
|
|
50
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
55
|
+
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; }
|
|
51
56
|
|
|
52
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
57
|
+
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; }
|
|
53
58
|
|
|
54
59
|
// Misc.
|
|
55
60
|
// ------------------------------
|
|
@@ -67,7 +72,7 @@ var wrapperStyles = (0, _core.css)({
|
|
|
67
72
|
zIndex: _constants.layers.blanket() + 1,
|
|
68
73
|
top: 0,
|
|
69
74
|
left: 0,
|
|
70
|
-
backgroundColor: _colors.N0,
|
|
75
|
+
backgroundColor: "var(--ds-background-overlay, ".concat(_colors.N0, ")"),
|
|
71
76
|
overflow: 'hidden'
|
|
72
77
|
});
|
|
73
78
|
|
|
@@ -76,7 +81,7 @@ var Wrapper = function Wrapper(_ref) {
|
|
|
76
81
|
width = _ref$width === void 0 ? 'narrow' : _ref$width,
|
|
77
82
|
shouldUnmountOnExit = _ref.shouldUnmountOnExit,
|
|
78
83
|
style = _ref.style,
|
|
79
|
-
props = (0, _objectWithoutProperties2.default)(_ref,
|
|
84
|
+
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
80
85
|
return (0, _core.jsx)("div", (0, _extends2.default)({
|
|
81
86
|
style: _objectSpread(_objectSpread({}, style), {}, {
|
|
82
87
|
width: widths[width]
|
|
@@ -111,16 +116,16 @@ var DrawerPrimitive = /*#__PURE__*/function (_Component) {
|
|
|
111
116
|
onOpenComplete = _this$props.onOpenComplete,
|
|
112
117
|
overrides = _this$props.overrides,
|
|
113
118
|
testId = _this$props.testId,
|
|
114
|
-
props = (0, _objectWithoutProperties2.default)(_this$props,
|
|
119
|
+
props = (0, _objectWithoutProperties2.default)(_this$props, _excluded2);
|
|
115
120
|
var getOverrides = (0, _utils.createExtender)(defaults, overrides);
|
|
116
121
|
|
|
117
122
|
var _getOverrides = getOverrides('Sidebar'),
|
|
118
123
|
Sidebar = _getOverrides.component,
|
|
119
|
-
sideBarOverrides = (0, _objectWithoutProperties2.default)(_getOverrides,
|
|
124
|
+
sideBarOverrides = (0, _objectWithoutProperties2.default)(_getOverrides, _excluded3);
|
|
120
125
|
|
|
121
126
|
var _getOverrides2 = getOverrides('Content'),
|
|
122
127
|
Content = _getOverrides2.component,
|
|
123
|
-
contentOverrides = (0, _objectWithoutProperties2.default)(_getOverrides2,
|
|
128
|
+
contentOverrides = (0, _objectWithoutProperties2.default)(_getOverrides2, _excluded4);
|
|
124
129
|
|
|
125
130
|
return (0, _core.jsx)(_transitions.Slide, (0, _extends2.default)({
|
|
126
131
|
component: Wrapper,
|
|
@@ -17,11 +17,11 @@ var _colors = require("@atlaskit/theme/colors");
|
|
|
17
17
|
|
|
18
18
|
var _constants = require("@atlaskit/theme/constants");
|
|
19
19
|
|
|
20
|
-
|
|
20
|
+
var _excluded = ["cssFn"];
|
|
21
21
|
var defaultStyle = {
|
|
22
22
|
alignItems: 'center',
|
|
23
23
|
boxSizing: 'border-box',
|
|
24
|
-
color: _colors.N500,
|
|
24
|
+
color: "var(--ds-text-mediumEmphasis, ".concat(_colors.N500, ")"),
|
|
25
25
|
display: 'flex',
|
|
26
26
|
flexShrink: 0,
|
|
27
27
|
flexDirection: 'column',
|
|
@@ -37,7 +37,7 @@ var sidebarCSS = function sidebarCSS() {
|
|
|
37
37
|
|
|
38
38
|
var Sidebar = function Sidebar(_ref) {
|
|
39
39
|
var cssFn = _ref.cssFn,
|
|
40
|
-
props = (0, _objectWithoutProperties2.default)(_ref,
|
|
40
|
+
props = (0, _objectWithoutProperties2.default)(_ref, _excluded);
|
|
41
41
|
// eslint-disable-next-line @repo/internal/react/consistent-css-prop-usage
|
|
42
42
|
return (0, _core.jsx)("div", (0, _extends2.default)({
|
|
43
43
|
css: cssFn(defaultStyle)
|
|
@@ -35,13 +35,16 @@ var _constants = require("@atlaskit/theme/constants");
|
|
|
35
35
|
|
|
36
36
|
var _constants2 = require("../constants");
|
|
37
37
|
|
|
38
|
+
var _excluded = ["component", "in", "onExited", "onEntered", "defaultStyles", "transitionStyles", "transitionProps"],
|
|
39
|
+
_excluded2 = ["shouldUnmountOnExit"];
|
|
40
|
+
|
|
38
41
|
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); }
|
|
39
42
|
|
|
40
43
|
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; }
|
|
41
44
|
|
|
42
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
45
|
+
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; }
|
|
43
46
|
|
|
44
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
47
|
+
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; }
|
|
45
48
|
|
|
46
49
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = (0, _getPrototypeOf2.default)(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = (0, _getPrototypeOf2.default)(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return (0, _possibleConstructorReturn2.default)(this, result); }; }
|
|
47
50
|
|
|
@@ -104,7 +107,7 @@ var TransitionHandler = /*#__PURE__*/function (_Component) {
|
|
|
104
107
|
defaultStyles = _this$props.defaultStyles,
|
|
105
108
|
transitionStyles = _this$props.transitionStyles,
|
|
106
109
|
transitionProps = _this$props.transitionProps,
|
|
107
|
-
props = (0, _objectWithoutProperties2.default)(_this$props,
|
|
110
|
+
props = (0, _objectWithoutProperties2.default)(_this$props, _excluded);
|
|
108
111
|
var timeout = {
|
|
109
112
|
enter: 0,
|
|
110
113
|
exit: _constants2.transitionDurationMs
|
|
@@ -158,7 +161,7 @@ exports.Fade = Fade;
|
|
|
158
161
|
var Slide = function Slide(_ref2) {
|
|
159
162
|
var _ref2$shouldUnmountOn = _ref2.shouldUnmountOnExit,
|
|
160
163
|
shouldUnmountOnExit = _ref2$shouldUnmountOn === void 0 ? true : _ref2$shouldUnmountOn,
|
|
161
|
-
props = (0, _objectWithoutProperties2.default)(_ref2,
|
|
164
|
+
props = (0, _objectWithoutProperties2.default)(_ref2, _excluded2);
|
|
162
165
|
return /*#__PURE__*/_react.default.createElement(TransitionHandler, (0, _extends2.default)({
|
|
163
166
|
defaultStyles: {
|
|
164
167
|
transition: "transform ".concat(_constants2.transitionDurationMs, "ms ").concat(_constants2.transitionTimingFunction, ", ") + "width ".concat(_constants2.transitionDurationMs, "ms ").concat(_constants2.transitionTimingFunction),
|
package/dist/cjs/version.json
CHANGED
|
@@ -10,7 +10,7 @@ import FocusLock from './focus-lock';
|
|
|
10
10
|
import DrawerPrimitive from './primitives';
|
|
11
11
|
import { Fade } from './transitions';
|
|
12
12
|
const packageName = "@atlaskit/drawer";
|
|
13
|
-
const packageVersion = "7.
|
|
13
|
+
const packageVersion = "7.1.2";
|
|
14
14
|
|
|
15
15
|
const OnlyChild = ({
|
|
16
16
|
children
|
|
@@ -19,10 +19,10 @@ const iconButtonStyles = css({
|
|
|
19
19
|
fontSize: 'inherit',
|
|
20
20
|
lineHeight: 1,
|
|
21
21
|
'&:hover': {
|
|
22
|
-
backgroundColor: N30A
|
|
22
|
+
backgroundColor: `var(--ds-background-transparentNeutral-hover, ${N30A})`
|
|
23
23
|
},
|
|
24
24
|
'&:active': {
|
|
25
|
-
backgroundColor: B50
|
|
25
|
+
backgroundColor: `var(--ds-background-transparentNeutral-pressed, ${B50})`,
|
|
26
26
|
outline: 0
|
|
27
27
|
}
|
|
28
28
|
});
|
package/dist/es2019/version.json
CHANGED
|
@@ -21,7 +21,7 @@ import FocusLock from './focus-lock';
|
|
|
21
21
|
import DrawerPrimitive from './primitives';
|
|
22
22
|
import { Fade } from './transitions';
|
|
23
23
|
var packageName = "@atlaskit/drawer";
|
|
24
|
-
var packageVersion = "7.
|
|
24
|
+
var packageVersion = "7.1.2";
|
|
25
25
|
|
|
26
26
|
var OnlyChild = function OnlyChild(_ref) {
|
|
27
27
|
var children = _ref.children;
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
|
+
var _excluded = ["cssFn"];
|
|
3
4
|
|
|
4
5
|
/** @jsx jsx */
|
|
5
6
|
import { jsx } from '@emotion/core';
|
|
@@ -16,7 +17,7 @@ var contentCSS = function contentCSS() {
|
|
|
16
17
|
|
|
17
18
|
var Content = function Content(_ref) {
|
|
18
19
|
var cssFn = _ref.cssFn,
|
|
19
|
-
props = _objectWithoutProperties(_ref,
|
|
20
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
20
21
|
|
|
21
22
|
return (
|
|
22
23
|
/**
|
|
@@ -19,10 +19,10 @@ var iconButtonStyles = css({
|
|
|
19
19
|
fontSize: 'inherit',
|
|
20
20
|
lineHeight: 1,
|
|
21
21
|
'&:hover': {
|
|
22
|
-
backgroundColor: N30A
|
|
22
|
+
backgroundColor: "var(--ds-background-transparentNeutral-hover, ".concat(N30A, ")")
|
|
23
23
|
},
|
|
24
24
|
'&:active': {
|
|
25
|
-
backgroundColor: B50,
|
|
25
|
+
backgroundColor: "var(--ds-background-transparentNeutral-pressed, ".concat(B50, ")"),
|
|
26
26
|
outline: 0
|
|
27
27
|
}
|
|
28
28
|
});
|
|
@@ -6,14 +6,18 @@ import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
|
6
6
|
import _extends from "@babel/runtime/helpers/extends";
|
|
7
7
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
8
8
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
9
|
+
var _excluded = ["width", "shouldUnmountOnExit", "style"],
|
|
10
|
+
_excluded2 = ["children", "icon", "onClose", "onCloseComplete", "onOpenComplete", "overrides", "testId"],
|
|
11
|
+
_excluded3 = ["component"],
|
|
12
|
+
_excluded4 = ["component"];
|
|
9
13
|
|
|
10
14
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
11
15
|
|
|
12
16
|
function _isNativeReflectConstruct() { if (typeof Reflect === "undefined" || !Reflect.construct) return false; if (Reflect.construct.sham) return false; if (typeof Proxy === "function") return true; try { Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); return true; } catch (e) { return false; } }
|
|
13
17
|
|
|
14
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
18
|
+
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; }
|
|
15
19
|
|
|
16
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
20
|
+
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; }
|
|
17
21
|
|
|
18
22
|
/** @jsx jsx */
|
|
19
23
|
import { Component } from 'react';
|
|
@@ -42,7 +46,7 @@ var wrapperStyles = css({
|
|
|
42
46
|
zIndex: layers.blanket() + 1,
|
|
43
47
|
top: 0,
|
|
44
48
|
left: 0,
|
|
45
|
-
backgroundColor: N0,
|
|
49
|
+
backgroundColor: "var(--ds-background-overlay, ".concat(N0, ")"),
|
|
46
50
|
overflow: 'hidden'
|
|
47
51
|
});
|
|
48
52
|
|
|
@@ -51,7 +55,7 @@ var Wrapper = function Wrapper(_ref) {
|
|
|
51
55
|
width = _ref$width === void 0 ? 'narrow' : _ref$width,
|
|
52
56
|
shouldUnmountOnExit = _ref.shouldUnmountOnExit,
|
|
53
57
|
style = _ref.style,
|
|
54
|
-
props = _objectWithoutProperties(_ref,
|
|
58
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
55
59
|
|
|
56
60
|
return jsx("div", _extends({
|
|
57
61
|
style: _objectSpread(_objectSpread({}, style), {}, {
|
|
@@ -88,17 +92,17 @@ var DrawerPrimitive = /*#__PURE__*/function (_Component) {
|
|
|
88
92
|
onOpenComplete = _this$props.onOpenComplete,
|
|
89
93
|
overrides = _this$props.overrides,
|
|
90
94
|
testId = _this$props.testId,
|
|
91
|
-
props = _objectWithoutProperties(_this$props,
|
|
95
|
+
props = _objectWithoutProperties(_this$props, _excluded2);
|
|
92
96
|
|
|
93
97
|
var getOverrides = createExtender(defaults, overrides);
|
|
94
98
|
|
|
95
99
|
var _getOverrides = getOverrides('Sidebar'),
|
|
96
100
|
Sidebar = _getOverrides.component,
|
|
97
|
-
sideBarOverrides = _objectWithoutProperties(_getOverrides,
|
|
101
|
+
sideBarOverrides = _objectWithoutProperties(_getOverrides, _excluded3);
|
|
98
102
|
|
|
99
103
|
var _getOverrides2 = getOverrides('Content'),
|
|
100
104
|
Content = _getOverrides2.component,
|
|
101
|
-
contentOverrides = _objectWithoutProperties(_getOverrides2,
|
|
105
|
+
contentOverrides = _objectWithoutProperties(_getOverrides2, _excluded4);
|
|
102
106
|
|
|
103
107
|
return jsx(Slide, _extends({
|
|
104
108
|
component: Wrapper,
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
|
+
var _excluded = ["cssFn"];
|
|
3
4
|
|
|
4
5
|
/** @jsx jsx */
|
|
5
6
|
import { jsx } from '@emotion/core';
|
|
@@ -8,7 +9,7 @@ import { gridSize } from '@atlaskit/theme/constants';
|
|
|
8
9
|
var defaultStyle = {
|
|
9
10
|
alignItems: 'center',
|
|
10
11
|
boxSizing: 'border-box',
|
|
11
|
-
color: N500,
|
|
12
|
+
color: "var(--ds-text-mediumEmphasis, ".concat(N500, ")"),
|
|
12
13
|
display: 'flex',
|
|
13
14
|
flexShrink: 0,
|
|
14
15
|
flexDirection: 'column',
|
|
@@ -24,7 +25,7 @@ var sidebarCSS = function sidebarCSS() {
|
|
|
24
25
|
|
|
25
26
|
var Sidebar = function Sidebar(_ref) {
|
|
26
27
|
var cssFn = _ref.cssFn,
|
|
27
|
-
props = _objectWithoutProperties(_ref,
|
|
28
|
+
props = _objectWithoutProperties(_ref, _excluded);
|
|
28
29
|
|
|
29
30
|
// eslint-disable-next-line @repo/internal/react/consistent-css-prop-usage
|
|
30
31
|
return jsx("div", _extends({
|
|
@@ -7,10 +7,12 @@ import _inherits from "@babel/runtime/helpers/inherits";
|
|
|
7
7
|
import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
|
|
8
8
|
import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
|
|
9
9
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
10
|
+
var _excluded = ["component", "in", "onExited", "onEntered", "defaultStyles", "transitionStyles", "transitionProps"],
|
|
11
|
+
_excluded2 = ["shouldUnmountOnExit"];
|
|
10
12
|
|
|
11
|
-
function ownKeys(object, enumerableOnly) { var keys = Object.keys(object); if (Object.getOwnPropertySymbols) { var symbols = Object.getOwnPropertySymbols(object);
|
|
13
|
+
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; }
|
|
12
14
|
|
|
13
|
-
function _objectSpread(target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]
|
|
15
|
+
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; }
|
|
14
16
|
|
|
15
17
|
function _createSuper(Derived) { var hasNativeReflectConstruct = _isNativeReflectConstruct(); return function _createSuperInternal() { var Super = _getPrototypeOf(Derived), result; if (hasNativeReflectConstruct) { var NewTarget = _getPrototypeOf(this).constructor; result = Reflect.construct(Super, arguments, NewTarget); } else { result = Super.apply(this, arguments); } return _possibleConstructorReturn(this, result); }; }
|
|
16
18
|
|
|
@@ -82,7 +84,7 @@ var TransitionHandler = /*#__PURE__*/function (_Component) {
|
|
|
82
84
|
defaultStyles = _this$props.defaultStyles,
|
|
83
85
|
transitionStyles = _this$props.transitionStyles,
|
|
84
86
|
transitionProps = _this$props.transitionProps,
|
|
85
|
-
props = _objectWithoutProperties(_this$props,
|
|
87
|
+
props = _objectWithoutProperties(_this$props, _excluded);
|
|
86
88
|
|
|
87
89
|
var timeout = {
|
|
88
90
|
enter: 0,
|
|
@@ -136,7 +138,7 @@ export var Fade = function Fade(_ref) {
|
|
|
136
138
|
export var Slide = function Slide(_ref2) {
|
|
137
139
|
var _ref2$shouldUnmountOn = _ref2.shouldUnmountOnExit,
|
|
138
140
|
shouldUnmountOnExit = _ref2$shouldUnmountOn === void 0 ? true : _ref2$shouldUnmountOn,
|
|
139
|
-
props = _objectWithoutProperties(_ref2,
|
|
141
|
+
props = _objectWithoutProperties(_ref2, _excluded2);
|
|
140
142
|
|
|
141
143
|
return /*#__PURE__*/React.createElement(TransitionHandler, _extends({
|
|
142
144
|
defaultStyles: {
|
package/dist/esm/version.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/drawer",
|
|
3
|
-
"version": "7.
|
|
3
|
+
"version": "7.1.2",
|
|
4
4
|
"description": "React component the renders a Drawer from the left of the screen",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -17,7 +17,6 @@
|
|
|
17
17
|
"atlassian": {
|
|
18
18
|
"team": "Design System Team",
|
|
19
19
|
"deprecatedAutoEntryPoints": true,
|
|
20
|
-
"inPublicMirror": true,
|
|
21
20
|
"releaseModel": "scheduled",
|
|
22
21
|
"website": {
|
|
23
22
|
"name": "Drawer"
|
|
@@ -26,13 +25,14 @@
|
|
|
26
25
|
"dependencies": {
|
|
27
26
|
"@atlaskit/analytics-next": "^8.2.0",
|
|
28
27
|
"@atlaskit/blanket": "^12.1.0",
|
|
29
|
-
"@atlaskit/icon": "^21.
|
|
28
|
+
"@atlaskit/icon": "^21.10.0",
|
|
30
29
|
"@atlaskit/portal": "^4.0.0",
|
|
31
|
-
"@atlaskit/theme": "^12.
|
|
30
|
+
"@atlaskit/theme": "^12.1.0",
|
|
31
|
+
"@atlaskit/tokens": "^0.5.0",
|
|
32
32
|
"@babel/runtime": "^7.0.0",
|
|
33
33
|
"@emotion/core": "^10.0.9",
|
|
34
34
|
"exenv": "^1.2.2",
|
|
35
|
-
"react-focus-lock": "^
|
|
35
|
+
"react-focus-lock": "^2.5.2",
|
|
36
36
|
"react-transition-group": "^4.4.1",
|
|
37
37
|
"tiny-invariant": "^0.0.3"
|
|
38
38
|
},
|
|
@@ -40,18 +40,17 @@
|
|
|
40
40
|
"react": "^16.8.0"
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
|
-
"@atlaskit/build-utils": "*",
|
|
44
43
|
"@atlaskit/button": "^16.0.0",
|
|
45
44
|
"@atlaskit/docs": "*",
|
|
46
|
-
"@atlaskit/dropdown-menu": "^
|
|
47
|
-
"@atlaskit/menu": "^1.0
|
|
45
|
+
"@atlaskit/dropdown-menu": "^11.0.0",
|
|
46
|
+
"@atlaskit/menu": "^1.2.0",
|
|
48
47
|
"@atlaskit/section-message": "^6.0.0",
|
|
49
48
|
"@atlaskit/ssr": "*",
|
|
50
49
|
"@atlaskit/visual-regression": "*",
|
|
51
50
|
"@atlaskit/webdriver-runner": "*",
|
|
52
51
|
"@atlassian/atlassian-frontend-prettier-config-1.0.1": "npm:@atlassian/atlassian-frontend-prettier-config@1.0.1",
|
|
53
52
|
"enzyme": "^3.10.0",
|
|
54
|
-
"lodash": "^4.17.
|
|
53
|
+
"lodash": "^4.17.21",
|
|
55
54
|
"react-dom": "^16.8.0",
|
|
56
55
|
"react-lorem-component": "^0.13.0",
|
|
57
56
|
"typescript": "3.9.6",
|
|
@@ -63,7 +62,11 @@
|
|
|
63
62
|
},
|
|
64
63
|
"@repo/internal": {
|
|
65
64
|
"analytics": "analytics-next",
|
|
66
|
-
"
|
|
65
|
+
"theming": "tokens",
|
|
66
|
+
"styling": [
|
|
67
|
+
"static",
|
|
68
|
+
"emotion"
|
|
69
|
+
],
|
|
67
70
|
"deprecation": "no-deprecated-imports"
|
|
68
71
|
}
|
|
69
72
|
},
|