Skip to content

Commit a6351cc

Browse files
renderer: add wrapLines option for line-by-line and side-by-side views
Introduce a new `wrapLines` configuration option that enables word-wrap display for diff output. When enabled, lines wrap at the container boundary instead of overflowing horizontally. Changes: - Add `wrapLines` boolean config to render-utils, line-by-line-renderer, side-by-side-renderer, and diff2html default config - Refactor mustache templates to separate row wrapping (generic-line) from cell content (generic-line-content), enabling flexible composition - Apply `d2h-wrapped-file-diff` CSS class conditionally to activate word-break and white-space styles scoped to wrapped mode only - Fix side-by-side view to render an aligned empty header row on the right panel so context lines are not visually offset - Add wrapLines checkbox to the demo page UI - Update test snapshots to reflect new template structure
1 parent 72331ff commit a6351cc

16 files changed

Lines changed: 1222 additions & 1064 deletions

package-lock.json

Lines changed: 23 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)