Skip to content

Commit

Permalink
Merge pull request #13 from sanjay7178/Sarath191181208/main
Browse files Browse the repository at this point in the history
Sarath191181208/main
  • Loading branch information
sanjay7178 authored May 8, 2024
2 parents 969aaf0 + 47a6f6a commit 5009968
Show file tree
Hide file tree
Showing 2 changed files with 65 additions and 23 deletions.
86 changes: 64 additions & 22 deletions html/popup.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
name="viewport"
content="width=device-width, initial-scale=1.0, shrink-to-fit=no"
/>
<style></style>
<title>ViBoot</title>
<link rel="stylesheet" href="styles.css" />
</head>
Expand All @@ -19,38 +20,79 @@
width="auto"
height="40px"
/> -->
still in development (Beta release)

still in development (Beta release)
</div>
<div class="body">
<button type="button" class="login-with-google-btn" id="login">
Sign in with Google
<button type="button" class="login-with-google-btn" id="view-offline">
Open offline page
</button>
<button type="button" class="login-with-google-btn" id="logout">
<!-- <button type="button" class="login-with-google-btn" id="logout">
Sign Out
</button>
<div class="content">* sign in to sync with calender</div>
<div class="content">* sign in to sync with calender</div> -->
</div>
</div>

<div>
<button type="button" id="view-offline">
Open offline page
</button>
</div>
<!-- <div class="navbar">
<div class="footer">
<div class="footer-content">made with &hearts; by</div>
<!-- <a href="https://vitrendz.com/" target="_blank" -->
<!-- ><img
src="../assets/img/ViTrendz.svg"
alt="logo"
height="50px"
width="auto"
/></a> -->
<p>GitHub Contributors</p>
<ul id="contributors-list"></ul>

<script s>
// script.js

// GitHub repository details
const owner = "sanjay7178";
const repo = "vRevamp";

// Function to fetch contributors
async function fetchContributors() {
try {
const response = await fetch(
`https://api.github.com/repos/${owner}/${repo}/contributors`
);
const contributors = await response.json();
displayContributors(contributors);
} catch (error) {
console.error("Error fetching contributors:", error);
}
}

// Function to display contributors on the webpage
function displayContributors(contributors) {
const contributorsList = document.getElementById("contributors-list");

contributors.forEach((contributor) => {
const listItem = document.createElement("li");

const profileLink = document.createElement("a");
profileLink.href = contributor.html_url;
profileLink.target = "_blank"; // Open link in new tab
profileLink.textContent = contributor.login;

const profileImage = document.createElement("img");
profileImage.src = contributor.avatar_url;
profileImage.alt = `${contributor.login}'s GitHub Profile Picture`;
profileImage.width = 20;
profileImage.height = 20;
profileImage.style.borderRadius = "50%";
profileImage.style.marginLeft = "10px";

profileLink.appendChild(profileImage);
listItem.appendChild(profileLink);

contributorsList.appendChild(listItem);
});
}

// Fetch contributors when the page loads
fetchContributors();
</script>

<div class="navbar">
<div class="footer">
<div class="footer-content">made with &hearts; by Github Community</div>
<a href="https://github.com/sanjay7178/vRevamp/issues" target="_blank" class="footer-content" />Report if any Issue faced</a>
</div>
</div>
</div>
<script src="popup.js"></script>
</body>
<script src="../js/popup.js"></script>
Expand Down
2 changes: 1 addition & 1 deletion service_worker/background.js
Original file line number Diff line number Diff line change
Expand Up @@ -227,4 +227,4 @@ chrome.runtime.onMessage.addListener((request) => {
viewOfflinePage();
}
});
=======

0 comments on commit 5009968

Please sign in to comment.