gdpr 0.1.0 → 1.0.0
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/LICENSE +21 -0
- data/README.md +19 -5
- data/app/assets/javascripts/gdpr.js +7 -0
- data/app/assets/stylesheets/gdpr.sass +8 -8
- data/app/views/gdpr/_cookie_consent.html.erb +11 -0
- data/config/locales/en.yml +7 -0
- data/config/locales/fr.yml +7 -0
- data/lib/gdpr.rb +4 -0
- data/lib/gdpr/engine.rb +5 -0
- data/lib/gdpr/version.rb +1 -1
- metadata +8 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d30ad7478790233bf21437ff952934f735b5248f
|
4
|
+
data.tar.gz: 5aa340f73a302342ef5042e5f63afb36beb2b27e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f5786697702cb52655ca25a66bd836791b7462bd6368698bcc85b9a6db88ec3b16e0ffcebcd7068fad8928cfef2d5a3052743a31466f99ef6e8a781af428e31d
|
7
|
+
data.tar.gz: a0431329c78ede616fe17d98828f660b1a80615cb28d4a5647e228a1c64c0653813e2f75894d3b89fa31e77109b7e19740d71b384931b94f4ee6ce0c6efd69d3
|
data/LICENSE
ADDED
@@ -0,0 +1,21 @@
|
|
1
|
+
MIT License
|
2
|
+
|
3
|
+
Copyright (c) 2018 Les Poupées Russes
|
4
|
+
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
7
|
+
in the Software without restriction, including without limitation the rights
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
10
|
+
furnished to do so, subject to the following conditions:
|
11
|
+
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
13
|
+
copies or substantial portions of the Software.
|
14
|
+
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
21
|
+
SOFTWARE.
|
data/README.md
CHANGED
@@ -1,8 +1,5 @@
|
|
1
|
-
#
|
2
|
-
|
3
|
-
|
4
|
-
## Usage
|
5
|
-
How to use my plugin.
|
1
|
+
# GDPR
|
2
|
+
Helps getting your Rails app GDPR compliant
|
6
3
|
|
7
4
|
## Installation
|
8
5
|
Add this line to your application's Gemfile:
|
@@ -21,8 +18,25 @@ Or install it yourself as:
|
|
21
18
|
$ gem install gdpr
|
22
19
|
```
|
23
20
|
|
21
|
+
Add this to layout:
|
22
|
+
```ruby
|
23
|
+
<%= render 'gdpr/cookie_consent' %>
|
24
|
+
```
|
25
|
+
|
26
|
+
Add this to javascripts:
|
27
|
+
```js
|
28
|
+
//= require gdpr
|
29
|
+
```
|
30
|
+
|
31
|
+
Add this to stylesheets:
|
32
|
+
```sass
|
33
|
+
@import 'gdpr'
|
34
|
+
```
|
35
|
+
|
24
36
|
## Checklist
|
25
37
|
|
38
|
+
https://www.eugdpr.org/
|
39
|
+
|
26
40
|
[x] Cookie consent
|
27
41
|
[ ] Privacy policy
|
28
42
|
[ ] Optin must exist, and must not be checked by default
|
@@ -1,4 +1,4 @@
|
|
1
|
-
.
|
1
|
+
.gdpr__cookie_consent
|
2
2
|
position: fixed
|
3
3
|
z-index: 999
|
4
4
|
right: 0
|
@@ -6,28 +6,28 @@
|
|
6
6
|
left: 0
|
7
7
|
padding: 0 20px
|
8
8
|
text-align: center
|
9
|
-
border-top: 1px solid
|
9
|
+
border-top: 1px solid #ccc
|
10
10
|
background: #fff
|
11
11
|
|
12
|
-
|
12
|
+
@media only screen and (max-width : 480px)
|
13
13
|
font-size: 12px
|
14
14
|
position: initial
|
15
15
|
|
16
|
-
|
16
|
+
&__text
|
17
17
|
display: inline-block
|
18
18
|
padding: 20px 160px
|
19
19
|
|
20
|
-
|
20
|
+
@media only screen and (max-width : 480px)
|
21
21
|
padding: 20px 0
|
22
22
|
|
23
|
-
|
23
|
+
&__buttons
|
24
24
|
position: absolute
|
25
25
|
right: 10px
|
26
26
|
top: 12px
|
27
27
|
|
28
|
-
|
28
|
+
@media only screen and (max-width : 480px)
|
29
29
|
position: initial
|
30
30
|
margin-bottom: 10px
|
31
31
|
|
32
|
-
|
32
|
+
&__ok
|
33
33
|
padding: 15px 21px 15px !important
|
@@ -0,0 +1,11 @@
|
|
1
|
+
<% if cookies && cookies['gdpr.cookie_consent.ok'] != 'true' %>
|
2
|
+
<div class="gdpr__cookie_consent js-gdpr__cookie_consent">
|
3
|
+
<div class="gdpr__cookie_consent__text">
|
4
|
+
<%= t('gdpr.cookie_consent.text') %>
|
5
|
+
<%= t('gdpr.cookie_consent.learn_more_html', link: t('gdpr.privacy_policy')) %>
|
6
|
+
</div>
|
7
|
+
<div class="gdpr__cookie_consent__buttons">
|
8
|
+
<button class="gdpr__cookie_consent__buttons__ok"> <%= t('gdpr.cookie_consent.btn_ok') %></button>
|
9
|
+
</div>
|
10
|
+
</div>
|
11
|
+
<% end %>
|
@@ -0,0 +1,7 @@
|
|
1
|
+
en:
|
2
|
+
gdpr:
|
3
|
+
privacy_policy: https://www.eugdpr.org
|
4
|
+
cookie_consent:
|
5
|
+
text: 'By navigating on this website, you agree to our use of cookies to personalize certain website features and to measure the audience and use of this website.'
|
6
|
+
button: "I agree"
|
7
|
+
learn_more_html: "To learn more about cookies and how to customize your cookies options: <a href=\"%{link}\" target=\"_blank\">click here</a>"
|
@@ -0,0 +1,7 @@
|
|
1
|
+
fr:
|
2
|
+
gdpr:
|
3
|
+
privacy_policy: https://www.eugdpr.org
|
4
|
+
cookie_consent:
|
5
|
+
text: "En poursuivant votre navigation sur ce site, vous acceptez l’utilisation de Cookies pour vous proposer notamment des fonctionnalités personnalisées et pour réaliser des mesures d’audience."
|
6
|
+
button: "J'ai compris"
|
7
|
+
learn_more_html: "Pour en savoir plus et paramétrer ces cookies : <a href=\"%{link}\" target=\"_blank\">cliquer ici</a>"
|
data/lib/gdpr.rb
CHANGED
data/lib/gdpr/engine.rb
ADDED
data/lib/gdpr/version.rb
CHANGED
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: gdpr
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Arnaud Levy
|
@@ -59,10 +59,16 @@ executables: []
|
|
59
59
|
extensions: []
|
60
60
|
extra_rdoc_files: []
|
61
61
|
files:
|
62
|
+
- LICENSE
|
62
63
|
- README.md
|
63
64
|
- Rakefile
|
65
|
+
- app/assets/javascripts/gdpr.js
|
64
66
|
- app/assets/stylesheets/gdpr.sass
|
67
|
+
- app/views/gdpr/_cookie_consent.html.erb
|
68
|
+
- config/locales/en.yml
|
69
|
+
- config/locales/fr.yml
|
65
70
|
- lib/gdpr.rb
|
71
|
+
- lib/gdpr/engine.rb
|
66
72
|
- lib/gdpr/version.rb
|
67
73
|
- lib/tasks/gdpr_tasks.rake
|
68
74
|
homepage: https://github.com/lespoupeesrusses/gdpr
|
@@ -72,7 +78,7 @@ metadata: {}
|
|
72
78
|
post_install_message:
|
73
79
|
rdoc_options: []
|
74
80
|
require_paths:
|
75
|
-
-
|
81
|
+
- "./app/assets/stylesheets"
|
76
82
|
required_ruby_version: !ruby/object:Gem::Requirement
|
77
83
|
requirements:
|
78
84
|
- - ">="
|