diff --git a/components/checkbox/nz-checkbox-wrapper.component.html b/components/checkbox/nz-checkbox-wrapper.component.html
index 2c761877f8..95a0b70bdc 100644
--- a/components/checkbox/nz-checkbox-wrapper.component.html
+++ b/components/checkbox/nz-checkbox-wrapper.component.html
@@ -1,3 +1 @@
-
-
-
\ No newline at end of file
+
\ No newline at end of file
diff --git a/components/checkbox/nz-checkbox-wrapper.component.ts b/components/checkbox/nz-checkbox-wrapper.component.ts
index a3dc584ce2..a1b0dff366 100644
--- a/components/checkbox/nz-checkbox-wrapper.component.ts
+++ b/components/checkbox/nz-checkbox-wrapper.component.ts
@@ -5,7 +5,10 @@ import { NzCheckboxComponent } from './nz-checkbox.component';
@Component({
selector : 'nz-checkbox-wrapper',
preserveWhitespaces: false,
- templateUrl : './nz-checkbox-wrapper.component.html'
+ templateUrl : './nz-checkbox-wrapper.component.html',
+ host : {
+ '[class.ant-checkbox-group]': 'true'
+ }
})
export class NzCheckboxWrapperComponent {
@Output() nzOnChange = new EventEmitter();
diff --git a/components/checkbox/nz-checkbox.spec.ts b/components/checkbox/nz-checkbox.spec.ts
index a43c1236a2..da43486ee5 100644
--- a/components/checkbox/nz-checkbox.spec.ts
+++ b/components/checkbox/nz-checkbox.spec.ts
@@ -251,7 +251,7 @@ describe('checkbox', () => {
inputElement = checkboxWrapper.nativeElement.querySelector('input') as HTMLInputElement;
}));
it('should className correct', fakeAsync(() => {
- expect(checkboxWrapper.nativeElement.firstElementChild.classList).toContain('ant-checkbox-group');
+ expect(checkboxWrapper.nativeElement.classList).toContain('ant-checkbox-group');
}));
it('should onChange correct', fakeAsync(() => {
inputElement.click();