Make WordPress Core

Opened 11 years ago

Closed 11 years ago

#24951 closed defect (bug) (fixed)

Quick edit always adds class "alternate"

Reported by: iseulde's profile iseulde Owned by: helen's profile helen
Milestone: 3.7 Priority: normal
Severity: trivial Version: 3.6
Component: Quick/Bulk Edit Keywords: needs-patch
Focuses: ui Cc:

Description

Quick editing adds the "alternate" class to the table row, even if it didn't have that class before. This only happens after updating, not after cancelling. Causes grey table rows to turn white in the current style and white rows to turn grey in mp6.
Related forum topic: http://wordpress.org/support/topic/quick-edit-4

Attachments (1)

24951.patch (488 bytes) - added by mordauk 11 years ago.

Download all attachments as: .zip

Change History (11)

#1 @knutsp
11 years ago

  • Cc knut@… added

#2 @iseulde
11 years ago

  • Component changed from General to Quick/Bulk Edit

#3 @helen
11 years ago

  • Keywords needs-patch added
  • Milestone changed from Awaiting Review to 3.7

Confirmed.

#4 @helen
11 years ago

  • Keywords ui-focus added

#5 @mordauk
11 years ago

Looks like the single_row() method in class-wp-posts-list-table.php defaults to alternate anytime there is only one item. Since the save request only gets one row, it will always have alternate.

@mordauk
11 years ago

#6 follow-ups: @mordauk
11 years ago

  • Cc pippin@… added

Not sure this is the best way to do it, but it does fix the issue.

#7 in reply to: ↑ 6 @iseulde
11 years ago

Replying to mordauk:

Not sure this is the best way to do it, but it does fix the issue.

Works great.

#8 in reply to: ↑ 6 @hotchkissconsulting
11 years ago

Replying to mordauk:

Not sure this is the best way to do it, but it does fix the issue.

Works like a charm for me.

#9 @helen
11 years ago

Fine with a JS solution, given that quick edit requires JS.

#10 @helen
11 years ago

  • Owner set to helen
  • Resolution set to fixed
  • Status changed from new to closed

In 25039:

Make sure quick edited non-alternate list table rows don't become alternate. props mordauk. fixes #24951.

Note: See TracTickets for help on using tickets.