1
0
mirror of https://github.com/s427/MARL.git synced 2025-01-31 11:34:46 +01:00

144 lines
8.1 KiB
Markdown
Raw Normal View History

2024-11-29 15:10:54 +01:00
# MARL - Mastodon Archive Reader Lite
## About
2024-12-01 01:27:23 +01:00
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.
2024-11-29 15:10:54 +01:00
Project page: https://github.com/s427/MARL
2024-12-01 01:27:23 +01:00
Should you want to spread the word, here are the announcement posts on Mastodon:
[English](https://lou.lt/@s427/113567190207673533) - [French](https://lou.lt/@s427/113567186376766727)
2024-11-29 15:10:54 +01:00
## Usage
__Access MARL online here:__ https://s427.github.io/MARL/
Alternatively, you can download this project from its [project page](https://github.com/s427/MARL), unpack it on your device, and simply launch (double click) `index.html`.
2024-12-01 00:37:22 +01:00
⚠️ __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.
2024-12-28 01:27:59 +01:00
## Screenshots
2024-11-29 15:10:54 +01:00
2024-12-12 20:31:50 +01:00
<img src="screenshot-multiple-archives.png" alt="app screenshot with multiple files loaded">
2024-11-29 15:10:54 +01:00
2024-12-28 01:27:59 +01:00
<img src="screenshot-dark-theme.png" alt="app screenshot with dark theme">
2024-11-29 15:10:54 +01:00
## Features
2024-12-01 01:27:23 +01:00
### What data is shown
2024-11-29 17:26:34 +01:00
2024-11-29 15:10:54 +01:00
- 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.
2024-12-01 01:27:23 +01:00
### Direct support for archive files
2024-11-29 17:26:34 +01:00
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.
2024-12-01 01:27:23 +01:00
### Strictly in-browser only
2024-11-29 17:26:34 +01:00
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.
2024-11-29 15:10:54 +01:00
2024-12-09 15:20:29 +01:00
### 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.
2024-12-01 01:27:23 +01:00
### Filters
2024-11-29 15:10:54 +01:00
2024-11-29 17:26:34 +01:00
Many filters allow you to quickly find a subset of posts in your archive:
2024-11-29 15:10:54 +01:00
- 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.
2024-12-01 01:27:23 +01:00
### Media viewer
2024-11-29 15:10:54 +01:00
2024-11-29 17:26:34 +01:00
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.
2024-12-01 01:27:23 +01:00
### Accessibility
2024-11-29 17:26:34 +01:00
2024-12-01 01:27:23 +01:00
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.
2024-11-29 15:10:54 +01:00
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!
2024-12-01 01:27:23 +01:00
### Responsive
2024-11-29 17:26:34 +01:00
MARL should work on pretty much any screen size, as low as 300 pixels wide (and possibly less).
2024-11-29 15:10:54 +01:00
2024-12-05 19:35:07 +01:00
### 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.
2024-11-29 15:10:54 +01:00
## Limitations
2024-11-29 17:26:34 +01:00
Everything is based on the data contained in the Mastodon archive file. As far as I can tell, the archive does __not__ include:
2024-11-29 15:10:54 +01:00
- 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
2024-11-29 17:26:34 +01:00
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.
2024-11-29 15:10:54 +01:00
### 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](https://github.com/mastodon/mastodon/issues/10400) on the official Mastodon project page.)
As a result, MARL can only show you very little data for your boosts, bookmarks and favorites.
2024-12-04 21:56:11 +01:00
## Tech
Third-party libraries and assets used:
- [AlpineJs](https://alpinejs.dev/) v3.14.5
- [JSZip](https://stuk.github.io/jszip/) v3.10.1
- [Material Icons](https://fonts.google.com/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.
2024-11-29 15:10:54 +01:00
## 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
2024-12-09 15:20:29 +01:00
## Version history
2025-01-06 18:14:41 +01:00
- v. 2.0
- code refactoring: MARL now uses Astro to build its HTML code as well as optimize and bundle its assets (CSS, SVG, images).
- all assets used to build MARL are now stored in the `dev` folder.
- the compiled, ready-to-use app can be found in the `dist` folder.
- except for the fact that it's now minified and packaged differently, everything works exactly the same as in version 1.3 for the end user (no new features).
2024-12-28 01:27:59 +01:00
- v. 1.3
- [NEW] dark theme
- will be set automatically based on your OS or browser preference (default to light if no preference is detected)
- support to manually choose the app theme will come in a later update
- misc minor tweaks or fixes
2024-12-09 15:20:29 +01:00
- 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.
- 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
2025-01-06 18:14:41 +01:00
- v. 1.0
- initial release