03.04.2012 Views

Amazon Guidelines

Guidelines for self created

Guidelines for self created

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

Publishing on Kindle: <strong>Guidelines</strong> for Publishers<br />

Media Queries in CSS CSS Applied to KF8<br />

p {<br />

CSS Applied to<br />

Mobi<br />

p {<br />

color: red;<br />

color: red;<br />

}<br />

}<br />

}<br />

}<br />

8.2 Using Media Queries for Backward Compatibility With Mobi<br />

CSS Applied to<br />

Other Readers<br />

Media queries allow one CSS file to supply complex CSS for KF8 and basic CSS for the Mobi format.<br />

Some guidelines:<br />

• Complex CSS can be overridden for the Mobi format by redefining the same class inside the<br />

@media amzn-mobi media query.<br />

• Per the W3C standard, media queries should either be:<br />

o Individual queries specified after the common CSS (such as amzn-mobi); or<br />

o Include !important with each property. (Example: @media amzn-mobi {.class1<br />

{font-size: 3em !important; font-weight: bold !important;}})<br />

CSS<br />

p<br />

CSS Styles Applied to Mobi CSS Styles Applied to KF8<br />

{<br />

p<br />

p<br />

font-style: normal; {<br />

{<br />

}<br />

font-style: normal; font-style: normal;<br />

h<br />

}<br />

}<br />

{<br />

h<br />

h<br />

font-weight: bold; {<br />

{<br />

}<br />

font-weight: bold; font-weight: bold;<br />

div.example {<br />

}<br />

}<br />

margin: 10px<br />

div.example {<br />

div.example {<br />

}<br />

margin: 10px<br />

margin: 10px<br />

ul {<br />

}<br />

}<br />

margin: 20px<br />

ul {<br />

ul {<br />

padding-left: 30px; margin: 20px<br />

margin: 20px<br />

}<br />

padding-left: 30px; padding-left: 30px;<br />

}<br />

}<br />

.firstletter {<br />

float: left;<br />

font-size: 3em;<br />

line-height: 1;<br />

font-weight:<br />

.firstletter {<br />

float: 0;<br />

font-size: 3em;<br />

line-height: 0;<br />

.firstletter {<br />

float: left;<br />

font-size: 3em;<br />

line-height: 1;<br />

Kindle Publishing <strong>Guidelines</strong> <strong>Amazon</strong>.com 39

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!