@@ -72,18 +71,6 @@ export default {
return this.user || isPublicBoard;
},
- boardStyles() {
- const backgroundImage = this.backgroundUrl
- ? `background-image: url('${this.backgroundUrl}');`
- : null;
-
- const backgroundColor = this.board?.backgroundColor
- ? `background-color: ${this.board.backgroundColor};`
- : null;
-
- return [backgroundImage, backgroundColor].join('');
- },
-
boardId() {
return this.$route.params?.id;
},
@@ -94,6 +81,10 @@ export default {
},
watch: {
+ backgroundUrl(value) {
+ if (value) this.$bus.$emit('UPDATE_WALLPAPER', value);
+ },
+
boardId(boardId) {
if (boardId) this.load();
},
@@ -121,6 +112,8 @@ export default {
destroyed() {
this.$bus.$off('LOAD_BOARD_BACKGROUND');
+ this.$bus.$emit('UPDATE_WALLPAPER', null);
+ this.$bus.$emit('UPDATE_BACKGROUND_COLOR', null);
},
methods: {
@@ -163,6 +156,8 @@ export default {
async loadBoardBackground() {
const url = this.board?.backgroundUrl;
+ if (this.board?.backgroundColor) this.$bus.$emit('UPDATE_BACKGROUND_COLOR', this.board?.backgroundColor);
+
if (url) {
this.backgroundUrl = url.includes('igdb')
? url
@@ -220,9 +215,8 @@ export default {
.board {
user-select: none;
display: flex;
- background-size: cover;
align-items: flex-start;
- height: 100%;
+ min-height: calc(100vh - 62px);
width: 100vw;
box-sizing: border-box;
overflow-x: auto;
diff --git a/src/pages/CreateBoardPage.vue b/src/pages/CreateBoardPage.vue
index 0645aaf1..5bb1f404 100644
--- a/src/pages/CreateBoardPage.vue
+++ b/src/pages/CreateBoardPage.vue
@@ -114,7 +114,6 @@ export default {
diff --git a/src/pages/SearchPage.vue b/src/pages/SearchPage.vue
index 8172d987..77dc282d 100644
--- a/src/pages/SearchPage.vue
+++ b/src/pages/SearchPage.vue
@@ -22,7 +22,7 @@
-