<p dir="auto"><code class="notranslate">/export/embed</code> page has the "Report a problem" link which is supposed to be localized depending on the browser's accept-language header. But that doesn't happen because javascript waits for <code class="notranslate">window.onload</code> before setting the language. By that time <code class="notranslate">L.Control.OSMReportAProblem</code> is already created with a default locale.</p>
<p dir="auto"><a href="https://github.com/openstreetmap/openstreetmap-website/assets/4158490/d67e1985-81a1-4e7d-aeba-f0929c0d9262">image.png (view on web)</a></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/4934'>https://github.com/openstreetmap/openstreetmap-website/pull/4934</a></p>

<h4>Commit Summary</h4>
<ul>
  <li><a href="https://github.com/openstreetmap/openstreetmap-website/pull/4934/commits/adabf84fe6e43af7905dfa2f6148390438d11ed8" class="commit-link">adabf84</a>  Set i18n locale before writing "report a problem" on embed page</li>
</ul>

<h4 style="display: inline-block">File Changes </h4> <p style="display: inline-block">(<a href="https://github.com/openstreetmap/openstreetmap-website/pull/4934/files">2 files</a>)</p>
<ul>
  <li>
    <strong>M</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/4934/files#diff-8c15a01c0063fe88fd9f5197128e788856295e4755fbb4a3cbf7aa6be9f81ca7">app/assets/javascripts/embed.js.erb</a>
    (12)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/openstreetmap/openstreetmap-website/pull/4934/files#diff-1d63afd70e90a474818a25b07647371a35c71bf161b87019414500948b7fb173">test/system/embed_test.rb</a>
    (19)
  </li>
</ul>

<h4>Patch Links:</h4>
<ul>
  <li><a href='https://github.com/openstreetmap/openstreetmap-website/pull/4934.patch'>https://github.com/openstreetmap/openstreetmap-website/pull/4934.patch</a></li>
  <li><a href='https://github.com/openstreetmap/openstreetmap-website/pull/4934.diff'>https://github.com/openstreetmap/openstreetmap-website/pull/4934.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/4934">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLMOLDR3I2JFQVQFUA3ZJ5REDAVCNFSM6AAAAABKDVK532VHI2DSMVQWIX3LMV43ASLTON2WKOZSGM4DEMBUGY4TIOA">unsubscribe</a>.<br />You are receiving this because you are subscribed to this thread.<img src="https://github.com/notifications/beacon/AAK2OLLISQTJK37QKDSCIU3ZJ5REDA5CNFSM6AAAAABKDVK532WGG33NNVSW45C7OR4XAZNFJFZXG5LFVJRW63LNMVXHIX3JMTHI36ZG4Q.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/4934</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/4934",
"url": "https://github.com/openstreetmap/openstreetmap-website/pull/4934",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>