@atlaskit/smart-user-picker 11.8.1 → 11.9.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.
- package/CHANGELOG.md +7 -0
- package/dist/cjs/components/SmartUserPicker.js +8 -8
- package/dist/cjs/index.js +17 -11
- package/dist/cjs/packageVersion.js +1 -1
- package/dist/cjs/service/default-value-hydration-client.js +2 -2
- package/dist/cjs/service/recommendation-client.js +1 -1
- package/dist/cjs/service/users-transformer.js +1 -1
- package/dist/cjs/ufoExperiences.js +1 -1
- package/dist/es2019/components/SmartUserPicker.js +8 -8
- package/dist/es2019/index.js +8 -5
- package/dist/es2019/option.js +1 -0
- package/dist/es2019/packageVersion.js +1 -1
- package/dist/es2019/service/default-value-hydration-client.js +2 -2
- package/dist/es2019/service/recommendation-client.js +1 -1
- package/dist/es2019/service/users-transformer.js +1 -1
- package/dist/es2019/ufoExperiences.js +1 -1
- package/dist/es2019/userPicker.js +1 -0
- package/dist/esm/components/SmartUserPicker.js +8 -8
- package/dist/esm/index.js +8 -5
- package/dist/esm/option.js +1 -0
- package/dist/esm/packageVersion.js +1 -1
- package/dist/esm/service/default-value-hydration-client.js +2 -2
- package/dist/esm/service/recommendation-client.js +1 -1
- package/dist/esm/service/users-transformer.js +1 -1
- package/dist/esm/ufoExperiences.js +1 -1
- package/dist/esm/userPicker.js +1 -0
- package/dist/types/components/SmartUserPicker.d.ts +1 -1
- package/dist/types/index.d.ts +9 -2
- package/dist/types/service/recommendation-client.d.ts +1 -1
- package/dist/types/service/users-transformer.d.ts +1 -1
- package/package.json +10 -7
- package/afm-cc/tsconfig.json +0 -38
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,12 @@
|
|
|
1
1
|
# @atlassian/smart-user-picker
|
|
2
2
|
|
|
3
|
+
## 11.9.0
|
|
4
|
+
|
|
5
|
+
### Minor Changes
|
|
6
|
+
|
|
7
|
+
- [`69cbbe9ee0f63`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/69cbbe9ee0f63) -
|
|
8
|
+
Update i18n NPM package versions for linking-platform,smart-experiences (Group 15)
|
|
9
|
+
|
|
3
10
|
## 11.8.1
|
|
4
11
|
|
|
5
12
|
### Patch Changes
|
|
@@ -19,18 +19,18 @@ var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits
|
|
|
19
19
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
20
20
|
var _react = _interopRequireDefault(require("react"));
|
|
21
21
|
var _debounce = _interopRequireDefault(require("lodash/debounce"));
|
|
22
|
-
var _uuid = require("uuid");
|
|
23
|
-
var _withAnalyticsEvents = _interopRequireDefault(require("@atlaskit/analytics-next/withAnalyticsEvents"));
|
|
24
22
|
var _memoizeOne = _interopRequireDefault(require("memoize-one"));
|
|
25
23
|
var _reactIntl = require("react-intl");
|
|
24
|
+
var _uuid = require("uuid");
|
|
25
|
+
var _withAnalyticsEvents = _interopRequireDefault(require("@atlaskit/analytics-next/withAnalyticsEvents"));
|
|
26
|
+
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
26
27
|
var _experienceState = require("@atlaskit/ufo/experience-state");
|
|
28
|
+
var _emailValidation = require("@atlaskit/user-picker/components/email-validation");
|
|
27
29
|
var _userPicker = require("@atlaskit/user-picker/components/user-picker");
|
|
28
30
|
var _isExternalUser = require("@atlaskit/user-picker/is-external-user");
|
|
29
|
-
var _isTeam = require("@atlaskit/user-picker/is-team");
|
|
30
31
|
var _isGroup = require("@atlaskit/user-picker/is-group");
|
|
32
|
+
var _isTeam = require("@atlaskit/user-picker/is-team");
|
|
31
33
|
var _isUser = require("@atlaskit/user-picker/is-user");
|
|
32
|
-
var _emailValidation = require("@atlaskit/user-picker/components/email-validation");
|
|
33
|
-
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
34
34
|
var _analytics = require("../analytics");
|
|
35
35
|
var _failedRequestUsersEvent = require("../failedRequestUsersEvent");
|
|
36
36
|
var _failedUserResolversEvent = require("../failedUserResolversEvent");
|
|
@@ -38,12 +38,12 @@ var _filterUsersEvent = require("../filterUsersEvent");
|
|
|
38
38
|
var _mountedWithPrefetchEvent = require("../mountedWithPrefetchEvent");
|
|
39
39
|
var _preparedUsersLoadedEvent = require("../preparedUsersLoadedEvent");
|
|
40
40
|
var _requestUsersEvent = require("../requestUsersEvent");
|
|
41
|
+
var _defaultValueHydrationClient = _interopRequireDefault(require("../service/default-value-hydration-client"));
|
|
42
|
+
var _recommendationClient = _interopRequireDefault(require("../service/recommendation-client"));
|
|
41
43
|
var _successfulRequestUsersEvent = require("../successfulRequestUsersEvent");
|
|
42
|
-
var _MessagesIntlProvider = _interopRequireDefault(require("./MessagesIntlProvider"));
|
|
43
44
|
var _types = require("../types");
|
|
44
|
-
var _recommendationClient = _interopRequireDefault(require("../service/recommendation-client"));
|
|
45
|
-
var _defaultValueHydrationClient = _interopRequireDefault(require("../service/default-value-hydration-client"));
|
|
46
45
|
var _ufoExperiences = require("../ufoExperiences");
|
|
46
|
+
var _MessagesIntlProvider = _interopRequireDefault(require("./MessagesIntlProvider"));
|
|
47
47
|
var _excluded = ["allowEmail", "enableEmailSearch", "allowEmailSelectionWhenEmailMatched", "suggestEmailsForDomain"];
|
|
48
48
|
function _createForOfIteratorHelper(r, e) { var t = "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"]; if (!t) { if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && "number" == typeof r.length) { t && (r = t); var _n = 0, F = function F() {}; return { s: F, n: function n() { return _n >= r.length ? { done: !0 } : { done: !1, value: r[_n++] }; }, e: function e(r) { throw r; }, f: F }; } throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); } var o, a = !0, u = !1; return { s: function s() { t = t.call(r); }, n: function n() { var r = t.next(); return a = r.done, r; }, e: function e(r) { u = !0, o = r; }, f: function f() { try { a || null == t.return || t.return(); } finally { if (u) throw o; } } }; }
|
|
49
49
|
function _unsupportedIterableToArray(r, a) { if (r) { if ("string" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return "Object" === t && r.constructor && (t = r.constructor.name), "Map" === t || "Set" === t ? Array.from(r) : "Arguments" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }
|
package/dist/cjs/index.js
CHANGED
|
@@ -7,25 +7,25 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
Object.defineProperty(exports, "EmailType", {
|
|
8
8
|
enumerable: true,
|
|
9
9
|
get: function get() {
|
|
10
|
-
return
|
|
10
|
+
return _types.EmailType;
|
|
11
11
|
}
|
|
12
12
|
});
|
|
13
13
|
Object.defineProperty(exports, "GroupType", {
|
|
14
14
|
enumerable: true,
|
|
15
15
|
get: function get() {
|
|
16
|
-
return
|
|
16
|
+
return _types.GroupType;
|
|
17
17
|
}
|
|
18
18
|
});
|
|
19
19
|
Object.defineProperty(exports, "TeamType", {
|
|
20
20
|
enumerable: true,
|
|
21
21
|
get: function get() {
|
|
22
|
-
return
|
|
22
|
+
return _types.TeamType;
|
|
23
23
|
}
|
|
24
24
|
});
|
|
25
25
|
Object.defineProperty(exports, "UserType", {
|
|
26
26
|
enumerable: true,
|
|
27
27
|
get: function get() {
|
|
28
|
-
return
|
|
28
|
+
return _types.UserType;
|
|
29
29
|
}
|
|
30
30
|
});
|
|
31
31
|
Object.defineProperty(exports, "default", {
|
|
@@ -49,40 +49,46 @@ Object.defineProperty(exports, "hydrateDefaultValues", {
|
|
|
49
49
|
Object.defineProperty(exports, "isEmail", {
|
|
50
50
|
enumerable: true,
|
|
51
51
|
get: function get() {
|
|
52
|
-
return
|
|
52
|
+
return _isEmail.isEmail;
|
|
53
53
|
}
|
|
54
54
|
});
|
|
55
55
|
Object.defineProperty(exports, "isExternalUser", {
|
|
56
56
|
enumerable: true,
|
|
57
57
|
get: function get() {
|
|
58
|
-
return
|
|
58
|
+
return _isExternalUser.isExternalUser;
|
|
59
59
|
}
|
|
60
60
|
});
|
|
61
61
|
Object.defineProperty(exports, "isGroup", {
|
|
62
62
|
enumerable: true,
|
|
63
63
|
get: function get() {
|
|
64
|
-
return
|
|
64
|
+
return _isGroup.isGroup;
|
|
65
65
|
}
|
|
66
66
|
});
|
|
67
67
|
Object.defineProperty(exports, "isTeam", {
|
|
68
68
|
enumerable: true,
|
|
69
69
|
get: function get() {
|
|
70
|
-
return
|
|
70
|
+
return _isTeam.isTeam;
|
|
71
71
|
}
|
|
72
72
|
});
|
|
73
73
|
Object.defineProperty(exports, "isUser", {
|
|
74
74
|
enumerable: true,
|
|
75
75
|
get: function get() {
|
|
76
|
-
return
|
|
76
|
+
return _isUser.isUser;
|
|
77
77
|
}
|
|
78
78
|
});
|
|
79
79
|
Object.defineProperty(exports, "isValidEmail", {
|
|
80
80
|
enumerable: true,
|
|
81
81
|
get: function get() {
|
|
82
|
-
return
|
|
82
|
+
return _emailValidation.isValidEmail;
|
|
83
83
|
}
|
|
84
84
|
});
|
|
85
85
|
var _components = _interopRequireDefault(require("./components"));
|
|
86
86
|
var _recommendationClient = _interopRequireDefault(require("./service/recommendation-client"));
|
|
87
87
|
var _defaultValueHydrationClient = _interopRequireDefault(require("./service/default-value-hydration-client"));
|
|
88
|
-
var
|
|
88
|
+
var _isEmail = require("@atlaskit/user-picker/is-email");
|
|
89
|
+
var _isTeam = require("@atlaskit/user-picker/is-team");
|
|
90
|
+
var _isUser = require("@atlaskit/user-picker/is-user");
|
|
91
|
+
var _isExternalUser = require("@atlaskit/user-picker/is-external-user");
|
|
92
|
+
var _emailValidation = require("@atlaskit/user-picker/components/email-validation");
|
|
93
|
+
var _isGroup = require("@atlaskit/user-picker/is-group");
|
|
94
|
+
var _types = require("@atlaskit/user-picker/types");
|
|
@@ -11,9 +11,9 @@ var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/de
|
|
|
11
11
|
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
12
12
|
var _types = require("@atlaskit/user-picker/types");
|
|
13
13
|
var _config = require("../config");
|
|
14
|
-
var _usersClient = _interopRequireDefault(require("./users-client"));
|
|
15
|
-
var _teamsClient = _interopRequireDefault(require("./teams-client"));
|
|
16
14
|
var _constants = require("./constants");
|
|
15
|
+
var _teamsClient = _interopRequireDefault(require("./teams-client"));
|
|
16
|
+
var _usersClient = _interopRequireDefault(require("./users-client"));
|
|
17
17
|
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; }
|
|
18
18
|
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; }
|
|
19
19
|
var getHydratedUsersFromProducts = function getHydratedUsersFromProducts(request) {
|
|
@@ -6,8 +6,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.default = void 0;
|
|
8
8
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
9
|
-
var _usersTransformer = require("./users-transformer");
|
|
10
9
|
var _config = require("../config");
|
|
10
|
+
var _usersTransformer = require("./users-transformer");
|
|
11
11
|
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; }
|
|
12
12
|
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; }
|
|
13
13
|
var getUserRecommendations = function getUserRecommendations(request, intl) {
|
|
@@ -4,10 +4,10 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.transformUsers = void 0;
|
|
7
|
+
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
7
8
|
var _types = require("@atlaskit/user-picker/types");
|
|
8
9
|
var _i18n = require("../i18n");
|
|
9
10
|
var _types2 = require("../types");
|
|
10
|
-
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
11
11
|
var getLozenzeProperties = function getLozenzeProperties(entity, intl) {
|
|
12
12
|
var _entity$attributes, _entity$attributes2, _entity$attributes3;
|
|
13
13
|
if ((_entity$attributes = entity.attributes) !== null && _entity$attributes !== void 0 && _entity$attributes.workspaceMember) {
|
|
@@ -4,8 +4,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.smartUserPickerRenderedUfoExperience = exports.smartUserPickerOptionsShownUfoExperience = void 0;
|
|
7
|
-
var _experienceTypes = require("@atlaskit/ufo/experience-types");
|
|
8
7
|
var _concurrentExperience = require("@atlaskit/ufo/concurrent-experience");
|
|
8
|
+
var _experienceTypes = require("@atlaskit/ufo/experience-types");
|
|
9
9
|
var COMPONENT_NAME = 'smart-user-picker';
|
|
10
10
|
var smartUserPickerRenderedUfoExperience = exports.smartUserPickerRenderedUfoExperience = new _concurrentExperience.ConcurrentExperience('smart-user-picker-rendered', {
|
|
11
11
|
platform: {
|
|
@@ -2,19 +2,19 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
import React from 'react';
|
|
4
4
|
import debounce from 'lodash/debounce';
|
|
5
|
+
import memoizeOne from 'memoize-one';
|
|
6
|
+
import { injectIntl } from 'react-intl';
|
|
5
7
|
// eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
|
|
6
8
|
import { v4 as uuidV4 } from 'uuid';
|
|
7
9
|
import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
|
|
8
|
-
import
|
|
9
|
-
import { injectIntl } from 'react-intl';
|
|
10
|
+
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
10
11
|
import { UFOExperienceState } from '@atlaskit/ufo/experience-state';
|
|
12
|
+
import { isValidEmail } from '@atlaskit/user-picker/components/email-validation';
|
|
11
13
|
import { UserPicker } from '@atlaskit/user-picker/components/user-picker';
|
|
12
14
|
import { isExternalUser } from '@atlaskit/user-picker/is-external-user';
|
|
13
|
-
import { isTeam } from '@atlaskit/user-picker/is-team';
|
|
14
15
|
import { isGroup } from '@atlaskit/user-picker/is-group';
|
|
16
|
+
import { isTeam } from '@atlaskit/user-picker/is-team';
|
|
15
17
|
import { isUser } from '@atlaskit/user-picker/is-user';
|
|
16
|
-
import { isValidEmail } from '@atlaskit/user-picker/components/email-validation';
|
|
17
|
-
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
18
18
|
import { createAndFireEventInElementsChannel } from '../analytics';
|
|
19
19
|
import { failedRequestUsersEvent } from '../failedRequestUsersEvent';
|
|
20
20
|
import { failedUserResolversEvent } from '../failedUserResolversEvent';
|
|
@@ -22,12 +22,12 @@ import { filterUsersEvent } from '../filterUsersEvent';
|
|
|
22
22
|
import { mountedWithPrefetchEvent } from '../mountedWithPrefetchEvent';
|
|
23
23
|
import { preparedUsersLoadedEvent } from '../preparedUsersLoadedEvent';
|
|
24
24
|
import { requestUsersEvent } from '../requestUsersEvent';
|
|
25
|
+
import hydrateDefaultValues from '../service/default-value-hydration-client';
|
|
26
|
+
import getUserRecommendations from '../service/recommendation-client';
|
|
25
27
|
import { successfulRequestUsersEvent } from '../successfulRequestUsersEvent';
|
|
26
|
-
import MessagesIntlProvider from './MessagesIntlProvider';
|
|
27
28
|
import { UserEntityType } from '../types';
|
|
28
|
-
import getUserRecommendations from '../service/recommendation-client';
|
|
29
|
-
import hydrateDefaultValues from '../service/default-value-hydration-client';
|
|
30
29
|
import { smartUserPickerOptionsShownUfoExperience } from '../ufoExperiences';
|
|
30
|
+
import MessagesIntlProvider from './MessagesIntlProvider';
|
|
31
31
|
const DEFAULT_DEBOUNCE_TIME_MS = 150;
|
|
32
32
|
const ufoEndStateConfig = fieldId => {
|
|
33
33
|
return {
|
package/dist/es2019/index.js
CHANGED
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
/* eslint-disable @repo/internal/deprecations/deprecation-ticket-required, @atlaskit/volt-strict-mode/no-re-exports, @atlaskit/editor/no-re-export -- VOLTC-139 tracks removal of these deprecated re-export shims. */
|
|
2
|
+
|
|
2
3
|
export { default } from './components';
|
|
3
4
|
export { default as getUserRecommendations } from './service/recommendation-client';
|
|
4
5
|
export { default as hydrateDefaultValues } from './service/default-value-hydration-client';
|
|
5
|
-
export {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
export { isEmail } from '@atlaskit/user-picker/is-email';
|
|
7
|
+
export { isTeam } from '@atlaskit/user-picker/is-team';
|
|
8
|
+
export { isUser } from '@atlaskit/user-picker/is-user';
|
|
9
|
+
export { isExternalUser } from '@atlaskit/user-picker/is-external-user';
|
|
10
|
+
export { isValidEmail } from '@atlaskit/user-picker/components/email-validation';
|
|
11
|
+
export { isGroup } from '@atlaskit/user-picker/is-group';
|
|
12
|
+
export { EmailType, GroupType, TeamType, UserType } from '@atlaskit/user-picker/types';
|
package/dist/es2019/option.js
CHANGED
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
/* eslint-disable @repo/internal/deprecations/deprecation-ticket-required, @atlaskit/volt-strict-mode/no-re-exports, @atlaskit/editor/no-re-export -- VOLTC-139 tracks removal of these deprecated re-export shims. */
|
|
2
|
+
|
|
2
3
|
export { Option, CustomOption, EmailOption, GroupOption, UserOption, TeamOption } from '@atlaskit/user-picker/option';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export const packageVersion = "11.8.
|
|
1
|
+
export const packageVersion = "11.8.1";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { UserType } from '@atlaskit/user-picker/types';
|
|
2
2
|
import { config } from '../config';
|
|
3
|
-
import getHydratedUsersFromPrs from './users-client';
|
|
4
|
-
import hydrateTeamFromLegion from './teams-client';
|
|
5
3
|
import { UNKNOWN } from './constants';
|
|
4
|
+
import hydrateTeamFromLegion from './teams-client';
|
|
5
|
+
import getHydratedUsersFromPrs from './users-client';
|
|
6
6
|
const getHydratedUsersFromProducts = request => {
|
|
7
7
|
const url = `${config.getUsersServiceUrl(request.productKey, request.baseUrl)}`;
|
|
8
8
|
let params = new URLSearchParams();
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { transformUsers } from './users-transformer';
|
|
2
1
|
import { config } from '../config';
|
|
2
|
+
import { transformUsers } from './users-transformer';
|
|
3
3
|
const getUserRecommendations = (request, intl) => {
|
|
4
4
|
var _request$context, _request$context$prod;
|
|
5
5
|
const url = config.getRecommendationServiceUrl(request.baseUrl || '');
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
+
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
1
2
|
import { ExternalUserType, GroupType, TeamType, UserType } from '@atlaskit/user-picker/types';
|
|
2
3
|
import { messages } from '../i18n';
|
|
3
4
|
import { EntityType } from '../types';
|
|
4
|
-
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
5
5
|
const getLozenzeProperties = (entity, intl) => {
|
|
6
6
|
var _entity$attributes, _entity$attributes2, _entity$attributes3;
|
|
7
7
|
if ((_entity$attributes = entity.attributes) !== null && _entity$attributes !== void 0 && _entity$attributes.workspaceMember) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ExperiencePerformanceTypes, ExperienceTypes } from '@atlaskit/ufo/experience-types';
|
|
2
1
|
import { ConcurrentExperience } from '@atlaskit/ufo/concurrent-experience';
|
|
2
|
+
import { ExperiencePerformanceTypes, ExperienceTypes } from '@atlaskit/ufo/experience-types';
|
|
3
3
|
const COMPONENT_NAME = 'smart-user-picker';
|
|
4
4
|
export const smartUserPickerRenderedUfoExperience = new ConcurrentExperience('smart-user-picker-rendered', {
|
|
5
5
|
platform: {
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/* eslint-disable @repo/internal/deprecations/deprecation-ticket-required, @atlaskit/volt-strict-mode/no-re-exports, @atlaskit/editor/no-re-export -- VOLTC-139 tracks removal of these deprecated re-export shims. */
|
|
2
|
+
|
|
2
3
|
export {
|
|
3
4
|
//Utils
|
|
4
5
|
isEmail, isTeam, isUser, isExternalUser, isValidEmail, isGroup,
|
|
@@ -20,19 +20,19 @@ function _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstruct
|
|
|
20
20
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
21
21
|
import React from 'react';
|
|
22
22
|
import debounce from 'lodash/debounce';
|
|
23
|
+
import memoizeOne from 'memoize-one';
|
|
24
|
+
import { injectIntl } from 'react-intl';
|
|
23
25
|
// eslint-disable-next-line @atlaskit/platform/prefer-crypto-random-uuid -- Use crypto.randomUUID instead
|
|
24
26
|
import { v4 as uuidV4 } from 'uuid';
|
|
25
27
|
import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
|
|
26
|
-
import
|
|
27
|
-
import { injectIntl } from 'react-intl';
|
|
28
|
+
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
28
29
|
import { UFOExperienceState } from '@atlaskit/ufo/experience-state';
|
|
30
|
+
import { isValidEmail } from '@atlaskit/user-picker/components/email-validation';
|
|
29
31
|
import { UserPicker } from '@atlaskit/user-picker/components/user-picker';
|
|
30
32
|
import { isExternalUser } from '@atlaskit/user-picker/is-external-user';
|
|
31
|
-
import { isTeam } from '@atlaskit/user-picker/is-team';
|
|
32
33
|
import { isGroup } from '@atlaskit/user-picker/is-group';
|
|
34
|
+
import { isTeam } from '@atlaskit/user-picker/is-team';
|
|
33
35
|
import { isUser } from '@atlaskit/user-picker/is-user';
|
|
34
|
-
import { isValidEmail } from '@atlaskit/user-picker/components/email-validation';
|
|
35
|
-
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
36
36
|
import { createAndFireEventInElementsChannel } from '../analytics';
|
|
37
37
|
import { failedRequestUsersEvent } from '../failedRequestUsersEvent';
|
|
38
38
|
import { failedUserResolversEvent } from '../failedUserResolversEvent';
|
|
@@ -40,12 +40,12 @@ import { filterUsersEvent } from '../filterUsersEvent';
|
|
|
40
40
|
import { mountedWithPrefetchEvent } from '../mountedWithPrefetchEvent';
|
|
41
41
|
import { preparedUsersLoadedEvent } from '../preparedUsersLoadedEvent';
|
|
42
42
|
import { requestUsersEvent } from '../requestUsersEvent';
|
|
43
|
+
import hydrateDefaultValues from '../service/default-value-hydration-client';
|
|
44
|
+
import getUserRecommendations from '../service/recommendation-client';
|
|
43
45
|
import { successfulRequestUsersEvent } from '../successfulRequestUsersEvent';
|
|
44
|
-
import MessagesIntlProvider from './MessagesIntlProvider';
|
|
45
46
|
import { UserEntityType } from '../types';
|
|
46
|
-
import getUserRecommendations from '../service/recommendation-client';
|
|
47
|
-
import hydrateDefaultValues from '../service/default-value-hydration-client';
|
|
48
47
|
import { smartUserPickerOptionsShownUfoExperience } from '../ufoExperiences';
|
|
48
|
+
import MessagesIntlProvider from './MessagesIntlProvider';
|
|
49
49
|
var DEFAULT_DEBOUNCE_TIME_MS = 150;
|
|
50
50
|
var ufoEndStateConfig = function ufoEndStateConfig(fieldId) {
|
|
51
51
|
return {
|
package/dist/esm/index.js
CHANGED
|
@@ -1,9 +1,12 @@
|
|
|
1
1
|
/* eslint-disable @repo/internal/deprecations/deprecation-ticket-required, @atlaskit/volt-strict-mode/no-re-exports, @atlaskit/editor/no-re-export -- VOLTC-139 tracks removal of these deprecated re-export shims. */
|
|
2
|
+
|
|
2
3
|
export { default } from './components';
|
|
3
4
|
export { default as getUserRecommendations } from './service/recommendation-client';
|
|
4
5
|
export { default as hydrateDefaultValues } from './service/default-value-hydration-client';
|
|
5
|
-
export {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
export { isEmail } from '@atlaskit/user-picker/is-email';
|
|
7
|
+
export { isTeam } from '@atlaskit/user-picker/is-team';
|
|
8
|
+
export { isUser } from '@atlaskit/user-picker/is-user';
|
|
9
|
+
export { isExternalUser } from '@atlaskit/user-picker/is-external-user';
|
|
10
|
+
export { isValidEmail } from '@atlaskit/user-picker/components/email-validation';
|
|
11
|
+
export { isGroup } from '@atlaskit/user-picker/is-group';
|
|
12
|
+
export { EmailType, GroupType, TeamType, UserType } from '@atlaskit/user-picker/types';
|
package/dist/esm/option.js
CHANGED
|
@@ -1,2 +1,3 @@
|
|
|
1
1
|
/* eslint-disable @repo/internal/deprecations/deprecation-ticket-required, @atlaskit/volt-strict-mode/no-re-exports, @atlaskit/editor/no-re-export -- VOLTC-139 tracks removal of these deprecated re-export shims. */
|
|
2
|
+
|
|
2
3
|
export { Option, CustomOption, EmailOption, GroupOption, UserOption, TeamOption } from '@atlaskit/user-picker/option';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export var packageVersion = "11.8.
|
|
1
|
+
export var packageVersion = "11.8.1";
|
|
@@ -6,9 +6,9 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
|
|
|
6
6
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
7
7
|
import { UserType } from '@atlaskit/user-picker/types';
|
|
8
8
|
import { config } from '../config';
|
|
9
|
-
import getHydratedUsersFromPrs from './users-client';
|
|
10
|
-
import hydrateTeamFromLegion from './teams-client';
|
|
11
9
|
import { UNKNOWN } from './constants';
|
|
10
|
+
import hydrateTeamFromLegion from './teams-client';
|
|
11
|
+
import getHydratedUsersFromPrs from './users-client';
|
|
12
12
|
var getHydratedUsersFromProducts = function getHydratedUsersFromProducts(request) {
|
|
13
13
|
var url = "".concat(config.getUsersServiceUrl(request.productKey, request.baseUrl));
|
|
14
14
|
var params = new URLSearchParams();
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
2
|
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; }
|
|
3
3
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
4
|
-
import { transformUsers } from './users-transformer';
|
|
5
4
|
import { config } from '../config';
|
|
5
|
+
import { transformUsers } from './users-transformer';
|
|
6
6
|
var getUserRecommendations = function getUserRecommendations(request, intl) {
|
|
7
7
|
var _request$context;
|
|
8
8
|
var url = config.getRecommendationServiceUrl(request.baseUrl || '');
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
+
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
1
2
|
import { ExternalUserType, GroupType, TeamType, UserType } from '@atlaskit/user-picker/types';
|
|
2
3
|
import { messages } from '../i18n';
|
|
3
4
|
import { EntityType } from '../types';
|
|
4
|
-
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
5
5
|
var getLozenzeProperties = function getLozenzeProperties(entity, intl) {
|
|
6
6
|
var _entity$attributes, _entity$attributes2, _entity$attributes3;
|
|
7
7
|
if ((_entity$attributes = entity.attributes) !== null && _entity$attributes !== void 0 && _entity$attributes.workspaceMember) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ExperiencePerformanceTypes, ExperienceTypes } from '@atlaskit/ufo/experience-types';
|
|
2
1
|
import { ConcurrentExperience } from '@atlaskit/ufo/concurrent-experience';
|
|
2
|
+
import { ExperiencePerformanceTypes, ExperienceTypes } from '@atlaskit/ufo/experience-types';
|
|
3
3
|
var COMPONENT_NAME = 'smart-user-picker';
|
|
4
4
|
export var smartUserPickerRenderedUfoExperience = new ConcurrentExperience('smart-user-picker-rendered', {
|
|
5
5
|
platform: {
|
package/dist/esm/userPicker.js
CHANGED
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
/* eslint-disable @repo/internal/deprecations/deprecation-ticket-required, @atlaskit/volt-strict-mode/no-re-exports, @atlaskit/editor/no-re-export -- VOLTC-139 tracks removal of these deprecated re-export shims. */
|
|
2
|
+
|
|
2
3
|
export {
|
|
3
4
|
//Utils
|
|
4
5
|
isEmail, isTeam, isUser, isExternalUser, isValidEmail, isGroup,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import type { DebouncedFunc } from 'lodash';
|
|
2
3
|
import { type MemoizedFn } from 'memoize-one';
|
|
3
4
|
import { type WrappedComponentProps } from 'react-intl';
|
|
4
5
|
import type { UFOExperience } from '@atlaskit/ufo/experience';
|
|
5
6
|
import type { OptionData } from '@atlaskit/user-picker/types';
|
|
6
7
|
import { type Props, type State, type FilterOptions } from '../types';
|
|
7
|
-
import type { DebouncedFunc } from 'lodash';
|
|
8
8
|
export declare class SmartUserPickerWithoutAnalytics extends React.Component<Props & WrappedComponentProps, State> {
|
|
9
9
|
state: State;
|
|
10
10
|
private lastEmailSearchFoundMatches;
|
package/dist/types/index.d.ts
CHANGED
|
@@ -2,5 +2,12 @@ export { default } from './components';
|
|
|
2
2
|
export { default as getUserRecommendations } from './service/recommendation-client';
|
|
3
3
|
export { default as hydrateDefaultValues } from './service/default-value-hydration-client';
|
|
4
4
|
export type { RecommendationRequest, Props, State, RestrictionFilter } from './types';
|
|
5
|
-
export { isEmail
|
|
6
|
-
export
|
|
5
|
+
export { isEmail } from '@atlaskit/user-picker/is-email';
|
|
6
|
+
export { isTeam } from '@atlaskit/user-picker/is-team';
|
|
7
|
+
export { isUser } from '@atlaskit/user-picker/is-user';
|
|
8
|
+
export { isExternalUser } from '@atlaskit/user-picker/is-external-user';
|
|
9
|
+
export { isValidEmail } from '@atlaskit/user-picker/components/email-validation';
|
|
10
|
+
export { isGroup } from '@atlaskit/user-picker/is-group';
|
|
11
|
+
export { EmailType, GroupType, TeamType, UserType } from '@atlaskit/user-picker/types';
|
|
12
|
+
export type { ActionTypes, Appearance, AtlasKitSelectChange, AtlaskitSelectValue, DefaultValue, InputActionTypes, LozengeProps, OnChange, OnInputChange, OnOption, OnPicker, Option, OptionData, OptionIdentifier, PopupUserPickerProps, Promisable, Target, UserPickerProps, UserPickerState, Value, Email, Group, GroupHighlight, HighlightRange, LoadOptions, Team, TeamHighlight, TeamMember, User, UserHighlight, ExternalUser, UserSource, } from '@atlaskit/user-picker/types';
|
|
13
|
+
export type { EmailValidationResponse, EmailValidator, } from '@atlaskit/user-picker/components/email-validation';
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { type IntlShape } from 'react-intl';
|
|
1
2
|
import type { OptionData } from '@atlaskit/user-picker/types';
|
|
2
3
|
import { type RecommendationRequest } from '../types';
|
|
3
|
-
import { type IntlShape } from 'react-intl';
|
|
4
4
|
export interface SUPError extends Error {
|
|
5
5
|
message: string;
|
|
6
6
|
statusCode: number;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/smart-user-picker",
|
|
3
|
-
"version": "11.
|
|
3
|
+
"version": "11.9.0",
|
|
4
4
|
"license": "Apache-2.0",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -15,6 +15,11 @@
|
|
|
15
15
|
"sideEffects": false,
|
|
16
16
|
"atlaskit:src": "src/index.ts",
|
|
17
17
|
"atlassian": {
|
|
18
|
+
"website": {
|
|
19
|
+
"tags": [
|
|
20
|
+
"platform-labs"
|
|
21
|
+
]
|
|
22
|
+
},
|
|
18
23
|
"team": "Search Platform: Search Experience",
|
|
19
24
|
"slack": {
|
|
20
25
|
"channel": "#search-plex-prs",
|
|
@@ -26,11 +31,11 @@
|
|
|
26
31
|
}
|
|
27
32
|
},
|
|
28
33
|
"dependencies": {
|
|
29
|
-
"@atlaskit/afm-i18n-platform-smart-experiences-smart-user-picker": "2.
|
|
34
|
+
"@atlaskit/afm-i18n-platform-smart-experiences-smart-user-picker": "2.259.0",
|
|
30
35
|
"@atlaskit/analytics-next": "^12.5.0",
|
|
31
36
|
"@atlaskit/platform-feature-flags": "^2.2.0",
|
|
32
37
|
"@atlaskit/ufo": "^1.2.0",
|
|
33
|
-
"@atlaskit/user-picker": "^13.
|
|
38
|
+
"@atlaskit/user-picker": "^13.13.0",
|
|
34
39
|
"@babel/runtime": "^7.0.0",
|
|
35
40
|
"lodash": "^4.17.21",
|
|
36
41
|
"memoize-one": "^6.0.0",
|
|
@@ -42,19 +47,17 @@
|
|
|
42
47
|
"react-intl": "^5.25.1 || ^6.0.0 || ^7.0.0"
|
|
43
48
|
},
|
|
44
49
|
"devDependencies": {
|
|
45
|
-
"@atlaskit/button": "^25.
|
|
50
|
+
"@atlaskit/button": "^25.4.0",
|
|
46
51
|
"@atlaskit/select": "^22.11.0",
|
|
47
52
|
"@atlaskit/textfield": "^10.2.0",
|
|
48
53
|
"@atlaskit/util-data-test": "^19.1.0",
|
|
49
54
|
"@atlassian/a11y-jest-testing": "^0.17.0",
|
|
50
55
|
"@atlassian/feature-flags-test-utils": "^1.3.0",
|
|
51
|
-
"@atlassian/integrations": "^33.
|
|
56
|
+
"@atlassian/integrations": "^33.13.0",
|
|
52
57
|
"@atlassian/workbench": "workspace:*",
|
|
53
58
|
"@testing-library/dom": "^10.1.0",
|
|
54
59
|
"@testing-library/react": "^16.3.0",
|
|
55
60
|
"@testing-library/user-event": "^14.4.3",
|
|
56
|
-
"@types/enzyme": "3.1.15",
|
|
57
|
-
"enzyme": "^3.10.0",
|
|
58
61
|
"fetch-mock": "^8.0.0",
|
|
59
62
|
"graphql-tag": "^2.10.1",
|
|
60
63
|
"mock-apollo-client": "^0.1.0",
|
package/afm-cc/tsconfig.json
DELETED
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
{
|
|
2
|
-
"extends": "../../../../tsconfig.local-consumption.json",
|
|
3
|
-
"compilerOptions": {
|
|
4
|
-
"outDir": "../../../../../confluence/tsDist/@atlaskit__smart-user-picker",
|
|
5
|
-
"rootDir": "../",
|
|
6
|
-
"composite": true,
|
|
7
|
-
"noCheck": true
|
|
8
|
-
},
|
|
9
|
-
"include": [
|
|
10
|
-
"../src/**/*.ts",
|
|
11
|
-
"../src/**/*.tsx"
|
|
12
|
-
],
|
|
13
|
-
"exclude": [
|
|
14
|
-
"../src/**/__tests__/*",
|
|
15
|
-
"../src/**/*.test.*",
|
|
16
|
-
"../src/**/test.*",
|
|
17
|
-
"../src/**/examples.*",
|
|
18
|
-
"../src/**/examples/*",
|
|
19
|
-
"../src/**/examples/**/*",
|
|
20
|
-
"../src/**/*.stories.*",
|
|
21
|
-
"../src/**/stories/*",
|
|
22
|
-
"../src/**/stories/**/*"
|
|
23
|
-
],
|
|
24
|
-
"references": [
|
|
25
|
-
{
|
|
26
|
-
"path": "../../../analytics/analytics-next/afm-cc/tsconfig.json"
|
|
27
|
-
},
|
|
28
|
-
{
|
|
29
|
-
"path": "../../../platform/feature-flags/afm-cc/tsconfig.json"
|
|
30
|
-
},
|
|
31
|
-
{
|
|
32
|
-
"path": "../../../data/ufo-external/afm-cc/tsconfig.json"
|
|
33
|
-
},
|
|
34
|
-
{
|
|
35
|
-
"path": "../../../elements/user-picker/afm-cc/tsconfig.json"
|
|
36
|
-
}
|
|
37
|
-
]
|
|
38
|
-
}
|