From c95a54df717099f315a6141939bcf2f9874bb7fd Mon Sep 17 00:00:00 2001 From: Kamran Ahmed Date: Fri, 8 Feb 2019 01:10:42 +0400 Subject: [PATCH] Expose refresh functionality --- src/index.js | 7 +++++++ types/index.d.ts | 5 +++++ 2 files changed, 12 insertions(+) diff --git a/src/index.js b/src/index.js index a195c05..934082f 100644 --- a/src/index.js +++ b/src/index.js @@ -155,6 +155,13 @@ export default class Driver { return; } + this.refresh(); + } + + /** + * Refreshes and repositions the popover and the overlay + */ + refresh() { this.overlay.refresh(); } diff --git a/types/index.d.ts b/types/index.d.ts index 4d9de47..b49207a 100644 --- a/types/index.d.ts +++ b/types/index.d.ts @@ -69,6 +69,11 @@ declare module 'driver.js' { */ private onResize(): void; + /** + * Refreshes and repositions the popover and the overlay + */ + private refresh(): void; + /** * Makes it operable with keyboard * @param {Event} e -- GitLab