Diferencia entre revisiones de «Usuario:Candalua/common.js»
Contenido eliminado Contenido añadido
Página nueva: // FUNCTIONS TO ENLARGE/REDUCE THE FONT //default size 100% - range is between 50%-200% fontSize = 100; function enlargeFont() { if (fontSize < 200) { fontSize += 10; $... |
Sin resumen de edición |
||
Línea 1:
// FUNCTIONS TO ENLARGE/REDUCE THE FONT
self.ws_messages = {
'optlist':'Display options',
}
//default size 100% - range is between 50%-200%
fontSize = 100;
Línea 21 ⟶ 27:
$(document).ready( function() {
get_optlist();
mw.util.addPortletLink ('p-displayOptions', 'javascript:enlargeFont()', 'Enlarge font', 'enlarge_font', 'Enlarge the font of the text' );▼
enlargeLink = mw.util.addPortletLink ('p-displayOptions', '
▲ reduceLink = mw.util.addPortletLink ('p-displayOptions', '
//expand as default
Línea 28 ⟶ 35:
});
}
// Bind click handlers
$(enlargeLink).click( function( e ) {
e.preventDefault();
enlargeFont();
});
$(reduceLink).click( function( e ) {
e.preventDefault();
reduceFont();
});
|