some minor adjustments

This commit is contained in:
Aman Varshney
2025-02-18 20:30:24 +05:30
parent 42285515c6
commit 5b5016037e
7 changed files with 32 additions and 27 deletions

View File

@@ -304,10 +304,13 @@ const CustomizableStack = () => {
zoomOnPinch={false}
preventScrolling={false}
nodesConnectable={true}
nodesDraggable={false}
nodesDraggable={true}
connectOnClick={true}
deleteKeyCode="Delete"
selectionKeyCode="Shift"
proOptions={{
hideAttribution: true,
}}
>
<Background
className="bg-gray-950/5"

View File

@@ -41,7 +41,7 @@ const Navbar = () => {
return (
<nav
className={`fixed top-0 left-0 z-[100] w-screen px-8 py-5 flex items-center sm:justify-between justify-center transition-all duration-300 ${
className={`fixed top-0 right-0 z-[100] w-screen px-8 py-5 flex items-center sm:justify-between justify-center transition-all duration-300 ${
scrolled
? "bg-transparent border-transparent"
: "sm:bg-black/10 sm:backdrop-blur-xl sm:border-b border-white/10"

View File

@@ -77,6 +77,22 @@ const TechConstellation = () => {
const centerRef = useRef<HTMLDivElement>(null);
const techRefs = useRef<{ [key: string]: HTMLDivElement | null }>({});
const [isVisible, setIsVisible] = useState(false);
const [stars, setStars] = useState<
Array<{
left: string;
top: string;
delay: string;
}>
>([]);
useEffect(() => {
const newStars = Array.from({ length: 20 }, () => ({
left: `${Math.random() * 100}%`,
top: `${Math.random() * 100}%`,
delay: `${Math.random() * 5}s`,
}));
setStars(newStars);
}, []);
const calculateRadius = (category: string) => {
switch (category) {
@@ -210,15 +226,14 @@ const TechConstellation = () => {
)}
<div className="absolute inset-0 overflow-hidden">
{[...Array(20)].map((_, i) => (
{stars.map((star) => (
<div
// biome-ignore lint/suspicious/noArrayIndexKey: <explanation>
key={`star-${i}`}
key={star.top}
className="absolute w-2 h-2 bg-blue-500 rounded-full opacity-20"
style={{
left: `${Math.random() * 100}%`,
top: `${Math.random() * 100}%`,
animationDelay: `${Math.random() * 5}s`,
left: star.left,
top: star.top,
animationDelay: star.delay,
}}
/>
))}