monkey-front-core 0.0.552 → 0.0.554
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/esm2020/lib/core/services/config/monkeyecx-logs-config.service.mjs +29 -4
- package/fesm2015/monkey-front-core.mjs +29 -3
- package/fesm2015/monkey-front-core.mjs.map +1 -1
- package/fesm2020/monkey-front-core.mjs +27 -3
- package/fesm2020/monkey-front-core.mjs.map +1 -1
- package/lib/core/services/config/monkeyecx-logs-config.service.d.ts +5 -0
- package/monkey-front-core-0.0.554.tgz +0 -0
- package/package.json +1 -1
- package/monkey-front-core-0.0.552.tgz +0 -0
|
@@ -3901,8 +3901,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImpor
|
|
|
3901
3901
|
}], ctorParameters: function () { return [{ type: MonkeyEcxService }, { type: MonkeyEcxTokenStorageService }, { type: i1$1.TranslateService }, { type: MonkeyEcxErrorConfigService }]; } });
|
|
3902
3902
|
|
|
3903
3903
|
class MonkeyEcxLogsConfigService {
|
|
3904
|
-
constructor() {
|
|
3904
|
+
constructor(tokenStorage) {
|
|
3905
|
+
this.tokenStorage = tokenStorage;
|
|
3905
3906
|
this.allSet = false;
|
|
3907
|
+
// not to do
|
|
3906
3908
|
}
|
|
3907
3909
|
apply(params, configBootstrap, environment, identifyCode) {
|
|
3908
3910
|
const { program, logs } = params;
|
|
@@ -3924,18 +3926,40 @@ class MonkeyEcxLogsConfigService {
|
|
|
3924
3926
|
defaultPrivacyLevel: 'mask-user-input'
|
|
3925
3927
|
});
|
|
3926
3928
|
datadogRum.startSessionReplayRecording();
|
|
3929
|
+
this.applyInfoToDataDog(environment);
|
|
3927
3930
|
this.allSet = true;
|
|
3928
3931
|
}
|
|
3929
3932
|
}
|
|
3933
|
+
async applyInfoToDataDog(environment) {
|
|
3934
|
+
try {
|
|
3935
|
+
const token = await this.tokenStorage.getToken();
|
|
3936
|
+
if (token.accessToken && environment.dataDogApplicationId) {
|
|
3937
|
+
const me = await this.tokenStorage.getMe();
|
|
3938
|
+
const user = {
|
|
3939
|
+
id: token.username,
|
|
3940
|
+
email: token.username,
|
|
3941
|
+
name: me.name,
|
|
3942
|
+
locale: me.locale
|
|
3943
|
+
};
|
|
3944
|
+
datadogRum.setUser(user);
|
|
3945
|
+
}
|
|
3946
|
+
}
|
|
3947
|
+
catch (e) {
|
|
3948
|
+
// not to do
|
|
3949
|
+
}
|
|
3950
|
+
}
|
|
3951
|
+
clearDataDogInfo() {
|
|
3952
|
+
datadogRum.clearUser();
|
|
3953
|
+
}
|
|
3930
3954
|
}
|
|
3931
|
-
MonkeyEcxLogsConfigService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: MonkeyEcxLogsConfigService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
3955
|
+
MonkeyEcxLogsConfigService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: MonkeyEcxLogsConfigService, deps: [{ token: MonkeyEcxTokenStorageService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
3932
3956
|
MonkeyEcxLogsConfigService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: MonkeyEcxLogsConfigService, providedIn: 'root' });
|
|
3933
3957
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.1.1", ngImport: i0, type: MonkeyEcxLogsConfigService, decorators: [{
|
|
3934
3958
|
type: Injectable,
|
|
3935
3959
|
args: [{
|
|
3936
3960
|
providedIn: 'root'
|
|
3937
3961
|
}]
|
|
3938
|
-
}] });
|
|
3962
|
+
}], ctorParameters: function () { return [{ type: MonkeyEcxTokenStorageService }]; } });
|
|
3939
3963
|
|
|
3940
3964
|
class MonkeyEcxServiceWorkerConfigService {
|
|
3941
3965
|
constructor(appRef, updates, modalService) {
|