Make WordPress Core

Opened 9 years ago

Closed 9 years ago

#33881 closed defect (bug) (fixed)

Tags auto-suggest: double trailing space after tags separator

Reported by: afercia's profile afercia Owned by: afercia's profile afercia
Milestone: 4.4 Priority: normal
Severity: normal Version: 4.2
Component: Administration Keywords: has-patch commit
Focuses: ui, javascript Cc:


To reproduce, let's first check where it works correctly:

  • go in the Posts screen and Quick Edit a post
  • in the Tags textarea, type something to make the suggestions "tooltip" appear
  • click on a suggestion
  • the new Tag is inserted in the textarea followed by the default tag separator (comma) and just one space

Do the same thing in:

  • Edit a post > the Tags postbox
  • in Press This, in the Tags sidebar

here, the new tag is followed by a comma and two spaces.

Looks like suggest.js already takes care to add a trailing space, thus the trailing space in tags-box.js at line 180 maybe should be removed. Unless I'm missing something :)

Attachments (1)

33881.patch (574 bytes) - added by afercia 9 years ago.

Download all attachments as: .zip

Change History (6)

9 years ago

#1 @afercia
9 years ago

  • Keywords has-patch added

Quick patch, looks good to me.

This ticket was mentioned in Slack in #core by afercia. View the logs.

9 years ago

#3 @afercia
9 years ago

  • Keywords commit added
  • Milestone changed from Awaiting Review to 4.4
  • Owner set to afercia
  • Status changed from new to assigned

#4 @SergeyBiryukov
9 years ago

  • Version changed from 4.3 to 4.2

Good catch, the space was moved into suggest.js in [28851], but it looks like [31534] didn't account for that.

#5 @SergeyBiryukov
9 years ago

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

In 35292:

Tags: Avoid a double trailing space after tags separator in auto-suggest.

Props afercia.
Fixes #33881.

Note: See TracTickets for help on using tickets.