@atlaskit/dropdown-menu 16.0.5 → 16.0.7
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 +15 -0
- package/dist/cjs/checkbox/dropdown-item-checkbox.js +2 -3
- package/dist/cjs/dropdown-menu-item.js +6 -7
- package/dist/cjs/dropdown-menu.js +1 -2
- package/dist/cjs/radio/dropdown-item-radio.js +2 -3
- package/dist/es2019/checkbox/dropdown-item-checkbox.js +3 -4
- package/dist/es2019/dropdown-menu-item.js +9 -10
- package/dist/es2019/dropdown-menu.js +2 -3
- package/dist/es2019/radio/dropdown-item-radio.js +3 -4
- package/dist/esm/checkbox/dropdown-item-checkbox.js +2 -3
- package/dist/esm/dropdown-menu-item.js +6 -7
- package/dist/esm/dropdown-menu.js +1 -2
- package/dist/esm/radio/dropdown-item-radio.js +2 -3
- package/package.json +2 -5
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,20 @@
|
|
|
1
1
|
# @atlaskit/dropdown-menu
|
|
2
2
|
|
|
3
|
+
## 16.0.7
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 16.0.6
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [#171641](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/171641)
|
|
14
|
+
[`1d4741f638def`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/1d4741f638def) -
|
|
15
|
+
Removed UFO metric interactionName FG from platform
|
|
16
|
+
- Updated dependencies
|
|
17
|
+
|
|
3
18
|
## 16.0.5
|
|
4
19
|
|
|
5
20
|
### Patch Changes
|
|
@@ -13,7 +13,6 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
13
13
|
var _noop = _interopRequireDefault(require("@atlaskit/ds-lib/noop"));
|
|
14
14
|
var _menu = require("@atlaskit/menu");
|
|
15
15
|
var _buttonItem = _interopRequireDefault(require("@atlaskit/menu/button-item"));
|
|
16
|
-
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
17
16
|
var _checkboxIcon = _interopRequireDefault(require("../internal/components/checkbox-icon"));
|
|
18
17
|
var _useCheckboxState3 = _interopRequireDefault(require("../internal/hooks/use-checkbox-state"));
|
|
19
18
|
var _useRegisterItemWithFocusManager = _interopRequireDefault(require("../internal/hooks/use-register-item-with-focus-manager"));
|
|
@@ -79,9 +78,9 @@ var DropdownItemCheckbox = function DropdownItemCheckbox(_ref) {
|
|
|
79
78
|
role: "menuitemcheckbox",
|
|
80
79
|
shouldDescriptionWrap: shouldDescriptionWrap,
|
|
81
80
|
shouldTitleWrap: shouldTitleWrap,
|
|
82
|
-
testId: testId
|
|
83
|
-
}, (0, _platformFeatureFlags.fg)('platform_button_item-add-ufo-metrics') && {
|
|
81
|
+
testId: testId,
|
|
84
82
|
interactionName: interactionName
|
|
83
|
+
// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
85
84
|
}, rest), children));
|
|
86
85
|
};
|
|
87
86
|
var _default = exports.default = DropdownItemCheckbox;
|
|
@@ -13,7 +13,6 @@ var _mergeRefs = _interopRequireDefault(require("@atlaskit/ds-lib/merge-refs"));
|
|
|
13
13
|
var _buttonItem = _interopRequireDefault(require("@atlaskit/menu/button-item"));
|
|
14
14
|
var _customItem = _interopRequireDefault(require("@atlaskit/menu/custom-item"));
|
|
15
15
|
var _linkItem = _interopRequireDefault(require("@atlaskit/menu/link-item"));
|
|
16
|
-
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
17
16
|
var _useRegisterItemWithFocusManager = _interopRequireDefault(require("./internal/hooks/use-register-item-with-focus-manager"));
|
|
18
17
|
var _excluded = ["children", "component", "description", "elemAfter", "elemBefore", "href", "isDisabled", "isSelected", "onClick", "rel", "shouldDescriptionWrap", "shouldTitleWrap", "target", "testId", "UNSAFE_shouldDisableRouterLink", "returnFocusRef", "interactionName", "role"];
|
|
19
18
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
@@ -78,9 +77,9 @@ var DropdownMenuItem = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref)
|
|
|
78
77
|
// @ts-expect-error
|
|
79
78
|
,
|
|
80
79
|
target: target,
|
|
81
|
-
rel: rel
|
|
82
|
-
}, (0, _platformFeatureFlags.fg)('platform_button_item-add-ufo-metrics') && {
|
|
80
|
+
rel: rel,
|
|
83
81
|
interactionName: interactionName
|
|
82
|
+
// DSP-13312 TODO: remove spread props in future major release
|
|
84
83
|
}, rest), children);
|
|
85
84
|
} else if (href) {
|
|
86
85
|
return /*#__PURE__*/_react.default.createElement(_linkItem.default, (0, _extends2.default)({
|
|
@@ -98,9 +97,9 @@ var DropdownMenuItem = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref)
|
|
|
98
97
|
shouldTitleWrap: shouldTitleWrap,
|
|
99
98
|
target: target,
|
|
100
99
|
testId: testId,
|
|
101
|
-
UNSAFE_shouldDisableRouterLink: UNSAFE_shouldDisableRouterLink
|
|
102
|
-
}, (0, _platformFeatureFlags.fg)('platform_button_item-add-ufo-metrics') && {
|
|
100
|
+
UNSAFE_shouldDisableRouterLink: UNSAFE_shouldDisableRouterLink,
|
|
103
101
|
interactionName: interactionName
|
|
102
|
+
// DSP-13312 TODO: remove spread props in future major release
|
|
104
103
|
}, rest), children);
|
|
105
104
|
} else {
|
|
106
105
|
return /*#__PURE__*/_react.default.createElement(_buttonItem.default, (0, _extends2.default)({
|
|
@@ -120,9 +119,9 @@ var DropdownMenuItem = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref)
|
|
|
120
119
|
// @ts-expect-error
|
|
121
120
|
,
|
|
122
121
|
target: target,
|
|
123
|
-
rel: rel
|
|
124
|
-
}, (0, _platformFeatureFlags.fg)('platform_button_item-add-ufo-metrics') && {
|
|
122
|
+
rel: rel,
|
|
125
123
|
interactionName: interactionName
|
|
124
|
+
// DSP-13312 TODO: remove spread props in future major release
|
|
126
125
|
}, rest), children);
|
|
127
126
|
}
|
|
128
127
|
});
|
|
@@ -310,8 +310,7 @@ var DropdownMenu = function DropdownMenu(_ref) {
|
|
|
310
310
|
},
|
|
311
311
|
onClick: handleTriggerClicked,
|
|
312
312
|
testId: testId && "".concat(testId, "--trigger"),
|
|
313
|
-
"aria-label": label
|
|
314
|
-
}, (0, _platformFeatureFlags.fg)('platform_button_item-add-ufo-metrics') && {
|
|
313
|
+
"aria-label": label,
|
|
315
314
|
interactionName: interactionName
|
|
316
315
|
}), _trigger);
|
|
317
316
|
},
|
|
@@ -13,7 +13,6 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
13
13
|
var _noop = _interopRequireDefault(require("@atlaskit/ds-lib/noop"));
|
|
14
14
|
var _menu = require("@atlaskit/menu");
|
|
15
15
|
var _buttonItem = _interopRequireDefault(require("@atlaskit/menu/button-item"));
|
|
16
|
-
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
17
16
|
var _radioIcon = _interopRequireDefault(require("../internal/components/radio-icon"));
|
|
18
17
|
var _useRadioState3 = _interopRequireDefault(require("../internal/hooks/use-radio-state"));
|
|
19
18
|
var _useRegisterItemWithFocusManager = _interopRequireDefault(require("../internal/hooks/use-register-item-with-focus-manager"));
|
|
@@ -86,9 +85,9 @@ var DropdownItemRadio = function DropdownItemRadio(_ref) {
|
|
|
86
85
|
// it's not in the component's prop types.
|
|
87
86
|
// @ts-expect-error
|
|
88
87
|
,
|
|
89
|
-
title: title
|
|
90
|
-
}, (0, _platformFeatureFlags.fg)('platform_button_item-add-ufo-metrics') && {
|
|
88
|
+
title: title,
|
|
91
89
|
interactionName: interactionName
|
|
90
|
+
// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
92
91
|
}, rest), children));
|
|
93
92
|
};
|
|
94
93
|
var _default = exports.default = DropdownItemRadio;
|
|
@@ -3,7 +3,6 @@ import React, { useCallback } from 'react';
|
|
|
3
3
|
import noop from '@atlaskit/ds-lib/noop';
|
|
4
4
|
import { SELECTION_STYLE_CONTEXT_DO_NOT_USE } from '@atlaskit/menu';
|
|
5
5
|
import ButtonItem from '@atlaskit/menu/button-item';
|
|
6
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
7
6
|
import CheckboxIcon from '../internal/components/checkbox-icon';
|
|
8
7
|
import useCheckboxState from '../internal/hooks/use-checkbox-state';
|
|
9
8
|
import useRegisterItemWithFocusManager from '../internal/hooks/use-register-item-with-focus-manager';
|
|
@@ -61,9 +60,9 @@ const DropdownItemCheckbox = ({
|
|
|
61
60
|
role: "menuitemcheckbox",
|
|
62
61
|
shouldDescriptionWrap: shouldDescriptionWrap,
|
|
63
62
|
shouldTitleWrap: shouldTitleWrap,
|
|
64
|
-
testId: testId
|
|
65
|
-
|
|
66
|
-
|
|
63
|
+
testId: testId,
|
|
64
|
+
interactionName: interactionName
|
|
65
|
+
// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
67
66
|
}, rest), children));
|
|
68
67
|
};
|
|
69
68
|
export default DropdownItemCheckbox;
|
|
@@ -4,7 +4,6 @@ import mergeRefs from '@atlaskit/ds-lib/merge-refs';
|
|
|
4
4
|
import ButtonItem from '@atlaskit/menu/button-item';
|
|
5
5
|
import CustomItem from '@atlaskit/menu/custom-item';
|
|
6
6
|
import LinkItem from '@atlaskit/menu/link-item';
|
|
7
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
7
|
import useRegisterItemWithFocusManager from './internal/hooks/use-register-item-with-focus-manager';
|
|
9
8
|
/**
|
|
10
9
|
* __Dropdown menu item__
|
|
@@ -66,9 +65,9 @@ const DropdownMenuItem = /*#__PURE__*/forwardRef(({
|
|
|
66
65
|
// @ts-expect-error
|
|
67
66
|
,
|
|
68
67
|
target: target,
|
|
69
|
-
rel: rel
|
|
70
|
-
|
|
71
|
-
|
|
68
|
+
rel: rel,
|
|
69
|
+
interactionName: interactionName
|
|
70
|
+
// DSP-13312 TODO: remove spread props in future major release
|
|
72
71
|
}, rest), children);
|
|
73
72
|
} else if (href) {
|
|
74
73
|
return /*#__PURE__*/React.createElement(LinkItem, _extends({
|
|
@@ -86,9 +85,9 @@ const DropdownMenuItem = /*#__PURE__*/forwardRef(({
|
|
|
86
85
|
shouldTitleWrap: shouldTitleWrap,
|
|
87
86
|
target: target,
|
|
88
87
|
testId: testId,
|
|
89
|
-
UNSAFE_shouldDisableRouterLink: UNSAFE_shouldDisableRouterLink
|
|
90
|
-
|
|
91
|
-
|
|
88
|
+
UNSAFE_shouldDisableRouterLink: UNSAFE_shouldDisableRouterLink,
|
|
89
|
+
interactionName: interactionName
|
|
90
|
+
// DSP-13312 TODO: remove spread props in future major release
|
|
92
91
|
}, rest), children);
|
|
93
92
|
} else {
|
|
94
93
|
return /*#__PURE__*/React.createElement(ButtonItem, _extends({
|
|
@@ -108,9 +107,9 @@ const DropdownMenuItem = /*#__PURE__*/forwardRef(({
|
|
|
108
107
|
// @ts-expect-error
|
|
109
108
|
,
|
|
110
109
|
target: target,
|
|
111
|
-
rel: rel
|
|
112
|
-
|
|
113
|
-
|
|
110
|
+
rel: rel,
|
|
111
|
+
interactionName: interactionName
|
|
112
|
+
// DSP-13312 TODO: remove spread props in future major release
|
|
114
113
|
}, rest), children);
|
|
115
114
|
}
|
|
116
115
|
});
|
|
@@ -282,9 +282,8 @@ const DropdownMenu = ({
|
|
|
282
282
|
})),
|
|
283
283
|
onClick: handleTriggerClicked,
|
|
284
284
|
testId: testId && `${testId}--trigger`,
|
|
285
|
-
"aria-label": label
|
|
286
|
-
|
|
287
|
-
interactionName
|
|
285
|
+
"aria-label": label,
|
|
286
|
+
interactionName: interactionName
|
|
288
287
|
}), trigger);
|
|
289
288
|
},
|
|
290
289
|
content: ({
|
|
@@ -3,7 +3,6 @@ import React, { useCallback } from 'react';
|
|
|
3
3
|
import noop from '@atlaskit/ds-lib/noop';
|
|
4
4
|
import { SELECTION_STYLE_CONTEXT_DO_NOT_USE } from '@atlaskit/menu';
|
|
5
5
|
import ButtonItem from '@atlaskit/menu/button-item';
|
|
6
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
7
6
|
import RadioIcon from '../internal/components/radio-icon';
|
|
8
7
|
import useRadioState from '../internal/hooks/use-radio-state';
|
|
9
8
|
import useRegisterItemWithFocusManager from '../internal/hooks/use-register-item-with-focus-manager';
|
|
@@ -68,9 +67,9 @@ const DropdownItemRadio = ({
|
|
|
68
67
|
// it's not in the component's prop types.
|
|
69
68
|
// @ts-expect-error
|
|
70
69
|
,
|
|
71
|
-
title: title
|
|
72
|
-
|
|
73
|
-
|
|
70
|
+
title: title,
|
|
71
|
+
interactionName: interactionName
|
|
72
|
+
// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
74
73
|
}, rest), children));
|
|
75
74
|
};
|
|
76
75
|
export default DropdownItemRadio;
|
|
@@ -6,7 +6,6 @@ import React, { useCallback } from 'react';
|
|
|
6
6
|
import noop from '@atlaskit/ds-lib/noop';
|
|
7
7
|
import { SELECTION_STYLE_CONTEXT_DO_NOT_USE } from '@atlaskit/menu';
|
|
8
8
|
import ButtonItem from '@atlaskit/menu/button-item';
|
|
9
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
10
9
|
import CheckboxIcon from '../internal/components/checkbox-icon';
|
|
11
10
|
import useCheckboxState from '../internal/hooks/use-checkbox-state';
|
|
12
11
|
import useRegisterItemWithFocusManager from '../internal/hooks/use-register-item-with-focus-manager';
|
|
@@ -70,9 +69,9 @@ var DropdownItemCheckbox = function DropdownItemCheckbox(_ref) {
|
|
|
70
69
|
role: "menuitemcheckbox",
|
|
71
70
|
shouldDescriptionWrap: shouldDescriptionWrap,
|
|
72
71
|
shouldTitleWrap: shouldTitleWrap,
|
|
73
|
-
testId: testId
|
|
74
|
-
}, fg('platform_button_item-add-ufo-metrics') && {
|
|
72
|
+
testId: testId,
|
|
75
73
|
interactionName: interactionName
|
|
74
|
+
// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
76
75
|
}, rest), children));
|
|
77
76
|
};
|
|
78
77
|
export default DropdownItemCheckbox;
|
|
@@ -6,7 +6,6 @@ import mergeRefs from '@atlaskit/ds-lib/merge-refs';
|
|
|
6
6
|
import ButtonItem from '@atlaskit/menu/button-item';
|
|
7
7
|
import CustomItem from '@atlaskit/menu/custom-item';
|
|
8
8
|
import LinkItem from '@atlaskit/menu/link-item';
|
|
9
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
10
9
|
import useRegisterItemWithFocusManager from './internal/hooks/use-register-item-with-focus-manager';
|
|
11
10
|
/**
|
|
12
11
|
* __Dropdown menu item__
|
|
@@ -69,9 +68,9 @@ var DropdownMenuItem = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
69
68
|
// @ts-expect-error
|
|
70
69
|
,
|
|
71
70
|
target: target,
|
|
72
|
-
rel: rel
|
|
73
|
-
}, fg('platform_button_item-add-ufo-metrics') && {
|
|
71
|
+
rel: rel,
|
|
74
72
|
interactionName: interactionName
|
|
73
|
+
// DSP-13312 TODO: remove spread props in future major release
|
|
75
74
|
}, rest), children);
|
|
76
75
|
} else if (href) {
|
|
77
76
|
return /*#__PURE__*/React.createElement(LinkItem, _extends({
|
|
@@ -89,9 +88,9 @@ var DropdownMenuItem = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
89
88
|
shouldTitleWrap: shouldTitleWrap,
|
|
90
89
|
target: target,
|
|
91
90
|
testId: testId,
|
|
92
|
-
UNSAFE_shouldDisableRouterLink: UNSAFE_shouldDisableRouterLink
|
|
93
|
-
}, fg('platform_button_item-add-ufo-metrics') && {
|
|
91
|
+
UNSAFE_shouldDisableRouterLink: UNSAFE_shouldDisableRouterLink,
|
|
94
92
|
interactionName: interactionName
|
|
93
|
+
// DSP-13312 TODO: remove spread props in future major release
|
|
95
94
|
}, rest), children);
|
|
96
95
|
} else {
|
|
97
96
|
return /*#__PURE__*/React.createElement(ButtonItem, _extends({
|
|
@@ -111,9 +110,9 @@ var DropdownMenuItem = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
|
111
110
|
// @ts-expect-error
|
|
112
111
|
,
|
|
113
112
|
target: target,
|
|
114
|
-
rel: rel
|
|
115
|
-
}, fg('platform_button_item-add-ufo-metrics') && {
|
|
113
|
+
rel: rel,
|
|
116
114
|
interactionName: interactionName
|
|
115
|
+
// DSP-13312 TODO: remove spread props in future major release
|
|
117
116
|
}, rest), children);
|
|
118
117
|
}
|
|
119
118
|
});
|
|
@@ -302,8 +302,7 @@ var DropdownMenu = function DropdownMenu(_ref) {
|
|
|
302
302
|
},
|
|
303
303
|
onClick: handleTriggerClicked,
|
|
304
304
|
testId: testId && "".concat(testId, "--trigger"),
|
|
305
|
-
"aria-label": label
|
|
306
|
-
}, fg('platform_button_item-add-ufo-metrics') && {
|
|
305
|
+
"aria-label": label,
|
|
307
306
|
interactionName: interactionName
|
|
308
307
|
}), _trigger);
|
|
309
308
|
},
|
|
@@ -6,7 +6,6 @@ import React, { useCallback } from 'react';
|
|
|
6
6
|
import noop from '@atlaskit/ds-lib/noop';
|
|
7
7
|
import { SELECTION_STYLE_CONTEXT_DO_NOT_USE } from '@atlaskit/menu';
|
|
8
8
|
import ButtonItem from '@atlaskit/menu/button-item';
|
|
9
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
10
9
|
import RadioIcon from '../internal/components/radio-icon';
|
|
11
10
|
import useRadioState from '../internal/hooks/use-radio-state';
|
|
12
11
|
import useRegisterItemWithFocusManager from '../internal/hooks/use-register-item-with-focus-manager';
|
|
@@ -77,9 +76,9 @@ var DropdownItemRadio = function DropdownItemRadio(_ref) {
|
|
|
77
76
|
// it's not in the component's prop types.
|
|
78
77
|
// @ts-expect-error
|
|
79
78
|
,
|
|
80
|
-
title: title
|
|
81
|
-
}, fg('platform_button_item-add-ufo-metrics') && {
|
|
79
|
+
title: title,
|
|
82
80
|
interactionName: interactionName
|
|
81
|
+
// eslint-disable-next-line @repo/internal/react/no-unsafe-spread-props
|
|
83
82
|
}, rest), children));
|
|
84
83
|
};
|
|
85
84
|
export default DropdownItemRadio;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/dropdown-menu",
|
|
3
|
-
"version": "16.0.
|
|
3
|
+
"version": "16.0.7",
|
|
4
4
|
"description": "A dropdown menu displays a list of actions or options to a user.",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"@atlaskit/button": "^23.2.0",
|
|
29
29
|
"@atlaskit/css": "^0.10.0",
|
|
30
30
|
"@atlaskit/ds-lib": "^4.0.0",
|
|
31
|
-
"@atlaskit/icon": "^
|
|
31
|
+
"@atlaskit/icon": "^27.0.0",
|
|
32
32
|
"@atlaskit/layering": "^3.0.0",
|
|
33
33
|
"@atlaskit/menu": "^8.0.0",
|
|
34
34
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
@@ -77,9 +77,6 @@
|
|
|
77
77
|
"platform_dst_popup-disable-focuslock": {
|
|
78
78
|
"type": "boolean"
|
|
79
79
|
},
|
|
80
|
-
"platform_button_item-add-ufo-metrics": {
|
|
81
|
-
"type": "boolean"
|
|
82
|
-
},
|
|
83
80
|
"platform-visual-refresh-icons": {
|
|
84
81
|
"type": "boolean"
|
|
85
82
|
},
|