logiclord / epubReader

epubReader is a standalone fluid infusion component. This project is about implementing a web based ePub reader component based on open web technologies for infusion framework
http://webbasedepubreader.blogspot.in
53 stars 16 forks source link

Bookmark in epub.js #15

Closed sangari closed 11 years ago

sangari commented 12 years ago

hai ,

can you pls explain me to implement bookmark in https://github.com/logiclord/epubjs.

logiclord commented 11 years ago

Hi sangari,

Basic logic that I used in epubReader Bookmarks is Identifier and Position

https://github.com/logiclord/epubReader/blob/master/js/epubReaderNavigator.js#L443

I create a unique Identifier and wrap it around the bookmarked text using html tag. This way I am able to identify bookmarks. I also replicate a part of HTML from bookmarked text for preview.

--logiclord