@jaak.ai/stamps 2.1.0 → 2.2.0-dev.2
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 +42 -9
- package/dist/cjs/{index-Ga0t6BMe.js → index-D6NBn_qu.js} +30 -5
- package/dist/cjs/index-D6NBn_qu.js.map +1 -0
- package/dist/cjs/jaak-stamps-webcomponent.cjs.js +2 -2
- package/dist/cjs/jaak-stamps.cjs.entry.js +20082 -11
- package/dist/cjs/jaak-stamps.cjs.entry.js.map +1 -1
- package/dist/cjs/jaak-stamps.entry.cjs.js.map +1 -1
- package/dist/cjs/loader.cjs.js +2 -2
- package/dist/collection/components/my-component/my-component.css +82 -2
- package/dist/collection/components/my-component/my-component.js +475 -9
- package/dist/collection/components/my-component/my-component.js.map +1 -1
- package/dist/collection/services/LicenseValidationService.js +111 -0
- package/dist/collection/services/LicenseValidationService.js.map +1 -0
- package/dist/collection/services/MetricsService.js +350 -0
- package/dist/collection/services/MetricsService.js.map +1 -0
- package/dist/collection/services/ServiceContainer.js +66 -1
- package/dist/collection/services/ServiceContainer.js.map +1 -1
- package/dist/collection/services/TracingService.js +442 -0
- package/dist/collection/services/TracingService.js.map +1 -0
- package/dist/collection/services/interfaces/ILicenseValidationService.js +2 -0
- package/dist/collection/services/interfaces/ILicenseValidationService.js.map +1 -0
- package/dist/collection/services/interfaces/IMetricsService.js +2 -0
- package/dist/collection/services/interfaces/IMetricsService.js.map +1 -0
- package/dist/collection/services/interfaces/ITracingService.js +2 -0
- package/dist/collection/services/interfaces/ITracingService.js.map +1 -0
- package/dist/components/index.js +28 -3
- package/dist/components/index.js.map +1 -1
- package/dist/components/jaak-stamps.js +20096 -10
- package/dist/components/jaak-stamps.js.map +1 -1
- package/dist/esm/{index-Drbzcuq-.js → index-BCfAsrzL.js} +30 -5
- package/dist/esm/index-BCfAsrzL.js.map +1 -0
- package/dist/esm/jaak-stamps-webcomponent.js +3 -3
- package/dist/esm/jaak-stamps.entry.js +20082 -11
- package/dist/esm/jaak-stamps.entry.js.map +1 -1
- package/dist/esm/loader.js +3 -3
- package/dist/jaak-stamps-webcomponent/jaak-stamps-webcomponent.esm.js +1 -1
- package/dist/jaak-stamps-webcomponent/jaak-stamps.entry.esm.js.map +1 -1
- package/dist/jaak-stamps-webcomponent/p-8c49893d.entry.js +7 -0
- package/dist/jaak-stamps-webcomponent/p-8c49893d.entry.js.map +1 -0
- package/dist/jaak-stamps-webcomponent/p-BCfAsrzL.js +3 -0
- package/dist/jaak-stamps-webcomponent/p-BCfAsrzL.js.map +1 -0
- package/dist/types/components/my-component/my-component.d.ts +23 -0
- package/dist/types/components.d.ts +76 -0
- package/dist/types/services/LicenseValidationService.d.ts +59 -0
- package/dist/types/services/MetricsService.d.ts +74 -0
- package/dist/types/services/ServiceContainer.d.ts +14 -1
- package/dist/types/services/TracingService.d.ts +67 -0
- package/dist/types/services/interfaces/ILicenseValidationService.d.ts +4 -0
- package/dist/types/services/interfaces/IMetricsService.d.ts +70 -0
- package/dist/types/services/interfaces/ITracingService.d.ts +59 -0
- package/package.json +18 -2
- package/dist/cjs/index-Ga0t6BMe.js.map +0 -1
- package/dist/esm/index-Drbzcuq-.js.map +0 -1
- package/dist/jaak-stamps-webcomponent/p-Drbzcuq-.js +0 -3
- package/dist/jaak-stamps-webcomponent/p-Drbzcuq-.js.map +0 -1
- package/dist/jaak-stamps-webcomponent/p-c06e5d7b.entry.js +0 -2
- package/dist/jaak-stamps-webcomponent/p-c06e5d7b.entry.js.map +0 -1
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { h } from "@stencil/core";
|
|
2
2
|
import { ServiceContainer } from "../../services/ServiceContainer";
|
|
3
|
+
import { LicenseValidationService } from "../../services/LicenseValidationService";
|
|
3
4
|
export class JaakStamps {
|
|
4
5
|
el;
|
|
5
6
|
debug = false;
|
|
@@ -12,8 +13,22 @@ export class JaakStamps {
|
|
|
12
13
|
captureDelay = 1500;
|
|
13
14
|
enableBackDocumentTimer = false;
|
|
14
15
|
backDocumentTimerDuration = 20;
|
|
16
|
+
telemetryCollectorUrl = 'https://collector.jaak.ai/v1/traces';
|
|
17
|
+
metricsCollectorUrl = 'https://collector.jaak.ai/v1/metrics';
|
|
18
|
+
enableTelemetry = true;
|
|
19
|
+
enableMetrics = true;
|
|
20
|
+
customerId;
|
|
21
|
+
tenantId;
|
|
22
|
+
environment = 'production';
|
|
23
|
+
propagateTraceHeaderCorsUrls; // Comma-separated URLs or regex patterns
|
|
24
|
+
metricsExportIntervalMillis = 60000; // Export metrics every 60 seconds
|
|
25
|
+
license; // License key for validation
|
|
26
|
+
licenseEnvironment = 'prod'; // Environment for license validation
|
|
27
|
+
traceId; // Optional trace ID for tracking
|
|
28
|
+
appId = 'jaak-stamps-web'; // Application ID for license validation
|
|
15
29
|
captureCompleted;
|
|
16
30
|
isReady;
|
|
31
|
+
traceIdGenerated;
|
|
17
32
|
// State derived from services
|
|
18
33
|
detectionBoxes = [];
|
|
19
34
|
sideAlignment = {
|
|
@@ -53,12 +68,17 @@ export class JaakStamps {
|
|
|
53
68
|
showPerformanceMessage = false; // Show performance message temporarily
|
|
54
69
|
captureStateVersion = 0; // Triggers re-render when StateManager changes
|
|
55
70
|
processingButton = null; // Track which button is processing
|
|
71
|
+
licenseValid = true; // License validation status
|
|
72
|
+
licenseError = null; // License validation error message
|
|
56
73
|
// Services
|
|
74
|
+
licenseValidationService = null;
|
|
57
75
|
serviceContainer;
|
|
58
76
|
eventBus;
|
|
59
77
|
stateManager;
|
|
60
78
|
cameraService;
|
|
61
79
|
detectionService;
|
|
80
|
+
tracingService;
|
|
81
|
+
metricsService;
|
|
62
82
|
// UI References
|
|
63
83
|
videoRef;
|
|
64
84
|
detectionContainer;
|
|
@@ -104,8 +124,23 @@ export class JaakStamps {
|
|
|
104
124
|
// Canvas pool for optimized screenshot capture
|
|
105
125
|
canvasPool = [];
|
|
106
126
|
MAX_CANVAS_POOL_SIZE = 3;
|
|
127
|
+
async componentWillLoad() {
|
|
128
|
+
// License is required - always validate
|
|
129
|
+
// Wait a bit to ensure props are set from attributes
|
|
130
|
+
await new Promise(resolve => setTimeout(resolve, 50));
|
|
131
|
+
this.updateStatus('Validando licencia...', 'Verificando autorización de uso', 'initializing');
|
|
132
|
+
await this.validateLicense();
|
|
133
|
+
// If license validation failed, stop initialization
|
|
134
|
+
if (!this.licenseValid) {
|
|
135
|
+
return;
|
|
136
|
+
}
|
|
137
|
+
}
|
|
107
138
|
async componentDidLoad() {
|
|
108
139
|
try {
|
|
140
|
+
// If license validation failed, stop initialization
|
|
141
|
+
if (!this.licenseValid) {
|
|
142
|
+
return;
|
|
143
|
+
}
|
|
109
144
|
this.updateStatus('Preparando capturador...', 'Configurando herramientas de captura', 'initializing');
|
|
110
145
|
await this.initializeServices();
|
|
111
146
|
this.updateStatus('Preparando funciones...', 'Configurando herramientas de trabajo', 'initializing');
|
|
@@ -121,6 +156,10 @@ export class JaakStamps {
|
|
|
121
156
|
}
|
|
122
157
|
}
|
|
123
158
|
async initializeServices() {
|
|
159
|
+
// Parse propagateTraceHeaderCorsUrls from comma-separated string
|
|
160
|
+
const propagateUrls = this.propagateTraceHeaderCorsUrls
|
|
161
|
+
? this.propagateTraceHeaderCorsUrls.split(',').map(url => url.trim())
|
|
162
|
+
: [];
|
|
124
163
|
const config = {
|
|
125
164
|
debug: this.debug,
|
|
126
165
|
alignmentTolerance: this.alignmentTolerance,
|
|
@@ -129,13 +168,72 @@ export class JaakStamps {
|
|
|
129
168
|
useDocumentClassification: this.useDocumentClassification,
|
|
130
169
|
useDocumentDetector: this.useDocumentDetector,
|
|
131
170
|
preferredCamera: this.preferredCamera,
|
|
132
|
-
captureDelay: this.captureDelay
|
|
171
|
+
captureDelay: this.captureDelay,
|
|
172
|
+
telemetryCollectorUrl: this.telemetryCollectorUrl,
|
|
173
|
+
metricsCollectorUrl: this.metricsCollectorUrl,
|
|
174
|
+
enableTelemetry: this.enableTelemetry,
|
|
175
|
+
enableMetrics: this.enableMetrics,
|
|
176
|
+
customerId: this.customerId,
|
|
177
|
+
tenantId: this.tenantId,
|
|
178
|
+
environment: this.environment,
|
|
179
|
+
propagateTraceHeaderCorsUrls: propagateUrls,
|
|
180
|
+
metricsExportIntervalMillis: this.metricsExportIntervalMillis
|
|
133
181
|
};
|
|
134
182
|
this.serviceContainer = new ServiceContainer(config);
|
|
135
183
|
this.eventBus = this.serviceContainer.getEventBus();
|
|
136
184
|
this.stateManager = this.serviceContainer.getStateManager();
|
|
137
185
|
this.cameraService = this.serviceContainer.getCameraService();
|
|
138
186
|
this.detectionService = this.serviceContainer.getDetectionService();
|
|
187
|
+
this.tracingService = this.serviceContainer.getTracingService();
|
|
188
|
+
this.metricsService = this.serviceContainer.getMetricsService();
|
|
189
|
+
// Record component initialization
|
|
190
|
+
if (this.tracingService) {
|
|
191
|
+
const span = this.tracingService.startSpan('component.initialize', {
|
|
192
|
+
'component.debug': this.debug,
|
|
193
|
+
'component.useDocumentDetector': this.useDocumentDetector,
|
|
194
|
+
'component.useDocumentClassification': this.useDocumentClassification,
|
|
195
|
+
});
|
|
196
|
+
this.tracingService.endSpan(span);
|
|
197
|
+
}
|
|
198
|
+
}
|
|
199
|
+
async validateLicense() {
|
|
200
|
+
if (!this.license) {
|
|
201
|
+
console.error('❌ No license provided for JAAK Stamps component');
|
|
202
|
+
this.licenseError = 'Este componente requiere una licencia válida. Por favor, proporcione una licencia usando el atributo "license".';
|
|
203
|
+
this.licenseValid = false;
|
|
204
|
+
this.updateStatus('Error de licencia', 'Licencia no proporcionada', 'error');
|
|
205
|
+
return;
|
|
206
|
+
}
|
|
207
|
+
try {
|
|
208
|
+
console.log('🔑 Validating license for JAAK Stamps...');
|
|
209
|
+
// Initialize license validation service
|
|
210
|
+
this.licenseValidationService = new LicenseValidationService(this.licenseEnvironment);
|
|
211
|
+
// Validate the license, passing traceId and appId if provided
|
|
212
|
+
const response = await this.licenseValidationService.validateLicense(this.license, this.traceId, this.appId);
|
|
213
|
+
if (response && response.access_token) {
|
|
214
|
+
this.licenseValid = true;
|
|
215
|
+
this.licenseError = null;
|
|
216
|
+
console.log('✅ License validated successfully for JAAK Stamps');
|
|
217
|
+
// Emit the traceId (either provided or generated)
|
|
218
|
+
if (response.traceId) {
|
|
219
|
+
this.traceIdGenerated.emit({ traceId: response.traceId });
|
|
220
|
+
console.log('📋 TraceId:', response.traceId);
|
|
221
|
+
}
|
|
222
|
+
}
|
|
223
|
+
else {
|
|
224
|
+
this.licenseValid = false;
|
|
225
|
+
this.licenseError = 'La licencia proporcionada no es válida. Por favor, verifique su licencia e intente nuevamente.';
|
|
226
|
+
this.updateStatus('Error de licencia', 'Licencia inválida', 'error');
|
|
227
|
+
console.error('❌ Invalid license for JAAK Stamps');
|
|
228
|
+
}
|
|
229
|
+
}
|
|
230
|
+
catch (error) {
|
|
231
|
+
this.licenseValid = false;
|
|
232
|
+
const licenseError = error;
|
|
233
|
+
this.licenseError = licenseError.error_description || 'Error al validar la licencia. Por favor, verifique su conexión e intente nuevamente.';
|
|
234
|
+
this.updateStatus('Error de licencia', 'Fallo en la validación', 'error');
|
|
235
|
+
console.error('❌ License validation failed for JAAK Stamps:', error);
|
|
236
|
+
}
|
|
139
237
|
}
|
|
140
238
|
async setupEventListeners() {
|
|
141
239
|
this.eventBus.on('state-changed', () => {
|
|
@@ -403,17 +501,31 @@ export class JaakStamps {
|
|
|
403
501
|
return this.stateManager.isProcessCompleted();
|
|
404
502
|
}
|
|
405
503
|
async startCapture() {
|
|
504
|
+
const span = this.tracingService?.startSpan('capture.start');
|
|
406
505
|
const readyCheck = this.isComponentReady();
|
|
407
506
|
if (!readyCheck.ready) {
|
|
408
507
|
this.updateStatus(readyCheck.message, 'Espere a que termine la inicialización', readyCheck.status);
|
|
508
|
+
if (span) {
|
|
509
|
+
this.tracingService?.setSpanAttribute(span, 'error', true);
|
|
510
|
+
this.tracingService?.setSpanAttribute(span, 'error.message', readyCheck.message);
|
|
511
|
+
this.tracingService?.endSpan(span);
|
|
512
|
+
}
|
|
409
513
|
return { success: false, error: readyCheck.message };
|
|
410
514
|
}
|
|
411
515
|
try {
|
|
412
516
|
await this.startDetection();
|
|
517
|
+
if (span) {
|
|
518
|
+
this.tracingService?.setSpanAttribute(span, 'success', true);
|
|
519
|
+
this.tracingService?.endSpan(span);
|
|
520
|
+
}
|
|
413
521
|
return { success: true };
|
|
414
522
|
}
|
|
415
523
|
catch (error) {
|
|
416
524
|
this.updateStatus('Error al iniciar captura', error.message, 'error');
|
|
525
|
+
if (span) {
|
|
526
|
+
this.tracingService?.recordException(span, error);
|
|
527
|
+
this.tracingService?.endSpan(span);
|
|
528
|
+
}
|
|
417
529
|
return { success: false, error: error.message };
|
|
418
530
|
}
|
|
419
531
|
}
|
|
@@ -511,13 +623,22 @@ export class JaakStamps {
|
|
|
511
623
|
}
|
|
512
624
|
}
|
|
513
625
|
async preloadModel() {
|
|
626
|
+
const span = this.tracingService?.startSpan('model.preload');
|
|
514
627
|
const readyCheck = this.isComponentReady();
|
|
515
628
|
if (!readyCheck.ready) {
|
|
516
629
|
this.updateStatus(readyCheck.message, 'Espere a que termine la inicialización', readyCheck.status);
|
|
630
|
+
if (span) {
|
|
631
|
+
this.tracingService?.setSpanAttribute(span, 'error', true);
|
|
632
|
+
this.tracingService?.endSpan(span);
|
|
633
|
+
}
|
|
517
634
|
return { success: false, error: readyCheck.message };
|
|
518
635
|
}
|
|
519
636
|
if (this.detectionService.isModelLoaded()) {
|
|
520
637
|
this.updateStatus('Reconocimiento listo', '', 'ready');
|
|
638
|
+
if (span) {
|
|
639
|
+
this.tracingService?.setSpanAttribute(span, 'cached', true);
|
|
640
|
+
this.tracingService?.endSpan(span);
|
|
641
|
+
}
|
|
521
642
|
return { success: true, message: 'Model already loaded' };
|
|
522
643
|
}
|
|
523
644
|
try {
|
|
@@ -527,17 +648,31 @@ export class JaakStamps {
|
|
|
527
648
|
this.stateManager.updateCaptureState({ isLoading: true });
|
|
528
649
|
}
|
|
529
650
|
try {
|
|
651
|
+
const detectionStartTime = performance.now();
|
|
652
|
+
const modelSpan = this.tracingService?.startSpan('model.detection.load');
|
|
530
653
|
await this.detectionService.loadModel();
|
|
654
|
+
if (modelSpan)
|
|
655
|
+
this.tracingService?.endSpan(modelSpan);
|
|
656
|
+
const detectionLoadTime = performance.now() - detectionStartTime;
|
|
657
|
+
this.metricsService?.recordModelLoad('detection', detectionLoadTime, false);
|
|
531
658
|
}
|
|
532
659
|
catch (modelError) {
|
|
660
|
+
this.metricsService?.recordError('model_load_failed', 'detection');
|
|
533
661
|
this.switchToManualModeWithError('Error al cargar modelo de detección');
|
|
534
662
|
throw modelError;
|
|
535
663
|
}
|
|
536
664
|
this.updateStatus('Optimizando detección...', 'Configurando reconocimiento de documentos', 'loading');
|
|
537
665
|
try {
|
|
666
|
+
const classificationStartTime = performance.now();
|
|
667
|
+
const classSpan = this.tracingService?.startSpan('model.classification.load');
|
|
538
668
|
await this.detectionService.loadClassificationModel();
|
|
669
|
+
if (classSpan)
|
|
670
|
+
this.tracingService?.endSpan(classSpan);
|
|
671
|
+
const classificationLoadTime = performance.now() - classificationStartTime;
|
|
672
|
+
this.metricsService?.recordModelLoad('classification', classificationLoadTime, false);
|
|
539
673
|
}
|
|
540
674
|
catch (classificationError) {
|
|
675
|
+
this.metricsService?.recordError('model_load_failed', 'classification');
|
|
541
676
|
this.switchToManualModeWithError('Error al cargar modelo de clasificación');
|
|
542
677
|
throw classificationError;
|
|
543
678
|
}
|
|
@@ -547,6 +682,9 @@ export class JaakStamps {
|
|
|
547
682
|
if (this.debug) {
|
|
548
683
|
this.recordOnnxPerformance(loadTime, 0);
|
|
549
684
|
}
|
|
685
|
+
if (span) {
|
|
686
|
+
this.tracingService?.setSpanAttribute(span, 'loadTime', loadTime);
|
|
687
|
+
}
|
|
550
688
|
this.updateStatus('Finalizando configuración...', 'Preparando herramientas para captura', 'loading');
|
|
551
689
|
await new Promise(resolve => setTimeout(resolve, 300));
|
|
552
690
|
this.updateStatus('Reconocimiento preparado', '', 'ready');
|
|
@@ -554,6 +692,10 @@ export class JaakStamps {
|
|
|
554
692
|
this.stateManager.updateCaptureState({ isLoading: false });
|
|
555
693
|
}
|
|
556
694
|
this.emitReadyEvent();
|
|
695
|
+
if (span) {
|
|
696
|
+
this.tracingService?.setSpanAttribute(span, 'success', true);
|
|
697
|
+
this.tracingService?.endSpan(span);
|
|
698
|
+
}
|
|
557
699
|
return { success: true, message: 'Models preloaded successfully' };
|
|
558
700
|
}
|
|
559
701
|
catch (error) {
|
|
@@ -561,6 +703,10 @@ export class JaakStamps {
|
|
|
561
703
|
if (this.stateManager) {
|
|
562
704
|
this.stateManager.updateCaptureState({ isLoading: false });
|
|
563
705
|
}
|
|
706
|
+
if (span) {
|
|
707
|
+
this.tracingService?.recordException(span, error);
|
|
708
|
+
this.tracingService?.endSpan(span);
|
|
709
|
+
}
|
|
564
710
|
return { success: false, error: error.message };
|
|
565
711
|
}
|
|
566
712
|
}
|
|
@@ -983,7 +1129,7 @@ export class JaakStamps {
|
|
|
983
1129
|
isCapturing: false
|
|
984
1130
|
};
|
|
985
1131
|
const cameraInfo = this.cameraInfoWithAutofocus;
|
|
986
|
-
return (h("div", { key: '
|
|
1132
|
+
return (h("div", { key: '69b36b10f1a790caa352acd5e149fe012ddebd3d', class: "detector-container" }, !this.licenseValid && this.licenseError && (h("div", { key: 'b96d8b52f6bb366b1d6239922a95b100befa5735', class: "license-error-container" }, h("div", { key: '58fb20b1acae97631c35730ed395acf9fa583df2', class: "license-error-card" }, h("svg", { key: 'f2726621e000bad3c62b1106778bb50e32ece973', class: "license-error-icon", width: "64", height: "64", viewBox: "0 0 24 24", fill: "none", xmlns: "http://www.w3.org/2000/svg" }, h("path", { key: '18a51f219cdc93f717867f61502c55b35d250532', d: "M12 22C12 22 20 18 20 12V5L12 2L4 5V12C4 18 12 22 12 22Z", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round", "stroke-linejoin": "round" }), h("path", { key: '0f157178a69c10590dd55f55c2223fdef31c2569', d: "M12 8V12", stroke: "currentColor", "stroke-width": "2", "stroke-linecap": "round" }), h("circle", { key: '0352746bef8e2e5a6be0c3868406005aae574a71', cx: "12", cy: "16", r: "0.5", fill: "currentColor", stroke: "currentColor", "stroke-width": "1" })), h("h2", { key: 'c63de740aa94503f1cf5e1cd1b366b11bc3253b3', class: "license-error-title" }, "Licencia Requerida"), h("p", { key: 'e36cefd08b510fc38f326de557ffc16425a0b324', class: "license-error-message" }, this.licenseError), h("p", { key: 'c77c6545b5186f7fb77a414120d3f6f5ba4a45f0', class: "license-error-help" }, "Contacte a soporte: ", h("a", { key: 'bef70b41a7ec454bed38c4162ce3cafc02c81071', href: "mailto:support@jaak.ai" }, "support@jaak.ai")), h("div", { key: '7fd679252453474021494c8dac3ec44da60b40eb', class: "license-error-footer" }, "JAAK Stamps")))), this.licenseValid && (h("div", { key: '369edcb3d7fcaa18059ae89f340f5e65bd0f0785', class: "video-container" }, h("video", { key: '88a67cf2451ebd53cb4fa709d34d11c7fa98cfc9', ref: el => this.videoRef = el, autoplay: true, muted: true, playsinline: true, class: this.shouldMirrorVideo ? 'mirror' : '', style: { display: captureState.isVideoActive ? 'block' : 'none' } }), h("div", { key: 'd309664c7a9e64f33dd45e0925f27768483b6795', ref: el => this.detectionContainer = el, class: `detection-overlay ${this.shouldMirrorVideo ? 'mirror' : ''}` }, this.debug && this.detectionBoxes.map((box, index) => (h("div", { key: index, class: "detection-box", style: {
|
|
987
1133
|
position: 'absolute',
|
|
988
1134
|
left: `${box.x}px`,
|
|
989
1135
|
top: `${box.y}px`,
|
|
@@ -992,9 +1138,9 @@ export class JaakStamps {
|
|
|
992
1138
|
border: '2px solid #32406C',
|
|
993
1139
|
pointerEvents: 'none',
|
|
994
1140
|
boxSizing: 'border-box'
|
|
995
|
-
} })))), this.isMaskReady && (h("div", { key: '
|
|
1141
|
+
} })))), this.isMaskReady && (h("div", { key: 'fbfc808e22ec640ddd9e34d52fab476d7a9becc1', class: "overlay-mask" }, h("div", { key: '40846a04d852bbcc2ac6c4a0ca356adae1c67765', class: "card-outline" }, h("div", { key: '452fe1786b67d0f9194e5d03ad2aaee08868a5fd', class: "side side-top" }), h("div", { key: 'a462c388ea55cd022b9616571f0012bd5eb380d4', class: "side side-right" }), h("div", { key: 'bfa2232443e23f2e72f009c62f7a866b9ff1b084', class: "side side-bottom" }), h("div", { key: '581746eca6fde6340d78e8ab48d6e21d17e7dfd3', class: "side side-left" })), !captureState.showFlipAnimation && !captureState.showSuccessAnimation && (h("div", { key: '8e57ac550ea3718322ba954682f93239acbabc78', class: `guide-text ${this.showPerformanceMessage ? 'performance-warning-text' : ''}` }, this.getGuideText(captureState.step))), captureState.step === 'back' && !captureState.showFlipAnimation && !captureState.showSuccessAnimation && (h("div", { key: '81cfab68789796d901afadc895d28f398e8c15cf', class: "back-capture-section" }, h("div", { key: 'd80455bd916c2d7ac47eb0ce3c62b0e5efbe4dff', class: "back-capture-buttons" }, (!this.useDocumentDetector || this.performanceDegradedMode || this.showManualCaptureButton) && (h("button", { key: 'c6d427cb32ecfb1ff40150d39f1d8ad7565f7156', class: "capture-button primary-button", onClick: () => this.takeManualScreenshot(), type: "button", disabled: this.processingButton !== null }, this.processingButton === 'capture-back' && (h("span", { key: 'cb57aec75ff91f2887fa258bd79b8efb98614d13', class: "button-spinner" })), "Capturar Reverso")), h("button", { key: 'c76f356a34fcbc790ebe2d900ed61cc4a6a02e28', class: "skip-button", onClick: () => this.skipBackCapture(), type: "button", disabled: this.processingButton !== null }, this.processingButton === 'skip-back' && (h("span", { key: 'd8fe69623902a5f41587f630552ef28a352733c6', class: "button-spinner" })), this.enableBackDocumentTimer && this.backDocumentTimerRemaining > 0
|
|
996
1142
|
? `Saltar reverso (${this.backDocumentTimerRemaining}s)`
|
|
997
|
-
: 'Saltar reverso')))), captureState.isVideoActive && (h("div", { key: '
|
|
1143
|
+
: 'Saltar reverso')))), captureState.isVideoActive && (h("div", { key: '08f4037c20b4dfed59553a7f29474940f5f3eb49', class: "camera-controls" }, h("button", { key: 'e873835d5d6587b19eb5e61e0073e4992fe115b6', class: `camera-selector-button ${this.isSwitchingCamera ? 'loading' : ''}`, onClick: () => this.toggleCameraSelector(), type: "button", title: "Seleccionar c\u00E1mara", disabled: this.isSwitchingCamera }, this.isSwitchingCamera ? (h("div", { class: "button-spinner" })) : ('Cámaras')))), this.showCameraSelector && cameraInfo.availableCameras.length > 0 && (h("div", { key: '8fca7e29f868570bb99dd2d09ca7da807656dad0', class: "camera-selector-dropdown" }, h("div", { key: 'abfac31042d3b362c094a297429e0272dabb2511', class: "camera-selector-header" }, h("span", { key: 'ffcd0e3c262aa86c431617568c1070548d88f38a' }, "Seleccionar C\u00E1mara"), h("button", { key: '8351be02ccbfa818cab352a37a29d2cd5bfd53ef', class: "close-selector", onClick: () => this.toggleCameraSelector(), type: "button" }, "\u00D7")), h("div", { key: 'b42d7a5855ec2f76bc105f7b03369b3d4c950762', class: "camera-list" }, cameraInfo.availableCameras.map((camera) => (h("button", { key: camera.id, class: `camera-option ${cameraInfo.selectedCameraId === camera.id ? 'selected' : ''}`, onClick: () => this.handleCameraSwitch(camera.id), type: "button" }, h("span", { class: "camera-label" }, camera.label || `Cámara ${cameraInfo.availableCameras.indexOf(camera) + 1}`, camera.hasAutofocus && (h("span", { class: "autofocus-icon", title: "Autofoco disponible" }, "\u29BF"))), cameraInfo.selectedCameraId === camera.id && (h("span", { class: "selected-indicator" }, "\u2713")))))), h("div", { key: 'cf3ca9fe1d626320ad2653a3db44cd86e998bcdf', class: "device-info" }, h("small", { key: '9b908dc6e759f1a5311b068dba10428ebd22cdc3' }, "Dispositivo: ", cameraInfo.deviceType)))), this.showManualCaptureButton && captureState.step === 'front' && !captureState.showFlipAnimation && !captureState.showSuccessAnimation && (h("div", { key: '9aa48412eaac0b2adf19f1defb3bc835ab031d9f', class: "manual-capture-section" }, h("button", { key: '1828e293ae4e544b00d0dd17a86401ff0436de37', class: "manual-capture-button", onClick: () => this.takeManualScreenshot(), type: "button", disabled: this.processingButton !== null }, this.processingButton === 'capture-front' && (h("span", { key: 'bbea1d654f80e537ff6616920fb6a2cb410e55f0', class: "button-spinner" })), "Capturar Frente"))))), captureState.isCapturing && (h("div", { key: '532f72395868ecf58bef350aed4da4e4fc0fa13c', class: "capture-animation" })), captureState.showFlipAnimation && (h("div", { key: '555cbc7504660b722f23389899956cf979a27e6c', class: "flip-animation" }, h("div", { key: 'e5de939b02cfb65697c70f265492f1f30f75c771', class: "id-card-icon" }), h("div", { key: '35867c2fbdf463d5b28f0bd3a58313d0d6f15e7b', class: "flip-text" }, "\u00A1Voltea tu identificaci\u00F3n!"))), captureState.showSuccessAnimation && (h("div", { key: '4a96d077e993012ed333384219ba27d5a68787ea', class: "success-animation" }, h("div", { key: '836809412d0674a0061aadaaa7c712a22f8770da', class: "check-icon" }), h("div", { key: 'd541dbdfa548760b196dd09dc44c3d1a6af8093c', class: "success-text" }, "\u00A1Proceso completado!"))), h("div", { key: '89a9d99fbeedff1bbcf723ba13d551c3290150fe', class: `component-status status-${this.currentStatus.type}` }, (this.currentStatus.type === 'loading' || this.currentStatus.type === 'initializing') && (h("div", { key: 'f100984baef7602ea40cea9bb74b4c84fd1f6ed9', class: "status-spinner" })), h("div", { key: 'ad4161c71f438174117e306e5084bfdff3d18dce', class: "status-content" }, h("div", { key: '26310245b58f331075dd344a6497e90631d5d78c', class: "status-message" }, this.currentStatus.message), this.currentStatus.description && (h("div", { key: 'f739148b45f7d43a3015cca3de8efc8b71d3d5e4', class: "status-description" }, this.currentStatus.description)))), this.debug && (h("div", { key: '0397b96391dff4f0662c913068a62c714df168bf', class: "performance-monitor" }, h("div", { key: 'da3c3638b3c048a425bf691b29755762ad40aa5c', class: "performance-expanded" }, h("div", { key: '467f5e2dc207cfd9fd31cef24d434452b3247c5f', class: "metrics-row" }, h("div", { key: 'e620d9017402317e09ec554bf933a4f5a5d0b0de', class: "metric-compact" }, h("span", { key: '8d21fa081bbf3ec7ad54f553b60b0a64ae41fb01', class: "metric-label" }, "FPS"), h("span", { key: '8e99113c7b93c128d7e390900a63f16c5b9483c0', class: `metric-value ${this.performanceData.fps < 15 ? 'warning' : this.performanceData.fps < 10 ? 'danger' : 'good'}` }, this.performanceData.fps)), h("div", { key: '67927ff90810b0c4d6717d520ad50142d5d6c0dd', class: "metric-compact" }, h("span", { key: '4810964d65c18248f01aff90dca36d732b80a05c', class: "metric-label" }, "MEM"), h("span", { key: 'e82ff493a2bc1d3baf60c1f638154e9208d0991f', class: `metric-value ${this.performanceData.memoryUsage > 100 ? 'warning' : this.performanceData.memoryUsage > 200 ? 'danger' : 'good'}` }, this.performanceData.memoryUsage, "MB"))), h("div", { key: '6ef07b3f3dc4c3d991f4bbae34e902a9efc1a359', class: "metrics-row" }, h("div", { key: 'b5eed3b30cb99d4d088a05494cda2eff0ba393cc', class: "metric-compact" }, h("span", { key: '52749839a61316b90f424b0920f4c82c6683dd29', class: "metric-label" }, "INF"), h("span", { key: '8509cf19af19b6ac2efc7ab68ac46d9d053c5464', class: `metric-value ${this.performanceData.inferenceTime > 100 ? 'warning' : this.performanceData.inferenceTime > 200 ? 'danger' : 'good'}` }, this.performanceData.inferenceTime, "ms")), h("div", { key: '34a8540d0840056a525a7afc35ca956943b527af', class: "metric-compact" }, h("span", { key: 'bdc2d8cd180b92ee7b84c8372aba5c2f33289669', class: "metric-label" }, "FRAME"), h("span", { key: '481a0735a5b7258fecdc1bab65a4d4018cc0e7b9', class: `metric-value ${this.performanceData.frameProcessingTime > 50 ? 'warning' : this.performanceData.frameProcessingTime > 100 ? 'danger' : 'good'}` }, this.performanceData.frameProcessingTime, "ms"))), h("div", { key: '7b5aa0a6fe97970f09db23103f7f0301fd98c4f8', class: "metrics-row" }, h("div", { key: '1c691159409e021176557904a1ceec05abc329e1', class: "metric-compact" }, h("span", { key: '5ab6c25d80548aa4e63c79ecf88d2386393ae707', class: "metric-label" }, "DET"), h("span", { key: '7641532633bc764d4dc209ba7e1827a2f3f59338', class: "metric-value good" }, this.performanceData.successfulDetections, "/", this.performanceData.totalDetections)), h("div", { key: 'feee52f464eeb965eeadfd944a65e94600591ed5', class: "metric-compact" }, h("span", { key: 'c7962650a7bf1bc86f8c733eb01d5eeb9e08d37e', class: "metric-label" }, "RATE"), h("span", { key: '337529444c8e7bacb47d686d0be33721a066eebe', class: `metric-value ${this.performanceData.detectionRate < 30 ? 'danger' : this.performanceData.detectionRate < 60 ? 'warning' : 'good'}` }, this.performanceData.detectionRate, "%")))))), h("div", { key: '49717c49e5316bfe10690733c5bf07eb0475a3e2', class: "watermark" }, h("img", { key: 'f86ff4364196627bb3f169e5ee1c14696126cd68', src: "https://storage.googleapis.com/jaak-static/commons/powered-by-jaak.png", alt: "Powered by Jaak" }))))));
|
|
998
1144
|
}
|
|
999
1145
|
// Utility methods
|
|
1000
1146
|
updateDetectionBoxes(boxes) {
|
|
@@ -1111,24 +1257,44 @@ export class JaakStamps {
|
|
|
1111
1257
|
}
|
|
1112
1258
|
async takeManualScreenshot() {
|
|
1113
1259
|
console.log('🔵 Botón clicked: Capturar (Frente/Reverso)');
|
|
1260
|
+
const captureStartTime = performance.now();
|
|
1261
|
+
const span = this.tracingService?.startSpan('capture.screenshot.manual');
|
|
1114
1262
|
// Set processing state immediately
|
|
1115
1263
|
const captureState = this.stateManager?.getCaptureState();
|
|
1264
|
+
const side = captureState?.step === 'front' ? 'front' : 'back';
|
|
1116
1265
|
if (captureState?.step === 'front') {
|
|
1117
1266
|
this.processingButton = 'capture-front';
|
|
1267
|
+
if (span)
|
|
1268
|
+
this.tracingService?.setSpanAttribute(span, 'side', 'front');
|
|
1118
1269
|
}
|
|
1119
1270
|
else if (captureState?.step === 'back') {
|
|
1120
1271
|
this.processingButton = 'capture-back';
|
|
1272
|
+
if (span)
|
|
1273
|
+
this.tracingService?.setSpanAttribute(span, 'side', 'back');
|
|
1121
1274
|
}
|
|
1275
|
+
// Record user interaction
|
|
1276
|
+
this.metricsService?.recordUserInteraction('manual_capture_button');
|
|
1122
1277
|
console.log('🔵 processingButton set to:', this.processingButton);
|
|
1123
1278
|
// Add small delay to show spinner
|
|
1124
1279
|
await new Promise(resolve => setTimeout(resolve, 100));
|
|
1125
1280
|
if (!this.videoRef) {
|
|
1126
1281
|
this.processingButton = null;
|
|
1282
|
+
if (span) {
|
|
1283
|
+
this.tracingService?.setSpanAttribute(span, 'error', 'no_video_ref');
|
|
1284
|
+
this.tracingService?.endSpan(span);
|
|
1285
|
+
}
|
|
1127
1286
|
return;
|
|
1128
1287
|
}
|
|
1129
1288
|
// When using manual capture, use mask coordinates for cropping
|
|
1130
1289
|
// Note: processingButton will be cleared inside takeScreenshotWithMaskCoordinates
|
|
1131
1290
|
await this.takeScreenshotWithMaskCoordinates();
|
|
1291
|
+
// Record metrics
|
|
1292
|
+
const captureDuration = performance.now() - captureStartTime;
|
|
1293
|
+
this.metricsService?.recordCapture(side, 'manual', captureDuration);
|
|
1294
|
+
if (span) {
|
|
1295
|
+
this.tracingService?.setSpanAttribute(span, 'success', true);
|
|
1296
|
+
this.tracingService?.endSpan(span);
|
|
1297
|
+
}
|
|
1132
1298
|
}
|
|
1133
1299
|
async takeScreenshotWithMaskCoordinates() {
|
|
1134
1300
|
if (!this.videoRef || !this.detectionContainer)
|
|
@@ -1247,6 +1413,8 @@ export class JaakStamps {
|
|
|
1247
1413
|
async takeScreenshot() {
|
|
1248
1414
|
if (!this.videoRef || !this.lastDetectedBox)
|
|
1249
1415
|
return;
|
|
1416
|
+
const captureStartTime = performance.now();
|
|
1417
|
+
const span = this.tracingService?.startSpan('capture.screenshot.auto');
|
|
1250
1418
|
this.stateManager.updateCaptureState({ isCapturing: true });
|
|
1251
1419
|
this.triggerCaptureAnimation();
|
|
1252
1420
|
// Use pooled canvas for optimization
|
|
@@ -1269,17 +1437,30 @@ export class JaakStamps {
|
|
|
1269
1437
|
croppedCtx.drawImage(this.videoRef, cropX, cropY, cropWidth, cropHeight, 0, 0, cropWidth, cropHeight);
|
|
1270
1438
|
const captureState = this.stateManager.getCaptureState();
|
|
1271
1439
|
if (captureState.step === 'front') {
|
|
1440
|
+
const frontImageData = captureCanvas.toDataURL('image/jpeg');
|
|
1441
|
+
const croppedImageData = croppedCanvas.toDataURL('image/jpeg');
|
|
1272
1442
|
this.stateManager.setCapturedImages({
|
|
1273
1443
|
front: {
|
|
1274
|
-
fullFrame:
|
|
1275
|
-
cropped:
|
|
1444
|
+
fullFrame: frontImageData,
|
|
1445
|
+
cropped: croppedImageData
|
|
1276
1446
|
}
|
|
1277
1447
|
});
|
|
1448
|
+
// Record metrics
|
|
1449
|
+
const captureDuration = performance.now() - captureStartTime;
|
|
1450
|
+
this.metricsService?.recordCapture('front', 'auto', captureDuration);
|
|
1451
|
+
this.metricsService?.recordImageSize('front', frontImageData.length);
|
|
1452
|
+
if (span) {
|
|
1453
|
+
this.tracingService?.setSpanAttribute(span, 'side', 'front');
|
|
1454
|
+
}
|
|
1278
1455
|
// Check if document classification is enabled
|
|
1279
1456
|
if (this.useDocumentClassification) {
|
|
1280
1457
|
try {
|
|
1281
1458
|
const classification = await this.detectionService.classifyDocument(croppedCanvas);
|
|
1282
1459
|
if (classification && classification.class === 'passport') {
|
|
1460
|
+
if (span) {
|
|
1461
|
+
this.tracingService?.setSpanAttribute(span, 'document.type', 'passport');
|
|
1462
|
+
this.tracingService?.endSpan(span);
|
|
1463
|
+
}
|
|
1283
1464
|
this.completeProcess(true);
|
|
1284
1465
|
return;
|
|
1285
1466
|
}
|
|
@@ -1293,6 +1474,9 @@ export class JaakStamps {
|
|
|
1293
1474
|
isDetectionPaused: true,
|
|
1294
1475
|
showFlipAnimation: true
|
|
1295
1476
|
});
|
|
1477
|
+
if (span) {
|
|
1478
|
+
this.tracingService?.endSpan(span);
|
|
1479
|
+
}
|
|
1296
1480
|
setTimeout(() => {
|
|
1297
1481
|
this.stateManager.updateCaptureState({
|
|
1298
1482
|
showFlipAnimation: false,
|
|
@@ -1302,12 +1486,22 @@ export class JaakStamps {
|
|
|
1302
1486
|
}, 3000);
|
|
1303
1487
|
}
|
|
1304
1488
|
else if (captureState.step === 'back') {
|
|
1489
|
+
const backImageData = captureCanvas.toDataURL('image/jpeg');
|
|
1490
|
+
const croppedBackImageData = croppedCanvas.toDataURL('image/jpeg');
|
|
1305
1491
|
this.stateManager.setCapturedImages({
|
|
1306
1492
|
back: {
|
|
1307
|
-
fullFrame:
|
|
1308
|
-
cropped:
|
|
1493
|
+
fullFrame: backImageData,
|
|
1494
|
+
cropped: croppedBackImageData
|
|
1309
1495
|
}
|
|
1310
1496
|
});
|
|
1497
|
+
// Record metrics
|
|
1498
|
+
const captureDuration = performance.now() - captureStartTime;
|
|
1499
|
+
this.metricsService?.recordCapture('back', 'auto', captureDuration);
|
|
1500
|
+
this.metricsService?.recordImageSize('back', backImageData.length);
|
|
1501
|
+
if (span) {
|
|
1502
|
+
this.tracingService?.setSpanAttribute(span, 'side', 'back');
|
|
1503
|
+
this.tracingService?.endSpan(span);
|
|
1504
|
+
}
|
|
1311
1505
|
this.completeProcess(false);
|
|
1312
1506
|
}
|
|
1313
1507
|
// Return canvases to pool after use
|
|
@@ -1944,6 +2138,261 @@ export class JaakStamps {
|
|
|
1944
2138
|
"setter": false,
|
|
1945
2139
|
"reflect": false,
|
|
1946
2140
|
"defaultValue": "20"
|
|
2141
|
+
},
|
|
2142
|
+
"telemetryCollectorUrl": {
|
|
2143
|
+
"type": "string",
|
|
2144
|
+
"attribute": "telemetry-collector-url",
|
|
2145
|
+
"mutable": false,
|
|
2146
|
+
"complexType": {
|
|
2147
|
+
"original": "string",
|
|
2148
|
+
"resolved": "string",
|
|
2149
|
+
"references": {}
|
|
2150
|
+
},
|
|
2151
|
+
"required": false,
|
|
2152
|
+
"optional": true,
|
|
2153
|
+
"docs": {
|
|
2154
|
+
"tags": [],
|
|
2155
|
+
"text": ""
|
|
2156
|
+
},
|
|
2157
|
+
"getter": false,
|
|
2158
|
+
"setter": false,
|
|
2159
|
+
"reflect": false,
|
|
2160
|
+
"defaultValue": "'https://collector.jaak.ai/v1/traces'"
|
|
2161
|
+
},
|
|
2162
|
+
"metricsCollectorUrl": {
|
|
2163
|
+
"type": "string",
|
|
2164
|
+
"attribute": "metrics-collector-url",
|
|
2165
|
+
"mutable": false,
|
|
2166
|
+
"complexType": {
|
|
2167
|
+
"original": "string",
|
|
2168
|
+
"resolved": "string",
|
|
2169
|
+
"references": {}
|
|
2170
|
+
},
|
|
2171
|
+
"required": false,
|
|
2172
|
+
"optional": true,
|
|
2173
|
+
"docs": {
|
|
2174
|
+
"tags": [],
|
|
2175
|
+
"text": ""
|
|
2176
|
+
},
|
|
2177
|
+
"getter": false,
|
|
2178
|
+
"setter": false,
|
|
2179
|
+
"reflect": false,
|
|
2180
|
+
"defaultValue": "'https://collector.jaak.ai/v1/metrics'"
|
|
2181
|
+
},
|
|
2182
|
+
"enableTelemetry": {
|
|
2183
|
+
"type": "boolean",
|
|
2184
|
+
"attribute": "enable-telemetry",
|
|
2185
|
+
"mutable": false,
|
|
2186
|
+
"complexType": {
|
|
2187
|
+
"original": "boolean",
|
|
2188
|
+
"resolved": "boolean",
|
|
2189
|
+
"references": {}
|
|
2190
|
+
},
|
|
2191
|
+
"required": false,
|
|
2192
|
+
"optional": false,
|
|
2193
|
+
"docs": {
|
|
2194
|
+
"tags": [],
|
|
2195
|
+
"text": ""
|
|
2196
|
+
},
|
|
2197
|
+
"getter": false,
|
|
2198
|
+
"setter": false,
|
|
2199
|
+
"reflect": false,
|
|
2200
|
+
"defaultValue": "true"
|
|
2201
|
+
},
|
|
2202
|
+
"enableMetrics": {
|
|
2203
|
+
"type": "boolean",
|
|
2204
|
+
"attribute": "enable-metrics",
|
|
2205
|
+
"mutable": false,
|
|
2206
|
+
"complexType": {
|
|
2207
|
+
"original": "boolean",
|
|
2208
|
+
"resolved": "boolean",
|
|
2209
|
+
"references": {}
|
|
2210
|
+
},
|
|
2211
|
+
"required": false,
|
|
2212
|
+
"optional": false,
|
|
2213
|
+
"docs": {
|
|
2214
|
+
"tags": [],
|
|
2215
|
+
"text": ""
|
|
2216
|
+
},
|
|
2217
|
+
"getter": false,
|
|
2218
|
+
"setter": false,
|
|
2219
|
+
"reflect": false,
|
|
2220
|
+
"defaultValue": "true"
|
|
2221
|
+
},
|
|
2222
|
+
"customerId": {
|
|
2223
|
+
"type": "string",
|
|
2224
|
+
"attribute": "customer-id",
|
|
2225
|
+
"mutable": false,
|
|
2226
|
+
"complexType": {
|
|
2227
|
+
"original": "string",
|
|
2228
|
+
"resolved": "string",
|
|
2229
|
+
"references": {}
|
|
2230
|
+
},
|
|
2231
|
+
"required": false,
|
|
2232
|
+
"optional": true,
|
|
2233
|
+
"docs": {
|
|
2234
|
+
"tags": [],
|
|
2235
|
+
"text": ""
|
|
2236
|
+
},
|
|
2237
|
+
"getter": false,
|
|
2238
|
+
"setter": false,
|
|
2239
|
+
"reflect": false
|
|
2240
|
+
},
|
|
2241
|
+
"tenantId": {
|
|
2242
|
+
"type": "string",
|
|
2243
|
+
"attribute": "tenant-id",
|
|
2244
|
+
"mutable": false,
|
|
2245
|
+
"complexType": {
|
|
2246
|
+
"original": "string",
|
|
2247
|
+
"resolved": "string",
|
|
2248
|
+
"references": {}
|
|
2249
|
+
},
|
|
2250
|
+
"required": false,
|
|
2251
|
+
"optional": true,
|
|
2252
|
+
"docs": {
|
|
2253
|
+
"tags": [],
|
|
2254
|
+
"text": ""
|
|
2255
|
+
},
|
|
2256
|
+
"getter": false,
|
|
2257
|
+
"setter": false,
|
|
2258
|
+
"reflect": false
|
|
2259
|
+
},
|
|
2260
|
+
"environment": {
|
|
2261
|
+
"type": "string",
|
|
2262
|
+
"attribute": "environment",
|
|
2263
|
+
"mutable": false,
|
|
2264
|
+
"complexType": {
|
|
2265
|
+
"original": "string",
|
|
2266
|
+
"resolved": "string",
|
|
2267
|
+
"references": {}
|
|
2268
|
+
},
|
|
2269
|
+
"required": false,
|
|
2270
|
+
"optional": true,
|
|
2271
|
+
"docs": {
|
|
2272
|
+
"tags": [],
|
|
2273
|
+
"text": ""
|
|
2274
|
+
},
|
|
2275
|
+
"getter": false,
|
|
2276
|
+
"setter": false,
|
|
2277
|
+
"reflect": false,
|
|
2278
|
+
"defaultValue": "'production'"
|
|
2279
|
+
},
|
|
2280
|
+
"propagateTraceHeaderCorsUrls": {
|
|
2281
|
+
"type": "string",
|
|
2282
|
+
"attribute": "propagate-trace-header-cors-urls",
|
|
2283
|
+
"mutable": false,
|
|
2284
|
+
"complexType": {
|
|
2285
|
+
"original": "string",
|
|
2286
|
+
"resolved": "string",
|
|
2287
|
+
"references": {}
|
|
2288
|
+
},
|
|
2289
|
+
"required": false,
|
|
2290
|
+
"optional": true,
|
|
2291
|
+
"docs": {
|
|
2292
|
+
"tags": [],
|
|
2293
|
+
"text": ""
|
|
2294
|
+
},
|
|
2295
|
+
"getter": false,
|
|
2296
|
+
"setter": false,
|
|
2297
|
+
"reflect": false
|
|
2298
|
+
},
|
|
2299
|
+
"metricsExportIntervalMillis": {
|
|
2300
|
+
"type": "number",
|
|
2301
|
+
"attribute": "metrics-export-interval-millis",
|
|
2302
|
+
"mutable": false,
|
|
2303
|
+
"complexType": {
|
|
2304
|
+
"original": "number",
|
|
2305
|
+
"resolved": "number",
|
|
2306
|
+
"references": {}
|
|
2307
|
+
},
|
|
2308
|
+
"required": false,
|
|
2309
|
+
"optional": true,
|
|
2310
|
+
"docs": {
|
|
2311
|
+
"tags": [],
|
|
2312
|
+
"text": ""
|
|
2313
|
+
},
|
|
2314
|
+
"getter": false,
|
|
2315
|
+
"setter": false,
|
|
2316
|
+
"reflect": false,
|
|
2317
|
+
"defaultValue": "60000"
|
|
2318
|
+
},
|
|
2319
|
+
"license": {
|
|
2320
|
+
"type": "string",
|
|
2321
|
+
"attribute": "license",
|
|
2322
|
+
"mutable": false,
|
|
2323
|
+
"complexType": {
|
|
2324
|
+
"original": "string",
|
|
2325
|
+
"resolved": "string",
|
|
2326
|
+
"references": {}
|
|
2327
|
+
},
|
|
2328
|
+
"required": false,
|
|
2329
|
+
"optional": true,
|
|
2330
|
+
"docs": {
|
|
2331
|
+
"tags": [],
|
|
2332
|
+
"text": ""
|
|
2333
|
+
},
|
|
2334
|
+
"getter": false,
|
|
2335
|
+
"setter": false,
|
|
2336
|
+
"reflect": false
|
|
2337
|
+
},
|
|
2338
|
+
"licenseEnvironment": {
|
|
2339
|
+
"type": "string",
|
|
2340
|
+
"attribute": "license-environment",
|
|
2341
|
+
"mutable": false,
|
|
2342
|
+
"complexType": {
|
|
2343
|
+
"original": "'dev' | 'qa' | 'staging' | 'prod'",
|
|
2344
|
+
"resolved": "\"dev\" | \"prod\" | \"qa\" | \"staging\"",
|
|
2345
|
+
"references": {}
|
|
2346
|
+
},
|
|
2347
|
+
"required": false,
|
|
2348
|
+
"optional": true,
|
|
2349
|
+
"docs": {
|
|
2350
|
+
"tags": [],
|
|
2351
|
+
"text": ""
|
|
2352
|
+
},
|
|
2353
|
+
"getter": false,
|
|
2354
|
+
"setter": false,
|
|
2355
|
+
"reflect": false,
|
|
2356
|
+
"defaultValue": "'prod'"
|
|
2357
|
+
},
|
|
2358
|
+
"traceId": {
|
|
2359
|
+
"type": "string",
|
|
2360
|
+
"attribute": "trace-id",
|
|
2361
|
+
"mutable": false,
|
|
2362
|
+
"complexType": {
|
|
2363
|
+
"original": "string",
|
|
2364
|
+
"resolved": "string",
|
|
2365
|
+
"references": {}
|
|
2366
|
+
},
|
|
2367
|
+
"required": false,
|
|
2368
|
+
"optional": true,
|
|
2369
|
+
"docs": {
|
|
2370
|
+
"tags": [],
|
|
2371
|
+
"text": ""
|
|
2372
|
+
},
|
|
2373
|
+
"getter": false,
|
|
2374
|
+
"setter": false,
|
|
2375
|
+
"reflect": false
|
|
2376
|
+
},
|
|
2377
|
+
"appId": {
|
|
2378
|
+
"type": "string",
|
|
2379
|
+
"attribute": "app-id",
|
|
2380
|
+
"mutable": false,
|
|
2381
|
+
"complexType": {
|
|
2382
|
+
"original": "string",
|
|
2383
|
+
"resolved": "string",
|
|
2384
|
+
"references": {}
|
|
2385
|
+
},
|
|
2386
|
+
"required": false,
|
|
2387
|
+
"optional": true,
|
|
2388
|
+
"docs": {
|
|
2389
|
+
"tags": [],
|
|
2390
|
+
"text": ""
|
|
2391
|
+
},
|
|
2392
|
+
"getter": false,
|
|
2393
|
+
"setter": false,
|
|
2394
|
+
"reflect": false,
|
|
2395
|
+
"defaultValue": "'jaak-stamps-web'"
|
|
1947
2396
|
}
|
|
1948
2397
|
};
|
|
1949
2398
|
}
|
|
@@ -1964,7 +2413,9 @@ export class JaakStamps {
|
|
|
1964
2413
|
"performanceDegradedMode": {},
|
|
1965
2414
|
"showPerformanceMessage": {},
|
|
1966
2415
|
"captureStateVersion": {},
|
|
1967
|
-
"processingButton": {}
|
|
2416
|
+
"processingButton": {},
|
|
2417
|
+
"licenseValid": {},
|
|
2418
|
+
"licenseError": {}
|
|
1968
2419
|
};
|
|
1969
2420
|
}
|
|
1970
2421
|
static get events() {
|
|
@@ -1998,6 +2449,21 @@ export class JaakStamps {
|
|
|
1998
2449
|
"resolved": "boolean",
|
|
1999
2450
|
"references": {}
|
|
2000
2451
|
}
|
|
2452
|
+
}, {
|
|
2453
|
+
"method": "traceIdGenerated",
|
|
2454
|
+
"name": "traceIdGenerated",
|
|
2455
|
+
"bubbles": true,
|
|
2456
|
+
"cancelable": true,
|
|
2457
|
+
"composed": true,
|
|
2458
|
+
"docs": {
|
|
2459
|
+
"tags": [],
|
|
2460
|
+
"text": ""
|
|
2461
|
+
},
|
|
2462
|
+
"complexType": {
|
|
2463
|
+
"original": "{traceId: string}",
|
|
2464
|
+
"resolved": "{ traceId: string; }",
|
|
2465
|
+
"references": {}
|
|
2466
|
+
}
|
|
2001
2467
|
}];
|
|
2002
2468
|
}
|
|
2003
2469
|
static get methods() {
|