From 1c7a014c7bc2a9198c35f5824ee47bc241ccb687 Mon Sep 17 00:00:00 2001
From: 135e2 <135e2@135e2.tk>
Date: Tue, 9 Aug 2022 02:21:17 +0800
Subject: revert: Revert "feat(SettingsPage): add backgroundImage
customization"
This reverts commit ffd55641317ebd6344e92eb8a3204981846b5e05.
---
src/App.vue | 6 +-----
src/components/SettingsPage.vue | 35 ++---------------------------------
2 files changed, 3 insertions(+), 38 deletions(-)
diff --git a/src/App.vue b/src/App.vue
index 366aeea..1beefd2 100644
--- a/src/App.vue
+++ b/src/App.vue
@@ -54,7 +54,6 @@
v-else-if="atSettings"
@update-title-size="updateTitleSize"
@update-content-size="updateContentSize"
- @update-background-image-url="updateBackgroundImageURL"
:realTitleSize="parseInt(titleSize)"
:realContentSize="contentSize"
/>
@@ -94,7 +93,7 @@ export default {
snackbarText: "Default snackbar text (End-user shouldn't see this)",
bg: {
// backgroundColor: "grey",
- backgroundImage: "",
+ // backgroundImage: "url(https://wallpapercave.com/wp/wp9649930.jpg)",
backgroundPosition: "center",
},
}),
@@ -125,9 +124,6 @@ export default {
updateContentSize(s) {
this.contentSize = s;
},
- updateBackgroundImageURL(s) {
- this.bg.backgroundImage = s ? `url(${s})` : "";
- },
},
};
diff --git a/src/components/SettingsPage.vue b/src/components/SettingsPage.vue
index cc00f93..8dc35b1 100644
--- a/src/components/SettingsPage.vue
+++ b/src/components/SettingsPage.vue
@@ -30,17 +30,6 @@
-
-
-
-
-
@@ -51,7 +40,7 @@
Clear Output
-
+
Otonashi is a simple, easy-to-use classboard app, built by 135e2
@@ -69,7 +58,7 @@
export default {
name: "SettingsPage",
props: ["realTitleSize", "realContentSize"],
- emits: ["updateTitleSize", "updateContentSize", "updateBackgroundImageURL"],
+ emits: ["updateTitleSize", "updateContentSize"],
computed: {
currentTitle() {
@@ -77,8 +66,6 @@ export default {
case 1:
return "MainPage Settings";
case 2:
- return "Background Settings";
- case 3:
return "Developer Settings";
default:
return "About Otonashi";
@@ -95,15 +82,9 @@ export default {
contentSize(s, _) {
this.$emit("updateContentSize", s);
},
- // eslint-disable-next-line no-unused-vars
- backgroundImageURL(s, _) {
- this.$emit("updateBackgroundImageURL", s);
- this.writeToLS();
- },
},
mounted() {
- this.loadFromLS();
// Sync titleSize with realTitleSize
this.titleSize = this.realTitleSize;
// Same
@@ -111,7 +92,6 @@ export default {
},
data: () => ({
- backgroundImageURL: "",
titleSize: 35,
contentSize: "text-h5",
debugLog: "",
@@ -120,17 +100,6 @@ export default {
methods: {
// LocalStorage
- loadFromLS() {
- this.backgroundImageURL =
- JSON.parse(localStorage.getItem("BackgroundImageURL")) ||
- this.backgroundImageURL;
- },
- writeToLS() {
- localStorage.setItem(
- "backgroundImageURL",
- JSON.stringify(this.backgroundImageURL)
- );
- },
clearLS() {
localStorage.clear();
this.debugLog += "LocalStorage cleared.\n";
--
cgit v1.2.3