pptx-react-viewer 4.1.0 → 4.1.1
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 +35 -0
- package/dist/{AiChatPanel-GQNSKMP6.js → AiChatPanel-N2FVAQRP.js} +24 -24
- package/dist/AiChatPanel-N2FVAQRP.js.br +0 -0
- package/dist/AiChatPanel-N2FVAQRP.js.gz +0 -0
- package/dist/{AiChatPanel-C3ACRWOY.mjs → AiChatPanel-VINTTAOW.mjs} +3 -3
- package/dist/AiChatPanel-VINTTAOW.mjs.br +0 -0
- package/dist/AiChatPanel-VINTTAOW.mjs.gz +0 -0
- package/dist/{Area3DChartScene-3I6KB2DN.js → Area3DChartScene-TI3GRA4Y.js} +2 -2
- package/dist/Area3DChartScene-TI3GRA4Y.js.br +0 -0
- package/dist/Area3DChartScene-TI3GRA4Y.js.gz +0 -0
- package/dist/{Area3DChartScene-4TPNRYXS.mjs → Area3DChartScene-WNEHMOG2.mjs} +1 -1
- package/dist/Area3DChartScene-WNEHMOG2.mjs.br +0 -0
- package/dist/Area3DChartScene-WNEHMOG2.mjs.gz +0 -0
- package/dist/{Bar3DChartScene-ZSCATOYF.js → Bar3DChartScene-CRN5WPCZ.js} +2 -2
- package/dist/Bar3DChartScene-CRN5WPCZ.js.br +0 -0
- package/dist/Bar3DChartScene-CRN5WPCZ.js.gz +0 -0
- package/dist/{Bar3DChartScene-V45IUIT7.mjs → Bar3DChartScene-E53RZRI4.mjs} +1 -1
- package/dist/Bar3DChartScene-E53RZRI4.mjs.br +0 -0
- package/dist/Bar3DChartScene-E53RZRI4.mjs.gz +0 -0
- package/dist/{Line3DChartScene-DK55LQ2D.js → Line3DChartScene-DGPE4GDN.js} +2 -2
- package/dist/Line3DChartScene-DGPE4GDN.js.br +0 -0
- package/dist/Line3DChartScene-DGPE4GDN.js.gz +0 -0
- package/dist/{Line3DChartScene-DCQJEZK6.mjs → Line3DChartScene-YJ2POVES.mjs} +1 -1
- package/dist/Line3DChartScene-YJ2POVES.mjs.br +0 -0
- package/dist/Line3DChartScene-YJ2POVES.mjs.gz +0 -0
- package/dist/{Model3DScene-SA5XMR2D.mjs → Model3DScene-MYODSOVU.mjs} +1 -1
- package/dist/Model3DScene-MYODSOVU.mjs.br +0 -0
- package/dist/Model3DScene-MYODSOVU.mjs.gz +0 -0
- package/dist/{Model3DScene-2WNP4XBP.js → Model3DScene-O4IOWE5S.js} +2 -2
- package/dist/Model3DScene-O4IOWE5S.js.br +0 -0
- package/dist/Model3DScene-O4IOWE5S.js.gz +0 -0
- package/dist/{PieChart3DScene-Q75D66HS.js → PieChart3DScene-4S4MZENR.js} +2 -2
- package/dist/PieChart3DScene-4S4MZENR.js.br +0 -0
- package/dist/PieChart3DScene-4S4MZENR.js.gz +0 -0
- package/dist/{PieChart3DScene-HC2ZWL42.mjs → PieChart3DScene-YYBYC5AM.mjs} +1 -1
- package/dist/PieChart3DScene-YYBYC5AM.mjs.br +0 -0
- package/dist/PieChart3DScene-YYBYC5AM.mjs.gz +0 -0
- package/dist/{SurfaceChart3DScene-JRMX4PN5.mjs → SurfaceChart3DScene-FFYG6CNE.mjs} +1 -1
- package/dist/SurfaceChart3DScene-FFYG6CNE.mjs.br +0 -0
- package/dist/SurfaceChart3DScene-FFYG6CNE.mjs.gz +0 -0
- package/dist/{SurfaceChart3DScene-ODS5E6ZG.js → SurfaceChart3DScene-RNBXINNV.js} +2 -2
- package/dist/SurfaceChart3DScene-RNBXINNV.js.br +0 -0
- package/dist/SurfaceChart3DScene-RNBXINNV.js.gz +0 -0
- package/dist/{chunk-NR4MQJM5.js → chunk-3LIWTQSG.js} +1062 -1062
- package/dist/chunk-3LIWTQSG.js.br +0 -0
- package/dist/chunk-3LIWTQSG.js.gz +0 -0
- package/dist/{chunk-A6JKOHSV.js → chunk-45JD3XEM.js} +816 -797
- package/dist/chunk-45JD3XEM.js.br +0 -0
- package/dist/chunk-45JD3XEM.js.gz +0 -0
- package/dist/{chunk-Q6QJOD56.mjs → chunk-7X6UCEYM.mjs} +80 -112
- package/dist/chunk-7X6UCEYM.mjs.br +0 -0
- package/dist/{chunk-Q6QJOD56.mjs.gz → chunk-7X6UCEYM.mjs.gz} +0 -0
- package/dist/{chunk-3B6YIH4K.mjs → chunk-FOXGVZ4A.mjs} +29 -10
- package/dist/chunk-FOXGVZ4A.mjs.br +0 -0
- package/dist/chunk-FOXGVZ4A.mjs.gz +0 -0
- package/dist/{chunk-WLWAYLL6.mjs → chunk-ILVWZ7TN.mjs} +1 -1
- package/dist/chunk-ILVWZ7TN.mjs.br +0 -0
- package/dist/chunk-ILVWZ7TN.mjs.gz +0 -0
- package/dist/{chunk-SK2CZQ6P.js → chunk-JLQWPRIM.js} +80 -112
- package/dist/chunk-JLQWPRIM.js.br +0 -0
- package/dist/{chunk-SK2CZQ6P.js.gz → chunk-JLQWPRIM.js.gz} +0 -0
- package/dist/{chunk-MQHMMB6V.js → chunk-MVLYI7C2.js} +5 -5
- package/dist/chunk-MVLYI7C2.js.br +0 -0
- package/dist/{chunk-MQHMMB6V.js.gz → chunk-MVLYI7C2.js.gz} +0 -0
- package/dist/{chunk-PUALTXTU.js → chunk-NKXILGP5.js} +173 -173
- package/dist/chunk-NKXILGP5.js.br +0 -0
- package/dist/chunk-NKXILGP5.js.gz +0 -0
- package/dist/{chunk-GRAARMUW.mjs → chunk-Q7MONAI4.mjs} +1 -1
- package/dist/chunk-Q7MONAI4.mjs.br +0 -0
- package/dist/chunk-Q7MONAI4.mjs.gz +0 -0
- package/dist/{chunk-25CABWCR.mjs → chunk-VC4GPWZS.mjs} +6 -6
- package/dist/chunk-VC4GPWZS.mjs.br +0 -0
- package/dist/chunk-VC4GPWZS.mjs.gz +0 -0
- package/dist/index.js +47 -47
- package/dist/index.js.br +0 -0
- package/dist/index.js.gz +0 -0
- package/dist/index.mjs +5 -5
- package/dist/index.mjs.br +0 -0
- package/dist/index.mjs.gz +0 -0
- package/dist/internals.js +104 -104
- package/dist/internals.js.br +0 -0
- package/dist/internals.js.gz +0 -0
- package/dist/internals.mjs +3 -3
- package/dist/internals.mjs.br +0 -0
- package/dist/internals.mjs.gz +0 -0
- package/dist/viewer/index.js +26 -26
- package/dist/viewer/index.js.br +0 -0
- package/dist/viewer/index.js.gz +0 -0
- package/dist/viewer/index.mjs +5 -5
- package/dist/viewer/index.mjs.br +2 -1
- package/dist/viewer/index.mjs.gz +0 -0
- package/package.json +2 -2
- package/dist/AiChatPanel-C3ACRWOY.mjs.br +0 -0
- package/dist/AiChatPanel-C3ACRWOY.mjs.gz +0 -0
- package/dist/AiChatPanel-GQNSKMP6.js.br +0 -0
- package/dist/AiChatPanel-GQNSKMP6.js.gz +0 -0
- package/dist/Area3DChartScene-3I6KB2DN.js.br +0 -0
- package/dist/Area3DChartScene-3I6KB2DN.js.gz +0 -0
- package/dist/Area3DChartScene-4TPNRYXS.mjs.br +0 -0
- package/dist/Area3DChartScene-4TPNRYXS.mjs.gz +0 -0
- package/dist/Bar3DChartScene-V45IUIT7.mjs.br +0 -0
- package/dist/Bar3DChartScene-V45IUIT7.mjs.gz +0 -0
- package/dist/Bar3DChartScene-ZSCATOYF.js.br +0 -0
- package/dist/Bar3DChartScene-ZSCATOYF.js.gz +0 -0
- package/dist/Line3DChartScene-DCQJEZK6.mjs.br +0 -0
- package/dist/Line3DChartScene-DCQJEZK6.mjs.gz +0 -0
- package/dist/Line3DChartScene-DK55LQ2D.js.br +0 -0
- package/dist/Line3DChartScene-DK55LQ2D.js.gz +0 -0
- package/dist/Model3DScene-2WNP4XBP.js.br +0 -0
- package/dist/Model3DScene-2WNP4XBP.js.gz +0 -0
- package/dist/Model3DScene-SA5XMR2D.mjs.br +0 -0
- package/dist/Model3DScene-SA5XMR2D.mjs.gz +0 -0
- package/dist/PieChart3DScene-HC2ZWL42.mjs.br +0 -0
- package/dist/PieChart3DScene-HC2ZWL42.mjs.gz +0 -0
- package/dist/PieChart3DScene-Q75D66HS.js.br +0 -0
- package/dist/PieChart3DScene-Q75D66HS.js.gz +0 -0
- package/dist/SurfaceChart3DScene-JRMX4PN5.mjs.br +0 -0
- package/dist/SurfaceChart3DScene-JRMX4PN5.mjs.gz +0 -0
- package/dist/SurfaceChart3DScene-ODS5E6ZG.js.br +0 -0
- package/dist/SurfaceChart3DScene-ODS5E6ZG.js.gz +0 -0
- package/dist/chunk-25CABWCR.mjs.br +0 -0
- package/dist/chunk-25CABWCR.mjs.gz +0 -0
- package/dist/chunk-3B6YIH4K.mjs.br +0 -0
- package/dist/chunk-3B6YIH4K.mjs.gz +0 -0
- package/dist/chunk-A6JKOHSV.js.br +0 -0
- package/dist/chunk-A6JKOHSV.js.gz +0 -0
- package/dist/chunk-GRAARMUW.mjs.br +0 -0
- package/dist/chunk-GRAARMUW.mjs.gz +0 -0
- package/dist/chunk-MQHMMB6V.js.br +0 -0
- package/dist/chunk-NR4MQJM5.js.br +0 -0
- package/dist/chunk-NR4MQJM5.js.gz +0 -0
- package/dist/chunk-PUALTXTU.js.br +0 -0
- package/dist/chunk-PUALTXTU.js.gz +0 -0
- package/dist/chunk-Q6QJOD56.mjs.br +0 -0
- package/dist/chunk-SK2CZQ6P.js.br +0 -0
- package/dist/chunk-WLWAYLL6.mjs.br +0 -0
- package/dist/chunk-WLWAYLL6.mjs.gz +0 -0
|
Binary file
|
|
Binary file
|
|
@@ -196750,117 +196750,6 @@ async function saveAutosaveSnapshot(filePath, data) {
|
|
|
196750
196750
|
return putAutosaveRecord(filePath, data);
|
|
196751
196751
|
}
|
|
196752
196752
|
}
|
|
196753
|
-
var AUTOSAVE_RECOVERY_WINDOW_MS = 24 * 60 * 60 * 1e3;
|
|
196754
|
-
var CONSUMED_KEY = "pptx-viewer-recovery-consumed";
|
|
196755
|
-
function markAutosaveSnapshotConsumed(timestamp) {
|
|
196756
|
-
try {
|
|
196757
|
-
if (typeof sessionStorage === "undefined" || !Number.isFinite(timestamp)) {
|
|
196758
|
-
return;
|
|
196759
|
-
}
|
|
196760
|
-
const previous = consumedAutosaveSnapshotTimestamp();
|
|
196761
|
-
if (timestamp > previous) {
|
|
196762
|
-
sessionStorage.setItem(CONSUMED_KEY, String(timestamp));
|
|
196763
|
-
}
|
|
196764
|
-
} catch {
|
|
196765
|
-
}
|
|
196766
|
-
}
|
|
196767
|
-
function consumedAutosaveSnapshotTimestamp() {
|
|
196768
|
-
try {
|
|
196769
|
-
if (typeof sessionStorage === "undefined") {
|
|
196770
|
-
return 0;
|
|
196771
|
-
}
|
|
196772
|
-
const raw = sessionStorage.getItem(CONSUMED_KEY);
|
|
196773
|
-
const value = raw === null ? Number.NaN : Number(raw);
|
|
196774
|
-
return Number.isFinite(value) ? value : 0;
|
|
196775
|
-
} catch {
|
|
196776
|
-
return 0;
|
|
196777
|
-
}
|
|
196778
|
-
}
|
|
196779
|
-
function shouldProbeAutosaveRecovery(input) {
|
|
196780
|
-
return !input.alreadyChecked && input.autosaveAllowed && Boolean(input.filePath) && !input.loading && !input.error && input.slideCount > 0;
|
|
196781
|
-
}
|
|
196782
|
-
function formatSnapshotSize(bytes) {
|
|
196783
|
-
if (!Number.isFinite(bytes) || bytes <= 0) {
|
|
196784
|
-
return "0 KB";
|
|
196785
|
-
}
|
|
196786
|
-
if (bytes < 1024 * 1024) {
|
|
196787
|
-
return `${Math.max(1, Math.round(bytes / 1024))} KB`;
|
|
196788
|
-
}
|
|
196789
|
-
return `${(bytes / (1024 * 1024)).toFixed(1)} MB`;
|
|
196790
|
-
}
|
|
196791
|
-
function ageKeyFor(ageMinutes) {
|
|
196792
|
-
if (ageMinutes < 1) {
|
|
196793
|
-
return { key: "pptx.autosave.justNow", count: 0 };
|
|
196794
|
-
}
|
|
196795
|
-
if (ageMinutes === 1) {
|
|
196796
|
-
return { key: "pptx.autosave.oneMinAgo", count: 1 };
|
|
196797
|
-
}
|
|
196798
|
-
if (ageMinutes < 60) {
|
|
196799
|
-
return { key: "pptx.autosave.minutesAgo", count: ageMinutes };
|
|
196800
|
-
}
|
|
196801
|
-
return { key: "pptx.autosave.recovery.hoursAgo", count: Math.floor(ageMinutes / 60) };
|
|
196802
|
-
}
|
|
196803
|
-
function autosaveRecoveryPrompt(input) {
|
|
196804
|
-
const record2 = input.record;
|
|
196805
|
-
if (!record2 || record2.size <= 0 || !record2.key) {
|
|
196806
|
-
return null;
|
|
196807
|
-
}
|
|
196808
|
-
const age = input.now - record2.timestamp;
|
|
196809
|
-
if (!Number.isFinite(age) || age < 0 || age >= AUTOSAVE_RECOVERY_WINDOW_MS) {
|
|
196810
|
-
return null;
|
|
196811
|
-
}
|
|
196812
|
-
if (record2.timestamp <= (input.consumedTimestamp ?? 0)) {
|
|
196813
|
-
return null;
|
|
196814
|
-
}
|
|
196815
|
-
const ageMinutes = Math.floor(age / 6e4);
|
|
196816
|
-
const relative = ageKeyFor(ageMinutes);
|
|
196817
|
-
return {
|
|
196818
|
-
filePath: record2.key,
|
|
196819
|
-
timestamp: record2.timestamp,
|
|
196820
|
-
size: record2.size,
|
|
196821
|
-
ageMinutes,
|
|
196822
|
-
titleKey: "pptx.autosave.recovery.title",
|
|
196823
|
-
messageKey: "pptx.autosave.recovery.message",
|
|
196824
|
-
messageParams: { file: record2.key, size: formatSnapshotSize(record2.size) },
|
|
196825
|
-
ageKey: relative.key,
|
|
196826
|
-
ageParams: { count: relative.count },
|
|
196827
|
-
restoreKey: "pptx.autosave.recovery.restore",
|
|
196828
|
-
discardKey: "pptx.autosave.recovery.discard"
|
|
196829
|
-
};
|
|
196830
|
-
}
|
|
196831
|
-
function shouldShowAutosaveRecoveryPrompt(input) {
|
|
196832
|
-
return Boolean(input.prompt) && !input.presenting;
|
|
196833
|
-
}
|
|
196834
|
-
async function probeAutosaveRecovery(filePath, now = Date.now()) {
|
|
196835
|
-
if (typeof indexedDB === "undefined") {
|
|
196836
|
-
return null;
|
|
196837
|
-
}
|
|
196838
|
-
try {
|
|
196839
|
-
const record2 = await getAutosaveSnapshot(filePath);
|
|
196840
|
-
const prompt = autosaveRecoveryPrompt({
|
|
196841
|
-
record: record2 ? { key: record2.key, timestamp: record2.timestamp, size: record2.size } : void 0,
|
|
196842
|
-
now,
|
|
196843
|
-
consumedTimestamp: consumedAutosaveSnapshotTimestamp()
|
|
196844
|
-
});
|
|
196845
|
-
if (!prompt || !record2) {
|
|
196846
|
-
return null;
|
|
196847
|
-
}
|
|
196848
|
-
return { prompt, record: record2 };
|
|
196849
|
-
} catch {
|
|
196850
|
-
return null;
|
|
196851
|
-
}
|
|
196852
|
-
}
|
|
196853
|
-
function acceptAutosaveRecovery(record2) {
|
|
196854
|
-
markAutosaveSnapshotConsumed(record2.timestamp);
|
|
196855
|
-
return record2.data instanceof Uint8Array ? record2.data : new Uint8Array(record2.data);
|
|
196856
|
-
}
|
|
196857
|
-
async function discardAutosaveRecovery(record2) {
|
|
196858
|
-
markAutosaveSnapshotConsumed(record2.timestamp);
|
|
196859
|
-
try {
|
|
196860
|
-
await deleteAutosaveSnapshot(record2.key);
|
|
196861
|
-
} catch {
|
|
196862
|
-
}
|
|
196863
|
-
}
|
|
196864
196753
|
function secureRandomBytes(length) {
|
|
196865
196754
|
const bytes = new Uint8Array(length);
|
|
196866
196755
|
if (typeof crypto !== "undefined" && typeof crypto.getRandomValues === "function") {
|
|
@@ -197059,7 +196948,6 @@ async function restoreSessionDeck() {
|
|
|
197059
196948
|
const snapshot = await getAutosaveSnapshot(deck.fileName);
|
|
197060
196949
|
const bytes = snapshot ? toBytes(snapshot.data) : null;
|
|
197061
196950
|
if (snapshot && bytes && bytes.byteLength > 0 && snapshot.timestamp > deck.timestamp) {
|
|
197062
|
-
markAutosaveSnapshotConsumed(snapshot.timestamp);
|
|
197063
196951
|
return { fileName: deck.fileName, data: bytes, timestamp: snapshot.timestamp };
|
|
197064
196952
|
}
|
|
197065
196953
|
} catch {
|
|
@@ -203519,6 +203407,86 @@ function resolveAutosaveIntervalMs(input) {
|
|
|
203519
203407
|
}
|
|
203520
203408
|
return AUTOSAVE_DEFAULT_INTERVAL_MS;
|
|
203521
203409
|
}
|
|
203410
|
+
var AUTOSAVE_RECOVERY_WINDOW_MS = 24 * 60 * 60 * 1e3;
|
|
203411
|
+
function shouldProbeAutosaveRecovery(input) {
|
|
203412
|
+
return !input.alreadyChecked && input.autosaveAllowed && Boolean(input.filePath) && !input.loading && !input.error && input.slideCount > 0;
|
|
203413
|
+
}
|
|
203414
|
+
function formatSnapshotSize(bytes) {
|
|
203415
|
+
if (!Number.isFinite(bytes) || bytes <= 0) {
|
|
203416
|
+
return "0 KB";
|
|
203417
|
+
}
|
|
203418
|
+
if (bytes < 1024 * 1024) {
|
|
203419
|
+
return `${Math.max(1, Math.round(bytes / 1024))} KB`;
|
|
203420
|
+
}
|
|
203421
|
+
return `${(bytes / (1024 * 1024)).toFixed(1)} MB`;
|
|
203422
|
+
}
|
|
203423
|
+
function ageKeyFor(ageMinutes) {
|
|
203424
|
+
if (ageMinutes < 1) {
|
|
203425
|
+
return { key: "pptx.autosave.justNow", count: 0 };
|
|
203426
|
+
}
|
|
203427
|
+
if (ageMinutes === 1) {
|
|
203428
|
+
return { key: "pptx.autosave.oneMinAgo", count: 1 };
|
|
203429
|
+
}
|
|
203430
|
+
if (ageMinutes < 60) {
|
|
203431
|
+
return { key: "pptx.autosave.minutesAgo", count: ageMinutes };
|
|
203432
|
+
}
|
|
203433
|
+
return { key: "pptx.autosave.recovery.hoursAgo", count: Math.floor(ageMinutes / 60) };
|
|
203434
|
+
}
|
|
203435
|
+
function autosaveRecoveryPrompt(input) {
|
|
203436
|
+
const record2 = input.record;
|
|
203437
|
+
if (!record2 || record2.size <= 0 || !record2.key) {
|
|
203438
|
+
return null;
|
|
203439
|
+
}
|
|
203440
|
+
const age = input.now - record2.timestamp;
|
|
203441
|
+
if (!Number.isFinite(age) || age < 0 || age >= AUTOSAVE_RECOVERY_WINDOW_MS) {
|
|
203442
|
+
return null;
|
|
203443
|
+
}
|
|
203444
|
+
const ageMinutes = Math.floor(age / 6e4);
|
|
203445
|
+
const relative = ageKeyFor(ageMinutes);
|
|
203446
|
+
return {
|
|
203447
|
+
filePath: record2.key,
|
|
203448
|
+
timestamp: record2.timestamp,
|
|
203449
|
+
size: record2.size,
|
|
203450
|
+
ageMinutes,
|
|
203451
|
+
titleKey: "pptx.autosave.recovery.title",
|
|
203452
|
+
messageKey: "pptx.autosave.recovery.message",
|
|
203453
|
+
messageParams: { file: record2.key, size: formatSnapshotSize(record2.size) },
|
|
203454
|
+
ageKey: relative.key,
|
|
203455
|
+
ageParams: { count: relative.count },
|
|
203456
|
+
restoreKey: "pptx.autosave.recovery.restore",
|
|
203457
|
+
discardKey: "pptx.autosave.recovery.discard"
|
|
203458
|
+
};
|
|
203459
|
+
}
|
|
203460
|
+
function shouldShowAutosaveRecoveryPrompt(input) {
|
|
203461
|
+
return Boolean(input.prompt) && !input.presenting;
|
|
203462
|
+
}
|
|
203463
|
+
async function probeAutosaveRecovery(filePath, now = Date.now()) {
|
|
203464
|
+
if (typeof indexedDB === "undefined") {
|
|
203465
|
+
return null;
|
|
203466
|
+
}
|
|
203467
|
+
try {
|
|
203468
|
+
const record2 = await getAutosaveSnapshot(filePath);
|
|
203469
|
+
const prompt = autosaveRecoveryPrompt({
|
|
203470
|
+
record: record2 ? { key: record2.key, timestamp: record2.timestamp, size: record2.size } : void 0,
|
|
203471
|
+
now
|
|
203472
|
+
});
|
|
203473
|
+
if (!prompt || !record2) {
|
|
203474
|
+
return null;
|
|
203475
|
+
}
|
|
203476
|
+
return { prompt, record: record2 };
|
|
203477
|
+
} catch {
|
|
203478
|
+
return null;
|
|
203479
|
+
}
|
|
203480
|
+
}
|
|
203481
|
+
function acceptAutosaveRecovery(record2) {
|
|
203482
|
+
return record2.data instanceof Uint8Array ? record2.data : new Uint8Array(record2.data);
|
|
203483
|
+
}
|
|
203484
|
+
async function discardAutosaveRecovery(record2) {
|
|
203485
|
+
try {
|
|
203486
|
+
await deleteAutosaveSnapshot(record2.key);
|
|
203487
|
+
} catch {
|
|
203488
|
+
}
|
|
203489
|
+
}
|
|
203522
203490
|
var BACKSTAGE_NAV = [
|
|
203523
203491
|
{ id: "home", label: "Home", labelKey: "pptx.backstage.nav.home" },
|
|
203524
203492
|
{ id: "new", label: "New", labelKey: "pptx.backstage.nav.new" },
|
|
Binary file
|
|
Binary file
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { DEFAULT_STROKE_COLOR, getConnectorPathGeometry, buildLineShadowCss, buildLineGlowFilter, renderConnectorMarker, getShapeVisualStyle, getTextStyleForElement, DEFAULT_TEXT_COLOR, renderVectorShape, isConnectorOrLineElement, build3DExtrusionData, getImageRenderStyle, cn, getImageSurfaceStyle, getTextLayoutStyle, renderTableElement, renderMediaElement, shouldRenderFallbackLabel, DEFAULT_FILL_COLOR, getCropShapeClipPath, hasDagDuotoneEffect, renderDagDuotoneSvgFilter, getImageSurfaceMaskStyle, getImageTilingStyle, getDuotoneColors, getTextWarpStyle, renderTextSegments, buildReactChartViewModel, renderChartElement, MIN_ELEMENT_SIZE, buildTextBody3DSceneStyle, DEFAULT_TEXT_FONT_SIZE, DEFAULT_FONT_FAMILY, HYPERLINK_COLOR, cloneHistorySnapshot, ZOOM_TO_SELECTION_PADDING, DEFAULT_CANVAS_HEIGHT, DEFAULT_CANVAS_WIDTH, UNGROUPED_SECTION_ID, DEFAULT_SECTION_GROUP_ID, DEFAULT_TABLE_ROWS, DEFAULT_TABLE_COLUMNS, buildPdfFromTiledImageData, GRID_SIZE, buildNotesPdf } from './chunk-
|
|
2
|
-
import { GlyphOutlineFontCache, createGlyphOutlineLookup, DEFAULT_VIEWER_OPTIONS, TOOLBAR_TABS, getSelectionControlArtworkStyle, hasShapeProperties, normalizeHexColor, colorWithOpacity, normalizeStrokeDashType, getSvgStrokeDasharray, getCompoundLineOffsets, getCompoundLineWidths, svgLineCap, hasTextProperties, getSelectionOutlineColor, connectorWrapperTransform, getAriaRoleDescription, getAriaLabel, getAriaRole, resolveElementInteractivity, isEditableTextElement, buildTextStyleOverrideCss, isElementRendered, resolveElementAriaAttributes, shouldRenderHitTarget, elementHitTargetStyle, getImageEffectsOpacity, getImageEffectsFilter, inlineElementPointerEvents, isHollowShapeElement, LINK_TOOLTIP_HOST_CLASS, ACTION_BUTTON_PRESETS, mediaTransportVisible, isInkElement, getGroupChildParentFill, getElementLabel, getResizeHandleHitAreaStyle, paintedStrokeWidth, buildCssGradientFromShapeStyle, ensureActionAffordanceStyles, resolveElementActionAffordance, actionAffordanceLabels, paintedElementSize, getElementTransform, resolveElementHighlightClick, applyHighlightClickStyle, getComputedEffectStyle, getSoftEdgeSvgFilter, getEffectStyleSource, getBevelLightingSvgFilter, buildStrokeOutline, buildHollowHitOutline, buildSubpathFillOverlay, isImageLikeElement, strokeOutlineViewBox, resolveRevealedSmartArtNodes, resolveRevealedDrawingShapes, buildSmartArtA11y, canDrillDown, computeSmartArtElementLayout, flattenNodes, buildSummaryZoomView, isImageTiled, getImageColorWashStyle, readEditableText, placeCaretAtEnd, getPendingSelectionRestore, restoreSegmentSelection, getTextCompensationTransform, resolveChartKind, subscribeBarFacePicturePixelSamples, getBarFacePicturePixelSampleVersion, ensureChartInteractionStyles, applyChartPartHighlight, resolveRevealedChartData, formatAxisValue, buildInkGroupStrokes, getInkReplayStyles, INK_REPLAY_KEYFRAMES, buildContentPartStrokes, getContentPartReplayStyles, resolveOleType, getOleAriaLabel, getOleTypeColor, getOleTypeLabel, filterRenderedElements, resolveGroupChildFill, isLinkedTextBox, getOverflowSegments, shouldUseSvgWarp, getTextBodyRotationTransform, placeholderPromptDescriptor, attachRotateHandlePlacement, elementIdSelector, createRotationDrag, ACTION_INDICATOR_CLASS, ACTION_INDICATOR_ICON_PATH, LINK_TOOLTIP_CLASS, LINK_TOOLTIP_PANEL_CLASS, LINK_TOOLTIP_LABEL_CLASS, LINK_TOOLTIP_HINT_CLASS, DEFAULT_PALETTE2, resolvePalette, computeDrawingViewBox, projectDrawingShapes, resolveRevealedDrawingShapeNodeIds, styleShadowFilter, buildChromeStyle, measureSvgViewportRect, modelDataToBlobUrl, getImageSvgFilters, buildDuotoneCacheKey, getDuotoneCachedResult, applyDuotone, setDuotoneCachedResult, buildCacheKey, DEFAULT_COLOR_CHANGE_TOLERANCE, getCachedResult, applyColorChange, setCachedResult, inlineListBodyText, createInlineListSeed, readListActivationSelection, createInlineListModelObserver, attachCollaborationInlineEditor, bindInlineListParagraph, bindInlineListRun, attachInlineListController, restoreInlineListBodySelection, getInlineEditorSelectionResult, isBulletMarkerSegment, findChartPartTarget, buildSurfaceChart3DDataForElement, buildBarChart3DDataForElement, buildLineChart3DDataForElement, buildAreaChart3DDataForElement, buildPieChart3DDataForElement, withChartTitle, resolveSmartArt3DLayout, buildSmartArt3DModel, collectCoherent3DOffNodeIds, isBrowserOpenableMime, formatBytes, getOleDisplayName, getOleBadgeLabel, openUrlInNewTab, getSubstituteFontFamily, hasGlyphEnvelope, buildGlyphEnvelope, getWarpPath, isWedgeCalloutPresetShape, isElementActionable, centeredSvgTextLines, findSmartArtNodeText, setSmartArtNodeStyle, rebuildDrawingShapesIfCleared, shouldCommitSmartArtNodeText, updateSmartArtNodeText, advanceChartMarkDrag, advanceChartValueDrag, buildChartMarkDragGeometry, beginChartMarkDrag, beginChartValueDrag, groupIntoParagraphs, substituteFieldText, computeInlineEditorRect, withChartPointValue, MIN_TOUCH_TARGET_PX, computeVirtualRange, DEFAULT_VIRTUAL_OVERSCAN, createSyncGate, clearLocalAwareness, validateRoomId, createDepartureChannel, resolveTransportForServerUrl, isMixedContentBlocked, CONNECTION_TIMEOUT_MS, registerCollaborationTeardown, createPresenceProjector, BROADCAST_THROTTLE_MS, sanitizeColor, cloneTemplateElementsBySlideId, cloneSlide, createWheelStepBuffer, createViewerZoomStore, clampZoomScale, mapEditingWheel, createActiveAnimationGroup, cancelBuildReveal, clearPlaybackTimers, PresentationAnimationController, resolveMediaTimeNodeElementIds, advanceMainSequence, playGroup, PRESENTATION_HASH, PRESENTATION_NONCE_KEY, PRESENTATION_CHANNEL_NAME, swapPresentationWindows, PRESENTATION_MESSAGE_ORIGIN, clearAudienceContent, buildPresentationAudienceUrl, resolveAudienceScreenPlacement, placeAudienceWindow, storeAudienceContent, isPresentationSessionMessage, endAudienceDisplay, createPresentationKeyBuffer, acceptsPresentationInput, resolveAutoAdvanceDelayMs, hasShowSlideAfter, nextShowSlideIndex, previousShowSlideIndex, createPresenterShowGuard, firstShowSlideIndex, attachPresentationVisibilityPause, presentationEntrySlideIndex, buildMorphTransitionPlan, morphOptionToMode, buildMorphAnimationRules, findInSlides, applyFindReplacements, visibleTemplateElements, createCollaborationLivePatcher, publishLiveInlineText, PptxHandler, createPresentationLoadResources, collectMediaElements, resolveMediaElementSource, collectImagePaths, applyImagePathPatches, resolveTableCellImageUrls, resolveTableStyleImageUrls, partitionTemplateElements, seedRecentColors, resolveAuthoredCustomShowId, buildInitialGuides, readOnlyRecommendation, compatibilityWarningToasts, EncryptedFileError, resolveAutosaveIntervalMs, shouldWriteAutosaveSnapshot, saveAutosaveSnapshot, autosaveSnapshotMark, updateMasterViewElement, isTemplateElementId, updateElement, masterViewElements, replaceMasterViewElements, addSection, renameSection, deleteSection, moveSectionUp, moveSectionDown, moveSlidesToSection, canInteractWithElement, prepareExportClone, normalizeColorsForCapture, preprocessCssForCapture, slideProgressPercent, slideStatusLabel, EXPORT_ASSEMBLING_PERCENT, EXPORT_DONE_PERCENT, isExportAbortError, resolveImageResolutionScale, applyThemeToData, THEME_PRESETS, themeColorSchemesEqual, comparePresentation, applyAcceptSlide, applyAcceptAllSlides, collectUsedFonts, describeFontEmbedding, isMobileViewport, resolveAuthoredSlideRange, mayLeaveSlideShow, stopAllPersistentAudio, guidePxToEmu, buildSaveSlides, buildDeckSaveOptions, resolveSlideSizeSelection, saveDeckWithPassword, shouldProbeAutosaveRecovery, probeAutosaveRecovery, acceptAutosaveRecovery, discardAutosaveRecovery, shouldLoopContinuously, applyRehearsalTimings, copyFormatFromElement, applyFormatToElement, collectReferencedFontFamilies, resolveGoogleWebfontHref, syncGoogleWebfontStylesheet, selectGoogleWebfontFamilies, fetchGoogleWebfontOutlineBytes, mapSlideShowStartKey, mapEditorKey, isEditorTextInputTarget, prepareElementForInsertion, createViewerOptionsStore, observeYDocSlides, LOCAL_SYNC_ORIGIN, readSlidesFromYDoc, shouldRoomSlidesReplaceLoad, reconcileSlidesInYDoc, shouldAutoFollowBroadcaster, detectTouchDevice, detectOrientation, deriveViewportBreakpoints, createTouchGestureRecognizer, MAX_ZOOM_SCALE, MIN_ZOOM_SCALE, isKeyboardOpen, scopeLayoutOptionsToSlide, checkModifyPassword, viewerPreferencesFromViewProperties, DEFAULT_VIEWER_PREFERENCES, viewPropertiesPatchFromPreferences, openPptxFile, readBackstageRecentFile, resolveCollaborationShellEditability, resolveCollaborationShellState, MORPH_CROSSFADE_GROUP_STYLE, MORPH_CROSSFADE_HALF_STYLE, getSlideTransitionAnimations, getFragmentedTransitionDescriptor, SLIDE_TRANSITION_KEYFRAMES, isActionHidden, buildInlineTextCommitPatch, resolveInlineEditAutoFitHeight, resolveInlineEditNormAutofitShrink, filterInteractableIds, beginShapeAdjustment, buildElementClipboardPayload, savedPresentationFileName, downloadBlob, exportDeckJson, groupElements, generateElementId, makeCloneId, ungroupElements, alignElements, distributeElements, newTableElement, createDefaultChartElement, readViewportMetrics, computeKeyboardInset, mergeShapes, mapPresentationKey, lastShowSlideIndex, mapPresentationWheel, openPendingPrintWindow, computeColorFilter, filterHiddenSlideIndices, computeSlideIndices, buildPrintDocument, finishPrintWindow, buildPrintHtmlDocument, buildOutlineHtml, buildSlidesHtml, buildNotesHtml, buildHandoutsHtml, createBlankSlide, makeSlideId, buildSlideTemplateSlide, templateSchemeFromTheme, buildThemeColorMap, reResolveSlideColors, reResolveElementColors, resolveViewportFitOptions, calculateViewportFit, scheduleAutoAdvanceChain, computeEntranceAnimationDelay, createPresentationSessionId, resolveTransitionDurationMs, resolveTransitionSoundAction, runPresentationAction, safeOpenUrl, buildRunProgramNotice, toggleStageElementMedia, resolveOleVerbTarget, downloadDataUrl, createPresenterTimer, createInitialPresentationSnapshot, mergePresentationSnapshot, resetPresenterTimer, presenterElapsed, stepPresenterZoom, togglePresenterTimer, addCommentToList, removeCommentFromList, editCommentInList, toggleCommentResolvedInList, remapTextToSegments, buildInlineListStylePatch, applyActiveInlineListFormatting, applyListStyleUpdate, setPendingSelectionRestore, applyTextStyleUpdate, toggleSelectionBullets, transformInlineListCase, applyCaseTransformToSegments, transformTextCase, resolveExportCaptureDecision, recordProgressPercent, computeGridSpacingPx, resolveShowSlideIndexes, groupSlidesBySection, masterViewPseudoSlide, overlayMasterViewInlineSnapshot, overlayInlineTextSnapshot, cloneElementUpdates, assertElementUpdateTarget, prepareElementUpdateBatch, createWriteBackScheduler, observeExternalCollaborationReadiness, resolveHistoryDepth, hasCopyableFormat, createBackstagePresentation, buildFieldSubstitutionContext, cloneElementForPaste, computeScrollDelta, getPresetShapeClipPath, svgPathToPolygons, polygonsToSvgPath, rerouteConnectorsForMovedElements, applyReroutedConnectors, SvgExporter, replyToCommentInList, removeTableElementColumn, insertTableElementColumn, removeTableElementRow, insertTableElementRow, updateCellTextStyleInRawXml, setCellText, updateCellTextInRawXml, splitCell, updateMergeAttrsInRawXml, mergeCells, pickSupportedMimeType, WEBM_MIME_CANDIDATES, fpsToFrameIntervalMs, segmentFrameCount, stopCaptureStream, GIF_POST_CAPTURE_MAX_SIDE, encodeGif, rasterResultToPngBlob, rasterizeElementTiles, placeTileOnPage, PDF_SLIDES_PAGE_WIDTH_PT, PDF_SLIDES_PAGE_HEIGHT_PT, canvasToJpegData, createSnapshotTextPositions, isPpactionUrl, parsePpactionUrl, resolvePresentationAction, elementActionToPptxAction, isUrlSafe, buildSmartArtPresetData, classifyMediaType, computeSnapToShape, publishLiveGeometry, getDraggedShapeAdjustments, computeMarqueeHitIds, mergeAdditiveSelection, rasterizeElementTiledToCanvas, borrowExternalCollaborationAwareness, observeExternalCollaborationSession, clampGifDimensions, rasterizeElement, shouldConfirmExternalHyperlink, applyResize, lockResizeAspect, snapBoxToGrid, applyMotionPathPreset, bringForward, sendBackward, bringToFront, sendToBack } from './chunk-Q6QJOD56.mjs';
|
|
1
|
+
import { DEFAULT_STROKE_COLOR, getConnectorPathGeometry, buildLineShadowCss, buildLineGlowFilter, renderConnectorMarker, getShapeVisualStyle, getTextStyleForElement, DEFAULT_TEXT_COLOR, renderVectorShape, isConnectorOrLineElement, build3DExtrusionData, getImageRenderStyle, cn, getImageSurfaceStyle, getTextLayoutStyle, renderTableElement, renderMediaElement, shouldRenderFallbackLabel, DEFAULT_FILL_COLOR, getCropShapeClipPath, hasDagDuotoneEffect, renderDagDuotoneSvgFilter, getImageSurfaceMaskStyle, getImageTilingStyle, getDuotoneColors, getTextWarpStyle, renderTextSegments, buildReactChartViewModel, renderChartElement, MIN_ELEMENT_SIZE, buildTextBody3DSceneStyle, DEFAULT_TEXT_FONT_SIZE, DEFAULT_FONT_FAMILY, HYPERLINK_COLOR, cloneHistorySnapshot, ZOOM_TO_SELECTION_PADDING, DEFAULT_CANVAS_HEIGHT, DEFAULT_CANVAS_WIDTH, UNGROUPED_SECTION_ID, DEFAULT_SECTION_GROUP_ID, DEFAULT_TABLE_ROWS, DEFAULT_TABLE_COLUMNS, buildPdfFromTiledImageData, GRID_SIZE, buildNotesPdf } from './chunk-ILVWZ7TN.mjs';
|
|
2
|
+
import { GlyphOutlineFontCache, createGlyphOutlineLookup, DEFAULT_VIEWER_OPTIONS, TOOLBAR_TABS, getSelectionControlArtworkStyle, hasShapeProperties, normalizeHexColor, colorWithOpacity, normalizeStrokeDashType, getSvgStrokeDasharray, getCompoundLineOffsets, getCompoundLineWidths, svgLineCap, hasTextProperties, getSelectionOutlineColor, connectorWrapperTransform, getAriaRoleDescription, getAriaLabel, getAriaRole, resolveElementInteractivity, isEditableTextElement, buildTextStyleOverrideCss, isElementRendered, resolveElementAriaAttributes, shouldRenderHitTarget, elementHitTargetStyle, getImageEffectsOpacity, getImageEffectsFilter, inlineElementPointerEvents, isHollowShapeElement, LINK_TOOLTIP_HOST_CLASS, ACTION_BUTTON_PRESETS, mediaTransportVisible, isInkElement, getGroupChildParentFill, getElementLabel, getResizeHandleHitAreaStyle, paintedStrokeWidth, buildCssGradientFromShapeStyle, ensureActionAffordanceStyles, resolveElementActionAffordance, actionAffordanceLabels, paintedElementSize, getElementTransform, resolveElementHighlightClick, applyHighlightClickStyle, getComputedEffectStyle, getSoftEdgeSvgFilter, getEffectStyleSource, getBevelLightingSvgFilter, buildStrokeOutline, buildHollowHitOutline, buildSubpathFillOverlay, isImageLikeElement, strokeOutlineViewBox, resolveRevealedSmartArtNodes, resolveRevealedDrawingShapes, buildSmartArtA11y, canDrillDown, computeSmartArtElementLayout, flattenNodes, buildSummaryZoomView, isImageTiled, getImageColorWashStyle, readEditableText, placeCaretAtEnd, getPendingSelectionRestore, restoreSegmentSelection, getTextCompensationTransform, resolveChartKind, subscribeBarFacePicturePixelSamples, getBarFacePicturePixelSampleVersion, ensureChartInteractionStyles, applyChartPartHighlight, resolveRevealedChartData, formatAxisValue, buildInkGroupStrokes, getInkReplayStyles, INK_REPLAY_KEYFRAMES, buildContentPartStrokes, getContentPartReplayStyles, resolveOleType, getOleAriaLabel, getOleTypeColor, getOleTypeLabel, filterRenderedElements, resolveGroupChildFill, isLinkedTextBox, getOverflowSegments, shouldUseSvgWarp, getTextBodyRotationTransform, placeholderPromptDescriptor, attachRotateHandlePlacement, elementIdSelector, createRotationDrag, ACTION_INDICATOR_CLASS, ACTION_INDICATOR_ICON_PATH, LINK_TOOLTIP_CLASS, LINK_TOOLTIP_PANEL_CLASS, LINK_TOOLTIP_LABEL_CLASS, LINK_TOOLTIP_HINT_CLASS, DEFAULT_PALETTE2, resolvePalette, computeDrawingViewBox, projectDrawingShapes, resolveRevealedDrawingShapeNodeIds, styleShadowFilter, buildChromeStyle, measureSvgViewportRect, modelDataToBlobUrl, getImageSvgFilters, buildDuotoneCacheKey, getDuotoneCachedResult, applyDuotone, setDuotoneCachedResult, buildCacheKey, DEFAULT_COLOR_CHANGE_TOLERANCE, getCachedResult, applyColorChange, setCachedResult, inlineListBodyText, createInlineListSeed, readListActivationSelection, createInlineListModelObserver, attachCollaborationInlineEditor, bindInlineListParagraph, bindInlineListRun, attachInlineListController, restoreInlineListBodySelection, getInlineEditorSelectionResult, isBulletMarkerSegment, findChartPartTarget, buildSurfaceChart3DDataForElement, buildBarChart3DDataForElement, buildLineChart3DDataForElement, buildAreaChart3DDataForElement, buildPieChart3DDataForElement, withChartTitle, resolveSmartArt3DLayout, buildSmartArt3DModel, collectCoherent3DOffNodeIds, isBrowserOpenableMime, formatBytes, getOleDisplayName, getOleBadgeLabel, openUrlInNewTab, getSubstituteFontFamily, hasGlyphEnvelope, buildGlyphEnvelope, getWarpPath, isWedgeCalloutPresetShape, isElementActionable, centeredSvgTextLines, findSmartArtNodeText, setSmartArtNodeStyle, rebuildDrawingShapesIfCleared, shouldCommitSmartArtNodeText, updateSmartArtNodeText, advanceChartMarkDrag, advanceChartValueDrag, buildChartMarkDragGeometry, beginChartMarkDrag, beginChartValueDrag, groupIntoParagraphs, substituteFieldText, computeInlineEditorRect, withChartPointValue, MIN_TOUCH_TARGET_PX, computeVirtualRange, DEFAULT_VIRTUAL_OVERSCAN, createSyncGate, clearLocalAwareness, validateRoomId, createDepartureChannel, resolveTransportForServerUrl, isMixedContentBlocked, CONNECTION_TIMEOUT_MS, registerCollaborationTeardown, createPresenceProjector, BROADCAST_THROTTLE_MS, sanitizeColor, cloneTemplateElementsBySlideId, cloneSlide, createWheelStepBuffer, createViewerZoomStore, clampZoomScale, mapEditingWheel, createActiveAnimationGroup, cancelBuildReveal, clearPlaybackTimers, PresentationAnimationController, resolveMediaTimeNodeElementIds, advanceMainSequence, playGroup, PRESENTATION_HASH, PRESENTATION_NONCE_KEY, PRESENTATION_CHANNEL_NAME, swapPresentationWindows, PRESENTATION_MESSAGE_ORIGIN, clearAudienceContent, buildPresentationAudienceUrl, resolveAudienceScreenPlacement, placeAudienceWindow, storeAudienceContent, isPresentationSessionMessage, endAudienceDisplay, createPresentationKeyBuffer, acceptsPresentationInput, resolveAutoAdvanceDelayMs, hasShowSlideAfter, nextShowSlideIndex, previousShowSlideIndex, createPresenterShowGuard, firstShowSlideIndex, attachPresentationVisibilityPause, presentationEntrySlideIndex, buildMorphTransitionPlan, morphOptionToMode, buildMorphAnimationRules, findInSlides, applyFindReplacements, visibleTemplateElements, createCollaborationLivePatcher, publishLiveInlineText, PptxHandler, createPresentationLoadResources, collectMediaElements, resolveMediaElementSource, collectImagePaths, applyImagePathPatches, resolveTableCellImageUrls, resolveTableStyleImageUrls, partitionTemplateElements, seedRecentColors, resolveAuthoredCustomShowId, buildInitialGuides, readOnlyRecommendation, compatibilityWarningToasts, EncryptedFileError, resolveAutosaveIntervalMs, shouldWriteAutosaveSnapshot, saveAutosaveSnapshot, autosaveSnapshotMark, updateMasterViewElement, isTemplateElementId, updateElement, masterViewElements, replaceMasterViewElements, addSection, renameSection, deleteSection, moveSectionUp, moveSectionDown, moveSlidesToSection, canInteractWithElement, prepareExportClone, normalizeColorsForCapture, preprocessCssForCapture, slideProgressPercent, slideStatusLabel, EXPORT_ASSEMBLING_PERCENT, EXPORT_DONE_PERCENT, isExportAbortError, resolveImageResolutionScale, applyThemeToData, THEME_PRESETS, themeColorSchemesEqual, comparePresentation, applyAcceptSlide, applyAcceptAllSlides, collectUsedFonts, describeFontEmbedding, isMobileViewport, resolveAuthoredSlideRange, mayLeaveSlideShow, stopAllPersistentAudio, guidePxToEmu, buildSaveSlides, buildDeckSaveOptions, resolveSlideSizeSelection, saveDeckWithPassword, shouldProbeAutosaveRecovery, probeAutosaveRecovery, acceptAutosaveRecovery, discardAutosaveRecovery, shouldLoopContinuously, applyRehearsalTimings, copyFormatFromElement, applyFormatToElement, collectReferencedFontFamilies, resolveGoogleWebfontHref, syncGoogleWebfontStylesheet, selectGoogleWebfontFamilies, fetchGoogleWebfontOutlineBytes, mapSlideShowStartKey, mapEditorKey, isEditorTextInputTarget, prepareElementForInsertion, createViewerOptionsStore, observeYDocSlides, LOCAL_SYNC_ORIGIN, readSlidesFromYDoc, shouldRoomSlidesReplaceLoad, reconcileSlidesInYDoc, shouldAutoFollowBroadcaster, detectTouchDevice, detectOrientation, deriveViewportBreakpoints, createTouchGestureRecognizer, MAX_ZOOM_SCALE, MIN_ZOOM_SCALE, isKeyboardOpen, scopeLayoutOptionsToSlide, checkModifyPassword, viewerPreferencesFromViewProperties, DEFAULT_VIEWER_PREFERENCES, viewPropertiesPatchFromPreferences, openPptxFile, readBackstageRecentFile, resolveCollaborationShellEditability, resolveCollaborationShellState, MORPH_CROSSFADE_GROUP_STYLE, MORPH_CROSSFADE_HALF_STYLE, getSlideTransitionAnimations, getFragmentedTransitionDescriptor, SLIDE_TRANSITION_KEYFRAMES, isActionHidden, buildInlineTextCommitPatch, resolveInlineEditAutoFitHeight, resolveInlineEditNormAutofitShrink, filterInteractableIds, beginShapeAdjustment, buildElementClipboardPayload, savedPresentationFileName, downloadBlob, exportDeckJson, groupElements, generateElementId, makeCloneId, ungroupElements, alignElements, distributeElements, newTableElement, createDefaultChartElement, readViewportMetrics, computeKeyboardInset, mergeShapes, mapPresentationKey, lastShowSlideIndex, mapPresentationWheel, openPendingPrintWindow, computeColorFilter, filterHiddenSlideIndices, computeSlideIndices, buildPrintDocument, finishPrintWindow, buildPrintHtmlDocument, buildOutlineHtml, buildSlidesHtml, buildNotesHtml, buildHandoutsHtml, createBlankSlide, makeSlideId, buildSlideTemplateSlide, templateSchemeFromTheme, buildThemeColorMap, reResolveSlideColors, reResolveElementColors, resolveViewportFitOptions, calculateViewportFit, scheduleAutoAdvanceChain, computeEntranceAnimationDelay, createPresentationSessionId, resolveTransitionDurationMs, resolveTransitionSoundAction, runPresentationAction, safeOpenUrl, buildRunProgramNotice, toggleStageElementMedia, resolveOleVerbTarget, downloadDataUrl, createPresenterTimer, createInitialPresentationSnapshot, mergePresentationSnapshot, resetPresenterTimer, presenterElapsed, stepPresenterZoom, togglePresenterTimer, addCommentToList, removeCommentFromList, editCommentInList, toggleCommentResolvedInList, remapTextToSegments, buildInlineListStylePatch, applyActiveInlineListFormatting, applyListStyleUpdate, setPendingSelectionRestore, applyTextStyleUpdate, toggleSelectionBullets, transformInlineListCase, applyCaseTransformToSegments, transformTextCase, resolveExportCaptureDecision, recordProgressPercent, computeGridSpacingPx, resolveShowSlideIndexes, groupSlidesBySection, masterViewPseudoSlide, overlayMasterViewInlineSnapshot, overlayInlineTextSnapshot, cloneElementUpdates, assertElementUpdateTarget, prepareElementUpdateBatch, createWriteBackScheduler, observeExternalCollaborationReadiness, resolveHistoryDepth, hasCopyableFormat, createBackstagePresentation, buildFieldSubstitutionContext, cloneElementForPaste, computeScrollDelta, getPresetShapeClipPath, svgPathToPolygons, polygonsToSvgPath, rerouteConnectorsForMovedElements, applyReroutedConnectors, SvgExporter, replyToCommentInList, removeTableElementColumn, insertTableElementColumn, removeTableElementRow, insertTableElementRow, updateCellTextStyleInRawXml, setCellText, updateCellTextInRawXml, splitCell, updateMergeAttrsInRawXml, mergeCells, pickSupportedMimeType, WEBM_MIME_CANDIDATES, fpsToFrameIntervalMs, segmentFrameCount, stopCaptureStream, GIF_POST_CAPTURE_MAX_SIDE, encodeGif, rasterResultToPngBlob, rasterizeElementTiles, placeTileOnPage, PDF_SLIDES_PAGE_WIDTH_PT, PDF_SLIDES_PAGE_HEIGHT_PT, canvasToJpegData, createSnapshotTextPositions, isPpactionUrl, parsePpactionUrl, resolvePresentationAction, elementActionToPptxAction, isUrlSafe, buildSmartArtPresetData, classifyMediaType, computeSnapToShape, publishLiveGeometry, getDraggedShapeAdjustments, computeMarqueeHitIds, mergeAdditiveSelection, rasterizeElementTiledToCanvas, borrowExternalCollaborationAwareness, observeExternalCollaborationSession, clampGifDimensions, rasterizeElement, shouldConfirmExternalHyperlink, applyResize, lockResizeAspect, snapBoxToGrid, applyMotionPathPreset, bringForward, sendBackward, bringToFront, sendToBack } from './chunk-7X6UCEYM.mjs';
|
|
3
3
|
import { translationsEn } from './chunk-PC7H3C5W.mjs';
|
|
4
4
|
import React20, { createContext, useMemo, useState, useCallback, useEffect, Suspense, useRef, useLayoutEffect, useContext, useSyncExternalStore, useImperativeHandle } from 'react';
|
|
5
5
|
import { jsxs, jsx, Fragment } from 'react/jsx-runtime';
|
|
@@ -645,12 +645,31 @@ function useSheetDismissDrag(onClose, threshold = 120) {
|
|
|
645
645
|
}
|
|
646
646
|
|
|
647
647
|
// src/viewer/hooks/explicit-slide-history.ts
|
|
648
|
+
function historyElementContent(element) {
|
|
649
|
+
return {
|
|
650
|
+
...element,
|
|
651
|
+
// Saving refreshes these archive-only fields in place. They are needed by
|
|
652
|
+
// serialization, but neither one represents a user edit.
|
|
653
|
+
rawXml: void 0,
|
|
654
|
+
shapeId: void 0,
|
|
655
|
+
...element.type === "group" ? { children: element.children.map(historyElementContent) } : {}
|
|
656
|
+
};
|
|
657
|
+
}
|
|
648
658
|
function serializeHistoryDocument(snapshot) {
|
|
649
659
|
return JSON.stringify({
|
|
650
660
|
width: snapshot.width,
|
|
651
661
|
height: snapshot.height,
|
|
652
|
-
slides: snapshot.slides
|
|
653
|
-
|
|
662
|
+
slides: snapshot.slides.map((slide) => ({
|
|
663
|
+
...slide,
|
|
664
|
+
rawXml: void 0,
|
|
665
|
+
elements: slide.elements.map(historyElementContent)
|
|
666
|
+
})),
|
|
667
|
+
templateElementsBySlideId: Object.fromEntries(
|
|
668
|
+
Object.entries(snapshot.templateElementsBySlideId).map(([slideId, elements]) => [
|
|
669
|
+
slideId,
|
|
670
|
+
elements.map(historyElementContent)
|
|
671
|
+
])
|
|
672
|
+
)
|
|
654
673
|
});
|
|
655
674
|
}
|
|
656
675
|
function recordExplicitSlideUpdate(past, future, previous, before, label, maxDepth) {
|
|
@@ -13410,7 +13429,7 @@ function FailedToLoad() {
|
|
|
13410
13429
|
var LazyArea3DChartScene = React20.lazy(
|
|
13411
13430
|
async () => {
|
|
13412
13431
|
try {
|
|
13413
|
-
return await import('./Area3DChartScene-
|
|
13432
|
+
return await import('./Area3DChartScene-WNEHMOG2.mjs');
|
|
13414
13433
|
} catch {
|
|
13415
13434
|
return { default: FailedToLoad };
|
|
13416
13435
|
}
|
|
@@ -13479,7 +13498,7 @@ function FailedToLoad2() {
|
|
|
13479
13498
|
var LazyBar3DChartScene = React20.lazy(
|
|
13480
13499
|
async () => {
|
|
13481
13500
|
try {
|
|
13482
|
-
return await import('./Bar3DChartScene-
|
|
13501
|
+
return await import('./Bar3DChartScene-E53RZRI4.mjs');
|
|
13483
13502
|
} catch {
|
|
13484
13503
|
return { default: FailedToLoad2 };
|
|
13485
13504
|
}
|
|
@@ -13582,7 +13601,7 @@ function FailedToLoad3() {
|
|
|
13582
13601
|
var LazyLine3DChartScene = React20.lazy(
|
|
13583
13602
|
async () => {
|
|
13584
13603
|
try {
|
|
13585
|
-
return await import('./Line3DChartScene-
|
|
13604
|
+
return await import('./Line3DChartScene-YJ2POVES.mjs');
|
|
13586
13605
|
} catch {
|
|
13587
13606
|
return { default: FailedToLoad3 };
|
|
13588
13607
|
}
|
|
@@ -13651,7 +13670,7 @@ function FailedToLoad4() {
|
|
|
13651
13670
|
var LazyPieChart3DScene = React20.lazy(
|
|
13652
13671
|
async () => {
|
|
13653
13672
|
try {
|
|
13654
|
-
return await import('./PieChart3DScene-
|
|
13673
|
+
return await import('./PieChart3DScene-YYBYC5AM.mjs');
|
|
13655
13674
|
} catch {
|
|
13656
13675
|
return { default: FailedToLoad4 };
|
|
13657
13676
|
}
|
|
@@ -13718,7 +13737,7 @@ function FailedToLoad5() {
|
|
|
13718
13737
|
var LazySurfaceChart3DScene = React20.lazy(
|
|
13719
13738
|
async () => {
|
|
13720
13739
|
try {
|
|
13721
|
-
return await import('./SurfaceChart3DScene-
|
|
13740
|
+
return await import('./SurfaceChart3DScene-FFYG6CNE.mjs');
|
|
13722
13741
|
} catch {
|
|
13723
13742
|
return { default: FailedToLoad5 };
|
|
13724
13743
|
}
|
|
@@ -16172,7 +16191,7 @@ function FailedToLoad6() {
|
|
|
16172
16191
|
var LazyModel3DScene = React20.lazy(
|
|
16173
16192
|
async () => {
|
|
16174
16193
|
try {
|
|
16175
|
-
return await import('./Model3DScene-
|
|
16194
|
+
return await import('./Model3DScene-MYODSOVU.mjs');
|
|
16176
16195
|
} catch {
|
|
16177
16196
|
return { default: FailedToLoad6 };
|
|
16178
16197
|
}
|
|
Binary file
|
|
Binary file
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { SHAPE_PRESET_DEFS, VIEWER_SHORTCUT_REFERENCE, STROKE_DASH_OPTIONS, getAnimationInitialStyle, cloneHistorySnapshot, hasShapeProperties, getImageFitStyle, getImageFillCounterTransform, getComputedFillStyle, isImageLikeElement, getCropShapeClipPath, getImageTilingStyle, mediaPlaybackAttributes, buildTextBlockStyle, hasTextProperties, toCssWritingMode, toCssTextOrientation, toCssVerticalDirection, buildTextBodyLayoutStyle, buildTextBody3DSceneStyle, buildParagraphs, colorWithOpacity, normalizeHexColor, hexToRgbUnit, build3DExtrusionData, getComputedEffectStyle, getComputedStrokeStyle, getAnimationColorBaseStyle, isStrokeOnlyPresetElement, resolveShapeGeometry, getConnectorPathGeometry, normalizeStrokeDashType, getSvgStrokeDasharray, buildSvgGradientDef, buildStrokeOutline, getPresetShapeVectorGeometry, isWedgeCalloutPresetShape, svgGradientFillRef, isCalloutShape, getCalloutLeaderLineGeometry, buildCalloutLeaderLineSvgPath, getCalloutViewBoxBounds, svgLineCap, getCompoundLineOffsets, getCompoundLineWidths, canDrillDown, computeSelectionRect, DEFAULT_FONT_FAMILY, cellStyleToCss, rectToCells, isCellInRect, tableContainerCss, buildChartViewModel, resolveChartKind, chartPreserveAspectRatio, buildNotesPdfBytes, buildTiledSlidesPdfBytes, buildPreviewAnimation, buildMotionPathPreview, mediaFallbackVisual, scheduleMediaTrimAndFade, registerCrossSlideAudio, withInlineListDecorationDefaults, segmentStyleToCss, resolveAutoFitFontScale, applyUnderlineVariant, nestedTextDecorationStyle, resolveFontKerning, getSubstituteFontFamily, parsePanoseString, resolveScriptFontSet, hasDistinctScriptFonts, pieceLetterSpacing, resolveMetricTrackingPx, hollowTextFillStyle, stripUnderlineDecoration, buildTabContext, TEXT_BUILD_ID_SEP, buildTextBuildSpec, textBuildSpanStyle, apply3dEffects, customGeometryPathsToSvgSubpaths, buildSubpathPaints, computeColumnBoundaries, getTableCellBandStyle, parseDrawingColor, parseDrawingColorOpacity, getCellDiagonalBorders, xmlText, cellRunStyle, getChartStylePalette, computeChartLegendLayout, mediaFallbackIcon, mediaFallbackLabelKey, MEDIA_CHROME_ATTRIBUTE, convertOmmlToMathMl, sanitizeMathMl, tableCellCss, computeResizedColumnWidths, computeResizedRowHeight, DEFAULT_ROW_HEIGHT, ooxmlGradientAngleToCssDegrees, buildRectPathGradient, buildRunTabLines, chartPartToAttrs, splitWordsForUnderline, splitRunForMetrics, splitRunByScriptFont } from './chunk-
|
|
1
|
+
import { SHAPE_PRESET_DEFS, VIEWER_SHORTCUT_REFERENCE, STROKE_DASH_OPTIONS, getAnimationInitialStyle, cloneHistorySnapshot, hasShapeProperties, getImageFitStyle, getImageFillCounterTransform, getComputedFillStyle, isImageLikeElement, getCropShapeClipPath, getImageTilingStyle, mediaPlaybackAttributes, buildTextBlockStyle, hasTextProperties, toCssWritingMode, toCssTextOrientation, toCssVerticalDirection, buildTextBodyLayoutStyle, buildTextBody3DSceneStyle, buildParagraphs, colorWithOpacity, normalizeHexColor, hexToRgbUnit, build3DExtrusionData, getComputedEffectStyle, getComputedStrokeStyle, getAnimationColorBaseStyle, isStrokeOnlyPresetElement, resolveShapeGeometry, getConnectorPathGeometry, normalizeStrokeDashType, getSvgStrokeDasharray, buildSvgGradientDef, buildStrokeOutline, getPresetShapeVectorGeometry, isWedgeCalloutPresetShape, svgGradientFillRef, isCalloutShape, getCalloutLeaderLineGeometry, buildCalloutLeaderLineSvgPath, getCalloutViewBoxBounds, svgLineCap, getCompoundLineOffsets, getCompoundLineWidths, canDrillDown, computeSelectionRect, DEFAULT_FONT_FAMILY, cellStyleToCss, rectToCells, isCellInRect, tableContainerCss, buildChartViewModel, resolveChartKind, chartPreserveAspectRatio, buildNotesPdfBytes, buildTiledSlidesPdfBytes, buildPreviewAnimation, buildMotionPathPreview, mediaFallbackVisual, scheduleMediaTrimAndFade, registerCrossSlideAudio, withInlineListDecorationDefaults, segmentStyleToCss, resolveAutoFitFontScale, applyUnderlineVariant, nestedTextDecorationStyle, resolveFontKerning, getSubstituteFontFamily, parsePanoseString, resolveScriptFontSet, hasDistinctScriptFonts, pieceLetterSpacing, resolveMetricTrackingPx, hollowTextFillStyle, stripUnderlineDecoration, buildTabContext, TEXT_BUILD_ID_SEP, buildTextBuildSpec, textBuildSpanStyle, apply3dEffects, customGeometryPathsToSvgSubpaths, buildSubpathPaints, computeColumnBoundaries, getTableCellBandStyle, parseDrawingColor, parseDrawingColorOpacity, getCellDiagonalBorders, xmlText, cellRunStyle, getChartStylePalette, computeChartLegendLayout, mediaFallbackIcon, mediaFallbackLabelKey, MEDIA_CHROME_ATTRIBUTE, convertOmmlToMathMl, sanitizeMathMl, tableCellCss, computeResizedColumnWidths, computeResizedRowHeight, DEFAULT_ROW_HEIGHT, ooxmlGradientAngleToCssDegrees, buildRectPathGradient, buildRunTabLines, chartPartToAttrs, splitWordsForUnderline, splitRunForMetrics, splitRunByScriptFont } from './chunk-7X6UCEYM.mjs';
|
|
2
2
|
import { translationsEn } from './chunk-PC7H3C5W.mjs';
|
|
3
3
|
import { clsx } from 'clsx';
|
|
4
4
|
import { twMerge } from 'tailwind-merge';
|
|
Binary file
|
|
Binary file
|
|
@@ -196757,117 +196757,6 @@ async function saveAutosaveSnapshot(filePath, data) {
|
|
|
196757
196757
|
return putAutosaveRecord(filePath, data);
|
|
196758
196758
|
}
|
|
196759
196759
|
}
|
|
196760
|
-
var AUTOSAVE_RECOVERY_WINDOW_MS = 24 * 60 * 60 * 1e3;
|
|
196761
|
-
var CONSUMED_KEY = "pptx-viewer-recovery-consumed";
|
|
196762
|
-
function markAutosaveSnapshotConsumed(timestamp) {
|
|
196763
|
-
try {
|
|
196764
|
-
if (typeof sessionStorage === "undefined" || !Number.isFinite(timestamp)) {
|
|
196765
|
-
return;
|
|
196766
|
-
}
|
|
196767
|
-
const previous = consumedAutosaveSnapshotTimestamp();
|
|
196768
|
-
if (timestamp > previous) {
|
|
196769
|
-
sessionStorage.setItem(CONSUMED_KEY, String(timestamp));
|
|
196770
|
-
}
|
|
196771
|
-
} catch {
|
|
196772
|
-
}
|
|
196773
|
-
}
|
|
196774
|
-
function consumedAutosaveSnapshotTimestamp() {
|
|
196775
|
-
try {
|
|
196776
|
-
if (typeof sessionStorage === "undefined") {
|
|
196777
|
-
return 0;
|
|
196778
|
-
}
|
|
196779
|
-
const raw = sessionStorage.getItem(CONSUMED_KEY);
|
|
196780
|
-
const value = raw === null ? Number.NaN : Number(raw);
|
|
196781
|
-
return Number.isFinite(value) ? value : 0;
|
|
196782
|
-
} catch {
|
|
196783
|
-
return 0;
|
|
196784
|
-
}
|
|
196785
|
-
}
|
|
196786
|
-
function shouldProbeAutosaveRecovery(input) {
|
|
196787
|
-
return !input.alreadyChecked && input.autosaveAllowed && Boolean(input.filePath) && !input.loading && !input.error && input.slideCount > 0;
|
|
196788
|
-
}
|
|
196789
|
-
function formatSnapshotSize(bytes) {
|
|
196790
|
-
if (!Number.isFinite(bytes) || bytes <= 0) {
|
|
196791
|
-
return "0 KB";
|
|
196792
|
-
}
|
|
196793
|
-
if (bytes < 1024 * 1024) {
|
|
196794
|
-
return `${Math.max(1, Math.round(bytes / 1024))} KB`;
|
|
196795
|
-
}
|
|
196796
|
-
return `${(bytes / (1024 * 1024)).toFixed(1)} MB`;
|
|
196797
|
-
}
|
|
196798
|
-
function ageKeyFor(ageMinutes) {
|
|
196799
|
-
if (ageMinutes < 1) {
|
|
196800
|
-
return { key: "pptx.autosave.justNow", count: 0 };
|
|
196801
|
-
}
|
|
196802
|
-
if (ageMinutes === 1) {
|
|
196803
|
-
return { key: "pptx.autosave.oneMinAgo", count: 1 };
|
|
196804
|
-
}
|
|
196805
|
-
if (ageMinutes < 60) {
|
|
196806
|
-
return { key: "pptx.autosave.minutesAgo", count: ageMinutes };
|
|
196807
|
-
}
|
|
196808
|
-
return { key: "pptx.autosave.recovery.hoursAgo", count: Math.floor(ageMinutes / 60) };
|
|
196809
|
-
}
|
|
196810
|
-
function autosaveRecoveryPrompt(input) {
|
|
196811
|
-
const record2 = input.record;
|
|
196812
|
-
if (!record2 || record2.size <= 0 || !record2.key) {
|
|
196813
|
-
return null;
|
|
196814
|
-
}
|
|
196815
|
-
const age = input.now - record2.timestamp;
|
|
196816
|
-
if (!Number.isFinite(age) || age < 0 || age >= AUTOSAVE_RECOVERY_WINDOW_MS) {
|
|
196817
|
-
return null;
|
|
196818
|
-
}
|
|
196819
|
-
if (record2.timestamp <= (input.consumedTimestamp ?? 0)) {
|
|
196820
|
-
return null;
|
|
196821
|
-
}
|
|
196822
|
-
const ageMinutes = Math.floor(age / 6e4);
|
|
196823
|
-
const relative = ageKeyFor(ageMinutes);
|
|
196824
|
-
return {
|
|
196825
|
-
filePath: record2.key,
|
|
196826
|
-
timestamp: record2.timestamp,
|
|
196827
|
-
size: record2.size,
|
|
196828
|
-
ageMinutes,
|
|
196829
|
-
titleKey: "pptx.autosave.recovery.title",
|
|
196830
|
-
messageKey: "pptx.autosave.recovery.message",
|
|
196831
|
-
messageParams: { file: record2.key, size: formatSnapshotSize(record2.size) },
|
|
196832
|
-
ageKey: relative.key,
|
|
196833
|
-
ageParams: { count: relative.count },
|
|
196834
|
-
restoreKey: "pptx.autosave.recovery.restore",
|
|
196835
|
-
discardKey: "pptx.autosave.recovery.discard"
|
|
196836
|
-
};
|
|
196837
|
-
}
|
|
196838
|
-
function shouldShowAutosaveRecoveryPrompt(input) {
|
|
196839
|
-
return Boolean(input.prompt) && !input.presenting;
|
|
196840
|
-
}
|
|
196841
|
-
async function probeAutosaveRecovery(filePath, now = Date.now()) {
|
|
196842
|
-
if (typeof indexedDB === "undefined") {
|
|
196843
|
-
return null;
|
|
196844
|
-
}
|
|
196845
|
-
try {
|
|
196846
|
-
const record2 = await getAutosaveSnapshot(filePath);
|
|
196847
|
-
const prompt = autosaveRecoveryPrompt({
|
|
196848
|
-
record: record2 ? { key: record2.key, timestamp: record2.timestamp, size: record2.size } : void 0,
|
|
196849
|
-
now,
|
|
196850
|
-
consumedTimestamp: consumedAutosaveSnapshotTimestamp()
|
|
196851
|
-
});
|
|
196852
|
-
if (!prompt || !record2) {
|
|
196853
|
-
return null;
|
|
196854
|
-
}
|
|
196855
|
-
return { prompt, record: record2 };
|
|
196856
|
-
} catch {
|
|
196857
|
-
return null;
|
|
196858
|
-
}
|
|
196859
|
-
}
|
|
196860
|
-
function acceptAutosaveRecovery(record2) {
|
|
196861
|
-
markAutosaveSnapshotConsumed(record2.timestamp);
|
|
196862
|
-
return record2.data instanceof Uint8Array ? record2.data : new Uint8Array(record2.data);
|
|
196863
|
-
}
|
|
196864
|
-
async function discardAutosaveRecovery(record2) {
|
|
196865
|
-
markAutosaveSnapshotConsumed(record2.timestamp);
|
|
196866
|
-
try {
|
|
196867
|
-
await deleteAutosaveSnapshot(record2.key);
|
|
196868
|
-
} catch {
|
|
196869
|
-
}
|
|
196870
|
-
}
|
|
196871
196760
|
function secureRandomBytes(length) {
|
|
196872
196761
|
const bytes = new Uint8Array(length);
|
|
196873
196762
|
if (typeof crypto !== "undefined" && typeof crypto.getRandomValues === "function") {
|
|
@@ -197066,7 +196955,6 @@ async function restoreSessionDeck() {
|
|
|
197066
196955
|
const snapshot = await getAutosaveSnapshot(deck.fileName);
|
|
197067
196956
|
const bytes = snapshot ? toBytes(snapshot.data) : null;
|
|
197068
196957
|
if (snapshot && bytes && bytes.byteLength > 0 && snapshot.timestamp > deck.timestamp) {
|
|
197069
|
-
markAutosaveSnapshotConsumed(snapshot.timestamp);
|
|
197070
196958
|
return { fileName: deck.fileName, data: bytes, timestamp: snapshot.timestamp };
|
|
197071
196959
|
}
|
|
197072
196960
|
} catch {
|
|
@@ -203526,6 +203414,86 @@ function resolveAutosaveIntervalMs(input) {
|
|
|
203526
203414
|
}
|
|
203527
203415
|
return AUTOSAVE_DEFAULT_INTERVAL_MS;
|
|
203528
203416
|
}
|
|
203417
|
+
var AUTOSAVE_RECOVERY_WINDOW_MS = 24 * 60 * 60 * 1e3;
|
|
203418
|
+
function shouldProbeAutosaveRecovery(input) {
|
|
203419
|
+
return !input.alreadyChecked && input.autosaveAllowed && Boolean(input.filePath) && !input.loading && !input.error && input.slideCount > 0;
|
|
203420
|
+
}
|
|
203421
|
+
function formatSnapshotSize(bytes) {
|
|
203422
|
+
if (!Number.isFinite(bytes) || bytes <= 0) {
|
|
203423
|
+
return "0 KB";
|
|
203424
|
+
}
|
|
203425
|
+
if (bytes < 1024 * 1024) {
|
|
203426
|
+
return `${Math.max(1, Math.round(bytes / 1024))} KB`;
|
|
203427
|
+
}
|
|
203428
|
+
return `${(bytes / (1024 * 1024)).toFixed(1)} MB`;
|
|
203429
|
+
}
|
|
203430
|
+
function ageKeyFor(ageMinutes) {
|
|
203431
|
+
if (ageMinutes < 1) {
|
|
203432
|
+
return { key: "pptx.autosave.justNow", count: 0 };
|
|
203433
|
+
}
|
|
203434
|
+
if (ageMinutes === 1) {
|
|
203435
|
+
return { key: "pptx.autosave.oneMinAgo", count: 1 };
|
|
203436
|
+
}
|
|
203437
|
+
if (ageMinutes < 60) {
|
|
203438
|
+
return { key: "pptx.autosave.minutesAgo", count: ageMinutes };
|
|
203439
|
+
}
|
|
203440
|
+
return { key: "pptx.autosave.recovery.hoursAgo", count: Math.floor(ageMinutes / 60) };
|
|
203441
|
+
}
|
|
203442
|
+
function autosaveRecoveryPrompt(input) {
|
|
203443
|
+
const record2 = input.record;
|
|
203444
|
+
if (!record2 || record2.size <= 0 || !record2.key) {
|
|
203445
|
+
return null;
|
|
203446
|
+
}
|
|
203447
|
+
const age = input.now - record2.timestamp;
|
|
203448
|
+
if (!Number.isFinite(age) || age < 0 || age >= AUTOSAVE_RECOVERY_WINDOW_MS) {
|
|
203449
|
+
return null;
|
|
203450
|
+
}
|
|
203451
|
+
const ageMinutes = Math.floor(age / 6e4);
|
|
203452
|
+
const relative = ageKeyFor(ageMinutes);
|
|
203453
|
+
return {
|
|
203454
|
+
filePath: record2.key,
|
|
203455
|
+
timestamp: record2.timestamp,
|
|
203456
|
+
size: record2.size,
|
|
203457
|
+
ageMinutes,
|
|
203458
|
+
titleKey: "pptx.autosave.recovery.title",
|
|
203459
|
+
messageKey: "pptx.autosave.recovery.message",
|
|
203460
|
+
messageParams: { file: record2.key, size: formatSnapshotSize(record2.size) },
|
|
203461
|
+
ageKey: relative.key,
|
|
203462
|
+
ageParams: { count: relative.count },
|
|
203463
|
+
restoreKey: "pptx.autosave.recovery.restore",
|
|
203464
|
+
discardKey: "pptx.autosave.recovery.discard"
|
|
203465
|
+
};
|
|
203466
|
+
}
|
|
203467
|
+
function shouldShowAutosaveRecoveryPrompt(input) {
|
|
203468
|
+
return Boolean(input.prompt) && !input.presenting;
|
|
203469
|
+
}
|
|
203470
|
+
async function probeAutosaveRecovery(filePath, now = Date.now()) {
|
|
203471
|
+
if (typeof indexedDB === "undefined") {
|
|
203472
|
+
return null;
|
|
203473
|
+
}
|
|
203474
|
+
try {
|
|
203475
|
+
const record2 = await getAutosaveSnapshot(filePath);
|
|
203476
|
+
const prompt = autosaveRecoveryPrompt({
|
|
203477
|
+
record: record2 ? { key: record2.key, timestamp: record2.timestamp, size: record2.size } : void 0,
|
|
203478
|
+
now
|
|
203479
|
+
});
|
|
203480
|
+
if (!prompt || !record2) {
|
|
203481
|
+
return null;
|
|
203482
|
+
}
|
|
203483
|
+
return { prompt, record: record2 };
|
|
203484
|
+
} catch {
|
|
203485
|
+
return null;
|
|
203486
|
+
}
|
|
203487
|
+
}
|
|
203488
|
+
function acceptAutosaveRecovery(record2) {
|
|
203489
|
+
return record2.data instanceof Uint8Array ? record2.data : new Uint8Array(record2.data);
|
|
203490
|
+
}
|
|
203491
|
+
async function discardAutosaveRecovery(record2) {
|
|
203492
|
+
try {
|
|
203493
|
+
await deleteAutosaveSnapshot(record2.key);
|
|
203494
|
+
} catch {
|
|
203495
|
+
}
|
|
203496
|
+
}
|
|
203529
203497
|
var BACKSTAGE_NAV = [
|
|
203530
203498
|
{ id: "home", label: "Home", labelKey: "pptx.backstage.nav.home" },
|
|
203531
203499
|
{ id: "new", label: "New", labelKey: "pptx.backstage.nav.new" },
|
|
Binary file
|
|
Binary file
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkJLQWPRIM_js = require('./chunk-JLQWPRIM.js');
|
|
4
4
|
var chunk4VNS5WPM_js = require('./chunk-4VNS5WPM.js');
|
|
5
5
|
var mcp = require('pptx-viewer-mcp');
|
|
6
6
|
var mcpSchemas = require('pptx-viewer-mcp/schemas');
|
|
@@ -19079,7 +19079,7 @@ async function buildSlideMarkdown(slides, slideIndex2, meta3, options = {}) {
|
|
|
19079
19079
|
};
|
|
19080
19080
|
let markdown;
|
|
19081
19081
|
try {
|
|
19082
|
-
const converter = new
|
|
19082
|
+
const converter = new chunkJLQWPRIM_js.PptxMarkdownConverter(
|
|
19083
19083
|
"",
|
|
19084
19084
|
{
|
|
19085
19085
|
sourceName: meta3.title ?? "deck.pptx",
|
|
@@ -19671,7 +19671,7 @@ var getTheme = (ctx) => {
|
|
|
19671
19671
|
name: theme?.name,
|
|
19672
19672
|
colorScheme: theme?.colorScheme,
|
|
19673
19673
|
fontScheme: theme?.fontScheme,
|
|
19674
|
-
availablePresets: Object.keys(
|
|
19674
|
+
availablePresets: Object.keys(chunkJLQWPRIM_js.ThemePresets)
|
|
19675
19675
|
};
|
|
19676
19676
|
};
|
|
19677
19677
|
var readExecutors = {
|
|
@@ -20776,7 +20776,7 @@ function applyElementUpdate(el, u) {
|
|
|
20776
20776
|
applyShapeStyleUpdate(el, u);
|
|
20777
20777
|
}
|
|
20778
20778
|
function applyTextUpdate(el, u) {
|
|
20779
|
-
if (!
|
|
20779
|
+
if (!chunkJLQWPRIM_js.hasTextProperties(el)) {
|
|
20780
20780
|
return;
|
|
20781
20781
|
}
|
|
20782
20782
|
const textEl = el;
|
|
@@ -20822,7 +20822,7 @@ function applyShapeStyleUpdate(el, u) {
|
|
|
20822
20822
|
if (u.fillColor === void 0 && u.strokeColor === void 0 && u.strokeWidth === void 0) {
|
|
20823
20823
|
return;
|
|
20824
20824
|
}
|
|
20825
|
-
if (!
|
|
20825
|
+
if (!chunkJLQWPRIM_js.hasShapeProperties(el)) {
|
|
20826
20826
|
return;
|
|
20827
20827
|
}
|
|
20828
20828
|
const holder = el;
|
|
Binary file
|
|
Binary file
|