@atlaskit/smart-card 32.7.2 → 32.7.3

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 (27) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/analytics.spec.yaml +112 -53
  3. package/dist/cjs/utils/analytics/analytics.js +1 -1
  4. package/dist/cjs/view/CardWithUrl/component.js +26 -9
  5. package/dist/cjs/view/CardWithUrl/loader.js +21 -7
  6. package/dist/cjs/view/HoverCard/components/views/resolved/index.js +35 -8
  7. package/dist/cjs/view/HoverCard/index.js +25 -8
  8. package/dist/cjs/view/LinkUrl/index.js +1 -1
  9. package/dist/es2019/utils/analytics/analytics.js +1 -1
  10. package/dist/es2019/view/CardWithUrl/component.js +26 -9
  11. package/dist/es2019/view/CardWithUrl/loader.js +21 -7
  12. package/dist/es2019/view/HoverCard/components/views/resolved/index.js +33 -9
  13. package/dist/es2019/view/HoverCard/index.js +26 -8
  14. package/dist/es2019/view/LinkUrl/index.js +1 -1
  15. package/dist/esm/utils/analytics/analytics.js +1 -1
  16. package/dist/esm/view/CardWithUrl/component.js +26 -9
  17. package/dist/esm/view/CardWithUrl/loader.js +21 -7
  18. package/dist/esm/view/HoverCard/components/views/resolved/index.js +36 -9
  19. package/dist/esm/view/HoverCard/index.js +25 -8
  20. package/dist/esm/view/LinkUrl/index.js +1 -1
  21. package/dist/types/common/analytics/generated/analytics.types.d.ts +35 -1
  22. package/dist/types/types.d.ts +1 -0
  23. package/dist/types/view/HoverCard/components/views/resolved/index.d.ts +1 -1
  24. package/dist/types-ts4.5/common/analytics/generated/analytics.types.d.ts +35 -1
  25. package/dist/types-ts4.5/types.d.ts +1 -0
  26. package/dist/types-ts4.5/view/HoverCard/components/views/resolved/index.d.ts +1 -1
  27. package/package.json +1 -1
@@ -3,7 +3,7 @@
3
3
  *
4
4
  * Generates Typescript types for analytics events from analytics.spec.yaml
5
5
  *
6
- * @codegen <<SignedSource::f06f113d9e5f9e84ba897b1fbfca3db4>>
6
+ * @codegen <<SignedSource::1e6835b50307a44a077c38d864a2c66e>>
7
7
  * @codegenCommand yarn workspace @atlassian/analytics-tooling run analytics:codegen smart-card
8
8
  */
9
9
  export type PackageMetaDataContextType = {
@@ -61,6 +61,13 @@ export type ButtonClickedShortcutGoToLinkAttributesType = {
61
61
  display: 'inline' | 'block' | 'embed' | 'embedPreview' | 'flexible' | 'hoverCardPreview' | null;
62
62
  resourceType: string | null;
63
63
  };
64
+ export type ButtonClickedIssueStatusUpdateAttributesType = {
65
+ actionType: string | null;
66
+ id: string | null;
67
+ definitionId: string | null;
68
+ display: 'inline' | 'block' | 'embed' | 'embedPreview' | 'flexible' | 'hoverCardPreview' | null;
69
+ resourceType: string | null;
70
+ };
64
71
  export type ButtonClickedAiSummaryAttributesType = {};
65
72
  export type ButtonClickedCopySummaryAttributesType = {};
66
73
  export type SummaryViewedAttributesType = {
@@ -200,6 +207,21 @@ export type ButtonClickedSmartLinkStatusOpenPreviewAttributesType = {};
200
207
  export type ButtonClickedSmartLinkFollowButtonAttributesType = {};
201
208
  export type ButtonClickedStatusUpdateActionAttributesType = {};
202
209
  export type ButtonClickedGetStatusTransitionsActionAttributesType = {};
210
+ export type ButtonClickedEmbedPreviewResizeAttributesType = {
211
+ newSize: 'large' | 'small';
212
+ origin: 'smartLinkCard' | 'smartLinkEmbed' | 'smartLinkInline' | 'smartLinkPreviewHoverCard' | null;
213
+ previousSize: 'large' | 'small';
214
+ };
215
+ export type SmartLinkRenderSuccessAttributesType = {
216
+ display: 'inline' | 'block' | 'embed' | 'embedPreview' | 'flexible' | 'hoverCardPreview';
217
+ definitionId: string | null;
218
+ };
219
+ export type SmartLinkRenderFailedAttributesType = {
220
+ display: 'inline' | 'block' | 'embed' | 'embedPreview' | 'flexible' | 'hoverCardPreview';
221
+ error: Record<string, unknown>;
222
+ errorInfo: Record<string, unknown>;
223
+ id: string | null;
224
+ };
203
225
  export type AnalyticsEventAttributes = {
204
226
  /**
205
227
  * Fired when an copy link is clicked */
@@ -213,6 +235,9 @@ export type AnalyticsEventAttributes = {
213
235
  /**
214
236
  * Fired when an view link is clicked */
215
237
  'ui.button.clicked.shortcutGoToLink': ButtonClickedShortcutGoToLinkAttributesType;
238
+ /**
239
+ * fires an event that represents a user clicking on the preview action button */
240
+ 'ui.button.clicked.issueStatusUpdate': ButtonClickedIssueStatusUpdateAttributesType;
216
241
  /**
217
242
  * fired when an ai summary is clicked */
218
243
  'ui.button.clicked.aiSummary': ButtonClickedAiSummaryAttributesType;
@@ -337,5 +362,14 @@ export type AnalyticsEventAttributes = {
337
362
  'ui.button.clicked.StatusUpdateAction': ButtonClickedStatusUpdateActionAttributesType;
338
363
  /** */
339
364
  'ui.button.clicked.GetStatusTransitionsAction': ButtonClickedGetStatusTransitionsActionAttributesType;
365
+ /**
366
+ * fires an event that represents a user clicking on the resize button in the embed preview */
367
+ 'ui.button.clicked.embedPreviewResize': ButtonClickedEmbedPreviewResizeAttributesType;
368
+ /**
369
+ * fires an event that represents when a Smart Link was rendered successfully (even if the Smart Link errors out) */
370
+ 'ui.smartLink.renderSuccess': SmartLinkRenderSuccessAttributesType;
371
+ /**
372
+ * fires an event that represents when a Smart Link renders unsuccessfully. */
373
+ 'ui.smartLink.renderFailed': SmartLinkRenderFailedAttributesType;
340
374
  };
341
375
  export type EventKey = keyof AnalyticsEventAttributes;
@@ -4,6 +4,7 @@ import { type LozengeProps as AtlaskitLozengeProps } from '@atlaskit/lozenge';
4
4
  import { type RequestAccessMessageKey } from './messages';
5
5
  import { type ActionProps } from './view/BlockCard/components/Action';
6
6
  import { type AccessContext } from './view/types';
7
+ /** @deprecated {@link https://hello.atlassian.net/browse/ENGHEALTH-15961 Internal documentation for deprecation (no external access)} */
7
8
  export type ResolveResponse = JsonLd.Response;
8
9
  export type { ProviderProps, CardType } from './state';
9
10
  export type { CardProps, CardAppearance, CardPlatform } from './view/Card/types';
@@ -1,4 +1,4 @@
1
1
  /// <reference types="react" />
2
2
  import { type HoverCardResolvedProps } from './types';
3
- declare const HoverCardResolvedView: ({ analytics, cardState, extensionKey, flexibleCardProps, isAISummaryEnabled, onActionClick, titleBlockProps, }: HoverCardResolvedProps) => JSX.Element;
3
+ declare const HoverCardResolvedView: ({ analytics, cardState, extensionKey, flexibleCardProps, isAISummaryEnabled, onActionClick, titleBlockProps, id, }: HoverCardResolvedProps) => JSX.Element;
4
4
  export default HoverCardResolvedView;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/smart-card",
3
- "version": "32.7.2",
3
+ "version": "32.7.3",
4
4
  "description": "Smart card component",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"