@atlaskit/profilecard 23.6.7 → 23.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (30) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/dist/cjs/client/getOrgIdForCloudIdFromAGG.js +1 -1
  3. package/dist/cjs/client/getTeamFromAGG.js +1 -1
  4. package/dist/cjs/components/team-profile-card/main.js +11 -7
  5. package/dist/cjs/components/team-profile-card/team-containers-skeleton/index.compiled.css +3 -0
  6. package/dist/cjs/components/team-profile-card/team-containers-skeleton/index.js +33 -0
  7. package/dist/cjs/components/team-profile-card/team-containers-skeleton/linked-container-card-skeleton/index.compiled.css +17 -0
  8. package/dist/cjs/components/team-profile-card/team-containers-skeleton/linked-container-card-skeleton/index.js +40 -0
  9. package/dist/cjs/util/analytics.js +1 -1
  10. package/dist/es2019/client/getOrgIdForCloudIdFromAGG.js +1 -1
  11. package/dist/es2019/client/getTeamFromAGG.js +1 -1
  12. package/dist/es2019/components/team-profile-card/main.js +11 -7
  13. package/dist/es2019/components/team-profile-card/team-containers-skeleton/index.compiled.css +3 -0
  14. package/dist/es2019/components/team-profile-card/team-containers-skeleton/index.js +24 -0
  15. package/dist/es2019/components/team-profile-card/team-containers-skeleton/linked-container-card-skeleton/index.compiled.css +17 -0
  16. package/dist/es2019/components/team-profile-card/team-containers-skeleton/linked-container-card-skeleton/index.js +33 -0
  17. package/dist/es2019/util/analytics.js +1 -1
  18. package/dist/esm/client/getOrgIdForCloudIdFromAGG.js +1 -1
  19. package/dist/esm/client/getTeamFromAGG.js +1 -1
  20. package/dist/esm/components/team-profile-card/main.js +11 -7
  21. package/dist/esm/components/team-profile-card/team-containers-skeleton/index.compiled.css +3 -0
  22. package/dist/esm/components/team-profile-card/team-containers-skeleton/index.js +26 -0
  23. package/dist/esm/components/team-profile-card/team-containers-skeleton/linked-container-card-skeleton/index.compiled.css +17 -0
  24. package/dist/esm/components/team-profile-card/team-containers-skeleton/linked-container-card-skeleton/index.js +33 -0
  25. package/dist/esm/util/analytics.js +1 -1
  26. package/dist/types/components/team-profile-card/team-containers-skeleton/index.d.ts +3 -0
  27. package/dist/types/components/team-profile-card/team-containers-skeleton/linked-container-card-skeleton/index.d.ts +2 -0
  28. package/dist/types-ts4.5/components/team-profile-card/team-containers-skeleton/index.d.ts +3 -0
  29. package/dist/types-ts4.5/components/team-profile-card/team-containers-skeleton/linked-container-card-skeleton/index.d.ts +2 -0
  30. package/package.json +2 -2
package/CHANGELOG.md CHANGED
@@ -1,5 +1,17 @@
1
1
  # @atlaskit/profilecard
2
2
 
3
+ ## 23.7.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#131460](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/131460)
8
+ [`c890581942f6e`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/c890581942f6e) -
9
+ [ux] Add loading skeleton for team containers in profile card
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies
14
+
3
15
  ## 23.6.7
4
16
 
5
17
  ### 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', "23.6.7");
14
+ headers.append('atl-client-version', "23.7.0");
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', "23.6.7");
69
+ headers.append('atl-client-version', "23.7.0");
70
70
  return headers;
71
71
  };
72
72
  function getTeamFromAGG(_x, _x2, _x3) {
@@ -18,6 +18,7 @@ var _compiled = require("@atlaskit/primitives/compiled");
18
18
  var _teamsAvatar = _interopRequireDefault(require("@atlaskit/teams-avatar"));
19
19
  var _teamsPublic = require("@atlaskit/teams-public");
20
20
  var _main = require("./team-connections/main");
21
+ var _teamContainersSkeleton = require("./team-containers-skeleton");
21
22
  function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
22
23
  function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
23
24
  var noop = function noop() {};
@@ -27,7 +28,8 @@ var styles = {
27
28
  avatarImageStyles: "_kqswstnw _18u01ejb",
28
29
  headerImageStyles: "_5ral1dfr _s7n4jp4b _4t3i53f4 _1bsb1osq",
29
30
  teamInformationStyles: "_18u01ejb _19pku2gc _2hwx1ejb",
30
- teamConnectionStyles: "_18u01ejb _19pkpxbi _2hwx1ejb _c71lx2si _18m91wug",
31
+ teamConnectionHeaderStyles: "_18u01ejb _19pkpxbi _2hwx1ejb _c71lx2si _18m91wug",
32
+ teamConnectionContainerStyles: "_18u01ejb _2hwx1ejb",
31
33
  viewProfileContainerStyles: "_4cvr1h6o _uwhke4h9 _15a5nqa1 _1i53muej _19bv1ejb _u5f31ejb",
32
34
  viewProfileButtonStyles: "_2rkoiti9 _189ee4h9 _1dqonqa1 _1h6dmuej _bfhksm61 _syaz1gjq _1bsb1osq _4t3i1ul9 _19pkpxbi"
33
35
  };
@@ -63,7 +65,8 @@ var TeamProfileCard = exports.TeamProfileCard = function TeamProfileCard(_ref3)
63
65
  isVerified = _ref3.isVerified,
64
66
  teamProfileUrl = _ref3.teamProfileUrl;
65
67
  var _useTeamContainers = (0, _teamsPublic.useTeamContainers)(teamId),
66
- teamContainers = _useTeamContainers.teamContainers;
68
+ teamContainers = _useTeamContainers.teamContainers,
69
+ loading = _useTeamContainers.loading;
67
70
  // Ensure that the current container is not the only connection for this team before showing the "Where we work" section
68
71
  var hasOtherTeamConnections = (0, _react.useMemo)(function () {
69
72
  return teamContainers.filter(function (tc) {
@@ -110,10 +113,10 @@ var TeamProfileCard = exports.TeamProfileCard = function TeamProfileCard(_ref3)
110
113
  })), description && /*#__PURE__*/_react.default.createElement(_compiled.Text, {
111
114
  color: "color.text",
112
115
  maxLines: 3
113
- }, description)), hasOtherTeamConnections && /*#__PURE__*/_react.default.createElement(_compiled.Stack, {
114
- xcss: styles.teamConnectionStyles,
115
- space: "space.200"
116
- }, /*#__PURE__*/_react.default.createElement(_heading.default, {
116
+ }, description)), (loading || hasOtherTeamConnections) && /*#__PURE__*/_react.default.createElement(_compiled.Stack, {
117
+ space: 'space.200',
118
+ xcss: hasOtherTeamConnections ? styles.teamConnectionHeaderStyles : styles.teamConnectionContainerStyles
119
+ }, hasOtherTeamConnections && /*#__PURE__*/_react.default.createElement(_heading.default, {
117
120
  size: "xxsmall"
118
121
  }, /*#__PURE__*/_react.default.createElement(_reactIntlNext.FormattedMessage, {
119
122
  defaultMessage: "Where we work",
@@ -124,7 +127,8 @@ var TeamProfileCard = exports.TeamProfileCard = function TeamProfileCard(_ref3)
124
127
  userId: userId,
125
128
  cloudId: cloudId,
126
129
  components: {
127
- ContainerCard: _main.TeamConnections
130
+ ContainerCard: _main.TeamConnections,
131
+ TeamContainersSkeleton: _teamContainersSkeleton.TeamContainersSkeleton
128
132
  },
129
133
  filterContainerId: containerId,
130
134
  isDisplayedOnProfileCard: true
@@ -0,0 +1,3 @@
1
+
2
+ ._2rko1q77{border-radius:var(--ds-border-radius-400,1pc)}
3
+ ._1rjc1b66{padding-block:var(--ds-space-050,4px)}._1bsbvbgk{width:4pc}
@@ -0,0 +1,33 @@
1
+ /* index.tsx generated by @compiled/babel-plugin v0.36.1 */
2
+ "use strict";
3
+
4
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports.TeamContainersSkeleton = void 0;
9
+ require("./index.compiled.css");
10
+ var _runtime = require("@compiled/react/runtime");
11
+ var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers/toConsumableArray"));
12
+ var _react = _interopRequireDefault(require("react"));
13
+ var _compiled = require("@atlaskit/primitives/compiled");
14
+ var _linkedContainerCardSkeleton = require("./linked-container-card-skeleton");
15
+ var styles = {
16
+ showMoreButtonSkeleton: "_2rko1q77 _1rjc1b66 _1bsbvbgk"
17
+ };
18
+ var TeamContainersSkeleton = exports.TeamContainersSkeleton = function TeamContainersSkeleton(_ref) {
19
+ var numberOfContainers = _ref.numberOfContainers;
20
+ return /*#__PURE__*/_react.default.createElement(_compiled.Stack, {
21
+ space: "space.200",
22
+ testId: "profile-card-team-containers-skeleton"
23
+ }, /*#__PURE__*/_react.default.createElement(_compiled.Stack, {
24
+ space: "space.100"
25
+ }, (0, _toConsumableArray2.default)(Array(numberOfContainers)).map(function (_, index) {
26
+ return /*#__PURE__*/_react.default.createElement(_linkedContainerCardSkeleton.LinkedContainerCardSkeleton, {
27
+ key: index
28
+ });
29
+ })), /*#__PURE__*/_react.default.createElement(_compiled.Box, {
30
+ backgroundColor: "color.background.neutral",
31
+ xcss: styles.showMoreButtonSkeleton
32
+ }));
33
+ };
@@ -0,0 +1,17 @@
1
+
2
+ ._2rko1q77{border-radius:var(--ds-border-radius-400,1pc)}
3
+ ._2rkoiti9{border-radius:var(--ds-border-radius-100,4px)}
4
+ ._1h6dz9xs{border-color:var(--ds-border-accent-gray,#758195)}
5
+ ._1rjc1b66{padding-block:var(--ds-space-050,4px)}._12jimuej{outline-color:var(--ds-border,#091e4224)}
6
+ ._12y3e4h9{outline-width:var(--ds-border-width,1px)}
7
+ ._19bvu2gc{padding-left:var(--ds-space-100,8px)}
8
+ ._1bsb1tcg{width:24px}
9
+ ._1bsb7vkz{width:1pc}
10
+ ._1bsbqkoa{width:9pc}
11
+ ._1qu2nqa1{outline-style:solid}
12
+ ._4t3i1tcg{height:24px}
13
+ ._4t3i7vkz{height:1pc}
14
+ ._ca0qu2gc{padding-top:var(--ds-space-100,8px)}
15
+ ._n3tdu2gc{padding-bottom:var(--ds-space-100,8px)}
16
+ ._syaz1fxt{color:var(--ds-text,#172b4d)}
17
+ ._u5f3u2gc{padding-right:var(--ds-space-100,8px)}
@@ -0,0 +1,40 @@
1
+ /* index.tsx generated by @compiled/babel-plugin v0.36.1 */
2
+ "use strict";
3
+
4
+ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
5
+ Object.defineProperty(exports, "__esModule", {
6
+ value: true
7
+ });
8
+ exports.LinkedContainerCardSkeleton = void 0;
9
+ require("./index.compiled.css");
10
+ var _runtime = require("@compiled/react/runtime");
11
+ var _react = _interopRequireDefault(require("react"));
12
+ var _compiled = require("@atlaskit/primitives/compiled");
13
+ var styles = {
14
+ containerWrapperSkeleton: "_2rkoiti9 _1h6dz9xs _12y3e4h9 _12jimuej _1qu2nqa1 _syaz1fxt _ca0qu2gc _u5f3u2gc _n3tdu2gc _19bvu2gc",
15
+ containerIconSkeleton: "_2rkoiti9 _4t3i1tcg _1bsb1tcg _ca0qu2gc _u5f3u2gc _n3tdu2gc _19bvu2gc",
16
+ firstLineSkeleton: "_2rko1q77 _1rjc1b66",
17
+ secondLineSkeleton: "_2rko1q77 _1rjc1b66 _1bsbqkoa",
18
+ containerTypeIconSkeleton: "_2rkoiti9 _4t3i7vkz _1bsb7vkz _ca0qu2gc _u5f3u2gc _n3tdu2gc _19bvu2gc"
19
+ };
20
+ var LinkedContainerCardSkeleton = exports.LinkedContainerCardSkeleton = function LinkedContainerCardSkeleton() {
21
+ return /*#__PURE__*/_react.default.createElement(_compiled.Inline, {
22
+ space: "space.100",
23
+ xcss: styles.containerWrapperSkeleton
24
+ }, /*#__PURE__*/_react.default.createElement(_compiled.Box, {
25
+ xcss: styles.containerIconSkeleton,
26
+ backgroundColor: "color.background.neutral"
27
+ }), /*#__PURE__*/_react.default.createElement(_compiled.Stack, {
28
+ grow: "fill",
29
+ space: "space.050"
30
+ }, /*#__PURE__*/_react.default.createElement(_compiled.Box, {
31
+ xcss: styles.firstLineSkeleton,
32
+ backgroundColor: "color.background.neutral"
33
+ }), /*#__PURE__*/_react.default.createElement(_compiled.Box, {
34
+ xcss: styles.secondLineSkeleton,
35
+ backgroundColor: "color.background.neutral"
36
+ })), /*#__PURE__*/_react.default.createElement(_compiled.Box, {
37
+ xcss: styles.containerTypeIconSkeleton,
38
+ backgroundColor: "color.background.neutral"
39
+ }));
40
+ };
@@ -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: "23.6.7"
48
+ packageVersion: "23.7.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', "23.6.7");
9
+ headers.append('atl-client-version', "23.7.0");
10
10
  return headers;
11
11
  };
12
12
  export async function getOrgIdForCloudIdFromAGG(url, cloudId) {
@@ -75,7 +75,7 @@ export const addHeaders = headers => {
75
75
  headers.append('X-ExperimentalApi', 'teams-beta');
76
76
  headers.append('X-ExperimentalApi', 'team-members-beta');
77
77
  headers.append('atl-client-name', "@atlaskit/profilecard");
78
- headers.append('atl-client-version', "23.6.7");
78
+ headers.append('atl-client-version', "23.7.0");
79
79
  return headers;
80
80
  };
81
81
  export async function getTeamFromAGG(url, teamId, siteId) {
@@ -10,6 +10,7 @@ import { Box, Inline, Pressable, Stack, Text } from '@atlaskit/primitives/compil
10
10
  import TeamAvatar from '@atlaskit/teams-avatar';
11
11
  import { TeamContainers, useTeamContainers } from '@atlaskit/teams-public';
12
12
  import { TeamConnections } from './team-connections/main';
13
+ import { TeamContainersSkeleton } from './team-containers-skeleton';
13
14
  const noop = () => {};
14
15
  const styles = {
15
16
  wrapperStyles: "_2rkopd34 _v564nm7n _1reo15vq _18m915vq _189ee4h9 _1dqonqa1 _1h6dmuej _1e0c1txw _2lx21bp4 _1bsb1gwv _1ul95x59 _4t3i1wug",
@@ -17,7 +18,8 @@ const styles = {
17
18
  avatarImageStyles: "_kqswstnw _18u01ejb",
18
19
  headerImageStyles: "_5ral1dfr _s7n4jp4b _4t3i53f4 _1bsb1osq",
19
20
  teamInformationStyles: "_18u01ejb _19pku2gc _2hwx1ejb",
20
- teamConnectionStyles: "_18u01ejb _19pkpxbi _2hwx1ejb _c71lx2si _18m91wug",
21
+ teamConnectionHeaderStyles: "_18u01ejb _19pkpxbi _2hwx1ejb _c71lx2si _18m91wug",
22
+ teamConnectionContainerStyles: "_18u01ejb _2hwx1ejb",
21
23
  viewProfileContainerStyles: "_4cvr1h6o _uwhke4h9 _15a5nqa1 _1i53muej _19bv1ejb _u5f31ejb",
22
24
  viewProfileButtonStyles: "_2rkoiti9 _189ee4h9 _1dqonqa1 _1h6dmuej _bfhksm61 _syaz1gjq _1bsb1osq _4t3i1ul9 _19pkpxbi"
23
25
  };
@@ -52,7 +54,8 @@ export const TeamProfileCard = ({
52
54
  teamProfileUrl
53
55
  }) => {
54
56
  const {
55
- teamContainers
57
+ teamContainers,
58
+ loading
56
59
  } = useTeamContainers(teamId);
57
60
  // Ensure that the current container is not the only connection for this team before showing the "Where we work" section
58
61
  const hasOtherTeamConnections = useMemo(() => teamContainers.filter(tc => tc.id === containerId).length < teamContainers.length, [containerId, teamContainers]);
@@ -96,10 +99,10 @@ export const TeamProfileCard = ({
96
99
  })), description && /*#__PURE__*/React.createElement(Text, {
97
100
  color: "color.text",
98
101
  maxLines: 3
99
- }, description)), hasOtherTeamConnections && /*#__PURE__*/React.createElement(Stack, {
100
- xcss: styles.teamConnectionStyles,
101
- space: "space.200"
102
- }, /*#__PURE__*/React.createElement(Heading, {
102
+ }, description)), (loading || hasOtherTeamConnections) && /*#__PURE__*/React.createElement(Stack, {
103
+ space: 'space.200',
104
+ xcss: hasOtherTeamConnections ? styles.teamConnectionHeaderStyles : styles.teamConnectionContainerStyles
105
+ }, hasOtherTeamConnections && /*#__PURE__*/React.createElement(Heading, {
103
106
  size: "xxsmall"
104
107
  }, /*#__PURE__*/React.createElement(FormattedMessage, {
105
108
  defaultMessage: "Where we work",
@@ -110,7 +113,8 @@ export const TeamProfileCard = ({
110
113
  userId: userId,
111
114
  cloudId: cloudId,
112
115
  components: {
113
- ContainerCard: TeamConnections
116
+ ContainerCard: TeamConnections,
117
+ TeamContainersSkeleton: TeamContainersSkeleton
114
118
  },
115
119
  filterContainerId: containerId,
116
120
  isDisplayedOnProfileCard: true
@@ -0,0 +1,3 @@
1
+
2
+ ._2rko1q77{border-radius:var(--ds-border-radius-400,1pc)}
3
+ ._1rjc1b66{padding-block:var(--ds-space-050,4px)}._1bsbvbgk{width:4pc}
@@ -0,0 +1,24 @@
1
+ /* index.tsx generated by @compiled/babel-plugin v0.36.1 */
2
+ import "./index.compiled.css";
3
+ import { ax, ix } from "@compiled/react/runtime";
4
+ import React from 'react';
5
+ import { Box, Stack } from '@atlaskit/primitives/compiled';
6
+ import { LinkedContainerCardSkeleton } from './linked-container-card-skeleton';
7
+ const styles = {
8
+ showMoreButtonSkeleton: "_2rko1q77 _1rjc1b66 _1bsbvbgk"
9
+ };
10
+ export const TeamContainersSkeleton = ({
11
+ numberOfContainers
12
+ }) => {
13
+ return /*#__PURE__*/React.createElement(Stack, {
14
+ space: "space.200",
15
+ testId: "profile-card-team-containers-skeleton"
16
+ }, /*#__PURE__*/React.createElement(Stack, {
17
+ space: "space.100"
18
+ }, [...Array(numberOfContainers)].map((_, index) => /*#__PURE__*/React.createElement(LinkedContainerCardSkeleton, {
19
+ key: index
20
+ }))), /*#__PURE__*/React.createElement(Box, {
21
+ backgroundColor: "color.background.neutral",
22
+ xcss: styles.showMoreButtonSkeleton
23
+ }));
24
+ };
@@ -0,0 +1,17 @@
1
+
2
+ ._2rko1q77{border-radius:var(--ds-border-radius-400,1pc)}
3
+ ._2rkoiti9{border-radius:var(--ds-border-radius-100,4px)}
4
+ ._1h6dz9xs{border-color:var(--ds-border-accent-gray,#758195)}
5
+ ._1rjc1b66{padding-block:var(--ds-space-050,4px)}._12jimuej{outline-color:var(--ds-border,#091e4224)}
6
+ ._12y3e4h9{outline-width:var(--ds-border-width,1px)}
7
+ ._19bvu2gc{padding-left:var(--ds-space-100,8px)}
8
+ ._1bsb1tcg{width:24px}
9
+ ._1bsb7vkz{width:1pc}
10
+ ._1bsbqkoa{width:9pc}
11
+ ._1qu2nqa1{outline-style:solid}
12
+ ._4t3i1tcg{height:24px}
13
+ ._4t3i7vkz{height:1pc}
14
+ ._ca0qu2gc{padding-top:var(--ds-space-100,8px)}
15
+ ._n3tdu2gc{padding-bottom:var(--ds-space-100,8px)}
16
+ ._syaz1fxt{color:var(--ds-text,#172b4d)}
17
+ ._u5f3u2gc{padding-right:var(--ds-space-100,8px)}
@@ -0,0 +1,33 @@
1
+ /* index.tsx generated by @compiled/babel-plugin v0.36.1 */
2
+ import "./index.compiled.css";
3
+ import { ax, ix } from "@compiled/react/runtime";
4
+ import React from 'react';
5
+ import { Box, Inline, Stack } from '@atlaskit/primitives/compiled';
6
+ const styles = {
7
+ containerWrapperSkeleton: "_2rkoiti9 _1h6dz9xs _12y3e4h9 _12jimuej _1qu2nqa1 _syaz1fxt _ca0qu2gc _u5f3u2gc _n3tdu2gc _19bvu2gc",
8
+ containerIconSkeleton: "_2rkoiti9 _4t3i1tcg _1bsb1tcg _ca0qu2gc _u5f3u2gc _n3tdu2gc _19bvu2gc",
9
+ firstLineSkeleton: "_2rko1q77 _1rjc1b66",
10
+ secondLineSkeleton: "_2rko1q77 _1rjc1b66 _1bsbqkoa",
11
+ containerTypeIconSkeleton: "_2rkoiti9 _4t3i7vkz _1bsb7vkz _ca0qu2gc _u5f3u2gc _n3tdu2gc _19bvu2gc"
12
+ };
13
+ export const LinkedContainerCardSkeleton = () => {
14
+ return /*#__PURE__*/React.createElement(Inline, {
15
+ space: "space.100",
16
+ xcss: styles.containerWrapperSkeleton
17
+ }, /*#__PURE__*/React.createElement(Box, {
18
+ xcss: styles.containerIconSkeleton,
19
+ backgroundColor: "color.background.neutral"
20
+ }), /*#__PURE__*/React.createElement(Stack, {
21
+ grow: "fill",
22
+ space: "space.050"
23
+ }, /*#__PURE__*/React.createElement(Box, {
24
+ xcss: styles.firstLineSkeleton,
25
+ backgroundColor: "color.background.neutral"
26
+ }), /*#__PURE__*/React.createElement(Box, {
27
+ xcss: styles.secondLineSkeleton,
28
+ backgroundColor: "color.background.neutral"
29
+ })), /*#__PURE__*/React.createElement(Box, {
30
+ xcss: styles.containerTypeIconSkeleton,
31
+ backgroundColor: "color.background.neutral"
32
+ }));
33
+ };
@@ -32,7 +32,7 @@ const createEvent = (eventType, action, actionSubject, actionSubjectId, attribut
32
32
  actionSubjectId,
33
33
  attributes: {
34
34
  packageName: "@atlaskit/profilecard",
35
- packageVersion: "23.6.7",
35
+ packageVersion: "23.7.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', "23.6.7");
7
+ headers.append('atl-client-version', "23.7.0");
8
8
  return headers;
9
9
  };
10
10
  export function getOrgIdForCloudIdFromAGG(_x, _x2) {
@@ -57,7 +57,7 @@ export var addHeaders = function addHeaders(headers) {
57
57
  headers.append('X-ExperimentalApi', 'teams-beta');
58
58
  headers.append('X-ExperimentalApi', 'team-members-beta');
59
59
  headers.append('atl-client-name', "@atlaskit/profilecard");
60
- headers.append('atl-client-version', "23.6.7");
60
+ headers.append('atl-client-version', "23.7.0");
61
61
  return headers;
62
62
  };
63
63
  export function getTeamFromAGG(_x, _x2, _x3) {
@@ -10,6 +10,7 @@ import { Box, Inline, Pressable, Stack, Text } from '@atlaskit/primitives/compil
10
10
  import TeamAvatar from '@atlaskit/teams-avatar';
11
11
  import { TeamContainers, useTeamContainers } from '@atlaskit/teams-public';
12
12
  import { TeamConnections } from './team-connections/main';
13
+ import { TeamContainersSkeleton } from './team-containers-skeleton';
13
14
  var noop = function noop() {};
14
15
  var styles = {
15
16
  wrapperStyles: "_2rkopd34 _v564nm7n _1reo15vq _18m915vq _189ee4h9 _1dqonqa1 _1h6dmuej _1e0c1txw _2lx21bp4 _1bsb1gwv _1ul95x59 _4t3i1wug",
@@ -17,7 +18,8 @@ var styles = {
17
18
  avatarImageStyles: "_kqswstnw _18u01ejb",
18
19
  headerImageStyles: "_5ral1dfr _s7n4jp4b _4t3i53f4 _1bsb1osq",
19
20
  teamInformationStyles: "_18u01ejb _19pku2gc _2hwx1ejb",
20
- teamConnectionStyles: "_18u01ejb _19pkpxbi _2hwx1ejb _c71lx2si _18m91wug",
21
+ teamConnectionHeaderStyles: "_18u01ejb _19pkpxbi _2hwx1ejb _c71lx2si _18m91wug",
22
+ teamConnectionContainerStyles: "_18u01ejb _2hwx1ejb",
21
23
  viewProfileContainerStyles: "_4cvr1h6o _uwhke4h9 _15a5nqa1 _1i53muej _19bv1ejb _u5f31ejb",
22
24
  viewProfileButtonStyles: "_2rkoiti9 _189ee4h9 _1dqonqa1 _1h6dmuej _bfhksm61 _syaz1gjq _1bsb1osq _4t3i1ul9 _19pkpxbi"
23
25
  };
@@ -53,7 +55,8 @@ export var TeamProfileCard = function TeamProfileCard(_ref3) {
53
55
  isVerified = _ref3.isVerified,
54
56
  teamProfileUrl = _ref3.teamProfileUrl;
55
57
  var _useTeamContainers = useTeamContainers(teamId),
56
- teamContainers = _useTeamContainers.teamContainers;
58
+ teamContainers = _useTeamContainers.teamContainers,
59
+ loading = _useTeamContainers.loading;
57
60
  // Ensure that the current container is not the only connection for this team before showing the "Where we work" section
58
61
  var hasOtherTeamConnections = useMemo(function () {
59
62
  return teamContainers.filter(function (tc) {
@@ -100,10 +103,10 @@ export var TeamProfileCard = function TeamProfileCard(_ref3) {
100
103
  })), description && /*#__PURE__*/React.createElement(Text, {
101
104
  color: "color.text",
102
105
  maxLines: 3
103
- }, description)), hasOtherTeamConnections && /*#__PURE__*/React.createElement(Stack, {
104
- xcss: styles.teamConnectionStyles,
105
- space: "space.200"
106
- }, /*#__PURE__*/React.createElement(Heading, {
106
+ }, description)), (loading || hasOtherTeamConnections) && /*#__PURE__*/React.createElement(Stack, {
107
+ space: 'space.200',
108
+ xcss: hasOtherTeamConnections ? styles.teamConnectionHeaderStyles : styles.teamConnectionContainerStyles
109
+ }, hasOtherTeamConnections && /*#__PURE__*/React.createElement(Heading, {
107
110
  size: "xxsmall"
108
111
  }, /*#__PURE__*/React.createElement(FormattedMessage, {
109
112
  defaultMessage: "Where we work",
@@ -114,7 +117,8 @@ export var TeamProfileCard = function TeamProfileCard(_ref3) {
114
117
  userId: userId,
115
118
  cloudId: cloudId,
116
119
  components: {
117
- ContainerCard: TeamConnections
120
+ ContainerCard: TeamConnections,
121
+ TeamContainersSkeleton: TeamContainersSkeleton
118
122
  },
119
123
  filterContainerId: containerId,
120
124
  isDisplayedOnProfileCard: true
@@ -0,0 +1,3 @@
1
+
2
+ ._2rko1q77{border-radius:var(--ds-border-radius-400,1pc)}
3
+ ._1rjc1b66{padding-block:var(--ds-space-050,4px)}._1bsbvbgk{width:4pc}
@@ -0,0 +1,26 @@
1
+ /* index.tsx generated by @compiled/babel-plugin v0.36.1 */
2
+ import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
3
+ import "./index.compiled.css";
4
+ import { ax, ix } from "@compiled/react/runtime";
5
+ import React from 'react';
6
+ import { Box, Stack } from '@atlaskit/primitives/compiled';
7
+ import { LinkedContainerCardSkeleton } from './linked-container-card-skeleton';
8
+ var styles = {
9
+ showMoreButtonSkeleton: "_2rko1q77 _1rjc1b66 _1bsbvbgk"
10
+ };
11
+ export var TeamContainersSkeleton = function TeamContainersSkeleton(_ref) {
12
+ var numberOfContainers = _ref.numberOfContainers;
13
+ return /*#__PURE__*/React.createElement(Stack, {
14
+ space: "space.200",
15
+ testId: "profile-card-team-containers-skeleton"
16
+ }, /*#__PURE__*/React.createElement(Stack, {
17
+ space: "space.100"
18
+ }, _toConsumableArray(Array(numberOfContainers)).map(function (_, index) {
19
+ return /*#__PURE__*/React.createElement(LinkedContainerCardSkeleton, {
20
+ key: index
21
+ });
22
+ })), /*#__PURE__*/React.createElement(Box, {
23
+ backgroundColor: "color.background.neutral",
24
+ xcss: styles.showMoreButtonSkeleton
25
+ }));
26
+ };
@@ -0,0 +1,17 @@
1
+
2
+ ._2rko1q77{border-radius:var(--ds-border-radius-400,1pc)}
3
+ ._2rkoiti9{border-radius:var(--ds-border-radius-100,4px)}
4
+ ._1h6dz9xs{border-color:var(--ds-border-accent-gray,#758195)}
5
+ ._1rjc1b66{padding-block:var(--ds-space-050,4px)}._12jimuej{outline-color:var(--ds-border,#091e4224)}
6
+ ._12y3e4h9{outline-width:var(--ds-border-width,1px)}
7
+ ._19bvu2gc{padding-left:var(--ds-space-100,8px)}
8
+ ._1bsb1tcg{width:24px}
9
+ ._1bsb7vkz{width:1pc}
10
+ ._1bsbqkoa{width:9pc}
11
+ ._1qu2nqa1{outline-style:solid}
12
+ ._4t3i1tcg{height:24px}
13
+ ._4t3i7vkz{height:1pc}
14
+ ._ca0qu2gc{padding-top:var(--ds-space-100,8px)}
15
+ ._n3tdu2gc{padding-bottom:var(--ds-space-100,8px)}
16
+ ._syaz1fxt{color:var(--ds-text,#172b4d)}
17
+ ._u5f3u2gc{padding-right:var(--ds-space-100,8px)}
@@ -0,0 +1,33 @@
1
+ /* index.tsx generated by @compiled/babel-plugin v0.36.1 */
2
+ import "./index.compiled.css";
3
+ import { ax, ix } from "@compiled/react/runtime";
4
+ import React from 'react';
5
+ import { Box, Inline, Stack } from '@atlaskit/primitives/compiled';
6
+ var styles = {
7
+ containerWrapperSkeleton: "_2rkoiti9 _1h6dz9xs _12y3e4h9 _12jimuej _1qu2nqa1 _syaz1fxt _ca0qu2gc _u5f3u2gc _n3tdu2gc _19bvu2gc",
8
+ containerIconSkeleton: "_2rkoiti9 _4t3i1tcg _1bsb1tcg _ca0qu2gc _u5f3u2gc _n3tdu2gc _19bvu2gc",
9
+ firstLineSkeleton: "_2rko1q77 _1rjc1b66",
10
+ secondLineSkeleton: "_2rko1q77 _1rjc1b66 _1bsbqkoa",
11
+ containerTypeIconSkeleton: "_2rkoiti9 _4t3i7vkz _1bsb7vkz _ca0qu2gc _u5f3u2gc _n3tdu2gc _19bvu2gc"
12
+ };
13
+ export var LinkedContainerCardSkeleton = function LinkedContainerCardSkeleton() {
14
+ return /*#__PURE__*/React.createElement(Inline, {
15
+ space: "space.100",
16
+ xcss: styles.containerWrapperSkeleton
17
+ }, /*#__PURE__*/React.createElement(Box, {
18
+ xcss: styles.containerIconSkeleton,
19
+ backgroundColor: "color.background.neutral"
20
+ }), /*#__PURE__*/React.createElement(Stack, {
21
+ grow: "fill",
22
+ space: "space.050"
23
+ }, /*#__PURE__*/React.createElement(Box, {
24
+ xcss: styles.firstLineSkeleton,
25
+ backgroundColor: "color.background.neutral"
26
+ }), /*#__PURE__*/React.createElement(Box, {
27
+ xcss: styles.secondLineSkeleton,
28
+ backgroundColor: "color.background.neutral"
29
+ })), /*#__PURE__*/React.createElement(Box, {
30
+ xcss: styles.containerTypeIconSkeleton,
31
+ backgroundColor: "color.background.neutral"
32
+ }));
33
+ };
@@ -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: "23.6.7"
42
+ packageVersion: "23.7.0"
43
43
  }, attributes), {}, {
44
44
  firedAt: Math.round(getPageTime())
45
45
  })
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ import type { TeamContainersSkeletonProps } from '@atlaskit/teams-public';
3
+ export declare const TeamContainersSkeleton: ({ numberOfContainers }: TeamContainersSkeletonProps) => React.JSX.Element;
@@ -0,0 +1,2 @@
1
+ import React from 'react';
2
+ export declare const LinkedContainerCardSkeleton: () => React.JSX.Element;
@@ -0,0 +1,3 @@
1
+ import React from 'react';
2
+ import type { TeamContainersSkeletonProps } from '@atlaskit/teams-public';
3
+ export declare const TeamContainersSkeleton: ({ numberOfContainers }: TeamContainersSkeletonProps) => React.JSX.Element;
@@ -0,0 +1,2 @@
1
+ import React from 'react';
2
+ export declare const LinkedContainerCardSkeleton: () => React.JSX.Element;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/profilecard",
3
- "version": "23.6.7",
3
+ "version": "23.7.0",
4
4
  "description": "A React component to display a card with user information.",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -74,7 +74,7 @@
74
74
  "@atlaskit/rovo-triggers": "^2.7.0",
75
75
  "@atlaskit/spinner": "^18.0.0",
76
76
  "@atlaskit/teams-avatar": "^2.3.0",
77
- "@atlaskit/teams-public": "^0.21.0",
77
+ "@atlaskit/teams-public": "^0.22.0",
78
78
  "@atlaskit/theme": "^18.0.0",
79
79
  "@atlaskit/tokens": "^4.5.0",
80
80
  "@atlaskit/tooltip": "^20.0.0",