Skip to content

Commit 52dc3e9

Browse files
os-zhuangclaude
andauthored
docs(showcase): add "Live Metadata Views" example doc (ADR-0051 P1) (#1951)
A `doc` whose Markdown embeds four ```metadata fences — two state machines (task/project lifecycles), a flow at business altitude, and a permission matrix — demonstrating ADR-0051 inline metadata views. Compiles via the existing doc collector (the fence is valid CommonMark, not MDX); renders live once the objectui `element:metadata_viewer` (objectstack-ai/objectui#1774) is deployed. Verified end-to-end in the browser against this showcase backend. Co-authored-by: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
1 parent 37f6bd8 commit 52dc3e9

1 file changed

Lines changed: 64 additions & 0 deletions

File tree

Lines changed: 64 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,64 @@
1+
---
2+
title: Live Metadata Views in Docs
3+
description: Embed live, read-only views of state machines, flows, and permissions directly in the prose.
4+
---
5+
6+
# Live Metadata Views in Docs
7+
8+
Documentation is for the reader who can't — or shouldn't — open Studio: a
9+
business analyst, a project manager, an auditor. For them a running screen only
10+
ever shows *their own slice* of the system. It never shows the whole shape of a
11+
process, the full set of legal state transitions, or who can do what across an
12+
object.
13+
14+
This page embeds those **live, read-only views** straight into the prose with a
15+
` ```metadata ` fenced block. Each view is **resolved at read time** from the
16+
current metadata — change the underlying state machine and the diagram below
17+
changes with it. Nothing here is a screenshot (ADR-0051).
18+
19+
## A record lifecycle — state machine
20+
21+
A Task moves across a board. Which moves are legal is governed by the
22+
`task_status_flow` state machine on the `showcase_task` object. Here it is,
23+
rendered live from that rule:
24+
25+
```metadata
26+
type: state_machine
27+
object: showcase_task
28+
name: task_status_flow
29+
```
30+
31+
Projects have their own lifecycle, including terminal (dead-end) states:
32+
33+
```metadata
34+
type: state_machine
35+
object: showcase_project
36+
name: project_status_flow
37+
```
38+
39+
## A process — flow
40+
41+
The reassignment wizard, shown at the **business altitude** — purely technical
42+
steps (scripts, record I/O) are folded away so the reader sees the process, not
43+
the plumbing:
44+
45+
```metadata
46+
type: flow
47+
name: showcase_reassign_wizard
48+
detail: business
49+
```
50+
51+
## Who can do what — permission
52+
53+
The `showcase_contributor` permission set, as an object-access matrix:
54+
55+
```metadata
56+
type: permission
57+
name: showcase_contributor
58+
```
59+
60+
---
61+
62+
> These four views are not authored prose — they are the live metadata,
63+
> projected read-only into the document. See
64+
> [the showcase overview](./showcase_index.md) for the rest of the workspace.

0 commit comments

Comments
 (0)