forked from mozilla/bedrock
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
2bd7bc4
commit de95781
Showing
5 changed files
with
138 additions
and
3 deletions.
There are no files selected for viewing
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
28 changes: 28 additions & 0 deletions
28
bedrock/mozorg/templates/mozorg/home/includes/pocket-best-of.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,28 @@ | ||
{# | ||
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/. | ||
#} | ||
{% if LANG == 'de' %} | ||
{% set small_text = 'Vorgestelltes Produkt' %} | ||
{% set heading_text = 'Entdecke die besten Artikel aus 2023' %} | ||
{% set cta_text = 'Zum Best of 2023' %} | ||
{% else %} | ||
{% set small_text = 'Featured product' %} | ||
{% set heading_text = 'Discover the top articles of 2023' %} | ||
{% set cta_text = 'See the winners' %} | ||
{% endif %} | ||
|
||
<aside class="pocket-feature mzp-l-content"> | ||
<div class="feature-wrapper"> | ||
<div class="image-wrapper"> | ||
<img loading="lazy" src="{{ static('img/home/2023/pocket-best-of.png') }}" alt="Pocket: Best of 2023"> | ||
</div> | ||
<div class="feature-info"> | ||
<small>{{ small_text }}</small> | ||
<h2>{{ heading_text }}</h2> | ||
</div> | ||
<a href="https://www.getpocket.com/2023/" rel="external noopener" target="_blank" class="mzp-c-button c-t-pocket" data-cta-text="See the winners" | ||
data-cta-type="link" data-cta-position="mid-page banner">{{ cta_text }}</a> | ||
</div> | ||
</aside> |
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,96 @@ | ||
// 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/includes/lib'; | ||
|
||
$pocket-inverse-color: #3A0603; | ||
|
||
.pocket-feature { | ||
@include font-base; | ||
padding-top: 0; | ||
|
||
.feature-wrapper { | ||
border-radius: $border-radius-md; | ||
display: flex; | ||
flex-direction: column; | ||
align-items: center; | ||
justify-content: space-between; | ||
background-color: #32313b; | ||
padding: $spacing-2xl 0; | ||
} | ||
|
||
.image-wrapper { | ||
max-width: 300px; | ||
margin-bottom: $spacing-xl; | ||
} | ||
|
||
.feature-info { | ||
text-align: center; | ||
margin-bottom: $spacing-lg; | ||
|
||
small, h2 { | ||
color: $color-white; | ||
} | ||
|
||
small { | ||
@include font-size(18px); | ||
text-transform: uppercase; | ||
font-weight: 700; | ||
} | ||
|
||
h2 { | ||
@include font-size(32px); | ||
@include font-base; | ||
font-weight: normal; | ||
} | ||
} | ||
|
||
a { | ||
@include text-body-lg; | ||
background-color: $color-red-50; | ||
border-color: $color-red-50; | ||
white-space: nowrap; | ||
|
||
&:hover, &:active { | ||
border-color: $color-red-50; | ||
color: $color-red-50 | ||
} | ||
|
||
&:focus { | ||
border-color: $color-red-50; | ||
color: $color-white; | ||
box-shadow: 0 0 0 1px $color-blue-05; | ||
} | ||
} | ||
|
||
@media #{$mq-md} { | ||
.image-wrapper { | ||
max-width: none; | ||
} | ||
} | ||
|
||
@media #{$mq-lg} { | ||
.feature-wrapper { | ||
flex-direction: row; | ||
padding: 0 $spacing-2xl 0 0; | ||
} | ||
|
||
.feature-info { | ||
text-align: left; | ||
margin: 0 $spacing-md; | ||
} | ||
|
||
.image-wrapper { | ||
background-color: $color-red-50; | ||
padding-left: $spacing-2xl; | ||
border-top-left-radius: $border-radius-md; | ||
border-bottom-left-radius: $border-radius-md; | ||
margin-bottom: 0; | ||
} | ||
} | ||
} |
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