Skip to content

Commit

Permalink
Merge pull request #414 from priyanshi-codes/enhancement
Browse files Browse the repository at this point in the history
Navbar fixed
  • Loading branch information
Jaishree2310 authored Nov 4, 2024
2 parents 737bf4a + 9fd7d64 commit 7f94324
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 3 deletions.
2 changes: 1 addition & 1 deletion package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"react-feather": "^2.0.10",
"react-icons": "^5.3.0",
"react-router-dom": "^6.27.0",
"react-scripts": "5.0.1",
"react-scripts": "^5.0.1",
"styled-components": "^6.1.13",
"typescript": "^4.9.5",
"web-vitals": "^2.1.4",
Expand Down
11 changes: 10 additions & 1 deletion src/components/Header.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,13 @@ const Header: React.FC<{ darkMode: boolean; toggleDarkMode: () => void }> = ({
display: 'flex',
justifyContent: 'space-between',
alignItems: 'center',
position: 'fixed', // Fix the navbar
top: 0, // Align it to the top of the page
width: '100%', // Ensure it spans the width of the page
zIndex: 1000, // Ensure it stays above other elements
backdropFilter: 'blur(10px)', // Apply the blur effect
WebkitBackdropFilter: 'blur(10px)', // For Safari compatibility
boxShadow: '0 4px 6px rgba(0, 0, 0, 0.1)', // Optional shadow for better contrast
};

const linkStyle: React.CSSProperties = {
Expand All @@ -43,7 +50,9 @@ const Header: React.FC<{ darkMode: boolean; toggleDarkMode: () => void }> = ({
alt='Glass UI Logo'
className='h-8 w-8' // Adjust size as needed
/>
<h1 className=className={`${darkMode ? 'text-white' : 'text-black'} text-[20px] font-bold`}>
<h1
className={`${darkMode ? 'text-white' : 'text-black'} text-[20px] font-bold`}
>
<span className='text-blue-400'>Glass</span>UI
</h1>
</div>
Expand Down

0 comments on commit 7f94324

Please sign in to comment.