Skip to content
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

Limit number of initial shown Pull Requests for cards on the Homepage #1481

Open
davidg-idealo opened this issue Jul 15, 2024 · 1 comment
Open
Labels
help wanted Extra attention is needed kind/enhancement New feature or request

Comments

@davidg-idealo
Copy link

For the HomePageRequestedReviewsCard & HomePageYourOpenPullRequestsCard are currently up to 100 Pull Requests shown. This can lead to a cluttered Homepage.

Feature Suggestion

To have a more consistent layout on the homepage I would suggest to limit the number of Pull Requests that are initially shown.
This ensures that a card does not take up a lot of height and thus destroy the structure of the homepage.

Possible Implementation

The Spotify HomePageRecentlyVisited & HomePageTopVisited plugins offer the option of configuring how many links should be displayed initially and how many should be loaded after expanding the card. I think this is a good solution to make the layout of the homepage homogeneous and to display the complete content if required.

Screenshot 2024-07-15 at 09 39 10
Screenshot 2024-07-15 at 09 39 19

Example: https://backstage.io/storybook/?path=/story/plugins-home-components-visitedbytype--recently-default

To follow the example from the Spotify Plugins the Pull Rquest Plugins could offer the following parameters:
<HomePageRequestedReviewsCard numPullRequestOpen={5} numPullRequestTotal={50}/>
These parameters can then be used for the GitHub API request: useGithubSearchPullRequest.tsx#L39

Context

This feature would ensure a consistent homepage structure. Furthermore, an OPTIONS and GET request are sent for each repository. The initial limitation also reduces the number of these requests.

@davidg-idealo davidg-idealo added the kind/enhancement New feature or request label Jul 15, 2024
Copy link
Contributor

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

@github-actions github-actions bot added the stale label Sep 13, 2024
@Xantier Xantier added help wanted Extra attention is needed and removed stale labels Sep 13, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Extra attention is needed kind/enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants