diff --git a/database/schema/001_structures.sql b/database/schema/001_structures.sql index 68f5d92f..6414f57b 100644 --- a/database/schema/001_structures.sql +++ b/database/schema/001_structures.sql @@ -12,7 +12,7 @@ CREATE TABLE structures ( type TEXT NOT NULL, name TEXT NOT NULL UNIQUE, notation TEXT NOT NULL, - description TEXT, + description TEXT NOT NULL, nlab_link TEXT CHECK (nlab_link IS NULL OR nlab_link like 'https://%'), dual_structure_id TEXT, parent TEXT, diff --git a/database/scripts/utils/seed.types.ts b/database/scripts/utils/seed.types.ts index 173af4f6..ffb93047 100644 --- a/database/scripts/utils/seed.types.ts +++ b/database/scripts/utils/seed.types.ts @@ -49,7 +49,7 @@ export type StructureYaml = { id: string name: string notation: string - description: string | null + description: string nlab_link: string | null tags: string[] related: string[] diff --git a/src/lib/commons/types.ts b/src/lib/commons/types.ts index 8fac8bf2..6aca366c 100644 --- a/src/lib/commons/types.ts +++ b/src/lib/commons/types.ts @@ -15,7 +15,7 @@ export type StructureDisplay = { id: string name: string notation: string - description: string | null + description: string nlab_link: string | null dual_structure_id: string | null dual_structure_name: string | null @@ -77,6 +77,7 @@ export type SpecialObject = { export type SpecialMorphism = { type: string + // null when the morphisms of this type have not been determined description: string | null proof: string } diff --git a/src/pages/CategoryDetailPage.svelte b/src/pages/CategoryDetailPage.svelte index c1a98c32..b343ace3 100644 --- a/src/pages/CategoryDetailPage.svelte +++ b/src/pages/CategoryDetailPage.svelte @@ -43,13 +43,13 @@

Special morphisms

- {#if structure.description} -

{@html structure.description}

- {/if} +

{@html structure.description}