Skip to content
This repository has been archived by the owner on Oct 8, 2021. It is now read-only.

Commit

Permalink
Merge pull request #5848 from jhogervorst/issue-5690
Browse files Browse the repository at this point in the history
Textinput: height correctly calculated (without extra padding) for box-sizing
  • Loading branch information
jaspermdegroot committed Apr 3, 2013
1 parent 8ff0c55 commit 60789e2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion js/widgets/forms/textinput.js
Original file line number Diff line number Diff line change
Expand Up @@ -125,7 +125,11 @@ $.widget( "mobile.textinput", $.mobile.widget, {
clientHeight = input[ 0 ].clientHeight;

if ( clientHeight < scrollHeight ) {
input.height( scrollHeight + extraLineHeight );
var paddingTop = parseFloat( input.css( "padding-top" ) ),
paddingBottom = parseFloat( input.css( "padding-bottom" ) ),
paddingHeight = paddingTop + paddingBottom;

input.height( scrollHeight - paddingHeight + extraLineHeight );
}
};

Expand Down

0 comments on commit 60789e2

Please sign in to comment.