TS SDK reference: ParamField parameters, code-block signatures, required badges - #3103
Draft
dbrian57 wants to merge 3 commits into
Draft
Conversation
… blocks Visual restructuring of the generated TypeScript SDK reference, applied in the generation script's post-processing so it survives regeneration: - Parameters sections become Mintlify <ParamField> rows (monospace name, type chip, description) instead of floating headings with orphaned type lines. Per-parameter anchors no longer pollute the on-page TOC. - Inline-expanded and destructured object members nest inside a bordered <Expandable>, restoring the parent/child hierarchy the @inline tag flattened. TypeDoc's dotted flattening (a.b at sibling depth) is rebuilt into real nesting. - Required parameters get ParamField's `required` badge; optionality is unbadged, per OpenAPI-reference convention, and still visible as `?` in the signature. - Function-page signature blockquotes become syntax-highlighted ```ts fences, enriched with parameter types from the Parameters section (display-compacted; over-long inline object types collapse to {…}, with the full type preserved in the parameter body). - Cross-reference links a type chip can't carry are kept as a "See ..." line; `Defined in:` metadata is de-emphasized to <sub>Source: ...</sub>. All 94 regenerated pages verified rendering on mint dev. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
HiveMind Sessions2 sessions · 1h 39m · $43
View all sessions in HiveMind → Run |
Contributor
Readability impactWord-weighted Flesch-Kincaid grade change across 32 changed pages: -0.4 (easier). Lower Flesch-Kincaid grade and higher reading ease both mean easier to read. This check is informational and never blocks a PR. Human readability
AI agent comprehensionRated 0-3 (higher is easier for an agent to parse and act on).
Curated-docs baseline median FK grade by type: conceptual 10.5, procedural 8.8, reference 9.4. |
dbrian57
marked this pull request as draft
August 25, 2026 14:35
Replace the <sub>Source: ...</sub> text line with the site's existing SourceLink snippet (snippets/_includes/source-link.mdx), the compact right-floated pill styled by `.source-link` and already used across the Weave tutorials. The import is added once per page, only when a linked source line exists. Since the button floats without interrupting text flow, the _move_source_links_after_description pass (which relocated the text line below descriptions for reading order) is now obsolete and removed; links stay where TypeDoc emits them and float to the top right of their section. Source lines without a GitHub URL (members inherited from TypeScript's lib .d.ts) keep the <sub> text treatment. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
… type params Two more conversion passes extending the ParamField work: - Members of an anonymous object return type (one heading + property signature blockquote each, which Mintlify rendered as misplaced quote bars) become <ResponseField> rows — ParamField's sibling component for return payloads — with the same badge policy: always-present members get `required`, optional ones are unbadged. Sections with any member that doesn't parse cleanly are left untouched rather than half-converted. - Type Parameters sections get the same row treatment: name plus `extends ...` constraint as the type text, or a bare name row when unconstrained — fixing the degenerate "### T" heading followed by a lone `T` chip that duplicated the name. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull against #3099. Visual redesign of the generated TypeScript SDK reference pages. This adds a few stock Mintlify components (built specifically for reference docs) to the page-generation template. The result is a much cleaner look.