@atlaskit/user-picker 13.8.6 → 13.8.8

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,20 @@
1
1
  # @atlaskit/user-picker
2
2
 
3
+ ## 13.8.8
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
9
+ ## 13.8.7
10
+
11
+ ### Patch Changes
12
+
13
+ - [`e0edc05cd52d7`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/e0edc05cd52d7) -
14
+ Migrates internal 16px Avatar usage from `xsmall` to `xxsmall` as a 1:1 size rename with no visual
15
+ change.
16
+ - Updated dependencies
17
+
3
18
  ## 13.8.6
4
19
 
5
20
  ### 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.5";
18
+ var packageVersion = "13.8.7";
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}$/;
@@ -21,6 +21,10 @@ var iconStyle = (0, _react.css)({
21
21
  flexShrink: 0
22
22
  });
23
23
  var iconSizes = {
24
+ xxsmall: (0, _react.css)({
25
+ width: '20px',
26
+ height: '20px'
27
+ }),
24
28
  xsmall: (0, _react.css)({
25
29
  width: '20px',
26
30
  height: '20px'
@@ -262,7 +262,7 @@ var MultiValue = exports.MultiValue = /*#__PURE__*/function (_React$Component) {
262
262
  onAfterRemoveAction: onAfterRemoveAction,
263
263
  avatar: function avatar(props) {
264
264
  return (
265
- // AvatarTag always supplies size="xsmall", which is a valid
265
+ // AvatarTag always supplies size="xxsmall", which is a valid
266
266
  // TeamAvatarSize; TeamAvatar does not support UNSAFE_xsmall.
267
267
  (0, _react2.jsx)(_teamsAvatar.default, (0, _extends2.default)({}, props, avatarProps))
268
268
  );
@@ -35,10 +35,6 @@ var SizeableAvatar = exports.SizeableAvatar = /*#__PURE__*/function (_React$Pure
35
35
  _this$props$type = _this$props.type,
36
36
  type = _this$props$type === void 0 ? 'person' : _this$props$type,
37
37
  avatarAppearanceShape = _this$props.avatarAppearanceShape;
38
-
39
- // `getAvatarSize` only ever returns 'xsmall' | 'small' | 'medium', none of
40
- // which is the team-avatar-unsupported `UNSAFE_xsmall` (20px) size. Keeping
41
- // `size` narrowed here lets the object satisfy both Avatar and TeamAvatar.
42
38
  var size = (0, _utils.getAvatarSize)(appearance);
43
39
  var props = _objectSpread({
44
40
  size: size,
@@ -83,7 +83,7 @@ var optionToSelectableOptions = exports.optionToSelectableOptions = (0, _memoize
83
83
  return optionToSelectableOption(defaultValue);
84
84
  });
85
85
  var getAvatarSize = exports.getAvatarSize = function getAvatarSize(appearance) {
86
- return appearance === 'big' ? 'medium' : appearance === 'multi' ? 'xsmall' : 'small';
86
+ return appearance === 'big' ? 'medium' : appearance === 'multi' ? 'xxsmall' : 'small';
87
87
  };
88
88
  var isChildInput = exports.isChildInput = function isChildInput(child) {
89
89
  return child && (0, _typeof2.default)(child) === 'object' && child.props && child.props.type === 'text';
@@ -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.5";
9
+ const packageVersion = "13.8.7";
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}$/;
@@ -14,6 +14,10 @@ const iconStyle = css({
14
14
  flexShrink: 0
15
15
  });
16
16
  const iconSizes = {
17
+ xxsmall: css({
18
+ width: '20px',
19
+ height: '20px'
20
+ }),
17
21
  xsmall: css({
18
22
  width: '20px',
19
23
  height: '20px'
@@ -257,7 +257,7 @@ export class MultiValue extends React.Component {
257
257
  isRemovable: !isDisabled,
258
258
  onAfterRemoveAction: onAfterRemoveAction,
259
259
  avatar: props =>
260
- // AvatarTag always supplies size="xsmall", which is a valid
260
+ // AvatarTag always supplies size="xxsmall", which is a valid
261
261
  // TeamAvatarSize; TeamAvatar does not support UNSAFE_xsmall.
262
262
  jsx(TeamAvatar, _extends({}, props, avatarProps)),
263
263
  hasMargin: false
@@ -11,10 +11,6 @@ export class SizeableAvatar extends React.PureComponent {
11
11
  type = 'person',
12
12
  avatarAppearanceShape
13
13
  } = this.props;
14
-
15
- // `getAvatarSize` only ever returns 'xsmall' | 'small' | 'medium', none of
16
- // which is the team-avatar-unsupported `UNSAFE_xsmall` (20px) size. Keeping
17
- // `size` narrowed here lets the object satisfy both Avatar and TeamAvatar.
18
14
  const size = getAvatarSize(appearance);
19
15
  const props = {
20
16
  size,
@@ -51,7 +51,7 @@ export const optionToSelectableOptions = memoizeOne(defaultValue => {
51
51
  }
52
52
  return optionToSelectableOption(defaultValue);
53
53
  });
54
- export const getAvatarSize = appearance => appearance === 'big' ? 'medium' : appearance === 'multi' ? 'xsmall' : 'small';
54
+ export const getAvatarSize = appearance => appearance === 'big' ? 'medium' : appearance === 'multi' ? 'xxsmall' : 'small';
55
55
  export const isChildInput = child => child && typeof child === 'object' && child.props && child.props.type === 'text';
56
56
  export const isSingleValue = value => !!value && !Array.isArray(value);
57
57
  export const hasValue = value => !!value && value.trim().length > 0;
@@ -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.5";
12
+ var packageVersion = "13.8.7";
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}$/;
@@ -14,6 +14,10 @@ var iconStyle = css({
14
14
  flexShrink: 0
15
15
  });
16
16
  var iconSizes = {
17
+ xxsmall: css({
18
+ width: '20px',
19
+ height: '20px'
20
+ }),
17
21
  xsmall: css({
18
22
  width: '20px',
19
23
  height: '20px'
@@ -255,7 +255,7 @@ export var MultiValue = /*#__PURE__*/function (_React$Component) {
255
255
  onAfterRemoveAction: onAfterRemoveAction,
256
256
  avatar: function avatar(props) {
257
257
  return (
258
- // AvatarTag always supplies size="xsmall", which is a valid
258
+ // AvatarTag always supplies size="xxsmall", which is a valid
259
259
  // TeamAvatarSize; TeamAvatar does not support UNSAFE_xsmall.
260
260
  jsx(TeamAvatar, _extends({}, props, avatarProps))
261
261
  );
@@ -28,10 +28,6 @@ export var SizeableAvatar = /*#__PURE__*/function (_React$PureComponent) {
28
28
  _this$props$type = _this$props.type,
29
29
  type = _this$props$type === void 0 ? 'person' : _this$props$type,
30
30
  avatarAppearanceShape = _this$props.avatarAppearanceShape;
31
-
32
- // `getAvatarSize` only ever returns 'xsmall' | 'small' | 'medium', none of
33
- // which is the team-avatar-unsupported `UNSAFE_xsmall` (20px) size. Keeping
34
- // `size` narrowed here lets the object satisfy both Avatar and TeamAvatar.
35
31
  var size = getAvatarSize(appearance);
36
32
  var props = _objectSpread({
37
33
  size: size,
@@ -76,7 +76,7 @@ export var optionToSelectableOptions = memoizeOne(function (defaultValue) {
76
76
  return optionToSelectableOption(defaultValue);
77
77
  });
78
78
  export var getAvatarSize = function getAvatarSize(appearance) {
79
- return appearance === 'big' ? 'medium' : appearance === 'multi' ? 'xsmall' : 'small';
79
+ return appearance === 'big' ? 'medium' : appearance === 'multi' ? 'xxsmall' : 'small';
80
80
  };
81
81
  export var isChildInput = function isChildInput(child) {
82
82
  return child && _typeof(child) === 'object' && child.props && child.props.type === 'text';
@@ -19,7 +19,7 @@ export interface OptionToSelectableOptions {
19
19
  (defaultValue?: DefaultValue): Option | Option[] | null | undefined;
20
20
  }
21
21
  export declare const optionToSelectableOptions: OptionToSelectableOptions;
22
- export declare const getAvatarSize: (appearance: string) => 'xsmall' | 'small' | 'medium';
22
+ export declare const getAvatarSize: (appearance: string) => 'xxsmall' | 'small' | 'medium';
23
23
  export declare const isChildInput: (child: ReactChild) => child is ReactElement<any>;
24
24
  export declare const isSingleValue: (value?: AtlaskitSelectValue) => value is Option;
25
25
  export declare const hasValue: (value?: string) => value is string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/user-picker",
3
- "version": "13.8.6",
3
+ "version": "13.8.8",
4
4
  "description": "Fabric component for display a dropdown to select a user from",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -18,7 +18,7 @@
18
18
  "@af/visual-regression": "workspace:^",
19
19
  "@atlaskit/heading": "^7.0.0",
20
20
  "@atlaskit/pragmatic-drag-and-drop-react-beautiful-dnd-migration": "^3.2.0",
21
- "@atlassian/a11y-jest-testing": "^0.14.0",
21
+ "@atlassian/a11y-jest-testing": "^0.15.0",
22
22
  "@atlassian/a11y-playwright-testing": "^0.10.0",
23
23
  "@atlassian/feature-flags-test-utils": "^1.2.0",
24
24
  "@emotion/styled": "^11.0.0",
@@ -65,21 +65,21 @@
65
65
  "dependencies": {
66
66
  "@atlaskit/afm-i18n-platform-elements-user-picker": "2.200.0",
67
67
  "@atlaskit/analytics-next": "^12.3.0",
68
- "@atlaskit/avatar": "^26.4.0",
68
+ "@atlaskit/avatar": "^27.0.0",
69
69
  "@atlaskit/feature-gate-js-client": "^6.0.0",
70
70
  "@atlaskit/icon": "^37.3.0",
71
71
  "@atlaskit/logo": "^21.4.0",
72
72
  "@atlaskit/lozenge": "^15.0.0",
73
73
  "@atlaskit/people-teams-ui-public": "^5.2.0",
74
74
  "@atlaskit/platform-feature-flags": "^2.1.0",
75
- "@atlaskit/popper": "^9.0.0",
75
+ "@atlaskit/popper": "^9.1.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
81
  "@atlaskit/teams-avatar": "^4.1.0",
82
- "@atlaskit/tokens": "^16.3.0",
82
+ "@atlaskit/tokens": "^16.4.0",
83
83
  "@atlaskit/tooltip": "^24.0.0",
84
84
  "@atlaskit/ufo": "^1.0.0",
85
85
  "@babel/runtime": "^7.0.0",