Skip to content

Commit 69a1604

Browse files
committed
Fix width calculation to allow for different padding
1 parent bd76b87 commit 69a1604

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/uiSelectController.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ uis.controller('uiSelectCtrl',
364364
if (containerWidth === 0) {
365365
return false;
366366
}
367-
var inputWidth = containerWidth - input.offsetLeft - 10;
367+
var inputWidth = containerWidth - input.offsetLeft - ctrl.searchInput.parent()[0].offsetLeft - 5;
368368
if (inputWidth < 50) inputWidth = containerWidth;
369369
ctrl.searchInput.css('width', inputWidth+'px');
370370
return true;

0 commit comments

Comments
 (0)