full upgrade
This commit is contained in:
@@ -35,11 +35,11 @@ const ProjectDetail = () => {
|
||||
if (data.projects && data.projects.length > 0) {
|
||||
setProject(data.projects[0]);
|
||||
}
|
||||
} else {
|
||||
console.error('Failed to fetch project from API');
|
||||
}
|
||||
} catch (error) {
|
||||
console.error('Error loading project:', error);
|
||||
if (process.env.NODE_ENV === 'development') {
|
||||
console.error('Error loading project:', error);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
@@ -59,7 +59,7 @@ const ProjectDetail = () => {
|
||||
|
||||
return (
|
||||
<div className="min-h-screen animated-bg">
|
||||
<div className="max-w-4xl mx-auto px-4 py-20">
|
||||
<div className="max-w-4xl mx-auto px-4 pt-32 pb-20">
|
||||
{/* Header */}
|
||||
<motion.div
|
||||
initial={{ opacity: 0, y: 30 }}
|
||||
|
||||
@@ -30,11 +30,11 @@ const ProjectsPage = () => {
|
||||
if (response.ok) {
|
||||
const data = await response.json();
|
||||
setProjects(data.projects || []);
|
||||
} else {
|
||||
console.error('Failed to fetch projects from API');
|
||||
}
|
||||
} catch (error) {
|
||||
console.error('Error loading projects:', error);
|
||||
if (process.env.NODE_ENV === 'development') {
|
||||
console.error('Error loading projects:', error);
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
@@ -57,16 +57,13 @@ const ProjectsPage = () => {
|
||||
? projects
|
||||
: projects.filter(project => project.category === selectedCategory);
|
||||
|
||||
console.log('Selected category:', selectedCategory);
|
||||
console.log('Filtered projects:', filteredProjects);
|
||||
|
||||
if (!mounted) {
|
||||
return null;
|
||||
}
|
||||
|
||||
return (
|
||||
<div className="min-h-screen animated-bg">
|
||||
<div className="max-w-7xl mx-auto px-4 py-20">
|
||||
<div className="max-w-7xl mx-auto px-4 pt-32 pb-20">
|
||||
{/* Header */}
|
||||
<motion.div
|
||||
initial={{ opacity: 0, y: 30 }}
|
||||
@@ -105,7 +102,7 @@ const ProjectsPage = () => {
|
||||
onClick={() => setSelectedCategory(category)}
|
||||
className={`px-6 py-3 rounded-lg font-medium transition-all duration-200 ${
|
||||
selectedCategory === category
|
||||
? 'bg-blue-600 text-white shadow-lg'
|
||||
? 'bg-gray-800 text-cream shadow-lg'
|
||||
: 'bg-gray-800/50 text-gray-300 hover:bg-gray-700/50 hover:text-white'
|
||||
}`}
|
||||
>
|
||||
|
||||
Reference in New Issue
Block a user