Skip to content

refactor!: Enhance pagination with handling specific markdown elements#27

Merged
DeepanshKhurana merged 9 commits intomainfrom
development
Mar 6, 2026
Merged

refactor!: Enhance pagination with handling specific markdown elements#27
DeepanshKhurana merged 9 commits intomainfrom
development

Conversation

@DeepanshKhurana
Copy link
Member

Related Issue:
Fixes #26

Warning

This introduces a Breaking Change in the configuration.

Added

  • Configurable pagination parameters via reader.pagination in config.yaml with columnWidth, columnHeight, lineHeight, avgCharWidth, and safetyMargin options.

Changed

  • Breaking: Rewrote pagination algorithm from line-based to character-based for more accurate page breaks.
  • CSS columns now allow content to break inside blocks (break-inside: auto) for natural text flow.
  • Theme scale overrides (ui.theme.overrides.font.scale) now affect pagination calculations.

Fixed

  • Theme config path now correctly reads ui.theme.preset instead of top-level theme.
  • Reader mode no longer overflows or cuts off content at column boundaries.
  • Blockquotes and lists split mid-content when needed instead of jumping entirely to next column.
  • Body of Work page now appears on first deploy when using a custom slug.

@DeepanshKhurana DeepanshKhurana self-assigned this Mar 6, 2026
@vercel
Copy link

vercel bot commented Mar 6, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
ode-docs Ready Ready Preview, Comment Mar 6, 2026 4:23pm

@DeepanshKhurana DeepanshKhurana merged commit e240da1 into main Mar 6, 2026
3 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] Pagination algorithm causes content overflow in reader mode

1 participant