<h3 dir="auto">Description</h3>
<p dir="auto">This PR introduces a heatmap visualization on user profile pages to display daily contribution activity over the past year.</p>
<p dir="auto"><strong>Key changes include:</strong></p>
<ul dir="auto">
<li>Added a heatmap container in the user profile view (<code class="notranslate">users/show.html.erb</code>).</li>
<li>Implemented JavaScript logic (<code class="notranslate">heatmap.js</code>) using CalHeatmap to render the heatmap dynamically based on contribution data.</li>
<li>Updated localization (<code class="notranslate">config/locales/en.yml</code>) to include tooltips and month/weekday labels for the heatmap.</li>
<li>Added tests in <code class="notranslate">users_controller_test.rb</code> to validate heatmap data handling.</li>
</ul>
<p dir="auto">Screenshots:<br>
<a href="https://github.com/user-attachments/assets/878068ee-c0cd-450d-b3e8-010a9c75575f">Screenshot.2024-12-16.at.16.35.58.png (view on web)</a><br>
<a href="https://github.com/user-attachments/assets/2ae8ff02-0416-41fe-aeeb-d91cc6584a67">Screenshot.2024-12-16.at.16.37.14.png (view on web)</a><br>
<a href="https://github.com/user-attachments/assets/ca4d4b80-cdbf-4b20-a5e6-602ef3ec07ce">Screenshot.2024-12-16.at.16.36.25.png (view on web)</a></p>
<h3 dir="auto">How has this been tested?</h3>
<ul dir="auto">
<li>Verified heatmap rendering with mock data for different users and activity levels.</li>
<li>Tested responsiveness and theme support (light/dark mode).</li>
<li>Checked correct localization of tooltips, month names, and weekday labels.</li>
<li>Ran automated tests to ensure proper heatmap data handling in the controller.</li>
</ul>
<p dir="auto">Let me know if you need further tweaks or enhancements!</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/5402'>https://github.com/openstreetmap/openstreetmap-website/pull/5402</a></p>
<h4>Commit Summary</h4>
<ul>
<li><a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/commits/ada1658217cc2609da0214cc0b98be482ee7a021" class="commit-link">ada1658</a> Add cal-heatmap lib with plugins and dependencies to vendor/assets/javascripts</li>
<li><a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/commits/467ef949fcba2e85935d4d159b7d3c49b321f689" class="commit-link">467ef94</a> Add manifest and application JS updates for asset linking and heatmap functionality</li>
<li><a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/commits/a438823754ff1ac7d4694d97dcbddd0cf668e8e6" class="commit-link">a438823</a> Add heatmap data caching and query for user contributions</li>
<li><a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/commits/e6bd49788270f43456796f6a9b3aeed603eb085f" class="commit-link">e6bd497</a> Add heatmap container to user profile view</li>
<li><a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/commits/9fe6cfde50fecbee2434ad91c5070a9a75d4a080" class="commit-link">9fe6cfd</a> Add heatmap javascript logic, styles and localization</li>
<li><a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/commits/79ed0bfece55d1cbef5e4d185bb5193a0ef1d974" class="commit-link">79ed0bf</a> Add tests for heatmap data in UsersController</li>
</ul>
<h4 style="display: inline-block">File Changes </h4> <p style="display: inline-block">(<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files">14 files</a>)</p>
<ul>
<li>
<strong>M</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-12fd523cb95d119382c3743591e40c90ae62ed20b24a7012b37aed54031009b8">app/assets/config/manifest.js</a>
(5)
</li>
<li>
<strong>M</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-0e145ba000e96b1a45d230275e350e4e8514efb4db7dbcfa228fe1003896c9b4">app/assets/javascripts/application.js</a>
(5)
</li>
<li>
<strong>A</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-ff3763133f63089f0a2593943a3de42c08dbbd7afc11b78d1cded6d0ece51c9a">app/assets/javascripts/heatmap.js</a>
(116)
</li>
<li>
<strong>A</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-2420639b443b35f36e59e32ab7bbb33ae0a34b92b7dec40453e7451493cf4ff0">app/assets/stylesheets/heatmap.css</a>
(3)
</li>
<li>
<strong>M</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-cfdccd0a9d5df5a43aaad2a35d36ebbe187c52ad5fdc9846fa189d04537adb6e">app/controllers/users_controller.rb</a>
(17)
</li>
<li>
<strong>M</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-78ff736409d758722403cce31873ba803b3fb526d37398ca21caa557b54dfd95">app/views/users/show.html.erb</a>
(10)
</li>
<li>
<strong>M</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-44438ce218f5287c58d0017f965d888715635d94280669896f75841fbd7b4cd7">config/locales/en.yml</a>
(4)
</li>
<li>
<strong>M</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-2719d3c650da3c587f727ca3c105e6bc93a7113f85717bb15983543cf4f85ae5">test/controllers/users_controller_test.rb</a>
(93)
</li>
<li>
<strong>A</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-6cfb4ddfa7b5d1cab473725c4ca117885a44e5358eda96fd7ca0e34c48147670">vendor/assets/cal-heatmap/cal-heatmap.css</a>
(1)
</li>
<li>
<strong>A</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-640de6090d0af887dfdf99e7cf6ab04843f58fad22a1ad9248658fa1ab29e000">vendor/assets/cal-heatmap/cal-heatmap.js</a>
(1)
</li>
<li>
<strong>A</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-25b77974c58a4dcea7e65ed7f664f2d3cbab469ecd8808644501e9785fc3f11f">vendor/assets/cal-heatmap/calendar-label.js</a>
(1)
</li>
<li>
<strong>A</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-07ff186f60d6b80b79e151c82095a4e2e5537eae07d28e1404c1be783a92a55e">vendor/assets/cal-heatmap/popper.js</a>
(6)
</li>
<li>
<strong>A</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-6fbf1eba74bea2d87124a2f3c2d86d3bdc98e30c09683907a00f7f1e5281c141">vendor/assets/cal-heatmap/tooltip.js</a>
(1)
</li>
<li>
<strong>A</strong>
<a href="https://github.com/openstreetmap/openstreetmap-website/pull/5402/files#diff-da23bd120b633c607c332abf0d0074a8bb27788c0fb1798aac0d3516d0461712">vendor/assets/d3/d3.js</a>
(2)
</li>
</ul>
<h4>Patch Links:</h4>
<ul>
<li><a href='https://github.com/openstreetmap/openstreetmap-website/pull/5402.patch'>https://github.com/openstreetmap/openstreetmap-website/pull/5402.patch</a></li>
<li><a href='https://github.com/openstreetmap/openstreetmap-website/pull/5402.diff'>https://github.com/openstreetmap/openstreetmap-website/pull/5402.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/5402">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAK2OLLEB2HSI3WG7QCLPOT2F3YBVAVCNFSM6AAAAABTWNRZO6VHI2DSMVQWIX3LMV43ASLTON2WKOZSG42DENZSHE2DSMQ">unsubscribe</a>.<br />You are receiving this because you are subscribed to this thread.<img src="https://github.com/notifications/beacon/AAK2OLJAWOUYZ33MCLDTZ332F3YBVA5CNFSM6AAAAABTWNRZO6WGG33NNVSW45C7OR4XAZNFJFZXG5LFVJRW63LNMVXHIX3JMTHKG6V3CQ.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/5402</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/5402",
"url": "https://github.com/openstreetmap/openstreetmap-website/pull/5402",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>