pptx-react-viewer 4.33.0 → 4.33.2
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/CHANGELOG.md +25 -0
- package/dist/{AiChatPanel-47A5ONVT.mjs → AiChatPanel-CYD46SEM.mjs} +1 -1
- package/dist/AiChatPanel-CYD46SEM.mjs.br +0 -0
- package/dist/AiChatPanel-CYD46SEM.mjs.gz +0 -0
- package/dist/{AiChatPanel-FV5ECOV5.js → AiChatPanel-ONHWZEPV.js} +9 -9
- package/dist/AiChatPanel-ONHWZEPV.js.br +0 -0
- package/dist/AiChatPanel-ONHWZEPV.js.gz +0 -0
- package/dist/{chunk-DD3ARHEW.mjs → chunk-2OIJUZD5.mjs} +7 -3
- package/dist/chunk-2OIJUZD5.mjs.br +0 -0
- package/dist/chunk-2OIJUZD5.mjs.gz +0 -0
- package/dist/{chunk-SQUVXHAE.js → chunk-7DGKSEIU.js} +1 -8
- package/dist/chunk-7DGKSEIU.js.br +0 -0
- package/dist/{chunk-SQUVXHAE.js.gz → chunk-7DGKSEIU.js.gz} +0 -0
- package/dist/{chunk-JL7A7NDD.js → chunk-DJ32R6VM.js} +388 -387
- package/dist/chunk-DJ32R6VM.js.br +0 -0
- package/dist/chunk-DJ32R6VM.js.gz +0 -0
- package/dist/{chunk-WEPZYAB6.mjs → chunk-K4UXDQZ6.mjs} +1 -8
- package/dist/chunk-K4UXDQZ6.mjs.br +0 -0
- package/dist/{chunk-WEPZYAB6.mjs.gz → chunk-K4UXDQZ6.mjs.gz} +0 -0
- package/dist/{chunk-LOBNIIFQ.mjs → chunk-P3ANCQX6.mjs} +8 -7
- package/dist/chunk-P3ANCQX6.mjs.br +0 -0
- package/dist/chunk-P3ANCQX6.mjs.gz +0 -0
- package/dist/{chunk-552NAFTD.js → chunk-TVSTM5J5.js} +251 -247
- package/dist/chunk-TVSTM5J5.js.br +0 -0
- package/dist/chunk-TVSTM5J5.js.gz +0 -0
- package/dist/index.js +24 -24
- package/dist/index.js.br +0 -0
- package/dist/index.js.gz +0 -0
- package/dist/index.mjs +3 -3
- package/dist/index.mjs.br +0 -0
- package/dist/index.mjs.gz +0 -0
- package/dist/internals.js +81 -81
- package/dist/internals.js.br +0 -0
- package/dist/internals.js.gz +0 -0
- package/dist/internals.mjs +2 -2
- package/dist/internals.mjs.br +0 -0
- package/dist/internals.mjs.gz +0 -0
- package/dist/viewer/index.js +19 -19
- package/dist/viewer/index.js.br +0 -0
- package/dist/viewer/index.js.gz +0 -0
- package/dist/viewer/index.mjs +3 -3
- package/dist/viewer/index.mjs.br +0 -0
- package/dist/viewer/index.mjs.gz +0 -0
- package/package.json +4 -4
- package/dist/AiChatPanel-47A5ONVT.mjs.br +0 -0
- package/dist/AiChatPanel-47A5ONVT.mjs.gz +0 -0
- package/dist/AiChatPanel-FV5ECOV5.js.br +0 -0
- package/dist/AiChatPanel-FV5ECOV5.js.gz +0 -0
- package/dist/chunk-552NAFTD.js.br +0 -0
- package/dist/chunk-552NAFTD.js.gz +0 -0
- package/dist/chunk-DD3ARHEW.mjs.br +0 -0
- package/dist/chunk-DD3ARHEW.mjs.gz +0 -0
- package/dist/chunk-JL7A7NDD.js.br +0 -0
- package/dist/chunk-JL7A7NDD.js.gz +0 -0
- package/dist/chunk-LOBNIIFQ.mjs.br +0 -0
- package/dist/chunk-LOBNIIFQ.mjs.gz +0 -0
- package/dist/chunk-SQUVXHAE.js.br +0 -0
- package/dist/chunk-WEPZYAB6.mjs.br +0 -0
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
3
|
+
var chunkTVSTM5J5_js = require('./chunk-TVSTM5J5.js');
|
|
4
|
+
var chunk7DGKSEIU_js = require('./chunk-7DGKSEIU.js');
|
|
5
5
|
var pptx = require('ooxml-ui/pptx');
|
|
6
6
|
var React99 = require('react');
|
|
7
7
|
var jsxRuntime = require('react/jsx-runtime');
|
|
@@ -307,7 +307,7 @@ function SlideTemplatePreview({
|
|
|
307
307
|
transformOrigin: "top left"
|
|
308
308
|
},
|
|
309
309
|
children: previewSlide.elements.map((element, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
310
|
-
|
|
310
|
+
chunkTVSTM5J5_js.StaticElementRenderer,
|
|
311
311
|
{
|
|
312
312
|
element,
|
|
313
313
|
activeSlide: previewSlide,
|
|
@@ -376,7 +376,7 @@ function SlideTemplateGalleryDialog({
|
|
|
376
376
|
scheme
|
|
377
377
|
}) {
|
|
378
378
|
const { t } = reactI18next.useTranslation();
|
|
379
|
-
const { panelStyle, handlers: dragHandlers } =
|
|
379
|
+
const { panelStyle, handlers: dragHandlers } = chunkTVSTM5J5_js.useModalDismissDrag(onClose);
|
|
380
380
|
const [selected, setSelected] = React99.useState(null);
|
|
381
381
|
const dialogRef = React99.useRef(null);
|
|
382
382
|
useModalFocus(isOpen, dialogRef, onClose);
|
|
@@ -459,7 +459,7 @@ function SlideTemplateGalleryDialog({
|
|
|
459
459
|
onInsert(spec.id);
|
|
460
460
|
onClose();
|
|
461
461
|
},
|
|
462
|
-
className:
|
|
462
|
+
className: chunk7DGKSEIU_js.cn(
|
|
463
463
|
"flex flex-col items-center gap-1 p-2 rounded border transition-colors",
|
|
464
464
|
selected === spec.id ? "border-primary bg-primary/20" : "border-border hover:border-border hover:bg-muted/50"
|
|
465
465
|
),
|
|
@@ -723,7 +723,7 @@ function WebHomeControls({
|
|
|
723
723
|
function ShapeArrangeExtras(p) {
|
|
724
724
|
const commands = useShapeFormatContext();
|
|
725
725
|
const crop = commands?.crop;
|
|
726
|
-
const { isHidden } =
|
|
726
|
+
const { isHidden } = chunkTVSTM5J5_js.useToolbarVisibility(p.hiddenActions);
|
|
727
727
|
const { onGroupElements, onUngroupElement, onUpdateElementStyle } = p;
|
|
728
728
|
const controls = React99.useMemo(
|
|
729
729
|
() => pptx.arrangeShapeHomeControls({
|
|
@@ -1056,7 +1056,7 @@ function TransitionsSection(p) {
|
|
|
1056
1056
|
case "soundPreview": {
|
|
1057
1057
|
const url = pptx.ribbonTransitionStockSoundUrl(transition);
|
|
1058
1058
|
if (url) {
|
|
1059
|
-
|
|
1059
|
+
chunkTVSTM5J5_js.playAnimationSound(url);
|
|
1060
1060
|
}
|
|
1061
1061
|
break;
|
|
1062
1062
|
}
|
|
@@ -1215,7 +1215,7 @@ function AccountPage() {
|
|
|
1215
1215
|
return void 0;
|
|
1216
1216
|
});
|
|
1217
1217
|
};
|
|
1218
|
-
const version = "4.33.
|
|
1218
|
+
const version = "4.33.2" ;
|
|
1219
1219
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "mt-8 max-w-[700px] space-y-6", children: [
|
|
1220
1220
|
/* @__PURE__ */ jsxRuntime.jsxs("section", { className: cardClass, children: [
|
|
1221
1221
|
/* @__PURE__ */ jsxRuntime.jsxs("h2", { className: "flex items-center gap-2 text-sm font-semibold", children: [
|
|
@@ -1255,7 +1255,7 @@ function AccountPage() {
|
|
|
1255
1255
|
"aria-label": color,
|
|
1256
1256
|
"aria-pressed": profile.avatarColor === color,
|
|
1257
1257
|
onClick: () => updateProfile({ avatarColor: color }),
|
|
1258
|
-
className:
|
|
1258
|
+
className: chunk7DGKSEIU_js.cn(
|
|
1259
1259
|
"size-7 rounded-full border-2 transition-transform",
|
|
1260
1260
|
profile.avatarColor === color ? "border-foreground scale-110" : "border-transparent hover:scale-105"
|
|
1261
1261
|
),
|
|
@@ -1478,7 +1478,7 @@ function FileSection(p) {
|
|
|
1478
1478
|
const page = offered(requestedPage) ? requestedPage : offered("home") ? "home" : nav.find((item) => item.id !== "save" && item.id !== "close")?.id ?? "home";
|
|
1479
1479
|
const [query, setQuery] = React99.useState("");
|
|
1480
1480
|
const [recent, setRecent] = React99.useState([]);
|
|
1481
|
-
const { isHidden } =
|
|
1481
|
+
const { isHidden } = chunkTVSTM5J5_js.useToolbarVisibility(p.hiddenActions);
|
|
1482
1482
|
const exportHidden = isHidden("export");
|
|
1483
1483
|
React99.useEffect(() => {
|
|
1484
1484
|
void pptx.listBackstageRecentFiles(t, p.recentPresentationsCount).then(setRecent);
|
|
@@ -1708,7 +1708,7 @@ function RibbonMenu({
|
|
|
1708
1708
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
1709
1709
|
"div",
|
|
1710
1710
|
{
|
|
1711
|
-
className:
|
|
1711
|
+
className: chunk7DGKSEIU_js.cn("fixed z-50", className),
|
|
1712
1712
|
style: pos ? { left: pos.left, top: pos.top } : { visibility: "hidden" },
|
|
1713
1713
|
children
|
|
1714
1714
|
}
|
|
@@ -1734,7 +1734,7 @@ function LayoutGalleryMenu(p) {
|
|
|
1734
1734
|
type: "button",
|
|
1735
1735
|
"aria-current": isCurrent ? "true" : void 0,
|
|
1736
1736
|
title: isCurrent ? `${layout.name} (${t("pptx.layoutGallery.current")})` : layout.name,
|
|
1737
|
-
className:
|
|
1737
|
+
className: chunk7DGKSEIU_js.cn(
|
|
1738
1738
|
"relative flex min-w-0 flex-col items-center gap-1 rounded border-2 p-1 text-xs text-foreground transition-colors hover:bg-muted",
|
|
1739
1739
|
isCurrent ? "border-primary bg-primary/10" : "border-transparent"
|
|
1740
1740
|
),
|
|
@@ -1808,7 +1808,7 @@ function LayoutArtwork({
|
|
|
1808
1808
|
backgroundColor
|
|
1809
1809
|
};
|
|
1810
1810
|
return /* @__PURE__ */ jsxRuntime.jsx(jsxRuntime.Fragment, { children: (preview?.elements ?? []).slice(0, MAX_PREVIEW_ELEMENTS).map((element, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
1811
|
-
|
|
1811
|
+
chunkTVSTM5J5_js.StaticElementRenderer,
|
|
1812
1812
|
{
|
|
1813
1813
|
element,
|
|
1814
1814
|
activeSlide: slide,
|
|
@@ -2370,7 +2370,7 @@ function CustomShowsControls({
|
|
|
2370
2370
|
{
|
|
2371
2371
|
type: "button",
|
|
2372
2372
|
onClick: onToggleCurrentSlideInActiveShow,
|
|
2373
|
-
className:
|
|
2373
|
+
className: chunk7DGKSEIU_js.cn(
|
|
2374
2374
|
"px-2 py-1 rounded text-[11px] transition-colors",
|
|
2375
2375
|
isCurrentSlideInActiveShow ? "bg-primary text-white" : "bg-muted hover:bg-accent"
|
|
2376
2376
|
),
|
|
@@ -2425,7 +2425,7 @@ function SlideShowOptions({
|
|
|
2425
2425
|
}
|
|
2426
2426
|
function SubtitleSettingsControl() {
|
|
2427
2427
|
const { t } = reactI18next.useTranslation();
|
|
2428
|
-
const supplied = React99.useContext(
|
|
2428
|
+
const supplied = React99.useContext(chunkTVSTM5J5_js.ViewerOptionsStoreContext);
|
|
2429
2429
|
const fallback = React99.useRef(null);
|
|
2430
2430
|
if (!supplied) {
|
|
2431
2431
|
fallback.current ??= pptx.createViewerOptionsStore({ persist: false });
|
|
@@ -2459,7 +2459,7 @@ function SubtitleSettingsControl() {
|
|
|
2459
2459
|
}
|
|
2460
2460
|
function SlideShowSection(p) {
|
|
2461
2461
|
const { t } = reactI18next.useTranslation();
|
|
2462
|
-
const { isHidden } =
|
|
2462
|
+
const { isHidden } = chunkTVSTM5J5_js.useToolbarVisibility(p.hiddenActions);
|
|
2463
2463
|
const [showsOpen, setShowsOpen] = React99.useState(false);
|
|
2464
2464
|
const showsRef = React99.useRef(null);
|
|
2465
2465
|
React99.useEffect(() => {
|
|
@@ -2540,7 +2540,7 @@ function extractFontInfo(element, themeFonts) {
|
|
|
2540
2540
|
fontFamily: pptx.resolveDefaultFontFamily(placeholderType, themeFonts),
|
|
2541
2541
|
fontSize: "24"
|
|
2542
2542
|
};
|
|
2543
|
-
if (!element || !(0,
|
|
2543
|
+
if (!element || !(0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(element)) {
|
|
2544
2544
|
return defaults;
|
|
2545
2545
|
}
|
|
2546
2546
|
const segStyle = element.textSegments?.[0]?.style;
|
|
@@ -2561,7 +2561,7 @@ function getEffectiveTextStyle(element, tableEditorState) {
|
|
|
2561
2561
|
if (!element) {
|
|
2562
2562
|
return void 0;
|
|
2563
2563
|
}
|
|
2564
|
-
if ((0,
|
|
2564
|
+
if ((0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(element)) {
|
|
2565
2565
|
return element.textStyle;
|
|
2566
2566
|
}
|
|
2567
2567
|
if (element.type === "table" && tableEditorState && element.tableData) {
|
|
@@ -2574,7 +2574,7 @@ function isTextDecorationFlag(id) {
|
|
|
2574
2574
|
return pptx.TEXT_DECORATION_FLAGS.includes(id);
|
|
2575
2575
|
}
|
|
2576
2576
|
function textSectionFlags(element, tableEditorState, readSelection) {
|
|
2577
|
-
if (element && (0,
|
|
2577
|
+
if (element && (0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(element)) {
|
|
2578
2578
|
const result = readSelection ? pptx.getInlineEditorSelectionResult(element.textSegments) : null;
|
|
2579
2579
|
const current = result?.kind === "supported" && (!result.snapshot || result.snapshot.elementId === element.id) ? result : null;
|
|
2580
2580
|
return pptx.getSelectionTextStyleFlags(
|
|
@@ -2590,7 +2590,7 @@ function textSectionFlags(element, tableEditorState, readSelection) {
|
|
|
2590
2590
|
);
|
|
2591
2591
|
}
|
|
2592
2592
|
function textSectionBulletKind(element, tableEditorState) {
|
|
2593
|
-
if (element && (0,
|
|
2593
|
+
if (element && (0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(element)) {
|
|
2594
2594
|
const result = pptx.getInlineEditorSelectionResult(element.textSegments, { preserveCaret: true });
|
|
2595
2595
|
return result.kind === "supported" && (!result.snapshot || result.snapshot.elementId === element.id) ? pptx.selectionBulletKind(element, result.selection, result.snapshot?.textSegments) : pptx.elementBulletKind(element);
|
|
2596
2596
|
}
|
|
@@ -2827,7 +2827,7 @@ function subscribe(onChange) {
|
|
|
2827
2827
|
}
|
|
2828
2828
|
function useParagraphListKind(element) {
|
|
2829
2829
|
const read = React99.useCallback(() => {
|
|
2830
|
-
if (!element || !(0,
|
|
2830
|
+
if (!element || !(0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(element)) {
|
|
2831
2831
|
return "none";
|
|
2832
2832
|
}
|
|
2833
2833
|
const result = pptx.getInlineEditorSelectionResult(element.textSegments, { preserveCaret: true });
|
|
@@ -2850,7 +2850,7 @@ function TextSection(p) {
|
|
|
2850
2850
|
const hasSel = Boolean(p.selectedElement);
|
|
2851
2851
|
const canMut = hasSel && p.canEdit;
|
|
2852
2852
|
const { fontFamily, fontSize } = extractFontInfo(p.selectedElement, p.themeFonts);
|
|
2853
|
-
const isTextEl = hasSel && p.selectedElement !== null && (0,
|
|
2853
|
+
const isTextEl = hasSel && p.selectedElement !== null && (0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(p.selectedElement);
|
|
2854
2854
|
const isTable = hasSel && p.selectedElement?.type === "table";
|
|
2855
2855
|
const canFormat = isTextEl || isTable;
|
|
2856
2856
|
const effectiveTs = getEffectiveTextStyle(p.selectedElement, p.tableEditorState);
|
|
@@ -2860,15 +2860,15 @@ function TextSection(p) {
|
|
|
2860
2860
|
if (!p.canEdit || !canFormat || !p.selectedElement) {
|
|
2861
2861
|
return;
|
|
2862
2862
|
}
|
|
2863
|
-
if ((0,
|
|
2863
|
+
if ((0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(p.selectedElement)) {
|
|
2864
2864
|
p.onToggleBullets(kind);
|
|
2865
2865
|
return;
|
|
2866
2866
|
}
|
|
2867
2867
|
p.onUpdateTextStyle({ listType: effectiveTs?.listType === kind ? "none" : kind });
|
|
2868
2868
|
};
|
|
2869
|
-
const currentColor = isTextEl && p.selectedElement && (0,
|
|
2870
|
-
const currentColorThemeRef = isTextEl && p.selectedElement && (0,
|
|
2871
|
-
const currentHighlight = isTextEl && p.selectedElement && (0,
|
|
2869
|
+
const currentColor = isTextEl && p.selectedElement && (0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(p.selectedElement) ? p.selectedElement.textSegments?.[0]?.style?.color ?? p.selectedElement.textStyle?.color ?? "#000000" : effectiveTs?.color ?? "#000000";
|
|
2870
|
+
const currentColorThemeRef = isTextEl && p.selectedElement && (0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(p.selectedElement) ? p.selectedElement.textSegments?.[0]?.style?.colorRef ?? p.selectedElement.textStyle?.colorRef : void 0;
|
|
2871
|
+
const currentHighlight = isTextEl && p.selectedElement && (0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(p.selectedElement) ? p.selectedElement.textSegments?.[0]?.style?.highlightColor ?? p.selectedElement.textStyle?.highlightColor ?? "#ffff00" : "#ffff00";
|
|
2872
2872
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
2873
2873
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col items-center gap-0.5", ...groupAttr("home.font"), children: [
|
|
2874
2874
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-1", "data-pptx-chrome": "font-controls", children: [
|
|
@@ -2883,7 +2883,7 @@ function TextSection(p) {
|
|
|
2883
2883
|
customFonts: p.customFontFamilies,
|
|
2884
2884
|
onFamily: (family) => p.onUpdateTextStyle({ fontFamily: family }),
|
|
2885
2885
|
onSize: (size) => p.onUpdateTextStyle({
|
|
2886
|
-
fontSize: p.selectedElement && (0,
|
|
2886
|
+
fontSize: p.selectedElement && (0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(p.selectedElement) ? pptx.textFontSizePtToPx(size) : size
|
|
2887
2887
|
})
|
|
2888
2888
|
}
|
|
2889
2889
|
),
|
|
@@ -2993,7 +2993,7 @@ function MobileSheet({
|
|
|
2993
2993
|
}) {
|
|
2994
2994
|
const sheetRef = React99.useRef(null);
|
|
2995
2995
|
const { t } = reactI18next.useTranslation();
|
|
2996
|
-
const { dragY, dragging, handlers } =
|
|
2996
|
+
const { dragY, dragging, handlers } = chunkTVSTM5J5_js.useSheetDismissDrag(onClose);
|
|
2997
2997
|
useModalFocus(open, sheetRef, onClose);
|
|
2998
2998
|
if (!open) {
|
|
2999
2999
|
return null;
|
|
@@ -3017,7 +3017,7 @@ function MobileSheet({
|
|
|
3017
3017
|
"aria-modal": "true",
|
|
3018
3018
|
"aria-label": typeof title === "string" ? title : t("pptx.mobileSheet.ariaLabel"),
|
|
3019
3019
|
tabIndex: -1,
|
|
3020
|
-
className:
|
|
3020
|
+
className: chunk7DGKSEIU_js.cn(
|
|
3021
3021
|
"relative bg-background border-t border-border rounded-t-2xl shadow-2xl flex flex-col overflow-hidden",
|
|
3022
3022
|
"animate-in slide-in-from-bottom duration-200",
|
|
3023
3023
|
className
|
|
@@ -3081,7 +3081,7 @@ function MobileMenuSheet(props) {
|
|
|
3081
3081
|
const { t } = reactI18next.useTranslation();
|
|
3082
3082
|
const { open, onClose } = props;
|
|
3083
3083
|
const [active, setActive] = React99.useState("home");
|
|
3084
|
-
const { isTabVisible } =
|
|
3084
|
+
const { isTabVisible } = chunkTVSTM5J5_js.useToolbarVisibility(props.hiddenActions);
|
|
3085
3085
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
3086
3086
|
MobileSheet,
|
|
3087
3087
|
{
|
|
@@ -3095,7 +3095,7 @@ function MobileMenuSheet(props) {
|
|
|
3095
3095
|
{
|
|
3096
3096
|
type: "button",
|
|
3097
3097
|
onClick: () => setActive(active === key ? null : key),
|
|
3098
|
-
className:
|
|
3098
|
+
className: chunk7DGKSEIU_js.cn(
|
|
3099
3099
|
"inline-flex items-center gap-1.5 shrink-0 px-3 py-2 rounded-full text-[12px] font-medium border transition-colors min-h-[36px]",
|
|
3100
3100
|
active === key ? "bg-primary text-white border-primary" : "border-border text-muted-foreground hover:text-foreground hover:bg-accent/40"
|
|
3101
3101
|
),
|
|
@@ -3362,7 +3362,7 @@ function MobileToolbar(props) {
|
|
|
3362
3362
|
const { t } = reactI18next.useTranslation();
|
|
3363
3363
|
const { mode, canUndo, canRedo, onUndo, onRedo, onSetMode, onSaveAsPptx } = props;
|
|
3364
3364
|
const [menuOpen, setMenuOpen] = React99.useState(false);
|
|
3365
|
-
const { isHidden } =
|
|
3365
|
+
const { isHidden } = chunkTVSTM5J5_js.useToolbarVisibility(props.hiddenActions);
|
|
3366
3366
|
const showEdit = mode === "edit" || mode === "master";
|
|
3367
3367
|
const hidden = [];
|
|
3368
3368
|
if (isHidden("undo")) {
|
|
@@ -3427,7 +3427,7 @@ function DrawingGroup(p) {
|
|
|
3427
3427
|
const { recentColors, pushColor } = useRecentColors();
|
|
3428
3428
|
const themeColors = useThemeColorMap();
|
|
3429
3429
|
const commands = useRibbonGalleryCommands();
|
|
3430
|
-
const style = p.selectedElement && (0,
|
|
3430
|
+
const style = p.selectedElement && (0, chunk7DGKSEIU_js.dist_exports.hasShapeProperties)(p.selectedElement) ? p.selectedElement.shapeStyle : void 0;
|
|
3431
3431
|
const { onMoveLayer, onMoveLayerToEdge, onSetNewShapeType, onAddShape, onUpdateElementStyle } = p;
|
|
3432
3432
|
const hasSelection = Boolean(p.selectedElement);
|
|
3433
3433
|
const controls = React99.useMemo(
|
|
@@ -3477,7 +3477,7 @@ function DrawingGroup(p) {
|
|
|
3477
3477
|
pushColor(String(value));
|
|
3478
3478
|
break;
|
|
3479
3479
|
case "home.drawing.shapeOutline":
|
|
3480
|
-
onUpdateElementStyle?.(pptx.shapeOutlineChange(String(value), intent?.ref));
|
|
3480
|
+
onUpdateElementStyle?.(pptx.shapeOutlineChange(String(value), intent?.ref, style ?? {}));
|
|
3481
3481
|
pushColor(String(value));
|
|
3482
3482
|
break;
|
|
3483
3483
|
default:
|
|
@@ -3496,7 +3496,8 @@ function DrawingGroup(p) {
|
|
|
3496
3496
|
onAddShape,
|
|
3497
3497
|
onUpdateElementStyle,
|
|
3498
3498
|
pushColor,
|
|
3499
|
-
commands
|
|
3499
|
+
commands,
|
|
3500
|
+
style
|
|
3500
3501
|
]
|
|
3501
3502
|
);
|
|
3502
3503
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
@@ -3555,7 +3556,7 @@ var TAB_BASE = "relative px-3.5 py-2 text-[12px] font-medium whitespace-nowrap t
|
|
|
3555
3556
|
var TAB_UNDERLINE = "after:absolute after:-bottom-px after:left-0 after:right-0 after:h-[2.5px] after:bg-primary";
|
|
3556
3557
|
function RibbonTabBar(p) {
|
|
3557
3558
|
const { t } = reactI18next.useTranslation();
|
|
3558
|
-
const viewerOptions =
|
|
3559
|
+
const viewerOptions = chunkTVSTM5J5_js.useViewerOptionsContext();
|
|
3559
3560
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
3560
3561
|
"div",
|
|
3561
3562
|
{
|
|
@@ -3563,7 +3564,7 @@ function RibbonTabBar(p) {
|
|
|
3563
3564
|
"data-pptx-chrome": "ribbon-tabs",
|
|
3564
3565
|
className: "flex items-center border-b border-border/60 px-1 max-md:overflow-x-auto max-md:scrollbar-none",
|
|
3565
3566
|
children: [
|
|
3566
|
-
|
|
3567
|
+
chunk7DGKSEIU_js.TOOLBAR_SECTIONS.filter((s) => p.isTabVisible(s.id)).map((s) => {
|
|
3567
3568
|
const selected = p.activeSection === s.id;
|
|
3568
3569
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
3569
3570
|
"button",
|
|
@@ -3573,7 +3574,7 @@ function RibbonTabBar(p) {
|
|
|
3573
3574
|
"aria-selected": selected,
|
|
3574
3575
|
title: pptx.resolveScreenTip(viewerOptions, t(s.labelKey)),
|
|
3575
3576
|
onClick: () => p.onSelectSection(s.id),
|
|
3576
|
-
className:
|
|
3577
|
+
className: chunk7DGKSEIU_js.cn(
|
|
3577
3578
|
TAB_BASE,
|
|
3578
3579
|
selected ? s.id === "file" ? "text-white bg-primary/80 rounded-sm" : `text-foreground ${TAB_UNDERLINE}` : s.id === "file" ? "text-primary hover:bg-primary/15 rounded-sm" : "text-muted-foreground hover:text-foreground hover:bg-accent/30"
|
|
3579
3580
|
),
|
|
@@ -3593,7 +3594,7 @@ function RibbonTabBar(p) {
|
|
|
3593
3594
|
...{ [pptx.RIBBON_ADD_IN_TAB_ATTR]: tab.id },
|
|
3594
3595
|
title: pptx.resolveScreenTip(viewerOptions, tab.label),
|
|
3595
3596
|
onClick: () => p.onSelectAddIn?.(tab.id),
|
|
3596
|
-
className:
|
|
3597
|
+
className: chunk7DGKSEIU_js.cn(
|
|
3597
3598
|
TAB_BASE,
|
|
3598
3599
|
selected ? `text-foreground ${TAB_UNDERLINE}` : "text-muted-foreground hover:text-foreground hover:bg-accent/30"
|
|
3599
3600
|
),
|
|
@@ -3614,7 +3615,7 @@ function RibbonTabBar(p) {
|
|
|
3614
3615
|
...{ [pptx.RIBBON_CONTEXTUAL_TAB_ATTR]: id },
|
|
3615
3616
|
title: pptx.resolveScreenTip(viewerOptions, label),
|
|
3616
3617
|
onClick: () => p.onSelectContextual(id),
|
|
3617
|
-
className:
|
|
3618
|
+
className: chunk7DGKSEIU_js.cn(
|
|
3618
3619
|
TAB_BASE,
|
|
3619
3620
|
"text-primary",
|
|
3620
3621
|
selected ? TAB_UNDERLINE : "hover:bg-primary/10"
|
|
@@ -3632,9 +3633,9 @@ function RibbonTabBar(p) {
|
|
|
3632
3633
|
}
|
|
3633
3634
|
function TabRowActions(p) {
|
|
3634
3635
|
const { t } = reactI18next.useTranslation();
|
|
3635
|
-
const collab =
|
|
3636
|
+
const collab = chunkTVSTM5J5_js.useCollaboration();
|
|
3636
3637
|
const isCollaborating = Boolean(collab && collab.status === "connected");
|
|
3637
|
-
const { isHidden } =
|
|
3638
|
+
const { isHidden } = chunkTVSTM5J5_js.useToolbarVisibility(p.hiddenActions);
|
|
3638
3639
|
const customization = useViewerCustomizationContext();
|
|
3639
3640
|
const ref = React99.useRef(null);
|
|
3640
3641
|
const handlers = React99.useRef(p);
|
|
@@ -3689,7 +3690,7 @@ function TabRowActions(p) {
|
|
|
3689
3690
|
}
|
|
3690
3691
|
function TitleBarElement(p) {
|
|
3691
3692
|
const { t } = reactI18next.useTranslation();
|
|
3692
|
-
const options =
|
|
3693
|
+
const options = chunkTVSTM5J5_js.useViewerOptionsContext();
|
|
3693
3694
|
const customization = useViewerCustomizationContext();
|
|
3694
3695
|
const ref = React99.useRef(null);
|
|
3695
3696
|
const stripVisible = options.quickAccess.visible && pptx.isPanelVisible(customization, "quickAccessToolbar");
|
|
@@ -3762,7 +3763,7 @@ function PresentDropdown({
|
|
|
3762
3763
|
{
|
|
3763
3764
|
type: "button",
|
|
3764
3765
|
onClick: onPresent,
|
|
3765
|
-
className:
|
|
3766
|
+
className: chunk7DGKSEIU_js.cn(
|
|
3766
3767
|
"px-2 py-1 transition-colors",
|
|
3767
3768
|
isActive ? "bg-primary text-white" : "hover:bg-accent text-foreground"
|
|
3768
3769
|
),
|
|
@@ -3775,7 +3776,7 @@ function PresentDropdown({
|
|
|
3775
3776
|
{
|
|
3776
3777
|
type: "button",
|
|
3777
3778
|
onClick: () => setOpen((prev) => !prev),
|
|
3778
|
-
className:
|
|
3779
|
+
className: chunk7DGKSEIU_js.cn(
|
|
3779
3780
|
"inline-flex items-center px-1 transition-colors border-l border-border",
|
|
3780
3781
|
open ? "bg-primary text-white" : "hover:bg-accent text-foreground"
|
|
3781
3782
|
),
|
|
@@ -3978,7 +3979,7 @@ function OverflowMenu(p) {
|
|
|
3978
3979
|
{
|
|
3979
3980
|
type: "button",
|
|
3980
3981
|
onClick: () => p.onSetOverflowMenuOpen(!p.isOverflowMenuOpen),
|
|
3981
|
-
className:
|
|
3982
|
+
className: chunk7DGKSEIU_js.cn(
|
|
3982
3983
|
"p-1.5 rounded transition-colors",
|
|
3983
3984
|
p.isOverflowMenuOpen ? "bg-primary/80 text-white" : "bg-muted hover:bg-accent"
|
|
3984
3985
|
),
|
|
@@ -4025,7 +4026,7 @@ function ToolbarPrimaryRow(p) {
|
|
|
4025
4026
|
onToggleSidebar,
|
|
4026
4027
|
onToggleInspector
|
|
4027
4028
|
} = p;
|
|
4028
|
-
const collab =
|
|
4029
|
+
const collab = chunkTVSTM5J5_js.useCollaboration();
|
|
4029
4030
|
const customization = useViewerCustomizationContext();
|
|
4030
4031
|
const showSlidesToggle = pptx.isPanelVisible(customization, "slidesPane");
|
|
4031
4032
|
const showInspectorToggle = pptx.isPanelVisible(customization, "inspector");
|
|
@@ -4043,7 +4044,7 @@ function ToolbarPrimaryRow(p) {
|
|
|
4043
4044
|
{
|
|
4044
4045
|
type: "button",
|
|
4045
4046
|
onClick: onToggleSidebar,
|
|
4046
|
-
className:
|
|
4047
|
+
className: chunk7DGKSEIU_js.cn(qab, !isSidebarCollapsed ? "text-foreground" : "text-muted-foreground"),
|
|
4047
4048
|
title: t("pptx.toolbar.toggleSlidesPanel"),
|
|
4048
4049
|
"aria-label": t("pptx.toolbar.toggleSlidesPanel"),
|
|
4049
4050
|
children: /* @__PURE__ */ jsxRuntime.jsx(lu.LuPanelLeft, { className: ic })
|
|
@@ -4104,7 +4105,7 @@ function ToolbarPrimaryRow(p) {
|
|
|
4104
4105
|
{
|
|
4105
4106
|
type: "button",
|
|
4106
4107
|
onClick: onToggleInspector,
|
|
4107
|
-
className:
|
|
4108
|
+
className: chunk7DGKSEIU_js.cn(qab, isInspectorPaneOpen ? "text-foreground" : "text-muted-foreground"),
|
|
4108
4109
|
title: t("pptx.toolbar.toggleInspector"),
|
|
4109
4110
|
"aria-label": t("pptx.toolbar.toggleInspector"),
|
|
4110
4111
|
children: /* @__PURE__ */ jsxRuntime.jsx(lu.LuPanelRight, { className: ic })
|
|
@@ -4115,7 +4116,7 @@ function ToolbarPrimaryRow(p) {
|
|
|
4115
4116
|
{
|
|
4116
4117
|
type: "button",
|
|
4117
4118
|
onClick: p.onToggleAiPanel,
|
|
4118
|
-
className:
|
|
4119
|
+
className: chunk7DGKSEIU_js.cn(qab, p.isAiPanelOpen ? "text-primary" : "text-muted-foreground"),
|
|
4119
4120
|
title: t("pptx.toolbar.toggleAiAssistant"),
|
|
4120
4121
|
"aria-label": t("pptx.toolbar.toggleAiAssistant"),
|
|
4121
4122
|
children: /* @__PURE__ */ jsxRuntime.jsx(lu.LuSparkles, { className: ic })
|
|
@@ -4126,7 +4127,7 @@ function ToolbarPrimaryRow(p) {
|
|
|
4126
4127
|
{
|
|
4127
4128
|
type: "button",
|
|
4128
4129
|
onClick: p.onOpenSettings ?? p.onToggleShortcuts,
|
|
4129
|
-
className:
|
|
4130
|
+
className: chunk7DGKSEIU_js.cn(qab, "text-muted-foreground"),
|
|
4130
4131
|
title: t("pptx.toolbar.settingsShortcuts"),
|
|
4131
4132
|
"aria-label": t("pptx.toolbar.settings"),
|
|
4132
4133
|
children: /* @__PURE__ */ jsxRuntime.jsx(lu.LuSettings, { className: ics })
|
|
@@ -4323,8 +4324,8 @@ function ToolbarLateTabs({
|
|
|
4323
4324
|
function Toolbar(p) {
|
|
4324
4325
|
const { mode, isNarrowViewport, isCompactToolbarOpen, toolbarSection, onSetToolbarSection } = p;
|
|
4325
4326
|
const { t } = reactI18next.useTranslation();
|
|
4326
|
-
const { isTabVisible } =
|
|
4327
|
-
const viewerOptions =
|
|
4327
|
+
const { isTabVisible } = chunkTVSTM5J5_js.useToolbarVisibility(p.hiddenActions);
|
|
4328
|
+
const viewerOptions = chunkTVSTM5J5_js.useViewerOptionsContext();
|
|
4328
4329
|
const customization = useViewerCustomizationContext();
|
|
4329
4330
|
const belowInput = React99.useMemo(
|
|
4330
4331
|
() => ({
|
|
@@ -4421,7 +4422,7 @@ function Toolbar(p) {
|
|
|
4421
4422
|
{
|
|
4422
4423
|
type: "button",
|
|
4423
4424
|
onClick: p.onToggleCompactToolbar,
|
|
4424
|
-
className:
|
|
4425
|
+
className: chunk7DGKSEIU_js.cn(
|
|
4425
4426
|
"px-2 py-1 rounded text-[11px] transition-colors mr-1",
|
|
4426
4427
|
isCompactToolbarOpen ? "bg-primary/80 text-white" : "text-muted-foreground hover:text-foreground"
|
|
4427
4428
|
),
|
|
@@ -4447,7 +4448,7 @@ function Toolbar(p) {
|
|
|
4447
4448
|
{
|
|
4448
4449
|
ref: attachOverflow,
|
|
4449
4450
|
"data-pptx-chrome": "ribbon-content",
|
|
4450
|
-
className:
|
|
4451
|
+
className: chunk7DGKSEIU_js.cn(
|
|
4451
4452
|
// Plain controls stay compact; labelled RibbonGroups opt into stretching.
|
|
4452
4453
|
// `RibbonGroupScope` wraps controls in a `display: contents` div, so its
|
|
4453
4454
|
// children are this row's flex items too and must not shrink (a shrunk
|
|
@@ -5301,7 +5302,7 @@ function DrawingOverlaySvg({
|
|
|
5301
5302
|
onPointerDown,
|
|
5302
5303
|
onPointerMove,
|
|
5303
5304
|
onPointerUp,
|
|
5304
|
-
children: isStrokeActive && liveStrokeView ?
|
|
5305
|
+
children: isStrokeActive && liveStrokeView ? chunkTVSTM5J5_js.renderStrokeView(liveStrokeView, true, void 0, "ink-live-preview") : isStrokeActive && liveStrokeD && /* @__PURE__ */ jsxRuntime.jsx(
|
|
5305
5306
|
"path",
|
|
5306
5307
|
{
|
|
5307
5308
|
d: liveStrokeD,
|
|
@@ -5316,7 +5317,7 @@ function DrawingOverlaySvg({
|
|
|
5316
5317
|
}
|
|
5317
5318
|
);
|
|
5318
5319
|
}
|
|
5319
|
-
function GridOverlay({ canvasSize, gridSpacingPx =
|
|
5320
|
+
function GridOverlay({ canvasSize, gridSpacingPx = chunk7DGKSEIU_js.GRID_SIZE, visible }) {
|
|
5320
5321
|
const spacing = Math.max(gridSpacingPx, 2);
|
|
5321
5322
|
const patternId = React99.useMemo(() => `grid-dot-pattern-${Math.random().toString(36).slice(2, 8)}`, []);
|
|
5322
5323
|
if (!visible) {
|
|
@@ -5880,7 +5881,7 @@ function PictureCropOverlay({
|
|
|
5880
5881
|
};
|
|
5881
5882
|
};
|
|
5882
5883
|
const { ghost, frame, handles } = overlay;
|
|
5883
|
-
const src =
|
|
5884
|
+
const src = chunkTVSTM5J5_js.imgSrc(element);
|
|
5884
5885
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
5885
5886
|
"div",
|
|
5886
5887
|
{
|
|
@@ -6293,10 +6294,10 @@ function SelectionHandleOverlay({
|
|
|
6293
6294
|
position: "absolute",
|
|
6294
6295
|
left: element.x,
|
|
6295
6296
|
top: element.y,
|
|
6296
|
-
width: Math.max(element.width,
|
|
6297
|
-
height: Math.max(element.height,
|
|
6298
|
-
["--pptx-selection-width"]: `${Math.max(element.width,
|
|
6299
|
-
["--pptx-selection-height"]: `${Math.max(element.height,
|
|
6297
|
+
width: Math.max(element.width, chunk7DGKSEIU_js.MIN_ELEMENT_SIZE),
|
|
6298
|
+
height: Math.max(element.height, chunk7DGKSEIU_js.MIN_ELEMENT_SIZE),
|
|
6299
|
+
["--pptx-selection-width"]: `${Math.max(element.width, chunk7DGKSEIU_js.MIN_ELEMENT_SIZE)}px`,
|
|
6300
|
+
["--pptx-selection-height"]: `${Math.max(element.height, chunk7DGKSEIU_js.MIN_ELEMENT_SIZE)}px`,
|
|
6300
6301
|
// Every slide element carries an explicit numeric `zIndex` (see
|
|
6301
6302
|
// `getContainerStyle`), so a sibling with no z-index at all paints
|
|
6302
6303
|
// at the CSS "z-index: 0" level regardless of DOM order: any
|
|
@@ -6308,7 +6309,7 @@ function SelectionHandleOverlay({
|
|
|
6308
6309
|
// (marquee z-50, connector overlay z-55/56) to match, well clear of
|
|
6309
6310
|
// any realistic per-slide element count.
|
|
6310
6311
|
zIndex: 58,
|
|
6311
|
-
transform:
|
|
6312
|
+
transform: chunk7DGKSEIU_js.getElementTransform(element),
|
|
6312
6313
|
transformOrigin: "center",
|
|
6313
6314
|
// Transparent everywhere a handle button is not, so a click that
|
|
6314
6315
|
// misses every handle still reaches the shape (or whatever is
|
|
@@ -6320,14 +6321,14 @@ function SelectionHandleOverlay({
|
|
|
6320
6321
|
onDoubleClick: (e) => onDoubleClick(element.id, e),
|
|
6321
6322
|
onContextMenu: (e) => onContextMenu(element.id, e),
|
|
6322
6323
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
6323
|
-
|
|
6324
|
+
chunkTVSTM5J5_js.ResizeHandles,
|
|
6324
6325
|
{
|
|
6325
6326
|
elementId: element.id,
|
|
6326
6327
|
adjustmentHandles,
|
|
6327
6328
|
onResizePointerDown,
|
|
6328
6329
|
onAdjustmentPointerDown,
|
|
6329
6330
|
rotation: element.rotation,
|
|
6330
|
-
nonRotationTransform:
|
|
6331
|
+
nonRotationTransform: chunk7DGKSEIU_js.getElementTransformWithoutRotation(element),
|
|
6331
6332
|
onRotate: allow.rotatable ? onRotate : void 0,
|
|
6332
6333
|
forcePointerEvents: true
|
|
6333
6334
|
}
|
|
@@ -7031,7 +7032,7 @@ function SlideCanvas(props) {
|
|
|
7031
7032
|
props.registerInlineEditReader
|
|
7032
7033
|
]
|
|
7033
7034
|
);
|
|
7034
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
7035
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkTVSTM5J5_js.InlineCollaborationContext.Provider, { value, children: /* @__PURE__ */ jsxRuntime.jsx(SlideCanvasContent, { ...props }) });
|
|
7035
7036
|
}
|
|
7036
7037
|
function SlideCanvasContent({
|
|
7037
7038
|
imagePaste,
|
|
@@ -7300,7 +7301,7 @@ function SlideCanvasContent({
|
|
|
7300
7301
|
onPointerMove: handleStagePointerMove,
|
|
7301
7302
|
onPointerUp: handleStagePointerUp,
|
|
7302
7303
|
children: [
|
|
7303
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7304
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTVSTM5J5_js.SlideBackgroundImageLayer, { slide: activeSlide }),
|
|
7304
7305
|
presentationKeyframesCss && /* @__PURE__ */ jsxRuntime.jsx("style", { children: presentationKeyframesCss }),
|
|
7305
7306
|
/* @__PURE__ */ jsxRuntime.jsx(GridOverlay, { canvasSize, gridSpacingPx, visible: showGrid }),
|
|
7306
7307
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -7312,7 +7313,7 @@ function SlideCanvasContent({
|
|
|
7312
7313
|
}
|
|
7313
7314
|
),
|
|
7314
7315
|
templateElements.map((element, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
7315
|
-
|
|
7316
|
+
chunkTVSTM5J5_js.ElementRenderer,
|
|
7316
7317
|
{
|
|
7317
7318
|
element,
|
|
7318
7319
|
activeSlide,
|
|
@@ -7334,7 +7335,7 @@ function SlideCanvasContent({
|
|
|
7334
7335
|
),
|
|
7335
7336
|
renderInk: false,
|
|
7336
7337
|
renderGroups: true,
|
|
7337
|
-
adjustmentHandles: isEditableCanvas && selectedElement?.id === element.id ?
|
|
7338
|
+
adjustmentHandles: isEditableCanvas && selectedElement?.id === element.id ? chunk7DGKSEIU_js.getShapeAdjustmentHandleDescriptors(element) : EMPTY_ADJUSTMENT_HANDLES,
|
|
7338
7339
|
onResizePointerDown: stableResizePointerDown,
|
|
7339
7340
|
onAdjustmentPointerDown: stableAdjustmentPointerDown,
|
|
7340
7341
|
onRotate: stableRotate,
|
|
@@ -7356,7 +7357,7 @@ function SlideCanvasContent({
|
|
|
7356
7357
|
`tpl-${element.id}`
|
|
7357
7358
|
)),
|
|
7358
7359
|
activeSlide?.elements.map((element, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
7359
|
-
|
|
7360
|
+
chunkTVSTM5J5_js.ElementRenderer,
|
|
7360
7361
|
{
|
|
7361
7362
|
element,
|
|
7362
7363
|
activeSlide,
|
|
@@ -7378,7 +7379,7 @@ function SlideCanvasContent({
|
|
|
7378
7379
|
),
|
|
7379
7380
|
renderInk: true,
|
|
7380
7381
|
renderGroups: true,
|
|
7381
|
-
adjustmentHandles: isEditableCanvas && selectedElement?.id === element.id ?
|
|
7382
|
+
adjustmentHandles: isEditableCanvas && selectedElement?.id === element.id ? chunk7DGKSEIU_js.getShapeAdjustmentHandleDescriptors(element) : EMPTY_ADJUSTMENT_HANDLES,
|
|
7382
7383
|
onResizePointerDown: stableResizePointerDown,
|
|
7383
7384
|
onAdjustmentPointerDown: stableAdjustmentPointerDown,
|
|
7384
7385
|
onRotate: stableRotate,
|
|
@@ -7422,7 +7423,7 @@ function SlideCanvasContent({
|
|
|
7422
7423
|
editingMember && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
7423
7424
|
/* @__PURE__ */ jsxRuntime.jsx("style", { children: `[data-element-id="${cssAttr(editingMember.parentId)}"] [data-element-id="${cssAttr(editingMember.member.id)}"]{visibility:hidden}` }),
|
|
7424
7425
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7425
|
-
|
|
7426
|
+
chunkTVSTM5J5_js.ElementRenderer,
|
|
7426
7427
|
{
|
|
7427
7428
|
element: editingMember.member,
|
|
7428
7429
|
activeSlide,
|
|
@@ -7457,11 +7458,11 @@ function SlideCanvasContent({
|
|
|
7457
7458
|
`group-member-edit-${editingMember.member.id}`
|
|
7458
7459
|
)
|
|
7459
7460
|
] }),
|
|
7460
|
-
selectedElement && selectedElement.id !== cropElement?.id && pptx.shouldShowElementHandles(isEditableCanvas, true, selectedElementIdSet.size) && !
|
|
7461
|
+
selectedElement && selectedElement.id !== cropElement?.id && pptx.shouldShowElementHandles(isEditableCanvas, true, selectedElementIdSet.size) && !chunk7DGKSEIU_js.isConnectorOrLineElement(selectedElement) && outlineAuthoring?.editPointsElementId !== selectedElement.id && /* @__PURE__ */ jsxRuntime.jsx(
|
|
7461
7462
|
SelectionHandleOverlay,
|
|
7462
7463
|
{
|
|
7463
7464
|
element: selectedElement,
|
|
7464
|
-
adjustmentHandles:
|
|
7465
|
+
adjustmentHandles: chunk7DGKSEIU_js.getShapeAdjustmentHandleDescriptors(selectedElement),
|
|
7465
7466
|
onResizePointerDown: stableResizePointerDown,
|
|
7466
7467
|
onAdjustmentPointerDown: stableAdjustmentPointerDown,
|
|
7467
7468
|
onRotate: stableRotate,
|
|
@@ -7575,7 +7576,7 @@ function LoadingState({ className }) {
|
|
|
7575
7576
|
role: "status",
|
|
7576
7577
|
"aria-live": "polite",
|
|
7577
7578
|
"aria-atomic": "true",
|
|
7578
|
-
className:
|
|
7579
|
+
className: chunk7DGKSEIU_js.cn(
|
|
7579
7580
|
"h-full w-full flex items-center justify-center text-muted-foreground",
|
|
7580
7581
|
className
|
|
7581
7582
|
),
|
|
@@ -7598,7 +7599,7 @@ function ErrorState({ className, error }) {
|
|
|
7598
7599
|
{
|
|
7599
7600
|
role: "alert",
|
|
7600
7601
|
"aria-live": "assertive",
|
|
7601
|
-
className:
|
|
7602
|
+
className: chunk7DGKSEIU_js.cn(
|
|
7602
7603
|
"h-full w-full flex items-center justify-center p-6 text-center text-red-400",
|
|
7603
7604
|
className
|
|
7604
7605
|
),
|
|
@@ -7629,7 +7630,7 @@ function ShortcutPanel({ isOpen, onClose }) {
|
|
|
7629
7630
|
}
|
|
7630
7631
|
)
|
|
7631
7632
|
] }),
|
|
7632
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "max-h-64 overflow-y-auto p-2 space-y-1", children:
|
|
7633
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "max-h-64 overflow-y-auto p-2 space-y-1", children: chunk7DGKSEIU_js.SHORTCUT_REFERENCE_ITEMS.map((shortcut) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
7633
7634
|
"div",
|
|
7634
7635
|
{
|
|
7635
7636
|
className: "flex items-center justify-between gap-3 rounded bg-muted/80 px-2 py-1.5",
|
|
@@ -7689,14 +7690,14 @@ function AccessibilityPanel({
|
|
|
7689
7690
|
"aria-label": t("pptx.accessibility.reduceMotion"),
|
|
7690
7691
|
"aria-checked": reducedMotion ?? false,
|
|
7691
7692
|
onClick: onToggleReducedMotion,
|
|
7692
|
-
className:
|
|
7693
|
+
className: chunk7DGKSEIU_js.cn(
|
|
7693
7694
|
"relative inline-flex h-5 w-9 items-center rounded-full transition-colors",
|
|
7694
7695
|
reducedMotion ? "bg-primary" : "bg-muted-foreground/30"
|
|
7695
7696
|
),
|
|
7696
7697
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
7697
7698
|
"span",
|
|
7698
7699
|
{
|
|
7699
|
-
className:
|
|
7700
|
+
className: chunk7DGKSEIU_js.cn(
|
|
7700
7701
|
"inline-block h-3.5 w-3.5 rounded-full bg-white transition-transform",
|
|
7701
7702
|
reducedMotion ? "translate-x-4" : "translate-x-0.5"
|
|
7702
7703
|
)
|
|
@@ -7715,7 +7716,7 @@ function AccessibilityPanel({
|
|
|
7715
7716
|
"div",
|
|
7716
7717
|
{
|
|
7717
7718
|
role: "listitem",
|
|
7718
|
-
className:
|
|
7719
|
+
className: chunk7DGKSEIU_js.cn(
|
|
7719
7720
|
"flex items-start gap-2 rounded px-2 py-1.5 text-xs",
|
|
7720
7721
|
/* Severity-based background and text colouring */
|
|
7721
7722
|
issue.severity === "error" ? "bg-red-900/30 text-red-300" : issue.severity === "warning" ? "bg-amber-900/30 text-amber-300" : "bg-muted/50 text-muted-foreground"
|
|
@@ -7875,7 +7876,7 @@ function ResizeHandle({
|
|
|
7875
7876
|
{
|
|
7876
7877
|
role: "separator",
|
|
7877
7878
|
"aria-orientation": direction,
|
|
7878
|
-
className:
|
|
7879
|
+
className: chunk7DGKSEIU_js.cn(
|
|
7879
7880
|
// Outer container: generous hit area for easy clicking.
|
|
7880
7881
|
// The visible indicator is rendered via the inner pseudo-element (::after).
|
|
7881
7882
|
"relative flex-shrink-0 z-20 group",
|
|
@@ -7886,7 +7887,7 @@ function ResizeHandle({
|
|
|
7886
7887
|
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
7887
7888
|
"div",
|
|
7888
7889
|
{
|
|
7889
|
-
className:
|
|
7890
|
+
className: chunk7DGKSEIU_js.cn(
|
|
7890
7891
|
"absolute transition-colors",
|
|
7891
7892
|
direction === "horizontal" ? "top-0 bottom-0 left-1/2 -translate-x-1/2 w-0.5 group-hover:w-1 group-hover:bg-primary/40 group-active:w-1 group-active:bg-primary/60" : "left-0 right-0 top-1/2 -translate-y-1/2 h-0.5 group-hover:h-1 group-hover:bg-primary/40 group-active:h-1 group-active:bg-primary/60"
|
|
7892
7893
|
)
|
|
@@ -7905,14 +7906,14 @@ function SlideThumbnailImpl({
|
|
|
7905
7906
|
}) {
|
|
7906
7907
|
const safeCanvasWidth = Math.max(canvasSize.width, 1);
|
|
7907
7908
|
const safeCanvasHeight = Math.max(canvasSize.height, 1);
|
|
7908
|
-
const width = previewWidth ??
|
|
7909
|
+
const width = previewWidth ?? chunk7DGKSEIU_js.SLIDE_NAV_THUMBNAIL_WIDTH;
|
|
7909
7910
|
const scale = width / safeCanvasWidth;
|
|
7910
7911
|
const previewHeight = pptx.editorThumbnailHeight(safeCanvasWidth, safeCanvasHeight, width);
|
|
7911
7912
|
const previewElements = pptx.buildPreviewElements(slide, templateElements);
|
|
7912
7913
|
const slideFieldContext = pptx.deriveSlideFieldContext(fieldContext, slide);
|
|
7913
7914
|
const { t } = reactI18next.useTranslation();
|
|
7914
7915
|
const transitionLabel = slide.transition ? (() => {
|
|
7915
|
-
const opt =
|
|
7916
|
+
const opt = chunk7DGKSEIU_js.SLIDE_TRANSITION_OPTIONS.find((o) => o.value === slide.transition?.type);
|
|
7916
7917
|
return opt ? t(opt.i18nKey) : slide.transition.type;
|
|
7917
7918
|
})() : void 0;
|
|
7918
7919
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -7938,7 +7939,7 @@ function SlideThumbnailImpl({
|
|
|
7938
7939
|
...pptx.deviceStrokeStageStyle(scale)
|
|
7939
7940
|
},
|
|
7940
7941
|
children: [
|
|
7941
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
7942
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTVSTM5J5_js.SlideBackgroundImageLayer, { slide }),
|
|
7942
7943
|
slide.transition && slide.transition.type !== "none" && slide.transition.type !== "cut" && /* @__PURE__ */ jsxRuntime.jsx(
|
|
7943
7944
|
"div",
|
|
7944
7945
|
{
|
|
@@ -7948,7 +7949,7 @@ function SlideThumbnailImpl({
|
|
|
7948
7949
|
}
|
|
7949
7950
|
),
|
|
7950
7951
|
previewElements.map((element, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
7951
|
-
|
|
7952
|
+
chunkTVSTM5J5_js.StaticElementRenderer,
|
|
7952
7953
|
{
|
|
7953
7954
|
element,
|
|
7954
7955
|
activeSlide: slide,
|
|
@@ -8504,7 +8505,7 @@ function SectionHeader({
|
|
|
8504
8505
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8505
8506
|
lu.LuChevronDown,
|
|
8506
8507
|
{
|
|
8507
|
-
className:
|
|
8508
|
+
className: chunk7DGKSEIU_js.cn(
|
|
8508
8509
|
"h-3 w-3 flex-shrink-0 transition-transform",
|
|
8509
8510
|
isCollapsed ? "-rotate-90" : "rotate-0"
|
|
8510
8511
|
)
|
|
@@ -8655,7 +8656,7 @@ function LazyThumbnailInner({
|
|
|
8655
8656
|
}
|
|
8656
8657
|
var LazyThumbnail = React99__default.default.memo(LazyThumbnailInner);
|
|
8657
8658
|
function declaredSectionFacts(groups, sectionId) {
|
|
8658
|
-
const declared = groups.filter((group) => group.id !==
|
|
8659
|
+
const declared = groups.filter((group) => group.id !== chunk7DGKSEIU_js.DEFAULT_SECTION_GROUP_ID && group.id !== chunk7DGKSEIU_js.UNGROUPED_SECTION_ID).map((group) => group.id);
|
|
8659
8660
|
return {
|
|
8660
8661
|
isDeclared: declared.includes(sectionId),
|
|
8661
8662
|
index: declared.indexOf(sectionId),
|
|
@@ -8740,7 +8741,7 @@ function SlideItemInner({
|
|
|
8740
8741
|
"data-pptx-chrome": "slide-row",
|
|
8741
8742
|
"aria-describedby": cue.labelId,
|
|
8742
8743
|
"data-pptx-slide-hidden": cue.marker,
|
|
8743
|
-
className:
|
|
8744
|
+
className: chunk7DGKSEIU_js.cn(
|
|
8744
8745
|
"group relative flex w-full items-center gap-1 cursor-pointer border-0 bg-transparent py-0.5 px-1 text-left transition-all",
|
|
8745
8746
|
isActive && "bg-accent/40 before:absolute before:left-0 before:top-1 before:bottom-1 before:w-[3px] before:bg-primary before:rounded-r",
|
|
8746
8747
|
isSelected && !isActive && "bg-accent/20 ring-1 ring-inset ring-primary/50",
|
|
@@ -8762,7 +8763,7 @@ function SlideItemInner({
|
|
|
8762
8763
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
8763
8764
|
"span",
|
|
8764
8765
|
{
|
|
8765
|
-
className:
|
|
8766
|
+
className: chunk7DGKSEIU_js.cn(
|
|
8766
8767
|
"text-[10px] tabular-nums text-right select-none w-full",
|
|
8767
8768
|
isActive ? "text-primary font-medium" : "text-muted-foreground"
|
|
8768
8769
|
),
|
|
@@ -8785,7 +8786,7 @@ function SlideItemInner({
|
|
|
8785
8786
|
/* @__PURE__ */ jsxRuntime.jsxs(
|
|
8786
8787
|
"div",
|
|
8787
8788
|
{
|
|
8788
|
-
className:
|
|
8789
|
+
className: chunk7DGKSEIU_js.cn(
|
|
8789
8790
|
"relative shrink-0 overflow-hidden border transition-colors bg-white",
|
|
8790
8791
|
isActive ? "border-primary/60" : "border-transparent group-hover:border-border/40"
|
|
8791
8792
|
),
|
|
@@ -8984,7 +8985,7 @@ function SlidesPaneSidebar({
|
|
|
8984
8985
|
tableStyleContext
|
|
8985
8986
|
}) {
|
|
8986
8987
|
const { t } = reactI18next.useTranslation();
|
|
8987
|
-
const collab =
|
|
8988
|
+
const collab = chunkTVSTM5J5_js.useCollaboration();
|
|
8988
8989
|
const slideRefs = React99.useRef(/* @__PURE__ */ new Map());
|
|
8989
8990
|
const renameInputRef = React99.useRef(null);
|
|
8990
8991
|
const slidePresenceMap = React99.useMemo(() => {
|
|
@@ -9009,7 +9010,7 @@ function SlidesPaneSidebar({
|
|
|
9009
9010
|
() => estimateSlideItemHeight(canvasSize.width, canvasSize.height, previewWidth),
|
|
9010
9011
|
[canvasSize.width, canvasSize.height, previewWidth]
|
|
9011
9012
|
);
|
|
9012
|
-
const showSectionHeaders = sectionGroups.some((group) => group.id !==
|
|
9013
|
+
const showSectionHeaders = sectionGroups.some((group) => group.id !== chunk7DGKSEIU_js.DEFAULT_SECTION_GROUP_ID);
|
|
9013
9014
|
const {
|
|
9014
9015
|
collapsedSections,
|
|
9015
9016
|
renamingSectionId,
|
|
@@ -9079,7 +9080,7 @@ function SlidesPaneSidebar({
|
|
|
9079
9080
|
[sectionGroups, showSectionHeaders, effectiveCollapsed]
|
|
9080
9081
|
);
|
|
9081
9082
|
const shouldVirtualize = slides.length >= VIRTUALIZATION_THRESHOLD;
|
|
9082
|
-
const { startIndex, endIndex, totalHeight, offsetY, scrollContainerRef, scrollToIndex } =
|
|
9083
|
+
const { startIndex, endIndex, totalHeight, offsetY, scrollContainerRef, scrollToIndex } = chunkTVSTM5J5_js.useVirtualizedSlides({
|
|
9083
9084
|
totalItems: shouldVirtualize ? flatItems.length : 0,
|
|
9084
9085
|
itemHeight: estimatedItemHeight
|
|
9085
9086
|
});
|
|
@@ -9336,7 +9337,7 @@ function HandoutMasterPanel({
|
|
|
9336
9337
|
{
|
|
9337
9338
|
type: "button",
|
|
9338
9339
|
"aria-pressed": slidesPerPage === count,
|
|
9339
|
-
className:
|
|
9340
|
+
className: chunk7DGKSEIU_js.cn(
|
|
9340
9341
|
"px-2 py-1.5 rounded text-[11px] font-medium transition-colors",
|
|
9341
9342
|
slidesPerPage === count ? "bg-primary text-white" : "bg-accent/50 text-muted-foreground hover:bg-accent/70 hover:text-foreground"
|
|
9342
9343
|
),
|
|
@@ -9454,7 +9455,7 @@ function SlideMastersList({
|
|
|
9454
9455
|
ref: isMasterActive ? activeRef : void 0,
|
|
9455
9456
|
"aria-pressed": isMasterActive,
|
|
9456
9457
|
"aria-label": master.name || t("pptx.master.master"),
|
|
9457
|
-
className:
|
|
9458
|
+
className: chunk7DGKSEIU_js.cn(
|
|
9458
9459
|
"group relative block w-full cursor-pointer rounded-lg border-2 p-1 text-left transition-all",
|
|
9459
9460
|
isMasterActive ? "border-amber-500 bg-amber-500/10" : "border-border bg-background/40 hover:border-border"
|
|
9460
9461
|
),
|
|
@@ -9471,7 +9472,7 @@ function SlideMastersList({
|
|
|
9471
9472
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-1 px-1", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
9472
9473
|
"span",
|
|
9473
9474
|
{
|
|
9474
|
-
className:
|
|
9475
|
+
className: chunk7DGKSEIU_js.cn(
|
|
9475
9476
|
"text-[10px] font-medium",
|
|
9476
9477
|
isMasterActive ? "text-amber-400" : "text-muted-foreground"
|
|
9477
9478
|
),
|
|
@@ -9490,7 +9491,7 @@ function SlideMastersList({
|
|
|
9490
9491
|
ref: isLayoutActive ? activeRef : void 0,
|
|
9491
9492
|
"aria-pressed": isLayoutActive,
|
|
9492
9493
|
"aria-label": layout.name || t("pptx.master.layout"),
|
|
9493
|
-
className:
|
|
9494
|
+
className: chunk7DGKSEIU_js.cn(
|
|
9494
9495
|
"group relative block w-full cursor-pointer rounded-md border-2 p-0.5 text-left transition-all",
|
|
9495
9496
|
isLayoutActive ? "border-primary bg-primary/10" : "border-border bg-background/40 hover:border-border"
|
|
9496
9497
|
),
|
|
@@ -9507,7 +9508,7 @@ function SlideMastersList({
|
|
|
9507
9508
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "mt-0.5 px-0.5", children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
9508
9509
|
"span",
|
|
9509
9510
|
{
|
|
9510
|
-
className:
|
|
9511
|
+
className: chunk7DGKSEIU_js.cn(
|
|
9511
9512
|
"text-[9px]",
|
|
9512
9513
|
isLayoutActive ? "text-primary" : "text-muted-foreground"
|
|
9513
9514
|
),
|
|
@@ -9599,7 +9600,7 @@ function MasterViewSidebar({
|
|
|
9599
9600
|
type: "button",
|
|
9600
9601
|
role: "tab",
|
|
9601
9602
|
"aria-selected": masterViewTab === tab.key,
|
|
9602
|
-
className:
|
|
9603
|
+
className: chunk7DGKSEIU_js.cn(
|
|
9603
9604
|
"flex-1 px-1 py-1.5 text-[10px] font-medium transition-colors border-b-2",
|
|
9604
9605
|
masterViewTab === tab.key ? "border-amber-500 text-amber-400" : "border-transparent text-muted-foreground hover:text-foreground"
|
|
9605
9606
|
),
|
|
@@ -10102,7 +10103,7 @@ function SectionBlock({
|
|
|
10102
10103
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10103
10104
|
lu.LuChevronDown,
|
|
10104
10105
|
{
|
|
10105
|
-
className:
|
|
10106
|
+
className: chunk7DGKSEIU_js.cn("h-3 w-3 transition-transform", collapsed ? "-rotate-90" : "rotate-0")
|
|
10106
10107
|
}
|
|
10107
10108
|
),
|
|
10108
10109
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "truncate text-left", children: section.label }),
|
|
@@ -10151,7 +10152,7 @@ function SlideCardImpl({
|
|
|
10151
10152
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
10152
10153
|
"div",
|
|
10153
10154
|
{
|
|
10154
|
-
className:
|
|
10155
|
+
className: chunk7DGKSEIU_js.cn(
|
|
10155
10156
|
"group relative cursor-pointer rounded-lg border-2 p-1 transition-all",
|
|
10156
10157
|
isDragTarget ? "border-primary bg-primary/20" : isSelected ? "border-primary bg-primary/10 ring-1 ring-primary/50" : isActive ? "border-primary/50 bg-primary/5" : "border-border bg-background/50 hover:border-border",
|
|
10157
10158
|
slide.hidden && "opacity-40"
|
|
@@ -10174,7 +10175,7 @@ function SlideCardImpl({
|
|
|
10174
10175
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
10175
10176
|
"span",
|
|
10176
10177
|
{
|
|
10177
|
-
className:
|
|
10178
|
+
className: chunk7DGKSEIU_js.cn(
|
|
10178
10179
|
"text-[11px] font-medium px-0.5",
|
|
10179
10180
|
isSelected ? "text-primary" : isActive ? "text-primary/70" : "text-muted-foreground"
|
|
10180
10181
|
),
|
|
@@ -10916,7 +10917,7 @@ function ReadingViewStage({
|
|
|
10916
10917
|
"div",
|
|
10917
10918
|
{
|
|
10918
10919
|
className: "absolute inset-0",
|
|
10919
|
-
style: { backgroundColor:
|
|
10920
|
+
style: { backgroundColor: chunk7DGKSEIU_js.normalizeHexColor(slide.backgroundColor, "#ffffff") }
|
|
10920
10921
|
}
|
|
10921
10922
|
),
|
|
10922
10923
|
slide.backgroundImage && /* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -10935,7 +10936,7 @@ function ReadingViewStage({
|
|
|
10935
10936
|
className: "absolute left-0 top-0 origin-top-left",
|
|
10936
10937
|
style: { width, height, transform: `scale(${scale})`, ...pptx.deviceStrokeStageStyle(scale) },
|
|
10937
10938
|
children: elements.map((element, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
10938
|
-
|
|
10939
|
+
chunkTVSTM5J5_js.StaticElementRenderer,
|
|
10939
10940
|
{
|
|
10940
10941
|
element,
|
|
10941
10942
|
activeSlide: slide,
|
|
@@ -11147,7 +11148,7 @@ function renderRichNotesSegments(segments) {
|
|
|
11147
11148
|
if (segment.style.fontFamily) {
|
|
11148
11149
|
style.fontFamily = segment.style.fontFamily;
|
|
11149
11150
|
}
|
|
11150
|
-
if (segment.style.hyperlink &&
|
|
11151
|
+
if (segment.style.hyperlink && chunk7DGKSEIU_js.isUrlSafe(segment.style.hyperlink)) {
|
|
11151
11152
|
const safeHref = segment.style.hyperlink;
|
|
11152
11153
|
style.color = "#4a9eff";
|
|
11153
11154
|
style.textDecoration = "underline";
|
|
@@ -11160,7 +11161,7 @@ function renderRichNotesSegments(segments) {
|
|
|
11160
11161
|
style,
|
|
11161
11162
|
onClick: (e) => {
|
|
11162
11163
|
e.preventDefault();
|
|
11163
|
-
|
|
11164
|
+
chunk7DGKSEIU_js.safeOpenUrl(safeHref);
|
|
11164
11165
|
},
|
|
11165
11166
|
children: segment.text
|
|
11166
11167
|
},
|
|
@@ -11509,7 +11510,7 @@ function useSlideNotes({
|
|
|
11509
11510
|
const href = target.getAttribute("data-hyperlink") || target.getAttribute("href");
|
|
11510
11511
|
if (href && (e.ctrlKey || e.metaKey)) {
|
|
11511
11512
|
e.preventDefault();
|
|
11512
|
-
|
|
11513
|
+
chunk7DGKSEIU_js.safeOpenUrl(href);
|
|
11513
11514
|
}
|
|
11514
11515
|
}, []);
|
|
11515
11516
|
return {
|
|
@@ -11590,7 +11591,7 @@ function SlideNotesPanel({
|
|
|
11590
11591
|
});
|
|
11591
11592
|
const hasNotes = draft.trim().length > 0;
|
|
11592
11593
|
const slideLabel = activeSlide ? t("pptx.notes.slideN", { n: activeSlide.slideNumber }) : t("pptx.notes.noSlide");
|
|
11593
|
-
const { dragY, handlers: dragHandlers } =
|
|
11594
|
+
const { dragY, handlers: dragHandlers } = chunkTVSTM5J5_js.useSheetDismissDrag(onToggle);
|
|
11594
11595
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
11595
11596
|
isExpanded && /* @__PURE__ */ jsxRuntime.jsx(
|
|
11596
11597
|
"button",
|
|
@@ -11606,7 +11607,7 @@ function SlideNotesPanel({
|
|
|
11606
11607
|
{
|
|
11607
11608
|
ref: rootRef,
|
|
11608
11609
|
"data-pptx-chrome": "notes",
|
|
11609
|
-
className:
|
|
11610
|
+
className: chunk7DGKSEIU_js.cn(
|
|
11610
11611
|
"flex flex-col border-t border-border/60 bg-background select-none",
|
|
11611
11612
|
// On mobile, hide the entire notes strip when collapsed: the
|
|
11612
11613
|
// MobileBottomBar's Notes button is the entry point instead.
|
|
@@ -11970,7 +11971,7 @@ function SlideDiffRow({
|
|
|
11970
11971
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
11971
11972
|
"div",
|
|
11972
11973
|
{
|
|
11973
|
-
className:
|
|
11974
|
+
className: chunk7DGKSEIU_js.cn(
|
|
11974
11975
|
"rounded-lg border transition-colors",
|
|
11975
11976
|
isResolved ? "border-border/60 bg-card/40 opacity-60" : "border-border bg-background/70"
|
|
11976
11977
|
),
|
|
@@ -11984,7 +11985,7 @@ function SlideDiffRow({
|
|
|
11984
11985
|
children: [
|
|
11985
11986
|
expanded ? /* @__PURE__ */ jsxRuntime.jsx(lu.LuChevronDown, { className: "w-3.5 h-3.5 text-muted-foreground flex-shrink-0" }) : /* @__PURE__ */ jsxRuntime.jsx(lu.LuChevronRight, { className: "w-3.5 h-3.5 text-muted-foreground flex-shrink-0" }),
|
|
11986
11987
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-xs text-foreground", children: t("pptx.compare.slideNumber", { number: slideNumber }) }),
|
|
11987
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className:
|
|
11988
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: chunk7DGKSEIU_js.cn("rounded-full px-2 py-0.5 text-[10px] font-medium", statusColor), children: statusLabel }),
|
|
11988
11989
|
diff.changes.length > 0 && /* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-[10px] text-muted-foreground", children: [
|
|
11989
11990
|
diff.changes.length,
|
|
11990
11991
|
" ",
|
|
@@ -11994,7 +11995,7 @@ function SlideDiffRow({
|
|
|
11994
11995
|
isResolved && /* @__PURE__ */ jsxRuntime.jsx(
|
|
11995
11996
|
"span",
|
|
11996
11997
|
{
|
|
11997
|
-
className:
|
|
11998
|
+
className: chunk7DGKSEIU_js.cn(
|
|
11998
11999
|
"text-[10px] font-medium",
|
|
11999
12000
|
accepted ? "text-green-400" : "text-muted-foreground"
|
|
12000
12001
|
),
|
|
@@ -12022,7 +12023,7 @@ function SlideDiffRow({
|
|
|
12022
12023
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
12023
12024
|
"div",
|
|
12024
12025
|
{
|
|
12025
|
-
className:
|
|
12026
|
+
className: chunk7DGKSEIU_js.cn(
|
|
12026
12027
|
"rounded border overflow-hidden",
|
|
12027
12028
|
diff.status === "added" ? "border-green-700/60" : diff.status === "changed" ? "border-amber-700/60" : "border-border"
|
|
12028
12029
|
),
|
|
@@ -12727,7 +12728,7 @@ function DocumentPropertiesDialog({
|
|
|
12727
12728
|
const handleClose = React99.useCallback(() => {
|
|
12728
12729
|
onClose();
|
|
12729
12730
|
}, [onClose]);
|
|
12730
|
-
const { panelStyle, handlers: dragHandlers } =
|
|
12731
|
+
const { panelStyle, handlers: dragHandlers } = chunkTVSTM5J5_js.useModalDismissDrag(handleClose);
|
|
12731
12732
|
if (!isOpen) {
|
|
12732
12733
|
return null;
|
|
12733
12734
|
}
|
|
@@ -13324,7 +13325,7 @@ function PresentationSubtitleBar({
|
|
|
13324
13325
|
}) {
|
|
13325
13326
|
const { t } = reactI18next.useTranslation();
|
|
13326
13327
|
const language = pptx.subtitleRecognitionLanguage(
|
|
13327
|
-
pptx.subtitleSettingsFromOptions(
|
|
13328
|
+
pptx.subtitleSettingsFromOptions(chunkTVSTM5J5_js.useViewerOptionsContext()),
|
|
13328
13329
|
typeof navigator === "undefined" ? "en-US" : navigator.language
|
|
13329
13330
|
);
|
|
13330
13331
|
const [captionText, setCaptionText] = React99.useState("");
|
|
@@ -13492,7 +13493,7 @@ function ScaledSlidePreviewImpl({
|
|
|
13492
13493
|
{
|
|
13493
13494
|
className: "absolute inset-0",
|
|
13494
13495
|
style: {
|
|
13495
|
-
backgroundColor:
|
|
13496
|
+
backgroundColor: chunk7DGKSEIU_js.normalizeHexColor(slide.backgroundColor, "#ffffff")
|
|
13496
13497
|
}
|
|
13497
13498
|
}
|
|
13498
13499
|
),
|
|
@@ -13518,7 +13519,7 @@ function ScaledSlidePreviewImpl({
|
|
|
13518
13519
|
...pptx.deviceStrokeStageStyle(scale)
|
|
13519
13520
|
},
|
|
13520
13521
|
children: previewElements.map((element, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
13521
|
-
|
|
13522
|
+
chunkTVSTM5J5_js.StaticElementRenderer,
|
|
13522
13523
|
{
|
|
13523
13524
|
element,
|
|
13524
13525
|
activeSlide: slide,
|
|
@@ -14235,7 +14236,7 @@ function getElementDisplayName(element, index) {
|
|
|
14235
14236
|
if (element.name && element.name.trim().length > 0) {
|
|
14236
14237
|
return element.name.trim();
|
|
14237
14238
|
}
|
|
14238
|
-
if ((0,
|
|
14239
|
+
if ((0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(element) && element.text && element.text.trim().length > 0) {
|
|
14239
14240
|
return element.text.trim().slice(0, 32);
|
|
14240
14241
|
}
|
|
14241
14242
|
const label = TYPE_LABELS[element.type] ?? "Object";
|
|
@@ -14408,7 +14409,7 @@ function SelectionPane({
|
|
|
14408
14409
|
setDragIndex(null);
|
|
14409
14410
|
setDragOverIndex(null);
|
|
14410
14411
|
},
|
|
14411
|
-
className:
|
|
14412
|
+
className: chunk7DGKSEIU_js.cn(
|
|
14412
14413
|
"flex items-center gap-1.5 px-2 py-1 text-xs cursor-pointer transition-colors",
|
|
14413
14414
|
isSelected ? "bg-primary/30 text-primary" : "hover:bg-muted text-foreground",
|
|
14414
14415
|
dragOverIndex === realIndex ? "border-t-2 border-primary" : ""
|
|
@@ -14462,13 +14463,13 @@ function SelectionPane({
|
|
|
14462
14463
|
}
|
|
14463
14464
|
var INPUT_CLS = "bg-muted border border-border rounded px-2 py-1 w-full text-[11px] max-md:min-h-[44px]!";
|
|
14464
14465
|
var SELECT_CLS = "bg-muted border border-border rounded px-2 py-1 w-full text-[11px] max-md:min-h-[44px]!";
|
|
14465
|
-
var ENTRANCE_PRESETS =
|
|
14466
|
+
var ENTRANCE_PRESETS = chunk7DGKSEIU_js.ANIMATION_PRESET_OPTIONS.filter(
|
|
14466
14467
|
(o) => o.value === "fadeIn" || o.value === "flyIn" || o.value === "zoomIn"
|
|
14467
14468
|
);
|
|
14468
|
-
var EXIT_PRESETS =
|
|
14469
|
+
var EXIT_PRESETS = chunk7DGKSEIU_js.ANIMATION_PRESET_OPTIONS.filter(
|
|
14469
14470
|
(o) => o.value === "fadeOut" || o.value === "flyOut" || o.value === "zoomOut"
|
|
14470
14471
|
);
|
|
14471
|
-
var EMPHASIS_PRESETS =
|
|
14472
|
+
var EMPHASIS_PRESETS = chunk7DGKSEIU_js.ANIMATION_PRESET_OPTIONS.filter(
|
|
14472
14473
|
(o) => o.value === "spin" || o.value === "pulse" || o.value === "colorWave" || o.value === "bounce" || o.value === "flash" || o.value === "growShrink" || o.value === "teeter"
|
|
14473
14474
|
);
|
|
14474
14475
|
var TIMING_CURVE_OPTIONS = [
|
|
@@ -14634,7 +14635,7 @@ function AnimationTimelineSection({
|
|
|
14634
14635
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "relative h-6 rounded bg-muted/50 border border-border overflow-hidden", children: timelineBarData.map((bar) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
14635
14636
|
"div",
|
|
14636
14637
|
{
|
|
14637
|
-
className:
|
|
14638
|
+
className: chunk7DGKSEIU_js.cn(
|
|
14638
14639
|
"absolute top-0.5 bottom-0.5 rounded-sm transition-colors",
|
|
14639
14640
|
animationTypeColor(bar.anim),
|
|
14640
14641
|
bar.anim.elementId === selectedElementId && "ring-1 ring-primary"
|
|
@@ -14663,7 +14664,7 @@ function AnimationTimelineSection({
|
|
|
14663
14664
|
onDragLeave: handleDragLeave,
|
|
14664
14665
|
onDrop: (e) => handleDrop(index, e),
|
|
14665
14666
|
title: t("pptx.animation.nativeEffectHint"),
|
|
14666
|
-
className:
|
|
14667
|
+
className: chunk7DGKSEIU_js.cn(
|
|
14667
14668
|
"flex items-center gap-1 px-1 py-0.5 rounded text-[10px] italic",
|
|
14668
14669
|
"bg-muted/20 text-muted-foreground/70",
|
|
14669
14670
|
isDragOver && "border-t-2 border-primary"
|
|
@@ -14702,7 +14703,7 @@ function AnimationTimelineSection({
|
|
|
14702
14703
|
onDragEnd: handleDragEnd,
|
|
14703
14704
|
onMouseEnter: () => handleAnimationHover(anim),
|
|
14704
14705
|
onMouseLeave: handleAnimationHoverEnd,
|
|
14705
|
-
className:
|
|
14706
|
+
className: chunk7DGKSEIU_js.cn(
|
|
14706
14707
|
"flex items-center gap-1 px-1 py-0.5 rounded text-[10px] cursor-grab transition-colors",
|
|
14707
14708
|
isSelected ? "bg-primary/30 text-primary" : "bg-muted/50 text-muted-foreground",
|
|
14708
14709
|
isDragging && "opacity-40",
|
|
@@ -14834,7 +14835,7 @@ function EffectSoundRow({
|
|
|
14834
14835
|
}
|
|
14835
14836
|
const asset = pptx.getEffectSoundAsset(soundState.catalogueId);
|
|
14836
14837
|
if (asset) {
|
|
14837
|
-
|
|
14838
|
+
chunkTVSTM5J5_js.playAnimationSound(asset.dataUrl);
|
|
14838
14839
|
}
|
|
14839
14840
|
};
|
|
14840
14841
|
return /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex flex-col gap-1", children: [
|
|
@@ -15009,7 +15010,7 @@ function useAnimationPreview({
|
|
|
15009
15010
|
}) {
|
|
15010
15011
|
const handleAnimationHover = React99.useCallback((anim) => {
|
|
15011
15012
|
if (anim.motionPath) {
|
|
15012
|
-
|
|
15013
|
+
chunk7DGKSEIU_js.startMotionPathPreview(anim.elementId, anim.motionPath, {
|
|
15013
15014
|
durationMs: anim.durationMs,
|
|
15014
15015
|
delayMs: anim.delayMs,
|
|
15015
15016
|
timingCurve: anim.timingCurve
|
|
@@ -15020,19 +15021,19 @@ function useAnimationPreview({
|
|
|
15020
15021
|
if (!preset || preset === "none") {
|
|
15021
15022
|
return;
|
|
15022
15023
|
}
|
|
15023
|
-
|
|
15024
|
+
chunk7DGKSEIU_js.startPreviewAnimation(anim.elementId, preset, {
|
|
15024
15025
|
direction: anim.direction,
|
|
15025
15026
|
durationMs: anim.durationMs ?? 500,
|
|
15026
15027
|
timingCurve: anim.timingCurve
|
|
15027
15028
|
});
|
|
15028
15029
|
}, []);
|
|
15029
|
-
const handleAnimationHoverEnd = React99.useCallback(() =>
|
|
15030
|
+
const handleAnimationHoverEnd = React99.useCallback(() => chunk7DGKSEIU_js.stopPreviewAnimation(), []);
|
|
15030
15031
|
const handlePreviewClick = React99.useCallback(() => {
|
|
15031
15032
|
if (!selectedElementAnimation) {
|
|
15032
15033
|
return;
|
|
15033
15034
|
}
|
|
15034
15035
|
if (selectedElementAnimation.motionPath) {
|
|
15035
|
-
|
|
15036
|
+
chunk7DGKSEIU_js.startMotionPathPreview(selectedElementId, selectedElementAnimation.motionPath, {
|
|
15036
15037
|
durationMs: selectedElementAnimation.durationMs,
|
|
15037
15038
|
delayMs: selectedElementAnimation.delayMs,
|
|
15038
15039
|
timingCurve: selectedElementAnimation.timingCurve
|
|
@@ -15043,7 +15044,7 @@ function useAnimationPreview({
|
|
|
15043
15044
|
if (!preset || preset === "none") {
|
|
15044
15045
|
return;
|
|
15045
15046
|
}
|
|
15046
|
-
|
|
15047
|
+
chunk7DGKSEIU_js.startPreviewAnimation(selectedElementId, preset, {
|
|
15047
15048
|
direction: selectedElementAnimation.direction,
|
|
15048
15049
|
durationMs: selectedElementAnimation.durationMs ?? 500,
|
|
15049
15050
|
timingCurve: selectedElementAnimation.timingCurve
|
|
@@ -15277,8 +15278,8 @@ function useAnimationHandlers({
|
|
|
15277
15278
|
if (!el) {
|
|
15278
15279
|
return anim.elementId.slice(0, 8);
|
|
15279
15280
|
}
|
|
15280
|
-
const text = (0,
|
|
15281
|
-
return text ||
|
|
15281
|
+
const text = (0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(el) ? el.text : void 0;
|
|
15282
|
+
return text || chunk7DGKSEIU_js.getElementLabel(el);
|
|
15282
15283
|
},
|
|
15283
15284
|
[activeSlide.elements]
|
|
15284
15285
|
);
|
|
@@ -15288,8 +15289,8 @@ function useAnimationHandlers({
|
|
|
15288
15289
|
if (!el) {
|
|
15289
15290
|
return id.slice(0, 8);
|
|
15290
15291
|
}
|
|
15291
|
-
const text = (0,
|
|
15292
|
-
return text ||
|
|
15292
|
+
const text = (0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(el) ? el.text : void 0;
|
|
15293
|
+
return text || chunk7DGKSEIU_js.getElementLabel(el);
|
|
15293
15294
|
}).join(", "),
|
|
15294
15295
|
[activeSlide.elements]
|
|
15295
15296
|
);
|
|
@@ -15346,7 +15347,7 @@ function AnimationPanel({
|
|
|
15346
15347
|
onUpdateSlide
|
|
15347
15348
|
}) {
|
|
15348
15349
|
const { t } = reactI18next.useTranslation();
|
|
15349
|
-
const { viewportWidth } =
|
|
15350
|
+
const { viewportWidth } = chunkTVSTM5J5_js.useIsMobile();
|
|
15350
15351
|
const directionBtnPx = Math.max(28, pptx.getDensePanelTouchTargetPx(viewportWidth));
|
|
15351
15352
|
const fieldStyle = { minHeight: pptx.getDensePanelTouchTargetPx(viewportWidth) };
|
|
15352
15353
|
const handlers = useAnimationHandlers({
|
|
@@ -15474,7 +15475,7 @@ function AnimationPanel({
|
|
|
15474
15475
|
type: "button",
|
|
15475
15476
|
disabled: !canEdit,
|
|
15476
15477
|
style: { minWidth: directionBtnPx, minHeight: directionBtnPx },
|
|
15477
|
-
className:
|
|
15478
|
+
className: chunk7DGKSEIU_js.cn(
|
|
15478
15479
|
"flex items-center justify-center rounded border transition-colors",
|
|
15479
15480
|
isActive ? "border-primary bg-primary/20 text-primary" : "border-border bg-muted text-muted-foreground hover:bg-accent"
|
|
15480
15481
|
),
|
|
@@ -15552,7 +15553,7 @@ function AnimationPanel({
|
|
|
15552
15553
|
style: fieldStyle,
|
|
15553
15554
|
children: [
|
|
15554
15555
|
/* @__PURE__ */ jsxRuntime.jsx("option", { value: "", children: t("pptx.animation.trigger.selectShape") }),
|
|
15555
|
-
activeSlide.elements.filter((el) => el.id !== selectedElement.id).map((el) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: el.id, children:
|
|
15556
|
+
activeSlide.elements.filter((el) => el.id !== selectedElement.id).map((el) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: el.id, children: chunk7DGKSEIU_js.getElementLabel(el) }, el.id))
|
|
15556
15557
|
]
|
|
15557
15558
|
}
|
|
15558
15559
|
)
|
|
@@ -15700,7 +15701,7 @@ function ActionTargetFields({
|
|
|
15700
15701
|
type: "text",
|
|
15701
15702
|
disabled: !canEdit,
|
|
15702
15703
|
"aria-label": t(urlLabelKey),
|
|
15703
|
-
className:
|
|
15704
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "w-full"),
|
|
15704
15705
|
placeholder: "https://...",
|
|
15705
15706
|
value: url ?? "",
|
|
15706
15707
|
onChange: (e) => onChange({ url: e.target.value })
|
|
@@ -15714,7 +15715,7 @@ function ActionTargetFields({
|
|
|
15714
15715
|
type: "number",
|
|
15715
15716
|
disabled: !canEdit,
|
|
15716
15717
|
"aria-label": t("pptx.action.gotoSlide"),
|
|
15717
|
-
className:
|
|
15718
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "w-full"),
|
|
15718
15719
|
placeholder: t("pptx.action.slideNumberPlaceholder"),
|
|
15719
15720
|
min: 1,
|
|
15720
15721
|
max: slideCount,
|
|
@@ -15736,7 +15737,7 @@ function ActionTargetFields({
|
|
|
15736
15737
|
"data-testid": "pptx-action-custom-show",
|
|
15737
15738
|
disabled: !canEdit,
|
|
15738
15739
|
"aria-label": t("pptx.hyperlink.customShowLabel"),
|
|
15739
|
-
className:
|
|
15740
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "w-full"),
|
|
15740
15741
|
value: customShowId ?? "",
|
|
15741
15742
|
onChange: (e) => onChange({ customShowId: e.target.value, returnAfter }),
|
|
15742
15743
|
children: [
|
|
@@ -15769,11 +15770,11 @@ function ActionSettingsPanel({
|
|
|
15769
15770
|
onUpdateElement
|
|
15770
15771
|
}) {
|
|
15771
15772
|
const { t } = reactI18next.useTranslation();
|
|
15772
|
-
const clickAction = selectedElement.actionClick ? (0,
|
|
15773
|
-
const hoverAction = selectedElement.actionHover ? (0,
|
|
15773
|
+
const clickAction = selectedElement.actionClick ? (0, chunk7DGKSEIU_js.dist_exports.pptxActionToElementAction)(selectedElement.actionClick, "click") : void 0;
|
|
15774
|
+
const hoverAction = selectedElement.actionHover ? (0, chunk7DGKSEIU_js.dist_exports.pptxActionToElementAction)(selectedElement.actionHover, "hover") : void 0;
|
|
15774
15775
|
const updateAction = (trigger, type, patch) => {
|
|
15775
15776
|
const ea = { trigger, type, ...patch };
|
|
15776
|
-
const pa = (0,
|
|
15777
|
+
const pa = (0, chunk7DGKSEIU_js.dist_exports.elementActionToPptxAction)(ea);
|
|
15777
15778
|
if (trigger === "click") {
|
|
15778
15779
|
onUpdateElement({ actionClick: pa });
|
|
15779
15780
|
} else {
|
|
@@ -15858,7 +15859,7 @@ function ActionTriggerSection({
|
|
|
15858
15859
|
{
|
|
15859
15860
|
disabled: !canEdit,
|
|
15860
15861
|
"aria-label": label,
|
|
15861
|
-
className:
|
|
15862
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "w-full"),
|
|
15862
15863
|
value: effectiveType,
|
|
15863
15864
|
onChange: (e) => changeType(e.target.value),
|
|
15864
15865
|
children: pptx.ELEMENT_ACTION_TYPE_OPTIONS.map((o) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: o.value, children: t(o.labelKey) }, o.value))
|
|
@@ -16246,7 +16247,7 @@ function ChartDataGrid({
|
|
|
16246
16247
|
}) {
|
|
16247
16248
|
const { t } = reactI18next.useTranslation();
|
|
16248
16249
|
const highlightRef = React99.useRef(null);
|
|
16249
|
-
const { viewportWidth } =
|
|
16250
|
+
const { viewportWidth } = chunkTVSTM5J5_js.useIsMobile();
|
|
16250
16251
|
const gridPlan = pptx.getDenseGridLayoutPlan(viewportWidth);
|
|
16251
16252
|
const touchTargetPx = pptx.getDensePanelTouchTargetPx(viewportWidth);
|
|
16252
16253
|
const rowHeaderClass = gridPlan.stickyFirstColumn ? "sticky left-0 z-10 bg-card" : "";
|
|
@@ -17603,8 +17604,8 @@ function ChartUserShapeOptions({
|
|
|
17603
17604
|
}
|
|
17604
17605
|
function ChartDataPanel({ selectedElement, canEdit, onUpdateElement }) {
|
|
17605
17606
|
const chartData = selectedElement.chartData;
|
|
17606
|
-
const followDataPoint =
|
|
17607
|
-
const { selection: partSelection } =
|
|
17607
|
+
const followDataPoint = chunkTVSTM5J5_js.useViewerOptionsContext().advanced.chartPropertiesFollowDataPoint;
|
|
17608
|
+
const { selection: partSelection } = chunkTVSTM5J5_js.useChartPartSelection();
|
|
17608
17609
|
const canvasPart = partSelection?.elementId === selectedElement.id ? partSelection.part : null;
|
|
17609
17610
|
const title = chartData?.title;
|
|
17610
17611
|
const chartType = chartData?.chartType;
|
|
@@ -17818,40 +17819,40 @@ function ChartDataPanel({ selectedElement, canEdit, onUpdateElement }) {
|
|
|
17818
17819
|
[chartData, selectedElement, replaceChartData]
|
|
17819
17820
|
);
|
|
17820
17821
|
const setAxisLogScale = React99.useCallback(
|
|
17821
|
-
(axisType, opts) => applyChartOp((el) => (0,
|
|
17822
|
+
(axisType, opts) => applyChartOp((el) => (0, chunk7DGKSEIU_js.dist_exports.setChartAxisLogScale)(el, axisType, opts)),
|
|
17822
17823
|
[applyChartOp]
|
|
17823
17824
|
);
|
|
17824
17825
|
const setAxisTitleStyle = React99.useCallback(
|
|
17825
|
-
(axisType, edit) => applyChartOp((el) => (0,
|
|
17826
|
+
(axisType, edit) => applyChartOp((el) => (0, chunk7DGKSEIU_js.dist_exports.setChartAxisTitleStyle)(el, axisType, edit)),
|
|
17826
17827
|
[applyChartOp]
|
|
17827
17828
|
);
|
|
17828
17829
|
const setGridlineStyle = React99.useCallback(
|
|
17829
|
-
(axisType, which, edit) => applyChartOp((el) => (0,
|
|
17830
|
+
(axisType, which, edit) => applyChartOp((el) => (0, chunk7DGKSEIU_js.dist_exports.setChartAxisGridlineStyle)(el, axisType, which, edit)),
|
|
17830
17831
|
[applyChartOp]
|
|
17831
17832
|
);
|
|
17832
17833
|
const setSeriesMarker = React99.useCallback(
|
|
17833
|
-
(index, marker) => applyChartOp((el) => (0,
|
|
17834
|
+
(index, marker) => applyChartOp((el) => (0, chunk7DGKSEIU_js.dist_exports.setChartSeriesMarker)(el, index, marker)),
|
|
17834
17835
|
[applyChartOp]
|
|
17835
17836
|
);
|
|
17836
17837
|
const setSeriesType = React99.useCallback(
|
|
17837
|
-
(index, seriesType) => applyChartOp((el) => (0,
|
|
17838
|
+
(index, seriesType) => applyChartOp((el) => (0, chunk7DGKSEIU_js.dist_exports.setChartSeriesChartType)(el, index, seriesType)),
|
|
17838
17839
|
[applyChartOp]
|
|
17839
17840
|
);
|
|
17840
17841
|
const setPointFill = React99.useCallback(
|
|
17841
|
-
(seriesIndex, pointIndex, color) => applyChartOp((el) => (0,
|
|
17842
|
+
(seriesIndex, pointIndex, color) => applyChartOp((el) => (0, chunk7DGKSEIU_js.dist_exports.setChartDataPointFill)(el, seriesIndex, pointIndex, color)),
|
|
17842
17843
|
[applyChartOp]
|
|
17843
17844
|
);
|
|
17844
17845
|
const setPointExplosion = React99.useCallback(
|
|
17845
|
-
(seriesIndex, pointIndex, explosion) => applyChartOp((el) => (0,
|
|
17846
|
+
(seriesIndex, pointIndex, explosion) => applyChartOp((el) => (0, chunk7DGKSEIU_js.dist_exports.setChartDataPointExplosion)(el, seriesIndex, pointIndex, explosion)),
|
|
17846
17847
|
[applyChartOp]
|
|
17847
17848
|
);
|
|
17848
17849
|
const setPointMarker = React99.useCallback(
|
|
17849
|
-
(seriesIndex, pointIndex, marker) => applyChartOp((el) => (0,
|
|
17850
|
+
(seriesIndex, pointIndex, marker) => applyChartOp((el) => (0, chunk7DGKSEIU_js.dist_exports.setChartDataPointMarker)(el, seriesIndex, pointIndex, marker)),
|
|
17850
17851
|
[applyChartOp]
|
|
17851
17852
|
);
|
|
17852
17853
|
const setPointLabel = React99.useCallback(
|
|
17853
17854
|
(seriesIndex, pointIndex, text) => applyChartOp(
|
|
17854
|
-
(el) => (0,
|
|
17855
|
+
(el) => (0, chunk7DGKSEIU_js.dist_exports.setChartDataPointLabel)(el, seriesIndex, pointIndex, text !== null ? { text } : null)
|
|
17855
17856
|
),
|
|
17856
17857
|
[applyChartOp]
|
|
17857
17858
|
);
|
|
@@ -18119,17 +18120,17 @@ function OleEditorDialog({
|
|
|
18119
18120
|
const kind = descriptor.contentTab.kind;
|
|
18120
18121
|
const load = async () => {
|
|
18121
18122
|
if (kind === "sheet") {
|
|
18122
|
-
const value = await (0,
|
|
18123
|
+
const value = await (0, chunk7DGKSEIU_js.dist_exports.getOleSheetGrid)(element);
|
|
18123
18124
|
if (!cancelled) {
|
|
18124
18125
|
setGrid(value);
|
|
18125
18126
|
}
|
|
18126
18127
|
} else if (kind === "document") {
|
|
18127
|
-
const value = await (0,
|
|
18128
|
+
const value = await (0, chunk7DGKSEIU_js.dist_exports.getOleDocumentParagraphs)(element);
|
|
18128
18129
|
if (!cancelled) {
|
|
18129
18130
|
setParagraphs(value);
|
|
18130
18131
|
}
|
|
18131
18132
|
} else if (kind === "deck") {
|
|
18132
|
-
const value = await (0,
|
|
18133
|
+
const value = await (0, chunk7DGKSEIU_js.dist_exports.getOleNestedDeckDetail)(element);
|
|
18133
18134
|
if (!cancelled) {
|
|
18134
18135
|
setDeckSlides(value);
|
|
18135
18136
|
}
|
|
@@ -18155,9 +18156,9 @@ function OleEditorDialog({
|
|
|
18155
18156
|
const handleCellEdit = React99.useCallback(
|
|
18156
18157
|
async (row, col, value) => {
|
|
18157
18158
|
try {
|
|
18158
|
-
const updated = await (0,
|
|
18159
|
+
const updated = await (0, chunk7DGKSEIU_js.dist_exports.applyOleSheetCellEdit)(element, { row, col, value });
|
|
18159
18160
|
commit(updated);
|
|
18160
|
-
const refreshed = await (0,
|
|
18161
|
+
const refreshed = await (0, chunk7DGKSEIU_js.dist_exports.getOleSheetGrid)(updated);
|
|
18161
18162
|
if (mountedRef.current) {
|
|
18162
18163
|
setGrid(refreshed);
|
|
18163
18164
|
}
|
|
@@ -18172,9 +18173,9 @@ function OleEditorDialog({
|
|
|
18172
18173
|
const handleParagraphEdit = React99.useCallback(
|
|
18173
18174
|
async (index, text) => {
|
|
18174
18175
|
try {
|
|
18175
|
-
const updated = await (0,
|
|
18176
|
+
const updated = await (0, chunk7DGKSEIU_js.dist_exports.applyOleDocumentParagraphEdit)(element, index, text);
|
|
18176
18177
|
commit(updated);
|
|
18177
|
-
const refreshed = await (0,
|
|
18178
|
+
const refreshed = await (0, chunk7DGKSEIU_js.dist_exports.getOleDocumentParagraphs)(updated);
|
|
18178
18179
|
if (mountedRef.current) {
|
|
18179
18180
|
setParagraphs(refreshed);
|
|
18180
18181
|
}
|
|
@@ -18189,14 +18190,14 @@ function OleEditorDialog({
|
|
|
18189
18190
|
const handleDeckElementEdit = React99.useCallback(
|
|
18190
18191
|
async (slideIndex, deckElementId, text) => {
|
|
18191
18192
|
try {
|
|
18192
|
-
const updated = await (0,
|
|
18193
|
+
const updated = await (0, chunk7DGKSEIU_js.dist_exports.applyOleNestedDeckElementTextEdit)(
|
|
18193
18194
|
element,
|
|
18194
18195
|
slideIndex,
|
|
18195
18196
|
deckElementId,
|
|
18196
18197
|
text
|
|
18197
18198
|
);
|
|
18198
18199
|
commit(updated);
|
|
18199
|
-
const refreshed = await (0,
|
|
18200
|
+
const refreshed = await (0, chunk7DGKSEIU_js.dist_exports.getOleNestedDeckDetail)(updated);
|
|
18200
18201
|
if (mountedRef.current) {
|
|
18201
18202
|
setDeckSlides(refreshed);
|
|
18202
18203
|
}
|
|
@@ -18212,7 +18213,7 @@ function OleEditorDialog({
|
|
|
18212
18213
|
async (file) => {
|
|
18213
18214
|
try {
|
|
18214
18215
|
const bytes = new Uint8Array(await file.arrayBuffer());
|
|
18215
|
-
const updated = await (0,
|
|
18216
|
+
const updated = await (0, chunk7DGKSEIU_js.dist_exports.replaceOleFile)(element, bytes, file.name);
|
|
18216
18217
|
commit(updated);
|
|
18217
18218
|
if (mountedRef.current) {
|
|
18218
18219
|
onClose();
|
|
@@ -18361,7 +18362,7 @@ function ConnectorArrowsSection({
|
|
|
18361
18362
|
},
|
|
18362
18363
|
disabled: !canEdit,
|
|
18363
18364
|
className: SELECT_CLS2,
|
|
18364
|
-
children:
|
|
18365
|
+
children: chunk7DGKSEIU_js.CONNECTOR_ARROW_OPTIONS.map((o) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: o.value, children: t(o.i18nKey) }, o.value))
|
|
18365
18366
|
}
|
|
18366
18367
|
)
|
|
18367
18368
|
] }, end);
|
|
@@ -18385,7 +18386,7 @@ function ConnectorArrowsSection({
|
|
|
18385
18386
|
},
|
|
18386
18387
|
disabled: !canEdit,
|
|
18387
18388
|
className: SELECT_CLS2,
|
|
18388
|
-
children:
|
|
18389
|
+
children: chunk7DGKSEIU_js.ARROW_SIZE_OPTIONS.map((o) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: o.value, children: t(o.i18nKey) }, o.value))
|
|
18389
18390
|
}
|
|
18390
18391
|
)
|
|
18391
18392
|
] }),
|
|
@@ -18404,7 +18405,7 @@ function ConnectorArrowsSection({
|
|
|
18404
18405
|
},
|
|
18405
18406
|
disabled: !canEdit,
|
|
18406
18407
|
className: SELECT_CLS2,
|
|
18407
|
-
children:
|
|
18408
|
+
children: chunk7DGKSEIU_js.ARROW_SIZE_OPTIONS.map((o) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: o.value, children: t(o.i18nKey) }, o.value))
|
|
18408
18409
|
}
|
|
18409
18410
|
)
|
|
18410
18411
|
] })
|
|
@@ -18484,7 +18485,7 @@ function OlePropertiesPanel({
|
|
|
18484
18485
|
] }),
|
|
18485
18486
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-2", children: [
|
|
18486
18487
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: t("pptx.ole.type") }),
|
|
18487
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground truncate", children: (0,
|
|
18488
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-foreground truncate", children: (0, chunk7DGKSEIU_js.dist_exports.getOleObjectTypeLabel)(ole.oleObjectType) })
|
|
18488
18489
|
] }),
|
|
18489
18490
|
ole.fileName && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center justify-between gap-2", children: [
|
|
18490
18491
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: t("pptx.ole.fileName") }),
|
|
@@ -18495,7 +18496,7 @@ function OlePropertiesPanel({
|
|
|
18495
18496
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
18496
18497
|
"span",
|
|
18497
18498
|
{
|
|
18498
|
-
className:
|
|
18499
|
+
className: chunk7DGKSEIU_js.cn(
|
|
18499
18500
|
"inline-flex items-center rounded-full px-2 py-0.5 text-[10px] font-medium",
|
|
18500
18501
|
ole.isLinked ? "bg-blue-500/20 text-blue-400" : "bg-green-500/20 text-green-400"
|
|
18501
18502
|
),
|
|
@@ -18563,7 +18564,7 @@ function LayerOrderButtons({
|
|
|
18563
18564
|
"button",
|
|
18564
18565
|
{
|
|
18565
18566
|
type: "button",
|
|
18566
|
-
className:
|
|
18567
|
+
className: chunk7DGKSEIU_js.cn("flex-1", BTN2),
|
|
18567
18568
|
disabled: !canEdit,
|
|
18568
18569
|
onClick: () => onMoveLayer("forward"),
|
|
18569
18570
|
children: "\u2191 Forward"
|
|
@@ -18573,7 +18574,7 @@ function LayerOrderButtons({
|
|
|
18573
18574
|
"button",
|
|
18574
18575
|
{
|
|
18575
18576
|
type: "button",
|
|
18576
|
-
className:
|
|
18577
|
+
className: chunk7DGKSEIU_js.cn("flex-1", BTN2),
|
|
18577
18578
|
disabled: !canEdit,
|
|
18578
18579
|
onClick: () => onMoveLayer("backward"),
|
|
18579
18580
|
children: "\u2193 Backward"
|
|
@@ -18597,7 +18598,7 @@ function ArtisticEffectsGallery({
|
|
|
18597
18598
|
{
|
|
18598
18599
|
type: "button",
|
|
18599
18600
|
disabled: !canEdit,
|
|
18600
|
-
className:
|
|
18601
|
+
className: chunk7DGKSEIU_js.cn(
|
|
18601
18602
|
"flex flex-col items-center gap-0.5 rounded border p-0.5 hover:bg-accent/50",
|
|
18602
18603
|
isActive ? "border-primary bg-primary/10" : "border-border"
|
|
18603
18604
|
),
|
|
@@ -18659,7 +18660,7 @@ function ColorChangeSection({
|
|
|
18659
18660
|
DebouncedColorInput,
|
|
18660
18661
|
{
|
|
18661
18662
|
disabled: !canEdit,
|
|
18662
|
-
value:
|
|
18663
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(cc.clrFrom, "#ffffff"),
|
|
18663
18664
|
className: "h-6 w-8 rounded border border-border bg-transparent cursor-pointer",
|
|
18664
18665
|
onCommit: (hex) => updateEffects({
|
|
18665
18666
|
clrChange: {
|
|
@@ -18677,7 +18678,7 @@ function ColorChangeSection({
|
|
|
18677
18678
|
DebouncedColorInput,
|
|
18678
18679
|
{
|
|
18679
18680
|
disabled: !canEdit || Boolean(cc.clrToTransparent),
|
|
18680
|
-
value:
|
|
18681
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(cc.clrTo, "#000000"),
|
|
18681
18682
|
className: "h-6 w-8 rounded border border-border bg-transparent cursor-pointer",
|
|
18682
18683
|
onCommit: (hex) => updateEffects({
|
|
18683
18684
|
clrChange: {
|
|
@@ -18737,7 +18738,7 @@ function ColorWashSection({
|
|
|
18737
18738
|
DebouncedColorInput,
|
|
18738
18739
|
{
|
|
18739
18740
|
disabled: !canEdit,
|
|
18740
|
-
value:
|
|
18741
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(wash.color, "#0066cc"),
|
|
18741
18742
|
className: "h-6 w-8 rounded border border-border bg-transparent cursor-pointer",
|
|
18742
18743
|
onCommit: (hex) => updateEffects({
|
|
18743
18744
|
colorWash: { color: hex, opacity: wash.opacity ?? 40 }
|
|
@@ -18840,8 +18841,8 @@ function DuotonePanel({
|
|
|
18840
18841
|
}
|
|
18841
18842
|
});
|
|
18842
18843
|
}, [effects, onUpdateElement]);
|
|
18843
|
-
const shadowColor =
|
|
18844
|
-
const highlightColor =
|
|
18844
|
+
const shadowColor = chunk7DGKSEIU_js.normalizeHexColor(effects?.duotone?.color1, "#000000");
|
|
18845
|
+
const highlightColor = chunk7DGKSEIU_js.normalizeHexColor(effects?.duotone?.color2, "#ffffff");
|
|
18845
18846
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-2 text-[11px]", children: [
|
|
18846
18847
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-muted-foreground font-medium", children: t("pptx.image.duotone") }),
|
|
18847
18848
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-3", children: [
|
|
@@ -18872,7 +18873,7 @@ function DuotonePanel({
|
|
|
18872
18873
|
] }),
|
|
18873
18874
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1", children: [
|
|
18874
18875
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-muted-foreground text-[10px]", children: t("pptx.image.duotonePresets") }),
|
|
18875
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid grid-cols-4 gap-1", children:
|
|
18876
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid grid-cols-4 gap-1", children: chunkTVSTM5J5_js.DUOTONE_PRESETS.map((preset) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
18876
18877
|
"button",
|
|
18877
18878
|
{
|
|
18878
18879
|
type: "button",
|
|
@@ -19010,7 +19011,7 @@ function ImageCropSection({
|
|
|
19010
19011
|
onUpdateElement
|
|
19011
19012
|
}) {
|
|
19012
19013
|
const { t } = reactI18next.useTranslation();
|
|
19013
|
-
if (!(0,
|
|
19014
|
+
if (!(0, chunk7DGKSEIU_js.dist_exports.isImageLikeElement)(selectedElement)) {
|
|
19014
19015
|
return null;
|
|
19015
19016
|
}
|
|
19016
19017
|
const croppable = pptx.cropResetState(selectedElement, canEdit, true).enabled;
|
|
@@ -19027,7 +19028,7 @@ function ImageCropSection({
|
|
|
19027
19028
|
max: MAX_CROP_PERCENT,
|
|
19028
19029
|
disabled: !croppable,
|
|
19029
19030
|
className: "accent-primary",
|
|
19030
|
-
value: Math.round(
|
|
19031
|
+
value: Math.round(chunk7DGKSEIU_js.clampCropValue(selectedElement[key]) * 100),
|
|
19031
19032
|
onChange: (e) => onUpdateElement({
|
|
19032
19033
|
[key]: Number(e.target.value) / 100
|
|
19033
19034
|
})
|
|
@@ -19091,7 +19092,7 @@ function ImagePropertiesPanel({
|
|
|
19091
19092
|
{
|
|
19092
19093
|
rows: 2,
|
|
19093
19094
|
disabled: !canEdit,
|
|
19094
|
-
className:
|
|
19095
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "resize-none text-[11px]"),
|
|
19095
19096
|
value: selectedElement.altText ?? "",
|
|
19096
19097
|
onChange: (e) => onUpdateElement({
|
|
19097
19098
|
altText: e.target.value
|
|
@@ -20031,7 +20032,7 @@ function AccessibilityTextSection({
|
|
|
20031
20032
|
rows: 2,
|
|
20032
20033
|
disabled: !canEdit,
|
|
20033
20034
|
placeholder: t("pptx.elementAccessibility.altTextPlaceholder"),
|
|
20034
|
-
className:
|
|
20035
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "resize-none text-[11px]"),
|
|
20035
20036
|
value: fields.altText,
|
|
20036
20037
|
onChange: (e) => onUpdateElement({ altText: e.target.value })
|
|
20037
20038
|
}
|
|
@@ -20045,7 +20046,7 @@ function AccessibilityTextSection({
|
|
|
20045
20046
|
type: "text",
|
|
20046
20047
|
disabled: !canEdit,
|
|
20047
20048
|
placeholder: t("pptx.elementAccessibility.titlePlaceholder"),
|
|
20048
|
-
className:
|
|
20049
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "text-[11px]"),
|
|
20049
20050
|
value: fields.title,
|
|
20050
20051
|
onChange: (e) => onUpdateElement({ title: e.target.value })
|
|
20051
20052
|
}
|
|
@@ -20161,7 +20162,7 @@ var SHADOW_EFFECT_CONFIGS = [
|
|
|
20161
20162
|
angle = (Math.atan2(offsetY, offsetX) * 180 / Math.PI + 360) % 360;
|
|
20162
20163
|
}
|
|
20163
20164
|
return {
|
|
20164
|
-
shadowColor:
|
|
20165
|
+
shadowColor: chunk7DGKSEIU_js.normalizeHexColor(s?.shadowColor, "#000000"),
|
|
20165
20166
|
shadowOpacity: s?.shadowOpacity ?? 0.35,
|
|
20166
20167
|
shadowBlur: s?.shadowBlur ?? 6,
|
|
20167
20168
|
shadowAngle: angle,
|
|
@@ -20177,7 +20178,7 @@ var SHADOW_EFFECT_CONFIGS = [
|
|
|
20177
20178
|
key: "sc",
|
|
20178
20179
|
label: "Shadow Color",
|
|
20179
20180
|
type: "color",
|
|
20180
|
-
read: (s) =>
|
|
20181
|
+
read: (s) => chunk7DGKSEIU_js.normalizeHexColor(s?.shadowColor, "#000000"),
|
|
20181
20182
|
write: (v) => ({ shadowColor: String(v) })
|
|
20182
20183
|
},
|
|
20183
20184
|
{
|
|
@@ -20313,7 +20314,7 @@ var SHADOW_EFFECT_CONFIGS = [
|
|
|
20313
20314
|
label: "Inner Shadow",
|
|
20314
20315
|
isOn: (s) => Boolean(s?.innerShadowColor) && s?.innerShadowColor !== "transparent",
|
|
20315
20316
|
onEnable: (s) => ({
|
|
20316
|
-
innerShadowColor:
|
|
20317
|
+
innerShadowColor: chunk7DGKSEIU_js.normalizeHexColor(s?.innerShadowColor, "#000000"),
|
|
20317
20318
|
innerShadowOpacity: s?.innerShadowOpacity ?? 0.5,
|
|
20318
20319
|
innerShadowBlur: s?.innerShadowBlur ?? 5,
|
|
20319
20320
|
innerShadowOffsetX: s?.innerShadowOffsetX ?? 0,
|
|
@@ -20325,7 +20326,7 @@ var SHADOW_EFFECT_CONFIGS = [
|
|
|
20325
20326
|
key: "isc",
|
|
20326
20327
|
label: "Color",
|
|
20327
20328
|
type: "color",
|
|
20328
|
-
read: (s) =>
|
|
20329
|
+
read: (s) => chunk7DGKSEIU_js.normalizeHexColor(s?.innerShadowColor, "#000000"),
|
|
20329
20330
|
write: (v) => ({ innerShadowColor: String(v) })
|
|
20330
20331
|
},
|
|
20331
20332
|
{
|
|
@@ -20835,7 +20836,7 @@ function ColorPickerRow({
|
|
|
20835
20836
|
pushColor(color);
|
|
20836
20837
|
};
|
|
20837
20838
|
const handleEyedropper = async () => {
|
|
20838
|
-
const color = await
|
|
20839
|
+
const color = await chunk7DGKSEIU_js.openNativeEyeDropper();
|
|
20839
20840
|
if (color) {
|
|
20840
20841
|
commit(color);
|
|
20841
20842
|
}
|
|
@@ -20918,9 +20919,9 @@ function GradientStopRow({
|
|
|
20918
20919
|
"input",
|
|
20919
20920
|
{
|
|
20920
20921
|
type: "color",
|
|
20921
|
-
value:
|
|
20922
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(stop2.color, "#3b82f6"),
|
|
20922
20923
|
onChange: (e) => {
|
|
20923
|
-
const hex =
|
|
20924
|
+
const hex = chunk7DGKSEIU_js.normalizeHexColor(e.target.value, "#3b82f6");
|
|
20924
20925
|
patchStop({ color: hex, colorRef: void 0 });
|
|
20925
20926
|
pushColor(hex);
|
|
20926
20927
|
},
|
|
@@ -21045,7 +21046,7 @@ function FillAdvancedControls({
|
|
|
21045
21046
|
onClick: () => onUpdateGradientStops([
|
|
21046
21047
|
...gradientStops,
|
|
21047
21048
|
{
|
|
21048
|
-
color:
|
|
21049
|
+
color: chunk7DGKSEIU_js.normalizeHexColor(style?.fillColor, chunk7DGKSEIU_js.DEFAULT_FILL_COLOR),
|
|
21049
21050
|
position: 50,
|
|
21050
21051
|
opacity: 1
|
|
21051
21052
|
}
|
|
@@ -21059,9 +21060,9 @@ function FillAdvancedControls({
|
|
|
21059
21060
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: `${COL2} flex flex-col gap-2`, children: [
|
|
21060
21061
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: LBL, children: "Pattern" }),
|
|
21061
21062
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid grid-cols-8 gap-1 max-h-48 overflow-y-auto rounded border border-border p-2", children: PATTERN_PRESET_OPTIONS.map((opt) => {
|
|
21062
|
-
const fgColor =
|
|
21063
|
-
const bgColor =
|
|
21064
|
-
const svgPattern =
|
|
21063
|
+
const fgColor = chunk7DGKSEIU_js.normalizeHexColor(style?.fillColor, chunk7DGKSEIU_js.DEFAULT_FILL_COLOR);
|
|
21064
|
+
const bgColor = chunk7DGKSEIU_js.normalizeHexColor(style?.fillPatternBackgroundColor, "#ffffff");
|
|
21065
|
+
const svgPattern = chunk7DGKSEIU_js.getPatternSvg(opt.value, fgColor, bgColor);
|
|
21065
21066
|
const isSelected = (style.fillPatternPreset || "pct20") === opt.value;
|
|
21066
21067
|
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
21067
21068
|
"button",
|
|
@@ -21094,7 +21095,7 @@ function FillAdvancedControls({
|
|
|
21094
21095
|
{
|
|
21095
21096
|
label: t("pptx.fillAdvanced.foregroundColor"),
|
|
21096
21097
|
prefix: "pattern-fg",
|
|
21097
|
-
value:
|
|
21098
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(style?.fillColor, chunk7DGKSEIU_js.DEFAULT_FILL_COLOR),
|
|
21098
21099
|
disabled: isLine,
|
|
21099
21100
|
onChange: (color) => onUpdateShapeStyle({ fillMode: "pattern", fillColor: color })
|
|
21100
21101
|
}
|
|
@@ -21104,7 +21105,7 @@ function FillAdvancedControls({
|
|
|
21104
21105
|
{
|
|
21105
21106
|
label: t("pptx.fillAdvanced.backgroundColor"),
|
|
21106
21107
|
prefix: "pattern-bg",
|
|
21107
|
-
value:
|
|
21108
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(style?.fillPatternBackgroundColor, "#ffffff"),
|
|
21108
21109
|
disabled: isLine,
|
|
21109
21110
|
onChange: (color) => onUpdateShapeStyle({
|
|
21110
21111
|
fillMode: "pattern",
|
|
@@ -21171,11 +21172,11 @@ function QuickStylesGallery({
|
|
|
21171
21172
|
onUpdateShapeStyle
|
|
21172
21173
|
}) {
|
|
21173
21174
|
const { t } = reactI18next.useTranslation();
|
|
21174
|
-
const { viewportWidth } =
|
|
21175
|
+
const { viewportWidth } = chunkTVSTM5J5_js.useIsMobile();
|
|
21175
21176
|
const swatchMinHeight = pptx.getDensePanelTouchTargetPx(viewportWidth);
|
|
21176
21177
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex flex-col gap-1", children: [
|
|
21177
21178
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: LBL, children: t("pptx.shape.quickStyles") }),
|
|
21178
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid grid-cols-6 gap-1", children:
|
|
21179
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid grid-cols-6 gap-1", children: chunk7DGKSEIU_js.SHAPE_QUICK_STYLES.map((qs, idx) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
21179
21180
|
"button",
|
|
21180
21181
|
{
|
|
21181
21182
|
type: "button",
|
|
@@ -21202,7 +21203,7 @@ function StrokeEffectsSection({
|
|
|
21202
21203
|
{
|
|
21203
21204
|
label: t("pptx.inspector.stroke"),
|
|
21204
21205
|
prefix: "stroke",
|
|
21205
|
-
value:
|
|
21206
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(style?.strokeColor, chunk7DGKSEIU_js.DEFAULT_STROKE_COLOR),
|
|
21206
21207
|
selectedRef: style?.strokeColorRef,
|
|
21207
21208
|
onChange: onSetStrokeColor
|
|
21208
21209
|
}
|
|
@@ -21265,7 +21266,7 @@ function StrokeEffectsSection({
|
|
|
21265
21266
|
strokeDash: e.target.value
|
|
21266
21267
|
}),
|
|
21267
21268
|
className: SEL,
|
|
21268
|
-
children:
|
|
21269
|
+
children: chunk7DGKSEIU_js.STROKE_DASH_OPTIONS.map((o) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: o.value, children: t(o.i18nKey) }, o.value))
|
|
21269
21270
|
}
|
|
21270
21271
|
)
|
|
21271
21272
|
] }),
|
|
@@ -21355,10 +21356,10 @@ function FillStrokeProperties({
|
|
|
21355
21356
|
return;
|
|
21356
21357
|
}
|
|
21357
21358
|
if (nextMode === "gradient") {
|
|
21358
|
-
const existing =
|
|
21359
|
+
const existing = chunk7DGKSEIU_js.sanitizeGradientStops(style?.fillGradientStops);
|
|
21359
21360
|
const stops = existing.length >= 2 ? existing : [
|
|
21360
21361
|
{
|
|
21361
|
-
color:
|
|
21362
|
+
color: chunk7DGKSEIU_js.normalizeHexColor(style?.fillColor, chunk7DGKSEIU_js.DEFAULT_FILL_COLOR),
|
|
21362
21363
|
position: 0,
|
|
21363
21364
|
opacity: 1
|
|
21364
21365
|
},
|
|
@@ -21383,7 +21384,7 @@ function FillStrokeProperties({
|
|
|
21383
21384
|
onUpdateShapeStyle({ fillMode: "solid" });
|
|
21384
21385
|
};
|
|
21385
21386
|
const gradientStops = selectedGradientStops.length > 0 ? selectedGradientStops : [
|
|
21386
|
-
{ color:
|
|
21387
|
+
{ color: chunk7DGKSEIU_js.DEFAULT_FILL_COLOR, position: 0 },
|
|
21387
21388
|
{ color: "#ffffff", position: 100 }
|
|
21388
21389
|
];
|
|
21389
21390
|
const showGradient = style?.fillMode === "gradient" || selectedGradientStops.length > 0;
|
|
@@ -21410,7 +21411,7 @@ function FillStrokeProperties({
|
|
|
21410
21411
|
{
|
|
21411
21412
|
label: t("pptx.fill.fill"),
|
|
21412
21413
|
prefix: "fill",
|
|
21413
|
-
value:
|
|
21414
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(style?.fillColor, chunk7DGKSEIU_js.DEFAULT_FILL_COLOR),
|
|
21414
21415
|
selectedRef: style?.fillColorRef,
|
|
21415
21416
|
disabled: line,
|
|
21416
21417
|
onChange: onSetFillColor
|
|
@@ -21494,7 +21495,7 @@ function Text3DProperties({
|
|
|
21494
21495
|
"input",
|
|
21495
21496
|
{
|
|
21496
21497
|
type: "color",
|
|
21497
|
-
value:
|
|
21498
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(t3d?.extrusionColor, "#888888"),
|
|
21498
21499
|
onChange: (e) => {
|
|
21499
21500
|
update3d({ extrusionColor: e.target.value });
|
|
21500
21501
|
pushColor(e.target.value);
|
|
@@ -21685,7 +21686,7 @@ function AdvancedTextFormatting({
|
|
|
21685
21686
|
"input",
|
|
21686
21687
|
{
|
|
21687
21688
|
type: "color",
|
|
21688
|
-
value:
|
|
21689
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(ts?.highlightColor, "#ffff00"),
|
|
21689
21690
|
onChange: (e) => {
|
|
21690
21691
|
onUpdateTextStyle({ highlightColor: e.target.value });
|
|
21691
21692
|
pushColor(e.target.value);
|
|
@@ -21989,7 +21990,7 @@ function TextEffectsPanel({
|
|
|
21989
21990
|
"input",
|
|
21990
21991
|
{
|
|
21991
21992
|
type: "color",
|
|
21992
|
-
value:
|
|
21993
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(ts?.textShadowColor, "#000000"),
|
|
21993
21994
|
onChange: (e) => {
|
|
21994
21995
|
onUpdateTextStyle({ textShadowColor: e.target.value });
|
|
21995
21996
|
pushColor(e.target.value);
|
|
@@ -22096,7 +22097,7 @@ function TextEffectsPanel({
|
|
|
22096
22097
|
"input",
|
|
22097
22098
|
{
|
|
22098
22099
|
type: "color",
|
|
22099
|
-
value:
|
|
22100
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(ts?.textGlowColor, "#ffff00"),
|
|
22100
22101
|
onChange: (e) => {
|
|
22101
22102
|
onUpdateTextStyle({ textGlowColor: e.target.value });
|
|
22102
22103
|
pushColor(e.target.value);
|
|
@@ -22195,7 +22196,7 @@ function TextAdvancedSections({
|
|
|
22195
22196
|
canEdit,
|
|
22196
22197
|
onUpdateTextStyle
|
|
22197
22198
|
}) {
|
|
22198
|
-
if (!(0,
|
|
22199
|
+
if (!(0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(selectedElement)) {
|
|
22199
22200
|
return null;
|
|
22200
22201
|
}
|
|
22201
22202
|
const ts = selectedElement.textStyle;
|
|
@@ -22224,22 +22225,22 @@ function ShapeTextPanels({
|
|
|
22224
22225
|
}) {
|
|
22225
22226
|
const { t } = reactI18next.useTranslation();
|
|
22226
22227
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
22227
|
-
(0,
|
|
22228
|
+
(0, chunk7DGKSEIU_js.dist_exports.hasShapeProperties)(selectedElement) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: CARD2, children: [
|
|
22228
22229
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: HEADING2, children: t("pptx.shape.type", "Shape Type") }),
|
|
22229
22230
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
22230
22231
|
WebSelect,
|
|
22231
22232
|
{
|
|
22232
22233
|
value: selectedElement.shapeType || "rect",
|
|
22233
22234
|
disabled: !canEdit,
|
|
22234
|
-
className:
|
|
22235
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "w-full"),
|
|
22235
22236
|
onChange: (e) => onUpdateElement({
|
|
22236
22237
|
shapeType: e.target.value
|
|
22237
22238
|
}),
|
|
22238
|
-
children:
|
|
22239
|
+
children: chunk7DGKSEIU_js.SHAPE_PRESETS.filter((p) => p.type !== "connector").map((p) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: p.type, children: t(p.i18nKey) }, p.type))
|
|
22239
22240
|
}
|
|
22240
22241
|
)
|
|
22241
22242
|
] }),
|
|
22242
|
-
(0,
|
|
22243
|
+
(0, chunk7DGKSEIU_js.dist_exports.hasShapeProperties)(selectedElement) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: CARD2, "data-pptx-fill-stroke": true, "data-pptx-inspector-section": "fill-stroke", children: [
|
|
22243
22244
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: HEADING2, children: t("pptx.shape.fillStroke", "Fill & Stroke") }),
|
|
22244
22245
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
22245
22246
|
FillStrokeProperties,
|
|
@@ -22247,17 +22248,17 @@ function ShapeTextPanels({
|
|
|
22247
22248
|
selectedElement,
|
|
22248
22249
|
selectedShapeStyle: selectedElement.shapeStyle,
|
|
22249
22250
|
selectedShapeType: selectedElement.shapeType,
|
|
22250
|
-
selectedGradientStops:
|
|
22251
|
+
selectedGradientStops: chunk7DGKSEIU_js.sanitizeGradientStops(
|
|
22251
22252
|
selectedElement.shapeStyle?.fillGradientStops
|
|
22252
22253
|
),
|
|
22253
22254
|
canEdit,
|
|
22254
22255
|
onUpdateShapeStyle: onUpdateElementStyle,
|
|
22255
22256
|
onSetFillColor: (hex, ref) => onUpdateElementStyle({ fillColor: hex, fillMode: "solid", fillColorRef: ref }),
|
|
22256
|
-
onSetStrokeColor: (hex, ref) => onUpdateElementStyle(
|
|
22257
|
+
onSetStrokeColor: (hex, ref) => onUpdateElementStyle(pptx.shapeOutlineChange(hex, ref, selectedElement.shapeStyle ?? {}))
|
|
22257
22258
|
}
|
|
22258
22259
|
)
|
|
22259
22260
|
] }),
|
|
22260
|
-
(0,
|
|
22261
|
+
(0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(selectedElement) && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: CARD2, "data-pptx-text-card": true, children: [
|
|
22261
22262
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: HEADING2, children: t("pptx.text.title", "Text") }),
|
|
22262
22263
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "grid grid-cols-2 gap-1.5 text-[11px]", children: [
|
|
22263
22264
|
/* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex flex-col gap-1", children: [
|
|
@@ -22283,7 +22284,7 @@ function ShapeTextPanels({
|
|
|
22283
22284
|
{
|
|
22284
22285
|
disabled: !canEdit,
|
|
22285
22286
|
ariaLabel: "Text Color",
|
|
22286
|
-
value:
|
|
22287
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(selectedElement.textStyle?.color, "#000000"),
|
|
22287
22288
|
className: "w-full h-7 rounded border border-border bg-transparent cursor-pointer",
|
|
22288
22289
|
onCommit: (hex) => onUpdateTextStyle({ color: hex, colorRef: void 0 })
|
|
22289
22290
|
}
|
|
@@ -22375,7 +22376,7 @@ function TextFormatToggle({
|
|
|
22375
22376
|
{
|
|
22376
22377
|
type: "button",
|
|
22377
22378
|
disabled,
|
|
22378
|
-
className:
|
|
22379
|
+
className: chunk7DGKSEIU_js.cn(
|
|
22379
22380
|
"px-2 py-1 rounded text-[11px] transition-colors max-md:min-w-[44px]! max-md:min-h-[44px]!",
|
|
22380
22381
|
italic && "italic",
|
|
22381
22382
|
underline && "underline",
|
|
@@ -22533,7 +22534,7 @@ var THUMB_COMPONENTS = {
|
|
|
22533
22534
|
chevron: ChevronThumb,
|
|
22534
22535
|
bending: BendingThumb
|
|
22535
22536
|
};
|
|
22536
|
-
var LAYOUT_DESCRIPTORS =
|
|
22537
|
+
var LAYOUT_DESCRIPTORS = chunk7DGKSEIU_js.dist_exports.SWITCHABLE_LAYOUT_TYPES.map((type) => ({
|
|
22537
22538
|
type,
|
|
22538
22539
|
i18nKey: `pptx.smartart.category.${type}`
|
|
22539
22540
|
}));
|
|
@@ -22561,7 +22562,7 @@ function SmartArtLayoutSwitcher({
|
|
|
22561
22562
|
type: "button",
|
|
22562
22563
|
"data-testid": `smartart-layout-${type}`,
|
|
22563
22564
|
disabled: !canEdit,
|
|
22564
|
-
className:
|
|
22565
|
+
className: chunk7DGKSEIU_js.cn(
|
|
22565
22566
|
"flex flex-col items-center gap-0.5 rounded border p-1.5 transition-colors",
|
|
22566
22567
|
"text-[9px] leading-tight",
|
|
22567
22568
|
isActive ? "border-primary bg-primary/15 text-primary" : "border-border text-muted-foreground hover:bg-muted hover:text-foreground",
|
|
@@ -22640,7 +22641,7 @@ function SmartArtNodeStyleControls({
|
|
|
22640
22641
|
disabled: !canEdit,
|
|
22641
22642
|
"aria-label": `Bold ${label}`,
|
|
22642
22643
|
"aria-pressed": bold,
|
|
22643
|
-
className:
|
|
22644
|
+
className: chunk7DGKSEIU_js.cn(
|
|
22644
22645
|
EMPHASIS_BTN,
|
|
22645
22646
|
"font-bold",
|
|
22646
22647
|
bold ? "border-primary bg-primary/20 text-primary" : "border-border text-muted-foreground"
|
|
@@ -22656,7 +22657,7 @@ function SmartArtNodeStyleControls({
|
|
|
22656
22657
|
disabled: !canEdit,
|
|
22657
22658
|
"aria-label": `Italic ${label}`,
|
|
22658
22659
|
"aria-pressed": italic,
|
|
22659
|
-
className:
|
|
22660
|
+
className: chunk7DGKSEIU_js.cn(
|
|
22660
22661
|
EMPHASIS_BTN,
|
|
22661
22662
|
"italic",
|
|
22662
22663
|
italic ? "border-primary bg-primary/20 text-primary" : "border-border text-muted-foreground"
|
|
@@ -22695,7 +22696,7 @@ function SmartArtNodeRow({
|
|
|
22695
22696
|
"div",
|
|
22696
22697
|
{
|
|
22697
22698
|
role: "listitem",
|
|
22698
|
-
className:
|
|
22699
|
+
className: chunk7DGKSEIU_js.cn(
|
|
22699
22700
|
"rounded border bg-background/60 p-1.5",
|
|
22700
22701
|
isChild ? "border-border/60 ml-4" : "border-border"
|
|
22701
22702
|
),
|
|
@@ -22710,7 +22711,7 @@ function SmartArtNodeRow({
|
|
|
22710
22711
|
"data-testid": "smartart-node-text",
|
|
22711
22712
|
disabled: !canEdit,
|
|
22712
22713
|
"aria-label": label,
|
|
22713
|
-
className:
|
|
22714
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "flex-1 text-[11px] py-0.5"),
|
|
22714
22715
|
value: text,
|
|
22715
22716
|
onChange: (e) => onChangeText(nodeId, e.target.value),
|
|
22716
22717
|
onKeyDown: (e) => onKeyDown(e, nodeId),
|
|
@@ -22759,7 +22760,7 @@ function SmartArtNodeRow({
|
|
|
22759
22760
|
{
|
|
22760
22761
|
type: "button",
|
|
22761
22762
|
disabled: !canEdit || removeDisabled,
|
|
22762
|
-
className:
|
|
22763
|
+
className: chunk7DGKSEIU_js.cn(MINI_BTN, "hover:text-red-400"),
|
|
22763
22764
|
onClick: () => onRemove(nodeId),
|
|
22764
22765
|
"aria-label": `Remove ${label}`,
|
|
22765
22766
|
title: removeDisabled ? t("pptx.smartArt.layoutMinimum") : t("pptx.smartArt.remove"),
|
|
@@ -22802,7 +22803,7 @@ function SmartArtStyleControls({
|
|
|
22802
22803
|
disabled: !canEdit,
|
|
22803
22804
|
"data-testid": "smartart-color-scheme",
|
|
22804
22805
|
"aria-label": t("pptx.smartart.colorScheme"),
|
|
22805
|
-
className:
|
|
22806
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "w-full"),
|
|
22806
22807
|
value: colorScheme,
|
|
22807
22808
|
onChange: (e) => onChangeColorScheme(e.target.value),
|
|
22808
22809
|
children: colorSchemes.map((cs) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: cs, children: pptx.schemaLabel(pptx.SMARTART_COLOR_SCHEME_LABEL_KEYS, cs, translate) }, cs))
|
|
@@ -22817,7 +22818,7 @@ function SmartArtStyleControls({
|
|
|
22817
22818
|
type: "button",
|
|
22818
22819
|
disabled: !canEdit,
|
|
22819
22820
|
"aria-pressed": style === s,
|
|
22820
|
-
className:
|
|
22821
|
+
className: chunk7DGKSEIU_js.cn(
|
|
22821
22822
|
"flex-1 px-2 py-1 text-[10px] rounded border transition-colors",
|
|
22822
22823
|
style === s ? "border-primary bg-primary/20 text-primary" : "border-border text-muted-foreground hover:bg-muted"
|
|
22823
22824
|
),
|
|
@@ -22863,7 +22864,7 @@ function SmartArtPropertiesPanel({
|
|
|
22863
22864
|
const reflowed = box ? pptx.rebuildDrawingShapesIfCleared(
|
|
22864
22865
|
newData,
|
|
22865
22866
|
newData.layout,
|
|
22866
|
-
|
|
22867
|
+
chunkTVSTM5J5_js.resolveSmartArtDataPalette(newData),
|
|
22867
22868
|
newData.style ?? "flat",
|
|
22868
22869
|
"inspector",
|
|
22869
22870
|
box
|
|
@@ -22874,10 +22875,10 @@ function SmartArtPropertiesPanel({
|
|
|
22874
22875
|
applySmartArtData({ ...smartArtData, ...patch });
|
|
22875
22876
|
};
|
|
22876
22877
|
const handleUpdateNodeText = (nodeId, text) => {
|
|
22877
|
-
applySmartArtData((0,
|
|
22878
|
+
applySmartArtData((0, chunk7DGKSEIU_js.dist_exports.updateSmartArtNodeText)(smartArtData, nodeId, text));
|
|
22878
22879
|
};
|
|
22879
22880
|
const handleChangeNodeStyle = (nodeId, patch) => {
|
|
22880
|
-
const next = (0,
|
|
22881
|
+
const next = (0, chunk7DGKSEIU_js.dist_exports.setSmartArtNodeStyle)(smartArtData, nodeId, patch);
|
|
22881
22882
|
if (next !== smartArtData) {
|
|
22882
22883
|
applySmartArtData(next);
|
|
22883
22884
|
}
|
|
@@ -22886,17 +22887,17 @@ function SmartArtPropertiesPanel({
|
|
|
22886
22887
|
if (!pptx.canAddTopLevelNode(layout, topLevelCount)) {
|
|
22887
22888
|
return;
|
|
22888
22889
|
}
|
|
22889
|
-
applySmartArtData((0,
|
|
22890
|
+
applySmartArtData((0, chunk7DGKSEIU_js.dist_exports.addSmartArtNodeAsChild)(smartArtData));
|
|
22890
22891
|
};
|
|
22891
22892
|
const addSubItem = (parentId) => {
|
|
22892
|
-
applySmartArtData((0,
|
|
22893
|
+
applySmartArtData((0, chunk7DGKSEIU_js.dist_exports.addSmartArtNodeAsChild)(smartArtData, parentId, "Sub-item"));
|
|
22893
22894
|
};
|
|
22894
22895
|
const removeNode = (nodeId) => {
|
|
22895
22896
|
const isTopLevel = !nodes.find((n) => n.id === nodeId)?.parentId;
|
|
22896
22897
|
if (isTopLevel && !pptx.canRemoveTopLevelNode(layout, topLevelCount)) {
|
|
22897
22898
|
return;
|
|
22898
22899
|
}
|
|
22899
|
-
applySmartArtData((0,
|
|
22900
|
+
applySmartArtData((0, chunk7DGKSEIU_js.dist_exports.removeSmartArtNode)(smartArtData, nodeId));
|
|
22900
22901
|
};
|
|
22901
22902
|
const moveNode = (nodeId, direction) => {
|
|
22902
22903
|
const next = pptx.reorder(smartArtData, nodeId, direction);
|
|
@@ -23052,7 +23053,7 @@ function TableDataGrid({
|
|
|
23052
23053
|
}) {
|
|
23053
23054
|
const { t } = reactI18next.useTranslation();
|
|
23054
23055
|
const grid = pptx.buildTableDataGrid(tableElement);
|
|
23055
|
-
const { viewportWidth } =
|
|
23056
|
+
const { viewportWidth } = chunkTVSTM5J5_js.useIsMobile();
|
|
23056
23057
|
const gridPlan = pptx.getDenseGridLayoutPlan(viewportWidth);
|
|
23057
23058
|
const touchTargetPx = pptx.getDensePanelTouchTargetPx(viewportWidth);
|
|
23058
23059
|
const stickyGutterClass = gridPlan.stickyFirstColumn ? "sticky left-0 z-10" : "";
|
|
@@ -23464,7 +23465,7 @@ function TableCellColorField({
|
|
|
23464
23465
|
disabled,
|
|
23465
23466
|
onCommit
|
|
23466
23467
|
}) {
|
|
23467
|
-
const hex =
|
|
23468
|
+
const hex = chunk7DGKSEIU_js.normalizeHexColor(value, fallback);
|
|
23468
23469
|
return /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex flex-col gap-1", children: [
|
|
23469
23470
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground", children: label }),
|
|
23470
23471
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -23575,7 +23576,7 @@ function TableCellFormattingPanel({
|
|
|
23575
23576
|
{
|
|
23576
23577
|
type: "button",
|
|
23577
23578
|
disabled: !canEdit,
|
|
23578
|
-
className:
|
|
23579
|
+
className: chunk7DGKSEIU_js.cn(
|
|
23579
23580
|
"px-2 py-1 rounded text-[11px] transition-colors",
|
|
23580
23581
|
cls,
|
|
23581
23582
|
cs[key] ? "bg-primary text-white" : "bg-muted hover:bg-accent"
|
|
@@ -23594,7 +23595,7 @@ function TableCellFormattingPanel({
|
|
|
23594
23595
|
{
|
|
23595
23596
|
type: "button",
|
|
23596
23597
|
disabled: !canEdit,
|
|
23597
|
-
className:
|
|
23598
|
+
className: chunk7DGKSEIU_js.cn(
|
|
23598
23599
|
"px-2 py-1 rounded text-[11px] transition-colors",
|
|
23599
23600
|
cs.align === val ? "bg-primary text-white" : "bg-muted hover:bg-accent"
|
|
23600
23601
|
),
|
|
@@ -23612,7 +23613,7 @@ function TableCellFormattingPanel({
|
|
|
23612
23613
|
{
|
|
23613
23614
|
type: "button",
|
|
23614
23615
|
disabled: !canEdit,
|
|
23615
|
-
className:
|
|
23616
|
+
className: chunk7DGKSEIU_js.cn(
|
|
23616
23617
|
"px-2 py-1 rounded text-[11px] transition-colors",
|
|
23617
23618
|
cs.vAlign === val ? "bg-primary text-white" : "bg-muted hover:bg-accent"
|
|
23618
23619
|
),
|
|
@@ -23635,7 +23636,7 @@ function TableCellFormattingPanel({
|
|
|
23635
23636
|
DebouncedColorInput,
|
|
23636
23637
|
{
|
|
23637
23638
|
disabled: !canEdit,
|
|
23638
|
-
value:
|
|
23639
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(cs[colorKey], "#374151"),
|
|
23639
23640
|
className: "w-7 h-6 rounded border border-border bg-transparent cursor-pointer shrink-0",
|
|
23640
23641
|
onCommit: (hex) => updateCellStyle({ [colorKey]: hex })
|
|
23641
23642
|
}
|
|
@@ -23645,7 +23646,7 @@ function TableCellFormattingPanel({
|
|
|
23645
23646
|
{
|
|
23646
23647
|
type: "number",
|
|
23647
23648
|
disabled: !canEdit,
|
|
23648
|
-
className:
|
|
23649
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "w-14"),
|
|
23649
23650
|
min: 0,
|
|
23650
23651
|
max: 10,
|
|
23651
23652
|
value: cs[widthKey] ?? 1,
|
|
@@ -23661,7 +23662,7 @@ function TableCellFormattingPanel({
|
|
|
23661
23662
|
{
|
|
23662
23663
|
type: "button",
|
|
23663
23664
|
disabled: !canEdit,
|
|
23664
|
-
className:
|
|
23665
|
+
className: chunk7DGKSEIU_js.cn(BTN2, "text-center"),
|
|
23665
23666
|
onClick: () => {
|
|
23666
23667
|
const newRows = pptx.computeMergeCellRight(td, rowIndex, columnIndex);
|
|
23667
23668
|
if (newRows) {
|
|
@@ -23676,7 +23677,7 @@ function TableCellFormattingPanel({
|
|
|
23676
23677
|
{
|
|
23677
23678
|
type: "button",
|
|
23678
23679
|
disabled: !canEdit,
|
|
23679
|
-
className:
|
|
23680
|
+
className: chunk7DGKSEIU_js.cn(BTN2, "text-center"),
|
|
23680
23681
|
onClick: () => {
|
|
23681
23682
|
const newRows = pptx.computeMergeCellDown(td, rowIndex, columnIndex);
|
|
23682
23683
|
if (newRows) {
|
|
@@ -23691,7 +23692,7 @@ function TableCellFormattingPanel({
|
|
|
23691
23692
|
{
|
|
23692
23693
|
type: "button",
|
|
23693
23694
|
disabled: !canEdit,
|
|
23694
|
-
className:
|
|
23695
|
+
className: chunk7DGKSEIU_js.cn(BTN2, "text-center"),
|
|
23695
23696
|
onClick: () => {
|
|
23696
23697
|
const newRows = pptx.computeSplitCell(td, rowIndex, columnIndex);
|
|
23697
23698
|
if (newRows) {
|
|
@@ -23877,7 +23878,7 @@ function TableStyleEditor({
|
|
|
23877
23878
|
const { t } = reactI18next.useTranslation();
|
|
23878
23879
|
const themeColorMap = useThemeColorMap();
|
|
23879
23880
|
const [activeStyleId, setActiveStyleId] = React99.useState(
|
|
23880
|
-
styleId ? (0,
|
|
23881
|
+
styleId ? (0, chunk7DGKSEIU_js.dist_exports.normalizeTableStyleGuid)(styleId) : ""
|
|
23881
23882
|
);
|
|
23882
23883
|
const [selectedPart, setSelectedPart] = React99.useState("wholeTbl");
|
|
23883
23884
|
const entry = activeStyleId ? styleMap?.[activeStyleId] : void 0;
|
|
@@ -23898,8 +23899,8 @@ function TableStyleEditor({
|
|
|
23898
23899
|
return;
|
|
23899
23900
|
}
|
|
23900
23901
|
const nextMap = { ...styleMap ?? {} };
|
|
23901
|
-
const created = (0,
|
|
23902
|
-
(0,
|
|
23902
|
+
const created = (0, chunk7DGKSEIU_js.dist_exports.createTableStyleEntry)(nextMap, { styleName: name, basedOn: entry });
|
|
23903
|
+
(0, chunk7DGKSEIU_js.dist_exports.addTableStyleToMap)(nextMap, created);
|
|
23903
23904
|
onStyleMapChange(nextMap);
|
|
23904
23905
|
setActiveStyleId(created.styleId);
|
|
23905
23906
|
onAssignStyle?.(created.styleId);
|
|
@@ -23909,7 +23910,7 @@ function TableStyleEditor({
|
|
|
23909
23910
|
return;
|
|
23910
23911
|
}
|
|
23911
23912
|
const nextMap = { ...styleMap };
|
|
23912
|
-
(0,
|
|
23913
|
+
(0, chunk7DGKSEIU_js.dist_exports.deleteTableStyleFromMap)(nextMap, entry.styleId);
|
|
23913
23914
|
onStyleMapChange(nextMap);
|
|
23914
23915
|
onDeleteStyle(entry.styleId);
|
|
23915
23916
|
onClose();
|
|
@@ -23963,7 +23964,7 @@ function TablePropertiesPanel({
|
|
|
23963
23964
|
const updateMergeRows = (rows) => {
|
|
23964
23965
|
const tableData = { ...td, rows };
|
|
23965
23966
|
const updates = { tableData };
|
|
23966
|
-
const rawXml = (0,
|
|
23967
|
+
const rawXml = (0, chunk7DGKSEIU_js.dist_exports.updateMergeAttrsInRawXml)(tableElement, tableData);
|
|
23967
23968
|
if (rawXml) {
|
|
23968
23969
|
updates.rawXml = rawXml;
|
|
23969
23970
|
}
|
|
@@ -24029,7 +24030,7 @@ function TablePropertiesPanel({
|
|
|
24029
24030
|
] }),
|
|
24030
24031
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: CARD2, children: [
|
|
24031
24032
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: HEADING2, children: t("pptx.table.stylePresets") }),
|
|
24032
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid grid-cols-3 gap-1.5", children:
|
|
24033
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "grid grid-cols-3 gap-1.5", children: chunk7DGKSEIU_js.TABLE_STYLE_PRESETS.map((preset) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
24033
24034
|
"button",
|
|
24034
24035
|
{
|
|
24035
24036
|
type: "button",
|
|
@@ -24257,7 +24258,7 @@ function ElementInspectorBody({
|
|
|
24257
24258
|
box: { width: selectedElement.width, height: selectedElement.height }
|
|
24258
24259
|
}
|
|
24259
24260
|
),
|
|
24260
|
-
(0,
|
|
24261
|
+
(0, chunk7DGKSEIU_js.dist_exports.isImageLikeElement)(selectedElement) && /* @__PURE__ */ jsxRuntime.jsx(
|
|
24261
24262
|
ImagePropertiesPanel,
|
|
24262
24263
|
{
|
|
24263
24264
|
selectedElement,
|
|
@@ -24422,7 +24423,7 @@ function CommentMentionTextarea({
|
|
|
24422
24423
|
"data-testid": "pptx-comment-mention-option",
|
|
24423
24424
|
role: "option",
|
|
24424
24425
|
"aria-selected": index === safeHighlighted,
|
|
24425
|
-
className:
|
|
24426
|
+
className: chunk7DGKSEIU_js.cn(
|
|
24426
24427
|
"block w-full px-2 py-1 text-left text-[11px] hover:bg-accent",
|
|
24427
24428
|
index === safeHighlighted && "bg-accent"
|
|
24428
24429
|
),
|
|
@@ -24545,7 +24546,7 @@ function InspectorCommentRow({
|
|
|
24545
24546
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
24546
24547
|
"div",
|
|
24547
24548
|
{
|
|
24548
|
-
className:
|
|
24549
|
+
className: chunk7DGKSEIU_js.cn(
|
|
24549
24550
|
"rounded border border-border bg-card p-2",
|
|
24550
24551
|
depth > 0 && "ml-3 border-l-2 border-l-primary/40"
|
|
24551
24552
|
),
|
|
@@ -24558,7 +24559,7 @@ function InspectorCommentRow({
|
|
|
24558
24559
|
t("pptx.comments.resolved")
|
|
24559
24560
|
] })
|
|
24560
24561
|
] }),
|
|
24561
|
-
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] text-muted-foreground flex-shrink-0", children:
|
|
24562
|
+
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-[10px] text-muted-foreground flex-shrink-0", children: chunk7DGKSEIU_js.formatCommentTimestamp(comment.createdAt) })
|
|
24562
24563
|
] }),
|
|
24563
24564
|
comment.elementId && (targetElement ? /* @__PURE__ */ jsxRuntime.jsxs(
|
|
24564
24565
|
"button",
|
|
@@ -24566,12 +24567,12 @@ function InspectorCommentRow({
|
|
|
24566
24567
|
type: "button",
|
|
24567
24568
|
className: "mt-1 inline-flex items-center gap-1 rounded bg-primary/20 px-1.5 py-0.5 text-[10px] text-primary hover:bg-primary/30 transition-colors",
|
|
24568
24569
|
title: t("pptx.comments.commentingOn", {
|
|
24569
|
-
element:
|
|
24570
|
+
element: chunk7DGKSEIU_js.getElementLabel(targetElement)
|
|
24570
24571
|
}),
|
|
24571
24572
|
onClick: () => onSelectElement(targetElement.id),
|
|
24572
24573
|
children: [
|
|
24573
24574
|
/* @__PURE__ */ jsxRuntime.jsx(lu.LuType, { className: "h-2.5 w-2.5" }),
|
|
24574
|
-
|
|
24575
|
+
chunk7DGKSEIU_js.getElementLabel(targetElement)
|
|
24575
24576
|
]
|
|
24576
24577
|
}
|
|
24577
24578
|
) : /* @__PURE__ */ jsxRuntime.jsx("span", { className: "mt-1 inline-flex items-center gap-1 rounded bg-muted/60 px-1.5 py-0.5 text-[10px] text-muted-foreground", children: t("pptx.comments.deletedElement") })),
|
|
@@ -24640,7 +24641,7 @@ function InspectorCommentRow({
|
|
|
24640
24641
|
"button",
|
|
24641
24642
|
{
|
|
24642
24643
|
type: "button",
|
|
24643
|
-
className:
|
|
24644
|
+
className: chunk7DGKSEIU_js.cn(
|
|
24644
24645
|
"inline-flex items-center justify-center p-1.5 border-l border-border transition-colors",
|
|
24645
24646
|
comment.resolved ? "bg-green-900/40 text-green-300 hover:bg-green-900/60" : "hover:bg-accent text-foreground hover:text-foreground"
|
|
24646
24647
|
),
|
|
@@ -24783,7 +24784,7 @@ function InspectorCommentsSection({
|
|
|
24783
24784
|
selectedElement && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "inline-flex items-center gap-1 rounded bg-primary/20 px-1.5 py-0.5 text-[10px] text-primary", children: [
|
|
24784
24785
|
/* @__PURE__ */ jsxRuntime.jsx(lu.LuType, { className: "h-2.5 w-2.5" }),
|
|
24785
24786
|
t("pptx.comments.commentingOn", {
|
|
24786
|
-
element:
|
|
24787
|
+
element: chunk7DGKSEIU_js.getElementLabel(selectedElement)
|
|
24787
24788
|
})
|
|
24788
24789
|
] }),
|
|
24789
24790
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
@@ -24794,7 +24795,7 @@ function InspectorCommentsSection({
|
|
|
24794
24795
|
authors: commentAuthors,
|
|
24795
24796
|
rows: 2,
|
|
24796
24797
|
placeholder: selectedElement ? t("pptx.comments.addOnElement", {
|
|
24797
|
-
element:
|
|
24798
|
+
element: chunk7DGKSEIU_js.getElementLabel(selectedElement)
|
|
24798
24799
|
}) : t("pptx.comments.addPlaceholder"),
|
|
24799
24800
|
className: "w-full bg-muted border border-border rounded px-2 py-1 text-xs resize-y outline-none focus:border-primary",
|
|
24800
24801
|
onChange: onSetCommentDraft,
|
|
@@ -24807,7 +24808,7 @@ function InspectorCommentsSection({
|
|
|
24807
24808
|
type: "button",
|
|
24808
24809
|
onClick: onAddComment,
|
|
24809
24810
|
disabled: !commentDraft.trim(),
|
|
24810
|
-
className:
|
|
24811
|
+
className: chunk7DGKSEIU_js.cn(
|
|
24811
24812
|
"w-full inline-flex items-center justify-center gap-1 rounded px-2 py-1 text-[11px] font-medium transition-colors max-md:min-h-[44px]!",
|
|
24812
24813
|
commentDraft.trim() ? "bg-primary hover:bg-primary/80 text-white" : "bg-muted text-muted-foreground cursor-not-allowed"
|
|
24813
24814
|
),
|
|
@@ -24821,7 +24822,7 @@ function InspectorCommentsSection({
|
|
|
24821
24822
|
] });
|
|
24822
24823
|
}
|
|
24823
24824
|
function elementLabel(element) {
|
|
24824
|
-
const text = (0,
|
|
24825
|
+
const text = (0, chunk7DGKSEIU_js.dist_exports.hasTextProperties)(element) ? (element.text || "").slice(0, 24) : void 0;
|
|
24825
24826
|
return text || element.type;
|
|
24826
24827
|
}
|
|
24827
24828
|
function InspectorElementsTab({
|
|
@@ -24848,13 +24849,13 @@ function InspectorElementsTab({
|
|
|
24848
24849
|
};
|
|
24849
24850
|
if (!activeSlide) {
|
|
24850
24851
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1", children: [
|
|
24851
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
24852
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: chunk7DGKSEIU_js.cn(HEADING2, "mb-2"), children: t("pptx.inspector.layerOrder") }),
|
|
24852
24853
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "text-muted-foreground italic", children: t("pptx.inspector.noSlideSelected") })
|
|
24853
24854
|
] });
|
|
24854
24855
|
}
|
|
24855
24856
|
const elements = activeSlide.elements || [];
|
|
24856
24857
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-1", "data-pptx-elements-tab": true, children: [
|
|
24857
|
-
/* @__PURE__ */ jsxRuntime.jsx("div", { className:
|
|
24858
|
+
/* @__PURE__ */ jsxRuntime.jsx("div", { className: chunk7DGKSEIU_js.cn(HEADING2, "mb-2"), children: t("pptx.inspector.layerOrder") }),
|
|
24858
24859
|
[...elements].reverse().map((el, reversedIndex) => {
|
|
24859
24860
|
const index = elements.length - 1 - reversedIndex;
|
|
24860
24861
|
const selected = selectedElementId === el.id || selectedElementIds.includes(el.id);
|
|
@@ -24862,7 +24863,7 @@ function InspectorElementsTab({
|
|
|
24862
24863
|
"div",
|
|
24863
24864
|
{
|
|
24864
24865
|
title: `${el.type} - ${el.id}`,
|
|
24865
|
-
className:
|
|
24866
|
+
className: chunk7DGKSEIU_js.cn(
|
|
24866
24867
|
"flex items-center gap-2 px-2 py-1 rounded cursor-pointer transition-colors",
|
|
24867
24868
|
selected ? "bg-primary/30 text-primary" : "hover:bg-muted text-foreground"
|
|
24868
24869
|
),
|
|
@@ -24899,7 +24900,7 @@ function InspectorPaneHeader({
|
|
|
24899
24900
|
onClose
|
|
24900
24901
|
}) {
|
|
24901
24902
|
const { t } = reactI18next.useTranslation();
|
|
24902
|
-
const { viewportWidth } =
|
|
24903
|
+
const { viewportWidth } = chunkTVSTM5J5_js.useIsMobile();
|
|
24903
24904
|
const touchTargetPx = pptx.getDensePanelTouchTargetPx(viewportWidth);
|
|
24904
24905
|
const touchBtnStyle = { minWidth: touchTargetPx, minHeight: touchTargetPx };
|
|
24905
24906
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
@@ -24922,7 +24923,7 @@ function InspectorPaneHeader({
|
|
|
24922
24923
|
type: "button",
|
|
24923
24924
|
title: t(labelKey),
|
|
24924
24925
|
style: touchBtnStyle,
|
|
24925
|
-
className:
|
|
24926
|
+
className: chunk7DGKSEIU_js.cn(
|
|
24926
24927
|
"flex items-center justify-center gap-1 px-2 py-1 rounded text-[11px] transition-colors",
|
|
24927
24928
|
activeTab === key ? "bg-primary text-white" : "text-muted-foreground hover:text-foreground hover:bg-accent"
|
|
24928
24929
|
),
|
|
@@ -25036,7 +25037,7 @@ function CustomPropertiesBlock({
|
|
|
25036
25037
|
"button",
|
|
25037
25038
|
{
|
|
25038
25039
|
type: "button",
|
|
25039
|
-
className:
|
|
25040
|
+
className: chunk7DGKSEIU_js.cn(BTN2, "px-1.5 text-red-400 hover:text-red-300"),
|
|
25040
25041
|
onClick: () => onUpdate(customProperties.filter((_, i) => i !== index)),
|
|
25041
25042
|
children: "\xD7"
|
|
25042
25043
|
}
|
|
@@ -25364,7 +25365,7 @@ function PresentationSettingsCard({
|
|
|
25364
25365
|
min: 1,
|
|
25365
25366
|
max: 16,
|
|
25366
25367
|
disabled: !canEdit,
|
|
25367
|
-
className:
|
|
25368
|
+
className: chunk7DGKSEIU_js.cn(INPUT2, "w-20"),
|
|
25368
25369
|
value: pptx.printPropertiesSlidesPerPage(presentationProperties.printProperties),
|
|
25369
25370
|
onChange: (e) => onUpdate({
|
|
25370
25371
|
printProperties: pptx.withSlidesPerPage(
|
|
@@ -25452,14 +25453,14 @@ function SlideThemeOverridePanel({
|
|
|
25452
25453
|
const translate = React99.useCallback((key) => t(key), [t]);
|
|
25453
25454
|
const override = activeSlide?.clrMapOverride;
|
|
25454
25455
|
const isOverrideActive = override !== void 0;
|
|
25455
|
-
const targetSlotOptions = React99.useMemo(() => [...
|
|
25456
|
+
const targetSlotOptions = React99.useMemo(() => [...chunk7DGKSEIU_js.dist_exports.THEME_COLOR_SCHEME_KEYS], []);
|
|
25456
25457
|
const commitOverride = React99.useCallback(
|
|
25457
25458
|
(nextOverride) => {
|
|
25458
25459
|
if (!activeSlide || !theme?.colorScheme) {
|
|
25459
25460
|
onUpdateSlide({ clrMapOverride: nextOverride });
|
|
25460
25461
|
return;
|
|
25461
25462
|
}
|
|
25462
|
-
const nextSlide = (0,
|
|
25463
|
+
const nextSlide = (0, chunk7DGKSEIU_js.dist_exports.applyThemeOverrideToSlide)(activeSlide, theme.colorScheme, nextOverride);
|
|
25463
25464
|
onUpdateSlide({
|
|
25464
25465
|
clrMapOverride: nextSlide.clrMapOverride,
|
|
25465
25466
|
backgroundColor: nextSlide.backgroundColor,
|
|
@@ -25472,8 +25473,8 @@ function SlideThemeOverridePanel({
|
|
|
25472
25473
|
(enabled) => {
|
|
25473
25474
|
if (enabled) {
|
|
25474
25475
|
const defaultMap = {};
|
|
25475
|
-
for (const key of
|
|
25476
|
-
defaultMap[key] =
|
|
25476
|
+
for (const key of chunk7DGKSEIU_js.dist_exports.COLOR_MAP_ALIAS_KEYS) {
|
|
25477
|
+
defaultMap[key] = chunk7DGKSEIU_js.dist_exports.DEFAULT_COLOR_MAP[key];
|
|
25477
25478
|
}
|
|
25478
25479
|
commitOverride(defaultMap);
|
|
25479
25480
|
} else {
|
|
@@ -25486,9 +25487,9 @@ function SlideThemeOverridePanel({
|
|
|
25486
25487
|
(alias, targetSlot) => {
|
|
25487
25488
|
const current = override ?? {};
|
|
25488
25489
|
const next = { ...current, [alias]: targetSlot };
|
|
25489
|
-
for (const key of
|
|
25490
|
+
for (const key of chunk7DGKSEIU_js.dist_exports.COLOR_MAP_ALIAS_KEYS) {
|
|
25490
25491
|
if (!next[key]) {
|
|
25491
|
-
next[key] =
|
|
25492
|
+
next[key] = chunk7DGKSEIU_js.dist_exports.DEFAULT_COLOR_MAP[key];
|
|
25492
25493
|
}
|
|
25493
25494
|
}
|
|
25494
25495
|
commitOverride(next);
|
|
@@ -25520,8 +25521,8 @@ function SlideThemeOverridePanel({
|
|
|
25520
25521
|
),
|
|
25521
25522
|
t("pptx.themeOverride.enableOverride")
|
|
25522
25523
|
] }),
|
|
25523
|
-
isOverrideActive && override && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-1.5", children:
|
|
25524
|
-
const currentTarget = override[alias] ??
|
|
25524
|
+
isOverrideActive && override && /* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-1.5", children: chunk7DGKSEIU_js.dist_exports.COLOR_MAP_ALIAS_KEYS.map((alias) => {
|
|
25525
|
+
const currentTarget = override[alias] ?? chunk7DGKSEIU_js.dist_exports.DEFAULT_COLOR_MAP[alias];
|
|
25525
25526
|
const resolvedHex = resolveSlotColor(currentTarget);
|
|
25526
25527
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "flex items-center gap-2 text-[11px]", children: [
|
|
25527
25528
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "w-24 truncate text-muted-foreground", title: ALIAS_LABELS[alias], children: ALIAS_LABELS[alias] }),
|
|
@@ -25600,7 +25601,7 @@ function TransitionPreview({
|
|
|
25600
25601
|
const { t } = reactI18next.useTranslation();
|
|
25601
25602
|
const durationMs = transition.durationMs ?? 500;
|
|
25602
25603
|
const animations = React99.useMemo(
|
|
25603
|
-
() =>
|
|
25604
|
+
() => chunkTVSTM5J5_js.getSlideTransitionAnimations(
|
|
25604
25605
|
transition.type,
|
|
25605
25606
|
durationMs,
|
|
25606
25607
|
transition.direction,
|
|
@@ -25669,7 +25670,7 @@ function TransitionPreview({
|
|
|
25669
25670
|
]
|
|
25670
25671
|
}
|
|
25671
25672
|
),
|
|
25672
|
-
/* @__PURE__ */ jsxRuntime.jsx("style", { children:
|
|
25673
|
+
/* @__PURE__ */ jsxRuntime.jsx("style", { children: chunkTVSTM5J5_js.SLIDE_TRANSITION_KEYFRAMES })
|
|
25673
25674
|
] });
|
|
25674
25675
|
}
|
|
25675
25676
|
var DEFAULT_DURATION_MS = 320;
|
|
@@ -25686,13 +25687,13 @@ function SlideTransitionSection({
|
|
|
25686
25687
|
return null;
|
|
25687
25688
|
}
|
|
25688
25689
|
const transitionType = activeSlide.transition?.type ?? "none";
|
|
25689
|
-
const validDirections =
|
|
25690
|
+
const validDirections = chunk7DGKSEIU_js.dist_exports.TRANSITION_VALID_DIRECTIONS[transitionType];
|
|
25690
25691
|
const hasDirections = validDirections !== void 0 && validDirections.length > 0;
|
|
25691
25692
|
const usesOrientation = pptx.TRANSITION_ORIENTATION_TYPES.has(transitionType);
|
|
25692
25693
|
const isWheel = transitionType === "wheel";
|
|
25693
25694
|
const isMorph = transitionType === "morph";
|
|
25694
|
-
const patternOptions =
|
|
25695
|
-
const hasThruBlk =
|
|
25695
|
+
const patternOptions = chunk7DGKSEIU_js.dist_exports.TRANSITION_PATTERN_OPTIONS[transitionType];
|
|
25696
|
+
const hasThruBlk = chunk7DGKSEIU_js.dist_exports.TRANSITION_THRUBLK_TYPES.has(transitionType);
|
|
25696
25697
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
25697
25698
|
"div",
|
|
25698
25699
|
{
|
|
@@ -25712,7 +25713,7 @@ function SlideTransitionSection({
|
|
|
25712
25713
|
type: e.target.value
|
|
25713
25714
|
}),
|
|
25714
25715
|
className: "bg-muted border border-border rounded px-2 py-1 max-md:min-h-[44px]!",
|
|
25715
|
-
children:
|
|
25716
|
+
children: chunk7DGKSEIU_js.SLIDE_TRANSITION_OPTIONS.map((option) => /* @__PURE__ */ jsxRuntime.jsx("option", { value: option.value, children: t(option.i18nKey) }, option.value))
|
|
25716
25717
|
}
|
|
25717
25718
|
)
|
|
25718
25719
|
] }),
|
|
@@ -25928,7 +25929,7 @@ function TagsSection({
|
|
|
25928
25929
|
"button",
|
|
25929
25930
|
{
|
|
25930
25931
|
type: "button",
|
|
25931
|
-
className:
|
|
25932
|
+
className: chunk7DGKSEIU_js.cn(BTN2, "px-1.5 text-red-400 hover:text-red-300"),
|
|
25932
25933
|
title: t("pptx.tags.deleteTag"),
|
|
25933
25934
|
onClick: () => deleteTag(tag.colIdx, tag.tagIdx),
|
|
25934
25935
|
children: /* @__PURE__ */ jsxRuntime.jsx(lu.LuTrash2, { className: "w-3 h-3" })
|
|
@@ -26057,7 +26058,7 @@ function PresentationPropertiesPanel({
|
|
|
26057
26058
|
canEdit
|
|
26058
26059
|
}
|
|
26059
26060
|
),
|
|
26060
|
-
activeSlide && /* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
26061
|
+
activeSlide && /* @__PURE__ */ jsxRuntime.jsxs("div", { className: chunk7DGKSEIU_js.cn(CARD2, "space-y-1"), children: [
|
|
26061
26062
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: HEADING2, children: "Slide" }),
|
|
26062
26063
|
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: "text-[11px] text-muted-foreground", children: [
|
|
26063
26064
|
activeSlide.elements?.length ?? 0,
|
|
@@ -26078,14 +26079,14 @@ function SlideBackgroundPanel({
|
|
|
26078
26079
|
const { t } = reactI18next.useTranslation();
|
|
26079
26080
|
const bgImageInputRef = React99.useRef(null);
|
|
26080
26081
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
26081
|
-
/* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
26082
|
+
/* @__PURE__ */ jsxRuntime.jsxs("div", { className: chunk7DGKSEIU_js.cn(CARD2, "space-y-2"), children: [
|
|
26082
26083
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: HEADING2, children: t("pptx.viewer.background") }),
|
|
26083
26084
|
/* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex items-center gap-2 text-[11px]", children: [
|
|
26084
26085
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground w-10 shrink-0", children: t("pptx.slideBackground.colour") }),
|
|
26085
26086
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
26086
26087
|
DebouncedColorInput,
|
|
26087
26088
|
{
|
|
26088
|
-
value:
|
|
26089
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(activeSlide.backgroundColor, "#ffffff"),
|
|
26089
26090
|
disabled: !canEdit,
|
|
26090
26091
|
className: "h-6 w-8 rounded border border-border bg-muted cursor-pointer",
|
|
26091
26092
|
onCommit: (hex) => onUpdateSlide({ backgroundColor: hex })
|
|
@@ -26124,7 +26125,7 @@ function SlideBackgroundPanel({
|
|
|
26124
26125
|
"button",
|
|
26125
26126
|
{
|
|
26126
26127
|
type: "button",
|
|
26127
|
-
className:
|
|
26128
|
+
className: chunk7DGKSEIU_js.cn(BTN2, "flex-1 text-center"),
|
|
26128
26129
|
disabled: !canEdit,
|
|
26129
26130
|
onClick: () => bgImageInputRef.current?.click(),
|
|
26130
26131
|
children: activeSlide.backgroundImage ? t("pptx.slideBackground.replaceImage") : t("pptx.slideBackground.chooseImage")
|
|
@@ -26157,7 +26158,7 @@ function SlideBackgroundPanel({
|
|
|
26157
26158
|
"button",
|
|
26158
26159
|
{
|
|
26159
26160
|
type: "button",
|
|
26160
|
-
className:
|
|
26161
|
+
className: chunk7DGKSEIU_js.cn(BTN2, "w-full text-center text-red-400 hover:text-red-300"),
|
|
26161
26162
|
disabled: !pptx.slideBackgroundClearState(activeSlide, canEdit).enabled,
|
|
26162
26163
|
onClick: () => onUpdateSlide(pptx.slideBackgroundClearPatch()),
|
|
26163
26164
|
children: t("pptx.slideBackground.clearBackground")
|
|
@@ -26201,14 +26202,14 @@ function TemplateBackgroundCard({
|
|
|
26201
26202
|
t("pptx.master.layout"),
|
|
26202
26203
|
t("pptx.master.master")
|
|
26203
26204
|
);
|
|
26204
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className:
|
|
26205
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: chunk7DGKSEIU_js.cn(CARD2, "space-y-2"), children: [
|
|
26205
26206
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: HEADING2, children: t("pptx.slideBackground.templateBackgroundsHeading") }),
|
|
26206
26207
|
rows.layout && /* @__PURE__ */ jsxRuntime.jsxs("label", { className: "flex items-center gap-2 text-[11px]", children: [
|
|
26207
26208
|
/* @__PURE__ */ jsxRuntime.jsx("span", { className: "text-muted-foreground w-14 shrink-0 truncate", title: rows.layout.title, children: t("pptx.master.layout") }),
|
|
26208
26209
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
26209
26210
|
DebouncedColorInput,
|
|
26210
26211
|
{
|
|
26211
|
-
value:
|
|
26212
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(onGetTemplateBackgroundColor(rows.layout.path), "#ffffff"),
|
|
26212
26213
|
disabled: !canEdit,
|
|
26213
26214
|
className: "h-6 w-8 rounded border border-border bg-muted cursor-pointer",
|
|
26214
26215
|
onCommit: (hex) => onSetTemplateBackground(rows.layout.path, hex)
|
|
@@ -26221,7 +26222,7 @@ function TemplateBackgroundCard({
|
|
|
26221
26222
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
26222
26223
|
DebouncedColorInput,
|
|
26223
26224
|
{
|
|
26224
|
-
value:
|
|
26225
|
+
value: chunk7DGKSEIU_js.normalizeHexColor(onGetTemplateBackgroundColor(rows.master.path), "#ffffff"),
|
|
26225
26226
|
disabled: !canEdit,
|
|
26226
26227
|
className: "h-6 w-8 rounded border border-border bg-muted cursor-pointer",
|
|
26227
26228
|
onCommit: (hex) => onSetTemplateBackground(rows.master.path, hex)
|
|
@@ -26332,7 +26333,7 @@ function InspectorPane(props) {
|
|
|
26332
26333
|
} = props;
|
|
26333
26334
|
const hasSelection = selectedElement !== null;
|
|
26334
26335
|
const { t } = reactI18next.useTranslation();
|
|
26335
|
-
const { dragY, handlers: dragHandlers } =
|
|
26336
|
+
const { dragY, handlers: dragHandlers } = chunkTVSTM5J5_js.useSheetDismissDrag(onClose);
|
|
26336
26337
|
const {
|
|
26337
26338
|
animationPanelHeight,
|
|
26338
26339
|
effectiveThemeOptions,
|
|
@@ -26354,7 +26355,7 @@ function InspectorPane(props) {
|
|
|
26354
26355
|
"div",
|
|
26355
26356
|
{
|
|
26356
26357
|
"data-pptx-chrome": "inspector",
|
|
26357
|
-
className:
|
|
26358
|
+
className: chunk7DGKSEIU_js.cn(
|
|
26358
26359
|
// Shared styles
|
|
26359
26360
|
"bg-background flex flex-col text-xs text-foreground shadow-xl",
|
|
26360
26361
|
// Mobile: absolute bottom sheet overlay sized via dvh so it
|
|
@@ -26745,7 +26746,7 @@ function PresentationTouchControls({
|
|
|
26745
26746
|
hideNavigation = false
|
|
26746
26747
|
}) {
|
|
26747
26748
|
const { t } = reactI18next.useTranslation();
|
|
26748
|
-
const { isTouchDevice } =
|
|
26749
|
+
const { isTouchDevice } = chunkTVSTM5J5_js.useIsMobile();
|
|
26749
26750
|
if (!isTouchDevice) {
|
|
26750
26751
|
return null;
|
|
26751
26752
|
}
|
|
@@ -27050,13 +27051,13 @@ function PrintPreview({
|
|
|
27050
27051
|
}) {
|
|
27051
27052
|
const { t } = reactI18next.useTranslation();
|
|
27052
27053
|
const pages = React99.useMemo(
|
|
27053
|
-
() =>
|
|
27054
|
+
() => chunk7DGKSEIU_js.computeHandoutLayout(slideIndices, slidesPerPage, orientation),
|
|
27054
27055
|
[slideIndices, slidesPerPage, orientation]
|
|
27055
27056
|
);
|
|
27056
|
-
const printable = React99.useMemo(() =>
|
|
27057
|
+
const printable = React99.useMemo(() => chunk7DGKSEIU_js.getPrintableArea(orientation), [orientation]);
|
|
27057
27058
|
const visiblePages = pages.slice(0, maxPages);
|
|
27058
27059
|
const isThreePerPage = slidesPerPage === 3;
|
|
27059
|
-
const noteLineCount =
|
|
27060
|
+
const noteLineCount = chunk7DGKSEIU_js.generateNoteLineCount();
|
|
27060
27061
|
const scaledW = printable.width * PREVIEW_SCALE3;
|
|
27061
27062
|
const scaledH = printable.height * PREVIEW_SCALE3;
|
|
27062
27063
|
const noteAreaFraction = 0.5;
|
|
@@ -27391,11 +27392,11 @@ function PrintDialog({
|
|
|
27391
27392
|
defaultFrameSlides
|
|
27392
27393
|
}) {
|
|
27393
27394
|
const { t } = reactI18next.useTranslation();
|
|
27394
|
-
const { panelStyle, handlers: dragHandlers } =
|
|
27395
|
-
const { viewportWidth } =
|
|
27395
|
+
const { panelStyle, handlers: dragHandlers } = chunkTVSTM5J5_js.useModalDismissDrag(onClose);
|
|
27396
|
+
const { viewportWidth } = chunkTVSTM5J5_js.useIsMobile();
|
|
27396
27397
|
const touchTargetPx = pptx.getDensePanelTouchTargetPx(viewportWidth);
|
|
27397
27398
|
const closeBtnStyle = { minWidth: touchTargetPx, minHeight: touchTargetPx };
|
|
27398
|
-
const printOptionDefaults = pptx.resolveDefaultPrintSettings(
|
|
27399
|
+
const printOptionDefaults = pptx.resolveDefaultPrintSettings(chunkTVSTM5J5_js.useViewerOptionsContext());
|
|
27399
27400
|
const [printWhat, setPrintWhat] = React99.useState(printOptionDefaults?.printWhat ?? "slides");
|
|
27400
27401
|
const [orientation, setOrientation] = React99.useState("landscape");
|
|
27401
27402
|
const [colorMode, setColorMode] = React99.useState(
|
|
@@ -27898,14 +27899,14 @@ function BroadcastDialog({
|
|
|
27898
27899
|
defaultServerUrl
|
|
27899
27900
|
}) {
|
|
27900
27901
|
const { t } = reactI18next.useTranslation();
|
|
27901
|
-
const collab =
|
|
27902
|
+
const collab = chunkTVSTM5J5_js.useCollaboration();
|
|
27902
27903
|
const isBroadcasting = collab !== null && collab.status !== "disconnected" && collab.status !== "error" && collab.config.role === "owner";
|
|
27903
27904
|
const [roomId, setRoomId] = React99.useState("");
|
|
27904
27905
|
const [userName, setUserName] = React99.useState("");
|
|
27905
27906
|
const [serverUrl, setServerUrl] = React99.useState("");
|
|
27906
27907
|
const [copied, setCopied] = React99.useState(false);
|
|
27907
27908
|
const dialogRef = React99.useRef(null);
|
|
27908
|
-
const { panelStyle, handlers: dragHandlers } =
|
|
27909
|
+
const { panelStyle, handlers: dragHandlers } = chunkTVSTM5J5_js.useModalDismissDrag(onClose);
|
|
27909
27910
|
useModalFocus(open, dialogRef, onClose);
|
|
27910
27911
|
React99.useEffect(() => {
|
|
27911
27912
|
if (open && !isBroadcasting) {
|
|
@@ -28208,7 +28209,7 @@ function ActiveSessionView({
|
|
|
28208
28209
|
onCopyRoomId,
|
|
28209
28210
|
onStopCollaboration
|
|
28210
28211
|
}) {
|
|
28211
|
-
const { t } = reactI18next.useTranslation(), viewerOptions =
|
|
28212
|
+
const { t } = reactI18next.useTranslation(), viewerOptions = chunkTVSTM5J5_js.useViewerOptionsContext(), statusColor = collab.status === "connected" ? "text-green-400" : collab.status === "connecting" ? "text-yellow-400" : "text-red-400", statusIcon = collab.status === "connected" || collab.status === "connecting" ? /* @__PURE__ */ jsxRuntime.jsx(lu.LuWifi, { className: "w-4 h-4" }) : /* @__PURE__ */ jsxRuntime.jsx(lu.LuWifiOff, { className: "w-4 h-4" }), sessionUsers = pptx.buildActiveSessionUsers({
|
|
28212
28213
|
localUserName: activeCollaboration?.userName ?? collab.config.userName,
|
|
28213
28214
|
localUserInitials: viewerOptions.general.userInitials,
|
|
28214
28215
|
localUserColor: collab.config.userColor,
|
|
@@ -28307,7 +28308,7 @@ function StartSessionForm({
|
|
|
28307
28308
|
onRetry
|
|
28308
28309
|
}) {
|
|
28309
28310
|
const { t } = reactI18next.useTranslation();
|
|
28310
|
-
const { viewportWidth } =
|
|
28311
|
+
const { viewportWidth } = chunkTVSTM5J5_js.useIsMobile();
|
|
28311
28312
|
const tabBtnStyle = { minHeight: pptx.getDensePanelTouchTargetPx(viewportWidth) };
|
|
28312
28313
|
const inputReadOnlyClass = preconfigured ? " opacity-70 cursor-not-allowed" : "";
|
|
28313
28314
|
return /* @__PURE__ */ jsxRuntime.jsxs("div", { className: "space-y-4", children: [
|
|
@@ -28441,7 +28442,7 @@ function ShareDialog({
|
|
|
28441
28442
|
defaultUserName,
|
|
28442
28443
|
defaultServerUrl
|
|
28443
28444
|
}) {
|
|
28444
|
-
const collab =
|
|
28445
|
+
const collab = chunkTVSTM5J5_js.useCollaboration();
|
|
28445
28446
|
const isActive = collab !== null && collab.status !== "disconnected" && collab.status !== "error";
|
|
28446
28447
|
const { t } = reactI18next.useTranslation();
|
|
28447
28448
|
const [roomId, setRoomId] = React99.useState(defaultRoomId ?? "");
|
|
@@ -28451,9 +28452,9 @@ function ShareDialog({
|
|
|
28451
28452
|
const [invitation, setInvitation] = React99.useState("");
|
|
28452
28453
|
const [copied, setCopied] = React99.useState(false);
|
|
28453
28454
|
const dialogRef = React99.useRef(null);
|
|
28454
|
-
const { panelStyle, handlers: dragHandlers } =
|
|
28455
|
+
const { panelStyle, handlers: dragHandlers } = chunkTVSTM5J5_js.useModalDismissDrag(onClose);
|
|
28455
28456
|
useModalFocus(open, dialogRef, onClose);
|
|
28456
|
-
const { viewportWidth, viewportHeight } =
|
|
28457
|
+
const { viewportWidth, viewportHeight } = chunkTVSTM5J5_js.useIsMobile();
|
|
28457
28458
|
const touchTargetPx = pptx.getDensePanelTouchTargetPx(viewportWidth);
|
|
28458
28459
|
const touchBtnStyle = { minWidth: touchTargetPx, minHeight: touchTargetPx };
|
|
28459
28460
|
const stickyFooterClass = pptx.shouldStickyActionRow(viewportWidth, viewportHeight) ? "sticky bottom-0 bg-popover" : "";
|
|
@@ -28736,12 +28737,12 @@ function HyperlinkEditDialog({
|
|
|
28736
28737
|
onCancel
|
|
28737
28738
|
}) {
|
|
28738
28739
|
const { t } = reactI18next.useTranslation();
|
|
28739
|
-
const { panelStyle, handlers: dragHandlers } =
|
|
28740
|
+
const { panelStyle, handlers: dragHandlers } = chunkTVSTM5J5_js.useModalDismissDrag(onCancel);
|
|
28740
28741
|
const inputRef = React99.useRef(null);
|
|
28741
|
-
const detectedType =
|
|
28742
|
-
const emailParts =
|
|
28743
|
-
const detectedSlide =
|
|
28744
|
-
const detectedVerb = initialAction ?
|
|
28742
|
+
const detectedType = chunkTVSTM5J5_js.detectTargetType(initialUrl, initialAction);
|
|
28743
|
+
const emailParts = chunkTVSTM5J5_js.parseEmailUrl(initialUrl || "");
|
|
28744
|
+
const detectedSlide = chunkTVSTM5J5_js.parseSlideFromUrl(initialUrl, initialAction);
|
|
28745
|
+
const detectedVerb = initialAction ? chunkTVSTM5J5_js.ACTION_VERB_MAP[initialAction.toLowerCase()] || "nextSlide" : "nextSlide";
|
|
28745
28746
|
const [targetType, setTargetType] = React99.useState(detectedType);
|
|
28746
28747
|
const [url, setUrl] = React99.useState(
|
|
28747
28748
|
detectedType === "email" || detectedType === "slide" || detectedType === "action" ? "" : initialUrl || ""
|
|
@@ -28772,7 +28773,7 @@ function HyperlinkEditDialog({
|
|
|
28772
28773
|
actionVerb
|
|
28773
28774
|
});
|
|
28774
28775
|
};
|
|
28775
|
-
const tabCls = (active) =>
|
|
28776
|
+
const tabCls = (active) => chunk7DGKSEIU_js.cn(
|
|
28776
28777
|
"px-3 py-1.5 text-xs rounded-t border-b-2 transition-colors",
|
|
28777
28778
|
active ? "border-primary text-primary font-medium" : "border-transparent text-muted-foreground hover:text-foreground hover:border-border"
|
|
28778
28779
|
);
|
|
@@ -29009,7 +29010,7 @@ function ViewerBottomPanels({
|
|
|
29009
29010
|
notesStyle,
|
|
29010
29011
|
onNotesHeightChange
|
|
29011
29012
|
}) {
|
|
29012
|
-
const { isHidden } =
|
|
29013
|
+
const { isHidden } = chunkTVSTM5J5_js.useToolbarVisibility(hiddenActions);
|
|
29013
29014
|
const customization = useViewerCustomizationContext();
|
|
29014
29015
|
const showNotes = pptx.isPanelVisible(customization, "notes");
|
|
29015
29016
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
@@ -29355,7 +29356,7 @@ function ViewerToolbarSection(props) {
|
|
|
29355
29356
|
[activeSlide, propertyHandlers]
|
|
29356
29357
|
);
|
|
29357
29358
|
const scopedLayoutOptions = React99__default.default.useMemo(
|
|
29358
|
-
() =>
|
|
29359
|
+
() => chunkTVSTM5J5_js.scopeLayoutOptionsToActiveSlide(s.layoutOptions, activeSlide),
|
|
29359
29360
|
[s.layoutOptions, activeSlide]
|
|
29360
29361
|
);
|
|
29361
29362
|
const handleResetSlide = React99.useCallback(() => {
|
|
@@ -29759,7 +29760,7 @@ function ViewerToolbarSection(props) {
|
|
|
29759
29760
|
isCommentsPanelOpen: s.isInspectorPaneOpen,
|
|
29760
29761
|
slideCommentCount: activeSlide?.comments?.length ?? 0,
|
|
29761
29762
|
formatPainterActive: s.formatPainterActive,
|
|
29762
|
-
canActivateFormatPainter:
|
|
29763
|
+
canActivateFormatPainter: chunk7DGKSEIU_js.hasCopyableFormat(selectedElement),
|
|
29763
29764
|
onToggleFormatPainter: onToggleFormatPainterProp ?? (() => s.setFormatPainterActive((p) => !p)),
|
|
29764
29765
|
isSelectionPaneOpen: s.isSelectionPaneOpen,
|
|
29765
29766
|
onToggleSelectionPane: () => s.setIsSelectionPaneOpen((p) => !p),
|
|
@@ -29846,7 +29847,7 @@ function EquationEditorDialog({
|
|
|
29846
29847
|
existingOmml
|
|
29847
29848
|
}) {
|
|
29848
29849
|
const { t } = reactI18next.useTranslation();
|
|
29849
|
-
const { panelStyle, handlers: dragHandlers } =
|
|
29850
|
+
const { panelStyle, handlers: dragHandlers } = chunkTVSTM5J5_js.useModalDismissDrag(onClose);
|
|
29850
29851
|
const initialLatex = React99.useMemo(() => {
|
|
29851
29852
|
if (!existingOmml) {
|
|
29852
29853
|
return "";
|
|
@@ -29968,7 +29969,7 @@ function EquationEditorDialog({
|
|
|
29968
29969
|
{
|
|
29969
29970
|
type: "button",
|
|
29970
29971
|
onClick: () => handleTemplateClick(tmpl.latex),
|
|
29971
|
-
className:
|
|
29972
|
+
className: chunk7DGKSEIU_js.cn(
|
|
29972
29973
|
"flex flex-col items-center gap-1 p-2 rounded-lg border transition-colors",
|
|
29973
29974
|
latex === tmpl.latex ? "border-primary bg-primary/10" : "border-border bg-muted/40 hover:bg-accent/60 hover:border-border"
|
|
29974
29975
|
),
|
|
@@ -30034,7 +30035,7 @@ function getPreviewForLayout(layout) {
|
|
|
30034
30035
|
transform: `scale(${scale})`,
|
|
30035
30036
|
transformOrigin: "top left"
|
|
30036
30037
|
},
|
|
30037
|
-
children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
30038
|
+
children: /* @__PURE__ */ jsxRuntime.jsx(chunkTVSTM5J5_js.SmartArtRenderer, { element: pptx.buildSmartArtPreviewElement(layout) })
|
|
30038
30039
|
}
|
|
30039
30040
|
)
|
|
30040
30041
|
}
|
|
@@ -30046,7 +30047,7 @@ function InsertSmartArtDialog({
|
|
|
30046
30047
|
onInsert
|
|
30047
30048
|
}) {
|
|
30048
30049
|
const { t } = reactI18next.useTranslation();
|
|
30049
|
-
const { panelStyle, handlers: dragHandlers } =
|
|
30050
|
+
const { panelStyle, handlers: dragHandlers } = chunkTVSTM5J5_js.useModalDismissDrag(onClose);
|
|
30050
30051
|
const [activeCategory, setActiveCategory] = React99.useState("list");
|
|
30051
30052
|
const [selectedLayout, setSelectedLayout] = React99.useState(null);
|
|
30052
30053
|
const dialogRef = React99.useRef(null);
|
|
@@ -30127,7 +30128,7 @@ function InsertSmartArtDialog({
|
|
|
30127
30128
|
setActiveCategory(cat.id);
|
|
30128
30129
|
setSelectedLayout(null);
|
|
30129
30130
|
},
|
|
30130
|
-
className:
|
|
30131
|
+
className: chunk7DGKSEIU_js.cn(
|
|
30131
30132
|
"w-full text-left px-3 py-1.5 text-xs transition-colors",
|
|
30132
30133
|
activeCategory === cat.id ? "bg-primary text-white" : "text-foreground hover:bg-muted"
|
|
30133
30134
|
),
|
|
@@ -30155,7 +30156,7 @@ function InsertSmartArtDialog({
|
|
|
30155
30156
|
onInsert(preset.layout, preset.defaultItems);
|
|
30156
30157
|
onClose();
|
|
30157
30158
|
},
|
|
30158
|
-
className:
|
|
30159
|
+
className: chunk7DGKSEIU_js.cn(
|
|
30159
30160
|
"flex flex-col items-center gap-1 p-2 rounded border transition-colors",
|
|
30160
30161
|
selectedLayout === preset.layout ? "border-primary bg-primary/20" : "border-border hover:border-border hover:bg-muted/50"
|
|
30161
30162
|
),
|
|
@@ -30652,11 +30653,11 @@ function PresentationStage({
|
|
|
30652
30653
|
})
|
|
30653
30654
|
},
|
|
30654
30655
|
children: [
|
|
30655
|
-
/* @__PURE__ */ jsxRuntime.jsx(
|
|
30656
|
+
/* @__PURE__ */ jsxRuntime.jsx(chunkTVSTM5J5_js.SlideBackgroundImageLayer, { slide: activeSlide }),
|
|
30656
30657
|
/* @__PURE__ */ jsxRuntime.jsx("style", { children: pptx.PRESENTATION_HIT_TEST_CSS }),
|
|
30657
30658
|
presentationKeyframesCss && /* @__PURE__ */ jsxRuntime.jsx("style", { children: presentationKeyframesCss }),
|
|
30658
30659
|
templateElements.map((element, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
30659
|
-
|
|
30660
|
+
chunkTVSTM5J5_js.ElementRenderer,
|
|
30660
30661
|
{
|
|
30661
30662
|
element,
|
|
30662
30663
|
activeSlide,
|
|
@@ -30693,7 +30694,7 @@ function PresentationStage({
|
|
|
30693
30694
|
`tpl-${element.id}`
|
|
30694
30695
|
)),
|
|
30695
30696
|
activeSlide?.elements.map((element, index) => /* @__PURE__ */ jsxRuntime.jsx(
|
|
30696
|
-
|
|
30697
|
+
chunkTVSTM5J5_js.ElementRenderer,
|
|
30697
30698
|
{
|
|
30698
30699
|
element,
|
|
30699
30700
|
activeSlide,
|
|
@@ -30814,8 +30815,8 @@ function ViewerCanvasArea(props) {
|
|
|
30814
30815
|
aiCanvasActive = false
|
|
30815
30816
|
} = props;
|
|
30816
30817
|
const { t } = reactI18next.useTranslation();
|
|
30817
|
-
const { isHidden } =
|
|
30818
|
-
const viewerOptions =
|
|
30818
|
+
const { isHidden } = chunkTVSTM5J5_js.useToolbarVisibility(hiddenActions);
|
|
30819
|
+
const viewerOptions = chunkTVSTM5J5_js.useViewerOptionsContext();
|
|
30819
30820
|
const outlineAuthoring = useOutlineAuthoring({
|
|
30820
30821
|
state: s,
|
|
30821
30822
|
updateElement: canvasHandlers.handleUpdateSmartArtElement,
|
|
@@ -30844,7 +30845,7 @@ function ViewerCanvasArea(props) {
|
|
|
30844
30845
|
${url}`)) {
|
|
30845
30846
|
return;
|
|
30846
30847
|
}
|
|
30847
|
-
|
|
30848
|
+
chunk7DGKSEIU_js.safeOpenUrl(url);
|
|
30848
30849
|
},
|
|
30849
30850
|
[viewerOptions, t]
|
|
30850
30851
|
);
|
|
@@ -30865,9 +30866,9 @@ ${url}`)) {
|
|
|
30865
30866
|
);
|
|
30866
30867
|
const handleHyperlinkClick = React99.useCallback(
|
|
30867
30868
|
(url) => {
|
|
30868
|
-
if (
|
|
30869
|
+
if (chunk7DGKSEIU_js.isPpactionUrl(url)) {
|
|
30869
30870
|
if (mode === "present") {
|
|
30870
|
-
const parsed =
|
|
30871
|
+
const parsed = chunk7DGKSEIU_js.parsePpactionUrl(url);
|
|
30871
30872
|
if (parsed) {
|
|
30872
30873
|
const action = {
|
|
30873
30874
|
action: parsed.action,
|
|
@@ -30952,7 +30953,7 @@ ${url}`)) {
|
|
|
30952
30953
|
s.setActiveSlideIndex((i) => Math.max(0, i - 1));
|
|
30953
30954
|
}
|
|
30954
30955
|
}, [mode, presentation, s]);
|
|
30955
|
-
const swipe =
|
|
30956
|
+
const swipe = chunkTVSTM5J5_js.useSwipeNavigation({
|
|
30956
30957
|
enabled: swipeEnabled,
|
|
30957
30958
|
onNext: handleSwipeNext,
|
|
30958
30959
|
onPrev: handleSwipePrev
|
|
@@ -31026,7 +31027,7 @@ ${url}`)) {
|
|
|
31026
31027
|
),
|
|
31027
31028
|
children: (stageScale) => /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
31028
31029
|
presentation.transitionOverlay && slides[presentation.transitionOverlay.outgoingSlideIndex] && /* @__PURE__ */ jsxRuntime.jsx(
|
|
31029
|
-
|
|
31030
|
+
chunkTVSTM5J5_js.PresentationTransitionOverlay,
|
|
31030
31031
|
{
|
|
31031
31032
|
outgoingSlide: slides[presentation.transitionOverlay.outgoingSlideIndex],
|
|
31032
31033
|
templateElements,
|
|
@@ -31137,14 +31138,14 @@ ${url}`)) {
|
|
|
31137
31138
|
outlineAuthoring,
|
|
31138
31139
|
collaborationOverlay: /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
31139
31140
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
31140
|
-
|
|
31141
|
+
chunkTVSTM5J5_js.RemoteSelectionOverlay,
|
|
31141
31142
|
{
|
|
31142
31143
|
elements: effectiveSlide?.elements ?? [],
|
|
31143
31144
|
activeSlideIndex
|
|
31144
31145
|
}
|
|
31145
31146
|
),
|
|
31146
31147
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
31147
|
-
|
|
31148
|
+
chunkTVSTM5J5_js.CollaborationCursorOverlay,
|
|
31148
31149
|
{
|
|
31149
31150
|
activeSlideIndex,
|
|
31150
31151
|
canvasWidth: canvasSize.width,
|
|
@@ -31284,7 +31285,7 @@ function useTableStyleMapHandlers(input) {
|
|
|
31284
31285
|
var AiChatPanel = React99.lazy(async () => {
|
|
31285
31286
|
const [{ useChat }, { default: Panel }] = await Promise.all([
|
|
31286
31287
|
import('@ai-sdk/react'),
|
|
31287
|
-
import('./AiChatPanel-
|
|
31288
|
+
import('./AiChatPanel-ONHWZEPV.js')
|
|
31288
31289
|
]);
|
|
31289
31290
|
function BoundAiChatPanel(props) {
|
|
31290
31291
|
return /* @__PURE__ */ jsxRuntime.jsx(Panel, { ...props, useChat });
|
|
@@ -31445,7 +31446,7 @@ function MobileDismissSheet({
|
|
|
31445
31446
|
children
|
|
31446
31447
|
}) {
|
|
31447
31448
|
const { t } = reactI18next.useTranslation();
|
|
31448
|
-
const { dragY, handlers } =
|
|
31449
|
+
const { dragY, handlers } = chunkTVSTM5J5_js.useSheetDismissDrag(onClose);
|
|
31449
31450
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
31450
31451
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
31451
31452
|
"button",
|
|
@@ -31714,7 +31715,7 @@ function ThemeThumbnail({
|
|
|
31714
31715
|
{
|
|
31715
31716
|
type: "button",
|
|
31716
31717
|
onClick,
|
|
31717
|
-
className:
|
|
31718
|
+
className: chunk7DGKSEIU_js.cn(
|
|
31718
31719
|
"group relative flex flex-col rounded-lg border-2 transition-all overflow-hidden",
|
|
31719
31720
|
selected ? "border-primary shadow-lg scale-[1.02]" : "border-border hover:border-primary/50 hover:shadow-md"
|
|
31720
31721
|
),
|
|
@@ -31900,7 +31901,7 @@ function ViewerSidePanels(props) {
|
|
|
31900
31901
|
const customization = useViewerCustomizationContext();
|
|
31901
31902
|
const inspectorOpen = (mode === "edit" || mode === "master") && s.isInspectorPaneOpen && pptx.isPanelVisible(customization, "inspector");
|
|
31902
31903
|
const currentBuiltInTheme = BUILT_IN_THEMES.find(
|
|
31903
|
-
(candidate) => (0,
|
|
31904
|
+
(candidate) => (0, chunk7DGKSEIU_js.dist_exports.themeColorSchemesEqual)(s.theme?.colorScheme, candidate.colorScheme)
|
|
31904
31905
|
) ?? null;
|
|
31905
31906
|
return /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
31906
31907
|
inspectorOpen && onResizeRight && /* @__PURE__ */ jsxRuntime.jsx(ResizeHandle, { direction: "horizontal", onResize: onResizeRight }),
|
|
@@ -32186,7 +32187,7 @@ function ViewerMainContent(props) {
|
|
|
32186
32187
|
);
|
|
32187
32188
|
const layoutGalleryAnchorRef = React99.useRef(null);
|
|
32188
32189
|
const layoutGalleryPreviews = useLayoutPreviews(loadLayoutPreviews, layoutGalleryAnchor !== null);
|
|
32189
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
32190
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkTVSTM5J5_js.ChartPartSelectionProvider, { children: /* @__PURE__ */ jsxRuntime.jsxs("div", { "data-pptx-chrome": "body", className: "relative z-10 flex flex-1 min-h-0", children: [
|
|
32190
32191
|
showSlidesPane && /* @__PURE__ */ jsxRuntime.jsxs(jsxRuntime.Fragment, { children: [
|
|
32191
32192
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
32192
32193
|
SlidesPaneSidebar,
|
|
@@ -32676,7 +32677,7 @@ function MobileChromeOverlay(props) {
|
|
|
32676
32677
|
slideSectionGroups,
|
|
32677
32678
|
canEdit,
|
|
32678
32679
|
commentCount
|
|
32679
|
-
} = props, { keyboardInset, isKeyboardOpen } =
|
|
32680
|
+
} = props, { keyboardInset, isKeyboardOpen } = chunkTVSTM5J5_js.useKeyboardInsets(), activeSheet = s.isSlidesPaneOpen ? "slides" : s.isInspectorPaneOpen ? s.sidebarPanelMode === "comments" ? "comments" : "inspector" : !s.isSlideNotesCollapsed ? "notes" : null, closeAllSheets = () => {
|
|
32680
32681
|
s.setIsSlidesPaneOpen(false);
|
|
32681
32682
|
s.setIsInspectorPaneOpen(false);
|
|
32682
32683
|
s.setIsSlideNotesCollapsed(true);
|
|
@@ -32882,7 +32883,7 @@ function AddinTable({
|
|
|
32882
32883
|
"tr",
|
|
32883
32884
|
{
|
|
32884
32885
|
onClick: () => onSelect(row.id),
|
|
32885
|
-
className:
|
|
32886
|
+
className: chunk7DGKSEIU_js.cn(
|
|
32886
32887
|
"cursor-pointer border-b border-border/40 transition-colors",
|
|
32887
32888
|
selectedId === row.id ? "bg-primary/10" : "hover:bg-accent"
|
|
32888
32889
|
),
|
|
@@ -32949,18 +32950,18 @@ function ControlRow({
|
|
|
32949
32950
|
onOptionChange: emitChange
|
|
32950
32951
|
}) {
|
|
32951
32952
|
const { t } = reactI18next.useTranslation();
|
|
32952
|
-
const { viewportWidth } =
|
|
32953
|
+
const { viewportWidth } = chunkTVSTM5J5_js.useIsMobile();
|
|
32953
32954
|
const fieldMinHeight = pptx.getDensePanelTouchTargetPx(viewportWidth);
|
|
32954
32955
|
const value = readValue(options, control);
|
|
32955
32956
|
const label = t(control.labelKey);
|
|
32956
32957
|
const info = control.infoKey ? /* @__PURE__ */ jsxRuntime.jsx(InfoTip, { text: t(control.infoKey) }) : null;
|
|
32957
|
-
const rowClass =
|
|
32958
|
+
const rowClass = chunk7DGKSEIU_js.cn("flex items-center justify-between gap-3 py-1.5", control.indent && "pl-6");
|
|
32958
32959
|
const rowStyle = { minHeight: fieldMinHeight };
|
|
32959
32960
|
const locked = control.readOnly === true;
|
|
32960
32961
|
const lockedTitle = locked ? t("pptx.options.lockedByHost") : void 0;
|
|
32961
32962
|
const onOptionChange = locked ? IGNORE_CHANGE : emitChange;
|
|
32962
32963
|
if (control.kind === "toggle") {
|
|
32963
|
-
return /* @__PURE__ */ jsxRuntime.jsxs("label", { className:
|
|
32964
|
+
return /* @__PURE__ */ jsxRuntime.jsxs("label", { className: chunk7DGKSEIU_js.cn(rowClass, "cursor-pointer select-none"), style: rowStyle, children: [
|
|
32964
32965
|
/* @__PURE__ */ jsxRuntime.jsxs("span", { className: "text-sm text-foreground", children: [
|
|
32965
32966
|
label,
|
|
32966
32967
|
info
|
|
@@ -33112,7 +33113,7 @@ function CommandList({
|
|
|
33112
33113
|
role: "option",
|
|
33113
33114
|
"aria-selected": selectedId === id,
|
|
33114
33115
|
onClick: () => onSelect(id),
|
|
33115
|
-
className:
|
|
33116
|
+
className: chunk7DGKSEIU_js.cn(
|
|
33116
33117
|
"flex w-full items-center rounded px-2 py-1.5 text-left text-sm transition-colors",
|
|
33117
33118
|
selectedId === id ? "bg-primary/15 text-primary" : "text-foreground hover:bg-accent"
|
|
33118
33119
|
),
|
|
@@ -33256,7 +33257,7 @@ function OptionsRibbonPane({
|
|
|
33256
33257
|
return /* @__PURE__ */ jsxRuntime.jsxs(
|
|
33257
33258
|
"label",
|
|
33258
33259
|
{
|
|
33259
|
-
className:
|
|
33260
|
+
className: chunk7DGKSEIU_js.cn(
|
|
33260
33261
|
"flex items-center gap-2 rounded px-2 py-1.5",
|
|
33261
33262
|
isFile ? "cursor-not-allowed opacity-60" : "cursor-pointer hover:bg-accent"
|
|
33262
33263
|
),
|
|
@@ -33290,7 +33291,7 @@ function OptionsRibbonPane({
|
|
|
33290
33291
|
/* @__PURE__ */ jsxRuntime.jsx("div", { className: "space-y-0.5", children: pptx.SHORTCUT_REFERENCE_ITEMS.map((shortcut, i) => /* @__PURE__ */ jsxRuntime.jsxs(
|
|
33291
33292
|
"div",
|
|
33292
33293
|
{
|
|
33293
|
-
className:
|
|
33294
|
+
className: chunk7DGKSEIU_js.cn(
|
|
33294
33295
|
"flex items-center justify-between gap-3 rounded px-3 py-2",
|
|
33295
33296
|
i % 2 === 0 ? "bg-muted/60" : ""
|
|
33296
33297
|
),
|
|
@@ -33311,7 +33312,7 @@ async function exportAiChatLogs(options) {
|
|
|
33311
33312
|
chats,
|
|
33312
33313
|
{ format: options?.format, detailed: options?.detailed, now: options?.now },
|
|
33313
33314
|
(filename, content, mime) => {
|
|
33314
|
-
|
|
33315
|
+
chunkTVSTM5J5_js.downloadBlob(new Blob([content], { type: mime }), filename);
|
|
33315
33316
|
}
|
|
33316
33317
|
);
|
|
33317
33318
|
}
|
|
@@ -33419,7 +33420,7 @@ function SettingsAppearanceTab({
|
|
|
33419
33420
|
type: "button",
|
|
33420
33421
|
onClick: () => onSelectTheme(entry.key),
|
|
33421
33422
|
"aria-pressed": isActive,
|
|
33422
|
-
className:
|
|
33423
|
+
className: chunk7DGKSEIU_js.cn(
|
|
33423
33424
|
"flex items-center gap-3 rounded-lg border px-3 py-2.5 text-left transition-colors",
|
|
33424
33425
|
isActive ? "border-primary bg-primary/10" : "border-border hover:border-primary/50 hover:bg-accent"
|
|
33425
33426
|
),
|
|
@@ -33436,7 +33437,7 @@ function SettingsAppearanceTab({
|
|
|
33436
33437
|
/* @__PURE__ */ jsxRuntime.jsx(
|
|
33437
33438
|
"span",
|
|
33438
33439
|
{
|
|
33439
|
-
className:
|
|
33440
|
+
className: chunk7DGKSEIU_js.cn("text-xs font-medium", isActive ? "text-primary" : "text-foreground"),
|
|
33440
33441
|
children: t(entry.labelKey)
|
|
33441
33442
|
}
|
|
33442
33443
|
)
|
|
@@ -33516,7 +33517,7 @@ function SettingsLanguageTab({
|
|
|
33516
33517
|
type: "button",
|
|
33517
33518
|
onClick: () => onSelectLocale(locale.code),
|
|
33518
33519
|
"aria-pressed": isActive,
|
|
33519
|
-
className:
|
|
33520
|
+
className: chunk7DGKSEIU_js.cn(
|
|
33520
33521
|
"flex w-full items-center justify-between rounded px-3 py-2.5 text-left transition-colors",
|
|
33521
33522
|
isActive ? "bg-primary/10 text-primary" : "text-foreground hover:bg-accent"
|
|
33522
33523
|
),
|
|
@@ -33556,8 +33557,8 @@ function SettingsDialog({
|
|
|
33556
33557
|
const [activeTabId, setActiveTabId] = React99.useState("general");
|
|
33557
33558
|
const { t } = reactI18next.useTranslation();
|
|
33558
33559
|
const customization = useViewerCustomizationContext();
|
|
33559
|
-
const { panelStyle, handlers: dragHandlers } =
|
|
33560
|
-
const { viewportWidth, viewportHeight } =
|
|
33560
|
+
const { panelStyle, handlers: dragHandlers } = chunkTVSTM5J5_js.useModalDismissDrag(onClose);
|
|
33561
|
+
const { viewportWidth, viewportHeight } = chunkTVSTM5J5_js.useIsMobile();
|
|
33561
33562
|
const touchTargetPx = pptx.getDensePanelTouchTargetPx(viewportWidth);
|
|
33562
33563
|
const navBtnStyle = { minHeight: touchTargetPx, minWidth: touchTargetPx };
|
|
33563
33564
|
const closeBtnStyle = { minWidth: touchTargetPx, minHeight: touchTargetPx };
|
|
@@ -33665,7 +33666,7 @@ function SettingsDialog({
|
|
|
33665
33666
|
onClick: () => setActiveTabId(tab.id),
|
|
33666
33667
|
"aria-current": currentTabId === tab.id,
|
|
33667
33668
|
style: navBtnStyle,
|
|
33668
|
-
className:
|
|
33669
|
+
className: chunk7DGKSEIU_js.cn(
|
|
33669
33670
|
"flex w-full items-center whitespace-nowrap rounded px-3 py-2 text-left text-sm transition-colors max-md:w-auto",
|
|
33670
33671
|
currentTabId === tab.id ? "bg-primary/10 font-medium text-primary" : "text-foreground hover:bg-accent"
|
|
33671
33672
|
),
|
|
@@ -33680,7 +33681,7 @@ function SettingsDialog({
|
|
|
33680
33681
|
onClick: () => setActiveTabId(AI_TAB_ID),
|
|
33681
33682
|
"aria-current": aiActive,
|
|
33682
33683
|
style: navBtnStyle,
|
|
33683
|
-
className:
|
|
33684
|
+
className: chunk7DGKSEIU_js.cn(
|
|
33684
33685
|
"flex w-full items-center whitespace-nowrap rounded px-3 py-2 text-left text-sm transition-colors max-md:w-auto",
|
|
33685
33686
|
aiActive ? "bg-primary/10 font-medium text-primary" : "text-foreground hover:bg-accent"
|
|
33686
33687
|
),
|
|
@@ -33826,7 +33827,7 @@ function ViewerOptionsProvider({
|
|
|
33826
33827
|
store,
|
|
33827
33828
|
children
|
|
33828
33829
|
}) {
|
|
33829
|
-
return /* @__PURE__ */ jsxRuntime.jsx(
|
|
33830
|
+
return /* @__PURE__ */ jsxRuntime.jsx(chunkTVSTM5J5_js.ViewerOptionsStoreContext.Provider, { value: store, children: /* @__PURE__ */ jsxRuntime.jsx(chunkTVSTM5J5_js.ViewerOptionsContext.Provider, { value: options, children }) });
|
|
33830
33831
|
}
|
|
33831
33832
|
function useAiBridge(input) {
|
|
33832
33833
|
const ref = React99.useRef(input);
|
|
@@ -34147,7 +34148,7 @@ function useMasterViewCrud(input) {
|
|
|
34147
34148
|
if (id === "renameLayout" || id === "renameMaster") {
|
|
34148
34149
|
const master = slideMasters[target.masterIndex];
|
|
34149
34150
|
const current = id === "renameLayout" ? master?.layouts?.[target.layoutIndex ?? -1]?.name ?? "" : master?.name ?? "";
|
|
34150
|
-
const next =
|
|
34151
|
+
const next = chunkTVSTM5J5_js.safePrompt(t("pptx.masterView.renamePrompt"), current)?.trim();
|
|
34151
34152
|
if (!next) {
|
|
34152
34153
|
return;
|
|
34153
34154
|
}
|
|
@@ -34608,7 +34609,7 @@ var PowerPointViewer = React99.forwardRef(
|
|
|
34608
34609
|
}
|
|
34609
34610
|
})();
|
|
34610
34611
|
}, []);
|
|
34611
|
-
const { optionsStore, options: viewerOptions } =
|
|
34612
|
+
const { optionsStore, options: viewerOptions } = chunkTVSTM5J5_js.useViewerOptions();
|
|
34612
34613
|
const custom = useViewerCustomization(customization, legacyHiddenActions, optionsStore);
|
|
34613
34614
|
const { resolved: customizationResolved, hiddenActions } = custom;
|
|
34614
34615
|
const aiEnabled = Boolean(ai) && pptx.isFeatureEnabled(customizationResolved, "ai");
|
|
@@ -34622,8 +34623,8 @@ var PowerPointViewer = React99.forwardRef(
|
|
|
34622
34623
|
const handleEnableEditing = React99.useCallback(() => {
|
|
34623
34624
|
setProtectedViewOverridden(true);
|
|
34624
34625
|
}, []);
|
|
34625
|
-
const readOnlyRec =
|
|
34626
|
-
const compatToastsState =
|
|
34626
|
+
const readOnlyRec = chunkTVSTM5J5_js.useReadOnlyRecommendationState(content);
|
|
34627
|
+
const compatToastsState = chunkTVSTM5J5_js.useCompatibilityToastsState();
|
|
34627
34628
|
const [notesBarHeight, setNotesBarHeight] = React99.useState(0);
|
|
34628
34629
|
const runProgramNoticesState = useRunProgramNoticesState();
|
|
34629
34630
|
const [collaborationReadOnly, setCollaborationReadOnly] = React99.useState(Boolean(collaboration));
|
|
@@ -34638,8 +34639,8 @@ var PowerPointViewer = React99.forwardRef(
|
|
|
34638
34639
|
filePath
|
|
34639
34640
|
});
|
|
34640
34641
|
const [isShareDialogOpen, setIsShareDialogOpen] = React99.useState(false);
|
|
34641
|
-
const { reducedMotion, toggleReducedMotion } =
|
|
34642
|
-
const state =
|
|
34642
|
+
const { reducedMotion, toggleReducedMotion } = chunkTVSTM5J5_js.useReducedMotion();
|
|
34643
|
+
const state = chunkTVSTM5J5_js.useViewerState({ content, canEdit });
|
|
34643
34644
|
const {
|
|
34644
34645
|
containerRef,
|
|
34645
34646
|
mode,
|
|
@@ -34664,7 +34665,7 @@ var PowerPointViewer = React99.forwardRef(
|
|
|
34664
34665
|
[state.recentColors, pushColor]
|
|
34665
34666
|
);
|
|
34666
34667
|
const themeColorMapValue = React99.useMemo(
|
|
34667
|
-
() => state.theme?.colorScheme ? (0,
|
|
34668
|
+
() => state.theme?.colorScheme ? (0, chunk7DGKSEIU_js.dist_exports.buildThemeColorMap)(state.theme.colorScheme) : void 0,
|
|
34668
34669
|
[state.theme?.colorScheme]
|
|
34669
34670
|
);
|
|
34670
34671
|
const settings = React99.useMemo(
|
|
@@ -34751,16 +34752,16 @@ var PowerPointViewer = React99.forwardRef(
|
|
|
34751
34752
|
}
|
|
34752
34753
|
}, [settings, optionsStore]);
|
|
34753
34754
|
const handleClearOptionsCache2 = useAutosaveCacheMaintenance(viewerOptions);
|
|
34754
|
-
const mobile =
|
|
34755
|
+
const mobile = chunkTVSTM5J5_js.useIsMobile();
|
|
34755
34756
|
const { isMobile, isTouchDevice, isVirtualKeyboardOpen } = mobile;
|
|
34756
|
-
const resizablePanels =
|
|
34757
|
+
const resizablePanels = chunkTVSTM5J5_js.useResizablePanels();
|
|
34757
34758
|
const {
|
|
34758
34759
|
gridSpacingPx,
|
|
34759
34760
|
visibleSlideIndexes,
|
|
34760
34761
|
slideSectionGroups,
|
|
34761
34762
|
masterPseudoSlide,
|
|
34762
34763
|
authoredRange
|
|
34763
|
-
} =
|
|
34764
|
+
} = chunkTVSTM5J5_js.useDerivedSlideState({
|
|
34764
34765
|
slides,
|
|
34765
34766
|
sections: state.sections,
|
|
34766
34767
|
customShows: state.customShows,
|
|
@@ -34785,7 +34786,7 @@ var PowerPointViewer = React99.forwardRef(
|
|
|
34785
34786
|
state.cropSessionRef
|
|
34786
34787
|
]
|
|
34787
34788
|
);
|
|
34788
|
-
const zoom =
|
|
34789
|
+
const zoom = chunkTVSTM5J5_js.useZoomViewport({
|
|
34789
34790
|
canvasSize,
|
|
34790
34791
|
selectedElements: state.selectedElements,
|
|
34791
34792
|
fitPadding: props.fitPadding,
|
|
@@ -34795,7 +34796,7 @@ var PowerPointViewer = React99.forwardRef(
|
|
|
34795
34796
|
const markDocumentDirty = React99.useCallback(() => {
|
|
34796
34797
|
setIsDirty(true);
|
|
34797
34798
|
}, [setIsDirty]);
|
|
34798
|
-
const history =
|
|
34799
|
+
const history = chunkTVSTM5J5_js.useEditorHistory({
|
|
34799
34800
|
slides,
|
|
34800
34801
|
canvasSize,
|
|
34801
34802
|
activeSlideIndex,
|
|
@@ -34821,7 +34822,7 @@ var PowerPointViewer = React99.forwardRef(
|
|
|
34821
34822
|
setEditTemplateMode: state.setEditTemplateMode,
|
|
34822
34823
|
setHeaderFooter: state.setHeaderFooter
|
|
34823
34824
|
});
|
|
34824
|
-
const { presentation, annotations, actionSoundHandlerRef, setExitModeHandler } =
|
|
34825
|
+
const { presentation, annotations, actionSoundHandlerRef, setExitModeHandler } = chunkTVSTM5J5_js.usePresentationSetup({
|
|
34825
34826
|
mode,
|
|
34826
34827
|
slides,
|
|
34827
34828
|
visibleSlideIndexes,
|
|
@@ -34896,7 +34897,7 @@ ${url}`)
|
|
|
34896
34897
|
loading,
|
|
34897
34898
|
error
|
|
34898
34899
|
]);
|
|
34899
|
-
|
|
34900
|
+
chunkTVSTM5J5_js.useTouchGestures({
|
|
34900
34901
|
targetRef: zoom.canvasViewportRef,
|
|
34901
34902
|
currentScale: zoom.scale,
|
|
34902
34903
|
callbacks: {
|
|
@@ -34918,7 +34919,7 @@ ${url}`)
|
|
|
34918
34919
|
},
|
|
34919
34920
|
enabled: isTouchDevice
|
|
34920
34921
|
});
|
|
34921
|
-
const dialogs =
|
|
34922
|
+
const dialogs = chunkTVSTM5J5_js.useViewerDialogs({
|
|
34922
34923
|
mode,
|
|
34923
34924
|
slides,
|
|
34924
34925
|
activeSlide,
|
|
@@ -34967,7 +34968,7 @@ ${url}`)
|
|
|
34967
34968
|
zoom.handleZoomToFit();
|
|
34968
34969
|
zoom.canvasViewportRef.current?.scrollTo({ left: 0, top: 0 });
|
|
34969
34970
|
}, [mode]);
|
|
34970
|
-
const editorOps =
|
|
34971
|
+
const editorOps = chunkTVSTM5J5_js.useEditorOperations({
|
|
34971
34972
|
state,
|
|
34972
34973
|
history,
|
|
34973
34974
|
zoom,
|
|
@@ -35009,7 +35010,7 @@ ${url}`)
|
|
|
35009
35010
|
setIsEncryptedDialogOpen,
|
|
35010
35011
|
handlerRef,
|
|
35011
35012
|
loadVersion
|
|
35012
|
-
} =
|
|
35013
|
+
} = chunkTVSTM5J5_js.useViewerIntegration({
|
|
35013
35014
|
transformCommittedText: (text) => pptx.applyAutoCorrect(text, viewerOptions.proofing),
|
|
35014
35015
|
state,
|
|
35015
35016
|
zoom,
|
|
@@ -35083,7 +35084,7 @@ ${url}`)
|
|
|
35083
35084
|
updateThemeFontScheme: themeHandlers.handleUpdateThemeFontScheme
|
|
35084
35085
|
});
|
|
35085
35086
|
const ribbonScope = useRibbonScopeToken();
|
|
35086
|
-
const viewPreferencesSync =
|
|
35087
|
+
const viewPreferencesSync = chunkTVSTM5J5_js.useViewPreferencesSync({
|
|
35087
35088
|
loadVersion,
|
|
35088
35089
|
viewProperties: state.viewProperties,
|
|
35089
35090
|
setViewProperties: state.setViewProperties,
|
|
@@ -35121,7 +35122,7 @@ ${url}`)
|
|
|
35121
35122
|
},
|
|
35122
35123
|
[state]
|
|
35123
35124
|
);
|
|
35124
|
-
const layoutSwitching =
|
|
35125
|
+
const layoutSwitching = chunkTVSTM5J5_js.useLayoutSwitching({
|
|
35125
35126
|
handler: handlerRef.current,
|
|
35126
35127
|
slides,
|
|
35127
35128
|
activeSlideIndex,
|
|
@@ -35217,7 +35218,7 @@ ${url}`)
|
|
|
35217
35218
|
"data-pptx-editor-chrome": "",
|
|
35218
35219
|
...{ [pptx.RIBBON_SCOPE_ATTR]: ribbonScope },
|
|
35219
35220
|
"aria-busy": loading,
|
|
35220
|
-
className:
|
|
35221
|
+
className: chunk7DGKSEIU_js.cn(
|
|
35221
35222
|
"h-full w-full bg-background text-foreground relative",
|
|
35222
35223
|
...pptx.resolveOptionRootClasses(viewerOptions, "pptx")
|
|
35223
35224
|
),
|
|
@@ -35608,8 +35609,8 @@ ${url}`)
|
|
|
35608
35609
|
// Nothing previously provided it, so every one of those consumers was
|
|
35609
35610
|
// silently reading `DEFAULT_VIEWER_OPTIONS` forever, no matter what
|
|
35610
35611
|
// the user changed in the Options dialog.
|
|
35611
|
-
/* @__PURE__ */ jsxRuntime.jsx(ViewerOptionsProvider, { options: viewerOptions, store: optionsStore, children: /* @__PURE__ */ jsxRuntime.jsx(ViewerCustomizationContext.Provider, { value: customizationResolved, children: /* @__PURE__ */ jsxRuntime.jsx(RibbonAddInsContext.Provider, { value: ribbonAddIns ?? NO_RIBBON_ADD_INS, children: /* @__PURE__ */ jsxRuntime.jsx(AccountAuthContext.Provider, { value: accountAuth, children: /* @__PURE__ */ jsxRuntime.jsx(
|
|
35612
|
-
|
|
35612
|
+
/* @__PURE__ */ jsxRuntime.jsx(ViewerOptionsProvider, { options: viewerOptions, store: optionsStore, children: /* @__PURE__ */ jsxRuntime.jsx(ViewerCustomizationContext.Provider, { value: customizationResolved, children: /* @__PURE__ */ jsxRuntime.jsx(RibbonAddInsContext.Provider, { value: ribbonAddIns ?? NO_RIBBON_ADD_INS, children: /* @__PURE__ */ jsxRuntime.jsx(AccountAuthContext.Provider, { value: accountAuth, children: /* @__PURE__ */ jsxRuntime.jsx(chunkTVSTM5J5_js.Rendering3DFlagsContext.Provider, { value: effective3D, children: /* @__PURE__ */ jsxRuntime.jsx(ViewerThemeProvider, { theme: effectiveTheme, children: /* @__PURE__ */ jsxRuntime.jsxs(
|
|
35613
|
+
chunkTVSTM5J5_js.CollaborationProvider,
|
|
35613
35614
|
{
|
|
35614
35615
|
config: collaboration,
|
|
35615
35616
|
canvasWidth: canvasSize.width,
|
|
@@ -35667,7 +35668,7 @@ ${url}`)
|
|
|
35667
35668
|
);
|
|
35668
35669
|
PowerPointViewer.displayName = "PowerPointViewer";
|
|
35669
35670
|
function CollaborationStatusStrip() {
|
|
35670
|
-
const collab =
|
|
35671
|
+
const collab = chunkTVSTM5J5_js.useCollaboration();
|
|
35671
35672
|
if (!collab) {
|
|
35672
35673
|
return null;
|
|
35673
35674
|
}
|
|
@@ -35691,8 +35692,8 @@ function CollaborationDocumentSync({
|
|
|
35691
35692
|
deckSaveState,
|
|
35692
35693
|
onReadOnlyChange
|
|
35693
35694
|
}) {
|
|
35694
|
-
const collab =
|
|
35695
|
-
|
|
35695
|
+
const collab = chunkTVSTM5J5_js.useCollaboration();
|
|
35696
|
+
chunkTVSTM5J5_js.useCollaborationDocumentSync({
|
|
35696
35697
|
collaboration: collab,
|
|
35697
35698
|
slides,
|
|
35698
35699
|
templateElementsBySlideId,
|
|
@@ -35711,14 +35712,14 @@ function CollaborationFollowLayer({
|
|
|
35711
35712
|
setActiveSlideIndex,
|
|
35712
35713
|
slideCount
|
|
35713
35714
|
}) {
|
|
35714
|
-
const collab =
|
|
35715
|
-
const { followedClientId, followUser } =
|
|
35715
|
+
const collab = chunkTVSTM5J5_js.useCollaboration();
|
|
35716
|
+
const { followedClientId, followUser } = chunkTVSTM5J5_js.useFollowMode({
|
|
35716
35717
|
collab,
|
|
35717
35718
|
activeSlideIndex,
|
|
35718
35719
|
setActiveSlideIndex,
|
|
35719
35720
|
slideCount
|
|
35720
35721
|
});
|
|
35721
|
-
|
|
35722
|
+
chunkTVSTM5J5_js.useBroadcastFollower({
|
|
35722
35723
|
collab,
|
|
35723
35724
|
activeSlideIndex,
|
|
35724
35725
|
setActiveSlideIndex,
|