-
Notifications
You must be signed in to change notification settings - Fork 2k
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
Store Dashboard: Refactor, Update widgets to use DashboardWidget #22859
Conversation
if ( ! orders.length ) { | ||
return null; | ||
} | ||
const currencyValue = ( currency && currency.value ) || ''; | ||
const orderCountPhrase = translate( '✨ New order', '✨ New orders', { |
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.
Hi! I've found a possible matching string that has already been translated 18 times:
translate( 'New Order' )
ES Score: 10
See 1 additional suggestion in the PR translation status page
Help me improve these suggestions: react with 👎 if the suggestion doesn't make any sense, or with 👍 if it's a particularly good one (even if not implemented).
I also noticed in working on this that |
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.
First of all, 😮 🙇 , this is awesome. Code is looking great, and this is testing out quite well for me. I did notice some z-index funk in mobile viewports on the <
arrow in the nav, but it is present in production too, so I'll make a new issue for that.
I highlighted a couple of minor differences I noted in my screen grabs, but overall I think this is looking much better than what we currently have in production, especially on mobile. I will like @jameskoster and @kellychoffman give it the final 👍 from the design side, but i'm giving it the pre-approval for code.
@@ -84,45 +83,60 @@ class ManageOrdersView extends Component { | |||
} | |||
}; | |||
|
|||
shouldShowPendingReviews = () => { |
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 this is live and likely won't be turned off, we could just remove this logic now that you are updating this component. Thought it could also be done in a follow-up PR that removes the config settings too.
<span className="dashboard__process-orders-value"> | ||
{ formatCurrency( ordersRevenue, currencyValue ) || ordersRevenue } | ||
</span> | ||
<span className="dashboard__process-orders-label">{ translate( '💰 Revenue' ) }</span> |
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.
translate
calls with emoji 🤣
@@ -0,0 +1,36 @@ | |||
DashboardWidget |
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.
Thanks for adding in this README 🙌
I don't know the history of that widget, but if it is not in use I'd say we just remove the files. |
Thanks for grabbing those screenshots :)
Funny enough, fixing that is how I started this PR: #22541 |
I think some of the widgets need a little design love. I'll try to get to that this week. |
d9b831f
to
94cc371
Compare
@jameskoster I'm going to merge this so it doesn't sit longer, but I'll be around to help out with any design PRs 🙂 |
This PR has a lot of turnover, but it boils down to three basic changes:
DashboardWidget
&DashboardWidgetRow
setup-*
files into asetup/
folder, to makeapp/dashboard
a little easier to scanI also moved the
DashboardWidgetRow
component & CSS into thedashboard-widget
folder, and deleted the now-unusedBasicWidget
&WidgetGroup
components.There are some minor visual changes with the switch to the standardized
DashboardWidget
:To test
/store/:site