Repository navigation
Render TypeScript API parameter descriptions - #2009
Merged
Merged
Conversation
TsMemberCard dropped each parameter's description when mapping the TS API data into MemberCardBase, so TypeScript function and method pages showed parameter names and types without their docs (e.g. the FluentUI icon hint on withIconName, #1287). Co-authored-by: Copilot <[email protected]>
Contributor
Frontend HTML artifact readyThe latest frontend build uploaded the This comment updates automatically when a new frontend build artifact is uploaded. |
David Fowler (davidfowl)
marked this pull request as ready for review
October 31, 2026 12:23
David Fowler (davidfowl)
requested a review
from David Pine (IEvangelist)
as a code owner
October 31, 2026 12:23
Contributor
There was a problem hiding this comment.
🟢 Approval recommended
No active review issues were identified for the change restoring TypeScript API parameter descriptions.
No open issues 🎉
What changed in this PR
Restores parameter descriptions in the TypeScript API reference by passing existing API data to the shared member-card renderer. This addresses the missing FluentUI icon hint from #1287 without changing generated data or links.
Changes:
- Pass parameter descriptions through
TsMemberCard. - Add unit coverage for parameters with and without descriptions.
- Add an end-to-end check that the
withIconNamepage displays the FluentUI hint.
| File | Description |
|---|---|
src/frontend/tests/unit/api-reference-components.vitest.test.ts |
Tests description rendering and omission when absent. |
src/frontend/tests/e2e/api-reference-ts-parameters.spec.ts |
Checks the FluentUI parameter description is visible on the API page. |
src/frontend/src/components/api-reference/TsMemberCard.astro |
Forwards parameter descriptions to the shared renderer. |
Review effort: Balanced
David Pine (IEvangelist)
enabled auto-merge (squash)
November 1, 2026 14:49
David Pine (IEvangelist)
approved these changes
Nov 1, 2026
David Pine (IEvangelist)
pushed a commit
that referenced
this pull request
Nov 1, 2026
…2010) ## Summary Related to #1287 (part 2: the broken Fluent UI icons link). Part 1 is handled by #2009, which leaves this link unchanged. The "Fluent UI: Icons catalog" link on **Custom HTTP commands** (English and Japanese) pointed to `https://storybooks.fluentui.dev/react/?path=/docs/icons-catalog--docs`. That story no longer exists. microsoft/fluentui#35991 (merged 2026-04-15) deleted `apps/public-docsite-v9/src/Icons/IconsCatalog.mdx` and the other local Icons stories. The React storybook now pulls in the icons docsite as a composed Storybook ref, so the old `icons-catalog--docs` deep link doesn't resolve. The catalog now lives in the `microsoft/fluentui-system-icons` docsite, defined by `packages/docsite/stories/Icons/IconsCatalog.mdx` with `<Meta title="Icons/Catalog" />`, which gives story ID `icons-catalog--docs`. That docsite is deployed to `https://microsoft.github.io/fluentui-system-icons/`; its latest GitHub Pages deployment (commit 883bef1, 2026-10-09) succeeded and contains that file. This PR changes the link to: `https://microsoft.github.io/fluentui-system-icons/?path=/docs/icons-catalog--docs` It also adds `tests/unit/fluentui-icon-links.vitest.test.ts`, which: - fails if any docs page links to the removed `storybooks.fluentui.dev/react/?path=/(docs|story)/icons-*` stories, and - checks that both `http-commands` pages link to the new catalog. ## Third-party links and affiliations Changed: `https://storybooks.fluentui.dev/react/?path=/docs/icons-catalog--docs` → `https://microsoft.github.io/fluentui-system-icons/?path=/docs/icons-catalog--docs` (Microsoft's Fluent UI System Icons docsite). No affiliation beyond Microsoft. ## Validation - New regression test: **3 of 3 failed before the fix** (both pages listed as offenders and missing the new URL), **3 of 3 pass after**. - `bun run test:unit`: 85 files, 1123 passed, 1 skipped. - `bun run lint`: passes. Prettier passes on the new test file. The two MDX pages already show Prettier warnings on `main`, unrelated to this one-line change. - Rendered-page check: with Playwright against the local dev server, `/fundamentals/http-commands/` and `/ja/fundamentals/http-commands/` each render exactly one icons-catalog link. Before the fix its href was the old storybook URL; after the fix it's the new catalog URL. No before/after screenshots, because the visible text is identical and only the href changes. - Limitation: my environment blocks outbound requests to `storybooks.fluentui.dev` and `microsoft.github.io`, so I couldn't load either URL live. The evidence above comes from the upstream source, the upstream PR and the Pages deployment record. A reviewer can confirm by clicking the new link. **🤖 Posted by AspireAgent (AI Agent)** Co-authored-by: davidfowl <[email protected]> Co-authored-by: Copilot <[email protected]>
David Pine (IEvangelist)
deleted the
aspireagent/ts-param-descriptions
branch
November 1, 2026 14:50
Sébastien Ros (sebastienros)
added a commit
that referenced
this pull request
Nov 11, 2026
- TypeScript API parameter descriptions (#2009) - No locale prefix or hreflang alternates for English-only pages: the footer language picker (#1988), hreflang (#1987) and the sidebar Glossary link (#1989) - Footer link to the Aspire MIT license - Homepage: environment fade (#1993), stale AppHost animations (#1950), the dashboard carousel keeps the selected slide on activation - Search: first-result highlight with out-of-order renders (#2007), hover cursor flicker (#1977) - Live status over WebSocket (#1942) and twoslash hover, merged into the copies of the frontend scripts - Icon data 5.40.0 and the regenerated sprite - src/frontend now uses Bun: README and script usage updated
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.
Summary
Fixes #1287, part 1: the TypeScript API reference never showed parameter descriptions, so the TS
withIconNamepage lacked the FluentUI icon hint that the C# page has.Root cause:
TsMemberCard.astromaps each TS parameter intoMemberCardBase'sParamshape but copied onlyname,type,isOptionalanddefaultValue.MemberCardBasealready rendersp.descriptionas.mc-param-desc, but it never received one. This affects every TS function and method page that usesTsMemberCard:[module]/[item]function pages and[module]/[item]/[member]method pages.The data already includes the text. In
src/data/ts-modules/Aspire.Hosting.13.6.0.json,withIconName.parameters[0].descriptionis "The name of the FluentUI icon to use. See https://aka.ms/fluentui-system-icons for available icons."Fix: pass
description: p.descriptionthrough. This is a one-line change.On part 2 of #1287 (the broken storybook link): the current generated data no longer contains
storybooks.fluentui.devand useshttps://aka.ms/fluentui-system-iconsinstead. That text comes from upstream XML docs, so this PR doesn't change it.Before / after
/reference/api/typescript/aspire.hosting/withiconname/at 1440×900, Playwright Chromium,astro dev:Before (main f05f556): parameters show only name and type.
After (this PR): each parameter shows its description, including the FluentUI hint.
Third-party links and affiliations
None. The aka.ms FluentUI link appears only because it already exists in the generated API data; this PR doesn't add it.
Validation
Unit (regression): new
TypeScript member cards render parameter descriptionstest intests/unit/api-reference-components.vitest.test.ts. It fails without the fix (× ... 83ms, 1 failed) and passes with it (2/2).E2E (regression): new
tests/e2e/api-reference-ts-parameters.spec.tsasserts that theiconNameparameter on the TSwithIconNamepage shows a visible.mc-param-descwith the FluentUI text.astro dev: fails with.mc-param-descelement(s) not found. The parameter row itself is found.--repeat-each=3 --retries=0.eslint --max-warnings=0is clean on the changed TS files. No local production build was run, per repo guidance; CI builds and runs the full E2E suite.CI on exact head
a98172ac(run 41198748955): all checks green. The E2E shards passed 250/246/210/248/243/208 with 0 flaky and 0 failed. The new spec passed on desktop-chromium, tablet-chromium and mobile-chromium.🤖 Posted by AspireAgent (AI Agent)