Page MenuHomePhabricator

Multiple Spaces cause edit conflicts in TCC, which do not make sense to the user
Open, Needs TriagePublic

Description

We keep getting reports about users being confused by whitespace-only changes. For example:

  • Sometimes the conflicting "paragraph" contains nothing but empty lines, e.g. when one user added a newline, but the other user removed one. There is an empty textarea then. The user can't see the newlines. The same also happens when the conflict is somewhere else, and there are newline-only changes somewhere else on the page. (This might be a duplicate with T250402.)
  • The colored diff is extremely dim/subtle when the only change is a single space character. What's weird about this complain is: Isn't this the same in all diffs? Maybe the font size is different. Maybe we use the wrong font (it just recently changed, see T250393). Maybe some users have custom styles for diffs, but these don't get active in the conflict UI.

Ideas:

  • Much stronger styling for single-character and/or whitespace-only changes. (See https://de.wikipedia.org/wiki/Benutzer:TMg/cleanDiff for a demo how this could look like.)
  • Present whitespace-only textareas as a message that can't be edited.
  • Always auto-resolve newline-only changes. Note we partly do this already with the newlines at the end of each paragraph (i.e. if it's 0, 1, or more newlines).
  • Auto-resolve space-only changes. When there is nothing done in a paragraph but adding/removing whitespace, just use the users (right) version.

Reported here: https://de.wikipedia.org/wiki/Wikipedia_Diskussion:Technische_W%C3%BCnsche/Topw%C3%BCnsche/Bearbeitungskonflikte#Kleine_%C3%84nderungen_unsichtbar_oder_Anzeige_von_nicht_ge%C3%A4nderten_Abschnitten

This is closely related to T250402: User-friendly presentation of whitespace-only changes (empty boxes).