Iva*_*van 1 ng-bootstrap angular
可以将html放在ngbPopover中吗?确切地说,我需要列出项目清单.目前我有这个参数:
`ngbPopover="{{column.popup.get(row)}}" triggers="mouseenter:mouseleave" popoverTitle="{{column.popup.title | translate}}" container="body"`
Run Code Online (Sandbox Code Playgroud)
pko*_*rce 11
是的,但你需要使用这样的<ng-template>元素:
<ng-template #popContent>Hello, <b>{{name}}</b>!</ng-template>
<button type="button" class="btn btn-secondary" [ngbPopover]="popContent" popoverTitle="Fancy content">
I've got markup and bindings in my popover!
</button>
Run Code Online (Sandbox Code Playgroud)
这是一个工作的plunker:http://plnkr.co/edit/re1JbPmiF11Qm3Pf3BtW?p = preview
这也在演示页面上记录:https://ng-bootstrap.github.io/#/components/popover/examples
| 归档时间: |
|
| 查看次数: |
7368 次 |
| 最近记录: |