Add versioned design profile releases

This commit is contained in:
DCCONSTRUCTIONS
2026-07-11 22:34:01 +03:00
parent 50718a33a1
commit 1f2dffc031
8 changed files with 473 additions and 17 deletions
+6
View File
@@ -11,6 +11,8 @@ const components = await parse("registry/components.json");
const candidates = await parse("registry/candidates.json");
const icons = await parse("registry/icons.json");
const pages = await parse("registry/pages.json");
const applicationManifestSchema = await parse("registry/schemas/application-manifest-v0.1.schema.json");
const designProfileSchema = await parse("registry/schemas/design-profile-v0.1.schema.json");
const failures = [];
const requireValue = (condition, message) => {
@@ -26,6 +28,10 @@ requireValue(Array.isArray(candidates.candidates) && candidates.candidates.lengt
requireValue(Array.isArray(icons.groups) && icons.groups.length >= 5, "icon registry is incomplete");
requireValue(pages.schemaVersion === "0.1.0", "page registry schemaVersion must be 0.1.0");
requireValue(Array.isArray(pages.templates) && pages.templates.length >= 1, "page registry must contain at least one template");
requireValue(registry.applicationManifestSchema === "schemas/application-manifest-v0.1.schema.json", "application manifest schema must be registered");
requireValue(registry.designProfileSchema === "schemas/design-profile-v0.1.schema.json", "design profile schema must be registered");
requireValue(applicationManifestSchema.properties?.schemaVersion?.const === "0.1.0", "application manifest schema version must be 0.1.0");
requireValue(designProfileSchema.properties?.schemaVersion?.const === "0.1.0", "design profile schema version must be 0.1.0");
const ids = components.components.map((component) => component.id);
requireValue(new Set(ids).size === ids.length, "component ids must be unique");