@atlaskit/smart-card 28.1.6 → 28.2.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.
Files changed (45) hide show
  1. package/CHANGELOG.md +23 -0
  2. package/dist/cjs/state/hooks/use-ai-summary/ai-summary-service/index.js +2 -9
  3. package/dist/cjs/state/hooks/use-ai-summary/ai-summary-service/types.js +19 -1
  4. package/dist/cjs/utils/actions/combine-action-options.js +1 -18
  5. package/dist/cjs/utils/analytics/analytics.js +1 -1
  6. package/dist/cjs/view/CardWithUrl/component.js +0 -4
  7. package/dist/cjs/view/CardWithUrl/loader.js +0 -4
  8. package/dist/cjs/view/FlexibleCard/components/blocks/ai-summary-block/feature-discovery/index.js +11 -2
  9. package/dist/cjs/view/HoverCard/components/HoverCardComponent.js +0 -2
  10. package/dist/cjs/view/LinkUrl/index.js +1 -1
  11. package/dist/es2019/state/hooks/use-ai-summary/ai-summary-service/index.js +3 -6
  12. package/dist/es2019/state/hooks/use-ai-summary/ai-summary-service/types.js +5 -0
  13. package/dist/es2019/utils/actions/combine-action-options.js +1 -18
  14. package/dist/es2019/utils/analytics/analytics.js +1 -1
  15. package/dist/es2019/view/CardWithUrl/component.js +0 -4
  16. package/dist/es2019/view/CardWithUrl/loader.js +0 -4
  17. package/dist/es2019/view/FlexibleCard/components/blocks/ai-summary-block/feature-discovery/index.js +13 -2
  18. package/dist/es2019/view/HoverCard/components/HoverCardComponent.js +0 -2
  19. package/dist/es2019/view/LinkUrl/index.js +1 -1
  20. package/dist/esm/state/hooks/use-ai-summary/ai-summary-service/index.js +3 -10
  21. package/dist/esm/state/hooks/use-ai-summary/ai-summary-service/types.js +17 -0
  22. package/dist/esm/utils/actions/combine-action-options.js +1 -18
  23. package/dist/esm/utils/analytics/analytics.js +1 -1
  24. package/dist/esm/view/CardWithUrl/component.js +0 -4
  25. package/dist/esm/view/CardWithUrl/loader.js +0 -4
  26. package/dist/esm/view/FlexibleCard/components/blocks/ai-summary-block/feature-discovery/index.js +11 -2
  27. package/dist/esm/view/HoverCard/components/HoverCardComponent.js +0 -2
  28. package/dist/esm/view/LinkUrl/index.js +1 -1
  29. package/dist/types/state/hooks/use-ai-summary/ai-summary-service/index.d.ts +0 -1
  30. package/dist/types/state/hooks/use-ai-summary/ai-summary-service/types.d.ts +4 -1
  31. package/dist/types/utils/actions/combine-action-options.d.ts +1 -3
  32. package/dist/types/utils/ai-summary.d.ts +1 -2
  33. package/dist/types/view/Card/types.d.ts +1 -0
  34. package/dist/types/view/FlexibleCard/components/actions/ai-summary-action/utils.d.ts +1 -2
  35. package/dist/types/view/HoverCard/components/CustomPopupContainer.d.ts +1 -1
  36. package/dist/types/view/HoverCard/components/HoverCardComponent.d.ts +1 -1
  37. package/dist/types-ts4.5/state/hooks/use-ai-summary/ai-summary-service/index.d.ts +0 -1
  38. package/dist/types-ts4.5/state/hooks/use-ai-summary/ai-summary-service/types.d.ts +4 -1
  39. package/dist/types-ts4.5/utils/actions/combine-action-options.d.ts +1 -3
  40. package/dist/types-ts4.5/utils/ai-summary.d.ts +1 -2
  41. package/dist/types-ts4.5/view/Card/types.d.ts +1 -0
  42. package/dist/types-ts4.5/view/FlexibleCard/components/actions/ai-summary-action/utils.d.ts +1 -2
  43. package/dist/types-ts4.5/view/HoverCard/components/CustomPopupContainer.d.ts +1 -1
  44. package/dist/types-ts4.5/view/HoverCard/components/HoverCardComponent.d.ts +1 -1
  45. package/package.json +8 -8
package/CHANGELOG.md CHANGED
@@ -1,5 +1,28 @@
1
1
  # @atlaskit/smart-card
2
2
 
3
+ ## 28.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#145026](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/145026)
8
+ [`98399b2cfafdc`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/98399b2cfafdc) -
9
+ Remove references to showActions and showServerActions
10
+
11
+ ### Patch Changes
12
+
13
+ - [#144894](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/144894)
14
+ [`c70fcb7df4d14`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/c70fcb7df4d14) -
15
+ Update AI summary errors to account for all messages sent by ConvoAI when streaming summary
16
+ content
17
+
18
+ ## 28.1.7
19
+
20
+ ### Patch Changes
21
+
22
+ - [#142271](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/pull-requests/142271)
23
+ [`b6147e8a87a2d`](https://stash.atlassian.com/projects/CONFCLOUD/repos/confluence-frontend/commits/b6147e8a87a2d) -
24
+ Add try/catch around localStorage usages
25
+
3
26
  ## 28.1.6
4
27
 
5
28
  ### Patch Changes
@@ -160,7 +160,7 @@ var AISummaryService = exports.AISummaryService = /*#__PURE__*/function () {
160
160
  _context2.next = 22;
161
161
  break;
162
162
  }
163
- throw new Error(chunk === null || chunk === void 0 || (_chunk$message = chunk.message) === null || _chunk$message === void 0 ? void 0 : _chunk$message.message_template);
163
+ throw new _types.ChunkProcessingError(chunk === null || chunk === void 0 || (_chunk$message = chunk.message) === null || _chunk$message === void 0 ? void 0 : _chunk$message.message_template);
164
164
  case 22:
165
165
  _iteratorAbruptCompletion = false;
166
166
  _context2.next = 14;
@@ -204,7 +204,7 @@ var AISummaryService = exports.AISummaryService = /*#__PURE__*/function () {
204
204
  case 45:
205
205
  _context2.prev = 45;
206
206
  _context2.t1 = _context2["catch"](4);
207
- message = _context2.t1 instanceof Error && this.isExpectedError(_context2.t1.message) ? _context2.t1.message : 'UNEXPECTED';
207
+ message = _context2.t1 instanceof _types.ChunkProcessingError ? _context2.t1.message : 'UNEXPECTED';
208
208
  (_this$onError = this.onError) === null || _this$onError === void 0 || _this$onError.call(this, id, message);
209
209
  this.state = {
210
210
  status: 'error',
@@ -235,13 +235,6 @@ var AISummaryService = exports.AISummaryService = /*#__PURE__*/function () {
235
235
  }
236
236
  return summariseUrl;
237
237
  }()
238
- }, {
239
- key: "isExpectedError",
240
- value: function isExpectedError(value) {
241
- return typeof value === 'string' && _types.errorMessages.some(function (a) {
242
- return a === value;
243
- });
244
- }
245
238
  }, {
246
239
  key: "subscribe",
247
240
  value: function subscribe(stateSetter) {
@@ -1,7 +1,25 @@
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
- exports.errorMessages = void 0;
7
+ exports.errorMessages = exports.ChunkProcessingError = void 0;
8
+ var _createClass2 = _interopRequireDefault(require("@babel/runtime/helpers/createClass"));
9
+ var _classCallCheck2 = _interopRequireDefault(require("@babel/runtime/helpers/classCallCheck"));
10
+ var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
11
+ var _possibleConstructorReturn2 = _interopRequireDefault(require("@babel/runtime/helpers/possibleConstructorReturn"));
12
+ var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/getPrototypeOf"));
13
+ var _wrapNativeSuper2 = _interopRequireDefault(require("@babel/runtime/helpers/wrapNativeSuper"));
14
+ function _createSuper(t) { var r = _isNativeReflectConstruct(); return function () { var e, o = (0, _getPrototypeOf2.default)(t); if (r) { var s = (0, _getPrototypeOf2.default)(this).constructor; e = Reflect.construct(o, arguments, s); } else e = o.apply(this, arguments); return (0, _possibleConstructorReturn2.default)(this, e); }; }
15
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
16
+ var ChunkProcessingError = exports.ChunkProcessingError = /*#__PURE__*/function (_Error) {
17
+ (0, _inherits2.default)(ChunkProcessingError, _Error);
18
+ var _super = _createSuper(ChunkProcessingError);
19
+ function ChunkProcessingError(error) {
20
+ (0, _classCallCheck2.default)(this, ChunkProcessingError);
21
+ return _super.call(this, error);
22
+ }
23
+ return (0, _createClass2.default)(ChunkProcessingError);
24
+ }( /*#__PURE__*/(0, _wrapNativeSuper2.default)(Error));
7
25
  var errorMessages = exports.errorMessages = ['NETWORK_ERROR', 'NO_ANSWER', 'RATE_LIMIT', 'NO_AGENT', 'PLUGIN_ERRORED', 'OPENAI_RATE_LIMIT_USER_ABUSE', 'ACCEPTABLE_USE_VIOLATIONS', 'AI_DISABLED', 'UNEXPECTED', 'HIPAA_CONTENT_DETECTED', 'EXCEEDING_CONTEXT_LENGTH_ERROR'];
@@ -9,14 +9,12 @@ var _toConsumableArray2 = _interopRequireDefault(require("@babel/runtime/helpers
9
9
  var _types = require("../../view/Card/types");
10
10
  var combineActionOptions = exports.combineActionOptions = function combineActionOptions(_ref) {
11
11
  var actionOptions = _ref.actionOptions,
12
- showServerActions = _ref.showServerActions,
13
- showActions = _ref.showActions,
14
12
  platform = _ref.platform,
15
13
  hidePreviewButton = _ref.hidePreviewButton;
16
14
  if (typeof actionOptions !== 'undefined') {
17
15
  return actionOptions;
18
16
  }
19
- if (platform === 'mobile' || showServerActions === false && showActions === false) {
17
+ if (platform === 'mobile') {
20
18
  return {
21
19
  hide: true
22
20
  };
@@ -25,21 +23,6 @@ var combineActionOptions = exports.combineActionOptions = function combineAction
25
23
  if (hidePreviewButton) {
26
24
  exclude = [].concat((0, _toConsumableArray2.default)(exclude), [_types.CardAction.PreviewAction]);
27
25
  }
28
- if (showServerActions && showActions) {
29
- return {
30
- hide: false,
31
- exclude: exclude
32
- };
33
- }
34
- if (showServerActions === false) {
35
- exclude = [].concat((0, _toConsumableArray2.default)(exclude), [_types.CardAction.FollowAction, _types.CardAction.ChangeStatusAction]);
36
- }
37
- if (showActions === false) {
38
- exclude = [].concat((0, _toConsumableArray2.default)(exclude), [_types.CardAction.DownloadAction, _types.CardAction.ViewAction]);
39
- if (!exclude.includes(_types.CardAction.PreviewAction)) {
40
- exclude.push(_types.CardAction.PreviewAction);
41
- }
42
- }
43
26
  return {
44
27
  hide: false,
45
28
  exclude: exclude
@@ -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: "28.1.6"
25
+ packageVersion: "28.2.0"
26
26
  };
27
27
  var TrackQuickActionType = exports.TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
28
28
  TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
@@ -38,8 +38,6 @@ function Component(_ref) {
38
38
  onResolve = _ref.onResolve,
39
39
  onError = _ref.onError,
40
40
  testId = _ref.testId,
41
- showActions = _ref.showActions,
42
- showServerActions = _ref.showServerActions,
43
41
  actionOptionsProp = _ref.actionOptions,
44
42
  inheritDimensions = _ref.inheritDimensions,
45
43
  embedIframeRef = _ref.embedIframeRef,
@@ -78,8 +76,6 @@ function Component(_ref) {
78
76
  }, [children]);
79
77
  var actionOptions = (0, _combineActionOptions.combineActionOptions)({
80
78
  actionOptions: actionOptionsProp,
81
- showServerActions: showServerActions,
82
- showActions: showActions,
83
79
  platform: platform
84
80
  });
85
81
  var frameStyle = (0, _utils.combineFrameStyle)(frameStyleProp, isFrameVisible);
@@ -50,8 +50,6 @@ function CardWithURLRenderer(props) {
50
50
  onResolve = props.onResolve,
51
51
  onError = props.onError,
52
52
  testId = props.testId,
53
- showActions = props.showActions,
54
- showServerActions = props.showServerActions,
55
53
  actionOptions = props.actionOptions,
56
54
  inheritDimensions = props.inheritDimensions,
57
55
  platform = props.platform,
@@ -124,8 +122,6 @@ function CardWithURLRenderer(props) {
124
122
  onResolve: onResolve,
125
123
  onError: onError,
126
124
  testId: testId,
127
- showActions: showActions,
128
- showServerActions: showServerActions,
129
125
  actionOptions: actionOptions,
130
126
  inheritDimensions: inheritDimensions,
131
127
  platform: platform,
@@ -32,7 +32,12 @@ var FeatureDiscovery = function FeatureDiscovery(_ref) {
32
32
  return new _storageClient.StorageClient(LOCAL_STORAGE_CLIENT_KEY);
33
33
  }, []);
34
34
  var discovered = (0, _react2.useMemo)(function () {
35
- return storageClient.getItem(LOCAL_STORAGE_DISCOVERY_KEY) === LOCAL_STORAGE_DISCOVERY_VALUE;
35
+ try {
36
+ return storageClient.getItem(LOCAL_STORAGE_DISCOVERY_KEY) === LOCAL_STORAGE_DISCOVERY_VALUE;
37
+ } catch (_unused) {
38
+ // If localStorage is not available, don't show feature discovery component. Treat it as 'discovered'.
39
+ return true;
40
+ }
36
41
  }, [storageClient]);
37
42
  (0, _react2.useEffect)(function () {
38
43
  renderedTime.current = Date.now();
@@ -40,7 +45,11 @@ var FeatureDiscovery = function FeatureDiscovery(_ref) {
40
45
  if (!discovered && renderedTime.current) {
41
46
  var duration = Date.now() - renderedTime.current;
42
47
  if (duration > LOCAL_STORAGE_DISCOVERY_REQUIRED_TIME) {
43
- storageClient.setItemWithExpiry(LOCAL_STORAGE_DISCOVERY_KEY, LOCAL_STORAGE_DISCOVERY_VALUE, LOCAL_STORAGE_DISCOVERY_EXPIRY_IN_MS);
48
+ try {
49
+ storageClient.setItemWithExpiry(LOCAL_STORAGE_DISCOVERY_KEY, LOCAL_STORAGE_DISCOVERY_VALUE, LOCAL_STORAGE_DISCOVERY_EXPIRY_IN_MS);
50
+ } catch (_unused2) {
51
+ // silent error
52
+ }
44
53
  }
45
54
  }
46
55
  };
@@ -48,7 +48,6 @@ var HoverCardComponent = exports.HoverCardComponent = function HoverCardComponen
48
48
  closeOnChildClick = _ref$closeOnChildClic === void 0 ? false : _ref$closeOnChildClic,
49
49
  _ref$hidePreviewButto = _ref.hidePreviewButton,
50
50
  hidePreviewButton = _ref$hidePreviewButto === void 0 ? false : _ref$hidePreviewButto,
51
- showServerActions = _ref.showServerActions,
52
51
  actionOptionsProp = _ref.actionOptions,
53
52
  _ref$allowEventPropag = _ref.allowEventPropagation,
54
53
  allowEventPropagation = _ref$allowEventPropag === void 0 ? false : _ref$allowEventPropag,
@@ -75,7 +74,6 @@ var HoverCardComponent = exports.HoverCardComponent = function HoverCardComponen
75
74
  loadMetadata = _useSmartCardActions.loadMetadata;
76
75
  var actionOptions = (0, _combineActionOptions.combineActionOptions)({
77
76
  actionOptions: actionOptionsProp,
78
- showServerActions: showServerActions,
79
77
  hidePreviewButton: hidePreviewButton
80
78
  });
81
79
  var setMousePosition = (0, _react2.useCallback)(function (event) {
@@ -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: "28.1.6",
20
+ packageVersion: "28.2.0",
21
21
  componentName: 'linkUrl'
22
22
  };
23
23
  var Link = (0, _click.withLinkClickedEvent)('a');
@@ -1,6 +1,6 @@
1
1
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
2
2
  import uuid from 'uuid';
3
- import { errorMessages } from './types';
3
+ import { ChunkProcessingError } from './types';
4
4
  import { addPath, getXProductHeaderValue } from './utils';
5
5
  import { readStream } from './readStream';
6
6
  import { getBaseUrl } from '@atlaskit/linking-common';
@@ -88,7 +88,7 @@ export class AISummaryService {
88
88
  }
89
89
  if (chunk.type === 'ERROR') {
90
90
  var _chunk$message;
91
- throw new Error(chunk === null || chunk === void 0 ? void 0 : (_chunk$message = chunk.message) === null || _chunk$message === void 0 ? void 0 : _chunk$message.message_template);
91
+ throw new ChunkProcessingError(chunk === null || chunk === void 0 ? void 0 : (_chunk$message = chunk.message) === null || _chunk$message === void 0 ? void 0 : _chunk$message.message_template);
92
92
  }
93
93
  }
94
94
  (_this$onSuccess = this.onSuccess) === null || _this$onSuccess === void 0 ? void 0 : _this$onSuccess.call(this, id);
@@ -98,7 +98,7 @@ export class AISummaryService {
98
98
  };
99
99
  } catch (err) {
100
100
  var _this$onError;
101
- let message = err instanceof Error && this.isExpectedError(err.message) ? err.message : 'UNEXPECTED';
101
+ let message = err instanceof ChunkProcessingError ? err.message : 'UNEXPECTED';
102
102
  (_this$onError = this.onError) === null || _this$onError === void 0 ? void 0 : _this$onError.call(this, id, message);
103
103
  this.state = {
104
104
  status: 'error',
@@ -111,9 +111,6 @@ export class AISummaryService {
111
111
  }
112
112
  return this.state;
113
113
  }
114
- isExpectedError(value) {
115
- return typeof value === 'string' && errorMessages.some(a => a === value);
116
- }
117
114
  subscribe(stateSetter) {
118
115
  this.subscribedStateSetters.add(stateSetter);
119
116
  return () => {
@@ -1 +1,6 @@
1
+ export class ChunkProcessingError extends Error {
2
+ constructor(error) {
3
+ super(error);
4
+ }
5
+ }
1
6
  export const errorMessages = ['NETWORK_ERROR', 'NO_ANSWER', 'RATE_LIMIT', 'NO_AGENT', 'PLUGIN_ERRORED', 'OPENAI_RATE_LIMIT_USER_ABUSE', 'ACCEPTABLE_USE_VIOLATIONS', 'AI_DISABLED', 'UNEXPECTED', 'HIPAA_CONTENT_DETECTED', 'EXCEEDING_CONTEXT_LENGTH_ERROR'];
@@ -1,15 +1,13 @@
1
1
  import { CardAction } from '../../view/Card/types';
2
2
  export const combineActionOptions = ({
3
3
  actionOptions,
4
- showServerActions,
5
- showActions,
6
4
  platform,
7
5
  hidePreviewButton
8
6
  }) => {
9
7
  if (typeof actionOptions !== 'undefined') {
10
8
  return actionOptions;
11
9
  }
12
- if (platform === 'mobile' || showServerActions === false && showActions === false) {
10
+ if (platform === 'mobile') {
13
11
  return {
14
12
  hide: true
15
13
  };
@@ -18,21 +16,6 @@ export const combineActionOptions = ({
18
16
  if (hidePreviewButton) {
19
17
  exclude = [...exclude, CardAction.PreviewAction];
20
18
  }
21
- if (showServerActions && showActions) {
22
- return {
23
- hide: false,
24
- exclude
25
- };
26
- }
27
- if (showServerActions === false) {
28
- exclude = [...exclude, CardAction.FollowAction, CardAction.ChangeStatusAction];
29
- }
30
- if (showActions === false) {
31
- exclude = [...exclude, CardAction.DownloadAction, CardAction.ViewAction];
32
- if (!exclude.includes(CardAction.PreviewAction)) {
33
- exclude.push(CardAction.PreviewAction);
34
- }
35
- }
36
19
  return {
37
20
  hide: false,
38
21
  exclude
@@ -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: "28.1.6"
7
+ packageVersion: "28.2.0"
8
8
  };
9
9
  export let TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
10
10
  TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
@@ -28,8 +28,6 @@ function Component({
28
28
  onResolve,
29
29
  onError,
30
30
  testId,
31
- showActions,
32
- showServerActions,
33
31
  actionOptions: actionOptionsProp,
34
32
  inheritDimensions,
35
33
  embedIframeRef,
@@ -69,8 +67,6 @@ function Component({
69
67
  let isFlexibleUi = useMemo(() => isFlexibleUiCard(children), [children]);
70
68
  const actionOptions = combineActionOptions({
71
69
  actionOptions: actionOptionsProp,
72
- showServerActions,
73
- showActions,
74
70
  platform
75
71
  });
76
72
  const frameStyle = combineFrameStyle(frameStyleProp, isFrameVisible);
@@ -29,8 +29,6 @@ export function CardWithURLRenderer(props) {
29
29
  onResolve,
30
30
  onError,
31
31
  testId,
32
- showActions,
33
- showServerActions,
34
32
  actionOptions,
35
33
  inheritDimensions,
36
34
  platform,
@@ -102,8 +100,6 @@ export function CardWithURLRenderer(props) {
102
100
  onResolve,
103
101
  onError,
104
102
  testId,
105
- showActions,
106
- showServerActions,
107
103
  actionOptions,
108
104
  inheritDimensions,
109
105
  platform,
@@ -23,14 +23,25 @@ const FeatureDiscovery = ({
23
23
  }) => {
24
24
  const renderedTime = useRef();
25
25
  const storageClient = useMemo(() => new StorageClient(LOCAL_STORAGE_CLIENT_KEY), []);
26
- const discovered = useMemo(() => storageClient.getItem(LOCAL_STORAGE_DISCOVERY_KEY) === LOCAL_STORAGE_DISCOVERY_VALUE, [storageClient]);
26
+ const discovered = useMemo(() => {
27
+ try {
28
+ return storageClient.getItem(LOCAL_STORAGE_DISCOVERY_KEY) === LOCAL_STORAGE_DISCOVERY_VALUE;
29
+ } catch {
30
+ // If localStorage is not available, don't show feature discovery component. Treat it as 'discovered'.
31
+ return true;
32
+ }
33
+ }, [storageClient]);
27
34
  useEffect(() => {
28
35
  renderedTime.current = Date.now();
29
36
  return () => {
30
37
  if (!discovered && renderedTime.current) {
31
38
  const duration = Date.now() - renderedTime.current;
32
39
  if (duration > LOCAL_STORAGE_DISCOVERY_REQUIRED_TIME) {
33
- storageClient.setItemWithExpiry(LOCAL_STORAGE_DISCOVERY_KEY, LOCAL_STORAGE_DISCOVERY_VALUE, LOCAL_STORAGE_DISCOVERY_EXPIRY_IN_MS);
40
+ try {
41
+ storageClient.setItemWithExpiry(LOCAL_STORAGE_DISCOVERY_KEY, LOCAL_STORAGE_DISCOVERY_VALUE, LOCAL_STORAGE_DISCOVERY_EXPIRY_IN_MS);
42
+ } catch {
43
+ // silent error
44
+ }
34
45
  }
35
46
  }
36
47
  };
@@ -30,7 +30,6 @@ export const HoverCardComponent = ({
30
30
  canOpen = true,
31
31
  closeOnChildClick = false,
32
32
  hidePreviewButton = false,
33
- showServerActions,
34
33
  actionOptions: actionOptionsProp,
35
34
  allowEventPropagation = false,
36
35
  zIndex = HOVER_CARD_Z_INDEX,
@@ -54,7 +53,6 @@ export const HoverCardComponent = ({
54
53
  } = useSmartCardActions(id, url, analytics);
55
54
  const actionOptions = combineActionOptions({
56
55
  actionOptions: actionOptionsProp,
57
- showServerActions,
58
56
  hidePreviewButton
59
57
  });
60
58
  const setMousePosition = useCallback(event => {
@@ -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: "28.1.6",
10
+ packageVersion: "28.2.0",
11
11
  componentName: 'linkUrl'
12
12
  };
13
13
  const Link = withLinkClickedEvent('a');
@@ -11,7 +11,7 @@ import _regeneratorRuntime from "@babel/runtime/regenerator";
11
11
  function _asyncIterator(r) { var n, t, o, e = 2; for ("undefined" != typeof Symbol && (t = Symbol.asyncIterator, o = Symbol.iterator); e--;) { if (t && null != (n = r[t])) return n.call(r); if (o && null != (n = r[o])) return new AsyncFromSyncIterator(n.call(r)); t = "@@asyncIterator", o = "@@iterator"; } throw new TypeError("Object is not async iterable"); }
12
12
  function AsyncFromSyncIterator(r) { function AsyncFromSyncIteratorContinuation(r) { if (Object(r) !== r) return Promise.reject(new TypeError(r + " is not an object.")); var n = r.done; return Promise.resolve(r.value).then(function (r) { return { value: r, done: n }; }); } return AsyncFromSyncIterator = function AsyncFromSyncIterator(r) { this.s = r, this.n = r.next; }, AsyncFromSyncIterator.prototype = { s: null, n: null, next: function next() { return AsyncFromSyncIteratorContinuation(this.n.apply(this.s, arguments)); }, return: function _return(r) { var n = this.s.return; return void 0 === n ? Promise.resolve({ value: r, done: !0 }) : AsyncFromSyncIteratorContinuation(n.apply(this.s, arguments)); }, throw: function _throw(r) { var n = this.s.return; return void 0 === n ? Promise.reject(r) : AsyncFromSyncIteratorContinuation(n.apply(this.s, arguments)); } }, new AsyncFromSyncIterator(r); }
13
13
  import uuid from 'uuid';
14
- import { errorMessages } from './types';
14
+ import { ChunkProcessingError } from './types';
15
15
  import { addPath, getXProductHeaderValue } from './utils';
16
16
  import { readStream } from './readStream';
17
17
  import { getBaseUrl } from '@atlaskit/linking-common';
@@ -153,7 +153,7 @@ export var AISummaryService = /*#__PURE__*/function () {
153
153
  _context2.next = 22;
154
154
  break;
155
155
  }
156
- throw new Error(chunk === null || chunk === void 0 || (_chunk$message = chunk.message) === null || _chunk$message === void 0 ? void 0 : _chunk$message.message_template);
156
+ throw new ChunkProcessingError(chunk === null || chunk === void 0 || (_chunk$message = chunk.message) === null || _chunk$message === void 0 ? void 0 : _chunk$message.message_template);
157
157
  case 22:
158
158
  _iteratorAbruptCompletion = false;
159
159
  _context2.next = 14;
@@ -197,7 +197,7 @@ export var AISummaryService = /*#__PURE__*/function () {
197
197
  case 45:
198
198
  _context2.prev = 45;
199
199
  _context2.t1 = _context2["catch"](4);
200
- message = _context2.t1 instanceof Error && this.isExpectedError(_context2.t1.message) ? _context2.t1.message : 'UNEXPECTED';
200
+ message = _context2.t1 instanceof ChunkProcessingError ? _context2.t1.message : 'UNEXPECTED';
201
201
  (_this$onError = this.onError) === null || _this$onError === void 0 || _this$onError.call(this, id, message);
202
202
  this.state = {
203
203
  status: 'error',
@@ -228,13 +228,6 @@ export var AISummaryService = /*#__PURE__*/function () {
228
228
  }
229
229
  return summariseUrl;
230
230
  }()
231
- }, {
232
- key: "isExpectedError",
233
- value: function isExpectedError(value) {
234
- return typeof value === 'string' && errorMessages.some(function (a) {
235
- return a === value;
236
- });
237
- }
238
231
  }, {
239
232
  key: "subscribe",
240
233
  value: function subscribe(stateSetter) {
@@ -1 +1,18 @@
1
+ import _createClass from "@babel/runtime/helpers/createClass";
2
+ import _classCallCheck from "@babel/runtime/helpers/classCallCheck";
3
+ import _inherits from "@babel/runtime/helpers/inherits";
4
+ import _possibleConstructorReturn from "@babel/runtime/helpers/possibleConstructorReturn";
5
+ import _getPrototypeOf from "@babel/runtime/helpers/getPrototypeOf";
6
+ import _wrapNativeSuper from "@babel/runtime/helpers/wrapNativeSuper";
7
+ function _createSuper(t) { var r = _isNativeReflectConstruct(); return function () { var e, o = _getPrototypeOf(t); if (r) { var s = _getPrototypeOf(this).constructor; e = Reflect.construct(o, arguments, s); } else e = o.apply(this, arguments); return _possibleConstructorReturn(this, e); }; }
8
+ function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
9
+ export var ChunkProcessingError = /*#__PURE__*/function (_Error) {
10
+ _inherits(ChunkProcessingError, _Error);
11
+ var _super = _createSuper(ChunkProcessingError);
12
+ function ChunkProcessingError(error) {
13
+ _classCallCheck(this, ChunkProcessingError);
14
+ return _super.call(this, error);
15
+ }
16
+ return _createClass(ChunkProcessingError);
17
+ }( /*#__PURE__*/_wrapNativeSuper(Error));
1
18
  export var errorMessages = ['NETWORK_ERROR', 'NO_ANSWER', 'RATE_LIMIT', 'NO_AGENT', 'PLUGIN_ERRORED', 'OPENAI_RATE_LIMIT_USER_ABUSE', 'ACCEPTABLE_USE_VIOLATIONS', 'AI_DISABLED', 'UNEXPECTED', 'HIPAA_CONTENT_DETECTED', 'EXCEEDING_CONTEXT_LENGTH_ERROR'];
@@ -2,14 +2,12 @@ import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
2
2
  import { CardAction } from '../../view/Card/types';
3
3
  export var combineActionOptions = function combineActionOptions(_ref) {
4
4
  var actionOptions = _ref.actionOptions,
5
- showServerActions = _ref.showServerActions,
6
- showActions = _ref.showActions,
7
5
  platform = _ref.platform,
8
6
  hidePreviewButton = _ref.hidePreviewButton;
9
7
  if (typeof actionOptions !== 'undefined') {
10
8
  return actionOptions;
11
9
  }
12
- if (platform === 'mobile' || showServerActions === false && showActions === false) {
10
+ if (platform === 'mobile') {
13
11
  return {
14
12
  hide: true
15
13
  };
@@ -18,21 +16,6 @@ export var combineActionOptions = function combineActionOptions(_ref) {
18
16
  if (hidePreviewButton) {
19
17
  exclude = [].concat(_toConsumableArray(exclude), [CardAction.PreviewAction]);
20
18
  }
21
- if (showServerActions && showActions) {
22
- return {
23
- hide: false,
24
- exclude: exclude
25
- };
26
- }
27
- if (showServerActions === false) {
28
- exclude = [].concat(_toConsumableArray(exclude), [CardAction.FollowAction, CardAction.ChangeStatusAction]);
29
- }
30
- if (showActions === false) {
31
- exclude = [].concat(_toConsumableArray(exclude), [CardAction.DownloadAction, CardAction.ViewAction]);
32
- if (!exclude.includes(CardAction.PreviewAction)) {
33
- exclude.push(CardAction.PreviewAction);
34
- }
35
- }
36
19
  return {
37
20
  hide: false,
38
21
  exclude: exclude
@@ -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: "28.1.6"
18
+ packageVersion: "28.2.0"
19
19
  };
20
20
  export var TrackQuickActionType = /*#__PURE__*/function (TrackQuickActionType) {
21
21
  TrackQuickActionType["StatusUpdate"] = "StatusUpdate";
@@ -28,8 +28,6 @@ function Component(_ref) {
28
28
  onResolve = _ref.onResolve,
29
29
  onError = _ref.onError,
30
30
  testId = _ref.testId,
31
- showActions = _ref.showActions,
32
- showServerActions = _ref.showServerActions,
33
31
  actionOptionsProp = _ref.actionOptions,
34
32
  inheritDimensions = _ref.inheritDimensions,
35
33
  embedIframeRef = _ref.embedIframeRef,
@@ -68,8 +66,6 @@ function Component(_ref) {
68
66
  }, [children]);
69
67
  var actionOptions = combineActionOptions({
70
68
  actionOptions: actionOptionsProp,
71
- showServerActions: showServerActions,
72
- showActions: showActions,
73
69
  platform: platform
74
70
  });
75
71
  var frameStyle = combineFrameStyle(frameStyleProp, isFrameVisible);
@@ -37,8 +37,6 @@ export function CardWithURLRenderer(props) {
37
37
  onResolve = props.onResolve,
38
38
  onError = props.onError,
39
39
  testId = props.testId,
40
- showActions = props.showActions,
41
- showServerActions = props.showServerActions,
42
40
  actionOptions = props.actionOptions,
43
41
  inheritDimensions = props.inheritDimensions,
44
42
  platform = props.platform,
@@ -111,8 +109,6 @@ export function CardWithURLRenderer(props) {
111
109
  onResolve: onResolve,
112
110
  onError: onError,
113
111
  testId: testId,
114
- showActions: showActions,
115
- showServerActions: showServerActions,
116
112
  actionOptions: actionOptions,
117
113
  inheritDimensions: inheritDimensions,
118
114
  platform: platform,
@@ -25,7 +25,12 @@ var FeatureDiscovery = function FeatureDiscovery(_ref) {
25
25
  return new StorageClient(LOCAL_STORAGE_CLIENT_KEY);
26
26
  }, []);
27
27
  var discovered = useMemo(function () {
28
- return storageClient.getItem(LOCAL_STORAGE_DISCOVERY_KEY) === LOCAL_STORAGE_DISCOVERY_VALUE;
28
+ try {
29
+ return storageClient.getItem(LOCAL_STORAGE_DISCOVERY_KEY) === LOCAL_STORAGE_DISCOVERY_VALUE;
30
+ } catch (_unused) {
31
+ // If localStorage is not available, don't show feature discovery component. Treat it as 'discovered'.
32
+ return true;
33
+ }
29
34
  }, [storageClient]);
30
35
  useEffect(function () {
31
36
  renderedTime.current = Date.now();
@@ -33,7 +38,11 @@ var FeatureDiscovery = function FeatureDiscovery(_ref) {
33
38
  if (!discovered && renderedTime.current) {
34
39
  var duration = Date.now() - renderedTime.current;
35
40
  if (duration > LOCAL_STORAGE_DISCOVERY_REQUIRED_TIME) {
36
- storageClient.setItemWithExpiry(LOCAL_STORAGE_DISCOVERY_KEY, LOCAL_STORAGE_DISCOVERY_VALUE, LOCAL_STORAGE_DISCOVERY_EXPIRY_IN_MS);
41
+ try {
42
+ storageClient.setItemWithExpiry(LOCAL_STORAGE_DISCOVERY_KEY, LOCAL_STORAGE_DISCOVERY_VALUE, LOCAL_STORAGE_DISCOVERY_EXPIRY_IN_MS);
43
+ } catch (_unused2) {
44
+ // silent error
45
+ }
37
46
  }
38
47
  }
39
48
  };
@@ -36,7 +36,6 @@ export var HoverCardComponent = function HoverCardComponent(_ref) {
36
36
  closeOnChildClick = _ref$closeOnChildClic === void 0 ? false : _ref$closeOnChildClic,
37
37
  _ref$hidePreviewButto = _ref.hidePreviewButton,
38
38
  hidePreviewButton = _ref$hidePreviewButto === void 0 ? false : _ref$hidePreviewButto,
39
- showServerActions = _ref.showServerActions,
40
39
  actionOptionsProp = _ref.actionOptions,
41
40
  _ref$allowEventPropag = _ref.allowEventPropagation,
42
41
  allowEventPropagation = _ref$allowEventPropag === void 0 ? false : _ref$allowEventPropag,
@@ -63,7 +62,6 @@ export var HoverCardComponent = function HoverCardComponent(_ref) {
63
62
  loadMetadata = _useSmartCardActions.loadMetadata;
64
63
  var actionOptions = combineActionOptions({
65
64
  actionOptions: actionOptionsProp,
66
- showServerActions: showServerActions,
67
65
  hidePreviewButton: hidePreviewButton
68
66
  });
69
67
  var setMousePosition = useCallback(function (event) {
@@ -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: "28.1.6",
13
+ packageVersion: "28.2.0",
14
14
  componentName: 'linkUrl'
15
15
  };
16
16
  var Link = withLinkClickedEvent('a');
@@ -12,6 +12,5 @@ export declare class AISummaryService implements AISummaryServiceInt {
12
12
  private getRequestUrl;
13
13
  private fetchStream;
14
14
  summariseUrl(): Promise<AISummaryState>;
15
- private isExpectedError;
16
15
  subscribe(stateSetter: StateSetter): () => void;
17
16
  }
@@ -4,6 +4,9 @@ export interface AISummaryServiceInt {
4
4
  state: AISummaryState;
5
5
  subscribe: (stateSetter: StateSetter) => () => void;
6
6
  }
7
+ export declare class ChunkProcessingError extends Error {
8
+ constructor(error: any);
9
+ }
7
10
  export type AISummaryServiceProps = {
8
11
  baseUrl?: string;
9
12
  onError?: (id: string, reason?: string) => void;
@@ -40,7 +43,7 @@ export type ErrorMessage = (typeof errorMessages)[number];
40
43
  export type AISummaryState = {
41
44
  content: string;
42
45
  status: AISummaryStatus;
43
- error?: ErrorMessage;
46
+ error?: string;
44
47
  };
45
48
  export type StateSetter = (state: AISummaryState) => any;
46
49
  export type StreamMessage = StreamTrace | StreamAnswerPart | StreamResponse | StreamError;
@@ -1,10 +1,8 @@
1
1
  import { type CardActionOptions, type CardPlatform } from '../../view/Card/types';
2
2
  type CombineActionsOptions = {
3
3
  actionOptions?: CardActionOptions;
4
- showServerActions?: boolean;
5
- showActions?: boolean;
6
4
  platform?: CardPlatform;
7
5
  hidePreviewButton?: boolean;
8
6
  };
9
- export declare const combineActionOptions: ({ actionOptions, showServerActions, showActions, platform, hidePreviewButton, }: CombineActionsOptions) => CardActionOptions;
7
+ export declare const combineActionOptions: ({ actionOptions, platform, hidePreviewButton, }: CombineActionsOptions) => CardActionOptions;
10
8
  export {};
@@ -1,8 +1,7 @@
1
1
  import type { JsonLd } from 'json-ld-types';
2
2
  import type { MessageDescriptor } from 'react-intl-next';
3
- import type { ErrorMessage } from '../state/hooks/use-ai-summary/ai-summary-service/types';
4
3
  export declare const getIsAISummaryEnabled: (isAdminHubAIEnabled?: boolean, response?: JsonLd.Response) => boolean;
5
- export declare const getAISummaryErrorMessage: (error?: ErrorMessage) => {
4
+ export declare const getAISummaryErrorMessage: (error?: string) => {
6
5
  message: MessageDescriptor;
7
6
  url?: string;
8
7
  };
@@ -107,6 +107,7 @@ export interface CardProps extends WithAnalyticsEventsProps {
107
107
  analyticsEvents?: AnalyticsFacade;
108
108
  placeholder?: string;
109
109
  /**
110
+ * @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-15021 Internal documentation for deprecation (no external access)}
110
111
  * When enabled the legacy block card is always used, even if the enableFlexibleBlockCard flag is set to true.
111
112
  * Usage is strongly discouraged. This should only be used if there is a specific reason you're
112
113
  * unable to use the new flexible block cards.
@@ -1,3 +1,2 @@
1
- import { type ErrorMessage } from '../../../../../state/hooks/use-ai-summary/ai-summary-service/types';
2
1
  import type { ActionMessage } from '../action/types';
3
- export declare const getErrorMessage: (error?: ErrorMessage) => ActionMessage;
2
+ export declare const getErrorMessage: (error?: string) => ActionMessage;
@@ -9,5 +9,5 @@ import { type PopupComponentProps } from '@atlaskit/popup';
9
9
  * HoverCard border implementation is in ContentContainer where it can
10
10
  * change between the default border and prism border during runtime.
11
11
  */
12
- declare const CustomPopupContainer: React.ForwardRefExoticComponent<Pick<PopupComponentProps, "children" | "style" | "id" | "tabIndex" | "role" | "data-testid" | "shouldFitContainer" | "shouldRenderToParent" | "data-placement"> & React.RefAttributes<HTMLDivElement>>;
12
+ declare const CustomPopupContainer: React.ForwardRefExoticComponent<Pick<PopupComponentProps, "appearance" | "children" | "style" | "id" | "tabIndex" | "role" | "data-testid" | "shouldFitContainer" | "shouldRenderToParent" | "xcss" | "data-placement"> & React.RefAttributes<HTMLDivElement>>;
13
13
  export default CustomPopupContainer;
@@ -1,3 +1,3 @@
1
1
  import { jsx } from '@emotion/react';
2
2
  import { type HoverCardComponentProps } from '../types';
3
- export declare const HoverCardComponent: ({ children, url, id, analyticsHandler, canOpen, closeOnChildClick, hidePreviewButton, showServerActions, actionOptions: actionOptionsProp, allowEventPropagation, zIndex, noFadeDelay, hoverPreviewOptions, }: HoverCardComponentProps) => jsx.JSX.Element;
3
+ export declare const HoverCardComponent: ({ children, url, id, analyticsHandler, canOpen, closeOnChildClick, hidePreviewButton, actionOptions: actionOptionsProp, allowEventPropagation, zIndex, noFadeDelay, hoverPreviewOptions, }: HoverCardComponentProps) => jsx.JSX.Element;
@@ -12,6 +12,5 @@ export declare class AISummaryService implements AISummaryServiceInt {
12
12
  private getRequestUrl;
13
13
  private fetchStream;
14
14
  summariseUrl(): Promise<AISummaryState>;
15
- private isExpectedError;
16
15
  subscribe(stateSetter: StateSetter): () => void;
17
16
  }
@@ -4,6 +4,9 @@ export interface AISummaryServiceInt {
4
4
  state: AISummaryState;
5
5
  subscribe: (stateSetter: StateSetter) => () => void;
6
6
  }
7
+ export declare class ChunkProcessingError extends Error {
8
+ constructor(error: any);
9
+ }
7
10
  export type AISummaryServiceProps = {
8
11
  baseUrl?: string;
9
12
  onError?: (id: string, reason?: string) => void;
@@ -52,7 +55,7 @@ export type ErrorMessage = (typeof errorMessages)[number];
52
55
  export type AISummaryState = {
53
56
  content: string;
54
57
  status: AISummaryStatus;
55
- error?: ErrorMessage;
58
+ error?: string;
56
59
  };
57
60
  export type StateSetter = (state: AISummaryState) => any;
58
61
  export type StreamMessage = StreamTrace | StreamAnswerPart | StreamResponse | StreamError;
@@ -1,10 +1,8 @@
1
1
  import { type CardActionOptions, type CardPlatform } from '../../view/Card/types';
2
2
  type CombineActionsOptions = {
3
3
  actionOptions?: CardActionOptions;
4
- showServerActions?: boolean;
5
- showActions?: boolean;
6
4
  platform?: CardPlatform;
7
5
  hidePreviewButton?: boolean;
8
6
  };
9
- export declare const combineActionOptions: ({ actionOptions, showServerActions, showActions, platform, hidePreviewButton, }: CombineActionsOptions) => CardActionOptions;
7
+ export declare const combineActionOptions: ({ actionOptions, platform, hidePreviewButton, }: CombineActionsOptions) => CardActionOptions;
10
8
  export {};
@@ -1,8 +1,7 @@
1
1
  import type { JsonLd } from 'json-ld-types';
2
2
  import type { MessageDescriptor } from 'react-intl-next';
3
- import type { ErrorMessage } from '../state/hooks/use-ai-summary/ai-summary-service/types';
4
3
  export declare const getIsAISummaryEnabled: (isAdminHubAIEnabled?: boolean, response?: JsonLd.Response) => boolean;
5
- export declare const getAISummaryErrorMessage: (error?: ErrorMessage) => {
4
+ export declare const getAISummaryErrorMessage: (error?: string) => {
6
5
  message: MessageDescriptor;
7
6
  url?: string;
8
7
  };
@@ -107,6 +107,7 @@ export interface CardProps extends WithAnalyticsEventsProps {
107
107
  analyticsEvents?: AnalyticsFacade;
108
108
  placeholder?: string;
109
109
  /**
110
+ * @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-15021 Internal documentation for deprecation (no external access)}
110
111
  * When enabled the legacy block card is always used, even if the enableFlexibleBlockCard flag is set to true.
111
112
  * Usage is strongly discouraged. This should only be used if there is a specific reason you're
112
113
  * unable to use the new flexible block cards.
@@ -1,3 +1,2 @@
1
- import { type ErrorMessage } from '../../../../../state/hooks/use-ai-summary/ai-summary-service/types';
2
1
  import type { ActionMessage } from '../action/types';
3
- export declare const getErrorMessage: (error?: ErrorMessage) => ActionMessage;
2
+ export declare const getErrorMessage: (error?: string) => ActionMessage;
@@ -9,5 +9,5 @@ import { type PopupComponentProps } from '@atlaskit/popup';
9
9
  * HoverCard border implementation is in ContentContainer where it can
10
10
  * change between the default border and prism border during runtime.
11
11
  */
12
- declare const CustomPopupContainer: React.ForwardRefExoticComponent<Pick<PopupComponentProps, "children" | "style" | "id" | "tabIndex" | "role" | "data-testid" | "shouldFitContainer" | "shouldRenderToParent" | "data-placement"> & React.RefAttributes<HTMLDivElement>>;
12
+ declare const CustomPopupContainer: React.ForwardRefExoticComponent<Pick<PopupComponentProps, "appearance" | "children" | "style" | "id" | "tabIndex" | "role" | "data-testid" | "shouldFitContainer" | "shouldRenderToParent" | "xcss" | "data-placement"> & React.RefAttributes<HTMLDivElement>>;
13
13
  export default CustomPopupContainer;
@@ -1,3 +1,3 @@
1
1
  import { jsx } from '@emotion/react';
2
2
  import { type HoverCardComponentProps } from '../types';
3
- export declare const HoverCardComponent: ({ children, url, id, analyticsHandler, canOpen, closeOnChildClick, hidePreviewButton, showServerActions, actionOptions: actionOptionsProp, allowEventPropagation, zIndex, noFadeDelay, hoverPreviewOptions, }: HoverCardComponentProps) => jsx.JSX.Element;
3
+ export declare const HoverCardComponent: ({ children, url, id, analyticsHandler, canOpen, closeOnChildClick, hidePreviewButton, actionOptions: actionOptionsProp, allowEventPropagation, zIndex, noFadeDelay, hoverPreviewOptions, }: HoverCardComponentProps) => jsx.JSX.Element;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/smart-card",
3
- "version": "28.1.6",
3
+ "version": "28.2.0",
4
4
  "description": "Smart card component",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -30,7 +30,7 @@
30
30
  "@atlaskit/avatar": "^21.15.0",
31
31
  "@atlaskit/avatar-group": "^9.11.0",
32
32
  "@atlaskit/badge": "^16.4.0",
33
- "@atlaskit/button": "^20.1.0",
33
+ "@atlaskit/button": "^20.2.0",
34
34
  "@atlaskit/checkbox": "^14.0.0",
35
35
  "@atlaskit/dropdown-menu": "^12.18.0",
36
36
  "@atlaskit/form": "^10.5.0",
@@ -45,21 +45,21 @@
45
45
  "@atlaskit/link-extractors": "^1.9.0",
46
46
  "@atlaskit/linking-common": "^5.11.0",
47
47
  "@atlaskit/linking-types": "^9.0.0",
48
- "@atlaskit/logo": "^14.2.0",
48
+ "@atlaskit/logo": "^14.3.0",
49
49
  "@atlaskit/lozenge": "^11.10.0",
50
50
  "@atlaskit/menu": "^2.12.0",
51
- "@atlaskit/modal-dialog": "^12.15.0",
51
+ "@atlaskit/modal-dialog": "^12.16.0",
52
52
  "@atlaskit/outbound-auth-flow-client": "^3.4.0",
53
53
  "@atlaskit/platform-feature-flags": "^0.3.0",
54
- "@atlaskit/popup": "^1.25.0",
55
- "@atlaskit/primitives": "^12.1.0",
54
+ "@atlaskit/popup": "^1.27.0",
55
+ "@atlaskit/primitives": "^12.2.0",
56
56
  "@atlaskit/section-message": "^6.6.0",
57
57
  "@atlaskit/select": "^17.19.0",
58
58
  "@atlaskit/spinner": "^16.3.0",
59
59
  "@atlaskit/textarea": "^5.6.0",
60
60
  "@atlaskit/textfield": "^6.5.0",
61
61
  "@atlaskit/theme": "^13.0.0",
62
- "@atlaskit/tokens": "^1.60.0",
62
+ "@atlaskit/tokens": "^1.61.0",
63
63
  "@atlaskit/tooltip": "^18.7.0",
64
64
  "@atlaskit/ufo": "^0.3.0",
65
65
  "@babel/runtime": "^7.0.0",
@@ -90,7 +90,7 @@
90
90
  "@atlaskit/analytics-listeners": "^8.11.0",
91
91
  "@atlaskit/css-reset": "^6.11.0",
92
92
  "@atlaskit/link-test-helpers": "^7.5.0",
93
- "@atlaskit/media-test-helpers": "^34.3.0",
93
+ "@atlaskit/media-test-helpers": "^34.4.0",
94
94
  "@atlaskit/ssr": "*",
95
95
  "@atlaskit/visual-regression": "*",
96
96
  "@atlassian/analytics-tooling": "*",