aboutsummaryrefslogtreecommitdiff
path: root/ext/js/display/element-overflow-controller.js
diff options
context:
space:
mode:
authortoasted-nutbread <toasted-nutbread@users.noreply.github.com>2023-11-27 19:33:01 -0500
committertoasted-nutbread <toasted-nutbread@users.noreply.github.com>2023-11-27 19:33:01 -0500
commit14d12f6ba20b837a04c638b935773f3120e194ff (patch)
treedcd6b61d51ff39c97b60812b2bf3c8cd564347f8 /ext/js/display/element-overflow-controller.js
parentd5b1217df3fe7480fc5f58fe194f5bbf73281094 (diff)
Update timer types and such
Diffstat (limited to 'ext/js/display/element-overflow-controller.js')
-rw-r--r--ext/js/display/element-overflow-controller.js8
1 files changed, 4 insertions, 4 deletions
diff --git a/ext/js/display/element-overflow-controller.js b/ext/js/display/element-overflow-controller.js
index 1d2c808f..35277fa5 100644
--- a/ext/js/display/element-overflow-controller.js
+++ b/ext/js/display/element-overflow-controller.js
@@ -22,7 +22,7 @@ export class ElementOverflowController {
constructor() {
/** @type {Element[]} */
this._elements = [];
- /** @type {?number} */
+ /** @type {?(number|import('core').Timeout)} */
this._checkTimer = null;
/** @type {EventListenerCollection} */
this._eventListeners = new EventListenerCollection();
@@ -154,7 +154,7 @@ export class ElementOverflowController {
/**
* @param {() => void} callback
* @param {number} timeout
- * @returns {number}
+ * @returns {number|import('core').Timeout}
*/
_requestIdleCallback(callback, timeout) {
if (typeof requestIdleCallback === 'function') {
@@ -165,11 +165,11 @@ export class ElementOverflowController {
}
/**
- * @param {number} handle
+ * @param {number|import('core').Timeout} handle
*/
_cancelIdleCallback(handle) {
if (typeof cancelIdleCallback === 'function') {
- cancelIdleCallback(handle);
+ cancelIdleCallback(/** @type {number} */ (handle));
} else {
clearTimeout(handle);
}