Automatiska ID, nya registertyper och ID-register
- Löpande ID per bok och typ enligt idöversikten (KI, FI, BI, DI, LI, UI, FD, RI, RD, SI, REI, PI, SCI, KD-R_/KD-E_), prefix samlade i src/lib/ids.ts - Nya typer: Fordon, Skiss, Research, Referens, Appar, Hemsidor (grupp Register) - Sida med ID-register med sök och filter - Migration 0003_auto_ids med backfill av befintliga poster - ID visas i listor, postsidor, kartpanel och scheman - README och Register/-mallar Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
This commit is contained in:
1 parent
0b65494cf5
commit
8a0e93f559
32 files changed
+664
-48
No files matched your search
+16
-8
@@ -4,18 +4,26 @@ export type KindInfo = {
|
||||
kind: EntityKind;
|
||||
slug: string;
|
||||
color: string;
|
||||
// world = berättelsens värld, register = stödregister (fordon, research, skisser ...)
|
||||
group: "world" | "register";
|
||||
};
|
||||
|
||||
// Ordningen styr menyer och översikt.
|
||||
export const KINDS: KindInfo[] = [
|
||||
{ kind: "CHARACTER", slug: "characters", color: "blue" },
|
||||
{ kind: "PET", slug: "pets", color: "orange" },
|
||||
{ kind: "HOME", slug: "homes", color: "green" },
|
||||
{ kind: "PLACE", slug: "places", color: "red" },
|
||||
{ kind: "COMPANY", slug: "companies", color: "purple" },
|
||||
{ kind: "PREMISES", slug: "premises", color: "teal" },
|
||||
{ kind: "EDUCATION", slug: "education", color: "cyan" },
|
||||
{ kind: "SCENARIO", slug: "scenarios", color: "pink" },
|
||||
{ kind: "CHARACTER", slug: "characters", color: "blue", group: "world" },
|
||||
{ kind: "PET", slug: "pets", color: "orange", group: "world" },
|
||||
{ kind: "HOME", slug: "homes", color: "green", group: "world" },
|
||||
{ kind: "PLACE", slug: "places", color: "red", group: "world" },
|
||||
{ kind: "COMPANY", slug: "companies", color: "purple", group: "world" },
|
||||
{ kind: "PREMISES", slug: "premises", color: "teal", group: "world" },
|
||||
{ kind: "EDUCATION", slug: "education", color: "cyan", group: "world" },
|
||||
{ kind: "SCENARIO", slug: "scenarios", color: "pink", group: "world" },
|
||||
{ kind: "VEHICLE", slug: "vehicles", color: "indigo", group: "register" },
|
||||
{ kind: "SKETCH", slug: "sketches", color: "azure", group: "register" },
|
||||
{ kind: "RESEARCH", slug: "research", color: "lime", group: "register" },
|
||||
{ kind: "REFERENCE", slug: "references", color: "yellow", group: "register" },
|
||||
{ kind: "APP", slug: "apps", color: "dark", group: "register" },
|
||||
{ kind: "WEBSITE", slug: "websites", color: "secondary", group: "register" },
|
||||
];
|
||||
|
||||
export const KIND_BY_SLUG = new Map(KINDS.map((k) => [k.slug, k]));
|
||||
|
||||
Reference in new issue
Block a user