@atlaskit/media-card 79.0.13 → 79.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 CHANGED
@@ -1,5 +1,25 @@
1
1
  # @atlaskit/media-card
2
2
 
3
+ ## 79.2.0
4
+
5
+ ### Minor Changes
6
+
7
+ - [#138850](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/138850)
8
+ [`6fe99d638a4ca`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/6fe99d638a4ca) -
9
+ Prevent media image resizing issue in confluence SSR
10
+
11
+ ## 79.1.0
12
+
13
+ ### Minor Changes
14
+
15
+ - [#123268](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/pull-requests/123268)
16
+ [`f47a830143188`](https://bitbucket.org/atlassian/atlassian-frontend-monorepo/commits/f47a830143188) -
17
+ Allow for passing in a resolved media provider to enable SSR'ing media in the editor
18
+
19
+ ### Patch Changes
20
+
21
+ - Updated dependencies
22
+
3
23
  ## 79.0.13
4
24
 
5
25
  ### Patch Changes
@@ -21,7 +21,7 @@ var _excluded = ["identifier"];
21
21
  function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function _getRequireWildcardCache(e) { return e ? t : r; })(e); }
22
22
  function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != _typeof(e) && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
23
23
  var packageName = "@atlaskit/media-card";
24
- var packageVersion = "79.0.13";
24
+ var packageVersion = "79.2.0";
25
25
  var CardBase = exports.CardBase = function CardBase(_ref) {
26
26
  var identifier = _ref.identifier,
27
27
  otherProps = (0, _objectWithoutProperties2.default)(_ref, _excluded);
@@ -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 = "79.0.13";
90
+ var packageVersion = "79.2.0";
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)({
@@ -8,6 +8,7 @@ exports.transition = exports.rgba = exports.getWrapperShadow = exports.getWrappe
8
8
  var _slicedToArray2 = _interopRequireDefault(require("@babel/runtime/helpers/slicedToArray"));
9
9
  var _colors = require("@atlaskit/theme/colors");
10
10
  var _consts = require("@atlaskit/editor-shared-styles/consts");
11
+ var _platformFeatureFlags = require("@atlaskit/platform-feature-flags");
11
12
  var _getCSSUnitValue = require("../../utils/getCSSUnitValue");
12
13
  var _cardDimensions = require("../../utils/cardDimensions");
13
14
  var _styles = require("./tickBox/styles");
@@ -38,7 +39,7 @@ var getWrapperDimensions = exports.getWrapperDimensions = function getWrapperDim
38
39
  var _getDefaultCardDimens = (0, _cardDimensions.getDefaultCardDimensions)(appearance),
39
40
  defaultWidth = _getDefaultCardDimens.width,
40
41
  defaultHeight = _getDefaultCardDimens.height;
41
- return "\n width: ".concat((0, _getCSSUnitValue.getCSSUnitValue)(width || defaultWidth), ";\n max-width: 100%;\n height: ").concat((0, _getCSSUnitValue.getCSSUnitValue)(height || defaultHeight), ";\n max-height: 100%;\n ");
42
+ return "\n ".concat((0, _platformFeatureFlags.fg)('platform_fix_media_image_resizing') ? "@container view-page-content (min-width: 1px) { width: 100cqw; }" : '', "\n\t/* If container doesn't exists, it will fallback to this */\n\twidth: ").concat((0, _getCSSUnitValue.getCSSUnitValue)(width || defaultWidth), ";\n\n max-width: 100%;\n height: ").concat((0, _getCSSUnitValue.getCSSUnitValue)(height || defaultHeight), ";\n max-height: 100%;\n ");
42
43
  };
43
44
 
44
45
  // This is a trick to simulate the blue border without affecting the dimensions.
@@ -117,7 +117,7 @@ var MediaInlineCardLoader = exports.default = /*#__PURE__*/function (_React$Pure
117
117
  ErrorBoundary = _this$state.ErrorBoundary;
118
118
  var analyticsContext = {
119
119
  packageVersion: "@atlaskit/media-card",
120
- packageName: "79.0.13",
120
+ packageName: "79.2.0",
121
121
  componentName: 'mediaInlineCard',
122
122
  component: 'mediaInlineCard'
123
123
  };
@@ -15,7 +15,7 @@ var _mediaClient = require("@atlaskit/media-client");
15
15
  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; }
16
16
  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; }
17
17
  var packageName = "@atlaskit/media-card";
18
- var packageVersion = "79.0.13";
18
+ var packageVersion = "79.2.0";
19
19
  var SAMPLE_RATE = 0.05;
20
20
  var concurrentExperience;
21
21
  var getExperience = function getExperience(id) {
@@ -9,7 +9,7 @@ import { startResourceObserver, setAnalyticsContext } from '../utils/mediaPerfor
9
9
  import { useAnalyticsEvents } from '@atlaskit/analytics-next';
10
10
  import UFOLabel from '@atlaskit/react-ufo/label';
11
11
  const packageName = "@atlaskit/media-card";
12
- const packageVersion = "79.0.13";
12
+ const packageVersion = "79.2.0";
13
13
  export const CardBase = ({
14
14
  identifier,
15
15
  ...otherProps
@@ -35,10 +35,7 @@ export const InlinePlayerWrapper = props => {
35
35
  style: {
36
36
  width: getDimensionsWithDefault(dimensions).width || '100%',
37
37
  height: getDimensionsWithDefault(dimensions).height || 'auto'
38
- }
39
- // eslint-disable-next-line @atlaskit/design-system/consistent-css-prop-usage, @atlaskit/ui-styling-standard/no-imported-style-values -- Ignored via go/DSP-18766
40
- ,
41
-
38
+ },
42
39
  onClick: onClick,
43
40
  ref: innerRef
44
41
  }, VcMediaWrapperProps), props.children);
@@ -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 = "79.0.13";
69
+ const packageVersion = "79.2.0";
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({
@@ -1,5 +1,6 @@
1
1
  import { N60A } from '@atlaskit/theme/colors';
2
2
  import { akEditorSelectedBoxShadow } from '@atlaskit/editor-shared-styles/consts';
3
+ import { fg } from '@atlaskit/platform-feature-flags';
3
4
  import { getCSSUnitValue } from '../../utils/getCSSUnitValue';
4
5
  import { getDefaultCardDimensions } from '../../utils/cardDimensions';
5
6
  import { tickBoxClassName, tickboxFixedStyles } from './tickBox/styles';
@@ -27,7 +28,10 @@ export const getWrapperDimensions = (dimensions, appearance) => {
27
28
  height: defaultHeight
28
29
  } = getDefaultCardDimensions(appearance);
29
30
  return `
30
- width: ${getCSSUnitValue(width || defaultWidth)};
31
+ ${fg('platform_fix_media_image_resizing') ? `@container view-page-content (min-width: 1px) { width: 100cqw; }` : ''}
32
+ /* If container doesn't exists, it will fallback to this */
33
+ width: ${getCSSUnitValue(width || defaultWidth)};
34
+
31
35
  max-width: 100%;
32
36
  height: ${getCSSUnitValue(height || defaultHeight)};
33
37
  max-height: 100%;
@@ -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: "79.0.13",
40
+ packageName: "79.2.0",
41
41
  componentName: 'mediaInlineCard',
42
42
  component: 'mediaInlineCard'
43
43
  };
@@ -5,7 +5,7 @@ import { extractErrorInfo, getRenderErrorRequestMetadata } from './analytics';
5
5
  import { MediaCardError } from '../errors';
6
6
  import { getMediaEnvironment, getMediaRegion } from '@atlaskit/media-client';
7
7
  const packageName = "@atlaskit/media-card";
8
- const packageVersion = "79.0.13";
8
+ const packageVersion = "79.2.0";
9
9
  const SAMPLE_RATE = 0.05;
10
10
  let concurrentExperience;
11
11
  const getExperience = id => {
@@ -11,7 +11,7 @@ import { startResourceObserver, setAnalyticsContext } from '../utils/mediaPerfor
11
11
  import { useAnalyticsEvents } from '@atlaskit/analytics-next';
12
12
  import UFOLabel from '@atlaskit/react-ufo/label';
13
13
  var packageName = "@atlaskit/media-card";
14
- var packageVersion = "79.0.13";
14
+ var packageVersion = "79.2.0";
15
15
  export var CardBase = function CardBase(_ref) {
16
16
  var identifier = _ref.identifier,
17
17
  otherProps = _objectWithoutProperties(_ref, _excluded);
@@ -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 = "79.0.13";
83
+ var packageVersion = "79.2.0";
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({
@@ -1,6 +1,7 @@
1
1
  import _slicedToArray from "@babel/runtime/helpers/slicedToArray";
2
2
  import { N60A } from '@atlaskit/theme/colors';
3
3
  import { akEditorSelectedBoxShadow } from '@atlaskit/editor-shared-styles/consts';
4
+ import { fg } from '@atlaskit/platform-feature-flags';
4
5
  import { getCSSUnitValue } from '../../utils/getCSSUnitValue';
5
6
  import { getDefaultCardDimensions } from '../../utils/cardDimensions';
6
7
  import { tickBoxClassName, tickboxFixedStyles } from './tickBox/styles';
@@ -31,7 +32,7 @@ export var getWrapperDimensions = function getWrapperDimensions(dimensions, appe
31
32
  var _getDefaultCardDimens = getDefaultCardDimensions(appearance),
32
33
  defaultWidth = _getDefaultCardDimens.width,
33
34
  defaultHeight = _getDefaultCardDimens.height;
34
- return "\n width: ".concat(getCSSUnitValue(width || defaultWidth), ";\n max-width: 100%;\n height: ").concat(getCSSUnitValue(height || defaultHeight), ";\n max-height: 100%;\n ");
35
+ return "\n ".concat(fg('platform_fix_media_image_resizing') ? "@container view-page-content (min-width: 1px) { width: 100cqw; }" : '', "\n\t/* If container doesn't exists, it will fallback to this */\n\twidth: ").concat(getCSSUnitValue(width || defaultWidth), ";\n\n max-width: 100%;\n height: ").concat(getCSSUnitValue(height || defaultHeight), ";\n max-height: 100%;\n ");
35
36
  };
36
37
 
37
38
  // This is a trick to simulate the blue border without affecting the dimensions.
@@ -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: "79.0.13",
104
+ packageName: "79.2.0",
105
105
  componentName: 'mediaInlineCard',
106
106
  component: 'mediaInlineCard'
107
107
  };
@@ -8,7 +8,7 @@ import { extractErrorInfo, getRenderErrorRequestMetadata } from './analytics';
8
8
  import { MediaCardError } from '../errors';
9
9
  import { getMediaEnvironment, getMediaRegion } from '@atlaskit/media-client';
10
10
  var packageName = "@atlaskit/media-card";
11
- var packageVersion = "79.0.13";
11
+ var packageVersion = "79.2.0";
12
12
  var SAMPLE_RATE = 0.05;
13
13
  var concurrentExperience;
14
14
  var getExperience = function getExperience(id) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@atlaskit/media-card",
3
- "version": "79.0.13",
3
+ "version": "79.2.0",
4
4
  "description": "Includes all media card related components, CardView, CardViewSmall, Card...",
5
5
  "publishConfig": {
6
6
  "registry": "https://registry.npmjs.org/"
@@ -40,7 +40,7 @@
40
40
  "@atlaskit/analytics-next": "^11.0.0",
41
41
  "@atlaskit/dropdown-menu": "^14.0.0",
42
42
  "@atlaskit/editor-shared-styles": "^3.4.0",
43
- "@atlaskit/icon": "^25.5.0",
43
+ "@atlaskit/icon": "^25.6.0",
44
44
  "@atlaskit/media-client": "^32.0.0",
45
45
  "@atlaskit/media-client-react": "^4.0.0",
46
46
  "@atlaskit/media-common": "^12.0.0",
@@ -50,10 +50,10 @@
50
50
  "@atlaskit/media-viewer": "^52.0.0",
51
51
  "@atlaskit/platform-feature-flags": "^1.1.0",
52
52
  "@atlaskit/primitives": "^14.4.0",
53
- "@atlaskit/react-ufo": "^3.4.0",
53
+ "@atlaskit/react-ufo": "^3.5.0",
54
54
  "@atlaskit/spinner": "^18.0.0",
55
55
  "@atlaskit/theme": "^18.0.0",
56
- "@atlaskit/tokens": "^4.7.0",
56
+ "@atlaskit/tokens": "^4.8.0",
57
57
  "@atlaskit/tooltip": "^20.0.0",
58
58
  "@atlaskit/ufo": "^0.4.0",
59
59
  "@atlaskit/visually-hidden": "^3.0.0",
@@ -124,6 +124,12 @@
124
124
  "platform_media_compiled": {
125
125
  "type": "boolean"
126
126
  },
127
+ "platform_fix_media_image_resizing": {
128
+ "type": "boolean"
129
+ },
130
+ "platform_editor_ssr_media": {
131
+ "type": "boolean"
132
+ },
127
133
  "platform_media_card_image_render": {
128
134
  "type": "boolean"
129
135
  }