/**
 * ProveIt is a reference manager for Wikipedia and any other MediaWiki wiki
 * Documentation at https://www.mediawiki.orghttps://wikines.com/es/ProveIt
 *
 * This initialization script sets the configuration options specific to this wiki
 * and then loads the ProveIt code directly from MediaWiki.org
 */
function loadProveIt() {
	mw.config.set({
		'proveit-tag': 'ProveIt', // Revision tag defined at Special:Tags (optional)
		'proveit-summary': 'Referencia editada con ]', // Automatic edit summary (optional)
		'proveit-templates': [ // Citation templates (without namespace)
			'Cita web',
			'Cita libro',
			'Cita enciclopedia',
			'Cita noticia',
			'Cita publicación',
			'Cita vídeo',
			'Obra citada'
		],
		'proveit-namespaces': [ // Supported namespaces (see https://www.mediawiki.orghttps://wikines.com/es/Manual:Namespace_constants)
			0, // Main namespace
			2, // User namespace
			104, // Anexos
		]
	});
	mw.loader.load( '//www.mediawiki.org/w/load.php?modules=ext.gadget.ProveIt&only=scripts' );
	mw.loader.load( '//www.mediawiki.org/w/load.php?modules=ext.gadget.ProveIt&only=styles', 'text/css' );
}

// Only load when editing
mw.hook( 'wikipage.editform' ).add( loadProveIt );
mw.hook( 've.activationComplete' ).add( loadProveIt );