forked from mozilla/bedrock
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add WNP for Firefox 104 for es-ES, it, and pl [mozilla#12015]
- Loading branch information
Showing
10 changed files
with
238 additions
and
0 deletions.
There are no files selected for viewing
10 changes: 10 additions & 0 deletions
10
bedrock/firefox/templates/firefox/whatsnew/includes/fx104/tcp.html
Large diffs are not rendered by default.
Oops, something went wrong.
37 changes: 37 additions & 0 deletions
37
bedrock/firefox/templates/firefox/whatsnew/whatsnew-fx104-default.html
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
{# | ||
This Source Code Form is subject to the terms of the Mozilla Public | ||
License, v. 2.0. If a copy of the MPL was not distributed with this | ||
file, You can obtain one at https://mozilla.org/MPL/2.0/. | ||
#} | ||
|
||
{% extends "firefox/whatsnew/base.html" %} | ||
|
||
{% block page_title %}{{ ftl('whatsnew-page-title') }}{% endblock %} | ||
{% block page_desc %}{{ ftl('whatsnew-page-description') }}{% endblock %} | ||
|
||
{% block page_css %} | ||
{{ css_bundle('firefox_whatsnew_104_default') }} | ||
{% endblock %} | ||
|
||
{% block site_header %}{% endblock %} | ||
|
||
{% block wnp_content %} | ||
<section class="wnp-content-main mzp-l-content mzp-t-content-md"> | ||
<h2 class="wnp-main-title">{{ ftl('whatsnew-104-default-title') }}</h2> | ||
{% include 'firefox/whatsnew/includes/fx104/tcp.html' %} | ||
<p class="wnp-main-tagline">{{ ftl('whatsnew-104-default-body') }}</p> | ||
<p class="wnp-main-cta"> | ||
<a class="mzp-c-button mzp-t-product" href="{{ url('firefox.set-as-default.thanks') }}" data-cta-text="Make Firefox your default browser" data-cta-type="button"> | ||
{{ ftl('whatsnew-104-default-cta') }} | ||
</a> | ||
</p> | ||
<div class="wnp-alt-msg"> | ||
<p><strong>{{ ftl('whatsnew-104-default-all-set') }}</strong></p> | ||
</div> | ||
</section> | ||
{% endblock %} | ||
|
||
{% block js %} | ||
{{ js_bundle('firefox_whatsnew') }} | ||
{{ js_bundle('firefox_whatsnew_104_default') }} | ||
{% endblock %} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
# This Source Code Form is subject to the terms of the Mozilla Public | ||
# License, v. 2.0. If a copy of the MPL was not distributed with this | ||
# file, You can obtain one at https://mozilla.org/MPL/2.0/. | ||
|
||
### URL: https://www-dev.allizom.org/firefox/104.0/whatsnew/ | ||
|
||
whatsnew-104-default-title = Feel safe every time you explore the web | ||
whatsnew-104-default-body = { -brand-name-firefox } is rolling out its strongest privacy protection to date: Total Cookie Protection confines cookies to the sites where they originated, preventing tracking companies from using them to follow you as you browse from site to site. { -brand-name-firefox } will always advocate and innovate for your privacy. | ||
whatsnew-104-default-cta = Make { -brand-name-firefox } your default browser | ||
# "You're all set" means everything is ready, you don't need to do anything more. | ||
whatsnew-104-default-all-set = You’re all set with { -brand-name-firefox } as your default browser. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,83 @@ | ||
// This Source Code Form is subject to the terms of the Mozilla Public | ||
// License, v. 2.0. If a copy of the MPL was not distributed with this | ||
// file, You can obtain one at https://mozilla.org/MPL/2.0/. | ||
|
||
$font-path: '/media/protocol/fonts'; | ||
$image-path: '/media/protocol/img'; | ||
|
||
@import '~@mozilla-protocol/core/protocol/css/components/notification-bar'; | ||
@import '~@mozilla-protocol/core/protocol/css/includes/lib'; | ||
@import 'includes/base'; | ||
@import 'includes/dark-mode'; | ||
|
||
// * -------------------------------------------------------------------------- */ | ||
// Main content | ||
.wnp-content-main { | ||
padding-top: $spacing-md; | ||
text-align: center; | ||
} | ||
|
||
.wnp-main-title { | ||
@include text-title-xl; | ||
} | ||
|
||
.wnp-main-img { | ||
max-width: $content-md; | ||
margin: $spacing-xl auto; | ||
|
||
svg { | ||
width: 100%; | ||
height: auto; | ||
} | ||
} | ||
|
||
.wnp-main-tagline { | ||
@include text-body-lg; | ||
text-align: left; | ||
} | ||
|
||
.wnp-main-cta { | ||
margin-top: $spacing-xl; | ||
|
||
&.hide { | ||
display: none; | ||
} | ||
|
||
.mzp-c-button { | ||
@include text-body-lg; | ||
} | ||
} | ||
|
||
.wnp-alt-msg { | ||
@include text-body-lg; | ||
display: none; | ||
margin-top: $spacing-xl; | ||
|
||
&.show { | ||
display: block; | ||
} | ||
|
||
@media #{$mq-md} { | ||
strong { | ||
display: inline-block; | ||
|
||
&::after { | ||
content: ''; | ||
background-image: url('/media/img/firefox/whatsnew/whatsnew104/orange-check.svg'); | ||
background-repeat: no-repeat; | ||
height: 25px; | ||
width: 25px; | ||
display: inline-block; | ||
margin: 0 0 -6px 6px; | ||
} | ||
} | ||
} | ||
} | ||
|
||
// * -------------------------------------------------------------------------- */ | ||
// For dark mode | ||
@media (prefers-color-scheme: dark) { | ||
.wnp-main-title { | ||
color: get-theme('title-text-color-inverse'); | ||
} | ||
} |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
/* | ||
* This Source Code Form is subject to the terms of the Mozilla Public | ||
* License, v. 2.0. If a copy of the MPL was not distributed with this | ||
* file, You can obtain one at https://mozilla.org/MPL/2.0/. | ||
*/ | ||
|
||
function isDefaultBrowser() { | ||
'use strict'; | ||
return new window.Promise(function (resolve, reject) { | ||
window.Mozilla.UITour.getConfiguration('appinfo', function (details) { | ||
if (details.defaultBrowser) { | ||
resolve(); | ||
} else { | ||
reject(); | ||
} | ||
}); | ||
}); | ||
} | ||
|
||
function init() { | ||
'use strict'; | ||
|
||
isDefaultBrowser() | ||
.then(function () { | ||
document.querySelector('.wnp-main-cta').classList.add('hide'); | ||
document.querySelector('.wnp-alt-msg').classList.add('show'); | ||
|
||
window.dataLayer.push({ | ||
event: 'non-interaction', | ||
eAction: 'whatsnew-104', | ||
eLabel: 'firefox-default' | ||
}); | ||
}) | ||
.catch(function () { | ||
window.dataLayer.push({ | ||
event: 'non-interaction', | ||
eAction: 'whatsnew-104', | ||
eLabel: 'firefox-not-default' | ||
}); | ||
}); | ||
} | ||
|
||
if ( | ||
typeof window.Mozilla.Client !== 'undefined' && | ||
typeof window.Mozilla.UITour !== 'undefined' && | ||
window.Mozilla.Client.isFirefoxDesktop | ||
) { | ||
init(); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters