Skip to content

Pagination updates #776

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 4 commits into from
Aug 3, 2023
Merged

Pagination updates #776

merged 4 commits into from
Aug 3, 2023

Conversation

sfc-gh-jgarcia
Copy link
Contributor

@sfc-gh-jgarcia sfc-gh-jgarcia commented Aug 3, 2023

📚 Context

This PR addresses a few requests from @MathCatsAnd, namely:

  1. Moves the pagination component a little higher in the page;
  2. Allows to override the automatically generated previous and next links on a per-page basis.

🧠 Description of Changes

  • Updated style of arrowLink.module.css, helpful.module.css and psa.module.css to better fit their new locations;
  • Added a couple checks in [...slug].js to see whether there is a specific previousLink, previousTitle, nextLink and nextTitle being set at a page level, and use those instead of the automatically generated through getPreviousNextFromMenu

Before:

Untitled

After:

Screenshot 2023-08-02 at 3 15 06 PM

How to set overrides for prev/next links:

---
title: Quickstart
slug: /streamlit-community-cloud/get-started/quickstart
nextLink: /streamlit-community-cloud/get-started/workspace
nextTitle: My nice next title
-—

💥 Impact

Size:

  • Small
  • Not small

🌐 References

Contribution License Agreement

By submitting this pull request you agree that all contributions to this project are made under the Apache 2.0 license.

@sfc-gh-jgarcia sfc-gh-jgarcia marked this pull request as ready for review August 3, 2023 15:26
@sfc-gh-dmatthews sfc-gh-dmatthews merged commit fa81bc9 into main Aug 3, 2023
@sfc-gh-dmatthews sfc-gh-dmatthews deleted the pagination-updates branch August 3, 2023 15:39
@sfc-gh-dmatthews
Copy link
Contributor

Thanks @sfc-gh-jgarcia!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants