mirror of
https://github.com/alibaba/lowcode-engine.git
synced 2025-12-12 03:01:16 +00:00
feat: 新增render notFoundComponent、faultComponent engineConfig配置
This commit is contained in:
parent
73acf6f112
commit
fceffce5cd
@ -258,6 +258,14 @@ export class BuiltinSimulatorHost implements ISimulatorHost<BuiltinSimulatorProp
|
|||||||
return engineConfig.get('enableStrictNotFoundMode') ?? false;
|
return engineConfig.get('enableStrictNotFoundMode') ?? false;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
get notFoundComponent(): any {
|
||||||
|
return engineConfig.get('notFoundComponent') ?? null;
|
||||||
|
}
|
||||||
|
|
||||||
|
get faultComponent(): any {
|
||||||
|
return engineConfig.get('faultComponent') ?? null;
|
||||||
|
}
|
||||||
|
|
||||||
@computed get componentsAsset(): Asset | undefined {
|
@computed get componentsAsset(): Asset | undefined {
|
||||||
return this.get('componentsAsset');
|
return this.get('componentsAsset');
|
||||||
}
|
}
|
||||||
|
|||||||
@ -188,6 +188,8 @@ class Renderer extends Component<{
|
|||||||
getNode={(id: string) => documentInstance.getNode(id) as Node}
|
getNode={(id: string) => documentInstance.getNode(id) as Node}
|
||||||
rendererName="PageRenderer"
|
rendererName="PageRenderer"
|
||||||
thisRequiredInJSE={host.thisRequiredInJSE}
|
thisRequiredInJSE={host.thisRequiredInJSE}
|
||||||
|
notFoundComponent={host.notFoundComponent}
|
||||||
|
faultComponent={host.faultComponent}
|
||||||
customCreateElement={(Component: any, props: any, children: any) => {
|
customCreateElement={(Component: any, props: any, children: any) => {
|
||||||
const { __id, ...viewProps } = props;
|
const { __id, ...viewProps } = props;
|
||||||
viewProps.componentId = __id;
|
viewProps.componentId = __id;
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user