feat(thank-you-page): convert to client component with confetti and UI enhancements

- Changed from server to client component to enable interactive features like confetti animation
- Removed server-side translations and hardcoded Portuguese text for simplicity
- Added confetti effect on page load and improved success icon with animations
- Updated buttons and share functionality for better user experience
- This enhances the donation thank you page with celebratory elements and client-side interactivity
This commit is contained in:
Evandro Fonseca Junior committed 2025-10-26 22:12:43 -03:00
1 parent ad62dd0de2
commit 8271d1fa31
7 files changed
+191 -54

No files matched your search

+3 -3
View File
@@ -1,5 +1,6 @@
import { NextRequest, NextResponse } from "next/server";
import { abacatePay } from "@/lib/abacatepay";
import { markAsPaid } from "@/lib/payment-cache";
export async function POST(request: NextRequest) {
try {
@@ -74,9 +75,8 @@ export async function POST(request: NextRequest) {
console.log("📝 Registro de pagamento:", donationRecord);
// Registar pixId confirmado (para frontend detectar via localStorage)
// O frontend salva pixIds confirmados em localStorage via evento do servidor
// Isso permite detecção em tempo real sem polling na API
// Salvar no cache para frontend detectar via polling
markAsPaid(pixQrCode.id, donationRecord);
// TODO: Quando implementar banco de dados, salvar aqui:
// await db.donations.create(donationRecord);