wickedest / Mergely

Merge and diff documents online
http://www.mergely.com
Other
1.17k stars 228 forks source link

When I compare two files again,"scrolltodiff" is still located at the previous diff,not the first diff #151

Closed baobaodz closed 3 years ago

baobaodz commented 3 years ago

Recently, I have encountered a problem during the project. I would like to ask you for help.

When I compare two different files, use "scrolltodiff" to next diff ,sunch as scroll to the third diff. When I compare two other different files again, I expect that diff has returned to the top or recalculated. But it is still located at the previous third place diff. Did I miss something? Or how to return to the first diff?

I’d be grateful if you could help me.

wickedest commented 3 years ago

@baobaodz, it sounds like you're re-using the mergely context, and the current diff position is not being reset. What are you using to "compare two other different files", are you calling lhs / rhs again?

wickedest commented 3 years ago

That should fix it.

baobaodz commented 3 years ago

That should fix it.

It works.Thanks!!!