text: "use strict";
  Object.defineProperty(exports, "__esModule", { value: true });
  var core_1 = require("@angular/core");
  var collapsible_item_component_1 = require("./collapsible-item/collapsible-item.component");
  var MzCollapsibleComponent = (function () {
      function MzCollapsibleComponent(renderer) {
          this.renderer = renderer;
      }
      MzCollapsibleComponent.prototype.ngAfterViewInit = function () {
          this.handleDataCollapsible();
          this.initCollapsible();
      };
      MzCollapsibleComponent.prototype.initCollapsible = function () {
          var options = {
              accordion: false,
              onClose: this.onClose,
              onOpen: this.onOpen,
          };
          this.renderer.invokeElementMethod($(this.collapsible.nativeElement), 'collapsible', [options]);
      };
      MzCollapsibleComponent.prototype.handleDataCollapsible = function () {
          if (this.mode) {
              this.renderer.setElementAttribute(this.collapsible.nativeElement, 'data-collapsible', this.mode);
          }
      };
      return MzCollapsibleComponent;
  }());
  MzCollapsibleComponent.decorators = [
      { type: core_1.Component, args: [{
                  selector: 'mz-collapsible',
                  template: "<ul #collapsible class=\"collapsible\" [class.popout]=\"popout\" [hidden]=\"items.length === 0\"><ng-content></ng-content></ul>",
                  styles: ["/deep/ .collapsible-header{clear:both}/deep/ .collapsible-body{clear:both}"],
              },] },
  ];
  /** @nocollapse */
  MzCollapsibleComponent.ctorParameters = function () { return [
      { type: core_1.Renderer, },
  ]; };
  MzCollapsibleComponent.propDecorators = {
      'mode': [{ type: core_1.Input },],
      'onClose': [{ type: core_1.Input },],
      'onOpen': [{ type: core_1.Input },],
      'popout': [{ type: core_1.Input },],
      'collapsible': [{ type: core_1.ViewChild, args: ['collapsible',] },],
      'items': [{ type: core_1.ContentChildren, args: [collapsible_item_component_1.MzCollapsibleItemComponent,] },],
  };
  exports.MzCollapsibleComponent = MzCollapsibleComponent;
  