<template>
  <div class="d-flex flex-column">
        <v-switch class="mt-0" v-model="newSettings.newMeetingNotificationExpanded" @change="updateSettings(newSettings.newMeetingNotificationExpanded)" label="Always expand new meeting notification"></v-switch>
    </div>
</template>

<script>
import { mapState } from "vuex";

export default {
    data() {
        return {
            newSettings: {
                newMeetingNotificationExpanded: null,
                admin: {
                    showAllLobbiesMettings: null
                }
            }
        }
    },
    computed: {
        ...mapState(["settings"]),
    },
    methods: {
        updateSettings(setting){
            localStorage.setItem(setting, this.newSettings[setting])
            this.$store.commit('updateSettings', this.newSettings)
        }
    },
    created(){
        this.newSettings = Object.assign({}, this.settings)
    }
}
</script>

<style>

</style>