@atlaskit/user-picker 11.13.0 → 11.13.2

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 (47) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/dist/cjs/analytics.js +1 -1
  3. package/dist/cjs/components/AddOptionAvatar.js +2 -2
  4. package/dist/cjs/components/AvatarItemOption.js +44 -1
  5. package/dist/cjs/components/Control.compiled.css +6 -6
  6. package/dist/cjs/components/Control.js +3 -3
  7. package/dist/cjs/components/GroupOption/main.js +1 -22
  8. package/dist/cjs/components/Input.compiled.css +3 -3
  9. package/dist/cjs/components/Input.js +1 -1
  10. package/dist/cjs/components/SingleValue.compiled.css +1 -1
  11. package/dist/cjs/components/SingleValue.js +1 -1
  12. package/dist/cjs/components/TeamOption/main.js +8 -38
  13. package/dist/cjs/components/UserOption.js +12 -1
  14. package/dist/cjs/components/i18n.js +0 -35
  15. package/dist/es2019/analytics.js +1 -1
  16. package/dist/es2019/components/AddOptionAvatar.js +2 -2
  17. package/dist/es2019/components/AvatarItemOption.js +71 -22
  18. package/dist/es2019/components/Control.compiled.css +6 -6
  19. package/dist/es2019/components/Control.js +3 -3
  20. package/dist/es2019/components/GroupOption/main.js +1 -22
  21. package/dist/es2019/components/Input.compiled.css +3 -3
  22. package/dist/es2019/components/Input.js +1 -1
  23. package/dist/es2019/components/SingleValue.compiled.css +1 -1
  24. package/dist/es2019/components/SingleValue.js +1 -1
  25. package/dist/es2019/components/TeamOption/main.js +8 -38
  26. package/dist/es2019/components/UserOption.js +11 -2
  27. package/dist/es2019/components/i18n.js +0 -35
  28. package/dist/esm/analytics.js +1 -1
  29. package/dist/esm/components/AddOptionAvatar.js +2 -2
  30. package/dist/esm/components/AvatarItemOption.js +44 -1
  31. package/dist/esm/components/Control.compiled.css +6 -6
  32. package/dist/esm/components/Control.js +3 -3
  33. package/dist/esm/components/GroupOption/main.js +1 -22
  34. package/dist/esm/components/Input.compiled.css +3 -3
  35. package/dist/esm/components/Input.js +1 -1
  36. package/dist/esm/components/SingleValue.compiled.css +1 -1
  37. package/dist/esm/components/SingleValue.js +1 -1
  38. package/dist/esm/components/TeamOption/main.js +8 -38
  39. package/dist/esm/components/UserOption.js +13 -2
  40. package/dist/esm/components/i18n.js +0 -35
  41. package/dist/types/components/GroupOption/main.d.ts +0 -1
  42. package/dist/types/components/TeamOption/main.d.ts +0 -1
  43. package/dist/types/components/i18n.d.ts +0 -35
  44. package/dist/types-ts4.5/components/GroupOption/main.d.ts +0 -1
  45. package/dist/types-ts4.5/components/TeamOption/main.d.ts +0 -1
  46. package/dist/types-ts4.5/components/i18n.d.ts +0 -35
  47. package/package.json +9 -6
package/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # @atlaskit/user-picker
2
2
 
3
+ ## 11.13.2
4
+
5
+ ### Patch Changes
6
+
7
+ - Updated dependencies
8
+
9
+ ## 11.13.1
10
+
11
+ ### Patch Changes
12
+
13
+ - [`ce660199aaa9a`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/ce660199aaa9a) -
14
+ [ux] Fix keyboard tab navigation between multiple user pickers in Firefox behind feature gate
15
+ 'user-dialog-tab-fix'
16
+ - Updated dependencies
17
+
3
18
  ## 11.13.0
4
19
 
5
20
  ### Minor Changes
@@ -12,7 +12,7 @@ var _utils = require("./components/utils");
12
12
  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; }
13
13
  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 @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
14
14
  var packageName = "@atlaskit/user-picker";
15
- var packageVersion = "11.12.0";
15
+ var packageVersion = "11.13.1";
16
16
  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}$/;
17
17
  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}$/;
18
18
  var UUID_REGEXP_NEW_AAID = /^[a-fA-F0-9]{24,24}$/;
@@ -19,7 +19,7 @@ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
19
19
 
20
20
  var getEmailAvatarWrapperStyle = function getEmailAvatarWrapperStyle(isLozenge, isPendingAction) {
21
21
  var padding = isLozenge ? "var(--ds-space-0, 0px)" : "var(--ds-space-050, 4px)";
22
- var backgroundColor = isPendingAction && (0, _platformFeatureFlags.fg)('twcg-444-invite-usd-improvements-m2-gate') ? "var(--ds-background-warning, #FFF7D6)" : "var(--ds-background-neutral, ".concat(_colors.N40, ")");
22
+ var backgroundColor = isPendingAction && (0, _platformFeatureFlags.fg)('twcg-444-invite-usd-improvements-m2-gate') ? "var(--ds-background-warning, #FFF5DB)" : "var(--ds-background-neutral, ".concat(_colors.N40, ")");
23
23
  return (0, _react.css)({
24
24
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
25
25
  padding: padding,
@@ -44,7 +44,7 @@ var AddOptionAvatar = exports.AddOptionAvatar = function AddOptionAvatar(_ref) {
44
44
  label: label || '',
45
45
  LEGACY_size: isLozenge ? 'small' : 'medium',
46
46
  LEGACY_margin: "0 0 0 -2px",
47
- color: isPendingAction && (0, _platformFeatureFlags.fg)('twcg-444-invite-usd-improvements-m2-gate') ? "var(--ds-text-warning, #A54800)" : "var(--ds-text-subtle, ".concat(_colors.N500, ")")
47
+ color: isPendingAction && (0, _platformFeatureFlags.fg)('twcg-444-invite-usd-improvements-m2-gate') ? "var(--ds-text-warning, #9E4C00)" : "var(--ds-text-subtle, ".concat(_colors.N500, ")")
48
48
  }))
49
49
  );
50
50
  };
@@ -11,6 +11,7 @@ var _react = _interopRequireDefault(require("react"));
11
11
  var _react2 = require("@emotion/react");
12
12
  var _lozenge = _interopRequireDefault(require("@atlaskit/lozenge"));
13
13
  var _utils = require("./utils");
14
+ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
14
15
  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; }
15
16
  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; }
16
17
  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" != (0, _typeof2.default)(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); } /**
@@ -27,6 +28,20 @@ var AsyncTooltip = /*#__PURE__*/_react.default.lazy(function () {
27
28
  });
28
29
  });
29
30
  var wrapper = function wrapper(isDisabled) {
31
+ if ((0, _platformFeatureFlags.fg)('platform_user_picker_firefox_tab_fix')) {
32
+ return (0, _react2.css)({
33
+ alignItems: 'center',
34
+ boxSizing: 'border-box',
35
+ display: 'flex',
36
+ outline: 'none',
37
+ margin: 0,
38
+ width: '100%',
39
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
40
+ cursor: isDisabled ? 'not-allowed' : 'pointer',
41
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
42
+ opacity: isDisabled ? "var(--ds-opacity-disabled, 0.4)" : undefined
43
+ });
44
+ }
30
45
  return (0, _react2.css)({
31
46
  alignItems: 'center',
32
47
  boxSizing: 'border-box',
@@ -49,10 +64,26 @@ var optionWrapper = (0, _react2.css)({
49
64
  lineHeight: '1.4',
50
65
  paddingLeft: "var(--ds-space-100, 8px)"
51
66
  });
67
+ var optionWrapperFix = (0, _react2.css)({
68
+ display: 'inline-block',
69
+ overflow: 'hidden',
70
+ minWidth: 0,
71
+ maxWidth: '100%',
72
+ paddingLeft: "var(--ds-space-100, 8px)"
73
+ });
52
74
  var getTextStyle = function getTextStyle(isSecondary) {
53
75
  var secondaryCssArgs = isSecondary ? {
54
76
  font: "var(--ds-font-body-small, normal 400 11px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, \"Helvetica Neue\", sans-serif)"
55
77
  } : {};
78
+ if ((0, _platformFeatureFlags.fg)('platform_user_picker_firefox_tab_fix')) {
79
+ return (0, _react2.css)(_objectSpread({
80
+ margin: 0,
81
+ maxWidth: '100%',
82
+ overflow: 'hidden',
83
+ textOverflow: 'ellipsis',
84
+ whiteSpace: 'nowrap'
85
+ }, secondaryCssArgs));
86
+ }
56
87
  return (0, _react2.css)(_objectSpread({
57
88
  margin: 0,
58
89
  overflowX: 'hidden',
@@ -65,6 +96,18 @@ var additionalInfo = (0, _react2.css)({
65
96
  marginLeft: "var(--ds-space-100, 8px)"
66
97
  });
67
98
  var textWrapper = exports.textWrapper = function textWrapper(color) {
99
+ if ((0, _platformFeatureFlags.fg)('platform_user_picker_firefox_tab_fix')) {
100
+ return (0, _react2.css)({
101
+ display: 'inline-block',
102
+ verticalAlign: 'bottom',
103
+ maxWidth: '100%',
104
+ overflow: 'hidden',
105
+ textOverflow: 'ellipsis',
106
+ whiteSpace: 'nowrap',
107
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
108
+ color: color
109
+ });
110
+ }
68
111
  return (0, _react2.css)({
69
112
  overflow: 'hidden',
70
113
  textOverflow: 'ellipsis',
@@ -99,7 +142,7 @@ var AvatarItemOption = exports.AvatarItemOption = function AvatarItemOption(_ref
99
142
  (0, _react2.jsx)("span", {
100
143
  css: wrapper(isDisabled)
101
144
  }, avatar, (0, _react2.jsx)("div", {
102
- css: optionWrapper
145
+ css: (0, _platformFeatureFlags.fg)('platform_user_picker_firefox_tab_fix') ? optionWrapperFix : optionWrapper
103
146
  }, (0, _react2.jsx)("div", null, (0, _react2.jsx)("div", {
104
147
  css: getTextStyle()
105
148
  }, primaryText), secondaryText && (0, _react2.jsx)("div", {
@@ -1,8 +1,8 @@
1
1
 
2
2
  ._1h6d1bqt{border-color:var(--ds-border-danger,#e2483d)}
3
- ._1h6d1elr{border-color:var(--ds-border-input,#8590a2)}
4
3
  ._1h6d1j28{border-color:transparent}
5
- ._1h6d1p6i{border-color:var(--ds-border-focused,#388bff)}._14regrf3 .fabric-user-picker__clear-indicator{opacity:0!important}
4
+ ._1h6d1v1w{border-color:var(--ds-border-focused,#4688ec)}
5
+ ._1h6drsbi{border-color:var(--ds-border-input,#8c8f97)}._14regrf3 .fabric-user-picker__clear-indicator{opacity:0!important}
6
6
  ._19bvidpf{padding-left:0}
7
7
  ._1a98zg3v:hover .fabric-user-picker__clear-indicator{opacity:1!important}
8
8
  ._1tke1wug{min-height:auto}
@@ -13,10 +13,10 @@
13
13
  ._p12f1osq{max-width:100%}
14
14
  ._u5f3idpf{padding-right:0}
15
15
  ._4cvx1bqt:hover{border-color:var(--ds-border-danger,#e2483d)}
16
- ._4cvx1elr:hover{border-color:var(--ds-border-input,#8590a2)}
17
16
  ._4cvx1j28:hover{border-color:transparent}
18
- ._4cvx1p6i:hover{border-color:var(--ds-border-focused,#388bff)}
19
- ._irr31d5g:hover{background-color:var(--ds-background-input-hovered,#f7f8f9)}
17
+ ._4cvx1v1w:hover{border-color:var(--ds-border-focused,#4688ec)}
18
+ ._4cvxrsbi:hover{border-color:var(--ds-border-input,#8c8f97)}
20
19
  ._irr31gly:hover{background-color:var(--ds-background-danger,#ffeceb)}
21
20
  ._irr31j9a:hover{background-color:var(--ds-background-input,#fff)}
22
- ._irr3syzs:hover{background-color:var(--ds-background-disabled,#091e4208)}
21
+ ._irr3by5v:hover{background-color:var(--ds-background-disabled,#17171708)}
22
+ ._irr3l4ek:hover{background-color:var(--ds-background-input-hovered,#f8f8f8)}
@@ -16,10 +16,10 @@ var _react2 = require("@compiled/react");
16
16
  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); }
17
17
  var controlStyles = {
18
18
  invalid: "_1h6d1bqt _4cvx1bqt",
19
- focused: "_1h6d1p6i _bfhk1j9a _4cvx1p6i _irr31j9a",
20
- disabled: "_irr3syzs",
19
+ focused: "_1h6d1v1w _bfhk1j9a _4cvx1v1w _irr31j9a",
20
+ disabled: "_irr3by5v",
21
21
  subtle: "_1h6d1j28 _bfhk1j28 _4cvx1j28 _irr31gly",
22
- root: "_ca0qidpf _u5f3idpf _n3tdidpf _19bvidpf _1h6d1elr _bfhk1j9a _p12f1osq _14regrf3 _4cvx1elr _irr31d5g _1a98zg3v",
22
+ root: "_ca0qidpf _u5f3idpf _n3tdidpf _19bvidpf _1h6drsbi _bfhk1j9a _p12f1osq _14regrf3 _4cvxrsbi _irr3l4ek _1a98zg3v",
23
23
  compact: "_1tke1wug"
24
24
  };
25
25
  var Control = function Control(props) {
@@ -5,7 +5,6 @@ Object.defineProperty(exports, "__esModule", {
5
5
  value: true
6
6
  });
7
7
  exports.groupOptionIconWrapper = exports.GroupOption = void 0;
8
- var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
9
8
  var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
10
9
  var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
11
10
  var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
@@ -17,8 +16,6 @@ var _reactIntlNext = require("react-intl-next");
17
16
  var _react2 = require("@emotion/react");
18
17
  var _colors = require("@atlaskit/theme/colors");
19
18
  var _peopleGroupPeople = _interopRequireDefault(require("@atlaskit/icon/core/migration/people-group--people"));
20
- var _verifiedTeamIcon = require("@atlaskit/people-teams-ui-public/verified-team-icon");
21
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
22
19
  var _AvatarItemOption = require("../AvatarItemOption");
23
20
  var _i18n = require("../i18n");
24
21
  var _HighlightText = require("../HighlightText");
@@ -70,33 +67,15 @@ var GroupOption = exports.GroupOption = /*#__PURE__*/function (_React$PureCompon
70
67
  spacing: "spacious"
71
68
  }));
72
69
  });
73
- (0, _defineProperty2.default)(_this, "renderVerifiedIcon", function () {
74
- return (0, _react2.jsx)(_verifiedTeamIcon.VerifiedTeamIcon, {
75
- label: "",
76
- size: "small",
77
- spacing: "none"
78
- });
79
- });
80
70
  (0, _defineProperty2.default)(_this, "renderByline", function () {
81
71
  var _this$props2 = _this.props,
82
72
  isSelected = _this$props2.isSelected,
83
73
  group = _this$props2.group;
84
- var getGroupByline = function getGroupByline() {
85
- if ((0, _platformFeatureFlags.fg)('confluence_frontend_perms_exp_teams_as_principals')) {
86
- return (0, _react2.jsx)(_reactIntlNext.FormattedMessage, (0, _extends2.default)({}, _i18n.messages.adminManagedGroupByline, {
87
- values: {
88
- verifiedIcon: _this.renderVerifiedIcon()
89
- }
90
- }));
91
- } else {
92
- return (0, _react2.jsx)(_reactIntlNext.FormattedMessage, _i18n.messages.groupByline);
93
- }
94
- };
95
74
  return (0, _react2.jsx)("span", {
96
75
  // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
97
76
  css: (0, _AvatarItemOption.textWrapper)(isSelected ? "var(--ds-text-selected, ".concat(_colors.B400, ")") : "var(--ds-text-subtlest, ".concat(_colors.N200, ")")),
98
77
  "data-testid": "user-picker-group-secondary-text"
99
- }, group.byline ? group.byline : getGroupByline());
78
+ }, group.byline ? group.byline : (0, _react2.jsx)(_reactIntlNext.FormattedMessage, _i18n.messages.groupByline));
100
79
  });
101
80
  (0, _defineProperty2.default)(_this, "getLozengeProps", function () {
102
81
  return typeof _this.props.group.lozenge === 'string' ? {
@@ -1,5 +1,5 @@
1
1
  ._1ir3kb7n input::-ms-input-placeholder{opacity:1}
2
2
  ._1ir3kb7n input::placeholder{opacity:1}
3
- ._5ce6131l input::-ms-input-placeholder{color:var(--ds-text-subtlest,#626f86)}
4
- ._5ce6131l input::placeholder{color:var(--ds-text-subtlest,#626f86)}
5
- ._h5gq131l input:-ms-input-placeholder{color:var(--ds-text-subtlest,#626f86)}
3
+ ._5ce61rpy input::-ms-input-placeholder{color:var(--ds-text-subtlest,#6b6e76)}
4
+ ._5ce61rpy input::placeholder{color:var(--ds-text-subtlest,#6b6e76)}
5
+ ._h5gq1rpy input:-ms-input-placeholder{color:var(--ds-text-subtlest,#6b6e76)}
@@ -20,7 +20,7 @@ var _select = require("@atlaskit/select");
20
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)); }
21
21
  function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
22
22
  var inputStyles = {
23
- root: "_5ce6131l _1ir3kb7n _h5gq131l"
23
+ root: "_5ce61rpy _1ir3kb7n _h5gq1rpy"
24
24
  };
25
25
  var Input = exports.Input = /*#__PURE__*/function (_React$Component) {
26
26
  function Input() {
@@ -10,5 +10,5 @@
10
10
  ._i0dl1osq{flex-basis:100%}
11
11
  ._o5721q9c{white-space:nowrap}
12
12
  ._p12f1osq{max-width:100%}
13
- ._syaz1fxt{color:var(--ds-text,#172b4d)}
13
+ ._syazi7uo{color:var(--ds-text,#292a2e)}
14
14
  ._vwz419ii{line-height:1.4}
@@ -18,7 +18,7 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
18
18
  var styles = {
19
19
  avatarItem: "_1reo15vq _18m915vq _4cvr1h6o _1ul953f4",
20
20
  avatarItemTextWrapper: "_16jlkb7n _1o9zkb7n _i0dl1osq _1ul9idpf _p12f1osq _bozgu2gc _vwz419ii",
21
- avatarItemText: "_syaz1fxt _1reo15vq _1bto1l2s _o5721q9c"
21
+ avatarItemText: "_syazi7uo _1reo15vq _1bto1l2s _o5721q9c"
22
22
  };
23
23
  var ElementAfter = function ElementAfter(props) {
24
24
  var data = props.data.data;
@@ -15,7 +15,6 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
15
15
  var _colors = require("@atlaskit/theme/colors");
16
16
  var _compiled = require("@atlaskit/primitives/compiled");
17
17
  var _verifiedTeamIcon = require("@atlaskit/people-teams-ui-public/verified-team-icon");
18
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
19
18
  var _react = require("@emotion/react");
20
19
  var _react2 = _interopRequireDefault(require("react"));
21
20
  var _reactIntlNext = require("react-intl-next");
@@ -39,7 +38,8 @@ var TeamOption = exports.TeamOption = /*#__PURE__*/function (_React$PureComponen
39
38
  (0, _defineProperty2.default)(_this, "getPrimaryText", function () {
40
39
  var _this$props$team = _this.props.team,
41
40
  name = _this$props$team.name,
42
- highlight = _this$props$team.highlight;
41
+ highlight = _this$props$team.highlight,
42
+ verified = _this$props$team.verified;
43
43
  return [(0, _react.jsx)("span", {
44
44
  key: "name"
45
45
  // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
@@ -49,16 +49,14 @@ var TeamOption = exports.TeamOption = /*#__PURE__*/function (_React$PureComponen
49
49
  alignBlock: "center"
50
50
  }, (0, _react.jsx)(_HighlightText.HighlightText, {
51
51
  highlights: highlight && highlight.name
52
- }, name), !(0, _platformFeatureFlags.fg)('confluence_frontend_perms_exp_teams_as_principals') && _this.renderVerifiedIcon()))];
52
+ }, name), verified && (0, _react.jsx)(_verifiedTeamIcon.VerifiedTeamIcon, null)))];
53
53
  });
54
54
  (0, _defineProperty2.default)(_this, "renderByline", function () {
55
55
  var _this$props = _this.props,
56
56
  isSelected = _this$props.isSelected,
57
57
  _this$props$team2 = _this$props.team,
58
58
  memberCount = _this$props$team2.memberCount,
59
- includesYou = _this$props$team2.includesYou,
60
- verified = _this$props$team2.verified;
61
- var isVerified = (0, _platformFeatureFlags.fg)('confluence_frontend_perms_exp_teams_as_principals') && verified;
59
+ includesYou = _this$props$team2.includesYou;
62
60
 
63
61
  // if Member count is missing, do not show the byline, regardless of the availability of includesYou
64
62
  if (memberCount === null || typeof memberCount === 'undefined') {
@@ -66,18 +64,9 @@ var TeamOption = exports.TeamOption = /*#__PURE__*/function (_React$PureComponen
66
64
  } else {
67
65
  if (includesYou === true) {
68
66
  if (memberCount > 50) {
69
- return _this.getBylineComponent(isSelected, isVerified ? (0, _react.jsx)(_reactIntlNext.FormattedMessage, (0, _extends2.default)({}, _i18n.messages.officialPlus50MembersWithYou, {
70
- values: {
71
- verifiedIcon: _this.renderVerifiedIcon()
72
- }
73
- })) : (0, _react.jsx)(_reactIntlNext.FormattedMessage, _i18n.messages.plus50MembersWithYou));
67
+ return _this.getBylineComponent(isSelected, (0, _react.jsx)(_reactIntlNext.FormattedMessage, _i18n.messages.plus50MembersWithYou));
74
68
  } else {
75
- return _this.getBylineComponent(isSelected, isVerified ? (0, _react.jsx)(_reactIntlNext.FormattedMessage, (0, _extends2.default)({}, _i18n.messages.officialMemberCountWithYou, {
76
- values: {
77
- verifiedIcon: _this.renderVerifiedIcon(),
78
- count: memberCount
79
- }
80
- })) : (0, _react.jsx)(_reactIntlNext.FormattedMessage, (0, _extends2.default)({}, _i18n.messages.memberCountWithYou, {
69
+ return _this.getBylineComponent(isSelected, (0, _react.jsx)(_reactIntlNext.FormattedMessage, (0, _extends2.default)({}, _i18n.messages.memberCountWithYou, {
81
70
  values: {
82
71
  count: memberCount
83
72
  }
@@ -85,18 +74,9 @@ var TeamOption = exports.TeamOption = /*#__PURE__*/function (_React$PureComponen
85
74
  }
86
75
  } else {
87
76
  if (memberCount > 50) {
88
- return _this.getBylineComponent(isSelected, isVerified ? (0, _react.jsx)(_reactIntlNext.FormattedMessage, (0, _extends2.default)({}, _i18n.messages.officialPlus50MembersWithoutYou, {
89
- values: {
90
- verifiedIcon: _this.renderVerifiedIcon()
91
- }
92
- })) : (0, _react.jsx)(_reactIntlNext.FormattedMessage, _i18n.messages.plus50MembersWithoutYou));
77
+ return _this.getBylineComponent(isSelected, (0, _react.jsx)(_reactIntlNext.FormattedMessage, _i18n.messages.plus50MembersWithoutYou));
93
78
  } else {
94
- return _this.getBylineComponent(isSelected, isVerified ? (0, _react.jsx)(_reactIntlNext.FormattedMessage, (0, _extends2.default)({}, _i18n.messages.officialMemberCountWithoutYou, {
95
- values: {
96
- verifiedIcon: _this.renderVerifiedIcon(),
97
- count: memberCount
98
- }
99
- })) : (0, _react.jsx)(_reactIntlNext.FormattedMessage, (0, _extends2.default)({}, _i18n.messages.memberCountWithoutYou, {
79
+ return _this.getBylineComponent(isSelected, (0, _react.jsx)(_reactIntlNext.FormattedMessage, (0, _extends2.default)({}, _i18n.messages.memberCountWithoutYou, {
100
80
  values: {
101
81
  count: memberCount
102
82
  }
@@ -120,16 +100,6 @@ var TeamOption = exports.TeamOption = /*#__PURE__*/function (_React$PureComponen
120
100
  type: "team"
121
101
  });
122
102
  });
123
- (0, _defineProperty2.default)(_this, "renderVerifiedIcon", function () {
124
- if (_this.props.team.verified) {
125
- return (0, _react.jsx)(_verifiedTeamIcon.VerifiedTeamIcon, {
126
- label: "",
127
- size: "small",
128
- spacing: "none"
129
- });
130
- }
131
- return undefined;
132
- });
133
103
  (0, _defineProperty2.default)(_this, "getLozengeProps", function () {
134
104
  return typeof _this.props.team.lozenge === 'string' ? {
135
105
  text: _this.props.team.lozenge
@@ -25,6 +25,16 @@ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.
25
25
  * @jsxRuntime classic
26
26
  * @jsx jsx
27
27
  */ // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
28
+ var styles = function styles(color) {
29
+ return (0, _react.css)({
30
+ display: 'inline',
31
+ verticalAlign: 'top',
32
+ overflow: 'hidden',
33
+ whiteSpace: 'nowrap',
34
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values
35
+ color: color
36
+ });
37
+ };
28
38
  var UserOption = exports.UserOption = /*#__PURE__*/function (_React$PureComponent) {
29
39
  function UserOption() {
30
40
  var _this;
@@ -47,11 +57,12 @@ var UserOption = exports.UserOption = /*#__PURE__*/function (_React$PureComponen
47
57
  highlights: highlight && highlight.name
48
58
  }, name))];
49
59
  if ((0, _utils.hasValue)(publicName) && name.trim() !== publicName.trim()) {
60
+ var color = _this.props.isSelected ? "var(--ds-text-selected, ".concat(_colors.B400, ")") : "var(--ds-text-subtlest, ".concat(_colors.N200, ")");
50
61
  result.push((0, _react.jsx)(_react2.default.Fragment, {
51
62
  key: "publicName"
52
63
  }, ' ', (0, _react.jsx)("span", {
53
64
  // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
54
- css: (0, _AvatarItemOption.textWrapper)(_this.props.isSelected ? "var(--ds-text-selected, ".concat(_colors.B400, ")") : "var(--ds-text-subtlest, ".concat(_colors.N200, ")"))
65
+ css: (0, _platformFeatureFlags.fg)('platform_user_picker_firefox_tab_fix') ? styles(color) : (0, _AvatarItemOption.textWrapper)(color)
55
66
  }, "(", (0, _react.jsx)(_HighlightText.HighlightText, {
56
67
  highlights: highlight && highlight.publicName
57
68
  }, publicName), ")")));
@@ -31,26 +31,6 @@ var messages = exports.messages = (0, _reactIntlNext.defineMessages)({
31
31
  defaultMessage: 'Something went wrong',
32
32
  description: 'Error message to display when options fail to load.'
33
33
  },
34
- teamByline: {
35
- id: 'fabric.elements.user-picker.team.byline',
36
- defaultMessage: 'Team',
37
- description: 'Byline for team'
38
- },
39
- officialTeamByline: {
40
- id: 'fabric.elements.user-picker.team.byline.official',
41
- defaultMessage: 'Official team {verifiedIcon}',
42
- description: 'Byline for official team'
43
- },
44
- officialMemberCountWithoutYou: {
45
- id: 'fabric.elements.user-picker.team.member.count.official',
46
- defaultMessage: 'Official team {verifiedIcon} • {count} {count, plural, one {member} other {members}}',
47
- description: 'Byline to show the number of members in the team when the current user is not a member of the team'
48
- },
49
- officialMemberCountWithYou: {
50
- id: 'fabric.elements.user-picker.team.member.count.official.including.you',
51
- defaultMessage: 'Official team {verifiedIcon} • {count} {count, plural, one {member} other {members}}, including you',
52
- description: 'Byline to show the number of members in the team when the current user is also a member of the team'
53
- },
54
34
  memberCountWithoutYou: {
55
35
  id: 'fabric.elements.user-picker.team.member.count',
56
36
  defaultMessage: 'Team • {count} {count, plural, one {member} other {members}}',
@@ -61,16 +41,6 @@ var messages = exports.messages = (0, _reactIntlNext.defineMessages)({
61
41
  defaultMessage: 'Team • {count} {count, plural, one {member} other {members}}, including you',
62
42
  description: 'Byline to show the number of members in the team when the current user is also a member of the team'
63
43
  },
64
- officialPlus50MembersWithoutYou: {
65
- id: 'fabric.elements.user-picker.team.member.50plus.official',
66
- defaultMessage: 'Official team {verifiedIcon} • 50+ members',
67
- description: 'Byline to show the number of members in the team when the number exceeds 50'
68
- },
69
- officialPlus50MembersWithYou: {
70
- id: 'fabric.elements.user-picker.team.member.50plus.official.including.you',
71
- defaultMessage: 'Official team {verifiedIcon} • 50+ members, including you',
72
- description: 'Byline to show the number of members in the team when the number exceeds 50 and also includes the current user'
73
- },
74
44
  plus50MembersWithoutYou: {
75
45
  id: 'fabric.elements.user-picker.team.member.50plus',
76
46
  defaultMessage: 'Team • 50+ members',
@@ -96,11 +66,6 @@ var messages = exports.messages = (0, _reactIntlNext.defineMessages)({
96
66
  defaultMessage: 'Enter an email address',
97
67
  description: 'Byline for a potentially valid email option.'
98
68
  },
99
- adminManagedGroupByline: {
100
- id: 'fabric.elements.user-picker.group.byline.admin-managed',
101
- defaultMessage: 'Admin group {verifiedIcon}',
102
- description: 'Byline for admin-managed groups with verified icon'
103
- },
104
69
  groupByline: {
105
70
  id: 'fabric.elements.user-picker.group.byline',
106
71
  defaultMessage: 'Admin-managed group',
@@ -3,7 +3,7 @@ import { createAndFireEvent } from '@atlaskit/analytics-next';
3
3
  import { v4 as uuidv4 } from 'uuid';
4
4
  import { isCustom, isExternalUser } from './components/utils';
5
5
  const packageName = "@atlaskit/user-picker";
6
- const packageVersion = "11.12.0";
6
+ const packageVersion = "11.13.1";
7
7
  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}$/;
8
8
  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}$/;
9
9
  const UUID_REGEXP_NEW_AAID = /^[a-fA-F0-9]{24,24}$/;
@@ -10,7 +10,7 @@ import React from 'react';
10
10
  import { fg } from '@atlaskit/platform-feature-flags';
11
11
  const getEmailAvatarWrapperStyle = (isLozenge, isPendingAction) => {
12
12
  const padding = isLozenge ? `${"var(--ds-space-0, 0px)"}` : `${"var(--ds-space-050, 4px)"}`;
13
- const backgroundColor = isPendingAction && fg('twcg-444-invite-usd-improvements-m2-gate') ? "var(--ds-background-warning, #FFF7D6)" : `var(--ds-background-neutral, ${N40})`;
13
+ const backgroundColor = isPendingAction && fg('twcg-444-invite-usd-improvements-m2-gate') ? "var(--ds-background-warning, #FFF5DB)" : `var(--ds-background-neutral, ${N40})`;
14
14
  return css({
15
15
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
16
16
  padding,
@@ -36,7 +36,7 @@ export const AddOptionAvatar = ({
36
36
  label: label || '',
37
37
  LEGACY_size: isLozenge ? 'small' : 'medium',
38
38
  LEGACY_margin: "0 0 0 -2px",
39
- color: isPendingAction && fg('twcg-444-invite-usd-improvements-m2-gate') ? "var(--ds-text-warning, #A54800)" : `var(--ds-text-subtle, ${N500})`
39
+ color: isPendingAction && fg('twcg-444-invite-usd-improvements-m2-gate') ? "var(--ds-text-warning, #9E4C00)" : `var(--ds-text-subtle, ${N500})`
40
40
  }))
41
41
  );
42
42
  };
@@ -7,25 +7,42 @@ import React from 'react';
7
7
  import { css, jsx } from '@emotion/react';
8
8
  import Lozenge from '@atlaskit/lozenge';
9
9
  import { isLozengeText } from './utils';
10
+ import { fg } from '@atlaskit/platform-feature-flags';
10
11
  const AsyncTooltip = /*#__PURE__*/React.lazy(() => import( /* webpackChunkName: "@atlaskit-internal_@atlaskit/tooltip" */'@atlaskit/tooltip').then(module => {
11
12
  return {
12
13
  default: module.default
13
14
  };
14
15
  }));
15
- const wrapper = isDisabled => css({
16
- alignItems: 'center',
17
- boxSizing: 'border-box',
18
- display: 'flex',
19
- // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
20
- lineHeight: 1,
21
- outline: 'none',
22
- margin: 0,
23
- width: '100%',
24
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
25
- cursor: isDisabled ? 'not-allowed' : 'pointer',
26
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
27
- opacity: isDisabled ? "var(--ds-opacity-disabled, 0.4)" : undefined
28
- });
16
+ const wrapper = isDisabled => {
17
+ if (fg('platform_user_picker_firefox_tab_fix')) {
18
+ return css({
19
+ alignItems: 'center',
20
+ boxSizing: 'border-box',
21
+ display: 'flex',
22
+ outline: 'none',
23
+ margin: 0,
24
+ width: '100%',
25
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
26
+ cursor: isDisabled ? 'not-allowed' : 'pointer',
27
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
28
+ opacity: isDisabled ? "var(--ds-opacity-disabled, 0.4)" : undefined
29
+ });
30
+ }
31
+ return css({
32
+ alignItems: 'center',
33
+ boxSizing: 'border-box',
34
+ display: 'flex',
35
+ // eslint-disable-next-line @atlaskit/design-system/use-tokens-typography
36
+ lineHeight: 1,
37
+ outline: 'none',
38
+ margin: 0,
39
+ width: '100%',
40
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
41
+ cursor: isDisabled ? 'not-allowed' : 'pointer',
42
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
43
+ opacity: isDisabled ? "var(--ds-opacity-disabled, 0.4)" : undefined
44
+ });
45
+ };
29
46
  const optionWrapper = css({
30
47
  maxWidth: '100%',
31
48
  minWidth: 0,
@@ -33,10 +50,28 @@ const optionWrapper = css({
33
50
  lineHeight: '1.4',
34
51
  paddingLeft: "var(--ds-space-100, 8px)"
35
52
  });
53
+ const optionWrapperFix = css({
54
+ display: 'inline-block',
55
+ overflow: 'hidden',
56
+ minWidth: 0,
57
+ maxWidth: '100%',
58
+ paddingLeft: "var(--ds-space-100, 8px)"
59
+ });
36
60
  const getTextStyle = isSecondary => {
37
61
  const secondaryCssArgs = isSecondary ? {
38
62
  font: "var(--ds-font-body-small, normal 400 11px/16px ui-sans-serif, -apple-system, BlinkMacSystemFont, \"Segoe UI\", Ubuntu, \"Helvetica Neue\", sans-serif)"
39
63
  } : {};
64
+ if (fg('platform_user_picker_firefox_tab_fix')) {
65
+ return css({
66
+ margin: 0,
67
+ maxWidth: '100%',
68
+ overflow: 'hidden',
69
+ textOverflow: 'ellipsis',
70
+ whiteSpace: 'nowrap',
71
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
72
+ ...secondaryCssArgs
73
+ });
74
+ }
40
75
  return css({
41
76
  margin: 0,
42
77
  overflowX: 'hidden',
@@ -50,13 +85,27 @@ const additionalInfo = css({
50
85
  float: 'right',
51
86
  marginLeft: "var(--ds-space-100, 8px)"
52
87
  });
53
- export const textWrapper = color => css({
54
- overflow: 'hidden',
55
- textOverflow: 'ellipsis',
56
- display: 'inline',
57
- // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
58
- color
59
- });
88
+ export const textWrapper = color => {
89
+ if (fg('platform_user_picker_firefox_tab_fix')) {
90
+ return css({
91
+ display: 'inline-block',
92
+ verticalAlign: 'bottom',
93
+ maxWidth: '100%',
94
+ overflow: 'hidden',
95
+ textOverflow: 'ellipsis',
96
+ whiteSpace: 'nowrap',
97
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
98
+ color
99
+ });
100
+ }
101
+ return css({
102
+ overflow: 'hidden',
103
+ textOverflow: 'ellipsis',
104
+ display: 'inline',
105
+ // eslint-disable-next-line @atlaskit/ui-styling-standard/no-unsafe-values -- Ignored via go/DSP-18766
106
+ color
107
+ });
108
+ };
60
109
  export const AvatarItemOption = ({
61
110
  avatar,
62
111
  isDisabled,
@@ -84,7 +133,7 @@ export const AvatarItemOption = ({
84
133
  jsx("span", {
85
134
  css: wrapper(isDisabled)
86
135
  }, avatar, jsx("div", {
87
- css: optionWrapper
136
+ css: fg('platform_user_picker_firefox_tab_fix') ? optionWrapperFix : optionWrapper
88
137
  }, jsx("div", null, jsx("div", {
89
138
  css: getTextStyle()
90
139
  }, primaryText), secondaryText && jsx("div", {
@@ -1,8 +1,8 @@
1
1
 
2
2
  ._1h6d1bqt{border-color:var(--ds-border-danger,#e2483d)}
3
- ._1h6d1elr{border-color:var(--ds-border-input,#8590a2)}
4
3
  ._1h6d1j28{border-color:transparent}
5
- ._1h6d1p6i{border-color:var(--ds-border-focused,#388bff)}._14regrf3 .fabric-user-picker__clear-indicator{opacity:0!important}
4
+ ._1h6d1v1w{border-color:var(--ds-border-focused,#4688ec)}
5
+ ._1h6drsbi{border-color:var(--ds-border-input,#8c8f97)}._14regrf3 .fabric-user-picker__clear-indicator{opacity:0!important}
6
6
  ._19bvidpf{padding-left:0}
7
7
  ._1a98zg3v:hover .fabric-user-picker__clear-indicator{opacity:1!important}
8
8
  ._1tke1wug{min-height:auto}
@@ -13,10 +13,10 @@
13
13
  ._p12f1osq{max-width:100%}
14
14
  ._u5f3idpf{padding-right:0}
15
15
  ._4cvx1bqt:hover{border-color:var(--ds-border-danger,#e2483d)}
16
- ._4cvx1elr:hover{border-color:var(--ds-border-input,#8590a2)}
17
16
  ._4cvx1j28:hover{border-color:transparent}
18
- ._4cvx1p6i:hover{border-color:var(--ds-border-focused,#388bff)}
19
- ._irr31d5g:hover{background-color:var(--ds-background-input-hovered,#f7f8f9)}
17
+ ._4cvx1v1w:hover{border-color:var(--ds-border-focused,#4688ec)}
18
+ ._4cvxrsbi:hover{border-color:var(--ds-border-input,#8c8f97)}
20
19
  ._irr31gly:hover{background-color:var(--ds-background-danger,#ffeceb)}
21
20
  ._irr31j9a:hover{background-color:var(--ds-background-input,#fff)}
22
- ._irr3syzs:hover{background-color:var(--ds-background-disabled,#091e4208)}
21
+ ._irr3by5v:hover{background-color:var(--ds-background-disabled,#17171708)}
22
+ ._irr3l4ek:hover{background-color:var(--ds-background-input-hovered,#f8f8f8)}