Bug 168793 - Web Inspector: RTL: navigation sidebar text overflows on left side (per RTL context), but resource names are LTR
Summary: Web Inspector: RTL: navigation sidebar text overflows on left side (per RTL c...
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (show other bugs)
Version: WebKit Nightly Build
Hardware: All All
: P2 Normal
Assignee: BJ Burg
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2017-02-23 12:11 PST by BJ Burg
Modified: 2017-04-03 12:48 PDT (History)
4 users (show)

See Also:


Attachments
SCREENSHOT (126.61 KB, image/png)
2017-02-23 12:11 PST, BJ Burg
no flags Details
Patch (2.22 KB, patch)
2017-03-10 21:23 PST, Matt Baker
mattbaker: review-
Details | Formatted Diff | Diff
[Image] Tree element titles (121.46 KB, image/png)
2017-03-10 21:24 PST, Matt Baker
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description BJ Burg 2017-02-23 12:11:22 PST
Created attachment 302555 [details]
SCREENSHOT

Problems:

 - ellipsis on left side of text is prepended to the resource
 - subtitle with origin text should be overflowed before the resource name

For the first, we should override the dir attribute for these labels so that ellipsis appear on the right side of text. I think it should still be possible to right align them.
For the second, we should double-check that the separator used for this is localizable so RTL languages can swap the order of the title and subtitle. Or, we could do it manually if this is ambiguous.
Comment 1 Matt Baker 2017-03-10 21:10:59 PST
(In reply to comment #0)
> Created attachment 302555 [details]
> SCREENSHOT
> 
> Problems:
> 
>  - ellipsis on left side of text is prepended to the resource
>  - subtitle with origin text should be overflowed before the resource name
> 
> For the first, we should override the dir attribute for these labels so that
> ellipsis appear on the right side of text. I think it should still be
> possible to right align them.
> For the second, we should double-check that the separator used for this is
> localizable so RTL languages can swap the order of the title and subtitle.
> Or, we could do it manually if this is ambiguous.

I have a patch that resolves the second issue. Elements will flow their contents according the current direction as long as the children are inline-block.

With only minor CSS tweaks our GeneralTreeElement class works great in RTL!
Comment 2 Matt Baker 2017-03-10 21:23:34 PST
Created attachment 304131 [details]
Patch
Comment 3 Matt Baker 2017-03-10 21:24:12 PST
Created attachment 304132 [details]
[Image] Tree element titles
Comment 4 Matt Baker 2017-03-12 11:25:25 PDT
Comment on attachment 304131 [details]
Patch

Need to come up with an alternate solution: inline-block breaks text-overflow on the title/subtitle elements.