govuk_design_system_formbuilder 2.7.4 → 2.7.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +1 -1
- data/lib/govuk_design_system_formbuilder/elements/error_summary.rb +1 -1
- data/lib/govuk_design_system_formbuilder/traits/fieldset_item.rb +1 -1
- data/lib/govuk_design_system_formbuilder/traits/html_attributes.rb +12 -6
- data/lib/govuk_design_system_formbuilder/version.rb +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bb37ec8e436af4e21bbc44dfbc7dbbead355c07f3f41f802f03de5550b7c419c
|
4
|
+
data.tar.gz: 8aba7fb23067d7ee5fc422488525b8d0d013bf7f76b67ecb31647619e4901f8f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: cfcabda01e6b764bbc17ea8185180b48095c2eae04cf308387c7fa430b374fa0c40bffb50e7bacf2d7c0abadca362e4fb07ae27699e7645bd732d9a9487a792a
|
7
|
+
data.tar.gz: 37ee3a7a8d6dbf5eaf441d81102e507e17043e79b4b774b3ebdad9e1d6d8607e509651c5b9586d029d1be1732805e950f1824e46f47cb88d5106f5a011bf2ff4
|
data/README.md
CHANGED
@@ -6,7 +6,7 @@
|
|
6
6
|
[![Gem](https://img.shields.io/gem/dt/govuk_design_system_formbuilder?logo=rubygems)](https://rubygems.org/gems/govuk_design_system_formbuilder)
|
7
7
|
[![Test Coverage](https://api.codeclimate.com/v1/badges/110136fb22341d3ba646/test_coverage)](https://codeclimate.com/github/DFE-Digital/govuk-formbuilder/test_coverage)
|
8
8
|
[![GitHub license](https://img.shields.io/github/license/DFE-Digital/govuk_design_system_formbuilder)](https://github.com/DFE-Digital/govuk-formbuilder/blob/master/LICENSE)
|
9
|
-
[![GOV.UK Design System Version](https://img.shields.io/badge/GOV.UK%20Design%20System-3.
|
9
|
+
[![GOV.UK Design System Version](https://img.shields.io/badge/GOV.UK%20Design%20System-3.14.0-brightgreen)](https://design-system.service.gov.uk)
|
10
10
|
[![Rails](https://img.shields.io/badge/Ruby-2.6.8%20%E2%95%B1%202.7.4%20%E2%95%B1%203.0.2-E16D6D)](https://www.ruby-lang.org/en/downloads/)
|
11
11
|
[![Ruby](https://img.shields.io/badge/Rails-6.0.4%20%E2%95%B1%206.1.3.2-E16D6D)](https://weblog.rubyonrails.org/releases/)
|
12
12
|
|
@@ -24,7 +24,7 @@ module GOVUKDesignSystemFormBuilder
|
|
24
24
|
id: field_id(link_errors: @link_errors),
|
25
25
|
class: classes,
|
26
26
|
multiple: @multiple,
|
27
|
-
aria: { describedby: [hint_id] },
|
27
|
+
aria: { describedby: [hint_id.presence] },
|
28
28
|
data: { 'aria-controls' => @conditional_id }
|
29
29
|
}
|
30
30
|
end
|
@@ -6,11 +6,17 @@ module GOVUKDesignSystemFormBuilder
|
|
6
6
|
# present
|
7
7
|
# * joins the arrays into strings to maintain Rails 6.0.* compatibility
|
8
8
|
class Attributes
|
9
|
-
#
|
10
|
-
#
|
11
|
-
#
|
12
|
-
|
13
|
-
|
9
|
+
# Only try to combine and merge these attributes that contain a list of
|
10
|
+
# values separated by a space. All other values should be merged in a
|
11
|
+
# regular fashion (where the custom value overrides the default)
|
12
|
+
MERGEABLE = [
|
13
|
+
%i(class),
|
14
|
+
%i(aria controls),
|
15
|
+
%i(aria describedby),
|
16
|
+
%i(aria flowto),
|
17
|
+
%i(aria labelledby),
|
18
|
+
%i(aria owns),
|
19
|
+
].freeze
|
14
20
|
|
15
21
|
def initialize(defaults, custom)
|
16
22
|
@merged = defaults.deeper_merge(deep_split_values(custom))
|
@@ -36,7 +42,7 @@ module GOVUKDesignSystemFormBuilder
|
|
36
42
|
end
|
37
43
|
|
38
44
|
def split_mergeable(key, value, parent = nil)
|
39
|
-
return value
|
45
|
+
return value.presence unless [parent, key].compact.in?(MERGEABLE)
|
40
46
|
|
41
47
|
value.split
|
42
48
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: govuk_design_system_formbuilder
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.7.
|
4
|
+
version: 2.7.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Peter Yates
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2021-
|
11
|
+
date: 2021-10-05 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: deep_merge
|
@@ -72,14 +72,14 @@ dependencies:
|
|
72
72
|
requirements:
|
73
73
|
- - "~>"
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version: 4.
|
75
|
+
version: 4.1.0
|
76
76
|
type: :development
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
80
|
- - "~>"
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version: 4.
|
82
|
+
version: 4.1.0
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: pry
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
@@ -355,7 +355,7 @@ metadata:
|
|
355
355
|
documentation_uri: https://www.rubydoc.info/gems/govuk_design_system_formbuilder/GOVUKDesignSystemFormBuilder/Builder
|
356
356
|
homepage_uri: https://govuk-form-builder.netlify.app
|
357
357
|
source_code_uri: https://github.com/DFE-Digital/govuk_design_system_formbuilder
|
358
|
-
github_repo:
|
358
|
+
github_repo: https://github.com/DFE-Digital/govuk_design_system_formbuilder
|
359
359
|
post_install_message:
|
360
360
|
rdoc_options: []
|
361
361
|
require_paths:
|