Skip to content

Commit 473408b

Browse files
author
Michael Yu
committed
MC-2217: Add support for new config structure
- Updated frontend composite reader
1 parent 7782438 commit 473408b

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

app/code/Magento/PageBuilder/view/adminhtml/web/js/master-format/read/composite.js

Lines changed: 1 addition & 1 deletion
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/master-format/read/composite.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,9 @@ export default class AttributeReaderComposite implements ReadInterface {
3535
if (!this.contentTypeConfig.hasOwnProperty(role)) {
3636
resolve(result);
3737
} else {
38-
const readerComponents = appearanceConfig(role, element.dataset.appearance).readers;
38+
const readerComponents = appearanceConfig(role, element.dataset.appearance).reader ?
39+
[appearanceConfig(role, element.dataset.appearance).reader] :
40+
appearanceConfig(role, element.dataset.appearance).readers;
3941
try {
4042
loadComponent(readerComponents, (...readers: any[]) => {
4143
const readerPromises: Array<Promise<any>> = [];

0 commit comments

Comments
 (0)