Skip to content

Fix ITocGeneratorService resolution in tiered Docs applications#25799

Open
maliming wants to merge 1 commit into
rel-10.6from
maliming/fix-docs-toc-layered
Open

Fix ITocGeneratorService resolution in tiered Docs applications#25799
maliming wants to merge 1 commit into
rel-10.6from
maliming/fix-docs-toc-layered

Conversation

@maliming

Copy link
Copy Markdown
Member

Move the Docs TableOfContents presentation helper back to the Web layer so ITocGeneratorService resolves in tiered applications; it is a rendering helper, not a remote application service.

Reported by @LEIRONGHUA in #25796.

ITocGeneratorService is a presentation helper for rendering, not a remote
application service, so it must be registered on the web tier.
Copilot AI review requested due to automatic review settings July 11, 2026 04:15
@maliming maliming added this to the 10.6-final milestone Jul 11, 2026
@maliming maliming changed the base branch from rel-10.5 to rel-10.6 July 11, 2026 04:17

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses DI resolution issues for ITocGeneratorService in tiered/layered Docs applications by relocating the Table of Contents (TOC) generation helper into the Web layer and ensuring it’s no longer treated as a remote application service.

Changes:

  • Added TOC model types (TocHeading, TocItem) and a Web-layer TocGeneratorService implementation.
  • Updated ITocGeneratorService to no longer inherit from IApplicationService (so it’s not considered a remote app service).
  • Updated Volo.Docs.Application.abppkg.analyze.json to remove the TOC generator from the Application module’s analyzed “applicationService” contents.

Reviewed changes

Copilot reviewed 2 out of 4 changed files in this pull request and generated no comments.

File Description
modules/docs/src/Volo.Docs.Web/TableOfContents/TocHeading.cs Introduces TOC heading/tree model types used by the Web UI.
modules/docs/src/Volo.Docs.Web/TableOfContents/TocGeneratorService.cs Adds a Web-layer TOC generation service based on Markdig parsing.
modules/docs/src/Volo.Docs.Web/TableOfContents/ITocGeneratorService.cs Removes IApplicationService inheritance so the TOC helper is not treated as a remote service.
modules/docs/src/Volo.Docs.Application/Volo.Docs.Application.abppkg.analyze.json Removes TOC generator service metadata from Application module analysis output.

@codecov

codecov Bot commented Jul 12, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 49.36%. Comparing base (cafda7a) to head (4fb0403).
⚠️ Report is 21 commits behind head on rel-10.6.

Additional details and impacted files
@@             Coverage Diff              @@
##           rel-10.6   #25799      +/-   ##
============================================
+ Coverage     49.06%   49.36%   +0.30%     
============================================
  Files          3738     3687      -51     
  Lines        126821   124434    -2387     
  Branches       9753     9508     -245     
============================================
- Hits          62223    61430     -793     
+ Misses        62728    61151    -1577     
+ Partials       1870     1853      -17     

☔ View full report in Codecov by Harness.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@maliming maliming requested a review from EngincanV July 13, 2026 00:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants