Skip to content

Commit

Permalink
Merge pull request #2613 from luisramos0/cookies_better_policy_page
Browse files Browse the repository at this point in the history
[Cookies] Updated cookies policy page text
mkllnk authored Sep 3, 2018

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
2 parents 42afd42 + 02b968b commit 3fadd06
Showing 7 changed files with 88 additions and 145 deletions.
1 change: 1 addition & 0 deletions app/assets/stylesheets/darkswarm/branding.css.scss
Original file line number Diff line number Diff line change
@@ -25,6 +25,7 @@ $clr-blue-bright: #14b6cc;

$clr-yellow-light: #faf6c7;

$disabled-very-light: #f5f5f5;
$disabled-light: #e5e5e5;
$disabled-bright: #ccc;
$disabled-med: #b3b3b3;
11 changes: 9 additions & 2 deletions app/assets/stylesheets/darkswarm/cookies_policy_modal.css.scss
Original file line number Diff line number Diff line change
@@ -5,8 +5,15 @@
border-bottom-color: $disabled-light;

table {
display: block;
overflow-x: auto;
width: 100%;

tr:nth-of-type(even) {
background-color: $disabled-very-light;
}

p {
margin-bottom: .25rem;
}
}

&.fade {
8 changes: 8 additions & 0 deletions app/helpers/cookies_policy_helper.rb
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
module CookiesPolicyHelper
def render_cookie_entry(cookie_name, cookie_desc, cookie_domain = nil)
render partial: 'cookies_policy_entry',
locals: { cookie_name: cookie_name,
cookie_desc: cookie_desc,
cookie_domain: cookie_domain }
end
end
13 changes: 13 additions & 0 deletions app/views/angular_templates/_cookies_policy_entry.html.haml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
%tr
%td
%p
%strong
= cookie_name
%span /
= t 'legal.cookies_policy.cookie_domain'
- if cookie_domain
= cookie_domain
- else
= "{{ instance_hostname }}"
%p
= cookie_desc
188 changes: 52 additions & 136 deletions app/views/angular_templates/cookies_policy.html.haml
Original file line number Diff line number Diff line change
@@ -1,177 +1,93 @@
%h2
{{ 'legal.cookies_policy.header' | t}}
= t 'legal.cookies_policy.header'
%p
{{ 'legal.cookies_policy.desc_part_1' | t}}
= t 'legal.cookies_policy.desc_part_1'
%p
{{ 'legal.cookies_policy.desc_part_2' | t}}
= t 'legal.cookies_policy.desc_part_2'
%p
{{ 'legal.cookies_policy.desc_part_3' | t}}
= t 'legal.cookies_policy.desc_part_3'

%h2
{{ 'legal.cookies_policy.essential_cookies' | t}}
= t 'legal.cookies_policy.essential_cookies'
%p
{{ 'legal.cookies_policy.essential_cookies_desc' | t}}
= t 'legal.cookies_policy.essential_cookies_desc'

%table{ng: { controller:"CookiesPolicyModalCtrl"}}
= render_cookie_entry( "_session_id", t( "legal.cookies_policy.cookie_session_desc" ) )
= render_cookie_entry( "cookies_consent", t( "legal.cookies_policy.cookie_consent_desc" ) )
= render_cookie_entry( "remember_spree_user_token", t( "legal.cookies_policy.cookie_remember_me_desc" ) )
= render_cookie_entry( "qos_token", t( "legal.cookies_policy.cookie_openstreemap_desc" ), "openstreetmap.org" )
%tr
%th
{{ 'legal.cookies_policy.cookie_name' | t}}
%th
{{ 'legal.cookies_policy.cookie_domain' | t}}
%th
{{ 'legal.cookies_policy.cookie_desc' | t}}
%tr
%td
_session_id
%td
{{ instance_hostname }}
%td
{{ 'legal.cookies_policy.cookie_session_desc' | t}}
%tr
%td
cookies_consent
%td
{{ instance_hostname }}
%td
{{ 'legal.cookies_policy.cookie_consent_desc' | t}}
%tr
%td
remember_spree_user_token
%td
{{ instance_hostname }}
%td
{{ 'legal.cookies_policy.cookie_remember_me_desc' | t}}
%tr
%td
qos_token
%td
openstreetmap.org
%td
{{ 'legal.cookies_policy.cookie_openstreemap_desc' | t}}
%tr
%td
m
%td
m.stripe.com
%td{rowspan:"4"}
{{ 'legal.cookies_policy.cookie_stripe_desc' | t}}
%tr
%td
nsr
%td
m.stripe.network
%tr
%td
__stripe_sid
%td
{{ instance_hostname }}
%tr
%td
__stripe_mid
%td
{{ instance_hostname }}
%p
%strong m
%span /
= t 'legal.cookies_policy.cookie_domain'
= "m.stripe.com"
%p
%strong nsr
%span /
= t 'legal.cookies_policy.cookie_domain'
= "m.stripe.network"
%p
%strong __stripe_sid
%span /
= t 'legal.cookies_policy.cookie_domain'
= "{{ instance_hostname }}"
%p
%strong __stripe_mid
%span /
= t 'legal.cookies_policy.cookie_domain'
= "{{ instance_hostname }}"
%p
= t 'legal.cookies_policy.cookie_stripe_desc'
%p
{{ 'legal.cookies_policy.essential_cookies_note' | t}}
= t 'legal.cookies_policy.essential_cookies_note'

- if Spree::Config.cookies_policy_matomo_section || Spree::Config.cookies_policy_ga_section
%h2
{{ 'legal.cookies_policy.statistics_cookies' | t}}
= t 'legal.cookies_policy.statistics_cookies'
%p
{{ 'legal.cookies_policy.statistics_cookies_desc' | t}}
= t 'legal.cookies_policy.statistics_cookies_desc'

- if Spree::Config.cookies_policy_ga_section
%p
{{ 'legal.cookies_policy.statistics_cookies_analytics_desc' | t}}
= t 'legal.cookies_policy.statistics_cookies_analytics_desc_html'
- if Spree::Config.cookies_policy_matomo_section
%p
{{ 'legal.cookies_policy.statistics_cookies_matomo_desc' | t}}
= t 'legal.cookies_policy.statistics_cookies_matomo_desc_html'

%table{ng: { controller:"CookiesPolicyModalCtrl"}}
%tr
%th
{{ 'legal.cookies_policy.cookie_name' | t}}
%th
{{ 'legal.cookies_policy.cookie_domain' | t}}
%th
{{ 'legal.cookies_policy.cookie_desc' | t}}
- if Spree::Config.cookies_policy_ga_section
%tr
%td
__utma
%td
{{ instance_hostname }}
%td
{{ 'legal.cookies_policy.cookie_analytics_utma_desc' | t}}
%tr
%td
__utmt
%td
{{ instance_hostname }}
%td
{{ 'legal.cookies_policy.cookie_analytics_utmt_desc' | t}}
%tr
%td
__utmb
%td
{{ instance_hostname }}
%td
{{ 'legal.cookies_policy.cookie_analytics_utmb_desc' | t}}
%tr
%td
__utmc
%td
{{ instance_hostname }}
%td
{{ 'legal.cookies_policy.cookie_analytics_utmc_desc' | t}}
%tr
%td
__utmz
%td
{{ instance_hostname }}
%td
{{ 'legal.cookies_policy.cookie_analytics_utmz_desc' | t}}
= render_cookie_entry( "__utma", t( "legal.cookies_policy.cookie_analytics_utma_desc" ) )
= render_cookie_entry( "__utmt", t( "legal.cookies_policy.cookie_analytics_utmt_desc" ) )
= render_cookie_entry( "__utmb", t( "legal.cookies_policy.cookie_analytics_utmb_desc" ) )
= render_cookie_entry( "__utmc", t( "legal.cookies_policy.cookie_analytics_utmc_desc" ) )
= render_cookie_entry( "__utmz", t( "legal.cookies_policy.cookie_analytics_utmz_desc" ) )
- if Spree::Config.cookies_policy_matomo_section
%tr
%td
_pk_ref, _pk_cvar, _pk_id and _pk_ses
%td
{{ instance_hostname }}
%td
{{ 'legal.cookies_policy.cookie_matomo_basics_desc' | t}}
%tr
%td
_pk_hsr
%td
{{ instance_hostname }}
%td
{{ 'legal.cookies_policy.cookie_matomo_heatmap_desc' | t}}
%tr
%td
piwik_ignore
%td
{{ instance_hostname }}
%td
{{ 'legal.cookies_policy.cookie_matomo_ignore_desc' | t}}
= render_cookie_entry( "_pk_ref, _pk_cvar, _pk_id and _pk_ses", t( "legal.cookies_policy.cookie_matomo_basics_desc" ) )
= render_cookie_entry( "_pk_hsr, _pk_cvar, _pk_id and _pk_ses", t( "legal.cookies_policy.cookie_matomo_heatmap_desc" ) )
= render_cookie_entry( "piwik_ignore, _pk_cvar, _pk_id and _pk_ses", t( "legal.cookies_policy.cookie_matomo_ignore_desc" ) )

%h2
{{ 'legal.cookies_policy.disabling_cookies_header' | t}}
= t 'legal.cookies_policy.disabling_cookies_header'
%p
{{ 'legal.cookies_policy.disabling_cookies_desc' | t}}
= t 'legal.cookies_policy.disabling_cookies_desc'
%ul
%li
%a{ href: "{{'legal.cookies_policy.disabling_cookies_firefox_link' | t}}", target: "_blank" }
%a{ href: t( 'legal.cookies_policy.disabling_cookies_firefox_link' ), target: "_blank" }
Firefox
%li
%a{ href: "{{ 'legal.cookies_policy.disabling_cookies_chrome_link' | t}}", target: "_blank" }
%a{ href: t( 'legal.cookies_policy.disabling_cookies_chrome_link' ), target: "_blank" }
Chrome
%li
%a{ href: "{{ 'legal.cookies_policy.disabling_cookies_ie_link' | t}}", target: "_blank" }
%a{ href: t( 'legal.cookies_policy.disabling_cookies_ie_link' ), target: "_blank" }
Internet Explorer
%li
%a{ href: "{{ 'legal.cookies_policy.disabling_cookies_safari_link' | t}}", target: "_blank" }
%a{ href: t( 'legal.cookies_policy.disabling_cookies_safari_link' ), target: "_blank" }
Safari
%p
{{ 'legal.cookies_policy.disabling_cookies_note' | t}}
= t 'legal.cookies_policy.disabling_cookies_note'

%a.close-reveal-modal{"ng-click" => "$close()"}
%i.ofn-i_009-close
10 changes: 4 additions & 6 deletions config/locales/en.yml
Original file line number Diff line number Diff line change
@@ -1289,18 +1289,16 @@ en:
essential_cookies: "Essential Cookies"
essential_cookies_desc: "The following cookies are strictly necessary for the operation of our website."
essential_cookies_note: "Most cookies only contain a unique identifier, but no other data, so your email address and password for instance are never contained in them and never exposed."
cookie_name: "Cookie Name"
cookie_domain: "Set By"
cookie_desc: "Description"
cookie_domain: "Set By:"
cookie_session_desc: "Used to allow the website to remember users between page visits, for example, remember items in your cart."
cookie_consent_desc: "Used to maintain status of user consent to store cookies"
cookie_remember_me_desc: "Used if the user has requested the website to remember him. This cookie is automatically deleted after 12 days. If as a user you want that cookie to be deleted, you only need to logout. If you don’t want that cookie to be installed on your computer you shouldn’t check the “remember me” checkbox when logging in."
cookie_openstreemap_desc: "Used by our friendly open source mapping provider (OpenStreetMap) to ensure that it does not receive too many requests during a given time period, to prevent abuse of their services."
cookie_stripe_desc: "Data collected by our payment processor Stripe for fraud detection https://stripe.com/cookies-policy/legal. Not all shops use Stripe as a payment method but it is a good practice to prevent fraud to apply it to all pages. Stripe probably build a picture of which of our pages usually interact with their API and then flag anything unusual. So setting the Stripe cookie has a broader function than simply the provision of a payment method to a user. Removing it could affect the security of the service itself. You can learn more about Stripe and read its privacy policy at https://stripe.com/privacy."
statistics_cookies: "Statistics Cookies"
statistics_cookies_desc: "The following are not Strictly Necessary, but help to provide you with the best user experience by allowing us to analyse user behaviour, identify which features you use most, or don’t use, understand user experience issues, etc."
statistics_cookies_analytics_desc: "We use Google Analytics, as it was the default service connected with Spree (the e-commerce open source software that we built on) but our vision is to switch to Matomo (ex Piwik, open source analytics tool) as soon as we can."
statistics_cookies_matomo_desc: "We use Matomo (ex Piwik), an open source analytics tool."
statistics_cookies_desc: "The following are not strictly necessary, but help to provide you with the best user experience by allowing us to analyse user behaviour, identify which features you use most, or don’t use, understand user experience issues, etc."
statistics_cookies_analytics_desc_html: "To collect and analyse platform usage data, we use Google Analytics, as it was the default service connected with Spree (the e-commerce open source software that we built on) but our vision is to switch to <a href='https://matomo.org/' target='_blank'>Matomo</a> (ex Piwik, open source analytics tool that is GDPR compliant and protects your privacy) as soon as we can."
statistics_cookies_matomo_desc_html: "To collect and analyse platform usage data, we use <a href='https://matomo.org/' target='_blank'>Matomo</a> (ex Piwik), an open source analytics tool that is GDPR compliant and protects your privacy."
cookie_analytics_utma_desc: "Used to distinguish users and sessions. The cookie is created when the javascript library executes and no existing __utma cookies exists. The cookie is updated every time data is sent to Google Analytics."
cookie_analytics_utmt_desc: "Used to throttle request rate."
cookie_analytics_utmb_desc: "Used to determine new sessions/visits. The cookie is created when the javascript library executes and no existing __utmb cookies exists. The cookie is updated every time data is sent to Google Analytics."
2 changes: 1 addition & 1 deletion spec/features/consumer/cookies_spec.rb
Original file line number Diff line number Diff line change
@@ -76,7 +76,7 @@
end

def matomo_description_text
I18n.t('legal.cookies_policy.statistics_cookies_matomo_desc')
I18n.t('legal.cookies_policy.cookie_matomo_basics_desc')
end

def expect_visible_cookies_policy_page

0 comments on commit 3fadd06

Please sign in to comment.