store item display preferences

This commit is contained in:
Hayden 2023-01-27 14:11:09 -09:00
parent 1c845f442e
commit 1aeab60045
No known key found for this signature in database
GPG key ID: 17CF79474E257545

View file

@ -1,10 +1,13 @@
import { Ref } from "vue";
import { DaisyTheme } from "~~/lib/data/themes";
export type ViewType = "table" | "card" | "tree";
export type LocationViewPreferences = {
showDetails: boolean;
showEmpty: boolean;
editorAdvancedView: boolean;
itemDisplayView: ViewType;
theme: DaisyTheme;
};
@ -19,6 +22,7 @@ export function useViewPreferences(): Ref<LocationViewPreferences> {
showDetails: true,
showEmpty: true,
editorAdvancedView: false,
itemDisplayView: "card",
theme: "homebox",
},
{ mergeDefaults: true }