Ajout du QRcode en mode print

This commit is contained in:
2024-05-03 13:21:11 +02:00
parent 11f120ba39
commit 8819cf18ad
3 changed files with 87 additions and 4 deletions

8
assets/qr-code.js Normal file

File diff suppressed because one or more lines are too long

View File

@ -90,7 +90,7 @@ small {
margin-right: 1ex;
}
.guide > p:first-of-type:last-of-type::before {
.guide > p:first-of-type:last-child::before {
content: "➔";
}
@ -127,4 +127,69 @@ pre {
.index ul {
padding: 0;
list-style-type: none;
}
.ressource qr-code {
display: none;
}
@media print {
a {
color: inherit;
}
.ressource :not(h2) {
font-size: 10pt;
}
.ressource ul {
list-style-type: none;
display: flex;
flex-direction: row;
justify-content: start;
align-items: start;
flex-wrap: wrap;
width: 100%;
margin-bottom: 50px;
}
.ressource ul > * {
width: 200px;
}
.ressource li {
display: flex;
flex-direction: column;
justify-content: start;
align-items: center;
text-align: center;
margin-bottom: 25px;
page-break-inside: avoid;
}
.ressource li a {
display: contents;
}
.ressource qr-code {
display: block;
width: 100px;
}
.ressource qr-code::part(img) {
width: 100%;
}
.ressource a::after {
content: attr(href);
display: block;
text-decoration: none;
font-size: 0.9em;
margin-top: 1em;
order: 0;
word-wrap: break-word;
opacity: 0.5;
width: 100%;
}
}