@atlaskit/teams-public 0.74.1 → 0.74.3
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 +12 -0
- package/dist/cjs/common/utils/spaceInviteScheduler.js +2 -0
- package/dist/cjs/ui/team-containers/main.js +8 -2
- package/dist/es2019/common/utils/spaceInviteScheduler.js +2 -0
- package/dist/es2019/ui/team-containers/main.js +7 -1
- package/dist/esm/common/utils/spaceInviteScheduler.js +2 -0
- package/dist/esm/ui/team-containers/main.js +8 -2
- package/dist/types/common/utils/spaceInviteScheduler.d.ts +1 -1
- package/dist/types-ts4.5/common/utils/spaceInviteScheduler.d.ts +1 -1
- package/package.json +5 -5
package/CHANGELOG.md
CHANGED
|
@@ -49,7 +49,9 @@ var spaceInviteScheduler = exports.spaceInviteScheduler = {
|
|
|
49
49
|
if (existing) {
|
|
50
50
|
clearTimeout(existing.timeoutId);
|
|
51
51
|
pending.delete(key);
|
|
52
|
+
return true;
|
|
52
53
|
}
|
|
54
|
+
return false;
|
|
53
55
|
},
|
|
54
56
|
/**
|
|
55
57
|
* Immediately fires all pending callbacks and clears the queue.
|
|
@@ -194,7 +194,7 @@ var TeamContainers = exports.TeamContainers = function TeamContainers(_ref) {
|
|
|
194
194
|
var LinkedContainerCardComponent = (components === null || components === void 0 ? void 0 : components.ContainerCard) || _teamLinkCard.TeamLinkCard;
|
|
195
195
|
var handleDisconnect = (0, _react.useCallback)( /*#__PURE__*/function () {
|
|
196
196
|
var _ref2 = (0, _asyncToGenerator2.default)( /*#__PURE__*/_regenerator.default.mark(function _callee(containerId) {
|
|
197
|
-
var removedContainer;
|
|
197
|
+
var removedContainer, wasCancelled;
|
|
198
198
|
return _regenerator.default.wrap(function _callee$(_context) {
|
|
199
199
|
while (1) switch (_context.prev = _context.next) {
|
|
200
200
|
case 0:
|
|
@@ -219,7 +219,13 @@ var TeamContainers = exports.TeamContainers = function TeamContainers(_ref) {
|
|
|
219
219
|
fireEvent('track.teamContainerUnlinked.failed', {});
|
|
220
220
|
} else {
|
|
221
221
|
if ((0, _platformFeatureFlags.fg)('space-team_linking_invites_fg')) {
|
|
222
|
-
_spaceInviteScheduler.spaceInviteScheduler.cancelInvite(teamId, containerId);
|
|
222
|
+
wasCancelled = _spaceInviteScheduler.spaceInviteScheduler.cancelInvite(teamId, containerId);
|
|
223
|
+
if (wasCancelled) {
|
|
224
|
+
fireEvent('track.sendSpaceTeamInvites.cancelled', {
|
|
225
|
+
spaceId: containerId,
|
|
226
|
+
teamId: teamId
|
|
227
|
+
});
|
|
228
|
+
}
|
|
223
229
|
}
|
|
224
230
|
fireEvent('track.teamContainerUnlinked.succeeded', {
|
|
225
231
|
containerRemoved: {
|
|
@@ -170,7 +170,13 @@ export const TeamContainers = ({
|
|
|
170
170
|
fireEvent('track.teamContainerUnlinked.failed', {});
|
|
171
171
|
} else {
|
|
172
172
|
if (fg('space-team_linking_invites_fg')) {
|
|
173
|
-
spaceInviteScheduler.cancelInvite(teamId, containerId);
|
|
173
|
+
const wasCancelled = spaceInviteScheduler.cancelInvite(teamId, containerId);
|
|
174
|
+
if (wasCancelled) {
|
|
175
|
+
fireEvent('track.sendSpaceTeamInvites.cancelled', {
|
|
176
|
+
spaceId: containerId,
|
|
177
|
+
teamId
|
|
178
|
+
});
|
|
179
|
+
}
|
|
174
180
|
}
|
|
175
181
|
fireEvent('track.teamContainerUnlinked.succeeded', {
|
|
176
182
|
containerRemoved: {
|
|
@@ -184,7 +184,7 @@ export var TeamContainers = function TeamContainers(_ref) {
|
|
|
184
184
|
var LinkedContainerCardComponent = (components === null || components === void 0 ? void 0 : components.ContainerCard) || TeamLinkCard;
|
|
185
185
|
var handleDisconnect = useCallback( /*#__PURE__*/function () {
|
|
186
186
|
var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(containerId) {
|
|
187
|
-
var removedContainer;
|
|
187
|
+
var removedContainer, wasCancelled;
|
|
188
188
|
return _regeneratorRuntime.wrap(function _callee$(_context) {
|
|
189
189
|
while (1) switch (_context.prev = _context.next) {
|
|
190
190
|
case 0:
|
|
@@ -209,7 +209,13 @@ export var TeamContainers = function TeamContainers(_ref) {
|
|
|
209
209
|
fireEvent('track.teamContainerUnlinked.failed', {});
|
|
210
210
|
} else {
|
|
211
211
|
if (fg('space-team_linking_invites_fg')) {
|
|
212
|
-
spaceInviteScheduler.cancelInvite(teamId, containerId);
|
|
212
|
+
wasCancelled = spaceInviteScheduler.cancelInvite(teamId, containerId);
|
|
213
|
+
if (wasCancelled) {
|
|
214
|
+
fireEvent('track.sendSpaceTeamInvites.cancelled', {
|
|
215
|
+
spaceId: containerId,
|
|
216
|
+
teamId: teamId
|
|
217
|
+
});
|
|
218
|
+
}
|
|
213
219
|
}
|
|
214
220
|
fireEvent('track.teamContainerUnlinked.succeeded', {
|
|
215
221
|
containerRemoved: {
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
*/
|
|
10
10
|
export declare const spaceInviteScheduler: {
|
|
11
11
|
scheduleInvite: (teamId: string, containerId: string, callback: () => void) => void;
|
|
12
|
-
cancelInvite: (teamId: string, containerId: string) =>
|
|
12
|
+
cancelInvite: (teamId: string, containerId: string) => boolean;
|
|
13
13
|
/**
|
|
14
14
|
* Immediately fires all pending callbacks and clears the queue.
|
|
15
15
|
* Called automatically on page unload (visibilitychange / beforeunload)
|
|
@@ -9,7 +9,7 @@
|
|
|
9
9
|
*/
|
|
10
10
|
export declare const spaceInviteScheduler: {
|
|
11
11
|
scheduleInvite: (teamId: string, containerId: string, callback: () => void) => void;
|
|
12
|
-
cancelInvite: (teamId: string, containerId: string) =>
|
|
12
|
+
cancelInvite: (teamId: string, containerId: string) => boolean;
|
|
13
13
|
/**
|
|
14
14
|
* Immediately fires all pending callbacks and clears the queue.
|
|
15
15
|
* Called automatically on page unload (visibilitychange / beforeunload)
|
package/package.json
CHANGED
|
@@ -35,16 +35,16 @@
|
|
|
35
35
|
"@atlaskit/icon": "^34.0.0",
|
|
36
36
|
"@atlaskit/image": "^3.0.0",
|
|
37
37
|
"@atlaskit/link": "^3.4.0",
|
|
38
|
-
"@atlaskit/modal-dialog": "^14.
|
|
38
|
+
"@atlaskit/modal-dialog": "^14.15.0",
|
|
39
39
|
"@atlaskit/people-teams-ui-public": "^3.7.0",
|
|
40
40
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
41
|
-
"@atlaskit/primitives": "^
|
|
41
|
+
"@atlaskit/primitives": "^19.0.0",
|
|
42
42
|
"@atlaskit/skeleton": "^2.1.0",
|
|
43
43
|
"@atlaskit/teams-app-internal-analytics": "^1.27.0",
|
|
44
44
|
"@atlaskit/teams-app-internal-navigation": "^1.8.0",
|
|
45
45
|
"@atlaskit/teams-app-internal-product-permissions": "^1.3.0",
|
|
46
|
-
"@atlaskit/teams-client": "^4.
|
|
47
|
-
"@atlaskit/tokens": "^
|
|
46
|
+
"@atlaskit/teams-client": "^4.32.0",
|
|
47
|
+
"@atlaskit/tokens": "^13.0.0",
|
|
48
48
|
"@atlaskit/tooltip": "^21.1.0",
|
|
49
49
|
"@babel/runtime": "^7.0.0",
|
|
50
50
|
"@compiled/react": "^0.20.0",
|
|
@@ -107,7 +107,7 @@
|
|
|
107
107
|
}
|
|
108
108
|
},
|
|
109
109
|
"name": "@atlaskit/teams-public",
|
|
110
|
-
"version": "0.74.
|
|
110
|
+
"version": "0.74.3",
|
|
111
111
|
"description": "Public components related to teams",
|
|
112
112
|
"author": "Atlassian Pty Ltd",
|
|
113
113
|
"license": "Apache-2.0",
|