Skip to content

Commit

Permalink
fix(radiosfield): better handling of long labels
Browse files Browse the repository at this point in the history
Signed-off-by: Thierry Bugier <tbugier@teclib.com>
  • Loading branch information
btry committed Jan 27, 2020
1 parent ec7cb62 commit e39016a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion css/styles.css
Original file line number Diff line number Diff line change
Expand Up @@ -427,7 +427,7 @@ input.submit_button:focus {
cursor: pointer;
padding-left: 22px;
position: relative;
display: block;
display: inline-block;
height: 26px;
}
.formcreator_radios input[type = radio] + label:before,
Expand Down
2 changes: 2 additions & 0 deletions inc/fields/radiosfield.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,7 @@ public function getRenderedHtml($canEdit = true) {
if ((trim($value) != '')) {
$i++;
$checked = ($this->value == $value) ? ['checked' => ''] : [];
$html .= '<p>';
$html .= Html::input($fieldName, [
'type' => 'radio',
'class' => 'form-control',
Expand All @@ -113,6 +114,7 @@ public function getRenderedHtml($canEdit = true) {
$html .= '<label for="' . $domId . '_' . $i . '">';
$html .= $value;
$html .= '</label>';
$html .= '</p>';
}
}
$html .= '</div>';
Expand Down

0 comments on commit e39016a

Please sign in to comment.