Skip to content

Improve long list item rendering without aggressive word splitting#160

Open
yukihane wants to merge 2 commits intoathul:masterfrom
yukihane:fix/issue-157-list-layout
Open

Improve long list item rendering without aggressive word splitting#160
yukihane wants to merge 2 commits intoathul:masterfrom
yukihane:fix/issue-157-list-layout

Conversation

@yukihane
Copy link

@yukihane yukihane commented Feb 15, 2026

Summary

This PR improves long list item rendering in the post body without forcing aggressive word splitting.

Changes

  1. Add a minimal reproduction page:

    • exampleSite/content/posts/issue-157-list-wrap.md
  2. Update list layout in assets/css/main.css:

    • Replace hanging indent via text-indent: -2ch with a more stable bullet layout using
      padding-inline-start + ::before absolute positioning
    • Scope the rule to .post-content .body ul so non-body list UIs are unaffected

Why this layout-based approach

This PR focuses on stabilizing bullet layout instead of introducing aggressive word-breaking rules.

Compared to adding word-break: break-all, this approach keeps wrapping behavior closer to browser defaults:

  • long tokens (including URLs) are less likely to be broken at arbitrary character boundaries
  • readability is preserved while still fixing the visual bullet/text split issue

In short: this fixes the layout root cause without forcing global hard word-splitting.

Scope

  • CSS-only rendering fix
  • No API/config changes
  • No required content migration

Fixes #157

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

1 participant