@atlaskit/smart-card 32.7.6 → 32.7.8
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 +16 -0
- package/dist/cjs/extractors/flexible/actions/index.js +5 -7
- package/dist/cjs/state/actions/index.js +13 -38
- package/dist/cjs/state/analytics/useSmartLinkAnalytics.js +54 -305
- package/dist/cjs/state/hooks/use-ai-summary/ai-summary-service/index.js +1 -2
- package/dist/cjs/state/hooks/use-ai-summary/ai-summary-service/types.js +4 -5
- package/dist/cjs/utils/analytics/analytics.js +28 -304
- package/dist/cjs/utils/analytics/index.js +0 -66
- package/dist/cjs/utils/mocks.js +5 -7
- package/dist/cjs/view/BlockCard/views/styled.js +1 -1
- package/dist/cjs/view/Card/index.js +5 -7
- package/dist/cjs/view/CardWithUrl/component.js +7 -22
- package/dist/cjs/view/EmbedCard/EmbedResizeMessageListener.js +7 -10
- package/dist/cjs/view/FlexibleCard/components/actions/action/action-button/index.js +1 -1
- package/dist/cjs/view/FlexibleCard/components/actions/action/server-action/index.js +4 -13
- package/dist/cjs/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-container/common/test-utils.js +10 -12
- package/dist/cjs/view/FlexibleCard/components/blocks/utils.js +1 -1
- package/dist/cjs/view/FlexibleCard/components/common/atlaskit-icon/index.js +61 -61
- package/dist/cjs/view/FlexibleCard/components/elements/badge/index.js +1 -1
- package/dist/cjs/view/FlexibleCard/components/elements/lozenge/lozenge-action/index.js +4 -16
- package/dist/cjs/view/FlexibleCard/components/elements/lozenge/lozenge-action/lozenge-action-error/index.js +1 -5
- package/dist/cjs/view/FlexibleCard/components/elements/utils.js +34 -34
- package/dist/cjs/view/FlexibleCard/components/utils.js +5 -5
- package/dist/cjs/view/HoverCard/components/HoverCardContent.js +21 -53
- package/dist/cjs/view/HoverCard/styled.js +1 -1
- package/dist/cjs/view/InlineCard/ErroredView/index.js +8 -11
- package/dist/cjs/view/InlineCard/ForbiddenView/index.js +10 -13
- package/dist/cjs/view/InlineCard/IconAndTitleLayout/index.js +7 -10
- package/dist/cjs/view/InlineCard/ResolvedView/index.js +5 -7
- package/dist/cjs/view/InlineCard/ResolvingView/index.js +5 -7
- package/dist/cjs/view/LinkUrl/index.js +1 -1
- package/dist/cjs/view/LinkView/index.js +5 -7
- package/dist/cjs/view/common/UnauthorisedViewContent.js +3 -9
- package/dist/es2019/state/actions/index.js +13 -38
- package/dist/es2019/state/analytics/useSmartLinkAnalytics.js +2 -238
- package/dist/es2019/utils/analytics/analytics.js +2 -286
- package/dist/es2019/utils/analytics/index.js +1 -1
- package/dist/es2019/view/BlockCard/views/styled.js +1 -1
- package/dist/es2019/view/CardWithUrl/component.js +8 -23
- package/dist/es2019/view/FlexibleCard/components/actions/action/action-button/index.js +1 -1
- package/dist/es2019/view/FlexibleCard/components/actions/action/server-action/index.js +4 -13
- package/dist/es2019/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-container/common/test-utils.js +3 -3
- package/dist/es2019/view/FlexibleCard/components/elements/lozenge/lozenge-action/index.js +4 -16
- package/dist/es2019/view/FlexibleCard/components/elements/lozenge/lozenge-action/lozenge-action-error/index.js +1 -5
- package/dist/es2019/view/FlexibleCard/components/utils.js +3 -3
- package/dist/es2019/view/HoverCard/components/HoverCardContent.js +21 -53
- package/dist/es2019/view/HoverCard/styled.js +1 -1
- package/dist/es2019/view/LinkUrl/index.js +1 -1
- package/dist/es2019/view/common/UnauthorisedViewContent.js +3 -9
- package/dist/esm/extractors/flexible/actions/index.js +5 -7
- package/dist/esm/state/actions/index.js +13 -38
- package/dist/esm/state/analytics/useSmartLinkAnalytics.js +55 -306
- package/dist/esm/state/hooks/use-ai-summary/ai-summary-service/index.js +1 -2
- package/dist/esm/state/hooks/use-ai-summary/ai-summary-service/types.js +4 -5
- package/dist/esm/utils/analytics/analytics.js +27 -303
- package/dist/esm/utils/analytics/index.js +1 -1
- package/dist/esm/utils/mocks.js +5 -7
- package/dist/esm/view/BlockCard/views/styled.js +1 -1
- package/dist/esm/view/Card/index.js +5 -7
- package/dist/esm/view/CardWithUrl/component.js +8 -23
- package/dist/esm/view/EmbedCard/EmbedResizeMessageListener.js +7 -10
- package/dist/esm/view/FlexibleCard/components/actions/action/action-button/index.js +1 -1
- package/dist/esm/view/FlexibleCard/components/actions/action/server-action/index.js +4 -13
- package/dist/esm/view/FlexibleCard/components/actions/automation-action/automation-manual-triggers/manual-triggers-container/common/test-utils.js +10 -12
- package/dist/esm/view/FlexibleCard/components/blocks/utils.js +1 -1
- package/dist/esm/view/FlexibleCard/components/common/atlaskit-icon/index.js +61 -61
- package/dist/esm/view/FlexibleCard/components/elements/badge/index.js +1 -1
- package/dist/esm/view/FlexibleCard/components/elements/lozenge/lozenge-action/index.js +4 -16
- package/dist/esm/view/FlexibleCard/components/elements/lozenge/lozenge-action/lozenge-action-error/index.js +1 -5
- package/dist/esm/view/FlexibleCard/components/elements/utils.js +34 -34
- package/dist/esm/view/FlexibleCard/components/utils.js +5 -5
- package/dist/esm/view/HoverCard/components/HoverCardContent.js +21 -53
- package/dist/esm/view/HoverCard/styled.js +1 -1
- package/dist/esm/view/InlineCard/ErroredView/index.js +8 -11
- package/dist/esm/view/InlineCard/ForbiddenView/index.js +10 -13
- package/dist/esm/view/InlineCard/IconAndTitleLayout/index.js +7 -10
- package/dist/esm/view/InlineCard/ResolvedView/index.js +5 -7
- package/dist/esm/view/InlineCard/ResolvingView/index.js +5 -7
- package/dist/esm/view/LinkUrl/index.js +1 -1
- package/dist/esm/view/LinkView/index.js +5 -7
- package/dist/esm/view/common/UnauthorisedViewContent.js +3 -9
- package/dist/types/state/analytics/useSmartLinkAnalytics.d.ts +1 -101
- package/dist/types/state/hooks/useSmartLink.d.ts +0 -12
- package/dist/types/utils/analytics/analytics.d.ts +1 -51
- package/dist/types/utils/analytics/index.d.ts +1 -1
- package/dist/types/utils/analytics/types.d.ts +0 -60
- package/dist/types/utils/mocks.d.ts +0 -12
- package/dist/types/view/common/UnauthorisedViewContent.d.ts +1 -1
- package/dist/types-ts4.5/state/analytics/useSmartLinkAnalytics.d.ts +1 -101
- package/dist/types-ts4.5/state/hooks/useSmartLink.d.ts +0 -12
- package/dist/types-ts4.5/utils/analytics/analytics.d.ts +1 -51
- package/dist/types-ts4.5/utils/analytics/index.d.ts +1 -1
- package/dist/types-ts4.5/utils/analytics/types.d.ts +0 -60
- package/dist/types-ts4.5/utils/mocks.d.ts +0 -12
- package/dist/types-ts4.5/view/common/UnauthorisedViewContent.d.ts +1 -1
- package/package.json +2 -5
|
@@ -8,7 +8,6 @@ import React, { useCallback, useEffect, useMemo, useRef } from 'react';
|
|
|
8
8
|
import { jsx } from '@emotion/react';
|
|
9
9
|
import { useAnalyticsEvents as useAnalyticsEventsNext } from '@atlaskit/analytics-next';
|
|
10
10
|
import { useSmartLinkContext } from '@atlaskit/link-provider';
|
|
11
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
12
11
|
import { useAnalyticsEvents } from '../../../common/analytics/generated/use-analytics-events';
|
|
13
12
|
import { CardDisplay, SmartLinkPosition, SmartLinkSize } from '../../../constants';
|
|
14
13
|
import { useSmartLinkAnalytics } from '../../../state/analytics';
|
|
@@ -56,17 +55,13 @@ const HoverCardContent = ({
|
|
|
56
55
|
const isAISummaryEnabled = getIsAISummaryEnabled(isAdminHubAIEnabled, cardState.details);
|
|
57
56
|
const services = getServices(linkState.details);
|
|
58
57
|
const statusRef = useRef(linkStatus);
|
|
59
|
-
const analyticsRef = useRef(analytics);
|
|
60
58
|
const fireEventRef = useRef(fireEvent);
|
|
61
59
|
const definitionIdRef = useRef(definitionId);
|
|
62
60
|
useEffect(() => {
|
|
63
61
|
/**
|
|
64
|
-
* Must access
|
|
62
|
+
* Must access object value via ref because its not stable
|
|
65
63
|
* and it can trigger useEffect to re-run below
|
|
66
64
|
*/
|
|
67
|
-
if (analyticsRef.current !== analytics) {
|
|
68
|
-
analyticsRef.current = analytics;
|
|
69
|
-
}
|
|
70
65
|
if (statusRef.current !== linkStatus) {
|
|
71
66
|
statusRef.current = linkStatus;
|
|
72
67
|
}
|
|
@@ -76,66 +71,39 @@ const HoverCardContent = ({
|
|
|
76
71
|
if (definitionIdRef.current !== definitionId) {
|
|
77
72
|
definitionIdRef.current = definitionId;
|
|
78
73
|
}
|
|
79
|
-
}, [
|
|
74
|
+
}, [linkStatus, fireEvent, definitionId]);
|
|
80
75
|
useEffect(() => {
|
|
76
|
+
var _definitionIdRef$curr;
|
|
81
77
|
const previewDisplay = 'card';
|
|
82
78
|
const previewInvokeMethod = 'mouse_hover';
|
|
83
79
|
const cardOpenTime = Date.now();
|
|
84
80
|
const fireEventCurrent = fireEventRef.current;
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
81
|
+
fireEventCurrent('ui.hoverCard.viewed', {
|
|
82
|
+
previewDisplay,
|
|
83
|
+
previewInvokeMethod,
|
|
84
|
+
definitionId: (_definitionIdRef$curr = definitionIdRef.current) !== null && _definitionIdRef$curr !== void 0 ? _definitionIdRef$curr : null
|
|
85
|
+
});
|
|
86
|
+
return () => {
|
|
87
|
+
var _definitionIdRef$curr2;
|
|
88
|
+
const hoverTime = Date.now() - cardOpenTime;
|
|
89
|
+
fireEventCurrent('ui.hoverCard.dismissed', {
|
|
94
90
|
previewDisplay,
|
|
95
91
|
previewInvokeMethod,
|
|
96
|
-
|
|
92
|
+
hoverTime,
|
|
93
|
+
definitionId: (_definitionIdRef$curr2 = definitionIdRef.current) !== null && _definitionIdRef$curr2 !== void 0 ? _definitionIdRef$curr2 : null
|
|
97
94
|
});
|
|
98
|
-
}
|
|
99
|
-
return () => {
|
|
100
|
-
const hoverTime = Date.now() - cardOpenTime;
|
|
101
|
-
if (fg('platform_migrate-some-ui-events-smart-card')) {
|
|
102
|
-
var _definitionIdRef$curr2;
|
|
103
|
-
fireEventCurrent('ui.hoverCard.dismissed', {
|
|
104
|
-
previewDisplay,
|
|
105
|
-
previewInvokeMethod,
|
|
106
|
-
hoverTime,
|
|
107
|
-
definitionId: (_definitionIdRef$curr2 = definitionIdRef.current) !== null && _definitionIdRef$curr2 !== void 0 ? _definitionIdRef$curr2 : null
|
|
108
|
-
});
|
|
109
|
-
} else {
|
|
110
|
-
analyticsRef.current.ui.hoverCardDismissedEvent({
|
|
111
|
-
previewDisplay,
|
|
112
|
-
previewInvokeMethod,
|
|
113
|
-
hoverTime,
|
|
114
|
-
status: statusRef.current
|
|
115
|
-
});
|
|
116
|
-
}
|
|
117
95
|
};
|
|
118
96
|
}, []);
|
|
119
97
|
const onClick = useCallback(event => {
|
|
120
98
|
const isModifierKeyPressed = isSpecialEvent(event);
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
});
|
|
128
|
-
} else {
|
|
129
|
-
analytics.ui.cardClickedEvent({
|
|
130
|
-
id,
|
|
131
|
-
display: CardDisplay.HoverCardPreview,
|
|
132
|
-
status: cardState.status,
|
|
133
|
-
isModifierKeyPressed,
|
|
134
|
-
actionSubjectId: 'titleGoToLink'
|
|
135
|
-
});
|
|
136
|
-
}
|
|
99
|
+
fireEvent('ui.smartLink.clicked.titleGoToLink', {
|
|
100
|
+
id,
|
|
101
|
+
display: CardDisplay.HoverCardPreview,
|
|
102
|
+
isModifierKeyPressed,
|
|
103
|
+
definitionId: definitionId !== null && definitionId !== void 0 ? definitionId : null
|
|
104
|
+
});
|
|
137
105
|
fireLinkClickedEvent(createAnalyticsEvent)(event);
|
|
138
|
-
}, [createAnalyticsEvent,
|
|
106
|
+
}, [createAnalyticsEvent, id, fireEvent, definitionId]);
|
|
139
107
|
const data = (_cardState$details = cardState.details) === null || _cardState$details === void 0 ? void 0 : _cardState$details.data;
|
|
140
108
|
const {
|
|
141
109
|
subtitle
|
|
@@ -10,7 +10,7 @@ import LinkWarningModal from './LinkWarningModal';
|
|
|
10
10
|
import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
|
|
11
11
|
const PACKAGE_DATA = {
|
|
12
12
|
packageName: "@atlaskit/smart-card",
|
|
13
|
-
packageVersion: "32.7.
|
|
13
|
+
packageVersion: "32.7.8",
|
|
14
14
|
componentName: 'linkUrl'
|
|
15
15
|
};
|
|
16
16
|
const Anchor = withLinkClickedEvent('a');
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import React, { useCallback } from 'react';
|
|
3
3
|
import { FormattedMessage } from 'react-intl-next';
|
|
4
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
5
4
|
import { useAnalyticsEvents } from '../../common/analytics/generated/use-analytics-events';
|
|
6
5
|
import { CONTENT_URL_3P_ACCOUNT_AUTH, CONTENT_URL_SECURITY_AND_PERMISSIONS } from '../../constants';
|
|
7
6
|
import { messages } from '../../messages';
|
|
@@ -12,19 +11,14 @@ import { messages } from '../../messages';
|
|
|
12
11
|
const UnauthorisedViewContent = ({
|
|
13
12
|
providerName,
|
|
14
13
|
isProductIntegrationSupported,
|
|
15
|
-
testId = 'unauthorised-view-content'
|
|
16
|
-
analytics
|
|
14
|
+
testId = 'unauthorised-view-content'
|
|
17
15
|
}) => {
|
|
18
16
|
const {
|
|
19
17
|
fireEvent
|
|
20
18
|
} = useAnalyticsEvents();
|
|
21
19
|
const handleLearnMoreClick = useCallback(() => {
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
} else {
|
|
25
|
-
analytics === null || analytics === void 0 ? void 0 : analytics.ui.learnMoreClickedEvent();
|
|
26
|
-
}
|
|
27
|
-
}, [analytics === null || analytics === void 0 ? void 0 : analytics.ui, fireEvent]);
|
|
20
|
+
fireEvent('ui.button.clicked.learnMore', {});
|
|
21
|
+
}, [fireEvent]);
|
|
28
22
|
const learnMoreMessage = isProductIntegrationSupported ? messages.learn_more_about_connecting_account : messages.learn_more_about_smart_links;
|
|
29
23
|
return /*#__PURE__*/React.createElement(React.Fragment, null, providerName ? /*#__PURE__*/React.createElement(FormattedMessage, _extends({}, messages.connect_unauthorised_account_description, {
|
|
30
24
|
values: {
|
|
@@ -11,7 +11,6 @@ import extractFollowAction from './extract-follow-action';
|
|
|
11
11
|
import { extractPreviewAction, extractPreviewClientAction } from './extract-preview-action';
|
|
12
12
|
import { extractViewRelatedLinksAction } from './extract-view-related-links-action';
|
|
13
13
|
export var extractFlexibleCardActions = function extractFlexibleCardActions(_ref) {
|
|
14
|
-
var _objectSpread2;
|
|
15
14
|
var actionOptions = _ref.actionOptions,
|
|
16
15
|
aiSummaryConfig = _ref.aiSummaryConfig,
|
|
17
16
|
appearance = _ref.appearance,
|
|
@@ -20,24 +19,24 @@ export var extractFlexibleCardActions = function extractFlexibleCardActions(_ref
|
|
|
20
19
|
origin = _ref.origin,
|
|
21
20
|
response = _ref.response,
|
|
22
21
|
url = _ref.url;
|
|
23
|
-
var action = _objectSpread((
|
|
22
|
+
var action = _objectSpread(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, ActionName.CopyLinkAction, extractCopyLinkClientAction({
|
|
24
23
|
actionOptions: actionOptions,
|
|
25
24
|
appearance: appearance,
|
|
26
25
|
id: id,
|
|
27
26
|
response: response
|
|
28
|
-
})),
|
|
27
|
+
})), ActionName.DownloadAction, extractDownloadClientAction({
|
|
29
28
|
actionOptions: actionOptions,
|
|
30
29
|
appearance: appearance,
|
|
31
30
|
id: id,
|
|
32
31
|
response: response
|
|
33
|
-
})),
|
|
32
|
+
})), ActionName.FollowAction, extractFollowAction(response, actionOptions, id)), ActionName.PreviewAction, extractPreviewClientAction({
|
|
34
33
|
actionOptions: actionOptions,
|
|
35
34
|
appearance: appearance,
|
|
36
35
|
fireEvent: fireEvent,
|
|
37
36
|
id: id,
|
|
38
37
|
origin: origin,
|
|
39
38
|
response: response
|
|
40
|
-
})),
|
|
39
|
+
})), ActionName.AutomationAction, extractAutomationAction(response)), InternalActionName.AISummaryAction, extractAISummaryAction(response, url, actionOptions, aiSummaryConfig)), fg('platform-smart-card-view-related-urls-action') ? _defineProperty({}, InternalActionName.ViewRelatedLinksAction, extractViewRelatedLinksAction(response)) : {});
|
|
41
40
|
return Object.values(action).some(function (value) {
|
|
42
41
|
return Boolean(value);
|
|
43
42
|
}) ? action : undefined;
|
|
@@ -48,9 +47,8 @@ export var extractFlexibleCardActions = function extractFlexibleCardActions(_ref
|
|
|
48
47
|
* Replaced with extractFlexibleCardActions()
|
|
49
48
|
*/
|
|
50
49
|
var extractActions = function extractActions(response, url, actionOptions, id, aiSummaryConfig) {
|
|
51
|
-
var _objectSpread3;
|
|
52
50
|
var data = response.data;
|
|
53
|
-
var action = _objectSpread((
|
|
51
|
+
var action = _objectSpread(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty(_defineProperty({}, ActionName.CopyLinkAction, extractCopyLinkAction(data, actionOptions)), ActionName.DownloadAction, extractDownloadAction(data, actionOptions)), ActionName.FollowAction, extractFollowAction(response, actionOptions, id)), ActionName.PreviewAction, extractPreviewAction(response, actionOptions)), ActionName.AutomationAction, extractAutomationAction(response)), InternalActionName.AISummaryAction, extractAISummaryAction(response, url, actionOptions, aiSummaryConfig)), fg('platform-smart-card-view-related-urls-action') ? _defineProperty({}, InternalActionName.ViewRelatedLinksAction, extractViewRelatedLinksAction(response)) : {});
|
|
54
52
|
return Object.values(action).some(function (value) {
|
|
55
53
|
return Boolean(value);
|
|
56
54
|
}) ? action : undefined;
|
|
@@ -4,7 +4,6 @@ import { useCallback, useMemo } from 'react';
|
|
|
4
4
|
import { useSmartLinkContext } from '@atlaskit/link-provider';
|
|
5
5
|
import { ACTION_RESOLVING, ACTION_UPDATE_METADATA_STATUS, cardAction } from '@atlaskit/linking-common';
|
|
6
6
|
import { auth } from '@atlaskit/outbound-auth-flow-client';
|
|
7
|
-
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
7
|
import { useAnalyticsEvents } from '../../common/analytics/generated/use-analytics-events';
|
|
9
8
|
import { SmartLinkStatus } from '../../constants';
|
|
10
9
|
import { startUfoExperience } from '../analytics';
|
|
@@ -100,32 +99,16 @@ export var useSmartCardActions = function useSmartCardActions(id, url, analytics
|
|
|
100
99
|
var services = getServices(details);
|
|
101
100
|
// When authentication is triggered, let GAS know!
|
|
102
101
|
if (status === 'unauthorized') {
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
});
|
|
108
|
-
} else {
|
|
109
|
-
analytics.ui.authEvent({
|
|
110
|
-
display: appearance,
|
|
111
|
-
definitionId: definitionId,
|
|
112
|
-
extensionKey: extensionKey
|
|
113
|
-
});
|
|
114
|
-
}
|
|
102
|
+
fireEvent('ui.button.clicked.connectAccount', {
|
|
103
|
+
display: appearance,
|
|
104
|
+
definitionId: definitionId !== null && definitionId !== void 0 ? definitionId : null
|
|
105
|
+
});
|
|
115
106
|
}
|
|
116
107
|
if (status === 'forbidden') {
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
});
|
|
122
|
-
} else {
|
|
123
|
-
analytics.ui.authAlternateAccountEvent({
|
|
124
|
-
display: appearance,
|
|
125
|
-
definitionId: definitionId,
|
|
126
|
-
extensionKey: extensionKey
|
|
127
|
-
});
|
|
128
|
-
}
|
|
108
|
+
fireEvent('ui.smartLink.clicked.tryAnotherAccount', {
|
|
109
|
+
display: appearance,
|
|
110
|
+
definitionId: definitionId !== null && definitionId !== void 0 ? definitionId : null
|
|
111
|
+
});
|
|
129
112
|
}
|
|
130
113
|
if (services.length > 0) {
|
|
131
114
|
fireEvent('screen.consentModal.viewed', {
|
|
@@ -154,23 +137,15 @@ export var useSmartCardActions = function useSmartCardActions(id, url, analytics
|
|
|
154
137
|
reason: (_err$type = err.type) !== null && _err$type !== void 0 ? _err$type : null
|
|
155
138
|
});
|
|
156
139
|
if (err.type === 'auth_window_closed') {
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
});
|
|
162
|
-
} else {
|
|
163
|
-
analytics.ui.closedAuthEvent({
|
|
164
|
-
display: appearance,
|
|
165
|
-
definitionId: definitionId,
|
|
166
|
-
extensionKey: extensionKey
|
|
167
|
-
});
|
|
168
|
-
}
|
|
140
|
+
fireEvent('ui.consentModal.closed', {
|
|
141
|
+
display: appearance,
|
|
142
|
+
definitionId: definitionId !== null && definitionId !== void 0 ? definitionId : null
|
|
143
|
+
});
|
|
169
144
|
}
|
|
170
145
|
reload();
|
|
171
146
|
});
|
|
172
147
|
}
|
|
173
|
-
}, [getSmartLinkState,
|
|
148
|
+
}, [getSmartLinkState, id, reload, fireEvent]);
|
|
174
149
|
var invoke = useCallback( /*#__PURE__*/function () {
|
|
175
150
|
var _ref3 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee2(opts, appearance) {
|
|
176
151
|
var key, action, source;
|