mirror of
https://gitee.com/baidu/amis.git
synced 2024-12-03 04:28:32 +08:00
不要造成 breakchanges 新增 component 属性
This commit is contained in:
parent
9674e316e1
commit
529b483510
@ -379,7 +379,7 @@ const defaultOmitList = [
|
||||
'hiddenOn',
|
||||
'disabled',
|
||||
'disabledOn',
|
||||
'children',
|
||||
'component',
|
||||
'detectField'
|
||||
];
|
||||
|
||||
@ -504,13 +504,13 @@ class SchemaRenderer extends React.Component<SchemaRendererProps, any> {
|
||||
} else if (schema.children) {
|
||||
return React.isValidElement(schema.children)
|
||||
? schema.children
|
||||
: React.createElement(schema.children as any, {
|
||||
...rest,
|
||||
$path: $path,
|
||||
render: this.renderChild
|
||||
});
|
||||
} else if (typeof schema.render === 'function') {
|
||||
return schema.render({
|
||||
: (schema.children as Function)({
|
||||
...rest,
|
||||
$path: $path,
|
||||
render: this.renderChild
|
||||
});
|
||||
} else if (typeof schema.component === 'function') {
|
||||
return React.createElement(schema.children as any, {
|
||||
...rest,
|
||||
$path: $path,
|
||||
render: this.renderChild
|
||||
|
Loading…
Reference in New Issue
Block a user