ooxml-ui 1.30.0 → 1.32.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/README.md +10 -0
- package/custom-elements.json +4 -0
- package/dist/building-block-styles.d.ts +0 -1
- package/dist/chart/format-pane-3d.d.ts +0 -1
- package/dist/chart/format-pane-analysis.d.ts +0 -1
- package/dist/chart/format-pane-fill-line.d.ts +0 -1
- package/dist/chart/format-pane-text.d.ts +0 -1
- package/dist/{chunk-SBBFNAKM.js → chunk-32P252JS.js} +3 -3
- package/dist/{chunk-E4H3Y7M4.js → chunk-6TS7ASDJ.js} +1 -1
- package/dist/{chunk-BKHWBIXP.js → chunk-CALEXPBD.js} +132 -69
- package/dist/{chunk-SXVOXSTE.js → chunk-CDC5MAZS.js} +1 -1
- package/dist/chunk-DA57FPSN.js +54 -0
- package/dist/{chunk-HNREZW5U.js → chunk-KYXSQFDB.js} +484 -1
- package/dist/{chunk-IE6HKH4X.js → chunk-OKEFAQJT.js} +1 -1
- package/dist/controls.d.ts +6 -0
- package/dist/controls.d.ts.map +1 -1
- package/dist/controls.js +1 -1
- package/dist/dialog/dialog-session.d.ts +19 -0
- package/dist/dialog/dialog-session.d.ts.map +1 -0
- package/dist/docx/smartart-node-view.d.ts +1 -1
- package/dist/docx.js +36 -20
- package/dist/fonts/availability.d.ts +10 -0
- package/dist/fonts/availability.d.ts.map +1 -0
- package/dist/fonts/catalog.d.ts +63 -0
- package/dist/fonts/catalog.d.ts.map +1 -0
- package/dist/fonts/custom-fonts.d.ts +75 -0
- package/dist/fonts/custom-fonts.d.ts.map +1 -0
- package/dist/form/color-input/live-color-input.d.ts +93 -0
- package/dist/form/color-input/live-color-input.d.ts.map +1 -0
- package/dist/form/color-input/live-color-leaves.d.ts +34 -0
- package/dist/form/color-input/live-color-leaves.d.ts.map +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +6 -5
- package/dist/picture-effects.d.ts +6 -0
- package/dist/pptx/ai/host.cjs +41 -37
- package/dist/pptx/ai/host.d.ts +2 -0
- package/dist/pptx/ai/host.d.ts.map +1 -1
- package/dist/pptx/ai/host.mjs +2 -2
- package/dist/pptx/ai/index.cjs +47 -43
- package/dist/pptx/ai/index.d.ts +2 -0
- package/dist/pptx/ai/index.d.ts.map +1 -1
- package/dist/pptx/ai/index.mjs +3 -3
- package/dist/pptx/{chart-3d-view-scene-ZUGA3DKM.mjs → chart-3d-view-scene-HNL4NWJT.mjs} +2 -2
- package/dist/pptx/{chart-3d-view-scene-N7UQOYFI.cjs → chart-3d-view-scene-OPVBTZL5.cjs} +38 -38
- package/dist/pptx/chunk-3RIGT7H6.cjs +82 -0
- package/dist/pptx/{chunk-D7UYDESZ.mjs → chunk-7DT3UJQB.mjs} +3 -3
- package/dist/pptx/{chunk-KY75GY5O.mjs → chunk-7FXQHSPE.mjs} +6 -24
- package/dist/pptx/{chunk-45OYSCLD.mjs → chunk-CH4Z6H6C.mjs} +581 -230
- package/dist/pptx/{chunk-6KLPQQYP.cjs → chunk-D4LJJ7Z7.cjs} +77 -327
- package/dist/pptx/{chunk-MNSWEXYO.mjs → chunk-DACFW5LO.mjs} +26 -3
- package/dist/pptx/{chunk-IOOI63TH.cjs → chunk-FFWLDANS.cjs} +6 -24
- package/dist/pptx/{chunk-SMMEIEEJ.mjs → chunk-KGDMMWIY.mjs} +1 -1
- package/dist/pptx/{chunk-LXEMMWVI.mjs → chunk-LCCRLB7Q.mjs} +1 -1
- package/dist/pptx/{chunk-BMMTD6PB.cjs → chunk-M55PNMFQ.cjs} +2 -2
- package/dist/pptx/chunk-PM2SOLK3.mjs +79 -0
- package/dist/pptx/{chunk-QX6XPYVA.mjs → chunk-PTIGQSTY.mjs} +31 -14
- package/dist/pptx/{chunk-34LEUH5R.mjs → chunk-RZVEPTLN.mjs} +63 -316
- package/dist/pptx/{chunk-CQYWHRZE.cjs → chunk-S3L5NNCK.cjs} +1 -1
- package/dist/pptx/{chunk-H5IPNKX6.cjs → chunk-S5I64Y55.cjs} +12 -12
- package/dist/pptx/{chunk-WQA3KZRB.mjs → chunk-SPOECCPV.mjs} +1 -1
- package/dist/pptx/{chunk-YMWEU56T.cjs → chunk-TDIJHLS5.cjs} +927 -543
- package/dist/pptx/{chunk-QWF3PGUX.cjs → chunk-VEFFYJGG.cjs} +26 -2
- package/dist/pptx/{chunk-BSGCZ4JZ.cjs → chunk-WBGU7BWD.cjs} +31 -14
- package/dist/pptx/{chunk-2CBK46AW.cjs → chunk-ZS5EVODY.cjs} +48 -48
- package/dist/pptx/dom/index.cjs +431 -430
- package/dist/pptx/dom/index.mjs +15 -14
- package/dist/pptx/export/html2canvas-clone.cjs +6 -6
- package/dist/pptx/export/html2canvas-clone.mjs +1 -1
- package/dist/pptx/index.cjs +3423 -3355
- package/dist/pptx/index.mjs +8 -8
- package/dist/pptx/render/bullet-toggle-selection.d.ts +8 -4
- package/dist/pptx/render/bullet-toggle-selection.d.ts.map +1 -1
- package/dist/pptx/render/chart-box-whisker.d.ts.map +1 -1
- package/dist/pptx/render/chart-combo-stock.cjs +3 -3
- package/dist/pptx/render/chart-combo-stock.mjs +1 -1
- package/dist/pptx/render/chart-data-table-metrics.d.ts +1 -1
- package/dist/pptx/render/chart-data-table-metrics.d.ts.map +1 -1
- package/dist/pptx/render/chart-data-table-render.d.ts.map +1 -1
- package/dist/pptx/render/chart-date-axis.d.ts +1 -1
- package/dist/pptx/render/chart-date-axis.d.ts.map +1 -1
- package/dist/pptx/render/chart-date-format.d.ts +1 -30
- package/dist/pptx/render/chart-date-format.d.ts.map +1 -1
- package/dist/pptx/render/chart-funnel-sunburst.d.ts +1 -1
- package/dist/pptx/render/chart-funnel-sunburst.d.ts.map +1 -1
- package/dist/pptx/render/chart-line-path.d.ts +2 -26
- package/dist/pptx/render/chart-line-path.d.ts.map +1 -1
- package/dist/pptx/render/chart-manual-layout.d.ts +1 -1
- package/dist/pptx/render/chart-manual-layout.d.ts.map +1 -1
- package/dist/pptx/render/chart-overlays.cjs +7 -7
- package/dist/pptx/render/chart-overlays.mjs +1 -1
- package/dist/pptx/render/chart-surface-treemap.cjs +4 -4
- package/dist/pptx/render/chart-surface-treemap.mjs +1 -1
- package/dist/pptx/render/chart-view-model-layout.d.ts.map +1 -1
- package/dist/pptx/render/chart-view-model.cjs +44 -44
- package/dist/pptx/render/chart-view-model.mjs +1 -1
- package/dist/pptx/render/chart-waterfall-map.cjs +6 -6
- package/dist/pptx/render/chart-waterfall-map.mjs +1 -1
- package/dist/pptx/render/controller/ai-assistant.d.ts +73 -0
- package/dist/pptx/render/controller/ai-assistant.d.ts.map +1 -0
- package/dist/pptx/render/controller/autosave-controller.d.ts.map +1 -1
- package/dist/pptx/render/controller/collaboration-history.d.ts +25 -0
- package/dist/pptx/render/controller/collaboration-history.d.ts.map +1 -1
- package/dist/pptx/render/controller/history-controller.d.ts +9 -0
- package/dist/pptx/render/controller/history-controller.d.ts.map +1 -1
- package/dist/pptx/render/controller/index.d.ts +4 -0
- package/dist/pptx/render/controller/index.d.ts.map +1 -1
- package/dist/pptx/render/custom-fonts.cjs +9 -5
- package/dist/pptx/render/custom-fonts.d.ts +1 -64
- package/dist/pptx/render/custom-fonts.d.ts.map +1 -1
- package/dist/pptx/render/custom-fonts.mjs +1 -1
- package/dist/pptx/render/editor-geometry.d.ts +3 -15
- package/dist/pptx/render/editor-geometry.d.ts.map +1 -1
- package/dist/pptx/render/font-availability.d.ts +1 -9
- package/dist/pptx/render/font-availability.d.ts.map +1 -1
- package/dist/pptx/render/font-catalog.cjs +3 -3
- package/dist/pptx/render/font-catalog.d.ts +3 -61
- package/dist/pptx/render/font-catalog.d.ts.map +1 -1
- package/dist/pptx/render/font-catalog.mjs +1 -1
- package/dist/pptx/render/hyperlink-security.cjs +8 -8
- package/dist/pptx/render/hyperlink-security.d.ts +1 -27
- package/dist/pptx/render/hyperlink-security.d.ts.map +1 -1
- package/dist/pptx/render/hyperlink-security.mjs +1 -1
- package/dist/pptx/render/image-effects.d.ts.map +1 -1
- package/dist/pptx/render/index.d.ts +2 -0
- package/dist/pptx/render/index.d.ts.map +1 -1
- package/dist/pptx/render/inline-list-style.d.ts +2 -1
- package/dist/pptx/render/inline-list-style.d.ts.map +1 -1
- package/dist/pptx/render/live-color-input.d.ts +2 -92
- package/dist/pptx/render/live-color-input.d.ts.map +1 -1
- package/dist/pptx/render/live-color-leaves.d.ts +2 -33
- package/dist/pptx/render/live-color-leaves.d.ts.map +1 -1
- package/dist/pptx/render/options/autocorrect.d.ts +15 -2
- package/dist/pptx/render/options/autocorrect.d.ts.map +1 -1
- package/dist/pptx/render/picture-crop/crop-geometry.d.ts +2 -20
- package/dist/pptx/render/picture-crop/crop-geometry.d.ts.map +1 -1
- package/dist/pptx/render/slides-pane-model.d.ts +79 -0
- package/dist/pptx/render/slides-pane-model.d.ts.map +1 -0
- package/dist/pptx/render/table-cell-edit.d.ts +1 -1
- package/dist/pptx/render/table-cell-edit.d.ts.map +1 -1
- package/dist/pptx/render/text-list-style-update.d.ts +23 -2
- package/dist/pptx/render/text-list-style-update.d.ts.map +1 -1
- package/dist/pptx/render/text-script-fonts.d.ts +4 -72
- package/dist/pptx/render/text-script-fonts.d.ts.map +1 -1
- package/dist/pptx/render/text-warp-envelope-block.d.ts +10 -1
- package/dist/pptx/render/text-warp-envelope-block.d.ts.map +1 -1
- package/dist/pptx/render/text-warp-envelope-curves.d.ts +8 -0
- package/dist/pptx/render/text-warp-envelope-curves.d.ts.map +1 -1
- package/dist/pptx/render/text-warp-envelope-layout.d.ts +9 -3
- package/dist/pptx/render/text-warp-envelope-layout.d.ts.map +1 -1
- package/dist/pptx/render/text-warp-envelope-map.d.ts.map +1 -1
- package/dist/pptx/render/text-warp-envelope-wrap.d.ts +29 -0
- package/dist/pptx/render/text-warp-envelope-wrap.d.ts.map +1 -0
- package/dist/pptx/render/text-warp-preset-definitions.d.ts +13 -0
- package/dist/pptx/render/text-warp-preset-definitions.d.ts.map +1 -1
- package/dist/pptx/render/text-warp-preset-sampler.d.ts +12 -0
- package/dist/pptx/render/text-warp-preset-sampler.d.ts.map +1 -1
- package/dist/pptx/render/text-warp.d.ts +3 -2
- package/dist/pptx/render/text-warp.d.ts.map +1 -1
- package/dist/pptx/render/viewer-props-manifest.d.ts.map +1 -1
- package/dist/pptx/{smartart-insert-preview-SKFD7NCQ.mjs → smartart-insert-preview-RQUFRLSV.mjs} +9 -9
- package/dist/pptx/{smartart-insert-preview-7OL7VWEK.cjs → smartart-insert-preview-YKNB37GE.cjs} +10 -10
- package/dist/recovery-scheduler.d.ts +18 -0
- package/dist/recovery-scheduler.d.ts.map +1 -0
- package/dist/smartart/smartart-geometry.d.ts +1 -3
- package/dist/smartart/smartart-paint.d.ts +2 -1
- package/dist/smartart/smartart-picture.d.ts +7 -0
- package/dist/smartart/smartart-svg.d.ts +2 -1
- package/dist/smartart/smartart.d.ts +6 -0
- package/dist/smartart.js +1 -1
- package/dist/teams.js +2 -2
- package/dist/theme-bridge.d.ts +0 -1
- package/dist/theme.d.ts +0 -1
- package/dist/visio/controller.d.ts +2 -2
- package/dist/visio/viewer-autorecover.d.ts +0 -1
- package/dist/visio/viewer-commands.d.ts +1 -1
- package/dist/visio/viewer-guides.d.ts +2 -2
- package/dist/visio/viewer-pointer-gestures.d.ts +1 -1
- package/dist/visio/viewer-resize-frame.d.ts +2 -2
- package/dist/visio/viewer-resize-handles.d.ts +1 -1
- package/dist/visio.js +109 -62
- package/dist/xlsx/grid/smartart.d.ts +1 -1
- package/dist/xlsx.js +91 -62
- package/package.json +2 -2
- package/dist/pptx/chunk-WM5SW737.mjs +0 -27
- package/dist/pptx/chunk-Y6DO6SVT.cjs +0 -29
|
@@ -1,4 +1,17 @@
|
|
|
1
1
|
import type { ViewerProofingOptions } from './viewer-options.js';
|
|
2
|
-
/**
|
|
3
|
-
|
|
2
|
+
/**
|
|
3
|
+
* Apply every enabled AutoCorrect rule to a run of text. `lead` is the text that
|
|
4
|
+
* precedes the run (default: none, so the run starts a sentence); it only decides
|
|
5
|
+
* quote direction and whether the run's first letter starts a sentence.
|
|
6
|
+
*/
|
|
7
|
+
export declare function applyAutoCorrect(text: string, proofing: ViewerProofingOptions, lead?: string): string;
|
|
8
|
+
/**
|
|
9
|
+
* AutoCorrect only what was typed in this edit. `previous` is the text before the
|
|
10
|
+
* edit and `text` the committed text; the range that differs (grown to whole
|
|
11
|
+
* words, like the word being completed) is corrected with the text before it as
|
|
12
|
+
* context, and everything else is left exactly as it was, so a URL or a
|
|
13
|
+
* collaborator's words are never rewritten. Without `previous` the whole text is
|
|
14
|
+
* treated as typed.
|
|
15
|
+
*/
|
|
16
|
+
export declare function applyAutoCorrectToEdit(text: string, previous: string | undefined, proofing: ViewerProofingOptions): string;
|
|
4
17
|
//# sourceMappingURL=autocorrect.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"autocorrect.d.ts","sourceRoot":"","sources":["../../../../src/pptx/render/options/autocorrect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;
|
|
1
|
+
{"version":3,"file":"autocorrect.d.ts","sourceRoot":"","sources":["../../../../src/pptx/render/options/autocorrect.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,kBAAkB,CAAC;AA2G9D;;;;GAIG;AACH,wBAAgB,gBAAgB,CAAC,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,qBAAqB,EAAE,IAAI,SAAK,GAAG,MAAM,CA0BjG;AAqCD;;;;;;;GAOG;AACH,wBAAgB,sBAAsB,CACrC,IAAI,EAAE,MAAM,EACZ,QAAQ,EAAE,MAAM,GAAG,SAAS,EAC5B,QAAQ,EAAE,qBAAqB,GAC7B,MAAM,CAcR"}
|
|
@@ -15,22 +15,8 @@
|
|
|
15
15
|
* @module render/picture-crop/crop-geometry
|
|
16
16
|
*/
|
|
17
17
|
import type { PptxElement } from 'ooxml-core/pptx';
|
|
18
|
-
|
|
19
|
-
export
|
|
20
|
-
x: number;
|
|
21
|
-
y: number;
|
|
22
|
-
width: number;
|
|
23
|
-
height: number;
|
|
24
|
-
}
|
|
25
|
-
/** The four `a:srcRect` insets as fractions of the image (negative pads). */
|
|
26
|
-
export interface CropInsets {
|
|
27
|
-
cropLeft: number;
|
|
28
|
-
cropTop: number;
|
|
29
|
-
cropRight: number;
|
|
30
|
-
cropBottom: number;
|
|
31
|
-
}
|
|
32
|
-
/** What a crop edit writes back onto the picture element. */
|
|
33
|
-
export type CropElementUpdate = CropInsets & CropRect;
|
|
18
|
+
import { type CropRect, type CropInsets, type CropElementUpdate } from 'ooxml-core/geometry';
|
|
19
|
+
export { imageRectFromCrop, cropUpdateFromRects, type CropRect, type CropInsets, type CropElementUpdate, } from 'ooxml-core/geometry';
|
|
34
20
|
/** One of the eight crop handles, named by compass direction. */
|
|
35
21
|
export type CropHandleId = 'nw' | 'n' | 'ne' | 'e' | 'se' | 's' | 'sw' | 'w';
|
|
36
22
|
/** Smallest frame a handle drag may leave, in slide pixels. */
|
|
@@ -39,10 +25,6 @@ export declare const MIN_CROP_FRAME_PX = 8;
|
|
|
39
25
|
export declare function readCropInsets(el: PptxElement): CropInsets;
|
|
40
26
|
/** The element's box. */
|
|
41
27
|
export declare function cropFrameOf(el: PptxElement): CropRect;
|
|
42
|
-
/** The whole image's rectangle, derived from the frame and the insets. */
|
|
43
|
-
export declare function imageRectFromCrop(frame: CropRect, insets: CropInsets): CropRect;
|
|
44
|
-
/** The insets that show `frame` out of `image`, plus the frame itself. */
|
|
45
|
-
export declare function cropUpdateFromRects(frame: CropRect, image: CropRect): CropElementUpdate;
|
|
46
28
|
/**
|
|
47
29
|
* Where a crop drag starts: the frame and image when the pointer went down, in
|
|
48
30
|
* DISPLAY terms (a flipped picture shows its `a:srcRect/@l` inset on the right)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"crop-geometry.d.ts","sourceRoot":"","sources":["../../../../src/pptx/render/picture-crop/crop-geometry.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAEnD,
|
|
1
|
+
{"version":3,"file":"crop-geometry.d.ts","sourceRoot":"","sources":["../../../../src/pptx/render/picture-crop/crop-geometry.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAEnD,OAAO,EAGN,KAAK,QAAQ,EACb,KAAK,UAAU,EACf,KAAK,iBAAiB,EACtB,MAAM,qBAAqB,CAAC;AAC7B,OAAO,EACN,iBAAiB,EACjB,mBAAmB,EACnB,KAAK,QAAQ,EACb,KAAK,UAAU,EACf,KAAK,iBAAiB,GACtB,MAAM,qBAAqB,CAAC;AAE7B,iEAAiE;AACjE,MAAM,MAAM,YAAY,GAAG,IAAI,GAAG,GAAG,GAAG,IAAI,GAAG,GAAG,GAAG,IAAI,GAAG,GAAG,GAAG,IAAI,GAAG,GAAG,CAAC;AAE7E,+DAA+D;AAC/D,eAAO,MAAM,iBAAiB,IAAI,CAAC;AAMnC,+DAA+D;AAC/D,wBAAgB,cAAc,CAAC,EAAE,EAAE,WAAW,GAAG,UAAU,CAQ1D;AAED,yBAAyB;AACzB,wBAAgB,WAAW,CAAC,EAAE,EAAE,WAAW,GAAG,QAAQ,CAErD;AAED;;;;GAIG;AACH,MAAM,WAAW,aAAa;IAC7B,KAAK,EAAE,QAAQ,CAAC;IAChB,KAAK,EAAE,QAAQ,CAAC;IAChB,QAAQ,EAAE,MAAM,CAAC;IACjB,cAAc,EAAE,OAAO,CAAC;IACxB,YAAY,EAAE,OAAO,CAAC;CACtB;AAaD,2CAA2C;AAC3C,wBAAgB,aAAa,CAAC,EAAE,EAAE,WAAW,GAAG,aAAa,CAY5D;AAED;;;;GAIG;AACH,wBAAgB,gBAAgB,CAC/B,KAAK,EAAE,aAAa,EACpB,KAAK,EAAE,QAAQ,EACf,KAAK,EAAE,QAAQ,GACb,iBAAiB,CAgBnB;AAgBD;;;;GAIG;AACH,wBAAgB,cAAc,CAC7B,KAAK,EAAE,aAAa,EACpB,MAAM,EAAE,YAAY,EACpB,EAAE,EAAE,MAAM,EACV,EAAE,EAAE,MAAM,GACR,iBAAiB,CA6BnB;AAED;;;GAGG;AACH,wBAAgB,YAAY,CAAC,KAAK,EAAE,aAAa,EAAE,EAAE,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,GAAG,iBAAiB,CAc5F;AAED,2EAA2E;AAC3E,wBAAgB,aAAa,CAAC,EAAE,EAAE,MAAM,EAAE,EAAE,EAAE,MAAM,EAAE,WAAW,SAAI,GAAG;IAAE,EAAE,EAAE,MAAM,CAAC;IAAC,EAAE,EAAE,MAAM,CAAA;CAAE,CAMjG;AAED,6DAA6D;AAC7D,wBAAgB,OAAO,CAAC,EAAE,EAAE,WAAW,GAAG,OAAO,CAQhD"}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import type { PptxCustomProperty, PptxHeaderFooter } from 'ooxml-core/pptx';
|
|
2
|
+
import type { FieldSubstitutionContext } from './text-field-substitution.js';
|
|
3
|
+
/**
|
|
4
|
+
* Framework-free wiring for the slides pane (the slide thumbnail rail) when a
|
|
5
|
+
* host composes it beside its own canvas instead of using the full viewer.
|
|
6
|
+
*
|
|
7
|
+
* Every binding exposes its own rail component; this module holds what they
|
|
8
|
+
* share, so each binding only maps it onto its template: the deck-wide field
|
|
9
|
+
* and table style contexts the thumbnails need to draw what the canvas draws,
|
|
10
|
+
* the rehearsal timings shown under each thumbnail, the bulk slide commands
|
|
11
|
+
* the rail's context menu issues, and the hand-off of the "Layout" entry to a
|
|
12
|
+
* host that renders its own Layout gallery.
|
|
13
|
+
*/
|
|
14
|
+
/** Deck-level inputs of the rail's thumbnail field context. */
|
|
15
|
+
export interface SlidesPaneFieldContextSources {
|
|
16
|
+
headerFooter?: PptxHeaderFooter;
|
|
17
|
+
customProperties?: readonly PptxCustomProperty[];
|
|
18
|
+
/** `p:presentation@firstSlideNum`; numbering starts at 1 when undefined. */
|
|
19
|
+
firstSlideNumber?: number | undefined;
|
|
20
|
+
locale?: string;
|
|
21
|
+
}
|
|
22
|
+
/**
|
|
23
|
+
* The deck-wide field context for the rail's thumbnails. Built with the same
|
|
24
|
+
* helper as the canvas, without a slide: each thumbnail re-points the slide
|
|
25
|
+
* number and title at its own slide, so one context serves every thumbnail and
|
|
26
|
+
* stays stable while the active slide changes.
|
|
27
|
+
*/
|
|
28
|
+
export declare function buildSlidesPaneFieldContext(sources: SlidesPaneFieldContextSources): FieldSubstitutionContext;
|
|
29
|
+
/**
|
|
30
|
+
* The rail's table style context: the theme and table style map the canvas
|
|
31
|
+
* resolves table colours from, or `undefined` when the deck has neither (the
|
|
32
|
+
* canvas's "no context" fallback). Generic so each binding keeps its own
|
|
33
|
+
* theme and style map types.
|
|
34
|
+
*/
|
|
35
|
+
export declare function buildSlidesPaneTableStyleContext<TTheme, TStyleMap>(theme: TTheme | undefined, tableStyleMap: TStyleMap | undefined): {
|
|
36
|
+
theme: TTheme | undefined;
|
|
37
|
+
tableStyleMap: TStyleMap | undefined;
|
|
38
|
+
} | undefined;
|
|
39
|
+
/**
|
|
40
|
+
* Rehearsal timings (slide index to seconds) for the rail, or `undefined` when
|
|
41
|
+
* none were recorded, so the rail shows no timing row on an unrehearsed deck.
|
|
42
|
+
*/
|
|
43
|
+
export declare function slidesPaneRehearsalTimings(recordedTimings: Readonly<Record<number, number>> | undefined): Record<number, number> | undefined;
|
|
44
|
+
/** Where the rail asked for the Layout gallery: the slide, and the click point. */
|
|
45
|
+
export interface SlidesPaneLayoutGalleryRequest {
|
|
46
|
+
/** Zero-based index of the slide whose layout is being changed (now the active slide). */
|
|
47
|
+
slideIndex: number;
|
|
48
|
+
/** Viewport x of the context-menu click, to anchor the gallery. */
|
|
49
|
+
x: number;
|
|
50
|
+
/** Viewport y of the context-menu click, to anchor the gallery. */
|
|
51
|
+
y: number;
|
|
52
|
+
}
|
|
53
|
+
/**
|
|
54
|
+
* The rail context menu's "Layout" entry for a host that renders its own
|
|
55
|
+
* Layout gallery: makes the slide active, then hands the request to the host.
|
|
56
|
+
* Without a host handler the slide still becomes active, so the entry is never
|
|
57
|
+
* a silent no-op.
|
|
58
|
+
*/
|
|
59
|
+
export declare function openSlidesPaneLayoutGallery(request: SlidesPaneLayoutGalleryRequest, setActiveSlide: (index: number) => void, onOpenLayoutGallery: ((request: SlidesPaneLayoutGalleryRequest) => void) | undefined): void;
|
|
60
|
+
/** Single-slide operations a binding already has, lifted to the rail's multi-selection. */
|
|
61
|
+
export interface SlidesPaneSingleSlideOps {
|
|
62
|
+
duplicateSlide: (index: number) => void;
|
|
63
|
+
deleteSlide: (index: number) => void;
|
|
64
|
+
toggleSlideHidden: (index: number) => void;
|
|
65
|
+
}
|
|
66
|
+
/** The rail's multi-selection commands. */
|
|
67
|
+
export interface SlidesPaneBulkSlideOps {
|
|
68
|
+
duplicateSlides: (indexes: readonly number[]) => void;
|
|
69
|
+
deleteSlides: (indexes: readonly number[]) => void;
|
|
70
|
+
toggleHideSlides: (indexes: readonly number[]) => void;
|
|
71
|
+
}
|
|
72
|
+
/**
|
|
73
|
+
* Bulk rail commands over single-slide operations. Deletion runs from the
|
|
74
|
+
* highest index down so earlier deletions do not shift the indexes still to
|
|
75
|
+
* delete; duplication runs from the highest index down so each copy lands
|
|
76
|
+
* after its own source. Indexes are de-duplicated first.
|
|
77
|
+
*/
|
|
78
|
+
export declare function createSlidesPaneBulkSlideOps(ops: SlidesPaneSingleSlideOps): SlidesPaneBulkSlideOps;
|
|
79
|
+
//# sourceMappingURL=slides-pane-model.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"slides-pane-model.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/slides-pane-model.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,kBAAkB,EAAE,gBAAgB,EAAE,MAA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GAAG,SAAS,GAClF,IAAI,CAGN;AAED,2FAA2F;AAC3F,MAAM,WAAW,wBAAwB;IACxC,cAAc,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACxC,WAAW,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;IACrC,iBAAiB,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,IAAI,CAAC;CAC3C;AAED,2CAA2C;AAC3C,MAAM,WAAW,sBAAsB;IACtC,eAAe,EAAE,CAAC,OAAO,EAAE,SAAS,MAAM,EAAE,KAAK,IAAI,CAAC;IACtD,YAAY,EAAE,CAAC,OAAO,EAAE,SAAS,MAAM,EAAE,KAAK,IAAI,CAAC;IACnD,gBAAgB,EAAE,CAAC,OAAO,EAAE,SAAS,MAAM,EAAE,KAAK,IAAI,CAAC;CACvD;AAED;;;;;GAKG;AACH,wBAAgB,4BAA4B,CAC3C,GAAG,EAAE,wBAAwB,GAC3B,sBAAsB,CAoBxB"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
export { withCellStyle, withCellText, setCellText, } from 'ooxml-core/pptx/editor/render/table-cell-edit';
|
|
1
|
+
export { getCellText, withCellStyle, withCellText, setCellText, } from 'ooxml-core/pptx/editor/render/table-cell-edit';
|
|
2
2
|
//# sourceMappingURL=table-cell-edit.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"table-cell-edit.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/table-cell-edit.ts"],"names":[],"mappings":"AACA,OAAO,EACN,aAAa,EACb,YAAY,EACZ,WAAW,GACX,MAAM,+CAA+C,CAAC"}
|
|
1
|
+
{"version":3,"file":"table-cell-edit.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/table-cell-edit.ts"],"names":[],"mappings":"AACA,OAAO,EACN,WAAW,EACX,aAAa,EACb,YAAY,EACZ,WAAW,GACX,MAAM,+CAA+C,CAAC"}
|
|
@@ -3,14 +3,35 @@ import type { ParagraphBulletKind } from './bullet-toggle.js';
|
|
|
3
3
|
import type { InlineTextSelection } from './inline-selection-utils.js';
|
|
4
4
|
/** Keep paragraph metadata on the first run when character styling splits it. */
|
|
5
5
|
export declare function restoreParagraphMetadata(original: TextSegment[], updated: TextSegment[]): TextSegment[];
|
|
6
|
+
/**
|
|
7
|
+
* How far a list switch made with a bare caret reaches.
|
|
8
|
+
*
|
|
9
|
+
* - `'paragraph'` (default, PowerPoint): Bullets / Numbering apply to the
|
|
10
|
+
* paragraph holding the caret, exactly as they apply to the paragraphs a
|
|
11
|
+
* range selection touches.
|
|
12
|
+
* - `'list'` (opt-in, Word / Google Docs): switching a list paragraph between
|
|
13
|
+
* bullets and numbering converts the whole list around the caret; see
|
|
14
|
+
* {@link caretListParagraphRange}. Turning a list off, listing a plain
|
|
15
|
+
* paragraph and range selections are unaffected.
|
|
16
|
+
*/
|
|
17
|
+
export type ListConversionScope = 'paragraph' | 'list';
|
|
18
|
+
/** The PowerPoint behaviour, used whenever a host does not choose. */
|
|
19
|
+
export declare const DEFAULT_LIST_CONVERSION_SCOPE: ListConversionScope;
|
|
20
|
+
/** Options shared by the list-style entry points. */
|
|
21
|
+
export interface ListStyleUpdateOptions {
|
|
22
|
+
/** Defaults to {@link DEFAULT_LIST_CONVERSION_SCOPE}. */
|
|
23
|
+
readonly listConversionScope?: ListConversionScope;
|
|
24
|
+
}
|
|
6
25
|
/** Current kind at the first selected paragraph; otherwise the element default. */
|
|
7
26
|
export declare function selectedParagraphBulletKind(element: PptxElement, selection: InlineTextSelection | null): ParagraphBulletKind;
|
|
8
27
|
/**
|
|
9
28
|
* Apply a list request to touched paragraphs, while accompanying character
|
|
10
29
|
* styles retain their existing selection scope. A null selection means the
|
|
11
|
-
* whole element, matching the existing editor contract.
|
|
30
|
+
* whole element, matching the existing editor contract. A bare caret touches
|
|
31
|
+
* its own paragraph, as in PowerPoint, unless `options.listConversionScope` is
|
|
32
|
+
* `'list'` (see {@link ListConversionScope}).
|
|
12
33
|
*/
|
|
13
|
-
export declare function applyListStyleUpdate(element: PptxElement, updates: Partial<TextStyle>, selection: InlineTextSelection | null): {
|
|
34
|
+
export declare function applyListStyleUpdate(element: PptxElement, updates: Partial<TextStyle>, selection: InlineTextSelection | null, options?: ListStyleUpdateOptions): {
|
|
14
35
|
patch: Partial<PptxElement>;
|
|
15
36
|
selection: InlineTextSelection | null;
|
|
16
37
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-list-style-update.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-list-style-update.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"text-list-style-update.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-list-style-update.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,SAAS,EAAE,MAAM,iBAAiB,CAAC;AAU3E,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,iBAAiB,CAAC;AAE3D,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,0BAA0B,CAAC;AA4DpE,iFAAiF;AACjF,wBAAgB,wBAAwB,CACvC,QAAQ,EAAE,WAAW,EAAE,EACvB,OAAO,EAAE,WAAW,EAAE,GACpB,WAAW,EAAE,CAsBf;AAED;;;;;;;;;;GAUG;AACH,MAAM,MAAM,mBAAmB,GAAG,WAAW,GAAG,MAAM,CAAC;AAEvD,sEAAsE;AACtE,eAAO,MAAM,6BAA6B,EAAE,mBAAiC,CAAC;AAE9E,qDAAqD;AACrD,MAAM,WAAW,sBAAsB;IACtC,yDAAyD;IACzD,QAAQ,CAAC,mBAAmB,CAAC,EAAE,mBAAmB,CAAC;CACnD;AAkDD,mFAAmF;AACnF,wBAAgB,2BAA2B,CAC1C,OAAO,EAAE,WAAW,EACpB,SAAS,EAAE,mBAAmB,GAAG,IAAI,GACnC,mBAAmB,CAUrB;AAED;;;;;;GAMG;AACH,wBAAgB,oBAAoB,CACnC,OAAO,EAAE,WAAW,EACpB,OAAO,EAAE,OAAO,CAAC,SAAS,CAAC,EAC3B,SAAS,EAAE,mBAAmB,GAAG,IAAI,EACrC,OAAO,GAAE,sBAA2B,GAClC;IAAE,KAAK,EAAE,OAAO,CAAC,WAAW,CAAC,CAAC;IAAC,SAAS,EAAE,mBAAmB,GAAG,IAAI,CAAA;CAAE,CA4DxE"}
|
|
@@ -1,79 +1,11 @@
|
|
|
1
|
-
/**
|
|
2
|
-
|
|
3
|
-
* decision function every binding maps onto its own nested-span markup.
|
|
4
|
-
*
|
|
5
|
-
* OOXML authors up to four typefaces per run (`a:latin`, `a:ea`, `a:cs`,
|
|
6
|
-
* `a:sym`), and PowerPoint paints each Unicode script category in ITS OWN
|
|
7
|
-
* font, not the run's `a:latin` face. This was React-only
|
|
8
|
-
* (`renderScriptAwareText` in `text-segment-render.tsx`): the other four
|
|
9
|
-
* bindings applied only `a:latin` to the whole run, so CJK, Arabic, Hebrew and
|
|
10
|
-
* Thai text rendered in the wrong typeface (or the browser's serif default)
|
|
11
|
-
* in Vue, Angular, Svelte and Vanilla.
|
|
12
|
-
*
|
|
13
|
-
* `resolveScriptFontSet` resolves the four faces (PANOSE-substituted, with the
|
|
14
|
-
* run falling back to the text body's own declaration); `splitRunByScriptFont`
|
|
15
|
-
* segments a run's text by script and returns, per piece, the CSS a binding
|
|
16
|
-
* spreads onto a nested span. A binding does nothing but map that descriptor:
|
|
17
|
-
* render `text` plain when a piece carries no `style` override, or a nested
|
|
18
|
-
* span with `style` when it does.
|
|
19
|
-
*/
|
|
20
|
-
import type { TextStyle } from 'ooxml-core/pptx';
|
|
1
|
+
/** Per-script span decoration adapter. Font decisions live in core/text. */
|
|
2
|
+
import { type ScriptFontSet } from 'ooxml-core/text';
|
|
21
3
|
import type { RunStyle } from './text-run-style.js';
|
|
22
|
-
|
|
23
|
-
export interface ScriptFontSet {
|
|
24
|
-
latin: string;
|
|
25
|
-
eastAsia: string;
|
|
26
|
-
complexScript: string;
|
|
27
|
-
symbol: string;
|
|
28
|
-
}
|
|
29
|
-
/** The `a:ea` / `a:cs` / `a:sym` typeface + PANOSE fields a run or body may carry. */
|
|
30
|
-
export type ScriptFontFields = Pick<TextStyle, 'eastAsiaFont' | 'complexScriptFont' | 'symbolFont' | 'eastAsiaFontPanose' | 'complexScriptFontPanose' | 'symbolFontPanose'>;
|
|
31
|
-
/**
|
|
32
|
-
* Resolve the four per-script faces for a run.
|
|
33
|
-
*
|
|
34
|
-
* Every entry goes through the SAME PANOSE substitution as the run's own
|
|
35
|
-
* `a:latin`, for two reasons. The obvious one: a bare `a:ea` name emitted on
|
|
36
|
-
* the inner script span overrides the parent's fallback chain, so a deck
|
|
37
|
-
* whose east-Asian font is not installed drops to the browser's default -
|
|
38
|
-
* which for CJK is a serif, where PowerPoint substitutes a sans. The subtle
|
|
39
|
-
* one: {@link hasDistinctScriptFonts} compares by STRING, so leaving `ea` bare
|
|
40
|
-
* while `latin` carries a substitution chain made an identical typeface look
|
|
41
|
-
* distinct and produced a needless nested span in the first place.
|
|
42
|
-
*
|
|
43
|
-
* `runFields` is checked first (`a:rPr > a:ea` etc.), then `blockFields` (the
|
|
44
|
-
* text body's own declaration), matching how a run inherits any property it
|
|
45
|
-
* does not author itself.
|
|
46
|
-
*
|
|
47
|
-
* @param runFields The run's own per-script fields, if it authored any.
|
|
48
|
-
* @param blockFields The text body's per-script fields, as a fallback.
|
|
49
|
-
* @param baseFontFamily The run's already-resolved `a:latin` face (post
|
|
50
|
-
* substitution), used both as the `latin` entry and as
|
|
51
|
-
* the fallback for any script the deck names no font for.
|
|
52
|
-
*/
|
|
53
|
-
export declare function resolveScriptFontSet(runFields: ScriptFontFields | undefined, blockFields: ScriptFontFields | undefined, baseFontFamily: string): ScriptFontSet;
|
|
54
|
-
/** One script-tagged piece of a run's text, ready for a binding's nested span. */
|
|
4
|
+
export { resolveScriptFontSet, type ScriptFontSet, type ScriptFontFields } from 'ooxml-core/text';
|
|
55
5
|
export interface ScriptFontPiece {
|
|
56
6
|
text: string;
|
|
57
|
-
/**
|
|
58
|
-
* CSS for a nested span wrapping `text`, or `undefined` when this piece
|
|
59
|
-
* needs no span at all (its script's font equals the run's own, so plain
|
|
60
|
-
* text renders identically). When present it carries the `fontFamily`
|
|
61
|
-
* override plus the run's own decoration subset, repeated because
|
|
62
|
-
* `text-decoration-*` does not inherit into a nested span (see
|
|
63
|
-
* `nestedTextDecorationStyle`).
|
|
64
|
-
*/
|
|
65
7
|
style?: RunStyle;
|
|
66
8
|
}
|
|
67
|
-
/**
|
|
68
|
-
* Split a run's text into per-script pieces, or `undefined` when it needs no
|
|
69
|
-
* split at all (the common case: `fonts` names no script distinctly from
|
|
70
|
-
* `latin`, so every character already renders in the run's own face).
|
|
71
|
-
*
|
|
72
|
-
* @param text The run's (or one word-piece's) text.
|
|
73
|
-
* @param fonts This run's resolved per-script faces.
|
|
74
|
-
* @param baseFontFamily The run's own `a:latin` face, to compare against.
|
|
75
|
-
* @param nestedDecoration This run's decoration subset, repeated onto any
|
|
76
|
-
* piece that needs a span (see {@link ScriptFontPiece.style}).
|
|
77
|
-
*/
|
|
9
|
+
/** Repeat non-inherited text decorations on each span that changes its font. */
|
|
78
10
|
export declare function splitRunByScriptFont(text: string, fonts: ScriptFontSet, baseFontFamily: string, nestedDecoration?: RunStyle): ScriptFontPiece[] | undefined;
|
|
79
11
|
//# sourceMappingURL=text-script-fonts.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-script-fonts.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-script-fonts.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"text-script-fonts.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-script-fonts.ts"],"names":[],"mappings":"AAAA,4EAA4E;AAC5E,OAAO,EAAiB,KAAK,aAAa,EAAE,MAAM,iBAAiB,CAAC;AACpE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,kBAAkB,CAAC;AACjD,OAAO,EAAE,oBAAoB,EAAE,KAAK,aAAa,EAAE,KAAK,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAElG,MAAM,WAAW,eAAe;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,CAAC,EAAE,QAAQ,CAAC;CACjB;AAED,gFAAgF;AAChF,wBAAgB,oBAAoB,CACnC,IAAI,EAAE,MAAM,EACZ,KAAK,EAAE,aAAa,EACpB,cAAc,EAAE,MAAM,EACtB,gBAAgB,CAAC,EAAE,QAAQ,GACzB,eAAe,EAAE,GAAG,SAAS,CAS/B"}
|
|
@@ -8,6 +8,9 @@
|
|
|
8
8
|
* sizes `S` ({@link LINE_PITCH_EM}, {@link BASELINE_FRACTION}); the 1.2em
|
|
9
9
|
* pitch held for all seven fonts measured (Arial, Times New Roman,
|
|
10
10
|
* Calibri, Georgia, Verdana, Segoe UI, Cambria, each within 0.3%).
|
|
11
|
+
* - With a wrap width (`a:bodyPr/@wrap` other than `none`, see
|
|
12
|
+
* `text-warp-envelope-wrap.ts`), each paragraph is first broken into rows
|
|
13
|
+
* at word boundaries; rows stack exactly like paragraphs do.
|
|
11
14
|
* - Lines are aligned against the widest line, and are NOT each stretched
|
|
12
15
|
* to the box: a short line keeps its natural width inside the block.
|
|
13
16
|
* - The block box is the union of every glyph's INK box vertically, and
|
|
@@ -36,12 +39,18 @@ export interface EnvelopeBlockGlyph {
|
|
|
36
39
|
}
|
|
37
40
|
/** The unwarped block: glyphs per paragraph plus the box the warp normalises by. */
|
|
38
41
|
export interface EnvelopeBlockLayout {
|
|
42
|
+
/** Every paragraph's glyphs, in order (all of its wrapped rows together). */
|
|
39
43
|
lines: EnvelopeBlockGlyph[][];
|
|
44
|
+
/** How many rows each paragraph wrapped into (1 when it did not wrap). */
|
|
45
|
+
rowCounts: number[];
|
|
40
46
|
box: EnvelopeBlockBox | undefined;
|
|
41
47
|
}
|
|
42
48
|
/**
|
|
43
49
|
* Lay out `paragraphs` (each a list of styled runs) unwarped, and measure
|
|
44
50
|
* the block box. The box is `undefined` when nothing on any line has ink.
|
|
51
|
+
* `wrapWidth` (see `envelopeWrapWidth`) breaks each paragraph into rows no
|
|
52
|
+
* wider than it at word boundaries; `undefined` keeps every paragraph on one
|
|
53
|
+
* row.
|
|
45
54
|
*/
|
|
46
|
-
export declare function layoutEnvelopeBlock(paragraphs: EnvelopeSegmentInput[][], align: EnvelopeAlign, getGlyphOutline?: GlyphOutlineLookup): EnvelopeBlockLayout;
|
|
55
|
+
export declare function layoutEnvelopeBlock(paragraphs: EnvelopeSegmentInput[][], align: EnvelopeAlign, getGlyphOutline?: GlyphOutlineLookup, wrapWidth?: number): EnvelopeBlockLayout;
|
|
47
56
|
//# sourceMappingURL=text-warp-envelope-block.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-warp-envelope-block.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-envelope-block.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"text-warp-envelope-block.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-envelope-block.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AACH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,0BAA0B,CAAC;AAMjE,OAAO,KAAK,EACX,aAAa,EACb,gBAAgB,EAChB,oBAAoB,EACpB,kBAAkB,EAClB,MAAM,4BAA4B,CAAC;AACpC,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,2BAA2B,CAAC;AAKrE,gFAAgF;AAChF,eAAO,MAAM,aAAa,MAAM,CAAC;AAUjC,8CAA8C;AAC9C,MAAM,WAAW,kBAAkB;IAClC,IAAI,EAAE,MAAM,CAAC;IACb,YAAY,EAAE,MAAM,CAAC;IACrB,IAAI,EAAE,gBAAgB,CAAC;IACvB,wCAAwC;IACxC,CAAC,EAAE,MAAM,CAAC;IACV,+BAA+B;IAC/B,QAAQ,EAAE,MAAM,CAAC;IACjB,OAAO,EAAE,MAAM,CAAC;IAChB,+DAA+D;IAC/D,OAAO,CAAC,EAAE,mBAAmB,EAAE,CAAC;IAChC,2CAA2C;IAC3C,GAAG,CAAC,EAAE,gBAAgB,CAAC;CACvB;AAED,oFAAoF;AACpF,MAAM,WAAW,mBAAmB;IACnC,6EAA6E;IAC7E,KAAK,EAAE,kBAAkB,EAAE,EAAE,CAAC;IAC9B,0EAA0E;IAC1E,SAAS,EAAE,MAAM,EAAE,CAAC;IACpB,GAAG,EAAE,gBAAgB,GAAG,SAAS,CAAC;CAClC;AAyFD;;;;;;GAMG;AACH,wBAAgB,mBAAmB,CAClC,UAAU,EAAE,oBAAoB,EAAE,EAAE,EACpC,KAAK,EAAE,aAAa,EACpB,eAAe,CAAC,EAAE,kBAAkB,EACpC,SAAS,CAAC,EAAE,MAAM,GAChB,mBAAmB,CAkDrB"}
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { SampledWarpXExtent } from './text-warp-preset-sampler.js';
|
|
1
2
|
/** Presets that carry an independent top/bottom envelope curve. */
|
|
2
3
|
export declare const GLYPH_ENVELOPE_PRESETS: ReadonlySet<string>;
|
|
3
4
|
/** True when `preset` should be rendered with a per-glyph two-curve envelope. */
|
|
@@ -14,6 +15,13 @@ export interface EnvelopeCurveFractions {
|
|
|
14
15
|
* Returns `undefined` for a preset outside {@link GLYPH_ENVELOPE_PRESETS}.
|
|
15
16
|
*/
|
|
16
17
|
export declare function envelopeCurveAt(preset: string, u: number, adj?: number, adj2?: number): EnvelopeCurveFractions | undefined;
|
|
18
|
+
/**
|
|
19
|
+
* Where the top and bottom envelope curves start and end horizontally, each a
|
|
20
|
+
* `[start, end]` fraction of box width. The full width for every preset
|
|
21
|
+
* except `textPlain` away from its default `adj`, and for a preset outside
|
|
22
|
+
* {@link GLYPH_ENVELOPE_PRESETS}.
|
|
23
|
+
*/
|
|
24
|
+
export declare function envelopeCurveXExtent(preset: string, adj?: number, adj2?: number): SampledWarpXExtent;
|
|
17
25
|
/** The undeformed band, exported so layout code can compute a stable scale=1 baseline. */
|
|
18
26
|
export declare const NOMINAL_ENVELOPE_BAND: EnvelopeCurveFractions;
|
|
19
27
|
//# sourceMappingURL=text-warp-envelope-curves.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-warp-envelope-curves.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-envelope-curves.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"text-warp-envelope-curves.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-envelope-curves.ts"],"names":[],"mappings":"AAsCA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,4BAA4B,CAAC;AAErE,mEAAmE;AACnE,eAAO,MAAM,sBAAsB,EAAE,WAAW,CAAC,MAAM,CAarD,CAAC;AAEH,iFAAiF;AACjF,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,OAAO,CAEpE;AAsCD,yEAAyE;AACzE,MAAM,WAAW,sBAAsB;IACtC,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;CACf;AAED;;;;;GAKG;AACH,wBAAgB,eAAe,CAC9B,MAAM,EAAE,MAAM,EACd,CAAC,EAAE,MAAM,EACT,GAAG,CAAC,EAAE,MAAM,EACZ,IAAI,CAAC,EAAE,MAAM,GACX,sBAAsB,GAAG,SAAS,CAyEpC;AAcD;;;;;GAKG;AACH,wBAAgB,oBAAoB,CACnC,MAAM,EAAE,MAAM,EACd,GAAG,CAAC,EAAE,MAAM,EACZ,IAAI,CAAC,EAAE,MAAM,GACX,kBAAkB,CAOpB;AAED,0FAA0F;AAC1F,eAAO,MAAM,qBAAqB,EAAE,sBAGnC,CAAC"}
|
|
@@ -1,17 +1,23 @@
|
|
|
1
1
|
import { measureGlyphAdvances, resetGlyphEnvelopeMeasureCache } from './text-warp-envelope-measure.js';
|
|
2
2
|
import type { EnvelopeAlign, EnvelopeGlyphPlacement, EnvelopeSegmentInput, GlyphOutlineLookup } from './text-warp-envelope-types.js';
|
|
3
|
+
import type { EnvelopeTextBody } from './text-warp-envelope-wrap.js';
|
|
3
4
|
export type { EnvelopeAlign, EnvelopeFontSpec, EnvelopeGlyphPlacement, EnvelopeSegmentInput, GlyphOutlineLookup, GlyphOutlineLookupFont, } from './text-warp-envelope-types.js';
|
|
4
5
|
export { measureGlyphAdvances, resetGlyphEnvelopeMeasureCache };
|
|
5
6
|
/**
|
|
6
7
|
* Build every paragraph's glyph placements for one envelope-warped text
|
|
7
8
|
* block in a `width` x `height` shape box. Returns one array per paragraph
|
|
8
9
|
* (in order), each empty when the preset is outside the envelope family, the
|
|
9
|
-
* box is degenerate, or the block has no ink at all.
|
|
10
|
+
* box is degenerate, or the block has no ink at all. A paragraph that wraps
|
|
11
|
+
* still returns one array, holding all of its rows' glyphs.
|
|
12
|
+
*
|
|
13
|
+
* `textBody` is the element's text style (its `a:bodyPr` insets and `wrap`):
|
|
14
|
+
* with it, paragraphs wrap at `width` less the insets before the warp, unless
|
|
15
|
+
* it says `wrap="none"`. Without it nothing wraps.
|
|
10
16
|
*/
|
|
11
|
-
export declare function buildGlyphEnvelopeBlock(preset: string, paragraphs: EnvelopeSegmentInput[][], width: number, height: number, align: EnvelopeAlign, adj?: number, adj2?: number, getGlyphOutline?: GlyphOutlineLookup): EnvelopeGlyphPlacement[][];
|
|
17
|
+
export declare function buildGlyphEnvelopeBlock(preset: string, paragraphs: EnvelopeSegmentInput[][], width: number, height: number, align: EnvelopeAlign, adj?: number, adj2?: number, getGlyphOutline?: GlyphOutlineLookup, textBody?: EnvelopeTextBody): EnvelopeGlyphPlacement[][];
|
|
12
18
|
/**
|
|
13
19
|
* Single-paragraph convenience wrapper around {@link buildGlyphEnvelopeBlock}:
|
|
14
20
|
* the placements for a block that consists of `segments` alone.
|
|
15
21
|
*/
|
|
16
|
-
export declare function buildGlyphEnvelope(preset: string, segments: EnvelopeSegmentInput[], width: number, height: number, align: EnvelopeAlign, adj?: number, adj2?: number, getGlyphOutline?: GlyphOutlineLookup): EnvelopeGlyphPlacement[];
|
|
22
|
+
export declare function buildGlyphEnvelope(preset: string, segments: EnvelopeSegmentInput[], width: number, height: number, align: EnvelopeAlign, adj?: number, adj2?: number, getGlyphOutline?: GlyphOutlineLookup, textBody?: EnvelopeTextBody): EnvelopeGlyphPlacement[];
|
|
17
23
|
//# sourceMappingURL=text-warp-envelope-layout.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-warp-envelope-layout.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-envelope-layout.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"text-warp-envelope-layout.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-envelope-layout.ts"],"names":[],"mappings":"AAgCA,OAAO,EAEN,oBAAoB,EACpB,8BAA8B,EAC9B,MAAM,8BAA8B,CAAC;AACtC,OAAO,KAAK,EACX,aAAa,EACb,sBAAsB,EACtB,oBAAoB,EACpB,kBAAkB,EAClB,MAAM,4BAA4B,CAAC;AAIpC,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAElE,YAAY,EACX,aAAa,EACb,gBAAgB,EAChB,sBAAsB,EACtB,oBAAoB,EACpB,kBAAkB,EAClB,sBAAsB,GACtB,MAAM,4BAA4B,CAAC;AAIpC,OAAO,EAAE,oBAAoB,EAAE,8BAA8B,EAAE,CAAC;AAuChE;;;;;;;;;;GAUG;AACH,wBAAgB,uBAAuB,CACtC,MAAM,EAAE,MAAM,EACd,UAAU,EAAE,oBAAoB,EAAE,EAAE,EACpC,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,EACd,KAAK,EAAE,aAAa,EACpB,GAAG,CAAC,EAAE,MAAM,EACZ,IAAI,CAAC,EAAE,MAAM,EACb,eAAe,CAAC,EAAE,kBAAkB,EACpC,QAAQ,CAAC,EAAE,gBAAgB,GACzB,sBAAsB,EAAE,EAAE,CAsB5B;AAED;;;GAGG;AACH,wBAAgB,kBAAkB,CACjC,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,oBAAoB,EAAE,EAChC,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,EACd,KAAK,EAAE,aAAa,EACpB,GAAG,CAAC,EAAE,MAAM,EACZ,IAAI,CAAC,EAAE,MAAM,EACb,eAAe,CAAC,EAAE,kBAAkB,EACpC,QAAQ,CAAC,EAAE,gBAAgB,GACzB,sBAAsB,EAAE,CAc1B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-warp-envelope-map.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-envelope-map.ts"],"names":[],"mappings":"AAsCA,qEAAqE;AACrE,MAAM,WAAW,gBAAgB;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CACf;AAED,+DAA+D;AAC/D,MAAM,WAAW,YAAY;IAC5B,GAAG,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG;QAAE,CAAC,EAAE,MAAM,CAAC;QAAC,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;CACpD;
|
|
1
|
+
{"version":3,"file":"text-warp-envelope-map.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-envelope-map.ts"],"names":[],"mappings":"AAsCA,qEAAqE;AACrE,MAAM,WAAW,gBAAgB;IAChC,IAAI,EAAE,MAAM,CAAC;IACb,GAAG,EAAE,MAAM,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CACf;AAED,+DAA+D;AAC/D,MAAM,WAAW,YAAY;IAC5B,GAAG,CAAC,CAAC,EAAE,MAAM,EAAE,CAAC,EAAE,MAAM,GAAG;QAAE,CAAC,EAAE,MAAM,CAAC;QAAC,CAAC,EAAE,MAAM,CAAA;KAAE,CAAC;CACpD;AAyDD;;;;GAIG;AACH,wBAAgB,kBAAkB,CACjC,MAAM,EAAE,MAAM,EACd,KAAK,EAAE,MAAM,EACb,MAAM,EAAE,MAAM,EACd,GAAG,EAAE,MAAM,GAAG,SAAS,EACvB,IAAI,EAAE,MAAM,GAAG,SAAS,EACxB,KAAK,EAAE,gBAAgB,GACrB,YAAY,GAAG,SAAS,CA4B1B"}
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
import type { EnvelopeSegmentInput } from './text-warp-envelope-types.js';
|
|
2
|
+
/** The `a:bodyPr` properties that decide whether, and how wide, the block wraps. */
|
|
3
|
+
export interface EnvelopeTextBody {
|
|
4
|
+
/** Left inset in px (`a:bodyPr/@lIns`); the OOXML default when absent. */
|
|
5
|
+
bodyInsetLeft?: number;
|
|
6
|
+
/** Right inset in px (`a:bodyPr/@rIns`); the OOXML default when absent. */
|
|
7
|
+
bodyInsetRight?: number;
|
|
8
|
+
/** `a:bodyPr/@wrap`: `'none'` keeps each paragraph on one row. */
|
|
9
|
+
textWrap?: string;
|
|
10
|
+
}
|
|
11
|
+
/** One character of a paragraph with the run it came from and its advance. */
|
|
12
|
+
export interface EnvelopeWrapItem {
|
|
13
|
+
seg: EnvelopeSegmentInput;
|
|
14
|
+
char: string;
|
|
15
|
+
advance: number;
|
|
16
|
+
}
|
|
17
|
+
/**
|
|
18
|
+
* The width a `boxWidth`-wide shape wraps its text at: the box less its left
|
|
19
|
+
* and right insets, or `undefined` (no wrapping) when `body` is absent or
|
|
20
|
+
* says `wrap="none"`.
|
|
21
|
+
*/
|
|
22
|
+
export declare function envelopeWrapWidth(boxWidth: number, body: EnvelopeTextBody | undefined): number | undefined;
|
|
23
|
+
/**
|
|
24
|
+
* Break one paragraph's characters into rows no wider than `maxWidth`
|
|
25
|
+
* (see the module comment). With `maxWidth` `undefined` the paragraph stays
|
|
26
|
+
* one row, unchanged.
|
|
27
|
+
*/
|
|
28
|
+
export declare function wrapEnvelopeParagraph(items: EnvelopeWrapItem[], maxWidth: number | undefined): EnvelopeWrapItem[][];
|
|
29
|
+
//# sourceMappingURL=text-warp-envelope-wrap.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"text-warp-envelope-wrap.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-envelope-wrap.ts"],"names":[],"mappings":"AAeA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,4BAA4B,CAAC;AAEvE,oFAAoF;AACpF,MAAM,WAAW,gBAAgB;IAChC,0EAA0E;IAC1E,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,2EAA2E;IAC3E,cAAc,CAAC,EAAE,MAAM,CAAC;IACxB,kEAAkE;IAClE,QAAQ,CAAC,EAAE,MAAM,CAAC;CAClB;AAED,8EAA8E;AAC9E,MAAM,WAAW,gBAAgB;IAChC,GAAG,EAAE,oBAAoB,CAAC;IAC1B,IAAI,EAAE,MAAM,CAAC;IACb,OAAO,EAAE,MAAM,CAAC;CAChB;AAWD;;;;GAIG;AACH,wBAAgB,iBAAiB,CAChC,QAAQ,EAAE,MAAM,EAChB,IAAI,EAAE,gBAAgB,GAAG,SAAS,GAChC,MAAM,GAAG,SAAS,CAOpB;AA6CD;;;;GAIG;AACH,wBAAgB,qBAAqB,CACpC,KAAK,EAAE,gBAAgB,EAAE,EACzB,QAAQ,EAAE,MAAM,GAAG,SAAS,GAC1B,gBAAgB,EAAE,EAAE,CAgBtB"}
|
|
@@ -67,12 +67,25 @@ export type WarpCurveSegment = {
|
|
|
67
67
|
readonly stAng: string;
|
|
68
68
|
readonly swAng: string;
|
|
69
69
|
};
|
|
70
|
+
/** Guide names for where a path starts and ends horizontally. */
|
|
71
|
+
export interface WarpCurveXExtent {
|
|
72
|
+
readonly startX: string;
|
|
73
|
+
readonly endX: string;
|
|
74
|
+
}
|
|
70
75
|
/** One preset's transcribed guide list plus its top/bottom curve segments. */
|
|
71
76
|
export interface WarpPresetDefinition {
|
|
72
77
|
readonly defaultAdj: number;
|
|
73
78
|
readonly gdLst: readonly GeometryGuide[];
|
|
74
79
|
readonly top: WarpCurveSegment;
|
|
75
80
|
readonly bottom: WarpCurveSegment;
|
|
81
|
+
/**
|
|
82
|
+
* Horizontal extent of the top path, for a preset whose path does not run
|
|
83
|
+
* from `l` to `r` (`textPlain` away from its default `adj`). Omitted means
|
|
84
|
+
* the full width.
|
|
85
|
+
*/
|
|
86
|
+
readonly topX?: WarpCurveXExtent;
|
|
87
|
+
/** Horizontal extent of the bottom path; see {@link topX}. */
|
|
88
|
+
readonly bottomX?: WarpCurveXExtent;
|
|
76
89
|
}
|
|
77
90
|
/** Spec-transcribed definitions, keyed by `prstTxWarp` preset name. */
|
|
78
91
|
export declare const WARP_PRESET_DEFINITIONS: Readonly<Record<string, WarpPresetDefinition>>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-warp-preset-definitions.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-preset-definitions.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA0CG;AACH,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AAErD,2FAA2F;AAC3F,MAAM,MAAM,gBAAgB,GACzB;IAAE,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IAAC,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAA;CAAE,GACzE;IACA,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;CACrB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B,EAAE,QAAQ,CAAC,MAAM,CAAC,MAAM,EAAE,oBAAoB,CAAC,CA0KlF,CAAC"}
|
|
@@ -10,6 +10,18 @@ export interface SampledWarpCurve {
|
|
|
10
10
|
* fall back to a reconstruction in that case).
|
|
11
11
|
*/
|
|
12
12
|
export declare function sampleWarpPresetCurve(preset: string, u: number, adj: number | undefined, adj2: number | undefined): SampledWarpCurve | undefined;
|
|
13
|
+
/** Where the top and bottom paths start and end, each a `[start, end]` fraction of box width. */
|
|
14
|
+
export interface SampledWarpXExtent {
|
|
15
|
+
top: readonly [number, number];
|
|
16
|
+
bottom: readonly [number, number];
|
|
17
|
+
}
|
|
18
|
+
/**
|
|
19
|
+
* The horizontal extent of `preset`'s top and bottom paths. Every path spans
|
|
20
|
+
* the full width except where a definition says otherwise (`textPlain` away
|
|
21
|
+
* from its default `adj`). Returns `undefined` when `preset` has no
|
|
22
|
+
* transcribed definition.
|
|
23
|
+
*/
|
|
24
|
+
export declare function sampleWarpPresetXExtent(preset: string, adj: number | undefined, adj2: number | undefined): SampledWarpXExtent | undefined;
|
|
13
25
|
/** Preset names with a spec-transcribed definition (exported for tests/tooling). */
|
|
14
26
|
export declare function hasWarpPresetDefinition(preset: string): boolean;
|
|
15
27
|
//# sourceMappingURL=text-warp-preset-sampler.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-warp-preset-sampler.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-preset-sampler.ts"],"names":[],"mappings":"AA6IA,qFAAqF;AACrF,MAAM,WAAW,gBAAgB;IAChC,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;CACf;AAED;;;;;GAKG;AACH,wBAAgB,qBAAqB,CACpC,MAAM,EAAE,MAAM,EACd,CAAC,EAAE,MAAM,EACT,GAAG,EAAE,MAAM,GAAG,SAAS,EACvB,IAAI,EAAE,MAAM,GAAG,SAAS,GACtB,gBAAgB,GAAG,SAAS,CAe9B;AAED,oFAAoF;AACpF,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAE/D"}
|
|
1
|
+
{"version":3,"file":"text-warp-preset-sampler.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp-preset-sampler.ts"],"names":[],"mappings":"AA6IA,qFAAqF;AACrF,MAAM,WAAW,gBAAgB;IAChC,GAAG,EAAE,MAAM,CAAC;IACZ,MAAM,EAAE,MAAM,CAAC;CACf;AAED;;;;;GAKG;AACH,wBAAgB,qBAAqB,CACpC,MAAM,EAAE,MAAM,EACd,CAAC,EAAE,MAAM,EACT,GAAG,EAAE,MAAM,GAAG,SAAS,EACvB,IAAI,EAAE,MAAM,GAAG,SAAS,GACtB,gBAAgB,GAAG,SAAS,CAe9B;AAED,iGAAiG;AACjG,MAAM,WAAW,kBAAkB;IAClC,GAAG,EAAE,SAAS,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IAC/B,MAAM,EAAE,SAAS,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;CAClC;AAmBD;;;;;GAKG;AACH,wBAAgB,uBAAuB,CACtC,MAAM,EAAE,MAAM,EACd,GAAG,EAAE,MAAM,GAAG,SAAS,EACvB,IAAI,EAAE,MAAM,GAAG,SAAS,GACtB,kBAAkB,GAAG,SAAS,CAchC;AAED,oFAAoF;AACpF,wBAAgB,uBAAuB,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAE/D"}
|
|
@@ -16,12 +16,13 @@ import type { PptxElement, PptxTextWarpPreset, TextSegment } from 'ooxml-core/pp
|
|
|
16
16
|
* Rendering-strategy category for a warp preset.
|
|
17
17
|
* - `path`: renders along an SVG `<textPath>` (arcs, waves, circles,
|
|
18
18
|
* slant/fade/cascade, …)
|
|
19
|
-
* - `envelope`:
|
|
19
|
+
* - `envelope`: the text block stretched between a top and a bottom curve
|
|
20
|
+
* (plain/inflate/deflate/can). Also
|
|
20
21
|
* renders along an SVG `<textPath>`; kept as its own category
|
|
21
22
|
* for documentation/grouping only (see {@link ENVELOPE_PRESETS}).
|
|
22
23
|
* - `simple`: unused (kept for API stability; no preset classifies here
|
|
23
24
|
* any more, see {@link SIMPLE_PRESETS}).
|
|
24
|
-
* - `none`: no warp (`textNoShape`,
|
|
25
|
+
* - `none`: no warp (`textNoShape`, unknown)
|
|
25
26
|
*
|
|
26
27
|
* Every classified preset (`path` and `envelope` alike) should be routed to
|
|
27
28
|
* SVG `<textPath>` rendering via {@link shouldUseSvgWarp}; a binding that
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"text-warp.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,kBAAkB,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAOpF
|
|
1
|
+
{"version":3,"file":"text-warp.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/text-warp.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;GAYG;AACH,OAAO,KAAK,EAAE,WAAW,EAAE,kBAAkB,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAC;AAOpF;;;;;;;;;;;;;;;;;GAiBG;AACH,MAAM,MAAM,YAAY,GAAG,MAAM,GAAG,UAAU,GAAG,QAAQ,GAAG,MAAM,CAAC;AA6EnE;;;;;GAKG;AACH,wBAAgB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,SAAS,GAAG,YAAY,CAczE;AAED,qDAAqD;AACrD,eAAO,MAAM,sBAAsB,EAAE,WAAW,CAAC,MAAM,CAKrD,CAAC;AAIH,8EAA8E;AAC9E,MAAM,WAAW,aAAa;IAC7B,+EAA+E;IAC/E,QAAQ,EAAE,WAAW,EAAE,CAAC;CACxB;AAED,+DAA+D;AAC/D,MAAM,WAAW,cAAc;IAC9B,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,YAAY,CAAC,EAAE,WAAW,EAAE,CAAC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AAE,MAAM,EACjB,SAAS,EAAE,MAAM,EACjB,GAAG,CAAC,EAAE,MAAM,EACZ,IAAI,CAAC,EAAE,MAAM,GACX,MAAM,CAQR;AAED;;;;GAIG;AACH,eAAO,MAAM,WAAW,sBAAgB,CAAC;AAIzC;;;;;;;;;GASG;AACH,MAAM,WAAW,gBAAgB;IAChC,iCAAiC;IACjC,SAAS,EAAE,MAAM,CAAC;IAClB,wCAAwC;IACxC,eAAe,EAAE,MAAM,CAAC;CACxB;AAmBD;;;;;;;;;;;GAWG;AACH,wBAAgB,uBAAuB,CACtC,MAAM,EAAE,MAAM,EACd,IAAI,CAAC,EAAE,MAAM,EACb,IAAI,CAAC,EAAE,MAAM,GACX,gBAAgB,GAAG,SAAS,CA8D9B;AAcD;;;;;;;;;GASG;AACH,wBAAgB,qBAAqB,CAAC,MAAM,EAAE,MAAM,EAAE,IAAI,CAAC,EAAE,MAAM,GAAG,gBAAgB,GAAG,SAAS,CA+CjG;AAED;;;;;;;;;;;GAWG;AACH,wBAAgB,mBAAmB,CAClC,MAAM,EAAE,kBAAkB,GAAG,MAAM,GAAG,SAAS,EAC/C,GAAG,CAAC,EAAE,MAAM,EACZ,IAAI,CAAC,EAAE,MAAM,GACX,gBAAgB,GAAG,SAAS,CAS9B"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"viewer-props-manifest.d.ts","sourceRoot":"","sources":["../../../src/pptx/render/viewer-props-manifest.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,eAAO,MAAM,eAAe,YAAI,OAAO,EAAE,KAAK,EAAE,SAAS,EAAE,QAAQ,EAAE,SAAS,CAAU,CAAC;AACzF,MAAM,MAAM,aAAa,GAAG,CAAC,OAAO,eAAe,CAAC,CAAC,MAAM,CAAC,CAAC;AAE7D,MAAM,WAAW,kBAAkB;IAClC,+CAA+C;IAC/C,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,yEAAyE;IACzE,QAAQ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AkF;AAClF,wBAAgB,eAAe,CAAC,KAAK,EAAE,kBAAkB,EAAE,OAAO,EAAE,aAAa,GAAG,MAAM,CAgBzF;AAED,MAAM,WAAW,kBAAkB;IAClC,OAAO,EAAE,aAAa,CAAC;IACvB,IAAI,EAAE,MAAM,GAAG,OAAO,CAAC;IACvB,sEAAsE;IACtE,OAAO,EAAE,MAAM,CAAC;CAChB;AAED,0FAA0F;AAC1F,MAAM,WAAW,gBAAgB;IAChC,KAAK,EAAE,SAAS,MAAM,EAAE,CAAC;IACzB,MAAM,EAAE,SAAS,MAAM,EAAE,CAAC;CAC1B;AA4CD,8FAA8F;AAC9F,wBAAgB,iBAAiB,CAChC,SAAS,EAAE,QAAQ,CAAC,MAAM,CAAC,aAAa,EAAE,gBAAgB,CAAC,CAAC,GAC1D,kBAAkB,EAAE,CAKtB"}
|
package/dist/pptx/{smartart-insert-preview-SKFD7NCQ.mjs → smartart-insert-preview-RQUFRLSV.mjs}
RENAMED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { buildSmartArtInsertPreview } from './chunk-
|
|
2
|
-
import './chunk-
|
|
1
|
+
export { buildSmartArtInsertPreview } from './chunk-7DT3UJQB.mjs';
|
|
2
|
+
import './chunk-CH4Z6H6C.mjs';
|
|
3
3
|
import './chunk-RQJOOXRG.mjs';
|
|
4
4
|
import './chunk-7BHPBO2O.mjs';
|
|
5
5
|
import './chunk-A63ASSCH.mjs';
|
|
@@ -8,21 +8,21 @@ import './chunk-WSR2S2MY.mjs';
|
|
|
8
8
|
import './chunk-GVH4QN7R.mjs';
|
|
9
9
|
import './chunk-6B3UUVRS.mjs';
|
|
10
10
|
import './chunk-APQ3OOAT.mjs';
|
|
11
|
-
import './chunk-
|
|
12
|
-
import './chunk-
|
|
11
|
+
import './chunk-SPOECCPV.mjs';
|
|
12
|
+
import './chunk-DACFW5LO.mjs';
|
|
13
13
|
import './chunk-PI47Z46K.mjs';
|
|
14
|
-
import './chunk-
|
|
14
|
+
import './chunk-PTIGQSTY.mjs';
|
|
15
15
|
import './chunk-67L75M6K.mjs';
|
|
16
|
-
import './chunk-
|
|
16
|
+
import './chunk-7FXQHSPE.mjs';
|
|
17
17
|
import './chunk-L55MIOBC.mjs';
|
|
18
18
|
import './chunk-FUKVYJPM.mjs';
|
|
19
19
|
import './chunk-SMSCEGAE.mjs';
|
|
20
20
|
import './chunk-T7FRLIDM.mjs';
|
|
21
|
-
import './chunk-
|
|
21
|
+
import './chunk-RZVEPTLN.mjs';
|
|
22
22
|
import './chunk-IB6ZM2E2.mjs';
|
|
23
23
|
import './chunk-JA7WYSRE.mjs';
|
|
24
24
|
import './chunk-V4YMLIGL.mjs';
|
|
25
|
-
import './chunk-
|
|
25
|
+
import './chunk-LCCRLB7Q.mjs';
|
|
26
26
|
import './chunk-2V5ATMMB.mjs';
|
|
27
27
|
import './chunk-A62C6PSL.mjs';
|
|
28
28
|
import './chunk-5VSUIPDX.mjs';
|
|
@@ -34,6 +34,6 @@ import './chunk-PMURSMHH.mjs';
|
|
|
34
34
|
import './chunk-MK2ASJSY.mjs';
|
|
35
35
|
import './chunk-AEQGGKRZ.mjs';
|
|
36
36
|
import './chunk-6MEBLCNK.mjs';
|
|
37
|
-
import './chunk-
|
|
37
|
+
import './chunk-PM2SOLK3.mjs';
|
|
38
38
|
import './chunk-PEDGPFLR.mjs';
|
|
39
39
|
import './chunk-7JBQPQ6G.mjs';
|