change region lien site et doc
This commit is contained in:
@@ -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);
|
||||
|
@@ -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;
|
||||
}
|
Reference in New Issue
Block a user