Skip to content

Commit 4776096

Browse files
committed
Revert "Merge branch 'master' into name-rog"
1 parent 52ac9fc commit 4776096

File tree

6 files changed

+118
-405
lines changed

6 files changed

+118
-405
lines changed

README.md

Lines changed: 2 additions & 35 deletions
Original file line numberDiff line numberDiff line change
@@ -116,41 +116,8 @@ Scrum Helper is not limited to the [FOSSASIA](https://github.com/fossasia) organ
116116
* Save your changes.
117117
* For Chrome: Rebuild or reload the extension in your browser (`chrome://extensions` → Refresh your extension).
118118
* For Firefox: Reload the temporary add-on by going to `about:debugging`"This Firefox" → Click "Reload" next to your extension.
119-
120-
4. **How to Obtain a GitHub Personal Access Token**
121-
122-
- To use Scrum Helper with authenticated requests (for higher rate limits and private repositories), you need a GitHub personal access token.
123-
124-
#### Steps to Generate a Token
125-
126-
1. **Go to GitHub Developer Settings:**
127-
Visit [https://github.com/settings/tokens](https://github.com/settings/tokens) while logged in to your GitHub account.
128-
129-
2. **Choose Token Type:**
130-
- Select **"Personal access tokens (classic)"**.
131-
132-
3. **Generate a New Token:**
133-
- Click **"Generate new token"**.
134-
- Give your token a descriptive name (e.g., "Scrum Helper Extension").
135-
- Set an expiration date if desired.
136-
137-
4. **Create and Copy the Token:**
138-
- Click **"Generate token"** at the bottom.
139-
- **Copy the token** and save it securely. You will not be able to see it again!
140-
141-
5. **Paste the Token in Scrum Helper:**
142-
- Open the Scrum Helper extension popup.
143-
- Paste your token into the "GitHub Token" field.
144-
145-
> **Keep your token secret!** Never share it or commit it to public repositories.
146-
147-
**Why use a token?**
148-
GitHub tokens allow the extension to make authenticated requests, increasing your API rate limit and enabling access to private repositories if you grant those permissions.
149-
150-
---
151-
5. **Get Customized SCRUM Reports**
152-
- The reports will now be generated using contributions from your organization.
153-
119+
4. **Get Customized SCRUM Reports**
120+
- The reports will now be generated using contributions from your organization.
154121

155122

156123
## About contributing

src/index.css

Lines changed: 56 additions & 85 deletions
Original file line numberDiff line numberDiff line change
@@ -287,103 +287,93 @@ hr,
287287
}
288288

289289
.tooltip-bubble {
290-
position: fixed !important;
291-
z-index: 9999;
292-
background: #f9fafb;
293-
color: #222;
294-
border-radius: 10px;
295-
border: 1px solid #e5e7eb;
296-
box-shadow: 0 4px 24px 0 rgba(0,0,0,0.12), 0 1.5px 4px 0 rgba(0,0,0,0.08);
297-
padding: 14px 18px;
298-
font-size: 13px;
299-
line-height: 1.5;
300-
min-width: 220px;
301-
max-width: 320px;
302-
white-space: normal;
290+
visibility: hidden;
303291
opacity: 0;
304-
pointer-events: none;
305-
transition: opacity 0.18s;
306-
}
307-
308-
.tooltip-container:hover .tooltip-bubble,
309-
.tooltip-container:focus-within .tooltip-bubble {
310-
opacity: 1;
311-
pointer-events: auto;
292+
position: absolute;
293+
background-color: #1f2937;
294+
color: white;
295+
text-align: left;
296+
padding: 12px;
297+
border-radius: 8px;
298+
font-size: 12px;
299+
line-height: 1.4;
300+
white-space: normal;
301+
box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
302+
z-index: 1000;
303+
transition: opacity 0.3s ease, visibility 0.3s ease;
304+
width: 280px;
312305
}
313306

314-
.tooltip-bubble a {
315-
color: #2563eb;
316-
text-decoration: underline;
307+
.tooltip-bubble {
308+
bottom: 125%;
309+
left: 150%;
310+
transform: translateX(-50%);
317311
}
318312

319313
.tooltip-bubble::after {
320314
content: "";
321315
position: absolute;
322-
width: 0; height: 0;
316+
top: 100%;
317+
left: 50%;
318+
margin-left: -5px;
319+
border-width: 5px;
323320
border-style: solid;
321+
border-color: #1f2937 transparent transparent transparent;
324322
}
325323

326-
327-
.dark-mode .tooltip-bubble {
328-
background: #f3f4f6;
329-
color: #222;
330-
border: 1px solid #374151;
324+
.tooltip-container.tooltip-bottom .tooltip-bubble {
325+
top: 125%;
326+
bottom: auto;
331327
}
332328

333-
.dark-mode .tooltip-bubble::after {
334-
border-color: #374151 transparent transparent transparent;
329+
.tooltip-container.tooltip-bottom .tooltip-bubble::after {
330+
top: -10px;
331+
border-color: transparent transparent #1f2937 transparent;
335332
}
336333

337-
.dark-mode .tooltip-container.tooltip-bottom .tooltip-bubble::after {
338-
border-color: transparent transparent #374151 transparent;
334+
.tooltip-container.tooltip-right .tooltip-bubble {
335+
top: -5px;
336+
left: 125%;
337+
bottom: auto;
338+
transform: none;
339339
}
340340

341-
.dark-mode .tooltip-container.tooltip-right .tooltip-bubble::after {
342-
border-color: transparent #374151 transparent transparent;
343-
}
344-
#toggleTokenVisibility {
345-
background: none;
346-
border: none;
347-
cursor: pointer;
348-
margin-left: 8px;
349-
padding: 0;
350-
line-height: 1;
341+
.tooltip-container.tooltip-right .tooltip-bubble::after {
342+
top: 15px;
343+
left: -10px;
344+
border-color: transparent #1f2937 transparent transparent;
351345
}
352-
#tokenEyeIcon {
353-
font-size: 18px;
354-
vertical-align: middle;
346+
347+
.tooltip-container:hover .tooltip-bubble {
348+
visibility: visible;
349+
opacity: 1;
355350
}
356-
@keyframes eye-rotate {
357-
0% { transform: rotate(0deg);}
358-
60% { transform: rotate(180deg);}
359-
100% { transform: rotate(180deg);}
351+
352+
.dark-mode .question-icon {
353+
color: #9ca3af;
360354
}
361-
.eye-animating {
362-
animation: eye-rotate 0.4s cubic-bezier(0.4,0,0.2,1);
355+
356+
.dark-mode .question-icon:hover {
357+
color: #60a5fa;
363358
}
364-
.token-animating {
365-
transition: box-shadow 0.3s, background 0.3s, color 0.3s, opacity 0.3s, transform 0.3s;
366-
box-shadow: 0 0 0 2px #3b82f6;
367-
opacity: 0.7;
368-
transform: translateX(8px) scale(1.03);
359+
360+
.dark-mode .tooltip-bubble {
361+
background-color: #374151;
362+
border: 1px solid #4b5563;
369363
}
370364

371-
.dark-mode #githubToken,
372-
.dark-mode .token-preview-char {
373-
background: #404040 !important;
374-
border-color: #505050 !important;
375-
color: #fff !important;
365+
.dark-mode .tooltip-bubble::after {
366+
border-color: #374151 transparent transparent transparent;
376367
}
377368

378-
.dark-mode .token-preview-dot {
379-
background: #9ca3af !important;
369+
.dark-mode .tooltip-container.tooltip-bottom .tooltip-bubble::after {
370+
border-color: transparent transparent #374151 transparent;
380371
}
381372

382373
.dark-mode .tooltip-container.tooltip-right .tooltip-bubble::after {
383374
border-color: transparent #374151 transparent transparent;
384375
}
385376

386-
387377
/* Custom Toast Styles for Materialize */
388378
.toast {
389379
color: #fff !important;
@@ -437,23 +427,4 @@ hr,
437427
.dark-mode .toast.toast-error {
438428
background: #b71c1c !important;
439429
color: #fff !important;
440-
441-
#homeButton {
442-
background: none;
443-
border: none;
444-
outline: none;
445-
cursor: pointer;
446-
display: flex;
447-
align-items: center;
448-
font-size: 1.5rem;
449-
}
450-
#homeButton:active {
451-
background: #e5e7eb;
452-
}
453-
.dark-mode #homeButton:active {
454-
background: #374151;
455-
456-
.dark-mode .token-preview-char {
457-
box-shadow: 0 1px 4px rgba(0,0,0,0.18);
458-
459430
}

src/popup.html

Lines changed: 20 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -23,32 +23,27 @@
2323
<body>
2424
<div class="pl-1 py-4 rounded-2xl">
2525
<div class="bg-white px-4 py-4 mx-2 mb-2 rounded-3xl">
26+
<div class="flex justify-between py-2">
27+
<h3 class="text-3xl font-semibold ">Scrum Helper</h3>
28+
<img src="icons/night-mode.png" alt="Night Mode" class="w-7 h-7 mx-3 cursor-pointer">
29+
</div>
30+
<div>
31+
<p class="">Report your development progress by auto-fetching your Git activity for a selected period</p>
32+
</div>
2633

27-
<div class="flex justify-between py-2">
28-
<h3 id="scrumHelperHeading" class="text-3xl font-semibold cursor-pointer">Scrum Helper</h3>
29-
<img src="icons/night-mode.png" alt="Night Mode" class="w-7 h-7 mx-3 cursor-pointer">
30-
</div>
31-
<div>
32-
<p class="">Report your development progress by auto-fetching your Git activity for a selected period</p>
33-
</div>
34-
3534
<div class="center mt-2 flex justify-between">
36-
<label class="flex items-center justify-center gap-2 ">
37-
Disable
38-
<input type="checkbox" value="" id="enable" class="sr-only peer" >
39-
<div class="relative w-11 h-6 bg-gray-200 rounded-full peer peer-focus:ring-blue-300 dark:peer-focus:ring-blue-800 dark:bg-gray-700 peer-checked:after:translate-x-full rtl:peer-checked:after:-translate-x-full peer-checked:after:border-white after:content-[''] after:absolute after:top-0.5 after:start-[2px] after:bg-white after:border-gray-300 after:border after:rounded-full after:h-5 after:w-5 after:transition-all dark:border-gray-600 peer-checked:bg-blue-600 dark:peer-checked:bg-blue-600"></div>
40-
<span class=""></span>
41-
Enable
42-
</label>
43-
<div class="flex">
44-
<button id="homeButton" title="Go to Report" class="ml-1 p-2 rounded hover:bg-gray-200 dark:hover:bg-gray-700 transition">
45-
<i class="fa fa-home text-2xl text-gray-600 dark:text-gray-300"></i>
46-
</button>
47-
<button id="settingsToggle">
48-
<img id="settingsIcon" src="icons/settings-light.png" alt="Settings" class="w-6 h-6 mx-3 cursor-pointer">
49-
</button>
35+
<label class="flex items-center justify-center gap-2 ">
36+
Disable
37+
<input type="checkbox" value="" id="enable" class="sr-only peer">
38+
<div
39+
class="relative w-11 h-6 bg-gray-200 rounded-full peer peer-focus:ring-blue-300 dark:peer-focus:ring-blue-800 dark:bg-gray-700 peer-checked:after:translate-x-full rtl:peer-checked:after:-translate-x-full peer-checked:after:border-white after:content-[''] after:absolute after:top-0.5 after:start-[2px] after:bg-white after:border-gray-300 after:border after:rounded-full after:h-5 after:w-5 after:transition-all dark:border-gray-600 peer-checked:bg-blue-600 dark:peer-checked:bg-blue-600">
5040
</div>
51-
41+
<span class=""></span>
42+
Enable
43+
</label>
44+
<button id="settingsToggle">
45+
<img id="settingsIcon" src="icons/settings-light.png" alt="Settings" class="w-7 h-7 mx-3 cursor-pointer">
46+
</button>
5247
</div>
5348
</div>
5449

@@ -139,31 +134,8 @@ <h6 class="text-base font-semibold">Scrum Report</h6>
139134
</div>
140135

141136
<div class="">
142-
143-
144-
<div class="flex items-center justify-between">
145-
<div class="flex">
146-
<h4>Your Github Token</h4>
147-
<span class="tooltip-container">
148-
<i class="fa fa-question-circle question-icon"></i>
149-
<span class="tooltip-bubble">
150-
<b>Why is it recommended to add a GitHub token?</b><br>
151-
Scrum Helper works without a GitHub token, but adding a personal access token is recommended for a better experience. It raises your API limits, allows access to private repos (if permitted), and improves accuracy and speed. Tokens are stored locally and never sent to us and used only to fetch your git data. You can add one anytime in the extension settings.<br><br>
152-
<b>How to obtain:</b><br>
153-
1. Go to <a href="https://github.com/settings/tokens" target="_blank" style="color:#2563eb;text-decoration:underline;">GitHub Developer Settings</a>.<br>
154-
3. Click "Generate new token", select classic token<br>
155-
4. Paste it here.<br>
156-
<i>Keep your token secret!</i>
157-
</span>
158-
</span>
159-
</div>
160-
<button id="toggleTokenVisibility" type="button" class="focus:outline-none">
161-
<i id="tokenEyeIcon" class="fa fa-eye text-gray-600"></i>
162-
</button>
163-
</div>
164-
<input id="githubToken" type="password" class="w-full border-2 border-gray-200 bg-gray-200 rounded-xl text-gray-800 p-2 my-2 pr-10" placeholder="Required for making authenticated requests">
165-
<p class="text-sm font-medium">Enter cache TTL <span class="text-sm font-normal">(in minutes)</span>
166-
137+
<p class="text-sm font-medium">Enter cache TTL <span class="text-sm text-gray-800 font-normal">(in
138+
minutes)</span>
167139
<span class="tooltip-container">
168140
<i class="fa fa-question-circle question-icon"></i>
169141
<span class="tooltip-bubble">

src/scripts/main.js

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
let enableToggleElement = document.getElementById('enable');
22
let githubUsernameElement = document.getElementById('githubUsername');
3-
let githubTokenElement = document.getElementById('githubToken');
43
let cacheInputElement = document.getElementById('cacheInput');
54
let projectNameElement = document.getElementById('projectName');
65
let lastWeekContributionElement = document.getElementById('lastWeekContribution');
@@ -24,15 +23,11 @@ function handleBodyOnLoad() {
2423
'lastWeekContribution',
2524
'yesterdayContribution',
2625
'cacheInput',
27-
'githubToken',
2826
],
2927
(items) => {
3028
if (items.githubUsername) {
3129
githubUsernameElement.value = items.githubUsername;
3230
}
33-
if (items.githubToken) {
34-
githubTokenElement.value = items.githubToken;
35-
}
3631
if (items.projectName) {
3732
projectNameElement.value = items.projectName;
3833
}
@@ -211,10 +206,6 @@ function handleGithubUsernameChange() {
211206
let value = githubUsernameElement.value;
212207
chrome.storage.local.set({ githubUsername: value });
213208
}
214-
function handleGithubTokenChange() {
215-
let value = githubTokenElement.value;
216-
chrome.storage.local.set({ githubToken: value });
217-
}
218209
function handleProjectNameChange() {
219210
let value = projectNameElement.value;
220211
chrome.storage.local.set({ projectName: value });
@@ -244,7 +235,6 @@ function handleUserReasonChange() {
244235
}
245236
enableToggleElement.addEventListener('change', handleEnableChange);
246237
githubUsernameElement.addEventListener('keyup', handleGithubUsernameChange);
247-
githubTokenElement.addEventListener('keyup', handleGithubTokenChange);
248238
cacheInputElement.addEventListener('keyup', handleCacheInputChange);
249239
projectNameElement.addEventListener('keyup', handleProjectNameChange);
250240
startingDateElement.addEventListener('change', handleStartingDateChange);

0 commit comments

Comments
 (0)