text: import { __decorate, __metadata } from 'tslib';
  import { Component, ChangeDetectionStrategy, ViewEncapsulation, Input, EventEmitter, ChangeDetectorRef, Host, ElementRef, Renderer2, Output, NgModule } from '@angular/core';
  import { NzConfigService, WithConfig, InputBoolean, collapseMotion, NzAddOnModule } from 'ng-zorro-antd/core';
  import { CommonModule } from '@angular/common';
  import { NzIconModule } from 'ng-zorro-antd/icon';
  
  /**
   * @fileoverview added by tsickle
   * Generated from: nz-collapse.component.ts
   * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
   */
  /** @type {?} */
  const NZ_CONFIG_COMPONENT_NAME = 'collapse';
  class NzCollapseComponent {
      /**
       * @param {?} nzConfigService
       */
      constructor(nzConfigService) {
          this.nzConfigService = nzConfigService;
          this.listOfNzCollapsePanelComponent = [];
      }
      /**
       * @param {?} value
       * @return {?}
       */
      addPanel(value) {
          this.listOfNzCollapsePanelComponent.push(value);
      }
      /**
       * @param {?} value
       * @return {?}
       */
      removePanel(value) {
          this.listOfNzCollapsePanelComponent.splice(this.listOfNzCollapsePanelComponent.indexOf(value), 1);
      }
      /**
       * @param {?} collapse
       * @return {?}
       */
      click(collapse) {
          if (this.nzAccordion && !collapse.nzActive) {
              this.listOfNzCollapsePanelComponent
                  .filter((/**
               * @param {?} item
               * @return {?}
               */
              item => item !== collapse))
                  .forEach((/**
               * @param {?} item
               * @return {?}
               */
              item => {
                  if (item.nzActive) {
                      item.nzActive = false;
                      item.nzActiveChange.emit(item.nzActive);
                      item.markForCheck();
                  }
              }));
          }
          collapse.nzActive = !collapse.nzActive;
          collapse.nzActiveChange.emit(collapse.nzActive);
      }
  }
  NzCollapseComponent.decorators = [
      { type: Component, args: [{
                  selector: 'nz-collapse',
                  exportAs: 'nzCollapse',
                  template: "<div class=\"ant-collapse\" [class.ant-collapse-borderless]=\"!nzBordered\">\n  <ng-content></ng-content>\n</div>",
                  changeDetection: ChangeDetectionStrategy.OnPush,
                  encapsulation: ViewEncapsulation.None,
                  styles: [`
        nz-collapse {
          display: block;
        }
      `]
              }] }
  ];
  /** @nocollapse */
  NzCollapseComponent.ctorParameters = () => [
      { type: NzConfigService }
  ];
  NzCollapseComponent.propDecorators = {
      nzAccordion: [{ type: Input }],
      nzBordered: [{ type: Input }]
  };
  __decorate([
      WithConfig(NZ_CONFIG_COMPONENT_NAME, false), InputBoolean(),
      __metadata("design:type", Boolean)
  ], NzCollapseComponent.prototype, "nzAccordion", void 0);
  __decorate([
      WithConfig(NZ_CONFIG_COMPONENT_NAME, true), InputBoolean(),
      __metadata("design:type", Boolean)
  ], NzCollapseComponent.prototype, "nzBordered", void 0);
  if (false) {
      /**
       * @type {?}
       * @private
       */
      NzCollapseComponent.prototype.listOfNzCollapsePanelComponent;
      /** @type {?} */
      NzCollapseComponent.prototype.nzAccordion;
      /** @type {?} */
      NzCollapseComponent.prototype.nzBordered;
      /** @type {?} */
      NzCollapseComponent.prototype.nzConfigService;
  }
  
  /**
   * @fileoverview added by tsickle
   * Generated from: nz-collapse-panel.component.ts
   * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
   */
  /** @type {?} */
  const NZ_CONFIG_COMPONENT_NAME$1 = 'collapsePanel';
  class NzCollapsePanelComponent {
      /**
       * @param {?} nzConfigService
       * @param {?} cdr
       * @param {?} nzCollapseComponent
       * @param {?} elementRef
       * @param {?} renderer
       */
      constructor(nzConfigService, cdr, nzCollapseComponent, elementRef, renderer) {
          this.nzConfigService = nzConfigService;
          this.cdr = cdr;
          this.nzCollapseComponent = nzCollapseComponent;
          this.nzActive = false;
          this.nzDisabled = false;
          this.nzActiveChange = new EventEmitter();
          renderer.addClass(elementRef.nativeElement, 'ant-collapse-item');
      }
      /**
       * @return {?}
       */
      clickHeader() {
          if (!this.nzDisabled) {
              this.nzCollapseComponent.click(this);
          }
      }
      /**
       * @return {?}
       */
      markForCheck() {
          this.cdr.markForCheck();
      }
      /**
       * @return {?}
       */
      ngOnInit() {
          this.nzCollapseComponent.addPanel(this);
      }
      /**
       * @return {?}
       */
      ngOnDestroy() {
          this.nzCollapseComponent.removePanel(this);
      }
  }
  NzCollapsePanelComponent.decorators = [
      { type: Component, args: [{
                  selector: 'nz-collapse-panel',
                  exportAs: 'nzCollapsePanel',
                  template: "<div role=\"tab\" [attr.aria-expanded]=\"nzActive\" class=\"ant-collapse-header\" (click)=\"clickHeader()\">\n  <ng-container *ngIf=\"nzShowArrow\">\n    <ng-container *nzStringTemplateOutlet=\"nzExpandedIcon\">\n      <i nz-icon [nzType]=\"nzExpandedIcon || 'right'\" class=\"ant-collapse-arrow\" [nzRotate]=\"nzActive ? 90 : 0\"></i>\n    </ng-container>\n  </ng-container>\n  <ng-container *nzStringTemplateOutlet=\"nzHeader\">{{ nzHeader }}</ng-container>\n  <div class=\"ant-collapse-extra\" *ngIf=\"nzExtra\">\n    <ng-container *nzStringTemplateOutlet=\"nzExtra\">{{ nzExtra }}</ng-container>\n  </div>\n</div>\n<div class=\"ant-collapse-content\"\n  [class.ant-collapse-content-active]=\"nzActive\"\n  [@collapseMotion]=\"nzActive ? 'expanded' : 'hidden' \">\n  <div class=\"ant-collapse-content-box\">\n    <ng-content></ng-content>\n  </div>\n</div>\n",
                  changeDetection: ChangeDetectionStrategy.OnPush,
                  encapsulation: ViewEncapsulation.None,
                  animations: [collapseMotion],
                  host: {
                      '[class.ant-collapse-no-arrow]': '!nzShowArrow',
                      '[class.ant-collapse-item-active]': 'nzActive',
                      '[class.ant-collapse-item-disabled]': 'nzDisabled'
                  },
                  styles: [`
        nz-collapse-panel {
          display: block;
        }
      `]
              }] }
  ];
  /** @nocollapse */
  NzCollapsePanelComponent.ctorParameters = () => [
      { type: NzConfigService },
      { type: ChangeDetectorRef },
      { type: NzCollapseComponent, decorators: [{ type: Host }] },
      { type: ElementRef },
      { type: Renderer2 }
  ];
  NzCollapsePanelComponent.propDecorators = {
      nzActive: [{ type: Input }],
      nzDisabled: [{ type: Input }],
      nzShowArrow: [{ type: Input }],
      nzExtra: [{ type: Input }],
      nzHeader: [{ type: Input }],
      nzExpandedIcon: [{ type: Input }],
      nzActiveChange: [{ type: Output }]
  };
  __decorate([
      InputBoolean(),
      __metadata("design:type", Object)
  ], NzCollapsePanelComponent.prototype, "nzActive", void 0);
  __decorate([
      InputBoolean(),
      __metadata("design:type", Object)
  ], NzCollapsePanelComponent.prototype, "nzDisabled", void 0);
  __decorate([
      WithConfig(NZ_CONFIG_COMPONENT_NAME$1, true), InputBoolean(),
      __metadata("design:type", Boolean)
  ], NzCollapsePanelComponent.prototype, "nzShowArrow", void 0);
  if (false) {
      /** @type {?} */
      NzCollapsePanelComponent.prototype.nzActive;
      /** @type {?} */
      NzCollapsePanelComponent.prototype.nzDisabled;
      /** @type {?} */
      NzCollapsePanelComponent.prototype.nzShowArrow;
      /** @type {?} */
      NzCollapsePanelComponent.prototype.nzExtra;
      /** @type {?} */
      NzCollapsePanelComponent.prototype.nzHeader;
      /** @type {?} */
      NzCollapsePanelComponent.prototype.nzExpandedIcon;
      /** @type {?} */
      NzCollapsePanelComponent.prototype.nzActiveChange;
      /** @type {?} */
      NzCollapsePanelComponent.prototype.nzConfigService;
      /**
       * @type {?}
       * @private
       */
      NzCollapsePanelComponent.prototype.cdr;
      /**
       * @type {?}
       * @private
       */
      NzCollapsePanelComponent.prototype.nzCollapseComponent;
  }
  
  /**
   * @fileoverview added by tsickle
   * Generated from: nz-collapse.module.ts
   * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
   */
  class NzCollapseModule {
  }
  NzCollapseModule.decorators = [
      { type: NgModule, args: [{
                  declarations: [NzCollapsePanelComponent, NzCollapseComponent],
                  exports: [NzCollapsePanelComponent, NzCollapseComponent],
                  imports: [CommonModule, NzIconModule, NzAddOnModule]
              },] }
  ];
  
  /**
   * @fileoverview added by tsickle
   * Generated from: public-api.ts
   * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
   */
  
  /**
   * @fileoverview added by tsickle
   * Generated from: ng-zorro-antd-collapse.ts
   * @suppress {checkTypes,constantProperty,extraRequire,missingOverride,missingReturn,unusedPrivateMembers,uselessCode} checked by tsc
   */
  
  export { NzCollapseComponent, NzCollapseModule, NzCollapsePanelComponent };
  //# sourceMappingURL=ng-zorro-antd-collapse.js.map
  