If you start selecting from outside the diff table, the side-locking code doesn't run, as it require you to click (or start selecting from) inside the diff table (test link). This task is to investigate how difficult it would be to fix that. It should be easy to some extent (e.g. if one column is shorter than the other, and you start selecting from the empty space after the short column), but it might be harder in general (up to the point where the selection starts very far away from the table, and it's also unclear what side should be locked).
Description
Details
Status | Subtype | Assigned | Task | ||
---|---|---|---|---|---|
Resolved | โข NRodriguez | T287177 [EPIC] Copy and Paste from Diffs | |||
Resolved | Daimona | T288676 Side lock isn't enabled when starting selection from outside the diff table |
Event Timeline
This should be easy if we limit that to the main diff table. What we need to do is add the "diff-left" and "diff-right" classes to the following elements:
- Headers (diff-otitle and diff-ntitle)
- Line numbers (diff-lineno)
- Empty lines
EDIT: Actually, not line numbers, as those aren't selectable anyway.
Change 712366 had a related patch set uploaded (by Daimona Eaytoy; author: Daimona Eaytoy):
[mediawiki/core@master] Apply side lock to diff headers and empty lines, too
Change 712367 had a related patch set uploaded (by Daimona Eaytoy; author: Daimona Eaytoy):
[mediawiki/php/wikidiff2@master] Apply side lock to diff headers and empty lines, too
Change 712367 merged by jenkins-bot:
[mediawiki/php/wikidiff2@master] Add CSS classes for side lock to empty lines, too
Change 712366 merged by jenkins-bot:
[mediawiki/core@master] Apply side lock to diff headers and empty lines, too
Hey @nayoub, hope your day is going well. I have a question on the copy and paste diff2 features. Do you know what tools the users typically paste their copied text to. Below screen shot is copy and paste to an excel-sheet. The first one is simple copy and paste from diff, the second one I clicked the cell and pasted the text. Would that be an acceptable behavior as far as the layout on excel-sheet?
Below is screenshot example that user can copy and paste one section at a time.
Hi @imaigwilo, I'm doing well, thank you - hope you are too!
I actually haven't worked on the Copy and Paste from Diffs project so I'm not sure what users' behavior might be in this case. I think @Daimona or @NRodriguez will be more helpful to answer your question :)
My understanding is that the scope of the wish is limited to allowing users to select just one column, and doesn't cover the use cases of pasting text.