@atlaskit/media-card 81.12.2 → 81.12.4
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 +12 -0
- package/dist/cjs/card/card.js +1 -1
- package/dist/cjs/card/fileCard.js +2 -2
- package/dist/cjs/card/media-card-analytics-error-boundary.js +1 -1
- package/dist/cjs/card/ui/imageRenderer/imageRendererV2.js +2 -2
- package/dist/cjs/inline/loader.js +1 -1
- package/dist/cjs/utils/ufoExperiences.js +1 -1
- package/dist/es2019/card/card.js +1 -1
- package/dist/es2019/card/fileCard.js +1 -1
- package/dist/es2019/card/media-card-analytics-error-boundary.js +1 -1
- package/dist/es2019/card/ui/imageRenderer/imageRendererV2.js +1 -1
- package/dist/es2019/inline/loader.js +1 -1
- package/dist/es2019/utils/ufoExperiences.js +1 -1
- package/dist/esm/card/card.js +1 -1
- package/dist/esm/card/fileCard.js +1 -1
- package/dist/esm/card/media-card-analytics-error-boundary.js +1 -1
- package/dist/esm/card/ui/imageRenderer/imageRendererV2.js +1 -1
- package/dist/esm/inline/loader.js +1 -1
- package/dist/esm/utils/ufoExperiences.js +1 -1
- package/example-helpers/cards.tsx +3 -1
- package/example-helpers/index.tsx +3 -2
- package/example-helpers/selectableCard.tsx +1 -1
- package/package.json +2 -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.3";
|
|
12
12
|
var Card = exports.Card = (0, _mediaCommon.withMediaAnalyticsContext)({
|
|
13
13
|
packageVersion: packageVersion,
|
|
14
14
|
packageName: packageName,
|
|
@@ -24,7 +24,7 @@ var _useFilePreview2 = require("@atlaskit/media-file-preview/use-file-preview");
|
|
|
24
24
|
var _abuseModal = require("@atlaskit/media-ui/abuseModal");
|
|
25
25
|
var _mediaViewer = require("@atlaskit/media-viewer");
|
|
26
26
|
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
27
|
-
var
|
|
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
30
|
var _MediaCardError = require("../MediaCardError");
|
|
@@ -55,7 +55,7 @@ function _interopRequireWildcard(e, t) { if ("function" == typeof WeakMap) var r
|
|
|
55
55
|
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; }
|
|
56
56
|
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; }
|
|
57
57
|
var traceContextRetriever = function traceContextRetriever() {
|
|
58
|
-
var trace = (0,
|
|
58
|
+
var trace = (0, _getActiveTrace.getActiveTrace)();
|
|
59
59
|
if (trace) {
|
|
60
60
|
return {
|
|
61
61
|
traceId: trace.traceId,
|
|
@@ -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.3";
|
|
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)({
|
|
@@ -15,7 +15,7 @@ var _react = _interopRequireWildcard(require("react"));
|
|
|
15
15
|
var _mediaClient = require("@atlaskit/media-client");
|
|
16
16
|
var _fg = require("@atlaskit/platform-feature-flags/fg");
|
|
17
17
|
var _customData = _interopRequireDefault(require("@atlaskit/react-ufo/custom-data"));
|
|
18
|
-
var
|
|
18
|
+
var _useInteractionContext = require("@atlaskit/react-ufo/use-interaction-context");
|
|
19
19
|
var _useCurrentValueRef = require("../../../utils/useCurrentValueRef");
|
|
20
20
|
var _calculateDimensions = require("./calculateDimensions");
|
|
21
21
|
var _calculateInitialDimensions = require("./calculateInitialDimensions");
|
|
@@ -43,7 +43,7 @@ var ImageRenderer = exports.ImageRenderer = function ImageRenderer(_ref) {
|
|
|
43
43
|
backgroundColor = _ref.backgroundColor,
|
|
44
44
|
testId = _ref.testId;
|
|
45
45
|
var onDisplayImageRef = (0, _useCurrentValueRef.useCurrentValueRef)(onDisplayImage);
|
|
46
|
-
var ufoContext = (0,
|
|
46
|
+
var ufoContext = (0, _useInteractionContext.useInteractionContext)();
|
|
47
47
|
(0, _react.useEffect)(function () {
|
|
48
48
|
if (mediaType === 'image') {
|
|
49
49
|
var _onDisplayImageRef$cu;
|
|
@@ -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.3",
|
|
120
120
|
componentName: 'mediaInlineCard',
|
|
121
121
|
component: 'mediaInlineCard'
|
|
122
122
|
};
|
|
@@ -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.3";
|
|
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.3";
|
|
6
6
|
export const Card = withMediaAnalyticsContext({
|
|
7
7
|
packageVersion,
|
|
8
8
|
packageName,
|
|
@@ -12,7 +12,7 @@ import { useFilePreview } from '@atlaskit/media-file-preview/use-file-preview';
|
|
|
12
12
|
import { AbuseModal } from '@atlaskit/media-ui/abuseModal';
|
|
13
13
|
import { MediaViewer } from '@atlaskit/media-viewer';
|
|
14
14
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
15
|
-
import { getActiveTrace } from '@atlaskit/react-ufo/
|
|
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
18
|
import { MediaCardError } from '../MediaCardError';
|
|
@@ -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.3";
|
|
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({
|
|
@@ -5,7 +5,7 @@ import React, { useState, useRef, useEffect, useLayoutEffect } from 'react';
|
|
|
5
5
|
import { isFileIdentifier } from '@atlaskit/media-client';
|
|
6
6
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
7
7
|
import UFOCustomData from '@atlaskit/react-ufo/custom-data';
|
|
8
|
-
import { useInteractionContext } from '@atlaskit/react-ufo/interaction-context';
|
|
8
|
+
import { useInteractionContext } from '@atlaskit/react-ufo/use-interaction-context';
|
|
9
9
|
import { useCurrentValueRef } from '../../../utils/useCurrentValueRef';
|
|
10
10
|
import { calculateDimensions } from './calculateDimensions';
|
|
11
11
|
import { calculateInitialDimensions } from './calculateInitialDimensions';
|
|
@@ -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.3",
|
|
41
41
|
componentName: 'mediaInlineCard',
|
|
42
42
|
component: 'mediaInlineCard'
|
|
43
43
|
};
|
|
@@ -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.3";
|
|
16
16
|
const SAMPLE_RATE = 0.05;
|
|
17
17
|
|
|
18
18
|
/**
|
package/dist/esm/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
|
var packageName = "@atlaskit/media-card";
|
|
5
|
-
var packageVersion = "81.12.
|
|
5
|
+
var packageVersion = "81.12.3";
|
|
6
6
|
export var Card = withMediaAnalyticsContext({
|
|
7
7
|
packageVersion: packageVersion,
|
|
8
8
|
packageName: packageName,
|
|
@@ -19,7 +19,7 @@ import { useFilePreview } from '@atlaskit/media-file-preview/use-file-preview';
|
|
|
19
19
|
import { AbuseModal } from '@atlaskit/media-ui/abuseModal';
|
|
20
20
|
import { MediaViewer } from '@atlaskit/media-viewer';
|
|
21
21
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
22
|
-
import { getActiveTrace } from '@atlaskit/react-ufo/
|
|
22
|
+
import { getActiveTrace } from '@atlaskit/react-ufo/get-active-trace';
|
|
23
23
|
import usePressTracing from '@atlaskit/react-ufo/use-press-tracing';
|
|
24
24
|
import { expValEquals } from '@atlaskit/tmp-editor-statsig/exp-val-equals';
|
|
25
25
|
import { MediaCardError } from '../MediaCardError';
|
|
@@ -80,7 +80,7 @@ var WrappedMediaCardAnalyticsErrorBoundary = /*#__PURE__*/function (_React$Compo
|
|
|
80
80
|
}(React.Component);
|
|
81
81
|
_defineProperty(WrappedMediaCardAnalyticsErrorBoundary, "displayName", 'MediaCardAnalyticsErrorBoundary');
|
|
82
82
|
var packageName = "@atlaskit/media-card";
|
|
83
|
-
var packageVersion = "81.12.
|
|
83
|
+
var packageVersion = "81.12.3";
|
|
84
84
|
|
|
85
85
|
// @ts-ignore: [PIT-1685] Fails in post-office due to backwards incompatibility issue with React 18
|
|
86
86
|
var MediaCardAnalyticsErrorBoundary = withMediaAnalyticsContext({
|
|
@@ -9,7 +9,7 @@ import React, { useState, useRef, useEffect, useLayoutEffect } from 'react';
|
|
|
9
9
|
import { isFileIdentifier } from '@atlaskit/media-client';
|
|
10
10
|
import { fg } from '@atlaskit/platform-feature-flags/fg';
|
|
11
11
|
import UFOCustomData from '@atlaskit/react-ufo/custom-data';
|
|
12
|
-
import { useInteractionContext } from '@atlaskit/react-ufo/interaction-context';
|
|
12
|
+
import { useInteractionContext } from '@atlaskit/react-ufo/use-interaction-context';
|
|
13
13
|
import { useCurrentValueRef } from '../../../utils/useCurrentValueRef';
|
|
14
14
|
import { calculateDimensions } from './calculateDimensions';
|
|
15
15
|
import { calculateInitialDimensions } from './calculateInitialDimensions';
|
|
@@ -101,7 +101,7 @@ var MediaInlineCardLoader = /*#__PURE__*/function (_React$PureComponent) {
|
|
|
101
101
|
ErrorBoundary = _this$state.ErrorBoundary;
|
|
102
102
|
var analyticsContext = {
|
|
103
103
|
packageVersion: "@atlaskit/media-card",
|
|
104
|
-
packageName: "81.12.
|
|
104
|
+
packageName: "81.12.3",
|
|
105
105
|
componentName: 'mediaInlineCard',
|
|
106
106
|
component: 'mediaInlineCard'
|
|
107
107
|
};
|
|
@@ -16,7 +16,7 @@ import { extractErrorInfo } from './analytics/extractErrorInfo';
|
|
|
16
16
|
import { getRenderErrorRequestMetadata } from './analytics/getRenderErrorRequestMetadata';
|
|
17
17
|
import { getMediaGlobalScope } from './globalScope/getMediaGlobalScope';
|
|
18
18
|
var packageName = "@atlaskit/media-card";
|
|
19
|
-
var packageVersion = "81.12.
|
|
19
|
+
var packageVersion = "81.12.3";
|
|
20
20
|
var SAMPLE_RATE = 0.05;
|
|
21
21
|
|
|
22
22
|
/**
|
|
@@ -15,7 +15,9 @@ import {
|
|
|
15
15
|
import { type FileIdentifier } from '@atlaskit/media-client';
|
|
16
16
|
|
|
17
17
|
import { createApiCards, actions } from '.';
|
|
18
|
-
import { CardLoading
|
|
18
|
+
import { CardLoading } from '../src/utils/lightCards/cardLoading';
|
|
19
|
+
import { CardError } from '../src/utils/lightCards/cardError';
|
|
20
|
+
import Card from '../src/card/cardLoader';
|
|
19
21
|
|
|
20
22
|
const mediaClientConfig = createStorybookMediaClientConfig();
|
|
21
23
|
// standard
|
|
@@ -20,9 +20,10 @@ import {
|
|
|
20
20
|
FeatureFlagsWrapper,
|
|
21
21
|
} from '@atlaskit/media-test-helpers';
|
|
22
22
|
|
|
23
|
-
import
|
|
23
|
+
import Card from '../src/card/cardLoader';
|
|
24
|
+
import { type CardAction } from '../src/card/actions';
|
|
24
25
|
import { MediaCardError } from '../src/MediaCardError';
|
|
25
|
-
import {
|
|
26
|
+
import type { CardFocusEvent, CardAppearance, CardEvent } from '../src/types';
|
|
26
27
|
import DevelopmentUseMessage from './developmentUseMessage';
|
|
27
28
|
import { SelectableCard } from './selectableCard';
|
|
28
29
|
|
|
@@ -2,7 +2,7 @@ import React from 'react';
|
|
|
2
2
|
import { Component } from 'react';
|
|
3
3
|
import type { MediaClientConfig } from '@atlaskit/media-core/auth';
|
|
4
4
|
import { type Identifier } from '@atlaskit/media-client';
|
|
5
|
-
import
|
|
5
|
+
import Card from '../src/card/cardLoader';
|
|
6
6
|
|
|
7
7
|
export interface SelectableCardProps {
|
|
8
8
|
mediaClientConfig: MediaClientConfig;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@atlaskit/media-card",
|
|
3
|
-
"version": "81.12.
|
|
3
|
+
"version": "81.12.4",
|
|
4
4
|
"description": "Includes all media card related components, CardView, CardViewSmall, Card...",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org/"
|
|
@@ -51,7 +51,7 @@
|
|
|
51
51
|
"@atlaskit/react-ufo": "^7.10.0",
|
|
52
52
|
"@atlaskit/section-message": "^10.2.0",
|
|
53
53
|
"@atlaskit/theme": "^28.2.0",
|
|
54
|
-
"@atlaskit/tmp-editor-statsig": "^
|
|
54
|
+
"@atlaskit/tmp-editor-statsig": "^197.0.0",
|
|
55
55
|
"@atlaskit/tokens": "^17.0.0",
|
|
56
56
|
"@atlaskit/tooltip": "^24.3.0",
|
|
57
57
|
"@atlaskit/ufo": "^1.2.0",
|