pptx-react-viewer 4.3.0 → 4.5.0

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.
Files changed (136) hide show
  1. package/CHANGELOG.md +143 -0
  2. package/dist/{AiChatPanel-UCEK3ZTD.mjs → AiChatPanel-HXGCZPUX.mjs} +4 -4
  3. package/dist/AiChatPanel-HXGCZPUX.mjs.br +0 -0
  4. package/dist/AiChatPanel-HXGCZPUX.mjs.gz +0 -0
  5. package/dist/{AiChatPanel-7UQA25FA.js → AiChatPanel-P2N6X2KB.js} +28 -28
  6. package/dist/AiChatPanel-P2N6X2KB.js.br +0 -0
  7. package/dist/AiChatPanel-P2N6X2KB.js.gz +0 -0
  8. package/dist/{Model3DScene-X3DS3ELB.js → Model3DScene-PIFMH2TU.js} +2 -2
  9. package/dist/Model3DScene-PIFMH2TU.js.br +0 -0
  10. package/dist/Model3DScene-PIFMH2TU.js.gz +0 -0
  11. package/dist/{Model3DScene-AI2JTBQM.mjs → Model3DScene-QXMMJRV3.mjs} +1 -1
  12. package/dist/Model3DScene-QXMMJRV3.mjs.br +0 -0
  13. package/dist/Model3DScene-QXMMJRV3.mjs.gz +0 -0
  14. package/dist/{chunk-E7O4HTS5.js → chunk-6FVYG27J.js} +211 -187
  15. package/dist/chunk-6FVYG27J.js.br +0 -0
  16. package/dist/chunk-6FVYG27J.js.gz +0 -0
  17. package/dist/{chunk-OBQ453H6.mjs → chunk-APAVAD2A.mjs} +37 -0
  18. package/dist/chunk-APAVAD2A.mjs.br +0 -0
  19. package/dist/chunk-APAVAD2A.mjs.gz +0 -0
  20. package/dist/{chunk-YQJOCGOK.mjs → chunk-DX2JCSQ4.mjs} +1 -1
  21. package/dist/chunk-DX2JCSQ4.mjs.br +0 -0
  22. package/dist/chunk-DX2JCSQ4.mjs.gz +0 -0
  23. package/dist/{chunk-RXYLPESV.mjs → chunk-IDV2ITXM.mjs} +607 -102
  24. package/dist/chunk-IDV2ITXM.mjs.br +0 -0
  25. package/dist/chunk-IDV2ITXM.mjs.gz +0 -0
  26. package/dist/{chunk-UTI4CLYJ.js → chunk-LYZQLV7R.js} +3417 -1722
  27. package/dist/chunk-LYZQLV7R.js.br +0 -0
  28. package/dist/chunk-LYZQLV7R.js.gz +0 -0
  29. package/dist/{chunk-SKTZSG7Q.mjs → chunk-PRXJ3J5W.mjs} +325 -48
  30. package/dist/chunk-PRXJ3J5W.mjs.br +0 -0
  31. package/dist/chunk-PRXJ3J5W.mjs.gz +0 -0
  32. package/dist/{chunk-KAO5USPE.js → chunk-T35BGKZG.js} +5 -5
  33. package/dist/chunk-T35BGKZG.js.br +0 -0
  34. package/dist/chunk-T35BGKZG.js.gz +0 -0
  35. package/dist/{chunk-W5KLLGVH.js → chunk-UMQV2432.js} +37 -0
  36. package/dist/chunk-UMQV2432.js.br +0 -0
  37. package/dist/chunk-UMQV2432.js.gz +0 -0
  38. package/dist/{chunk-42XEZVUQ.js → chunk-UZFCFYK6.js} +1667 -1162
  39. package/dist/chunk-UZFCFYK6.js.br +0 -0
  40. package/dist/chunk-UZFCFYK6.js.gz +0 -0
  41. package/dist/{chunk-3UWJWJCR.mjs → chunk-VZNIVS3X.mjs} +3397 -1723
  42. package/dist/chunk-VZNIVS3X.mjs.br +0 -0
  43. package/dist/chunk-VZNIVS3X.mjs.gz +0 -0
  44. package/dist/{chunk-Y7LI2JIR.js → chunk-Y4VRYQQS.js} +1123 -846
  45. package/dist/chunk-Y4VRYQQS.js.br +0 -0
  46. package/dist/chunk-Y4VRYQQS.js.gz +0 -0
  47. package/dist/{chunk-PLDG3CXW.mjs → chunk-ZF5S3HHW.mjs} +31 -7
  48. package/dist/chunk-ZF5S3HHW.mjs.br +0 -0
  49. package/dist/chunk-ZF5S3HHW.mjs.gz +0 -0
  50. package/dist/i18n/de.cjs +33 -0
  51. package/dist/i18n/de.cjs.br +0 -0
  52. package/dist/i18n/de.cjs.gz +0 -0
  53. package/dist/i18n/de.mjs +33 -0
  54. package/dist/i18n/de.mjs.br +0 -0
  55. package/dist/i18n/de.mjs.gz +0 -0
  56. package/dist/i18n/es.cjs +33 -0
  57. package/dist/i18n/es.cjs.br +0 -0
  58. package/dist/i18n/es.cjs.gz +0 -0
  59. package/dist/i18n/es.mjs +33 -0
  60. package/dist/i18n/es.mjs.br +0 -0
  61. package/dist/i18n/es.mjs.gz +0 -0
  62. package/dist/i18n/fr.cjs +33 -0
  63. package/dist/i18n/fr.cjs.br +0 -0
  64. package/dist/i18n/fr.cjs.gz +0 -0
  65. package/dist/i18n/fr.mjs +33 -0
  66. package/dist/i18n/fr.mjs.br +0 -0
  67. package/dist/i18n/fr.mjs.gz +0 -0
  68. package/dist/i18n/zh-CN.cjs +33 -0
  69. package/dist/i18n/zh-CN.cjs.br +0 -0
  70. package/dist/i18n/zh-CN.cjs.gz +0 -0
  71. package/dist/i18n/zh-CN.mjs +33 -0
  72. package/dist/i18n/zh-CN.mjs.br +0 -0
  73. package/dist/i18n/zh-CN.mjs.gz +0 -0
  74. package/dist/i18n.js +4 -4
  75. package/dist/i18n.js.br +0 -0
  76. package/dist/i18n.js.gz +0 -0
  77. package/dist/i18n.mjs +1 -1
  78. package/dist/i18n.mjs.br +0 -0
  79. package/dist/i18n.mjs.gz +0 -0
  80. package/dist/index.d.ts +116 -8
  81. package/dist/index.js +49 -49
  82. package/dist/index.js.br +0 -0
  83. package/dist/index.js.gz +0 -0
  84. package/dist/index.mjs +6 -6
  85. package/dist/index.mjs.br +0 -0
  86. package/dist/index.mjs.gz +0 -0
  87. package/dist/internals.d.ts +228 -44
  88. package/dist/internals.js +105 -105
  89. package/dist/internals.js.br +0 -0
  90. package/dist/internals.js.gz +0 -0
  91. package/dist/internals.mjs +4 -4
  92. package/dist/internals.mjs.br +0 -0
  93. package/dist/internals.mjs.gz +0 -0
  94. package/dist/pptx-viewer.css +1 -1
  95. package/dist/pptx-viewer.css.br +0 -0
  96. package/dist/pptx-viewer.css.gz +0 -0
  97. package/dist/viewer/index.d.ts +97 -8
  98. package/dist/viewer/index.js +27 -27
  99. package/dist/viewer/index.js.br +0 -0
  100. package/dist/viewer/index.js.gz +0 -0
  101. package/dist/viewer/index.mjs +6 -6
  102. package/dist/viewer/index.mjs.br +0 -0
  103. package/dist/viewer/index.mjs.gz +0 -0
  104. package/package.json +1 -1
  105. package/dist/AiChatPanel-7UQA25FA.js.br +0 -0
  106. package/dist/AiChatPanel-7UQA25FA.js.gz +0 -0
  107. package/dist/AiChatPanel-UCEK3ZTD.mjs.br +0 -0
  108. package/dist/AiChatPanel-UCEK3ZTD.mjs.gz +0 -0
  109. package/dist/Model3DScene-AI2JTBQM.mjs.br +0 -0
  110. package/dist/Model3DScene-AI2JTBQM.mjs.gz +0 -0
  111. package/dist/Model3DScene-X3DS3ELB.js.br +0 -0
  112. package/dist/Model3DScene-X3DS3ELB.js.gz +0 -0
  113. package/dist/chunk-3UWJWJCR.mjs.br +0 -0
  114. package/dist/chunk-3UWJWJCR.mjs.gz +0 -0
  115. package/dist/chunk-42XEZVUQ.js.br +0 -0
  116. package/dist/chunk-42XEZVUQ.js.gz +0 -0
  117. package/dist/chunk-E7O4HTS5.js.br +0 -0
  118. package/dist/chunk-E7O4HTS5.js.gz +0 -0
  119. package/dist/chunk-KAO5USPE.js.br +0 -0
  120. package/dist/chunk-KAO5USPE.js.gz +0 -0
  121. package/dist/chunk-OBQ453H6.mjs.br +0 -0
  122. package/dist/chunk-OBQ453H6.mjs.gz +0 -0
  123. package/dist/chunk-PLDG3CXW.mjs.br +0 -0
  124. package/dist/chunk-PLDG3CXW.mjs.gz +0 -0
  125. package/dist/chunk-RXYLPESV.mjs.br +0 -0
  126. package/dist/chunk-RXYLPESV.mjs.gz +0 -0
  127. package/dist/chunk-SKTZSG7Q.mjs.br +0 -0
  128. package/dist/chunk-SKTZSG7Q.mjs.gz +0 -0
  129. package/dist/chunk-UTI4CLYJ.js.br +0 -0
  130. package/dist/chunk-UTI4CLYJ.js.gz +0 -0
  131. package/dist/chunk-W5KLLGVH.js.br +0 -0
  132. package/dist/chunk-W5KLLGVH.js.gz +0 -0
  133. package/dist/chunk-Y7LI2JIR.js.br +0 -0
  134. package/dist/chunk-Y7LI2JIR.js.gz +0 -0
  135. package/dist/chunk-YQJOCGOK.mjs.br +0 -0
  136. package/dist/chunk-YQJOCGOK.mjs.gz +0 -0
@@ -1,6 +1,6 @@
1
- import { DEFAULT_STROKE_COLOR, getConnectorPathGeometry, buildLineShadowCss, buildLineGlowFilter, renderConnectorMarker, getShapeVisualStyle, getTextStyleForElement, DEFAULT_TEXT_COLOR, renderVectorShape, isConnectorOrLineElement, build3DExtrusionData, getImageRenderStyle, cn, getImageSurfaceStyle, getTextLayoutStyle, renderTableElement, renderMediaElement, shouldRenderFallbackLabel, DEFAULT_FILL_COLOR, getCropShapeClipPath, hasDagDuotoneEffect, renderDagDuotoneSvgFilter, getImageSurfaceMaskStyle, getDuotoneColors, getTextWarpStyle, renderTextSegments, buildReactChartViewModel, renderChartElement, MIN_ELEMENT_SIZE, buildTextBody3DSceneStyle, getImageTilingStyle, DEFAULT_TEXT_FONT_SIZE, DEFAULT_FONT_FAMILY, HYPERLINK_COLOR, cloneHistorySnapshot, ZOOM_TO_SELECTION_PADDING, DEFAULT_CANVAS_HEIGHT, DEFAULT_CANVAS_WIDTH, UNGROUPED_SECTION_ID, DEFAULT_SECTION_GROUP_ID, DEFAULT_TABLE_ROWS, DEFAULT_TABLE_COLUMNS, buildPdfFromTiledImageData, GRID_SIZE, buildNotesPdf } from './chunk-PLDG3CXW.mjs';
2
- import { GlyphOutlineFontCache, createGlyphOutlineLookup, DEFAULT_VIEWER_OPTIONS, TOOLBAR_TABS, defineThreeViewElement, getSelectionControlArtworkStyle, hasShapeProperties, normalizeHexColor, colorWithOpacity, normalizeStrokeDashType, getSvgStrokeDasharray, getCompoundLineOffsets, getCompoundLineWidths, svgLineCap, hasTextProperties, getSelectionOutlineColor, connectorWrapperTransform, getAriaRoleDescription, getAriaLabel, getAriaRole, resolveElementInteractivity, isEditableTextElement, buildTextStyleOverrideCss, isElementRendered, resolveElementAriaAttributes, isMediaFullscreenActive, shouldRenderHitTarget, elementHitTargetStyle, getImageEffectsOpacity, getImageEffectsFilter, inlineElementPointerEvents, isHollowShapeElement, LINK_TOOLTIP_HOST_CLASS, ACTION_BUTTON_PRESETS, mediaTransportVisible, isInkElement, getGroupChildParentFill, getElementLabel, getResizeHandleHitAreaStyle, paintedStrokeWidth, buildCssGradientFromShapeStyle, ensureActionAffordanceStyles, resolveElementActionAffordance, actionAffordanceLabels, paintedElementSize, MEDIA_FULLSCREEN_OVERLAY_STYLE, elementContainerHeightStyle, getElementTransform, resolveElementHighlightClick, applyHighlightClickStyle, getComputedEffectStyle, getSoftEdgeSvgFilter, getEffectStyleSource, getBevelLightingSvgFilter, buildStrokeOutline, buildHollowHitOutline, buildSubpathFillOverlay, isImageLikeElement, strokeOutlineViewBox, resolveRevealedSmartArtNodes, resolveRevealedDrawingShapes, buildSmartArtA11y, canDrillDown, computeSmartArtElementLayout, flattenNodes, buildSummaryZoomView, isImageTiled, getImageColorWashStyle, readEditableText, placeCaretAtEnd, getPendingSelectionRestore, restoreSegmentSelection, getTextCompensationTransform, mapInlineTextFormatKey, subscribeBarFacePicturePixelSamples, getBarFacePicturePixelSampleVersion, ensureChartInteractionStyles, applyChartPartHighlight, resolveRevealedChartData, formatAxisValue, buildInkGroupStrokes, getInkReplayStyles, INK_REPLAY_KEYFRAMES, buildContentPartStrokes, getContentPartReplayStyles, resolveOleType, getOleAriaLabel, getOleTypeColor, getOleTypeLabel, filterRenderedElements, resolveGroupChildFill, isLinkedTextBox, getOverflowSegments, shouldUseSvgWarp, getTextBodyRotationTransform, placeholderPromptDescriptor, attachRotateHandlePlacement, elementIdSelector, createRotationDrag, ACTION_INDICATOR_CLASS, ACTION_INDICATOR_ICON_PATH, LINK_TOOLTIP_CLASS, LINK_TOOLTIP_PANEL_CLASS, LINK_TOOLTIP_LABEL_CLASS, LINK_TOOLTIP_HINT_CLASS, DEFAULT_PALETTE2, resolvePalette, computeDrawingViewBox, projectDrawingShapes, resolveRevealedDrawingShapeNodeIds, styleShadowFilter, buildChromeStyle, measureSvgViewportRect, modelDataToBlobUrl, getImageSvgFilters, getCachedNativeImageSize, probeNativeImageSize, buildDuotoneCacheKey, getDuotoneCachedResult, applyDuotone, setDuotoneCachedResult, buildCacheKey, DEFAULT_COLOR_CHANGE_TOLERANCE, getCachedResult, applyColorChange, setCachedResult, inlineListBodyText, createInlineListSeed, readListActivationSelection, createInlineListModelObserver, attachCollaborationInlineEditor, bindInlineListParagraph, bindInlineListRun, attachInlineListController, restoreInlineListBodySelection, getInlineEditorSelectionResult, isBulletMarkerSegment, resolveChartThreeViewSpec, applyChart3DDrag, applyChart3DSelect, findChartPartTarget, withChartTitle, resolveSmartArtThreeViewSpec, isBrowserOpenableMime, formatBytes, getOleDisplayName, getOleBadgeLabel, openUrlInNewTab, getSubstituteFontFamily, hasGlyphEnvelope, buildGlyphEnvelopeBlock, getWarpPath, isWedgeCalloutPresetShape, isElementActionable, centeredSvgTextLines, findSmartArtNodeText, setSmartArtNodeStyle, rebuildDrawingShapesIfCleared, shouldCommitSmartArtNodeText, updateSmartArtNodeText, advanceChartMarkDrag, advanceChartValueDrag, resolveChartKind, buildChartMarkDragGeometry, beginChartMarkDrag, beginChartValueDrag, groupIntoParagraphs, substituteFieldText, computeInlineEditorRect, MIN_TOUCH_TARGET_PX, computeVirtualRange, DEFAULT_VIRTUAL_OVERSCAN, createSyncGate, clearLocalAwareness, validateRoomId, createDepartureChannel, resolveTransportForServerUrl, isMixedContentBlocked, CONNECTION_TIMEOUT_MS, registerCollaborationTeardown, createPresenceProjector, BROADCAST_THROTTLE_MS, sanitizeColor, cloneTemplateElementsBySlideId, cloneSlide, createWheelStepBuffer, createViewerZoomStore, clampZoomScale, mapEditingWheel, createActiveAnimationGroup, cancelBuildReveal, clearPlaybackTimers, PresentationAnimationController, resolveMediaTimeNodeElementIds, resolveMediaBookmarkTimesMs, advanceMainSequence, playGroup, PRESENTATION_HASH, PRESENTATION_NONCE_KEY, PRESENTATION_CHANNEL_NAME, swapPresentationWindows, PRESENTATION_MESSAGE_ORIGIN, clearAudienceContent, buildPresentationAudienceUrl, resolveAudienceScreenPlacement, placeAudienceWindow, storeAudienceContent, isPresentationSessionMessage, endAudienceDisplay, createPresentationKeyBuffer, acceptsPresentationInput, resolveAutoAdvanceDelayMs, hasShowSlideAfter, nextShowSlideIndex, previousShowSlideIndex, createPresenterShowGuard, firstShowSlideIndex, attachPresentationVisibilityPause, presentationEntrySlideIndex, buildMorphTransitionPlan, morphOptionToMode, buildMorphAnimationRules, findInSlides, applyFindReplacements, visibleTemplateElements, createCollaborationLivePatcher, publishLiveInlineText, PptxHandler, createPresentationLoadResources, collectMediaElements, resolveMediaElementSource, collectImagePaths, applyImagePathPatches, resolveTableCellImageUrls, resolveTableStyleImageUrls, partitionTemplateElements, seedRecentColors, resolveAuthoredCustomShowId, buildInitialGuides, readOnlyRecommendation, compatibilityWarningToasts, EncryptedFileError, resolveAutosaveIntervalMs, shouldWriteAutosaveSnapshot, saveAutosaveSnapshot, autosaveSnapshotMark, updateMasterViewElement, isTemplateElementId, updateElement, masterViewElements, replaceMasterViewElements, addSection, renameSection, deleteSection, moveSectionUp, moveSectionDown, moveSlidesToSection, canInteractWithElement, prepareExportClone, normalizeColorsForCapture, preprocessCssForCapture, slideProgressPercent, slideStatusLabel, EXPORT_ASSEMBLING_PERCENT, EXPORT_DONE_PERCENT, isExportAbortError, resolveImageResolutionScale, applyThemeToData, THEME_PRESETS, themeColorSchemesEqual, comparePresentation, applyAcceptSlide, applyAcceptAllSlides, collectUsedFonts, describeFontEmbedding, isMobileViewport, resolveAuthoredSlideRange, mayLeaveSlideShow, stopAllPersistentAudio, guidePxToEmu, buildSaveSlides, buildDeckSaveOptions, resolveSlideSizeSelection, saveDeckWithPassword, shouldProbeAutosaveRecovery, probeAutosaveRecovery, acceptAutosaveRecovery, acknowledgeAutosaveRecovery, discardAutosaveRecovery, shouldLoopContinuously, applyRehearsalTimings, collectReferencedFontFamilies, resolveGoogleWebfontHref, syncGoogleWebfontStylesheet, selectGoogleWebfontFamilies, fetchGoogleWebfontOutlineBytes, mapSlideShowStartKey, mapEditorKey, isEditorTextInputTarget, textFontSizePtToPx, stepFontSizePt, textFontSizePxToPt, cycleSelectableElement, prepareElementForInsertion, createViewerOptionsStore, observeYDocSlides, LOCAL_SYNC_ORIGIN, readSlidesFromYDoc, shouldRoomSlidesReplaceLoad, reconcileSlidesInYDoc, shouldAutoFollowBroadcaster, detectTouchDevice, detectOrientation, deriveViewportBreakpoints, createTouchGestureRecognizer, MAX_ZOOM_SCALE, MIN_ZOOM_SCALE, isKeyboardOpen, scopeLayoutOptionsToSlide, checkModifyPassword, viewerPreferencesFromViewProperties, DEFAULT_VIEWER_PREFERENCES, viewPropertiesPatchFromPreferences, openPptxFile, readBackstageRecentFile, resolveCollaborationShellEditability, resolveCollaborationShellState, MORPH_CROSSFADE_GROUP_STYLE, MORPH_CROSSFADE_HALF_STYLE, getSlideTransitionAnimations, getFragmentedTransitionDescriptor, SLIDE_TRANSITION_KEYFRAMES, isActionHidden, buildInlineTextCommitPatch, resolveInlineEditAutoFitHeight, resolveInlineEditNormAutofitShrink, filterInteractableIds, beginShapeAdjustment, buildElementClipboardPayload, savedPresentationFileName, downloadBlob, exportDeckJson, groupElements, generateElementId, makeCloneId, ungroupElements, alignElements, distributeElements, newTableElement, createDefaultChartElement, readViewportMetrics, computeKeyboardInset, mergeShapes, mapPresentationKey, lastShowSlideIndex, mapPresentationWheel, openPendingPrintWindow, computeColorFilter, filterHiddenSlideIndices, computeSlideIndices, buildPrintDocument, finishPrintWindow, buildPrintHtmlDocument, buildOutlineHtml, buildSlidesHtml, buildNotesHtml, buildHandoutsHtml, createBlankSlide, makeSlideId, buildSlideTemplateSlide, templateSchemeFromTheme, buildThemeColorMap, reResolveSlideColors, reResolveElementColors, resolveViewportFitOptions, calculateViewportFit, scheduleAutoAdvanceChain, computeEntranceAnimationDelay, createPresentationSessionId, resolveTransitionDurationMs, resolveTransitionSoundAction, runPresentationAction, safeOpenUrl, buildRunProgramNotice, toggleStageElementMedia, resolveOleVerbTarget, downloadDataUrl, createPresenterTimer, createInitialPresentationSnapshot, mergePresentationSnapshot, resetPresenterTimer, presenterElapsed, stepPresenterZoom, togglePresenterTimer, addCommentToList, removeCommentFromList, editCommentInList, toggleCommentResolvedInList, remapTextToSegments, buildInlineListStylePatch, applyActiveInlineListFormatting, applyListStyleUpdate, setPendingSelectionRestore, applyTextStyleUpdate, toggleSelectionBullets, transformInlineListCase, applyCaseTransformToSegments, transformTextCase, resolveExportCaptureDecision, recordProgressPercent, computeGridSpacingPx, resolveShowSlideIndexes, groupSlidesBySection, masterViewPseudoSlide, overlayMasterViewInlineSnapshot, overlayInlineTextSnapshot, copyFormatFromElement, cloneElementUpdates, assertElementUpdateTarget, prepareElementUpdateBatch, createWriteBackScheduler, observeExternalCollaborationReadiness, resolveHistoryDepth, hasCopyableFormat, createBackstagePresentation, buildFieldSubstitutionContext, cloneElementForPaste, computeScrollDelta, getPresetShapeClipPath, svgPathToPolygons, polygonsToSvgPath, rerouteConnectorsForMovedElements, applyReroutedConnectors, SvgExporter, replyToCommentInList, removeTableElementColumn, insertTableElementColumn, removeTableElementRow, insertTableElementRow, updateCellTextStyleInRawXml, setCellText, updateCellTextInRawXml, splitCell, updateMergeAttrsInRawXml, mergeCells, pickSupportedMimeType, WEBM_MIME_CANDIDATES, fpsToFrameIntervalMs, segmentFrameCount, stopCaptureStream, GIF_POST_CAPTURE_MAX_SIDE, encodeGif, rasterResultToPngBlob, rasterizeElementTiles, placeTileOnPage, PDF_SLIDES_PAGE_WIDTH_PT, PDF_SLIDES_PAGE_HEIGHT_PT, canvasToJpegData, applyFormatToElement, createSnapshotTextPositions, isPpactionUrl, parsePpactionUrl, resolvePresentationAction, elementActionToPptxAction, isUrlSafe, buildSmartArtPresetData, classifyMediaType, computeSnapToShape, publishLiveGeometry, getDraggedShapeAdjustments, computeMarqueeHitIds, mergeAdditiveSelection, rasterizeElementTiledToCanvas, borrowExternalCollaborationAwareness, observeExternalCollaborationSession, clampGifDimensions, rasterizeElement, shouldConfirmExternalHyperlink, applyResize, lockResizeAspect, snapBoxToGrid, applyMotionPathPreset, bringForward, sendBackward, bringToFront, sendToBack } from './chunk-3UWJWJCR.mjs';
3
- import { translationsEn } from './chunk-OBQ453H6.mjs';
1
+ import { DEFAULT_STROKE_COLOR, getConnectorPathGeometry, buildLineShadowCss, buildLineGlowFilter, renderConnectorMarker, getShapeVisualStyle, getTextStyleForElement, DEFAULT_TEXT_COLOR, renderVectorShape, isConnectorOrLineElement, build3DExtrusionData, getImageRenderStyle, cn, getImageSurfaceStyle, getTextLayoutStyle, renderTableElement, renderMediaElement, shouldRenderFallbackLabel, DEFAULT_FILL_COLOR, getCropShapeClipPath, hasDagDuotoneEffect, renderDagDuotoneSvgFilter, getImageSurfaceMaskStyle, getDuotoneColors, getTextWarpStyle, renderTextSegments, buildReactChartViewModel, renderChartElement, MIN_ELEMENT_SIZE, buildTextBody3DSceneStyle, getImageTilingStyle, DEFAULT_TEXT_FONT_SIZE, DEFAULT_FONT_FAMILY, HYPERLINK_COLOR, cloneHistorySnapshot, ZOOM_TO_SELECTION_PADDING, DEFAULT_CANVAS_HEIGHT, DEFAULT_CANVAS_WIDTH, UNGROUPED_SECTION_ID, DEFAULT_SECTION_GROUP_ID, DEFAULT_TABLE_ROWS, DEFAULT_TABLE_COLUMNS, buildPdfFromTiledImageData, GRID_SIZE, buildNotesPdf } from './chunk-ZF5S3HHW.mjs';
2
+ import { GlyphOutlineFontCache, createGlyphOutlineLookup, DEFAULT_VIEWER_OPTIONS, TOOLBAR_TABS, defineThreeViewElement, getSelectionControlArtworkStyle, hasShapeProperties, normalizeHexColor, colorWithOpacity, normalizeStrokeDashType, getSvgStrokeDasharray, getCompoundLineOffsets, getCompoundLineWidths, svgLineCap, hasTextProperties, getSelectionOutlineColor, connectorWrapperTransform, getAriaRoleDescription, getAriaLabel, getAriaRole, resolveElementInteractivity, isEditableTextElement, buildTextStyleOverrideCss, isElementRendered, resolveElementAriaAttributes, isMediaFullscreenActive, shouldRenderHitTarget, elementHitTargetStyle, getImageEffectsOpacity, getImageEffectsFilter, inlineElementPointerEvents, isHollowShapeElement, LINK_TOOLTIP_HOST_CLASS, ACTION_BUTTON_PRESETS, mediaTransportVisible, isInkElement, oleActionsVisible, getGroupChildParentFill, getElementLabel, getResizeHandleHitAreaStyle, paintedStrokeWidth, buildCssGradientFromShapeStyle, ensureActionAffordanceStyles, resolveElementActionAffordance, actionAffordanceLabels, paintedElementSize, MEDIA_FULLSCREEN_OVERLAY_STYLE, elementContainerHeightStyle, getElementTransform, resolveElementHighlightClick, applyHighlightClickStyle, getComputedEffectStyle, getSoftEdgeSvgFilter, getEffectStyleSource, getBevelLightingSvgFilter, buildStrokeOutline, buildHollowHitOutline, buildSubpathFillOverlay, isImageLikeElement, strokeOutlineViewBox, resolveRevealedSmartArtNodes, resolveRevealedDrawingShapes, buildSmartArtA11y, canDrillDown, computeSmartArtElementLayout, flattenNodes, buildSummaryZoomView, isImageTiled, getImageColorWashStyle, readEditableText, placeCaretAtEnd, getPendingSelectionRestore, restoreSegmentSelection, getTextCompensationTransform, mapInlineTextFormatKey, subscribeBarFacePicturePixelSamples, getBarFacePicturePixelSampleVersion, ensureChartInteractionStyles, applyChartPartHighlight, resolveRevealedChartData, formatAxisValue, buildInkGroupStrokes, getInkReplayStyles, INK_REPLAY_KEYFRAMES, buildContentPartStrokes, getContentPartReplayStyles, resolveOleType, getOleAriaLabel, getOleTypeColor, getOleTypeLabel, filterRenderedElements, resolveGroupChildFill, isLinkedTextBox, getOverflowSegments, shouldUseSvgWarp, getTextBodyRotationTransform, placeholderPromptDescriptor, attachRotateHandlePlacement, elementIdSelector, createRotationDrag, ACTION_INDICATOR_CLASS, ACTION_INDICATOR_ICON_PATH, LINK_TOOLTIP_CLASS, LINK_TOOLTIP_PANEL_CLASS, LINK_TOOLTIP_LABEL_CLASS, LINK_TOOLTIP_HINT_CLASS, DEFAULT_PALETTE2, resolvePalette, computeDrawingViewBox, projectDrawingShapes, resolveRevealedDrawingShapeNodeIds, styleShadowFilter, buildChromeStyle, measureSvgViewportRect, modelDataToBlobUrl, resolveZoomNavigationTarget, getImageSvgFilters, getCachedNativeImageSize, probeNativeImageSize, buildDuotoneCacheKey, getDuotoneCachedResult, applyDuotone, setDuotoneCachedResult, buildCacheKey, DEFAULT_COLOR_CHANGE_TOLERANCE, getCachedResult, applyColorChange, setCachedResult, inlineListBodyText, createInlineListSeed, readListActivationSelection, createInlineListModelObserver, attachCollaborationInlineEditor, bindInlineListParagraph, bindInlineListRun, attachInlineListController, restoreInlineListBodySelection, getInlineEditorSelectionResult, isBulletMarkerSegment, resolveChartThreeViewSpec, applyChart3DDrag, applyChart3DSelect, findChartPartTarget, withChartTitle, resolveSmartArtThreeViewSpec, isBrowserOpenableMime, formatBytes, getOleDisplayName, getOleBadgeLabel, openUrlInNewTab, getSubstituteFontFamily, hasGlyphEnvelope, buildGlyphEnvelopeBlock, getWarpPath, isWedgeCalloutPresetShape, isElementActionable, centeredSvgTextLines, findSmartArtNodeText, setSmartArtNodeStyle, rebuildDrawingShapesIfCleared, shouldCommitSmartArtNodeText, updateSmartArtNodeText, advanceChartMarkDrag, advanceChartValueDrag, resolveChartKind, buildChartMarkDragGeometry, beginChartMarkDrag, beginChartValueDrag, groupIntoParagraphs, substituteFieldText, computeInlineEditorRect, MIN_TOUCH_TARGET_PX, computeVirtualRange, DEFAULT_VIRTUAL_OVERSCAN, createSyncGate, clearLocalAwareness, validateRoomId, createDepartureChannel, resolveTransportForServerUrl, isMixedContentBlocked, CONNECTION_TIMEOUT_MS, registerCollaborationTeardown, createPresenceProjector, BROADCAST_THROTTLE_MS, sanitizeColor, cloneTemplateElementsBySlideId, cloneSlide, createWheelStepBuffer, createViewerZoomStore, clampZoomScale, mapEditingWheel, createActiveAnimationGroup, cancelBuildReveal, clearPlaybackTimers, PresentationAnimationController, resolveMediaTimeNodeElementIds, resolveMediaBookmarkTimesMs, advanceMainSequence, playGroup, PRESENTATION_HASH, PRESENTATION_NONCE_KEY, PRESENTATION_CHANNEL_NAME, swapPresentationWindows, PRESENTATION_MESSAGE_ORIGIN, clearAudienceContent, buildPresentationAudienceUrl, resolveAudienceScreenPlacement, placeAudienceWindow, storeAudienceContent, isPresentationSessionMessage, endAudienceDisplay, createPresentationKeyBuffer, acceptsPresentationInput, resolveAutoAdvanceDelayMs, resolveForwardSlideWithZoomReturn, buildZoomTransitionOverride, hasShowSlideAfter, nextShowSlideIndex, previousShowSlideIndex, beginZoomExcursion, createPresenterShowGuard, firstShowSlideIndex, attachPresentationVisibilityPause, presentationEntrySlideIndex, buildMorphTransitionPlan, morphOptionToMode, buildMorphAnimationRules, findInSlides, applyFindReplacements, visibleTemplateElements, createCollaborationLivePatcher, publishLiveInlineText, PptxHandler, createPresentationLoadResources, collectMediaElements, resolveMediaElementSource, collectImagePaths, applyImagePathPatches, resolveTableCellImageUrls, resolveTableStyleImageUrls, partitionTemplateElements, seedRecentColors, resolveAuthoredCustomShowId, buildInitialGuides, readOnlyRecommendation, compatibilityWarningToasts, EncryptedFileError, resolveAutosaveIntervalMs, shouldWriteAutosaveSnapshot, saveAutosaveSnapshot, autosaveSnapshotMark, updateMasterViewElement, isTemplateElementId, updateElement, masterViewElements, replaceMasterViewElements, addSection, renameSection, deleteSection, moveSectionUp, moveSectionDown, moveSlidesToSection, canInteractWithElement, prepareExportClone, normalizeColorsForCapture, preprocessCssForCapture, slideProgressPercent, slideStatusLabel, EXPORT_ASSEMBLING_PERCENT, EXPORT_DONE_PERCENT, isExportAbortError, resolveImageResolutionScale, applyThemeToData, THEME_PRESETS, themeColorSchemesEqual, comparePresentation, applyAcceptSlide, applyAcceptAllSlides, collectUsedFonts, describeFontEmbedding, isMobileViewport, resolveAuthoredSlideRange, mayLeaveSlideShow, stopAllPersistentAudio, guidePxToEmu, buildSaveSlides, buildDeckSaveOptions, resolveSlideSizeSelection, saveDeckWithPassword, shouldProbeAutosaveRecovery, probeAutosaveRecovery, acceptAutosaveRecovery, acknowledgeAutosaveRecovery, discardAutosaveRecovery, shouldLoopContinuously, applyRehearsalTimings, rasterResultToPngBlob, downloadBlob, elementPictureFilename, collectReferencedFontFamilies, resolveGoogleWebfontHref, syncGoogleWebfontStylesheet, selectGoogleWebfontFamilies, fetchGoogleWebfontOutlineBytes, mapSlideShowStartKey, mapEditorKey, isEditorTextInputTarget, textFontSizePtToPx, stepFontSizePt, textFontSizePxToPt, cycleSelectableElement, prepareElementForInsertion, createViewerOptionsStore, observeYDocSlides, LOCAL_SYNC_ORIGIN, readSlidesFromYDoc, shouldRoomSlidesReplaceLoad, reconcileSlidesInYDoc, shouldAutoFollowBroadcaster, detectTouchDevice, detectOrientation, deriveViewportBreakpoints, createTouchGestureRecognizer, MAX_ZOOM_SCALE, MIN_ZOOM_SCALE, isKeyboardOpen, scopeLayoutOptionsToSlide, checkModifyPassword, viewerPreferencesFromViewProperties, DEFAULT_VIEWER_PREFERENCES, viewPropertiesPatchFromPreferences, openPptxFile, readBackstageRecentFile, resolveCollaborationShellEditability, resolveCollaborationShellState, MORPH_CROSSFADE_GROUP_STYLE, MORPH_CROSSFADE_HALF_STYLE, getSlideTransitionAnimations, getFragmentedTransitionDescriptor, SLIDE_TRANSITION_KEYFRAMES, isActionHidden, buildInlineTextCommitPatch, resolveInlineEditAutoFitHeight, resolveInlineEditNormAutofitShrink, filterInteractableIds, beginShapeAdjustment, buildElementClipboardPayload, contextMenuInspectorAnchor, savedPresentationFileName, exportDeckJson, groupElements, generateElementId, makeCloneId, ungroupElements, alignElements, distributeElements, newTableElement, createDefaultChartElement, readViewportMetrics, computeKeyboardInset, mergeShapes, mapPresentationKey, lastShowSlideIndex, mapPresentationWheel, openPendingPrintWindow, computeColorFilter, filterHiddenSlideIndices, computeSlideIndices, buildPrintDocument, finishPrintWindow, buildPrintHtmlDocument, buildOutlineHtml, buildSlidesHtml, buildNotesHtml, buildHandoutsHtml, createBlankSlide, makeSlideId, buildSlideTemplateSlide, templateSchemeFromTheme, buildThemeColorMap, reResolveSlideColors, reResolveElementColors, resolveViewportFitOptions, calculateViewportFit, scheduleAutoAdvanceChain, computeEntranceAnimationDelay, createPresentationSessionId, resolveTransitionDurationMs, resolveTransitionSoundAction, runPresentationAction, safeOpenUrl, buildRunProgramNotice, toggleStageElementMedia, resolveOleVerbTarget, downloadDataUrl, createPresenterTimer, createInitialPresentationSnapshot, mergePresentationSnapshot, resetPresenterTimer, presenterElapsed, stepPresenterZoom, togglePresenterTimer, addCommentToList, removeCommentFromList, editCommentInList, toggleCommentResolvedInList, remapTextToSegments, buildInlineListStylePatch, applyActiveInlineListFormatting, applyListStyleUpdate, setPendingSelectionRestore, applyTextStyleUpdate, toggleSelectionBullets, transformInlineListCase, applyCaseTransformToSegments, transformTextCase, resolveExportCaptureDecision, recordProgressPercent, computeGridSpacingPx, resolveShowSlideIndexes, groupSlidesBySection, masterViewPseudoSlide, overlayMasterViewInlineSnapshot, overlayInlineTextSnapshot, rasterizeElement, cloneElementForPaste, applyPasteSpecialFormat, buildRasterPictureElement, copyFormatFromElement, cloneElementUpdates, assertElementUpdateTarget, prepareElementUpdateBatch, createWriteBackScheduler, observeExternalCollaborationReadiness, resolveHistoryDepth, hasCopyableFormat, createBackstagePresentation, buildFieldSubstitutionContext, scrollInspectorSectionIntoView, computeScrollDelta, getPresetShapeClipPath, svgPathToPolygons, polygonsToSvgPath, rerouteConnectorsForMovedElements, applyReroutedConnectors, SvgExporter, replyToCommentInList, removeTableElementColumn, insertTableElementColumn, removeTableElementRow, insertTableElementRow, updateCellTextStyleInRawXml, setCellText, updateCellTextInRawXml, splitCell, updateMergeAttrsInRawXml, mergeCells, pickSupportedMimeType, WEBM_MIME_CANDIDATES, fpsToFrameIntervalMs, segmentFrameCount, stopCaptureStream, GIF_POST_CAPTURE_MAX_SIDE, encodeGif, rasterizeElementTiles, placeTileOnPage, PDF_SLIDES_PAGE_WIDTH_PT, PDF_SLIDES_PAGE_HEIGHT_PT, canvasToJpegData, applyFormatToElement, createSnapshotTextPositions, isPpactionUrl, parsePpactionUrl, resolvePresentationAction, elementActionToPptxAction, isUrlSafe, buildSmartArtPresetData, classifyMediaType, computeSnapToShape, publishLiveGeometry, getDraggedShapeAdjustments, computeMarqueeHitIds, mergeAdditiveSelection, rasterizeElementTiledToCanvas, borrowExternalCollaborationAwareness, observeExternalCollaborationSession, clampGifDimensions, rasterResultToPngDataUrl, shouldConfirmExternalHyperlink, applyResize, lockResizeAspect, snapBoxToGrid, applyMotionPathPreset, bringForward, sendBackward, bringToFront, sendToBack } from './chunk-VZNIVS3X.mjs';
3
+ import { translationsEn } from './chunk-APAVAD2A.mjs';
4
4
  import React17, { createContext, useMemo, useState, useCallback, useEffect, Suspense, useRef, useLayoutEffect, useContext, useSyncExternalStore, useImperativeHandle } from 'react';
5
5
  import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
6
6
  import { useTranslation } from 'react-i18next';
@@ -2077,7 +2077,7 @@ function handlePresentationActionImpl(action, deps) {
2077
2077
  // src/viewer/hooks/presentation-mode/slide-transition.ts
2078
2078
  function executeSlideTransition(nextSlideIndex, deps) {
2079
2079
  const incomingSlide = deps.slides[nextSlideIndex];
2080
- const transition = deps.reverse ? deps.slides[deps.currentSlideIndex]?.transition : incomingSlide?.transition;
2080
+ const transition = deps.transitionOverride ?? (deps.reverse ? deps.slides[deps.currentSlideIndex]?.transition : incomingSlide?.transition);
2081
2081
  const durationMs = deps.playTransition ? resolveTransitionDurationMs(transition) : 0;
2082
2082
  deps.clearPresentationTimers();
2083
2083
  deps.setPresentationSlideIndex(nextSlideIndex);
@@ -2142,7 +2142,8 @@ function useSlideNavigation(input) {
2142
2142
  onOpenPresentation,
2143
2143
  onPlayMedia,
2144
2144
  onOleVerb,
2145
- onRunProgram
2145
+ onRunProgram,
2146
+ zoomExcursionRef
2146
2147
  } = input;
2147
2148
  const movePresentationSlideRef = useRef(() => {
2148
2149
  });
@@ -2167,6 +2168,37 @@ function useSlideNavigation(input) {
2167
2168
  if (isClickAdvanceBlocked(slides[presentationSlideIndex], direction, trigger)) {
2168
2169
  return;
2169
2170
  }
2171
+ if (direction === 1) {
2172
+ const consumedExcursion = zoomExcursionRef.current;
2173
+ const step = resolveForwardSlideWithZoomReturn(
2174
+ presentationSlideIndex,
2175
+ void 0,
2176
+ consumedExcursion
2177
+ );
2178
+ if (step.returnedToZoom && step.nextSlideIndex !== void 0) {
2179
+ zoomExcursionRef.current = step.excursion;
2180
+ executeSlideTransition(step.nextSlideIndex, {
2181
+ slides,
2182
+ currentSlideIndex: presentationSlideIndex,
2183
+ onPlayActionSound,
2184
+ onStopActionSound,
2185
+ setPresentationSlideVisible,
2186
+ clearPresentationTimers,
2187
+ setPresentationSlideIndex,
2188
+ onSetActiveSlideIndex,
2189
+ seedSlideAnimations,
2190
+ startSlideAnimations,
2191
+ scheduleAutoAdvanceForSlide,
2192
+ presentationTimersRef,
2193
+ setTransitionOverlay,
2194
+ playTransition: true,
2195
+ transitionOverride: buildZoomTransitionOverride(
2196
+ consumedExcursion?.transitionDurationMs
2197
+ )
2198
+ });
2199
+ return;
2200
+ }
2201
+ }
2170
2202
  const availableSlideIndexes = visibleSlideIndexes.length > 0 ? visibleSlideIndexes : slides.map((_slide, slideIndex) => slideIndex);
2171
2203
  if (availableSlideIndexes.length === 0) {
2172
2204
  return;
@@ -2242,12 +2274,13 @@ function useSlideNavigation(input) {
2242
2274
  visibleSlideIndexes,
2243
2275
  setPresentationSlideVisible,
2244
2276
  setPresentationSlideIndex,
2245
- setTransitionOverlay
2277
+ setTransitionOverlay,
2278
+ zoomExcursionRef
2246
2279
  ]
2247
2280
  );
2248
2281
  movePresentationSlideRef.current = movePresentationSlide;
2249
2282
  const navigateToSlide = useCallback(
2250
- (targetIndex) => {
2283
+ (targetIndex, transitionOverride) => {
2251
2284
  if (targetIndex < 0 || targetIndex >= slides.length) {
2252
2285
  return;
2253
2286
  }
@@ -2275,7 +2308,11 @@ function useSlideNavigation(input) {
2275
2308
  // on-slide links (this is how the issue #131 reporter drives their
2276
2309
  // wheel menu) appeared to have no morph at all, while the same
2277
2310
  // transition played fine on PageDown.
2278
- playTransition: true
2311
+ playTransition: true,
2312
+ // A Slide Zoom / Section Zoom / Summary Zoom click carries its own
2313
+ // `zmPr/@transitionDur`, independent of the destination's own
2314
+ // authored transition (see `useZoomNavigation`).
2315
+ transitionOverride
2279
2316
  });
2280
2317
  },
2281
2318
  [
@@ -2335,31 +2372,22 @@ function useSlideNavigation(input) {
2335
2372
  };
2336
2373
  }
2337
2374
  function useZoomNavigation(input) {
2338
- const { navigateToSlide } = input;
2339
- const zoomReturnSlideIndex = useRef(null);
2375
+ const { slides, navigateToSlide, zoomExcursionRef } = input;
2340
2376
  const handleZoomClick = useCallback(
2341
- (targetSlideIndex, returnSlideIndex) => {
2342
- zoomReturnSlideIndex.current = returnSlideIndex;
2343
- navigateToSlide(targetSlideIndex);
2377
+ (target, returnSlideIndex) => {
2378
+ zoomExcursionRef.current = beginZoomExcursion(target, returnSlideIndex, slides);
2379
+ navigateToSlide(
2380
+ target.targetSlideIndex,
2381
+ buildZoomTransitionOverride(target.transitionDurationMs)
2382
+ );
2344
2383
  },
2345
- [navigateToSlide]
2384
+ [navigateToSlide, slides, zoomExcursionRef]
2346
2385
  );
2347
- const returnToZoomSlide = useCallback(() => {
2348
- const returnIndex = zoomReturnSlideIndex.current;
2349
- if (returnIndex === null) {
2350
- return false;
2351
- }
2352
- zoomReturnSlideIndex.current = null;
2353
- navigateToSlide(returnIndex);
2354
- return true;
2355
- }, [navigateToSlide]);
2356
2386
  const clearZoomReturn = useCallback(() => {
2357
- zoomReturnSlideIndex.current = null;
2358
- }, []);
2387
+ zoomExcursionRef.current = void 0;
2388
+ }, [zoomExcursionRef]);
2359
2389
  return {
2360
2390
  handleZoomClick,
2361
- zoomReturnSlideIndex,
2362
- returnToZoomSlide,
2363
2391
  clearZoomReturn
2364
2392
  };
2365
2393
  }
@@ -2661,6 +2689,7 @@ function usePresentationMode(input) {
2661
2689
  setEndOfShowVisible,
2662
2690
  onAddRunProgramNotice
2663
2691
  });
2692
+ const zoomExcursionRef = useRef(void 0);
2664
2693
  const {
2665
2694
  movePresentationSlide: moveNavigationSlide,
2666
2695
  navigateToSlide,
@@ -2668,6 +2697,7 @@ function usePresentationMode(input) {
2668
2697
  scheduleAutoAdvanceForSlide
2669
2698
  } = useSlideNavigation({
2670
2699
  slides,
2700
+ zoomExcursionRef,
2671
2701
  visibleSlideIndexes,
2672
2702
  presentationSlideIndex,
2673
2703
  setPresentationSlideIndex,
@@ -2724,7 +2754,16 @@ function usePresentationMode(input) {
2724
2754
  runPresentationEntranceAnimations
2725
2755
  ]
2726
2756
  );
2727
- const { handleZoomClick, zoomReturnSlideIndex, returnToZoomSlide, clearZoomReturn } = useZoomNavigation({ navigateToSlide });
2757
+ const { handleZoomClick, clearZoomReturn } = useZoomNavigation({
2758
+ slides,
2759
+ navigateToSlide,
2760
+ zoomExcursionRef
2761
+ });
2762
+ useEffect(() => {
2763
+ if (mode !== "present") {
2764
+ clearZoomReturn();
2765
+ }
2766
+ }, [mode, clearZoomReturn]);
2728
2767
  const openAllSlides = useCallback(() => setAllSlidesOpen(true), []);
2729
2768
  const closeAllSlides = useCallback(() => setAllSlidesOpen(false), []);
2730
2769
  const presenterConsole = usePresenterConsole(presentationSlideIndex, mode === "present");
@@ -3009,8 +3048,6 @@ ${imageRules}`;
3009
3048
  rehearsalPaused,
3010
3049
  toggleRehearsalPause,
3011
3050
  handleZoomClick,
3012
- zoomReturnSlideIndex,
3013
- returnToZoomSlide,
3014
3051
  clearZoomReturn,
3015
3052
  openAudienceWindow,
3016
3053
  closeAudienceWindow,
@@ -4222,6 +4259,7 @@ function useViewerUIState() {
4222
4259
  const [isAccessibilityPanelOpen, setIsAccessibilityPanelOpen] = useState(false);
4223
4260
  const [accessibilityIssues, setAccessibilityIssues] = useState([]);
4224
4261
  const [contextMenuState, setContextMenuState] = useState(null);
4262
+ const [canvasContextMenuState, setCanvasContextMenuState] = useState(null);
4225
4263
  const [tableEditorState, setTableEditorState] = useState(null);
4226
4264
  const [spellCheckEnabled, setSpellCheckEnabled] = useState(true);
4227
4265
  const [showGrid, setShowGrid] = useState(false);
@@ -4276,6 +4314,8 @@ function useViewerUIState() {
4276
4314
  setAccessibilityIssues,
4277
4315
  contextMenuState,
4278
4316
  setContextMenuState,
4317
+ canvasContextMenuState,
4318
+ setCanvasContextMenuState,
4279
4319
  tableEditorState,
4280
4320
  setTableEditorState,
4281
4321
  spellCheckEnabled,
@@ -5648,6 +5688,7 @@ function useCanvasInteractions(input) {
5648
5688
  setInlineEditingElementId,
5649
5689
  setInlineEditingText,
5650
5690
  setContextMenuState,
5691
+ setCanvasContextMenuState,
5651
5692
  setMarqueeSelectionState,
5652
5693
  setSnapLines,
5653
5694
  inlineEditingText,
@@ -5672,7 +5713,9 @@ function useCanvasInteractions(input) {
5672
5713
  if (el && hasTextProperties(el)) {
5673
5714
  const reader = inlineEditingReaderRef?.current;
5674
5715
  const read = reader?.elementId === editId ? reader.read() : void 0;
5675
- if (read?.kind === "unsupported") return;
5716
+ if (read?.kind === "unsupported") {
5717
+ return;
5718
+ }
5676
5719
  const liveText = read?.snapshot.text ?? inlineEditingTextRef?.current ?? inlineEditingText;
5677
5720
  const committedText = transformCommittedText ? transformCommittedText(liveText) : liveText;
5678
5721
  const textPatch = buildInlineTextCommitPatch(
@@ -5825,6 +5868,15 @@ function useCanvasInteractions(input) {
5825
5868
  }
5826
5869
  setContextMenuState({ x: e.clientX, y: e.clientY, elementId });
5827
5870
  };
5871
+ const handleCanvasContextMenu = (e) => {
5872
+ if (mode === "present") {
5873
+ return;
5874
+ }
5875
+ e.preventDefault();
5876
+ e.stopPropagation();
5877
+ setContextMenuState(null);
5878
+ setCanvasContextMenuState({ x: e.clientX, y: e.clientY });
5879
+ };
5828
5880
  const handleCanvasMouseDown = (e) => {
5829
5881
  if (mode !== "edit" || !canEdit || e.button !== 0 || activeTool !== "select") {
5830
5882
  return;
@@ -5852,6 +5904,7 @@ function useCanvasInteractions(input) {
5852
5904
  marqueeStateRef.current = nextMarquee;
5853
5905
  setMarqueeSelectionState(nextMarquee);
5854
5906
  setContextMenuState(null);
5907
+ setCanvasContextMenuState(null);
5855
5908
  };
5856
5909
  const handleResizePointerDown = (elementId, e, handle) => {
5857
5910
  e.stopPropagation();
@@ -5914,6 +5967,7 @@ function useCanvasInteractions(input) {
5914
5967
  handleElementDoubleClick,
5915
5968
  handleElementMouseDown,
5916
5969
  handleElementContextMenu,
5970
+ handleCanvasContextMenu,
5917
5971
  handleCanvasMouseDown,
5918
5972
  handleResizePointerDown,
5919
5973
  handleAdjustmentPointerDown,
@@ -6477,12 +6531,13 @@ function useClipboardHandlers(input) {
6477
6531
  ops.updateActiveElements((els) => [...els, clone]);
6478
6532
  ops.applySelection(clone.id);
6479
6533
  history.markDirty();
6534
+ return clone;
6480
6535
  };
6481
6536
  const handlePaste = () => {
6482
6537
  if (!clipboardPayload || !activeSlide) {
6483
6538
  return;
6484
6539
  }
6485
- insertClone(clipboardPayload.element);
6540
+ input.onPasted?.(insertClone(clipboardPayload.element));
6486
6541
  };
6487
6542
  const handleDuplicate = () => {
6488
6543
  if (!selectedElement || !activeSlide) {
@@ -6944,8 +6999,25 @@ function useGroupAlignLayerHandlers(input) {
6944
6999
  }
6945
7000
 
6946
7001
  // src/viewer/hooks/useElementManipulation.ts
7002
+ function focusInspectorSection(setIsInspectorPaneOpen, setSidebarPanelMode, anchor) {
7003
+ setIsInspectorPaneOpen(true);
7004
+ setSidebarPanelMode("properties");
7005
+ if (!anchor) {
7006
+ return;
7007
+ }
7008
+ requestAnimationFrame(() => {
7009
+ requestAnimationFrame(() => scrollInspectorSectionIntoView(document, anchor));
7010
+ });
7011
+ }
6947
7012
  function useElementManipulation(input) {
6948
- const { setIsInspectorPaneOpen, setSidebarPanelMode, onOpenHyperlinkDialog } = input;
7013
+ const {
7014
+ selectedElement,
7015
+ setIsInspectorPaneOpen,
7016
+ setSidebarPanelMode,
7017
+ onOpenHyperlinkDialog,
7018
+ onEditText,
7019
+ onSaveElementAsPicture
7020
+ } = input;
6949
7021
  const { handleCopy, handleCut, handlePaste, handleDuplicate, handleDelete } = useClipboardHandlers(input);
6950
7022
  const {
6951
7023
  handleGroupElements,
@@ -7007,6 +7079,37 @@ function useElementManipulation(input) {
7007
7079
  case "editHyperlink":
7008
7080
  onOpenHyperlinkDialog();
7009
7081
  break;
7082
+ case "edit-text":
7083
+ if (selectedElement) {
7084
+ onEditText?.(selectedElement.id);
7085
+ }
7086
+ break;
7087
+ case "save-as-picture":
7088
+ if (selectedElement) {
7089
+ onSaveElementAsPicture?.(selectedElement.id);
7090
+ }
7091
+ break;
7092
+ case "edit-alt-text":
7093
+ focusInspectorSection(
7094
+ setIsInspectorPaneOpen,
7095
+ setSidebarPanelMode,
7096
+ contextMenuInspectorAnchor("edit-alt-text")
7097
+ );
7098
+ break;
7099
+ case "size-and-position":
7100
+ focusInspectorSection(
7101
+ setIsInspectorPaneOpen,
7102
+ setSidebarPanelMode,
7103
+ contextMenuInspectorAnchor("size-and-position")
7104
+ );
7105
+ break;
7106
+ case "format-shape":
7107
+ focusInspectorSection(
7108
+ setIsInspectorPaneOpen,
7109
+ setSidebarPanelMode,
7110
+ contextMenuInspectorAnchor("format-shape")
7111
+ );
7112
+ break;
7010
7113
  }
7011
7114
  };
7012
7115
  return {
@@ -7633,6 +7736,9 @@ async function renderElementToRaster(element, scale = 2, backgroundColor, mode =
7633
7736
  buildRasterOptions(element, scale, backgroundColor, mode)
7634
7737
  );
7635
7738
  }
7739
+ async function renderElementToRasterDataUrl(element, scale = 2) {
7740
+ return rasterResultToPngDataUrl(await renderElementToRaster(element, scale));
7741
+ }
7636
7742
  async function renderElementToTiles(element, scale = 2, backgroundColor, mode = "auto") {
7637
7743
  const { width, height } = measureNaturalSize(element);
7638
7744
  return rasterizeElementTiles(
@@ -9906,6 +10012,98 @@ function useFormatPainterEditing(input) {
9906
10012
  pasteFormatToSelection
9907
10013
  };
9908
10014
  }
10015
+ function findMountedElementNode(elementId) {
10016
+ return document.querySelector(
10017
+ `[data-element-id="${elementId}"][data-pptx-element="true"]`
10018
+ );
10019
+ }
10020
+ async function rasterizePastedNode(elementId) {
10021
+ const node = findMountedElementNode(elementId);
10022
+ if (!node) {
10023
+ return null;
10024
+ }
10025
+ return renderElementToRasterDataUrl(node, 2);
10026
+ }
10027
+ function usePasteSpecial(input) {
10028
+ const { clipboardPayload, editTemplateMode, ops, markDirty } = input;
10029
+ const [isPasteSpecialDialogOpen, setIsPasteSpecialDialogOpen] = useState(false);
10030
+ const [pasteOptionsToolbar, setPasteOptionsToolbar] = useState(
10031
+ null
10032
+ );
10033
+ const openPasteSpecialDialog = useCallback(() => {
10034
+ if (clipboardPayload) {
10035
+ setIsPasteSpecialDialogOpen(true);
10036
+ }
10037
+ }, [clipboardPayload]);
10038
+ const closePasteSpecialDialog = useCallback(() => setIsPasteSpecialDialogOpen(false), []);
10039
+ const dismissPasteOptionsToolbar = useCallback(() => setPasteOptionsToolbar(null), []);
10040
+ const notePastedElement = useCallback((element) => {
10041
+ setPasteOptionsToolbar({ elementId: element.id, sourceClone: element });
10042
+ }, []);
10043
+ const replacePastedElement = useCallback(
10044
+ (elementId, next) => {
10045
+ ops.updateActiveElements((els) => els.map((el) => el.id === elementId ? next : el));
10046
+ markDirty();
10047
+ },
10048
+ [ops, markDirty]
10049
+ );
10050
+ const pasteWithFormat = useCallback(
10051
+ async (format) => {
10052
+ if (!clipboardPayload) {
10053
+ return;
10054
+ }
10055
+ setIsPasteSpecialDialogOpen(false);
10056
+ const sourceClone = cloneElementForPaste(clipboardPayload.element, {
10057
+ intoTemplate: editTemplateMode
10058
+ });
10059
+ const initial = format === "picture" ? sourceClone : applyPasteSpecialFormat(sourceClone, format);
10060
+ ops.updateActiveElements((els) => [...els, initial]);
10061
+ ops.applySelection(initial.id);
10062
+ markDirty();
10063
+ setPasteOptionsToolbar({ elementId: initial.id, sourceClone });
10064
+ if (format === "picture") {
10065
+ await new Promise((resolve) => {
10066
+ requestAnimationFrame(() => resolve());
10067
+ });
10068
+ const dataUrl = await rasterizePastedNode(initial.id);
10069
+ if (dataUrl) {
10070
+ replacePastedElement(initial.id, buildRasterPictureElement(sourceClone, dataUrl));
10071
+ }
10072
+ }
10073
+ },
10074
+ [clipboardPayload, editTemplateMode, ops, markDirty, replacePastedElement]
10075
+ );
10076
+ const reformatPastedElement = useCallback(
10077
+ async (format) => {
10078
+ const toolbar = pasteOptionsToolbar;
10079
+ if (!toolbar) {
10080
+ return;
10081
+ }
10082
+ if (format === "picture") {
10083
+ const dataUrl = await rasterizePastedNode(toolbar.elementId);
10084
+ if (dataUrl) {
10085
+ replacePastedElement(
10086
+ toolbar.elementId,
10087
+ buildRasterPictureElement(toolbar.sourceClone, dataUrl)
10088
+ );
10089
+ }
10090
+ return;
10091
+ }
10092
+ replacePastedElement(toolbar.elementId, applyPasteSpecialFormat(toolbar.sourceClone, format));
10093
+ },
10094
+ [pasteOptionsToolbar, replacePastedElement]
10095
+ );
10096
+ return {
10097
+ isPasteSpecialDialogOpen,
10098
+ openPasteSpecialDialog,
10099
+ closePasteSpecialDialog,
10100
+ pasteWithFormat,
10101
+ pasteOptionsToolbar,
10102
+ notePastedElement,
10103
+ reformatPastedElement,
10104
+ dismissPasteOptionsToolbar
10105
+ };
10106
+ }
9909
10107
 
9910
10108
  // src/viewer/hooks/useEditorOperations.ts
9911
10109
  function useEditorOperations(input) {
@@ -10019,6 +10217,7 @@ function useEditorOperations(input) {
10019
10217
  setInlineEditingElementId: state.setInlineEditingElementId,
10020
10218
  setInlineEditingText: state.setInlineEditingText,
10021
10219
  setContextMenuState: state.setContextMenuState,
10220
+ setCanvasContextMenuState: state.setCanvasContextMenuState,
10022
10221
  setMarqueeSelectionState: state.setMarqueeSelectionState,
10023
10222
  setSnapLines: state.setSnapLines,
10024
10223
  inlineEditingText: state.inlineEditingText,
@@ -10049,6 +10248,35 @@ function useEditorOperations(input) {
10049
10248
  handlerRef,
10050
10249
  insertElement: insertHandlers.addElement
10051
10250
  });
10251
+ const handleEditTextFromContextMenu = useCallback(
10252
+ (elementId) => {
10253
+ canvasHandlers.handleElementDoubleClick(elementId, {});
10254
+ },
10255
+ [canvasHandlers]
10256
+ );
10257
+ const handleSaveElementAsPicture = useCallback(
10258
+ (elementId) => {
10259
+ const node = document.querySelector(
10260
+ `[data-element-id="${elementId}"][data-pptx-element="true"]`
10261
+ );
10262
+ if (!node) {
10263
+ return;
10264
+ }
10265
+ void (async () => {
10266
+ const result = await renderElementToRaster(node, 2);
10267
+ const blob = await rasterResultToPngBlob(result);
10268
+ const el = state.elementLookup.get(elementId);
10269
+ downloadBlob(blob, elementPictureFilename(el?.name, "Picture"));
10270
+ })();
10271
+ },
10272
+ [state.elementLookup]
10273
+ );
10274
+ const pasteSpecial = usePasteSpecial({
10275
+ clipboardPayload: state.clipboardPayload,
10276
+ editTemplateMode: state.editTemplateMode,
10277
+ ops,
10278
+ markDirty: history.markDirty
10279
+ });
10052
10280
  const manipulation = useElementManipulation({
10053
10281
  activeSlide,
10054
10282
  activeSlideIndex,
@@ -10066,7 +10294,10 @@ function useEditorOperations(input) {
10066
10294
  setSidebarPanelMode: state.setSidebarPanelMode,
10067
10295
  ops,
10068
10296
  history,
10069
- onOpenHyperlinkDialog: () => dialogs.setIsHyperlinkDialogOpen(true)
10297
+ onOpenHyperlinkDialog: () => dialogs.setIsHyperlinkDialogOpen(true),
10298
+ onEditText: handleEditTextFromContextMenu,
10299
+ onSaveElementAsPicture: handleSaveElementAsPicture,
10300
+ onPasted: pasteSpecial.notePastedElement
10070
10301
  });
10071
10302
  const slideOps = useSlideManagement({
10072
10303
  slides,
@@ -10126,6 +10357,7 @@ function useEditorOperations(input) {
10126
10357
  canvasHandlers: formatPainterCanvasHandlers,
10127
10358
  insertHandlers: { ...insertHandlers, imagePaste },
10128
10359
  manipulation,
10360
+ pasteSpecial,
10129
10361
  slideOps,
10130
10362
  tableOps,
10131
10363
  copyFormatFromSelection,
@@ -10644,6 +10876,9 @@ function useKeyboardShortcuts(input) {
10644
10876
  case "cycleSelectionPrev":
10645
10877
  current.onCycleSelectionPrev?.();
10646
10878
  break;
10879
+ case "pasteSpecial":
10880
+ current.onPasteSpecial?.();
10881
+ break;
10647
10882
  }
10648
10883
  }, []);
10649
10884
  useEffect(() => {
@@ -10677,7 +10912,8 @@ function useKeyboardShortcutWiring(input) {
10677
10912
  handleAddSlide,
10678
10913
  onOpenHyperlinkDialog,
10679
10914
  copyFormatFromSelection,
10680
- pasteFormatToSelection
10915
+ pasteFormatToSelection,
10916
+ onPasteSpecial
10681
10917
  } = input;
10682
10918
  useKeyboardShortcuts({
10683
10919
  containerRef: state.containerRef,
@@ -10764,7 +11000,8 @@ function useKeyboardShortcutWiring(input) {
10764
11000
  onHyperlink: onOpenHyperlinkDialog,
10765
11001
  onClearFormatting: () => ops.updateSelectedTextStyle({ ...CLEAR_FORMATTING_PATCH }),
10766
11002
  onCycleSelectionNext: () => cycleSelection(state, activeSlide, ops, "next"),
10767
- onCycleSelectionPrev: () => cycleSelection(state, activeSlide, ops, "prev")
11003
+ onCycleSelectionPrev: () => cycleSelection(state, activeSlide, ops, "prev"),
11004
+ onPasteSpecial
10768
11005
  });
10769
11006
  }
10770
11007
  function stepSelectedFontSize(state, ops, direction) {
@@ -11183,7 +11420,8 @@ function useViewerIntegration(input) {
11183
11420
  handleAddSlide: editorOps.slideOps.handleAddSlide,
11184
11421
  onOpenHyperlinkDialog: () => dialogs.setIsHyperlinkDialogOpen(true),
11185
11422
  copyFormatFromSelection: editorOps.copyFormatFromSelection,
11186
- pasteFormatToSelection: editorOps.pasteFormatToSelection
11423
+ pasteFormatToSelection: editorOps.pasteFormatToSelection,
11424
+ onPasteSpecial: editorOps.pasteSpecial.openPasteSpecialDialog
11187
11425
  });
11188
11426
  return {
11189
11427
  exportHandlers,
@@ -12053,6 +12291,7 @@ function buildCanvasProps(input) {
12053
12291
  onMouseDown: canvasHandlers.handleElementMouseDown,
12054
12292
  onContextMenu: canvasHandlers.handleElementContextMenu,
12055
12293
  onCanvasMouseDown: canvasHandlers.handleCanvasMouseDown,
12294
+ onCanvasContextMenu: canvasHandlers.handleCanvasContextMenu,
12056
12295
  onResizePointerDown: canvasHandlers.handleResizePointerDown,
12057
12296
  onAdjustmentPointerDown: canvasHandlers.handleAdjustmentPointerDown,
12058
12297
  onRotate: canvasHandlers.handleRotate,
@@ -16075,7 +16314,7 @@ function FailedToLoad() {
16075
16314
  var LazyModel3DScene = React17.lazy(
16076
16315
  async () => {
16077
16316
  try {
16078
- return await import('./Model3DScene-AI2JTBQM.mjs');
16317
+ return await import('./Model3DScene-QXMMJRV3.mjs');
16079
16318
  } catch {
16080
16319
  return { default: FailedToLoad };
16081
16320
  }
@@ -16223,9 +16462,13 @@ function buildTooltip(info) {
16223
16462
  function stopPointer(e) {
16224
16463
  e.stopPropagation();
16225
16464
  }
16226
- function OleActionFooter({ el, info }) {
16465
+ function OleActionFooter({
16466
+ el,
16467
+ info,
16468
+ showActions
16469
+ }) {
16227
16470
  const { t } = useTranslation();
16228
- if (!info.canDownload || !el.oleEmbeddedData) {
16471
+ if (!showActions || !info.canDownload || !el.oleEmbeddedData) {
16229
16472
  return null;
16230
16473
  }
16231
16474
  const downloadName = info.fileName ?? "embedded-object";
@@ -16268,7 +16511,10 @@ function OleActionFooter({ el, info }) {
16268
16511
  }
16269
16512
  );
16270
16513
  }
16271
- function OleRenderer({ element: el }) {
16514
+ function OleRenderer({
16515
+ element: el,
16516
+ showActions = true
16517
+ }) {
16272
16518
  const oleType = resolveOleType(el);
16273
16519
  const ariaLabel = getOleAriaLabel(el);
16274
16520
  const info = buildEmbedInfo(el);
@@ -16292,7 +16538,7 @@ function OleRenderer({ element: el }) {
16292
16538
  }
16293
16539
  ),
16294
16540
  renderOleBadge(oleType),
16295
- /* @__PURE__ */ jsx(OleActionFooter, { el, info })
16541
+ /* @__PURE__ */ jsx(OleActionFooter, { el, info, showActions })
16296
16542
  ]
16297
16543
  }
16298
16544
  );
@@ -16316,7 +16562,7 @@ function OleRenderer({ element: el }) {
16316
16562
  getOleIcon(oleType, color, 36),
16317
16563
  /* @__PURE__ */ jsx("span", { className: "mt-2 text-[12px] font-medium max-w-[90%] truncate", style: { color }, children: displayName }),
16318
16564
  /* @__PURE__ */ jsx("span", { className: "mt-0.5 text-[10px] text-white/50 max-w-[90%] truncate", children: info.readableSize ? `${label} \xB7 ${info.readableSize}` : label }),
16319
- /* @__PURE__ */ jsx(OleActionFooter, { el, info })
16565
+ /* @__PURE__ */ jsx(OleActionFooter, { el, info, showActions })
16320
16566
  ]
16321
16567
  }
16322
16568
  );
@@ -17631,14 +17877,30 @@ function ZoomElementRenderer({
17631
17877
  onClick: (event) => {
17632
17878
  if (isPresentationMode && onZoomClick) {
17633
17879
  event.stopPropagation();
17634
- onZoomClick(tile.targetSlideIndex, sourceSlideIndex ?? 0);
17880
+ onZoomClick(
17881
+ {
17882
+ targetSlideIndex: tile.targetSlideIndex,
17883
+ targetSectionId: tile.sectionId,
17884
+ returnToParent: tile.returnToParent,
17885
+ transitionDurationMs: tile.transitionDurationMs
17886
+ },
17887
+ sourceSlideIndex ?? 0
17888
+ );
17635
17889
  }
17636
17890
  },
17637
17891
  onKeyDown: (event) => {
17638
17892
  if (isPresentationMode && onZoomClick && (event.key === "Enter" || event.key === " ")) {
17639
17893
  event.preventDefault();
17640
17894
  event.stopPropagation();
17641
- onZoomClick(tile.targetSlideIndex, sourceSlideIndex ?? 0);
17895
+ onZoomClick(
17896
+ {
17897
+ targetSlideIndex: tile.targetSlideIndex,
17898
+ targetSectionId: tile.sectionId,
17899
+ returnToParent: tile.returnToParent,
17900
+ transitionDurationMs: tile.transitionDurationMs
17901
+ },
17902
+ sourceSlideIndex ?? 0
17903
+ );
17642
17904
  }
17643
17905
  },
17644
17906
  children: tile.imageSrc ? /* @__PURE__ */ jsx(
@@ -17666,7 +17928,10 @@ function ZoomElementRenderer({
17666
17928
  return;
17667
17929
  }
17668
17930
  e.stopPropagation();
17669
- onZoomClick(element.targetSlideIndex, sourceSlideIndex ?? 0);
17931
+ const target = resolveZoomNavigationTarget(element);
17932
+ if (target) {
17933
+ onZoomClick(target, sourceSlideIndex ?? 0);
17934
+ }
17670
17935
  };
17671
17936
  const handleKeyDown = (e) => {
17672
17937
  if (!isPresentationMode || !onZoomClick) {
@@ -17675,7 +17940,10 @@ function ZoomElementRenderer({
17675
17940
  if (e.key === "Enter" || e.key === " ") {
17676
17941
  e.preventDefault();
17677
17942
  e.stopPropagation();
17678
- onZoomClick(element.targetSlideIndex, sourceSlideIndex ?? 0);
17943
+ const target = resolveZoomNavigationTarget(element);
17944
+ if (target) {
17945
+ onZoomClick(target, sourceSlideIndex ?? 0);
17946
+ }
17679
17947
  }
17680
17948
  };
17681
17949
  const hasPreviewImage = Boolean(element.imageData);
@@ -17957,7 +18225,16 @@ function renderBody(options) {
17957
18225
  });
17958
18226
  }
17959
18227
  if (el.type === "ole") {
17960
- return /* @__PURE__ */ jsx(OleRenderer, { element: el });
18228
+ return /* @__PURE__ */ jsx(
18229
+ OleRenderer,
18230
+ {
18231
+ element: el,
18232
+ showActions: oleActionsVisible({
18233
+ presenting: isPresentationPassive === true,
18234
+ preview: isStaticSurface === true
18235
+ })
18236
+ }
18237
+ );
17961
18238
  }
17962
18239
  if (doGrp && el.type === "group" && el.children) {
17963
18240
  if (renderGroupChild) {