feat(site): add section and heading anchors for deep-linking
Landing sections now carry ids (status, features, faq, collab, …) so any section is directly linkable (e.g. /#faq). About and Legal headings get a discreet, hover-revealed permalink via a goldmark heading render hook. A scroll-margin-top offset keeps anchored targets clear of the sticky header.
This commit is contained in:
parent
b0325fd40d
commit
bfd29f19b9
3 changed files with 28 additions and 8 deletions
4
site/layouts/_default/_markup/render-heading.html
Normal file
4
site/layouts/_default/_markup/render-heading.html
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
<h{{ .Level }} id="{{ .Anchor }}">
|
||||
{{ .Text | safeHTML }}
|
||||
<a class="heading-anchor" href="#{{ .Anchor }}" aria-label="Permalink">#</a>
|
||||
</h{{ .Level }}>
|
||||
Loading…
Add table
Add a link
Reference in a new issue