@atlaskit/link-datasource 4.32.0 → 4.32.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 +17 -0
- package/dist/cjs/ui/assets-modal/search-container/aql-search-input/index.js +0 -5
- package/dist/cjs/ui/common/modal/basic-search-input/index.js +0 -1
- package/dist/cjs/ui/common/modal/popup-select/formatOptionLabel.js +0 -1
- package/dist/cjs/ui/common/modal/popup-select/index.js +2 -0
- package/dist/cjs/ui/common/modal/popup-select/trigger.js +36 -1
- package/dist/cjs/ui/issue-like-table/edit-type/icon/index.js +3 -1
- package/dist/cjs/ui/issue-like-table/edit-type/status/index.js +3 -1
- package/dist/cjs/ui/issue-like-table/edit-type/user/index.js +3 -1
- package/dist/es2019/ui/assets-modal/search-container/aql-search-input/index.js +0 -5
- package/dist/es2019/ui/common/modal/basic-search-input/index.js +0 -1
- package/dist/es2019/ui/common/modal/popup-select/formatOptionLabel.js +0 -1
- package/dist/es2019/ui/common/modal/popup-select/index.js +2 -0
- package/dist/es2019/ui/common/modal/popup-select/trigger.js +31 -2
- package/dist/es2019/ui/issue-like-table/edit-type/icon/index.js +3 -1
- package/dist/es2019/ui/issue-like-table/edit-type/status/index.js +3 -1
- package/dist/es2019/ui/issue-like-table/edit-type/user/index.js +3 -1
- package/dist/esm/ui/assets-modal/search-container/aql-search-input/index.js +0 -5
- package/dist/esm/ui/common/modal/basic-search-input/index.js +0 -1
- package/dist/esm/ui/common/modal/popup-select/formatOptionLabel.js +0 -1
- package/dist/esm/ui/common/modal/popup-select/index.js +2 -0
- package/dist/esm/ui/common/modal/popup-select/trigger.js +37 -2
- package/dist/esm/ui/issue-like-table/edit-type/icon/index.js +3 -1
- package/dist/esm/ui/issue-like-table/edit-type/status/index.js +3 -1
- package/dist/esm/ui/issue-like-table/edit-type/user/index.js +3 -1
- package/dist/types/ui/common/modal/popup-select/trigger.d.ts +1 -1
- package/dist/types/ui/issue-like-table/types.d.ts +1 -1
- package/dist/types-ts4.5/ui/common/modal/popup-select/trigger.d.ts +1 -1
- package/dist/types-ts4.5/ui/issue-like-table/types.d.ts +1 -1
- package/examples-helpers/buildIssueLikeTable.tsx +5 -8
- package/examples-helpers/fakeModalDialogContainer.tsx +28 -0
- package/package.json +8 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,22 @@
|
|
|
1
1
|
# @atlaskit/link-datasource
|
|
2
2
|
|
|
3
|
+
## 4.32.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`ebd1d53e42731`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/ebd1d53e42731) -
|
|
8
|
+
[ux] Fix a bug where pressing escape when dropdowns inside modal dialog are opened is closing the
|
|
9
|
+
modal dialog itself. Behind platform_navx_sllv_dropdown_escape_and_focus_fix FG
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
12
|
+
## 4.32.1
|
|
13
|
+
|
|
14
|
+
### Patch Changes
|
|
15
|
+
|
|
16
|
+
- [`1d8c8a19192b2`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/1d8c8a19192b2) -
|
|
17
|
+
[ux] For Jira inlne editing dropdown (status, assignee) are now show over the edge of scrallable
|
|
18
|
+
table. Behind FG platform_navx_sllv_j2ws_dropdown_for_single_row
|
|
19
|
+
|
|
3
20
|
## 4.32.0
|
|
4
21
|
|
|
5
22
|
### Minor Changes
|
|
@@ -61,7 +61,6 @@ var renderValidatorIcon = function renderValidatorIcon(lastValidationResult) {
|
|
|
61
61
|
return /*#__PURE__*/React.createElement(_crossCircle.default, {
|
|
62
62
|
label: "label",
|
|
63
63
|
color: "var(--ds-icon-danger, ".concat(_colors.R400, ")"),
|
|
64
|
-
LEGACY_size: "medium",
|
|
65
64
|
testId: "assets-datasource-modal--aql-invalid",
|
|
66
65
|
spacing: "spacious"
|
|
67
66
|
});
|
|
@@ -70,14 +69,12 @@ var renderValidatorIcon = function renderValidatorIcon(lastValidationResult) {
|
|
|
70
69
|
return /*#__PURE__*/React.createElement(_statusSuccess.default, {
|
|
71
70
|
label: "label",
|
|
72
71
|
color: "var(--ds-icon-success, ".concat(_colors.G300, ")"),
|
|
73
|
-
LEGACY_size: "medium",
|
|
74
72
|
testId: "assets-datasource-modal--aql-valid",
|
|
75
73
|
spacing: "spacious"
|
|
76
74
|
});
|
|
77
75
|
}
|
|
78
76
|
return /*#__PURE__*/React.createElement(_search.default, {
|
|
79
77
|
label: "label",
|
|
80
|
-
LEGACY_size: "medium",
|
|
81
78
|
testId: "assets-datasource-modal--aql-idle",
|
|
82
79
|
color: "currentColor",
|
|
83
80
|
spacing: "spacious"
|
|
@@ -119,7 +116,6 @@ var AqlSearchInput = exports.AqlSearchInput = function AqlSearchInput(_ref2) {
|
|
|
119
116
|
}, /*#__PURE__*/React.createElement(_questionCircle.default, {
|
|
120
117
|
label: "label",
|
|
121
118
|
color: "var(--ds-icon, ".concat(_colors.N500, ")"),
|
|
122
|
-
LEGACY_size: "medium",
|
|
123
119
|
testId: "assets-datasource-modal-help",
|
|
124
120
|
spacing: "spacious"
|
|
125
121
|
}))), /*#__PURE__*/React.createElement(_compiled.Box, {
|
|
@@ -129,7 +125,6 @@ var AqlSearchInput = exports.AqlSearchInput = function AqlSearchInput(_ref2) {
|
|
|
129
125
|
isLoading: isSearching,
|
|
130
126
|
icon: function icon(iconProps) {
|
|
131
127
|
return /*#__PURE__*/React.createElement(_search.default, (0, _extends2.default)({}, iconProps, {
|
|
132
|
-
LEGACY_size: "medium",
|
|
133
128
|
spacing: "spacious",
|
|
134
129
|
color: "currentColor"
|
|
135
130
|
}));
|
|
@@ -57,7 +57,6 @@ var BasicSearchInput = exports.BasicSearchInput = function BasicSearchInput(_ref
|
|
|
57
57
|
isLoading: isSearching,
|
|
58
58
|
icon: function icon(iconProps) {
|
|
59
59
|
return /*#__PURE__*/React.createElement(_search.default, (0, _extends2.default)({}, iconProps, {
|
|
60
|
-
LEGACY_size: "medium",
|
|
61
60
|
spacing: "spacious",
|
|
62
61
|
color: "currentColor"
|
|
63
62
|
}));
|
|
@@ -59,7 +59,6 @@ var AvatarOptionLabel = function AvatarOptionLabel(_ref3) {
|
|
|
59
59
|
xcss: styles.groupWrapperStyles
|
|
60
60
|
}, /*#__PURE__*/_react.default.createElement(_peopleGroup.default, {
|
|
61
61
|
color: "currentColor",
|
|
62
|
-
LEGACY_size: "small",
|
|
63
62
|
label: ""
|
|
64
63
|
})) : /*#__PURE__*/_react.default.createElement(_avatar.default, {
|
|
65
64
|
appearance: data.isSquare ? 'square' : 'circle',
|
|
@@ -16,6 +16,7 @@ var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/sli
|
|
|
16
16
|
var _react = _interopRequireWildcard(require("react"));
|
|
17
17
|
var _isEqual = _interopRequireDefault(require("lodash/isEqual"));
|
|
18
18
|
var _reactIntlNext = require("react-intl-next");
|
|
19
|
+
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
19
20
|
var _select = require("@atlaskit/select");
|
|
20
21
|
var _analytics = require("../../../../analytics");
|
|
21
22
|
var _control = _interopRequireDefault(require("./control"));
|
|
@@ -223,6 +224,7 @@ var FilterPopupSelect = exports.FilterPopupSelect = function FilterPopupSelect(_
|
|
|
223
224
|
onInputChange: handleInputChange,
|
|
224
225
|
onOpen: handleMenuOpen,
|
|
225
226
|
onClose: handleMenuClose,
|
|
227
|
+
shouldPreventEscapePropagation: (0, _platformFeatureFlags.fg)('platform_navx_sllv_dropdown_escape_and_focus_fix'),
|
|
226
228
|
target: function target(_ref3) {
|
|
227
229
|
var isOpen = _ref3.isOpen,
|
|
228
230
|
triggerProps = (0, _objectWithoutProperties2.default)(_ref3, _excluded);
|
|
@@ -17,6 +17,7 @@ var _badge = _interopRequireDefault(require("@atlaskit/badge"));
|
|
|
17
17
|
var _new = _interopRequireDefault(require("@atlaskit/button/new"));
|
|
18
18
|
var _standardButton = _interopRequireDefault(require("@atlaskit/button/standard-button"));
|
|
19
19
|
var _chevronDown = _interopRequireDefault(require("@atlaskit/icon/core/chevron-down"));
|
|
20
|
+
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
20
21
|
var _compiled = require("@atlaskit/primitives/compiled");
|
|
21
22
|
var _spinner = _interopRequireDefault(require("@atlaskit/spinner"));
|
|
22
23
|
var _excluded = ["as", "style"];
|
|
@@ -62,6 +63,15 @@ var PopupTrigger = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2, ref) {
|
|
|
62
63
|
testId: "".concat(triggerButtonTestId, "--loading-button")
|
|
63
64
|
}, label));
|
|
64
65
|
}, [label, triggerButtonTestId]);
|
|
66
|
+
var loadingButton = (0, _react.useMemo)(function () {
|
|
67
|
+
return /*#__PURE__*/_react.default.createElement(LoadingStateAnimationWrapper, null, /*#__PURE__*/_react.default.createElement(_standardButton.default, {
|
|
68
|
+
ref: ref,
|
|
69
|
+
iconAfter: /*#__PURE__*/_react.default.createElement(_spinner.default, {
|
|
70
|
+
size: 'xsmall'
|
|
71
|
+
}),
|
|
72
|
+
testId: "".concat(triggerButtonTestId, "--loading-button")
|
|
73
|
+
}, label));
|
|
74
|
+
}, [label, triggerButtonTestId, ref]);
|
|
65
75
|
var DefaultButton = (0, _react.useCallback)(function () {
|
|
66
76
|
return /*#__PURE__*/_react.default.createElement(_new.default, {
|
|
67
77
|
isSelected: isSelected || hasOptions,
|
|
@@ -84,12 +94,37 @@ var PopupTrigger = /*#__PURE__*/(0, _react.forwardRef)(function (_ref2, ref) {
|
|
|
84
94
|
appearance: "primary"
|
|
85
95
|
}, "+", selectedOptions.length - 1))));
|
|
86
96
|
}, [firstOption, hasOptions, isDisabled, isSelected, label, selectedOptions, triggerButtonTestId]);
|
|
97
|
+
var defaultButton = (0, _react.useMemo)(function () {
|
|
98
|
+
return /*#__PURE__*/_react.default.createElement(_new.default, {
|
|
99
|
+
ref: ref,
|
|
100
|
+
isSelected: isSelected || hasOptions,
|
|
101
|
+
isDisabled: isDisabled,
|
|
102
|
+
iconAfter: function iconAfter() {
|
|
103
|
+
return /*#__PURE__*/_react.default.createElement(_chevronDown.default, {
|
|
104
|
+
label: "",
|
|
105
|
+
color: "currentColor",
|
|
106
|
+
size: "small"
|
|
107
|
+
});
|
|
108
|
+
},
|
|
109
|
+
testId: "".concat(triggerButtonTestId, "--button"),
|
|
110
|
+
"aria-expanded": isSelected
|
|
111
|
+
}, /*#__PURE__*/_react.default.createElement(_compiled.Flex, null, /*#__PURE__*/_react.default.createElement(_compiled.Box, {
|
|
112
|
+
xcss: styles.triggerButtonLabelStyles
|
|
113
|
+
}, label, firstOption && /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, ": ", firstOption.label)), selectedOptions && selectedOptions.length > 1 && /*#__PURE__*/_react.default.createElement(_compiled.Flex, {
|
|
114
|
+
xcss: styles.badgeStyles,
|
|
115
|
+
alignItems: "center"
|
|
116
|
+
}, /*#__PURE__*/_react.default.createElement(_badge.default, {
|
|
117
|
+
appearance: "primary"
|
|
118
|
+
}, "+", selectedOptions.length - 1))));
|
|
119
|
+
}, [firstOption, hasOptions, isDisabled, isSelected, label, selectedOptions, triggerButtonTestId, ref]);
|
|
87
120
|
|
|
88
121
|
/**
|
|
89
122
|
* We had an issue with the popup component referencing a stale DOM ref for the trigger button.
|
|
90
123
|
* Hence introducing a Box to make sure ref is always the same and only content is refreshed on re-renders
|
|
91
124
|
*/
|
|
92
|
-
return /*#__PURE__*/_react.default.createElement(_compiled.Box, {
|
|
125
|
+
return (0, _platformFeatureFlags.fg)('platform_navx_sllv_dropdown_escape_and_focus_fix') ? /*#__PURE__*/_react.default.createElement(_compiled.Box, {
|
|
126
|
+
testId: triggerButtonTestId
|
|
127
|
+
}, showButtonLoading ? loadingButton : defaultButton) : /*#__PURE__*/_react.default.createElement(_compiled.Box, {
|
|
93
128
|
ref: ref,
|
|
94
129
|
testId: triggerButtonTestId
|
|
95
130
|
}, showButtonLoading ? /*#__PURE__*/_react.default.createElement(LoadingButton, null) : /*#__PURE__*/_react.default.createElement(DefaultButton, null));
|
|
@@ -48,6 +48,7 @@ var IconEditType = function IconEditType(props) {
|
|
|
48
48
|
return /*#__PURE__*/_react.default.createElement(_layering.Layering, {
|
|
49
49
|
isDisabled: false
|
|
50
50
|
}, /*#__PURE__*/_react.default.createElement(_select.default, (0, _extends2.default)({}, (0, _utils.getCleanedSelectProps)(props), {
|
|
51
|
+
menuPortalTarget: (0, _platformFeatureFlags.fg)('platform_navx_sllv_j2ws_dropdown_for_single_row') ? document.body : undefined,
|
|
51
52
|
autoFocus: true,
|
|
52
53
|
blurInputOnSelect: true,
|
|
53
54
|
defaultMenuIsOpen: true
|
|
@@ -86,7 +87,8 @@ var IconEditType = function IconEditType(props) {
|
|
|
86
87
|
type: 'icon',
|
|
87
88
|
values: e ? [e] : []
|
|
88
89
|
});
|
|
89
|
-
}
|
|
90
|
+
},
|
|
91
|
+
shouldPreventEscapePropagation: (0, _platformFeatureFlags.fg)('platform_navx_sllv_dropdown_escape_and_focus_fix') ? true : undefined
|
|
90
92
|
})));
|
|
91
93
|
};
|
|
92
94
|
|
|
@@ -48,6 +48,7 @@ var StatusEditType = function StatusEditType(props) {
|
|
|
48
48
|
return /*#__PURE__*/_react.default.createElement(_layering.Layering, {
|
|
49
49
|
isDisabled: false
|
|
50
50
|
}, /*#__PURE__*/_react.default.createElement(_select.default, (0, _extends2.default)({}, (0, _utils.getCleanedSelectProps)(props), {
|
|
51
|
+
menuPortalTarget: (0, _platformFeatureFlags.fg)('platform_navx_sllv_j2ws_dropdown_for_single_row') ? document.body : undefined,
|
|
51
52
|
autoFocus: true,
|
|
52
53
|
options: options,
|
|
53
54
|
defaultMenuIsOpen: true,
|
|
@@ -79,7 +80,8 @@ var StatusEditType = function StatusEditType(props) {
|
|
|
79
80
|
type: 'status',
|
|
80
81
|
values: e ? [e] : []
|
|
81
82
|
});
|
|
82
|
-
}
|
|
83
|
+
},
|
|
84
|
+
shouldPreventEscapePropagation: (0, _platformFeatureFlags.fg)('platform_navx_sllv_dropdown_escape_and_focus_fix') ? true : undefined
|
|
83
85
|
})));
|
|
84
86
|
};
|
|
85
87
|
|
|
@@ -78,6 +78,7 @@ var UserEditType = function UserEditType(props) {
|
|
|
78
78
|
return /*#__PURE__*/_react.default.createElement(_layering.Layering, {
|
|
79
79
|
isDisabled: false
|
|
80
80
|
}, /*#__PURE__*/_react.default.createElement(_select.default, (0, _extends2.default)({}, (0, _utils.getCleanedSelectProps)(props), {
|
|
81
|
+
menuPortalTarget: (0, _platformFeatureFlags.fg)('platform_navx_sllv_j2ws_dropdown_for_single_row') ? document.body : undefined,
|
|
81
82
|
autoFocus: true,
|
|
82
83
|
defaultMenuIsOpen: true,
|
|
83
84
|
blurInputOnSelect: true,
|
|
@@ -114,7 +115,8 @@ var UserEditType = function UserEditType(props) {
|
|
|
114
115
|
type: 'user',
|
|
115
116
|
values: e ? [e] : []
|
|
116
117
|
});
|
|
117
|
-
}
|
|
118
|
+
},
|
|
119
|
+
shouldPreventEscapePropagation: (0, _platformFeatureFlags.fg)('platform_navx_sllv_dropdown_escape_and_focus_fix') ? true : undefined
|
|
118
120
|
})));
|
|
119
121
|
};
|
|
120
122
|
|
|
@@ -52,7 +52,6 @@ const renderValidatorIcon = lastValidationResult => {
|
|
|
52
52
|
return /*#__PURE__*/React.createElement(CrossCircleIcon, {
|
|
53
53
|
label: "label",
|
|
54
54
|
color: `var(--ds-icon-danger, ${R400})`,
|
|
55
|
-
LEGACY_size: "medium",
|
|
56
55
|
testId: "assets-datasource-modal--aql-invalid",
|
|
57
56
|
spacing: "spacious"
|
|
58
57
|
});
|
|
@@ -61,14 +60,12 @@ const renderValidatorIcon = lastValidationResult => {
|
|
|
61
60
|
return /*#__PURE__*/React.createElement(CheckCircleIcon, {
|
|
62
61
|
label: "label",
|
|
63
62
|
color: `var(--ds-icon-success, ${G300})`,
|
|
64
|
-
LEGACY_size: "medium",
|
|
65
63
|
testId: "assets-datasource-modal--aql-valid",
|
|
66
64
|
spacing: "spacious"
|
|
67
65
|
});
|
|
68
66
|
}
|
|
69
67
|
return /*#__PURE__*/React.createElement(SearchIcon, {
|
|
70
68
|
label: "label",
|
|
71
|
-
LEGACY_size: "medium",
|
|
72
69
|
testId: "assets-datasource-modal--aql-idle",
|
|
73
70
|
color: "currentColor",
|
|
74
71
|
spacing: "spacious"
|
|
@@ -112,7 +109,6 @@ export const AqlSearchInput = ({
|
|
|
112
109
|
}, /*#__PURE__*/React.createElement(QuestionCircleIcon, {
|
|
113
110
|
label: "label",
|
|
114
111
|
color: `var(--ds-icon, ${N500})`,
|
|
115
|
-
LEGACY_size: "medium",
|
|
116
112
|
testId: "assets-datasource-modal-help",
|
|
117
113
|
spacing: "spacious"
|
|
118
114
|
}))), /*#__PURE__*/React.createElement(Box, {
|
|
@@ -121,7 +117,6 @@ export const AqlSearchInput = ({
|
|
|
121
117
|
appearance: "primary",
|
|
122
118
|
isLoading: isSearching,
|
|
123
119
|
icon: iconProps => /*#__PURE__*/React.createElement(SearchIcon, _extends({}, iconProps, {
|
|
124
|
-
LEGACY_size: "medium",
|
|
125
120
|
spacing: "spacious",
|
|
126
121
|
color: "currentColor"
|
|
127
122
|
})),
|
|
@@ -50,7 +50,6 @@ export const BasicSearchInput = ({
|
|
|
50
50
|
appearance: "primary",
|
|
51
51
|
isLoading: isSearching,
|
|
52
52
|
icon: iconProps => /*#__PURE__*/React.createElement(SearchIcon, _extends({}, iconProps, {
|
|
53
|
-
LEGACY_size: "medium",
|
|
54
53
|
spacing: "spacious",
|
|
55
54
|
color: "currentColor"
|
|
56
55
|
})),
|
|
@@ -57,7 +57,6 @@ const AvatarOptionLabel = ({
|
|
|
57
57
|
xcss: styles.groupWrapperStyles
|
|
58
58
|
}, /*#__PURE__*/React.createElement(PeopleGroupIcon, {
|
|
59
59
|
color: "currentColor",
|
|
60
|
-
LEGACY_size: "small",
|
|
61
60
|
label: ""
|
|
62
61
|
})) : /*#__PURE__*/React.createElement(Avatar, {
|
|
63
62
|
appearance: data.isSquare ? 'square' : 'circle',
|
|
@@ -2,6 +2,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
import React, { useCallback, useEffect, useRef, useState } from 'react';
|
|
3
3
|
import isEqual from 'lodash/isEqual';
|
|
4
4
|
import { useIntl } from 'react-intl-next';
|
|
5
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
5
6
|
import { PopupSelect } from '@atlaskit/select';
|
|
6
7
|
import { useDatasourceAnalyticsEvents } from '../../../../analytics';
|
|
7
8
|
import CustomControl from './control';
|
|
@@ -172,6 +173,7 @@ export const FilterPopupSelect = ({
|
|
|
172
173
|
onInputChange: handleInputChange,
|
|
173
174
|
onOpen: handleMenuOpen,
|
|
174
175
|
onClose: handleMenuClose,
|
|
176
|
+
shouldPreventEscapePropagation: fg('platform_navx_sllv_dropdown_escape_and_focus_fix'),
|
|
175
177
|
target: ({
|
|
176
178
|
isOpen,
|
|
177
179
|
...triggerProps
|
|
@@ -2,11 +2,12 @@
|
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import "./trigger.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
5
|
-
import React, { forwardRef, useCallback } from 'react';
|
|
5
|
+
import React, { forwardRef, useCallback, useMemo } from 'react';
|
|
6
6
|
import Badge from '@atlaskit/badge';
|
|
7
7
|
import NewButton from '@atlaskit/button/new';
|
|
8
8
|
import Button from '@atlaskit/button/standard-button';
|
|
9
9
|
import ChevronDownIcon from '@atlaskit/icon/core/chevron-down';
|
|
10
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
10
11
|
import { Box, Flex } from '@atlaskit/primitives/compiled';
|
|
11
12
|
import Spinner from '@atlaskit/spinner';
|
|
12
13
|
const styles = {
|
|
@@ -47,6 +48,13 @@ const PopupTrigger = /*#__PURE__*/forwardRef(({
|
|
|
47
48
|
}),
|
|
48
49
|
testId: `${triggerButtonTestId}--loading-button`
|
|
49
50
|
}, label)), [label, triggerButtonTestId]);
|
|
51
|
+
const loadingButton = useMemo(() => /*#__PURE__*/React.createElement(LoadingStateAnimationWrapper, null, /*#__PURE__*/React.createElement(Button, {
|
|
52
|
+
ref: ref,
|
|
53
|
+
iconAfter: /*#__PURE__*/React.createElement(Spinner, {
|
|
54
|
+
size: 'xsmall'
|
|
55
|
+
}),
|
|
56
|
+
testId: `${triggerButtonTestId}--loading-button`
|
|
57
|
+
}, label)), [label, triggerButtonTestId, ref]);
|
|
50
58
|
const DefaultButton = useCallback(() => /*#__PURE__*/React.createElement(NewButton, {
|
|
51
59
|
isSelected: isSelected || hasOptions,
|
|
52
60
|
isDisabled: isDisabled,
|
|
@@ -65,12 +73,33 @@ const PopupTrigger = /*#__PURE__*/forwardRef(({
|
|
|
65
73
|
}, /*#__PURE__*/React.createElement(Badge, {
|
|
66
74
|
appearance: "primary"
|
|
67
75
|
}, "+", selectedOptions.length - 1)))), [firstOption, hasOptions, isDisabled, isSelected, label, selectedOptions, triggerButtonTestId]);
|
|
76
|
+
const defaultButton = useMemo(() => /*#__PURE__*/React.createElement(NewButton, {
|
|
77
|
+
ref: ref,
|
|
78
|
+
isSelected: isSelected || hasOptions,
|
|
79
|
+
isDisabled: isDisabled,
|
|
80
|
+
iconAfter: () => /*#__PURE__*/React.createElement(ChevronDownIcon, {
|
|
81
|
+
label: "",
|
|
82
|
+
color: "currentColor",
|
|
83
|
+
size: "small"
|
|
84
|
+
}),
|
|
85
|
+
testId: `${triggerButtonTestId}--button`,
|
|
86
|
+
"aria-expanded": isSelected
|
|
87
|
+
}, /*#__PURE__*/React.createElement(Flex, null, /*#__PURE__*/React.createElement(Box, {
|
|
88
|
+
xcss: styles.triggerButtonLabelStyles
|
|
89
|
+
}, label, firstOption && /*#__PURE__*/React.createElement(React.Fragment, null, ": ", firstOption.label)), selectedOptions && selectedOptions.length > 1 && /*#__PURE__*/React.createElement(Flex, {
|
|
90
|
+
xcss: styles.badgeStyles,
|
|
91
|
+
alignItems: "center"
|
|
92
|
+
}, /*#__PURE__*/React.createElement(Badge, {
|
|
93
|
+
appearance: "primary"
|
|
94
|
+
}, "+", selectedOptions.length - 1)))), [firstOption, hasOptions, isDisabled, isSelected, label, selectedOptions, triggerButtonTestId, ref]);
|
|
68
95
|
|
|
69
96
|
/**
|
|
70
97
|
* We had an issue with the popup component referencing a stale DOM ref for the trigger button.
|
|
71
98
|
* Hence introducing a Box to make sure ref is always the same and only content is refreshed on re-renders
|
|
72
99
|
*/
|
|
73
|
-
return /*#__PURE__*/React.createElement(Box, {
|
|
100
|
+
return fg('platform_navx_sllv_dropdown_escape_and_focus_fix') ? /*#__PURE__*/React.createElement(Box, {
|
|
101
|
+
testId: triggerButtonTestId
|
|
102
|
+
}, showButtonLoading ? loadingButton : defaultButton) : /*#__PURE__*/React.createElement(Box, {
|
|
74
103
|
ref: ref,
|
|
75
104
|
testId: triggerButtonTestId
|
|
76
105
|
}, showButtonLoading ? /*#__PURE__*/React.createElement(LoadingButton, null) : /*#__PURE__*/React.createElement(DefaultButton, null));
|
|
@@ -42,6 +42,7 @@ const IconEditType = props => {
|
|
|
42
42
|
return /*#__PURE__*/React.createElement(Layering, {
|
|
43
43
|
isDisabled: false
|
|
44
44
|
}, /*#__PURE__*/React.createElement(Select, _extends({}, getCleanedSelectProps(props), {
|
|
45
|
+
menuPortalTarget: fg('platform_navx_sllv_j2ws_dropdown_for_single_row') ? document.body : undefined,
|
|
45
46
|
autoFocus: true,
|
|
46
47
|
blurInputOnSelect: true,
|
|
47
48
|
defaultMenuIsOpen: true
|
|
@@ -71,7 +72,8 @@ const IconEditType = props => {
|
|
|
71
72
|
onChange: e => props.setEditValues({
|
|
72
73
|
type: 'icon',
|
|
73
74
|
values: e ? [e] : []
|
|
74
|
-
})
|
|
75
|
+
}),
|
|
76
|
+
shouldPreventEscapePropagation: fg('platform_navx_sllv_dropdown_escape_and_focus_fix') ? true : undefined
|
|
75
77
|
})));
|
|
76
78
|
};
|
|
77
79
|
|
|
@@ -42,6 +42,7 @@ const StatusEditType = props => {
|
|
|
42
42
|
return /*#__PURE__*/React.createElement(Layering, {
|
|
43
43
|
isDisabled: false
|
|
44
44
|
}, /*#__PURE__*/React.createElement(Select, _extends({}, getCleanedSelectProps(props), {
|
|
45
|
+
menuPortalTarget: fg('platform_navx_sllv_j2ws_dropdown_for_single_row') ? document.body : undefined,
|
|
45
46
|
autoFocus: true,
|
|
46
47
|
options: options,
|
|
47
48
|
defaultMenuIsOpen: true,
|
|
@@ -67,7 +68,8 @@ const StatusEditType = props => {
|
|
|
67
68
|
onChange: e => props.setEditValues({
|
|
68
69
|
type: 'status',
|
|
69
70
|
values: e ? [e] : []
|
|
70
|
-
})
|
|
71
|
+
}),
|
|
72
|
+
shouldPreventEscapePropagation: fg('platform_navx_sllv_dropdown_escape_and_focus_fix') ? true : undefined
|
|
71
73
|
})));
|
|
72
74
|
};
|
|
73
75
|
|
|
@@ -63,6 +63,7 @@ const UserEditType = props => {
|
|
|
63
63
|
return /*#__PURE__*/React.createElement(Layering, {
|
|
64
64
|
isDisabled: false
|
|
65
65
|
}, /*#__PURE__*/React.createElement(Select, _extends({}, getCleanedSelectProps(props), {
|
|
66
|
+
menuPortalTarget: fg('platform_navx_sllv_j2ws_dropdown_for_single_row') ? document.body : undefined,
|
|
66
67
|
autoFocus: true,
|
|
67
68
|
defaultMenuIsOpen: true,
|
|
68
69
|
blurInputOnSelect: true,
|
|
@@ -93,7 +94,8 @@ const UserEditType = props => {
|
|
|
93
94
|
onChange: e => props.setEditValues({
|
|
94
95
|
type: 'user',
|
|
95
96
|
values: e ? [e] : []
|
|
96
|
-
})
|
|
97
|
+
}),
|
|
98
|
+
shouldPreventEscapePropagation: fg('platform_navx_sllv_dropdown_escape_and_focus_fix') ? true : undefined
|
|
97
99
|
})));
|
|
98
100
|
};
|
|
99
101
|
|
|
@@ -54,7 +54,6 @@ var renderValidatorIcon = function renderValidatorIcon(lastValidationResult) {
|
|
|
54
54
|
return /*#__PURE__*/React.createElement(CrossCircleIcon, {
|
|
55
55
|
label: "label",
|
|
56
56
|
color: "var(--ds-icon-danger, ".concat(R400, ")"),
|
|
57
|
-
LEGACY_size: "medium",
|
|
58
57
|
testId: "assets-datasource-modal--aql-invalid",
|
|
59
58
|
spacing: "spacious"
|
|
60
59
|
});
|
|
@@ -63,14 +62,12 @@ var renderValidatorIcon = function renderValidatorIcon(lastValidationResult) {
|
|
|
63
62
|
return /*#__PURE__*/React.createElement(CheckCircleIcon, {
|
|
64
63
|
label: "label",
|
|
65
64
|
color: "var(--ds-icon-success, ".concat(G300, ")"),
|
|
66
|
-
LEGACY_size: "medium",
|
|
67
65
|
testId: "assets-datasource-modal--aql-valid",
|
|
68
66
|
spacing: "spacious"
|
|
69
67
|
});
|
|
70
68
|
}
|
|
71
69
|
return /*#__PURE__*/React.createElement(SearchIcon, {
|
|
72
70
|
label: "label",
|
|
73
|
-
LEGACY_size: "medium",
|
|
74
71
|
testId: "assets-datasource-modal--aql-idle",
|
|
75
72
|
color: "currentColor",
|
|
76
73
|
spacing: "spacious"
|
|
@@ -112,7 +109,6 @@ export var AqlSearchInput = function AqlSearchInput(_ref2) {
|
|
|
112
109
|
}, /*#__PURE__*/React.createElement(QuestionCircleIcon, {
|
|
113
110
|
label: "label",
|
|
114
111
|
color: "var(--ds-icon, ".concat(N500, ")"),
|
|
115
|
-
LEGACY_size: "medium",
|
|
116
112
|
testId: "assets-datasource-modal-help",
|
|
117
113
|
spacing: "spacious"
|
|
118
114
|
}))), /*#__PURE__*/React.createElement(Box, {
|
|
@@ -122,7 +118,6 @@ export var AqlSearchInput = function AqlSearchInput(_ref2) {
|
|
|
122
118
|
isLoading: isSearching,
|
|
123
119
|
icon: function icon(iconProps) {
|
|
124
120
|
return /*#__PURE__*/React.createElement(SearchIcon, _extends({}, iconProps, {
|
|
125
|
-
LEGACY_size: "medium",
|
|
126
121
|
spacing: "spacious",
|
|
127
122
|
color: "currentColor"
|
|
128
123
|
}));
|
|
@@ -48,7 +48,6 @@ export var BasicSearchInput = function BasicSearchInput(_ref) {
|
|
|
48
48
|
isLoading: isSearching,
|
|
49
49
|
icon: function icon(iconProps) {
|
|
50
50
|
return /*#__PURE__*/React.createElement(SearchIcon, _extends({}, iconProps, {
|
|
51
|
-
LEGACY_size: "medium",
|
|
52
51
|
spacing: "spacious",
|
|
53
52
|
color: "currentColor"
|
|
54
53
|
}));
|
|
@@ -52,7 +52,6 @@ var AvatarOptionLabel = function AvatarOptionLabel(_ref3) {
|
|
|
52
52
|
xcss: styles.groupWrapperStyles
|
|
53
53
|
}, /*#__PURE__*/React.createElement(PeopleGroupIcon, {
|
|
54
54
|
color: "currentColor",
|
|
55
|
-
LEGACY_size: "small",
|
|
56
55
|
label: ""
|
|
57
56
|
})) : /*#__PURE__*/React.createElement(Avatar, {
|
|
58
57
|
appearance: data.isSquare ? 'square' : 'circle',
|
|
@@ -11,6 +11,7 @@ import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
|
11
11
|
import React, { useCallback, useEffect, useRef, useState } from 'react';
|
|
12
12
|
import isEqual from 'lodash/isEqual';
|
|
13
13
|
import { useIntl } from 'react-intl-next';
|
|
14
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
14
15
|
import { PopupSelect } from '@atlaskit/select';
|
|
15
16
|
import { useDatasourceAnalyticsEvents } from '../../../../analytics';
|
|
16
17
|
import CustomControl from './control';
|
|
@@ -214,6 +215,7 @@ export var FilterPopupSelect = function FilterPopupSelect(_ref) {
|
|
|
214
215
|
onInputChange: handleInputChange,
|
|
215
216
|
onOpen: handleMenuOpen,
|
|
216
217
|
onClose: handleMenuClose,
|
|
218
|
+
shouldPreventEscapePropagation: fg('platform_navx_sllv_dropdown_escape_and_focus_fix'),
|
|
217
219
|
target: function target(_ref3) {
|
|
218
220
|
var isOpen = _ref3.isOpen,
|
|
219
221
|
triggerProps = _objectWithoutProperties(_ref3, _excluded);
|
|
@@ -5,11 +5,12 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
|
5
5
|
var _excluded = ["as", "style"];
|
|
6
6
|
import "./trigger.compiled.css";
|
|
7
7
|
import { ax, ix } from "@compiled/react/runtime";
|
|
8
|
-
import React, { forwardRef, useCallback } from 'react';
|
|
8
|
+
import React, { forwardRef, useCallback, useMemo } from 'react';
|
|
9
9
|
import Badge from '@atlaskit/badge';
|
|
10
10
|
import NewButton from '@atlaskit/button/new';
|
|
11
11
|
import Button from '@atlaskit/button/standard-button';
|
|
12
12
|
import ChevronDownIcon from '@atlaskit/icon/core/chevron-down';
|
|
13
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
13
14
|
import { Box, Flex } from '@atlaskit/primitives/compiled';
|
|
14
15
|
import Spinner from '@atlaskit/spinner';
|
|
15
16
|
var styles = {
|
|
@@ -53,6 +54,15 @@ var PopupTrigger = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
53
54
|
testId: "".concat(triggerButtonTestId, "--loading-button")
|
|
54
55
|
}, label));
|
|
55
56
|
}, [label, triggerButtonTestId]);
|
|
57
|
+
var loadingButton = useMemo(function () {
|
|
58
|
+
return /*#__PURE__*/React.createElement(LoadingStateAnimationWrapper, null, /*#__PURE__*/React.createElement(Button, {
|
|
59
|
+
ref: ref,
|
|
60
|
+
iconAfter: /*#__PURE__*/React.createElement(Spinner, {
|
|
61
|
+
size: 'xsmall'
|
|
62
|
+
}),
|
|
63
|
+
testId: "".concat(triggerButtonTestId, "--loading-button")
|
|
64
|
+
}, label));
|
|
65
|
+
}, [label, triggerButtonTestId, ref]);
|
|
56
66
|
var DefaultButton = useCallback(function () {
|
|
57
67
|
return /*#__PURE__*/React.createElement(NewButton, {
|
|
58
68
|
isSelected: isSelected || hasOptions,
|
|
@@ -75,12 +85,37 @@ var PopupTrigger = /*#__PURE__*/forwardRef(function (_ref2, ref) {
|
|
|
75
85
|
appearance: "primary"
|
|
76
86
|
}, "+", selectedOptions.length - 1))));
|
|
77
87
|
}, [firstOption, hasOptions, isDisabled, isSelected, label, selectedOptions, triggerButtonTestId]);
|
|
88
|
+
var defaultButton = useMemo(function () {
|
|
89
|
+
return /*#__PURE__*/React.createElement(NewButton, {
|
|
90
|
+
ref: ref,
|
|
91
|
+
isSelected: isSelected || hasOptions,
|
|
92
|
+
isDisabled: isDisabled,
|
|
93
|
+
iconAfter: function iconAfter() {
|
|
94
|
+
return /*#__PURE__*/React.createElement(ChevronDownIcon, {
|
|
95
|
+
label: "",
|
|
96
|
+
color: "currentColor",
|
|
97
|
+
size: "small"
|
|
98
|
+
});
|
|
99
|
+
},
|
|
100
|
+
testId: "".concat(triggerButtonTestId, "--button"),
|
|
101
|
+
"aria-expanded": isSelected
|
|
102
|
+
}, /*#__PURE__*/React.createElement(Flex, null, /*#__PURE__*/React.createElement(Box, {
|
|
103
|
+
xcss: styles.triggerButtonLabelStyles
|
|
104
|
+
}, label, firstOption && /*#__PURE__*/React.createElement(React.Fragment, null, ": ", firstOption.label)), selectedOptions && selectedOptions.length > 1 && /*#__PURE__*/React.createElement(Flex, {
|
|
105
|
+
xcss: styles.badgeStyles,
|
|
106
|
+
alignItems: "center"
|
|
107
|
+
}, /*#__PURE__*/React.createElement(Badge, {
|
|
108
|
+
appearance: "primary"
|
|
109
|
+
}, "+", selectedOptions.length - 1))));
|
|
110
|
+
}, [firstOption, hasOptions, isDisabled, isSelected, label, selectedOptions, triggerButtonTestId, ref]);
|
|
78
111
|
|
|
79
112
|
/**
|
|
80
113
|
* We had an issue with the popup component referencing a stale DOM ref for the trigger button.
|
|
81
114
|
* Hence introducing a Box to make sure ref is always the same and only content is refreshed on re-renders
|
|
82
115
|
*/
|
|
83
|
-
return /*#__PURE__*/React.createElement(Box, {
|
|
116
|
+
return fg('platform_navx_sllv_dropdown_escape_and_focus_fix') ? /*#__PURE__*/React.createElement(Box, {
|
|
117
|
+
testId: triggerButtonTestId
|
|
118
|
+
}, showButtonLoading ? loadingButton : defaultButton) : /*#__PURE__*/React.createElement(Box, {
|
|
84
119
|
ref: ref,
|
|
85
120
|
testId: triggerButtonTestId
|
|
86
121
|
}, showButtonLoading ? /*#__PURE__*/React.createElement(LoadingButton, null) : /*#__PURE__*/React.createElement(DefaultButton, null));
|
|
@@ -39,6 +39,7 @@ var IconEditType = function IconEditType(props) {
|
|
|
39
39
|
return /*#__PURE__*/React.createElement(Layering, {
|
|
40
40
|
isDisabled: false
|
|
41
41
|
}, /*#__PURE__*/React.createElement(Select, _extends({}, getCleanedSelectProps(props), {
|
|
42
|
+
menuPortalTarget: fg('platform_navx_sllv_j2ws_dropdown_for_single_row') ? document.body : undefined,
|
|
42
43
|
autoFocus: true,
|
|
43
44
|
blurInputOnSelect: true,
|
|
44
45
|
defaultMenuIsOpen: true
|
|
@@ -77,7 +78,8 @@ var IconEditType = function IconEditType(props) {
|
|
|
77
78
|
type: 'icon',
|
|
78
79
|
values: e ? [e] : []
|
|
79
80
|
});
|
|
80
|
-
}
|
|
81
|
+
},
|
|
82
|
+
shouldPreventEscapePropagation: fg('platform_navx_sllv_dropdown_escape_and_focus_fix') ? true : undefined
|
|
81
83
|
})));
|
|
82
84
|
};
|
|
83
85
|
|
|
@@ -39,6 +39,7 @@ var StatusEditType = function StatusEditType(props) {
|
|
|
39
39
|
return /*#__PURE__*/React.createElement(Layering, {
|
|
40
40
|
isDisabled: false
|
|
41
41
|
}, /*#__PURE__*/React.createElement(Select, _extends({}, getCleanedSelectProps(props), {
|
|
42
|
+
menuPortalTarget: fg('platform_navx_sllv_j2ws_dropdown_for_single_row') ? document.body : undefined,
|
|
42
43
|
autoFocus: true,
|
|
43
44
|
options: options,
|
|
44
45
|
defaultMenuIsOpen: true,
|
|
@@ -70,7 +71,8 @@ var StatusEditType = function StatusEditType(props) {
|
|
|
70
71
|
type: 'status',
|
|
71
72
|
values: e ? [e] : []
|
|
72
73
|
});
|
|
73
|
-
}
|
|
74
|
+
},
|
|
75
|
+
shouldPreventEscapePropagation: fg('platform_navx_sllv_dropdown_escape_and_focus_fix') ? true : undefined
|
|
74
76
|
})));
|
|
75
77
|
};
|
|
76
78
|
|
|
@@ -69,6 +69,7 @@ var UserEditType = function UserEditType(props) {
|
|
|
69
69
|
return /*#__PURE__*/React.createElement(Layering, {
|
|
70
70
|
isDisabled: false
|
|
71
71
|
}, /*#__PURE__*/React.createElement(Select, _extends({}, getCleanedSelectProps(props), {
|
|
72
|
+
menuPortalTarget: fg('platform_navx_sllv_j2ws_dropdown_for_single_row') ? document.body : undefined,
|
|
72
73
|
autoFocus: true,
|
|
73
74
|
defaultMenuIsOpen: true,
|
|
74
75
|
blurInputOnSelect: true,
|
|
@@ -105,7 +106,8 @@ var UserEditType = function UserEditType(props) {
|
|
|
105
106
|
type: 'user',
|
|
106
107
|
values: e ? [e] : []
|
|
107
108
|
});
|
|
108
|
-
}
|
|
109
|
+
},
|
|
110
|
+
shouldPreventEscapePropagation: fg('platform_navx_sllv_dropdown_escape_and_focus_fix') ? true : undefined
|
|
109
111
|
})));
|
|
110
112
|
};
|
|
111
113
|
|
|
@@ -8,5 +8,5 @@ export interface PopupTriggerProps {
|
|
|
8
8
|
selectedOptions?: ReadonlyArray<SelectOption>;
|
|
9
9
|
testId?: string;
|
|
10
10
|
}
|
|
11
|
-
declare const PopupTrigger: React.ForwardRefExoticComponent<PopupTriggerProps & React.RefAttributes<
|
|
11
|
+
declare const PopupTrigger: React.ForwardRefExoticComponent<PopupTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
12
12
|
export default PopupTrigger;
|
|
@@ -73,7 +73,7 @@ export interface IssueLikeDataTableViewProps {
|
|
|
73
73
|
renderItem?: TableViewPropsRenderType;
|
|
74
74
|
/**
|
|
75
75
|
* If this number is set it will restrict (max-height) maximum size of the component AND make main container a scrollable container.
|
|
76
|
-
* It this number is
|
|
76
|
+
* It this number is 0 it will not restrict height and not make container scrollable.
|
|
77
77
|
*/
|
|
78
78
|
scrollableContainerHeight?: number;
|
|
79
79
|
status: DatasourceTableStatusType;
|
|
@@ -8,5 +8,5 @@ export interface PopupTriggerProps {
|
|
|
8
8
|
selectedOptions?: ReadonlyArray<SelectOption>;
|
|
9
9
|
testId?: string;
|
|
10
10
|
}
|
|
11
|
-
declare const PopupTrigger: React.ForwardRefExoticComponent<PopupTriggerProps & React.RefAttributes<
|
|
11
|
+
declare const PopupTrigger: React.ForwardRefExoticComponent<PopupTriggerProps & React.RefAttributes<HTMLButtonElement>>;
|
|
12
12
|
export default PopupTrigger;
|
|
@@ -73,7 +73,7 @@ export interface IssueLikeDataTableViewProps {
|
|
|
73
73
|
renderItem?: TableViewPropsRenderType;
|
|
74
74
|
/**
|
|
75
75
|
* If this number is set it will restrict (max-height) maximum size of the component AND make main container a scrollable container.
|
|
76
|
-
* It this number is
|
|
76
|
+
* It this number is 0 it will not restrict height and not make container scrollable.
|
|
77
77
|
*/
|
|
78
78
|
scrollableContainerHeight?: number;
|
|
79
79
|
status: DatasourceTableStatusType;
|
|
@@ -23,16 +23,12 @@ import { useCommonTableProps } from './useCommonTableProps';
|
|
|
23
23
|
type Props = {
|
|
24
24
|
canControlWrapping?: boolean;
|
|
25
25
|
canResizeColumns?: boolean;
|
|
26
|
+
cloudId?: string;
|
|
26
27
|
forceLoading?: boolean;
|
|
27
28
|
isReadonly?: boolean;
|
|
28
|
-
/**
|
|
29
|
-
* Use infinity for an infinite delay (promise never resolves or rejects)
|
|
30
|
-
* Default is 600ms
|
|
31
|
-
*/
|
|
32
|
-
mockExecutionDelay?: number;
|
|
33
29
|
skipIntl?: boolean;
|
|
34
30
|
visibleColumnKeys?: string[];
|
|
35
|
-
};
|
|
31
|
+
} & Parameters<typeof mockDatasourceFetchRequests>[0];
|
|
36
32
|
|
|
37
33
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-styled -- To migrate as part of go/ui-styling-standard
|
|
38
34
|
const TableViewWrapper = styled.div({
|
|
@@ -50,13 +46,14 @@ const ExampleBody = ({
|
|
|
50
46
|
forceLoading = false,
|
|
51
47
|
visibleColumnKeys: overrideVisibleColumnKeys,
|
|
52
48
|
mockExecutionDelay = 600,
|
|
49
|
+
cloudId,
|
|
53
50
|
}: Props) => {
|
|
54
51
|
const parameters = useMemo<JiraIssueDatasourceParameters>(
|
|
55
52
|
() => ({
|
|
56
|
-
cloudId: 'some-cloud-id',
|
|
53
|
+
cloudId: cloudId ?? 'some-cloud-id',
|
|
57
54
|
jql: 'some-jql',
|
|
58
55
|
}),
|
|
59
|
-
[],
|
|
56
|
+
[cloudId],
|
|
60
57
|
);
|
|
61
58
|
|
|
62
59
|
useEffect(() => {
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
|
|
3
|
+
import { cssMap, cx } from '@atlaskit/css';
|
|
4
|
+
import { Box } from '@atlaskit/primitives/compiled';
|
|
5
|
+
import { token } from '@atlaskit/tokens';
|
|
6
|
+
|
|
7
|
+
const styles = cssMap({
|
|
8
|
+
tableWrapper: {
|
|
9
|
+
marginInline: 'auto',
|
|
10
|
+
marginTop: token('space.200'),
|
|
11
|
+
width: '90%',
|
|
12
|
+
borderRadius: token('radius.large'),
|
|
13
|
+
borderWidth: token('border.width'),
|
|
14
|
+
borderStyle: 'solid',
|
|
15
|
+
borderColor: token('color.border'),
|
|
16
|
+
},
|
|
17
|
+
hasOverflow: {
|
|
18
|
+
overflow: 'hidden',
|
|
19
|
+
},
|
|
20
|
+
});
|
|
21
|
+
|
|
22
|
+
export const FakeModalDialogContainer = ({ children, hasOverflow = true }: { children: React.ReactNode, hasOverflow?: boolean }): React.JSX.Element => {
|
|
23
|
+
return (
|
|
24
|
+
<Box xcss={cx(styles.tableWrapper, hasOverflow && styles.hasOverflow)}>
|
|
25
|
+
{children}
|
|
26
|
+
</Box>
|
|
27
|
+
);
|
|
28
|
+
};
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/link-datasource",
|
|
3
|
-
"version": "4.32.
|
|
3
|
+
"version": "4.32.2",
|
|
4
4
|
"description": "UI Components to support linking platform dataset feature",
|
|
5
5
|
"author": "Atlassian Pty Ltd",
|
|
6
6
|
"license": "Apache-2.0",
|
|
@@ -81,7 +81,7 @@
|
|
|
81
81
|
"@atlaskit/react-select": "^3.13.0",
|
|
82
82
|
"@atlaskit/select": "^21.6.0",
|
|
83
83
|
"@atlaskit/smart-card": "^43.20.0",
|
|
84
|
-
"@atlaskit/smart-user-picker": "^8.
|
|
84
|
+
"@atlaskit/smart-user-picker": "^8.9.0",
|
|
85
85
|
"@atlaskit/spinner": "^19.0.0",
|
|
86
86
|
"@atlaskit/tag": "^14.2.0",
|
|
87
87
|
"@atlaskit/textfield": "^8.2.0",
|
|
@@ -186,6 +186,12 @@
|
|
|
186
186
|
},
|
|
187
187
|
"lp_disable_datasource_table_max_height_restriction": {
|
|
188
188
|
"type": "boolean"
|
|
189
|
+
},
|
|
190
|
+
"platform_navx_sllv_dropdown_escape_and_focus_fix": {
|
|
191
|
+
"type": "boolean"
|
|
192
|
+
},
|
|
193
|
+
"platform_navx_sllv_j2ws_dropdown_for_single_row": {
|
|
194
|
+
"type": "boolean"
|
|
189
195
|
}
|
|
190
196
|
},
|
|
191
197
|
"compassUnitTestMetricSourceId": "ari:cloud:compass:a436116f-02ce-4520-8fbb-7301462a1674:metric-source/c5751cc6-3513-4070-9deb-af31e86aed34/9c893299-a527-4457-9b46-f3bc4c828766"
|