Pre Refinamiento Movil
This commit is contained in:
44
Elecciones-Web/frontend/package-lock.json
generated
44
Elecciones-Web/frontend/package-lock.json
generated
@@ -17,7 +17,9 @@
|
|||||||
"d3-geo": "^3.1.1",
|
"d3-geo": "^3.1.1",
|
||||||
"d3-shape": "^3.2.0",
|
"d3-shape": "^3.2.0",
|
||||||
"react": "^19.1.1",
|
"react": "^19.1.1",
|
||||||
|
"react-circular-progressbar": "^2.2.0",
|
||||||
"react-dom": "^19.1.1",
|
"react-dom": "^19.1.1",
|
||||||
|
"react-icons": "^5.5.0",
|
||||||
"react-pdf": "^10.1.0",
|
"react-pdf": "^10.1.0",
|
||||||
"react-select": "^5.10.2",
|
"react-select": "^5.10.2",
|
||||||
"react-simple-maps": "github:ozimmortal/react-simple-maps#feat/react-19-support",
|
"react-simple-maps": "github:ozimmortal/react-simple-maps#feat/react-19-support",
|
||||||
@@ -2600,9 +2602,9 @@
|
|||||||
"license": "MIT"
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/axios": {
|
"node_modules/axios": {
|
||||||
"version": "1.11.0",
|
"version": "1.12.2",
|
||||||
"resolved": "https://registry.npmjs.org/axios/-/axios-1.11.0.tgz",
|
"resolved": "https://registry.npmjs.org/axios/-/axios-1.12.2.tgz",
|
||||||
"integrity": "sha512-1Lx3WLFQWm3ooKDYZD1eXmoGO9fxYQjrycfHFC8P0sCfQVXyROp0p9PFWBehewBOdCwHc+f/b8I0fMto5eSfwA==",
|
"integrity": "sha512-vMJzPewAlRyOgxV2dU0Cuz2O8zzzx9VYtbJOaBgXFeLc4IV/Eg50n4LowmehOOR61S8ZMpc2K5Sa7g6A4jfkUw==",
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"follow-redirects": "^1.15.6",
|
"follow-redirects": "^1.15.6",
|
||||||
@@ -4443,6 +4445,15 @@
|
|||||||
"node": ">=0.10.0"
|
"node": ">=0.10.0"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/react-circular-progressbar": {
|
||||||
|
"version": "2.2.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/react-circular-progressbar/-/react-circular-progressbar-2.2.0.tgz",
|
||||||
|
"integrity": "sha512-cgyqEHOzB0nWMZjKfWN3MfSa1LV3OatcDjPz68lchXQUEiBD5O1WsAtoVK4/DSL0B4USR//cTdok4zCBkq8X5g==",
|
||||||
|
"license": "MIT",
|
||||||
|
"peerDependencies": {
|
||||||
|
"react": ">=0.14.0"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/react-dom": {
|
"node_modules/react-dom": {
|
||||||
"version": "19.1.1",
|
"version": "19.1.1",
|
||||||
"resolved": "https://registry.npmjs.org/react-dom/-/react-dom-19.1.1.tgz",
|
"resolved": "https://registry.npmjs.org/react-dom/-/react-dom-19.1.1.tgz",
|
||||||
@@ -4455,6 +4466,15 @@
|
|||||||
"react": "^19.1.1"
|
"react": "^19.1.1"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"node_modules/react-icons": {
|
||||||
|
"version": "5.5.0",
|
||||||
|
"resolved": "https://registry.npmjs.org/react-icons/-/react-icons-5.5.0.tgz",
|
||||||
|
"integrity": "sha512-MEFcXdkP3dLo8uumGI5xN3lDFNsRtrjbOEKDLD7yv76v4wpnEq2Lt2qeHaQOr34I/wPN3s3+N08WkQ+CW37Xiw==",
|
||||||
|
"license": "MIT",
|
||||||
|
"peerDependencies": {
|
||||||
|
"react": "*"
|
||||||
|
}
|
||||||
|
},
|
||||||
"node_modules/react-is": {
|
"node_modules/react-is": {
|
||||||
"version": "16.13.1",
|
"version": "16.13.1",
|
||||||
"resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz",
|
"resolved": "https://registry.npmjs.org/react-is/-/react-is-16.13.1.tgz",
|
||||||
@@ -4847,14 +4867,14 @@
|
|||||||
"license": "MIT"
|
"license": "MIT"
|
||||||
},
|
},
|
||||||
"node_modules/tinyglobby": {
|
"node_modules/tinyglobby": {
|
||||||
"version": "0.2.14",
|
"version": "0.2.15",
|
||||||
"resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.14.tgz",
|
"resolved": "https://registry.npmjs.org/tinyglobby/-/tinyglobby-0.2.15.tgz",
|
||||||
"integrity": "sha512-tX5e7OM1HnYr2+a2C/4V0htOcSQcoSTH9KgJnVvNm5zm/cyEWKJ7j7YutsH9CxMdtOkkLFy2AHrMci9IM8IPZQ==",
|
"integrity": "sha512-j2Zq4NyQYG5XMST4cbs02Ak8iJUdxRM0XI5QyxXuZOzKOINmWurp3smXu3y5wDcJrptwpSjgXHzIQxR0omXljQ==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"fdir": "^6.4.4",
|
"fdir": "^6.5.0",
|
||||||
"picomatch": "^4.0.2"
|
"picomatch": "^4.0.3"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=12.0.0"
|
"node": ">=12.0.0"
|
||||||
@@ -5068,9 +5088,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/vite": {
|
"node_modules/vite": {
|
||||||
"version": "7.1.3",
|
"version": "7.1.6",
|
||||||
"resolved": "https://registry.npmjs.org/vite/-/vite-7.1.3.tgz",
|
"resolved": "https://registry.npmjs.org/vite/-/vite-7.1.6.tgz",
|
||||||
"integrity": "sha512-OOUi5zjkDxYrKhTV3V7iKsoS37VUM7v40+HuwEmcrsf11Cdx9y3DIr2Px6liIcZFwt3XSRpQvFpL3WVy7ApkGw==",
|
"integrity": "sha512-SRYIB8t/isTwNn8vMB3MR6E+EQZM/WG1aKmmIUCfDXfVvKfc20ZpamngWHKzAmmu9ppsgxsg4b2I7c90JZudIQ==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"license": "MIT",
|
"license": "MIT",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
@@ -5079,7 +5099,7 @@
|
|||||||
"picomatch": "^4.0.3",
|
"picomatch": "^4.0.3",
|
||||||
"postcss": "^8.5.6",
|
"postcss": "^8.5.6",
|
||||||
"rollup": "^4.43.0",
|
"rollup": "^4.43.0",
|
||||||
"tinyglobby": "^0.2.14"
|
"tinyglobby": "^0.2.15"
|
||||||
},
|
},
|
||||||
"bin": {
|
"bin": {
|
||||||
"vite": "bin/vite.js"
|
"vite": "bin/vite.js"
|
||||||
|
|||||||
@@ -19,7 +19,9 @@
|
|||||||
"d3-geo": "^3.1.1",
|
"d3-geo": "^3.1.1",
|
||||||
"d3-shape": "^3.2.0",
|
"d3-shape": "^3.2.0",
|
||||||
"react": "^19.1.1",
|
"react": "^19.1.1",
|
||||||
|
"react-circular-progressbar": "^2.2.0",
|
||||||
"react-dom": "^19.1.1",
|
"react-dom": "^19.1.1",
|
||||||
|
"react-icons": "^5.5.0",
|
||||||
"react-pdf": "^10.1.0",
|
"react-pdf": "^10.1.0",
|
||||||
"react-select": "^5.10.2",
|
"react-select": "^5.10.2",
|
||||||
"react-simple-maps": "github:ozimmortal/react-simple-maps#feat/react-19-support",
|
"react-simple-maps": "github:ozimmortal/react-simple-maps#feat/react-19-support",
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
@@ -12,7 +12,7 @@
|
|||||||
border-bottom: 1px solid #e0e0e0;
|
border-bottom: 1px solid #e0e0e0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Nuevo contenedor para alinear título y selector */
|
/* Contenedor para alinear título y selector */
|
||||||
.header-top-row {
|
.header-top-row {
|
||||||
display: flex;
|
display: flex;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
@@ -27,26 +27,55 @@
|
|||||||
|
|
||||||
.categoria-selector {
|
.categoria-selector {
|
||||||
min-width: 220px;
|
min-width: 220px;
|
||||||
/* Ancho del selector */
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.breadcrumbs {
|
/* --- ESTILOS MODERNOS PARA BREADCRUMBS --- */
|
||||||
|
|
||||||
|
.breadcrumbs-container {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 0.5rem; /* Espacio entre elementos */
|
||||||
font-size: 0.9rem;
|
font-size: 0.9rem;
|
||||||
color: #666;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.breadcrumb-link {
|
.breadcrumb-item, .breadcrumb-item-actual {
|
||||||
background: none;
|
display: flex;
|
||||||
border: none;
|
align-items: center;
|
||||||
color: #007bff;
|
padding: 0.4rem 0.8rem;
|
||||||
|
border-radius: 8px; /* Bordes redondeados para efecto píldora */
|
||||||
|
transition: background-color 0.2s ease-in-out;
|
||||||
|
}
|
||||||
|
|
||||||
|
.breadcrumb-item {
|
||||||
|
background-color: #f0f0f0;
|
||||||
|
border: 1px solid #e0e0e0;
|
||||||
|
color: #333;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
padding: 0;
|
font-weight: 500;
|
||||||
|
}
|
||||||
|
|
||||||
|
.breadcrumb-item:hover {
|
||||||
|
background-color: #e0e0e0;
|
||||||
|
border-color: #d1d1d1;
|
||||||
|
}
|
||||||
|
|
||||||
|
.breadcrumb-item-actual {
|
||||||
|
background-color: transparent;
|
||||||
|
color: #000;
|
||||||
|
font-weight: 700; /* Más peso para el nivel actual */
|
||||||
|
}
|
||||||
|
|
||||||
|
.breadcrumb-icon {
|
||||||
|
margin-right: 0.4rem;
|
||||||
|
font-size: 1rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
.breadcrumb-separator {
|
.breadcrumb-separator {
|
||||||
margin: 0 0.5rem;
|
color: #a0a0a0; /* Color sutil para el separador */
|
||||||
|
font-size: 1.2rem;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.panel-main-content {
|
.panel-main-content {
|
||||||
display: flex;
|
display: flex;
|
||||||
height: 75vh;
|
height: 75vh;
|
||||||
@@ -70,13 +99,126 @@
|
|||||||
min-width: 320px; /* Un ancho mínimo para que no se comprima demasiado */
|
min-width: 320px; /* Un ancho mínimo para que no se comprima demasiado */
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --- NUEVOS ESTILOS --- */
|
/* --- NUEVO LAYOUT PARA TARJETAS DE PARTIDO --- */
|
||||||
|
.partido-fila {
|
||||||
|
display: flex;
|
||||||
|
align-items: center;
|
||||||
|
gap: 1rem;
|
||||||
|
padding: 1rem 0;
|
||||||
|
border-bottom: 1px solid #f0f0f0; /* Separador sutil */
|
||||||
|
border-left: 5px solid; /* El color se aplica inline */
|
||||||
|
padding-left: 1rem;
|
||||||
|
}
|
||||||
|
|
||||||
|
.partido-logo {
|
||||||
|
flex-shrink: 0;
|
||||||
|
width: 75px;
|
||||||
|
height: 75px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.partido-logo img {
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
object-fit: contain;
|
||||||
|
border-radius: 10%;
|
||||||
|
}
|
||||||
|
|
||||||
|
.partido-main-content {
|
||||||
|
flex-grow: 1;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
gap: 0.5rem; /* Espacio entre la fila superior y la barra */
|
||||||
|
}
|
||||||
|
|
||||||
|
.partido-top-row {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-between;
|
||||||
|
align-items: flex-start; /* Alinea los elementos al tope */
|
||||||
|
}
|
||||||
|
|
||||||
|
.partido-info-wrapper {
|
||||||
|
/* Ocupa el espacio disponible a la izquierda */
|
||||||
|
min-width: 0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.partido-nombre {
|
||||||
|
font-weight: 500;
|
||||||
|
white-space: nowrap;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
|
}
|
||||||
|
|
||||||
|
.candidato-nombre {
|
||||||
|
font-size: 0.85rem;
|
||||||
|
color: #666;
|
||||||
|
}
|
||||||
|
|
||||||
|
.partido-stats {
|
||||||
|
flex-shrink: 0;
|
||||||
|
text-align: right;
|
||||||
|
padding-left: 1rem; /* Espacio para que no se pegue al nombre */
|
||||||
|
}
|
||||||
|
|
||||||
|
.partido-porcentaje {
|
||||||
|
font-size: 1.5rem;
|
||||||
|
font-weight: 700;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
.partido-votos {
|
||||||
|
font-size: 1rem;
|
||||||
|
color: #666;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
.partido-barra-background {
|
||||||
|
height: 20px;
|
||||||
|
background-color: #f0f0f0;
|
||||||
|
border-radius: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.partido-barra-foreground {
|
||||||
|
height: 100%;
|
||||||
|
border-radius: 4px;
|
||||||
|
transition: width 0.5s ease-in-out;
|
||||||
|
}
|
||||||
|
/* ------------------------------------------- */
|
||||||
|
|
||||||
|
.panel-estado-recuento {
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-around;
|
||||||
|
padding-bottom: 1.5rem;
|
||||||
|
margin-bottom: 1.5rem;
|
||||||
|
border-bottom: 1px solid #e0e0e0;
|
||||||
|
}
|
||||||
|
|
||||||
|
.estado-item {
|
||||||
|
width: 100px;
|
||||||
|
text-align: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.estado-item span {
|
||||||
|
margin-top: 0.5rem;
|
||||||
|
font-size: 0.9rem;
|
||||||
|
color: #666;
|
||||||
|
display: block;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/* --- MAPA Y ELEMENTOS ASOCIADOS (sin cambios) --- */
|
||||||
.mapa-componente-container {
|
.mapa-componente-container {
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
position: relative;
|
position: relative;
|
||||||
|
overflow: hidden;
|
||||||
|
}
|
||||||
|
.mapa-render-area {
|
||||||
|
position: absolute;
|
||||||
|
top: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.mapa-volver-btn {
|
.mapa-volver-btn {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 10px;
|
top: 10px;
|
||||||
@@ -89,144 +231,19 @@
|
|||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
|
||||||
}
|
}
|
||||||
|
|
||||||
.partido-fila {
|
|
||||||
display: flex;
|
|
||||||
align-items: center;
|
|
||||||
margin-bottom: 1rem;
|
|
||||||
gap: 1rem; /* Añade un espacio entre logo, info y stats */
|
|
||||||
}
|
|
||||||
|
|
||||||
.partido-logo {
|
|
||||||
flex-shrink: 0;
|
|
||||||
width: 48px;
|
|
||||||
height: 48px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.partido-logo img {
|
|
||||||
width: 100%;
|
|
||||||
height: 100%;
|
|
||||||
object-fit: contain;
|
|
||||||
border-radius: 50%;
|
|
||||||
}
|
|
||||||
|
|
||||||
.partido-info-wrapper {
|
|
||||||
flex-grow: 1; /* Permite que esta sección crezca */
|
|
||||||
flex-shrink: 1; /* Permite que se encoja si es necesario */
|
|
||||||
min-width: 0; /* <-- TRUCO CLAVE DE FLEXBOX para que text-overflow funcione */
|
|
||||||
}
|
|
||||||
|
|
||||||
.partido-nombre {
|
|
||||||
font-weight: 500;
|
|
||||||
display: block;
|
|
||||||
white-space: nowrap; /* <-- No permitir que el texto salte de línea */
|
|
||||||
overflow: hidden; /* <-- Ocultar el texto que se desborda */
|
|
||||||
text-overflow: ellipsis; /* <-- Añadir "..." al final */
|
|
||||||
}
|
|
||||||
|
|
||||||
.candidato-nombre {
|
|
||||||
font-size: 0.85rem;
|
|
||||||
color: #666;
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
.partido-barra-background {
|
|
||||||
height: 15px;
|
|
||||||
background-color: #f0f0f0;
|
|
||||||
border-radius: 5px;
|
|
||||||
margin-top: 4px;
|
|
||||||
}
|
|
||||||
|
|
||||||
.partido-barra-foreground {
|
|
||||||
height: 100%;
|
|
||||||
border-radius: 4px;
|
|
||||||
transition: width 0.5s ease-in-out;
|
|
||||||
}
|
|
||||||
|
|
||||||
.partido-stats {
|
|
||||||
flex-shrink: 0; /* <-- MUY IMPORTANTE: Evita que este bloque se encoja */
|
|
||||||
text-align: right;
|
|
||||||
min-width: 100px; /* Asegura que siempre tenga espacio suficiente */
|
|
||||||
}
|
|
||||||
|
|
||||||
.partido-porcentaje {
|
|
||||||
font-size: 1.2rem;
|
|
||||||
font-weight: 700;
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
.partido-votos {
|
|
||||||
font-size: 0.8rem;
|
|
||||||
color: #666;
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
.panel-estado-recuento {
|
|
||||||
margin-top: auto;
|
|
||||||
padding-top: 1rem;
|
|
||||||
border-top: 1px solid #e0e0e0;
|
|
||||||
display: flex;
|
|
||||||
justify-content: space-around;
|
|
||||||
}
|
|
||||||
|
|
||||||
.estado-item {
|
|
||||||
text-align: center;
|
|
||||||
}
|
|
||||||
|
|
||||||
.estado-item span {
|
|
||||||
font-size: 0.8rem;
|
|
||||||
color: #666;
|
|
||||||
display: block;
|
|
||||||
}
|
|
||||||
|
|
||||||
.estado-item strong {
|
|
||||||
font-size: 1.2rem;
|
|
||||||
color: #333;
|
|
||||||
}
|
|
||||||
|
|
||||||
.rsm-zoomable-group {
|
.rsm-zoomable-group {
|
||||||
transition: transform 0.75s ease-in-out;
|
transition: transform 0.75s ease-in-out;
|
||||||
}
|
}
|
||||||
|
|
||||||
* Contenedor principal del contenido */
|
|
||||||
.panel-main-content {
|
|
||||||
display: flex;
|
|
||||||
height: 70vh;
|
|
||||||
min-height: 500px;
|
|
||||||
transition: all 0.5s ease-in-out; /* Transición suave para el layout */
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Columna del mapa */
|
|
||||||
.mapa-column {
|
|
||||||
flex: 2; /* Por defecto, ocupa 2/3 del espacio */
|
|
||||||
position: relative;
|
|
||||||
transition: flex 0.5s ease-in-out;
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Columna de resultados */
|
|
||||||
.resultados-column {
|
|
||||||
flex: 1; /* Por defecto, ocupa 1/3 */
|
|
||||||
overflow-y: auto;
|
|
||||||
padding: 1.5rem;
|
|
||||||
transition: all 0.5s ease-in-out;
|
|
||||||
min-width: 320px; /* Un ancho mínimo para que no se comprima demasiado */
|
|
||||||
}
|
|
||||||
|
|
||||||
/* --- ESTADO COLAPSADO --- */
|
|
||||||
/* Cuando el panel principal tiene la clase 'panel-collapsed' */
|
|
||||||
.panel-main-content.panel-collapsed .mapa-column {
|
.panel-main-content.panel-collapsed .mapa-column {
|
||||||
flex: 1 1 100%; /* El mapa ocupa todo el ancho */
|
flex: 1 1 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
.panel-main-content.panel-collapsed .resultados-column {
|
.panel-main-content.panel-collapsed .resultados-column {
|
||||||
flex-basis: 0;
|
flex-basis: 0;
|
||||||
min-width: 0;
|
min-width: 0;
|
||||||
max-width: 0;
|
max-width: 0;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
overflow: hidden; /* Oculta el contenido para que no se desborde */
|
overflow: hidden;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --- Estilo del botón para colapsar --- */
|
|
||||||
.panel-toggle-btn {
|
.panel-toggle-btn {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 50%;
|
top: 50%;
|
||||||
@@ -248,70 +265,53 @@
|
|||||||
box-shadow: -2px 0 5px rgba(0,0,0,0.1);
|
box-shadow: -2px 0 5px rgba(0,0,0,0.1);
|
||||||
transition: background-color 0.2s;
|
transition: background-color 0.2s;
|
||||||
}
|
}
|
||||||
|
|
||||||
.panel-toggle-btn:hover {
|
.panel-toggle-btn:hover {
|
||||||
background-color: #f0f0f0;
|
background-color: #f0f0f0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.rsm-geography {
|
.rsm-geography {
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
stroke: #000000;
|
stroke: #000000;
|
||||||
stroke-width: 0.2px;
|
stroke-width: 0.25px;
|
||||||
outline: none;
|
outline: none;
|
||||||
transition: filter 0.2s ease-in-out, stroke 0.2s ease-in-out, stroke-width 0.2s ease-in-out;
|
transition: filter 0.2s ease-in-out;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --- ESTADO HOVER (Sutil) --- */
|
|
||||||
/* Se aplica solo si la geografía NO está seleccionada */
|
|
||||||
.rsm-geography:not(.selected):hover {
|
.rsm-geography:not(.selected):hover {
|
||||||
filter: brightness(1.10);
|
filter: brightness(1.15);
|
||||||
stroke: #0000ff;
|
stroke: #ffffff;
|
||||||
stroke-width: 0.5px;
|
stroke-width: 0.25px;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* --- ESTADO SELECCIONADO (Foco) --- */
|
|
||||||
/* Clase que añadiremos desde React para el municipio en foco */
|
|
||||||
.rsm-geography.selected {
|
.rsm-geography.selected {
|
||||||
stroke: #0000ff; /* Borde negro para el seleccionado */
|
stroke: #000000;
|
||||||
stroke-width: 0.5px; /* <-- Borde más grueso para destacar */
|
stroke-width: 0.25px;
|
||||||
filter: none; /* Quitamos cualquier otro filtro para que se vea nítido */
|
filter: none;
|
||||||
pointer-events: none; /* Desactivamos eventos para que no interfiera el hover */
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Reglas para los mapas atenuados (sin cambios) */
|
|
||||||
.rsm-geography-faded,
|
|
||||||
.rsm-geography-faded-municipality {
|
|
||||||
opacity: 0.3;
|
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
}
|
}
|
||||||
|
.rsm-geography-faded,
|
||||||
.rsm-geography-faded:hover,
|
.rsm-geography-faded-municipality {
|
||||||
.rsm-geography-faded-municipality:hover {
|
opacity: 0.5;
|
||||||
filter: none;
|
pointer-events: none;
|
||||||
stroke: #FFFFFF;
|
|
||||||
stroke-width: 0.5px;
|
|
||||||
}
|
}
|
||||||
|
.caba-comuna-geography {
|
||||||
.partido-barra-foreground {
|
stroke: #000000;
|
||||||
height: 100%;
|
stroke-width: 0.05px;
|
||||||
border-radius: 4px;
|
}
|
||||||
transition: width 0.5s ease-in-out;
|
.caba-comuna-geography:not(.selected):hover {
|
||||||
|
stroke: #000000;
|
||||||
|
stroke-width: 0.055px;
|
||||||
|
filter: brightness(1.25);
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Spinner para la transición entre mapas */
|
|
||||||
.transition-spinner {
|
.transition-spinner {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
height: 100%;
|
height: 100%;
|
||||||
background-color: rgba(255, 255, 255, 0.5); /* Fondo blanco semitransparente */
|
background-color: rgba(255, 255, 255, 0.5);
|
||||||
z-index: 20;
|
z-index: 20;
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
}
|
}
|
||||||
/* Estilo del spinner en sí mismo */
|
|
||||||
.transition-spinner::after {
|
.transition-spinner::after {
|
||||||
content: '';
|
content: '';
|
||||||
width: 50px;
|
width: 50px;
|
||||||
@@ -321,7 +321,42 @@
|
|||||||
border-radius: 50%;
|
border-radius: 50%;
|
||||||
animation: spin 1s linear infinite;
|
animation: spin 1s linear infinite;
|
||||||
}
|
}
|
||||||
|
|
||||||
@keyframes spin {
|
@keyframes spin {
|
||||||
to { transform: rotate(360deg); }
|
to { transform: rotate(360deg); }
|
||||||
}
|
}
|
||||||
|
.caba-magnifier-container {
|
||||||
|
position: absolute;
|
||||||
|
height: auto;
|
||||||
|
transform: translate(-50%, -50%);
|
||||||
|
pointer-events: none;
|
||||||
|
}
|
||||||
|
.caba-lupa-svg {
|
||||||
|
width: 100%;
|
||||||
|
height: auto;
|
||||||
|
pointer-events: none;
|
||||||
|
}
|
||||||
|
.caba-lupa-interactive-area {
|
||||||
|
pointer-events: all;
|
||||||
|
cursor: pointer;
|
||||||
|
filter: drop-shadow(0px 2px 4px rgba(0,0,0,0.25));
|
||||||
|
transition: transform 0.2s ease-in-out;
|
||||||
|
}
|
||||||
|
.caba-lupa-interactive-area:hover {
|
||||||
|
filter: brightness(1.15);
|
||||||
|
stroke: #ffffff;
|
||||||
|
stroke-width: 0.25px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.skeleton-fila div {
|
||||||
|
background: #f6f7f8;
|
||||||
|
background-image: linear-gradient(to right, #f6f7f8 0%, #edeef1 20%, #f6f7f8 40%, #f6f7f8 100%);
|
||||||
|
background-repeat: no-repeat;
|
||||||
|
background-size: 800px 104px;
|
||||||
|
animation: shimmer 1s linear infinite;
|
||||||
|
border-radius: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.skeleton-logo { width: 65px; height: 65px; }
|
||||||
|
.skeleton-text { height: 1em; }
|
||||||
|
.skeleton-bar { height: 20px; margin-top: 4px; }
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
// src/features/legislativas/nacionales/PanelNacionalWidget.tsx
|
// src/features/legislativas/nacionales/PanelNacionalWidget.tsx
|
||||||
import { useMemo, useState, Suspense } from 'react';
|
import { useMemo, useState, Suspense } from 'react';
|
||||||
import { useSuspenseQuery } from '@tanstack/react-query'; // <-- CAMBIO CLAVE
|
import { useSuspenseQuery } from '@tanstack/react-query';
|
||||||
import { getPanelElectoral } from '../../../apiService';
|
import { getPanelElectoral } from '../../../apiService';
|
||||||
import { MapaNacional } from './components/MapaNacional';
|
import { MapaNacional } from './components/MapaNacional';
|
||||||
import { PanelResultados } from './components/PanelResultados';
|
import { PanelResultados } from './components/PanelResultados';
|
||||||
@@ -26,20 +26,12 @@ const CATEGORIAS_NACIONALES = [
|
|||||||
{ value: 1, label: 'Senadores Nacionales' },
|
{ value: 1, label: 'Senadores Nacionales' },
|
||||||
];
|
];
|
||||||
|
|
||||||
// Creamos un componente interno para poder usar Suspense correctamente
|
|
||||||
const PanelContenido = ({ eleccionId, ambitoActual, categoriaId }: { eleccionId: number, ambitoActual: AmbitoState, categoriaId: number }) => {
|
const PanelContenido = ({ eleccionId, ambitoActual, categoriaId }: { eleccionId: number, ambitoActual: AmbitoState, categoriaId: number }) => {
|
||||||
// Este hook ahora suspenderá el renderizado si los datos no están listos
|
|
||||||
const { data } = useSuspenseQuery<PanelElectoralDto>({
|
const { data } = useSuspenseQuery<PanelElectoralDto>({
|
||||||
queryKey: ['panelElectoral', eleccionId, ambitoActual.id, categoriaId],
|
queryKey: ['panelElectoral', eleccionId, ambitoActual.id, categoriaId],
|
||||||
queryFn: () => getPanelElectoral(eleccionId, ambitoActual.id, categoriaId),
|
queryFn: () => getPanelElectoral(eleccionId, ambitoActual.id, categoriaId),
|
||||||
});
|
});
|
||||||
|
return <PanelResultados resultados={data.resultadosPanel} estadoRecuento={data.estadoRecuento} />;
|
||||||
return (
|
|
||||||
<PanelResultados
|
|
||||||
resultados={data.resultadosPanel}
|
|
||||||
estadoRecuento={data.estadoRecuento}
|
|
||||||
/>
|
|
||||||
);
|
|
||||||
};
|
};
|
||||||
|
|
||||||
export const PanelNacionalWidget = ({ eleccionId }: PanelNacionalWidgetProps) => {
|
export const PanelNacionalWidget = ({ eleccionId }: PanelNacionalWidgetProps) => {
|
||||||
@@ -52,7 +44,7 @@ export const PanelNacionalWidget = ({ eleccionId }: PanelNacionalWidgetProps) =>
|
|||||||
id: nuevoAmbitoId,
|
id: nuevoAmbitoId,
|
||||||
nivel: nuevoNivel,
|
nivel: nuevoNivel,
|
||||||
nombre: nuevoNombre,
|
nombre: nuevoNombre,
|
||||||
provinciaNombre: nuevoNivel === 'municipio' ? prev.nombre : (nuevoNivel === 'provincia' ? nuevoNombre : undefined),
|
provinciaNombre: nuevoNivel === 'municipio' ? prev.provinciaNombre : (nuevoNivel === 'provincia' ? nuevoNombre : undefined),
|
||||||
provinciaDistritoId: nuevoNivel === 'provincia' ? nuevoAmbitoId : prev.provinciaDistritoId
|
provinciaDistritoId: nuevoNivel === 'provincia' ? nuevoAmbitoId : prev.provinciaDistritoId
|
||||||
}));
|
}));
|
||||||
};
|
};
|
||||||
@@ -67,7 +59,8 @@ export const PanelNacionalWidget = ({ eleccionId }: PanelNacionalWidgetProps) =>
|
|||||||
id: ambitoActual.provinciaDistritoId,
|
id: ambitoActual.provinciaDistritoId,
|
||||||
nivel: 'provincia',
|
nivel: 'provincia',
|
||||||
nombre: ambitoActual.provinciaNombre,
|
nombre: ambitoActual.provinciaNombre,
|
||||||
provinciaDistritoId: ambitoActual.provinciaDistritoId
|
provinciaDistritoId: ambitoActual.provinciaDistritoId,
|
||||||
|
provinciaNombre: ambitoActual.provinciaNombre,
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
handleResetToPais();
|
handleResetToPais();
|
||||||
@@ -101,11 +94,7 @@ export const PanelNacionalWidget = ({ eleccionId }: PanelNacionalWidgetProps) =>
|
|||||||
</header>
|
</header>
|
||||||
<main className={`panel-main-content ${!isPanelOpen ? 'panel-collapsed' : ''}`}>
|
<main className={`panel-main-content ${!isPanelOpen ? 'panel-collapsed' : ''}`}>
|
||||||
<div className="mapa-column">
|
<div className="mapa-column">
|
||||||
<button
|
<button className="panel-toggle-btn" onClick={() => setIsPanelOpen(!isPanelOpen)} title={isPanelOpen ? "Ocultar panel" : "Mostrar panel"}>
|
||||||
className="panel-toggle-btn"
|
|
||||||
onClick={() => setIsPanelOpen(!isPanelOpen)}
|
|
||||||
title={isPanelOpen ? "Ocultar panel" : "Mostrar panel"}
|
|
||||||
>
|
|
||||||
{isPanelOpen ? '›' : '‹'}
|
{isPanelOpen ? '›' : '‹'}
|
||||||
</button>
|
</button>
|
||||||
<Suspense fallback={<div className="spinner" />}>
|
<Suspense fallback={<div className="spinner" />}>
|
||||||
@@ -114,6 +103,7 @@ export const PanelNacionalWidget = ({ eleccionId }: PanelNacionalWidgetProps) =>
|
|||||||
categoriaId={categoriaId}
|
categoriaId={categoriaId}
|
||||||
nivel={ambitoActual.nivel}
|
nivel={ambitoActual.nivel}
|
||||||
nombreAmbito={ambitoActual.nombre}
|
nombreAmbito={ambitoActual.nombre}
|
||||||
|
nombreProvinciaActiva={ambitoActual.provinciaNombre}
|
||||||
provinciaDistritoId={ambitoActual.provinciaDistritoId ?? null}
|
provinciaDistritoId={ambitoActual.provinciaDistritoId ?? null}
|
||||||
onAmbitoSelect={handleAmbitoSelect}
|
onAmbitoSelect={handleAmbitoSelect}
|
||||||
onVolver={ambitoActual.nivel === 'municipio' ? handleVolverAProvincia : handleResetToPais}
|
onVolver={ambitoActual.nivel === 'municipio' ? handleVolverAProvincia : handleResetToPais}
|
||||||
|
|||||||
@@ -1,4 +1,6 @@
|
|||||||
// src/features/legislativas/nacionales/components/Breadcrumbs.tsx
|
// src/features/legislativas/nacionales/components/Breadcrumbs.tsx
|
||||||
|
import { FiHome, FiChevronRight } from 'react-icons/fi';
|
||||||
|
|
||||||
interface BreadcrumbsProps {
|
interface BreadcrumbsProps {
|
||||||
nivel: 'pais' | 'provincia' | 'municipio';
|
nivel: 'pais' | 'provincia' | 'municipio';
|
||||||
nombreAmbito: string;
|
nombreAmbito: string;
|
||||||
@@ -9,20 +11,39 @@ interface BreadcrumbsProps {
|
|||||||
|
|
||||||
export const Breadcrumbs = ({ nivel, nombreAmbito, nombreProvincia, onReset, onVolverProvincia }: BreadcrumbsProps) => {
|
export const Breadcrumbs = ({ nivel, nombreAmbito, nombreProvincia, onReset, onVolverProvincia }: BreadcrumbsProps) => {
|
||||||
return (
|
return (
|
||||||
<div className="breadcrumbs">
|
<nav className="breadcrumbs-container">
|
||||||
{nivel !== 'pais' && (
|
{nivel !== 'pais' ? (
|
||||||
<>
|
<>
|
||||||
<button onClick={onReset} className="breadcrumb-link">Argentina</button>
|
<button onClick={onReset} className="breadcrumb-item">
|
||||||
<span className="breadcrumb-separator">{'>'}</span>
|
<FiHome className="breadcrumb-icon" />
|
||||||
|
<span>Argentina</span>
|
||||||
|
</button>
|
||||||
|
<FiChevronRight className="breadcrumb-separator" />
|
||||||
</>
|
</>
|
||||||
|
) : (
|
||||||
|
<div className="breadcrumb-item-actual">
|
||||||
|
<FiHome className="breadcrumb-icon" />
|
||||||
|
<span>{nombreAmbito}</span>
|
||||||
|
</div>
|
||||||
)}
|
)}
|
||||||
|
|
||||||
|
{nivel === 'provincia' && (
|
||||||
|
<div className="breadcrumb-item-actual">
|
||||||
|
<span>{nombreAmbito}</span>
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
|
||||||
{nivel === 'municipio' && nombreProvincia && (
|
{nivel === 'municipio' && nombreProvincia && (
|
||||||
<>
|
<>
|
||||||
<button onClick={onVolverProvincia} className="breadcrumb-link">{nombreProvincia}</button>
|
<button onClick={onVolverProvincia} className="breadcrumb-item">
|
||||||
<span className="breadcrumb-separator">{'>'}</span>
|
<span>{nombreProvincia}</span>
|
||||||
|
</button>
|
||||||
|
<FiChevronRight className="breadcrumb-separator" />
|
||||||
|
<div className="breadcrumb-item-actual">
|
||||||
|
<span>{nombreAmbito}</span>
|
||||||
|
</div>
|
||||||
</>
|
</>
|
||||||
)}
|
)}
|
||||||
<span className="breadcrumb-actual">{nombreAmbito}</span>
|
</nav>
|
||||||
</div>
|
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
File diff suppressed because one or more lines are too long
@@ -1,12 +1,14 @@
|
|||||||
// src/features/legislativas/nacionales/components/MapaNacional.tsx
|
|
||||||
import axios from 'axios';
|
import axios from 'axios';
|
||||||
import { Suspense, useState, useEffect, useCallback } from 'react'; // <-- Asegúrate de que useCallback esté importado
|
import { Suspense, useState, useEffect, useCallback, useRef } from 'react';
|
||||||
import { useSuspenseQuery } from '@tanstack/react-query';
|
import { useSuspenseQuery } from '@tanstack/react-query';
|
||||||
import { ComposableMap, Geographies, Geography, ZoomableGroup } from 'react-simple-maps';
|
import { ComposableMap, Geographies, Geography, ZoomableGroup } from 'react-simple-maps';
|
||||||
import { Tooltip } from 'react-tooltip';
|
import { Tooltip } from 'react-tooltip';
|
||||||
|
import { geoCentroid } from 'd3-geo';
|
||||||
|
import { feature } from 'topojson-client';
|
||||||
import { API_BASE_URL, assetBaseUrl } from '../../../../apiService';
|
import { API_BASE_URL, assetBaseUrl } from '../../../../apiService';
|
||||||
import type { ResultadoMapaDto, AmbitoGeography } from '../../../../types/types';
|
import type { ResultadoMapaDto, AmbitoGeography } from '../../../../types/types';
|
||||||
import { MapaProvincial } from './MapaProvincial';
|
import { MapaProvincial } from './MapaProvincial';
|
||||||
|
import { CabaLupa } from './CabaLupa';
|
||||||
|
|
||||||
const DEFAULT_MAP_COLOR = '#E0E0E0';
|
const DEFAULT_MAP_COLOR = '#E0E0E0';
|
||||||
const FADED_BACKGROUND_COLOR = '#F0F0F0';
|
const FADED_BACKGROUND_COLOR = '#F0F0F0';
|
||||||
@@ -14,19 +16,44 @@ const normalizarTexto = (texto: string = '') => texto.trim().toUpperCase().norma
|
|||||||
|
|
||||||
type PointTuple = [number, number];
|
type PointTuple = [number, number];
|
||||||
|
|
||||||
|
const PROVINCE_VIEW_CONFIG: Record<string, { center: PointTuple; zoom: number }> = {
|
||||||
|
"BUENOS AIRES": { center: [-60.5, -37.3], zoom: 5.5 },
|
||||||
|
"SANTA CRUZ": { center: [-69.5, -48.8], zoom: 5 },
|
||||||
|
"CIUDAD AUTONOMA DE BUENOS AIRES": { center: [-58.45, -34.6], zoom: 85 },
|
||||||
|
"CHUBUT": { center: [-68.5, -44.5], zoom: 5.5 },
|
||||||
|
"SANTA FE": { center: [-61, -31.2], zoom: 6 },
|
||||||
|
"CORRIENTES": { center: [-58, -29], zoom: 7 },
|
||||||
|
"RIO NEGRO": { center: [-67.5, -40], zoom: 5.5 },
|
||||||
|
"TIERRA DEL FUEGO": { center: [-66.5, -54.2], zoom: 7 },
|
||||||
|
};
|
||||||
|
|
||||||
|
const LUPA_SIZE_RATIO = 0.2;
|
||||||
|
const MIN_LUPA_SIZE_PX = 100;
|
||||||
|
const MAX_LUPA_SIZE_PX = 180;
|
||||||
|
|
||||||
|
|
||||||
interface MapaNacionalProps {
|
interface MapaNacionalProps {
|
||||||
eleccionId: number;
|
eleccionId: number;
|
||||||
categoriaId: number;
|
categoriaId: number;
|
||||||
nivel: 'pais' | 'provincia' | 'municipio';
|
nivel: 'pais' | 'provincia' | 'municipio';
|
||||||
nombreAmbito: string;
|
nombreAmbito: string;
|
||||||
|
nombreProvinciaActiva: string | undefined | null;
|
||||||
provinciaDistritoId: string | null;
|
provinciaDistritoId: string | null;
|
||||||
onAmbitoSelect: (ambitoId: string, nivel: 'provincia' | 'municipio', nombre: string) => void;
|
onAmbitoSelect: (ambitoId: string, nivel: 'provincia' | 'municipio', nombre: string) => void;
|
||||||
onVolver: () => void;
|
onVolver: () => void;
|
||||||
}
|
}
|
||||||
|
|
||||||
export const MapaNacional = ({ eleccionId, categoriaId, nivel, nombreAmbito, provinciaDistritoId, onAmbitoSelect, onVolver }: MapaNacionalProps) => {
|
export const MapaNacional = ({ eleccionId, categoriaId, nivel, nombreAmbito, nombreProvinciaActiva, provinciaDistritoId, onAmbitoSelect, onVolver }: MapaNacionalProps) => {
|
||||||
const [position, setPosition] = useState({ zoom: 1, center: [-65, -40] as PointTuple });
|
const [position, setPosition] = useState({ zoom: 1, center: [-65, -40] as PointTuple });
|
||||||
|
|
||||||
|
const containerRef = useRef<HTMLDivElement | null>(null);
|
||||||
|
const lupaRef = useRef<HTMLDivElement | null>(null);
|
||||||
|
const cabaPathRef = useRef<SVGPathElement | null>(null);
|
||||||
|
const isAnimatingRef = useRef(false);
|
||||||
|
const initialLoadRef = useRef(true); // Ref para controlar la carga inicial
|
||||||
|
|
||||||
|
const [lupaStyle, setLupaStyle] = useState<React.CSSProperties>({ opacity: 0 });
|
||||||
|
|
||||||
const { data: mapaDataNacional } = useSuspenseQuery<ResultadoMapaDto[]>({
|
const { data: mapaDataNacional } = useSuspenseQuery<ResultadoMapaDto[]>({
|
||||||
queryKey: ['mapaResultados', eleccionId, categoriaId, null],
|
queryKey: ['mapaResultados', eleccionId, categoriaId, null],
|
||||||
queryFn: async () => {
|
queryFn: async () => {
|
||||||
@@ -41,63 +68,171 @@ export const MapaNacional = ({ eleccionId, categoriaId, nivel, nombreAmbito, pro
|
|||||||
queryFn: () => axios.get(`${assetBaseUrl}/maps/argentina-provincias.topojson`).then(res => res.data),
|
queryFn: () => axios.get(`${assetBaseUrl}/maps/argentina-provincias.topojson`).then(res => res.data),
|
||||||
});
|
});
|
||||||
|
|
||||||
const resultadosNacionalesPorNombre = new Map<string, ResultadoMapaDto>(mapaDataNacional.map(d => [normalizarTexto(d.ambitoNombre), d]));
|
|
||||||
|
|
||||||
const nombreMunicipioSeleccionado = nivel === 'municipio' ? nombreAmbito : null;
|
|
||||||
|
|
||||||
// El useEffect para el zoom provincial y nacional sigue siendo correcto.
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (nivel === 'pais') {
|
if (nivel === 'pais') {
|
||||||
setPosition({ zoom: 1, center: [-65, -40] });
|
setPosition({ zoom: 1, center: [-65, -40] });
|
||||||
} else if (nivel === 'provincia') {
|
} else if (nivel === 'provincia') {
|
||||||
setPosition({ zoom: 7, center: [-60.5, -37] });
|
const nombreNormalizado = normalizarTexto(nombreAmbito);
|
||||||
}
|
const manualConfig = PROVINCE_VIEW_CONFIG[nombreNormalizado];
|
||||||
// La lógica de centrado en municipio se delega al hijo, que llamará a `handleCalculatedCenter`
|
|
||||||
}, [nivel]);
|
|
||||||
|
|
||||||
// **LA SOLUCIÓN CLAVE**: Estabilizamos la función que se pasa al hijo.
|
if (manualConfig) {
|
||||||
const handleCalculatedCenter = useCallback((center: PointTuple, zoom: number) => {
|
setPosition(manualConfig);
|
||||||
setPosition({ center, zoom });
|
} else {
|
||||||
}, []); // El array de dependencias vacío asegura que la función nunca cambie
|
const provinciaGeo = geoDataNacional.objects.provincias.geometries.find((g: any) => normalizarTexto(g.properties.nombre) === nombreNormalizado);
|
||||||
|
if (provinciaGeo) {
|
||||||
|
const provinciaFeature = feature(geoDataNacional, provinciaGeo);
|
||||||
|
const centroid = geoCentroid(provinciaFeature);
|
||||||
|
setPosition({ zoom: 7, center: centroid as PointTuple });
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}, [nivel, nombreAmbito, geoDataNacional]);
|
||||||
|
|
||||||
|
const resultadosNacionalesPorNombre = new Map<string, ResultadoMapaDto>(mapaDataNacional.map(d => [normalizarTexto(d.ambitoNombre), d]));
|
||||||
|
const nombreMunicipioSeleccionado = nivel === 'municipio' ? nombreAmbito : null;
|
||||||
|
const handleCalculatedCenter = useCallback((center: PointTuple, zoom: number) => { setPosition({ center, zoom }); }, []);
|
||||||
|
|
||||||
|
useEffect(() => {
|
||||||
|
const updateLupaPosition = () => {
|
||||||
|
if (nivel === 'pais' && cabaPathRef.current && containerRef.current) {
|
||||||
|
const containerRect = containerRef.current.getBoundingClientRect();
|
||||||
|
if (containerRect.width === 0) return;
|
||||||
|
|
||||||
|
const cabaRect = cabaPathRef.current.getBoundingClientRect();
|
||||||
|
const cabaCenterX = (cabaRect.left - containerRect.left) + cabaRect.width / 2;
|
||||||
|
const cabaCenterY = (cabaRect.top - containerRect.top) + cabaRect.height / 2;
|
||||||
|
|
||||||
|
const calculatedSize = containerRect.width * LUPA_SIZE_RATIO;
|
||||||
|
const newLupaSize = Math.max(MIN_LUPA_SIZE_PX, Math.min(calculatedSize, MAX_LUPA_SIZE_PX));
|
||||||
|
|
||||||
|
const horizontalOffset = newLupaSize * 0.5;
|
||||||
|
const verticalOffset = newLupaSize * 0.2;
|
||||||
|
|
||||||
|
setLupaStyle({
|
||||||
|
position: 'absolute',
|
||||||
|
top: `${cabaCenterY - verticalOffset}px`,
|
||||||
|
left: `${cabaCenterX + horizontalOffset}px`,
|
||||||
|
width: `${newLupaSize}px`,
|
||||||
|
opacity: 1,
|
||||||
|
});
|
||||||
|
} else {
|
||||||
|
setLupaStyle({ opacity: 0, pointerEvents: 'none' });
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
isAnimatingRef.current = true;
|
||||||
|
|
||||||
|
const handleResize = () => {
|
||||||
|
if (!isAnimatingRef.current) {
|
||||||
|
updateLupaPosition();
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
const resizeObserver = new ResizeObserver(handleResize);
|
||||||
|
if (containerRef.current) {
|
||||||
|
resizeObserver.observe(containerRef.current);
|
||||||
|
}
|
||||||
|
|
||||||
|
let timerId: NodeJS.Timeout;
|
||||||
|
|
||||||
|
if (initialLoadRef.current && nivel === 'pais') {
|
||||||
|
// Carga inicial: posicionar inmediatamente
|
||||||
|
timerId = setTimeout(() => {
|
||||||
|
updateLupaPosition();
|
||||||
|
isAnimatingRef.current = false;
|
||||||
|
}, 0);
|
||||||
|
initialLoadRef.current = false; // Marcar como ya cargado
|
||||||
|
} else {
|
||||||
|
// Transición de vuelta: esperar a que termine la animación
|
||||||
|
timerId = setTimeout(() => {
|
||||||
|
updateLupaPosition();
|
||||||
|
isAnimatingRef.current = false;
|
||||||
|
}, 800);
|
||||||
|
}
|
||||||
|
|
||||||
|
return () => {
|
||||||
|
if (containerRef.current) {
|
||||||
|
resizeObserver.unobserve(containerRef.current);
|
||||||
|
}
|
||||||
|
clearTimeout(timerId);
|
||||||
|
isAnimatingRef.current = false;
|
||||||
|
};
|
||||||
|
}, [position, nivel]);
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<div className="mapa-componente-container">
|
<div className="mapa-componente-container" ref={containerRef}>
|
||||||
{nivel !== 'pais' && <button onClick={onVolver} className="mapa-volver-btn">← Volver</button>}
|
{nivel !== 'pais' && <button onClick={onVolver} className="mapa-volver-btn">← Volver</button>}
|
||||||
<ComposableMap projection="geoMercator" projectionConfig={{ scale: 700, center: [-65, -40] }} style={{ width: "100%", height: "100%" }}>
|
|
||||||
<ZoomableGroup center={position.center} zoom={position.zoom} filterZoomEvent={() => false}>
|
|
||||||
<Geographies geography={geoDataNacional}>
|
|
||||||
{({ geographies }: { geographies: AmbitoGeography[] }) => geographies.map((geo) => {
|
|
||||||
const resultado = resultadosNacionalesPorNombre.get(normalizarTexto(geo.properties.nombre));
|
|
||||||
const esProvinciaActiva = provinciaDistritoId && resultado?.ambitoId === provinciaDistritoId;
|
|
||||||
|
|
||||||
return (
|
<div className="mapa-render-area">
|
||||||
<Geography
|
<ComposableMap
|
||||||
key={geo.rsmKey} geography={geo}
|
projection="geoMercator"
|
||||||
className={`rsm-geography ${nivel !== 'pais' ? 'rsm-geography-faded' : ''}`}
|
projectionConfig={{ scale: 700, center: [-65, -40] }}
|
||||||
style={{ visibility: esProvinciaActiva ? 'hidden' : 'visible' }}
|
style={{ width: "100%", height: "100%" }}
|
||||||
fill={nivel === 'pais' ? (resultado?.colorGanador || DEFAULT_MAP_COLOR) : FADED_BACKGROUND_COLOR}
|
>
|
||||||
onClick={() => resultado && onAmbitoSelect(resultado.ambitoId, 'provincia', resultado.ambitoNombre)}
|
<ZoomableGroup
|
||||||
|
center={position.center}
|
||||||
|
zoom={position.zoom}
|
||||||
|
filterZoomEvent={() => false}
|
||||||
|
>
|
||||||
|
<Geographies geography={geoDataNacional}>
|
||||||
|
{({ geographies }: { geographies: AmbitoGeography[] }) => geographies.map((geo) => {
|
||||||
|
const nombreNormalizado = normalizarTexto(geo.properties.nombre);
|
||||||
|
const esCABA = nombreNormalizado === 'CIUDAD AUTONOMA DE BUENOS AIRES';
|
||||||
|
const resultado = resultadosNacionalesPorNombre.get(nombreNormalizado);
|
||||||
|
const esProvinciaActiva = provinciaDistritoId && resultado?.ambitoId === provinciaDistritoId;
|
||||||
|
|
||||||
|
return (
|
||||||
|
<Geography
|
||||||
|
key={geo.rsmKey}
|
||||||
|
geography={geo}
|
||||||
|
ref={esCABA ? cabaPathRef : undefined}
|
||||||
|
className={`rsm-geography ${nivel !== 'pais' ? 'rsm-geography-faded' : ''}`}
|
||||||
|
style={{
|
||||||
|
visibility: esCABA ? 'hidden' : (esProvinciaActiva ? 'hidden' : 'visible'),
|
||||||
|
}}
|
||||||
|
fill={nivel === 'pais' ? (resultado?.colorGanador || DEFAULT_MAP_COLOR) : FADED_BACKGROUND_COLOR}
|
||||||
|
onClick={() => !esCABA && resultado && onAmbitoSelect(resultado.ambitoId, 'provincia', resultado.ambitoNombre)}
|
||||||
|
data-tooltip-id="mapa-tooltip"
|
||||||
|
data-tooltip-content={geo.properties.nombre}
|
||||||
|
/>
|
||||||
|
);
|
||||||
|
})}
|
||||||
|
</Geographies>
|
||||||
|
|
||||||
|
{provinciaDistritoId && nombreProvinciaActiva && (
|
||||||
|
<Suspense fallback={null}>
|
||||||
|
<MapaProvincial
|
||||||
|
eleccionId={eleccionId}
|
||||||
|
categoriaId={categoriaId}
|
||||||
|
distritoId={provinciaDistritoId}
|
||||||
|
nombreProvincia={nombreProvinciaActiva}
|
||||||
|
nombreMunicipioSeleccionado={nombreMunicipioSeleccionado}
|
||||||
|
onMunicipioSelect={(ambitoId, nombre) => onAmbitoSelect(ambitoId, 'municipio', nombre)}
|
||||||
|
onCalculatedCenter={handleCalculatedCenter}
|
||||||
|
nivel={nivel as 'provincia' | 'municipio'}
|
||||||
/>
|
/>
|
||||||
);
|
</Suspense>
|
||||||
})}
|
)}
|
||||||
</Geographies>
|
</ZoomableGroup>
|
||||||
|
</ComposableMap>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
{nivel === 'pais' && (
|
||||||
|
<div id="caba-lupa-anchor" className="caba-magnifier-container" style={lupaStyle} ref={lupaRef}>
|
||||||
|
{(() => {
|
||||||
|
const resultadoCABA = resultadosNacionalesPorNombre.get("CIUDAD AUTONOMA DE BUENOS AIRES");
|
||||||
|
const fillColor = resultadoCABA?.colorGanador || DEFAULT_MAP_COLOR;
|
||||||
|
const handleClick = () => {
|
||||||
|
if (resultadoCABA) {
|
||||||
|
onAmbitoSelect(resultadoCABA.ambitoId, 'provincia', resultadoCABA.ambitoNombre);
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
|
return <CabaLupa fillColor={fillColor} onClick={handleClick} />;
|
||||||
|
})()}
|
||||||
|
</div>
|
||||||
|
)}
|
||||||
|
|
||||||
{provinciaDistritoId && (
|
|
||||||
<Suspense fallback={null}>
|
|
||||||
<MapaProvincial
|
|
||||||
eleccionId={eleccionId}
|
|
||||||
categoriaId={categoriaId}
|
|
||||||
distritoId={provinciaDistritoId}
|
|
||||||
nombreProvincia={"BUENOS AIRES"} // Esto se podría hacer dinámico si fuera necesario
|
|
||||||
nombreMunicipioSeleccionado={nombreMunicipioSeleccionado}
|
|
||||||
onMunicipioSelect={(ambitoId, nombre) => onAmbitoSelect(ambitoId, 'municipio', nombre)}
|
|
||||||
onCalculatedCenter={handleCalculatedCenter} // Pasamos la función estabilizada
|
|
||||||
nivel={nivel as 'provincia' | 'municipio'} // El cast de tipo sigue siendo necesario y correcto
|
|
||||||
/>
|
|
||||||
</Suspense>
|
|
||||||
)}
|
|
||||||
</ZoomableGroup>
|
|
||||||
</ComposableMap>
|
|
||||||
<Tooltip id="mapa-tooltip" />
|
<Tooltip id="mapa-tooltip" />
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
|
|||||||
@@ -32,8 +32,7 @@ export const MapaProvincial = ({ eleccionId, categoriaId, distritoId, nombreProv
|
|||||||
return response.data;
|
return response.data;
|
||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
// El nombre del archivo ahora es completamente dinámico
|
|
||||||
const { data: geoData } = useSuspenseQuery<any>({
|
const { data: geoData } = useSuspenseQuery<any>({
|
||||||
queryKey: ['geoDataProvincial', nombreProvincia],
|
queryKey: ['geoDataProvincial', nombreProvincia],
|
||||||
queryFn: async () => {
|
queryFn: async () => {
|
||||||
@@ -43,21 +42,22 @@ export const MapaProvincial = ({ eleccionId, categoriaId, distritoId, nombreProv
|
|||||||
},
|
},
|
||||||
});
|
});
|
||||||
|
|
||||||
// useEffect para calcular y "exportar" la posición del municipio al padre
|
// useEffect que calcula y exporta la posición del municipio al padre
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (nivel === 'municipio' && geoData?.objects && nombreMunicipioSeleccionado) {
|
if (nivel === 'municipio' && geoData?.objects && nombreMunicipioSeleccionado) {
|
||||||
const geometries = geoData.objects[Object.keys(geoData.objects)[0]].geometries;
|
const geometries = geoData.objects[Object.keys(geoData.objects)[0]].geometries;
|
||||||
const municipioGeo = geometries.find((g: any) => normalizarTexto(g.properties.departamento) === normalizarTexto(nombreMunicipioSeleccionado));
|
const municipioGeo = geometries.find((g: any) => normalizarTexto(g.properties.departamento) === normalizarTexto(nombreMunicipioSeleccionado));
|
||||||
if (municipioGeo) {
|
if (municipioGeo) {
|
||||||
const municipioFeature = feature(geoData, municipioGeo);
|
const municipioFeature = feature(geoData, municipioGeo);
|
||||||
const centroid = geoCentroid(municipioFeature);
|
const centroid = geoCentroid(municipioFeature);
|
||||||
// Usamos un zoom genérico alto para cualquier municipio
|
// Llama a la función del padre para que actualice la posición
|
||||||
onCalculatedCenter(centroid as PointTuple, 40);
|
onCalculatedCenter(centroid as PointTuple, 40);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}, [nivel, nombreMunicipioSeleccionado, geoData, onCalculatedCenter]);
|
}, [nivel, nombreMunicipioSeleccionado, geoData, onCalculatedCenter]);
|
||||||
|
|
||||||
const resultadosPorNombre = new Map<string, ResultadoMapaDto>(mapaData.map(d => [normalizarTexto(d.ambitoNombre), d]));
|
const resultadosPorNombre = new Map<string, ResultadoMapaDto>(mapaData.map(d => [normalizarTexto(d.ambitoNombre), d]));
|
||||||
|
const esCABA = normalizarTexto(nombreProvincia) === "CIUDAD AUTONOMA DE BUENOS AIRES";
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Geographies geography={geoData}>
|
<Geographies geography={geoData}>
|
||||||
@@ -65,11 +65,19 @@ export const MapaProvincial = ({ eleccionId, categoriaId, distritoId, nombreProv
|
|||||||
const resultado = resultadosPorNombre.get(normalizarTexto(geo.properties.departamento));
|
const resultado = resultadosPorNombre.get(normalizarTexto(geo.properties.departamento));
|
||||||
const esSeleccionado = nombreMunicipioSeleccionado ? normalizarTexto(geo.properties.departamento) === normalizarTexto(nombreMunicipioSeleccionado) : false;
|
const esSeleccionado = nombreMunicipioSeleccionado ? normalizarTexto(geo.properties.departamento) === normalizarTexto(nombreMunicipioSeleccionado) : false;
|
||||||
|
|
||||||
|
const classNames = [
|
||||||
|
'rsm-geography',
|
||||||
|
'mapa-provincial-geography',
|
||||||
|
esSeleccionado ? 'selected' : '',
|
||||||
|
nombreMunicipioSeleccionado && !esSeleccionado ? 'rsm-geography-faded-municipality' : '',
|
||||||
|
esCABA ? 'caba-comuna-geography' : ''
|
||||||
|
].filter(Boolean).join(' ');
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Geography
|
<Geography
|
||||||
key={geo.rsmKey}
|
key={geo.rsmKey}
|
||||||
geography={geo}
|
geography={geo}
|
||||||
className={`rsm-geography ${esSeleccionado ? 'selected' : ''} ${nombreMunicipioSeleccionado && !esSeleccionado ? 'rsm-geography-faded-municipality' : ''}`}
|
className={classNames}
|
||||||
fill={resultado?.colorGanador || DEFAULT_MAP_COLOR}
|
fill={resultado?.colorGanador || DEFAULT_MAP_COLOR}
|
||||||
onClick={resultado ? () => onMunicipioSelect(resultado.ambitoId.toString(), resultado.ambitoNombre) : undefined}
|
onClick={resultado ? () => onMunicipioSelect(resultado.ambitoId.toString(), resultado.ambitoNombre) : undefined}
|
||||||
data-tooltip-id="mapa-tooltip"
|
data-tooltip-id="mapa-tooltip"
|
||||||
|
|||||||
@@ -3,6 +3,8 @@ import type { ResultadoTicker, EstadoRecuentoTicker } from '../../../../types/ty
|
|||||||
import { ImageWithFallback } from '../../../../components/common/ImageWithFallback';
|
import { ImageWithFallback } from '../../../../components/common/ImageWithFallback';
|
||||||
import { assetBaseUrl } from '../../../../apiService';
|
import { assetBaseUrl } from '../../../../apiService';
|
||||||
import { AnimatedNumber } from './AnimatedNumber';
|
import { AnimatedNumber } from './AnimatedNumber';
|
||||||
|
import { CircularProgressbar, buildStyles } from 'react-circular-progressbar';
|
||||||
|
import 'react-circular-progressbar/dist/styles.css';
|
||||||
|
|
||||||
const formatPercent = (num: number) => `${(num || 0).toFixed(2).replace('.', ',')}%`;
|
const formatPercent = (num: number) => `${(num || 0).toFixed(2).replace('.', ',')}%`;
|
||||||
const formatVotes = (num: number) => Math.round(num).toLocaleString('es-AR');
|
const formatVotes = (num: number) => Math.round(num).toLocaleString('es-AR');
|
||||||
@@ -15,41 +17,65 @@ interface PanelResultadosProps {
|
|||||||
export const PanelResultados = ({ resultados, estadoRecuento }: PanelResultadosProps) => {
|
export const PanelResultados = ({ resultados, estadoRecuento }: PanelResultadosProps) => {
|
||||||
return (
|
return (
|
||||||
<div className="panel-resultados">
|
<div className="panel-resultados">
|
||||||
|
<div className="panel-estado-recuento">
|
||||||
|
<div className="estado-item">
|
||||||
|
<CircularProgressbar
|
||||||
|
value={estadoRecuento.participacionPorcentaje}
|
||||||
|
text={formatPercent(estadoRecuento.participacionPorcentaje)}
|
||||||
|
strokeWidth={10}
|
||||||
|
styles={buildStyles({
|
||||||
|
textColor: '#333',
|
||||||
|
pathColor: '#28a745',
|
||||||
|
trailColor: '#e9ecef',
|
||||||
|
textSize: '24px',
|
||||||
|
})}
|
||||||
|
/>
|
||||||
|
<span>Participación</span>
|
||||||
|
</div>
|
||||||
|
<div className="estado-item">
|
||||||
|
<CircularProgressbar
|
||||||
|
value={estadoRecuento.mesasTotalizadasPorcentaje}
|
||||||
|
text={formatPercent(estadoRecuento.mesasTotalizadasPorcentaje)}
|
||||||
|
strokeWidth={10}
|
||||||
|
styles={buildStyles({
|
||||||
|
textColor: '#333',
|
||||||
|
pathColor: '#007bff',
|
||||||
|
trailColor: '#e9ecef',
|
||||||
|
textSize: '24px',
|
||||||
|
})}
|
||||||
|
/>
|
||||||
|
<span>Escrutado</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
<div className="panel-partidos-container">
|
<div className="panel-partidos-container">
|
||||||
{resultados.map(partido => (
|
{resultados.map(partido => (
|
||||||
<div key={partido.id} className="partido-fila">
|
<div key={partido.id} className="partido-fila" style={{ borderLeftColor: partido.color || '#888' }}>
|
||||||
<div className="partido-logo">
|
<div className="partido-logo">
|
||||||
<ImageWithFallback src={partido.logoUrl || undefined} fallbackSrc={`${assetBaseUrl}/default-avatar.png`} alt={partido.nombre} />
|
<ImageWithFallback src={partido.logoUrl || undefined} fallbackSrc={`${assetBaseUrl}/default-avatar.png`} alt={partido.nombre} />
|
||||||
</div>
|
</div>
|
||||||
<div className="partido-info-wrapper">
|
<div className="partido-main-content">
|
||||||
<span className="partido-nombre">{partido.nombreCorto || partido.nombre}</span>
|
<div className="partido-top-row">
|
||||||
{partido.nombreCandidato && <span className="candidato-nombre">{partido.nombreCandidato}</span>}
|
<div className="partido-info-wrapper">
|
||||||
|
<span className="partido-nombre">{partido.nombreCorto || partido.nombre}</span>
|
||||||
|
{partido.nombreCandidato && <span className="candidato-nombre">{partido.nombreCandidato}</span>}
|
||||||
|
</div>
|
||||||
|
<div className="partido-stats">
|
||||||
|
<span className="partido-porcentaje">
|
||||||
|
<AnimatedNumber value={partido.porcentaje} formatter={formatPercent} />
|
||||||
|
</span>
|
||||||
|
<span className="partido-votos">
|
||||||
|
<AnimatedNumber value={partido.votos} formatter={formatVotes} /> votos
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
<div className="partido-barra-background">
|
<div className="partido-barra-background">
|
||||||
<div className="partido-barra-foreground" style={{ width: `${partido.porcentaje}%`, backgroundColor: partido.color || '#888' }} />
|
<div className="partido-barra-foreground" style={{ width: `${partido.porcentaje}%`, backgroundColor: partido.color || '#888' }} />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div className="partido-stats">
|
|
||||||
<span className="partido-porcentaje">
|
|
||||||
<AnimatedNumber value={partido.porcentaje} formatter={formatPercent} />
|
|
||||||
</span>
|
|
||||||
<span className="partido-votos">
|
|
||||||
<AnimatedNumber value={partido.votos} formatter={formatVotes} /> votos
|
|
||||||
</span>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
))}
|
))}
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div className="panel-estado-recuento">
|
|
||||||
<div className="estado-item">
|
|
||||||
<span>Participación</span>
|
|
||||||
<strong><AnimatedNumber value={estadoRecuento.participacionPorcentaje} formatter={formatPercent} /></strong>
|
|
||||||
</div>
|
|
||||||
<div className="estado-item">
|
|
||||||
<span>Mesas Escrutadas</span>
|
|
||||||
<strong><AnimatedNumber value={estadoRecuento.mesasTotalizadasPorcentaje} formatter={formatPercent} /></strong>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
</div>
|
</div>
|
||||||
);
|
);
|
||||||
};
|
};
|
||||||
@@ -0,0 +1,21 @@
|
|||||||
|
// src/features/legislativas/nacionales/components/PanelResultadosSkeleton.tsx
|
||||||
|
const SkeletonRow = () => (
|
||||||
|
<div className="partido-fila skeleton-fila">
|
||||||
|
<div className="skeleton-logo" />
|
||||||
|
<div className="partido-info-wrapper">
|
||||||
|
<div className="skeleton-text" style={{ width: '60%' }} />
|
||||||
|
<div className="skeleton-text" style={{ width: '40%', marginTop: '4px' }} />
|
||||||
|
<div className="skeleton-bar" />
|
||||||
|
</div>
|
||||||
|
<div className="partido-stats">
|
||||||
|
<div className="skeleton-text" style={{ width: '70%', marginBottom: '4px' }} />
|
||||||
|
<div className="skeleton-text" style={{ width: '50%' }} />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
);
|
||||||
|
|
||||||
|
export const PanelResultadosSkeleton = () => (
|
||||||
|
<div className="panel-resultados-skeleton">
|
||||||
|
{[...Array(5)].map((_, i) => <SkeletonRow key={i} />)}
|
||||||
|
</div>
|
||||||
|
);
|
||||||
@@ -1103,73 +1103,42 @@ public class ResultadosController : ControllerBase
|
|||||||
// Este método se ejecutará cuando la URL sea, por ejemplo, /api/elecciones/2/panel/02?categoriaId=2
|
// Este método se ejecutará cuando la URL sea, por ejemplo, /api/elecciones/2/panel/02?categoriaId=2
|
||||||
private async Task<IActionResult> GetPanelProvincial(int eleccionId, string distritoId, int categoriaId)
|
private async Task<IActionResult> GetPanelProvincial(int eleccionId, string distritoId, int categoriaId)
|
||||||
{
|
{
|
||||||
// 1. Validar y obtener la entidad de la provincia
|
|
||||||
var provincia = await _dbContext.AmbitosGeograficos.AsNoTracking()
|
var provincia = await _dbContext.AmbitosGeograficos.AsNoTracking()
|
||||||
.FirstOrDefaultAsync(a => a.DistritoId == distritoId && a.NivelId == 10);
|
.FirstOrDefaultAsync(a => a.DistritoId == distritoId && a.NivelId == 10);
|
||||||
|
if (provincia == null) return NotFound($"No se encontró la provincia con DistritoId {distritoId}.");
|
||||||
|
|
||||||
if (provincia == null)
|
// --- INICIO DE LA OPTIMIZACIÓN ---
|
||||||
{
|
// 1. Agrupar y sumar directamente en la base de datos. EF lo traducirá a un SQL eficiente.
|
||||||
_logger.LogWarning("Panel Provincial: La provincia {DistritoId} no fue encontrada en AmbitosGeograficos.", distritoId);
|
var resultadosAgregados = await _dbContext.ResultadosVotos.AsNoTracking()
|
||||||
return NotFound($"No se encontró la provincia con distritoId {distritoId}");
|
|
||||||
}
|
|
||||||
|
|
||||||
_logger.LogInformation("Panel Provincial: Provincia {Nombre} ({Id}) encontrada. Buscando municipios...", provincia.Nombre, provincia.Id);
|
|
||||||
|
|
||||||
// 2. Obtener los votos de TODOS los municipios de ESA provincia.
|
|
||||||
var resultadosCrudos = await _dbContext.ResultadosVotos.AsNoTracking()
|
|
||||||
.Include(r => r.AgrupacionPolitica)
|
|
||||||
.Include(r => r.AmbitoGeografico)
|
|
||||||
.Where(r => r.EleccionId == eleccionId &&
|
.Where(r => r.EleccionId == eleccionId &&
|
||||||
r.CategoriaId == categoriaId &&
|
r.CategoriaId == categoriaId &&
|
||||||
r.AmbitoGeografico.DistritoId == distritoId &&
|
r.AmbitoGeografico.DistritoId == distritoId &&
|
||||||
r.AmbitoGeografico.NivelId == 30)
|
r.AmbitoGeografico.NivelId == 30)
|
||||||
|
.GroupBy(r => r.AgrupacionPolitica) // Agrupar por la entidad
|
||||||
|
.Select(g => new
|
||||||
|
{
|
||||||
|
Agrupacion = g.Key,
|
||||||
|
TotalVotos = g.Sum(r => r.CantidadVotos)
|
||||||
|
})
|
||||||
.ToListAsync();
|
.ToListAsync();
|
||||||
|
|
||||||
if (!resultadosCrudos.Any())
|
// 2. Calcular el total de votos en memoria (sobre una lista ya pequeña)
|
||||||
{
|
var totalVotosProvincia = (decimal)resultadosAgregados.Sum(r => r.TotalVotos);
|
||||||
return Ok(new PanelElectoralDto
|
|
||||||
{
|
|
||||||
AmbitoNombre = provincia.Nombre,
|
|
||||||
MapaData = new List<ResultadoMapaDto>(),
|
|
||||||
ResultadosPanel = new List<AgrupacionResultadoDto>(),
|
|
||||||
EstadoRecuento = new EstadoRecuentoDto()
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// 3. Calcular los resultados para el PANEL LATERAL (agregado provincial)
|
// 3. Mapear a DTO (muy rápido)
|
||||||
var totalVotosProvincia = (decimal)resultadosCrudos.Sum(r => r.CantidadVotos);
|
var resultadosPanel = resultadosAgregados
|
||||||
var resultadosPanel = resultadosCrudos
|
|
||||||
.GroupBy(r => r.AgrupacionPolitica.Id)
|
|
||||||
.Select(g => new AgrupacionResultadoDto
|
.Select(g => new AgrupacionResultadoDto
|
||||||
{
|
{
|
||||||
Id = g.Key,
|
Id = g.Agrupacion.Id,
|
||||||
Nombre = g.First().AgrupacionPolitica.Nombre,
|
Nombre = g.Agrupacion.Nombre,
|
||||||
NombreCorto = g.First().AgrupacionPolitica.NombreCorto,
|
NombreCorto = g.Agrupacion.NombreCorto,
|
||||||
Color = g.First().AgrupacionPolitica.Color,
|
Color = g.Agrupacion.Color,
|
||||||
Votos = g.Sum(r => r.CantidadVotos),
|
Votos = g.TotalVotos,
|
||||||
Porcentaje = totalVotosProvincia > 0 ? (g.Sum(r => r.CantidadVotos) / totalVotosProvincia) * 100 : 0
|
Porcentaje = totalVotosProvincia > 0 ? (g.TotalVotos / totalVotosProvincia) * 100 : 0
|
||||||
})
|
})
|
||||||
.OrderByDescending(r => r.Votos)
|
.OrderByDescending(r => r.Votos)
|
||||||
.ToList();
|
.ToList();
|
||||||
|
// --- FIN DE LA OPTIMIZACIÓN ---
|
||||||
// --- CORRECCIÓN DEFINITIVA DE LA LÓGICA DEL MAPA ---
|
|
||||||
var mapaData = resultadosCrudos
|
|
||||||
.GroupBy(r => r.AmbitoGeografico) // 1. Agrupar por la entidad del municipio
|
|
||||||
.Select(g =>
|
|
||||||
{
|
|
||||||
// 2. DENTRO de cada grupo (municipio), encontrar la fila con más votos
|
|
||||||
var ganador = g.OrderByDescending(r => r.CantidadVotos).First();
|
|
||||||
|
|
||||||
// 3. Crear UN SOLO objeto ResultadoMapaDto para este municipio
|
|
||||||
return new ResultadoMapaDto
|
|
||||||
{
|
|
||||||
AmbitoId = g.Key.SeccionId!,
|
|
||||||
AmbitoNombre = g.Key.Nombre,
|
|
||||||
AgrupacionGanadoraId = ganador.AgrupacionPolitica.Id,
|
|
||||||
ColorGanador = ganador.AgrupacionPolitica.Color ?? "#808080"
|
|
||||||
};
|
|
||||||
})
|
|
||||||
.ToList();
|
|
||||||
|
|
||||||
var estadoRecuento = await _dbContext.EstadosRecuentosGenerales.AsNoTracking()
|
var estadoRecuento = await _dbContext.EstadosRecuentosGenerales.AsNoTracking()
|
||||||
.FirstOrDefaultAsync(e => e.EleccionId == eleccionId && e.AmbitoGeograficoId == provincia.Id && e.CategoriaId == categoriaId);
|
.FirstOrDefaultAsync(e => e.EleccionId == eleccionId && e.AmbitoGeograficoId == provincia.Id && e.CategoriaId == categoriaId);
|
||||||
@@ -1177,86 +1146,62 @@ public class ResultadosController : ControllerBase
|
|||||||
var respuesta = new PanelElectoralDto
|
var respuesta = new PanelElectoralDto
|
||||||
{
|
{
|
||||||
AmbitoNombre = provincia.Nombre,
|
AmbitoNombre = provincia.Nombre,
|
||||||
MapaData = mapaData,
|
MapaData = new List<ResultadoMapaDto>(), // Se carga por separado
|
||||||
ResultadosPanel = resultadosPanel,
|
ResultadosPanel = resultadosPanel,
|
||||||
EstadoRecuento = new EstadoRecuentoDto() // Simplificado para el ejemplo
|
EstadoRecuento = new EstadoRecuentoDto
|
||||||
|
{
|
||||||
|
ParticipacionPorcentaje = estadoRecuento?.ParticipacionPorcentaje ?? 0,
|
||||||
|
MesasTotalizadasPorcentaje = estadoRecuento?.MesasTotalizadasPorcentaje ?? 0
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
return Ok(respuesta);
|
return Ok(respuesta);
|
||||||
}
|
}
|
||||||
|
|
||||||
private async Task<IActionResult> GetPanelNacional(int eleccionId, int categoriaId)
|
private async Task<IActionResult> GetPanelNacional(int eleccionId, int categoriaId)
|
||||||
{
|
{
|
||||||
var resultadosCrudos = await _dbContext.ResultadosVotos.AsNoTracking()
|
// --- INICIO DE LA OPTIMIZACIÓN ---
|
||||||
.Include(r => r.AgrupacionPolitica)
|
// 1. Agrupar y sumar directamente en la base de datos a nivel nacional.
|
||||||
.Include(r => r.AmbitoGeografico)
|
var resultadosAgregados = await _dbContext.ResultadosVotos.AsNoTracking()
|
||||||
.Where(r => r.EleccionId == eleccionId && r.CategoriaId == categoriaId)
|
.Where(r => r.EleccionId == eleccionId && r.CategoriaId == categoriaId)
|
||||||
|
.GroupBy(r => r.AgrupacionPolitica)
|
||||||
|
.Select(g => new
|
||||||
|
{
|
||||||
|
Agrupacion = g.Key,
|
||||||
|
TotalVotos = g.Sum(r => r.CantidadVotos)
|
||||||
|
})
|
||||||
.ToListAsync();
|
.ToListAsync();
|
||||||
|
|
||||||
if (!resultadosCrudos.Any())
|
// 2. Calcular el total de votos en memoria
|
||||||
{
|
var totalVotosNacional = (decimal)resultadosAgregados.Sum(r => r.TotalVotos);
|
||||||
return Ok(new PanelElectoralDto
|
|
||||||
{
|
|
||||||
AmbitoNombre = "Argentina",
|
|
||||||
MapaData = new List<ResultadoMapaDto>(),
|
|
||||||
ResultadosPanel = new List<AgrupacionResultadoDto>(),
|
|
||||||
EstadoRecuento = new EstadoRecuentoDto()
|
|
||||||
});
|
|
||||||
}
|
|
||||||
|
|
||||||
// 2. Calcular los resultados para el panel
|
// 3. Mapear a DTO
|
||||||
var resultadosPanel = resultadosCrudos
|
var resultadosPanel = resultadosAgregados
|
||||||
.GroupBy(r => r.AgrupacionPolitica.Id)
|
.Select(g => new AgrupacionResultadoDto
|
||||||
.Select(g => new AgrupacionResultadoDto
|
{
|
||||||
{
|
Id = g.Agrupacion.Id,
|
||||||
// g.Key ahora es el ID de la agrupación
|
Nombre = g.Agrupacion.Nombre,
|
||||||
Id = g.Key,
|
NombreCorto = g.Agrupacion.NombreCorto,
|
||||||
// Tomamos los datos de la agrupación del primer elemento del grupo
|
Color = g.Agrupacion.Color,
|
||||||
Nombre = g.First().AgrupacionPolitica.Nombre,
|
Votos = g.TotalVotos,
|
||||||
NombreCorto = g.First().AgrupacionPolitica.NombreCorto,
|
Porcentaje = totalVotosNacional > 0 ? (g.TotalVotos / totalVotosNacional) * 100 : 0
|
||||||
Color = g.First().AgrupacionPolitica.Color,
|
})
|
||||||
Votos = g.Sum(r => r.CantidadVotos),
|
|
||||||
Porcentaje = (decimal)g.Sum(r => r.CantidadVotos) * 100 / resultadosCrudos.Sum(r => r.CantidadVotos)
|
|
||||||
})
|
|
||||||
.OrderByDescending(r => r.Votos)
|
.OrderByDescending(r => r.Votos)
|
||||||
.ToList();
|
.ToList();
|
||||||
|
// --- FIN DE LA OPTIMIZACIÓN ---
|
||||||
|
|
||||||
// 3. Calcular los datos para el mapa (ganador por provincia/distrito)
|
var estadoRecuento = await _dbContext.EstadosRecuentosGenerales.AsNoTracking()
|
||||||
var mapaData = resultadosCrudos
|
.FirstOrDefaultAsync(e => e.EleccionId == eleccionId && e.CategoriaId == categoriaId);
|
||||||
.Where(r => !string.IsNullOrEmpty(r.AmbitoGeografico.DistritoId))
|
|
||||||
.GroupBy(r => r.AmbitoGeografico.DistritoId)
|
|
||||||
.Select(g =>
|
|
||||||
{
|
|
||||||
var ganador = g.GroupBy(r => r.AgrupacionPoliticaId)
|
|
||||||
.Select(pg => new { Votos = pg.Sum(r => r.CantidadVotos), Agrupacion = pg.First().AgrupacionPolitica })
|
|
||||||
.OrderByDescending(x => x.Votos)
|
|
||||||
.First();
|
|
||||||
|
|
||||||
var provinciaAmbito = _dbContext.AmbitosGeograficos.AsNoTracking()
|
|
||||||
.FirstOrDefault(a => a.DistritoId == g.Key && a.NivelId == 10);
|
|
||||||
|
|
||||||
return new ResultadoMapaDto
|
|
||||||
{
|
|
||||||
AmbitoId = g.Key!,
|
|
||||||
AmbitoNombre = provinciaAmbito?.Nombre ?? "Desconocido", // <-- ENVIAMOS EL NOMBRE DE LA PROVINCIA
|
|
||||||
AgrupacionGanadoraId = ganador.Agrupacion.Id,
|
|
||||||
ColorGanador = ganador.Agrupacion.Color ?? "#808080"
|
|
||||||
};
|
|
||||||
})
|
|
||||||
.ToList();
|
|
||||||
|
|
||||||
// 4. Obtener el estado del recuento general
|
|
||||||
// Asumimos que existe un registro en EstadosRecuentosGenerales para el ámbito de la elección
|
|
||||||
var estadoRecuento = await _dbContext.EstadosRecuentosGenerales
|
|
||||||
.AsNoTracking()
|
|
||||||
.FirstOrDefaultAsync(e => e.EleccionId == eleccionId);
|
|
||||||
|
|
||||||
var respuesta = new PanelElectoralDto
|
var respuesta = new PanelElectoralDto
|
||||||
{
|
{
|
||||||
AmbitoNombre = "Argentina",
|
AmbitoNombre = "Argentina",
|
||||||
MapaData = mapaData,
|
MapaData = new List<ResultadoMapaDto>(), // Se carga por separado
|
||||||
ResultadosPanel = resultadosPanel,
|
ResultadosPanel = resultadosPanel,
|
||||||
EstadoRecuento = new EstadoRecuentoDto()
|
EstadoRecuento = new EstadoRecuentoDto
|
||||||
|
{
|
||||||
|
ParticipacionPorcentaje = estadoRecuento?.ParticipacionPorcentaje ?? 0,
|
||||||
|
MesasTotalizadasPorcentaje = estadoRecuento?.MesasTotalizadasPorcentaje ?? 0
|
||||||
|
}
|
||||||
};
|
};
|
||||||
return Ok(respuesta);
|
return Ok(respuesta);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -237,7 +237,7 @@ using (var scope = app.Services.CreateScope())
|
|||||||
|
|
||||||
var provinciasMaestras = new Dictionary<string, string>
|
var provinciasMaestras = new Dictionary<string, string>
|
||||||
{
|
{
|
||||||
{ "01", "CABA" }, { "02", "BUENOS AIRES" }, { "03", "CATAMARCA" }, { "04", "CORDOBA" },
|
{ "01", "CIUDAD AUTONOMA DE BUENOS AIRES" }, { "02", "BUENOS AIRES" }, { "03", "CATAMARCA" }, { "04", "CORDOBA" },
|
||||||
{ "05", "CORRIENTES" },{ "06", "CHACO" }, { "07", "CHUBUT" }, { "08", "ENTRE RIOS" },
|
{ "05", "CORRIENTES" },{ "06", "CHACO" }, { "07", "CHUBUT" }, { "08", "ENTRE RIOS" },
|
||||||
{ "09", "FORMOSA" }, { "10", "JUJUY" }, { "11", "LA PAMPA" }, { "12", "LA RIOJA" },
|
{ "09", "FORMOSA" }, { "10", "JUJUY" }, { "11", "LA PAMPA" }, { "12", "LA RIOJA" },
|
||||||
{ "13", "MENDOZA" }, { "14", "MISIONES" }, { "15", "NEUQUEN" }, { "16", "RIO NEGRO" },
|
{ "13", "MENDOZA" }, { "14", "MISIONES" }, { "15", "NEUQUEN" }, { "16", "RIO NEGRO" },
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ using System.Reflection;
|
|||||||
[assembly: System.Reflection.AssemblyCompanyAttribute("Elecciones.Api")]
|
[assembly: System.Reflection.AssemblyCompanyAttribute("Elecciones.Api")]
|
||||||
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
||||||
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
||||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+64dc7ef440f585cb5e7723585b6327d5387f1b32")]
|
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+3a8f64bf854b2bdf66d83e503aaacc7dca77138e")]
|
||||||
[assembly: System.Reflection.AssemblyProductAttribute("Elecciones.Api")]
|
[assembly: System.Reflection.AssemblyProductAttribute("Elecciones.Api")]
|
||||||
[assembly: System.Reflection.AssemblyTitleAttribute("Elecciones.Api")]
|
[assembly: System.Reflection.AssemblyTitleAttribute("Elecciones.Api")]
|
||||||
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
||||||
|
|||||||
@@ -1 +1 @@
|
|||||||
{"GlobalPropertiesHash":"b5T/+ta4fUd8qpIzUTm3KyEwAYYUsU5ASo+CSFM3ByE=","FingerprintPatternsHash":"8ZRc1sGeVrPBx4lD717BgRaQekyh78QKV9SKsdt638U=","PropertyOverridesHash":"8ZRc1sGeVrPBx4lD717BgRaQekyh78QKV9SKsdt638U=","InputHashes":["TyIJk/eQMWjmB5LsDE\u002BZIJC9P9ciVxd7bnzRiTZsGt4=","t631p0kaOa0gMRIcaPzz1ZVPZ1kuq4pq4kYPWQgoPcM=","PA/Beu9jJpOBY5r5Y1CiSyqrARA2j7LHeWYUnEZpQO8=","E2ODTAlJxzsXY1iP1eB/02NIUK\u002BnQveGlWAOHY1cpgA=","6WTvWQ72AaZBYOVSmaxaci9tc1dW5p7IK9Kscjj2cb0=","vAy46VJ9Gp8QqG/Px4J1mj8jL6ws4/A01UKRmMYfYek=","cdgbHR/E4DJsddPc\u002BTpzoUMOVNaFJZm33Pw7AxU9Ees=","4r4JGR4hS5m4rsLfuCSZxzrknTBxKFkLQDXc\u002B2KbqTU=","yVoZ4UnBcSOapsJIi046hnn7ylD3jAcEBUxQ\u002Brkvj/4=","/GfbpJthEWmsuz0uFx1QLHM7gyM1wLLeQgAIl4SzUD4=","i5\u002B5LcfxQD8meRAkQbVf4wMvjxSE4\u002BjCd2/FdPtMpms=","AvSkxVPIg0GjnB1RJ4hDNyo9p9GONrzDs8uVuixH\u002BOE=","IgT9pOgRnK37qfILj2QcjFoBZ180HMt\u002BScgje2iYOo4=","ezUlOMzNZmyKDIe1wwXqvX\u002BvhwfB992xNVts7r2zcTc=","y2BV4WpkQuLfqQhfOQBtmuzh940c3s4LAopGKfztfTE=","lHTUEsMkDu8nqXtfTwl7FRfgocyyc7RI5O/edTHN1\u002B0=","A7nz7qgOtQ1CwZZLvNnr0b5QZB3fTi3y4i6y7rBIcxQ=","znnuRi2tsk7AACuYo4WSgj7NcLriG4PKVaF4L35SvDk=","GelE32odx/vTului267wqi6zL3abBnF9yvwC2Q66LoM=","TEsXImnzxFKTIq2f5fiDu7i6Ar/cbecW5MZ3z8Wb/a4=","5WogJu\u002BUPlF\u002BE5mq/ILtDXpVwqwmhHtsEB13nmT5JJk=","dcHQRkttjMjo2dvhL7hA9t4Pg\u002B7OnjZpkFmakT4QR9U=","Of8nTYw5l\u002BgiAJo7z6XYIntG2tUtCFcILzHbTiiXn\u002Bw=","PDy\u002BTiayvNAoXXBEgwC/kCojpgOOMI6RQOIoSXs3LJc=","ePXrkee3hv3wHUr8S7aYmRVvXUTxQf76zApKGv3/l3o=","DXx5dQywLo3UsY2zQaUG\u002BbW4ObiYbybxPBWxeJD2bhk=","muVh5sjH3sgdvuz4TbuTwTggX1uDnsWXgoosMKST/r4=","nrP5gSIA5vzgp8v12CAOr943QYLxU4Til6oiCcWSNI8=","yMd45U9BK07I3b3fBQ627PWTYyZ2ZjrmFc5VD\u002BQVx1Q=","xKskvcoJU0RVRN1a5dRqKRM7IP5vmmbraUaPFYjhnCc=","p7BjQw7aSZjfOCqmKm7/kPO9qegEQZBfirMjlOx/I1I=","xf7fvi/A0tUBZMxhPJDER8vuJQH2E3gyAnDWXXhOyD0=","P8JRhYPpULTLMAydvl3Ky\u002B92/tYDIjui0l66En4aXuQ=","sfQbd729CZjIZCr20t2H\u002BLd7hI/GEf6\u002BdyvRnmo8MpU="],"CachedAssets":{},"CachedCopyCandidates":{}}
|
{"GlobalPropertiesHash":"b5T/+ta4fUd8qpIzUTm3KyEwAYYUsU5ASo+CSFM3ByE=","FingerprintPatternsHash":"8ZRc1sGeVrPBx4lD717BgRaQekyh78QKV9SKsdt638U=","PropertyOverridesHash":"8ZRc1sGeVrPBx4lD717BgRaQekyh78QKV9SKsdt638U=","InputHashes":["TyIJk/eQMWjmB5LsDE\u002BZIJC9P9ciVxd7bnzRiTZsGt4=","t631p0kaOa0gMRIcaPzz1ZVPZ1kuq4pq4kYPWQgoPcM=","PA/Beu9jJpOBY5r5Y1CiSyqrARA2j7LHeWYUnEZpQO8=","E2ODTAlJxzsXY1iP1eB/02NIUK\u002BnQveGlWAOHY1cpgA=","6WTvWQ72AaZBYOVSmaxaci9tc1dW5p7IK9Kscjj2cb0=","vAy46VJ9Gp8QqG/Px4J1mj8jL6ws4/A01UKRmMYfYek=","cdgbHR/E4DJsddPc\u002BTpzoUMOVNaFJZm33Pw7AxU9Ees=","4r4JGR4hS5m4rsLfuCSZxzrknTBxKFkLQDXc\u002B2KbqTU=","yVoZ4UnBcSOapsJIi046hnn7ylD3jAcEBUxQ\u002Brkvj/4=","/GfbpJthEWmsuz0uFx1QLHM7gyM1wLLeQgAIl4SzUD4=","i5\u002B5LcfxQD8meRAkQbVf4wMvjxSE4\u002BjCd2/FdPtMpms=","AvSkxVPIg0GjnB1RJ4hDNyo9p9GONrzDs8uVuixH\u002BOE=","IgT9pOgRnK37qfILj2QcjFoBZ180HMt\u002BScgje2iYOo4=","ezUlOMzNZmyKDIe1wwXqvX\u002BvhwfB992xNVts7r2zcTc=","y2BV4WpkQuLfqQhfOQBtmuzh940c3s4LAopGKfztfTE=","lHTUEsMkDu8nqXtfTwl7FRfgocyyc7RI5O/edTHN1\u002B0=","A7nz7qgOtQ1CwZZLvNnr0b5QZB3fTi3y4i6y7rBIcxQ=","znnuRi2tsk7AACuYo4WSgj7NcLriG4PKVaF4L35SvDk=","GelE32odx/vTului267wqi6zL3abBnF9yvwC2Q66LoM=","TEsXImnzxFKTIq2f5fiDu7i6Ar/cbecW5MZ3z8Wb/a4=","5WogJu\u002BUPlF\u002BE5mq/ILtDXpVwqwmhHtsEB13nmT5JJk=","dcHQRkttjMjo2dvhL7hA9t4Pg\u002B7OnjZpkFmakT4QR9U=","Of8nTYw5l\u002BgiAJo7z6XYIntG2tUtCFcILzHbTiiXn\u002Bw=","PDy\u002BTiayvNAoXXBEgwC/kCojpgOOMI6RQOIoSXs3LJc=","ePXrkee3hv3wHUr8S7aYmRVvXUTxQf76zApKGv3/l3o=","DXx5dQywLo3UsY2zQaUG\u002BbW4ObiYbybxPBWxeJD2bhk=","muVh5sjH3sgdvuz4TbuTwTggX1uDnsWXgoosMKST/r4=","nrP5gSIA5vzgp8v12CAOr943QYLxU4Til6oiCcWSNI8=","yMd45U9BK07I3b3fBQ627PWTYyZ2ZjrmFc5VD\u002BQVx1Q=","xKskvcoJU0RVRN1a5dRqKRM7IP5vmmbraUaPFYjhnCc=","p7BjQw7aSZjfOCqmKm7/kPO9qegEQZBfirMjlOx/I1I=","MI0hVVLYavEhzHq/Z1UbajfrxanA1aET19aOH8G2ImI=","46MA\u002Blq7j9R/uzmiVYtYpsRnGYG/Wwao3ZdubH\u002B4izQ=","P8JRhYPpULTLMAydvl3Ky\u002B92/tYDIjui0l66En4aXuQ=","bU7YiR/er3vUMAl0wuUE995hYVK8QhuhabOYX6kCMds="],"CachedAssets":{},"CachedCopyCandidates":{}}
|
||||||
@@ -1 +1 @@
|
|||||||
{"GlobalPropertiesHash":"tJTBjV/i0Ihkc6XuOu69wxL8PBac9c9Kak6srMso4pU=","FingerprintPatternsHash":"8ZRc1sGeVrPBx4lD717BgRaQekyh78QKV9SKsdt638U=","PropertyOverridesHash":"8ZRc1sGeVrPBx4lD717BgRaQekyh78QKV9SKsdt638U=","InputHashes":["TyIJk/eQMWjmB5LsDE\u002BZIJC9P9ciVxd7bnzRiTZsGt4=","t631p0kaOa0gMRIcaPzz1ZVPZ1kuq4pq4kYPWQgoPcM=","PA/Beu9jJpOBY5r5Y1CiSyqrARA2j7LHeWYUnEZpQO8=","E2ODTAlJxzsXY1iP1eB/02NIUK\u002BnQveGlWAOHY1cpgA=","6WTvWQ72AaZBYOVSmaxaci9tc1dW5p7IK9Kscjj2cb0=","vAy46VJ9Gp8QqG/Px4J1mj8jL6ws4/A01UKRmMYfYek=","cdgbHR/E4DJsddPc\u002BTpzoUMOVNaFJZm33Pw7AxU9Ees=","4r4JGR4hS5m4rsLfuCSZxzrknTBxKFkLQDXc\u002B2KbqTU=","yVoZ4UnBcSOapsJIi046hnn7ylD3jAcEBUxQ\u002Brkvj/4=","/GfbpJthEWmsuz0uFx1QLHM7gyM1wLLeQgAIl4SzUD4=","i5\u002B5LcfxQD8meRAkQbVf4wMvjxSE4\u002BjCd2/FdPtMpms=","AvSkxVPIg0GjnB1RJ4hDNyo9p9GONrzDs8uVuixH\u002BOE=","IgT9pOgRnK37qfILj2QcjFoBZ180HMt\u002BScgje2iYOo4=","ezUlOMzNZmyKDIe1wwXqvX\u002BvhwfB992xNVts7r2zcTc=","y2BV4WpkQuLfqQhfOQBtmuzh940c3s4LAopGKfztfTE=","lHTUEsMkDu8nqXtfTwl7FRfgocyyc7RI5O/edTHN1\u002B0=","A7nz7qgOtQ1CwZZLvNnr0b5QZB3fTi3y4i6y7rBIcxQ=","znnuRi2tsk7AACuYo4WSgj7NcLriG4PKVaF4L35SvDk=","GelE32odx/vTului267wqi6zL3abBnF9yvwC2Q66LoM=","TEsXImnzxFKTIq2f5fiDu7i6Ar/cbecW5MZ3z8Wb/a4=","5WogJu\u002BUPlF\u002BE5mq/ILtDXpVwqwmhHtsEB13nmT5JJk=","dcHQRkttjMjo2dvhL7hA9t4Pg\u002B7OnjZpkFmakT4QR9U=","Of8nTYw5l\u002BgiAJo7z6XYIntG2tUtCFcILzHbTiiXn\u002Bw=","PDy\u002BTiayvNAoXXBEgwC/kCojpgOOMI6RQOIoSXs3LJc=","ePXrkee3hv3wHUr8S7aYmRVvXUTxQf76zApKGv3/l3o=","DXx5dQywLo3UsY2zQaUG\u002BbW4ObiYbybxPBWxeJD2bhk=","muVh5sjH3sgdvuz4TbuTwTggX1uDnsWXgoosMKST/r4=","nrP5gSIA5vzgp8v12CAOr943QYLxU4Til6oiCcWSNI8=","yMd45U9BK07I3b3fBQ627PWTYyZ2ZjrmFc5VD\u002BQVx1Q=","xKskvcoJU0RVRN1a5dRqKRM7IP5vmmbraUaPFYjhnCc=","p7BjQw7aSZjfOCqmKm7/kPO9qegEQZBfirMjlOx/I1I=","xf7fvi/A0tUBZMxhPJDER8vuJQH2E3gyAnDWXXhOyD0=","P8JRhYPpULTLMAydvl3Ky\u002B92/tYDIjui0l66En4aXuQ=","sfQbd729CZjIZCr20t2H\u002BLd7hI/GEf6\u002BdyvRnmo8MpU="],"CachedAssets":{},"CachedCopyCandidates":{}}
|
{"GlobalPropertiesHash":"tJTBjV/i0Ihkc6XuOu69wxL8PBac9c9Kak6srMso4pU=","FingerprintPatternsHash":"8ZRc1sGeVrPBx4lD717BgRaQekyh78QKV9SKsdt638U=","PropertyOverridesHash":"8ZRc1sGeVrPBx4lD717BgRaQekyh78QKV9SKsdt638U=","InputHashes":["TyIJk/eQMWjmB5LsDE\u002BZIJC9P9ciVxd7bnzRiTZsGt4=","t631p0kaOa0gMRIcaPzz1ZVPZ1kuq4pq4kYPWQgoPcM=","PA/Beu9jJpOBY5r5Y1CiSyqrARA2j7LHeWYUnEZpQO8=","E2ODTAlJxzsXY1iP1eB/02NIUK\u002BnQveGlWAOHY1cpgA=","6WTvWQ72AaZBYOVSmaxaci9tc1dW5p7IK9Kscjj2cb0=","vAy46VJ9Gp8QqG/Px4J1mj8jL6ws4/A01UKRmMYfYek=","cdgbHR/E4DJsddPc\u002BTpzoUMOVNaFJZm33Pw7AxU9Ees=","4r4JGR4hS5m4rsLfuCSZxzrknTBxKFkLQDXc\u002B2KbqTU=","yVoZ4UnBcSOapsJIi046hnn7ylD3jAcEBUxQ\u002Brkvj/4=","/GfbpJthEWmsuz0uFx1QLHM7gyM1wLLeQgAIl4SzUD4=","i5\u002B5LcfxQD8meRAkQbVf4wMvjxSE4\u002BjCd2/FdPtMpms=","AvSkxVPIg0GjnB1RJ4hDNyo9p9GONrzDs8uVuixH\u002BOE=","IgT9pOgRnK37qfILj2QcjFoBZ180HMt\u002BScgje2iYOo4=","ezUlOMzNZmyKDIe1wwXqvX\u002BvhwfB992xNVts7r2zcTc=","y2BV4WpkQuLfqQhfOQBtmuzh940c3s4LAopGKfztfTE=","lHTUEsMkDu8nqXtfTwl7FRfgocyyc7RI5O/edTHN1\u002B0=","A7nz7qgOtQ1CwZZLvNnr0b5QZB3fTi3y4i6y7rBIcxQ=","znnuRi2tsk7AACuYo4WSgj7NcLriG4PKVaF4L35SvDk=","GelE32odx/vTului267wqi6zL3abBnF9yvwC2Q66LoM=","TEsXImnzxFKTIq2f5fiDu7i6Ar/cbecW5MZ3z8Wb/a4=","5WogJu\u002BUPlF\u002BE5mq/ILtDXpVwqwmhHtsEB13nmT5JJk=","dcHQRkttjMjo2dvhL7hA9t4Pg\u002B7OnjZpkFmakT4QR9U=","Of8nTYw5l\u002BgiAJo7z6XYIntG2tUtCFcILzHbTiiXn\u002Bw=","PDy\u002BTiayvNAoXXBEgwC/kCojpgOOMI6RQOIoSXs3LJc=","ePXrkee3hv3wHUr8S7aYmRVvXUTxQf76zApKGv3/l3o=","DXx5dQywLo3UsY2zQaUG\u002BbW4ObiYbybxPBWxeJD2bhk=","muVh5sjH3sgdvuz4TbuTwTggX1uDnsWXgoosMKST/r4=","nrP5gSIA5vzgp8v12CAOr943QYLxU4Til6oiCcWSNI8=","yMd45U9BK07I3b3fBQ627PWTYyZ2ZjrmFc5VD\u002BQVx1Q=","xKskvcoJU0RVRN1a5dRqKRM7IP5vmmbraUaPFYjhnCc=","p7BjQw7aSZjfOCqmKm7/kPO9qegEQZBfirMjlOx/I1I=","MI0hVVLYavEhzHq/Z1UbajfrxanA1aET19aOH8G2ImI=","46MA\u002Blq7j9R/uzmiVYtYpsRnGYG/Wwao3ZdubH\u002B4izQ=","P8JRhYPpULTLMAydvl3Ky\u002B92/tYDIjui0l66En4aXuQ=","bU7YiR/er3vUMAl0wuUE995hYVK8QhuhabOYX6kCMds="],"CachedAssets":{},"CachedCopyCandidates":{}}
|
||||||
@@ -13,7 +13,7 @@ using System.Reflection;
|
|||||||
[assembly: System.Reflection.AssemblyCompanyAttribute("Elecciones.Core")]
|
[assembly: System.Reflection.AssemblyCompanyAttribute("Elecciones.Core")]
|
||||||
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
||||||
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
||||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+64dc7ef440f585cb5e7723585b6327d5387f1b32")]
|
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+3a8f64bf854b2bdf66d83e503aaacc7dca77138e")]
|
||||||
[assembly: System.Reflection.AssemblyProductAttribute("Elecciones.Core")]
|
[assembly: System.Reflection.AssemblyProductAttribute("Elecciones.Core")]
|
||||||
[assembly: System.Reflection.AssemblyTitleAttribute("Elecciones.Core")]
|
[assembly: System.Reflection.AssemblyTitleAttribute("Elecciones.Core")]
|
||||||
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ using System.Reflection;
|
|||||||
[assembly: System.Reflection.AssemblyCompanyAttribute("Elecciones.Database")]
|
[assembly: System.Reflection.AssemblyCompanyAttribute("Elecciones.Database")]
|
||||||
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
||||||
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
||||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+64dc7ef440f585cb5e7723585b6327d5387f1b32")]
|
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+3a8f64bf854b2bdf66d83e503aaacc7dca77138e")]
|
||||||
[assembly: System.Reflection.AssemblyProductAttribute("Elecciones.Database")]
|
[assembly: System.Reflection.AssemblyProductAttribute("Elecciones.Database")]
|
||||||
[assembly: System.Reflection.AssemblyTitleAttribute("Elecciones.Database")]
|
[assembly: System.Reflection.AssemblyTitleAttribute("Elecciones.Database")]
|
||||||
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
||||||
|
|||||||
@@ -13,7 +13,7 @@ using System.Reflection;
|
|||||||
[assembly: System.Reflection.AssemblyCompanyAttribute("Elecciones.Infrastructure")]
|
[assembly: System.Reflection.AssemblyCompanyAttribute("Elecciones.Infrastructure")]
|
||||||
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
||||||
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
||||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+64dc7ef440f585cb5e7723585b6327d5387f1b32")]
|
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+3a8f64bf854b2bdf66d83e503aaacc7dca77138e")]
|
||||||
[assembly: System.Reflection.AssemblyProductAttribute("Elecciones.Infrastructure")]
|
[assembly: System.Reflection.AssemblyProductAttribute("Elecciones.Infrastructure")]
|
||||||
[assembly: System.Reflection.AssemblyTitleAttribute("Elecciones.Infrastructure")]
|
[assembly: System.Reflection.AssemblyTitleAttribute("Elecciones.Infrastructure")]
|
||||||
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ using System.Reflection;
|
|||||||
[assembly: System.Reflection.AssemblyCompanyAttribute("Elecciones.Worker")]
|
[assembly: System.Reflection.AssemblyCompanyAttribute("Elecciones.Worker")]
|
||||||
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
||||||
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
||||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+843c0f725893a48eae1236473cb5eeb00ef3d91c")]
|
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+3a8f64bf854b2bdf66d83e503aaacc7dca77138e")]
|
||||||
[assembly: System.Reflection.AssemblyProductAttribute("Elecciones.Worker")]
|
[assembly: System.Reflection.AssemblyProductAttribute("Elecciones.Worker")]
|
||||||
[assembly: System.Reflection.AssemblyTitleAttribute("Elecciones.Worker")]
|
[assembly: System.Reflection.AssemblyTitleAttribute("Elecciones.Worker")]
|
||||||
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
||||||
|
|||||||
Reference in New Issue
Block a user