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

feat(media-kit): add media kit (from publisher-media-kit plugin) #894

Merged
merged 2 commits into from
Aug 30, 2024

Conversation

adekbadek
Copy link
Member

@adekbadek adekbadek commented Aug 22, 2024

All Submissions:

Changes proposed in this Pull Request:

Incorporates a Media Kit page functionality, adapted from the https://github.com/10up/publisher-media-kit/ plugin:

media-kit

How to test the changes in this Pull Request:

  1. If publisher-media-kit plugin is active, deactivate it and ensure the media kit page and pmk-page option are deleted
  2. Use the WP CLI command wp newspack-ads create-media-kit-page to create the page, observe the command outputs the created post ID
  3. Run the command again, observe it informs that the page has already been created, and outputs the post ID
  4. Observe a media kit page draft was created, edit it
  5. Observe it has the content as in the image seen above
  6. Publish the page, observe the interactive elements – the tabs in "Ad Specs" and "Our Rates" sections – are functioning properly

Other information:

  • Have you added an explanation of what your changes do and why you'd like us to include them?
  • Have you written new tests for your changes, as applicable?
  • Have you successfully ran tests with your changes locally?

@leogermani
Copy link
Contributor

It works well. I left the media-kit plugin active on purpose to see if there would be any conflict, looks ok.

If publisher-media-kit plugin is active, deactivate it and ensure the media kit page and pmk-page option are deleted

I had to manually delete the page.

Overall it looks good, my only question is that there is no way for an existing user of the plugin to start using this feature unless they deactivate and activate the plugin.

I'm not sure I have all the context, but is that ok? Don't we want to add a button somewhere to create the page?

@adekbadek
Copy link
Member Author

there is no way for an existing user of the plugin to start using this feature unless they deactivate and activate the plugin.
I'm not sure I have all the context, but is that ok? Don't we want to add a button somewhere to create the page?

That's a great remark, indeed we should not require the plugin to be re-activated. However, in our case the migration will be one by one, assisted by our team, so we have no immediate need for a UI. Instead, I've added a CLI command in 7d259fc. I've updated the testing instructions.

@leogermani leogermani merged commit 8c46acf into trunk Aug 30, 2024
7 checks passed
@leogermani leogermani deleted the feat/media-kit-page branch August 30, 2024 13:13
matticbot pushed a commit that referenced this pull request Aug 30, 2024
# [3.1.0-alpha.1](v3.0.2...v3.1.0-alpha.1) (2024-08-30)

### Features

* **media-kit:** add media kit (from publisher-media-kit plugin) ([#894](#894)) ([8c46acf](8c46acf))
@matticbot
Copy link
Contributor

🎉 This PR is included in version 3.1.0-alpha.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

matticbot pushed a commit that referenced this pull request Oct 8, 2024
# [3.1.0](v3.0.2...v3.1.0) (2024-10-08)

### Features

* **media-kit:** add media kit (from publisher-media-kit plugin) ([#894](#894)) ([8c46acf](8c46acf))
@matticbot
Copy link
Contributor

🎉 This PR is included in version 3.1.0 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@adekbadek adekbadek mentioned this pull request Oct 11, 2024
6 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants