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

Text disappears at page break when footnote or page float is given on before pseudo element #740

Closed
MurakamiShinyu opened this issue Jul 7, 2021 · 2 comments · Fixed by #746
Assignees
Labels
bug P1 Priority 1: Required for MVP (Minimum Viable Product)

Comments

@MurakamiShinyu
Copy link
Member

MurakamiShinyu commented Jul 7, 2021

リスト内で改ページが起きるとき、リスト項目の1行目がリストマーカーの点だけ残して消えてしまうことがあります。

「Vivliostyleで本を作ろうVol.5」の記事「CSS 組版の基本仕様 CSS Paged Media 入門のススメ」で気がつきました。

スクリーンショット:
Screen Shot 2021-07-13 at 14 23 37

問題のリスト項目のHTMLコードは

https://github.com/spring-raining/tbf11-draft/blob/2fec4d89a17c7891fa0e6d0e66186f81c690772a/content/shinyu/index.html#L38-L42

リスト項目内の最初のa要素の ::before 擬似要素には float: footnote が指定されている:

https://github.com/spring-raining/tbf11-draft/blob/2fec4d89a17c7891fa0e6d0e66186f81c690772a/theme/theme_screen.css#L718-L726

@MurakamiShinyu MurakamiShinyu self-assigned this Jul 12, 2021
@MurakamiShinyu MurakamiShinyu added the P1 Priority 1: Required for MVP (Minimum Viable Product) label Jul 12, 2021
@MurakamiShinyu
Copy link
Member Author

問題が起きるのは、リスト項目内の最初のインライン要素の ::before 擬似要素に float: footnote による脚注の指定がある場合。
また、 リスト項目に限らず、通常のブロック内の最初のインライン要素の ::before 擬似要素に float: footnote による脚注の指定がある場合や、ブロック要素の::before 擬似要素に float: footnote による脚注の指定がある場合にも同じ問題が起きることを確認した。float: footnote だけでなく、float-reference: page; float: bottom などページフロートでも同様。いずれも、 ::before 擬似要素を指定した要素の内容のテキストが消えてしまうことがある。

いくつかのテスト

(test files: https://github.com/MurakamiShinyu/bugtest/tree/main/test003 )

@MurakamiShinyu MurakamiShinyu changed the title List item's first line disappears when page break occurs within the list Text disappears at page break when footnote or page float is given on before pseudo element Jul 13, 2021
MurakamiShinyu added a commit that referenced this issue Jul 13, 2021
@MurakamiShinyu
Copy link
Member Author

#746 にてテキストが消える現象は起きないようにしたが、その結果、正しく改ページ処理がされない問題が生じているので別のissueへ→#747

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug P1 Priority 1: Required for MVP (Minimum Viable Product)
Projects
None yet
1 participant