Skip to content

Commit

Permalink
Add CTD pages in ES, IT, and PL [fix #14264] (#14306)
Browse files Browse the repository at this point in the history
* Add CTD pages in ES, IT, and PL [fix #14264]
* Move German CTD page to new URL [fix #14266]
  • Loading branch information
craigcook committed Mar 13, 2024
1 parent 1f38655 commit 48d8f0d
Show file tree
Hide file tree
Showing 19 changed files with 283 additions and 93 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ <h1>{{ hero_head|safe }}</h1>
{{ cta_group('hero') }}
</div>
</div>
{% if LANG != "fr" %}
{% if LANG == "de" %}
{{ picture(
url='img/firefox/challenge-the-default/hero-image-mobile.png',
sources=[
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -362,12 +362,14 @@ <h3>{{ cred_private_title }}</h3>
</summary>
<p>{{ cred_private_body }}</p>
</details>
{% if cred_ethical_title %}
<details class="mzp-c-details">
<summary>
<h3>{{ cred_ethical_title }}</h3>
</summary>
<p>{{ cred_ethical_body }}</p>
</details>
{% endif %}
<details class="mzp-c-details">
<summary>
<h3>{{ cred_change_title }}</h3>
Expand All @@ -380,6 +382,7 @@ <h3>{{ cred_community_title }}</h3>
</summary>
<p>{{ cred_community_body }}</p>
</details>

</div>
</section>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,14 @@
{% if switch('challenge-the-default-active') %}
{% if LANG == 'de' %}
{% include 'firefox/challenge-the-default/langs/landing.de.html' %}
{% elif LANG == 'es-ES' %}
{% include 'firefox/challenge-the-default/langs/landing.es-ES.html' %}
{% elif LANG == 'fr' %}
{% include 'firefox/challenge-the-default/langs/landing.fr.html' %}
{% elif LANG == 'it' %}
{% include 'firefox/challenge-the-default/langs/landing.it.html' %}
{% elif LANG == 'pl' %}
{% include 'firefox/challenge-the-default/langs/landing.pl.html' %}
{% endif %}
{% else %}
{% include 'firefox/home/index-master.html' %}
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
{#
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/challenge-the-default/landing-base.html" %}

{% block page_image %}{{ static('img/firefox/challenge-the-default/ctd-share-es.png') }}{% endblock %}

{% set seo_desc = 'Cuando eliges Firefox, estás tomando una decisión consciente. Mejor protección de datos, más transparencia y una web más sana.' %}
{% set cta_default = 'Configura Firefox como tu navegador por defecto' %}
{% set cta_mobile = 'Descubre Firefox para móvil' %}
{% set cta_download = 'Elige Firefox' %}
{% set hero_alt = 'Cambia la norma' %}
{% set hero_egg = 'Llegaste al final. ¡Bien hecho!' %}
{% set hero_head = 'Elige un navegador diseñado <span class="icon-firefox"></span> pensando en ti' %}
{% set hero_text_ff = 'A decir verdad, este es un lugar para promocionar Firefox. Como tú ya lo estás usando, te vamos a contar un secreto en su lugar: hemos escondido unas cuantas sorpresas en esta página. Haz clic por aquí a ver qué encuentras.' %}
{% set hero_text_not_ff = 'Cuando eliges Firefox, estás tomando una decisión consciente. Mejor protección de datos, más transparencia y una web más sana.' %}

{% set features_head = 'Nuestras<br> funcionalidades favoritas' %}
{% set features_browsing_title = 'Navegación fluida' %}
{% set features_browsing_body = 'Mantén pestañas abiertas y contraseñas a mano en todos tus dispositivos, si así lo quieres.' %}
{% set features_multi_title = 'Multitarea sencilla' %}
{% set features_multi_body = 'Sigue viendo tus vídeos en una ventana pop-up mientras navegas.' %}
{% set features_power_title = 'Poder sin ánimo de lucro*' %}
{% set features_power_body = 'Firefox está respaldado por la Fundación Mozilla y prioriza a las personas sobre las ganancias.' %}
{% set features_power_small = '*Vale, esto no es una funcionalidad, pero mola, ¿verdad? :)' %}
{% set features_pdf_title = 'Facilidad para editar PDFs' %}
{% set features_pdf_body = 'Edita PDFs directamente en el navegador, sin desvíos.' %}

{% set compare_title = 'Firefox<br> es diferente' %}
{% set compare_body = '¿Te dan pereza los textos largos? ¡No hay problema! Aquí puedes comprobar de un solo vistazo por qué Firefox es la elección correcta para ti.' %}
{% set compare_passwords = 'Autocompletar contraseñas' %}
{% set compare_search = 'Opciones de motor de búsqueda' %}
{% set compare_sync = 'Sincronización entre dispositivos' %}
{% set compare_block = 'Bloquear cookies de terceros por defecto' %}
{% set compare_profit = 'Respaldado por una organización sin ánimo de lucro' %}
{% set compare_privacy = 'Se preocupa de tu privacidad' %}
{% set compare_shareholders = 'No tiene accionistas ni intereses creados' %}
{% set compare_logo = 'Adora Internet y tiene un bonito logo.' %}
{% set compare_cta = 'Firefox es diferente' %}
{% set kitten_egg = 'No todos los caminos conducen a Chrome' %}

{% set cred_title = 'La misión de Firefox' %}
{% set cred_private_title = 'Tu privacidad es solo tuya.' %}
{% set cred_private_body = 'Tus datos te pertenecen. Y con Firefox, te aseguras que eso es así. Nosotros no vendemos tu información personal y ni siquiera guardamos gran parte de ella.' %}
{% set cred_ethical_title = 'Una alternativa ética' %}
{% set cred_ethical_body = 'Siempre hemos estado comprometidos con ofrecer una opción diferente en la web. Somos, y seguiremos siendo, una alternativa al dominio en Internet de unas pocas empresas que solo buscan maximizar sus ganancias.' %}
{% set cred_change_title = 'Somos motor de cambio' %}
{% set cred_change_body = 'Abogamos por una mejor legislación y colaboramos con organizaciones gubernamentales para mantener a las personas seguras y la industria justa.' %}
{% set cred_community_title = 'Estamos juntos en esto' %}
{% set cred_community_body = 'Firefox trabaja con una comunidad global que nos ayuda a mejorar nuestros productos y hacer de la web un lugar más seguro y atractivo para todos.' %}

{% set footer_title = 'Involúcrate' %}
{% set footer_body = 'Si amas Internet y quieres mantenerlo tan sano como nosotros, definitivamente deberías <a %s>unirte a nuestra comunidad</a>.' %}
{% set footer_mobile = 'Impulsado por Mozilla.<br> Poniendo a las personas por delante de los beneficios desde 1998.' %}
{% set footer_desktop = 'Impulsado por Mozilla. Poniendo a las personas por delante de los beneficios desde 1998.' %}
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
{#
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/challenge-the-default/landing-base.html" %}

{% block page_image %}{{ static('img/firefox/challenge-the-default/ctd-share-it.png') }}{% endblock %}

{% set seo_desc = 'Quando scegli Firefox, metti te al primo posto. Noi proteggiamo meglio i tuoi dati, tu hai più trasparenza ed entri a far parte del lato più sano di internet.' %}
{% set cta_default = 'Rendi Firefox il tuo browser predefinito' %}
{% set cta_mobile = 'Scopri Firefox per il mobile' %}
{% set cta_download = 'Scegli Firefox' %}
{% set hero_alt = 'Sfida lo standard' %}
{% set hero_egg = 'Ah, ma quindi leggi davvero tutto. E niente, sei super!' %}
{% set hero_head = 'Scegli un browser che scelga <span class="icon-firefox"></span> prima te' %}
{% set hero_text_ff = 'A dire il vero, questo spazio noi lo usiamo per promuovere Firefox e ci sembra che tu lo stia già usando. Siccome ci piaci, facciamo così: resta qui con noi, fatti un giro sulla pagina e vedi se trovi le sorprese che abbiamo nascosto per te. Ti basta cliccare qui e là!' %}
{% set hero_text_not_ff = 'Quando scegli Firefox, metti te al primo posto. Noi proteggiamo meglio i tuoi dati, tu hai più trasparenza ed entri a far parte del lato più sano di internet.' %}

{% set features_head = 'Cose belle<br> scelte per te' %}
{% set features_browsing_title = 'Navigazione fluida' %}
{% set features_browsing_body = 'Tieni aperte tutte le tab che desideri e memorizzi le tue password su ogni tuo device - ma solo se lo vuoi.' %}
{% set features_multi_title = 'Esperienza multitasking' %}
{% set features_multi_body = 'Vuoi continuare a navigare mentre guardi un video in una finestra pop-up? Puoi farlo.' %}
{% set features_power_title = 'Il superpotere del no profit*' %}
{% set features_power_body = 'Firefox è supportato dalla Mozilla Foundation e preferisce le persone al profitto.' %}
{% set features_power_small = '*Sì, questa non è una feature del browser. È comunque una cosa bella, no?' %}
{% set features_pdf_title = 'Modifica facile dei PDF' %}
{% set features_pdf_body = 'Puoi modificare i tuoi PDF direttamente nel browser, senza fare giri in giro.' %}

{% set compare_title = 'Firefox<br> fa la differenza' %}
{% set compare_body = 'Non ami i testi lunghi? Ti capiamo. Ecco perché Firefox è la scelta giusta per te, così, a colpo d’occhio.' %}
{% set compare_passwords = 'Auto-completa le tue password' %}
{% set compare_search = 'Ti fa scegliere i motori di ricerca' %}
{% set compare_sync = 'Si sincronizza coi tuoi device' %}
{% set compare_block = 'Blocca di default i cookies di terze parti' %}
{% set compare_profit = 'È supportato da una no-profit' %}
{% set compare_privacy = 'Ci tiene alla tua privacy' %}
{% set compare_shareholders = 'Non ha shareholder con doppi fini' %}
{% set compare_logo = 'Adora internet e ha un logo strabello' %}
{% set compare_cta = 'Fai la differenza con Firefox' %}
{% set kitten_egg = 'Non tutte le strade portano a Chrome' %}

{% set cred_title = 'La nostra missione' %}
{% set cred_private_title = 'Privacy senza compromessi' %}
{% set cred_private_body = 'I tuoi dati appartengono a te, mica a noi. Con Firefox rimarranno sempre tuoi: non venderemo mai a terzi nessuna delle tue informazioni. Un sacco di cose non le salviamo neppure.' %}
{% set cred_ethical_title = 'Un’alternativa etica' %}
{% set cred_ethical_body = 'Ci impegniamo da sempre per offrire una scelta diversa sul web. Siamo e vogliamo rimanere un’alternativa alla prevalenza su internet dei pochi noti. Quelli che conosci anche tu e che preferiscono mettere il profitto prima di tutto.' %}
{% set cred_change_title = 'Qualcosa non va? Allora cambiamola' %}
{% set cred_change_body = 'Ci attiviamo per avere leggi migliori e lavoriamo con gli enti governativi di tutto il mondo per mantenere le persone al sicuro e rendere l’industria digitale più giusta.' %}
{% set cred_community_title = 'Insieme non si è mai da soli' %}
{% set cred_community_body = 'Firefox funziona grazie a una community internazionale che aiuta a rendere i nostri prodotti migliori, ma anche a fare del web un posto più bello e sicuro per tutte e tutti.' %}

{% set footer_title = 'Unisciti a noi' %}
{% set footer_body = 'Se anche a te internet sembra un posto fantastico e vuoi mantenerlo equo e sano insieme a noi, <a %s>unisciti alla nostra community</a>.' %}
{% set footer_mobile = 'Powered by Mozilla.<br> Mettiamo le persone prima del profitto dal 1998.' %}
{% set footer_desktop = 'Powered by Mozilla. Mettiamo le persone prima del profitto dal 1998.' %}
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
{#
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/challenge-the-default/landing-base.html" %}

{% block page_image %}{{ static('img/firefox/challenge-the-default/ctd-share-pl.png') }}{% endblock %}

{% set seo_desc = 'Korzystając z Firefoksa decydujesz się na lepszą ochronę danych, większą transparentość i "zdrowszy" internet. To Twój świadomy wybór.' %}
{% set cta_default = 'Ustaw Firefoksa jako domyślną przeglądarkę' %}
{% set cta_mobile = 'Odkryj Firefoksa dla urządzeń mobilnych' %}
{% set cta_download = 'Wybierz Firefoksa' %}
{% set hero_alt = 'Wybierz po swojemu' %}
{% set hero_egg = 'Trafiłeś w sam środek. Dobra robota!' %}
{% set hero_head = 'Wybierz <span class="icon-firefox"></span> przeglądarkę zaprojektowaną z myślą o Tobie' %}
{% set hero_text_ff = 'W tym miejscu powinniśmy zareklamować Firefoksa. Skoro i tak już z niego korzystarz, to zdradzimy Ci tajemnicę: ukryliśmy na tej stronie kilka niespodzianek. Poklikaj trochę i sam się przekonaj, czy coś znajdziesz.' %}
{% set hero_text_not_ff = 'Korzystając z Firefoksa decydujesz się na lepszą ochronę danych, większą transparentość i "zdrowszy" internet. To Twój świadomy wybór.' %}

{% set features_head = 'Nasze ulubione<br> funkcje' %}
{% set features_browsing_title = 'Płynne przeglądanie stron' %}
{% set features_browsing_body = 'Miej wszystkie otwarte karty i zapisane hasła zawsze pod ręką - na wszystkich urządzeniach.' %}
{% set features_multi_title = 'Pełna wielozadaniowość' %}
{% set features_multi_body = 'Oglądaj filmy i przeglądaj strony w tym samym czasie, w dwóch różnych okienkach.' %}
{% set features_power_title = 'Non-profit power*' %}
{% set features_power_body = 'Firefox wspierany jest przez Fundację Mozilli. Stawiamy ludzi ponad zyski.' %}
{% set features_power_small = '*Wiemy, że to nie funkcja, ale to my tu ustalamy zasady :)' %}
{% set features_pdf_title = 'Szybka edycja plików PDF' %}
{% set features_pdf_body = 'Edytuj pliki PDF bezpośrednio w przeglądarce - idź na skróty.' %}

{% set compare_title = 'Firefox robi<br> różnicę' %}
{% set compare_body = 'Nie lubisz długich tekstów? Żaden problem! Tu jak na dłoni widać, że Firefox to coś dla Ciebie.' %}
{% set compare_passwords = 'Automatyczne wpisywanie haseł' %}
{% set compare_search = 'Możliwość wyboru wyszukiwarki' %}
{% set compare_sync = 'Synchronizacja urządzeń' %}
{% set compare_block = 'Blokowanie plików cookies ze stron trzecich ' %}
{% set compare_profit = 'Wspierany przez organizację non-profit' %}
{% set compare_privacy = 'Troszczy się o prywatność' %}
{% set compare_shareholders = 'Nie ma działających na swój interes udziałowców' %}
{% set compare_logo = 'Kocha internet i ma fajne logo' %}
{% set compare_cta = 'Zmieniaj zasady gry z Firefoksem' %}
{% set kitten_egg = 'Jest od Chrome’a możliwości - wybierz po swojemu' %}

{% set cred_title = 'Nasza Misja' %}
{% set cred_private_title = 'Prywatność bez kompromisów.' %}
{% set cred_private_body = 'Twoje dane należą do Ciebie. Nie sprzedajemy Twoich danych, wielu rzeczy nawet nie zapisujemy. Tak to robimy w Firefoksie.' %}
{% set cred_ethical_title = '' %}
{% set cred_ethical_body = '' %}
{% set cred_change_title = 'Coś nie gra? Zmieńmy to!' %}
{% set cred_change_body = 'Zależy nam na lepszym prawie. Współpracujemy z orgaznizacjami rządowymi, aby użytkownicy czuli się bezpiecznie, a nasza branża mogła być uczciwa.' %}
{% set cred_community_title = 'Razem raźniej!' %}
{% set cred_community_body = 'Globalna społeczność Firefoksa pomaga nam ulepszać nasze produkty. Razem łatwiej troszczyć się o bezpieczny i przyjazny dla wszystkich internet.' %}

{% set footer_title = 'Dołącz do nas' %}
{% set footer_body = 'Jeśli zależy Ci, żeby internet był bezpiecznym miejscem, zdecydowanie <a %s>powinieneś dołączyć do społeczności</a>.' %}
{% set footer_mobile = 'Powered by Mozilla.<br> Stawiamy ludzi ponad zyskami od 1998.' %}
{% set footer_desktop = 'Powered by Mozilla. Stawiamy ludzi ponad zyskami od 1998.' %}
20 changes: 0 additions & 20 deletions bedrock/firefox/tests/test_views.py
Original file line number Diff line number Diff line change
Expand Up @@ -492,26 +492,6 @@ def test_windows_download_template(self, render_mock):
assert template == ["firefox/new/basic/download_windows.html"]


class TestFirefoxHome(TestCase):
@patch("bedrock.firefox.views.l10n_utils.render")
def test_firefox_home(self, render_mock):
req = RequestFactory().get("/firefox/")
req.locale = "en-US"
view = views.FirefoxHomeView.as_view()
view(req)
template = render_mock.call_args[0][1]
assert template == ["firefox/home/index-master.html"]

@patch("bedrock.firefox.views.l10n_utils.render")
def test_firefox_home_de(self, render_mock):
req = RequestFactory().get("/firefox/")
req.locale = "de"
view = views.FirefoxHomeView.as_view()
view(req)
template = render_mock.call_args[0][1]
assert template == ["firefox/challenge-the-default/landing-switch.html"]


class TestFirefoxGA(TestCase):
def assert_ga_attr(self, response):
doc = pq(response.content)
Expand Down
6 changes: 3 additions & 3 deletions bedrock/firefox/urls.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@
"firefox/challenge-the-default/",
VariationTemplateView.as_view(
template_name="firefox/challenge-the-default/landing-switch.html",
active_locales=["fr"],
variation_locales=["fr"],
active_locales=["de", "es-ES", "fr", "it", "pl"],
variation_locales=["de", "fr"],
ftl_files=["firefox/home"],
template_context_variations=["1", "2", "3", "4", "5"],
template_context_variations=["1", "2", "3", "4", "5", "6"],
),
),
path("firefox/all/", views.firefox_all, name="firefox.all"),
Expand Down
25 changes: 13 additions & 12 deletions bedrock/firefox/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -756,30 +756,31 @@ def ios_testflight(request):


class FirefoxHomeView(L10nTemplateView):
ftl_files_map = {"firefox/home/index-master.html": ["firefox/home"], "firefox/challenge-the-default/landing-switch.html": ["firefox/home"]}
ftl_files_map = {"firefox/home/index-master.html": ["firefox/home"]}

# place expected ?v= values in this list
variations = ["1", "2", "3", "4", "5", "6"]
variations = []

def get_context_data(self, **kwargs):
ctx = super().get_context_data(**kwargs)
variation = self.request.GET.get("v", None)
variant = self.request.GET.get("v", None)

# ensure variation matches pre-defined value
if variation not in self.variations:
variation = None
# ensure variant matches pre-defined value
if variant not in self.variations:
variant = None

ctx["variation"] = variation
ctx["variant"] = variant

return ctx

def get_template_names(self):
locale = l10n_utils.get_locale(self.request)
variant = self.request.GET.get("v", None)

if locale == "de":
template_name = "firefox/challenge-the-default/landing-switch.html"
else:
template_name = "firefox/home/index-master.html"
# ensure variant matches pre-defined value
if variant not in self.variations:
variant = None

template_name = "firefox/home/index-master.html"

return [template_name]

Expand Down
11 changes: 8 additions & 3 deletions media/css/firefox/challenge-the-default/_compare-table.scss
Original file line number Diff line number Diff line change
Expand Up @@ -216,10 +216,11 @@

.kitten-modal-grid {
display: grid;
grid-template-rows: 360px;
grid-template-columns: 1fr;
grid-gap: $spacing-lg;
justify-items: center;
grid-template-columns: 1fr;
grid-template-rows: 360px;
min-height: 340px;
place-items: center center;

@media #{$mq-md} {
grid-template-columns: 1fr 1fr;
Expand All @@ -237,6 +238,10 @@
@media #{$mq-md} {
@include font-size(60px);
align-self: initial;

[lang="pl"] & {
@include font-size(42px);
}
}
}

Expand Down
Loading

0 comments on commit 48d8f0d

Please sign in to comment.