Skip to content

Commit

Permalink
Improves HTML diff table format for long line lengths. (#793)
Browse files Browse the repository at this point in the history
* Ignores nowrap attribute in diff HTML tables.
* Makes html report table 50/50 split
* Aligns diff text to the top of table cells.
  • Loading branch information
trevorshannon authored Feb 12, 2024
1 parent 0b9f2d2 commit 0bc4abd
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 0 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ The format mostly follows [Keep a Changelog](http://keepachangelog.com/en/1.0.0/
- Fix line height and dark mode regression (#774 reported by kongomongo, PRs #777 and #778 by trevorshannon)
- Fix compatibility with lxml >= 5 which caused the CSS Selector filter to fail (#783 reported by jamesquilty, PR #786 by jamstah)
- Fix pep8 test to ignore files in the site-packages directory for cases where the venv is in the project directory (#788 by jamstah)
- Fix HTML diff table rendering for long line lengths (#793 by trevorshannon)

## [2.28] -- 2023-05-03

Expand Down
1 change: 1 addition & 0 deletions lib/urlwatch/reporters.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,7 @@ def _parts(self):
td.diff_header, td.diff_next { color: #6e7781; background-color: #f5f5f5; text-align: right; vertical-align: top; }
table { font-family: monospace; line-height: 1.5em; }
td, th { padding: 0 0.5em; }
td[nowrap] { width: 50%; vertical-align: top; white-space: normal; word-break: break-word; }
h2 span.verb { color: #888; }
@media (prefers-color-scheme: dark) {
body { background-color: #121212; color: #fff; }
Expand Down

0 comments on commit 0bc4abd

Please sign in to comment.