mirror of
https://github.com/lllin000/PaperForge.git
synced 2026-07-22 06:50:53 +00:00
fix: prevent frontmatter_side_zone on/near reference boundary page
Blocks on ref page and 1 page before no longer get frontmatter_side_zone. Fixes 'Conflict of Interest' heading on P21 (4AG67PBH) being assigned to frontmatter_side_zone via _is_explicit_frontmatter_support_furniture path that bypassed _is_heading_like_block check. Adds page gate: first_reference_page is not None and page >= first_reference_page - 1
This commit is contained in:
parent
172c3b2590
commit
bea122b36f
1 changed files with 4 additions and 0 deletions
|
|
@ -1460,6 +1460,10 @@ def infer_zones(
|
|||
and first_surviving_page is not None
|
||||
and int(block.get("page", 0) or 0) == first_surviving_page
|
||||
)
|
||||
and not (
|
||||
first_reference_page is not None
|
||||
and int(block.get("page", 0) or 0) >= first_reference_page - 1
|
||||
)
|
||||
]
|
||||
# Blocks on the first surviving page excluded from frontmatter_side_zone
|
||||
# because body has started are real body content -- collect their ids so
|
||||
|
|
|
|||
Loading…
Reference in a new issue