Sha256: 0ce20179255703ac8b4402a7db39ea78e41f8fb1df11452b8096c9af47a2341b

Contents?: true

Size: 969 Bytes

Versions: 3

Compression:

Stored size: 969 Bytes

Contents

<:Body>
  <div class="{{ if errors }}has-error{{ elsif marked }}has-success{{ end }} has-feedback">
    {{ attrs.options.each do |option| }}
      <div class="radio">
        {{ if checked?(option['value']) }}
          <label>
            <input type="radio" e-click="set_field(option['value'])" name="{{ @field_name }}_radio" value="{{option['value']}}" checked/>
            {{ option['label'] }}
          </label>
          {{ if errors }}
            <span class="glyphicon glyphicon-remove"></span>
            <span class="control-label errors">{{ (errors || []).join(', ') }}</span>
          {{ elsif marked }}
            <span class="glyphicon glyphicon-ok"></span>
          {{ end }}
        {{ else }}
          <label>
            <input type="radio" e-click="set_field(option['value'])" name="{{ @field_name }}_radio" value="{{option['value']}}"/>
            {{ option['label'] }}
          </label>
        {{ end }}
    {{ end }}
    </div>
  </div>

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
volt-fields-0.1.3 app/fields/views/radio/index.html
volt-fields-0.1.2 app/fields/views/radio/index.html
volt-fields-0.1.1 app/fields/views/radio/index.html