mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2026-01-18 21:38:14 +00:00
Merge branch fix/componentNotFound into develop
Title: fix: renderer not rendering correct components when loading components with loadAsyncLibrary api fix: renderer not rendering correct components when loading components with loadAsyncLibrary api Link: https://code.aone.alibaba-inc.com/ali-lowcode/ali-lowcode-engine/codereview/8411442
This commit is contained in:
commit
e4ae885394
@ -332,7 +332,7 @@ export class SimulatorRendererContainer implements BuiltinSimulatorRenderer {
|
|||||||
...this._components,
|
...this._components,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
private _components: any = {};
|
@obx.ref private _components: any = {};
|
||||||
|
|
||||||
get components(): object {
|
get components(): object {
|
||||||
// 根据 device 选择不同组件,进行响应式
|
// 根据 device 选择不同组件,进行响应式
|
||||||
|
|||||||
@ -421,7 +421,14 @@ export default function baseRendererFactory() {
|
|||||||
|
|
||||||
if (!Comp) {
|
if (!Comp) {
|
||||||
console.error(`${schema.componentName} is not found! component list is:`, components || this.props.__container?.components);
|
console.error(`${schema.componentName} is not found! component list is:`, components || this.props.__container?.components);
|
||||||
Comp = engine.getNotFoundComponent();
|
return engine.createElement(
|
||||||
|
engine.getNotFoundComponent(),
|
||||||
|
{
|
||||||
|
componentName: schema.componentName,
|
||||||
|
componentId: schema.id,
|
||||||
|
},
|
||||||
|
this.__getSchemaChildrenVirtualDom(schema, scope, Comp),
|
||||||
|
);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (schema.hidden && (engine?.props?.designMode && engine?.props?.designMode !== 'design')) {
|
if (schema.hidden && (engine?.props?.designMode && engine?.props?.designMode !== 'design')) {
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user