[9.2.17] Fixed Body footer option

This commit is contained in:
Fred Tempez 2020-02-02 19:14:57 +01:00
parent 054244a2f6
commit 3bb3f992ae
6 changed files with 41 additions and 4 deletions

View File

@ -563,9 +563,11 @@ ul .menuSideChild, li .menuSideChild {
section {
min-height: 450px;
}
section #sectionTitle {
margin-top: 0;
}
.userLogin, .updateForm {
min-height: 0px;
}
@ -598,6 +600,16 @@ footer {
margin: 0;
}
.footerbodyFixed {
position: fixed;
bottom: 0;
left: 0;
width: 100%;
z-index:50;
background-color: inherit;
padding: inherit;
}
#footersiteRight, #footersiteLeft, #footersiteCenter,
#footerbodyRight, #footerbodyLeft, #footerbodyCenter {
vertical-align: middle;

View File

@ -212,7 +212,10 @@
)
) { $position = 'site'; } else {
$position = 'body';
echo '</div>';
if ( $this->getData(['theme', 'footer', 'fixed']) === true) {
$positionFixed = 'footerbodyFixed';
}
echo '</div>';
}
?>
<!-- Pied de page -->
@ -221,7 +224,7 @@
if ($position === 'site'): ?>
<div class="container"><div class="row" id="footersite">
<?php else: ?>
<div class="container-large"><div class="row" id="footerbody">
<div class="container-large <?php echo $positionFixed; ?>"><div class="row" id="footerbody">
<?php endif?>
<!-- Mise en page -->
<?php switch($this->getData(['theme', 'footer', 'template'])) {

View File

@ -317,6 +317,7 @@ class theme extends common {
'loginLink' => $this->getInput('themeFooterLoginLink'),
'margin' => $this->getInput('themeFooterMargin', helper::FILTER_BOOLEAN),
'position' => $this->getInput('themeFooterPosition'),
'fixed' => $this->getInput('themeFooterFixed', helper::FILTER_BOOLEAN),
'socialsAlign' => $this->getInput('themeFooterSocialsAlign'),
'text' => $this->getInput('themeFooterText', null),
'textAlign' => $this->getInput('themeFooterTextAlign'),

View File

@ -207,7 +207,17 @@ $("#themeFooterCopyrightPosition").on("change", function() {
}
}
}).trigger("change");
// Affiche / Cache les options du footer fixe
$("#themeFooterPosition").on("change", function() {
if($(this).val() === 'body') {
$("#themeFooterPositionFixed").slideDown();
}
else {
$("#themeFooterPositionFixed").slideUp(function() {
$("#themeFooterPositionFixed").prop("checked", false).trigger("change");
});
}
}).trigger("change");
// Lien de connexion
$("#themeFooterLoginLink").on("change", function() {

View File

@ -196,7 +196,14 @@
'checked' => $this->getData(['theme', 'footer', 'margin'])
]); ?>
</div>
</div>
</div>
<div class="col6">
<div id="themeFooterPositionFixed" class="displayNone">
<?php echo template::checkbox('themeFooterFixed', true, 'Pied de page fixe', [
'checked' => $this->getData(['theme', 'footer', 'fixed'])
]); ?>
</div>
</div>
</div>
</div>
</div>

View File

@ -19,6 +19,10 @@ footer {
position: relative;
z-index: 10;
}
.footerbodyFixed {
position: relative;
z-index: 5;
}
nav li ul {
display: none;
}