NotificationBlock: UI to show blocked posts #1582
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Simplified version of #1071, this time without saving the user's blog UUIDs into storage (per precedent set in #450).
This implements a UI for NotificationBlock's preference pane similar to PostBlock's, including additions in #719. That is, it displays a list of posts that one has blocked notifications for, including the ability to click to navigate to the posts in question (so that, for example, one can migrate to the native "notification muting" feature instead).
This requires opening a post purely based on its post id, something which the Tumblr API isn't able to do. Therefore, this assumes the post is probably on one of the currently logged in user's blogs, and simply checks each blog the user has access to in descending order of post count for the post in question.
If the user uses container tabs, they'll have to right click the link and open it in the correct, logged-in container tab for this to work. The only way I could think of to do this was to make the link real and include a query parameter in it, which is a bit clunky since it persists once you close the blog view modal. This is therefore of last resort.
Testing steps
todo: document tests