92 lines
2.6 KiB
PHP
92 lines
2.6 KiB
PHP
/**
|
|
* This file is part of DeltaCMS.
|
|
*/
|
|
|
|
/**
|
|
* Ajout des overlays
|
|
*/
|
|
$("<a>")
|
|
.addClass("themeOverlay")
|
|
.attr({
|
|
"id": "themeOverlayBody",
|
|
"href": "<?php echo helper::baseUrl(); ?>theme/body"
|
|
})
|
|
.appendTo("body");
|
|
$("<a>")
|
|
.addClass("themeOverlay")
|
|
.attr({
|
|
"id": "themeOverlayHeader",
|
|
"href": "<?php echo helper::baseUrl(); ?>theme/header"
|
|
})
|
|
.appendTo("header");
|
|
$("<a>")
|
|
.addClass("themeOverlay")
|
|
.attr({
|
|
"id": "themeOverlayMenu",
|
|
"href": "<?php echo helper::baseUrl(); ?>theme/menu"
|
|
})
|
|
.appendTo("nav");
|
|
$("<a>")
|
|
.addClass("themeOverlay")
|
|
.attr({
|
|
"id": "themeOverlaySite",
|
|
"href": "<?php echo helper::baseUrl(); ?>theme/site"
|
|
})
|
|
.appendTo("#site");
|
|
$("<a>")
|
|
.addClass("themeOverlay themeOverlayHideBackground")
|
|
.attr({
|
|
"id": "themeOverlaySection",
|
|
"href": "<?php echo helper::baseUrl(); ?>theme/site"
|
|
})
|
|
.appendTo("section");
|
|
$("<a>")
|
|
.addClass("themeOverlay")
|
|
.attr({
|
|
"id": "themeOverlayFooter",
|
|
"href": "<?php echo helper::baseUrl(); ?>theme/footer"
|
|
})
|
|
.appendTo("footer");
|
|
|
|
/**
|
|
* Affiche les zones cachées
|
|
*/
|
|
$("#themeShowAll").on("click", function() {
|
|
if( $(window).width() >= 800 ){
|
|
$("header.displayNone, nav.displayNone, footer.displayNone").slideToggle();
|
|
} else {
|
|
$("header.displayNone, nav.displayNone, footer.displayNone, header.bannerDisplay").slideToggle();
|
|
}
|
|
});
|
|
|
|
/**
|
|
* Simule un survol du site lors du survol de la section
|
|
*/
|
|
$("section")
|
|
.on("mouseover", function() {
|
|
$("#themeOverlaySite:not(.themeOverlayTriggerHover)").addClass("themeOverlayTriggerHover");
|
|
})
|
|
.on("mouseleave", function() {
|
|
$("#themeOverlaySite.themeOverlayTriggerHover").removeClass("themeOverlayTriggerHover");
|
|
});
|
|
|
|
/**
|
|
* Affiche le bouton zones cachées en grand écran et en petit écran
|
|
*/
|
|
var tinyHidden = "<?php echo $this->getData(['theme', 'header', 'tinyHidden']); ?>" ;
|
|
<?php
|
|
include('./core/module/theme/lang/'. $this->getData(['config', 'i18n', 'langAdmin']) . '/lex_theme.php');
|
|
if( $this->getData(['theme', 'header', 'position']) === 'hide'
|
|
OR $this->getData(['theme', 'menu', 'position']) === 'hide'
|
|
OR $this->getData(['theme', 'footer', 'position']) === 'hide' ) { ?>
|
|
$(".showAll").css("display","block");
|
|
$(".speechBubble").text(" <?php echo $text['core_theme_view']['index'][0]; ?> ");
|
|
<?php } else { ?>
|
|
if( $(window).width() >= 800 || tinyHidden !== "1"){
|
|
$(".showAll").css("display","none");
|
|
$(".speechBubble").text(" <?php echo $text['core_theme_view']['index'][8]; ?> ");
|
|
} else {
|
|
$(".showAll").css("display","block");
|
|
$(".speechBubble").text(" <?php echo $text['core_theme_view']['index'][0]; ?> ");
|
|
}
|
|
<?php } ?>
|