danielfarrell / bootstrap-combobox

A combobox plugin that works with twitter bootstrap
849 stars 328 forks source link

visualization problem with Bootstrap 4 #255

Open seanVonDrake opened 6 years ago

seanVonDrake commented 6 years ago

hi, I am using for the first time bootstrap-combobox with Bootstrap 4 and I am experiencing a problem (apparently) with CSS, the combobox is rendered as you can see in the attached image file. My HTML code is here: <div class="col-md-3"><select name="id_citta" class="form-control form-control-sm">[options here...]</select></div> I am getting the code from the cdnjs: `

` please note that the same code is working fine with Bootstrap 3, as you can see in the second image attached. Any help would be appreciated, many thanks. ![1](https://user-images.githubusercontent.com/11670332/35543171-01c6ac92-0564-11e8-9a6b-da7b4cf40fea.jpg) ![2](https://user-images.githubusercontent.com/11670332/35543172-01e022c6-0564-11e8-8c0c-24126339fc11.jpg)
tiesont commented 6 years ago

The addon markup and classes have changed between Bootstrap 3 and Bootstrap 4, so at the moment Bootstrap 4 is incompatible. Not sure when you can expect an update.

I will be taking over development at some point, so this is on me, but I'm a bit short of time to work on this at the moment. Sorry.

jcass77 commented 6 years ago

254 might help.

TusharSD commented 5 years ago

Bootstrap 4 Input-groups > .input-group-append will do the job for you

eddy-lau commented 5 years ago

I do this for Bootstrap 4:

$('.combobox').combobox({
        template: function() {
          return '<div class="combobox-container"> <input type="hidden" /><div class="input-group"> <input type="text" autocomplete="off" /><span class="input-group-append input-group-text dropdown-toggle" data-dropdown="dropdown"><span class="caret" /> <span class="glyphicon glyphicon-remove" /></span></div></div>';
        }
});
seanVonDrake commented 5 years ago

hello, any news about this? sorry for bothering, but Bootstrap 4 is becoming a standard now and it would be great to use this wonderful plugin again!

seanVonDrake commented 5 years ago

just in case anyone out there need this, as a dirty workaround I added this to my CSS in order to make the combobox look a little better:

.dropdown-toggle { width: 32px; color: #ffffff; cursor: pointer; background-color: #6c757d; font-size: 1.4em; padding: 0px 6px; padding-top: 4px; border-top-right-radius: .2rem; border-bottom-right-radius: .2rem; }

hope it helps