@atlaskit/smart-user-picker 10.0.0 → 10.0.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,20 @@
1
1
  # @atlassian/smart-user-picker
2
2
 
3
+ ## 10.0.2
4
+
5
+ ### Patch Changes
6
+
7
+ - [`a95470b46e97e`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/a95470b46e97e) -
8
+ Map `appType` field from the recommendation service response through `users-transformer` so that
9
+ agent principals correctly expose `appType` on the resulting `OptionData` object.
10
+
11
+ ## 10.0.1
12
+
13
+ ### Patch Changes
14
+
15
+ - [`9b1521c6d0e35`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/9b1521c6d0e35) -
16
+ FFCLEANUP-97327: Remove smart-user-picker-attribution-header feature gate (always-on cleanup)
17
+
3
18
  ## 10.0.0
4
19
 
5
20
  ### Major Changes
package/dist/cjs/i18n.js CHANGED
@@ -9,7 +9,7 @@ var messages = exports.messages = (0, _reactIntl.defineMessages)({
9
9
  externalUserSourcesHeading: {
10
10
  id: 'fabric.elements.user-picker.external.sourced.from',
11
11
  defaultMessage: 'Found in:',
12
- description: 'From where the external user is coming'
12
+ description: 'The text is shown as a label in the user picker dropdown preceding the list of external organizations or directories where the external user account was found (e.g. a guest directory or external workspace).'
13
13
  },
14
14
  slackProvider: {
15
15
  id: 'fabric.elements.user-picker.slack.provider',
@@ -4,15 +4,12 @@ Object.defineProperty(exports, "__esModule", {
4
4
  value: true
5
5
  });
6
6
  exports.graphqlQuery = graphqlQuery;
7
- var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
8
7
  var _atlAttribution = require("./atl-attribution");
9
8
  var buildHeaders = function buildHeaders(attributionData) {
10
9
  var headers = new Headers();
11
10
  headers.append('Content-Type', 'application/json');
12
- if ((0, _platformFeatureFlags.fg)('smart-user-picker-attribution-header')) {
13
- var atlAttributionHeader = (0, _atlAttribution.createAtlAttributionHeader)(attributionData);
14
- headers.append('atl-attribution', atlAttributionHeader['atl-attribution']);
15
- }
11
+ var atlAttributionHeader = (0, _atlAttribution.createAtlAttributionHeader)(attributionData);
12
+ headers.append('atl-attribution', atlAttributionHeader['atl-attribution']);
16
13
  return headers;
17
14
  };
18
15
  /**
@@ -30,6 +30,7 @@ var getLozenzeProperties = function getLozenzeProperties(entity, intl) {
30
30
  var transformUser = function transformUser(item, intl) {
31
31
  var type = item.entityType;
32
32
  if (type === _types.EntityType.USER) {
33
+ var _user$attributes;
33
34
  var user = item;
34
35
  var lozenge = getLozenzeProperties(user, intl);
35
36
  return {
@@ -43,7 +44,8 @@ var transformUser = function transformUser(item, intl) {
43
44
  lozenge: lozenge,
44
45
  tooltip: user.name,
45
46
  isExternal: Boolean(user.nonLicensedUser),
46
- sources: user.nonLicensedUser ? ['other-atlassian'] : undefined
47
+ sources: user.nonLicensedUser ? ['other-atlassian'] : undefined,
48
+ appType: user.appType !== undefined ? user.appType : (_user$attributes = user.attributes) === null || _user$attributes === void 0 ? void 0 : _user$attributes.appType
47
49
  };
48
50
  }
49
51
  if (type === _types.EntityType.TEAM) {
@@ -3,7 +3,7 @@ export const messages = defineMessages({
3
3
  externalUserSourcesHeading: {
4
4
  id: 'fabric.elements.user-picker.external.sourced.from',
5
5
  defaultMessage: 'Found in:',
6
- description: 'From where the external user is coming'
6
+ description: 'The text is shown as a label in the user picker dropdown preceding the list of external organizations or directories where the external user account was found (e.g. a guest directory or external workspace).'
7
7
  },
8
8
  slackProvider: {
9
9
  id: 'fabric.elements.user-picker.slack.provider',
@@ -1,12 +1,9 @@
1
- import { fg } from '@atlaskit/platform-feature-flags';
2
1
  import { createAtlAttributionHeader } from './atl-attribution';
3
2
  const buildHeaders = attributionData => {
4
3
  const headers = new Headers();
5
4
  headers.append('Content-Type', 'application/json');
6
- if (fg('smart-user-picker-attribution-header')) {
7
- const atlAttributionHeader = createAtlAttributionHeader(attributionData);
8
- headers.append('atl-attribution', atlAttributionHeader['atl-attribution']);
9
- }
5
+ const atlAttributionHeader = createAtlAttributionHeader(attributionData);
6
+ headers.append('atl-attribution', atlAttributionHeader['atl-attribution']);
10
7
  return headers;
11
8
  };
12
9
  /**
@@ -24,6 +24,7 @@ const getLozenzeProperties = (entity, intl) => {
24
24
  const transformUser = (item, intl) => {
25
25
  const type = item.entityType;
26
26
  if (type === EntityType.USER) {
27
+ var _user$attributes;
27
28
  const user = item;
28
29
  const lozenge = getLozenzeProperties(user, intl);
29
30
  return {
@@ -37,7 +38,8 @@ const transformUser = (item, intl) => {
37
38
  lozenge: lozenge,
38
39
  tooltip: user.name,
39
40
  isExternal: Boolean(user.nonLicensedUser),
40
- sources: user.nonLicensedUser ? ['other-atlassian'] : undefined
41
+ sources: user.nonLicensedUser ? ['other-atlassian'] : undefined,
42
+ appType: user.appType !== undefined ? user.appType : (_user$attributes = user.attributes) === null || _user$attributes === void 0 ? void 0 : _user$attributes.appType
41
43
  };
42
44
  }
43
45
  if (type === EntityType.TEAM) {
package/dist/esm/i18n.js CHANGED
@@ -3,7 +3,7 @@ export var messages = defineMessages({
3
3
  externalUserSourcesHeading: {
4
4
  id: 'fabric.elements.user-picker.external.sourced.from',
5
5
  defaultMessage: 'Found in:',
6
- description: 'From where the external user is coming'
6
+ description: 'The text is shown as a label in the user picker dropdown preceding the list of external organizations or directories where the external user account was found (e.g. a guest directory or external workspace).'
7
7
  },
8
8
  slackProvider: {
9
9
  id: 'fabric.elements.user-picker.slack.provider',
@@ -1,12 +1,9 @@
1
- import { fg } from '@atlaskit/platform-feature-flags';
2
1
  import { createAtlAttributionHeader } from './atl-attribution';
3
2
  var buildHeaders = function buildHeaders(attributionData) {
4
3
  var headers = new Headers();
5
4
  headers.append('Content-Type', 'application/json');
6
- if (fg('smart-user-picker-attribution-header')) {
7
- var atlAttributionHeader = createAtlAttributionHeader(attributionData);
8
- headers.append('atl-attribution', atlAttributionHeader['atl-attribution']);
9
- }
5
+ var atlAttributionHeader = createAtlAttributionHeader(attributionData);
6
+ headers.append('atl-attribution', atlAttributionHeader['atl-attribution']);
10
7
  return headers;
11
8
  };
12
9
  /**
@@ -24,6 +24,7 @@ var getLozenzeProperties = function getLozenzeProperties(entity, intl) {
24
24
  var transformUser = function transformUser(item, intl) {
25
25
  var type = item.entityType;
26
26
  if (type === EntityType.USER) {
27
+ var _user$attributes;
27
28
  var user = item;
28
29
  var lozenge = getLozenzeProperties(user, intl);
29
30
  return {
@@ -37,7 +38,8 @@ var transformUser = function transformUser(item, intl) {
37
38
  lozenge: lozenge,
38
39
  tooltip: user.name,
39
40
  isExternal: Boolean(user.nonLicensedUser),
40
- sources: user.nonLicensedUser ? ['other-atlassian'] : undefined
41
+ sources: user.nonLicensedUser ? ['other-atlassian'] : undefined,
42
+ appType: user.appType !== undefined ? user.appType : (_user$attributes = user.attributes) === null || _user$attributes === void 0 ? void 0 : _user$attributes.appType
41
43
  };
42
44
  }
43
45
  if (type === EntityType.TEAM) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/smart-user-picker",
3
- "version": "10.0.0",
3
+ "version": "10.0.2",
4
4
  "license": "Apache-2.0",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -72,9 +72,6 @@
72
72
  "smart-user-picker-restrict-to-gate": {
73
73
  "type": "boolean"
74
74
  },
75
- "smart-user-picker-attribution-header": {
76
- "type": "boolean"
77
- },
78
75
  "user_picker_guest_lozenges": {
79
76
  "type": "boolean"
80
77
  }