@atlaskit/media-card 77.1.1 → 77.2.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.
- package/CHANGELOG.md +14 -0
- package/dist/cjs/card/card.js +17 -13
- package/dist/cjs/card/cardState.js +1 -1
- package/dist/cjs/card/getCardPreview/index.js +2 -5
- package/dist/cjs/card/media-card-analytics-error-boundary.js +1 -1
- package/dist/cjs/card/useBreakpoint.js +29 -0
- package/dist/cjs/card/v2/cardV2.js +22 -20
- package/dist/cjs/card/v2/cardViewV2.js +5 -22
- package/dist/cjs/card/v2/inlinePlayerLazyV2.js +35 -0
- package/dist/cjs/card/v2/inlinePlayerV2.js +222 -0
- package/dist/cjs/inline/loader.js +1 -1
- package/dist/cjs/utils/ufoExperiences.js +18 -14
- package/dist/es2019/card/card.js +18 -16
- package/dist/es2019/card/cardState.js +1 -1
- package/dist/es2019/card/getCardPreview/index.js +0 -5
- package/dist/es2019/card/media-card-analytics-error-boundary.js +1 -1
- package/dist/es2019/card/useBreakpoint.js +22 -0
- package/dist/es2019/card/v2/cardV2.js +23 -23
- package/dist/es2019/card/v2/cardViewV2.js +4 -18
- package/dist/es2019/card/v2/inlinePlayerLazyV2.js +10 -0
- package/dist/es2019/card/v2/inlinePlayerV2.js +164 -0
- package/dist/es2019/inline/loader.js +1 -1
- package/dist/es2019/utils/ufoExperiences.js +18 -9
- package/dist/esm/card/card.js +18 -14
- package/dist/esm/card/cardState.js +1 -1
- package/dist/esm/card/getCardPreview/index.js +2 -5
- package/dist/esm/card/media-card-analytics-error-boundary.js +1 -1
- package/dist/esm/card/useBreakpoint.js +24 -0
- package/dist/esm/card/v2/cardV2.js +23 -21
- package/dist/esm/card/v2/cardViewV2.js +7 -24
- package/dist/esm/card/v2/inlinePlayerLazyV2.js +23 -0
- package/dist/esm/card/v2/inlinePlayerV2.js +212 -0
- package/dist/esm/inline/loader.js +1 -1
- package/dist/esm/utils/ufoExperiences.js +17 -13
- package/dist/types/card/card.d.ts +1 -0
- package/dist/types/card/cardState.d.ts +1 -2
- package/dist/types/card/getCardPreview/index.d.ts +4 -10
- package/dist/types/card/useBreakpoint.d.ts +3 -0
- package/dist/types/card/v2/cardV2.d.ts +3 -2
- package/dist/types/card/v2/inlinePlayerLazyV2.d.ts +2 -0
- package/dist/types/card/v2/inlinePlayerV2.d.ts +23 -0
- package/dist/types/utils/ufoExperiences.d.ts +7 -0
- package/dist/types-ts4.5/card/card.d.ts +1 -0
- package/dist/types-ts4.5/card/cardState.d.ts +1 -2
- package/dist/types-ts4.5/card/getCardPreview/index.d.ts +4 -10
- package/dist/types-ts4.5/card/useBreakpoint.d.ts +3 -0
- package/dist/types-ts4.5/card/v2/cardV2.d.ts +3 -2
- package/dist/types-ts4.5/card/v2/inlinePlayerLazyV2.d.ts +2 -0
- package/dist/types-ts4.5/card/v2/inlinePlayerV2.d.ts +23 -0
- package/dist/types-ts4.5/utils/ufoExperiences.d.ts +7 -0
- package/package.json +5 -4
package/dist/esm/card/card.js
CHANGED
|
@@ -37,10 +37,10 @@ import { StoreSSRDataScript, getSSRData } from '../utils/globalScope';
|
|
|
37
37
|
import { getCardStateFromFileState, createStateUpdater } from './cardState';
|
|
38
38
|
import { isBigger } from '../utils/dimensionComparer';
|
|
39
39
|
import { getMediaCardCursor } from '../utils/getMediaCardCursor';
|
|
40
|
-
import { completeUfoExperience, startUfoExperience } from '../utils/ufoExperiences';
|
|
40
|
+
import { completeUfoExperience, startUfoExperience, abortUfoExperience } from '../utils/ufoExperiences';
|
|
41
41
|
import { generateUniqueId } from '../utils/generateUniqueId';
|
|
42
42
|
var packageName = "@atlaskit/media-card";
|
|
43
|
-
var packageVersion = "77.
|
|
43
|
+
var packageVersion = "77.2.0";
|
|
44
44
|
export var CardBase = /*#__PURE__*/function (_Component) {
|
|
45
45
|
_inherits(CardBase, _Component);
|
|
46
46
|
var _super = _createSuper(CardBase);
|
|
@@ -108,8 +108,7 @@ export var CardBase = /*#__PURE__*/function (_Component) {
|
|
|
108
108
|
var _this$props2 = _this.props,
|
|
109
109
|
_this$props2$dimensio = _this$props2.dimensions,
|
|
110
110
|
dimensions = _this$props2$dimensio === void 0 ? {} : _this$props2$dimensio,
|
|
111
|
-
mediaClient = _this$props2.mediaClient
|
|
112
|
-
createAnalyticsEvent = _this$props2.createAnalyticsEvent;
|
|
111
|
+
mediaClient = _this$props2.mediaClient;
|
|
113
112
|
return {
|
|
114
113
|
mediaClient: mediaClient,
|
|
115
114
|
id: id,
|
|
@@ -119,8 +118,6 @@ export var CardBase = /*#__PURE__*/function (_Component) {
|
|
|
119
118
|
isRemotePreviewReady: isImageRepresentationReady(fileState),
|
|
120
119
|
imageUrlParams: _this.getImageURLParams(identifier),
|
|
121
120
|
mediaBlobUrlAttrs: _this.getMediaBlobUrlAttrs(identifier, fileState),
|
|
122
|
-
createAnalyticsEvent: createAnalyticsEvent,
|
|
123
|
-
featureFlags: _this.props.featureFlags,
|
|
124
121
|
traceContext: _this.traceContext
|
|
125
122
|
};
|
|
126
123
|
});
|
|
@@ -759,10 +756,8 @@ export var CardBase = /*#__PURE__*/function (_Component) {
|
|
|
759
756
|
mediaClient = _this$props12.mediaClient,
|
|
760
757
|
identifier = _this$props12.identifier,
|
|
761
758
|
dimensions = _this$props12.dimensions,
|
|
762
|
-
featureFlags = _this$props12.featureFlags,
|
|
763
759
|
useInlinePlayer = _this$props12.useInlinePlayer,
|
|
764
760
|
disableOverlay = _this$props12.disableOverlay,
|
|
765
|
-
resizeMode = _this$props12.resizeMode,
|
|
766
761
|
ssr = _this$props12.ssr;
|
|
767
762
|
var _this$state4 = this.state,
|
|
768
763
|
isCardVisible = _this$state4.isCardVisible,
|
|
@@ -789,7 +784,6 @@ export var CardBase = /*#__PURE__*/function (_Component) {
|
|
|
789
784
|
var turnedVisible = !prevIsCardVisible && isCardVisible;
|
|
790
785
|
var hadSSRCardPreview = !!prevCardPreview && isSSRClientPreview(prevCardPreview) && !cardPreview;
|
|
791
786
|
var isNewMediaClient = prevMediaClient !== mediaClient;
|
|
792
|
-
var fileImageMode = imageResizeModeToFileImageMode(resizeMode);
|
|
793
787
|
this.updateFileStateFlag(fileState);
|
|
794
788
|
if (isExternalImageIdentifier(identifier) && isDiffIdentifier) {
|
|
795
789
|
this.fireCommencedEvent();
|
|
@@ -828,9 +822,6 @@ export var CardBase = /*#__PURE__*/function (_Component) {
|
|
|
828
822
|
fileState: fileState,
|
|
829
823
|
prevDimensions: prevDimensions,
|
|
830
824
|
dimensions: dimensions,
|
|
831
|
-
identifier: identifier,
|
|
832
|
-
fileImageMode: fileImageMode,
|
|
833
|
-
featureFlags: featureFlags,
|
|
834
825
|
hasCardPreview: !!cardPreview,
|
|
835
826
|
isBannedLocalPreview: isBannedLocalPreview,
|
|
836
827
|
wasResolvedUpfrontPreview: wasResolvedUpfrontPreview
|
|
@@ -864,6 +855,7 @@ export var CardBase = /*#__PURE__*/function (_Component) {
|
|
|
864
855
|
key: "componentWillUnmount",
|
|
865
856
|
value: function componentWillUnmount() {
|
|
866
857
|
var _getDocument2;
|
|
858
|
+
this.fireAbortedEvent();
|
|
867
859
|
this.hasBeenMounted = false;
|
|
868
860
|
this.unsubscribe();
|
|
869
861
|
(_getDocument2 = getDocument()) === null || _getDocument2 === void 0 || _getDocument2.removeEventListener('copy', this.fireCopiedEvent);
|
|
@@ -902,8 +894,7 @@ export var CardBase = /*#__PURE__*/function (_Component) {
|
|
|
902
894
|
occurrenceKey: occurrenceKey
|
|
903
895
|
}).subscribe({
|
|
904
896
|
next: function next(fileState) {
|
|
905
|
-
var
|
|
906
|
-
var newState = getCardStateFromFileState(fileState, isBannedLocalPreview, featureFlags);
|
|
897
|
+
var newState = getCardStateFromFileState(fileState, isBannedLocalPreview);
|
|
907
898
|
_this2.safeSetState(newState);
|
|
908
899
|
},
|
|
909
900
|
error: function error(e) {
|
|
@@ -950,6 +941,19 @@ export var CardBase = /*#__PURE__*/function (_Component) {
|
|
|
950
941
|
createAnalyticsEvent && _fireOperationalEvent(createAnalyticsEvent, status, this.fileAttributes, this.getPerformanceAttributes(), this.ssrReliability, error, this.traceContext, fileState === null || fileState === void 0 ? void 0 : fileState.metadataTraceContext);
|
|
951
942
|
completeUfoExperience(this.internalOccurrenceKey, status, this.fileAttributes, this.fileStateFlags, this.ssrReliability, error);
|
|
952
943
|
}
|
|
944
|
+
}, {
|
|
945
|
+
key: "fireAbortedEvent",
|
|
946
|
+
value: function fireAbortedEvent() {
|
|
947
|
+
var fileAttributes = this.fileAttributes,
|
|
948
|
+
fileStateFlags = this.fileStateFlags,
|
|
949
|
+
ssrReliability = this.ssrReliability;
|
|
950
|
+
// UFO won't abort if it's already in a final state (succeeded, failed, aborted, etc)
|
|
951
|
+
abortUfoExperience(this.internalOccurrenceKey, {
|
|
952
|
+
fileAttributes: fileAttributes,
|
|
953
|
+
fileStateFlags: fileStateFlags,
|
|
954
|
+
ssrReliability: ssrReliability
|
|
955
|
+
});
|
|
956
|
+
}
|
|
953
957
|
}, {
|
|
954
958
|
key: "fireCommencedEvent",
|
|
955
959
|
value: function fireCommencedEvent() {
|
|
@@ -19,7 +19,7 @@ export var createStateUpdater = function createStateUpdater(newState, fireErrorE
|
|
|
19
19
|
return newState;
|
|
20
20
|
};
|
|
21
21
|
};
|
|
22
|
-
export var getCardStateFromFileState = function getCardStateFromFileState(fileState, isBannedLocalPreview
|
|
22
|
+
export var getCardStateFromFileState = function getCardStateFromFileState(fileState, isBannedLocalPreview) {
|
|
23
23
|
var status = getCardStatus(fileState.status, extractFilePreviewStatus(fileState, isBannedLocalPreview));
|
|
24
24
|
var error = status === 'error' && isErrorFileState(fileState) ? new MediaCardError('error-file-state', new Error(fileState.message)) : undefined;
|
|
25
25
|
var progress = status === 'uploading' && fileState.status === 'uploading' ? fileState.progress : 1;
|
|
@@ -64,11 +64,11 @@ var extendAndCachePreview = function extendAndCachePreview(id, mode, preview, me
|
|
|
64
64
|
*/
|
|
65
65
|
export var getCardPreview = /*#__PURE__*/function () {
|
|
66
66
|
var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(_ref) {
|
|
67
|
-
var mediaClient, id, _ref$dimensions, dimensions, filePreview, onLocalPreviewError, isRemotePreviewReady, imageUrlParams, mediaBlobUrlAttrs,
|
|
67
|
+
var mediaClient, id, _ref$dimensions, dimensions, filePreview, onLocalPreviewError, isRemotePreviewReady, imageUrlParams, mediaBlobUrlAttrs, traceContext, mode, cachedPreview, dimensionsAreBigger, localPreview, remotePreview;
|
|
68
68
|
return _regeneratorRuntime.wrap(function _callee$(_context) {
|
|
69
69
|
while (1) switch (_context.prev = _context.next) {
|
|
70
70
|
case 0:
|
|
71
|
-
mediaClient = _ref.mediaClient, id = _ref.id, _ref$dimensions = _ref.dimensions, dimensions = _ref$dimensions === void 0 ? {} : _ref$dimensions, filePreview = _ref.filePreview, onLocalPreviewError = _ref.onLocalPreviewError, isRemotePreviewReady = _ref.isRemotePreviewReady, imageUrlParams = _ref.imageUrlParams, mediaBlobUrlAttrs = _ref.mediaBlobUrlAttrs,
|
|
71
|
+
mediaClient = _ref.mediaClient, id = _ref.id, _ref$dimensions = _ref.dimensions, dimensions = _ref$dimensions === void 0 ? {} : _ref$dimensions, filePreview = _ref.filePreview, onLocalPreviewError = _ref.onLocalPreviewError, isRemotePreviewReady = _ref.isRemotePreviewReady, imageUrlParams = _ref.imageUrlParams, mediaBlobUrlAttrs = _ref.mediaBlobUrlAttrs, traceContext = _ref.traceContext;
|
|
72
72
|
mode = imageUrlParams.mode;
|
|
73
73
|
cachedPreview = cardPreviewCache.get(id, mode);
|
|
74
74
|
dimensionsAreBigger = isBigger(cachedPreview === null || cachedPreview === void 0 ? void 0 : cachedPreview.dimensions, dimensions);
|
|
@@ -145,11 +145,8 @@ export var shouldResolvePreview = function shouldResolvePreview(_ref3) {
|
|
|
145
145
|
fileState = _ref3.fileState,
|
|
146
146
|
prevDimensions = _ref3.prevDimensions,
|
|
147
147
|
dimensions = _ref3.dimensions,
|
|
148
|
-
identifier = _ref3.identifier,
|
|
149
|
-
fileImageMode = _ref3.fileImageMode,
|
|
150
148
|
hasCardPreview = _ref3.hasCardPreview,
|
|
151
149
|
isBannedLocalPreview = _ref3.isBannedLocalPreview,
|
|
152
|
-
featureFlags = _ref3.featureFlags,
|
|
153
150
|
wasResolvedUpfrontPreview = _ref3.wasResolvedUpfrontPreview;
|
|
154
151
|
var statusIsPreviewable = isPreviewableStatus(status, extractFilePreviewStatus(fileState, isBannedLocalPreview));
|
|
155
152
|
var dimensionsAreBigger = isBigger(prevDimensions, dimensions);
|
|
@@ -83,7 +83,7 @@ var WrappedMediaCardAnalyticsErrorBoundary = /*#__PURE__*/function (_React$Compo
|
|
|
83
83
|
}(React.Component);
|
|
84
84
|
_defineProperty(WrappedMediaCardAnalyticsErrorBoundary, "displayName", 'MediaCardAnalyticsErrorBoundary');
|
|
85
85
|
var packageName = "@atlaskit/media-card";
|
|
86
|
-
var packageVersion = "77.
|
|
86
|
+
var packageVersion = "77.2.0";
|
|
87
87
|
var MediaCardAnalyticsErrorBoundary = withMediaAnalyticsContext({
|
|
88
88
|
packageVersion: packageVersion,
|
|
89
89
|
packageName: packageName,
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
import { useMemo } from 'react';
|
|
2
|
+
import { calcBreakpointSize } from './ui/styles';
|
|
3
|
+
import { getElementDimension, isValidPercentageUnit, defaultImageCardDimensions } from '../utils';
|
|
4
|
+
|
|
5
|
+
// Hook to calculate the breakpoint based on the width of the element
|
|
6
|
+
export var useBreakpoint = function useBreakpoint() {
|
|
7
|
+
var dimensionWidth = arguments.length > 0 && arguments[0] !== undefined ? arguments[0] : 0;
|
|
8
|
+
var divRef = arguments.length > 1 ? arguments[1] : undefined;
|
|
9
|
+
var breakpoint = useMemo(function () {
|
|
10
|
+
var widthToCalculate;
|
|
11
|
+
if (dimensionWidth) {
|
|
12
|
+
if (isValidPercentageUnit(dimensionWidth) && divRef.current) {
|
|
13
|
+
var width = getElementDimension(divRef.current, 'width');
|
|
14
|
+
widthToCalculate = width || defaultImageCardDimensions.width;
|
|
15
|
+
} else {
|
|
16
|
+
widthToCalculate = dimensionWidth;
|
|
17
|
+
}
|
|
18
|
+
} else {
|
|
19
|
+
widthToCalculate = defaultImageCardDimensions.width;
|
|
20
|
+
}
|
|
21
|
+
return calcBreakpointSize(parseInt("".concat(widthToCalculate), 10));
|
|
22
|
+
}, [dimensionWidth, divRef]);
|
|
23
|
+
return breakpoint;
|
|
24
|
+
};
|
|
@@ -28,7 +28,7 @@ import { videoIsPlayable } from '../../utils/videoIsPlayable';
|
|
|
28
28
|
import { getRequestedDimensions } from '../../utils/getDataURIDimension';
|
|
29
29
|
import { getCardPreview, getCardPreviewFromCache, removeCardPreviewFromCache, getFilePreviewFromFileState, shouldResolvePreview, getSSRCardPreview, isLocalPreview, isSSRPreview, isSSRClientPreview, isSSRDataPreview, fetchAndCacheRemotePreview } from '../getCardPreview';
|
|
30
30
|
import { getFileDetails } from '../../utils/metadata';
|
|
31
|
-
import {
|
|
31
|
+
import { InlinePlayerLazyV2 } from './inlinePlayerLazyV2';
|
|
32
32
|
import { getFileAttributes, extractErrorInfo } from '../../utils/analytics';
|
|
33
33
|
import { isLocalPreviewError, MediaCardError, MediaFileStateError, ensureMediaCardError, ImageLoadError } from '../../errors';
|
|
34
34
|
import { fireOperationalEvent as _fireOperationalEvent, fireCommencedEvent as _fireCommencedEvent, fireCopiedEvent, fireScreenEvent, fireNonCriticalErrorEvent } from '../cardAnalytics';
|
|
@@ -37,11 +37,11 @@ import { StoreSSRDataScript, getSSRData } from '../../utils/globalScope';
|
|
|
37
37
|
import { getCardStateFromFileState, createStateUpdater } from '../cardState';
|
|
38
38
|
import { isBigger } from '../../utils/dimensionComparer';
|
|
39
39
|
import { getMediaCardCursor } from '../../utils/getMediaCardCursor';
|
|
40
|
-
import { completeUfoExperience, startUfoExperience } from '../../utils/ufoExperiences';
|
|
40
|
+
import { completeUfoExperience, startUfoExperience, abortUfoExperience } from '../../utils/ufoExperiences';
|
|
41
41
|
import { generateUniqueId } from '../../utils/generateUniqueId';
|
|
42
42
|
import { useFileState } from '@atlaskit/media-client-react';
|
|
43
43
|
var packageName = "@atlaskit/media-card";
|
|
44
|
-
var packageVersion = "77.
|
|
44
|
+
var packageVersion = "77.2.0";
|
|
45
45
|
export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
46
46
|
_inherits(CardV2Base, _Component);
|
|
47
47
|
var _super = _createSuper(CardV2Base);
|
|
@@ -109,8 +109,7 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
109
109
|
var _this$props2 = _this.props,
|
|
110
110
|
_this$props2$dimensio = _this$props2.dimensions,
|
|
111
111
|
dimensions = _this$props2$dimensio === void 0 ? {} : _this$props2$dimensio,
|
|
112
|
-
mediaClient = _this$props2.mediaClient
|
|
113
|
-
createAnalyticsEvent = _this$props2.createAnalyticsEvent;
|
|
112
|
+
mediaClient = _this$props2.mediaClient;
|
|
114
113
|
return {
|
|
115
114
|
mediaClient: mediaClient,
|
|
116
115
|
id: id,
|
|
@@ -120,8 +119,6 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
120
119
|
isRemotePreviewReady: isImageRepresentationReady(fileState),
|
|
121
120
|
imageUrlParams: _this.getImageURLParams(identifier),
|
|
122
121
|
mediaBlobUrlAttrs: _this.getMediaBlobUrlAttrs(identifier, fileState),
|
|
123
|
-
createAnalyticsEvent: createAnalyticsEvent,
|
|
124
|
-
featureFlags: _this.props.featureFlags,
|
|
125
122
|
traceContext: _this.traceContext
|
|
126
123
|
};
|
|
127
124
|
});
|
|
@@ -264,8 +261,7 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
264
261
|
_defineProperty(_assertThisInitialized(_this), "subscribeFileState", function (fileState) {
|
|
265
262
|
var isBannedLocalPreview = _this.state.isBannedLocalPreview;
|
|
266
263
|
if (fileState.status !== 'error') {
|
|
267
|
-
var
|
|
268
|
-
var newState = getCardStateFromFileState(fileState, isBannedLocalPreview, featureFlags);
|
|
264
|
+
var newState = getCardStateFromFileState(fileState, isBannedLocalPreview);
|
|
269
265
|
_this.safeSetState(newState);
|
|
270
266
|
} else {
|
|
271
267
|
var e = new MediaFileStateError(fileState.id, fileState.reason, fileState.message, fileState.details);
|
|
@@ -447,7 +443,6 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
447
443
|
_defineProperty(_assertThisInitialized(_this), "renderInlinePlayer", function () {
|
|
448
444
|
var _this$props6 = _this.props,
|
|
449
445
|
identifier = _this$props6.identifier,
|
|
450
|
-
mediaClient = _this$props6.mediaClient,
|
|
451
446
|
dimensions = _this$props6.dimensions,
|
|
452
447
|
selected = _this$props6.selected,
|
|
453
448
|
testId = _this$props6.testId,
|
|
@@ -459,8 +454,7 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
459
454
|
var card = _this.renderCard(false, 'loading', false);
|
|
460
455
|
return /*#__PURE__*/React.createElement(Suspense, {
|
|
461
456
|
fallback: card
|
|
462
|
-
}, /*#__PURE__*/React.createElement(
|
|
463
|
-
mediaClient: mediaClient,
|
|
457
|
+
}, /*#__PURE__*/React.createElement(InlinePlayerLazyV2, {
|
|
464
458
|
dimensions: dimensions,
|
|
465
459
|
originalDimensions: originalDimensions,
|
|
466
460
|
identifier: identifier,
|
|
@@ -727,7 +721,7 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
727
721
|
ssr = _this$props11.ssr,
|
|
728
722
|
dimensions = _this$props11.dimensions;
|
|
729
723
|
if (isCardVisible && isFileIdentifier(identifier)) {
|
|
730
|
-
this.updateStateForIdentifier(
|
|
724
|
+
this.updateStateForIdentifier();
|
|
731
725
|
if (!cardPreview) {
|
|
732
726
|
this.resolveUpfrontPreview(identifier);
|
|
733
727
|
}
|
|
@@ -764,10 +758,8 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
764
758
|
mediaClient = _this$props12.mediaClient,
|
|
765
759
|
identifier = _this$props12.identifier,
|
|
766
760
|
dimensions = _this$props12.dimensions,
|
|
767
|
-
featureFlags = _this$props12.featureFlags,
|
|
768
761
|
useInlinePlayer = _this$props12.useInlinePlayer,
|
|
769
762
|
disableOverlay = _this$props12.disableOverlay,
|
|
770
|
-
resizeMode = _this$props12.resizeMode,
|
|
771
763
|
ssr = _this$props12.ssr;
|
|
772
764
|
var _this$state4 = this.state,
|
|
773
765
|
isCardVisible = _this$state4.isCardVisible,
|
|
@@ -794,7 +786,6 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
794
786
|
var turnedVisible = !prevIsCardVisible && isCardVisible;
|
|
795
787
|
var hadSSRCardPreview = !!prevCardPreview && isSSRClientPreview(prevCardPreview) && !cardPreview;
|
|
796
788
|
var isNewMediaClient = prevMediaClient !== mediaClient;
|
|
797
|
-
var fileImageMode = imageResizeModeToFileImageMode(resizeMode);
|
|
798
789
|
this.updateFileStateFlag(fileState);
|
|
799
790
|
if (isExternalImageIdentifier(identifier) && isDiffIdentifier) {
|
|
800
791
|
this.fireCommencedEvent();
|
|
@@ -815,7 +806,7 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
815
806
|
this.refetchSSRPreview(identifier);
|
|
816
807
|
}
|
|
817
808
|
if (isFileIdentifier(identifier) && (turnedVisible || !!this.subscription && (isNewMediaClient || isDiffIdentifier))) {
|
|
818
|
-
this.updateStateForIdentifier(
|
|
809
|
+
this.updateStateForIdentifier();
|
|
819
810
|
}
|
|
820
811
|
if (this.state.status !== prevState.status) {
|
|
821
812
|
this.fireOperationalEvent();
|
|
@@ -833,9 +824,6 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
833
824
|
fileState: fileState,
|
|
834
825
|
prevDimensions: prevDimensions,
|
|
835
826
|
dimensions: dimensions,
|
|
836
|
-
identifier: identifier,
|
|
837
|
-
fileImageMode: fileImageMode,
|
|
838
|
-
featureFlags: featureFlags,
|
|
839
827
|
hasCardPreview: !!cardPreview,
|
|
840
828
|
isBannedLocalPreview: isBannedLocalPreview,
|
|
841
829
|
wasResolvedUpfrontPreview: wasResolvedUpfrontPreview
|
|
@@ -875,12 +863,13 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
875
863
|
key: "componentWillUnmount",
|
|
876
864
|
value: function componentWillUnmount() {
|
|
877
865
|
var _getDocument2;
|
|
866
|
+
this.fireAbortedEvent();
|
|
878
867
|
this.hasBeenMounted = false;
|
|
879
868
|
(_getDocument2 = getDocument()) === null || _getDocument2 === void 0 || _getDocument2.removeEventListener('copy', this.fireCopiedEvent);
|
|
880
869
|
}
|
|
881
870
|
}, {
|
|
882
871
|
key: "updateStateForIdentifier",
|
|
883
|
-
value: function updateStateForIdentifier(
|
|
872
|
+
value: function updateStateForIdentifier() {
|
|
884
873
|
this.fireCommencedEvent();
|
|
885
874
|
this.setState({
|
|
886
875
|
shouldUpdateStateForIdentifier: true
|
|
@@ -945,6 +934,19 @@ export var CardV2Base = /*#__PURE__*/function (_Component) {
|
|
|
945
934
|
}, this.traceContext);
|
|
946
935
|
startUfoExperience(this.internalOccurrenceKey);
|
|
947
936
|
}
|
|
937
|
+
}, {
|
|
938
|
+
key: "fireAbortedEvent",
|
|
939
|
+
value: function fireAbortedEvent() {
|
|
940
|
+
var fileAttributes = this.fileAttributes,
|
|
941
|
+
fileStateFlags = this.fileStateFlags,
|
|
942
|
+
ssrReliability = this.ssrReliability;
|
|
943
|
+
// UFO won't abort if it's already in a final state (succeeded, failed, aborted, etc)
|
|
944
|
+
abortUfoExperience(this.internalOccurrenceKey, {
|
|
945
|
+
fileAttributes: fileAttributes,
|
|
946
|
+
fileStateFlags: fileStateFlags,
|
|
947
|
+
ssrReliability: ssrReliability
|
|
948
|
+
});
|
|
949
|
+
}
|
|
948
950
|
}, {
|
|
949
951
|
key: "actions",
|
|
950
952
|
get: function get() {
|
|
@@ -4,18 +4,15 @@ function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbol
|
|
|
4
4
|
function _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }
|
|
5
5
|
/** @jsx jsx */
|
|
6
6
|
import { jsx } from '@emotion/react';
|
|
7
|
-
import React, { useEffect, useState, useRef
|
|
7
|
+
import React, { useEffect, useState, useRef } from 'react';
|
|
8
8
|
import { withAnalyticsEvents } from '@atlaskit/analytics-next';
|
|
9
9
|
import { MimeTypeIcon } from '@atlaskit/media-ui/mime-type-icon';
|
|
10
10
|
import SpinnerIcon from '@atlaskit/spinner';
|
|
11
11
|
import Tooltip from '@atlaskit/tooltip';
|
|
12
12
|
import { messages } from '@atlaskit/media-ui';
|
|
13
|
-
import { defaultImageCardDimensions } from '../../utils/cardDimensions';
|
|
14
|
-
import { isValidPercentageUnit } from '../../utils/isValidPercentageUnit';
|
|
15
|
-
import { getElementDimension } from '../../utils/getElementDimension';
|
|
16
13
|
import { createAndFireMediaCardEvent } from '../../utils/analytics';
|
|
17
14
|
import { attachDetailsToActions } from '../actions';
|
|
18
|
-
import { cardImageContainerStyles
|
|
15
|
+
import { cardImageContainerStyles } from '../ui/styles';
|
|
19
16
|
import { ImageRenderer } from '../ui/imageRenderer/imageRenderer';
|
|
20
17
|
import { TitleBox } from '../ui/titleBox/titleBox';
|
|
21
18
|
import { FailedTitleBox } from '../ui/titleBox/failedTitleBox';
|
|
@@ -29,6 +26,7 @@ import { PreviewUnavailable, CreatingPreview, FailedToUpload, PreviewCurrentlyUn
|
|
|
29
26
|
import { isUploadError, isRateLimitedError, isPollingError } from '../../errors';
|
|
30
27
|
import { Wrapper } from '../ui/wrapper';
|
|
31
28
|
import { fileCardImageViewSelector } from '../classnames';
|
|
29
|
+
import { useBreakpoint } from '../useBreakpoint';
|
|
32
30
|
export var CardViewV2Base = function CardViewV2Base(_ref) {
|
|
33
31
|
var innerRef = _ref.innerRef,
|
|
34
32
|
onImageLoad = _ref.onImageLoad,
|
|
@@ -58,24 +56,13 @@ export var CardViewV2Base = function CardViewV2Base(_ref) {
|
|
|
58
56
|
titleBoxIcon = _ref.titleBoxIcon,
|
|
59
57
|
error = _ref.error,
|
|
60
58
|
disableAnimation = _ref.disableAnimation;
|
|
61
|
-
var _useState = useState(),
|
|
59
|
+
var _useState = useState(false),
|
|
62
60
|
_useState2 = _slicedToArray(_useState, 2),
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
var _useState3 = useState(false),
|
|
66
|
-
_useState4 = _slicedToArray(_useState3, 2),
|
|
67
|
-
didImageRender = _useState4[0],
|
|
68
|
-
setDidImageRender = _useState4[1];
|
|
61
|
+
didImageRender = _useState2[0],
|
|
62
|
+
setDidImageRender = _useState2[1];
|
|
69
63
|
var divRef = useRef(null);
|
|
70
64
|
var prevCardPreviewRef = useRef();
|
|
71
|
-
var
|
|
72
|
-
useEffect(function () {
|
|
73
|
-
// If the dimensions.width is a percentage, we need to transform it into a pixel value in order to get the right breakpoints applied.
|
|
74
|
-
if (width && isValidPercentageUnit(width) && !!divRef.current) {
|
|
75
|
-
var _elementWidth = getElementDimension(divRef.current, 'width');
|
|
76
|
-
setElementWidth(_elementWidth);
|
|
77
|
-
}
|
|
78
|
-
}, [width]);
|
|
65
|
+
var breakpoint = useBreakpoint(dimensions === null || dimensions === void 0 ? void 0 : dimensions.width, divRef);
|
|
79
66
|
useEffect(function () {
|
|
80
67
|
innerRef && !!divRef.current && innerRef(divRef.current);
|
|
81
68
|
}, [innerRef]);
|
|
@@ -105,10 +92,6 @@ export var CardViewV2Base = function CardViewV2Base(_ref) {
|
|
|
105
92
|
setDidImageRender(false);
|
|
106
93
|
onImageError === null || onImageError === void 0 || onImageError(cardPreview);
|
|
107
94
|
};
|
|
108
|
-
var breakpoint = useMemo(function () {
|
|
109
|
-
var width = elementWidth || (dimensions ? dimensions.width : '') || defaultImageCardDimensions.width;
|
|
110
|
-
return calcBreakpointSize(parseInt("".concat(width), 10));
|
|
111
|
-
}, [elementWidth, dimensions]);
|
|
112
95
|
var shouldRenderPlayButton = function shouldRenderPlayButton() {
|
|
113
96
|
var _ref2 = metadata || {},
|
|
114
97
|
mediaType = _ref2.mediaType;
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
2
|
+
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
3
|
+
import { lazy } from 'react';
|
|
4
|
+
export var InlinePlayerLazyV2 = /*#__PURE__*/lazy( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee() {
|
|
5
|
+
var _yield$import, InlinePlayerV2;
|
|
6
|
+
return _regeneratorRuntime.wrap(function _callee$(_context) {
|
|
7
|
+
while (1) switch (_context.prev = _context.next) {
|
|
8
|
+
case 0:
|
|
9
|
+
_context.next = 2;
|
|
10
|
+
return import( /* webpackChunkName: "@atlaskit-internal_media-card-inlineplayer-v2" */
|
|
11
|
+
'./inlinePlayerV2');
|
|
12
|
+
case 2:
|
|
13
|
+
_yield$import = _context.sent;
|
|
14
|
+
InlinePlayerV2 = _yield$import.InlinePlayerV2;
|
|
15
|
+
return _context.abrupt("return", {
|
|
16
|
+
default: InlinePlayerV2
|
|
17
|
+
});
|
|
18
|
+
case 5:
|
|
19
|
+
case "end":
|
|
20
|
+
return _context.stop();
|
|
21
|
+
}
|
|
22
|
+
}, _callee);
|
|
23
|
+
})));
|
|
@@ -0,0 +1,212 @@
|
|
|
1
|
+
import _extends from "@babel/runtime/helpers/extends";
|
|
2
|
+
import _asyncToGenerator from "@babel/runtime/helpers/asyncToGenerator";
|
|
3
|
+
import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
|
|
4
|
+
import _regeneratorRuntime from "@babel/runtime/regenerator";
|
|
5
|
+
import React, { useRef, useState, useEffect } from 'react';
|
|
6
|
+
import { globalMediaEventEmitter } from '@atlaskit/media-client';
|
|
7
|
+
import { CustomMediaPlayer, InactivityDetector } from '@atlaskit/media-ui';
|
|
8
|
+
import { defaultImageCardDimensions } from '../../utils';
|
|
9
|
+
import { CardLoading } from '../../utils/lightCards/cardLoading';
|
|
10
|
+
import { ProgressBar } from '../ui/progressBar/progressBar';
|
|
11
|
+
import { InlinePlayerWrapper } from '../inlinePlayerWrapper';
|
|
12
|
+
import { useBreakpoint } from '../useBreakpoint';
|
|
13
|
+
import { useFileState, useMediaClient } from '@atlaskit/media-client-react';
|
|
14
|
+
export var getPreferredVideoArtifact = function getPreferredVideoArtifact(fileState) {
|
|
15
|
+
if (fileState.status === 'processed' || fileState.status === 'processing') {
|
|
16
|
+
var artifacts = fileState.artifacts;
|
|
17
|
+
if (!artifacts) {
|
|
18
|
+
return undefined;
|
|
19
|
+
}
|
|
20
|
+
return artifacts['video_1280.mp4'] ? 'video_1280.mp4' : artifacts['video_640.mp4'] ? 'video_640.mp4' : undefined;
|
|
21
|
+
}
|
|
22
|
+
return undefined;
|
|
23
|
+
};
|
|
24
|
+
export var InlinePlayerBaseV2 = function InlinePlayerBaseV2(_ref) {
|
|
25
|
+
var identifier = _ref.identifier,
|
|
26
|
+
onError = _ref.onError,
|
|
27
|
+
onClick = _ref.onClick,
|
|
28
|
+
_ref$dimensions = _ref.dimensions,
|
|
29
|
+
dimensions = _ref$dimensions === void 0 ? defaultImageCardDimensions : _ref$dimensions,
|
|
30
|
+
originalDimensions = _ref.originalDimensions,
|
|
31
|
+
selected = _ref.selected,
|
|
32
|
+
testId = _ref.testId,
|
|
33
|
+
forwardRef = _ref.forwardRef,
|
|
34
|
+
autoplay = _ref.autoplay,
|
|
35
|
+
cardPreview = _ref.cardPreview,
|
|
36
|
+
onFullscreenChange = _ref.onFullscreenChange;
|
|
37
|
+
// === States ===
|
|
38
|
+
var _useState = useState(),
|
|
39
|
+
_useState2 = _slicedToArray(_useState, 2),
|
|
40
|
+
fileSrc = _useState2[0],
|
|
41
|
+
setFileSrc = _useState2[1];
|
|
42
|
+
var _useState3 = useState(),
|
|
43
|
+
_useState4 = _slicedToArray(_useState3, 2),
|
|
44
|
+
isUploading = _useState4[0],
|
|
45
|
+
setIsUploading = _useState4[1];
|
|
46
|
+
var _useState5 = useState(),
|
|
47
|
+
_useState6 = _slicedToArray(_useState5, 2),
|
|
48
|
+
progress = _useState6[0],
|
|
49
|
+
setProgress = _useState6[1];
|
|
50
|
+
|
|
51
|
+
// === Refs and Local Variables ===
|
|
52
|
+
var divRef = useRef(null);
|
|
53
|
+
var onErrorRef = useRef(onError);
|
|
54
|
+
onErrorRef.current = onError;
|
|
55
|
+
var id = identifier.id,
|
|
56
|
+
collectionName = identifier.collectionName,
|
|
57
|
+
occurrenceKey = identifier.occurrenceKey;
|
|
58
|
+
var breakpoint = useBreakpoint(dimensions === null || dimensions === void 0 ? void 0 : dimensions.width, divRef);
|
|
59
|
+
var mediaClient = useMediaClient();
|
|
60
|
+
var _useFileState = useFileState(id, {
|
|
61
|
+
collectionName: collectionName,
|
|
62
|
+
occurrenceKey: occurrenceKey
|
|
63
|
+
}),
|
|
64
|
+
fileState = _useFileState.fileState;
|
|
65
|
+
useEffect(function () {
|
|
66
|
+
var subscribeFileState = /*#__PURE__*/function () {
|
|
67
|
+
var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime.mark(function _callee(fileState) {
|
|
68
|
+
var _yield$fileState$prev, value, newFileSrc, artifactName, artifacts, _newFileSrc, _newFileSrc2;
|
|
69
|
+
return _regeneratorRuntime.wrap(function _callee$(_context) {
|
|
70
|
+
while (1) switch (_context.prev = _context.next) {
|
|
71
|
+
case 0:
|
|
72
|
+
if (fileState.status === 'uploading') {
|
|
73
|
+
setIsUploading(true);
|
|
74
|
+
setProgress(fileState.progress);
|
|
75
|
+
} else {
|
|
76
|
+
setIsUploading(false);
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
// We reuse the existing fileSrc to prevent re renders, therefore we only perform fileSrc updates when there isn't any
|
|
80
|
+
if (!fileSrc) {
|
|
81
|
+
_context.next = 3;
|
|
82
|
+
break;
|
|
83
|
+
}
|
|
84
|
+
return _context.abrupt("return");
|
|
85
|
+
case 3:
|
|
86
|
+
if (!(fileState.status !== 'error' && fileState.preview)) {
|
|
87
|
+
_context.next = 12;
|
|
88
|
+
break;
|
|
89
|
+
}
|
|
90
|
+
_context.next = 6;
|
|
91
|
+
return fileState.preview;
|
|
92
|
+
case 6:
|
|
93
|
+
_yield$fileState$prev = _context.sent;
|
|
94
|
+
value = _yield$fileState$prev.value;
|
|
95
|
+
if (!(value instanceof Blob && value.type.indexOf('video/') === 0)) {
|
|
96
|
+
_context.next = 12;
|
|
97
|
+
break;
|
|
98
|
+
}
|
|
99
|
+
newFileSrc = URL.createObjectURL(value);
|
|
100
|
+
setFileSrc(newFileSrc);
|
|
101
|
+
return _context.abrupt("return");
|
|
102
|
+
case 12:
|
|
103
|
+
if (!(fileState.status === 'processed' || fileState.status === 'processing')) {
|
|
104
|
+
_context.next = 37;
|
|
105
|
+
break;
|
|
106
|
+
}
|
|
107
|
+
artifactName = getPreferredVideoArtifact(fileState);
|
|
108
|
+
artifacts = fileState.artifacts;
|
|
109
|
+
if (!(!artifactName || !artifacts)) {
|
|
110
|
+
_context.next = 27;
|
|
111
|
+
break;
|
|
112
|
+
}
|
|
113
|
+
_context.prev = 16;
|
|
114
|
+
_context.next = 19;
|
|
115
|
+
return mediaClient.file.getFileBinaryURL(id, collectionName);
|
|
116
|
+
case 19:
|
|
117
|
+
_newFileSrc = _context.sent;
|
|
118
|
+
setFileSrc(_newFileSrc);
|
|
119
|
+
_context.next = 26;
|
|
120
|
+
break;
|
|
121
|
+
case 23:
|
|
122
|
+
_context.prev = 23;
|
|
123
|
+
_context.t0 = _context["catch"](16);
|
|
124
|
+
if (onErrorRef.current && _context.t0 instanceof Error) {
|
|
125
|
+
onErrorRef.current(_context.t0);
|
|
126
|
+
}
|
|
127
|
+
case 26:
|
|
128
|
+
return _context.abrupt("return");
|
|
129
|
+
case 27:
|
|
130
|
+
_context.prev = 27;
|
|
131
|
+
_context.next = 30;
|
|
132
|
+
return mediaClient.file.getArtifactURL(artifacts, artifactName, collectionName);
|
|
133
|
+
case 30:
|
|
134
|
+
_newFileSrc2 = _context.sent;
|
|
135
|
+
setFileSrc(_newFileSrc2);
|
|
136
|
+
_context.next = 37;
|
|
137
|
+
break;
|
|
138
|
+
case 34:
|
|
139
|
+
_context.prev = 34;
|
|
140
|
+
_context.t1 = _context["catch"](27);
|
|
141
|
+
if (onErrorRef.current && _context.t1 instanceof Error) {
|
|
142
|
+
onErrorRef.current(_context.t1);
|
|
143
|
+
}
|
|
144
|
+
case 37:
|
|
145
|
+
case "end":
|
|
146
|
+
return _context.stop();
|
|
147
|
+
}
|
|
148
|
+
}, _callee, null, [[16, 23], [27, 34]]);
|
|
149
|
+
}));
|
|
150
|
+
return function subscribeFileState(_x) {
|
|
151
|
+
return _ref2.apply(this, arguments);
|
|
152
|
+
};
|
|
153
|
+
}();
|
|
154
|
+
if (fileState) {
|
|
155
|
+
subscribeFileState(fileState);
|
|
156
|
+
}
|
|
157
|
+
}, [fileState, collectionName, fileSrc, id, mediaClient]);
|
|
158
|
+
useEffect(function () {
|
|
159
|
+
return function () {
|
|
160
|
+
fileSrc && URL.revokeObjectURL(fileSrc);
|
|
161
|
+
};
|
|
162
|
+
}, [fileSrc]);
|
|
163
|
+
|
|
164
|
+
// === Render ===
|
|
165
|
+
return fileSrc ? /*#__PURE__*/React.createElement(InlinePlayerWrapper, {
|
|
166
|
+
testId: testId || 'media-card-inline-player',
|
|
167
|
+
selected: {
|
|
168
|
+
selected: selected
|
|
169
|
+
},
|
|
170
|
+
onClick: onClick,
|
|
171
|
+
innerRef: forwardRef || undefined,
|
|
172
|
+
dimensions: dimensions
|
|
173
|
+
}, /*#__PURE__*/React.createElement(InactivityDetector, null, function (checkMouseMovement) {
|
|
174
|
+
return /*#__PURE__*/React.createElement(CustomMediaPlayer, {
|
|
175
|
+
type: "video",
|
|
176
|
+
src: fileSrc,
|
|
177
|
+
onFullscreenChange: onFullscreenChange,
|
|
178
|
+
fileId: id,
|
|
179
|
+
isAutoPlay: autoplay,
|
|
180
|
+
isHDAvailable: false,
|
|
181
|
+
onDownloadClick: function onDownloadClick() {
|
|
182
|
+
mediaClient.file.downloadBinary(id, undefined, collectionName);
|
|
183
|
+
},
|
|
184
|
+
onFirstPlay: function onFirstPlay() {
|
|
185
|
+
globalMediaEventEmitter.emit('media-viewed', {
|
|
186
|
+
fileId: id,
|
|
187
|
+
viewingLevel: 'full'
|
|
188
|
+
});
|
|
189
|
+
},
|
|
190
|
+
lastWatchTimeConfig: {
|
|
191
|
+
contentId: id
|
|
192
|
+
},
|
|
193
|
+
originalDimensions: originalDimensions,
|
|
194
|
+
showControls: checkMouseMovement,
|
|
195
|
+
poster: cardPreview === null || cardPreview === void 0 ? void 0 : cardPreview.dataURI
|
|
196
|
+
});
|
|
197
|
+
}), isUploading && /*#__PURE__*/React.createElement(ProgressBar, {
|
|
198
|
+
progress: progress,
|
|
199
|
+
breakpoint: breakpoint,
|
|
200
|
+
positionBottom: true,
|
|
201
|
+
showOnTop: true
|
|
202
|
+
})) : /*#__PURE__*/React.createElement(CardLoading, {
|
|
203
|
+
testId: testId,
|
|
204
|
+
dimensions: dimensions
|
|
205
|
+
});
|
|
206
|
+
};
|
|
207
|
+
var InlinePlayerForwardRef = /*#__PURE__*/React.forwardRef(function (props, ref) {
|
|
208
|
+
return /*#__PURE__*/React.createElement(InlinePlayerBaseV2, _extends({}, props, {
|
|
209
|
+
forwardRef: ref
|
|
210
|
+
}));
|
|
211
|
+
});
|
|
212
|
+
export var InlinePlayerV2 = InlinePlayerForwardRef;
|
|
@@ -103,7 +103,7 @@ var MediaInlineCardLoader = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
103
103
|
ErrorBoundary = _this$state.ErrorBoundary;
|
|
104
104
|
var analyticsContext = {
|
|
105
105
|
packageVersion: "@atlaskit/media-card",
|
|
106
|
-
packageName: "77.
|
|
106
|
+
packageName: "77.2.0",
|
|
107
107
|
componentName: 'mediaInlineCard',
|
|
108
108
|
component: 'mediaInlineCard'
|
|
109
109
|
};
|