mirror of
https://github.com/discourse/discourse.git
synced 2025-05-28 13:51:18 +08:00
FEATURE: Add last visit indication to topic view page. (#13471)
This PR also removes grey old unread bubble from the topic badges by dropping `TopicUser#highest_seen_post_number`.
This commit is contained in:

committed by
GitHub

parent
0f688f45bd
commit
37b8ce79c9
@ -192,7 +192,7 @@ after_initialize do
|
||||
return if topic_id.blank? || data[:track] != DiscourseNarrativeBot::NewUserNarrative.to_s
|
||||
|
||||
topic_user = topic_users.find_by(topic_id: topic_id)
|
||||
return if topic_user.present? && (topic_user.last_read_post_number.present? || topic_user.highest_seen_post_number.present?)
|
||||
return if topic_user.present? && topic_user.last_read_post_number.present?
|
||||
|
||||
topic = Topic.find_by(id: topic_id)
|
||||
return if topic.blank?
|
||||
|
@ -150,8 +150,7 @@ acceptance("Poll in a post reply history", function (needs) {
|
||||
archetype: "regular",
|
||||
unseen: false,
|
||||
last_read_post_number: 3,
|
||||
unread: 0,
|
||||
new_posts: 0,
|
||||
unread_posts: 0,
|
||||
pinned: false,
|
||||
unpinned: null,
|
||||
visible: true,
|
||||
@ -205,8 +204,7 @@ acceptance("Poll in a post reply history", function (needs) {
|
||||
archetype: "regular",
|
||||
unseen: false,
|
||||
last_read_post_number: 12,
|
||||
unread: 0,
|
||||
new_posts: 0,
|
||||
unread_posts: 0,
|
||||
pinned: false,
|
||||
unpinned: null,
|
||||
visible: true,
|
||||
|
@ -230,8 +230,7 @@ acceptance("Poll quote", function (needs) {
|
||||
archetype: "regular",
|
||||
unseen: false,
|
||||
last_read_post_number: 1,
|
||||
unread: 0,
|
||||
new_posts: 0,
|
||||
unread_posts: 0,
|
||||
pinned: false,
|
||||
unpinned: true,
|
||||
visible: true,
|
||||
@ -275,8 +274,7 @@ acceptance("Poll quote", function (needs) {
|
||||
archetype: "regular",
|
||||
unseen: false,
|
||||
last_read_post_number: 1,
|
||||
unread: 0,
|
||||
new_posts: 0,
|
||||
unread_posts: 0,
|
||||
pinned: false,
|
||||
unpinned: null,
|
||||
visible: true,
|
||||
|
@ -239,8 +239,7 @@ acceptance("Poll results", function (needs) {
|
||||
archetype: "regular",
|
||||
unseen: false,
|
||||
last_read_post_number: 9,
|
||||
unread: 0,
|
||||
new_posts: 0,
|
||||
unread_posts: 0,
|
||||
pinned: false,
|
||||
unpinned: true,
|
||||
visible: true,
|
||||
@ -295,8 +294,7 @@ acceptance("Poll results", function (needs) {
|
||||
archetype: "regular",
|
||||
unseen: false,
|
||||
last_read_post_number: 1,
|
||||
unread: 0,
|
||||
new_posts: 0,
|
||||
unread_posts: 0,
|
||||
pinned: false,
|
||||
unpinned: null,
|
||||
visible: true,
|
||||
@ -343,8 +341,7 @@ acceptance("Poll results", function (needs) {
|
||||
archetype: "regular",
|
||||
unseen: false,
|
||||
last_read_post_number: 1,
|
||||
unread: 0,
|
||||
new_posts: 0,
|
||||
unread_posts: 0,
|
||||
pinned: false,
|
||||
unpinned: null,
|
||||
visible: true,
|
||||
@ -389,8 +386,7 @@ acceptance("Poll results", function (needs) {
|
||||
archetype: "regular",
|
||||
unseen: false,
|
||||
last_read_post_number: 12,
|
||||
unread: 0,
|
||||
new_posts: 0,
|
||||
unread_posts: 0,
|
||||
pinned: false,
|
||||
unpinned: null,
|
||||
visible: true,
|
||||
|
Reference in New Issue
Block a user