@atlaskit/smart-user-picker 6.0.7 → 6.1.1

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 (127) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/dist/cjs/components/SmartUserPicker.js +173 -177
  3. package/dist/cjs/i18n/cs.js +9 -9
  4. package/dist/cjs/i18n/da.js +9 -9
  5. package/dist/cjs/i18n/de.js +9 -9
  6. package/dist/cjs/i18n/en.js +9 -9
  7. package/dist/cjs/i18n/en_GB.js +9 -9
  8. package/dist/cjs/i18n/en_ZZ.js +9 -9
  9. package/dist/cjs/i18n/es.js +9 -9
  10. package/dist/cjs/i18n/fi.js +9 -9
  11. package/dist/cjs/i18n/fr.js +9 -9
  12. package/dist/cjs/i18n/hu.js +9 -9
  13. package/dist/cjs/i18n/it.js +9 -9
  14. package/dist/cjs/i18n/ja.js +9 -9
  15. package/dist/cjs/i18n/ko.js +9 -9
  16. package/dist/cjs/i18n/nb.js +9 -9
  17. package/dist/cjs/i18n/nl.js +9 -9
  18. package/dist/cjs/i18n/pl.js +9 -9
  19. package/dist/cjs/i18n/pt_BR.js +9 -9
  20. package/dist/cjs/i18n/ru.js +9 -9
  21. package/dist/cjs/i18n/sv.js +9 -9
  22. package/dist/cjs/i18n/th.js +9 -9
  23. package/dist/cjs/i18n/tr.js +9 -9
  24. package/dist/cjs/i18n/uk.js +9 -9
  25. package/dist/cjs/i18n/vi.js +9 -9
  26. package/dist/cjs/i18n/zh.js +9 -9
  27. package/dist/cjs/i18n/zh_TW.js +9 -9
  28. package/dist/cjs/service/default-value-hydration-client.js +91 -97
  29. package/dist/cjs/service/users-client.js +10 -12
  30. package/dist/cjs/service/users-transformer.js +3 -3
  31. package/dist/cjs/types.js +4 -4
  32. package/dist/cjs/util/i18n-util.js +194 -196
  33. package/dist/cjs/version.json +1 -1
  34. package/dist/es2019/i18n/cs.js +9 -9
  35. package/dist/es2019/i18n/da.js +9 -9
  36. package/dist/es2019/i18n/de.js +9 -9
  37. package/dist/es2019/i18n/en.js +9 -9
  38. package/dist/es2019/i18n/en_GB.js +9 -9
  39. package/dist/es2019/i18n/en_ZZ.js +9 -9
  40. package/dist/es2019/i18n/es.js +9 -9
  41. package/dist/es2019/i18n/fi.js +9 -9
  42. package/dist/es2019/i18n/fr.js +9 -9
  43. package/dist/es2019/i18n/hu.js +9 -9
  44. package/dist/es2019/i18n/it.js +9 -9
  45. package/dist/es2019/i18n/ja.js +9 -9
  46. package/dist/es2019/i18n/ko.js +9 -9
  47. package/dist/es2019/i18n/nb.js +9 -9
  48. package/dist/es2019/i18n/nl.js +9 -9
  49. package/dist/es2019/i18n/pl.js +9 -9
  50. package/dist/es2019/i18n/pt_BR.js +9 -9
  51. package/dist/es2019/i18n/ru.js +9 -9
  52. package/dist/es2019/i18n/sv.js +9 -9
  53. package/dist/es2019/i18n/th.js +9 -9
  54. package/dist/es2019/i18n/tr.js +9 -9
  55. package/dist/es2019/i18n/uk.js +9 -9
  56. package/dist/es2019/i18n/vi.js +9 -9
  57. package/dist/es2019/i18n/zh.js +9 -9
  58. package/dist/es2019/i18n/zh_TW.js +9 -9
  59. package/dist/es2019/service/users-transformer.js +3 -3
  60. package/dist/es2019/types.js +5 -3
  61. package/dist/es2019/version.json +1 -1
  62. package/dist/esm/components/SmartUserPicker.js +173 -177
  63. package/dist/esm/i18n/cs.js +9 -9
  64. package/dist/esm/i18n/da.js +9 -9
  65. package/dist/esm/i18n/de.js +9 -9
  66. package/dist/esm/i18n/en.js +9 -9
  67. package/dist/esm/i18n/en_GB.js +9 -9
  68. package/dist/esm/i18n/en_ZZ.js +9 -9
  69. package/dist/esm/i18n/es.js +9 -9
  70. package/dist/esm/i18n/fi.js +9 -9
  71. package/dist/esm/i18n/fr.js +9 -9
  72. package/dist/esm/i18n/hu.js +9 -9
  73. package/dist/esm/i18n/it.js +9 -9
  74. package/dist/esm/i18n/ja.js +9 -9
  75. package/dist/esm/i18n/ko.js +9 -9
  76. package/dist/esm/i18n/nb.js +9 -9
  77. package/dist/esm/i18n/nl.js +9 -9
  78. package/dist/esm/i18n/pl.js +9 -9
  79. package/dist/esm/i18n/pt_BR.js +9 -9
  80. package/dist/esm/i18n/ru.js +9 -9
  81. package/dist/esm/i18n/sv.js +9 -9
  82. package/dist/esm/i18n/th.js +9 -9
  83. package/dist/esm/i18n/tr.js +9 -9
  84. package/dist/esm/i18n/uk.js +9 -9
  85. package/dist/esm/i18n/vi.js +9 -9
  86. package/dist/esm/i18n/zh.js +9 -9
  87. package/dist/esm/i18n/zh_TW.js +9 -9
  88. package/dist/esm/service/default-value-hydration-client.js +91 -97
  89. package/dist/esm/service/users-client.js +10 -12
  90. package/dist/esm/service/users-transformer.js +3 -3
  91. package/dist/esm/types.js +5 -3
  92. package/dist/esm/util/i18n-util.js +134 -136
  93. package/dist/esm/version.json +1 -1
  94. package/dist/types/analytics.d.ts +1 -1
  95. package/dist/types/components/SmartUserPicker.d.ts +5 -5
  96. package/dist/types/config/index.d.ts +2 -2
  97. package/dist/types/i18n/cs.d.ts +11 -11
  98. package/dist/types/i18n/da.d.ts +11 -11
  99. package/dist/types/i18n/de.d.ts +11 -11
  100. package/dist/types/i18n/en.d.ts +11 -11
  101. package/dist/types/i18n/en_GB.d.ts +11 -11
  102. package/dist/types/i18n/en_ZZ.d.ts +11 -11
  103. package/dist/types/i18n/es.d.ts +11 -11
  104. package/dist/types/i18n/et.d.ts +1 -1
  105. package/dist/types/i18n/fi.d.ts +11 -11
  106. package/dist/types/i18n/fr.d.ts +11 -11
  107. package/dist/types/i18n/hu.d.ts +11 -11
  108. package/dist/types/i18n/it.d.ts +11 -11
  109. package/dist/types/i18n/ja.d.ts +11 -11
  110. package/dist/types/i18n/ko.d.ts +11 -11
  111. package/dist/types/i18n/nb.d.ts +11 -11
  112. package/dist/types/i18n/nl.d.ts +11 -11
  113. package/dist/types/i18n/pl.d.ts +11 -11
  114. package/dist/types/i18n/pt_BR.d.ts +11 -11
  115. package/dist/types/i18n/pt_PT.d.ts +1 -1
  116. package/dist/types/i18n/ru.d.ts +11 -11
  117. package/dist/types/i18n/sk.d.ts +1 -1
  118. package/dist/types/i18n/sv.d.ts +11 -11
  119. package/dist/types/i18n/th.d.ts +11 -11
  120. package/dist/types/i18n/tr.d.ts +11 -11
  121. package/dist/types/i18n/uk.d.ts +11 -11
  122. package/dist/types/i18n/vi.d.ts +11 -11
  123. package/dist/types/i18n/zh.d.ts +11 -11
  124. package/dist/types/i18n/zh_TW.d.ts +11 -11
  125. package/dist/types/service/teams-client.d.ts +2 -2
  126. package/dist/types/types.d.ts +5 -5
  127. package/package.json +20 -12
@@ -89,29 +89,27 @@ var hydrateTeamIds = /*#__PURE__*/function () {
89
89
  var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(baseUrl, values) {
90
90
  var legionPromises;
91
91
  return _regeneratorRuntime.wrap(function _callee$(_context) {
92
- while (1) {
93
- switch (_context.prev = _context.next) {
94
- case 0:
95
- if (!(values.length === 0)) {
96
- _context.next = 2;
97
- break;
98
- }
99
- return _context.abrupt("return", []);
100
- case 2:
101
- legionPromises = values.map(function (value) {
102
- return hydrateTeamFromLegion({
103
- baseUrl: baseUrl,
104
- id: value.id
105
- });
92
+ while (1) switch (_context.prev = _context.next) {
93
+ case 0:
94
+ if (!(values.length === 0)) {
95
+ _context.next = 2;
96
+ break;
97
+ }
98
+ return _context.abrupt("return", []);
99
+ case 2:
100
+ legionPromises = values.map(function (value) {
101
+ return hydrateTeamFromLegion({
102
+ baseUrl: baseUrl,
103
+ id: value.id
106
104
  });
107
- _context.next = 5;
108
- return Promise.all(legionPromises);
109
- case 5:
110
- return _context.abrupt("return", _context.sent);
111
- case 6:
112
- case "end":
113
- return _context.stop();
114
- }
105
+ });
106
+ _context.next = 5;
107
+ return Promise.all(legionPromises);
108
+ case 5:
109
+ return _context.abrupt("return", _context.sent);
110
+ case 6:
111
+ case "end":
112
+ return _context.stop();
115
113
  }
116
114
  }, _callee);
117
115
  }));
@@ -123,43 +121,41 @@ var hydrateAccountIds = /*#__PURE__*/function () {
123
121
  var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee2(baseUrl, productKey, values) {
124
122
  var accountIds;
125
123
  return _regeneratorRuntime.wrap(function _callee2$(_context2) {
126
- while (1) {
127
- switch (_context2.prev = _context2.next) {
128
- case 0:
129
- if (!(values.length === 0)) {
130
- _context2.next = 2;
131
- break;
132
- }
133
- return _context2.abrupt("return", []);
134
- case 2:
135
- accountIds = values.map(function (val) {
136
- return val.id;
137
- }); //if we are not jira or confluence then use PRS platform hydration
138
- if (!(productKey === 'jira' || productKey === 'confluence')) {
139
- _context2.next = 9;
140
- break;
141
- }
142
- _context2.next = 6;
143
- return getHydratedUsersFromProducts({
144
- baseUrl: baseUrl,
145
- productKey: productKey,
146
- accountIds: accountIds
147
- });
148
- case 6:
149
- _context2.t0 = _context2.sent;
150
- _context2.next = 12;
124
+ while (1) switch (_context2.prev = _context2.next) {
125
+ case 0:
126
+ if (!(values.length === 0)) {
127
+ _context2.next = 2;
151
128
  break;
152
- case 9:
153
- _context2.next = 11;
154
- return getHydratedUsersFromPrs(baseUrl, accountIds);
155
- case 11:
156
- _context2.t0 = _context2.sent;
157
- case 12:
158
- return _context2.abrupt("return", _context2.t0);
159
- case 13:
160
- case "end":
161
- return _context2.stop();
162
- }
129
+ }
130
+ return _context2.abrupt("return", []);
131
+ case 2:
132
+ accountIds = values.map(function (val) {
133
+ return val.id;
134
+ }); //if we are not jira or confluence then use PRS platform hydration
135
+ if (!(productKey === 'jira' || productKey === 'confluence')) {
136
+ _context2.next = 9;
137
+ break;
138
+ }
139
+ _context2.next = 6;
140
+ return getHydratedUsersFromProducts({
141
+ baseUrl: baseUrl,
142
+ productKey: productKey,
143
+ accountIds: accountIds
144
+ });
145
+ case 6:
146
+ _context2.t0 = _context2.sent;
147
+ _context2.next = 12;
148
+ break;
149
+ case 9:
150
+ _context2.next = 11;
151
+ return getHydratedUsersFromPrs(baseUrl, accountIds);
152
+ case 11:
153
+ _context2.t0 = _context2.sent;
154
+ case 12:
155
+ return _context2.abrupt("return", _context2.t0);
156
+ case 13:
157
+ case "end":
158
+ return _context2.stop();
163
159
  }
164
160
  }, _callee2);
165
161
  }));
@@ -174,45 +170,43 @@ function _hydrateDefaultValues() {
174
170
  _hydrateDefaultValues = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee3(baseUrl, value, productKey) {
175
171
  var values, _yield$Promise$all, _yield$Promise$all2, hydratedUsers, hydratedTeams, hydratedOptions;
176
172
  return _regeneratorRuntime.wrap(function _callee3$(_context3) {
177
- while (1) {
178
- switch (_context3.prev = _context3.next) {
179
- case 0:
180
- if (!(!value || Array.isArray(value) && value.length === 0)) {
181
- _context3.next = 2;
182
- break;
183
- }
184
- return _context3.abrupt("return", []);
185
- case 2:
186
- values = Array.isArray(value) ? value : [value]; // return if all hydrated
187
- if (values.some(function (val) {
188
- return !isOptionData(val);
189
- })) {
190
- _context3.next = 5;
191
- break;
192
- }
193
- return _context3.abrupt("return", value);
194
- case 5:
195
- _context3.next = 7;
196
- return Promise.all([hydrateAccountIds(baseUrl, productKey, values.filter(function (val) {
197
- return !isOptionData(val) && val.type === 'user';
198
- })), hydrateTeamIds(baseUrl, values.filter(function (val) {
199
- return !isOptionData(val) && val.type === 'team';
200
- }))]);
201
- case 7:
202
- _yield$Promise$all = _context3.sent;
203
- _yield$Promise$all2 = _slicedToArray(_yield$Promise$all, 2);
204
- hydratedUsers = _yield$Promise$all2[0];
205
- hydratedTeams = _yield$Promise$all2[1];
206
- hydratedOptions = values.filter(function (val) {
207
- return isOptionData(val);
208
- }).map(function (val) {
209
- return val;
210
- }).concat(hydratedUsers).concat(hydratedTeams);
211
- return _context3.abrupt("return", sortResults(hydratedOptions, values));
212
- case 13:
213
- case "end":
214
- return _context3.stop();
215
- }
173
+ while (1) switch (_context3.prev = _context3.next) {
174
+ case 0:
175
+ if (!(!value || Array.isArray(value) && value.length === 0)) {
176
+ _context3.next = 2;
177
+ break;
178
+ }
179
+ return _context3.abrupt("return", []);
180
+ case 2:
181
+ values = Array.isArray(value) ? value : [value]; // return if all hydrated
182
+ if (values.some(function (val) {
183
+ return !isOptionData(val);
184
+ })) {
185
+ _context3.next = 5;
186
+ break;
187
+ }
188
+ return _context3.abrupt("return", value);
189
+ case 5:
190
+ _context3.next = 7;
191
+ return Promise.all([hydrateAccountIds(baseUrl, productKey, values.filter(function (val) {
192
+ return !isOptionData(val) && val.type === 'user';
193
+ })), hydrateTeamIds(baseUrl, values.filter(function (val) {
194
+ return !isOptionData(val) && val.type === 'team';
195
+ }))]);
196
+ case 7:
197
+ _yield$Promise$all = _context3.sent;
198
+ _yield$Promise$all2 = _slicedToArray(_yield$Promise$all, 2);
199
+ hydratedUsers = _yield$Promise$all2[0];
200
+ hydratedTeams = _yield$Promise$all2[1];
201
+ hydratedOptions = values.filter(function (val) {
202
+ return isOptionData(val);
203
+ }).map(function (val) {
204
+ return val;
205
+ }).concat(hydratedUsers).concat(hydratedTeams);
206
+ return _context3.abrupt("return", sortResults(hydratedOptions, values));
207
+ case 13:
208
+ case "end":
209
+ return _context3.stop();
216
210
  }
217
211
  }, _callee3);
218
212
  }));
@@ -22,18 +22,16 @@ var makeRequest = /*#__PURE__*/function () {
22
22
  var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(url, accountIds) {
23
23
  var query;
24
24
  return _regeneratorRuntime.wrap(function _callee$(_context) {
25
- while (1) {
26
- switch (_context.prev = _context.next) {
27
- case 0:
28
- query = buildUsersQuery(accountIds);
29
- _context.next = 3;
30
- return graphqlQuery(url, query);
31
- case 3:
32
- return _context.abrupt("return", _context.sent);
33
- case 4:
34
- case "end":
35
- return _context.stop();
36
- }
25
+ while (1) switch (_context.prev = _context.next) {
26
+ case 0:
27
+ query = buildUsersQuery(accountIds);
28
+ _context.next = 3;
29
+ return graphqlQuery(url, query);
30
+ case 3:
31
+ return _context.abrupt("return", _context.sent);
32
+ case 4:
33
+ case "end":
34
+ return _context.stop();
37
35
  }
38
36
  }, _callee);
39
37
  }));
@@ -1,11 +1,11 @@
1
1
  import { TeamType, UserType, GroupType } from '@atlaskit/user-picker';
2
2
  import { messages } from '../i18n';
3
- var EntityType;
4
- (function (EntityType) {
3
+ var EntityType = /*#__PURE__*/function (EntityType) {
5
4
  EntityType["USER"] = "USER";
6
5
  EntityType["TEAM"] = "TEAM";
7
6
  EntityType["GROUP"] = "GROUP";
8
- })(EntityType || (EntityType = {}));
7
+ return EntityType;
8
+ }(EntityType || {});
9
9
  var getLozenzeProperties = function getLozenzeProperties(entity, intl) {
10
10
  var _entity$attributes, _entity$attributes2;
11
11
  if ((_entity$attributes = entity.attributes) !== null && _entity$attributes !== void 0 && _entity$attributes.workspaceMember) {
package/dist/esm/types.js CHANGED
@@ -1,6 +1,8 @@
1
- export var EntityType;
2
- (function (EntityType) {
1
+ export var EntityType = /*#__PURE__*/function (EntityType) {
3
2
  EntityType["USER"] = "USER";
4
3
  EntityType["TEAM"] = "TEAM";
5
4
  EntityType["GROUP"] = "GROUP";
6
- })(EntityType || (EntityType = {}));
5
+ return EntityType;
6
+ }({});
7
+
8
+ // Override UserPickerProps below with replacement documentation
@@ -14,143 +14,141 @@ export var getMessagesForLocale = /*#__PURE__*/function () {
14
14
  var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(locale) {
15
15
  var fragments;
16
16
  return _regeneratorRuntime.wrap(function _callee$(_context) {
17
- while (1) {
18
- switch (_context.prev = _context.next) {
19
- case 0:
20
- _context.t0 = locale;
21
- _context.next = _context.t0 === 'cs' ? 3 : _context.t0 === 'da' ? 4 : _context.t0 === 'de' ? 5 : _context.t0 === 'en' ? 6 : _context.t0 === 'en_GB' ? 7 : _context.t0 === 'es' ? 8 : _context.t0 === 'et' ? 9 : _context.t0 === 'fi' ? 10 : _context.t0 === 'fr' ? 11 : _context.t0 === 'hu' ? 12 : _context.t0 === 'is' ? 13 : _context.t0 === 'it' ? 14 : _context.t0 === 'ja' ? 15 : _context.t0 === 'ko' ? 16 : _context.t0 === 'nb' ? 17 : _context.t0 === 'nl' ? 18 : _context.t0 === 'pl' ? 19 : _context.t0 === 'pt_BR' ? 20 : _context.t0 === 'pt-BR' ? 20 : _context.t0 === 'pt_PT' ? 21 : _context.t0 === 'pt-PT' ? 21 : _context.t0 === 'ro' ? 22 : _context.t0 === 'ru' ? 23 : _context.t0 === 'sk' ? 24 : _context.t0 === 'sv' ? 25 : _context.t0 === 'th' ? 26 : _context.t0 === 'tr' ? 27 : _context.t0 === 'uk' ? 28 : _context.t0 === 'vi' ? 29 : _context.t0 === 'zh_TW' ? 30 : _context.t0 === 'zh' ? 31 : 32;
17
+ while (1) switch (_context.prev = _context.next) {
18
+ case 0:
19
+ _context.t0 = locale;
20
+ _context.next = _context.t0 === 'cs' ? 3 : _context.t0 === 'da' ? 4 : _context.t0 === 'de' ? 5 : _context.t0 === 'en' ? 6 : _context.t0 === 'en_GB' ? 7 : _context.t0 === 'es' ? 8 : _context.t0 === 'et' ? 9 : _context.t0 === 'fi' ? 10 : _context.t0 === 'fr' ? 11 : _context.t0 === 'hu' ? 12 : _context.t0 === 'is' ? 13 : _context.t0 === 'it' ? 14 : _context.t0 === 'ja' ? 15 : _context.t0 === 'ko' ? 16 : _context.t0 === 'nb' ? 17 : _context.t0 === 'nl' ? 18 : _context.t0 === 'pl' ? 19 : _context.t0 === 'pt_BR' ? 20 : _context.t0 === 'pt-BR' ? 20 : _context.t0 === 'pt_PT' ? 21 : _context.t0 === 'pt-PT' ? 21 : _context.t0 === 'ro' ? 22 : _context.t0 === 'ru' ? 23 : _context.t0 === 'sk' ? 24 : _context.t0 === 'sv' ? 25 : _context.t0 === 'th' ? 26 : _context.t0 === 'tr' ? 27 : _context.t0 === 'uk' ? 28 : _context.t0 === 'vi' ? 29 : _context.t0 === 'zh_TW' ? 30 : _context.t0 === 'zh' ? 31 : 32;
21
+ break;
22
+ case 3:
23
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-cs" */'../i18n/cs').then(function (mod) {
24
+ return mod.default;
25
+ }));
26
+ case 4:
27
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-da" */'../i18n/da').then(function (mod) {
28
+ return mod.default;
29
+ }));
30
+ case 5:
31
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-de" */'../i18n/de').then(function (mod) {
32
+ return mod.default;
33
+ }));
34
+ case 6:
35
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-en" */'../i18n/en').then(function (mod) {
36
+ return mod.default;
37
+ }));
38
+ case 7:
39
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-en_GB" */'../i18n/en_GB').then(function (mod) {
40
+ return mod.default;
41
+ }));
42
+ case 8:
43
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-es" */'../i18n/es').then(function (mod) {
44
+ return mod.default;
45
+ }));
46
+ case 9:
47
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-et" */'../i18n/et').then(function (mod) {
48
+ return mod.default;
49
+ }));
50
+ case 10:
51
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-fi" */'../i18n/fi').then(function (mod) {
52
+ return mod.default;
53
+ }));
54
+ case 11:
55
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-fr" */'../i18n/fr').then(function (mod) {
56
+ return mod.default;
57
+ }));
58
+ case 12:
59
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-hu" */'../i18n/hu').then(function (mod) {
60
+ return mod.default;
61
+ }));
62
+ case 13:
63
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-is" */'../i18n/is').then(function (mod) {
64
+ return mod.default;
65
+ }));
66
+ case 14:
67
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-it" */'../i18n/it').then(function (mod) {
68
+ return mod.default;
69
+ }));
70
+ case 15:
71
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-ja" */'../i18n/ja').then(function (mod) {
72
+ return mod.default;
73
+ }));
74
+ case 16:
75
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-ko" */'../i18n/ko').then(function (mod) {
76
+ return mod.default;
77
+ }));
78
+ case 17:
79
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-nb" */'../i18n/nb').then(function (mod) {
80
+ return mod.default;
81
+ }));
82
+ case 18:
83
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-nl" */'../i18n/nl').then(function (mod) {
84
+ return mod.default;
85
+ }));
86
+ case 19:
87
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-pl" */'../i18n/pl').then(function (mod) {
88
+ return mod.default;
89
+ }));
90
+ case 20:
91
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-pt_BR" */'../i18n/pt_BR').then(function (mod) {
92
+ return mod.default;
93
+ }));
94
+ case 21:
95
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-pt_PT" */'../i18n/pt_PT').then(function (mod) {
96
+ return mod.default;
97
+ }));
98
+ case 22:
99
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-ro" */'../i18n/ro').then(function (mod) {
100
+ return mod.default;
101
+ }));
102
+ case 23:
103
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-ru" */'../i18n/ru').then(function (mod) {
104
+ return mod.default;
105
+ }));
106
+ case 24:
107
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-sk" */'../i18n/sk').then(function (mod) {
108
+ return mod.default;
109
+ }));
110
+ case 25:
111
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-sv" */'../i18n/sv').then(function (mod) {
112
+ return mod.default;
113
+ }));
114
+ case 26:
115
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-th" */'../i18n/th').then(function (mod) {
116
+ return mod.default;
117
+ }));
118
+ case 27:
119
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-tr" */'../i18n/tr').then(function (mod) {
120
+ return mod.default;
121
+ }));
122
+ case 28:
123
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-uk" */'../i18n/uk').then(function (mod) {
124
+ return mod.default;
125
+ }));
126
+ case 29:
127
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-vi" */'../i18n/vi').then(function (mod) {
128
+ return mod.default;
129
+ }));
130
+ case 30:
131
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-zh_TW" */'../i18n/zh_TW').then(function (mod) {
132
+ return mod.default;
133
+ }));
134
+ case 31:
135
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-zh" */'../i18n/zh').then(function (mod) {
136
+ return mod.default;
137
+ }));
138
+ case 32:
139
+ fragments = locale.split(/[_-]/);
140
+ if (!(fragments.length === 2)) {
141
+ _context.next = 37;
22
142
  break;
23
- case 3:
24
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-cs" */'../i18n/cs').then(function (mod) {
25
- return mod.default;
26
- }));
27
- case 4:
28
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-da" */'../i18n/da').then(function (mod) {
29
- return mod.default;
30
- }));
31
- case 5:
32
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-de" */'../i18n/de').then(function (mod) {
33
- return mod.default;
34
- }));
35
- case 6:
36
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-en" */'../i18n/en').then(function (mod) {
37
- return mod.default;
38
- }));
39
- case 7:
40
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-en_GB" */'../i18n/en_GB').then(function (mod) {
41
- return mod.default;
42
- }));
43
- case 8:
44
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-es" */'../i18n/es').then(function (mod) {
45
- return mod.default;
46
- }));
47
- case 9:
48
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-et" */'../i18n/et').then(function (mod) {
49
- return mod.default;
50
- }));
51
- case 10:
52
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-fi" */'../i18n/fi').then(function (mod) {
53
- return mod.default;
54
- }));
55
- case 11:
56
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-fr" */'../i18n/fr').then(function (mod) {
57
- return mod.default;
58
- }));
59
- case 12:
60
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-hu" */'../i18n/hu').then(function (mod) {
61
- return mod.default;
62
- }));
63
- case 13:
64
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-is" */'../i18n/is').then(function (mod) {
65
- return mod.default;
66
- }));
67
- case 14:
68
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-it" */'../i18n/it').then(function (mod) {
69
- return mod.default;
70
- }));
71
- case 15:
72
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-ja" */'../i18n/ja').then(function (mod) {
73
- return mod.default;
74
- }));
75
- case 16:
76
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-ko" */'../i18n/ko').then(function (mod) {
77
- return mod.default;
78
- }));
79
- case 17:
80
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-nb" */'../i18n/nb').then(function (mod) {
81
- return mod.default;
82
- }));
83
- case 18:
84
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-nl" */'../i18n/nl').then(function (mod) {
85
- return mod.default;
86
- }));
87
- case 19:
88
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-pl" */'../i18n/pl').then(function (mod) {
89
- return mod.default;
90
- }));
91
- case 20:
92
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-pt_BR" */'../i18n/pt_BR').then(function (mod) {
93
- return mod.default;
94
- }));
95
- case 21:
96
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-pt_PT" */'../i18n/pt_PT').then(function (mod) {
97
- return mod.default;
98
- }));
99
- case 22:
100
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-ro" */'../i18n/ro').then(function (mod) {
101
- return mod.default;
102
- }));
103
- case 23:
104
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-ru" */'../i18n/ru').then(function (mod) {
105
- return mod.default;
106
- }));
107
- case 24:
108
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-sk" */'../i18n/sk').then(function (mod) {
109
- return mod.default;
110
- }));
111
- case 25:
112
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-sv" */'../i18n/sv').then(function (mod) {
113
- return mod.default;
114
- }));
115
- case 26:
116
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-th" */'../i18n/th').then(function (mod) {
117
- return mod.default;
118
- }));
119
- case 27:
120
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-tr" */'../i18n/tr').then(function (mod) {
121
- return mod.default;
122
- }));
123
- case 28:
124
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-uk" */'../i18n/uk').then(function (mod) {
125
- return mod.default;
126
- }));
127
- case 29:
128
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-vi" */'../i18n/vi').then(function (mod) {
129
- return mod.default;
130
- }));
131
- case 30:
132
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-zh_TW" */'../i18n/zh_TW').then(function (mod) {
133
- return mod.default;
134
- }));
135
- case 31:
136
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-zh" */'../i18n/zh').then(function (mod) {
137
- return mod.default;
138
- }));
139
- case 32:
140
- fragments = locale.split(/[_-]/);
141
- if (!(fragments.length === 2)) {
142
- _context.next = 37;
143
- break;
144
- }
145
- return _context.abrupt("return", getMessagesForLocale(fragments[0]));
146
- case 37:
147
- return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-en" */'../i18n/en').then(function (mod) {
148
- return mod.default;
149
- }));
150
- case 38:
151
- case "end":
152
- return _context.stop();
153
- }
143
+ }
144
+ return _context.abrupt("return", getMessagesForLocale(fragments[0]));
145
+ case 37:
146
+ return _context.abrupt("return", import( /* webpackChunkName: "@atlaskit-internal_user-picker-i18n-en" */'../i18n/en').then(function (mod) {
147
+ return mod.default;
148
+ }));
149
+ case 38:
150
+ case "end":
151
+ return _context.stop();
154
152
  }
155
153
  }, _callee);
156
154
  }));
@@ -1,5 +1,5 @@
1
1
  {
2
2
  "name": "@atlaskit/smart-user-picker",
3
- "version": "6.0.7",
3
+ "version": "6.1.1",
4
4
  "sideEffects": false
5
5
  }
@@ -1,6 +1,6 @@
1
1
  import { AnalyticsEventPayload } from '@atlaskit/analytics-next';
2
2
  import { Props } from './types';
3
- export declare type UserPickerSession = {
3
+ export type UserPickerSession = {
4
4
  id: string;
5
5
  start: number;
6
6
  inputChangeTime: number;
@@ -22,13 +22,13 @@ export declare class SmartUserPickerWithoutAnalytics extends React.Component<Pro
22
22
  abortOptionsShownUfoExperience: () => void;
23
23
  startOptionsShownUfoExperience: () => void;
24
24
  private fireEvent;
25
- filterOptions: (users: OptionData[], query: string, propFilterOptions?: FilterOptions | undefined) => OptionData[];
26
- memoizedFilterOptions: import("memoize-one").MemoizedFn<(users: OptionData[], query: string, propFilterOptions?: FilterOptions | undefined) => OptionData[]>;
25
+ filterOptions: (users: OptionData[], query: string, propFilterOptions?: FilterOptions) => OptionData[];
26
+ memoizedFilterOptions: import("memoize-one").MemoizedFn<(users: OptionData[], query: string, propFilterOptions?: FilterOptions) => OptionData[]>;
27
27
  getUsers: import("lodash").DebouncedFunc<() => Promise<void>>;
28
- onInputChange: (newQuery?: string | undefined, sessionId?: string | undefined) => void;
28
+ onInputChange: (newQuery?: string, sessionId?: string) => void;
29
29
  filterUsers: () => OptionData[];
30
- onFocus: (sessionId?: string | undefined) => void;
31
- onBlur: (sessionId?: string | undefined) => void;
30
+ onFocus: (sessionId?: string) => void;
31
+ onBlur: (sessionId?: string) => void;
32
32
  render(): JSX.Element;
33
33
  }
34
34
  export declare const SmartUserPicker: any;
@@ -1,6 +1,6 @@
1
1
  export declare const config: {
2
2
  getRecommendationServiceUrl(baseUrl: string): string;
3
3
  getUsersServiceUrl(productKey: string, baseUrl?: string): string;
4
- getGraphQLUrl(baseUrl?: string | undefined): string;
5
- getTeamsUrl(baseUrl?: string | undefined): string;
4
+ getGraphQLUrl(baseUrl?: string): string;
5
+ getTeamsUrl(baseUrl?: string): string;
6
6
  };
@@ -1,18 +1,18 @@
1
- declare const _default: {
2
- "fabric.elements.user-picker.external.sourced.from": string;
3
- "fabric.elements.user-picker.github.provider": string;
4
- "fabric.elements.user-picker.google.provider": string;
5
- "fabric.elements.user-picker.guest.lozenge.text": string;
6
- "fabric.elements.user-picker.guest.lozenge.tooltip.group": string;
7
- "fabric.elements.user-picker.guest.lozenge.tooltip.user": string;
8
- "fabric.elements.user-picker.member.lozenge.text": string;
9
- "fabric.elements.user-picker.microsoft.provider": string;
10
- "fabric.elements.user-picker.slack.provider": string;
11
- };
12
1
  /**
13
2
  * NOTE:
14
3
  *
15
4
  * This file is automatically generated by Traduki 2.0.
16
5
  * DO NOT CHANGE IT BY HAND or your changes will be lost.
17
6
  */
7
+ declare const _default: {
8
+ 'fabric.elements.user-picker.external.sourced.from': string;
9
+ 'fabric.elements.user-picker.github.provider': string;
10
+ 'fabric.elements.user-picker.google.provider': string;
11
+ 'fabric.elements.user-picker.guest.lozenge.text': string;
12
+ 'fabric.elements.user-picker.guest.lozenge.tooltip.group': string;
13
+ 'fabric.elements.user-picker.guest.lozenge.tooltip.user': string;
14
+ 'fabric.elements.user-picker.member.lozenge.text': string;
15
+ 'fabric.elements.user-picker.microsoft.provider': string;
16
+ 'fabric.elements.user-picker.slack.provider': string;
17
+ };
18
18
  export default _default;