@atlaskit/smart-card 46.22.2 → 46.23.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (155) hide show
  1. package/CHANGELOG.md +27 -0
  2. package/analytics.spec.yaml +23 -0
  3. package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/block-card-google-sheets-with-remix-action-and-rovo-chat-action-opted-out--default.png +3 -0
  4. package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/block-card-google-sheets-with-remix-action-experiment-on---default.png +3 -0
  5. package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/embed-card-google-sheets-with-remix-action-and-rovo-chat-action-opted-out--default.png +3 -0
  6. package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/embed-card-google-sheets-with-remix-action-experiment-on---default.png +3 -0
  7. package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/inline-card-google-sheets-with-remix-action-and-rovo-chat-action-opted-out--default.png +3 -0
  8. package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/inline-card-google-sheets-with-remix-action-experiment-on---default.png +3 -0
  9. package/dist/cjs/constants.js +2 -0
  10. package/dist/cjs/extractors/flexible/actions/extract-remix-action.js +53 -0
  11. package/dist/cjs/extractors/flexible/actions/index.js +11 -2
  12. package/dist/cjs/extractors/flexible/index.js +7 -3
  13. package/dist/cjs/messages.js +4 -9
  14. package/dist/cjs/utils/analytics/analytics.js +1 -1
  15. package/dist/cjs/utils/is-remix-action-enabled.js +48 -0
  16. package/dist/cjs/utils/use-remix-action-exposure.js +16 -0
  17. package/dist/cjs/view/BlockCard/views/ResolvedView.js +18 -13
  18. package/dist/cjs/view/EmbedCard/components/rovo-actions-footer/index.js +58 -10
  19. package/dist/cjs/view/EmbedCard/index.js +2 -0
  20. package/dist/cjs/view/EmbedCard/views/ResolvedView.js +23 -7
  21. package/dist/cjs/view/FlexibleCard/components/actions/remix-action/index.js +81 -0
  22. package/dist/cjs/view/FlexibleCard/components/blocks/action-block/index.js +3 -2
  23. package/dist/cjs/view/FlexibleCard/components/blocks/action-group/action-group-item/index.js +2 -1
  24. package/dist/cjs/view/FlexibleCard/components/blocks/action-group/index.js +5 -1
  25. package/dist/cjs/view/FlexibleCard/components/blocks/footer-block/resolved/index.js +10 -3
  26. package/dist/cjs/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +1 -1
  27. package/dist/cjs/view/FlexibleCard/index.js +9 -3
  28. package/dist/cjs/view/InlineCard/ResolvedView/InlineCardResolvedViewFunctional.js +9 -1
  29. package/dist/cjs/view/InlineCard/common/inline-card-action/index.js +70 -0
  30. package/dist/cjs/view/InlineCard/common/remix-action/index.compiled.css +5 -0
  31. package/dist/cjs/view/InlineCard/common/remix-action/index.js +77 -0
  32. package/dist/cjs/view/InlineCard/common/rovo-actions-cta/index.js +1 -24
  33. package/dist/cjs/view/LinkUrl/index.js +1 -1
  34. package/dist/cjs/view/common/rovo-chat-utils/index.js +0 -28
  35. package/dist/cjs/view/common/rovo-post-auth-prompts/index.js +1 -16
  36. package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/block-card-google-sheets-with-remix-action-and-rovo-chat-action-opted-out--default.png +3 -0
  37. package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/block-card-google-sheets-with-remix-action-experiment-on---default.png +3 -0
  38. package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/embed-card-google-sheets-with-remix-action-and-rovo-chat-action-opted-out--default.png +3 -0
  39. package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/embed-card-google-sheets-with-remix-action-experiment-on---default.png +3 -0
  40. package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/inline-card-google-sheets-with-remix-action-and-rovo-chat-action-opted-out--default.png +3 -0
  41. package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/inline-card-google-sheets-with-remix-action-experiment-on---default.png +3 -0
  42. package/dist/es2019/constants.js +2 -0
  43. package/dist/es2019/extractors/flexible/actions/extract-remix-action.js +48 -0
  44. package/dist/es2019/extractors/flexible/actions/index.js +12 -0
  45. package/dist/es2019/extractors/flexible/index.js +4 -0
  46. package/dist/es2019/messages.js +4 -9
  47. package/dist/es2019/utils/analytics/analytics.js +1 -1
  48. package/dist/es2019/utils/is-remix-action-enabled.js +39 -0
  49. package/dist/es2019/utils/use-remix-action-exposure.js +11 -0
  50. package/dist/es2019/view/BlockCard/views/ResolvedView.js +19 -14
  51. package/dist/es2019/view/EmbedCard/components/rovo-actions-footer/index.js +43 -11
  52. package/dist/es2019/view/EmbedCard/index.js +2 -0
  53. package/dist/es2019/view/EmbedCard/views/ResolvedView.js +22 -7
  54. package/dist/es2019/view/FlexibleCard/components/actions/remix-action/index.js +54 -0
  55. package/dist/es2019/view/FlexibleCard/components/blocks/action-block/index.js +3 -1
  56. package/dist/es2019/view/FlexibleCard/components/blocks/action-group/action-group-item/index.js +2 -0
  57. package/dist/es2019/view/FlexibleCard/components/blocks/action-group/index.js +4 -1
  58. package/dist/es2019/view/FlexibleCard/components/blocks/footer-block/resolved/index.js +9 -4
  59. package/dist/es2019/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +1 -1
  60. package/dist/es2019/view/FlexibleCard/index.js +8 -1
  61. package/dist/es2019/view/InlineCard/ResolvedView/InlineCardResolvedViewFunctional.js +9 -1
  62. package/dist/es2019/view/InlineCard/common/inline-card-action/index.js +61 -0
  63. package/dist/es2019/view/InlineCard/common/remix-action/index.compiled.css +5 -0
  64. package/dist/es2019/view/InlineCard/common/remix-action/index.js +50 -0
  65. package/dist/es2019/view/InlineCard/common/rovo-actions-cta/index.js +1 -24
  66. package/dist/es2019/view/LinkUrl/index.js +1 -1
  67. package/dist/es2019/view/common/rovo-chat-utils/index.js +0 -26
  68. package/dist/es2019/view/common/rovo-post-auth-prompts/index.js +1 -15
  69. package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/block-card-google-sheets-with-remix-action-and-rovo-chat-action-opted-out--default.png +3 -0
  70. package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/block-card-google-sheets-with-remix-action-experiment-on---default.png +3 -0
  71. package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/embed-card-google-sheets-with-remix-action-and-rovo-chat-action-opted-out--default.png +3 -0
  72. package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/embed-card-google-sheets-with-remix-action-experiment-on---default.png +3 -0
  73. package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/inline-card-google-sheets-with-remix-action-and-rovo-chat-action-opted-out--default.png +3 -0
  74. package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/inline-card-google-sheets-with-remix-action-experiment-on---default.png +3 -0
  75. package/dist/esm/constants.js +2 -0
  76. package/dist/esm/extractors/flexible/actions/extract-remix-action.js +47 -0
  77. package/dist/esm/extractors/flexible/actions/index.js +11 -2
  78. package/dist/esm/extractors/flexible/index.js +7 -3
  79. package/dist/esm/messages.js +4 -9
  80. package/dist/esm/utils/analytics/analytics.js +1 -1
  81. package/dist/esm/utils/is-remix-action-enabled.js +42 -0
  82. package/dist/esm/utils/use-remix-action-exposure.js +11 -0
  83. package/dist/esm/view/BlockCard/views/ResolvedView.js +19 -14
  84. package/dist/esm/view/EmbedCard/components/rovo-actions-footer/index.js +59 -11
  85. package/dist/esm/view/EmbedCard/index.js +2 -0
  86. package/dist/esm/view/EmbedCard/views/ResolvedView.js +23 -7
  87. package/dist/esm/view/FlexibleCard/components/actions/remix-action/index.js +72 -0
  88. package/dist/esm/view/FlexibleCard/components/blocks/action-block/index.js +3 -2
  89. package/dist/esm/view/FlexibleCard/components/blocks/action-group/action-group-item/index.js +2 -1
  90. package/dist/esm/view/FlexibleCard/components/blocks/action-group/index.js +5 -1
  91. package/dist/esm/view/FlexibleCard/components/blocks/footer-block/resolved/index.js +11 -4
  92. package/dist/esm/view/FlexibleCard/components/blocks/hover-card-footer-block/index.js +1 -1
  93. package/dist/esm/view/FlexibleCard/index.js +9 -3
  94. package/dist/esm/view/InlineCard/ResolvedView/InlineCardResolvedViewFunctional.js +9 -1
  95. package/dist/esm/view/InlineCard/common/inline-card-action/index.js +61 -0
  96. package/dist/esm/view/InlineCard/common/remix-action/index.compiled.css +5 -0
  97. package/dist/esm/view/InlineCard/common/remix-action/index.js +70 -0
  98. package/dist/esm/view/InlineCard/common/rovo-actions-cta/index.js +1 -24
  99. package/dist/esm/view/LinkUrl/index.js +1 -1
  100. package/dist/esm/view/common/rovo-chat-utils/index.js +0 -28
  101. package/dist/esm/view/common/rovo-post-auth-prompts/index.js +1 -16
  102. package/dist/types/common/analytics/generated/analytics.types.d.ts +17 -2
  103. package/dist/types/constants.d.ts +2 -0
  104. package/dist/types/extractors/flexible/actions/extract-remix-action.d.ts +15 -0
  105. package/dist/types/extractors/flexible/actions/index.d.ts +3 -1
  106. package/dist/types/extractors/flexible/index.d.ts +1 -1
  107. package/dist/types/messages.d.ts +1 -1
  108. package/dist/types/state/flexible-ui-context/types.d.ts +5 -0
  109. package/dist/types/state/hooks/use-invoke-client-action/types.d.ts +1 -1
  110. package/dist/types/utils/is-remix-action-enabled.d.ts +15 -0
  111. package/dist/types/utils/use-remix-action-exposure.d.ts +2 -0
  112. package/dist/types/view/Card/types.d.ts +10 -1
  113. package/dist/types/view/EmbedCard/components/rovo-actions-footer/index.d.ts +5 -4
  114. package/dist/types/view/EmbedCard/views/ResolvedView.d.ts +2 -0
  115. package/dist/types/view/FlexibleCard/components/actions/remix-action/index.d.ts +4 -0
  116. package/dist/types/view/FlexibleCard/components/blocks/action-group/index.d.ts +1 -1
  117. package/dist/types/view/FlexibleCard/components/blocks/action-group/types.d.ts +4 -0
  118. package/dist/types/view/FlexibleCard/components/blocks/types.d.ts +8 -2
  119. package/dist/types/view/FlexibleCard/types.d.ts +2 -1
  120. package/dist/types/view/InlineCard/common/inline-card-action/index.d.ts +11 -0
  121. package/dist/types/view/InlineCard/common/remix-action/index.d.ts +9 -0
  122. package/dist/types/view/common/rovo-chat-utils/index.d.ts +1 -2
  123. package/dist/types/view/common/rovo-post-auth-prompts/index.d.ts +1 -10
  124. package/package.json +2 -2
  125. package/dist/cjs/__tests__/vr-tests/__snapshots__/embed-card/embed-card-forbidden-view--default.png +0 -3
  126. package/dist/cjs/__tests__/vr-tests/__snapshots__/embed-card/embed-card-not-found-default--default.png +0 -3
  127. package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/block-card-google-sheets-with-visualize-rovo-action-experiment-on---default.png +0 -3
  128. package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/embed-card-google-sheets-with-visualize-rovo-action-experiment-on---default.png +0 -3
  129. package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/inline-card-google-sheets-with-visualize-rovo-action-experiment-on---default.png +0 -3
  130. package/dist/cjs/__tests__/vr-tests/__snapshots__/inline-card/inline-card-forbidden-view-with-default-legacy-icon--default.png +0 -3
  131. package/dist/cjs/utils/is-rovo-chat-action-visualize-enabled.js +0 -43
  132. package/dist/es2019/__tests__/vr-tests/__snapshots__/embed-card/embed-card-forbidden-view--default.png +0 -3
  133. package/dist/es2019/__tests__/vr-tests/__snapshots__/embed-card/embed-card-not-found-default--default.png +0 -3
  134. package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/block-card-google-sheets-with-visualize-rovo-action-experiment-on---default.png +0 -3
  135. package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/embed-card-google-sheets-with-visualize-rovo-action-experiment-on---default.png +0 -3
  136. package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/inline-card-google-sheets-with-visualize-rovo-action-experiment-on---default.png +0 -3
  137. package/dist/es2019/__tests__/vr-tests/__snapshots__/inline-card/inline-card-forbidden-view-with-default-legacy-icon--default.png +0 -3
  138. package/dist/es2019/utils/is-rovo-chat-action-visualize-enabled.js +0 -34
  139. package/dist/esm/__tests__/vr-tests/__snapshots__/embed-card/embed-card-forbidden-view--default.png +0 -3
  140. package/dist/esm/__tests__/vr-tests/__snapshots__/embed-card/embed-card-not-found-default--default.png +0 -3
  141. package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/block-card-google-sheets-with-visualize-rovo-action-experiment-on---default.png +0 -3
  142. package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/embed-card-google-sheets-with-visualize-rovo-action-experiment-on---default.png +0 -3
  143. package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/inline-card-google-sheets-with-visualize-rovo-action-experiment-on---default.png +0 -3
  144. package/dist/esm/__tests__/vr-tests/__snapshots__/inline-card/inline-card-forbidden-view-with-default-legacy-icon--default.png +0 -3
  145. package/dist/esm/utils/is-rovo-chat-action-visualize-enabled.js +0 -37
  146. package/dist/types/utils/is-rovo-chat-action-visualize-enabled.d.ts +0 -18
  147. /package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/{block-card-google-sheets-without-visualize-rovo-action-experiment-off---default.png → block-card-google-sheets-without-remix-action-experiment-off---default.png} +0 -0
  148. /package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/{embed-card-google-sheets-without-visualize-rovo-action-experiment-off---default.png → embed-card-google-sheets-without-remix-action-experiment-off---default.png} +0 -0
  149. /package/dist/cjs/__tests__/vr-tests/__snapshots__/google-sheets-visualize/{inline-card-google-sheets-without-visualize-rovo-action-experiment-off---default.png → inline-card-google-sheets-without-remix-action-experiment-off---default.png} +0 -0
  150. /package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/{block-card-google-sheets-without-visualize-rovo-action-experiment-off---default.png → block-card-google-sheets-without-remix-action-experiment-off---default.png} +0 -0
  151. /package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/{embed-card-google-sheets-without-visualize-rovo-action-experiment-off---default.png → embed-card-google-sheets-without-remix-action-experiment-off---default.png} +0 -0
  152. /package/dist/es2019/__tests__/vr-tests/__snapshots__/google-sheets-visualize/{inline-card-google-sheets-without-visualize-rovo-action-experiment-off---default.png → inline-card-google-sheets-without-remix-action-experiment-off---default.png} +0 -0
  153. /package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/{block-card-google-sheets-without-visualize-rovo-action-experiment-off---default.png → block-card-google-sheets-without-remix-action-experiment-off---default.png} +0 -0
  154. /package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/{embed-card-google-sheets-without-visualize-rovo-action-experiment-off---default.png → embed-card-google-sheets-without-remix-action-experiment-off---default.png} +0 -0
  155. /package/dist/esm/__tests__/vr-tests/__snapshots__/google-sheets-visualize/{inline-card-google-sheets-without-visualize-rovo-action-experiment-off---default.png → inline-card-google-sheets-without-remix-action-experiment-off---default.png} +0 -0
@@ -1,6 +1,7 @@
1
1
  import { type ReactNode, type Ref } from 'react';
2
2
  import type { LozengeProps as AtlaskitLozengeProps } from '@atlaskit/lozenge/lozenge';
3
- import { type ActionName, type CardDisplay, type ElementName, type SmartLinkDirection, type SmartLinkSize } from '../../../../constants';
3
+ import { type ActionName, type InternalActionName, type CardDisplay, type ElementName, type SmartLinkDirection, type SmartLinkSize } from '../../../../constants';
4
+ import type { RovoChatPromptKey } from '../../../common/rovo-chat-utils';
4
5
  import { type ActionProps } from '../actions/action/types';
5
6
  import type { AssignedToGroupElementProps } from '../elements/assigned-to-group-element';
6
7
  import type { BaseAvatarGroupElementProps } from '../elements/common/base-avatar-group-element';
@@ -176,6 +177,7 @@ export type BaseDataActionItem = {
176
177
  */
177
178
  export type NamedDataActionItem = BaseDataActionItem & {
178
179
  name: ActionName.FollowAction | ActionName.PreviewAction | ActionName.DownloadAction | ActionName.AutomationAction | ActionName.CopyLinkAction | ActionName.RovoChatAction;
180
+ prompts?: RovoChatPromptKey[];
179
181
  } & Pick<ActionProps, 'iconSize'>;
180
182
  /**
181
183
  * This represents an action that does not fetch data where Icon and Content are provided implicitly.
@@ -192,7 +194,10 @@ export type CustomActionItem = BaseActionItem & {
192
194
  href?: string;
193
195
  name: ActionName.CustomAction;
194
196
  } & ((Required<Pick<ActionProps, 'icon' | 'iconPosition'>> & Pick<ActionProps, 'content'>) | ((Required<Pick<ActionProps, 'content'>> & Pick<ActionProps, 'icon' | 'iconPosition'>) & Pick<ActionProps, 'tooltipMessage'>));
195
- export type ActionItem = (NamedActionItem | NamedDataActionItem | CustomActionItem) & {
197
+ type InternalDataActionItem = Omit<BaseDataActionItem, 'name'> & {
198
+ name: InternalActionName.RemixAction;
199
+ } & Pick<ActionProps, 'iconSize'>;
200
+ export type ActionItem = (NamedActionItem | NamedDataActionItem | InternalDataActionItem | CustomActionItem) & {
196
201
  entryPointWrapper?: React.FC<{
197
202
  children: React.ReactNode;
198
203
  }>;
@@ -467,3 +472,4 @@ export type UserAttributes = {
467
472
  export type HostName = {
468
473
  name: ElementName.HostName;
469
474
  };
475
+ export {};
@@ -1,5 +1,5 @@
1
1
  import { type MessageDescriptor } from 'react-intl';
2
- import type { CardProviderRenderers } from '@atlaskit/link-provider/types';
2
+ import type { CardProviderRenderers, LinkProviderRemixPlugin } from '@atlaskit/link-provider/types';
3
3
  import type { CardState } from '@atlaskit/linking-common/store';
4
4
  import type { ProductType } from '@atlaskit/linking-common/types';
5
5
  import type { SmartLinkResponse } from '@atlaskit/linking-types/smart-link';
@@ -211,6 +211,7 @@ export type ExtractFlexibleUiDataContextParams = Pick<FlexibleCardProps, 'appear
211
211
  url: string;
212
212
  }) => void;
213
213
  product?: ProductType;
214
+ remix?: LinkProviderRemixPlugin;
214
215
  resolve?: ResolveFunction;
215
216
  response?: SmartLinkResponse;
216
217
  rovoConfig?: RovoConfig;
@@ -0,0 +1,11 @@
1
+ import React from 'react';
2
+ import type { InternalCardActionOptions } from '../../../Card/types';
3
+ type InlineCardActionProps = {
4
+ actionOptions?: InternalCardActionOptions;
5
+ id?: string;
6
+ showHoverPreview?: boolean;
7
+ testId?: string;
8
+ url?: string;
9
+ };
10
+ export declare const InlineCardAction: ({ testId, ...props }: InlineCardActionProps) => React.JSX.Element | null;
11
+ export {};
@@ -0,0 +1,9 @@
1
+ import React from 'react';
2
+ import type { LinkProviderRemixPlugin } from '@atlaskit/link-provider/types';
3
+ import type { RemixActionData } from '../../../../state/flexible-ui-context/types';
4
+ declare const InlineRemixAction: ({ data, remix, testId, }: {
5
+ data: RemixActionData;
6
+ remix: LinkProviderRemixPlugin;
7
+ testId?: string;
8
+ }) => React.JSX.Element;
9
+ export default InlineRemixAction;
@@ -20,8 +20,7 @@ export declare enum RovoChatPromptKey {
20
20
  SUMMARIZE_PRESENTATION = "summarize-presentation",
21
21
  EXPLAIN_CODE = "explain-code",
22
22
  CATCH_UP = "catch-up",
23
- SALESFORCE_PREP = "salesforce-prep",
24
- VISUALIZE = "visualize"
23
+ SALESFORCE_PREP = "salesforce-prep"
25
24
  }
26
25
  type PromptActionProps = {
27
26
  cardAppearance?: CardDisplay;
@@ -1,14 +1,5 @@
1
- import type { JsonLd } from '@atlaskit/json-ld-types/jsonld';
2
- import type { ProductType } from '@atlaskit/linking-common/types';
3
1
  import { RovoChatPromptKey } from '../rovo-chat-utils';
4
2
  export type RovoPostAuthPromptKeysOptions = {
5
3
  extensionKey?: string;
6
- /**
7
- * Whether the Rovo chat action will be shown for the link. Prompt experiments
8
- * (e.g. Visualize) are only evaluated, firing exposure, when this is true.
9
- */
10
- isRovoChatActionShown?: boolean;
11
- product?: ProductType;
12
- response?: JsonLd.Response;
13
4
  };
14
- export declare const getRovoPostAuthPromptKeys: ({ extensionKey, isRovoChatActionShown, product, response, }: RovoPostAuthPromptKeysOptions) => RovoChatPromptKey[];
5
+ export declare const getRovoPostAuthPromptKeys: ({ extensionKey, }: RovoPostAuthPromptKeysOptions) => RovoChatPromptKey[];
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/smart-card",
3
- "version": "46.22.2",
3
+ "version": "46.23.0",
4
4
  "description": "Smart card component",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -93,7 +93,7 @@
93
93
  "@atlaskit/textfield": "^11.0.0",
94
94
  "@atlaskit/theme": "^28.2.0",
95
95
  "@atlaskit/tile": "^5.0.0",
96
- "@atlaskit/tmp-editor-statsig": "^279.0.0",
96
+ "@atlaskit/tmp-editor-statsig": "^280.0.0",
97
97
  "@atlaskit/tokens": "^20.15.0",
98
98
  "@atlaskit/tooltip": "^24.4.0",
99
99
  "@atlaskit/top-layer": "^8.2.0",
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:415a4f35e974e2fb6b461d2fc194c43919a240a61689d7a6ff9d74c310ec49c2
3
- size 23132
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:58436125a822a77b05d46dde77e47c6f7bcaf54d3faccf63c01e810670e37c4d
3
- size 27268
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:0ee0b8e92f9b9c2b3ef643ddd4e755acaff8fd52fb3006b4f413390039d170dc
3
- size 15497
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:1bf87dae2a7cbfdef18c8a87fb2c733aa37ed1f1b073966035c98a06dc7c9033
3
- size 13712
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:db641c996de33386cdc38f5196e715e29fb02c19557707ee2ff3e7b7298b3327
3
- size 3898
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:dac320cae16598f66f3cbae31245519311ab708f1b4b1eb857655d40acd1b3fd
3
- size 4372
@@ -1,43 +0,0 @@
1
- "use strict";
2
-
3
- Object.defineProperty(exports, "__esModule", {
4
- value: true
5
- });
6
- exports.isRovoChatActionVisualizeEnabled = void 0;
7
- var _expVal = require("@atlaskit/platform-feature-experiments/exp-val");
8
- var _fg = require("@atlaskit/platform-feature-flags/fg");
9
- /**
10
- * Rollout state only (kill switch, then experiment). Evaluating the experiment
11
- * fires exposure, so this must run after every business rule has passed.
12
- * Remove this function on experiment cleanup; the business rules stay.
13
- */
14
- var isVisualizeExperimentEnabled = function isVisualizeExperimentEnabled() {
15
- return (0, _fg.fg)('platform_sl_3p_auth_visualize_killswitch') && (0, _expVal.expVal)('platform_sl_3p_auth_visualize_exp', 'isEnabled', false);
16
- };
17
-
18
- /**
19
- * `@type` is a string or string array per JSON-LD, but it comes from the network, so guard
20
- * against any other shape rather than calling `.includes` on it directly.
21
- */
22
- var isGoogleSheetsType = function isGoogleSheetsType(response) {
23
- var _response$data;
24
- var type = response === null || response === void 0 || (_response$data = response.data) === null || _response$data === void 0 ? void 0 : _response$data['@type'];
25
- var types = Array.isArray(type) ? type : [type];
26
- return types.includes('schema:SpreadsheetDigitalDocument');
27
- };
28
-
29
- /**
30
- * Whether the Rovo chat "Visualize" action is offered for a resolved link.
31
- *
32
- * Business rules: Google Sheets links in Confluence.
33
- *
34
- * Callers must only call this once the Rovo chat action will be shown for the
35
- * link (resolved, Rovo chat enabled, opted in and not hidden), so experiment
36
- * exposure matches what the user sees.
37
- */
38
- var isRovoChatActionVisualizeEnabled = exports.isRovoChatActionVisualizeEnabled = function isRovoChatActionVisualizeEnabled(_ref) {
39
- var extensionKey = _ref.extensionKey,
40
- product = _ref.product,
41
- response = _ref.response;
42
- return product === 'CONFLUENCE' && extensionKey === 'google-object-provider' && isGoogleSheetsType(response) && isVisualizeExperimentEnabled();
43
- };
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:415a4f35e974e2fb6b461d2fc194c43919a240a61689d7a6ff9d74c310ec49c2
3
- size 23132
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:58436125a822a77b05d46dde77e47c6f7bcaf54d3faccf63c01e810670e37c4d
3
- size 27268
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:0ee0b8e92f9b9c2b3ef643ddd4e755acaff8fd52fb3006b4f413390039d170dc
3
- size 15497
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:1bf87dae2a7cbfdef18c8a87fb2c733aa37ed1f1b073966035c98a06dc7c9033
3
- size 13712
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:db641c996de33386cdc38f5196e715e29fb02c19557707ee2ff3e7b7298b3327
3
- size 3898
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:dac320cae16598f66f3cbae31245519311ab708f1b4b1eb857655d40acd1b3fd
3
- size 4372
@@ -1,34 +0,0 @@
1
- import { expVal } from '@atlaskit/platform-feature-experiments/exp-val';
2
- import { fg } from '@atlaskit/platform-feature-flags/fg';
3
- /**
4
- * Rollout state only (kill switch, then experiment). Evaluating the experiment
5
- * fires exposure, so this must run after every business rule has passed.
6
- * Remove this function on experiment cleanup; the business rules stay.
7
- */
8
- const isVisualizeExperimentEnabled = () => fg('platform_sl_3p_auth_visualize_killswitch') && expVal('platform_sl_3p_auth_visualize_exp', 'isEnabled', false);
9
-
10
- /**
11
- * `@type` is a string or string array per JSON-LD, but it comes from the network, so guard
12
- * against any other shape rather than calling `.includes` on it directly.
13
- */
14
- const isGoogleSheetsType = response => {
15
- var _response$data;
16
- const type = response === null || response === void 0 ? void 0 : (_response$data = response.data) === null || _response$data === void 0 ? void 0 : _response$data['@type'];
17
- const types = Array.isArray(type) ? type : [type];
18
- return types.includes('schema:SpreadsheetDigitalDocument');
19
- };
20
-
21
- /**
22
- * Whether the Rovo chat "Visualize" action is offered for a resolved link.
23
- *
24
- * Business rules: Google Sheets links in Confluence.
25
- *
26
- * Callers must only call this once the Rovo chat action will be shown for the
27
- * link (resolved, Rovo chat enabled, opted in and not hidden), so experiment
28
- * exposure matches what the user sees.
29
- */
30
- export const isRovoChatActionVisualizeEnabled = ({
31
- extensionKey,
32
- product,
33
- response
34
- }) => product === 'CONFLUENCE' && extensionKey === 'google-object-provider' && isGoogleSheetsType(response) && isVisualizeExperimentEnabled();
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:415a4f35e974e2fb6b461d2fc194c43919a240a61689d7a6ff9d74c310ec49c2
3
- size 23132
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:58436125a822a77b05d46dde77e47c6f7bcaf54d3faccf63c01e810670e37c4d
3
- size 27268
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:0ee0b8e92f9b9c2b3ef643ddd4e755acaff8fd52fb3006b4f413390039d170dc
3
- size 15497
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:1bf87dae2a7cbfdef18c8a87fb2c733aa37ed1f1b073966035c98a06dc7c9033
3
- size 13712
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:db641c996de33386cdc38f5196e715e29fb02c19557707ee2ff3e7b7298b3327
3
- size 3898
@@ -1,3 +0,0 @@
1
- version https://git-lfs.github.com/spec/v1
2
- oid sha256:dac320cae16598f66f3cbae31245519311ab708f1b4b1eb857655d40acd1b3fd
3
- size 4372
@@ -1,37 +0,0 @@
1
- import { expVal } from '@atlaskit/platform-feature-experiments/exp-val';
2
- import { fg } from '@atlaskit/platform-feature-flags/fg';
3
- /**
4
- * Rollout state only (kill switch, then experiment). Evaluating the experiment
5
- * fires exposure, so this must run after every business rule has passed.
6
- * Remove this function on experiment cleanup; the business rules stay.
7
- */
8
- var isVisualizeExperimentEnabled = function isVisualizeExperimentEnabled() {
9
- return fg('platform_sl_3p_auth_visualize_killswitch') && expVal('platform_sl_3p_auth_visualize_exp', 'isEnabled', false);
10
- };
11
-
12
- /**
13
- * `@type` is a string or string array per JSON-LD, but it comes from the network, so guard
14
- * against any other shape rather than calling `.includes` on it directly.
15
- */
16
- var isGoogleSheetsType = function isGoogleSheetsType(response) {
17
- var _response$data;
18
- var type = response === null || response === void 0 || (_response$data = response.data) === null || _response$data === void 0 ? void 0 : _response$data['@type'];
19
- var types = Array.isArray(type) ? type : [type];
20
- return types.includes('schema:SpreadsheetDigitalDocument');
21
- };
22
-
23
- /**
24
- * Whether the Rovo chat "Visualize" action is offered for a resolved link.
25
- *
26
- * Business rules: Google Sheets links in Confluence.
27
- *
28
- * Callers must only call this once the Rovo chat action will be shown for the
29
- * link (resolved, Rovo chat enabled, opted in and not hidden), so experiment
30
- * exposure matches what the user sees.
31
- */
32
- export var isRovoChatActionVisualizeEnabled = function isRovoChatActionVisualizeEnabled(_ref) {
33
- var extensionKey = _ref.extensionKey,
34
- product = _ref.product,
35
- response = _ref.response;
36
- return product === 'CONFLUENCE' && extensionKey === 'google-object-provider' && isGoogleSheetsType(response) && isVisualizeExperimentEnabled();
37
- };
@@ -1,18 +0,0 @@
1
- import type { JsonLd } from '@atlaskit/json-ld-types/jsonld';
2
- import type { ProductType } from '@atlaskit/linking-common/types';
3
- type IsRovoChatActionVisualizeEnabledOptions = {
4
- extensionKey?: string;
5
- product?: ProductType;
6
- response?: JsonLd.Response;
7
- };
8
- /**
9
- * Whether the Rovo chat "Visualize" action is offered for a resolved link.
10
- *
11
- * Business rules: Google Sheets links in Confluence.
12
- *
13
- * Callers must only call this once the Rovo chat action will be shown for the
14
- * link (resolved, Rovo chat enabled, opted in and not hidden), so experiment
15
- * exposure matches what the user sees.
16
- */
17
- export declare const isRovoChatActionVisualizeEnabled: ({ extensionKey, product, response, }: IsRovoChatActionVisualizeEnabledOptions) => boolean;
18
- export {};