Fix checkbox label containing links
The link tags were being stripped out by `content_tag`.
This commit is contained in:
@@ -21,7 +21,7 @@ class ConsulFormBuilder < FoundationRailsHelper::FormBuilder
|
|||||||
|
|
||||||
def check_box(attribute, options = {})
|
def check_box(attribute, options = {})
|
||||||
if options[:label] != false
|
if options[:label] != false
|
||||||
label = content_tag(:span, label_text(object, attribute, options[:label]), class: "checkbox")
|
label = content_tag(:span, sanitize(label_text(object, attribute, options[:label]), class: "checkbox"))
|
||||||
|
|
||||||
super(attribute, options.merge(label: label, label_options: label_options_for(options)))
|
super(attribute, options.merge(label: label, label_options: label_options_for(options)))
|
||||||
else
|
else
|
||||||
|
|||||||
@@ -874,7 +874,7 @@ describe "Budget Investments" do
|
|||||||
fill_in "Title", with: "I am a bot"
|
fill_in "Title", with: "I am a bot"
|
||||||
fill_in "budget_investment_subtitle", with: "This is the honeypot"
|
fill_in "budget_investment_subtitle", with: "This is the honeypot"
|
||||||
fill_in "Description", with: "This is the description"
|
fill_in "Description", with: "This is the description"
|
||||||
check "budget_investment_terms_of_service"
|
check "I agree to the Privacy Policy and the Terms and conditions of use"
|
||||||
|
|
||||||
click_button "Create Investment"
|
click_button "Create Investment"
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user