Skip to content

Commit

Permalink
fixed #1375
Browse files Browse the repository at this point in the history
  • Loading branch information
Mrtcndkn committed Nov 21, 2016
1 parent 556332d commit f33c025
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions components/accordion/accordion.ts
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import {NgModule,Component,ElementRef,AfterContentInit,Input,Output,EventEmitter,ContentChild,
import {NgModule,Component,ElementRef,AfterContentInit,Input,Output,EventEmitter,ContentChildren,QueryList,
trigger,state,transition,style,animate} from '@angular/core';
import {CommonModule} from '@angular/common';
import {Header} from '../common/shared';
Expand Down Expand Up @@ -43,9 +43,9 @@ export class Accordion implements BlockableUI {
<div class="ui-accordion-header ui-state-default ui-corner-all" [ngClass]="{'ui-state-active': selected,'ui-state-hover':hover&&!disabled,'ui-state-disabled':disabled}"
(mouseenter)="hover = true" (mouseleave)="hover=false" (click)="toggle($event)">
<span class="fa fa-fw" [ngClass]="{'fa-caret-down': selected, 'fa-caret-right': !selected}"></span>
<a href="#" *ngIf="!headerFacet" role="tab" [attr.aria-expanded]="selected" [attr.aria-selected]="selected">{{header}}</a>
<a href="#" *ngIf="headerFacet" role="tab" [attr.aria-expanded]="selected" [attr.aria-selected]="selected">
{{header}}<ng-content select="header"></ng-content>
<a href="#" *ngIf="!headerFacet.length" role="tab" [attr.aria-expanded]="selected" [attr.aria-selected]="selected">{{header}}</a>
<a href="#" *ngIf="headerFacet.length" role="tab" [attr.aria-expanded]="selected" [attr.aria-selected]="selected">
<ng-content select="header"></ng-content>
</a>
</div>
<div class="ui-accordion-content-wrapper" [@tabContent]="selected ? 'visible' : 'hidden'"
Expand Down Expand Up @@ -78,7 +78,7 @@ export class AccordionTab {

@Output() selectedChange: EventEmitter<any> = new EventEmitter();

@ContentChild(Header) headerFacet;
@ContentChildren(Header) headerFacet: QueryList<AccordionTab>;

public animating: boolean;

Expand Down

0 comments on commit f33c025

Please sign in to comment.