@atlaskit/smart-card 40.8.2 → 40.8.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/dist/cjs/messages.js +30 -0
- package/dist/cjs/state/helpers.js +10 -1
- package/dist/cjs/utils/analytics/analytics.js +1 -1
- package/dist/cjs/view/CardWithUrl/component.js +4 -3
- package/dist/cjs/view/FlexibleCard/components/actions/follow-action/index.js +3 -2
- package/dist/cjs/view/FlexibleCard/components/actions/follow-action/utils.js +4 -2
- package/dist/cjs/view/LinkUrl/index.js +1 -1
- package/dist/es2019/messages.js +30 -0
- package/dist/es2019/state/helpers.js +9 -0
- package/dist/es2019/utils/analytics/analytics.js +1 -1
- package/dist/es2019/view/CardWithUrl/component.js +5 -4
- package/dist/es2019/view/FlexibleCard/components/actions/follow-action/index.js +3 -2
- package/dist/es2019/view/FlexibleCard/components/actions/follow-action/utils.js +3 -2
- package/dist/es2019/view/LinkUrl/index.js +1 -1
- package/dist/esm/messages.js +30 -0
- package/dist/esm/state/helpers.js +9 -0
- package/dist/esm/utils/analytics/analytics.js +1 -1
- package/dist/esm/view/CardWithUrl/component.js +5 -4
- package/dist/esm/view/FlexibleCard/components/actions/follow-action/index.js +3 -2
- package/dist/esm/view/FlexibleCard/components/actions/follow-action/utils.js +3 -2
- package/dist/esm/view/LinkUrl/index.js +1 -1
- package/dist/types/messages.d.ts +1 -1
- package/dist/types/state/helpers.d.ts +2 -0
- package/dist/types-ts4.5/messages.d.ts +1 -1
- package/dist/types-ts4.5/state/helpers.d.ts +2 -0
- package/package.json +2 -1
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,13 @@
|
|
|
1
1
|
# @atlaskit/smart-card
|
|
2
2
|
|
|
3
|
+
## 40.8.3
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [`e8b2481cab6c0`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/e8b2481cab6c0) -
|
|
8
|
+
Add third party ARI to analytics emission
|
|
9
|
+
- Updated dependencies
|
|
10
|
+
|
|
3
11
|
## 40.8.2
|
|
4
12
|
|
|
5
13
|
### Patch Changes
|
package/dist/cjs/messages.js
CHANGED
|
@@ -784,5 +784,35 @@ var messages = exports.messages = (0, _reactIntlNext.defineMessages)({
|
|
|
784
784
|
id: 'fabric.linking.user_attributes',
|
|
785
785
|
defaultMessage: '{context}',
|
|
786
786
|
description: 'Displays user attributes like role, department, location, and pronouns'
|
|
787
|
+
},
|
|
788
|
+
follow_project_descriptionGalaxia: {
|
|
789
|
+
id: 'fabric.linking.follow_project_description-galaxia',
|
|
790
|
+
defaultMessage: 'Follow to get notifications on this space',
|
|
791
|
+
description: 'Description on what Follow does'
|
|
792
|
+
},
|
|
793
|
+
follow_projectGalaxia: {
|
|
794
|
+
id: 'fabric.linking.follow_project-galaxia',
|
|
795
|
+
defaultMessage: 'Follow space',
|
|
796
|
+
description: 'Click to follow a project.'
|
|
797
|
+
},
|
|
798
|
+
follow_project_errorGalaxia: {
|
|
799
|
+
id: 'fabric.linking.follow_project_error-galaxia',
|
|
800
|
+
defaultMessage: 'We encountered an error while trying to follow the space. Check your connection or refresh the page and try again.',
|
|
801
|
+
description: 'Shown when an unknown error occurs when following an Atlas project'
|
|
802
|
+
},
|
|
803
|
+
unfollow_project_descriptionGalaxia: {
|
|
804
|
+
id: 'fabric.linking.unfollow_project_description-galaxia',
|
|
805
|
+
defaultMessage: 'Unfollow to stop receiving space notifications',
|
|
806
|
+
description: 'Description on what Unfollow does'
|
|
807
|
+
},
|
|
808
|
+
unfollow_projectGalaxia: {
|
|
809
|
+
id: 'fabric.linking.unfollow_project-galaxia',
|
|
810
|
+
defaultMessage: 'Unfollow space',
|
|
811
|
+
description: 'Click to unfollow a project.'
|
|
812
|
+
},
|
|
813
|
+
unfollow_project_errorGalaxia: {
|
|
814
|
+
id: 'fabric.linking.unfollow_project_error-galaxia',
|
|
815
|
+
defaultMessage: 'We encountered an error while trying to unfollow the space. Check your connection or refresh the page and try again.',
|
|
816
|
+
description: 'Shown when an unknown error occurs when unfollowing an Atlas project'
|
|
787
817
|
}
|
|
788
818
|
});
|
|
@@ -4,8 +4,9 @@ var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefau
|
|
|
4
4
|
Object.defineProperty(exports, "__esModule", {
|
|
5
5
|
value: true
|
|
6
6
|
});
|
|
7
|
-
exports.isVisible = exports.isFinalState = exports.isAccessible = exports.hasResolved = exports.hasAuthScopeOverrides = exports.getSubproduct = exports.getStatusDetails = exports.getServices = exports.getResourceType = exports.getProduct = exports.getObjectName = exports.getObjectIconUrl = exports.getObjectAri = exports.getExtensionKey = exports.getDefinitionId = exports.getDatasources = exports.getClickUrl = exports.getCanBeDatasource = exports.getByDefinitionId = void 0;
|
|
7
|
+
exports.isVisible = exports.isFinalState = exports.isAccessible = exports.hasResolved = exports.hasAuthScopeOverrides = exports.getThirdPartyARI = exports.getSubproduct = exports.getStatusDetails = exports.getServices = exports.getResourceType = exports.getProduct = exports.getObjectName = exports.getObjectIconUrl = exports.getObjectAri = exports.getExtensionKey = exports.getDefinitionId = exports.getDatasources = exports.getClickUrl = exports.getCanBeDatasource = exports.getByDefinitionId = void 0;
|
|
8
8
|
var _typeof2 = _interopRequireDefault(require("@babel/runtime/helpers/typeof"));
|
|
9
|
+
var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
|
|
9
10
|
var _extractVisitUrl = require("../extractors/common/primitives/extractVisitUrl");
|
|
10
11
|
var getByDefinitionId = exports.getByDefinitionId = function getByDefinitionId(definitionId, store) {
|
|
11
12
|
var urls = Object.keys(store);
|
|
@@ -34,6 +35,14 @@ var getExtensionKey = exports.getExtensionKey = function getExtensionKey(details
|
|
|
34
35
|
var getObjectAri = exports.getObjectAri = function getObjectAri(details) {
|
|
35
36
|
return (details === null || details === void 0 ? void 0 : details.data) && 'atlassian:ari' in details.data && details.data['atlassian:ari'] || undefined;
|
|
36
37
|
};
|
|
38
|
+
var getThirdPartyARI = exports.getThirdPartyARI = function getThirdPartyARI(details) {
|
|
39
|
+
if ((0, _platformFeatureFlags.fg)('platform_smartlink_3pclick_analytics')) {
|
|
40
|
+
if (details !== null && details !== void 0 && details.entityData && 'thirdPartyAri' in details.entityData && details.entityData.thirdPartyAri) {
|
|
41
|
+
return details.entityData.thirdPartyAri;
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
return undefined;
|
|
45
|
+
};
|
|
37
46
|
var getObjectName = exports.getObjectName = function getObjectName(details) {
|
|
38
47
|
return (details === null || details === void 0 ? void 0 : details.data) && 'name' in details.data && details.data.name || undefined;
|
|
39
48
|
};
|
|
@@ -11,7 +11,7 @@ var ANALYTICS_CHANNEL = exports.ANALYTICS_CHANNEL = 'media';
|
|
|
11
11
|
var context = exports.context = {
|
|
12
12
|
componentName: 'smart-cards',
|
|
13
13
|
packageName: "@atlaskit/smart-card",
|
|
14
|
-
packageVersion: "40.8.
|
|
14
|
+
packageVersion: "40.8.2"
|
|
15
15
|
};
|
|
16
16
|
var TrackQuickActionType = exports.TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
17
17
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -68,6 +68,7 @@ function Component(_ref) {
|
|
|
68
68
|
isPreviewPanelAvailable = _useSmartLink.isPreviewPanelAvailable,
|
|
69
69
|
openPreviewPanel = _useSmartLink.openPreviewPanel;
|
|
70
70
|
var ari = (0, _helpers.getObjectAri)(state.details);
|
|
71
|
+
var thirdPartyARI = (0, _helpers.getThirdPartyARI)(state.details);
|
|
71
72
|
var name = (0, _helpers.getObjectName)(state.details);
|
|
72
73
|
var definitionId = (0, _helpers.getDefinitionId)(state.details);
|
|
73
74
|
var extensionKey = (0, _helpers.getExtensionKey)(state.details);
|
|
@@ -91,7 +92,7 @@ function Component(_ref) {
|
|
|
91
92
|
isModifierKeyPressed: isModifierKeyPressed
|
|
92
93
|
});
|
|
93
94
|
if ((0, _platformFeatureFlags.fg)('platform_smartlink_3pclick_analytics')) {
|
|
94
|
-
if (
|
|
95
|
+
if (thirdPartyARI && thirdPartyARI.startsWith(thirdPartyARIPrefix)) {
|
|
95
96
|
var sourceURL = window.location.href;
|
|
96
97
|
var clickURL = (0, _helpers.getClickUrl)(url, state.details);
|
|
97
98
|
if (clickURL === url) {
|
|
@@ -107,7 +108,7 @@ function Component(_ref) {
|
|
|
107
108
|
},
|
|
108
109
|
nonPrivacySafeAttributes: {
|
|
109
110
|
sourceURL: sourceURL,
|
|
110
|
-
thirdPartyARI:
|
|
111
|
+
thirdPartyARI: thirdPartyARI
|
|
111
112
|
}
|
|
112
113
|
});
|
|
113
114
|
smartlinkClickAnalyticsEvent.fire('media');
|
|
@@ -153,7 +154,7 @@ function Component(_ref) {
|
|
|
153
154
|
}
|
|
154
155
|
(0, _click.fireLinkClickedEvent)(createAnalyticsEvent)(event);
|
|
155
156
|
}
|
|
156
|
-
}, [fireEvent, id, isFlexibleUi, appearance, definitionId, onClick, url, state.details, ari, name, isPreviewPanelAvailable, openPreviewPanel, createAnalyticsEvent]);
|
|
157
|
+
}, [fireEvent, id, isFlexibleUi, appearance, definitionId, onClick, url, state.details, ari, name, isPreviewPanelAvailable, openPreviewPanel, createAnalyticsEvent, thirdPartyARI]);
|
|
157
158
|
var handleAuthorize = (0, _react.useCallback)(function () {
|
|
158
159
|
return actions.authorize(appearance);
|
|
159
160
|
}, [actions, appearance]);
|
|
@@ -10,6 +10,7 @@ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends")
|
|
|
10
10
|
var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/helpers/objectWithoutProperties"));
|
|
11
11
|
var _react = _interopRequireDefault(require("react"));
|
|
12
12
|
var _reactIntlNext = require("react-intl-next");
|
|
13
|
+
var _featureGateJsClient = _interopRequireDefault(require("@atlaskit/feature-gate-js-client"));
|
|
13
14
|
var _constants = require("../../../../../constants");
|
|
14
15
|
var _messages = require("../../../../../messages");
|
|
15
16
|
var _flexibleUiContext = require("../../../../../state/flexible-ui-context");
|
|
@@ -59,11 +60,11 @@ var FollowAction = function FollowAction(props) {
|
|
|
59
60
|
data = (0, _objectWithoutProperties2.default)(actionData, _excluded);
|
|
60
61
|
var isStackItem = props.as === 'stack-item';
|
|
61
62
|
var message = value ? _messages.messages.follow : _messages.messages.unfollow;
|
|
62
|
-
var projectMessage = value ? _messages.messages.follow_project : _messages.messages.unfollow_project;
|
|
63
|
+
var projectMessage = value ? _featureGateJsClient.default.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? _messages.messages.follow_projectGalaxia : _messages.messages.follow_project : _featureGateJsClient.default.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? _messages.messages.unfollow_projectGalaxia : _messages.messages.unfollow_project;
|
|
63
64
|
var goalMessage = value ? _messages.messages.follow_goal : _messages.messages.unfollow_goal;
|
|
64
65
|
var stackMessage = isProject ? projectMessage : goalMessage;
|
|
65
66
|
var label = isStackItem ? stackMessage : message;
|
|
66
|
-
var projectTooltipMessage = value ? _messages.messages.follow_project_description : _messages.messages.unfollow_project_description;
|
|
67
|
+
var projectTooltipMessage = value ? _featureGateJsClient.default.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? _messages.messages.follow_project_descriptionGalaxia : _messages.messages.follow_project_description : _featureGateJsClient.default.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? _messages.messages.unfollow_project_descriptionGalaxia : _messages.messages.unfollow_project_description;
|
|
67
68
|
var goalTooltipMessage = value ? _messages.messages.follow_goal_description : _messages.messages.unfollow_goal_description;
|
|
68
69
|
var stackTooltipMessage = isProject ? projectTooltipMessage : goalTooltipMessage;
|
|
69
70
|
var tooltipMessage = isStackItem ? stackTooltipMessage : message;
|
|
@@ -1,18 +1,20 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
|
|
3
|
+
var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
|
|
3
4
|
Object.defineProperty(exports, "__esModule", {
|
|
4
5
|
value: true
|
|
5
6
|
});
|
|
6
7
|
exports.getFollowActionErrorMessage = void 0;
|
|
8
|
+
var _featureGateJsClient = _interopRequireDefault(require("@atlaskit/feature-gate-js-client"));
|
|
7
9
|
var _messages = require("../../../../../messages");
|
|
8
10
|
var getFollowActionErrorMessage = exports.getFollowActionErrorMessage = function getFollowActionErrorMessage() {
|
|
9
11
|
var isProject = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
|
|
10
12
|
var isFollow = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
11
13
|
if (isProject && isFollow) {
|
|
12
|
-
return _messages.messages.follow_project_error;
|
|
14
|
+
return _featureGateJsClient.default.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? _messages.messages.follow_project_errorGalaxia : _messages.messages.follow_project_error;
|
|
13
15
|
}
|
|
14
16
|
if (isProject && !isFollow) {
|
|
15
|
-
return _messages.messages.unfollow_project_error;
|
|
17
|
+
return _featureGateJsClient.default.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? _messages.messages.unfollow_project_errorGalaxia : _messages.messages.unfollow_project_error;
|
|
16
18
|
}
|
|
17
19
|
if (!isProject && isFollow) {
|
|
18
20
|
return _messages.messages.follow_goal_error;
|
|
@@ -19,7 +19,7 @@ var _excluded = ["href", "children", "checkSafety", "onClick", "testId", "isLink
|
|
|
19
19
|
_excluded2 = ["isLinkSafe", "showSafetyWarningModal"];
|
|
20
20
|
var PACKAGE_DATA = {
|
|
21
21
|
packageName: "@atlaskit/smart-card",
|
|
22
|
-
packageVersion: "40.8.
|
|
22
|
+
packageVersion: "40.8.2",
|
|
23
23
|
componentName: 'linkUrl'
|
|
24
24
|
};
|
|
25
25
|
var Anchor = (0, _click.withLinkClickedEvent)('a');
|
package/dist/es2019/messages.js
CHANGED
|
@@ -778,5 +778,35 @@ export const messages = defineMessages({
|
|
|
778
778
|
id: 'fabric.linking.user_attributes',
|
|
779
779
|
defaultMessage: '{context}',
|
|
780
780
|
description: 'Displays user attributes like role, department, location, and pronouns'
|
|
781
|
+
},
|
|
782
|
+
follow_project_descriptionGalaxia: {
|
|
783
|
+
id: 'fabric.linking.follow_project_description-galaxia',
|
|
784
|
+
defaultMessage: 'Follow to get notifications on this space',
|
|
785
|
+
description: 'Description on what Follow does'
|
|
786
|
+
},
|
|
787
|
+
follow_projectGalaxia: {
|
|
788
|
+
id: 'fabric.linking.follow_project-galaxia',
|
|
789
|
+
defaultMessage: 'Follow space',
|
|
790
|
+
description: 'Click to follow a project.'
|
|
791
|
+
},
|
|
792
|
+
follow_project_errorGalaxia: {
|
|
793
|
+
id: 'fabric.linking.follow_project_error-galaxia',
|
|
794
|
+
defaultMessage: 'We encountered an error while trying to follow the space. Check your connection or refresh the page and try again.',
|
|
795
|
+
description: 'Shown when an unknown error occurs when following an Atlas project'
|
|
796
|
+
},
|
|
797
|
+
unfollow_project_descriptionGalaxia: {
|
|
798
|
+
id: 'fabric.linking.unfollow_project_description-galaxia',
|
|
799
|
+
defaultMessage: 'Unfollow to stop receiving space notifications',
|
|
800
|
+
description: 'Description on what Unfollow does'
|
|
801
|
+
},
|
|
802
|
+
unfollow_projectGalaxia: {
|
|
803
|
+
id: 'fabric.linking.unfollow_project-galaxia',
|
|
804
|
+
defaultMessage: 'Unfollow space',
|
|
805
|
+
description: 'Click to unfollow a project.'
|
|
806
|
+
},
|
|
807
|
+
unfollow_project_errorGalaxia: {
|
|
808
|
+
id: 'fabric.linking.unfollow_project_error-galaxia',
|
|
809
|
+
defaultMessage: 'We encountered an error while trying to unfollow the space. Check your connection or refresh the page and try again.',
|
|
810
|
+
description: 'Shown when an unknown error occurs when unfollowing an Atlas project'
|
|
781
811
|
}
|
|
782
812
|
});
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
1
2
|
import { extractVisitUrl } from '../extractors/common/primitives/extractVisitUrl';
|
|
2
3
|
export const getByDefinitionId = (definitionId, store) => {
|
|
3
4
|
const urls = Object.keys(store);
|
|
@@ -26,6 +27,14 @@ export const getExtensionKey = details => {
|
|
|
26
27
|
return details === null || details === void 0 ? void 0 : (_details$meta2 = details.meta) === null || _details$meta2 === void 0 ? void 0 : _details$meta2.key;
|
|
27
28
|
};
|
|
28
29
|
export const getObjectAri = details => (details === null || details === void 0 ? void 0 : details.data) && 'atlassian:ari' in details.data && details.data['atlassian:ari'] || undefined;
|
|
30
|
+
export const getThirdPartyARI = details => {
|
|
31
|
+
if (fg('platform_smartlink_3pclick_analytics')) {
|
|
32
|
+
if (details !== null && details !== void 0 && details.entityData && 'thirdPartyAri' in details.entityData && details.entityData.thirdPartyAri) {
|
|
33
|
+
return details.entityData.thirdPartyAri;
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
return undefined;
|
|
37
|
+
};
|
|
29
38
|
export const getObjectName = details => (details === null || details === void 0 ? void 0 : details.data) && 'name' in details.data && details.data.name || undefined;
|
|
30
39
|
export const getObjectIconUrl = details => {
|
|
31
40
|
if (details !== null && details !== void 0 && details.data && 'icon' in details.data && details.data.icon) {
|
|
@@ -2,7 +2,7 @@ export const ANALYTICS_CHANNEL = 'media';
|
|
|
2
2
|
export const context = {
|
|
3
3
|
componentName: 'smart-cards',
|
|
4
4
|
packageName: "@atlaskit/smart-card",
|
|
5
|
-
packageVersion: "40.8.
|
|
5
|
+
packageVersion: "40.8.2"
|
|
6
6
|
};
|
|
7
7
|
export let TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
8
8
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -5,7 +5,7 @@ import { useAnalyticsEvents } from '../../common/analytics/generated/use-analyti
|
|
|
5
5
|
import { CardDisplay } from '../../constants';
|
|
6
6
|
import { useSmartLink } from '../../state';
|
|
7
7
|
import { succeedUfoExperience } from '../../state/analytics';
|
|
8
|
-
import { getClickUrl, getDefinitionId, getExtensionKey, getObjectAri, getObjectIconUrl, getObjectName, getResourceType, getServices, isFinalState } from '../../state/helpers';
|
|
8
|
+
import { getClickUrl, getDefinitionId, getExtensionKey, getObjectAri, getObjectIconUrl, getObjectName, getResourceType, getServices, getThirdPartyARI, isFinalState } from '../../state/helpers';
|
|
9
9
|
import { SmartLinkModalProvider } from '../../state/modal';
|
|
10
10
|
import { isSpecialClick, isSpecialEvent, isSpecialKey } from '../../utils';
|
|
11
11
|
import { combineActionOptions } from '../../utils/actions/combine-action-options';
|
|
@@ -63,6 +63,7 @@ function Component({
|
|
|
63
63
|
openPreviewPanel
|
|
64
64
|
} = useSmartLink(id, url);
|
|
65
65
|
const ari = getObjectAri(state.details);
|
|
66
|
+
const thirdPartyARI = getThirdPartyARI(state.details);
|
|
66
67
|
const name = getObjectName(state.details);
|
|
67
68
|
const definitionId = getDefinitionId(state.details);
|
|
68
69
|
const extensionKey = getExtensionKey(state.details);
|
|
@@ -84,7 +85,7 @@ function Component({
|
|
|
84
85
|
isModifierKeyPressed
|
|
85
86
|
});
|
|
86
87
|
if (fg('platform_smartlink_3pclick_analytics')) {
|
|
87
|
-
if (
|
|
88
|
+
if (thirdPartyARI && thirdPartyARI.startsWith(thirdPartyARIPrefix)) {
|
|
88
89
|
const sourceURL = window.location.href;
|
|
89
90
|
const clickURL = getClickUrl(url, state.details);
|
|
90
91
|
if (clickURL === url) {
|
|
@@ -100,7 +101,7 @@ function Component({
|
|
|
100
101
|
},
|
|
101
102
|
nonPrivacySafeAttributes: {
|
|
102
103
|
sourceURL: sourceURL,
|
|
103
|
-
thirdPartyARI:
|
|
104
|
+
thirdPartyARI: thirdPartyARI
|
|
104
105
|
}
|
|
105
106
|
});
|
|
106
107
|
smartlinkClickAnalyticsEvent.fire('media');
|
|
@@ -146,7 +147,7 @@ function Component({
|
|
|
146
147
|
}
|
|
147
148
|
fireLinkClickedEvent(createAnalyticsEvent)(event);
|
|
148
149
|
}
|
|
149
|
-
}, [fireEvent, id, isFlexibleUi, appearance, definitionId, onClick, url, state.details, ari, name, isPreviewPanelAvailable, openPreviewPanel, createAnalyticsEvent]);
|
|
150
|
+
}, [fireEvent, id, isFlexibleUi, appearance, definitionId, onClick, url, state.details, ari, name, isPreviewPanelAvailable, openPreviewPanel, createAnalyticsEvent, thirdPartyARI]);
|
|
150
151
|
const handleAuthorize = useCallback(() => actions.authorize(appearance), [actions, appearance]);
|
|
151
152
|
const handleRetry = useCallback(() => {
|
|
152
153
|
actions.reload();
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { FormattedMessage } from 'react-intl-next';
|
|
4
|
+
import FeatureGates from '@atlaskit/feature-gate-js-client';
|
|
4
5
|
import { ActionName } from '../../../../../constants';
|
|
5
6
|
import { messages } from '../../../../../messages';
|
|
6
7
|
import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
|
|
@@ -40,11 +41,11 @@ const FollowAction = props => {
|
|
|
40
41
|
} = actionData;
|
|
41
42
|
const isStackItem = props.as === 'stack-item';
|
|
42
43
|
const message = value ? messages.follow : messages.unfollow;
|
|
43
|
-
const projectMessage = value ? messages.follow_project : messages.unfollow_project;
|
|
44
|
+
const projectMessage = value ? FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.follow_projectGalaxia : messages.follow_project : FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.unfollow_projectGalaxia : messages.unfollow_project;
|
|
44
45
|
const goalMessage = value ? messages.follow_goal : messages.unfollow_goal;
|
|
45
46
|
const stackMessage = isProject ? projectMessage : goalMessage;
|
|
46
47
|
const label = isStackItem ? stackMessage : message;
|
|
47
|
-
const projectTooltipMessage = value ? messages.follow_project_description : messages.unfollow_project_description;
|
|
48
|
+
const projectTooltipMessage = value ? FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.follow_project_descriptionGalaxia : messages.follow_project_description : FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.unfollow_project_descriptionGalaxia : messages.unfollow_project_description;
|
|
48
49
|
const goalTooltipMessage = value ? messages.follow_goal_description : messages.unfollow_goal_description;
|
|
49
50
|
const stackTooltipMessage = isProject ? projectTooltipMessage : goalTooltipMessage;
|
|
50
51
|
const tooltipMessage = isStackItem ? stackTooltipMessage : message;
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
+
import FeatureGates from '@atlaskit/feature-gate-js-client';
|
|
1
2
|
import { messages } from '../../../../../messages';
|
|
2
3
|
export const getFollowActionErrorMessage = (isProject = false, isFollow = false) => {
|
|
3
4
|
if (isProject && isFollow) {
|
|
4
|
-
return messages.follow_project_error;
|
|
5
|
+
return FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.follow_project_errorGalaxia : messages.follow_project_error;
|
|
5
6
|
}
|
|
6
7
|
if (isProject && !isFollow) {
|
|
7
|
-
return messages.unfollow_project_error;
|
|
8
|
+
return FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.unfollow_project_errorGalaxia : messages.unfollow_project_error;
|
|
8
9
|
}
|
|
9
10
|
if (!isProject && isFollow) {
|
|
10
11
|
return messages.follow_goal_error;
|
|
@@ -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: "40.8.
|
|
12
|
+
packageVersion: "40.8.2",
|
|
13
13
|
componentName: 'linkUrl'
|
|
14
14
|
};
|
|
15
15
|
const Anchor = withLinkClickedEvent('a');
|
package/dist/esm/messages.js
CHANGED
|
@@ -778,5 +778,35 @@ export var messages = defineMessages({
|
|
|
778
778
|
id: 'fabric.linking.user_attributes',
|
|
779
779
|
defaultMessage: '{context}',
|
|
780
780
|
description: 'Displays user attributes like role, department, location, and pronouns'
|
|
781
|
+
},
|
|
782
|
+
follow_project_descriptionGalaxia: {
|
|
783
|
+
id: 'fabric.linking.follow_project_description-galaxia',
|
|
784
|
+
defaultMessage: 'Follow to get notifications on this space',
|
|
785
|
+
description: 'Description on what Follow does'
|
|
786
|
+
},
|
|
787
|
+
follow_projectGalaxia: {
|
|
788
|
+
id: 'fabric.linking.follow_project-galaxia',
|
|
789
|
+
defaultMessage: 'Follow space',
|
|
790
|
+
description: 'Click to follow a project.'
|
|
791
|
+
},
|
|
792
|
+
follow_project_errorGalaxia: {
|
|
793
|
+
id: 'fabric.linking.follow_project_error-galaxia',
|
|
794
|
+
defaultMessage: 'We encountered an error while trying to follow the space. Check your connection or refresh the page and try again.',
|
|
795
|
+
description: 'Shown when an unknown error occurs when following an Atlas project'
|
|
796
|
+
},
|
|
797
|
+
unfollow_project_descriptionGalaxia: {
|
|
798
|
+
id: 'fabric.linking.unfollow_project_description-galaxia',
|
|
799
|
+
defaultMessage: 'Unfollow to stop receiving space notifications',
|
|
800
|
+
description: 'Description on what Unfollow does'
|
|
801
|
+
},
|
|
802
|
+
unfollow_projectGalaxia: {
|
|
803
|
+
id: 'fabric.linking.unfollow_project-galaxia',
|
|
804
|
+
defaultMessage: 'Unfollow space',
|
|
805
|
+
description: 'Click to unfollow a project.'
|
|
806
|
+
},
|
|
807
|
+
unfollow_project_errorGalaxia: {
|
|
808
|
+
id: 'fabric.linking.unfollow_project_error-galaxia',
|
|
809
|
+
defaultMessage: 'We encountered an error while trying to unfollow the space. Check your connection or refresh the page and try again.',
|
|
810
|
+
description: 'Shown when an unknown error occurs when unfollowing an Atlas project'
|
|
781
811
|
}
|
|
782
812
|
});
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import _typeof from "@babel/runtime/helpers/typeof";
|
|
2
|
+
import { fg } from '@atlaskit/platform-feature-flags';
|
|
2
3
|
import { extractVisitUrl } from '../extractors/common/primitives/extractVisitUrl';
|
|
3
4
|
export var getByDefinitionId = function getByDefinitionId(definitionId, store) {
|
|
4
5
|
var urls = Object.keys(store);
|
|
@@ -27,6 +28,14 @@ export var getExtensionKey = function getExtensionKey(details) {
|
|
|
27
28
|
export var getObjectAri = function getObjectAri(details) {
|
|
28
29
|
return (details === null || details === void 0 ? void 0 : details.data) && 'atlassian:ari' in details.data && details.data['atlassian:ari'] || undefined;
|
|
29
30
|
};
|
|
31
|
+
export var getThirdPartyARI = function getThirdPartyARI(details) {
|
|
32
|
+
if (fg('platform_smartlink_3pclick_analytics')) {
|
|
33
|
+
if (details !== null && details !== void 0 && details.entityData && 'thirdPartyAri' in details.entityData && details.entityData.thirdPartyAri) {
|
|
34
|
+
return details.entityData.thirdPartyAri;
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
return undefined;
|
|
38
|
+
};
|
|
30
39
|
export var getObjectName = function getObjectName(details) {
|
|
31
40
|
return (details === null || details === void 0 ? void 0 : details.data) && 'name' in details.data && details.data.name || undefined;
|
|
32
41
|
};
|
|
@@ -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: "40.8.
|
|
7
|
+
packageVersion: "40.8.2"
|
|
8
8
|
};
|
|
9
9
|
export var TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
10
10
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -5,7 +5,7 @@ import { useAnalyticsEvents } from '../../common/analytics/generated/use-analyti
|
|
|
5
5
|
import { CardDisplay } from '../../constants';
|
|
6
6
|
import { useSmartLink } from '../../state';
|
|
7
7
|
import { succeedUfoExperience } from '../../state/analytics';
|
|
8
|
-
import { getClickUrl, getDefinitionId, getExtensionKey, getObjectAri, getObjectIconUrl, getObjectName, getResourceType, getServices, isFinalState } from '../../state/helpers';
|
|
8
|
+
import { getClickUrl, getDefinitionId, getExtensionKey, getObjectAri, getObjectIconUrl, getObjectName, getResourceType, getServices, getThirdPartyARI, isFinalState } from '../../state/helpers';
|
|
9
9
|
import { SmartLinkModalProvider } from '../../state/modal';
|
|
10
10
|
import { isSpecialClick, isSpecialEvent, isSpecialKey } from '../../utils';
|
|
11
11
|
import { combineActionOptions } from '../../utils/actions/combine-action-options';
|
|
@@ -59,6 +59,7 @@ function Component(_ref) {
|
|
|
59
59
|
isPreviewPanelAvailable = _useSmartLink.isPreviewPanelAvailable,
|
|
60
60
|
openPreviewPanel = _useSmartLink.openPreviewPanel;
|
|
61
61
|
var ari = getObjectAri(state.details);
|
|
62
|
+
var thirdPartyARI = getThirdPartyARI(state.details);
|
|
62
63
|
var name = getObjectName(state.details);
|
|
63
64
|
var definitionId = getDefinitionId(state.details);
|
|
64
65
|
var extensionKey = getExtensionKey(state.details);
|
|
@@ -82,7 +83,7 @@ function Component(_ref) {
|
|
|
82
83
|
isModifierKeyPressed: isModifierKeyPressed
|
|
83
84
|
});
|
|
84
85
|
if (fg('platform_smartlink_3pclick_analytics')) {
|
|
85
|
-
if (
|
|
86
|
+
if (thirdPartyARI && thirdPartyARI.startsWith(thirdPartyARIPrefix)) {
|
|
86
87
|
var sourceURL = window.location.href;
|
|
87
88
|
var clickURL = getClickUrl(url, state.details);
|
|
88
89
|
if (clickURL === url) {
|
|
@@ -98,7 +99,7 @@ function Component(_ref) {
|
|
|
98
99
|
},
|
|
99
100
|
nonPrivacySafeAttributes: {
|
|
100
101
|
sourceURL: sourceURL,
|
|
101
|
-
thirdPartyARI:
|
|
102
|
+
thirdPartyARI: thirdPartyARI
|
|
102
103
|
}
|
|
103
104
|
});
|
|
104
105
|
smartlinkClickAnalyticsEvent.fire('media');
|
|
@@ -144,7 +145,7 @@ function Component(_ref) {
|
|
|
144
145
|
}
|
|
145
146
|
fireLinkClickedEvent(createAnalyticsEvent)(event);
|
|
146
147
|
}
|
|
147
|
-
}, [fireEvent, id, isFlexibleUi, appearance, definitionId, onClick, url, state.details, ari, name, isPreviewPanelAvailable, openPreviewPanel, createAnalyticsEvent]);
|
|
148
|
+
}, [fireEvent, id, isFlexibleUi, appearance, definitionId, onClick, url, state.details, ari, name, isPreviewPanelAvailable, openPreviewPanel, createAnalyticsEvent, thirdPartyARI]);
|
|
148
149
|
var handleAuthorize = useCallback(function () {
|
|
149
150
|
return actions.authorize(appearance);
|
|
150
151
|
}, [actions, appearance]);
|
|
@@ -3,6 +3,7 @@ import _objectWithoutProperties from "@babel/runtime/helpers/objectWithoutProper
|
|
|
3
3
|
var _excluded = ["value", "isProject"];
|
|
4
4
|
import React from 'react';
|
|
5
5
|
import { FormattedMessage } from 'react-intl-next';
|
|
6
|
+
import FeatureGates from '@atlaskit/feature-gate-js-client';
|
|
6
7
|
import { ActionName } from '../../../../../constants';
|
|
7
8
|
import { messages } from '../../../../../messages';
|
|
8
9
|
import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
|
|
@@ -46,11 +47,11 @@ var FollowAction = function FollowAction(props) {
|
|
|
46
47
|
data = _objectWithoutProperties(actionData, _excluded);
|
|
47
48
|
var isStackItem = props.as === 'stack-item';
|
|
48
49
|
var message = value ? messages.follow : messages.unfollow;
|
|
49
|
-
var projectMessage = value ? messages.follow_project : messages.unfollow_project;
|
|
50
|
+
var projectMessage = value ? FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.follow_projectGalaxia : messages.follow_project : FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.unfollow_projectGalaxia : messages.unfollow_project;
|
|
50
51
|
var goalMessage = value ? messages.follow_goal : messages.unfollow_goal;
|
|
51
52
|
var stackMessage = isProject ? projectMessage : goalMessage;
|
|
52
53
|
var label = isStackItem ? stackMessage : message;
|
|
53
|
-
var projectTooltipMessage = value ? messages.follow_project_description : messages.unfollow_project_description;
|
|
54
|
+
var projectTooltipMessage = value ? FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.follow_project_descriptionGalaxia : messages.follow_project_description : FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.unfollow_project_descriptionGalaxia : messages.unfollow_project_description;
|
|
54
55
|
var goalTooltipMessage = value ? messages.follow_goal_description : messages.unfollow_goal_description;
|
|
55
56
|
var stackTooltipMessage = isProject ? projectTooltipMessage : goalTooltipMessage;
|
|
56
57
|
var tooltipMessage = isStackItem ? stackTooltipMessage : message;
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
+
import FeatureGates from '@atlaskit/feature-gate-js-client';
|
|
1
2
|
import { messages } from '../../../../../messages';
|
|
2
3
|
export var getFollowActionErrorMessage = function getFollowActionErrorMessage() {
|
|
3
4
|
var isProject = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : false;
|
|
4
5
|
var isFollow = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : false;
|
|
5
6
|
if (isProject && isFollow) {
|
|
6
|
-
return messages.follow_project_error;
|
|
7
|
+
return FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.follow_project_errorGalaxia : messages.follow_project_error;
|
|
7
8
|
}
|
|
8
9
|
if (isProject && !isFollow) {
|
|
9
|
-
return messages.unfollow_project_error;
|
|
10
|
+
return FeatureGates.getExperimentValue('project-terminology-refresh', 'isEnabled', false) ? messages.unfollow_project_errorGalaxia : messages.unfollow_project_error;
|
|
10
11
|
}
|
|
11
12
|
if (!isProject && isFollow) {
|
|
12
13
|
return messages.follow_goal_error;
|
|
@@ -12,7 +12,7 @@ import LinkWarningModal from './LinkWarningModal';
|
|
|
12
12
|
import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
|
|
13
13
|
var PACKAGE_DATA = {
|
|
14
14
|
packageName: "@atlaskit/smart-card",
|
|
15
|
-
packageVersion: "40.8.
|
|
15
|
+
packageVersion: "40.8.2",
|
|
16
16
|
componentName: 'linkUrl'
|
|
17
17
|
};
|
|
18
18
|
var Anchor = withLinkClickedEvent('a');
|
package/dist/types/messages.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type MessageDescriptor } from 'react-intl-next';
|
|
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 MessageKey = 'assigned_to' | 'ai_summarize' | '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' | 'follow_goal' | 'follow_goal_description' | 'follow_project_error' | '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_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' | 'unassigned' | 'unfollow' | 'unfollow_project_description' | 'unfollow_project' | 'unfollow_project_error' | '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';
|
|
3
|
+
export type MessageKey = 'assigned_to' | 'ai_summarize' | '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_projectGalaxia' | '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_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' | 'unassigned' | 'unfollow' | 'unfollow_project_description' | 'unfollow_project_descriptionGalaxia' | 'unfollow_projectGalaxia' | 'unfollow_project' | 'unfollow_projectGalaxia' | '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';
|
|
4
4
|
type Messages = {
|
|
5
5
|
[K in MessageKey]: MessageDescriptor;
|
|
6
6
|
};
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import { type JsonLd } from '@atlaskit/json-ld-types';
|
|
2
2
|
import { type DatasourceResolveResponse, type JsonLdDatasourceResponse } from '@atlaskit/link-client-extension';
|
|
3
3
|
import { type CardStore, type CardType } from '@atlaskit/linking-common';
|
|
4
|
+
import { type SmartLinkResponse } from '@atlaskit/linking-types';
|
|
4
5
|
import { type DestinationProduct, type DestinationSubproduct } from '../utils/analytics/types';
|
|
5
6
|
export declare const getByDefinitionId: (definitionId: string | undefined, store: CardStore) => string[];
|
|
6
7
|
export declare const getClickUrl: (url: string, jsonLd?: JsonLd.Response) => string;
|
|
7
8
|
export declare const getDefinitionId: (details?: JsonLd.Response) => string | undefined;
|
|
8
9
|
export declare const getExtensionKey: (details?: JsonLd.Response) => string | undefined;
|
|
9
10
|
export declare const getObjectAri: (details?: JsonLd.Response) => string | undefined;
|
|
11
|
+
export declare const getThirdPartyARI: (details?: SmartLinkResponse) => string | undefined;
|
|
10
12
|
export declare const getObjectName: (details?: JsonLd.Response) => string | undefined;
|
|
11
13
|
export declare const getObjectIconUrl: (details?: JsonLd.Response) => string | undefined;
|
|
12
14
|
export declare const getResourceType: (details?: JsonLd.Response) => string | undefined;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { type MessageDescriptor } from 'react-intl-next';
|
|
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 MessageKey = 'assigned_to' | 'ai_summarize' | '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' | 'follow_goal' | 'follow_goal_description' | 'follow_project_error' | '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_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' | 'unassigned' | 'unfollow' | 'unfollow_project_description' | 'unfollow_project' | 'unfollow_project_error' | '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';
|
|
3
|
+
export type MessageKey = 'assigned_to' | 'ai_summarize' | '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_projectGalaxia' | '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_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' | 'unassigned' | 'unfollow' | 'unfollow_project_description' | 'unfollow_project_descriptionGalaxia' | 'unfollow_projectGalaxia' | 'unfollow_project' | 'unfollow_projectGalaxia' | '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';
|
|
4
4
|
type Messages = {
|
|
5
5
|
[K in MessageKey]: MessageDescriptor;
|
|
6
6
|
};
|
|
@@ -1,12 +1,14 @@
|
|
|
1
1
|
import { type JsonLd } from '@atlaskit/json-ld-types';
|
|
2
2
|
import { type DatasourceResolveResponse, type JsonLdDatasourceResponse } from '@atlaskit/link-client-extension';
|
|
3
3
|
import { type CardStore, type CardType } from '@atlaskit/linking-common';
|
|
4
|
+
import { type SmartLinkResponse } from '@atlaskit/linking-types';
|
|
4
5
|
import { type DestinationProduct, type DestinationSubproduct } from '../utils/analytics/types';
|
|
5
6
|
export declare const getByDefinitionId: (definitionId: string | undefined, store: CardStore) => string[];
|
|
6
7
|
export declare const getClickUrl: (url: string, jsonLd?: JsonLd.Response) => string;
|
|
7
8
|
export declare const getDefinitionId: (details?: JsonLd.Response) => string | undefined;
|
|
8
9
|
export declare const getExtensionKey: (details?: JsonLd.Response) => string | undefined;
|
|
9
10
|
export declare const getObjectAri: (details?: JsonLd.Response) => string | undefined;
|
|
11
|
+
export declare const getThirdPartyARI: (details?: SmartLinkResponse) => string | undefined;
|
|
10
12
|
export declare const getObjectName: (details?: JsonLd.Response) => string | undefined;
|
|
11
13
|
export declare const getObjectIconUrl: (details?: JsonLd.Response) => string | undefined;
|
|
12
14
|
export declare const getResourceType: (details?: JsonLd.Response) => string | undefined;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/smart-card",
|
|
3
|
-
"version": "40.8.
|
|
3
|
+
"version": "40.8.3",
|
|
4
4
|
"description": "Smart card component",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -35,6 +35,7 @@
|
|
|
35
35
|
"@atlaskit/checkbox": "^17.1.0",
|
|
36
36
|
"@atlaskit/css": "^0.12.0",
|
|
37
37
|
"@atlaskit/dropdown-menu": "^16.3.0",
|
|
38
|
+
"@atlaskit/feature-gate-js-client": "^5.5.0",
|
|
38
39
|
"@atlaskit/form": "^12.0.0",
|
|
39
40
|
"@atlaskit/frontend-utilities": "^3.1.0",
|
|
40
41
|
"@atlaskit/heading": "^5.2.0",
|