futurepress/epubjs-rn

font family

Closed this issue · 2 comments

hey guys
can someone answer my question ???
font-family inside body and epub font property is not changing font
it's 2 week i'm working on it and try out every way get in my head.
its not working really
can someone just say yes or no
just tell me if it's not working
i'm on react-native 0.57.8
and epub-rn version 0.0.127

i fixed font-family
and i will close this one
you need add font family in css body of theme in epub
themes={{
tan: {
body: {"font-family":"BNazanin","background-color":this.state.bc,},
}
then add all of your fonts to the epub file when you create epub file
i use sigil application to create a epub book
there you need to add fonts and add a stylesheet css file and also add file to the epub header codes
and a css @font-face to style file
you can call any font in react-native when you have added that font to epub file when you created it.
screen shot 2019-03-01 at 5 44 14 pm
screen shot 2019-03-01 at 5 44 21 pm
screen shot 2019-03-01 at 5 44 00 pm
and then in your react native epub tag add style for body theme
screen shot 2019-03-01 at 5 45 58 pm

hi veeyka , can you send me your sample code for change theme