govuk_publishing_components 21.15.1 → 21.15.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/app/assets/javascripts/govuk_publishing_components/lib/cookie-functions.js +4 -4
- data/app/assets/stylesheets/govuk_publishing_components/components/_cookie-banner.scss +12 -3
- data/app/views/govuk_publishing_components/components/_cookie_banner.html.erb +1 -1
- data/app/views/govuk_publishing_components/components/docs/cookie_banner.yml +1 -1
- data/lib/govuk_publishing_components/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
---
|
|
2
2
|
SHA256:
|
|
3
|
-
metadata.gz:
|
|
4
|
-
data.tar.gz:
|
|
3
|
+
metadata.gz: 8315a827c7e0bb201abdb8f6c0f0ce808ab0531c80113a7b6eab67426788cd8d
|
|
4
|
+
data.tar.gz: 912061103bd7142d52ba5fde79bde3ecf5c25b7761fecf1455890241155fdfe5
|
|
5
5
|
SHA512:
|
|
6
|
-
metadata.gz:
|
|
7
|
-
data.tar.gz:
|
|
6
|
+
metadata.gz: cba3df16d2d460a621ccb9d7186e69c8f77733a89c34ca5f61ec2c8c267ee3ccb394e48d5665a6c72f4e7b522e7028830fe66fbb87a544aaa3bd6bf7c34b68cb
|
|
7
|
+
data.tar.gz: b519951ca60b5cdbe529f7cbb3115fa904a3f2604dad344aa5edad78d18a7d8644d40d62fe3d278a5a13bedd35163f5cffad86f77b0c534863ca6133e8bf330a
|
|
@@ -22,8 +22,6 @@
|
|
|
22
22
|
'global_bar_seen': 'settings',
|
|
23
23
|
'govuk_browser_upgrade_dismisssed': 'settings',
|
|
24
24
|
'govuk_not_first_visit': 'settings',
|
|
25
|
-
'govuk_surveySeenUserSatisfactionSurvey': 'settings',
|
|
26
|
-
'govuk_takenUserSatisfactionSurvey': 'settings',
|
|
27
25
|
'analytics_next_page_call': 'usage',
|
|
28
26
|
'_ga': 'usage',
|
|
29
27
|
'_gid': 'usage',
|
|
@@ -116,7 +114,9 @@
|
|
|
116
114
|
window.GOVUK.cookie(cookie, null)
|
|
117
115
|
|
|
118
116
|
if (window.GOVUK.cookie(cookie)) {
|
|
119
|
-
|
|
117
|
+
// We need to handle deleting cookies on the domain and the .domain
|
|
118
|
+
document.cookie = cookie + '=;expires=' + new Date() + ';'
|
|
119
|
+
document.cookie = cookie + '=;expires=' + new Date() + ';domain=' + window.location.hostname + ';path=/'
|
|
120
120
|
}
|
|
121
121
|
}
|
|
122
122
|
}
|
|
@@ -153,7 +153,7 @@
|
|
|
153
153
|
|
|
154
154
|
// Survey cookies are dynamically generated, so we need to check for these separately
|
|
155
155
|
if (cookieName.match('^govuk_surveySeen') || cookieName.match('^govuk_taken')) {
|
|
156
|
-
return window.GOVUK.checkConsentCookieCategory(cookieName, '
|
|
156
|
+
return window.GOVUK.checkConsentCookieCategory(cookieName, 'settings')
|
|
157
157
|
}
|
|
158
158
|
|
|
159
159
|
if (COOKIE_CATEGORIES[cookieName]) {
|
|
@@ -14,9 +14,12 @@ $govuk-cookie-banner-background: govuk-colour("light-grey", "grey-4");
|
|
|
14
14
|
|
|
15
15
|
.gem-c-cookie-banner__message {
|
|
16
16
|
display: inline-block;
|
|
17
|
-
@include govuk-font($size: 16);
|
|
18
|
-
padding-right: govuk-spacing(4);
|
|
19
17
|
padding-bottom: govuk-spacing(2);
|
|
18
|
+
|
|
19
|
+
@include govuk-font($size: 16);
|
|
20
|
+
@include govuk-media-query($from: desktop) {
|
|
21
|
+
padding-right: govuk-spacing(4);
|
|
22
|
+
}
|
|
20
23
|
}
|
|
21
24
|
|
|
22
25
|
.gem-c-cookie-banner__button {
|
|
@@ -26,7 +29,9 @@ $govuk-cookie-banner-background: govuk-colour("light-grey", "grey-4");
|
|
|
26
29
|
}
|
|
27
30
|
|
|
28
31
|
.govuk-button {
|
|
29
|
-
|
|
32
|
+
@include govuk-media-query($from: desktop) {
|
|
33
|
+
width: 90%;
|
|
34
|
+
}
|
|
30
35
|
|
|
31
36
|
@include govuk-media-query($until: desktop) {
|
|
32
37
|
margin-bottom: govuk-spacing(4);
|
|
@@ -116,6 +121,10 @@ $govuk-cookie-banner-background: govuk-colour("light-grey", "grey-4");
|
|
|
116
121
|
@include govuk-font($size: 19);
|
|
117
122
|
}
|
|
118
123
|
|
|
124
|
+
.gem-c-cookie-banner__message {
|
|
125
|
+
margin-bottom: 0;
|
|
126
|
+
}
|
|
127
|
+
|
|
119
128
|
p {
|
|
120
129
|
@include govuk-font($size: 19);
|
|
121
130
|
margin: 0 0 govuk-spacing(2) 0;
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
|
|
5
5
|
<div id="<%= id %>" class="gem-c-cookie-banner govuk-clearfix" data-module="cookie-banner" role="region" aria-label="cookie banner" data-nosnippet>
|
|
6
6
|
<div class="gem-c-cookie-banner__wrapper govuk-width-container">
|
|
7
|
-
<div class="govuk-row">
|
|
7
|
+
<div class="govuk-grid-row">
|
|
8
8
|
<div class=" govuk-grid-column-two-thirds">
|
|
9
9
|
<div class="gem-c-cookie-banner__message">
|
|
10
10
|
<span class="govuk-heading-m">Tell us whether you accept cookies</span>
|
|
@@ -3,7 +3,7 @@ description: Help users manage their personal data by telling them when you stor
|
|
|
3
3
|
body: |
|
|
4
4
|
Setting `data-hide-cookie-banner="true"` on any link inside the banner will overwrite the default action and when clicked will dismiss the cookie banner for a period of 365 days (approx. 1 year).
|
|
5
5
|
|
|
6
|
-
If the examples below are not showing the banner, make sure the `
|
|
6
|
+
If the examples below are not showing the banner, make sure the `cookies_preferences_set` cookie is not present or is set to false.
|
|
7
7
|
accessibility_criteria: |
|
|
8
8
|
Text in the cookie banner must be clear and unambiguous and should provide a way to dismiss the message.
|
|
9
9
|
|
metadata
CHANGED
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: govuk_publishing_components
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
version: 21.15.
|
|
4
|
+
version: 21.15.2
|
|
5
5
|
platform: ruby
|
|
6
6
|
authors:
|
|
7
7
|
- GOV.UK Dev
|
|
8
8
|
autorequire:
|
|
9
9
|
bindir: bin
|
|
10
10
|
cert_chain: []
|
|
11
|
-
date: 2019-12-
|
|
11
|
+
date: 2019-12-20 00:00:00.000000000 Z
|
|
12
12
|
dependencies:
|
|
13
13
|
- !ruby/object:Gem::Dependency
|
|
14
14
|
name: gds-api-adapters
|