Skip to content
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

b站笔记导出到本地离线html,在「稍后读 - 阅读模式」 显示异常 #2319

Closed
binsee opened this issue Jun 4, 2021 · 9 comments

Comments

@binsee
Copy link
Contributor

binsee commented Jun 4, 2021

b站笔记加入到稍后读,自动导出离线html。在「稍后读 - 阅读模式」 中打开时,显示异常

  1. 开头多了一行『视频连接:xxxx』,且a标签的href信息丢失
  2. 视频时间戳的a标签,href信息丢失
  3. 视频时间戳的a标签,时间戳文本丢失
  • 显示截图:(左离线html,右稍后读)
    image

  • 元素截图:(左离线html,右稍后读)
    image

测试文件如下:
先审后播会对日本动画带来什么影响?——日本动画走向世界的必经之路.zip

@Kenshin
Copy link
Owner

Kenshin commented Jun 5, 2021

嗨,我没有遇到你说的问题,下图

image


确认下 output 文件夹里面的文件,举个例子:

  1. 1234-test.html
  2. test.html

1234 是你的稍后读 id,简悦会优先读取 1234 的 HTML,然后没有找到的话,会读标题一致的 HTML。

@binsee
Copy link
Contributor Author

binsee commented Jun 5, 2021

晚上回去测试

@Kenshin
Copy link
Owner

Kenshin commented Jun 5, 2021

晚上回去测试

okay 🙏

@binsee
Copy link
Contributor Author

binsee commented Jun 5, 2021

仍然是此问题。
已经从稍后读中移除,并移除现有的output下文件,重新加入稍后读后,在稍后读中打开问题依旧。

image

@binsee
Copy link
Contributor Author

binsee commented Jun 5, 2021

有趣的是,我跟踪「稍后读-阅读模式」页面的流程,从同步助手读取到的正常,但进行二次处理渲染后,就出现问题

image
image

后续跟踪调试代码,确定如下问题:
image

调试视频如下:
https://user-images.githubusercontent.com/5285894/120900884-0bb24e80-c66a-11eb-965e-5765acd30bd3.mp4

@binsee
Copy link
Contributor Author

binsee commented Jun 5, 2021

嗨,我发现了问题所在。
『稍后读 - 阅读模式』中,即使读取的文件来自于同步助手从output目录下读取的离线文件,简悦也会按文章所属的站点适配规则,执行隐藏列表规则。
因为b站笔记的适配,隐藏列表中进行一些特殊处理,而在稍后读中无法获取到对应内容,导致页面呈现异常。

binsee added a commit to binsee/simpread that referenced this issue Jun 5, 2021
修复b站笔记离线阅读在稍后读中显示异常

Fixes  Kenshin#2319
@Kenshin
Copy link
Owner

Kenshin commented Jun 6, 2021

嗨,我发现了问题所在。
『稍后读 - 阅读模式』中,即使读取的文件来自于同步助手从output目录下读取的离线文件,简悦也会按文章所属的站点适配规则,执行隐藏列表规则。
因为b站笔记的适配,隐藏列表中进行一些特殊处理,而在稍后读中无法获取到对应内容,导致页面呈现异常。

竟然是这个问题导致... 也就是说我昨天测试的时候应该没有更新适配列表,所以无法重现?

另外,你在 #2327 应该已经 Fixed 了这个问题,是吧。

@binsee
Copy link
Contributor Author

binsee commented Jun 6, 2021

另外,你在 #2327 应该已经 Fixed 了这个问题,是吧。

是的,已经修复。

解决方法已另外记录至
#2328

@Kenshin
Copy link
Owner

Kenshin commented Jun 6, 2021

okay 已 Merge 到主适配源~

@Kenshin Kenshin closed this as completed Jun 6, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants