[Rt-commit] rt branch, 4.2/clicky-radio-labels, created. rt-4.2.11-40-g7239117

Dustin Graves dustin at bestpractical.com
Wed Aug 5 16:12:38 EDT 2015


The branch, 4.2/clicky-radio-labels has been created
        at  7239117ded55600b50640e926ed4a47f783345e8 (commit)

- Log -----------------------------------------------------------------
commit 7239117ded55600b50640e926ed4a47f783345e8
Author: Dustin Graves <dustin at bestpractical.com>
Date:   Wed Aug 5 20:11:08 2015 +0000

    added label container for standard boolean radio buttons
    
    clicking their label will select the radio button
    
    Fixes: I#30953

diff --git a/share/html/Widgets/Form/Boolean b/share/html/Widgets/Form/Boolean
index 0d5bd1a..a1292de 100644
--- a/share/html/Widgets/Form/Boolean
+++ b/share/html/Widgets/Form/Boolean
@@ -73,12 +73,18 @@ $CurrentValue => undef,
 <input type="hidden" name="<% $Name %>" value="0" />\
 <input type="checkbox" name="<% $Name %>" value="1" <% $CurrentValue? ' checked="checked"': '' |n %> />\
 % } else {
-<input type="radio" name="<% $Name %>" value="1" <% $CurrentValue? ' checked="checked"': '' |n %> />\
-<% loc('Yes') %>
-<input type="radio" name="<% $Name %>" value="0" <% defined $CurrentValue && !$CurrentValue? ' checked="checked"': '' |n %> />\
-<% loc('No') %>
-<input type="radio" name="<% $Name %>" value="__empty_value__" <% !defined $CurrentValue? ' checked="checked"': '' |n %> />\
-<% $DefaultLabel %>
+<label>
+    <input type="radio" name="<% $Name %>" value="1" <% $CurrentValue? ' checked="checked"': '' |n %> />\
+    <% loc('Yes') %>
+</label>
+<label>
+    <input type="radio" name="<% $Name %>" value="0" <% defined $CurrentValue && !$CurrentValue? ' checked="checked"': '' |n %> />\
+    <% loc('No') %>
+</label>
+<label>
+    <input type="radio" name="<% $Name %>" value="__empty_value__" <% !defined $CurrentValue? ' checked="checked"': '' |n %> />\
+    <% $DefaultLabel %>
+</label>
 % }
 </%METHOD>
 

-----------------------------------------------------------------------


More information about the rt-commit mailing list