Currently, I am referring to this specific article in order to integrate Bootstrap with Angular 2. While the instructions in the article are helpful, there seems to be a lack of information on how to pass the popover reference to a component method. The only thing mentioned is an NgbPopoverConfig
, which does not have the ability to open the popover.
Here is an example of my component method:
popOpen(p : NgbPopoverConfig): void {
p.open(); //An error occurs here stating no Open method on NgbPopoverConfig
}
Below is the snippet of HTML where a Material 2 based input field is used:
<md-input type="email" value="" name="em" id="em" placement="left" ngbPopover="adfga" popoverTitle="Popover on left" triggers="manual" #p="ngbPopover" (click)="p.Open()" [(ngModel)]="thisModel.email"
#this="ngModel">
</md-input>
Is there any documentation available for programmatically opening and closing the popover from the TypeScript component code? Or perhaps some sample code that can be shared?
My current setup includes Angular 2.1.0, Bootstrap 4.0.0-alpha.5, and Angular Material 2.0.0-alpha.9-3.