@atlaskit/link-datasource 4.5.0 → 4.6.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 +21 -0
- package/dist/cjs/common/ui/spot/error-state/error/assets/dark.svg +7 -4
- package/dist/cjs/common/ui/spot/error-state/error/assets/light.svg +7 -4
- package/dist/cjs/common/ui/spot/error-state/error-old/assets/dark.svg +5 -0
- package/dist/cjs/common/ui/spot/error-state/error-old/assets/light.svg +5 -0
- package/dist/cjs/common/ui/spot/error-state/error-old/index.js +18 -0
- package/dist/cjs/common/utils/withFeatureFlaggedComponent.js +23 -0
- package/dist/cjs/ui/assets-modal/search-container/object-schema-select/index.js +7 -2
- package/dist/cjs/ui/common/modal/basic-search-input/index.compiled.css +1 -0
- package/dist/cjs/ui/common/modal/basic-search-input/index.js +6 -4
- package/dist/cjs/ui/common/modal/display-view-dropdown/display-view-drop-down.js +46 -6
- package/dist/cjs/ui/common/modal/mode-switcher/index.compiled.css +16 -0
- package/dist/cjs/ui/common/modal/mode-switcher/index.js +24 -2
- package/dist/cjs/ui/common/modal/popup-select/checkbox-option-visual-refresh-sllv.compiled.css +15 -0
- package/dist/cjs/ui/common/modal/popup-select/checkbox-option-visual-refresh-sllv.js +30 -0
- package/dist/cjs/ui/common/modal/popup-select/control.compiled.css +4 -0
- package/dist/cjs/ui/common/modal/popup-select/control.js +34 -7
- package/dist/cjs/ui/common/modal/popup-select/dropdownIndicator.js +19 -10
- package/dist/cjs/ui/common/modal/popup-select/footer.compiled.css +4 -0
- package/dist/cjs/ui/common/modal/popup-select/footer.js +8 -4
- package/dist/cjs/ui/common/modal/popup-select/index.js +25 -3
- package/dist/cjs/ui/common/modal/popup-select/menu-list/errorMessage.js +8 -3
- package/dist/cjs/ui/common/modal/popup-select/menu-list/index.compiled.css +4 -1
- package/dist/cjs/ui/common/modal/popup-select/menu-list/index.js +5 -2
- package/dist/cjs/ui/common/modal/popup-select/menu-list/messages.js +21 -1
- package/dist/cjs/ui/common/modal/popup-select/menu-list/noOptionsMessage.js +4 -3
- package/dist/cjs/ui/common/modal/popup-select/menu-list/selectMessage.compiled.css +8 -1
- package/dist/cjs/ui/common/modal/popup-select/menu-list/selectMessage.js +23 -4
- package/dist/cjs/ui/common/modal/popup-select/menu-list/showMoreButton.js +10 -0
- package/dist/cjs/ui/common/modal/popup-select/trigger.compiled.css +1 -0
- package/dist/cjs/ui/common/modal/popup-select/trigger.js +26 -5
- package/dist/cjs/ui/common/modal/site-selector/index.js +7 -2
- package/dist/cjs/ui/confluence-search-modal/basic-filters/filters/date-range-picker/trigger.js +18 -2
- package/dist/cjs/ui/confluence-search-modal/confluence-search-container/index.compiled.css +2 -1
- package/dist/cjs/ui/confluence-search-modal/confluence-search-container/index.js +14 -2
- package/dist/cjs/ui/jira-issues-modal/basic-filters/ui/async-popup-select/index.js +3 -1
- package/dist/cjs/ui/jira-issues-modal/basic-filters/ui/async-popup-select/messages.js +25 -0
- package/dist/cjs/ui/jira-issues-modal/jira-search-container/index.compiled.css +4 -1
- package/dist/cjs/ui/jira-issues-modal/jira-search-container/index.js +49 -2
- package/dist/es2019/common/ui/spot/error-state/error/assets/dark.svg +7 -4
- package/dist/es2019/common/ui/spot/error-state/error/assets/light.svg +7 -4
- package/dist/es2019/common/ui/spot/error-state/error-old/assets/dark.svg +5 -0
- package/dist/es2019/common/ui/spot/error-state/error-old/assets/light.svg +5 -0
- package/dist/es2019/common/ui/spot/error-state/error-old/index.js +11 -0
- package/dist/es2019/common/utils/withFeatureFlaggedComponent.js +17 -0
- package/dist/es2019/ui/assets-modal/search-container/object-schema-select/index.js +5 -2
- package/dist/es2019/ui/common/modal/basic-search-input/index.compiled.css +1 -0
- package/dist/es2019/ui/common/modal/basic-search-input/index.js +6 -4
- package/dist/es2019/ui/common/modal/display-view-dropdown/display-view-drop-down.js +37 -6
- package/dist/es2019/ui/common/modal/mode-switcher/index.compiled.css +16 -0
- package/dist/es2019/ui/common/modal/mode-switcher/index.js +19 -2
- package/dist/es2019/ui/common/modal/popup-select/checkbox-option-visual-refresh-sllv.compiled.css +15 -0
- package/dist/es2019/ui/common/modal/popup-select/checkbox-option-visual-refresh-sllv.js +19 -0
- package/dist/es2019/ui/common/modal/popup-select/control.compiled.css +4 -0
- package/dist/es2019/ui/common/modal/popup-select/control.js +26 -5
- package/dist/es2019/ui/common/modal/popup-select/dropdownIndicator.js +20 -11
- package/dist/es2019/ui/common/modal/popup-select/footer.compiled.css +4 -0
- package/dist/es2019/ui/common/modal/popup-select/footer.js +8 -4
- package/dist/es2019/ui/common/modal/popup-select/index.js +20 -3
- package/dist/es2019/ui/common/modal/popup-select/menu-list/errorMessage.js +8 -3
- package/dist/es2019/ui/common/modal/popup-select/menu-list/index.compiled.css +4 -1
- package/dist/es2019/ui/common/modal/popup-select/menu-list/index.js +5 -2
- package/dist/es2019/ui/common/modal/popup-select/menu-list/messages.js +21 -1
- package/dist/es2019/ui/common/modal/popup-select/menu-list/noOptionsMessage.js +4 -3
- package/dist/es2019/ui/common/modal/popup-select/menu-list/selectMessage.compiled.css +8 -1
- package/dist/es2019/ui/common/modal/popup-select/menu-list/selectMessage.js +24 -5
- package/dist/es2019/ui/common/modal/popup-select/menu-list/showMoreButton.js +12 -2
- package/dist/es2019/ui/common/modal/popup-select/trigger.compiled.css +1 -0
- package/dist/es2019/ui/common/modal/popup-select/trigger.js +24 -5
- package/dist/es2019/ui/common/modal/site-selector/index.js +5 -2
- package/dist/es2019/ui/confluence-search-modal/basic-filters/filters/date-range-picker/trigger.js +16 -2
- package/dist/es2019/ui/confluence-search-modal/confluence-search-container/index.compiled.css +2 -1
- package/dist/es2019/ui/confluence-search-modal/confluence-search-container/index.js +16 -3
- package/dist/es2019/ui/jira-issues-modal/basic-filters/ui/async-popup-select/index.js +3 -1
- package/dist/es2019/ui/jira-issues-modal/basic-filters/ui/async-popup-select/messages.js +25 -0
- package/dist/es2019/ui/jira-issues-modal/jira-search-container/index.compiled.css +4 -1
- package/dist/es2019/ui/jira-issues-modal/jira-search-container/index.js +50 -3
- package/dist/esm/common/ui/spot/error-state/error/assets/dark.svg +7 -4
- package/dist/esm/common/ui/spot/error-state/error/assets/light.svg +7 -4
- package/dist/esm/common/ui/spot/error-state/error-old/assets/dark.svg +5 -0
- package/dist/esm/common/ui/spot/error-state/error-old/assets/light.svg +5 -0
- package/dist/esm/common/ui/spot/error-state/error-old/index.js +11 -0
- package/dist/esm/common/utils/withFeatureFlaggedComponent.js +17 -0
- package/dist/esm/ui/assets-modal/search-container/object-schema-select/index.js +7 -2
- package/dist/esm/ui/common/modal/basic-search-input/index.compiled.css +1 -0
- package/dist/esm/ui/common/modal/basic-search-input/index.js +6 -4
- package/dist/esm/ui/common/modal/display-view-dropdown/display-view-drop-down.js +46 -6
- package/dist/esm/ui/common/modal/mode-switcher/index.compiled.css +16 -0
- package/dist/esm/ui/common/modal/mode-switcher/index.js +24 -2
- package/dist/esm/ui/common/modal/popup-select/checkbox-option-visual-refresh-sllv.compiled.css +15 -0
- package/dist/esm/ui/common/modal/popup-select/checkbox-option-visual-refresh-sllv.js +20 -0
- package/dist/esm/ui/common/modal/popup-select/control.compiled.css +4 -0
- package/dist/esm/ui/common/modal/popup-select/control.js +33 -6
- package/dist/esm/ui/common/modal/popup-select/dropdownIndicator.js +20 -11
- package/dist/esm/ui/common/modal/popup-select/footer.compiled.css +4 -0
- package/dist/esm/ui/common/modal/popup-select/footer.js +8 -4
- package/dist/esm/ui/common/modal/popup-select/index.js +25 -3
- package/dist/esm/ui/common/modal/popup-select/menu-list/errorMessage.js +8 -3
- package/dist/esm/ui/common/modal/popup-select/menu-list/index.compiled.css +4 -1
- package/dist/esm/ui/common/modal/popup-select/menu-list/index.js +5 -2
- package/dist/esm/ui/common/modal/popup-select/menu-list/messages.js +21 -1
- package/dist/esm/ui/common/modal/popup-select/menu-list/noOptionsMessage.js +4 -3
- package/dist/esm/ui/common/modal/popup-select/menu-list/selectMessage.compiled.css +8 -1
- package/dist/esm/ui/common/modal/popup-select/menu-list/selectMessage.js +24 -5
- package/dist/esm/ui/common/modal/popup-select/menu-list/showMoreButton.js +12 -2
- package/dist/esm/ui/common/modal/popup-select/trigger.compiled.css +1 -0
- package/dist/esm/ui/common/modal/popup-select/trigger.js +26 -5
- package/dist/esm/ui/common/modal/site-selector/index.js +7 -2
- package/dist/esm/ui/confluence-search-modal/basic-filters/filters/date-range-picker/trigger.js +18 -2
- package/dist/esm/ui/confluence-search-modal/confluence-search-container/index.compiled.css +2 -1
- package/dist/esm/ui/confluence-search-modal/confluence-search-container/index.js +15 -3
- package/dist/esm/ui/jira-issues-modal/basic-filters/ui/async-popup-select/index.js +3 -1
- package/dist/esm/ui/jira-issues-modal/basic-filters/ui/async-popup-select/messages.js +25 -0
- package/dist/esm/ui/jira-issues-modal/jira-search-container/index.compiled.css +4 -1
- package/dist/esm/ui/jira-issues-modal/jira-search-container/index.js +50 -3
- package/dist/types/common/ui/spot/error-state/error-old/index.d.ts +3 -0
- package/dist/types/common/utils/withFeatureFlaggedComponent.d.ts +9 -0
- package/dist/types/ui/common/modal/basic-search-input/index.d.ts +6 -1
- package/dist/types/ui/common/modal/popup-select/checkbox-option-visual-refresh-sllv.d.ts +4 -0
- package/dist/types/ui/common/modal/popup-select/control.d.ts +3 -1
- package/dist/types/ui/common/modal/popup-select/index.d.ts +6 -1
- package/dist/types/ui/common/modal/popup-select/menu-list/messages.d.ts +20 -0
- package/dist/types/ui/common/modal/popup-select/menu-list/selectMessage.d.ts +6 -1
- package/dist/types/ui/jira-issues-modal/basic-filters/ui/async-popup-select/messages.d.ts +25 -0
- package/dist/types-ts4.5/common/ui/spot/error-state/error-old/index.d.ts +3 -0
- package/dist/types-ts4.5/common/utils/withFeatureFlaggedComponent.d.ts +9 -0
- package/dist/types-ts4.5/ui/common/modal/basic-search-input/index.d.ts +6 -1
- package/dist/types-ts4.5/ui/common/modal/popup-select/checkbox-option-visual-refresh-sllv.d.ts +4 -0
- package/dist/types-ts4.5/ui/common/modal/popup-select/control.d.ts +3 -1
- package/dist/types-ts4.5/ui/common/modal/popup-select/index.d.ts +6 -1
- package/dist/types-ts4.5/ui/common/modal/popup-select/menu-list/messages.d.ts +20 -0
- package/dist/types-ts4.5/ui/common/modal/popup-select/menu-list/selectMessage.d.ts +6 -1
- package/dist/types-ts4.5/ui/jira-issues-modal/basic-filters/ui/async-popup-select/messages.d.ts +25 -0
- package/package.json +5 -5
|
@@ -2,8 +2,10 @@ 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 { CheckboxOption, PopupSelect } from '@atlaskit/select';
|
|
6
7
|
import { useDatasourceAnalyticsEvents } from '../../../../analytics';
|
|
8
|
+
import { CheckboxOptionVisualRefreshSllv } from './checkbox-option-visual-refresh-sllv';
|
|
7
9
|
import CustomControl from './control';
|
|
8
10
|
import CustomDropdownIndicator from './dropdownIndicator';
|
|
9
11
|
import PopupFooter from './footer';
|
|
@@ -18,6 +20,7 @@ export const FilterPopupSelect = ({
|
|
|
18
20
|
totalCount = 0,
|
|
19
21
|
status,
|
|
20
22
|
buttonLabel,
|
|
23
|
+
searchPlaceholder,
|
|
21
24
|
showLoading = false,
|
|
22
25
|
isDisabled = false,
|
|
23
26
|
showHydrating = false,
|
|
@@ -137,17 +140,31 @@ export const FilterPopupSelect = ({
|
|
|
137
140
|
shouldCloseMenuOnTab: false,
|
|
138
141
|
hideSelectedOptions: false,
|
|
139
142
|
isLoading: showLoading,
|
|
140
|
-
placeholder: formatMessage(asyncPopupSelectMessages.selectPlaceholder)
|
|
143
|
+
placeholder: searchPlaceholder && fg('platform-linking-visual-refresh-sllv') ? searchPlaceholder : formatMessage(asyncPopupSelectMessages.selectPlaceholder)
|
|
141
144
|
// @ts-ignore - https://product-fabric.atlassian.net/browse/DSP-21000
|
|
142
145
|
,
|
|
143
146
|
menuListProps: menuListProps,
|
|
144
147
|
components: {
|
|
145
|
-
Option: CheckboxOption,
|
|
148
|
+
Option: fg('platform-linking-visual-refresh-sllv') ? CheckboxOptionVisualRefreshSllv : CheckboxOption,
|
|
146
149
|
Control: CustomControl,
|
|
147
150
|
MenuList: CustomMenuList,
|
|
148
151
|
DropdownIndicator: CustomDropdownIndicator,
|
|
149
152
|
LoadingIndicator: undefined // disables the three ... indicator in the searchbox when picker is loading
|
|
150
|
-
}
|
|
153
|
+
}
|
|
154
|
+
// eslint-disable-next-line @atlaskit/design-system/no-unsafe-style-overrides
|
|
155
|
+
,
|
|
156
|
+
styles: fg('platform-linking-visual-refresh-sllv') ? {
|
|
157
|
+
container: base => ({
|
|
158
|
+
...base,
|
|
159
|
+
paddingTop: "var(--ds-space-075, 6px)",
|
|
160
|
+
paddingBottom: 0
|
|
161
|
+
}),
|
|
162
|
+
menuList: base => ({
|
|
163
|
+
...base,
|
|
164
|
+
paddingTop: "var(--ds-space-050, 4px)",
|
|
165
|
+
paddingBottom: 0
|
|
166
|
+
})
|
|
167
|
+
} : undefined,
|
|
151
168
|
options: sortedOptions,
|
|
152
169
|
value: selectedOptions,
|
|
153
170
|
filterOption: noFilterOptions,
|
|
@@ -6,6 +6,7 @@ import { fg } from '@atlaskit/platform-feature-flags';
|
|
|
6
6
|
import { N500 } from '@atlaskit/theme/colors';
|
|
7
7
|
import { useDatasourceAnalyticsEvents } from '../../../../../analytics';
|
|
8
8
|
import { SpotError } from '../../../../../common/ui/spot/error-state/error';
|
|
9
|
+
import { SpotErrorOld } from '../../../../../common/ui/spot/error-state/error-old';
|
|
9
10
|
import { SEARCH_DEBOUNCE_MS } from '../constants';
|
|
10
11
|
import { asyncPopupSelectMessages } from './messages';
|
|
11
12
|
import CustomSelectMessage from './selectMessage';
|
|
@@ -47,15 +48,19 @@ const CustomErrorMessage = ({
|
|
|
47
48
|
formatMessage: noop
|
|
48
49
|
};
|
|
49
50
|
return /*#__PURE__*/React.createElement(CustomSelectMessage, {
|
|
50
|
-
icon: fg('
|
|
51
|
-
size:
|
|
51
|
+
icon: fg('platform-linking-visual-refresh-sllv') ? /*#__PURE__*/React.createElement(SpotError, {
|
|
52
|
+
size: "large",
|
|
52
53
|
alt: formatMessage(asyncPopupSelectMessages.errorMessage)
|
|
54
|
+
}) : fg('bandicoots-update-sllv-icons') ? /*#__PURE__*/React.createElement(SpotErrorOld, {
|
|
55
|
+
size: 'medium',
|
|
56
|
+
alt: formatMessage(asyncPopupSelectMessages.errorMessageOld)
|
|
53
57
|
}) : /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(ErrorIcon, {
|
|
54
58
|
primaryColor: `var(--ds-icon, ${N500})`,
|
|
55
59
|
label: "",
|
|
56
60
|
size: "xlarge"
|
|
57
61
|
})),
|
|
58
|
-
message: asyncPopupSelectMessages.errorMessage,
|
|
62
|
+
message: fg('platform-linking-visual-refresh-sllv') ? asyncPopupSelectMessages.errorMessage : asyncPopupSelectMessages.errorMessageOld,
|
|
63
|
+
description: fg('platform-linking-visual-refresh-sllv') ? asyncPopupSelectMessages.errorDescription : undefined,
|
|
59
64
|
testId: `${filterName}--error-message`
|
|
60
65
|
});
|
|
61
66
|
};
|
|
@@ -1,3 +1,6 @@
|
|
|
1
1
|
._19bv12x7{padding-left:var(--ds-space-075,6px)}
|
|
2
|
+
._19bvpxbi{padding-left:var(--ds-space-200,1pc)}
|
|
2
3
|
._ca0q12x7{padding-top:var(--ds-space-075,6px)}
|
|
3
|
-
._ca0qu2gc{padding-top:var(--ds-space-100,8px)}
|
|
4
|
+
._ca0qu2gc{padding-top:var(--ds-space-100,8px)}
|
|
5
|
+
._n3tdu2gc{padding-bottom:var(--ds-space-100,8px)}
|
|
6
|
+
._u5f3u2gc{padding-right:var(--ds-space-100,8px)}
|
|
@@ -2,6 +2,8 @@
|
|
|
2
2
|
import "./index.compiled.css";
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
5
|
+
import { cx } from '@compiled/react';
|
|
6
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
5
7
|
import { Box, Flex } from '@atlaskit/primitives/compiled';
|
|
6
8
|
import { components } from '@atlaskit/select';
|
|
7
9
|
import Spinner from '@atlaskit/spinner';
|
|
@@ -11,7 +13,8 @@ import CustomNoOptionsMessage from './noOptionsMessage';
|
|
|
11
13
|
import ShowMoreButton from './showMoreButton';
|
|
12
14
|
const styles = {
|
|
13
15
|
inlineSpinnerStyles: "_ca0q12x7",
|
|
14
|
-
|
|
16
|
+
showMoreButtonBoxStylesOld: "_19bv12x7 _ca0qu2gc",
|
|
17
|
+
showMoreButtonBoxStyles: "_ca0qu2gc _u5f3u2gc _n3tdu2gc _19bvpxbi"
|
|
15
18
|
};
|
|
16
19
|
const CustomMenuList = ({
|
|
17
20
|
children,
|
|
@@ -55,7 +58,7 @@ const CustomMenuList = ({
|
|
|
55
58
|
});
|
|
56
59
|
}
|
|
57
60
|
return /*#__PURE__*/React.createElement(React.Fragment, null, children, shouldDisplayShowMore && handleShowMore && /*#__PURE__*/React.createElement(Box, {
|
|
58
|
-
xcss: styles.showMoreButtonBoxStyles
|
|
61
|
+
xcss: cx(fg('platform-linking-visual-refresh-sllv') ? styles.showMoreButtonBoxStyles : styles.showMoreButtonBoxStylesOld)
|
|
59
62
|
}, /*#__PURE__*/React.createElement(ShowMoreButton, {
|
|
60
63
|
onShowMore: handleShowMore,
|
|
61
64
|
filterName: filterName
|
|
@@ -7,14 +7,34 @@ export const asyncPopupSelectMessages = defineMessages({
|
|
|
7
7
|
},
|
|
8
8
|
noOptionsMessage: {
|
|
9
9
|
id: 'linkDataSource.basic-filter.no-options-message',
|
|
10
|
+
defaultMessage: "We couldn't find anything matching your search",
|
|
11
|
+
description: 'The text for when no matches are found in dropdown'
|
|
12
|
+
},
|
|
13
|
+
noOptionsMessageOld: {
|
|
14
|
+
id: 'linkDataSource.basic-filter.no-options-message-old',
|
|
10
15
|
defaultMessage: 'No matches found',
|
|
11
16
|
description: 'The text for when no matches are found in dropdown'
|
|
12
17
|
},
|
|
18
|
+
noOptionsDescription: {
|
|
19
|
+
id: 'linkDataSource.basic-filter.no-options-description',
|
|
20
|
+
defaultMessage: 'Try again with a different term.',
|
|
21
|
+
description: 'The helper text for when no matches are found in dropdown'
|
|
22
|
+
},
|
|
13
23
|
errorMessage: {
|
|
14
|
-
id: 'linkDataSource.basic-filter.
|
|
24
|
+
id: 'linkDataSource.basic-filter.errorMessage',
|
|
25
|
+
defaultMessage: 'We ran into an issue trying to load results',
|
|
26
|
+
description: 'The text for when an error occurs when loading options'
|
|
27
|
+
},
|
|
28
|
+
errorMessageOld: {
|
|
29
|
+
id: 'linkDataSource.basic-filter.errorMessageOld',
|
|
15
30
|
defaultMessage: 'Something went wrong',
|
|
16
31
|
description: 'The text for when an error occurs when loading options'
|
|
17
32
|
},
|
|
33
|
+
errorDescription: {
|
|
34
|
+
id: 'linkDataSource.basic-filter.error-description',
|
|
35
|
+
defaultMessage: 'Check your connection and refresh',
|
|
36
|
+
description: 'The helper text for when no matches are found in dropdown'
|
|
37
|
+
},
|
|
18
38
|
showMoreMessage: {
|
|
19
39
|
id: 'linkDataSource.basic-filter.showMoreButton',
|
|
20
40
|
defaultMessage: 'Show more',
|
|
@@ -38,14 +38,15 @@ const CustomNoOptionsMessage = ({
|
|
|
38
38
|
};
|
|
39
39
|
return /*#__PURE__*/React.createElement(CustomSelectMessage, {
|
|
40
40
|
icon: fg('bandicoots-update-sllv-icons') ? /*#__PURE__*/React.createElement(SpotSearchNoResult, {
|
|
41
|
-
size: 'medium',
|
|
42
|
-
alt: formatMessage(asyncPopupSelectMessages.noOptionsMessage)
|
|
41
|
+
size: fg('platform-linking-visual-refresh-sllv') ? 'large' : 'medium',
|
|
42
|
+
alt: formatMessage(fg('platform-linking-visual-refresh-sllv') ? asyncPopupSelectMessages.noOptionsMessage : asyncPopupSelectMessages.noOptionsMessageOld)
|
|
43
43
|
}) : /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(QuestionCircleIcon, {
|
|
44
44
|
primaryColor: `var(--ds-icon, ${N500})`,
|
|
45
45
|
size: "xlarge",
|
|
46
46
|
label: ""
|
|
47
47
|
})),
|
|
48
|
-
message: asyncPopupSelectMessages.noOptionsMessage,
|
|
48
|
+
message: fg('platform-linking-visual-refresh-sllv') ? asyncPopupSelectMessages.noOptionsMessage : asyncPopupSelectMessages.noOptionsMessageOld,
|
|
49
|
+
description: fg('platform-linking-visual-refresh-sllv') ? asyncPopupSelectMessages.noOptionsDescription : undefined,
|
|
49
50
|
testId: `${filterName}--no-options-message`
|
|
50
51
|
});
|
|
51
52
|
};
|
|
@@ -1,6 +1,13 @@
|
|
|
1
|
+
|
|
2
|
+
._zulppxbi{gap:var(--ds-space-200,1pc)}._19bvoahv{padding-left:var(--ds-space-600,3pc)}
|
|
1
3
|
._19bvutpp{padding-left:var(--ds-space-150,9pt)}
|
|
4
|
+
._4t3i16xz{height:6pc}
|
|
2
5
|
._4t3ivbgk{height:4pc}
|
|
6
|
+
._ca0q1jfw{padding-top:var(--ds-space-500,40px)}
|
|
3
7
|
._ca0qu2gc{padding-top:var(--ds-space-100,8px)}
|
|
8
|
+
._n3td1jfw{padding-bottom:var(--ds-space-500,40px)}
|
|
4
9
|
._n3tdu2gc{padding-bottom:var(--ds-space-100,8px)}
|
|
5
10
|
._otyrpxbi{margin-bottom:var(--ds-space-200,1pc)}
|
|
6
|
-
.
|
|
11
|
+
._u5f3oahv{padding-right:var(--ds-space-600,3pc)}
|
|
12
|
+
._u5f3utpp{padding-right:var(--ds-space-150,9pt)}
|
|
13
|
+
._y3gn1h6o{text-align:center}
|
|
@@ -4,22 +4,41 @@ import { ax, ix } from "@compiled/react/runtime";
|
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { FormattedMessage } from 'react-intl-next';
|
|
6
6
|
import Heading from '@atlaskit/heading';
|
|
7
|
-
import {
|
|
7
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
|
+
import { Flex, Stack, Text } from '@atlaskit/primitives/compiled';
|
|
8
9
|
const styles = {
|
|
9
|
-
|
|
10
|
-
|
|
10
|
+
boxStylesOld: "_4t3ivbgk _otyrpxbi",
|
|
11
|
+
boxStyles: "_4t3i16xz",
|
|
12
|
+
stackStylesOld: "_ca0qu2gc _n3tdu2gc _19bvutpp _u5f3utpp",
|
|
13
|
+
stackStyles: "_zulppxbi _ca0q1jfw _n3td1jfw _19bvoahv _u5f3oahv _y3gn1h6o"
|
|
11
14
|
};
|
|
12
15
|
const CustomSelectMessage = ({
|
|
13
16
|
icon,
|
|
14
17
|
message,
|
|
18
|
+
description,
|
|
15
19
|
testId
|
|
16
20
|
}) => {
|
|
21
|
+
if (fg('platform-linking-visual-refresh-sllv')) {
|
|
22
|
+
return /*#__PURE__*/React.createElement(Stack, {
|
|
23
|
+
xcss: styles.stackStyles,
|
|
24
|
+
testId: testId,
|
|
25
|
+
alignInline: "center"
|
|
26
|
+
}, /*#__PURE__*/React.createElement(Flex, {
|
|
27
|
+
xcss: styles.boxStyles,
|
|
28
|
+
alignItems: "center",
|
|
29
|
+
justifyContent: "center"
|
|
30
|
+
}, icon), /*#__PURE__*/React.createElement(Heading, {
|
|
31
|
+
size: "small"
|
|
32
|
+
}, /*#__PURE__*/React.createElement(FormattedMessage, message)), description && /*#__PURE__*/React.createElement(Text, {
|
|
33
|
+
size: "medium"
|
|
34
|
+
}, /*#__PURE__*/React.createElement(FormattedMessage, description)));
|
|
35
|
+
}
|
|
17
36
|
return /*#__PURE__*/React.createElement(Stack, {
|
|
18
|
-
xcss: styles.
|
|
37
|
+
xcss: styles.stackStylesOld,
|
|
19
38
|
testId: testId,
|
|
20
39
|
alignInline: "center"
|
|
21
40
|
}, /*#__PURE__*/React.createElement(Flex, {
|
|
22
|
-
xcss: styles.
|
|
41
|
+
xcss: styles.boxStylesOld,
|
|
23
42
|
alignItems: "center",
|
|
24
43
|
justifyContent: "center"
|
|
25
44
|
}, icon), /*#__PURE__*/React.createElement(Heading, {
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import React, { useCallback } from 'react';
|
|
2
2
|
import { useIntl } from 'react-intl-next';
|
|
3
|
-
import
|
|
3
|
+
import ButtonOld from '@atlaskit/button';
|
|
4
|
+
import Button from '@atlaskit/button/new';
|
|
5
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
4
6
|
import { useDatasourceAnalyticsEvents } from '../../../../../analytics';
|
|
5
7
|
import { asyncPopupSelectMessages } from './messages';
|
|
6
8
|
const ShowMoreButton = ({
|
|
@@ -20,7 +22,15 @@ const ShowMoreButton = ({
|
|
|
20
22
|
});
|
|
21
23
|
onShowMore();
|
|
22
24
|
}, [filterName, fireEvent, onShowMore]);
|
|
23
|
-
|
|
25
|
+
if (fg('platform-linking-visual-refresh-sllv')) {
|
|
26
|
+
return /*#__PURE__*/React.createElement(Button, {
|
|
27
|
+
onClick: handleShowMore,
|
|
28
|
+
appearance: "subtle",
|
|
29
|
+
testId: `${filterName}--show-more-button`,
|
|
30
|
+
spacing: "compact"
|
|
31
|
+
}, formatMessage(asyncPopupSelectMessages.showMoreMessage));
|
|
32
|
+
}
|
|
33
|
+
return /*#__PURE__*/React.createElement(ButtonOld, {
|
|
24
34
|
onClick: handleShowMore,
|
|
25
35
|
appearance: "link",
|
|
26
36
|
testId: `${filterName}--show-more-button`
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
|
|
2
2
|
._y44vkmg5{animation:flickerAnimation 2s infinite}._18m915vq{overflow-y:hidden}
|
|
3
3
|
._18u01b66{margin-left:var(--ds-space-050,4px)}
|
|
4
|
+
._18u0utpp{margin-left:var(--ds-space-150,9pt)}
|
|
4
5
|
._1bto1l2s{text-overflow:ellipsis}
|
|
5
6
|
._1reo15vq{overflow-x:hidden}
|
|
6
7
|
._kqswh2mm{position:relative}
|
|
@@ -4,13 +4,17 @@ import "./trigger.compiled.css";
|
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
5
5
|
import React, { forwardRef, useCallback } from 'react';
|
|
6
6
|
import Badge from '@atlaskit/badge';
|
|
7
|
+
import NewButton from '@atlaskit/button/new';
|
|
7
8
|
import Button from '@atlaskit/button/standard-button';
|
|
8
|
-
import ChevronDownIcon from '@atlaskit/icon/utility/
|
|
9
|
+
import ChevronDownIcon from '@atlaskit/icon/utility/chevron-down';
|
|
10
|
+
import ChevronDownIconOld from '@atlaskit/icon/utility/migration/chevron-down';
|
|
11
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
9
12
|
import { Box, Flex } from '@atlaskit/primitives/compiled';
|
|
10
13
|
import Spinner from '@atlaskit/spinner';
|
|
11
14
|
const styles = {
|
|
12
15
|
triggerButtonLabelStyles: "_1reo15vq _18m915vq _1bto1l2s",
|
|
13
|
-
|
|
16
|
+
badgeStylesOld: "_18u01b66",
|
|
17
|
+
badgeStyles: "_18u0utpp"
|
|
14
18
|
};
|
|
15
19
|
|
|
16
20
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-styled
|
|
@@ -46,11 +50,10 @@ const PopupTrigger = /*#__PURE__*/forwardRef(({
|
|
|
46
50
|
}),
|
|
47
51
|
testId: `${triggerButtonTestId}--loading-button`
|
|
48
52
|
}, label)), [label, triggerButtonTestId]);
|
|
49
|
-
const DefaultButton = useCallback(() => /*#__PURE__*/React.createElement(
|
|
50
|
-
appearance: "default",
|
|
53
|
+
const DefaultButton = useCallback(() => fg('platform-linking-visual-refresh-sllv') ? /*#__PURE__*/React.createElement(NewButton, {
|
|
51
54
|
isSelected: isSelected || hasOptions,
|
|
52
55
|
isDisabled: isDisabled,
|
|
53
|
-
iconAfter: /*#__PURE__*/React.createElement(ChevronDownIcon, {
|
|
56
|
+
iconAfter: () => /*#__PURE__*/React.createElement(ChevronDownIcon, {
|
|
54
57
|
label: "",
|
|
55
58
|
color: "currentColor"
|
|
56
59
|
}),
|
|
@@ -62,6 +65,22 @@ const PopupTrigger = /*#__PURE__*/forwardRef(({
|
|
|
62
65
|
alignItems: "center"
|
|
63
66
|
}, /*#__PURE__*/React.createElement(Badge, {
|
|
64
67
|
appearance: "primary"
|
|
68
|
+
}, "+", selectedOptions.length - 1)))) : /*#__PURE__*/React.createElement(Button, {
|
|
69
|
+
appearance: "default",
|
|
70
|
+
isSelected: isSelected || hasOptions,
|
|
71
|
+
isDisabled: isDisabled,
|
|
72
|
+
iconAfter: /*#__PURE__*/React.createElement(ChevronDownIconOld, {
|
|
73
|
+
label: "",
|
|
74
|
+
color: "currentColor"
|
|
75
|
+
}),
|
|
76
|
+
testId: `${triggerButtonTestId}--button`
|
|
77
|
+
}, /*#__PURE__*/React.createElement(Flex, null, /*#__PURE__*/React.createElement(Box, {
|
|
78
|
+
xcss: styles.triggerButtonLabelStyles
|
|
79
|
+
}, label, firstOption && /*#__PURE__*/React.createElement(React.Fragment, null, ": ", firstOption.label)), selectedOptions && selectedOptions.length > 1 && /*#__PURE__*/React.createElement(Flex, {
|
|
80
|
+
xcss: styles.badgeStylesOld,
|
|
81
|
+
alignItems: "center"
|
|
82
|
+
}, /*#__PURE__*/React.createElement(Badge, {
|
|
83
|
+
appearance: "primary"
|
|
65
84
|
}, "+", selectedOptions.length - 1)))), [firstOption, hasOptions, isDisabled, isSelected, label, selectedOptions, triggerButtonTestId]);
|
|
66
85
|
|
|
67
86
|
/**
|
|
@@ -7,7 +7,7 @@ import { useMemo } from 'react';
|
|
|
7
7
|
import { useIntl } from 'react-intl-next';
|
|
8
8
|
import Button from '@atlaskit/button/new';
|
|
9
9
|
import Heading from '@atlaskit/heading';
|
|
10
|
-
import ChevronDownIcon from '@atlaskit/icon/utility/
|
|
10
|
+
import ChevronDownIcon from '@atlaskit/icon/utility/chevron-down';
|
|
11
11
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
12
12
|
import { Box } from '@atlaskit/primitives/compiled';
|
|
13
13
|
import Select, { PopupSelect } from '@atlaskit/select';
|
|
@@ -63,7 +63,10 @@ export const SiteSelector = props => {
|
|
|
63
63
|
...triggerProps
|
|
64
64
|
}) => /*#__PURE__*/React.createElement(Button, _extends({}, triggerProps, {
|
|
65
65
|
isSelected: isOpen,
|
|
66
|
-
iconAfter: ChevronDownIcon,
|
|
66
|
+
iconAfter: () => /*#__PURE__*/React.createElement(ChevronDownIcon, {
|
|
67
|
+
label: "",
|
|
68
|
+
color: "currentColor"
|
|
69
|
+
}),
|
|
67
70
|
testId: `${testId}__control`
|
|
68
71
|
}), (selectedSiteOption === null || selectedSiteOption === void 0 ? void 0 : selectedSiteOption.label) || formatMessage(siteSelectorMessages.chooseSite))
|
|
69
72
|
}) : /*#__PURE__*/React.createElement(Select, {
|
package/dist/es2019/ui/confluence-search-modal/basic-filters/filters/date-range-picker/trigger.js
CHANGED
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import React from 'react';
|
|
3
|
+
import NewButton from '@atlaskit/button/new';
|
|
3
4
|
import Button from '@atlaskit/button/standard-button';
|
|
4
|
-
import ChevronDownIcon from '@atlaskit/icon/utility/
|
|
5
|
+
import ChevronDownIcon from '@atlaskit/icon/utility/chevron-down';
|
|
6
|
+
import ChevronDownIconOld from '@atlaskit/icon/utility/migration/chevron-down';
|
|
7
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
5
8
|
export const PopupTrigger = ({
|
|
6
9
|
triggerProps,
|
|
7
10
|
isSelected,
|
|
@@ -9,6 +12,17 @@ export const PopupTrigger = ({
|
|
|
9
12
|
selectedLabel,
|
|
10
13
|
onClick
|
|
11
14
|
}) => {
|
|
15
|
+
if (fg('platform-linking-visual-refresh-sllv')) {
|
|
16
|
+
return /*#__PURE__*/React.createElement(NewButton, _extends({}, triggerProps, {
|
|
17
|
+
testId: 'confluence-search-modal--date-range-button',
|
|
18
|
+
onClick: onClick,
|
|
19
|
+
isSelected: isSelected,
|
|
20
|
+
iconAfter: () => /*#__PURE__*/React.createElement(ChevronDownIcon, {
|
|
21
|
+
label: "",
|
|
22
|
+
color: "currentColor"
|
|
23
|
+
})
|
|
24
|
+
}), labelPrefix, selectedLabel ? `: ${selectedLabel}` : '');
|
|
25
|
+
}
|
|
12
26
|
return /*#__PURE__*/React.createElement(Button, _extends({}, triggerProps, {
|
|
13
27
|
testId: 'confluence-search-modal--date-range-button',
|
|
14
28
|
onClick: onClick,
|
|
@@ -21,7 +35,7 @@ export const PopupTrigger = ({
|
|
|
21
35
|
display: 'flex',
|
|
22
36
|
alignItems: 'center'
|
|
23
37
|
}
|
|
24
|
-
}, /*#__PURE__*/React.createElement(
|
|
38
|
+
}, /*#__PURE__*/React.createElement(ChevronDownIconOld, {
|
|
25
39
|
LEGACY_size: "medium",
|
|
26
40
|
label: "",
|
|
27
41
|
color: "currentColor"
|
package/dist/es2019/ui/confluence-search-modal/confluence-search-container/index.compiled.css
CHANGED
|
@@ -1 +1,2 @@
|
|
|
1
|
-
._16jlkb7n{flex-grow:1}
|
|
1
|
+
._16jlkb7n{flex-grow:1}
|
|
2
|
+
._1bsb1osq{width:100%}
|
|
@@ -2,8 +2,10 @@
|
|
|
2
2
|
import "./index.compiled.css";
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React, { useCallback, useEffect, useRef, useState } from 'react';
|
|
5
|
+
import { useIntl } from 'react-intl-next';
|
|
5
6
|
import { useDebouncedCallback } from 'use-debounce';
|
|
6
|
-
import {
|
|
7
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
|
+
import { Box, Flex, Text } from '@atlaskit/primitives/compiled';
|
|
7
9
|
import { BasicSearchInput } from '../../common/modal/basic-search-input';
|
|
8
10
|
import { FILTER_SELECTION_DEBOUNCE_MS } from '../../common/modal/popup-select/constants';
|
|
9
11
|
import BasicFilters from '../basic-filters';
|
|
@@ -11,6 +13,7 @@ import { useBasicFilterHydration } from '../basic-filters/hooks/useBasicFilterHy
|
|
|
11
13
|
import { CLOLBasicFilters } from '../basic-filters/types';
|
|
12
14
|
import { searchMessages } from './messages';
|
|
13
15
|
const styles = {
|
|
16
|
+
basicSearchInputBoxStyles: "_1bsb1osq",
|
|
14
17
|
basicSearchInputContainerStyles: "_16jlkb7n"
|
|
15
18
|
};
|
|
16
19
|
const ConfluenceSearchContainer = ({
|
|
@@ -43,6 +46,9 @@ const ConfluenceSearchContainer = ({
|
|
|
43
46
|
to: lastModifiedTo
|
|
44
47
|
}]
|
|
45
48
|
} : {});
|
|
49
|
+
const {
|
|
50
|
+
formatMessage
|
|
51
|
+
} = useIntl();
|
|
46
52
|
const handleSearchChange = useCallback(e => {
|
|
47
53
|
const rawSearch = e.currentTarget.value;
|
|
48
54
|
setSearchBarSearchString(rawSearch);
|
|
@@ -88,7 +94,9 @@ const ConfluenceSearchContainer = ({
|
|
|
88
94
|
});
|
|
89
95
|
}
|
|
90
96
|
}, [users, status, filterSelections.lastModified]);
|
|
91
|
-
return /*#__PURE__*/React.createElement(
|
|
97
|
+
return /*#__PURE__*/React.createElement(Box, {
|
|
98
|
+
xcss: styles.basicSearchInputBoxStyles
|
|
99
|
+
}, /*#__PURE__*/React.createElement(Flex, {
|
|
92
100
|
alignItems: "center",
|
|
93
101
|
xcss: styles.basicSearchInputContainerStyles
|
|
94
102
|
}, /*#__PURE__*/React.createElement(BasicSearchInput, {
|
|
@@ -98,12 +106,17 @@ const ConfluenceSearchContainer = ({
|
|
|
98
106
|
onSearch: onSearch,
|
|
99
107
|
searchTerm: searchBarSearchString,
|
|
100
108
|
placeholder: searchMessages.searchLabel,
|
|
109
|
+
ariaLabel: searchMessages.searchLabel,
|
|
101
110
|
fullWidth: false
|
|
102
111
|
}), /*#__PURE__*/React.createElement(BasicFilters, {
|
|
103
112
|
cloudId: cloudId,
|
|
104
113
|
selections: filterSelections,
|
|
105
114
|
onChange: handleBasicFilterSelectionChange,
|
|
106
115
|
isHydrating: status === 'loading'
|
|
107
|
-
}))
|
|
116
|
+
})), fg('platform-linking-visual-refresh-sllv') && /*#__PURE__*/React.createElement(Text, {
|
|
117
|
+
size: "small",
|
|
118
|
+
color: "color.text.subtlest",
|
|
119
|
+
testId: "confluence-search-placeholder"
|
|
120
|
+
}, formatMessage(searchMessages.searchLabel)));
|
|
108
121
|
};
|
|
109
122
|
export default ConfluenceSearchContainer;
|
|
@@ -2,6 +2,7 @@ import React, { useCallback, useEffect, useRef, useState } from 'react';
|
|
|
2
2
|
import isEqual from 'lodash/isEqual';
|
|
3
3
|
import { useIntl } from 'react-intl-next';
|
|
4
4
|
import { useDebouncedCallback } from 'use-debounce';
|
|
5
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
5
6
|
import { FilterPopupSelect } from '../../../../common/modal/popup-select';
|
|
6
7
|
import { SEARCH_DEBOUNCE_MS } from '../../../../common/modal/popup-select/constants';
|
|
7
8
|
import { useFilterOptions } from '../../hooks/useFilterOptions';
|
|
@@ -85,7 +86,7 @@ const AsyncPopupSelect = ({
|
|
|
85
86
|
const filterName = `jlol-basic-filter-${filterType}`;
|
|
86
87
|
const shouldShowFooter = (status === 'resolved' || isLoadingMore) && filterOptionsLength > 0; // footer should not disappear when there is an inline spinner for loading more data
|
|
87
88
|
const shouldDisplayShowMoreButton = status === 'resolved' && !!pageCursor && !areAllResultsLoaded;
|
|
88
|
-
const triggerButtonLabel = formatMessage(asyncPopupSelectMessages[`${filterType}Label`]);
|
|
89
|
+
const triggerButtonLabel = formatMessage(!fg('platform-linking-visual-refresh-sllv') && filterType === 'type' ? asyncPopupSelectMessages.typeLabelOld : asyncPopupSelectMessages[`${filterType}Label`]);
|
|
89
90
|
return /*#__PURE__*/React.createElement(FilterPopupSelect, {
|
|
90
91
|
filterName: filterName,
|
|
91
92
|
status: status,
|
|
@@ -97,6 +98,7 @@ const AsyncPopupSelect = ({
|
|
|
97
98
|
selectedOptions: selectedOptions,
|
|
98
99
|
options: popupSelectOptions,
|
|
99
100
|
buttonLabel: triggerButtonLabel,
|
|
101
|
+
searchPlaceholder: fg('platform-linking-visual-refresh-sllv') ? formatMessage(asyncPopupSelectMessages[`${filterType}SearchPlaceholder`]) : undefined,
|
|
100
102
|
onInputChange: handleInputChange,
|
|
101
103
|
onSelectionChange: handleOptionSelection,
|
|
102
104
|
onMenuOpen: handleMenuOpen,
|
|
@@ -13,11 +13,36 @@ export const asyncPopupSelectMessages = defineMessages({
|
|
|
13
13
|
typeLabel: {
|
|
14
14
|
id: 'linkDataSource.basic-filter.type.label',
|
|
15
15
|
description: 'Label to be displayed for type filter dropdown button.',
|
|
16
|
+
defaultMessage: 'Work type'
|
|
17
|
+
},
|
|
18
|
+
typeLabelOld: {
|
|
19
|
+
id: 'linkDataSource.basic-filter.type.labelOld',
|
|
20
|
+
description: 'Label to be displayed for type filter dropdown button.',
|
|
16
21
|
defaultMessage: 'Type'
|
|
17
22
|
},
|
|
18
23
|
assigneeLabel: {
|
|
19
24
|
id: 'linkDataSource.basic-filter.assignee.label',
|
|
20
25
|
description: 'Label to be displayed for assignee filter dropdown button.',
|
|
21
26
|
defaultMessage: 'Assignee'
|
|
27
|
+
},
|
|
28
|
+
projectSearchPlaceholder: {
|
|
29
|
+
id: 'linkDataSource.basic-filter.project.searchPlaceholder',
|
|
30
|
+
description: 'Placeholder to be displayed for project filter dropdown search input.',
|
|
31
|
+
defaultMessage: 'Search for projects'
|
|
32
|
+
},
|
|
33
|
+
statusSearchPlaceholder: {
|
|
34
|
+
id: 'linkDataSource.basic-filter.status.searchPlaceholder',
|
|
35
|
+
description: 'Placeholder to be displayed for status filter dropdown search input.',
|
|
36
|
+
defaultMessage: 'Search for status'
|
|
37
|
+
},
|
|
38
|
+
typeSearchPlaceholder: {
|
|
39
|
+
id: 'linkDataSource.basic-filter.type.searchPlaceholder',
|
|
40
|
+
description: 'Placeholder to be displayed for work type filter dropdown search input.',
|
|
41
|
+
defaultMessage: 'Search for work type'
|
|
42
|
+
},
|
|
43
|
+
assigneeSearchPlaceholder: {
|
|
44
|
+
id: 'linkDataSource.basic-filter.assignee.searchPlaceholder',
|
|
45
|
+
description: 'Placeholder to be displayed for assignee filter dropdown search input.',
|
|
46
|
+
defaultMessage: 'Search for assignee'
|
|
22
47
|
}
|
|
23
48
|
});
|
|
@@ -4,7 +4,8 @@ import { ax, ix } from "@compiled/react/runtime";
|
|
|
4
4
|
import React, { useCallback, useEffect, useMemo, useState } from 'react';
|
|
5
5
|
import { useIntl } from 'react-intl-next';
|
|
6
6
|
import { useDebouncedCallback } from 'use-debounce';
|
|
7
|
-
import {
|
|
7
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
|
+
import { Box, Flex, Text } from '@atlaskit/primitives/compiled';
|
|
8
9
|
import { useDatasourceAnalyticsEvents } from '../../../analytics';
|
|
9
10
|
import { BasicSearchInput } from '../../common/modal/basic-search-input';
|
|
10
11
|
import { basicSearchInputMessages } from '../../common/modal/basic-search-input/messages';
|
|
@@ -17,8 +18,11 @@ import { JiraJQLEditor } from '../jql-editor';
|
|
|
17
18
|
import { buildJQL } from './buildJQL';
|
|
18
19
|
import { modeSwitcherMessages } from './messages';
|
|
19
20
|
const styles = {
|
|
21
|
+
basicSearchInputBoxStyles: "_1bsb1osq",
|
|
20
22
|
basicSearchInputContainerStyles: "_16jlkb7n",
|
|
21
|
-
|
|
23
|
+
inputContainerStylesOld: "_4cvr1q9y _1e0c1txw _1tket9kd",
|
|
24
|
+
inputContainerStyles: "_4cvr1y6m _1e0c1txw _1tket9kd",
|
|
25
|
+
modeSwitcherContainerStyles: "_19pk1b66"
|
|
22
26
|
};
|
|
23
27
|
export const DEFAULT_JQL_QUERY = 'ORDER BY created DESC';
|
|
24
28
|
export const ALLOWED_ORDER_BY_KEYS = ['key', 'summary', 'assignee', 'status', 'created'];
|
|
@@ -171,9 +175,51 @@ export const JiraSearchContainer = props => {
|
|
|
171
175
|
setCloudId(currentCloudId);
|
|
172
176
|
}
|
|
173
177
|
}, [currentCloudId, cloudId, setSearchBarJql]);
|
|
178
|
+
if (fg('platform-linking-visual-refresh-sllv')) {
|
|
179
|
+
return /*#__PURE__*/React.createElement("div", {
|
|
180
|
+
"data-testid": "jira-search-container",
|
|
181
|
+
className: ax([styles.inputContainerStyles])
|
|
182
|
+
}, currentSearchMethod === 'basic' && /*#__PURE__*/React.createElement(Box, {
|
|
183
|
+
xcss: styles.basicSearchInputBoxStyles
|
|
184
|
+
}, /*#__PURE__*/React.createElement(Flex, {
|
|
185
|
+
alignItems: "center",
|
|
186
|
+
xcss: styles.basicSearchInputContainerStyles
|
|
187
|
+
}, /*#__PURE__*/React.createElement(BasicSearchInput, {
|
|
188
|
+
isSearching: isSearching,
|
|
189
|
+
onChange: handleBasicSearchChange,
|
|
190
|
+
onSearch: handleSearch,
|
|
191
|
+
searchTerm: basicSearchTerm,
|
|
192
|
+
placeholder: basicSearchInputMessages.basicTextSearchLabel,
|
|
193
|
+
ariaLabel: basicSearchInputMessages.basicTextSearchLabel,
|
|
194
|
+
testId: "jira-datasource-modal",
|
|
195
|
+
fullWidth: false
|
|
196
|
+
}), /*#__PURE__*/React.createElement(BasicFilters, {
|
|
197
|
+
jql: searchBarJql,
|
|
198
|
+
site: site,
|
|
199
|
+
onChange: handleBasicFilterSelectionChange,
|
|
200
|
+
selections: filterSelections,
|
|
201
|
+
isJQLHydrating: basicFilterHydrationStatus === 'loading'
|
|
202
|
+
})), currentSearchMethod === 'basic' && /*#__PURE__*/React.createElement(Text, {
|
|
203
|
+
size: "small",
|
|
204
|
+
color: "color.text.subtlest",
|
|
205
|
+
testId: "jira-search-placeholder"
|
|
206
|
+
}, formatMessage(basicSearchInputMessages.basicTextSearchLabel))), currentSearchMethod === 'jql' && /*#__PURE__*/React.createElement(JiraJQLEditor, {
|
|
207
|
+
cloudId: cloudId || '',
|
|
208
|
+
isSearching: isSearching,
|
|
209
|
+
onChange: onQueryChange,
|
|
210
|
+
onSearch: handleSearch,
|
|
211
|
+
query: searchBarJql
|
|
212
|
+
}), /*#__PURE__*/React.createElement(Box, {
|
|
213
|
+
xcss: styles.modeSwitcherContainerStyles
|
|
214
|
+
}, /*#__PURE__*/React.createElement(ModeSwitcher, {
|
|
215
|
+
onOptionValueChange: onSearchMethodChange,
|
|
216
|
+
selectedOptionValue: currentSearchMethod,
|
|
217
|
+
options: modeSwitcherOptions
|
|
218
|
+
})));
|
|
219
|
+
}
|
|
174
220
|
return /*#__PURE__*/React.createElement("div", {
|
|
175
221
|
"data-testid": "jira-search-container",
|
|
176
|
-
className: ax([styles.
|
|
222
|
+
className: ax([styles.inputContainerStylesOld])
|
|
177
223
|
}, currentSearchMethod === 'basic' && /*#__PURE__*/React.createElement(Flex, {
|
|
178
224
|
alignItems: "center",
|
|
179
225
|
xcss: styles.basicSearchInputContainerStyles
|
|
@@ -183,6 +229,7 @@ export const JiraSearchContainer = props => {
|
|
|
183
229
|
onSearch: handleSearch,
|
|
184
230
|
searchTerm: basicSearchTerm,
|
|
185
231
|
placeholder: basicSearchInputMessages.basicTextSearchLabel,
|
|
232
|
+
ariaLabel: basicSearchInputMessages.basicTextSearchLabel,
|
|
186
233
|
testId: "jira-datasource-modal",
|
|
187
234
|
fullWidth: false
|
|
188
235
|
}), /*#__PURE__*/React.createElement(BasicFilters, {
|
|
@@ -1,5 +1,8 @@
|
|
|
1
|
-
<svg
|
|
2
|
-
<path d="
|
|
3
|
-
<path fill
|
|
4
|
-
<path fill
|
|
1
|
+
<svg xmlns="http://www.w3.org/2000/svg" fill="none" viewBox="0 0 275 275">
|
|
2
|
+
<path fill="#4B4D51" d="M191.87 88.67c-2.28-4.36-5.07-8.68-8.3-12.86-3.27-4.23-6.8-8.07-10.5-11.4-21.6-19.51-49.11-22.5-75.49-8.19a93.066 93.066 0 0 0-12.54 8.22 94.563 94.563 0 0 0-11.53 10.51c-20.39 22.01-24.43 49.35-11.09 75.03 2.3 4.42 5.12 8.81 8.39 13.04 3.23 4.18 6.72 7.96 10.37 11.26 12.5 11.29 27.05 17.01 42.25 17.01 10.9 0 22.13-2.94 33.18-8.88 4.46-2.4 8.86-5.26 13.07-8.52 4.06-3.14 7.79-6.53 11.11-10.07 20.52-21.96 24.56-49.35 11.08-75.14v-.01Zm-30.56 74.37c-3.61 2.79-7.37 5.25-11.17 7.29-21.38 11.48-42.6 9.27-59.76-6.23-3.05-2.76-5.98-5.94-8.72-9.48-2.77-3.59-5.16-7.28-7.08-10.97-10.67-20.53-7.48-41.63 8.98-59.4 2.93-3.17 6.25-6.19 9.86-8.98 3.47-2.69 7.07-5.04 10.7-7.01 8.96-4.86 17.91-7.28 26.57-7.28 11.89 0 23.21 4.56 33.2 13.59 3.09 2.79 6.07 6.03 8.84 9.62 2.73 3.54 5.09 7.18 6.99 10.82 10.77 20.62 7.6 41.73-8.95 59.44-2.81 3.01-6 5.9-9.48 8.59h.02Z"/>
|
|
3
|
+
<path fill="#4B4D51" d="M179.96 171c-3.54-4.93-7.34-4.9-11.05-2.03-3.48 2.69-4.41 6.33-.7 11.12l4.24 5.48 11.75-9.09-4.24-5.48Z"/>
|
|
4
|
+
<path fill="#4B4D51" d="m187.155 174.199-17.642 13.64 33.152 42.878 17.642-13.64-33.152-42.878Z"/>
|
|
5
|
+
<path fill="#7E8188" d="m184.32 176.391-11.97 9.255 11.243 14.54 11.969-9.254-11.242-14.541Z"/>
|
|
6
|
+
<path fill="#4B4D51" fill-rule="evenodd" d="m157.715 95.826-53.98 53.979-7.07-7.071 53.979-53.98 7.071 7.072Z" clip-rule="evenodd"/>
|
|
7
|
+
<path fill="#4B4D51" fill-rule="evenodd" d="m150.644 149.805-53.98-53.98 7.071-7.07 53.98 53.979-7.071 7.071Z" clip-rule="evenodd"/>
|
|
5
8
|
</svg>
|