Skip to content

Add search param in getWPThemesPage method and migrate endpoint to v2.0 #834

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 20 commits into from
Mar 28, 2025

Conversation

pmusolino
Copy link
Contributor

@pmusolino pmusolino commented Mar 18, 2025

Description

This PR can be tested through wordpress-mobile/WordPress-iOS#24262

WordPressKit.zip

This is part of the work needed to fix this issue: wordpress-mobile/WordPress-iOS#23153

In WPiOS, the theme search was not functioning correctly because the search was conducted locally. As a result, since it also supports pagination, the search only considered the elements that had been fetched. If some elements were beyond the already downloaded data, they were not displayed.

In this PR, I migrated the endpoint rest/v1.2/themes to v2.0, as v1.2 has been deprecated. I also introduced the search parameter, which allows users to search for themes by keyword. Please refer to the linear issue for more details CMM-55/cannot-find-seedlet-theme.


  • Please check here if your pull request includes additional test coverage.
  • I have considered if this change warrants release notes and have added them to the appropriate section in the CHANGELOG.md if necessary.

@dangermattic
Copy link
Collaborator

1 Warning
⚠️ Package.swift was changed without updating its corresponding Package.resolved. Please resolve the Swift packages in Xcode.

Generated by 🚫 Danger

@pmusolino pmusolino added the enhancement New feature or request label Mar 19, 2025
@pmusolino pmusolino requested review from kean and crazytonyli March 19, 2025 14:04
@pmusolino pmusolino marked this pull request as ready for review March 19, 2025 14:04
@pmusolino pmusolino changed the title Add search param in getWPThemesPage method Add search param in getWPThemesPage method and migrate endpoint to v2.0 Mar 19, 2025
@pmusolino pmusolino marked this pull request as draft March 19, 2025 14:13
@kean
Copy link
Contributor

kean commented Mar 19, 2025

LGTM – the changes to the package file look good. I will approve it once there is a respective PR in WordPress-iOS with these changes where they could be tested.

@pmusolino
Copy link
Contributor Author

Opened the respective PR in WordPress-iOS repo wordpress-mobile/WordPress-iOS#24262

Copy link
Contributor

@kean kean left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks good. Please feel free to incorporating it in wpios-edition, but make sure to pull the changes first so your binary have all changes from both wpios-edition and your branch.

@pmusolino pmusolino merged commit 7dc4ed3 into wpios-edition Mar 28, 2025
10 checks passed
@pmusolino pmusolino deleted the add-search-param-in-theme-service-remote branch March 28, 2025 14:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants