@gravity-ui/page-constructor 1.2.3-alpha.0 → 1.2.3-alpha.1
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.
|
@@ -14,8 +14,8 @@ const ThemeValueContext_1 = require("../../context/theme/ThemeValueContext");
|
|
|
14
14
|
const utils_3 = require("../../components/Media/Image/utils");
|
|
15
15
|
const b = (0, utils_1.block)('header-block');
|
|
16
16
|
const Background = ({ background }) => {
|
|
17
|
-
const { url, color, disableCompress, fullWidth, fullWidthMedia
|
|
18
|
-
const imageObject =
|
|
17
|
+
const { url, color, disableCompress, fullWidth, fullWidthMedia } = background;
|
|
18
|
+
const imageObject = url && (0, utils_3.getMediaImage)(url);
|
|
19
19
|
if (imageObject && disableCompress) {
|
|
20
20
|
imageObject.disableCompress = disableCompress;
|
|
21
21
|
}
|
|
@@ -11,8 +11,8 @@ import { getMediaImage } from '../../components/Media/Image/utils';
|
|
|
11
11
|
import './Header.css';
|
|
12
12
|
const b = block('header-block');
|
|
13
13
|
const Background = ({ background }) => {
|
|
14
|
-
const { url, color, disableCompress, fullWidth, fullWidthMedia
|
|
15
|
-
const imageObject =
|
|
14
|
+
const { url, color, disableCompress, fullWidth, fullWidthMedia } = background;
|
|
15
|
+
const imageObject = url && getMediaImage(url);
|
|
16
16
|
if (imageObject && disableCompress) {
|
|
17
17
|
imageObject.disableCompress = disableCompress;
|
|
18
18
|
}
|