Skip to content

Commit

Permalink
refactor
Browse files Browse the repository at this point in the history
  • Loading branch information
Andi Braimllari committed Dec 3, 2024
1 parent f094b3e commit f5e2231
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@
pointer-events: all;
}

#file-name {
.uploaded-document-name {
min-width: 300px;
max-width: 300px;
white-space: nowrap;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,10 @@ <h5 class="modal-title" id="document-upload-modal-label">
(change)="uploadDocument($event)"
accept=".pdf"
/>
<i id="file-name"></i>
<i
id="uploaded-document-name"
class="uploaded-document-name"
></i>
</div>
<div class="about-file-upload-message-div">
<span class="about-file-upload-message"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,8 @@ export class DocumentUploadComponent implements OnDestroy {
(Math.round(fileSize) + 1) * 60 * 1000;
this.startProcessingTimer(sizeBasedTimerEstimation);

document.getElementById('file-name')!.textContent = file.name;
document.getElementById('uploaded-document-name')!.textContent =
file.name;
const formData: FormData = new FormData();
formData.append('uploadFile', file, file.name);
this.documentUploadSubscription$ = this.httpClient
Expand All @@ -93,7 +94,7 @@ export class DocumentUploadComponent implements OnDestroy {
this.totalMarkingsCount = undefined;
this.totalPagesMarkedCount = undefined;
(document.getElementById('document-upload-input')! as any).value = null;
document.getElementById('file-name')!.textContent = '';
document.getElementById('uploaded-document-name')!.textContent = '';
}

private startProcessingTimer(totalMinutes: number = 3 * 60 * 1000): void {
Expand Down

0 comments on commit f5e2231

Please sign in to comment.