diff --git a/site/blueprints/pages/investigations.yml b/site/blueprints/pages/investigations.yml index 0ee8ce8..7b15b5a 100644 --- a/site/blueprints/pages/investigations.yml +++ b/site/blueprints/pages/investigations.yml @@ -15,20 +15,12 @@ tabs: - width: 2/3 sections: investigations: fields/investigations - highlightTab: - label: Mise en avant + starredTab: + label: En avant icon: star fields: - pinnedInvestigations: - label: Enquêtes pinnées - type: pages - query: page('enquetes').children.listed - multiple: true - layout: list - text: "{{ page.title }}" - info: "{{ page.incidentDate }}" - superPinnedInvestigation: - label: Super pin (home) + featuredInvestigation: + label: À la une type: pages query: page('enquetes').children.listed multiple: false @@ -36,4 +28,16 @@ tabs: layout: list text: "{{ page.title }}" info: "{{ page.incidentDate }}" + width: 1/3 + help: Affichée en tête et en plus grand, avec son média de couverture (vidéo ou image). + pinnedInvestigations: + label: Enquêtes épinglées + type: pages + query: page('enquetes').children.listed + multiple: true + layout: list + text: "{{ page.title }}" + info: "{{ page.incidentDate }}" + width: 2/3 + help: Affichées après l'enquête "à la une", avant les autres mais dans le même format, simplement marquées par une 📌. seo: seo/page diff --git a/site/templates/home.php b/site/templates/home.php index 3a4490b..08ba960 100644 --- a/site/templates/home.php +++ b/site/templates/home.php @@ -45,16 +45,16 @@ $count = max(4, (int)$section->count()->value()); superPinnedInvestigation()->toPage(); + $featured = $enquetesPage->featuredInvestigation()->toPage(); $pinned = $enquetesPage->pinnedInvestigations()->toPages(); - if ($superPin) $pinned = $pinned->not($superPin); + if ($featured) $pinned = $pinned->not($featured); $list = []; $shownIds = []; - if ($superPin) { - $list[] = ['page' => $superPin, 'type' => 'super']; - $shownIds[] = $superPin->id(); + if ($featured) { + $list[] = ['page' => $featured, 'type' => 'super']; + $shownIds[] = $featured->id(); } foreach ($pinned as $p) {