From 2991ed18f3d3d5aabb37aae57b6733b1383aa84a Mon Sep 17 00:00:00 2001 From: "Amir E. Aharoni" Date: Mon, 8 Oct 2012 20:46:07 +0200 Subject: [PATCH] Refactor font selection HTML Added whitespace for readability and comments to understand the different parts of the HTML template. Also removed an unneeded closing . The output is not supposed to change. Change-Id: I43891170eb6fac03370cf1d71cd399d2de3c4da8 --- resources/js/ext.uls.displaysettings.js | 75 ++++++++++++++++++------- 1 file changed, 56 insertions(+), 19 deletions(-) diff --git a/resources/js/ext.uls.displaysettings.js b/resources/js/ext.uls.displaysettings.js index cc8ac175..a25d2e9a 100644 --- a/resources/js/ext.uls.displaysettings.js +++ b/resources/js/ext.uls.displaysettings.js @@ -20,38 +20,72 @@ ( function ( $, mw, undefined ) { "use strict"; - var template = '
' - + '

' - + '
' - + '

' - + '
' - + '
' - + '
' - + '

' + var template = '
' // Top "Display settings" title + + '
' + + '

' + + '
' + + '
' + + // "Language for display", title above the buttons row + '
' + '
' - + '
' + + '
' + + // UI languages buttons row + + '
' + + '
' + + '
' + + // "Font settings" title + + '
' + + '
' + + '

' + + '
' + + '
' + + // Webfonts enabling chechbox with label + + '
' + + '
' + + '' + + '' + '
' + '
' - + '
' + + // Font selection title + + '
' + + '
' + + '
' + + // Menus font selection dropdown with label + '
' - + '
' + + '
' + + '' + + '
' + '' + '
' + + // Content font selection dropdown with label + '
' - + '
' + + '
' + + '' + + '
' + '' + '
' + + // Separator + '
' + + // Apply and Cancel buttons + '
' + '
' + '' - + '' + + '' + '
' + '
'; // FIXME i18n and too much hardcoding. @@ -242,13 +276,15 @@ var $systemFont = $( "