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.
刚刚发现IP属地展示在处理新版评论区的楼中楼回复时会出错(应查找
.sub-reply-info>.sub-reply-time
而不是.reply-info>.reply-time
),已修复该问题另外我还发现
onRepliesUpdate
只能处理旧版评论区的展开和翻页,对于新版评论区无效(依赖此功能的复制评论链接也受此影响)可以将
/src/components/utils/comment-apis.ts
第113行开始的替换为
来对此进行修复
但这样带来了一个新问题,目前项目里使用了
onRepliesUpdate
这个功能的就只有我这个IP属地显示(ipShow
)以及原先的复制评论链接(copyCommentsLink
),也就是说原先使用此功能的只有复制评论链接这一个组件。现在我的IP属地显示同样需要使用这个功能,但onRepliesUpdate
只能同时绑定一个回调函数,经测试开启复制评论链接后,IP属地显示将会无法处理新版评论区的回复更新