@atlaskit/teams-public 2.5.0 → 2.5.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 +14 -0
- package/dist/cjs/common/ui/container-icon/index.js +1 -1
- package/dist/cjs/common/ui/loom-avatar/main.js +1 -1
- package/dist/cjs/common/ui/separator/index.js +1 -1
- package/dist/cjs/common/ui/team-containers-skeleton/index.compiled.css +0 -1
- package/dist/cjs/common/ui/team-containers-skeleton/index.js +1 -1
- package/dist/cjs/common/ui/team-containers-skeleton/linked-container-card-skeleton/index.compiled.css +0 -1
- package/dist/cjs/common/ui/team-containers-skeleton/linked-container-card-skeleton/index.js +1 -1
- package/dist/cjs/common/ui/team-link-card-actions/index.js +1 -1
- package/dist/cjs/common/utils/get-container-properties.compiled.css +0 -1
- package/dist/cjs/common/utils/get-container-properties.js +1 -1
- package/dist/cjs/next/common/ui/team-container-skeleton/index.js +1 -1
- package/dist/cjs/next/ui/team-containers/add-container-card/index.compiled.css +0 -1
- package/dist/cjs/next/ui/team-containers/add-container-card/index.js +1 -1
- package/dist/cjs/next/ui/team-containers/team-link-card/index.compiled.css +0 -1
- package/dist/cjs/next/ui/team-containers/team-link-card/index.js +1 -1
- package/dist/cjs/ui/team-containers/add-container-card/index.compiled.css +0 -1
- package/dist/cjs/ui/team-containers/add-container-card/index.js +16 -7
- package/dist/cjs/ui/team-containers/main.js +18 -5
- package/dist/cjs/ui/team-containers/no-product-access-empty-state/index.compiled.css +0 -1
- package/dist/cjs/ui/team-containers/no-product-access-empty-state/index.js +1 -1
- package/dist/cjs/ui/team-containers/no-product-access-empty-state/no-product-access-icon/index.js +1 -1
- package/dist/cjs/ui/team-containers/team-link-card/index.compiled.css +0 -1
- package/dist/cjs/ui/team-containers/team-link-card/index.js +1 -1
- package/dist/cjs/ui/team-containers/team-link-card/team-link-card-title.compiled.css +0 -1
- package/dist/cjs/ui/team-containers/team-link-card/team-link-card-title.js +1 -1
- package/dist/es2019/common/ui/container-icon/index.js +1 -1
- package/dist/es2019/common/ui/loom-avatar/main.js +1 -1
- package/dist/es2019/common/ui/separator/index.js +1 -1
- package/dist/es2019/common/ui/team-containers-skeleton/index.compiled.css +0 -1
- package/dist/es2019/common/ui/team-containers-skeleton/index.js +1 -1
- package/dist/es2019/common/ui/team-containers-skeleton/linked-container-card-skeleton/index.compiled.css +0 -1
- package/dist/es2019/common/ui/team-containers-skeleton/linked-container-card-skeleton/index.js +1 -1
- package/dist/es2019/common/ui/team-link-card-actions/index.js +1 -1
- package/dist/es2019/common/utils/get-container-properties.compiled.css +0 -1
- package/dist/es2019/common/utils/get-container-properties.js +1 -1
- package/dist/es2019/next/common/ui/team-container-skeleton/index.js +1 -1
- package/dist/es2019/next/ui/team-containers/add-container-card/index.compiled.css +0 -1
- package/dist/es2019/next/ui/team-containers/add-container-card/index.js +1 -1
- package/dist/es2019/next/ui/team-containers/team-link-card/index.compiled.css +0 -1
- package/dist/es2019/next/ui/team-containers/team-link-card/index.js +1 -1
- package/dist/es2019/ui/team-containers/add-container-card/index.compiled.css +0 -1
- package/dist/es2019/ui/team-containers/add-container-card/index.js +16 -7
- package/dist/es2019/ui/team-containers/main.js +19 -6
- package/dist/es2019/ui/team-containers/no-product-access-empty-state/index.compiled.css +0 -1
- package/dist/es2019/ui/team-containers/no-product-access-empty-state/index.js +1 -1
- package/dist/es2019/ui/team-containers/no-product-access-empty-state/no-product-access-icon/index.js +1 -1
- package/dist/es2019/ui/team-containers/team-link-card/index.compiled.css +0 -1
- package/dist/es2019/ui/team-containers/team-link-card/index.js +1 -1
- package/dist/es2019/ui/team-containers/team-link-card/team-link-card-title.compiled.css +0 -1
- package/dist/es2019/ui/team-containers/team-link-card/team-link-card-title.js +1 -1
- package/dist/esm/common/ui/container-icon/index.js +1 -1
- package/dist/esm/common/ui/loom-avatar/main.js +1 -1
- package/dist/esm/common/ui/separator/index.js +1 -1
- package/dist/esm/common/ui/team-containers-skeleton/index.compiled.css +0 -1
- package/dist/esm/common/ui/team-containers-skeleton/index.js +1 -1
- package/dist/esm/common/ui/team-containers-skeleton/linked-container-card-skeleton/index.compiled.css +0 -1
- package/dist/esm/common/ui/team-containers-skeleton/linked-container-card-skeleton/index.js +1 -1
- package/dist/esm/common/ui/team-link-card-actions/index.js +1 -1
- package/dist/esm/common/utils/get-container-properties.compiled.css +0 -1
- package/dist/esm/common/utils/get-container-properties.js +1 -1
- package/dist/esm/next/common/ui/team-container-skeleton/index.js +1 -1
- package/dist/esm/next/ui/team-containers/add-container-card/index.compiled.css +0 -1
- package/dist/esm/next/ui/team-containers/add-container-card/index.js +1 -1
- package/dist/esm/next/ui/team-containers/team-link-card/index.compiled.css +0 -1
- package/dist/esm/next/ui/team-containers/team-link-card/index.js +1 -1
- package/dist/esm/ui/team-containers/add-container-card/index.compiled.css +0 -1
- package/dist/esm/ui/team-containers/add-container-card/index.js +16 -7
- package/dist/esm/ui/team-containers/main.js +19 -6
- package/dist/esm/ui/team-containers/no-product-access-empty-state/index.compiled.css +0 -1
- package/dist/esm/ui/team-containers/no-product-access-empty-state/index.js +1 -1
- package/dist/esm/ui/team-containers/no-product-access-empty-state/no-product-access-icon/index.js +1 -1
- package/dist/esm/ui/team-containers/team-link-card/index.compiled.css +0 -1
- package/dist/esm/ui/team-containers/team-link-card/index.js +1 -1
- package/dist/esm/ui/team-containers/team-link-card/team-link-card-title.compiled.css +0 -1
- package/dist/esm/ui/team-containers/team-link-card/team-link-card-title.js +1 -1
- package/dist/types/common/types.d.ts +2 -2
- package/dist/types/controllers/product-permission/types.d.ts +1 -1
- package/dist/types/ui/team-containers/add-container-card/index.d.ts +2 -1
- package/package.json +15 -12
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,19 @@
|
|
|
1
1
|
# @atlaskit/teams-public
|
|
2
2
|
|
|
3
|
+
## 2.5.2
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- Updated dependencies
|
|
8
|
+
|
|
9
|
+
## 2.5.1
|
|
10
|
+
|
|
11
|
+
### Patch Changes
|
|
12
|
+
|
|
13
|
+
- [`92b3f332e1a93`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/92b3f332e1a93) -
|
|
14
|
+
A11Y-34709: Add unordered list semantics to Team link add-container cards section (gated
|
|
15
|
+
teams-a11y-34974-34752-34709)
|
|
16
|
+
|
|
3
17
|
## 2.5.0
|
|
4
18
|
|
|
5
19
|
### Minor Changes
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* index.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* index.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
"use strict";
|
|
3
3
|
|
|
4
4
|
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
@@ -110,34 +110,43 @@ var getAddContainerCards = exports.getAddContainerCards = function getAddContain
|
|
|
110
110
|
var containers = _ref3.containers,
|
|
111
111
|
_onAddAContainerClick = _ref3.onAddAContainerClick,
|
|
112
112
|
CustomAddContainerCard = _ref3.CustomAddContainerCard,
|
|
113
|
-
canCreateContainers = _ref3.canCreateContainers
|
|
113
|
+
canCreateContainers = _ref3.canCreateContainers,
|
|
114
|
+
isTeamsA11yGateEnabled = _ref3.isTeamsA11yGateEnabled;
|
|
114
115
|
var AddContainerCardComponent = CustomAddContainerCard !== null && CustomAddContainerCard !== void 0 ? CustomAddContainerCard : AddContainerCard;
|
|
115
|
-
|
|
116
|
+
var renderCard = function renderCard(key, card) {
|
|
117
|
+
return isTeamsA11yGateEnabled ? /*#__PURE__*/_react.default.createElement(_compiled.Box, {
|
|
118
|
+
key: key,
|
|
119
|
+
role: "listitem"
|
|
120
|
+
}, card) : /*#__PURE__*/_react.default.createElement(_react.default.Fragment, {
|
|
121
|
+
key: key
|
|
122
|
+
}, card);
|
|
123
|
+
};
|
|
124
|
+
return /*#__PURE__*/_react.default.createElement(_react.default.Fragment, null, containers.Jira.canAdd && renderCard('jira-add-container', /*#__PURE__*/_react.default.createElement(AddContainerCardComponent, {
|
|
116
125
|
onAddAContainerClick: function onAddAContainerClick(e) {
|
|
117
126
|
return _onAddAContainerClick(e, 'Jira');
|
|
118
127
|
},
|
|
119
128
|
containerType: "JiraProject",
|
|
120
129
|
isLoading: containers.Jira.isLoading,
|
|
121
130
|
canCreateContainers: canCreateContainers
|
|
122
|
-
}), containers.Confluence.canAdd && /*#__PURE__*/_react.default.createElement(AddContainerCardComponent, {
|
|
131
|
+
})), containers.Confluence.canAdd && renderCard('confluence-add-container', /*#__PURE__*/_react.default.createElement(AddContainerCardComponent, {
|
|
123
132
|
onAddAContainerClick: function onAddAContainerClick(e) {
|
|
124
133
|
return _onAddAContainerClick(e, 'Confluence');
|
|
125
134
|
},
|
|
126
135
|
containerType: "ConfluenceSpace",
|
|
127
136
|
isLoading: containers.Confluence.isLoading,
|
|
128
137
|
canCreateContainers: canCreateContainers
|
|
129
|
-
}), containers.Loom.canAdd && /*#__PURE__*/_react.default.createElement(AddContainerCardComponent, {
|
|
138
|
+
})), containers.Loom.canAdd && renderCard('loom-add-container', /*#__PURE__*/_react.default.createElement(AddContainerCardComponent, {
|
|
130
139
|
onAddAContainerClick: function onAddAContainerClick(e) {
|
|
131
140
|
return _onAddAContainerClick(e, 'Loom');
|
|
132
141
|
},
|
|
133
142
|
containerType: "LoomSpace",
|
|
134
143
|
isLoading: containers.Loom.isLoading,
|
|
135
144
|
canCreateContainers: canCreateContainers
|
|
136
|
-
}), containers.WebLink.canAdd && /*#__PURE__*/_react.default.createElement(AddContainerCardComponent, {
|
|
145
|
+
})), containers.WebLink.canAdd && renderCard('weblink-add-container', /*#__PURE__*/_react.default.createElement(AddContainerCardComponent, {
|
|
137
146
|
onAddAContainerClick: function onAddAContainerClick(e) {
|
|
138
147
|
return _onAddAContainerClick(e, 'WebLink');
|
|
139
148
|
},
|
|
140
149
|
containerType: "WebLink",
|
|
141
150
|
canCreateContainers: canCreateContainers
|
|
142
|
-
}));
|
|
151
|
+
})));
|
|
143
152
|
};
|
|
@@ -7,6 +7,7 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
});
|
|
8
8
|
exports.TeamContainers = exports.MAX_NUMBER_OF_CONTAINERS_TO_SHOW = exports.ICON_COLOR = exports.ICON_BACKGROUND = void 0;
|
|
9
9
|
var _regenerator = _interopRequireDefault(require("@babel/runtime/regenerator"));
|
|
10
|
+
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
10
11
|
var _asyncToGenerator2 = _interopRequireDefault(require("@babel/runtime/helpers/asyncToGenerator"));
|
|
11
12
|
var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
|
|
12
13
|
var _react = _interopRequireWildcard(require("react"));
|
|
@@ -296,14 +297,17 @@ var TeamContainers = exports.TeamContainers = function TeamContainers(_ref) {
|
|
|
296
297
|
space: "space.200"
|
|
297
298
|
}, function () {
|
|
298
299
|
var GridComponent = (components === null || components === void 0 ? void 0 : components.Grid) || _primitives.Grid;
|
|
299
|
-
|
|
300
|
+
var isTeamsA11yGateEnabled = (0, _platformFeatureFlags.fg)('teams-a11y-34974-34752-34709');
|
|
301
|
+
return /*#__PURE__*/_react.default.createElement(GridComponent, (0, _extends2.default)({
|
|
300
302
|
templateColumns: "repeat(auto-fill, minmax(300px, 1fr))",
|
|
301
303
|
gap: isDisplayedOnProfileCard ? 'space.0' : 'space.100'
|
|
302
|
-
},
|
|
304
|
+
}, isTeamsA11yGateEnabled && {
|
|
305
|
+
role: 'list'
|
|
306
|
+
}), elemBeforeCards && function () {
|
|
303
307
|
var ElemBeforeCards = elemBeforeCards;
|
|
304
308
|
return /*#__PURE__*/_react.default.createElement(ElemBeforeCards, null);
|
|
305
309
|
}(), filteredTeamLinks.slice(0, maxNumberOfContainersToShow).map(function (container) {
|
|
306
|
-
|
|
310
|
+
var card = /*#__PURE__*/_react.default.createElement(LinkedContainerCardComponent, {
|
|
307
311
|
key: container.id,
|
|
308
312
|
containerType: container.type,
|
|
309
313
|
containerTypeProperties: container.containerTypeProperties,
|
|
@@ -324,13 +328,18 @@ var TeamContainers = exports.TeamContainers = function TeamContainers(_ref) {
|
|
|
324
328
|
return handleEditContainerClick(container);
|
|
325
329
|
}
|
|
326
330
|
});
|
|
331
|
+
return isTeamsA11yGateEnabled ? /*#__PURE__*/_react.default.createElement(_compiled.Box, {
|
|
332
|
+
key: container.id,
|
|
333
|
+
role: "listitem"
|
|
334
|
+
}, card) : card;
|
|
327
335
|
}), (0, _addContainerCard.getAddContainerCards)({
|
|
328
336
|
containers: availableContainers,
|
|
329
337
|
onAddAContainerClick: onAddAContainerClick,
|
|
330
338
|
CustomAddContainerCard: components === null || components === void 0 ? void 0 : components.AddContainerCard,
|
|
331
|
-
canCreateContainers: hasPermissionToCreateContainer
|
|
339
|
+
canCreateContainers: hasPermissionToCreateContainer,
|
|
340
|
+
isTeamsA11yGateEnabled: isTeamsA11yGateEnabled
|
|
332
341
|
}), showMore && filteredTeamLinks.slice(maxNumberOfContainersToShow).map(function (container) {
|
|
333
|
-
|
|
342
|
+
var card = /*#__PURE__*/_react.default.createElement(LinkedContainerCardComponent, {
|
|
334
343
|
key: container.id,
|
|
335
344
|
containerType: container.type,
|
|
336
345
|
containerTypeProperties: container.containerTypeProperties,
|
|
@@ -351,6 +360,10 @@ var TeamContainers = exports.TeamContainers = function TeamContainers(_ref) {
|
|
|
351
360
|
return handleEditContainerClick(container);
|
|
352
361
|
}
|
|
353
362
|
});
|
|
363
|
+
return isTeamsA11yGateEnabled ? /*#__PURE__*/_react.default.createElement(_compiled.Box, {
|
|
364
|
+
key: container.id,
|
|
365
|
+
role: "listitem"
|
|
366
|
+
}, card) : card;
|
|
354
367
|
}));
|
|
355
368
|
}(), filteredTeamLinks.length > maxNumberOfContainersToShow && /*#__PURE__*/_react.default.createElement(_compiled.Inline, null, /*#__PURE__*/_react.default.createElement(_new.default, {
|
|
356
369
|
appearance: "subtle",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* get-container-properties.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* get-container-properties.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import "./get-container-properties.compiled.css";
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* index.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* index.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import "./index.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
@@ -92,27 +92,36 @@ export const getAddContainerCards = ({
|
|
|
92
92
|
containers,
|
|
93
93
|
onAddAContainerClick,
|
|
94
94
|
CustomAddContainerCard,
|
|
95
|
-
canCreateContainers
|
|
95
|
+
canCreateContainers,
|
|
96
|
+
isTeamsA11yGateEnabled
|
|
96
97
|
}) => {
|
|
97
98
|
const AddContainerCardComponent = CustomAddContainerCard !== null && CustomAddContainerCard !== void 0 ? CustomAddContainerCard : AddContainerCard;
|
|
98
|
-
|
|
99
|
+
const renderCard = (key, card) => {
|
|
100
|
+
return isTeamsA11yGateEnabled ? /*#__PURE__*/React.createElement(Box, {
|
|
101
|
+
key: key,
|
|
102
|
+
role: "listitem"
|
|
103
|
+
}, card) : /*#__PURE__*/React.createElement(React.Fragment, {
|
|
104
|
+
key: key
|
|
105
|
+
}, card);
|
|
106
|
+
};
|
|
107
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, containers.Jira.canAdd && renderCard('jira-add-container', /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
99
108
|
onAddAContainerClick: e => onAddAContainerClick(e, 'Jira'),
|
|
100
109
|
containerType: "JiraProject",
|
|
101
110
|
isLoading: containers.Jira.isLoading,
|
|
102
111
|
canCreateContainers: canCreateContainers
|
|
103
|
-
}), containers.Confluence.canAdd && /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
112
|
+
})), containers.Confluence.canAdd && renderCard('confluence-add-container', /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
104
113
|
onAddAContainerClick: e => onAddAContainerClick(e, 'Confluence'),
|
|
105
114
|
containerType: "ConfluenceSpace",
|
|
106
115
|
isLoading: containers.Confluence.isLoading,
|
|
107
116
|
canCreateContainers: canCreateContainers
|
|
108
|
-
}), containers.Loom.canAdd && /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
117
|
+
})), containers.Loom.canAdd && renderCard('loom-add-container', /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
109
118
|
onAddAContainerClick: e => onAddAContainerClick(e, 'Loom'),
|
|
110
119
|
containerType: "LoomSpace",
|
|
111
120
|
isLoading: containers.Loom.isLoading,
|
|
112
121
|
canCreateContainers: canCreateContainers
|
|
113
|
-
}), containers.WebLink.canAdd && /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
122
|
+
})), containers.WebLink.canAdd && renderCard('weblink-add-container', /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
114
123
|
onAddAContainerClick: e => onAddAContainerClick(e, 'WebLink'),
|
|
115
124
|
containerType: "WebLink",
|
|
116
125
|
canCreateContainers: canCreateContainers
|
|
117
|
-
}));
|
|
126
|
+
})));
|
|
118
127
|
};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
1
2
|
import React, { useCallback, useEffect, useMemo, useState } from 'react';
|
|
2
3
|
import { defineMessages, FormattedMessage } from 'react-intl';
|
|
3
4
|
import Button from '@atlaskit/button/new';
|
|
@@ -5,7 +6,7 @@ import ModalTransition from '@atlaskit/modal-dialog/modal-transition';
|
|
|
5
6
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
6
7
|
// eslint-disable-next-line @atlaskit/design-system/no-emotion-primitives -- to be migrated to @atlaskit/primitives/compiled – go/akcss
|
|
7
8
|
import { Grid } from '@atlaskit/primitives';
|
|
8
|
-
import { Inline, Stack } from '@atlaskit/primitives/compiled';
|
|
9
|
+
import { Box, Inline, Stack } from '@atlaskit/primitives/compiled';
|
|
9
10
|
import { useAnalyticsEvents } from '@atlaskit/teams-app-internal-analytics';
|
|
10
11
|
import { hasProductPermission, useProductPermissions } from '@atlaskit/teams-app-internal-product-permissions';
|
|
11
12
|
import { TeamContainersSkeleton } from '../../common/ui/team-containers-skeleton';
|
|
@@ -238,14 +239,17 @@ export const TeamContainers = ({
|
|
|
238
239
|
space: "space.200"
|
|
239
240
|
}, (() => {
|
|
240
241
|
const GridComponent = (components === null || components === void 0 ? void 0 : components.Grid) || Grid;
|
|
241
|
-
|
|
242
|
+
const isTeamsA11yGateEnabled = fg('teams-a11y-34974-34752-34709');
|
|
243
|
+
return /*#__PURE__*/React.createElement(GridComponent, _extends({
|
|
242
244
|
templateColumns: "repeat(auto-fill, minmax(300px, 1fr))",
|
|
243
245
|
gap: isDisplayedOnProfileCard ? 'space.0' : 'space.100'
|
|
244
|
-
},
|
|
246
|
+
}, isTeamsA11yGateEnabled && {
|
|
247
|
+
role: 'list'
|
|
248
|
+
}), elemBeforeCards && (() => {
|
|
245
249
|
const ElemBeforeCards = elemBeforeCards;
|
|
246
250
|
return /*#__PURE__*/React.createElement(ElemBeforeCards, null);
|
|
247
251
|
})(), filteredTeamLinks.slice(0, maxNumberOfContainersToShow).map(container => {
|
|
248
|
-
|
|
252
|
+
const card = /*#__PURE__*/React.createElement(LinkedContainerCardComponent, {
|
|
249
253
|
key: container.id,
|
|
250
254
|
containerType: container.type,
|
|
251
255
|
containerTypeProperties: container.containerTypeProperties,
|
|
@@ -262,13 +266,18 @@ export const TeamContainers = ({
|
|
|
262
266
|
}),
|
|
263
267
|
onEditLinkClick: () => handleEditContainerClick(container)
|
|
264
268
|
});
|
|
269
|
+
return isTeamsA11yGateEnabled ? /*#__PURE__*/React.createElement(Box, {
|
|
270
|
+
key: container.id,
|
|
271
|
+
role: "listitem"
|
|
272
|
+
}, card) : card;
|
|
265
273
|
}), getAddContainerCards({
|
|
266
274
|
containers: availableContainers,
|
|
267
275
|
onAddAContainerClick: onAddAContainerClick,
|
|
268
276
|
CustomAddContainerCard: components === null || components === void 0 ? void 0 : components.AddContainerCard,
|
|
269
|
-
canCreateContainers: hasPermissionToCreateContainer
|
|
277
|
+
canCreateContainers: hasPermissionToCreateContainer,
|
|
278
|
+
isTeamsA11yGateEnabled
|
|
270
279
|
}), showMore && filteredTeamLinks.slice(maxNumberOfContainersToShow).map(container => {
|
|
271
|
-
|
|
280
|
+
const card = /*#__PURE__*/React.createElement(LinkedContainerCardComponent, {
|
|
272
281
|
key: container.id,
|
|
273
282
|
containerType: container.type,
|
|
274
283
|
containerTypeProperties: container.containerTypeProperties,
|
|
@@ -285,6 +294,10 @@ export const TeamContainers = ({
|
|
|
285
294
|
}),
|
|
286
295
|
onEditLinkClick: () => handleEditContainerClick(container)
|
|
287
296
|
});
|
|
297
|
+
return isTeamsA11yGateEnabled ? /*#__PURE__*/React.createElement(Box, {
|
|
298
|
+
key: container.id,
|
|
299
|
+
role: "listitem"
|
|
300
|
+
}, card) : card;
|
|
288
301
|
}));
|
|
289
302
|
})(), filteredTeamLinks.length > maxNumberOfContainersToShow && /*#__PURE__*/React.createElement(Inline, null, /*#__PURE__*/React.createElement(Button, {
|
|
290
303
|
appearance: "subtle",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* team-link-card-title.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* team-link-card-title.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import "./team-link-card-title.compiled.css";
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* index.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* index.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
3
3
|
import "./index.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* index.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* index.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
|
3
3
|
import "./index.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* index.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* index.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
4
|
var _excluded = ["triggerRef"];
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* get-container-properties.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* get-container-properties.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
import "./get-container-properties.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* index.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* index.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
|
3
3
|
import "./index.compiled.css";
|
|
4
4
|
import { ax, ix } from "@compiled/react/runtime";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* index.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* index.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
3
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
4
4
|
import "./index.compiled.css";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* index.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* index.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
4
4
|
import "./index.compiled.css";
|
|
@@ -101,34 +101,43 @@ export var getAddContainerCards = function getAddContainerCards(_ref3) {
|
|
|
101
101
|
var containers = _ref3.containers,
|
|
102
102
|
_onAddAContainerClick = _ref3.onAddAContainerClick,
|
|
103
103
|
CustomAddContainerCard = _ref3.CustomAddContainerCard,
|
|
104
|
-
canCreateContainers = _ref3.canCreateContainers
|
|
104
|
+
canCreateContainers = _ref3.canCreateContainers,
|
|
105
|
+
isTeamsA11yGateEnabled = _ref3.isTeamsA11yGateEnabled;
|
|
105
106
|
var AddContainerCardComponent = CustomAddContainerCard !== null && CustomAddContainerCard !== void 0 ? CustomAddContainerCard : AddContainerCard;
|
|
106
|
-
|
|
107
|
+
var renderCard = function renderCard(key, card) {
|
|
108
|
+
return isTeamsA11yGateEnabled ? /*#__PURE__*/React.createElement(Box, {
|
|
109
|
+
key: key,
|
|
110
|
+
role: "listitem"
|
|
111
|
+
}, card) : /*#__PURE__*/React.createElement(React.Fragment, {
|
|
112
|
+
key: key
|
|
113
|
+
}, card);
|
|
114
|
+
};
|
|
115
|
+
return /*#__PURE__*/React.createElement(React.Fragment, null, containers.Jira.canAdd && renderCard('jira-add-container', /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
107
116
|
onAddAContainerClick: function onAddAContainerClick(e) {
|
|
108
117
|
return _onAddAContainerClick(e, 'Jira');
|
|
109
118
|
},
|
|
110
119
|
containerType: "JiraProject",
|
|
111
120
|
isLoading: containers.Jira.isLoading,
|
|
112
121
|
canCreateContainers: canCreateContainers
|
|
113
|
-
}), containers.Confluence.canAdd && /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
122
|
+
})), containers.Confluence.canAdd && renderCard('confluence-add-container', /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
114
123
|
onAddAContainerClick: function onAddAContainerClick(e) {
|
|
115
124
|
return _onAddAContainerClick(e, 'Confluence');
|
|
116
125
|
},
|
|
117
126
|
containerType: "ConfluenceSpace",
|
|
118
127
|
isLoading: containers.Confluence.isLoading,
|
|
119
128
|
canCreateContainers: canCreateContainers
|
|
120
|
-
}), containers.Loom.canAdd && /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
129
|
+
})), containers.Loom.canAdd && renderCard('loom-add-container', /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
121
130
|
onAddAContainerClick: function onAddAContainerClick(e) {
|
|
122
131
|
return _onAddAContainerClick(e, 'Loom');
|
|
123
132
|
},
|
|
124
133
|
containerType: "LoomSpace",
|
|
125
134
|
isLoading: containers.Loom.isLoading,
|
|
126
135
|
canCreateContainers: canCreateContainers
|
|
127
|
-
}), containers.WebLink.canAdd && /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
136
|
+
})), containers.WebLink.canAdd && renderCard('weblink-add-container', /*#__PURE__*/React.createElement(AddContainerCardComponent, {
|
|
128
137
|
onAddAContainerClick: function onAddAContainerClick(e) {
|
|
129
138
|
return _onAddAContainerClick(e, 'WebLink');
|
|
130
139
|
},
|
|
131
140
|
containerType: "WebLink",
|
|
132
141
|
canCreateContainers: canCreateContainers
|
|
133
|
-
}));
|
|
142
|
+
})));
|
|
134
143
|
};
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
1
2
|
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
2
3
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
3
4
|
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
@@ -8,7 +9,7 @@ import ModalTransition from '@atlaskit/modal-dialog/modal-transition';
|
|
|
8
9
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
9
10
|
// eslint-disable-next-line @atlaskit/design-system/no-emotion-primitives -- to be migrated to @atlaskit/primitives/compiled – go/akcss
|
|
10
11
|
import { Grid } from '@atlaskit/primitives';
|
|
11
|
-
import { Inline, Stack } from '@atlaskit/primitives/compiled';
|
|
12
|
+
import { Box, Inline, Stack } from '@atlaskit/primitives/compiled';
|
|
12
13
|
import { useAnalyticsEvents } from '@atlaskit/teams-app-internal-analytics';
|
|
13
14
|
import { hasProductPermission, useProductPermissions } from '@atlaskit/teams-app-internal-product-permissions';
|
|
14
15
|
import { TeamContainersSkeleton } from '../../common/ui/team-containers-skeleton';
|
|
@@ -286,14 +287,17 @@ export var TeamContainers = function TeamContainers(_ref) {
|
|
|
286
287
|
space: "space.200"
|
|
287
288
|
}, function () {
|
|
288
289
|
var GridComponent = (components === null || components === void 0 ? void 0 : components.Grid) || Grid;
|
|
289
|
-
|
|
290
|
+
var isTeamsA11yGateEnabled = fg('teams-a11y-34974-34752-34709');
|
|
291
|
+
return /*#__PURE__*/React.createElement(GridComponent, _extends({
|
|
290
292
|
templateColumns: "repeat(auto-fill, minmax(300px, 1fr))",
|
|
291
293
|
gap: isDisplayedOnProfileCard ? 'space.0' : 'space.100'
|
|
292
|
-
},
|
|
294
|
+
}, isTeamsA11yGateEnabled && {
|
|
295
|
+
role: 'list'
|
|
296
|
+
}), elemBeforeCards && function () {
|
|
293
297
|
var ElemBeforeCards = elemBeforeCards;
|
|
294
298
|
return /*#__PURE__*/React.createElement(ElemBeforeCards, null);
|
|
295
299
|
}(), filteredTeamLinks.slice(0, maxNumberOfContainersToShow).map(function (container) {
|
|
296
|
-
|
|
300
|
+
var card = /*#__PURE__*/React.createElement(LinkedContainerCardComponent, {
|
|
297
301
|
key: container.id,
|
|
298
302
|
containerType: container.type,
|
|
299
303
|
containerTypeProperties: container.containerTypeProperties,
|
|
@@ -314,13 +318,18 @@ export var TeamContainers = function TeamContainers(_ref) {
|
|
|
314
318
|
return handleEditContainerClick(container);
|
|
315
319
|
}
|
|
316
320
|
});
|
|
321
|
+
return isTeamsA11yGateEnabled ? /*#__PURE__*/React.createElement(Box, {
|
|
322
|
+
key: container.id,
|
|
323
|
+
role: "listitem"
|
|
324
|
+
}, card) : card;
|
|
317
325
|
}), getAddContainerCards({
|
|
318
326
|
containers: availableContainers,
|
|
319
327
|
onAddAContainerClick: onAddAContainerClick,
|
|
320
328
|
CustomAddContainerCard: components === null || components === void 0 ? void 0 : components.AddContainerCard,
|
|
321
|
-
canCreateContainers: hasPermissionToCreateContainer
|
|
329
|
+
canCreateContainers: hasPermissionToCreateContainer,
|
|
330
|
+
isTeamsA11yGateEnabled: isTeamsA11yGateEnabled
|
|
322
331
|
}), showMore && filteredTeamLinks.slice(maxNumberOfContainersToShow).map(function (container) {
|
|
323
|
-
|
|
332
|
+
var card = /*#__PURE__*/React.createElement(LinkedContainerCardComponent, {
|
|
324
333
|
key: container.id,
|
|
325
334
|
containerType: container.type,
|
|
326
335
|
containerTypeProperties: container.containerTypeProperties,
|
|
@@ -341,6 +350,10 @@ export var TeamContainers = function TeamContainers(_ref) {
|
|
|
341
350
|
return handleEditContainerClick(container);
|
|
342
351
|
}
|
|
343
352
|
});
|
|
353
|
+
return isTeamsA11yGateEnabled ? /*#__PURE__*/React.createElement(Box, {
|
|
354
|
+
key: container.id,
|
|
355
|
+
role: "listitem"
|
|
356
|
+
}, card) : card;
|
|
344
357
|
}));
|
|
345
358
|
}(), filteredTeamLinks.length > maxNumberOfContainersToShow && /*#__PURE__*/React.createElement(Inline, null, /*#__PURE__*/React.createElement(Button, {
|
|
346
359
|
appearance: "subtle",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* index.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* index.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
3
3
|
import _extends from "@babel/runtime/helpers/extends";
|
|
4
4
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
/* team-link-card-title.tsx generated by @compiled/babel-plugin v0.
|
|
1
|
+
/* team-link-card-title.tsx generated by @compiled/babel-plugin v0.40.0 */
|
|
2
2
|
import "./team-link-card-title.compiled.css";
|
|
3
3
|
import { ax, ix } from "@compiled/react/runtime";
|
|
4
4
|
import React from 'react';
|
|
@@ -27,9 +27,9 @@ export interface TeamWebLink {
|
|
|
27
27
|
teamId?: string;
|
|
28
28
|
}
|
|
29
29
|
export type NewTeamWebLink = Omit<TeamWebLink, 'linkId'>;
|
|
30
|
-
export declare const USER_ARI_PREFIX:
|
|
30
|
+
export declare const USER_ARI_PREFIX: 'ari:cloud:identity::user/';
|
|
31
31
|
export type UserARI = `${typeof USER_ARI_PREFIX}${string}`;
|
|
32
|
-
export declare const TEAM_ARI_PREFIX:
|
|
32
|
+
export declare const TEAM_ARI_PREFIX: 'ari:cloud:identity::team/';
|
|
33
33
|
export type TeamARI = `${typeof TEAM_ARI_PREFIX}${string}`;
|
|
34
34
|
export type UserStatus = 'active' | 'inactive' | 'closed';
|
|
35
35
|
export type TeamState = 'ACTIVE' | 'PURGED' | 'DISBANDED';
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { StoreActionApi } from 'react-sweet-state';
|
|
2
|
-
export declare const SUPPORTED_PRODUCTS: readonly [
|
|
2
|
+
export declare const SUPPORTED_PRODUCTS: readonly ['confluence', 'jira', 'loom'];
|
|
3
3
|
export type ProductPermissionRequestBodyType = {
|
|
4
4
|
permissionId: keyof ProductPermissionsType;
|
|
5
5
|
resourceId: string;
|
|
@@ -24,6 +24,7 @@ type GetAddContainerCardsProps = {
|
|
|
24
24
|
onAddAContainerClick: (e: React.MouseEvent<HTMLButtonElement>, containerType: 'Confluence' | 'Jira' | 'Loom' | 'WebLink') => void;
|
|
25
25
|
CustomAddContainerCard?: React.ComponentType<AddContainerCardProps>;
|
|
26
26
|
canCreateContainers?: boolean;
|
|
27
|
+
isTeamsA11yGateEnabled?: boolean;
|
|
27
28
|
};
|
|
28
|
-
export declare const getAddContainerCards: ({ containers, onAddAContainerClick, CustomAddContainerCard, canCreateContainers, }: GetAddContainerCardsProps) => React.JSX.Element;
|
|
29
|
+
export declare const getAddContainerCards: ({ containers, onAddAContainerClick, CustomAddContainerCard, canCreateContainers, isTeamsA11yGateEnabled, }: GetAddContainerCardsProps) => React.JSX.Element;
|
|
29
30
|
export {};
|
package/package.json
CHANGED
|
@@ -25,19 +25,19 @@
|
|
|
25
25
|
"dependencies": {
|
|
26
26
|
"@atlaskit/afm-i18n-platform-people-and-teams-teams-public": "2.193.0",
|
|
27
27
|
"@atlaskit/analytics-next": "^12.3.0",
|
|
28
|
-
"@atlaskit/avatar": "^26.
|
|
28
|
+
"@atlaskit/avatar": "^26.4.0",
|
|
29
29
|
"@atlaskit/button": "^24.3.0",
|
|
30
30
|
"@atlaskit/css": "^1.0.0",
|
|
31
|
-
"@atlaskit/dropdown-menu": "^17.
|
|
31
|
+
"@atlaskit/dropdown-menu": "^17.2.0",
|
|
32
32
|
"@atlaskit/feature-gate-js-client": "^6.0.0",
|
|
33
|
-
"@atlaskit/heading": "^
|
|
34
|
-
"@atlaskit/icon": "^37.
|
|
33
|
+
"@atlaskit/heading": "^7.0.0",
|
|
34
|
+
"@atlaskit/icon": "^37.2.0",
|
|
35
35
|
"@atlaskit/image": "^4.2.0",
|
|
36
|
-
"@atlaskit/link": "^
|
|
37
|
-
"@atlaskit/modal-dialog": "^16.
|
|
36
|
+
"@atlaskit/link": "^5.0.0",
|
|
37
|
+
"@atlaskit/modal-dialog": "^16.2.0",
|
|
38
38
|
"@atlaskit/people-teams-ui-public": "^5.1.0",
|
|
39
|
-
"@atlaskit/platform-feature-flags": "^2.
|
|
40
|
-
"@atlaskit/primitives": "^22.
|
|
39
|
+
"@atlaskit/platform-feature-flags": "^2.1.0",
|
|
40
|
+
"@atlaskit/primitives": "^22.2.0",
|
|
41
41
|
"@atlaskit/react-compiler-gating": "^0.2.0",
|
|
42
42
|
"@atlaskit/skeleton": "^4.2.0",
|
|
43
43
|
"@atlaskit/teams-app-internal-analytics": "^2.2.0",
|
|
@@ -45,10 +45,10 @@
|
|
|
45
45
|
"@atlaskit/teams-app-internal-product-permissions": "^2.1.0",
|
|
46
46
|
"@atlaskit/teams-client": "^5.1.0",
|
|
47
47
|
"@atlaskit/tile": "^2.3.0",
|
|
48
|
-
"@atlaskit/tokens": "^16.
|
|
49
|
-
"@atlaskit/tooltip": "^
|
|
48
|
+
"@atlaskit/tokens": "^16.3.0",
|
|
49
|
+
"@atlaskit/tooltip": "^24.0.0",
|
|
50
50
|
"@babel/runtime": "^7.0.0",
|
|
51
|
-
"@compiled/react": "^0.
|
|
51
|
+
"@compiled/react": "^1.0.0",
|
|
52
52
|
"@types/string-hash": "^1.1.3",
|
|
53
53
|
"graphql": "^15.8.0",
|
|
54
54
|
"graphql-tag": "^2.10.1",
|
|
@@ -111,7 +111,7 @@
|
|
|
111
111
|
}
|
|
112
112
|
},
|
|
113
113
|
"name": "@atlaskit/teams-public",
|
|
114
|
-
"version": "2.5.
|
|
114
|
+
"version": "2.5.2",
|
|
115
115
|
"description": "Public components related to teams",
|
|
116
116
|
"author": "Atlassian Pty Ltd",
|
|
117
117
|
"license": "Apache-2.0",
|
|
@@ -143,6 +143,9 @@
|
|
|
143
143
|
},
|
|
144
144
|
"enable_teams_t26_design_drop_core_experiences": {
|
|
145
145
|
"type": "boolean"
|
|
146
|
+
},
|
|
147
|
+
"teams-a11y-34974-34752-34709": {
|
|
148
|
+
"type": "boolean"
|
|
146
149
|
}
|
|
147
150
|
}
|
|
148
151
|
}
|