<?php 
$im=new thumbnail_tool(CHEMIN,CACHE_VIGNETTES,APP."images/");
$im->set_source(IMPORTS_URL.$item->getFile('illustration'));
$de=$item->getDescription('illustration');
?>
<div id="fw" class="px-3 pt-0">
    <div id="fw-visual">
        <div id="fw-image">
            <img src="<?= $im->vignette(FULLSIZE_W,FULLSIZE_H,false); ?>" alt="<?= $de ?>">
            <div class="fw-nav fw-prev" onclick="yc_vieweshowimage(-1)"></div>
            <div class="fw-nav fw-next" onclick="yc_vieweshowimage(1)"></div>
            <div class="fw-description ff-bold-secondary fs-small"><?php
                if($de){
                    echo "<span>".$de."</span>";
                }
                ?></div>
        </div>
    </div>
    <div id="fw-infos" class="p-3">
        <img onclick="yc_vieweshowclickimage(this)" class="img-object-fit aspectratio-1 mb-2" data-slideshow data-slideshowsrc="<?= $im->vignette(FULLSIZE_W,FULLSIZE_H,false) ?>" src="<?= $im->vignette(VIGNETTE_W,VIGNETTE_H,false) ?>" title="<?= $item->getDescription('illustration') ?>">

        <h2 class="mb-3"><?= $item->get("titre") ?></h2>
        <?php
    $liste=$item->getFilledValues();
             unset($liste['illustration']);
             unset($liste['titre']);    
             foreach($liste as $id => $val){
                 if($item->getParam($id,"snippet")){
                     $snippet=getSnippetFile("display_".$item->getParam($id,"snippet").".php");
                     include($snippet);
                 } else {
                     // voir s'il existe un snippet spécifique
                     $type=$item->getParam($id,"type");
                     $snippet=getSnippetFile("display_part_".$type.".php");
                     if(!file_exists($snippet)){
                         $snippet=getSnippetFile("display_part_default.php");
                     } 
                     include($snippet);
                 }
             }
             foreach(MODULES['insert_item'] as $insert){
                 include(CHEMIN.$insert);
             }
        ?>
    </div>
</div>