Skip to content

Commit 28963fe

Browse files
authored
Update autoridade.html
1 parent 910bd29 commit 28963fe

File tree

1 file changed

+34
-0
lines changed

1 file changed

+34
-0
lines changed

autoridade.html

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -92,6 +92,24 @@
9292
background: rgba(45, 140, 240, 0.2);
9393
}
9494

95+
/* BOTÃO GPT ASSISTANT - ROXO */
96+
.tab-gpt {
97+
background: transparent;
98+
border: 1px solid #9c27b0;
99+
color: #9c27b0;
100+
padding: 12px 25px;
101+
border-radius: 20px;
102+
cursor: pointer;
103+
transition: .3s;
104+
font-size: 1rem;
105+
}
106+
.tab-gpt:hover {
107+
background: rgba(156, 39, 176, 0.1);
108+
}
109+
.tab-gpt.active {
110+
background: rgba(156, 39, 176, 0.2);
111+
}
112+
95113
/* Conteúdo principal */
96114
.content {
97115
background: #111;
@@ -438,6 +456,8 @@ <h1>🌍 Painel de Autoridade — Terra Dourada</h1>
438456
<button class="tab-perfil" onclick="showTab('perfil')">👤 Editar Perfil</button>
439457
<!-- BOTÃO P2P SOCIAL -->
440458
<button class="tab-p2p" onclick="irParaRedeSocial()">🌐 P2P Social</button>
459+
<!-- NOVO BOTÃO: GPT ASSISTANT -->
460+
<button class="tab-gpt" onclick="irParaGPTAssistant()">🤖 GPT Assistant</button>
441461
</div>
442462

443463
<!-- CONTEÚDO PRINCIPAL -->
@@ -604,6 +624,19 @@ <h3 id="confirmationElectionName" style="color: #d4af37; margin: 10px 0 20px;"><
604624
window.location.href = `rede_social.html?user_id=${userId}`;
605625
}
606626

627+
// NOVA FUNÇÃO: Ir para GPT Assistant
628+
function irParaGPTAssistant() {
629+
if (!usuarioLogado) {
630+
alert('Erro: Usuário não identificado. Faça login novamente.');
631+
window.location.href = 'login.html';
632+
return;
633+
}
634+
635+
// Passar o email do usuário como parâmetro para manter o login
636+
const userId = encodeURIComponent(usuarioLogado.email);
637+
window.location.href = `index_gpt.html?user_id=${userId}`;
638+
}
639+
607640
// FUNÇÃO: Identificar usuário logado
608641
async function identificarUsuarioLogado() {
609642
try {
@@ -641,6 +674,7 @@ <h3 id="confirmationElectionName" style="color: #d4af37; margin: 10px 0 20px;"><
641674
document.querySelectorAll('.tab').forEach(t => t.classList.remove('active'));
642675
document.querySelectorAll('.tab-p2p').forEach(t => t.classList.remove('active'));
643676
document.querySelectorAll('.tab-perfil').forEach(t => t.classList.remove('active'));
677+
document.querySelectorAll('.tab-gpt').forEach(t => t.classList.remove('active'));
644678
document.querySelectorAll('[id^="tab-"]').forEach(c => c.style.display = 'none');
645679

646680
// Ativar aba atual

0 commit comments

Comments
 (0)