mirror of
https://github.com/facebook/docusaurus.git
synced 2025-05-10 15:47:23 +02:00
feat(v2): use new pagination nav CSS (#1520)
This commit is contained in:
parent
c75cec76ec
commit
b8965dcf38
3 changed files with 40 additions and 27 deletions
|
@ -15,29 +15,32 @@ function DocPaginator(props) {
|
|||
} = props;
|
||||
|
||||
return (
|
||||
<div className="row">
|
||||
<div className="col col--6">
|
||||
<nav className="pagination-nav">
|
||||
<div className="pagination-nav__item">
|
||||
{metadata.previous && docs[metadata.previous] && (
|
||||
<Link
|
||||
className="button button--secondary"
|
||||
className="pagination-nav__link"
|
||||
to={docs[metadata.previous].permalink}>
|
||||
<i className="fas fa-arrow-left" />
|
||||
|
||||
{metadata.previous_title}
|
||||
<h5 className="pagination-nav__link--sublabel">Previous</h5>
|
||||
<h4 className="pagination-nav__link--label">
|
||||
« {metadata.previous_title}
|
||||
</h4>
|
||||
</Link>
|
||||
)}
|
||||
</div>
|
||||
<div className="col col--6 text--right">
|
||||
<div className="pagination-nav__item pagination-nav__item--next">
|
||||
{metadata.next && docs[metadata.next] && (
|
||||
<Link
|
||||
className="button button--secondary"
|
||||
className="pagination-nav__link"
|
||||
to={docs[metadata.next].permalink}>
|
||||
{metadata.next_title}
|
||||
<i className="fas fa-arrow-right" />
|
||||
<h5 className="pagination-nav__link--sublabel">Next</h5>
|
||||
<h4 className="pagination-nav__link--label">
|
||||
{metadata.next_title} »
|
||||
</h4>
|
||||
</Link>
|
||||
)}
|
||||
</div>
|
||||
</div>
|
||||
</nav>
|
||||
);
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue