Page MenuHomePhabricator

[Bug] Article cells are backwards for RTL languages
Closed, ResolvedPublic


Steps to reproduce

  1. Switch device language to Hebrew
  2. Install the app with Hebrew wikipedia as your only language
  3. Open the app, tap the search icon
  4. Enter text, tap search
  5. Verify cell layout direction
  6. Tap an article
  7. Tap search, tap clear
  8. Verify recent search layout direction

Expected result
Article cells and recent search cells are right aligned

Actual result
Article cells and recent search cells are left aligned

Recent search alignment will match device language (for example, even if you search enwiki using the english keyboard, the recent search entry will be right aligned if your system language is hebrew)
Search result alignment should match article language (left aligned for enwiki, right aligned for hewiki)

Event Timeline

cmadeo created this task.Oct 3 2017, 11:54 PM
Restricted Application added a project: Wikipedia-iOS-App-Backlog. · View Herald TranscriptOct 3 2017, 11:54 PM
Restricted Application added a subscriber: Aklapper. · View Herald Transcript
cmadeo closed this task as Invalid.Oct 3 2017, 11:56 PM

I had the English keyboard up, this works fine with the Arabic keyboard!

JoeWalsh reopened this task as Open.EditedOct 4 2017, 11:35 AM
JoeWalsh claimed this task.
JoeWalsh added a subscriber: JoeWalsh.

The text field is fine, but the cells are backwards. Re-opening this bug to fix that issue (since the screenshot already illustrates the problem)

JoeWalsh renamed this task from [Bug] Text appearing from wrong side in RTL languages in search field to [Bug] Article cells are backwards for RTL languages.Oct 4 2017, 11:37 AM
JoeWalsh updated the task description. (Show Details)

Expected behavior:

JoeWalsh updated the task description. (Show Details)Oct 4 2017, 11:41 AM
cmadeo added a comment.Oct 4 2017, 4:18 PM

@JoeWalsh thanks for re-opening this! Can't believe I missed the backwards cells!

ABorbaWMF added a subscriber: ABorbaWMF.

Works on iPhone X on Beta 5.7.1 (1244)

Looks to me. I was wondering if the same logic should apply the search view and list view in places? The images/icons on those views are currently on the right. @cmadeo, What do you think?

@ABorbaWMF, good catch! @JoeWalsh how hard would it be to have this logic apply to the list view in Places?

JMinor added a subscriber: JMinor.

Moving to 5.7.1 to discuss Places.

JMinor triaged this task as Low priority.Oct 30 2017, 9:59 PM

The issue I'm seeing with places is that when there's a device language/wiki language mismatch, the cells always respect the device language. For example, the cells are RTL for Hebrew Wikipedia on a Hebrew device, but LTR for Hebrew Wikipedia on an English device.

I tried setting the cells' semanticContentAttribute but the problem persisted. Might be a more involved workaround.

LGoto closed this task as Resolved.Mar 26 2019, 9:31 PM