@smartbit4all/ng-client 3.1.25 → 3.1.27
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/session/projects.mjs +7 -9
- package/esm2020/lib/session/smart-session.module.mjs +6 -22
- package/esm2020/lib/smart-form/widgets/components/smart-month-picker/smart-month-picker.component.mjs +18 -22
- package/fesm2015/smartbit4all-ng-client.mjs +22 -396
- package/fesm2015/smartbit4all-ng-client.mjs.map +1 -1
- package/fesm2020/smartbit4all-ng-client.mjs +22 -394
- package/fesm2020/smartbit4all-ng-client.mjs.map +1 -1
- package/lib/session/projects.d.ts +6 -8
- package/lib/session/smart-session.module.d.ts +7 -10
- package/lib/smart-form/widgets/components/smart-month-picker/smart-month-picker.component.d.ts +7 -8
- package/package.json +1 -1
- package/smartbit4all-ng-client-3.1.27.tgz +0 -0
- package/esm2020/lib/session/dev-tool/smart-dev-tool-dialog/smart-dev-tool-dialog.component.mjs +0 -90
- package/esm2020/lib/session/dev-tool/smart-dev-tool-dialog/smart-dev-tool-dialog.service.mjs +0 -43
- package/esm2020/lib/session/dev-tool/smart-dev-tool-floating-button/smart-dev-tool-floating-button.component.mjs +0 -40
- package/esm2020/lib/session/dev-tool/smart-dev-tool.interceptor.mjs +0 -52
- package/esm2020/lib/session/dev-tool/smart-dev-tool.service.mjs +0 -165
- package/lib/session/dev-tool/smart-dev-tool-dialog/smart-dev-tool-dialog.component.d.ts +0 -28
- package/lib/session/dev-tool/smart-dev-tool-dialog/smart-dev-tool-dialog.service.d.ts +0 -18
- package/lib/session/dev-tool/smart-dev-tool-floating-button/smart-dev-tool-floating-button.component.d.ts +0 -15
- package/lib/session/dev-tool/smart-dev-tool.interceptor.d.ts +0 -18
- package/lib/session/dev-tool/smart-dev-tool.service.d.ts +0 -57
- package/smartbit4all-ng-client-3.1.25.tgz +0 -0
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
2
|
import { InjectionToken, Injectable, Optional, Inject, PLATFORM_ID, NgModule, SkipSelf, Component, Input, ViewChild, forwardRef, EventEmitter, Output, Directive, HostListener, ViewContainerRef, ViewEncapsulation, ViewChildren, Pipe, CUSTOM_ELEMENTS_SCHEMA, NO_ERRORS_SCHEMA } from '@angular/core';
|
|
3
|
-
import { Subject, takeUntil, startWith, map, distinctUntilChanged,
|
|
3
|
+
import { Subject, takeUntil, startWith, map, distinctUntilChanged, throwError, from, catchError as catchError$1, lastValueFrom } from 'rxjs';
|
|
4
4
|
import * as i1 from '@angular/common/http';
|
|
5
|
-
import { HttpHeaders, HttpContext, HttpParams,
|
|
5
|
+
import { HttpHeaders, HttpContext, HttpParams, HTTP_INTERCEPTORS, HttpClientModule } from '@angular/common/http';
|
|
6
6
|
import * as i3$1 from '@angular/common';
|
|
7
7
|
import { isPlatformBrowser, DOCUMENT, DatePipe, CommonModule } from '@angular/common';
|
|
8
8
|
import * as i3 from '@angular/material/button';
|
|
@@ -16,7 +16,7 @@ import * as i7 from '@angular/material/core';
|
|
|
16
16
|
import { DateAdapter, MAT_DATE_LOCALE, MAT_DATE_FORMATS, MatCommonModule } from '@angular/material/core';
|
|
17
17
|
import * as i2$1 from '@angular/platform-browser';
|
|
18
18
|
import { BrowserModule } from '@angular/platform-browser';
|
|
19
|
-
import * as
|
|
19
|
+
import * as i2$6 from '@angular/material/expansion';
|
|
20
20
|
import { MatExpansionModule } from '@angular/material/expansion';
|
|
21
21
|
import * as i20 from '@angular/forms';
|
|
22
22
|
import { FormGroup, FormControl, Validators, NG_VALUE_ACCESSOR, FormsModule, ReactiveFormsModule } from '@angular/forms';
|
|
@@ -60,7 +60,7 @@ import { MatProgressSpinnerModule } from '@angular/material/progress-spinner';
|
|
|
60
60
|
import { trigger, state, style, transition, animate } from '@angular/animations';
|
|
61
61
|
import * as i2$4 from '@angular/material/table';
|
|
62
62
|
import { MatTableModule } from '@angular/material/table';
|
|
63
|
-
import { catchError
|
|
63
|
+
import { catchError, switchMap } from 'rxjs/operators';
|
|
64
64
|
import * as i2$5 from '@angular/material/tree';
|
|
65
65
|
import { MatTreeNestedDataSource, MatTreeModule } from '@angular/material/tree';
|
|
66
66
|
import { NestedTreeControl } from '@angular/cdk/tree';
|
|
@@ -4466,13 +4466,13 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImpor
|
|
|
4466
4466
|
|
|
4467
4467
|
const YEARH_MONTH_FORMAT = {
|
|
4468
4468
|
parse: {
|
|
4469
|
-
dateInput:
|
|
4469
|
+
dateInput: 'MM/YYYY',
|
|
4470
4470
|
},
|
|
4471
4471
|
display: {
|
|
4472
|
-
dateInput:
|
|
4473
|
-
monthYearLabel:
|
|
4474
|
-
dateA11yLabel:
|
|
4475
|
-
monthYearA11yLabel:
|
|
4472
|
+
dateInput: 'MM/YYYY',
|
|
4473
|
+
monthYearLabel: 'MMM YYYY',
|
|
4474
|
+
dateA11yLabel: 'LL',
|
|
4475
|
+
monthYearA11yLabel: 'MMMM YYYY',
|
|
4476
4476
|
},
|
|
4477
4477
|
};
|
|
4478
4478
|
class SmartMonthPickerComponent {
|
|
@@ -4490,14 +4490,10 @@ class SmartMonthPickerComponent {
|
|
|
4490
4490
|
this.date = new FormControl(moment());
|
|
4491
4491
|
}
|
|
4492
4492
|
}
|
|
4493
|
-
|
|
4493
|
+
chosenMonthHandler(moment, datepicker) {
|
|
4494
4494
|
const ctrlValue = this.date.value;
|
|
4495
|
-
ctrlValue.
|
|
4496
|
-
|
|
4497
|
-
}
|
|
4498
|
-
chosenMonthHandler(normalizedMonth, datepicker) {
|
|
4499
|
-
const ctrlValue = this.date.value;
|
|
4500
|
-
ctrlValue.month(normalizedMonth.month());
|
|
4495
|
+
ctrlValue.month(moment.month());
|
|
4496
|
+
ctrlValue.year(moment.year());
|
|
4501
4497
|
this.date.setValue(ctrlValue);
|
|
4502
4498
|
this.valueChange.next(ctrlValue);
|
|
4503
4499
|
datepicker.close();
|
|
@@ -4511,17 +4507,17 @@ SmartMonthPickerComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.
|
|
|
4511
4507
|
deps: [MAT_DATE_LOCALE, MAT_MOMENT_DATE_ADAPTER_OPTIONS],
|
|
4512
4508
|
},
|
|
4513
4509
|
{ provide: MAT_DATE_FORMATS, useValue: YEARH_MONTH_FORMAT },
|
|
4514
|
-
], ngImport: i0, template: "<div class=\"smart-month-picker-container\">\r\n <mat-form-field appearance=\"outline\">\r\n <input
|
|
4510
|
+
], ngImport: i0, template: "<div class=\"smart-month-picker-container\">\r\n <mat-form-field appearance=\"outline\">\r\n <input matInput [matDatepicker]=\"dp\" placeholder=\"Month and Year\" [formControl]=\"date\" />\r\n <mat-datepicker-toggle matSuffix [for]=\"dp\"></mat-datepicker-toggle>\r\n <mat-datepicker\r\n #dp\r\n startView=\"multi-year\"\r\n (monthSelected)=\"chosenMonthHandler($event, dp)\"\r\n panelClass=\"example-month-picker\"\r\n >\r\n </mat-datepicker>\r\n </mat-form-field>\r\n <div class=\"smart-month-picker-hint\">\r\n <mat-hint\r\n *ngIf=\"\r\n !widgetInstance?.hintConfig ||\r\n widgetInstance?.hintConfig?.position === SmartWidgetHintPosition.UNDER_INPUT\r\n \"\r\n >{{ widgetInstance.hint }}</mat-hint\r\n >\r\n </div>\r\n</div>\r\n", styles: [""], components: [{ type: i3$2.MatFormField, selector: "mat-form-field", inputs: ["color", "appearance", "hideRequiredMarker", "hintLabel", "floatLabel"], exportAs: ["matFormField"] }, { type: i2$3.MatDatepickerToggle, selector: "mat-datepicker-toggle", inputs: ["for", "tabIndex", "aria-label", "disabled", "disableRipple"], exportAs: ["matDatepickerToggle"] }, { type: i2$3.MatDatepicker, selector: "mat-datepicker", exportAs: ["matDatepicker"] }], directives: [{ type: i3$3.MatInput, selector: "input[matInput], textarea[matInput], select[matNativeControl], input[matNativeControl], textarea[matNativeControl]", inputs: ["disabled", "id", "placeholder", "name", "required", "type", "errorStateMatcher", "aria-describedby", "value", "readonly"], exportAs: ["matInput"] }, { type: i2$3.MatDatepickerInput, selector: "input[matDatepicker]", inputs: ["matDatepicker", "min", "max", "matDatepickerFilter"], exportAs: ["matDatepickerInput"] }, { type: i20.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i20.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i20.FormControlDirective, selector: "[formControl]", inputs: ["formControl", "disabled", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { type: i3$2.MatSuffix, selector: "[matSuffix]" }, { type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i3$2.MatHint, selector: "mat-hint", inputs: ["align", "id"] }] });
|
|
4515
4511
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartMonthPickerComponent, decorators: [{
|
|
4516
4512
|
type: Component,
|
|
4517
|
-
args: [{ selector:
|
|
4513
|
+
args: [{ selector: 'lib-smart-month-picker', providers: [
|
|
4518
4514
|
{
|
|
4519
4515
|
provide: DateAdapter,
|
|
4520
4516
|
useClass: MomentDateAdapter,
|
|
4521
4517
|
deps: [MAT_DATE_LOCALE, MAT_MOMENT_DATE_ADAPTER_OPTIONS],
|
|
4522
4518
|
},
|
|
4523
4519
|
{ provide: MAT_DATE_FORMATS, useValue: YEARH_MONTH_FORMAT },
|
|
4524
|
-
], template: "<div class=\"smart-month-picker-container\">\r\n <mat-form-field appearance=\"outline\">\r\n <input
|
|
4520
|
+
], template: "<div class=\"smart-month-picker-container\">\r\n <mat-form-field appearance=\"outline\">\r\n <input matInput [matDatepicker]=\"dp\" placeholder=\"Month and Year\" [formControl]=\"date\" />\r\n <mat-datepicker-toggle matSuffix [for]=\"dp\"></mat-datepicker-toggle>\r\n <mat-datepicker\r\n #dp\r\n startView=\"multi-year\"\r\n (monthSelected)=\"chosenMonthHandler($event, dp)\"\r\n panelClass=\"example-month-picker\"\r\n >\r\n </mat-datepicker>\r\n </mat-form-field>\r\n <div class=\"smart-month-picker-hint\">\r\n <mat-hint\r\n *ngIf=\"\r\n !widgetInstance?.hintConfig ||\r\n widgetInstance?.hintConfig?.position === SmartWidgetHintPosition.UNDER_INPUT\r\n \"\r\n >{{ widgetInstance.hint }}</mat-hint\r\n >\r\n </div>\r\n</div>\r\n", styles: [""] }]
|
|
4525
4521
|
}], propDecorators: { widgetInstance: [{
|
|
4526
4522
|
type: Input
|
|
4527
4523
|
}], valueChange: [{
|
|
@@ -6727,362 +6723,6 @@ var SmartActionType;
|
|
|
6727
6723
|
* Public API Surface of smartdialog
|
|
6728
6724
|
*/
|
|
6729
6725
|
|
|
6730
|
-
class SmartDevToolService {
|
|
6731
|
-
constructor(cookieService) {
|
|
6732
|
-
this.cookieService = cookieService;
|
|
6733
|
-
this.smartDevToolName = 'smartDevTool';
|
|
6734
|
-
this.isSmartDevToolActiveName = 'smartDevToolActive';
|
|
6735
|
-
this.isActive = false;
|
|
6736
|
-
this.smartDevToolHoursName = 'smartDevToolHours';
|
|
6737
|
-
this.smartDevToolMaxName = 'smartDevToolMaxCalls';
|
|
6738
|
-
this.hoursToSave = 1;
|
|
6739
|
-
this.maxNumOfSavedCalls = 50;
|
|
6740
|
-
this._destroy$ = new Subject();
|
|
6741
|
-
this.descriptorChanged = new SmartSubject(this._destroy$);
|
|
6742
|
-
this.newErrorsCount = 0;
|
|
6743
|
-
this.newErrorsCountChanged = new SmartSubject(this._destroy$);
|
|
6744
|
-
this.setUpLocalStorage();
|
|
6745
|
-
let apiCallsFromLocalStorage = localStorage.getItem(this.smartDevToolName);
|
|
6746
|
-
if (apiCallsFromLocalStorage) {
|
|
6747
|
-
this.descriptor = JSON.parse(apiCallsFromLocalStorage);
|
|
6748
|
-
}
|
|
6749
|
-
else {
|
|
6750
|
-
this.descriptor = { apiCalls: [] };
|
|
6751
|
-
this.save();
|
|
6752
|
-
}
|
|
6753
|
-
window.addEventListener('storage', (event) => {
|
|
6754
|
-
if (event.storageArea === localStorage) {
|
|
6755
|
-
this.isActive = localStorage.getItem(this.isSmartDevToolActiveName) === 'true';
|
|
6756
|
-
let hoursToSaveString = localStorage.getItem(this.smartDevToolHoursName);
|
|
6757
|
-
if (hoursToSaveString) {
|
|
6758
|
-
this.hoursToSave = Number.parseInt(hoursToSaveString);
|
|
6759
|
-
}
|
|
6760
|
-
let maxNumOfSavedCalls = localStorage.getItem(this.smartDevToolMaxName);
|
|
6761
|
-
if (maxNumOfSavedCalls) {
|
|
6762
|
-
this.maxNumOfSavedCalls = Number.parseInt(maxNumOfSavedCalls);
|
|
6763
|
-
}
|
|
6764
|
-
}
|
|
6765
|
-
});
|
|
6766
|
-
}
|
|
6767
|
-
ngOnDestroy() {
|
|
6768
|
-
this._destroy$.next();
|
|
6769
|
-
this._destroy$.complete();
|
|
6770
|
-
}
|
|
6771
|
-
setUpLocalStorage() {
|
|
6772
|
-
let keysOfLocalStorage = Object.keys(localStorage);
|
|
6773
|
-
if (!keysOfLocalStorage.includes(this.isSmartDevToolActiveName)) {
|
|
6774
|
-
localStorage.setItem(this.isSmartDevToolActiveName, 'true');
|
|
6775
|
-
}
|
|
6776
|
-
}
|
|
6777
|
-
writeResponse(request, response, requestDate, responseDate) {
|
|
6778
|
-
this.sanitizeByLength();
|
|
6779
|
-
this.sanitizeByTime();
|
|
6780
|
-
let requestHeader = this.createObject(request.headers.keys(), request.headers, false);
|
|
6781
|
-
let responseHeader = this.createObject(response.headers.keys(), response.headers, false);
|
|
6782
|
-
let _localStorage = this.createObject(Object.keys(localStorage).filter((key) => key !== this.smartDevToolName), localStorage, true);
|
|
6783
|
-
let _sessionStorage = this.createObject(Object.keys(sessionStorage), sessionStorage, true);
|
|
6784
|
-
let _cookies = this.cookieService.getAll();
|
|
6785
|
-
this.descriptor.apiCalls = [
|
|
6786
|
-
{
|
|
6787
|
-
url: response.url,
|
|
6788
|
-
requestBody: request.body,
|
|
6789
|
-
requestHeader,
|
|
6790
|
-
requestDate,
|
|
6791
|
-
requestMethod: request.method,
|
|
6792
|
-
responseBody: response.body ?? null,
|
|
6793
|
-
responseHeader,
|
|
6794
|
-
responseStatus: response.status,
|
|
6795
|
-
responseStatusText: response.statusText,
|
|
6796
|
-
responseDate,
|
|
6797
|
-
localStorage: _localStorage,
|
|
6798
|
-
sessionStorage: _sessionStorage,
|
|
6799
|
-
cookies: _cookies,
|
|
6800
|
-
},
|
|
6801
|
-
...this.descriptor.apiCalls,
|
|
6802
|
-
];
|
|
6803
|
-
if (response.status !== 200) {
|
|
6804
|
-
this.newErrorsCount++;
|
|
6805
|
-
this.newErrorsCountChanged.next();
|
|
6806
|
-
}
|
|
6807
|
-
this.save();
|
|
6808
|
-
}
|
|
6809
|
-
clearErrors() {
|
|
6810
|
-
this.newErrorsCount = 0;
|
|
6811
|
-
this.newErrorsCountChanged.next();
|
|
6812
|
-
}
|
|
6813
|
-
createObject(keys, mapWithValues, useGetItem) {
|
|
6814
|
-
let newObject = {};
|
|
6815
|
-
keys.forEach((key) => {
|
|
6816
|
-
if (useGetItem) {
|
|
6817
|
-
newObject[key] = mapWithValues.getItem(key);
|
|
6818
|
-
}
|
|
6819
|
-
else {
|
|
6820
|
-
newObject[key] = mapWithValues.get(key);
|
|
6821
|
-
}
|
|
6822
|
-
});
|
|
6823
|
-
return newObject;
|
|
6824
|
-
}
|
|
6825
|
-
sanitizeByTime() {
|
|
6826
|
-
let now = new Date();
|
|
6827
|
-
this.descriptor.apiCalls = this.descriptor.apiCalls.filter((apiCall) => {
|
|
6828
|
-
let hoursBetween;
|
|
6829
|
-
if (typeof apiCall.requestDate === 'string') {
|
|
6830
|
-
hoursBetween = Math.floor(Math.abs(now.getMilliseconds() - new Date(apiCall.requestDate).getMilliseconds()) / 36e5);
|
|
6831
|
-
}
|
|
6832
|
-
else {
|
|
6833
|
-
hoursBetween = Math.floor(Math.abs(now.getMilliseconds() - apiCall.requestDate.getMilliseconds()) / 36e5);
|
|
6834
|
-
}
|
|
6835
|
-
return hoursBetween < this.hoursToSave;
|
|
6836
|
-
});
|
|
6837
|
-
}
|
|
6838
|
-
sanitizeByLength() {
|
|
6839
|
-
if (this.descriptor?.apiCalls && this.descriptor.apiCalls.length > this.maxNumOfSavedCalls) {
|
|
6840
|
-
let length = this.descriptor.apiCalls.length;
|
|
6841
|
-
this.descriptor.apiCalls.splice(this.maxNumOfSavedCalls - 1, length - this.maxNumOfSavedCalls);
|
|
6842
|
-
}
|
|
6843
|
-
}
|
|
6844
|
-
save() {
|
|
6845
|
-
try {
|
|
6846
|
-
localStorage.setItem(this.smartDevToolName, JSON.stringify(this.descriptor));
|
|
6847
|
-
this.descriptorChanged.next();
|
|
6848
|
-
}
|
|
6849
|
-
catch (error) {
|
|
6850
|
-
// localStorage.setItem() throws a "QuotaExceededError" DOMException exception if the new value
|
|
6851
|
-
// couldn't be set. (Setting could fail if, e.g., the user has disabled storage for the site,
|
|
6852
|
-
// or if the quota has been exceeded.)
|
|
6853
|
-
this.sanitizeByLength();
|
|
6854
|
-
this.save();
|
|
6855
|
-
}
|
|
6856
|
-
}
|
|
6857
|
-
clear() {
|
|
6858
|
-
this.descriptor = {
|
|
6859
|
-
apiCalls: [],
|
|
6860
|
-
};
|
|
6861
|
-
this.save();
|
|
6862
|
-
}
|
|
6863
|
-
getPureString() {
|
|
6864
|
-
return localStorage.getItem(this.smartDevToolName);
|
|
6865
|
-
}
|
|
6866
|
-
}
|
|
6867
|
-
SmartDevToolService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolService, deps: [{ token: SmartCookieService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
6868
|
-
SmartDevToolService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolService, providedIn: 'root' });
|
|
6869
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolService, decorators: [{
|
|
6870
|
-
type: Injectable,
|
|
6871
|
-
args: [{
|
|
6872
|
-
providedIn: 'root',
|
|
6873
|
-
}]
|
|
6874
|
-
}], ctorParameters: function () { return [{ type: SmartCookieService }]; } });
|
|
6875
|
-
class SmartDevToolDatePipe extends DatePipe {
|
|
6876
|
-
transform(value, format = 'yyyy.MM.dd. H:mm:ss') {
|
|
6877
|
-
return super.transform(value, format);
|
|
6878
|
-
}
|
|
6879
|
-
}
|
|
6880
|
-
SmartDevToolDatePipe.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolDatePipe, deps: null, target: i0.ɵɵFactoryTarget.Pipe });
|
|
6881
|
-
SmartDevToolDatePipe.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolDatePipe, name: "smartDevToolDatePipe" });
|
|
6882
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolDatePipe, decorators: [{
|
|
6883
|
-
type: Pipe,
|
|
6884
|
-
args: [{
|
|
6885
|
-
name: 'smartDevToolDatePipe',
|
|
6886
|
-
}]
|
|
6887
|
-
}] });
|
|
6888
|
-
|
|
6889
|
-
class SmartDevToolDialogService extends SmartdialogService {
|
|
6890
|
-
constructor(dialog, router, service) {
|
|
6891
|
-
super(dialog, router);
|
|
6892
|
-
this.service = service;
|
|
6893
|
-
this.update = this.service.descriptorChanged;
|
|
6894
|
-
}
|
|
6895
|
-
handleAfterClosed(result) { }
|
|
6896
|
-
openDialog() {
|
|
6897
|
-
const dialogData = {
|
|
6898
|
-
content: {
|
|
6899
|
-
title: '',
|
|
6900
|
-
},
|
|
6901
|
-
size: {},
|
|
6902
|
-
customComponent: SmartDevToolDialogComponent,
|
|
6903
|
-
};
|
|
6904
|
-
this.createDialog(dialogData, SmartDevToolDialogComponent);
|
|
6905
|
-
}
|
|
6906
|
-
getData() {
|
|
6907
|
-
return this.service.descriptor;
|
|
6908
|
-
}
|
|
6909
|
-
getPureString() {
|
|
6910
|
-
return this.service.getPureString();
|
|
6911
|
-
}
|
|
6912
|
-
clear() {
|
|
6913
|
-
this.service.clear();
|
|
6914
|
-
}
|
|
6915
|
-
}
|
|
6916
|
-
SmartDevToolDialogService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolDialogService, deps: [{ token: i1$2.MatDialog }, { token: i2.Router }, { token: SmartDevToolService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
6917
|
-
SmartDevToolDialogService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolDialogService, providedIn: 'root' });
|
|
6918
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolDialogService, decorators: [{
|
|
6919
|
-
type: Injectable,
|
|
6920
|
-
args: [{
|
|
6921
|
-
providedIn: 'root',
|
|
6922
|
-
}]
|
|
6923
|
-
}], ctorParameters: function () { return [{ type: i1$2.MatDialog }, { type: i2.Router }, { type: SmartDevToolService }]; } });
|
|
6924
|
-
|
|
6925
|
-
class SmartDevToolDialogComponent {
|
|
6926
|
-
constructor(service) {
|
|
6927
|
-
this.service = service;
|
|
6928
|
-
this._destroy$ = new Subject();
|
|
6929
|
-
this.descriptor = this.service.getData();
|
|
6930
|
-
this.service.update.pipe(takeUntil(this._destroy$)).subscribe(() => {
|
|
6931
|
-
this.descriptor = this.service.getData();
|
|
6932
|
-
});
|
|
6933
|
-
this.service.service.clearErrors();
|
|
6934
|
-
}
|
|
6935
|
-
ngOnDestroy() {
|
|
6936
|
-
this._destroy$.next();
|
|
6937
|
-
}
|
|
6938
|
-
clear() {
|
|
6939
|
-
this.service.clear();
|
|
6940
|
-
}
|
|
6941
|
-
getBody(inp) {
|
|
6942
|
-
return this.syntaxHighlight(inp);
|
|
6943
|
-
}
|
|
6944
|
-
syntaxHighlight(json) {
|
|
6945
|
-
if (typeof json != 'string') {
|
|
6946
|
-
json = JSON.stringify(json, undefined, 2);
|
|
6947
|
-
}
|
|
6948
|
-
json = json.replace(/&/g, '&').replace(/</g, '<').replace(/>/g, '>');
|
|
6949
|
-
return json.replace(/("(\\u[a-zA-Z0-9]{4}|\\[^u]|[^\\"])*"(\s*:)?|\b(true|false|null)\b|-?\d+(?:\.\d*)?(?:[eE][+\-]?\d+)?)/g, function (match) {
|
|
6950
|
-
var cls = 'number';
|
|
6951
|
-
if (/^"/.test(match)) {
|
|
6952
|
-
if (/:$/.test(match)) {
|
|
6953
|
-
cls = 'key';
|
|
6954
|
-
}
|
|
6955
|
-
else {
|
|
6956
|
-
cls = 'string';
|
|
6957
|
-
}
|
|
6958
|
-
}
|
|
6959
|
-
else if (/true|false/.test(match)) {
|
|
6960
|
-
cls = 'boolean';
|
|
6961
|
-
}
|
|
6962
|
-
else if (/null/.test(match)) {
|
|
6963
|
-
cls = 'null';
|
|
6964
|
-
}
|
|
6965
|
-
return '<span class="' + cls + '">' + match + '</span>';
|
|
6966
|
-
});
|
|
6967
|
-
}
|
|
6968
|
-
copy() {
|
|
6969
|
-
copyToClipboard({
|
|
6970
|
-
value: this.service.getPureString(),
|
|
6971
|
-
});
|
|
6972
|
-
}
|
|
6973
|
-
close() {
|
|
6974
|
-
this.service.closeDialog();
|
|
6975
|
-
}
|
|
6976
|
-
}
|
|
6977
|
-
SmartDevToolDialogComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolDialogComponent, deps: [{ token: SmartDevToolDialogService }], target: i0.ɵɵFactoryTarget.Component });
|
|
6978
|
-
SmartDevToolDialogComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: SmartDevToolDialogComponent, selector: "app-smart-dev-tool-dialog", ngImport: i0, template: "<div class=\"smartDevToolDialogContainer\">\r\n <div class=\"header\">\r\n <h2>Developer tool</h2>\r\n <button mat-icon-button title=\"close\" (click)=\"close()\">\r\n <smart-icon icon=\"close\"></smart-icon>\r\n </button>\r\n </div>\r\n <div class=\"requestsContainer\">\r\n <mat-accordion multi>\r\n <mat-expansion-panel\r\n class=\"requestCard\"\r\n [ngClass]=\"apiCall.responseStatus === 200 ? '' : 'hasError'\"\r\n *ngFor=\"let apiCall of descriptor?.apiCalls; let i = index\"\r\n >\r\n <mat-expansion-panel-header>\r\n <mat-panel-title>\r\n <div class=\"titlePanel\">\r\n <span class=\"date\">\r\n {{ apiCall.responseDate | smartDevToolDatePipe }}\r\n </span>\r\n <span class=\"urlText\">\r\n {{ apiCall.url }}\r\n </span>\r\n <div [ngClass]=\"apiCall.requestMethod\">\r\n {{ apiCall.requestMethod }}\r\n </div>\r\n <div [ngClass]=\"'statusCode-' + apiCall.responseStatus.toString()[0]\">\r\n {{ apiCall.responseStatus }}\r\n </div>\r\n </div>\r\n </mat-panel-title>\r\n </mat-expansion-panel-header>\r\n\r\n <div>\r\n <div class=\"table\">\r\n <div class=\"row\">\r\n <div class=\"mainCol heading\">Request</div>\r\n <div class=\"mainCol heading\">Response</div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Date</div>\r\n <div class=\"data\">\r\n {{ apiCall.requestDate | smartDevToolDatePipe }}\r\n </div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Date</div>\r\n <div class=\"data\">\r\n {{ apiCall.responseDate | smartDevToolDatePipe }}\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Headers</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Headers</div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.requestHeader\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.requestHeader)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.requestHeader\" class=\"data\">null</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.responseHeader\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.responseHeader)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.responseHeader\" class=\"data\">null</div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\"></div>\r\n <div class=\"data\"></div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Status</div>\r\n <div class=\"data\">\r\n {{ apiCall.responseStatus }}\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\"></div>\r\n <div class=\"data\"></div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Status text</div>\r\n <div class=\"data\">\r\n {{ apiCall.responseStatusText }}\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Body</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Body</div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.requestBody\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.requestBody)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.requestBody\" class=\"data\">null</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.responseBody\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.responseBody)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.responseBody\" class=\"data\">null</div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Session Storage</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Local Storage</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Cookies</div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.sessionStorage\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.sessionStorage)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.sessionStorage\" class=\"data\">null</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.localStorage\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.localStorage)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.localStorage\" class=\"data\">null</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.cookies\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.cookies)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.cookies\" class=\"data\">null</div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </mat-expansion-panel>\r\n </mat-accordion>\r\n </div>\r\n <div class=\"buttonsContainer\">\r\n <button color=\"primary\" mat-raised-button (click)=\"copy()\">Copy</button>\r\n <button color=\"warn\" mat-raised-button (click)=\"clear()\">Clear</button>\r\n </div>\r\n</div>\r\n", styles: [".smartDevToolDialogContainer{display:flex;flex-direction:column;gap:1rem;width:78vw;height:90vh}.header{display:flex;flex-direction:row;justify-content:space-between}.requestsContainer{display:flex;flex-direction:column;gap:1rem;flex:1;overflow:auto}.requestCard{background-color:var(--primary-lighter-color);padding:.5rem;border-radius:.5rem;display:flex;flex-direction:column}.table{display:flex;flex-direction:column;gap:.25rem}.row{display:flex;flex-direction:row;gap:1rem}.mainCol{flex:1;display:flex;flex-direction:row;gap:.5rem;overflow:auto}.heading{font-weight:700}.data{word-wrap:break-word}.buttonsContainer{display:flex;flex-direction:row;justify-content:space-between}pre{outline:1px solid #000;padding:5px;margin:5px}.string{color:green}.number{color:#ff8c00}.boolean{color:#00f}.null{color:#f0f}.key{color:red}@media only screen and (max-width: 1000px){.row{flex-direction:column;gap:.5rem}.mainCol{flex-direction:column;overflow-x:auto;overflow-y:visible;flex:auto}.requestCard h4{font-size:small;overflow:auto}.smartDevToolDialogContainer{width:calc(80vw - 3rem)}}.hasError{background-color:var(--warn-lighter-color)}.titlePanel{flex:1;display:flex;flex-direction:row;gap:1rem}.urlText{flex:1;text-decoration:underline}.PATCH{color:#d38042}.DELETE{color:#a41e22}.GET{color:#0f6ab4}.POST{color:#10a54a}.PUT{color:#c5862b}.HEAD{color:#ffd20f}.statusCode-2{color:#5fb442}.statusCode-3{color:#5970f6}.statusCode-4{color:#ec6762}.statusCode-5{color:#f2a63b}\n"], components: [{ type: i3.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: SmartIconComponent, selector: "smart-icon", inputs: ["icon", "color"] }, { type: i4.MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["disabled", "expanded", "hideToggle", "togglePosition"], outputs: ["opened", "closed", "expandedChange", "afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { type: i4.MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["tabIndex", "expandedHeight", "collapsedHeight"] }], directives: [{ type: i4.MatAccordion, selector: "mat-accordion", inputs: ["multi", "hideToggle", "displayMode", "togglePosition"], exportAs: ["matAccordion"] }, { type: i3$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i3$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i4.MatExpansionPanelTitle, selector: "mat-panel-title" }, { type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }], pipes: { "smartDevToolDatePipe": SmartDevToolDatePipe } });
|
|
6979
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolDialogComponent, decorators: [{
|
|
6980
|
-
type: Component,
|
|
6981
|
-
args: [{ selector: 'app-smart-dev-tool-dialog', template: "<div class=\"smartDevToolDialogContainer\">\r\n <div class=\"header\">\r\n <h2>Developer tool</h2>\r\n <button mat-icon-button title=\"close\" (click)=\"close()\">\r\n <smart-icon icon=\"close\"></smart-icon>\r\n </button>\r\n </div>\r\n <div class=\"requestsContainer\">\r\n <mat-accordion multi>\r\n <mat-expansion-panel\r\n class=\"requestCard\"\r\n [ngClass]=\"apiCall.responseStatus === 200 ? '' : 'hasError'\"\r\n *ngFor=\"let apiCall of descriptor?.apiCalls; let i = index\"\r\n >\r\n <mat-expansion-panel-header>\r\n <mat-panel-title>\r\n <div class=\"titlePanel\">\r\n <span class=\"date\">\r\n {{ apiCall.responseDate | smartDevToolDatePipe }}\r\n </span>\r\n <span class=\"urlText\">\r\n {{ apiCall.url }}\r\n </span>\r\n <div [ngClass]=\"apiCall.requestMethod\">\r\n {{ apiCall.requestMethod }}\r\n </div>\r\n <div [ngClass]=\"'statusCode-' + apiCall.responseStatus.toString()[0]\">\r\n {{ apiCall.responseStatus }}\r\n </div>\r\n </div>\r\n </mat-panel-title>\r\n </mat-expansion-panel-header>\r\n\r\n <div>\r\n <div class=\"table\">\r\n <div class=\"row\">\r\n <div class=\"mainCol heading\">Request</div>\r\n <div class=\"mainCol heading\">Response</div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Date</div>\r\n <div class=\"data\">\r\n {{ apiCall.requestDate | smartDevToolDatePipe }}\r\n </div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Date</div>\r\n <div class=\"data\">\r\n {{ apiCall.responseDate | smartDevToolDatePipe }}\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Headers</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Headers</div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.requestHeader\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.requestHeader)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.requestHeader\" class=\"data\">null</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.responseHeader\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.responseHeader)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.responseHeader\" class=\"data\">null</div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\"></div>\r\n <div class=\"data\"></div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Status</div>\r\n <div class=\"data\">\r\n {{ apiCall.responseStatus }}\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\"></div>\r\n <div class=\"data\"></div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Status text</div>\r\n <div class=\"data\">\r\n {{ apiCall.responseStatusText }}\r\n </div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Body</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Body</div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.requestBody\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.requestBody)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.requestBody\" class=\"data\">null</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.responseBody\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.responseBody)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.responseBody\" class=\"data\">null</div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Session Storage</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Local Storage</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <div class=\"heading\">Cookies</div>\r\n </div>\r\n </div>\r\n <div class=\"row\">\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.sessionStorage\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.sessionStorage)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.sessionStorage\" class=\"data\">null</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.localStorage\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.localStorage)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.localStorage\" class=\"data\">null</div>\r\n </div>\r\n <div class=\"mainCol\">\r\n <pre\r\n *ngIf=\"apiCall.cookies\"\r\n class=\"data\"\r\n [innerHTML]=\"getBody(apiCall.cookies)\"\r\n ></pre>\r\n <div *ngIf=\"!apiCall.cookies\" class=\"data\">null</div>\r\n </div>\r\n </div>\r\n </div>\r\n </div>\r\n </mat-expansion-panel>\r\n </mat-accordion>\r\n </div>\r\n <div class=\"buttonsContainer\">\r\n <button color=\"primary\" mat-raised-button (click)=\"copy()\">Copy</button>\r\n <button color=\"warn\" mat-raised-button (click)=\"clear()\">Clear</button>\r\n </div>\r\n</div>\r\n", styles: [".smartDevToolDialogContainer{display:flex;flex-direction:column;gap:1rem;width:78vw;height:90vh}.header{display:flex;flex-direction:row;justify-content:space-between}.requestsContainer{display:flex;flex-direction:column;gap:1rem;flex:1;overflow:auto}.requestCard{background-color:var(--primary-lighter-color);padding:.5rem;border-radius:.5rem;display:flex;flex-direction:column}.table{display:flex;flex-direction:column;gap:.25rem}.row{display:flex;flex-direction:row;gap:1rem}.mainCol{flex:1;display:flex;flex-direction:row;gap:.5rem;overflow:auto}.heading{font-weight:700}.data{word-wrap:break-word}.buttonsContainer{display:flex;flex-direction:row;justify-content:space-between}pre{outline:1px solid #000;padding:5px;margin:5px}.string{color:green}.number{color:#ff8c00}.boolean{color:#00f}.null{color:#f0f}.key{color:red}@media only screen and (max-width: 1000px){.row{flex-direction:column;gap:.5rem}.mainCol{flex-direction:column;overflow-x:auto;overflow-y:visible;flex:auto}.requestCard h4{font-size:small;overflow:auto}.smartDevToolDialogContainer{width:calc(80vw - 3rem)}}.hasError{background-color:var(--warn-lighter-color)}.titlePanel{flex:1;display:flex;flex-direction:row;gap:1rem}.urlText{flex:1;text-decoration:underline}.PATCH{color:#d38042}.DELETE{color:#a41e22}.GET{color:#0f6ab4}.POST{color:#10a54a}.PUT{color:#c5862b}.HEAD{color:#ffd20f}.statusCode-2{color:#5fb442}.statusCode-3{color:#5970f6}.statusCode-4{color:#ec6762}.statusCode-5{color:#f2a63b}\n"] }]
|
|
6982
|
-
}], ctorParameters: function () { return [{ type: SmartDevToolDialogService }]; } });
|
|
6983
|
-
const copyToClipboard = async ({ target, message, value }) => {
|
|
6984
|
-
try {
|
|
6985
|
-
let copyValue = '';
|
|
6986
|
-
if (!navigator.clipboard) {
|
|
6987
|
-
throw new Error("Browser don't have support for native clipboard.");
|
|
6988
|
-
}
|
|
6989
|
-
if (target) {
|
|
6990
|
-
const node = document.querySelector(target);
|
|
6991
|
-
if (!node || !node.textContent) {
|
|
6992
|
-
throw new Error('Element not found');
|
|
6993
|
-
}
|
|
6994
|
-
value = node.textContent;
|
|
6995
|
-
}
|
|
6996
|
-
if (value) {
|
|
6997
|
-
copyValue = value;
|
|
6998
|
-
}
|
|
6999
|
-
await navigator.clipboard.writeText(copyValue);
|
|
7000
|
-
}
|
|
7001
|
-
catch (error) {
|
|
7002
|
-
console.error(error.toString());
|
|
7003
|
-
}
|
|
7004
|
-
};
|
|
7005
|
-
|
|
7006
|
-
class SmartDevToolFloatingButtonComponent {
|
|
7007
|
-
constructor(service) {
|
|
7008
|
-
this.service = service;
|
|
7009
|
-
this._destroy$ = new Subject();
|
|
7010
|
-
this.adminKeyName = 'useDevTool';
|
|
7011
|
-
this.isShown = false;
|
|
7012
|
-
this.errorsCount = '';
|
|
7013
|
-
this.service.service.newErrorsCountChanged.pipe(takeUntil(this._destroy$)).subscribe(() => {
|
|
7014
|
-
this.errorsCount = `${this.service.service.newErrorsCount > 0 ? this.service.service.newErrorsCount : ''}`;
|
|
7015
|
-
});
|
|
7016
|
-
window.addEventListener('storage', (event) => {
|
|
7017
|
-
if (event.storageArea === localStorage) {
|
|
7018
|
-
if (Object.keys(localStorage).includes(this.adminKeyName)) {
|
|
7019
|
-
this.isShown = localStorage.getItem(this.adminKeyName) === 'true';
|
|
7020
|
-
}
|
|
7021
|
-
}
|
|
7022
|
-
});
|
|
7023
|
-
this.isShown = localStorage.getItem(this.adminKeyName) === 'true';
|
|
7024
|
-
}
|
|
7025
|
-
ngOnDestroy() {
|
|
7026
|
-
this._destroy$.next();
|
|
7027
|
-
}
|
|
7028
|
-
openDevToolDialog() {
|
|
7029
|
-
this.service.openDialog();
|
|
7030
|
-
}
|
|
7031
|
-
}
|
|
7032
|
-
SmartDevToolFloatingButtonComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolFloatingButtonComponent, deps: [{ token: SmartDevToolDialogService }], target: i0.ɵɵFactoryTarget.Component });
|
|
7033
|
-
SmartDevToolFloatingButtonComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: SmartDevToolFloatingButtonComponent, selector: "smart-session-dev-tool", ngImport: i0, template: "<button\r\n *ngIf=\"isShown\"\r\n mat-fab\r\n [color]=\"errorsCount.length ? 'warn' : 'accent'\"\r\n class=\"floatingButton\"\r\n extended\r\n title=\"devTool\"\r\n (click)=\"openDevToolDialog()\"\r\n>\r\n <smart-icon color=\"white\" icon=\"developer_mode\"></smart-icon>\r\n {{ errorsCount }}\r\n</button>\r\n", styles: [".floatingButton{position:fixed;right:2rem;bottom:2rem}.mat-icon.mat-white{color:#fff}\n"], components: [{ type: i3.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: SmartIconComponent, selector: "smart-icon", inputs: ["icon", "color"] }], directives: [{ type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
|
|
7034
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolFloatingButtonComponent, decorators: [{
|
|
7035
|
-
type: Component,
|
|
7036
|
-
args: [{ selector: 'smart-session-dev-tool', template: "<button\r\n *ngIf=\"isShown\"\r\n mat-fab\r\n [color]=\"errorsCount.length ? 'warn' : 'accent'\"\r\n class=\"floatingButton\"\r\n extended\r\n title=\"devTool\"\r\n (click)=\"openDevToolDialog()\"\r\n>\r\n <smart-icon color=\"white\" icon=\"developer_mode\"></smart-icon>\r\n {{ errorsCount }}\r\n</button>\r\n", styles: [".floatingButton{position:fixed;right:2rem;bottom:2rem}.mat-icon.mat-white{color:#fff}\n"] }]
|
|
7037
|
-
}], ctorParameters: function () { return [{ type: SmartDevToolDialogService }]; } });
|
|
7038
|
-
|
|
7039
|
-
class SmartDevToolInterceptor {
|
|
7040
|
-
constructor(service) {
|
|
7041
|
-
this.service = service;
|
|
7042
|
-
}
|
|
7043
|
-
intercept(request, next) {
|
|
7044
|
-
if (!this.service.isActive) {
|
|
7045
|
-
return next.handle(request);
|
|
7046
|
-
}
|
|
7047
|
-
let requestDate = new Date();
|
|
7048
|
-
return next.handle(request).pipe(map((event) => {
|
|
7049
|
-
if (event.type === HttpEventType.Response) {
|
|
7050
|
-
let responseDate = new Date();
|
|
7051
|
-
this.service.writeResponse(request, event, requestDate, responseDate);
|
|
7052
|
-
}
|
|
7053
|
-
return event;
|
|
7054
|
-
}));
|
|
7055
|
-
}
|
|
7056
|
-
}
|
|
7057
|
-
SmartDevToolInterceptor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolInterceptor, deps: [{ token: SmartDevToolService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
7058
|
-
SmartDevToolInterceptor.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolInterceptor });
|
|
7059
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolInterceptor, decorators: [{
|
|
7060
|
-
type: Injectable
|
|
7061
|
-
}], ctorParameters: function () { return [{ type: SmartDevToolService }]; } });
|
|
7062
|
-
class SmartDevToolErrorInterceptor {
|
|
7063
|
-
constructor(service) {
|
|
7064
|
-
this.service = service;
|
|
7065
|
-
}
|
|
7066
|
-
intercept(request, next) {
|
|
7067
|
-
if (!this.service.isActive) {
|
|
7068
|
-
return next.handle(request);
|
|
7069
|
-
}
|
|
7070
|
-
let requestDate = new Date();
|
|
7071
|
-
return next.handle(request).pipe(catchError((error) => {
|
|
7072
|
-
if (error.status !== 200) {
|
|
7073
|
-
let responseDate = new Date();
|
|
7074
|
-
this.service.writeResponse(request, error, requestDate, responseDate);
|
|
7075
|
-
}
|
|
7076
|
-
return throwError(error);
|
|
7077
|
-
}));
|
|
7078
|
-
}
|
|
7079
|
-
}
|
|
7080
|
-
SmartDevToolErrorInterceptor.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolErrorInterceptor, deps: [{ token: SmartDevToolService }], target: i0.ɵɵFactoryTarget.Injectable });
|
|
7081
|
-
SmartDevToolErrorInterceptor.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolErrorInterceptor });
|
|
7082
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartDevToolErrorInterceptor, decorators: [{
|
|
7083
|
-
type: Injectable
|
|
7084
|
-
}], ctorParameters: function () { return [{ type: SmartDevToolService }]; } });
|
|
7085
|
-
|
|
7086
6726
|
var SessionErrorBehaviour;
|
|
7087
6727
|
(function (SessionErrorBehaviour) {
|
|
7088
6728
|
SessionErrorBehaviour[SessionErrorBehaviour["REFRESH"] = 0] = "REFRESH";
|
|
@@ -7204,7 +6844,7 @@ class SmartErrorCatchingInterceptor {
|
|
|
7204
6844
|
];
|
|
7205
6845
|
}
|
|
7206
6846
|
intercept(request, next) {
|
|
7207
|
-
return next.handle(request).pipe(catchError
|
|
6847
|
+
return next.handle(request).pipe(catchError((error) => {
|
|
7208
6848
|
if (error.status === 400 && error.error.code) {
|
|
7209
6849
|
let sessionError = this.sessionErrorCodes.find((sessionError) => sessionError.code === error.error.code);
|
|
7210
6850
|
if (sessionError) {
|
|
@@ -7280,10 +6920,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImpor
|
|
|
7280
6920
|
class SmartSessionModule {
|
|
7281
6921
|
}
|
|
7282
6922
|
SmartSessionModule.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartSessionModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
7283
|
-
SmartSessionModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartSessionModule, declarations: [
|
|
7284
|
-
SmartDevToolFloatingButtonComponent,
|
|
7285
|
-
SmartDevToolDatePipe,
|
|
7286
|
-
SmartSessionTimerComponent], imports: [BrowserModule, MatCommonModule, MatExpansionModule, MatButtonModule, SmartIconModule], exports: [SmartDevToolFloatingButtonComponent, SmartSessionTimerComponent] });
|
|
6923
|
+
SmartSessionModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartSessionModule, declarations: [SmartSessionTimerComponent], imports: [BrowserModule, MatCommonModule, MatExpansionModule, MatButtonModule, SmartIconModule], exports: [SmartSessionTimerComponent] });
|
|
7287
6924
|
SmartSessionModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartSessionModule, providers: [
|
|
7288
6925
|
SmartCookieService,
|
|
7289
6926
|
SmartSessionService,
|
|
@@ -7298,20 +6935,13 @@ SmartSessionModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", vers
|
|
|
7298
6935
|
useClass: SmartHeaderMaintainerInterceptor,
|
|
7299
6936
|
multi: true,
|
|
7300
6937
|
},
|
|
7301
|
-
{ provide: HTTP_INTERCEPTORS, useClass: SmartDevToolInterceptor, multi: true },
|
|
7302
|
-
{ provide: HTTP_INTERCEPTORS, useClass: SmartDevToolErrorInterceptor, multi: true },
|
|
7303
6938
|
], imports: [[BrowserModule, MatCommonModule, MatExpansionModule, MatButtonModule, SmartIconModule]] });
|
|
7304
6939
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: SmartSessionModule, decorators: [{
|
|
7305
6940
|
type: NgModule,
|
|
7306
6941
|
args: [{
|
|
7307
|
-
declarations: [
|
|
7308
|
-
SmartDevToolDialogComponent,
|
|
7309
|
-
SmartDevToolFloatingButtonComponent,
|
|
7310
|
-
SmartDevToolDatePipe,
|
|
7311
|
-
SmartSessionTimerComponent,
|
|
7312
|
-
],
|
|
6942
|
+
declarations: [SmartSessionTimerComponent],
|
|
7313
6943
|
imports: [BrowserModule, MatCommonModule, MatExpansionModule, MatButtonModule, SmartIconModule],
|
|
7314
|
-
exports: [
|
|
6944
|
+
exports: [SmartSessionTimerComponent],
|
|
7315
6945
|
schemas: [CUSTOM_ELEMENTS_SCHEMA],
|
|
7316
6946
|
providers: [
|
|
7317
6947
|
SmartCookieService,
|
|
@@ -7327,8 +6957,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImpor
|
|
|
7327
6957
|
useClass: SmartHeaderMaintainerInterceptor,
|
|
7328
6958
|
multi: true,
|
|
7329
6959
|
},
|
|
7330
|
-
{ provide: HTTP_INTERCEPTORS, useClass: SmartDevToolInterceptor, multi: true },
|
|
7331
|
-
{ provide: HTTP_INTERCEPTORS, useClass: SmartDevToolErrorInterceptor, multi: true },
|
|
7332
6960
|
],
|
|
7333
6961
|
}]
|
|
7334
6962
|
}] });
|
|
@@ -7433,7 +7061,7 @@ class SmartViewContextInterceptor {
|
|
|
7433
7061
|
}
|
|
7434
7062
|
catch (error) { }
|
|
7435
7063
|
}
|
|
7436
|
-
return next.handle(request).pipe(catchError((error) => {
|
|
7064
|
+
return next.handle(request).pipe(catchError$1((error) => {
|
|
7437
7065
|
if (error.status === 409 &&
|
|
7438
7066
|
(error.error.code || error.error.message)) {
|
|
7439
7067
|
this.openErrorDialog(error.error);
|
|
@@ -9772,7 +9400,7 @@ class ExpandableSectionComponent {
|
|
|
9772
9400
|
}
|
|
9773
9401
|
}
|
|
9774
9402
|
ExpandableSectionComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: ExpandableSectionComponent, deps: [{ token: ComponentFactoryService }], target: i0.ɵɵFactoryTarget.Component });
|
|
9775
|
-
ExpandableSectionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: ExpandableSectionComponent, selector: "smart-expandable-section", inputs: { data: "data", index: "index" }, viewQueries: [{ propertyName: "vcRef", first: true, predicate: ["renderComponent"], descendants: true, read: ViewContainerRef }, { propertyName: "vcRefheader", first: true, predicate: ["headerComponent"], descendants: true, read: ViewContainerRef }], ngImport: i0, template: "<div class=\"section-container\" [ngClass]=\"data.cssClass ?? ''\">\r\n <mat-expansion-panel\r\n [expanded]=\"data.isExpanded\"\r\n (opened)=\"onStateChange(true)\"\r\n (closed)=\"onStateChange(false)\"\r\n >\r\n <mat-expansion-panel-header *ngIf=\"data.headerComponent\">\r\n <ng-template #headerComponent></ng-template>\r\n </mat-expansion-panel-header>\r\n <mat-expansion-panel-header *ngIf=\"!data.headerComponent\">\r\n <mat-panel-title> {{ data.title }} </mat-panel-title>\r\n <div class=\"btn-container\" *ngIf=\"data.button\">\r\n <button\r\n *ngIf=\"data.button.type === type().BUTTON\"\r\n class=\"btn\"\r\n (click)=\"action(data.button, $event)\"\r\n mat-stroked-button\r\n >\r\n <smart-icon\r\n *ngIf=\"\r\n data.button.icon &&\r\n (!data.button.iconPosition ||\r\n data.button.iconPosition === position().PRE)\r\n \"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon>\r\n {{ data.button.label }}\r\n <smart-icon\r\n *ngIf=\"data.button.icon && data.button.iconPosition === position().POST\"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon>\r\n </button>\r\n <button\r\n *ngIf=\"data.button.type === type().MENU\"\r\n mat-button\r\n [matMenuTriggerFor]=\"menu\"\r\n (click)=\"$event.stopPropagation()\"\r\n color=\"{{ data.button.color }}\"\r\n >\r\n <smart-icon\r\n *ngIf=\"\r\n data.button.icon &&\r\n (!data.button.iconPosition ||\r\n data.button.iconPosition === position().PRE)\r\n \"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon\r\n >{{ data.button.label }}\r\n <smart-icon\r\n *ngIf=\"data.button.icon && data.button.iconPosition === position().POST\"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon>\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <button\r\n *ngFor=\"let button of data.button.menuItemButtons\"\r\n (click)=\"customButtonClicked($event, button, data.index)\"\r\n mat-menu-item\r\n >\r\n <smart-icon\r\n *ngIf=\"\r\n button.icon &&\r\n (!button.iconPosition || button.iconPosition === position().PRE)\r\n \"\r\n [icon]=\"button.icon\"\r\n ></smart-icon\r\n >{{ button.label }}\r\n <smart-icon\r\n *ngIf=\"button.icon && button.iconPosition === position().POST\"\r\n [icon]=\"button.icon\"\r\n ></smart-icon>\r\n </button>\r\n </mat-menu>\r\n </div>\r\n </mat-expansion-panel-header>\r\n <ng-template #renderComponent></ng-template>\r\n </mat-expansion-panel>\r\n</div>\r\n", styles: [".section-container{margin-bottom:50px}:host::ng-deep .mat-expansion-panel-header{background:var(--primary-lighter-color)}:host::ng-deep .mat-expansion-panel-header-title{color:var(--primary-color)}:host::ng-deep .btn-container{margin:1em 3em 1em 1em}:host::ng-deep .btn{border-radius:24px}\n"], components: [{ type:
|
|
9403
|
+
ExpandableSectionComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "13.4.0", type: ExpandableSectionComponent, selector: "smart-expandable-section", inputs: { data: "data", index: "index" }, viewQueries: [{ propertyName: "vcRef", first: true, predicate: ["renderComponent"], descendants: true, read: ViewContainerRef }, { propertyName: "vcRefheader", first: true, predicate: ["headerComponent"], descendants: true, read: ViewContainerRef }], ngImport: i0, template: "<div class=\"section-container\" [ngClass]=\"data.cssClass ?? ''\">\r\n <mat-expansion-panel\r\n [expanded]=\"data.isExpanded\"\r\n (opened)=\"onStateChange(true)\"\r\n (closed)=\"onStateChange(false)\"\r\n >\r\n <mat-expansion-panel-header *ngIf=\"data.headerComponent\">\r\n <ng-template #headerComponent></ng-template>\r\n </mat-expansion-panel-header>\r\n <mat-expansion-panel-header *ngIf=\"!data.headerComponent\">\r\n <mat-panel-title> {{ data.title }} </mat-panel-title>\r\n <div class=\"btn-container\" *ngIf=\"data.button\">\r\n <button\r\n *ngIf=\"data.button.type === type().BUTTON\"\r\n class=\"btn\"\r\n (click)=\"action(data.button, $event)\"\r\n mat-stroked-button\r\n >\r\n <smart-icon\r\n *ngIf=\"\r\n data.button.icon &&\r\n (!data.button.iconPosition ||\r\n data.button.iconPosition === position().PRE)\r\n \"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon>\r\n {{ data.button.label }}\r\n <smart-icon\r\n *ngIf=\"data.button.icon && data.button.iconPosition === position().POST\"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon>\r\n </button>\r\n <button\r\n *ngIf=\"data.button.type === type().MENU\"\r\n mat-button\r\n [matMenuTriggerFor]=\"menu\"\r\n (click)=\"$event.stopPropagation()\"\r\n color=\"{{ data.button.color }}\"\r\n >\r\n <smart-icon\r\n *ngIf=\"\r\n data.button.icon &&\r\n (!data.button.iconPosition ||\r\n data.button.iconPosition === position().PRE)\r\n \"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon\r\n >{{ data.button.label }}\r\n <smart-icon\r\n *ngIf=\"data.button.icon && data.button.iconPosition === position().POST\"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon>\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <button\r\n *ngFor=\"let button of data.button.menuItemButtons\"\r\n (click)=\"customButtonClicked($event, button, data.index)\"\r\n mat-menu-item\r\n >\r\n <smart-icon\r\n *ngIf=\"\r\n button.icon &&\r\n (!button.iconPosition || button.iconPosition === position().PRE)\r\n \"\r\n [icon]=\"button.icon\"\r\n ></smart-icon\r\n >{{ button.label }}\r\n <smart-icon\r\n *ngIf=\"button.icon && button.iconPosition === position().POST\"\r\n [icon]=\"button.icon\"\r\n ></smart-icon>\r\n </button>\r\n </mat-menu>\r\n </div>\r\n </mat-expansion-panel-header>\r\n <ng-template #renderComponent></ng-template>\r\n </mat-expansion-panel>\r\n</div>\r\n", styles: [".section-container{margin-bottom:50px}:host::ng-deep .mat-expansion-panel-header{background:var(--primary-lighter-color)}:host::ng-deep .mat-expansion-panel-header-title{color:var(--primary-color)}:host::ng-deep .btn-container{margin:1em 3em 1em 1em}:host::ng-deep .btn{border-radius:24px}\n"], components: [{ type: i2$6.MatExpansionPanel, selector: "mat-expansion-panel", inputs: ["disabled", "expanded", "hideToggle", "togglePosition"], outputs: ["opened", "closed", "expandedChange", "afterExpand", "afterCollapse"], exportAs: ["matExpansionPanel"] }, { type: i2$6.MatExpansionPanelHeader, selector: "mat-expansion-panel-header", inputs: ["tabIndex", "expandedHeight", "collapsedHeight"] }, { type: i3.MatButton, selector: "button[mat-button], button[mat-raised-button], button[mat-icon-button], button[mat-fab], button[mat-mini-fab], button[mat-stroked-button], button[mat-flat-button]", inputs: ["disabled", "disableRipple", "color"], exportAs: ["matButton"] }, { type: SmartIconComponent, selector: "smart-icon", inputs: ["icon", "color"] }, { type: i5.MatMenu, selector: "mat-menu", exportAs: ["matMenu"] }, { type: i5.MatMenuItem, selector: "[mat-menu-item]", inputs: ["disabled", "disableRipple", "role"], exportAs: ["matMenuItem"] }], directives: [{ type: i3$1.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i3$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$6.MatExpansionPanelTitle, selector: "mat-panel-title" }, { type: i5.MatMenuTrigger, selector: "[mat-menu-trigger-for], [matMenuTriggerFor]", exportAs: ["matMenuTrigger"] }, { type: i3$1.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
|
|
9776
9404
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImport: i0, type: ExpandableSectionComponent, decorators: [{
|
|
9777
9405
|
type: Component,
|
|
9778
9406
|
args: [{ selector: 'smart-expandable-section', template: "<div class=\"section-container\" [ngClass]=\"data.cssClass ?? ''\">\r\n <mat-expansion-panel\r\n [expanded]=\"data.isExpanded\"\r\n (opened)=\"onStateChange(true)\"\r\n (closed)=\"onStateChange(false)\"\r\n >\r\n <mat-expansion-panel-header *ngIf=\"data.headerComponent\">\r\n <ng-template #headerComponent></ng-template>\r\n </mat-expansion-panel-header>\r\n <mat-expansion-panel-header *ngIf=\"!data.headerComponent\">\r\n <mat-panel-title> {{ data.title }} </mat-panel-title>\r\n <div class=\"btn-container\" *ngIf=\"data.button\">\r\n <button\r\n *ngIf=\"data.button.type === type().BUTTON\"\r\n class=\"btn\"\r\n (click)=\"action(data.button, $event)\"\r\n mat-stroked-button\r\n >\r\n <smart-icon\r\n *ngIf=\"\r\n data.button.icon &&\r\n (!data.button.iconPosition ||\r\n data.button.iconPosition === position().PRE)\r\n \"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon>\r\n {{ data.button.label }}\r\n <smart-icon\r\n *ngIf=\"data.button.icon && data.button.iconPosition === position().POST\"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon>\r\n </button>\r\n <button\r\n *ngIf=\"data.button.type === type().MENU\"\r\n mat-button\r\n [matMenuTriggerFor]=\"menu\"\r\n (click)=\"$event.stopPropagation()\"\r\n color=\"{{ data.button.color }}\"\r\n >\r\n <smart-icon\r\n *ngIf=\"\r\n data.button.icon &&\r\n (!data.button.iconPosition ||\r\n data.button.iconPosition === position().PRE)\r\n \"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon\r\n >{{ data.button.label }}\r\n <smart-icon\r\n *ngIf=\"data.button.icon && data.button.iconPosition === position().POST\"\r\n [icon]=\"data.button.icon\"\r\n ></smart-icon>\r\n </button>\r\n <mat-menu #menu=\"matMenu\">\r\n <button\r\n *ngFor=\"let button of data.button.menuItemButtons\"\r\n (click)=\"customButtonClicked($event, button, data.index)\"\r\n mat-menu-item\r\n >\r\n <smart-icon\r\n *ngIf=\"\r\n button.icon &&\r\n (!button.iconPosition || button.iconPosition === position().PRE)\r\n \"\r\n [icon]=\"button.icon\"\r\n ></smart-icon\r\n >{{ button.label }}\r\n <smart-icon\r\n *ngIf=\"button.icon && button.iconPosition === position().POST\"\r\n [icon]=\"button.icon\"\r\n ></smart-icon>\r\n </button>\r\n </mat-menu>\r\n </div>\r\n </mat-expansion-panel-header>\r\n <ng-template #renderComponent></ng-template>\r\n </mat-expansion-panel>\r\n</div>\r\n", styles: [".section-container{margin-bottom:50px}:host::ng-deep .mat-expansion-panel-header{background:var(--primary-lighter-color)}:host::ng-deep .mat-expansion-panel-header-title{color:var(--primary-color)}:host::ng-deep .btn-container{margin:1em 3em 1em 1em}:host::ng-deep .btn{border-radius:24px}\n"] }]
|
|
@@ -13056,5 +12684,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "13.4.0", ngImpor
|
|
|
13056
12684
|
* Generated bundle index. Do not edit.
|
|
13057
12685
|
*/
|
|
13058
12686
|
|
|
13059
|
-
export { APIS$3 as APIS, ApiModule$3 as ApiModule, ApiQueueService, BASE_PATH$4 as BASE_PATH, COLLECTION_FORMATS$4 as COLLECTION_FORMATS, CloseResult, ComponentFactoryService, ComponentFactoryServiceModule, ComponentType, ComponentWidgetType, Configuration$4 as Configuration, DIALOG_DISABLE_CLOSE, DataChangeKind, DefaultUiActionCode_CLOSE, ExpandableSectionButtonIconPosition, ExpandableSectionButtonType, ExpandableSectionComponent, FilterExpressionBoolOperator, FilterExpressionBuilderGroup, FilterExpressionDataType, FilterExpressionFieldWidgetType, FilterExpressionOperation, FilterExpressionOrderBy, GridColumnContentType, GridDataAccessConfig, GridSelectionMode, GridSelectionType, GridUiActionType, GridViewDescriptor, IS_ASYNC_PARAM_NAME, ImageResource, LayoutDirection, Link, MessageOptionType, MessageType, SelectionDefinition, SessionAPIS, SessionErrorBehaviour, SessionService, SimplifiedTabGroupComponent, SmartActionType, SmartAuthService, SmartComponent, SmartComponentApiClient, SmartComponentLayoutComponent, SmartComponentLayoutModule, SmartComponentLayoutUtility, SmartDatePipe, SmartDateTimePipe,
|
|
12687
|
+
export { APIS$3 as APIS, ApiModule$3 as ApiModule, ApiQueueService, BASE_PATH$4 as BASE_PATH, COLLECTION_FORMATS$4 as COLLECTION_FORMATS, CloseResult, ComponentFactoryService, ComponentFactoryServiceModule, ComponentType, ComponentWidgetType, Configuration$4 as Configuration, DIALOG_DISABLE_CLOSE, DataChangeKind, DefaultUiActionCode_CLOSE, ExpandableSectionButtonIconPosition, ExpandableSectionButtonType, ExpandableSectionComponent, FilterExpressionBoolOperator, FilterExpressionBuilderGroup, FilterExpressionDataType, FilterExpressionFieldWidgetType, FilterExpressionOperation, FilterExpressionOrderBy, GridColumnContentType, GridDataAccessConfig, GridSelectionMode, GridSelectionType, GridUiActionType, GridViewDescriptor, IS_ASYNC_PARAM_NAME, ImageResource, LayoutDirection, Link, MessageOptionType, MessageType, SelectionDefinition, SessionAPIS, SessionErrorBehaviour, SessionService, SimplifiedTabGroupComponent, SmartActionType, SmartAuthService, SmartComponent, SmartComponentApiClient, SmartComponentLayoutComponent, SmartComponentLayoutModule, SmartComponentLayoutUtility, SmartDatePipe, SmartDateTimePipe, SmartDialog, SmartExpandableSectionModule, SmartExpandableSectionService, SmartFileUploaderComponent, SmartFilterComponent, SmartFilterModule, SmartFilterPosition, SmartFilterType, SmartFormTextFieldButtonIconPosition, SmartFormWidgetDirection, SmartFormWidgetType, SmartFormWidgetWidth, SmartGridButtonType, SmartGridComponent, SmartGridDataLayout, SmartGridModule, SmartGridService, SmartGridType, SmartIconComponent, SmartIconModule, SmartIconService, SmartLayoutDef, SmartLinkChannelVariableInPath, SmartLinkUuidVariableInPath, SmartNavbarComponent, SmartNavbarModule, SmartNavbarService, SmartNavigationModule, SmartNavigationService, SmartNgClientModule, SmartNgClientService, SmartService, SmartSessionModule, SmartSessionService, SmartSessionTimerComponent, SmartSessionTimerService, SmartSubject, SmartTabGroupModule, SmartTabGroupService, SmartTable, SmartTableButtonType, SmartTableHeaderPropertyType, SmartTableInterfaceTypeEnum, SmartTableOptionButtonDirection, SmartTableOrder, SmartTableType, SmartTimePipe, SmartTreeComponent, SmartTreeNodeButtonType, SmartUserSettinsIconPosition, SmartValidatorName, SmartViewContextErrorDialogButtonLabel, SmartViewContextErrorDialogMessage, SmartViewContextErrorDialogTitle, SmartViewContextModule, SmartViewContextService, SmartViewRedirect, SmartWidgetHintPosition, SmartWidgetSettings, SmartdialogModule, SmartdialogService, SmartfileuploaderComponent, SmartformComponent, SmartformLayoutDefinitionService, SmartformModule, SmartformwidgetComponent, SmarttableComponent, SmarttableModule, SmarttableService, SmarttreeGenericService, SmarttreeModule, SmarttreeService, TabGroupComponent, ToggleLabelPosition, UiActionButtonIconPos, UiActionButtonType, UiActionConfirmDialogComponent, UiActionConfirmDialogService, UiActionDescriptorService, UiActionDialogType, UiActionFeedbackType, UiActionInputDialogComponent, UiActionInputDialogService, UiActionInputType, UiActionService, UiActionToolbarComponent, ViewEventHandler, ViewService, ViewState, ViewType, WidgetMap };
|
|
13060
12688
|
//# sourceMappingURL=smartbit4all-ng-client.mjs.map
|