X-Git-Url: https://git.heureux-cyclage.org/?a=blobdiff_plain;f=mw-config%2Fconfig.js;h=d2dc21321302fdf4e5b3d4cda9f15d7c5019fd76;hb=d92845c2295d982c80312880c3fae788450676ea;hp=cf17aef77c075c50b95e482453d606f38ed6153f;hpb=16a9dd96bd5d7bec87c83d47fb954f2e7934dffe;p=lhc%2Fweb%2Fwiklou.git diff --git a/mw-config/config.js b/mw-config/config.js index cf17aef77c..d2dc213213 100644 --- a/mw-config/config.js +++ b/mw-config/config.js @@ -3,7 +3,7 @@ var $label, labelText; function syncText() { - var value = $(this).val() + var value = $( this ).val() .replace( /[\[\]\{\}|#<>%+? ]/g, '_' ) .replace( /&/, '&' ) .replace( /__+/g, '_' ) @@ -20,7 +20,7 @@ .find( '.mw-help-field-hint' ) .show() .click( function () { - $(this) + $( this ) .closest( '.mw-help-field-container' ) .find( '.mw-help-field-data' ) .slideToggle( 'fast' ); @@ -29,7 +29,7 @@ // Show/hide code for DB-specific options // FIXME: Do we want slow, fast, or even non-animated (instantaneous) showing/hiding here? $( '.dbRadio' ).each( function () { - $( document.getElementById( $(this).attr( 'rel' ) ) ).hide(); + $( document.getElementById( $( this ).attr( 'rel' ) ) ).hide(); } ); $( document.getElementById( $( '.dbRadio:checked' ).attr( 'rel' ) ) ).show(); $( '.dbRadio' ).click( function () { @@ -58,16 +58,16 @@ // Show/hide random stuff (email, upload) $( '.showHideRadio' ).click( function () { - var $wrapper = $( '#' + $(this).attr( 'rel' ) ); - if ( $(this).is( ':checked' ) ) { + var $wrapper = $( '#' + $( this ).attr( 'rel' ) ); + if ( $( this ).is( ':checked' ) ) { $wrapper.show( 'slow' ); } else { $wrapper.hide( 'slow' ); } } ); $( '.hideShowRadio' ).click( function () { - var $wrapper = $( '#' + $(this).attr( 'rel' ) ); - if ( $(this).is( ':checked' ) ) { + var $wrapper = $( '#' + $( this ).attr( 'rel' ) ); + if ( $( this ).is( ':checked' ) ) { $wrapper.hide( 'slow' ); } else { $wrapper.show( 'slow' ); @@ -80,9 +80,9 @@ // Enable/disable "other" textboxes $( '.enableForOther' ).click( function () { - var $textbox = $( document.getElementById( $(this).attr( 'rel' ) ) ); + var $textbox = $( document.getElementById( $( this ).attr( 'rel' ) ) ); // FIXME: Ugh, this is ugly - if ( $(this).val() === 'other' ) { + if ( $( this ).val() === 'other' ) { $textbox.removeProp( 'readonly' ).closest( '.config-block' ).slideDown( 'fast' ); } else { $textbox.prop( 'readonly', true ).closest( '.config-block' ).slideUp( 'fast' );