@atlaskit/profilecard 25.7.7 → 25.7.8

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,12 @@
1
1
  # @atlaskit/profilecard
2
2
 
3
+ ## 25.7.8
4
+
5
+ ### Patch Changes
6
+
7
+ - [`230baf9a1f9fb`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/230baf9a1f9fb) -
8
+ Use the stable agent profile card loading path when editor agent mentions are enabled.
9
+
3
10
  ## 25.7.7
4
11
 
5
12
  ### Patch Changes
@@ -11,7 +11,7 @@ var _graphqlUtils = require("./graphqlUtils");
11
11
  var ORG_ID_FROM_CLOUD_ID_QUERY = "query OrgIdFromCloudId($cloudId: ID!) {\n\ttenantContexts(cloudIds: [$cloudId]) {\n\t\torgId\n\t}\n}";
12
12
  var addHeaders = function addHeaders(headers) {
13
13
  headers.append('atl-client-name', "@atlaskit/profilecard");
14
- headers.append('atl-client-version', "25.7.6");
14
+ headers.append('atl-client-version', "25.7.7");
15
15
  return headers;
16
16
  };
17
17
  function getOrgIdForCloudIdFromAGG(_x, _x2) {
@@ -66,7 +66,7 @@ var addHeaders = exports.addHeaders = function addHeaders(headers) {
66
66
  headers.append('X-ExperimentalApi', 'teams-beta');
67
67
  headers.append('X-ExperimentalApi', 'team-members-beta');
68
68
  headers.append('atl-client-name', "@atlaskit/profilecard");
69
- headers.append('atl-client-version', "25.7.6");
69
+ headers.append('atl-client-version', "25.7.7");
70
70
  return headers;
71
71
  };
72
72
  function getTeamFromAGG(_x, _x2, _x3) {
@@ -29,7 +29,7 @@ var AgentProfileCardResourced = exports.AgentProfileCardResourced = function Age
29
29
  setAgentData = _useState2[1];
30
30
  // Initialize as true when fix is enabled since we fetch immediately on mount,
31
31
  // avoiding a brief error screen flash before the useEffect fires.
32
- var _useState3 = (0, _react.useState)((0, _platformFeatureFlags.fg)('jira_ai_fix_agent_profile_card_flashing')),
32
+ var _useState3 = (0, _react.useState)((0, _platformFeatureFlags.fg)('jira_ai_fix_agent_profile_card_flashing') || (0, _platformFeatureFlags.fg)('confluence_fix_agent_profile_card_flash')),
33
33
  _useState4 = (0, _slicedToArray2.default)(_useState3, 2),
34
34
  isLoading = _useState4[0],
35
35
  setIsLoading = _useState4[1];
@@ -58,7 +58,7 @@ var AgentProfileCardResourced = exports.AgentProfileCardResourced = function Age
58
58
  case 0:
59
59
  creator_type = _ref.creator_type, creator = _ref.creator, authoringTeam = _ref.authoringTeam;
60
60
  _context.prev = 1;
61
- currentCreatorUserId = (0, _platformFeatureFlags.fg)('jira_ai_fix_agent_profile_card_flashing') ? creator_type === 'CUSTOMER' && creator ? (0, _rovoAgentUtils.getAAIDFromARI)(creator) : undefined : creatorUserId;
61
+ currentCreatorUserId = (0, _platformFeatureFlags.fg)('jira_ai_fix_agent_profile_card_flashing') || (0, _platformFeatureFlags.fg)('confluence_fix_agent_profile_card_flash') ? creator_type === 'CUSTOMER' && creator ? (0, _rovoAgentUtils.getAAIDFromARI)(creator) : undefined : creatorUserId;
62
62
  if (!(currentCreatorUserId && props.cloudId)) {
63
63
  _context.next = 3;
64
64
  break;
@@ -67,7 +67,7 @@ var AgentProfileCardResourced = exports.AgentProfileCardResourced = function Age
67
67
  return props.resourceClient.getProfile(props.cloudId, currentCreatorUserId, fireEvent);
68
68
  case 2:
69
69
  userCreatorInfo = _context.sent;
70
- if ((0, _platformFeatureFlags.fg)('jira_ai_fix_agent_profile_card_flashing')) {
70
+ if ((0, _platformFeatureFlags.fg)('jira_ai_fix_agent_profile_card_flashing') || (0, _platformFeatureFlags.fg)('confluence_fix_agent_profile_card_flash')) {
71
71
  profileHref = (0, _navigation.navigateToTeamsApp)({
72
72
  type: 'USER',
73
73
  payload: {
@@ -152,7 +152,7 @@ var AgentProfileCardResourced = exports.AgentProfileCardResourced = function Age
152
152
  // agentData changes → creatorUserId → getCreator → fetchData ref changes → useEffect re-fires.
153
153
  // Reset state on accountId change so stale data from the previous agent isn't briefly shown.
154
154
  (0, _react.useEffect)(function () {
155
- if (!(0, _platformFeatureFlags.fg)('jira_ai_fix_agent_profile_card_flashing')) {
155
+ if (!((0, _platformFeatureFlags.fg)('jira_ai_fix_agent_profile_card_flashing') || (0, _platformFeatureFlags.fg)('confluence_fix_agent_profile_card_flash'))) {
156
156
  return;
157
157
  }
158
158
  setAgentData(undefined);
@@ -162,7 +162,7 @@ var AgentProfileCardResourced = exports.AgentProfileCardResourced = function Age
162
162
  // eslint-disable-next-line react-hooks/exhaustive-deps
163
163
  }, [props.accountId]);
164
164
  (0, _react.useEffect)(function () {
165
- if ((0, _platformFeatureFlags.fg)('jira_ai_fix_agent_profile_card_flashing')) {
165
+ if ((0, _platformFeatureFlags.fg)('jira_ai_fix_agent_profile_card_flashing') || (0, _platformFeatureFlags.fg)('confluence_fix_agent_profile_card_flash')) {
166
166
  return;
167
167
  }
168
168
  fetchData();
@@ -12,7 +12,7 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
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 PACKAGE_META_DATA = exports.PACKAGE_META_DATA = {
14
14
  packageName: (_process$env$_PACKAGE = "@atlaskit/profilecard") !== null && _process$env$_PACKAGE !== void 0 ? _process$env$_PACKAGE : '',
15
- packageVersion: (_process$env$_PACKAGE2 = "25.7.6") !== null && _process$env$_PACKAGE2 !== void 0 ? _process$env$_PACKAGE2 : ''
15
+ packageVersion: (_process$env$_PACKAGE2 = "25.7.7") !== null && _process$env$_PACKAGE2 !== void 0 ? _process$env$_PACKAGE2 : ''
16
16
  };
17
17
  var TEAM_SUBJECT = 'teamProfileCard';
18
18
  var USER_SUBJECT = 'profilecard';
@@ -31,7 +31,7 @@ var createEvent = function createEvent(eventType, action, actionSubject, actionS
31
31
  actionSubjectId: actionSubjectId,
32
32
  attributes: _objectSpread(_objectSpread({
33
33
  packageName: "@atlaskit/profilecard",
34
- packageVersion: "25.7.6"
34
+ packageVersion: "25.7.7"
35
35
  }, attributes), {}, {
36
36
  firedAt: Math.round((0, _performance.getPageTime)())
37
37
  })
@@ -6,7 +6,7 @@ const ORG_ID_FROM_CLOUD_ID_QUERY = `query OrgIdFromCloudId($cloudId: ID!) {
6
6
  }`;
7
7
  const addHeaders = headers => {
8
8
  headers.append('atl-client-name', "@atlaskit/profilecard");
9
- headers.append('atl-client-version', "25.7.6");
9
+ headers.append('atl-client-version', "25.7.7");
10
10
  return headers;
11
11
  };
12
12
  export async function getOrgIdForCloudIdFromAGG(url, cloudId) {
@@ -78,7 +78,7 @@ export const addHeaders = headers => {
78
78
  headers.append('X-ExperimentalApi', 'teams-beta');
79
79
  headers.append('X-ExperimentalApi', 'team-members-beta');
80
80
  headers.append('atl-client-name', "@atlaskit/profilecard");
81
- headers.append('atl-client-version', "25.7.6");
81
+ headers.append('atl-client-version', "25.7.7");
82
82
  return headers;
83
83
  };
84
84
  export async function getTeamFromAGG(url, teamId, siteId) {
@@ -11,7 +11,7 @@ export const AgentProfileCardResourced = props => {
11
11
  const [agentData, setAgentData] = useState();
12
12
  // Initialize as true when fix is enabled since we fetch immediately on mount,
13
13
  // avoiding a brief error screen flash before the useEffect fires.
14
- const [isLoading, setIsLoading] = useState(fg('jira_ai_fix_agent_profile_card_flashing'));
14
+ const [isLoading, setIsLoading] = useState(fg('jira_ai_fix_agent_profile_card_flashing') || fg('confluence_fix_agent_profile_card_flash'));
15
15
  const [error, setError] = useState();
16
16
  const {
17
17
  fireEvent
@@ -33,10 +33,10 @@ export const AgentProfileCardResourced = props => {
33
33
  try {
34
34
  var _authoringTeam$displa, _authoringTeam$profil, _userCreatorInfo$full;
35
35
  let userCreatorInfo;
36
- const currentCreatorUserId = fg('jira_ai_fix_agent_profile_card_flashing') ? creator_type === 'CUSTOMER' && creator ? getAAIDFromARI(creator) : undefined : creatorUserId;
36
+ const currentCreatorUserId = fg('jira_ai_fix_agent_profile_card_flashing') || fg('confluence_fix_agent_profile_card_flash') ? creator_type === 'CUSTOMER' && creator ? getAAIDFromARI(creator) : undefined : creatorUserId;
37
37
  if (currentCreatorUserId && props.cloudId) {
38
38
  userCreatorInfo = await props.resourceClient.getProfile(props.cloudId, currentCreatorUserId, fireEvent);
39
- if (fg('jira_ai_fix_agent_profile_card_flashing')) {
39
+ if (fg('jira_ai_fix_agent_profile_card_flashing') || fg('confluence_fix_agent_profile_card_flash')) {
40
40
  profileHref = navigateToTeamsApp({
41
41
  type: 'USER',
42
42
  payload: {
@@ -93,7 +93,7 @@ export const AgentProfileCardResourced = props => {
93
93
  // agentData changes → creatorUserId → getCreator → fetchData ref changes → useEffect re-fires.
94
94
  // Reset state on accountId change so stale data from the previous agent isn't briefly shown.
95
95
  useEffect(() => {
96
- if (!fg('jira_ai_fix_agent_profile_card_flashing')) {
96
+ if (!(fg('jira_ai_fix_agent_profile_card_flashing') || fg('confluence_fix_agent_profile_card_flash'))) {
97
97
  return;
98
98
  }
99
99
  setAgentData(undefined);
@@ -103,7 +103,7 @@ export const AgentProfileCardResourced = props => {
103
103
  // eslint-disable-next-line react-hooks/exhaustive-deps
104
104
  }, [props.accountId]);
105
105
  useEffect(() => {
106
- if (fg('jira_ai_fix_agent_profile_card_flashing')) {
106
+ if (fg('jira_ai_fix_agent_profile_card_flashing') || fg('confluence_fix_agent_profile_card_flash')) {
107
107
  return;
108
108
  }
109
109
  fetchData();
@@ -2,7 +2,7 @@ var _process$env$_PACKAGE, _process$env$_PACKAGE2;
2
2
  import { getPageTime } from './performance';
3
3
  export const PACKAGE_META_DATA = {
4
4
  packageName: (_process$env$_PACKAGE = "@atlaskit/profilecard") !== null && _process$env$_PACKAGE !== void 0 ? _process$env$_PACKAGE : '',
5
- packageVersion: (_process$env$_PACKAGE2 = "25.7.6") !== null && _process$env$_PACKAGE2 !== void 0 ? _process$env$_PACKAGE2 : ''
5
+ packageVersion: (_process$env$_PACKAGE2 = "25.7.7") !== null && _process$env$_PACKAGE2 !== void 0 ? _process$env$_PACKAGE2 : ''
6
6
  };
7
7
  const TEAM_SUBJECT = 'teamProfileCard';
8
8
  const USER_SUBJECT = 'profilecard';
@@ -19,7 +19,7 @@ const createEvent = (eventType, action, actionSubject, actionSubjectId, attribut
19
19
  actionSubjectId,
20
20
  attributes: {
21
21
  packageName: "@atlaskit/profilecard",
22
- packageVersion: "25.7.6",
22
+ packageVersion: "25.7.7",
23
23
  ...attributes,
24
24
  firedAt: Math.round(getPageTime())
25
25
  }
@@ -4,7 +4,7 @@ import { AGGQuery } from './graphqlUtils';
4
4
  var ORG_ID_FROM_CLOUD_ID_QUERY = "query OrgIdFromCloudId($cloudId: ID!) {\n\ttenantContexts(cloudIds: [$cloudId]) {\n\t\torgId\n\t}\n}";
5
5
  var addHeaders = function addHeaders(headers) {
6
6
  headers.append('atl-client-name', "@atlaskit/profilecard");
7
- headers.append('atl-client-version', "25.7.6");
7
+ headers.append('atl-client-version', "25.7.7");
8
8
  return headers;
9
9
  };
10
10
  export function getOrgIdForCloudIdFromAGG(_x, _x2) {
@@ -59,7 +59,7 @@ export var addHeaders = function addHeaders(headers) {
59
59
  headers.append('X-ExperimentalApi', 'teams-beta');
60
60
  headers.append('X-ExperimentalApi', 'team-members-beta');
61
61
  headers.append('atl-client-name', "@atlaskit/profilecard");
62
- headers.append('atl-client-version', "25.7.6");
62
+ headers.append('atl-client-version', "25.7.7");
63
63
  return headers;
64
64
  };
65
65
  export function getTeamFromAGG(_x, _x2, _x3) {
@@ -20,7 +20,7 @@ export var AgentProfileCardResourced = function AgentProfileCardResourced(props)
20
20
  setAgentData = _useState2[1];
21
21
  // Initialize as true when fix is enabled since we fetch immediately on mount,
22
22
  // avoiding a brief error screen flash before the useEffect fires.
23
- var _useState3 = useState(fg('jira_ai_fix_agent_profile_card_flashing')),
23
+ var _useState3 = useState(fg('jira_ai_fix_agent_profile_card_flashing') || fg('confluence_fix_agent_profile_card_flash')),
24
24
  _useState4 = _slicedToArray(_useState3, 2),
25
25
  isLoading = _useState4[0],
26
26
  setIsLoading = _useState4[1];
@@ -49,7 +49,7 @@ export var AgentProfileCardResourced = function AgentProfileCardResourced(props)
49
49
  case 0:
50
50
  creator_type = _ref.creator_type, creator = _ref.creator, authoringTeam = _ref.authoringTeam;
51
51
  _context.prev = 1;
52
- currentCreatorUserId = fg('jira_ai_fix_agent_profile_card_flashing') ? creator_type === 'CUSTOMER' && creator ? getAAIDFromARI(creator) : undefined : creatorUserId;
52
+ currentCreatorUserId = fg('jira_ai_fix_agent_profile_card_flashing') || fg('confluence_fix_agent_profile_card_flash') ? creator_type === 'CUSTOMER' && creator ? getAAIDFromARI(creator) : undefined : creatorUserId;
53
53
  if (!(currentCreatorUserId && props.cloudId)) {
54
54
  _context.next = 3;
55
55
  break;
@@ -58,7 +58,7 @@ export var AgentProfileCardResourced = function AgentProfileCardResourced(props)
58
58
  return props.resourceClient.getProfile(props.cloudId, currentCreatorUserId, fireEvent);
59
59
  case 2:
60
60
  userCreatorInfo = _context.sent;
61
- if (fg('jira_ai_fix_agent_profile_card_flashing')) {
61
+ if (fg('jira_ai_fix_agent_profile_card_flashing') || fg('confluence_fix_agent_profile_card_flash')) {
62
62
  profileHref = navigateToTeamsApp({
63
63
  type: 'USER',
64
64
  payload: {
@@ -143,7 +143,7 @@ export var AgentProfileCardResourced = function AgentProfileCardResourced(props)
143
143
  // agentData changes → creatorUserId → getCreator → fetchData ref changes → useEffect re-fires.
144
144
  // Reset state on accountId change so stale data from the previous agent isn't briefly shown.
145
145
  useEffect(function () {
146
- if (!fg('jira_ai_fix_agent_profile_card_flashing')) {
146
+ if (!(fg('jira_ai_fix_agent_profile_card_flashing') || fg('confluence_fix_agent_profile_card_flash'))) {
147
147
  return;
148
148
  }
149
149
  setAgentData(undefined);
@@ -153,7 +153,7 @@ export var AgentProfileCardResourced = function AgentProfileCardResourced(props)
153
153
  // eslint-disable-next-line react-hooks/exhaustive-deps
154
154
  }, [props.accountId]);
155
155
  useEffect(function () {
156
- if (fg('jira_ai_fix_agent_profile_card_flashing')) {
156
+ if (fg('jira_ai_fix_agent_profile_card_flashing') || fg('confluence_fix_agent_profile_card_flash')) {
157
157
  return;
158
158
  }
159
159
  fetchData();
@@ -5,7 +5,7 @@ function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t =
5
5
  import { getPageTime } from './performance';
6
6
  export var PACKAGE_META_DATA = {
7
7
  packageName: (_process$env$_PACKAGE = "@atlaskit/profilecard") !== null && _process$env$_PACKAGE !== void 0 ? _process$env$_PACKAGE : '',
8
- packageVersion: (_process$env$_PACKAGE2 = "25.7.6") !== null && _process$env$_PACKAGE2 !== void 0 ? _process$env$_PACKAGE2 : ''
8
+ packageVersion: (_process$env$_PACKAGE2 = "25.7.7") !== null && _process$env$_PACKAGE2 !== void 0 ? _process$env$_PACKAGE2 : ''
9
9
  };
10
10
  var TEAM_SUBJECT = 'teamProfileCard';
11
11
  var USER_SUBJECT = 'profilecard';
@@ -24,7 +24,7 @@ var createEvent = function createEvent(eventType, action, actionSubject, actionS
24
24
  actionSubjectId: actionSubjectId,
25
25
  attributes: _objectSpread(_objectSpread({
26
26
  packageName: "@atlaskit/profilecard",
27
- packageVersion: "25.7.6"
27
+ packageVersion: "25.7.7"
28
28
  }, attributes), {}, {
29
29
  firedAt: Math.round(getPageTime())
30
30
  })
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/profilecard",
3
- "version": "25.7.7",
3
+ "version": "25.7.8",
4
4
  "description": "A React component to display a card with user information.",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -52,7 +52,7 @@
52
52
  "@atlaskit/avatar-group": "^12.10.0",
53
53
  "@atlaskit/button": "^23.11.0",
54
54
  "@atlaskit/css": "^0.19.0",
55
- "@atlaskit/dropdown-menu": "^16.9.0",
55
+ "@atlaskit/dropdown-menu": "^16.10.0",
56
56
  "@atlaskit/empty-state": "^10.2.0",
57
57
  "@atlaskit/give-kudos": "^5.12.0",
58
58
  "@atlaskit/heading": "^5.4.0",
@@ -63,10 +63,10 @@
63
63
  "@atlaskit/modal-dialog": "^15.2.0",
64
64
  "@atlaskit/people-teams-ui-public": "^4.1.0",
65
65
  "@atlaskit/platform-feature-flags": "^1.1.0",
66
- "@atlaskit/popup": "^4.22.0",
66
+ "@atlaskit/popup": "^4.23.0",
67
67
  "@atlaskit/primitives": "^19.0.0",
68
- "@atlaskit/rovo-agent-components": "^4.6.0",
69
- "@atlaskit/rovo-triggers": "^6.4.0",
68
+ "@atlaskit/rovo-agent-components": "^4.7.0",
69
+ "@atlaskit/rovo-triggers": "^6.5.0",
70
70
  "@atlaskit/spinner": "^19.1.0",
71
71
  "@atlaskit/teams-app-config": "^1.12.0",
72
72
  "@atlaskit/teams-app-internal-analytics": "^1.32.0",
@@ -183,6 +183,9 @@
183
183
  "jira_ai_fix_agent_profile_card_flashing": {
184
184
  "type": "boolean"
185
185
  },
186
+ "confluence_fix_agent_profile_card_flash": {
187
+ "type": "boolean"
188
+ },
186
189
  "enable_teams_t26_design_drop_core_experiences": {
187
190
  "type": "boolean"
188
191
  },