FINAL MERGE V2 (from antoine-merge branch)
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
Nonimart 2025-08-05 14:53:21 +02:00
parent b64b82ab9f
commit 1886840c70
46 changed files with 757 additions and 703 deletions

View File

@ -1,7 +1,6 @@
<?php
switch_to_blog(1);
?>
<?php get_template_part('template-components/footer/page-scroller'); ?>
</main>
@ -54,7 +53,6 @@ switch_to_blog(1);
<div class="menu-renovateur--footer menu-renovateur">
<?php get_template_part('template-components/footer/menu-renovateur-footer'); ?>
</div>
<?php
wp_nav_menu(
array(
@ -157,9 +155,13 @@ switch_to_blog(1);
</ul>
</div>
</footer>
</div>
<?php
restore_current_blog();
?>

0
front-page.php Executable file → Normal file
View File

View File

@ -16,4 +16,3 @@ require_once(__DIR__ . '/includes/wysiwyg.php');
require_once(__DIR__ . '/includes/search.php');
require_once(__DIR__ . '/includes/rooting.php');
require_once(__DIR__ . '/includes/forms.php');
require_once(__DIR__ . '/includes/wpml.php');

View File

@ -8,10 +8,10 @@
<link rel="pingback" href="<?php bloginfo('pingback_url'); ?>">
<?php wp_head(); ?>
</head>
<?php $currentLanguage = apply_filters('wpml_current_language', null); ?>
<?php
$currentLanguage = apply_filters('wpml_current_language', null);
switch_to_blog(1)
switch_to_blog(1);
?>
<body <?php body_class("homegrade-frontend-page ") ?> current-language="<?php echo $currentLanguage ?? "" ?>">
@ -35,10 +35,10 @@ switch_to_blog(1)
<?php get_template_part('template-components/header/mobile-brand'); ?>
<!-- MENU HOMEGRADE -->
<?php get_template_part('template-components/header/menu-homegrade'); ?>
<?php get_template_part('template-components/header/menu-renovateur'); ?>
<!-- SEARCH MODULE -->
<?php get_template_part('template-components/header/search-module'); ?>
</header>

0
includes/errorlog.php Executable file → Normal file
View File

View File

@ -7,6 +7,8 @@ function add_menu_item($menu_items)
return $menu_items;
}
function homegrade_stats_option_page()
{
?>
@ -88,6 +90,9 @@ function generate_order_datas_to_csv()
$document_id_nl = $document['id_nl'] ?? null;
$document_quantity_nl = $document['quantity_nl'] ?? null;
$dateCreatedRaw = $entry['date_created'] ?? '';
$dateCreated = $dateCreatedRaw ? date('d / m / Y', strtotime($dateCreatedRaw)) : '';
if (!$document_quantity_fr && !$document_quantity_nl) {
continue;
}
@ -103,6 +108,7 @@ function generate_order_datas_to_csv()
'company_type' => $companyType,
'zipCode' => $zipCode,
'userLanguage' => $userLanguage,
'order_date' => $dateCreated,
];
array_push($output_formatted_entries, $document_formatted_order_nl);
}
@ -119,6 +125,7 @@ function generate_order_datas_to_csv()
'company_type' => $companyType,
'zipCode' => $zipCode,
'userLanguage' => $userLanguage,
'order_date' => $dateCreated,
];
array_push($output_formatted_entries, $document_formatted_order_fr);
}
@ -136,7 +143,7 @@ function generate_order_datas_to_csv()
}
// Ajouter les en-têtes du CSV
fputcsv($file, ['Publication', 'Quantité', 'Langue de la publication', 'Thématique', 'ID de la brochure', 'Type d\'organisme', 'Code Postal', 'Langue de l\'utilisateur']);
fputcsv($file, ['Publication', 'Quantité', 'Langue de la publication', 'Thématique', 'ID de la brochure', 'Type d\'organisme', 'Code Postal', 'Langue de l\'utilisateur', 'Date de la commande']);
// Boucler sur chaque entrée formatée et l'écrire dans le CSV
foreach ($output_formatted_entries as $entry) {

0
includes/logos.php Executable file → Normal file
View File

View File

@ -68,7 +68,6 @@ function add_custom_item_to_menu($items, $args)
switch_to_blog(2);
// $home_url_metiers_patrimoine = get_home_url();
$home_url_metiers_patrimoine = get_the_permalink(43);
// switch_to_blog(1);
restore_current_blog();
$items .= '<li id="menu-item-artisan-du-patrimoine" class="menu-item menu-item-type-post_type menu-item-object-page menu-navlink ">';
@ -80,7 +79,6 @@ function add_custom_item_to_menu($items, $args)
/* WPML NAV SWITCHER */
ob_start();
// switch_to_blog(1);
restore_current_blog();
// do_action('wpml_language_switcher', array('flags' => false, 'translated' => false, 'link_current' => true));
do_action('wpml_add_language_selector');

View File

@ -42,9 +42,14 @@ function undo_create_term($term_id, $tt_id, $taxonomy)
REGISTER TAXONOMIES
--------------------*/
function homegrade_add_custom_taxonomies()
function homegrade_add_homegrade_custom_taxonomies()
{
$current_blog_id = get_current_blog_id();
// write_log("Current blog ID: " . $current_blog_id);
// if ($current_blog_id !== 1) {
// return; // Skip if not on the main site
// }
// ————— Thématiques —————
register_taxonomy('thematiques', ['questions', 'conseils', 'brochures', 'fiches-infos', 'videos-webinaires'], array(
@ -104,7 +109,6 @@ function homegrade_add_custom_taxonomies()
'name' => ' Général',
'slug' => 'general',
],
));
// ————— mots-clés —————
@ -131,7 +135,7 @@ function homegrade_add_custom_taxonomies()
));
}
add_action('init', 'homegrade_add_custom_taxonomies', 0);
add_action('init', 'homegrade_add_homegrade_custom_taxonomies', 0);
/* -----------------------
HIDE THEMATIQUE METABOX

View File

@ -196,8 +196,8 @@ function build_page_chapter_index($blocks)
if ($block['blockName'] == 'homegrade-content-blocks/content-heading' && isset($block['attrs']['title']) && isset($block['attrs']['headingLevel']) && $block['attrs']['headingLevel'] == "h2") {
array_push($chapterBlockIndex, [
'block-type' => $block['blockName'],
'anchor' => "#" . esc_html($block['attrs']['idName']),
'title' => esc_html($block['attrs']['title']),
'anchor' => "#" . strip_tags($block['attrs']['idName']),
'title' => strip_tags($block['attrs']['title']),
]);
}
if ($block['blockName'] == 'homegrade-content-blocks/chapitrage-thematique') {

0
includes/wysiwyg.php Executable file → Normal file
View File

View File

@ -224,3 +224,23 @@
@apply bg-patrimoine-sante-securite;
}
}
// Maybe Refactor ?
ol {
@apply list-decimal list-inside;
/* font-family: 'Railway', sans-serif; */
li {
list-style-type: decimal !important;
list-style-position: inside !important;
position: relative !important;
padding-left: 1.5em !important;
}
li:marker {
position: absolute !important;
left: 0 !important;
}
.block-editor-rich-text__editable {
display: inline-block !important;
}
}

0
resources/css/blocks/aides-financieres.css Executable file → Normal file
View File

View File

@ -1,5 +1,5 @@
.block-content-page-header {
@apply py-8 md:py-16 flex gap-12 justify-between mx-auto;
@apply py-8 md:py-16 lg:flex gap-12 justify-between mx-auto;
.section_titling {
@apply px-0 !mb-1;

0
resources/css/blocks/demarches-administratives.css Executable file → Normal file
View File

0
resources/css/blocks/home-header.css Executable file → Normal file
View File

View File

@ -1,11 +1,31 @@
.lightbox-gallery {
@apply grid sm:grid-cols-2 lg:grid-cols-3 gap-6;
img {
@apply h-full w-full object-cover max-h-80;
@apply h-full w-full object-cover max-h-80 rounded-lg;
}
&__picture {
@apply pointer-events-none;
}
&__trigger {
@apply block relative;
cursor: zoom-in;
/* content: url('../resources/img/graphic-assets/icone-external-link-purple.svg'); */
&:after {
transition: all 0.3s ease;
content: '';
@apply bg-contain bg-center w-16 h-16 top-1/2 right-1/2 absolute z-40 content-[''];
@apply opacity-0;
transform: translateY(10px);
translate: 50% -50%;
background-image: url('../resources/img/graphic-assets/icone-focus-galerie.svg');
}
&:hover:after {
transform: translateY(0px);
@apply opacity-100;
}
}
}
.lightbox {
@ -56,20 +76,22 @@
}
}
&__container {
@apply relative flex justify-center items-center bg-white;
@apply relative flex justify-center items-center bg-white rounded-xl;
width: 90%;
height: fit-content;
min-height: 90vh;
@apply my-4 mx-auto;
}
&__current-picture {
img {
@apply h-full w-full max-w-xl;
@apply h-full w-full max-w-xl rounded-lg;
max-height: 60vh;
}
}
&__current-picture-description {
@apply text-center text-neutral-800 pt-2;
}
}
@keyframes lightboxIn {

84
resources/css/blocks/show-thematiques.css Executable file → Normal file
View File

@ -81,87 +81,3 @@
pt-16;
}
}
.swiper-content {
@apply lg:px-24 relative max-w-screen-2xl mx-auto;
/* @apply bg-fuchsia-100; */
}
.swiper-container {
height: auto;
@apply px-3 overflow-hidden;
/* @apply bg-yellow-50; */
}
.swiper-wrapper {
@apply pt-24 pb-16 w-full flex-col lg:flex-row gap-y-20;
}
.swiper-slide {
@apply h-auto;
.card-thematique {
@apply h-full;
}
}
.thematique-button-next,
.thematique-button-prev {
@apply absolute top-1/2 z-50 opacity-80 hidden lg:block;
width: 60px;
height: 60px;
&:hover,
&:focus-visible {
@apply opacity-100;
filter: invert(13%) sepia(71%) saturate(4425%) hue-rotate(338deg) brightness(109%)
contrast(117%);
}
&:focus-visible {
@apply rounded-full;
}
}
.thematique-button-next {
@apply right-0 transform;
}
.thematique-button-prev {
@apply left-0;
}
.swiper-pagination {
@apply hidden lg:block;
}
.swiper-pagination-bullet {
@apply w-5 h-5 !mx-2 opacity-100 bg-white !border-2 !border-solid border-black;
}
.swiper-pagination-bullet:focus-visible {
outline-offset: 4px;
}
.swiper-pagination-bullet-active {
@apply bg-secondary !border-secondary opacity-100;
}
/* .swiper-slide {
background-color: red !important;
text-align: center;
font-size: 18px;
background: #fff;
display: flex;
justify-content: center;
align-items: center;
}
.swiper-slide img {
display: block;
width: 100%;
height: 100%;
object-fit: cover;
} */
.section-show-thematiques {
@apply pt-8 pb-8 px-8 md:px-16;
.thematiques-container {
@apply grid
grid-cols-3
gap-8
gap-y-32
max-w-screen-xl
mx-auto
pt-16;
}
}

View File

@ -0,0 +1,6 @@
.informative-message {
@apply bg-primary text-white p-8 col-span-4 rounded-3xl flex justify-center;
img {
@apply mr-2;
}
}

View File

@ -2,6 +2,7 @@
.previous-next-parcours,
.previous-next-questions {
@apply grid md:grid-cols-2 gap-x-6 gap-y-3 mx-auto max-w-screen-xl !px-6 xl:px-24 my-16;
&__previous,
&__next {
@apply flex gap-4 bg-white rounded-lg shadowed !py-4 px-6 items-center;
@ -12,6 +13,10 @@
@apply -translate-y-1 !bg-white;
}
}
&__post-thumbnail {
@apply w-20 h-20 object-cover rounded-lg;
}
&__previous {
@apply text-left justify-end;
&:after {

View File

@ -0,0 +1,22 @@
.side-card {
@apply py-4 px-6 w-fit bg-white shadowed text-neutral-900
font-bold rounded-2xl flex items-center justify-center my-5 gap-6;
transition: transform 0.3s;
&__title {
@apply leading-snug;
}
&__icon {
@apply w-16 h-16;
}
&:after {
@apply content-[''] w-3 h-3 block bg-no-repeat bg-center bg-contain mt-1 ml-4;
background-image: url('../resources/img/pictogrammes/Homegrade_back_icon.svg');
rotate: 180deg;
}
&:hover {
@apply translate-x-2;
}
}

View File

@ -1,8 +1,7 @@
/* Handling background page scroll */
body:has(header .menu-renovateur .sub-menu--open) {
@media screen and (max-width: 960px) {
@apply overflow-hidden;
@media screen and (max-width: 960px) {
/* FIXING BUG ON SAFARI */
.menu-renovateur__mobile-menu-toggle,
main {

View File

@ -9,8 +9,8 @@
h-fit
py-2
px-4
pl-10
md:pl-24
lg:pl-0
xl:pl-24
xl:px-8
2xl:px-32
my-0;
@ -61,7 +61,7 @@
&__navlist {
@apply w-full
max-w-screen-2xl mx-auto lg:flex justify-center pr-0;
max-w-screen-2xl mx-auto lg:flex justify-center items-center pr-0;
/* Highlight using list element */
li.current-page-parent > a,
@ -74,6 +74,7 @@
text-center
rounded-xl;
@apply w-fit lg:mx-0;
line-height: 1;
button,
a {
@ -96,6 +97,23 @@
outline-offset: 8px;
}
&#menu-item-artisan-du-patrimoine {
@apply bg-white text-sm text-neutral-900 font-bold rounded-full mr-1
2xl:mr-8 mt-4 lg:mt-0;
transition: all 0.3s ease-out;
&:focus-within,
&:hover {
@apply text-primary translate-x-1;
}
a {
@apply flex items-center justify-center !py-1;
}
a:before {
@apply w-6 h-6 mr-2 bg-contain bg-center bg-no-repeat content-[''];
background-image: url('../resources/img/pictogrammes/Homegrade_artisans-patrimoine.svg');
}
}
/* IF SUBMENU CHILD */
.menu-item__submenu-toggle {
@apply pr-4;
@ -118,6 +136,12 @@
transform: translateY(20%) rotate(225deg);
}
}
/* .wpml-ls-legacy-list-horizontal {
@apply p-0;
}
.wpml-ls {
@apply !p-0;
} */
}
/* &__burger-menu-toggle {
@apply lg:hidden

View File

@ -82,7 +82,7 @@ header#main-header {
}
}
@media screen and (max-width: 1024px) {
@media screen and (max-width: 960px) {
.menu-renovateur:not([opened]) {
@apply h-0 opacity-0;
transition: all 0.3s ease-in-out;

View File

@ -3,8 +3,9 @@
px-4
xl:px-8
relative
flex
flex-wrap
lg:flex
flex-nowrap
xl:flex-wrap
items-center
justify-between
lg:justify-center
@ -23,6 +24,7 @@
@apply order-1
mr-2
md:mr-12
lg:mr-0
xl:mr-auto
w-[140px]
md:w-[190px]
@ -35,13 +37,10 @@
@apply !opacity-90 rounded-md;
}
}
/* &__main-elements {
@apply w-full bg-red-200 flex justify-between items-center;
} */
&__navlist {
@apply w-fit
md:pl-14
xl:pl-14
lg:mx-auto
lg:flex
justify-center;
@ -169,7 +168,7 @@
}
&__submenu-toggle,
> a {
@apply p-6 rounded-3xl
@apply lg:p-4 xl:p-6 rounded-3xl
flex
items-center;
}
@ -305,7 +304,7 @@
.menu-item {
&__submenu-toggle,
> a {
@apply p-3;
@apply p-1 xl:p-3;
}
}
}

View File

@ -5,15 +5,20 @@
.conseils_wrapper {
@apply lg:flex gap-x-8 max-w-screen-2xl mx-auto pb-12;
aside {
@apply lg:sticky
left-0
h-fit
lg:max-w-md
top-4;
}
.chapter_index {
@apply bg-gray
w-full
lg:max-w-md
p-8
h-fit
lg:sticky
left-0
top-4
mb-4
/* lg:sticky */
rounded-2xl;
&__title {

0
resources/img/demo-img/chauffage.jpg Executable file → Normal file
View File

Before

Width:  |  Height:  |  Size: 116 KiB

After

Width:  |  Height:  |  Size: 116 KiB

View File

@ -1,75 +1,55 @@
<?xml version="1.0" encoding="UTF-8"?>
<svg id="renolution-primes" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 247.37 335.2">
<svg id="renolution-primes" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" viewBox="0 0 223.89 323.88">
<defs>
<style>
.cls-1 {
fill: url(#Dégradé_sans_nom_11-3);
}
.cls-1, .cls-2, .cls-3, .cls-4 {
.cls-1, .cls-2 {
stroke-width: 0px;
}
.cls-5 {
.cls-3 {
fill: #fff;
}
.cls-5, .cls-6 {
.cls-3, .cls-4 {
stroke: #000;
stroke-linecap: round;
stroke-linejoin: round;
stroke-width: 2px;
}
.cls-3 {
fill: url(#Dégradé_sans_nom_11-2);
}
.cls-4 {
.cls-2 {
fill: url(#Dégradé_sans_nom_11);
}
.cls-6 {
.cls-4 {
fill: none;
}
</style>
<linearGradient id="Dégradé_sans_nom_11" data-name="Dégradé sans nom 11" x1="-5717.86" y1="-104.98" x2="-5716.78" y2="-106.12" gradientTransform="translate(-85206.48 -17519.94) rotate(-169.4) scale(15.26 15.2)" gradientUnits="userSpaceOnUse">
<linearGradient id="Dégradé_sans_nom_11" data-name="Dégradé sans nom 11" x1="156.55" y1="6.44" x2="96.61" y2="49.84" gradientTransform="translate(34.23 119.5) rotate(-30) skewX(-30)" gradientUnits="userSpaceOnUse">
<stop offset="0" stop-color="#f3281d"/>
<stop offset="1" stop-color="#fe766f"/>
</linearGradient>
<linearGradient id="Dégradé_sans_nom_11-2" data-name="Dégradé sans nom 11" x1="-5712.77" y1="-100.18" x2="-5711.22" y2="-101.81" gradientTransform="translate(-86319.6 -10446.66) rotate(-174.12) scale(15.26 15.2)" xlink:href="#Dégradé_sans_nom_11"/>
<linearGradient id="Dégradé_sans_nom_11-3" data-name="Dégradé sans nom 11" x1="156.55" y1="17.77" x2="96.61" y2="61.16" gradientTransform="translate(34.23 117.75) rotate(-30) skewX(-30)" xlink:href="#Dégradé_sans_nom_11"/>
</defs>
<g id="Groupe_5560" data-name="Groupe 5560">
<g id="Groupe_5557" data-name="Groupe 5557">
<path id="Tracé_23834" data-name="Tracé 23834" class="cls-4" d="m233.24,96.7l-1.82.35c-.23.04-.38.27-.34.5.02.12.09.22.19.28l1.57.98c2.17,1.36,3.68,3.55,4.17,6.06l.35,1.82c.05.23.27.38.5.34.11-.02.22-.09.28-.19l.99-1.57c1.36-2.16,3.57-3.66,6.08-4.14l1.82-.35c.23-.04.38-.27.34-.5-.02-.12-.09-.22-.19-.28l-1.57-.99c-2.17-1.36-3.68-3.55-4.17-6.06l-.35-1.82c-.05-.23-.27-.38-.5-.34-.11.02-.22.09-.28.19l-.99,1.57c-1.36,2.16-3.56,3.66-6.07,4.14Z"/>
</g>
</g>
<g id="Groupe_5560-2" data-name="Groupe 5560">
<g id="Groupe_5557-2" data-name="Groupe 5557">
<path id="Tracé_23834-2" data-name="Tracé 23834" class="cls-3" d="m203.36,9.3l-2.56.71c-.32.09-.51.42-.42.75.05.16.16.3.31.38l2.36,1.22c3.25,1.68,5.66,4.63,6.65,8.15l.72,2.55c.09.32.43.51.75.42.16-.05.3-.16.37-.3l1.22-2.35c1.69-3.24,4.65-5.64,8.18-6.62l2.55-.71c.32-.09.51-.42.42-.75-.05-.16-.16-.3-.31-.38l-2.36-1.22c-3.25-1.68-5.66-4.63-6.65-8.15l-.71-2.55c-.09-.32-.43-.51-.75-.42-.16.05-.3.16-.37.3l-1.22,2.35c-1.69,3.24-4.65,5.64-8.17,6.62Z"/>
<g>
<polygon class="cls-3" points="8.06 262.47 112.64 322.88 112.64 204.34 60.35 108.7 8.06 143.97 8.06 262.47"/>
<polygon class="cls-3" points="112.64 322.88 217.22 263.31 217.22 143.97 112.64 204.34 112.64 322.88"/>
<polygon class="cls-3" points="222.89 145.24 166.82 42.68 54.67 107.43 110.75 209.99 222.89 145.24"/>
<polygon class="cls-3" points="54.67 107.43 1 143.97 8.06 143.97 56.71 111.15 54.67 107.43"/>
</g>
<polygon class="cls-1" points="99.81 144.19 107.72 156.63 183.15 116.01 175.13 103.23 99.81 144.19"/>
<g>
<polygon class="cls-3" points="161.61 29.38 161.61 76.8 105.87 104.49 105.87 61.48 161.61 29.38"/>
<path class="cls-3" d="m159.06,33.87l6.29,3.9-47.27,28.3c-1.26-.14-3.57-.45-5.99-1.05-.89-.22-1.98-.53-2.92-1.46-.34-.34-.57-.67-.71-.9,16.87-9.6,33.73-19.19,50.6-28.79Z"/>
<path class="cls-3" d="m105.37,62.89v76.11c.99,1.92,3,5.04,6.52,6.23,3.5,1.18,7.01.14,8.97-1,17.61-10.24,35.21-20.48,52.82-30.73V36.11l-53.65,31.06c-.66.32-5.06,2.35-9.7.24-2.89-1.32-4.39-3.56-4.95-4.51Z"/>
<line class="cls-4" x1="120.86" y1="144.23" x2="120.86" y2="67.17"/>
<path class="cls-3" d="m173.67,36.11l-2.53-1.81c-17.45,10.18-34.91,20.36-52.36,30.54-1.62.5-4.42,1.05-7.31-.08-1.18-.46-2.94-1.15-3.16-2.57-.19-1.27.89-2.74,2.7-3.61,16.86-9.73,33.73-19.46,50.59-29.19-.75-.48-1.49-.95-2.24-1.43-17.09,9.83-34.17,19.66-51.26,29.48-.78.49-2.81,1.88-2.99,3.96-.28,3.22,4.06,5.73,6.87,6.52,3.64,1.04,6.82-.2,8.04-.75,17.88-10.35,35.76-20.71,53.65-31.06Z"/>
</g>
<g>
<polygon class="cls-5" points="8.06 273.8 112.64 334.2 112.64 215.67 60.35 120.03 8.06 155.29 8.06 273.8"/>
<polygon class="cls-5" points="112.64 334.2 217.22 274.64 217.22 155.29 112.64 215.67 112.64 334.2"/>
<polygon class="cls-5" points="222.89 156.57 166.82 54.01 54.67 118.75 110.75 221.31 222.89 156.57"/>
<polygon class="cls-5" points="54.67 118.75 1 155.29 8.06 155.29 56.71 122.48 54.67 118.75"/>
<polygon class="cls-3" points="118.39 60.39 155.9 38.74 155.9 1 118.39 22.66 118.39 60.39"/>
<line class="cls-4" x1="150.32" y1="12.79" x2="123.97" y2="28"/>
<line class="cls-4" x1="150.32" y1="21.04" x2="123.97" y2="36.26"/>
<line class="cls-4" x1="150.32" y1="29.3" x2="123.97" y2="44.51"/>
<line class="cls-4" x1="150.32" y1="37.56" x2="123.97" y2="52.77"/>
</g>
<polygon class="cls-2" points="99.81 155.52 107.72 167.96 183.15 127.34 175.13 114.56 99.81 155.52"/>
<g>
<polygon class="cls-5" points="161.61 40.71 161.61 88.13 105.87 115.82 105.87 72.8 161.61 40.71"/>
<path class="cls-5" d="m159.06,45.2l6.29,3.9-47.27,28.3c-1.26-.14-3.57-.45-5.99-1.05-.89-.22-1.98-.53-2.92-1.46-.34-.34-.57-.67-.71-.9,16.87-9.6,33.73-19.19,50.6-28.79Z"/>
<path class="cls-5" d="m105.37,74.22v76.11c.99,1.92,3,5.04,6.52,6.23,3.5,1.18,7.01.14,8.97-1,17.61-10.24,35.21-20.48,52.82-30.73V47.44l-53.65,31.06c-.66.32-5.06,2.35-9.7.24-2.89-1.32-4.39-3.56-4.95-4.51Z"/>
<line class="cls-6" x1="120.86" y1="155.56" x2="120.86" y2="78.5"/>
<path class="cls-5" d="m173.67,47.44l-2.53-1.81c-17.45,10.18-34.91,20.36-52.36,30.54-1.62.5-4.42,1.05-7.31-.08-1.18-.46-2.94-1.15-3.16-2.57-.19-1.27.89-2.74,2.7-3.61,16.86-9.73,33.73-19.46,50.59-29.19-.75-.48-1.49-.95-2.24-1.43-17.09,9.83-34.17,19.66-51.26,29.48-.78.49-2.81,1.88-2.99,3.96-.28,3.22,4.06,5.73,6.87,6.52,3.64,1.04,6.82-.2,8.04-.75,17.88-10.35,35.76-20.71,53.65-31.06Z"/>
</g>
<g>
<polygon class="cls-5" points="118.39 71.72 155.9 50.07 155.9 12.33 118.39 33.98 118.39 71.72"/>
<line class="cls-6" x1="150.32" y1="24.11" x2="123.97" y2="39.33"/>
<line class="cls-6" x1="150.32" y1="32.37" x2="123.97" y2="47.58"/>
<line class="cls-6" x1="150.32" y1="40.63" x2="123.97" y2="55.84"/>
<line class="cls-6" x1="150.32" y1="48.88" x2="123.97" y2="64.1"/>
</g>
<polygon class="cls-1" points="165.6 88.63 131.03 108.58 131.03 97.66 165.6 77.7 165.6 88.63"/>
<polygon class="cls-2" points="165.6 77.3 131.03 97.26 131.03 86.33 165.6 66.37 165.6 77.3"/>
</svg>

Before

Width:  |  Height:  |  Size: 4.6 KiB

After

Width:  |  Height:  |  Size: 2.8 KiB

View File

@ -1,4 +1,4 @@
import editorInit from './editor';
import editorInit from './editor-shortcode';
import menuInit from './menus';
import SchemaBulletPointsInit from './schema-bullet-points';
import taxonomyThematiqueFaqInit from './taxonomy-thematique-(faq)';
@ -29,5 +29,4 @@ window.addEventListener('DOMContentLoaded', (event) => {
// NOTIFICATIONS
notificationsInit();
LightBoxSingle.init();
});

View File

@ -82,11 +82,8 @@ get_header();
'ctaTitle' => $relatedDocumentCtaTitle,
'hasInfoCapsule' => true,
));
?>
<?php /* -------
CONSEIL
---------------*/ ?>
@ -118,10 +115,5 @@ get_header();
<?php endwhile; ?>
<?php endif; ?>
<?php
get_footer();

0
style-login.css Executable file → Normal file
View File

View File

@ -3,7 +3,7 @@ Theme Name: Homegrade_Theme
Author: Deligraph
Author URI: https://deligraph.com/
Version: 1.0.0
Text Domain: homegrade-theme__texte-fonctionnel
Text Domain: metiers-du-patrimoine
Language: French
Test
*/

View File

@ -14,7 +14,7 @@ $thematiqueColorSlug = $mainThematique->slug;
<?php
$currentPage = get_post();
$parentPage = $currentPage->post_parent !== 0 ? get_post($currentPage->post_parent) : null;
$grandParentPage = $parentPage->post_parent ? get_post($parentPage->post_parent) : null;
$grandParentPage = $parentPage && $parentPage->post_parent ? get_post($parentPage->post_parent) : null;
?>
<ol>

View File

@ -3,18 +3,17 @@
?>
<nav class="menu-homegrade menu-homegrade--header" closed>
<!-- <div class="menu-homegrade__wrapper-container"> -->
<?php
wp_nav_menu(
array(
$args = array(
'container' => 'false',
'theme_location' => 'homegrade',
'li_class' => 'menu-navlink',
'fallback_cb' => false,
'menu_class' => 'menu-homegrade-header menu-homegrade__navlist',
'menu_id' => 'menu-homegrade-navlist',
);
wp_nav_menu($args);
?>
)
); ?>
</nav>

View File

@ -1,12 +1,9 @@
<?php
// switch_to_blog(1);
switch_to_blog(1);
$menu_name = 'renovateur';
$locations = get_nav_menu_locations();
$menu = wp_get_nav_menu_object($locations[$menu_name]);
if ($menu->taxonomy !== 'nav_menu') die();
$menuitems = wp_get_nav_menu_items($menu->term_id, array('order' => 'DESC'));
$logoID = get_theme_mod('custom_logo');
$logoSRC = wp_get_attachment_image_src($logoID, 'full');
@ -224,5 +221,5 @@ $logoSRC = wp_get_attachment_image_src($logoID, 'full');
</div>
<?php
// restore_current_blog();
restore_current_blog();
?>

View File

@ -1,5 +1,5 @@
<?php
// switch_to_blog(1);
switch_to_blog(1);
$logoID = get_theme_mod('custom_logo');
$logoSRC = wp_get_attachment_image_src($logoID, 'full');
?>
@ -41,5 +41,5 @@ $logoSRC = wp_get_attachment_image_src($logoID, 'full');
<?php
// restore_current_blog();
restore_current_blog();
?>

View File

@ -1,5 +1,5 @@
<?php
switch_to_blog(1);
// switch_to_blog(1);
?>
<div id="search-module" class="search-module" mobile-closed aria-hidden role="search">
<div class="search-module__wrapper-container">
@ -28,5 +28,5 @@ switch_to_blog(1);
</div>
<?php
restore_current_blog();
// restore_current_blog();
?>

View File

@ -0,0 +1,9 @@
<?php
$message = $args['message'];
if (!$message) return;
?>
<div class="informative-message">
<img src='<?php echo get_template_directory_uri() ?>/resources/img/pictogrammes/icone-info.svg' alt=''>
<p><?php echo $message ?></p>
</div>

View File

@ -0,0 +1,18 @@
<?php
$chapterBlockIndex = $args["chapterBlockIndex"];
?>
<div class="chapter_index">
<div class="chapter_index__titling">
<div class="icon">
<img src="<?php echo get_template_directory_uri() . '/resources/img/graphic-assets/icon-feather-menu.svg' ?>" alt="">
</div>
<h2 class="chapter_index__title"> <?php echo __("Dans ce conseil", "homegrade-theme__texte-fonctionnel") ?> </h2>
</div>
<ul class="chapter_index__list">
<div class="chapter_index__position-indicator"></div>
<?php foreach ($chapterBlockIndex as $chapter) : ?>
<li class="chapter_index__link"><a href="<?php echo $chapter['anchor'] ?>"><?php echo $chapter['title'] ?></a></li>
<?php endforeach; ?>
</ul>
</div>

View File

@ -0,0 +1,10 @@
<?php
// get network site 2 home url
$networkArtisan = get_blog_details(2);
$networkArtisanHomeUrl = isset($networkArtisan->home) ? $networkArtisan->home : '';
?>
<a href="<?php echo $networkArtisanHomeUrl ?>" class="side-card">
<img class="side-card__icon" src="<?php echo get_template_directory_uri() . '/resources/img/pictogrammes/Homegrade_chercher-entreprise.svg' ?>" alt=''>
<p class="side-card__title"> <?php echo __("Trouver un artisan du patrimoine pour réaliser vos rénovations", "metiers-patrimoine-theme") ?></p>
</a>

View File

@ -22,6 +22,7 @@
.share-button a {
@apply bg-primary !block w-8 h-8 rounded-full p-4 relative;
transition: transform 0.3s ease-in-out;
&:before {
@apply absolute w-3 h-3 bg-contain bg-center bg-no-repeat;
width: 25px;

View File

@ -75,12 +75,6 @@ $total_posts_found = $brochuresPosts->found_posts + $fichesInfosPosts->found_pos
"pageIcon" => $pageIcon,
"title" => get_the_title(get_queried_object_id()),
"description" => __("Découvrez toutes nos publications et outils en ligne", "homegrade-theme__texte-fonctionnel"),
"ctaSecondary" => array(
"title" => $receivePrintedPublicationsDatas['cta_title'] ?? null,
"url" => $receivePrintedPublicationsDatas['order_form_url'] ?? null,
"target" => "_blank",
"custom-class" => "paper-button",
),
));
?>
@ -239,15 +233,42 @@ $total_posts_found = $brochuresPosts->found_posts + $fichesInfosPosts->found_pos
<!-- LOAD MORE -->
<button id="load-more-brochures" class="cta cta--button cta--outline cta--button cta--centered cta--load-more" data-publication-type="brochures"><?php echo __("Consulter plus de brochures", "homegrade-theme__texte-fonctionnel__publications-archive-brochures") ?></button>
<?php wp_reset_postdata(); ?>
<?php /* ---------
DISTRIBUEZ PUBLICATIONS
-----------------*/ ?>
<?php
$sharePublications = get_field('section_share_publications', $current_page_id);
?>
</section>
<?php
/* -------------------------
DISTRIBUEZ PUBLICATIONS
-----------------------------*/
?>
<?php
$receivePrintedPublicationsDatas['order_form_url'] ?? null
?>
<section class="distribuez-publications wp-block-homegrade-content-blocks-highlight homegrade-blocks-highlight homegrade-blocks-highlight--classic homegrade-blocks-highlight--has-illustration">
<div class="homegrade-blocks-highlight--has-illustration__content">
<div class="homegrade-blocks-highlight__titling ">
<div class="icon"><img decoding="async" src="data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSIxNi4wMTIiIGhlaWdodD0iMTUuOTk5IiB2aWV3Qm94PSIwIDAgMTYuMDEyIDE1Ljk5OSI+CiAgPGcgaWQ9Ikljb25fZmVhdGhlci1saW5rIiBkYXRhLW5hbWU9Ikljb24gZmVhdGhlci1saW5rIiB0cmFuc2Zvcm09InRyYW5zbGF0ZSgtMS45OTMgLTIuMDA3KSI+CiAgICA8cGF0aCBpZD0iVHJhY8OpXzE4NTU5IiBkYXRhLW5hbWU9IlRyYWPDqSAxODU1OSIgZD0iTTE1LDEwLjcwN2EzLjUsMy41LDAsMCwwLDUuMjguMzc4bDIuMS0yLjFBMy41LDMuNSwwLDEsMCwxNy40Myw0LjAzM2wtMS4yLDEuMiIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoLTYuNDAyIDApIiBmaWxsPSJub25lIiBzdHJva2U9IiNmZmYiIHN0cm9rZS1saW5lY2FwPSJyb3VuZCIgc3Ryb2tlLWxpbmVqb2luPSJyb3VuZCIgc3Ryb2tlLXdpZHRoPSIyIi8+CiAgICA8cGF0aCBpZD0iVHJhY8OpXzE4NTYwIiBkYXRhLW5hbWU9IlRyYWPDqSAxODU2MCIgZD0iTTExLjQsMTQuOWEzLjUsMy41LDAsMCwwLTUuMjgtLjM3OGwtMi4xLDIuMUEzLjUsMy41LDAsMSwwLDguOTcsMjEuNTdsMS4yLTEuMiIgdHJhbnNmb3JtPSJ0cmFuc2xhdGUoMCAtNS41OSkiIGZpbGw9Im5vbmUiIHN0cm9rZT0iI2ZmZiIgc3Ryb2tlLWxpbmVjYXA9InJvdW5kIiBzdHJva2UtbGluZWpvaW49InJvdW5kIiBzdHJva2Utd2lkdGg9IjIiLz4KICA8L2c+Cjwvc3ZnPgo=" alt=""></div>
<h3 class="homegrade-blocks-highlight__block-title"><?php echo $receivePrintedPublicationsDatas['title'] ?></h3>
</div>
<div class="homegrade-blocks-highlight__content__innerblocks">
<p><?php echo $receivePrintedPublicationsDatas['description'] ?></p>
<div class="wp-block-button"><a class="wp-block-button__link wp-element-button" href="<?php echo $receivePrintedPublicationsDatas['order_form_url'] ?>" target="_blank" rel="noreferrer noopener"><?php echo $receivePrintedPublicationsDatas['cta_title'] ?></a></div>
</div>
</div>
<img class="homegrade-blocks-highlight--has-illustration__illustration" decoding="async" src="<?php echo get_template_directory_uri() . "/resources/img/illustrations/homegrade_brochure-impression-domicile.svg" ?>" alt="">
</section>
<?php /* -----------
FICHES INFOS
------------------*/ ?>