How to prevent simple_form from applying default label to a custom wrapper?
<p>I am using SimpleForm + Bootstrap. I needed to add a <code>&lt;i&gt;&lt;/i&gt;</code>tag immediately after checkbox inputs, as follows:</p>

<pre><code>&lt;div class="form-group"&gt;
  &lt;div class="checkbox"&gt;
    &lt;label class="checkbox"&gt;
      &lt;input type="checkbox" &gt;
      &lt;i&gt;&lt;/i&gt;
      Label Text
    &lt;/label&gt;
  &lt;/div&gt;
&lt;/div&gt;
</code></pre>

<p>So i modified the initializer</p>

<pre><code>#initializers/simple_form_bootstrap.rb
config.wrappers :vertical_boolean, tag: 'div', class: 'form-group', error_class: 'has-error' do |b|
  b.use :html5
  b.optional :readonly

  b.wrapper tag: 'div', class: 'checkbox' do |ba|
    ba.wrapper tag: 'label' do |bb|
      bb.use :input
      bb.wrapper tag: 'i' do |baa|
      end
      bb.use :label_text
    end
  end

  b.use :error, wrap_with: { tag: 'span', class: 'help-block' }
  b.use :hint,  wrap_with: { tag: 'p', class: 'help-block' }
end 
</code></pre>

<p>But this is inserting an extra label tag </p>

<pre><code>&lt;div class="form-group"&gt;
  &lt;div class="checkbox"&gt;
    &lt;label&gt;
    &lt;label class="checkbox"&gt;
      &lt;input type="checkbox" &gt;
      &lt;i&gt;&lt;/i&gt;
      Label Text
    &lt;/label&gt;
    &lt;/label&gt;
  &lt;/div&gt;
&lt;/div&gt;
</code></pre>

<p><code>label.checkbox</code> is the default label applied by simple_form. i.e., via <code>config.boolean_label_class = 'checkbox'</code>. So it looks like I can remove my custom label wrapper.</p>

<pre><code>b.wrapper tag: 'div', class: 'checkbox' do |ba|
  # ba.wrapper tag: 'label' do |bb|
    bb.use :input
    bb.wrapper tag: 'i' do |baa|
    end
    bb.use :label_text
  # end
end
</code></pre>

<p>But then the label only surrounds the input.</p>

<pre><code>&lt;div class="form-group"&gt;
  &lt;div class="checkbox"&gt;
    &lt;label class="checkbox"&gt;
      &lt;input type="checkbox" &gt;
    &lt;/label&gt;
    &lt;i&gt;&lt;/i&gt;
    Label Text
  &lt;/div&gt;
&lt;/div&gt;
</code></pre>

<p>I have tried enabling and disabling <code>inline_label</code>. I am using a fresh configuration file containing the default simple_form wrappers. The only modification is as above. </p>

<p>Why is Simple_Form applying a label to the input, when <code>use label_input</code> is not being called?</p>

<p>How do I configure simple_form to wrap the input, <code>&lt;i&gt;</code> tag and label text with the label?</p>