carderne / signal-export

Export your Signal chats to markdown files with attachments
Other
436 stars 46 forks source link

Formatting of pagination buttons in HTML is off #87

Closed njgte closed 1 year ago

njgte commented 1 year ago

Setup: I am on Lubuntu 20.04 and have installed Signal as a snap in version 5.63.0. I installed signal-export using the docker method according to the Readme.

What I did I ran the export using

sigexport --source /home/myusername/snap/signal-desktop/current/.config/Signal /path-for-export

Bug The formatting of the pagination buttons in the html is somehow off, as you can see in the image. It looks like that for all chats. image

The generated html for an empty chat is the following, if that helps:

<!DOCTYPE html>
<html lang="en">
    <head>
        <meta charset="utf-8"/>
        <title>
            tii
        </title>
        <link href="../style.css" rel="stylesheet"/>
    </head>
    <body>
        <div class="first">
            <a href="#pg0">
                FIRST
            </a>
        </div>
        <div class="last">
            <a href="#pg0">
                LAST
            </a>
        </div>
        <div class="page" id="pg0">
            <nav>
                <div class="prev">
                    PREV
                </div>
                <div class="next">
                    NEXT
                </div>
            </nav>
            <div class="msg">
                <span class="date">
                    2021-09-21
                </span>
                <span class="time">
                    20:03
                </span>
                <span class="sender">
                    tii
                </span>
                <span class="body">
                </span>
                <span class="reaction">
                </span>
            </div>
            <script>
                if (!document.location.hash) document.location.hash = 'pg0'
            </script>
        </div>
    </body>
</html>
carderne commented 1 year ago

Hack fix in https://github.com/carderne/signal-export/commit/15aaa746e160f09067bedb1fbdfa054f24753508

Feel free to PR a proper solution if you want :)

pip install -U signal-export to get the fix