Diferencia entre revisiones de «Usuario:King of Herdaz/common.js»

moved art stuff to advanced section and organized some more
m
(moved art stuff to advanced section and organized some more)
//removing original buttons I don't want
 
//removeRemove bulleteddefault listreferences button
$( '#wpTextbox1' ).wikiEditor( 'removeFromToolbar', {
'section': 'advancedmain',
'group': 'formatinsert',
'tool': 'ulistreference'
});
//remove bulleted list button
$( '#wpTextbox1' ).wikiEditor( 'removeFromToolbar', {
'section': 'advanced',
'group': 'format',
'tool': 'ulist'
});
//remove numbered list button
$( '#wpTextbox1' ).wikiEditor( 'removeFromToolbar', {
'section': 'advanced',
'group': 'format',
'tool': 'olist'
});
 
//remove numbered<br> listbutton so I can replace it with my own <br/> button
$( '#wpTextbox1' ).wikiEditor( 'removeFromToolbar', {
'section': 'advanced',
'group': 'format',
'tool': 'olistnewline'
});
 
//remove <br>table button so I can replace it with <br/>
$( '#wpTextbox1' ).wikiEditor( 'removeFromToolbar', {
'section': 'advanced',
'group': 'formatinsert',
'tool': 'newlinetable'
});
 
//remove tableFile button
$( '#wpTextbox1' ).wikiEditor( 'removeFromToolbar', {
'section': 'advancedmain',
'group': 'insert',
'tool': 'tablefile'
});
 
//remove Fileoriginal buttonlink from main barbutton
$( '#wpTextbox1' ).wikiEditor( 'removeFromToolbar', {
'section': 'main',
'group': 'insert',
'tool': 'filelink'
});
 
//remove original link button from main bar
$( '#wpTextbox1' ).wikiEditor( 'removeFromToolbar', {
'section': 'main',
'group': 'insert',
'tool': 'link'
});
 
//add new "Useful Stuff" section to editing toolbar
'label': 'Useful Stuff',
'pages': {
//page of art stuff
'section-art': {
'label': 'Art stuff',
'layout': 'characters',
'characters': [
{
'action': {
'type': 'encapsulate',
'options': {
'pre': '{'+'{artist' + '\n' + '|image=' + '\n' + '|alias=' + '\n' + '|fb=' + '\n' + '|reddit=' + '\n' + '|behance=' + '\n' + '|da=' + '\n' + '|ig=' + '\n' + '|as=' + '\n' + '|tumblr=' + '\n' + '|twitter=' + '\n' + '|site=' + '\n' + '|license=all|some|none|official' + '\n' + '|contact=' + '\n' + '|type=fan|interior|cover|multimedia' + '\n' + '|no-notify=y' + '\n' + '}}' + '\n'
}
},
'label': '{' + '{artist}}'
},
{
'action': {
'type': 'encapsulate',
'options': {
'pre': '== Official artwork ==' + '\n' + '<' + 'gallery mode="packed" heights=200px caption="Official artwork">' + '\n' + '\n' + '</gallery>' + '\n' + '\n' + '== Portraits ==' + '\n' + '<' + 'gallery mode="packed" heights=200px caption="Portraits">' + '\n' + '\n' + '</gallery>' + '\n' + '\n' + '== Scenes ==' + '\n' + '<' + 'gallery mode="packed" heights=200px caption="Scenes">' + '\n' + '\n' + '</gallery>' + '\n' + '\n' + '[' + '[Category:Gallery Subpages]]'
}
},
'label': 'Gallery subpage'
},
{
'action': {
'type': 'encapsulate',
'options': {
'pre': '{' + '{art' + '\n' + '|#artist=' + '\n' + '|series=' + '\n' + '|#source=',
'post': '\n' + '|type=' + '\n' + '}}'
}
},
'label': 'Art infobox'
},
{
'action': {
'type': 'encapsulate',
'options': {
'pre': '<small><center>by {' + '{a|',
'post': '}}</center></small>'
}
},
'label': 'Artist heading'
},
'{' + '{cat tag|Books|book cover}}',
'{' + '{cat tag|Character images}}',
'{' + '{cat tag|Art}}',
'{' + '{cat tag|Interior art}}',
'|official=y' + '\n',
'\n' + '|tracer=',
'\n' + '|modified=',
'\n' + '|book=',
'\n' + '|series=',
{
'action': {
'type': 'encapsulate',
'options': {
'pre': '[mailto:',
'post': ' Email]'
}
},
'label': 'Email'
},
'<br style="clear:right;"/>',
'<' + 'gallery caption="Gallery" mode="packed" heights=200px>' + '\n',
]
},
//page of commonly used character infobox parameters
'section-params': {
});
 
//Adding various buttons
// Add category button to the "main" section
 
// Adding category button to the "main" section
$('#wpTextbox1').wikiEditor('addToToolbar', {
section: 'main',
});
 
// AddAdding image template button to the "main" section
$('#wpTextbox1').wikiEditor('addToToolbar', {
section: 'main',
});
 
// AddAdding Wikipedia link button to the "main" section
$('#wpTextbox1').wikiEditor('addToToolbar', {
section: 'main',
});
 
// AddAdding signature button to the "main" section
$('#wpTextbox1').wikiEditor('addToToolbar', {
section: 'main',
});
 
// AddAdding <br/> button to the "main" section
$('#wpTextbox1').wikiEditor('addToToolbar', {
section: 'main',
});
 
// AddAdding link button to the "main" section
$('#wpTextbox1' ).wikiEditor( 'addToToolbar', {
section: 'main',
});
 
// AddAdding hidden text button to the "main" section
$('#wpTextbox1' ).wikiEditor( 'addToToolbar', {
section: 'main',
});
 
// AddAdding columns button to the "main" section
$('#wpTextbox1' ).wikiEditor( 'addToToolbar', {
section: 'main',
});
 
//Adding a bunch of dropdowns to the "advanced" section for easy access
//Remove default references button
$( '#wpTextbox1' ).wikiEditor( 'removeFromToolbar', {
'section': 'main',
'group': 'insert',
'tool': 'reference'
});
 
//Add new references dropdown to the "advanced" section
options: {
pre: '{' + '{file ref|New_Ascendancy_broadsheet.jpg|\'\'The New Ascendency\'\' Broadsheet}}',
}
}
}
}
}
}
}
}
} );
 
//Add new art dropdown to the "advanced" section
$( '#wpTextbox1' ).wikiEditor( 'addToToolbar', {
section: 'advanced',
groups: {
list: {
tools: {
art: {
label: 'art',
type: 'select',
list: {
'artistbox-button': {
label: '{' + '{artist}}',
action: {
type: 'encapsulate',
options: {
pre: '{'+'{artist' + '\n' + '|image=' + '\n' + '|alias=' + '\n' + '|fb=' + '\n' + '|reddit=' + '\n' + '|behance=' + '\n' + '|da=' + '\n' + '|ig=' + '\n' + '|as=' + '\n' + '|tumblr=' + '\n' + '|twitter=' + '\n' + '|site=' + '\n' + '|license=all|some|none|official' + '\n' + '|contact=' + '\n' + '|type=fan|interior|cover|multimedia' + '\n' + '|no-notify=y' + '\n' + '}}' + '\n',
}
}
},
'gallerysubpage-button': {
label: 'gallery subpage',
action: {
type: 'encapsulate',
options: {
pre: '== Official artwork ==' + '\n' + '<' + 'gallery mode="packed" heights=200px caption="Official artwork">' + '\n' + '\n' + '</gallery>' + '\n' + '\n' + '== Portraits ==' + '\n' + '<' + 'gallery mode="packed" heights=200px caption="Portraits">' + '\n' + '\n' + '</gallery>' + '\n' + '\n' + '== Scenes ==' + '\n' + '<' + 'gallery mode="packed" heights=200px caption="Scenes">' + '\n' + '\n' + '</gallery>' + '\n' + '\n' + '[' + '[Category:Gallery Subpages]]',
}
}
},
'artbox-button': {
label: '{' + '{art}}',
action: {
type: 'encapsulate',
options: {
pre: '{' + '{art' + '\n' + '|#artist=' + '\n' + '|series=' + '\n' + '|#source=',
post: '\n' + '|type=' + '\n' + '}}'
}
}
},
'artistheading-button': {
label: 'artist header',
action: {
type: 'encapsulate',
options: {
pre: '<small><center>by {' + '{a|',
post: '}}</center></small>'
}
}
},
'bookcovercat-button': {
label: '{' + '{cat tag|Books|book cover}}',
action: {
type: 'encapsulate',
options: {
pre: '{' + '{cat tag|Books|book cover}}',
}
}
},
'charactercat-button': {
label: '{' + '{cat tag|Character images}}',
action: {
type: 'encapsulate',
options: {
pre: '{' + '{cat tag|Character images}}',
}
}
},
'artcat-button': {
label: '{' + '{cat tag|Art}}',
action: {
type: 'encapsulate',
options: {
pre: '{' + '{cat tag|Art}}',
}
}
},
'interiorartcat-button': {
label: '{' + '{cat tag|Interior art}}',
action: {
type: 'encapsulate',
options: {
pre: '{' + '{cat tag|Interior art}}',
}
}
},
'17s-button': {
label: '{' + '{17s ref}}',
action: {
type: 'encapsulate',
options: {
pre: '{' + '{17s ref|topic/news/post',
post: '|id#|description|date=}}'
}
}
},
'interiorartcat-button': {
label: '{' + '{cat tag|Interior art}}',
action: {
type: 'encapsulate',
options: {
pre: '{' + '{cat tag|Interior art}}',
}
}
},
'officialart-button': {
label: '|official=y',
action: {
type: 'encapsulate',
options: {
pre: '|official=y' + '\n',
}
}
},
'tracer-button': {
label: '|tracer=',
action: {
type: 'encapsulate',
options: {
pre: '\n' + '|tracer=',
}
}
},
'modified-button': {
llabel: '|modified=',
action: {
type: 'encapsulate',
options: {
pre: '\n' + '|modified=',
}
}
},
'bookparam-button': {
llabel: '|book=',
action: {
type: 'encapsulate',
options: {
pre: '\n' + '|book=',
}
}
},
'seriesparam-button': {
llabel: '|series=',
action: {
type: 'encapsulate',
options: {
pre: '\n' + '|series=',
}
}
},
'email-button': {
llabel: 'Email',
action: {
type: 'encapsulate',
options: {
pre: '[mailto:',
post: ' Email]'
}
}
},
'clearright-button': {
llabel: 'clear:right',
action: {
type: 'encapsulate',
options: {
pre: '<br style="clear:right;"/>',
}
}
},
'galleryheader-button': {
llabel: 'gallery header',
action: {
type: 'encapsulate',
options: {
pre: '<' + 'gallery caption="Gallery" mode="packed" heights=200px>' + '\n',
}
}
8718

ediciones