UNPKG

ng2-bootstrap-base-modified

Version:

Native Angular Bootstrap Components Typeahead modified

30 lines (25 loc) 644 B
import { Component } from '@angular/core'; @Component({ selector: 'demo-accordion-dynamic', templateUrl: './dynamic.html' }) export class DemoAccordionDynamicComponent { public items: string[] = ['Item 1', 'Item 2', 'Item 3']; public status: any = { isFirstOpen: true, isOpen: false }; public groups: any[] = [ { title: 'Dynamic Group Header - 1', content: 'Dynamic Group Body - 1' }, { title: 'Dynamic Group Header - 2', content: 'Dynamic Group Body - 2' } ]; public addItem(): void { this.items.push(`Items ${this.items.length + 1}`); } }