View Single Post
Old Yesterday, 05:39 PM   #9
enuddleyarbl
Guru
enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.enuddleyarbl ought to be getting tired of karma fortunes by now.
 
enuddleyarbl's Avatar
 
Posts: 911
Karma: 2111023
Join Date: Sep 2013
Device: Kobo Sage
Well, I just went and brute-forced my CSS. For the class I noted, above, it now looks like this:
Code:
div.chapquote {
	/* Chapter Quote (quote at top of chapters) Styling */
	display: block;
	font-style:	italic;
	margin-left:	1.5em;
	margin-right:	1.5em;
	padding-left: 1.5em;
	padding-right:	1.5em;
	text-align: justify;
}
div.chapquote em	{
	font-style:	normal;
}
div.chapquote i	{
	font-style:	normal;
}
I added those em and i classes to every class I had that used
Code:
font-style: italic
. Then, when the Calibre Editor's Check Book function complained about specificity for some very specific classes near the bottom of my CSS stylesheet, I just dragged those classes up near the top in their own "because Calibre told me so" section.

Not exactly elegant, but it works.

I've also opened an issue with EpubCheck:

https://github.com/w3c/epubcheck/issues/1765

They could very well come back and say Nesting Selectors don't work in Epubs, so that's why it errors on the & (though a more meaningful error message would be nice).
enuddleyarbl is offline   Reply With Quote