@atlaskit/smart-card 26.52.2 → 26.52.4

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 (112) hide show
  1. package/CHANGELOG.md +13 -0
  2. package/dist/cjs/extractors/flexible/actions/index.js +1 -1
  3. package/dist/cjs/messages.js +5 -0
  4. package/dist/cjs/state/hooks/use-ai-summary/ai-summary-service/index.js +72 -102
  5. package/dist/cjs/utils/analytics/analytics.js +1 -1
  6. package/dist/cjs/view/FlexibleCard/components/actions/action/action-icon/index.js +23 -6
  7. package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/index.js +94 -0
  8. package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/types.js +5 -0
  9. package/dist/cjs/view/FlexibleCard/components/actions/action/index.js +36 -20
  10. package/dist/cjs/view/FlexibleCard/components/actions/delete-action/index.js +24 -0
  11. package/dist/cjs/view/FlexibleCard/components/actions/delete-action/types.js +5 -0
  12. package/dist/cjs/view/FlexibleCard/components/actions/edit-action/index.js +24 -0
  13. package/dist/cjs/view/FlexibleCard/components/actions/edit-action/types.js +5 -0
  14. package/dist/cjs/view/FlexibleCard/components/actions/index.js +15 -15
  15. package/dist/cjs/view/FlexibleCard/components/actions/preview-action/index.js +6 -2
  16. package/dist/cjs/view/FlexibleCard/components/actions/preview-action/preview-icon/index.js +19 -0
  17. package/dist/cjs/view/FlexibleCard/components/actions/utils.js +0 -22
  18. package/dist/cjs/view/FlexibleCard/components/blocks/action-block/index.js +72 -0
  19. package/dist/cjs/view/FlexibleCard/components/blocks/action-block/types.js +5 -0
  20. package/dist/cjs/view/FlexibleCard/components/blocks/index.js +8 -1
  21. package/dist/cjs/view/FlexibleCard/components/blocks/utils.js +6 -0
  22. package/dist/cjs/view/FlexibleCard/components/container/index.js +26 -5
  23. package/dist/cjs/view/FlexibleCard/components/utils.js +76 -8
  24. package/dist/cjs/view/HoverCard/components/views/resolved/index.js +2 -0
  25. package/dist/cjs/view/LinkUrl/index.js +1 -1
  26. package/dist/es2019/extractors/flexible/actions/index.js +2 -2
  27. package/dist/es2019/messages.js +5 -0
  28. package/dist/es2019/state/hooks/use-ai-summary/ai-summary-service/index.js +4 -4
  29. package/dist/es2019/utils/analytics/analytics.js +1 -1
  30. package/dist/es2019/view/FlexibleCard/components/actions/action/action-icon/index.js +21 -6
  31. package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/index.js +83 -0
  32. package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/types.js +1 -0
  33. package/dist/es2019/view/FlexibleCard/components/actions/action/index.js +34 -17
  34. package/dist/es2019/view/FlexibleCard/components/actions/delete-action/index.js +15 -0
  35. package/dist/es2019/view/FlexibleCard/components/actions/delete-action/types.js +1 -0
  36. package/dist/es2019/view/FlexibleCard/components/actions/edit-action/index.js +15 -0
  37. package/dist/es2019/view/FlexibleCard/components/actions/edit-action/types.js +1 -0
  38. package/dist/es2019/view/FlexibleCard/components/actions/index.js +2 -13
  39. package/dist/es2019/view/FlexibleCard/components/actions/preview-action/index.js +6 -2
  40. package/dist/es2019/view/FlexibleCard/components/actions/preview-action/preview-icon/index.js +10 -0
  41. package/dist/es2019/view/FlexibleCard/components/actions/utils.js +0 -24
  42. package/dist/es2019/view/FlexibleCard/components/blocks/action-block/index.js +61 -0
  43. package/dist/es2019/view/FlexibleCard/components/blocks/action-block/types.js +1 -0
  44. package/dist/es2019/view/FlexibleCard/components/blocks/index.js +2 -1
  45. package/dist/es2019/view/FlexibleCard/components/blocks/utils.js +6 -0
  46. package/dist/es2019/view/FlexibleCard/components/container/index.js +23 -24
  47. package/dist/es2019/view/FlexibleCard/components/utils.js +73 -38
  48. package/dist/es2019/view/HoverCard/components/views/resolved/index.js +3 -1
  49. package/dist/es2019/view/LinkUrl/index.js +1 -1
  50. package/dist/esm/extractors/flexible/actions/index.js +1 -1
  51. package/dist/esm/messages.js +5 -0
  52. package/dist/esm/state/hooks/use-ai-summary/ai-summary-service/index.js +72 -102
  53. package/dist/esm/utils/analytics/analytics.js +1 -1
  54. package/dist/esm/view/FlexibleCard/components/actions/action/action-icon/index.js +22 -6
  55. package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/index.js +84 -0
  56. package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/types.js +1 -0
  57. package/dist/esm/view/FlexibleCard/components/actions/action/index.js +35 -18
  58. package/dist/esm/view/FlexibleCard/components/actions/delete-action/index.js +17 -0
  59. package/dist/esm/view/FlexibleCard/components/actions/delete-action/types.js +1 -0
  60. package/dist/esm/view/FlexibleCard/components/actions/edit-action/index.js +17 -0
  61. package/dist/esm/view/FlexibleCard/components/actions/edit-action/types.js +1 -0
  62. package/dist/esm/view/FlexibleCard/components/actions/index.js +2 -13
  63. package/dist/esm/view/FlexibleCard/components/actions/preview-action/index.js +6 -2
  64. package/dist/esm/view/FlexibleCard/components/actions/preview-action/preview-icon/index.js +12 -0
  65. package/dist/esm/view/FlexibleCard/components/actions/utils.js +0 -22
  66. package/dist/esm/view/FlexibleCard/components/blocks/action-block/index.js +63 -0
  67. package/dist/esm/view/FlexibleCard/components/blocks/action-block/types.js +1 -0
  68. package/dist/esm/view/FlexibleCard/components/blocks/index.js +2 -1
  69. package/dist/esm/view/FlexibleCard/components/blocks/utils.js +6 -0
  70. package/dist/esm/view/FlexibleCard/components/container/index.js +26 -5
  71. package/dist/esm/view/FlexibleCard/components/utils.js +75 -7
  72. package/dist/esm/view/HoverCard/components/views/resolved/index.js +3 -1
  73. package/dist/esm/view/LinkUrl/index.js +1 -1
  74. package/dist/types/messages.d.ts +1 -1
  75. package/dist/types/state/hooks/use-ai-summary/ai-summary-service/index.d.ts +2 -2
  76. package/dist/types/state/hooks/use-ai-summary/ai-summary-service/types.d.ts +4 -4
  77. package/dist/types/view/FlexibleCard/components/actions/action/action-icon/types.d.ts +4 -3
  78. package/dist/types/view/FlexibleCard/components/actions/action/action-stack-item/index.d.ts +4 -0
  79. package/dist/types/view/FlexibleCard/components/actions/action/action-stack-item/types.d.ts +10 -0
  80. package/dist/types/view/FlexibleCard/components/actions/action/index.d.ts +3 -6
  81. package/dist/types/view/FlexibleCard/components/actions/action/types.d.ts +24 -16
  82. package/dist/types/view/FlexibleCard/components/actions/delete-action/index.d.ts +4 -0
  83. package/dist/types/view/FlexibleCard/components/actions/delete-action/types.d.ts +2 -0
  84. package/dist/types/view/FlexibleCard/components/actions/edit-action/index.d.ts +4 -0
  85. package/dist/types/view/FlexibleCard/components/actions/edit-action/types.d.ts +2 -0
  86. package/dist/types/view/FlexibleCard/components/actions/index.d.ts +2 -12
  87. package/dist/types/view/FlexibleCard/components/actions/preview-action/preview-icon/index.d.ts +4 -0
  88. package/dist/types/view/FlexibleCard/components/blocks/action-block/index.d.ts +4 -0
  89. package/dist/types/view/FlexibleCard/components/blocks/action-block/types.d.ts +17 -0
  90. package/dist/types/view/FlexibleCard/components/blocks/index.d.ts +1 -0
  91. package/dist/types/view/FlexibleCard/components/blocks/utils.d.ts +5 -0
  92. package/dist/types/view/FlexibleCard/components/utils.d.ts +11 -0
  93. package/dist/types-ts4.5/messages.d.ts +1 -1
  94. package/dist/types-ts4.5/state/hooks/use-ai-summary/ai-summary-service/index.d.ts +2 -2
  95. package/dist/types-ts4.5/state/hooks/use-ai-summary/ai-summary-service/types.d.ts +4 -4
  96. package/dist/types-ts4.5/view/FlexibleCard/components/actions/action/action-icon/types.d.ts +4 -3
  97. package/dist/types-ts4.5/view/FlexibleCard/components/actions/action/action-stack-item/index.d.ts +4 -0
  98. package/dist/types-ts4.5/view/FlexibleCard/components/actions/action/action-stack-item/types.d.ts +10 -0
  99. package/dist/types-ts4.5/view/FlexibleCard/components/actions/action/index.d.ts +3 -6
  100. package/dist/types-ts4.5/view/FlexibleCard/components/actions/action/types.d.ts +24 -16
  101. package/dist/types-ts4.5/view/FlexibleCard/components/actions/delete-action/index.d.ts +4 -0
  102. package/dist/types-ts4.5/view/FlexibleCard/components/actions/delete-action/types.d.ts +2 -0
  103. package/dist/types-ts4.5/view/FlexibleCard/components/actions/edit-action/index.d.ts +4 -0
  104. package/dist/types-ts4.5/view/FlexibleCard/components/actions/edit-action/types.d.ts +2 -0
  105. package/dist/types-ts4.5/view/FlexibleCard/components/actions/index.d.ts +2 -12
  106. package/dist/types-ts4.5/view/FlexibleCard/components/actions/preview-action/preview-icon/index.d.ts +4 -0
  107. package/dist/types-ts4.5/view/FlexibleCard/components/blocks/action-block/index.d.ts +4 -0
  108. package/dist/types-ts4.5/view/FlexibleCard/components/blocks/action-block/types.d.ts +17 -0
  109. package/dist/types-ts4.5/view/FlexibleCard/components/blocks/index.d.ts +1 -0
  110. package/dist/types-ts4.5/view/FlexibleCard/components/blocks/utils.d.ts +5 -0
  111. package/dist/types-ts4.5/view/FlexibleCard/components/utils.d.ts +11 -0
  112. package/package.json +4 -1
@@ -0,0 +1,63 @@
1
+ import { Stack, xcss } from '@atlaskit/primitives';
2
+ import React, { useMemo } from 'react';
3
+ import { SmartLinkSize } from '../../../../../constants';
4
+ import { useFlexibleUiContext, useFlexibleUiOptionContext } from '../../../../../state/flexible-ui-context';
5
+ import * as Actions from '../../actions';
6
+ import { getPrimitivesPaddingSpaceBySize } from '../../utils';
7
+ // We have to find a better way to ignore container padding
8
+ // This has become more and more of a common use case.
9
+ var ignoreContainerPaddingStyles = xcss({
10
+ marginLeft: 'calc(var(--container-gap-left) * -1)',
11
+ marginRight: 'calc(var(--container-gap-right) * -1)'
12
+ });
13
+ var ActionBlock = function ActionBlock(_ref) {
14
+ var blockRef = _ref.blockRef,
15
+ onClickCallback = _ref.onClick,
16
+ size = _ref.size,
17
+ sort = _ref.sort,
18
+ spaceInline = _ref.spaceInline,
19
+ _ref$testId = _ref.testId,
20
+ testId = _ref$testId === void 0 ? 'smart-block-action' : _ref$testId;
21
+ var context = useFlexibleUiContext();
22
+ var ui = useFlexibleUiOptionContext();
23
+ var padding = !(ui !== null && ui !== void 0 && ui.hidePadding) ? getPrimitivesPaddingSpaceBySize((ui === null || ui === void 0 ? void 0 : ui.size) || SmartLinkSize.Medium) : undefined;
24
+ var actions = useMemo(function () {
25
+ if (!(context !== null && context !== void 0 && context.actions)) {
26
+ return;
27
+ }
28
+ var arr = Object.keys(context.actions);
29
+ if (sort) {
30
+ arr.sort(sort);
31
+ }
32
+ return arr.map(function (name) {
33
+ var Action = Actions[name];
34
+ return Action ? /*#__PURE__*/React.createElement(Action, {
35
+ as: "stack-item",
36
+ spaceInline: spaceInline,
37
+ key: name,
38
+ onClick: function onClick() {
39
+ return onClickCallback === null || onClickCallback === void 0 ? void 0 : onClickCallback(name);
40
+ },
41
+ size: size
42
+ // Remove url once ViewAction is retired.
43
+ // This seems to be a typescript workaround
44
+ // because ViewAction marks it as required,
45
+ // which does not reflect actual implementation as the url
46
+ // came from data context and not all actions require url.
47
+ // https://product-fabric.atlassian.net/browse/EDM-9547
48
+ ,
49
+ url: "",
50
+ xcss: xcss({
51
+ paddingInline: padding
52
+ })
53
+ }) : null;
54
+ });
55
+ }, [context === null || context === void 0 ? void 0 : context.actions, onClickCallback, padding, size, sort, spaceInline]);
56
+ return actions ? /*#__PURE__*/React.createElement(Stack, {
57
+ grow: "fill",
58
+ xcss: ignoreContainerPaddingStyles,
59
+ ref: blockRef,
60
+ testId: testId
61
+ }, actions) : null;
62
+ };
63
+ export default ActionBlock;
@@ -8,4 +8,5 @@ export { default as CustomBlock } from './block';
8
8
  // Internal components to be used within @atlaskit/smart-card only.
9
9
  export { default as InternalFooterBlock } from './footer-block/resolved';
10
10
  export { default as RelatedUrlsBlock } from './related-urls-block';
11
- export { default as AISummaryBlock } from './ai-summary-block';
11
+ export { default as AISummaryBlock } from './ai-summary-block';
12
+ export { default as ActionBlock } from './action-block';
@@ -31,6 +31,12 @@ var getDirectionStyles = function getDirectionStyles(direction) {
31
31
  });
32
32
  }
33
33
  };
34
+
35
+ /**
36
+ * Get gap size between elements inside a block
37
+ * Equivalent version for DS primitives space token is getPrimitivesInlineSpaceBySize()
38
+ * at view/FlexibleCard/components/utils.tsx
39
+ */
34
40
  export var getGapSize = function getGapSize(size) {
35
41
  switch (size) {
36
42
  case SmartLinkSize.XLarge:
@@ -1,5 +1,5 @@
1
1
  import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral";
2
- var _templateObject, _templateObject2, _templateObject3, _templateObject4;
2
+ var _templateObject;
3
3
  /** @jsx jsx */
4
4
  import React, { useContext } from 'react';
5
5
  import { css, jsx } from '@emotion/react';
@@ -11,7 +11,11 @@ import HoverCardControl from './hover-card-control';
11
11
  import { isFlexUiPreviewPresent } from '../../../../state/flexible-ui-context/utils';
12
12
  import { N40 } from '@atlaskit/theme/colors';
13
13
  import { di } from 'react-magnetic-di';
14
- var elevationStyles = css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n border: 1px solid ", ";\n border-radius: ", ";\n margin: ", ";\n"])), "var(--ds-border, ".concat(N40, ")"), "var(--ds-border-radius-200, 8px)", "var(--ds-space-025, 2px)");
14
+ var elevationStyles = css({
15
+ border: "1px solid ".concat("var(--ds-border, ".concat(N40, ")")),
16
+ borderRadius: "var(--ds-border-radius-200, 8px)",
17
+ margin: "var(--ds-space-025, 2px)"
18
+ });
15
19
  var getGap = function getGap(size) {
16
20
  switch (size) {
17
21
  case SmartLinkSize.XLarge:
@@ -25,6 +29,12 @@ var getGap = function getGap(size) {
25
29
  return '.25rem';
26
30
  }
27
31
  };
32
+
33
+ /**
34
+ * Get container padding based on smart link size
35
+ * Equivalent version for DS primitives space token is getPrimitivesPaddingSpaceBySize()
36
+ * at view/FlexibleCard/components/utils.tsx
37
+ */
28
38
  var getPadding = function getPadding(size) {
29
39
  switch (size) {
30
40
  case SmartLinkSize.XLarge:
@@ -38,13 +48,24 @@ var getPadding = function getPadding(size) {
38
48
  return '.5rem';
39
49
  }
40
50
  };
41
- var clickableContainerStyles = css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n // Position any interactive elements at the top of the z-index stack.\n a,\n button,\n .has-action {\n position: relative;\n z-index: 1;\n }\n"])));
51
+ var clickableContainerStyles = css({
52
+ 'a, button, .has-action': {
53
+ position: 'relative',
54
+ zIndex: 1
55
+ }
56
+ });
42
57
  var getContainerPaddingStyles = function getContainerPaddingStyles(size, hidePadding, childrenOptions) {
43
58
  var padding = hidePadding ? '0rem' : getPadding(size);
44
59
  var gap = getGap(size);
45
60
  var previewOnLeft = childrenOptions.previewOnLeft,
46
61
  previewOnRight = childrenOptions.previewOnRight;
47
- return css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n // Set variables for PreviewBlock to use.\n --container-padding: ", ";\n --container-gap-left: ", ";\n --container-gap-right: ", ";\n --preview-block-width: 30%;\n\n padding: ", ";\n ", "\n ", "\n "])), padding, previewOnLeft ? gap : padding, previewOnRight ? gap : padding, padding, previewOnLeft ? "padding-left: calc(var(--preview-block-width) + ".concat(gap, ");") : '', previewOnRight ? "padding-right: calc(var(--preview-block-width) + ".concat(gap, ");") : '');
62
+ return css({
63
+ '--container-padding': padding,
64
+ '--container-gap-left': previewOnLeft ? gap : padding,
65
+ '--container-gap-right': previewOnRight ? gap : padding,
66
+ '--preview-block-width': '30%',
67
+ padding: padding
68
+ }, previewOnLeft ? "padding-left: calc(var(--preview-block-width) + ".concat(gap, ");") : '', previewOnRight ? "padding-right: calc(var(--preview-block-width) + ".concat(gap, ");") : '');
48
69
  };
49
70
  var getChildrenOptions = function getChildrenOptions(children, context) {
50
71
  var options = {};
@@ -67,7 +88,7 @@ var getChildrenOptions = function getChildrenOptions(children, context) {
67
88
  };
68
89
  export var getContainerStyles = function getContainerStyles(size, hideBackground, hideElevation, hidePadding, clickableContainer, childrenOptions) {
69
90
  var paddingCss = getContainerPaddingStyles(size, hidePadding, childrenOptions);
70
- return css(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n display: flex;\n gap: ", " 0;\n flex-direction: column;\n min-width: 0;\n overflow-x: hidden;\n position: relative;\n ", "\n ", "\n ", "\n ", "\n &:hover ~ .actions-button-group {\n opacity: 1;\n }\n a:focus,\n .has-action:focus {\n outline-offset: -2px;\n }\n "])), getGap(size), hideBackground ? '' : "background-color: ".concat("var(--ds-surface-raised, #FFFFFF)", ";"), paddingCss, hideElevation ? '' : elevationStyles, clickableContainer ? clickableContainerStyles : '');
91
+ return css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n display: flex;\n gap: ", " 0;\n flex-direction: column;\n min-width: 0;\n overflow-x: hidden;\n position: relative;\n ", "\n ", "\n ", "\n ", "\n &:hover ~ .actions-button-group {\n opacity: 1;\n }\n a:focus,\n .has-action:focus {\n outline-offset: -2px;\n }\n "])), getGap(size), hideBackground ? '' : "background-color: ".concat("var(--ds-surface-raised, #FFFFFF)", ";"), paddingCss, hideElevation ? '' : elevationStyles, clickableContainer ? clickableContainerStyles : '');
71
92
  };
72
93
  var renderChildren = function renderChildren(children, containerSize, containerTheme, status, retry, onClick) {
73
94
  return React.Children.map(children, function (child) {
@@ -3,7 +3,7 @@ import _taggedTemplateLiteral from "@babel/runtime/helpers/taggedTemplateLiteral
3
3
  import _extends from "@babel/runtime/helpers/extends";
4
4
  import _defineProperty from "@babel/runtime/helpers/defineProperty";
5
5
  var _excluded = ["linkIcon"];
6
- var _sizeToButtonSpacing, _templateObject, _templateObject2, _templateObject3, _templateObject4, _templateObject5, _templateObject6;
6
+ var _sizeToButtonSpacing, _templateObject;
7
7
  function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
8
8
  function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
9
9
  import React from 'react';
@@ -29,11 +29,18 @@ export var getFormattedMessageAsString = function getFormattedMessageAsString(in
29
29
  }) : '';
30
30
  };
31
31
  var getIconDimensionStyles = function getIconDimensionStyles(value) {
32
- return css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n height: ", ";\n min-height: ", ";\n max-height: ", ";\n width: ", ";\n min-width: ", ";\n max-width: ", ";\n"])), value, value, value, value, value, value);
32
+ return css({
33
+ height: value,
34
+ minHeight: value,
35
+ maxHeight: value,
36
+ width: value,
37
+ minWidth: value,
38
+ maxWidth: value
39
+ });
33
40
  };
34
41
  export var getIconSizeStyles = function getIconSizeStyles(width) {
35
42
  var sizeStyles = getIconDimensionStyles(width);
36
- return css(_templateObject2 || (_templateObject2 = _taggedTemplateLiteral(["\n flex: 0 0 auto;\n ", "\n span,\n svg,\n img {\n ", "\n }\n svg {\n padding: 0;\n }\n "])), sizeStyles, sizeStyles);
43
+ return css(_templateObject || (_templateObject = _taggedTemplateLiteral(["\n flex: 0 0 auto;\n ", "\n span,\n svg,\n img {\n ", "\n }\n svg {\n padding: 0;\n }\n "])), sizeStyles, sizeStyles);
37
44
  };
38
45
  export var getIconWidth = function getIconWidth(size) {
39
46
  switch (size) {
@@ -62,13 +69,28 @@ export var getLinkLineHeight = function getLinkLineHeight(size) {
62
69
  export var getLinkSizeStyles = function getLinkSizeStyles(size) {
63
70
  switch (size) {
64
71
  case SmartLinkSize.XLarge:
65
- return css(_templateObject3 || (_templateObject3 = _taggedTemplateLiteral(["\n font-size: 1.25rem;\n font-weight: 400;\n letter-spacing: -0.008em;\n line-height: ", ";\n "])), getLinkLineHeight(size));
72
+ return css({
73
+ fontSize: '1.25rem',
74
+ fontWeight: 400,
75
+ letterSpacing: '-0.008em',
76
+ lineHeight: getLinkLineHeight(size)
77
+ });
66
78
  case SmartLinkSize.Large:
67
79
  case SmartLinkSize.Medium:
68
- return css(_templateObject4 || (_templateObject4 = _taggedTemplateLiteral(["\n font-size: 0.875rem;\n font-weight: 400;\n letter-spacing: -0.003em;\n line-height: ", ";\n "])), getLinkLineHeight(size));
80
+ return css({
81
+ fontSize: '0.875rem',
82
+ fontWeight: 400,
83
+ letterSpacing: '-0.003em',
84
+ lineHeight: getLinkLineHeight(size)
85
+ });
69
86
  case SmartLinkSize.Small:
70
87
  default:
71
- return css(_templateObject5 || (_templateObject5 = _taggedTemplateLiteral(["\n font-size: 0.75rem;\n font-weight: 400;\n letter-spacing: 0em;\n line-height: ", ";\n "])), getLinkLineHeight(size));
88
+ return css({
89
+ fontSize: '0.75rem',
90
+ fontWeight: 400,
91
+ letterSpacing: '0em',
92
+ lineHeight: getLinkLineHeight(size)
93
+ });
72
94
  }
73
95
  };
74
96
  export var getMaxLineHeight = function getMaxLineHeight(size) {
@@ -93,10 +115,56 @@ export var getMaxLines = function getMaxLines(value, defaultValue, max, min) {
93
115
  }
94
116
  return value;
95
117
  };
118
+
119
+ /**
120
+ * A space between element based on smart link size
121
+ * To replace blocks/utils.tsz getGapSize() with space token for primitives
122
+ */
123
+ export var getPrimitivesInlineSpaceBySize = function getPrimitivesInlineSpaceBySize(size) {
124
+ switch (size) {
125
+ case SmartLinkSize.XLarge:
126
+ return 'space.250';
127
+ case SmartLinkSize.Large:
128
+ return 'space.200';
129
+ case SmartLinkSize.Medium:
130
+ return 'space.100';
131
+ case SmartLinkSize.Small:
132
+ default:
133
+ return 'space.050';
134
+ }
135
+ };
136
+
137
+ /**
138
+ * Get container padding based on smart link size
139
+ * To replace container/index.tsx getPadding() with space token for primitives
140
+ */
141
+ export var getPrimitivesPaddingSpaceBySize = function getPrimitivesPaddingSpaceBySize(size) {
142
+ switch (size) {
143
+ case SmartLinkSize.XLarge:
144
+ return 'space.300';
145
+ case SmartLinkSize.Large:
146
+ return 'space.250';
147
+ case SmartLinkSize.Medium:
148
+ return 'space.200';
149
+ case SmartLinkSize.Small:
150
+ default:
151
+ return 'space.100';
152
+ }
153
+ };
96
154
  export var getTruncateStyles = function getTruncateStyles(maxLines) {
97
155
  var lineHeight = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : '1rem';
98
156
  var wordBreak = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 'break-word';
99
- return css(_templateObject6 || (_templateObject6 = _taggedTemplateLiteral(["\n display: -webkit-box;\n overflow: hidden;\n text-overflow: ellipsis;\n word-break: ", ";\n -webkit-line-clamp: ", ";\n -webkit-box-orient: vertical;\n // Fallback options\n @supports not (-webkit-line-clamp: 1) {\n max-height: calc(", " * ", ");\n }\n "])), wordBreak, maxLines, maxLines, lineHeight);
157
+ return css({
158
+ display: '-webkit-box',
159
+ overflow: 'hidden',
160
+ textOverflow: 'ellipsis',
161
+ wordBreak: wordBreak,
162
+ WebkitLineClamp: maxLines,
163
+ WebkitBoxOrient: 'vertical',
164
+ '@supports not (-webkit-line-clamp: 1)': {
165
+ maxHeight: "calc(".concat(maxLines, " * ").concat(lineHeight, ")")
166
+ }
167
+ });
100
168
  };
101
169
  export var hasWhiteSpace = function hasWhiteSpace(str) {
102
170
  return str.search(/\s/) >= 0;
@@ -2,7 +2,7 @@ import _extends from "@babel/runtime/helpers/extends";
2
2
  import _toConsumableArray from "@babel/runtime/helpers/toConsumableArray";
3
3
  import React, { useCallback, useEffect, useMemo, useRef } from 'react';
4
4
  import { ActionName, CardDisplay, ElementName, SmartLinkPosition, SmartLinkSize, SmartLinkDirection } from '../../../../../constants';
5
- import { FooterBlock, MetadataBlock, RelatedUrlsBlock, SnippetBlock, TitleBlock, AISummaryBlock, CustomBlock } from '../../../../FlexibleCard/components/blocks';
5
+ import { FooterBlock, MetadataBlock, RelatedUrlsBlock, SnippetBlock, TitleBlock, AISummaryBlock, CustomBlock, ActionBlock } from '../../../../FlexibleCard/components/blocks';
6
6
  import { footerBlockCss, hiddenSnippetStyles, metadataBlockCss } from './styled';
7
7
  import FlexibleCard from '../../../../FlexibleCard';
8
8
  import { getSimulatedBetterMetadata } from '../../../utils';
@@ -183,6 +183,8 @@ var HoverCardResolvedView = function HoverCardResolvedView(_ref2) {
183
183
  actions: footerActions,
184
184
  size: SmartLinkSize.Large,
185
185
  overrideCss: footerBlockCss
186
+ }), getBooleanFF('platform.linking-platform.smart-card.hover-card-action-redesign') && /*#__PURE__*/React.createElement(ActionBlock, {
187
+ spaceInline: "space.150"
186
188
  }));
187
189
  };
188
190
  export default HoverCardResolvedView;
@@ -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.52.2",
13
+ packageVersion: "26.52.4",
14
14
  componentName: 'linkUrl'
15
15
  };
16
16
  var Link = withLinkClickedEvent('a');
@@ -1,6 +1,6 @@
1
1
  import { 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_summarizing' | 'ai_summary_error_generic' | 'ai_summary_error_acceptable_use_violation' | 'beta' | 'cannot_find_link' | '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' | 'could_not_load_link' | 'download' | 'follow' | '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' | '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' | 'view' | 'viewIn' | 'viewOriginal' | 'actions' | 'add_account' | 'cancel' | 'close' | 'connect_to' | 'connect_account_description' | 'retry' | 'save' | 'unlink_account' | RequestAccessMessageKey | 'related_work_items_not_found' | 'last_mentioned_in' | 'related' | 'generic_error_message';
3
+ export type MessageKey = 'assigned_to' | 'ai_summarize' | 'ai_summarized' | 'ai_summarized_abbreviation' | 'ai_summarized_info' | 'ai_summarizing' | 'ai_summary_error_generic' | 'ai_summary_error_acceptable_use_violation' | 'beta' | 'cannot_find_link' | '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' | 'could_not_load_link' | 'download' | 'follow' | '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' | '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' | 'view' | 'viewIn' | 'viewOriginal' | 'actions' | 'add_account' | 'cancel' | 'close' | 'connect_to' | 'connect_account_description' | 'retry' | 'save' | 'unlink_account' | RequestAccessMessageKey | 'related_work_items_not_found' | 'last_mentioned_in' | 'related' | 'generic_error_message';
4
4
  type Messages = {
5
5
  [K in MessageKey]: MessageDescriptor;
6
6
  };
@@ -1,4 +1,4 @@
1
- import { type AISummaryServiceProps, type AISummaryServiceInt, type AISummaryState, type StateSetter, type SummaryStyle } from './types';
1
+ import { type AISummaryServiceProps, type AISummaryServiceInt, type AISummaryState, type StateSetter } from './types';
2
2
  export declare class AISummaryService implements AISummaryServiceInt {
3
3
  state: AISummaryState;
4
4
  private config;
@@ -10,7 +10,7 @@ export declare class AISummaryService implements AISummaryServiceInt {
10
10
  private onError?;
11
11
  constructor(props: AISummaryServiceProps);
12
12
  private fetchStream;
13
- summariseUrl(summaryStyle?: SummaryStyle): Promise<void>;
13
+ summariseUrl(): Promise<void>;
14
14
  private isExpectedError;
15
15
  subscribe(stateSetter: StateSetter): () => void;
16
16
  }
@@ -28,10 +28,10 @@ export type PostAgentPayload = {
28
28
  export type AgentInputContext = {
29
29
  content_url: string;
30
30
  content_ari?: string;
31
- summary_style?: SummaryStyle;
31
+ prompt_id: PromptId;
32
32
  summary_output_mimetype?: SummaryOutputMimeType;
33
33
  };
34
- export type SummaryStyle = 'short' | 'medium' | 'long';
34
+ export type PromptId = 'smart_links';
35
35
  export type SummaryOutputMimeType = 'text/adf' | 'text/markdown' | 'text/json';
36
36
  export declare const errorMessages: readonly ["NETWORK_ERROR", "NO_ANSWER", "RATE_LIMIT", "NO_AGENT", "PLUGIN_ERRORED", "OPENAI_RATE_LIMIT_USER_ABUSE", "ACCEPTABLE_USE_VIOLATIONS", "AI_DISABLED", "UNEXPECTED"];
37
37
  export type ErrorMessage = (typeof errorMessages)[number];
@@ -124,7 +124,7 @@ export type Message = {
124
124
  content: string;
125
125
  content_mime_type: ContentType;
126
126
  conversation_channel_id?: string;
127
- experience_id: ExpirienceID;
127
+ experience_id: ExperienceId;
128
128
  message_metadata?: Metadata;
129
129
  plugin_invocations: PluginInvocationMessage[];
130
130
  role: Role;
@@ -134,7 +134,7 @@ export type Message = {
134
134
  sources?: Sources;
135
135
  };
136
136
  export type ContentType = 'text/markdown';
137
- export type ExpirienceID = 'ai-mate';
137
+ export type ExperienceId = 'ai-mate' | 'smart-link';
138
138
  export type Role = 'ASSISTANT';
139
139
  export type Appendices = Array<Appendix>;
140
140
  export type Appendix = {
@@ -1,8 +1,9 @@
1
- import { ReactChild } from 'react';
2
- import { SmartLinkSize } from '../../../../../../constants';
1
+ import type { ReactChild } from 'react';
2
+ import type { SmartLinkSize } from '../../../../../../constants';
3
3
  export type ActionIconProps = {
4
4
  size?: SmartLinkSize;
5
5
  icon?: ReactChild;
6
- testId?: string;
7
6
  isDisabled?: boolean;
7
+ showBackground?: boolean;
8
+ testId?: string;
8
9
  };
@@ -0,0 +1,4 @@
1
+ import { type FC } from 'react';
2
+ import { ActionStackItemProps } from './types';
3
+ declare const ActionStackItem: FC<ActionStackItemProps>;
4
+ export default ActionStackItem;
@@ -0,0 +1,10 @@
1
+ import type { Space, XCSS } from '@atlaskit/primitives';
2
+ import type { SmartLinkSize } from '../../../../../../constants';
3
+ import type { ActionProps } from '../types';
4
+ export type ActionStackItemProps = ActionProps & {
5
+ isLoading?: boolean;
6
+ size: SmartLinkSize;
7
+ isDisabled?: boolean;
8
+ space?: Space;
9
+ xcss?: XCSS;
10
+ };
@@ -1,13 +1,10 @@
1
1
  /** @jsx jsx */
2
- import React from 'react';
3
- import { ActionProps, InternalActionProps } from './types';
2
+ import { type FC } from 'react';
3
+ import { ActionProps } from './types';
4
4
  /**
5
5
  * A base action that can be triggered with an on click.
6
6
  * @internal
7
7
  * @param {ActionProps} ActionProps - The props necessary for the Action.
8
- * @see DeleteAction
9
- * @see EditAction
10
- * @see CustomAction
11
8
  */
12
- declare const Action: React.FC<ActionProps & InternalActionProps>;
9
+ declare const Action: FC<ActionProps>;
13
10
  export default Action;
@@ -1,8 +1,13 @@
1
- import { SerializedStyles } from '@emotion/react';
2
- import { SmartLinkSize } from '../../../../../constants';
3
- import { Appearance } from '@atlaskit/button/types';
4
- import { ReactChild } from 'react';
1
+ import type { Appearance } from '@atlaskit/button/types';
2
+ import type { Space, XCSS } from '@atlaskit/primitives';
3
+ import type { SerializedStyles } from '@emotion/react';
4
+ import type { ReactChild, ReactNode } from 'react';
5
+ import type { SmartLinkSize } from '../../../../../constants';
5
6
  export type ActionProps = {
7
+ /**
8
+ * Determines the appearance of the action.
9
+ */
10
+ as?: 'button' | 'dropdown-item' | 'stack-item';
6
11
  /**
7
12
  * Determines the size of the Action. Corresponds to an Action appearance.
8
13
  */
@@ -10,7 +15,7 @@ export type ActionProps = {
10
15
  /**
11
16
  * Determines the text content of the Action.
12
17
  */
13
- content?: React.ReactNode;
18
+ content?: ReactNode;
14
19
  /**
15
20
  * Determines the appearance of the action. Corresponds to the Atlaskit action appearance.
16
21
  */
@@ -27,18 +32,29 @@ export type ActionProps = {
27
32
  * Determines where the icon should be rendered if text is provided.
28
33
  */
29
34
  iconPosition?: 'before' | 'after';
35
+ /**
36
+ * Conditionally show a spinner over the top of a button or disable a dropdown item
37
+ * while server action is executing.
38
+ */
39
+ isLoading?: boolean;
30
40
  /**
31
41
  * Determines the tooltip message when hovering over the Action.
32
42
  */
33
- tooltipMessage?: React.ReactNode;
43
+ tooltipMessage?: ReactNode;
34
44
  /**
45
+ * @deprecated Use 'as' instead
35
46
  * Used to determine whether the Action is in a Dropdown.
36
47
  */
37
48
  asDropDownItem?: boolean;
38
49
  /**
39
50
  * Additional CSS properties on the Action.
51
+ * Note: This should be replaced with xcss once component has migrate to use DS Primitives
40
52
  */
41
53
  overrideCss?: SerializedStyles;
54
+ /**
55
+ * Used to add space along the inline axis in ActionStackItem.
56
+ */
57
+ spaceInline?: Space;
42
58
  /**
43
59
  * A `testId` prop is provided for specified elements, which is a unique
44
60
  * string that appears as a data attribute `data-testid` in the rendered code,
@@ -49,16 +65,8 @@ export type ActionProps = {
49
65
  * Determines whether the button displays as disabled.
50
66
  */
51
67
  isDisabled?: boolean;
52
- };
53
- /**
54
- * The internal props that should only be controlled by internal components
55
- * and/or used by experiment. If there is a use case where these props/feature
56
- * should be available as part of smart-card, please move them to ActionProps.
57
- */
58
- export type InternalActionProps = {
59
68
  /**
60
- * Conditionally show a spinner over the top of a button or disable a dropdown item
61
- * while server action is executing.
69
+ * Additional styling properties for Primitives based component
62
70
  */
63
- isLoading?: boolean;
71
+ xcss?: XCSS;
64
72
  };
@@ -0,0 +1,4 @@
1
+ import { type FC } from 'react';
2
+ import { DeleteActionProps } from './types';
3
+ declare const DeleteAction: FC<DeleteActionProps>;
4
+ export default DeleteAction;
@@ -0,0 +1,2 @@
1
+ import type { ActionProps } from '../action/types';
2
+ export type DeleteActionProps = ActionProps;
@@ -0,0 +1,4 @@
1
+ import { type FC } from 'react';
2
+ import { EditActionProps } from './types';
3
+ declare const EditAction: FC<EditActionProps>;
4
+ export default EditAction;
@@ -0,0 +1,2 @@
1
+ import type { ActionProps } from '../action/types';
2
+ export type EditActionProps = ActionProps;
@@ -4,18 +4,8 @@ import { ViewActionProps } from './action/view-action/types';
4
4
  export { default as FollowAction } from './follow-action';
5
5
  export { default as PreviewAction } from './preview-action';
6
6
  export { default as DownloadAction } from './download-action';
7
- /**
8
- * Creates a DeleteAction component. Accepts default ActionProps, but defaults
9
- * the icon to a cross icon.
10
- * @see Action
11
- */
12
- export declare const DeleteAction: import("react").FC<ActionProps>;
13
- /**
14
- * Creates a EditAction component. Accepts default ActionProps, but defaults
15
- * the icon to an edit (pencil) icon.
16
- * @see Action
17
- */
18
- export declare const EditAction: import("react").FC<ActionProps>;
7
+ export { default as EditAction } from './edit-action';
8
+ export { default as DeleteAction } from './delete-action';
19
9
  /**
20
10
  * Creates a ViewAction component. Accepts default ViewActionProps, and defaults
21
11
  * to the text 'View' inside the button.
@@ -0,0 +1,4 @@
1
+ import type { GlyphProps } from '@atlaskit/icon';
2
+ import React from 'react';
3
+ declare const PreviewIcon: React.FC<GlyphProps>;
4
+ export default PreviewIcon;
@@ -0,0 +1,4 @@
1
+ import React from 'react';
2
+ import { ActionBlockProps } from './types';
3
+ declare const ActionBlock: React.FC<ActionBlockProps>;
4
+ export default ActionBlock;
@@ -0,0 +1,17 @@
1
+ import type { Space } from '@atlaskit/primitives';
2
+ import type { ActionName } from '../../../../../constants';
3
+ import type { BlockProps } from '../types';
4
+ export type ActionBlockProps = {
5
+ /**
6
+ * Callback once action is executed.
7
+ */
8
+ onClick?: (name: ActionName) => {};
9
+ /**
10
+ * Array.Sort function to order the actions
11
+ */
12
+ sort?: (a: ActionName, b: ActionName) => number;
13
+ /**
14
+ * Used to add space along the inline axis (typically horizontal).
15
+ */
16
+ spaceInline?: Space;
17
+ } & BlockProps;
@@ -7,3 +7,4 @@ export { default as CustomBlock } from './block';
7
7
  export { default as InternalFooterBlock } from './footer-block/resolved';
8
8
  export { default as RelatedUrlsBlock } from './related-urls-block';
9
9
  export { default as AISummaryBlock } from './ai-summary-block';
10
+ export { default as ActionBlock } from './action-block';
@@ -5,6 +5,11 @@ import { ElementName, SmartLinkDirection, SmartLinkSize } from '../../../../cons
5
5
  import type { FlexibleUiDataContext } from '../../../../state/flexible-ui-context/types';
6
6
  export type ElementDisplaySchemaType = 'inline' | 'block';
7
7
  export declare const ElementDisplaySchema: Record<ElementName, ElementDisplaySchemaType[]>;
8
+ /**
9
+ * Get gap size between elements inside a block
10
+ * Equivalent version for DS primitives space token is getPrimitivesInlineSpaceBySize()
11
+ * at view/FlexibleCard/components/utils.tsx
12
+ */
8
13
  export declare const getGapSize: (size: SmartLinkSize) => number;
9
14
  export declare const getBaseStyles: (direction: SmartLinkDirection, size: SmartLinkSize) => SerializedStyles;
10
15
  export declare const highlightRemoveStyles: SerializedStyles;
@@ -1,6 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import { SerializedStyles } from '@emotion/react';
3
3
  import { Spacing } from '@atlaskit/button';
4
+ import type { Space } from '@atlaskit/primitives';
4
5
  import { SmartLinkSize } from '../../../constants';
5
6
  import { MessageProps } from './types';
6
7
  import { PreviewActionData } from '../../../state/flexible-ui-context/types';
@@ -15,6 +16,16 @@ export declare const getLinkLineHeight: (size: SmartLinkSize) => string;
15
16
  export declare const getLinkSizeStyles: (size: SmartLinkSize) => SerializedStyles;
16
17
  export declare const getMaxLineHeight: (size: SmartLinkSize) => 1.5 | 1.75;
17
18
  export declare const getMaxLines: (value: number, defaultValue: number, max: number, min: number) => number;
19
+ /**
20
+ * A space between element based on smart link size
21
+ * To replace blocks/utils.tsz getGapSize() with space token for primitives
22
+ */
23
+ export declare const getPrimitivesInlineSpaceBySize: (size: SmartLinkSize) => Space;
24
+ /**
25
+ * Get container padding based on smart link size
26
+ * To replace container/index.tsx getPadding() with space token for primitives
27
+ */
28
+ export declare const getPrimitivesPaddingSpaceBySize: (size: SmartLinkSize) => Space;
18
29
  export declare const getTruncateStyles: (maxLines: number, lineHeight?: string, wordBreak?: 'break-word' | 'break-all') => SerializedStyles;
19
30
  export declare const hasWhiteSpace: (str: string) => boolean;
20
31
  export declare const openEmbedModalWithFlexibleUiIcon: ({ linkIcon, ...props }: Partial<EmbedModalProps> & Pick<PreviewActionData, 'linkIcon'>) => Promise<void>;