@atlaskit/link-picker 4.0.2 → 4.1.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,24 @@
1
1
  # @atlaskit/link-picker
2
2
 
3
+ ## 4.1.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [`7117e5c06e992`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/7117e5c06e992) -
8
+ [ux] ENGHEALTH-45703 fixing a11y violation aria-valid-attr-value for plugin search results error
9
+ screen
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies
14
+
15
+ ## 4.0.3
16
+
17
+ ### Patch Changes
18
+
19
+ - [`c37544224e3fd`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/c37544224e3fd) -
20
+ NAVX-2340 cleaning up navx-2134-fix-a11y-link-picker-headings
21
+
3
22
  ## 4.0.2
4
23
 
5
24
  ### Patch Changes
@@ -12,6 +12,7 @@ var _react = _interopRequireWildcard(require("react"));
12
12
  var React = _react;
13
13
  var _runtime = require("@compiled/react/runtime");
14
14
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
15
+ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
15
16
  var _compiled = require("@atlaskit/primitives/compiled");
16
17
  var _spinner = _interopRequireDefault(require("@atlaskit/spinner/spinner"));
17
18
  var _tabs = _interopRequireWildcard(require("@atlaskit/tabs"));
@@ -61,6 +62,12 @@ var SearchResults = exports.SearchResults = function SearchResults(_ref) {
61
62
  testId: testIds.tabItem
62
63
  }, tab.tabTitle);
63
64
  }));
65
+ var ErrorWrapper = function ErrorWrapper(_ref2) {
66
+ var children = _ref2.children;
67
+ return !!tabs.length && (0, _platformFeatureFlags.fg)('fix_invalid_aria_attr_in_link_picker_search_error') ? /*#__PURE__*/React.createElement("div", {
68
+ id: "".concat(testIds.tabList, "-").concat(activeTab, "-tab")
69
+ }, children) : children;
70
+ };
64
71
  return /*#__PURE__*/React.createElement(_searchResultsContainer.SearchResultsContainer, {
65
72
  hasTabs: !!tabs.length || isLoadingPlugins,
66
73
  adaptiveHeight: adaptiveHeight,
@@ -96,7 +103,7 @@ var SearchResults = exports.SearchResults = function SearchResults(_ref) {
96
103
  adaptiveHeight: adaptiveHeight,
97
104
  tabPanelId: "".concat(testIds.tabList, "-").concat(activeTab, "-tab"),
98
105
  shouldRenderNoResultsImage: shouldRenderNoResultsImage
99
- }), error ? (_activePlugin$errorFa = activePlugin === null || activePlugin === void 0 || (_activePlugin$errorFa2 = activePlugin.errorFallback) === null || _activePlugin$errorFa2 === void 0 ? void 0 : _activePlugin$errorFa2.call(activePlugin, error, retry)) !== null && _activePlugin$errorFa !== void 0 ? _activePlugin$errorFa : /*#__PURE__*/React.createElement(_linkSearchError.LinkSearchError, {
106
+ }), error ? (_activePlugin$errorFa = activePlugin === null || activePlugin === void 0 || (_activePlugin$errorFa2 = activePlugin.errorFallback) === null || _activePlugin$errorFa2 === void 0 ? void 0 : _activePlugin$errorFa2.call(activePlugin, error, retry)) !== null && _activePlugin$errorFa !== void 0 ? _activePlugin$errorFa : /*#__PURE__*/React.createElement(ErrorWrapper, null, /*#__PURE__*/React.createElement(_linkSearchError.LinkSearchError, {
100
107
  onRetry: retry
101
- }) : null));
108
+ })) : null));
102
109
  };
@@ -1,6 +1,5 @@
1
- ._11c81o8v{font:var(--ds-font-body-small,normal 400 11px/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,"Helvetica Neue",sans-serif)}
2
- ._qtt8glyw{list-style:none}
3
- ._16jlkb7n{flex-grow:1}
1
+
2
+ ._qtt8glyw{list-style:none}._16jlkb7n{flex-grow:1}
4
3
  ._18u01mjz{margin-left:calc(var(--link-picker-padding-left)*-1)}
5
4
  ._19bvze3t{padding-left:var(--ds-space-0,0)}
6
5
  ._19pkpxbi{margin-top:var(--ds-space-200,1pc)}
@@ -14,10 +13,7 @@
14
13
  ._4cvr1h6o{align-items:center}
15
14
  ._ca0qidpf{padding-top:0}
16
15
  ._ca0qze3t{padding-top:var(--ds-space-0,0)}
17
- ._k48pmoej{font-weight:var(--ds-font-weight-bold,700)}
18
16
  ._n3tdze3t{padding-bottom:var(--ds-space-0,0)}
19
- ._otyr1b66{margin-bottom:var(--ds-space-050,4px)}
20
17
  ._otyrpxbi{margin-bottom:var(--ds-space-200,1pc)}
21
18
  ._otyrze3t{margin-bottom:var(--ds-space-0,0)}
22
- ._syazazsu{color:var(--ds-text-subtle,#505258)}
23
19
  ._u5f3ze3t{padding-right:var(--ds-space-0,0)}
@@ -24,7 +24,7 @@ var _handleNavKeyDown = require("../../../../common/utils/handleNavKeyDown");
24
24
  var _linkSearchNoResults = require("./link-search-no-results");
25
25
  var _listItem = require("./list-item");
26
26
  var _useTrackResultsShown = require("./use-track-results-shown");
27
- var _excluded = ["onChange", "onSelect", "onKeyDown", "items", "activeIndex", "selectedIndex", "isLoading", "ariaControls", "ariaLabelledBy", "ariaReadOnly", "role", "id", "hasSearchTerm", "activePlugin", "adaptiveHeight", "className", "tabPanelId", "shouldRenderNoResultsImage"];
27
+ var _excluded = ["onChange", "onSelect", "onKeyDown", "items", "activeIndex", "selectedIndex", "isLoading", "ariaReadOnly", "role", "id", "hasSearchTerm", "activePlugin", "adaptiveHeight", "className", "tabPanelId", "shouldRenderNoResultsImage"];
28
28
  function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
29
29
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
30
30
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { (0, _defineProperty2.default)(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
@@ -34,8 +34,6 @@ var styles = {
34
34
  var listContainerStyles = null;
35
35
  var spinnerContainerStyles = null;
36
36
  var listStyles = null;
37
- var baseListTitleStyles = null;
38
- var newListTitleStyles = null;
39
37
  var listTitleStyles = {
40
38
  font: "var(--ds-font-body-small, normal 400 11px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, \"Helvetica Neue\", sans-serif)",
41
39
  fontWeight: "var(--ds-font-weight-bold, 700)",
@@ -79,8 +77,6 @@ var LinkSearchList = exports.LinkSearchList = /*#__PURE__*/(0, _react.forwardRef
79
77
  activeIndex = _ref.activeIndex,
80
78
  selectedIndex = _ref.selectedIndex,
81
79
  isLoading = _ref.isLoading,
82
- ariaControls = _ref.ariaControls,
83
- ariaLabelledBy = _ref.ariaLabelledBy,
84
80
  ariaReadOnly = _ref.ariaReadOnly,
85
81
  role = _ref.role,
86
82
  id = _ref.id,
@@ -149,7 +145,7 @@ var LinkSearchList = exports.LinkSearchList = /*#__PURE__*/(0, _react.forwardRef
149
145
  }
150
146
  var listItemNameMaxLines = activePlugin === null || activePlugin === void 0 || (_activePlugin$uiOptio = activePlugin.uiOptions) === null || _activePlugin$uiOptio === void 0 ? void 0 : _activePlugin$uiOptio.listItemNameMaxLines;
151
147
  if (items && items.length > 0) {
152
- itemsContent = /*#__PURE__*/React.createElement(_react.Fragment, null, (0, _platformFeatureFlags.fg)('navx-2134-fix-a11y-link-picker-headings') ? /*#__PURE__*/React.createElement(_compiled.Box, {
148
+ itemsContent = /*#__PURE__*/React.createElement(_react.Fragment, null, /*#__PURE__*/React.createElement(_compiled.Box, {
153
149
  as: "h2" // Must remain <h2> for a11y title hierarchy as per https://hello.jira.atlassian.cloud/browse/A11Y-27579
154
150
  // `.wiki-content h2` css styles in confluence override ADS/native styles here, so inline styles are needed.
155
151
  // Should use css or xcss prop when that CSS is removed/fixed by confluence
@@ -158,10 +154,6 @@ var LinkSearchList = exports.LinkSearchList = /*#__PURE__*/(0, _react.forwardRef
158
154
  style: listTitleStyles,
159
155
  id: testIds.resultListTitle,
160
156
  testId: testIds.resultListTitle
161
- }, /*#__PURE__*/React.createElement(_reactIntlNext.FormattedMessage, linkListTitle)) : /*#__PURE__*/React.createElement("div", {
162
- id: testIds.resultListTitle,
163
- "data-testid": testIds.resultListTitle,
164
- className: (0, _runtime.ax)(["_11c81o8v _k48pmoej _otyr1b66", "_syazazsu"])
165
157
  }, /*#__PURE__*/React.createElement(_reactIntlNext.FormattedMessage, linkListTitle)), /*#__PURE__*/React.createElement(_visuallyHidden.default, {
166
158
  id: "fabric.smartcard.linkpicker.suggested.results"
167
159
  }, hasSearchTerm && /*#__PURE__*/React.createElement(_reactIntlNext.FormattedMessage, (0, _extends2.default)({}, messages.searchLinkResults, {
@@ -25,7 +25,7 @@ var testIds = exports.testIds = {
25
25
  };
26
26
  var PACKAGE_DATA = exports.PACKAGE_DATA = {
27
27
  packageName: "@atlaskit/link-picker" || '',
28
- packageVersion: "0.0.0-development" || '',
28
+ packageVersion: "4.0.3" || '',
29
29
  componentName: _constants.COMPONENT_NAME,
30
30
  source: _constants.COMPONENT_NAME
31
31
  };
@@ -3,6 +3,7 @@ import "./index.compiled.css";
3
3
  import * as React from 'react';
4
4
  import { ax, ix } from "@compiled/react/runtime";
5
5
  import { Fragment } from 'react';
6
+ import { fg } from '@atlaskit/platform-feature-flags';
6
7
  import { Box } from '@atlaskit/primitives/compiled';
7
8
  import Spinner from '@atlaskit/spinner/spinner';
8
9
  import Tabs, { Tab, TabList } from '@atlaskit/tabs';
@@ -50,6 +51,11 @@ export const SearchResults = ({
50
51
  key: tab.tabTitle,
51
52
  testId: testIds.tabItem
52
53
  }, tab.tabTitle)));
54
+ const ErrorWrapper = ({
55
+ children
56
+ }) => !!tabs.length && fg('fix_invalid_aria_attr_in_link_picker_search_error') ? /*#__PURE__*/React.createElement("div", {
57
+ id: `${testIds.tabList}-${activeTab}-tab`
58
+ }, children) : children;
53
59
  return /*#__PURE__*/React.createElement(SearchResultsContainer, {
54
60
  hasTabs: !!tabs.length || isLoadingPlugins,
55
61
  adaptiveHeight: adaptiveHeight,
@@ -85,7 +91,7 @@ export const SearchResults = ({
85
91
  adaptiveHeight: adaptiveHeight,
86
92
  tabPanelId: `${testIds.tabList}-${activeTab}-tab`,
87
93
  shouldRenderNoResultsImage: shouldRenderNoResultsImage
88
- }), error ? (_activePlugin$errorFa = activePlugin === null || activePlugin === void 0 ? void 0 : (_activePlugin$errorFa2 = activePlugin.errorFallback) === null || _activePlugin$errorFa2 === void 0 ? void 0 : _activePlugin$errorFa2.call(activePlugin, error, retry)) !== null && _activePlugin$errorFa !== void 0 ? _activePlugin$errorFa : /*#__PURE__*/React.createElement(LinkSearchError, {
94
+ }), error ? (_activePlugin$errorFa = activePlugin === null || activePlugin === void 0 ? void 0 : (_activePlugin$errorFa2 = activePlugin.errorFallback) === null || _activePlugin$errorFa2 === void 0 ? void 0 : _activePlugin$errorFa2.call(activePlugin, error, retry)) !== null && _activePlugin$errorFa !== void 0 ? _activePlugin$errorFa : /*#__PURE__*/React.createElement(ErrorWrapper, null, /*#__PURE__*/React.createElement(LinkSearchError, {
89
95
  onRetry: retry
90
- }) : null));
96
+ })) : null));
91
97
  };
@@ -1,6 +1,5 @@
1
- ._11c81o8v{font:var(--ds-font-body-small,normal 400 11px/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,"Helvetica Neue",sans-serif)}
2
- ._qtt8glyw{list-style:none}
3
- ._16jlkb7n{flex-grow:1}
1
+
2
+ ._qtt8glyw{list-style:none}._16jlkb7n{flex-grow:1}
4
3
  ._18u01mjz{margin-left:calc(var(--link-picker-padding-left)*-1)}
5
4
  ._19bvze3t{padding-left:var(--ds-space-0,0)}
6
5
  ._19pkpxbi{margin-top:var(--ds-space-200,1pc)}
@@ -14,10 +13,7 @@
14
13
  ._4cvr1h6o{align-items:center}
15
14
  ._ca0qidpf{padding-top:0}
16
15
  ._ca0qze3t{padding-top:var(--ds-space-0,0)}
17
- ._k48pmoej{font-weight:var(--ds-font-weight-bold,700)}
18
16
  ._n3tdze3t{padding-bottom:var(--ds-space-0,0)}
19
- ._otyr1b66{margin-bottom:var(--ds-space-050,4px)}
20
17
  ._otyrpxbi{margin-bottom:var(--ds-space-200,1pc)}
21
18
  ._otyrze3t{margin-bottom:var(--ds-space-0,0)}
22
- ._syazazsu{color:var(--ds-text-subtle,#505258)}
23
19
  ._u5f3ze3t{padding-right:var(--ds-space-0,0)}
@@ -20,8 +20,6 @@ const styles = {
20
20
  const listContainerStyles = null;
21
21
  const spinnerContainerStyles = null;
22
22
  const listStyles = null;
23
- const baseListTitleStyles = null;
24
- const newListTitleStyles = null;
25
23
  const listTitleStyles = {
26
24
  font: "var(--ds-font-body-small, normal 400 11px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, \"Helvetica Neue\", sans-serif)",
27
25
  fontWeight: "var(--ds-font-weight-bold, 700)",
@@ -66,8 +64,6 @@ export const LinkSearchList = /*#__PURE__*/forwardRef(({
66
64
  activeIndex,
67
65
  selectedIndex,
68
66
  isLoading,
69
- ariaControls,
70
- ariaLabelledBy,
71
67
  ariaReadOnly,
72
68
  role,
73
69
  id,
@@ -138,7 +134,7 @@ export const LinkSearchList = /*#__PURE__*/forwardRef(({
138
134
  }
139
135
  const listItemNameMaxLines = activePlugin === null || activePlugin === void 0 ? void 0 : (_activePlugin$uiOptio = activePlugin.uiOptions) === null || _activePlugin$uiOptio === void 0 ? void 0 : _activePlugin$uiOptio.listItemNameMaxLines;
140
136
  if (items && items.length > 0) {
141
- itemsContent = /*#__PURE__*/React.createElement(Fragment, null, fg('navx-2134-fix-a11y-link-picker-headings') ? /*#__PURE__*/React.createElement(Box, {
137
+ itemsContent = /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement(Box, {
142
138
  as: "h2" // Must remain <h2> for a11y title hierarchy as per https://hello.jira.atlassian.cloud/browse/A11Y-27579
143
139
  // `.wiki-content h2` css styles in confluence override ADS/native styles here, so inline styles are needed.
144
140
  // Should use css or xcss prop when that CSS is removed/fixed by confluence
@@ -147,10 +143,6 @@ export const LinkSearchList = /*#__PURE__*/forwardRef(({
147
143
  style: listTitleStyles,
148
144
  id: testIds.resultListTitle,
149
145
  testId: testIds.resultListTitle
150
- }, /*#__PURE__*/React.createElement(FormattedMessage, linkListTitle)) : /*#__PURE__*/React.createElement("div", {
151
- id: testIds.resultListTitle,
152
- "data-testid": testIds.resultListTitle,
153
- className: ax(["_11c81o8v _k48pmoej _otyr1b66", "_syazazsu"])
154
146
  }, /*#__PURE__*/React.createElement(FormattedMessage, linkListTitle)), /*#__PURE__*/React.createElement(VisuallyHidden, {
155
147
  id: "fabric.smartcard.linkpicker.suggested.results"
156
148
  }, hasSearchTerm && /*#__PURE__*/React.createElement(FormattedMessage, _extends({}, messages.searchLinkResults, {
@@ -15,7 +15,7 @@ export const testIds = {
15
15
  };
16
16
  export const PACKAGE_DATA = {
17
17
  packageName: "@atlaskit/link-picker" || '',
18
- packageVersion: "0.0.0-development" || '',
18
+ packageVersion: "4.0.3" || '',
19
19
  componentName: COMPONENT_NAME,
20
20
  source: COMPONENT_NAME
21
21
  };
@@ -6,6 +6,7 @@ import { ax, ix } from "@compiled/react/runtime";
6
6
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
7
7
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
8
8
  import { Fragment } from 'react';
9
+ import { fg } from '@atlaskit/platform-feature-flags';
9
10
  import { Box } from '@atlaskit/primitives/compiled';
10
11
  import Spinner from '@atlaskit/spinner/spinner';
11
12
  import Tabs, { Tab, TabList } from '@atlaskit/tabs';
@@ -52,6 +53,12 @@ export var SearchResults = function SearchResults(_ref) {
52
53
  testId: testIds.tabItem
53
54
  }, tab.tabTitle);
54
55
  }));
56
+ var ErrorWrapper = function ErrorWrapper(_ref2) {
57
+ var children = _ref2.children;
58
+ return !!tabs.length && fg('fix_invalid_aria_attr_in_link_picker_search_error') ? /*#__PURE__*/React.createElement("div", {
59
+ id: "".concat(testIds.tabList, "-").concat(activeTab, "-tab")
60
+ }, children) : children;
61
+ };
55
62
  return /*#__PURE__*/React.createElement(SearchResultsContainer, {
56
63
  hasTabs: !!tabs.length || isLoadingPlugins,
57
64
  adaptiveHeight: adaptiveHeight,
@@ -87,7 +94,7 @@ export var SearchResults = function SearchResults(_ref) {
87
94
  adaptiveHeight: adaptiveHeight,
88
95
  tabPanelId: "".concat(testIds.tabList, "-").concat(activeTab, "-tab"),
89
96
  shouldRenderNoResultsImage: shouldRenderNoResultsImage
90
- }), error ? (_activePlugin$errorFa = activePlugin === null || activePlugin === void 0 || (_activePlugin$errorFa2 = activePlugin.errorFallback) === null || _activePlugin$errorFa2 === void 0 ? void 0 : _activePlugin$errorFa2.call(activePlugin, error, retry)) !== null && _activePlugin$errorFa !== void 0 ? _activePlugin$errorFa : /*#__PURE__*/React.createElement(LinkSearchError, {
97
+ }), error ? (_activePlugin$errorFa = activePlugin === null || activePlugin === void 0 || (_activePlugin$errorFa2 = activePlugin.errorFallback) === null || _activePlugin$errorFa2 === void 0 ? void 0 : _activePlugin$errorFa2.call(activePlugin, error, retry)) !== null && _activePlugin$errorFa !== void 0 ? _activePlugin$errorFa : /*#__PURE__*/React.createElement(ErrorWrapper, null, /*#__PURE__*/React.createElement(LinkSearchError, {
91
98
  onRetry: retry
92
- }) : null));
99
+ })) : null));
93
100
  };
@@ -1,6 +1,5 @@
1
- ._11c81o8v{font:var(--ds-font-body-small,normal 400 11px/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,"Helvetica Neue",sans-serif)}
2
- ._qtt8glyw{list-style:none}
3
- ._16jlkb7n{flex-grow:1}
1
+
2
+ ._qtt8glyw{list-style:none}._16jlkb7n{flex-grow:1}
4
3
  ._18u01mjz{margin-left:calc(var(--link-picker-padding-left)*-1)}
5
4
  ._19bvze3t{padding-left:var(--ds-space-0,0)}
6
5
  ._19pkpxbi{margin-top:var(--ds-space-200,1pc)}
@@ -14,10 +13,7 @@
14
13
  ._4cvr1h6o{align-items:center}
15
14
  ._ca0qidpf{padding-top:0}
16
15
  ._ca0qze3t{padding-top:var(--ds-space-0,0)}
17
- ._k48pmoej{font-weight:var(--ds-font-weight-bold,700)}
18
16
  ._n3tdze3t{padding-bottom:var(--ds-space-0,0)}
19
- ._otyr1b66{margin-bottom:var(--ds-space-050,4px)}
20
17
  ._otyrpxbi{margin-bottom:var(--ds-space-200,1pc)}
21
18
  ._otyrze3t{margin-bottom:var(--ds-space-0,0)}
22
- ._syazazsu{color:var(--ds-text-subtle,#505258)}
23
19
  ._u5f3ze3t{padding-right:var(--ds-space-0,0)}
@@ -2,7 +2,7 @@
2
2
  import _extends from "@babel/runtime/helpers/extends";
3
3
  import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
4
4
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
5
- var _excluded = ["onChange", "onSelect", "onKeyDown", "items", "activeIndex", "selectedIndex", "isLoading", "ariaControls", "ariaLabelledBy", "ariaReadOnly", "role", "id", "hasSearchTerm", "activePlugin", "adaptiveHeight", "className", "tabPanelId", "shouldRenderNoResultsImage"];
5
+ var _excluded = ["onChange", "onSelect", "onKeyDown", "items", "activeIndex", "selectedIndex", "isLoading", "ariaReadOnly", "role", "id", "hasSearchTerm", "activePlugin", "adaptiveHeight", "className", "tabPanelId", "shouldRenderNoResultsImage"];
6
6
  import "./index.compiled.css";
7
7
  import * as React from 'react';
8
8
  import { ax, ix } from "@compiled/react/runtime";
@@ -25,8 +25,6 @@ var styles = {
25
25
  var listContainerStyles = null;
26
26
  var spinnerContainerStyles = null;
27
27
  var listStyles = null;
28
- var baseListTitleStyles = null;
29
- var newListTitleStyles = null;
30
28
  var listTitleStyles = {
31
29
  font: "var(--ds-font-body-small, normal 400 11px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, \"Helvetica Neue\", sans-serif)",
32
30
  fontWeight: "var(--ds-font-weight-bold, 700)",
@@ -70,8 +68,6 @@ export var LinkSearchList = /*#__PURE__*/forwardRef(function (_ref, ref) {
70
68
  activeIndex = _ref.activeIndex,
71
69
  selectedIndex = _ref.selectedIndex,
72
70
  isLoading = _ref.isLoading,
73
- ariaControls = _ref.ariaControls,
74
- ariaLabelledBy = _ref.ariaLabelledBy,
75
71
  ariaReadOnly = _ref.ariaReadOnly,
76
72
  role = _ref.role,
77
73
  id = _ref.id,
@@ -140,7 +136,7 @@ export var LinkSearchList = /*#__PURE__*/forwardRef(function (_ref, ref) {
140
136
  }
141
137
  var listItemNameMaxLines = activePlugin === null || activePlugin === void 0 || (_activePlugin$uiOptio = activePlugin.uiOptions) === null || _activePlugin$uiOptio === void 0 ? void 0 : _activePlugin$uiOptio.listItemNameMaxLines;
142
138
  if (items && items.length > 0) {
143
- itemsContent = /*#__PURE__*/React.createElement(Fragment, null, fg('navx-2134-fix-a11y-link-picker-headings') ? /*#__PURE__*/React.createElement(Box, {
139
+ itemsContent = /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement(Box, {
144
140
  as: "h2" // Must remain <h2> for a11y title hierarchy as per https://hello.jira.atlassian.cloud/browse/A11Y-27579
145
141
  // `.wiki-content h2` css styles in confluence override ADS/native styles here, so inline styles are needed.
146
142
  // Should use css or xcss prop when that CSS is removed/fixed by confluence
@@ -149,10 +145,6 @@ export var LinkSearchList = /*#__PURE__*/forwardRef(function (_ref, ref) {
149
145
  style: listTitleStyles,
150
146
  id: testIds.resultListTitle,
151
147
  testId: testIds.resultListTitle
152
- }, /*#__PURE__*/React.createElement(FormattedMessage, linkListTitle)) : /*#__PURE__*/React.createElement("div", {
153
- id: testIds.resultListTitle,
154
- "data-testid": testIds.resultListTitle,
155
- className: ax(["_11c81o8v _k48pmoej _otyr1b66", "_syazazsu"])
156
148
  }, /*#__PURE__*/React.createElement(FormattedMessage, linkListTitle)), /*#__PURE__*/React.createElement(VisuallyHidden, {
157
149
  id: "fabric.smartcard.linkpicker.suggested.results"
158
150
  }, hasSearchTerm && /*#__PURE__*/React.createElement(FormattedMessage, _extends({}, messages.searchLinkResults, {
@@ -16,7 +16,7 @@ export var testIds = {
16
16
  };
17
17
  export var PACKAGE_DATA = {
18
18
  packageName: "@atlaskit/link-picker" || '',
19
- packageVersion: "0.0.0-development" || '',
19
+ packageVersion: "4.0.3" || '',
20
20
  componentName: COMPONENT_NAME,
21
21
  source: COMPONENT_NAME
22
22
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/link-picker",
3
- "version": "4.0.2",
3
+ "version": "4.1.0",
4
4
  "description": "Standalone link picker",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "publishConfig": {
@@ -41,7 +41,7 @@
41
41
  "aifc_create_enabled": {
42
42
  "type": "boolean"
43
43
  },
44
- "navx-2134-fix-a11y-link-picker-headings": {
44
+ "fix_invalid_aria_attr_in_link_picker_search_error": {
45
45
  "type": "boolean"
46
46
  }
47
47
  },
@@ -54,7 +54,6 @@
54
54
  "@atlaskit/atlassian-context": "^0.6.0",
55
55
  "@atlaskit/button": "^23.6.0",
56
56
  "@atlaskit/css": "^0.17.0",
57
- "@atlaskit/feature-gate-js-client": "^5.5.0",
58
57
  "@atlaskit/form": "^14.3.0",
59
58
  "@atlaskit/frontend-utilities": "^3.2.0",
60
59
  "@atlaskit/heading": "^5.2.0",
@@ -66,13 +65,13 @@
66
65
  "@atlaskit/onboarding": "^14.4.0",
67
66
  "@atlaskit/platform-feature-flags": "^1.1.0",
68
67
  "@atlaskit/primitives": "^16.4.0",
69
- "@atlaskit/smart-card": "^43.11.0",
68
+ "@atlaskit/smart-card": "^43.14.0",
70
69
  "@atlaskit/spinner": "^19.0.0",
71
70
  "@atlaskit/tabs": "^18.2.0",
72
71
  "@atlaskit/textfield": "^8.1.0",
73
72
  "@atlaskit/theme": "^21.0.0",
74
73
  "@atlaskit/tokens": "^8.4.0",
75
- "@atlaskit/tooltip": "^20.10.0",
74
+ "@atlaskit/tooltip": "^20.11.0",
76
75
  "@atlaskit/ufo": "^0.4.0",
77
76
  "@atlaskit/visually-hidden": "^3.0.0",
78
77
  "@babel/runtime": "^7.0.0",
@@ -93,7 +92,7 @@
93
92
  "@af/integration-testing": "workspace:^",
94
93
  "@af/visual-regression": "workspace:^",
95
94
  "@atlaskit/dropdown-menu": "^16.3.0",
96
- "@atlaskit/link-test-helpers": "^8.5.0",
95
+ "@atlaskit/link-test-helpers": "^9.0.0",
97
96
  "@atlassian/feature-flags-test-utils": "^1.0.0",
98
97
  "@testing-library/dom": "^10.1.0",
99
98
  "@testing-library/jest-dom": "^6.4.5",