1
0
Fork 0
mirror of https://github.com/futurepress/epub.js.git synced 2025-10-03 14:59:18 +02:00
Commit graph

35 commits

Author SHA1 Message Date
John Factotum
1336e51c40 Allow span in toc nav items
According to https://www.w3.org/publishing/epub32/epub-packages.html#sec-package-nav-def-model:

"A child `a` element describes the target that the link points to, while a `span` element serves as a heading for breaking down lists into distinct groups (for example, a large list of illustrations can be segmented into several lists, one for each chapter)."
2021-12-16 15:11:55 +08:00
niels
ef588a5fd5 Get the OL element, null check on item 2020-08-21 14:28:27 +02:00
niels
7297af051b Return nested TOC with duplicate ids 2020-08-21 11:34:51 +02:00
m8524769
920846bda2 Fix wrong TOC item retruns by Navigation.get() (#831) 2019-12-16 18:56:05 +08:00
Niels Lanting
6333d008fe
Parse nxcItem with namespace
Some Ncx files have a namespace. A normal navpoint looks like this:

```
<navPoint id="id3" playOrder="3">
```

But a namespaced navPoint looks like this:

```
<ncx:navPoint id="id3" playOrder="3">
```

This change will remove the namespace  of the nodeName. This way we'll get a properly nested TOC.
2018-10-18 15:59:17 +02:00
Niels Lanting
6d328c02dc
Navigation href fallback for parent detection
The navItem function assumes that every item has an id attribute.
In practice this is not always the case, this will use the href attribute as fallback for the id attribute.
2018-10-03 16:37:03 +02:00
Fred Chasen
6bfcd1e4eb Added type declarations 2018-08-20 22:21:26 -07:00
Johan Poirier
8fb82b1d1c Set empty subitems array on toc items 2018-07-20 12:52:07 +02:00
Fred Chasen
3f16c7492e Add landmark method 2017-11-06 12:09:59 -08:00
Fred Chasen
7596f180d8 Add landmark parsing 2017-11-06 11:57:34 -08:00
Fred Chasen
5f53b7223c Update toc nav subitem parsing 2017-10-31 18:27:26 -07:00
Fred Chasen
9b6e864ae4 Add RTL support 2017-10-16 17:24:45 -07:00
Fred Chasen
bb1ab21a33 Updates for rendering in embedded Webviews (#643)
* Initial embedding support

* Updates for rendering in embedded webviews

* toLowerCase nodeName check
2017-08-01 17:25:19 -04:00
Fred Chasen
cde11e83d0 Fix variable issue with naviation parse 2017-03-27 11:32:07 -04:00
Fred Chasen
66242c5e99 Fix navigation isXml check 2017-03-27 11:20:50 -04:00
Fred Chasen
f26b0c9f00 Add parsing of json manifest 2017-03-22 11:17:13 -04:00
Fred Chasen
ac1bb6fa23 Switch tocLinkArray to use forEach instead of iterator 2017-01-24 13:21:44 -05:00
Sunil-BB
61f4ab7c57 Fix for https://github.com/futurepress/epub.js/issues/427 2017-01-13 17:58:51 +05:30
Fred Chasen
a435650c3b Fix eslint errors 2016-12-08 01:08:39 +01:00
Fred Chasen
353dfa62fd Intial move to ES2015 2016-12-06 15:04:16 +01:00
Fred Chasen
662a3e1079 Add resources.substitute back, fix toc promise 2016-11-18 21:40:33 +01:00
Fred Chasen
d14280b917 Added pageList, initial documentation 2016-11-10 23:08:39 +01:00
Fred Chasen
47787678f7 Added core Url and Path, split up book.open, added Container and Packaging 2016-11-08 02:06:10 +01:00
Fred Chasen
315650006e Switched from URIjs to URL and Node Path 2016-10-30 22:14:01 +01:00
Fred Chasen
151dc97d19 Switch to Native Promises, add polyfills.js in dist folder 2016-10-27 00:46:56 +02:00
Fred Chasen
32993dc58c Tabify src 2016-10-24 15:15:16 +02:00
Gerhard Sletten
e7df931fd2 Fixed wrong function name for parsing epub toc 2016-04-20 23:08:19 +02:00
fchasen
13467128e5 Switch to URI.js for url parsing, basic replacement for Archived urls 2015-12-06 22:14:02 -05:00
fchasen
fb61126382 Handle archived epubs 2015-12-04 17:21:26 -05:00
fchasen
91d1df14b1 setup browserify and requires 2015-12-03 23:41:49 -05:00
fchasen
82fb23daab Flattened src dir 2015-06-22 23:01:25 -04:00
fchasen
93a0cd772d initial pagination features 2014-01-31 11:58:19 -08:00
fchasen
73ac66ba65 updated cfi to handle text nodes and character offset 2014-01-29 11:04:48 -08:00
Fred Chasen
0398b5eedf split rendering up into renderer, render, layout 2014-01-21 20:39:30 -08:00
Fred Chasen
a5d970bca2 File Split 2014-01-21 20:37:36 -08:00