MediaWiki:Common.js: Difference between revisions
Appearance
mNo edit summary |
mNo edit summary |
||
| Line 9: | Line 9: | ||
setTimeout(function(){ | setTimeout(function(){ | ||
tinymce.init({ plugins: 'preview importcss searchreplace autolink autosave save directionality code visualblocks visualchars fullscreen image link media codesample table charmap pagebreak nonbreaking anchor insertdatetime advlist lists help quickbars', | tinymce.init({ plugins: 'preview importcss searchreplace autolink autosave save directionality code visualblocks visualchars fullscreen image link media codesample table charmap pagebreak nonbreaking anchor insertdatetime advlist lists help quickbars', | ||
menubar: 'edit view insert format tools table', | menubar: 'edit view insert format tools table code', | ||
toolbar: 'undo redo | bold italic underline strikethrough | fontfamily fontsize blocks | alignleft aligncenter alignright alignjustify | outdent indent | numlist bullist | forecolor backcolor removeformat | fullscreen preview save print | image media link anchor', | toolbar: 'undo redo | bold italic underline strikethrough | fontfamily fontsize blocks | alignleft aligncenter alignright alignjustify | outdent indent | numlist bullist | forecolor backcolor removeformat | fullscreen preview save print | image media link anchor', | ||
quickbars_selection_toolbar: 'bold italic | quicklink h2 h3 blockquote quickimage quicktable', | quickbars_selection_toolbar: 'bold italic | quicklink h2 h3 blockquote quickimage quicktable', | ||
Revision as of 18:24, 18 March 2023
/* Any JavaScript here will be loaded for all users on every page load. */
setTimeout(function(){
var $ = jQuery;
if(RLCONF.wgUserGroups.length>1) {
$('#p-tb').css('display','block');
if(top.location.href.includes('action=edit') && !top.location.href.includes('Common')) {
mw.loader.load( 'https://cdn.jsdelivr.net/npm/tinymce@6.4.0/tinymce.min.js' );
mw.loader.load( 'https://cdn.jsdelivr.net/npm/tinymce@6.4.0/skins/ui/oxide/content.min.css' );
setTimeout(function(){
tinymce.init({ plugins: 'preview importcss searchreplace autolink autosave save directionality code visualblocks visualchars fullscreen image link media codesample table charmap pagebreak nonbreaking anchor insertdatetime advlist lists help quickbars',
menubar: 'edit view insert format tools table code',
toolbar: 'undo redo | bold italic underline strikethrough | fontfamily fontsize blocks | alignleft aligncenter alignright alignjustify | outdent indent | numlist bullist | forecolor backcolor removeformat | fullscreen preview save print | image media link anchor',
quickbars_selection_toolbar: 'bold italic | quicklink h2 h3 blockquote quickimage quicktable',
contextmenu: 'link image table',
toolbar_sticky: true,
selector: '#wpTextbox1',forced_root_block : "",extended_valid_elements : '*[*]',cleanup : false,
verify_html : false });
},300); }
}
console.log('Ready');
},300);