{% extends 'base.html.twig' %}
{% block title %}SVS - {{"PRODUITS SENSIBLES"|trans}}{% endblock %}
{% block body %}
<style>
{% include "produitssensible/produitssensible.css" %}
</style>
<!-- Element -->
<div class="element1">
{% include "produitssensible/5/refait.html.twig" %}
</div>
<!-- Element -->
<div class="appElement element2 element_produitssensible_about">
{% include "produitssensible/aproposproduitssensible/index.html.twig" %}
</div>
<!-- Element -->
<div class="appElement element3 element_produitssensible_icons">
{% include "produitssensible/serviceIcons/index.html.twig" %}
</div>
<!-- Element -->
<div class="appElement element4 element_produitssensible_section">
<div class="position1"></div>
{% include "produitssensible/cadreSVS/element.html.twig" %}
</div>
<!-- EXECUTE SCRIPT FOR PRODUITSSENSIBLE PAGE -->
<script>
// HERE @VAR IMPORTANT FOR THIS SCRIPT
var viewportHeight = window.innerHeight;
var hasTitleAboutRun = false; // Variable pour suivre si initTitle_produitssensible_about a déjà été exécutée.
var hasTitleIconsRun = false; // Variable pour suivre si initTitle_produitssensible_icons a déjà été exécutée.
var hasTitleSectionRun = false; // Variable pour suivre si initTitle_produitssensible_section a déjà été exécutée.
// HERE FUNCTION TITLE_produitssensible_ABOUT
function initTitle_produitssensible_about() {
var typed_produitssensible_about = new Typed('.typed_produitssensible_about', {
strings: ['{{"Sentinelles du convoyage"|trans}}<br><span>{{"garants de la sûreté intégrale"|trans}}</span>'],
typeSpeed: 20,
startDelay: 250,
backDelay: 2500,
loop: false,
cursorChar: '<i class="fas fa-circle"></i>',
});
}
// HERE FUNCTION TITLE_produitssensible_ICONS
function initTitle_produitssensible_icons() {
var typed_produitssensible_icons = new Typed('.typed_produitssensible_icons', {
strings: ['{{"Convoi Protégé"|trans}}<br><span>{{"préparation pour un trajet sans risque"|trans}}</span>'],
typeSpeed: 25,
startDelay: 250,
backDelay: 2500,
loop: false,
cursorChar: '<i class="fas fa-circle"></i>',
});
}
// HERE FUNCTION TITLE_produitssensible_SECTION
function initTitle_produitssensible_section() {
var typed_produitssensible_section = new Typed('.typed_produitssensible_section', {
strings: ['{{"Une connaissance approfondie de la réglementation"|trans}}<br><span>{{"pour garantir la sécurité du transport des produits sensibles"|trans}}.</span>'],
typeSpeed: 25,
startDelay: 250,
backDelay: 2500,
loop: false,
cursorChar: '<i class="fas fa-circle"></i>',
});
}
// HERE EXECUTION OF SCRIPT @HOME
window.addEventListener('scroll', function() {
// HERE @VAR FOR element_produitssensible_about ELEMENT RECTANGLE
var element_produitssensible_about = document.querySelector('.element_produitssensible_about');
var rectangle_about = element_produitssensible_about.getBoundingClientRect();
if (!hasTitleAboutRun && rectangle_about.top < viewportHeight && rectangle_about.bottom > 0) {
initTitle_produitssensible_about();
hasTitleAboutRun = true; // Marquer que la fonction a été exécutée.
}
// HERE @VAR FOR element_produitssensible_icons ELEMENT RECTANGLE
var element_produitssensible_icons = document.querySelector('.element_produitssensible_icons');
var rectangle_icons = element_produitssensible_icons.getBoundingClientRect();
if (!hasTitleIconsRun && rectangle_icons.top < viewportHeight && rectangle_icons.bottom > 0) {
initTitle_produitssensible_icons();
hasTitleIconsRun = true; // Marquer que la fonction a été exécutée.
}
// HERE @VAR FOR element_produitssensible_section ELEMENT RECTANGLE
var element_produitssensible_section = document.querySelector('.element_produitssensible_section');
var rectangle_section = element_produitssensible_section.getBoundingClientRect();
if (!hasTitleSectionRun && rectangle_section.top < viewportHeight && rectangle_section.bottom > 0) {
initTitle_produitssensible_section();
hasTitleSectionRun = true; // Marquer que la fonction a été exécutée.
}
});
</script>
{% endblock %}