@atlaskit/media-card 77.12.3 → 78.0.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 (151) hide show
  1. package/CHANGELOG.md +15 -0
  2. package/dist/cjs/card/card.js +20 -1039
  3. package/dist/cjs/card/cardLoader.js +2 -2
  4. package/dist/cjs/card/cardView.js +255 -417
  5. package/dist/cjs/card/cardWithMediaClient.js +5 -9
  6. package/dist/cjs/card/{v2/cardviews → cardviews}/cardViewWrapper.js +8 -8
  7. package/dist/cjs/card/{v2/cardviews → cardviews}/errorCardView.js +6 -6
  8. package/dist/cjs/card/{v2/cardviews → cardviews}/iconCardView.js +5 -5
  9. package/dist/cjs/card/{v2/cardviews → cardviews}/imageCardView.js +5 -5
  10. package/dist/cjs/card/{v2/cardviews → cardviews}/index.js +2 -2
  11. package/dist/cjs/card/{v2/cardviews → cardviews}/loadingCardView.js +3 -3
  12. package/dist/cjs/card/{v2/cardviews → cardviews}/processingCardView.js +4 -4
  13. package/dist/cjs/card/{v2/cardviews → cardviews}/videoCardView.js +7 -7
  14. package/dist/cjs/card/{v2/externalImageCard.js → externalImageCard.js} +11 -11
  15. package/dist/cjs/card/{v2/fileCard.js → fileCard.js} +18 -18
  16. package/dist/cjs/card/index.js +2 -2
  17. package/dist/cjs/card/inlinePlayer.js +184 -267
  18. package/dist/cjs/card/media-card-analytics-error-boundary.js +1 -1
  19. package/dist/cjs/card/{v2/svgView → svgView}/svgView.js +9 -9
  20. package/dist/cjs/inline/loader.js +1 -1
  21. package/dist/cjs/utils/ufoExperiences.js +1 -1
  22. package/dist/es2019/card/card.js +20 -1023
  23. package/dist/es2019/card/cardLoader.js +2 -2
  24. package/dist/es2019/card/cardView.js +252 -403
  25. package/dist/es2019/card/cardWithMediaClient.js +6 -10
  26. package/dist/es2019/card/{v2/cardviews → cardviews}/cardViewWrapper.js +8 -8
  27. package/dist/es2019/card/{v2/cardviews → cardviews}/errorCardView.js +6 -6
  28. package/dist/es2019/card/{v2/cardviews → cardviews}/iconCardView.js +5 -5
  29. package/dist/es2019/card/{v2/cardviews → cardviews}/imageCardView.js +5 -5
  30. package/dist/es2019/card/{v2/cardviews → cardviews}/index.js +2 -2
  31. package/dist/es2019/card/{v2/cardviews → cardviews}/loadingCardView.js +3 -3
  32. package/dist/es2019/card/{v2/cardviews → cardviews}/processingCardView.js +4 -4
  33. package/dist/es2019/card/{v2/cardviews → cardviews}/videoCardView.js +7 -7
  34. package/dist/es2019/card/{v2/externalImageCard.js → externalImageCard.js} +11 -11
  35. package/dist/es2019/card/{v2/fileCard.js → fileCard.js} +18 -18
  36. package/dist/es2019/card/index.js +1 -1
  37. package/dist/es2019/card/inlinePlayer.js +127 -208
  38. package/dist/es2019/card/media-card-analytics-error-boundary.js +1 -1
  39. package/dist/es2019/card/{v2/svgView → svgView}/svgView.js +9 -9
  40. package/dist/es2019/inline/loader.js +1 -1
  41. package/dist/es2019/utils/ufoExperiences.js +1 -1
  42. package/dist/esm/card/card.js +21 -1040
  43. package/dist/esm/card/cardLoader.js +2 -2
  44. package/dist/esm/card/cardView.js +251 -416
  45. package/dist/esm/card/cardWithMediaClient.js +6 -10
  46. package/dist/esm/card/{v2/cardviews → cardviews}/cardViewWrapper.js +8 -8
  47. package/dist/esm/card/{v2/cardviews → cardviews}/errorCardView.js +6 -6
  48. package/dist/esm/card/{v2/cardviews → cardviews}/iconCardView.js +5 -5
  49. package/dist/esm/card/{v2/cardviews → cardviews}/imageCardView.js +5 -5
  50. package/dist/esm/card/{v2/cardviews → cardviews}/index.js +2 -2
  51. package/dist/esm/card/{v2/cardviews → cardviews}/loadingCardView.js +3 -3
  52. package/dist/esm/card/{v2/cardviews → cardviews}/processingCardView.js +4 -4
  53. package/dist/esm/card/{v2/cardviews → cardviews}/videoCardView.js +7 -7
  54. package/dist/esm/card/{v2/externalImageCard.js → externalImageCard.js} +11 -11
  55. package/dist/esm/card/{v2/fileCard.js → fileCard.js} +18 -18
  56. package/dist/esm/card/index.js +1 -1
  57. package/dist/esm/card/inlinePlayer.js +185 -269
  58. package/dist/esm/card/media-card-analytics-error-boundary.js +1 -1
  59. package/dist/esm/card/{v2/svgView → svgView}/svgView.js +9 -9
  60. package/dist/esm/inline/loader.js +1 -1
  61. package/dist/esm/utils/ufoExperiences.js +1 -1
  62. package/dist/types/card/card.d.ts +5 -66
  63. package/dist/types/card/cardLoader.d.ts +1 -1
  64. package/dist/types/card/cardView.d.ts +23 -45
  65. package/dist/types/card/cardWithMediaClient.d.ts +1 -1
  66. package/dist/types/card/{v2/cardviews → cardviews}/cardViewWrapper.d.ts +3 -3
  67. package/dist/types/card/{v2/cardviews → cardviews}/errorCardView.d.ts +1 -1
  68. package/dist/{types-ts4.5/card/v2 → types/card}/cardviews/iconCardView.d.ts +1 -1
  69. package/dist/{types-ts4.5/card/v2 → types/card}/cardviews/imageCardView.d.ts +1 -1
  70. package/dist/{types-ts4.5/card/v2 → types/card}/cardviews/index.d.ts +5 -5
  71. package/dist/types/card/{v2/cardviews → cardviews}/videoCardView.d.ts +1 -1
  72. package/dist/types/card/{v2/externalImageCard.d.ts → externalImageCard.d.ts} +1 -1
  73. package/dist/types/card/{v2/fileCard.d.ts → fileCard.d.ts} +2 -2
  74. package/dist/types/card/index.d.ts +1 -1
  75. package/dist/types/card/inlinePlayer.d.ts +2 -31
  76. package/dist/types/card/{v2/svgView → svgView}/errors.d.ts +1 -1
  77. package/dist/{types-ts4.5/card/v2 → types/card}/svgView/svgView.d.ts +2 -2
  78. package/dist/types-ts4.5/card/card.d.ts +5 -66
  79. package/dist/types-ts4.5/card/cardLoader.d.ts +1 -1
  80. package/dist/types-ts4.5/card/cardView.d.ts +23 -45
  81. package/dist/types-ts4.5/card/cardWithMediaClient.d.ts +1 -1
  82. package/dist/types-ts4.5/card/{v2/cardviews → cardviews}/cardViewWrapper.d.ts +3 -3
  83. package/dist/types-ts4.5/card/{v2/cardviews → cardviews}/errorCardView.d.ts +1 -1
  84. package/dist/{types/card/v2 → types-ts4.5/card}/cardviews/iconCardView.d.ts +1 -1
  85. package/dist/{types/card/v2 → types-ts4.5/card}/cardviews/imageCardView.d.ts +1 -1
  86. package/dist/{types/card/v2 → types-ts4.5/card}/cardviews/index.d.ts +5 -5
  87. package/dist/types-ts4.5/card/{v2/cardviews → cardviews}/videoCardView.d.ts +1 -1
  88. package/dist/types-ts4.5/card/{v2/externalImageCard.d.ts → externalImageCard.d.ts} +1 -1
  89. package/dist/types-ts4.5/card/{v2/fileCard.d.ts → fileCard.d.ts} +2 -2
  90. package/dist/types-ts4.5/card/index.d.ts +1 -1
  91. package/dist/types-ts4.5/card/inlinePlayer.d.ts +2 -31
  92. package/dist/types-ts4.5/card/{v2/svgView → svgView}/errors.d.ts +1 -1
  93. package/dist/{types/card/v2 → types-ts4.5/card}/svgView/svgView.d.ts +2 -2
  94. package/package.json +3 -6
  95. package/dist/cjs/card/cardSwitcher.js +0 -15
  96. package/dist/cjs/card/v2/cardV2.js +0 -41
  97. package/dist/cjs/card/v2/cardV2Loader.js +0 -36
  98. package/dist/cjs/card/v2/cardViewV2.js +0 -298
  99. package/dist/cjs/card/v2/cardWithMediaClientV2.js +0 -34
  100. package/dist/cjs/card/v2/inlinePlayerLazyV2.js +0 -35
  101. package/dist/cjs/card/v2/inlinePlayerV2.js +0 -224
  102. package/dist/es2019/card/cardSwitcher.js +0 -8
  103. package/dist/es2019/card/v2/cardV2.js +0 -33
  104. package/dist/es2019/card/v2/cardV2Loader.js +0 -18
  105. package/dist/es2019/card/v2/cardViewV2.js +0 -294
  106. package/dist/es2019/card/v2/cardWithMediaClientV2.js +0 -25
  107. package/dist/es2019/card/v2/inlinePlayerLazyV2.js +0 -10
  108. package/dist/es2019/card/v2/inlinePlayerV2.js +0 -166
  109. package/dist/esm/card/cardSwitcher.js +0 -8
  110. package/dist/esm/card/v2/cardV2.js +0 -34
  111. package/dist/esm/card/v2/cardV2Loader.js +0 -24
  112. package/dist/esm/card/v2/cardViewV2.js +0 -290
  113. package/dist/esm/card/v2/cardWithMediaClientV2.js +0 -27
  114. package/dist/esm/card/v2/inlinePlayerLazyV2.js +0 -23
  115. package/dist/esm/card/v2/inlinePlayerV2.js +0 -214
  116. package/dist/types/card/cardSwitcher.d.ts +0 -4
  117. package/dist/types/card/v2/cardV2.d.ts +0 -7
  118. package/dist/types/card/v2/cardV2Loader.d.ts +0 -4
  119. package/dist/types/card/v2/cardViewV2.d.ts +0 -59
  120. package/dist/types/card/v2/cardWithMediaClientV2.d.ts +0 -3
  121. package/dist/types/card/v2/inlinePlayerLazyV2.d.ts +0 -2
  122. package/dist/types/card/v2/inlinePlayerV2.d.ts +0 -24
  123. package/dist/types-ts4.5/card/cardSwitcher.d.ts +0 -4
  124. package/dist/types-ts4.5/card/v2/cardV2.d.ts +0 -7
  125. package/dist/types-ts4.5/card/v2/cardV2Loader.d.ts +0 -4
  126. package/dist/types-ts4.5/card/v2/cardViewV2.d.ts +0 -59
  127. package/dist/types-ts4.5/card/v2/cardWithMediaClientV2.d.ts +0 -3
  128. package/dist/types-ts4.5/card/v2/inlinePlayerLazyV2.d.ts +0 -2
  129. package/dist/types-ts4.5/card/v2/inlinePlayerV2.d.ts +0 -24
  130. /package/dist/cjs/card/{v2/performance.js → performance.js} +0 -0
  131. /package/dist/cjs/card/{v2/svgView → svgView}/errors.js +0 -0
  132. /package/dist/cjs/card/{v2/svgView → svgView}/helpers.js +0 -0
  133. /package/dist/cjs/card/{v2/svgView → svgView}/index.js +0 -0
  134. /package/dist/es2019/card/{v2/performance.js → performance.js} +0 -0
  135. /package/dist/es2019/card/{v2/svgView → svgView}/errors.js +0 -0
  136. /package/dist/es2019/card/{v2/svgView → svgView}/helpers.js +0 -0
  137. /package/dist/es2019/card/{v2/svgView → svgView}/index.js +0 -0
  138. /package/dist/esm/card/{v2/performance.js → performance.js} +0 -0
  139. /package/dist/esm/card/{v2/svgView → svgView}/errors.js +0 -0
  140. /package/dist/esm/card/{v2/svgView → svgView}/helpers.js +0 -0
  141. /package/dist/esm/card/{v2/svgView → svgView}/index.js +0 -0
  142. /package/dist/types/card/{v2/cardviews → cardviews}/loadingCardView.d.ts +0 -0
  143. /package/dist/types/card/{v2/cardviews → cardviews}/processingCardView.d.ts +0 -0
  144. /package/dist/types/card/{v2/performance.d.ts → performance.d.ts} +0 -0
  145. /package/dist/types/card/{v2/svgView → svgView}/helpers.d.ts +0 -0
  146. /package/dist/types/card/{v2/svgView → svgView}/index.d.ts +0 -0
  147. /package/dist/types-ts4.5/card/{v2/cardviews → cardviews}/loadingCardView.d.ts +0 -0
  148. /package/dist/types-ts4.5/card/{v2/cardviews → cardviews}/processingCardView.d.ts +0 -0
  149. /package/dist/types-ts4.5/card/{v2/performance.d.ts → performance.d.ts} +0 -0
  150. /package/dist/types-ts4.5/card/{v2/svgView → svgView}/helpers.d.ts +0 -0
  151. /package/dist/types-ts4.5/card/{v2/svgView → svgView}/index.d.ts +0 -0
@@ -2,39 +2,45 @@
2
2
  import { jsx } from '@emotion/react';
3
3
  import React, { type MouseEvent } from 'react';
4
4
  import { type MessageDescriptor } from 'react-intl-next';
5
- import { type MediaItemType, type FileDetails } from '@atlaskit/media-client';
5
+ import { type MediaItemType, type FileDetails, type ImageResizeMode } from '@atlaskit/media-client';
6
6
  import { type WithAnalyticsEventsProps, type UIAnalyticsEvent } from '@atlaskit/analytics-next';
7
- import { type SharedCardProps, type CardStatus } from '../types';
7
+ import { type CardStatus, type MediaCardCursor, type CardDimensions, type TitleBoxIcon } from '../types';
8
+ import { type MediaFilePreview } from '@atlaskit/media-file-preview';
9
+ import { type CardAction } from './actions';
8
10
  import { type MediaCardError } from '../errors';
9
- import { type CardPreview } from '../types';
10
- import { type MediaCardCursor } from '../types';
11
- export interface CardViewOwnProps extends SharedCardProps {
11
+ export interface CardViewProps {
12
+ readonly disableOverlay?: boolean;
13
+ readonly resizeMode?: ImageResizeMode;
14
+ readonly dimensions: CardDimensions;
15
+ readonly actions?: Array<CardAction>;
16
+ readonly selectable?: boolean;
17
+ readonly selected?: boolean;
18
+ readonly alt?: string;
19
+ readonly testId?: string;
20
+ readonly titleBoxBgColor?: string;
21
+ readonly titleBoxIcon?: TitleBoxIcon;
12
22
  readonly status: CardStatus;
13
23
  readonly mediaItemType: MediaItemType;
14
24
  readonly mediaCardCursor?: MediaCardCursor;
15
25
  readonly metadata?: FileDetails;
16
26
  readonly error?: MediaCardError;
17
- readonly shouldOpenMediaViewer: boolean;
18
27
  readonly onClick?: (event: React.MouseEvent<HTMLDivElement | HTMLButtonElement>, analyticsEvent?: UIAnalyticsEvent) => void;
28
+ readonly openMediaViewerButtonRef?: React.Ref<HTMLButtonElement>;
29
+ readonly shouldOpenMediaViewer?: boolean;
19
30
  readonly onMouseEnter?: (event: MouseEvent<HTMLDivElement>) => void;
20
31
  readonly onDisplayImage?: () => void;
21
- readonly cardPreview?: CardPreview;
32
+ readonly cardPreview?: MediaFilePreview;
22
33
  readonly progress?: number;
23
34
  readonly innerRef?: (instance: HTMLDivElement | null) => void;
24
- readonly openMediaViewerButtonRef?: React.Ref<HTMLButtonElement>;
25
- readonly onImageLoad: (cardPreview: CardPreview) => void;
26
- readonly onImageError: (cardPreview: CardPreview) => void;
35
+ readonly onImageLoad?: (cardPreview: MediaFilePreview) => void;
36
+ readonly onImageError?: (cardPreview: MediaFilePreview) => void;
27
37
  readonly nativeLazyLoad?: boolean;
28
38
  readonly forceSyncDisplay?: boolean;
29
39
  disableAnimation?: boolean;
30
40
  shouldHideTooltip?: boolean;
31
41
  overriddenCreationDate?: number;
32
42
  }
33
- export interface CardViewState {
34
- elementWidth?: number;
35
- didImageRender: boolean;
36
- }
37
- export type CardViewProps = CardViewOwnProps & WithAnalyticsEventsProps;
43
+ export type CardViewBaseProps = CardViewProps & WithAnalyticsEventsProps;
38
44
  export interface RenderConfigByStatus {
39
45
  renderTypeIcon?: boolean;
40
46
  iconMessage?: JSX.Element;
@@ -49,33 +55,5 @@ export interface RenderConfigByStatus {
49
55
  renderTickBox?: boolean;
50
56
  customTitleMessage?: MessageDescriptor;
51
57
  }
52
- /**
53
- * This is classic vanilla CardView class. To create an instance of class one would need to supply
54
- * `createAnalyticsEvent` prop to satisfy it's Analytics Events needs.
55
- */
56
- export declare class CardViewBase extends React.Component<CardViewProps, CardViewState> {
57
- state: CardViewState;
58
- divRef: React.RefObject<HTMLDivElement>;
59
- static defaultProps: Partial<CardViewOwnProps>;
60
- componentDidMount(): void;
61
- componentDidUpdate({ cardPreview: prevCardPreview }: CardViewProps): void;
62
- private onImageLoad;
63
- private onImageError;
64
- private get breakpoint();
65
- private saveElementWidth;
66
- private renderSpinner;
67
- private shouldRenderPlayButton;
68
- private renderPlayButton;
69
- private renderBlanket;
70
- private renderTitleBox;
71
- private renderFailedTitleBox;
72
- private renderProgressBar;
73
- private renderImageRenderer;
74
- private renderTickBox;
75
- private renderMediaTypeIcon;
76
- private renderActionsBar;
77
- render(): jsx.JSX.Element;
78
- private getRenderConfigByStatus;
79
- private renderContents;
80
- }
81
- export declare const CardView: React.ForwardRefExoticComponent<Pick<Omit<CardViewProps, keyof WithAnalyticsEventsProps>, never> & Partial<Pick<Omit<CardViewProps, keyof WithAnalyticsEventsProps>, keyof CardViewOwnProps>> & Partial<Pick<Partial<CardViewOwnProps>, never>> & React.RefAttributes<any>>;
58
+ export declare const CardViewBase: ({ innerRef, onImageLoad, onImageError, dimensions, onClick, onMouseEnter, testId, metadata, status, selected, selectable, cardPreview, mediaCardCursor, shouldHideTooltip, progress, alt, resizeMode, onDisplayImage, nativeLazyLoad, forceSyncDisplay, actions, disableOverlay, titleBoxBgColor, titleBoxIcon, error, disableAnimation, openMediaViewerButtonRef, shouldOpenMediaViewer, overriddenCreationDate, }: CardViewBaseProps) => jsx.JSX.Element;
59
+ export declare const CardView: React.ForwardRefExoticComponent<Omit<CardViewProps & WithAnalyticsEventsProps, keyof WithAnalyticsEventsProps> & React.RefAttributes<any>>;
@@ -1,3 +1,3 @@
1
1
  import React from 'react';
2
- import type { CardWithMediaClientConfigProps } from './types';
2
+ import { type CardWithMediaClientConfigProps } from './types';
3
3
  export declare const CardWithMediaClient: React.FC<CardWithMediaClientConfigProps>;
@@ -1,9 +1,9 @@
1
1
  import React, { type MouseEvent, type ReactNode } from 'react';
2
2
  import { type FileDetails } from '@atlaskit/media-client';
3
3
  import { type UIAnalyticsEvent } from '@atlaskit/analytics-next';
4
- import { type CardAppearance, type CardDimensions, type MediaCardCursor, type TitleBoxIcon } from '../../../types';
5
- import { type CardAction } from '../../actions';
6
- import { type Breakpoint } from '../../ui/common';
4
+ import { type CardAppearance, type CardDimensions, type MediaCardCursor, type TitleBoxIcon } from '../../types';
5
+ import { type CardAction } from '../actions';
6
+ import { type Breakpoint } from '../ui/common';
7
7
  import { type MediaFilePreview } from '@atlaskit/media-file-preview';
8
8
  export type SharedCardViewProps = {
9
9
  readonly cardPreview?: MediaFilePreview;
@@ -2,7 +2,7 @@
2
2
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
3
3
  import { type FileDetails } from '@atlaskit/media-client';
4
4
  import { type SharedCardViewProps } from './cardViewWrapper';
5
- import { type MediaCardError } from '../../../errors';
5
+ import { type MediaCardError } from '../../errors';
6
6
  export type ErrorCardViewProps = SharedCardViewProps & WithAnalyticsEventsProps & {
7
7
  metadata?: FileDetails;
8
8
  disableAnimation?: boolean;
@@ -2,7 +2,7 @@
2
2
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
3
3
  import { type FileDetails } from '@atlaskit/media-client';
4
4
  import { type SharedCardViewProps } from './cardViewWrapper';
5
- import type { CardStatus } from '../../../types';
5
+ import type { CardStatus } from '../../types';
6
6
  export type IconCardViewProps = SharedCardViewProps & WithAnalyticsEventsProps & {
7
7
  status: CardStatus;
8
8
  metadata?: FileDetails;
@@ -2,7 +2,7 @@
2
2
  import { type ImageResizeMode } from '@atlaskit/media-client';
3
3
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
4
4
  import { type FileDetails } from '@atlaskit/media-client';
5
- import type { CardPreview, CardStatus } from '../../../types';
5
+ import type { CardPreview, CardStatus } from '../../types';
6
6
  import { type SharedCardViewProps } from './cardViewWrapper';
7
7
  export type ImageCardViewProps = SharedCardViewProps & WithAnalyticsEventsProps & {
8
8
  status: CardStatus;
@@ -4,8 +4,8 @@ import React, { type MouseEvent } from 'react';
4
4
  import { type MessageDescriptor } from 'react-intl-next';
5
5
  import { type MediaItemType, type FileDetails } from '@atlaskit/media-client';
6
6
  import { type WithAnalyticsEventsProps, type UIAnalyticsEvent } from '@atlaskit/analytics-next';
7
- import { type SharedCardProps, type CardStatus, type MediaCardCursor } from '../../../types';
8
- import { type MediaCardError } from '../../../errors';
7
+ import { type SharedCardProps, type CardStatus, type MediaCardCursor } from '../../types';
8
+ import { type MediaCardError } from '../../errors';
9
9
  import { type MediaFilePreview } from '@atlaskit/media-file-preview';
10
10
  export interface CardViewsOwnProps extends SharedCardProps {
11
11
  readonly status: CardStatus;
@@ -29,8 +29,8 @@ export interface CardViewsOwnProps extends SharedCardProps {
29
29
  readonly shouldOpenMediaViewer?: boolean;
30
30
  overriddenCreationDate?: number;
31
31
  }
32
- export type CardViewV2Props = CardViewsOwnProps & WithAnalyticsEventsProps;
33
- export interface RenderConfigByStatusV2 {
32
+ export type CardViewProps = CardViewsOwnProps & WithAnalyticsEventsProps;
33
+ export interface RenderConfigByStatus {
34
34
  renderTypeIcon?: boolean;
35
35
  iconMessage?: JSX.Element;
36
36
  renderImageRenderer?: boolean;
@@ -44,5 +44,5 @@ export interface RenderConfigByStatusV2 {
44
44
  renderTickBox?: boolean;
45
45
  customTitleMessage?: MessageDescriptor;
46
46
  }
47
- export declare const CardViewsBase: ({ innerRef, onImageLoad, onImageError, dimensions, appearance, onClick, onMouseEnter, testId, metadata, status, selected, selectable, cardPreview, mediaCardCursor, shouldHideTooltip, progress, alt, resizeMode, onDisplayImage, nativeLazyLoad, forceSyncDisplay, actions, disableOverlay, titleBoxBgColor, titleBoxIcon, error, disableAnimation, shouldOpenMediaViewer, openMediaViewerButtonRef, overriddenCreationDate, }: CardViewV2Props) => jsx.JSX.Element;
47
+ export declare const CardViewsBase: ({ innerRef, onImageLoad, onImageError, dimensions, appearance, onClick, onMouseEnter, testId, metadata, status, selected, selectable, cardPreview, mediaCardCursor, shouldHideTooltip, progress, alt, resizeMode, onDisplayImage, nativeLazyLoad, forceSyncDisplay, actions, disableOverlay, titleBoxBgColor, titleBoxIcon, error, disableAnimation, shouldOpenMediaViewer, openMediaViewerButtonRef, overriddenCreationDate, }: CardViewProps) => jsx.JSX.Element;
48
48
  export declare const CardViews: React.ForwardRefExoticComponent<Omit<CardViewsOwnProps & WithAnalyticsEventsProps, keyof WithAnalyticsEventsProps> & React.RefAttributes<any>>;
@@ -2,7 +2,7 @@
2
2
  import { type ImageResizeMode } from '@atlaskit/media-client';
3
3
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
4
4
  import { type FileDetails } from '@atlaskit/media-client';
5
- import type { CardPreview, CardStatus } from '../../../types';
5
+ import type { CardPreview, CardStatus } from '../../types';
6
6
  import { type SharedCardViewProps } from './cardViewWrapper';
7
7
  export type VideoCardViewProps = SharedCardViewProps & WithAnalyticsEventsProps & {
8
8
  status: CardStatus;
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
3
3
  import { type ExternalImageIdentifier, type Identifier, type MediaClient } from '@atlaskit/media-client';
4
- import { type CardEventProps, type SharedCardProps } from '../../types';
4
+ import { type CardEventProps, type SharedCardProps } from '../types';
5
5
  export interface ExternalImageCardProps extends SharedCardProps, CardEventProps {
6
6
  readonly mediaClient: MediaClient;
7
7
  readonly identifier: ExternalImageIdentifier;
@@ -2,8 +2,8 @@
2
2
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
3
3
  import { type FileIdentifier, type Identifier, type ImageResizeMode } from '@atlaskit/media-client';
4
4
  import { type MediaFeatureFlags, type NumericalCardDimensions, type SSR } from '@atlaskit/media-common';
5
- import { type CardAppearance, type CardDimensions, type CardEventProps, type TitleBoxIcon } from '../../types';
6
- import { type CardAction } from '../actions';
5
+ import { type CardAppearance, type CardDimensions, type CardEventProps, type TitleBoxIcon } from '../types';
6
+ import { type CardAction } from './actions';
7
7
  export interface FileCardProps extends CardEventProps {
8
8
  /** Overlay the media file. */
9
9
  readonly disableOverlay?: boolean;
@@ -1 +1 @@
1
- export { default as Card } from './cardSwitcher';
1
+ export { default as Card } from './cardLoader';
@@ -1,13 +1,11 @@
1
1
  import React from 'react';
2
- import { Component } from 'react';
3
- import { type MediaClient, type FileIdentifier, type FileState, type MediaFileArtifacts, type MediaSubscription } from '@atlaskit/media-client';
2
+ import { type FileIdentifier, type FileState, type MediaFileArtifacts } from '@atlaskit/media-client';
4
3
  import { type NumericalCardDimensions } from '@atlaskit/media-common';
5
4
  import { type CardDimensions } from '../types';
6
5
  import { type WithAnalyticsEventsProps, type UIAnalyticsEvent } from '@atlaskit/analytics-next';
7
6
  import type { CardPreview } from '../types';
8
7
  export interface InlinePlayerOwnProps {
9
8
  identifier: FileIdentifier;
10
- mediaClient: MediaClient;
11
9
  dimensions?: CardDimensions;
12
10
  originalDimensions?: NumericalCardDimensions;
13
11
  autoplay: boolean;
@@ -21,33 +19,6 @@ export interface InlinePlayerOwnProps {
21
19
  readonly videoControlsWrapperRef?: React.Ref<HTMLDivElement>;
22
20
  }
23
21
  export type InlinePlayerProps = InlinePlayerOwnProps & WithAnalyticsEventsProps;
24
- export interface InlinePlayerState {
25
- fileSrc?: string;
26
- isUploading?: boolean;
27
- progress?: number;
28
- elementWidth?: number;
29
- }
30
22
  export declare const getPreferredVideoArtifact: (fileState: FileState) => keyof MediaFileArtifacts | undefined;
31
- export declare class InlinePlayerBase extends Component<InlinePlayerProps, InlinePlayerState> {
32
- subscription?: MediaSubscription;
33
- state: InlinePlayerState;
34
- divRef: React.RefObject<HTMLDivElement>;
35
- static defaultProps: {
36
- dimensions: {
37
- width: number;
38
- height: number;
39
- };
40
- };
41
- componentDidMount(): void;
42
- setFileSrc: (fileSrc: string) => void;
43
- setBinaryURL: () => Promise<void>;
44
- unsubscribe: () => void;
45
- revoke: () => void;
46
- componentWillUnmount(): void;
47
- onDownloadClick: () => void;
48
- onFirstPlay: () => void;
49
- private get breakpoint();
50
- saveElementWidth: () => void;
51
- render(): JSX.Element;
52
- }
23
+ export declare const InlinePlayerBase: ({ identifier, onError, onClick, dimensions, originalDimensions, selected, testId, forwardRef, autoplay, cardPreview, onFullscreenChange, videoControlsWrapperRef, }: InlinePlayerProps) => JSX.Element;
53
24
  export declare const InlinePlayer: React.ForwardRefExoticComponent<Pick<InlinePlayerProps, "createAnalyticsEvent" | keyof InlinePlayerOwnProps> & React.RefAttributes<HTMLDivElement>>;
@@ -1,3 +1,3 @@
1
1
  import { type MediaSVGErrorReason } from '@atlaskit/media-svg';
2
- import { type SvgPrimaryReason } from '../../../errors';
2
+ import { type SvgPrimaryReason } from '../../errors';
3
3
  export declare const getErrorReason: (svgReason: MediaSVGErrorReason) => SvgPrimaryReason;
@@ -3,9 +3,9 @@ import { jsx } from '@emotion/react';
3
3
  import React, { type MouseEvent } from 'react';
4
4
  import { type FileIdentifier, type ImageResizeMode } from '@atlaskit/media-client';
5
5
  import { type WithAnalyticsEventsProps, type UIAnalyticsEvent } from '@atlaskit/analytics-next';
6
- import { type CardStatus, type MediaCardCursor, type CardDimensions } from '../../../types';
6
+ import { type CardStatus, type MediaCardCursor, type CardDimensions } from '../../types';
7
7
  import { type MediaFilePreview } from '@atlaskit/media-file-preview';
8
- import { MediaCardError } from '../../../errors';
8
+ import { MediaCardError } from '../../errors';
9
9
  export declare const convertResizeMode: (resizeMode?: ImageResizeMode) => React.CSSProperties['objectFit'];
10
10
  export type OnClickFn = (event: React.MouseEvent<HTMLDivElement | HTMLButtonElement>, analyticsEvent?: UIAnalyticsEvent) => void;
11
11
  export interface SvgViewBaseOwnProps {
@@ -1,68 +1,7 @@
1
- import React, { Component } from 'react';
2
- import { type UIAnalyticsEvent, type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
3
- import { type FileIdentifier, type FileState, type MediaSubscription } from '@atlaskit/media-client';
1
+ import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
2
+ import React from 'react';
4
3
  import { type WrappedComponentProps } from 'react-intl-next';
5
- import { type CardAction } from './actions';
6
- import { type CardProps, type CardState, type CardStatus } from '../types';
7
- export type CardBaseProps = CardProps & WithAnalyticsEventsProps & Partial<WrappedComponentProps> & {
8
- dateOverride?: number;
9
- };
10
- export declare class CardBase extends Component<CardBaseProps, CardState> {
11
- private internalOccurrenceKey;
12
- private hasBeenMounted;
13
- private mediaViewerButtonRef;
14
- private fileStateFlags;
15
- private ssrReliability;
16
- private timeElapsedTillCommenced;
17
- subscription?: MediaSubscription;
18
- private ssrData?;
19
- private traceContext;
20
- static defaultProps: Partial<CardProps>;
21
- constructor(props: CardBaseProps);
22
- private getSSRPreview;
23
- componentDidMount(): void;
24
- componentDidUpdate(prevProps: CardProps, prevState: CardState): void;
25
- componentWillUnmount(): void;
26
- updateStateForIdentifier(identifier: FileIdentifier): void;
27
- private getImageURLParams;
28
- private getMediaBlobUrlAttrs;
29
- private getCardPreviewParams;
30
- private setCacheSSRPreview;
31
- private refetchSSRPreview;
32
- private resolveUpfrontPreview;
33
- private fetchAndCacheRemotePreview;
34
- private resolvePreview;
35
- updateFileStateFlag(fileState?: FileState): void;
36
- subscribeInternalFile(identifier: FileIdentifier): void;
37
- private get requestedDimensions();
38
- private get metadata();
39
- private get fileAttributes();
40
- private getPerformanceAttributes;
41
- private logSSRImageError;
42
- private onImageError;
43
- private onImageLoad;
44
- private fireOperationalEvent;
45
- private fireAbortedEvent;
46
- private fireCommencedEvent;
47
- private fireCopiedEvent;
48
- private fireScreenEvent;
49
- private fireNonCriticalErrorEvent;
50
- private safeSetState;
51
- unsubscribe: () => void;
52
- get actions(): CardAction[];
53
- onCardViewClick: (event: React.MouseEvent<HTMLDivElement | HTMLButtonElement>, analyticsEvent?: UIAnalyticsEvent) => void;
54
- onInlinePlayerError: (e: Error) => void;
55
- setRef: (cardRef: HTMLDivElement | null) => void;
56
- setMediaViewerButtonRef: (buttonRef: HTMLButtonElement | null) => void;
57
- renderInlinePlayer: () => JSX.Element;
58
- onMediaViewerClose: () => void;
59
- private onDisplayImage;
60
- renderMediaViewer: () => React.ReactPortal | undefined;
61
- renderCard: (withCallbacks?: boolean, cardStatusOverride?: CardStatus, izLazyOverride?: boolean) => JSX.Element;
62
- private storeSSRData;
63
- render(): JSX.Element;
64
- private onCardInViewport;
65
- onClick: (event: React.MouseEvent<HTMLDivElement | HTMLButtonElement>, analyticsEvent?: UIAnalyticsEvent) => void;
66
- onMouseEnter: (event: React.MouseEvent<HTMLDivElement>) => void;
67
- }
4
+ import { type CardProps } from '../types';
5
+ export type CardBaseProps = CardProps & WithAnalyticsEventsProps & Partial<WrappedComponentProps>;
6
+ export declare const CardBase: ({ identifier, ...otherProps }: CardBaseProps & WrappedComponentProps) => JSX.Element;
68
7
  export declare const Card: React.ComponentType<CardBaseProps>;
@@ -1,4 +1,4 @@
1
1
  import React from 'react';
2
- import type { CardWithMediaClientConfigProps } from './types';
2
+ import { type CardWithMediaClientConfigProps } from './types';
3
3
  declare const CardLoader: React.FC<CardWithMediaClientConfigProps>;
4
4
  export default CardLoader;
@@ -2,39 +2,45 @@
2
2
  import { jsx } from '@emotion/react';
3
3
  import React, { type MouseEvent } from 'react';
4
4
  import { type MessageDescriptor } from 'react-intl-next';
5
- import { type MediaItemType, type FileDetails } from '@atlaskit/media-client';
5
+ import { type MediaItemType, type FileDetails, type ImageResizeMode } from '@atlaskit/media-client';
6
6
  import { type WithAnalyticsEventsProps, type UIAnalyticsEvent } from '@atlaskit/analytics-next';
7
- import { type SharedCardProps, type CardStatus } from '../types';
7
+ import { type CardStatus, type MediaCardCursor, type CardDimensions, type TitleBoxIcon } from '../types';
8
+ import { type MediaFilePreview } from '@atlaskit/media-file-preview';
9
+ import { type CardAction } from './actions';
8
10
  import { type MediaCardError } from '../errors';
9
- import { type CardPreview } from '../types';
10
- import { type MediaCardCursor } from '../types';
11
- export interface CardViewOwnProps extends SharedCardProps {
11
+ export interface CardViewProps {
12
+ readonly disableOverlay?: boolean;
13
+ readonly resizeMode?: ImageResizeMode;
14
+ readonly dimensions: CardDimensions;
15
+ readonly actions?: Array<CardAction>;
16
+ readonly selectable?: boolean;
17
+ readonly selected?: boolean;
18
+ readonly alt?: string;
19
+ readonly testId?: string;
20
+ readonly titleBoxBgColor?: string;
21
+ readonly titleBoxIcon?: TitleBoxIcon;
12
22
  readonly status: CardStatus;
13
23
  readonly mediaItemType: MediaItemType;
14
24
  readonly mediaCardCursor?: MediaCardCursor;
15
25
  readonly metadata?: FileDetails;
16
26
  readonly error?: MediaCardError;
17
- readonly shouldOpenMediaViewer: boolean;
18
27
  readonly onClick?: (event: React.MouseEvent<HTMLDivElement | HTMLButtonElement>, analyticsEvent?: UIAnalyticsEvent) => void;
28
+ readonly openMediaViewerButtonRef?: React.Ref<HTMLButtonElement>;
29
+ readonly shouldOpenMediaViewer?: boolean;
19
30
  readonly onMouseEnter?: (event: MouseEvent<HTMLDivElement>) => void;
20
31
  readonly onDisplayImage?: () => void;
21
- readonly cardPreview?: CardPreview;
32
+ readonly cardPreview?: MediaFilePreview;
22
33
  readonly progress?: number;
23
34
  readonly innerRef?: (instance: HTMLDivElement | null) => void;
24
- readonly openMediaViewerButtonRef?: React.Ref<HTMLButtonElement>;
25
- readonly onImageLoad: (cardPreview: CardPreview) => void;
26
- readonly onImageError: (cardPreview: CardPreview) => void;
35
+ readonly onImageLoad?: (cardPreview: MediaFilePreview) => void;
36
+ readonly onImageError?: (cardPreview: MediaFilePreview) => void;
27
37
  readonly nativeLazyLoad?: boolean;
28
38
  readonly forceSyncDisplay?: boolean;
29
39
  disableAnimation?: boolean;
30
40
  shouldHideTooltip?: boolean;
31
41
  overriddenCreationDate?: number;
32
42
  }
33
- export interface CardViewState {
34
- elementWidth?: number;
35
- didImageRender: boolean;
36
- }
37
- export type CardViewProps = CardViewOwnProps & WithAnalyticsEventsProps;
43
+ export type CardViewBaseProps = CardViewProps & WithAnalyticsEventsProps;
38
44
  export interface RenderConfigByStatus {
39
45
  renderTypeIcon?: boolean;
40
46
  iconMessage?: JSX.Element;
@@ -49,33 +55,5 @@ export interface RenderConfigByStatus {
49
55
  renderTickBox?: boolean;
50
56
  customTitleMessage?: MessageDescriptor;
51
57
  }
52
- /**
53
- * This is classic vanilla CardView class. To create an instance of class one would need to supply
54
- * `createAnalyticsEvent` prop to satisfy it's Analytics Events needs.
55
- */
56
- export declare class CardViewBase extends React.Component<CardViewProps, CardViewState> {
57
- state: CardViewState;
58
- divRef: React.RefObject<HTMLDivElement>;
59
- static defaultProps: Partial<CardViewOwnProps>;
60
- componentDidMount(): void;
61
- componentDidUpdate({ cardPreview: prevCardPreview }: CardViewProps): void;
62
- private onImageLoad;
63
- private onImageError;
64
- private get breakpoint();
65
- private saveElementWidth;
66
- private renderSpinner;
67
- private shouldRenderPlayButton;
68
- private renderPlayButton;
69
- private renderBlanket;
70
- private renderTitleBox;
71
- private renderFailedTitleBox;
72
- private renderProgressBar;
73
- private renderImageRenderer;
74
- private renderTickBox;
75
- private renderMediaTypeIcon;
76
- private renderActionsBar;
77
- render(): jsx.JSX.Element;
78
- private getRenderConfigByStatus;
79
- private renderContents;
80
- }
81
- export declare const CardView: React.ForwardRefExoticComponent<Pick<Omit<CardViewProps, keyof WithAnalyticsEventsProps>, never> & Partial<Pick<Omit<CardViewProps, keyof WithAnalyticsEventsProps>, keyof CardViewOwnProps>> & Partial<Pick<Partial<CardViewOwnProps>, never>> & React.RefAttributes<any>>;
58
+ export declare const CardViewBase: ({ innerRef, onImageLoad, onImageError, dimensions, onClick, onMouseEnter, testId, metadata, status, selected, selectable, cardPreview, mediaCardCursor, shouldHideTooltip, progress, alt, resizeMode, onDisplayImage, nativeLazyLoad, forceSyncDisplay, actions, disableOverlay, titleBoxBgColor, titleBoxIcon, error, disableAnimation, openMediaViewerButtonRef, shouldOpenMediaViewer, overriddenCreationDate, }: CardViewBaseProps) => jsx.JSX.Element;
59
+ export declare const CardView: React.ForwardRefExoticComponent<Omit<CardViewProps & WithAnalyticsEventsProps, keyof WithAnalyticsEventsProps> & React.RefAttributes<any>>;
@@ -1,3 +1,3 @@
1
1
  import React from 'react';
2
- import type { CardWithMediaClientConfigProps } from './types';
2
+ import { type CardWithMediaClientConfigProps } from './types';
3
3
  export declare const CardWithMediaClient: React.FC<CardWithMediaClientConfigProps>;
@@ -1,9 +1,9 @@
1
1
  import React, { type MouseEvent, type ReactNode } from 'react';
2
2
  import { type FileDetails } from '@atlaskit/media-client';
3
3
  import { type UIAnalyticsEvent } from '@atlaskit/analytics-next';
4
- import { type CardAppearance, type CardDimensions, type MediaCardCursor, type TitleBoxIcon } from '../../../types';
5
- import { type CardAction } from '../../actions';
6
- import { type Breakpoint } from '../../ui/common';
4
+ import { type CardAppearance, type CardDimensions, type MediaCardCursor, type TitleBoxIcon } from '../../types';
5
+ import { type CardAction } from '../actions';
6
+ import { type Breakpoint } from '../ui/common';
7
7
  import { type MediaFilePreview } from '@atlaskit/media-file-preview';
8
8
  export type SharedCardViewProps = {
9
9
  readonly cardPreview?: MediaFilePreview;
@@ -2,7 +2,7 @@
2
2
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
3
3
  import { type FileDetails } from '@atlaskit/media-client';
4
4
  import { type SharedCardViewProps } from './cardViewWrapper';
5
- import { type MediaCardError } from '../../../errors';
5
+ import { type MediaCardError } from '../../errors';
6
6
  export type ErrorCardViewProps = SharedCardViewProps & WithAnalyticsEventsProps & {
7
7
  metadata?: FileDetails;
8
8
  disableAnimation?: boolean;
@@ -2,7 +2,7 @@
2
2
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
3
3
  import { type FileDetails } from '@atlaskit/media-client';
4
4
  import { type SharedCardViewProps } from './cardViewWrapper';
5
- import type { CardStatus } from '../../../types';
5
+ import type { CardStatus } from '../../types';
6
6
  export type IconCardViewProps = SharedCardViewProps & WithAnalyticsEventsProps & {
7
7
  status: CardStatus;
8
8
  metadata?: FileDetails;
@@ -2,7 +2,7 @@
2
2
  import { type ImageResizeMode } from '@atlaskit/media-client';
3
3
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
4
4
  import { type FileDetails } from '@atlaskit/media-client';
5
- import type { CardPreview, CardStatus } from '../../../types';
5
+ import type { CardPreview, CardStatus } from '../../types';
6
6
  import { type SharedCardViewProps } from './cardViewWrapper';
7
7
  export type ImageCardViewProps = SharedCardViewProps & WithAnalyticsEventsProps & {
8
8
  status: CardStatus;
@@ -4,8 +4,8 @@ import React, { type MouseEvent } from 'react';
4
4
  import { type MessageDescriptor } from 'react-intl-next';
5
5
  import { type MediaItemType, type FileDetails } from '@atlaskit/media-client';
6
6
  import { type WithAnalyticsEventsProps, type UIAnalyticsEvent } from '@atlaskit/analytics-next';
7
- import { type SharedCardProps, type CardStatus, type MediaCardCursor } from '../../../types';
8
- import { type MediaCardError } from '../../../errors';
7
+ import { type SharedCardProps, type CardStatus, type MediaCardCursor } from '../../types';
8
+ import { type MediaCardError } from '../../errors';
9
9
  import { type MediaFilePreview } from '@atlaskit/media-file-preview';
10
10
  export interface CardViewsOwnProps extends SharedCardProps {
11
11
  readonly status: CardStatus;
@@ -29,8 +29,8 @@ export interface CardViewsOwnProps extends SharedCardProps {
29
29
  readonly shouldOpenMediaViewer?: boolean;
30
30
  overriddenCreationDate?: number;
31
31
  }
32
- export type CardViewV2Props = CardViewsOwnProps & WithAnalyticsEventsProps;
33
- export interface RenderConfigByStatusV2 {
32
+ export type CardViewProps = CardViewsOwnProps & WithAnalyticsEventsProps;
33
+ export interface RenderConfigByStatus {
34
34
  renderTypeIcon?: boolean;
35
35
  iconMessage?: JSX.Element;
36
36
  renderImageRenderer?: boolean;
@@ -44,5 +44,5 @@ export interface RenderConfigByStatusV2 {
44
44
  renderTickBox?: boolean;
45
45
  customTitleMessage?: MessageDescriptor;
46
46
  }
47
- export declare const CardViewsBase: ({ innerRef, onImageLoad, onImageError, dimensions, appearance, onClick, onMouseEnter, testId, metadata, status, selected, selectable, cardPreview, mediaCardCursor, shouldHideTooltip, progress, alt, resizeMode, onDisplayImage, nativeLazyLoad, forceSyncDisplay, actions, disableOverlay, titleBoxBgColor, titleBoxIcon, error, disableAnimation, shouldOpenMediaViewer, openMediaViewerButtonRef, overriddenCreationDate, }: CardViewV2Props) => jsx.JSX.Element;
47
+ export declare const CardViewsBase: ({ innerRef, onImageLoad, onImageError, dimensions, appearance, onClick, onMouseEnter, testId, metadata, status, selected, selectable, cardPreview, mediaCardCursor, shouldHideTooltip, progress, alt, resizeMode, onDisplayImage, nativeLazyLoad, forceSyncDisplay, actions, disableOverlay, titleBoxBgColor, titleBoxIcon, error, disableAnimation, shouldOpenMediaViewer, openMediaViewerButtonRef, overriddenCreationDate, }: CardViewProps) => jsx.JSX.Element;
48
48
  export declare const CardViews: React.ForwardRefExoticComponent<Omit<CardViewsOwnProps & WithAnalyticsEventsProps, keyof WithAnalyticsEventsProps> & React.RefAttributes<any>>;
@@ -2,7 +2,7 @@
2
2
  import { type ImageResizeMode } from '@atlaskit/media-client';
3
3
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
4
4
  import { type FileDetails } from '@atlaskit/media-client';
5
- import type { CardPreview, CardStatus } from '../../../types';
5
+ import type { CardPreview, CardStatus } from '../../types';
6
6
  import { type SharedCardViewProps } from './cardViewWrapper';
7
7
  export type VideoCardViewProps = SharedCardViewProps & WithAnalyticsEventsProps & {
8
8
  status: CardStatus;
@@ -1,7 +1,7 @@
1
1
  /// <reference types="react" />
2
2
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
3
3
  import { type ExternalImageIdentifier, type Identifier, type MediaClient } from '@atlaskit/media-client';
4
- import { type CardEventProps, type SharedCardProps } from '../../types';
4
+ import { type CardEventProps, type SharedCardProps } from '../types';
5
5
  export interface ExternalImageCardProps extends SharedCardProps, CardEventProps {
6
6
  readonly mediaClient: MediaClient;
7
7
  readonly identifier: ExternalImageIdentifier;
@@ -2,8 +2,8 @@
2
2
  import { type WithAnalyticsEventsProps } from '@atlaskit/analytics-next';
3
3
  import { type FileIdentifier, type Identifier, type ImageResizeMode } from '@atlaskit/media-client';
4
4
  import { type MediaFeatureFlags, type NumericalCardDimensions, type SSR } from '@atlaskit/media-common';
5
- import { type CardAppearance, type CardDimensions, type CardEventProps, type TitleBoxIcon } from '../../types';
6
- import { type CardAction } from '../actions';
5
+ import { type CardAppearance, type CardDimensions, type CardEventProps, type TitleBoxIcon } from '../types';
6
+ import { type CardAction } from './actions';
7
7
  export interface FileCardProps extends CardEventProps {
8
8
  /** Overlay the media file. */
9
9
  readonly disableOverlay?: boolean;
@@ -1 +1 @@
1
- export { default as Card } from './cardSwitcher';
1
+ export { default as Card } from './cardLoader';