govuk-components 5.0.0b1 → 5.0.0b2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 71deff2fbc3e3456d59fe65244041e5b892a2c014967e11cf3a4f5e64a6da596
4
- data.tar.gz: 756dfe3c9c96747e25d11e7175f6ae1b15b8cb9db0556f400ac00275c97dbd9a
3
+ metadata.gz: d6c2597cbc2b6db48def0781c11e2173bb2e3a1bf5b661c695145d68ea41fa7f
4
+ data.tar.gz: c6853251961b9b9e2e102cbdd6439cf20b99d695ba548008c1d68edb1c287158
5
5
  SHA512:
6
- metadata.gz: a62ba0fdd881023b79cff29398915f1b37d8b11057bc544fe5bc3df9c7c5336a0c6703360eac1d629ec0c7a7edf8fe1673195478424e86695ad6d273c66527ff
7
- data.tar.gz: cbf84f6ea8a76973402d07375b4552661e7316267e1edfd89151f05dc74fe3de38366230c4e498cf66f03111ea180870b05439c79076c89c0fc4b9ca58d5d22d
6
+ metadata.gz: 7d908043c42e33bf274e2d06e8873ec6fe207825b866064fc12dcd46ce9c113db3476dd7ee9537d65b5648e2521da1b7abcaccdd23fdbbf715003d9672390952
7
+ data.tar.gz: 3595863554678c2eb81f5a286d71257a0340bcb57d9dda6596d6d7efa0e985e8dd59cd72d984cba87cb86ad0c2f49e3280dc918f207970cdd0e9b3246cd793f9
@@ -1,13 +1,9 @@
1
1
  module GovukVisuallyHiddenHelper
2
- def govuk_visually_hidden(text = nil, focusable: false, &block)
3
- content = (block_given?) ? block.call : text
2
+ def govuk_visually_hidden(text = nil, &block)
3
+ return if text.blank? && block.nil?
4
4
 
5
- return if content.blank?
6
-
7
- visually_hidden_class = focusable ? "govuk-visually-hidden-focusable" : "govuk-visually-hidden"
8
-
9
- tag.span(content, class: visually_hidden_class)
5
+ tag.span(text, class: "govuk-visually-hidden", &block)
10
6
  end
11
7
  end
12
8
 
13
- ActiveSupport.on_load(:action_view) { include GovukSkipLinkHelper }
9
+ ActiveSupport.on_load(:action_view) { include GovukVisuallyHiddenHelper }
@@ -1,5 +1,5 @@
1
1
  module Govuk
2
2
  module Components
3
- VERSION = '5.0.0b1'.freeze
3
+ VERSION = '5.0.0b2'.freeze
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: govuk-components
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.0.0b1
4
+ version: 5.0.0b2
5
5
  platform: ruby
6
6
  authors:
7
7
  - DfE developers
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-11-28 00:00:00.000000000 Z
11
+ date: 2023-11-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: html-attributes-utils