ion-popover-controller
Popover controllers programmatically control the popover component. Popovers can be created and dismissed from the popover controller. View the
Usage
async function presentPopover() {
const popoverElement = Object.assign(document.createElement('ion-popover'), {
component: 'profile-page',
event: event
});
document.body.appendChild(popoverElement);
return await popoverElement.present();
}
Methods
create | |
---|---|
Description | Create a popover overlay with popover options. |
Signature | create<T extends ComponentRef>(options: PopoverOptions<T>) => Promise<HTMLIonPopoverElement> |
dismiss | |
Description | Dismiss the open popover overlay. |
Signature | dismiss(data?: any, role?: string | undefined, id?: string | undefined) => Promise<boolean> |
getTop | |
Description | Get the most recently opened popover overlay. |
Signature | getTop() => Promise<HTMLIonPopoverElement | undefined> |