honestbleeps/Reddit-Enhancement-Suite
在 GitHub 查看User Tagger x filteReddit: custom conditions to display user tags
Open
#4,881 建立於 2018年10月14日
Difficulty-3_HardDifficulty-2_MediumPriority-2_A litte more Interesthelp wanted
描述
A potential overblown design for @aslakhol's https://github.com/honestbleeps/Reddit-Enhancement-Suite/issues/4722#issuecomment-429592085
Summary
Use the "post/comment filters" engine to determine if a user tag should be displayed. Add/alter UI entry points to set filters for user tags.
Use cases
- "highlight user" persisting on the same post across sessions
- highlight users only on certain subreddits / multireddits (e.g. frequent posters to r/talesfromtechsupport, track certain users in moderated subreddits)
- "expire" user tags (only show for a week, e.g. for an AMA, or only start showing in a few months)
Implementation details
- Apply filtering to usertags (medium-hard)
- Add "filter" data to "user tag" data model
- When rendering user tag UI, run filter logic to determine whether to show user tag or button
- Add "post ID" to filter cases (medium-easy)
- may as well add "comment id" while you're there
- Alter "highlight" button (from user info hover card) to create a "Highlighted" user tag
- Set user tag text to a flag emoji or something
- Set filter to "post id: this comments page" when browsing comments or "subreddit: this subreddit" when browsing subreddit
- Set filter to "before this date": today + 1 week
- Add option to User Tagger to apply user tag's color to author using User Highlighter