fix : enter and shash enter has better working things (qui, tan,for)
This commit is contained in:
parent
3f1081b014
commit
f7552a8479
@ -19,11 +19,12 @@
|
||||
<button
|
||||
*ngIf="showShashEnter"
|
||||
class="btn btn-dark"
|
||||
[disabled]="twoGroupLabels.includes(selectedLabel || '') && isFirstGroupComplete"
|
||||
(click)="padEnter()"
|
||||
>
|
||||
[disabled]="isShashEnterDisabled"
|
||||
(click)="onShashEnter()"
|
||||
>
|
||||
shash ENTER
|
||||
</button>
|
||||
</button>
|
||||
|
||||
<button class="btn btn-dark">COPY</button>
|
||||
|
||||
<button class="btn btn-danger btn-bkp" *ngIf="showBackspace" (click)="removeLastNumber()">BKP</button>
|
||||
@ -96,7 +97,7 @@
|
||||
</ng-container>
|
||||
|
||||
<div class="col-6">
|
||||
<button class="btn btn-secondary w-100 number-button" [disabled]="!numericPadEnabled" (click)="padEnter()">Enter</button>
|
||||
<button class="btn btn-secondary w-100 number-button" [disabled]="!numericPadEnabled" (click)="onPadEnter()">Enter</button>
|
||||
</div>
|
||||
<div class="col-6">
|
||||
<button class="btn btn-secondary w-100 number-button" [disabled]="!canPrint" (click)="print()">Print</button>
|
||||
|
||||
@ -1,3 +1,4 @@
|
||||
// ... same imports
|
||||
import { Component, Input, OnInit } from '@angular/core';
|
||||
import { CommonModule } from '@angular/common';
|
||||
import { SelectionService } from '../selection.service/selection.service';
|
||||
@ -162,7 +163,14 @@ export class TouchPadMenuComponent implements OnInit {
|
||||
return this.selectedNumbers.includes(number);
|
||||
}
|
||||
|
||||
padEnter() {
|
||||
// 👉 Changed from padEnter to split into two handlers
|
||||
onPadEnter() {
|
||||
if (this.canPrint) {
|
||||
this.print();
|
||||
}
|
||||
}
|
||||
|
||||
onShashEnter() {
|
||||
if (this.selectedLabel === 'TAN') {
|
||||
if (this.tanGroupStage < 2) {
|
||||
this.tanGroupStage++;
|
||||
@ -183,8 +191,6 @@ export class TouchPadMenuComponent implements OnInit {
|
||||
this.selectionService.updatePartial({ numbers: [...this.selectedNumbers] });
|
||||
return;
|
||||
}
|
||||
} else if (this.canPrint) {
|
||||
this.print();
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user