SD-1830 - use fragment.lines for click position in multi-column layouts#1963
Conversation
c7d5002 to
f018a4c
Compare
caio-pizzol
left a comment
There was a problem hiding this comment.
nice one @mattConnHarbour!
let's try to simplify a bit the code here
| lineIndex = fragment.fromLine + lineIndex; | ||
| } | ||
|
|
||
| // Guard against undefined line (defensive check) |
There was a problem hiding this comment.
findLineIndexAtY already returns null when lines[i] is undefined (line 2127-2128), and if it returns a non-null index, every line in the range was verified to exist during iteration.
this guard can never trigger -- removing it avoids making a reader wonder "wait, can this actually be undefined?"
f018a4c to
cca8b54
Compare
|
@caio-pizzol Thanks for the review! Just addressed your feedback - could you merge when you get a chance? |
End-to-end Playwright tests that verify clicking in two-column documents works correctly across Chromium, Firefox, and WebKit. Covers the customer-reported TypeError from IT-407.
caio-pizzol
left a comment
There was a problem hiding this comment.
@mattConnHarbour the feedback from last round is all addressed, and there are no new issues. also pushed a behavior test (Playwright, all 3 browsers) that loads a real two-column docx and clicks in the second column — end-to-end proof that IT-407 is fixed. lgtm, approving.
|
🎉 This PR is included in superdoc v1.17.0-next.35 The release is available on GitHub release |
|
🎉 This PR is included in superdoc-cli v0.2.0-next.30 The release is available on GitHub release |
|
🎉 This PR is included in superdoc v1.17.0 The release is available on GitHub release |
|
🎉 This PR is included in superdoc-cli v0.2.0 The release is available on GitHub release |
No description provided.