diff options
| author | Michael Howell <michael@notriddle.com> | 2025-01-29 13:11:17 -0700 |
|---|---|---|
| committer | Michael Howell <michael@notriddle.com> | 2025-02-03 10:04:17 -0700 |
| commit | 2ea95f867012e91fa742e60b7b6424abf86c05cf (patch) | |
| tree | 423eec5221aa1a81d0dac2243ae6176e83f75543 /src/librustdoc/html/static/js/rustdoc.d.ts | |
| parent | f2c4ccd852f68fb36dedc033239cb7c0fb1921ef (diff) | |
| download | rust-2ea95f867012e91fa742e60b7b6424abf86c05cf.tar.gz rust-2ea95f867012e91fa742e60b7b6424abf86c05cf.zip | |
rustdoc: clean up a bunch of ts-expected-error declarations in main
This mostly consists of handling potentially-null input and adding more global functions to the list of globals.
Diffstat (limited to 'src/librustdoc/html/static/js/rustdoc.d.ts')
| -rw-r--r-- | src/librustdoc/html/static/js/rustdoc.d.ts | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/librustdoc/html/static/js/rustdoc.d.ts b/src/librustdoc/html/static/js/rustdoc.d.ts index 18a3e22113b..acea7828e86 100644 --- a/src/librustdoc/html/static/js/rustdoc.d.ts +++ b/src/librustdoc/html/static/js/rustdoc.d.ts @@ -20,6 +20,28 @@ declare global { * As a multi-page application, we know this never changes once set. */ currentCrate: string|null; + /** + * Hide popovers, tooltips, or the mobile sidebar. + */ + hideAllModals: function(boolean), + /** + * Hide popovers, but leave other modals alone. + */ + hidePopoverMenus: function(), + /** + * Hide the source page sidebar. If it's already closed, + * or if this is a docs page, this function does nothing. + */ + rustdocCloseSourceSidebar: function(), + /** + * Show the source page sidebar. If it's already opened, + * or if this is a docs page, this function does nothing. + */ + rustdocShowSourceSidebar: function(), + /** + * Set up event listeners for a scraped source example. + */ + updateScrapedExample?: function(HTMLElement, HTMLElement), } interface HTMLElement { /** Used by the popover tooltip code. */ |
