/** * Supera Glia - Tab E-mail v3 * Iframe ocupa toda a tela disponível */ (function() { 'use strict'; const WEBMAIL_URL = 'https://webmail.supera.myddns.me'; const EmailTab = () => { const { useState } = SuperaGlia.hooks; const [carregando, setCarregando] = useState(true); const [erro, setErro] = useState(false); return React.createElement('div', { style: { height: 'calc(100vh - 32px)' }, className: 'relative rounded-lg overflow-hidden' }, carregando && React.createElement('div', { className: 'absolute inset-0 flex items-center justify-center bg-gray-50 z-10' }, React.createElement('div', { className: 'text-center' }, React.createElement('div', { className: 'w-10 h-10 border-4 border-blue-200 border-t-blue-500 rounded-full animate-spin mx-auto mb-4' }), React.createElement('p', { className: 'text-gray-500' }, 'Carregando...') ) ), erro ? React.createElement('div', { className: 'h-full flex items-center justify-center bg-gray-50' }, React.createElement('div', { className: 'text-center' }, React.createElement('p', { className: 'text-gray-500 mb-4' }, 'Não foi possível carregar'), React.createElement('button', { onClick: () => window.open(WEBMAIL_URL, '_blank'), className: 'px-4 py-2 bg-blue-500 text-white rounded-lg' }, 'Abrir em nova aba') ) ) : React.createElement('iframe', { src: WEBMAIL_URL, className: 'w-full h-full border-0', onLoad: () => setCarregando(false), onError: () => { setCarregando(false); setErro(true); }, allow: 'clipboard-read; clipboard-write' }) ); }; SuperaGlia.initEmailTab = function() { SuperaGlia.EmailTab = EmailTab; }; })();