@files-preview-app/preview-file 1.3.5 → 1.3.6

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/dist/vue.d.cts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as vue from 'vue';
2
2
  import { PropType } from 'vue';
3
- import { F as FileSource, P as PreviewPlugin, a as PreviewViewerOptions } from './index.d-B79v0jxi.cjs';
3
+ import { F as FileSource, P as PreviewPlugin, a as PreviewViewerOptions } from './index.d-DPqVo4OT.cjs';
4
4
 
5
5
  declare const FilePreview: vue.DefineComponent<vue.ExtractPropTypes<{
6
6
  src: {
package/dist/vue.d.ts CHANGED
@@ -1,6 +1,6 @@
1
1
  import * as vue from 'vue';
2
2
  import { PropType } from 'vue';
3
- import { F as FileSource, P as PreviewPlugin, a as PreviewViewerOptions } from './index.d-B79v0jxi.js';
3
+ import { F as FileSource, P as PreviewPlugin, a as PreviewViewerOptions } from './index.d-DPqVo4OT.js';
4
4
 
5
5
  declare const FilePreview: vue.DefineComponent<vue.ExtractPropTypes<{
6
6
  src: {
package/dist/vue.js CHANGED
@@ -495,6 +495,7 @@ var ICON_COPY = `<svg width="24" height="24" viewBox="0 0 24 24" fill="none" str
495
495
  var ICON_FAST_FORWARD = `<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polygon points="13 19 22 12 13 5 13 19"></polygon><polygon points="2 19 11 12 2 5 2 19"></polygon></svg>`;
496
496
  var ICON_REWIND = `<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><polygon points="11 19 2 12 11 5 11 19"></polygon><polygon points="22 19 13 12 22 5 22 19"></polygon></svg>`;
497
497
  var ICON_EXTERNAL_WINDOW = `<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="3" width="18" height="18" rx="2"></rect><line x1="3" y1="8" x2="21" y2="8"></line><circle cx="6" cy="5.5" r="0.75" fill="currentColor"></circle><circle cx="8.5" cy="5.5" r="0.75" fill="currentColor"></circle><polyline points="14 13 18 13 18 17"></polyline><line x1="11" y1="20" x2="18" y2="13"></line></svg>`;
498
+ var ICON_RESET_ZOOM = `<svg width="24" height="24" viewBox="0 0 24 24" fill="none" stroke="currentColor" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><circle cx="11" cy="11" r="8"></circle><line x1="21" y1="21" x2="16.65" y2="16.65"></line><path d="M13 11a3 3 0 1 0-3 3"></path><path d="M10 11v3h3"></path></svg>`;
498
499
  var ICON_MAP = {
499
500
  "zoom-in": ICON_ZOOM_IN,
500
501
  "zoom-out": ICON_ZOOM_OUT,
@@ -524,7 +525,10 @@ var ICON_MAP = {
524
525
  "open-window": ICON_EXTERNAL_WINDOW,
525
526
  "external-window": ICON_EXTERNAL_WINDOW,
526
527
  "openWindow": ICON_EXTERNAL_WINDOW,
527
- "openSeparateWindow": ICON_EXTERNAL_WINDOW
528
+ "openSeparateWindow": ICON_EXTERNAL_WINDOW,
529
+ "reset-zoom": ICON_RESET_ZOOM,
530
+ "zoom-reset": ICON_RESET_ZOOM,
531
+ "resetZoom": ICON_RESET_ZOOM
528
532
  };
529
533
  var ToolbarController = class {
530
534
  el;
@@ -557,6 +561,10 @@ var ToolbarController = class {
557
561
  this.config.fitToPage = false;
558
562
  this.config.fitWidth = false;
559
563
  }
564
+ if (actionId === "reset-zoom" || actionId === "zoom-reset" || actionId === "resetZoom") {
565
+ this.config.resetZoom = false;
566
+ this.config.zoomReset = false;
567
+ }
560
568
  if (actionId === "rotate-cw" || actionId === "rotate" || actionId === "rotateCW") this.config.rotate = false;
561
569
  if (actionId === "fullscreen") this.config.fullscreen = false;
562
570
  if (actionId === "download") this.config.download = false;
@@ -581,6 +589,10 @@ var ToolbarController = class {
581
589
  this.config.fitToPage = true;
582
590
  this.config.fitWidth = true;
583
591
  }
592
+ if (actionId === "reset-zoom" || actionId === "zoom-reset" || actionId === "resetZoom") {
593
+ this.config.resetZoom = true;
594
+ this.config.zoomReset = true;
595
+ }
584
596
  if (actionId === "rotate-cw" || actionId === "rotate" || actionId === "rotateCW") this.config.rotate = true;
585
597
  if (actionId === "fullscreen") this.config.fullscreen = true;
586
598
  if (actionId === "download") this.config.download = true;
@@ -600,6 +612,7 @@ var ToolbarController = class {
600
612
  if (actionId === "zoomIn") return "zoom-in";
601
613
  if (actionId === "zoomOut") return "zoom-out";
602
614
  if (actionId === "fitPage" || actionId === "fitToPage" || actionId === "fitWidth") return "fit-page";
615
+ if (actionId === "resetZoom" || actionId === "zoomReset") return "reset-zoom";
603
616
  if (actionId === "rotateCW") return "rotate-cw";
604
617
  if (actionId === "rotateCCW") return "rotate-ccw";
605
618
  if (actionId === "openWindow" || actionId === "openSeparateWindow") return "open-window";
@@ -642,6 +655,9 @@ var ToolbarController = class {
642
655
  if ((id === "fit-page" || id === "fit-width" || id === "fit-slide") && (c.fitPage === false || c.fitToPage === false || c.fitWidth === false || c["fit-page"] === false || c["fit-width"] === false)) {
643
656
  return false;
644
657
  }
658
+ if ((id === "reset-zoom" || id === "zoom-reset") && (c.resetZoom === false || c.zoomReset === false || c["reset-zoom"] === false || c["zoom-reset"] === false)) {
659
+ return false;
660
+ }
645
661
  if ((id === "rotate-cw" || id === "rotate-ccw" || id === "rotate") && (c.rotate === false || c.rotateCW === false || c.rotateCCW === false || c["rotate-cw"] === false)) {
646
662
  return false;
647
663
  }
@@ -1088,6 +1104,9 @@ var FilePreviewViewer = class _FilePreviewViewer {
1088
1104
  this.activeInstance = instance;
1089
1105
  instance.openInSeparateWindow = () => this.openInSeparateWindow();
1090
1106
  instance.toggleThumbnails = () => this.toggleThumbnails();
1107
+ if (!instance.resetZoom && instance.fitToPage) {
1108
+ instance.resetZoom = () => instance.fitToPage?.();
1109
+ }
1091
1110
  this.hideLoading();
1092
1111
  this.eventEmitter.emit("loaded", { metadata, plugin: matchedPlugin.id });
1093
1112
  const isToolbarVisible = options.showToolbar !== false && options.toolbar !== false;
@@ -1371,6 +1390,16 @@ var FilePreviewViewer = class _FilePreviewViewer {
1371
1390
  fitToPage() {
1372
1391
  this.activeInstance?.fitToPage?.();
1373
1392
  }
1393
+ /**
1394
+ * Reset zoom level to initial/default fit state.
1395
+ */
1396
+ resetZoom() {
1397
+ if (this.activeInstance?.resetZoom) {
1398
+ this.activeInstance.resetZoom();
1399
+ } else if (this.activeInstance?.fitToPage) {
1400
+ this.activeInstance.fitToPage();
1401
+ }
1402
+ }
1374
1403
  /**
1375
1404
  * Zoom in.
1376
1405
  */
@@ -1992,6 +2021,14 @@ var PdfPlugin = class {
1992
2021
  group: "zoom",
1993
2022
  execute: () => instance.fitToPage?.()
1994
2023
  },
2024
+ {
2025
+ id: "reset-zoom",
2026
+ icon: "reset-zoom",
2027
+ label: "Reset Zoom",
2028
+ type: "button",
2029
+ group: "zoom",
2030
+ execute: () => instance.resetZoom?.()
2031
+ },
1995
2032
  {
1996
2033
  id: "fit-width",
1997
2034
  icon: "fit-width",
@@ -2254,6 +2291,14 @@ var PdfPlugin = class {
2254
2291
  zoomScale = 1;
2255
2292
  renderPage(currentPage);
2256
2293
  },
2294
+ resetZoom: () => {
2295
+ fitMode = "page";
2296
+ zoomScale = 1;
2297
+ rotation = 0;
2298
+ container.scrollTop = 0;
2299
+ container.scrollLeft = 0;
2300
+ renderPage(currentPage);
2301
+ },
2257
2302
  fitToWidth: () => {
2258
2303
  fitMode = "width";
2259
2304
  zoomScale = 1;
@@ -2421,6 +2466,16 @@ var MediaPlugin = class {
2421
2466
  instance.fitToPage?.();
2422
2467
  }
2423
2468
  },
2469
+ {
2470
+ id: "reset-zoom",
2471
+ icon: "reset-zoom",
2472
+ label: "Reset Zoom",
2473
+ type: "button",
2474
+ group: "zoom",
2475
+ execute: () => {
2476
+ instance.resetZoom?.();
2477
+ }
2478
+ },
2424
2479
  {
2425
2480
  id: "rotate-cw",
2426
2481
  icon: "rotate-cw",
@@ -2594,6 +2649,13 @@ var MediaPlugin = class {
2594
2649
  rotation = 0;
2595
2650
  applyTransform();
2596
2651
  } : void 0,
2652
+ resetZoom: isImage ? () => {
2653
+ currentZoom = 1;
2654
+ rotation = 0;
2655
+ ctx.container.scrollTop = 0;
2656
+ ctx.container.scrollLeft = 0;
2657
+ applyTransform();
2658
+ } : void 0,
2597
2659
  rotateCW: isImage || isVideo ? () => {
2598
2660
  rotation = (rotation + 90) % 360;
2599
2661
  applyTransform();
@@ -2710,6 +2772,14 @@ var DocxPlugin = class {
2710
2772
  group: "zoom",
2711
2773
  execute: () => instance.fitToPage?.()
2712
2774
  },
2775
+ {
2776
+ id: "reset-zoom",
2777
+ icon: "reset-zoom",
2778
+ label: "Reset Zoom",
2779
+ type: "button",
2780
+ group: "zoom",
2781
+ execute: () => instance.resetZoom?.()
2782
+ },
2713
2783
  {
2714
2784
  id: "rotate-cw",
2715
2785
  icon: "rotate-cw",
@@ -3026,6 +3096,14 @@ var DocxPlugin = class {
3026
3096
  rotation = 0;
3027
3097
  applyTransform();
3028
3098
  },
3099
+ resetZoom: () => {
3100
+ isUserZoomed = false;
3101
+ scale = calculateFitScale("page");
3102
+ rotation = 0;
3103
+ ctx.container.scrollTop = 0;
3104
+ ctx.container.scrollLeft = 0;
3105
+ applyTransform();
3106
+ },
3029
3107
  rotateCW: () => {
3030
3108
  rotation = (rotation + 90) % 360;
3031
3109
  applyTransform();
@@ -3475,6 +3553,16 @@ var ExcelPlugin = class {
3475
3553
  instance.zoomIn?.();
3476
3554
  }
3477
3555
  },
3556
+ {
3557
+ id: "reset-zoom",
3558
+ icon: "reset-zoom",
3559
+ label: "Reset Zoom",
3560
+ type: "button",
3561
+ group: "zoom",
3562
+ execute: () => {
3563
+ instance.resetZoom?.();
3564
+ }
3565
+ },
3478
3566
  {
3479
3567
  id: "download",
3480
3568
  icon: "download",
@@ -3662,6 +3750,12 @@ var ExcelPlugin = class {
3662
3750
  scale = calculateFitScale();
3663
3751
  applyTransform();
3664
3752
  },
3753
+ resetZoom: () => {
3754
+ scale = calculateFitScale();
3755
+ contentArea.scrollTop = 0;
3756
+ contentArea.scrollLeft = 0;
3757
+ applyTransform();
3758
+ },
3665
3759
  rotateCW: () => {
3666
3760
  },
3667
3761
  rotateCCW: () => {
@@ -3792,6 +3886,16 @@ var CsvPlugin = class {
3792
3886
  instance.zoomIn?.();
3793
3887
  }
3794
3888
  },
3889
+ {
3890
+ id: "reset-zoom",
3891
+ icon: "reset-zoom",
3892
+ label: "Reset Zoom",
3893
+ type: "button",
3894
+ group: "zoom",
3895
+ execute: () => {
3896
+ instance.resetZoom?.();
3897
+ }
3898
+ },
3795
3899
  {
3796
3900
  id: "download",
3797
3901
  icon: "download",
@@ -3981,6 +4085,12 @@ var CsvPlugin = class {
3981
4085
  scale = calculateFitScale();
3982
4086
  applyScale();
3983
4087
  },
4088
+ resetZoom: () => {
4089
+ scale = calculateFitScale();
4090
+ container.scrollTop = 0;
4091
+ container.scrollLeft = 0;
4092
+ applyScale();
4093
+ },
3984
4094
  rotateCW: () => {
3985
4095
  },
3986
4096
  rotateCCW: () => {
@@ -4096,6 +4206,16 @@ var CodePlugin = class {
4096
4206
  instance.zoomIn?.();
4097
4207
  }
4098
4208
  },
4209
+ {
4210
+ id: "reset-zoom",
4211
+ icon: "reset-zoom",
4212
+ label: "Reset Zoom",
4213
+ type: "button",
4214
+ group: "zoom",
4215
+ execute: () => {
4216
+ instance.resetZoom?.();
4217
+ }
4218
+ },
4099
4219
  {
4100
4220
  id: "copy",
4101
4221
  icon: "copy",
@@ -4375,6 +4495,15 @@ var CodePlugin = class {
4375
4495
  zoomLevel = isTxt ? calculateTxtFit() : 1;
4376
4496
  updateTransform();
4377
4497
  },
4498
+ resetZoom: () => {
4499
+ isUserZoomed = false;
4500
+ fontSize = 13;
4501
+ rotation = 0;
4502
+ zoomLevel = isTxt ? calculateTxtFit() : 1;
4503
+ container.scrollTop = 0;
4504
+ container.scrollLeft = 0;
4505
+ updateTransform();
4506
+ },
4378
4507
  rotateCW: () => {
4379
4508
  rotation = (rotation + 90) % 360;
4380
4509
  updateTransform();
@@ -4437,11 +4566,19 @@ var ArchivePlugin = class {
4437
4566
  {
4438
4567
  id: "fit-page",
4439
4568
  icon: "fit-page",
4440
- label: "Reset Zoom",
4569
+ label: "Fit to Page",
4441
4570
  type: "button",
4442
4571
  group: "zoom",
4443
4572
  execute: () => instance.fitToPage?.()
4444
4573
  },
4574
+ {
4575
+ id: "reset-zoom",
4576
+ icon: "reset-zoom",
4577
+ label: "Reset Zoom",
4578
+ type: "button",
4579
+ group: "zoom",
4580
+ execute: () => instance.resetZoom?.()
4581
+ },
4445
4582
  {
4446
4583
  id: "download",
4447
4584
  icon: "download",
@@ -4596,7 +4733,13 @@ var ArchivePlugin = class {
4596
4733
  },
4597
4734
  fitToPage: () => {
4598
4735
  scale = 1;
4599
- wrapper.style.transform = `scale(1)`;
4736
+ wrapper.style.transform = "scale(1)";
4737
+ },
4738
+ resetZoom: () => {
4739
+ scale = 1;
4740
+ wrapper.style.transform = "scale(1)";
4741
+ ctx.container.scrollTop = 0;
4742
+ ctx.container.scrollLeft = 0;
4600
4743
  },
4601
4744
  download: () => {
4602
4745
  downloadFile(ctx.buffer, ctx.metadata.name || "archive.zip", "application/zip");
@@ -4648,6 +4791,14 @@ var MarkdownPlugin = class {
4648
4791
  group: "zoom",
4649
4792
  execute: () => instance.fitToPage?.()
4650
4793
  },
4794
+ {
4795
+ id: "reset-zoom",
4796
+ icon: "reset-zoom",
4797
+ label: "Reset Zoom",
4798
+ type: "button",
4799
+ group: "zoom",
4800
+ execute: () => instance.resetZoom?.()
4801
+ },
4651
4802
  {
4652
4803
  id: "copy",
4653
4804
  icon: "copy",
@@ -4801,6 +4952,12 @@ var MarkdownPlugin = class {
4801
4952
  fontSize = 15;
4802
4953
  wrapper.style.fontSize = "15px";
4803
4954
  },
4955
+ resetZoom: () => {
4956
+ fontSize = 15;
4957
+ wrapper.style.fontSize = "15px";
4958
+ ctx.container.scrollTop = 0;
4959
+ ctx.container.scrollLeft = 0;
4960
+ },
4804
4961
  download: () => {
4805
4962
  downloadFile(ctx.buffer, ctx.metadata.name || "document.md", "text/markdown");
4806
4963
  },
@@ -4894,6 +5051,14 @@ var PptxPlugin = class {
4894
5051
  group: "zoom",
4895
5052
  execute: () => instance.fitToPage?.()
4896
5053
  },
5054
+ {
5055
+ id: "reset-zoom",
5056
+ icon: "reset-zoom",
5057
+ label: "Reset Zoom",
5058
+ type: "button",
5059
+ group: "zoom",
5060
+ execute: () => instance.resetZoom?.()
5061
+ },
4897
5062
  {
4898
5063
  id: "rotate-cw",
4899
5064
  icon: "rotate-cw",
@@ -5013,6 +5178,13 @@ var PptxPlugin = class {
5013
5178
  rotation = 0;
5014
5179
  applyTransform();
5015
5180
  },
5181
+ resetZoom: () => {
5182
+ scale = calculateFitScale();
5183
+ rotation = 0;
5184
+ wrapper.scrollTop = 0;
5185
+ wrapper.scrollLeft = 0;
5186
+ applyTransform();
5187
+ },
5016
5188
  rotateCW: () => {
5017
5189
  rotation = (rotation + 90) % 360;
5018
5190
  applyTransform();
@@ -5088,6 +5260,14 @@ var ThreeDPlugin = class {
5088
5260
  group: "zoom",
5089
5261
  execute: () => instance.fitToPage?.()
5090
5262
  },
5263
+ {
5264
+ id: "reset-zoom",
5265
+ icon: "reset-zoom",
5266
+ label: "Reset Zoom",
5267
+ type: "button",
5268
+ group: "zoom",
5269
+ execute: () => instance.resetZoom?.()
5270
+ },
5091
5271
  {
5092
5272
  id: "rotate-cw",
5093
5273
  icon: "rotate-cw",
@@ -5224,6 +5404,7 @@ var ThreeDPlugin = class {
5224
5404
  controls.update();
5225
5405
  },
5226
5406
  fitToPage: fitCamera,
5407
+ resetZoom: fitCamera,
5227
5408
  rotateCW: () => {
5228
5409
  isWireframe = !isWireframe;
5229
5410
  materials.forEach((m) => {
@@ -5438,6 +5619,14 @@ var RtfPlugin = class {
5438
5619
  group: "zoom",
5439
5620
  execute: () => instance.fitToPage?.()
5440
5621
  },
5622
+ {
5623
+ id: "reset-zoom",
5624
+ icon: "reset-zoom",
5625
+ label: "Reset Zoom",
5626
+ type: "button",
5627
+ group: "zoom",
5628
+ execute: () => instance.resetZoom?.()
5629
+ },
5441
5630
  {
5442
5631
  id: "rotate-cw",
5443
5632
  icon: "rotate-cw",
@@ -5907,6 +6096,15 @@ var RtfPlugin = class {
5907
6096
  rotation = 0;
5908
6097
  applyTransform();
5909
6098
  },
6099
+ resetZoom: () => {
6100
+ isUserZoomed = false;
6101
+ fitMode = "width";
6102
+ scale = calculateFitScale("width");
6103
+ rotation = 0;
6104
+ ctx.container.scrollTop = 0;
6105
+ ctx.container.scrollLeft = 0;
6106
+ applyTransform();
6107
+ },
5910
6108
  rotateCW: () => {
5911
6109
  rotation = (rotation + 90) % 360;
5912
6110
  applyTransform();
@@ -5974,6 +6172,14 @@ var HtmlPreviewPlugin = class {
5974
6172
  group: "zoom",
5975
6173
  execute: () => instance.fitToPage?.()
5976
6174
  },
6175
+ {
6176
+ id: "reset-zoom",
6177
+ icon: "reset-zoom",
6178
+ label: "Reset Zoom",
6179
+ type: "button",
6180
+ group: "zoom",
6181
+ execute: () => instance.resetZoom?.()
6182
+ },
5977
6183
  {
5978
6184
  id: "copy",
5979
6185
  icon: "copy",
@@ -6046,6 +6252,12 @@ var HtmlPreviewPlugin = class {
6046
6252
  scale = 1;
6047
6253
  iframe.style.transform = "scale(1)";
6048
6254
  },
6255
+ resetZoom: () => {
6256
+ scale = 1;
6257
+ iframe.style.transform = "scale(1)";
6258
+ ctx.container.scrollTop = 0;
6259
+ ctx.container.scrollLeft = 0;
6260
+ },
6049
6261
  copy: () => {
6050
6262
  navigator.clipboard.writeText(rawHtml);
6051
6263
  },
@@ -6146,6 +6358,14 @@ var OpenDocumentPlugin = class {
6146
6358
  group: "zoom",
6147
6359
  execute: () => instance.fitToPage?.()
6148
6360
  },
6361
+ {
6362
+ id: "reset-zoom",
6363
+ icon: "reset-zoom",
6364
+ label: "Reset Zoom",
6365
+ type: "button",
6366
+ group: "zoom",
6367
+ execute: () => instance.resetZoom?.()
6368
+ },
6149
6369
  {
6150
6370
  id: "rotate-cw",
6151
6371
  icon: "rotate-cw",
@@ -6413,6 +6633,15 @@ var OpenDocumentPlugin = class {
6413
6633
  rotation = 0;
6414
6634
  applyTransform();
6415
6635
  },
6636
+ resetZoom: () => {
6637
+ isUserZoomed = false;
6638
+ fitMode = "width";
6639
+ scale = calculateFitScale("width");
6640
+ rotation = 0;
6641
+ container.scrollTop = 0;
6642
+ container.scrollLeft = 0;
6643
+ applyTransform();
6644
+ },
6416
6645
  rotateCW: () => {
6417
6646
  rotation = (rotation + 90) % 360;
6418
6647
  applyTransform();
@@ -6756,6 +6985,14 @@ var DocPlugin = class {
6756
6985
  group: "zoom",
6757
6986
  execute: () => instance.fitToPage?.()
6758
6987
  },
6988
+ {
6989
+ id: "reset-zoom",
6990
+ icon: "reset-zoom",
6991
+ label: "Reset Zoom",
6992
+ type: "button",
6993
+ group: "zoom",
6994
+ execute: () => instance.resetZoom?.()
6995
+ },
6759
6996
  {
6760
6997
  id: "rotate-cw",
6761
6998
  icon: "rotate-cw",
@@ -6962,6 +7199,15 @@ var DocPlugin = class {
6962
7199
  rotation = 0;
6963
7200
  applyTransform();
6964
7201
  },
7202
+ resetZoom: () => {
7203
+ isUserZoomed = false;
7204
+ fitMode = "width";
7205
+ scale = calculateFitScale("width");
7206
+ rotation = 0;
7207
+ ctx.container.scrollTop = 0;
7208
+ ctx.container.scrollLeft = 0;
7209
+ applyTransform();
7210
+ },
6965
7211
  rotateCW: () => {
6966
7212
  rotation = (rotation + 90) % 360;
6967
7213
  applyTransform();
@@ -7442,6 +7688,14 @@ var PptPlugin = class {
7442
7688
  group: "zoom",
7443
7689
  execute: () => instance.fitToPage?.()
7444
7690
  },
7691
+ {
7692
+ id: "reset-zoom",
7693
+ icon: "reset-zoom",
7694
+ label: "Reset Zoom",
7695
+ type: "button",
7696
+ group: "zoom",
7697
+ execute: () => instance.resetZoom?.()
7698
+ },
7445
7699
  {
7446
7700
  id: "rotate-cw",
7447
7701
  icon: "rotate-cw",
@@ -7630,6 +7884,13 @@ var PptPlugin = class {
7630
7884
  rotation = 0;
7631
7885
  applyTransform();
7632
7886
  },
7887
+ resetZoom: () => {
7888
+ scale = calculateFitScale();
7889
+ rotation = 0;
7890
+ container.scrollTop = 0;
7891
+ container.scrollLeft = 0;
7892
+ applyTransform();
7893
+ },
7633
7894
  rotateCW: () => {
7634
7895
  rotation = (rotation + 90) % 360;
7635
7896
  applyTransform();