-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: Observe notification read and fix #6406 #6407
feat: Observe notification read and fix #6406 #6407
Conversation
tamaina
commented
May 24, 2020
•
edited
edited
- https://github.com/syuilo/misskey/pull/6406#issuecomment-633203670 の修正
- notificationのpack(=APIの通知の返答)でisReadを含めるように
- 通知一覧で、通知が画面に表示されると既読にすなるように(IntersectionObserver使用)
- String Unionをsrc/types.tsにまとめる
通知ウィジェットを表示していたり通知ページにいた場合、既読をつける処理をしないとだ |
notificationのPack時にisReadがなくて、各通知の既読状態を知る手立てがないんだよね。含めるようにしちゃっていいかしら? |
post-form.vueが #6408 と競合した |
通知表示検出もc2.a9z.devで動作中 |
isRead: falseな通知がAPIから返ってくるケースってあるかな? |
ストリームからきた通知はfalseなのでそこらへんで |
isReadが最初からfalseなときはIntersectionObserverのインスタンスは無駄ですね |
これ、メンションなどのnoteの場合は既読にならないですね |
Co-authored-by: syuilo <Syuilotan@yahoo.co.jp>
Co-authored-by: syuilo <Syuilotan@yahoo.co.jp>
@@ -0,0 +1,3 @@ | |||
export const notificationTypes = ['follow', 'mention', 'reply', 'renote', 'quote', 'reaction', 'pollVote', 'receiveFollowRequest', 'followRequestAccepted', 'groupInvited', 'app'] as const; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
notificationTypes は src/models/entities/notification にあっても良さそうに思った
@@ -0,0 +1,3 @@ | |||
export const notificationTypes = ['follow', 'mention', 'reply', 'renote', 'quote', 'reaction', 'pollVote', 'receiveFollowRequest', 'followRequestAccepted', 'groupInvited', 'app'] as const; | |||
|
|||
export const noteVisibilities = ['public', 'home', 'followers', 'specified'] as const; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
noteVisibilities は src/models/entities/note にあっても良さそう
クライアントで使用する場合にmodels/entitiesにあるtsから持ってきても大丈夫なのでしょうか? 怖いけど適当な場所がなかったのでtypes.tsを作ったのですが |
うーむ |
🙏 |