govuk_frontend_toolkit
Advanced tools
Comparing version 4.16.1 to 4.17.0
@@ -0,1 +1,5 @@ | ||
# 4.17.0 | ||
- SelectionButtons will add a class to the label with the type of the child input ([PR #317](https://github.com/alphagov/govuk_frontend_toolkit/pull/317)) | ||
# 4.16.1 | ||
@@ -2,0 +6,0 @@ |
@@ -11,2 +11,4 @@ (function (global) { | ||
this.focusedClass = 'focused'; | ||
this.radioClass = 'selection-button-radio'; | ||
this.checkboxClass = 'selection-button-checkbox'; | ||
if (opts !== undefined) { | ||
@@ -37,2 +39,4 @@ $.each(opts, function (optionName, optionObj) { | ||
var labelClass = $elm.attr('type') === 'radio' ? this.radioClass : this.checkboxClass; | ||
$elm.parent('label').addClass(labelClass); | ||
if ($elm.is(':checked')) { | ||
@@ -39,0 +43,0 @@ this.markSelected($elm); |
{ | ||
"name": "govuk_frontend_toolkit", | ||
"version": "4.16.1", | ||
"version": "4.17.0", | ||
"description": "npm package for using the GOV.UK frontend toolkit", | ||
@@ -5,0 +5,0 @@ "repository": { |
@@ -1,1 +0,1 @@ | ||
4.16.1 | ||
4.17.0 |
471756
1124