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(ia): audience subscriptions boilerplate #3565

Open
wants to merge 43 commits into
base: epic/ia
Choose a base branch
from

Conversation

jaredrethman
Copy link
Collaborator

@jaredrethman jaredrethman commented Nov 21, 2024

All Submissions:

Changes proposed in this Pull Request:

Add New IA for Audience > Subscription wizard.

How to test the changes in this Pull Request:

  1. Checkout and build assets git checkout origin/feat/ia-audience-subscriptions && npm run build
  2. Navigate to /wp-admin/admin.php?page=newspack-audience-subscriptions
  3. Observe Configuration tab and card load correctly.
    Screenshot 2024-12-12 at 08 57 56
  4. Navigate to "Revenue" tab. Observe Revenue tab and card load correctly.
    Screenshot 2024-12-12 at 08 59 17

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?

Base automatically changed from feat/ia-audience-donations-2 to epic/ia November 29, 2024 11:37
@jaredrethman jaredrethman changed the base branch from epic/ia to feat/epic-ia-trunk-rasacc December 11, 2024 17:07
@jaredrethman jaredrethman marked this pull request as ready for review December 12, 2024 15:45
@jaredrethman jaredrethman requested a review from a team as a code owner December 12, 2024 15:45
@jaredrethman jaredrethman added the [Status] Needs Review The issue or pull request needs to be reviewed label Dec 12, 2024
@jaredrethman
Copy link
Collaborator Author

Noting Audience / Subscriptions wizard slug change from newspack-audience-subscriptions-wizard to newspack-audience-subscriptions

Base automatically changed from feat/epic-ia-trunk-rasacc to epic/ia December 12, 2024 18:54
Copy link
Member

@miguelpeixe miguelpeixe left a comment

Choose a reason for hiding this comment

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

Tests well and code looks good!

A few comments below.

'title' => esc_html__( 'Configuration', 'newspack-plugin' ),
'header' => esc_html__( 'Manage Subscriptions settings in Woo Memberships', 'newspack-plugin' ),
'description' => esc_html__( 'You can manage the details of your subscription offerings in the Woo Memberships plugin.', 'newspack-plugin' ),
'href' => admin_url( 'admin.php?page=wc-settings&tab=memberships' ),
Copy link
Member

Choose a reason for hiding this comment

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

Is it confirmed that this is the link we want to redirect to? I don't think we change the defaults here. A better destination would be wp-admin/edit.php?post_type=wc_membership_plan

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Refactored in fefbfba

Comment on lines +77 to +84
[
'path' => '/revenue',
'title' => esc_html__( 'Revenue', 'newspack-plugin' ),
'header' => esc_html__( 'View Subscription Revenue in WooCommerce', 'newspack-plugin' ),
'description' => esc_html__( 'You can view revenue data from Donations and Subscriptions in the WooCommerce Plugin.', 'newspack-plugin' ),
'href' => admin_url( 'admin.php?page=wc-reports' ),
'btn_text' => esc_html__( 'View Subscription Revenue', 'newspack-plugin' ),
],
Copy link
Member

Choose a reason for hiding this comment

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

During the presentation, it was pointed out that we shouldn't render this tab while we don't have the link for our custom revenue report.

We can preserve the code but comment it out with a docblock stating the reason.

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

Refactored in 60a1787. PHPCS required the space between the block comments, looks little weird.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Information Architecture [Status] Needs Review The issue or pull request needs to be reviewed
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants