Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Use word-wrap instead of char-wrap for long-lines in diff views #22003

Open
wolftune opened this issue Dec 2, 2022 · 1 comment
Open

Use word-wrap instead of char-wrap for long-lines in diff views #22003

wolftune opened this issue Dec 2, 2022 · 1 comment

Comments

@wolftune
Copy link

wolftune commented Dec 2, 2022

Gitea would do better to wrap on words when viewing the changes in the PR view. Right now, it breaks up words in the middle, and that makes it harder to read. At the very least, this should be the default for files like Markdown that are more likely to be prose and not program code.

@silverwind
Copy link
Member

silverwind commented Dec 2, 2022

The intend of the wrap is to avoid long lines without whitespace to not break outside their container, but I think we can improve by using overflow-wrap: anywhere or overflow-wrap: break-word instead of word-wrap: break-all so that it only breaks inside words as last-resort before the container overflows. This is not just diff, but many other places as well.

Edit: Note to self: also check this in GitHub-code-wrap.

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

No branches or pull requests

2 participants