I made a modification in the code to control the width. Maybe not the elegant solution, but it works for me. Greetings!
Consist in add a div as a guide to get width for the .editableform .form-control class
Make BKP before make changes!
bootstrap-editable.js
On Line 14 add this code
var GLOBAL_aux_id_ei = 0;
On Line 181 add this code
var w = $('#div-guide-'+GLOBAL_aux_id_ei).width();
w = w - ((w * 20) / 100);
$('.editableform .form-control').css({"width":""+w+"px"});
On Line 628 add this code and modify the existing code
You can avoid having custom Javascript for each element on the page by using the data-inputclass attribute:
And CSS:
I made a modification in the code to control the width. Maybe not the elegant solution, but it works for me. Greetings! Consist in add a div as a guide to get width for the .editableform .form-control class
Make BKP before make changes!
bootstrap-editable.js On Line 14 add this code
On Line 181 add this code
On Line 628 add this code and modify the existing code
bootstrap-editable.css In .editable-container.editable-inline class on line 158
If you don't want to change the .css file, you can set the style of the x-editable input field by changing its template:
Note the 'tpl' attribute.
if you're doing this with angularjs xeditable you can just use 'e-style' instead of 'style' like:
I'm not sure if that would work without angularjs... but it's worth a try
you could use
inputclass
option to provide a CSS class, where you can add the width for input field, likeAnd css: