@atlaskit/link-picker 1.46.0 → 1.47.0

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 CHANGED
@@ -1,5 +1,21 @@
1
1
  # @atlaskit/link-picker
2
2
 
3
+ ## 1.47.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#147531](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/147531)
8
+ [`b599457543db5`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/b599457543db5) -
9
+ Officially enables/uses the `emptyStateNoResults` option from plugins to render a custom empty
10
+ state screen when there is no active query (via cleanup of
11
+ platform.linking-platform.link-picker.enable-empty-state ff).
12
+
13
+ ## 1.46.1
14
+
15
+ ### Patch Changes
16
+
17
+ - Updated dependencies
18
+
3
19
  ## 1.46.0
4
20
 
5
21
  ### Minor Changes
@@ -11,7 +11,6 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
11
11
  var _react = require("react");
12
12
  var _react2 = require("@emotion/react");
13
13
  var _reactIntlNext = require("react-intl-next");
14
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
15
14
  var _primitives = require("@atlaskit/primitives");
16
15
  var _spinner = _interopRequireDefault(require("@atlaskit/spinner"));
17
16
  var _visuallyHidden = _interopRequireDefault(require("@atlaskit/visually-hidden"));
@@ -110,15 +109,13 @@ var LinkSearchList = exports.LinkSearchList = /*#__PURE__*/(0, _react.forwardRef
110
109
  }
111
110
  }, [activeIndex, items, onKeyDown]);
112
111
  if ((items === null || items === void 0 ? void 0 : items.length) === 0) {
113
- if ((0, _platformFeatureFlags.fg)('platform.linking-platform.link-picker.enable-empty-state')) {
114
- if (!hasSearchTerm) {
115
- var _activePlugin$emptySt;
116
- var emptyState = activePlugin === null || activePlugin === void 0 || (_activePlugin$emptySt = activePlugin.emptyStateNoResults) === null || _activePlugin$emptySt === void 0 ? void 0 : _activePlugin$emptySt.call(activePlugin);
117
- if (emptyState) {
118
- return (0, _react2.jsx)(_primitives.Box, {
119
- xcss: emptyStateNoResultsWrapper
120
- }, emptyState);
121
- }
112
+ if (!hasSearchTerm) {
113
+ var _activePlugin$emptySt;
114
+ var emptyState = activePlugin === null || activePlugin === void 0 || (_activePlugin$emptySt = activePlugin.emptyStateNoResults) === null || _activePlugin$emptySt === void 0 ? void 0 : _activePlugin$emptySt.call(activePlugin);
115
+ if (emptyState) {
116
+ return (0, _react2.jsx)(_primitives.Box, {
117
+ xcss: emptyStateNoResultsWrapper
118
+ }, emptyState);
122
119
  }
123
120
  }
124
121
  return (0, _react2.jsx)(_linkSearchNoResults.NoResults, null);
@@ -31,7 +31,7 @@ var testIds = exports.testIds = {
31
31
  };
32
32
  var PACKAGE_DATA = exports.PACKAGE_DATA = {
33
33
  packageName: "@atlaskit/link-picker" || '',
34
- packageVersion: "1.46.0" || '',
34
+ packageVersion: "1.47.0" || '',
35
35
  componentName: _constants.COMPONENT_NAME,
36
36
  source: _constants.COMPONENT_NAME
37
37
  };
@@ -8,7 +8,6 @@ import { forwardRef, Fragment, useCallback, useRef } from 'react';
8
8
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
9
9
  import { jsx } from '@emotion/react';
10
10
  import { defineMessages, FormattedMessage } from 'react-intl-next';
11
- import { fg } from '@atlaskit/platform-feature-flags';
12
11
  import { Box, xcss } from '@atlaskit/primitives';
13
12
  import Spinner from '@atlaskit/spinner';
14
13
  import VisuallyHidden from '@atlaskit/visually-hidden';
@@ -104,15 +103,13 @@ export const LinkSearchList = /*#__PURE__*/forwardRef(({
104
103
  }
105
104
  }, [activeIndex, items, onKeyDown]);
106
105
  if ((items === null || items === void 0 ? void 0 : items.length) === 0) {
107
- if (fg('platform.linking-platform.link-picker.enable-empty-state')) {
108
- if (!hasSearchTerm) {
109
- var _activePlugin$emptySt;
110
- const emptyState = activePlugin === null || activePlugin === void 0 ? void 0 : (_activePlugin$emptySt = activePlugin.emptyStateNoResults) === null || _activePlugin$emptySt === void 0 ? void 0 : _activePlugin$emptySt.call(activePlugin);
111
- if (emptyState) {
112
- return jsx(Box, {
113
- xcss: emptyStateNoResultsWrapper
114
- }, emptyState);
115
- }
106
+ if (!hasSearchTerm) {
107
+ var _activePlugin$emptySt;
108
+ const emptyState = activePlugin === null || activePlugin === void 0 ? void 0 : (_activePlugin$emptySt = activePlugin.emptyStateNoResults) === null || _activePlugin$emptySt === void 0 ? void 0 : _activePlugin$emptySt.call(activePlugin);
109
+ if (emptyState) {
110
+ return jsx(Box, {
111
+ xcss: emptyStateNoResultsWrapper
112
+ }, emptyState);
116
113
  }
117
114
  }
118
115
  return jsx(NoResults, null);
@@ -19,7 +19,7 @@ export const testIds = {
19
19
  };
20
20
  export const PACKAGE_DATA = {
21
21
  packageName: "@atlaskit/link-picker" || '',
22
- packageVersion: "1.46.0" || '',
22
+ packageVersion: "1.47.0" || '',
23
23
  componentName: COMPONENT_NAME,
24
24
  source: COMPONENT_NAME
25
25
  };
@@ -13,7 +13,6 @@ import { forwardRef, Fragment, useCallback, useRef } from 'react';
13
13
  // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
14
14
  import { jsx } from '@emotion/react';
15
15
  import { defineMessages, FormattedMessage } from 'react-intl-next';
16
- import { fg } from '@atlaskit/platform-feature-flags';
17
16
  import { Box, xcss } from '@atlaskit/primitives';
18
17
  import Spinner from '@atlaskit/spinner';
19
18
  import VisuallyHidden from '@atlaskit/visually-hidden';
@@ -106,15 +105,13 @@ export var LinkSearchList = /*#__PURE__*/forwardRef(function (_ref, ref) {
106
105
  }
107
106
  }, [activeIndex, items, onKeyDown]);
108
107
  if ((items === null || items === void 0 ? void 0 : items.length) === 0) {
109
- if (fg('platform.linking-platform.link-picker.enable-empty-state')) {
110
- if (!hasSearchTerm) {
111
- var _activePlugin$emptySt;
112
- var emptyState = activePlugin === null || activePlugin === void 0 || (_activePlugin$emptySt = activePlugin.emptyStateNoResults) === null || _activePlugin$emptySt === void 0 ? void 0 : _activePlugin$emptySt.call(activePlugin);
113
- if (emptyState) {
114
- return jsx(Box, {
115
- xcss: emptyStateNoResultsWrapper
116
- }, emptyState);
117
- }
108
+ if (!hasSearchTerm) {
109
+ var _activePlugin$emptySt;
110
+ var emptyState = activePlugin === null || activePlugin === void 0 || (_activePlugin$emptySt = activePlugin.emptyStateNoResults) === null || _activePlugin$emptySt === void 0 ? void 0 : _activePlugin$emptySt.call(activePlugin);
111
+ if (emptyState) {
112
+ return jsx(Box, {
113
+ xcss: emptyStateNoResultsWrapper
114
+ }, emptyState);
118
115
  }
119
116
  }
120
117
  return jsx(NoResults, null);
@@ -20,7 +20,7 @@ export var testIds = {
20
20
  };
21
21
  export var PACKAGE_DATA = {
22
22
  packageName: "@atlaskit/link-picker" || '',
23
- packageVersion: "1.46.0" || '',
23
+ packageVersion: "1.47.0" || '',
24
24
  componentName: COMPONENT_NAME,
25
25
  source: COMPONENT_NAME
26
26
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/link-picker",
3
- "version": "1.46.0",
3
+ "version": "1.47.0",
4
4
  "description": "Standalone link picker",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "publishConfig": {
@@ -35,9 +35,6 @@
35
35
  "./lazy": "./src/lazy.ts"
36
36
  },
37
37
  "platform-feature-flags": {
38
- "platform.linking-platform.link-picker.enable-empty-state": {
39
- "type": "boolean"
40
- },
41
38
  "platform.linking-platform.link-picker.enable-jira-create": {
42
39
  "type": "boolean"
43
40
  }
@@ -52,7 +49,7 @@
52
49
  "@atlaskit/form": "^10.5.0",
53
50
  "@atlaskit/frontend-utilities": "^2.7.0",
54
51
  "@atlaskit/heading": "^2.4.0",
55
- "@atlaskit/icon": "^22.18.0",
52
+ "@atlaskit/icon": "^22.20.0",
56
53
  "@atlaskit/intl-messages-provider": "^1.0.2",
57
54
  "@atlaskit/linking-common": "^5.11.0",
58
55
  "@atlaskit/onboarding": "^11.15.0",
@@ -62,7 +59,7 @@
62
59
  "@atlaskit/tabs": "^16.4.0",
63
60
  "@atlaskit/textfield": "^6.5.0",
64
61
  "@atlaskit/theme": "^13.0.0",
65
- "@atlaskit/tokens": "^1.61.0",
62
+ "@atlaskit/tokens": "^2.0.0",
66
63
  "@atlaskit/tooltip": "^18.7.0",
67
64
  "@atlaskit/ufo": "^0.3.0",
68
65
  "@atlaskit/visually-hidden": "^1.5.0",