MCPcopy Index your code
hub / github.com/ionic-team/ionic-framework / getOverlays

Function getOverlays

core/src/utils/overlays.ts:445–450  ·  view source on GitHub ↗
(doc: Document, selector?: string)

Source from the content-addressed store, hash-verified

443 * Returns a list of all overlays in the DOM even if they are not presented.
444 */
445export const getOverlays = (doc: Document, selector?: string): HTMLIonOverlayElement[] => {
446 if (selector === undefined) {
447 selector = 'ion-alert,ion-action-sheet,ion-loading,ion-modal,ion-picker-legacy,ion-popover,ion-toast';
448 }
449 return (Array.from(doc.querySelectorAll(selector)) as HTMLIonOverlayElement[]).filter((c) => c.overlayIndex > 0);
450};
451
452/**
453 * Returns a list of all presented overlays.

Callers 1

getPresentedOverlaysFunction · 0.85

Calls 1

fromMethod · 0.80

Tested by

no test coverage detected