mirror of
https://github.com/daniel-j/fimfic2epub.git
synced 2024-06-28 19:10:17 +12:00
Add chapter link after author note in index
This commit is contained in:
parent
ac56b2fa42
commit
750df5b434
|
@ -405,7 +405,8 @@ class FimFic2Epub extends EventEmitter {
|
||||||
if (this.options.includeAuthorNotes && this.options.useAuthorNotesIndex && chapter.notes) {
|
if (this.options.includeAuthorNotes && this.options.useAuthorNotesIndex && chapter.notes) {
|
||||||
chain = chain.then(template.createChapter.bind(null, this, {
|
chain = chain.then(template.createChapter.bind(null, this, {
|
||||||
title: 'Author\'s Note: ' + ch.title,
|
title: 'Author\'s Note: ' + ch.title,
|
||||||
content: chapter.notes
|
content: chapter.notes,
|
||||||
|
index: i
|
||||||
}, true)).then((html) => {
|
}, true)).then((html) => {
|
||||||
this.findRemoteResources('note_' + zeroFill(3, i + 1), {note: i}, html)
|
this.findRemoteResources('note_' + zeroFill(3, i + 1), {note: i}, html)
|
||||||
this.notesHtml[i] = html
|
this.notesHtml[i] = html
|
||||||
|
|
|
@ -100,9 +100,10 @@ export function createChapter (ffc, ch, isNotesChapter) {
|
||||||
m('hr.old')
|
m('hr.old')
|
||||||
]) : null,
|
]) : null,
|
||||||
tokenContent,
|
tokenContent,
|
||||||
(link || linkNotes) ? m('p.double', {style: 'text-align: center; clear: both;'},
|
(link || linkNotes || isNotesChapter) ? m('p.double', {style: 'text-align: center; clear: both;'},
|
||||||
link ? m('a.chaptercomments', {href: link + '#comment_list'}, 'Read chapter comments online') : null,
|
link ? m('a.chaptercomments', {href: link + '#comment_list'}, 'Read chapter comments online') : null,
|
||||||
linkNotes ? m('a.chaptercomments', {href: linkNotes}, 'Read author\'s note') : null
|
linkNotes ? m('a.chaptercomments', {href: linkNotes}, 'Read author\'s note') : null,
|
||||||
|
isNotesChapter ? m('a.chaptercomments', {href: './chapter_' + zeroFill(3, index + 1) + '.xhtml'}, 'Read chapter') : null
|
||||||
) : null,
|
) : null,
|
||||||
!isNotesChapter && ffc.options.addChapterBars ? chapterBars(ffc.storyInfo.chapters, index) : null
|
!isNotesChapter && ffc.options.addChapterBars ? chapterBars(ffc.storyInfo.chapters, index) : null
|
||||||
]))
|
]))
|
||||||
|
|
Loading…
Reference in a new issue