@atlaskit/smart-card 44.1.2 → 44.3.0
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 +22 -0
- package/dist/cjs/__tests__/vr-tests/__snapshots__/block-card/block-card-resolved-icon-variations-resolvedclient-icontesturls-/342/200/224-flexible-extractsmartlinkicon-path---default.png +3 -0
- package/dist/cjs/__tests__/vr-tests/__snapshots__/inline-card/inline-card-resolved-icon-variations-resolvedclient-icontesturls-/342/200/224-extracticon-document-non-document-paths---default.png +3 -0
- package/dist/cjs/constants.js +1 -1
- package/dist/cjs/extractors/flexible/actions/extract-rovo-chat-action.js +3 -2
- package/dist/cjs/extractors/flexible/actions/index.js +1 -1
- package/dist/cjs/messages.js +40 -0
- package/dist/cjs/utils/analytics/analytics.js +1 -1
- package/dist/cjs/view/BlockCard/views/ResolvedView.js +48 -2
- package/dist/cjs/view/FlexibleCard/components/actions/rovo-chat-action/index.js +83 -1
- package/dist/cjs/view/FlexibleCard/components/blocks/action-block/index.js +3 -3
- package/dist/cjs/view/FlexibleCard/components/blocks/action-group/index.js +20 -4
- package/dist/cjs/view/FlexibleCard/components/blocks/footer-block/resolved/index.js +4 -1
- package/dist/cjs/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +1 -1
- package/dist/cjs/view/FlexibleCard/components/blocks/utils.js +11 -0
- package/dist/cjs/view/LinkUrl/index.js +1 -1
- package/dist/es2019/__tests__/vr-tests/__snapshots__/block-card/block-card-resolved-icon-variations-resolvedclient-icontesturls-/342/200/224-flexible-extractsmartlinkicon-path---default.png +3 -0
- package/dist/es2019/__tests__/vr-tests/__snapshots__/inline-card/inline-card-resolved-icon-variations-resolvedclient-icontesturls-/342/200/224-extracticon-document-non-document-paths---default.png +3 -0
- package/dist/es2019/constants.js +1 -1
- package/dist/es2019/extractors/flexible/actions/extract-rovo-chat-action.js +4 -3
- package/dist/es2019/extractors/flexible/actions/index.js +1 -1
- package/dist/es2019/messages.js +40 -0
- package/dist/es2019/utils/analytics/analytics.js +1 -1
- package/dist/es2019/view/BlockCard/views/ResolvedView.js +46 -2
- package/dist/es2019/view/FlexibleCard/components/actions/rovo-chat-action/index.js +84 -2
- package/dist/es2019/view/FlexibleCard/components/blocks/action-block/index.js +3 -3
- package/dist/es2019/view/FlexibleCard/components/blocks/action-group/index.js +20 -5
- package/dist/es2019/view/FlexibleCard/components/blocks/footer-block/resolved/index.js +5 -2
- package/dist/es2019/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +2 -2
- package/dist/es2019/view/FlexibleCard/components/blocks/utils.js +11 -0
- package/dist/es2019/view/LinkUrl/index.js +1 -1
- package/dist/esm/__tests__/vr-tests/__snapshots__/block-card/block-card-resolved-icon-variations-resolvedclient-icontesturls-/342/200/224-flexible-extractsmartlinkicon-path---default.png +3 -0
- package/dist/esm/__tests__/vr-tests/__snapshots__/inline-card/inline-card-resolved-icon-variations-resolvedclient-icontesturls-/342/200/224-extracticon-document-non-document-paths---default.png +3 -0
- package/dist/esm/constants.js +1 -1
- package/dist/esm/extractors/flexible/actions/extract-rovo-chat-action.js +4 -3
- package/dist/esm/extractors/flexible/actions/index.js +1 -1
- package/dist/esm/messages.js +40 -0
- package/dist/esm/utils/analytics/analytics.js +1 -1
- package/dist/esm/view/BlockCard/views/ResolvedView.js +48 -2
- package/dist/esm/view/FlexibleCard/components/actions/rovo-chat-action/index.js +84 -2
- package/dist/esm/view/FlexibleCard/components/blocks/action-block/index.js +4 -4
- package/dist/esm/view/FlexibleCard/components/blocks/action-group/index.js +21 -5
- package/dist/esm/view/FlexibleCard/components/blocks/footer-block/resolved/index.js +5 -2
- package/dist/esm/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +2 -2
- package/dist/esm/view/FlexibleCard/components/blocks/utils.js +11 -0
- package/dist/esm/view/LinkUrl/index.js +1 -1
- package/dist/types/constants.d.ts +2 -2
- package/dist/types/messages.d.ts +1 -1
- package/dist/types/state/flexible-ui-context/types.d.ts +1 -1
- package/dist/types/view/FlexibleCard/components/actions/rovo-chat-action/index.d.ts +5 -1
- package/dist/types/view/FlexibleCard/components/blocks/types.d.ts +1 -1
- package/dist/types-ts4.5/constants.d.ts +2 -2
- package/dist/types-ts4.5/messages.d.ts +1 -1
- package/dist/types-ts4.5/state/flexible-ui-context/types.d.ts +1 -1
- package/dist/types-ts4.5/view/FlexibleCard/components/actions/rovo-chat-action/index.d.ts +5 -1
- package/dist/types-ts4.5/view/FlexibleCard/components/blocks/types.d.ts +1 -1
- package/package.json +11 -11
|
@@ -8,8 +8,9 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
|
|
|
8
8
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
9
9
|
import React, { useCallback, useMemo } from 'react';
|
|
10
10
|
import { useIntl } from 'react-intl';
|
|
11
|
+
import AiGenerativeTextIcon from '@atlaskit/icon-lab/core/ai-generative-text';
|
|
11
12
|
import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
|
|
12
|
-
import {
|
|
13
|
+
import { ActionName } from '../../../../../constants';
|
|
13
14
|
import { messages } from '../../../../../messages';
|
|
14
15
|
import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
|
|
15
16
|
import useInvokeClientAction from '../../../../../state/hooks/use-invoke-client-action';
|
|
@@ -26,6 +27,10 @@ export var RovoChatPromptKey = /*#__PURE__*/function (RovoChatPromptKey) {
|
|
|
26
27
|
RovoChatPromptKey["SUMMARIZE_LINK"] = "summarize-link";
|
|
27
28
|
RovoChatPromptKey["KEY_HIGHLIGHTS"] = "key-highlights";
|
|
28
29
|
RovoChatPromptKey["ASK_ROVO_ANYTHING"] = "ask-rovo-anything";
|
|
30
|
+
RovoChatPromptKey["IDENTIFY_KEY_POINTS"] = "identify-key-points";
|
|
31
|
+
RovoChatPromptKey["IDENTIFY_KEY_TRENDS"] = "identify-key-trends";
|
|
32
|
+
RovoChatPromptKey["FIND_OPEN_QUESTIONS"] = "find-open-questions";
|
|
33
|
+
RovoChatPromptKey["HIGHLIGHT_RELEVANT_CONTENT"] = "highlight-relevant-content";
|
|
29
34
|
return RovoChatPromptKey;
|
|
30
35
|
}({});
|
|
31
36
|
var GOOGLE_PROMPTS = [RovoChatPromptKey.RECOMMEND_OTHER_SOURCES, RovoChatPromptKey.SHOW_OTHER_MENTIONS, RovoChatPromptKey.SUGGEST_IMPROVEMENT];
|
|
@@ -174,6 +179,83 @@ var getPromptAction = function getPromptAction(promptKey, intl) {
|
|
|
174
179
|
placeholderType: 'generic'
|
|
175
180
|
}
|
|
176
181
|
};
|
|
182
|
+
case RovoChatPromptKey.HIGHLIGHT_RELEVANT_CONTENT:
|
|
183
|
+
var label_highlight_relevant_content = intl.formatMessage(messages.rovo_prompt_button_highlight_relevant_content);
|
|
184
|
+
var html_highlight_relevant_content = intl.formatMessage(messages.rovo_prompt_message_highlight_relevant_content, {
|
|
185
|
+
context: contextLong,
|
|
186
|
+
url: url
|
|
187
|
+
}, {
|
|
188
|
+
ignoreTag: true
|
|
189
|
+
});
|
|
190
|
+
return {
|
|
191
|
+
icon: /*#__PURE__*/React.createElement(AiGenerativeTextIcon, {
|
|
192
|
+
label: label_highlight_relevant_content
|
|
193
|
+
}),
|
|
194
|
+
content: label_highlight_relevant_content,
|
|
195
|
+
tooltipMessage: label_highlight_relevant_content,
|
|
196
|
+
data: {
|
|
197
|
+
name: label_highlight_relevant_content,
|
|
198
|
+
dialogues: [],
|
|
199
|
+
prompt: htmlToAdf(html_highlight_relevant_content)
|
|
200
|
+
}
|
|
201
|
+
};
|
|
202
|
+
case RovoChatPromptKey.IDENTIFY_KEY_TRENDS:
|
|
203
|
+
var label_identify_key_trends = intl.formatMessage(messages.rovo_prompt_button_identify_key_trends);
|
|
204
|
+
var html_identify_key_trends = intl.formatMessage(messages.rovo_prompt_message_identify_key_trends, {
|
|
205
|
+
url: url
|
|
206
|
+
}, {
|
|
207
|
+
ignoreTag: true
|
|
208
|
+
});
|
|
209
|
+
return {
|
|
210
|
+
icon: /*#__PURE__*/React.createElement(AiGenerativeTextIcon, {
|
|
211
|
+
label: label_identify_key_trends
|
|
212
|
+
}),
|
|
213
|
+
content: label_identify_key_trends,
|
|
214
|
+
tooltipMessage: label_identify_key_trends,
|
|
215
|
+
data: {
|
|
216
|
+
name: label_identify_key_trends,
|
|
217
|
+
dialogues: [],
|
|
218
|
+
prompt: htmlToAdf(html_identify_key_trends)
|
|
219
|
+
}
|
|
220
|
+
};
|
|
221
|
+
case RovoChatPromptKey.IDENTIFY_KEY_POINTS:
|
|
222
|
+
var label_identify_key_points = intl.formatMessage(messages.rovo_prompt_button_identify_key_points);
|
|
223
|
+
var html_identify_key_points = intl.formatMessage(messages.rovo_prompt_message_identify_key_points, {
|
|
224
|
+
url: url
|
|
225
|
+
}, {
|
|
226
|
+
ignoreTag: true
|
|
227
|
+
});
|
|
228
|
+
return {
|
|
229
|
+
icon: /*#__PURE__*/React.createElement(AiGenerativeTextIcon, {
|
|
230
|
+
label: label_identify_key_points
|
|
231
|
+
}),
|
|
232
|
+
content: label_identify_key_points,
|
|
233
|
+
tooltipMessage: label_identify_key_points,
|
|
234
|
+
data: {
|
|
235
|
+
name: label_identify_key_points,
|
|
236
|
+
dialogues: [],
|
|
237
|
+
prompt: htmlToAdf(html_identify_key_points)
|
|
238
|
+
}
|
|
239
|
+
};
|
|
240
|
+
case RovoChatPromptKey.FIND_OPEN_QUESTIONS:
|
|
241
|
+
var label_find_open_questions = intl.formatMessage(messages.rovo_prompt_button_find_open_questions);
|
|
242
|
+
var html_find_open_questions = intl.formatMessage(messages.rovo_prompt_message_find_open_questions, {
|
|
243
|
+
url: url
|
|
244
|
+
}, {
|
|
245
|
+
ignoreTag: true
|
|
246
|
+
});
|
|
247
|
+
return {
|
|
248
|
+
icon: /*#__PURE__*/React.createElement(AiGenerativeTextIcon, {
|
|
249
|
+
label: label_find_open_questions
|
|
250
|
+
}),
|
|
251
|
+
content: label_find_open_questions,
|
|
252
|
+
tooltipMessage: label_find_open_questions,
|
|
253
|
+
data: {
|
|
254
|
+
name: label_find_open_questions,
|
|
255
|
+
dialogues: [],
|
|
256
|
+
prompt: htmlToAdf(html_find_open_questions)
|
|
257
|
+
}
|
|
258
|
+
};
|
|
177
259
|
}
|
|
178
260
|
};
|
|
179
261
|
var RovoChatAction = function RovoChatAction(_ref2) {
|
|
@@ -188,7 +270,7 @@ var RovoChatAction = function RovoChatAction(_ref2) {
|
|
|
188
270
|
isRovoChatEnabled = _useRovoChat.isRovoChatEnabled,
|
|
189
271
|
sendPromptMessage = _useRovoChat.sendPromptMessage;
|
|
190
272
|
var context = useFlexibleUiContext();
|
|
191
|
-
var data = context === null || context === void 0 || (_context$actions = context.actions) === null || _context$actions === void 0 ? void 0 : _context$actions[
|
|
273
|
+
var data = context === null || context === void 0 || (_context$actions = context.actions) === null || _context$actions === void 0 ? void 0 : _context$actions[ActionName.RovoChatAction];
|
|
192
274
|
var resolvedPrompts = useMemo(function () {
|
|
193
275
|
var _data$invokeAction;
|
|
194
276
|
if (prompts) {
|
|
@@ -6,7 +6,7 @@ import { ax, ix } from "@compiled/react/runtime";
|
|
|
6
6
|
import { useCallback, useMemo, useState } from 'react';
|
|
7
7
|
import { di } from 'react-magnetic-di';
|
|
8
8
|
import { fg } from '@atlaskit/platform-feature-flags';
|
|
9
|
-
import {
|
|
9
|
+
import { ActionName, SmartLinkSize } from '../../../../../constants';
|
|
10
10
|
import { useFlexibleUiContext, useFlexibleUiOptionContext } from '../../../../../state/flexible-ui-context';
|
|
11
11
|
import * as Actions from '../../actions';
|
|
12
12
|
import { ActionFooter } from './action-footer';
|
|
@@ -53,7 +53,7 @@ var ActionBlock = function ActionBlock(_ref) {
|
|
|
53
53
|
isAny3pRovoActionsExperimentOn = _ref.isAny3pRovoActionsExperimentOn;
|
|
54
54
|
var context = useFlexibleUiContext();
|
|
55
55
|
var ui = useFlexibleUiOptionContext();
|
|
56
|
-
var isRovoChatActionAvailable = (fg('platform_sl_3p_auth_rovo_action_kill_switch') || fg('rovogrowth-640-inline-action-nudge-fg')) && isAny3pRovoActionsExperimentOn ? (context === null || context === void 0 || (_context$actions = context.actions) === null || _context$actions === void 0 ? void 0 : _context$actions[
|
|
56
|
+
var isRovoChatActionAvailable = (fg('platform_sl_3p_auth_rovo_action_kill_switch') || fg('rovogrowth-640-inline-action-nudge-fg')) && isAny3pRovoActionsExperimentOn ? (context === null || context === void 0 || (_context$actions = context.actions) === null || _context$actions === void 0 ? void 0 : _context$actions[ActionName.RovoChatAction]) !== undefined : undefined;
|
|
57
57
|
var _useState = useState(),
|
|
58
58
|
_useState2 = _slicedToArray(_useState, 2),
|
|
59
59
|
message = _useState2[0],
|
|
@@ -77,8 +77,8 @@ var ActionBlock = function ActionBlock(_ref) {
|
|
|
77
77
|
if (!(context !== null && context !== void 0 && context.actions)) {
|
|
78
78
|
return;
|
|
79
79
|
}
|
|
80
|
-
var arr = fg('platform_sl_3p_auth_rovo_action_kill_switch') || fg('rovogrowth-640-inline-action-nudge-fg') ? isRovoChatActionAvailable ? [
|
|
81
|
-
return name !==
|
|
80
|
+
var arr = fg('platform_sl_3p_auth_rovo_action_kill_switch') || fg('rovogrowth-640-inline-action-nudge-fg') ? isRovoChatActionAvailable ? [ActionName.RovoChatAction] : Object.keys(context.actions).filter(function (name) {
|
|
81
|
+
return name !== ActionName.RovoChatAction;
|
|
82
82
|
}) : Object.keys(context.actions);
|
|
83
83
|
arr.sort(sort);
|
|
84
84
|
var renderAction = function renderAction(name) {
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
/* index.tsx generated by @compiled/babel-plugin v0.39.1 */
|
|
2
2
|
import _extends from "@babel/runtime/helpers/extends";
|
|
3
3
|
import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProperties";
|
|
4
|
+
import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
|
|
4
5
|
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
5
6
|
var _excluded = ["triggerRef"];
|
|
6
7
|
import "./index.compiled.css";
|
|
@@ -15,8 +16,9 @@ import ButtonGroup from '@atlaskit/button/button-group';
|
|
|
15
16
|
import Button from '@atlaskit/button/standard-button';
|
|
16
17
|
import DropdownMenu from '@atlaskit/dropdown-menu';
|
|
17
18
|
import MoreIcon from '@atlaskit/icon/core/show-more-horizontal';
|
|
19
|
+
import { fg } from "@atlaskit/platform-feature-flags";
|
|
18
20
|
import Tooltip from '@atlaskit/tooltip';
|
|
19
|
-
import { SmartLinkSize } from '../../../../../constants';
|
|
21
|
+
import { ActionName, SmartLinkSize } from '../../../../../constants';
|
|
20
22
|
import { messages } from '../../../../../messages';
|
|
21
23
|
import { useFlexibleUiContext, useFlexibleUiOptionContext } from '../../../../../state/flexible-ui-context';
|
|
22
24
|
import { sizeToButtonSpacing } from '../../utils';
|
|
@@ -49,6 +51,7 @@ var renderActionItems = function renderActionItems() {
|
|
|
49
51
|
* @see Action
|
|
50
52
|
*/
|
|
51
53
|
var ActionGroup = function ActionGroup(_ref) {
|
|
54
|
+
var _context$actions;
|
|
52
55
|
var _ref$items = _ref.items,
|
|
53
56
|
items = _ref$items === void 0 ? [] : _ref$items,
|
|
54
57
|
_ref$size = _ref.size,
|
|
@@ -67,6 +70,7 @@ var ActionGroup = function ActionGroup(_ref) {
|
|
|
67
70
|
return filterActionItems(items, context);
|
|
68
71
|
}, [context, items]);
|
|
69
72
|
var isMoreThenTwoItems = renderableActionItems.length > visibleButtonsNum;
|
|
73
|
+
var isRovoActionsEnabled = !!(context !== null && context !== void 0 && (_context$actions = context.actions) !== null && _context$actions !== void 0 && _context$actions[ActionName.RovoChatAction]);
|
|
70
74
|
var onOpenChange = useCallback(function (attrs) {
|
|
71
75
|
setIsOpen(attrs.isOpen);
|
|
72
76
|
if (onDropdownOpenChange) {
|
|
@@ -81,11 +85,21 @@ var ActionGroup = function ActionGroup(_ref) {
|
|
|
81
85
|
}
|
|
82
86
|
}, [isOpen, onOpenChange]);
|
|
83
87
|
var actionButtons = useMemo(function () {
|
|
88
|
+
if (isRovoActionsEnabled && fg('platform_sl_3p_auth_rovo_block_card_kill_switch')) {
|
|
89
|
+
var rovoActions = [].concat(_toConsumableArray(renderableActionItems.slice(0, visibleButtonsNum - 1)), [{
|
|
90
|
+
name: ActionName.PreviewAction,
|
|
91
|
+
hideContent: true
|
|
92
|
+
}, {
|
|
93
|
+
name: ActionName.CopyLinkAction,
|
|
94
|
+
hideContent: true
|
|
95
|
+
}]);
|
|
96
|
+
return renderActionItems(rovoActions, size, appearance, false, onActionItemClick);
|
|
97
|
+
}
|
|
84
98
|
var actionItems = isMoreThenTwoItems ? renderableActionItems.slice(0, visibleButtonsNum - 1) : renderableActionItems;
|
|
85
99
|
return renderActionItems(actionItems, size, appearance, false, onActionItemClick);
|
|
86
|
-
}, [appearance, isMoreThenTwoItems, onActionItemClick, renderableActionItems, size, visibleButtonsNum]);
|
|
100
|
+
}, [appearance, isMoreThenTwoItems, onActionItemClick, renderableActionItems, size, visibleButtonsNum, isRovoActionsEnabled]);
|
|
87
101
|
var moreActionDropdown = useMemo(function () {
|
|
88
|
-
var actionItems = isMoreThenTwoItems ? renderableActionItems.slice(visibleButtonsNum - 1) : [];
|
|
102
|
+
var actionItems = isMoreThenTwoItems || isRovoActionsEnabled && fg('platform_sl_3p_auth_rovo_block_card_kill_switch') ? renderableActionItems.slice(visibleButtonsNum - 1) : [];
|
|
89
103
|
if (actionItems.length > 0) {
|
|
90
104
|
var spacing = sizeToButtonSpacing[size];
|
|
91
105
|
var moreIcon = /*#__PURE__*/React.createElement(MoreIcon, {
|
|
@@ -109,14 +123,16 @@ var ActionGroup = function ActionGroup(_ref) {
|
|
|
109
123
|
testId: "action-group-more-button",
|
|
110
124
|
iconBefore: moreIcon,
|
|
111
125
|
ref: triggerRef
|
|
112
|
-
})
|
|
126
|
+
}, fg('platform_sl_3p_auth_rovo_block_card_kill_switch') ? {
|
|
127
|
+
appearance: appearance
|
|
128
|
+
} : {})));
|
|
113
129
|
},
|
|
114
130
|
testId: "action-group-dropdown",
|
|
115
131
|
zIndex: ui === null || ui === void 0 ? void 0 : ui.zIndex
|
|
116
132
|
}, renderActionItems(actionItems, size, appearance, true, onActionItemClick));
|
|
117
133
|
}
|
|
118
134
|
return null;
|
|
119
|
-
}, [appearance, isMoreThenTwoItems, isOpen, onActionItemClick, onOpenChange, renderableActionItems, size, ui === null || ui === void 0 ? void 0 : ui.zIndex, visibleButtonsNum]);
|
|
135
|
+
}, [appearance, isMoreThenTwoItems, isOpen, onActionItemClick, onOpenChange, renderableActionItems, size, ui === null || ui === void 0 ? void 0 : ui.zIndex, visibleButtonsNum, isRovoActionsEnabled]);
|
|
120
136
|
return renderableActionItems.length > 0 ? /*#__PURE__*/React.createElement("div", {
|
|
121
137
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop -- Ignored via go/DSP-18766
|
|
122
138
|
className: ax(["_1e0c116y _dzc21h6o _1ilq1i6y", "actions-button-group"]),
|
|
@@ -5,7 +5,8 @@ import * as React from 'react';
|
|
|
5
5
|
import { ax, ix } from "@compiled/react/runtime";
|
|
6
6
|
import { useCallback, useMemo } from 'react';
|
|
7
7
|
import { browser } from '@atlaskit/linking-common/user-agent';
|
|
8
|
-
import {
|
|
8
|
+
import { fg } from "@atlaskit/platform-feature-flags";
|
|
9
|
+
import { ActionName, SmartLinkAlignment, SmartLinkDirection, SmartLinkSize, SmartLinkWidth } from '../../../../../../constants';
|
|
9
10
|
import { useFlexibleUiContext } from '../../../../../../state/flexible-ui-context';
|
|
10
11
|
import { Provider } from '../../../elements';
|
|
11
12
|
import ActionGroup from '../../action-group';
|
|
@@ -15,6 +16,7 @@ import { filterActionItems } from '../../utils';
|
|
|
15
16
|
var actionGroupStyles = null;
|
|
16
17
|
var safariStyles = null;
|
|
17
18
|
var FooterBlockResolvedView = function FooterBlockResolvedView(props) {
|
|
19
|
+
var _context$actions;
|
|
18
20
|
var actions = props.actions,
|
|
19
21
|
testId = props.testId,
|
|
20
22
|
onActionMenuOpenChange = props.onActionMenuOpenChange,
|
|
@@ -22,6 +24,7 @@ var FooterBlockResolvedView = function FooterBlockResolvedView(props) {
|
|
|
22
24
|
size = _props$size === void 0 ? SmartLinkSize.Medium : _props$size,
|
|
23
25
|
hideProvider = props.hideProvider;
|
|
24
26
|
var context = useFlexibleUiContext();
|
|
27
|
+
var isRovoSupportedFeature = !!(context !== null && context !== void 0 && (_context$actions = context.actions) !== null && _context$actions !== void 0 && _context$actions[ActionName.RovoChatAction]);
|
|
25
28
|
var hasActions = useMemo(function () {
|
|
26
29
|
var _filterActionItems;
|
|
27
30
|
return ((_filterActionItems = filterActionItems(actions, context)) === null || _filterActionItems === void 0 ? void 0 : _filterActionItems.length) > 0;
|
|
@@ -54,7 +57,7 @@ var FooterBlockResolvedView = function FooterBlockResolvedView(props) {
|
|
|
54
57
|
}, /*#__PURE__*/React.createElement(ActionGroup, {
|
|
55
58
|
onDropdownOpenChange: onDropdownOpenChange,
|
|
56
59
|
items: actions,
|
|
57
|
-
appearance:
|
|
60
|
+
appearance: isRovoSupportedFeature && fg('platform_sl_3p_auth_rovo_block_card_kill_switch') ? 'subtle' : 'default',
|
|
58
61
|
size: size
|
|
59
62
|
})) : null);
|
|
60
63
|
};
|
|
@@ -6,7 +6,7 @@ import "./index.compiled.css";
|
|
|
6
6
|
import * as React from 'react';
|
|
7
7
|
import { ax, ix } from "@compiled/react/runtime";
|
|
8
8
|
import { useMemo } from 'react';
|
|
9
|
-
import {
|
|
9
|
+
import { ActionName } from '../../../../../constants';
|
|
10
10
|
import { useFlexibleCardContext } from '../../../../../state/flexible-ui-context';
|
|
11
11
|
import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
|
|
12
12
|
import * as Actions from '../../actions';
|
|
@@ -16,7 +16,7 @@ import Block from '../block';
|
|
|
16
16
|
* Allowed footer actions for HoverCard, in display order. Fetched from context.
|
|
17
17
|
* @featureGate platform_sl_3p_auth_rovo_action_kill_switch
|
|
18
18
|
*/
|
|
19
|
-
var HIDDEN_HOVER_CARD_FOOTER_ACTIONS = [
|
|
19
|
+
var HIDDEN_HOVER_CARD_FOOTER_ACTIONS = [ActionName.RovoChatAction];
|
|
20
20
|
var ignoreContainerMarginStyles = null;
|
|
21
21
|
var elevatedFooterStyles = null;
|
|
22
22
|
var providerStyles = null;
|
|
@@ -5,6 +5,7 @@ import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
|
5
5
|
var _excluded = ["name"];
|
|
6
6
|
var _ElementDisplaySchema;
|
|
7
7
|
import React from 'react';
|
|
8
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
8
9
|
import { ActionName, ElementName, SmartLinkSize } from '../../../../constants';
|
|
9
10
|
import { isFlexibleUiElement } from '../../../../utils/flexible';
|
|
10
11
|
import * as Elements from '../elements';
|
|
@@ -56,6 +57,16 @@ export var filterActionItems = function filterActionItems() {
|
|
|
56
57
|
case ActionName.CustomAction:
|
|
57
58
|
// Named and custom actions that user defines.
|
|
58
59
|
return Boolean(ActionName[item.name]);
|
|
60
|
+
case ActionName.RovoChatAction:
|
|
61
|
+
if (fg('platform_sl_3p_auth_rovo_block_card_kill_switch')) {
|
|
62
|
+
return Boolean(ActionName[item.name]);
|
|
63
|
+
}
|
|
64
|
+
// same as default case below
|
|
65
|
+
// remove on cleanup of platform_sl_3p_auth_rovo_block_card_kill_switch
|
|
66
|
+
if ((context === null || context === void 0 ? void 0 : context.actions) === undefined) {
|
|
67
|
+
return false;
|
|
68
|
+
}
|
|
69
|
+
return Boolean(item.name in context.actions ? context.actions[item.name] : undefined);
|
|
59
70
|
default:
|
|
60
71
|
// Action that require data from the data context to render.
|
|
61
72
|
if ((context === null || context === void 0 ? void 0 : context.actions) === undefined) {
|
|
@@ -15,7 +15,7 @@ import LinkWarningModal from './LinkWarningModal';
|
|
|
15
15
|
import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
|
|
16
16
|
var PACKAGE_DATA = {
|
|
17
17
|
packageName: "@atlaskit/smart-card",
|
|
18
|
-
packageVersion: "44.
|
|
18
|
+
packageVersion: "44.2.0",
|
|
19
19
|
componentName: 'linkUrl'
|
|
20
20
|
};
|
|
21
21
|
var Anchor = withLinkClickedEvent('a');
|
|
@@ -138,11 +138,11 @@ export declare enum ActionName {
|
|
|
138
138
|
PreviewAction = "PreviewAction",
|
|
139
139
|
AutomationAction = "AutomationAction",
|
|
140
140
|
DownloadAction = "DownloadAction",
|
|
141
|
-
CustomAction = "CustomAction"
|
|
141
|
+
CustomAction = "CustomAction",
|
|
142
|
+
RovoChatAction = "RovoChatAction"
|
|
142
143
|
}
|
|
143
144
|
export declare enum InternalActionName {
|
|
144
145
|
AISummaryAction = "AISummaryAction",
|
|
145
|
-
RovoChatAction = "RovoChatAction",
|
|
146
146
|
UnresolvedAction = "UnresolvedAction",
|
|
147
147
|
ViewRelatedLinksAction = "ViewRelatedLinksAction"
|
|
148
148
|
}
|
package/dist/types/messages.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type MessageDescriptor } from 'react-intl';
|
|
2
2
|
export type RequestAccessMessageKey = 'click_to_join' | 'click_to_join_description' | 'forbidden_description' | 'request_access' | 'request_access_description' | 'request_access_pending' | 'request_access_pending_title' | 'request_access_pending_description' | 'request_denied_description' | 'default_no_access_title' | 'direct_access_title' | 'direct_access_description' | 'direct_access' | 'access_exists_description' | 'not_found_description' | 'not_found_title';
|
|
3
|
-
export type RovoChatActionMessageKey = 'rovo_prompt_context_generic' | 'rovo_prompt_context_generic_plural' | 'rovo_prompt_context_confluence_page' | 'rovo_prompt_context_confluence_page_short' | 'rovo_prompt_context_jira_work_item' | 'rovo_prompt_context_jira_work_item_short' | 'rovo_prompt_button_recommend_other_sources' | 'rovo_prompt_message_recommend_other_sources' | 'rovo_prompt_button_show_other_mentions' | 'rovo_prompt_message_show_other_mentions' | 'rovo_prompt_button_suggest_improvement' | 'rovo_prompt_message_suggest_improvement' | 'rovo_prompt_message_summarize' | 'rovo_prompt_button_key_highlights' | 'rovo_prompt_message_key_highlights' | 'rovo_prompt_button_ask_rovo_anything' | 'rovo_prompt_message_ask_rovo_anything';
|
|
3
|
+
export type RovoChatActionMessageKey = 'rovo_prompt_context_generic' | 'rovo_prompt_context_generic_plural' | 'rovo_prompt_context_confluence_page' | 'rovo_prompt_context_confluence_page_short' | 'rovo_prompt_context_jira_work_item' | 'rovo_prompt_context_jira_work_item_short' | 'rovo_prompt_button_recommend_other_sources' | 'rovo_prompt_message_recommend_other_sources' | 'rovo_prompt_button_show_other_mentions' | 'rovo_prompt_message_show_other_mentions' | 'rovo_prompt_button_suggest_improvement' | 'rovo_prompt_message_suggest_improvement' | 'rovo_prompt_message_summarize' | 'rovo_prompt_button_key_highlights' | 'rovo_prompt_message_key_highlights' | 'rovo_prompt_button_ask_rovo_anything' | 'rovo_prompt_message_ask_rovo_anything' | 'rovo_prompt_button_highlight_relevant_content' | 'rovo_prompt_message_highlight_relevant_content' | 'rovo_prompt_button_identify_key_trends' | 'rovo_prompt_message_identify_key_trends' | 'rovo_prompt_button_identify_key_points' | 'rovo_prompt_message_identify_key_points' | 'rovo_prompt_button_find_open_questions' | 'rovo_prompt_message_find_open_questions';
|
|
4
4
|
export type MessageKey = 'assigned_to' | 'ai_summarize' | 'change_status' | 'ai_summarized' | 'ai_summarized_abbreviation' | 'ai_summarized_info' | 'ai_summarized_info_short' | 'ai_summarizing' | 'ai_summary_error_generic' | 'ai_summary_error_acceptable_use_violation' | 'ai_summary_error_hipaa_content_detected' | 'ai_summary_error_exceeding_context_length_error' | 'ai_summary_action' | 'ai_summary_action_description' | 'automation_action_title' | 'automation_action_tooltip' | 'automation_action_icon_label' | 'automation_action_confluence_page_modal_title' | 'automation_action_confluence_page_modal_description' | 'copy_summary_action' | 'copy_summary_action_description' | 'copied_summary_action_description' | 'beta' | 'cannot_find_link' | 'compass_applied_components_count' | 'connect_link_account_card' | 'connect_link_account_card_name' | 'connect_link_account_card_description' | 'connect_unauthorised_account_action' | 'connect_unauthorised_account_description' | 'connect_unauthorised_account_description_no_provider' | 'continue' | 'copy_url_to_clipboard' | 'copied_url_to_clipboard' | 'could_not_load_link' | 'download' | 'download_description' | 'download_file' | 'follow' | 'follow_project_description' | 'follow_project_descriptionGalaxia' | 'follow_project' | 'follow_goal' | 'follow_goal_description' | 'follow_project_error' | 'follow_project_errorGalaxia' | 'follow_goal_error' | 'go_back' | 'invalid_permissions' | 'invalid_permissions_description' | 'join_to_view' | 'connect_link_account' | 'created_by' | 'created_on_relative' | 'created_on_absolute' | 'check_this_link' | 'delete' | 'edit' | 'learn_more_about_smart_links' | 'learn_more_about_connecting_account' | 'loading' | 'link_safety_warning_message' | 'modified_by' | 'modified_on_relative' | 'modified_on_absolute' | 'more_actions' | 'not_found_title' | 'not_found_description' | 'open_issue_in_jira' | 'open_link_in_a_new_tab' | 'owned_by' | 'owned_by_override' | 'preview_description' | 'preview_improved' | 'preview_modal' | 'preview_panel' | 'preview_close' | 'preview_max_size' | 'preview_min_size' | 'priority_blocker' | 'priority_critical' | 'priority_high' | 'priority_highest' | 'priority_low' | 'priority_lowest' | 'priority_major' | 'priority_medium' | 'priority_minor' | 'priority_trivial' | 'priority_undefined' | 'forbidden_access' | 'pending_request' | 'read_time' | 'restricted_link' | 'request_access_to_view' | 'request_denied' | 'sent_on_relative' | 'sent_on_absolute' | 'status_change_load_error' | 'status_change_permission_error' | 'status_change_update_error' | 'try_again' | 'try_another_account' | 'unauthorised_account_description' | 'unauthorised_account_description_no_provider' | 'unauthorised_account_name' | 'unauthorised_account_name_no_provider' | 'rovo_actions_explore' | 'unassigned' | 'unfollow' | 'unfollow_project_description' | 'unfollow_project_descriptionGalaxia' | 'unfollow_project' | 'unfollow_project_error' | 'unfollow_project_errorGalaxia' | 'unfollow_goal' | 'unfollow_goal_description' | 'unfollow_goal_error' | 'user_attributes' | 'view' | 'viewIn' | 'viewOriginal' | 'actions' | 'add_account' | 'cancel' | 'close' | 'connect_to' | 'connect_account_description' | 'retry' | 'save' | 'unlink_account' | RequestAccessMessageKey | 'related' | 'generic_error_message' | 'related_links_modal_error_title' | 'related_links_modal_error_description' | 'related_links_modal_unavailable_title' | 'related_links_modal_unavailable_description' | 'related_links_modal_title' | 'related_links_view_related_urls' | 'related_links_view_related_links' | 'related_links_found_in' | 'related_links_includes_links_to' | 'related_links_not_found' | 'join_to_viewIssueTermRefresh' | 'open_issue_in_jiraIssueTermRefresh' | 'request_access_to_viewIssueTermRefresh' | 'team_members_count' | 'status_change_permission_errorIssueTermRefresh' | 'connect_unauthorised_account_description_appify' | 'connect_unauthorised_account_description_no_provider_appify' | 'learn_more_about_connecting_account_experiment_shorter' | 'learn_more_about_connecting_account_appify' | 'rovo_summary_loading' | 'ai_disclaimer' | 'rovo_unauthorised_title' | 'rovo_unauthorised_title_no_provider' | 'rovo_unauthorised_feature_clear_link_names' | 'rovo_unauthorised_feature_understand_linked_docs' | 'rovo_unauthorised_feature_go_deeper_smart_suggestions' | 'rovo_unauthorised_connect_account' | 'rovo_unauthorised_not_now' | RovoChatActionMessageKey;
|
|
5
5
|
type Messages = {
|
|
6
6
|
[K in MessageKey]: MessageDescriptor;
|
|
@@ -293,8 +293,8 @@ export type FlexibleUiActions = {
|
|
|
293
293
|
[ActionName.DownloadAction]?: DownloadActionData;
|
|
294
294
|
[ActionName.FollowAction]?: ServerActionProp<boolean>;
|
|
295
295
|
[ActionName.PreviewAction]?: PreviewActionData;
|
|
296
|
+
[ActionName.RovoChatAction]?: RovoChatActionData;
|
|
296
297
|
[InternalActionName.AISummaryAction]?: AISummaryActionData;
|
|
297
|
-
[InternalActionName.RovoChatAction]?: RovoChatActionData;
|
|
298
298
|
[InternalActionName.UnresolvedAction]?: UnresolvedActionData;
|
|
299
299
|
[InternalActionName.ViewRelatedLinksAction]?: ViewRelatedLinksActionData;
|
|
300
300
|
};
|
|
@@ -6,7 +6,11 @@ export declare enum RovoChatPromptKey {
|
|
|
6
6
|
SUGGEST_IMPROVEMENT = "suggest-improvement",
|
|
7
7
|
SUMMARIZE_LINK = "summarize-link",
|
|
8
8
|
KEY_HIGHLIGHTS = "key-highlights",
|
|
9
|
-
ASK_ROVO_ANYTHING = "ask-rovo-anything"
|
|
9
|
+
ASK_ROVO_ANYTHING = "ask-rovo-anything",
|
|
10
|
+
IDENTIFY_KEY_POINTS = "identify-key-points",
|
|
11
|
+
IDENTIFY_KEY_TRENDS = "identify-key-trends",
|
|
12
|
+
FIND_OPEN_QUESTIONS = "find-open-questions",
|
|
13
|
+
HIGHLIGHT_RELEVANT_CONTENT = "highlight-relevant-content"
|
|
10
14
|
}
|
|
11
15
|
type RovoChatActionProps = LinkActionProps & {
|
|
12
16
|
prompts?: RovoChatPromptKey[];
|
|
@@ -166,7 +166,7 @@ export type BaseDataActionItem = {
|
|
|
166
166
|
* renders a preview modal when clicked.
|
|
167
167
|
*/
|
|
168
168
|
export type NamedDataActionItem = BaseDataActionItem & {
|
|
169
|
-
name: ActionName.FollowAction | ActionName.PreviewAction | ActionName.DownloadAction | ActionName.AutomationAction | ActionName.CopyLinkAction;
|
|
169
|
+
name: ActionName.FollowAction | ActionName.PreviewAction | ActionName.DownloadAction | ActionName.AutomationAction | ActionName.CopyLinkAction | ActionName.RovoChatAction;
|
|
170
170
|
};
|
|
171
171
|
/**
|
|
172
172
|
* This represents an action that does not fetch data where Icon and Content are provided implicitly.
|
|
@@ -138,11 +138,11 @@ export declare enum ActionName {
|
|
|
138
138
|
PreviewAction = "PreviewAction",
|
|
139
139
|
AutomationAction = "AutomationAction",
|
|
140
140
|
DownloadAction = "DownloadAction",
|
|
141
|
-
CustomAction = "CustomAction"
|
|
141
|
+
CustomAction = "CustomAction",
|
|
142
|
+
RovoChatAction = "RovoChatAction"
|
|
142
143
|
}
|
|
143
144
|
export declare enum InternalActionName {
|
|
144
145
|
AISummaryAction = "AISummaryAction",
|
|
145
|
-
RovoChatAction = "RovoChatAction",
|
|
146
146
|
UnresolvedAction = "UnresolvedAction",
|
|
147
147
|
ViewRelatedLinksAction = "ViewRelatedLinksAction"
|
|
148
148
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type MessageDescriptor } from 'react-intl';
|
|
2
2
|
export type RequestAccessMessageKey = 'click_to_join' | 'click_to_join_description' | 'forbidden_description' | 'request_access' | 'request_access_description' | 'request_access_pending' | 'request_access_pending_title' | 'request_access_pending_description' | 'request_denied_description' | 'default_no_access_title' | 'direct_access_title' | 'direct_access_description' | 'direct_access' | 'access_exists_description' | 'not_found_description' | 'not_found_title';
|
|
3
|
-
export type RovoChatActionMessageKey = 'rovo_prompt_context_generic' | 'rovo_prompt_context_generic_plural' | 'rovo_prompt_context_confluence_page' | 'rovo_prompt_context_confluence_page_short' | 'rovo_prompt_context_jira_work_item' | 'rovo_prompt_context_jira_work_item_short' | 'rovo_prompt_button_recommend_other_sources' | 'rovo_prompt_message_recommend_other_sources' | 'rovo_prompt_button_show_other_mentions' | 'rovo_prompt_message_show_other_mentions' | 'rovo_prompt_button_suggest_improvement' | 'rovo_prompt_message_suggest_improvement' | 'rovo_prompt_message_summarize' | 'rovo_prompt_button_key_highlights' | 'rovo_prompt_message_key_highlights' | 'rovo_prompt_button_ask_rovo_anything' | 'rovo_prompt_message_ask_rovo_anything';
|
|
3
|
+
export type RovoChatActionMessageKey = 'rovo_prompt_context_generic' | 'rovo_prompt_context_generic_plural' | 'rovo_prompt_context_confluence_page' | 'rovo_prompt_context_confluence_page_short' | 'rovo_prompt_context_jira_work_item' | 'rovo_prompt_context_jira_work_item_short' | 'rovo_prompt_button_recommend_other_sources' | 'rovo_prompt_message_recommend_other_sources' | 'rovo_prompt_button_show_other_mentions' | 'rovo_prompt_message_show_other_mentions' | 'rovo_prompt_button_suggest_improvement' | 'rovo_prompt_message_suggest_improvement' | 'rovo_prompt_message_summarize' | 'rovo_prompt_button_key_highlights' | 'rovo_prompt_message_key_highlights' | 'rovo_prompt_button_ask_rovo_anything' | 'rovo_prompt_message_ask_rovo_anything' | 'rovo_prompt_button_highlight_relevant_content' | 'rovo_prompt_message_highlight_relevant_content' | 'rovo_prompt_button_identify_key_trends' | 'rovo_prompt_message_identify_key_trends' | 'rovo_prompt_button_identify_key_points' | 'rovo_prompt_message_identify_key_points' | 'rovo_prompt_button_find_open_questions' | 'rovo_prompt_message_find_open_questions';
|
|
4
4
|
export type MessageKey = 'assigned_to' | 'ai_summarize' | 'change_status' | 'ai_summarized' | 'ai_summarized_abbreviation' | 'ai_summarized_info' | 'ai_summarized_info_short' | 'ai_summarizing' | 'ai_summary_error_generic' | 'ai_summary_error_acceptable_use_violation' | 'ai_summary_error_hipaa_content_detected' | 'ai_summary_error_exceeding_context_length_error' | 'ai_summary_action' | 'ai_summary_action_description' | 'automation_action_title' | 'automation_action_tooltip' | 'automation_action_icon_label' | 'automation_action_confluence_page_modal_title' | 'automation_action_confluence_page_modal_description' | 'copy_summary_action' | 'copy_summary_action_description' | 'copied_summary_action_description' | 'beta' | 'cannot_find_link' | 'compass_applied_components_count' | 'connect_link_account_card' | 'connect_link_account_card_name' | 'connect_link_account_card_description' | 'connect_unauthorised_account_action' | 'connect_unauthorised_account_description' | 'connect_unauthorised_account_description_no_provider' | 'continue' | 'copy_url_to_clipboard' | 'copied_url_to_clipboard' | 'could_not_load_link' | 'download' | 'download_description' | 'download_file' | 'follow' | 'follow_project_description' | 'follow_project_descriptionGalaxia' | 'follow_project' | 'follow_goal' | 'follow_goal_description' | 'follow_project_error' | 'follow_project_errorGalaxia' | 'follow_goal_error' | 'go_back' | 'invalid_permissions' | 'invalid_permissions_description' | 'join_to_view' | 'connect_link_account' | 'created_by' | 'created_on_relative' | 'created_on_absolute' | 'check_this_link' | 'delete' | 'edit' | 'learn_more_about_smart_links' | 'learn_more_about_connecting_account' | 'loading' | 'link_safety_warning_message' | 'modified_by' | 'modified_on_relative' | 'modified_on_absolute' | 'more_actions' | 'not_found_title' | 'not_found_description' | 'open_issue_in_jira' | 'open_link_in_a_new_tab' | 'owned_by' | 'owned_by_override' | 'preview_description' | 'preview_improved' | 'preview_modal' | 'preview_panel' | 'preview_close' | 'preview_max_size' | 'preview_min_size' | 'priority_blocker' | 'priority_critical' | 'priority_high' | 'priority_highest' | 'priority_low' | 'priority_lowest' | 'priority_major' | 'priority_medium' | 'priority_minor' | 'priority_trivial' | 'priority_undefined' | 'forbidden_access' | 'pending_request' | 'read_time' | 'restricted_link' | 'request_access_to_view' | 'request_denied' | 'sent_on_relative' | 'sent_on_absolute' | 'status_change_load_error' | 'status_change_permission_error' | 'status_change_update_error' | 'try_again' | 'try_another_account' | 'unauthorised_account_description' | 'unauthorised_account_description_no_provider' | 'unauthorised_account_name' | 'unauthorised_account_name_no_provider' | 'rovo_actions_explore' | 'unassigned' | 'unfollow' | 'unfollow_project_description' | 'unfollow_project_descriptionGalaxia' | 'unfollow_project' | 'unfollow_project_error' | 'unfollow_project_errorGalaxia' | 'unfollow_goal' | 'unfollow_goal_description' | 'unfollow_goal_error' | 'user_attributes' | 'view' | 'viewIn' | 'viewOriginal' | 'actions' | 'add_account' | 'cancel' | 'close' | 'connect_to' | 'connect_account_description' | 'retry' | 'save' | 'unlink_account' | RequestAccessMessageKey | 'related' | 'generic_error_message' | 'related_links_modal_error_title' | 'related_links_modal_error_description' | 'related_links_modal_unavailable_title' | 'related_links_modal_unavailable_description' | 'related_links_modal_title' | 'related_links_view_related_urls' | 'related_links_view_related_links' | 'related_links_found_in' | 'related_links_includes_links_to' | 'related_links_not_found' | 'join_to_viewIssueTermRefresh' | 'open_issue_in_jiraIssueTermRefresh' | 'request_access_to_viewIssueTermRefresh' | 'team_members_count' | 'status_change_permission_errorIssueTermRefresh' | 'connect_unauthorised_account_description_appify' | 'connect_unauthorised_account_description_no_provider_appify' | 'learn_more_about_connecting_account_experiment_shorter' | 'learn_more_about_connecting_account_appify' | 'rovo_summary_loading' | 'ai_disclaimer' | 'rovo_unauthorised_title' | 'rovo_unauthorised_title_no_provider' | 'rovo_unauthorised_feature_clear_link_names' | 'rovo_unauthorised_feature_understand_linked_docs' | 'rovo_unauthorised_feature_go_deeper_smart_suggestions' | 'rovo_unauthorised_connect_account' | 'rovo_unauthorised_not_now' | RovoChatActionMessageKey;
|
|
5
5
|
type Messages = {
|
|
6
6
|
[K in MessageKey]: MessageDescriptor;
|
|
@@ -293,8 +293,8 @@ export type FlexibleUiActions = {
|
|
|
293
293
|
[ActionName.DownloadAction]?: DownloadActionData;
|
|
294
294
|
[ActionName.FollowAction]?: ServerActionProp<boolean>;
|
|
295
295
|
[ActionName.PreviewAction]?: PreviewActionData;
|
|
296
|
+
[ActionName.RovoChatAction]?: RovoChatActionData;
|
|
296
297
|
[InternalActionName.AISummaryAction]?: AISummaryActionData;
|
|
297
|
-
[InternalActionName.RovoChatAction]?: RovoChatActionData;
|
|
298
298
|
[InternalActionName.UnresolvedAction]?: UnresolvedActionData;
|
|
299
299
|
[InternalActionName.ViewRelatedLinksAction]?: ViewRelatedLinksActionData;
|
|
300
300
|
};
|
|
@@ -6,7 +6,11 @@ export declare enum RovoChatPromptKey {
|
|
|
6
6
|
SUGGEST_IMPROVEMENT = "suggest-improvement",
|
|
7
7
|
SUMMARIZE_LINK = "summarize-link",
|
|
8
8
|
KEY_HIGHLIGHTS = "key-highlights",
|
|
9
|
-
ASK_ROVO_ANYTHING = "ask-rovo-anything"
|
|
9
|
+
ASK_ROVO_ANYTHING = "ask-rovo-anything",
|
|
10
|
+
IDENTIFY_KEY_POINTS = "identify-key-points",
|
|
11
|
+
IDENTIFY_KEY_TRENDS = "identify-key-trends",
|
|
12
|
+
FIND_OPEN_QUESTIONS = "find-open-questions",
|
|
13
|
+
HIGHLIGHT_RELEVANT_CONTENT = "highlight-relevant-content"
|
|
10
14
|
}
|
|
11
15
|
type RovoChatActionProps = LinkActionProps & {
|
|
12
16
|
prompts?: RovoChatPromptKey[];
|
|
@@ -166,7 +166,7 @@ export type BaseDataActionItem = {
|
|
|
166
166
|
* renders a preview modal when clicked.
|
|
167
167
|
*/
|
|
168
168
|
export type NamedDataActionItem = BaseDataActionItem & {
|
|
169
|
-
name: ActionName.FollowAction | ActionName.PreviewAction | ActionName.DownloadAction | ActionName.AutomationAction | ActionName.CopyLinkAction;
|
|
169
|
+
name: ActionName.FollowAction | ActionName.PreviewAction | ActionName.DownloadAction | ActionName.AutomationAction | ActionName.CopyLinkAction | ActionName.RovoChatAction;
|
|
170
170
|
};
|
|
171
171
|
/**
|
|
172
172
|
* This represents an action that does not fetch data where Icon and Content are provided implicitly.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/smart-card",
|
|
3
|
-
"version": "44.
|
|
3
|
+
"version": "44.3.0",
|
|
4
4
|
"description": "Smart card component",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -39,7 +39,7 @@
|
|
|
39
39
|
"@atlaskit/afm-i18n-platform-linking-platform-smart-card": "2.6.0",
|
|
40
40
|
"@atlaskit/analytics-gas-types": "^5.1.0",
|
|
41
41
|
"@atlaskit/analytics-next": "^11.2.0",
|
|
42
|
-
"@atlaskit/avatar": "^25.
|
|
42
|
+
"@atlaskit/avatar": "^25.12.0",
|
|
43
43
|
"@atlaskit/avatar-group": "^12.7.0",
|
|
44
44
|
"@atlaskit/badge": "^18.6.0",
|
|
45
45
|
"@atlaskit/browser-apis": "^0.0.1",
|
|
@@ -62,29 +62,29 @@
|
|
|
62
62
|
"@atlaskit/link-analytics": "^11.0.0",
|
|
63
63
|
"@atlaskit/link-client-extension": "^6.0.0",
|
|
64
64
|
"@atlaskit/link-extractors": "^2.4.0",
|
|
65
|
-
"@atlaskit/link-test-helpers": "^10.
|
|
65
|
+
"@atlaskit/link-test-helpers": "^10.1.0",
|
|
66
66
|
"@atlaskit/linking-common": "^9.11.0",
|
|
67
67
|
"@atlaskit/linking-types": "^14.2.0",
|
|
68
68
|
"@atlaskit/logo": "^20.0.0",
|
|
69
69
|
"@atlaskit/lozenge": "^13.7.0",
|
|
70
70
|
"@atlaskit/menu": "^8.5.0",
|
|
71
|
-
"@atlaskit/modal-dialog": "^14.
|
|
71
|
+
"@atlaskit/modal-dialog": "^14.16.0",
|
|
72
72
|
"@atlaskit/outbound-auth-flow-client": "^3.4.0",
|
|
73
73
|
"@atlaskit/platform-feature-flags": "^1.1.0",
|
|
74
74
|
"@atlaskit/platform-feature-flags-react": "^0.4.0",
|
|
75
75
|
"@atlaskit/popup": "^4.16.0",
|
|
76
76
|
"@atlaskit/primitives": "^19.0.0",
|
|
77
|
-
"@atlaskit/react-ufo": "^5.
|
|
78
|
-
"@atlaskit/rovo-triggers": "^5.
|
|
77
|
+
"@atlaskit/react-ufo": "^5.16.0",
|
|
78
|
+
"@atlaskit/rovo-triggers": "^5.42.0",
|
|
79
79
|
"@atlaskit/section-message": "^8.12.0",
|
|
80
80
|
"@atlaskit/select": "^21.10.0",
|
|
81
81
|
"@atlaskit/spinner": "^19.1.0",
|
|
82
|
-
"@atlaskit/tag": "^14.
|
|
82
|
+
"@atlaskit/tag": "^14.12.0",
|
|
83
83
|
"@atlaskit/textarea": "^8.3.0",
|
|
84
84
|
"@atlaskit/textfield": "^8.3.0",
|
|
85
85
|
"@atlaskit/theme": "^23.1.0",
|
|
86
86
|
"@atlaskit/tile": "^1.0.0",
|
|
87
|
-
"@atlaskit/tmp-editor-statsig": "^
|
|
87
|
+
"@atlaskit/tmp-editor-statsig": "^64.0.0",
|
|
88
88
|
"@atlaskit/tokens": "^13.0.0",
|
|
89
89
|
"@atlaskit/tooltip": "^21.1.0",
|
|
90
90
|
"@atlaskit/ufo": "^0.4.0",
|
|
@@ -187,9 +187,6 @@
|
|
|
187
187
|
"confluence-issue-terminology-refresh": {
|
|
188
188
|
"type": "boolean"
|
|
189
189
|
},
|
|
190
|
-
"dst-a11y__replace-anchor-with-link__linking-platfo": {
|
|
191
|
-
"type": "boolean"
|
|
192
|
-
},
|
|
193
190
|
"platform_editor_content_mode_button_mvp": {
|
|
194
191
|
"type": "boolean"
|
|
195
192
|
},
|
|
@@ -249,6 +246,9 @@
|
|
|
249
246
|
},
|
|
250
247
|
"rovogrowth-640-inline-action-nudge-fg": {
|
|
251
248
|
"type": "boolean"
|
|
249
|
+
},
|
|
250
|
+
"platform_sl_3p_auth_rovo_block_card_kill_switch": {
|
|
251
|
+
"type": "boolean"
|
|
252
252
|
}
|
|
253
253
|
},
|
|
254
254
|
"compassUnitTestMetricSourceId": "ari:cloud:compass:a436116f-02ce-4520-8fbb-7301462a1674:metric-source/c5751cc6-3513-4070-9deb-af31e86aed34/f74ef1bc-7240-4aac-9dc8-9dc43b502089"
|