File tree Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Expand file tree Collapse file tree 2 files changed +7
-3
lines changed Original file line number Diff line number Diff line change 393393 jMask . options = options ;
394394 jMask . remove = function ( ) {
395395 var caret = p . getCaret ( ) ;
396+ if ( jMask . options . placeholder ) {
397+ el . removeAttr ( 'placeholder' ) ;
398+ }
396399 p . destroyEvents ( ) ;
397400 p . val ( jMask . getCleanVal ( ) ) ;
398401 p . setCaret ( caret ) ;
Original file line number Diff line number Diff line change @@ -326,11 +326,12 @@ $(document).ready(function(){
326326 module ( 'Removing mask' ) ;
327327
328328 test ( "when I get the unmasked value" , function ( ) {
329- testfield . mask ( '(00) 0000-0000' ) ;
329+ testfield . mask ( '(00) 0000-0000' , { placeholder : '(__) ____-____' } ) ;
330330
331- equal ( typeTest ( "1299999999" ) , "(12) 9999-9999" ) ;
331+ equal ( typeTest ( "1299999999" ) , "(12) 9999-9999" ) ;
332332 testfield . unmask ( )
333- equal ( testfield . val ( ) , "1299999999" ) ;
333+ equal ( testfield . val ( ) , "1299999999" ) ;
334+ equal ( testfield . attr ( 'placeholder' ) , undefined ) ;
334335 } ) ;
335336
336337 module ( 'Getting Unmasked Value' ) ;
You can’t perform that action at this time.
0 commit comments