Files
front/stores/settingsStore.ts
T

26 lines
595 B
TypeScript

import { defineStore } from "pinia";
enum CardStyles {
HERON = "heron",
ORIGINAL = "original"
}
export const useSettingsStore = defineStore("settingstore", {
state: () => ({
cardStyle: CardStyles.HERON,
shaderQuality: 0,
shaderFramerate: 10,
shaderPixelated: false
}),
actions: {
switchCardStyles() {
if (this.cardStyle === CardStyles.HERON) {
this.cardStyle = CardStyles.ORIGINAL
} else {
this.cardStyle = CardStyles.HERON
}
}
},
persist: true
});