@atlaskit/link-picker 3.16.1 → 3.16.3

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,19 @@
1
1
  # @atlaskit/link-picker
2
2
 
3
+ ## 3.16.3
4
+
5
+ ### Patch Changes
6
+
7
+ - [`1300e23207706`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/1300e23207706) -
8
+ NAVX-2134 Fix link-picker headings to rendered as h2 for a11y
9
+ - Updated dependencies
10
+
11
+ ## 3.16.2
12
+
13
+ ### Patch Changes
14
+
15
+ - Updated dependencies
16
+
3
17
  ## 3.16.1
4
18
 
5
19
  ### Patch Changes
@@ -85,11 +99,9 @@
85
99
 
86
100
  - [`489caede2951a`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/489caede2951a) -
87
101
  [ux] link-picker-atlassian-plugin changes:
88
-
89
102
  - Introduce GoogleDriveConnectBanner to support Google Drive tab experiment
90
103
 
91
104
  link-picker changes:
92
-
93
105
  - Extend the LinkPickerPlugin interface to include an optional banner render function
94
106
  - Modify the usePlugins hook to collect the banner from the active plugin
95
107
  - Add banner rendering in LinkPicker between the moveSubmitButton clause and SearchResults
@@ -1936,7 +1948,6 @@
1936
1948
  - [#20341](https://bitbucket.org/atlassian/atlassian-frontend/pull-requests/20341)
1937
1949
  [`af6e73a1e17`](https://bitbucket.org/atlassian/atlassian-frontend/commits/af6e73a1e17) - Bumping
1938
1950
  dependencies via Renovate:
1939
-
1940
1951
  - react-loosely-lazy
1941
1952
 
1942
1953
  ## 1.11.0
@@ -15,7 +15,9 @@ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends")
15
15
  var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
16
16
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
17
17
  var _reactIntlNext = require("react-intl-next");
18
+ var _css = require("@atlaskit/css");
18
19
  var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
20
+ var _compiled = require("@atlaskit/primitives/compiled");
19
21
  var _spinner = _interopRequireDefault(require("@atlaskit/spinner"));
20
22
  var _visuallyHidden = _interopRequireDefault(require("@atlaskit/visually-hidden"));
21
23
  var _minHeightContainer = require("../../../../common/ui/min-height-container");
@@ -28,7 +30,9 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
28
30
  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; }
29
31
  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; }
30
32
  var styles = {
31
- emptyStateNoResultsWrapper: "_1tkepxbi"
33
+ emptyStateNoResultsWrapper: "_1tkepxbi",
34
+ baseListTitleStyles: "_11c81o8v _k48pmoej _otyr1b66",
35
+ newListTitleStyles: "_syaz1gjq"
32
36
  };
33
37
  var listContainerStyles = null;
34
38
  var spinnerContainerStyles = null;
@@ -142,7 +146,12 @@ var LinkSearchList = exports.LinkSearchList = /*#__PURE__*/(0, _react.forwardRef
142
146
  }
143
147
  var listItemNameMaxLines = activePlugin === null || activePlugin === void 0 || (_activePlugin$uiOptio = activePlugin.uiOptions) === null || _activePlugin$uiOptio === void 0 ? void 0 : _activePlugin$uiOptio.listItemNameMaxLines;
144
148
  if (items && items.length > 0) {
145
- itemsContent = /*#__PURE__*/React.createElement(_react.Fragment, null, /*#__PURE__*/React.createElement("div", {
149
+ itemsContent = /*#__PURE__*/React.createElement(_react.Fragment, null, (0, _platformFeatureFlags.fg)('navx-2134-fix-a11y-link-picker-headings') ? /*#__PURE__*/React.createElement(_compiled.Box, {
150
+ as: "h2",
151
+ xcss: (0, _css.cx)(styles.baseListTitleStyles, styles.newListTitleStyles),
152
+ id: testIds.resultListTitle,
153
+ testId: testIds.resultListTitle
154
+ }, /*#__PURE__*/React.createElement(_reactIntlNext.FormattedMessage, linkListTitle)) : /*#__PURE__*/React.createElement("div", {
146
155
  id: testIds.resultListTitle,
147
156
  "data-testid": testIds.resultListTitle,
148
157
  className: (0, _runtime.ax)(["_11c81o8v _k48pmoej _otyr1b66", "_syaz1gjq"])
@@ -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: "3.16.2" || '',
29
29
  componentName: _constants.COMPONENT_NAME,
30
30
  source: _constants.COMPONENT_NAME
31
31
  };
@@ -5,7 +5,9 @@ import * as React from 'react';
5
5
  import { ax, ix } from "@compiled/react/runtime";
6
6
  import { forwardRef, Fragment, useCallback, useRef } from 'react';
7
7
  import { defineMessages, FormattedMessage } from 'react-intl-next';
8
+ import { cx } from '@atlaskit/css';
8
9
  import { fg } from '@atlaskit/platform-feature-flags';
10
+ import { Box } from '@atlaskit/primitives/compiled';
9
11
  import Spinner from '@atlaskit/spinner';
10
12
  import VisuallyHidden from '@atlaskit/visually-hidden';
11
13
  import { MinHeightContainer } from '../../../../common/ui/min-height-container';
@@ -14,7 +16,9 @@ import { NoResults, testIds as noResultsTestIds } from './link-search-no-results
14
16
  import { LinkSearchListItem, testIds as searchResultItemTestIds } from './list-item';
15
17
  import { useTrackResultsShown } from './use-track-results-shown';
16
18
  const styles = {
17
- emptyStateNoResultsWrapper: "_1tkepxbi"
19
+ emptyStateNoResultsWrapper: "_1tkepxbi",
20
+ baseListTitleStyles: "_11c81o8v _k48pmoej _otyr1b66",
21
+ newListTitleStyles: "_syaz1gjq"
18
22
  };
19
23
  const listContainerStyles = null;
20
24
  const spinnerContainerStyles = null;
@@ -131,7 +135,12 @@ export const LinkSearchList = /*#__PURE__*/forwardRef(({
131
135
  }
132
136
  const listItemNameMaxLines = activePlugin === null || activePlugin === void 0 ? void 0 : (_activePlugin$uiOptio = activePlugin.uiOptions) === null || _activePlugin$uiOptio === void 0 ? void 0 : _activePlugin$uiOptio.listItemNameMaxLines;
133
137
  if (items && items.length > 0) {
134
- itemsContent = /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
138
+ itemsContent = /*#__PURE__*/React.createElement(Fragment, null, fg('navx-2134-fix-a11y-link-picker-headings') ? /*#__PURE__*/React.createElement(Box, {
139
+ as: "h2",
140
+ xcss: cx(styles.baseListTitleStyles, styles.newListTitleStyles),
141
+ id: testIds.resultListTitle,
142
+ testId: testIds.resultListTitle
143
+ }, /*#__PURE__*/React.createElement(FormattedMessage, linkListTitle)) : /*#__PURE__*/React.createElement("div", {
135
144
  id: testIds.resultListTitle,
136
145
  "data-testid": testIds.resultListTitle,
137
146
  className: ax(["_11c81o8v _k48pmoej _otyr1b66", "_syaz1gjq"])
@@ -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: "3.16.2" || '',
19
19
  componentName: COMPONENT_NAME,
20
20
  source: COMPONENT_NAME
21
21
  };
@@ -10,7 +10,9 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
10
10
  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; }
11
11
  import { forwardRef, Fragment, useCallback, useRef } from 'react';
12
12
  import { defineMessages, FormattedMessage } from 'react-intl-next';
13
+ import { cx } from '@atlaskit/css';
13
14
  import { fg } from '@atlaskit/platform-feature-flags';
15
+ import { Box } from '@atlaskit/primitives/compiled';
14
16
  import Spinner from '@atlaskit/spinner';
15
17
  import VisuallyHidden from '@atlaskit/visually-hidden';
16
18
  import { MinHeightContainer } from '../../../../common/ui/min-height-container';
@@ -19,7 +21,9 @@ import { NoResults, testIds as noResultsTestIds } from './link-search-no-results
19
21
  import { LinkSearchListItem, testIds as searchResultItemTestIds } from './list-item';
20
22
  import { useTrackResultsShown } from './use-track-results-shown';
21
23
  var styles = {
22
- emptyStateNoResultsWrapper: "_1tkepxbi"
24
+ emptyStateNoResultsWrapper: "_1tkepxbi",
25
+ baseListTitleStyles: "_11c81o8v _k48pmoej _otyr1b66",
26
+ newListTitleStyles: "_syaz1gjq"
23
27
  };
24
28
  var listContainerStyles = null;
25
29
  var spinnerContainerStyles = null;
@@ -133,7 +137,12 @@ export var LinkSearchList = /*#__PURE__*/forwardRef(function (_ref, ref) {
133
137
  }
134
138
  var listItemNameMaxLines = activePlugin === null || activePlugin === void 0 || (_activePlugin$uiOptio = activePlugin.uiOptions) === null || _activePlugin$uiOptio === void 0 ? void 0 : _activePlugin$uiOptio.listItemNameMaxLines;
135
139
  if (items && items.length > 0) {
136
- itemsContent = /*#__PURE__*/React.createElement(Fragment, null, /*#__PURE__*/React.createElement("div", {
140
+ itemsContent = /*#__PURE__*/React.createElement(Fragment, null, fg('navx-2134-fix-a11y-link-picker-headings') ? /*#__PURE__*/React.createElement(Box, {
141
+ as: "h2",
142
+ xcss: cx(styles.baseListTitleStyles, styles.newListTitleStyles),
143
+ id: testIds.resultListTitle,
144
+ testId: testIds.resultListTitle
145
+ }, /*#__PURE__*/React.createElement(FormattedMessage, linkListTitle)) : /*#__PURE__*/React.createElement("div", {
137
146
  id: testIds.resultListTitle,
138
147
  "data-testid": testIds.resultListTitle,
139
148
  className: ax(["_11c81o8v _k48pmoej _otyr1b66", "_syaz1gjq"])
@@ -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: "3.16.2" || '',
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": "3.16.1",
3
+ "version": "3.16.3",
4
4
  "description": "Standalone link picker",
5
5
  "author": "Atlassian Pty Ltd",
6
6
  "publishConfig": {
@@ -46,6 +46,9 @@
46
46
  },
47
47
  "aifc_create_enabled": {
48
48
  "type": "boolean"
49
+ },
50
+ "navx-2134-fix-a11y-link-picker-headings": {
51
+ "type": "boolean"
49
52
  }
50
53
  },
51
54
  "scripts": {
@@ -68,18 +71,18 @@
68
71
  "@atlaskit/linking-common": "^9.7.0",
69
72
  "@atlaskit/onboarding": "^14.4.0",
70
73
  "@atlaskit/platform-feature-flags": "^1.1.0",
71
- "@atlaskit/primitives": "^15.0.0",
74
+ "@atlaskit/primitives": "^16.0.0",
72
75
  "@atlaskit/smart-card": "^43.1.0",
73
76
  "@atlaskit/spinner": "^19.0.0",
74
77
  "@atlaskit/tabs": "^18.2.0",
75
78
  "@atlaskit/textfield": "^8.0.0",
76
79
  "@atlaskit/theme": "^21.0.0",
77
- "@atlaskit/tokens": "^6.5.0",
80
+ "@atlaskit/tokens": "^7.0.0",
78
81
  "@atlaskit/tooltip": "^20.5.0",
79
82
  "@atlaskit/ufo": "^0.4.0",
80
83
  "@atlaskit/visually-hidden": "^3.0.0",
81
84
  "@babel/runtime": "^7.0.0",
82
- "@compiled/react": "^0.18.3",
85
+ "@compiled/react": "^0.18.6",
83
86
  "@react-loosely-lazy/manifest": "^1.0.0",
84
87
  "date-fns": "^2.17.0",
85
88
  "react-loosely-lazy": "^1.0.0",