From a31262838392e2ae9eee8972c932510b4f59d202 Mon Sep 17 00:00:00 2001 From: Simon Lehericey Date: Wed, 10 May 2017 15:44:47 +0200 Subject: [PATCH] Newsletter: add mailjet widget --- app/views/layouts/_mailjet_newsletter.html.haml | 2 ++ app/views/layouts/_new_footer.html.haml | 2 ++ app/views/layouts/new_application.html.haml | 1 + 3 files changed, 5 insertions(+) create mode 100644 app/views/layouts/_mailjet_newsletter.html.haml diff --git a/app/views/layouts/_mailjet_newsletter.html.haml b/app/views/layouts/_mailjet_newsletter.html.haml new file mode 100644 index 000000000..d99e0c794 --- /dev/null +++ b/app/views/layouts/_mailjet_newsletter.html.haml @@ -0,0 +1,2 @@ +%data.mj-w-data{ "data-apikey" => "1v5T", "data-base" => "http://app.mailjet.com", "data-height" => "328", "data-lang" => "fr_FR", "data-statics" => "statics", "data-token" => "11c89e7ddb46fbcdcb7f8fe5fdfca818", "data-w-id" => "39b", "data-width" => "640" } +%script{ src: 'http://app.mailjet.com/statics/js/widget.modal.js' } diff --git a/app/views/layouts/_new_footer.html.haml b/app/views/layouts/_new_footer.html.haml index 806541020..4bcc09bc8 100644 --- a/app/views/layouts/_new_footer.html.haml +++ b/app/views/layouts/_new_footer.html.haml @@ -25,6 +25,8 @@ %li.footer-column %ul.footer-links + %li.footer-link + %a{ href: '#', 'data-token' => '11c89e7ddb46fbcdcb7f8fe5fdfca818', onclick: 'mjOpenPopin(event, this)' } Newsletter %li.footer-link = link_to "Contact", "mailto:#{t('dynamics.contact_email')}", diff --git a/app/views/layouts/new_application.html.haml b/app/views/layouts/new_application.html.haml index 5310f24cf..ba6539661 100644 --- a/app/views/layouts/new_application.html.haml +++ b/app/views/layouts/new_application.html.haml @@ -33,6 +33,7 @@ = render partial: "layouts/new_footer" = render partial: "layouts/google_analytics" + = render partial: "layouts/mailjet_newsletter" = javascript_include_tag "application", "data-turbolinks-track" => true - if Rails.env == "test"