Download index.html from edulisboa/acitymob: direct link, hf CLI and curl.
- Browser
- Download file 31.3 kB
-
https://huggingface.co/spaces/edulisboa/acitymob/resolve/main/index.html
- Command line
-
hf download hf://spaces/edulisboa/acitymob/index.html
-
curl -L -o index.html https://huggingface.co/spaces/edulisboa/acitymob/resolve/main/index.html
31.3 kB
| <html lang="pt-BR"> | |
| <head> | |
| <meta charset="UTF-8"> | |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> | |
| <title>Jacareí Transporte Oficial</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> | |
| .map-container { | |
| height: 300px; | |
| background-color: #e5e7eb; | |
| position: relative; | |
| overflow: hidden; | |
| } | |
| .map-placeholder { | |
| position: absolute; | |
| top: 50%; | |
| left: 50%; | |
| transform: translate(-50%, -50%); | |
| text-align: center; | |
| color: #6b7280; | |
| } | |
| .driver-avatar { | |
| width: 50px; | |
| height: 50px; | |
| border-radius: 50%; | |
| border: 2px solid #3b82f6; | |
| } | |
| .slide-up { | |
| animation: slideUp 0.3s ease-out; | |
| } | |
| @keyframes slideUp { | |
| from { transform: translateY(100%); } | |
| to { transform: translateY(0); } | |
| } | |
| .pulse { | |
| animation: pulse 2s infinite; | |
| } | |
| @keyframes pulse { | |
| 0% { transform: scale(1); } | |
| 50% { transform: scale(1.05); } | |
| 100% { transform: scale(1); } | |
| } | |
| </style> | |
| </head> | |
| <body class="bg-gray-100 font-sans"> | |
| <!-- Login Screen --> | |
| <div id="login-screen" class="min-h-screen flex flex-col justify-center items-center p-4 bg-gradient-to-b from-blue-600 to-blue-800 text-white"> | |
| <div class="bg-white rounded-lg shadow-xl p-8 w-full max-w-md text-gray-800"> | |
| <div class="flex justify-center mb-6"> | |
| <img src="https://via.placeholder.com/80" alt="Prefeitura de Jacareí" class="h-20"> | |
| </div> | |
| <h1 class="text-2xl font-bold text-center mb-2 text-blue-800">Jacareí Transporte Oficial</h1> | |
| <p class="text-center text-gray-600 mb-8">Serviço exclusivo para servidores municipais</p> | |
| <div class="mb-4"> | |
| <label class="block text-gray-700 text-sm font-bold mb-2" for="email">E-mail Institucional</label> | |
| <input id="email" type="email" class="w-full px-4 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="seu.email@jacarei.sp.gov.br"> | |
| </div> | |
| <div class="mb-6"> | |
| <label class="block text-gray-700 text-sm font-bold mb-2" for="password">Senha</label> | |
| <input id="password" type="password" class="w-full px-4 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="••••••••"> | |
| </div> | |
| <button onclick="login()" class="w-full bg-blue-600 hover:bg-blue-700 text-white font-bold py-3 px-4 rounded-lg transition duration-200 flex items-center justify-center"> | |
| <i class="fas fa-sign-in-alt mr-2"></i> Entrar | |
| </button> | |
| <div class="mt-6 text-center text-sm text-gray-500"> | |
| <p>Problemas para acessar? Contate o <a href="#" class="text-blue-600 hover:underline">suporte TI</a></p> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Main App (hidden initially) --> | |
| <div id="app-container" class="hidden"> | |
| <!-- Header --> | |
| <header class="bg-blue-700 text-white p-4 shadow-md"> | |
| <div class="flex justify-between items-center"> | |
| <div class="flex items-center"> | |
| <img src="https://via.placeholder.com/40" alt="Logo" class="h-10 mr-2"> | |
| <h1 class="font-bold text-lg">Transporte Oficial</h1> | |
| </div> | |
| <div class="flex items-center space-x-3"> | |
| <button id="profile-btn" class="bg-blue-600 hover:bg-blue-800 rounded-full p-2 transition"> | |
| <i class="fas fa-user"></i> | |
| </button> | |
| <button id="menu-btn" class="bg-blue-600 hover:bg-blue-800 rounded-full p-2 transition"> | |
| <i class="fas fa-bars"></i> | |
| </button> | |
| </div> | |
| </div> | |
| </header> | |
| <!-- Main Content --> | |
| <main class="pb-24"> | |
| <!-- Home Screen --> | |
| <div id="home-screen" class="p-4"> | |
| <div class="bg-white rounded-xl shadow-md p-4 mb-4"> | |
| <h2 class="font-bold text-lg mb-3 text-gray-800">Solicitar transporte</h2> | |
| <div class="map-container rounded-lg mb-4"> | |
| <div class="map-placeholder"> | |
| <i class="fas fa-map-marked-alt text-4xl mb-2"></i> | |
| <p>Carregando mapa...</p> | |
| </div> | |
| </div> | |
| <div class="mb-3"> | |
| <label class="block text-gray-700 text-sm font-bold mb-1">Local de partida</label> | |
| <div class="flex items-center bg-gray-100 rounded-lg p-3"> | |
| <i class="fas fa-map-marker-alt text-blue-600 mr-2"></i> | |
| <span id="current-location" class="text-gray-700">Minha localização atual</span> | |
| </div> | |
| </div> | |
| <div class="mb-4"> | |
| <label class="block text-gray-700 text-sm font-bold mb-1">Destino</label> | |
| <div class="relative"> | |
| <input id="destination-input" type="text" class="w-full px-4 py-3 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="Digite o destino ou selecione abaixo"> | |
| <button class="absolute right-3 top-3 text-gray-500"> | |
| <i class="fas fa-search"></i> | |
| </button> | |
| </div> | |
| </div> | |
| <div class="mb-4"> | |
| <h3 class="text-sm font-semibold text-gray-600 mb-2">LOCAIS FREQUENTES</h3> | |
| <div class="grid grid-cols-2 gap-2"> | |
| <button onclick="selectDestination('Prefeitura Municipal')" class="bg-gray-100 hover:bg-gray-200 rounded-lg p-3 text-left transition"> | |
| <i class="fas fa-landmark text-blue-600 mr-2"></i> Prefeitura | |
| </button> | |
| <button onclick="selectDestination('Hospital Municipal')" class="bg-gray-100 hover:bg-gray-200 rounded-lg p-3 text-left transition"> | |
| <i class="fas fa-hospital text-red-600 mr-2"></i> Hospital | |
| </button> | |
| <button onclick="selectDestination('Secretaria de Educação')" class="bg-gray-100 hover:bg-gray-200 rounded-lg p-3 text-left transition"> | |
| <i class="fas fa-school text-yellow-600 mr-2"></i> Educação | |
| </button> | |
| <button onclick="selectDestination('Secretaria de Obras')" class="bg-gray-100 hover:bg-gray-200 rounded-lg p-3 text-left transition"> | |
| <i class="fas fa-hard-hat text-green-600 mr-2"></i> Obras | |
| </button> | |
| </div> | |
| </div> | |
| <button id="request-ride-btn" onclick="requestRide()" class="w-full bg-blue-600 hover:bg-blue-700 text-white font-bold py-3 px-4 rounded-lg transition duration-200 mt-2 flex items-center justify-center pulse"> | |
| <i class="fas fa-car mr-2"></i> Solicitar Veículo | |
| </button> | |
| </div> | |
| <div class="bg-white rounded-xl shadow-md p-4"> | |
| <h2 class="font-bold text-lg mb-3 text-gray-800">Histórico recente</h2> | |
| <div class="space-y-3"> | |
| <div class="flex items-center p-2 border-b"> | |
| <div class="bg-blue-100 rounded-full p-3 mr-3"> | |
| <i class="fas fa-car text-blue-600"></i> | |
| </div> | |
| <div> | |
| <p class="font-medium">Prefeitura → Hospital</p> | |
| <p class="text-sm text-gray-500">15/06/2023 - 14:30</p> | |
| </div> | |
| </div> | |
| <div class="flex items-center p-2 border-b"> | |
| <div class="bg-green-100 rounded-full p-3 mr-3"> | |
| <i class="fas fa-car text-green-600"></i> | |
| </div> | |
| <div> | |
| <p class="font-medium">Educação → Obras</p> | |
| <p class="text-sm text-gray-500">14/06/2023 - 10:15</p> | |
| </div> | |
| </div> | |
| </div> | |
| <button class="text-blue-600 font-medium mt-3 w-full text-center py-2"> | |
| Ver histórico completo | |
| </button> | |
| </div> | |
| </div> | |
| <!-- Ride Requested Screen (hidden initially) --> | |
| <div id="ride-requested-screen" class="hidden p-4"> | |
| <div class="bg-white rounded-xl shadow-md p-4 mb-4"> | |
| <div class="text-center mb-6"> | |
| <div class="inline-block bg-blue-100 rounded-full p-4 mb-3"> | |
| <i class="fas fa-car text-blue-600 text-3xl"></i> | |
| </div> | |
| <h2 class="font-bold text-xl mb-1">Solicitação enviada</h2> | |
| <p class="text-gray-600">Aguardando motorista disponível</p> | |
| </div> | |
| <div class="flex justify-between items-center mb-6"> | |
| <div> | |
| <p class="text-gray-500 text-sm">De</p> | |
| <p class="font-medium">Minha localização</p> | |
| </div> | |
| <div class="w-10 h-10 bg-blue-100 rounded-full flex items-center justify-center"> | |
| <i class="fas fa-arrow-right text-blue-600"></i> | |
| </div> | |
| <div> | |
| <p class="text-gray-500 text-sm">Para</p> | |
| <p id="destination-display" class="font-medium">Hospital Municipal</p> | |
| </div> | |
| </div> | |
| <div class="bg-gray-100 rounded-lg p-3 mb-4"> | |
| <div class="flex justify-between mb-2"> | |
| <span class="text-gray-600">Tempo estimado:</span> | |
| <span class="font-medium">5-7 minutos</span> | |
| </div> | |
| <div class="flex justify-between"> | |
| <span class="text-gray-600">Distância:</span> | |
| <span class="font-medium">2,3 km</span> | |
| </div> | |
| </div> | |
| <button id="cancel-ride-btn" onclick="cancelRide()" class="w-full bg-red-100 hover:bg-red-200 text-red-600 font-bold py-3 px-4 rounded-lg transition duration-200"> | |
| Cancelar solicitação | |
| </button> | |
| </div> | |
| </div> | |
| <!-- Driver Assigned Screen (hidden initially) --> | |
| <div id="driver-assigned-screen" class="hidden p-4"> | |
| <div class="bg-white rounded-xl shadow-md p-4 mb-4"> | |
| <div class="text-center mb-6"> | |
| <div class="inline-block bg-green-100 rounded-full p-4 mb-3"> | |
| <i class="fas fa-check-circle text-green-600 text-3xl"></i> | |
| </div> | |
| <h2 class="font-bold text-xl mb-1">Motorista encontrado!</h2> | |
| <p class="text-gray-600">Seu veículo está a caminho</p> | |
| </div> | |
| <div class="flex items-center justify-center mb-6"> | |
| <img src="https://via.placeholder.com/80" alt="Motorista" class="driver-avatar mr-4"> | |
| <div> | |
| <p class="font-bold">João Silva</p> | |
| <p class="text-gray-600">Placa: ABC-1234</p> | |
| <div class="flex items-center mt-1"> | |
| <i class="fas fa-star text-yellow-400 mr-1"></i> | |
| <span class="font-medium">4.9</span> | |
| <span class="text-gray-500 text-sm ml-1">(42 avaliações)</span> | |
| </div> | |
| </div> | |
| </div> | |
| <div class="map-container rounded-lg mb-4"> | |
| <div class="map-placeholder"> | |
| <i class="fas fa-car-side text-4xl mb-2 text-blue-600"></i> | |
| <p>Motorista a 1,2 km de distância</p> | |
| </div> | |
| </div> | |
| <div class="bg-gray-100 rounded-lg p-3 mb-4"> | |
| <div class="flex justify-between mb-2"> | |
| <span class="text-gray-600">Tempo estimado:</span> | |
| <span class="font-medium">3 minutos</span> | |
| </div> | |
| <div class="flex justify-between"> | |
| <span class="text-gray-600">Veículo:</span> | |
| <span class="font-medium">Fiat Toro - Preto</span> | |
| </div> | |
| </div> | |
| <div class="flex space-x-3"> | |
| <button class="flex-1 bg-blue-100 hover:bg-blue-200 text-blue-600 font-medium py-3 px-4 rounded-lg transition duration-200 flex items-center justify-center"> | |
| <i class="fas fa-phone-alt mr-2"></i> Ligar | |
| </button> | |
| <button onclick="cancelRide()" class="flex-1 bg-red-100 hover:bg-red-200 text-red-600 font-medium py-3 px-4 rounded-lg transition duration-200 flex items-center justify-center"> | |
| <i class="fas fa-times mr-2"></i> Cancelar | |
| </button> | |
| </div> | |
| </div> | |
| </div> | |
| <!-- Ride In Progress Screen (hidden initially) --> | |
| <div id="ride-in-progress-screen" class="hidden p-4"> | |
| <div class="bg-white rounded-xl shadow-md p-4 mb-4"> | |
| <div class="text-center mb-6"> | |
| <h2 class="font-bold text-xl mb-1">Em andamento</h2> | |
| <p class="text-gray-600">Você está a caminho do destino</p> | |
| </div> | |
| <div class="map-container rounded-lg mb-4"> | |
| <div class="map-placeholder"> | |
| <i class="fas fa-route text-4xl mb-2 text-blue-600"></i> | |
| <p>Rota em andamento</p> | |
| </div> | |
| </div> | |
| <div class="flex items-center justify-between mb-6 p-3 bg-gray-100 rounded-lg"> | |
| <div class="flex items-center"> | |
| <img src="https://via.placeholder.com/50" alt="Motorista" class="w-10 h-10 rounded-full mr-3"> | |
| <div> | |
| <p class="font-bold">João Silva</p> | |
| <p class="text-gray-600 text-sm">Fiat Toro - ABC-1234</p> | |
| </div> | |
| </div> | |
| <button class="bg-blue-600 hover:bg-blue-700 text-white rounded-full p-2"> | |
| <i class="fas fa-phone-alt"></i> | |
| </button> | |
| </div> | |
| <div class="bg-gray-100 rounded-lg p-3 mb-4"> | |
| <div class="flex justify-between mb-2"> | |
| <span class="text-gray-600">Destino:</span> | |
| <span id="current-destination" class="font-medium">Hospital Municipal</span> | |
| </div> | |
| <div class="flex justify-between mb-2"> | |
| <span class="text-gray-600">Tempo restante:</span> | |
| <span class="font-medium">~2 minutos</span> | |
| </div> | |
| <div class="flex justify-between"> | |
| <span class="text-gray-600">Distância:</span> | |
| <span class="font-medium">0,7 km</span> | |
| </div> | |
| </div> | |
| <button onclick="completeRide()" class="w-full bg-blue-600 hover:bg-blue-700 text-white font-bold py-3 px-4 rounded-lg transition duration-200 flex items-center justify-center"> | |
| <i class="fas fa-flag-checkered mr-2"></i> Cheguei no destino | |
| </button> | |
| </div> | |
| </div> | |
| <!-- Ride Completed Screen (hidden initially) --> | |
| <div id="ride-completed-screen" class="hidden p-4"> | |
| <div class="bg-white rounded-xl shadow-md p-4 mb-4"> | |
| <div class="text-center mb-6"> | |
| <div class="inline-block bg-green-100 rounded-full p-4 mb-3"> | |
| <i class="fas fa-check-circle text-green-600 text-3xl"></i> | |
| </div> | |
| <h2 class="font-bold text-xl mb-1">Corrida finalizada</h2> | |
| <p class="text-gray-600">Obrigado por utilizar o Transporte Oficial</p> | |
| </div> | |
| <div class="bg-gray-100 rounded-lg p-3 mb-6"> | |
| <div class="flex justify-between mb-2"> | |
| <span class="text-gray-600">De:</span> | |
| <span class="font-medium">Minha localização</span> | |
| </div> | |
| <div class="flex justify-between mb-2"> | |
| <span class="text-gray-600">Para:</span> | |
| <span id="completed-destination" class="font-medium">Hospital Municipal</span> | |
| </div> | |
| <div class="flex justify-between mb-2"> | |
| <span class="text-gray-600">Motorista:</span> | |
| <span class="font-medium">João Silva</span> | |
| </div> | |
| <div class="flex justify-between mb-2"> | |
| <span class="text-gray-600">Veículo:</span> | |
| <span class="font-medium">Fiat Toro - ABC-1234</span> | |
| </div> | |
| <div class="flex justify-between"> | |
| <span class="text-gray-600">Duração:</span> | |
| <span class="font-medium">7 minutos</span> | |
| </div> | |
| </div> | |
| <div class="mb-6"> | |
| <h3 class="font-bold text-lg mb-3 text-gray-800">Avalie o serviço</h3> | |
| <div class="flex justify-center space-x-2 mb-4"> | |
| <i class="fas fa-star text-2xl text-gray-300 hover:text-yellow-400 cursor-pointer" onmouseover="hoverStar(1)" onclick="rateStar(1)"></i> | |
| <i class="fas fa-star text-2xl text-gray-300 hover:text-yellow-400 cursor-pointer" onmouseover="hoverStar(2)" onclick="rateStar(2)"></i> | |
| <i class="fas fa-star text-2xl text-gray-300 hover:text-yellow-400 cursor-pointer" onmouseover="hoverStar(3)" onclick="rateStar(3)"></i> | |
| <i class="fas fa-star text-2xl text-gray-300 hover:text-yellow-400 cursor-pointer" onmouseover="hoverStar(4)" onclick="rateStar(4)"></i> | |
| <i class="fas fa-star text-2xl text-gray-300 hover:text-yellow-400 cursor-pointer" onmouseover="hoverStar(5)" onclick="rateStar(5)"></i> | |
| </div> | |
| <textarea class="w-full px-4 py-2 border rounded-lg focus:outline-none focus:ring-2 focus:ring-blue-500" placeholder="Comentários (opcional)" rows="2"></textarea> | |
| </div> | |
| <button onclick="returnHome()" class="w-full bg-blue-600 hover:bg-blue-700 text-white font-bold py-3 px-4 rounded-lg transition duration-200"> | |
| Voltar ao início | |
| </button> | |
| </div> | |
| </div> | |
| </main> | |
| <!-- Bottom Navigation --> | |
| <nav class="fixed bottom-0 left-0 right-0 bg-white shadow-lg border-t border-gray-200 flex justify-around items-center p-2"> | |
| <button class="flex flex-col items-center p-2 text-blue-600"> | |
| <i class="fas fa-home text-xl"></i> | |
| <span class="text-xs mt-1">Início</span> | |
| </button> | |
| <button class="flex flex-col items-center p-2 text-gray-500"> | |
| <i class="fas fa-history text-xl"></i> | |
| <span class="text-xs mt-1">Histórico</span> | |
| </button> | |
| <button class="flex flex-col items-center p-2 text-gray-500"> | |
| <i class="fas fa-cog text-xl"></i> | |
| <span class="text-xs mt-1">Configurações</span> | |
| </button> | |
| <button class="flex flex-col items-center p-2 text-gray-500"> | |
| <i class="fas fa-question-circle text-xl"></i> | |
| <span class="text-xs mt-1">Ajuda</span> | |
| </button> | |
| </nav> | |
| <!-- Side Menu (hidden initially) --> | |
| <div id="side-menu" class="fixed inset-0 bg-black bg-opacity-50 z-50 hidden"> | |
| <div class="absolute right-0 top-0 bottom-0 bg-white w-64 shadow-lg slide-up"> | |
| <div class="p-4 border-b border-gray-200 flex items-center"> | |
| <img src="https://via.placeholder.com/40" alt="Usuário" class="rounded-full mr-3"> | |
| <div> | |
| <p class="font-bold">Maria Oliveira</p> | |
| <p class="text-sm text-gray-600">maria.oliveira@jacarei.sp.gov.br</p> | |
| </div> | |
| </div> | |
| <div class="p-2"> | |
| <button class="w-full text-left p-3 rounded-lg hover:bg-gray-100 flex items-center"> | |
| <i class="fas fa-user-circle text-gray-500 mr-3 w-6 text-center"></i> | |
| <span>Meu perfil</span> | |
| </button> | |
| <button class="w-full text-left p-3 rounded-lg hover:bg-gray-100 flex items-center"> | |
| <i class="fas fa-history text-gray-500 mr-3 w-6 text-center"></i> | |
| <span>Histórico completo</span> | |
| </button> | |
| <button class="w-full text-left p-3 rounded-lg hover:bg-gray-100 flex items-center"> | |
| <i class="fas fa-car text-gray-500 mr-3 w-6 text-center"></i> | |
| <span>Veículos disponíveis</span> | |
| </button> | |
| <button class="w-full text-left p-3 rounded-lg hover:bg-gray-100 flex items-center"> | |
| <i class="fas fa-question-circle text-gray-500 mr-3 w-6 text-center"></i> | |
| <span>Ajuda e suporte</span> | |
| </button> | |
| <button class="w-full text-left p-3 rounded-lg hover:bg-gray-100 flex items-center"> | |
| <i class="fas fa-cog text-gray-500 mr-3 w-6 text-center"></i> | |
| <span>Configurações</span> | |
| </button> | |
| </div> | |
| <div class="absolute bottom-0 left-0 right-0 p-4 border-t border-gray-200"> | |
| <button onclick="logout()" class="w-full bg-red-100 hover:bg-red-200 text-red-600 font-medium py-2 px-4 rounded-lg transition duration-200 flex items-center justify-center"> | |
| <i class="fas fa-sign-out-alt mr-2"></i> Sair | |
| </button> | |
| </div> | |
| </div> | |
| </div> | |
| </div> | |
| <script> | |
| // App state | |
| let currentDestination = ''; | |
| let currentRating = 0; | |
| // DOM elements | |
| const loginScreen = document.getElementById('login-screen'); | |
| const appContainer = document.getElementById('app-container'); | |
| const homeScreen = document.getElementById('home-screen'); | |
| const rideRequestedScreen = document.getElementById('ride-requested-screen'); | |
| const driverAssignedScreen = document.getElementById('driver-assigned-screen'); | |
| const rideInProgressScreen = document.getElementById('ride-in-progress-screen'); | |
| const rideCompletedScreen = document.getElementById('ride-completed-screen'); | |
| const sideMenu = document.getElementById('side-menu'); | |
| const destinationInput = document.getElementById('destination-input'); | |
| const destinationDisplay = document.getElementById('destination-display'); | |
| const currentDestination = document.getElementById('current-destination'); | |
| const completedDestination = document.getElementById('completed-destination'); | |
| // Login function | |
| function login() { | |
| const email = document.getElementById('email').value; | |
| const password = document.getElementById('password').value; | |
| // Simple validation | |
| if (email && password) { | |
| loginScreen.classList.add('hidden'); | |
| appContainer.classList.remove('hidden'); | |
| } else { | |
| alert('Por favor, preencha todos os campos.'); | |
| } | |
| } | |
| // Logout function | |
| function logout() { | |
| hideSideMenu(); | |
| appContainer.classList.add('hidden'); | |
| loginScreen.classList.remove('hidden'); | |
| returnHome(); | |
| } | |
| // Show side menu | |
| document.getElementById('menu-btn').addEventListener('click', () => { | |
| sideMenu.classList.remove('hidden'); | |
| }); | |
| // Hide side menu | |
| function hideSideMenu() { | |
| sideMenu.classList.add('hidden'); | |
| } | |
| // Click outside to close menu | |
| sideMenu.addEventListener('click', (e) => { | |
| if (e.target === sideMenu) { | |
| hideSideMenu(); | |
| } | |
| }); | |
| // Select destination from quick buttons | |
| function selectDestination(destination) { | |
| currentDestination = destination; | |
| destinationInput.value = destination; | |
| } | |
| // Request ride | |
| function requestRide() { | |
| const destination = destinationInput.value.trim(); | |
| if (!destination) { | |
| alert('Por favor, informe o destino.'); | |
| return; | |
| } | |
| currentDestination = destination; | |
| homeScreen.classList.add('hidden'); | |
| rideRequestedScreen.classList.remove('hidden'); | |
| // Simulate driver assignment after 3 seconds | |
| setTimeout(() => { | |
| rideRequestedScreen.classList.add('hidden'); | |
| driverAssignedScreen.classList.remove('hidden'); | |
| destinationDisplay.textContent = currentDestination; | |
| // Simulate ride start after 5 seconds | |
| setTimeout(() => { | |
| driverAssignedScreen.classList.add('hidden'); | |
| rideInProgressScreen.classList.remove('hidden'); | |
| currentDestination.textContent = currentDestination; | |
| }, 5000); | |
| }, 3000); | |
| } | |
| // Cancel ride | |
| function cancelRide() { | |
| if (confirm('Tem certeza que deseja cancelar esta corrida?')) { | |
| rideRequestedScreen.classList.add('hidden'); | |
| driverAssignedScreen.classList.add('hidden'); | |
| rideInProgressScreen.classList.add('hidden'); | |
| homeScreen.classList.remove('hidden'); | |
| } | |
| } | |
| // Complete ride | |
| function completeRide() { | |
| rideInProgressScreen.classList.add('hidden'); | |
| rideCompletedScreen.classList.remove('hidden'); | |
| completedDestination.textContent = currentDestination; | |
| } | |
| // Return to home screen | |
| function returnHome() { | |
| rideCompletedScreen.classList.add('hidden'); | |
| homeScreen.classList.remove('hidden'); | |
| currentDestination = ''; | |
| destinationInput.value = ''; | |
| } | |
| // Star rating hover effect | |
| function hoverStar(num) { | |
| const stars = document.querySelectorAll('.fa-star'); | |
| stars.forEach((star, index) => { | |
| if (index < num) { | |
| star.classList.add('text-yellow-400'); | |
| star.classList.remove('text-gray-300'); | |
| } else { | |
| star.classList.add('text-gray-300'); | |
| star.classList.remove('text-yellow-400'); | |
| } | |
| }); | |
| } | |
| // Rate with stars | |
| function rateStar(num) { | |
| currentRating = num; | |
| const stars = document.querySelectorAll('.fa-star'); | |
| stars.forEach((star, index) => { | |
| if (index < num) { | |
| star.classList.add('text-yellow-400'); | |
| star.classList.remove('text-gray-300'); | |
| } else { | |
| star.classList.add('text-gray-300'); | |
| star.classList.remove('text-yellow-400'); | |
| } | |
| }); | |
| } | |
| </script> | |
| <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=edulisboa/acitymob" style="color: #fff;text-decoration: underline;" target="_blank" >Remix</a></p></body> | |
| </html> |