Skip to content

Commit

Permalink
Adjust list size only for WPBeginner plugins
Browse files Browse the repository at this point in the history
  • Loading branch information
claudiucelfilip committed Oct 22, 2024
1 parent 9e8f3a0 commit 62da370
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -29,11 +29,13 @@ const PluginsCategoryResultsPage = ( { category, siteSlug, sites } ) => {
const categoryName = categories[ category ]?.title || category;
const categoryDescription = categories[ category ]?.description;
const translate = useTranslate();
let size;

if ( category === 'wpbeginner' ) {
plugins = esPlugins;
isFetching = esIsFetching;
results = esPlugins.length;
size = results;
} else {
plugins = categoryPlugins;
isFetching = categoryIsFetching;
Expand Down Expand Up @@ -65,7 +67,7 @@ const PluginsCategoryResultsPage = ( { category, siteSlug, sites } ) => {
currentSites={ sites }
variant={ PluginsBrowserListVariant.InfiniteScroll }
extended
size={ 15 }
size={ size }
/>
<InfiniteScroll nextPageMethod={ fetchNextPage } />
</>
Expand Down

0 comments on commit 62da370

Please sign in to comment.