Anyway, I don’t intend to re-open the discussion about pdf-oneboxing but am rather looking for viable workarounds for displaying uploaded pdfs somewhat more prominently. Apparently, there was a previous discussion on this, but it has been deleted.
A concrete example of a use case are posts created basen on a forwarded email. Here, if the email had a pdf document attached, it is easy to miss that as it appears as a simple link at the very bottom of the post, i.e. after the forwarded email’s signature, if any.
As far as I know oneboxing will only work on externally linked PDFs, not uploaded ones.
With CSS you could do something like
a.attachment[href$=".pdf"] {
color: red;
&:before {
// The attachment icon is added using a pseudo-selector
// so you'd need to edit its styles here
}
}
This applies styles to links with the class attachment only if the href ends in .pdf