bootstrap-fullscreen-select icon indicating copy to clipboard operation
bootstrap-fullscreen-select copied to clipboard

Select like native - without save and cancel button

Open ashvin777 opened this issue 8 years ago • 5 comments

Is it possible to use this select popup without having save and cancel button on the bottom of the popup. It should select the row selected and close the popup then itself instead of additional Save click.

Please confirm if it is already available or if there is any way to do that.

ashvin777 avatar Feb 09 '17 15:02 ashvin777

I'm looking for the same option any update on this.

Frank004 avatar Sep 04 '18 18:09 Frank004

You can change the _bindEvents function. In the "mobileSelect-control" click handler function, you can insert that.syncR(); and that.hide(); after $this.siblings().removeClass('selected').end().addClass('selected'); (after row 254). After that you can remove the buttons from _buildHTML function (after row 146) something like this:

this.$c.find('.mobileSelect-clearbtn').remove();
this.$c.find('.mobileSelect-cancelbtn').remove();
this.$c.find('.mobileSelect-buttons').remove();
this.$c.find('.list-container').css('margin-bottom',0);

johnsonbeng avatar Sep 12 '18 13:09 johnsonbeng

After following as exactly what johnsonbeng told. It really works like a native select. Thank you very much!

SyafiqTM avatar Nov 26 '19 07:11 SyafiqTM

@SyafiqTM where did you find that file to edit and insert that lines of code or is a custom script in the assets?

Frank004 avatar Nov 26 '19 13:11 Frank004

it was inside bootstrap-fullscreen-select.js created by author himself.

SyafiqTM avatar Nov 27 '19 08:11 SyafiqTM