Make WordPress Core

Opened 10 years ago

Closed 10 years ago

#29421 closed defect (bug) (fixed)

Misleading number bubble on the Add Themes network admin screen

Reported by: johnbillion's profile johnbillion Owned by: nikolovtmw's profile nikolov.tmw
Milestone: 4.1 Priority: normal
Severity: normal Version: 3.9
Component: Themes Keywords: good-first-bug has-patch
Focuses: administration, multisite Cc:

Description

When browsing for new themes on the Network Admin -> Themes -> Add New screen, the bubble in the left hand menu which indicates the number of theme updates gets updated along with the number of results in your current search. This is confusing. In the screenshot below, it looks like I have 100 theme updates available.

https://i.imgur.com/o2ouNl2.png

Attachments (2)

theme.diff (387 bytes) - added by nikolov.tmw 10 years ago.
theme.2.diff (334 bytes) - added by mantismamita 10 years ago.

Download all attachments as: .zip

Change History (8)

#1 @celloexpressions
10 years ago

  • Component changed from Customize to Themes

#2 @SergeyBiryukov
10 years ago

  • Keywords good-first-bug added
  • Milestone changed from Awaiting Review to 4.1

The issue is the $( '.theme-count' ) selector in wp-admin/js/theme.js. It should be more specific.

@nikolov.tmw
10 years ago

#3 @nikolov.tmw
10 years ago

  • Keywords has-patch added; needs-patch removed

What do you think of the following selector: '#wpbody-content .theme-count'? We're still targeting the main content container(in case more counters are added in the future), but we're avoiding the sidebar with the admin navigation.

The patch above uses that selector and works for me with 4.0.

#4 @helen
10 years ago

  • Owner set to nikolov.tmw
  • Status changed from new to assigned

.wp-filter .theme-count is probably a better one to use - it's pretty specific to that UI context, at least right now.

#5 @mantismamita
10 years ago

changed selector to use .wp-filter

#6 @SergeyBiryukov
10 years ago

  • Resolution set to fixed
  • Status changed from assigned to closed

In 29786:

Use a more specific selector for the count displayed on Add Themes network admin screen.

props mantismamita, nikolov.tmw.
fixes #29421.

Note: See TracTickets for help on using tickets.