ngx-scandoc 1.3.2 → 1.3.3

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.
@@ -2835,8 +2835,10 @@ class ScanComponent extends BaseComponent {
2835
2835
  // console.log('MODEL', this.model);
2836
2836
  this.actions.emit({
2837
2837
  type: 'scanFinish',
2838
- model,
2839
- results,
2838
+ data: {
2839
+ model: this.model,
2840
+ images: this.images,
2841
+ },
2840
2842
  });
2841
2843
  this.zone.run(() => {
2842
2844
  this.result = true;
@@ -3793,10 +3795,11 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImpor
3793
3795
  }], ctorParameters: function () { return [{ type: i1$3.MatDialog }]; } });
3794
3796
 
3795
3797
  class ScanProfileComponent extends BaseComponent {
3796
- constructor(dialogs, cameraProvider, dialogRef, platform) {
3798
+ constructor(dialogs, cameraProvider, scanProvider, dialogRef, platform) {
3797
3799
  super();
3798
3800
  this.dialogs = dialogs;
3799
3801
  this.cameraProvider = cameraProvider;
3802
+ this.scanProvider = scanProvider;
3800
3803
  this.dialogRef = dialogRef;
3801
3804
  this.platform = platform;
3802
3805
  this.type = 'desktop';
@@ -3822,6 +3825,11 @@ class ScanProfileComponent extends BaseComponent {
3822
3825
  }
3823
3826
  actions(event) {
3824
3827
  switch (event.type) {
3828
+ case 'scanFinish':
3829
+ if (this.scanProvider.config.hideResults) {
3830
+ this.dialogRef?.close(event.data);
3831
+ }
3832
+ break;
3825
3833
  case 'manualMode':
3826
3834
  this.dialogRef?.close({ manual: true });
3827
3835
  break;
@@ -3839,12 +3847,12 @@ class ScanProfileComponent extends BaseComponent {
3839
3847
  this.dialogRef?.close();
3840
3848
  }
3841
3849
  }
3842
- ScanProfileComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScanProfileComponent, deps: [{ token: DialogsCoreProvider }, { token: NgxScandocCameraProvider }, { token: i1$3.MatDialogRef }, { token: i2.Platform }], target: i0.ɵɵFactoryTarget.Component });
3850
+ ScanProfileComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScanProfileComponent, deps: [{ token: DialogsCoreProvider }, { token: NgxScandocCameraProvider }, { token: ScanProvider }, { token: i1$3.MatDialogRef }, { token: i2.Platform }], target: i0.ɵɵFactoryTarget.Component });
3843
3851
  ScanProfileComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.3.0", type: ScanProfileComponent, selector: "app-scan-profile", inputs: { type: "type" }, host: { listeners: { "touchmove": "handleTouchMove($event)" } }, usesInheritance: true, ngImport: i0, template: "<header class=\"page-header\">\n <div class=\"title\" >\n {{ \"scandoc.title\" | translate }}\n </div>\n\n <span style=\"flex: 1\"></span>\n\n <ng-container *ngIf=\"cameraProvider.$showSwitch| async\">\n <div class=\"separator\"></div>\n <div style=\"padding: 0px 16px\">\n <ngx-scan-camera-switch></ngx-scan-camera-switch>\n </div>\n </ng-container>\n\n <ng-container *ngIf=\"type === 'desktop'\">\n <div class=\"separator\"></div>\n\n <button mat-button (click)=\"close()\">\n <mat-icon>close</mat-icon>\n </button>\n </ng-container>\n</header>\n\n<ngx-scan\n (actions)=\"actions($event)\"\n [showDialog]=\"showDialog\"\n [dialogs]=\"dialogs\"\n></ngx-scan>\n", styles: [":host{display:flex;flex-direction:column!important;flex:1;background-color:#f5f5f5;overflow:hidden}.page-header{display:flex;flex-direction:row;align-items:center}.page-header button{height:100%}@media only screen and (max-width: 768px){header .title{font-size:12px!important;line-height:18px!important}}\n", ".page-header{z-index:2000;height:64px;padding:0;background-color:#fff;border-bottom:1px solid rgba(0,0,0,.12)}.page-header .title{padding-left:24px;line-height:64px;font-size:18px}.page-header .separator{width:1px;background-color:#0000001f;height:100%}.page-header .total{line-height:64px}.page-header .total span{font-weight:700}.page-footer{height:64px}.page-footer button{margin-left:24px;box-shadow:none!important}\n"], dependencies: [{ kind: "directive", type: i2$1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i6$1.MatIcon, selector: "mat-icon", inputs: ["color", "inline", "svgIcon", "fontSet", "fontIcon"], exportAs: ["matIcon"] }, { kind: "component", 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"] }, { kind: "component", type: ScanComponent, selector: "ngx-scan", inputs: ["type", "dialogs", "showDialog"], outputs: ["actions"] }, { kind: "component", type: CameraSwitchComponent, selector: "ngx-scan-camera-switch" }, { kind: "pipe", type: i2$1.AsyncPipe, name: "async" }, { kind: "pipe", type: i4.TranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
3844
3852
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.3.0", ngImport: i0, type: ScanProfileComponent, decorators: [{
3845
3853
  type: Component,
3846
3854
  args: [{ selector: 'app-scan-profile', changeDetection: ChangeDetectionStrategy.OnPush, template: "<header class=\"page-header\">\n <div class=\"title\" >\n {{ \"scandoc.title\" | translate }}\n </div>\n\n <span style=\"flex: 1\"></span>\n\n <ng-container *ngIf=\"cameraProvider.$showSwitch| async\">\n <div class=\"separator\"></div>\n <div style=\"padding: 0px 16px\">\n <ngx-scan-camera-switch></ngx-scan-camera-switch>\n </div>\n </ng-container>\n\n <ng-container *ngIf=\"type === 'desktop'\">\n <div class=\"separator\"></div>\n\n <button mat-button (click)=\"close()\">\n <mat-icon>close</mat-icon>\n </button>\n </ng-container>\n</header>\n\n<ngx-scan\n (actions)=\"actions($event)\"\n [showDialog]=\"showDialog\"\n [dialogs]=\"dialogs\"\n></ngx-scan>\n", styles: [":host{display:flex;flex-direction:column!important;flex:1;background-color:#f5f5f5;overflow:hidden}.page-header{display:flex;flex-direction:row;align-items:center}.page-header button{height:100%}@media only screen and (max-width: 768px){header .title{font-size:12px!important;line-height:18px!important}}\n", ".page-header{z-index:2000;height:64px;padding:0;background-color:#fff;border-bottom:1px solid rgba(0,0,0,.12)}.page-header .title{padding-left:24px;line-height:64px;font-size:18px}.page-header .separator{width:1px;background-color:#0000001f;height:100%}.page-header .total{line-height:64px}.page-header .total span{font-weight:700}.page-footer{height:64px}.page-footer button{margin-left:24px;box-shadow:none!important}\n"] }]
3847
- }], ctorParameters: function () { return [{ type: DialogsCoreProvider }, { type: NgxScandocCameraProvider }, { type: i1$3.MatDialogRef }, { type: i2.Platform }]; }, propDecorators: { type: [{
3855
+ }], ctorParameters: function () { return [{ type: DialogsCoreProvider }, { type: NgxScandocCameraProvider }, { type: ScanProvider }, { type: i1$3.MatDialogRef }, { type: i2.Platform }]; }, propDecorators: { type: [{
3848
3856
  type: Input
3849
3857
  }], handleTouchMove: [{
3850
3858
  type: HostListener,