@atlaskit/smart-card 44.23.0 → 44.23.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 +16 -0
- package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-false.png +2 -2
- package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-true.png +2 -2
- package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default.png +3 -0
- package/dist/cjs/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
- package/dist/cjs/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
- package/dist/cjs/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
- package/dist/cjs/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
- package/dist/cjs/__tests__/vr-tests/__snapshots__/inline-card/inline-card-resolved-view-with-rovo-actions-cta-treatment---default.png +2 -2
- package/dist/cjs/__tests__/vr-tests/__snapshots__/inline-card/inline-card-with-entity-support--default.png +2 -2
- package/dist/cjs/extractors/common/icon/extractIconFromDocument.js +6 -14
- package/dist/cjs/extractors/flexible/actions/extract-rovo-chat-action.js +2 -4
- package/dist/cjs/extractors/flexible/actions/index.js +1 -1
- package/dist/cjs/extractors/flexible/index.js +1 -1
- package/dist/cjs/state/hooks/use-rovo-chat/index.js +1 -1
- package/dist/cjs/utils/analytics/analytics.js +1 -1
- package/dist/cjs/utils/index.js +23 -75
- package/dist/cjs/view/CardWithUrl/component.js +3 -3
- package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/action-button.compiled.css +0 -9
- package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +7 -28
- package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/index.js +1 -10
- package/dist/cjs/view/FlexibleCard/components/actions/ai-summary-action/ai-summarise-action.js +1 -2
- package/dist/cjs/view/FlexibleCard/components/actions/ai-summary-action/ai-summary-action-component.js +1 -2
- package/dist/cjs/view/FlexibleCard/components/actions/automation-action/index.js +1 -2
- package/dist/cjs/view/FlexibleCard/components/actions/copy-link-action/index.js +1 -2
- package/dist/cjs/view/FlexibleCard/components/actions/follow-action/index.js +1 -2
- package/dist/cjs/view/FlexibleCard/components/actions/preview-action/index.js +2 -3
- package/dist/cjs/view/FlexibleCard/components/actions/rovo-chat-action/index.js +0 -7
- package/dist/cjs/view/FlexibleCard/components/actions/view-related-links-action/index.js +2 -3
- package/dist/cjs/view/FlexibleCard/components/blocks/action-block/index.compiled.css +2 -6
- package/dist/cjs/view/FlexibleCard/components/blocks/action-block/index.js +4 -26
- package/dist/cjs/view/FlexibleCard/components/blocks/hover-card-footer-block/index.compiled.css +0 -1
- package/dist/cjs/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +1 -4
- package/dist/cjs/view/FlexibleCard/components/common/atlaskit-icon/index.js +34 -36
- package/dist/cjs/view/FlexibleCard/index.js +2 -2
- package/dist/cjs/view/HoverCard/components/HoverCardContent.js +7 -15
- package/dist/cjs/view/HoverCard/components/views/resolved/index.js +4 -11
- package/dist/cjs/view/InlineCard/ResolvedView/InlineCardResolvedViewFunctional.js +2 -8
- package/dist/cjs/view/LinkUrl/index.js +1 -1
- package/dist/cjs/view/common/ai-summary/index.js +1 -3
- package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-false.png +2 -2
- package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-true.png +2 -2
- package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default.png +3 -0
- package/dist/es2019/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
- package/dist/es2019/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
- package/dist/es2019/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
- package/dist/es2019/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
- package/dist/es2019/__tests__/vr-tests/__snapshots__/inline-card/inline-card-resolved-view-with-rovo-actions-cta-treatment---default.png +2 -2
- package/dist/es2019/__tests__/vr-tests/__snapshots__/inline-card/inline-card-with-entity-support--default.png +2 -2
- package/dist/es2019/extractors/common/icon/extractIconFromDocument.js +6 -14
- package/dist/es2019/extractors/flexible/actions/extract-rovo-chat-action.js +2 -4
- package/dist/es2019/extractors/flexible/actions/index.js +1 -1
- package/dist/es2019/extractors/flexible/index.js +1 -1
- package/dist/es2019/state/hooks/use-rovo-chat/index.js +1 -1
- package/dist/es2019/utils/analytics/analytics.js +1 -1
- package/dist/es2019/utils/index.js +3 -26
- package/dist/es2019/view/CardWithUrl/component.js +3 -4
- package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/action-button.compiled.css +0 -9
- package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +7 -28
- package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/index.js +1 -10
- package/dist/es2019/view/FlexibleCard/components/actions/ai-summary-action/ai-summarise-action.js +1 -2
- package/dist/es2019/view/FlexibleCard/components/actions/ai-summary-action/ai-summary-action-component.js +1 -2
- package/dist/es2019/view/FlexibleCard/components/actions/automation-action/index.js +1 -2
- package/dist/es2019/view/FlexibleCard/components/actions/copy-link-action/index.js +1 -2
- package/dist/es2019/view/FlexibleCard/components/actions/follow-action/index.js +1 -2
- package/dist/es2019/view/FlexibleCard/components/actions/preview-action/index.js +2 -3
- package/dist/es2019/view/FlexibleCard/components/actions/rovo-chat-action/index.js +0 -7
- package/dist/es2019/view/FlexibleCard/components/actions/view-related-links-action/index.js +2 -3
- package/dist/es2019/view/FlexibleCard/components/blocks/action-block/index.compiled.css +2 -6
- package/dist/es2019/view/FlexibleCard/components/blocks/action-block/index.js +4 -26
- package/dist/es2019/view/FlexibleCard/components/blocks/hover-card-footer-block/index.compiled.css +0 -1
- package/dist/es2019/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +1 -4
- package/dist/es2019/view/FlexibleCard/components/common/atlaskit-icon/index.js +34 -36
- package/dist/es2019/view/FlexibleCard/index.js +2 -2
- package/dist/es2019/view/HoverCard/components/HoverCardContent.js +7 -16
- package/dist/es2019/view/HoverCard/components/views/resolved/index.js +3 -11
- package/dist/es2019/view/InlineCard/ResolvedView/InlineCardResolvedViewFunctional.js +3 -10
- package/dist/es2019/view/LinkUrl/index.js +1 -1
- package/dist/es2019/view/common/ai-summary/index.js +1 -3
- package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-false.png +2 -2
- package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-true.png +2 -2
- package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default.png +3 -0
- package/dist/esm/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
- package/dist/esm/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
- package/dist/esm/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
- package/dist/esm/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
- package/dist/esm/__tests__/vr-tests/__snapshots__/inline-card/inline-card-resolved-view-with-rovo-actions-cta-treatment---default.png +2 -2
- package/dist/esm/__tests__/vr-tests/__snapshots__/inline-card/inline-card-with-entity-support--default.png +2 -2
- package/dist/esm/extractors/common/icon/extractIconFromDocument.js +6 -14
- package/dist/esm/extractors/flexible/actions/extract-rovo-chat-action.js +2 -4
- package/dist/esm/extractors/flexible/actions/index.js +1 -1
- package/dist/esm/extractors/flexible/index.js +1 -1
- package/dist/esm/state/hooks/use-rovo-chat/index.js +1 -1
- package/dist/esm/utils/analytics/analytics.js +1 -1
- package/dist/esm/utils/index.js +23 -63
- package/dist/esm/view/CardWithUrl/component.js +3 -3
- package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/action-button.compiled.css +0 -9
- package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +7 -28
- package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/index.js +1 -10
- package/dist/esm/view/FlexibleCard/components/actions/ai-summary-action/ai-summarise-action.js +1 -2
- package/dist/esm/view/FlexibleCard/components/actions/ai-summary-action/ai-summary-action-component.js +1 -2
- package/dist/esm/view/FlexibleCard/components/actions/automation-action/index.js +1 -2
- package/dist/esm/view/FlexibleCard/components/actions/copy-link-action/index.js +1 -2
- package/dist/esm/view/FlexibleCard/components/actions/follow-action/index.js +1 -2
- package/dist/esm/view/FlexibleCard/components/actions/preview-action/index.js +2 -3
- package/dist/esm/view/FlexibleCard/components/actions/rovo-chat-action/index.js +0 -7
- package/dist/esm/view/FlexibleCard/components/actions/view-related-links-action/index.js +2 -3
- package/dist/esm/view/FlexibleCard/components/blocks/action-block/index.compiled.css +2 -6
- package/dist/esm/view/FlexibleCard/components/blocks/action-block/index.js +4 -26
- package/dist/esm/view/FlexibleCard/components/blocks/hover-card-footer-block/index.compiled.css +0 -1
- package/dist/esm/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +1 -4
- package/dist/esm/view/FlexibleCard/components/common/atlaskit-icon/index.js +34 -36
- package/dist/esm/view/FlexibleCard/index.js +2 -2
- package/dist/esm/view/HoverCard/components/HoverCardContent.js +7 -15
- package/dist/esm/view/HoverCard/components/views/resolved/index.js +4 -11
- package/dist/esm/view/InlineCard/ResolvedView/InlineCardResolvedViewFunctional.js +3 -9
- package/dist/esm/view/LinkUrl/index.js +1 -1
- package/dist/esm/view/common/ai-summary/index.js +1 -3
- package/dist/types/view/FlexibleCard/components/blocks/action-block/types.d.ts +1 -1
- package/dist/types/view/FlexibleCard/components/blocks/ai-summary-block/types.d.ts +2 -2
- package/dist/types/view/HoverCard/components/views/resolved/index.d.ts +1 -1
- package/dist/types-ts4.5/view/FlexibleCard/components/blocks/action-block/types.d.ts +1 -1
- package/dist/types-ts4.5/view/FlexibleCard/components/blocks/ai-summary-block/types.d.ts +2 -2
- package/dist/types-ts4.5/view/HoverCard/components/views/resolved/index.d.ts +1 -1
- package/package.json +5 -8
- package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-generic-3p-rovo-chat-action--default.png +0 -3
- package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-false.png +0 -3
- package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-true.png +0 -3
- package/dist/cjs/state/hooks/use-inline-action-nudge-experiment/index.js +0 -54
- package/dist/cjs/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.compiled.css +0 -15
- package/dist/cjs/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.js +0 -44
- package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-generic-3p-rovo-chat-action--default.png +0 -3
- package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-false.png +0 -3
- package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-true.png +0 -3
- package/dist/es2019/state/hooks/use-inline-action-nudge-experiment/index.js +0 -48
- package/dist/es2019/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.compiled.css +0 -15
- package/dist/es2019/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.js +0 -36
- package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-generic-3p-rovo-chat-action--default.png +0 -3
- package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-false.png +0 -3
- package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-true.png +0 -3
- package/dist/esm/state/hooks/use-inline-action-nudge-experiment/index.js +0 -47
- package/dist/esm/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.compiled.css +0 -15
- package/dist/esm/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.js +0 -35
- package/dist/types/state/hooks/use-inline-action-nudge-experiment/index.d.ts +0 -24
- package/dist/types/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.d.ts +0 -12
- package/dist/types-ts4.5/state/hooks/use-inline-action-nudge-experiment/index.d.ts +0 -24
- package/dist/types-ts4.5/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.d.ts +0 -12
|
@@ -33,42 +33,40 @@ const AtlaskitIcon = ({
|
|
|
33
33
|
size = SmartLinkSize.Medium,
|
|
34
34
|
isTiledIcon
|
|
35
35
|
}) => {
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
}
|
|
71
|
-
}
|
|
36
|
+
// Intentionally keep these three icon types synchronous and outside lazy imports.
|
|
37
|
+
// These icons should be present in SSR markup so hydration does not cause a
|
|
38
|
+
// visible empty-state-then-pop-in transition in Smart Link consumers.
|
|
39
|
+
switch (icon) {
|
|
40
|
+
case IconType.Document:
|
|
41
|
+
{
|
|
42
|
+
const DocumentIcon = getDocumentIcon();
|
|
43
|
+
return /*#__PURE__*/React.createElement(DocumentIcon, {
|
|
44
|
+
label: label !== null && label !== void 0 ? label : 'document',
|
|
45
|
+
testId: testId,
|
|
46
|
+
size: size,
|
|
47
|
+
isTiledIcon: isTiledIcon
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
case IconType.Blog:
|
|
51
|
+
{
|
|
52
|
+
const BlogIcon = getBlogIcon();
|
|
53
|
+
return /*#__PURE__*/React.createElement(BlogIcon, {
|
|
54
|
+
label: label !== null && label !== void 0 ? label : 'blog',
|
|
55
|
+
testId: testId,
|
|
56
|
+
size: size,
|
|
57
|
+
isTiledIcon: isTiledIcon
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
case IconType.LiveDocument:
|
|
61
|
+
{
|
|
62
|
+
const LiveDocumentIcon = getLiveDocumentIcon();
|
|
63
|
+
return /*#__PURE__*/React.createElement(LiveDocumentIcon, {
|
|
64
|
+
label: label !== null && label !== void 0 ? label : 'live-doc',
|
|
65
|
+
testId: testId,
|
|
66
|
+
size: size,
|
|
67
|
+
isTiledIcon: isTiledIcon
|
|
68
|
+
});
|
|
69
|
+
}
|
|
72
70
|
}
|
|
73
71
|
const importFn = getIconImportFn(icon, size);
|
|
74
72
|
if (!importFn) {
|
|
@@ -49,7 +49,7 @@ const FlexibleCard = ({
|
|
|
49
49
|
openPreviewPanel,
|
|
50
50
|
product
|
|
51
51
|
} = useSmartLinkContext();
|
|
52
|
-
const rovoConfig = fg('platform_sl_3p_auth_rovo_action_kill_switch')
|
|
52
|
+
const rovoConfig = fg('platform_sl_3p_auth_rovo_action_kill_switch') ?
|
|
53
53
|
// eslint-disable-next-line react-hooks/rules-of-hooks
|
|
54
54
|
useRovoConfig() : undefined;
|
|
55
55
|
const {
|
|
@@ -78,7 +78,7 @@ const FlexibleCard = ({
|
|
|
78
78
|
origin,
|
|
79
79
|
renderers,
|
|
80
80
|
resolve,
|
|
81
|
-
...(fg('platform_sl_3p_auth_rovo_action_kill_switch')
|
|
81
|
+
...(fg('platform_sl_3p_auth_rovo_action_kill_switch') ? {
|
|
82
82
|
product,
|
|
83
83
|
rovoConfig
|
|
84
84
|
} : undefined),
|
|
@@ -10,7 +10,6 @@ import { useAnalyticsEvents } from '../../../common/analytics/generated/use-anal
|
|
|
10
10
|
import { CardDisplay, SmartLinkPosition, SmartLinkSize } from '../../../constants';
|
|
11
11
|
import extractRovoChatAction from '../../../extractors/flexible/actions/extract-rovo-chat-action';
|
|
12
12
|
import { getDefinitionId, getExtensionKey, getServices } from '../../../state/helpers';
|
|
13
|
-
import useInlineActionNudgeExperiment from '../../../state/hooks/use-inline-action-nudge-experiment';
|
|
14
13
|
import useRovoConfig from '../../../state/hooks/use-rovo-config';
|
|
15
14
|
import { useSmartCardState } from '../../../state/store';
|
|
16
15
|
import { isSpecialEvent } from '../../../utils';
|
|
@@ -224,9 +223,8 @@ const HoverCardContent = ({
|
|
|
224
223
|
flexibleCardProps: flexibleCardProps
|
|
225
224
|
});
|
|
226
225
|
}
|
|
227
|
-
const is3PInlinePostAuthActionsEnabled = fg('rovogrowth-640-inline-action-nudge-fg') && expValEqualsNoExposure('rovogrowth-640-inline-action-nudge-exp', 'isEnabled', true);
|
|
228
226
|
if (isResolved) {
|
|
229
|
-
return /*#__PURE__*/React.createElement(HoverCardResolvedView, _extends({}, fg('platform_sl_3p_auth_rovo_action_kill_switch')
|
|
227
|
+
return /*#__PURE__*/React.createElement(HoverCardResolvedView, _extends({}, fg('platform_sl_3p_auth_rovo_action_kill_switch') ? {
|
|
230
228
|
actionOptions,
|
|
231
229
|
showRovoResolvedView
|
|
232
230
|
} : undefined, {
|
|
@@ -277,9 +275,8 @@ const HoverCardContent = ({
|
|
|
277
275
|
flexibleCardProps: flexibleCardProps
|
|
278
276
|
});
|
|
279
277
|
}
|
|
280
|
-
const is3PInlinePostAuthActionsEnabled = fg('rovogrowth-640-inline-action-nudge-fg') && expValEqualsNoExposure('rovogrowth-640-inline-action-nudge-exp', 'isEnabled', true);
|
|
281
278
|
if (cardState.status === 'resolved') {
|
|
282
|
-
return /*#__PURE__*/React.createElement(HoverCardResolvedView, _extends({}, fg('platform_sl_3p_auth_rovo_action_kill_switch')
|
|
279
|
+
return /*#__PURE__*/React.createElement(HoverCardResolvedView, _extends({}, fg('platform_sl_3p_auth_rovo_action_kill_switch') ? {
|
|
283
280
|
actionOptions,
|
|
284
281
|
showRovoResolvedView
|
|
285
282
|
} : undefined, {
|
|
@@ -306,8 +303,7 @@ const HoverCardContent = ({
|
|
|
306
303
|
const HoverCardContentWithViewVariant = props => {
|
|
307
304
|
const {
|
|
308
305
|
cardState,
|
|
309
|
-
actionOptions
|
|
310
|
-
url
|
|
306
|
+
actionOptions
|
|
311
307
|
} = props;
|
|
312
308
|
const rovoConfig = useRovoConfig();
|
|
313
309
|
const isResolved = useIsResolvedView(props);
|
|
@@ -317,23 +313,19 @@ const HoverCardContentWithViewVariant = props => {
|
|
|
317
313
|
rovoConfig,
|
|
318
314
|
actionOptions
|
|
319
315
|
}) !== undefined, [actionOptions, cardState.details, rovoConfig, isResolved]);
|
|
320
|
-
const {
|
|
321
|
-
isEnabled: rovoActionsCtaShown
|
|
322
|
-
} = useInlineActionNudgeExperiment(url, true, actionOptions);
|
|
323
316
|
const data = useMemo(() => {
|
|
324
317
|
let viewVariant = 'default';
|
|
325
|
-
if (showRovoResolvedView &&
|
|
318
|
+
if (showRovoResolvedView && expValEqualsNoExposure('platform_sl_3p_auth_rovo_action', 'isEnabled', true)) {
|
|
326
319
|
viewVariant = 'rovo-resolved-view';
|
|
327
320
|
} else if (showPreauthBetterHovercard) {
|
|
328
321
|
viewVariant = 'rovo-unauthorised-view';
|
|
329
322
|
}
|
|
330
323
|
return {
|
|
331
324
|
attributes: {
|
|
332
|
-
viewVariant
|
|
333
|
-
rovoActionsCtaShown
|
|
325
|
+
viewVariant
|
|
334
326
|
}
|
|
335
327
|
};
|
|
336
|
-
}, [showRovoResolvedView, showPreauthBetterHovercard
|
|
328
|
+
}, [showRovoResolvedView, showPreauthBetterHovercard]);
|
|
337
329
|
return /*#__PURE__*/React.createElement(AnalyticsContext, {
|
|
338
330
|
data: data
|
|
339
331
|
}, /*#__PURE__*/React.createElement(HoverCardContent, _extends({}, props, {
|
|
@@ -344,7 +336,6 @@ const _default_1 = componentWithCondition(() => {
|
|
|
344
336
|
// We need to read both of them to sutisfy some of the tests that expect both to be checked.
|
|
345
337
|
const flagA = fg('platform_sl_3p_preauth_better_hovercard_killswitch');
|
|
346
338
|
const flagB = fg('platform_sl_3p_auth_rovo_action_kill_switch');
|
|
347
|
-
|
|
348
|
-
return flagA || flagB || flagC;
|
|
339
|
+
return flagA || flagB;
|
|
349
340
|
}, HoverCardContentWithViewVariant, HoverCardContent);
|
|
350
341
|
export default _default_1;
|
|
@@ -9,7 +9,6 @@ import { useAnalyticsEvents } from '../../../../../common/analytics/generated/us
|
|
|
9
9
|
import { CardDisplay, SmartLinkPosition, SmartLinkSize } from '../../../../../constants';
|
|
10
10
|
import { succeedUfoExperience } from '../../../../../state/analytics';
|
|
11
11
|
import useAISummaryAction from '../../../../../state/hooks/use-ai-summary-action';
|
|
12
|
-
import useInlineActionNudgeExperiment from '../../../../../state/hooks/use-inline-action-nudge-experiment';
|
|
13
12
|
import FlexibleCard from '../../../../FlexibleCard';
|
|
14
13
|
import { ActionBlock, AIFooterBlock, AISummaryBlock, ResolvedHoverCardFooterBlock, MetadataBlock, SnippetBlock, TitleBlock } from '../../../../FlexibleCard/components/blocks';
|
|
15
14
|
import { getMetadata } from '../../../utils';
|
|
@@ -19,7 +18,6 @@ const titleBlockStyles = null;
|
|
|
19
18
|
const snippetBlockCss = null;
|
|
20
19
|
const actionBlockCss = null;
|
|
21
20
|
const HoverCardResolvedView = ({
|
|
22
|
-
actionOptions,
|
|
23
21
|
cardState,
|
|
24
22
|
extensionKey,
|
|
25
23
|
flexibleCardProps,
|
|
@@ -33,15 +31,9 @@ const HoverCardResolvedView = ({
|
|
|
33
31
|
const {
|
|
34
32
|
fireEvent
|
|
35
33
|
} = useAnalyticsEvents();
|
|
36
|
-
const {
|
|
37
|
-
isEnabled: InlineActionNudgeExperimentValue
|
|
38
|
-
} = useInlineActionNudgeExperiment(flexibleCardProps.url, true, actionOptions);
|
|
39
|
-
|
|
40
34
|
// We want to fire exposure event only for those cases when user otherwise can see the experiment which would be controlled
|
|
41
35
|
// by all the other condition defined above as a result of what was defined in actionOptions as well as in CardContext.
|
|
42
36
|
const is3PAuthRovoActionsExperimentOn = showRovoResolvedView && expValEquals('platform_sl_3p_auth_rovo_action', 'isEnabled', true);
|
|
43
|
-
const is3PInlinePostAuthActionsExperimentOn = showRovoResolvedView && InlineActionNudgeExperimentValue;
|
|
44
|
-
const isAny3pRovoActionsExperimentOn = is3PAuthRovoActionsExperimentOn || is3PInlinePostAuthActionsExperimentOn;
|
|
45
37
|
useEffect(() => {
|
|
46
38
|
// Since this hover view is only rendered on resolved status,
|
|
47
39
|
// there is no need to check for statuses.
|
|
@@ -90,7 +82,7 @@ const HoverCardResolvedView = ({
|
|
|
90
82
|
}), isAISummaryEnabled ? /*#__PURE__*/React.createElement(AISummaryBlock, {
|
|
91
83
|
aiSummaryMinHeight: aiSummaryMinHeight,
|
|
92
84
|
placeholder: snippet,
|
|
93
|
-
isAny3pRovoActionsExperimentOn:
|
|
85
|
+
isAny3pRovoActionsExperimentOn: is3PAuthRovoActionsExperimentOn
|
|
94
86
|
}) : snippet, /*#__PURE__*/React.createElement(SnippetBlock, {
|
|
95
87
|
testId: "hidden-snippet",
|
|
96
88
|
onRender: onSnippetRender,
|
|
@@ -100,9 +92,9 @@ const HoverCardResolvedView = ({
|
|
|
100
92
|
}), /*#__PURE__*/React.createElement(ActionBlock, {
|
|
101
93
|
onClick: onActionClick,
|
|
102
94
|
spaceInline: "space.100",
|
|
103
|
-
isAny3pRovoActionsExperimentOn:
|
|
95
|
+
isAny3pRovoActionsExperimentOn: is3PAuthRovoActionsExperimentOn,
|
|
104
96
|
className: ax(["_n3td1b66"])
|
|
105
|
-
}),
|
|
97
|
+
}), is3PAuthRovoActionsExperimentOn ? /*#__PURE__*/React.createElement(ResolvedHoverCardFooterBlock, {
|
|
106
98
|
onActionClick: onActionClick
|
|
107
99
|
}) : /*#__PURE__*/React.createElement(AIFooterBlock, null));
|
|
108
100
|
};
|
|
@@ -1,10 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { fg } from "@atlaskit/platform-feature-flags";
|
|
3
2
|
import { componentWithFG } from '@atlaskit/platform-feature-flags-react';
|
|
4
|
-
import useInlineActionNudgeExperiment from '../../../state/hooks/use-inline-action-nudge-experiment';
|
|
5
3
|
import useInlineTailoredActionExperiment from '../../../state/hooks/use-inline-tailored-action-experiment';
|
|
6
4
|
import { HoverCard } from '../../HoverCard';
|
|
7
|
-
import {
|
|
5
|
+
import { InlineRovoActionButton } from '../common/rovo-actions-cta';
|
|
8
6
|
import { Frame } from '../Frame';
|
|
9
7
|
import { IconAndTitleLayout } from '../IconAndTitleLayout';
|
|
10
8
|
import { renderLozenge } from './renderLozenge';
|
|
@@ -77,9 +75,6 @@ export function InlineCardResolvedViewFunctionalWithRovoActions({
|
|
|
77
75
|
hideIconLoadingSkeleton,
|
|
78
76
|
lozenge
|
|
79
77
|
}) {
|
|
80
|
-
const {
|
|
81
|
-
isEnabled
|
|
82
|
-
} = useInlineActionNudgeExperiment(link, showHoverPreview, actionOptions);
|
|
83
78
|
const {
|
|
84
79
|
isEnabled: isInlineTailoredRovoActionEnabled
|
|
85
80
|
} = useInlineTailoredActionExperiment(link, showHoverPreview, actionOptions);
|
|
@@ -101,9 +96,7 @@ export function InlineCardResolvedViewFunctionalWithRovoActions({
|
|
|
101
96
|
titleTextColor: titleTextColor,
|
|
102
97
|
type: type,
|
|
103
98
|
hideIconLoadingSkeleton: hideIconLoadingSkeleton
|
|
104
|
-
}), renderLozenge(lozenge),
|
|
105
|
-
testId: `${testId}-rovo-actions-cta`
|
|
106
|
-
}), isInlineTailoredRovoActionEnabled && /*#__PURE__*/React.createElement(InlineRovoActionButton, {
|
|
99
|
+
}), renderLozenge(lozenge), isInlineTailoredRovoActionEnabled && /*#__PURE__*/React.createElement(InlineRovoActionButton, {
|
|
107
100
|
testId: `${testId}-rovo-actions-cta`,
|
|
108
101
|
url: link
|
|
109
102
|
}));
|
|
@@ -119,4 +112,4 @@ export function InlineCardResolvedViewFunctionalWithRovoActions({
|
|
|
119
112
|
}
|
|
120
113
|
|
|
121
114
|
// Todo: replace with platform_sl_3p_auth_inline_tailored_cta_killswitch after cleanup of rovogrowth-640-inline-action-nudge-fg
|
|
122
|
-
export const InlineCardResolvedViewFunctional = componentWithFG('
|
|
115
|
+
export const InlineCardResolvedViewFunctional = componentWithFG('platform_sl_3p_auth_inline_tailored_cta_killswitch', InlineCardResolvedViewFunctionalWithRovoActions, InlineCardResolvedViewBase);
|
|
@@ -9,7 +9,7 @@ import LinkWarningModal from './LinkWarningModal';
|
|
|
9
9
|
import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
|
|
10
10
|
const PACKAGE_DATA = {
|
|
11
11
|
packageName: "@atlaskit/smart-card",
|
|
12
|
-
packageVersion: "44.
|
|
12
|
+
packageVersion: "44.23.1",
|
|
13
13
|
componentName: 'linkUrl'
|
|
14
14
|
};
|
|
15
15
|
const LinkUrl = ({
|
|
@@ -26,9 +26,7 @@ const AISummary = ({
|
|
|
26
26
|
}
|
|
27
27
|
const is3pExperimentEnabled =
|
|
28
28
|
// eslint-disable-next-line @atlaskit/platform/no-preconditioning
|
|
29
|
-
fg('platform_sl_3p_auth_rovo_action_kill_switch') && expValEqualsNoExposure('platform_sl_3p_auth_rovo_action', 'isEnabled', true)
|
|
30
|
-
// eslint-disable-next-line @atlaskit/platform/no-preconditioning
|
|
31
|
-
fg('rovogrowth-640-inline-action-nudge-fg') && expValEqualsNoExposure('rovogrowth-640-inline-action-nudge-exp', 'isEnabled', true);
|
|
29
|
+
fg('platform_sl_3p_auth_rovo_action_kill_switch') && expValEqualsNoExposure('platform_sl_3p_auth_rovo_action', 'isEnabled', true);
|
|
32
30
|
return /*#__PURE__*/React.createElement(Markdown, {
|
|
33
31
|
"data-testid": testId
|
|
34
32
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
version https://git-lfs.github.com/spec/v1
|
|
2
|
-
oid sha256:
|
|
3
|
-
size
|
|
2
|
+
oid sha256:e4e629c90112ffa47189f9d7084394fcd9a217bf624a1b05b5adb76909268c96
|
|
3
|
+
size 22340
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
version https://git-lfs.github.com/spec/v1
|
|
2
|
-
oid sha256:
|
|
3
|
-
size
|
|
2
|
+
oid sha256:9d850871e06f9ed1baa276db443eb1747b92e8d5576bbe2af83f7978ddff4652
|
|
3
|
+
size 36435
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
version https://git-lfs.github.com/spec/v1
|
|
2
|
-
oid sha256:
|
|
3
|
-
size
|
|
2
|
+
oid sha256:889ac946e251a99b4da6d9a75cab61cdd97a1649ead5018faa97d6e9a180e9f0
|
|
3
|
+
size 218408
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
version https://git-lfs.github.com/spec/v1
|
|
2
|
-
oid sha256:
|
|
3
|
-
size
|
|
2
|
+
oid sha256:889ac946e251a99b4da6d9a75cab61cdd97a1649ead5018faa97d6e9a180e9f0
|
|
3
|
+
size 218408
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
version https://git-lfs.github.com/spec/v1
|
|
2
|
-
oid sha256:
|
|
3
|
-
size
|
|
2
|
+
oid sha256:d3d9be35e64429a385cfdbfb97e6acf1c220377632d238d33bf9fa42bfa03155
|
|
3
|
+
size 218616
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
version https://git-lfs.github.com/spec/v1
|
|
2
|
-
oid sha256:
|
|
3
|
-
size
|
|
2
|
+
oid sha256:d3d9be35e64429a385cfdbfb97e6acf1c220377632d238d33bf9fa42bfa03155
|
|
3
|
+
size 218616
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
version https://git-lfs.github.com/spec/v1
|
|
2
|
-
oid sha256:
|
|
3
|
-
size
|
|
2
|
+
oid sha256:13d8e863b7dcc6b41eef967c98a4e961078c5442a20e9d14ce373567ec6ea6f9
|
|
3
|
+
size 12894
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
version https://git-lfs.github.com/spec/v1
|
|
2
|
-
oid sha256:
|
|
3
|
-
size
|
|
2
|
+
oid sha256:79dfaed74e187a22da54cdf220a9f681e089542858ba84b0ffeb7e77b787f626
|
|
3
|
+
size 2111
|
|
@@ -1,8 +1,6 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import DocumentFilledIcon from '@atlaskit/icon/core/file';
|
|
3
3
|
import { isConfluenceGenerator } from '@atlaskit/link-extractors';
|
|
4
|
-
import BlogIconObject from '@atlaskit/object/blog';
|
|
5
|
-
import LiveDocumentIconObject from '@atlaskit/object/page-live-doc';
|
|
6
4
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
7
5
|
import { getIconForFileType } from '../../../utils';
|
|
8
6
|
import { prioritiseIcon } from './prioritiseIcon';
|
|
@@ -59,12 +57,9 @@ var documentTypeToIcon = function documentTypeToIcon(type, opts) {
|
|
|
59
57
|
switch (type) {
|
|
60
58
|
case 'schema:BlogPosting':
|
|
61
59
|
{
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
testId: "blog-icon"
|
|
66
|
-
});
|
|
67
|
-
}
|
|
60
|
+
// Intentionally keep this icon on a synchronous require()-based path.
|
|
61
|
+
// This icon must be present in SSR markup so hydration does not cause a
|
|
62
|
+
// visible empty-state-then-pop-in transition for Smart Links.
|
|
68
63
|
var BlogIconWrapped = getBlogIconWrapped();
|
|
69
64
|
return /*#__PURE__*/React.createElement(BlogIconWrapped, {
|
|
70
65
|
label: documentLabel(opts, 'blog'),
|
|
@@ -125,12 +120,9 @@ var documentTypeToIcon = function documentTypeToIcon(type, opts) {
|
|
|
125
120
|
var digitalDocumentToIcon = function digitalDocumentToIcon(opts) {
|
|
126
121
|
var _opts$provider;
|
|
127
122
|
if ((_opts$provider = opts.provider) !== null && _opts$provider !== void 0 && _opts$provider.id && isConfluenceGenerator(opts.provider.id)) {
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
testId: "live-doc-icon"
|
|
132
|
-
});
|
|
133
|
-
}
|
|
123
|
+
// Intentionally keep this icon on a synchronous require()-based path.
|
|
124
|
+
// This icon must be present in SSR markup so hydration does not cause a
|
|
125
|
+
// visible empty-state-then-pop-in transition for Smart Links.
|
|
134
126
|
var LiveDocumentIconWrapped = getLiveDocumentIconWrapped();
|
|
135
127
|
return /*#__PURE__*/React.createElement(LiveDocumentIconWrapped, {
|
|
136
128
|
label: documentLabel(opts, 'live document'),
|
|
@@ -1,12 +1,11 @@
|
|
|
1
1
|
import { extractSmartLinkUrl } from '@atlaskit/link-extractors';
|
|
2
2
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
3
|
-
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
4
3
|
import { ActionName, CardAction } from '../../../constants';
|
|
5
4
|
import { getDefinitionId, getExtensionKey, getResourceType } from '../../../state/helpers';
|
|
6
5
|
import { isBlockCardRovoActionExperimentEnabled } from '../../../state/hooks/use-block-card-rovo-action-experiment';
|
|
7
6
|
import { canShowAction } from '../../../utils/actions/can-show-action';
|
|
8
7
|
import { getIsRovoChatEnabled } from '../../../utils/rovo';
|
|
9
|
-
// For
|
|
8
|
+
// For block card experiment (NAVX-4814)
|
|
10
9
|
var ELIGIBLE_EXTENSION_KEYS = new Set(['slack-object-provider', 'google-object-provider', 'onedrive-object-provider', 'github-object-provider', 'ms-teams-object-provider', 'gitlab-object-provider', 'salesforce-object-provider']);
|
|
11
10
|
var extractRovoChatAction = function extractRovoChatAction(_ref) {
|
|
12
11
|
var _rovoConfig$product, _actionOptions$rovoCh;
|
|
@@ -27,9 +26,8 @@ var extractRovoChatAction = function extractRovoChatAction(_ref) {
|
|
|
27
26
|
var isGoogleProvider = extensionKey === 'google-object-provider';
|
|
28
27
|
var is3PBlockExperimentEnabled = isBlockCardRovoActionExperimentEnabled((_rovoConfig$product = rovoConfig === null || rovoConfig === void 0 ? void 0 : rovoConfig.product) !== null && _rovoConfig$product !== void 0 ? _rovoConfig$product : product);
|
|
29
28
|
var is3PAuthRovoActionEnabled = isGoogleProvider && fg('platform_sl_3p_auth_rovo_action_kill_switch');
|
|
30
|
-
var is3PInlinePostAuthActionsEnabled = extensionKey !== undefined && ELIGIBLE_EXTENSION_KEYS.has(extensionKey) && fg('rovogrowth-640-inline-action-nudge-fg') && expValEqualsNoExposure('rovogrowth-640-inline-action-nudge-exp', 'isEnabled', true);
|
|
31
29
|
var is3PBlockPostAuthActionsEnabled = extensionKey !== undefined && ELIGIBLE_EXTENSION_KEYS.has(extensionKey) && is3PBlockExperimentEnabled;
|
|
32
|
-
var isSupportedFeature =
|
|
30
|
+
var isSupportedFeature = is3PAuthRovoActionEnabled || is3PBlockPostAuthActionsEnabled;
|
|
33
31
|
var isOptIn = (actionOptions === null || actionOptions === void 0 || (_actionOptions$rovoCh = actionOptions.rovoChatAction) === null || _actionOptions$rovoCh === void 0 ? void 0 : _actionOptions$rovoCh.optIn) === true;
|
|
34
32
|
var url = extractSmartLinkUrl(response);
|
|
35
33
|
return isSupportedFeature && isOptIn ? {
|
|
@@ -43,7 +43,7 @@ export var extractFlexibleCardActions = function extractFlexibleCardActions(_ref
|
|
|
43
43
|
response: response,
|
|
44
44
|
isPreviewPanelAvailable: isPreviewPanelAvailable,
|
|
45
45
|
openPreviewPanel: openPreviewPanel
|
|
46
|
-
})), ActionName.AutomationAction, extractAutomationAction(response)), InternalActionName.AISummaryAction, extractAISummaryAction(response, url, actionOptions, aiSummaryConfig)), fg('platform_sl_3p_auth_rovo_action_kill_switch')
|
|
46
|
+
})), ActionName.AutomationAction, extractAutomationAction(response)), InternalActionName.AISummaryAction, extractAISummaryAction(response, url, actionOptions, aiSummaryConfig)), fg('platform_sl_3p_auth_rovo_action_kill_switch') ? _defineProperty({}, ActionName.RovoChatAction, extractRovoChatAction({
|
|
47
47
|
actionOptions: actionOptions,
|
|
48
48
|
appearance: appearance,
|
|
49
49
|
id: id,
|
|
@@ -49,7 +49,7 @@ var extractFlexibleUiContext = function extractFlexibleUiContext() {
|
|
|
49
49
|
fireEvent: fireEvent,
|
|
50
50
|
id: id,
|
|
51
51
|
origin: origin
|
|
52
|
-
}, fg('platform_sl_3p_auth_rovo_action_kill_switch')
|
|
52
|
+
}, fg('platform_sl_3p_auth_rovo_action_kill_switch') ? {
|
|
53
53
|
product: product,
|
|
54
54
|
rovoConfig: rovoConfig
|
|
55
55
|
} : undefined), {}, {
|
|
@@ -29,7 +29,7 @@ var useRovoChat = function useRovoChat() {
|
|
|
29
29
|
agentId: undefined
|
|
30
30
|
}),
|
|
31
31
|
openChat: true,
|
|
32
|
-
openChatMode: isJiraProduct &&
|
|
32
|
+
openChatMode: isJiraProduct && fg('platform_sl_3p_auth_rovo_block_jira_kill_switch') ? 'mini-modal' : 'sidebar'
|
|
33
33
|
},
|
|
34
34
|
onAcknowledgeTimeout: function onAcknowledgeTimeout() {
|
|
35
35
|
// NAVX-3599: Add analytics event
|
|
@@ -4,7 +4,7 @@ export var ANALYTICS_CHANNEL = 'media';
|
|
|
4
4
|
export var context = {
|
|
5
5
|
componentName: 'smart-cards',
|
|
6
6
|
packageName: "@atlaskit/smart-card" || '',
|
|
7
|
-
packageVersion: "44.
|
|
7
|
+
packageVersion: "44.23.1" || ''
|
|
8
8
|
};
|
|
9
9
|
export var TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
10
10
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|