kwikid-agent-dashboard 0.0.29 → 0.0.31

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.
@@ -1,8 +1,8 @@
1
1
  (function (global, factory) {
2
- typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/google-maps'), require('@taiga-ui/core'), require('leaflet'), require('leaflet-routing-machine'), require('kwikid-toolkit'), require('@angular/common/http'), require('kwikui'), require('@angular/common'), require('@angular/forms'), require('@taiga-ui/cdk'), require('@angular/cdk/scrolling'), require('kwikid-forms'), require('@taiga-ui/addon-mobile')) :
3
- typeof define === 'function' && define.amd ? define('kwikid-agent-dashboard', ['exports', '@angular/core', '@angular/google-maps', '@taiga-ui/core', 'leaflet', 'leaflet-routing-machine', 'kwikid-toolkit', '@angular/common/http', 'kwikui', '@angular/common', '@angular/forms', '@taiga-ui/cdk', '@angular/cdk/scrolling', 'kwikid-forms', '@taiga-ui/addon-mobile'], factory) :
4
- (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["kwikid-agent-dashboard"] = {}, global.ng.core, global.ng.googleMaps, global["@taiga-ui/core"], global.L, null, global.kwikidToolkit, global.ng.common.http, global.i3, global.ng.common, global.ng.forms, global["@taiga-ui/cdk"], global.ng.cdk.scrolling, global.i7, global["@taiga-ui/addon-mobile"]));
5
- })(this, (function (exports, i0, googleMaps, i10, L, leafletRoutingMachine, kwikidToolkit, i3$1, i3, i5, i6, i9, i4, i7, addonMobile) { 'use strict';
2
+ typeof exports === 'object' && typeof module !== 'undefined' ? factory(exports, require('@angular/core'), require('@angular/google-maps'), require('@taiga-ui/core'), require('kwikid-toolkit'), require('rxjs/operators'), require('rxjs'), require('@angular/common/http'), require('kwikui'), require('leaflet'), require('leaflet-routing-machine'), require('@angular/common'), require('@angular/forms'), require('@taiga-ui/cdk'), require('@angular/cdk/scrolling'), require('kwikid-forms'), require('@taiga-ui/addon-mobile')) :
3
+ typeof define === 'function' && define.amd ? define('kwikid-agent-dashboard', ['exports', '@angular/core', '@angular/google-maps', '@taiga-ui/core', 'kwikid-toolkit', 'rxjs/operators', 'rxjs', '@angular/common/http', 'kwikui', 'leaflet', 'leaflet-routing-machine', '@angular/common', '@angular/forms', '@taiga-ui/cdk', '@angular/cdk/scrolling', 'kwikid-forms', '@taiga-ui/addon-mobile'], factory) :
4
+ (global = typeof globalThis !== 'undefined' ? globalThis : global || self, factory(global["kwikid-agent-dashboard"] = {}, global.ng.core, global.ng.googleMaps, global["@taiga-ui/core"], global.kwikidToolkit, global.rxjs.operators, global.rxjs, global.ng.common.http, global.i4, global.L, null, global.ng.common, global.ng.forms, global["@taiga-ui/cdk"], global.ng.cdk.scrolling, global.i8, global["@taiga-ui/addon-mobile"]));
5
+ })(this, (function (exports, i0, i2, i11, kwikidToolkit, operators, rxjs, i3, i4, L, leafletRoutingMachine, i6, i7, i10, i5, i8, addonMobile) { 'use strict';
6
6
 
7
7
  function _interopNamespace(e) {
8
8
  if (e && e.__esModule) return e;
@@ -23,15 +23,16 @@
23
23
  }
24
24
 
25
25
  var i0__namespace = /*#__PURE__*/_interopNamespace(i0);
26
- var i10__namespace = /*#__PURE__*/_interopNamespace(i10);
27
- var L__namespace = /*#__PURE__*/_interopNamespace(L);
28
- var i3__namespace$1 = /*#__PURE__*/_interopNamespace(i3$1);
26
+ var i2__namespace = /*#__PURE__*/_interopNamespace(i2);
27
+ var i11__namespace = /*#__PURE__*/_interopNamespace(i11);
29
28
  var i3__namespace = /*#__PURE__*/_interopNamespace(i3);
30
- var i5__namespace = /*#__PURE__*/_interopNamespace(i5);
31
- var i6__namespace = /*#__PURE__*/_interopNamespace(i6);
32
- var i9__namespace = /*#__PURE__*/_interopNamespace(i9);
33
29
  var i4__namespace = /*#__PURE__*/_interopNamespace(i4);
30
+ var L__namespace = /*#__PURE__*/_interopNamespace(L);
31
+ var i6__namespace = /*#__PURE__*/_interopNamespace(i6);
34
32
  var i7__namespace = /*#__PURE__*/_interopNamespace(i7);
33
+ var i10__namespace = /*#__PURE__*/_interopNamespace(i10);
34
+ var i5__namespace = /*#__PURE__*/_interopNamespace(i5);
35
+ var i8__namespace = /*#__PURE__*/_interopNamespace(i8);
35
36
 
36
37
  /******************************************************************************
37
38
  Copyright (c) Microsoft Corporation.
@@ -497,6 +498,62 @@
497
498
  __disposeResources: __disposeResources,
498
499
  };
499
500
 
501
+ // To Calculate Distance between two markers
502
+ var calculateDistance = function (point1, point2) {
503
+ var lat1 = point1.lat;
504
+ var lng1 = point1.lng;
505
+ var lat2 = point2.lat;
506
+ var lng2 = point2.lng;
507
+ var R = 6371; // Earth radius in kilometers
508
+ var dLat = (lat2 - lat1) * (Math.PI / 180);
509
+ var dLng = (lng2 - lng1) * (Math.PI / 180);
510
+ var a = Math.sin(dLat / 2) * Math.sin(dLat / 2) +
511
+ Math.cos((lat1 * Math.PI) / 180) *
512
+ Math.cos((lat2 * Math.PI) / 180) *
513
+ Math.sin(dLng / 2) *
514
+ Math.sin(dLng / 2);
515
+ var c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));
516
+ var distance = R * c;
517
+ return distance;
518
+ };
519
+ // To calculate nearest distance from marker
520
+ var nearestNeighborAlgorithm = function (startingPoint, unvisitedPoints) {
521
+ var e_1, _a;
522
+ var currentPoint = startingPoint;
523
+ var path = [currentPoint];
524
+ var visitedPoints = new Set([currentPoint]);
525
+ while (unvisitedPoints.length > 0) {
526
+ var nearestPoint = null;
527
+ var minDistance = Number.POSITIVE_INFINITY;
528
+ try {
529
+ for (var unvisitedPoints_1 = (e_1 = void 0, __values(unvisitedPoints)), unvisitedPoints_1_1 = unvisitedPoints_1.next(); !unvisitedPoints_1_1.done; unvisitedPoints_1_1 = unvisitedPoints_1.next()) {
530
+ var point = unvisitedPoints_1_1.value;
531
+ var distance = calculateDistance(currentPoint, point);
532
+ if (distance < minDistance) {
533
+ minDistance = distance;
534
+ nearestPoint = point;
535
+ }
536
+ }
537
+ }
538
+ catch (e_1_1) { e_1 = { error: e_1_1 }; }
539
+ finally {
540
+ try {
541
+ if (unvisitedPoints_1_1 && !unvisitedPoints_1_1.done && (_a = unvisitedPoints_1.return)) _a.call(unvisitedPoints_1);
542
+ }
543
+ finally { if (e_1) throw e_1.error; }
544
+ }
545
+ path.push(nearestPoint);
546
+ visitedPoints.add(nearestPoint);
547
+ currentPoint = nearestPoint;
548
+ unvisitedPoints = unvisitedPoints.filter(function (point) { return !visitedPoints.has(point); });
549
+ }
550
+ return path;
551
+ };
552
+ var addressConcator = function (data, config) {
553
+ var address = config.reduce(function (accumulator, currentValue) { return accumulator + '' + kwikidToolkit.getObjectValueFromPath(data, currentValue); }, '');
554
+ return address;
555
+ };
556
+
500
557
  var EStatus;
501
558
  (function (EStatus) {
502
559
  EStatus["NOT_STARTED"] = "not_started";
@@ -684,25 +741,381 @@
684
741
  }]
685
742
  }], ctorParameters: function () { return []; } });
686
743
 
687
- var MapService = /** @class */ (function () {
688
- function MapService(agentService) {
744
+ var GoogleMapsService = /** @class */ (function () {
745
+ function GoogleMapsService(agentService, mapDirectionsService, httpClient) {
689
746
  this.agentService = agentService;
747
+ this.mapDirectionsService = mapDirectionsService;
748
+ this.httpClient = httpClient;
690
749
  this.allMarkers = [];
691
750
  }
692
- // To Initialize Map
693
- MapService.prototype.initMap = function () {
751
+ // To get Current Position
752
+ GoogleMapsService.prototype.getPosition = function () {
753
+ return new Promise(function (resolve, reject) {
754
+ navigator.geolocation.watchPosition(function (resp) {
755
+ resolve({
756
+ lng: resp.coords.longitude,
757
+ lat: resp.coords.latitude
758
+ });
759
+ }, function (err) {
760
+ reject(err);
761
+ });
762
+ });
763
+ };
764
+ // To Initialize Google Maps
765
+ GoogleMapsService.prototype.initializeMap = function () {
766
+ return __awaiter(this, void 0, void 0, function () {
767
+ var _o;
768
+ return __generator(this, function (_p) {
769
+ switch (_p.label) {
770
+ case 0:
771
+ _o = this;
772
+ return [4 /*yield*/, this.getPosition()];
773
+ case 1:
774
+ _o.myPosition = _p.sent();
775
+ this.map = {
776
+ zoom: 10,
777
+ center: this.myPosition,
778
+ streetViewControl: false,
779
+ mapTypeControl: false,
780
+ fullscreenControl: false,
781
+ zoomControl: false
782
+ };
783
+ return [2 /*return*/];
784
+ }
785
+ });
786
+ });
787
+ };
788
+ // To extract Location from the Task Details
789
+ GoogleMapsService.prototype.getLocation = function (task) {
790
+ return __awaiter(this, void 0, void 0, function () {
791
+ var _this = this;
792
+ return __generator(this, function (_o) {
793
+ return [2 /*return*/, new Promise(function (resolve) { return __awaiter(_this, void 0, void 0, function () {
794
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, encodedAddres, config, address, config, address, address, url, response, data, isValidLocation, location;
795
+ return __generator(this, function (_o) {
796
+ switch (_o.label) {
797
+ case 0:
798
+ // If Fetch Address from Multiple Paths
799
+ if (kwikidToolkit.checkObjectPathExists(this.agentService.config, 'dashboard.taskLocationPaths')) {
800
+ config = this.agentService.config.dashboard.taskLocationPaths;
801
+ address = addressConcator(task, config);
802
+ // Encode the Address in URI
803
+ encodedAddres = encodeURI(address);
804
+ }
805
+ // If Fetch Address from Single Path
806
+ else if (kwikidToolkit.checkObjectPathExists(this.agentService.config, 'dashboard.taskLocationPath')) {
807
+ config = this.agentService.config.dashboard.taskLocationPath;
808
+ address = kwikidToolkit.getObjectValueFromPath(task, config);
809
+ // Encode the Address in URI
810
+ encodedAddres = encodeURI(address);
811
+ }
812
+ // Default Address Paths Avaiable
813
+ else {
814
+ address = (_k = (_j = (_g = (_d = (_c = (_b = (_a = task === null || task === void 0 ? void 0 : task.extras) === null || _a === void 0 ? void 0 : _a.task_details) === null || _b === void 0 ? void 0 : _b.customer_details) === null || _c === void 0 ? void 0 : _c.address) !== null && _d !== void 0 ? _d : (_f = (_e = task === null || task === void 0 ? void 0 : task.task_details) === null || _e === void 0 ? void 0 : _e.customer_details) === null || _f === void 0 ? void 0 : _f.address) !== null && _g !== void 0 ? _g : (_h = task === null || task === void 0 ? void 0 : task.extras) === null || _h === void 0 ? void 0 : _h.address) !== null && _j !== void 0 ? _j : task === null || task === void 0 ? void 0 : task.address) !== null && _k !== void 0 ? _k : '';
815
+ // Encode the Address in URI
816
+ encodedAddres = encodeURI(address);
817
+ }
818
+ url = "https://maps.googleapis.com/maps/api/geocode/json?key=" + this.apiKey + "&address=" + encodedAddres;
819
+ return [4 /*yield*/, fetch(url)];
820
+ case 1:
821
+ response = _o.sent();
822
+ return [4 /*yield*/, response.json()];
823
+ case 2:
824
+ data = _o.sent();
825
+ isValidLocation = kwikidToolkit.isNotEmptyArray(data === null || data === void 0 ? void 0 : data.results);
826
+ location = isValidLocation
827
+ ? (_m = (_l = data === null || data === void 0 ? void 0 : data.results[0]) === null || _l === void 0 ? void 0 : _l.geometry) === null || _m === void 0 ? void 0 : _m.location
828
+ : { lat: null, lng: null };
829
+ // Set Location validation & Google Maps URL
830
+ location['isValidLocation'] = isValidLocation;
831
+ location['googleMapsUrl'] = "https://www.google.com/maps/place/" + (location === null || location === void 0 ? void 0 : location.lat) + "," + (location === null || location === void 0 ? void 0 : location.lng);
832
+ resolve(location);
833
+ return [2 /*return*/];
834
+ }
835
+ });
836
+ }); })];
837
+ });
838
+ });
839
+ };
840
+ // Get Tasks | Markers Location Co Ordinates
841
+ GoogleMapsService.prototype.getMarkersLocation = function (myMarker, tasks) {
842
+ return __awaiter(this, void 0, void 0, function () {
843
+ var _this = this;
844
+ return __generator(this, function (_o) {
845
+ return [2 /*return*/, new Promise(function (resolve) { return __awaiter(_this, void 0, void 0, function () {
846
+ var markers, promises;
847
+ var _this = this;
848
+ return __generator(this, function (_o) {
849
+ switch (_o.label) {
850
+ case 0:
851
+ markers = [];
852
+ markers.push(myMarker);
853
+ promises = tasks.map(function (task) { return __awaiter(_this, void 0, void 0, function () {
854
+ var marker;
855
+ return __generator(this, function (_o) {
856
+ switch (_o.label) {
857
+ case 0: return [4 /*yield*/, this.getLocation(task)];
858
+ case 1:
859
+ marker = _o.sent();
860
+ task = Object.assign(Object.assign({}, task), marker);
861
+ markers.push(task);
862
+ return [2 /*return*/];
863
+ }
864
+ });
865
+ }); });
866
+ return [4 /*yield*/, Promise.all(promises)];
867
+ case 1:
868
+ _o.sent();
869
+ resolve(markers);
870
+ return [2 /*return*/];
871
+ }
872
+ });
873
+ }); })];
874
+ });
875
+ });
876
+ };
877
+ // Plot All Markers
878
+ GoogleMapsService.prototype.plotAllMarkers = function (tasks) {
879
+ return __awaiter(this, void 0, void 0, function () {
880
+ var _this = this;
881
+ return __generator(this, function (_o) {
882
+ return [2 /*return*/, new Promise(function (resolve) { return __awaiter(_this, void 0, void 0, function () {
883
+ var path, promises;
884
+ var _this = this;
885
+ return __generator(this, function (_o) {
886
+ switch (_o.label) {
887
+ case 0:
888
+ path = [];
889
+ promises = tasks.map(function (task) {
890
+ if (task === null || task === void 0 ? void 0 : task.isValidLocation) {
891
+ path.push({
892
+ location: task,
893
+ stopover: true
894
+ });
895
+ _this.allMarkers.push(task);
896
+ }
897
+ });
898
+ return [4 /*yield*/, Promise.all(promises)];
899
+ case 1:
900
+ _o.sent();
901
+ resolve(path);
902
+ return [2 /*return*/];
903
+ }
904
+ });
905
+ }); })];
906
+ });
907
+ });
908
+ };
909
+ // To Plot Directions for All Tasks
910
+ GoogleMapsService.prototype.plotDirectionsForAllTasks = function (tasks) {
911
+ return __awaiter(this, void 0, void 0, function () {
912
+ var myMarker, markers, startingPoint, unvisitedWaypoints, optimizedRoute, path, request;
913
+ return __generator(this, function (_o) {
914
+ switch (_o.label) {
915
+ case 0:
916
+ this.allMarkers = [];
917
+ myMarker = {
918
+ lat: this.myPosition.lat,
919
+ lng: this.myPosition.lng,
920
+ title: 0,
921
+ color: 'red'
922
+ };
923
+ return [4 /*yield*/, this.getMarkersLocation(myMarker, tasks)];
924
+ case 1:
925
+ markers = _o.sent();
926
+ startingPoint = markers[0];
927
+ unvisitedWaypoints = markers.slice(1);
928
+ optimizedRoute = nearestNeighborAlgorithm(startingPoint, unvisitedWaypoints);
929
+ // Sort All Tasks as per optimized routes
930
+ tasks = optimizedRoute.slice(1);
931
+ this.allMarkers = [myMarker];
932
+ return [4 /*yield*/, this.plotAllMarkers(tasks)];
933
+ case 2:
934
+ path = _o.sent();
935
+ request = {
936
+ origin: this.myPosition,
937
+ destination: this.myPosition,
938
+ waypoints: path,
939
+ travelMode: google.maps.TravelMode.DRIVING
940
+ };
941
+ this.directionsRenderOption = {
942
+ suppressMarkers: true
943
+ };
944
+ this.directionsResults$ = this.mapDirectionsService
945
+ .route(request)
946
+ .pipe(operators.map(function (response) { return response.result; }));
947
+ this.directionsResults$.subscribe(function (val) { });
948
+ this.allDirectionsResults$ = this.directionsResults$;
949
+ return [2 /*return*/, tasks];
950
+ }
951
+ });
952
+ });
953
+ };
954
+ // To Plot Directions for Selected Tasks
955
+ GoogleMapsService.prototype.plotDirectionsForSelectedTask = function (index) {
956
+ if (index != null) {
957
+ var taskMarker = this.allMarkers[index + 1];
958
+ // If Location is Available in Task Details
959
+ if (taskMarker === null || taskMarker === void 0 ? void 0 : taskMarker.isValidLocation) {
960
+ var request = {
961
+ origin: this.myPosition,
962
+ destination: taskMarker,
963
+ optimizeWaypoints: true,
964
+ travelMode: google.maps.TravelMode.DRIVING
965
+ };
966
+ this.directionsResults$ = this.mapDirectionsService
967
+ .route(request)
968
+ .pipe(operators.map(function (response) { return response.result; }));
969
+ this.directionsResults$.subscribe();
970
+ }
971
+ else {
972
+ alert('No Location Available');
973
+ this.directionsResults$ = this.allDirectionsResults$;
974
+ }
975
+ }
976
+ else {
977
+ this.directionsResults$ = this.allDirectionsResults$;
978
+ }
979
+ };
980
+ return GoogleMapsService;
981
+ }());
982
+ /** @nocollapse */ GoogleMapsService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: GoogleMapsService, deps: [{ token: AgentService }, { token: i2__namespace.MapDirectionsService }, { token: i3__namespace.HttpClient }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
983
+ /** @nocollapse */ GoogleMapsService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: GoogleMapsService, providedIn: 'root' });
984
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: GoogleMapsService, decorators: [{
985
+ type: i0.Injectable,
986
+ args: [{
987
+ providedIn: 'root'
988
+ }]
989
+ }], ctorParameters: function () { return [{ type: AgentService }, { type: i2__namespace.MapDirectionsService }, { type: i3__namespace.HttpClient }]; }, propDecorators: { directionsRenders: [{
990
+ type: i0.ViewChildren,
991
+ args: ['directionsRender']
992
+ }] } });
993
+
994
+ var OpenStreetMapsService = /** @class */ (function () {
995
+ function OpenStreetMapsService(agentService, mapDirectionsService, httpClient) {
996
+ this.agentService = agentService;
997
+ this.mapDirectionsService = mapDirectionsService;
998
+ this.httpClient = httpClient;
999
+ this.allMarkers = [];
1000
+ }
1001
+ // To get Current Position
1002
+ OpenStreetMapsService.prototype.getPosition = function () {
1003
+ return new Promise(function (resolve, reject) {
1004
+ navigator.geolocation.watchPosition(function (resp) {
1005
+ resolve({
1006
+ lng: resp.coords.longitude,
1007
+ lat: resp.coords.latitude
1008
+ });
1009
+ }, function (err) {
1010
+ reject(err);
1011
+ });
1012
+ });
1013
+ };
1014
+ // To extract Location from the Task Details
1015
+ OpenStreetMapsService.prototype.getLocation = function (task) {
694
1016
  return __awaiter(this, void 0, void 0, function () {
695
- var _g;
696
- return __generator(this, function (_h) {
697
- switch (_h.label) {
1017
+ var _this = this;
1018
+ return __generator(this, function (_q) {
1019
+ return [2 /*return*/, new Promise(function (resolve) { return __awaiter(_this, void 0, void 0, function () {
1020
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m, _o, _p, encodedAddres, config, address, config, address, address, url, response, data, isValidLocation, location;
1021
+ return __generator(this, function (_q) {
1022
+ switch (_q.label) {
1023
+ case 0:
1024
+ // If Fetch Address from Multiple Paths
1025
+ if (kwikidToolkit.checkObjectPathExists(this.agentService.config, 'dashboard.taskLocationPaths')) {
1026
+ config = this.agentService.config.dashboard.taskLocationPaths;
1027
+ address = addressConcator(task, config);
1028
+ // Encode the Address in URI
1029
+ encodedAddres = encodeURI(address);
1030
+ }
1031
+ // If Fetch Address from Single Path
1032
+ else if (kwikidToolkit.checkObjectPathExists(this.agentService.config, 'dashboard.taskLocationPath')) {
1033
+ config = this.agentService.config.dashboard.taskLocationPath;
1034
+ address = kwikidToolkit.getObjectValueFromPath(task, config);
1035
+ // Encode the Address in URI
1036
+ encodedAddres = encodeURI(address);
1037
+ }
1038
+ // Default Address Paths Avaiable
1039
+ else {
1040
+ address = (_k = (_j = (_g = (_d = (_c = (_b = (_a = task === null || task === void 0 ? void 0 : task.extras) === null || _a === void 0 ? void 0 : _a.task_details) === null || _b === void 0 ? void 0 : _b.customer_details) === null || _c === void 0 ? void 0 : _c.address) !== null && _d !== void 0 ? _d : (_f = (_e = task === null || task === void 0 ? void 0 : task.task_details) === null || _e === void 0 ? void 0 : _e.customer_details) === null || _f === void 0 ? void 0 : _f.address) !== null && _g !== void 0 ? _g : (_h = task === null || task === void 0 ? void 0 : task.extras) === null || _h === void 0 ? void 0 : _h.address) !== null && _j !== void 0 ? _j : task === null || task === void 0 ? void 0 : task.address) !== null && _k !== void 0 ? _k : '';
1041
+ // Encode the Address in URI
1042
+ encodedAddres = encodeURI(address);
1043
+ }
1044
+ url = "https://nominatim.openstreetmap.org/search?q=" + encodedAddres + "&format=json";
1045
+ return [4 /*yield*/, fetch(url)];
1046
+ case 1:
1047
+ response = _q.sent();
1048
+ return [4 /*yield*/, response.json()];
1049
+ case 2:
1050
+ data = _q.sent();
1051
+ isValidLocation = kwikidToolkit.isNotEmptyArray(data) && ((_l = data[0]) === null || _l === void 0 ? void 0 : _l.lat) & ((_m = data[0]) === null || _m === void 0 ? void 0 : _m.lon);
1052
+ location = isValidLocation
1053
+ ? { lat: (_o = data[0]) === null || _o === void 0 ? void 0 : _o.lat, lng: (_p = data[0]) === null || _p === void 0 ? void 0 : _p.lon }
1054
+ : { lat: null, lng: null };
1055
+ // Set Location validation & Google Maps URL
1056
+ location['isValidLocation'] = isValidLocation;
1057
+ location['color'] = isValidLocation ? 'blue' : 'red';
1058
+ location['googleMapsUrl'] = "https://www.google.com/maps/place/" + (location === null || location === void 0 ? void 0 : location.lat) + "," + (location === null || location === void 0 ? void 0 : location.lng);
1059
+ resolve(location);
1060
+ return [2 /*return*/];
1061
+ }
1062
+ });
1063
+ }); })];
1064
+ });
1065
+ });
1066
+ };
1067
+ // Get Tasks | Markers Location Co Ordinates
1068
+ OpenStreetMapsService.prototype.getMarkersLocation = function (myMarker, tasks) {
1069
+ return __awaiter(this, void 0, void 0, function () {
1070
+ var _this = this;
1071
+ return __generator(this, function (_q) {
1072
+ return [2 /*return*/, new Promise(function (resolve) { return __awaiter(_this, void 0, void 0, function () {
1073
+ var markers, promises;
1074
+ var _this = this;
1075
+ return __generator(this, function (_q) {
1076
+ switch (_q.label) {
1077
+ case 0:
1078
+ markers = [];
1079
+ markers.push(myMarker);
1080
+ promises = tasks.map(function (task) { return __awaiter(_this, void 0, void 0, function () {
1081
+ var marker;
1082
+ return __generator(this, function (_q) {
1083
+ switch (_q.label) {
1084
+ case 0: return [4 /*yield*/, this.getLocation(task)];
1085
+ case 1:
1086
+ marker = _q.sent();
1087
+ task = Object.assign(Object.assign({}, task), marker);
1088
+ markers.push(task);
1089
+ return [2 /*return*/];
1090
+ }
1091
+ });
1092
+ }); });
1093
+ return [4 /*yield*/, Promise.all(promises)];
1094
+ case 1:
1095
+ _q.sent();
1096
+ resolve(markers);
1097
+ return [2 /*return*/];
1098
+ }
1099
+ });
1100
+ }); })];
1101
+ });
1102
+ });
1103
+ };
1104
+ // To Initialize Open Street Map
1105
+ OpenStreetMapsService.prototype.initializeMap = function () {
1106
+ return __awaiter(this, void 0, void 0, function () {
1107
+ var _q;
1108
+ return __generator(this, function (_r) {
1109
+ switch (_r.label) {
698
1110
  case 0:
699
- _g = this;
1111
+ console.log('Running Init Open Street Maps');
1112
+ _q = this;
700
1113
  return [4 /*yield*/, this.getPosition()];
701
1114
  case 1:
702
- _g.myPosition = _h.sent();
1115
+ _q.myPosition = _r.sent();
703
1116
  this.map = L__namespace.map('map', {
704
1117
  center: [this.myPosition.lat, this.myPosition.lng],
705
- zoom: 13
1118
+ zoom: 11
706
1119
  });
707
1120
  L__namespace.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png').addTo(this.map);
708
1121
  return [2 /*return*/];
@@ -710,9 +1123,9 @@
710
1123
  });
711
1124
  });
712
1125
  };
713
- // To Add Marker in Map
714
- MapService.prototype.addMarker = function (_g) {
715
- var lat = _g.lat, lng = _g.lng, title = _g.title, color = _g.color;
1126
+ // To Add Open Street Marker in Map
1127
+ OpenStreetMapsService.prototype.addMarker = function (_q) {
1128
+ var lat = _q.lat, lng = _q.lng, title = _q.title, color = _q.color;
716
1129
  L__namespace.marker([lat, lng], {
717
1130
  icon: L__namespace.icon({
718
1131
  iconUrl: color == 'red'
@@ -723,51 +1136,59 @@
723
1136
  .addTo(this.map)
724
1137
  .bindPopup(title);
725
1138
  };
726
- // To Plot Directions for All Tasks
727
- MapService.prototype.plotDirectionsForAllTasks = function (tasks) {
728
- var _this = this;
729
- if (this.map) {
730
- this.allMarkers = [];
731
- // Create Agent Marker & Plot It.
732
- var myMarker = {
733
- lat: this.myPosition.lat,
734
- lng: this.myPosition.lng,
735
- title: 0,
736
- color: 'red'
737
- };
738
- this.addMarker(myMarker);
739
- this.allMarkers.push(myMarker);
740
- // Create Markers for all Tasks
741
- tasks.map(function (task, index) {
742
- var marker = _this.getLatLng(_this.getLocation(task), index);
743
- _this.allMarkers.push(marker);
744
- });
745
- // Run Algorithm to get optimized Routes
746
- var startingPoint = this.allMarkers[0];
747
- var unvisitedWaypoints = this.allMarkers.slice(1);
748
- var optimizedRoute = this.nearestNeighborAlgorithm(startingPoint, unvisitedWaypoints);
749
- // Sort All Markers as per optimized routes
750
- this.allMarkers = this.sortTasksAsPerDistance(optimizedRoute, this.allMarkers, true);
751
- // Sort All Tasks as per optimized routes
752
- tasks = this.sortTasksAsPerDistance(optimizedRoute.slice(1), tasks, false);
753
- // Plot Markers for All Tasks
754
- tasks.map(function (task, index) {
755
- var marker = _this.getLatLng(_this.getLocation(task), index);
756
- _this.addMarker(marker);
1139
+ // To Plot Open Street Directions for All Tasks
1140
+ OpenStreetMapsService.prototype.plotDirectionsForAllTasks = function (tasks) {
1141
+ return __awaiter(this, void 0, void 0, function () {
1142
+ var myMarker, _q, startingPoint, unvisitedWaypoints, optimizedRoute, styles;
1143
+ var _this = this;
1144
+ return __generator(this, function (_r) {
1145
+ switch (_r.label) {
1146
+ case 0:
1147
+ if (!this.map) return [3 /*break*/, 2];
1148
+ this.allMarkers = [];
1149
+ myMarker = {
1150
+ lat: this.myPosition.lat,
1151
+ lng: this.myPosition.lng,
1152
+ title: 0,
1153
+ color: 'red'
1154
+ };
1155
+ this.addMarker(myMarker);
1156
+ this.allMarkers.push(myMarker);
1157
+ // Create Markers for all Tasks
1158
+ _q = this;
1159
+ return [4 /*yield*/, this.getMarkersLocation(myMarker, tasks)];
1160
+ case 1:
1161
+ // Create Markers for all Tasks
1162
+ _q.allMarkers = _r.sent();
1163
+ startingPoint = this.allMarkers[0];
1164
+ unvisitedWaypoints = this.allMarkers.slice(1);
1165
+ optimizedRoute = nearestNeighborAlgorithm(startingPoint, unvisitedWaypoints);
1166
+ // Sort All Markers as per optimized routes
1167
+ this.allMarkers = this.sortTasksAsPerDistance(optimizedRoute, this.allMarkers, true);
1168
+ // Sort All Tasks as per optimized routes
1169
+ tasks = this.sortTasksAsPerDistance(optimizedRoute.slice(1), tasks, false);
1170
+ // Plot Markers for All Tasks
1171
+ tasks.map(function (task) {
1172
+ if (task === null || task === void 0 ? void 0 : task.isValidLocation) {
1173
+ var marker = _this.getLocation(task);
1174
+ _this.addMarker(marker);
1175
+ }
1176
+ });
1177
+ styles = [
1178
+ { color: 'blue', opacity: 1, weight: 8 },
1179
+ { color: 'white', opacity: 0.6, weight: 12 }
1180
+ ];
1181
+ // Set Routes for all Tasks
1182
+ this.allTasksRoutes = this.setRoutes(this.allMarkers, styles);
1183
+ this.fitMapBounds();
1184
+ _r.label = 2;
1185
+ case 2: return [2 /*return*/, tasks];
1186
+ }
757
1187
  });
758
- // Set Styles for all Task Routes
759
- var styles = [
760
- { color: 'blue', opacity: 1, weight: 8 },
761
- { color: 'white', opacity: 0.6, weight: 12 }
762
- ];
763
- // Set Routes for all Tasks
764
- this.allTasksRoutes = this.setRoutes(this.allMarkers, styles);
765
- this.fitMapBounds();
766
- }
767
- return tasks;
1188
+ });
768
1189
  };
769
- // To plot Direction for selected Task
770
- MapService.prototype.plotDirectionsForSelectedTask = function (index) {
1190
+ // To plot Open Street Direction for selected Task
1191
+ OpenStreetMapsService.prototype.plotDirectionsForSelectedTask = function (index) {
771
1192
  if (index !== null) {
772
1193
  // Remove Previously Selected Task Route
773
1194
  if (this.selectedTaskRoutes) {
@@ -803,11 +1224,11 @@
803
1224
  this.fitMapBounds();
804
1225
  };
805
1226
  // Get Distance & Time of Selected Task
806
- MapService.prototype.getSelectedTaskDistanceAndTime = function () {
1227
+ OpenStreetMapsService.prototype.getSelectedTaskDistanceAndTime = function () {
807
1228
  return this.selectedTaskDistanceAndTime;
808
1229
  };
809
1230
  // Set Distance & Time of Selected Task
810
- MapService.prototype.setSelectedTaskDistanceAndTime = function () {
1231
+ OpenStreetMapsService.prototype.setSelectedTaskDistanceAndTime = function () {
811
1232
  this.selectedTaskRoutes.on('routesfound', function (e) {
812
1233
  var routes = e.routes;
813
1234
  var summary = routes[0].summary;
@@ -819,8 +1240,8 @@
819
1240
  };
820
1241
  });
821
1242
  };
822
- // To sort Task as per nearest distance
823
- MapService.prototype.sortTasksAsPerDistance = function (order, tasks, isMarker) {
1243
+ // To sort Open Street Maps Task as per nearest distance
1244
+ OpenStreetMapsService.prototype.sortTasksAsPerDistance = function (order, tasks, isMarker) {
824
1245
  var sortedTasks = [];
825
1246
  for (var i = 0; i < tasks.length; i++) {
826
1247
  var title = isMarker ? order[i].title : order[i].title - 1;
@@ -829,8 +1250,8 @@
829
1250
  }
830
1251
  return sortedTasks;
831
1252
  };
832
- // To set routes in the maps
833
- MapService.prototype.setRoutes = function (markers, styles) {
1253
+ // To set Open Street routes in the maps
1254
+ OpenStreetMapsService.prototype.setRoutes = function (markers, styles) {
834
1255
  return L__namespace.Routing.control({
835
1256
  waypoints: markers,
836
1257
  lineOptions: {
@@ -842,115 +1263,21 @@
842
1263
  routeWhileDragging: true
843
1264
  }).addTo(this.map);
844
1265
  };
845
- // To set view point on the map
846
- MapService.prototype.fitMapBounds = function () {
1266
+ // To set Open Street view point on the map
1267
+ OpenStreetMapsService.prototype.fitMapBounds = function () {
847
1268
  var markerLatLngs = this.allMarkers.map(function (marker) { return L__namespace.latLng(marker.lat, marker.lng); });
848
1269
  this.map.fitBounds(markerLatLngs);
849
1270
  };
850
- // To get Current Position
851
- MapService.prototype.getPosition = function () {
852
- return new Promise(function (resolve, reject) {
853
- navigator.geolocation.watchPosition(function (resp) {
854
- resolve({
855
- lng: resp.coords.longitude,
856
- lat: resp.coords.latitude
857
- });
858
- }, function (err) {
859
- reject(err);
860
- });
861
- });
862
- };
863
- // To extract Location from the Task Details
864
- MapService.prototype.getLocation = function (task) {
865
- var _a, _b, _c, _d, _e, _f;
866
- if (kwikidToolkit.checkObjectPathExists(this.agentService.config, 'dashboard.taskLocationPath')) {
867
- var location = kwikidToolkit.getObjectValueFromPath(task, this.agentService.config.dashboard.taskLocationPath);
868
- return location;
869
- }
870
- else {
871
- return ((_d = (_c = (_b = (_a = task === null || task === void 0 ? void 0 : task.extras) === null || _a === void 0 ? void 0 : _a.task_details) === null || _b === void 0 ? void 0 : _b.customer_details) === null || _c === void 0 ? void 0 : _c.location) !== null && _d !== void 0 ? _d : (_f = (_e = task === null || task === void 0 ? void 0 : task.task_details) === null || _e === void 0 ? void 0 : _e.customer_details) === null || _f === void 0 ? void 0 : _f.location);
872
- }
873
- };
874
- // To get Latitude & Longitude from Task Location
875
- MapService.prototype.getLatLng = function (data, index) {
876
- try {
877
- var url = data.split('@');
878
- var lat_long_match = url[1].split(',');
879
- var lat = Number(lat_long_match[0]);
880
- var long = Number(lat_long_match[1]);
881
- return { lat: lat, lng: long, title: index + 1, color: 'blue' };
882
- }
883
- catch (_a) {
884
- // If could not find Google Maps Location URL in Task
885
- return {
886
- lat: this.myPosition.lat,
887
- lng: this.myPosition.lng,
888
- title: index + 1,
889
- color: 'red'
890
- };
891
- }
892
- };
893
- // To Calculate Distance between two markers
894
- MapService.prototype.calculateDistance = function (point1, point2) {
895
- var lat1 = point1.lat;
896
- var lng1 = point1.lng;
897
- var lat2 = point2.lat;
898
- var lng2 = point2.lng;
899
- var R = 6371; // Earth radius in kilometers
900
- var dLat = (lat2 - lat1) * (Math.PI / 180);
901
- var dLng = (lng2 - lng1) * (Math.PI / 180);
902
- var a = Math.sin(dLat / 2) * Math.sin(dLat / 2) +
903
- Math.cos((lat1 * Math.PI) / 180) *
904
- Math.cos((lat2 * Math.PI) / 180) *
905
- Math.sin(dLng / 2) *
906
- Math.sin(dLng / 2);
907
- var c = 2 * Math.atan2(Math.sqrt(a), Math.sqrt(1 - a));
908
- var distance = R * c;
909
- return distance;
910
- };
911
- // To calculate nearest distance from marker
912
- MapService.prototype.nearestNeighborAlgorithm = function (startingPoint, unvisitedPoints) {
913
- var e_1, _g;
914
- var currentPoint = startingPoint;
915
- var path = [currentPoint];
916
- var visitedPoints = new Set([currentPoint]);
917
- while (unvisitedPoints.length > 0) {
918
- var nearestPoint = null;
919
- var minDistance = Number.POSITIVE_INFINITY;
920
- try {
921
- for (var unvisitedPoints_1 = (e_1 = void 0, __values(unvisitedPoints)), unvisitedPoints_1_1 = unvisitedPoints_1.next(); !unvisitedPoints_1_1.done; unvisitedPoints_1_1 = unvisitedPoints_1.next()) {
922
- var point = unvisitedPoints_1_1.value;
923
- var distance = this.calculateDistance(currentPoint, point);
924
- if (distance < minDistance) {
925
- minDistance = distance;
926
- nearestPoint = point;
927
- }
928
- }
929
- }
930
- catch (e_1_1) { e_1 = { error: e_1_1 }; }
931
- finally {
932
- try {
933
- if (unvisitedPoints_1_1 && !unvisitedPoints_1_1.done && (_g = unvisitedPoints_1.return)) _g.call(unvisitedPoints_1);
934
- }
935
- finally { if (e_1) throw e_1.error; }
936
- }
937
- path.push(nearestPoint);
938
- visitedPoints.add(nearestPoint);
939
- currentPoint = nearestPoint;
940
- unvisitedPoints = unvisitedPoints.filter(function (point) { return !visitedPoints.has(point); });
941
- }
942
- return path;
943
- };
944
- return MapService;
1271
+ return OpenStreetMapsService;
945
1272
  }());
946
- /** @nocollapse */ MapService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: MapService, deps: [{ token: AgentService }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
947
- /** @nocollapse */ MapService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: MapService, providedIn: 'root' });
948
- i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: MapService, decorators: [{
1273
+ /** @nocollapse */ OpenStreetMapsService.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: OpenStreetMapsService, deps: [{ token: AgentService }, { token: i2__namespace.MapDirectionsService }, { token: i3__namespace.HttpClient }], target: i0__namespace.ɵɵFactoryTarget.Injectable });
1274
+ /** @nocollapse */ OpenStreetMapsService.ɵprov = i0__namespace.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: OpenStreetMapsService, providedIn: 'root' });
1275
+ i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: OpenStreetMapsService, decorators: [{
949
1276
  type: i0.Injectable,
950
1277
  args: [{
951
1278
  providedIn: 'root'
952
1279
  }]
953
- }], ctorParameters: function () { return [{ type: AgentService }]; }, propDecorators: { directionsRenders: [{
1280
+ }], ctorParameters: function () { return [{ type: AgentService }, { type: i2__namespace.MapDirectionsService }, { type: i3__namespace.HttpClient }]; }, propDecorators: { directionsRenders: [{
954
1281
  type: i0.ViewChildren,
955
1282
  args: ['directionsRender']
956
1283
  }] } });
@@ -973,7 +1300,7 @@
973
1300
  return StatusPillComponent;
974
1301
  }());
975
1302
  /** @nocollapse */ StatusPillComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: StatusPillComponent, deps: [], target: i0__namespace.ɵɵFactoryTarget.Component });
976
- /** @nocollapse */ StatusPillComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: StatusPillComponent, selector: "status-pill", inputs: { status: "status" }, ngImport: i0__namespace, template: "<div [ngClass]=\"getStatusPillClass(status)\">{{ getStatusLabel(status) }}</div>\n", styles: [".status-pill{background-color:#555;padding:.1rem .5rem;border-radius:1rem;font-size:.7rem;color:#fff}.complete,.kyc-request-accepted,.kyc-result-approved{background-color:var(--tui-positive)}.rejected,.kyc-request-rejected,.kyc-result-rejected,.kyc-rejected{background-color:var(--tui-negative)}.auditing,.on-going,.kyc-result-partial-update,.kyc-resut-partial-update{background-color:var(--tui-primary)}.after-audit,.waiting,.kyc-result-under-review{background-color:var(--tui-warning-fill);color:#222}\n"], directives: [{ type: i5__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
1303
+ /** @nocollapse */ StatusPillComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: StatusPillComponent, selector: "status-pill", inputs: { status: "status" }, ngImport: i0__namespace, template: "<div [ngClass]=\"getStatusPillClass(status)\">{{ getStatusLabel(status) }}</div>\n", styles: [".status-pill{background-color:#555;padding:.1rem .5rem;border-radius:1rem;font-size:.7rem;color:#fff}.complete,.kyc-request-accepted,.kyc-result-approved{background-color:var(--tui-positive)}.rejected,.kyc-request-rejected,.kyc-result-rejected,.kyc-rejected{background-color:var(--tui-negative)}.auditing,.on-going,.kyc-result-partial-update,.kyc-resut-partial-update{background-color:var(--tui-primary)}.after-audit,.waiting,.kyc-result-under-review{background-color:var(--tui-warning-fill);color:#222}\n"], directives: [{ type: i6__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
977
1304
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: StatusPillComponent, decorators: [{
978
1305
  type: i0.Component,
979
1306
  args: [{
@@ -986,39 +1313,12 @@
986
1313
  }] } });
987
1314
 
988
1315
  var CustomerDetailsComponent = /** @class */ (function () {
989
- function CustomerDetailsComponent(agentService, mapService, cdr) {
1316
+ function CustomerDetailsComponent(agentService, googleMapsService, openStreetMapsService, cdr) {
990
1317
  this.agentService = agentService;
991
- this.mapService = mapService;
1318
+ this.googleMapsService = googleMapsService;
1319
+ this.openStreetMapsService = openStreetMapsService;
992
1320
  this.cdr = cdr;
993
- this.customer = {
994
- agent_id: 'sparkcpaital_dev_agent_1',
995
- client_name: 'sparkcpaital_dev',
996
- extras: {},
997
- session_status: '',
998
- task_completed_time: '',
999
- task_creation_time: '1679469532.340057',
1000
- task_details: {
1001
- customer_details: {
1002
- email: 'gaurang.thakkar1997@gmail.com',
1003
- phone: '9930607033',
1004
- lc_lg_code: 'LC123456',
1005
- branch_code: 'HDFC56475H',
1006
- business_code: 'ABCD12345H'
1007
- },
1008
- link_details: {
1009
- queryParams: {
1010
- autoSendMobileOtp: true,
1011
- client_id: 'sparkcpaital_dev',
1012
- mobileOtpVerification: true,
1013
- mobile_number: '9930607033',
1014
- user_id: '9930607033'
1015
- }
1016
- }
1017
- },
1018
- task_id: 'sparkcpaital_dev_4632c291-1b4c-4f5b-bb95-f9acaab45e27',
1019
- task_schedule_time: '1679469532.340057',
1020
- user_id: '9930607033'
1021
- };
1321
+ this.customer = {};
1022
1322
  this.viewTaskDetails = [];
1023
1323
  this.nextStep = new i0.EventEmitter();
1024
1324
  this.removeTask = new i0.EventEmitter();
@@ -1060,16 +1360,22 @@
1060
1360
  this.nextStep.emit(e);
1061
1361
  };
1062
1362
  CustomerDetailsComponent.prototype.close = function () {
1363
+ var _a, _b;
1063
1364
  this.agentService.isShowTaskDetails = undefined;
1064
- this.mapService.plotDirectionsForSelectedTask(null);
1365
+ if (((_b = (_a = this.agentService.config) === null || _a === void 0 ? void 0 : _a.dashboard) === null || _b === void 0 ? void 0 : _b.mapType) == 'google-maps') {
1366
+ this.googleMapsService.plotDirectionsForSelectedTask(null);
1367
+ }
1368
+ else {
1369
+ this.openStreetMapsService.plotDirectionsForSelectedTask(null);
1370
+ }
1065
1371
  };
1066
1372
  CustomerDetailsComponent.prototype.handleOnClickRemoveTask = function (task) {
1067
1373
  this.removeTask.emit(task);
1068
1374
  };
1069
1375
  return CustomerDetailsComponent;
1070
1376
  }());
1071
- /** @nocollapse */ CustomerDetailsComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerDetailsComponent, deps: [{ token: AgentService }, { token: MapService }, { token: i0__namespace.ChangeDetectorRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
1072
- /** @nocollapse */ CustomerDetailsComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CustomerDetailsComponent, selector: "customer-details", inputs: { customer: "customer", config: "config" }, outputs: { nextStep: "nextStep", removeTask: "removeTask" }, usesOnChanges: true, ngImport: i0__namespace, template: "<div class=\"customer-details-wrapper\">\n <div class=\"customer-details-heading\">User Details</div>\n <div class=\"customer-details-body\">\n <div class=\"customer-details-user-id\">\n <kwikui-label-value-pair\n [data]=\"customer\"\n [field]=\"config?.dashboard?.taskIdentifier ?? {value:'$.user_id', type: 'string'} \"\n ></kwikui-label-value-pair>\n\n <status-pill\n *ngIf=\"config?.dashboard?.isShowTaskStatus\"\n [status]=\"customer.session_status\"\n ></status-pill>\n </div>\n\n <div class=\"customer-details-table\">\n <div\n class=\"customer-details-table-data\"\n *ngFor=\"let taskData of viewTaskDetails\"\n >\n <kwikui-label-value-pair\n [field]=\"taskData\"\n [data]=\"customer\"\n ></kwikui-label-value-pair>\n </div>\n </div>\n\n <div class=\"customer-details-date\">\n Created at: {{ getTaskCreationTime(customer) }}\n </div>\n\n <div class=\"customer-details-actions\">\n <div class=\"customer-details-task-buttons\">\n <kwikui-button\n *ngIf=\"config.dashboard?.isAllowRemoveTask\"\n [icon]=\"'tuiIconTrash2'\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"handleOnClickRemoveTask(customer)\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"config.dashboard?.isShowCopyLink\"\n icon=\"tuiIconCopy\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"\n handleOnClickNext({\n customer: customer,\n stepType: 'SHARE_JOURNEY_LINK'\n })\n \"\n ></kwikui-button>\n </div>\n <div class=\"customer-details-journey-buttons\">\n <kwikui-button\n *ngIf=\"\n config.dashboard?.isShowMaps &&\n customer?.task_details?.customer_details?.location\n \"\n label=\"Show Directions\"\n appearance=\"flat\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n goToMaps(customer?.task_details?.customer_details?.location)\n \"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"\n config.dashboard?.isAllowStartJourney &&\n agentService.canStartJourney(customer.session_status)\n \"\n label=\"Start Journey\"\n appearance=\"primary\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n handleOnClickNext({ customer: customer, stepType: 'START_JOURNEY' })\n \"\n ></kwikui-button>\n </div>\n </div>\n </div>\n</div>\n", styles: [".customer-details-wrapper{display:flex;flex-direction:column;align-items:stretch;overflow:auto;grid-gap:.5rem;gap:.5rem;padding:1.5rem;height:100%;width:100%}.customer-details-wrapper .customer-details-heading{display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding:1rem 0;font-size:1.5rem;font-weight:600}.customer-details-wrapper .customer-details-body{display:flex;flex-direction:column;grid-gap:1.25rem;gap:1.25rem}.customer-details-wrapper .customer-details-body .customer-details-user-id{display:flex;flex-direction:row;grid-gap:.6rem;gap:.6rem;align-items:center;font-size:1.25rem;font-weight:500;padding:.5rem 0}.customer-details-wrapper .customer-details-body .customer-details-table{display:flex;grid-gap:.5rem;gap:.5rem;flex-direction:column}.customer-details-wrapper .customer-details-body .customer-details-table .customer-details-table-data .customer-details-table-detail-name{font-weight:500}.customer-details-wrapper .customer-details-body .customer-details-table .customer-details-table-data .customer-details-table-detail-value{word-wrap:break-word}.customer-details-wrapper .customer-details-body .customer-details-date{padding-top:1rem}.customer-details-wrapper .customer-details-body .customer-details-actions{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center}.customer-details-wrapper .customer-details-body .customer-details-actions .customer-details-task-buttons{display:flex;flex-direction:row;align-items:center;justify-content:flex-start;padding:1rem 0}.customer-details-wrapper .customer-details-body .customer-details-actions .customer-details-journey-buttons{padding-right:.2rem;display:flex;flex-direction:row;grid-gap:.2rem;gap:.2rem;align-items:center;justify-content:flex-end}.customer-details-wrapper .customer-details-body .customer-details-actions .customer-details-journey-buttons .customer-share-link{font-size:.7rem}::-webkit-scrollbar{width:8px;height:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}\n"], components: [{ type: i3__namespace.KwikUILabelValuePairComponent, selector: "kwikui-label-value-pair", inputs: ["field", "data"] }, { type: StatusPillComponent, selector: "status-pill", inputs: ["status"] }, { type: i3__namespace.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["appearance", "class", "disabled", "icon", "iconRight", "id", "label", "shape", "showLoader", "size", "styles", "type"], outputs: ["onClick"] }], directives: [{ type: i5__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], changeDetection: i0__namespace.ChangeDetectionStrategy.Default });
1377
+ /** @nocollapse */ CustomerDetailsComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerDetailsComponent, deps: [{ token: AgentService }, { token: GoogleMapsService }, { token: OpenStreetMapsService }, { token: i0__namespace.ChangeDetectorRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
1378
+ /** @nocollapse */ CustomerDetailsComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CustomerDetailsComponent, selector: "customer-details", inputs: { customer: "customer", config: "config" }, outputs: { nextStep: "nextStep", removeTask: "removeTask" }, usesOnChanges: true, ngImport: i0__namespace, template: "<div class=\"customer-details-wrapper\">\n <div class=\"customer-details-heading\">User Details</div>\n <div class=\"customer-details-body\">\n <div class=\"customer-details-user-id\">\n <kwikui-label-value-pair\n [data]=\"customer\"\n [field]=\"config?.dashboard?.taskIdentifier ?? {value:'$.user_id', type: 'string'} \"\n ></kwikui-label-value-pair>\n\n <status-pill\n *ngIf=\"config?.dashboard?.isShowTaskStatus\"\n [status]=\"customer.session_status\"\n ></status-pill>\n </div>\n\n <div class=\"customer-details-table\">\n <div\n class=\"customer-details-table-data\"\n *ngFor=\"let taskData of viewTaskDetails\"\n >\n <kwikui-label-value-pair\n [field]=\"taskData\"\n [data]=\"customer\"\n ></kwikui-label-value-pair>\n </div>\n </div>\n\n <div class=\"customer-details-date\">\n Created at: {{ getTaskCreationTime(customer) }}\n </div>\n\n <div class=\"customer-details-actions\">\n <div class=\"customer-details-task-buttons\">\n <kwikui-button\n *ngIf=\"config.dashboard?.isAllowRemoveTask\"\n [icon]=\"'tuiIconTrash2'\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"handleOnClickRemoveTask(customer)\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"config.dashboard?.isShowCopyLink\"\n icon=\"tuiIconCopy\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"\n handleOnClickNext({\n customer: customer,\n stepType: 'SHARE_JOURNEY_LINK'\n })\n \"\n ></kwikui-button>\n </div>\n <div class=\"customer-details-journey-buttons\">\n <kwikui-button\n *ngIf=\"\n config.dashboard?.isShowMaps &&\n customer?.isValidLocation\n \"\n label=\"Show Directions\"\n appearance=\"flat\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n goToMaps(customer?.googleMapsUrl)\n \"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"\n config.dashboard?.isAllowStartJourney &&\n agentService.canStartJourney(customer.session_status)\n \"\n label=\"Start Journey\"\n appearance=\"primary\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n handleOnClickNext({ customer: customer, stepType: 'START_JOURNEY' })\n \"\n ></kwikui-button>\n </div>\n </div>\n </div>\n</div>\n", styles: [".customer-details-wrapper{display:flex;flex-direction:column;align-items:stretch;overflow:auto;grid-gap:.5rem;gap:.5rem;padding:1.5rem;height:100%;width:100%}.customer-details-wrapper .customer-details-heading{display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding:1rem 0;font-size:1.5rem;font-weight:600}.customer-details-wrapper .customer-details-body{display:flex;flex-direction:column;grid-gap:1.25rem;gap:1.25rem}.customer-details-wrapper .customer-details-body .customer-details-user-id{display:flex;flex-direction:row;grid-gap:.6rem;gap:.6rem;align-items:center;font-size:1.25rem;font-weight:500;padding:.5rem 0}.customer-details-wrapper .customer-details-body .customer-details-table{display:flex;grid-gap:.5rem;gap:.5rem;flex-direction:column}.customer-details-wrapper .customer-details-body .customer-details-table .customer-details-table-data .customer-details-table-detail-name{font-weight:500}.customer-details-wrapper .customer-details-body .customer-details-table .customer-details-table-data .customer-details-table-detail-value{word-wrap:break-word}.customer-details-wrapper .customer-details-body .customer-details-date{padding-top:1rem}.customer-details-wrapper .customer-details-body .customer-details-actions{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center}.customer-details-wrapper .customer-details-body .customer-details-actions .customer-details-task-buttons{display:flex;flex-direction:row;align-items:center;justify-content:flex-start;padding:1rem 0}.customer-details-wrapper .customer-details-body .customer-details-actions .customer-details-journey-buttons{padding-right:.2rem;display:flex;flex-direction:row;grid-gap:.2rem;gap:.2rem;align-items:center;justify-content:flex-end}.customer-details-wrapper .customer-details-body .customer-details-actions .customer-details-journey-buttons .customer-share-link{font-size:.7rem}::-webkit-scrollbar{width:8px;height:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}\n"], components: [{ type: i4__namespace.KwikUILabelValuePairComponent, selector: "kwikui-label-value-pair", inputs: ["field", "data"] }, { type: StatusPillComponent, selector: "status-pill", inputs: ["status"] }, { type: i4__namespace.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["appearance", "class", "disabled", "icon", "iconRight", "id", "label", "shape", "showLoader", "size", "styles", "type"], outputs: ["onClick"] }], directives: [{ type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i6__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }], changeDetection: i0__namespace.ChangeDetectionStrategy.Default });
1073
1379
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerDetailsComponent, decorators: [{
1074
1380
  type: i0.Component,
1075
1381
  args: [{
@@ -1078,7 +1384,7 @@
1078
1384
  styleUrls: ['./customer-details.component.scss'],
1079
1385
  changeDetection: i0.ChangeDetectionStrategy.Default
1080
1386
  }]
1081
- }], ctorParameters: function () { return [{ type: AgentService }, { type: MapService }, { type: i0__namespace.ChangeDetectorRef }]; }, propDecorators: { customer: [{
1387
+ }], ctorParameters: function () { return [{ type: AgentService }, { type: GoogleMapsService }, { type: OpenStreetMapsService }, { type: i0__namespace.ChangeDetectorRef }]; }, propDecorators: { customer: [{
1082
1388
  type: i0.Input
1083
1389
  }], config: [{
1084
1390
  type: i0.Input
@@ -1089,8 +1395,9 @@
1089
1395
  }] } });
1090
1396
 
1091
1397
  var CustomerTileComponent = /** @class */ (function () {
1092
- function CustomerTileComponent(mapService, agentService, hostElement) {
1093
- this.mapService = mapService;
1398
+ function CustomerTileComponent(googleMapsService, openStreetMapsService, agentService, hostElement) {
1399
+ this.googleMapsService = googleMapsService;
1400
+ this.openStreetMapsService = openStreetMapsService;
1094
1401
  this.agentService = agentService;
1095
1402
  this.hostElement = hostElement;
1096
1403
  this.customer = {};
@@ -1113,17 +1420,33 @@
1113
1420
  this.viewTaskDetails =
1114
1421
  (_c = (_b = (_a = this.config) === null || _a === void 0 ? void 0 : _a.dashboard) === null || _b === void 0 ? void 0 : _b.viewTaskDetails) !== null && _c !== void 0 ? _c : this.viewTaskDetails;
1115
1422
  };
1116
- CustomerTileComponent.prototype.getTaskDetails = function (taskData) {
1117
- return kwikidToolkit.getObjectValueFromPath(this.customer, taskData);
1118
- };
1119
1423
  CustomerTileComponent.prototype.openDetails = function () {
1424
+ var _a, _b;
1425
+ if (((_b = (_a = this.agentService.config) === null || _a === void 0 ? void 0 : _a.dashboard) === null || _b === void 0 ? void 0 : _b.mapType) == 'google-maps') {
1426
+ this.openGoogleMapsDetails();
1427
+ }
1428
+ else {
1429
+ this.plotOpenStreetMapsDirection();
1430
+ }
1431
+ };
1432
+ CustomerTileComponent.prototype.openGoogleMapsDetails = function () {
1120
1433
  if (this.agentService.isShowTaskDetails !== this.index) {
1121
1434
  this.agentService.isShowTaskDetails = this.index;
1122
- this.mapService.plotDirectionsForSelectedTask(this.index);
1435
+ this.googleMapsService.plotDirectionsForSelectedTask(this.index);
1123
1436
  }
1124
1437
  else {
1125
1438
  this.agentService.isShowTaskDetails = undefined;
1126
- this.mapService.plotDirectionsForSelectedTask(null);
1439
+ this.googleMapsService.plotDirectionsForSelectedTask(null);
1440
+ }
1441
+ };
1442
+ CustomerTileComponent.prototype.plotOpenStreetMapsDirection = function () {
1443
+ if (this.agentService.isShowTaskDetails !== this.index) {
1444
+ this.agentService.isShowTaskDetails = this.index;
1445
+ this.openStreetMapsService.plotDirectionsForSelectedTask(this.index);
1446
+ }
1447
+ else {
1448
+ this.agentService.isShowTaskDetails = undefined;
1449
+ this.openStreetMapsService.plotDirectionsForSelectedTask(null);
1127
1450
  }
1128
1451
  };
1129
1452
  CustomerTileComponent.prototype.goToMaps = function (location) {
@@ -1137,8 +1460,8 @@
1137
1460
  };
1138
1461
  return CustomerTileComponent;
1139
1462
  }());
1140
- /** @nocollapse */ CustomerTileComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerTileComponent, deps: [{ token: MapService }, { token: AgentService }, { token: i0__namespace.ElementRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
1141
- /** @nocollapse */ CustomerTileComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CustomerTileComponent, selector: "customer-tile", inputs: { customer: "customer", index: "index", config: "config" }, outputs: { nextStep: "nextStep", removeTask: "removeTask" }, host: { listeners: { "window:resize": "windowResizeWatcher($event)" } }, ngImport: i0__namespace, template: "<div\n [ngClass]=\"\n index == agentService.isShowTaskDetails\n ? 'customer-tile-wrapper customer-tile-active'\n : 'customer-tile-wrapper'\n \"\n>\n <div class=\"customer-tile-primary-container\">\n <div class=\"customer-tile-primary-container-data\">\n <div class=\"customer-tile-primary-container-userid\">\n <kwikui-label-value-pair\n [data]=\"customer\"\n [field]=\"config?.dashboard?.taskIdentifier ?? {value:'$.user_id', type: 'string'} \"\n ></kwikui-label-value-pair>\n </div>\n <status-pill\n *ngIf=\"config?.dashboard?.isShowTaskStatus\"\n [status]=\"customer.session_status\"\n ></status-pill>\n </div>\n <kwikui-button\n *ngIf=\"!agentService.isMobileView && !agentService.showMapview\"\n [icon]=\"\n agentService.isShowTaskDetails == index\n ? 'tuiIconChevronLeftLarge'\n : 'tuiIconChevronRightLarge'\n \"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"openDetails()\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"agentService.isMobileView || agentService.showMapview\"\n [icon]=\"\n agentService.isShowTaskDetails == index\n ? 'tuiIconChevronUpLarge'\n : 'tuiIconChevronDownLarge'\n \"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"openDetails()\"\n ></kwikui-button>\n </div>\n <div\n [ngClass]=\"\n index == agentService.isShowTaskDetails &&\n (agentService.isMobileView || agentService.showMapview)\n ? 'customer-tile-secondary-container'\n : 'data-collasped'\n \"\n >\n <div class=\"customer-tile-secondary-container-data\">\n <div\n *ngFor=\"let taskData of viewTaskDetails\"\n class=\"customer-tile-secondary-container-custom-details\"\n >\n <kwikui-label-value-pair\n [field]=\"taskData\"\n [data]=\"customer\"\n ></kwikui-label-value-pair>\n </div>\n <div\n *ngIf=\"\n agentService.config?.dashboard?.isShowMaps &&\n agentService.config?.dashboard?.isShowDistanceAndTime &&\n mapService.getSelectedTaskDistanceAndTime()\n \"\n class=\"customer-tile-secondary-container-custom-details\"\n >\n Distance: {{ mapService.getSelectedTaskDistanceAndTime()?.distance }} |\n Time: {{ mapService.getSelectedTaskDistanceAndTime()?.time }}\n </div>\n </div>\n <div class=\"customer-tile-secondary-container-actions\">\n <div class=\"customer-tile-secondary-container-task-buttons\">\n <kwikui-button\n *ngIf=\"config.dashboard?.isAllowRemoveTask\"\n [icon]=\"'tuiIconTrash2'\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"handleOnClickRemoveTask(customer)\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"config.dashboard?.isShowCopyLink\"\n icon=\"tuiIconCopy\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"\n handleOnClickNext({\n customer: customer,\n stepType: 'SHARE_JOURNEY_LINK'\n })\n \"\n ></kwikui-button>\n </div>\n <div class=\"customer-tile-secondary-container-journey-buttons\">\n <kwikui-button\n *ngIf=\"\n config.dashboard?.isShowMaps &&\n customer?.task_details?.customer_details?.location\n \"\n label=\"Show Directions\"\n appearance=\"flat\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"goToMaps(customer.task_details.customer_details.location)\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"\n config.dashboard?.isAllowStartJourney &&\n agentService.canStartJourney(customer.session_status)\n \"\n label=\"Start Journey\"\n appearance=\"primary\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n handleOnClickNext({ customer: customer, stepType: 'START_JOURNEY' })\n \"\n ></kwikui-button>\n </div>\n </div>\n </div>\n</div>\n", styles: [".customer-tile-wrapper{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:stretch;flex:1;overflow:auto;grid-gap:.5rem;gap:.5rem;padding:1rem;border-bottom:.5px solid #ddd}.customer-tile-wrapper .customer-tile-primary-container{display:flex;grid-gap:.5rem;gap:.5rem;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;width:100%;height:100%}.customer-tile-wrapper .customer-tile-primary-container .customer-tile-primary-container-data{padding-left:.2rem;grid-gap:.6rem;gap:.6rem;display:flex;flex-direction:row;flex-wrap:wrap;align-content:stretch;justify-content:space-evenly;align-items:center}.customer-tile-wrapper .customer-tile-primary-container .customer-tile-primary-container-data .customer-tile-primary-container-userid{font-weight:500;font-size:1.1rem;line-height:1rem}.customer-tile-wrapper .customer-tile-secondary-container{width:100%;height:100%;display:flex;flex-direction:column;overflow:auto;grid-gap:.5rem;gap:.5rem}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-data{padding:.4rem .2rem;display:flex;flex-direction:column;font-size:.7rem;grid-gap:.3rem;gap:.3rem}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-data .customer-tile-secondary-container-custom-details{width:100%;height:100%;line-height:.9rem;word-wrap:break-word}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-task-buttons{display:flex;flex-direction:row;align-items:center;justify-content:flex-start}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-journey-buttons{padding-right:.2rem;display:flex;flex-direction:row;grid-gap:.2rem;gap:.2rem;align-items:center;justify-content:flex-end}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-journey-buttons .customer-share-link{font-size:.7rem}.customer-tile-wrapper .data-collasped{display:none}.customer-tile-active{background-color:#dcedfd}\n"], components: [{ type: i3__namespace.KwikUILabelValuePairComponent, selector: "kwikui-label-value-pair", inputs: ["field", "data"] }, { type: StatusPillComponent, selector: "status-pill", inputs: ["status"] }, { type: i3__namespace.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["appearance", "class", "disabled", "icon", "iconRight", "id", "label", "shape", "showLoader", "size", "styles", "type"], outputs: ["onClick"] }], directives: [{ type: i5__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i5__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
1463
+ /** @nocollapse */ CustomerTileComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerTileComponent, deps: [{ token: GoogleMapsService }, { token: OpenStreetMapsService }, { token: AgentService }, { token: i0__namespace.ElementRef }], target: i0__namespace.ɵɵFactoryTarget.Component });
1464
+ /** @nocollapse */ CustomerTileComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CustomerTileComponent, selector: "customer-tile", inputs: { customer: "customer", index: "index", config: "config" }, outputs: { nextStep: "nextStep", removeTask: "removeTask" }, host: { listeners: { "window:resize": "windowResizeWatcher($event)" } }, ngImport: i0__namespace, template: "<div\n [ngClass]=\"\n index == agentService.isShowTaskDetails\n ? 'customer-tile-wrapper customer-tile-active'\n : 'customer-tile-wrapper'\n \"\n>\n <div class=\"customer-tile-primary-container\">\n <div class=\"customer-tile-primary-container-data\">\n <div class=\"customer-tile-primary-container-userid\">\n <kwikui-label-value-pair\n [data]=\"customer\"\n [field]=\"config?.dashboard?.taskIdentifier ?? {value:'$.user_id', type: 'string'} \"\n ></kwikui-label-value-pair>\n </div>\n <status-pill\n *ngIf=\"config?.dashboard?.isShowTaskStatus\"\n [status]=\"customer.session_status\"\n ></status-pill>\n </div>\n <kwikui-button\n *ngIf=\"!agentService.isMobileView && !agentService.showMapview\"\n [icon]=\"\n agentService.isShowTaskDetails == index\n ? 'tuiIconChevronLeftLarge'\n : 'tuiIconChevronRightLarge'\n \"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"openDetails()\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"agentService.isMobileView || agentService.showMapview\"\n [icon]=\"\n agentService.isShowTaskDetails == index\n ? 'tuiIconChevronUpLarge'\n : 'tuiIconChevronDownLarge'\n \"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"openDetails()\"\n ></kwikui-button>\n </div>\n <div\n [ngClass]=\"\n index == agentService.isShowTaskDetails &&\n (agentService.isMobileView || agentService.showMapview)\n ? 'customer-tile-secondary-container'\n : 'data-collasped'\n \"\n >\n <div class=\"customer-tile-secondary-container-data\">\n <div\n *ngFor=\"let taskData of viewTaskDetails\"\n class=\"customer-tile-secondary-container-custom-details\"\n >\n <kwikui-label-value-pair\n [field]=\"taskData\"\n [data]=\"customer\"\n ></kwikui-label-value-pair>\n </div>\n <!-- <div\n *ngIf=\"\n agentService.config?.dashboard?.maps?.sho &&\n agentService.config?.dashboard?.isShowDistanceAndTime &&\n openStreetMapsService.getSelectedTaskDistanceAndTime()\n \"\n class=\"customer-tile-secondary-container-custom-details\"\n >\n Distance: {{ openStreetMapsService.getSelectedTaskDistanceAndTime()?.distance }} |\n Time: {{ openStreetMapsService.getSelectedTaskDistanceAndTime()?.time }}\n </div> -->\n </div>\n <div class=\"customer-tile-secondary-container-actions\">\n <div class=\"customer-tile-secondary-container-task-buttons\">\n <kwikui-button\n *ngIf=\"config.dashboard?.isAllowRemoveTask\"\n [icon]=\"'tuiIconTrash2'\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"handleOnClickRemoveTask(customer)\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"config.dashboard?.isShowCopyLink\"\n icon=\"tuiIconCopy\"\n [shape]=\"'rounded'\"\n appearance=\"icon\"\n size=\"s\"\n (onClick)=\"\n handleOnClickNext({\n customer: customer,\n stepType: 'SHARE_JOURNEY_LINK'\n })\n \"\n ></kwikui-button>\n </div>\n <div class=\"customer-tile-secondary-container-journey-buttons\">\n <kwikui-button\n *ngIf=\"config.dashboard?.isShowMaps && customer?.isValidLocation\"\n label=\"Show Directions\"\n appearance=\"flat\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"goToMaps(customer.googleMapsUrl)\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"\n config.dashboard?.isAllowStartJourney &&\n agentService.canStartJourney(customer.session_status)\n \"\n label=\"Start Journey\"\n appearance=\"primary\"\n size=\"s\"\n styles=\"font-size:0.7rem;\"\n (onClick)=\"\n handleOnClickNext({ customer: customer, stepType: 'START_JOURNEY' })\n \"\n ></kwikui-button>\n </div>\n </div>\n </div>\n</div>\n", styles: [".customer-tile-wrapper{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:stretch;flex:1;overflow:auto;grid-gap:.5rem;gap:.5rem;padding:1rem;border-bottom:.5px solid #ddd}.customer-tile-wrapper .customer-tile-primary-container{display:flex;grid-gap:.5rem;gap:.5rem;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;width:100%;height:100%}.customer-tile-wrapper .customer-tile-primary-container .customer-tile-primary-container-data{padding-left:.2rem;grid-gap:.6rem;gap:.6rem;display:flex;flex-direction:row;flex-wrap:wrap;align-content:stretch;justify-content:space-evenly;align-items:center}.customer-tile-wrapper .customer-tile-primary-container .customer-tile-primary-container-data .customer-tile-primary-container-userid{font-weight:500;font-size:1.1rem;line-height:1rem}.customer-tile-wrapper .customer-tile-secondary-container{width:100%;height:100%;display:flex;flex-direction:column;overflow:auto;grid-gap:.5rem;gap:.5rem}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-data{padding:.4rem .2rem;display:flex;flex-direction:column;font-size:.7rem;grid-gap:.3rem;gap:.3rem}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-data .customer-tile-secondary-container-custom-details{width:100%;height:100%;line-height:.9rem;word-wrap:break-word}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions{display:flex;flex-wrap:wrap;justify-content:space-between;align-items:center}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-task-buttons{display:flex;flex-direction:row;align-items:center;justify-content:flex-start}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-journey-buttons{padding-right:.2rem;display:flex;flex-direction:row;grid-gap:.2rem;gap:.2rem;align-items:center;justify-content:flex-end}.customer-tile-wrapper .customer-tile-secondary-container .customer-tile-secondary-container-actions .customer-tile-secondary-container-journey-buttons .customer-share-link{font-size:.7rem}.customer-tile-wrapper .data-collasped{display:none}.customer-tile-active{background-color:#dcedfd}\n"], components: [{ type: i4__namespace.KwikUILabelValuePairComponent, selector: "kwikui-label-value-pair", inputs: ["field", "data"] }, { type: StatusPillComponent, selector: "status-pill", inputs: ["status"] }, { type: i4__namespace.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["appearance", "class", "disabled", "icon", "iconRight", "id", "label", "shape", "showLoader", "size", "styles", "type"], outputs: ["onClick"] }], directives: [{ type: i6__namespace.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i6__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }] });
1142
1465
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerTileComponent, decorators: [{
1143
1466
  type: i0.Component,
1144
1467
  args: [{
@@ -1146,7 +1469,7 @@
1146
1469
  templateUrl: './customer-tile.component.html',
1147
1470
  styleUrls: ['./customer-tile.component.scss']
1148
1471
  }]
1149
- }], ctorParameters: function () { return [{ type: MapService }, { type: AgentService }, { type: i0__namespace.ElementRef }]; }, propDecorators: { windowResizeWatcher: [{
1472
+ }], ctorParameters: function () { return [{ type: GoogleMapsService }, { type: OpenStreetMapsService }, { type: AgentService }, { type: i0__namespace.ElementRef }]; }, propDecorators: { windowResizeWatcher: [{
1150
1473
  type: i0.HostListener,
1151
1474
  args: ['window:resize', ['$event']]
1152
1475
  }], customer: [{
@@ -1226,64 +1549,74 @@
1226
1549
  }] });
1227
1550
 
1228
1551
  var CustomerListComponent = /** @class */ (function () {
1229
- function CustomerListComponent(mapService, agentService) {
1230
- this.mapService = mapService;
1552
+ function CustomerListComponent(googleMapsService, openStreetMapsService, agentService) {
1553
+ this.googleMapsService = googleMapsService;
1554
+ this.openStreetMapsService = openStreetMapsService;
1231
1555
  this.agentService = agentService;
1232
1556
  this.nextStep = new i0.EventEmitter();
1233
1557
  this.removeTask = new i0.EventEmitter();
1234
1558
  this.filterTaskList = new i0.EventEmitter();
1235
1559
  this.filteredData = [];
1236
- this.formGroup = new i6.FormGroup({});
1560
+ this.formGroup = new i7.FormGroup({});
1237
1561
  this.fromDate = this.getDate(null);
1238
1562
  this.toDate = this.getDate(null);
1239
- this.dateRangeFormControl = new i6.FormControl({
1240
- value: new i9.TuiDayRange(new i9.TuiDay(new Date().getFullYear(), new Date().getMonth(), new Date().getDate()), new i9.TuiDay(new Date().getFullYear(), new Date().getMonth(), new Date().getDate())),
1563
+ this.dateRangeFormControl = new i7.FormControl({
1564
+ value: new i10.TuiDayRange(new i10.TuiDay(new Date().getFullYear(), new Date().getMonth(), new Date().getDate()), new i10.TuiDay(new Date().getFullYear(), new Date().getMonth(), new Date().getDate())),
1241
1565
  disabled: false
1242
1566
  });
1243
1567
  this.formGroup.addControl('dateRange', this.dateRangeFormControl);
1244
- this.searchFormControl = new i6.FormControl('');
1568
+ this.searchFormControl = new i7.FormControl('');
1245
1569
  this.formGroup.addControl('search', this.searchFormControl);
1246
1570
  }
1247
- CustomerListComponent.prototype.ngOnInit = function () { };
1571
+ CustomerListComponent.prototype.ngOnInit = function () {
1572
+ };
1248
1573
  CustomerListComponent.prototype.ngAfterViewInit = function () {
1249
1574
  var _this = this;
1250
1575
  setTimeout(function () { return __awaiter(_this, void 0, void 0, function () {
1251
- var _b;
1252
- return __generator(this, function (_c) {
1253
- switch (_c.label) {
1576
+ var _a, _c;
1577
+ return __generator(this, function (_d) {
1578
+ switch (_d.label) {
1254
1579
  case 0:
1255
- if (!this.config.dashboard.isShowMaps) return [3 /*break*/, 3];
1256
- return [4 /*yield*/, this.mapService.initMap()];
1580
+ if (!this.config.dashboard.isShowMaps) return [3 /*break*/, 6];
1581
+ if (!(((_a = this.config.dashboard) === null || _a === void 0 ? void 0 : _a.mapType) == 'open-street')) return [3 /*break*/, 2];
1582
+ return [4 /*yield*/, this.openStreetMapsService.initializeMap()];
1257
1583
  case 1:
1258
- _c.sent();
1259
- _b = this;
1260
- return [4 /*yield*/, this.plotMarkers(this.customers)];
1261
- case 2:
1262
- _b.filteredData = _c.sent();
1584
+ _d.sent();
1263
1585
  return [3 /*break*/, 4];
1586
+ case 2: return [4 /*yield*/, this.googleMapsService.initializeMap()];
1264
1587
  case 3:
1588
+ _d.sent();
1589
+ _d.label = 4;
1590
+ case 4:
1591
+ _c = this;
1592
+ return [4 /*yield*/, this.plotMarkers(this.customers)];
1593
+ case 5:
1594
+ _c.filteredData = _d.sent();
1595
+ return [3 /*break*/, 7];
1596
+ case 6:
1265
1597
  this.filteredData = this.customers;
1266
- _c.label = 4;
1267
- case 4: return [2 /*return*/];
1598
+ _d.label = 7;
1599
+ case 7: return [2 /*return*/];
1268
1600
  }
1269
1601
  });
1270
1602
  }); }, 1000);
1271
1603
  };
1272
1604
  CustomerListComponent.prototype.ngOnChanges = function () {
1273
1605
  return __awaiter(this, void 0, void 0, function () {
1274
- var _b;
1275
- return __generator(this, function (_c) {
1276
- switch (_c.label) {
1606
+ var _c;
1607
+ return __generator(this, function (_d) {
1608
+ switch (_d.label) {
1277
1609
  case 0:
1278
- if (!this.config.dashboard.isShowMaps) return [3 /*break*/, 2];
1279
- _b = this;
1610
+ if (!(this.config.dashboard.isShowMaps &&
1611
+ (this.googleMapsService.map || this.openStreetMapsService.map))) return [3 /*break*/, 2];
1612
+ _c = this;
1280
1613
  return [4 /*yield*/, this.plotMarkers(this.customers)];
1281
1614
  case 1:
1282
- _b.filteredData = _c.sent();
1615
+ _c.filteredData = _d.sent();
1283
1616
  return [3 /*break*/, 3];
1284
1617
  case 2:
1285
1618
  this.filteredData = this.customers;
1286
- _c.label = 3;
1619
+ _d.label = 3;
1287
1620
  case 3: return [2 /*return*/];
1288
1621
  }
1289
1622
  });
@@ -1305,21 +1638,27 @@
1305
1638
  return today;
1306
1639
  };
1307
1640
  CustomerListComponent.prototype.plotMarkers = function (customers) {
1308
- var _a;
1641
+ var _a, _b;
1309
1642
  return __awaiter(this, void 0, void 0, function () {
1310
1643
  var _this = this;
1311
- return __generator(this, function (_b) {
1312
- switch (_b.label) {
1644
+ return __generator(this, function (_c) {
1645
+ switch (_c.label) {
1313
1646
  case 0:
1314
1647
  if (!((_a = this.config.dashboard) === null || _a === void 0 ? void 0 : _a.isPlotCompletedTaskMarkers)) {
1315
1648
  customers = customers.filter(function (customer) {
1316
1649
  return _this.agentService.canPlotMarkers(customer.session_status);
1317
1650
  });
1318
1651
  }
1319
- return [4 /*yield*/, this.mapService.plotDirectionsForAllTasks(customers)];
1652
+ if (!(((_b = this.config.dashboard) === null || _b === void 0 ? void 0 : _b.mapType) == 'open-street')) return [3 /*break*/, 2];
1653
+ return [4 /*yield*/, this.openStreetMapsService.plotDirectionsForAllTasks(customers)];
1320
1654
  case 1:
1321
- customers = _b.sent();
1322
- return [2 /*return*/, customers];
1655
+ customers = _c.sent();
1656
+ return [3 /*break*/, 4];
1657
+ case 2: return [4 /*yield*/, this.googleMapsService.plotDirectionsForAllTasks(customers)];
1658
+ case 3:
1659
+ customers = _c.sent();
1660
+ _c.label = 4;
1661
+ case 4: return [2 /*return*/, customers];
1323
1662
  }
1324
1663
  });
1325
1664
  });
@@ -1351,8 +1690,8 @@
1351
1690
  };
1352
1691
  return CustomerListComponent;
1353
1692
  }());
1354
- /** @nocollapse */ CustomerListComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerListComponent, deps: [{ token: MapService }, { token: AgentService }], target: i0__namespace.ɵɵFactoryTarget.Component });
1355
- /** @nocollapse */ CustomerListComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CustomerListComponent, selector: "customer-list", inputs: { customers: "customers", config: "config" }, outputs: { nextStep: "nextStep", removeTask: "removeTask", filterTaskList: "filterTaskList" }, usesOnChanges: true, ngImport: i0__namespace, template: "<div class=\"customer-list-wrapper\">\n <div class=\"customer-list-filter\" [formGroup]=\"formGroup\">\n <kwikui-input-date-range\n *ngIf=\"config?.dashboard?.isAllowDateFilter\"\n [label]=\"'Date Range'\"\n [id]=\"'dateRange'\"\n [size]=\"'m'\"\n [formControlName]=\"'dateRange'\"\n [formControl]=\"dateRangeFormControl\"\n (getKeyValue)=\"onDateRangeChange($event)\"\n ></kwikui-input-date-range>\n <kwikui-input\n *ngIf=\"config?.dashboard?.isAllowSearchFilter\"\n [label]=\"'Search'\"\n [id]=\"'search'\"\n icon=\"tuiIconSearch\"\n size=\"m\"\n placeholder=\"Search Any Task\"\n [formControlName]=\"'search'\"\n [formControl]=\"searchFormControl\"\n (getKeyValue)=\"onSearchFilter($event)\"\n ></kwikui-input>\n </div>\n\n <div class=\"customer-task-list\">\n <cdk-virtual-scroll-viewport itemSize=\"1\" class=\"customer-task-list-scroll\">\n <div\n *cdkVirtualFor=\"\n let customer of filteredData | filter: searchText;\n index as index\n \"\n >\n <customer-tile\n class=\"example-item\"\n [customer]=\"customer\"\n [config]=\"config\"\n [index]=\"index\"\n (nextStep)=\"handleOnClickNext($event)\"\n (removeTask)=\"handleOnClickRemoveTask($event)\"\n ></customer-tile>\n </div>\n </cdk-virtual-scroll-viewport>\n </div>\n\n <div class=\"customer-list-empty\" *ngIf=\"filteredData.length === 0\">\n {{config?.dashboard?.emptyTaskListMessage ?? '0 Tasks for the given Date.'}}\n </div>\n</div>\n", styles: [".customer-list-wrapper{width:100%;height:100%;display:flex;flex-direction:column}.customer-list-filter{height:-moz-fit-content;height:fit-content;width:100%;display:flex;flex-direction:column;padding:1rem;grid-gap:.8rem;gap:.8rem;border-bottom:.5px solid #ddd}.customer-list-empty{height:100%;width:100%;margin-top:.5rem;font-size:1rem;text-align:center}.customer-task-list{height:100%}.customer-task-list-scroll{height:100%;width:100%}.cdk-virtual-scroll-spacer{height:0!important}.example-item{height:50px}::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}\n"], components: [{ type: i3__namespace.KwikUIInputDateRangeComponent, selector: "kwikui-input-date-range", inputs: ["disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "max", "maxLength", "min", "minLength", "placeholder", "postfix", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i3__namespace.KwikUIInputComponent, selector: "kwikui-input", inputs: ["case", "disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "placeholder", "postfix", "prefix", "properties", "size", "type", "validators"], outputs: ["getKeyValue"] }, { type: i4__namespace.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { type: CustomerTileComponent, selector: "customer-tile", inputs: ["customer", "index", "config"], outputs: ["nextStep", "removeTask"] }], directives: [{ type: i6__namespace.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i6__namespace.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i5__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i6__namespace.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i6__namespace.FormControlName, selector: "[formControlName]", inputs: ["disabled", "formControlName", "ngModel"], outputs: ["ngModelChange"] }, { type: i6__namespace.FormControlDirective, selector: "[formControl]", inputs: ["disabled", "formControl", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { type: i4__namespace.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { type: i4__namespace.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }], pipes: { "filter": Ng2SearchPipe } });
1693
+ /** @nocollapse */ CustomerListComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerListComponent, deps: [{ token: GoogleMapsService }, { token: OpenStreetMapsService }, { token: AgentService }], target: i0__namespace.ɵɵFactoryTarget.Component });
1694
+ /** @nocollapse */ CustomerListComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: CustomerListComponent, selector: "customer-list", inputs: { customers: "customers", config: "config" }, outputs: { nextStep: "nextStep", removeTask: "removeTask", filterTaskList: "filterTaskList" }, usesOnChanges: true, ngImport: i0__namespace, template: "<div class=\"customer-list-wrapper\">\n <div class=\"customer-list-filter\" [formGroup]=\"formGroup\">\n <kwikui-input-date-range\n *ngIf=\"config?.dashboard?.isAllowDateFilter\"\n [label]=\"'Date Range'\"\n [id]=\"'dateRange'\"\n [size]=\"'m'\"\n [formControlName]=\"'dateRange'\"\n [formControl]=\"dateRangeFormControl\"\n (getKeyValue)=\"onDateRangeChange($event)\"\n ></kwikui-input-date-range>\n <kwikui-input\n *ngIf=\"config?.dashboard?.isAllowSearchFilter\"\n [label]=\"'Search'\"\n [id]=\"'search'\"\n icon=\"tuiIconSearch\"\n size=\"m\"\n placeholder=\"Search Any Task\"\n [formControlName]=\"'search'\"\n [formControl]=\"searchFormControl\"\n (getKeyValue)=\"onSearchFilter($event)\"\n ></kwikui-input>\n </div>\n\n <div class=\"customer-task-list\">\n <cdk-virtual-scroll-viewport itemSize=\"1\" class=\"customer-task-list-scroll\">\n <div\n *cdkVirtualFor=\"\n let customer of filteredData | filter: searchText;\n index as index\n \"\n >\n <customer-tile\n class=\"example-item\"\n [customer]=\"customer\"\n [config]=\"config\"\n [index]=\"index\"\n (nextStep)=\"handleOnClickNext($event)\"\n (removeTask)=\"handleOnClickRemoveTask($event)\"\n ></customer-tile>\n </div>\n </cdk-virtual-scroll-viewport>\n </div>\n\n <div class=\"customer-list-empty\" *ngIf=\"filteredData.length === 0\">\n {{config?.dashboard?.emptyTaskListMessage ?? '0 Tasks for the given Date.'}}\n </div>\n</div>\n", styles: [".customer-list-wrapper{width:100%;height:100%;display:flex;flex-direction:column}.customer-list-filter{height:-moz-fit-content;height:fit-content;width:100%;display:flex;flex-direction:column;padding:1rem;grid-gap:.8rem;gap:.8rem;border-bottom:.5px solid #ddd}.customer-list-empty{height:100%;width:100%;margin-top:.5rem;font-size:1rem;text-align:center}.customer-task-list{height:100%}.customer-task-list-scroll{height:100%;width:100%}.cdk-virtual-scroll-spacer{height:0!important}.example-item{height:50px}::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}\n"], components: [{ type: i4__namespace.KwikUIInputDateRangeComponent, selector: "kwikui-input-date-range", inputs: ["disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "max", "maxLength", "min", "minLength", "placeholder", "postfix", "prefix", "properties", "size", "validators"], outputs: ["getKeyValue"] }, { type: i4__namespace.KwikUIInputComponent, selector: "kwikui-input", inputs: ["case", "disabled", "focus", "formControl", "formControlName", "hintContent", "icon", "id", "invalid", "label", "placeholder", "postfix", "prefix", "properties", "size", "type", "validators"], outputs: ["getKeyValue"] }, { type: i5__namespace.CdkVirtualScrollViewport, selector: "cdk-virtual-scroll-viewport", inputs: ["orientation", "appendOnly"], outputs: ["scrolledIndexChange"] }, { type: CustomerTileComponent, selector: "customer-tile", inputs: ["customer", "index", "config"], outputs: ["nextStep", "removeTask"] }], directives: [{ type: i7__namespace.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i7__namespace.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i7__namespace.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i7__namespace.FormControlName, selector: "[formControlName]", inputs: ["disabled", "formControlName", "ngModel"], outputs: ["ngModelChange"] }, { type: i7__namespace.FormControlDirective, selector: "[formControl]", inputs: ["disabled", "formControl", "ngModel"], outputs: ["ngModelChange"], exportAs: ["ngForm"] }, { type: i5__namespace.CdkFixedSizeVirtualScroll, selector: "cdk-virtual-scroll-viewport[itemSize]", inputs: ["itemSize", "minBufferPx", "maxBufferPx"] }, { type: i5__namespace.CdkVirtualForOf, selector: "[cdkVirtualFor][cdkVirtualForOf]", inputs: ["cdkVirtualForOf", "cdkVirtualForTrackBy", "cdkVirtualForTemplate", "cdkVirtualForTemplateCacheSize"] }], pipes: { "filter": Ng2SearchPipe } });
1356
1695
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: CustomerListComponent, decorators: [{
1357
1696
  type: i0.Component,
1358
1697
  args: [{
@@ -1360,7 +1699,7 @@
1360
1699
  templateUrl: './customer-list.component.html',
1361
1700
  styleUrls: ['./customer-list.component.css']
1362
1701
  }]
1363
- }], ctorParameters: function () { return [{ type: MapService }, { type: AgentService }]; }, propDecorators: { customers: [{
1702
+ }], ctorParameters: function () { return [{ type: GoogleMapsService }, { type: OpenStreetMapsService }, { type: AgentService }]; }, propDecorators: { customers: [{
1364
1703
  type: i0.Input
1365
1704
  }], config: [{
1366
1705
  type: i0.Input
@@ -1373,8 +1712,8 @@
1373
1712
  }] } });
1374
1713
 
1375
1714
  var KwikIDAgentDashboardComponent = /** @class */ (function () {
1376
- function KwikIDAgentDashboardComponent(mapService, agentService, httpClient, hostElement, dialogService) {
1377
- this.mapService = mapService;
1715
+ function KwikIDAgentDashboardComponent(googleMapsService, agentService, httpClient, hostElement, dialogService) {
1716
+ this.googleMapsService = googleMapsService;
1378
1717
  this.agentService = agentService;
1379
1718
  this.httpClient = httpClient;
1380
1719
  this.hostElement = hostElement;
@@ -1386,6 +1725,7 @@
1386
1725
  this.removeTask = new i0.EventEmitter();
1387
1726
  this.filterTaskList = new i0.EventEmitter();
1388
1727
  this.loading = true;
1728
+ this.console = console;
1389
1729
  this.open = false;
1390
1730
  this.allFormsData = {};
1391
1731
  this.String = String;
@@ -1401,17 +1741,48 @@
1401
1741
  }
1402
1742
  };
1403
1743
  KwikIDAgentDashboardComponent.prototype.ngOnInit = function () {
1404
- var _this = this;
1405
- var _a, _b, _c, _d, _e, _f;
1406
- this.agentService.config = this.config;
1407
- this.agentService.showMapview =
1408
- (_c = (_b = (_a = this.config) === null || _a === void 0 ? void 0 : _a.dashboard) === null || _b === void 0 ? void 0 : _b.isShowMaps) !== null && _c !== void 0 ? _c : false;
1409
- this.agentService.addTaskForm =
1410
- (_f = (_e = (_d = this.config) === null || _d === void 0 ? void 0 : _d.dashboard) === null || _e === void 0 ? void 0 : _e.addTaskForm) !== null && _f !== void 0 ? _f : this.agentService.addTaskForm;
1411
- this.loading = false;
1412
- setTimeout(function () {
1413
- _this.windowResizeWatcher();
1414
- }, 1000);
1744
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j, _k, _l, _m;
1745
+ return __awaiter(this, void 0, void 0, function () {
1746
+ var _this = this;
1747
+ return __generator(this, function (_o) {
1748
+ this.agentService.config = this.config;
1749
+ this.agentService.showMapview = (_c = (_b = (_a = this.config) === null || _a === void 0 ? void 0 : _a.dashboard) === null || _b === void 0 ? void 0 : _b.isShowMaps) !== null && _c !== void 0 ? _c : false;
1750
+ this.agentService.addTaskForm =
1751
+ (_f = (_e = (_d = this.config) === null || _d === void 0 ? void 0 : _d.dashboard) === null || _e === void 0 ? void 0 : _e.addTaskForm) !== null && _f !== void 0 ? _f : this.agentService.addTaskForm;
1752
+ if (((_h = (_g = this.config) === null || _g === void 0 ? void 0 : _g.dashboard) === null || _h === void 0 ? void 0 : _h.mapType) == 'google-maps' &&
1753
+ kwikidToolkit.isNotEmptyValue((_k = (_j = this.config) === null || _j === void 0 ? void 0 : _j.dashboard) === null || _k === void 0 ? void 0 : _k.googleMapsAPIKey)) {
1754
+ this.loadMaps((_m = (_l = this.config) === null || _l === void 0 ? void 0 : _l.dashboard) === null || _m === void 0 ? void 0 : _m.googleMapsAPIKey).subscribe(function (loaded) {
1755
+ _this.mapsLoaded = loaded;
1756
+ if (loaded) {
1757
+ console.log('Google Maps JavaScript API loaded successfully.');
1758
+ _this.loading = false;
1759
+ // Initialize and render Google Map here
1760
+ }
1761
+ else {
1762
+ console.error('Google Maps JavaScript API failed to load.');
1763
+ _this.loading = false;
1764
+ }
1765
+ });
1766
+ }
1767
+ else {
1768
+ this.mapsLoaded = true;
1769
+ this.loading = false;
1770
+ }
1771
+ setTimeout(function () {
1772
+ _this.windowResizeWatcher();
1773
+ }, 1000);
1774
+ return [2 /*return*/];
1775
+ });
1776
+ });
1777
+ };
1778
+ // Load Google Maps
1779
+ KwikIDAgentDashboardComponent.prototype.loadMaps = function (apiKey) {
1780
+ var url = "https://maps.googleapis.com/maps/api/js?key=" + apiKey + "&v=3.exp&libraries=geometry,drawing,places";
1781
+ this.googleMapsService.apiKey = apiKey;
1782
+ return this.httpClient.jsonp(url, 'callback').pipe(operators.map(function () { return true; }), operators.catchError(function () {
1783
+ console.error('Error loading Google Maps JavaScript API.');
1784
+ return rxjs.of(false);
1785
+ }));
1415
1786
  };
1416
1787
  KwikIDAgentDashboardComponent.prototype.handleOnClickNext = function (e) {
1417
1788
  this.nextStep.emit(e);
@@ -1453,8 +1824,8 @@
1453
1824
  KwikIDAgentDashboardComponent.prototype.handleOnClickViewForms = function (e) { };
1454
1825
  return KwikIDAgentDashboardComponent;
1455
1826
  }());
1456
- /** @nocollapse */ KwikIDAgentDashboardComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardComponent, deps: [{ token: MapService }, { token: AgentService }, { token: i3__namespace$1.HttpClient }, { token: i0__namespace.ElementRef }, { token: i10.TuiDialogService }], target: i0__namespace.ɵɵFactoryTarget.Component });
1457
- /** @nocollapse */ KwikIDAgentDashboardComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: KwikIDAgentDashboardComponent, selector: "kwikid-agent-dashboard", inputs: { config: "config", taskList: "taskList" }, outputs: { nextStep: "nextStep", addTask: "addTask", removeTask: "removeTask", filterTaskList: "filterTaskList" }, host: { listeners: { "window:resize": "windowResizeWatcher($event)" } }, viewQueries: [{ propertyName: "infoWindow", first: true, predicate: googleMaps.MapInfoWindow, descendants: true }, { propertyName: "mapElement", first: true, predicate: ["map"], descendants: true, static: true }], ngImport: i0__namespace, template: "<div class=\"kwikid-agent-dashboard\" *ngIf=\"!loading\">\n <div class=\"wrapper\">\n <header>\n <img\n *ngIf=\"\n agentService.config?.clientLogo &&\n agentService.config?.dashboard?.isShowClientLogo\n \"\n [src]=\"agentService.config.clientLogo\"\n class=\"client-logo\"\n />\n <div\n *ngIf=\"\n !agentService.config.clientLogo ||\n !agentService.config?.dashboard?.isShowClientLogo\n \"\n class=\"client-name\"\n >\n <kwikui-button\n [icon]=\"'tuiIconLink'\"\n appearance=\"mono\"\n size=\"m\"\n ></kwikui-button>\n\n {{ agentService.config.clientName }}\n </div>\n <div class=\"actions\">\n <kwikui-button\n *ngIf=\"agentService.config?.dashboard?.isAllowAddTask\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"primary\"\n [label]=\"agentService.config?.dashboard?.addTaskButtonLabel ?? 'Add User'\"\n [icon]=\"'tuiIconPlus'\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"s\"\n (onClick)=\"showDialog(template)\"\n ></kwikui-button>\n <span (tuiActiveZoneChange)=\"onActiveZone($event)\">\n <kwikui-button\n [icon]=\"'tuiIconSettingsLarge'\"\n (onClick)=\"onClick()\"\n appearance=\"mono\"\n size=\"s\"\n [tuiDropdown]=\"dropdownContent\"\n [tuiDropdownManual]=\"open\"\n (tuiObscured)=\"onObscured($event)\"\n ></kwikui-button>\n <ng-template #dropdownContent>\n <div class=\"menu-dropdown\">\n <div class=\"menu-dropdown-header\">\n <div class=\"menu-dropdown-header-agent-name\">\n {{ agentService.config.agentName }}\n </div>\n <div class=\"menu-dropdown-header-agent-id\">\n Agent ID: {{ agentService.config.agentId }}\n </div>\n </div>\n <hr />\n <div\n class=\"menu-dropdown-body\"\n tuiGroup\n [collapsed]=\"true\"\n [rounded]=\"false\"\n [orientation]=\"'vertical'\"\n [size]=\"'m'\"\n >\n <kwikui-button\n appearance=\"mono\"\n class=\"menu-dropdown-buttons\"\n label=\"Refresh\"\n [icon]=\"'tuiIconRefreshCw'\"\n size=\"m\"\n type=\"button\"\n (onClick)=\"refresh()\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"this.config.dashboard.isShowMaps\"\n id=\"\"\n label=\"{{\n agentService.showMapview ? 'Hide Maps' : 'Show Maps'\n }}\"\n styles=\"\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n icon=\"{{\n agentService.showMapview ? 'tuiIconEyeOff' : 'tuiIconEye'\n }}\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n styles=\"padding: 0rem !important\"\n (onClick)=\"agentService.toggleMapview()\"\n ></kwikui-button>\n </div>\n <div class=\"menu-dropdown-footer\">\n <kwikui-button\n id=\"\"\n label=\"Logout\"\n styles=\"\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n [icon]=\"'tuiIconLogOut'\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"handleOnClickNext({ stepType: 'LOGOUT' })\"\n ></kwikui-button>\n </div>\n </div>\n </ng-template>\n </span>\n </div>\n </header>\n\n <div class=\"dashboard-body\">\n <div [class]=\"agentService.showMapview ? 'map' : 'map-hidden'\">\n <div id=\"map\" style=\"height: 100%\"></div>\n </div>\n\n <div\n class=\"task-details\"\n *ngIf=\"\n !agentService.isMobileView &&\n agentService.isShowTaskDetails != undefined &&\n !agentService.showMapview\n \"\n >\n <customer-details\n [customer]=\"taskList[agentService.isShowTaskDetails]\"\n [config]=\"config\"\n (nextStep)=\"handleOnClickNext($event)\"\n (removeTask)=\"handleOnClickRemoveTask($event)\"\n ></customer-details>\n </div>\n\n <div\n class=\"no-task-details\"\n *ngIf=\"\n !agentService.isMobileView &&\n agentService.isShowTaskDetails == undefined &&\n !agentService.showMapview\n \"\n >\n <img src=\"assets/No-Results.jpg\" class=\"no-task-img\" alt=\"No Task\" />\n <div class=\"\">Select a Task to view it's details.</div>\n </div>\n\n <div class=\"customer-list\">\n <customer-list\n [customers]=\"taskList\"\n [config]=\"config\"\n (nextStep)=\"handleOnClickNext($event)\"\n (removeTask)=\"handleOnClickRemoveTask($event)\"\n (filterTaskList)=\"handleOnFilterTaskList($event)\"\n ></customer-list>\n </div>\n </div>\n </div>\n</div>\n\n<div class=\"kwikid-agent-dashboard-loader\" *ngIf=\"loading\">\n <span class=\"loader\"></span>\n</div>\n\n<ng-template #template let-observer>\n <div class=\"add-task-header\">\n <h2>{{agentService?.addTaskForm?.title ?? \"Create User\"}}</h2>\n <kwikui-button\n icon=\"tuiIconX\"\n id=\"\"\n styles=\"\"\n type=\"button\"\n appearance=\"mono\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"observer.complete()\"\n ></kwikui-button>\n </div>\n <kwikid-form-view\n [allFormsData]=\"allFormsData\"\n [formConfig]=\"agentService.addTaskForm\"\n [isMobileView]=\"true\"\n (onClickViewForms)=\"this.handleOnClickViewForms($event)\"\n (onClickSaveForm)=\"this.handleOnClickSaveForm($event)\"\n ></kwikid-form-view>\n</ng-template>\n", styles: [".kwikid-agent-dashboard{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;width:100%;height:100%;position:relative}.kwikid-agent-dashboard .wrapper{width:100%;height:100%;display:flex;flex-direction:column;align-content:center;justify-content:space-between;align-items:stretch}.kwikid-agent-dashboard .wrapper header{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;grid-column-gap:1rem;column-gap:1rem;padding:.2rem;max-height:4rem;border:1px solid #fafafa;box-shadow:0 2px 10px -6px #000}.kwikid-agent-dashboard .wrapper header .client-logo{height:100%;padding-left:1rem}.kwikid-agent-dashboard .wrapper header .client-name{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;font-size:1rem;font-weight:600}.kwikid-agent-dashboard .wrapper header .actions{display:flex;flex-direction:row;align-items:center}.kwikid-agent-dashboard .wrapper header .actions>*:not(:last-child){margin-right:.5rem}.kwikid-agent-dashboard .wrapper .dashboard-body{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:stretch;flex:1;overflow:auto}.kwikid-agent-dashboard .wrapper .dashboard-body .map{width:100%;height:100%;position:relative;overflow:hidden}.kwikid-agent-dashboard .wrapper .dashboard-body .map-hidden{visibility:collapse}.kwikid-agent-dashboard .wrapper .dashboard-body .customer-list{width:100%;height:100%;background-color:#fafafa;overflow:hidden}@media screen and (min-width: 600px){.kwikid-agent-dashboard{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;width:100%;height:100%}.kwikid-agent-dashboard .wrapper{width:100%;height:100%;display:flex;flex-direction:column;align-content:center;justify-content:space-between;align-items:stretch}.kwikid-agent-dashboard .wrapper header{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;grid-column-gap:1rem;column-gap:1rem;padding:.2rem;max-height:4rem;border:1px solid #fafafa;box-shadow:0 2px 10px -6px #000}.kwikid-agent-dashboard .wrapper header .client-name{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;font-size:1rem;font-weight:600}.kwikid-agent-dashboard .wrapper .dashboard-body{display:flex;flex-direction:row-reverse;align-content:center;justify-content:flex-end;align-items:stretch;padding:1.5rem;grid-gap:1.5rem;gap:1.5rem;overflow:auto;background-color:#fafafa}.kwikid-agent-dashboard .wrapper .dashboard-body .map{width:100%;height:100%;position:relative;overflow:hidden;box-shadow:#0000001a 0 4px 6px -1px,#0000000f 0 2px 4px -1px;border-radius:.5rem}.kwikid-agent-dashboard .wrapper .dashboard-body .map-hidden{visibility:collapse}.kwikid-agent-dashboard .wrapper .dashboard-body .task-details{width:100%;height:100%;position:relative;overflow:hidden;box-shadow:#0000001a 0 4px 6px -1px,#0000000f 0 2px 4px -1px;border-radius:.5rem}.kwikid-agent-dashboard .wrapper .dashboard-body .no-task-details{width:100%;height:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;grid-gap:.5rem;gap:.5rem;overflow:hidden;color:#555}.kwikid-agent-dashboard .wrapper .dashboard-body .no-task-details .no-task-img{height:100px;width:100px}.kwikid-agent-dashboard .wrapper .dashboard-body .customer-list{min-width:300px;max-width:400px;width:100%;height:100%;overflow:hidden;box-shadow:#0000001a 0 4px 6px -1px,#0000000f 0 2px 4px -1px;border-radius:.5rem}}.menu{position:absolute;transition:\"0.15s linear 0s\"}.kwikid-agent-dashboard-loader{position:absolute;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,.75);display:flex;flex-direction:row;align-content:center;justify-content:center;align-items:center;z-index:100}.kwikid-agent-dashboard-loader .loader{width:48px;height:48px;border-radius:50%;display:inline-block;position:relative;border:3px solid;border-color:#fff #fff transparent;box-sizing:border-box;animation:rotation 1s linear infinite}.kwikid-agent-dashboard-loader .loader:after{content:\"\";box-sizing:border-box;position:absolute;left:0;right:0;top:0;bottom:0;margin:auto;border:3px solid;border-color:transparent var(--tui-primary) var(--tui-primary);width:24px;height:24px;border-radius:50%;animation:rotationBack .5s linear infinite;transform-origin:center center}@keyframes rotation{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes rotationBack{0%{transform:rotate(0)}to{transform:rotate(-360deg)}}.kwikid-agent-dashboard-loader .t-loader{display:none!important}.add-task-header{display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding:.5rem 0 1rem 1rem}:host{width:100%;height:100%}::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}.menu-dropdown{display:flex;flex-direction:column;justify-content:space-between;align-items:stretch;grid-gap:.5rem;gap:.5rem;padding:1rem 1.5rem}.menu-dropdown .menu-dropdown-header{display:flex;flex-direction:column;align-content:flex-start;justify-content:space-between;align-items:flex-start;grid-gap:1rem;gap:1rem}.menu-dropdown .menu-dropdown-header .menu-dropdown-header-agent-name{font-size:1.2rem;font-weight:600}.menu-dropdown .menu-dropdown-header .menu-dropdown-header-agent-id{font-size:.8rem;font-weight:600}.menu-dropdown .menu-dropdown-buttons ::ng-deep .t-wrapper{padding:0!important}\n"], components: [{ type: i3__namespace.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["appearance", "class", "disabled", "icon", "iconRight", "id", "label", "shape", "showLoader", "size", "styles", "type"], outputs: ["onClick"] }, { type: CustomerDetailsComponent, selector: "customer-details", inputs: ["customer", "config"], outputs: ["nextStep", "removeTask"] }, { type: CustomerListComponent, selector: "customer-list", inputs: ["customers", "config"], outputs: ["nextStep", "removeTask", "filterTaskList"] }, { type: i7__namespace.KwikIDFormViewComponent, selector: "kwikid-form-view", inputs: ["allFormsData", "apiCallResponse", "buttonClickResponse", "formConfig", "formData", "isMobileView", "popupFormCallback", "userConfig"], outputs: ["getLogs", "getUnsavedDataState", "onActionShowPopupForm", "onClickApiCall", "onClickFormFieldButton", "onClickGoBack", "onClickSaveForm", "onClickViewForms"] }], directives: [{ type: i5__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i9__namespace.TuiActiveZoneDirective, selector: "[tuiActiveZone]:not(ng-container), [tuiActiveZoneChange]:not(ng-container), [tuiActiveZoneParent]:not(ng-container)", inputs: ["tuiActiveZoneParent"], outputs: ["tuiActiveZoneChange"], exportAs: ["tuiActiveZone"] }, { type: i10__namespace.TuiDropdownDirective, selector: "[tuiDropdown]:not(ng-container)", inputs: ["tuiDropdown"], exportAs: ["tuiDropdown"] }, { type: i10__namespace.TuiDropdownDriverDirective, selector: "[tuiDropdown]" }, { type: i10__namespace.TuiDropdownPositionDirective, selector: "[tuiDropdown]:not([tuiDropdownCustomPosition]):not([tuiDropdownSided])" }, { type: i10__namespace.TuiDropdownManualDirective, selector: "[tuiDropdown][tuiDropdownManual]", inputs: ["tuiDropdownManual"] }, { type: i10__namespace.TuiGroupDirective, selector: "[tuiGroup]:not(ng-container)", inputs: ["orientation", "adaptive", "collapsed", "rounded", "size"] }] });
1827
+ /** @nocollapse */ KwikIDAgentDashboardComponent.ɵfac = i0__namespace.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardComponent, deps: [{ token: GoogleMapsService }, { token: AgentService }, { token: i3__namespace.HttpClient }, { token: i0__namespace.ElementRef }, { token: i11.TuiDialogService }], target: i0__namespace.ɵɵFactoryTarget.Component });
1828
+ /** @nocollapse */ KwikIDAgentDashboardComponent.ɵcmp = i0__namespace.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: KwikIDAgentDashboardComponent, selector: "kwikid-agent-dashboard", inputs: { config: "config", taskList: "taskList" }, outputs: { nextStep: "nextStep", addTask: "addTask", removeTask: "removeTask", filterTaskList: "filterTaskList" }, host: { listeners: { "window:resize": "windowResizeWatcher($event)" } }, viewQueries: [{ propertyName: "infoWindow", first: true, predicate: i2.MapInfoWindow, descendants: true }, { propertyName: "mapElement", first: true, predicate: ["map"], descendants: true, static: true }], ngImport: i0__namespace, template: "<div class=\"kwikid-agent-dashboard\" *ngIf=\"!loading\">\n <div class=\"wrapper\">\n <header>\n <img\n *ngIf=\"\n agentService.config?.clientLogo &&\n agentService.config?.dashboard?.isShowClientLogo\n \"\n [src]=\"agentService.config.clientLogo\"\n class=\"client-logo\"\n />\n <div\n *ngIf=\"\n !agentService.config.clientLogo ||\n !agentService.config?.dashboard?.isShowClientLogo\n \"\n class=\"client-name\"\n >\n <kwikui-button\n [icon]=\"'tuiIconLink'\"\n appearance=\"mono\"\n size=\"m\"\n ></kwikui-button>\n\n {{ agentService.config.clientName }}\n </div>\n <div class=\"actions\">\n <kwikui-button\n *ngIf=\"agentService.config?.dashboard?.isAllowAddTask\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"primary\"\n [label]=\"agentService.config?.dashboard?.addTaskButtonLabel ?? 'Add User'\"\n [icon]=\"'tuiIconPlus'\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"s\"\n (onClick)=\"showDialog(template)\"\n ></kwikui-button>\n\n <kwikui-button\n *ngIf=\"!agentService.config?.dashboard?.isAllowAddTask\"\n appearance=\"mono\"\n class=\"menu-dropdown-buttons\"\n [icon]=\"'tuiIconRefreshCwLarge'\"\n size=\"m\"\n type=\"button\"\n (onClick)=\"refresh()\"\n ></kwikui-button>\n <span (tuiActiveZoneChange)=\"onActiveZone($event)\">\n <kwikui-button\n [icon]=\"'tuiIconSettingsLarge'\"\n (onClick)=\"onClick()\"\n appearance=\"mono\"\n size=\"s\"\n [tuiDropdown]=\"dropdownContent\"\n [tuiDropdownManual]=\"open\"\n (tuiObscured)=\"onObscured($event)\"\n ></kwikui-button>\n <ng-template #dropdownContent>\n <div class=\"menu-dropdown\">\n <div class=\"menu-dropdown-header\">\n <div class=\"menu-dropdown-header-agent-name\">\n {{ agentService.config.agentName }}\n </div>\n <div class=\"menu-dropdown-header-agent-id\">\n Agent ID: {{ agentService.config.agentId }}\n </div>\n </div>\n <hr />\n <div\n class=\"menu-dropdown-body\"\n tuiGroup\n [collapsed]=\"true\"\n [rounded]=\"false\"\n [orientation]=\"'vertical'\"\n [size]=\"'m'\"\n >\n <kwikui-button\n *ngIf=\"agentService.config?.dashboard?.isAllowAddTask\"\n appearance=\"mono\"\n class=\"menu-dropdown-buttons\"\n label=\"Refresh\"\n [icon]=\"'tuiIconRefreshCw'\"\n size=\"m\"\n type=\"button\"\n (onClick)=\"refresh()\"\n ></kwikui-button>\n <kwikui-button\n *ngIf=\"this.config.dashboard.isShowMaps\"\n id=\"\"\n label=\"{{\n agentService.showMapview ? 'Hide Maps' : 'Show Maps'\n }}\"\n styles=\"\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n icon=\"{{\n agentService.showMapview ? 'tuiIconEyeOff' : 'tuiIconEye'\n }}\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n styles=\"padding: 0rem !important\"\n (onClick)=\"agentService.toggleMapview()\"\n ></kwikui-button>\n </div>\n <hr />\n <div class=\"menu-dropdown-footer\">\n <kwikui-button\n id=\"\"\n label=\"Logout\"\n styles=\"\"\n class=\"menu-dropdown-buttons\"\n type=\"button\"\n appearance=\"mono\"\n [icon]=\"'tuiIconLogOut'\"\n iconRight=\"\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"handleOnClickNext({ stepType: 'LOGOUT' })\"\n ></kwikui-button>\n </div>\n </div>\n </ng-template>\n </span>\n </div>\n </header>\n\n <div class=\"dashboard-body\">\n <div\n *ngIf=\"mapsLoaded\"\n [class]=\"agentService.showMapview ? 'map' : 'map-hidden'\"\n >\n <google-map\n *ngIf=\"agentService.config?.dashboard?.mapType == 'google-maps'\"\n [options]=\"this.googleMapsService.map\"\n height=\"100%\"\n width=\"100%\"\n >\n <map-marker\n #marker=\"mapMarker\"\n *ngFor=\"\n let markerPosition of this.googleMapsService.allMarkers;\n let index = index\n \"\n [position]=\"markerPosition\"\n [label]=\"{ text: String(index) }\"\n ></map-marker>\n <map-directions-renderer\n *ngIf=\"\n this.googleMapsService.directionsResults$\n | async as directionsResults\n \"\n [directions]=\"directionsResults\"\n [options]=\"this.googleMapsService.directionsRenderOption\"\n ></map-directions-renderer>\n </google-map>\n\n <div\n *ngIf=\"agentService.config?.dashboard?.mapType == 'open-street'\"\n id=\"map\"\n style=\"height: 100%\"\n ></div>\n </div>\n\n <div\n class=\"task-details\"\n *ngIf=\"\n !agentService.isMobileView &&\n agentService.isShowTaskDetails != undefined &&\n !agentService.showMapview\n \"\n >\n <customer-details\n [customer]=\"taskList[agentService.isShowTaskDetails]\"\n [config]=\"config\"\n (nextStep)=\"handleOnClickNext($event)\"\n (removeTask)=\"handleOnClickRemoveTask($event)\"\n ></customer-details>\n </div>\n\n <div\n class=\"no-task-details\"\n *ngIf=\"\n !agentService.isMobileView &&\n agentService.isShowTaskDetails == undefined &&\n !agentService.showMapview\n \"\n >\n <img src=\"assets/No-Results.jpg\" class=\"no-task-img\" alt=\"No Task\" />\n <div class=\"\">Select a Task to view it's details.</div>\n </div>\n\n <div class=\"customer-list\">\n <customer-list\n [customers]=\"taskList\"\n [config]=\"config\"\n (nextStep)=\"handleOnClickNext($event)\"\n (removeTask)=\"handleOnClickRemoveTask($event)\"\n (filterTaskList)=\"handleOnFilterTaskList($event)\"\n ></customer-list>\n </div>\n </div>\n </div>\n</div>\n\n<div class=\"kwikid-agent-dashboard-loader\" *ngIf=\"loading\">\n <span class=\"loader\"></span>\n</div>\n\n<ng-template #template let-observer>\n <div class=\"add-task-header\">\n <h2>{{agentService?.addTaskForm?.title ?? \"Create User\"}}</h2>\n <kwikui-button\n icon=\"tuiIconX\"\n id=\"\"\n styles=\"\"\n type=\"button\"\n appearance=\"mono\"\n [shape]=\"null\"\n size=\"m\"\n (onClick)=\"observer.complete()\"\n ></kwikui-button>\n </div>\n <kwikid-form-view\n [allFormsData]=\"allFormsData\"\n [formConfig]=\"agentService.addTaskForm\"\n [isMobileView]=\"true\"\n (onClickViewForms)=\"this.handleOnClickViewForms($event)\"\n (onClickSaveForm)=\"this.handleOnClickSaveForm($event)\"\n ></kwikid-form-view>\n</ng-template>\n", styles: [".kwikid-agent-dashboard{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;width:100%;height:100%;position:relative}.kwikid-agent-dashboard .wrapper{width:100%;height:100%;display:flex;flex-direction:column;align-content:center;justify-content:space-between;align-items:stretch}.kwikid-agent-dashboard .wrapper header{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;grid-column-gap:1rem;column-gap:1rem;padding:.2rem;max-height:4rem;border:1px solid #fafafa;box-shadow:0 2px 10px -6px #000}.kwikid-agent-dashboard .wrapper header .client-logo{height:100%;padding-left:1rem}.kwikid-agent-dashboard .wrapper header .client-name{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;font-size:1rem;font-weight:600}.kwikid-agent-dashboard .wrapper header .actions{display:flex;flex-direction:row;align-items:center}.kwikid-agent-dashboard .wrapper header .actions>*{margin-right:.5rem}.kwikid-agent-dashboard .wrapper .dashboard-body{display:flex;flex-direction:column;align-content:center;justify-content:center;align-items:stretch;flex:1;overflow:auto}.kwikid-agent-dashboard .wrapper .dashboard-body .map{width:100%;height:100%;position:relative;overflow:hidden}.kwikid-agent-dashboard .wrapper .dashboard-body .map-hidden{visibility:collapse}.kwikid-agent-dashboard .wrapper .dashboard-body .customer-list{width:100%;height:100%;background-color:#fafafa;overflow:hidden}@media screen and (min-width: 600px){.kwikid-agent-dashboard{display:flex;flex-direction:column;justify-content:flex-start;align-items:stretch;align-content:center;width:100%;height:100%}.kwikid-agent-dashboard .wrapper{width:100%;height:100%;display:flex;flex-direction:column;align-content:center;justify-content:space-between;align-items:stretch}.kwikid-agent-dashboard .wrapper header{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;grid-column-gap:1rem;column-gap:1rem;padding:.2rem;max-height:4rem;border:1px solid #fafafa;box-shadow:0 2px 10px -6px #000}.kwikid-agent-dashboard .wrapper header .client-name{display:flex;flex-direction:row;align-content:center;justify-content:space-between;align-items:center;font-size:1rem;font-weight:600}.kwikid-agent-dashboard .wrapper .dashboard-body{display:flex;flex-direction:row-reverse;align-content:center;justify-content:flex-end;align-items:stretch;padding:1.5rem;grid-gap:1.5rem;gap:1.5rem;overflow:auto;background-color:#fafafa}.kwikid-agent-dashboard .wrapper .dashboard-body .map{width:100%;height:100%;position:relative;overflow:hidden;box-shadow:#0000001a 0 4px 6px -1px,#0000000f 0 2px 4px -1px;border-radius:.5rem}.kwikid-agent-dashboard .wrapper .dashboard-body .map-hidden{visibility:collapse}.kwikid-agent-dashboard .wrapper .dashboard-body .task-details{width:100%;height:100%;position:relative;overflow:hidden;box-shadow:#0000001a 0 4px 6px -1px,#0000000f 0 2px 4px -1px;border-radius:.5rem}.kwikid-agent-dashboard .wrapper .dashboard-body .no-task-details{width:100%;height:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;grid-gap:.5rem;gap:.5rem;overflow:hidden;color:#555}.kwikid-agent-dashboard .wrapper .dashboard-body .no-task-details .no-task-img{height:100px;width:100px}.kwikid-agent-dashboard .wrapper .dashboard-body .customer-list{min-width:300px;max-width:400px;width:100%;height:100%;overflow:hidden;box-shadow:#0000001a 0 4px 6px -1px,#0000000f 0 2px 4px -1px;border-radius:.5rem}}.menu{position:absolute;transition:\"0.15s linear 0s\"}.kwikid-agent-dashboard-loader{position:absolute;top:0;left:0;width:100%;height:100%;background:rgba(0,0,0,.75);display:flex;flex-direction:row;align-content:center;justify-content:center;align-items:center;z-index:100}.kwikid-agent-dashboard-loader .loader{width:48px;height:48px;border-radius:50%;display:inline-block;position:relative;border:3px solid;border-color:#fff #fff transparent;box-sizing:border-box;animation:rotation 1s linear infinite}.kwikid-agent-dashboard-loader .loader:after{content:\"\";box-sizing:border-box;position:absolute;left:0;right:0;top:0;bottom:0;margin:auto;border:3px solid;border-color:transparent var(--tui-primary) var(--tui-primary);width:24px;height:24px;border-radius:50%;animation:rotationBack .5s linear infinite;transform-origin:center center}@keyframes rotation{0%{transform:rotate(0)}to{transform:rotate(360deg)}}@keyframes rotationBack{0%{transform:rotate(0)}to{transform:rotate(-360deg)}}.kwikid-agent-dashboard-loader .t-loader{display:none!important}.add-task-header{display:flex;flex-direction:row;justify-content:space-between;align-items:center;padding:.5rem 0 1rem 1rem}:host{width:100%;height:100%}::-webkit-scrollbar{width:8px}::-webkit-scrollbar-track{border-radius:10px}::-webkit-scrollbar-thumb{background:lightgray;border-radius:10px}::-webkit-scrollbar-thumb:hover{background:gray}.menu-dropdown{display:flex;flex-direction:column;justify-content:space-between;align-items:stretch;grid-gap:.5rem;gap:.5rem;padding:1rem 1.5rem}.menu-dropdown .menu-dropdown-header{display:flex;flex-direction:column;align-content:flex-start;justify-content:space-between;align-items:flex-start;grid-gap:1rem;gap:1rem}.menu-dropdown .menu-dropdown-header .menu-dropdown-header-agent-name{font-size:1.2rem;font-weight:600}.menu-dropdown .menu-dropdown-header .menu-dropdown-header-agent-id{font-size:.8rem;font-weight:600}.menu-dropdown .menu-dropdown-buttons ::ng-deep .t-wrapper{padding:0!important}\n"], components: [{ type: i4__namespace.KwikUIButtonComponent, selector: "kwikui-button", inputs: ["appearance", "class", "disabled", "icon", "iconRight", "id", "label", "shape", "showLoader", "size", "styles", "type"], outputs: ["onClick"] }, { type: i2__namespace.GoogleMap, selector: "google-map", inputs: ["height", "width", "center", "zoom", "options", "mapTypeId"], outputs: ["authFailure", "boundsChanged", "centerChanged", "mapClick", "mapDblclick", "mapDrag", "mapDragend", "mapDragstart", "headingChanged", "idle", "maptypeidChanged", "mapMousemove", "mapMouseout", "mapMouseover", "projectionChanged", "mapRightclick", "tilesloaded", "tiltChanged", "zoomChanged"], exportAs: ["googleMap"] }, { type: CustomerDetailsComponent, selector: "customer-details", inputs: ["customer", "config"], outputs: ["nextStep", "removeTask"] }, { type: CustomerListComponent, selector: "customer-list", inputs: ["customers", "config"], outputs: ["nextStep", "removeTask", "filterTaskList"] }, { type: i8__namespace.KwikIDFormViewComponent, selector: "kwikid-form-view", inputs: ["allFormsData", "apiCallResponse", "buttonClickResponse", "formConfig", "formData", "isMobileView", "popupFormCallback", "userConfig"], outputs: ["getLogs", "getUnsavedDataState", "onActionShowPopupForm", "onClickApiCall", "onClickFormFieldButton", "onClickGoBack", "onClickSaveForm", "onClickViewForms"] }], directives: [{ type: i6__namespace.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i10__namespace.TuiActiveZoneDirective, selector: "[tuiActiveZone]:not(ng-container), [tuiActiveZoneChange]:not(ng-container), [tuiActiveZoneParent]:not(ng-container)", inputs: ["tuiActiveZoneParent"], outputs: ["tuiActiveZoneChange"], exportAs: ["tuiActiveZone"] }, { type: i11__namespace.TuiDropdownDirective, selector: "[tuiDropdown]:not(ng-container)", inputs: ["tuiDropdown"], exportAs: ["tuiDropdown"] }, { type: i11__namespace.TuiDropdownDriverDirective, selector: "[tuiDropdown]" }, { type: i11__namespace.TuiDropdownPositionDirective, selector: "[tuiDropdown]:not([tuiDropdownCustomPosition]):not([tuiDropdownSided])" }, { type: i11__namespace.TuiDropdownManualDirective, selector: "[tuiDropdown][tuiDropdownManual]", inputs: ["tuiDropdownManual"] }, { type: i11__namespace.TuiGroupDirective, selector: "[tuiGroup]:not(ng-container)", inputs: ["orientation", "adaptive", "collapsed", "rounded", "size"] }, { type: i6__namespace.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2__namespace.MapMarker, selector: "map-marker", inputs: ["title", "position", "label", "clickable", "options", "icon", "visible"], outputs: ["animationChanged", "mapClick", "clickableChanged", "cursorChanged", "mapDblclick", "mapDrag", "mapDragend", "draggableChanged", "mapDragstart", "flatChanged", "iconChanged", "mapMousedown", "mapMouseout", "mapMouseover", "mapMouseup", "positionChanged", "mapRightclick", "shapeChanged", "titleChanged", "visibleChanged", "zindexChanged"], exportAs: ["mapMarker"] }, { type: i2__namespace.MapDirectionsRenderer, selector: "map-directions-renderer", inputs: ["directions", "options"], outputs: ["directionsChanged"], exportAs: ["mapDirectionsRenderer"] }], pipes: { "async": i6__namespace.AsyncPipe } });
1458
1829
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardComponent, decorators: [{
1459
1830
  type: i0.Component,
1460
1831
  args: [{
@@ -1463,9 +1834,9 @@
1463
1834
  styleUrls: ['./kwikid-agent-dashboard.component.scss']
1464
1835
  }]
1465
1836
  }], ctorParameters: function () {
1466
- return [{ type: MapService }, { type: AgentService }, { type: i3__namespace$1.HttpClient }, { type: i0__namespace.ElementRef }, { type: i10__namespace.TuiDialogService, decorators: [{
1837
+ return [{ type: GoogleMapsService }, { type: AgentService }, { type: i3__namespace.HttpClient }, { type: i0__namespace.ElementRef }, { type: i11__namespace.TuiDialogService, decorators: [{
1467
1838
  type: i0.Inject,
1468
- args: [i10.TuiDialogService]
1839
+ args: [i11.TuiDialogService]
1469
1840
  }] }];
1470
1841
  }, propDecorators: { windowResizeWatcher: [{
1471
1842
  type: i0.HostListener,
@@ -1484,7 +1855,7 @@
1484
1855
  type: i0.Output
1485
1856
  }], infoWindow: [{
1486
1857
  type: i0.ViewChild,
1487
- args: [googleMaps.MapInfoWindow, { static: false }]
1858
+ args: [i2.MapInfoWindow, { static: false }]
1488
1859
  }], mapElement: [{
1489
1860
  type: i0.ViewChild,
1490
1861
  args: ['map', { static: true }]
@@ -1501,55 +1872,55 @@
1501
1872
  CustomerTileComponent,
1502
1873
  Ng2SearchPipe,
1503
1874
  StatusPillComponent,
1504
- CustomerDetailsComponent], imports: [i5.CommonModule,
1505
- i3$1.HttpClientModule,
1506
- i6.FormsModule,
1507
- i6.ReactiveFormsModule,
1508
- i3.KwikUIButtonModule,
1509
- i3.KwikUIInputModule,
1510
- i3.KwikUIInputDateModule,
1511
- i3.KwikUIInputDateRangeModule,
1512
- i3.KwikUIInputSelectModule,
1513
- i3.KwikUILabelValuePairModule,
1514
- i3.KwikUITableModule,
1515
- i3.KwikUITablePaginationModule,
1516
- i7.KwikIDFormViewModule,
1517
- i10.TuiRootModule,
1518
- i10.TuiDialogModule,
1519
- i10.TuiDropdownModule,
1875
+ CustomerDetailsComponent], imports: [i6.CommonModule,
1876
+ i3.HttpClientModule,
1877
+ i7.FormsModule,
1878
+ i7.ReactiveFormsModule,
1879
+ i4.KwikUIButtonModule,
1880
+ i4.KwikUIInputModule,
1881
+ i4.KwikUIInputDateModule,
1882
+ i4.KwikUIInputDateRangeModule,
1883
+ i4.KwikUIInputSelectModule,
1884
+ i4.KwikUILabelValuePairModule,
1885
+ i4.KwikUITableModule,
1886
+ i4.KwikUITablePaginationModule,
1887
+ i8.KwikIDFormViewModule,
1888
+ i11.TuiRootModule,
1889
+ i11.TuiDialogModule,
1890
+ i11.TuiDropdownModule,
1520
1891
  addonMobile.TuiSidebarModule,
1521
- i9.TuiActiveZoneModule,
1522
- i10.TuiGroupModule,
1523
- i10.TuiSvgModule,
1524
- i4.ScrollingModule,
1525
- googleMaps.GoogleMapsModule,
1526
- i3$1.HttpClientModule,
1527
- i3$1.HttpClientJsonpModule], exports: [KwikIDAgentDashboardComponent] });
1892
+ i10.TuiActiveZoneModule,
1893
+ i11.TuiGroupModule,
1894
+ i11.TuiSvgModule,
1895
+ i5.ScrollingModule,
1896
+ i2.GoogleMapsModule,
1897
+ i3.HttpClientModule,
1898
+ i3.HttpClientJsonpModule], exports: [KwikIDAgentDashboardComponent] });
1528
1899
  /** @nocollapse */ KwikIDAgentDashboardModule.ɵinj = i0__namespace.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardModule, imports: [[
1529
- i5.CommonModule,
1530
- i3$1.HttpClientModule,
1531
- i6.FormsModule,
1532
- i6.ReactiveFormsModule,
1533
- i3.KwikUIButtonModule,
1534
- i3.KwikUIInputModule,
1535
- i3.KwikUIInputDateModule,
1536
- i3.KwikUIInputDateRangeModule,
1537
- i3.KwikUIInputSelectModule,
1538
- i3.KwikUILabelValuePairModule,
1539
- i3.KwikUITableModule,
1540
- i3.KwikUITablePaginationModule,
1541
- i7.KwikIDFormViewModule,
1542
- i10.TuiRootModule,
1543
- i10.TuiDialogModule,
1544
- i10.TuiDropdownModule,
1900
+ i6.CommonModule,
1901
+ i3.HttpClientModule,
1902
+ i7.FormsModule,
1903
+ i7.ReactiveFormsModule,
1904
+ i4.KwikUIButtonModule,
1905
+ i4.KwikUIInputModule,
1906
+ i4.KwikUIInputDateModule,
1907
+ i4.KwikUIInputDateRangeModule,
1908
+ i4.KwikUIInputSelectModule,
1909
+ i4.KwikUILabelValuePairModule,
1910
+ i4.KwikUITableModule,
1911
+ i4.KwikUITablePaginationModule,
1912
+ i8.KwikIDFormViewModule,
1913
+ i11.TuiRootModule,
1914
+ i11.TuiDialogModule,
1915
+ i11.TuiDropdownModule,
1545
1916
  addonMobile.TuiSidebarModule,
1546
- i9.TuiActiveZoneModule,
1547
- i10.TuiGroupModule,
1548
- i10.TuiSvgModule,
1549
- i4.ScrollingModule,
1550
- googleMaps.GoogleMapsModule,
1551
- i3$1.HttpClientModule,
1552
- i3$1.HttpClientJsonpModule
1917
+ i10.TuiActiveZoneModule,
1918
+ i11.TuiGroupModule,
1919
+ i11.TuiSvgModule,
1920
+ i5.ScrollingModule,
1921
+ i2.GoogleMapsModule,
1922
+ i3.HttpClientModule,
1923
+ i3.HttpClientJsonpModule
1553
1924
  ]] });
1554
1925
  i0__namespace.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0__namespace, type: KwikIDAgentDashboardModule, decorators: [{
1555
1926
  type: i0.NgModule,
@@ -1563,30 +1934,30 @@
1563
1934
  CustomerDetailsComponent
1564
1935
  ],
1565
1936
  imports: [
1566
- i5.CommonModule,
1567
- i3$1.HttpClientModule,
1568
- i6.FormsModule,
1569
- i6.ReactiveFormsModule,
1570
- i3.KwikUIButtonModule,
1571
- i3.KwikUIInputModule,
1572
- i3.KwikUIInputDateModule,
1573
- i3.KwikUIInputDateRangeModule,
1574
- i3.KwikUIInputSelectModule,
1575
- i3.KwikUILabelValuePairModule,
1576
- i3.KwikUITableModule,
1577
- i3.KwikUITablePaginationModule,
1578
- i7.KwikIDFormViewModule,
1579
- i10.TuiRootModule,
1580
- i10.TuiDialogModule,
1581
- i10.TuiDropdownModule,
1937
+ i6.CommonModule,
1938
+ i3.HttpClientModule,
1939
+ i7.FormsModule,
1940
+ i7.ReactiveFormsModule,
1941
+ i4.KwikUIButtonModule,
1942
+ i4.KwikUIInputModule,
1943
+ i4.KwikUIInputDateModule,
1944
+ i4.KwikUIInputDateRangeModule,
1945
+ i4.KwikUIInputSelectModule,
1946
+ i4.KwikUILabelValuePairModule,
1947
+ i4.KwikUITableModule,
1948
+ i4.KwikUITablePaginationModule,
1949
+ i8.KwikIDFormViewModule,
1950
+ i11.TuiRootModule,
1951
+ i11.TuiDialogModule,
1952
+ i11.TuiDropdownModule,
1582
1953
  addonMobile.TuiSidebarModule,
1583
- i9.TuiActiveZoneModule,
1584
- i10.TuiGroupModule,
1585
- i10.TuiSvgModule,
1586
- i4.ScrollingModule,
1587
- googleMaps.GoogleMapsModule,
1588
- i3$1.HttpClientModule,
1589
- i3$1.HttpClientJsonpModule
1954
+ i10.TuiActiveZoneModule,
1955
+ i11.TuiGroupModule,
1956
+ i11.TuiSvgModule,
1957
+ i5.ScrollingModule,
1958
+ i2.GoogleMapsModule,
1959
+ i3.HttpClientModule,
1960
+ i3.HttpClientJsonpModule
1590
1961
  ],
1591
1962
  exports: [KwikIDAgentDashboardComponent]
1592
1963
  }]