text: move right padding for clear to render, otherwise popup position wrong
This commit is contained in:
parent
5ac48f3fd8
commit
2258124766
@ -43,8 +43,11 @@ $(function(){
|
||||
renderClear: function() {
|
||||
if (this.options.clear) {
|
||||
this.$clear = $('<span class="editable-clear-x"></span>');
|
||||
this.$input.after(this.$clear).parent().css('position', 'relative');
|
||||
this.$input.keyup($.proxy(this.toggleClear, this));
|
||||
this.$input.after(this.$clear)
|
||||
.css('padding-right', 25)
|
||||
.keyup($.proxy(this.toggleClear, this))
|
||||
.parent().css('position', 'relative');
|
||||
|
||||
this.$clear.click($.proxy(function(){
|
||||
this.$clear.hide();
|
||||
this.$input.val('').focus();
|
||||
@ -64,7 +67,6 @@ $(function(){
|
||||
}
|
||||
|
||||
this.$clear.css({top: delta, right: delta});
|
||||
this.$input.css('padding-right', this.$clear.width() + 2*delta - 3);
|
||||
}
|
||||
},
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user