Apply suggestions from code review

Use `mobile` class on body to determine the style of `CloseZenButton` instead of an extra class

Co-authored-by: Elian Doran <contact@eliandoran.me>
This commit is contained in:
Papierkorb2292 2025-08-09 16:31:56 +02:00 committed by GitHub
parent d975790e79
commit 4cd4c2f607
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -29,7 +29,7 @@ const TPL = /*html*/`\
-webkit-app-region: no-drag; -webkit-app-region: no-drag;
} }
body.zen .mobile-close-zen-container { body.zen.mobile .close-zen-container {
top: -2px; top: -2px;
} }
@ -45,7 +45,6 @@ export default class CloseZenButton extends BasicWidget {
doRender(): void { doRender(): void {
this.$widget = $(TPL); this.$widget = $(TPL);
this.$widget.toggleClass("mobile-close-zen-container", utils.isMobile())
} }
zenChangedEvent() { zenChangedEvent() {