[xwiki-contrib/documentation] 468698: DA-51: The TOC should display sections coming from...
Branch: refs/heads/master Home: https://github.com/xwiki-contrib/documentation Commit: 468698b4c9f46c4ee29aeb1b11e7d5c6cf5bf606 https://github.com/xwiki-contrib/documentation/commit/468698b4c9f46c4ee29aeb... Author: Vincent Massol <[email protected]> Date: 2026-10-10 (Sat, 10 Oct 2026) Changed paths: M documentation-api/pom.xml A documentation-api/src/main/java/org/xwiki/contrib/documentation/internal/DocumentationContentDisplayer.java A documentation-api/src/main/java/org/xwiki/contrib/documentation/internal/DocumentationContentMacro.java A documentation-api/src/main/java/org/xwiki/contrib/documentation/internal/DocumentationContentMacroParameters.java A documentation-api/src/main/java/org/xwiki/contrib/documentation/internal/DocumentationFAQDisplayer.java M documentation-api/src/main/resources/META-INF/components.txt A documentation-api/src/test/java/org/xwiki/contrib/documentation/internal/DocumentationContentMacroTest.java M documentation-test/documentation-test-docker/src/test/it/org/xwiki/contrib/documentation/test/docker/DocumentationIT.java M documentation-test/documentation-test-pageobjects/src/main/java/org/xwiki/contrib/documentation/test/po/DocumentationViewPage.java M documentation-ui/src/main/resources/DocApp/Code/DocumentationSheet.xml Log Message: ----------- DA-51: The TOC should display sections coming from the main content or from the FAQ content (#53) * Add an internal `documentationContent` macro that displays the content or the FAQ of the current documentation page as blocks of the page instead of rendered HTML, so that the `toc` macro of the documentation sheet sees their headings. * Execute the content like `$services.display.content()` does (isolated execution context, with the rights of its content author) and the FAQ like `$doc.display('faq')` does (with the rights of the document author, restricted when the rendering, the document or the property is), so the macro grants no extra rights. * Make the ids of the displayed headings and images unique within the page, and display nothing when a field contains the macro displaying itself. * Use the macro in view mode in `DocApp.Code.DocumentationSheet`, keeping `$doc.display()` for edit mode. * Test the table of contents in the functional test, and give the Image macros of its fixtures a size, since the page content is now displayed in the test wiki, which doesn't have AppWithinMinutes installed. Co-authored-by: Claude Opus 5.5 (1M context) <[email protected]> To unsubscribe from these emails, change your notification settings at https://github.com/xwiki-contrib/documentation/settings/notifications
participants (1)
-
XWiki Notifications