diff --git a/src/app/header/header.component.html b/src/app/header/header.component.html
index e71f158..a4ca718 100644
--- a/src/app/header/header.component.html
+++ b/src/app/header/header.component.html
@@ -1,7 +1,7 @@
diff --git a/src/app/route/route-edit/route-edit.component.css b/src/app/route/route-edit/route-edit.component.css
index e69de29..0bf09ef 100644
--- a/src/app/route/route-edit/route-edit.component.css
+++ b/src/app/route/route-edit/route-edit.component.css
@@ -0,0 +1,4 @@
+input[type="text"], textarea {
+ -webkit-user-select: auto;
+ user-select: auto;
+}
diff --git a/src/app/route/route-edit/route-edit.component.html b/src/app/route/route-edit/route-edit.component.html
index bfb03eb..de8cee9 100644
--- a/src/app/route/route-edit/route-edit.component.html
+++ b/src/app/route/route-edit/route-edit.component.html
@@ -28,7 +28,8 @@
Editing Route
-
+
diff --git a/src/app/route/route-edit/route-edit.component.ts b/src/app/route/route-edit/route-edit.component.ts
index 6c6dad8..ee48f30 100644
--- a/src/app/route/route-edit/route-edit.component.ts
+++ b/src/app/route/route-edit/route-edit.component.ts
@@ -200,4 +200,8 @@ export class RouteEditComponent implements OnInit, CanComponentDeactivate {
});
}
}
+
+ onFocus(event: Event): void {
+ event.preventDefault();
+ }
}
diff --git a/src/app/shared/guards/can-deactivate-form-guard.service.ts b/src/app/shared/guards/can-deactivate-form-guard.service.ts
index 28ac70e..0326efb 100644
--- a/src/app/shared/guards/can-deactivate-form-guard.service.ts
+++ b/src/app/shared/guards/can-deactivate-form-guard.service.ts
@@ -9,7 +9,7 @@ export class CanDeactivateFormGuardService {
constructor(private confirmationDialogService: ConfirmationDialogService) {}
canDeactivateForm(isDirty: boolean):Promise {
- if (isDirty) {
+ /*if (isDirty) {
return new Promise((resolve) => {
this.confirmationDialogService
.confirm(
@@ -24,6 +24,19 @@ export class CanDeactivateFormGuardService {
});
} else {
return Promise.resolve(true);
- }
+ }*/
+
+ return new Promise((resolve) => {
+ this.confirmationDialogService
+ .confirm(
+ 'Confirm Exiting',
+ `You are about to exit without saving the changes. Do you want to proceed?`,
+ 'Yes',
+ 'Cancel'
+ )
+ .subscribe((confirmed: boolean) => {
+ resolve(confirmed);
+ });
+ });
}
}