forked from ANSHIKA-26/WordWise
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
f620734
commit d9bf671
Showing
11 changed files
with
120 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,70 @@ | ||
/* Custom Scrollbar */ | ||
::-webkit-scrollbar { | ||
width: 15px; /* Width of the scrollbar */ | ||
} | ||
|
||
::-webkit-scrollbar-track { | ||
background: #f0f0f0; /* Background color of the track */ | ||
border-radius: 10px; /* Rounded corners for the track */ | ||
} | ||
|
||
::-webkit-scrollbar-thumb { | ||
background: linear-gradient(45deg, #cd61ff, #ec6371); /* Gradient color for the scrollbar */ | ||
border-radius: 10px; /* Rounded corners for the scrollbar */ | ||
box-shadow: inset 2px 2px 5px rgba(0, 0, 0, 0.3); /* Adds a shadow effect */ | ||
} | ||
|
||
::-webkit-scrollbar-thumb:hover { | ||
background: linear-gradient(45deg, #ff409c, #e763ec); /* Hover effect to change color */ | ||
cursor: pointer; /* Changes cursor to pointer when hovered */ | ||
} | ||
|
||
::-webkit-scrollbar-thumb:active { | ||
background: linear-gradient(45deg, #b222ff, #ff0062); /* Color when scrollbar is clicked */ | ||
} | ||
|
||
/* Optional: smooth scrolling */ | ||
html { | ||
scroll-behavior: smooth; | ||
} | ||
|
||
/* Hide scrollbar but keep functionality */ | ||
.main-body { | ||
scrollbar-width: none; /* For Firefox */ | ||
-ms-overflow-style: none; /* For IE and Edge */ | ||
} | ||
|
||
.main-body::-webkit-scrollbar { | ||
display: none; /* For Chrome, Safari, and Opera */ | ||
} | ||
|
||
/* Progress Bar Container */ | ||
.progress-container { | ||
width: 100%; | ||
height: 10px; /* Height of the progress bar */ | ||
background-color: #f0f0f0; /* Background color matching scrollbar track */ | ||
border-radius: 10px; /* Rounded corners */ | ||
box-shadow: inset 2px 2px 5px rgba(0, 0, 0, 0.2); /* Optional shadow for container */ | ||
position: fixed; | ||
overflow: hidden; | ||
} | ||
|
||
/* Progress Bar */ | ||
.progress-bar { | ||
width: 0%; /* Initial width (can be dynamically adjusted via JS) */ | ||
height: 100%; | ||
background: linear-gradient(45deg, #cd61ff, #ec6371); /* Gradient matching scrollbar */ | ||
border-radius: 10px; /* Rounded corners */ | ||
transition: width 0.3s ease-in-out; /* Smooth transition for width change */ | ||
box-shadow: inset 2px 2px 5px rgba(0, 0, 0, 0.3); /* Adds shadow effect */ | ||
} | ||
|
||
/* Hover effect for the progress bar */ | ||
.progress-bar:hover { | ||
background: linear-gradient(45deg, #ff409c, #e763ec); /* Hover gradient color */ | ||
} | ||
|
||
/* Active state (when clicked or progressing) */ | ||
.progress-bar:active { | ||
background: linear-gradient(45deg, #b222ff, #ff0062); /* Active gradient color */ | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -102,6 +102,7 @@ | |
margin: 0; | ||
padding: 0; | ||
box-sizing: border-box; | ||
z-index: -1; | ||
} | ||
|
||
.sliderr { | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
// Function to update the progress bar width as the user scrolls | ||
function updateProgressBar() { | ||
const scrollTop = document.documentElement.scrollTop || document.body.scrollTop; | ||
const scrollHeight = document.documentElement.scrollHeight - document.documentElement.clientHeight; | ||
const scrollPercentage = (scrollTop / scrollHeight) * 100; | ||
|
||
document.getElementById('progress-bar').style.width = scrollPercentage + '%'; | ||
} | ||
|
||
// Event listener for scrolling to update the progress bar | ||
window.addEventListener('scroll', updateProgressBar); | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,6 +12,7 @@ | |
<link href='https://unpkg.com/[email protected]/css/boxicons.min.css' rel='stylesheet'> | ||
<!--css--> | ||
<link rel="stylesheet" href="style.css"> | ||
<link rel="stylesheet" href="Scroll_and_progressbar.css"> | ||
|
||
<style> | ||
.secondary-title { | ||
|
@@ -23,6 +24,9 @@ | |
|
||
</head> | ||
<body> | ||
<div class="progress-container"> | ||
<div class="progress-bar" id="progress-bar"></div> | ||
</div> | ||
<!--header--> | ||
<header class="navbar"> | ||
<div class="logo"> | ||
|
@@ -362,6 +366,7 @@ <h2 class="footer-title secondary-title mt-2">Social</h2> | |
<script src="./darkMode.js"></script> | ||
<script src="./backend/login-Auth/login.js"></script> | ||
<script src="./backend/signup-Auth/signup.js"></script> | ||
<script src="progress_bar.js"></script> | ||
<!--swiper slider cdn--> | ||
|
||
</body> | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters