MDL-76367 core: Apply RTL transformations to editors too
This commit is contained in:
+15
-4
@@ -925,6 +925,11 @@ class theme_config {
|
||||
public function editor_css_url($encoded=true) {
|
||||
global $CFG;
|
||||
$rev = theme_get_revision();
|
||||
$type = 'editor';
|
||||
if (right_to_left()) {
|
||||
$type .= '-rtl';
|
||||
}
|
||||
|
||||
if ($rev > -1) {
|
||||
$themesubrevision = theme_get_sub_revision_for_theme($this->name);
|
||||
|
||||
@@ -936,13 +941,19 @@ class theme_config {
|
||||
|
||||
$url = new moodle_url("/theme/styles.php");
|
||||
if (!empty($CFG->slasharguments)) {
|
||||
$url->set_slashargument('/'.$this->name.'/'.$rev.'/editor', 'noparam', true);
|
||||
$url->set_slashargument("{$this->name}/{$rev}/{$type}", 'noparam', true);
|
||||
} else {
|
||||
$url->params(array('theme'=>$this->name,'rev'=>$rev, 'type'=>'editor'));
|
||||
$url->params([
|
||||
'theme' => $this->name,
|
||||
'rev' => $rev,
|
||||
'type' => $type,
|
||||
]);
|
||||
}
|
||||
} else {
|
||||
$params = array('theme'=>$this->name, 'type'=>'editor');
|
||||
$url = new moodle_url('/theme/styles_debug.php', $params);
|
||||
$url = new moodle_url('/theme/styles_debug.php', [
|
||||
'theme' => $this->name,
|
||||
'type' => $type,
|
||||
]);
|
||||
}
|
||||
return $url;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user