Skip to content

Commit 6fcebce

Browse files
committed
feature: version update for release
1 parent 8aad900 commit 6fcebce

File tree

3 files changed

+9
-7
lines changed

3 files changed

+9
-7
lines changed

git_analytics/static/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ <h1 class="h3 mb-4">Other statistics</h1>
183183
</main>
184184
<footer class="bg-dark text-white py-3 mt-auto">
185185
<div class="container">
186-
<span>&copy; 2025 ver 0.1.9</span>
186+
<span>&copy; 2025 ver 0.1.10</span>
187187
</div>
188188
</footer>
189189
<script src="js/bootstrap.bundle.min.js"></script>

git_analytics/static/js/git-analytics.js

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ async function fetchStatistics(type, value) {
4747
return data;
4848
}
4949

50-
async function loadAndRender(type, value) {
50+
async function loadAndRender(type, value, label) {
5151
try {
5252
// fetch stats
5353
const modalEl = document.getElementById("loadingModal");
@@ -57,7 +57,7 @@ async function loadAndRender(type, value) {
5757
modal.hide();
5858

5959
// render stats
60-
renderSummary(stats);
60+
renderSummary(stats, label);
6161
buildAuthorsChart(stats.authors_statistics.authors);
6262
buildAuthorsStackedChart(stats.authors_statistics.authors);
6363
buildHourByAuthorChart(stats.historical_statistics.hour_of_day);
@@ -72,7 +72,7 @@ async function loadAndRender(type, value) {
7272
}
7373
}
7474

75-
function renderSummary(stats) {
75+
function renderSummary(stats, rangeLabel) {
7676
const s = stats.commits_summary;
7777
if (!s) return;
7878

@@ -81,6 +81,7 @@ function renderSummary(stats) {
8181

8282
summaryEl.innerHTML = `
8383
<div>
84+
<strong>Statistics for:</strong> ${rangeLabel.toLowerCase()}<br>
8485
<strong>Total number of authors:</strong> ${s.total_number_authors}<br>
8586
<strong>Total number of commits:</strong> ${s.total_number_commit}<br>
8687
<strong>Date of the first commit:</strong> ${s.date_first_commit}<br>
@@ -470,15 +471,16 @@ document.addEventListener("DOMContentLoaded", () => {
470471
const menu = document.getElementById("rangeMenu");
471472
const btn = document.getElementById("rangeDropdownBtn");
472473

473-
loadAndRender("months", 1);
474+
loadAndRender("months", 1, "Last month");
474475

475476
menu.addEventListener("click", (e) => {
476477
const item = e.target.closest(".dropdown-item");
477478
if (!item) return;
478479
e.preventDefault();
479480
const type = item.dataset.type;
480481
const value = item.dataset.value;
482+
const label = item.textContent.trim();
481483
btn.textContent = item.textContent.trim();
482-
loadAndRender(type, value);
484+
loadAndRender(type, value, label);
483485
});
484486
});

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[tool.poetry]
22
name = "git-analytics"
3-
version = "0.1.9"
3+
version = "0.1.10"
44
description = "Advanced analytics for Git repositories — commits, authors, code churn, lines of code, trends, and visual dashboards."
55
authors = ["n0rfas <n0rfas@protonmail.com>"]
66
license = "MIT"

0 commit comments

Comments
 (0)