@rsltda/components 1.0.15 → 1.0.16
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.
- package/README.md +4 -3
- package/custom-elements.json +1 -1
- package/dist/components/rs-map.d.ts +24 -0
- package/dist/components/rs-quote-form.d.ts +24 -0
- package/dist/rs-components.es.js +820 -443
- package/dist/rs-components.es.js.map +1 -1
- package/dist/rs-components.iife.js +203 -6
- package/dist/rs-components.iife.js.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# @rsltda/components
|
|
2
2
|
|
|
3
|
-
Web Components construidos con Vite + TypeScript. El paquete expone principalmente `<rs-map>`,
|
|
3
|
+
Web Components construidos con Vite + TypeScript. El paquete expone principalmente `<rs-map>`, listo para integrarse en cualquier sitio mediante Web Components.
|
|
4
4
|
|
|
5
5
|
## Alcance de uso
|
|
6
6
|
|
|
@@ -50,15 +50,16 @@ import "@rsltda/components/rs-components.es.js";
|
|
|
50
50
|
| `google-maps-key` | API key de Google Maps. |
|
|
51
51
|
| `points-api-url` | Endpoint base de puntos. El componente usa un valor por defecto interno cuando no se especifica uno. |
|
|
52
52
|
| `cache-days` | Dias de vigencia del cache local. Por defecto `30`. |
|
|
53
|
-
| `marker-icon-base` | URL base para iconos por marca.
|
|
53
|
+
| `marker-icon-base` | URL base opcional para iconos por marca. |
|
|
54
54
|
| `marker-icon-default` | Icono de respaldo si no se quiere usar icono por marca. |
|
|
55
55
|
|
|
56
56
|
## Defaults importantes
|
|
57
57
|
|
|
58
58
|
- `points-api-url`: valor interno por defecto
|
|
59
|
-
- `marker-icon-base`: valor interno por defecto
|
|
60
59
|
- `cache-days`: `30`
|
|
61
60
|
|
|
61
|
+
Si no existe un pin local para la marca/tipo ni se define `marker-icon-default`, Google Maps usa su marcador por defecto.
|
|
62
|
+
|
|
62
63
|
## Cache y primera carga
|
|
63
64
|
|
|
64
65
|
`rs-map` primero intenta leer puntos desde `IndexedDB` y usa `localStorage` como respaldo.
|
package/custom-elements.json
CHANGED
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
},
|
|
41
41
|
{
|
|
42
42
|
"name": "marker-icon-base",
|
|
43
|
-
"description": "URL base para iconos por marca.
|
|
43
|
+
"description": "URL base opcional para iconos por marca. Si no hay pin local ni respaldo explicito, Google Maps usa su marcador por defecto."
|
|
44
44
|
},
|
|
45
45
|
{
|
|
46
46
|
"name": "marker-icon-default",
|
|
@@ -5,6 +5,10 @@ export declare class RsMap extends HTMLElement {
|
|
|
5
5
|
private root;
|
|
6
6
|
private mapEl;
|
|
7
7
|
private map;
|
|
8
|
+
private pointModalOverlayEl;
|
|
9
|
+
private pointModalTitleEl;
|
|
10
|
+
private pointModalBodyEl;
|
|
11
|
+
private pointModalCloseButton;
|
|
8
12
|
private markers;
|
|
9
13
|
private marca;
|
|
10
14
|
private marcaKey;
|
|
@@ -60,6 +64,7 @@ export declare class RsMap extends HTMLElement {
|
|
|
60
64
|
private normalizeTipo;
|
|
61
65
|
private refreshPoints;
|
|
62
66
|
private applyPointsPayload;
|
|
67
|
+
private reportUnmappablePoints;
|
|
63
68
|
private getPointsCacheKey;
|
|
64
69
|
private getLocalPointsFallback;
|
|
65
70
|
private parseLocalPointsPayload;
|
|
@@ -72,11 +77,29 @@ export declare class RsMap extends HTMLElement {
|
|
|
72
77
|
private renderPoints;
|
|
73
78
|
private groupPoints;
|
|
74
79
|
private createPointCard;
|
|
80
|
+
private createMobileNavigationActions;
|
|
81
|
+
private createMobileNavigationLink;
|
|
75
82
|
private getZoneForPoint;
|
|
76
83
|
private normalizeRegionName;
|
|
84
|
+
private getMarcaRequestValue;
|
|
77
85
|
private normalizeBrandKey;
|
|
86
|
+
private normalizeBrandToken;
|
|
78
87
|
private getMarkerIcon;
|
|
88
|
+
private getLocalMarkerIconUrl;
|
|
89
|
+
private getPointCoordinateWarning;
|
|
90
|
+
private getPointPosition;
|
|
91
|
+
private isMappableCoordinate;
|
|
79
92
|
private updateMarkers;
|
|
93
|
+
private openPointModal;
|
|
94
|
+
private closePointModal;
|
|
95
|
+
private handlePointModalOverlayClick;
|
|
96
|
+
private handlePointModalKeydown;
|
|
97
|
+
private createPointModalContent;
|
|
98
|
+
private createPointModalSection;
|
|
99
|
+
private appendPointModalLine;
|
|
100
|
+
private createPointModalPhoneItem;
|
|
101
|
+
private createPointModalActions;
|
|
102
|
+
private createPointModalLink;
|
|
80
103
|
private handleZoneButtonClick;
|
|
81
104
|
private setActiveZone;
|
|
82
105
|
private scrollToZoneSection;
|
|
@@ -96,5 +119,6 @@ export declare class RsMap extends HTMLElement {
|
|
|
96
119
|
private animateMapPan;
|
|
97
120
|
private static ensureFontAwesome;
|
|
98
121
|
private createIconElement;
|
|
122
|
+
private isWhatsappPhone;
|
|
99
123
|
private getWhatsappLink;
|
|
100
124
|
}
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
export declare class RsQuoteForm extends HTMLElement {
|
|
2
|
+
static tag: string;
|
|
3
|
+
private root;
|
|
4
|
+
private formEl;
|
|
5
|
+
private submitButtonEl;
|
|
6
|
+
private statusEl;
|
|
7
|
+
private endpoint;
|
|
8
|
+
private method;
|
|
9
|
+
private submitLabel;
|
|
10
|
+
private successMessage;
|
|
11
|
+
private errorMessage;
|
|
12
|
+
static get observedAttributes(): string[];
|
|
13
|
+
constructor();
|
|
14
|
+
connectedCallback(): void;
|
|
15
|
+
disconnectedCallback(): void;
|
|
16
|
+
attributeChangedCallback(name: string, _oldValue: string | null, newValue: string | null): void;
|
|
17
|
+
private syncAttributesToState;
|
|
18
|
+
private updateVehicleSummary;
|
|
19
|
+
private buildPayload;
|
|
20
|
+
private handleSubmit;
|
|
21
|
+
private setLoading;
|
|
22
|
+
private clearStatus;
|
|
23
|
+
private showStatus;
|
|
24
|
+
}
|