0

I want to create a nesting table in Angular using Ng-lightning. I'm trying to do that by adding tables inside of an accordion.

However, I can't seem to find a way to set the label of the nglAccordionSection as a component or element instead of just text.

Other solutions besides adding tables to accordions are welcome as well.

1 Answers1

0

Check the "Custom reusable header" example at http://ng-lightning.github.io/ng-lightning/#/components/accordion. There you can see that you can use ng-template as value of the [label].

For example:

<ng-template #header>html header</ng-template>
<ul ngl-accordion [(activeName)]="active">
  <ng-template nglAccordionSection name="A" [label]="header">Content area</ng-template>
</ul>
bekos
  • 1,303
  • 1
  • 13
  • 11