我想使用 Ng-lightning 在 Angular 中创建一个嵌套表。我试图通过在手风琴内添加表格来做到这一点。
但是,我似乎找不到将 nglAccordionSection 的标签设置为组件或元素而不仅仅是文本的方法。
除了向手风琴添加表格外,其他解决方案也受到欢迎。
我想使用 Ng-lightning 在 Angular 中创建一个嵌套表。我试图通过在手风琴内添加表格来做到这一点。
但是,我似乎找不到将 nglAccordionSection 的标签设置为组件或元素而不仅仅是文本的方法。
除了向手风琴添加表格外,其他解决方案也受到欢迎。
检查http://ng-lightning.github.io/ng-lightning/#/components/accordion上的“ Custom reusable header ”示例。在那里你可以看到你可以使用 ng-template 作为.[label]
例如:
<ng-template #header>html header</ng-template>
<ul ngl-accordion [(activeName)]="active">
<ng-template nglAccordionSection name="A" [label]="header">Content area</ng-template>
</ul>