fix: Fix YAML syntax errors and validator prompt formatting
- Fix YAML files with unquoted strings containing quotes - Export singleton instances in ai/__init__.py - Fix validator scoring prompt to use replace() instead of format() to avoid conflicts with JSON curly braces Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -4,108 +4,79 @@
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0">
|
||||
<title>Login - Social Media Automation</title>
|
||||
<link href="https://cdn.jsdelivr.net/npm/tailwindcss@2.2.19/dist/tailwind.min.css" rel="stylesheet">
|
||||
<script src="https://cdn.tailwindcss.com"></script>
|
||||
<link href="https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap" rel="stylesheet">
|
||||
<style>
|
||||
body {
|
||||
background: linear-gradient(135deg, #1a1a2e 0%, #16213e 50%, #0f3460 100%);
|
||||
min-height: 100vh;
|
||||
}
|
||||
.card {
|
||||
background-color: #16213e;
|
||||
border-radius: 12px;
|
||||
}
|
||||
.accent { color: #d4a574; }
|
||||
.btn-primary {
|
||||
background-color: #d4a574;
|
||||
color: #1a1a2e;
|
||||
transition: all 0.3s;
|
||||
}
|
||||
.btn-primary:hover {
|
||||
background-color: #c49564;
|
||||
transform: translateY(-2px);
|
||||
}
|
||||
.input-field {
|
||||
background-color: #1a1a2e;
|
||||
border: 1px solid #2d3748;
|
||||
color: #fff;
|
||||
transition: border-color 0.3s;
|
||||
}
|
||||
.input-field:focus {
|
||||
border-color: #d4a574;
|
||||
outline: none;
|
||||
}
|
||||
.input-field::placeholder {
|
||||
color: #6b7280;
|
||||
}
|
||||
body { font-family: 'Inter', sans-serif; }
|
||||
.gradient-bg { background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%); }
|
||||
.card { background: rgba(30, 41, 59, 0.8); backdrop-filter: blur(10px); border: 1px solid rgba(99, 102, 241, 0.1); }
|
||||
.btn-primary { background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%); }
|
||||
.btn-primary:hover { background: linear-gradient(135deg, #4f46e5 0%, #7c3aed 100%); }
|
||||
.input-field { background: rgba(15, 23, 42, 0.5); border: 1px solid rgba(99, 102, 241, 0.2); }
|
||||
.input-field:focus { border-color: #6366f1; box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1); }
|
||||
.animate-float { animation: float 3s ease-in-out infinite; }
|
||||
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }
|
||||
</style>
|
||||
</head>
|
||||
<body class="flex items-center justify-center p-4">
|
||||
<div class="card p-8 w-full max-w-md">
|
||||
<body class="gradient-bg min-h-screen flex items-center justify-center p-4">
|
||||
<div class="w-full max-w-md">
|
||||
<!-- Logo -->
|
||||
<div class="text-center mb-8">
|
||||
<div class="inline-flex items-center justify-center w-16 h-16 rounded-xl bg-gradient-to-br from-yellow-600 to-yellow-800 mb-4">
|
||||
<span class="text-2xl font-bold text-white">AS</span>
|
||||
<div class="w-20 h-20 mx-auto rounded-2xl bg-gradient-to-br from-indigo-500 to-purple-600 flex items-center justify-center mb-4 animate-float">
|
||||
<span class="text-4xl">📱</span>
|
||||
</div>
|
||||
<h1 class="text-2xl font-bold text-white">Social Media Automation</h1>
|
||||
<p class="text-gray-400 mt-1">Consultoría AS</p>
|
||||
<p class="text-gray-400 mt-2">Consultoría AS</p>
|
||||
</div>
|
||||
|
||||
<!-- Error message -->
|
||||
{% if error %}
|
||||
<div class="bg-red-900/50 border border-red-700 text-red-300 px-4 py-3 rounded-lg mb-6">
|
||||
{{ error }}
|
||||
<!-- Login Card -->
|
||||
<div class="card rounded-2xl p-8">
|
||||
<h2 class="text-xl font-semibold text-white mb-6 text-center">Iniciar Sesión</h2>
|
||||
|
||||
{% if error %}
|
||||
<div class="bg-red-500/20 border border-red-500/50 text-red-400 px-4 py-3 rounded-lg mb-6 text-sm">
|
||||
{{ error }}
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<form method="POST" action="/login" class="space-y-5">
|
||||
<div>
|
||||
<label class="block text-sm font-medium text-gray-300 mb-2">Usuario o Email</label>
|
||||
<input
|
||||
type="text"
|
||||
name="username"
|
||||
required
|
||||
class="input-field w-full px-4 py-3 rounded-xl text-white placeholder-gray-500 focus:outline-none transition-all"
|
||||
placeholder="tu@email.com"
|
||||
autocomplete="username"
|
||||
>
|
||||
</div>
|
||||
|
||||
<div>
|
||||
<label class="block text-sm font-medium text-gray-300 mb-2">Contraseña</label>
|
||||
<input
|
||||
type="password"
|
||||
name="password"
|
||||
required
|
||||
class="input-field w-full px-4 py-3 rounded-xl text-white placeholder-gray-500 focus:outline-none transition-all"
|
||||
placeholder="••••••••"
|
||||
autocomplete="current-password"
|
||||
>
|
||||
</div>
|
||||
|
||||
<button
|
||||
type="submit"
|
||||
class="btn-primary w-full py-3 rounded-xl text-white font-medium transition-all hover:shadow-lg hover:shadow-indigo-500/25"
|
||||
>
|
||||
Entrar
|
||||
</button>
|
||||
</form>
|
||||
</div>
|
||||
{% endif %}
|
||||
|
||||
<!-- Login Form -->
|
||||
<form method="POST" action="/login">
|
||||
<div class="mb-4">
|
||||
<label for="username" class="block text-gray-400 text-sm mb-2">
|
||||
Usuario o Email
|
||||
</label>
|
||||
<input
|
||||
type="text"
|
||||
id="username"
|
||||
name="username"
|
||||
required
|
||||
class="input-field w-full px-4 py-3 rounded-lg"
|
||||
placeholder="tu.usuario"
|
||||
autocomplete="username"
|
||||
>
|
||||
</div>
|
||||
|
||||
<div class="mb-6">
|
||||
<label for="password" class="block text-gray-400 text-sm mb-2">
|
||||
Contraseña
|
||||
</label>
|
||||
<input
|
||||
type="password"
|
||||
id="password"
|
||||
name="password"
|
||||
required
|
||||
class="input-field w-full px-4 py-3 rounded-lg"
|
||||
placeholder="••••••••"
|
||||
autocomplete="current-password"
|
||||
>
|
||||
</div>
|
||||
|
||||
<button
|
||||
type="submit"
|
||||
class="btn-primary w-full py-3 rounded-lg font-semibold text-lg"
|
||||
>
|
||||
Iniciar Sesión
|
||||
</button>
|
||||
</form>
|
||||
|
||||
<!-- Footer -->
|
||||
<div class="mt-8 text-center text-gray-500 text-sm">
|
||||
<p>Sistema de automatización de redes sociales</p>
|
||||
<p class="mt-1">
|
||||
<a href="https://consultoria-as.com" target="_blank" class="accent hover:underline">
|
||||
consultoria-as.com
|
||||
</a>
|
||||
</p>
|
||||
</div>
|
||||
<p class="text-center text-gray-500 text-sm mt-8">
|
||||
© 2025 <a href="https://consultoria-as.com" target="_blank" class="text-indigo-400 hover:underline">Consultoría AS</a> - Tijuana, México
|
||||
</p>
|
||||
</div>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user