-
Notifications
You must be signed in to change notification settings - Fork 723
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix attribute class redefined error on some epub files #457
base: master
Are you sure you want to change the base?
Conversation
Some epubs, have an html content with "class" attribute. FolioReader will fail since it's also defining its class attribute. Fixed this by adding a logic to check if the class attribute already exist, if it does then just append the class attribute of FolioReader to the already existing class attribute of the Epub file. Otherwise, just add the class attribute directly to the htmlcontent.
how are you finding this library so far, i am looking for a open source epub reader for ios and android and couldnt find anything so far except this, also is there a flutter version if you know? |
yes. i'm actually using flutter to display epub files. I'm using epub_kitty package which is also using this library (folioreader). |
can someone review these PRs and feedback the contributor ? |
Some epubs, have an html content with "class" attribute. FolioReader
will fail since it's also defining its class attribute.
Fixed this by adding a logic to check if the class attribute already exist,
if it does then just append the class attribute of FolioReader to the already
existing class attribute of the Epub file. Otherwise, just add the class attribute
directly to the htmlcontent.
Example epub html content:
With my fix the class attribute will become like class="lora nightmode hltr" (sample only)
Will fix #456