@atlaskit/smart-card 26.63.0 → 26.63.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +12 -0
- package/analytics.spec.yaml +5 -0
- package/dist/cjs/state/hooks/use-ai-summary/index.js +7 -1
- package/dist/cjs/utils/analytics/analytics.js +1 -1
- package/dist/cjs/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +3 -2
- package/dist/cjs/view/HoverCard/components/views/resolved/index.js +1 -1
- package/dist/cjs/view/LinkUrl/index.js +1 -1
- package/dist/es2019/state/hooks/use-ai-summary/index.js +7 -1
- package/dist/es2019/utils/analytics/analytics.js +1 -1
- package/dist/es2019/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +3 -2
- package/dist/es2019/view/HoverCard/components/views/resolved/index.js +1 -1
- package/dist/es2019/view/LinkUrl/index.js +1 -1
- package/dist/esm/state/hooks/use-ai-summary/index.js +7 -1
- package/dist/esm/utils/analytics/analytics.js +1 -1
- package/dist/esm/view/FlexibleCard/components/blocks/action-block/action-footer/index.js +3 -2
- package/dist/esm/view/HoverCard/components/views/resolved/index.js +1 -1
- package/dist/esm/view/LinkUrl/index.js +1 -1
- package/dist/types/common/analytics/generated/analytics.types.d.ts +4 -0
- package/dist/types-ts4.5/common/analytics/generated/analytics.types.d.ts +4 -0
- package/package.json +2 -2
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,17 @@
|
|
|
1
1
|
# @atlaskit/smart-card
|
|
2
2
|
|
|
3
|
+
## 26.63.1
|
|
4
|
+
|
|
5
|
+
### Patch Changes
|
|
6
|
+
|
|
7
|
+
- [#98606](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/98606)
|
|
8
|
+
[`11fe8e219753`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/11fe8e219753) -
|
|
9
|
+
Hover preview redesign: Update sizing and gap
|
|
10
|
+
- [#98541](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/98541)
|
|
11
|
+
[`8393ed89f5cf`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/8393ed89f5cf) -
|
|
12
|
+
EDM-9790 Add isSlaError event attribute
|
|
13
|
+
- Updated dependencies
|
|
14
|
+
|
|
3
15
|
## 26.63.0
|
|
4
16
|
|
|
5
17
|
### Minor Changes
|
package/analytics.spec.yaml
CHANGED
|
@@ -128,6 +128,11 @@ events:
|
|
|
128
128
|
required: false
|
|
129
129
|
type: string
|
|
130
130
|
description: failure reason
|
|
131
|
+
isSloError:
|
|
132
|
+
required: true
|
|
133
|
+
type: boolean
|
|
134
|
+
description: True if the error should be counted towards the SLO.
|
|
135
|
+
|
|
131
136
|
|
|
132
137
|
- aiInteraction initiated:
|
|
133
138
|
type: track
|
|
@@ -37,8 +37,14 @@ var useAISummary = exports.useAISummary = function useAISummary(props) {
|
|
|
37
37
|
(0, _analytics.succeedUfoExperience)(EXPERIENCE_NAME, id);
|
|
38
38
|
}, [fireEvent]);
|
|
39
39
|
var onError = (0, _react.useCallback)(function (id, reason) {
|
|
40
|
+
/**
|
|
41
|
+
* Errors should only be counted to the SLO if they are not due to acceptable use violations
|
|
42
|
+
* or HIPAA content detected.
|
|
43
|
+
*/
|
|
44
|
+
var isSloError = reason !== "ACCEPTABLE_USE_VIOLATIONS" && reason !== "HIPAA_CONTENT_DETECTED";
|
|
40
45
|
fireEvent('operational.summary.failed', {
|
|
41
|
-
reason: reason || null
|
|
46
|
+
reason: reason || null,
|
|
47
|
+
isSloError: isSloError
|
|
42
48
|
});
|
|
43
49
|
(0, _analytics.failUfoExperience)(EXPERIENCE_NAME, id);
|
|
44
50
|
}, [fireEvent]);
|
|
@@ -22,7 +22,7 @@ var ANALYTICS_CHANNEL = exports.ANALYTICS_CHANNEL = 'media';
|
|
|
22
22
|
var context = exports.context = {
|
|
23
23
|
componentName: 'smart-cards',
|
|
24
24
|
packageName: "@atlaskit/smart-card",
|
|
25
|
-
packageVersion: "26.63.
|
|
25
|
+
packageVersion: "26.63.1"
|
|
26
26
|
};
|
|
27
27
|
var TrackQuickActionType = exports.TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
28
28
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -13,8 +13,9 @@ var containerStyles = (0, _primitives.xcss)({
|
|
|
13
13
|
all: 'unset',
|
|
14
14
|
borderRadius: 'border.radius',
|
|
15
15
|
margin: 'space.100',
|
|
16
|
+
marginBottom: 'space.0',
|
|
16
17
|
lineHeight: '20px',
|
|
17
|
-
padding: 'space.
|
|
18
|
+
padding: 'space.075',
|
|
18
19
|
paddingInline: 'space.100',
|
|
19
20
|
width: '100%',
|
|
20
21
|
':empty': {
|
|
@@ -60,7 +61,7 @@ var ActionFooter = exports.ActionFooter = function ActionFooter(_ref) {
|
|
|
60
61
|
}, /*#__PURE__*/_react.default.createElement(_primitives.Inline, {
|
|
61
62
|
alignBlock: "start",
|
|
62
63
|
grow: "fill",
|
|
63
|
-
space: "space.
|
|
64
|
+
space: "space.050"
|
|
64
65
|
}, message.icon || getIcon(message.appearance), /*#__PURE__*/_react.default.createElement(_primitives.Box, {
|
|
65
66
|
xcss: titleStyles
|
|
66
67
|
}, message.title))));
|
|
@@ -190,7 +190,7 @@ var HoverCardResolvedView = function HoverCardResolvedView(_ref2) {
|
|
|
190
190
|
aiSummaryMinHeight: connectedAIBlockHeight.current
|
|
191
191
|
}), isActionBlockEnabled && /*#__PURE__*/_react.default.createElement(_blocks.ActionBlock, {
|
|
192
192
|
onClick: onActionClick,
|
|
193
|
-
spaceInline: "space.
|
|
193
|
+
spaceInline: "space.100"
|
|
194
194
|
}), isActionBlockEnabled && /*#__PURE__*/_react.default.createElement(_blocks.FooterBlock, null), !isAISummaryEnabled && !isActionBlockEnabled && /*#__PURE__*/_react.default.createElement(_blocks.FooterBlock, {
|
|
195
195
|
actions: footerActions,
|
|
196
196
|
size: _constants.SmartLinkSize.Large,
|
|
@@ -17,7 +17,7 @@ var _excluded = ["href", "children", "checkSafety", "onClick", "testId"],
|
|
|
17
17
|
_excluded2 = ["isLinkSafe", "showSafetyWarningModal"];
|
|
18
18
|
var PACKAGE_DATA = {
|
|
19
19
|
packageName: "@atlaskit/smart-card",
|
|
20
|
-
packageVersion: "26.63.
|
|
20
|
+
packageVersion: "26.63.1",
|
|
21
21
|
componentName: 'linkUrl'
|
|
22
22
|
};
|
|
23
23
|
var Link = (0, _click.withLinkClickedEvent)('a');
|
|
@@ -29,8 +29,14 @@ export const useAISummary = props => {
|
|
|
29
29
|
succeedUfoExperience(EXPERIENCE_NAME, id);
|
|
30
30
|
}, [fireEvent]);
|
|
31
31
|
const onError = useCallback((id, reason) => {
|
|
32
|
+
/**
|
|
33
|
+
* Errors should only be counted to the SLO if they are not due to acceptable use violations
|
|
34
|
+
* or HIPAA content detected.
|
|
35
|
+
*/
|
|
36
|
+
const isSloError = reason !== "ACCEPTABLE_USE_VIOLATIONS" && reason !== "HIPAA_CONTENT_DETECTED";
|
|
32
37
|
fireEvent('operational.summary.failed', {
|
|
33
|
-
reason: reason || null
|
|
38
|
+
reason: reason || null,
|
|
39
|
+
isSloError
|
|
34
40
|
});
|
|
35
41
|
failUfoExperience(EXPERIENCE_NAME, id);
|
|
36
42
|
}, [fireEvent]);
|
|
@@ -4,7 +4,7 @@ export const ANALYTICS_CHANNEL = 'media';
|
|
|
4
4
|
export const context = {
|
|
5
5
|
componentName: 'smart-cards',
|
|
6
6
|
packageName: "@atlaskit/smart-card",
|
|
7
|
-
packageVersion: "26.63.
|
|
7
|
+
packageVersion: "26.63.1"
|
|
8
8
|
};
|
|
9
9
|
export let TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
10
10
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -6,8 +6,9 @@ const containerStyles = xcss({
|
|
|
6
6
|
all: 'unset',
|
|
7
7
|
borderRadius: 'border.radius',
|
|
8
8
|
margin: 'space.100',
|
|
9
|
+
marginBottom: 'space.0',
|
|
9
10
|
lineHeight: '20px',
|
|
10
|
-
padding: 'space.
|
|
11
|
+
padding: 'space.075',
|
|
11
12
|
paddingInline: 'space.100',
|
|
12
13
|
width: '100%',
|
|
13
14
|
':empty': {
|
|
@@ -54,7 +55,7 @@ export const ActionFooter = ({
|
|
|
54
55
|
}, /*#__PURE__*/React.createElement(Inline, {
|
|
55
56
|
alignBlock: "start",
|
|
56
57
|
grow: "fill",
|
|
57
|
-
space: "space.
|
|
58
|
+
space: "space.050"
|
|
58
59
|
}, message.icon || getIcon(message.appearance), /*#__PURE__*/React.createElement(Box, {
|
|
59
60
|
xcss: titleStyles
|
|
60
61
|
}, message.title))));
|
|
@@ -183,7 +183,7 @@ const HoverCardResolvedView = ({
|
|
|
183
183
|
aiSummaryMinHeight: connectedAIBlockHeight.current
|
|
184
184
|
}), isActionBlockEnabled && /*#__PURE__*/React.createElement(ActionBlock, {
|
|
185
185
|
onClick: onActionClick,
|
|
186
|
-
spaceInline: "space.
|
|
186
|
+
spaceInline: "space.100"
|
|
187
187
|
}), isActionBlockEnabled && /*#__PURE__*/React.createElement(FooterBlock, null), !isAISummaryEnabled && !isActionBlockEnabled && /*#__PURE__*/React.createElement(FooterBlock, {
|
|
188
188
|
actions: footerActions,
|
|
189
189
|
size: SmartLinkSize.Large,
|
|
@@ -7,7 +7,7 @@ import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-m
|
|
|
7
7
|
import LinkWarningModal from './LinkWarningModal';
|
|
8
8
|
const PACKAGE_DATA = {
|
|
9
9
|
packageName: "@atlaskit/smart-card",
|
|
10
|
-
packageVersion: "26.63.
|
|
10
|
+
packageVersion: "26.63.1",
|
|
11
11
|
componentName: 'linkUrl'
|
|
12
12
|
};
|
|
13
13
|
const Link = withLinkClickedEvent('a');
|
|
@@ -30,8 +30,14 @@ export var useAISummary = function useAISummary(props) {
|
|
|
30
30
|
succeedUfoExperience(EXPERIENCE_NAME, id);
|
|
31
31
|
}, [fireEvent]);
|
|
32
32
|
var onError = useCallback(function (id, reason) {
|
|
33
|
+
/**
|
|
34
|
+
* Errors should only be counted to the SLO if they are not due to acceptable use violations
|
|
35
|
+
* or HIPAA content detected.
|
|
36
|
+
*/
|
|
37
|
+
var isSloError = reason !== "ACCEPTABLE_USE_VIOLATIONS" && reason !== "HIPAA_CONTENT_DETECTED";
|
|
33
38
|
fireEvent('operational.summary.failed', {
|
|
34
|
-
reason: reason || null
|
|
39
|
+
reason: reason || null,
|
|
40
|
+
isSloError: isSloError
|
|
35
41
|
});
|
|
36
42
|
failUfoExperience(EXPERIENCE_NAME, id);
|
|
37
43
|
}, [fireEvent]);
|
|
@@ -15,7 +15,7 @@ export var ANALYTICS_CHANNEL = 'media';
|
|
|
15
15
|
export var context = {
|
|
16
16
|
componentName: 'smart-cards',
|
|
17
17
|
packageName: "@atlaskit/smart-card",
|
|
18
|
-
packageVersion: "26.63.
|
|
18
|
+
packageVersion: "26.63.1"
|
|
19
19
|
};
|
|
20
20
|
export var TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
|
|
21
21
|
TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
|
|
@@ -6,8 +6,9 @@ var containerStyles = xcss({
|
|
|
6
6
|
all: 'unset',
|
|
7
7
|
borderRadius: 'border.radius',
|
|
8
8
|
margin: 'space.100',
|
|
9
|
+
marginBottom: 'space.0',
|
|
9
10
|
lineHeight: '20px',
|
|
10
|
-
padding: 'space.
|
|
11
|
+
padding: 'space.075',
|
|
11
12
|
paddingInline: 'space.100',
|
|
12
13
|
width: '100%',
|
|
13
14
|
':empty': {
|
|
@@ -53,7 +54,7 @@ export var ActionFooter = function ActionFooter(_ref) {
|
|
|
53
54
|
}, /*#__PURE__*/React.createElement(Inline, {
|
|
54
55
|
alignBlock: "start",
|
|
55
56
|
grow: "fill",
|
|
56
|
-
space: "space.
|
|
57
|
+
space: "space.050"
|
|
57
58
|
}, message.icon || getIcon(message.appearance), /*#__PURE__*/React.createElement(Box, {
|
|
58
59
|
xcss: titleStyles
|
|
59
60
|
}, message.title))));
|
|
@@ -181,7 +181,7 @@ var HoverCardResolvedView = function HoverCardResolvedView(_ref2) {
|
|
|
181
181
|
aiSummaryMinHeight: connectedAIBlockHeight.current
|
|
182
182
|
}), isActionBlockEnabled && /*#__PURE__*/React.createElement(ActionBlock, {
|
|
183
183
|
onClick: onActionClick,
|
|
184
|
-
spaceInline: "space.
|
|
184
|
+
spaceInline: "space.100"
|
|
185
185
|
}), isActionBlockEnabled && /*#__PURE__*/React.createElement(FooterBlock, null), !isAISummaryEnabled && !isActionBlockEnabled && /*#__PURE__*/React.createElement(FooterBlock, {
|
|
186
186
|
actions: footerActions,
|
|
187
187
|
size: SmartLinkSize.Large,
|
|
@@ -10,7 +10,7 @@ import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-m
|
|
|
10
10
|
import LinkWarningModal from './LinkWarningModal';
|
|
11
11
|
var PACKAGE_DATA = {
|
|
12
12
|
packageName: "@atlaskit/smart-card",
|
|
13
|
-
packageVersion: "26.63.
|
|
13
|
+
packageVersion: "26.63.1",
|
|
14
14
|
componentName: 'linkUrl'
|
|
15
15
|
};
|
|
16
16
|
var Link = withLinkClickedEvent('a');
|
|
@@ -33,6 +33,10 @@ export type ErrorViewedAiSummaryAttributesType = {};
|
|
|
33
33
|
export type SummarySuccessAttributesType = {};
|
|
34
34
|
export type SummaryFailedAttributesType = {
|
|
35
35
|
reason: string | null;
|
|
36
|
+
/**
|
|
37
|
+
* True if the error should be counted towards the SLO.
|
|
38
|
+
*/
|
|
39
|
+
isSloError: boolean;
|
|
36
40
|
};
|
|
37
41
|
export type AiInteractionInitiatedAttributesType = {
|
|
38
42
|
aiFeatureName: string;
|
|
@@ -33,6 +33,10 @@ export type ErrorViewedAiSummaryAttributesType = {};
|
|
|
33
33
|
export type SummarySuccessAttributesType = {};
|
|
34
34
|
export type SummaryFailedAttributesType = {
|
|
35
35
|
reason: string | null;
|
|
36
|
+
/**
|
|
37
|
+
* True if the error should be counted towards the SLO.
|
|
38
|
+
*/
|
|
39
|
+
isSloError: boolean;
|
|
36
40
|
};
|
|
37
41
|
export type AiInteractionInitiatedAttributesType = {
|
|
38
42
|
aiFeatureName: string;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/smart-card",
|
|
3
|
-
"version": "26.63.
|
|
3
|
+
"version": "26.63.1",
|
|
4
4
|
"description": "Smart card component",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -55,7 +55,7 @@
|
|
|
55
55
|
"@atlaskit/primitives": "^6.1.0",
|
|
56
56
|
"@atlaskit/spinner": "^16.1.0",
|
|
57
57
|
"@atlaskit/theme": "^12.8.0",
|
|
58
|
-
"@atlaskit/tokens": "^1.
|
|
58
|
+
"@atlaskit/tokens": "^1.47.0",
|
|
59
59
|
"@atlaskit/tooltip": "^18.3.0",
|
|
60
60
|
"@atlaskit/ufo": "^0.2.0",
|
|
61
61
|
"@babel/runtime": "^7.0.0",
|