chore: drop the hide right sidebar setting
This commit is contained in:
1 parent
2f3d030f6c
commit
ae13fb44a3
6 files changed
+62
-29
No files matched your search
@@ -131,8 +131,8 @@ The Modrinth Servers button in the left sidebar can be switched off under
|
||||
Settings > Features > Sidebar.
|
||||
|
||||
The news section in the right sidebar folds away by clicking its heading. The right sidebar itself
|
||||
folds away with the arrow button in the title bar, which upstream only shows once "Hide right
|
||||
sidebar" is turned on in settings. Both remember what they were set to across restarts, and the
|
||||
folds away with the arrow button in the title bar. Upstream shows that button only once "Hide right
|
||||
sidebar" is turned on in settings; here it is always there and that setting is gone. Both remember what they were set to across restarts, and the
|
||||
title bar button briefly shows a check once its state is saved; the first time, a short note
|
||||
explains this. On pages that need the sidebar, such as the mod browser, the button stays in place,
|
||||
greyed out. While the sidebar is folded away, the
|
||||
|
||||
@@ -30,14 +30,15 @@ page headed "Sync features across devices" and would otherwise look like
|
||||
it syncs. The other two are not settings entries - a heading and a title
|
||||
bar button - so nothing there promises anything.
|
||||
---
|
||||
apps/app-frontend/src/App.vue | 184 ++++++++++++++++--
|
||||
apps/app-frontend/src/App.vue | 180 ++++++++++++++++--
|
||||
.../ui/settings/display/BehaviorSettings.vue | 18 --
|
||||
.../ui/settings/display/FeaturesSettings.vue | 28 +++
|
||||
.../src/composables/use-app-settings.ts | 4 +
|
||||
packages/app-lib/src/state/settings.rs | 4 +
|
||||
4 files changed, 205 insertions(+), 15 deletions(-)
|
||||
5 files changed, 201 insertions(+), 33 deletions(-)
|
||||
|
||||
diff --git a/apps/app-frontend/src/App.vue b/apps/app-frontend/src/App.vue
|
||||
index d750a5f..c47484d 100644
|
||||
index d750a5f..76da736 100644
|
||||
--- a/apps/app-frontend/src/App.vue
|
||||
+++ b/apps/app-frontend/src/App.vue
|
||||
@@ -10,6 +10,8 @@ import {
|
||||
@@ -65,14 +66,14 @@ index d750a5f..c47484d 100644
|
||||
NewsArticleCard,
|
||||
NotificationPanel,
|
||||
PopupNotificationPanel,
|
||||
@@ -254,12 +258,46 @@ const credentials = ref()
|
||||
@@ -254,12 +258,42 @@ const credentials = ref()
|
||||
const storedModrinthAccounts = ref([])
|
||||
let credentialsRefreshId = 0
|
||||
const sidebarToggled = ref(true)
|
||||
+// Whether the right sidebar is folded away, remembered across restarts in the
|
||||
+// feature flags. The title bar button below is what normally sets it; the
|
||||
+// "Hide right sidebar" setting still seeds it, so turning that on folds the
|
||||
+// sidebar away as it always did.
|
||||
+// feature flags. The title bar button below is the only thing that sets it:
|
||||
+// upstream's "Hide right sidebar" setting, which used to be what showed that
|
||||
+// button, is gone.
|
||||
watch(
|
||||
- () => appSettings.toggleSidebar,
|
||||
- (toggleSidebar) => {
|
||||
@@ -82,10 +83,6 @@ index d750a5f..c47484d 100644
|
||||
+ sidebarToggled.value = !collapsed
|
||||
},
|
||||
+ { immediate: true },
|
||||
+)
|
||||
+watch(
|
||||
+ () => appSettings.toggleSidebar,
|
||||
+ (hide) => setSidebarCollapsed(hide),
|
||||
)
|
||||
+
|
||||
+// Briefly shows a check on the fold button once the state is saved, and the
|
||||
@@ -115,7 +112,7 @@ index d750a5f..c47484d 100644
|
||||
const forceSidebar = computed(
|
||||
() =>
|
||||
route.path.startsWith('/browse') ||
|
||||
@@ -358,6 +396,21 @@ useQuery({
|
||||
@@ -358,6 +392,21 @@ useQuery({
|
||||
// ad and the gradient being drawn above it.
|
||||
const showAd = computed(() => false)
|
||||
const adConsentAvailable = computed(() => false)
|
||||
@@ -137,7 +134,7 @@ index d750a5f..c47484d 100644
|
||||
providePageContext({
|
||||
hierarchicalSidebarAvailable: ref(true),
|
||||
showAds: showAd,
|
||||
@@ -588,6 +641,25 @@ const messages = defineMessages({
|
||||
@@ -588,6 +637,25 @@ const messages = defineMessages({
|
||||
goBack: { id: 'app.navigation.go-back', defaultMessage: 'Go back' },
|
||||
goForward: { id: 'app.navigation.go-forward', defaultMessage: 'Go forward' },
|
||||
nextImage: { id: 'app.navigation.next-image', defaultMessage: 'Next image' },
|
||||
@@ -163,7 +160,7 @@ index d750a5f..c47484d 100644
|
||||
updateDownloadMissingVersion: {
|
||||
id: 'app.update.download-error.missing-version',
|
||||
defaultMessage: 'Failed to download update: no version available',
|
||||
@@ -2252,6 +2324,7 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
@@ -2252,6 +2320,7 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
<ImageIcon />
|
||||
</NavButton>
|
||||
<NavButton
|
||||
@@ -171,7 +168,7 @@ index d750a5f..c47484d 100644
|
||||
v-tooltip.right="formatMessage(messages.modrinthHosting)"
|
||||
to="/hosting/manage"
|
||||
:is-primary="(r) => r.path === '/hosting/manage' || r.path === '/hosting/manage/'"
|
||||
@@ -2377,16 +2450,42 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
@@ -2377,16 +2446,42 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
<Breadcrumbs />
|
||||
</div>
|
||||
<section data-tauri-drag-region class="flex shrink-0 ml-auto items-center">
|
||||
@@ -223,7 +220,7 @@ index d750a5f..c47484d 100644
|
||||
<div class="flex mr-3">
|
||||
<Suspense>
|
||||
<AppActionBar />
|
||||
@@ -2502,10 +2601,18 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
@@ -2502,10 +2597,18 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
class="p-4 border-0 border-b-[1px] border-[--brand-gradient-border] border-solid"
|
||||
/>
|
||||
<div v-if="news && news.length > 0" class="p-4 flex flex-col items-center">
|
||||
@@ -245,7 +242,7 @@ index d750a5f..c47484d 100644
|
||||
<NewsArticleCard
|
||||
v-for="(item, index) in news"
|
||||
:key="`news-${index}`"
|
||||
@@ -2531,6 +2638,21 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
@@ -2531,6 +2634,21 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
<I18nDebugPanel />
|
||||
<NotificationPanel :has-sidebar="sidebarVisible" />
|
||||
<PopupNotificationPanel :has-sidebar="sidebarVisible" />
|
||||
@@ -267,7 +264,7 @@ index d750a5f..c47484d 100644
|
||||
<ErrorModal ref="errorModal" />
|
||||
<MinecraftAuthErrorModal ref="minecraftAuthErrorModal" />
|
||||
<MinecraftRequiredModal ref="minecraftRequiredModal" />
|
||||
@@ -2743,6 +2865,38 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
@@ -2743,6 +2861,38 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
display: contents;
|
||||
}
|
||||
|
||||
@@ -306,6 +303,42 @@ index d750a5f..c47484d 100644
|
||||
@media (prefers-reduced-motion: no-preference) {
|
||||
.nav-button-animated-enter-active {
|
||||
transition: all 0.5s cubic-bezier(0.15, 1.4, 0.64, 0.96);
|
||||
diff --git a/apps/app-frontend/src/components/ui/settings/display/BehaviorSettings.vue b/apps/app-frontend/src/components/ui/settings/display/BehaviorSettings.vue
|
||||
index 55622d7..6c6ba20 100644
|
||||
--- a/apps/app-frontend/src/components/ui/settings/display/BehaviorSettings.vue
|
||||
+++ b/apps/app-frontend/src/components/ui/settings/display/BehaviorSettings.vue
|
||||
@@ -80,14 +80,6 @@ const messages = defineMessages({
|
||||
id: 'app.appearance-settings.default-landing-page.library',
|
||||
defaultMessage: 'Library',
|
||||
},
|
||||
- toggleSidebarTitle: {
|
||||
- id: 'app.appearance-settings.toggle-sidebar.title',
|
||||
- defaultMessage: 'Hide right sidebar',
|
||||
- },
|
||||
- toggleSidebarDescription: {
|
||||
- id: 'app.appearance-settings.toggle-sidebar.description',
|
||||
- defaultMessage: 'Hide the right sidebar by default and add a button to show or hide it.',
|
||||
- },
|
||||
compactModeTitle: {
|
||||
id: 'app.appearance-settings.compact-mode.title',
|
||||
defaultMessage: 'Compact mode',
|
||||
@@ -288,16 +280,6 @@ onBeforeUnmount(() => {
|
||||
</div>
|
||||
<Toggle id="minimize-launcher" v-model="current.minimizeApp" />
|
||||
</div>
|
||||
-
|
||||
- <div class="flex items-center justify-between gap-4">
|
||||
- <div>
|
||||
- <h3 class="m-0 text-lg font-semibold text-contrast">
|
||||
- {{ formatMessage(messages.toggleSidebarTitle) }}
|
||||
- </h3>
|
||||
- <p class="m-0 mt-1">{{ formatMessage(messages.toggleSidebarDescription) }}</p>
|
||||
- </div>
|
||||
- <Toggle id="toggle-sidebar" v-model="current.hideRightSidebar" />
|
||||
- </div>
|
||||
</div>
|
||||
</section>
|
||||
|
||||
diff --git a/apps/app-frontend/src/components/ui/settings/display/FeaturesSettings.vue b/apps/app-frontend/src/components/ui/settings/display/FeaturesSettings.vue
|
||||
index 1d3e379..ae88550 100644
|
||||
--- a/apps/app-frontend/src/components/ui/settings/display/FeaturesSettings.vue
|
||||
|
||||
@@ -11,10 +11,10 @@ Subject: [PATCH] Round the window corners on Linux
|
||||
4 files changed, 53 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/apps/app-frontend/src/App.vue b/apps/app-frontend/src/App.vue
|
||||
index c47484d..556ef25 100644
|
||||
index 76da736..dcae1f1 100644
|
||||
--- a/apps/app-frontend/src/App.vue
|
||||
+++ b/apps/app-frontend/src/App.vue
|
||||
@@ -547,6 +547,16 @@ watch([os, isFullscreen], ([osName, fullscreen]) => {
|
||||
@@ -543,6 +543,16 @@ watch([os, isFullscreen], ([osName, fullscreen]) => {
|
||||
document.documentElement.classList.toggle('mac-traffic-lights', osName === 'MacOS' && !fullscreen)
|
||||
})
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@ Subject: [PATCH] Scroll with the middle mouse button
|
||||
create mode 100644 apps/app-frontend/src/helpers/autoscroll.ts
|
||||
|
||||
diff --git a/apps/app-frontend/src/App.vue b/apps/app-frontend/src/App.vue
|
||||
index 556ef25..0ffddff 100644
|
||||
index dcae1f1..e18904b 100644
|
||||
--- a/apps/app-frontend/src/App.vue
|
||||
+++ b/apps/app-frontend/src/App.vue
|
||||
@@ -126,6 +126,7 @@ import {
|
||||
@@ -22,7 +22,7 @@ index 556ef25..0ffddff 100644
|
||||
import { get_user, get_user_many, get_version } from '@/helpers/cache.js'
|
||||
import { gameSettingsQueryOptions } from '@/helpers/game-options'
|
||||
import { install_create_modpack_instance, install_get_modpack_preview } from '@/helpers/install'
|
||||
@@ -607,11 +608,18 @@ onMounted(async () => {
|
||||
@@ -603,11 +604,18 @@ onMounted(async () => {
|
||||
document.querySelector('body').addEventListener('auxclick', handleAuxClick)
|
||||
document.querySelector('body').addEventListener('contextmenu', handleContextMenu)
|
||||
document.addEventListener('fullscreenchange', handleFullscreenChange)
|
||||
|
||||
@@ -22,7 +22,7 @@ menu closing.
|
||||
create mode 100644 apps/app-frontend/src/components/ui/TitleBarAccountSwitcher.vue
|
||||
|
||||
diff --git a/apps/app-frontend/src/App.vue b/apps/app-frontend/src/App.vue
|
||||
index 0ffddff..5cbe7d8 100644
|
||||
index e18904b..4d95408 100644
|
||||
--- a/apps/app-frontend/src/App.vue
|
||||
+++ b/apps/app-frontend/src/App.vue
|
||||
@@ -79,6 +79,7 @@ import { computed, nextTick, onMounted, onUnmounted, provide, ref, watch } from
|
||||
@@ -33,7 +33,7 @@ index 0ffddff..5cbe7d8 100644
|
||||
import AppActionBar from '@/components/ui/AppActionBar.vue'
|
||||
import Breadcrumbs from '@/components/ui/Breadcrumbs.vue'
|
||||
import ErrorModal from '@/components/ui/ErrorModal.vue'
|
||||
@@ -2509,6 +2510,13 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
@@ -2505,6 +2506,13 @@ provideAppUpdateDownloadProgress(appUpdateDownload)
|
||||
<AppActionBar />
|
||||
</Suspense>
|
||||
</div>
|
||||
|
||||
@@ -19,10 +19,10 @@ get a notice with a button to the release on GitHub.
|
||||
3 files changed, 76 insertions(+), 21 deletions(-)
|
||||
|
||||
diff --git a/apps/app-frontend/src/App.vue b/apps/app-frontend/src/App.vue
|
||||
index 5cbe7d8..dfdcdb1 100644
|
||||
index 4d95408..6539d4a 100644
|
||||
--- a/apps/app-frontend/src/App.vue
|
||||
+++ b/apps/app-frontend/src/App.vue
|
||||
@@ -1888,9 +1888,13 @@ const updatePopupMessages = defineMessages({
|
||||
@@ -1884,9 +1884,13 @@ const updatePopupMessages = defineMessages({
|
||||
defaultMessage: `Modrinth App v{version} has finished downloading. Reload to update now, or automatically when you close Modrinth App.`,
|
||||
},
|
||||
linuxBody: {
|
||||
@@ -38,7 +38,7 @@ index 5cbe7d8..dfdcdb1 100644
|
||||
},
|
||||
reload: {
|
||||
id: 'app.update-popup.reload',
|
||||
@@ -2065,28 +2069,47 @@ async function checkUpdates() {
|
||||
@@ -2061,28 +2065,47 @@ async function checkUpdates() {
|
||||
)
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user