Skip to content

Commit 5a4edc8

Browse files
committed
feat: reformular página NotFound com layout profissional
- Implementar Header e Footer para consistência visual - Substituir AlertTriangle pelo ícone Radar (mais tech e amigável) - Adicionar seções organizadas: 'O que aconteceu?' e 'Como podemos ajudar?' - Criar cards de navegação com botões estilizados - Implementar funcionalidade 'Página Anterior' com window.history.back() - Aplicar design system completo (bg-background, text-foreground, etc.) - Reformular todo conteúdo para português brasileiro - Adicionar layout responsivo com grid md:grid-cols-2 - Melhorar experiência do usuário com texto amigável e navegação clara Resolves: Melhoria da página 404 conforme tarefa documentada
1 parent 4fd738d commit 5a4edc8

File tree

1 file changed

+87
-8
lines changed

1 file changed

+87
-8
lines changed

src/pages/NotFound.tsx

Lines changed: 87 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
import { Link, useLocation } from "react-router-dom";
22
import { useEffect } from "react";
3+
import Header from "@/components/Header";
4+
import Footer from "@/components/Footer";
5+
import { Radar, Home, ArrowLeft, Search } from "lucide-react";
36

47
const NotFound = () => {
58
const location = useLocation();
@@ -9,14 +12,90 @@ const NotFound = () => {
912
}, [location.pathname]);
1013

1114
return (
12-
<div className="min-h-screen flex items-center justify-center bg-gray-100">
13-
<div className="text-center">
14-
<h1 className="text-4xl font-bold mb-4">404</h1>
15-
<p className="text-xl text-gray-600 mb-4">Oops! Page not found</p>
16-
<Link to="/" className="text-blue-500 hover:text-blue-700 underline">
17-
Voltar para a página inicial
18-
</Link>
19-
</div>
15+
<div className="min-h-screen bg-background">
16+
<Header />
17+
18+
<main className="container mx-auto px-6 py-16">
19+
<div className="max-w-4xl mx-auto">
20+
<div className="text-center mb-12">
21+
<Radar className="w-16 h-16 mx-auto mb-6 text-primary" />
22+
<h1 className="text-4xl md:text-5xl font-bold mb-6 text-foreground">
23+
404 - Página não encontrada
24+
</h1>
25+
<p className="text-xl text-muted-foreground">
26+
Ops! A página que você está procurando não existe ou foi movida para outro local.
27+
</p>
28+
</div>
29+
30+
<div className="space-y-12">
31+
<section>
32+
<div className="flex items-center mb-6 justify-center">
33+
<Search className="w-6 h-6 mr-3 text-primary" />
34+
<h2 className="text-2xl font-bold text-foreground">O que aconteceu?</h2>
35+
</div>
36+
<div className="prose prose-lg max-w-none text-muted-foreground text-center">
37+
<p>
38+
A página que você tentou acessar pode ter sido removida, renomeada ou está
39+
temporariamente indisponível. Não se preocupe, isso acontece às vezes durante
40+
atualizações do site.
41+
</p>
42+
</div>
43+
</section>
44+
45+
<section>
46+
<div className="flex items-center mb-6 justify-center">
47+
<Home className="w-6 h-6 mr-3 text-primary" />
48+
<h2 className="text-2xl font-bold text-foreground">Como podemos ajudar?</h2>
49+
</div>
50+
<div className="prose prose-lg max-w-none text-muted-foreground">
51+
<p className="text-center mb-8">
52+
Aqui estão algumas opções para você continuar navegando:
53+
</p>
54+
<div className="grid md:grid-cols-2 gap-6 not-prose">
55+
<div className="bg-card p-6 rounded-lg border border-border text-center">
56+
<h3 className="text-lg font-semibold mb-3 text-foreground">Voltar ao Início</h3>
57+
<p className="text-muted-foreground mb-4">
58+
Retorne à página inicial e explore nossos produtos e serviços.
59+
</p>
60+
<Link
61+
to="/"
62+
className="inline-flex items-center px-4 py-2 bg-primary text-primary-foreground rounded-md hover:bg-primary/90 transition-colors"
63+
>
64+
<Home className="w-4 h-4 mr-2" />
65+
Página Inicial
66+
</Link>
67+
</div>
68+
69+
<div className="bg-card p-6 rounded-lg border border-border text-center">
70+
<ArrowLeft className="w-8 h-8 mx-auto mb-4 text-primary" />
71+
<p className="text-muted-foreground mb-4">
72+
Retorne à página anterior de onde você veio.
73+
</p>
74+
<button
75+
onClick={() => window.history.back()}
76+
className="inline-flex items-center px-4 py-2 bg-secondary text-secondary-foreground rounded-md hover:bg-secondary/90 transition-colors"
77+
>
78+
<ArrowLeft className="w-4 h-4 mr-2" />
79+
Página Anterior
80+
</button>
81+
</div>
82+
</div>
83+
</div>
84+
</section>
85+
86+
<section className="text-center">
87+
<div className="prose prose-lg max-w-none text-muted-foreground">
88+
<p className="text-sm mt-8 pt-8 border-t border-border">
89+
Se você acredita que chegou aqui por um erro em nosso site, entre em contato
90+
conosco. Estamos sempre trabalhando para melhorar sua experiência.
91+
</p>
92+
</div>
93+
</section>
94+
</div>
95+
</div>
96+
</main>
97+
98+
<Footer />
2099
</div>
21100
);
22101
};

0 commit comments

Comments
 (0)