Skip to content

Commit

Permalink
Update templating of radio field labels (#659)
Browse files Browse the repository at this point in the history
Updates the templating of radio fields to go along with the updates to
select field options in #591.
  • Loading branch information
goldenapples authored and mattheu committed Nov 18, 2016
1 parent 0ac7ac1 commit f98409d
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions inc/templates/edit-form.tpl.php
Original file line number Diff line number Diff line change
Expand Up @@ -72,10 +72,10 @@
<script type="text/html" id="tmpl-shortcode-ui-field-radio">
<div class="field-block shortcode-ui-field-radio shortcode-ui-attribute-{{ data.attr }}">
<label>{{{ data.label }}}</label>
<# _.each( data.options, function( label, value ) { #>
<# _.each( data.options, function( option ) { #>
<label>
<input type="radio" name="{{ data.attr }}" value="{{ value }}" <# if ( value == data.value ) { print('checked'); } #> />
{{ label }}
<input type="radio" name="{{ data.attr }}" value="{{ option.value }}" <# if ( option.value == data.value ) { print('checked'); } #> />
{{ option.label }}
</label>
<# }); #>
<# if ( typeof data.description == 'string' && data.description.length ) { #>
Expand Down

0 comments on commit f98409d

Please sign in to comment.