UNPKG

cross-domain-utils

Version:
57 lines (54 loc) 2.73 kB
// @flow import {isRegex, noop} from "./util"; declare class Class0 extends HTMLElement<> { allowFullScreen: boolean; contentDocument: Document; contentWindow: any; frameBorder: string; height: string; marginHeight: string; marginWidth: string; name: string; sandbox: DOMTokenList; scrolling: string; src: string; srcDoc: string; width: string; } declare export function findChildFrameByName(win: any, name: string): void; declare export function findFrameByName(win: any, name: string): void; declare export function getActualDomain(win: any): string; declare export function getAllChildFrames(win: any): []; declare export function getAllFramesInWindow(win: any): Array<any>; declare export function getAncestor(win: any): void; declare export function getAncestors(win: any): []; declare export function getDistanceFromTop(win?: any): number; declare export function getDomain(win: any): string; declare export function getDomainFromUrl(url: string): string; declare export function getFrameByName(win: any, name: string): void; declare export function getFrames(win: any): []; declare export function getNthParent(win: any, n?: number): any; declare export function getNthParentFromTop(win: any, n?: number): any; declare export function getOpener(win: any): void; declare export function getParent(win: any): void; declare export function getParents(win: any): []; declare export function getTop(win: any): void; declare export function getUserAgent(win: any): any; declare export function isActuallySameDomain(win: any): boolean; declare export function isAncestor(parent: any, child: any): boolean; declare export function isAncestorParent(parent: any, child: any): boolean; declare export function isBlankDomain(win: any): boolean; declare export function isFrameWindowClosed(frame: Class0): boolean; declare export function isFullpage(): boolean; declare export function isIframe(): boolean; declare export function isOpener(parent: any, child: any): boolean; declare export function isParent(win: any, frame: any): boolean; declare export function isPopup(): boolean; declare export function isSameDomain(win: any): boolean; declare export function isSameTopWindow(win1: any, win2: any): boolean | boolean | boolean | boolean | boolean | void; declare export function isTop(win: any): boolean; declare export function isWindow(obj: Object): boolean; declare export function isWindowClosed(win: any, allowMock?: boolean): boolean; declare export function linkFrameWindow(frame: Class0): void; declare export function matchDomain(pattern: any, origin: any): boolean; declare export function onCloseWindow(win: any, callback: Function, delay?: number, maxtime?: number): {cancel: () => void};