-
Notifications
You must be signed in to change notification settings - Fork 10.7k
Add/35129 product mvp ces #35652
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
Add/35129 product mvp ces #35652
Conversation
Test Results SummaryCommit SHA: 61989a6
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. |
ea4b177 to
5c85b41
Compare
| import './footer.scss'; | ||
| import { WC_FOOTER_SLOT_NAME, WooFooterItem } from './utils'; | ||
|
|
||
| export const Footer: React.FC = () => { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A simple Footer component with a SlotFill, this allows us to easily fill it with the CES footer and correctly use the full width.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
💯
203b845 to
be6f3fc
Compare
|
|
||
| export const WC_FOOTER_SLOT_NAME = 'woocommerce_footer_item'; | ||
| /** | ||
| * Create a Fill for extensions to add items to the WooCommerce Admin header. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Typo here:
| * Create a Fill for extensions to add items to the WooCommerce Admin header. | |
| * Create a Fill for extensions to add items to the WooCommerce Admin footer. |
| cesShownForActions, | ||
| resolving: isLoading, | ||
| } = useSelect( ( select ) => { | ||
| const { getOption, isResolving } = select( OPTIONS_STORE_NAME ); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just a note here that isResolving will actually be false before it's true, which can cause some erratic behavior. I think it's more reliable to use hasFinishedResolution if that can serve your use case.
joelclimbsthings
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice work @louwie17 ! Made a couple minor comments.
I also noticed that the display breaks around a viewport width of ~1050px, which seems a bit fragile even if we're not putting attention towards mobile on this screen so far.
Once we do support mobile this will be additional technical debt, so perhaps it's worth trying to accommodate it here in some fashion? @jarekmorawski
Also, not at all required but I wonder if there is an argument for adding the UI layer of this component to the customer-effort-score package?
be6f3fc to
3952fbc
Compare
|
Thanks for the review @joelclimbsthings, I addressed your feedback and fixed the styling around the viewport.
Yeah potentially, given this is mostly geared towards the Product MVP, I don't think it be useful for users to re-use this, unless they wanted to gather feedback and have access to our The one potential item that probably should be moved is the Footer Slot fill, we did have to move that along with the header slot fill. Given the header hasn't moved yet, I will leave that until we move both, maybe when we implement extensibility. |
| </WooFooterItem> | ||
| ) } | ||
| { showFeedbackModal && ( | ||
| <CustomerFeedbackModal |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since I just merged the CES: Add additional question PR, we'll want to add the additional props here and double-check that it's working properly after a rebase on trunk. Here's an example.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Addressed here: 66ad4d0
joelclimbsthings
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Right on, great work @louwie17 . Everything looks good, although I recently merged a PR that will require a minor update. See this comment for details.
3952fbc to
4b5869f
Compare
Thanks @joelclimbsthings, I updated it to account for the second question. Also note that I updated the |
| customOptions && customOptions.length > 0 | ||
| ? customOptions | ||
| : [ | ||
| { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice! Thanks for updating these @louwie17
joelclimbsthings
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Also note that I updated the options text in the customer effort modal to match the questions, as from the design that looks to be new normal. Otherwise the options sounded kinda weird.
💯 Looks like that was a miss on my part. Thanks for getting that. Everything looks and works great! 🚢

All Submissions:
Changes proposed in this Pull Request:
Add's a CES bar to the footer of the Product MVP page when a user saves or publishes a product for the first time.
Closes #35129
Kapture.2022-11-21.at.11.23.33.mp4
How to test the changes in this Pull Request:
new-product-management-experiencefeature flag enabled (you can do so using the latest version of the Beta tester within the mono repo).You're using the new product editor (currently in development). How is your experience so far?and give the option to share feedbacknew_productaction and the score.new_productaction once finished.Turn it offon the notice, the notice should not show up there after, also on refresh.If you wanted to re-test you can delete the
woocommerce_ces_product_mvp_ces_actionoption.Other information:
pnpm --filter=<project> changelog add?FOR PR REVIEWER ONLY: