Skip to content

Commit 6f7b349

Browse files
authored
Merge pull request #143 from vedansh-5/settingEnhanc
Improved navigation, added home button
2 parents 15b6d3e + bb87132 commit 6f7b349

File tree

3 files changed

+41
-10
lines changed

3 files changed

+41
-10
lines changed

src/index.css

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -345,6 +345,24 @@ body,input,div,h3,h4,p,label,hr, #scrumReport{
345345
background: #9ca3af !important;
346346
}
347347

348+
.dark-mode .tooltip-container.tooltip-right .tooltip-bubble::after {
349+
border-color: transparent #374151 transparent transparent;
350+
}
351+
#homeButton {
352+
background: none;
353+
border: none;
354+
outline: none;
355+
cursor: pointer;
356+
display: flex;
357+
align-items: center;
358+
font-size: 1.5rem;
359+
}
360+
#homeButton:active {
361+
background: #e5e7eb;
362+
}
363+
.dark-mode #homeButton:active {
364+
background: #374151;
365+
=======
348366
.dark-mode .token-preview-char {
349367
box-shadow: 0 1px 4px rgba(0,0,0,0.18);
350368
}

src/popup.html

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@
2121
<div class="pl-1 py-4 rounded-2xl">
2222
<div class="bg-white px-4 py-4 mx-2 mb-2 rounded-3xl">
2323
<div class="flex justify-between py-2">
24-
<h3 class="text-3xl font-semibold ">Scrum Helper</h3>
24+
<h3 id="scrumHelperHeading" class="text-3xl font-semibold cursor-pointer">Scrum Helper</h3>
2525
<img src="icons/night-mode.png" alt="Night Mode" class="w-7 h-7 mx-3 cursor-pointer">
2626
</div>
2727
<div>
@@ -36,9 +36,14 @@ <h3 class="text-3xl font-semibold ">Scrum Helper</h3>
3636
<span class=""></span>
3737
Enable
3838
</label>
39-
<button id="settingsToggle">
40-
<img id="settingsIcon" src="icons/settings-light.png" alt="Settings" class="w-7 h-7 mx-3 cursor-pointer">
41-
</button>
39+
<div class="flex">
40+
<button id="homeButton" title="Go to Report" class="ml-1 p-2 rounded hover:bg-gray-200 dark:hover:bg-gray-700 transition">
41+
<i class="fa fa-home text-2xl text-gray-600 dark:text-gray-300"></i>
42+
</button>
43+
<button id="settingsToggle">
44+
<img id="settingsIcon" src="icons/settings-light.png" alt="Settings" class="w-6 h-6 mx-3 cursor-pointer">
45+
</button>
46+
</div>
4247
</div>
4348
</div>
4449

src/scripts/popup.js

Lines changed: 14 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -47,6 +47,13 @@ document.addEventListener('DOMContentLoaded', function() {
4747
const darkModeToggle = document.querySelector('img[alt="Night Mode"]');
4848
const settingsIcon = document.getElementById('settingsIcon');
4949
const body = document.body;
50+
const homeButton = document.getElementById('homeButton');
51+
const scrumHelperHeading = document.getElementById('scrumHelperHeading');
52+
const settingsToggle = document.getElementById('settingsToggle');
53+
const reportSection = document.getElementById('reportSection');
54+
const settingsSection = document.getElementById('settingsSection');
55+
56+
let isSettingsVisible = false;
5057
const githubTokenInput = document.getElementById('githubToken');
5158
const toggleTokenBtn = document.getElementById('toggleTokenVisibility');
5259
const tokenEyeIcon = document.getElementById('tokenEyeIcon');
@@ -298,12 +305,6 @@ document.addEventListener('DOMContentLoaded', function() {
298305
});
299306
}
300307

301-
const settingsToggle = document.getElementById('settingsToggle');
302-
const reportSection = document.getElementById('reportSection');
303-
const settingsSection = document.getElementById('settingsSection');
304-
305-
let isSettingsVisible = false;
306-
307308
function showReportView() {
308309
isSettingsVisible = false;
309310
reportSection.classList.remove('hidden');
@@ -330,6 +331,13 @@ document.addEventListener('DOMContentLoaded', function() {
330331
});
331332
}
332333

334+
if (homeButton) {
335+
homeButton.addEventListener('click', showReportView);
336+
}
337+
if (scrumHelperHeading) {
338+
scrumHelperHeading.addEventListener('click', showReportView);
339+
}
340+
333341
showReportView();
334342

335343
});

0 commit comments

Comments
 (0)