@syncfusion/ej2-pdfviewer 17.3.48-4568 → 17.3.50-4568

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.
package/package.json CHANGED
@@ -1,26 +1,50 @@
1
1
  {
2
-
2
+ "_from": "@syncfusion/ej2-pdfviewer@17.3.50-4568",
3
+ "_id": "@syncfusion/ej2-pdfviewer@17.3.50-4568",
4
+ "_inBundle": false,
5
+ "_integrity": "sha512-Cw4UApaqGOrXL96j7UUbFY9ph9rV4wg9Q5ahgvaDykId7tb2OzdgzQZuxU5RVWRU6uPqVSNFfiO8wxcGgjBfmg==",
6
+ "_location": "/@syncfusion/ej2-pdfviewer",
7
+ "_phantomChildren": {},
8
+ "_requested": {
9
+ "type": "version",
10
+ "registry": true,
11
+ "raw": "@syncfusion/ej2-pdfviewer@17.3.48-4568",
12
+ "name": "@syncfusion/ej2-pdfviewer",
13
+ "escapedName": "@syncfusion%2fej2-pdfviewer",
14
+ "scope": "@syncfusion",
15
+ "rawSpec": "17.3.48-4568",
16
+ "saveSpec": null,
17
+ "fetchSpec": "17.3.48-4568"
18
+ },
19
+ "_requiredBy": [
20
+ "#USER",
21
+ "/"
22
+ ],
23
+ "_resolved": "https://registry.npmjs.org/@syncfusion/ej2-pdfviewer/-/ej2-pdfviewer-17.3.48-4568.tgz",
24
+ "_shasum": "e4d7d8aa526d5ded9260c431fb667e186623e53f",
25
+ "_spec": "@syncfusion/ej2-pdfviewer@17.3.48-4568",
26
+ "_where": "E:\\New folder",
3
27
  "author": {
4
- "name": "Syncfusion Inc."
28
+ "name": "Syncfusion Inc."
5
29
  },
6
30
  "bugs": {
7
- "url": "https://github.com/syncfusion/ej2-pdfviewer/issues"
31
+ "url": "https://github.com/syncfusion/ej2-pdfviewer/issues"
8
32
  },
9
33
  "bundleDependencies": false,
10
34
  "dependencies": {
11
- "@syncfusion/ej2-base": "~17.3.27",
12
- "@syncfusion/ej2-buttons": "~17.3.27",
13
- "@syncfusion/ej2-calendars": "~17.3.28",
14
- "@syncfusion/ej2-data": "~17.3.30",
15
- "@syncfusion/ej2-drawings": "~17.3.27",
16
- "@syncfusion/ej2-dropdowns": "~17.3.34",
17
- "@syncfusion/ej2-inplace-editor": "~17.3.29",
18
- "@syncfusion/ej2-inputs": "~17.3.29",
19
- "@syncfusion/ej2-lists": "~17.3.27",
20
- "@syncfusion/ej2-navigations": "~17.3.34",
21
- "@syncfusion/ej2-notifications": "~17.3.30",
22
- "@syncfusion/ej2-popups": "~17.3.34",
23
- "@syncfusion/ej2-richtexteditor": "~17.3.29"
35
+ "@syncfusion/ej2-base": "~17.3.27",
36
+ "@syncfusion/ej2-buttons": "~17.3.27",
37
+ "@syncfusion/ej2-calendars": "~17.3.28",
38
+ "@syncfusion/ej2-data": "~17.3.30",
39
+ "@syncfusion/ej2-drawings": "~17.3.27",
40
+ "@syncfusion/ej2-dropdowns": "~17.3.34",
41
+ "@syncfusion/ej2-inplace-editor": "~17.3.29",
42
+ "@syncfusion/ej2-inputs": "~17.3.29",
43
+ "@syncfusion/ej2-lists": "~17.3.27",
44
+ "@syncfusion/ej2-navigations": "~17.3.34",
45
+ "@syncfusion/ej2-notifications": "~17.3.30",
46
+ "@syncfusion/ej2-popups": "~17.3.34",
47
+ "@syncfusion/ej2-richtexteditor": "~17.3.29"
24
48
  },
25
49
  "deprecated": false,
26
50
  "description": "Essential JS 2 PDF viewer Component",
@@ -28,24 +52,25 @@
28
52
  "es2015": "./dist/es6/ej2-pdfviewer.es2015.js",
29
53
  "homepage": "https://github.com/syncfusion/ej2-pdfviewer#readme",
30
54
  "keywords": [
31
- "ej2",
32
- "syncfusion",
33
- "ej2-pdfviewer",
34
- "web-components",
35
- "JavaScript",
36
- "TypeScript",
37
- "viewer",
38
- "annotation"
55
+ "ej2",
56
+ "syncfusion",
57
+ "ej2-pdfviewer",
58
+ "web-components",
59
+ "JavaScript",
60
+ "TypeScript",
61
+ "viewer",
62
+ "annotation"
39
63
  ],
40
64
  "license": "SEE LICENSE IN license",
41
65
  "main": "./dist/ej2-pdfviewer.umd.min.js",
42
66
  "module": "./index.js",
43
67
  "name": "@syncfusion/ej2-pdfviewer",
44
68
  "repository": {
45
- "type": "git",
46
- "url": "git+https://github.com/syncfusion/ej2-pdfviewer.git"
69
+ "type": "git",
70
+ "url": "git+https://github.com/syncfusion/ej2-pdfviewer.git"
47
71
  },
72
+ "sideEffects": false,
48
73
  "typings": "index.d.ts",
49
- "version": "17.3.48-4568",
50
- "sideEffects": false
51
- }
74
+ "version": "17.3.50-4568"
75
+ }
76
+
@@ -34,6 +34,7 @@ export declare class AjaxHandler {
34
34
  private pdfViewer;
35
35
  private retryCount;
36
36
  private retryStatusCodes;
37
+ private retryTimeout;
37
38
  /**
38
39
  * Constructor for Ajax class
39
40
  * @param {PdfViewer} pdfviewer
@@ -26,9 +26,11 @@ var AjaxHandler = /** @class */ (function () {
26
26
  * @private
27
27
  */
28
28
  this.contentType = 'application/json;charset=UTF-8';
29
+ this.retryTimeout = 0;
29
30
  this.pdfViewer = pdfviewer;
30
31
  this.retryCount = pdfviewer.retryCount;
31
32
  this.retryStatusCodes = pdfviewer.retryStatusCodes;
33
+ this.retryTimeout = 1000 * pdfviewer.retryTimeout;
32
34
  }
33
35
  /**
34
36
  * Send the request to server
@@ -38,6 +40,7 @@ var AjaxHandler = /** @class */ (function () {
38
40
  AjaxHandler.prototype.send = function (jsonObj) {
39
41
  var _this = this;
40
42
  this.httpRequest = new XMLHttpRequest();
43
+ this.httpRequest.timeout = this.retryTimeout;
41
44
  if (!this.mode) {
42
45
  setTimeout(function () { _this.sendRequest(jsonObj); });
43
46
  }
@@ -53,7 +56,22 @@ var AjaxHandler = /** @class */ (function () {
53
56
  _this.retryCount = 0;
54
57
  }
55
58
  if (_this.retryCount > 0) {
56
- isSkip = _this.resendRequest(_this, jsonObj);
59
+ isSkip = _this.resendRequest(_this, jsonObj, false);
60
+ }
61
+ if (!isSkip) {
62
+ _this.stateChange(_this);
63
+ }
64
+ };
65
+ this.httpRequest.ontimeout = function () {
66
+ var isSkip = false;
67
+ // tslint:disable-next-line
68
+ var viewerBase = _this.pdfViewer.viewerBase;
69
+ if (viewerBase && viewerBase.isPasswordAvailable && viewerBase.passwordData === '') {
70
+ isSkip = true;
71
+ _this.retryCount = 0;
72
+ }
73
+ if (_this.retryCount > 0) {
74
+ isSkip = _this.resendRequest(_this, jsonObj, true);
57
75
  }
58
76
  if (!isSkip) {
59
77
  _this.stateChange(_this);
@@ -62,7 +80,7 @@ var AjaxHandler = /** @class */ (function () {
62
80
  this.httpRequest.onerror = function () { _this.error(_this); };
63
81
  };
64
82
  // tslint:disable-next-line
65
- AjaxHandler.prototype.resendRequest = function (proxy, jsonObj) {
83
+ AjaxHandler.prototype.resendRequest = function (proxy, jsonObj, isTimeout) {
66
84
  var isSkip = false;
67
85
  var status = proxy.httpRequest.status;
68
86
  var statusString = this.retryStatusCodes.indexOf(status) !== -1;
@@ -89,7 +107,7 @@ var AjaxHandler = /** @class */ (function () {
89
107
  }
90
108
  }
91
109
  }
92
- if (statusString || isSkip) {
110
+ if (statusString || isSkip || isTimeout) {
93
111
  isSkip = true;
94
112
  this.retryCount--;
95
113
  proxy.send(jsonObj);
@@ -441,6 +441,31 @@ export declare class PdfViewerBase {
441
441
  * @private
442
442
  */
443
443
  isReRenderRequired: boolean;
444
+ /**
445
+ * @private
446
+ */
447
+ isTouchPad: boolean;
448
+ /**
449
+ * @private
450
+ */
451
+ isMacGestureActive: boolean;
452
+ /**
453
+ * @private
454
+ */
455
+ macGestureStartScale: number;
456
+ /**
457
+ * @private
458
+ */
459
+ zoomInterval: number;
460
+ /**
461
+ * EJ2CORE-813 - This flag is represent current device is 'iPad' or 'iPhone' or'iPod' device.
462
+ * @private
463
+ */
464
+ isDeviceiOS: Boolean;
465
+ /**
466
+ * @private
467
+ */
468
+ isMacSafari: boolean;
444
469
  /**
445
470
  * @private
446
471
  */
@@ -598,6 +623,26 @@ export declare class PdfViewerBase {
598
623
  */
599
624
  checkIsNormalText(): boolean;
600
625
  private viewerContainerOnMouseup;
626
+ /**
627
+ * @param {any} event - The Wheel event.
628
+ * @returns {void}
629
+ */
630
+ private detectTouchPad;
631
+ /**
632
+ * @param {any} event - The Wheel event.
633
+ * @returns {void}
634
+ */
635
+ private handleMacGestureStart;
636
+ /**
637
+ * @param {any} event - The Wheel event.
638
+ * @returns {void}
639
+ */
640
+ private handleMacGestureChange;
641
+ /**
642
+ * @param {any} event - The Wheel event.
643
+ * @returns {void}
644
+ */
645
+ private handleMacGestureEnd;
601
646
  private viewerContainerOnMouseWheel;
602
647
  private viewerContainerOnKeyDown;
603
648
  private viewerContainerOnMousemove;
@@ -337,6 +337,37 @@ var PdfViewerBase = /** @class */ (function () {
337
337
  * @private
338
338
  */
339
339
  this.isReRenderRequired = true;
340
+ /**
341
+ * @private
342
+ */
343
+ // eslint-disable-next-line
344
+ this.isTouchPad = false;
345
+ /**
346
+ * @private
347
+ */
348
+ // eslint-disable-next-line
349
+ this.isMacGestureActive = false;
350
+ /**
351
+ * @private
352
+ */
353
+ // eslint-disable-next-line
354
+ this.macGestureStartScale = 0;
355
+ /**
356
+ * @private
357
+ */
358
+ // eslint-disable-next-line
359
+ this.zoomInterval = 5;
360
+ /**
361
+ * EJ2CORE-813 - This flag is represent current device is 'iPad' or 'iPhone' or'iPod' device.
362
+ * @private
363
+ */
364
+ // eslint-disable-next-line
365
+ this.isDeviceiOS = (['iPad Simulator', 'iPhone Simulator', 'iPod Simulator', 'iPad', 'iPhone', 'iPod'].includes(navigator.platform) || (navigator.userAgent.includes("Mac") && "ontouchend" in document));
366
+ /**
367
+ * @private
368
+ */
369
+ // eslint-disable-next-line
370
+ this.isMacSafari = navigator.userAgent.indexOf("Safari") > -1 && navigator.userAgent.indexOf("Chrome") === -1 && !this.isDeviceiOS;
340
371
  /**
341
372
  * @private
342
373
  */
@@ -617,6 +648,49 @@ var PdfViewerBase = /** @class */ (function () {
617
648
  _this.isViewerMouseDown = false;
618
649
  }
619
650
  };
651
+ /**
652
+ * @param {any} event - The Wheel event.
653
+ * @returns {void}
654
+ */
655
+ this.detectTouchPad = function (event) {
656
+ // eslint-disable-next-line max-len
657
+ _this.isTouchPad = event.wheelDeltaY ? (event.wheelDeltaY === (event.deltaY * -3) ? true : Math.abs(event.deltaY) < 60) : (event.deltaMode === 0);
658
+ };
659
+ /**
660
+ * @param {any} event - The Wheel event.
661
+ * @returns {void}
662
+ */
663
+ this.handleMacGestureStart = function (event) {
664
+ event.preventDefault();
665
+ event.stopPropagation();
666
+ _this.macGestureStartScale = _this.pdfViewer.magnification.zoomFactor;
667
+ };
668
+ /**
669
+ * @param {any} event - The Wheel event.
670
+ * @returns {void}
671
+ */
672
+ this.handleMacGestureChange = function (event) {
673
+ event.preventDefault();
674
+ event.stopPropagation();
675
+ var macX = event.clientX;
676
+ var macY = event.clientY;
677
+ var scale = Number((_this.macGestureStartScale * event.scale).toFixed(2));
678
+ if (!_this.isMacGestureActive) {
679
+ _this.isMacGestureActive = true;
680
+ _this.pdfViewer.magnification.initiateMouseZoom(macX, macY, scale * 100);
681
+ setTimeout(function () {
682
+ _this.isMacGestureActive = false;
683
+ }, 70);
684
+ }
685
+ };
686
+ /**
687
+ * @param {any} event - The Wheel event.
688
+ * @returns {void}
689
+ */
690
+ this.handleMacGestureEnd = function (event) {
691
+ event.preventDefault();
692
+ event.stopPropagation();
693
+ };
620
694
  this.viewerContainerOnMouseWheel = function (event) {
621
695
  _this.isViewerMouseWheel = true;
622
696
  if (_this.getRerenderCanvasCreated()) {
@@ -630,13 +704,17 @@ var PdfViewerBase = /** @class */ (function () {
630
704
  if (_this.pdfViewer.magnification.zoomFactor >= 2) {
631
705
  zoomDifference = 50;
632
706
  }
707
+ if (_this.isTouchPad && !_this.isMacSafari) {
708
+ zoomDifference = zoomDifference / _this.zoomInterval;
709
+ }
633
710
  // eslint-disable-next-line
634
711
  if (event.wheelDelta > 0) {
635
- _this.pdfViewer.magnification.zoomTo((_this.pdfViewer.magnification.zoomFactor * 100) + zoomDifference);
712
+ _this.pdfViewer.magnification.initiateMouseZoom(event.x, event.y, (_this.pdfViewer.magnification.zoomFactor * 100) + zoomDifference);
636
713
  }
637
714
  else {
638
- _this.pdfViewer.magnification.zoomTo((_this.pdfViewer.magnification.zoomFactor * 100) - zoomDifference);
715
+ _this.pdfViewer.magnification.initiateMouseZoom(event.x, event.y, (_this.pdfViewer.magnification.zoomFactor * 100) - zoomDifference);
639
716
  }
717
+ _this.isTouchPad = false;
640
718
  }
641
719
  if (_this.pdfViewer.magnificationModule) {
642
720
  _this.pdfViewer.magnificationModule.pageRerenderOnMouseWheel();
@@ -1125,8 +1203,8 @@ var PdfViewerBase = /** @class */ (function () {
1125
1203
  _this.previousTime = new Date().getTime();
1126
1204
  // tslint:disable-next-line:max-line-length
1127
1205
  if (touchPoints.length === 1 && !(event.target.classList.contains('e-pv-touch-select-drop') || event.target.classList.contains('e-pv-touch-ellipse'))) {
1128
- if (Browser.isDevice && _this.pageCount > 0 && !_this.isThumb && !(event.target.classList.contains('e-pv-hyperlink'))) {
1129
- _this.handleTaps(touchPoints);
1206
+ if ((Browser.isDevice || (typeof navigator !== 'undefined' && navigator.platform === 'MacIntel' && navigator.maxTouchPoints > 1 && Browser.isTouch === true)) && _this.pageCount > 0 && !_this.isThumb && !(event.target.classList.contains('e-pv-hyperlink'))) {
1207
+ _this.handleTaps(touchPoints, event);
1130
1208
  }
1131
1209
  else if (!Browser.isDevice) {
1132
1210
  _this.handleTextBoxTaps(touchPoints);
@@ -1155,7 +1233,6 @@ var PdfViewerBase = /** @class */ (function () {
1155
1233
  _this.pdfViewer.textSelectionModule.initiateTouchSelection(event, _this.touchClientX, _this.touchClientY);
1156
1234
  if (Browser.isDevice) {
1157
1235
  clearTimeout(_this.singleTapTimer);
1158
- _this.singleTapTimer = null;
1159
1236
  _this.tapCount = 0;
1160
1237
  }
1161
1238
  }
@@ -2676,7 +2753,16 @@ var PdfViewerBase = /** @class */ (function () {
2676
2753
  }
2677
2754
  this.viewerContainer.addEventListener('mousedown', this.viewerContainerOnMousedown);
2678
2755
  this.viewerContainer.addEventListener('mouseup', this.viewerContainerOnMouseup);
2756
+ this.viewerContainer.addEventListener("wheel", this.detectTouchPad, false);
2679
2757
  this.viewerContainer.addEventListener('wheel', this.viewerContainerOnMouseWheel);
2758
+ if (this.isMacSafari) {
2759
+ window.addEventListener('gesturestart', function (e) { return e.preventDefault(); });
2760
+ window.addEventListener('gesturechange', function (e) { return e.preventDefault(); });
2761
+ window.addEventListener('gestureend', function (e) { return e.preventDefault(); });
2762
+ this.viewerContainer.addEventListener('gesturestart', this.handleMacGestureStart, false);
2763
+ this.viewerContainer.addEventListener('gesturechange', this.handleMacGestureChange, false);
2764
+ this.viewerContainer.addEventListener('gestureend', this.handleMacGestureEnd, false);
2765
+ }
2680
2766
  this.viewerContainer.addEventListener('mousemove', this.viewerContainerOnMousemove);
2681
2767
  this.viewerContainer.addEventListener('mouseleave', this.viewerContainerOnMouseLeave);
2682
2768
  this.viewerContainer.addEventListener('mouseenter', this.viewerContainerOnMouseEnter);
@@ -2700,6 +2786,12 @@ var PdfViewerBase = /** @class */ (function () {
2700
2786
  }
2701
2787
  else {
2702
2788
  this.viewerContainer.addEventListener('touchstart', this.viewerContainerOnTouchStart);
2789
+ if (this.isWebkitMobile && this.isDeviceiOS) {
2790
+ // eslint-disable-next-line max-len
2791
+ this.viewerContainer.addEventListener("touchmove", function (e) { if (e.scale !== 1) {
2792
+ e.preventDefault();
2793
+ } }, { passive: false });
2794
+ }
2703
2795
  this.viewerContainer.addEventListener('touchmove', this.viewerContainerOnTouchMove);
2704
2796
  this.viewerContainer.addEventListener('touchend', this.viewerContainerOnTouchEnd);
2705
2797
  this.viewerContainer.addEventListener('touchleave', this.viewerContainerOnTouchEnd);
@@ -2713,7 +2805,16 @@ var PdfViewerBase = /** @class */ (function () {
2713
2805
  }
2714
2806
  this.viewerContainer.removeEventListener('mousedown', this.viewerContainerOnMousedown);
2715
2807
  this.viewerContainer.removeEventListener('mouseup', this.viewerContainerOnMouseup);
2808
+ this.viewerContainer.removeEventListener("wheel", this.detectTouchPad, false);
2716
2809
  this.viewerContainer.removeEventListener('wheel', this.viewerContainerOnMouseWheel);
2810
+ if (this.isMacSafari) {
2811
+ window.removeEventListener('gesturestart', function (e) { return e.preventDefault(); });
2812
+ window.removeEventListener('gesturechange', function (e) { return e.preventDefault(); });
2813
+ window.removeEventListener('gestureend', function (e) { return e.preventDefault(); });
2814
+ this.viewerContainer.removeEventListener('gesturestart', this.handleMacGestureStart, false);
2815
+ this.viewerContainer.removeEventListener('gesturechange', this.handleMacGestureChange, false);
2816
+ this.viewerContainer.removeEventListener('gestureend', this.handleMacGestureEnd, false);
2817
+ }
2717
2818
  this.viewerContainer.removeEventListener('mousemove', this.viewerContainerOnMousemove);
2718
2819
  this.viewerContainer.removeEventListener('mouseleave', this.viewerContainerOnMouseLeave);
2719
2820
  this.viewerContainer.removeEventListener('mouseenter', this.viewerContainerOnMouseEnter);
@@ -2734,6 +2835,12 @@ var PdfViewerBase = /** @class */ (function () {
2734
2835
  }
2735
2836
  else {
2736
2837
  this.viewerContainer.removeEventListener('touchstart', this.viewerContainerOnTouchStart);
2838
+ if (this.isWebkitMobile && this.isDeviceiOS) {
2839
+ // eslint-disable-next-line max-len
2840
+ this.viewerContainer.removeEventListener("touchmove", function (e) { if (e.scale !== 1) {
2841
+ e.preventDefault();
2842
+ } }, false);
2843
+ }
2737
2844
  this.viewerContainer.removeEventListener('touchmove', this.viewerContainerOnTouchMove);
2738
2845
  this.viewerContainer.removeEventListener('touchend', this.viewerContainerOnTouchEnd);
2739
2846
  this.viewerContainer.removeEventListener('touchleave', this.viewerContainerOnTouchEnd);
@@ -2849,30 +2956,66 @@ var PdfViewerBase = /** @class */ (function () {
2849
2956
  }
2850
2957
  this.isViewerContainerDoubleClick = false;
2851
2958
  };
2852
- PdfViewerBase.prototype.handleTaps = function (touchPoints) {
2959
+ PdfViewerBase.prototype.handleTaps = function (touchPoints, event) {
2853
2960
  var _this = this;
2854
- if (!this.singleTapTimer) {
2855
- this.singleTapTimer = setTimeout(function () {
2856
- _this.onSingleTap(touchPoints);
2857
- // tslint:disable-next-line
2858
- }, 300);
2859
- this.tapCount++;
2961
+ //EJ2CORE-813 - Implemented focus removing logic for iOS devices
2962
+ if (this.isDeviceiOS) {
2963
+ var obj = findActiveElement(event, this, this.pdfViewer);
2964
+ // eslint-disable-next-line
2965
+ var isRemoveFocus_1 = !this.pdfViewer.annotation.freeTextAnnotationModule.isNewFreeTextAnnot && (obj && this.pdfViewer.selectedItems.annotations[0] ? obj.id !== this.pdfViewer.selectedItems.annotations[0].id : true) && document.activeElement.classList.contains('free-text-input') && this.isFreeTextAnnotation(this.pdfViewer.selectedItems.annotations);
2966
+ if (!this.singleTapTimer) {
2967
+ this.singleTapTimer = setTimeout(function () {
2968
+ if (isRemoveFocus_1) {
2969
+ _this.pdfViewer.clearSelection(_this.pdfViewer.selectedItems.annotations[0].pageIndex);
2970
+ _this.focusViewerContainer();
2971
+ }
2972
+ _this.onSingleTap(touchPoints);
2973
+ // eslint-disable-next-line
2974
+ }, 300);
2975
+ this.tapCount++;
2976
+ }
2977
+ else {
2978
+ if (this.pdfViewer.enablePinchZoom) {
2979
+ this.tapCount++;
2980
+ clearTimeout(this.singleTapTimer);
2981
+ this.singleTapTimer = null;
2982
+ this.onDoubleTap(touchPoints);
2983
+ }
2984
+ }
2860
2985
  }
2861
2986
  else {
2862
- if (this.pdfViewer.enablePinchZoom) {
2987
+ if (!this.singleTapTimer) {
2988
+ this.singleTapTimer = setTimeout(function () {
2989
+ _this.onSingleTap(touchPoints);
2990
+ // eslint-disable-next-line
2991
+ }, 300);
2863
2992
  this.tapCount++;
2864
- clearTimeout(this.singleTapTimer);
2865
- this.singleTapTimer = null;
2866
- this.onDoubleTap(touchPoints);
2993
+ }
2994
+ else {
2995
+ if (this.pdfViewer.enablePinchZoom) {
2996
+ this.tapCount++;
2997
+ clearTimeout(this.singleTapTimer);
2998
+ this.singleTapTimer = null;
2999
+ this.onDoubleTap(touchPoints);
3000
+ }
2867
3001
  }
2868
3002
  }
2869
3003
  };
2870
3004
  PdfViewerBase.prototype.handleTextBoxTaps = function (touchPoints) {
2871
3005
  var _this = this;
2872
- setTimeout(function () { _this.inputTapCount = 0; }, 300);
3006
+ setTimeout(function () {
3007
+ _this.inputTapCount = 0;
3008
+ }, 300);
2873
3009
  this.inputTapCount++;
2874
- // tslint:disable-next-line
2875
- var timer = setTimeout(function () { _this.onTextBoxDoubleTap(touchPoints); }, 200);
3010
+ if (this.isDeviceiOS) {
3011
+ // eslint-disable-next-line
3012
+ this.onTextBoxDoubleTap(touchPoints);
3013
+ }
3014
+ else {
3015
+ var timer = setTimeout(function () {
3016
+ _this.onTextBoxDoubleTap(touchPoints);
3017
+ }, 200);
3018
+ }
2876
3019
  if (this.inputTapCount > 2) {
2877
3020
  this.inputTapCount = 0;
2878
3021
  }
@@ -2971,7 +3114,7 @@ var PdfViewerBase = /** @class */ (function () {
2971
3114
  if (this.pdfViewer.textSelectionModule) {
2972
3115
  // tslint:disable-next-line:max-line-length
2973
3116
  if (!this.isPanMode && this.pdfViewer.enableTextSelection && !this.isTextSelectionDisabled && this.getSelectTextMarkupCurrentPage() == null) {
2974
- if (!(this.isWebkitMobile && Browser.isDevice)) {
3117
+ if (!(this.isWebkitMobile && (Browser.isDevice || (typeof navigator !== 'undefined' && navigator.platform === 'MacIntel' && navigator.maxTouchPoints > 1 && Browser.isTouch === true)))) {
2975
3118
  event.preventDefault();
2976
3119
  event.stopPropagation();
2977
3120
  }
@@ -3630,7 +3773,7 @@ var PdfViewerBase = /** @class */ (function () {
3630
3773
  var proxy = this;
3631
3774
  jsonObject = { action: 'RenderTaggedContent', elementId: this.pdfViewer.element.id, hashId: this.hashId, uniqueId: this.documentId, pageIndex: pageIndex };
3632
3775
  if (this.jsonDocumentId) {
3633
- jsonObject.document = this.jsonDocumentId;
3776
+ jsonObject.documentId = this.jsonDocumentId;
3634
3777
  }
3635
3778
  var url = this.pdfViewer.serviceUrl + '/' + "RenderTaggedContent";
3636
3779
  this.taggedTextHandler = new AjaxHandler(this.pdfViewer);
@@ -27,6 +27,8 @@ export declare class Magnification {
27
27
  private previousTouchDifference;
28
28
  private touchCenterX;
29
29
  private touchCenterY;
30
+ private mouseCenterX;
31
+ private mouseCenterY;
30
32
  private pageRerenderCount;
31
33
  private imageObjects;
32
34
  private topValue;
@@ -67,6 +69,10 @@ export declare class Magnification {
67
69
  * @private
68
70
  */
69
71
  isAutoZoom: boolean;
72
+ /**
73
+ * @private
74
+ */
75
+ isDoubleTapZoom: boolean;
70
76
  private isWebkitMobile;
71
77
  /**
72
78
  * @private
@@ -107,6 +113,11 @@ export declare class Magnification {
107
113
  * Returns zoom factor for the fit zooms.
108
114
  */
109
115
  private calculateFitZoomFactor;
116
+ /**
117
+ * Initiating cursor based zoom.
118
+ * @private
119
+ */
120
+ initiateMouseZoom(pointX: number, pointY: number, zoomValue: number): void;
110
121
  /**
111
122
  * Performs pinch in operation
112
123
  */
@@ -151,6 +162,7 @@ export declare class Magnification {
151
162
  private renderInSeparateThread;
152
163
  private responsivePages;
153
164
  private calculateScrollValues;
165
+ private calculateScrollValuesOnMouse;
154
166
  private rerenderOnScroll;
155
167
  /**
156
168
  * @private
@@ -208,4 +220,16 @@ export declare class Magnification {
208
220
  * @private
209
221
  */
210
222
  getModuleName(): string;
223
+ /**
224
+ * Returns the pinch step value.
225
+ * @param higherValue
226
+ * @param lowerValue
227
+ */
228
+ private getPinchStep;
229
+ /**
230
+ * Returns Point value respect to Main container.
231
+ * @param pointX
232
+ * @param pointY
233
+ */
234
+ private positionInViewer;
211
235
  }