Add examples for <bdi> and <bdo>#880
Add examples for <bdi> and <bdo>#880Elchi3 wants to merge 1 commit intomdn:masterfrom Elchi3:html-bdi-bdo
Conversation
|
As I understand it, For example, in your example you have: But actually, if you omit the But there are times when the bidi algorithm needs help, mostly I think because some characters (for example, "!") are "neutral", so the algorithm tries to figure out the directionality from the surrounding text, and sometimes that doesn't give you the result you want. w3schools has a good example of this: Without the ...you get: There's a great article on this here: https://www.w3.org/International/articles/inline-bidi-markup/. The rules are:
...although I guess the semantics of the first are clearer. So So anyway, if I'm right about any of this, it would be good to have an example showing something like:
|
|
Wow, thanks Will! I've not understood |
|
I've pushed a new set of examples for bdi/bdo in this PR: #1041. Apologies if it wasn't the most elegant way to do this, but I wasn't sure if there was a way to add to Florian's PR. |
|
Closed in favour of #1041. |

Examples for:
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/bdi
https://developer.mozilla.org/en-US/docs/Web/HTML/Element/bdo
For
<bdi>it says it "is useful when embedding text whose directionality may not be known" so I've listed a few different languages where some are ltr and some rtl.I think the
<bdo>example demonstrates what it does pretty well, but I had trouble finding a real situation for this that isn't just demoing the behavior.Fixes:
#765, #766