PageLinks
PageLinksReading sequence Previous and next navigation for a reading sequence, with explicit destinations or SSG-derived neighbors.
Site navigation & servicesA guided reading sequence
Each link has a directional relationship and an accessible label.
Both directions, one direction, and missing destinations. Open the source tab to adapt the composition.
<PageLinks :context="{previous:{title:'Grid',url:'/components/layout/grid/'},next:{title:'Panel',url:'/components/layout/panel/'}}"/> One available direction
An incomplete link object is ignored. Supplying an empty object suppresses the inherited neighbor for this example.
<PageLinks :context="{previous:{},next:{title:'Explore the library',url:'/components/'}}"/> Every available direction
Both directions Previous only Next only Neither direction No navigation is rendered when both destinations are incomplete.
Explicit links must have both a title and URL. Missing links leave their grid cell empty; neither direction renders no navigation.
Feature map
| Feature | Where to explore it |
|---|---|
| Both directions, one direction, and missing destinations | Context preview, feature comparisons, and original copyable source examples. |
| Native semantics and integration | Behavior notes and API contracts below explain the component’s roots, slots, and runtime dependencies. |
This component has no semantic-tone, component-variant, or variant-mode props. Its own content and styling API is shown above.
Behavior and accessibility
Only links with both title and url render. Omitted props fall back to the page navigation context. Both directions missing removes the whole component. The root is a nav labelled Adjacent pages.
API reference
PageLinks contract
Props below are the public template API. RefOrValue accepts a literal or a reactive ref; bind refs with a colon-prefixed attribute. Native attributes and events can be passed through the component root.
previous
PageNavigationLink - Default
context.navigation.pageLinks.previous
Previous page object with title and url. An explicit object takes precedence over context.
next
PageNavigationLink - Default
context.navigation.pageLinks.next
Next page object with title and url. An explicit object takes precedence over context.
Composition
No slots. Register definePageLinksComponents with Grid, Flex, BtnLink and Icon. SSG context is required, even when links are explicit.