feat: #9628, allow setting custom icon names

v1.18.x
Barış Soner Uşaklı 4 years ago
parent 52596902a6
commit 2fe30b6fa0

@ -48,11 +48,16 @@ define('iconSelect', ['benchpress'], function (Benchpress) {
var iconClass = $('.bootbox .selected').attr('class');
var categoryIconClass = $('<div></div>').addClass(iconClass).removeClass('fa').removeClass('selected')
.attr('class');
var searchElVal = picker.find('input').val();
if (categoryIconClass) {
el.attr('class', 'fa ' + (doubleSize ? 'fa-2x ' : '') + categoryIconClass);
el.val(categoryIconClass);
el.attr('value', categoryIconClass);
} else if (searchElVal) {
el.attr('class', searchElVal);
el.val(searchElVal);
el.attr('value', searchElVal);
}
onModified(el);

Loading…
Cancel
Save