Skip to content

Commit

Permalink
Merge pull request #1427 from mozilla/remove-old-scan-page
Browse files Browse the repository at this point in the history
Remove old scan page.
  • Loading branch information
groovecoder authored Dec 4, 2019
2 parents fc11f99 + 39050e4 commit 4647f72
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 34 deletions.
4 changes: 1 addition & 3 deletions public/js/fxa-analytics.js
Original file line number Diff line number Diff line change
Expand Up @@ -115,9 +115,7 @@ function getUTMNames() {
ga("create", "UA-77033033-16");
ga("set", "anonymizeIp", true);
ga("set", "transport", "beacon");
if (document.getElementById("new-scan-page")) {
ga("set", "dimension5", "newScanPage");
}

ga("send", "pageview", {
hitCallback: function() {
removeUtmsFromUrl();
Expand Down
2 changes: 0 additions & 2 deletions scan-results.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,6 @@ const scanResult = async(req, selfScan=false) => {
}
}

const newScanPage = ((Math.random() * 10) >= 5);

return {
title,
Expand All @@ -99,7 +98,6 @@ const scanResult = async(req, selfScan=false) => {
fullReport,
userDash,
scannedEmailId,
newScanPage,
};
};

Expand Down
41 changes: 12 additions & 29 deletions views/scan.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -14,15 +14,9 @@
{{/getScanResultsHeadline}}
{{else}}
<h2 class="headline scan-results-headline">{{{ fluentNestedBold "scan-results-known-breaches" breachCount=foundBreaches.length }}}</h2>
{{#if newScanPage}} <!-- New trial UI for testing call to actions -->
<button id="new-scan-page" class="open-oauth blue-link temp-marketing-alert-me-link" {{> analytics/fxa id="fx-monitor-alert-me-blue-link" }} data-event-category="Alert me about new breaches">
{{ getString "alert-about-new-breaches" }}
</button>
{{else}}
<button class="btn-violet-secondary open-oauth btn-small btn-transparent" {{> analytics/fxa id="fx-monitor-alert-me-btn" }} data-event-category="Alert me about new breaches">
{{ getString "alert-about-new-breaches" }}
</button>
{{/if}}
{{/if}}
</div>
</div>
Expand All @@ -41,27 +35,16 @@
</div>
</main>
<section>
{{#if newScanPage}} <!-- New trial UI for testing call to actions -->
<div class="row txt-cntr jst-cntr flx-col temp-marketing-callout">
<img class="temp-marketing-img" src="img/svg/stay-alert.svg" alt="" />
<h2 class="temp-marketing-hl mw-360">{{ getString "stay-alert" }}</h2>
<p class="temp-marketing-p mw-360">{{ getString "if-your-info" }}</p>
<!--
the `data-event-category` attribute for this button is "Alert me about new breaches - Banner"
to match the "Alert me.." button on the other version of the scan results page and to make comparisons
between this button and the "Alert me.." button on the other version of the scan results page easier
-->
<button class="open-oauth temp-marketing-btn-blue" {{> analytics/fxa id="fx-monitor-alert-me-blue-btn" }} data-event-category="Alert me about new breaches - Banner">{{ getString "alert-about-new-breaches" }}</button>
{{> sign-up-banners/browser-not-required }}
</div>
{{else}}
<div class="row jst-cntr flx-col">
{{> scan-another-email addClass="stacked"}}
</div>
<div class="fxa-signup-gradient">
<div class="row fxa-signup-banner scan-res">
{{> sign-up-banners/scan-results-sign-up }}
</div>
</div>
{{/if}}
<div class="row txt-cntr jst-cntr flx-col temp-marketing-callout">
<img class="temp-marketing-img" src="img/svg/stay-alert.svg" alt="" />
<h2 class="temp-marketing-hl mw-360">{{ getString "stay-alert" }}</h2>
<p class="temp-marketing-p mw-360">{{ getString "if-your-info" }}</p>
<!--
the `data-event-category` attribute for this button is "Alert me about new breaches - Banner"
to match the "Alert me.." button on the other version of the scan results page and to make comparisons
between this button and the "Alert me.." button on the other version of the scan results page easier
-->
<button class="open-oauth temp-marketing-btn-blue" {{> analytics/fxa id="fx-monitor-alert-me-blue-btn" }} data-event-category="Alert me about new breaches - Banner">{{ getString "alert-about-new-breaches" }}</button>
{{> sign-up-banners/browser-not-required }}
</div>
</section>

0 comments on commit 4647f72

Please sign in to comment.