modifs carousel desktop + corrections partenaires et img portrait fullpage

This commit is contained in:
Valentin 2024-01-22 15:25:26 +01:00
parent eee07205df
commit 3a0fe66eca
5 changed files with 60 additions and 128 deletions

View File

@ -470,6 +470,8 @@ body.toolbar-fixed header {
height: 30vh !important;
overflow-y: hidden;
padding: 0 !important;
display: flex;
align-items: center;
}
.slick-container div.views-row article > div:first-of-type > div {
width: 100%;
@ -481,50 +483,21 @@ body.toolbar-fixed header {
width: 100%;
height: auto;
}
@media (min-width: 1080px) {
.slick-container div.views-row article > div:first-of-type {
height: 50vh !important;
}
}
@media (min-width: 760px) {
.slick-container div.views-row article .preview_meta {
margin-left: 0;
margin-right: 0;
justify-content: flex-start;
flex-direction: column;
}
.slick-container div.views-row article .preview_meta > div:last-of-type {
padding-top: 0.5rem;
}
.slick-container div.views-row article h2, .slick-container div.views-row article .preview_sous_titre {
padding-left: 0;
padding-right: 0;
}
}
@media (min-width: 1080px) {
.slick-container div.views-row article {
display: flex;
align-items: flex-end;
border-bottom: solid 1px #038788;
}
.slick-container div.views-row article > div:first-of-type {
width: calc(50% + 6.25vw);
height: 40vh !important;
align-self: flex-start;
min-height: 100% !important;
}
.slick-container div.views-row article > div:last-of-type {
width: calc(50% - 6.25vw);
padding-bottom: 4rem;
}
.slick-container div.views-row article > div:last-of-type > div, .slick-container div.views-row article > div:last-of-type > h2 {
padding-left: 3vw;
}
.slick-container div.views-row article > div:last-of-type > div:first-of-type {
padding-top: 3rem;
}
.slick-container div.views-row article > div:last-of-type > div:last-of-type {
margin-top: 0.5rem;
}
.slick-container div.views-row article .preview_infos {
background-color: #fcf9ee;
}
}
.slick-container .slick-arrow {
display: none !important;
width: 2rem;
@ -536,6 +509,11 @@ body.toolbar-fixed header {
background-color: rgba(255, 255, 255, 0.4) !important;
transition: background-color 0.3s ease;
}
@media (min-width: 1080px) {
.slick-container .slick-arrow {
transform: translateY(-5rem);
}
}
.slick-container .slick-arrow:hover {
background-color: rgba(255, 255, 255, 0.8) !important;
}
@ -561,8 +539,7 @@ body.toolbar-fixed header {
}
@media (min-width: 1080px) {
.slick-container #carousel_dots {
margin-top: 8vh;
margin-left: 12.5vw;
margin-top: 4vh;
}
}
.slick-container footer {
@ -587,13 +564,6 @@ body.toolbar-fixed header {
.slick-container footer a:hover {
background-color: #00ff80;
}
@media (min-width: 1080px) {
.slick-container footer {
margin-top: -2vh;
position: absolute;
right: 12.5vw;
}
}
@media (min-width: 760px) {
.slick-container {
padding: 0 12.5vw;
@ -608,22 +578,6 @@ body.toolbar-fixed header {
right: -5rem;
}
}
@media (min-width: 1080px) {
.slick-container {
padding: 0;
padding-right: 12.5vw;
padding-bottom: 10vh;
}
.slick-container .slick-prev, .slick-container .slick-next {
bottom: 20%;
}
.slick-container .slick-prev {
display: none !important;
}
.slick-container .slick-next {
display: block !important;
}
}
.actu_full div {
font-family: "Marianne", sans-serif;
@ -1720,7 +1674,7 @@ body.toolbar-fixed header {
}
@media (min-width: 1080px) {
.content_partenaires .views-row article > div:first-of-type > div:first-of-type > div {
width: 15vw;
width: 10vw;
}
}
.content_partenaires .views-row article > div:first-of-type > div:nth-of-type(2) {

File diff suppressed because one or more lines are too long

View File

@ -134,12 +134,34 @@
menuContainer.append(socialsContainer);
//
// Effets parallax
// Retirer paragraphes vides fullpage
// et ajouter de la marge pour les images en portrait
//
let currentPage;
if (document.querySelector('.fullpage:not(.actus)')) currentPage = 'fullpage';
else if (document.querySelector('.carousel_container')) currentPage = 'home';
if (currentPage === 'fullpage') {
let paragraphs = document.querySelectorAll('p');
for (let paragraph of paragraphs) {
if (!/[a-zA-Z]/.test(paragraph.innerText)) {
paragraph.remove();
}
}
let imgs = document.querySelectorAll('.fullpage img');
for (let img of imgs) {
if (img.height > img.width) {
console.log('ouiiii');
img.parentElement.style.padding = '0 12vw';
}
}
}
//
// Effets parallax
//
let ornements, scrollHeight;
function getElementsAndPositions() {
scrollHeight = document.body.scrollHeight;

View File

@ -26,7 +26,7 @@
width: 20vw;
}
@media (min-width: $breakpoint_desktop) {
width: 15vw;
width: 10vw;
}
}
}

View File

@ -9,6 +9,8 @@
height: 30vh !important;
overflow-y: hidden;
padding: 0 !important;
display: flex;
align-items: center;
> div {
width: 100%;
> a {
@ -19,50 +21,21 @@
}
}
}
@media (min-width: $breakpoint_desktop) {
height: 50vh !important;
}
}
@media (min-width: $breakpoint_tablet) {
.preview_meta {
margin-left: 0;
margin-right: 0;
justify-content: flex-start;
flex-direction: column;
> div:last-of-type {
padding-top: 0.5rem;
}
}
h2, .preview_sous_titre {
padding-left: 0;
padding-right: 0;
}
}
@media (min-width: $breakpoint_desktop) {
display: flex;
align-items: flex-end;
border-bottom: solid 1px $teal;
> div:first-of-type {
width: calc(50% + 6.25vw);
height: 40vh !important;
align-self: flex-start;
min-height: 100% !important;
}
> div:last-of-type {
width: calc(50% - 6.25vw);
padding-bottom: 4rem;
> div, > h2 {
padding-left: $x_margin;
}
> div:first-of-type {
padding-top: 3rem;
}
> div:last-of-type {
margin-top: 0.5rem;
}
}
.preview_infos {
background-color: $beige;
}
}
}
}
.slick-arrow {
display: none !important;
width: 2rem;
@ -73,6 +46,9 @@
bottom: 5%;
background-color: rgba(255, 255, 255, 0.4) !important;
transition: background-color 0.3s ease;
@media (min-width: $breakpoint_desktop) {
transform: translateY(-5rem);
}
}
.slick-arrow:hover {
background-color: rgba(255, 255, 255, 0.8) !important;
@ -97,8 +73,7 @@
}
}
@media (min-width: $breakpoint_desktop) {
margin-top: 8vh;
margin-left: 12.5vw;
margin-top: 4vh;
}
}
footer {
@ -106,36 +81,17 @@
text-align: center;
margin-top: 4rem;
margin-bottom: 4rem;
@media (min-width: $breakpoint_desktop) {
margin-top: -2vh;
position: absolute;
right: 12.5vw;
}
}
@media (min-width: $breakpoint_tablet) {
padding: 0 12.5vw;
.slick-prev, .slick-next {
display: block !important;
@media (min-width: $breakpoint_tablet) {
padding: 0 12.5vw;
.slick-prev, .slick-next {
display: block !important;
}
.slick-prev {
left: -5rem;
}
.slick-next {
right: -5rem;
}
}
.slick-prev {
left: -5rem;
}
.slick-next {
right: -5rem;
}
}
@media (min-width: $breakpoint_desktop) {
padding: 0;
padding-right: 12.5vw;
padding-bottom: 10vh;
.slick-prev, .slick-next {
bottom: 20%;
}
.slick-prev {
display: none !important;
}
.slick-next {
display: block !important;
}
}
}