[Webkit-unassigned] [Bug 70373] New: Putting a dir attribute on a bdi element makes it lose isolation

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Oct 18 15:46:20 PDT 2011


           Summary: Putting a dir attribute on a bdi element makes it lose
           Product: WebKit
           Version: 528+ (Nightly build)
          Platform: All
        OS/Version: All
            Status: UNCONFIRMED
          Severity: Normal
          Priority: P2
         Component: CSS
        AssignedTo: webkit-unassigned at lists.webkit.org
        ReportedBy: aharon at google.com
                CC: eric at webkit.org, playmobil at google.com

This is true whether you say dir=ltr, dir=rtl, or even dir=auto (even though dir=auto is in fact supposed to imply isolation on any element - see https://bugs.webkit.org/show_bug.cgi?id=63903). Please note that <bdi dir="ltr|rtl"> is very useful - IMO, it should replace <span dir="ltr|rtl"> as the usual way of indicating an inline direction change: isolation extremely rarely hurts, and is often quite necessary. This is bad enough, but given that <bdi> currently does not have dir=auto by default (https://bugs.webkit.org/show_bug.cgi?id=68773), <bdi> is currently completely broken.

The bug is due to the current default stylesheet, which says that specifying a dir attribute sets unicode-bidi to embed. This is incorrect in HTML5, i.e. http://dev.w3.org/html5/spec/Overview.html#bidirectional-text, which says that the default stylesheet should go like this:

:dir(ltr) { direction: ltr; }
:dir(rtl) { direction: rtl; }
[dir] { unicode-bidi: embed; }
bdi, bdi[dir], output, output[dir], [dir=auto i] { unicode-bidi: isolate; }
bdo, bdo[dir] { unicode-bidi: bidi-override; }
bdo[dir=auto i] { unicode-bidi: bidi-override isolate; }
textarea[dir=auto i], pre[dir=auto i] { unicode-bidi: plaintext; }

Implementing this trivial fix would also fix https://bugs.webkit.org/show_bug.cgi?id=63903.

Configure bugmail: https://bugs.webkit.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.

More information about the webkit-unassigned mailing list