Spaces:
Running
Running
Aqui está um prompt mais detalhado e estruturado para criar um site de Pomodoro com Angular e Golang, incluindo todas as funcionalidades solicitadas: --- **Objetivo:** Desenvolver uma aplicação web usando Angular (frontend) e Golang (backend) que implemente a técnica Pomodoro com as seguintes funcionalidades: ### Funcionalidades Principais: 1. **Temporizador Pomodoro:** - Configuração personalizável de tempo (trabalho: padrão 25min, descanso: padrão 5min). - Botões para iniciar, pausar, reiniciar e pular fases. - Notificação visual/sonora ao final de cada fase. 2. **Gerenciamento de Tarefas:** - CRUD (Criar, Ler, Atualizar, Excluir) para tarefas. - Vincular pomodoros concluídos a cada tarefa. - Marcar tarefas como concluídas. - Categorização por tags/projetos. 3. **Calendário e Estatísticas:** - Visualização mensal/semanal com dias clicáveis. - Exibir por dia: - Número de pomodoros concluídos. - Tempo total de trabalho/descanso. - Gráficos (barras, linhas) para comparação histórica. 4. **Relatórios:** - Filtros por período (semana, mês, ano). - Dados consolidados: - Média diária/semanal de pomodoros. - Tempo total produtivo. - Tarefas mais frequentes. - Exportação em PDF/CSV. ### Requisitos Técnicos: - **Frontend (Angular):** - Componentes reutilizáveis (timer, lista de tarefas, calendário). - Serviços para comunicação com a API. - RxJS para gerenciamento de estado. - UI responsiva com Angular Material ou TailwindCSS. - Animações para transições de fases. - **Backend (Golang):** - API RESTful com endpoints para: - `/tasks` (gerenciamento de tarefas). - `/pomodoros` (registro de sessões). - `/reports` (geração de relatórios). - Banco de dados (ex: PostgreSQL/SQLite) com modelos para: - `Task` (id, title, tags, completed, createdAt). - `Pomodoro` (id, taskId, duration, type:work/break, date). - Autenticação JWT (opcional, se necessário). ### Entregáveis Esperados: 1. Código fonte organizado em repositório Git. 2. Dockerfile/docker-compose para deploy (opcional). 3. README com instruções de instalação e uso. ### Exemplo de Fluxo: ```typescript // Exemplo de estrutura para uma tarefa interface Task { id: string; title: string; estimatedPomodoros: number; completedPomodoros: number; isCompleted: boolean; } // Exemplo de dado para o relatório interface PomodoroReport { date: Date; workTime: number; // em minutos breakTime: number; completedTasks: number; } ``` **Diferenciais:** - Dark mode. - Sincronização entre dispositivos. - Integração com Google Calendar. --- Este prompt é mais claro para desenvolvedores, especificando: ✅ Arquitetura ✅ Funcionalidades detalhadas ✅ Estrutura de dados ✅ Requisitos não-funcionais (ex: responsividade) - Initial Deployment
1fcdb15 verified Download index.html from devdsfr/dsfrpomodoro: direct link, hf CLI and curl.
- Browser
- Download file 15.3 kB
-
https://huggingface.co/spaces/devdsfr/dsfrpomodoro/resolve/main/index.html
- Command line
-
hf download hf://spaces/devdsfr/dsfrpomodoro/index.html
-
curl -L -o index.html https://huggingface.co/spaces/devdsfr/dsfrpomodoro/resolve/main/index.html
15.3 kB
| <html lang="en"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>FocusFlow - Pomodoro Timer</title> | |
| <script src="https://cdn.tailwindcss.com"></script> | |
| <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css"> | |
| <style> | |
| @keyframes pulse { | |
| 0% { transform: scale(1); } | |
| 50% { transform: scale(1.05); } | |
| 100% { transform: scale(1); } | |
| } | |
| .pulse-animation { | |
| animation: pulse 1.5s infinite; | |
| } | |
| .progress-ring__circle { | |
| transition: stroke-dashoffset 0.35s; | |
| transform: rotate(-90deg); | |
| transform-origin: 50% 50%; | |
| } | |
| .task-item:hover .task-actions { | |
| opacity: 1; | |
| } | |
| .dark-mode { | |
| background-color: #1a202c; | |
| color: #e2e8f0; | |
| } | |
| .dark-mode .card { | |
| background-color: #2d3748; | |
| border-color: #4a5568; | |
| } | |
| </style> | |
| </head> | |
| <body class="bg-gray-100 font-sans transition-colors duration-300"> | |
| <div class="container mx-auto px-4 py-8 max-w-6xl"> | |
| <!-- Header --> | |
| <header class="flex justify-between items-center mb-8"> | |
| <h1 class="text-3xl font-bold text-indigo-600"> | |
| <i class="fas fa-clock mr-2"></i> FocusFlow | |
| </h1> | |
| <div class="flex items-center space-x-4"> | |
| <button id="themeToggle" class="p-2 rounded-full bg-gray-200 hover:bg-gray-300 dark:bg-gray-700 dark:hover:bg-gray-600"> | |
| <i class="fas fa-moon text-gray-700 dark:text-yellow-300"></i> | |
| </button> | |
| <button class="px-4 py-2 bg-indigo-600 text-white rounded-lg hover:bg-indigo-700 transition"> | |
| <i class="fas fa-sign-in-alt mr-2"></i> Login | |
| </button> | |
| </div> | |
| </header> | |
| <div class="grid grid-cols-1 lg:grid-cols-3 gap-8"> | |
| <!-- Timer Section --> | |
| <div class="lg:col-span-2"> | |
| <div class="card bg-white rounded-xl shadow-lg p-6 mb-6 transition-colors duration-300 dark:bg-gray-800 dark:border-gray-700"> | |
| <div class="flex justify-between items-center mb-6"> | |
| <h2 class="text-2xl font-semibold dark:text-white">Pomodoro Timer</h2> | |
| <div class="flex space-x-2"> | |
| <button id="settingsBtn" class="p-2 text-gray-500 hover:text-indigo-600 dark:hover:text-indigo-400"> | |
| <i class="fas fa-cog"></i> | |
| </button> | |
| </div> | |
| </div> | |
| <!-- Timer Display --> | |
| <div class="flex justify-center mb-8"> | |
| <div class="relative w-64 h-64"> | |
| <svg class="w-full h-full" viewBox="0 0 100 100"> | |
| <circle cx="50" cy="50" r="45" fill="none" stroke="#e2e8f0" stroke-width="8" class="dark:stroke-gray-600"/> | |
| <circle id="progressCircle" cx="50" cy="50" r="45" fill="none" stroke="#4f46e5" stroke-width="8" stroke-dasharray="283" stroke-dashoffset="0" class="progress-ring__circle"/> | |
| </svg> | |
| <div class="absolute inset-0 flex flex-col items-center justify-center"> | |
| <div id="timerDisplay" class="text-5xl font-bold mb-2 dark:text-white">25:00</div> | |
| <div id="phaseDisplay" class="text-lg font-medium text-indigo-600 dark:text-indigo-400">Focus Time</div> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Timer Controls --> | |
| <div class="flex justify-center space-x-4 mb-6"> | |
| <button id="startBtn" class="px-6 py-3 bg-indigo-600 text-white rounded-lg hover:bg-indigo-700 transition flex items-center pulse-animation"> | |
| <i class="fas fa-play mr-2"></i> Start | |
| </button> | |
| <button id="pauseBtn" class="px-6 py-3 bg-gray-200 text-gray-700 rounded-lg hover:bg-gray-300 transition flex items-center dark:bg-gray-700 dark:text-white dark:hover:bg-gray-600" disabled> | |
| <i class="fas fa-pause mr-2"></i> Pause | |
| </button> | |
| <button id="skipBtn" class="px-6 py-3 bg-gray-200 text-gray-700 rounded-lg hover:bg-gray-300 transition flex items-center dark:bg-gray-700 dark:text-white dark:hover:bg-gray-600"> | |
| <i class="fas fa-forward mr-2"></i> Skip | |
| </button> | |
| </div> | |
| <!-- Pomodoro Counter --> | |
| <div class="text-center"> | |
| <div class="inline-flex items-center bg-gray-100 rounded-full px-4 py-2 dark:bg-gray-700"> | |
| <span class="font-medium mr-2 dark:text-white">Session:</span> | |
| <span id="pomodoroCount" class="font-bold text-indigo-600 dark:text-indigo-400">0</span> | |
| <span class="mx-1 dark:text-white">/</span> | |
| <span id="pomodoroGoal" class="font-bold dark:text-white">4</span> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Tasks Section --> | |
| <div class="card bg-white rounded-xl shadow-lg p-6 transition-colors duration-300 dark:bg-gray-800 dark:border-gray-700"> | |
| <div class="flex justify-between items-center mb-4"> | |
| <h2 class="text-2xl font-semibold dark:text-white">Tasks</h2> | |
| <button id="addTaskBtn" class="px-4 py-2 bg-indigo-600 text-white rounded-lg hover:bg-indigo-700 transition flex items-center"> | |
| <i class="fas fa-plus mr-2"></i> Add Task | |
| </button> | |
| </div> | |
| <div id="taskList" class="space-y-3"> | |
| <!-- Task items will be added here dynamically --> | |
| <div class="task-item bg-gray-50 rounded-lg p-4 border border-gray-200 transition hover:border-indigo-300 dark:bg-gray-700 dark:border-gray-600"> | |
| <div class="flex items-center justify-between"> | |
| <div class="flex items-center"> | |
| <button class="w-6 h-6 rounded-full border-2 border-gray-300 mr-3 flex items-center justify-center hover:border-indigo-400 dark:border-gray-500"> | |
| <i class="fas fa-check text-transparent"></i> | |
| </button> | |
| <span class="font-medium dark:text-white">Complete project proposal</span> | |
| </div> | |
| <div class="task-actions opacity-0 transition-opacity flex space-x-2"> | |
| <button class="text-gray-400 hover:text-indigo-600 dark:hover:text-indigo-400"> | |
| <i class="fas fa-pencil-alt"></i> | |
| </button> | |
| <button class="text-gray-400 hover:text-red-600"> | |
| <i class="fas fa-trash-alt"></i> | |
| </button> | |
| </div> | |
| </div> | |
| <div class="flex items-center mt-2 ml-9 text-sm text-gray-500 dark:text-gray-400"> | |
| <span class="mr-4"><i class="fas fa-clock mr-1"></i> 2 pomodoros</span> | |
| <span><i class="fas fa-tag mr-1"></i> Work</span> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Right Sidebar --> | |
| <div class="lg:col-span-1"> | |
| <!-- Stats Card --> | |
| <div class="card bg-white rounded-xl shadow-lg p-6 mb-6 transition-colors duration-300 dark:bg-gray-800 dark:border-gray-700"> | |
| <h2 class="text-2xl font-semibold mb-4 dark:text-white">Today's Stats</h2> | |
| <div class="space-y-4"> | |
| <div> | |
| <div class="flex justify-between mb-1"> | |
| <span class="text-gray-600 dark:text-gray-300">Focus Time</span> | |
| <span class="font-medium dark:text-white">0 min</span> | |
| </div> | |
| <div class="w-full bg-gray-200 rounded-full h-2 dark:bg-gray-700"> | |
| <div class="bg-indigo-600 h-2 rounded-full" style="width: 0%"></div> | |
| </div> | |
| </div> | |
| <div> | |
| <div class="flex justify-between mb-1"> | |
| <span class="text-gray-600 dark:text-gray-300">Break Time</span> | |
| <span class="font-medium dark:text-white">0 min</span> | |
| </div> | |
| <div class="w-full bg-gray-200 rounded-full h-2 dark:bg-gray-700"> | |
| <div class="bg-green-500 h-2 rounded-full" style="width: 0%"></div> | |
| </div> | |
| </div> | |
| <div> | |
| <div class="flex justify-between mb-1"> | |
| <span class="text-gray-600 dark:text-gray-300">Pomodoros</span> | |
| <span class="font-medium dark:text-white">0/4</span> | |
| </div> | |
| <div class="w-full bg-gray-200 rounded-full h-2 dark:bg-gray-700"> | |
| <div class="bg-yellow-500 h-2 rounded-full" style="width: 0%"></div> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Calendar --> | |
| <div class="card bg-white rounded-xl shadow-lg p-6 mb-6 transition-colors duration-300 dark:bg-gray-800 dark:border-gray-700"> | |
| <div class="flex justify-between items-center mb-4"> | |
| <h2 class="text-2xl font-semibold dark:text-white">Calendar</h2> | |
| <div class="flex space-x-2"> | |
| <button class="p-1 text-gray-500 hover:text-indigo-600 dark:hover:text-indigo-400"> | |
| <i class="fas fa-chevron-left"></i> | |
| </button> | |
| <span class="font-medium dark:text-white">June 2023</span> | |
| <button class="p-1 text-gray-500 hover:text-indigo-600 dark:hover:text-indigo-400"> | |
| <i class="fas fa-chevron-right"></i> | |
| </button> | |
| </div> | |
| </div> | |
| <div class="grid grid-cols-7 gap-1 text-center"> | |
| <div class="text-sm font-medium text-gray-500 dark:text-gray-400">Sun</div> | |
| <div class="text-sm font-medium text-gray-500 dark:text-gray-400">Mon</div> | |
| <div class="text-sm font-medium text-gray-500 dark:text-gray-400">Tue</div> | |
| <div class="text-sm font-medium text-gray-500 dark:text-gray-400">Wed</div> | |
| <div class="text-sm font-medium text-gray-500 dark:text-gray-400">Thu</div> | |
| <div class="text-sm font-medium text-gray-500 dark:text-gray-400">Fri</div> | |
| <div class="text-sm font-medium text-gray-500 dark:text-gray-400">Sat</div> | |
| <!-- Calendar days will be added here dynamically --> | |
| <div class="py-1 rounded-full text-gray-400 dark:text-gray-500">28</div> | |
| <div class="py-1 rounded-full text-gray-400 dark:text-gray-500">29</div> | |
| <div class="py-1 rounded-full text-gray-400 dark:text-gray-500">30</div> | |
| <div class="py-1 rounded-full text-gray-400 dark:text-gray-500">31</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">1</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">2</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">3</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">4</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">5</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">6</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">7</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">8</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">9</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">10</div> | |
| <div class="py-1 rounded-full bg-indigo-100 text-indigo-600 font-medium dark:bg-indigo-900 dark:text-indigo-200 cursor-pointer">11</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">12</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">13</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">14</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">15</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">16</div> | |
| <div class="py-1 rounded-full hover:bg-gray-100 dark:hover:bg-gray-700 cursor-pointer">17</div> | |
| <div class="py-1 rounded-full hover | |
| <p style="border-radius: 8px; text-align: center; font-size: 12px; color: #fff; margin-top: 16px;position: fixed; left: 8px; bottom: 8px; z-index: 10; background: rgba(0, 0, 0, 0.8); padding: 4px 8px;">Made with <img src="https://enzostvs-deepsite.hf.space/logo.svg" alt="DeepSite Logo" style="width: 16px; height: 16px; vertical-align: middle;display:inline-block;margin-right:3px;filter:brightness(0) invert(1);"><a href="https://enzostvs-deepsite.hf.space" style="color: #fff;text-decoration: underline;" target="_blank" >DeepSite</a> - 🧬 <a href="https://enzostvs-deepsite.hf.space?remix=devdsfr/dsfrpomodoro" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body> | |
| </html> |