@extend-ai/react-pptx 0.2.4 → 0.3.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 +19 -1
- package/README.md +20 -0
- package/THIRD_PARTY_LICENSES/apache-poi-LICENSE.txt +268 -0
- package/THIRD_PARTY_LICENSES/apache-poi-NOTICE.txt +36 -0
- package/THIRD_PARTY_LICENSES/apache-poi-SOURCE.md +13 -0
- package/THIRD_PARTY_NOTICES.md +15 -20
- package/dist/{dist-NDTOVNYD.js → dist-L6HJ7VKE.js} +268 -7
- package/dist/dist-L6HJ7VKE.js.map +1 -0
- package/dist/index.d.ts +495 -3
- package/dist/index.js +2499 -8568
- package/dist/index.js.map +1 -1
- package/dist/native-parser-worker.js +166 -6
- package/dist/native-parser-worker.js.map +1 -1
- package/dist/pptx_wasm_bg.wasm +0 -0
- package/package.json +6 -22
- package/THIRD_PARTY_LICENSES/ISC.txt +0 -15
- package/dist/chunk-YVOPQP3D.js +0 -50
- package/dist/chunk-YVOPQP3D.js.map +0 -1
- package/dist/dist-NDTOVNYD.js.map +0 -1
- package/dist/region-map-atlas-S2YXLDE2.js +0 -125
- package/dist/region-map-atlas-S2YXLDE2.js.map +0 -1
package/dist/index.d.ts
CHANGED
|
@@ -12,6 +12,229 @@ declare class PptxViewerError extends Error {
|
|
|
12
12
|
});
|
|
13
13
|
}
|
|
14
14
|
|
|
15
|
+
/** Finite quantity or indefinite; durations are milliseconds and percentages are fractions. */
|
|
16
|
+
type AnimationNumber = number | 'indefinite';
|
|
17
|
+
type AnimationValue = {
|
|
18
|
+
kind: 'string';
|
|
19
|
+
value: string;
|
|
20
|
+
} | {
|
|
21
|
+
kind: 'boolean';
|
|
22
|
+
value: boolean;
|
|
23
|
+
} | {
|
|
24
|
+
kind: 'integer' | 'number';
|
|
25
|
+
value: number;
|
|
26
|
+
} | {
|
|
27
|
+
kind: 'color';
|
|
28
|
+
value: ColorValue;
|
|
29
|
+
} | {
|
|
30
|
+
kind: 'point';
|
|
31
|
+
value: AnimationPoint;
|
|
32
|
+
} | {
|
|
33
|
+
kind: 'rgbDelta' | 'hslDelta';
|
|
34
|
+
value: [number, number, number];
|
|
35
|
+
};
|
|
36
|
+
interface SlideTransition {
|
|
37
|
+
effect?: TransitionEffect;
|
|
38
|
+
speed: string;
|
|
39
|
+
durationMs?: number;
|
|
40
|
+
advanceOnClick: boolean;
|
|
41
|
+
advanceAfterMs?: number;
|
|
42
|
+
sound?: TransitionSound;
|
|
43
|
+
sourceXml: string;
|
|
44
|
+
}
|
|
45
|
+
interface TransitionEffect {
|
|
46
|
+
kind: string;
|
|
47
|
+
namespace: string;
|
|
48
|
+
direction?: string;
|
|
49
|
+
orientation?: string;
|
|
50
|
+
throughBlack?: boolean;
|
|
51
|
+
spokes?: number;
|
|
52
|
+
parameters: Record<string, string>;
|
|
53
|
+
}
|
|
54
|
+
interface TransitionSound {
|
|
55
|
+
action: string;
|
|
56
|
+
loopSound: boolean;
|
|
57
|
+
source?: AnimationSound;
|
|
58
|
+
}
|
|
59
|
+
interface AnimationSound {
|
|
60
|
+
relationshipId?: string;
|
|
61
|
+
target?: string;
|
|
62
|
+
assetId?: string;
|
|
63
|
+
external: boolean;
|
|
64
|
+
name?: string;
|
|
65
|
+
builtin?: boolean;
|
|
66
|
+
}
|
|
67
|
+
interface SlideTiming {
|
|
68
|
+
nodes?: AnimationNode[];
|
|
69
|
+
builds?: AnimationBuild[];
|
|
70
|
+
unsupported?: string[];
|
|
71
|
+
sourceXml: string;
|
|
72
|
+
}
|
|
73
|
+
interface AnimationNode {
|
|
74
|
+
kind: string;
|
|
75
|
+
time?: AnimationTime;
|
|
76
|
+
behavior?: AnimationBehavior;
|
|
77
|
+
sequence?: AnimationSequence;
|
|
78
|
+
media?: AnimationMedia;
|
|
79
|
+
parameters: AnimationParameters;
|
|
80
|
+
}
|
|
81
|
+
interface AnimationTime {
|
|
82
|
+
id?: number;
|
|
83
|
+
presetId?: number;
|
|
84
|
+
presetClass?: string;
|
|
85
|
+
presetSubtype?: number;
|
|
86
|
+
durationMs?: AnimationNumber;
|
|
87
|
+
repeatCount: AnimationNumber;
|
|
88
|
+
repeatDurationMs?: AnimationNumber;
|
|
89
|
+
speed: number;
|
|
90
|
+
acceleration: number;
|
|
91
|
+
deceleration: number;
|
|
92
|
+
autoReverse: boolean;
|
|
93
|
+
restart?: string;
|
|
94
|
+
fill?: string;
|
|
95
|
+
syncBehavior?: string;
|
|
96
|
+
timeFilter?: string;
|
|
97
|
+
eventFilter?: string;
|
|
98
|
+
display?: boolean;
|
|
99
|
+
masterRelation?: string;
|
|
100
|
+
buildLevel?: number;
|
|
101
|
+
groupId?: number;
|
|
102
|
+
afterEffect?: boolean;
|
|
103
|
+
nodeType?: string;
|
|
104
|
+
placeholder?: boolean;
|
|
105
|
+
startConditions?: AnimationCondition[];
|
|
106
|
+
endConditions?: AnimationCondition[];
|
|
107
|
+
endSync?: AnimationCondition;
|
|
108
|
+
iterate?: AnimationIteration;
|
|
109
|
+
children?: AnimationNode[];
|
|
110
|
+
subNodes?: AnimationNode[];
|
|
111
|
+
}
|
|
112
|
+
interface AnimationCondition {
|
|
113
|
+
event?: string;
|
|
114
|
+
delayMs?: AnimationNumber;
|
|
115
|
+
target?: AnimationTarget;
|
|
116
|
+
timeNodeId?: number;
|
|
117
|
+
runtimeNode?: string;
|
|
118
|
+
}
|
|
119
|
+
interface AnimationIteration {
|
|
120
|
+
kind: string;
|
|
121
|
+
backwards: boolean;
|
|
122
|
+
intervalMs?: AnimationNumber;
|
|
123
|
+
intervalFraction?: number;
|
|
124
|
+
}
|
|
125
|
+
interface AnimationTarget {
|
|
126
|
+
kind: string;
|
|
127
|
+
/** Identifier scoped to the owning part, matching object source identity. */
|
|
128
|
+
shapeId?: string;
|
|
129
|
+
subShapeId?: string;
|
|
130
|
+
background?: boolean;
|
|
131
|
+
text?: AnimationTextRange;
|
|
132
|
+
chart?: AnimationChartTarget;
|
|
133
|
+
diagram?: AnimationDiagramTarget;
|
|
134
|
+
sound?: AnimationSound;
|
|
135
|
+
}
|
|
136
|
+
interface AnimationTextRange {
|
|
137
|
+
kind: string;
|
|
138
|
+
start?: number;
|
|
139
|
+
end?: number;
|
|
140
|
+
}
|
|
141
|
+
interface AnimationChartTarget {
|
|
142
|
+
kind: string;
|
|
143
|
+
level?: number;
|
|
144
|
+
seriesIndex?: number;
|
|
145
|
+
categoryIndex?: number;
|
|
146
|
+
}
|
|
147
|
+
interface AnimationDiagramTarget {
|
|
148
|
+
id?: string;
|
|
149
|
+
buildStep?: string;
|
|
150
|
+
}
|
|
151
|
+
interface AnimationBehavior {
|
|
152
|
+
target?: AnimationTarget;
|
|
153
|
+
attributeNames?: string[];
|
|
154
|
+
additive?: string;
|
|
155
|
+
accumulate?: string;
|
|
156
|
+
transformType?: string;
|
|
157
|
+
from?: string;
|
|
158
|
+
to?: string;
|
|
159
|
+
by?: string;
|
|
160
|
+
runtimeContext?: string;
|
|
161
|
+
overrideMode?: string;
|
|
162
|
+
}
|
|
163
|
+
interface AnimationSequence {
|
|
164
|
+
concurrent?: boolean;
|
|
165
|
+
previousAction?: string;
|
|
166
|
+
nextAction?: string;
|
|
167
|
+
previousConditions?: AnimationCondition[];
|
|
168
|
+
nextConditions?: AnimationCondition[];
|
|
169
|
+
}
|
|
170
|
+
interface AnimationMedia {
|
|
171
|
+
target?: AnimationTarget;
|
|
172
|
+
volume: number;
|
|
173
|
+
mute: boolean;
|
|
174
|
+
slideCount: number;
|
|
175
|
+
showWhenStopped: boolean;
|
|
176
|
+
narration?: boolean;
|
|
177
|
+
fullScreen?: boolean;
|
|
178
|
+
}
|
|
179
|
+
interface AnimationParameters {
|
|
180
|
+
from?: AnimationValue;
|
|
181
|
+
to?: AnimationValue;
|
|
182
|
+
by?: AnimationValue;
|
|
183
|
+
calculationMode?: string;
|
|
184
|
+
valueType?: string;
|
|
185
|
+
keyframes?: AnimationKeyframe[];
|
|
186
|
+
colorSpace?: string;
|
|
187
|
+
direction?: string;
|
|
188
|
+
transition?: string;
|
|
189
|
+
filter?: string;
|
|
190
|
+
properties?: string;
|
|
191
|
+
progress?: AnimationValue;
|
|
192
|
+
origin?: string;
|
|
193
|
+
path?: string;
|
|
194
|
+
pathEditMode?: string;
|
|
195
|
+
rotationCenter?: AnimationPoint;
|
|
196
|
+
rotationDegrees?: number;
|
|
197
|
+
pointTypes?: string;
|
|
198
|
+
zoomContents?: boolean;
|
|
199
|
+
commandType?: string;
|
|
200
|
+
command?: string;
|
|
201
|
+
}
|
|
202
|
+
interface AnimationPoint {
|
|
203
|
+
x: number;
|
|
204
|
+
y: number;
|
|
205
|
+
}
|
|
206
|
+
interface AnimationKeyframe {
|
|
207
|
+
time: AnimationNumber;
|
|
208
|
+
formula: string;
|
|
209
|
+
value?: AnimationValue;
|
|
210
|
+
}
|
|
211
|
+
interface AnimationBuild {
|
|
212
|
+
kind: string;
|
|
213
|
+
/** Identifier scoped to the owning part, matching object source identity. */
|
|
214
|
+
shapeId?: string;
|
|
215
|
+
groupId?: number;
|
|
216
|
+
uiExpand: boolean;
|
|
217
|
+
build?: string;
|
|
218
|
+
level?: number;
|
|
219
|
+
animateBackground?: boolean;
|
|
220
|
+
autoUpdateBackground?: boolean;
|
|
221
|
+
reverse?: boolean;
|
|
222
|
+
advanceAfterMs?: AnimationNumber;
|
|
223
|
+
asOne?: boolean;
|
|
224
|
+
graphicBuild?: AnimationGraphicBuild;
|
|
225
|
+
templates?: AnimationTemplate[];
|
|
226
|
+
}
|
|
227
|
+
interface AnimationGraphicBuild {
|
|
228
|
+
kind: string;
|
|
229
|
+
build?: string;
|
|
230
|
+
reverse?: boolean;
|
|
231
|
+
animateBackground?: boolean;
|
|
232
|
+
}
|
|
233
|
+
interface AnimationTemplate {
|
|
234
|
+
level: number;
|
|
235
|
+
nodes?: AnimationNode[];
|
|
236
|
+
}
|
|
237
|
+
|
|
15
238
|
type PresentationFormat = 'pptx' | 'ppt';
|
|
16
239
|
interface PresentationSize {
|
|
17
240
|
widthEmu: number;
|
|
@@ -108,8 +331,28 @@ interface LineStyle {
|
|
|
108
331
|
startArrow?: string;
|
|
109
332
|
endArrow?: string;
|
|
110
333
|
}
|
|
111
|
-
interface
|
|
334
|
+
interface MathElement {
|
|
335
|
+
name: string;
|
|
336
|
+
namespace?: string;
|
|
337
|
+
attributes?: {
|
|
338
|
+
name: string;
|
|
339
|
+
namespace?: string;
|
|
340
|
+
value: string;
|
|
341
|
+
}[];
|
|
342
|
+
children?: MathElement[];
|
|
343
|
+
text?: string;
|
|
344
|
+
}
|
|
345
|
+
interface OfficeMath {
|
|
112
346
|
text: string;
|
|
347
|
+
display: boolean;
|
|
348
|
+
sourceXml: string;
|
|
349
|
+
root?: MathElement;
|
|
350
|
+
justification?: string;
|
|
351
|
+
mathMl: string;
|
|
352
|
+
fontSizePt?: number;
|
|
353
|
+
unsupported?: string[];
|
|
354
|
+
}
|
|
355
|
+
interface TextRunProperties {
|
|
113
356
|
fontFamily?: string;
|
|
114
357
|
/** Explicit East Asian typeface declared for this run. */
|
|
115
358
|
eastAsianFontFamily?: string;
|
|
@@ -134,6 +377,30 @@ interface TextRun {
|
|
|
134
377
|
kerningThresholdPt?: number;
|
|
135
378
|
hyperlink?: string;
|
|
136
379
|
}
|
|
380
|
+
interface TextRun extends TextRunProperties {
|
|
381
|
+
math?: OfficeMath;
|
|
382
|
+
text: string;
|
|
383
|
+
field?: TextField;
|
|
384
|
+
}
|
|
385
|
+
interface TextField {
|
|
386
|
+
id?: string;
|
|
387
|
+
type?: string;
|
|
388
|
+
hasCachedText: boolean;
|
|
389
|
+
paragraphProperties?: TextFieldParagraphProperties;
|
|
390
|
+
sourcePart?: string;
|
|
391
|
+
sourceXml: string;
|
|
392
|
+
}
|
|
393
|
+
interface TextFieldParagraphProperties extends Omit<TextParagraph, 'runs'> {
|
|
394
|
+
marginRightEmu?: number;
|
|
395
|
+
fontAlignment?: string;
|
|
396
|
+
bulletNone?: boolean;
|
|
397
|
+
bulletColor?: ColorValue;
|
|
398
|
+
bulletColorFollowText?: boolean;
|
|
399
|
+
bulletFontFollowText?: boolean;
|
|
400
|
+
bulletSizeFollowText?: boolean;
|
|
401
|
+
bulletImageAssetId?: string;
|
|
402
|
+
defaultRunProperties?: TextRunProperties;
|
|
403
|
+
}
|
|
137
404
|
interface TextTabStop {
|
|
138
405
|
positionEmu: number;
|
|
139
406
|
alignment: 'left' | 'center' | 'right' | 'decimal';
|
|
@@ -179,6 +446,21 @@ interface TextAutofit {
|
|
|
179
446
|
/** PowerPoint normal-autofit line-spacing reduction, normalized to 0..1. */
|
|
180
447
|
lineSpacingReduction?: number;
|
|
181
448
|
}
|
|
449
|
+
interface ObjectAction {
|
|
450
|
+
relationshipId?: string;
|
|
451
|
+
target?: string;
|
|
452
|
+
external?: boolean;
|
|
453
|
+
action?: string;
|
|
454
|
+
tooltip?: string;
|
|
455
|
+
targetFrame?: string;
|
|
456
|
+
invalidUrl?: string;
|
|
457
|
+
history?: boolean;
|
|
458
|
+
highlightClick?: boolean;
|
|
459
|
+
endSound?: boolean;
|
|
460
|
+
soundAssetId?: string;
|
|
461
|
+
soundName?: string;
|
|
462
|
+
soundBuiltin?: boolean;
|
|
463
|
+
}
|
|
182
464
|
interface BaseSlideNode {
|
|
183
465
|
id: string;
|
|
184
466
|
name?: string;
|
|
@@ -187,10 +469,53 @@ interface BaseSlideNode {
|
|
|
187
469
|
opacity?: number;
|
|
188
470
|
hyperlink?: string;
|
|
189
471
|
altText?: string;
|
|
472
|
+
accessibilityTitle?: string;
|
|
473
|
+
description?: string;
|
|
474
|
+
decorative?: boolean;
|
|
475
|
+
clickAction?: ObjectAction;
|
|
476
|
+
hoverAction?: ObjectAction;
|
|
190
477
|
sourcePart?: string;
|
|
478
|
+
sourceId?: string;
|
|
479
|
+
editing?: ObjectEditing;
|
|
480
|
+
}
|
|
481
|
+
interface ObjectEditing {
|
|
482
|
+
kind: 'shape' | 'connector' | 'picture' | 'group' | 'graphicFrame' | 'contentPart';
|
|
483
|
+
locks?: ObjectLocks;
|
|
484
|
+
connector?: ConnectorConnections;
|
|
485
|
+
textBox?: boolean;
|
|
486
|
+
preferRelativeResize?: boolean;
|
|
487
|
+
isComment?: boolean;
|
|
488
|
+
sourceXml: string;
|
|
489
|
+
}
|
|
490
|
+
interface ObjectLocks {
|
|
491
|
+
noGrouping?: boolean;
|
|
492
|
+
noUngrouping?: boolean;
|
|
493
|
+
noSelection?: boolean;
|
|
494
|
+
noRotation?: boolean;
|
|
495
|
+
noChangeAspect?: boolean;
|
|
496
|
+
noMove?: boolean;
|
|
497
|
+
noResize?: boolean;
|
|
498
|
+
noEditPoints?: boolean;
|
|
499
|
+
noAdjustHandles?: boolean;
|
|
500
|
+
noChangeArrowheads?: boolean;
|
|
501
|
+
noChangeShapeType?: boolean;
|
|
502
|
+
noTextEdit?: boolean;
|
|
503
|
+
noCrop?: boolean;
|
|
504
|
+
noDrilldown?: boolean;
|
|
505
|
+
}
|
|
506
|
+
interface ConnectorConnections {
|
|
507
|
+
start?: ConnectorEndpoint;
|
|
508
|
+
end?: ConnectorEndpoint;
|
|
509
|
+
}
|
|
510
|
+
interface ConnectorEndpoint {
|
|
511
|
+
shapeId: number;
|
|
512
|
+
connectionSite: number;
|
|
191
513
|
}
|
|
192
514
|
interface ShapeNode extends BaseSlideNode {
|
|
193
515
|
type: 'shape';
|
|
516
|
+
shapeSvg?: string;
|
|
517
|
+
paintBounds?: PicturePaintBounds;
|
|
518
|
+
sourceXml?: string;
|
|
194
519
|
geometry: {
|
|
195
520
|
preset?: string;
|
|
196
521
|
path?: string;
|
|
@@ -208,6 +533,7 @@ interface ShapeNode extends BaseSlideNode {
|
|
|
208
533
|
};
|
|
209
534
|
autofit?: TextAutofit;
|
|
210
535
|
textRotation?: number;
|
|
536
|
+
textTransform?: Transform;
|
|
211
537
|
verticalText?: string;
|
|
212
538
|
horizontalOverflow?: string;
|
|
213
539
|
verticalOverflow?: string;
|
|
@@ -217,8 +543,66 @@ interface ShapeNode extends BaseSlideNode {
|
|
|
217
543
|
rightToLeftColumns?: boolean;
|
|
218
544
|
spaceFirstLastParagraph?: boolean;
|
|
219
545
|
}
|
|
546
|
+
interface PicturePaintBounds {
|
|
547
|
+
xPx: number;
|
|
548
|
+
yPx: number;
|
|
549
|
+
widthPx: number;
|
|
550
|
+
heightPx: number;
|
|
551
|
+
layoutWidthPx: number;
|
|
552
|
+
layoutHeightPx: number;
|
|
553
|
+
}
|
|
554
|
+
interface Model3DAsset {
|
|
555
|
+
partName: string;
|
|
556
|
+
contentType: string;
|
|
557
|
+
data?: Uint8Array;
|
|
558
|
+
}
|
|
559
|
+
interface Model3DPreview {
|
|
560
|
+
modelRelationshipId?: string;
|
|
561
|
+
rasterRelationshipId: string;
|
|
562
|
+
renderer?: string;
|
|
563
|
+
rendererVersion?: string;
|
|
564
|
+
}
|
|
565
|
+
interface Model3D {
|
|
566
|
+
modelRelationshipId?: string;
|
|
567
|
+
linkedModelRelationshipId?: string;
|
|
568
|
+
asset?: Model3DAsset;
|
|
569
|
+
preview?: Model3DPreview;
|
|
570
|
+
sourceXml: string;
|
|
571
|
+
}
|
|
220
572
|
interface ImageNode extends BaseSlideNode {
|
|
221
573
|
type: 'image';
|
|
574
|
+
model3d?: Model3D;
|
|
575
|
+
ink?: {
|
|
576
|
+
assetId?: string;
|
|
577
|
+
sourceXml?: string;
|
|
578
|
+
drawing?: {
|
|
579
|
+
sourceBounds: {
|
|
580
|
+
x: number;
|
|
581
|
+
y: number;
|
|
582
|
+
width: number;
|
|
583
|
+
height: number;
|
|
584
|
+
};
|
|
585
|
+
strokes: Array<{
|
|
586
|
+
id?: string;
|
|
587
|
+
timeOffset?: string;
|
|
588
|
+
points: Array<{
|
|
589
|
+
x: number;
|
|
590
|
+
y: number;
|
|
591
|
+
pressure: number;
|
|
592
|
+
contact: boolean;
|
|
593
|
+
}>;
|
|
594
|
+
brush: {
|
|
595
|
+
width: number;
|
|
596
|
+
height: number;
|
|
597
|
+
color: string;
|
|
598
|
+
opacity: number;
|
|
599
|
+
rectangle: boolean;
|
|
600
|
+
pencil: boolean;
|
|
601
|
+
ignorePressure: boolean;
|
|
602
|
+
};
|
|
603
|
+
}>;
|
|
604
|
+
};
|
|
605
|
+
};
|
|
222
606
|
assetId: string;
|
|
223
607
|
crop?: {
|
|
224
608
|
top: number;
|
|
@@ -226,8 +610,16 @@ interface ImageNode extends BaseSlideNode {
|
|
|
226
610
|
bottom: number;
|
|
227
611
|
left: number;
|
|
228
612
|
};
|
|
613
|
+
fallbackAssetId?: string;
|
|
229
614
|
preserveAspectRatio?: boolean;
|
|
230
615
|
effects?: ImageEffects;
|
|
616
|
+
pictureSvg?: string;
|
|
617
|
+
fallbackPicture?: {
|
|
618
|
+
svg: string;
|
|
619
|
+
paintBounds?: PicturePaintBounds | null;
|
|
620
|
+
};
|
|
621
|
+
paintBounds?: PicturePaintBounds;
|
|
622
|
+
sourceXml?: string;
|
|
231
623
|
}
|
|
232
624
|
interface GroupNode extends BaseSlideNode {
|
|
233
625
|
type: 'group';
|
|
@@ -235,6 +627,14 @@ interface GroupNode extends BaseSlideNode {
|
|
|
235
627
|
childTransform?: Transform;
|
|
236
628
|
}
|
|
237
629
|
interface TableCell {
|
|
630
|
+
merge?: {
|
|
631
|
+
horizontal: boolean;
|
|
632
|
+
vertical: boolean;
|
|
633
|
+
origin?: {
|
|
634
|
+
row: number;
|
|
635
|
+
column: number;
|
|
636
|
+
};
|
|
637
|
+
};
|
|
238
638
|
rowSpan?: number;
|
|
239
639
|
colSpan?: number;
|
|
240
640
|
fill?: FillStyle;
|
|
@@ -282,9 +682,44 @@ interface ChartNode extends BaseSlideNode {
|
|
|
282
682
|
}
|
|
283
683
|
interface MediaNode extends BaseSlideNode {
|
|
284
684
|
type: 'media';
|
|
285
|
-
mediaType: 'audio' | 'video' | 'ole' | 'unknown';
|
|
685
|
+
mediaType: 'audio' | 'video' | 'ole' | 'control' | 'unknown';
|
|
286
686
|
assetId?: string;
|
|
287
687
|
posterAssetId?: string;
|
|
688
|
+
sourceUrl?: string;
|
|
689
|
+
poster?: ImageNode;
|
|
690
|
+
playback?: {
|
|
691
|
+
trimStartMs?: number;
|
|
692
|
+
/** Duration removed from the end of the media. */
|
|
693
|
+
trimEndMs?: number;
|
|
694
|
+
fadeInMs?: number;
|
|
695
|
+
fadeOutMs?: number;
|
|
696
|
+
bookmarks?: {
|
|
697
|
+
name: string;
|
|
698
|
+
timeMs: number;
|
|
699
|
+
}[];
|
|
700
|
+
};
|
|
701
|
+
embeddedObject?: {
|
|
702
|
+
control?: {
|
|
703
|
+
classId?: string;
|
|
704
|
+
persistence?: string;
|
|
705
|
+
sourceXml?: string;
|
|
706
|
+
binaryAssetIds?: string[];
|
|
707
|
+
properties?: Array<{
|
|
708
|
+
name: string;
|
|
709
|
+
value?: string;
|
|
710
|
+
}>;
|
|
711
|
+
};
|
|
712
|
+
programId?: string;
|
|
713
|
+
name?: string;
|
|
714
|
+
relationshipId?: string;
|
|
715
|
+
linked: boolean;
|
|
716
|
+
showAsIcon?: boolean;
|
|
717
|
+
previewWidthEmu?: number;
|
|
718
|
+
previewHeightEmu?: number;
|
|
719
|
+
followColorScheme?: string;
|
|
720
|
+
updateAutomatic?: boolean;
|
|
721
|
+
};
|
|
722
|
+
sourceXml?: string;
|
|
288
723
|
}
|
|
289
724
|
interface UnknownNode extends BaseSlideNode {
|
|
290
725
|
type: 'unknown';
|
|
@@ -293,6 +728,7 @@ interface UnknownNode extends BaseSlideNode {
|
|
|
293
728
|
}
|
|
294
729
|
type SlideNode = ShapeNode | ImageNode | GroupNode | TableNode | ChartNode | MediaNode | UnknownNode;
|
|
295
730
|
interface PresentationTheme {
|
|
731
|
+
formatSchemeXml?: string;
|
|
296
732
|
id: string;
|
|
297
733
|
name?: string;
|
|
298
734
|
colors: Record<string, string>;
|
|
@@ -303,25 +739,77 @@ interface SlideMaster {
|
|
|
303
739
|
id: string;
|
|
304
740
|
name?: string;
|
|
305
741
|
themeId?: string;
|
|
742
|
+
transition?: SlideTransition;
|
|
743
|
+
timing?: SlideTiming;
|
|
306
744
|
nodes: SlideNode[];
|
|
307
745
|
}
|
|
308
746
|
interface SlideLayout {
|
|
309
747
|
id: string;
|
|
310
748
|
name?: string;
|
|
311
749
|
masterId?: string;
|
|
750
|
+
transition?: SlideTransition;
|
|
751
|
+
timing?: SlideTiming;
|
|
312
752
|
nodes: SlideNode[];
|
|
313
753
|
}
|
|
314
754
|
interface SlideNote {
|
|
315
755
|
text: string;
|
|
756
|
+
paragraphs?: TextParagraph[];
|
|
316
757
|
}
|
|
317
758
|
interface SlideComment {
|
|
318
759
|
id: string;
|
|
319
760
|
author?: string;
|
|
761
|
+
authorId?: string;
|
|
762
|
+
authorInitials?: string;
|
|
763
|
+
sourceIndex?: number;
|
|
764
|
+
sourcePart?: string;
|
|
320
765
|
text: string;
|
|
766
|
+
paragraphs?: TextParagraph[];
|
|
767
|
+
replies?: SlideComment[];
|
|
768
|
+
modern?: ModernComment;
|
|
321
769
|
createdAt?: string;
|
|
770
|
+
modifiedAt?: string;
|
|
771
|
+
position?: {
|
|
772
|
+
x: number;
|
|
773
|
+
y: number;
|
|
774
|
+
unit: 'eighthPoint';
|
|
775
|
+
};
|
|
322
776
|
x?: number;
|
|
323
777
|
y?: number;
|
|
324
778
|
}
|
|
779
|
+
interface ModernComment {
|
|
780
|
+
status: string;
|
|
781
|
+
authorUserId?: string;
|
|
782
|
+
authorProviderId?: string;
|
|
783
|
+
authorExtensionsXml?: string;
|
|
784
|
+
anchors?: CommentAnchor[];
|
|
785
|
+
positionEmu?: {
|
|
786
|
+
x: number;
|
|
787
|
+
y: number;
|
|
788
|
+
sourceX: string;
|
|
789
|
+
sourceY: string;
|
|
790
|
+
};
|
|
791
|
+
task?: CommentTask;
|
|
792
|
+
extensionsXml?: string;
|
|
793
|
+
}
|
|
794
|
+
interface CommentTask {
|
|
795
|
+
startDate?: string;
|
|
796
|
+
dueDate?: string;
|
|
797
|
+
assignedTo: string[];
|
|
798
|
+
title: string;
|
|
799
|
+
completion: string;
|
|
800
|
+
completionFraction?: number;
|
|
801
|
+
}
|
|
802
|
+
interface CommentAnchor {
|
|
803
|
+
kind: 'slide' | 'drawingElement' | 'textRange' | 'unknown';
|
|
804
|
+
monikers: CommentMoniker[];
|
|
805
|
+
}
|
|
806
|
+
interface CommentMoniker {
|
|
807
|
+
namespace: string;
|
|
808
|
+
name: string;
|
|
809
|
+
attributes: Record<string, string>;
|
|
810
|
+
children?: CommentMoniker[];
|
|
811
|
+
text?: string;
|
|
812
|
+
}
|
|
325
813
|
interface PresentationSlide {
|
|
326
814
|
id: string;
|
|
327
815
|
index: number;
|
|
@@ -330,6 +818,8 @@ interface PresentationSlide {
|
|
|
330
818
|
masterId?: string;
|
|
331
819
|
layoutId?: string;
|
|
332
820
|
background?: FillStyle;
|
|
821
|
+
transition?: SlideTransition;
|
|
822
|
+
timing?: SlideTiming;
|
|
333
823
|
nodes: SlideNode[];
|
|
334
824
|
notes?: SlideNote[];
|
|
335
825
|
comments?: SlideComment[];
|
|
@@ -395,6 +885,7 @@ type ViewerZoomState = {
|
|
|
395
885
|
resolvedZoom: number;
|
|
396
886
|
};
|
|
397
887
|
interface ParsePresentationOptions {
|
|
888
|
+
include3dModels?: boolean;
|
|
398
889
|
signal?: AbortSignal;
|
|
399
890
|
formatHint?: PresentationFormat;
|
|
400
891
|
maxInputBytes?: number;
|
|
@@ -675,6 +1166,7 @@ declare const ReactPptxViewer: react.ForwardRefExoticComponent<Omit<ReactPptxVie
|
|
|
675
1166
|
declare function parsePresentation(source: PresentationSource, options?: ParsePresentationOptions): Promise<ParsedPresentation>;
|
|
676
1167
|
declare const presentationParsingDefaults: Readonly<{
|
|
677
1168
|
maxInputBytes: number;
|
|
1169
|
+
include3dModels: false;
|
|
678
1170
|
}>;
|
|
679
1171
|
|
|
680
1172
|
type WasmSource = string | URL | Request | Response | BufferSource | WebAssembly.Module;
|
|
@@ -713,4 +1205,4 @@ declare function createPptxThumbnailRenderer(presentation: ParsedPresentation, o
|
|
|
713
1205
|
declare const OFFICE_FONT_FALLBACKS: Readonly<Record<string, readonly string[]>>;
|
|
714
1206
|
declare function resolvePptxFontFamily(fontFamily: string, options?: Pick<PptxFontOptions, 'fallbacks' | 'fallbackFamilies' | 'useOfficeFallbacks'>): string;
|
|
715
1207
|
|
|
716
|
-
export { type BinaryPresentationSource, type FitMode, OFFICE_FONT_FALLBACKS, type ParsePresentationOptions, type ParsedPresentation, type PptxFontOptions, type PptxFontSource, type PptxPerformanceMeasurement, type PptxPerformancePhase, type PptxSlideThumbnailItem, type PptxSlideThumbnailRenderOptions, type PptxSlideThumbnailRenderWindow, type PptxSlideThumbnailResolution, type PptxSlideThumbnailStatus, type PptxThumbnailOutput, type PptxThumbnailRenderOptions, type PptxThumbnailRenderResult, type PptxThumbnailRenderer, type PptxThumbnailRendererOptions, type PptxViewerController, PptxViewerError, type PptxViewerThumbnails, type PresentationAsset, type PresentationDocument, type PresentationEmbeddedFont, type PresentationFormat, type PresentationMetadata, type PresentationSearchResult, type PresentationSlide, type PresentationSource, type PresentationTheme, type PresentationWarning, ReactPptxViewer, type ReactPptxViewerProps, type SearchHighlightOptions, type Slide, type SlideComment, type SlideLayout, type SlideMaster, type SlideNode, type SlideNote, type ThumbnailRenderContext, type UsePptxPresentationState, type UsePptxViewerResult, type UsePptxViewerThumbnailsOptions, type ViewerMode, type ViewerSearchOptions, type ViewerZoomLevel, type ViewerZoomMode, type ViewerZoomState, type VirtualizationOptions, type WasmSource, type WorkerWasmSource, createPptxThumbnailRenderer, initWasm, parsePresentation, presentationParsingDefaults, resolvePptxFontFamily, setWasmSource, usePptxModel, usePptxPresentation, usePptxViewer, usePptxViewerThumbnails };
|
|
1208
|
+
export { type BinaryPresentationSource, type CommentAnchor, type CommentMoniker, type CommentTask, type FitMode, type ModernComment, OFFICE_FONT_FALLBACKS, type ParsePresentationOptions, type ParsedPresentation, type PicturePaintBounds, type PptxFontOptions, type PptxFontSource, type PptxPerformanceMeasurement, type PptxPerformancePhase, type PptxSlideThumbnailItem, type PptxSlideThumbnailRenderOptions, type PptxSlideThumbnailRenderWindow, type PptxSlideThumbnailResolution, type PptxSlideThumbnailStatus, type PptxThumbnailOutput, type PptxThumbnailRenderOptions, type PptxThumbnailRenderResult, type PptxThumbnailRenderer, type PptxThumbnailRendererOptions, type PptxViewerController, PptxViewerError, type PptxViewerThumbnails, type PresentationAsset, type PresentationDocument, type PresentationEmbeddedFont, type PresentationFormat, type PresentationMetadata, type PresentationSearchResult, type PresentationSlide, type PresentationSource, type PresentationTheme, type PresentationWarning, ReactPptxViewer, type ReactPptxViewerProps, type SearchHighlightOptions, type Slide, type SlideComment, type SlideLayout, type SlideMaster, type SlideNode, type SlideNote, type ThumbnailRenderContext, type UsePptxPresentationState, type UsePptxViewerResult, type UsePptxViewerThumbnailsOptions, type ViewerMode, type ViewerSearchOptions, type ViewerZoomLevel, type ViewerZoomMode, type ViewerZoomState, type VirtualizationOptions, type WasmSource, type WorkerWasmSource, createPptxThumbnailRenderer, initWasm, parsePresentation, presentationParsingDefaults, resolvePptxFontFamily, setWasmSource, usePptxModel, usePptxPresentation, usePptxViewer, usePptxViewerThumbnails };
|