-
@@ -127,7 +137,7 @@ export default {
}
}
-.piped-play {
+#menu-mobile .piped-play {
animation: bump 300ms ease-in-out 500ms;
}
@media (prefers-reduced-motion) {
@@ -136,37 +146,39 @@ export default {
}
}
-.logout-button {
+#menu-mobile .logout-button {
white-space: nowrap;
}
-.button:hover {
+#menu-mobile .button:hover {
cursor: pointer;
}
-.highlight {
+#menu-mobile .highlight {
color: #abb2c6;
}
-.sidebar-link {
+#menu-mobile .sidebar-link {
gap: 14px !important;
padding: 10px 12px;
border-radius: 12px;
- transition: padding 500ms, gap 500ms;
+}
+#menu-mobile .sidebar-link.enable-animations {
+ transition: padding 400ms, gap 400ms;
}
-.sidebar-link span {
+#menu-mobile .sidebar-link span {
transition: font-size 500ms, padding 500ms;
}
-.collapse-text .sidebar-link span {
+#menu-mobile.collapse-text .sidebar-link span {
font-size: 0;
}
-.highlight:hover,
-.router-link-active {
+#menu-mobile .highlight:hover,
+#menu-mobile .router-link-active {
color: #fff;
}
-.router-link-active {
+#menu-mobile .router-link-active {
background: linear-gradient(to right, #da22ff, #9733ee);
}
diff --git a/src/components/Preferences.vue b/src/components/Preferences.vue
index 12ce50eb..cd942457 100644
--- a/src/components/Preferences.vue
+++ b/src/components/Preferences.vue
@@ -176,6 +176,16 @@
+
+
+
+
@@ -273,6 +283,7 @@ export default {
enabledCodecs: ["av1", "vp9", "avc"],
disableLBRY: false,
proxyLBRY: false,
+ disableAnimations: false,
};
},
activated() {
@@ -361,6 +372,7 @@ export default {
this.enabledCodecs = this.getPreferenceString("enabledCodecs", "av1,vp9,avc").split(",");
this.disableLBRY = this.getPreferenceBoolean("disableLBRY", false);
this.proxyLBRY = this.getPreferenceBoolean("proxyLBRY", false);
+ this.disableAnimations = this.getPreferenceBoolean("disableAnimations", false);
if (this.selectedLanguage != "en") {
try {
this.CountryMap = await import("@/utils/CountryMaps/" + this.selectedLanguage + ".json").then(
@@ -414,6 +426,7 @@ export default {
localStorage.setItem("enabledCodecs", this.enabledCodecs.join(","));
localStorage.setItem("disableLBRY", this.disableLBRY);
localStorage.setItem("proxyLBRY", this.proxyLBRY);
+ localStorage.setItem("disableAnimations", this.disableAnimations);
if (shouldReload) window.location.reload();
}
diff --git a/src/locales/en.json b/src/locales/en.json
index 69c12d6a..c6fd891f 100644
--- a/src/locales/en.json
+++ b/src/locales/en.json
@@ -74,7 +74,8 @@
"instance_name": "Instance Name",
"instance_locations": "Instance Locations",
"has_cdn": "Has CDN?",
- "ssl_score": "SSL Score"
+ "ssl_score": "SSL Score",
+ "disable_animations": "Disable animations"
},
"login": {
"username": "Username",
diff --git a/src/store.js b/src/store.js
index a24600dc..51ca7bbd 100644
--- a/src/store.js
+++ b/src/store.js
@@ -9,3 +9,13 @@ export function useIsMobile() {
return isMobile;
}
+
+const menuCollapsed = ref(false);
+export function useMenuCollapsed() {
+ return {
+ menuCollapsed,
+ toggleCollapsed: () => {
+ menuCollapsed.value = !menuCollapsed.value;
+ },
+ };
+}
From e40dbe02a7d1d4277baabf7133d6ebe29b0ac9c5 Mon Sep 17 00:00:00 2001
From: Filipe Medeiros
Date: Tue, 12 Oct 2021 18:27:52 +0100
Subject: [PATCH 08/12] fix: mobile menu
---
src/components/MenuDesktop.vue | 23 +++++------------
src/components/MenuMobile.vue | 45 ++++++++++++++--------------------
src/components/Preferences.vue | 4 +--
3 files changed, 27 insertions(+), 45 deletions(-)
diff --git a/src/components/MenuDesktop.vue b/src/components/MenuDesktop.vue
index 889c0548..4a2966c6 100644
--- a/src/components/MenuDesktop.vue
+++ b/src/components/MenuDesktop.vue
@@ -2,7 +2,7 @@
@@ -55,21 +54,13 @@
-
-