header responsive avec feature

This commit is contained in:
SylvainLelievre 2021-12-14 08:02:11 +01:00
parent 07a1d97149
commit 48d1bf27a0

View File

@ -251,7 +251,7 @@ core.start = function() {
/** /**
* Commande de gestion des cookies dans le footer * Commande de gestion des cookies dans le footer
*/ */
$("#footerLinkCookie").on("click", function() { $("#footerLinkCookie").on("click", function() {
$("#cookieConsent").removeClass("displayNone"); $("#cookieConsent").removeClass("displayNone");
}); });
@ -375,9 +375,10 @@ core.start = function() {
var heightpx = "<?php echo $this->getdata(['theme','header','height']);?>"; var heightpx = "<?php echo $this->getdata(['theme','header','height']);?>";
var height = heightpx.substr(0,heightpx.length-2); var height = heightpx.substr(0,heightpx.length-2);
var ratio = width / height; var ratio = width / height;
var feature = "<?php echo $this->getdata(['theme','header','feature']);?>";
if ( ($(window).width() / ratio) <= height) { if ( ($(window).width() / ratio) <= height) {
$("header").height( $(window).width() / ratio ); $("header").height( $(window).width() / ratio );
$("header").css("line-height", $(window).width() / ratio + "px"); if( feature !== "feature"){ $("header").css("line-height", $(window).width() / ratio + "px")};
} }
} }
}).trigger("resize"); }).trigger("resize");