css | ||
img | ||
js | ||
svg | ||
.gitignore | ||
Dockerfile | ||
index.html | ||
LICENSE | ||
readme.md | ||
screenshot-multiple-archives.png | ||
screenshot.png |
MARL - Mastodon Archive Reader Lite
About
MARL is a lightweight, single-page app that provides a user-friendly interface to explore the content of a Mastodon archive file: account data, posts, attachments, etc.
Project page: https://github.com/s427/MARL
Should you want to spread the word, here are the announcement posts on Mastodon:
English - French
Usage
Access MARL online here: https://s427.github.io/MARL/
Alternatively, you can download this project from its project page, unpack it on your device, and simply launch (double click) index.html
.
⚠️ Only ZIP files are supported —not GZ files. This is a limitation of the JSZip library which is used by MARL to unpack the archive file. Older versions of Mastodon (prior to version 4.2.0) used to export the archive in TAR.GZ. If this is your case, you will have to first convert your archive to a ZIP file.
Screenshot
Features
What data is shown
- basic profile info, including pictures (avatar, banner)
- full profile JSON data
- favorites (*)
- bookmarks (*)
- posts, including attachments (images, sounds, videos)
- boosts (*)
- full JSON data for each post or boost
- an overview of all the hashtags or mentions in your posts (will update dynamically depending on the active filters)
- an overview of all the users whose posts you have boosted
(*) see "Limitations" below.
Direct support for archive files
No need to unpack your archive. Just drag'n'drop your file in the MARL window, and MARL will unpack it for you. This takes place in your browser's memory: no files are written on your disks. It's also strictly read-only: your archive file is not altered in any way.
Strictly in-browser only
Everything takes place in the browser, with no communication with any server (once the page has been loaded). Your archive data is not sent to any server. No analytics are included either.
Support for multiple archives
You can open multiple archive files at once (or add some more after via drag'n'drop) and MARL will show you all their posts in a single chronological list, as well as all the profiles in a tabbed interface. Each profile is automatically color-coded. A new group of filters allow you to filter posts by author.
Filters
Many filters allow you to quickly find a subset of posts in your archive:
- search full text, or exclusively in hashtags, mentions, content warnings or external links
- filter posts depending on their language or visibility (public, unlisted etc)
- filter posts depending on whether they contain images, videos or sounds
- and more.
Media viewer
Posts attachments (images, videos or sounds) can be viewed or played in MARL. However there may be some limitations depending on the size of the attachment, as well as your browser and/or device.
Accessibility
MARL should be fully accessible to keyboard users. It also has been optimized for Forced Colors (aka "High Contrast" or "Contrast Theme") mode. Last but not least, it should be accessible to screen readers.
Accessibility is a vast and complex topic, and there's probably room for improvement. Feel free to let me know if you have feedback or suggestion!
Responsive
MARL should work on pretty much any screen size, as low as 300 pixels wide (and possibly less).
Persistent settings
Paging-related settings (namely: number of posts per page, and sorting order) are stored in the browser and automatically restored when the app is initialized, so that you don't have to re-set them the way you like it every time.
Limitations
Everything is based on the data contained in the Mastodon archive file. As far as I can tell, the archive does not include:
- a list of the accounts you follow or are followed by
- a list of your blocked or muted accounts
- your lists
- your pinned posts
Some data may not be shown in MARL, by choice or oversight. This is why the full JSON data for the account is also displayed, as well as the full JSON data for each of your post (below each post).
Heavy attachments
MARL will try to load images, sounds or videos that are attached to your posts. However, this all takes place in your browser/OS memory. Very large images or videos may fail to load. You can still find them by unpacking your archive: for each attachment, MARL tells you the exact path where you can find it in your archive.
Boosts, favorites and bookmarks
As far as I can tell, any content that is not directly hosted on your instance (in other words, any content that originated from another instance, but that you may have boosted, liked or bookmarked) is stored for a limited time in your instance cache. How long that time is depends on your instance configuration. Once a post expires (is removed) from this cache, it is also removed from your account (as a boost, favorite or bookmark) and therefore will not be included in your archive.
This affects boosts, favorites and bookmarks —except for posts that are hosted on your instance directly (i.e. your own posts, or posts from other members of your instance). This explains why the actual number of posts shown by MARL may be significantly lower than the "official" number of posts displayed on your Mastodon profile. Conversations with users hosted on other instances may also be broken for the same reason.
Moreover, even when those external posts have not expired, the data that is included in the archive is very sparse: basically a single URL to the post on its original instance. It is not possible to programmatically fetch more data from those URLs, as Mastodon servers currently do not allow cross-origin resource sharing (CORS). (See this issue on the official Mastodon project page.)
As a result, MARL can only show you very little data for your boosts, bookmarks and favorites.
Tech
Third-party libraries and assets used:
- AlpineJs v3.14.5
- JSZip v3.10.1
- Material Icons
All are stored within the project; no request to a CDN or third-party server is made by MARL.
Everything else coded by me.
Disclaimer
This is a personal, non-official project. I am not associated with the Mastodon project in any way. A lot of the way MARL works is based on guesswork on my part when trying to understand the archive structure. Feel free to let me know if you think I've missed or misunderstood something!
You can reach me via github or on Mastodon:
Github: https://github.com/s427
Mastodon: https://lou.lt/@s427
Version history
- v. 1.2
- [NEW] support for multiple archive files. Notes:
- you can select multiple files from the open dialog;
- if one or several files are already loaded, you can drag and drop more files anywhere on the app window in order for MARL to load those new files and add them to the ones already loaded;
- for now the "Load new file" button still assumes you want to start over (blank slate); this will probably be changed in a future version.
- [NEW] support for multiple archive files. Notes:
- v. 1.1
- [NEW] paging preferences (page size and posts order) are automatically saved to the browser and restored on app load if present
- various bug fixes and improvements
- v. 1.0 - Initial release