Feat Prototipos Widgets y Fix Worker Telegramas
This commit is contained in:
		| @@ -1,25 +1,27 @@ | ||||
| /* src/components/MapaBsAs.css */ | ||||
| :root { | ||||
|   --primary-accent-color: #FF5722; | ||||
|   --background-panel-color: #2f2f2f; | ||||
|   --border-color: #444; | ||||
|   --text-color: #f0f0f0; | ||||
|   --text-color-muted: #aaa; | ||||
|   --progress-bar-background: #4a4a4a; | ||||
|   --scrollbar-thumb-color: #666; | ||||
|   --scrollbar-track-color: #333; | ||||
|   --map-background-color: #242424; /* Color de fondo del mapa */ | ||||
|   --primary-accent-color: #0073e6; | ||||
|   --background-panel-color: #ffffff; | ||||
|   --border-color: #dee2e6; | ||||
|   --text-color: #212529; | ||||
|   --text-color-muted: #6c757d; | ||||
|   --progress-bar-background: #e9ecef; | ||||
|   --scrollbar-thumb-color: #ced4da; | ||||
|   --scrollbar-track-color: #f1f1f1; | ||||
|   --map-background-color: #f8f9fa; | ||||
| } | ||||
|  | ||||
| .mapa-wrapper { | ||||
|   display: flex; | ||||
|   gap: 1.5rem; | ||||
|   background-color: var(--map-background-color); | ||||
|   background-color: #ffffff; | ||||
|   border: 1px solid var(--border-color); | ||||
|   box-shadow: 0 2px 5px rgba(0, 0, 0, 0.05); | ||||
|   padding: 1rem; | ||||
|   border-radius: 12px; | ||||
|   max-width: 1600px; /* Incrementado para pantallas más grandes */ | ||||
|   border-radius: 8px; | ||||
|   max-width: 1600px; | ||||
|   margin: auto; | ||||
|   height: 88vh; /* Ligeramente más alto */ | ||||
|   height: 88vh; | ||||
|   min-height: 650px; | ||||
| } | ||||
|  | ||||
| @@ -30,7 +32,6 @@ | ||||
|   border-radius: 8px; | ||||
|   position: relative; | ||||
|   overflow: hidden; | ||||
|   /* CORRECCIÓN: Se añade el color de fondo para eliminar el marco blanco */ | ||||
|   background-color: var(--map-background-color); | ||||
| } | ||||
|  | ||||
| @@ -43,46 +44,47 @@ | ||||
| } | ||||
|  | ||||
| .rsm-geography { | ||||
|   transition: opacity 0.3s ease-in-out, transform 0.2s ease-in-out, filter 0.2s ease-in-out, fill 0.3s ease; | ||||
|   transition: opacity 0.3s ease, transform 0.2s ease, filter 0.2s ease, fill 0.3s ease; | ||||
|   cursor: pointer; | ||||
|   stroke-width: 1px; | ||||
|   stroke: #b0b0b0; | ||||
|   stroke-width: 0.5px; | ||||
| } | ||||
|  | ||||
| .rsm-geography:hover { | ||||
|   filter: drop-shadow(0px 0px 6px rgba(255, 255, 255, 0.6)); | ||||
|   transform: translateY(-1px); | ||||
|   stroke: var(--primary-accent-color); | ||||
|   stroke-width: 1.5px; | ||||
|   filter: brightness(1.05); | ||||
| } | ||||
|  | ||||
| .rsm-geography.selected { | ||||
|   fill: var(--primary-accent-color); /* Rellena el partido seleccionado con el color principal */ | ||||
|   stroke: #ffffff; /* Añade un borde blanco para un mejor contraste */ | ||||
|   stroke-width: 2px; /* Un grosor de borde definido */ | ||||
|   filter: none; /* Elimina el efecto de sombra/resplandor */ | ||||
|   outline: none; /* Previene el recuadro de enfoque del navegador */ | ||||
|   pointer-events: none; /* Mantenemos esto para evitar interacciones no deseadas */ | ||||
|   stroke: #333; | ||||
|   stroke-width: 2px; | ||||
|   filter: none; | ||||
|   pointer-events: none; | ||||
| } | ||||
|  | ||||
| .rsm-geography.faded { | ||||
|   opacity: 0.15; | ||||
|   opacity: 0.25; | ||||
|   pointer-events: none; | ||||
| } | ||||
|  | ||||
| .info-panel { | ||||
|   flex: 1; | ||||
|   height: 100%; | ||||
|   background-color: var(--background-panel-color); | ||||
|   border-radius: 8px; | ||||
|   display: flex; | ||||
|   flex-direction: column; | ||||
|   overflow-y: auto; | ||||
|   min-height: 0; | ||||
|   background-color: var(--background-panel-color); | ||||
|   border-radius: 8px; | ||||
|   padding: 1.5rem; | ||||
|   border: none; | ||||
| } | ||||
|  | ||||
| .info-panel::-webkit-scrollbar { width: 8px; } | ||||
| .info-panel::-webkit-scrollbar-track { background: var(--scrollbar-track-color); border-radius: 4px; } | ||||
| .info-panel::-webkit-scrollbar-thumb { background-color: var(--scrollbar-thumb-color); border-radius: 4px; border: 2px solid var(--scrollbar-track-color); } | ||||
| .info-panel::-webkit-scrollbar-thumb:hover { background-color: #888; } | ||||
| .info-panel::-webkit-scrollbar-thumb:hover { background-color: #adb5bd; } | ||||
|  | ||||
| .info-panel h3 { margin-top: 0; color: var(--primary-accent-color); border-bottom: 2px solid var(--border-color); padding-bottom: 0.5rem; } | ||||
| .info-panel p { color: var(--text-color-muted); } | ||||
|  | ||||
| @@ -91,14 +93,17 @@ | ||||
| } | ||||
| .reset-button-panel:hover { background-color: var(--primary-accent-color); color: white; } | ||||
|  | ||||
| .detalle-placeholder { text-align: center; margin: auto; } | ||||
| .detalle-loading, .detalle-error { text-align: center; margin: auto; color: var(--text-color-muted); } | ||||
| .detalle-placeholder {  | ||||
|   text-align: center;  | ||||
|   margin: auto 0;  | ||||
| } | ||||
| .detalle-loading, .detalle-error { text-align: center; margin: auto 0; color: var(--text-color-muted); } | ||||
| .detalle-metricas { display: flex; justify-content: space-between; font-size: 0.9em; padding-bottom: 1rem; border-bottom: 1px solid var(--border-color); margin-bottom: 1rem; } | ||||
| .resultados-lista { list-style: none; padding: 0; margin: 0; } | ||||
| .resultados-lista li { margin-bottom: 1rem; } | ||||
| .resultado-info { display: flex; justify-content: space-between; margin-bottom: 0.25rem; font-size: 0.9em; } | ||||
| .partido-nombre { font-weight: 500; } | ||||
| .partido-votos { font-weight: 300; color: var(--text-color-muted); } | ||||
| .partido-votos { font-weight: 400; color: var(--text-color-muted); } | ||||
| .progress-bar { height: 8px; background-color: var(--progress-bar-background); border-radius: 4px; overflow: hidden; } | ||||
| .progress-fill { height: 100%; background-color: var(--primary-accent-color); border-radius: 4px; transition: width 0.5s ease-out; } | ||||
|  | ||||
| @@ -112,14 +117,81 @@ | ||||
|   display: flex; | ||||
|   flex-direction: column; | ||||
|   gap: 5px; | ||||
|   z-index: 10; /* <-- AÑADIDO: Esta línea asegura que los controles estén por encima del mapa. */ | ||||
|   z-index: 10; | ||||
| } | ||||
| .map-controls button { | ||||
|   width: 32px; height: 32px; font-size: 1.2rem; font-weight: bold; background-color: rgba(0, 0, 0, 0.7); color: white; border: 1px solid var(--border-color); border-radius: 4px; cursor: pointer; transition: all 0.2s; display: flex; align-items: center; justify-content: center; padding: 0; line-height: 1; | ||||
| } | ||||
| .map-controls button:hover { background-color: rgba(0, 0, 0, 0.9); border-color: var(--primary-accent-color); } | ||||
|  | ||||
| .legend { margin-top: auto; padding-top: 1rem; border-top: 1px solid var(--border-color); } | ||||
| .legend h4 { margin-top: 0; } | ||||
| /* --- ESTILOS PARA EL BOTÓN DE "VOLVER" (VISTA DESKTOP) --- */ | ||||
| .map-controls button { | ||||
|   /* Se elimina el ancho y alto fijos para que el botón se ajuste al texto. */ | ||||
|   width: auto; | ||||
|   height: auto; | ||||
|   /* Se define un padding para dar espacio interno al texto. */ | ||||
|   padding: 0.5rem 1rem; | ||||
|   /* Se ajusta el tamaño de fuente para el texto. */ | ||||
|   font-size: 0.9em; | ||||
|   font-weight: bold; | ||||
|   background-color: #ffffff; | ||||
|   color: #333; | ||||
|   border: 1px solid var(--border-color); | ||||
|   box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1); | ||||
|   border-radius: 4px; | ||||
|   cursor: pointer; | ||||
|   transition: all 0.2s; | ||||
|   /* Se eliminan las propiedades de centrado de íconos que ya no son necesarias. */ | ||||
| } | ||||
| .map-controls button:hover { | ||||
|   background-color: #f8f9fa; | ||||
|   border-color: var(--primary-accent-color); | ||||
|   color: var(--primary-accent-color); | ||||
| } | ||||
|  | ||||
| .legend { | ||||
|   padding-top: 1rem; | ||||
|   border-top: 1px solid var(--border-color); | ||||
| } | ||||
| .legend h4 { | ||||
|   margin-top: 0; | ||||
| } | ||||
| .legend-item { display: flex; align-items: center; margin-bottom: 0.5rem; font-size: 0.85em; } | ||||
| .legend-color-box { width: 16px; height: 16px; margin-right: 8px; border-radius: 3px; } | ||||
| .legend-color-box { width: 16px; height: 16px; margin-right: 8px; border-radius: 3px; border: 1px solid #ccc; } | ||||
|  | ||||
| /* --- ESTILOS PARA RESPONSIVIDAD MÓVIL --- */ | ||||
| @media (max-width: 992px) { | ||||
|   .mapa-wrapper { | ||||
|     flex-direction: column; | ||||
|     height: auto; | ||||
|     min-height: 100vh; | ||||
|     padding: 0.5rem; | ||||
|   } | ||||
|  | ||||
|   .mapa-container { | ||||
|     flex-basis: auto; | ||||
|     width: 100%; | ||||
|     height: 50vh; | ||||
|     min-height: 400px; | ||||
|   } | ||||
|  | ||||
|   .info-panel { | ||||
|     flex-basis: auto; | ||||
|     width: 100%; | ||||
|     height: auto; | ||||
|     overflow-y: visible; | ||||
|     box-sizing: border-box; | ||||
|   } | ||||
|  | ||||
|   .map-controls { | ||||
|     top: 10px; | ||||
|     right: 10px; | ||||
|   } | ||||
|  | ||||
|   /* --- ESTILOS PARA EL BOTÓN DE "VOLVER" (VISTA MÓVIL) --- */ | ||||
|   .map-controls button { | ||||
|     /* Se elimina el ancho y alto fijos para que el botón se ajuste al texto. */ | ||||
|     width: auto; | ||||
|     height: auto; | ||||
|     /* Se ajusta el padding para que sea un buen objetivo táctil (tappable). */ | ||||
|     padding: 0.6rem 1.2rem; | ||||
|     /* Un tamaño de fuente legible en móviles. */ | ||||
|     font-size: 1em; | ||||
|   } | ||||
| } | ||||
		Reference in New Issue
	
	Block a user