@atlaskit/profilecard 24.9.3 → 24.10.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.
- package/CHANGELOG.md +19 -0
- package/dist/cjs/client/getOrgIdForCloudIdFromAGG.js +1 -1
- package/dist/cjs/client/getTeamFromAGG.js +1 -1
- package/dist/cjs/components/Agent/AgentProfileCardTrigger.js +3 -2
- package/dist/cjs/components/common/ProfileCardTrigger.js +7 -1
- package/dist/cjs/styled/Card.compiled.css +1 -1
- package/dist/cjs/styled/Card.js +2 -2
- package/dist/cjs/styled/CoverImage.compiled.css +2 -2
- package/dist/cjs/styled/CoverImage.js +1 -1
- package/dist/cjs/styled/TeamTrigger.compiled.css +1 -1
- package/dist/cjs/styled/TeamTrigger.js +1 -1
- package/dist/cjs/styled/UserTrigger.compiled.css +1 -1
- package/dist/cjs/styled/UserTrigger.js +1 -1
- package/dist/cjs/util/analytics.js +1 -1
- package/dist/es2019/client/getOrgIdForCloudIdFromAGG.js +1 -1
- package/dist/es2019/client/getTeamFromAGG.js +1 -1
- package/dist/es2019/components/Agent/AgentProfileCardTrigger.js +5 -4
- package/dist/es2019/components/common/ProfileCardTrigger.js +7 -3
- package/dist/es2019/styled/Card.compiled.css +1 -1
- package/dist/es2019/styled/Card.js +2 -2
- package/dist/es2019/styled/CoverImage.compiled.css +2 -2
- package/dist/es2019/styled/CoverImage.js +1 -1
- package/dist/es2019/styled/TeamTrigger.compiled.css +1 -1
- package/dist/es2019/styled/TeamTrigger.js +1 -1
- package/dist/es2019/styled/UserTrigger.compiled.css +1 -1
- package/dist/es2019/styled/UserTrigger.js +1 -1
- package/dist/es2019/util/analytics.js +1 -1
- package/dist/esm/client/getOrgIdForCloudIdFromAGG.js +1 -1
- package/dist/esm/client/getTeamFromAGG.js +1 -1
- package/dist/esm/components/Agent/AgentProfileCardTrigger.js +4 -3
- package/dist/esm/components/common/ProfileCardTrigger.js +8 -2
- package/dist/esm/styled/Card.compiled.css +1 -1
- package/dist/esm/styled/Card.js +2 -2
- package/dist/esm/styled/CoverImage.compiled.css +2 -2
- package/dist/esm/styled/CoverImage.js +1 -1
- package/dist/esm/styled/TeamTrigger.compiled.css +1 -1
- package/dist/esm/styled/TeamTrigger.js +1 -1
- package/dist/esm/styled/UserTrigger.compiled.css +1 -1
- package/dist/esm/styled/UserTrigger.js +1 -1
- package/dist/esm/util/analytics.js +1 -1
- package/dist/types/components/Agent/AgentProfileCardTrigger.d.ts +2 -1
- package/dist/types/components/common/ProfileCardTrigger.d.ts +6 -1
- package/dist/types-ts4.5/components/Agent/AgentProfileCardTrigger.d.ts +2 -1
- package/dist/types-ts4.5/components/common/ProfileCardTrigger.d.ts +6 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,24 @@
|
|
|
1
1
|
# @atlaskit/profilecard
|
|
2
2
|
|
|
3
|
+
## 24.10.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`7850e27fc7fa1`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/7850e27fc7fa1) -
|
|
8
|
+
Internal changes to how border radius is applied.
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
|
|
11
|
+
## 24.10.0
|
|
12
|
+
|
|
13
|
+
### Minor Changes
|
|
14
|
+
|
|
15
|
+
- [`c002dc5d4d6c0`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/c002dc5d4d6c0) -
|
|
16
|
+
[ux] Agent profile card dismisses when user clicks a chat prompt
|
|
17
|
+
|
|
18
|
+
### Patch Changes
|
|
19
|
+
|
|
20
|
+
- Updated dependencies
|
|
21
|
+
|
|
3
22
|
## 24.9.3
|
|
4
23
|
|
|
5
24
|
### 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', "24.
|
|
14
|
+
headers.append('atl-client-version', "24.10.0");
|
|
15
15
|
return headers;
|
|
16
16
|
};
|
|
17
17
|
function getOrgIdForCloudIdFromAGG(_x, _x2) {
|
|
@@ -65,7 +65,7 @@ var addHeaders = exports.addHeaders = function addHeaders(headers) {
|
|
|
65
65
|
headers.append('X-ExperimentalApi', 'teams-beta');
|
|
66
66
|
headers.append('X-ExperimentalApi', 'team-members-beta');
|
|
67
67
|
headers.append('atl-client-name', "@atlaskit/profilecard");
|
|
68
|
-
headers.append('atl-client-version', "24.
|
|
68
|
+
headers.append('atl-client-version', "24.10.0");
|
|
69
69
|
return headers;
|
|
70
70
|
};
|
|
71
71
|
function getTeamFromAGG(_x, _x2, _x3) {
|
|
@@ -23,7 +23,7 @@ var _excluded = ["trigger", "viewingUserId", "product", "hideOverflow"];
|
|
|
23
23
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
24
24
|
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; }
|
|
25
25
|
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; }
|
|
26
|
-
var AgentProfileCardTrigger = exports.AgentProfileCardTrigger = function
|
|
26
|
+
var AgentProfileCardTrigger = exports.AgentProfileCardTrigger = /*#__PURE__*/(0, _react.forwardRef)(function (_ref, ref) {
|
|
27
27
|
var _ref$trigger = _ref.trigger,
|
|
28
28
|
trigger = _ref$trigger === void 0 ? 'hover' : _ref$trigger,
|
|
29
29
|
viewingUserId = _ref.viewingUserId,
|
|
@@ -159,6 +159,7 @@ var AgentProfileCardTrigger = exports.AgentProfileCardTrigger = function AgentPr
|
|
|
159
159
|
}));
|
|
160
160
|
};
|
|
161
161
|
return /*#__PURE__*/_react.default.createElement(_ProfileCardTrigger.default, (0, _extends2.default)({}, props, {
|
|
162
|
+
ref: ref,
|
|
162
163
|
trigger: "hover",
|
|
163
164
|
renderProfileCard: renderProfileCard,
|
|
164
165
|
fetchProfile: fetchAgentProfile,
|
|
@@ -166,4 +167,4 @@ var AgentProfileCardTrigger = exports.AgentProfileCardTrigger = function AgentPr
|
|
|
166
167
|
profileCardType: "agent",
|
|
167
168
|
hideOverflow: hideOverflow
|
|
168
169
|
}));
|
|
169
|
-
};
|
|
170
|
+
});
|
|
@@ -31,7 +31,7 @@ var styles = {
|
|
|
31
31
|
};
|
|
32
32
|
var DELAY_MS_SHOW = 800;
|
|
33
33
|
var DELAY_MS_HIDE = 200;
|
|
34
|
-
function
|
|
34
|
+
function ProfileCardTriggerInner(_ref, ref) {
|
|
35
35
|
var _popupProps$autoFocus;
|
|
36
36
|
var _trigger = _ref.trigger,
|
|
37
37
|
ariaLabelledBy = _ref.ariaLabelledBy,
|
|
@@ -71,6 +71,11 @@ function ProfileCardTrigger(_ref) {
|
|
|
71
71
|
setVisible(false);
|
|
72
72
|
}, hideDelay);
|
|
73
73
|
}, [hideDelay]);
|
|
74
|
+
(0, _react.useImperativeHandle)(ref, function () {
|
|
75
|
+
return {
|
|
76
|
+
hideProfilecard: hideProfilecard
|
|
77
|
+
};
|
|
78
|
+
}, [hideProfilecard]);
|
|
74
79
|
var showProfilecard = (0, _react.useCallback)( /*#__PURE__*/(0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee() {
|
|
75
80
|
return _regenerator.default.wrap(function _callee$(_context) {
|
|
76
81
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -140,4 +145,5 @@ function ProfileCardTrigger(_ref) {
|
|
|
140
145
|
}
|
|
141
146
|
}));
|
|
142
147
|
}
|
|
148
|
+
var ProfileCardTrigger = /*#__PURE__*/(0, _react.forwardRef)(ProfileCardTriggerInner);
|
|
143
149
|
var _default = exports.default = ProfileCardTrigger;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
._11c81o8v{font:var(--ds-font-body-small,normal 400 11px/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,"Helvetica Neue",sans-serif)}
|
|
2
2
|
._11c8dcr7{font:var(--ds-font-body-UNSAFE_small,normal 400 9pt/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,"Helvetica Neue",sans-serif)}
|
|
3
|
-
.
|
|
3
|
+
._2rko12b0{border-radius:var(--ds-radius-small,4px)}
|
|
4
4
|
._zulp12x7{gap:var(--ds-space-075,6px)}
|
|
5
5
|
._zulpu2gc{gap:var(--ds-space-100,8px)}
|
|
6
6
|
._12vemgnk{background-repeat:no-repeat}
|
package/dist/cjs/styled/Card.js
CHANGED
|
@@ -30,7 +30,7 @@ var styles = {
|
|
|
30
30
|
cardContainer: "_1reo15vq _18m915vq _kqswh2mm _12vemgnk _1lrw14bs _ca0q1ejb _19bv1ejb _u5f31ejb _n3td1ejb",
|
|
31
31
|
cardContainerActiveUser: "_1itk1419",
|
|
32
32
|
cardContainerDisabledUser: "_1itkkf3t",
|
|
33
|
-
cardContainerWithElevation: "
|
|
33
|
+
cardContainerWithElevation: "_2rko12b0 _16qs1cd0",
|
|
34
34
|
detailsLabel: "_zulpu2gc _1e0c1txw _4cvr1h6o _1bah1y6m _19pkutpp _2hwxze3t _18u0ze3t _otyrze3t _o5721q9c",
|
|
35
35
|
detailsLabelNext: "_zulpu2gc _1e0c1txw _4cvr1h6o _1bah1y6m _19pkutpp _2hwxze3t _18u0ze3t _otyrze3t _19bvze3t _o5721q9c",
|
|
36
36
|
detailsLabelExtraTopSpace: "_19pkxy5q",
|
|
@@ -38,7 +38,7 @@ var styles = {
|
|
|
38
38
|
detailsLabelText: "_1reo15vq _18m915vq _11c8dcr7 _1bto1l2s _syaz1fxt _19pkze3t _18u0ze3t",
|
|
39
39
|
kudosBlobAnimation: "_1e0cglyw _4t3i1w81 _1bsb1w81 _1pby1mrw _kqswstnw _j7hq1q51 _tip8kb7n _5sagi11n _1itkq1hn",
|
|
40
40
|
jobTitleLabel: "_19pkze3t _otyrze3t _18u0utpp _2hwxze3t",
|
|
41
|
-
appTitleLabel: "
|
|
41
|
+
appTitleLabel: "_2rko12b0 _syaz1fxt _u5f312x7 _19bv12x7 _1bsb1ns9 _19pk1b66 _otyrze3t _18u0utpp _2hwxze3t"
|
|
42
42
|
};
|
|
43
43
|
var stylesCompiled = {
|
|
44
44
|
jobTitleLabel: "_19pkze3t _otyrze3t _18u0utpp _2hwxze3t _1br315cr",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
.
|
|
1
|
+
._13li12b0{border-top-left-radius:var(--ds-radius-small,4px)}
|
|
2
2
|
._18m915vq{overflow-y:hidden}
|
|
3
3
|
._1bah1h6o{justify-content:center}
|
|
4
4
|
._1bsb1osq{width:100%}
|
|
@@ -9,4 +9,4 @@
|
|
|
9
9
|
._4t3i1qr7{height:8pc}
|
|
10
10
|
._4t3i1wug{height:auto}
|
|
11
11
|
._kqswh2mm{position:relative}
|
|
12
|
-
.
|
|
12
|
+
._qrwq12b0{border-top-right-radius:var(--ds-radius-small,4px)}
|
|
@@ -12,7 +12,7 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
12
12
|
var _compiled = require("@atlaskit/primitives/compiled");
|
|
13
13
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
14
14
|
var styles = {
|
|
15
|
-
container: "_1reo15vq _18m915vq _1bsb1osq _4t3i1qr7 _kqswh2mm
|
|
15
|
+
container: "_1reo15vq _18m915vq _1bsb1osq _4t3i1qr7 _kqswh2mm _13li12b0 _qrwq12b0 _1e0c1txw _1bah1h6o _4cvr1h6o",
|
|
16
16
|
image: "_1bsbnklw _4t3i1wug"
|
|
17
17
|
};
|
|
18
18
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
.
|
|
2
|
+
._2rko12b0{border-radius:var(--ds-radius-small,4px)}._19bv1ejb{padding-left:var(--ds-space-300,24px)}
|
|
3
3
|
._19pk1jfw{margin-top:var(--ds-space-500,40px)}
|
|
4
4
|
._1bsb1osq{width:100%}
|
|
5
5
|
._1bsbnklw{width:20pc}
|
|
@@ -15,7 +15,7 @@ var _compiled = require("@atlaskit/primitives/compiled");
|
|
|
15
15
|
var _CoverImage = require("./CoverImage");
|
|
16
16
|
var styles = {
|
|
17
17
|
cardtriggerwrapper: "_1e0c1kw7",
|
|
18
|
-
cardwrapper: "
|
|
18
|
+
cardwrapper: "_2rko12b0 _1bsbnklw _kqswh2mm",
|
|
19
19
|
cardheader: "_4t3i1qr7 _1bsb1osq",
|
|
20
20
|
cardcontent: "_1e0c1txw _2lx21bp4 _ca0q1ejb _u5f31ejb _n3td1ejb _19bv1ejb _1tke1l8a",
|
|
21
21
|
loadingwrapper: "_y3gn1h6o _19pk1jfw _otyr1jfw"
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireDefault(require("react"));
|
|
|
15
15
|
var _css = require("@atlaskit/css");
|
|
16
16
|
var _compiled = require("@atlaskit/primitives/compiled");
|
|
17
17
|
var styles = {
|
|
18
|
-
cardWrapper: "
|
|
18
|
+
cardWrapper: "_2rko12b0 _1bsb1gwv",
|
|
19
19
|
spinnerContainer: "_4cvr1h6o _1e0c1txw _4t3i16xz _1bah1h6o _kqswh2mm"
|
|
20
20
|
};
|
|
21
21
|
var CardWrapper = exports.CardWrapper = function CardWrapper(_ref) {
|
|
@@ -45,7 +45,7 @@ var createEvent = function createEvent(eventType, action, actionSubject, actionS
|
|
|
45
45
|
actionSubjectId: actionSubjectId,
|
|
46
46
|
attributes: _objectSpread(_objectSpread({
|
|
47
47
|
packageName: "@atlaskit/profilecard",
|
|
48
|
-
packageVersion: "24.
|
|
48
|
+
packageVersion: "24.10.0"
|
|
49
49
|
}, attributes), {}, {
|
|
50
50
|
firedAt: Math.round((0, _performance.getPageTime)())
|
|
51
51
|
})
|
|
@@ -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', "24.
|
|
9
|
+
headers.append('atl-client-version', "24.10.0");
|
|
10
10
|
return headers;
|
|
11
11
|
};
|
|
12
12
|
export async function getOrgIdForCloudIdFromAGG(url, cloudId) {
|
|
@@ -74,7 +74,7 @@ export const addHeaders = headers => {
|
|
|
74
74
|
headers.append('X-ExperimentalApi', 'teams-beta');
|
|
75
75
|
headers.append('X-ExperimentalApi', 'team-members-beta');
|
|
76
76
|
headers.append('atl-client-name', "@atlaskit/profilecard");
|
|
77
|
-
headers.append('atl-client-version', "24.
|
|
77
|
+
headers.append('atl-client-version', "24.10.0");
|
|
78
78
|
return headers;
|
|
79
79
|
};
|
|
80
80
|
export async function getTeamFromAGG(url, teamId, siteId) {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
-
import React, { Suspense, useCallback } from 'react';
|
|
2
|
+
import React, { forwardRef, Suspense, useCallback } from 'react';
|
|
3
3
|
import { useAnalyticsEvents } from '@atlaskit/analytics-next';
|
|
4
4
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
5
5
|
import { navigateToTeamsApp } from '@atlaskit/teams-app-config/navigation';
|
|
@@ -7,13 +7,13 @@ import { fireEvent } from '../../util/analytics';
|
|
|
7
7
|
import { getAAIDFromARI } from '../../util/rovoAgentUtils';
|
|
8
8
|
import ProfileCardTrigger from '../common/ProfileCardTrigger';
|
|
9
9
|
import { AgentProfileCardLazy } from './lazyAgentProfileCard';
|
|
10
|
-
export const AgentProfileCardTrigger = ({
|
|
10
|
+
export const AgentProfileCardTrigger = /*#__PURE__*/forwardRef(({
|
|
11
11
|
trigger = 'hover',
|
|
12
12
|
viewingUserId,
|
|
13
13
|
product,
|
|
14
14
|
hideOverflow,
|
|
15
15
|
...props
|
|
16
|
-
}) => {
|
|
16
|
+
}, ref) => {
|
|
17
17
|
const {
|
|
18
18
|
resourceClient,
|
|
19
19
|
agentId: userId,
|
|
@@ -105,6 +105,7 @@ export const AgentProfileCardTrigger = ({
|
|
|
105
105
|
}));
|
|
106
106
|
};
|
|
107
107
|
return /*#__PURE__*/React.createElement(ProfileCardTrigger, _extends({}, props, {
|
|
108
|
+
ref: ref,
|
|
108
109
|
trigger: "hover",
|
|
109
110
|
renderProfileCard: renderProfileCard,
|
|
110
111
|
fetchProfile: fetchAgentProfile,
|
|
@@ -112,4 +113,4 @@ export const AgentProfileCardTrigger = ({
|
|
|
112
113
|
profileCardType: "agent",
|
|
113
114
|
hideOverflow: hideOverflow
|
|
114
115
|
}));
|
|
115
|
-
};
|
|
116
|
+
});
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import "./ProfileCardTrigger.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
5
|
-
import React, { useCallback, useEffect, useRef, useState } from 'react';
|
|
5
|
+
import React, { forwardRef, useCallback, useEffect, useImperativeHandle, useRef, useState } from 'react';
|
|
6
6
|
import Popup from '@atlaskit/popup';
|
|
7
7
|
import { Box } from '@atlaskit/primitives/compiled';
|
|
8
8
|
import { layers } from '@atlaskit/theme/constants';
|
|
@@ -16,7 +16,7 @@ const styles = {
|
|
|
16
16
|
};
|
|
17
17
|
const DELAY_MS_SHOW = 800;
|
|
18
18
|
const DELAY_MS_HIDE = 200;
|
|
19
|
-
function
|
|
19
|
+
function ProfileCardTriggerInner({
|
|
20
20
|
trigger,
|
|
21
21
|
ariaLabelledBy,
|
|
22
22
|
children,
|
|
@@ -27,7 +27,7 @@ function ProfileCardTrigger({
|
|
|
27
27
|
fireAnalytics,
|
|
28
28
|
hideOverflow,
|
|
29
29
|
...popupProps
|
|
30
|
-
}) {
|
|
30
|
+
}, ref) {
|
|
31
31
|
var _popupProps$autoFocus;
|
|
32
32
|
const showDelay = trigger === 'click' ? 0 : DELAY_MS_SHOW;
|
|
33
33
|
const hideDelay = trigger === 'click' ? 0 : DELAY_MS_HIDE;
|
|
@@ -55,6 +55,9 @@ function ProfileCardTrigger({
|
|
|
55
55
|
setVisible(false);
|
|
56
56
|
}, hideDelay);
|
|
57
57
|
}, [hideDelay]);
|
|
58
|
+
useImperativeHandle(ref, () => ({
|
|
59
|
+
hideProfilecard
|
|
60
|
+
}), [hideProfilecard]);
|
|
58
61
|
const showProfilecard = useCallback(async () => {
|
|
59
62
|
clearTimeout(hideTimer.current);
|
|
60
63
|
clearTimeout(showTimer.current);
|
|
@@ -115,4 +118,5 @@ function ProfileCardTrigger({
|
|
|
115
118
|
}))
|
|
116
119
|
}));
|
|
117
120
|
}
|
|
121
|
+
const ProfileCardTrigger = /*#__PURE__*/forwardRef(ProfileCardTriggerInner);
|
|
118
122
|
export default ProfileCardTrigger;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
._11c81o8v{font:var(--ds-font-body-small,normal 400 11px/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,"Helvetica Neue",sans-serif)}
|
|
2
2
|
._11c8dcr7{font:var(--ds-font-body-UNSAFE_small,normal 400 9pt/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,"Helvetica Neue",sans-serif)}
|
|
3
|
-
.
|
|
3
|
+
._2rko12b0{border-radius:var(--ds-radius-small,4px)}
|
|
4
4
|
._zulp12x7{gap:var(--ds-space-075,6px)}
|
|
5
5
|
._zulpu2gc{gap:var(--ds-space-100,8px)}
|
|
6
6
|
._12vemgnk{background-repeat:no-repeat}
|
|
@@ -23,7 +23,7 @@ const styles = {
|
|
|
23
23
|
cardContainer: "_1reo15vq _18m915vq _kqswh2mm _12vemgnk _1lrw14bs _ca0q1ejb _19bv1ejb _u5f31ejb _n3td1ejb",
|
|
24
24
|
cardContainerActiveUser: "_1itk1419",
|
|
25
25
|
cardContainerDisabledUser: "_1itkkf3t",
|
|
26
|
-
cardContainerWithElevation: "
|
|
26
|
+
cardContainerWithElevation: "_2rko12b0 _16qs1cd0",
|
|
27
27
|
detailsLabel: "_zulpu2gc _1e0c1txw _4cvr1h6o _1bah1y6m _19pkutpp _2hwxze3t _18u0ze3t _otyrze3t _o5721q9c",
|
|
28
28
|
detailsLabelNext: "_zulpu2gc _1e0c1txw _4cvr1h6o _1bah1y6m _19pkutpp _2hwxze3t _18u0ze3t _otyrze3t _19bvze3t _o5721q9c",
|
|
29
29
|
detailsLabelExtraTopSpace: "_19pkxy5q",
|
|
@@ -31,7 +31,7 @@ const styles = {
|
|
|
31
31
|
detailsLabelText: "_1reo15vq _18m915vq _11c8dcr7 _1bto1l2s _syaz1fxt _19pkze3t _18u0ze3t",
|
|
32
32
|
kudosBlobAnimation: "_1e0cglyw _4t3i1w81 _1bsb1w81 _1pby1mrw _kqswstnw _j7hq1q51 _tip8kb7n _5sagi11n _1itkq1hn",
|
|
33
33
|
jobTitleLabel: "_19pkze3t _otyrze3t _18u0utpp _2hwxze3t",
|
|
34
|
-
appTitleLabel: "
|
|
34
|
+
appTitleLabel: "_2rko12b0 _syaz1fxt _u5f312x7 _19bv12x7 _1bsb1ns9 _19pk1b66 _otyrze3t _18u0utpp _2hwxze3t"
|
|
35
35
|
};
|
|
36
36
|
const stylesCompiled = {
|
|
37
37
|
jobTitleLabel: "_19pkze3t _otyrze3t _18u0utpp _2hwxze3t _1br315cr",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
.
|
|
1
|
+
._13li12b0{border-top-left-radius:var(--ds-radius-small,4px)}
|
|
2
2
|
._18m915vq{overflow-y:hidden}
|
|
3
3
|
._1bah1h6o{justify-content:center}
|
|
4
4
|
._1bsb1osq{width:100%}
|
|
@@ -9,4 +9,4 @@
|
|
|
9
9
|
._4t3i1qr7{height:8pc}
|
|
10
10
|
._4t3i1wug{height:auto}
|
|
11
11
|
._kqswh2mm{position:relative}
|
|
12
|
-
.
|
|
12
|
+
._qrwq12b0{border-top-right-radius:var(--ds-radius-small,4px)}
|
|
@@ -4,7 +4,7 @@ import { ax, ix } from "@compiled/react/runtime";
|
|
|
4
4
|
import React, { useRef } from 'react';
|
|
5
5
|
import { Box } from '@atlaskit/primitives/compiled';
|
|
6
6
|
const styles = {
|
|
7
|
-
container: "_1reo15vq _18m915vq _1bsb1osq _4t3i1qr7 _kqswh2mm
|
|
7
|
+
container: "_1reo15vq _18m915vq _1bsb1osq _4t3i1qr7 _kqswh2mm _13li12b0 _qrwq12b0 _1e0c1txw _1bah1h6o _4cvr1h6o",
|
|
8
8
|
image: "_1bsbnklw _4t3i1wug"
|
|
9
9
|
};
|
|
10
10
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
.
|
|
2
|
+
._2rko12b0{border-radius:var(--ds-radius-small,4px)}._19bv1ejb{padding-left:var(--ds-space-300,24px)}
|
|
3
3
|
._19pk1jfw{margin-top:var(--ds-space-500,40px)}
|
|
4
4
|
._1bsb1osq{width:100%}
|
|
5
5
|
._1bsbnklw{width:20pc}
|
|
@@ -8,7 +8,7 @@ import { Box } from '@atlaskit/primitives/compiled';
|
|
|
8
8
|
import { CoverImage } from './CoverImage';
|
|
9
9
|
const styles = {
|
|
10
10
|
cardtriggerwrapper: "_1e0c1kw7",
|
|
11
|
-
cardwrapper: "
|
|
11
|
+
cardwrapper: "_2rko12b0 _1bsbnklw _kqswh2mm",
|
|
12
12
|
cardheader: "_4t3i1qr7 _1bsb1osq",
|
|
13
13
|
cardcontent: "_1e0c1txw _2lx21bp4 _ca0q1ejb _u5f31ejb _n3td1ejb _19bv1ejb _1tke1l8a",
|
|
14
14
|
loadingwrapper: "_y3gn1h6o _19pk1jfw _otyr1jfw"
|
|
@@ -8,7 +8,7 @@ import React from 'react';
|
|
|
8
8
|
import { cx } from '@atlaskit/css';
|
|
9
9
|
import { Box } from '@atlaskit/primitives/compiled';
|
|
10
10
|
const styles = {
|
|
11
|
-
cardWrapper: "
|
|
11
|
+
cardWrapper: "_2rko12b0 _1bsb1gwv",
|
|
12
12
|
spinnerContainer: "_4cvr1h6o _1e0c1txw _4t3i16xz _1bah1h6o _kqswh2mm"
|
|
13
13
|
};
|
|
14
14
|
export const CardWrapper = ({
|
|
@@ -32,7 +32,7 @@ const createEvent = (eventType, action, actionSubject, actionSubjectId, attribut
|
|
|
32
32
|
actionSubjectId,
|
|
33
33
|
attributes: {
|
|
34
34
|
packageName: "@atlaskit/profilecard",
|
|
35
|
-
packageVersion: "24.
|
|
35
|
+
packageVersion: "24.10.0",
|
|
36
36
|
...attributes,
|
|
37
37
|
firedAt: Math.round(getPageTime())
|
|
38
38
|
}
|
|
@@ -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', "24.
|
|
7
|
+
headers.append('atl-client-version', "24.10.0");
|
|
8
8
|
return headers;
|
|
9
9
|
};
|
|
10
10
|
export function getOrgIdForCloudIdFromAGG(_x, _x2) {
|
|
@@ -56,7 +56,7 @@ export var addHeaders = function addHeaders(headers) {
|
|
|
56
56
|
headers.append('X-ExperimentalApi', 'teams-beta');
|
|
57
57
|
headers.append('X-ExperimentalApi', 'team-members-beta');
|
|
58
58
|
headers.append('atl-client-name', "@atlaskit/profilecard");
|
|
59
|
-
headers.append('atl-client-version', "24.
|
|
59
|
+
headers.append('atl-client-version', "24.10.0");
|
|
60
60
|
return headers;
|
|
61
61
|
};
|
|
62
62
|
export function getTeamFromAGG(_x, _x2, _x3) {
|
|
@@ -6,7 +6,7 @@ var _excluded = ["trigger", "viewingUserId", "product", "hideOverflow"];
|
|
|
6
6
|
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; }
|
|
7
7
|
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; }
|
|
8
8
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
9
|
-
import React, { Suspense, useCallback } from 'react';
|
|
9
|
+
import React, { forwardRef, Suspense, useCallback } from 'react';
|
|
10
10
|
import { useAnalyticsEvents } from '@atlaskit/analytics-next';
|
|
11
11
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
12
12
|
import { navigateToTeamsApp } from '@atlaskit/teams-app-config/navigation';
|
|
@@ -14,7 +14,7 @@ import { fireEvent } from '../../util/analytics';
|
|
|
14
14
|
import { getAAIDFromARI } from '../../util/rovoAgentUtils';
|
|
15
15
|
import ProfileCardTrigger from '../common/ProfileCardTrigger';
|
|
16
16
|
import { AgentProfileCardLazy } from './lazyAgentProfileCard';
|
|
17
|
-
export var AgentProfileCardTrigger = function
|
|
17
|
+
export var AgentProfileCardTrigger = /*#__PURE__*/forwardRef(function (_ref, ref) {
|
|
18
18
|
var _ref$trigger = _ref.trigger,
|
|
19
19
|
trigger = _ref$trigger === void 0 ? 'hover' : _ref$trigger,
|
|
20
20
|
viewingUserId = _ref.viewingUserId,
|
|
@@ -150,6 +150,7 @@ export var AgentProfileCardTrigger = function AgentProfileCardTrigger(_ref) {
|
|
|
150
150
|
}));
|
|
151
151
|
};
|
|
152
152
|
return /*#__PURE__*/React.createElement(ProfileCardTrigger, _extends({}, props, {
|
|
153
|
+
ref: ref,
|
|
153
154
|
trigger: "hover",
|
|
154
155
|
renderProfileCard: renderProfileCard,
|
|
155
156
|
fetchProfile: fetchAgentProfile,
|
|
@@ -157,4 +158,4 @@ export var AgentProfileCardTrigger = function AgentProfileCardTrigger(_ref) {
|
|
|
157
158
|
profileCardType: "agent",
|
|
158
159
|
hideOverflow: hideOverflow
|
|
159
160
|
}));
|
|
160
|
-
};
|
|
161
|
+
});
|
|
@@ -8,7 +8,7 @@ var _excluded = ["trigger", "ariaLabelledBy", "children", "renderProfileCard", "
|
|
|
8
8
|
import "./ProfileCardTrigger.compiled.css";
|
|
9
9
|
import { ax, ix } from "@compiled/react/runtime";
|
|
10
10
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
11
|
-
import React, { useCallback, useEffect, useRef, useState } from 'react';
|
|
11
|
+
import React, { forwardRef, useCallback, useEffect, useImperativeHandle, useRef, useState } from 'react';
|
|
12
12
|
import Popup from '@atlaskit/popup';
|
|
13
13
|
import { Box } from '@atlaskit/primitives/compiled';
|
|
14
14
|
import { layers } from '@atlaskit/theme/constants';
|
|
@@ -22,7 +22,7 @@ var styles = {
|
|
|
22
22
|
};
|
|
23
23
|
var DELAY_MS_SHOW = 800;
|
|
24
24
|
var DELAY_MS_HIDE = 200;
|
|
25
|
-
function
|
|
25
|
+
function ProfileCardTriggerInner(_ref, ref) {
|
|
26
26
|
var _popupProps$autoFocus;
|
|
27
27
|
var _trigger = _ref.trigger,
|
|
28
28
|
ariaLabelledBy = _ref.ariaLabelledBy,
|
|
@@ -62,6 +62,11 @@ function ProfileCardTrigger(_ref) {
|
|
|
62
62
|
setVisible(false);
|
|
63
63
|
}, hideDelay);
|
|
64
64
|
}, [hideDelay]);
|
|
65
|
+
useImperativeHandle(ref, function () {
|
|
66
|
+
return {
|
|
67
|
+
hideProfilecard: hideProfilecard
|
|
68
|
+
};
|
|
69
|
+
}, [hideProfilecard]);
|
|
65
70
|
var showProfilecard = useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee() {
|
|
66
71
|
return _regeneratorRuntime.wrap(function _callee$(_context) {
|
|
67
72
|
while (1) switch (_context.prev = _context.next) {
|
|
@@ -131,4 +136,5 @@ function ProfileCardTrigger(_ref) {
|
|
|
131
136
|
}
|
|
132
137
|
}));
|
|
133
138
|
}
|
|
139
|
+
var ProfileCardTrigger = /*#__PURE__*/forwardRef(ProfileCardTriggerInner);
|
|
134
140
|
export default ProfileCardTrigger;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
._11c81o8v{font:var(--ds-font-body-small,normal 400 11px/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,"Helvetica Neue",sans-serif)}
|
|
2
2
|
._11c8dcr7{font:var(--ds-font-body-UNSAFE_small,normal 400 9pt/1pc ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,"Helvetica Neue",sans-serif)}
|
|
3
|
-
.
|
|
3
|
+
._2rko12b0{border-radius:var(--ds-radius-small,4px)}
|
|
4
4
|
._zulp12x7{gap:var(--ds-space-075,6px)}
|
|
5
5
|
._zulpu2gc{gap:var(--ds-space-100,8px)}
|
|
6
6
|
._12vemgnk{background-repeat:no-repeat}
|
package/dist/esm/styled/Card.js
CHANGED
|
@@ -23,7 +23,7 @@ var styles = {
|
|
|
23
23
|
cardContainer: "_1reo15vq _18m915vq _kqswh2mm _12vemgnk _1lrw14bs _ca0q1ejb _19bv1ejb _u5f31ejb _n3td1ejb",
|
|
24
24
|
cardContainerActiveUser: "_1itk1419",
|
|
25
25
|
cardContainerDisabledUser: "_1itkkf3t",
|
|
26
|
-
cardContainerWithElevation: "
|
|
26
|
+
cardContainerWithElevation: "_2rko12b0 _16qs1cd0",
|
|
27
27
|
detailsLabel: "_zulpu2gc _1e0c1txw _4cvr1h6o _1bah1y6m _19pkutpp _2hwxze3t _18u0ze3t _otyrze3t _o5721q9c",
|
|
28
28
|
detailsLabelNext: "_zulpu2gc _1e0c1txw _4cvr1h6o _1bah1y6m _19pkutpp _2hwxze3t _18u0ze3t _otyrze3t _19bvze3t _o5721q9c",
|
|
29
29
|
detailsLabelExtraTopSpace: "_19pkxy5q",
|
|
@@ -31,7 +31,7 @@ var styles = {
|
|
|
31
31
|
detailsLabelText: "_1reo15vq _18m915vq _11c8dcr7 _1bto1l2s _syaz1fxt _19pkze3t _18u0ze3t",
|
|
32
32
|
kudosBlobAnimation: "_1e0cglyw _4t3i1w81 _1bsb1w81 _1pby1mrw _kqswstnw _j7hq1q51 _tip8kb7n _5sagi11n _1itkq1hn",
|
|
33
33
|
jobTitleLabel: "_19pkze3t _otyrze3t _18u0utpp _2hwxze3t",
|
|
34
|
-
appTitleLabel: "
|
|
34
|
+
appTitleLabel: "_2rko12b0 _syaz1fxt _u5f312x7 _19bv12x7 _1bsb1ns9 _19pk1b66 _otyrze3t _18u0utpp _2hwxze3t"
|
|
35
35
|
};
|
|
36
36
|
var stylesCompiled = {
|
|
37
37
|
jobTitleLabel: "_19pkze3t _otyrze3t _18u0utpp _2hwxze3t _1br315cr",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
.
|
|
1
|
+
._13li12b0{border-top-left-radius:var(--ds-radius-small,4px)}
|
|
2
2
|
._18m915vq{overflow-y:hidden}
|
|
3
3
|
._1bah1h6o{justify-content:center}
|
|
4
4
|
._1bsb1osq{width:100%}
|
|
@@ -9,4 +9,4 @@
|
|
|
9
9
|
._4t3i1qr7{height:8pc}
|
|
10
10
|
._4t3i1wug{height:auto}
|
|
11
11
|
._kqswh2mm{position:relative}
|
|
12
|
-
.
|
|
12
|
+
._qrwq12b0{border-top-right-radius:var(--ds-radius-small,4px)}
|
|
@@ -4,7 +4,7 @@ import { ax, ix } from "@compiled/react/runtime";
|
|
|
4
4
|
import React, { useRef } from 'react';
|
|
5
5
|
import { Box } from '@atlaskit/primitives/compiled';
|
|
6
6
|
var styles = {
|
|
7
|
-
container: "_1reo15vq _18m915vq _1bsb1osq _4t3i1qr7 _kqswh2mm
|
|
7
|
+
container: "_1reo15vq _18m915vq _1bsb1osq _4t3i1qr7 _kqswh2mm _13li12b0 _qrwq12b0 _1e0c1txw _1bah1h6o _4cvr1h6o",
|
|
8
8
|
image: "_1bsbnklw _4t3i1wug"
|
|
9
9
|
};
|
|
10
10
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
|
|
2
|
-
.
|
|
2
|
+
._2rko12b0{border-radius:var(--ds-radius-small,4px)}._19bv1ejb{padding-left:var(--ds-space-300,24px)}
|
|
3
3
|
._19pk1jfw{margin-top:var(--ds-space-500,40px)}
|
|
4
4
|
._1bsb1osq{width:100%}
|
|
5
5
|
._1bsbnklw{width:20pc}
|
|
@@ -8,7 +8,7 @@ import { Box } from '@atlaskit/primitives/compiled';
|
|
|
8
8
|
import { CoverImage } from './CoverImage';
|
|
9
9
|
var styles = {
|
|
10
10
|
cardtriggerwrapper: "_1e0c1kw7",
|
|
11
|
-
cardwrapper: "
|
|
11
|
+
cardwrapper: "_2rko12b0 _1bsbnklw _kqswh2mm",
|
|
12
12
|
cardheader: "_4t3i1qr7 _1bsb1osq",
|
|
13
13
|
cardcontent: "_1e0c1txw _2lx21bp4 _ca0q1ejb _u5f31ejb _n3td1ejb _19bv1ejb _1tke1l8a",
|
|
14
14
|
loadingwrapper: "_y3gn1h6o _19pk1jfw _otyr1jfw"
|
|
@@ -8,7 +8,7 @@ import React from 'react';
|
|
|
8
8
|
import { cx } from '@atlaskit/css';
|
|
9
9
|
import { Box } from '@atlaskit/primitives/compiled';
|
|
10
10
|
var styles = {
|
|
11
|
-
cardWrapper: "
|
|
11
|
+
cardWrapper: "_2rko12b0 _1bsb1gwv",
|
|
12
12
|
spinnerContainer: "_4cvr1h6o _1e0c1txw _4t3i16xz _1bah1h6o _kqswh2mm"
|
|
13
13
|
};
|
|
14
14
|
export var CardWrapper = function CardWrapper(_ref) {
|
|
@@ -39,7 +39,7 @@ var createEvent = function createEvent(eventType, action, actionSubject, actionS
|
|
|
39
39
|
actionSubjectId: actionSubjectId,
|
|
40
40
|
attributes: _objectSpread(_objectSpread({
|
|
41
41
|
packageName: "@atlaskit/profilecard",
|
|
42
|
-
packageVersion: "24.
|
|
42
|
+
packageVersion: "24.10.0"
|
|
43
43
|
}, attributes), {}, {
|
|
44
44
|
firedAt: Math.round(getPageTime())
|
|
45
45
|
})
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { type AgentProfileCardTriggerProps } from '../../types';
|
|
3
|
-
|
|
3
|
+
import { type ProfileCardHandle } from '../common/ProfileCardTrigger';
|
|
4
|
+
export declare const AgentProfileCardTrigger: React.ForwardRefExoticComponent<AgentProfileCardTriggerProps & React.RefAttributes<ProfileCardHandle>>;
|
|
@@ -1,4 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { type ProfileCardTriggerProps } from './types';
|
|
3
|
-
|
|
3
|
+
export interface ProfileCardHandle {
|
|
4
|
+
hideProfilecard: () => void;
|
|
5
|
+
}
|
|
6
|
+
declare const ProfileCardTrigger: <T>(props: ProfileCardTriggerProps<T> & {
|
|
7
|
+
ref?: React.Ref<ProfileCardHandle>;
|
|
8
|
+
}) => React.ReactElement;
|
|
4
9
|
export default ProfileCardTrigger;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { type AgentProfileCardTriggerProps } from '../../types';
|
|
3
|
-
|
|
3
|
+
import { type ProfileCardHandle } from '../common/ProfileCardTrigger';
|
|
4
|
+
export declare const AgentProfileCardTrigger: React.ForwardRefExoticComponent<AgentProfileCardTriggerProps & React.RefAttributes<ProfileCardHandle>>;
|
|
@@ -1,4 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { type ProfileCardTriggerProps } from './types';
|
|
3
|
-
|
|
3
|
+
export interface ProfileCardHandle {
|
|
4
|
+
hideProfilecard: () => void;
|
|
5
|
+
}
|
|
6
|
+
declare const ProfileCardTrigger: <T>(props: ProfileCardTriggerProps<T> & {
|
|
7
|
+
ref?: React.Ref<ProfileCardHandle>;
|
|
8
|
+
}) => React.ReactElement;
|
|
4
9
|
export default ProfileCardTrigger;
|