Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

<b:inputText tags="true" /> has wrong width when using the tags attribute and inside of a <b:panelGrid /> #902

Closed
ghost opened this issue Jan 12, 2018 · 4 comments
Assignees
Milestone

Comments

@ghost
Copy link

ghost commented Jan 12, 2018

Bootsfaces Version 1.2.0

Using the tags attribute in an <b:inputText /> component, I got code like this:

<div id="..." class="form-group">
  <div class="bootstrap-tagsinput">  
    <input placeholder="" size="10" type="text"></div>
    <input id="..." name="..." class="form-control" data-role="tagsinput" style="display: none" type="text">
  </div>
</div>

Using this inside of a <b:panelGrid />, the component is not rendered as expected (does not fill out the full space of the given width by the panelGrid).

The problem is that the second div (of class bootstrap-tagsinput) does not have the expected width value of 100%.

Workaround:

add an id valuelistinput to the <b:inputText /> component and set the width by jquery (which is shipped with bootsfaces):

<script type="text/javascript">
$(document).ready(function(){
  $("[id='form:valuelistinput']").children().css("width", "100%");
});
</script>

Nevertheless, this is a bug in combination with the panelGrid component (I suppose a conflict of the css classes), so I post this here.

@stephanrauh
Copy link
Collaborator

Thanks for both the workaround and the detailed analysis!

@stephanrauh
Copy link
Collaborator

IMHO the CSS class form-control is missing.

stephanrauh added a commit to stephanrauh/bootstrap-tagsinput that referenced this issue Jun 2, 2018
@stephanrauh
Copy link
Collaborator

Seems the JavaScript library has been abandoned two years ago. I've forked it and patched it (https://github.com/stephanrauh/bootstrap-tagsinput).

@stephanrauh
Copy link
Collaborator

I've uploaded a new developer version of BootsFaces 1.2.1 to Maven Central. #369 shows how to get it.

@stephanrauh stephanrauh self-assigned this Jun 2, 2018
@stephanrauh stephanrauh added this to the v1.5.0 milestone Jun 2, 2018
@stephanrauh stephanrauh modified the milestones: v1.5.0, v1.3.0 Oct 13, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant