/// /** * Wait Class */ declare class Wait { /** * Waits for an element to be removed or become invisible on the page * * ```js * Wait.waitUntilInvisibilityOfElement("//input[@id='login']",20); * ``` * * @param {String} locator locator located by xpath|CSS * @param {String} timeoutSecs in secs * */ static waitUntilInvisibilityOfElement(locator: string, timeoutSecs?: number): Promise; /** * Waits for an element to become visible on the page * * ```js * Wait.waitUntilVisibilityOfElement("//input[@id='login']",20); * ``` * * @param {String} locator located by xpath|CSS * @param {String} timeoutSecs in secs * */ static waitUntilVisibilityOfElement(locator: string | CodeceptJS.Locator, timeoutSecs?: number): Promise; /** * Pauses for an execution for a number of secs * * ```js * Wait.waitForDefaultTimeout(20); * ``` * * @param {String} timeoutSecs in secs * */ static waitForDefaultTimeout(timeoutSecs: number): Promise; /** * Waits for an element to be clickable * * ```js * Wait.waitForElementClickable("//input[@id='login']",20); * ``` * * @param {String} locator located by xpath|CSS * @param {String} timeoutSecs in secs * */ static waitForElementClickable(locator: string, timeoutSecs?: number): Promise; /** * Waits for a text to appear * * ```js * Wait.waitForVisibilityOfText("Apple",20); * ``` * * @param {String} text * @param {String} timeoutSecs in secs * */ static waitForVisibilityOfText(text: string, timeoutSecs?: number): Promise; /** * Waits for a specified value of attribute * * ```js * Wait.waitForVisibilityOfValue("//input[@id='name']","John",20); * ``` * @param {string} locator * @param {String} value "value" * @param {String} timeoutSecs in secs * */ static waitForVisibilityOfValue(locator: string, value: string, timeoutSecs?: number): Promise; /** * Waits for an element to become enabled * * ```js * Wait.waitForElementToBeEnabled("//input[@id='login']",20); * ``` * * @param {String} locator specified by CSS | Xpath * @param {String} timeoutSecs in secs * */ static waitForElementToBeEnabled(locator: string, timeoutSecs?: number): Promise; /** * Waits for an URL to match the expected * * ```js * Wait.waitForURLPresent("eInvoice#\auth\login",20); * ``` * * @param {String} URLPart * @param {String} timeoutSecs in secs * */ static waitForURLPresent(URLPart: string, timeoutSecs?: number): Promise; /** * Waits for an element * * ```js * await Wait.waitForElement("//input[@id='login']"",20); * ``` * * @param {String} locator specified by CSS | Xpath * @param {String} timeoutSecs in secs * */ static waitForElement(locator: string, timeoutSecs?: number): Promise; /** * Waits for an element to not attached to DOM * * ```js * Wait.waitForElementToDetach("//input[@id='login']"",20); * ``` * * @param {String} locator specified by CSS | Xpath * @param {String} timeoutSecs in secs * */ static waitForElementToDetach(locator: string, timeoutSecs?: number): Promise; /** * Waits for a specified number of elements * * ```js * Wait.waitForNumberOfElementsToBeVisible("//input",10,20); * ``` * * @param {String} locator specified by CSS | Xpath * @param {number} numberOfElements of elements * @param {String} timeoutSecs in secs * */ static waitForNumberOfElementsToBeVisible(locator: string, numberOfElements: number, timeoutSecs?: number): Promise; /** * Waits for an element to hide * * ```js * Wait.waitForElementToHide(locator,20); * ``` * * @param {function} locator specified as CSS | Xpath * @param {String} timeoutSecs in secs * */ static waitForElementToHide(locator: string, timeoutSecs?: number): Promise; } declare const _default: Wait; export default _default; declare const _Wait: typeof Wait; export { _Wait as Wait };