seankwilliams / modern-footnotes

WordPress plugin to provide inline footnotes inspired by the styles of Grantland and FiveThirtyEight
14 stars 10 forks source link

Any way to add brackets to the footnote numbers? To improve their visibility #49

Closed johnr365 closed 2 years ago

johnr365 commented 2 years ago

I'm currently using an older wordpress plugin for footnotes called Easy Footnotes.

No updates to it in 2 years, and it doesn't allow display of footnotes inline on mobile.

I'd like to move to Modern Footnotes, but one thing is holding me back.

With easy footnotes there are square brackets around the numbers which make them a lot more visible on mobile (where the screen and text is smaller).

I don't think the brackets look "good" per se, but they do make it much harder to miss that there's a citation, and for me this is of value.

Is there currently a way to add these brackets to modern footnotes? Or does it need some code changes?

I've attached an image to illustrate how the two look side by side:

Captura de Pantalla 2022-08-16 a la(s) 7 09 02

seankwilliams commented 2 years ago

Hi @johnr365 ,

Yep, you can add these square brackets on mobile. Modern Footnotes has a setting field for custom CSS, so you can get square brackets around the footnote numbers on mobile by adding this value at Settings > Modern Footnotes > Modern Footnotes Custom CSS:

@media (max-width:768px) {
    .modern-footnotes-footnote::before {
        content: "[";
    }
    .modern-footnotes-footnote::after {
        content: "]";
    }
}