It's not ideal, but at least it's no worse than it was in 1.16. It's preferable because the content area is more likely to have bidirectional text than the UI area. The UI is split up into short strings, generally in a consistent language, so there is less chance of the UBA moving fragments of text around.
Ideally, the direction of each div would be set according to the language of the text it contains.
if ( $this->direction === null ) {
$this->direction = $this->request->getVal( 'dir' );
if ( !$this->direction ) {
- $this->direction = Language::factory( $this->language )->getDir();
+ global $wgContLang;
+ $this->direction = $wgContLang->getDir();
}
}
return $this->direction;