From 33bb1ccc59e33ef92ab8e93d2ac208d6eb7dfe03 Mon Sep 17 00:00:00 2001 From: os-zhuang Date: Fri, 26 Jun 2026 16:26:52 +0800 Subject: [PATCH] docs: fix two inaccuracies found dogfooding #2338 (responsiveStyles keys, dataset include) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Browser/dogfood verification of the features documented in #2338 (booted app-showcase, exercised at runtime) confirmed $search / searchableFields and multi-hop dataset joins work as documented, but surfaced two doc inaccuracies in #2338 itself: - page.mdx: responsiveStyles breakpoint keys are `large` / `medium` / `small` / `xsmall` (desktop-first — `large` is the unconditional base, the rest are max-width overrides) per ResponsiveStylesSchema, NOT the `xs/sm/md/lg/xl/2xl` axis (those are BreakpointName, used by layout columns/visibility/order). Verified against the served showcase_styling_gallery page metadata (key: `large`). - analytics-datasets.mdx: multi-hop joins must be DECLARED in the dataset's `include` (joins are derived from include; only declared paths are joinable). Verified live: an inline dataset on showcase_invoice_line with include:['invoice.account'] + dotted-path dimension `invoice.account.industry` returns correctly-joined rows. Docs-only. Co-Authored-By: Claude Opus 4.8 --- content/docs/guides/analytics-datasets.mdx | 11 +++++++---- content/docs/guides/metadata/page.mdx | 2 +- 2 files changed, 8 insertions(+), 5 deletions(-) diff --git a/content/docs/guides/analytics-datasets.mdx b/content/docs/guides/analytics-datasets.mdx index e7208df35c..1b6ab3a7db 100644 --- a/content/docs/guides/analytics-datasets.mdx +++ b/content/docs/guides/analytics-datasets.mdx @@ -135,10 +135,13 @@ capability the inline single-object query could never reach: // → revenue by account.region, joined + RLS-enforced per object. ``` -Joins follow **dotted relationship paths** and may traverse **multiple to-one hops** -(ADR-0071) — e.g. `account.owner.region` walks the chain order → account → owner → -region. The path is capped at **3 join hops (4 objects)** and is **to-one only**; -to-many traversal is rejected (aggregate the many-side as its own measure instead). +Joins are **derived from the dataset's `include` declarations**: list the relationship +paths to join (`include: ['account', 'account.owner']`), and dimensions/measures then +reference fields along them by **dotted path** (`account.owner.region`). Only declared +paths are joinable. Paths may chain **multiple to-one hops** (ADR-0071 — declaring +`account.owner` implicitly includes `account`), are capped at **3 join hops (4 objects)**, +and are **to-one only**; to-many traversal is rejected (aggregate the many-side as its +own measure instead). ## How it runs diff --git a/content/docs/guides/metadata/page.mdx b/content/docs/guides/metadata/page.mdx index 9569551a47..138f3f365b 100644 --- a/content/docs/guides/metadata/page.mdx +++ b/content/docs/guides/metadata/page.mdx @@ -136,7 +136,7 @@ Components are the building blocks placed inside regions. | `events` | `Record` | optional | Event handlers (action expressions) | | `style` | `object` | optional | CSS styles | | `className` | `string` | optional | CSS class names | -| `responsiveStyles` | `object` | optional | **Preferred** SDUI styling channel (ADR-0065): per-breakpoint scoped CSS-property maps keyed by `xs`/`sm`/`md`/`lg`/`xl`/`2xl`, compiled to id-scoped CSS at render. Prefer design tokens, e.g. `{ base: { padding: 'var(--space-6)' }, md: { padding: 'var(--space-8)' } }`. Use over ad-hoc `style`/`className` for metadata-authored pages. | +| `responsiveStyles` | `object` | optional | **Preferred** SDUI styling channel (ADR-0065): **desktop-first** per-breakpoint scoped style maps, compiled to id-scoped CSS at render. Keys are `large` (the unconditional base), then `medium` / `small` / `xsmall` as `max-width` overrides. Prefer design tokens, e.g. `{ large: { padding: 'var(--space-8)' }, small: { padding: 'var(--space-4)' } }`. Use over ad-hoc `style` / `className` for metadata-authored pages. | | `visibility` | `string` | optional | Visibility predicate (CEL expression) | The `type` field is a union of the standard `PageComponentType` enum and any custom string. The standard (namespaced) component types include: