mirror of
https://github.com/mmarusiak/pdf-emojis-plugin.git
synced 2026-07-22 13:00:27 +00:00
The previous span-only approach failed because Obsidian's PDF export strips leading digits from heading text via pattern matching (not CSS), happening after post-processors run. Inserting U+2060 (Word Joiner, zero-width invisible char) before the digit breaks the regex match so the number is preserved. Also added @media print CSS rules and ::first-letter overrides as defense-in-depth.
30 lines
No EOL
767 B
CSS
30 lines
No EOL
767 B
CSS
.emoji {
|
|
font-weight: normal !important;
|
|
font-style: normal !important;
|
|
}
|
|
|
|
.pdf-heading-number {
|
|
display: inline !important;
|
|
visibility: visible !important;
|
|
opacity: 1 !important;
|
|
color: inherit !important;
|
|
font-size: inherit !important;
|
|
}
|
|
|
|
@media print {
|
|
.pdf-heading-number {
|
|
display: inline !important;
|
|
visibility: visible !important;
|
|
opacity: 1 !important;
|
|
color: inherit !important;
|
|
font-size: inherit !important;
|
|
}
|
|
|
|
h1::first-letter, h2::first-letter, h3::first-letter,
|
|
h4::first-letter, h5::first-letter, h6::first-letter {
|
|
font-size: inherit !important;
|
|
color: inherit !important;
|
|
visibility: visible !important;
|
|
opacity: 1 !important;
|
|
}
|
|
} |