fix: fehlende Dateien fuer Volk-Ueberarbeitung nachreichen
labels.ts und die ColonyCondition-Migration waren untracked und fehlten im letzten Commit, dadurch schlug der Docker-Build mit "Module not found: @/lib/colonies/labels" fehl.
This commit is contained in:
1 parent
8520678a48
commit
133edcd5ba
2 files changed
+68
No files matched your search
@@ -0,0 +1,8 @@
|
|||||||
|
-- CreateEnum
|
||||||
|
CREATE TYPE "ColonyCondition" AS ENUM ('EXCELLENT', 'GOOD', 'AVERAGE', 'WEAK', 'CRITICAL');
|
||||||
|
|
||||||
|
-- AlterTable
|
||||||
|
ALTER TABLE "Colony"
|
||||||
|
ALTER COLUMN "broodStatus" TYPE "ColonyCondition" USING ("broodStatus"::"ColonyCondition"),
|
||||||
|
ALTER COLUMN "feedStatus" TYPE "ColonyCondition" USING ("feedStatus"::"ColonyCondition"),
|
||||||
|
ALTER COLUMN "healthStatus" TYPE "ColonyCondition" USING ("healthStatus"::"ColonyCondition");
|
||||||
@@ -0,0 +1,60 @@
|
|||||||
|
import { ColonyCondition, ColonyStatus, ColonyType } from "./types";
|
||||||
|
|
||||||
|
// Werte und Reihenfolge aus docs/lastenheft.md Abschnitt 4.3 ("Moegliche Volkstypen"/"Moegliche Status").
|
||||||
|
export const COLONY_TYPES: ColonyType[] = [
|
||||||
|
"PRODUCTION_COLONY",
|
||||||
|
"NUCLEUS_COLONY",
|
||||||
|
"YOUNG_COLONY",
|
||||||
|
"CARETAKER_COLONY",
|
||||||
|
"MATING_NUCLEUS",
|
||||||
|
"RESERVE_COLONY",
|
||||||
|
];
|
||||||
|
|
||||||
|
export const COLONY_TYPE_LABELS: Record<ColonyType, string> = {
|
||||||
|
PRODUCTION_COLONY: "Wirtschaftsvolk",
|
||||||
|
NUCLEUS_COLONY: "Ableger",
|
||||||
|
YOUNG_COLONY: "Jungvolk",
|
||||||
|
CARETAKER_COLONY: "Pflegevolk",
|
||||||
|
MATING_NUCLEUS: "Begattungseinheit",
|
||||||
|
RESERVE_COLONY: "Reservevolk",
|
||||||
|
};
|
||||||
|
|
||||||
|
export const COLONY_STATUS_LABELS: Record<ColonyStatus, string> = {
|
||||||
|
ACTIVE: "Aktiv",
|
||||||
|
WEAK: "Schwach",
|
||||||
|
CONSPICUOUS: "Auffällig",
|
||||||
|
QUEENLESS: "Weisellos",
|
||||||
|
DISSOLVED: "Aufgelöst",
|
||||||
|
SOLD: "Verkauft",
|
||||||
|
DECEASED: "Eingegangen",
|
||||||
|
MERGED: "Vereinigt",
|
||||||
|
};
|
||||||
|
|
||||||
|
// Gemeinsame fuenfstufige Skala fuer Brut-, Futter- und Gesundheitsstatus,
|
||||||
|
// bester bis schlechtester Zustand.
|
||||||
|
export const COLONY_CONDITIONS: ColonyCondition[] = [
|
||||||
|
"EXCELLENT",
|
||||||
|
"GOOD",
|
||||||
|
"AVERAGE",
|
||||||
|
"WEAK",
|
||||||
|
"CRITICAL",
|
||||||
|
];
|
||||||
|
|
||||||
|
export const COLONY_CONDITION_LABELS: Record<ColonyCondition, string> = {
|
||||||
|
EXCELLENT: "Sehr gut",
|
||||||
|
GOOD: "Gut",
|
||||||
|
AVERAGE: "Mittel",
|
||||||
|
WEAK: "Schwach",
|
||||||
|
CRITICAL: "Kritisch",
|
||||||
|
};
|
||||||
|
|
||||||
|
// Tailwind-Klassen auf Basis der --condition-* Tokens aus globals.css (hell/dunkel-faehig).
|
||||||
|
export const COLONY_CONDITION_TONE_CLASS: Record<ColonyCondition, string> = {
|
||||||
|
EXCELLENT: "border-transparent bg-condition-excellent/15 text-condition-excellent-foreground",
|
||||||
|
GOOD: "border-transparent bg-condition-good/15 text-condition-good-foreground",
|
||||||
|
AVERAGE: "border-transparent bg-condition-average/15 text-condition-average-foreground",
|
||||||
|
WEAK: "border-transparent bg-condition-weak/15 text-condition-weak-foreground",
|
||||||
|
CRITICAL: "border-transparent bg-condition-critical/15 text-condition-critical-foreground",
|
||||||
|
};
|
||||||
|
|
||||||
|
export const COLONY_STRENGTH_OPTIONS: number[] = Array.from({ length: 10 }, (_, index) => index + 1);
|
||||||
Reference in new issue
Block a user