§22 S6: type-driven entry noun (§22.4a) — backend source of truth + chrome
The displayed noun for an entry is a framework concept keyed on the collection's immutable type — document→"RFC", specification→"Spec", bdd→"Feature" — not deployment content. The chrome reads it from the API instead of hardcoding "RFC". - collections.ENTRY_NOUN + entry_noun(type) (unknown type → generic "RFC"). - Surfaced as entry_noun on get_collection, list_collections items, the /api/deployment directory items, and GET /api/projects/:id. - Frontend: Catalog reads entry_noun for the "+ Propose New <noun>" control; ProposeModal fetches the active collection's noun for its title + field copy. - test_s6_entry_noun_vertical.py: map + API surfacing (collection + directory). Scope note: this is §22.4a item (2) — terminology. The deeper type-module work (item 1 per-type frontmatter schemas; item 3 specification release-planning + bdd scenario/coverage surfaces) is flagged OPEN in the design doc and is handed off to a follow-up spec+slice. Backend 528 passed; frontend 30 passed + build green. Part of v0.45.0. Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -78,6 +78,11 @@ def make_router(config: Config, gitea: Gitea, bot: Bot) -> APIRouter:
|
||||
"type": collections_mod.collection_type(
|
||||
collections_mod.default_collection_id(r["id"])
|
||||
),
|
||||
"entry_noun": collections_mod.entry_noun(
|
||||
collections_mod.collection_type(
|
||||
collections_mod.default_collection_id(r["id"])
|
||||
)
|
||||
),
|
||||
"visibility": r["visibility"],
|
||||
}
|
||||
for r in rows
|
||||
@@ -221,6 +226,7 @@ def make_router(config: Config, gitea: Gitea, bot: Bot) -> APIRouter:
|
||||
"name": row["name"],
|
||||
"tagline": (dep["tagline"] if dep else "") or "",
|
||||
"type": collections_mod.collection_type(cid),
|
||||
"entry_noun": collections_mod.entry_noun(collections_mod.collection_type(cid)),
|
||||
"visibility": row["visibility"],
|
||||
"initial_state": collections_mod.collection_initial_state(cid),
|
||||
"theme": cfg.get("theme") or {},
|
||||
|
||||
Reference in New Issue
Block a user