@atlaskit/teams-public 3.6.0 → 3.6.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 +9 -0
- package/dist/cjs/common/ui/team-link-card-actions/index.compiled.css +0 -1
- package/dist/cjs/common/ui/team-link-card-actions/index.js +3 -17
- package/dist/cjs/ui/team-containers/main.js +2 -2
- package/dist/es2019/common/ui/team-link-card-actions/index.compiled.css +0 -1
- package/dist/es2019/common/ui/team-link-card-actions/index.js +3 -17
- package/dist/es2019/ui/team-containers/main.js +2 -2
- package/dist/esm/common/ui/team-link-card-actions/index.compiled.css +0 -1
- package/dist/esm/common/ui/team-link-card-actions/index.js +3 -17
- package/dist/esm/ui/team-containers/main.js +2 -2
- package/dist/types/common/ui/team-link-card-actions/index.d.ts +1 -1
- package/package.json +3 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,14 @@
|
|
|
1
1
|
# @atlaskit/teams-public
|
|
2
2
|
|
|
3
|
+
## 3.6.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`c9e46bb98b3b2`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/c9e46bb98b3b2) -
|
|
8
|
+
Remove the completed Teams accessibility gate and retain accessible headings, keyboard navigation,
|
|
9
|
+
focus management and visible link actions.
|
|
10
|
+
- Updated dependencies
|
|
11
|
+
|
|
3
12
|
## 3.6.0
|
|
4
13
|
|
|
5
14
|
### Minor Changes
|
|
@@ -13,22 +13,18 @@ var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/h
|
|
|
13
13
|
var _react = _interopRequireDefault(require("react"));
|
|
14
14
|
var _reactIntl = require("react-intl");
|
|
15
15
|
var _button = _interopRequireDefault(require("@atlaskit/button/icon/button"));
|
|
16
|
-
var _css = require("@atlaskit/css");
|
|
17
16
|
var _dropdownMenu = _interopRequireDefault(require("@atlaskit/dropdown-menu/dropdown-menu"));
|
|
18
17
|
var _dropdownMenuItem = _interopRequireDefault(require("@atlaskit/dropdown-menu/dropdown-menu-item"));
|
|
19
18
|
var _dropdownMenuItemGroup = _interopRequireDefault(require("@atlaskit/dropdown-menu/dropdown-menu-item-group"));
|
|
20
19
|
var _cross = _interopRequireDefault(require("@atlaskit/icon/core/cross"));
|
|
21
20
|
var _showMoreHorizontal = _interopRequireDefault(require("@atlaskit/icon/core/show-more-horizontal"));
|
|
22
|
-
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
23
21
|
var _box = require("@atlaskit/primitives/compiled/box");
|
|
24
22
|
var _useAnalyticsEvents2 = require("@atlaskit/teams-app-internal-analytics/use-analytics-events");
|
|
25
23
|
var _Tooltip = _interopRequireDefault(require("@atlaskit/tooltip/Tooltip"));
|
|
26
24
|
var _excluded = ["triggerRef"];
|
|
27
25
|
var styles = {
|
|
28
26
|
crossIconWrapper: "_1e0c1txw _4cvr1h6o _1bahesu3 _18u01wug",
|
|
29
|
-
showMoreIconWrapper: "_1e0c1txw _4cvr1h6o _1bahesu3 _18u01wug"
|
|
30
|
-
iconHidden: "_1e0cglyw",
|
|
31
|
-
iconVisible: "_1e0c1txw"
|
|
27
|
+
showMoreIconWrapper: "_1e0c1txw _4cvr1h6o _1bahesu3 _18u01wug"
|
|
32
28
|
};
|
|
33
29
|
var messages = (0, _reactIntl.defineMessages)({
|
|
34
30
|
disconnectTooltip: {
|
|
@@ -51,10 +47,6 @@ var TeamLinkCardActions = exports.TeamLinkCardActions = function TeamLinkCardAct
|
|
|
51
47
|
var containerType = _ref.containerType,
|
|
52
48
|
title = _ref.title,
|
|
53
49
|
containerId = _ref.containerId,
|
|
54
|
-
hovered = _ref.hovered,
|
|
55
|
-
focused = _ref.focused,
|
|
56
|
-
isDropdownOpen = _ref.isDropdownOpen,
|
|
57
|
-
showKeyboardFocus = _ref.showKeyboardFocus,
|
|
58
50
|
onDisconnectButtonClick = _ref.onDisconnectButtonClick,
|
|
59
51
|
onEditLinkClick = _ref.onEditLinkClick,
|
|
60
52
|
onDropdownOpenChange = _ref.onDropdownOpenChange;
|
|
@@ -67,12 +59,6 @@ var TeamLinkCardActions = exports.TeamLinkCardActions = function TeamLinkCardAct
|
|
|
67
59
|
var _dropdownTriggerEleme;
|
|
68
60
|
(_dropdownTriggerEleme = dropdownTriggerElementRef.current) === null || _dropdownTriggerEleme === void 0 || _dropdownTriggerEleme.focus();
|
|
69
61
|
};
|
|
70
|
-
|
|
71
|
-
// Show icons when:
|
|
72
|
-
// 1. Hovering over the card
|
|
73
|
-
// 2. Dropdown is open
|
|
74
|
-
// 3. Focused via keyboard navigation (when showKeyboardFocus is true)
|
|
75
|
-
var shouldShowIcon = (0, _fg.fg)('teams_a11y_20261005') || hovered || isDropdownOpen || focused && showKeyboardFocus;
|
|
76
62
|
var handleDisconnectClick = function handleDisconnectClick(e) {
|
|
77
63
|
e.preventDefault();
|
|
78
64
|
e.stopPropagation();
|
|
@@ -99,7 +85,7 @@ var TeamLinkCardActions = exports.TeamLinkCardActions = function TeamLinkCardAct
|
|
|
99
85
|
};
|
|
100
86
|
if (containerType === 'WebLink') {
|
|
101
87
|
return /*#__PURE__*/_react.default.createElement(_box.Box, {
|
|
102
|
-
xcss:
|
|
88
|
+
xcss: styles.showMoreIconWrapper
|
|
103
89
|
}, /*#__PURE__*/_react.default.createElement(_dropdownMenu.default, {
|
|
104
90
|
trigger: function trigger(_ref2) {
|
|
105
91
|
var triggerRef = _ref2.triggerRef,
|
|
@@ -134,7 +120,7 @@ var TeamLinkCardActions = exports.TeamLinkCardActions = function TeamLinkCardAct
|
|
|
134
120
|
}, formatMessage(messages.removeLink)))));
|
|
135
121
|
}
|
|
136
122
|
return /*#__PURE__*/_react.default.createElement(_box.Box, {
|
|
137
|
-
xcss:
|
|
123
|
+
xcss: styles.crossIconWrapper
|
|
138
124
|
}, /*#__PURE__*/_react.default.createElement(_Tooltip.default, {
|
|
139
125
|
content: formatMessage(messages.disconnectTooltip),
|
|
140
126
|
position: "top"
|
|
@@ -184,7 +184,7 @@ var TeamContainers = exports.TeamContainers = function TeamContainers(_ref) {
|
|
|
184
184
|
}
|
|
185
185
|
}, [hasError, unlinkError, onError]);
|
|
186
186
|
(0, _react.useEffect)(function () {
|
|
187
|
-
if (
|
|
187
|
+
if (showMore && firstShowMoreItemRef.current) {
|
|
188
188
|
firstShowMoreItemRef.current.focus({
|
|
189
189
|
preventScroll: false
|
|
190
190
|
});
|
|
@@ -374,7 +374,7 @@ var TeamContainers = exports.TeamContainers = function TeamContainers(_ref) {
|
|
|
374
374
|
key: container.id,
|
|
375
375
|
role: "listitem",
|
|
376
376
|
ref: index === 0 ? firstShowMoreItemRef : undefined,
|
|
377
|
-
tabIndex: index === 0
|
|
377
|
+
tabIndex: index === 0 ? -1 : undefined
|
|
378
378
|
}, card);
|
|
379
379
|
}));
|
|
380
380
|
}(), filteredTeamLinks.length > maxNumberOfContainersToShow && /*#__PURE__*/_react.default.createElement(_inline.Inline, null, /*#__PURE__*/_react.default.createElement(_button.default, {
|
|
@@ -5,21 +5,17 @@ import { ax, ix } from "@compiled/react/runtime";
|
|
|
5
5
|
import React from 'react';
|
|
6
6
|
import { defineMessages, useIntl } from 'react-intl';
|
|
7
7
|
import IconButton from '@atlaskit/button/icon/button';
|
|
8
|
-
import { cx } from '@atlaskit/css';
|
|
9
8
|
import DropdownMenu from '@atlaskit/dropdown-menu/dropdown-menu';
|
|
10
9
|
import DropdownItem from '@atlaskit/dropdown-menu/dropdown-menu-item';
|
|
11
10
|
import DropdownItemGroup from '@atlaskit/dropdown-menu/dropdown-menu-item-group';
|
|
12
11
|
import CrossIcon from '@atlaskit/icon/core/cross';
|
|
13
12
|
import ShowMoreHorizontalIcon from '@atlaskit/icon/core/show-more-horizontal';
|
|
14
|
-
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
15
13
|
import { Box } from '@atlaskit/primitives/compiled/box';
|
|
16
14
|
import { useAnalyticsEvents } from '@atlaskit/teams-app-internal-analytics/use-analytics-events';
|
|
17
15
|
import Tooltip from '@atlaskit/tooltip/Tooltip';
|
|
18
16
|
const styles = {
|
|
19
17
|
crossIconWrapper: "_1e0c1txw _4cvr1h6o _1bahesu3 _18u01wug",
|
|
20
|
-
showMoreIconWrapper: "_1e0c1txw _4cvr1h6o _1bahesu3 _18u01wug"
|
|
21
|
-
iconHidden: "_1e0cglyw",
|
|
22
|
-
iconVisible: "_1e0c1txw"
|
|
18
|
+
showMoreIconWrapper: "_1e0c1txw _4cvr1h6o _1bahesu3 _18u01wug"
|
|
23
19
|
};
|
|
24
20
|
const messages = defineMessages({
|
|
25
21
|
disconnectTooltip: {
|
|
@@ -42,10 +38,6 @@ export const TeamLinkCardActions = ({
|
|
|
42
38
|
containerType,
|
|
43
39
|
title,
|
|
44
40
|
containerId,
|
|
45
|
-
hovered,
|
|
46
|
-
focused,
|
|
47
|
-
isDropdownOpen,
|
|
48
|
-
showKeyboardFocus,
|
|
49
41
|
onDisconnectButtonClick,
|
|
50
42
|
onEditLinkClick,
|
|
51
43
|
onDropdownOpenChange
|
|
@@ -61,12 +53,6 @@ export const TeamLinkCardActions = ({
|
|
|
61
53
|
var _dropdownTriggerEleme;
|
|
62
54
|
(_dropdownTriggerEleme = dropdownTriggerElementRef.current) === null || _dropdownTriggerEleme === void 0 ? void 0 : _dropdownTriggerEleme.focus();
|
|
63
55
|
};
|
|
64
|
-
|
|
65
|
-
// Show icons when:
|
|
66
|
-
// 1. Hovering over the card
|
|
67
|
-
// 2. Dropdown is open
|
|
68
|
-
// 3. Focused via keyboard navigation (when showKeyboardFocus is true)
|
|
69
|
-
const shouldShowIcon = fg('teams_a11y_20261005') || hovered || isDropdownOpen || focused && showKeyboardFocus;
|
|
70
56
|
const handleDisconnectClick = e => {
|
|
71
57
|
e.preventDefault();
|
|
72
58
|
e.stopPropagation();
|
|
@@ -93,7 +79,7 @@ export const TeamLinkCardActions = ({
|
|
|
93
79
|
};
|
|
94
80
|
if (containerType === 'WebLink') {
|
|
95
81
|
return /*#__PURE__*/React.createElement(Box, {
|
|
96
|
-
xcss:
|
|
82
|
+
xcss: styles.showMoreIconWrapper
|
|
97
83
|
}, /*#__PURE__*/React.createElement(DropdownMenu, {
|
|
98
84
|
trigger: ({
|
|
99
85
|
triggerRef,
|
|
@@ -125,7 +111,7 @@ export const TeamLinkCardActions = ({
|
|
|
125
111
|
}, formatMessage(messages.removeLink)))));
|
|
126
112
|
}
|
|
127
113
|
return /*#__PURE__*/React.createElement(Box, {
|
|
128
|
-
xcss:
|
|
114
|
+
xcss: styles.crossIconWrapper
|
|
129
115
|
}, /*#__PURE__*/React.createElement(Tooltip, {
|
|
130
116
|
content: formatMessage(messages.disconnectTooltip),
|
|
131
117
|
position: "top"
|
|
@@ -151,7 +151,7 @@ export const TeamContainers = ({
|
|
|
151
151
|
}
|
|
152
152
|
}, [hasError, unlinkError, onError]);
|
|
153
153
|
useEffect(() => {
|
|
154
|
-
if (
|
|
154
|
+
if (showMore && firstShowMoreItemRef.current) {
|
|
155
155
|
firstShowMoreItemRef.current.focus({
|
|
156
156
|
preventScroll: false
|
|
157
157
|
});
|
|
@@ -309,7 +309,7 @@ export const TeamContainers = ({
|
|
|
309
309
|
key: container.id,
|
|
310
310
|
role: "listitem",
|
|
311
311
|
ref: index === 0 ? firstShowMoreItemRef : undefined,
|
|
312
|
-
tabIndex: index === 0
|
|
312
|
+
tabIndex: index === 0 ? -1 : undefined
|
|
313
313
|
}, card);
|
|
314
314
|
}));
|
|
315
315
|
})(), filteredTeamLinks.length > maxNumberOfContainersToShow && /*#__PURE__*/React.createElement(Inline, null, /*#__PURE__*/React.createElement(Button, {
|
|
@@ -7,21 +7,17 @@ import { ax, ix } from "@compiled/react/runtime";
|
|
|
7
7
|
import React from 'react';
|
|
8
8
|
import { defineMessages, useIntl } from 'react-intl';
|
|
9
9
|
import IconButton from '@atlaskit/button/icon/button';
|
|
10
|
-
import { cx } from '@atlaskit/css';
|
|
11
10
|
import DropdownMenu from '@atlaskit/dropdown-menu/dropdown-menu';
|
|
12
11
|
import DropdownItem from '@atlaskit/dropdown-menu/dropdown-menu-item';
|
|
13
12
|
import DropdownItemGroup from '@atlaskit/dropdown-menu/dropdown-menu-item-group';
|
|
14
13
|
import CrossIcon from '@atlaskit/icon/core/cross';
|
|
15
14
|
import ShowMoreHorizontalIcon from '@atlaskit/icon/core/show-more-horizontal';
|
|
16
|
-
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
17
15
|
import { Box } from '@atlaskit/primitives/compiled/box';
|
|
18
16
|
import { useAnalyticsEvents } from '@atlaskit/teams-app-internal-analytics/use-analytics-events';
|
|
19
17
|
import Tooltip from '@atlaskit/tooltip/Tooltip';
|
|
20
18
|
var styles = {
|
|
21
19
|
crossIconWrapper: "_1e0c1txw _4cvr1h6o _1bahesu3 _18u01wug",
|
|
22
|
-
showMoreIconWrapper: "_1e0c1txw _4cvr1h6o _1bahesu3 _18u01wug"
|
|
23
|
-
iconHidden: "_1e0cglyw",
|
|
24
|
-
iconVisible: "_1e0c1txw"
|
|
20
|
+
showMoreIconWrapper: "_1e0c1txw _4cvr1h6o _1bahesu3 _18u01wug"
|
|
25
21
|
};
|
|
26
22
|
var messages = defineMessages({
|
|
27
23
|
disconnectTooltip: {
|
|
@@ -44,10 +40,6 @@ export var TeamLinkCardActions = function TeamLinkCardActions(_ref) {
|
|
|
44
40
|
var containerType = _ref.containerType,
|
|
45
41
|
title = _ref.title,
|
|
46
42
|
containerId = _ref.containerId,
|
|
47
|
-
hovered = _ref.hovered,
|
|
48
|
-
focused = _ref.focused,
|
|
49
|
-
isDropdownOpen = _ref.isDropdownOpen,
|
|
50
|
-
showKeyboardFocus = _ref.showKeyboardFocus,
|
|
51
43
|
onDisconnectButtonClick = _ref.onDisconnectButtonClick,
|
|
52
44
|
onEditLinkClick = _ref.onEditLinkClick,
|
|
53
45
|
onDropdownOpenChange = _ref.onDropdownOpenChange;
|
|
@@ -60,12 +52,6 @@ export var TeamLinkCardActions = function TeamLinkCardActions(_ref) {
|
|
|
60
52
|
var _dropdownTriggerEleme;
|
|
61
53
|
(_dropdownTriggerEleme = dropdownTriggerElementRef.current) === null || _dropdownTriggerEleme === void 0 || _dropdownTriggerEleme.focus();
|
|
62
54
|
};
|
|
63
|
-
|
|
64
|
-
// Show icons when:
|
|
65
|
-
// 1. Hovering over the card
|
|
66
|
-
// 2. Dropdown is open
|
|
67
|
-
// 3. Focused via keyboard navigation (when showKeyboardFocus is true)
|
|
68
|
-
var shouldShowIcon = fg('teams_a11y_20261005') || hovered || isDropdownOpen || focused && showKeyboardFocus;
|
|
69
55
|
var handleDisconnectClick = function handleDisconnectClick(e) {
|
|
70
56
|
e.preventDefault();
|
|
71
57
|
e.stopPropagation();
|
|
@@ -92,7 +78,7 @@ export var TeamLinkCardActions = function TeamLinkCardActions(_ref) {
|
|
|
92
78
|
};
|
|
93
79
|
if (containerType === 'WebLink') {
|
|
94
80
|
return /*#__PURE__*/React.createElement(Box, {
|
|
95
|
-
xcss:
|
|
81
|
+
xcss: styles.showMoreIconWrapper
|
|
96
82
|
}, /*#__PURE__*/React.createElement(DropdownMenu, {
|
|
97
83
|
trigger: function trigger(_ref2) {
|
|
98
84
|
var triggerRef = _ref2.triggerRef,
|
|
@@ -127,7 +113,7 @@ export var TeamLinkCardActions = function TeamLinkCardActions(_ref) {
|
|
|
127
113
|
}, formatMessage(messages.removeLink)))));
|
|
128
114
|
}
|
|
129
115
|
return /*#__PURE__*/React.createElement(Box, {
|
|
130
|
-
xcss:
|
|
116
|
+
xcss: styles.crossIconWrapper
|
|
131
117
|
}, /*#__PURE__*/React.createElement(Tooltip, {
|
|
132
118
|
content: formatMessage(messages.disconnectTooltip),
|
|
133
119
|
position: "top"
|
|
@@ -175,7 +175,7 @@ export var TeamContainers = function TeamContainers(_ref) {
|
|
|
175
175
|
}
|
|
176
176
|
}, [hasError, unlinkError, onError]);
|
|
177
177
|
useEffect(function () {
|
|
178
|
-
if (
|
|
178
|
+
if (showMore && firstShowMoreItemRef.current) {
|
|
179
179
|
firstShowMoreItemRef.current.focus({
|
|
180
180
|
preventScroll: false
|
|
181
181
|
});
|
|
@@ -365,7 +365,7 @@ export var TeamContainers = function TeamContainers(_ref) {
|
|
|
365
365
|
key: container.id,
|
|
366
366
|
role: "listitem",
|
|
367
367
|
ref: index === 0 ? firstShowMoreItemRef : undefined,
|
|
368
|
-
tabIndex: index === 0
|
|
368
|
+
tabIndex: index === 0 ? -1 : undefined
|
|
369
369
|
}, card);
|
|
370
370
|
}));
|
|
371
371
|
}(), filteredTeamLinks.length > maxNumberOfContainersToShow && /*#__PURE__*/React.createElement(Inline, null, /*#__PURE__*/React.createElement(Button, {
|
|
@@ -12,4 +12,4 @@ export interface TeamLinkCardActionsProps {
|
|
|
12
12
|
onEditLinkClick?: () => void;
|
|
13
13
|
onDropdownOpenChange: (isOpen: boolean) => void;
|
|
14
14
|
}
|
|
15
|
-
export declare const TeamLinkCardActions: ({ containerType, title, containerId,
|
|
15
|
+
export declare const TeamLinkCardActions: ({ containerType, title, containerId, onDisconnectButtonClick, onEditLinkClick, onDropdownOpenChange, }: TeamLinkCardActionsProps) => React.JSX.Element;
|
package/package.json
CHANGED
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"@atlaskit/afm-i18n-platform-people-and-teams-teams-public": "2.285.0",
|
|
27
27
|
"@atlaskit/analytics-next": "^12.6.0",
|
|
28
28
|
"@atlaskit/avatar": "^30.0.0",
|
|
29
|
-
"@atlaskit/button": "^25.
|
|
29
|
+
"@atlaskit/button": "^25.6.0",
|
|
30
30
|
"@atlaskit/css": "^1.1.0",
|
|
31
31
|
"@atlaskit/dropdown-menu": "^21.0.0",
|
|
32
32
|
"@atlaskit/feature-gate-js-client": "^7.0.0",
|
|
@@ -45,7 +45,7 @@
|
|
|
45
45
|
"@atlaskit/teams-app-internal-product-permissions": "^2.2.0",
|
|
46
46
|
"@atlaskit/teams-client": "^6.2.0",
|
|
47
47
|
"@atlaskit/tile": "^5.0.0",
|
|
48
|
-
"@atlaskit/tokens": "^20.
|
|
48
|
+
"@atlaskit/tokens": "^20.7.0",
|
|
49
49
|
"@atlaskit/tooltip": "^24.4.0",
|
|
50
50
|
"@babel/runtime": "^7.0.0",
|
|
51
51
|
"@compiled/react": "^1.0.2",
|
|
@@ -77,7 +77,7 @@
|
|
|
77
77
|
"react-intl": "^7.0.0"
|
|
78
78
|
},
|
|
79
79
|
"name": "@atlaskit/teams-public",
|
|
80
|
-
"version": "3.6.
|
|
80
|
+
"version": "3.6.1",
|
|
81
81
|
"description": "Public components related to teams",
|
|
82
82
|
"author": "Atlassian Pty Ltd",
|
|
83
83
|
"license": "Apache-2.0",
|
|
@@ -94,9 +94,6 @@
|
|
|
94
94
|
},
|
|
95
95
|
"workforce_optimization_team_modal_update": {
|
|
96
96
|
"type": "boolean"
|
|
97
|
-
},
|
|
98
|
-
"teams_a11y_20261005": {
|
|
99
|
-
"type": "boolean"
|
|
100
97
|
}
|
|
101
98
|
}
|
|
102
99
|
}
|