diff --git a/backend/src/main/kotlin/net/perfectdreams/galleryofdreams/backend/views/ArtistFanArtsView.kt b/backend/src/main/kotlin/net/perfectdreams/galleryofdreams/backend/views/ArtistFanArtsView.kt index f5fa062..220a6e0 100644 --- a/backend/src/main/kotlin/net/perfectdreams/galleryofdreams/backend/views/ArtistFanArtsView.kt +++ b/backend/src/main/kotlin/net/perfectdreams/galleryofdreams/backend/views/ArtistFanArtsView.kt @@ -40,7 +40,7 @@ class ArtistFanArtsView( override fun rightSidebar(): FlowContent.() -> (Unit) = { div { id = "fan-arts-wrapper" - + h1 { text(fanArtArtist.name) } diff --git a/backend/src/main/kotlin/net/perfectdreams/galleryofdreams/backend/views/DashboardView.kt b/backend/src/main/kotlin/net/perfectdreams/galleryofdreams/backend/views/DashboardView.kt index e03c03b..c32d7e1 100644 --- a/backend/src/main/kotlin/net/perfectdreams/galleryofdreams/backend/views/DashboardView.kt +++ b/backend/src/main/kotlin/net/perfectdreams/galleryofdreams/backend/views/DashboardView.kt @@ -170,6 +170,7 @@ abstract class DashboardView( a(classes = "entry", href = "/${i18nContext.websiteLocaleIdPath}/fan-arts") { attributes["hx-target"] = "#content" + attributes["power-close-sidebar"] = "true" text(i18nContext.get(I18nKeysData.ViewAllFanArts(totalFanArtCount))) } diff --git a/frontend/src/jsMain/kotlin/net/perfectdreams/galleryofdreams/frontend/GalleryOfDreamsFrontend.kt b/frontend/src/jsMain/kotlin/net/perfectdreams/galleryofdreams/frontend/GalleryOfDreamsFrontend.kt index 7f3b905..9ac1698 100644 --- a/frontend/src/jsMain/kotlin/net/perfectdreams/galleryofdreams/frontend/GalleryOfDreamsFrontend.kt +++ b/frontend/src/jsMain/kotlin/net/perfectdreams/galleryofdreams/frontend/GalleryOfDreamsFrontend.kt @@ -33,6 +33,8 @@ class GalleryOfDreamsFrontend { leftSidebarMobileElement.addClass("is-open") leftSidebarElement.removeClass("is-closed") leftSidebarMobileElement.removeClass("is-closed") + + isLeftSidebarOpen = true } private fun closeSidebar() { @@ -40,6 +42,8 @@ class GalleryOfDreamsFrontend { leftSidebarMobileElement.removeClass("is-open") leftSidebarElement.addClass("is-closed") leftSidebarMobileElement.addClass("is-closed") + + isLeftSidebarOpen = false } private fun toggleSidebar() { @@ -48,8 +52,6 @@ class GalleryOfDreamsFrontend { } else { closeSidebar() } - - isLeftSidebarOpen = !isLeftSidebarOpen } fun start() {