@atlaskit/user-picker 11.13.2 → 11.14.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.
Files changed (42) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/afm-jira/tsconfig.json +1 -1
  3. package/dist/cjs/analytics.js +1 -1
  4. package/dist/cjs/components/BaseUserPicker.js +3 -6
  5. package/dist/cjs/components/GroupOption/main.js +23 -2
  6. package/dist/cjs/components/Option.js +4 -2
  7. package/dist/cjs/components/TeamOption/main.js +47 -14
  8. package/dist/cjs/components/UserPicker.js +5 -2
  9. package/dist/cjs/components/i18n.js +35 -0
  10. package/dist/es2019/analytics.js +1 -1
  11. package/dist/es2019/components/BaseUserPicker.js +3 -6
  12. package/dist/es2019/components/GroupOption/main.js +23 -2
  13. package/dist/es2019/components/Option.js +4 -2
  14. package/dist/es2019/components/TeamOption/main.js +40 -8
  15. package/dist/es2019/components/UserPicker.js +4 -2
  16. package/dist/es2019/components/i18n.js +35 -0
  17. package/dist/esm/analytics.js +1 -1
  18. package/dist/esm/components/BaseUserPicker.js +3 -6
  19. package/dist/esm/components/GroupOption/main.js +23 -2
  20. package/dist/esm/components/Option.js +4 -2
  21. package/dist/esm/components/TeamOption/main.js +47 -14
  22. package/dist/esm/components/UserPicker.js +5 -2
  23. package/dist/esm/components/i18n.js +35 -0
  24. package/dist/types/components/BaseUserPicker.d.ts +2 -1
  25. package/dist/types/components/GroupOption/main.d.ts +2 -0
  26. package/dist/types/components/Option.d.ts +1 -0
  27. package/dist/types/components/PopupUserPicker.d.ts +2 -0
  28. package/dist/types/components/TeamOption/main.d.ts +2 -0
  29. package/dist/types/components/UserPicker.d.ts +2 -1
  30. package/dist/types/components/components.d.ts +1 -1
  31. package/dist/types/components/i18n.d.ts +35 -0
  32. package/dist/types/types.d.ts +5 -0
  33. package/dist/types-ts4.5/components/BaseUserPicker.d.ts +2 -1
  34. package/dist/types-ts4.5/components/GroupOption/main.d.ts +2 -0
  35. package/dist/types-ts4.5/components/Option.d.ts +1 -0
  36. package/dist/types-ts4.5/components/PopupUserPicker.d.ts +2 -0
  37. package/dist/types-ts4.5/components/TeamOption/main.d.ts +2 -0
  38. package/dist/types-ts4.5/components/UserPicker.d.ts +2 -1
  39. package/dist/types-ts4.5/components/components.d.ts +1 -1
  40. package/dist/types-ts4.5/components/i18n.d.ts +35 -0
  41. package/dist/types-ts4.5/types.d.ts +5 -0
  42. package/package.json +5 -6
@@ -27,7 +27,6 @@ import { messages } from './i18n';
27
27
  import { callCallback, extractOptionValue, getOptions, isIterable, isPopupUserPickerByComponent, isDefaultValuePopulated, isSingleValue, optionToSelectableOptions } from './utils';
28
28
  import { groupOptionsByType } from '../util/group-options-by-type';
29
29
  import { userPickerOptionsShownUfoExperience } from '../util/ufoExperiences';
30
- import { fg } from '@atlaskit/platform-feature-flags';
31
30
  var loadingMessage = function loadingMessage() {
32
31
  return null;
33
32
  };
@@ -531,10 +530,8 @@ export var BaseUserPickerWithoutAnalytics = /*#__PURE__*/function (_React$Compon
531
530
  name: name,
532
531
  value: value,
533
532
  autoFocus: autoFocus !== undefined ? autoFocus : menuIsOpen,
534
- labelId: fg('user_picker_migrate_aria_label_description') ? ariaLabelledBy !== null && ariaLabelledBy !== void 0 ? ariaLabelledBy : ariaLabelledByStandard : undefined,
535
- "aria-labelledby": fg('user_picker_migrate_aria_label_description') ? undefined : ariaLabelledBy,
536
- descriptionId: fg('user_picker_migrate_aria_label_description') ? ariaDescribedBy !== null && ariaDescribedBy !== void 0 ? ariaDescribedBy : ariaDescribedByStandard : undefined,
537
- "aria-describedby": fg('user_picker_migrate_aria_label_description') ? undefined : ariaDescribedBy,
533
+ labelId: ariaLabelledBy !== null && ariaLabelledBy !== void 0 ? ariaLabelledBy : ariaLabelledByStandard,
534
+ descriptionId: ariaDescribedBy !== null && ariaDescribedBy !== void 0 ? ariaDescribedBy : ariaDescribedByStandard,
538
535
  "aria-live": ariaLive,
539
536
  "aria-required": required // This has been added as a safety net.
540
537
  ,
@@ -587,7 +584,7 @@ export var BaseUserPickerWithoutAnalytics = /*#__PURE__*/function (_React$Compon
587
584
  textFieldBackgroundColor: textFieldBackgroundColor,
588
585
  header: header,
589
586
  placeholderAvatar: placeholderAvatar
590
- }, fg('user_picker_migrate_aria_label_description') ? restAriaProps : this.ariaProps, pickerProps, UNSAFE_hasDraggableParentComponent && {
587
+ }, restAriaProps, pickerProps, UNSAFE_hasDraggableParentComponent && {
591
588
  onValueContainerClick: this.handleClickDraggableParentComponent
592
589
  }, menuOpenDeciderProps));
593
590
  }
@@ -1,3 +1,4 @@
1
+ import _extends from "@babel/runtime/helpers/extends";
1
2
  import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
2
3
  import _createClass from "@babel/runtime/helpers/createClass";
3
4
  import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
@@ -16,6 +17,7 @@ import { FormattedMessage } from 'react-intl-next';
16
17
  import { css, jsx } from '@emotion/react';
17
18
  import { N20, B400, N800, N200 } from '@atlaskit/theme/colors';
18
19
  import PeopleIcon from '@atlaskit/icon/core/migration/people-group--people';
20
+ import { VerifiedTeamIcon } from '@atlaskit/people-teams-ui-public/verified-team-icon';
19
21
  import { AvatarItemOption, textWrapper } from '../AvatarItemOption';
20
22
  import { messages } from '../i18n';
21
23
  import { HighlightText } from '../HighlightText';
@@ -63,15 +65,34 @@ export var GroupOption = /*#__PURE__*/function (_React$PureComponent) {
63
65
  spacing: "spacious"
64
66
  }));
65
67
  });
68
+ _defineProperty(_this, "renderVerifiedIcon", function () {
69
+ return jsx(VerifiedTeamIcon, {
70
+ label: "",
71
+ size: "small",
72
+ spacing: "none"
73
+ });
74
+ });
66
75
  _defineProperty(_this, "renderByline", function () {
67
76
  var _this$props2 = _this.props,
68
77
  isSelected = _this$props2.isSelected,
69
- group = _this$props2.group;
78
+ group = _this$props2.group,
79
+ includeTeamsUpdates = _this$props2.includeTeamsUpdates;
80
+ var getGroupByline = function getGroupByline() {
81
+ if (includeTeamsUpdates) {
82
+ return jsx(FormattedMessage, _extends({}, messages.adminManagedGroupByline, {
83
+ values: {
84
+ verifiedIcon: _this.renderVerifiedIcon()
85
+ }
86
+ }));
87
+ } else {
88
+ return jsx(FormattedMessage, messages.groupByline);
89
+ }
90
+ };
70
91
  return jsx("span", {
71
92
  // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
72
93
  css: textWrapper(isSelected ? "var(--ds-text-selected, ".concat(B400, ")") : "var(--ds-text-subtlest, ".concat(N200, ")")),
73
94
  "data-testid": "user-picker-group-secondary-text"
74
- }, group.byline ? group.byline : jsx(FormattedMessage, messages.groupByline));
95
+ }, group.byline ? group.byline : getGroupByline());
75
96
  });
76
97
  _defineProperty(_this, "getLozengeProps", function () {
77
98
  return typeof _this.props.group.lozenge === 'string' ? {
@@ -54,13 +54,15 @@ var dataOption = function dataOption(_ref2) {
54
54
  if (isTeam(data)) {
55
55
  return /*#__PURE__*/React.createElement(AsyncTeamOption, {
56
56
  team: data,
57
- isSelected: isSelected
57
+ isSelected: isSelected,
58
+ includeTeamsUpdates: data.includeTeamsUpdates
58
59
  });
59
60
  }
60
61
  if (isGroup(data)) {
61
62
  return /*#__PURE__*/React.createElement(AsyncGroupOption, {
62
63
  group: data,
63
- isSelected: isSelected
64
+ isSelected: isSelected,
65
+ includeTeamsUpdates: data.includeTeamsUpdates
64
66
  });
65
67
  }
66
68
  if (isCustom(data)) {
@@ -31,10 +31,12 @@ export var TeamOption = /*#__PURE__*/function (_React$PureComponent) {
31
31
  }
32
32
  _this = _callSuper(this, TeamOption, [].concat(args));
33
33
  _defineProperty(_this, "getPrimaryText", function () {
34
- var _this$props$team = _this.props.team,
34
+ var _this$props = _this.props,
35
+ _this$props$team = _this$props.team,
35
36
  name = _this$props$team.name,
36
37
  highlight = _this$props$team.highlight,
37
- verified = _this$props$team.verified;
38
+ verified = _this$props$team.verified,
39
+ includeTeamsUpdates = _this$props.includeTeamsUpdates;
38
40
  return [jsx("span", {
39
41
  key: "name"
40
42
  // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
@@ -44,14 +46,17 @@ export var TeamOption = /*#__PURE__*/function (_React$PureComponent) {
44
46
  alignBlock: "center"
45
47
  }, jsx(HighlightText, {
46
48
  highlights: highlight && highlight.name
47
- }, name), verified && jsx(VerifiedTeamIcon, null)))];
49
+ }, name), verified && !includeTeamsUpdates && _this.renderVerifiedIcon()))];
48
50
  });
49
51
  _defineProperty(_this, "renderByline", function () {
50
- var _this$props = _this.props,
51
- isSelected = _this$props.isSelected,
52
- _this$props$team2 = _this$props.team,
53
- memberCount = _this$props$team2.memberCount,
54
- includesYou = _this$props$team2.includesYou;
52
+ var _this$props2 = _this.props,
53
+ isSelected = _this$props2.isSelected,
54
+ _this$props2$team = _this$props2.team,
55
+ memberCount = _this$props2$team.memberCount,
56
+ includesYou = _this$props2$team.includesYou,
57
+ verified = _this$props2$team.verified,
58
+ includeTeamsUpdates = _this$props2.includeTeamsUpdates;
59
+ var isVerified = includeTeamsUpdates && verified;
55
60
 
56
61
  // if Member count is missing, do not show the byline, regardless of the availability of includesYou
57
62
  if (memberCount === null || typeof memberCount === 'undefined') {
@@ -59,9 +64,18 @@ export var TeamOption = /*#__PURE__*/function (_React$PureComponent) {
59
64
  } else {
60
65
  if (includesYou === true) {
61
66
  if (memberCount > 50) {
62
- return _this.getBylineComponent(isSelected, jsx(FormattedMessage, messages.plus50MembersWithYou));
67
+ return _this.getBylineComponent(isSelected, isVerified ? jsx(FormattedMessage, _extends({}, messages.officialPlus50MembersWithYou, {
68
+ values: {
69
+ verifiedIcon: _this.renderVerifiedIcon()
70
+ }
71
+ })) : jsx(FormattedMessage, messages.plus50MembersWithYou));
63
72
  } else {
64
- return _this.getBylineComponent(isSelected, jsx(FormattedMessage, _extends({}, messages.memberCountWithYou, {
73
+ return _this.getBylineComponent(isSelected, isVerified ? jsx(FormattedMessage, _extends({}, messages.officialMemberCountWithYou, {
74
+ values: {
75
+ verifiedIcon: _this.renderVerifiedIcon(),
76
+ count: memberCount
77
+ }
78
+ })) : jsx(FormattedMessage, _extends({}, messages.memberCountWithYou, {
65
79
  values: {
66
80
  count: memberCount
67
81
  }
@@ -69,9 +83,18 @@ export var TeamOption = /*#__PURE__*/function (_React$PureComponent) {
69
83
  }
70
84
  } else {
71
85
  if (memberCount > 50) {
72
- return _this.getBylineComponent(isSelected, jsx(FormattedMessage, messages.plus50MembersWithoutYou));
86
+ return _this.getBylineComponent(isSelected, isVerified ? jsx(FormattedMessage, _extends({}, messages.officialPlus50MembersWithoutYou, {
87
+ values: {
88
+ verifiedIcon: _this.renderVerifiedIcon()
89
+ }
90
+ })) : jsx(FormattedMessage, messages.plus50MembersWithoutYou));
73
91
  } else {
74
- return _this.getBylineComponent(isSelected, jsx(FormattedMessage, _extends({}, messages.memberCountWithoutYou, {
92
+ return _this.getBylineComponent(isSelected, isVerified ? jsx(FormattedMessage, _extends({}, messages.officialMemberCountWithoutYou, {
93
+ values: {
94
+ verifiedIcon: _this.renderVerifiedIcon(),
95
+ count: memberCount
96
+ }
97
+ })) : jsx(FormattedMessage, _extends({}, messages.memberCountWithoutYou, {
75
98
  values: {
76
99
  count: memberCount
77
100
  }
@@ -95,14 +118,24 @@ export var TeamOption = /*#__PURE__*/function (_React$PureComponent) {
95
118
  type: "team"
96
119
  });
97
120
  });
121
+ _defineProperty(_this, "renderVerifiedIcon", function () {
122
+ if (_this.props.team.verified) {
123
+ return jsx(VerifiedTeamIcon, {
124
+ label: "",
125
+ size: "small",
126
+ spacing: "none"
127
+ });
128
+ }
129
+ return undefined;
130
+ });
98
131
  _defineProperty(_this, "getLozengeProps", function () {
99
132
  return typeof _this.props.team.lozenge === 'string' ? {
100
133
  text: _this.props.team.lozenge
101
134
  } : _this.props.team.lozenge;
102
135
  });
103
136
  _defineProperty(_this, "renderCustomByLine", function () {
104
- var _this$props$team3;
105
- if (!((_this$props$team3 = _this.props.team) !== null && _this$props$team3 !== void 0 && _this$props$team3.byline)) {
137
+ var _this$props$team2;
138
+ if (!((_this$props$team2 = _this.props.team) !== null && _this$props$team2 !== void 0 && _this$props$team2.byline)) {
106
139
  return undefined;
107
140
  }
108
141
  return jsx("span", {
@@ -70,7 +70,9 @@ export var UserPickerWithoutAnalytics = /*#__PURE__*/function (_React$Component)
70
70
  _this$props$required = _this$props.required,
71
71
  required = _this$props$required === void 0 ? false : _this$props$required,
72
72
  _this$props$showClear = _this$props.showClearIndicator,
73
- showClearIndicator = _this$props$showClear === void 0 ? false : _this$props$showClear;
73
+ showClearIndicator = _this$props$showClear === void 0 ? false : _this$props$showClear,
74
+ _this$props$includeTe = _this$props.includeTeamsUpdates,
75
+ includeTeamsUpdates = _this$props$includeTe === void 0 ? false : _this$props$includeTe;
74
76
  var width = this.props.width;
75
77
  var SelectComponent = allowEmail ? CreatableSelect : Select;
76
78
  var creatableProps = suggestEmailsForDomain ? getCreatableSuggestedEmailProps(suggestEmailsForDomain, isValidEmail) : getCreatableProps(isValidEmail);
@@ -80,7 +82,8 @@ export var UserPickerWithoutAnalytics = /*#__PURE__*/function (_React$Component)
80
82
  menuPosition: menuPosition,
81
83
  menuShouldBlockScroll: menuShouldBlockScroll,
82
84
  captureMenuScroll: captureMenuScroll,
83
- required: required
85
+ required: required,
86
+ includeTeamsUpdates: includeTeamsUpdates
84
87
  };
85
88
  var pickerProps = allowEmail ? _objectSpread(_objectSpread(_objectSpread({}, defaultPickerProps), creatableProps), {}, {
86
89
  emailLabel: emailLabel
@@ -25,6 +25,26 @@ export var messages = defineMessages({
25
25
  defaultMessage: 'Something went wrong',
26
26
  description: 'Error message to display when options fail to load.'
27
27
  },
28
+ teamByline: {
29
+ id: 'fabric.elements.user-picker.team.byline',
30
+ defaultMessage: 'Team',
31
+ description: 'Byline for team'
32
+ },
33
+ officialTeamByline: {
34
+ id: 'fabric.elements.user-picker.team.byline.official',
35
+ defaultMessage: 'Official team {verifiedIcon}',
36
+ description: 'Byline for official team'
37
+ },
38
+ officialMemberCountWithoutYou: {
39
+ id: 'fabric.elements.user-picker.team.member.count.official',
40
+ defaultMessage: 'Official team {verifiedIcon} • {count} {count, plural, one {member} other {members}}',
41
+ description: 'Byline to show the number of members in the team when the current user is not a member of the team'
42
+ },
43
+ officialMemberCountWithYou: {
44
+ id: 'fabric.elements.user-picker.team.member.count.official.including.you',
45
+ defaultMessage: 'Official team {verifiedIcon} • {count} {count, plural, one {member} other {members}}, including you',
46
+ description: 'Byline to show the number of members in the team when the current user is also a member of the team'
47
+ },
28
48
  memberCountWithoutYou: {
29
49
  id: 'fabric.elements.user-picker.team.member.count',
30
50
  defaultMessage: 'Team • {count} {count, plural, one {member} other {members}}',
@@ -35,6 +55,16 @@ export var messages = defineMessages({
35
55
  defaultMessage: 'Team • {count} {count, plural, one {member} other {members}}, including you',
36
56
  description: 'Byline to show the number of members in the team when the current user is also a member of the team'
37
57
  },
58
+ officialPlus50MembersWithoutYou: {
59
+ id: 'fabric.elements.user-picker.team.member.50plus.official',
60
+ defaultMessage: 'Official team {verifiedIcon} • 50+ members',
61
+ description: 'Byline to show the number of members in the team when the number exceeds 50'
62
+ },
63
+ officialPlus50MembersWithYou: {
64
+ id: 'fabric.elements.user-picker.team.member.50plus.official.including.you',
65
+ defaultMessage: 'Official team {verifiedIcon} • 50+ members, including you',
66
+ description: 'Byline to show the number of members in the team when the number exceeds 50 and also includes the current user'
67
+ },
38
68
  plus50MembersWithoutYou: {
39
69
  id: 'fabric.elements.user-picker.team.member.50plus',
40
70
  defaultMessage: 'Team • 50+ members',
@@ -60,6 +90,11 @@ export var messages = defineMessages({
60
90
  defaultMessage: 'Enter an email address',
61
91
  description: 'Byline for a potentially valid email option.'
62
92
  },
93
+ adminManagedGroupByline: {
94
+ id: 'fabric.elements.user-picker.group.byline.admin-managed',
95
+ defaultMessage: 'Admin group {verifiedIcon}',
96
+ description: 'Byline for admin-managed groups with verified icon'
97
+ },
63
98
  groupByline: {
64
99
  id: 'fabric.elements.user-picker.group.byline',
65
100
  defaultMessage: 'Admin-managed group',
@@ -88,6 +88,7 @@ export declare const BaseUserPicker: React.ForwardRefExoticComponent<Pick<Omit<{
88
88
  groupByTypeOrder?: NonNullable<OptionData["type"]>[];
89
89
  header?: React.ReactNode;
90
90
  height?: number | string;
91
+ includeTeamsUpdates?: boolean;
91
92
  inputId?: string;
92
93
  isClearable?: boolean;
93
94
  isDisabled?: boolean;
@@ -150,7 +151,7 @@ export declare const BaseUserPicker: React.ForwardRefExoticComponent<Pick<Omit<{
150
151
  */
151
152
  UNSAFE_hasDraggableParentComponent?: boolean;
152
153
  width: string | number;
153
- }, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "placeholder" | "isDisabled" | "onChange" | "onInputChange" | "value" | "appearance" | "autoFocus" | "captureMenuScroll" | "closeMenuOnScroll" | "components" | "inputId" | "isInvalid" | "isLoading" | "menuPosition" | "menuPortalTarget" | "menuShouldBlockScroll" | "name" | "noOptionsMessage" | "onBlur" | "onFocus" | "onKeyDown" | "options" | "styles" | "required" | "footer" | "defaultValue" | "search" | "anchor" | "addMoreMessage" | "allowEmail" | "ariaDescribedBy" | "ariaLabel" | "ariaLabelledBy" | "ariaLive" | "clearValueLabel" | "disableInput" | "emailLabel" | "fieldId" | "forwardedRef" | "groupByTypeOrder" | "header" | "height" | "isValidEmail" | "loadOptions" | "loadUserSource" | "maxOptions" | "maxPickerHeight" | "menuMinWidth" | "onClear" | "onClose" | "onOpen" | "onSelection" | "open" | "placeholderAvatar" | "popupSelectProps" | "showClearIndicator" | "strategy" | "suggestEmailsForDomain" | "UNSAFE_hasDraggableParentComponent" | "width" | "pickerProps" | "SelectComponent"> & {
154
+ }, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "placeholder" | "isDisabled" | "onChange" | "onInputChange" | "value" | "appearance" | "autoFocus" | "captureMenuScroll" | "closeMenuOnScroll" | "components" | "inputId" | "isInvalid" | "isLoading" | "menuPosition" | "menuPortalTarget" | "menuShouldBlockScroll" | "name" | "noOptionsMessage" | "onBlur" | "onFocus" | "onKeyDown" | "options" | "styles" | "required" | "footer" | "defaultValue" | "search" | "anchor" | "addMoreMessage" | "allowEmail" | "ariaDescribedBy" | "ariaLabel" | "ariaLabelledBy" | "ariaLive" | "clearValueLabel" | "disableInput" | "emailLabel" | "fieldId" | "forwardedRef" | "groupByTypeOrder" | "header" | "height" | "includeTeamsUpdates" | "isValidEmail" | "loadOptions" | "loadUserSource" | "maxOptions" | "maxPickerHeight" | "menuMinWidth" | "onClear" | "onClose" | "onOpen" | "onSelection" | "open" | "placeholderAvatar" | "popupSelectProps" | "showClearIndicator" | "strategy" | "suggestEmailsForDomain" | "UNSAFE_hasDraggableParentComponent" | "width" | "pickerProps" | "SelectComponent"> & {
154
155
  isClearable?: boolean | undefined;
155
156
  isMulti?: boolean | undefined;
156
157
  openMenuOnClick?: boolean | undefined;
@@ -8,11 +8,13 @@ import { type Group } from '../../types';
8
8
  export declare const groupOptionIconWrapper: import("@emotion/react").SerializedStyles;
9
9
  export type GroupOptionProps = {
10
10
  group: Group;
11
+ includeTeamsUpdates?: boolean;
11
12
  isSelected: boolean;
12
13
  };
13
14
  export declare class GroupOption extends React.PureComponent<GroupOptionProps> {
14
15
  private getPrimaryText;
15
16
  private renderAvatar;
17
+ private renderVerifiedIcon;
16
18
  private renderByline;
17
19
  private getLozengeProps;
18
20
  render(): jsx.JSX.Element;
@@ -3,6 +3,7 @@ import { type FC } from 'react';
3
3
  import { type Option as OptionType } from '../types';
4
4
  export type OptionProps = AkOptionProps & {
5
5
  data: OptionType;
6
+ includeTeamsUpdates?: boolean;
6
7
  isDisabled: boolean;
7
8
  isFocused: boolean;
8
9
  isSelected: boolean;
@@ -42,6 +42,7 @@ export declare const PopupUserPicker: React.ForwardRefExoticComponent<Omit<Pick<
42
42
  groupByTypeOrder?: NonNullable<import("../types").OptionData["type"]>[];
43
43
  header?: React.ReactNode;
44
44
  height?: number | string;
45
+ includeTeamsUpdates?: boolean;
45
46
  inputId?: string;
46
47
  isClearable?: boolean;
47
48
  isDisabled?: boolean;
@@ -149,6 +150,7 @@ export declare const PopupUserPicker: React.ForwardRefExoticComponent<Omit<Pick<
149
150
  groupByTypeOrder?: NonNullable<import("../types").OptionData["type"]>[] | undefined;
150
151
  header?: React.ReactNode;
151
152
  height?: number | string | undefined;
153
+ includeTeamsUpdates?: boolean | undefined;
152
154
  isValidEmail?: import("./emailValidation").EmailValidator | undefined;
153
155
  loadOptions?: import("../types").LoadOptions | undefined;
154
156
  loadOptionsErrorMessage?: ((value: {
@@ -2,6 +2,7 @@ import { jsx } from '@emotion/react';
2
2
  import React from 'react';
3
3
  import { type Team } from '../../types';
4
4
  export type TeamOptionProps = {
5
+ includeTeamsUpdates?: boolean;
5
6
  isSelected: boolean;
6
7
  team: Team;
7
8
  };
@@ -10,6 +11,7 @@ export declare class TeamOption extends React.PureComponent<TeamOptionProps> {
10
11
  private renderByline;
11
12
  private getBylineComponent;
12
13
  private renderAvatar;
14
+ private renderVerifiedIcon;
13
15
  private getLozengeProps;
14
16
  private renderCustomByLine;
15
17
  render(): jsx.JSX.Element;
@@ -33,6 +33,7 @@ export declare const UserPicker: React.ForwardRefExoticComponent<Pick<Omit<{
33
33
  groupByTypeOrder?: NonNullable<import("../types").OptionData["type"]>[];
34
34
  header?: React.ReactNode;
35
35
  height?: number | string;
36
+ includeTeamsUpdates?: boolean;
36
37
  inputId?: string;
37
38
  isClearable?: boolean;
38
39
  isDisabled?: boolean;
@@ -82,7 +83,7 @@ export declare const UserPicker: React.ForwardRefExoticComponent<Pick<Omit<{
82
83
  UNSAFE_hasDraggableParentComponent?: boolean;
83
84
  value?: import("../types").Value;
84
85
  width?: number | string;
85
- }, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "placeholder" | "isDisabled" | "onChange" | "onInputChange" | "value" | "appearance" | "autoFocus" | "captureMenuScroll" | "closeMenuOnScroll" | "components" | "inputId" | "isClearable" | "isInvalid" | "isLoading" | "menuPosition" | "menuPortalTarget" | "menuShouldBlockScroll" | "name" | "noOptionsMessage" | "onBlur" | "onFocus" | "onKeyDown" | "openMenuOnClick" | "options" | "styles" | "required" | "footer" | "defaultValue" | "search" | "anchor" | "addMoreMessage" | "allowEmail" | "ariaDescribedBy" | "ariaLabel" | "ariaLabelledBy" | "ariaLive" | "clearValueLabel" | "disableInput" | "emailLabel" | "fieldId" | "forwardedRef" | "groupByTypeOrder" | "header" | "height" | "isValidEmail" | "loadOptions" | "loadOptionsErrorMessage" | "loadUserSource" | "maxOptions" | "maxPickerHeight" | "menuMinWidth" | "noBorder" | "onClear" | "onClose" | "onOpen" | "onSelection" | "open" | "placeholderAvatar" | "popupSelectProps" | "showClearIndicator" | "strategy" | "subtle" | "suggestEmailsForDomain" | "textFieldBackgroundColor" | "UNSAFE_hasDraggableParentComponent"> & {
86
+ }, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "placeholder" | "isDisabled" | "onChange" | "onInputChange" | "value" | "appearance" | "autoFocus" | "captureMenuScroll" | "closeMenuOnScroll" | "components" | "inputId" | "isClearable" | "isInvalid" | "isLoading" | "menuPosition" | "menuPortalTarget" | "menuShouldBlockScroll" | "name" | "noOptionsMessage" | "onBlur" | "onFocus" | "onKeyDown" | "openMenuOnClick" | "options" | "styles" | "required" | "footer" | "defaultValue" | "search" | "anchor" | "addMoreMessage" | "allowEmail" | "ariaDescribedBy" | "ariaLabel" | "ariaLabelledBy" | "ariaLive" | "clearValueLabel" | "disableInput" | "emailLabel" | "fieldId" | "forwardedRef" | "groupByTypeOrder" | "header" | "height" | "includeTeamsUpdates" | "isValidEmail" | "loadOptions" | "loadOptionsErrorMessage" | "loadUserSource" | "maxOptions" | "maxPickerHeight" | "menuMinWidth" | "noBorder" | "onClear" | "onClose" | "onOpen" | "onSelection" | "open" | "placeholderAvatar" | "popupSelectProps" | "showClearIndicator" | "strategy" | "subtle" | "suggestEmailsForDomain" | "textFieldBackgroundColor" | "UNSAFE_hasDraggableParentComponent"> & {
86
87
  isMulti?: boolean | undefined;
87
88
  width?: number | string | undefined;
88
89
  } & {} & React.RefAttributes<any>>;
@@ -26,7 +26,7 @@ export declare const getComponents: import("memoize-one").MemoizedFn<(multi?: bo
26
26
  LoadingIndicator?: import("react").ComponentType<import("@atlaskit/select").LoadingIndicatorProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
27
27
  Menu: typeof Menu | import("react").ComponentType<import("packages/design-system/react-select/dist/types").MenuProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>>;
28
28
  MenuList?: import("react").ComponentType<import("packages/design-system/react-select/dist/types").MenuListProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
29
- MenuPortal?: import("react").ComponentType<import("packages/design-system/react-select/dist/types/components/menu").MenuPortalProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
29
+ MenuPortal?: import("react").ComponentType<import("packages/design-system/react-select/dist/types").MenuPortalProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
30
30
  LoadingMessage?: import("react").ComponentType<import("@atlaskit/select").NoticeProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
31
31
  NoOptionsMessage?: import("react").ComponentType<import("@atlaskit/select").NoticeProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
32
32
  MultiValue: typeof MultiValue | import("react").ComponentType<import("@atlaskit/select").MultiValueProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>>;
@@ -24,6 +24,26 @@ export declare const messages: {
24
24
  defaultMessage: string;
25
25
  description: string;
26
26
  };
27
+ teamByline: {
28
+ id: string;
29
+ defaultMessage: string;
30
+ description: string;
31
+ };
32
+ officialTeamByline: {
33
+ id: string;
34
+ defaultMessage: string;
35
+ description: string;
36
+ };
37
+ officialMemberCountWithoutYou: {
38
+ id: string;
39
+ defaultMessage: string;
40
+ description: string;
41
+ };
42
+ officialMemberCountWithYou: {
43
+ id: string;
44
+ defaultMessage: string;
45
+ description: string;
46
+ };
27
47
  memberCountWithoutYou: {
28
48
  id: string;
29
49
  defaultMessage: string;
@@ -34,6 +54,16 @@ export declare const messages: {
34
54
  defaultMessage: string;
35
55
  description: string;
36
56
  };
57
+ officialPlus50MembersWithoutYou: {
58
+ id: string;
59
+ defaultMessage: string;
60
+ description: string;
61
+ };
62
+ officialPlus50MembersWithYou: {
63
+ id: string;
64
+ defaultMessage: string;
65
+ description: string;
66
+ };
37
67
  plus50MembersWithoutYou: {
38
68
  id: string;
39
69
  defaultMessage: string;
@@ -59,6 +89,11 @@ export declare const messages: {
59
89
  defaultMessage: string;
60
90
  description: string;
61
91
  };
92
+ adminManagedGroupByline: {
93
+ id: string;
94
+ defaultMessage: string;
95
+ description: string;
96
+ };
62
97
  groupByline: {
63
98
  id: string;
64
99
  defaultMessage: string;
@@ -70,6 +70,8 @@ export type UserPickerProps = WithAnalyticsEventsProps & {
70
70
  header?: React.ReactNode;
71
71
  /** Sets the height of the user picker. If not set, the height settings will be based on the "compact" or "normal" appearance. */
72
72
  height?: number | string;
73
+ /** Whether to include teams UI updates in the resultset. @default false */
74
+ includeTeamsUpdates?: boolean;
73
75
  /** Allows clicking on a label with the same id to open user picker. */
74
76
  inputId?: string;
75
77
  /** Display a remove button on the single picker. True by default. */
@@ -263,6 +265,7 @@ export interface OptionData {
263
265
  avatarUrl?: any;
264
266
  fixed?: boolean;
265
267
  id: string;
268
+ includeTeamsUpdates?: boolean;
266
269
  isDisabled?: boolean;
267
270
  lozenge?: string | LozengeProps | ReactNode;
268
271
  name: string;
@@ -310,6 +313,7 @@ export interface Team extends OptionData {
310
313
  description?: string;
311
314
  highlight?: TeamHighlight;
312
315
  includesYou?: boolean;
316
+ includeTeamsUpdates?: boolean;
313
317
  memberCount?: number;
314
318
  members?: TeamMember[];
315
319
  type: 'team';
@@ -319,6 +323,7 @@ export declare const GroupType = "group";
319
323
  export interface Group extends OptionData {
320
324
  byline?: string;
321
325
  highlight?: GroupHighlight;
326
+ includeTeamsUpdates?: boolean;
322
327
  type: 'group';
323
328
  }
324
329
  export interface Custom extends OptionData {
@@ -88,6 +88,7 @@ export declare const BaseUserPicker: React.ForwardRefExoticComponent<Pick<Omit<{
88
88
  groupByTypeOrder?: NonNullable<OptionData["type"]>[];
89
89
  header?: React.ReactNode;
90
90
  height?: number | string;
91
+ includeTeamsUpdates?: boolean;
91
92
  inputId?: string;
92
93
  isClearable?: boolean;
93
94
  isDisabled?: boolean;
@@ -150,7 +151,7 @@ export declare const BaseUserPicker: React.ForwardRefExoticComponent<Pick<Omit<{
150
151
  */
151
152
  UNSAFE_hasDraggableParentComponent?: boolean;
152
153
  width: string | number;
153
- }, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "placeholder" | "isDisabled" | "onChange" | "onInputChange" | "value" | "appearance" | "autoFocus" | "captureMenuScroll" | "closeMenuOnScroll" | "components" | "inputId" | "isInvalid" | "isLoading" | "menuPosition" | "menuPortalTarget" | "menuShouldBlockScroll" | "name" | "noOptionsMessage" | "onBlur" | "onFocus" | "onKeyDown" | "options" | "styles" | "required" | "footer" | "defaultValue" | "search" | "anchor" | "addMoreMessage" | "allowEmail" | "ariaDescribedBy" | "ariaLabel" | "ariaLabelledBy" | "ariaLive" | "clearValueLabel" | "disableInput" | "emailLabel" | "fieldId" | "forwardedRef" | "groupByTypeOrder" | "header" | "height" | "isValidEmail" | "loadOptions" | "loadUserSource" | "maxOptions" | "maxPickerHeight" | "menuMinWidth" | "onClear" | "onClose" | "onOpen" | "onSelection" | "open" | "placeholderAvatar" | "popupSelectProps" | "showClearIndicator" | "strategy" | "suggestEmailsForDomain" | "UNSAFE_hasDraggableParentComponent" | "width" | "pickerProps" | "SelectComponent"> & {
154
+ }, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "placeholder" | "isDisabled" | "onChange" | "onInputChange" | "value" | "appearance" | "autoFocus" | "captureMenuScroll" | "closeMenuOnScroll" | "components" | "inputId" | "isInvalid" | "isLoading" | "menuPosition" | "menuPortalTarget" | "menuShouldBlockScroll" | "name" | "noOptionsMessage" | "onBlur" | "onFocus" | "onKeyDown" | "options" | "styles" | "required" | "footer" | "defaultValue" | "search" | "anchor" | "addMoreMessage" | "allowEmail" | "ariaDescribedBy" | "ariaLabel" | "ariaLabelledBy" | "ariaLive" | "clearValueLabel" | "disableInput" | "emailLabel" | "fieldId" | "forwardedRef" | "groupByTypeOrder" | "header" | "height" | "includeTeamsUpdates" | "isValidEmail" | "loadOptions" | "loadUserSource" | "maxOptions" | "maxPickerHeight" | "menuMinWidth" | "onClear" | "onClose" | "onOpen" | "onSelection" | "open" | "placeholderAvatar" | "popupSelectProps" | "showClearIndicator" | "strategy" | "suggestEmailsForDomain" | "UNSAFE_hasDraggableParentComponent" | "width" | "pickerProps" | "SelectComponent"> & {
154
155
  isClearable?: boolean | undefined;
155
156
  isMulti?: boolean | undefined;
156
157
  openMenuOnClick?: boolean | undefined;
@@ -8,11 +8,13 @@ import { type Group } from '../../types';
8
8
  export declare const groupOptionIconWrapper: import("@emotion/react").SerializedStyles;
9
9
  export type GroupOptionProps = {
10
10
  group: Group;
11
+ includeTeamsUpdates?: boolean;
11
12
  isSelected: boolean;
12
13
  };
13
14
  export declare class GroupOption extends React.PureComponent<GroupOptionProps> {
14
15
  private getPrimaryText;
15
16
  private renderAvatar;
17
+ private renderVerifiedIcon;
16
18
  private renderByline;
17
19
  private getLozengeProps;
18
20
  render(): jsx.JSX.Element;
@@ -3,6 +3,7 @@ import { type FC } from 'react';
3
3
  import { type Option as OptionType } from '../types';
4
4
  export type OptionProps = AkOptionProps & {
5
5
  data: OptionType;
6
+ includeTeamsUpdates?: boolean;
6
7
  isDisabled: boolean;
7
8
  isFocused: boolean;
8
9
  isSelected: boolean;
@@ -42,6 +42,7 @@ export declare const PopupUserPicker: React.ForwardRefExoticComponent<Omit<Pick<
42
42
  groupByTypeOrder?: NonNullable<import("../types").OptionData["type"]>[];
43
43
  header?: React.ReactNode;
44
44
  height?: number | string;
45
+ includeTeamsUpdates?: boolean;
45
46
  inputId?: string;
46
47
  isClearable?: boolean;
47
48
  isDisabled?: boolean;
@@ -155,6 +156,7 @@ export declare const PopupUserPicker: React.ForwardRefExoticComponent<Omit<Pick<
155
156
  groupByTypeOrder?: NonNullable<import("../types").OptionData["type"]>[] | undefined;
156
157
  header?: React.ReactNode;
157
158
  height?: number | string | undefined;
159
+ includeTeamsUpdates?: boolean | undefined;
158
160
  isValidEmail?: import("./emailValidation").EmailValidator | undefined;
159
161
  loadOptions?: import("../types").LoadOptions | undefined;
160
162
  loadOptionsErrorMessage?: ((value: {
@@ -2,6 +2,7 @@ import { jsx } from '@emotion/react';
2
2
  import React from 'react';
3
3
  import { type Team } from '../../types';
4
4
  export type TeamOptionProps = {
5
+ includeTeamsUpdates?: boolean;
5
6
  isSelected: boolean;
6
7
  team: Team;
7
8
  };
@@ -10,6 +11,7 @@ export declare class TeamOption extends React.PureComponent<TeamOptionProps> {
10
11
  private renderByline;
11
12
  private getBylineComponent;
12
13
  private renderAvatar;
14
+ private renderVerifiedIcon;
13
15
  private getLozengeProps;
14
16
  private renderCustomByLine;
15
17
  render(): jsx.JSX.Element;
@@ -33,6 +33,7 @@ export declare const UserPicker: React.ForwardRefExoticComponent<Pick<Omit<{
33
33
  groupByTypeOrder?: NonNullable<import("../types").OptionData["type"]>[];
34
34
  header?: React.ReactNode;
35
35
  height?: number | string;
36
+ includeTeamsUpdates?: boolean;
36
37
  inputId?: string;
37
38
  isClearable?: boolean;
38
39
  isDisabled?: boolean;
@@ -82,7 +83,7 @@ export declare const UserPicker: React.ForwardRefExoticComponent<Pick<Omit<{
82
83
  UNSAFE_hasDraggableParentComponent?: boolean;
83
84
  value?: import("../types").Value;
84
85
  width?: number | string;
85
- }, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "placeholder" | "isDisabled" | "onChange" | "onInputChange" | "value" | "appearance" | "autoFocus" | "captureMenuScroll" | "closeMenuOnScroll" | "components" | "inputId" | "isClearable" | "isInvalid" | "isLoading" | "menuPosition" | "menuPortalTarget" | "menuShouldBlockScroll" | "name" | "noOptionsMessage" | "onBlur" | "onFocus" | "onKeyDown" | "openMenuOnClick" | "options" | "styles" | "required" | "footer" | "defaultValue" | "search" | "anchor" | "addMoreMessage" | "allowEmail" | "ariaDescribedBy" | "ariaLabel" | "ariaLabelledBy" | "ariaLive" | "clearValueLabel" | "disableInput" | "emailLabel" | "fieldId" | "forwardedRef" | "groupByTypeOrder" | "header" | "height" | "isValidEmail" | "loadOptions" | "loadOptionsErrorMessage" | "loadUserSource" | "maxOptions" | "maxPickerHeight" | "menuMinWidth" | "noBorder" | "onClear" | "onClose" | "onOpen" | "onSelection" | "open" | "placeholderAvatar" | "popupSelectProps" | "showClearIndicator" | "strategy" | "subtle" | "suggestEmailsForDomain" | "textFieldBackgroundColor" | "UNSAFE_hasDraggableParentComponent"> & {
86
+ }, keyof import("@atlaskit/analytics-next").WithAnalyticsEventsProps>, "placeholder" | "isDisabled" | "onChange" | "onInputChange" | "value" | "appearance" | "autoFocus" | "captureMenuScroll" | "closeMenuOnScroll" | "components" | "inputId" | "isClearable" | "isInvalid" | "isLoading" | "menuPosition" | "menuPortalTarget" | "menuShouldBlockScroll" | "name" | "noOptionsMessage" | "onBlur" | "onFocus" | "onKeyDown" | "openMenuOnClick" | "options" | "styles" | "required" | "footer" | "defaultValue" | "search" | "anchor" | "addMoreMessage" | "allowEmail" | "ariaDescribedBy" | "ariaLabel" | "ariaLabelledBy" | "ariaLive" | "clearValueLabel" | "disableInput" | "emailLabel" | "fieldId" | "forwardedRef" | "groupByTypeOrder" | "header" | "height" | "includeTeamsUpdates" | "isValidEmail" | "loadOptions" | "loadOptionsErrorMessage" | "loadUserSource" | "maxOptions" | "maxPickerHeight" | "menuMinWidth" | "noBorder" | "onClear" | "onClose" | "onOpen" | "onSelection" | "open" | "placeholderAvatar" | "popupSelectProps" | "showClearIndicator" | "strategy" | "subtle" | "suggestEmailsForDomain" | "textFieldBackgroundColor" | "UNSAFE_hasDraggableParentComponent"> & {
86
87
  isMulti?: boolean | undefined;
87
88
  width?: number | string | undefined;
88
89
  } & {} & React.RefAttributes<any>>;
@@ -26,7 +26,7 @@ export declare const getComponents: import("memoize-one").MemoizedFn<(multi?: bo
26
26
  LoadingIndicator?: import("react").ComponentType<import("@atlaskit/select").LoadingIndicatorProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
27
27
  Menu: typeof Menu | import("react").ComponentType<import("packages/design-system/react-select/dist/types").MenuProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>>;
28
28
  MenuList?: import("react").ComponentType<import("packages/design-system/react-select/dist/types").MenuListProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
29
- MenuPortal?: import("react").ComponentType<import("packages/design-system/react-select/dist/types/components/menu").MenuPortalProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
29
+ MenuPortal?: import("react").ComponentType<import("packages/design-system/react-select/dist/types").MenuPortalProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
30
30
  LoadingMessage?: import("react").ComponentType<import("@atlaskit/select").NoticeProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
31
31
  NoOptionsMessage?: import("react").ComponentType<import("@atlaskit/select").NoticeProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>> | undefined;
32
32
  MultiValue: typeof MultiValue | import("react").ComponentType<import("@atlaskit/select").MultiValueProps<OptionData, boolean, import("@atlaskit/select").GroupType<OptionData>>>;