WordPress.org

Make WordPress Core

Opened 7 weeks ago

Closed 6 weeks ago

#49195 closed defect (bug) (fixed)

The numbering is visibly bad when it reaches 2 decimal places

Reported by: Marcio Zebedeu Owned by: audrasjb
Milestone: 5.4 Priority: normal
Severity: normal Version: 5.3
Component: Widgets Keywords: has-screenshots has-patch commit
Focuses: ui, accessibility Cc:

Description

The numbering is visibly bad when it reaches 2 decimal places in widgets.
The WP version used is 5.4 alpha

Attachments (7)

Captura de ecrã 2020-01-14, às 15.18.36.png (19.3 KB) - added by Marcio Zebedeu 7 weeks ago.
49195-1-small-input.png (18.0 KB) - added by audrasjb 6 weeks ago.
Using small text input instead of tiny one looks nice to me
49195-2-small-input-long-text.png (20.8 KB) - added by audrasjb 6 weeks ago.
Testing behavior with longer label: it works.
49195.patch (2.3 KB) - added by Marcio Zebedeu 6 weeks ago.
changed class tiny-text by small-text
49195.diff (426 bytes) - added by SergeyBiryukov 6 weeks ago.
49195.png (7.0 KB) - added by SergeyBiryukov 6 weeks ago.
Capture d’écran 2020-01-17 à 11.06.52.png (20.2 KB) - added by audrasjb 6 weeks ago.
Sergey’s patch works also in Chrome

Download all attachments as: .zip

Change History (16)

#1 @SergeyBiryukov
7 weeks ago

  • Component changed from General to Widgets

#2 @audrasjb
6 weeks ago

  • Keywords needs-patch has-screenshots added
  • Milestone changed from Awaiting Review to 5.4
  • Owner set to audrasjb
  • Status changed from new to accepted
  • Version set to 5.3

Hello @marcio-zebedeu, thanks for this ticket,

I agree we can easily fix that. Milestoning to 5.4.

@audrasjb
6 weeks ago

Using small text input instead of tiny one looks nice to me

@audrasjb
6 weeks ago

Testing behavior with longer label: it works.

#3 follow-ups: @audrasjb
6 weeks ago

I checked all default widgets, and the only ones that use tiny-text class are Recent Comments and Recent Posts.
Patch welcome.

@Marcio Zebedeu
6 weeks ago

changed class tiny-text by small-text

#4 in reply to: ↑ 3 @Marcio Zebedeu
6 weeks ago

  • Keywords has-patch added; needs-patch removed

Replying to audrasjb:

I checked all default widgets, and the only ones that use tiny-text class are Recent Comments and Recent Posts.
Patch welcome.

Thanks... patch was created

#5 in reply to: ↑ 3 @SergeyBiryukov
6 weeks ago

Replying to audrasjb:

I checked all default widgets, and the only ones that use tiny-text class are Recent Comments and Recent Posts.

Correct. Just noting that these appear to be the only instances of .tiny-text in core, it's not used anywhere else.

@SergeyBiryukov
6 weeks ago

@SergeyBiryukov
6 weeks ago

#6 @SergeyBiryukov
6 weeks ago

Since we don't generally need to display more than 99 posts or comments in these widgets, could we just remove the extra padding on the right? I think it looks better that way, see 49195.diff / 49195.png.

@audrasjb
6 weeks ago

Sergey’s patch works also in Chrome

#7 @audrasjb
6 weeks ago

  • Keywords commit added

Right. This patch is even easier and plugins may also benefits from this change, so I'd finally vote for your approach @SergeyBiryukov :-)

Tested in several browsers and it works as intended. Thanks!

#8 @Marcio Zebedeu
6 weeks ago

that's perfect @SergeyBiryukov.

#9 @SergeyBiryukov
6 weeks ago

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

In 47082:

Widgets: Remove extra padding from number inputs in Recent Posts and Recent Comments widgets.

Props marcio-zebedeu, audrasjb, SergeyBiryukov.
Fixes #49195.

Note: See TracTickets for help on using tickets.