@atlaskit/media-card 81.12.8 → 81.12.9
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 +6 -0
- package/dist/cjs/card/card.js +1 -1
- package/dist/cjs/card/cardLoader.js +1 -1
- package/dist/cjs/card/cardWithMediaClient.js +3 -3
- package/dist/cjs/card/fileCard.js +2 -2
- package/dist/cjs/card/fireOperationalEvent.js +1 -1
- package/dist/cjs/card/inlinePlayerWrapper-compiled.js +3 -3
- package/dist/cjs/card/inlinePlayerWrapperStyles.js +1 -1
- package/dist/cjs/card/media-card-analytics-error-boundary.js +3 -3
- package/dist/cjs/card/svgView/svgViewV2.js +2 -2
- package/dist/cjs/card/ui/actionsBar/cardActions/cardActionIconButton.js +1 -1
- package/dist/cjs/card/ui/actionsBar/cardActions/cardActionsDropdownMenu.js +3 -3
- package/dist/cjs/card/ui/imageRenderer/imageRenderer.js +1 -1
- package/dist/cjs/card/ui/imageRenderer/index.js +1 -1
- package/dist/cjs/card/ui/playButton/playButton.js +1 -1
- package/dist/cjs/card/ui/wrapper/wrapper-compiled.js +2 -2
- package/dist/cjs/ensureMediaCardError.js +1 -1
- package/dist/cjs/inline/loader.js +2 -2
- package/dist/cjs/utils/lightCards/cardError.js +1 -1
- package/dist/cjs/utils/ufoExperiences.js +1 -1
- package/dist/es2019/card/card.js +1 -1
- package/dist/es2019/card/cardLoader.js +1 -1
- package/dist/es2019/card/cardWithMediaClient.js +3 -3
- package/dist/es2019/card/fileCard.js +2 -2
- package/dist/es2019/card/fireOperationalEvent.js +2 -1
- package/dist/es2019/card/inlinePlayerWrapper-compiled.js +3 -3
- package/dist/es2019/card/inlinePlayerWrapperStyles.js +1 -1
- package/dist/es2019/card/media-card-analytics-error-boundary.js +3 -3
- package/dist/es2019/card/svgView/svgViewV2.js +4 -3
- package/dist/es2019/card/ui/actionsBar/cardActions/cardActionButton-compiled.js +1 -0
- package/dist/es2019/card/ui/actionsBar/cardActions/cardActionIconButton.js +1 -1
- package/dist/es2019/card/ui/actionsBar/cardActions/cardActionsDropdownMenu.js +3 -3
- package/dist/es2019/card/ui/imageRenderer/imageRenderer.js +1 -1
- package/dist/es2019/card/ui/imageRenderer/index.js +1 -1
- package/dist/es2019/card/ui/playButton/playButton.js +1 -1
- package/dist/es2019/card/ui/playButton/playButtonBackground.js +1 -0
- package/dist/es2019/card/ui/wrapper/wrapper-compiled.js +2 -2
- package/dist/es2019/ensureMediaCardError.js +1 -1
- package/dist/es2019/inline/loader.js +2 -2
- package/dist/es2019/inline/mediaInlineCardAnalytics.js +1 -0
- package/dist/es2019/utils/getMediaCardCursor.js +1 -0
- package/dist/es2019/utils/lightCards/cardError.js +1 -1
- package/dist/es2019/utils/lightCards/errorIcon/index.js +2 -1
- package/dist/es2019/utils/lightCards/errorIcon/styles.js +0 -1
- package/dist/es2019/utils/lightCards/lightCardWrappers.js +1 -0
- package/dist/es2019/utils/ufoExperiences.js +1 -1
- package/dist/esm/card/card.js +1 -1
- package/dist/esm/card/cardLoader.js +1 -1
- package/dist/esm/card/cardWithMediaClient.js +3 -3
- package/dist/esm/card/fileCard.js +2 -2
- package/dist/esm/card/fireOperationalEvent.js +2 -1
- package/dist/esm/card/inlinePlayerWrapper-compiled.js +3 -3
- package/dist/esm/card/inlinePlayerWrapperStyles.js +1 -1
- package/dist/esm/card/media-card-analytics-error-boundary.js +3 -3
- package/dist/esm/card/svgView/svgViewV2.js +4 -3
- package/dist/esm/card/ui/actionsBar/cardActions/cardActionButton-compiled.js +1 -0
- package/dist/esm/card/ui/actionsBar/cardActions/cardActionIconButton.js +1 -1
- package/dist/esm/card/ui/actionsBar/cardActions/cardActionsDropdownMenu.js +3 -3
- package/dist/esm/card/ui/imageRenderer/imageRenderer.js +1 -1
- package/dist/esm/card/ui/imageRenderer/index.js +1 -1
- package/dist/esm/card/ui/playButton/playButton.js +1 -1
- package/dist/esm/card/ui/playButton/playButtonBackground.js +1 -0
- package/dist/esm/card/ui/wrapper/wrapper-compiled.js +2 -2
- package/dist/esm/ensureMediaCardError.js +1 -1
- package/dist/esm/inline/loader.js +2 -2
- package/dist/esm/inline/mediaInlineCardAnalytics.js +1 -0
- package/dist/esm/utils/getMediaCardCursor.js +1 -0
- package/dist/esm/utils/lightCards/cardError.js +1 -1
- package/dist/esm/utils/lightCards/errorIcon/index.js +2 -1
- package/dist/esm/utils/lightCards/errorIcon/styles.js +0 -1
- package/dist/esm/utils/lightCards/lightCardWrappers.js +1 -0
- package/dist/esm/utils/ufoExperiences.js +1 -1
- package/dist/types/card/inlinePlayerWrapper-compiled.d.ts +4 -0
- package/dist/types/card/media-card-analytics-error-boundary.d.ts +1 -1
- package/dist/types/card/ui/actionsBar/cardActions/styles.d.ts +1 -1
- package/dist/types/card/ui/aiBorder/aiBorder.d.ts +4 -0
- package/dist/types/card/ui/imageRenderer/wrapper.d.ts +4 -0
- package/dist/types/card/ui/titleBox/types.d.ts +1 -1
- package/dist/types/card/ui/wrapper/types.d.ts +1 -1
- package/dist/types/inline/mediaInlineAnalyticsErrorBoundary.d.ts +1 -1
- package/dist/types/types.d.ts +1 -1
- package/dist/types/utils/getMediaCardCursor.d.ts +1 -1
- package/dist/types/utils/lightCards/types.d.ts +1 -1
- package/example-helpers/cardViewWrapper.tsx +2 -0
- package/example-helpers/cards.tsx +3 -3
- package/example-helpers/developmentUseMessage.tsx +1 -0
- package/example-helpers/index.tsx +3 -3
- package/example-helpers/selectableCard.tsx +3 -1
- package/example-helpers/ssrHelpers.tsx +2 -0
- package/example-helpers/styles.ts +2 -1
- package/package.json +3 -2
package/CHANGELOG.md
CHANGED
package/dist/cjs/card/card.js
CHANGED
|
@@ -8,7 +8,7 @@ var _reactIntl = require("react-intl");
|
|
|
8
8
|
var _mediaCommon = require("@atlaskit/media-common");
|
|
9
9
|
var _CardWithPerformanceObserver = require("./CardWithPerformanceObserver");
|
|
10
10
|
var packageName = "@atlaskit/media-card";
|
|
11
|
-
var packageVersion = "81.12.
|
|
11
|
+
var packageVersion = "81.12.8";
|
|
12
12
|
var Card = exports.Card = (0, _mediaCommon.withMediaAnalyticsContext)({
|
|
13
13
|
packageVersion: packageVersion,
|
|
14
14
|
packageName: packageName,
|
|
@@ -10,8 +10,8 @@ var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends")
|
|
|
10
10
|
var _react = _interopRequireWildcard(require("react"));
|
|
11
11
|
var _reactLoadable = _interopRequireDefault(require("react-loadable"));
|
|
12
12
|
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
13
|
-
var _cardLoading = require("../utils/lightCards/cardLoading");
|
|
14
13
|
var _ufoSegment = _interopRequireDefault(require("@atlaskit/react-ufo/ufo-segment"));
|
|
14
|
+
var _cardLoading = require("../utils/lightCards/cardLoading");
|
|
15
15
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
16
16
|
var MediaCardContext = /*#__PURE__*/_react.default.createContext({});
|
|
17
17
|
var CardLoadingWithContext = function CardLoadingWithContext() {
|
|
@@ -6,11 +6,11 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.CardWithMediaClient = void 0;
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
|
-
var _withMediaClientAndSettings = require("@atlaskit/media-client-react/with-media-client-and-settings");
|
|
10
9
|
var _withMediaClient = require("@atlaskit/media-client-react/with-media-client");
|
|
11
|
-
var
|
|
12
|
-
var _card = require("./card");
|
|
10
|
+
var _withMediaClientAndSettings = require("@atlaskit/media-client-react/with-media-client-and-settings");
|
|
13
11
|
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
12
|
+
var _card = require("./card");
|
|
13
|
+
var _mediaCardAnalyticsErrorBoundary = _interopRequireDefault(require("./media-card-analytics-error-boundary"));
|
|
14
14
|
var CardWithMediaClient = exports.CardWithMediaClient = function CardWithMediaClient(props) {
|
|
15
15
|
var dimensions = props.dimensions,
|
|
16
16
|
onClick = props.onClick;
|
|
@@ -27,12 +27,12 @@ var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
|
27
27
|
var _getActiveTrace = require("@atlaskit/react-ufo/get-active-trace");
|
|
28
28
|
var _usePressTracing = _interopRequireDefault(require("@atlaskit/react-ufo/use-press-tracing"));
|
|
29
29
|
var _expValEquals = require("@atlaskit/tmp-editor-statsig/exp-val-equals");
|
|
30
|
-
var _MediaCardError = require("../MediaCardError");
|
|
31
30
|
var _dateOverrideContext = require("../dateOverrideContext");
|
|
32
31
|
var _isSSRPreview = require("../isSSRPreview");
|
|
32
|
+
var _MediaCardError = require("../MediaCardError");
|
|
33
33
|
var _fireMediaCardEvent = require("../utils/analytics/fireMediaCardEvent");
|
|
34
|
-
var _getAuthProviderSucceededPayload = require("../utils/analytics/getAuthProviderSucceededPayload");
|
|
35
34
|
var _getAuthProviderFailedPayload = require("../utils/analytics/getAuthProviderFailedPayload");
|
|
35
|
+
var _getAuthProviderSucceededPayload = require("../utils/analytics/getAuthProviderSucceededPayload");
|
|
36
36
|
var _cardDimensions = require("../utils/cardDimensions");
|
|
37
37
|
var _generateUniqueId = require("../utils/generateUniqueId");
|
|
38
38
|
var _getMediaCardCursor = require("../utils/getMediaCardCursor");
|
|
@@ -7,9 +7,9 @@ exports.fireOperationalEvent = void 0;
|
|
|
7
7
|
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
8
8
|
var _MediaCardError = require("../MediaCardError");
|
|
9
9
|
var _fireMediaCardEvent = require("../utils/analytics/fireMediaCardEvent");
|
|
10
|
-
var _getRenderSucceededEventPayload = require("../utils/analytics/getRenderSucceededEventPayload");
|
|
11
10
|
var _getRenderErrorEventPayload = require("../utils/analytics/getRenderErrorEventPayload");
|
|
12
11
|
var _getRenderFailedFileStatusPayload = require("../utils/analytics/getRenderFailedFileStatusPayload");
|
|
12
|
+
var _getRenderSucceededEventPayload = require("../utils/analytics/getRenderSucceededEventPayload");
|
|
13
13
|
// Sampling rate for mediaCardRender success events (10%)
|
|
14
14
|
var MEDIA_CARD_RENDER_SUCCESS_SAMPLE_RATE = 0.1;
|
|
15
15
|
var fireOperationalEvent = exports.fireOperationalEvent = function fireOperationalEvent(createAnalyticsEvent, status, fileAttributes, performanceAttributes, ssrReliability) {
|
|
@@ -12,10 +12,10 @@ var React = _interopRequireWildcard(require("react"));
|
|
|
12
12
|
var _runtime = require("@compiled/react/runtime");
|
|
13
13
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
14
14
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
15
|
-
var _getDimensionsWithDefault = require("../utils/lightCards/getDimensionsWithDefault");
|
|
16
|
-
var _vcMedia = require("@atlaskit/react-ufo/vc-media");
|
|
17
|
-
var _customData = _interopRequireDefault(require("@atlaskit/react-ufo/custom-data"));
|
|
18
15
|
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
16
|
+
var _customData = _interopRequireDefault(require("@atlaskit/react-ufo/custom-data"));
|
|
17
|
+
var _vcMedia = require("@atlaskit/react-ufo/vc-media");
|
|
18
|
+
var _getDimensionsWithDefault = require("../utils/lightCards/getDimensionsWithDefault");
|
|
19
19
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
20
20
|
var hideNativeBrowserTextSelectionStyles = null;
|
|
21
21
|
var selectedBorderStyle = null;
|
|
@@ -7,8 +7,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.inlinePlayerWrapperStyles = exports.inlinePlayerClassName = void 0;
|
|
8
8
|
var _taggedTemplateLiteral2 = _interopRequireDefault(require("@babel/runtime/helpers/taggedTemplateLiteral"));
|
|
9
9
|
var _react = require("@emotion/react");
|
|
10
|
-
var _getDimensionsWithDefault = require("../utils/lightCards/getDimensionsWithDefault");
|
|
11
10
|
var _selection = require("@atlaskit/editor-shared-styles/selection");
|
|
11
|
+
var _getDimensionsWithDefault = require("../utils/lightCards/getDimensionsWithDefault");
|
|
12
12
|
var _templateObject; // eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
13
13
|
/*
|
|
14
14
|
* Used to display the blue border around a selected card without
|
|
@@ -12,10 +12,10 @@ var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/ge
|
|
|
12
12
|
var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
|
|
13
13
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
14
14
|
var _react = _interopRequireDefault(require("react"));
|
|
15
|
-
var _mediaCommon = require("@atlaskit/media-common");
|
|
16
|
-
var _unhandledErrorCard = require("./ui/unhandledErrorCard");
|
|
17
15
|
var _withAnalyticsEvents = _interopRequireDefault(require("@atlaskit/analytics-next/withAnalyticsEvents"));
|
|
16
|
+
var _mediaCommon = require("@atlaskit/media-common");
|
|
18
17
|
var _fireMediaCardEvent = require("../utils/analytics/fireMediaCardEvent");
|
|
18
|
+
var _unhandledErrorCard = require("./ui/unhandledErrorCard");
|
|
19
19
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
20
20
|
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) { (0, _defineProperty2.default)(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; }
|
|
21
21
|
function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); }
|
|
@@ -87,7 +87,7 @@ var WrappedMediaCardAnalyticsErrorBoundary = /*#__PURE__*/function (_React$Compo
|
|
|
87
87
|
}(_react.default.Component);
|
|
88
88
|
(0, _defineProperty2.default)(WrappedMediaCardAnalyticsErrorBoundary, "displayName", 'MediaCardAnalyticsErrorBoundary');
|
|
89
89
|
var packageName = "@atlaskit/media-card";
|
|
90
|
-
var packageVersion = "81.12.
|
|
90
|
+
var packageVersion = "81.12.8";
|
|
91
91
|
|
|
92
92
|
// @ts-ignore: [PIT-1685] Fails in post-office due to backwards incompatibility issue with React 18
|
|
93
93
|
var MediaCardAnalyticsErrorBoundary = (0, _mediaCommon.withMediaAnalyticsContext)({
|
|
@@ -7,9 +7,9 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.SvgView = void 0;
|
|
8
8
|
var _react = _interopRequireWildcard(require("react"));
|
|
9
9
|
var _react2 = require("@emotion/react");
|
|
10
|
-
var _MediaCardError = require("../../MediaCardError");
|
|
11
|
-
var _useResolveSvg2 = require("@atlaskit/media-svg/use-resolve-svg");
|
|
12
10
|
var _mediaSvgError = require("@atlaskit/media-svg/media-svg-error");
|
|
11
|
+
var _useResolveSvg2 = require("@atlaskit/media-svg/use-resolve-svg");
|
|
12
|
+
var _MediaCardError = require("../../MediaCardError");
|
|
13
13
|
var _imageRendererV = require("../ui/imageRenderer/imageRendererV2");
|
|
14
14
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
15
15
|
/**
|
|
@@ -7,9 +7,9 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.CardActionIconButton = void 0;
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
var _useAnalyticsEvents2 = require("@atlaskit/analytics-next/useAnalyticsEvents");
|
|
10
|
-
var _cardActionButton = require("./cardActionButton");
|
|
11
10
|
var _Tooltip = _interopRequireDefault(require("@atlaskit/tooltip/Tooltip"));
|
|
12
11
|
var _fireMediaCardEvent = require("../../../../utils/analytics/fireMediaCardEvent");
|
|
12
|
+
var _cardActionButton = require("./cardActionButton");
|
|
13
13
|
var CardActionIconButton = exports.CardActionIconButton = function CardActionIconButton(_ref) {
|
|
14
14
|
var icon = _ref.icon,
|
|
15
15
|
label = _ref.label,
|
|
@@ -9,11 +9,11 @@ var _objectWithoutProperties2 = _interopRequireDefault(require("@babel/runtime/h
|
|
|
9
9
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
10
10
|
var _react = _interopRequireDefault(require("react"));
|
|
11
11
|
var _useAnalyticsEvents2 = require("@atlaskit/analytics-next/useAnalyticsEvents");
|
|
12
|
-
var
|
|
12
|
+
var _withAnalyticsEvents = _interopRequireDefault(require("@atlaskit/analytics-next/withAnalyticsEvents"));
|
|
13
13
|
var _dropdownMenu = _interopRequireDefault(require("@atlaskit/dropdown-menu/dropdown-menu"));
|
|
14
|
-
var _dropdownMenuItemGroup = _interopRequireDefault(require("@atlaskit/dropdown-menu/dropdown-menu-item-group"));
|
|
15
14
|
var _dropdownMenuItem = _interopRequireDefault(require("@atlaskit/dropdown-menu/dropdown-menu-item"));
|
|
16
|
-
var
|
|
15
|
+
var _dropdownMenuItemGroup = _interopRequireDefault(require("@atlaskit/dropdown-menu/dropdown-menu-item-group"));
|
|
16
|
+
var _showMoreHorizontal = _interopRequireDefault(require("@atlaskit/icon/core/show-more-horizontal"));
|
|
17
17
|
var _createAndFireMediaCardEvent = require("../../../../utils/analytics/createAndFireMediaCardEvent");
|
|
18
18
|
var _fireMediaCardEvent = require("../../../../utils/analytics/fireMediaCardEvent");
|
|
19
19
|
var _cardActionButton = require("./cardActionButton");
|
|
@@ -9,8 +9,8 @@ exports.ImageRenderer = void 0;
|
|
|
9
9
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
10
10
|
var _react = _interopRequireWildcard(require("react"));
|
|
11
11
|
var _mediaImage = require("@atlaskit/media-ui/mediaImage");
|
|
12
|
-
var _resizeModeToMediaImageProps = require("./resizeModeToMediaImageProps");
|
|
13
12
|
var _useCurrentValueRef = require("../../../utils/useCurrentValueRef");
|
|
13
|
+
var _resizeModeToMediaImageProps = require("./resizeModeToMediaImageProps");
|
|
14
14
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
15
15
|
var ImageRenderer = exports.ImageRenderer = function ImageRenderer(_ref) {
|
|
16
16
|
var cardPreview = _ref.cardPreview,
|
|
@@ -6,9 +6,9 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
6
6
|
});
|
|
7
7
|
exports.ImageRenderer = void 0;
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
|
+
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
9
10
|
var _imageRenderer = require("./imageRenderer");
|
|
10
11
|
var _imageRendererV = require("./imageRendererV2");
|
|
11
|
-
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
12
12
|
var ImageRenderer = exports.ImageRenderer = function ImageRenderer(props) {
|
|
13
13
|
return (0, _fg.fg)('platform_media_card_image_render') ? /*#__PURE__*/_react.default.createElement(_imageRendererV.ImageRenderer, props) : /*#__PURE__*/_react.default.createElement(_imageRenderer.ImageRenderer, props);
|
|
14
14
|
};
|
|
@@ -7,8 +7,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
7
7
|
exports.PlayButton = void 0;
|
|
8
8
|
var _react = _interopRequireDefault(require("react"));
|
|
9
9
|
var _videoPlayOverlay = _interopRequireDefault(require("@atlaskit/icon/core/video-play-overlay"));
|
|
10
|
-
var _playButtonWrapper = require("./playButtonWrapper");
|
|
11
10
|
var _playButtonBackground = require("./playButtonBackground");
|
|
11
|
+
var _playButtonWrapper = require("./playButtonWrapper");
|
|
12
12
|
var PlayButton = exports.PlayButton = function PlayButton() {
|
|
13
13
|
return /*#__PURE__*/_react.default.createElement(_playButtonWrapper.PlayButtonWrapper, null, /*#__PURE__*/_react.default.createElement(_playButtonBackground.PlayButtonBackground, null), /*#__PURE__*/_react.default.createElement(_videoPlayOverlay.default, {
|
|
14
14
|
color: "currentColor",
|
|
@@ -12,11 +12,11 @@ var React = _interopRequireWildcard(require("react"));
|
|
|
12
12
|
var _runtime = require("@compiled/react/runtime");
|
|
13
13
|
var _extends2 = _interopRequireDefault(require("@babel/runtime/helpers/extends"));
|
|
14
14
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
15
|
-
var
|
|
15
|
+
var _customData = _interopRequireDefault(require("@atlaskit/react-ufo/custom-data"));
|
|
16
16
|
var _vcMedia = require("@atlaskit/react-ufo/vc-media");
|
|
17
17
|
var _cardDimensions = require("../../../utils/cardDimensions");
|
|
18
18
|
var _getCSSUnitValue = require("../../../utils/getCSSUnitValue");
|
|
19
|
-
var
|
|
19
|
+
var _cardConstants = require("../../cardConstants");
|
|
20
20
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
21
21
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
22
22
|
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) { (0, _defineProperty2.default)(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; }
|
|
@@ -4,8 +4,8 @@ Object.defineProperty(exports, "__esModule", {
|
|
|
4
4
|
value: true
|
|
5
5
|
});
|
|
6
6
|
exports.ensureMediaCardError = void 0;
|
|
7
|
-
var _MediaCardError = require("./MediaCardError");
|
|
8
7
|
var _isMediaCardError = require("./isMediaCardError");
|
|
8
|
+
var _MediaCardError = require("./MediaCardError");
|
|
9
9
|
// In a try/catch statement, the error caught is the type of unknown.
|
|
10
10
|
// We can use this helper to ensure that the error handled is the type of MediaCardError if unsure
|
|
11
11
|
// If updatePrimaryReason is true, if it's a MediaCardError already, it will update it's primary reason
|
|
@@ -16,8 +16,8 @@ var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/ge
|
|
|
16
16
|
var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
|
|
17
17
|
var _defineProperty2 = _interopRequireDefault(require("@babel/runtime/helpers/defineProperty"));
|
|
18
18
|
var _react = _interopRequireDefault(require("react"));
|
|
19
|
-
var _LoadingView = require("@atlaskit/media-ui/LoadingView");
|
|
20
19
|
var _AnalyticsContext = _interopRequireDefault(require("@atlaskit/analytics-next/AnalyticsContext"));
|
|
20
|
+
var _LoadingView = require("@atlaskit/media-ui/LoadingView");
|
|
21
21
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t2 in e) "default" !== _t2 && {}.hasOwnProperty.call(e, _t2) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t2)) && (i.get || i.set) ? o(f, _t2, i) : f[_t2] = e[_t2]); return f; })(e, t); }
|
|
22
22
|
function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); }
|
|
23
23
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
@@ -116,7 +116,7 @@ var MediaInlineCardLoader = exports.default = /*#__PURE__*/function (_React$Pure
|
|
|
116
116
|
ErrorBoundary = _this$state.ErrorBoundary;
|
|
117
117
|
var analyticsContext = {
|
|
118
118
|
packageVersion: "@atlaskit/media-card",
|
|
119
|
-
packageName: "81.12.
|
|
119
|
+
packageName: "81.12.8",
|
|
120
120
|
componentName: 'mediaInlineCard',
|
|
121
121
|
component: 'mediaInlineCard'
|
|
122
122
|
};
|
|
@@ -13,8 +13,8 @@ var _getPrototypeOf2 = _interopRequireDefault(require("@babel/runtime/helpers/ge
|
|
|
13
13
|
var _inherits2 = _interopRequireDefault(require("@babel/runtime/helpers/inherits"));
|
|
14
14
|
var _react = _interopRequireWildcard(require("react"));
|
|
15
15
|
var _errorIcon = require("./errorIcon");
|
|
16
|
-
var _lightCardWrappers = require("./lightCardWrappers");
|
|
17
16
|
var _getDimensionsWithDefault = require("./getDimensionsWithDefault");
|
|
17
|
+
var _lightCardWrappers = require("./lightCardWrappers");
|
|
18
18
|
function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r = new WeakMap(), n = new WeakMap(); return (_interopRequireWildcard = function _interopRequireWildcard(e, t) { if (!t && e && e.__esModule) return e; var o, i, f = { __proto__: null, default: e }; if (null === e || "object" != _typeof(e) && "function" != typeof e) return f; if (o = t ? n : r) { if (o.has(e)) return o.get(e); o.set(e, f); } for (var _t in e) "default" !== _t && {}.hasOwnProperty.call(e, _t) && ((i = (o = Object.defineProperty) && Object.getOwnPropertyDescriptor(e, _t)) && (i.get || i.set) ? o(f, _t, i) : f[_t] = e[_t]); return f; })(e, t); }
|
|
19
19
|
function _callSuper(t, o, e) { return o = (0, _getPrototypeOf2.default)(o), (0, _possibleConstructorReturn2.default)(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], (0, _getPrototypeOf2.default)(t).constructor) : o.apply(t, e)); }
|
|
20
20
|
function _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }
|
|
@@ -23,7 +23,7 @@ var _getMediaGlobalScope = require("./globalScope/getMediaGlobalScope");
|
|
|
23
23
|
function ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }
|
|
24
24
|
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) { (0, _defineProperty2.default)(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; }
|
|
25
25
|
var packageName = "@atlaskit/media-card";
|
|
26
|
-
var packageVersion = "81.12.
|
|
26
|
+
var packageVersion = "81.12.8";
|
|
27
27
|
var SAMPLE_RATE = 0.05;
|
|
28
28
|
|
|
29
29
|
/**
|
package/dist/es2019/card/card.js
CHANGED
|
@@ -2,7 +2,7 @@ import { injectIntl } from 'react-intl';
|
|
|
2
2
|
import { withMediaAnalyticsContext } from '@atlaskit/media-common';
|
|
3
3
|
import { CardWithPerformanceObserver } from './CardWithPerformanceObserver';
|
|
4
4
|
const packageName = "@atlaskit/media-card";
|
|
5
|
-
const packageVersion = "81.12.
|
|
5
|
+
const packageVersion = "81.12.8";
|
|
6
6
|
export const Card = withMediaAnalyticsContext({
|
|
7
7
|
packageVersion,
|
|
8
8
|
packageName,
|
|
@@ -2,8 +2,8 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
2
2
|
import React, { Suspense, useContext } from 'react';
|
|
3
3
|
import Loadable from 'react-loadable';
|
|
4
4
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
5
|
-
import { CardLoading } from '../utils/lightCards/cardLoading';
|
|
6
5
|
import UFOSegment from '@atlaskit/react-ufo/ufo-segment';
|
|
6
|
+
import { CardLoading } from '../utils/lightCards/cardLoading';
|
|
7
7
|
const MediaCardContext = /*#__PURE__*/React.createContext({});
|
|
8
8
|
const CardLoadingWithContext = () => {
|
|
9
9
|
const props = useContext(MediaCardContext);
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
-
import { withMediaClientAndSettings } from '@atlaskit/media-client-react/with-media-client-and-settings';
|
|
3
2
|
import { withMediaClient } from '@atlaskit/media-client-react/with-media-client';
|
|
4
|
-
import
|
|
5
|
-
import { Card as InternalCard } from './card';
|
|
3
|
+
import { withMediaClientAndSettings } from '@atlaskit/media-client-react/with-media-client-and-settings';
|
|
6
4
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
5
|
+
import { Card as InternalCard } from './card';
|
|
6
|
+
import MediaCardAnalyticsErrorBoundary from './media-card-analytics-error-boundary';
|
|
7
7
|
export const CardWithMediaClient = props => {
|
|
8
8
|
const {
|
|
9
9
|
dimensions,
|
|
@@ -15,12 +15,12 @@ import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
|
15
15
|
import { getActiveTrace } from '@atlaskit/react-ufo/get-active-trace';
|
|
16
16
|
import usePressTracing from '@atlaskit/react-ufo/use-press-tracing';
|
|
17
17
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
18
|
-
import { MediaCardError } from '../MediaCardError';
|
|
19
18
|
import { DateOverrideContext } from '../dateOverrideContext';
|
|
20
19
|
import { isSSRPreview } from '../isSSRPreview';
|
|
20
|
+
import { MediaCardError } from '../MediaCardError';
|
|
21
21
|
import { fireMediaCardEvent } from '../utils/analytics/fireMediaCardEvent';
|
|
22
|
-
import { getAuthProviderSucceededPayload } from '../utils/analytics/getAuthProviderSucceededPayload';
|
|
23
22
|
import { getAuthProviderFailedPayload } from '../utils/analytics/getAuthProviderFailedPayload';
|
|
23
|
+
import { getAuthProviderSucceededPayload } from '../utils/analytics/getAuthProviderSucceededPayload';
|
|
24
24
|
import { getDefaultCardDimensions } from '../utils/cardDimensions';
|
|
25
25
|
import { generateUniqueId } from '../utils/generateUniqueId';
|
|
26
26
|
import { getMediaCardCursor } from '../utils/getMediaCardCursor';
|
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
2
2
|
import { MediaCardError } from '../MediaCardError';
|
|
3
3
|
import { fireMediaCardEvent } from '../utils/analytics/fireMediaCardEvent';
|
|
4
|
-
import { getRenderSucceededEventPayload } from '../utils/analytics/getRenderSucceededEventPayload';
|
|
5
4
|
import { getRenderErrorEventPayload } from '../utils/analytics/getRenderErrorEventPayload';
|
|
6
5
|
import { getRenderFailedFileStatusPayload } from '../utils/analytics/getRenderFailedFileStatusPayload';
|
|
6
|
+
import { getRenderSucceededEventPayload } from '../utils/analytics/getRenderSucceededEventPayload';
|
|
7
|
+
|
|
7
8
|
// Sampling rate for mediaCardRender success events (10%)
|
|
8
9
|
const MEDIA_CARD_RENDER_SUCCESS_SAMPLE_RATE = 0.1;
|
|
9
10
|
export const fireOperationalEvent = (createAnalyticsEvent, status, fileAttributes, performanceAttributes, ssrReliability, error = new MediaCardError('missing-error-data'), traceContext, metadataTraceContext, processingFailReason) => {
|
|
@@ -3,10 +3,10 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
3
3
|
import "./inlinePlayerWrapper-compiled.compiled.css";
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import { ax, ix } from "@compiled/react/runtime";
|
|
6
|
-
import { getDimensionsWithDefault } from '../utils/lightCards/getDimensionsWithDefault';
|
|
7
|
-
import { VcMediaWrapperProps } from '@atlaskit/react-ufo/vc-media';
|
|
8
|
-
import UFOCustomData from '@atlaskit/react-ufo/custom-data';
|
|
9
6
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
7
|
+
import UFOCustomData from '@atlaskit/react-ufo/custom-data';
|
|
8
|
+
import { VcMediaWrapperProps } from '@atlaskit/react-ufo/vc-media';
|
|
9
|
+
import { getDimensionsWithDefault } from '../utils/lightCards/getDimensionsWithDefault';
|
|
10
10
|
const hideNativeBrowserTextSelectionStyles = null;
|
|
11
11
|
const selectedBorderStyle = null;
|
|
12
12
|
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
2
2
|
import { css } from '@emotion/react';
|
|
3
|
-
import { getDimensionsWithDefault } from '../utils/lightCards/getDimensionsWithDefault';
|
|
4
3
|
import { getSelectionStyles, SelectionStyle, hideNativeBrowserTextSelectionStyles } from '@atlaskit/editor-shared-styles/selection';
|
|
4
|
+
import { getDimensionsWithDefault } from '../utils/lightCards/getDimensionsWithDefault';
|
|
5
5
|
/*
|
|
6
6
|
* Used to display the blue border around a selected card without
|
|
7
7
|
* shrinking the image OR growing the card size
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { withMediaAnalyticsContext } from '@atlaskit/media-common';
|
|
4
|
-
import { UnhandledErrorCard } from './ui/unhandledErrorCard';
|
|
5
3
|
import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
|
|
4
|
+
import { withMediaAnalyticsContext } from '@atlaskit/media-common';
|
|
6
5
|
import { fireMediaCardEvent } from '../utils/analytics/fireMediaCardEvent';
|
|
6
|
+
import { UnhandledErrorCard } from './ui/unhandledErrorCard';
|
|
7
7
|
class WrappedMediaCardAnalyticsErrorBoundary extends React.Component {
|
|
8
8
|
constructor(props) {
|
|
9
9
|
super(props);
|
|
@@ -66,7 +66,7 @@ class WrappedMediaCardAnalyticsErrorBoundary extends React.Component {
|
|
|
66
66
|
}
|
|
67
67
|
_defineProperty(WrappedMediaCardAnalyticsErrorBoundary, "displayName", 'MediaCardAnalyticsErrorBoundary');
|
|
68
68
|
const packageName = "@atlaskit/media-card";
|
|
69
|
-
const packageVersion = "81.12.
|
|
69
|
+
const packageVersion = "81.12.8";
|
|
70
70
|
|
|
71
71
|
// @ts-ignore: [PIT-1685] Fails in post-office due to backwards incompatibility issue with React 18
|
|
72
72
|
const MediaCardAnalyticsErrorBoundary = withMediaAnalyticsContext({
|
|
@@ -4,12 +4,13 @@
|
|
|
4
4
|
*/
|
|
5
5
|
|
|
6
6
|
import React from 'react';
|
|
7
|
+
import { useMemo } from 'react';
|
|
8
|
+
|
|
7
9
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
10
|
import { jsx } from '@emotion/react';
|
|
9
|
-
import { useMemo } from 'react';
|
|
10
|
-
import { MediaCardError } from '../../MediaCardError';
|
|
11
|
-
import { useResolveSvg } from '@atlaskit/media-svg/use-resolve-svg';
|
|
12
11
|
import { MediaSVGError } from '@atlaskit/media-svg/media-svg-error';
|
|
12
|
+
import { useResolveSvg } from '@atlaskit/media-svg/use-resolve-svg';
|
|
13
|
+
import { MediaCardError } from '../../MediaCardError';
|
|
13
14
|
import { ImageRenderer } from '../ui/imageRenderer/imageRendererV2';
|
|
14
15
|
const getErrorReason = svgReason => {
|
|
15
16
|
switch (svgReason) {
|
|
@@ -4,6 +4,7 @@ import "./cardActionButton-compiled.compiled.css";
|
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import { ax, ix } from "@compiled/react/runtime";
|
|
6
6
|
import { forwardRef } from 'react';
|
|
7
|
+
|
|
7
8
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
9
|
|
|
9
10
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { useAnalyticsEvents } from '@atlaskit/analytics-next/useAnalyticsEvents';
|
|
3
|
-
import { CardActionButton } from './cardActionButton';
|
|
4
3
|
import Tooltip from '@atlaskit/tooltip/Tooltip';
|
|
5
4
|
import { fireMediaCardEvent } from '../../../../utils/analytics/fireMediaCardEvent';
|
|
5
|
+
import { CardActionButton } from './cardActionButton';
|
|
6
6
|
export const CardActionIconButton = ({
|
|
7
7
|
icon,
|
|
8
8
|
label,
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import React from 'react';
|
|
3
3
|
import { useAnalyticsEvents } from '@atlaskit/analytics-next/useAnalyticsEvents';
|
|
4
|
-
import
|
|
4
|
+
import withAnalyticsEvents from '@atlaskit/analytics-next/withAnalyticsEvents';
|
|
5
5
|
import DropdownMenu from '@atlaskit/dropdown-menu/dropdown-menu';
|
|
6
|
-
import DropdownItemGroup from '@atlaskit/dropdown-menu/dropdown-menu-item-group';
|
|
7
6
|
import DropdownItem from '@atlaskit/dropdown-menu/dropdown-menu-item';
|
|
8
|
-
import
|
|
7
|
+
import DropdownItemGroup from '@atlaskit/dropdown-menu/dropdown-menu-item-group';
|
|
8
|
+
import MoreIcon from '@atlaskit/icon/core/show-more-horizontal';
|
|
9
9
|
import { createAndFireMediaCardEvent } from '../../../../utils/analytics/createAndFireMediaCardEvent';
|
|
10
10
|
import { fireMediaCardEvent } from '../../../../utils/analytics/fireMediaCardEvent';
|
|
11
11
|
import { CardActionButton } from './cardActionButton';
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import _extends from "@babel/runtime/helpers/extends";
|
|
2
2
|
import React, { useEffect } from 'react';
|
|
3
3
|
import { MediaImage } from '@atlaskit/media-ui/mediaImage';
|
|
4
|
-
import { resizeModeToMediaImageProps } from './resizeModeToMediaImageProps';
|
|
5
4
|
import { useCurrentValueRef } from '../../../utils/useCurrentValueRef';
|
|
5
|
+
import { resizeModeToMediaImageProps } from './resizeModeToMediaImageProps';
|
|
6
6
|
export const ImageRenderer = ({
|
|
7
7
|
cardPreview,
|
|
8
8
|
alt,
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
2
3
|
import { ImageRenderer as ImageRendererV1 } from './imageRenderer';
|
|
3
4
|
import { ImageRenderer as ImageRendererV2 } from './imageRendererV2';
|
|
4
|
-
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
5
5
|
export const ImageRenderer = props => {
|
|
6
6
|
return fg('platform_media_card_image_render') ? /*#__PURE__*/React.createElement(ImageRendererV2, props) : /*#__PURE__*/React.createElement(ImageRendererV1, props);
|
|
7
7
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import VidPlayIcon from '@atlaskit/icon/core/video-play-overlay';
|
|
3
|
-
import { PlayButtonWrapper } from './playButtonWrapper';
|
|
4
3
|
import { PlayButtonBackground } from './playButtonBackground';
|
|
4
|
+
import { PlayButtonWrapper } from './playButtonWrapper';
|
|
5
5
|
export const PlayButton = () => {
|
|
6
6
|
return /*#__PURE__*/React.createElement(PlayButtonWrapper, null, /*#__PURE__*/React.createElement(PlayButtonBackground, null), /*#__PURE__*/React.createElement(VidPlayIcon, {
|
|
7
7
|
color: "currentColor",
|
|
@@ -3,11 +3,11 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
3
3
|
import "./wrapper-compiled.compiled.css";
|
|
4
4
|
import * as React from 'react';
|
|
5
5
|
import { ax, ix } from "@compiled/react/runtime";
|
|
6
|
-
import
|
|
6
|
+
import UFOCustomData from '@atlaskit/react-ufo/custom-data';
|
|
7
7
|
import { VcMediaWrapperProps } from '@atlaskit/react-ufo/vc-media';
|
|
8
8
|
import { getDefaultCardDimensions } from '../../../utils/cardDimensions';
|
|
9
9
|
import { getCSSUnitValue } from '../../../utils/getCSSUnitValue';
|
|
10
|
-
import
|
|
10
|
+
import { newFileExperienceClassName } from '../../cardConstants';
|
|
11
11
|
export const LOCAL_WIDTH_VARIABLE = '--media-wrapper-width';
|
|
12
12
|
export const LOCAL_HEIGHT_VARIABLE = '--media-wrapper-height';
|
|
13
13
|
const wrapperStyles = {
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { MediaCardError } from './MediaCardError';
|
|
2
1
|
import { isMediaCardError } from './isMediaCardError';
|
|
2
|
+
import { MediaCardError } from './MediaCardError';
|
|
3
3
|
|
|
4
4
|
// In a try/catch statement, the error caught is the type of unknown.
|
|
5
5
|
// We can use this helper to ensure that the error handled is the type of MediaCardError if unsure
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
2
2
|
import React from 'react';
|
|
3
|
-
import { MediaInlineCardLoadingView } from '@atlaskit/media-ui/LoadingView';
|
|
4
3
|
import AnalyticsContext from '@atlaskit/analytics-next/AnalyticsContext';
|
|
4
|
+
import { MediaInlineCardLoadingView } from '@atlaskit/media-ui/LoadingView';
|
|
5
5
|
export default class MediaInlineCardLoader extends React.PureComponent {
|
|
6
6
|
constructor(...args) {
|
|
7
7
|
super(...args);
|
|
@@ -37,7 +37,7 @@ export default class MediaInlineCardLoader extends React.PureComponent {
|
|
|
37
37
|
} = this.state;
|
|
38
38
|
const analyticsContext = {
|
|
39
39
|
packageVersion: "@atlaskit/media-card",
|
|
40
|
-
packageName: "81.12.
|
|
40
|
+
packageName: "81.12.8",
|
|
41
41
|
componentName: 'mediaInlineCard',
|
|
42
42
|
component: 'mediaInlineCard'
|
|
43
43
|
};
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* @deprecated Use `import { getSucceededStatusPayload } from '@atlaskit/media-card/mediaInlineCardAnalytics'` instead.
|
|
4
4
|
*/
|
|
5
|
+
|
|
5
6
|
export { getSucceededStatusPayload } from './getSucceededStatusPayload';
|
|
6
7
|
/**
|
|
7
8
|
* @deprecated Use `import { getErrorStatusPayload } from '@atlaskit/media-card/mediaInlineCardAnalytics'` instead.
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
2
|
import { Component } from 'react';
|
|
3
3
|
import { ErrorIcon } from './errorIcon';
|
|
4
|
-
import { Wrapper } from './lightCardWrappers';
|
|
5
4
|
import { getDimensionsWithDefault } from './getDimensionsWithDefault';
|
|
5
|
+
import { Wrapper } from './lightCardWrappers';
|
|
6
6
|
export class CardError extends Component {
|
|
7
7
|
render() {
|
|
8
8
|
const dimensions = getDimensionsWithDefault(this.props.dimensions);
|
|
@@ -3,9 +3,10 @@
|
|
|
3
3
|
* @jsx jsx
|
|
4
4
|
*/
|
|
5
5
|
import React from 'react';
|
|
6
|
+
import { Component } from 'react';
|
|
7
|
+
|
|
6
8
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
7
9
|
import { jsx } from '@emotion/react';
|
|
8
|
-
import { Component } from 'react';
|
|
9
10
|
import WarningIcon from '@atlaskit/icon/core/status-warning';
|
|
10
11
|
import { errorIconWrapperStyles } from './styles';
|
|
11
12
|
export class ErrorIcon extends Component {
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
2
2
|
import { css } from '@emotion/react';
|
|
3
|
-
|
|
4
3
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/no-exported-styles -- Ignored via go/DSP-18766
|
|
5
4
|
export const errorIconWrapperStyles = css({
|
|
6
5
|
display: 'flex',
|
|
@@ -4,6 +4,7 @@ import _extends from "@babel/runtime/helpers/extends";
|
|
|
4
4
|
* @jsx jsx
|
|
5
5
|
*/
|
|
6
6
|
import React from 'react';
|
|
7
|
+
|
|
7
8
|
// eslint-disable-next-line @atlaskit/ui-styling-standard/use-compiled -- Ignored via go/DSP-18766
|
|
8
9
|
import { jsx } from '@emotion/react';
|
|
9
10
|
import { wrapperStyles } from './styles';
|
|
@@ -12,7 +12,7 @@ import { extractErrorInfo } from './analytics/extractErrorInfo';
|
|
|
12
12
|
import { getRenderErrorRequestMetadata } from './analytics/getRenderErrorRequestMetadata';
|
|
13
13
|
import { getMediaGlobalScope } from './globalScope/getMediaGlobalScope';
|
|
14
14
|
const packageName = "@atlaskit/media-card";
|
|
15
|
-
const packageVersion = "81.12.
|
|
15
|
+
const packageVersion = "81.12.8";
|
|
16
16
|
const SAMPLE_RATE = 0.05;
|
|
17
17
|
|
|
18
18
|
/**
|