| 
														
															@@ -7,6 +7,17 @@ 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 				<p>Use nightmode</p> 
														 | 
														
														 | 
														
															 				<p>Use nightmode</p> 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 			</label> 
														 | 
														
														 | 
														
															 			</label> 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 		</p> 
														 | 
														
														 | 
														
															 		</p> 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+		<p class="control is-expanded checkbox-control"> 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			<input 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+				type="checkbox" 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+				id="autoSkipDisliked" 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+				v-model="localAutoSkipDisliked" 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			/> 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			<label for="autoSkipDisliked"> 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+				<span></span> 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+				<p>Automatically vote to skip disliked songs</p> 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			</label> 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+		</p> 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 		<button class="button is-primary save-changes" @click="saveChanges()"> 
														 | 
														
														 | 
														
															 		<button class="button is-primary save-changes" @click="saveChanges()"> 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 			Save changes 
														 | 
														
														 | 
														
															 			Save changes 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 		</button> 
														 | 
														
														 | 
														
															 		</button> 
														 | 
													
												
											
										
											
												
													
														 | 
														
															@@ -19,25 +30,40 @@ import { mapState, mapActions } from "vuex"; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 export default { 
														 | 
														
														 | 
														
															 export default { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 	data() { 
														 | 
														
														 | 
														
															 	data() { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 		return { 
														 | 
														
														 | 
														
															 		return { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-			localNightmode: false 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			localNightmode: false, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			localAutoSkipDisliked: false 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 		}; 
														 | 
														
														 | 
														
															 		}; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 	}, 
														 | 
														
														 | 
														
															 	}, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 	computed: mapState({ 
														 | 
														
														 | 
														
															 	computed: mapState({ 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-		nightmode: state => state.user.preferences.nightmode 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+		nightmode: state => state.user.preferences.nightmode, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+		autoSkipDisliked: state => state.user.preferences.autoSkipDisliked 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 	}), 
														 | 
														
														 | 
														
															 	}), 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 	mounted() { 
														 | 
														
														 | 
														
															 	mounted() { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 		this.localNightmode = this.nightmode; 
														 | 
														
														 | 
														
															 		this.localNightmode = this.nightmode; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+		this.localAutoSkipDisliked = this.autoSkipDisliked; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 	}, 
														 | 
														
														 | 
														
															 	}, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 	methods: { 
														 | 
														
														 | 
														
															 	methods: { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 		saveChanges() { 
														 | 
														
														 | 
														
															 		saveChanges() { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 			if (this.localNightmode !== this.nightmode) 
														 | 
														
														 | 
														
															 			if (this.localNightmode !== this.nightmode) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 				this.changeNightmodeLocal(); 
														 | 
														
														 | 
														
															 				this.changeNightmodeLocal(); 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			if (this.localAutoSkipDisliked !== this.autoSkipDisliked) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+				this.changeAutoSkipDislikedLocal(); 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 		}, 
														 | 
														
														 | 
														
															 		}, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 		changeNightmodeLocal() { 
														 | 
														
														 | 
														
															 		changeNightmodeLocal() { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 			localStorage.setItem("nightmode", this.localNightmode); 
														 | 
														
														 | 
														
															 			localStorage.setItem("nightmode", this.localNightmode); 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 			this.changeNightmode(this.localNightmode); 
														 | 
														
														 | 
														
															 			this.changeNightmode(this.localNightmode); 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 		}, 
														 | 
														
														 | 
														
															 		}, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															-		...mapActions("user/preferences", ["changeNightmode"]) 
														 | 
														
														 | 
														
															 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+		changeAutoSkipDislikedLocal() { 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			localStorage.setItem( 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+				"autoSkipDisliked", 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+				this.localAutoSkipDisliked 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			); 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			this.changeAutoSkipDisliked(this.localAutoSkipDisliked); 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+		}, 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+		...mapActions("user/preferences", [ 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			"changeNightmode", 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+			"changeAutoSkipDisliked" 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 
														 | 
														
														 | 
														
															+		]) 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 	} 
														 | 
														
														 | 
														
															 	} 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 }; 
														 | 
														
														 | 
														
															 }; 
														 | 
													
												
											
												
													
														| 
														 | 
														
															 </script> 
														 | 
														
														 | 
														
															 </script> 
														 |