change region lien site et doc

This commit is contained in:
ouidade 2024-11-08 20:44:39 +01:00
parent cefa8f0acd
commit 7e518c5d90
5 changed files with 241 additions and 6 deletions

File diff suppressed because one or more lines are too long

View File

@ -3002,7 +3002,7 @@ body {
}
}
.node-type-site .layout--threecol-25-50-25 .layout__region--first {
flex: 1 0 20%;
flex: 0 1 25%;
display: flex;
flex-direction: column;
align-items: center;
@ -3043,6 +3043,9 @@ body {
height: fit-content;
}
}
.node-type-site .layout--threecol-25-50-25 .layout__region--first h2 {
display: none;
}
.node-type-site .layout--threecol-25-50-25 .layout__region--first div:has(.field_field_documents) {
margin-bottom: 0.2rem;
}
@ -3244,7 +3247,7 @@ body {
font-family: "gilroy-light";
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third {
flex: 0 1 15% !important;
flex: 0 1 25% !important;
height: fit-content;
margin-top: 1rem;
}
@ -3279,6 +3282,87 @@ body {
.node-type-site .layout--threecol-25-50-25 .layout__region--third .block-region-third div .next-site::before {
content: url("../img/next.svg");
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .documents-liens-wrapper {
display: flex;
flex-direction: column !important;
padding-top: 2rem;
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .documents-liens-wrapper .field--name-field-documents, .node-type-site .layout--threecol-25-50-25 .layout__region--third .documents-liens-wrapper .field_field_documents > div:nth-child(2) > div:nth-child(1) > span:nth-child(2) {
display: none;
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .documents-liens-wrapper .field_field_liens_site > div:nth-child(2) > div:nth-child(1) {
display: flex;
flex-direction: column !important;
width: fit-content;
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .documents-liens-wrapper .field_field_liens_site > div:nth-child(2) {
flex-direction: column;
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .documents-liens-wrapper .field_field_documents {
margin-bottom: 0.5rem;
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .field_field_liens_site {
display: flex;
flex-direction: column !important;
}
@media (max-width: 810px) {
.node-type-site .layout--threecol-25-50-25 .layout__region--third .field_field_liens_site {
max-width: 50%;
margin: auto;
}
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .field_field_liens_site a {
display: inline-flex;
align-items: center;
color: white;
background: black;
padding-left: 0.5rem;
text-transform: uppercase;
font-size: 0.6rem;
margin-bottom: 0.3rem;
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .field_field_liens_site a svg {
display: none;
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .field_field_liens_site a::after {
display: inline-flex;
content: url("../img/noun-arrow-to-right.svg");
padding-right: 0.2rem;
padding-left: 0.2rem;
padding-bottom: 0.2rem;
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .file--mime-application-pdf {
width: fit-content;
padding-left: 0.5rem;
background: black;
}
@media (max-width: 810px) {
.node-type-site .layout--threecol-25-50-25 .layout__region--third .file--mime-application-pdf {
margin-left: 0;
}
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .file--mime-application-pdf a {
display: inline-flex;
align-items: center;
color: white;
text-transform: uppercase;
font-size: 0.6rem;
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .file--mime-application-pdf a svg {
display: none;
}
.node-type-site .layout--threecol-25-50-25 .layout__region--third .file--mime-application-pdf a::after {
display: inline-flex;
content: url("../img/noun-arrow-to-right.svg");
padding-right: 0.2rem;
padding-left: 0.2rem;
padding-bottom: 0.2rem;
}
.field_field_liens_site > div:nth-child(2) > div:nth-child(1) {
display: flex;
flex-direction: column;
}
main {
background-color: #f6f7f3;

View File

@ -625,6 +625,38 @@ if (document.body.classList.contains('node-type-site')) {
}
//////////////////// end div infos site ////////////////////////
document.addEventListener("DOMContentLoaded", function() {
// Sélectionner les éléments à déplacer
const documentsField = document.querySelector(".field_field_documents");
const liensSiteField = document.querySelector(".field_field_liens_site");
// Sélectionner la destination
const thirdRegion = document.querySelector(".block-region-third > div");
// Créer une nouvelle div pour englober les éléments déplacés
const wrapperDiv = document.createElement("div");
wrapperDiv.classList.add("documents-liens-wrapper");
// Déplacer les éléments dans la nouvelle div
if (documentsField && liensSiteField && thirdRegion) {
wrapperDiv.appendChild(documentsField);
wrapperDiv.appendChild(liensSiteField);
// Ajouter la nouvelle div dans la destination
thirdRegion.appendChild(wrapperDiv);
}
});
document.addEventListener("DOMContentLoaded", function() {
// Sélectionner les éléments pertinents
const documentsLiensWrapper = document.querySelector(".documents-liens-wrapper");
const blockRegionThird = document.querySelector(".block-region-third");
// Vérifier que les éléments existent avant de les manipuler
if (documentsLiensWrapper && blockRegionThird) {
// Déplacer .documents-liens-wrapper en dehors du div contenant les boutons prev/next
blockRegionThird.appendChild(documentsLiensWrapper);
}
});
})(jQuery, window);

View File

@ -15,7 +15,7 @@
width: 100%;
}
.layout__region--first{
flex: 1 0 20%;
flex: 0 1 25%;
display: flex;
flex-direction: column;
align-items: center;
@ -52,8 +52,18 @@
left: 0;
height: fit-content;
}
@media only screen and (max-width: 1200px) and (max-resolution: 300dpi){
}
}
}
h2{
display:none;
}
div:has(.field_field_documents){
margin-bottom: 0.2rem;
@ -306,7 +316,7 @@
}
.layout__region--third{
flex: 0 1 15% !important;
flex: 0 1 25% !important;
height: fit-content;
margin-top: 1rem;
@ -343,7 +353,94 @@
}
}
.documents-liens-wrapper{
display: flex;
flex-direction: column !important;
padding-top: 2rem;
.field--name-field-documents, .field_field_documents > div:nth-child(2) > div:nth-child(1) > span:nth-child(2){
display: none;
}
.field_field_liens_site > div:nth-child(2) > div:nth-child(1){
display: flex;
flex-direction: column !important;
width: fit-content;
}
.field_field_liens_site > div:nth-child(2){
flex-direction: column;
}
.field_field_documents{
margin-bottom: 0.5rem;
}
}
.field_field_liens_site{
display: flex;
flex-direction: column !important;
@media (max-width:810px) {
// margin-left: 0;
max-width: 50%;
margin: auto;
}
a{
display: inline-flex;
align-items: center;
color: white;
background: black;
padding-left: 0.5rem;
text-transform: uppercase;
font-size: 0.6rem;
margin-bottom: 0.3rem;
svg{
display: none;
}
&::after{
display: inline-flex;
content: url("../img/noun-arrow-to-right.svg");
padding-right: 0.2rem;
padding-left: 0.2rem;
padding-bottom: 0.2rem;
}
}
}
.file--mime-application-pdf{
width: fit-content;
padding-left: 0.5rem;
// padding-bottom: 0.2rem;
// padding-top: 0.2rem;
background: black;
@media (max-width:810px) {
margin-left: 0;
}
a{
display: inline-flex;
align-items: center;
color: white;
text-transform: uppercase;
font-size: 0.6rem;
svg{
display: none;
}
&::after{
display: inline-flex;
content: url("../img/noun-arrow-to-right.svg");
padding-right: 0.2rem;
padding-left: 0.2rem;
padding-bottom: 0.2rem;
}
}
}
}
}
}
.field_field_liens_site > div:nth-child(2) > div:nth-child(1){
display: flex;
flex-direction: column;
}

View File

@ -77,7 +77,29 @@
<div id="lightbox" class="lightbox">
<span class="close">&times;</span>
<img class="lightbox-content" id="lightbox-img">
<a class="prev" id="prev">&#10094;</a>
<a class="prev" id="prev">
<svg />
</clipPath>
</defs>
<g
id="g1"
transform="translate(-1178.8005,-9024.7618)">
<g
id="g696">
<path
id="path392"
d="m 0,0 c -18.507,0 -33.509,15.003 -33.509,33.51 0,18.506 15.002,33.509 33.509,33.509 18.507,0 33.509,-15.003 33.509,-33.509 C 33.509,15.003 18.507,0 0,0 Z"
style="fill:none;stroke:#000000;stroke-width:0.85;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
transform="matrix(1.3333333,0,0,-1.3333333,1224.0459,9114.6875)"
clip-path="url(#clipPath393)" />
<path
id="path394"
d="M 0,0 -9.997,-8.944 0,-17.887"
style="fill:none;stroke:#000000;stroke-width:0.85;stroke-linecap:butt;stroke-linejoin:miter;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1"
transform="matrix(1.3333333,0,0,-1.3333333,1228.3967,9058.0833)" />
</g>
</g>
</svg></a>
<a class="next" id="next">&#10095;</a>
</div>
</div>