Repository navigation
Conversation
The guide line stops at each open node, so the open path through a deep schema is hard to follow. An open node now sits in an outlined box headed by its toggle, and the innermost open box gets a darker border. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
A folded toggle now has the box's margin, padding and border under a transparent border, so opening it no longer nudges the toggle sideways. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Docs preview (local build)Handbook preview: https://docs-v3-preview.elastic.dev/elastic/docs-builder/pull/4493/ |
The toggle label now interrupts the top line of its box, like a fieldset legend, instead of sitting in a header row above the contents. The row keeps one height folded or open, so the toggle stays put. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The first row's own top padding left about 20px under the top edge against 9px above the bottom edge. The gap under the top edge is now 13px and the bottom gap 12px. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The reference link still drew the old L-shaped branch, which leads nowhere now that open nodes sit in boxes. It stays above the toggle and lines up with the toggle's icon. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
Measured from the line the toggle sits on, the first row started 26px below it and the last ended 12px above the bottom edge. Both gaps are now 16px. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
The gap between a box's top edge and its first row, and between its last row and the bottom edge, grows from 16px to 20px. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
A reference link with no toggle below it sat indented as if it hung from the toggle. It now starts at the description's left edge. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
|
This kind of reminds me of what we used to do in the manually-maintained API docs (e.g. https://www.elastic.co/guide/en/elasticsearch/reference/8.15/ml-put-job.html). Which I think we eventually had a problem with where something becomes so deeply nested that you can't represent it any more (i.e. you run out of room for the boxes). So as long as there's some way of automating / controlling when you point to objects in the "Types" section instead, this is seems fine to me. |
do you have some extreme nesting example? |
Open nodes in an API schema now sit in nested outlined boxes, so the open path through a deep schema reads from the outlines.
Affects:
API referencePrompt summary: Work on elastic/docs-eng-team#1072. In deeply nested
oneOf/anyOfand object schemas, it is hard to tell which nodes are open and where you are. Prototype boxes with outlines only, in the greys the other panels use, and put the result on a draft PR for the preview.Why
An open node draws a thin guide line that ends at its last child. With five or six levels open, the lines run together and nothing marks which node you are inside.
What
Boxes replace guide lines
An open object row or union variant is outlined in
--color-grey-20, and its "hide properties" toggle is the header of that box. The guide lines and L-connectors are hidden. Each level indents by 0.25rem plus its border and padding, less than the old 1.25rem per level.Innermost open box
The deepest open box in a chain gets a darker
--color-grey-60outline. It marks where the reader is.Verify
Check on the preview
inner_hitsanddocvalue_fields: each open node is a box, the innermost has the darker outline.