Skip to content
This repository was archived by the owner on Oct 2, 2019. It is now read-only.

Commit b7c568a

Browse files
committed
Fix input width calculation and avoid unnecesary digest
1 parent 958b153 commit b7c568a

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/select.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -300,10 +300,10 @@
300300
container = _searchInput.parent().parent()[0];
301301
_searchInput.css('width','10px');
302302
$timeout(function(){
303-
var newWidth = container.clientWidth - input.offsetLeft;
303+
var newWidth = container.clientWidth - input.offsetLeft - 10;
304304
if(newWidth < 50) newWidth = container.clientWidth;
305305
_searchInput.css('width',newWidth+'px');
306-
});
306+
}, 0, false);
307307
};
308308

309309
var Key = {

0 commit comments

Comments
 (0)