diff --git a/components/gc-featured-link/_base.scss b/components/gc-featured-link/_base.scss index 542ba3b67..7944f0b7c 100644 --- a/components/gc-featured-link/_base.scss +++ b/components/gc-featured-link/_base.scss @@ -2,20 +2,27 @@ .gc-featured-link { background-color: $bg-gctheme; + color: #fff; + font-family: Lato, sans-serif; + opacity: .9; + padding-bottom: $space-md; + padding-top: $space-md; - &.provisional { - font-family: Lato, sans-serif; - opacity: .9; - padding-bottom: $space-md; - padding-top: $space-md; + p:first-of-type { + margin-bottom: $space-0; + } - p:first-of-type { - font-weight: $bold-weight; - margin-bottom: $space-0; - } + a { + color: #fff; + font-weight: $bold-weight; + } + + html:not(.wb-disable) &[data-bg-color] { + background-color: transparent; + color: $text-color; - p, a { - color: #fff; + a { + color: $text-color; } } } diff --git a/components/gc-featured-link/gc-featured-link-en.html b/components/gc-featured-link/gc-featured-link-en.html index c7b286db6..8ef7ad9a6 100644 --- a/components/gc-featured-link/gc-featured-link-en.html +++ b/components/gc-featured-link/gc-featured-link-en.html @@ -34,7 +34,7 @@
The logic semantic structure of headings have not been followed to accommodate each working examples.
+The logic semantic structure of headings have not been followed to accommodate the following working example. You can go directly to the source code.
<section class="provisional gc-featured-link">
- <div class="container">
- <div class="row">
- <div class="col-xs-12">
- <h2 class="wb-inv">Featured</h2>
- <p><a class="stretched-link" href="#">[Promotion title]</a></p>
- <p>Long description [optional]</p>
- </div>
+ <div class="container">
+ <div class="row">
+ <div class="col-xs-12">
+ <h2 class="wb-inv">Featured</h2>
+ <p><a class="stretched-link" href="#">[Promotion title]</a></p>
+ <p>Long description [optional]</p>
</div>
</div>
- </section>
-
+ </div>
+</section>
+
+ To customize the background color, add the attribute data-bg-color
. The value should be the hexadecimal code of the desired color.
The plugin will automatically apply the correct color to the text: #FFFFFF
for dark colors, #333333
for light colors, #000000
for colors in-between.
The logic semantic structure of headings have not been followed to accommodate each working examples. You can go directly to the source code.
+Dark background example:
+Light color example:
+Medium color example:
+<section class="provisional gc-featured-link" data-bg-color="#005B61">
+ <div class="container">
+ <div class="row">
+ <div class="col-xs-12">
+ <h2 class="wb-inv">Featured</h2>
+ <p><a class="stretched-link" href="#">[Promotion title]</a></p>
+ <p>Long description [Optional]</p>
+ </div>
+ </div>
+ </div>
+ </section>
+
+ <section class="provisional gc-featured-link" data-bg-color="#99dade">
+ <div class="container">
+ <div class="row">
+ <div class="col-xs-12">
+ <h2 class="wb-inv">Featured</h2>
+ <p><a class="stretched-link" href="#">[Promotion title]</a></p>
+ <p>Long description [Optional]</p>
+ </div>
+ </div>
+ </div>
+ </section>
+
+ <section class="provisional gc-featured-link" data-bg-color="#8F8F8F">
+ <div class="container">
+ <div class="row">
+ <div class="col-xs-12">
+ <h2 class="wb-inv">Featured</h2>
+ <p><a class="stretched-link" href="#">[Promotion title]</a></p>
+ <p>Long description [Optional]</p>
+ </div>
+ </div>
+ </div>
+ </section>
La structure sémantique logique des en-têtes n'a pas été suivie afin de s'adapter à chaque exemples pratiques.
+La structure sémantique logique des en-têtes n'a pas été suivie afin de s'adapter à l'exemple pratique suivant. Vous pouvez aller directement au code source.
<section class="provisional gc-featured-link">
- <div class="container">
- <div class="row">
- <div class="col-xs-12">
- <h2 class="wb-inv">En vedette</h2>
- <p><a class="stretched-link" href="#">[Titre de la promotion]</a></p>
- <p>Description longue [Facultatif]</p>
- </div>
- </div>
- </div>
- </section>
-
+ <section class="provisional gc-featured-link">
+ <div class="container">
+ <div class="row">
+ <div class="col-xs-12">
+ <h2 class="wb-inv">En vedette</h2>
+ <p><a class="stretched-link" href="#">[Titre de la promotion]</a></p>
+ <p>Description longue [Facultatif]</p>
+ </div>
+ </div>
+ </div>
+</section>
+
+ Pour personnaliser la couleur d'arrière-pla, ajoutez l'attribut data-bg-color
. La valeur doit être le code hexadécimal de la couleur souhaitée.
Le plugiciel appliquera automatiquement la bonne couleur au texte : #FFFFFF
pour les couleurs sombres, #333333
pour les couleurs claires, #000000
pour les couleurs intermédiaires.
La structure sémantique logique des en-têtes n'a pas été suivie afin de s'adapter à chaque exemples pratiques. Vous pouvez aller directement au code source.
+Exemple avec couleur sombre :
+Exemple avec couleur claire :
+Exemple avec couleur intermédiaire :
+<section class="provisional gc-featured-link" data-bg-color="#005B61">
+ <div class="container">
+ <div class="row">
+ <div class="col-xs-12">
+ <h2 class="wb-inv">En vedette</h2>
+ <p><a class="stretched-link" href="#">[Titre de la promotion]</a></p>
+ <p>Description longue [Facultatif]</p>
+ </div>
+ </div>
+ </div>
+ </section>
+
+ <section class="provisional gc-featured-link" data-bg-color="#99dade">
+ <div class="container">
+ <div class="row">
+ <div class="col-xs-12">
+ <h2 class="wb-inv">En vedette</h2>
+ <p><a class="stretched-link" href="#">[Titre de la promotion]</a></p>
+ <p>Description longue [Facultatif]</p>
+ </div>
+ </div>
+ </div>
+ </section>
+
+ <section class="provisional gc-featured-link" data-bg-color="#8F8F8F">
+ <div class="container">
+ <div class="row">
+ <div class="col-xs-12">
+ <h2 class="wb-inv">En vedette</h2>
+ <p><a class="stretched-link" href="#">[Titre de la promotion]</a></p>
+ <p>Description longue [Facultatif]</p>
+ </div>
+ </div>
+ </div>
+ </section>