From d1b574ca19a384495b97534df402d178ca63c1d4 Mon Sep 17 00:00:00 2001 From: qowevisa Date: Sat, 30 Nov 2024 16:38:19 +0200 Subject: [PATCH] Add interfaces related to Settings part of the application --- src/lib/entities.ts | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/src/lib/entities.ts b/src/lib/entities.ts index 20a6f11..3440c60 100644 --- a/src/lib/entities.ts +++ b/src/lib/entities.ts @@ -148,6 +148,28 @@ export interface StatsTypeCurrencyChart { elements: StatsType[]; } +// {{{ Settings section + +export interface SettingsTypeFilter { + type_id: number; + filter_this: boolean; + // For UI + color: string; + comment: string; + name: string; +} + +export const SettingsTypes = { + type: "SettingsTypeFilter", +} as const; + +export type SettingsName = keyof typeof SettingsTypes; +export type SettingsType = + T extends "type" ? SettingsTypeFilter : + never; + +// }}} + export const EntityTypes = { card: "Card", type: "Type",