intial commit

This commit is contained in:
Ned Halksworth
2026-05-15 21:36:13 +01:00
commit a9a35cc751
23 changed files with 9588 additions and 0 deletions
+56
View File
@@ -0,0 +1,56 @@
export type BuiltInSize = 250 | 355 | 473;
export type RedBullEntry = {
id: string;
userId: string;
cans: number;
flavour: string;
flavourAccent: string;
sizeMl: number;
pricePerCan: number;
dateTime: string;
notes?: string;
store?: string;
sugarFree: boolean;
caffeineMgPerCan?: number;
importKey: string;
source: "manual" | "quick-add" | "excel" | "json";
createdAt?: string;
updatedAt?: string;
};
export type Flavour = {
name: string;
accent: string;
sugarFree?: boolean;
};
export type DateFilter = "all" | "today" | "week" | "month" | "custom";
export type EntryDraft = Omit<
RedBullEntry,
"id" | "userId" | "importKey" | "source" | "createdAt" | "updatedAt"
> & {
source?: RedBullEntry["source"];
};
export type Filters = {
flavour: string;
dateRange: DateFilter;
store: string;
from: string;
to: string;
};
export type ImportPreviewRow = {
rowNumber: number;
entry?: EntryDraft;
errors: string[];
duplicate: boolean;
duplicateReason?: string;
};
export type ImportPreview = {
fileName: string;
rows: ImportPreviewRow[];
};