Skip to content

Commit

Permalink
fix(form): fix ui value cross pollute (#1355)
Browse files Browse the repository at this point in the history
  • Loading branch information
cipchk authored Sep 19, 2021
1 parent 53757c5 commit 65ac839
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions packages/form/src/sf.component.ts
Original file line number Diff line number Diff line change
Expand Up @@ -294,7 +294,7 @@ export class SFComponent implements OnInit, OnChanges, OnDestroy {
Object.keys(schema.properties!).forEach(key => {
const uiKey = `$${key}`;
const property = retrieveSchema(schema.properties![key] as SFSchema, definitions);
const ui = {
const ui = deepCopy({
widget: property.type,
...(property.format && (this.options.formatMap as NzSafeAny)[property.format]),
...(typeof property.ui === 'string' ? { widget: property.ui } : null),
Expand All @@ -304,7 +304,7 @@ export class SFComponent implements OnInit, OnChanges, OnDestroy {
...this._defUi,
...(property.ui as SFUISchemaItem),
...uiSchema[uiKey]
} as SFUISchemaItemRun;
}) as SFUISchemaItemRun;
// 继承父节点布局属性
if (isHorizontal) {
if (parentUiSchema.spanLabelFixed) {
Expand Down

0 comments on commit 65ac839

Please sign in to comment.