sapenlinea-components 0.6.65 → 0.6.66

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -3115,7 +3115,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
3115
3115
 
3116
3116
  class FeatureCard {
3117
3117
  /** Objeto feature (con soporte para binding bidireccional vía señales) */
3118
- feature = model(undefined, ...(ngDevMode ? [{ debugName: "feature" }] : []));
3118
+ feature = model(...(ngDevMode ? [undefined, { debugName: "feature" }] : []));
3119
3119
  showLeading = input(false, ...(ngDevMode ? [{ debugName: "showLeading" }] : []));
3120
3120
  showTrailling = input(false, ...(ngDevMode ? [{ debugName: "showTrailling" }] : []));
3121
3121
  /** Valor interno de la descripción mientras se edita */
@@ -5143,32 +5143,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
5143
5143
  args: [{ selector: 'lib-heatmap', imports: [BaseChart], template: "<div class=\"heatmap-container\" [class.expanded]=\"isExpanded()\">\r\n <div class=\"heatmap-header\">\r\n <h3 class=\"heatmap-title\">{{ title() }}</h3>\r\n <button class=\"expand-btn\" (click)=\"toggleExpand()\" type=\"button\" [attr.aria-label]=\"isExpanded() ? 'Minimize chart' : 'Maximize chart'\">\r\n @if (isExpanded()) {\r\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"lucide lucide-minimize-2\"><polyline points=\"4 14 10 14 10 20\"/><polyline points=\"20 10 14 10 14 4\"/><line x1=\"14\" x2=\"21\" y1=\"10\" y2=\"3\"/><line x1=\"3\" x2=\"10\" y1=\"21\" y2=\"14\"/></svg>\r\n } @else {\r\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"lucide lucide-maximize-2\"><polyline points=\"15 3 21 3 21 9\"/><polyline points=\"9 21 3 21 3 15\"/><line x1=\"21\" x2=\"14\" y1=\"3\" y2=\"10\"/><line x1=\"3\" x2=\"10\" y1=\"21\" y2=\"14\"/></svg>\r\n }\r\n </button>\r\n </div>\r\n <lib-base-chart [options]=\"options()\" class=\"chart-wrapper\" />\r\n</div>\r\n@if (isExpanded()) {\r\n <div class=\"overlay\" (click)=\"toggleExpand()\"></div>\r\n}", styles: [":host{display:block;width:100%;min-width:0}.heatmap-container{width:100%;min-width:0;display:flex;flex-direction:column;gap:16px;background-color:#f0f0db;padding:24px 16px 16px;border-radius:20px;position:relative;transition:all .3s ease}.heatmap-container.expanded{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);width:90vw;height:90vh;z-index:9999;box-shadow:0 25px 50px -12px #00000040;margin:0}.chart-wrapper{flex:1;min-height:300px;display:block;width:100%;min-width:0}.heatmap-container.expanded .chart-wrapper{min-height:unset;height:100%}.heatmap-header{display:flex;justify-content:space-between;align-items:center;gap:16px}.heatmap-title{font-size:20px;font-weight:600;color:#333;font-family:Inter,sans-serif}.expand-btn{background:transparent;border:none;cursor:pointer;color:#61661f;padding:6px;border-radius:8px;display:flex;align-items:center;justify-content:center;transition:background-color .2s}.expand-btn:hover{background-color:#61661f1a}.overlay{position:fixed;top:0;left:0;width:100vw;height:100vh;background-color:#0006;-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);z-index:9998}\n"] }]
5144
5144
  }], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], config: [{ type: i0.Input, args: [{ isSignal: true, alias: "config", required: false }] }] } });
5145
5145
 
5146
- const Colors = {
5147
- primary: '#4B5E05',
5148
- secondary: '#063546',
5149
- tertiary: '#6B0518',
5150
- quaternary: '#F57C00',
5151
- };
5152
- class KpiCard {
5153
- title = input('Titulo', ...(ngDevMode ? [{ debugName: "title" }] : []));
5154
- description = input('Descripción', ...(ngDevMode ? [{ debugName: "description" }] : []));
5155
- value = input('0', ...(ngDevMode ? [{ debugName: "value" }] : []));
5156
- iconColor = input('primary', ...(ngDevMode ? [{ debugName: "iconColor" }] : []));
5157
- resolvedIconColor = computed(() => {
5158
- const color = this.iconColor();
5159
- // Revisa si es un predeterminado, si no, lo asume como hex code.
5160
- return Colors[color] || color;
5161
- }, ...(ngDevMode ? [{ debugName: "resolvedIconColor" }] : []));
5162
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: KpiCard, deps: [], target: i0.ɵɵFactoryTarget.Component });
5163
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.16", type: KpiCard, isStandalone: true, selector: "lib-kpi-card", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, iconColor: { classPropertyName: "iconColor", publicName: "iconColor", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"kpi-card\">\n <div class=\"kpi-card-text\">\n <h3 class=\"kpi-title\">{{ title() }}</h3>\n <p class=\"kpi-description\">{{ description() }}</p>\n <h2 class=\"kpi-value\">{{ value() }}</h2>\n </div>\n <div class=\"kpi-icon-container\" [style.--kpi-base-color]=\"resolvedIconColor()\">\n <ng-content select=\"[icon]\"></ng-content>\n </div>\n</div>\n", styles: [".kpi-card{background-color:#f0f0db;border-radius:20px;padding:24px;display:flex;justify-content:space-between;font-family:Roboto,sans-serif;min-width:260px}.kpi-card-text{display:flex;flex-direction:column}.kpi-title{font-size:20px;font-weight:700;color:#37474f;margin:0 0 4px}.kpi-description{font-size:15px;font-weight:500;color:#546e7a;margin:0 0 16px}.kpi-value{font-size:28px;font-weight:800;color:#10161a;margin:0;line-height:1}.kpi-icon-container{width:72px;height:72px;background-color:var(--kpi-base-color, #4B5E05);color:color-mix(in srgb,var(--kpi-base-color, #4B5E05) 35%,white);border-radius:50%;display:flex;justify-content:center;align-items:center;flex-shrink:0;box-shadow:0 4px 6px #0000000d}::ng-deep .kpi-icon-container svg{width:32px;height:32px;stroke:currentColor;stroke-width:2}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }] });
5164
- }
5165
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: KpiCard, decorators: [{
5166
- type: Component,
5167
- args: [{ selector: 'lib-kpi-card', imports: [CommonModule], template: "<div class=\"kpi-card\">\n <div class=\"kpi-card-text\">\n <h3 class=\"kpi-title\">{{ title() }}</h3>\n <p class=\"kpi-description\">{{ description() }}</p>\n <h2 class=\"kpi-value\">{{ value() }}</h2>\n </div>\n <div class=\"kpi-icon-container\" [style.--kpi-base-color]=\"resolvedIconColor()\">\n <ng-content select=\"[icon]\"></ng-content>\n </div>\n</div>\n", styles: [".kpi-card{background-color:#f0f0db;border-radius:20px;padding:24px;display:flex;justify-content:space-between;font-family:Roboto,sans-serif;min-width:260px}.kpi-card-text{display:flex;flex-direction:column}.kpi-title{font-size:20px;font-weight:700;color:#37474f;margin:0 0 4px}.kpi-description{font-size:15px;font-weight:500;color:#546e7a;margin:0 0 16px}.kpi-value{font-size:28px;font-weight:800;color:#10161a;margin:0;line-height:1}.kpi-icon-container{width:72px;height:72px;background-color:var(--kpi-base-color, #4B5E05);color:color-mix(in srgb,var(--kpi-base-color, #4B5E05) 35%,white);border-radius:50%;display:flex;justify-content:center;align-items:center;flex-shrink:0;box-shadow:0 4px 6px #0000000d}::ng-deep .kpi-icon-container svg{width:32px;height:32px;stroke:currentColor;stroke-width:2}\n"] }]
5168
- }], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], description: [{ type: i0.Input, args: [{ isSignal: true, alias: "description", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }], iconColor: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconColor", required: false }] }] } });
5169
-
5170
5146
  class GeoAPIMaps {
5147
+ points = input([], ...(ngDevMode ? [{ debugName: "points" }] : []));
5171
5148
  map;
5149
+ markers = [];
5150
+ constructor() {
5151
+ effect(() => {
5152
+ const pts = this.points();
5153
+ if (this.map && pts.length > 0) {
5154
+ this.renderPoints(pts);
5155
+ }
5156
+ });
5157
+ }
5172
5158
  ngAfterViewInit() {
5173
5159
  this.initMap();
5174
5160
  }
@@ -5177,11 +5163,11 @@ class GeoAPIMaps {
5177
5163
  if (!mapElement)
5178
5164
  return;
5179
5165
  this.map = new google.maps.Map(mapElement, {
5180
- center: { lat: 10.9878, lng: -74.7889 }, // Barranquilla
5181
- zoom: 15,
5166
+ center: { lat: 10.96854, lng: -74.78132 }, // Barranquilla
5167
+ zoom: 13,
5182
5168
  clickableIcons: false,
5183
5169
  mapId: '1b033ea586ba5df9c6dc091a',
5184
- // 🔥 Opciones para ocultar controles
5170
+ // Opciones para ocultar controles
5185
5171
  mapTypeControl: false, // quita el botón "Mapa/Satélite"
5186
5172
  streetViewControl: true, // quita Street View
5187
5173
  fullscreenControl: false, // quita fullscreen
@@ -5191,6 +5177,10 @@ class GeoAPIMaps {
5191
5177
  position: google.maps.ControlPosition.TOP_LEFT // mueve el zoom a la parte superior izquierda
5192
5178
  },
5193
5179
  });
5180
+ // Render points if they already exist when map is ready
5181
+ if (this.points().length > 0) {
5182
+ this.renderPoints(this.points());
5183
+ }
5194
5184
  }
5195
5185
  goToLocation(lat, lng) {
5196
5186
  if (!this.map)
@@ -5203,13 +5193,129 @@ class GeoAPIMaps {
5203
5193
  this.map.panTo(position);
5204
5194
  this.map.setZoom(18);
5205
5195
  }
5196
+ clearMarkers() {
5197
+ this.markers.forEach(m => m.map = null);
5198
+ this.markers = [];
5199
+ }
5200
+ renderPoints(points) {
5201
+ this.clearMarkers();
5202
+ const infoWindow = new google.maps.InfoWindow();
5203
+ let lockedMarker = null;
5204
+ points.forEach(point => {
5205
+ const dot = document.createElement('div');
5206
+ dot.style.width = '16px';
5207
+ dot.style.height = '16px';
5208
+ dot.style.borderRadius = '50%';
5209
+ dot.style.backgroundColor = point.immobilized ? '#ef4444' : '#3b82f6';
5210
+ dot.style.border = '2px solid white';
5211
+ dot.style.boxShadow = '0 2px 4px rgba(0,0,0,0.2)';
5212
+ dot.style.cursor = 'pointer';
5213
+ const marker = new google.maps.marker.AdvancedMarkerElement({
5214
+ position: { lat: point.latitude, lng: point.longitude },
5215
+ map: this.map,
5216
+ content: dot,
5217
+ });
5218
+ const content = `
5219
+ <div style="padding: 0 12px 12px 12px; font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; min-width: 200px; color: #374151;">
5220
+ <div style="font-weight: 700; font-size: 15px; color: #111827; margin-bottom: 8px; line-height: 1.2;">
5221
+ ${point.subpoenaNumber}
5222
+ </div>
5223
+ <div style="font-size: 14px; color: #4b5563; margin-bottom: 4px;">
5224
+ ${point.locationLabel}
5225
+ </div>
5226
+ <div style="font-size: 14px; color: #6b7280; margin-bottom: 4px;">
5227
+ ${point.dateTime.replace('T', ' - ').substring(0, 18)}
5228
+ </div>
5229
+ <div style="display: flex; flex-direction: column; gap: 4px; margin-top: 4px;">
5230
+ <div style="font-size: 13px;">
5231
+ <span style="color: #9ca3af;">Infracción:</span>
5232
+ <span style="font-weight: 500; color: #374151;">${point.infractionCode}</span>
5233
+ </div>
5234
+ <div style="font-size: 13px;">
5235
+ <span style="color: #9ca3af;">Placa:</span>
5236
+ <span style="font-weight: 500; color: #374151;">${point.plate}</span>
5237
+ </div>
5238
+ <div style="display: flex; align-items: center; gap: 6px; font-size: 13px; font-weight: 600; margin-top: 4px; color: ${point.immobilized ? '#ef4444' : '#3b82f6'};">
5239
+ <span style="width: 8px; height: 8px; border-radius: 50%; background-color: ${point.immobilized ? '#ef4444' : '#3b82f6'};"></span>
5240
+ ${point.immobilized ? 'Inmovilizado' : 'Normal'}
5241
+ </div>
5242
+ </div>
5243
+ </div>
5244
+ `;
5245
+ marker.addListener('mouseover', () => {
5246
+ if (!lockedMarker) {
5247
+ infoWindow.setContent(content);
5248
+ infoWindow.open(this.map, marker);
5249
+ }
5250
+ });
5251
+ marker.addListener('mouseout', () => {
5252
+ if (!lockedMarker) {
5253
+ infoWindow.close();
5254
+ }
5255
+ });
5256
+ marker.addListener('click', () => {
5257
+ lockedMarker = marker;
5258
+ infoWindow.setContent(content);
5259
+ infoWindow.open(this.map, marker);
5260
+ });
5261
+ infoWindow.addListener('closeclick', () => {
5262
+ lockedMarker = null;
5263
+ });
5264
+ this.markers.push(marker);
5265
+ });
5266
+ // Auto-center and zoom to show all points
5267
+ if (points.length > 0) {
5268
+ const bounds = new google.maps.LatLngBounds();
5269
+ points.forEach(p => bounds.extend({ lat: p.latitude, lng: p.longitude }));
5270
+ this.map.fitBounds(bounds);
5271
+ }
5272
+ }
5206
5273
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: GeoAPIMaps, deps: [], target: i0.ɵɵFactoryTarget.Component });
5207
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "20.3.16", type: GeoAPIMaps, isStandalone: true, selector: "lib-geo-api-maps", ngImport: i0, template: "<div id=\"map\"></div>\r\n", styles: ["#map{position:absolute;inset:0;z-index:1}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }] });
5274
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "20.3.16", type: GeoAPIMaps, isStandalone: true, selector: "lib-geo-api-maps", inputs: { points: { classPropertyName: "points", publicName: "points", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div id=\"map\"></div>\r\n", styles: [":host{display:block;width:100%;height:100%;position:relative}#map{position:absolute;inset:0;z-index:1;border-radius:12px}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }] });
5208
5275
  }
5209
5276
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: GeoAPIMaps, decorators: [{
5210
5277
  type: Component,
5211
- args: [{ selector: 'lib-geo-api-maps', imports: [CommonModule], template: "<div id=\"map\"></div>\r\n", styles: ["#map{position:absolute;inset:0;z-index:1}\n"] }]
5212
- }] });
5278
+ args: [{ selector: 'lib-geo-api-maps', standalone: true, imports: [CommonModule], template: "<div id=\"map\"></div>\r\n", styles: [":host{display:block;width:100%;height:100%;position:relative}#map{position:absolute;inset:0;z-index:1;border-radius:12px}\n"] }]
5279
+ }], ctorParameters: () => [], propDecorators: { points: [{ type: i0.Input, args: [{ isSignal: true, alias: "points", required: false }] }] } });
5280
+
5281
+ class MapGeo {
5282
+ title = input('Mapa Geográfico', ...(ngDevMode ? [{ debugName: "title" }] : []));
5283
+ isExpanded = signal(false, ...(ngDevMode ? [{ debugName: "isExpanded" }] : []));
5284
+ points = input([], ...(ngDevMode ? [{ debugName: "points" }] : []));
5285
+ toggleExpand() {
5286
+ this.isExpanded.update((value) => !value);
5287
+ }
5288
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: MapGeo, deps: [], target: i0.ɵɵFactoryTarget.Component });
5289
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: MapGeo, isStandalone: true, selector: "lib-map-geo", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, points: { classPropertyName: "points", publicName: "points", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"map-geo-container\" [class.expanded]=\"isExpanded()\">\r\n <div class=\"map-geo-header\">\r\n <h3 class=\"map-geo-title\">{{ title() }}</h3>\r\n <button class=\"expand-btn\" (click)=\"toggleExpand()\" type=\"button\" [attr.aria-label]=\"isExpanded() ? 'Minimize chart' : 'Maximize chart'\">\r\n @if (isExpanded()) {\r\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"lucide lucide-minimize-2\"><polyline points=\"4 14 10 14 10 20\"/><polyline points=\"20 10 14 10 14 4\"/><line x1=\"14\" x2=\"21\" y1=\"10\" y2=\"3\"/><line x1=\"3\" x2=\"10\" y1=\"21\" y2=\"14\"/></svg>\r\n } @else {\r\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"lucide lucide-maximize-2\"><polyline points=\"15 3 21 3 21 9\"/><polyline points=\"9 21 3 21 3 15\"/><line x1=\"21\" x2=\"14\" y1=\"3\" y2=\"10\"/><line x1=\"3\" x2=\"10\" y1=\"21\" y2=\"14\"/></svg>\r\n }\r\n </button>\r\n </div>\r\n <div class=\"chart-wrapper\">\r\n <lib-geo-api-maps [points]=\"points()\" />\r\n </div>\r\n</div>\r\n@if (isExpanded()) {\r\n <div class=\"overlay\" (click)=\"toggleExpand()\"></div>\r\n}", styles: [":host{display:block;width:100%;min-width:0}.map-geo-container{width:100%;min-width:0;display:flex;flex-direction:column;gap:16px;background-color:#f0f0db;padding:24px 16px 16px;border-radius:20px;position:relative;transition:all .3s ease}.map-geo-container.expanded{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);width:90vw;height:90vh;z-index:9999;box-shadow:0 25px 50px -12px #00000040;margin:0}.chart-wrapper{position:relative;width:100%;height:450px;min-height:450px;display:block;min-width:0}.map-geo-container.expanded .chart-wrapper{flex:1;height:auto;min-height:0}.map-geo-header{display:flex;justify-content:space-between;align-items:center;gap:16px}.map-geo-title{font-size:20px;font-weight:600;color:#333;font-family:Inter,sans-serif}.expand-btn{background:transparent;border:none;cursor:pointer;color:#61661f;padding:6px;border-radius:8px;display:flex;align-items:center;justify-content:center;transition:background-color .2s}.expand-btn:hover{background-color:#61661f1a}.overlay{position:fixed;top:0;left:0;width:100vw;height:100vh;background-color:#0006;-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);z-index:9998}\n"], dependencies: [{ kind: "component", type: GeoAPIMaps, selector: "lib-geo-api-maps", inputs: ["points"] }] });
5290
+ }
5291
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: MapGeo, decorators: [{
5292
+ type: Component,
5293
+ args: [{ selector: 'lib-map-geo', imports: [GeoAPIMaps], template: "<div class=\"map-geo-container\" [class.expanded]=\"isExpanded()\">\r\n <div class=\"map-geo-header\">\r\n <h3 class=\"map-geo-title\">{{ title() }}</h3>\r\n <button class=\"expand-btn\" (click)=\"toggleExpand()\" type=\"button\" [attr.aria-label]=\"isExpanded() ? 'Minimize chart' : 'Maximize chart'\">\r\n @if (isExpanded()) {\r\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"lucide lucide-minimize-2\"><polyline points=\"4 14 10 14 10 20\"/><polyline points=\"20 10 14 10 14 4\"/><line x1=\"14\" x2=\"21\" y1=\"10\" y2=\"3\"/><line x1=\"3\" x2=\"10\" y1=\"21\" y2=\"14\"/></svg>\r\n } @else {\r\n <svg xmlns=\"http://www.w3.org/2000/svg\" width=\"20\" height=\"20\" viewBox=\"0 0 24 24\" fill=\"none\" stroke=\"currentColor\" stroke-width=\"2\" stroke-linecap=\"round\" stroke-linejoin=\"round\" class=\"lucide lucide-maximize-2\"><polyline points=\"15 3 21 3 21 9\"/><polyline points=\"9 21 3 21 3 15\"/><line x1=\"21\" x2=\"14\" y1=\"3\" y2=\"10\"/><line x1=\"3\" x2=\"10\" y1=\"21\" y2=\"14\"/></svg>\r\n }\r\n </button>\r\n </div>\r\n <div class=\"chart-wrapper\">\r\n <lib-geo-api-maps [points]=\"points()\" />\r\n </div>\r\n</div>\r\n@if (isExpanded()) {\r\n <div class=\"overlay\" (click)=\"toggleExpand()\"></div>\r\n}", styles: [":host{display:block;width:100%;min-width:0}.map-geo-container{width:100%;min-width:0;display:flex;flex-direction:column;gap:16px;background-color:#f0f0db;padding:24px 16px 16px;border-radius:20px;position:relative;transition:all .3s ease}.map-geo-container.expanded{position:fixed;top:50%;left:50%;transform:translate(-50%,-50%);width:90vw;height:90vh;z-index:9999;box-shadow:0 25px 50px -12px #00000040;margin:0}.chart-wrapper{position:relative;width:100%;height:450px;min-height:450px;display:block;min-width:0}.map-geo-container.expanded .chart-wrapper{flex:1;height:auto;min-height:0}.map-geo-header{display:flex;justify-content:space-between;align-items:center;gap:16px}.map-geo-title{font-size:20px;font-weight:600;color:#333;font-family:Inter,sans-serif}.expand-btn{background:transparent;border:none;cursor:pointer;color:#61661f;padding:6px;border-radius:8px;display:flex;align-items:center;justify-content:center;transition:background-color .2s}.expand-btn:hover{background-color:#61661f1a}.overlay{position:fixed;top:0;left:0;width:100vw;height:100vh;background-color:#0006;-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px);z-index:9998}\n"] }]
5294
+ }], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], points: [{ type: i0.Input, args: [{ isSignal: true, alias: "points", required: false }] }] } });
5295
+
5296
+ const Colors = {
5297
+ primary: '#4B5E05',
5298
+ secondary: '#063546',
5299
+ tertiary: '#6B0518',
5300
+ quaternary: '#F57C00',
5301
+ };
5302
+ class KpiCard {
5303
+ title = input('Titulo', ...(ngDevMode ? [{ debugName: "title" }] : []));
5304
+ description = input(...(ngDevMode ? [undefined, { debugName: "description" }] : []));
5305
+ value = input('0', ...(ngDevMode ? [{ debugName: "value" }] : []));
5306
+ iconColor = input('primary', ...(ngDevMode ? [{ debugName: "iconColor" }] : []));
5307
+ resolvedIconColor = computed(() => {
5308
+ const color = this.iconColor();
5309
+ // Revisa si es un predeterminado, si no, lo asume como hex code.
5310
+ return Colors[color] || color;
5311
+ }, ...(ngDevMode ? [{ debugName: "resolvedIconColor" }] : []));
5312
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: KpiCard, deps: [], target: i0.ɵɵFactoryTarget.Component });
5313
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.3.16", type: KpiCard, isStandalone: true, selector: "lib-kpi-card", inputs: { title: { classPropertyName: "title", publicName: "title", isSignal: true, isRequired: false, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null }, value: { classPropertyName: "value", publicName: "value", isSignal: true, isRequired: false, transformFunction: null }, iconColor: { classPropertyName: "iconColor", publicName: "iconColor", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"kpi-card\">\n <div class=\"kpi-card-text\">\n <h3 class=\"kpi-title\">{{ title() }}</h3>\n @if (description()) {\n <p class=\"kpi-description\">{{ description() }}</p>\n } @else {\n <div class=\"kpi-description\">\n <ng-content select=\"[description]\"></ng-content>\n </div>\n }\n <h2 class=\"kpi-value\">{{ value() }}</h2>\n </div>\n <div class=\"kpi-icon-container\" [style.--kpi-base-color]=\"resolvedIconColor()\">\n <ng-content select=\"[icon]\"></ng-content>\n </div>\n</div>\n", styles: [".kpi-card{background-color:#f0f0db;border-radius:20px;padding:24px;display:flex;justify-content:space-between;font-family:Roboto,sans-serif;min-width:260px}.kpi-card-text{display:flex;flex-direction:column}.kpi-title{font-size:20px;font-weight:700;color:#37474f;margin:0 0 4px}.kpi-description{font-size:15px;font-weight:500;color:#546e7a;margin:0 0 16px}.kpi-value{font-size:28px;font-weight:800;color:#10161a;margin:0;line-height:1}.kpi-icon-container{width:72px;height:72px;background-color:var(--kpi-base-color, #4B5E05);color:color-mix(in srgb,var(--kpi-base-color, #4B5E05) 35%,white);border-radius:50%;display:flex;justify-content:center;align-items:center;flex-shrink:0;box-shadow:0 4px 6px #0000000d}::ng-deep .kpi-icon-container svg{width:32px;height:32px;stroke:currentColor;stroke-width:2}\n"], dependencies: [{ kind: "ngmodule", type: CommonModule }] });
5314
+ }
5315
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImport: i0, type: KpiCard, decorators: [{
5316
+ type: Component,
5317
+ args: [{ selector: 'lib-kpi-card', imports: [CommonModule], template: "<div class=\"kpi-card\">\n <div class=\"kpi-card-text\">\n <h3 class=\"kpi-title\">{{ title() }}</h3>\n @if (description()) {\n <p class=\"kpi-description\">{{ description() }}</p>\n } @else {\n <div class=\"kpi-description\">\n <ng-content select=\"[description]\"></ng-content>\n </div>\n }\n <h2 class=\"kpi-value\">{{ value() }}</h2>\n </div>\n <div class=\"kpi-icon-container\" [style.--kpi-base-color]=\"resolvedIconColor()\">\n <ng-content select=\"[icon]\"></ng-content>\n </div>\n</div>\n", styles: [".kpi-card{background-color:#f0f0db;border-radius:20px;padding:24px;display:flex;justify-content:space-between;font-family:Roboto,sans-serif;min-width:260px}.kpi-card-text{display:flex;flex-direction:column}.kpi-title{font-size:20px;font-weight:700;color:#37474f;margin:0 0 4px}.kpi-description{font-size:15px;font-weight:500;color:#546e7a;margin:0 0 16px}.kpi-value{font-size:28px;font-weight:800;color:#10161a;margin:0;line-height:1}.kpi-icon-container{width:72px;height:72px;background-color:var(--kpi-base-color, #4B5E05);color:color-mix(in srgb,var(--kpi-base-color, #4B5E05) 35%,white);border-radius:50%;display:flex;justify-content:center;align-items:center;flex-shrink:0;box-shadow:0 4px 6px #0000000d}::ng-deep .kpi-icon-container svg{width:32px;height:32px;stroke:currentColor;stroke-width:2}\n"] }]
5318
+ }], propDecorators: { title: [{ type: i0.Input, args: [{ isSignal: true, alias: "title", required: false }] }], description: [{ type: i0.Input, args: [{ isSignal: true, alias: "description", required: false }] }], value: [{ type: i0.Input, args: [{ isSignal: true, alias: "value", required: false }] }], iconColor: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconColor", required: false }] }] } });
5213
5319
 
5214
5320
  // src/app/components/public-api.ts
5215
5321
  // Exportar los componentes
@@ -5218,5 +5324,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.3.16", ngImpo
5218
5324
  * Generated bundle index. Do not edit.
5219
5325
  */
5220
5326
 
5221
- export { BarChart, BaseChart, Button, ButtonCards, CARD_BG, CardContent, Colors, DateTimeFilter, DateTimePicker, DevicesCarousel, DialogAlertComponent, DialogConfirmation, DonutChart, DynamicFormFields, FeatureCard, Footer, GeoAPIMaps, Heatmap, InfoGroup, Input, InputNumberFilter, InputSelectFilter, InputTextFilter, InputTimeFilter, KpiCard, LineChart, Loader, ModalForm, NotFoundModal, NotFoundSection, NotificationModal, OptionCard, PaginationComponent, ProcessingOverlay, ProgressBar, ProgressFormService, SelectCustomSearch, SideCard, SideCardDetail, TOAST_EVENTS, Table, Tabs, TitleFilters, Toast, ToastHelper, ToastService, ToggleCustom, UI_CHART_TOKENS, WizardForm };
5327
+ export { BarChart, BaseChart, Button, ButtonCards, CARD_BG, CardContent, Colors, DateTimeFilter, DateTimePicker, DevicesCarousel, DialogAlertComponent, DialogConfirmation, DonutChart, DynamicFormFields, FeatureCard, Footer, GeoAPIMaps, Heatmap, InfoGroup, Input, InputNumberFilter, InputSelectFilter, InputTextFilter, InputTimeFilter, KpiCard, LineChart, Loader, MapGeo, ModalForm, NotFoundModal, NotFoundSection, NotificationModal, OptionCard, PaginationComponent, ProcessingOverlay, ProgressBar, ProgressFormService, SelectCustomSearch, SideCard, SideCardDetail, TOAST_EVENTS, Table, Tabs, TitleFilters, Toast, ToastHelper, ToastService, ToggleCustom, UI_CHART_TOKENS, WizardForm };
5222
5328
  //# sourceMappingURL=sapenlinea-components.mjs.map