<p></p>
<p>I have the same issue with not preserving the layer that I pick. This appears to be due to constructing a URL fragment (<a href="https://www.openstreetmap.org/#map=19/XX/YY" rel="nofollow">https://www.openstreetmap.org/#map=19/XX/YY</a>) for the current editor view that doesn't include the previous layers (<a href="https://www.openstreetmap.org/#map=19/XX/YY&layers=YN" rel="nofollow">https://www.openstreetmap.org/#map=19/XX/YY&layers=YN</a>). I've never worked on the code for this project, and I don't do much web development, but it seems like there are two ways to fix this:</p>
<ol>
<li>Add the layer info to the generated URL, but I'm not sure where this is stored, or how one would get it</li>
<li>Don't reset the layer when getting a URL fragment without layer parameter, perhaps only doing it when receiving an empty layer parameter (<a href="https://www.openstreetmap.org/#map=19/XX/YY&layers=" rel="nofollow">https://www.openstreetmap.org/#map=19/XX/YY&layers=</a>)</li>
</ol>
<p>I'm not sure which would be a better solution, though</p>
<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/openstreetmap/openstreetmap-website/issues/1212#issuecomment-865315341">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLMNWKDZDCARQQIDHGLTT6MU7ANCNFSM4CCDZEJQ">unsubscribe</a>.<img src="https://github.com/notifications/beacon/AAK2OLMAMQADSCMUUAEWVCDTT6MU7A5CNFSM4CCDZEJ2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOGOJ2UDI.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/openstreetmap/openstreetmap-website/issues/1212#issuecomment-865315341",
"url": "https://github.com/openstreetmap/openstreetmap-website/issues/1212#issuecomment-865315341",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>