Diferencia entre revisiones de «Usuario:Leoncastro/Taller/MediaWiki:Gadget-DeluxeHistory.js»

Contenido eliminado Contenido añadido
oversight → suppress
Para permitir la personalización de los mensajes de la interfaz
(No se muestra una edición intermedia del mismo usuario)
Línea 1:
(function(mw, $){
 
var default_config = {
var op = window.deluxehistory ? (window.deluxehistory.options ? window.deluxehistory.options : window.deluxehistory) : ['sysop', 'bot'];
loaded: false,
var cs = window.deluxehistory ? (window.deluxehistory.css ? window.deluxehistory.css : '') : '';
options: ['sysop', 'bot'],
var ls = window.deluxehistory ? (window.deluxehistory.cache ? window.deluxehistory.cache : 7) : 7; // 7 days cache
css: '',
window.deluxehistory = { loaded: false, options: typeof op == 'string' ? [op] : op, css: cs, cache: parseInt(ls) };
cache: 7,
 
i18n: {
// message strings
var strDeluxeHistoryMenuText = 'Purgar historial';
var strDeluxeHistoryMenuInfo = strMenuText: 'Purgar la caché del historial';,
strMenuInfo: 'Purgar la caché del historial',
var strDeluxeHistoryMsgError = strMsgError: 'DeluxeHistory: Error en la recuperación de datos de la API';,
},
};
var cs = window.deluxehistory ?= $.extend(window.deluxehistory.css ? window.deluxehistory.css, :default_config '') : '';
 
// localStorage cache strings
Línea 141 ⟶ 145:
})
.fail(function(e){
mw.notify(strDeluxeHistoryMsgError window.deluxehistory.i18n.strMsgError );
});
}
Línea 213 ⟶ 217:
'p-cactions',
location.href + lsDelCache,
window.deluxehistory.i18n.strMenuText,
strDeluxeHistoryMenuText,
'ca-purge-deluxehistory',
window.deluxehistory.i18n.strMenuInfo
strDeluxeHistoryMenuInfo
);
}
Línea 226 ⟶ 230:
if( mw.config.get('wgAction') == 'history' )
{
markHistory('#pagehistory > li');
}
else if( mw.config.get('wgCanonicalSpecialPageName') == 'Recentchanges' ||