Is there any way to include a line-break between a string while using {content: }?
The following snippet is not working. I'm trying to use the \A
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<style>
@media print {
@page {
@bottom-center {
content: "Tous droits r茅serv茅s, 2014 \A https://doi.org/10.7202/1027428ar";
}
}
}
</style>
</head>
<body>
Content
</body>
</html>
AFAIK only possible with position: running() and content: element(), e.g.:
<style>
.footer {
position: running(footer);
text-align:center;
}
@page {
@bottom-center {
content: element(footer);
}
}
</style>
<div class="footer">
Tous droits r茅serv茅s, 2014 <br>
https://doi.org/10.7202/1027428ar
</div>
For the record, it also works with \A if you use a white-space value that keeps line breaks (for example white-space: pre-wrap).
Fun fact: that's how <br> tags are handled in WeasyPrint :wink:.