ooxml-core 1.47.0 → 1.48.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/PptxHandler-6UQWMUVU.cjs +14 -0
- package/dist/{PptxHandler-NXHZ6ITL.mjs → PptxHandler-PLSH2BAS.mjs} +2 -2
- package/dist/PptxHandler-QLKZVYCG.mjs +5 -0
- package/dist/{PresentationBuilder-URSPID7L.mjs → PresentationBuilder-3QXOJNRO.mjs} +2 -2
- package/dist/{PresentationBuilder-IK6NIK6T.cjs → PresentationBuilder-CRBFFHNW.cjs} +6 -6
- package/dist/{PresentationBuilder-LHQ333UL.mjs → PresentationBuilder-DQ3XFU4R.mjs} +3 -3
- package/dist/{chunk-QHR726W3.mjs → chunk-32K7JG2Z.mjs} +1 -1
- package/dist/{chunk-APCA7N6Q.cjs → chunk-7RCBSNXT.cjs} +3 -3
- package/dist/{chunk-6MU4WKHS.mjs → chunk-CXIDPUT6.mjs} +1 -1
- package/dist/{chunk-553WFEHD.mjs → chunk-EKEE6BTU.mjs} +638 -50
- package/dist/{chunk-XVEJS7HN.mjs → chunk-IKFTITJ7.mjs} +4 -4
- package/dist/{chunk-7L6ZAA5Y.mjs → chunk-K5G6MV37.mjs} +2 -2
- package/dist/{chunk-4GPLQEEC.cjs → chunk-RRA262A6.cjs} +1926 -1326
- package/dist/{chunk-5HNRZOBX.mjs → chunk-WAYEYX4G.mjs} +1 -1
- package/dist/{chunk-Z734BYYR.mjs → chunk-WLKOLTBH.mjs} +653 -53
- package/dist/pptx/automation/index.cjs +45094 -44442
- package/dist/pptx/automation/index.d.ts +5 -12
- package/dist/pptx/automation/index.d.ts.map +1 -1
- package/dist/pptx/automation/index.mjs +5 -5
- package/dist/pptx/automation/schemas/chart-formatting-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/chart-formatting-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/chart-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/chart-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/chart-user-shape-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/chart-user-shape-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/element-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/element-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/export-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/export-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/geometry-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/geometry-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/hyperlink-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/hyperlink-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/index.d.ts +8 -8
- package/dist/pptx/automation/schemas/index.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/json-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/json-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/layout-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/layout-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/lock-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/lock-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/metadata-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/metadata-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/ole-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/ole-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/presentation-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/presentation-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/section-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/section-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/slide-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/slide-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/smartart-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/smartart-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/table-style-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/table-style-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/template-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/template-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/theme-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/theme-schemas.d.ts.map +1 -1
- package/dist/pptx/automation/schemas/validation-schemas.d.ts +1 -1
- package/dist/pptx/automation/schemas/validation-schemas.d.ts.map +1 -1
- package/dist/pptx/chunks/color-primitives-DHyz14D9.d.ts +151 -0
- package/dist/pptx/chunks/color-primitives-DHyz14D9.d.ts.map +1 -0
- package/dist/pptx/chunks/{index--HBUyILF.d.ts → index-7tA9HqRL.d.ts} +10060 -1223
- package/dist/pptx/chunks/index-7tA9HqRL.d.ts.map +1 -0
- package/dist/pptx/chunks/{index-Dr3iIPt9.d.ts → index-CAzt1jbx.d.ts} +4 -5
- package/dist/pptx/chunks/index-CAzt1jbx.d.ts.map +1 -0
- package/dist/pptx/chunks/{schemas-LHsDbVOw.d.ts → index-CyAgQ2zG.d.ts} +6 -2
- package/dist/pptx/chunks/index-CyAgQ2zG.d.ts.map +1 -0
- package/dist/pptx/chunks/index-cJSPBkU1.d.ts +185 -0
- package/dist/pptx/chunks/index-cJSPBkU1.d.ts.map +1 -0
- package/dist/pptx/chunks/index-cr_sgz1w.d.ts +94 -0
- package/dist/pptx/chunks/index-cr_sgz1w.d.ts.map +1 -0
- package/dist/pptx/chunks/presentation-Be108jrz.d.ts +12521 -0
- package/dist/pptx/chunks/presentation-Be108jrz.d.ts.map +1 -0
- package/dist/pptx/chunks/{inspection-status-TKac7eqb.d.ts → signature-inspection-status-TKac7eqb.d.ts} +1 -1
- package/dist/pptx/chunks/signature-inspection-status-TKac7eqb.d.ts.map +1 -0
- package/dist/pptx/chunks/text-operations-a1cqBYk9.d.ts +111 -0
- package/dist/pptx/chunks/text-operations-a1cqBYk9.d.ts.map +1 -0
- package/dist/pptx/cli/index.cjs +746 -94
- package/dist/pptx/cli/index.d.ts +17 -1
- package/dist/pptx/cli/index.d.ts.map +1 -1
- package/dist/pptx/cli/index.mjs +4 -4
- package/dist/pptx/converter/index.d.ts +1 -1
- package/dist/pptx/converter/index.mjs +2 -2
- package/dist/pptx/editor/ai/table-merge.d.ts +16 -0
- package/dist/pptx/editor/ai/table-merge.d.ts.map +1 -1
- package/dist/pptx/editor/loader/element-patch-walker.d.ts +15 -0
- package/dist/pptx/editor/loader/element-patch-walker.d.ts.map +1 -1
- package/dist/pptx/editor/loader/lazy-image-resolution.d.ts +15 -0
- package/dist/pptx/editor/loader/lazy-image-resolution.d.ts.map +1 -1
- package/dist/pptx/editor/loader/load-content-helpers.d.ts +7 -0
- package/dist/pptx/editor/loader/load-content-helpers.d.ts.map +1 -1
- package/dist/pptx/editor/loader/table-style-image-paths.d.ts +20 -0
- package/dist/pptx/editor/loader/table-style-image-paths.d.ts.map +1 -1
- package/dist/pptx/editor/loader/text-fill-image-paths.d.ts +19 -0
- package/dist/pptx/editor/loader/text-fill-image-paths.d.ts.map +1 -1
- package/dist/pptx/editor/render/bullet-autonum.d.ts +14 -0
- package/dist/pptx/editor/render/bullet-list.d.ts +8 -0
- package/dist/pptx/editor/render/bullet-list.d.ts.map +1 -1
- package/dist/pptx/editor/render/bullet-toggle.d.ts +4 -0
- package/dist/pptx/editor/render/bullet-toggle.d.ts.map +1 -1
- package/dist/pptx/editor/render/chart-user-shape-edit.d.ts +12 -0
- package/dist/pptx/editor/render/chart-user-shape-edit.d.ts.map +1 -1
- package/dist/pptx/editor/render/clone.d.ts +20 -0
- package/dist/pptx/editor/render/clone.d.ts.map +1 -1
- package/dist/pptx/editor/render/collaboration-assets.d.ts +17 -0
- package/dist/pptx/editor/render/collaboration-live-patch-target.d.ts +9 -0
- package/dist/pptx/editor/render/collaboration-live-patch-target.d.ts.map +1 -1
- package/dist/pptx/editor/render/collaboration-reconcile.d.ts +21 -0
- package/dist/pptx/editor/render/collaboration-reconcile.d.ts.map +1 -1
- package/dist/pptx/editor/render/collaboration-sync.d.ts +32 -4
- package/dist/pptx/editor/render/collaboration-sync.d.ts.map +1 -1
- package/dist/pptx/editor/render/collaboration-text-codec.d.ts +33 -2
- package/dist/pptx/editor/render/collaboration-text-codec.d.ts.map +1 -0
- package/dist/pptx/editor/render/collaboration-text-merge.d.ts +36 -2
- package/dist/pptx/editor/render/collaboration-text-merge.d.ts.map +1 -0
- package/dist/pptx/editor/render/collaboration-text-native-edit.d.ts +2 -2
- package/dist/pptx/editor/render/collaboration-text-positions.d.ts +34 -2
- package/dist/pptx/editor/render/collaboration-text-positions.d.ts.map +1 -0
- package/dist/pptx/editor/render/collaboration-text-projection.d.ts +1 -1
- package/dist/pptx/editor/render/collaboration-text-session-apply.d.ts +3 -3
- package/dist/pptx/editor/render/collaboration-text-session-delta.d.ts +36 -2
- package/dist/pptx/editor/render/collaboration-text-session-delta.d.ts.map +1 -0
- package/dist/pptx/editor/render/collaboration-text-session-paragraph.d.ts +1 -1
- package/dist/pptx/editor/render/collaboration-text-session.d.ts +40 -2
- package/dist/pptx/editor/render/collaboration-text-session.d.ts.map +1 -0
- package/dist/pptx/editor/render/collaboration-text-snapshot-positions.d.ts +2 -2
- package/dist/pptx/editor/render/custom-show-operations.cjs +2 -2
- package/dist/pptx/editor/render/custom-show-operations.d.ts +14 -0
- package/dist/pptx/editor/render/custom-show-operations.d.ts.map +1 -1
- package/dist/pptx/editor/render/custom-show-operations.mjs +1 -1
- package/dist/pptx/editor/render/deck-save-encryption.d.ts +24 -0
- package/dist/pptx/editor/render/deck-save-encryption.d.ts.map +1 -1
- package/dist/pptx/editor/render/element-locks.d.ts +25 -0
- package/dist/pptx/editor/render/element-locks.d.ts.map +1 -1
- package/dist/pptx/editor/render/element-operations.d.ts +11 -0
- package/dist/pptx/editor/render/element-operations.d.ts.map +1 -1
- package/dist/pptx/editor/render/element.d.ts +12 -0
- package/dist/pptx/editor/render/element.d.ts.map +1 -1
- package/dist/pptx/editor/render/find-replace.cjs +15 -15
- package/dist/pptx/editor/render/find-replace.d.ts +8 -2
- package/dist/pptx/editor/render/find-replace.d.ts.map +1 -1
- package/dist/pptx/editor/render/find-replace.mjs +2 -2
- package/dist/pptx/editor/render/font-family-update.d.ts +32 -1
- package/dist/pptx/editor/render/font-family-update.d.ts.map +1 -1
- package/dist/pptx/editor/render/group-drill.d.ts +26 -0
- package/dist/pptx/editor/render/group-drill.d.ts.map +1 -1
- package/dist/pptx/editor/render/group-ops.d.ts +24 -0
- package/dist/pptx/editor/render/paragraph-geometry-overrides.d.ts +21 -1
- package/dist/pptx/editor/render/paragraph-geometry-overrides.d.ts.map +1 -1
- package/dist/pptx/editor/render/remap-text.d.ts +5 -0
- package/dist/pptx/editor/render/remap-text.d.ts.map +1 -1
- package/dist/pptx/editor/render/section-operations.d.ts +14 -0
- package/dist/pptx/editor/render/section-operations.d.ts.map +1 -1
- package/dist/pptx/editor/render/slide-background-patch.d.ts +15 -0
- package/dist/pptx/editor/render/slide-background-patch.d.ts.map +1 -1
- package/dist/pptx/editor/render/slide-operations.cjs +9 -9
- package/dist/pptx/editor/render/slide-operations.d.ts +12 -0
- package/dist/pptx/editor/render/slide-operations.d.ts.map +1 -1
- package/dist/pptx/editor/render/slide-operations.mjs +3 -3
- package/dist/pptx/editor/render/slide-search.d.ts +6 -0
- package/dist/pptx/editor/render/slide-search.d.ts.map +1 -1
- package/dist/pptx/editor/render/slide-size-rescale.d.ts +18 -0
- package/dist/pptx/editor/render/slide-size-rescale.d.ts.map +1 -1
- package/dist/pptx/editor/render/slide-transition-edits.d.ts +15 -0
- package/dist/pptx/editor/render/slide-transition-edits.d.ts.map +1 -1
- package/dist/pptx/editor/render/table-cell-edit.d.ts +8 -0
- package/dist/pptx/editor/render/table-cell-edit.d.ts.map +1 -1
- package/dist/pptx/editor/render/table-cell-merge.d.ts +15 -0
- package/dist/pptx/editor/render/table-cell-merge.d.ts.map +1 -1
- package/dist/pptx/editor/render/table-data-grid-ops.d.ts +26 -0
- package/dist/pptx/editor/render/table-data-grid-ops.d.ts.map +1 -1
- package/dist/pptx/editor/render/table-layout.d.ts +3 -1
- package/dist/pptx/editor/render/table-layout.d.ts.map +1 -1
- package/dist/pptx/editor/render/table-merge.d.ts +16 -0
- package/dist/pptx/editor/render/table-merge.d.ts.map +1 -1
- package/dist/pptx/editor/render/table-style-editor-descriptor.d.ts +13 -0
- package/dist/pptx/editor/render/table-style-editor-descriptor.d.ts.map +1 -1
- package/dist/pptx/editor/render/table-style-editor-edit.d.ts +13 -0
- package/dist/pptx/editor/render/table-style-editor-edit.d.ts.map +1 -1
- package/dist/pptx/editor/render/table-style-editor-parts.d.ts +10 -0
- package/dist/pptx/editor/render/table-style-editor-parts.d.ts.map +1 -1
- package/dist/pptx/editor/render/table-style-map-edits.d.ts +20 -0
- package/dist/pptx/editor/render/table-style-map-edits.d.ts.map +1 -1
- package/dist/pptx/editor/render/text-content-style.d.ts +2 -1
- package/dist/pptx/editor/render/text-content-style.d.ts.map +1 -1
- package/dist/pptx/editor/render/text-runs-style-patch.d.ts +2 -2
- package/dist/pptx/editor/render/text-segment-paragraph-break.d.ts +23 -0
- package/dist/pptx/editor/render/text-segment-paragraph-break.d.ts.map +1 -1
- package/dist/pptx/editor/render/text-style-scope.d.ts +20 -2
- package/dist/pptx/editor/render/text-style-scope.d.ts.map +1 -1
- package/dist/pptx/editor/render/text-theme.d.ts +11 -0
- package/dist/pptx/editor/render/text-theme.d.ts.map +1 -1
- package/dist/pptx/editor/render/theme-editor-presets.d.ts +9 -0
- package/dist/pptx/editor/render/theme-editor-presets.d.ts.map +1 -1
- package/dist/pptx/editor/render/update-text-segment-style.d.ts +2 -1
- package/dist/pptx/editor/render/update-text-segment-style.d.ts.map +1 -1
- package/dist/pptx/index.cjs +34610 -33974
- package/dist/pptx/index.d.ts +24 -10
- package/dist/pptx/index.mjs +5 -5
- package/dist/pptx/node/index.d.ts +17 -1
- package/dist/pptx/node/index.d.ts.map +1 -1
- package/dist/pptx/signature-node/index.d.ts +8 -1
- package/dist/pptx/signature-node/index.d.ts.map +1 -1
- package/dist/pptx/smartart-layouts/index.d.ts +8 -1
- package/dist/pptx/smartart-layouts/index.d.ts.map +1 -1
- package/dist/pptx/ui/index.d.ts +2 -0
- package/dist/pptx/ui/index.d.ts.map +1 -1
- package/package.json +8 -8
- package/dist/PptxHandler-JX62VKU4.cjs +0 -14
- package/dist/PptxHandler-SUGLNSZI.mjs +0 -5
- package/dist/pptx/chunks/collaboration-text-codec-1VmwD3yq.d.ts +0 -34
- package/dist/pptx/chunks/collaboration-text-codec-1VmwD3yq.d.ts.map +0 -1
- package/dist/pptx/chunks/collaboration-text-merge-B-tth-0W.d.ts +0 -19
- package/dist/pptx/chunks/collaboration-text-merge-B-tth-0W.d.ts.map +0 -1
- package/dist/pptx/chunks/collaboration-text-positions-D-1Jo1Fz.d.ts +0 -34
- package/dist/pptx/chunks/collaboration-text-positions-D-1Jo1Fz.d.ts.map +0 -1
- package/dist/pptx/chunks/collaboration-text-session-CWHTaWF4.d.ts +0 -41
- package/dist/pptx/chunks/collaboration-text-session-CWHTaWF4.d.ts.map +0 -1
- package/dist/pptx/chunks/collaboration-text-session-delta-Dxzybssp.d.ts +0 -37
- package/dist/pptx/chunks/collaboration-text-session-delta-Dxzybssp.d.ts.map +0 -1
- package/dist/pptx/chunks/elements-B4Z6N-Gz.d.ts +0 -3993
- package/dist/pptx/chunks/elements-B4Z6N-Gz.d.ts.map +0 -1
- package/dist/pptx/chunks/index--HBUyILF.d.ts.map +0 -1
- package/dist/pptx/chunks/index-BDVzSboe.d.ts +0 -9746
- package/dist/pptx/chunks/index-BDVzSboe.d.ts.map +0 -1
- package/dist/pptx/chunks/index-Dr3iIPt9.d.ts.map +0 -1
- package/dist/pptx/chunks/inspection-status-TKac7eqb.d.ts.map +0 -1
- package/dist/pptx/chunks/schemas-LHsDbVOw.d.ts.map +0 -1
- package/dist/pptx/chunks/smart-art-DB37AsFP.d.ts +0 -1817
- package/dist/pptx/chunks/smart-art-DB37AsFP.d.ts.map +0 -1
- package/dist/pptx/chunks/table-BfgZfw5R.d.ts +0 -1359
- package/dist/pptx/chunks/table-BfgZfw5R.d.ts.map +0 -1
- package/dist/pptx/chunks/text-operations-CVHXOSit.d.ts +0 -3363
- package/dist/pptx/chunks/text-operations-CVHXOSit.d.ts.map +0 -1
- package/dist/pptx/chunks/text-t_wJ2OwM.d.ts +0 -1452
- package/dist/pptx/chunks/text-t_wJ2OwM.d.ts.map +0 -1
- /package/dist/{chunk-WFN6ZU7N.cjs → chunk-HBQBS7PO.cjs} +0 -0
- /package/dist/{chunk-DEDK2J57.mjs → chunk-I5REMIZR.mjs} +0 -0
|
@@ -1,2 +1,36 @@
|
|
|
1
|
-
import {
|
|
2
|
-
export
|
|
1
|
+
import { DeltaOp } from "./collaboration-text-codec.js";
|
|
2
|
+
export interface TextSessionUnit {
|
|
3
|
+
text: string;
|
|
4
|
+
attributes: Record<string, string>;
|
|
5
|
+
}
|
|
6
|
+
/** Browser edit range mapped to the editor's pre-input encoded coordinates. */
|
|
7
|
+
export interface LocalTextReplacement {
|
|
8
|
+
from: number;
|
|
9
|
+
to: number;
|
|
10
|
+
}
|
|
11
|
+
/** Desired UTF-16 units mapped to the editor's previously observed identities. */
|
|
12
|
+
export interface TextSessionCorrespondence {
|
|
13
|
+
readonly retainedIndices: readonly (number | null)[];
|
|
14
|
+
/** Old carriers for known paragraph attributes, independently of character identity. */
|
|
15
|
+
readonly paragraphSources?: readonly (number | null)[];
|
|
16
|
+
}
|
|
17
|
+
export type LocalTextEdit = LocalTextReplacement | TextSessionCorrespondence;
|
|
18
|
+
/** A range disambiguates repeated text; reject a draft that changed outside it. */
|
|
19
|
+
export declare function textSessionReplacementSpan(before: string, after: string, { from, to }: LocalTextReplacement): {
|
|
20
|
+
prefix: number;
|
|
21
|
+
suffix: number;
|
|
22
|
+
} | undefined;
|
|
23
|
+
/** Validate all identities before writes; null units are explicit new insertions. */
|
|
24
|
+
export declare function textSessionRetainedIndices(before: string, after: string, edit?: LocalTextEdit): (number | null)[] | undefined;
|
|
25
|
+
/** Copy and validate optional carrier provenance before entering a transaction. */
|
|
26
|
+
export declare function textSessionPlan(before: string, after: string, edit?: LocalTextEdit): TextSessionCorrespondence | undefined;
|
|
27
|
+
export declare function textSessionAttributesEqual(a: Record<string, string>, b: Record<string, string>): boolean;
|
|
28
|
+
/** Encoded Y.Text coordinates, not native editor/body offsets. */
|
|
29
|
+
export declare function textSessionDeltaSupported(delta: readonly DeltaOp[]): boolean;
|
|
30
|
+
/** Expand validated encoded runs into UTF-16 character identities. */
|
|
31
|
+
export declare function textSessionUnits(delta: readonly DeltaOp[]): TextSessionUnit[] | undefined;
|
|
32
|
+
/** Preserve remote keys when the local draft did not change them. */
|
|
33
|
+
export declare function textSessionAttributePatch(before: Record<string, string>, after: Record<string, string>, current: Record<string, string>): Record<string, string | null>;
|
|
34
|
+
/** Codec JSON objects merge local property changes without overwriting peer keys. */
|
|
35
|
+
export declare function mergeTextSessionObjectAttribute(before: string | undefined, after: string | undefined, current: string | undefined): string | null;
|
|
36
|
+
//# sourceMappingURL=collaboration-text-session-delta.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"collaboration-text-session-delta.d.ts","names":[],"sources":["../../../../pptx/editor/render/collaboration-text-session-delta.ts"],"mappings":";iBAGiB;EAChB;EACA,YAAY;;;iBAII;EAChB;EACA;;;iBAIgB;WACP;;WAEA;;YAGE,gBAAgB,uBAAuB;;wBAWnC,2BACf,gBACA,iBACE,MAAM,MAAM;EACV;EAAgB;;;wBAoBL,2BACf,gBACA,eACA,OAAO;;wBA8CQ,gBACf,gBACA,eACA,OAAO,gBACL;wBAsBa,2BACf,GAAG,wBACH,GAAG;;wBASY,0BAA0B,gBAAgB;;wBAS1C,iBAAiB,gBAAgB,YAAY;;wBAqB7C,0BACf,QAAQ,wBACR,OAAO,wBACP,SAAS,yBACP;;wBAmDa,gCACf,4BACA,2BACA"}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { TextSessionUnit } from "./collaboration-text-session-delta.js";
|
|
2
2
|
type ParagraphPatch = Record<string, string | null>;
|
|
3
3
|
/** Read source identities before deletion; character/run attributes never relocate. */
|
|
4
4
|
export declare function textSessionParagraphPatches(previous: readonly TextSessionUnit[], desired: readonly TextSessionUnit[], sources: readonly (number | null)[] | undefined, readCurrent: (source: number) => Record<string, string> | undefined): Map<number, ParagraphPatch>;
|
|
@@ -1,2 +1,40 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
1
|
+
import { DeltaOp } from "./collaboration-text-codec.js";
|
|
2
|
+
import { YTextEditableLike } from "./collaboration-text-merge.js";
|
|
3
|
+
import { LocalTextEdit } from "./collaboration-text-session-delta.js";
|
|
4
|
+
/** Supplied by the binding's existing Yjs runtime, bound to this exact Y.Text. */
|
|
5
|
+
export interface TextSessionPositions<Position> {
|
|
6
|
+
capture: (index: number, association: number) => Position;
|
|
7
|
+
resolve: (position: Position) => number | null;
|
|
8
|
+
/** Synchronize tracked positions once per batch, including in-transaction writes. */
|
|
9
|
+
refresh?: () => boolean | void;
|
|
10
|
+
/** Release only resources created for this session. */
|
|
11
|
+
dispose?: () => void;
|
|
12
|
+
}
|
|
13
|
+
/** Opaque acknowledgement identity for an exact remote snapshot painted by an adapter. */
|
|
14
|
+
export interface CollaborationTextSnapshot {
|
|
15
|
+
readonly delta: readonly DeltaOp[];
|
|
16
|
+
}
|
|
17
|
+
export interface CollaborationTextSession {
|
|
18
|
+
applyLocalDelta: (delta: readonly DeltaOp[], edit?: LocalTextEdit) => boolean;
|
|
19
|
+
readMerged: () => CollaborationTextSnapshot | undefined;
|
|
20
|
+
adoptMerged: (snapshot: CollaborationTextSnapshot) => boolean;
|
|
21
|
+
/** Capture an offset in the last painted/local draft, not the newer remote string. */
|
|
22
|
+
bookmark: (index: number, association: number) => () => number | null;
|
|
23
|
+
dispose: () => void;
|
|
24
|
+
}
|
|
25
|
+
/**
|
|
26
|
+
* Rebase an active editor's local intent onto an integrated Y.Text.
|
|
27
|
+
*
|
|
28
|
+
* This primitive uses encoded deltas, including the codec's break and empty-run
|
|
29
|
+
* carriers. Adapters must map native body offsets, initialize legacy plain-text
|
|
30
|
+
* inputs, and apply/acknowledge remote DOM snapshots separately. It does not
|
|
31
|
+
* reinterpret scalar text, own host resources or schedule delayed whole drafts.
|
|
32
|
+
*/
|
|
33
|
+
export declare function createCollaborationTextSession<Position>({ text, positions, transact, isCurrent }: {
|
|
34
|
+
text: YTextEditableLike;
|
|
35
|
+
positions: TextSessionPositions<Position>;
|
|
36
|
+
transact: (callback: () => void) => void;
|
|
37
|
+
/** Checks edit permission and the exact document/element/text identity. */
|
|
38
|
+
isCurrent: () => boolean;
|
|
39
|
+
}): CollaborationTextSession | undefined;
|
|
40
|
+
//# sourceMappingURL=collaboration-text-session.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"collaboration-text-session.d.ts","names":[],"sources":["../../../../pptx/editor/render/collaboration-text-session.ts"],"mappings":";;;;iBAaiB,qBAAqB;EACrC,UAAU,eAAe,wBAAwB;EACjD,UAAU,UAAU;;EAEpB;;EAEA;;;iBAIgB;WACP,gBAAgB;;iBAGT;EAChB,kBAAkB,gBAAgB,WAAW,OAAO;EACpD,kBAAkB;EAClB,cAAc,UAAU;;EAExB,WAAW,eAAe;EAC1B;;;;;;;;;;wBAWe,+BAA+B,YAC9C,MACA,WACA,UACA;EAEA,MAAM;EACN,WAAW,qBAAqB;EAChC,WAAW;;EAEX;IACG"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import { TrackedTextPosition } from "./collaboration-text-positions.js";
|
|
2
|
+
import { DeltaOp } from "./collaboration-text-codec.js";
|
|
3
3
|
/** Public snapshot operations supplied by the binding's existing Yjs runtime. */
|
|
4
4
|
export interface TextPositionSnapshots<Snapshot> {
|
|
5
5
|
read: () => Snapshot;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkHBQBS7PO_cjs = require('../../../chunk-HBQBS7PO.cjs');
|
|
4
4
|
require('../../../chunk-XZPZHXV4.cjs');
|
|
5
5
|
require('../../../chunk-5W2QL4SB.cjs');
|
|
6
6
|
|
|
@@ -114,7 +114,7 @@ function customShowSlides(show, slides) {
|
|
|
114
114
|
});
|
|
115
115
|
}
|
|
116
116
|
function clearCustomShowActions(slides, id) {
|
|
117
|
-
const result =
|
|
117
|
+
const result = chunkHBQBS7PO_cjs.mapCustomShowActions(slides, (target) => target === id ? null : target);
|
|
118
118
|
return { slides: result.slides, cleared: result.changed };
|
|
119
119
|
}
|
|
120
120
|
|
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* custom-show-operations: pure edits of the `p:custShowLst` model.
|
|
3
|
+
*
|
|
4
|
+
* Mirrors PowerPoint's Slide Show > Custom Slide Show > Custom Shows dialog:
|
|
5
|
+
* New, Edit (name, add slides, remove, reorder), Copy and Remove. Every function
|
|
6
|
+
* takes the current shows and returns NEW values; inputs are never mutated.
|
|
7
|
+
*
|
|
8
|
+
* A show lists slides by relationship id (`PptxSlide.rId`, `p:sld/@r:id`), may
|
|
9
|
+
* repeat a slide (PowerPoint allows it), and is identified by an
|
|
10
|
+
* `xsd:unsignedInt` id that hyperlinks and actions name with
|
|
11
|
+
* `ppaction://customshow?id=N`. Slide deletion and reordering are reconciled
|
|
12
|
+
* by the save pipeline (`applyCustomShows` remaps and prunes by rId); use
|
|
13
|
+
* {@link pruneCustomShowSlides} to keep the in-memory model in step.
|
|
14
|
+
*/
|
|
1
15
|
import { PptxCustomShow, PptxSlide } from "ooxml-core/pptx";
|
|
2
16
|
/** Result of an edit that targets one show. `show` is undefined when the id is unknown. */
|
|
3
17
|
export interface CustomShowEditResult {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"custom-show-operations.d.ts","names":[],"sources":["../../../../pptx/editor/render/custom-show-operations.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"custom-show-operations.d.ts","names":[],"sources":["../../../../pptx/editor/render/custom-show-operations.ts"],"mappings":";;;;;;;;;;;;;;;;iBAmBiB;EAChB,OAAO;EACP,MAAM;;;wBAIS,iBAAiB,gBAAgB;;wBAYjC,qBACf,gBAAgB,kBAChB,cACA;;wBAkCe,iBACf,gBAAgB,kBAChB,cACA,gCACE;;wBAUa,iBACf,gBAAgB,kBAChB,YACA,eACE;;wBAQa,oBACf,gBAAgB,kBAChB,YACA,+BACE;;wBAKa,sBACf,gBAAgB,kBAChB,YACA,8BACA,iBACE;;wBAUa,2BACf,gBAAgB,kBAChB,YACA,+BACE;;wBASa,oBACf,gBAAgB,kBAChB,YACA,cACA,aACE;;wBAaa,eACf,gBAAgB,kBAChB,YACA,gBACE;;wBAea,iBACf,gBAAgB,kBAChB,aACE;;wBAMa,sBACf,gBAAgB,kBAChB,iBAAiB,KAAK,sBACpB;;wBAUa,iBAAiB,UAAU,KAAK,mBAC/C,MAAM,gBACN,iBAAiB,MACf;;;;;;wBAaa,uBACf,iBAAiB,aACjB;EACI,QAAQ;EAAa"}
|
|
@@ -1,3 +1,27 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* deck-save-encryption: the single place that decides whether a deck save
|
|
3
|
+
* produces a plain OOXML ZIP or an encrypted OLE/CFB container.
|
|
4
|
+
*
|
|
5
|
+
* "Encrypt with Password" (File > Info > Protect Presentation) captures a
|
|
6
|
+
* secret in every binding. Whether that secret reaches the serialiser used to
|
|
7
|
+
* be re-decided per binding, and four of the five never decided it at all:
|
|
8
|
+
* they stored the password, showed a "protected" badge, and wrote a plaintext
|
|
9
|
+
* `.pptx`. That is a security-facing lie, so the decision now lives here as a
|
|
10
|
+
* pure function and every binding routes its save through
|
|
11
|
+
* {@link saveDeckWithPassword}.
|
|
12
|
+
*
|
|
13
|
+
* The rule is deliberately trivial: a non-empty password means
|
|
14
|
+
* `PptxHandler.saveEncrypted` (ECMA-376 agile encryption inside an OLE2
|
|
15
|
+
* compound file with `EncryptionInfo` + `EncryptedPackage` streams), anything
|
|
16
|
+
* else means `PptxHandler.save` (a `PK\x03\x04` ZIP). What matters is that it
|
|
17
|
+
* is decided ONCE.
|
|
18
|
+
*
|
|
19
|
+
* The one exception is the save PURPOSE (see {@link DeckSavePurpose}): bytes the
|
|
20
|
+
* viewer writes only so it can read them back itself - the crash-recovery
|
|
21
|
+
* autosave snapshot, and the re-serialise-then-reload cycle behind "apply
|
|
22
|
+
* theme" - are never encrypted, because nothing on the way back in has a
|
|
23
|
+
* password to offer.
|
|
24
|
+
*/
|
|
1
25
|
import { PptxHandler, PptxSlide } from "ooxml-core/pptx";
|
|
2
26
|
/**
|
|
3
27
|
* The slice of `PptxHandler` a deck save needs. Bindings pass the live handler;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"deck-save-encryption.d.ts","names":[],"sources":["../../../../pptx/editor/render/deck-save-encryption.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"deck-save-encryption.d.ts","names":[],"sources":["../../../../pptx/editor/render/deck-save-encryption.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;YAgCY,qBAAqB,KAAK;;YAG1B,kBAAkB,YAAY,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;YA8CzC;;;;;;;;;;;iBAYK;EAChB;EACA;EACA,UAAU;;;;;;YAOC;WACE;WAA6B;;WAC7B;WAAsC;WAA0B;;;;;;;;;;;;;;;;;;;;wBAsB9D,aAAa,QAAQ,6CAA6C;;;;;;;;;;;;;;;;;;wBAqClE,uBACf,SAAS,iCACP;EAAmB;;;;;;;;;;;;;;;;;wBAuBA,qBACrB,YAAY,oBACZ,QAAQ,aACR,SAAS,6BACT,QAAQ,6CACN,QAAQ;;;;;;;;;wBAgBK,qBAAqB,OAAO,aAAa"}
|
|
@@ -1,3 +1,28 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* `element-locks`: whether an authored `a:spLocks` lets a gesture proceed.
|
|
3
|
+
*
|
|
4
|
+
* PowerPoint stores per-shape interaction locks on the non-visual properties
|
|
5
|
+
* node (`p:cNvSpPr/a:spLocks`, and the `a:cxnSpLocks` / `a:picLocks` /
|
|
6
|
+
* `a:grpSpLocks` / `a:graphicFrameLocks` variants), and the parser folds all of
|
|
7
|
+
* them into one {@link PptxShapeLocks} bag on the element. A locked shape in a
|
|
8
|
+
* real deck is a template guardrail: the author is saying "the reader may not
|
|
9
|
+
* drag this masthead off the slide".
|
|
10
|
+
*
|
|
11
|
+
* Enforcement used to be spread across the bindings by hand, which is how the
|
|
12
|
+
* repo ended up shipping a Lock button in the Vue and Angular inspectors that
|
|
13
|
+
* wrote `locks` nothing on the canvas ever read. This module is the single
|
|
14
|
+
* decision function: give it an element and it returns a framework-neutral
|
|
15
|
+
* descriptor of what the user may still do to it, and every binding maps that
|
|
16
|
+
* descriptor onto its own pointer wiring.
|
|
17
|
+
*
|
|
18
|
+
* Composition rules (PowerPoint's, not ours):
|
|
19
|
+
* - `noSelect` subsumes everything. A shape you cannot select is a shape you
|
|
20
|
+
* cannot move, resize, rotate, adjust or edit, whatever the other flags say.
|
|
21
|
+
* - every other flag gates exactly one gesture, so a shape can be pinned in
|
|
22
|
+
* place (`noMove`) and still be resized, which is what PowerPoint does.
|
|
23
|
+
*
|
|
24
|
+
* @module render/element-locks
|
|
25
|
+
*/
|
|
1
26
|
import { PptxElement, PptxShapeLocks } from "ooxml-core/pptx";
|
|
2
27
|
/** A single on-canvas gesture a lock may forbid. */
|
|
3
28
|
export type ElementInteraction = 'select' | 'move' | 'resize' | 'rotate' | 'textEdit' | 'group' | 'changeAspect' | 'adjustHandle' | 'editPoints' | 'changeArrowheads' | 'changeShapeType' | 'crop' | 'drilldown';
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"element-locks.d.ts","names":[],"sources":["../../../../pptx/editor/render/element-locks.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"element-locks.d.ts","names":[],"sources":["../../../../pptx/editor/render/element-locks.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;YA4BY;;;;;;;;;iBAuBK;;EAEhB;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;;;;;;;EAQA;;;;;;;;wBA2Ce,gBACf,SAAS,iCACP;;;;;;;;wBAWa,4BACf,SAAS,iCACP;;;;;;;;wBAiDa,uBACf,SAAS,gCACT,aAAa;;;;;;;;;;;wBAeE,aAAa,SAAS;;wBAKtB,2BACf,SAAS,gCACT,aAAa;;;;;;;wBAWE,gBAAgB,SAAS;;;;;;;;;;;;;wBAoBzB,uBAAuB,sBAAsB;;;;;;;;wBAW7C,sBACf,wBACA,SAAS,eAAe,gCACxB,aAAa"}
|
|
@@ -1,3 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* element-operations: Pure array-transformation functions for slide elements.
|
|
3
|
+
*
|
|
4
|
+
* All functions are framework-agnostic (no framework imports). Each takes a
|
|
5
|
+
* `readonly PptxElement[]` representing the ordered element list for a slide
|
|
6
|
+
* (array index 0 = back, last index = front/top in paint order) and returns a
|
|
7
|
+
* NEW array; the input is never mutated.
|
|
8
|
+
*
|
|
9
|
+
* Callers supply a `newId` wherever a new element identity is needed, keeping
|
|
10
|
+
* these functions deterministic and side-effect-free.
|
|
11
|
+
*/
|
|
1
12
|
import { PptxElement } from "ooxml-core/pptx";
|
|
2
13
|
/**
|
|
3
14
|
* Shallow-merge `patch` onto the element with `id`.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"element-operations.d.ts","names":[],"sources":["../../../../pptx/editor/render/element-operations.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"element-operations.d.ts","names":[],"sources":["../../../../pptx/editor/render/element-operations.ts"],"mappings":";;;;;;;;;;;;;;;;;;;wBAqEgB,kBACf,mBAAmB,eACnB,YACA,OAAO,QAAQ,eACb;;;;;;;wBAUa,cACf,mBAAmB,eACnB,YACA,YACA,aACE;;;;;;;wBAUa,mBACf,mBAAmB,eACnB,YACA,WACA,YACE;;;;;;;;wBAWa,cACf,mBAAmB,eACnB,YACA,eACA,iBACE;;;;;;;;wBAaa,oBACf,mBAAmB,eACnB,yBACE;;;;;;;;;;;;wBAmBa,qBACf,mBAAmB,eACnB,YACA,eACA,kBACE;;;;;;;wBAuBa,aAAa,mBAAmB,eAAe,aAAa;;;;;;;wBAgB5D,WAAW,mBAAmB,eAAe,aAAa;;;;;;;;wBAiB1D,aAAa,mBAAmB,eAAe,aAAa;;;;;;;;wBAmB5D,aAAa,mBAAmB,eAAe,aAAa"}
|
|
@@ -1,3 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* element.ts: framework-agnostic element helpers for the viewer/editor.
|
|
3
|
+
*
|
|
4
|
+
* Template-origin detection, inline-text eligibility, display labels, comment
|
|
5
|
+
* timestamp formatting + marker positioning, and connection-site geometry. All
|
|
6
|
+
* pure (only `ooxml-core/pptx` types), shared by every binding.
|
|
7
|
+
*
|
|
8
|
+
* Note: `isConnectorOrLineElement` stays in each binding because it depends on
|
|
9
|
+
* that binding's shape-type classifier (not a core export).
|
|
10
|
+
*
|
|
11
|
+
* @module render/element
|
|
12
|
+
*/
|
|
1
13
|
import { PptxComment, PptxElement, PptxElementWithText } from "ooxml-core/pptx";
|
|
2
14
|
/**
|
|
3
15
|
* Checks whether an element originates from a slide layout or slide master.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"element.d.ts","names":[],"sources":["../../../../pptx/editor/render/element.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"element.d.ts","names":[],"sources":["../../../../pptx/editor/render/element.ts"],"mappings":";;;;;;;;;;;;;;;;;wBAwBgB,kBAAkB,SAAS;;;;wBAO3B,oBAAoB;;;;;;wBASpB,sBAAsB,SAAS,cAAc,WAAW;;;;;wBAexD,gBAAgB,SAAS;;;;;wBAmDzB,uBAAuB;;;;;;wBAuBvB,yBACf,SAAS,aACT,eACA,eACA;EACI;EAAW;;;;;;;;;;wBAoBA,0BACf,SAAS,aACT;EACI;EAAW"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
4
|
-
var
|
|
3
|
+
var chunk7RCBSNXT_cjs = require('../../../chunk-7RCBSNXT.cjs');
|
|
4
|
+
var chunkHBQBS7PO_cjs = require('../../../chunk-HBQBS7PO.cjs');
|
|
5
5
|
var chunkXZPZHXV4_cjs = require('../../../chunk-XZPZHXV4.cjs');
|
|
6
6
|
require('../../../chunk-5W2QL4SB.cjs');
|
|
7
7
|
var chunkAWIDASUW_cjs = require('../../../chunk-AWIDASUW.cjs');
|
|
@@ -146,10 +146,10 @@ function* findSlideTextTargets(slide, includeNotes = false, includeChartTitles =
|
|
|
146
146
|
function patchTableXml(element, rowIndex, colIndex, original, runs) {
|
|
147
147
|
if (!element.rawXml) return void 0;
|
|
148
148
|
const rawXml = structuredClone(element.rawXml);
|
|
149
|
-
const table =
|
|
150
|
-
const row =
|
|
151
|
-
const cell =
|
|
152
|
-
const paragraphs =
|
|
149
|
+
const table = chunk7RCBSNXT_cjs.getTblFromRawXml(rawXml);
|
|
150
|
+
const row = chunk7RCBSNXT_cjs.ensureArray(table?.["a:tr"])[rowIndex];
|
|
151
|
+
const cell = chunk7RCBSNXT_cjs.ensureArray(row?.["a:tc"])[colIndex];
|
|
152
|
+
const paragraphs = chunk7RCBSNXT_cjs.ensureArray(
|
|
153
153
|
cell?.["a:txBody"]?.["a:p"]
|
|
154
154
|
);
|
|
155
155
|
let paragraphIndex = 0, runIndex = 0, fieldIndex = 0;
|
|
@@ -164,7 +164,7 @@ function patchTableXml(element, rowIndex, colIndex, original, runs) {
|
|
|
164
164
|
if (previous.isLineBreak) continue;
|
|
165
165
|
const paragraph = paragraphs[paragraphIndex];
|
|
166
166
|
const key = previous.isField ? "a:fld" : "a:r";
|
|
167
|
-
const xmlRun =
|
|
167
|
+
const xmlRun = chunk7RCBSNXT_cjs.ensureArray(paragraph?.[key])[previous.isField ? fieldIndex++ : runIndex++];
|
|
168
168
|
if (!xmlRun) return void 0;
|
|
169
169
|
if (previous.text !== runs[index].text) xmlRun["a:t"] = runs[index].text;
|
|
170
170
|
}
|
|
@@ -174,7 +174,7 @@ function updateNode(nodes, nodeId, text) {
|
|
|
174
174
|
return nodes.map((node) => {
|
|
175
175
|
if (node.id === nodeId) {
|
|
176
176
|
const originalParagraphs = node.paragraphs ?? (node.runs?.length ? [{ items: node.runs.map((run) => ({ kind: "run", run })) }] : void 0);
|
|
177
|
-
const paragraphs = originalParagraphs ?
|
|
177
|
+
const paragraphs = originalParagraphs ? chunkHBQBS7PO_cjs.reconcileSmartArtTextParagraphs(originalParagraphs, text) : void 0;
|
|
178
178
|
return { ...node, text, ...paragraphs ? { paragraphs } : {} };
|
|
179
179
|
}
|
|
180
180
|
if (!node.children) return node;
|
|
@@ -253,14 +253,14 @@ function replaceLeaf(element, match, replacement) {
|
|
|
253
253
|
);
|
|
254
254
|
if (!runs) return element;
|
|
255
255
|
let text = runs.map((run) => run.isParagraphBreak ? "\n" : run.isLineBreak ? "" : run.text).join("");
|
|
256
|
-
let rawXml = cell.textRuns?.length ? patchTableXml(element, rowIndex, colIndex, original2, runs) :
|
|
256
|
+
let rawXml = cell.textRuns?.length ? patchTableXml(element, rowIndex, colIndex, original2, runs) : chunk7RCBSNXT_cjs.updateCellTextInRawXml(element, rowIndex, colIndex, text);
|
|
257
257
|
if (rawXml) {
|
|
258
|
-
const table =
|
|
259
|
-
const xmlRow =
|
|
260
|
-
const xmlCell =
|
|
261
|
-
text =
|
|
258
|
+
const table = chunk7RCBSNXT_cjs.getTblFromRawXml(rawXml);
|
|
259
|
+
const xmlRow = chunk7RCBSNXT_cjs.ensureArray(table?.["a:tr"])[rowIndex];
|
|
260
|
+
const xmlCell = chunk7RCBSNXT_cjs.ensureArray(xmlRow?.["a:tc"])[colIndex];
|
|
261
|
+
text = chunk7RCBSNXT_cjs.flattenCellTxBodyText(
|
|
262
262
|
xmlCell?.["a:txBody"],
|
|
263
|
-
(value) =>
|
|
263
|
+
(value) => chunk7RCBSNXT_cjs.ensureArray(value)
|
|
264
264
|
);
|
|
265
265
|
}
|
|
266
266
|
const rows = [...element.tableData.rows], cells = [...row.cells];
|
|
@@ -274,7 +274,7 @@ function replaceLeaf(element, match, replacement) {
|
|
|
274
274
|
if (!node || match.startOffset < 0 || match.startOffset + match.length > node.text.length)
|
|
275
275
|
return element;
|
|
276
276
|
const text = node.text.slice(0, match.startOffset) + replacement + node.text.slice(match.startOffset + match.length);
|
|
277
|
-
const next =
|
|
277
|
+
const next = chunkHBQBS7PO_cjs.updateSmartArtNodeText({ ...data, nodes }, node.id, text);
|
|
278
278
|
const drawingShapes = next.drawingShapes?.map((shape, index) => {
|
|
279
279
|
if (shape === data.drawingShapes?.[index] || !shape.textSegments) return shape;
|
|
280
280
|
return {
|
|
@@ -1,5 +1,11 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
/**
|
|
2
|
+
* Pure find & replace helpers for PPTX slides, shared by every binding.
|
|
3
|
+
*
|
|
4
|
+
* All functions are immutable; they never mutate their input arrays. No
|
|
5
|
+
* framework imports, so this is safe to use in web workers or server-side code.
|
|
6
|
+
*/
|
|
7
|
+
import { _ as PptxSlide } from "../../chunks/presentation-Be108jrz.js";
|
|
8
|
+
import "../../chunks/index-cr_sgz1w.js";
|
|
3
9
|
/** Identifies a single match of the find query at segment-level precision. */
|
|
4
10
|
export interface FindResult {
|
|
5
11
|
/** Zero-based index of the slide in the slides array. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"find-replace.d.ts","names":[],"sources":["../../../../pptx/editor/render/find-replace.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"find-replace.d.ts","names":[],"sources":["../../../../pptx/editor/render/find-replace.ts"],"mappings":";;;;;;;;;iBAiBiB;;EAEhB;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;;EAEA;IAAc;IAAkB;;;EAEhC;;EAEA;;EAEA;;EAEA;EACA;EACA;;EAEA;;;iBAIgB;;EAEhB;;EAEA;;EAEA;;EAEA;;;iBAIgB;;EAEhB,iBAAiB;;EAEjB;;;wBAIe,4BACf,kBAAkB,KAAK,2BACvB;;;;;;;;;;;;;;wBAuBe,aACf,iBAAiB,aACjB,eACA,OAAM,cACJ;;;;;;;;;;wBA4Ea,sBACf,iBAAiB,aACjB,oBAAoB,cACpB,sBACE;;;;;;;;;wBAuHa,aACf,iBAAiB,aACjB,qBAAqB,cACrB,oBACA,sBACE;;;;;;;wBAca,gBACf,iBAAiB,aACjB,eACA,qBACA,OAAM,cACJ"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { updateCellTextInRawXml, getTblFromRawXml, ensureArray, flattenCellTxBodyText } from '../../../chunk-
|
|
2
|
-
import { updateSmartArtNodeText, reconcileSmartArtTextParagraphs } from '../../../chunk-
|
|
1
|
+
import { updateCellTextInRawXml, getTblFromRawXml, ensureArray, flattenCellTxBodyText } from '../../../chunk-CXIDPUT6.mjs';
|
|
2
|
+
import { updateSmartArtNodeText, reconcileSmartArtTextParagraphs } from '../../../chunk-I5REMIZR.mjs';
|
|
3
3
|
import { hasTextProperties } from '../../../chunk-GXHKNSZX.mjs';
|
|
4
4
|
import '../../../chunk-CA7KCNL3.mjs';
|
|
5
5
|
import { remapTextToSegments } from '../../../chunk-CBNKBVX5.mjs';
|
|
@@ -1,4 +1,35 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* What picking a font family in the ribbon or the inspector writes to a run.
|
|
3
|
+
*
|
|
4
|
+
* A run names up to four faces (`a:latin`, `a:ea`, `a:cs`, `a:sym`) and the
|
|
5
|
+
* renderer paints each script in its own face (`text-script-fonts.ts`). The
|
|
6
|
+
* font picker only ever set `fontFamily` (the `a:latin` face), so a run whose
|
|
7
|
+
* `a:ea` named the same font as its `a:latin` kept painting Hangul, kana and
|
|
8
|
+
* Han in the old face: on a Korean or Japanese slide choosing a font changed
|
|
9
|
+
* nothing visible. A deck written by PowerPoint for a CJK locale, or by most
|
|
10
|
+
* converters, gives every slot the same face, so this is the common case.
|
|
11
|
+
*
|
|
12
|
+
* The rule kept here is deliberately narrow: an east Asian or complex script
|
|
13
|
+
* face follows the new family only when it was the same face as the old
|
|
14
|
+
* `a:latin`, i.e. the deck treated the slots as one font. A run with a
|
|
15
|
+
* distinct Asian face (`a:latin` Arial with `a:ea` Meiryo, or a theme whose
|
|
16
|
+
* minor east Asian font differs from its minor Latin font) keeps it, since
|
|
17
|
+
* the picker cannot tell whether the new font covers the script. PowerPoint
|
|
18
|
+
* makes the same call: a Latin font picked from the font box leaves `a:ea`
|
|
19
|
+
* alone.
|
|
20
|
+
*
|
|
21
|
+
* A concrete family also drops the theme token of each face it replaces. The
|
|
22
|
+
* writer prefers the token (`+mn-lt`) over the concrete name, so leaving it in
|
|
23
|
+
* place lost the choice on save.
|
|
24
|
+
*
|
|
25
|
+
* "Same face" is judged against the run's EFFECTIVE Latin face: a run with no
|
|
26
|
+
* `fontFamily` of its own inherits it from the text box, so the caller passes
|
|
27
|
+
* the box's (pre-edit) style as `inherited`. A script slot matches when its
|
|
28
|
+
* concrete face equals that Latin face or its theme token equals the Latin
|
|
29
|
+
* theme token (a token-only slot has no concrete face to compare).
|
|
30
|
+
*/
|
|
31
|
+
import { Tc as TextStyle } from "../../chunks/presentation-Be108jrz.js";
|
|
32
|
+
import "../../chunks/index-cJSPBkU1.js";
|
|
2
33
|
/**
|
|
3
34
|
* Expand a style update for `style`: when it sets a concrete `fontFamily`,
|
|
4
35
|
* carry the change to the script faces that were the same face as the old
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"font-family-update.d.ts","names":[],"sources":["../../../../pptx/editor/render/font-family-update.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"font-family-update.d.ts","names":[],"sources":["../../../../pptx/editor/render/font-family-update.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;wBAgDgB,uBACf,OAAO,uBACP,SAAS,QAAQ,YACjB,YAAY,YACV,QAAQ;;;;;wBAmCK,qBACf,OAAO,uBACP,SAAS,QAAQ,YACjB,YAAY,YACV"}
|
|
@@ -1,3 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Selecting inside a group, the way PowerPoint does: the first click selects
|
|
3
|
+
* the group, a click on one of its members while the group is selected selects
|
|
4
|
+
* that member, a click on another member of the same group moves the selection
|
|
5
|
+
* to it, a double-click goes straight to the innermost shape (so its text can
|
|
6
|
+
* be edited without ungrouping), and Escape steps back out one level.
|
|
7
|
+
*
|
|
8
|
+
* Group members are stored relative to their group (the parser subtracts the
|
|
9
|
+
* parent's offset, see `PptxHandlerRuntimeGroupParsing`), and every binding's
|
|
10
|
+
* lookups, selection chrome and update paths only know top-level elements. So
|
|
11
|
+
* this module gives the bindings three things, framework-free:
|
|
12
|
+
*
|
|
13
|
+
* - the decision (which id a click, double-click or Escape selects);
|
|
14
|
+
* - a geometric hit-test, because grouped children render with
|
|
15
|
+
* `pointer-events: none` and a click's DOM target is always the group;
|
|
16
|
+
* - a slide-space view of a member (absolute x/y) for the chrome, drag and
|
|
17
|
+
* inline editor, and the reverse: an update in slide space written back
|
|
18
|
+
* into the group's coordinate space.
|
|
19
|
+
*
|
|
20
|
+
* Only groups that are neither rotated nor flipped are entered: their members'
|
|
21
|
+
* slide-space box is then a plain offset, and anything else keeps today's
|
|
22
|
+
* behaviour (the group selects as one) instead of drawing chrome in the wrong
|
|
23
|
+
* place.
|
|
24
|
+
*
|
|
25
|
+
* @module render/group-drill
|
|
26
|
+
*/
|
|
1
27
|
import { GroupPptxElement, PptxElement } from "ooxml-core/pptx";
|
|
2
28
|
/** A group whose members can be selected one by one (see the module note). */
|
|
3
29
|
export declare function isEnterableGroup(el: PptxElement): el is GroupPptxElement;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"group-drill.d.ts","names":[],"sources":["../../../../pptx/editor/render/group-drill.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"group-drill.d.ts","names":[],"sources":["../../../../pptx/editor/render/group-drill.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;wBAqCgB,iBAAiB,IAAI,cAAc,MAAM;;;;;wBAUzC,gBACf,mBAAmB,eACnB,aACE;;wBAgBa,cAAc,mBAAmB,eAAe;;;;;;;wBA6BhD,kBACf,mBAAmB,eACnB,aACE;;;;;;wBAqBa,kBAAkB,mBAAmB,gBAAgB,YAAY;;;;;;;;;wBA2BjE,oBACf,UAAU,eACV,YACA,SAAS,QAAQ,eACf;;;;;;;;;wBAwCa,mBACf,mBAAmB,eACnB,eACA;EAAS;EAAW;;;;;;;;;;;;;;;;wBAmDL,uBACf,0BACA,uBAAuB;;wBA8BR,6BAA6B;;;;;;wBAS7B,gBACf,mBAAmB,eACnB"}
|
|
@@ -1,2 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* group-ops: pure, immutable group/ungroup operations for the slide element
|
|
3
|
+
* tree, shared by every binding's editor.
|
|
4
|
+
*
|
|
5
|
+
* The implementation itself lives in `ooxml-core/pptx`
|
|
6
|
+
* (`core/utils/group-ops`) and is re-exported here unchanged, because the
|
|
7
|
+
* `pptx-viewer-mcp` tool set that backs the AI panel needs the SAME operation
|
|
8
|
+
* and cannot import this package: `pptx-viewer-mcp` is published, this one is
|
|
9
|
+
* private and already imports it. Core is the only module all three consumers
|
|
10
|
+
* reach, and one implementation cannot drift from itself: the MCP copy had
|
|
11
|
+
* already drifted into appending a grouped selection to the front of the paint
|
|
12
|
+
* order and re-iding nothing when promoting a nested group.
|
|
13
|
+
*
|
|
14
|
+
* Coordinate system (verified from the renderer):
|
|
15
|
+
* - The group <div> is positioned at (group.x, group.y) in slide space.
|
|
16
|
+
* - Each child is positioned at (child.x, child.y) RELATIVE to the group's
|
|
17
|
+
* top-left corner inside that div.
|
|
18
|
+
*
|
|
19
|
+
* Therefore:
|
|
20
|
+
* - grouping -> child slide-absolute -> child group-relative:
|
|
21
|
+
* childRelX = childAbsX - groupX
|
|
22
|
+
* - ungrouping -> child group-relative -> child slide-absolute:
|
|
23
|
+
* childAbsX = childRelX + groupX
|
|
24
|
+
*/
|
|
1
25
|
import { GroupResult, UngroupOptions, UngroupResult, groupElements, ungroupElements } from "ooxml-core/pptx";
|
|
2
26
|
export { type GroupResult, type UngroupOptions, type UngroupResult, groupElements, ungroupElements };
|
|
@@ -1,4 +1,24 @@
|
|
|
1
|
-
|
|
1
|
+
/**
|
|
2
|
+
* Per-paragraph overrides of the kinsoku / font-alignment / tab-default
|
|
3
|
+
* geometry that `resolveShapeParagraphStyle` (core) otherwise collapses to
|
|
4
|
+
* whichever paragraph authors it FIRST in the shape.
|
|
5
|
+
*
|
|
6
|
+
* Core keeps a single shape-scope `TextStyle` object it mutates across every
|
|
7
|
+
* paragraph, first-wins (`if (textStyle.eaLineBreak === undefined) {...}`):
|
|
8
|
+
* paragraph 1's own `a:pPr/@eaLnBrk`/`@latinLnBrk`/`@fontAlgn`/
|
|
9
|
+
* `@hangingPunct`/`@defTabSz` becomes every OTHER paragraph's resolved value
|
|
10
|
+
* too, because they all read the SAME mutated object. Each paragraph's own
|
|
11
|
+
* authored value is still captured separately, strictly, on
|
|
12
|
+
* `TextSegment.paragraphProperties` (`extractParagraphOwnProperties`) for
|
|
13
|
+
* round-trip - just never consulted at render. This module is the render-side
|
|
14
|
+
* fix: it resolves this paragraph's OWN value first, falling back to the
|
|
15
|
+
* text body's resolved (first-paragraph-collapsed) value exactly like
|
|
16
|
+
* `resolveParagraphSpacing` already does for spacing.
|
|
17
|
+
*
|
|
18
|
+
* @module render/paragraph-geometry-overrides
|
|
19
|
+
*/
|
|
20
|
+
import { Tc as TextStyle } from "../../chunks/presentation-Be108jrz.js";
|
|
21
|
+
import "../../chunks/index-cJSPBkU1.js";
|
|
2
22
|
/** The geometry keys a paragraph may override independently of the body. */
|
|
3
23
|
export type ParagraphGeometryOverrides = Pick<TextStyle, 'eaLineBreak' | 'latinLineBreak' | 'hangingPunctuation' | 'fontAlignment' | 'defaultTabSize'>;
|
|
4
24
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"paragraph-geometry-overrides.d.ts","names":[],"sources":["../../../../pptx/editor/render/paragraph-geometry-overrides.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"paragraph-geometry-overrides.d.ts","names":[],"sources":["../../../../pptx/editor/render/paragraph-geometry-overrides.ts"],"mappings":";;;;;;;;;;;;;;;;;;;;;;YAuBY,6BAA6B,KACxC;;;;;;;;;;;wBAce,kCACf,WAAW,uBACX,WAAW,wBACT"}
|
|
@@ -1,3 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Remap edited plain-text back onto original rich-text segments, preserving
|
|
3
|
+
* per-segment styles (font, size, colour, bold, italic, …). Pure,
|
|
4
|
+
* framework-agnostic logic shared by every binding (React / Vue / Angular).
|
|
5
|
+
*/
|
|
1
6
|
import { TextSegment, TextStyle } from "ooxml-core/pptx";
|
|
2
7
|
/**
|
|
3
8
|
* Strategy:
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"remap-text.d.ts","names":[],"sources":["../../../../pptx/editor/render/remap-text.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"remap-text.d.ts","names":[],"sources":["../../../../pptx/editor/render/remap-text.ts"],"mappings":";;;;;;;;;;;;;wBAiFgB,oBACf,iBACA,kBAAkB,2BAClB,kBAAkB,wBAChB"}
|
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* section-operations: Pure array-transformation functions for slide sections.
|
|
3
|
+
*
|
|
4
|
+
* Framework-agnostic (no framework imports). Each transform takes the current
|
|
5
|
+
* `sections` and `slides` arrays and returns a NEW `{ sections, slides }` pair;
|
|
6
|
+
* the inputs are never mutated. The React `useSectionOperations` hook and the
|
|
7
|
+
* Vue `useSectionOperations` composable both wire their reactive state through
|
|
8
|
+
* these transforms so the immutable section algorithms live in one place.
|
|
9
|
+
*
|
|
10
|
+
* Section ids are OOXML GUID-like strings. `addSection` generates one via the
|
|
11
|
+
* supplied `idGenerator` (default {@link generateSectionId}), keeping the
|
|
12
|
+
* transform overridable yet self-contained, matching the neighbouring shared
|
|
13
|
+
* editor modules.
|
|
14
|
+
*/
|
|
1
15
|
import { PptxSection, PptxSlide } from "ooxml-core/pptx";
|
|
2
16
|
/** The updated `sections` + `slides` pair produced by a section transform. */
|
|
3
17
|
export interface SectionMutationResult {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"section-operations.d.ts","names":[],"sources":["../../../../pptx/editor/render/section-operations.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"section-operations.d.ts","names":[],"sources":["../../../../pptx/editor/render/section-operations.ts"],"mappings":";;;;;;;;;;;;;;;;iBAsBiB;EAChB,UAAU;EACV,QAAQ;;;iBAIQ;EAChB;EACA;EACA;EACA;;;iBAIgB,kBAAkB,iBAAiB,yBAAyB;EAC5E,SAAS;EACT,QAAQ;EACR;;;;;;;wBAYe;;;;;;;;;;;;;;;;;wBAwBA,eAAe,OAAO,uBAAuB;;;;;wBAY7C,qBAAqB,iBAAiB,wBACrD,mBAAmB,YACnB,iBAAiB,cACf,kBAAkB;;;;;;;wBA+CL,WACf,mBAAmB,eACnB,iBAAiB,aACjB,cACA,yBACA,6BACE;;wBAyCa,cACf,mBAAmB,eACnB,iBAAiB,aACjB,mBACA,kBACE;;;;;wBAWa,cACf,mBAAmB,eACnB,iBAAiB,aACjB,oBACE;;wBAiCa,cAAc,mBAAmB,eAAe,oBAAoB;;wBAWpE,gBACf,mBAAmB,eACnB,oBACE;;;;;wBAca,oBACf,mBAAmB,eACnB,iBAAiB,aACjB,iCACA,0BACE"}
|
|
@@ -1,3 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Slide-background patch builders for the Format Background controls.
|
|
3
|
+
*
|
|
4
|
+
* The stage paints a slide's background facets with a fixed precedence (image
|
|
5
|
+
* over gradient over pattern over solid colour, see `slide-background.ts`).
|
|
6
|
+
* PowerPoint's Format Background pane is exclusive: choosing a solid fill
|
|
7
|
+
* REPLACES a picture or gradient fill, and choosing a picture replaces the
|
|
8
|
+
* gradient. The panels used to patch a single facet, so picking a colour on a
|
|
9
|
+
* slide that carried a picture background changed nothing visible (the
|
|
10
|
+
* picture stayed on top) and the deck saved with both, which PowerPoint then
|
|
11
|
+
* rendered the same way.
|
|
12
|
+
*
|
|
13
|
+
* Pure decision functions: each returns the `PptxSlide` patch a binding hands
|
|
14
|
+
* to its slide-update operation.
|
|
15
|
+
*/
|
|
1
16
|
import { PptxSlide } from "ooxml-core/pptx";
|
|
2
17
|
/** Fields a background choice replaces. */
|
|
3
18
|
export type SlideBackgroundPatch = Pick<PptxSlide, 'backgroundColor' | 'backgroundImage' | 'backgroundGradient' | 'backgroundPattern'>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"slide-background-patch.d.ts","names":[],"sources":["../../../../pptx/editor/render/slide-background-patch.ts"],"mappings":"
|
|
1
|
+
{"version":3,"file":"slide-background-patch.d.ts","names":[],"sources":["../../../../pptx/editor/render/slide-background-patch.ts"],"mappings":";;;;;;;;;;;;;;;;;YAkBY,uBAAuB,KAClC;;;;;wBAQe,qBAAqB,cAAc;;;;;;wBAcnC,qBACf,kBACE,KAAK;;wBASQ,wBAAwB"}
|