Skip to content

Conversation

@joelclimbsthings
Copy link
Contributor

@joelclimbsthings joelclimbsthings commented Dec 1, 2022

Changes proposed in this Pull Request:

Closes #35806 .

How to test the changes in this Pull Request:

  1. Checkout branch.

  2. Navigate to classic product editor. (Menu -> Products -> Add New)

  3. Notice that the Feedback button appears in the header above:
    image

  4. Click the feedback button.

  5. Notice that the icon color changes, and the CES modal is displayed.

  6. Open the console and enable tracks debugging with localStorage.setItem( 'debug', 'wc-admin:*' );

  7. Click "Send" on the modal, and ensure that the wcadmin_ces_feedback event is sent with the product_feedback action and correct score(s).

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 created a changelog file for each project being changed, ie pnpm --filter=<project> changelog add?

FOR PR REVIEWER ONLY:

  • I have reviewed that everything is sanitized/escaped appropriately for any SQL or XSS injection possibilities. I made sure Linting is not ignored or disabled.

@github-actions github-actions bot added focus: react admin plugin: woocommerce Issues related to the WooCommerce Core plugin. labels Dec 1, 2022
@joelclimbsthings joelclimbsthings self-assigned this Dec 1, 2022
@github-actions
Copy link
Contributor

github-actions bot commented Dec 1, 2022

Test Results Summary

Commit SHA: 017fcbb

Test 🧪Passed ✅Failed 🚨Broken 🚧Skipped ⏭️Unknown ❔Total 📊Duration ⏱️
API Tests25900202610m 57s
E2E Tests187006019315m 13s

To view the full API test report, click here.
To view the full E2E test report, click here.
To view all test reports, visit the WooCommerce Test Reports Dashboard.

@louwie17 louwie17 force-pushed the add/35300_ces_feedback_product_mvp branch from ccfe5fd to e44dc68 Compare December 2, 2022 10:32
Base automatically changed from add/35300_ces_feedback_product_mvp to trunk December 2, 2022 15:59
@joelclimbsthings joelclimbsthings force-pushed the add/35806-classic-product-feedback branch 2 times, most recently from fbbe50b to 3a11101 Compare December 2, 2022 20:42
Copy link
Contributor

@joshuatf joshuatf left a comment

Choose a reason for hiding this comment

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

Thanks for adding this in to the old experience, Joel! The CES modal is testing well for me and all tracks events work as expected 👍

I'm running into 2 issues (not sure if it's just my env):

  1. After opening the feedback modal, the "Activity Panel" and "Finish setup" buttons no longer work for me.

Screen Shot 2022-12-05 at 8 25 17 AM

  1. After opening and closing the feedback modal a couple times, the activity panel icon remains highlighted like its active even when the modal is closed.

Screen Shot 2022-12-05 at 8 18 16 AM

};

const isProductPage = () => {
const isProductScreen = () => {
Copy link
Contributor

Choose a reason for hiding this comment

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

Don't disagree or feel strongly about this change, but just curious if there are reasons to change this name to encompass more screens.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

This was an off the cuff thought to discern the MVP from the current product UI. Basically I associate the term screen a bit more with the reactified MVP, and page moreso with the current UI.

Not sure if this is just me, and something more explicit might be better. I didn't want to use the term "MVP" since that will soon be obsolete, but open to suggestions.

Copy link
Contributor

Choose a reason for hiding this comment

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

Basically I associate the term screen a bit more with the reactified MVP, and page moreso with the current UI.

I'm fine with either, though I do know we still refer to some areas as "pages." I guess we should figure out which we like and be consistent, but I'm fine with this change for now.

I didn't want to use the term "MVP" since that will soon be obsolete

Definitely agree with this. We need to name what we want it to be going forward and not something "future-y" since it won't always be.

{
action: 'new_product',
label: __(
title: __(
Copy link
Contributor

Choose a reason for hiding this comment

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

Nice 👍

@joelclimbsthings
Copy link
Contributor Author

Thanks for the review @joshuatf ! I'd actually seen that behavior, but thought I'd resolved it with my last change. Seems not.

After opening and closing the feedback modal a couple times, the activity panel icon remains highlighted like its active even when the modal is closed.

I've noticed that some of the above behavior is preexisting (such as the "preview" button the appearance task), but resolving it in all cases might require a bit more nuance on a case-by-case basis. The change I made in 84635fb I believe will result in the best behavior for this particular instance, although IMO the logic in this component is a little unintuitive and overly complex. Perhaps due to revisit in another issue.

One other way to approach this is just using the component prop (seen here), with the <Tab /> component, but that ends up being a lot more verbose for the same behavior.

All that said, I believe everything is resolved! Let me know.

joshuatf
joshuatf previously approved these changes Dec 7, 2022
Copy link
Contributor

@joshuatf joshuatf left a comment

Choose a reason for hiding this comment

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

Thanks for the changes, Joel!

This is testing really for me now. One minor quirk remaining, but pre-approving. ✅

After completing the feedback form, the tab is still active. Is that possible to update after completion?
Screen Shot 2022-12-07 at 1 22 17 PM

};

const isProductPage = () => {
const isProductScreen = () => {
Copy link
Contributor

Choose a reason for hiding this comment

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

Basically I associate the term screen a bit more with the reactified MVP, and page moreso with the current UI.

I'm fine with either, though I do know we still refer to some areas as "pages." I guess we should figure out which we like and be consistent, but I'm fine with this change for now.

I didn't want to use the term "MVP" since that will soon be obsolete

Definitely agree with this. We need to name what we want it to be going forward and not something "future-y" since it won't always be.

@joelclimbsthings
Copy link
Contributor Author

Thanks @joshuatf , looks like that handler isn't called on submission. Remedied in a4b6739.

joshuatf
joshuatf previously approved these changes Dec 13, 2022
Copy link
Contributor

@joshuatf joshuatf left a comment

Choose a reason for hiding this comment

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

Testing well! Thanks for fixing the state after feedback submission. This LGTM, but there is a conflict so feel free to ping me if you need another ✅

@joelclimbsthings joelclimbsthings force-pushed the add/35806-classic-product-feedback branch from 5ea33af to 017fcbb Compare December 15, 2022 19:19
Copy link
Contributor

@joshuatf joshuatf left a comment

Choose a reason for hiding this comment

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

Still testing well! 🚢

@joelclimbsthings joelclimbsthings merged commit 6e20f66 into trunk Dec 15, 2022
@joelclimbsthings joelclimbsthings deleted the add/35806-classic-product-feedback branch December 15, 2022 22:31
@github-actions github-actions bot added this to the 7.4.0 milestone Dec 15, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

plugin: woocommerce Issues related to the WooCommerce Core plugin.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CES: Add the feedback button to the navbar on classic product management page

3 participants