-
Notifications
You must be signed in to change notification settings - Fork 144
add defaultOrder field to tablecard header #2139
Conversation
I noticed today that clicking the chevron the first time updates the query object from empty to "asc" even when it's already set to default "asc". |
This was fixed in 2ef82bc |
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.
LGTM, you'll just want to add a note to the changelog to go along with this.
Added. I'm getting a linter error after merging in master: .../wp-content/plugins/woocommerce-admin/client/dashboard/store-performance/index.js
202:5 error 'hiddenIndicators' is not defined no-undef |
Weird how that slipped through. This line
Should be |
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.
I took care of the build error here #2184. This one is ready to 🚢
@psealock Thanks :) |
Fixes #2136
This PR adds a
defaultOrder
field to the headers prototype of theTableCard
component to allow specifying whether the default sort column is initially sorted in ascending or descending order.Screenshots
Screenshot showing
query
is an empty object, headerdefaultOrder
set, chevron showing ascending:Detailed test instructions: