Skip to content

Commit

Permalink
Survey: Enable translatable survey (for textarea contents only) in mi…
Browse files Browse the repository at this point in the history
…nimized editors - refs BT#16553
  • Loading branch information
ywarnier committed Jan 13, 2020
1 parent 05bc6cb commit c5d75e5
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 1 deletion.
Expand Up @@ -109,7 +109,17 @@ protected function getMinimizedToolbar()
['Link', 'Image', 'Video', 'Flash', 'Audio', 'Table', 'Asciimath', 'Asciisvg'],
['BulletedList', 'NumberedList', 'HorizontalRule'],
['JustifyLeft', 'JustifyCenter', 'JustifyRight'],
['Format', 'FontSize', 'Bold', 'Italic', 'Underline', 'TextColor', 'BGColor', 'Source'],
[
'Format',
'FontSize',
'Bold',
'Italic',
'Underline',
'TextColor',
'BGColor',
api_get_configuration_value('translate_html') ? 'Language' : '',
'Source'
],
['Toolbarswitch'],
];
}
Expand Down
Expand Up @@ -76,4 +76,36 @@ protected function getMaximizedToolbar()
['Toolbarswitch', 'Source'],
];
}

/**
* Get the toolbar configuration when CKEditor is minimized.
*
* @return array
*/
protected function getMinimizedToolbar()
{
return [
$this->getNewPageBlock(),
['Undo', 'Redo'],
['Link', 'Image', 'Video', 'Oembed', 'Flash', 'Youtube', 'Audio', 'Table', 'Asciimath', 'Asciisvg'],
['BulletedList', 'NumberedList', 'HorizontalRule'],
['JustifyLeft', 'JustifyCenter', 'JustifyRight', 'JustifyBlock'],
[
'Styles',
'Format',
'Font',
'FontSize',
'Bold',
'Italic',
'Underline',
'TextColor',
'BGColor',
api_get_configuration_value('translate_html') ? 'Language' : '',
],
api_get_setting('enabled_wiris') == 'true' ? ['ckeditor_wiris_formulaEditor', 'ckeditor_wiris_CAS'] : [''],
['Toolbarswitch', 'Source'],
];
}


}

0 comments on commit c5d75e5

Please sign in to comment.