<p dir="auto">The previous method relied on intersection events for all changeset list items that go from below the viewport to above the viewport or in the opposite direction. But that required the items to enter the viewport in between. This is not guaranteed to happen if the sidebar contents is scrolled fast enough, for example by dragging the scrollbar or pressing Home/End keys. If an item goes from below straight to above without ever being inside the viewport, no intersection event is generated and the changeset is left in an invalid state with wrong color.</p>
<p dir="auto">This fix updates changesets below/above based on changesets inside the viewport.</p>

<hr>

<h4>You can view, comment on, or merge this pull request online at:</h4>
<p>  <a href='https://github.com/openstreetmap/openstreetmap-website/pull/5935'>https://github.com/openstreetmap/openstreetmap-website/pull/5935</a></p>

<h4>Commit Summary</h4>
<ul>
  <li><a href="https://github.com/openstreetmap/openstreetmap-website/pull/5935/commits/0a9cd466c7fe3b1b34566c051d6b6cb5e811e9c5" class="commit-link">0a9cd46</a>  Fix marking changesets outside of viewport on history pages</li>
</ul>

<h4 style="display: inline-block">File Changes </h4> <p style="display: inline-block">(<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5935/files">2 files</a>)</p>
<ul>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/5935/files#diff-dc12b10289b1608e5deb501050928dc5db8564cb2e09e01de68e949662123404">app/assets/javascripts/index/history-changesets-layer.js</a>
    (6)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/5935/files#diff-25cab16df4a58e0c8e53d0a0e70d9bbf28ef3beb9e6bf1208234fdeed7515392">app/assets/javascripts/index/history.js</a>
    (15)
  </li>
</ul>

<h4>Patch Links:</h4>
<ul>
  <li><a href='https://github.com/openstreetmap/openstreetmap-website/pull/5935.patch'>https://github.com/openstreetmap/openstreetmap-website/pull/5935.patch</a></li>
  <li><a href='https://github.com/openstreetmap/openstreetmap-website/pull/5935.diff'>https://github.com/openstreetmap/openstreetmap-website/pull/5935.diff</a></li>
</ul>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/pull/5935">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLI5KPKPJSUJFFEI2OD2ZY5STAVCNFSM6AAAAAB3IBBBE2VHI2DSMVQWIX3LMV43ASLTON2WKOZSHE4TSMZVGM2TINQ">unsubscribe</a>.<br />You are receiving this because you are subscribed to this thread.<img src="https://github.com/notifications/beacon/AAK2OLORKY2LPXCZYK4CRZT2ZY5STA5CNFSM6AAAAAB3IBBBE2WGG33NNVSW45C7OR4XAZNFJFZXG5LFVJRW63LNMVXHIX3JMTHLFRUAZI.gif" height="1" width="1" alt="" /><span style="color: transparent; font-size: 0; display: none; visibility: hidden; overflow: hidden; opacity: 0; width: 0; height: 0; max-width: 0; max-height: 0; mso-hide: all">Message ID: <span><openstreetmap/openstreetmap-website/pull/5935</span><span>@</span><span>github</span><span>.</span><span>com></span></span></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/pull/5935",
"url": "https://github.com/openstreetmap/openstreetmap-website/pull/5935",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>