diff --git a/lib/jquery.webfonts.js b/lib/jquery.webfonts.js index 4cc01e02..74dab695 100644 --- a/lib/jquery.webfonts.js +++ b/lib/jquery.webfonts.js @@ -100,6 +100,16 @@ $element.css( 'font-family', fontStack.join() ); } + if ( !fontFamily || fontFamily === this.originalFontFamily ) { + // We are resetting the font to original font. + // Do not explicitly set fontFamily for child nodes. Just remove + // the previous setting. + $element.find( 'textarea, input, button' ) + .not( this.options.exclude ) + .css( 'font-family', '' ); + + return; + } // Set the font of this element's children if they are not excluded. // font-family of ,