From e735b5f3e0b1879f15084f18230cddbeeebe760e Mon Sep 17 00:00:00 2001 From: Pavel Dohnal Date: Wed, 12 Jul 2017 08:44:04 +0100 Subject: [PATCH 1/8] Replace title [MAILPOET-979] --- views/update.html | 7 +++++-- views/welcome.html | 7 +++++-- 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/views/update.html b/views/update.html index e373fff267..545d101f17 100644 --- a/views/update.html +++ b/views/update.html @@ -10,9 +10,12 @@
-

<%= __('Welcome to MailPoet') %> <%= settings.version %>

+

<%= __('Greetings, humans.') %>

-

<%= __("Thank you for helping us test and improve this new version of MailPoet. You're one of our extra-special beta testers. We really appreciate your help!") %> +

<%= __("Thanks for using MailPoet! We really appreciate all of your love, affection, [link]and (good) plugin reviews.[/link]") + |replaceLinkTags('https://wordpress.org/support/plugin/wysija-newsletters/reviews/', {'target' : '_blank'}) + |raw + %>

diff --git a/views/welcome.html b/views/welcome.html index cb80c8a807..0202871ba9 100644 --- a/views/welcome.html +++ b/views/welcome.html @@ -19,9 +19,12 @@
-

<%= __('Welcome to MailPoet') %> <%= settings.version %>

+

<%= __('Greetings, humans.') %>

-

<%= __("Thank you for helping us test and improve this new version of MailPoet. You're one of our extra-special beta testers. We really appreciate your help!") %> +

<%= __("Thanks for using MailPoet! We really appreciate all of your love, affection, [link]and (good) plugin reviews.[/link]") + |replaceLinkTags('https://wordpress.org/support/plugin/wysija-newsletters/reviews/', {'target' : '_blank'}) + |raw + %>

From 1823985172b8a86c465084c7b6368199257eacaa Mon Sep 17 00:00:00 2001 From: Pavel Dohnal Date: Wed, 12 Jul 2017 09:19:22 +0100 Subject: [PATCH 2/8] Display only one set of changelog [MAILPOET-979] --- lib/Config/Menu.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/Config/Menu.php b/lib/Config/Menu.php index 2abb4bb8b9..2edcc1d5b1 100644 --- a/lib/Config/Menu.php +++ b/lib/Config/Menu.php @@ -340,7 +340,7 @@ class Menu { $readme_file = Env::$path . '/readme.txt'; if(is_readable($readme_file)) { - $changelog = Readme::parseChangelog(file_get_contents($readme_file), 2); + $changelog = Readme::parseChangelog(file_get_contents($readme_file), 1); if($changelog) { $data['changelog'] = $changelog; } From 8a7ea791b0b14a37b25ba7039f9e9c5d4bdbc3d7 Mon Sep 17 00:00:00 2001 From: Pavel Dohnal Date: Wed, 12 Jul 2017 09:35:10 +0100 Subject: [PATCH 3/8] Move button to see all changelogs [MAILPOET-979] --- views/update.html | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/views/update.html b/views/update.html index 545d101f17..9c789b86a8 100644 --- a/views/update.html +++ b/views/update.html @@ -24,7 +24,7 @@ <%= __("What's New") %> -
+

<%= __("List of Changes") %>

<% if changelog %> <% for item in changelog %> @@ -39,13 +39,13 @@ <% else %>

<%= __("See readme.txt for a changelog.") %>

<% endif %> + <%= __("View all changes") %> →

From 65f4f493f1b9e6b3a076cb295350531ded2dc493 Mon Sep 17 00:00:00 2001 From: Pavel Dohnal Date: Wed, 12 Jul 2017 10:09:17 +0100 Subject: [PATCH 4/8] Add sharing section [MAILPOET-979] --- views/update.html | 38 +++++++++++++++++++++++++++++++++++++- 1 file changed, 37 insertions(+), 1 deletion(-) diff --git a/views/update.html b/views/update.html index 9c789b86a8..7d80c1f846 100644 --- a/views/update.html +++ b/views/update.html @@ -44,7 +44,24 @@
-
+ <% if(not settings.analytics.enabled) %> +
+

<%= __("Do Your Part to Make MailPoet Better") %>

+

+ +

<%= __("By sharing your data with us, you can help us understand what our users like (and don't like).") %> + <%= __("We use it to prioritize and develop new plugin features.") %>
+ <%= __("Share your data to help shape the future of MailPoet! [link]Read more.[/link]") + |replaceLinkTags('http://docs.mailpoet.com/article/36-share-your-data', {'target' : '_blank'}) + |raw + %> +

+ <% endif %> + + @@ -59,7 +76,26 @@ {'MailPoet Free version': window.mailpoet_version} ); }); + $("#mailpoet_analytics_enabled").on("click", function() { + var is_enabled = $(this).is(":checked") ? true : ""; + MailPoet.Ajax.post({ + api_version: window.mailpoet_api_version, + endpoint: "settings", + action: "set", + data: { + analytics: { enabled: (is_enabled)} + } + }).fail((response) => { + if (response.errors.length > 0) { + MailPoet.Notice.error( + response.errors.map((error) => { return error.message; }), + { scroll: true } + ); + } + }); + }) }); + <% endblock %> From c01b57a3833c1c38ea5e6ca0d856245bd251ee3d Mon Sep 17 00:00:00 2001 From: Pavel Dohnal Date: Wed, 12 Jul 2017 10:28:35 +0100 Subject: [PATCH 5/8] Add poll [MAILPOET-979] --- views/update.html | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/views/update.html b/views/update.html index 7d80c1f846..546896001a 100644 --- a/views/update.html +++ b/views/update.html @@ -59,12 +59,24 @@ |raw %>
+ +
<% endif %> + +
+ + +
From 0554a84f774dff85456e5a288bc30540bc1db0ef Mon Sep 17 00:00:00 2001 From: Pavel Dohnal Date: Wed, 12 Jul 2017 13:38:56 +0100 Subject: [PATCH 6/8] Apply new styles [MAILPOET-979] --- assets/css/src/pages.styl | 15 +++++++++++++++ views/update.html | 14 +++++++------- 2 files changed, 22 insertions(+), 7 deletions(-) diff --git a/assets/css/src/pages.styl b/assets/css/src/pages.styl index 5573d2d813..5917c6da46 100644 --- a/assets/css/src/pages.styl +++ b/assets/css/src/pages.styl @@ -117,6 +117,21 @@ About page styles that may differ across WP versions. h3 margin-top: 0 + .feature-section + &.one-col + width: 700px + margin: 0 auto + text-align: center + & > a.button + margin-top: 2em + &.one-col-left + width: 700px + margin: 0 auto + h2.mailpoet-feature-top + margin: 50px auto + .lead-description ~ p + margin-top: 3em + .feature-section h4 margin: 1.4em 0 0.6em 0 diff --git a/views/update.html b/views/update.html index 546896001a..8cd5599d5d 100644 --- a/views/update.html +++ b/views/update.html @@ -24,8 +24,8 @@ <%= __("What's New") %> -
-

<%= __("List of Changes") %>

+
+

<%= __("List of Changes") %>

<% if changelog %> <% for item in changelog %>

<%= item.version %>

@@ -34,7 +34,6 @@
  • <%= change %>
  • <% endfor %> -
    <% endfor %> <% else %>

    <%= __("See readme.txt for a changelog.") %>

    @@ -47,12 +46,13 @@ <% if(not settings.analytics.enabled) %>

    <%= __("Do Your Part to Make MailPoet Better") %>

    -

    +

    -

    <%= __("By sharing your data with us, you can help us understand what our users like (and don't like).") %> +

    +

    <%= __("By sharing your data with us, you can help us understand what our users like (and don't like).") %> <%= __("We use it to prioritize and develop new plugin features.") %>
    <%= __("Share your data to help shape the future of MailPoet! [link]Read more.[/link]") |replaceLinkTags('http://docs.mailpoet.com/article/36-share-your-data', {'target' : '_blank'}) @@ -74,8 +74,8 @@


    + <%= __("Awesome! Now, take me to MailPoet") %> → +
    From 88d59526844779e326adf6c4e106e62e7edbe6fa Mon Sep 17 00:00:00 2001 From: Pavel Dohnal Date: Wed, 12 Jul 2017 14:55:53 +0100 Subject: [PATCH 7/8] Remove duplicate id [MAILPOET-979] --- views/update.html | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/views/update.html b/views/update.html index 8cd5599d5d..3758ed546b 100644 --- a/views/update.html +++ b/views/update.html @@ -44,9 +44,10 @@
    <% if(not settings.analytics.enabled) %> -
    +

    <%= __("Do Your Part to Make MailPoet Better") %>

    +