Skip to content

Commit f6f9f7b

Browse files
committed
PB-95: Video background for Row
1 parent 0907a15 commit f6f9f7b

File tree

2 files changed

+4
-4
lines changed
  • app/code/Magento/PageBuilder/view/adminhtml/web

2 files changed

+4
-4
lines changed

app/code/Magento/PageBuilder/view/adminhtml/web/js/content-type/row/preview.js

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

app/code/Magento/PageBuilder/view/adminhtml/web/ts/js/content-type/row/preview.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -42,8 +42,8 @@ export default class Preview extends PreviewCollection {
4242
const backgroundImage = (this.contentType.dataStore.get("background_image") as any[]);
4343
jarallax(this.element, "destroy");
4444
this.element.setAttribute("style", style);
45-
if (this.contentType.dataStore.get("background_type") as string !== "video" && backgroundImage) {
46-
this.element.style.backgroundImage = backgroundImage;
45+
if (this.contentType.dataStore.get("background_type") as string !== "video" && backgroundImage.length) {
46+
this.element.style.backgroundImage = `url(${backgroundImage[0].url})`;
4747
}
4848
} catch (e) {
4949
// Failure of destroying is acceptable

0 commit comments

Comments
 (0)