From 2a5e06e6c89cdb50625710364597e0360a24382e Mon Sep 17 00:00:00 2001 From: HyperLifelll9 Date: Mon, 9 Sep 2024 21:03:47 +0800 Subject: [PATCH] refactor(module:tree-select): simpilfy code (#8734) --- components/tree-select/tree-select.component.ts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/components/tree-select/tree-select.component.ts b/components/tree-select/tree-select.component.ts index 70a28eb78a..5f4274c6dd 100644 --- a/components/tree-select/tree-select.component.ts +++ b/components/tree-select/tree-select.component.ts @@ -226,7 +226,7 @@ const listOfPositions = [ } ], host: { - class: 'ant-select', + class: 'ant-select ant-tree-select', '[class.ant-select-in-form-item]': '!!nzFormStatusService', '[class.ant-select-lg]': 'nzSize==="large"', '[class.ant-select-rtl]': 'dir==="rtl"', @@ -371,9 +371,6 @@ export class NzTreeSelectComponent extends NzTreeBase implements ControlValueAcc private focusMonitor: FocusMonitor ) { super(nzTreeService); - - this.renderer.addClass(this.elementRef.nativeElement, 'ant-select'); - this.renderer.addClass(this.elementRef.nativeElement, 'ant-tree-select'); } ngOnInit(): void {