@atlaskit/user-picker 13.8.4 → 13.8.6

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,22 @@
1
1
  # @atlaskit/user-picker
2
2
 
3
+ ## 13.8.6
4
+
5
+ ### Patch Changes
6
+
7
+ - [`e9153fd2bb41f`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/e9153fd2bb41f) -
8
+ Migrate user picker feature gate unit tests to the supported mock-gates test utilities.
9
+ - [`1457e7f84155e`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/1457e7f84155e) -
10
+ Cleanup feature gate platform_user_picker_fix_redundant_labelledby. Stop promoting
11
+ aria-describedby to aria-labelledby when aria-label is present (A11Y-37267).
12
+ - Updated dependencies
13
+
14
+ ## 13.8.5
15
+
16
+ ### Patch Changes
17
+
18
+ - Updated dependencies
19
+
3
20
  ## 13.8.4
4
21
 
5
22
  ### Patch Changes
@@ -15,7 +15,7 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
15
15
  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; } // eslint-disable-next-line @typescript-eslint/consistent-type-imports
16
16
  // eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
17
17
  var packageName = "@atlaskit/user-picker";
18
- var packageVersion = "13.8.3";
18
+ var packageVersion = "13.8.5";
19
19
  var UUID_REGEXP_TEAMS_GROUPS = /^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/;
20
20
  var UUID_REGEXP_OLD_AAID = /^[a-fA-F0-9]{1,8}:[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/;
21
21
  var UUID_REGEXP_NEW_AAID = /^[a-fA-F0-9]{24,24}$/;
@@ -16,7 +16,6 @@ var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/ge
16
16
  var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
17
17
  var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
18
18
  var _react = _interopRequireDefault(require("react"));
19
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
20
19
  var _select = require("@atlaskit/select");
21
20
  function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); }
22
21
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
@@ -60,23 +59,19 @@ var Input = exports.Input = /*#__PURE__*/function (_React$Component) {
60
59
  * This reassignment should only apply when the input has no other accessible name.
61
60
  */
62
61
  function get() {
63
- var _this$props$ariaLabe;
64
- if ((0, _platformFeatureFlags.fg)('platform_user_picker_fix_redundant_labelledby')) {
65
- // A11Y-37267: An explicit aria-labelledby is a deliberate association with a visible label
66
- // element and is the field's true accessible name (WCAG 2.5.3 Label in Name), so it always
67
- // wins. Otherwise we promote aria-describedby -> aria-labelledby to work around
68
- // react-select's placeholder linkage bug, but skip that promotion when the input already
69
- // has an accessible name via aria-label so the description is announced via
70
- // aria-describedby instead.
71
- if (this.props['aria-labelledby']) {
72
- return this.props['aria-labelledby'];
73
- }
74
- if (this.props['aria-label']) {
75
- return undefined;
76
- }
77
- return this.props['aria-describedby'];
62
+ // A11Y-37267: An explicit aria-labelledby is a deliberate association with a visible label
63
+ // element and is the field's true accessible name (WCAG 2.5.3 Label in Name), so it always
64
+ // wins. Otherwise we promote aria-describedby -> aria-labelledby to work around
65
+ // react-select's placeholder linkage bug, but skip that promotion when the input already
66
+ // has an accessible name via aria-label so the description is announced via
67
+ // aria-describedby instead.
68
+ if (this.props['aria-labelledby']) {
69
+ return this.props['aria-labelledby'];
78
70
  }
79
- return (_this$props$ariaLabe = this.props['aria-labelledby']) !== null && _this$props$ariaLabe !== void 0 ? _this$props$ariaLabe : this.props['aria-describedby'];
71
+ if (this.props['aria-label']) {
72
+ return undefined;
73
+ }
74
+ return this.props['aria-describedby'];
80
75
  }
81
76
  }, {
82
77
  key: "ariaDescribedBy",
@@ -6,7 +6,7 @@ import { fg } from '@atlaskit/platform-feature-flags';
6
6
  import { v4 as uuidv4 } from 'uuid';
7
7
  import { isCustom, isExternalUser } from './components/utils';
8
8
  const packageName = "@atlaskit/user-picker";
9
- const packageVersion = "13.8.3";
9
+ const packageVersion = "13.8.5";
10
10
  const UUID_REGEXP_TEAMS_GROUPS = /^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/;
11
11
  const UUID_REGEXP_OLD_AAID = /^[a-fA-F0-9]{1,8}:[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/;
12
12
  const UUID_REGEXP_NEW_AAID = /^[a-fA-F0-9]{24,24}$/;
@@ -4,7 +4,6 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
4
4
  import "./Input.compiled.css";
5
5
  import { ax, ix } from "@compiled/react/runtime";
6
6
  import React from 'react';
7
- import { fg } from '@atlaskit/platform-feature-flags';
8
7
  import { components } from '@atlaskit/select';
9
8
  const inputStyles = {
10
9
  root: "_5ce61rpy _1ir3kb7n _h5gq1rpy"
@@ -36,23 +35,19 @@ export class Input extends React.Component {
36
35
  * This reassignment should only apply when the input has no other accessible name.
37
36
  */
38
37
  get ariaLabelledBy() {
39
- var _this$props$ariaLabe;
40
- if (fg('platform_user_picker_fix_redundant_labelledby')) {
41
- // A11Y-37267: An explicit aria-labelledby is a deliberate association with a visible label
42
- // element and is the field's true accessible name (WCAG 2.5.3 Label in Name), so it always
43
- // wins. Otherwise we promote aria-describedby -> aria-labelledby to work around
44
- // react-select's placeholder linkage bug, but skip that promotion when the input already
45
- // has an accessible name via aria-label so the description is announced via
46
- // aria-describedby instead.
47
- if (this.props['aria-labelledby']) {
48
- return this.props['aria-labelledby'];
49
- }
50
- if (this.props['aria-label']) {
51
- return undefined;
52
- }
53
- return this.props['aria-describedby'];
38
+ // A11Y-37267: An explicit aria-labelledby is a deliberate association with a visible label
39
+ // element and is the field's true accessible name (WCAG 2.5.3 Label in Name), so it always
40
+ // wins. Otherwise we promote aria-describedby -> aria-labelledby to work around
41
+ // react-select's placeholder linkage bug, but skip that promotion when the input already
42
+ // has an accessible name via aria-label so the description is announced via
43
+ // aria-describedby instead.
44
+ if (this.props['aria-labelledby']) {
45
+ return this.props['aria-labelledby'];
46
+ }
47
+ if (this.props['aria-label']) {
48
+ return undefined;
54
49
  }
55
- return (_this$props$ariaLabe = this.props['aria-labelledby']) !== null && _this$props$ariaLabe !== void 0 ? _this$props$ariaLabe : this.props['aria-describedby'];
50
+ return this.props['aria-describedby'];
56
51
  }
57
52
  get ariaDescribedBy() {
58
53
  var _this$props$selectPro2, _this$props$selectPro3;
@@ -9,7 +9,7 @@ import { fg } from '@atlaskit/platform-feature-flags';
9
9
  import { v4 as uuidv4 } from 'uuid';
10
10
  import { isCustom, isExternalUser } from './components/utils';
11
11
  var packageName = "@atlaskit/user-picker";
12
- var packageVersion = "13.8.3";
12
+ var packageVersion = "13.8.5";
13
13
  var UUID_REGEXP_TEAMS_GROUPS = /^[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/;
14
14
  var UUID_REGEXP_OLD_AAID = /^[a-fA-F0-9]{1,8}:[a-fA-F0-9]{8}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{4}-[a-fA-F0-9]{12}$/;
15
15
  var UUID_REGEXP_NEW_AAID = /^[a-fA-F0-9]{24,24}$/;
@@ -11,7 +11,6 @@ import { ax, ix } from "@compiled/react/runtime";
11
11
  function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }
12
12
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
13
13
  import React from 'react';
14
- import { fg } from '@atlaskit/platform-feature-flags';
15
14
  import { components } from '@atlaskit/select';
16
15
  var inputStyles = {
17
16
  root: "_5ce61rpy _1ir3kb7n _h5gq1rpy"
@@ -53,23 +52,19 @@ export var Input = /*#__PURE__*/function (_React$Component) {
53
52
  * This reassignment should only apply when the input has no other accessible name.
54
53
  */
55
54
  function get() {
56
- var _this$props$ariaLabe;
57
- if (fg('platform_user_picker_fix_redundant_labelledby')) {
58
- // A11Y-37267: An explicit aria-labelledby is a deliberate association with a visible label
59
- // element and is the field's true accessible name (WCAG 2.5.3 Label in Name), so it always
60
- // wins. Otherwise we promote aria-describedby -> aria-labelledby to work around
61
- // react-select's placeholder linkage bug, but skip that promotion when the input already
62
- // has an accessible name via aria-label so the description is announced via
63
- // aria-describedby instead.
64
- if (this.props['aria-labelledby']) {
65
- return this.props['aria-labelledby'];
66
- }
67
- if (this.props['aria-label']) {
68
- return undefined;
69
- }
70
- return this.props['aria-describedby'];
55
+ // A11Y-37267: An explicit aria-labelledby is a deliberate association with a visible label
56
+ // element and is the field's true accessible name (WCAG 2.5.3 Label in Name), so it always
57
+ // wins. Otherwise we promote aria-describedby -> aria-labelledby to work around
58
+ // react-select's placeholder linkage bug, but skip that promotion when the input already
59
+ // has an accessible name via aria-label so the description is announced via
60
+ // aria-describedby instead.
61
+ if (this.props['aria-labelledby']) {
62
+ return this.props['aria-labelledby'];
71
63
  }
72
- return (_this$props$ariaLabe = this.props['aria-labelledby']) !== null && _this$props$ariaLabe !== void 0 ? _this$props$ariaLabe : this.props['aria-describedby'];
64
+ if (this.props['aria-label']) {
65
+ return undefined;
66
+ }
67
+ return this.props['aria-describedby'];
73
68
  }
74
69
  }, {
75
70
  key: "ariaDescribedBy",
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/user-picker",
3
- "version": "13.8.4",
3
+ "version": "13.8.6",
4
4
  "description": "Fabric component for display a dropdown to select a user from",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -17,6 +17,7 @@
17
17
  "@af/search-test-utils": "workspace:^",
18
18
  "@af/visual-regression": "workspace:^",
19
19
  "@atlaskit/heading": "^7.0.0",
20
+ "@atlaskit/pragmatic-drag-and-drop-react-beautiful-dnd-migration": "^3.2.0",
20
21
  "@atlassian/a11y-jest-testing": "^0.14.0",
21
22
  "@atlassian/a11y-playwright-testing": "^0.10.0",
22
23
  "@atlassian/feature-flags-test-utils": "^1.2.0",
@@ -29,7 +30,6 @@
29
30
  "enzyme": "^3.10.0",
30
31
  "mock-apollo-client": "^0.1.0",
31
32
  "react": "^18.2.0",
32
- "react-beautiful-dnd": "^12.2.0",
33
33
  "react-dom": "^18.2.0",
34
34
  "react-intl": "^7.0.0",
35
35
  "react-select-event": "^5.5.0"
@@ -67,18 +67,18 @@
67
67
  "@atlaskit/analytics-next": "^12.3.0",
68
68
  "@atlaskit/avatar": "^26.4.0",
69
69
  "@atlaskit/feature-gate-js-client": "^6.0.0",
70
- "@atlaskit/icon": "^37.2.0",
70
+ "@atlaskit/icon": "^37.3.0",
71
71
  "@atlaskit/logo": "^21.4.0",
72
72
  "@atlaskit/lozenge": "^15.0.0",
73
- "@atlaskit/people-teams-ui-public": "^5.1.0",
73
+ "@atlaskit/people-teams-ui-public": "^5.2.0",
74
74
  "@atlaskit/platform-feature-flags": "^2.1.0",
75
- "@atlaskit/popper": "^8.5.0",
75
+ "@atlaskit/popper": "^9.0.0",
76
76
  "@atlaskit/primitives": "^22.2.0",
77
77
  "@atlaskit/react-compiler-gating": "^0.2.0",
78
78
  "@atlaskit/select": "^22.6.0",
79
79
  "@atlaskit/spinner": "^20.1.0",
80
80
  "@atlaskit/tag": "^15.4.0",
81
- "@atlaskit/teams-avatar": "^4.0.0",
81
+ "@atlaskit/teams-avatar": "^4.1.0",
82
82
  "@atlaskit/tokens": "^16.3.0",
83
83
  "@atlaskit/tooltip": "^24.0.0",
84
84
  "@atlaskit/ufo": "^1.0.0",
@@ -120,9 +120,6 @@
120
120
  },
121
121
  "jsm-wfo-assignee-recommendation-on-queues": {
122
122
  "type": "boolean"
123
- },
124
- "platform_user_picker_fix_redundant_labelledby": {
125
- "type": "boolean"
126
123
  }
127
124
  }
128
125
  }
package/tsconfig.json CHANGED
@@ -1,19 +1,7 @@
1
1
  {
2
- "extends": "../../../tsconfig.json",
3
- "include": [
4
- "./*.docs.tsx",
5
- "./package.json",
6
- "./src/**/*.ts",
7
- "./src/**/*.tsx",
8
- "./docs/**/*.ts",
9
- "./docs/**/*.tsx",
10
- "./examples/**/*.ts",
11
- "./examples/**/*.tsx",
12
- "**/stories.ts",
13
- "**/stories.tsx",
14
- "**/stories/*.ts",
15
- "**/stories/*.tsx",
16
- "**/stories/**/*.ts",
17
- "**/stories/**/*.tsx"
18
- ]
2
+ "extends": "./tsconfig.dev.json",
3
+ "compilerOptions": {
4
+ "disableReferencedProjectLoad": true,
5
+ "disableSolutionSearching": true
6
+ }
19
7
  }