@sobree/core 0.1.20 → 0.1.21
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/docx/import/anchoredFrames.d.ts +21 -0
- package/dist/index.js +1815 -1752
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
|
@@ -36,3 +36,24 @@ export interface AnchoredFramesContext {
|
|
|
36
36
|
* stable across re-imports of the same source.
|
|
37
37
|
*/
|
|
38
38
|
export declare function parseAnchoredFrames(xmlDoc: Document, ctx: AnchoredFramesContext, claim?: boolean): AnchoredFrame[];
|
|
39
|
+
/**
|
|
40
|
+
* Parse FLOATING legacy-VML objects — `<w:pict>` / `<w:object>` whose
|
|
41
|
+
* `<v:shape style="position:absolute;…">` pins them to page/margin
|
|
42
|
+
* coordinates (watermarks, full-page decorative backgrounds, logos
|
|
43
|
+
* placed by absolute position). DrawingML anchors are handled by
|
|
44
|
+
* `parseAnchoredFrames`; this is the VML-era equivalent and returns the
|
|
45
|
+
* same `AnchoredFrame` model, so the renderer is oblivious to the
|
|
46
|
+
* source format.
|
|
47
|
+
*
|
|
48
|
+
* ONLY floating VML is claimed here — gated on `position:absolute`.
|
|
49
|
+
* An INLINE VML picture (an OLE logo sitting in the text flow) has no
|
|
50
|
+
* such style; it stays in flow and `runs.ts` reads it as a `DrawingRun`.
|
|
51
|
+
* That distinction is what stops a header watermark from inflating the
|
|
52
|
+
* header's flow height (and shoving the body off the page) while
|
|
53
|
+
* leaving ordinary inline VML images untouched.
|
|
54
|
+
*
|
|
55
|
+
* Behind-text when the shape's `z-index` is negative (Word's "behind
|
|
56
|
+
* text" wrap). Claims (removes) the container so the body / flow walker
|
|
57
|
+
* never double-renders it.
|
|
58
|
+
*/
|
|
59
|
+
export declare function parseVmlFloatingFrames(xmlDoc: Document, ctx: AnchoredFramesContext, claim?: boolean): AnchoredFrame[];
|