@atlaskit/smart-card 44.23.0 → 44.23.2

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 (147) hide show
  1. package/CHANGELOG.md +16 -0
  2. package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-false.png +2 -2
  3. package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-true.png +2 -2
  4. package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default.png +3 -0
  5. package/dist/cjs/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
  6. package/dist/cjs/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
  7. package/dist/cjs/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
  8. package/dist/cjs/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
  9. package/dist/cjs/__tests__/vr-tests/__snapshots__/inline-card/inline-card-resolved-view-with-rovo-actions-cta-treatment---default.png +2 -2
  10. package/dist/cjs/__tests__/vr-tests/__snapshots__/inline-card/inline-card-with-entity-support--default.png +2 -2
  11. package/dist/cjs/extractors/common/icon/extractIconFromDocument.js +6 -14
  12. package/dist/cjs/extractors/flexible/actions/extract-rovo-chat-action.js +2 -4
  13. package/dist/cjs/extractors/flexible/actions/index.js +1 -1
  14. package/dist/cjs/extractors/flexible/index.js +1 -1
  15. package/dist/cjs/state/hooks/use-rovo-chat/index.js +1 -1
  16. package/dist/cjs/utils/analytics/analytics.js +1 -1
  17. package/dist/cjs/utils/index.js +23 -75
  18. package/dist/cjs/view/CardWithUrl/component.js +3 -3
  19. package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/action-button.compiled.css +0 -9
  20. package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +7 -28
  21. package/dist/cjs/view/FlexibleCard/components/actions/action/action-stack-item/index.js +1 -10
  22. package/dist/cjs/view/FlexibleCard/components/actions/ai-summary-action/ai-summarise-action.js +1 -2
  23. package/dist/cjs/view/FlexibleCard/components/actions/ai-summary-action/ai-summary-action-component.js +1 -2
  24. package/dist/cjs/view/FlexibleCard/components/actions/automation-action/index.js +1 -2
  25. package/dist/cjs/view/FlexibleCard/components/actions/copy-link-action/index.js +1 -2
  26. package/dist/cjs/view/FlexibleCard/components/actions/follow-action/index.js +1 -2
  27. package/dist/cjs/view/FlexibleCard/components/actions/preview-action/index.js +2 -3
  28. package/dist/cjs/view/FlexibleCard/components/actions/rovo-chat-action/index.js +0 -7
  29. package/dist/cjs/view/FlexibleCard/components/actions/view-related-links-action/index.js +2 -3
  30. package/dist/cjs/view/FlexibleCard/components/blocks/action-block/index.compiled.css +2 -6
  31. package/dist/cjs/view/FlexibleCard/components/blocks/action-block/index.js +4 -26
  32. package/dist/cjs/view/FlexibleCard/components/blocks/hover-card-footer-block/index.compiled.css +0 -1
  33. package/dist/cjs/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +1 -4
  34. package/dist/cjs/view/FlexibleCard/components/common/atlaskit-icon/index.js +34 -36
  35. package/dist/cjs/view/FlexibleCard/index.js +2 -2
  36. package/dist/cjs/view/HoverCard/components/HoverCardContent.js +7 -15
  37. package/dist/cjs/view/HoverCard/components/views/resolved/index.js +4 -11
  38. package/dist/cjs/view/InlineCard/ResolvedView/InlineCardResolvedViewFunctional.js +2 -8
  39. package/dist/cjs/view/LinkUrl/index.js +1 -1
  40. package/dist/cjs/view/common/ai-summary/index.js +1 -3
  41. package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-false.png +2 -2
  42. package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-true.png +2 -2
  43. package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default.png +3 -0
  44. package/dist/es2019/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
  45. package/dist/es2019/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
  46. package/dist/es2019/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
  47. package/dist/es2019/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
  48. package/dist/es2019/__tests__/vr-tests/__snapshots__/inline-card/inline-card-resolved-view-with-rovo-actions-cta-treatment---default.png +2 -2
  49. package/dist/es2019/__tests__/vr-tests/__snapshots__/inline-card/inline-card-with-entity-support--default.png +2 -2
  50. package/dist/es2019/extractors/common/icon/extractIconFromDocument.js +6 -14
  51. package/dist/es2019/extractors/flexible/actions/extract-rovo-chat-action.js +2 -4
  52. package/dist/es2019/extractors/flexible/actions/index.js +1 -1
  53. package/dist/es2019/extractors/flexible/index.js +1 -1
  54. package/dist/es2019/state/hooks/use-rovo-chat/index.js +1 -1
  55. package/dist/es2019/utils/analytics/analytics.js +1 -1
  56. package/dist/es2019/utils/index.js +3 -26
  57. package/dist/es2019/view/CardWithUrl/component.js +3 -4
  58. package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/action-button.compiled.css +0 -9
  59. package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +7 -28
  60. package/dist/es2019/view/FlexibleCard/components/actions/action/action-stack-item/index.js +1 -10
  61. package/dist/es2019/view/FlexibleCard/components/actions/ai-summary-action/ai-summarise-action.js +1 -2
  62. package/dist/es2019/view/FlexibleCard/components/actions/ai-summary-action/ai-summary-action-component.js +1 -2
  63. package/dist/es2019/view/FlexibleCard/components/actions/automation-action/index.js +1 -2
  64. package/dist/es2019/view/FlexibleCard/components/actions/copy-link-action/index.js +1 -2
  65. package/dist/es2019/view/FlexibleCard/components/actions/follow-action/index.js +1 -2
  66. package/dist/es2019/view/FlexibleCard/components/actions/preview-action/index.js +2 -3
  67. package/dist/es2019/view/FlexibleCard/components/actions/rovo-chat-action/index.js +0 -7
  68. package/dist/es2019/view/FlexibleCard/components/actions/view-related-links-action/index.js +2 -3
  69. package/dist/es2019/view/FlexibleCard/components/blocks/action-block/index.compiled.css +2 -6
  70. package/dist/es2019/view/FlexibleCard/components/blocks/action-block/index.js +4 -26
  71. package/dist/es2019/view/FlexibleCard/components/blocks/hover-card-footer-block/index.compiled.css +0 -1
  72. package/dist/es2019/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +1 -4
  73. package/dist/es2019/view/FlexibleCard/components/common/atlaskit-icon/index.js +34 -36
  74. package/dist/es2019/view/FlexibleCard/index.js +2 -2
  75. package/dist/es2019/view/HoverCard/components/HoverCardContent.js +7 -16
  76. package/dist/es2019/view/HoverCard/components/views/resolved/index.js +3 -11
  77. package/dist/es2019/view/InlineCard/ResolvedView/InlineCardResolvedViewFunctional.js +3 -10
  78. package/dist/es2019/view/LinkUrl/index.js +1 -1
  79. package/dist/es2019/view/common/ai-summary/index.js +1 -3
  80. package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-false.png +2 -2
  81. package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-unauthorised--default--platform-sl-3p-preauth-better-hovercard-true.png +2 -2
  82. package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default.png +3 -0
  83. package/dist/esm/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
  84. package/dist/esm/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-false-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
  85. package/dist/esm/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-false.png +2 -2
  86. package/dist/esm/__tests__/vr-tests/__snapshots__/icon-element-variations/icon-element-all-variations-with-experiments--default--platform-sl-3p-preauth-better-hovercard-killswitch-true-platform-sl-3p-preauth-better-hovercard-true.png +2 -2
  87. package/dist/esm/__tests__/vr-tests/__snapshots__/inline-card/inline-card-resolved-view-with-rovo-actions-cta-treatment---default.png +2 -2
  88. package/dist/esm/__tests__/vr-tests/__snapshots__/inline-card/inline-card-with-entity-support--default.png +2 -2
  89. package/dist/esm/extractors/common/icon/extractIconFromDocument.js +6 -14
  90. package/dist/esm/extractors/flexible/actions/extract-rovo-chat-action.js +2 -4
  91. package/dist/esm/extractors/flexible/actions/index.js +1 -1
  92. package/dist/esm/extractors/flexible/index.js +1 -1
  93. package/dist/esm/state/hooks/use-rovo-chat/index.js +1 -1
  94. package/dist/esm/utils/analytics/analytics.js +1 -1
  95. package/dist/esm/utils/index.js +23 -63
  96. package/dist/esm/view/CardWithUrl/component.js +3 -3
  97. package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/action-button.compiled.css +0 -9
  98. package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/action-button.js +7 -28
  99. package/dist/esm/view/FlexibleCard/components/actions/action/action-stack-item/index.js +1 -10
  100. package/dist/esm/view/FlexibleCard/components/actions/ai-summary-action/ai-summarise-action.js +1 -2
  101. package/dist/esm/view/FlexibleCard/components/actions/ai-summary-action/ai-summary-action-component.js +1 -2
  102. package/dist/esm/view/FlexibleCard/components/actions/automation-action/index.js +1 -2
  103. package/dist/esm/view/FlexibleCard/components/actions/copy-link-action/index.js +1 -2
  104. package/dist/esm/view/FlexibleCard/components/actions/follow-action/index.js +1 -2
  105. package/dist/esm/view/FlexibleCard/components/actions/preview-action/index.js +2 -3
  106. package/dist/esm/view/FlexibleCard/components/actions/rovo-chat-action/index.js +0 -7
  107. package/dist/esm/view/FlexibleCard/components/actions/view-related-links-action/index.js +2 -3
  108. package/dist/esm/view/FlexibleCard/components/blocks/action-block/index.compiled.css +2 -6
  109. package/dist/esm/view/FlexibleCard/components/blocks/action-block/index.js +4 -26
  110. package/dist/esm/view/FlexibleCard/components/blocks/hover-card-footer-block/index.compiled.css +0 -1
  111. package/dist/esm/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +1 -4
  112. package/dist/esm/view/FlexibleCard/components/common/atlaskit-icon/index.js +34 -36
  113. package/dist/esm/view/FlexibleCard/index.js +2 -2
  114. package/dist/esm/view/HoverCard/components/HoverCardContent.js +7 -15
  115. package/dist/esm/view/HoverCard/components/views/resolved/index.js +4 -11
  116. package/dist/esm/view/InlineCard/ResolvedView/InlineCardResolvedViewFunctional.js +3 -9
  117. package/dist/esm/view/LinkUrl/index.js +1 -1
  118. package/dist/esm/view/common/ai-summary/index.js +1 -3
  119. package/dist/types/view/FlexibleCard/components/blocks/action-block/types.d.ts +1 -1
  120. package/dist/types/view/FlexibleCard/components/blocks/ai-summary-block/types.d.ts +2 -2
  121. package/dist/types/view/HoverCard/components/views/resolved/index.d.ts +1 -1
  122. package/dist/types-ts4.5/view/FlexibleCard/components/blocks/action-block/types.d.ts +1 -1
  123. package/dist/types-ts4.5/view/FlexibleCard/components/blocks/ai-summary-block/types.d.ts +2 -2
  124. package/dist/types-ts4.5/view/HoverCard/components/views/resolved/index.d.ts +1 -1
  125. package/package.json +5 -8
  126. package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-generic-3p-rovo-chat-action--default.png +0 -3
  127. package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-false.png +0 -3
  128. package/dist/cjs/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-true.png +0 -3
  129. package/dist/cjs/state/hooks/use-inline-action-nudge-experiment/index.js +0 -54
  130. package/dist/cjs/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.compiled.css +0 -15
  131. package/dist/cjs/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.js +0 -44
  132. package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-generic-3p-rovo-chat-action--default.png +0 -3
  133. package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-false.png +0 -3
  134. package/dist/es2019/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-true.png +0 -3
  135. package/dist/es2019/state/hooks/use-inline-action-nudge-experiment/index.js +0 -48
  136. package/dist/es2019/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.compiled.css +0 -15
  137. package/dist/es2019/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.js +0 -36
  138. package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-generic-3p-rovo-chat-action--default.png +0 -3
  139. package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-false.png +0 -3
  140. package/dist/esm/__tests__/vr-tests/__snapshots__/hover-card/hover-card-with-google-rovo-chat-action--default--rovogrowth-640-inline-action-nudge-exp-true.png +0 -3
  141. package/dist/esm/state/hooks/use-inline-action-nudge-experiment/index.js +0 -47
  142. package/dist/esm/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.compiled.css +0 -15
  143. package/dist/esm/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.js +0 -35
  144. package/dist/types/state/hooks/use-inline-action-nudge-experiment/index.d.ts +0 -24
  145. package/dist/types/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.d.ts +0 -12
  146. package/dist/types-ts4.5/state/hooks/use-inline-action-nudge-experiment/index.d.ts +0 -24
  147. package/dist/types-ts4.5/view/FlexibleCard/components/blocks/action-block/ask-rovo-section-header.d.ts +0 -12
@@ -6,8 +6,6 @@ import "./index.compiled.css";
6
6
  import * as React from 'react';
7
7
  import { ax, ix } from "@compiled/react/runtime";
8
8
  import { useMemo } from 'react';
9
- import { fg } from '@atlaskit/platform-feature-flags';
10
- import { expValEqualsNoExposure } from '@atlaskit/tmp-editor-statsig/exp-val-equals-no-exposure';
11
9
  import { ActionName } from '../../../../../constants';
12
10
  import { useFlexibleCardContext } from '../../../../../state/flexible-ui-context';
13
11
  import { useFlexibleUiContext } from '../../../../../state/flexible-ui-context';
@@ -20,7 +18,6 @@ import Block from '../block';
20
18
  */
21
19
  var HIDDEN_HOVER_CARD_FOOTER_ACTIONS = [ActionName.RovoChatAction];
22
20
  var ignoreContainerMarginStyles = null;
23
- var inlineActionNudgeFooterMarginStyles = null;
24
21
  var elevatedFooterStyles = null;
25
22
  var providerStyles = null;
26
23
  var actionsStyles = null;
@@ -66,7 +63,7 @@ var ResolvedHoverCardFooterBlock = function ResolvedHoverCardFooterBlock(_ref) {
66
63
  return /*#__PURE__*/React.createElement(Block, _extends({}, props, {
67
64
  size: size,
68
65
  testId: "".concat(testId, "-resolved-view"),
69
- className: ax(["_18zrpxbi _1rjcutpp _vchhusvi _1bsb129b _18u01ivi _2hwxc10g _otyr1ya9 _4t3ioahv", "_zulpu2gc _x3doj0fz _bfhkhfxm _mrkb1mok _1o0z1mok", fg('rovogrowth-640-inline-action-nudge-fg') && expValEqualsNoExposure('rovogrowth-640-inline-action-nudge-exp', 'isEnabled', true) && "_19pkutpp"])
66
+ className: ax(["_18zrpxbi _1rjcutpp _vchhusvi _1bsb129b _18u01ivi _2hwxc10g _otyr1ya9 _4t3ioahv", "_zulpu2gc _x3doj0fz _bfhkhfxm _mrkb1mok _1o0z1mok"])
70
67
  }), !hideProvider && /*#__PURE__*/React.createElement("div", {
71
68
  className: ax(["_4t3i1ejb _1e0c1txw _4cvr1h6o _1bah1y6m _vchhusvi _16jlkb7n"])
72
69
  }, /*#__PURE__*/React.createElement(Provider, {
@@ -45,42 +45,40 @@ var AtlaskitIcon = function AtlaskitIcon(_ref) {
45
45
  _ref$size = _ref.size,
46
46
  size = _ref$size === void 0 ? SmartLinkSize.Medium : _ref$size,
47
47
  isTiledIcon = _ref.isTiledIcon;
48
- if (!fg('platform_sl_icons_refactor')) {
49
- // Check for synchronously loaded icons first for SSR purposes.
50
- // Require these icons only inside this branch to avoid evaluating legacy icon
51
- // wrapper modules when the icon refactor is enabled.
52
- switch (icon) {
53
- case IconType.Document:
54
- {
55
- var DocumentIcon = getDocumentIcon();
56
- return /*#__PURE__*/React.createElement(DocumentIcon, {
57
- label: label !== null && label !== void 0 ? label : 'document',
58
- testId: testId,
59
- size: size,
60
- isTiledIcon: isTiledIcon
61
- });
62
- }
63
- case IconType.Blog:
64
- {
65
- var BlogIcon = getBlogIcon();
66
- return /*#__PURE__*/React.createElement(BlogIcon, {
67
- label: label !== null && label !== void 0 ? label : 'blog',
68
- testId: testId,
69
- size: size,
70
- isTiledIcon: isTiledIcon
71
- });
72
- }
73
- case IconType.LiveDocument:
74
- {
75
- var LiveDocumentIcon = getLiveDocumentIcon();
76
- return /*#__PURE__*/React.createElement(LiveDocumentIcon, {
77
- label: label !== null && label !== void 0 ? label : 'live-doc',
78
- testId: testId,
79
- size: size,
80
- isTiledIcon: isTiledIcon
81
- });
82
- }
83
- }
48
+ // Intentionally keep these three icon types synchronous and outside lazy imports.
49
+ // These icons should be present in SSR markup so hydration does not cause a
50
+ // visible empty-state-then-pop-in transition in Smart Link consumers.
51
+ switch (icon) {
52
+ case IconType.Document:
53
+ {
54
+ var DocumentIcon = getDocumentIcon();
55
+ return /*#__PURE__*/React.createElement(DocumentIcon, {
56
+ label: label !== null && label !== void 0 ? label : 'document',
57
+ testId: testId,
58
+ size: size,
59
+ isTiledIcon: isTiledIcon
60
+ });
61
+ }
62
+ case IconType.Blog:
63
+ {
64
+ var BlogIcon = getBlogIcon();
65
+ return /*#__PURE__*/React.createElement(BlogIcon, {
66
+ label: label !== null && label !== void 0 ? label : 'blog',
67
+ testId: testId,
68
+ size: size,
69
+ isTiledIcon: isTiledIcon
70
+ });
71
+ }
72
+ case IconType.LiveDocument:
73
+ {
74
+ var LiveDocumentIcon = getLiveDocumentIcon();
75
+ return /*#__PURE__*/React.createElement(LiveDocumentIcon, {
76
+ label: label !== null && label !== void 0 ? label : 'live-doc',
77
+ testId: testId,
78
+ size: size,
79
+ isTiledIcon: isTiledIcon
80
+ });
81
+ }
84
82
  }
85
83
  var importFn = getIconImportFn(icon, size);
86
84
  if (!importFn) {
@@ -51,7 +51,7 @@ var FlexibleCard = function FlexibleCard(_ref) {
51
51
  isPreviewPanelAvailable = _useSmartLinkContext.isPreviewPanelAvailable,
52
52
  openPreviewPanel = _useSmartLinkContext.openPreviewPanel,
53
53
  product = _useSmartLinkContext.product;
54
- var rovoConfig = fg('platform_sl_3p_auth_rovo_action_kill_switch') || fg('rovogrowth-640-inline-action-nudge-fg') ?
54
+ var rovoConfig = fg('platform_sl_3p_auth_rovo_action_kill_switch') ?
55
55
  // eslint-disable-next-line react-hooks/rules-of-hooks
56
56
  useRovoConfig() : undefined;
57
57
  var _useAnalyticsEvents = useAnalyticsEvents(),
@@ -80,7 +80,7 @@ var FlexibleCard = function FlexibleCard(_ref) {
80
80
  origin: origin,
81
81
  renderers: renderers,
82
82
  resolve: resolve
83
- }, fg('platform_sl_3p_auth_rovo_action_kill_switch') || fg('rovogrowth-640-inline-action-nudge-fg') ? {
83
+ }, fg('platform_sl_3p_auth_rovo_action_kill_switch') ? {
84
84
  product: product,
85
85
  rovoConfig: rovoConfig
86
86
  } : undefined), {}, {
@@ -13,7 +13,6 @@ import { useAnalyticsEvents } from '../../../common/analytics/generated/use-anal
13
13
  import { CardDisplay, SmartLinkPosition, SmartLinkSize } from '../../../constants';
14
14
  import extractRovoChatAction from '../../../extractors/flexible/actions/extract-rovo-chat-action';
15
15
  import { getDefinitionId, getExtensionKey, getServices } from '../../../state/helpers';
16
- import useInlineActionNudgeExperiment from '../../../state/hooks/use-inline-action-nudge-experiment';
17
16
  import useRovoConfig from '../../../state/hooks/use-rovo-config';
18
17
  import { useSmartCardState } from '../../../state/store';
19
18
  import { isSpecialEvent } from '../../../utils';
@@ -236,9 +235,8 @@ var HoverCardContent = function HoverCardContent(_ref4) {
236
235
  flexibleCardProps: flexibleCardProps
237
236
  });
238
237
  }
239
- var is3PInlinePostAuthActionsEnabled = fg('rovogrowth-640-inline-action-nudge-fg') && expValEqualsNoExposure('rovogrowth-640-inline-action-nudge-exp', 'isEnabled', true);
240
238
  if (isResolved) {
241
- return /*#__PURE__*/React.createElement(HoverCardResolvedView, _extends({}, fg('platform_sl_3p_auth_rovo_action_kill_switch') || is3PInlinePostAuthActionsEnabled ? {
239
+ return /*#__PURE__*/React.createElement(HoverCardResolvedView, _extends({}, fg('platform_sl_3p_auth_rovo_action_kill_switch') ? {
242
240
  actionOptions: actionOptions,
243
241
  showRovoResolvedView: showRovoResolvedView
244
242
  } : undefined, {
@@ -289,9 +287,8 @@ var HoverCardContent = function HoverCardContent(_ref4) {
289
287
  flexibleCardProps: flexibleCardProps
290
288
  });
291
289
  }
292
- var is3PInlinePostAuthActionsEnabled = fg('rovogrowth-640-inline-action-nudge-fg') && expValEqualsNoExposure('rovogrowth-640-inline-action-nudge-exp', 'isEnabled', true);
293
290
  if (cardState.status === 'resolved') {
294
- return /*#__PURE__*/React.createElement(HoverCardResolvedView, _extends({}, fg('platform_sl_3p_auth_rovo_action_kill_switch') || is3PInlinePostAuthActionsEnabled ? {
291
+ return /*#__PURE__*/React.createElement(HoverCardResolvedView, _extends({}, fg('platform_sl_3p_auth_rovo_action_kill_switch') ? {
295
292
  actionOptions: actionOptions,
296
293
  showRovoResolvedView: showRovoResolvedView
297
294
  } : undefined, {
@@ -317,8 +314,7 @@ var HoverCardContent = function HoverCardContent(_ref4) {
317
314
  };
318
315
  var HoverCardContentWithViewVariant = function HoverCardContentWithViewVariant(props) {
319
316
  var cardState = props.cardState,
320
- actionOptions = props.actionOptions,
321
- url = props.url;
317
+ actionOptions = props.actionOptions;
322
318
  var rovoConfig = useRovoConfig();
323
319
  var isResolved = useIsResolvedView(props);
324
320
  var showPreauthBetterHovercard = useIsShowPreauthBetterHovercard(props);
@@ -329,22 +325,19 @@ var HoverCardContentWithViewVariant = function HoverCardContentWithViewVariant(p
329
325
  actionOptions: actionOptions
330
326
  }) !== undefined;
331
327
  }, [actionOptions, cardState.details, rovoConfig, isResolved]);
332
- var _useInlineActionNudge = useInlineActionNudgeExperiment(url, true, actionOptions),
333
- rovoActionsCtaShown = _useInlineActionNudge.isEnabled;
334
328
  var data = useMemo(function () {
335
329
  var viewVariant = 'default';
336
- if (showRovoResolvedView && (expValEqualsNoExposure('platform_sl_3p_auth_rovo_action', 'isEnabled', true) || expValEqualsNoExposure('rovogrowth-640-inline-action-nudge-exp', 'isEnabled', true))) {
330
+ if (showRovoResolvedView && expValEqualsNoExposure('platform_sl_3p_auth_rovo_action', 'isEnabled', true)) {
337
331
  viewVariant = 'rovo-resolved-view';
338
332
  } else if (showPreauthBetterHovercard) {
339
333
  viewVariant = 'rovo-unauthorised-view';
340
334
  }
341
335
  return {
342
336
  attributes: {
343
- viewVariant: viewVariant,
344
- rovoActionsCtaShown: rovoActionsCtaShown
337
+ viewVariant: viewVariant
345
338
  }
346
339
  };
347
- }, [showRovoResolvedView, showPreauthBetterHovercard, rovoActionsCtaShown]);
340
+ }, [showRovoResolvedView, showPreauthBetterHovercard]);
348
341
  return /*#__PURE__*/React.createElement(AnalyticsContext, {
349
342
  data: data
350
343
  }, /*#__PURE__*/React.createElement(HoverCardContent, _extends({}, props, {
@@ -355,7 +348,6 @@ var _default_1 = componentWithCondition(function () {
355
348
  // We need to read both of them to sutisfy some of the tests that expect both to be checked.
356
349
  var flagA = fg('platform_sl_3p_preauth_better_hovercard_killswitch');
357
350
  var flagB = fg('platform_sl_3p_auth_rovo_action_kill_switch');
358
- var flagC = fg('rovogrowth-640-inline-action-nudge-fg');
359
- return flagA || flagB || flagC;
351
+ return flagA || flagB;
360
352
  }, HoverCardContentWithViewVariant, HoverCardContent);
361
353
  export default _default_1;
@@ -9,7 +9,6 @@ import { useAnalyticsEvents } from '../../../../../common/analytics/generated/us
9
9
  import { CardDisplay, SmartLinkPosition, SmartLinkSize } from '../../../../../constants';
10
10
  import { succeedUfoExperience } from '../../../../../state/analytics';
11
11
  import useAISummaryAction from '../../../../../state/hooks/use-ai-summary-action';
12
- import useInlineActionNudgeExperiment from '../../../../../state/hooks/use-inline-action-nudge-experiment';
13
12
  import FlexibleCard from '../../../../FlexibleCard';
14
13
  import { ActionBlock, AIFooterBlock, AISummaryBlock, ResolvedHoverCardFooterBlock, MetadataBlock, SnippetBlock, TitleBlock } from '../../../../FlexibleCard/components/blocks';
15
14
  import { getMetadata } from '../../../utils';
@@ -20,8 +19,7 @@ var snippetBlockCss = null;
20
19
  var actionBlockCss = null;
21
20
  var HoverCardResolvedView = function HoverCardResolvedView(_ref) {
22
21
  var _cardState$details;
23
- var actionOptions = _ref.actionOptions,
24
- cardState = _ref.cardState,
22
+ var cardState = _ref.cardState,
25
23
  extensionKey = _ref.extensionKey,
26
24
  flexibleCardProps = _ref.flexibleCardProps,
27
25
  isAISummaryEnabled = _ref.isAISummaryEnabled,
@@ -31,14 +29,9 @@ var HoverCardResolvedView = function HoverCardResolvedView(_ref) {
31
29
  id = _ref.id;
32
30
  var _useAnalyticsEvents = useAnalyticsEvents(),
33
31
  fireEvent = _useAnalyticsEvents.fireEvent;
34
- var _useInlineActionNudge = useInlineActionNudgeExperiment(flexibleCardProps.url, true, actionOptions),
35
- InlineActionNudgeExperimentValue = _useInlineActionNudge.isEnabled;
36
-
37
32
  // We want to fire exposure event only for those cases when user otherwise can see the experiment which would be controlled
38
33
  // by all the other condition defined above as a result of what was defined in actionOptions as well as in CardContext.
39
34
  var is3PAuthRovoActionsExperimentOn = showRovoResolvedView && expValEquals('platform_sl_3p_auth_rovo_action', 'isEnabled', true);
40
- var is3PInlinePostAuthActionsExperimentOn = showRovoResolvedView && InlineActionNudgeExperimentValue;
41
- var isAny3pRovoActionsExperimentOn = is3PAuthRovoActionsExperimentOn || is3PInlinePostAuthActionsExperimentOn;
42
35
  useEffect(function () {
43
36
  // Since this hover view is only rendered on resolved status,
44
37
  // there is no need to check for statuses.
@@ -86,7 +79,7 @@ var HoverCardResolvedView = function HoverCardResolvedView(_ref) {
86
79
  }), isAISummaryEnabled ? /*#__PURE__*/React.createElement(AISummaryBlock, {
87
80
  aiSummaryMinHeight: aiSummaryMinHeight,
88
81
  placeholder: snippet,
89
- isAny3pRovoActionsExperimentOn: isAny3pRovoActionsExperimentOn
82
+ isAny3pRovoActionsExperimentOn: is3PAuthRovoActionsExperimentOn
90
83
  }) : snippet, /*#__PURE__*/React.createElement(SnippetBlock, {
91
84
  testId: "hidden-snippet",
92
85
  onRender: onSnippetRender,
@@ -96,9 +89,9 @@ var HoverCardResolvedView = function HoverCardResolvedView(_ref) {
96
89
  }), /*#__PURE__*/React.createElement(ActionBlock, {
97
90
  onClick: onActionClick,
98
91
  spaceInline: "space.100",
99
- isAny3pRovoActionsExperimentOn: isAny3pRovoActionsExperimentOn,
92
+ isAny3pRovoActionsExperimentOn: is3PAuthRovoActionsExperimentOn,
100
93
  className: ax(["_n3td1b66"])
101
- }), isAny3pRovoActionsExperimentOn ? /*#__PURE__*/React.createElement(ResolvedHoverCardFooterBlock, {
94
+ }), is3PAuthRovoActionsExperimentOn ? /*#__PURE__*/React.createElement(ResolvedHoverCardFooterBlock, {
102
95
  onActionClick: onActionClick
103
96
  }) : /*#__PURE__*/React.createElement(AIFooterBlock, null));
104
97
  };
@@ -1,10 +1,8 @@
1
1
  import React from 'react';
2
- import { fg } from "@atlaskit/platform-feature-flags";
3
2
  import { componentWithFG } from '@atlaskit/platform-feature-flags-react';
4
- import useInlineActionNudgeExperiment from '../../../state/hooks/use-inline-action-nudge-experiment';
5
3
  import useInlineTailoredActionExperiment from '../../../state/hooks/use-inline-tailored-action-experiment';
6
4
  import { HoverCard } from '../../HoverCard';
7
- import { RovoActionsCta, InlineRovoActionButton } from '../common/rovo-actions-cta';
5
+ import { InlineRovoActionButton } from '../common/rovo-actions-cta';
8
6
  import { Frame } from '../Frame';
9
7
  import { IconAndTitleLayout } from '../IconAndTitleLayout';
10
8
  import { renderLozenge } from './renderLozenge';
@@ -81,8 +79,6 @@ export function InlineCardResolvedViewFunctionalWithRovoActions(_ref2) {
81
79
  type = _ref2.type,
82
80
  hideIconLoadingSkeleton = _ref2.hideIconLoadingSkeleton,
83
81
  lozenge = _ref2.lozenge;
84
- var _useInlineActionNudge = useInlineActionNudgeExperiment(link, showHoverPreview, actionOptions),
85
- isEnabled = _useInlineActionNudge.isEnabled;
86
82
  var _useInlineTailoredAct = useInlineTailoredActionExperiment(link, showHoverPreview, actionOptions),
87
83
  isInlineTailoredRovoActionEnabled = _useInlineTailoredAct.isEnabled;
88
84
 
@@ -103,9 +99,7 @@ export function InlineCardResolvedViewFunctionalWithRovoActions(_ref2) {
103
99
  titleTextColor: titleTextColor,
104
100
  type: type,
105
101
  hideIconLoadingSkeleton: hideIconLoadingSkeleton
106
- }), renderLozenge(lozenge), isEnabled && !fg('platform_sl_3p_auth_inline_tailored_cta_killswitch') && /*#__PURE__*/React.createElement(RovoActionsCta, {
107
- testId: "".concat(testId, "-rovo-actions-cta")
108
- }), isInlineTailoredRovoActionEnabled && /*#__PURE__*/React.createElement(InlineRovoActionButton, {
102
+ }), renderLozenge(lozenge), isInlineTailoredRovoActionEnabled && /*#__PURE__*/React.createElement(InlineRovoActionButton, {
109
103
  testId: "".concat(testId, "-rovo-actions-cta"),
110
104
  url: link
111
105
  }));
@@ -121,4 +115,4 @@ export function InlineCardResolvedViewFunctionalWithRovoActions(_ref2) {
121
115
  }
122
116
 
123
117
  // Todo: replace with platform_sl_3p_auth_inline_tailored_cta_killswitch after cleanup of rovogrowth-640-inline-action-nudge-fg
124
- export var InlineCardResolvedViewFunctional = componentWithFG('rovogrowth-640-inline-action-nudge-fg', InlineCardResolvedViewFunctionalWithRovoActions, InlineCardResolvedViewBase);
118
+ export var InlineCardResolvedViewFunctional = componentWithFG('platform_sl_3p_auth_inline_tailored_cta_killswitch', InlineCardResolvedViewFunctionalWithRovoActions, InlineCardResolvedViewBase);
@@ -12,7 +12,7 @@ import LinkWarningModal from './LinkWarningModal';
12
12
  import { useLinkWarningModal } from './LinkWarningModal/hooks/use-link-warning-modal';
13
13
  var PACKAGE_DATA = {
14
14
  packageName: "@atlaskit/smart-card",
15
- packageVersion: "44.22.0",
15
+ packageVersion: "44.23.1",
16
16
  componentName: 'linkUrl'
17
17
  };
18
18
  var LinkUrl = function LinkUrl(_ref) {
@@ -28,9 +28,7 @@ var AISummary = function AISummary(_ref) {
28
28
  }
29
29
  var is3pExperimentEnabled =
30
30
  // eslint-disable-next-line @atlaskit/platform/no-preconditioning
31
- fg('platform_sl_3p_auth_rovo_action_kill_switch') && expValEqualsNoExposure('platform_sl_3p_auth_rovo_action', 'isEnabled', true) ||
32
- // eslint-disable-next-line @atlaskit/platform/no-preconditioning
33
- fg('rovogrowth-640-inline-action-nudge-fg') && expValEqualsNoExposure('rovogrowth-640-inline-action-nudge-exp', 'isEnabled', true);
31
+ fg('platform_sl_3p_auth_rovo_action_kill_switch') && expValEqualsNoExposure('platform_sl_3p_auth_rovo_action', 'isEnabled', true);
34
32
  return /*#__PURE__*/React.createElement(Markdown, {
35
33
  "data-testid": testId
36
34
  // eslint-disable-next-line @atlaskit/ui-styling-standard/no-classname-prop
@@ -3,7 +3,7 @@ import { type FlexibleUiActionName } from '../../../../../constants';
3
3
  import type { BlockProps } from '../types';
4
4
  export type ActionBlockProps = {
5
5
  /**
6
- * Whether platform_sl_3p_auth_rovo_action or rovogrowth-640-inline-action-nudge-exp experiment value is ON for current runtime
6
+ * Whether the platform_sl_3p_auth_rovo_action experiment value is ON for current runtime
7
7
  */
8
8
  isAny3pRovoActionsExperimentOn?: boolean;
9
9
  /**
@@ -6,8 +6,8 @@ export type AISummaryBlockProps = {
6
6
  */
7
7
  aiSummaryMinHeight?: number;
8
8
  /**
9
- * Whether platform_sl_3p_auth_rovo_action or rovogrowth-640-inline-action-nudge-exp experiment value is ON for current runtime
10
- */
9
+ * Whether the platform_sl_3p_auth_rovo_action experiment value is ON for current runtime
10
+ */
11
11
  isAny3pRovoActionsExperimentOn?: boolean;
12
12
  /**
13
13
  * Placeholder to show when summary is not available
@@ -1,3 +1,3 @@
1
1
  import { type HoverCardResolvedProps } from './types';
2
- declare const HoverCardResolvedView: ({ actionOptions, cardState, extensionKey, flexibleCardProps, isAISummaryEnabled, onActionClick, showRovoResolvedView, titleBlockProps, id, }: HoverCardResolvedProps) => JSX.Element;
2
+ declare const HoverCardResolvedView: ({ cardState, extensionKey, flexibleCardProps, isAISummaryEnabled, onActionClick, showRovoResolvedView, titleBlockProps, id, }: HoverCardResolvedProps) => JSX.Element;
3
3
  export default HoverCardResolvedView;
@@ -3,7 +3,7 @@ import { type FlexibleUiActionName } from '../../../../../constants';
3
3
  import type { BlockProps } from '../types';
4
4
  export type ActionBlockProps = {
5
5
  /**
6
- * Whether platform_sl_3p_auth_rovo_action or rovogrowth-640-inline-action-nudge-exp experiment value is ON for current runtime
6
+ * Whether the platform_sl_3p_auth_rovo_action experiment value is ON for current runtime
7
7
  */
8
8
  isAny3pRovoActionsExperimentOn?: boolean;
9
9
  /**
@@ -6,8 +6,8 @@ export type AISummaryBlockProps = {
6
6
  */
7
7
  aiSummaryMinHeight?: number;
8
8
  /**
9
- * Whether platform_sl_3p_auth_rovo_action or rovogrowth-640-inline-action-nudge-exp experiment value is ON for current runtime
10
- */
9
+ * Whether the platform_sl_3p_auth_rovo_action experiment value is ON for current runtime
10
+ */
11
11
  isAny3pRovoActionsExperimentOn?: boolean;
12
12
  /**
13
13
  * Placeholder to show when summary is not available
@@ -1,3 +1,3 @@
1
1
  import { type HoverCardResolvedProps } from './types';
2
- declare const HoverCardResolvedView: ({ actionOptions, cardState, extensionKey, flexibleCardProps, isAISummaryEnabled, onActionClick, showRovoResolvedView, titleBlockProps, id, }: HoverCardResolvedProps) => JSX.Element;
2
+ declare const HoverCardResolvedView: ({ cardState, extensionKey, flexibleCardProps, isAISummaryEnabled, onActionClick, showRovoResolvedView, titleBlockProps, id, }: HoverCardResolvedProps) => JSX.Element;
3
3
  export default HoverCardResolvedView;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/smart-card",
3
- "version": "44.23.0",
3
+ "version": "44.23.2",
4
4
  "description": "Smart card component",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -66,7 +66,7 @@
66
66
  "@atlaskit/link-test-helpers": "^10.4.0",
67
67
  "@atlaskit/linking-common": "^9.13.0",
68
68
  "@atlaskit/linking-types": "^14.4.0",
69
- "@atlaskit/logo": "^20.1.0",
69
+ "@atlaskit/logo": "^20.2.0",
70
70
  "@atlaskit/lozenge": "^13.8.0",
71
71
  "@atlaskit/menu": "^8.5.0",
72
72
  "@atlaskit/modal-dialog": "^15.2.0",
@@ -77,8 +77,8 @@
77
77
  "@atlaskit/platform-feature-flags-react": "^0.5.0",
78
78
  "@atlaskit/popup": "^4.23.0",
79
79
  "@atlaskit/primitives": "^19.0.0",
80
- "@atlaskit/react-ufo": "^6.6.0",
81
- "@atlaskit/rovo-triggers": "^7.3.0",
80
+ "@atlaskit/react-ufo": "^6.7.0",
81
+ "@atlaskit/rovo-triggers": "^7.4.0",
82
82
  "@atlaskit/section-message": "^8.13.0",
83
83
  "@atlaskit/select": "^21.12.0",
84
84
  "@atlaskit/spinner": "^19.1.0",
@@ -87,7 +87,7 @@
87
87
  "@atlaskit/textfield": "^8.3.0",
88
88
  "@atlaskit/theme": "^25.0.0",
89
89
  "@atlaskit/tile": "^1.1.0",
90
- "@atlaskit/tmp-editor-statsig": "^89.0.0",
90
+ "@atlaskit/tmp-editor-statsig": "^89.1.0",
91
91
  "@atlaskit/tokens": "^13.1.0",
92
92
  "@atlaskit/tooltip": "^22.6.0",
93
93
  "@atlaskit/ufo": "^0.5.0",
@@ -253,9 +253,6 @@
253
253
  "smart-card-inline-resolved-view-refactor": {
254
254
  "type": "boolean"
255
255
  },
256
- "rovogrowth-640-inline-action-nudge-fg": {
257
- "type": "boolean"
258
- },
259
256
  "platform_sl_3p_auth_rovo_block_card_kill_switch": {
260
257
  "type": "boolean"
261
258
  },
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:7936624f90412a4ec9f8ad90e18d96a7475c1d9ff0046d30b3c28d9b444ec620
3
- size 36680
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:fb7b5b33d29a1563781735b24728ab0623702f0d621ebb0867052297e30706fb
3
- size 27534
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:75a94e19b2f3e92d9cd9b588a9cc693a24e672d3549dcc97c55587f3234671c5
3
- size 29262
@@ -1,54 +0,0 @@
1
- "use strict";
2
-
3
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
4
- Object.defineProperty(exports, "__esModule", {
5
- value: true
6
- });
7
- exports.default = void 0;
8
- var _react = require("react");
9
- var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
10
- var _rovo = require("../../../utils/rovo");
11
- var _helpers = require("../../helpers");
12
- var _store = require("../../store");
13
- var _useRovoConfig2 = _interopRequireDefault(require("../use-rovo-config"));
14
- var ELIGIBLE_EXTENSION_KEYS = new Set(['slack-object-provider', 'google-object-provider', 'onedrive-object-provider', 'github-object-provider', 'ms-teams-object-provider', 'gitlab-object-provider', 'salesforce-object-provider']);
15
- var NOT_ENABLED_RESULT = {
16
- isEnabled: false
17
- };
18
-
19
- /**
20
- * Returns whether the rovogrowth-640-inline-action-nudge-exp experiment
21
- * is enabled for the current user and link context.
22
- *
23
- * All eligibility criteria are consolidated here:
24
- * 1. Rovo chat must be enabled for the tenant.
25
- * 2. The consumer must have opted in via actionOptions.rovoChatAction.optIn.
26
- * 3. The link must support the RovoActions feature.
27
- * 4. The extension key must be one of the supported options.
28
- * 5. The experiment value must be true (via tmp-editor-statsig).
29
- *
30
- * The extension key is derived from the card store via the resolved URL,
31
- * so callers don't need to thread it as a prop.
32
- */
33
- var useInlineActionNudgeExperiment = function useInlineActionNudgeExperiment(url, showHoverPreview, actionOptions) {
34
- var _actionOptions$rovoCh, _actionOptions$rovoCh2;
35
- var _useRovoConfig = (0, _useRovoConfig2.default)(),
36
- rovoConfig = _useRovoConfig.rovoOptions;
37
- var isRovoChatEnabled = (0, _rovo.getIsRovoChatEnabled)(rovoConfig);
38
- var cardState = (0, _store.useSmartCardState)(url !== null && url !== void 0 ? url : '');
39
- var extensionKey = (0, _helpers.getExtensionKey)(cardState.details);
40
- var isRovoChatActionOptedIn = (_actionOptions$rovoCh = actionOptions === null || actionOptions === void 0 || (_actionOptions$rovoCh2 = actionOptions.rovoChatAction) === null || _actionOptions$rovoCh2 === void 0 ? void 0 : _actionOptions$rovoCh2.optIn) !== null && _actionOptions$rovoCh !== void 0 ? _actionOptions$rovoCh : false;
41
- return (0, _react.useMemo)(function () {
42
- if (!isRovoChatEnabled || !showHoverPreview || !url || !isRovoChatActionOptedIn) {
43
- return NOT_ENABLED_RESULT;
44
- }
45
- if (!extensionKey || !ELIGIBLE_EXTENSION_KEYS.has(extensionKey)) {
46
- return NOT_ENABLED_RESULT;
47
- }
48
- var isEnabled = (0, _expValEquals.expValEquals)('rovogrowth-640-inline-action-nudge-exp', 'isEnabled', true);
49
- return {
50
- isEnabled: isEnabled
51
- };
52
- }, [isRovoChatEnabled, extensionKey, showHoverPreview, url, isRovoChatActionOptedIn]);
53
- };
54
- var _default = exports.default = useInlineActionNudgeExperiment;
@@ -1,15 +0,0 @@
1
- ._11c8wadc{font:var(--ds-font-body-small,normal 400 9pt/1pc "Atlassian Sans",ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,"Helvetica Neue",sans-serif)}
2
- ._zulp1b66{gap:var(--ds-space-050,4px)}
3
- ._zulputpp{gap:var(--ds-space-150,9pt)}
4
- ._18u0v77o{margin-left:var(--ds-space-025,2px)}
5
- ._19bv1b66{padding-left:var(--ds-space-050,4px)}
6
- ._1bsb1osq{width:100%}
7
- ._1e0c1txw{display:flex}
8
- ._1wpz1fhb{align-self:stretch}
9
- ._2lx21bp4{flex-direction:column}
10
- ._4cvr1h6o{align-items:center}
11
- ._4t3it94y{height:1px}
12
- ._bfhk1l7x{background-color:var(--ds-border,#0b120e24)}
13
- ._k48p1wq8{font-weight:var(--ds-font-weight-medium,500)}
14
- ._otyrutpp{margin-bottom:var(--ds-space-150,9pt)}
15
- ._syazazsu{color:var(--ds-text-subtle,#505258)}
@@ -1,44 +0,0 @@
1
- /* ask-rovo-section-header.tsx generated by @compiled/babel-plugin v0.39.1 */
2
- "use strict";
3
-
4
- var _interopRequireDefault = require("@babel/runtime/helpers/interopRequireDefault");
5
- var _typeof = require("@babel/runtime/helpers/typeof");
6
- Object.defineProperty(exports, "__esModule", {
7
- value: true
8
- });
9
- exports.default = void 0;
10
- require("./ask-rovo-section-header.compiled.css");
11
- var React = _interopRequireWildcard(require("react"));
12
- var _runtime = require("@compiled/react/runtime");
13
- var _reactIntl = require("react-intl");
14
- var _messages = require("../../../../../messages");
15
- var _rovoHexLogo = _interopRequireDefault(require("../../../assets/rovo-hex-logo"));
16
- function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
17
- var sectionHeaderStyles = null;
18
- var sectionHeaderDividerStyles = null;
19
- var sectionHeaderRowStyles = null;
20
- var sectionHeaderLabelStyles = null;
21
- /**
22
- * "Ask Rovo" section header rendered above the prompt action pill buttons in
23
- * the rovogrowth-640-inline-action-nudge-exp pill variant.
24
- *
25
- * Renders a full-width 1px divider followed by a row containing the colourful
26
- * Rovo hex logo and the "Ask Rovo" label.
27
- */
28
- var AskRovoSectionHeader = function AskRovoSectionHeader(_ref) {
29
- var testId = _ref.testId;
30
- var intl = (0, _reactIntl.useIntl)();
31
- return /*#__PURE__*/React.createElement("div", {
32
- "data-testid": testId,
33
- className: (0, _runtime.ax)(["_zulputpp _1e0c1txw _2lx21bp4 _otyrutpp _18u0v77o _1bsb1osq _1wpz1fhb"])
34
- }, /*#__PURE__*/React.createElement("div", {
35
- role: "separator",
36
- "aria-orientation": "horizontal",
37
- className: (0, _runtime.ax)(["_4t3it94y _1bsb1osq _bfhk1l7x"])
38
- }), /*#__PURE__*/React.createElement("div", {
39
- className: (0, _runtime.ax)(["_zulp1b66 _1e0c1txw _4cvr1h6o _19bv1b66"])
40
- }, /*#__PURE__*/React.createElement(_rovoHexLogo.default, null), /*#__PURE__*/React.createElement("span", {
41
- className: (0, _runtime.ax)(["_11c8wadc _syazazsu _k48p1wq8"])
42
- }, intl.formatMessage(_messages.messages.rovo_chat_action_section_header))));
43
- };
44
- var _default = exports.default = AskRovoSectionHeader;
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:7936624f90412a4ec9f8ad90e18d96a7475c1d9ff0046d30b3c28d9b444ec620
3
- size 36680
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:fb7b5b33d29a1563781735b24728ab0623702f0d621ebb0867052297e30706fb
3
- size 27534
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:75a94e19b2f3e92d9cd9b588a9cc693a24e672d3549dcc97c55587f3234671c5
3
- size 29262
@@ -1,48 +0,0 @@
1
- import { useMemo } from 'react';
2
- import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
3
- import { getIsRovoChatEnabled } from '../../../utils/rovo';
4
- import { getExtensionKey } from '../../helpers';
5
- import { useSmartCardState } from '../../store';
6
- import useRovoConfig from '../use-rovo-config';
7
- const ELIGIBLE_EXTENSION_KEYS = new Set(['slack-object-provider', 'google-object-provider', 'onedrive-object-provider', 'github-object-provider', 'ms-teams-object-provider', 'gitlab-object-provider', 'salesforce-object-provider']);
8
- const NOT_ENABLED_RESULT = {
9
- isEnabled: false
10
- };
11
-
12
- /**
13
- * Returns whether the rovogrowth-640-inline-action-nudge-exp experiment
14
- * is enabled for the current user and link context.
15
- *
16
- * All eligibility criteria are consolidated here:
17
- * 1. Rovo chat must be enabled for the tenant.
18
- * 2. The consumer must have opted in via actionOptions.rovoChatAction.optIn.
19
- * 3. The link must support the RovoActions feature.
20
- * 4. The extension key must be one of the supported options.
21
- * 5. The experiment value must be true (via tmp-editor-statsig).
22
- *
23
- * The extension key is derived from the card store via the resolved URL,
24
- * so callers don't need to thread it as a prop.
25
- */
26
- const useInlineActionNudgeExperiment = (url, showHoverPreview, actionOptions) => {
27
- var _actionOptions$rovoCh, _actionOptions$rovoCh2;
28
- const {
29
- rovoOptions: rovoConfig
30
- } = useRovoConfig();
31
- const isRovoChatEnabled = getIsRovoChatEnabled(rovoConfig);
32
- const cardState = useSmartCardState(url !== null && url !== void 0 ? url : '');
33
- const extensionKey = getExtensionKey(cardState.details);
34
- const isRovoChatActionOptedIn = (_actionOptions$rovoCh = actionOptions === null || actionOptions === void 0 ? void 0 : (_actionOptions$rovoCh2 = actionOptions.rovoChatAction) === null || _actionOptions$rovoCh2 === void 0 ? void 0 : _actionOptions$rovoCh2.optIn) !== null && _actionOptions$rovoCh !== void 0 ? _actionOptions$rovoCh : false;
35
- return useMemo(() => {
36
- if (!isRovoChatEnabled || !showHoverPreview || !url || !isRovoChatActionOptedIn) {
37
- return NOT_ENABLED_RESULT;
38
- }
39
- if (!extensionKey || !ELIGIBLE_EXTENSION_KEYS.has(extensionKey)) {
40
- return NOT_ENABLED_RESULT;
41
- }
42
- const isEnabled = expValEquals('rovogrowth-640-inline-action-nudge-exp', 'isEnabled', true);
43
- return {
44
- isEnabled
45
- };
46
- }, [isRovoChatEnabled, extensionKey, showHoverPreview, url, isRovoChatActionOptedIn]);
47
- };
48
- export default useInlineActionNudgeExperiment;
@@ -1,15 +0,0 @@
1
- ._11c8wadc{font:var(--ds-font-body-small,normal 400 9pt/1pc "Atlassian Sans",ui-sans-serif,-apple-system,BlinkMacSystemFont,"Segoe UI",Ubuntu,"Helvetica Neue",sans-serif)}
2
- ._zulp1b66{gap:var(--ds-space-050,4px)}
3
- ._zulputpp{gap:var(--ds-space-150,9pt)}
4
- ._18u0v77o{margin-left:var(--ds-space-025,2px)}
5
- ._19bv1b66{padding-left:var(--ds-space-050,4px)}
6
- ._1bsb1osq{width:100%}
7
- ._1e0c1txw{display:flex}
8
- ._1wpz1fhb{align-self:stretch}
9
- ._2lx21bp4{flex-direction:column}
10
- ._4cvr1h6o{align-items:center}
11
- ._4t3it94y{height:1px}
12
- ._bfhk1l7x{background-color:var(--ds-border,#0b120e24)}
13
- ._k48p1wq8{font-weight:var(--ds-font-weight-medium,500)}
14
- ._otyrutpp{margin-bottom:var(--ds-space-150,9pt)}
15
- ._syazazsu{color:var(--ds-text-subtle,#505258)}