Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#42799 closed enhancement (wontfix)

paginate_links() - Replace CSS class 'page-numbers' with 'page-number'

Reported by: antonioeatgoat's profile antonioeatgoat Owned by:
Milestone: Priority: normal
Severity: normal Version: 5.1
Component: Themes Keywords: has-patch ui-feedback
Focuses: Cc:


Function paginate_links() uses the CSS class page-numbers on single items, page-number would be more correct. The plural name seems to indicate a wrapping container.

It's indeed the same naming expected by Twenty Seventeen:

wp_link_pages( array(
	'before'      => '<div class="page-links">' . __( 'Pages:', 'twentyseventeen' ),
	'after'       => '</div>',
	'link_before' => '<span class="page-number">',
	'link_after'  => '</span>',
) );

Attachments (1)

42799.patch (23.0 KB) - added by antonioeatgoat 5 years ago.
Replaced "page-numbers" with "page-number" everywhere, both core and themes

Download all attachments as: .zip

Change History (5)

5 years ago

Replaced "page-numbers" with "page-number" everywhere, both core and themes

#1 @antonioeatgoat
5 years ago

  • Keywords has-patch ui-feedback added

#2 @joyously
5 years ago

This would affect more themes than just the core themes.
Why change it if it's not broken?

#3 @antonioeatgoat
5 years ago

It was in naming clarity/consistency sake. However that's totally true, it will upsets other themes and maybe the result doesn't worth the trouble.

Probably it was a consideration to state on slack before open the ticket. If this is the case, I apologize.

#4 @dd32
5 years ago

  • Milestone Awaiting Review deleted
  • Resolution set to wontfix
  • Status changed from new to closed

I can't see any benefit to renaming this, other than consistency sake.

As the change affects themes, I don't see any need to change this and break a bunch of themes overnight when 5.0 is released. I'm going to close this as wontfix for that reason unfortunately.
We could add a second class here, but that just seems like duplicating it needlessly.

Note: See TracTickets for help on using tickets.