fixes : data-value igoned for empty element

This commit is contained in:
vitalets
2013-03-06 13:17:40 +04:00
parent 4d527d7007
commit fcc08b8def
4 changed files with 20 additions and 8 deletions

@ -453,7 +453,7 @@ $(function () {
expect(3);
//auto, text->empty, source->array
var e = $('<a href="#" data-type="select" data-value="3"></a>').appendTo(sfx).editable({
var e = $('<a href="#" data-type="select" data-value="3"> </a>').appendTo(sfx).editable({
source: groups,
autotext: 'auto'
}),

@ -15,8 +15,9 @@ $(function () {
equal(p.find('input[type=text]').attr('placeholder'), 'abc', 'placeholder exists');
p.find('.editable-cancel').click();
ok(!p.is(':visible'), 'popover was removed');
});
});
asyncTest("should load correct value and save new entered text (and value)", function () {
var v = 'ab<b>"',
esc_v = $('<div>').text(v).html(),