Compare commits
3 Commits
8884e28ed7
...
cf96f84470
| Author | SHA1 | Date | |
|---|---|---|---|
| cf96f84470 | |||
| 07835d2a7b | |||
| 3b4117c9b4 |
+3
-1
@@ -6,7 +6,10 @@ WORKDIR /app
|
|||||||
FROM base AS deps
|
FROM base AS deps
|
||||||
RUN apk add --no-cache libc6-compat openssl
|
RUN apk add --no-cache libc6-compat openssl
|
||||||
COPY package.json package-lock.json* ./
|
COPY package.json package-lock.json* ./
|
||||||
|
COPY prisma ./prisma/
|
||||||
RUN npm install --frozen-lockfile
|
RUN npm install --frozen-lockfile
|
||||||
|
# Generate Prisma Client with correct binary targets
|
||||||
|
RUN npx prisma generate
|
||||||
|
|
||||||
# Build stage
|
# Build stage
|
||||||
FROM base AS builder
|
FROM base AS builder
|
||||||
@@ -17,7 +20,6 @@ RUN apk add --no-cache openssl
|
|||||||
COPY --from=deps /app/node_modules ./node_modules
|
COPY --from=deps /app/node_modules ./node_modules
|
||||||
COPY . .
|
COPY . .
|
||||||
ENV NEXT_TELEMETRY_DISABLED=1
|
ENV NEXT_TELEMETRY_DISABLED=1
|
||||||
RUN npx prisma generate
|
|
||||||
RUN npm run build
|
RUN npm run build
|
||||||
|
|
||||||
# Production stage
|
# Production stage
|
||||||
|
|||||||
+1
-1
@@ -19,7 +19,7 @@ services:
|
|||||||
depends_on:
|
depends_on:
|
||||||
- db
|
- db
|
||||||
environment:
|
environment:
|
||||||
DATABASE_URL: postgresql://user:change_me_password@10.0.1.21:5432/1000apps
|
DATABASE_URL: postgresql://user:change_me_password@db:5432/1000apps
|
||||||
NEXTAUTH_SECRET: test-secret-2x4=
|
NEXTAUTH_SECRET: test-secret-2x4=
|
||||||
NEXTAUTH_URL: https://1000apps.fluxtechnologies.uk
|
NEXTAUTH_URL: https://1000apps.fluxtechnologies.uk
|
||||||
GOOGLE_CLIENT_ID: ""
|
GOOGLE_CLIENT_ID: ""
|
||||||
|
|||||||
+3
-7
@@ -1,13 +1,9 @@
|
|||||||
import { SessionProvider } from "next-auth/react"
|
// _app.jsx — SessionProvider de autenticação REMOVIDO (login desativado temporariamente).
|
||||||
|
// App agora abre direto no dashboard, sem verificação de sessão.
|
||||||
import "../styles/globals.css"
|
import "../styles/globals.css"
|
||||||
|
|
||||||
export default function App({
|
export default function App({ Component, pageProps }) {
|
||||||
Component,
|
|
||||||
pageProps: { session, ...pageProps }
|
|
||||||
}) {
|
|
||||||
return (
|
return (
|
||||||
<SessionProvider session={session}>
|
|
||||||
<Component {...pageProps} />
|
<Component {...pageProps} />
|
||||||
</SessionProvider>
|
|
||||||
)
|
)
|
||||||
}
|
}
|
||||||
@@ -1,3 +1,6 @@
|
|||||||
|
// API DE AUTENTICAÇÃO DESATIVADA TEMPORARIAMENTE (2026-07-11)
|
||||||
|
// Arquivo PRESERVADO para reativação futura. Nenhum componente/chamada
|
||||||
|
// ativa depende desta rota após a remoção do fluxo de login.
|
||||||
import NextAuth from "next-auth"
|
import NextAuth from "next-auth"
|
||||||
import CredentialsProvider from "next-auth/providers/credentials"
|
import CredentialsProvider from "next-auth/providers/credentials"
|
||||||
import { PrismaClient } from "@prisma/client"
|
import { PrismaClient } from "@prisma/client"
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
import { useState, useEffect } from "react"
|
import { useState, useEffect } from "react"
|
||||||
import { useSession } from "next-auth/react"
|
|
||||||
import { useRouter } from "next/router"
|
import { useRouter } from "next/router"
|
||||||
|
|
||||||
// Top 100 Notícias - Trends Brasil e Mundo (Junho 2026)
|
// Top 100 Notícias - Trends Brasil e Mundo (Junho 2026)
|
||||||
@@ -122,7 +121,6 @@ const weeklyTrends = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
export default function TrendsNews() {
|
export default function TrendsNews() {
|
||||||
const { data: session } = useSession()
|
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
const [selectedCategory, setSelectedCategory] = useState("TODAS")
|
const [selectedCategory, setSelectedCategory] = useState("TODAS")
|
||||||
const [trendingNews, setTrendingNews] = useState(weeklyTrends)
|
const [trendingNews, setTrendingNews] = useState(weeklyTrends)
|
||||||
|
|||||||
@@ -1,5 +1,4 @@
|
|||||||
import { useState, useEffect } from "react"
|
import { useState, useEffect } from "react"
|
||||||
import { useSession } from "next-auth/react"
|
|
||||||
import { useRouter } from "next/router"
|
import { useRouter } from "next/router"
|
||||||
|
|
||||||
// Copa do Mundo 2026 - Grupos e Classificação (48 seleções, 12 grupos de 4)
|
// Copa do Mundo 2026 - Grupos e Classificação (48 seleções, 12 grupos de 4)
|
||||||
@@ -95,7 +94,6 @@ const worldCupNews = [
|
|||||||
]
|
]
|
||||||
|
|
||||||
export default function WorldCup2026() {
|
export default function WorldCup2026() {
|
||||||
const { data: session } = useSession()
|
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
const [selectedGroup, setSelectedGroup] = useState("TODOS")
|
const [selectedGroup, setSelectedGroup] = useState("TODOS")
|
||||||
const [selectedCategory, setSelectedCategory] = useState("TODAS")
|
const [selectedCategory, setSelectedCategory] = useState("TODAS")
|
||||||
|
|||||||
+1
-11
@@ -1,11 +1,10 @@
|
|||||||
|
import React from "react"
|
||||||
import { useState } from "react"
|
import { useState } from "react"
|
||||||
import { useRouter } from "next/router"
|
import { useRouter } from "next/router"
|
||||||
import { useSession, signOut } from "next-auth/react"
|
|
||||||
import AvatarSelector from "../components/AvatarSelector"
|
import AvatarSelector from "../components/AvatarSelector"
|
||||||
import CategoryMenu from "../components/CategoryMenu"
|
import CategoryMenu from "../components/CategoryMenu"
|
||||||
|
|
||||||
export default function Dashboard() {
|
export default function Dashboard() {
|
||||||
const { data: session } = useSession()
|
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
const [selectedAvatar, setSelectedAvatar] = useState("😀")
|
const [selectedAvatar, setSelectedAvatar] = useState("😀")
|
||||||
const [selectedCategory, setSelectedCategory] = useState("all")
|
const [selectedCategory, setSelectedCategory] = useState("all")
|
||||||
@@ -104,15 +103,6 @@ export default function Dashboard() {
|
|||||||
selectedAvatar={selectedAvatar}
|
selectedAvatar={selectedAvatar}
|
||||||
onSelect={setSelectedAvatar}
|
onSelect={setSelectedAvatar}
|
||||||
/>
|
/>
|
||||||
<span className="text-gray-600">
|
|
||||||
Olá, {session?.user?.name || session?.user?.username || "usuário"}!
|
|
||||||
</span>
|
|
||||||
<button
|
|
||||||
onClick={() => signOut({ callbackUrl: "/" })}
|
|
||||||
className="text-red-600 hover:underline font-medium"
|
|
||||||
>
|
|
||||||
Sair
|
|
||||||
</button>
|
|
||||||
</div>
|
</div>
|
||||||
</nav>
|
</nav>
|
||||||
|
|
||||||
|
|||||||
+12
-137
@@ -1,139 +1,14 @@
|
|||||||
// Updated: force rebuild for cache invalidation
|
// index.jsx — rota "/" agora redireciona direto para o dashboard.
|
||||||
|
// O login foi removido; o app abre sem autenticação.
|
||||||
export default function Home() {
|
export default function Home() {
|
||||||
return (
|
return null
|
||||||
<div className="bg-gray-50 min-h-screen">
|
}
|
||||||
{/* Header */}
|
|
||||||
<header className="bg-white shadow-sm">
|
export async function getServerSideProps() {
|
||||||
<div className="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-4 flex justify-between items-center">
|
return {
|
||||||
<h1 className="text-2xl font-bold text-gray-900">1000Apps</h1>
|
redirect: {
|
||||||
<div className="space-x-4">
|
destination: "/dashboard",
|
||||||
<a href="/signin" className="text-gray-600 hover:text-gray-900 font-medium">Entrar</a>
|
permanent: false,
|
||||||
<a href="/signup" className="bg-blue-600 text-white px-4 py-2 rounded-lg font-medium hover:bg-blue-700 transition">Cadastrar</a>
|
},
|
||||||
</div>
|
}
|
||||||
</div>
|
|
||||||
</header>
|
|
||||||
|
|
||||||
{/* Hero Section */}
|
|
||||||
<section className="bg-gradient-to-r from-blue-600 to-purple-600 text-white py-20">
|
|
||||||
<div className="max-w-4xl mx-auto px-4 text-center">
|
|
||||||
<h2 className="text-5xl font-bold mb-6">Seu Canivete Suíço Digital</h2>
|
|
||||||
<p className="text-xl mb-8 opacity-90">
|
|
||||||
Mais de 1000 ferramentas úteis, games e produtividade - tudo online, sem instalar nada!
|
|
||||||
</p>
|
|
||||||
<div className="flex justify-center space-x-4">
|
|
||||||
<a href="/signup" className="bg-white text-blue-600 px-8 py-3 rounded-lg font-semibold text-lg hover:bg-gray-100 transition">Começar Grátis</a>
|
|
||||||
<a href="#apps" className="border border-white text-white px-8 py-3 rounded-lg font-semibold text-lg hover:bg-white/10 transition">Explorar Apps</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
{/* Categories */}
|
|
||||||
<section id="apps" className="py-16 px-4">
|
|
||||||
<div className="max-w-6xl mx-auto">
|
|
||||||
<h3 className="text-3xl font-bold text-center mb-12 text-gray-800">Categorias</h3>
|
|
||||||
|
|
||||||
<div className="grid md:grid-cols-3 gap-8">
|
|
||||||
<div className="bg-white rounded-xl p-8 card-hover transition transform hover:-translate-y-1">
|
|
||||||
<div className="w-14 h-14 bg-blue-100 rounded-lg flex items-center justify-center mb-4">
|
|
||||||
<svg className="w-8 h-8 text-blue-600" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
|
||||||
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M9 5l7 7-7 7" />
|
|
||||||
</svg>
|
|
||||||
</div>
|
|
||||||
<h4 className="text-xl font-semibold mb-2">Produtividade</h4>
|
|
||||||
<p className="text-gray-600 mb-4">Ferramentas para otimizar seu tempo e trabalho</p>
|
|
||||||
<span className="text-blue-600 font-medium">Ver apps →</span>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div className="bg-white rounded-xl p-8 card-hover transition transform hover:-translate-y-1">
|
|
||||||
<div className="w-14 h-14 bg-green-100 rounded-lg flex items-center justify-center mb-4">
|
|
||||||
<svg className="w-8 h-8 text-green-600" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
|
||||||
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M11 4a2 2 0 114 0v5a2 2 0 01-2 2H7a2 2 0 00-2-2V6a2 2 0 012-2h2z" />
|
|
||||||
</svg>
|
|
||||||
</div>
|
|
||||||
<h4 className="text-xl font-semibold mb-2">Utilidades</h4>
|
|
||||||
<p className="text-gray-600 mb-4">Ferramentas práticas para o dia a dia</p>
|
|
||||||
<span className="text-green-600 font-medium">Ver apps →</span>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div className="bg-white rounded-xl p-8 card-hover transition transform hover:-translate-y-1">
|
|
||||||
<div className="w-14 h-14 bg-purple-100 rounded-lg flex items-center justify-center mb-4">
|
|
||||||
<svg className="w-8 h-8 text-purple-600" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
|
||||||
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M14.752 12.795a7.95 7.95 0 001.904-5.452 7.95 7.95 0 00-7.95 7.95A7.95 7.95 0 0012.795 14.752" />
|
|
||||||
</svg>
|
|
||||||
</div>
|
|
||||||
<h4 className="text-xl font-semibold mb-2">Games</h4>
|
|
||||||
<p className="text-gray-600 mb-4">Diversão rápida e envolvente</p>
|
|
||||||
<span className="text-purple-600 font-medium">Ver apps →</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
{/* Features */}
|
|
||||||
<section className="bg-gray-100 py-16 px-4">
|
|
||||||
<div className="max-w-6xl mx-auto">
|
|
||||||
<h3 className="text-3xl font-bold text-center mb-12 text-gray-800">Por que 1000Apps?</h3>
|
|
||||||
|
|
||||||
<div className="grid md:grid-cols-2 lg:grid-cols-4 gap-6">
|
|
||||||
<div className="text-center">
|
|
||||||
<div className="w-16 h-16 bg-blue-600 rounded-full flex items-center justify-center mx-auto mb-4">
|
|
||||||
<span className="text-2xl font-bold text-white">01</span>
|
|
||||||
</div>
|
|
||||||
<h5 className="font-semibold mb-2">Nada para Instalar</h5>
|
|
||||||
<p className="text-sm text-gray-600">Tudo rodando direto no navegador</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div className="text-center">
|
|
||||||
<div className="w-16 h-16 bg-green-600 rounded-full flex items-center justify-center mx-auto mb-4">
|
|
||||||
<span className="text-2xl font-bold text-white">02</span>
|
|
||||||
</div>
|
|
||||||
<h5 className="font-semibold mb-2">Sempre Atualizado</h5>
|
|
||||||
<p className="text-sm text-gray-600">Conteúdo fresco todo dia</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div className="text-center">
|
|
||||||
<div className="w-16 h-16 bg-purple-600 rounded-full flex items-center justify-center mx-auto mb-4">
|
|
||||||
<span className="text-2xl font-bold text-white">03</span>
|
|
||||||
</div>
|
|
||||||
<h5 className="font-semibold mb-2">Curadoria Inteligente</h5>
|
|
||||||
<p className="text-sm text-gray-600">Só apps úteis e testados</p>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<div className="text-center">
|
|
||||||
<div className="w-16 h-16 bg-orange-600 rounded-full flex items-center justify-center mx-auto mb-4">
|
|
||||||
<span className="text-2xl font-bold text-white">04</span>
|
|
||||||
</div>
|
|
||||||
<h5 className="font-semibold mb-2">Grátis para Sempre</h5>
|
|
||||||
<p className="text-sm text-gray-600">Acesso completo sem pagar nada</p>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
{/* CTA Final */}
|
|
||||||
<section className="py-20 px-4">
|
|
||||||
<div className="max-w-3xl mx-auto text-center">
|
|
||||||
<h3 className="text-4xl font-bold mb-4 text-gray-900">Pronto para começar?</h3>
|
|
||||||
<p className="text-lg text-gray-600 mb-8">
|
|
||||||
Junte-se a milhares de usuários que já economizam tempo com 1000Apps
|
|
||||||
</p>
|
|
||||||
<a href="/signup" className="inline-block bg-blue-600 text-white px-10 py-4 rounded-lg font-semibold text-xl hover:bg-blue-700 transition transform hover:scale-105">
|
|
||||||
Criar Conta Grátis
|
|
||||||
</a>
|
|
||||||
</div>
|
|
||||||
</section>
|
|
||||||
|
|
||||||
{/* Footer */}
|
|
||||||
<footer className="bg-gray-900 text-white py-8 px-4">
|
|
||||||
<div className="max-w-6xl mx-auto text-center">
|
|
||||||
<p className="mb-4">© 2026 1000Apps. Todos os direitos reservados.</p>
|
|
||||||
<div className="space-x-6 text-sm">
|
|
||||||
<a href="#" className="hover:text-gray-300">Termos</a>
|
|
||||||
<a href="#" className="hover:text-gray-300">Privacidade</a>
|
|
||||||
<a href="#" className="hover:text-gray-300">Contato</a>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</footer>
|
|
||||||
</div>
|
|
||||||
)
|
|
||||||
}
|
}
|
||||||
@@ -0,0 +1,143 @@
|
|||||||
|
// LANDING PAGE — DESATIVADA TEMPORARIAMENTE (2026-07-11)
|
||||||
|
// Motivo: remoção do fluxo de login; app agora abre direto no dashboard.
|
||||||
|
// Arquivo PRESERVADO para reativação futura. Não foi apagado componente,
|
||||||
|
// asset ou estilo. Para reativar: renomear para pages/index.jsx.
|
||||||
|
// Updated: force rebuild for cache invalidation
|
||||||
|
export default function Home() {
|
||||||
|
return (
|
||||||
|
<div className="bg-gray-50 min-h-screen">
|
||||||
|
{/* Header */}
|
||||||
|
<header className="bg-white shadow-sm">
|
||||||
|
<div className="max-w-7xl mx-auto px-4 sm:px-6 lg:px-8 py-4 flex justify-between items-center">
|
||||||
|
<h1 className="text-2xl font-bold text-gray-900">1000Apps</h1>
|
||||||
|
<div className="space-x-4">
|
||||||
|
<a href="/signin" className="text-gray-600 hover:text-gray-900 font-medium">Entrar</a>
|
||||||
|
<a href="/signup" className="bg-blue-600 text-white px-4 py-2 rounded-lg font-medium hover:bg-blue-700 transition">Cadastrar</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</header>
|
||||||
|
|
||||||
|
{/* Hero Section */}
|
||||||
|
<section className="bg-gradient-to-r from-blue-600 to-purple-600 text-white py-20">
|
||||||
|
<div className="max-w-4xl mx-auto px-4 text-center">
|
||||||
|
<h2 className="text-5xl font-bold mb-6">Seu Canivete Suíço Digital</h2>
|
||||||
|
<p className="text-xl mb-8 opacity-90">
|
||||||
|
Mais de 1000 ferramentas úteis, games e produtividade - tudo online, sem instalar nada!
|
||||||
|
</p>
|
||||||
|
<div className="flex justify-center space-x-4">
|
||||||
|
<a href="/signup" className="bg-white text-blue-600 px-8 py-3 rounded-lg font-semibold text-lg hover:bg-gray-100 transition">Começar Grátis</a>
|
||||||
|
<a href="#apps" className="border border-white text-white px-8 py-3 rounded-lg font-semibold text-lg hover:bg-white/10 transition">Explorar Apps</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
{/* Categories */}
|
||||||
|
<section id="apps" className="py-16 px-4">
|
||||||
|
<div className="max-w-6xl mx-auto">
|
||||||
|
<h3 className="text-3xl font-bold text-center mb-12 text-gray-800">Categorias</h3>
|
||||||
|
|
||||||
|
<div className="grid md:grid-cols-3 gap-8">
|
||||||
|
<div className="bg-white rounded-xl p-8 card-hover transition transform hover:-translate-y-1">
|
||||||
|
<div className="w-14 h-14 bg-blue-100 rounded-lg flex items-center justify-center mb-4">
|
||||||
|
<svg className="w-8 h-8 text-blue-600" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
||||||
|
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M9 5l7 7-7 7" />
|
||||||
|
</svg>
|
||||||
|
</div>
|
||||||
|
<h4 className="text-xl font-semibold mb-2">Produtividade</h4>
|
||||||
|
<p className="text-gray-600 mb-4">Ferramentas para otimizar seu tempo e trabalho</p>
|
||||||
|
<span className="text-blue-600 font-medium">Ver apps →</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div className="bg-white rounded-xl p-8 card-hover transition transform hover:-translate-y-1">
|
||||||
|
<div className="w-14 h-14 bg-green-100 rounded-lg flex items-center justify-center mb-4">
|
||||||
|
<svg className="w-8 h-8 text-green-600" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
||||||
|
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M11 4a2 2 0 114 0v5a2 2 0 01-2 2H7a2 2 0 00-2-2V6a2 2 0 012-2h2z" />
|
||||||
|
</svg>
|
||||||
|
</div>
|
||||||
|
<h4 className="text-xl font-semibold mb-2">Utilidades</h4>
|
||||||
|
<p className="text-gray-600 mb-4">Ferramentas práticas para o dia a dia</p>
|
||||||
|
<span className="text-green-600 font-medium">Ver apps →</span>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div className="bg-white rounded-xl p-8 card-hover transition transform hover:-translate-y-1">
|
||||||
|
<div className="w-14 h-14 bg-purple-100 rounded-lg flex items-center justify-center mb-4">
|
||||||
|
<svg className="w-8 h-8 text-purple-600" fill="none" stroke="currentColor" viewBox="0 0 24 24">
|
||||||
|
<path strokeLinecap="round" strokeLinejoin="round" strokeWidth="2" d="M14.752 12.795a7.95 7.95 0 001.904-5.452 7.95 7.95 0 00-7.95 7.95A7.95 7.95 0 0012.795 14.752" />
|
||||||
|
</svg>
|
||||||
|
</div>
|
||||||
|
<h4 className="text-xl font-semibold mb-2">Games</h4>
|
||||||
|
<p className="text-gray-600 mb-4">Diversão rápida e envolvente</p>
|
||||||
|
<span className="text-purple-600 font-medium">Ver apps →</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
{/* Features */}
|
||||||
|
<section className="bg-gray-100 py-16 px-4">
|
||||||
|
<div className="max-w-6xl mx-auto">
|
||||||
|
<h3 className="text-3xl font-bold text-center mb-12 text-gray-800">Por que 1000Apps?</h3>
|
||||||
|
|
||||||
|
<div className="grid md:grid-cols-2 lg:grid-cols-4 gap-6">
|
||||||
|
<div className="text-center">
|
||||||
|
<div className="w-16 h-16 bg-blue-600 rounded-full flex items-center justify-center mx-auto mb-4">
|
||||||
|
<span className="text-2xl font-bold text-white">01</span>
|
||||||
|
</div>
|
||||||
|
<h5 className="font-semibold mb-2">Nada para Instalar</h5>
|
||||||
|
<p className="text-sm text-gray-600">Tudo rodando direto no navegador</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div className="text-center">
|
||||||
|
<div className="w-16 h-16 bg-green-600 rounded-full flex items-center justify-center mx-auto mb-4">
|
||||||
|
<span className="text-2xl font-bold text-white">02</span>
|
||||||
|
</div>
|
||||||
|
<h5 className="font-semibold mb-2">Sempre Atualizado</h5>
|
||||||
|
<p className="text-sm text-gray-600">Conteúdo fresco todo dia</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div className="text-center">
|
||||||
|
<div className="w-16 h-16 bg-purple-600 rounded-full flex items-center justify-center mx-auto mb-4">
|
||||||
|
<span className="text-2xl font-bold text-white">03</span>
|
||||||
|
</div>
|
||||||
|
<h5 className="font-semibold mb-2">Curadoria Inteligente</h5>
|
||||||
|
<p className="text-sm text-gray-600">Só apps úteis e testados</p>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
<div className="text-center">
|
||||||
|
<div className="w-16 h-16 bg-orange-600 rounded-full flex items-center justify-center mx-auto mb-4">
|
||||||
|
<span className="text-2xl font-bold text-white">04</span>
|
||||||
|
</div>
|
||||||
|
<h5 className="font-semibold mb-2">Grátis para Sempre</h5>
|
||||||
|
<p className="text-sm text-gray-600">Acesso completo sem pagar nada</p>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
{/* CTA Final */}
|
||||||
|
<section className="py-20 px-4">
|
||||||
|
<div className="max-w-3xl mx-auto text-center">
|
||||||
|
<h3 className="text-4xl font-bold mb-4 text-gray-900">Pronto para começar?</h3>
|
||||||
|
<p className="text-lg text-gray-600 mb-8">
|
||||||
|
Junte-se a milhares de usuários que já economizam tempo com 1000Apps
|
||||||
|
</p>
|
||||||
|
<a href="/signup" className="inline-block bg-blue-600 text-white px-10 py-4 rounded-lg font-semibold text-xl hover:bg-blue-700 transition transform hover:scale-105">
|
||||||
|
Criar Conta Grátis
|
||||||
|
</a>
|
||||||
|
</div>
|
||||||
|
</section>
|
||||||
|
|
||||||
|
{/* Footer */}
|
||||||
|
<footer className="bg-gray-900 text-white py-8 px-4">
|
||||||
|
<div className="max-w-6xl mx-auto text-center">
|
||||||
|
<p className="mb-4">© 2026 1000Apps. Todos os direitos reservados.</p>
|
||||||
|
<div className="space-x-6 text-sm">
|
||||||
|
<a href="#" className="hover:text-gray-300">Termos</a>
|
||||||
|
<a href="#" className="hover:text-gray-300">Privacidade</a>
|
||||||
|
<a href="#" className="hover:text-gray-300">Contato</a>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</footer>
|
||||||
|
</div>
|
||||||
|
)
|
||||||
|
}
|
||||||
+33
-24
@@ -1,32 +1,38 @@
|
|||||||
import { useState } from 'react'
|
// LOGIN DESATIVADO TEMPORARIAMENTE (2026-07-11)
|
||||||
import { useRouter } from 'next/router'
|
// Arquivo PRESERVADO para reativação futura. Nada neste app o referencia
|
||||||
import { signIn } from 'next-auth/react'
|
// ativamente (sem links, sem SessionProvider, sem getSession).
|
||||||
|
import { useState } from "react"
|
||||||
|
import { useRouter } from "next/router"
|
||||||
|
import { signIn } from "next-auth/react"
|
||||||
|
|
||||||
export default function SignIn() {
|
export default function SignIn() {
|
||||||
const [username, setUsername] = useState('')
|
const [username, setUsername] = useState("")
|
||||||
const [password, setPassword] = useState('')
|
const [password, setPassword] = useState("")
|
||||||
const [error, setError] = useState('')
|
const [error, setError] = useState("")
|
||||||
const [loading, setLoading] = useState(false)
|
const [loading, setLoading] = useState(false)
|
||||||
const router = useRouter()
|
const router = useRouter()
|
||||||
|
|
||||||
const handleSubmit = async (e) => {
|
const handleSubmit = async (e) => {
|
||||||
e.preventDefault()
|
e.preventDefault()
|
||||||
setError('')
|
setError("")
|
||||||
setLoading(true)
|
setLoading(true)
|
||||||
|
|
||||||
try {
|
try {
|
||||||
const result = await signIn('credentials', {
|
const result = await signIn("credentials", {
|
||||||
redirect: false,
|
|
||||||
callbackUrl: '/dashboard',
|
|
||||||
username,
|
username,
|
||||||
password,
|
password,
|
||||||
|
redirect: false,
|
||||||
|
callbackUrl: "/dashboard"
|
||||||
})
|
})
|
||||||
if (result.error) {
|
|
||||||
setError(result.error)
|
if (result?.ok) {
|
||||||
} else if (result.status === 'ok') {
|
router.push("/dashboard")
|
||||||
router.push('/dashboard')
|
router.refresh()
|
||||||
|
} else {
|
||||||
|
setError(result?.error || "Erro ao entrar")
|
||||||
}
|
}
|
||||||
} catch (err) {
|
} catch (err) {
|
||||||
setError('Authentication error')
|
setError("Erro de conexão")
|
||||||
} finally {
|
} finally {
|
||||||
setLoading(false)
|
setLoading(false)
|
||||||
}
|
}
|
||||||
@@ -36,21 +42,28 @@ export default function SignIn() {
|
|||||||
<div className="min-h-screen bg-gray-50 flex items-center justify-center">
|
<div className="min-h-screen bg-gray-50 flex items-center justify-center">
|
||||||
<div className="bg-white p-8 rounded-lg shadow-md w-96">
|
<div className="bg-white p-8 rounded-lg shadow-md w-96">
|
||||||
<h2 className="text-2xl font-bold mb-6">Entrar - 1000Apps</h2>
|
<h2 className="text-2xl font-bold mb-6">Entrar - 1000Apps</h2>
|
||||||
|
|
||||||
|
{error && (
|
||||||
|
<div className="bg-red-100 text-red-700 p-3 rounded mb-4">
|
||||||
|
{error}
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
|
||||||
<form onSubmit={handleSubmit} className="space-y-4">
|
<form onSubmit={handleSubmit} className="space-y-4">
|
||||||
<input
|
<input
|
||||||
type="text"
|
type="text"
|
||||||
placeholder="Nome de usuário"
|
placeholder="Nome de usuário"
|
||||||
className="w-full p-2 border rounded"
|
|
||||||
value={username}
|
value={username}
|
||||||
onChange={(e) => setUsername(e.target.value)}
|
onChange={(e) => setUsername(e.target.value)}
|
||||||
|
className="w-full p-2 border rounded"
|
||||||
required
|
required
|
||||||
/>
|
/>
|
||||||
<input
|
<input
|
||||||
type="password"
|
type="password"
|
||||||
placeholder="Senha"
|
placeholder="Senha"
|
||||||
className="w-full p-2 border rounded"
|
|
||||||
value={password}
|
value={password}
|
||||||
onChange={(e) => setPassword(e.target.value)}
|
onChange={(e) => setPassword(e.target.value)}
|
||||||
|
className="w-full p-2 border rounded"
|
||||||
required
|
required
|
||||||
/>
|
/>
|
||||||
<button
|
<button
|
||||||
@@ -58,20 +71,16 @@ export default function SignIn() {
|
|||||||
disabled={loading}
|
disabled={loading}
|
||||||
className="w-full bg-blue-600 text-white py-2 rounded-lg disabled:opacity-50"
|
className="w-full bg-blue-600 text-white py-2 rounded-lg disabled:opacity-50"
|
||||||
>
|
>
|
||||||
{loading ? 'Entrando...' : 'Entrar'}
|
{loading ? "Entrando..." : "Entrar"}
|
||||||
</button>
|
</button>
|
||||||
</form>
|
</form>
|
||||||
|
|
||||||
<p className="text-center mt-4 text-sm">
|
<p className="text-center mt-4 text-sm">
|
||||||
Não tem conta?{' '}
|
Não tem conta?{" "}
|
||||||
<a href="/signup" className="text-blue-600 hover:underline">
|
<a href="/signup" className="text-blue-600 hover:underline">
|
||||||
Cadastrar
|
Cadastrar
|
||||||
</a>
|
</a>
|
||||||
</p>
|
</p>
|
||||||
{error && (
|
|
||||||
<div className="mt-4 bg-red-100 text-red-700 p-3 rounded">
|
|
||||||
{error}
|
|
||||||
</div>
|
|
||||||
)}
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
)
|
)
|
||||||
|
|||||||
@@ -1,3 +1,5 @@
|
|||||||
|
// CADASTRO DESATIVADO TEMPORARIAMENTE (2026-07-11)
|
||||||
|
// Arquivo PRESERVADO para reativação futura. Não há mais link ativo para cá.
|
||||||
import { useState } from "react"
|
import { useState } from "react"
|
||||||
import { useRouter } from "next/router"
|
import { useRouter } from "next/router"
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
generator client {
|
generator client {
|
||||||
provider = "prisma-client-js"
|
provider = "prisma-client-js"
|
||||||
binaryTargets = ["native", "linux-musl-openssl-3.0.x"]
|
binaryTargets = ["linux-musl-openssl-3.0.x"]
|
||||||
}
|
}
|
||||||
|
|
||||||
datasource db {
|
datasource db {
|
||||||
|
|||||||
Reference in New Issue
Block a user