Browse Source

refactor: Minor sitename usage improvements

Owen Diffey 2 years ago
parent
commit
9ea6fb6f9c

+ 8 - 3
frontend/src/components/Request.vue

@@ -34,7 +34,9 @@
 			</div>
 			<div class="tab" v-show="tab === 'songs'">
 				<div class="musare-songs">
-					<label class="label"> Search for a song on Musare </label>
+					<label class="label">
+						Search for a song on {{ sitename }}
+					</label>
 					<div class="control is-grouped input-with-button">
 						<p class="control is-expanded">
 							<input
@@ -208,7 +210,8 @@ export default {
 	},
 	data() {
 		return {
-			tab: "songs"
+			tab: "songs",
+			sitename: "Musare"
 		};
 	},
 	computed: {
@@ -297,7 +300,9 @@ export default {
 			socket: "websockets/getSocket"
 		})
 	},
-	mounted() {
+	async mounted() {
+		this.sitename = await lofig.get("siteSettings.sitename");
+
 		this.showTab("songs");
 
 		this.socket.on("event:station.queue.updated", () =>

+ 7 - 3
frontend/src/components/modals/EditSong/Tabs/Songs.vue

@@ -1,6 +1,6 @@
 <template>
 	<div class="musare-songs-tab">
-		<label class="label"> Search for a song on Musare </label>
+		<label class="label"> Search for a song on {{ sitename }} </label>
 		<div class="control is-grouped input-with-button">
 			<p class="control is-expanded">
 				<input
@@ -49,7 +49,9 @@ export default {
 	},
 	mixins: [SearchMusare],
 	data() {
-		return {};
+		return {
+			sitename: "Musare"
+		};
 	},
 	computed: {
 		...mapState("modals/editSong", {
@@ -59,7 +61,9 @@ export default {
 			socket: "websockets/getSocket"
 		})
 	},
-	mounted() {
+	async mounted() {
+		this.sitename = await lofig.get("siteSettings.sitename");
+
 		this.musareSearch.query = this.song.title;
 		this.searchForMusareSongs(1, false);
 	}