diff --git a/packages/Epub/converters/wax.js b/packages/Epub/converters/wax.js index 79fe2657381596f5d5d21930acbcf06950017f07..7d52bfa3ce43f8866ba03c3d5df829e620d45b96 100644 --- a/packages/Epub/converters/wax.js +++ b/packages/Epub/converters/wax.js @@ -1,8 +1,8 @@ module.exports = ($, fragmentTitle, bookTitle, fragmentDivision) => { const body = $('body') - const outerContainer = $('<div/>').attr('class', fragmentDivision) - const innerContainer = $('<section/>').attr('data-type', 'chapter') + let outerContainer = $('<div/>').attr('class', fragmentDivision) + let innerContainer = $('<section/>').attr('data-type', 'chapter') $('<p/>').attr('class', 'ch-start').html('beginning').appendTo(innerContainer) $('<div/>').attr('class', 'folio').appendTo(innerContainer) $('<div/>').attr('class', 'booktitle').html(bookTitle).appendTo(innerContainer) diff --git a/packages/Epub/process.test.js b/packages/Epub/process.test.js index ee8e0a64917ad76e7957205c0a1a31e0780dabe4..e3cef916a3d3e4c1a49486b38c7fc20b5d4dea3c 100644 --- a/packages/Epub/process.test.js +++ b/packages/Epub/process.test.js @@ -5,6 +5,7 @@ const processFragment = require('./process') test('converts source to html', () => { const fragment = { title: 'A Test', + division: 'body', source: ` <div> <h1>A Test</h1>