Epub format stores the TOC in metadata; any TOC that appears in the text pages, while somewhat common, is technically part of the book and not the 'official TOC' as such.
In contrast, other formats such as mobi and azw3 (kindle formats) store the TOC in a visible page, usually at the end of the book.
By default, EpubMerge combines the metadata TOCs together, nesting the original TOCs in a tree. That can be changed in in Epubmerge's config. There's also an option to flatten the TOC to a single level.
EpubMerge doesn't have any way to generate a consolidated in-text TOC like you describe. Calibre's own Conversion tool can, and you can do an epub->epub conversion. I haven't looked at how well that works and convert does sometimes change things more than you might like.
|