Spaces:
Running
Running
| <html lang="pt-BR"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Matriz de Análise de Vínculos</title> | |
| <script src="https://cdn.tailwindcss.com"></script> | |
| <script> | |
| tailwind.config = { | |
| theme: { | |
| extend: { | |
| colors: { | |
| primary: '#3b82f6', | |
| secondary: '#8b5cf6', | |
| } | |
| } | |
| } | |
| } | |
| </script> | |
| <link rel="stylesheet" href="style.css"> | |
| </head> | |
| <body class="bg-gray-100 p-4 sm:p-8 font-sans"> | |
| <div class="max-w-7xl mx-auto bg-white p-6 rounded-lg shadow-md"> | |
| <h1 class="text-2xl font-bold text-center text-gray-800 mb-4">Matriz de Análise de Vínculos</h1> | |
| <!-- Controles --> | |
| <div class="flex flex-wrap justify-between items-center gap-4 mb-6 pb-4 border-b no-print"> | |
| <div class="flex gap-2 flex-grow"> | |
| <input type="text" id="newEntityInput" placeholder="Nome do Réu, Prova, Testemunha..." | |
| class="border border-gray-300 rounded px-4 py-2 w-full max-w-md focus:ring-2 focus:ring-primary outline-none transition" | |
| autocomplete="off" /> | |
| <button id="addEntityBtn" class="bg-primary hover:bg-primary-dark text-white font-semibold py-2 px-4 rounded transition duration-200 flex items-center gap-1"> | |
| <span class="text-lg">➕</span> Adicionar | |
| </button> | |
| </div> | |
| <div class="flex gap-2 flex-wrap"> | |
| <button onclick="exportMatrix()" class="bg-secondary hover:bg-secondary-dark text-white font-semibold py-2 px-4 rounded transition duration-200 flex items-center gap-1"> | |
| <span class="text-lg">📤</span> Exportar | |
| </button> | |
| <button onclick="importMatrix()" class="bg-indigo-600 hover:bg-indigo-700 text-white font-semibold py-2 px-4 rounded transition duration-200 flex items-center gap-1"> | |
| <span class="text-lg">📥</span> Importar | |
| </button> | |
| <button onclick="window.print()" class="bg-green-600 hover:bg-green-700 text-white font-semibold py-2 px-4 rounded transition duration-200 flex items-center gap-1"> | |
| <span class="text-lg">🖨️</span> Imprimir | |
| </button> | |
| <button onclick="clearAllData()" class="bg-red-600 hover:bg-red-700 text-white font-semibold py-2 px-4 rounded transition duration-200 flex items-center gap-1"> | |
| <span class="text-lg">🗑️</span> Limpar Tudo | |
| </button> | |
| </div> | |
| </div> | |
| <!-- Tabela --> | |
| <div class="overflow-x-auto"> | |
| <table id="matrix-table" class="min-w-full border-collapse"></table> | |
| </div> | |
| </div> | |
| <!-- Modal de Anotações --> | |
| <div id="note-modal" class="hidden fixed inset-0 bg-black bg-opacity-50 flex items-center justify-center p-4 z-50"> | |
| <div class="bg-white rounded-lg shadow-lg max-w-lg w-full p-6"> | |
| <h2 class="text-xl font-bold mb-2">📝 Anotação do Vínculo</h2> | |
| <p id="note-context" class="mb-4 text-gray-700"></p> | |
| <textarea id="note-textarea" placeholder="Escreva aqui a fundamentação do vínculo..." class="w-full p-3 border border-gray-300 rounded-md mb-4 h-32 focus:ring-2 focus:ring-primary outline-none transition"></textarea> | |
| <div class="flex justify-end gap-2"> | |
| <button onclick="closeNoteModal()" class="px-4 py-2 bg-gray-300 hover:bg-gray-400 rounded-md transition">Cancelar</button> | |
| <button onclick="saveNote()" class="px-4 py-2 bg-green-500 hover:bg-green-600 text-white rounded-md transition">💾 Salvar</button> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Input oculto para importação --> | |
| <input type="file" id="importInput" accept=".json" class="hidden" /> | |
| <script src="script.js"></script> | |
| <script src="https://huggingface.co/deepsite/deepsite-badge.js"></script> | |
| </body> | |
| </html> |