From b771322b2484fe28b22020cfffebd416e1aaebc8 Mon Sep 17 00:00:00 2001
From: killer-cf
Date: Fri, 12 Dec 2025 14:22:28 -0300
Subject: [PATCH 1/8] feat: Implement dedicated login page and public/dashboard
layouts, refactoring authentication flow and removing the todos page.
---
.../web/src/lib/components/ActionGuard.svelte | 8 +-
apps/web/src/lib/components/Footer.svelte | 52 +++
apps/web/src/lib/components/Header.svelte | 19 +-
.../src/lib/components/MenuProtection.svelte | 62 +---
apps/web/src/lib/components/Sidebar.svelte | 341 +-----------------
.../src/routes/(dashboard)/+layout.server.ts | 17 +-
.../web/src/routes/(dashboard)/+layout.svelte | 93 +----
apps/web/src/routes/(dashboard)/+page.svelte | 15 +-
apps/web/src/routes/(public)/+layout.svelte | 22 ++
.../web/src/routes/(public)/home/+page.svelte | 134 +++++++
.../src/routes/(public)/login/+page.server.ts | 24 ++
.../src/routes/(public)/login/+page.svelte | 312 ++++++++++++++++
apps/web/src/routes/+layout.svelte | 7 +-
apps/web/src/routes/todos/+page.svelte | 153 --------
bun.lock | 71 ++--
package.json | 19 +-
packages/backend/convex/_generated/api.d.ts | 116 +-----
.../backend/convex/_generated/dataModel.d.ts | 2 +-
18 files changed, 665 insertions(+), 802 deletions(-)
create mode 100644 apps/web/src/lib/components/Footer.svelte
create mode 100644 apps/web/src/routes/(public)/+layout.svelte
create mode 100644 apps/web/src/routes/(public)/home/+page.svelte
create mode 100644 apps/web/src/routes/(public)/login/+page.server.ts
create mode 100644 apps/web/src/routes/(public)/login/+page.svelte
delete mode 100644 apps/web/src/routes/todos/+page.svelte
diff --git a/apps/web/src/lib/components/ActionGuard.svelte b/apps/web/src/lib/components/ActionGuard.svelte
index 6b718fb..ba8086b 100644
--- a/apps/web/src/lib/components/ActionGuard.svelte
+++ b/apps/web/src/lib/components/ActionGuard.svelte
@@ -2,8 +2,9 @@
import { useQuery } from 'convex-svelte';
import { api } from '@sgse-app/backend/convex/_generated/api';
import type { Id } from '@sgse-app/backend/convex/_generated/dataModel';
- import { loginModalStore } from '$lib/stores/loginModal.svelte';
import { TriangleAlert } from 'lucide-svelte';
+ import { goto } from '$app/navigation';
+ import { resolve } from '$app/paths';
interface Props {
recurso: string;
@@ -34,7 +35,10 @@
verificando = false;
permitido = false;
const currentPath = window.location.pathname;
- loginModalStore.open(currentPath);
+ goto(`${resolve('/login')}?redirect=${encodeURIComponent(currentPath)}`, {
+ replaceState: true,
+ noScroll: true
+ });
return;
}
diff --git a/apps/web/src/lib/components/Footer.svelte b/apps/web/src/lib/components/Footer.svelte
new file mode 100644
index 0000000..81e8d72
--- /dev/null
+++ b/apps/web/src/lib/components/Footer.svelte
@@ -0,0 +1,52 @@
+
+
+
+
+
+
+
SGSE
+
+ Sistema de Gestão de Secretaria
+ Simplificando processos e conectando pessoas.
+
+
+
+
+
+
+
Contato
+
+ Secretaria de Educação
+ Recife - PE
+
+
+
+
+
+
+
+
© {currentYear} Governo de Pernambuco. Todos os direitos reservados.
+
Desenvolvido com tecnologia de ponta.
+
+
+
diff --git a/apps/web/src/lib/components/Header.svelte b/apps/web/src/lib/components/Header.svelte
index b4882cb..1e3ec44 100644
--- a/apps/web/src/lib/components/Header.svelte
+++ b/apps/web/src/lib/components/Header.svelte
@@ -1,7 +1,20 @@
-
-
-
+
diff --git a/apps/web/src/lib/components/MenuProtection.svelte b/apps/web/src/lib/components/MenuProtection.svelte
index bb772a9..d05e6b6 100644
--- a/apps/web/src/lib/components/MenuProtection.svelte
+++ b/apps/web/src/lib/components/MenuProtection.svelte
@@ -1,9 +1,9 @@
diff --git a/apps/web/src/lib/components/Sidebar.svelte b/apps/web/src/lib/components/Sidebar.svelte
index 3c40c08..deafcde 100644
--- a/apps/web/src/lib/components/Sidebar.svelte
+++ b/apps/web/src/lib/components/Sidebar.svelte
@@ -1,8 +1,7 @@
-{#if routeAction}
-
+
+
{@render children()}
-
-{:else}
-
- {@render children()}
-
-{/if}
+
+
diff --git a/apps/web/src/routes/(dashboard)/+page.svelte b/apps/web/src/routes/(dashboard)/+page.svelte
index 5607d01..fc48c00 100644
--- a/apps/web/src/routes/(dashboard)/+page.svelte
+++ b/apps/web/src/routes/(dashboard)/+page.svelte
@@ -6,7 +6,6 @@
import { resolve } from '$app/paths';
import { UserPlus, Mail, Clock, Award, TrendingUp, Zap, Users, Database } from 'lucide-svelte';
import ProtectedRoute from '$lib/components/ProtectedRoute.svelte';
- import { loginModalStore } from '$lib/stores/loginModal.svelte';
// Queries para dados do dashboard
const statsQuery = useQuery(api.dashboard.getStats, {});
@@ -36,7 +35,12 @@
// Se for erro de autenticação, abrir modal de login automaticamente
if (error === 'auth_required') {
- loginModalStore.open(route || to.url.pathname);
+ const redirectTo = route || to.url.pathname;
+ goto(`${resolve('/login')}?redirect=${encodeURIComponent(redirectTo)}`, {
+ replaceState: true,
+ noScroll: true
+ });
+ return;
}
// Limpar URL usando SvelteKit (após router estar inicializado)
@@ -65,7 +69,12 @@
const route = urlParams.get('route') || urlParams.get('redirect') || '';
if (error === 'auth_required') {
- loginModalStore.open(route || window.location.pathname);
+ const redirectTo = route || window.location.pathname;
+ goto(`${resolve('/login')}?redirect=${encodeURIComponent(redirectTo)}`, {
+ replaceState: true,
+ noScroll: true
+ });
+ return;
}
}
diff --git a/apps/web/src/routes/(public)/+layout.svelte b/apps/web/src/routes/(public)/+layout.svelte
new file mode 100644
index 0000000..b209967
--- /dev/null
+++ b/apps/web/src/routes/(public)/+layout.svelte
@@ -0,0 +1,22 @@
+
+
+
+
+
+
+ {@render children()}
+
+
+
+
+
+
+
diff --git a/apps/web/src/routes/(public)/home/+page.svelte b/apps/web/src/routes/(public)/home/+page.svelte
new file mode 100644
index 0000000..4f1d759
--- /dev/null
+++ b/apps/web/src/routes/(public)/home/+page.svelte
@@ -0,0 +1,134 @@
+
+
+
+ Home - SGSE
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Sistema de Gestão de Secretaria
+
+
+
+
+
+ Uma plataforma unificada para otimizar processos, conectar departamentos e garantir eficiência na administração pública.
+
+
+
+
+
+
+
+
+
+
+
+
Recursos Principais
+
+ Ferramentas desenvolvidas especificamente para atender às necessidades da gestão secretaria.
+
+
+
+
+ {#each [
+ {
+ icon: Zap,
+ title: 'Agilidade nos Processos',
+ description: 'Automatize tarefas repetitivas e reduza o tempo de tramitação de documentos.'
+ },
+ {
+ icon: ShieldCheck,
+ title: 'Segurança de Dados',
+ description: 'Proteção avançada para garantir a integridade e confidencialidade das informações.'
+ },
+ {
+ icon: Users,
+ title: 'Gestão de Pessoas',
+ description: 'Ferramentas integradas para acompanhamento e desenvolvimento dos servidores.'
+ },
+ {
+ icon: BarChart3,
+ title: 'Relatórios Inteligentes',
+ description: 'Dashboards interativos para tomada de decisão baseada em dados reais.'
+ },
+ {
+ icon: CheckCircle2,
+ title: 'Controle de Ativos',
+ description: 'Rastreamento completo de bens e recursos da secretaria.'
+ },
+ {
+ icon: Users,
+ title: 'Colaboração em Tempo Real',
+ description: 'Conecte equipes e facilite a comunicação interna entre departamentos.'
+ }
+ ] as feature}
+
+
+
+
+
+
{feature.title}
+
{feature.description}
+
+
+ {/each}
+
+
+
+
+
+
+
+
+
+
Pronto para começar?
+
+ Acesse o portal e tenha todo o controle da secretaria na palma da sua mão.
+
+
+ Fazer Login Agora
+
+
+
+
+
+
+
diff --git a/apps/web/src/routes/(public)/login/+page.server.ts b/apps/web/src/routes/(public)/login/+page.server.ts
new file mode 100644
index 0000000..6a7a227
--- /dev/null
+++ b/apps/web/src/routes/(public)/login/+page.server.ts
@@ -0,0 +1,24 @@
+import { createConvexHttpClient } from '@mmailaender/convex-better-auth-svelte/sveltekit';
+import { api } from '@sgse-app/backend/convex/_generated/api';
+import { redirect } from '@sveltejs/kit';
+import type { FunctionReference } from 'convex/server';
+
+export const load = async ({ locals, url }) => {
+ try {
+ const client = createConvexHttpClient({ token: locals.token });
+ const currentUser = await client.query(api.auth.getCurrentUser as FunctionReference<'query'>);
+
+ if (currentUser) {
+ const redirectTo = url.searchParams.get('redirect');
+ if (redirectTo && redirectTo.startsWith('/')) {
+ throw redirect(302, redirectTo);
+ }
+ throw redirect(302, '/');
+ }
+ } catch (error) {
+ // Se houver falha transitória na API/auth, ainda assim permitir renderizar a página de login.
+ console.error('Erro ao validar sessão na página de login:', error);
+ }
+
+ return {};
+};
diff --git a/apps/web/src/routes/(public)/login/+page.svelte b/apps/web/src/routes/(public)/login/+page.svelte
new file mode 100644
index 0000000..a00edc1
--- /dev/null
+++ b/apps/web/src/routes/(public)/login/+page.svelte
@@ -0,0 +1,312 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ Bem-vindo de volta
+
+
+ Entre com suas credenciais para acessar o sistema
+
+
+
+
+ {#if erroLogin}
+
+
+ {erroLogin}
+
+ {/if}
+
+
+
+
+
+
+
+ Precisa de ajuda?
+
+ Abrir um chamado
+
+
+
+
+
+
+
+
© {new Date().getFullYear()} Governo de Pernambuco. Todos os direitos reservados.
+
+
+
diff --git a/apps/web/src/routes/+layout.svelte b/apps/web/src/routes/+layout.svelte
index 3f33df5..a32e3e5 100644
--- a/apps/web/src/routes/+layout.svelte
+++ b/apps/web/src/routes/+layout.svelte
@@ -1,6 +1,5 @@
-
-
- {@render children()}
-
-
+{@render children()}
diff --git a/apps/web/src/routes/todos/+page.svelte b/apps/web/src/routes/todos/+page.svelte
deleted file mode 100644
index d06bb31..0000000
--- a/apps/web/src/routes/todos/+page.svelte
+++ /dev/null
@@ -1,153 +0,0 @@
-
-
-
-
Todos (Convex)
-
-
-
- {#if isLoadingTodos}
-
Loading...
- {:else if !hasTodos}
-
No todos yet.
- {:else}
-
- {/if}
-
- {#if todosQuery.error}
-
- Error loading: {todosQuery.error?.message ?? 'Unknown error'}
-
- {/if}
- {#if addError}
-
- Error adding: {addError.message ?? 'Unknown error'}
-
- {/if}
- {#if toggleError}
-
- Error updating: {toggleError.message ?? 'Unknown error'}
-
- {/if}
- {#if deleteError}
-
- Error deleting: {deleteError.message ?? 'Unknown error'}
-
- {/if}
-
diff --git a/bun.lock b/bun.lock
index d892394..3ea4adc 100644
--- a/bun.lock
+++ b/bun.lock
@@ -8,21 +8,22 @@
"@convex-dev/better-auth": "^0.9.7",
"@tanstack/svelte-form": "^1.23.8",
"chart.js": "^4.5.1",
+ "convex": "^1.31.0",
"lucide-svelte": "^0.552.0",
"prettier-plugin-svelte": "^3.4.0",
"svelte-chartjs": "^3.1.5",
- "svelte-sonner": "^1.0.5",
+ "svelte-sonner": "^1.0.7",
},
"devDependencies": {
"eslint": "^9.39.1",
- "eslint-plugin-svelte": "^3.13.0",
+ "eslint-plugin-svelte": "^3.13.1",
"globals": "^16.5.0",
"jiti": "^2.6.1",
- "prettier": "^3.6.2",
- "prettier-plugin-tailwindcss": "^0.7.1",
- "svelte-dnd-action": "^0.9.67",
+ "prettier": "^3.7.4",
+ "prettier-plugin-tailwindcss": "^0.7.2",
+ "svelte-dnd-action": "^0.9.68",
"turbo": "^2.6.3",
- "typescript-eslint": "^8.46.3",
+ "typescript-eslint": "^8.49.0",
},
},
"apps/web": {
@@ -130,7 +131,7 @@
},
"catalog": {
"@eslint/js": "^9.39.1",
- "better-auth": "1.3.27",
+ "better-auth": "1.3.34",
"convex": "^1.28.2",
"eslint": "^9.39.1",
"typescript": "^5.9.2",
@@ -200,13 +201,15 @@
"@babel/runtime": ["@babel/runtime@7.28.4", "", {}, "sha512-Q/N6JNWvIvPnLDvjlE1OUBLPQHH6l3CltCEsHIujp45zQUSSh8K+gHnaEX45yAT1nyngnINhvWtzN+Nb9D8RAQ=="],
- "@better-auth/core": ["@better-auth/core@1.3.27", "", { "dependencies": { "better-call": "1.0.19", "zod": "^4.1.5" } }, "sha512-3Sfdax6MQyronY+znx7bOsfQHI6m1SThvJWb0RDscFEAhfqLy95k1sl+/PgGyg0cwc2cUXoEiAOSqYdFYrg3vA=="],
+ "@better-auth/core": ["@better-auth/core@1.3.34", "", { "dependencies": { "zod": "^4.1.5" }, "peerDependencies": { "@better-auth/utils": "0.3.0", "@better-fetch/fetch": "1.1.18", "better-call": "1.0.19", "jose": "^6.1.0", "kysely": "^0.28.5", "nanostores": "^1.0.1" } }, "sha512-rt/Bgl0Xa8OQ2DUMKCZEJ8vL9kUw4NCJsBP9Sj9uRhbsK8NEMPiznUOFMkUY2FvrslvfKN7H/fivwyHz9c7HzQ=="],
+
+ "@better-auth/telemetry": ["@better-auth/telemetry@1.3.34", "", { "dependencies": { "@better-auth/core": "1.3.34", "@better-auth/utils": "0.3.0", "@better-fetch/fetch": "1.1.18" } }, "sha512-aQZ3wN90YMqV49diWxAMe1k7s2qb55KCsedCZne5PlgCjU4s3YtnqyjC5FEpzw2KY8l8rvR7DMAsDl13NjObKA=="],
"@better-auth/utils": ["@better-auth/utils@0.3.0", "", {}, "sha512-W+Adw6ZA6mgvnSnhOki270rwJ42t4XzSK6YWGF//BbVXL6SwCLWfyzBc1lN2m/4RM28KubdBKQ4X5VMoLRNPQw=="],
"@better-fetch/fetch": ["@better-fetch/fetch@1.1.18", "", {}, "sha512-rEFOE1MYIsBmoMJtQbl32PGHHXuG2hDxvEd7rUHE0vCBoFQVSDqaVs9hkZEtHCxRoY+CljXKFCOuJ8uxqw1LcA=="],
- "@convex-dev/better-auth": ["@convex-dev/better-auth@0.9.7", "", { "dependencies": { "common-tags": "^1.8.2", "convex-helpers": "^0.1.95", "jose": "^6.1.0", "remeda": "^2.32.0", "semver": "^7.7.3", "type-fest": "^4.39.1", "zod": "^3.24.4" }, "peerDependencies": { "better-auth": "1.3.27", "convex": ">=1.28.2 <1.35.0", "react": "^18.3.1 || ^19.0.0", "react-dom": "^18.3.1 || ^19.0.0" } }, "sha512-ni0oLM3IQho8KVBlMoyTk50IIbckhZmlEMxLgaVSixKmFJ4N/kGC6T91MjPTw3+bVLn/qHmIinLp7Dm+NRYzBw=="],
+ "@convex-dev/better-auth": ["@convex-dev/better-auth@0.9.11", "", { "dependencies": { "common-tags": "^1.8.2", "convex-helpers": "^0.1.95", "jose": "^6.1.0", "remeda": "^2.32.0", "semver": "^7.7.3", "type-fest": "^4.39.1", "zod": "^3.24.4" }, "peerDependencies": { "better-auth": "1.3.34", "convex": "^1.25.0", "react": "^18.3.1 || ^19.0.0", "react-dom": "^18.3.1 || ^19.0.0" } }, "sha512-SZHuh/rgLxDydAG8fRMm6H6SECGt9FfgRMPR6/k+cR8MKsksr0YWvPhAVpe7hAwuuXAachP+9SqG/YIwBVNUZA=="],
"@convex-dev/eslint-plugin": ["@convex-dev/eslint-plugin@1.0.0", "", { "dependencies": { "@typescript-eslint/utils": "~8.38.0" } }, "sha512-ublJRBKcLCioNaf1ylkCHD2KzAqWE2RIQ6DA/UgXAXQW5qg4vZSWY8wy+EK11yJkSSxcGfFXDWaE1+cHaWJvNA=="],
@@ -640,15 +643,15 @@
"@tailwindcss/vite": ["@tailwindcss/vite@4.1.16", "", { "dependencies": { "@tailwindcss/node": "4.1.16", "@tailwindcss/oxide": "4.1.16", "tailwindcss": "4.1.16" }, "peerDependencies": { "vite": "^5.2.0 || ^6 || ^7" } }, "sha512-bbguNBcDxsRmi9nnlWJxhfDWamY3lmcyACHcdO1crxfzuLpOhHLLtEIN/nCbbAtj5rchUgQD17QVAKi1f7IsKg=="],
- "@tanstack/devtools-event-client": ["@tanstack/devtools-event-client@0.3.4", "", {}, "sha512-eq+PpuutUyubXu+ycC1GIiVwBs86NF/8yYJJAKSpPcJLWl6R/761F1H4F/9ziX6zKezltFUH1ah3Cz8Ah+KJrw=="],
+ "@tanstack/devtools-event-client": ["@tanstack/devtools-event-client@0.3.5", "", {}, "sha512-RL1f5ZlfZMpghrCIdzl6mLOFLTuhqmPNblZgBaeKfdtk5rfbjykurv+VfYydOFXj0vxVIoA2d/zT7xfD7Ph8fw=="],
- "@tanstack/form-core": ["@tanstack/form-core@1.24.4", "", { "dependencies": { "@tanstack/devtools-event-client": "^0.3.3", "@tanstack/pacer": "^0.15.3", "@tanstack/store": "^0.7.7" } }, "sha512-+eIR7DiDamit1zvTVgaHxuIRA02YFgJaXMUGxsLRJoBpUjGl/g/nhUocQoNkRyfXqOlh8OCMTanjwDprWSRq6w=="],
+ "@tanstack/form-core": ["@tanstack/form-core@1.27.3", "", { "dependencies": { "@tanstack/devtools-event-client": "^0.3.5", "@tanstack/pacer-lite": "^0.1.1", "@tanstack/store": "^0.7.7" } }, "sha512-dFllZ1JEVmFVwvbXL+l1NWbj4X++FL+D9EK3Xksw7JA+V48wLHq7uzNHQy76al0M+ry0reLqfm65fgd8BWR7/Q=="],
- "@tanstack/pacer": ["@tanstack/pacer@0.15.4", "", { "dependencies": { "@tanstack/devtools-event-client": "^0.3.2", "@tanstack/store": "^0.7.5" } }, "sha512-vGY+CWsFZeac3dELgB6UZ4c7OacwsLb8hvL2gLS6hTgy8Fl0Bm/aLokHaeDIP+q9F9HUZTnp360z9uv78eg8pg=="],
+ "@tanstack/pacer-lite": ["@tanstack/pacer-lite@0.1.1", "", {}, "sha512-y/xtNPNt/YeyoVxE/JCx+T7yjEzpezmbb+toK8DDD1P4m7Kzs5YR956+7OKexG3f8aXgC3rLZl7b1V+yNUSy5w=="],
"@tanstack/store": ["@tanstack/store@0.7.7", "", {}, "sha512-xa6pTan1bcaqYDS9BDpSiS63qa6EoDkPN9RsRaxHuDdVDNntzq3xNwR5YKTU/V3SkSyC9T4YVOPh2zRQN0nhIQ=="],
- "@tanstack/svelte-form": ["@tanstack/svelte-form@1.23.8", "", { "dependencies": { "@tanstack/form-core": "1.24.4", "@tanstack/svelte-store": "^0.7.7" }, "peerDependencies": { "svelte": "^5.0.0" } }, "sha512-ZH17T/gOQ9sBpI/38zBCBiuceLsa9c9rOgwB7CRt/FBFunIkaG2gY02IiUBpjZfm1fiKBcTryaJGfR3XAtIH/g=="],
+ "@tanstack/svelte-form": ["@tanstack/svelte-form@1.27.3", "", { "dependencies": { "@tanstack/form-core": "1.27.3", "@tanstack/svelte-store": "^0.7.7" }, "peerDependencies": { "svelte": "^5.0.0" } }, "sha512-urJDvf1LA8HzbOFQAIRZLMToYnAc/mIg+Linn8FgVDZYg9PNlUM5Afb0JURpjE6mXNLXLmNyVs/p432pN03GOA=="],
"@tanstack/svelte-store": ["@tanstack/svelte-store@0.7.7", "", { "dependencies": { "@tanstack/store": "0.7.7" }, "peerDependencies": { "svelte": "^5.0.0" } }, "sha512-JeDyY7SxBi6EKzkf2wWoghdaC2bvmwNL9X/dgkx7LKEvJVle+te7tlELI3cqRNGbjXt9sx+97jx9M5dCCHcuog=="],
@@ -674,25 +677,25 @@
"@types/trusted-types": ["@types/trusted-types@2.0.7", "", {}, "sha512-ScaPdn1dQczgbl0QFTeTOmVHFULt394XJgOQNoyVhZ6r2vLnMLJfBPd53SB52T/3G36VI1/g2MZaX0cwDuXsfw=="],
- "@typescript-eslint/eslint-plugin": ["@typescript-eslint/eslint-plugin@8.46.3", "", { "dependencies": { "@eslint-community/regexpp": "^4.10.0", "@typescript-eslint/scope-manager": "8.46.3", "@typescript-eslint/type-utils": "8.46.3", "@typescript-eslint/utils": "8.46.3", "@typescript-eslint/visitor-keys": "8.46.3", "graphemer": "^1.4.0", "ignore": "^7.0.0", "natural-compare": "^1.4.0", "ts-api-utils": "^2.1.0" }, "peerDependencies": { "@typescript-eslint/parser": "^8.46.3", "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } }, "sha512-sbaQ27XBUopBkRiuY/P9sWGOWUW4rl8fDoHIUmLpZd8uldsTyB4/Zg6bWTegPoTLnKj9Hqgn3QD6cjPNB32Odw=="],
+ "@typescript-eslint/eslint-plugin": ["@typescript-eslint/eslint-plugin@8.49.0", "", { "dependencies": { "@eslint-community/regexpp": "^4.10.0", "@typescript-eslint/scope-manager": "8.49.0", "@typescript-eslint/type-utils": "8.49.0", "@typescript-eslint/utils": "8.49.0", "@typescript-eslint/visitor-keys": "8.49.0", "ignore": "^7.0.0", "natural-compare": "^1.4.0", "ts-api-utils": "^2.1.0" }, "peerDependencies": { "@typescript-eslint/parser": "^8.49.0", "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } }, "sha512-JXij0vzIaTtCwu6SxTh8qBc66kmf1xs7pI4UOiMDFVct6q86G0Zs7KRcEoJgY3Cav3x5Tq0MF5jwgpgLqgKG3A=="],
- "@typescript-eslint/parser": ["@typescript-eslint/parser@8.46.3", "", { "dependencies": { "@typescript-eslint/scope-manager": "8.46.3", "@typescript-eslint/types": "8.46.3", "@typescript-eslint/typescript-estree": "8.46.3", "@typescript-eslint/visitor-keys": "8.46.3", "debug": "^4.3.4" }, "peerDependencies": { "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } }, "sha512-6m1I5RmHBGTnUGS113G04DMu3CpSdxCAU/UvtjNWL4Nuf3MW9tQhiJqRlHzChIkhy6kZSAQmc+I1bcGjE3yNKg=="],
+ "@typescript-eslint/parser": ["@typescript-eslint/parser@8.49.0", "", { "dependencies": { "@typescript-eslint/scope-manager": "8.49.0", "@typescript-eslint/types": "8.49.0", "@typescript-eslint/typescript-estree": "8.49.0", "@typescript-eslint/visitor-keys": "8.49.0", "debug": "^4.3.4" }, "peerDependencies": { "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } }, "sha512-N9lBGA9o9aqb1hVMc9hzySbhKibHmB+N3IpoShyV6HyQYRGIhlrO5rQgttypi+yEeKsKI4idxC8Jw6gXKD4THA=="],
- "@typescript-eslint/project-service": ["@typescript-eslint/project-service@8.46.3", "", { "dependencies": { "@typescript-eslint/tsconfig-utils": "^8.46.3", "@typescript-eslint/types": "^8.46.3", "debug": "^4.3.4" }, "peerDependencies": { "typescript": ">=4.8.4 <6.0.0" } }, "sha512-Fz8yFXsp2wDFeUElO88S9n4w1I4CWDTXDqDr9gYvZgUpwXQqmZBr9+NTTql5R3J7+hrJZPdpiWaB9VNhAKYLuQ=="],
+ "@typescript-eslint/project-service": ["@typescript-eslint/project-service@8.49.0", "", { "dependencies": { "@typescript-eslint/tsconfig-utils": "^8.49.0", "@typescript-eslint/types": "^8.49.0", "debug": "^4.3.4" }, "peerDependencies": { "typescript": ">=4.8.4 <6.0.0" } }, "sha512-/wJN0/DKkmRUMXjZUXYZpD1NEQzQAAn9QWfGwo+Ai8gnzqH7tvqS7oNVdTjKqOcPyVIdZdyCMoqN66Ia789e7g=="],
- "@typescript-eslint/scope-manager": ["@typescript-eslint/scope-manager@8.46.3", "", { "dependencies": { "@typescript-eslint/types": "8.46.3", "@typescript-eslint/visitor-keys": "8.46.3" } }, "sha512-FCi7Y1zgrmxp3DfWfr+3m9ansUUFoy8dkEdeQSgA9gbm8DaHYvZCdkFRQrtKiedFf3Ha6VmoqoAaP68+i+22kg=="],
+ "@typescript-eslint/scope-manager": ["@typescript-eslint/scope-manager@8.49.0", "", { "dependencies": { "@typescript-eslint/types": "8.49.0", "@typescript-eslint/visitor-keys": "8.49.0" } }, "sha512-npgS3zi+/30KSOkXNs0LQXtsg9ekZ8OISAOLGWA/ZOEn0ZH74Ginfl7foziV8DT+D98WfQ5Kopwqb/PZOaIJGg=="],
- "@typescript-eslint/tsconfig-utils": ["@typescript-eslint/tsconfig-utils@8.46.3", "", { "peerDependencies": { "typescript": ">=4.8.4 <6.0.0" } }, "sha512-GLupljMniHNIROP0zE7nCcybptolcH8QZfXOpCfhQDAdwJ/ZTlcaBOYebSOZotpti/3HrHSw7D3PZm75gYFsOA=="],
+ "@typescript-eslint/tsconfig-utils": ["@typescript-eslint/tsconfig-utils@8.49.0", "", { "peerDependencies": { "typescript": ">=4.8.4 <6.0.0" } }, "sha512-8prixNi1/6nawsRYxet4YOhnbW+W9FK/bQPxsGB1D3ZrDzbJ5FXw5XmzxZv82X3B+ZccuSxo/X8q9nQ+mFecWA=="],
- "@typescript-eslint/type-utils": ["@typescript-eslint/type-utils@8.46.3", "", { "dependencies": { "@typescript-eslint/types": "8.46.3", "@typescript-eslint/typescript-estree": "8.46.3", "@typescript-eslint/utils": "8.46.3", "debug": "^4.3.4", "ts-api-utils": "^2.1.0" }, "peerDependencies": { "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } }, "sha512-ZPCADbr+qfz3aiTTYNNkCbUt+cjNwI/5McyANNrFBpVxPt7GqpEYz5ZfdwuFyGUnJ9FdDXbGODUu6iRCI6XRXw=="],
+ "@typescript-eslint/type-utils": ["@typescript-eslint/type-utils@8.49.0", "", { "dependencies": { "@typescript-eslint/types": "8.49.0", "@typescript-eslint/typescript-estree": "8.49.0", "@typescript-eslint/utils": "8.49.0", "debug": "^4.3.4", "ts-api-utils": "^2.1.0" }, "peerDependencies": { "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } }, "sha512-KTExJfQ+svY8I10P4HdxKzWsvtVnsuCifU5MvXrRwoP2KOlNZ9ADNEWWsQTJgMxLzS5VLQKDjkCT/YzgsnqmZg=="],
- "@typescript-eslint/types": ["@typescript-eslint/types@8.46.3", "", {}, "sha512-G7Ok9WN/ggW7e/tOf8TQYMaxgID3Iujn231hfi0Pc7ZheztIJVpO44ekY00b7akqc6nZcvregk0Jpah3kep6hA=="],
+ "@typescript-eslint/types": ["@typescript-eslint/types@8.49.0", "", {}, "sha512-e9k/fneezorUo6WShlQpMxXh8/8wfyc+biu6tnAqA81oWrEic0k21RHzP9uqqpyBBeBKu4T+Bsjy9/b8u7obXQ=="],
- "@typescript-eslint/typescript-estree": ["@typescript-eslint/typescript-estree@8.46.3", "", { "dependencies": { "@typescript-eslint/project-service": "8.46.3", "@typescript-eslint/tsconfig-utils": "8.46.3", "@typescript-eslint/types": "8.46.3", "@typescript-eslint/visitor-keys": "8.46.3", "debug": "^4.3.4", "fast-glob": "^3.3.2", "is-glob": "^4.0.3", "minimatch": "^9.0.4", "semver": "^7.6.0", "ts-api-utils": "^2.1.0" }, "peerDependencies": { "typescript": ">=4.8.4 <6.0.0" } }, "sha512-f/NvtRjOm80BtNM5OQtlaBdM5BRFUv7gf381j9wygDNL+qOYSNOgtQ/DCndiYi80iIOv76QqaTmp4fa9hwI0OA=="],
+ "@typescript-eslint/typescript-estree": ["@typescript-eslint/typescript-estree@8.49.0", "", { "dependencies": { "@typescript-eslint/project-service": "8.49.0", "@typescript-eslint/tsconfig-utils": "8.49.0", "@typescript-eslint/types": "8.49.0", "@typescript-eslint/visitor-keys": "8.49.0", "debug": "^4.3.4", "minimatch": "^9.0.4", "semver": "^7.6.0", "tinyglobby": "^0.2.15", "ts-api-utils": "^2.1.0" }, "peerDependencies": { "typescript": ">=4.8.4 <6.0.0" } }, "sha512-jrLdRuAbPfPIdYNppHJ/D0wN+wwNfJ32YTAm10eJVsFmrVpXQnDWBn8niCSMlWjvml8jsce5E/O+86IQtTbJWA=="],
- "@typescript-eslint/utils": ["@typescript-eslint/utils@8.46.3", "", { "dependencies": { "@eslint-community/eslint-utils": "^4.7.0", "@typescript-eslint/scope-manager": "8.46.3", "@typescript-eslint/types": "8.46.3", "@typescript-eslint/typescript-estree": "8.46.3" }, "peerDependencies": { "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } }, "sha512-VXw7qmdkucEx9WkmR3ld/u6VhRyKeiF1uxWwCy/iuNfokjJ7VhsgLSOTjsol8BunSw190zABzpwdNsze2Kpo4g=="],
+ "@typescript-eslint/utils": ["@typescript-eslint/utils@8.49.0", "", { "dependencies": { "@eslint-community/eslint-utils": "^4.7.0", "@typescript-eslint/scope-manager": "8.49.0", "@typescript-eslint/types": "8.49.0", "@typescript-eslint/typescript-estree": "8.49.0" }, "peerDependencies": { "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } }, "sha512-N3W7rJw7Rw+z1tRsHZbK395TWSYvufBXumYtEGzypgMUthlg0/hmCImeA8hgO2d2G4pd7ftpxxul2J8OdtdaFA=="],
- "@typescript-eslint/visitor-keys": ["@typescript-eslint/visitor-keys@8.46.3", "", { "dependencies": { "@typescript-eslint/types": "8.46.3", "eslint-visitor-keys": "^4.2.1" } }, "sha512-uk574k8IU0rOF/AjniX8qbLSGURJVUCeM5e4MIMKBFFi8weeiLrG1fyQejyLXQpRZbU/1BuQasleV/RfHC3hHg=="],
+ "@typescript-eslint/visitor-keys": ["@typescript-eslint/visitor-keys@8.49.0", "", { "dependencies": { "@typescript-eslint/types": "8.49.0", "eslint-visitor-keys": "^4.2.1" } }, "sha512-LlKaciDe3GmZFphXIc79THF/YYBugZ7FS1pO581E/edlVVNbZKDy93evqmrfQ9/Y4uN0vVhX4iuchq26mK/iiA=="],
"acorn": ["acorn@8.15.0", "", { "bin": { "acorn": "bin/acorn" } }, "sha512-NZyJarBfL7nWwIq+FDL6Zp/yHEhePMNnnJ0y3qfieCrmNvYct8uvtiV41UvlSe6apAfk0fY1FbWx+NwfmpvtTg=="],
@@ -748,7 +751,7 @@
"baseline-browser-mapping": ["baseline-browser-mapping@2.8.21", "", { "bin": { "baseline-browser-mapping": "dist/cli.js" } }, "sha512-JU0h5APyQNsHOlAM7HnQnPToSDQoEBZqzu/YBlqDnEeymPnZDREeXJA3KBMQee+dKteAxZ2AtvQEvVYdZf241Q=="],
- "better-auth": ["better-auth@1.3.27", "", { "dependencies": { "@better-auth/core": "1.3.27", "@better-auth/utils": "0.3.0", "@better-fetch/fetch": "1.1.18", "@noble/ciphers": "^2.0.0", "@noble/hashes": "^2.0.0", "@simplewebauthn/browser": "^13.1.2", "@simplewebauthn/server": "^13.1.2", "better-call": "1.0.19", "defu": "^6.1.4", "jose": "^6.1.0", "kysely": "^0.28.5", "nanostores": "^1.0.1", "zod": "^4.1.5" } }, "sha512-SwiGAJ7yU6dBhNg0NdV1h5M8T5sa7/AszZVc4vBfMDrLLmvUfbt9JoJ0uRUJUEdKRAAxTyl9yA+F3+GhtAD80w=="],
+ "better-auth": ["better-auth@1.3.34", "", { "dependencies": { "@better-auth/core": "1.3.34", "@better-auth/telemetry": "1.3.34", "@better-auth/utils": "0.3.0", "@better-fetch/fetch": "1.1.18", "@noble/ciphers": "^2.0.0", "@noble/hashes": "^2.0.0", "@simplewebauthn/browser": "^13.1.2", "@simplewebauthn/server": "^13.1.2", "better-call": "1.0.19", "defu": "^6.1.4", "jose": "^6.1.0", "kysely": "^0.28.5", "nanostores": "^1.0.1", "zod": "^4.1.5" } }, "sha512-LWA52SlvnUBJRbN8VLSTLILPomZY3zZAiLxVJCeSQ5uVmaIKkMBhERitkfJcXB9RJcfl4uP+3EqKkb6hX1/uiw=="],
"better-call": ["better-call@1.0.19", "", { "dependencies": { "@better-auth/utils": "^0.3.0", "@better-fetch/fetch": "^1.1.4", "rou3": "^0.5.1", "set-cookie-parser": "^2.7.1", "uncrypto": "^0.1.3" } }, "sha512-sI3GcA1SCVa3H+CDHl8W8qzhlrckwXOTKhqq3OOPXjgn5aTOMIqGY34zLY/pHA6tRRMjTUC3lz5Mi7EbDA24Kw=="],
@@ -814,7 +817,7 @@
"concat-map": ["concat-map@0.0.1", "", {}, "sha512-/Srv4dswyQNBfohGpz9o6Yb3Gz3SrUDqBH5rTuhGR7ahtlbYKnVxw2bCFMRljaA7EXHaXZ8wsHdodFvbkhKmqg=="],
- "convex": ["convex@1.29.0", "", { "dependencies": { "esbuild": "0.25.4", "prettier": "^3.0.0" }, "peerDependencies": { "@auth0/auth0-react": "^2.0.1", "@clerk/clerk-react": "^4.12.8 || ^5.0.0", "react": "^18.0.0 || ^19.0.0-0 || ^19.0.0" }, "optionalPeers": ["@auth0/auth0-react", "@clerk/clerk-react", "react"], "bin": { "convex": "bin/main.js" } }, "sha512-uoIPXRKIp2eLCkkR9WJ2vc9NtgQtx8Pml59WPUahwbrd5EuW2WLI/cf2E7XrUzOSifdQC3kJZepisk4wJNTJaA=="],
+ "convex": ["convex@1.31.0", "", { "dependencies": { "esbuild": "0.25.4", "prettier": "^3.0.0" }, "peerDependencies": { "@auth0/auth0-react": "^2.0.1", "@clerk/clerk-react": "^4.12.8 || ^5.0.0", "react": "^18.0.0 || ^19.0.0-0 || ^19.0.0" }, "optionalPeers": ["@auth0/auth0-react", "@clerk/clerk-react", "react"], "bin": { "convex": "bin/main.js" } }, "sha512-ht3dtpWQmxX62T8PT3p/5PDlRzSW5p2IDTP4exKjQ5dqmvhtn1wLFakJAX4CCeu1s0Ch0dKY5g2dk/wETTRAOw=="],
"convex-helpers": ["convex-helpers@0.1.104", "", { "peerDependencies": { "@standard-schema/spec": "^1.0.0", "convex": "^1.24.0", "hono": "^4.0.5", "react": "^17.0.2 || ^18.0.0 || ^19.0.0", "typescript": "^5.5", "zod": "^3.22.4 || ^4.0.15" }, "optionalPeers": ["@standard-schema/spec", "hono", "react", "typescript", "zod"], "bin": { "convex-helpers": "bin.cjs" } }, "sha512-7CYvx7T3K6n+McDTK4ZQaQNNGBzq5aWezpjzsKbOxPXx7oNcTP9wrpef3JxeXWFzkByJv5hRCjseh9B7eNJ7Ig=="],
@@ -914,7 +917,7 @@
"eslint-plugin-react-hooks": ["eslint-plugin-react-hooks@5.2.0", "", { "peerDependencies": { "eslint": "^3.0.0 || ^4.0.0 || ^5.0.0 || ^6.0.0 || ^7.0.0 || ^8.0.0-0 || ^9.0.0" } }, "sha512-+f15FfK64YQwZdJNELETdn5ibXEUQmW1DZL6KXhNnc2heoy/sg9VJJeT7n8TlMWouzWqSWavFkIhHyIbIAEapg=="],
- "eslint-plugin-svelte": ["eslint-plugin-svelte@3.13.0", "", { "dependencies": { "@eslint-community/eslint-utils": "^4.6.1", "@jridgewell/sourcemap-codec": "^1.5.0", "esutils": "^2.0.3", "globals": "^16.0.0", "known-css-properties": "^0.37.0", "postcss": "^8.4.49", "postcss-load-config": "^3.1.4", "postcss-safe-parser": "^7.0.0", "semver": "^7.6.3", "svelte-eslint-parser": "^1.4.0" }, "peerDependencies": { "eslint": "^8.57.1 || ^9.0.0", "svelte": "^3.37.0 || ^4.0.0 || ^5.0.0" }, "optionalPeers": ["svelte"] }, "sha512-2ohCCQJJTNbIpQCSDSTWj+FN0OVfPmSO03lmSNT7ytqMaWF6kpT86LdzDqtm4sh7TVPl/OEWJ/d7R87bXP2Vjg=="],
+ "eslint-plugin-svelte": ["eslint-plugin-svelte@3.13.1", "", { "dependencies": { "@eslint-community/eslint-utils": "^4.6.1", "@jridgewell/sourcemap-codec": "^1.5.0", "esutils": "^2.0.3", "globals": "^16.0.0", "known-css-properties": "^0.37.0", "postcss": "^8.4.49", "postcss-load-config": "^3.1.4", "postcss-safe-parser": "^7.0.0", "semver": "^7.6.3", "svelte-eslint-parser": "^1.4.0" }, "peerDependencies": { "eslint": "^8.57.1 || ^9.0.0", "svelte": "^3.37.0 || ^4.0.0 || ^5.0.0" }, "optionalPeers": ["svelte"] }, "sha512-Ng+kV/qGS8P/isbNYVE3sJORtubB+yLEcYICMkUWNaDTb0SwZni/JhAYXh/Dz/q2eThUwWY0VMPZ//KYD1n3eQ=="],
"eslint-plugin-turbo": ["eslint-plugin-turbo@2.6.0", "", { "dependencies": { "dotenv": "16.0.3" }, "peerDependencies": { "eslint": ">6.6.0", "turbo": ">2.0.0" } }, "sha512-04TohZhq6YQVXBZVRvrn8ZTj1sUQYZmjUWsfwgFAlaM5Kbk5Fdh5mLBKfhGGzekB55E+Ut9qNzAGh+JW4rjiuA=="],
@@ -1010,8 +1013,6 @@
"graceful-fs": ["graceful-fs@4.2.11", "", {}, "sha512-RbJ5/jmFcNNCcDV5o9eTnBLJ/HszWV0P73bc+Ff4nS/rJj+YaS6IGyiOL0VoBYX+l1Wrl3k63h/KrH+nhJ0XvQ=="],
- "graphemer": ["graphemer@1.4.0", "", {}, "sha512-EtKwoO6kxCL9WO5xipiHTZlSzBm7WLT627TqC/uVRd0HKmq8NXyebnNYxDoBi7wt8eTWrUrKXCOVaFq9x1kgag=="],
-
"has-bigints": ["has-bigints@1.1.0", "", {}, "sha512-R3pbpkcIqv2Pm3dUwgjclDRVmWpTJW2DcMzcIhEXEx1oh/CEMObMm3KLmRJOdvhM7o4uQBnwr8pzRK2sJWIqfg=="],
"has-flag": ["has-flag@4.0.0", "", {}, "sha512-EykJT/Q1KjTWctppgIAgfSO0tKVuZUjhgMr17kqTumMl6Afv3EISleU7qZUzoXDFTAHTDC4NOoG/ZxU3EvlMPQ=="],
@@ -1304,11 +1305,11 @@
"prelude-ls": ["prelude-ls@1.2.1", "", {}, "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g=="],
- "prettier": ["prettier@3.6.2", "", { "bin": { "prettier": "bin/prettier.cjs" } }, "sha512-I7AIg5boAr5R0FFtJ6rCfD+LFsWHp81dolrFD8S79U9tb8Az2nGrJncnMSnys+bpQJfRUzqs9hnA81OAA3hCuQ=="],
+ "prettier": ["prettier@3.7.4", "", { "bin": { "prettier": "bin/prettier.cjs" } }, "sha512-v6UNi1+3hSlVvv8fSaoUbggEM5VErKmmpGA7Pl3HF8V6uKY7rvClBOJlH6yNwQtfTueNkGVpOv/mtWL9L4bgRA=="],
"prettier-plugin-svelte": ["prettier-plugin-svelte@3.4.0", "", { "peerDependencies": { "prettier": "^3.0.0", "svelte": "^3.2.0 || ^4.0.0-next.0 || ^5.0.0-next.0" } }, "sha512-pn1ra/0mPObzqoIQn/vUTR3ZZI6UuZ0sHqMK5x2jMLGrs53h0sXhkVuDcrlssHwIMk7FYrMjHBPoUSyyEEDlBQ=="],
- "prettier-plugin-tailwindcss": ["prettier-plugin-tailwindcss@0.7.1", "", { "peerDependencies": { "@ianvs/prettier-plugin-sort-imports": "*", "@prettier/plugin-hermes": "*", "@prettier/plugin-oxc": "*", "@prettier/plugin-pug": "*", "@shopify/prettier-plugin-liquid": "*", "@trivago/prettier-plugin-sort-imports": "*", "@zackad/prettier-plugin-twig": "*", "prettier": "^3.0", "prettier-plugin-astro": "*", "prettier-plugin-css-order": "*", "prettier-plugin-jsdoc": "*", "prettier-plugin-marko": "*", "prettier-plugin-multiline-arrays": "*", "prettier-plugin-organize-attributes": "*", "prettier-plugin-organize-imports": "*", "prettier-plugin-sort-imports": "*", "prettier-plugin-svelte": "*" }, "optionalPeers": ["@ianvs/prettier-plugin-sort-imports", "@prettier/plugin-hermes", "@prettier/plugin-oxc", "@prettier/plugin-pug", "@shopify/prettier-plugin-liquid", "@trivago/prettier-plugin-sort-imports", "@zackad/prettier-plugin-twig", "prettier-plugin-astro", "prettier-plugin-css-order", "prettier-plugin-jsdoc", "prettier-plugin-marko", "prettier-plugin-multiline-arrays", "prettier-plugin-organize-attributes", "prettier-plugin-organize-imports", "prettier-plugin-sort-imports", "prettier-plugin-svelte"] }, "sha512-Bzv1LZcuiR1Sk02iJTS1QzlFNp/o5l2p3xkopwOrbPmtMeh3fK9rVW5M3neBQzHq+kGKj/4LGQMTNcTH4NGPtQ=="],
+ "prettier-plugin-tailwindcss": ["prettier-plugin-tailwindcss@0.7.2", "", { "peerDependencies": { "@ianvs/prettier-plugin-sort-imports": "*", "@prettier/plugin-hermes": "*", "@prettier/plugin-oxc": "*", "@prettier/plugin-pug": "*", "@shopify/prettier-plugin-liquid": "*", "@trivago/prettier-plugin-sort-imports": "*", "@zackad/prettier-plugin-twig": "*", "prettier": "^3.0", "prettier-plugin-astro": "*", "prettier-plugin-css-order": "*", "prettier-plugin-jsdoc": "*", "prettier-plugin-marko": "*", "prettier-plugin-multiline-arrays": "*", "prettier-plugin-organize-attributes": "*", "prettier-plugin-organize-imports": "*", "prettier-plugin-sort-imports": "*", "prettier-plugin-svelte": "*" }, "optionalPeers": ["@ianvs/prettier-plugin-sort-imports", "@prettier/plugin-hermes", "@prettier/plugin-oxc", "@prettier/plugin-pug", "@shopify/prettier-plugin-liquid", "@trivago/prettier-plugin-sort-imports", "@zackad/prettier-plugin-twig", "prettier-plugin-astro", "prettier-plugin-css-order", "prettier-plugin-jsdoc", "prettier-plugin-marko", "prettier-plugin-multiline-arrays", "prettier-plugin-organize-attributes", "prettier-plugin-organize-imports", "prettier-plugin-sort-imports", "prettier-plugin-svelte"] }, "sha512-LkphyK3Fw+q2HdMOoiEHWf93fNtYJwfamoKPl7UwtjFQdei/iIBoX11G6j706FzN3ymX9mPVi97qIY8328vdnA=="],
"printj": ["printj@1.1.2", "", { "bin": { "printj": "./bin/printj.njs" } }, "sha512-zA2SmoLaxZyArQTOPj5LXecR+RagfPSU5Kw1qP+jkWeNlrq+eJZyY2oS68SU1Z/7/myXM4lo9716laOFAVStCQ=="],
@@ -1444,11 +1445,11 @@
"svelte-check": ["svelte-check@4.3.3", "", { "dependencies": { "@jridgewell/trace-mapping": "^0.3.25", "chokidar": "^4.0.1", "fdir": "^6.2.0", "picocolors": "^1.0.0", "sade": "^1.7.4" }, "peerDependencies": { "svelte": "^4.0.0 || ^5.0.0-next.0", "typescript": ">=5.0.0" }, "bin": { "svelte-check": "bin/svelte-check" } }, "sha512-RYP0bEwenDXzfv0P1sKAwjZSlaRyqBn0Fz1TVni58lqyEiqgwztTpmodJrGzP6ZT2aHl4MbTvWP6gbmQ3FOnBg=="],
- "svelte-dnd-action": ["svelte-dnd-action@0.9.67", "", { "peerDependencies": { "svelte": ">=3.23.0 || ^5.0.0-next.0" } }, "sha512-yEJQZ9SFy3O4mnOdtjwWyotRsWRktNf4W8k67zgiLiMtMNQnwCyJHBjkGMgZMDh8EGZ4gr88l+GebBWoHDwo+g=="],
+ "svelte-dnd-action": ["svelte-dnd-action@0.9.68", "", { "peerDependencies": { "svelte": ">=3.23.0 || ^5.0.0-next.0" } }, "sha512-maFNIHwimGYbvIG8uOHsU9T/4+VKBIaAaFEGWYFIyo4f8qwUs0BIqwvBfHkaN+MXt8MBB9rByPTvF7fRx0eIjw=="],
"svelte-eslint-parser": ["svelte-eslint-parser@1.4.0", "", { "dependencies": { "eslint-scope": "^8.2.0", "eslint-visitor-keys": "^4.0.0", "espree": "^10.0.0", "postcss": "^8.4.49", "postcss-scss": "^4.0.9", "postcss-selector-parser": "^7.0.0" }, "peerDependencies": { "svelte": "^3.37.0 || ^4.0.0 || ^5.0.0" }, "optionalPeers": ["svelte"] }, "sha512-fjPzOfipR5S7gQ/JvI9r2H8y9gMGXO3JtmrylHLLyahEMquXI0lrebcjT+9/hNgDej0H7abTyox5HpHmW1PSWA=="],
- "svelte-sonner": ["svelte-sonner@1.0.5", "", { "dependencies": { "runed": "^0.28.0" }, "peerDependencies": { "svelte": "^5.0.0" } }, "sha512-9dpGPFqKb/QWudYqGnEz93vuY+NgCEvyNvxoCLMVGw6sDN/3oVeKV1xiEirW2E1N3vJEyj5imSBNOGltQHA7mg=="],
+ "svelte-sonner": ["svelte-sonner@1.0.7", "", { "dependencies": { "runed": "^0.28.0" }, "peerDependencies": { "svelte": "^5.0.0" } }, "sha512-1EUFYmd7q/xfs2qCHwJzGPh9n5VJ3X6QjBN10fof2vxgy8fYE7kVfZ7uGnd7i6fQaWIr5KvXcwYXE/cmTEjk5A=="],
"svg-pathdata": ["svg-pathdata@6.0.3", "", {}, "sha512-qsjeeq5YjBZ5eMdFuUa4ZosMLxgr5RZ+F+Y1OrDhuOCEInRMA3x74XdBtggJcj9kOeInz0WE+LgCPDkZFlBYJw=="],
@@ -1504,7 +1505,7 @@
"typescript": ["typescript@5.9.3", "", { "bin": { "tsc": "bin/tsc", "tsserver": "bin/tsserver" } }, "sha512-jl1vZzPDinLr9eUt3J/t7V6FgNEw9QjvBPdysz9KfQDD41fQrC2Y4vKQdiaUpFT4bXlb1RHhLpp8wtm6M5TgSw=="],
- "typescript-eslint": ["typescript-eslint@8.46.3", "", { "dependencies": { "@typescript-eslint/eslint-plugin": "8.46.3", "@typescript-eslint/parser": "8.46.3", "@typescript-eslint/typescript-estree": "8.46.3", "@typescript-eslint/utils": "8.46.3" }, "peerDependencies": { "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } }, "sha512-bAfgMavTuGo+8n6/QQDVQz4tZ4f7Soqg53RbrlZQEoAltYop/XR4RAts/I0BrO3TTClTSTFJ0wYbla+P8cEWJA=="],
+ "typescript-eslint": ["typescript-eslint@8.49.0", "", { "dependencies": { "@typescript-eslint/eslint-plugin": "8.49.0", "@typescript-eslint/parser": "8.49.0", "@typescript-eslint/typescript-estree": "8.49.0", "@typescript-eslint/utils": "8.49.0" }, "peerDependencies": { "eslint": "^8.57.0 || ^9.0.0", "typescript": ">=4.8.4 <6.0.0" } }, "sha512-zRSVH1WXD0uXczCXw+nsdjGPUdx4dfrs5VQoHnUWmv1U3oNlAKv4FUNdLDhVUg+gYn+a5hUESqch//Rv5wVhrg=="],
"unbox-primitive": ["unbox-primitive@1.1.0", "", { "dependencies": { "call-bound": "^1.0.3", "has-bigints": "^1.0.2", "has-symbols": "^1.1.0", "which-boxed-primitive": "^1.1.1" } }, "sha512-nWJ91DjeOkej/TA8pXQ3myruKpKEYgqvpw9lz4OPHj/NWFNluYrjbz9j01CJ8yKQd2g4jFoOkINCTW2I5LEEyw=="],
@@ -1602,8 +1603,6 @@
"@typescript-eslint/eslint-plugin/ignore": ["ignore@7.0.5", "", {}, "sha512-Hs59xBNfUIunMFgWAbGX5cq6893IbWg4KnrjbYwX3tx0ztorVgTDA6B2sxf8ejHJ4wz8BqGUMYlnzNBer5NvGg=="],
- "@typescript-eslint/typescript-estree/fast-glob": ["fast-glob@3.3.3", "", { "dependencies": { "@nodelib/fs.stat": "^2.0.2", "@nodelib/fs.walk": "^1.2.3", "glob-parent": "^5.1.2", "merge2": "^1.3.0", "micromatch": "^4.0.8" } }, "sha512-7MptL8U0cqcFdzIzwOTHoilX9x5BrNqye7Z/LuC7kCMRio1EMSyqRK3BEAUD7sXRq4iT4AzTVuZdhgQ2TCvYLg=="],
-
"@typescript-eslint/typescript-estree/minimatch": ["minimatch@9.0.5", "", { "dependencies": { "brace-expansion": "^2.0.1" } }, "sha512-G6T0ZX48xgozx7587koeX9Ys2NYy6Gmv//P89sEte9V9whIapMNF4idKxnW2QtCcLiTWlb/wfCabAtAFWhhBow=="],
"archiver-utils/readable-stream": ["readable-stream@2.3.8", "", { "dependencies": { "core-util-is": "~1.0.0", "inherits": "~2.0.3", "isarray": "~1.0.0", "process-nextick-args": "~2.0.0", "safe-buffer": "~5.1.1", "string_decoder": "~1.1.1", "util-deprecate": "~1.0.1" } }, "sha512-8p0AUk4XODgIewSi0l8Epjs+EVnWiK7NoDIEGU0HhE7+ZyY8D1IMY7odu5lRrFXGg71L15KG8QrPmum45RTtdA=="],
@@ -1654,8 +1653,6 @@
"@types/ssh2/@types/node/undici-types": ["undici-types@5.26.5", "", {}, "sha512-JlCMO+ehdEIKqlFxk6IfVoAUVmgz7cU7zD/h9XZ0qzeosSHmUJVOzSQvvYSYWXkFXC+IfLKSIffhv0sVZup6pA=="],
- "@typescript-eslint/typescript-estree/fast-glob/glob-parent": ["glob-parent@5.1.2", "", { "dependencies": { "is-glob": "^4.0.1" } }, "sha512-AOIgSQCepiJYwP3ARnGx+5VnTu2HBYdzbGP45eLw1vr3zB3vZLeyed1sC9hnbcOc9/SrMyM5RPQrkGz4aS9Zow=="],
-
"@typescript-eslint/typescript-estree/minimatch/brace-expansion": ["brace-expansion@2.0.2", "", { "dependencies": { "balanced-match": "^1.0.0" } }, "sha512-Jt0vHyM+jmUBqojB7E1NIYadt0vI0Qxjxd2TErW94wDz+E2LAm5vKMXXwg6ZZBTHPuUlDgQHKXvjGBdfcF1ZDQ=="],
"archiver-utils/readable-stream/isarray": ["isarray@1.0.0", "", {}, "sha512-VLghIWNM6ELQzo7zwmcg0NmTVyWKYjvIeM83yjp0wRDTmUnrM678fQbcKBo6n2CJEF0szoG//ytg+TKla89ALQ=="],
diff --git a/package.json b/package.json
index ec4e9c1..1cbe527 100644
--- a/package.json
+++ b/package.json
@@ -8,9 +8,9 @@
"packages/*"
],
"catalog": {
- "convex": "^1.28.2",
+ "convex": "^1.31.0",
"typescript": "^5.9.2",
- "better-auth": "1.3.27",
+ "better-auth": "1.3.34",
"eslint": "^9.39.1",
"@eslint/js": "^9.39.1"
}
@@ -29,23 +29,24 @@
},
"devDependencies": {
"eslint": "^9.39.1",
- "eslint-plugin-svelte": "^3.13.0",
+ "eslint-plugin-svelte": "^3.13.1",
"globals": "^16.5.0",
"jiti": "^2.6.1",
- "prettier": "^3.6.2",
- "prettier-plugin-tailwindcss": "^0.7.1",
- "svelte-dnd-action": "^0.9.67",
+ "prettier": "^3.7.4",
+ "prettier-plugin-tailwindcss": "^0.7.2",
+ "svelte-dnd-action": "^0.9.68",
"turbo": "^2.6.3",
- "typescript-eslint": "^8.46.3"
+ "typescript-eslint": "^8.49.0"
},
"dependencies": {
+ "@convex-dev/better-auth": "^0.9.7",
"@tanstack/svelte-form": "^1.23.8",
"chart.js": "^4.5.1",
+ "convex": "^1.31.0",
"lucide-svelte": "^0.552.0",
"prettier-plugin-svelte": "^3.4.0",
"svelte-chartjs": "^3.1.5",
- "svelte-sonner": "^1.0.5",
- "@convex-dev/better-auth": "^0.9.7"
+ "svelte-sonner": "^1.0.7"
},
"packageManager": "bun@1.3.0"
}
diff --git a/packages/backend/convex/_generated/api.d.ts b/packages/backend/convex/_generated/api.d.ts
index 255192f..1b5ac8d 100644
--- a/packages/backend/convex/_generated/api.d.ts
+++ b/packages/backend/convex/_generated/api.d.ts
@@ -352,10 +352,6 @@ export declare const components: {
lastRequest?: null | number;
};
model: "rateLimit";
- }
- | {
- data: { count: number; key: string; lastRequest: number };
- model: "ratelimit";
};
onCreateHandle?: string;
select?: Array;
@@ -733,32 +729,6 @@ export declare const components: {
| Array
| null;
}>;
- }
- | {
- model: "ratelimit";
- where?: Array<{
- connector?: "AND" | "OR";
- field: "key" | "count" | "lastRequest" | "_id";
- operator?:
- | "lt"
- | "lte"
- | "gt"
- | "gte"
- | "eq"
- | "in"
- | "not_in"
- | "ne"
- | "contains"
- | "starts_with"
- | "ends_with";
- value:
- | string
- | number
- | boolean
- | Array
- | Array
- | null;
- }>;
};
onDeleteHandle?: string;
paginationOpts: {
@@ -1143,32 +1113,6 @@ export declare const components: {
| Array
| null;
}>;
- }
- | {
- model: "ratelimit";
- where?: Array<{
- connector?: "AND" | "OR";
- field: "key" | "count" | "lastRequest" | "_id";
- operator?:
- | "lt"
- | "lte"
- | "gt"
- | "gte"
- | "eq"
- | "in"
- | "not_in"
- | "ne"
- | "contains"
- | "starts_with"
- | "ends_with";
- value:
- | string
- | number
- | boolean
- | Array
- | Array
- | null;
- }>;
};
onDeleteHandle?: string;
},
@@ -1190,8 +1134,7 @@ export declare const components: {
| "oauthAccessToken"
| "oauthConsent"
| "jwks"
- | "rateLimit"
- | "ratelimit";
+ | "rateLimit";
offset?: number;
paginationOpts: {
cursor: string | null;
@@ -1243,8 +1186,7 @@ export declare const components: {
| "oauthAccessToken"
| "oauthConsent"
| "jwks"
- | "rateLimit"
- | "ratelimit";
+ | "rateLimit";
select?: Array;
where?: Array<{
connector?: "AND" | "OR";
@@ -1753,33 +1695,6 @@ export declare const components: {
| Array
| null;
}>;
- }
- | {
- model: "ratelimit";
- update: { count?: number; key?: string; lastRequest?: number };
- where?: Array<{
- connector?: "AND" | "OR";
- field: "key" | "count" | "lastRequest" | "_id";
- operator?:
- | "lt"
- | "lte"
- | "gt"
- | "gte"
- | "eq"
- | "in"
- | "not_in"
- | "ne"
- | "contains"
- | "starts_with"
- | "ends_with";
- value:
- | string
- | number
- | boolean
- | Array
- | Array
- | null;
- }>;
};
onUpdateHandle?: string;
paginationOpts: {
@@ -2268,33 +2183,6 @@ export declare const components: {
| Array
| null;
}>;
- }
- | {
- model: "ratelimit";
- update: { count?: number; key?: string; lastRequest?: number };
- where?: Array<{
- connector?: "AND" | "OR";
- field: "key" | "count" | "lastRequest" | "_id";
- operator?:
- | "lt"
- | "lte"
- | "gt"
- | "gte"
- | "eq"
- | "in"
- | "not_in"
- | "ne"
- | "contains"
- | "starts_with"
- | "ends_with";
- value:
- | string
- | number
- | boolean
- | Array
- | Array
- | null;
- }>;
};
onUpdateHandle?: string;
},
diff --git a/packages/backend/convex/_generated/dataModel.d.ts b/packages/backend/convex/_generated/dataModel.d.ts
index 8541f31..f97fd19 100644
--- a/packages/backend/convex/_generated/dataModel.d.ts
+++ b/packages/backend/convex/_generated/dataModel.d.ts
@@ -38,7 +38,7 @@ export type Doc = DocumentByName<
* Convex documents are uniquely identified by their `Id`, which is accessible
* on the `_id` field. To learn more, see [Document IDs](https://docs.convex.dev/using/document-ids).
*
- * Documents can be loaded using `db.get(id)` in query and mutation functions.
+ * Documents can be loaded using `db.get(tableName, id)` in query and mutation functions.
*
* IDs are just strings at runtime, but this type can be used to distinguish them from other
* strings when type checking.
From 4f238022cf2c4b8526573902122305e1b15ff092 Mon Sep 17 00:00:00 2001
From: killer-cf
Date: Fri, 12 Dec 2025 16:05:28 -0300
Subject: [PATCH 2/8] feat: enhance layout and component structure for
dashboard, including responsive sidebar and header actions, and update footer
styling
---
apps/web/src/lib/components/Footer.svelte | 4 +-
apps/web/src/lib/components/Header.svelte | 49 +-
apps/web/src/lib/components/Sidebar.svelte | 537 +++---------------
.../dashboard/DashboardHeaderActions.svelte | 124 ++++
.../web/src/routes/(dashboard)/+layout.svelte | 99 +++-
apps/web/src/routes/(dashboard)/+page.svelte | 2 +-
6 files changed, 350 insertions(+), 465 deletions(-)
create mode 100644 apps/web/src/lib/components/dashboard/DashboardHeaderActions.svelte
diff --git a/apps/web/src/lib/components/Footer.svelte b/apps/web/src/lib/components/Footer.svelte
index 81e8d72..850978c 100644
--- a/apps/web/src/lib/components/Footer.svelte
+++ b/apps/web/src/lib/components/Footer.svelte
@@ -4,8 +4,8 @@
const currentYear = new Date().getFullYear();
-
-
+
+
SGSE
diff --git a/apps/web/src/lib/components/Header.svelte b/apps/web/src/lib/components/Header.svelte
index 1e3ec44..20ee848 100644
--- a/apps/web/src/lib/components/Header.svelte
+++ b/apps/web/src/lib/components/Header.svelte
@@ -1,20 +1,43 @@
-
-
-
-
-
- Governo de
-
-
-
+
diff --git a/apps/web/src/lib/components/Sidebar.svelte b/apps/web/src/lib/components/Sidebar.svelte
index deafcde..d040a3f 100644
--- a/apps/web/src/lib/components/Sidebar.svelte
+++ b/apps/web/src/lib/components/Sidebar.svelte
@@ -3,39 +3,19 @@
import { useQuery } from 'convex-svelte';
import type { FunctionReference } from 'convex/server';
import {
- Home,
- User,
- UserPlus,
- XCircle,
- Users,
- DollarSign,
+ ChevronDown,
ClipboardCheck,
FileText,
- ShoppingCart,
- Scale,
- Megaphone,
- Trophy,
- Briefcase,
- UserCog,
- Monitor,
- ChevronDown,
GitMerge,
+ Home,
Settings,
- Check,
- LogIn,
- Menu,
- Plus,
- Tag
+ Tag,
+ Users,
+ Briefcase,
+ UserPlus
} from 'lucide-svelte';
- import type { Snippet } from 'svelte';
- import { goto } from '$app/navigation';
import { resolve } from '$app/paths';
import { page } from '$app/state';
- import logo from '$lib/assets/logo_governo_PE.png';
- import { authClient } from '$lib/auth';
- import ChatWidget from '$lib/components/chat/ChatWidget.svelte';
- import NotificationBell from '$lib/components/chat/NotificationBell.svelte';
- import PresenceManager from '$lib/components/chat/PresenceManager.svelte';
interface MenuItemPermission {
recurso: string;
@@ -198,12 +178,13 @@
type IconType = typeof Home;
- const { children }: { children: Snippet } = $props();
+ type SidebarProps = {
+ onNavigate?: () => void;
+ };
+
+ const { onNavigate }: SidebarProps = $props();
let currentPath = $derived(page.url.pathname);
- let showAboutModal = $state(false);
-
- const currentUser = useQuery(api.auth.getCurrentUser as FunctionReference<'query'>, {});
const permissionsQuery = useQuery(api.menu.getUserPermissions as FunctionReference<'query'>, {});
// Filtrar menu baseado nas permissões do usuário
@@ -267,27 +248,14 @@
const iconMap: Record
= {
Home,
- User,
UserPlus,
- XCircle,
Users,
- DollarSign,
ClipboardCheck,
FileText,
- ShoppingCart,
- Scale,
- Megaphone,
- Trophy,
Briefcase,
- UserCog,
- Monitor,
ChevronDown,
GitMerge,
Settings,
- Check,
- LogIn,
- Menu,
- Plus,
Tag
};
@@ -330,419 +298,102 @@
function getSolicitarClasses(active: boolean) {
return getMenuClasses(active);
}
-
- // Função para obter a URL do avatar/foto do usuário
- let avatarUrlDoUsuario = $derived.by(() => {
- if (!currentUser.data) return null;
-
- // Prioridade: fotoPerfilUrl > avatar > fallback com nome
- if (currentUser.data.fotoPerfilUrl) {
- return currentUser.data.fotoPerfilUrl;
- }
-
- if (currentUser.data.avatar) {
- return currentUser.data.avatar;
- }
-
- // Fallback: retornar null para usar o ícone User do Lucide
- return null;
- });
-
- function goToLogin(redirectTo?: string) {
- const target = redirectTo || currentPath || '/';
- goto(`${resolve('/login')}?redirect=${encodeURIComponent(target)}`);
- }
-
- function openAboutModal() {
- showAboutModal = true;
- }
-
- function closeAboutModal() {
- showAboutModal = false;
- }
-
- async function handleLogout() {
- const result = await authClient.signOut();
- if (result.error) {
- console.error('Sign out error:', result.error);
- }
- // Resetar tema para padrão ao fazer logout
- const { aplicarTemaPadrao } = await import('$lib/utils/temas');
- aplicarTemaPadrao();
- goto(resolve('/'));
- }
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- SGSE
-
- Secretaria de Esportes
-
-
-
-
- {#if currentUser.data}
-
-
- {currentUser.data.nome}
- {currentUser.data.role?.nome}
-
+ {#snippet menuItem(item: MenuItem)}
+ {@const Icon = getIconComponent(item.icon)}
+ {@const isActive = isRouteActive(item.link, {
+ exact: item.link === '/',
+ excludePaths: item.excludePaths
+ })}
+ {@const hasSubmenus = item.submenus && item.submenus.length > 0}
-
-
-
-
- {#if avatarUrlDoUsuario}
-
- {:else}
-
-
-
- {/if}
-
-
-
-
-
-
- Meu Perfil
-
-
- Alterar Senha
-
-
-
- Sair
-
-
-
-
-
-
-
-
- {:else}
-
goToLogin()}
- >
- Entrar
-
- {/if}
-
-
-
-
-
-
-
-
- {@render children?.()}
-
-
-
-
-
-
-
-
-
-
-
-{#if showAboutModal}
-
-
-
- ✕
-
-
-
-
-
-
-
-
-
-
-
SGSE
-
- Sistema de Gerenciamento de Secretaria
-
-
-
-
-
-
-
-
-
+
+
+ {#if item.submenus}
+ {#each item.submenus as sub (sub.link)}
+ {@const isSubActive = isRouteActive(sub.link, {
+ excludePaths: sub.excludePaths,
+ exact: sub.exact
+ })}
+
+
+
+ {/each}
+ {/if}
+
+
+ {:else}
+
+
+
{item.label}
+
+ {/if}
+
+ {/snippet}
-
-
-
- Desenvolvido por
-
-
Secretaria de Esportes de Pernambuco
-
-
-
-
-
-
-
-
-
Governo
-
Estado de Pernambuco
-
-
-
-
-
-
-
-
- OK
-
-
+
- e.key === 'Escape' && closeAboutModal()}
- >
-
-{/if}
+ {:else}
+ {#each menuItems as item (item.link)}
+ {@render menuItem(item)}
+ {/each}
+ {/if}
+
-
-{#if currentUser.data}
-
-
-{/if}
+
+
diff --git a/apps/web/src/routes/(dashboard)/+page.svelte b/apps/web/src/routes/(dashboard)/+page.svelte
index fc48c00..1117734 100644
--- a/apps/web/src/routes/(dashboard)/+page.svelte
+++ b/apps/web/src/routes/(dashboard)/+page.svelte
@@ -140,7 +140,7 @@
-
+
{#if showAlert}
{@const alertData = getAlertMessage()}
From 13ec7cc8e3afae3ae26c3fe4abfe46461d726c16 Mon Sep 17 00:00:00 2001
From: killer-cf
Date: Fri, 12 Dec 2025 19:37:43 -0300
Subject: [PATCH 3/8] feat: improve sidebar behavior for responsive layout,
ensuring it opens by default on desktop and closes on mobile, with event
listener for screen size changes
---
apps/web/src/routes/(dashboard)/+layout.svelte | 17 ++++++++++++++---
1 file changed, 14 insertions(+), 3 deletions(-)
diff --git a/apps/web/src/routes/(dashboard)/+layout.svelte b/apps/web/src/routes/(dashboard)/+layout.svelte
index ed236da..68ea086 100644
--- a/apps/web/src/routes/(dashboard)/+layout.svelte
+++ b/apps/web/src/routes/(dashboard)/+layout.svelte
@@ -13,12 +13,23 @@
const { children } = $props();
let sidebarOpen = $state(false);
+ let isDesktop = $state(false);
const toggleSidebar = () => (sidebarOpen = !sidebarOpen);
const closeSidebar = () => (sidebarOpen = false);
// No desktop, abrir por padrão; no mobile, começar fechado
onMount(() => {
- sidebarOpen = window.matchMedia('(min-width: 1024px)').matches;
+ const mql = window.matchMedia('(min-width: 1024px)');
+
+ const update = () => {
+ isDesktop = mql.matches;
+ };
+
+ update();
+ sidebarOpen = mql.matches;
+
+ mql.addEventListener('change', update);
+ return () => mql.removeEventListener('change', update);
});
@@ -66,13 +77,13 @@
class:-translate-x-full={!sidebarOpen}
>
-
+ !isDesktop && closeSidebar()} />
-
-
-
-
-
- Novo Setor
-
-
+
+
+
+
+ Novo Setor
+
@@ -307,52 +304,48 @@
{formatDate(setor.createdAt)}
-
- openEditModal(setor)}
- aria-label="Editar setor {setor.nome}"
+ openEditModal(setor)}
+ aria-label="Editar setor {setor.nome}"
+ >
+
-
-
-
-
-
-
- openDeleteModal(setor)}
- aria-label="Excluir setor {setor.nome}"
+
+
+
+ openDeleteModal(setor)}
+ aria-label="Excluir setor {setor.nome}"
+ >
+
-
-
-
-
-
+
+
+
diff --git a/apps/web/src/routes/(dashboard)/controladoria/+page.server.ts b/apps/web/src/routes/(dashboard)/controladoria/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/controladoria/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/financeiro/+page.server.ts b/apps/web/src/routes/(dashboard)/financeiro/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/financeiro/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/fluxos/+page.server.ts b/apps/web/src/routes/(dashboard)/fluxos/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/fluxos/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/fluxos/+page.svelte b/apps/web/src/routes/(dashboard)/fluxos/+page.svelte
index 153a956..41b48a0 100644
--- a/apps/web/src/routes/(dashboard)/fluxos/+page.svelte
+++ b/apps/web/src/routes/(dashboard)/fluxos/+page.svelte
@@ -3,7 +3,6 @@
import type { Id } from '@sgse-app/backend/convex/_generated/dataModel';
import { useConvexClient, useQuery } from 'convex-svelte';
import { goto } from '$app/navigation';
- import ActionGuard from '$lib/components/ActionGuard.svelte';
const client = useConvexClient();
@@ -164,26 +163,24 @@
Arquivado
-
-
-
-
-
- Novo Template
-
-
+
+
+
+
+ Novo Template
+
diff --git a/apps/web/src/routes/(dashboard)/fluxos/[id]-fluxo/+page.server.ts b/apps/web/src/routes/(dashboard)/fluxos/[id]-fluxo/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/fluxos/[id]-fluxo/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/fluxos/[id]-fluxo/+page.svelte b/apps/web/src/routes/(dashboard)/fluxos/[id]-fluxo/+page.svelte
index 5ace5bf..a2a4d1e 100644
--- a/apps/web/src/routes/(dashboard)/fluxos/[id]-fluxo/+page.svelte
+++ b/apps/web/src/routes/(dashboard)/fluxos/[id]-fluxo/+page.svelte
@@ -4,7 +4,6 @@
import { useConvexClient, useQuery } from 'convex-svelte';
import { resolve } from '$app/paths';
import { page } from '$app/stores';
- import ActionGuard from '$lib/components/ActionGuard.svelte';
const client = useConvexClient();
let instanceId = $derived($page.params.id as Id<'flowInstances'>);
@@ -416,26 +415,24 @@
{#if instance.status === 'active'}
-
- (showCancelModal = true)}>
-
-
-
- Cancelar Fluxo
-
-
+
(showCancelModal = true)}>
+
+
+
+ Cancelar Fluxo
+
{/if}
@@ -616,67 +613,59 @@
{#if instance.status === 'active'}
{#if step.status === 'pending'}
-
- handleStartStep(step._id)}
- disabled={isProcessing}
- >
- Iniciar
-
-
+
handleStartStep(step._id)}
+ disabled={isProcessing}
+ >
+ Iniciar
+
{:else if step.status === 'in_progress'}
-
- handleCompleteStep(step._id)}
- disabled={isProcessing}
- >
- Concluir
-
- handleBlockStep(step._id)}
- disabled={isProcessing}
- >
- Bloquear
-
-
+
handleCompleteStep(step._id)}
+ disabled={isProcessing}
+ >
+ Concluir
+
+
handleBlockStep(step._id)}
+ disabled={isProcessing}
+ >
+ Bloquear
+
{:else if step.status === 'blocked'}
-
- handleStartStep(step._id)}
- disabled={isProcessing}
- >
- Desbloquear
-
-
+
handleStartStep(step._id)}
+ disabled={isProcessing}
+ >
+ Desbloquear
+
{/if}
-
- openReassignModal(step)}
- aria-label="Reatribuir responsável"
+ openReassignModal(step)}
+ aria-label="Reatribuir responsável"
+ >
+
-
-
-
-
-
+
+
+
-
- openUploadModal(step)}
- aria-label="Upload de documento"
+ openUploadModal(step)}
+ aria-label="Upload de documento"
+ >
+
-
-
-
-
-
+
+
+
{/if}
@@ -759,15 +746,13 @@
/>
{doc.name}
-
- handleDeleteDocument(doc._id)}
- aria-label="Excluir documento {doc.name}"
- >
- ×
-
-
+ handleDeleteDocument(doc._id)}
+ aria-label="Excluir documento {doc.name}"
+ >
+ ×
+
{/each}
diff --git a/apps/web/src/routes/(dashboard)/fluxos/[id]/editor/+page.server.ts b/apps/web/src/routes/(dashboard)/fluxos/[id]/editor/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/fluxos/[id]/editor/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/fluxos/instancias/+page.server.ts b/apps/web/src/routes/(dashboard)/fluxos/instancias/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/fluxos/instancias/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/fluxos/instancias/+page.svelte b/apps/web/src/routes/(dashboard)/fluxos/instancias/+page.svelte
index 30794f0..1d62555 100644
--- a/apps/web/src/routes/(dashboard)/fluxos/instancias/+page.svelte
+++ b/apps/web/src/routes/(dashboard)/fluxos/instancias/+page.svelte
@@ -3,7 +3,6 @@
import type { Id } from '@sgse-app/backend/convex/_generated/dataModel';
import { useConvexClient, useQuery } from 'convex-svelte';
import { goto } from '$app/navigation';
- import ActionGuard from '$lib/components/ActionGuard.svelte';
const client = useConvexClient();
@@ -148,26 +147,24 @@
Cancelado
-
-
-
-
-
- Nova Instância
-
-
+
+
+
+
+ Nova Instância
+
diff --git a/apps/web/src/routes/(dashboard)/gestao-pessoas/+page.server.ts b/apps/web/src/routes/(dashboard)/gestao-pessoas/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/gestao-pessoas/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/gestao-pessoas/gestao-ausencias/+page.server.ts b/apps/web/src/routes/(dashboard)/gestao-pessoas/gestao-ausencias/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/gestao-pessoas/gestao-ausencias/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/juridico/+page.server.ts b/apps/web/src/routes/(dashboard)/juridico/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/juridico/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/licitacoes/+page.server.ts b/apps/web/src/routes/(dashboard)/licitacoes/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/licitacoes/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/licitacoes/contratos/+page.server.ts b/apps/web/src/routes/(dashboard)/licitacoes/contratos/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/licitacoes/contratos/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/licitacoes/contratos/[id]/+page.server.ts b/apps/web/src/routes/(dashboard)/licitacoes/contratos/[id]/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/licitacoes/contratos/[id]/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/licitacoes/contratos/novo/+page.server.ts b/apps/web/src/routes/(dashboard)/licitacoes/contratos/novo/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/licitacoes/contratos/novo/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/licitacoes/empresas/+page.server.ts b/apps/web/src/routes/(dashboard)/licitacoes/empresas/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/licitacoes/empresas/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/licitacoes/fluxos/+page.svelte b/apps/web/src/routes/(dashboard)/licitacoes/fluxos/+page.svelte
index 29bc7d6..7f6341c 100644
--- a/apps/web/src/routes/(dashboard)/licitacoes/fluxos/+page.svelte
+++ b/apps/web/src/routes/(dashboard)/licitacoes/fluxos/+page.svelte
@@ -3,7 +3,6 @@
import type { Id } from '@sgse-app/backend/convex/_generated/dataModel';
import { useConvexClient, useQuery } from 'convex-svelte';
import { goto } from '$app/navigation';
- import ActionGuard from '$lib/components/ActionGuard.svelte';
const client = useConvexClient();
@@ -148,26 +147,24 @@
Cancelado
-
-
-
-
-
- Novo Fluxo
-
-
+
+
+
+
+ Novo Fluxo
+
diff --git a/apps/web/src/routes/(dashboard)/licitacoes/fluxos/[id]/+page.server.ts b/apps/web/src/routes/(dashboard)/licitacoes/fluxos/[id]/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/licitacoes/fluxos/[id]/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/licitacoes/fluxos/[id]/+page.svelte b/apps/web/src/routes/(dashboard)/licitacoes/fluxos/[id]/+page.svelte
index b5c5eeb..339982a 100644
--- a/apps/web/src/routes/(dashboard)/licitacoes/fluxos/[id]/+page.svelte
+++ b/apps/web/src/routes/(dashboard)/licitacoes/fluxos/[id]/+page.svelte
@@ -5,7 +5,6 @@
import { goto } from '$app/navigation';
import { resolve } from '$app/paths';
import { page } from '$app/stores';
- import ActionGuard from '$lib/components/ActionGuard.svelte';
import RelogioPrazo from '$lib/components/RelogioPrazo.svelte';
const client = useConvexClient();
@@ -651,26 +650,24 @@
{#if instance.status === 'active'}
-
- (showCancelModal = true)}>
-
-
-
- Cancelar Fluxo
-
-
+ (showCancelModal = true)}>
+
+
+
+ Cancelar Fluxo
+
{/if}
@@ -867,68 +864,60 @@
{#if instance.status === 'active'}
{#if step.status === 'pending'}
-
- handleStartStep(step._id)}
- disabled={isProcessing}
- >
- Iniciar
-
-
+
handleStartStep(step._id)}
+ disabled={isProcessing}
+ >
+ Iniciar
+
{:else if step.status === 'in_progress'}
-
- handleCompleteStep(step._id)}
- disabled={isProcessing}
- >
- Concluir
-
- handleBlockStep(step._id)}
- disabled={isProcessing}
- >
- Bloquear
-
-
+
handleCompleteStep(step._id)}
+ disabled={isProcessing}
+ >
+ Concluir
+
+
handleBlockStep(step._id)}
+ disabled={isProcessing}
+ >
+ Bloquear
+
{:else if step.status === 'blocked'}
-
- handleStartStep(step._id)}
- disabled={isProcessing}
- >
- Desbloquear
-
-
+
handleStartStep(step._id)}
+ disabled={isProcessing}
+ >
+ Desbloquear
+
{/if}
-
- openReassignModal(step)}
- aria-label="Reatribuir responsável"
- title="Reatribuir responsável"
+ openReassignModal(step)}
+ aria-label="Reatribuir responsável"
+ title="Reatribuir responsável"
+ >
+
-
-
-
-
-
+
+
+
{/if}
@@ -1104,30 +1093,28 @@
{/if}
{#if instance.status === 'active'}
-
- openUploadModal(step)}
- aria-label="Upload de documento"
+ openUploadModal(step)}
+ aria-label="Upload de documento"
+ >
+
-
-
-
- Enviar
-
-
+
+
+ Enviar
+
{/if}
@@ -1158,29 +1145,27 @@
{#if instance.status === 'active'}
-
- handleDeleteDocument(doc._id)}
- aria-label="Excluir documento {doc.name}"
+ handleDeleteDocument(doc._id)}
+ aria-label="Excluir documento {doc.name}"
+ >
+
-
-
-
-
-
+
+
+
{/if}
{/each}
diff --git a/apps/web/src/routes/(dashboard)/pedidos/+page.server.ts b/apps/web/src/routes/(dashboard)/pedidos/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/pedidos/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/pedidos/[id]/+page.server.ts b/apps/web/src/routes/(dashboard)/pedidos/[id]/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/pedidos/[id]/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/pedidos/aceite/+page.server.ts b/apps/web/src/routes/(dashboard)/pedidos/aceite/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/pedidos/aceite/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/pedidos/minhas-analises/+page.server.ts b/apps/web/src/routes/(dashboard)/pedidos/minhas-analises/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/pedidos/minhas-analises/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/pedidos/novo/+page.server.ts b/apps/web/src/routes/(dashboard)/pedidos/novo/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/pedidos/novo/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/perfil/+page.server.ts b/apps/web/src/routes/(dashboard)/perfil/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/perfil/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/perfil/chamados/+page.server.ts b/apps/web/src/routes/(dashboard)/perfil/chamados/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/perfil/chamados/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/perfil/privacidade/+page.server.ts b/apps/web/src/routes/(dashboard)/perfil/privacidade/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/perfil/privacidade/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/privacidade/meus-dados/+page.svelte b/apps/web/src/routes/(dashboard)/perfil/privacidade/meus-dados/+page.svelte
similarity index 100%
rename from apps/web/src/routes/(dashboard)/privacidade/meus-dados/+page.svelte
rename to apps/web/src/routes/(dashboard)/perfil/privacidade/meus-dados/+page.svelte
diff --git a/apps/web/src/routes/(dashboard)/programas-esportivos/+page.server.ts b/apps/web/src/routes/(dashboard)/programas-esportivos/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/programas-esportivos/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/programas-esportivos/acoes/+page.server.ts b/apps/web/src/routes/(dashboard)/programas-esportivos/acoes/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/programas-esportivos/acoes/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/atestados-licencas/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/atestados-licencas/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/atestados-licencas/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/ausencias/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/ausencias/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/ausencias/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/+page.server.ts
new file mode 100644
index 0000000..d5152b0
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/+page.server.ts
@@ -0,0 +1,4 @@
+export const load = async ({ parent }) => {
+ const { currentUser } = await parent();
+ console.log(currentUser);
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/banco-horas/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/banco-horas/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/banco-horas/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/dispensa/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/dispensa/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/dispensa/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/homologacao/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/homologacao/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/controle-ponto/homologacao/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/ferias/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/ferias/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/ferias/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/[funcionarioId]/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/[funcionarioId]/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/[funcionarioId]/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/cadastro/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/cadastro/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/cadastro/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/excluir/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/excluir/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/excluir/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/relatorios/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/relatorios/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/funcionarios/relatorios/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/simbolos/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/simbolos/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/simbolos/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/simbolos/[simboloId]/editar/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/simbolos/[simboloId]/editar/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/simbolos/[simboloId]/editar/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/recursos-humanos/simbolos/cadastro/+page.server.ts b/apps/web/src/routes/(dashboard)/recursos-humanos/simbolos/cadastro/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/recursos-humanos/simbolos/cadastro/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/secretaria-executiva/+page.server.ts b/apps/web/src/routes/(dashboard)/secretaria-executiva/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/secretaria-executiva/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/secretaria-executiva/gestao-ausencias/+page.server.ts b/apps/web/src/routes/(dashboard)/secretaria-executiva/gestao-ausencias/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/secretaria-executiva/gestao-ausencias/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/termo-consentimento/+page.server.ts b/apps/web/src/routes/(dashboard)/termo-consentimento/+page.server.ts
new file mode 100644
index 0000000..166f51d
--- /dev/null
+++ b/apps/web/src/routes/(dashboard)/termo-consentimento/+page.server.ts
@@ -0,0 +1,3 @@
+export const load = async ({ parent }) => {
+ await parent();
+};
diff --git a/apps/web/src/routes/(dashboard)/esqueci-senha/+page.svelte b/apps/web/src/routes/(public)/esqueci-senha/+page.svelte
similarity index 100%
rename from apps/web/src/routes/(dashboard)/esqueci-senha/+page.svelte
rename to apps/web/src/routes/(public)/esqueci-senha/+page.svelte
diff --git a/apps/web/src/routes/(public)/login/+page.svelte b/apps/web/src/routes/(public)/login/+page.svelte
index a00edc1..2aabd1b 100644
--- a/apps/web/src/routes/(public)/login/+page.svelte
+++ b/apps/web/src/routes/(public)/login/+page.svelte
@@ -63,7 +63,6 @@
}
const gpsPromise = coletarGPS();
-
const result = await authClient.signIn.email(
{ email: matricula.trim(), password: senha },
{
@@ -158,7 +157,7 @@
}
})();
- await goto(resolve(redirectAfterLogin as any), { replaceState: true });
+ await goto(resolve(redirectAfterLogin as string), { replaceState: true });
} else {
erroLogin = result.error?.message || 'Erro ao fazer login';
}
diff --git a/apps/web/src/routes/(dashboard)/privacidade/+page.svelte b/apps/web/src/routes/(public)/privacidade/+page.svelte
similarity index 93%
rename from apps/web/src/routes/(dashboard)/privacidade/+page.svelte
rename to apps/web/src/routes/(public)/privacidade/+page.svelte
index a905b4b..aef4f9a 100644
--- a/apps/web/src/routes/(dashboard)/privacidade/+page.svelte
+++ b/apps/web/src/routes/(public)/privacidade/+page.svelte
@@ -3,6 +3,10 @@
import { Shield, FileText, Mail, Phone, Calendar } from 'lucide-svelte';
import { useQuery } from 'convex-svelte';
import { api } from '@sgse-app/backend/convex/_generated/api';
+ import { useAuth } from '@mmailaender/convex-better-auth-svelte/svelte';
+
+ const auth = useAuth();
+ const isAuthenticated = $derived(auth.isAuthenticated);
const configLGPD = useQuery(api.lgpd.obterConfiguracaoLGPD, {});
@@ -66,7 +70,7 @@
-
+
Dados de Identificação
@@ -76,7 +80,7 @@
-
+
Dados de Contato
@@ -85,7 +89,7 @@
-
+
Dados Profissionais
@@ -95,7 +99,7 @@
-
+
Dados de Saúde
@@ -105,7 +109,7 @@
-
+
Dados de Acesso
@@ -346,15 +350,17 @@
-
+ {#if isAuthenticated}
+
+ {/if}
@@ -420,15 +426,17 @@
-
+ {#if isAuthenticated}
+
+ {/if}
From 9e45a43910588384b02d60d840b1f903b92b4dc0 Mon Sep 17 00:00:00 2001
From: killer-cf
Date: Sat, 13 Dec 2025 17:09:15 -0300
Subject: [PATCH 5/8] feat: add theme selection functionality and update theme
management in the application, including new themes and improved persistence
handling
---
apps/web/package.json | 1 +
apps/web/src/app.css | 686 ++++++++++------------
apps/web/src/app.html | 13 +-
apps/web/src/lib/components/Header.svelte | 17 +
apps/web/src/lib/utils/temas.ts | 34 +-
apps/web/src/routes/+layout.svelte | 45 ++
bun.lock | 5 +-
package.json | 2 +-
8 files changed, 407 insertions(+), 396 deletions(-)
diff --git a/apps/web/package.json b/apps/web/package.json
index 49ad8c6..d5cf103 100644
--- a/apps/web/package.json
+++ b/apps/web/package.json
@@ -60,6 +60,7 @@
"marked": "^17.0.1",
"papaparse": "^5.4.1",
"svelte-sonner": "^1.0.5",
+ "theme-change": "^2.5.0",
"xlsx": "^0.18.5",
"xlsx-js-style": "^1.2.0",
"zod": "^4.1.12"
diff --git a/apps/web/src/app.css b/apps/web/src/app.css
index 9622199..494c37c 100644
--- a/apps/web/src/app.css
+++ b/apps/web/src/app.css
@@ -21,405 +21,345 @@
@apply border-error bg-base-100 hover:bg-error/60 active:bg-error text-error flex items-center justify-center gap-2 rounded-xl border px-4 py-2 text-center font-medium transition-colors hover:text-white active:text-white;
}
-/* Tema Aqua (padrão roxo/azul) - customizado para garantir funcionamento */
-html[data-theme='aqua'],
-html[data-theme='aqua'] body,
-[data-theme='aqua'] {
+/* Tema Aqua (padrão roxo/azul) - redefinido como custom para garantir compatibilidade */
+@plugin 'daisyui/theme' {
+ name: 'aqua';
+ default: true;
color-scheme: light;
- --p: 217 91% 60%;
- --pf: 217 91% 50%;
- --pc: 0 0% 100%;
- --s: 217 91% 60%;
- --sf: 217 91% 50%;
- --sc: 0 0% 100%;
- --a: 217 91% 60%;
- --af: 217 91% 50%;
- --ac: 0 0% 100%;
- --n: 217 20% 17%;
- --nf: 217 20% 10%;
- --nc: 0 0% 100%;
- --b1: 0 0% 100%;
- --b2: 217 20% 95%;
- --b3: 217 20% 90%;
- --bc: 217 20% 17%;
- --in: 217 91% 60%;
- --inc: 0 0% 100%;
- --su: 142 76% 36%;
- --suc: 0 0% 100%;
- --wa: 38 92% 50%;
- --wac: 0 0% 100%;
- --er: 0 84% 60%;
- --erc: 0 0% 100%;
- --rounded-box: 1rem;
- --rounded-btn: 0.5rem;
- --rounded-badge: 1.9rem;
- --animation-btn: 0.25s;
- --animation-input: 0.2s;
- --btn-focus-scale: 0.95;
- --border-btn: 1px;
- --tab-border: 1px;
- --tab-radius: 0.5rem;
+ --color-primary: hsl(217 91% 60%);
+ --color-primary-content: hsl(0 0% 100%);
+ --color-secondary: hsl(217 91% 60%);
+ --color-secondary-content: hsl(0 0% 100%);
+ --color-accent: hsl(217 91% 60%);
+ --color-accent-content: hsl(0 0% 100%);
+ --color-neutral: hsl(217 20% 17%);
+ --color-neutral-content: hsl(0 0% 100%);
+ --color-base-100: hsl(0 0% 100%);
+ --color-base-200: hsl(217 20% 95%);
+ --color-base-300: hsl(217 20% 90%);
+ --color-base-content: hsl(217 20% 17%);
+ --color-info: hsl(217 91% 60%);
+ --color-info-content: hsl(0 0% 100%);
+ --color-success: hsl(142 76% 36%);
+ --color-success-content: hsl(0 0% 100%);
+ --color-warning: hsl(38 92% 50%);
+ --color-warning-content: hsl(0 0% 100%);
+ --color-error: hsl(0 84% 60%);
+ --color-error-content: hsl(0 0% 100%);
+ --radius-selector: 0.5rem;
+ --radius-field: 0.5rem;
+ --radius-box: 1rem;
+ --size-selector: 0.25rem;
+ --size-field: 0.25rem;
+ --border: 1px;
+ --depth: 1;
+ --noise: 0;
}
-/* Temas customizados para SGSE - Azul */
-html[data-theme='sgse-blue'],
-html[data-theme='sgse-blue'] body,
-[data-theme='sgse-blue'] {
+/* Temas customizados para SGSE */
+
+/* Azul */
+@plugin 'daisyui/theme' {
+ name: 'sgse-blue';
color-scheme: light;
- --p: 217 91% 60%;
- --pf: 217 91% 50%;
- --pc: 0 0% 100%;
- --s: 217 91% 60%;
- --sf: 217 91% 50%;
- --sc: 0 0% 100%;
- --a: 217 91% 60%;
- --af: 217 91% 50%;
- --ac: 0 0% 100%;
- --n: 217 20% 17%;
- --nf: 217 20% 10%;
- --nc: 0 0% 100%;
- --b1: 0 0% 100%;
- --b2: 217 20% 95%;
- --b3: 217 20% 90%;
- --bc: 217 20% 17%;
- --in: 217 91% 60%;
- --inc: 0 0% 100%;
- --su: 142 76% 36%;
- --suc: 0 0% 100%;
- --wa: 38 92% 50%;
- --wac: 0 0% 100%;
- --er: 0 84% 60%;
- --erc: 0 0% 100%;
- --rounded-box: 1rem;
- --rounded-btn: 0.5rem;
- --rounded-badge: 1.9rem;
- --animation-btn: 0.25s;
- --animation-input: 0.2s;
- --btn-focus-scale: 0.95;
- --border-btn: 1px;
- --tab-border: 1px;
- --tab-radius: 0.5rem;
+ --color-primary: hsl(217 91% 60%);
+ --color-primary-content: hsl(0 0% 100%);
+ --color-secondary: hsl(217 91% 60%);
+ --color-secondary-content: hsl(0 0% 100%);
+ --color-accent: hsl(217 91% 60%);
+ --color-accent-content: hsl(0 0% 100%);
+ --color-neutral: hsl(217 20% 17%);
+ --color-neutral-content: hsl(0 0% 100%);
+ --color-base-100: hsl(0 0% 100%);
+ --color-base-200: hsl(217 20% 95%);
+ --color-base-300: hsl(217 20% 90%);
+ --color-base-content: hsl(217 20% 17%);
+ --color-info: hsl(217 91% 60%);
+ --color-info-content: hsl(0 0% 100%);
+ --color-success: hsl(142 76% 36%);
+ --color-success-content: hsl(0 0% 100%);
+ --color-warning: hsl(38 92% 50%);
+ --color-warning-content: hsl(0 0% 100%);
+ --color-error: hsl(0 84% 60%);
+ --color-error-content: hsl(0 0% 100%);
+ --radius-selector: 0.5rem;
+ --radius-field: 0.5rem;
+ --radius-box: 1rem;
+ --size-selector: 0.25rem;
+ --size-field: 0.25rem;
+ --border: 1px;
+ --depth: 1;
+ --noise: 0;
}
-/* Garantir que todas as variáveis CSS sejam aplicadas em todos os elementos */
-html[data-theme] {
- color-scheme: var(--color-scheme, light);
-}
-
-html[data-theme] * {
- color-scheme: inherit;
-}
-
-html[data-theme='sgse-green'],
-html[data-theme='sgse-green'] body,
-[data-theme='sgse-green'] {
+/* Verde */
+@plugin 'daisyui/theme' {
+ name: 'sgse-green';
color-scheme: light;
- --p: 142 76% 36%;
- --pf: 142 76% 26%;
- --pc: 0 0% 100%;
- --s: 142 76% 36%;
- --sf: 142 76% 26%;
- --sc: 0 0% 100%;
- --a: 142 76% 36%;
- --af: 142 76% 26%;
- --ac: 0 0% 100%;
- --n: 142 20% 17%;
- --nf: 142 20% 10%;
- --nc: 0 0% 100%;
- --b1: 0 0% 100%;
- --b2: 142 20% 95%;
- --b3: 142 20% 90%;
- --bc: 142 20% 17%;
- --in: 142 76% 36%;
- --inc: 0 0% 100%;
- --su: 142 76% 36%;
- --suc: 0 0% 100%;
- --wa: 38 92% 50%;
- --wac: 0 0% 100%;
- --er: 0 84% 60%;
- --erc: 0 0% 100%;
- --rounded-box: 1rem;
- --rounded-btn: 0.5rem;
- --rounded-badge: 1.9rem;
- --animation-btn: 0.25s;
- --animation-input: 0.2s;
- --btn-focus-scale: 0.95;
- --border-btn: 1px;
- --tab-border: 1px;
- --tab-radius: 0.5rem;
+ --color-primary: hsl(142 76% 36%);
+ --color-primary-content: hsl(0 0% 100%);
+ --color-secondary: hsl(142 76% 36%);
+ --color-secondary-content: hsl(0 0% 100%);
+ --color-accent: hsl(142 76% 36%);
+ --color-accent-content: hsl(0 0% 100%);
+ --color-neutral: hsl(142 20% 17%);
+ --color-neutral-content: hsl(0 0% 100%);
+ --color-base-100: hsl(0 0% 100%);
+ --color-base-200: hsl(142 20% 95%);
+ --color-base-300: hsl(142 20% 90%);
+ --color-base-content: hsl(142 20% 17%);
+ --color-info: hsl(142 76% 36%);
+ --color-info-content: hsl(0 0% 100%);
+ --color-success: hsl(142 76% 36%);
+ --color-success-content: hsl(0 0% 100%);
+ --color-warning: hsl(38 92% 50%);
+ --color-warning-content: hsl(0 0% 100%);
+ --color-error: hsl(0 84% 60%);
+ --color-error-content: hsl(0 0% 100%);
+ --radius-selector: 0.5rem;
+ --radius-field: 0.5rem;
+ --radius-box: 1rem;
+ --size-selector: 0.25rem;
+ --size-field: 0.25rem;
+ --border: 1px;
+ --depth: 1;
+ --noise: 0;
}
-html[data-theme='sgse-orange'],
-html[data-theme='sgse-orange'] body,
-[data-theme='sgse-orange'] {
+/* Laranja */
+@plugin 'daisyui/theme' {
+ name: 'sgse-orange';
color-scheme: light;
- --p: 25 95% 53%;
- --pf: 25 95% 43%;
- --pc: 0 0% 100%;
- --s: 25 95% 53%;
- --sf: 25 95% 43%;
- --sc: 0 0% 100%;
- --a: 25 95% 53%;
- --af: 25 95% 43%;
- --ac: 0 0% 100%;
- --n: 25 20% 17%;
- --nf: 25 20% 10%;
- --nc: 0 0% 100%;
- --b1: 0 0% 100%;
- --b2: 25 20% 95%;
- --b3: 25 20% 90%;
- --bc: 25 20% 17%;
- --in: 25 95% 53%;
- --inc: 0 0% 100%;
- --su: 142 76% 36%;
- --suc: 0 0% 100%;
- --wa: 38 92% 50%;
- --wac: 0 0% 100%;
- --er: 0 84% 60%;
- --erc: 0 0% 100%;
- --rounded-box: 1rem;
- --rounded-btn: 0.5rem;
- --rounded-badge: 1.9rem;
- --animation-btn: 0.25s;
- --animation-input: 0.2s;
- --btn-focus-scale: 0.95;
- --border-btn: 1px;
- --tab-border: 1px;
- --tab-radius: 0.5rem;
+ --color-primary: hsl(25 95% 53%);
+ --color-primary-content: hsl(0 0% 100%);
+ --color-secondary: hsl(25 95% 53%);
+ --color-secondary-content: hsl(0 0% 100%);
+ --color-accent: hsl(25 95% 53%);
+ --color-accent-content: hsl(0 0% 100%);
+ --color-neutral: hsl(25 20% 17%);
+ --color-neutral-content: hsl(0 0% 100%);
+ --color-base-100: hsl(0 0% 100%);
+ --color-base-200: hsl(25 20% 95%);
+ --color-base-300: hsl(25 20% 90%);
+ --color-base-content: hsl(25 20% 17%);
+ --color-info: hsl(25 95% 53%);
+ --color-info-content: hsl(0 0% 100%);
+ --color-success: hsl(142 76% 36%);
+ --color-success-content: hsl(0 0% 100%);
+ --color-warning: hsl(38 92% 50%);
+ --color-warning-content: hsl(0 0% 100%);
+ --color-error: hsl(0 84% 60%);
+ --color-error-content: hsl(0 0% 100%);
+ --radius-selector: 0.5rem;
+ --radius-field: 0.5rem;
+ --radius-box: 1rem;
+ --size-selector: 0.25rem;
+ --size-field: 0.25rem;
+ --border: 1px;
+ --depth: 1;
+ --noise: 0;
}
-html[data-theme='sgse-red'],
-html[data-theme='sgse-red'] body,
-[data-theme='sgse-red'] {
+/* Vermelho */
+@plugin 'daisyui/theme' {
+ name: 'sgse-red';
color-scheme: light;
- --p: 0 84% 60%;
- --pf: 0 84% 50%;
- --pc: 0 0% 100%;
- --s: 0 84% 60%;
- --sf: 0 84% 50%;
- --sc: 0 0% 100%;
- --a: 0 84% 60%;
- --af: 0 84% 50%;
- --ac: 0 0% 100%;
- --n: 0 20% 17%;
- --nf: 0 20% 10%;
- --nc: 0 0% 100%;
- --b1: 0 0% 100%;
- --b2: 0 20% 95%;
- --b3: 0 20% 90%;
- --bc: 0 20% 17%;
- --in: 0 84% 60%;
- --inc: 0 0% 100%;
- --su: 142 76% 36%;
- --suc: 0 0% 100%;
- --wa: 38 92% 50%;
- --wac: 0 0% 100%;
- --er: 0 84% 60%;
- --erc: 0 0% 100%;
- --rounded-box: 1rem;
- --rounded-btn: 0.5rem;
- --rounded-badge: 1.9rem;
- --animation-btn: 0.25s;
- --animation-input: 0.2s;
- --btn-focus-scale: 0.95;
- --border-btn: 1px;
- --tab-border: 1px;
- --tab-radius: 0.5rem;
+ --color-primary: hsl(0 84% 60%);
+ --color-primary-content: hsl(0 0% 100%);
+ --color-secondary: hsl(0 84% 60%);
+ --color-secondary-content: hsl(0 0% 100%);
+ --color-accent: hsl(0 84% 60%);
+ --color-accent-content: hsl(0 0% 100%);
+ --color-neutral: hsl(0 20% 17%);
+ --color-neutral-content: hsl(0 0% 100%);
+ --color-base-100: hsl(0 0% 100%);
+ --color-base-200: hsl(0 20% 95%);
+ --color-base-300: hsl(0 20% 90%);
+ --color-base-content: hsl(0 20% 17%);
+ --color-info: hsl(0 84% 60%);
+ --color-info-content: hsl(0 0% 100%);
+ --color-success: hsl(142 76% 36%);
+ --color-success-content: hsl(0 0% 100%);
+ --color-warning: hsl(38 92% 50%);
+ --color-warning-content: hsl(0 0% 100%);
+ --color-error: hsl(0 84% 60%);
+ --color-error-content: hsl(0 0% 100%);
+ --radius-selector: 0.5rem;
+ --radius-field: 0.5rem;
+ --radius-box: 1rem;
+ --size-selector: 0.25rem;
+ --size-field: 0.25rem;
+ --border: 1px;
+ --depth: 1;
+ --noise: 0;
}
-html[data-theme='sgse-pink'],
-html[data-theme='sgse-pink'] body,
-[data-theme='sgse-pink'] {
+/* Rosa */
+@plugin 'daisyui/theme' {
+ name: 'sgse-pink';
color-scheme: light;
- --p: 330 81% 60%;
- --pf: 330 81% 50%;
- --pc: 0 0% 100%;
- --s: 330 81% 60%;
- --sf: 330 81% 50%;
- --sc: 0 0% 100%;
- --a: 330 81% 60%;
- --af: 330 81% 50%;
- --ac: 0 0% 100%;
- --n: 330 20% 17%;
- --nf: 330 20% 10%;
- --nc: 0 0% 100%;
- --b1: 0 0% 100%;
- --b2: 330 20% 95%;
- --b3: 330 20% 90%;
- --bc: 330 20% 17%;
- --in: 330 81% 60%;
- --inc: 0 0% 100%;
- --su: 142 76% 36%;
- --suc: 0 0% 100%;
- --wa: 38 92% 50%;
- --wac: 0 0% 100%;
- --er: 0 84% 60%;
- --erc: 0 0% 100%;
- --rounded-box: 1rem;
- --rounded-btn: 0.5rem;
- --rounded-badge: 1.9rem;
- --animation-btn: 0.25s;
- --animation-input: 0.2s;
- --btn-focus-scale: 0.95;
- --border-btn: 1px;
- --tab-border: 1px;
- --tab-radius: 0.5rem;
+ --color-primary: hsl(330 81% 60%);
+ --color-primary-content: hsl(0 0% 100%);
+ --color-secondary: hsl(330 81% 60%);
+ --color-secondary-content: hsl(0 0% 100%);
+ --color-accent: hsl(330 81% 60%);
+ --color-accent-content: hsl(0 0% 100%);
+ --color-neutral: hsl(330 20% 17%);
+ --color-neutral-content: hsl(0 0% 100%);
+ --color-base-100: hsl(0 0% 100%);
+ --color-base-200: hsl(330 20% 95%);
+ --color-base-300: hsl(330 20% 90%);
+ --color-base-content: hsl(330 20% 17%);
+ --color-info: hsl(330 81% 60%);
+ --color-info-content: hsl(0 0% 100%);
+ --color-success: hsl(142 76% 36%);
+ --color-success-content: hsl(0 0% 100%);
+ --color-warning: hsl(38 92% 50%);
+ --color-warning-content: hsl(0 0% 100%);
+ --color-error: hsl(0 84% 60%);
+ --color-error-content: hsl(0 0% 100%);
+ --radius-selector: 0.5rem;
+ --radius-field: 0.5rem;
+ --radius-box: 1rem;
+ --size-selector: 0.25rem;
+ --size-field: 0.25rem;
+ --border: 1px;
+ --depth: 1;
+ --noise: 0;
}
-html[data-theme='sgse-teal'],
-html[data-theme='sgse-teal'] body,
-[data-theme='sgse-teal'] {
+/* Teal */
+@plugin 'daisyui/theme' {
+ name: 'sgse-teal';
color-scheme: light;
- --p: 173 80% 40%;
- --pf: 173 80% 30%;
- --pc: 0 0% 100%;
- --s: 173 80% 40%;
- --sf: 173 80% 30%;
- --sc: 0 0% 100%;
- --a: 173 80% 40%;
- --af: 173 80% 30%;
- --ac: 0 0% 100%;
- --n: 173 20% 17%;
- --nf: 173 20% 10%;
- --nc: 0 0% 100%;
- --b1: 0 0% 100%;
- --b2: 173 20% 95%;
- --b3: 173 20% 90%;
- --bc: 173 20% 17%;
- --in: 173 80% 40%;
- --inc: 0 0% 100%;
- --su: 142 76% 36%;
- --suc: 0 0% 100%;
- --wa: 38 92% 50%;
- --wac: 0 0% 100%;
- --er: 0 84% 60%;
- --erc: 0 0% 100%;
- --rounded-box: 1rem;
- --rounded-btn: 0.5rem;
- --rounded-badge: 1.9rem;
- --animation-btn: 0.25s;
- --animation-input: 0.2s;
- --btn-focus-scale: 0.95;
- --border-btn: 1px;
- --tab-border: 1px;
- --tab-radius: 0.5rem;
+ --color-primary: hsl(173 80% 40%);
+ --color-primary-content: hsl(0 0% 100%);
+ --color-secondary: hsl(173 80% 40%);
+ --color-secondary-content: hsl(0 0% 100%);
+ --color-accent: hsl(173 80% 40%);
+ --color-accent-content: hsl(0 0% 100%);
+ --color-neutral: hsl(173 20% 17%);
+ --color-neutral-content: hsl(0 0% 100%);
+ --color-base-100: hsl(0 0% 100%);
+ --color-base-200: hsl(173 20% 95%);
+ --color-base-300: hsl(173 20% 90%);
+ --color-base-content: hsl(173 20% 17%);
+ --color-info: hsl(173 80% 40%);
+ --color-info-content: hsl(0 0% 100%);
+ --color-success: hsl(142 76% 36%);
+ --color-success-content: hsl(0 0% 100%);
+ --color-warning: hsl(38 92% 50%);
+ --color-warning-content: hsl(0 0% 100%);
+ --color-error: hsl(0 84% 60%);
+ --color-error-content: hsl(0 0% 100%);
+ --radius-selector: 0.5rem;
+ --radius-field: 0.5rem;
+ --radius-box: 1rem;
+ --size-selector: 0.25rem;
+ --size-field: 0.25rem;
+ --border: 1px;
+ --depth: 1;
+ --noise: 0;
}
-html[data-theme='sgse-corporate'],
-html[data-theme='sgse-corporate'] body,
-[data-theme='sgse-corporate'] {
+/* Corporativo (Dark Blue) */
+@plugin 'daisyui/theme' {
+ name: 'sgse-corporate';
color-scheme: dark;
- --p: 217 91% 60%;
- --pf: 217 91% 50%;
- --pc: 0 0% 100%;
- --s: 217 91% 60%;
- --sf: 217 91% 50%;
- --sc: 0 0% 100%;
- --a: 217 91% 60%;
- --af: 217 91% 50%;
- --ac: 0 0% 100%;
- --n: 217 30% 15%;
- --nf: 217 30% 8%;
- --nc: 0 0% 100%;
- --b1: 217 30% 10%;
- --b2: 217 30% 15%;
- --b3: 217 30% 20%;
- --bc: 217 10% 90%;
- --in: 217 91% 60%;
- --inc: 0 0% 100%;
- --su: 142 76% 36%;
- --suc: 0 0% 100%;
- --wa: 38 92% 50%;
- --wac: 0 0% 100%;
- --er: 0 84% 60%;
- --erc: 0 0% 100%;
- --rounded-box: 1rem;
- --rounded-btn: 0.5rem;
- --rounded-badge: 1.9rem;
- --animation-btn: 0.25s;
- --animation-input: 0.2s;
- --btn-focus-scale: 0.95;
- --border-btn: 1px;
- --tab-border: 1px;
- --tab-radius: 0.5rem;
+ --color-primary: hsl(217 91% 60%);
+ --color-primary-content: hsl(0 0% 100%);
+ --color-secondary: hsl(217 91% 60%);
+ --color-secondary-content: hsl(0 0% 100%);
+ --color-accent: hsl(217 91% 60%);
+ --color-accent-content: hsl(0 0% 100%);
+ --color-neutral: hsl(217 30% 15%);
+ --color-neutral-content: hsl(0 0% 100%);
+ --color-base-100: hsl(217 30% 10%);
+ --color-base-200: hsl(217 30% 15%);
+ --color-base-300: hsl(217 30% 20%);
+ --color-base-content: hsl(217 10% 90%);
+ --color-info: hsl(217 91% 60%);
+ --color-info-content: hsl(0 0% 100%);
+ --color-success: hsl(142 76% 36%);
+ --color-success-content: hsl(0 0% 100%);
+ --color-warning: hsl(38 92% 50%);
+ --color-warning-content: hsl(0 0% 100%);
+ --color-error: hsl(0 84% 60%);
+ --color-error-content: hsl(0 0% 100%);
+ --radius-selector: 0.5rem;
+ --radius-field: 0.5rem;
+ --radius-box: 1rem;
+ --size-selector: 0.25rem;
+ --size-field: 0.25rem;
+ --border: 1px;
+ --depth: 1;
+ --noise: 0;
}
-/* Tema Light customizado para garantir funcionamento completo */
-html[data-theme='light'],
-html[data-theme='light'] body,
-[data-theme='light'] {
+/* Light */
+@plugin 'daisyui/theme' {
+ name: 'light';
color-scheme: light;
- --p: 217 91% 60%;
- --pf: 217 91% 50%;
- --pc: 0 0% 100%;
- --s: 217 91% 60%;
- --sf: 217 91% 50%;
- --sc: 0 0% 100%;
- --a: 217 91% 60%;
- --af: 217 91% 50%;
- --ac: 0 0% 100%;
- --n: 217 20% 17%;
- --nf: 217 20% 10%;
- --nc: 0 0% 100%;
- --b1: 0 0% 100%;
- --b2: 217 20% 95%;
- --b3: 217 20% 90%;
- --bc: 217 20% 17%;
- --in: 217 91% 60%;
- --inc: 0 0% 100%;
- --su: 142 76% 36%;
- --suc: 0 0% 100%;
- --wa: 38 92% 50%;
- --wac: 0 0% 100%;
- --er: 0 84% 60%;
- --erc: 0 0% 100%;
- --rounded-box: 1rem;
- --rounded-btn: 0.5rem;
- --rounded-badge: 1.9rem;
- --animation-btn: 0.25s;
- --animation-input: 0.2s;
- --btn-focus-scale: 0.95;
- --border-btn: 1px;
- --tab-border: 1px;
- --tab-radius: 0.5rem;
+ --color-primary: hsl(217 91% 60%);
+ --color-primary-content: hsl(0 0% 100%);
+ --color-secondary: hsl(217 91% 60%);
+ --color-secondary-content: hsl(0 0% 100%);
+ --color-accent: hsl(217 91% 60%);
+ --color-accent-content: hsl(0 0% 100%);
+ --color-neutral: hsl(217 20% 17%);
+ --color-neutral-content: hsl(0 0% 100%);
+ --color-base-100: hsl(0 0% 100%);
+ --color-base-200: hsl(217 20% 95%);
+ --color-base-300: hsl(217 20% 90%);
+ --color-base-content: hsl(217 20% 17%);
+ --color-info: hsl(217 91% 60%);
+ --color-info-content: hsl(0 0% 100%);
+ --color-success: hsl(142 76% 36%);
+ --color-success-content: hsl(0 0% 100%);
+ --color-warning: hsl(38 92% 50%);
+ --color-warning-content: hsl(0 0% 100%);
+ --color-error: hsl(0 84% 60%);
+ --color-error-content: hsl(0 0% 100%);
+ --radius-selector: 0.5rem;
+ --radius-field: 0.5rem;
+ --radius-box: 1rem;
+ --size-selector: 0.25rem;
+ --size-field: 0.25rem;
+ --border: 1px;
+ --depth: 1;
+ --noise: 0;
}
-/* Tema Dark customizado para garantir funcionamento completo */
-html[data-theme='dark'],
-html[data-theme='dark'] body,
-[data-theme='dark'] {
+/* Dark */
+@plugin 'daisyui/theme' {
+ name: 'dark';
color-scheme: dark;
- --p: 217 91% 60%;
- --pf: 217 91% 50%;
- --pc: 0 0% 100%;
- --s: 217 91% 60%;
- --sf: 217 91% 50%;
- --sc: 0 0% 100%;
- --a: 217 91% 60%;
- --af: 217 91% 50%;
- --ac: 0 0% 100%;
- --n: 217 30% 15%;
- --nf: 217 30% 8%;
- --nc: 0 0% 100%;
- --b1: 217 30% 10%;
- --b2: 217 30% 15%;
- --b3: 217 30% 20%;
- --bc: 217 10% 90%;
- --in: 217 91% 60%;
- --inc: 0 0% 100%;
- --su: 142 76% 36%;
- --suc: 0 0% 100%;
- --wa: 38 92% 50%;
- --wac: 0 0% 100%;
- --er: 0 84% 60%;
- --erc: 0 0% 100%;
- --rounded-box: 1rem;
- --rounded-btn: 0.5rem;
- --rounded-badge: 1.9rem;
- --animation-btn: 0.25s;
- --animation-input: 0.2s;
- --btn-focus-scale: 0.95;
- --border-btn: 1px;
- --tab-border: 1px;
- --tab-radius: 0.5rem;
+ --color-primary: hsl(217 91% 60%);
+ --color-primary-content: hsl(0 0% 100%);
+ --color-secondary: hsl(217 91% 60%);
+ --color-secondary-content: hsl(0 0% 100%);
+ --color-accent: hsl(217 91% 60%);
+ --color-accent-content: hsl(0 0% 100%);
+ --color-neutral: hsl(217 30% 15%);
+ --color-neutral-content: hsl(0 0% 100%);
+ --color-base-100: hsl(217 30% 10%);
+ --color-base-200: hsl(217 30% 15%);
+ --color-base-300: hsl(217 30% 20%);
+ --color-base-content: hsl(217 10% 90%);
+ --color-info: hsl(217 91% 60%);
+ --color-info-content: hsl(0 0% 100%);
+ --color-success: hsl(142 76% 36%);
+ --color-success-content: hsl(0 0% 100%);
+ --color-warning: hsl(38 92% 50%);
+ --color-warning-content: hsl(0 0% 100%);
+ --color-error: hsl(0 84% 60%);
+ --color-error-content: hsl(0 0% 100%);
+ --radius-selector: 0.5rem;
+ --radius-field: 0.5rem;
+ --radius-box: 1rem;
+ --size-selector: 0.25rem;
+ --size-field: 0.25rem;
+ --border: 1px;
+ --depth: 1;
+ --noise: 0;
}
diff --git a/apps/web/src/app.html b/apps/web/src/app.html
index e912c97..acc1048 100644
--- a/apps/web/src/app.html
+++ b/apps/web/src/app.html
@@ -111,8 +111,17 @@
(function () {
if (typeof document !== 'undefined') {
var html = document.documentElement;
- if (!html.getAttribute('data-theme')) {
- html.setAttribute('data-theme', 'aqua');
+ if (html && !html.getAttribute('data-theme')) {
+ var tema = null;
+ try {
+ // theme-change usa por padrão a chave "theme"
+ tema = localStorage.getItem('theme');
+ } catch (e) {
+ tema = null;
+ }
+
+ // Fallback para o tema padrão se não houver persistência
+ html.setAttribute('data-theme', tema || 'aqua');
}
}
})();
diff --git a/apps/web/src/lib/components/Header.svelte b/apps/web/src/lib/components/Header.svelte
index 20ee848..a28489c 100644
--- a/apps/web/src/lib/components/Header.svelte
+++ b/apps/web/src/lib/components/Header.svelte
@@ -35,6 +35,23 @@
+
+ Aqua
+ Azul
+ Verde
+ Laranja
+ Vermelho
+ Rosa
+ Verde-água
+ Corporativo
+ Claro
+ Escuro
+
+
{#if right}
{@render right()}
{/if}
diff --git a/apps/web/src/lib/utils/temas.ts b/apps/web/src/lib/utils/temas.ts
index 3fef2d7..bc17ca8 100644
--- a/apps/web/src/lib/utils/temas.ts
+++ b/apps/web/src/lib/utils/temas.ts
@@ -153,20 +153,15 @@ export function aplicarTema(temaId: TemaId | string | null | undefined): void {
const nomeDaisyUI = obterNomeDaisyUI(temaId || 'purple');
const htmlElement = document.documentElement;
- const bodyElement = document.body;
if (htmlElement) {
// Remover todos os atributos data-theme existentes primeiro
htmlElement.removeAttribute('data-theme');
- if (bodyElement) {
- bodyElement.removeAttribute('data-theme');
- }
+ // Evita que `body[data-theme]` sobrescreva o tema do ``
+ if (document.body) document.body.removeAttribute('data-theme');
// Aplicar o novo tema
htmlElement.setAttribute('data-theme', nomeDaisyUI);
- if (bodyElement) {
- bodyElement.setAttribute('data-theme', nomeDaisyUI);
- }
// Forçar reflow para garantir que o CSS seja aplicado
void htmlElement.offsetHeight;
@@ -230,20 +225,21 @@ export function obterCoresDoTema(): {
}
const htmlElement = document.documentElement;
- const getComputedStyle = (varName: string): string => {
- return getComputedStyle(htmlElement).getPropertyValue(varName).trim() || '';
+ const readCssVar = (varName: string): string => {
+ return window.getComputedStyle(htmlElement).getPropertyValue(varName).trim() || '';
};
- // Tentar obter variáveis CSS do DaisyUI
- const primary = getComputedStyle('--p') || '#667eea';
- const success = getComputedStyle('--suc') || '#10b981';
- const error = getComputedStyle('--er') || '#ef4444';
- const warning = getComputedStyle('--wa') || '#f59e0b';
- const info = getComputedStyle('--in') || '#3b82f6';
- const baseContent = getComputedStyle('--bc') || '#1f2937';
- const base100 = getComputedStyle('--b1') || '#ffffff';
- const base200 = getComputedStyle('--b2') || '#f3f4f6';
- const base300 = getComputedStyle('--b3') || '#e5e7eb';
+ // DaisyUI v5: variáveis `--color-*`
+ // Fallback para v4/legado: variáveis curtas `--p`, `--suc`, etc.
+ const primary = readCssVar('--color-primary') || readCssVar('--p') || '#667eea';
+ const success = readCssVar('--color-success') || readCssVar('--suc') || '#10b981';
+ const error = readCssVar('--color-error') || readCssVar('--er') || '#ef4444';
+ const warning = readCssVar('--color-warning') || readCssVar('--wa') || '#f59e0b';
+ const info = readCssVar('--color-info') || readCssVar('--in') || '#3b82f6';
+ const baseContent = readCssVar('--color-base-content') || readCssVar('--bc') || '#1f2937';
+ const base100 = readCssVar('--color-base-100') || readCssVar('--b1') || '#ffffff';
+ const base200 = readCssVar('--color-base-200') || readCssVar('--b2') || '#f3f4f6';
+ const base300 = readCssVar('--color-base-300') || readCssVar('--b3') || '#e5e7eb';
return {
primary: primary || '#667eea',
diff --git a/apps/web/src/routes/+layout.svelte b/apps/web/src/routes/+layout.svelte
index a32e3e5..5942838 100644
--- a/apps/web/src/routes/+layout.svelte
+++ b/apps/web/src/routes/+layout.svelte
@@ -1,5 +1,6 @@
+
+
diff --git a/apps/web/src/lib/components/DecorativeTopLine.svelte b/apps/web/src/lib/components/DecorativeTopLine.svelte
new file mode 100644
index 0000000..97129d5
--- /dev/null
+++ b/apps/web/src/lib/components/DecorativeTopLine.svelte
@@ -0,0 +1,14 @@
+
+
+
diff --git a/apps/web/src/lib/components/ErrorMessage.svelte b/apps/web/src/lib/components/ErrorMessage.svelte
new file mode 100644
index 0000000..e6f0850
--- /dev/null
+++ b/apps/web/src/lib/components/ErrorMessage.svelte
@@ -0,0 +1,22 @@
+
+
+{#if message}
+
+
+ {message}
+
+{/if}
diff --git a/apps/web/src/lib/components/GlassCard.svelte b/apps/web/src/lib/components/GlassCard.svelte
new file mode 100644
index 0000000..600d7f3
--- /dev/null
+++ b/apps/web/src/lib/components/GlassCard.svelte
@@ -0,0 +1,19 @@
+
+
+
+ {@render children?.()}
+
diff --git a/apps/web/src/lib/components/Header.svelte b/apps/web/src/lib/components/Header.svelte
index 6a42959..e5e7e3e 100644
--- a/apps/web/src/lib/components/Header.svelte
+++ b/apps/web/src/lib/components/Header.svelte
@@ -12,7 +12,7 @@
diff --git a/apps/web/src/lib/components/MenuToggleIcon.svelte b/apps/web/src/lib/components/MenuToggleIcon.svelte
new file mode 100644
index 0000000..1e6bb1e
--- /dev/null
+++ b/apps/web/src/lib/components/MenuToggleIcon.svelte
@@ -0,0 +1,85 @@
+
+
+
+
+
diff --git a/apps/web/src/lib/components/ShineEffect.svelte b/apps/web/src/lib/components/ShineEffect.svelte
new file mode 100644
index 0000000..df60c12
--- /dev/null
+++ b/apps/web/src/lib/components/ShineEffect.svelte
@@ -0,0 +1,14 @@
+
+
+
diff --git a/apps/web/src/lib/components/login/LoginInput.svelte b/apps/web/src/lib/components/login/LoginInput.svelte
new file mode 100644
index 0000000..024413a
--- /dev/null
+++ b/apps/web/src/lib/components/login/LoginInput.svelte
@@ -0,0 +1,62 @@
+
+
+
+
+
+ {label}
+
+ {@render right?.()}
+
+
+
+
+
+
+ {#if error}
+ {error}
+ {/if}
+
diff --git a/apps/web/src/routes/(dashboard)/+layout.svelte b/apps/web/src/routes/(dashboard)/+layout.svelte
index 68ea086..46cf6c0 100644
--- a/apps/web/src/routes/(dashboard)/+layout.svelte
+++ b/apps/web/src/routes/(dashboard)/+layout.svelte
@@ -4,11 +4,11 @@
import PushNotificationManager from '$lib/components/PushNotificationManager.svelte';
import Footer from '$lib/components/Footer.svelte';
import Header from '$lib/components/Header.svelte';
+ import MenuToggleIcon from '$lib/components/MenuToggleIcon.svelte';
import Sidebar from '$lib/components/Sidebar.svelte';
import DashboardHeaderActions from '$lib/components/dashboard/DashboardHeaderActions.svelte';
import ChatWidget from '$lib/components/chat/ChatWidget.svelte';
import PresenceManager from '$lib/components/chat/PresenceManager.svelte';
- import { Menu, X } from 'lucide-svelte';
const { children } = $props();
@@ -44,11 +44,7 @@
aria-label={sidebarOpen ? 'Fechar menu' : 'Abrir menu'}
onclick={toggleSidebar}
>
- {#if sidebarOpen}
-
- {:else}
-
- {/if}
+
{/snippet}
diff --git a/apps/web/src/routes/(public)/login/+page.svelte b/apps/web/src/routes/(public)/login/+page.svelte
index 2aabd1b..94daa52 100644
--- a/apps/web/src/routes/(public)/login/+page.svelte
+++ b/apps/web/src/routes/(public)/login/+page.svelte
@@ -9,7 +9,13 @@
import logo from '$lib/assets/logo_governo_PE.png';
import { authClient } from '$lib/auth';
import { obterIPPublico } from '$lib/utils/deviceInfo';
- import { LogIn, XCircle } from 'lucide-svelte';
+ import AnimatedBackgroundElements from '$lib/components/AnimatedBackgroundElements.svelte';
+ import DecorativeTopLine from '$lib/components/DecorativeTopLine.svelte';
+ import ErrorMessage from '$lib/components/ErrorMessage.svelte';
+ import GlassCard from '$lib/components/GlassCard.svelte';
+ import LoginInput from '$lib/components/login/LoginInput.svelte';
+ import ShineEffect from '$lib/components/ShineEffect.svelte';
+ import { LogIn } from 'lucide-svelte';
interface GPSLocation {
latitude?: number;
@@ -167,114 +173,74 @@
-
-
+
-
-
-
+
+
-
+
Bem-vindo de volta
-
+
Entre com suas credenciais para acessar o sistema
- {#if erroLogin}
-
-
- {erroLogin}
-
- {/if}
+
-
+
Precisa de ajuda?
Abrir um chamado
-
+
-
+
© {new Date().getFullYear()} Governo de Pernambuco. Todos os direitos reservados.