cookies_eu 1.7.7 → 1.7.8
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +11 -0
- data/app/assets/javascripts/cookies_eu.js +2 -0
- data/config/locales/tr.yml +5 -0
- data/lib/cookies_eu/version.rb +1 -1
- metadata +4 -4
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: ef0d89db9e2357389f70112e9a4297b66425c05f650388b0faad52ac093bdc95
|
4
|
+
data.tar.gz: 1c4ad2c16def8a1c133fd43bae71ab719e35adb979307047fd7b9ad392844892
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: dc9a1a68a0199e56fe4c7c8af2a0e7a39cb9b0f558280d2c972aa65080901a1de9f97622aab838aae99c5a797b7c53c07ea0f6d8a947752588ecd1f6b37a4b53
|
7
|
+
data.tar.gz: d3d46d5e74e8eab57e1cb670a81503ad42213d3540d0766832f2116a085564f749254ca06bb9f79e1a8366c768174caee59072d99671283572cc481a1ae2ad10
|
data/README.md
CHANGED
@@ -32,6 +32,7 @@ Gem to add cookie consent to rails application
|
|
32
32
|
* Slovenian
|
33
33
|
* Spanish
|
34
34
|
* Swedish
|
35
|
+
* Turkish
|
35
36
|
* Ukrainian
|
36
37
|
|
37
38
|
## Screenshot
|
@@ -100,6 +101,16 @@ If you wish to customize the style of the div the classes are:
|
|
100
101
|
|
101
102
|
If you wish to customize the HTML, create a folder `cookies_eu`, create a partial `_consent_banner.html.erb` and paste the HTML from [here](app/views/cookies_eu/_consent_banner.html.erb)
|
102
103
|
|
104
|
+
If you wish to run some arbitrary code when the user acknowledges the cookie message, you can register a callback. This is useful if you wish to persist the user's preference to the database.
|
105
|
+
|
106
|
+
```javascript
|
107
|
+
document.addEventListener('cookies-eu-acknowledged', function() {
|
108
|
+
// The user has acknowledged cookies! If they're logged in, make an api call
|
109
|
+
// so we remember their preference.
|
110
|
+
fetch('...');
|
111
|
+
});
|
112
|
+
```
|
113
|
+
|
103
114
|
## Cookies used
|
104
115
|
|
105
116
|
This gem uses a cookie called **cookie_eu_consented** to track whether a user has accepted the cookie notice and whether it needs to be shown again or not.
|
data/lib/cookies_eu/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: cookies_eu
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.7.
|
4
|
+
version: 1.7.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Stjepan Hadjic
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2021-07-31 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: js_cookie_rails
|
@@ -98,6 +98,7 @@ files:
|
|
98
98
|
- config/locales/sl.yml
|
99
99
|
- config/locales/sq.yml
|
100
100
|
- config/locales/sv.yml
|
101
|
+
- config/locales/tr.yml
|
101
102
|
- config/locales/ua.yml
|
102
103
|
- cookies_eu.gemspec
|
103
104
|
- lib/cookies_eu.rb
|
@@ -123,8 +124,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
123
124
|
- !ruby/object:Gem::Version
|
124
125
|
version: '0'
|
125
126
|
requirements: []
|
126
|
-
|
127
|
-
rubygems_version: 2.7.6.2
|
127
|
+
rubygems_version: 3.1.4
|
128
128
|
signing_key:
|
129
129
|
specification_version: 4
|
130
130
|
summary: Displays a cookie consent. If you dont disable cokkies in settings, we assume
|