User:Begoon/ConfWikiEditor.js
Note: After saving, you have to bypass your browser's cache to see the changes. Google Chrome, Firefox, Microsoft Edge and Safari: Hold down the ⇧ Shift key and click the Reload toolbar button. For details and instructions about other browsers, see Wikipedia:Bypass your cache.
// WikiEditor Configuration values ...
////////////////////////////////////////
/////////////////////////////////////////////////
//add strikethrough button to WikiEditor toolbar/
/////////////////////////////////////////////////
if ( typeof $ != 'undefined' && typeof $.fn.wikiEditor != 'undefined' ) {
$( function() {
$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
'section': 'advanced',
'group': 'format',
'tools': {
'strikethrough': {
label: 'Strike',
type: 'button',
icon: 'http://www.designedandonline.com/w/images/a/aa/WikiEditor-Strike.png',
action: {
type: 'encapsulate',
options: {
pre: "<s>",
post: "</s>"
}}}}} );} );}
///////////////////////////////////////////////////
//add Horizontal line button to WikiEditor toolbar/
///////////////////////////////////////////////////
if ( typeof $ != 'undefined' && typeof $.fn.wikiEditor != 'undefined' ) {
$( function() {
$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
'section': 'advanced',
'group': 'format',
'tools': {
'hline': {
label: 'Horizontal line',
type: 'button',
icon: 'http://www.designedandonline.com/w/images/9/97/WikiEditor-Hr.png',
action: {
type: 'encapsulate',
options: {
pre: "----",
ownline: true
}}}}} );} );}
//add Comment button to WikiEditor toolbar /
////////////////////////////////////////////////////////////
if ( typeof $ != 'undefined' && typeof $.fn.wikiEditor != 'undefined' ) {
$( function() {
$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
'section': 'advanced',
'group': 'format',
'tools': {
'comment': {
label: 'Comment',
type: 'button',
icon: 'http://www.designedandonline.com/w/images/0/02/WikiEditor-Comment.png',
action: {
type: 'encapsulate',
options: {
pre: "<!-- ",
post: " -->"
}}}}} );} );
}
//add Hellip button to WikiEditor toolbar
/////////////////////////////////////////
if ( typeof $ != 'undefined' && typeof $.fn.wikiEditor != 'undefined' ) {
$( function() {
$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
'section': 'advanced',
'group': 'format',
'tools': {
'comment': {
label: 'HTML ellipsis',
type: 'button',
icon: 'http://www.designedandonline.com/w/images/1/11/WikiEditor-Hellip.png',
action: {
type: 'encapsulate',
options: {
pre: "…",
ownline: false
}}}}} );} );
}
// add Template wrapper button to WikiEditor toolbar
////////////////////////////////////////////////////
if ( typeof $ != 'undefined' && typeof $.fn.wikiEditor != 'undefined' ) {
$( function() {
$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
'section': 'advanced',
'group': 'format',
'tools': {
'comment': {
label: 'Template wrapper',
type: 'button',
icon: 'http://www.designedandonline.com/w/images/6/6d/WikiEditor-Twrap.png',
action: {
type: 'encapsulate',
options: {
pre: "{{|",
post: "}}",
ownline: false
}}}}} );} );
}