Skip to content

Detect current child chapter #799

@yelyzaveta-kartseva

Description

@yelyzaveta-kartseva

Hey! Some of my epubs have chapters of different levels. Also app should show book contents with all chapters listed. So on book opening I fetch contents using
publication.tableOfContents()
draw tree of contents and for each Link (vReadiumShared.Link) using publication.locate(link) I generate object of Locator (for user to be able to tap and go there). The problem is I need to mark inside view of contents which chapter user is reading right now, but current locator does not show inside which child chapter user is. Like it shows (using href and title) that I'm under chapter1 (level 1), but even though I'm under chapter1.1 (level 2) href still leading me to it's parent -> chapter1 (level 1).
How using current locator updates know inside which child chapter user is?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions