From d270d6a0426e4f33dc8ffbf7d1dde991ccaad921 Mon Sep 17 00:00:00 2001 From: Chocobozzz Date: Thu, 16 Feb 2023 16:41:34 +0100 Subject: Fix lint --- client/src/assets/player/shared/settings/settings-menu-button.ts | 5 +---- client/src/assets/player/shared/settings/settings-menu-item.ts | 4 ++-- 2 files changed, 3 insertions(+), 6 deletions(-) (limited to 'client/src') diff --git a/client/src/assets/player/shared/settings/settings-menu-button.ts b/client/src/assets/player/shared/settings/settings-menu-button.ts index 64866aab2..4cf29866b 100644 --- a/client/src/assets/player/shared/settings/settings-menu-button.ts +++ b/client/src/assets/player/shared/settings/settings-menu-button.ts @@ -175,10 +175,7 @@ class SettingsButton extends Button { const el = element.el() as HTMLElement width = el.offsetWidth - height = el.offsetHeight; - - (element as any).width = width; - (element as any).height = height + height = el.offsetHeight } else { width = element.offsetWidth height = element.offsetHeight diff --git a/client/src/assets/player/shared/settings/settings-menu-item.ts b/client/src/assets/player/shared/settings/settings-menu-item.ts index 07ff0f2a8..288e3b233 100644 --- a/client/src/assets/player/shared/settings/settings-menu-item.ts +++ b/client/src/assets/player/shared/settings/settings-menu-item.ts @@ -238,8 +238,8 @@ class SettingsMenuItem extends MenuItem { mainMenuEl.style.opacity = '0' // back button will always take you to main menu, so set dialog sizes - const mainMenuAny = this.mainMenu as any - this.settingsButton.setDialogSize([ mainMenuAny.width, mainMenuAny.height ]) + const mainMenuAny = this.mainMenu + this.settingsButton.setDialogSize([ mainMenuAny.width() as number, mainMenuAny.height() as number ]) // animation not triggered without timeout (some async stuff ?!?) setTimeout(() => { -- cgit v1.2.3