From 70e45c80d933deecf2fb336f05470aa3983cf6cd Mon Sep 17 00:00:00 2001 From: Samuel Williams Date: Sun, 16 Aug 2026 20:29:44 +1200 Subject: [PATCH] Summarize nested reference definitions --- pages/reference/show.xnode | 18 +++++++++++++----- public/_static/site.css | 31 +++++++++++++++++++++++++++++++ test/utopia/project/serve.rb | 9 +++++++++ 3 files changed, 53 insertions(+), 5 deletions(-) diff --git a/pages/reference/show.xnode b/pages/reference/show.xnode index ec71309..11c23ca 100644 --- a/pages/reference/show.xnode +++ b/pages/reference/show.xnode @@ -30,13 +30,21 @@ if nested.any? ?>
-

Nested

+

Classes and Modules

- +
div { + min-width: 0; +} + +dl.nested-definitions dt, dl.nested-definitions dd, +dl.nested-definitions dd p { + margin: 0; +} + +dl.nested-definitions dt { + font-size: 1.05em; +} + +dl.nested-definitions dt code, +dl.nested-definitions dt syntax-code { + display: block; + max-width: 100%; + white-space: pre-wrap; + overflow-wrap: anywhere; +} + +dl.nested-definitions dd { + margin-top: 0.25rem; +} + ul.index { padding: 0; list-style: none; diff --git a/test/utopia/project/serve.rb b/test/utopia/project/serve.rb index 7b70bb6..0e8419d 100644 --- a/test/utopia/project/serve.rb +++ b/test/utopia/project/serve.rb @@ -84,4 +84,13 @@ expect(body).to be(:include?, "
Inherits from
") expect(body).to be(:include?, "/reference/Utopia/Project/Document/index#Utopia%3A%3AProject%3A%3ADocument%23root") end + + it "summarizes nested definitions" do + body = client.get("/reference/Utopia/Project/index").read + + expect(body).to be(:include?, "Classes and Modules") + expect(body).to be(:include?, '
') + expect(body).to be(:include?, 'class Document') + expect(body).to be(:include?, "Represents a Markdown document with optional source code cross-references.") + end end