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

Remove favorite button block, use shared block #697

Merged
merged 1 commit into from
Jul 16, 2024

Conversation

ryelle
Copy link
Contributor

@ryelle ryelle commented Jul 2, 2024

This removes the favorite block in favor of the new shared favorite button. Unlike WordPress/wporg-theme-directory#148, I did not remove the favorite endpoints here — they're not bundled with the theme, and while I don't think they're used anywhere else, I wanted a second opinion before just pulling them out.

See WordPress/wporg-mu-plugins#617

To test

  • Use the branch here New block: Favorite button wporg-mu-plugins#635
  • Make sure to build both projects
  • View the pattern directory
  • There should be small heart icons on each pattern in the grid, with counts
  • If you are logged in, those are clickable; if not, they're just text
  • View a single pattern
  • You should see a button in the theme header with a count
  • If you are logged in, it should be are clickable; if not, it's just text
  • You should be able to click or trigger with a keyboard to favorite/unfavorite items, and the button should update with the interaction
  • Reload the page or view /favorites to ensure the favorite saved correctly

@adamwoodnz
Copy link
Contributor

Updated my local env to test this, but was initially blocked because the parent theme wasn't installed. I think we need to add it to composer.json 🙂

@colorful-tones
Copy link
Member

Updated my local env to test this, but was initially blocked because the parent theme wasn't installed. I think we need to add it to composer.json 🙂

I opened #701 to try and address this.

@ryelle ryelle merged commit eba66dc into trunk Jul 16, 2024
3 checks passed
@ryelle ryelle deleted the try/mu-plugins-favorite-button branch July 16, 2024 15:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

3 participants