Page MenuHomePhabricator

Strange directionality in some renameuser logs
Closed, DuplicatePublic

Description

https://test.wikipedia.org/wiki/Special:Log/renameuser

See this entry: 05:17, 12 October 2015 Steinsplitter (talk | contribs | block) renamed user درفش کاویانی (0 edits) to Darafsh (per request)

The درفش کاویانی (0 edits) portion should say (0 edits) instead of what it is saying now.

The previous rename log entry - 15:14, 9 October 2015 K6ka (talk | contribs | block) renamed user Войтович Роман Романович (0 edits) to DigitalRebel78 (per request)
...appears to be correct. It looks like the log is having trouble with usernames that use this lettering. Even pasting them into this form creates problems. It messes up the ability to delete words and letters that surround it, as well as add things (the carrot cursor jumps randomly, it seems). I think something similar may be happening with the logs too.

Event Timeline

Oshwah created this task.Oct 12 2015, 9:37 PM
Oshwah raised the priority of this task from to Low.
Oshwah updated the task description. (Show Details)
Oshwah added a project: MediaWiki-Logging.
Oshwah added a subscriber: Oshwah.
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptOct 12 2015, 9:37 PM
Oshwah renamed this task from User Rename Log now has typos. to User Rename Log displays incorrectly when a user with foreign lettering is involved..Oct 12 2015, 9:39 PM
Oshwah set Security to None.
Oshwah removed a subscriber: Krenair.
Oshwah added a subscriber: Krenair.
Krenair renamed this task from User Rename Log displays incorrectly when a user with foreign lettering is involved. to Strange directionality in some user rights logs.Oct 12 2015, 9:39 PM
Krenair removed a subscriber: Krenair.
Krenair added a subscriber: Krenair.
Reedy added a subscriber: Reedy.Oct 12 2015, 9:40 PM

It's due to a mixed LTR/RTL languages in one string

Oshwah added a comment.EditedOct 12 2015, 9:41 PM

Sorry, editing the entry undid some things that Krenair changed. Tried to fix, but didn't fix them all.

Reedy added a comment.Oct 12 2015, 9:41 PM

This might be a WONTFIX, unless there's some way we can put dir markers in the string easily...

Oshwah added a comment.EditedOct 12 2015, 9:48 PM

I definitely agree with Krenair that this is probably due to two different LTR/RTL languages being inserted into the same string. Happened again with:

07:26, 2 October 2015 Steinsplitter (talk | contribs | block) renamed user دالبا (2 edits) to Dalba (Per :m:SRUC)

Umherirrender renamed this task from Strange directionality in some user rights logs to Strange directionality in some renameuser logs.Dec 22 2015, 8:33 PM

I think we can use Language::embedBidi() for this?

This only happens on Chrome. The parentheses auto-fixing part of the Unicode bidirectional algorithm is implemented in Firefox, but not in Chrome.

The solutions are:

  • Wait for Chrome developers to implement it
  • Isolate the username link with unicode-bidi: isolate in CSS or an HTML <bdi> tag.

Language::embedBidi() will probably work, but it uses control characters, which is less elegant than proper HTML or CSS.

The trouble with usernames is that it happens in a lot of other contexts, and this needs to be done every time. It would be nice to have a uniform solution for all usernames. Same for page titles... it's fun :)

Amire80 moved this task from Untriaged to RTL on the I18n board.Feb 27 2018, 7:34 AM