pptx-react-viewer 4.13.0 → 4.14.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +26 -0
- package/dist/{AiChatPanel-VXQUQNZ6.js → AiChatPanel-PULXQTFJ.js} +27 -27
- package/dist/AiChatPanel-PULXQTFJ.js.br +0 -0
- package/dist/AiChatPanel-PULXQTFJ.js.gz +0 -0
- package/dist/{AiChatPanel-AQDB2BLO.mjs → AiChatPanel-WQUOEVQB.mjs} +3 -3
- package/dist/AiChatPanel-WQUOEVQB.mjs.br +0 -0
- package/dist/AiChatPanel-WQUOEVQB.mjs.gz +0 -0
- package/dist/{Model3DScene-I6OVMXEE.js → Model3DScene-6MYHPE5N.js} +2 -2
- package/dist/Model3DScene-6MYHPE5N.js.br +0 -0
- package/dist/Model3DScene-6MYHPE5N.js.gz +0 -0
- package/dist/{Model3DScene-UHHKYZSK.mjs → Model3DScene-HZG33BWN.mjs} +1 -1
- package/dist/Model3DScene-HZG33BWN.mjs.br +0 -0
- package/dist/Model3DScene-HZG33BWN.mjs.gz +0 -0
- package/dist/{chunk-UOS5HJLG.js → chunk-6ZR27XTL.js} +166 -110
- package/dist/chunk-6ZR27XTL.js.br +0 -0
- package/dist/chunk-6ZR27XTL.js.gz +0 -0
- package/dist/{chunk-5DQNWKOF.mjs → chunk-AJTFPTSN.mjs} +1 -1
- package/dist/chunk-AJTFPTSN.mjs.br +0 -0
- package/dist/chunk-AJTFPTSN.mjs.gz +0 -0
- package/dist/{chunk-5YW6N5KJ.js → chunk-DI4YTG3J.js} +187 -187
- package/dist/chunk-DI4YTG3J.js.br +0 -0
- package/dist/chunk-DI4YTG3J.js.gz +0 -0
- package/dist/{chunk-57RBEPPQ.js → chunk-E6VYR3GM.js} +806 -806
- package/dist/chunk-E6VYR3GM.js.br +0 -0
- package/dist/chunk-E6VYR3GM.js.gz +0 -0
- package/dist/{chunk-SLMDLVFV.mjs → chunk-ECKXYCP3.mjs} +1 -1
- package/dist/chunk-ECKXYCP3.mjs.br +0 -0
- package/dist/chunk-ECKXYCP3.mjs.gz +0 -0
- package/dist/{chunk-HJBTQ234.mjs → chunk-EPMT65EN.mjs} +3 -3
- package/dist/chunk-EPMT65EN.mjs.br +0 -0
- package/dist/chunk-EPMT65EN.mjs.gz +0 -0
- package/dist/{chunk-KA24ZRTJ.js → chunk-RK5UV5HL.js} +1187 -1187
- package/dist/chunk-RK5UV5HL.js.br +0 -0
- package/dist/chunk-RK5UV5HL.js.gz +0 -0
- package/dist/{chunk-JUUI5DHB.mjs → chunk-UWVRB4Z5.mjs} +166 -110
- package/dist/chunk-UWVRB4Z5.mjs.br +0 -0
- package/dist/chunk-UWVRB4Z5.mjs.gz +0 -0
- package/dist/{chunk-C5ZJGQ2F.mjs → chunk-WSYKEPW6.mjs} +6 -6
- package/dist/chunk-WSYKEPW6.mjs.br +0 -0
- package/dist/chunk-WSYKEPW6.mjs.gz +0 -0
- package/dist/{chunk-MXH7RMTF.js → chunk-XWO367ZG.js} +5 -5
- package/dist/chunk-XWO367ZG.js.br +0 -0
- package/dist/chunk-XWO367ZG.js.gz +0 -0
- package/dist/index.js +61 -61
- 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 +0 -0
- package/dist/viewer/index.mjs.gz +0 -0
- package/package.json +1 -1
- package/dist/AiChatPanel-AQDB2BLO.mjs.br +0 -0
- package/dist/AiChatPanel-AQDB2BLO.mjs.gz +0 -0
- package/dist/AiChatPanel-VXQUQNZ6.js.br +0 -0
- package/dist/AiChatPanel-VXQUQNZ6.js.gz +0 -0
- package/dist/Model3DScene-I6OVMXEE.js.br +0 -0
- package/dist/Model3DScene-I6OVMXEE.js.gz +0 -0
- package/dist/Model3DScene-UHHKYZSK.mjs.br +0 -0
- package/dist/Model3DScene-UHHKYZSK.mjs.gz +0 -0
- package/dist/chunk-57RBEPPQ.js.br +0 -0
- package/dist/chunk-57RBEPPQ.js.gz +0 -0
- package/dist/chunk-5DQNWKOF.mjs.br +0 -0
- package/dist/chunk-5DQNWKOF.mjs.gz +0 -0
- package/dist/chunk-5YW6N5KJ.js.br +0 -0
- package/dist/chunk-5YW6N5KJ.js.gz +0 -0
- package/dist/chunk-C5ZJGQ2F.mjs.br +0 -0
- package/dist/chunk-C5ZJGQ2F.mjs.gz +0 -0
- package/dist/chunk-HJBTQ234.mjs.br +0 -0
- package/dist/chunk-HJBTQ234.mjs.gz +0 -0
- package/dist/chunk-JUUI5DHB.mjs.br +0 -0
- package/dist/chunk-JUUI5DHB.mjs.gz +0 -0
- package/dist/chunk-KA24ZRTJ.js.br +0 -0
- package/dist/chunk-KA24ZRTJ.js.gz +0 -0
- package/dist/chunk-MXH7RMTF.js.br +0 -0
- package/dist/chunk-MXH7RMTF.js.gz +0 -0
- package/dist/chunk-SLMDLVFV.mjs.br +0 -0
- package/dist/chunk-SLMDLVFV.mjs.gz +0 -0
- package/dist/chunk-UOS5HJLG.js.br +0 -0
- package/dist/chunk-UOS5HJLG.js.gz +0 -0
|
@@ -28716,7 +28716,7 @@ var ENTRY_TYPE_ROOT;
|
|
|
28716
28716
|
var DIR_ENTRY_SIZE;
|
|
28717
28717
|
var Ole2ParseError;
|
|
28718
28718
|
var init_ole2_parser_types = __esm({
|
|
28719
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
28719
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole2-parser-types.js"() {
|
|
28720
28720
|
OLE_MAGIC = new Uint8Array([208, 207, 17, 224, 161, 177, 26, 225]);
|
|
28721
28721
|
ENDOFCHAIN = 4294967294;
|
|
28722
28722
|
FREESECT = 4294967295;
|
|
@@ -28912,7 +28912,7 @@ function parseOle2(buffer) {
|
|
|
28912
28912
|
return { entries: entries2, getStream };
|
|
28913
28913
|
}
|
|
28914
28914
|
var init_ole2_parser_read = __esm({
|
|
28915
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
28915
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole2-parser-read.js"() {
|
|
28916
28916
|
init_ole2_parser_types();
|
|
28917
28917
|
}
|
|
28918
28918
|
});
|
|
@@ -29091,7 +29091,7 @@ function writeInt32Sectors(outBytes, int32Data, firstSector, numSectors, sectorS
|
|
|
29091
29091
|
}
|
|
29092
29092
|
}
|
|
29093
29093
|
var init_ole2_parser_write_helpers = __esm({
|
|
29094
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
29094
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole2-parser-write-helpers.js"() {
|
|
29095
29095
|
init_ole2_parser_types();
|
|
29096
29096
|
}
|
|
29097
29097
|
});
|
|
@@ -29186,7 +29186,7 @@ function writeStreamSectors(outBytes, streamData, chain2, sectorSize) {
|
|
|
29186
29186
|
}
|
|
29187
29187
|
var HEADER_DIFAT_ENTRIES;
|
|
29188
29188
|
var init_ole2_parser_write_serialize = __esm({
|
|
29189
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
29189
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole2-parser-write-serialize.js"() {
|
|
29190
29190
|
init_ole2_parser_types();
|
|
29191
29191
|
init_ole2_parser_write_helpers();
|
|
29192
29192
|
HEADER_DIFAT_ENTRIES = 109;
|
|
@@ -29357,7 +29357,7 @@ function buildOle2(streams, rootClsid, miniStreamCutoff = 4096) {
|
|
|
29357
29357
|
return output;
|
|
29358
29358
|
}
|
|
29359
29359
|
var init_ole2_parser_write = __esm({
|
|
29360
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
29360
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole2-parser-write.js"() {
|
|
29361
29361
|
init_ole2_parser_types();
|
|
29362
29362
|
init_ole2_parser_write_helpers();
|
|
29363
29363
|
init_ole2_parser_write_serialize();
|
|
@@ -30321,7 +30321,7 @@ var MAX;
|
|
|
30321
30321
|
var NIL;
|
|
30322
30322
|
var SIZE;
|
|
30323
30323
|
var init_ole2_stream_edit = __esm({
|
|
30324
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
30324
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole2-stream-edit.js"() {
|
|
30325
30325
|
END = 4294967294;
|
|
30326
30326
|
MAX = 4294967290;
|
|
30327
30327
|
NIL = 4294967295;
|
|
@@ -30394,7 +30394,7 @@ function isCfb(bytes) {
|
|
|
30394
30394
|
}
|
|
30395
30395
|
var WORKBOOK_STREAM_NAMES;
|
|
30396
30396
|
var init_legacy_excel_cfb = __esm({
|
|
30397
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
30397
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/legacy-excel-cfb.js"() {
|
|
30398
30398
|
init_ole2_parser_read();
|
|
30399
30399
|
init_ole2_parser_types();
|
|
30400
30400
|
init_ole2_parser_write();
|
|
@@ -30621,7 +30621,7 @@ var WORKSHEET_DT;
|
|
|
30621
30621
|
var DEFAULT_MAX_ROWS2;
|
|
30622
30622
|
var DEFAULT_MAX_COLS2;
|
|
30623
30623
|
var init_legacy_excel_biff8 = __esm({
|
|
30624
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
30624
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/legacy-excel-biff8.js"() {
|
|
30625
30625
|
init_legacy_excel_cfb();
|
|
30626
30626
|
OPCODE_BOF = 2057;
|
|
30627
30627
|
OPCODE_EOF = 10;
|
|
@@ -30767,7 +30767,7 @@ function buildXlsRowCellRegion(grid) {
|
|
|
30767
30767
|
return Uint8Array.from(bytesOut);
|
|
30768
30768
|
}
|
|
30769
30769
|
var init_legacy_excel_biff8_grid = __esm({
|
|
30770
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
30770
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/legacy-excel-biff8-grid.js"() {
|
|
30771
30771
|
init_legacy_excel_biff8();
|
|
30772
30772
|
}
|
|
30773
30773
|
});
|
|
@@ -30888,7 +30888,7 @@ function writeOleXlsStringCellEdit(inputBytes, edit) {
|
|
|
30888
30888
|
}
|
|
30889
30889
|
}
|
|
30890
30890
|
var init_legacy_excel_biff8_writer = __esm({
|
|
30891
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
30891
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/legacy-excel-biff8-writer.js"() {
|
|
30892
30892
|
init_legacy_excel_biff8();
|
|
30893
30893
|
init_legacy_excel_biff8_grid();
|
|
30894
30894
|
init_legacy_excel_cfb();
|
|
@@ -31054,7 +31054,7 @@ function patchDocFib(wordDoc, fib, patch) {
|
|
|
31054
31054
|
var FC_LCB_INDEX;
|
|
31055
31055
|
var F_COMPLEX_BIT;
|
|
31056
31056
|
var init_ole_document_doc_fib = __esm({
|
|
31057
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
31057
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole-document-doc-fib.js"() {
|
|
31058
31058
|
FC_LCB_INDEX = {
|
|
31059
31059
|
plcfbteChpx: 12,
|
|
31060
31060
|
plcfbtePapx: 13,
|
|
@@ -31104,7 +31104,7 @@ function unwrapDocBytes(bytes) {
|
|
|
31104
31104
|
}
|
|
31105
31105
|
}
|
|
31106
31106
|
var init_ole_document_doc_cfb = __esm({
|
|
31107
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
31107
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole-document-doc-cfb.js"() {
|
|
31108
31108
|
init_ole_document_doc_fib();
|
|
31109
31109
|
init_ole2_parser_read();
|
|
31110
31110
|
init_ole2_parser_types();
|
|
@@ -31218,7 +31218,7 @@ function buildSingleRunChpxPage(fcStart, fcEnd, blob) {
|
|
|
31218
31218
|
}
|
|
31219
31219
|
var PAGE_SIZE;
|
|
31220
31220
|
var init_ole_document_doc_fkp = __esm({
|
|
31221
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
31221
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole-document-doc-fkp.js"() {
|
|
31222
31222
|
PAGE_SIZE = 512;
|
|
31223
31223
|
}
|
|
31224
31224
|
});
|
|
@@ -31256,7 +31256,7 @@ function encodeCp1252(text22) {
|
|
|
31256
31256
|
var CP1252_HIGH_BLOCK;
|
|
31257
31257
|
var CP1252_HIGH_BLOCK_REVERSE;
|
|
31258
31258
|
var init_ole_document_doc_cp1252 = __esm({
|
|
31259
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
31259
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole-document-doc-cp1252.js"() {
|
|
31260
31260
|
CP1252_HIGH_BLOCK = [
|
|
31261
31261
|
8364,
|
|
31262
31262
|
129,
|
|
@@ -31455,7 +31455,7 @@ function buildClxBytes(pieces) {
|
|
|
31455
31455
|
var CLXT_PRC;
|
|
31456
31456
|
var CLXT_PCDT;
|
|
31457
31457
|
var init_ole_document_doc_pieces = __esm({
|
|
31458
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
31458
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole-document-doc-pieces.js"() {
|
|
31459
31459
|
init_ole_document_doc_cp1252();
|
|
31460
31460
|
CLXT_PRC = 1;
|
|
31461
31461
|
CLXT_PCDT = 2;
|
|
@@ -31615,7 +31615,7 @@ function writeOleDocParagraphEdit(docBytes, paragraphIndex, text22) {
|
|
|
31615
31615
|
var RISKY_PLCF_INDICES;
|
|
31616
31616
|
var RISKY_STTB_INDICES;
|
|
31617
31617
|
var init_ole_document_doc_editor = __esm({
|
|
31618
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
31618
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ole-document-doc-editor.js"() {
|
|
31619
31619
|
init_ole_document_doc_cfb();
|
|
31620
31620
|
init_ole_document_doc_fib();
|
|
31621
31621
|
init_ole_document_doc_fkp();
|
|
@@ -31806,7 +31806,7 @@ function encodePng(width, height, rgba) {
|
|
|
31806
31806
|
var CRC_TABLE;
|
|
31807
31807
|
var PNG_SIGNATURE;
|
|
31808
31808
|
var init_png_encoder = __esm({
|
|
31809
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
31809
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/utils/png-encoder.js"() {
|
|
31810
31810
|
CRC_TABLE = (() => {
|
|
31811
31811
|
const table2 = new Uint32Array(256);
|
|
31812
31812
|
for (let n = 0; n < 256; n++) {
|
|
@@ -50714,7 +50714,7 @@ async function hmac(algorithm, key2, data) {
|
|
|
50714
50714
|
return new Uint8Array(result);
|
|
50715
50715
|
}
|
|
50716
50716
|
var init_ooxml_crypto_primitives = __esm({
|
|
50717
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
50717
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/utils/ooxml-crypto-primitives.js"() {
|
|
50718
50718
|
}
|
|
50719
50719
|
});
|
|
50720
50720
|
var init_ooxml_crypto_primitives2 = __esm({
|
|
@@ -51829,7 +51829,7 @@ function mdStyleDigest(message, initialState, transform6) {
|
|
|
51829
51829
|
return out;
|
|
51830
51830
|
}
|
|
51831
51831
|
var init_bit_ops = __esm({
|
|
51832
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
51832
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/utils/digests/bit-ops.js"() {
|
|
51833
51833
|
}
|
|
51834
51834
|
});
|
|
51835
51835
|
function f1(x, y, z) {
|
|
@@ -51860,7 +51860,7 @@ var ROUND1;
|
|
|
51860
51860
|
var ROUND2;
|
|
51861
51861
|
var ROUND3;
|
|
51862
51862
|
var init_md4 = __esm({
|
|
51863
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
51863
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/utils/digests/md4.js"() {
|
|
51864
51864
|
init_bit_ops();
|
|
51865
51865
|
INITIAL_STATE = [1732584193, 4023233417, 2562383102, 271733878];
|
|
51866
51866
|
K2 = 1518500249;
|
|
@@ -109771,7 +109771,7 @@ function record(recType, data, recInstance = 0, isContainer2 = false, recVer = 0
|
|
|
109771
109771
|
}
|
|
109772
109772
|
var ByteWriter;
|
|
109773
109773
|
var init_byte_writer = __esm({
|
|
109774
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
109774
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/byte-writer.js"() {
|
|
109775
109775
|
ByteWriter = class {
|
|
109776
109776
|
chunks = [];
|
|
109777
109777
|
length = 0;
|
|
@@ -109863,7 +109863,7 @@ var HEADER_TOKEN_PLAIN;
|
|
|
109863
109863
|
var HEADER_TOKEN_ENCRYPTED;
|
|
109864
109864
|
var EMU_PER_MASTER;
|
|
109865
109865
|
var init_legacy_ppt_record_types = __esm({
|
|
109866
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
109866
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/legacy-ppt-record-types.js"() {
|
|
109867
109867
|
RT = {
|
|
109868
109868
|
Document: 1e3,
|
|
109869
109869
|
DocumentAtom: 1001,
|
|
@@ -109992,7 +109992,7 @@ var init_legacy_ppt_record_types = __esm({
|
|
|
109992
109992
|
}
|
|
109993
109993
|
});
|
|
109994
109994
|
var init_record_types = __esm({
|
|
109995
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
109995
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/record-types.js"() {
|
|
109996
109996
|
init_legacy_ppt_record_types();
|
|
109997
109997
|
}
|
|
109998
109998
|
});
|
|
@@ -110010,7 +110010,7 @@ function buildCurrentUserStream(offsetToCurrentEdit, encrypted) {
|
|
|
110010
110010
|
var USER_NAME;
|
|
110011
110011
|
var CURRENT_USER_STREAM_SIZE;
|
|
110012
110012
|
var init_current_user_writer = __esm({
|
|
110013
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110013
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/current-user-writer.js"() {
|
|
110014
110014
|
init_record_types();
|
|
110015
110015
|
init_byte_writer();
|
|
110016
110016
|
USER_NAME = "pptx-viewer";
|
|
@@ -110040,7 +110040,7 @@ function buildFbse(picture, uid, foDelay, size) {
|
|
|
110040
110040
|
var MSOBLIP_PICT;
|
|
110041
110041
|
var BLIP_INFO;
|
|
110042
110042
|
var init_blip_writer = __esm({
|
|
110043
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110043
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/blip-writer.js"() {
|
|
110044
110044
|
init_md4();
|
|
110045
110045
|
init_png_encoder();
|
|
110046
110046
|
init_record_types();
|
|
@@ -110092,7 +110092,7 @@ var OPT;
|
|
|
110092
110092
|
var FBID_FLAG;
|
|
110093
110093
|
var METRO_BLOB_OPID;
|
|
110094
110094
|
var init_fopt_writer = __esm({
|
|
110095
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110095
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/fopt-writer.js"() {
|
|
110096
110096
|
init_record_types();
|
|
110097
110097
|
init_byte_writer();
|
|
110098
110098
|
OPT = {
|
|
@@ -110176,7 +110176,7 @@ function buildPictureStore(pictures, shapesPerDrawing) {
|
|
|
110176
110176
|
}
|
|
110177
110177
|
var SHAPE_ID_CLUSTER_SIZE;
|
|
110178
110178
|
var init_bstore_writer = __esm({
|
|
110179
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110179
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/bstore-writer.js"() {
|
|
110180
110180
|
init_record_types();
|
|
110181
110181
|
init_blip_writer();
|
|
110182
110182
|
init_byte_writer();
|
|
@@ -110211,7 +110211,7 @@ function buildEnvironment(fonts, otherTextStyle) {
|
|
|
110211
110211
|
}
|
|
110212
110212
|
var LF_FACE_NAME_BYTES;
|
|
110213
110213
|
var init_font_collection_writer = __esm({
|
|
110214
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110214
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/font-collection-writer.js"() {
|
|
110215
110215
|
init_record_types();
|
|
110216
110216
|
init_byte_writer();
|
|
110217
110217
|
LF_FACE_NAME_BYTES = 64;
|
|
@@ -110262,7 +110262,8 @@ function buildDocumentContainer(input) {
|
|
|
110262
110262
|
if (input.soundCollection) {
|
|
110263
110263
|
w.bytes(input.soundCollection);
|
|
110264
110264
|
}
|
|
110265
|
-
|
|
110265
|
+
const masterAtoms = input.masterPersistAtoms ?? (input.masterPersistAtom ? [input.masterPersistAtom] : []);
|
|
110266
|
+
w.bytes(drawingGroup).bytes(buildSlideListWithText(masterAtoms, 1));
|
|
110266
110267
|
if (input.paddingBytes) {
|
|
110267
110268
|
w.bytes(buildPaddingTag(input.paddingBytes));
|
|
110268
110269
|
}
|
|
@@ -110273,7 +110274,7 @@ var MASTER_SLIDE_ID_SENTINEL;
|
|
|
110273
110274
|
var RT_CSTRING;
|
|
110274
110275
|
var RT_BINARY_TAG_DATA_BLOB;
|
|
110275
110276
|
var init_document_writer = __esm({
|
|
110276
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110277
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/document-writer.js"() {
|
|
110277
110278
|
init_record_types();
|
|
110278
110279
|
init_byte_writer();
|
|
110279
110280
|
init_font_collection_writer();
|
|
@@ -110421,7 +110422,7 @@ var LT;
|
|
|
110421
110422
|
var FLAG_CUSTOM_SHOW_RETURN;
|
|
110422
110423
|
var HyperlinkCollector;
|
|
110423
110424
|
var init_hyperlink_writer = __esm({
|
|
110424
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110425
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/hyperlink-writer.js"() {
|
|
110425
110426
|
init_record_types();
|
|
110426
110427
|
init_byte_writer();
|
|
110427
110428
|
II_ACTION = {
|
|
@@ -110520,7 +110521,7 @@ var MediaCollector;
|
|
|
110520
110521
|
var SOUND_EXTENSION_WAV;
|
|
110521
110522
|
var SOUND_LENGTH_UNKNOWN;
|
|
110522
110523
|
var init_media_writer = __esm({
|
|
110523
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110524
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/media-writer.js"() {
|
|
110524
110525
|
init_record_types();
|
|
110525
110526
|
init_byte_writer();
|
|
110526
110527
|
MediaCollector = class {
|
|
@@ -110622,7 +110623,7 @@ var EX_OLE_SUB_DEFAULT;
|
|
|
110622
110623
|
var PACKAGER_MENU_NAME;
|
|
110623
110624
|
var OleCollector;
|
|
110624
110625
|
var init_ole_writer = __esm({
|
|
110625
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110626
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/ole-writer.js"() {
|
|
110626
110627
|
init_ole2_parser_write();
|
|
110627
110628
|
init_record_types();
|
|
110628
110629
|
init_byte_writer();
|
|
@@ -110707,7 +110708,7 @@ function buildExObjList(hyperlinks, ole, media) {
|
|
|
110707
110708
|
return record(RT.ExternalObjectList, w.toBytes(), 0, true);
|
|
110708
110709
|
}
|
|
110709
110710
|
var init_ex_obj_list_writer = __esm({
|
|
110710
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110711
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/ex-obj-list-writer.js"() {
|
|
110711
110712
|
init_record_types();
|
|
110712
110713
|
init_byte_writer();
|
|
110713
110714
|
init_hyperlink_writer();
|
|
@@ -110760,7 +110761,7 @@ function buildChildAnchor(rect22) {
|
|
|
110760
110761
|
var INT16_MIN2;
|
|
110761
110762
|
var INT16_MAX2;
|
|
110762
110763
|
var init_anchor_writer = __esm({
|
|
110763
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110764
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/anchor-writer.js"() {
|
|
110764
110765
|
init_record_types();
|
|
110765
110766
|
init_byte_writer();
|
|
110766
110767
|
INT16_MIN2 = -32768;
|
|
@@ -110788,7 +110789,7 @@ function encodeColorIndex(rgb2) {
|
|
|
110788
110789
|
}
|
|
110789
110790
|
var DEFAULT_RGB;
|
|
110790
110791
|
var init_colors = __esm({
|
|
110791
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110792
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/colors.js"() {
|
|
110792
110793
|
DEFAULT_RGB = "000000";
|
|
110793
110794
|
}
|
|
110794
110795
|
});
|
|
@@ -110882,7 +110883,7 @@ function writeCfException(w, run, fontIndex) {
|
|
|
110882
110883
|
var ALIGN_CODE;
|
|
110883
110884
|
var EMU_PER_MASTER_UNIT;
|
|
110884
110885
|
var init_text_exception_writer = __esm({
|
|
110885
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110886
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/text-exception-writer.js"() {
|
|
110886
110887
|
init_colors();
|
|
110887
110888
|
ALIGN_CODE = {
|
|
110888
110889
|
l: 0,
|
|
@@ -110953,7 +110954,7 @@ function buildTextAtoms(body, fonts, hyperlinks) {
|
|
|
110953
110954
|
return new ByteWriter().bytes(buildTextHeaderAtom(body.textType)).bytes(buildTextCharsAtom(text22)).bytes(buildStyleTextPropAtom(body, fontIndex)).bytes(buildRunHyperlinks(body, hyperlinks)).toBytes();
|
|
110954
110955
|
}
|
|
110955
110956
|
var init_text_atom_writer = __esm({
|
|
110956
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
110957
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/text-atom-writer.js"() {
|
|
110957
110958
|
init_record_types();
|
|
110958
110959
|
init_byte_writer();
|
|
110959
110960
|
init_hyperlink_writer();
|
|
@@ -111065,7 +111066,7 @@ var TITLE_PROMPT;
|
|
|
111065
111066
|
var BODY_PROMPT;
|
|
111066
111067
|
var DEFAULT_FRAMES;
|
|
111067
111068
|
var init_master_placeholders_writer = __esm({
|
|
111068
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111069
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/master-placeholders-writer.js"() {
|
|
111069
111070
|
init_record_types();
|
|
111070
111071
|
init_anchor_writer();
|
|
111071
111072
|
init_byte_writer();
|
|
@@ -111137,7 +111138,7 @@ function masterStyleFonts(styles) {
|
|
|
111137
111138
|
return [styles.title, styles.body, styles.other].flatMap((levels) => levels ?? []).map((level2) => level2.run.fontName).filter((name) => Boolean(name));
|
|
111138
111139
|
}
|
|
111139
111140
|
var init_master_style_fonts = __esm({
|
|
111140
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111141
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/master-style-fonts.js"() {
|
|
111141
111142
|
}
|
|
111142
111143
|
});
|
|
111143
111144
|
function buildMasterStyleAtom(recInstance, levels, fontIndex) {
|
|
@@ -111171,7 +111172,7 @@ function buildMasterTextStyles(styles, fontIndex) {
|
|
|
111171
111172
|
var EMPTY_LEVELS;
|
|
111172
111173
|
var FIXED_INSTANCE_DATA;
|
|
111173
111174
|
var init_master_text_styles_writer = __esm({
|
|
111174
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111175
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/master-text-styles-writer.js"() {
|
|
111175
111176
|
init_record_types();
|
|
111176
111177
|
init_byte_writer();
|
|
111177
111178
|
init_text_exception_writer();
|
|
@@ -111240,7 +111241,7 @@ function buildShapeFoptProps(input) {
|
|
|
111240
111241
|
}
|
|
111241
111242
|
var DASH_CODE;
|
|
111242
111243
|
var init_shape_props_writer = __esm({
|
|
111243
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111244
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/shape-props-writer.js"() {
|
|
111244
111245
|
init_colors();
|
|
111245
111246
|
init_fopt_writer();
|
|
111246
111247
|
DASH_CODE = {
|
|
@@ -111359,7 +111360,7 @@ var FSP_FLAG_OLE_SHAPE;
|
|
|
111359
111360
|
var FSP_FLAG_CHILD;
|
|
111360
111361
|
var PLACEHOLDER_ID;
|
|
111361
111362
|
var init_shape_writer = __esm({
|
|
111362
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111363
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/shape-writer.js"() {
|
|
111363
111364
|
init_record_types();
|
|
111364
111365
|
init_anchor_writer();
|
|
111365
111366
|
init_byte_writer();
|
|
@@ -111423,7 +111424,7 @@ var FSP_FLAG_PATRIARCH;
|
|
|
111423
111424
|
var FSP_FLAG_HAVE_ANCHOR;
|
|
111424
111425
|
var ZERO_RECT;
|
|
111425
111426
|
var init_group_writer = __esm({
|
|
111426
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111427
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/group-writer.js"() {
|
|
111427
111428
|
init_record_types();
|
|
111428
111429
|
init_anchor_writer();
|
|
111429
111430
|
init_byte_writer();
|
|
@@ -111436,7 +111437,7 @@ var init_group_writer = __esm({
|
|
|
111436
111437
|
});
|
|
111437
111438
|
var ShapeIdAllocator2;
|
|
111438
111439
|
var init_shape_id_allocator = __esm({
|
|
111439
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111440
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/shape-id-allocator.js"() {
|
|
111440
111441
|
ShapeIdAllocator2 = class {
|
|
111441
111442
|
current;
|
|
111442
111443
|
constructor(drawingId, clusterSize) {
|
|
@@ -111493,7 +111494,7 @@ var FSP_FLAG_BACKGROUND;
|
|
|
111493
111494
|
var BACKGROUND_RECT_SPT;
|
|
111494
111495
|
var SHAPE_ID_CLUSTER_SIZE2;
|
|
111495
111496
|
var init_drawing_writer = __esm({
|
|
111496
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111497
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/drawing-writer.js"() {
|
|
111497
111498
|
init_record_types();
|
|
111498
111499
|
init_byte_writer();
|
|
111499
111500
|
init_colors();
|
|
@@ -111522,7 +111523,7 @@ function buildNotesContainer(paragraphs2, notesRect, slidePersistIdRef, fonts, d
|
|
|
111522
111523
|
return record(RT.Notes, data, 0, true);
|
|
111523
111524
|
}
|
|
111524
111525
|
var init_notes_writer = __esm({
|
|
111525
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111526
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/notes-writer.js"() {
|
|
111526
111527
|
init_record_types();
|
|
111527
111528
|
init_byte_writer();
|
|
111528
111529
|
init_drawing_writer();
|
|
@@ -111602,7 +111603,7 @@ function recordBytes(data, rec) {
|
|
|
111602
111603
|
var PptParseError;
|
|
111603
111604
|
var RECORD_HEADER_SIZE;
|
|
111604
111605
|
var init_legacy_ppt_record_stream = __esm({
|
|
111605
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111606
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/legacy-ppt-record-stream.js"() {
|
|
111606
111607
|
PptParseError = class extends Error {
|
|
111607
111608
|
constructor(message) {
|
|
111608
111609
|
super(message);
|
|
@@ -111613,7 +111614,7 @@ var init_legacy_ppt_record_stream = __esm({
|
|
|
111613
111614
|
}
|
|
111614
111615
|
});
|
|
111615
111616
|
var init_record_stream = __esm({
|
|
111616
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111617
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/record-stream.js"() {
|
|
111617
111618
|
init_legacy_ppt_record_stream();
|
|
111618
111619
|
}
|
|
111619
111620
|
});
|
|
@@ -111668,7 +111669,7 @@ function resolveEscherColor(colorRef, scheme) {
|
|
|
111668
111669
|
var SCHEME;
|
|
111669
111670
|
var DEFAULT_SCHEME;
|
|
111670
111671
|
var init_color_scheme = __esm({
|
|
111671
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111672
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/color-scheme.js"() {
|
|
111672
111673
|
init_record_stream();
|
|
111673
111674
|
init_record_types();
|
|
111674
111675
|
SCHEME = {
|
|
@@ -111701,7 +111702,7 @@ function buildColorSchemeAtom(recInstance = 1, colors) {
|
|
|
111701
111702
|
return record(RT.ColorSchemeAtom, w.toBytes(), recInstance, false, 0);
|
|
111702
111703
|
}
|
|
111703
111704
|
var init_color_scheme_writer = __esm({
|
|
111704
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111705
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/color-scheme-writer.js"() {
|
|
111705
111706
|
init_color_scheme();
|
|
111706
111707
|
init_record_types();
|
|
111707
111708
|
init_byte_writer();
|
|
@@ -111722,8 +111723,14 @@ function buildSlideAtom(masterIdRef, notesIdRef, hasOwnBackground) {
|
|
|
111722
111723
|
function buildMasterSlideAtom() {
|
|
111723
111724
|
return buildSlideAtomRaw(0, 0, 0, SLIDE_FLAG_MASTER_SCHEME);
|
|
111724
111725
|
}
|
|
111725
|
-
function buildSlideContainer(slide, slideRect,
|
|
111726
|
-
const data = new ByteWriter().bytes(buildSlideAtom(
|
|
111726
|
+
function buildSlideContainer(slide, slideRect, masterIdRef, notesIdRef, fonts, drawingId, hyperlinks, oleEmbeds, mediaEmbeds) {
|
|
111727
|
+
const data = new ByteWriter().bytes(buildSlideAtom(
|
|
111728
|
+
// A master is named by its slide id (>= 0x80000000), never by a
|
|
111729
|
+
// persist id; anything smaller falls back to the first master.
|
|
111730
|
+
masterIdRef >= SLIDE_MASTER_ID_SENTINEL ? masterIdRef : SLIDE_MASTER_ID_SENTINEL,
|
|
111731
|
+
notesIdRef,
|
|
111732
|
+
Boolean(slide.backgroundRgb)
|
|
111733
|
+
)).bytes(buildDrawing(slideRect, slide.shapes, slide.backgroundRgb, fonts, drawingId, hyperlinks, oleEmbeds, mediaEmbeds)).bytes(buildColorSchemeAtom()).toBytes();
|
|
111727
111734
|
return record(RT.Slide, data, 0, true);
|
|
111728
111735
|
}
|
|
111729
111736
|
function buildMainMasterContainer(slideRect, drawingId, hyperlinks, oleEmbeds, mediaEmbeds, masterStyles, fonts, master) {
|
|
@@ -111742,7 +111749,7 @@ var SLIDE_FLAG_MASTER_BACKGROUND;
|
|
|
111742
111749
|
var SLIDE_MASTER_ID_SENTINEL;
|
|
111743
111750
|
var MASTER_FIRST_COLOR_SCHEME_INSTANCE;
|
|
111744
111751
|
var init_slide_writer = __esm({
|
|
111745
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111752
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/slide-writer.js"() {
|
|
111746
111753
|
init_record_types();
|
|
111747
111754
|
init_byte_writer();
|
|
111748
111755
|
init_color_scheme_writer();
|
|
@@ -111756,6 +111763,15 @@ var init_slide_writer = __esm({
|
|
|
111756
111763
|
MASTER_FIRST_COLOR_SCHEME_INSTANCE = 6;
|
|
111757
111764
|
}
|
|
111758
111765
|
});
|
|
111766
|
+
function masterSlideId(index) {
|
|
111767
|
+
return MASTER_SLIDE_ID_SENTINEL + index;
|
|
111768
|
+
}
|
|
111769
|
+
function resolveDeckMasters(deck) {
|
|
111770
|
+
return deck.masters && deck.masters.length > 0 ? deck.masters : [{ styles: deck.masterStyles, roundTrip: deck.master }];
|
|
111771
|
+
}
|
|
111772
|
+
function slideMasterIndex(masterIndex, masterCount) {
|
|
111773
|
+
return masterIndex !== void 0 && Number.isInteger(masterIndex) && masterIndex >= 0 && masterIndex < masterCount ? masterIndex : 0;
|
|
111774
|
+
}
|
|
111759
111775
|
function countDrawingShapes(shapes) {
|
|
111760
111776
|
let count = 1;
|
|
111761
111777
|
const walk3 = (list2) => {
|
|
@@ -111769,7 +111785,7 @@ function countDrawingShapes(shapes) {
|
|
|
111769
111785
|
walk3(shapes);
|
|
111770
111786
|
return count;
|
|
111771
111787
|
}
|
|
111772
|
-
function collectFonts(deck) {
|
|
111788
|
+
function collectFonts(deck, masters) {
|
|
111773
111789
|
const collect2 = (shape) => {
|
|
111774
111790
|
if (shape.kind === "group") {
|
|
111775
111791
|
return shape.children.flatMap(collect2);
|
|
@@ -111779,40 +111795,43 @@ function collectFonts(deck) {
|
|
|
111779
111795
|
}
|
|
111780
111796
|
return shape.text.paragraphs.flatMap((p) => p.runs.map((r) => r.fontName).filter((n) => Boolean(n)));
|
|
111781
111797
|
};
|
|
111782
|
-
const themeMinor =
|
|
111798
|
+
const themeMinor = masters[0]?.roundTrip?.themeFonts?.minor;
|
|
111783
111799
|
const fonts = Array.from(/* @__PURE__ */ new Set([
|
|
111784
111800
|
...themeMinor ? [themeMinor] : [],
|
|
111785
111801
|
...deck.slides.flatMap((slide) => slide.shapes.flatMap(collect2)),
|
|
111786
|
-
...masterStyleFonts(
|
|
111802
|
+
...masters.flatMap((master) => masterStyleFonts(master.styles))
|
|
111787
111803
|
]));
|
|
111788
111804
|
return fonts.length > 0 ? fonts : ["Calibri"];
|
|
111789
111805
|
}
|
|
111790
111806
|
function layoutDocumentStream(deck) {
|
|
111791
111807
|
const slideRect = { w: deck.widthEmu, h: deck.heightEmu };
|
|
111792
111808
|
const notesRect = { x: 0, y: 0, w: deck.heightEmu, h: deck.widthEmu };
|
|
111793
|
-
const
|
|
111794
|
-
|
|
111809
|
+
const masters = resolveDeckMasters(deck);
|
|
111810
|
+
const masterIds = masters.map((_, i2) => MASTER_ID + i2);
|
|
111811
|
+
const firstSlideId = MASTER_ID + masters.length;
|
|
111812
|
+
const slideIds = deck.slides.map((_, i2) => firstSlideId + i2);
|
|
111813
|
+
let nextId2 = firstSlideId + deck.slides.length;
|
|
111795
111814
|
const notesIds = deck.slides.map((slide) => slide.notesParagraphs?.length ? nextId2++ : 0);
|
|
111796
|
-
const
|
|
111797
|
-
const slideDrawingIds = deck.slides.map((_, i2) =>
|
|
111798
|
-
let nextDrawingId =
|
|
111815
|
+
const masterDrawingIds = masters.map((_, i2) => 1 + i2);
|
|
111816
|
+
const slideDrawingIds = deck.slides.map((_, i2) => 1 + masters.length + i2);
|
|
111817
|
+
let nextDrawingId = 1 + masters.length + deck.slides.length;
|
|
111799
111818
|
const notesDrawingIds = deck.slides.map((slide) => slide.notesParagraphs?.length ? nextDrawingId++ : 0);
|
|
111800
111819
|
const shapesPerDrawing = [
|
|
111801
|
-
1 + MASTER_PLACEHOLDER_ORDER.length,
|
|
111802
|
-
//
|
|
111820
|
+
...masters.map(() => 1 + MASTER_PLACEHOLDER_ORDER.length),
|
|
111821
|
+
// patriarch + placeholders
|
|
111803
111822
|
...deck.slides.map((slide) => countDrawingShapes(slide.shapes)),
|
|
111804
111823
|
...deck.slides.filter((s) => s.notesParagraphs?.length).map(() => 2)
|
|
111805
111824
|
// patriarch + body placeholder
|
|
111806
111825
|
];
|
|
111807
|
-
const fonts = collectFonts(deck);
|
|
111826
|
+
const fonts = collectFonts(deck, masters);
|
|
111808
111827
|
const { dggContainer, picturesStream } = buildPictureStore(deck.pictures, shapesPerDrawing);
|
|
111809
111828
|
const hyperlinks = new HyperlinkCollector();
|
|
111810
111829
|
const oleEmbeds = new OleCollector(hyperlinks);
|
|
111811
111830
|
const mediaEmbeds = new MediaCollector(hyperlinks);
|
|
111812
|
-
const slideContainers = deck.slides.map((slide, i2) => buildSlideContainer(slide, slideRect,
|
|
111831
|
+
const slideContainers = deck.slides.map((slide, i2) => buildSlideContainer(slide, slideRect, masterSlideId(slideMasterIndex(slide.masterIndex, masters.length)), notesIds[i2], fonts, slideDrawingIds[i2], hyperlinks, oleEmbeds, mediaEmbeds));
|
|
111813
111832
|
const notesContainers = deck.slides.map((slide, i2) => notesIds[i2] ? buildNotesContainer(slide.notesParagraphs, notesRect, slideIds[i2], fonts, notesDrawingIds[i2], hyperlinks, oleEmbeds, mediaEmbeds) : void 0).filter((c) => c !== void 0);
|
|
111814
|
-
const
|
|
111815
|
-
const
|
|
111833
|
+
const masterContainers = masters.map((master, i2) => buildMainMasterContainer(slideRect, masterDrawingIds[i2], hyperlinks, oleEmbeds, mediaEmbeds, master.styles, fonts, master.roundTrip));
|
|
111834
|
+
const masterPersistAtoms = masterIds.map((id, i2) => buildSlidePersistAtom(id, masterSlideId(i2)));
|
|
111816
111835
|
const slidePersistAtoms = slideIds.map((id, i2) => buildSlidePersistAtom(id, 256 + i2, 4));
|
|
111817
111836
|
const oleStgIds = oleEmbeds.all.map(() => nextId2++);
|
|
111818
111837
|
oleEmbeds.all.forEach((entry5, i2) => {
|
|
@@ -111825,18 +111844,18 @@ function layoutDocumentStream(deck) {
|
|
|
111825
111844
|
widthEmu: deck.widthEmu,
|
|
111826
111845
|
heightEmu: deck.heightEmu,
|
|
111827
111846
|
fonts,
|
|
111828
|
-
|
|
111847
|
+
masterPersistAtoms,
|
|
111829
111848
|
slidePersistAtoms,
|
|
111830
111849
|
dggContainer,
|
|
111831
111850
|
exObjList,
|
|
111832
111851
|
soundCollection,
|
|
111833
|
-
otherTextStyle: buildOtherTextStyle(
|
|
111852
|
+
otherTextStyle: buildOtherTextStyle(masters[0]?.styles, (name) => {
|
|
111834
111853
|
const idx = name ? fonts.indexOf(name) : -1;
|
|
111835
111854
|
return idx >= 0 ? idx : void 0;
|
|
111836
111855
|
})
|
|
111837
111856
|
};
|
|
111838
111857
|
const maxPersistId = nextId2 - 1;
|
|
111839
|
-
const contentSizeWithoutPadding = buildDocumentContainer(documentInput).length +
|
|
111858
|
+
const contentSizeWithoutPadding = buildDocumentContainer(documentInput).length + masterContainers.reduce((sum, c) => sum + c.length, 0) + slideContainers.reduce((sum, c) => sum + c.length, 0) + notesContainers.reduce((sum, c) => sum + c.length, 0) + oleStgRecords.reduce((sum, c) => sum + c.length, 0);
|
|
111840
111859
|
const paddingBytes = ensureMinimumDocumentStreamSize(contentSizeWithoutPadding, maxPersistId);
|
|
111841
111860
|
const documentContainer = buildDocumentContainer({ ...documentInput, paddingBytes });
|
|
111842
111861
|
const layout = new ByteWriter();
|
|
@@ -111846,7 +111865,7 @@ function layoutDocumentStream(deck) {
|
|
|
111846
111865
|
layout.bytes(bytes);
|
|
111847
111866
|
};
|
|
111848
111867
|
place(DOC_ID, documentContainer);
|
|
111849
|
-
place(
|
|
111868
|
+
masterIds.forEach((id, i2) => place(id, masterContainers[i2]));
|
|
111850
111869
|
slideIds.forEach((id, i2) => place(id, slideContainers[i2]));
|
|
111851
111870
|
let notesCursor = 0;
|
|
111852
111871
|
notesIds.forEach((id) => {
|
|
@@ -111868,7 +111887,7 @@ function ensureMinimumDocumentStreamSize(contentSizeWithoutPadding, maxPersistId
|
|
|
111868
111887
|
var DOC_ID;
|
|
111869
111888
|
var MASTER_ID;
|
|
111870
111889
|
var init_document_stream_layout = __esm({
|
|
111871
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111890
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/document-stream-layout.js"() {
|
|
111872
111891
|
init_bstore_writer();
|
|
111873
111892
|
init_byte_writer();
|
|
111874
111893
|
init_document_writer();
|
|
@@ -111887,7 +111906,7 @@ var init_document_stream_layout = __esm({
|
|
|
111887
111906
|
});
|
|
111888
111907
|
var RC4_ALG_ID2;
|
|
111889
111908
|
var init_crypto_constants = __esm({
|
|
111890
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111909
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/crypto-constants.js"() {
|
|
111891
111910
|
RC4_ALG_ID2 = 26625;
|
|
111892
111911
|
}
|
|
111893
111912
|
});
|
|
@@ -111921,7 +111940,7 @@ function rc4Cipher(key2, data) {
|
|
|
111921
111940
|
return out;
|
|
111922
111941
|
}
|
|
111923
111942
|
var init_rc4_cipher = __esm({
|
|
111924
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111943
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/utils/rc4-cipher.js"() {
|
|
111925
111944
|
}
|
|
111926
111945
|
});
|
|
111927
111946
|
async function rc4CryptoApiKeyBase(password, salt) {
|
|
@@ -111964,7 +111983,7 @@ async function rc4CryptoApiEncryptVerifier(key0, verifier) {
|
|
|
111964
111983
|
}
|
|
111965
111984
|
var PADDED_40_BIT_KEY_BYTES;
|
|
111966
111985
|
var init_rc4_cryptoapi_key = __esm({
|
|
111967
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
111986
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/rc4-cryptoapi-key.js"() {
|
|
111968
111987
|
init_ooxml_crypto_primitives();
|
|
111969
111988
|
init_rc4_cipher();
|
|
111970
111989
|
PADDED_40_BIT_KEY_BYTES = 16;
|
|
@@ -112042,7 +112061,7 @@ var BITMAP_TAG_SIZE;
|
|
|
112042
112061
|
var METAFILE_BLIPS;
|
|
112043
112062
|
var BITMAP_BLIPS;
|
|
112044
112063
|
var init_rc4_cryptoapi_streams = __esm({
|
|
112045
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
112064
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/rc4-cryptoapi-streams.js"() {
|
|
112046
112065
|
init_rc4_cipher();
|
|
112047
112066
|
init_record_stream();
|
|
112048
112067
|
UID_SIZE = 16;
|
|
@@ -112084,7 +112103,7 @@ var VERIFIER_SIZE;
|
|
|
112084
112103
|
var VERIFIER_HASH_SIZE;
|
|
112085
112104
|
var ENCRYPTION_FLAGS;
|
|
112086
112105
|
var init_encrypt_writer = __esm({
|
|
112087
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
112106
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/encrypt-writer.js"() {
|
|
112088
112107
|
init_crypto_constants();
|
|
112089
112108
|
init_rc4_cryptoapi_key();
|
|
112090
112109
|
init_rc4_cryptoapi_streams();
|
|
@@ -112163,7 +112182,7 @@ function withMasterRelativeRunStyles(deck) {
|
|
|
112163
112182
|
}
|
|
112164
112183
|
var STYLE_KEYS;
|
|
112165
112184
|
var init_master_relative_runs = __esm({
|
|
112166
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
112185
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/master-relative-runs.js"() {
|
|
112167
112186
|
STYLE_KEYS = ["bold", "italic", "underline"];
|
|
112168
112187
|
}
|
|
112169
112188
|
});
|
|
@@ -112196,7 +112215,7 @@ function buildEncryptedUserEditAtom(input) {
|
|
|
112196
112215
|
}
|
|
112197
112216
|
var MAX_RUN;
|
|
112198
112217
|
var init_persist_writer = __esm({
|
|
112199
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
112218
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/persist-writer.js"() {
|
|
112200
112219
|
init_record_types();
|
|
112201
112220
|
init_byte_writer();
|
|
112202
112221
|
MAX_RUN = 4095;
|
|
@@ -112204,7 +112223,7 @@ var init_persist_writer = __esm({
|
|
|
112204
112223
|
});
|
|
112205
112224
|
var PPT_STORAGE_CLSID;
|
|
112206
112225
|
var init_ppt_clsid = __esm({
|
|
112207
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
112226
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/ppt-clsid.js"() {
|
|
112208
112227
|
PPT_STORAGE_CLSID = new Uint8Array([
|
|
112209
112228
|
16,
|
|
112210
112229
|
141,
|
|
@@ -112278,7 +112297,7 @@ async function buildPptFile(deck, options = {}) {
|
|
|
112278
112297
|
return new Uint8Array(buildOle2(streams, PPT_STORAGE_CLSID, 0));
|
|
112279
112298
|
}
|
|
112280
112299
|
var init_write_ppt = __esm({
|
|
112281
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
112300
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/writer/write-ppt.js"() {
|
|
112282
112301
|
init_ole2_parser_write();
|
|
112283
112302
|
init_byte_writer();
|
|
112284
112303
|
init_current_user_writer();
|
|
@@ -112290,7 +112309,7 @@ var init_write_ppt = __esm({
|
|
|
112290
112309
|
}
|
|
112291
112310
|
});
|
|
112292
112311
|
var init_legacy_ppt_writer = __esm({
|
|
112293
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
112312
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/legacy-ppt-writer.js"() {
|
|
112294
112313
|
init_write_ppt();
|
|
112295
112314
|
init_master_style_fonts();
|
|
112296
112315
|
}
|
|
@@ -112394,16 +112413,21 @@ async function followRel(zip, from, type) {
|
|
|
112394
112413
|
const rel = rels ? parseRels(rels).find((r) => r.type === `${REL}/${type}`) : void 0;
|
|
112395
112414
|
return rel && !rel.external ? resolveTarget2(from, rel.target) : void 0;
|
|
112396
112415
|
}
|
|
112397
|
-
async function
|
|
112416
|
+
async function readSlideMasterPaths(zip) {
|
|
112398
112417
|
const presentation = "ppt/presentation.xml";
|
|
112399
112418
|
const xml = await readText(zip, presentation);
|
|
112400
|
-
const firstSlideRid = xml ? /<p:sldId\b[^>]*\br:id="([^"]+)"/u.exec(xml)?.[1] : void 0;
|
|
112401
112419
|
const rels = await readText(zip, relsPath(presentation));
|
|
112402
|
-
const
|
|
112403
|
-
const
|
|
112404
|
-
const
|
|
112405
|
-
const
|
|
112406
|
-
|
|
112420
|
+
const presentationRels = rels ? parseRels(rels) : [];
|
|
112421
|
+
const slideRids = xml ? [...xml.matchAll(/<p:sldId\b[^>]*\br:id="([^"]+)"/gu)].map((m) => m[1]) : [];
|
|
112422
|
+
const paths = [];
|
|
112423
|
+
for (const rid of slideRids) {
|
|
112424
|
+
const slideRel = presentationRels.find((r) => r.id === rid);
|
|
112425
|
+
const slide = slideRel ? resolveTarget2(presentation, slideRel.target) : void 0;
|
|
112426
|
+
const layout = slide ? await followRel(zip, slide, "slideLayout") : void 0;
|
|
112427
|
+
const master = layout ? await followRel(zip, layout, "slideMaster") : void 0;
|
|
112428
|
+
paths.push(master && zip.file(master) ? master : FALLBACK_MASTER);
|
|
112429
|
+
}
|
|
112430
|
+
return paths;
|
|
112407
112431
|
}
|
|
112408
112432
|
function num3(xml, pattern) {
|
|
112409
112433
|
const value = pattern.exec(xml)?.[1];
|
|
@@ -112467,8 +112491,8 @@ function latinFace(themeXml3, scheme) {
|
|
|
112467
112491
|
const body = close < 0 ? void 0 : themeXml3.slice(open, close);
|
|
112468
112492
|
return body && /<a:latin [^>]*typeface="([^"]+)"/u.exec(body)?.[1] || void 0;
|
|
112469
112493
|
}
|
|
112470
|
-
async function readMasterRoundTripSource(zip) {
|
|
112471
|
-
|
|
112494
|
+
async function readMasterRoundTripSource(zip, masterPath) {
|
|
112495
|
+
masterPath ??= (await readSlideMasterPaths(zip))[0] ?? FALLBACK_MASTER;
|
|
112472
112496
|
const masterXml = await readText(zip, masterPath);
|
|
112473
112497
|
if (!masterXml) {
|
|
112474
112498
|
return { placeholders: [], themeFonts: {} };
|
|
@@ -112566,8 +112590,27 @@ async function buildMasterRoundTrip(source) {
|
|
|
112566
112590
|
colorMapping: source.clrMapAttributes ? buildColorMapping(source.clrMapAttributes) : void 0
|
|
112567
112591
|
};
|
|
112568
112592
|
}
|
|
112569
|
-
async function
|
|
112570
|
-
|
|
112593
|
+
async function buildDeckMasterRoundTripsFromPptx(pptxBytes) {
|
|
112594
|
+
const zip = await JSZip3.loadAsync(pptxBytes);
|
|
112595
|
+
const slidePaths = await readSlideMasterPaths(zip);
|
|
112596
|
+
const masterPaths = [...new Set(slidePaths)];
|
|
112597
|
+
if (masterPaths.length === 0) {
|
|
112598
|
+
return {
|
|
112599
|
+
masterPaths: [],
|
|
112600
|
+
masters: [await buildMasterRoundTrip(await readMasterRoundTripSource(zip))],
|
|
112601
|
+
slideMasterIndex: []
|
|
112602
|
+
};
|
|
112603
|
+
}
|
|
112604
|
+
const masters = await Promise.all(
|
|
112605
|
+
masterPaths.map(
|
|
112606
|
+
async (path) => buildMasterRoundTrip(await readMasterRoundTripSource(zip, path))
|
|
112607
|
+
)
|
|
112608
|
+
);
|
|
112609
|
+
return {
|
|
112610
|
+
masterPaths,
|
|
112611
|
+
masters,
|
|
112612
|
+
slideMasterIndex: slidePaths.map((path) => masterPaths.indexOf(path))
|
|
112613
|
+
};
|
|
112571
112614
|
}
|
|
112572
112615
|
var XML_DECL2;
|
|
112573
112616
|
var CT_NS2;
|
|
@@ -138033,19 +138076,18 @@ var init_PptxHandlerRuntimeSaveLegacyPpt = __esm({
|
|
|
138033
138076
|
return buildMetroBlobs(pptxBytes, slides);
|
|
138034
138077
|
}
|
|
138035
138078
|
/**
|
|
138036
|
-
* The
|
|
138037
|
-
*
|
|
138038
|
-
*
|
|
138039
|
-
* the styles parsed at load.
|
|
138079
|
+
* The text styles of the master at `masterPath` (the first slide's master
|
|
138080
|
+
* when omitted), preferring an edited copy passed in `options.slideMasters`
|
|
138081
|
+
* over the styles parsed at load.
|
|
138040
138082
|
*/
|
|
138041
|
-
legacyMasterTextStyles(slides, options) {
|
|
138083
|
+
legacyMasterTextStyles(slides, options, masterPath) {
|
|
138042
138084
|
const layoutPath = slides[0]?.layoutPath;
|
|
138043
|
-
const
|
|
138044
|
-
if (!
|
|
138085
|
+
const path = (masterPath && this.masterTxStylesCache.has(masterPath) ? masterPath : void 0) ?? (layoutPath ? this.resolveMasterPathForLayout(layoutPath) : void 0) ?? this.masterTxStylesCache.keys().next().value;
|
|
138086
|
+
if (!path) {
|
|
138045
138087
|
return void 0;
|
|
138046
138088
|
}
|
|
138047
|
-
const edited = options?.slideMasters?.find((master) => master.path ===
|
|
138048
|
-
return edited ?? this.masterTxStylesCache.get(
|
|
138089
|
+
const edited = options?.slideMasters?.find((master) => master.path === path)?.txStyles;
|
|
138090
|
+
return edited ?? this.masterTxStylesCache.get(path);
|
|
138049
138091
|
}
|
|
138050
138092
|
/**
|
|
138051
138093
|
* Serialise `slides` to a legacy binary PowerPoint 97-2003 (`.ppt`) file.
|
|
@@ -138062,7 +138104,7 @@ var init_PptxHandlerRuntimeSaveLegacyPpt = __esm({
|
|
|
138062
138104
|
async saveAsLegacyPpt(slides, options, saveAsPptx) {
|
|
138063
138105
|
const pptxBytes = saveAsPptx ? await saveAsPptx() : void 0;
|
|
138064
138106
|
const metroBlobs = await this.resolveMetroBlobs(slides, pptxBytes);
|
|
138065
|
-
const
|
|
138107
|
+
const deckMasters = pptxBytes ? await buildDeckMasterRoundTripsFromPptx(pptxBytes) : void 0;
|
|
138066
138108
|
this.compatibilityService.resetWarnings();
|
|
138067
138109
|
const resolvedMedia = await this.resolveAudioMediaBytes(slides);
|
|
138068
138110
|
const resolvedPictures = await resolvePictureSources(
|
|
@@ -138079,11 +138121,25 @@ var init_PptxHandlerRuntimeSaveLegacyPpt = __esm({
|
|
|
138079
138121
|
metroBlobs,
|
|
138080
138122
|
resolvedPictures
|
|
138081
138123
|
);
|
|
138082
|
-
|
|
138083
|
-
|
|
138084
|
-
|
|
138085
|
-
|
|
138086
|
-
|
|
138124
|
+
if (deckMasters && deckMasters.masterPaths.length > 1) {
|
|
138125
|
+
deck.masters = deckMasters.masters.map((roundTrip, i2) => ({
|
|
138126
|
+
roundTrip,
|
|
138127
|
+
styles: convertMasterTextStyles(
|
|
138128
|
+
this.legacyMasterTextStyles(slides, options, deckMasters.masterPaths[i2]),
|
|
138129
|
+
roundTrip.themeFonts
|
|
138130
|
+
)
|
|
138131
|
+
}));
|
|
138132
|
+
deck.slides.forEach((slide, i2) => {
|
|
138133
|
+
slide.masterIndex = deckMasters.slideMasterIndex[i2];
|
|
138134
|
+
});
|
|
138135
|
+
} else {
|
|
138136
|
+
const master = deckMasters?.masters[0];
|
|
138137
|
+
deck.masterStyles = convertMasterTextStyles(
|
|
138138
|
+
this.legacyMasterTextStyles(slides, options, deckMasters?.masterPaths[0]),
|
|
138139
|
+
master?.themeFonts
|
|
138140
|
+
);
|
|
138141
|
+
deck.master = master;
|
|
138142
|
+
}
|
|
138087
138143
|
return buildPptFile(deck, { password: options?.pptPassword });
|
|
138088
138144
|
}
|
|
138089
138145
|
};
|
|
@@ -151597,7 +151653,7 @@ function readPersistRecord(view, directory, persistId) {
|
|
|
151597
151653
|
return readRecordOrThrow(view, offset);
|
|
151598
151654
|
}
|
|
151599
151655
|
var init_persist_directory = __esm({
|
|
151600
|
-
"../../node_modules/.bun/@christophervr+ole2@0.
|
|
151656
|
+
"../../node_modules/.bun/@christophervr+ole2@0.3.0/node_modules/@christophervr/ole2/dist/ppt/persist-directory.js"() {
|
|
151601
151657
|
init_record_stream();
|
|
151602
151658
|
init_record_types();
|
|
151603
151659
|
}
|