mirror of
https://github.com/outline/outline.git
synced 2026-11-21 21:44:30 +03:00
* feat: section-aware unfurl previews for heading links When a link targets a specific heading (URL hash anchor), the hover preview now shows the content of that section rather than the top of the document. Adds DocumentHelper.getAnchorContent which extracts the Markdown for the section beginning at the heading matching a given anchor, spanning until the next heading of the same or higher level. The urls.unfurl endpoint passes the URL hash through to the document presenter for both internal and public share links. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0185Tt87p63vsnAC8oGSLLRs * fix: retain heading anchor in internal document unfurl url The internal-document unfurl branch never passed a url to the presenter, so the response fell back to document.url without the hash. Clicking the hover preview then navigated to the top of the document rather than the summarized section. Re-append the anchor in the presenter fallback so the unfurl points at the same heading it previews. Also supports the mention anchorId path: document mentions serialize their anchorId into the href hash, which flows through this same path. --------- Co-authored-by: Claude <noreply@anthropic.com>