modif des notes
This commit is contained in:
@@ -49,7 +49,10 @@ saut de ligne dans texte libre (à la fin de chaque ligne) : `<br>`
|
||||
|
||||
`[citation]`
|
||||
|
||||
`[note]`
|
||||
|
||||
### SOUS-TITRE
|
||||
|
||||
`[moment]`
|
||||
|
||||
### ENCADRÉS
|
||||
@@ -71,6 +74,8 @@ saut de ligne dans texte libre (à la fin de chaque ligne) : `<br>`
|
||||
`[imgsmallsmall]`
|
||||

|
||||
|
||||
`[screenshot]`
|
||||
|
||||
`[fullpage2imgs]`
|
||||

|
||||
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
last_checked: 1707326193
|
||||
last_checked: 1711015441
|
||||
data:
|
||||
-
|
||||
title: 'macOS 14.0 Sonoma Apache Setup: Upgrading Homebrew'
|
||||
url: 'https://getgrav.org/blog/macos-ventura-apache-upgrade-homebrew'
|
||||
date: 1697803200
|
||||
nicetime: '4 months ago'
|
||||
nicetime: '5 months ago'
|
||||
-
|
||||
title: 'macOS 14.0 Sonoma Apache Setup: LetsEncrypt SSL'
|
||||
url: 'https://getgrav.org/blog/macos-sonoma-apache-ssl'
|
||||
date: 1697799780
|
||||
nicetime: '4 months ago'
|
||||
nicetime: '5 months ago'
|
||||
-
|
||||
title: 'macOS 14.0 Sonoma Apache Setup: MySQL, Xdebug & More...'
|
||||
url: 'https://getgrav.org/blog/macos-sonoma-apache-mysql-vhost-apc'
|
||||
date: 1697799600
|
||||
nicetime: '4 months ago'
|
||||
nicetime: '5 months ago'
|
||||
-
|
||||
title: 'macOS 14.0 Sonoma Apache Setup: Multiple PHP Versions'
|
||||
url: 'https://getgrav.org/blog/macos-sonoma-apache-multiple-php-versions'
|
||||
date: 1697796000
|
||||
nicetime: '4 months ago'
|
||||
nicetime: '5 months ago'
|
||||
-
|
||||
title: 'Big changes for Email plugin'
|
||||
url: 'https://getgrav.org/blog/new-email-plugin'
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1,81 +1,57 @@
|
||||
last_checked: 1707326192
|
||||
last_checked: 1711049804
|
||||
data:
|
||||
feed:
|
||||
-
|
||||
id: 31
|
||||
date: '2024-02-13 11:40'
|
||||
message: '🗜️Optimize your Grav site with Image Optimize'
|
||||
link: 'https://getgrav.org/premium/image-optimize'
|
||||
type: info
|
||||
location:
|
||||
- feed
|
||||
-
|
||||
id: 30
|
||||
date: '2023-03-09 11:40'
|
||||
message: '🗳️ Please <b>VOTE NOW</b> for Grav in the 2022 CMS Critic Awards'
|
||||
link: 'https://www.cmscritic.com/vote-for-the-cms-critic-2022-peoples-choice-awards/'
|
||||
date: '2024-02-13 11:40'
|
||||
message: '🗳️ Please <b>Cast your vote</b> for Grav in the 2024 CMS Critic Awards'
|
||||
link: 'https://cmscritic.com/vote?utm_source=cmscritic&utm_medium=featured_banner&utm_campaign=CMS+Critic'
|
||||
type: note
|
||||
location:
|
||||
- feed
|
||||
-
|
||||
id: 29
|
||||
date: '2022-01-02 11:40'
|
||||
message: '🎉 Grav 1.7.38 released to start the new year'
|
||||
link: 'https://getgrav.org/downloads'
|
||||
type: info
|
||||
location:
|
||||
- feed
|
||||
-
|
||||
id: 28
|
||||
date: '2021-04-23 11:40'
|
||||
message: '🚨 Grav 1.7.13 released, please update!'
|
||||
link: 'https://getgrav.org/downloads'
|
||||
type: info
|
||||
location:
|
||||
- feed
|
||||
-
|
||||
id: 26
|
||||
date: '2020-02-21 00:01'
|
||||
message: '🚀 Grav Premium available. Turbo-charge your Grav site today.'
|
||||
date: '2024-02-10 00:01'
|
||||
message: '🚀 Grav Premium Plugins and Themes available. Turbo-charge your Grav site today.'
|
||||
link: 'https://getgrav.org/premium'
|
||||
type: info
|
||||
location:
|
||||
- feed
|
||||
-
|
||||
id: 24
|
||||
date: '2019-10-03 11:27'
|
||||
message: '🙏 Thanks to our amazing community, Grav was voted <b>Best Flat File CMS</b> in the 2019 CMS Critics'' Awards!'
|
||||
link: 'https://www.cmscritic.com/awards/'
|
||||
type: info
|
||||
location:
|
||||
- feed
|
||||
-
|
||||
id: 23
|
||||
date: '2018-11-15 15:50'
|
||||
message: '🙊 Grav community chat has moved from Slack to <span class=''fa fa-comments''></span> Discord'
|
||||
link: 'https://chat.getgrav.org'
|
||||
type: info
|
||||
location:
|
||||
- feed
|
||||
-
|
||||
id: 12
|
||||
date: '2017-02-17 15:15'
|
||||
date: '2024-01-17 15:15'
|
||||
message: '☕️ Support Grav for the price of a <span class=''fa fa-coffee''></span> a month!'
|
||||
link: 'https://opencollective.com/grav'
|
||||
type: note
|
||||
location:
|
||||
- feed
|
||||
-
|
||||
id: 4
|
||||
date: '2016-08-05 02:23'
|
||||
message: '💌 Join the Grav mailing list to stay in the loop!'
|
||||
link: 'http://eepurl.com/b41_oP'
|
||||
id: 23
|
||||
date: '2024-01-05 15:50'
|
||||
message: '🙊 Grav community chat has moved from Slack to <span class=''fa fa-comments''></span> Discord'
|
||||
link: 'https://chat.getgrav.org'
|
||||
type: info
|
||||
location:
|
||||
- feed
|
||||
-
|
||||
id: 3
|
||||
date: '2016-08-05 02:23'
|
||||
message: '🐥 Please follow us on Twitter'
|
||||
link: 'https://twitter.com/getgrav'
|
||||
type: note
|
||||
id: 24
|
||||
date: '2024-01-05 11:27'
|
||||
message: '🙏 Thanks to our amazing community, Grav was voted <b>Best Flat File CMS</b> in the 2019 CMS Critics'' Awards!'
|
||||
link: 'https://www.cmscritic.com/awards/'
|
||||
type: info
|
||||
location:
|
||||
- feed
|
||||
-
|
||||
id: 2
|
||||
date: '2016-08-05 02:23'
|
||||
date: '2024-01-05 02:23'
|
||||
message: '🎖 Don''t forget to star Grav on GitHub!'
|
||||
link: 'https://github.com/getgrav/grav'
|
||||
type: info
|
||||
@@ -85,7 +61,7 @@ data:
|
||||
-
|
||||
id: 27
|
||||
date: '2020-02-21 00:01'
|
||||
message: "<style>\n.dashboard-notifications-container, .dashboard-notifications-container .alert, .themes-notifications-container, .themes-notifications-container .alert, .plugins-notifications-container, .plugins-notifications-container .alert {\n margin: 0;\n padding: 0; \n}\n.dashboard-notifications-container .alert.position-dashboard:before,\n.themes-notifications-container .alert.position-themes:before,\n.plugins-notifications-container .alert.position-plugins:before,\n.hide-after-load {\n display: none;\n}\n</style>\n\n<span class=\"hide-after-load\">Loading...</span>\n<link href=\"https://getgrav.org/notifications/grav-premium-notification.css\" type=\"text/css\" rel=\"stylesheet\">\n<script src=\"https://getgrav.org/notifications/grav-premium-notification.js\" async></script>\n<div class=\"gp-banner hidden\">\n <div class=\"gp-image\">\n <img src=\"https://getgrav.org/user/themes/planetoid/images/grav-premium-logo-white.svg\" />\n </div>\n <div class=\"gp-sentences\">\n <span>Turbo-charge your Grav site - from the creators of Grav</span>\n <span>Downloads Pro - Powerful download manager directly integrated with Grav</span>\n <span>Algolia Pro - Class-leading AI-powered search made easy for Grav</span>\n <span>SEO-Magic - Advanced SEO tool for Grav with automatic webshot generator</span>\n <span>Typhoon - The most powerful Grav theme ever built, based on Tailwind 3</span>\n <span>NextGen Editor - The most advanced WYSIWYM editor for Grav</span>\n <span>Cloudflare Manager - Configure and manage your domain right within the admin</span>\n <span>Lightbox Gallery - A light, versatile and mobile friendly Lightbox Gallery</span>\n </div>\n <a class=\"gp-learn-more button\" href=\"https://getgrav.org/premium\" target=\"_blank\">Learn more</a>\n</div>\n"
|
||||
message: "<style>\n.dashboard-notifications-container, .dashboard-notifications-container .alert, .themes-notifications-container, .themes-notifications-container .alert, .plugins-notifications-container, .plugins-notifications-container .alert {\n margin: 0;\n padding: 0; \n}\n.dashboard-notifications-container .alert.position-dashboard:before,\n.themes-notifications-container .alert.position-themes:before,\n.plugins-notifications-container .alert.position-plugins:before,\n.hide-after-load {\n display: none;\n}\n</style>\n\n<span class=\"hide-after-load\">Loading...</span>\n<link href=\"https://getgrav.org/notifications/grav-premium-notification.css\" type=\"text/css\" rel=\"stylesheet\">\n<script src=\"https://getgrav.org/notifications/grav-premium-notification.js\" async></script>\n<div class=\"gp-banner hidden\">\n <div class=\"gp-image\">\n <img src=\"https://getgrav.org/user/themes/planetoid/images/grav-premium-logo-white.svg\" />\n </div>\n <div class=\"gp-sentences\">\n <span>Turbo-charge your Grav site - from the creators of Grav</span>\n <span>Image Optimize - Optimize all the images on your Grav site</span>\n <span>Downloads Pro - Powerful download manager directly integrated with Grav</span>\n <span>Algolia Pro - Class-leading AI-powered search made easy for Grav</span>\n <span>SEO-Magic - Advanced SEO tool for Grav with automatic webshot generator</span>\n <span>Typhoon - The most powerful Grav theme ever built, based on Tailwind 3</span>\n <span>Cloudflare Manager - Configure and manage your domain right within the admin</span>\n <span>Lightbox Gallery - A light, versatile and mobile friendly Lightbox Gallery</span>\n </div>\n <a class=\"gp-learn-more button\" href=\"https://getgrav.org/premium\" target=\"_blank\">Learn more</a>\n</div>\n"
|
||||
type: notice
|
||||
link: 'https://getgrav.org/premium'
|
||||
location:
|
||||
@@ -96,7 +72,7 @@ data:
|
||||
-
|
||||
id: 27
|
||||
date: '2020-02-21 00:01'
|
||||
message: "<style>\n.dashboard-notifications-container, .dashboard-notifications-container .alert, .themes-notifications-container, .themes-notifications-container .alert, .plugins-notifications-container, .plugins-notifications-container .alert {\n margin: 0;\n padding: 0; \n}\n.dashboard-notifications-container .alert.position-dashboard:before,\n.themes-notifications-container .alert.position-themes:before,\n.plugins-notifications-container .alert.position-plugins:before,\n.hide-after-load {\n display: none;\n}\n</style>\n\n<span class=\"hide-after-load\">Loading...</span>\n<link href=\"https://getgrav.org/notifications/grav-premium-notification.css\" type=\"text/css\" rel=\"stylesheet\">\n<script src=\"https://getgrav.org/notifications/grav-premium-notification.js\" async></script>\n<div class=\"gp-banner hidden\">\n <div class=\"gp-image\">\n <img src=\"https://getgrav.org/user/themes/planetoid/images/grav-premium-logo-white.svg\" />\n </div>\n <div class=\"gp-sentences\">\n <span>Turbo-charge your Grav site - from the creators of Grav</span>\n <span>Downloads Pro - Powerful download manager directly integrated with Grav</span>\n <span>Algolia Pro - Class-leading AI-powered search made easy for Grav</span>\n <span>SEO-Magic - Advanced SEO tool for Grav with automatic webshot generator</span>\n <span>Typhoon - The most powerful Grav theme ever built, based on Tailwind 3</span>\n <span>NextGen Editor - The most advanced WYSIWYM editor for Grav</span>\n <span>Cloudflare Manager - Configure and manage your domain right within the admin</span>\n <span>Lightbox Gallery - A light, versatile and mobile friendly Lightbox Gallery</span>\n </div>\n <a class=\"gp-learn-more button\" href=\"https://getgrav.org/premium\" target=\"_blank\">Learn more</a>\n</div>\n"
|
||||
message: "<style>\n.dashboard-notifications-container, .dashboard-notifications-container .alert, .themes-notifications-container, .themes-notifications-container .alert, .plugins-notifications-container, .plugins-notifications-container .alert {\n margin: 0;\n padding: 0; \n}\n.dashboard-notifications-container .alert.position-dashboard:before,\n.themes-notifications-container .alert.position-themes:before,\n.plugins-notifications-container .alert.position-plugins:before,\n.hide-after-load {\n display: none;\n}\n</style>\n\n<span class=\"hide-after-load\">Loading...</span>\n<link href=\"https://getgrav.org/notifications/grav-premium-notification.css\" type=\"text/css\" rel=\"stylesheet\">\n<script src=\"https://getgrav.org/notifications/grav-premium-notification.js\" async></script>\n<div class=\"gp-banner hidden\">\n <div class=\"gp-image\">\n <img src=\"https://getgrav.org/user/themes/planetoid/images/grav-premium-logo-white.svg\" />\n </div>\n <div class=\"gp-sentences\">\n <span>Turbo-charge your Grav site - from the creators of Grav</span>\n <span>Image Optimize - Optimize all the images on your Grav site</span>\n <span>Downloads Pro - Powerful download manager directly integrated with Grav</span>\n <span>Algolia Pro - Class-leading AI-powered search made easy for Grav</span>\n <span>SEO-Magic - Advanced SEO tool for Grav with automatic webshot generator</span>\n <span>Typhoon - The most powerful Grav theme ever built, based on Tailwind 3</span>\n <span>Cloudflare Manager - Configure and manage your domain right within the admin</span>\n <span>Lightbox Gallery - A light, versatile and mobile friendly Lightbox Gallery</span>\n </div>\n <a class=\"gp-learn-more button\" href=\"https://getgrav.org/premium\" target=\"_blank\">Learn more</a>\n</div>\n"
|
||||
type: notice
|
||||
link: 'https://getgrav.org/premium'
|
||||
location:
|
||||
@@ -107,19 +83,10 @@ data:
|
||||
-
|
||||
id: 27
|
||||
date: '2020-02-21 00:01'
|
||||
message: "<style>\n.dashboard-notifications-container, .dashboard-notifications-container .alert, .themes-notifications-container, .themes-notifications-container .alert, .plugins-notifications-container, .plugins-notifications-container .alert {\n margin: 0;\n padding: 0; \n}\n.dashboard-notifications-container .alert.position-dashboard:before,\n.themes-notifications-container .alert.position-themes:before,\n.plugins-notifications-container .alert.position-plugins:before,\n.hide-after-load {\n display: none;\n}\n</style>\n\n<span class=\"hide-after-load\">Loading...</span>\n<link href=\"https://getgrav.org/notifications/grav-premium-notification.css\" type=\"text/css\" rel=\"stylesheet\">\n<script src=\"https://getgrav.org/notifications/grav-premium-notification.js\" async></script>\n<div class=\"gp-banner hidden\">\n <div class=\"gp-image\">\n <img src=\"https://getgrav.org/user/themes/planetoid/images/grav-premium-logo-white.svg\" />\n </div>\n <div class=\"gp-sentences\">\n <span>Turbo-charge your Grav site - from the creators of Grav</span>\n <span>Downloads Pro - Powerful download manager directly integrated with Grav</span>\n <span>Algolia Pro - Class-leading AI-powered search made easy for Grav</span>\n <span>SEO-Magic - Advanced SEO tool for Grav with automatic webshot generator</span>\n <span>Typhoon - The most powerful Grav theme ever built, based on Tailwind 3</span>\n <span>NextGen Editor - The most advanced WYSIWYM editor for Grav</span>\n <span>Cloudflare Manager - Configure and manage your domain right within the admin</span>\n <span>Lightbox Gallery - A light, versatile and mobile friendly Lightbox Gallery</span>\n </div>\n <a class=\"gp-learn-more button\" href=\"https://getgrav.org/premium\" target=\"_blank\">Learn more</a>\n</div>\n"
|
||||
message: "<style>\n.dashboard-notifications-container, .dashboard-notifications-container .alert, .themes-notifications-container, .themes-notifications-container .alert, .plugins-notifications-container, .plugins-notifications-container .alert {\n margin: 0;\n padding: 0; \n}\n.dashboard-notifications-container .alert.position-dashboard:before,\n.themes-notifications-container .alert.position-themes:before,\n.plugins-notifications-container .alert.position-plugins:before,\n.hide-after-load {\n display: none;\n}\n</style>\n\n<span class=\"hide-after-load\">Loading...</span>\n<link href=\"https://getgrav.org/notifications/grav-premium-notification.css\" type=\"text/css\" rel=\"stylesheet\">\n<script src=\"https://getgrav.org/notifications/grav-premium-notification.js\" async></script>\n<div class=\"gp-banner hidden\">\n <div class=\"gp-image\">\n <img src=\"https://getgrav.org/user/themes/planetoid/images/grav-premium-logo-white.svg\" />\n </div>\n <div class=\"gp-sentences\">\n <span>Turbo-charge your Grav site - from the creators of Grav</span>\n <span>Image Optimize - Optimize all the images on your Grav site</span>\n <span>Downloads Pro - Powerful download manager directly integrated with Grav</span>\n <span>Algolia Pro - Class-leading AI-powered search made easy for Grav</span>\n <span>SEO-Magic - Advanced SEO tool for Grav with automatic webshot generator</span>\n <span>Typhoon - The most powerful Grav theme ever built, based on Tailwind 3</span>\n <span>Cloudflare Manager - Configure and manage your domain right within the admin</span>\n <span>Lightbox Gallery - A light, versatile and mobile friendly Lightbox Gallery</span>\n </div>\n <a class=\"gp-learn-more button\" href=\"https://getgrav.org/premium\" target=\"_blank\">Learn more</a>\n</div>\n"
|
||||
type: notice
|
||||
link: 'https://getgrav.org/premium'
|
||||
location:
|
||||
- dashboard
|
||||
- plugins
|
||||
- themes
|
||||
none:
|
||||
-
|
||||
id: 15
|
||||
date: '2017-11-16 12:15'
|
||||
message: 'We won! <b>Grav</b> voted "Best Flat File CMS" in the 2017 CMS Critic Awards!'
|
||||
link: 'https://getgrav.org/blog/cms-critic-award-2017'
|
||||
type: note
|
||||
location:
|
||||
- none
|
||||
|
||||
@@ -10,6 +10,11 @@ img {
|
||||
.imgsmallsmall {
|
||||
padding-left: calc((var(--pagedjs-pagebox-width) / var(--cols)) + 10mm);
|
||||
}
|
||||
|
||||
.screenshot {
|
||||
padding-left: calc((var(--pagedjs-pagebox-width) / var(--cols)) + 6mm);
|
||||
padding-right: 16mm;
|
||||
}
|
||||
|
||||
.imgsmall_bottom {
|
||||
break-after: page;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
.latour_nohead, .lampe_nohead {
|
||||
font-family: 'Novel';
|
||||
font-weight: normal;
|
||||
margin-top: 5mm !important;
|
||||
margin-top: 5mm;
|
||||
margin-left: calc(var(--pagedjs-pagebox-width) / var(--cols));
|
||||
margin-right: -16mm;
|
||||
margin-bottom: 5mm;
|
||||
@@ -17,8 +17,9 @@
|
||||
max-height: 198mm;
|
||||
}
|
||||
|
||||
.pagedjs_page_content section div div div div:first-child:is(.latour),
|
||||
.pagedjs_page_content section div div div div:nth-child(2):is(.latour[data-split-from]) {
|
||||
.pagedjs_page_content section div div div div:first-child:is(.latour, .lampe, .latour_nohead, .lampe_nohead),
|
||||
.pagedjs_page_content section div div div div:nth-child(2):is(
|
||||
.latour[data-split-from], .latour_nohead[data-split-from], .lampe[data-split-from], .lampe_nohead[data-split-from]) {
|
||||
margin-top: 0mm !important;
|
||||
}
|
||||
|
||||
|
||||
@@ -24,10 +24,14 @@
|
||||
column-fill: auto;
|
||||
line-height: 12pt;
|
||||
font-size: 9pt;
|
||||
font-weight: bold;
|
||||
font-weight: normal;
|
||||
z-index: 1;
|
||||
position: relative;
|
||||
}
|
||||
|
||||
.bibliographie em {
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.bibliographie a {
|
||||
word-break: break-all;
|
||||
|
||||
@@ -71,7 +71,8 @@ a {
|
||||
padding-right: 16mm;
|
||||
hyphens: auto;
|
||||
font-style: italic;
|
||||
margin-top: 4mm;
|
||||
margin-top: 10mm;
|
||||
margin-bottom: 10mm;
|
||||
}
|
||||
|
||||
.citation .guillement_ouvrant {
|
||||
|
||||
@@ -87,21 +87,10 @@ if (debug) console.log('start colors');
|
||||
if (bibliographie) {
|
||||
bibliographie.style.color = atelierColor;
|
||||
// set bg et sprays
|
||||
let bibliographiePage = bibliographie.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement.parentElement; // désolé
|
||||
let bibliographiePage = bibliographie.closest('.pagedjs_page');
|
||||
bibliographiePage.style.backgroundColor = bgColor;
|
||||
|
||||
let nextPage;
|
||||
if (bibliographiePage.parentElement.classList.contains('pagedjs_sheet')) {
|
||||
nextPage = bibliographiePage.parentElement?.parentElement?.nextElementSibling?.firstElementChild;
|
||||
} else {
|
||||
nextPage = bibliographiePage.parentElement?.nextElementSibling?.firstElementChild;
|
||||
}
|
||||
|
||||
if (!bibliographie.closest('.pagedjs_page').previousElementSibling.querySelector('.bibliographie')) {
|
||||
if (nextPage) {
|
||||
nextPage.style.backgroundColor = bgColor;
|
||||
}
|
||||
|
||||
if (bibliographiePage.classList.contains('pagedjs_left_page')) {
|
||||
let sprayImg = document.createElement('img');
|
||||
sprayImg.setAttribute('src', sprays[atelierIndex - 1]);
|
||||
sprayImg.style.height = "242mm";
|
||||
@@ -110,13 +99,12 @@ if (debug) console.log('start colors');
|
||||
sprayImg.style.top = "-22mm";
|
||||
sprayImg.style.right = "-20mm";
|
||||
sprayImg.style.mixBlendMode = "multiply";
|
||||
sprayImg.style.opacity = "0.75";
|
||||
|
||||
let nextBiblioPageEl = bibliographiePage.parentElement.nextElementSibling?.querySelector('.bibliographie');
|
||||
if (nextBiblioPageEl) {
|
||||
bibliographiePage.parentElement.nextElementSibling?.querySelector('.bibliographie').insertAdjacentElement("afterend", sprayImg);
|
||||
} else {
|
||||
bibliographiePage.parentElement.parentElement.nextElementSibling?.querySelector('.pagedjs_page_content').appendChild(sprayImg);
|
||||
if (!bibliographiePage.nextElementSibling.querySelector('.bibliographie')) {
|
||||
bibliographiePage.nextElementSibling.style.backgroundColor = bgColor;
|
||||
}
|
||||
bibliographiePage.nextElementSibling.querySelector('.pagedjs_page_content').appendChild(sprayImg);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -48,8 +48,8 @@ if (debug) console.log('start imgsFullspread');
|
||||
}
|
||||
if (fullspreadEl.classList.contains('doublepage_bigleft')
|
||||
|| fullspreadEl.classList.contains('doublepage_bigright')) {
|
||||
let smallImgSrc = fullspreadEl.lastElementChild?.getAttribute('src');
|
||||
fullspreadEl.lastElementChild?.remove();
|
||||
let smallImgSrc = fullspreadEl.querySelector('img:last-of-type')?.getAttribute('src');
|
||||
fullspreadEl.querySelector('img:last-of-type')?.remove();
|
||||
let smallImg = document.createElement('img');
|
||||
smallImg.setAttribute('src', smallImgSrc);
|
||||
let smallImgEl = document.createElement('div');
|
||||
|
||||
@@ -32,6 +32,10 @@ if (debug) console.log('start inserts');
|
||||
plainColor.style.top = "-22mm";
|
||||
encart.parentNode.prepend(plainColor);
|
||||
}
|
||||
|
||||
if (encart.previousElementSibling?.classList.contains('breakbefore')) {
|
||||
encart.style.marginTop = "0mm";
|
||||
}
|
||||
}
|
||||
|
||||
})();
|
||||
|
||||
@@ -6,33 +6,37 @@ if (debug) console.log('start addInsertIcons');
|
||||
let encarts = document.querySelectorAll('.latour, .latour_nohead, .lampe, .lampe_nohead');
|
||||
|
||||
for(let encart of encarts) {
|
||||
let headContent = encart.firstChild
|
||||
let headerEl = document.createElement('div');
|
||||
headerEl.setAttribute('class', 'encart-header')
|
||||
let iconImg = document.createElement('img');
|
||||
let imgFile = encart.classList.contains('latour') || encart.classList.contains('latour_nohead') ? 'map' : 'lampe';
|
||||
iconImg.setAttribute('src', `/user/themes/carnet-atterrissage/assets/${ imgFile }.png`);
|
||||
|
||||
if (encart.classList.contains('latour_nohead') || encart.classList.contains('lampe_nohead')) {
|
||||
headerEl.style.flexDirection = 'column';
|
||||
headerEl.style.alignItems = 'flex-start';
|
||||
headerEl.style.fontWeight = 'normal';
|
||||
encart.style.paddingTop = '5mm';
|
||||
encart.style.paddingBottom = '5mm';
|
||||
iconImg.style.marginBottom = '2mm';
|
||||
iconImg.style.margin = '0';
|
||||
iconImg.style.marginBottom = '2.5mm';
|
||||
}
|
||||
|
||||
headerEl.append(iconImg);
|
||||
headerEl.append(headContent);
|
||||
|
||||
encart.firstChild?.remove();
|
||||
encart.prepend(headerEl);
|
||||
|
||||
if (encart.querySelector('.encart-header').nextElementSibling == null) {
|
||||
encart.querySelector('.encart-header').style.marginBottom = '0';
|
||||
if (encart.innerHTML.indexOf("<") === -1) {
|
||||
encart.innerHTML = '<p>' + encart.innerHTML;
|
||||
encart.innerHTML = encart.innerHTML + '</p>';
|
||||
} else {
|
||||
// to check if the first tag is a span
|
||||
if (encart.innerHTML, encart.innerHTML[encart.innerHTML.indexOf("<") + 1] === 's') {
|
||||
encart.innerHTML = encart.innerHTML.substring(0, encart.innerHTML.indexOf('</span>') + 7) + '</p>' + encart.innerHTML.substring(encart.innerHTML.indexOf('</span>') + 7);
|
||||
} else {
|
||||
encart.innerHTML = encart.innerHTML.substring(0, encart.innerHTML.indexOf('<')) + '</p>' + encart.innerHTML.substring(encart.innerHTML.indexOf('<'));
|
||||
}
|
||||
encart.innerHTML = '<p>' + encart.innerHTML;
|
||||
}
|
||||
|
||||
let headContent = encart.firstElementChild;
|
||||
let iconImg = document.createElement('img');
|
||||
let imgFile = encart.classList.contains('latour') || encart.classList.contains('latour_nohead') ? 'map' : 'lampe';
|
||||
iconImg.setAttribute('src', `/user/themes/carnet-atterrissage/assets/${ imgFile }.png`);
|
||||
|
||||
if (encart.classList.contains('latour_nohead') || encart.classList.contains('lampe_nohead')) {
|
||||
encart.prepend(iconImg);
|
||||
iconImg.style.marginTop = '3mm';
|
||||
iconImg.style.width = '8mm';
|
||||
} else {
|
||||
headContent.prepend(iconImg);
|
||||
headContent.classList.add('encart-header');
|
||||
}
|
||||
|
||||
if (encart.querySelector('.encart-header')
|
||||
&& encart.querySelector('.encart-header')?.nextElementSibling == null) {
|
||||
encart.querySelector('.encart-header').style.marginBottom = '0';
|
||||
}
|
||||
}
|
||||
|
||||
})();
|
||||
|
||||
@@ -67,7 +67,7 @@ if (debug) console.log('start footnotes');
|
||||
let partie = 0;
|
||||
let notes = document.querySelectorAll('.note');
|
||||
let noteTitleNextEl;
|
||||
let prevNoteContent;
|
||||
let notesContent = [];
|
||||
|
||||
for (let note of notes) {
|
||||
let currentPartie = findH3InAncestorsAndSiblings(note, false);
|
||||
@@ -82,31 +82,35 @@ if (debug) console.log('start footnotes');
|
||||
// insert before the next partie page
|
||||
findH3InAncestorsAndSiblings(note, true).parentNode.insertBefore(notePageTitle, findH3InAncestorsAndSiblings(note, true));
|
||||
noteNumber = 1;
|
||||
notesContent = [];
|
||||
partie++;
|
||||
notePageTitle.setAttribute('id', 'note_page_title_' + partie);
|
||||
noteTitleNextEl = document.getElementById(`note_page_title_${partie}`).nextElementSibling;
|
||||
let notesContentEl = document.createElement('div');
|
||||
notesContentEl.setAttribute('id', `notes_content_${partie}`);
|
||||
notesContentEl.classList.add('note_text');
|
||||
noteTitleNextEl.parentNode.insertBefore(notesContentEl, noteTitleNextEl);
|
||||
}
|
||||
|
||||
if (noteContent != prevNoteContent) {
|
||||
|
||||
if (!notesContent.includes(noteContent)) {
|
||||
notesContent.push(noteContent);
|
||||
let noteTextEl = document.createElement('p');
|
||||
noteTextEl.setAttribute('class', 'note_text');
|
||||
noteTextEl.innerHTML = '<span class="note_texte_number">' + noteNumber + '</span><span> ' + noteContent + '</span>';
|
||||
noteTextEl.innerHTML = `<p class="note_content_${ notesContent.length }"><span class="note_texte_number">` + noteNumber + '</span><span> ' + noteContent + '</span></p>';
|
||||
let notesContentEl = document.getElementById(`notes_content_${partie}`);
|
||||
notesContentEl.append(noteTextEl);
|
||||
} else {
|
||||
// si les notes qui se suivent ont le même contenu
|
||||
let notesContentEl = document.getElementById(`notes_content_${partie}`);
|
||||
let lastSpan = notesContentEl.querySelector('p:last-of-type span:last-of-type');
|
||||
let numberToAdd = document.createElement('span');
|
||||
numberToAdd.setAttribute('class', 'note_texte_number');
|
||||
numberToAdd.innerText = `, ${noteNumber}`;
|
||||
notesContentEl.querySelector('p:last-of-type').insertBefore(numberToAdd, lastSpan);
|
||||
let notesPageEl = document.querySelector(`#notes_content_${partie}`);
|
||||
let noteContentEl = notesPageEl.querySelector(`.note_content_${notesContent.indexOf(noteContent) + 1}`);
|
||||
console.log(noteContentEl);
|
||||
let spanToAdd = document.createElement('span');
|
||||
spanToAdd.classList.add('note_texte_number');
|
||||
spanToAdd.innerText = `, ${ noteNumber }`;
|
||||
let lastSpan = noteContentEl.lastElementChild.previousElementSibling;
|
||||
console.log(lastSpan, spanToAdd, noteContent);
|
||||
lastSpan.append(spanToAdd);
|
||||
}
|
||||
|
||||
prevNoteContent = noteContent;
|
||||
|
||||
prevPartie = currentPartie;
|
||||
|
||||
if (isImgNote(note)) {
|
||||
|
||||
@@ -2,39 +2,21 @@
|
||||
if (debug) console.log('start nonBreakingSpaces');
|
||||
|
||||
(function() {
|
||||
let contentsToClean = document.querySelectorAll('.labeur, .free, .latour, .latour_nohead, .lampe, .lampe_nohead, .bibliographie');
|
||||
let contentsToClean = document.querySelectorAll('.labeur, .free, .latour, .latour_nohead, .lampe, .lampe_nohead, .bibliographie, .citation');
|
||||
|
||||
for (let content of contentsToClean) {
|
||||
content.innerHTML = content.innerHTML.replaceAll(' :', ' :');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' ?', ' ?');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' !', ' !');
|
||||
content.innerHTML = content.innerHTML.replaceAll('« ', '« ');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' »', ' »');
|
||||
content.innerHTML = content.innerHTML.replaceAll('(« ', '(« ');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' »)', ' »)');
|
||||
content.innerHTML = content.innerHTML.replaceAll('“', '« ');
|
||||
content.innerHTML = content.innerHTML.replaceAll('”', ' »');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' min', ' min');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' ;', ' ;');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' :', ' :');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' ?', ' ?');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' !', ' !');
|
||||
content.innerHTML = content.innerHTML.replaceAll('« ', '« ');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' »', ' »');
|
||||
content.innerHTML = content.innerHTML.replaceAll('(« ', '(« ');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' »)', ' »)');
|
||||
content.innerHTML = content.innerHTML.replaceAll('“', '« ');
|
||||
content.innerHTML = content.innerHTML.replaceAll('”', ' »');
|
||||
content.innerHTML = content.innerHTML.replaceAll(' min', ' min');
|
||||
}
|
||||
})();
|
||||
|
||||
if (debug) console.log('end nonBreakingSpaces');
|
||||
|
||||
|
||||
/*
|
||||
// micro-typo
|
||||
for(let j = 0; j < contentToParse[i].childNodes.length; j++) {
|
||||
let contentHTML = contentToParse[i].childNodes[j].innerHTML;
|
||||
if (contentHTML != undefined) {
|
||||
contentToParse[i].childNodes[j].innerHTML = contentToParse[i].childNodes[j].innerHTML.replaceAll(' :', ' :');
|
||||
contentToParse[i].childNodes[j].innerHTML = contentToParse[i].childNodes[j].innerHTML.replaceAll(' ?', ' ?');
|
||||
contentToParse[i].childNodes[j].innerHTML = contentToParse[i].childNodes[j].innerHTML.replaceAll(' !', ' !');
|
||||
contentToParse[i].childNodes[j].innerHTML = contentToParse[i].childNodes[j].innerHTML.replaceAll('« ', '« ');
|
||||
contentToParse[i].childNodes[j].innerHTML = contentToParse[i].childNodes[j].innerHTML.replaceAll(' »', ' »');
|
||||
contentToParse[i].childNodes[j].innerHTML = contentToParse[i].childNodes[j].innerHTML.replaceAll('(« ', '(« ');
|
||||
contentToParse[i].childNodes[j].innerHTML = contentToParse[i].childNodes[j].innerHTML.replaceAll(' »)', ' »)');
|
||||
contentToParse[i].childNodes[j].innerHTML = contentToParse[i].childNodes[j].innerHTML.replaceAll('“', '« ');
|
||||
contentToParse[i].childNodes[j].innerHTML = contentToParse[i].childNodes[j].innerHTML.replaceAll('”', ' »');
|
||||
contentToParse[i].childNodes[j].innerHTML = contentToParse[i].childNodes[j].innerHTML.replaceAll(' min', ' min');
|
||||
}
|
||||
} */
|
||||
if (debug) console.log('end nonBreakingSpaces');
|
||||
@@ -34,7 +34,8 @@ if (debug) console.log('start tagToClass');
|
||||
'breakbefore',
|
||||
'breakafter',
|
||||
`doublepage_bigright`,
|
||||
`doublepage_bigleft`
|
||||
`doublepage_bigleft`,
|
||||
`screenshot`,
|
||||
];
|
||||
|
||||
let bodyContent = $('#body').html();
|
||||
|
||||
@@ -45,6 +45,8 @@ if (debug) console.log('start pagesToDisplay');
|
||||
uiContent.append(pagesToDisplayContainer);
|
||||
|
||||
function displayPagesRange(start, end) {
|
||||
start = parseInt(start);
|
||||
end = parseInt(end);
|
||||
let pages = document.querySelectorAll('.pagedjs_page');
|
||||
|
||||
if (/^\d+$/.test(start) && /^\d+$/.test(end) && start <= pages.length && end <= pages.length && start < end) {
|
||||
|
||||
@@ -8,9 +8,9 @@ if (debug) console.log('start toggleUiWhenPrinting');
|
||||
uiContainer.style.display = "none";
|
||||
});
|
||||
|
||||
window.addEventListener("afterprint", (event) => {
|
||||
uiContainer.style.display = "block";
|
||||
});
|
||||
window.addEventListener("afterprint", (event) => {
|
||||
uiContainer.style.display = "block";
|
||||
});
|
||||
|
||||
})();
|
||||
|
||||
|
||||
@@ -34,13 +34,13 @@
|
||||
{% endblock %}
|
||||
</head>
|
||||
<body id="top" class="{{ page.header.body_classes|e }}">
|
||||
{% block body %}
|
||||
<section id="body">
|
||||
<div>
|
||||
{% block content %}{% endblock %}
|
||||
</div>
|
||||
</section>
|
||||
{% endblock %}
|
||||
{% block body %}
|
||||
<section id="body">
|
||||
<div>
|
||||
{% block content %}{% endblock %}
|
||||
</div>
|
||||
</section>
|
||||
{% endblock %}
|
||||
|
||||
|
||||
{% block bottom %}
|
||||
|
||||
Reference in New Issue
Block a user