wordinweb 0.2.4 → 0.2.5

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.
@@ -22802,8 +22802,39 @@ function insertWordArtAt(doc, caretT, text, preset = "plain") {
22802
22802
  if (color) color.attrs[Object.keys(color.attrs).find((key) => localName(key) === "val") ?? `${prefixOf8(color)}val`] = "2E74B5";
22803
22803
  if (size) size.attrs[Object.keys(size.attrs).find((key) => localName(key) === "val") ?? `${prefixOf8(size)}val`] = "40";
22804
22804
  }
22805
+ const paragraphProperties = descendant3(drawing, "pPr");
22806
+ const justification = paragraphProperties ? descendant3(paragraphProperties, "jc") : void 0;
22807
+ if (justification) {
22808
+ const valueKey = Object.keys(justification.attrs).find((key) => localName(key) === "val") ?? `${prefixOf8(justification)}val`;
22809
+ justification.attrs[valueKey] = "center";
22810
+ }
22805
22811
  const bodyPr = descendant3(drawing, "bodyPr");
22806
- if (bodyPr) bodyPr.children.unshift(el6("a:prstTxWarp", { prst: warp }, [el6("a:avLst")]));
22812
+ if (bodyPr) {
22813
+ bodyPr.attrs = {
22814
+ rot: "0",
22815
+ spcFirstLastPara: "1",
22816
+ vertOverflow: "overflow",
22817
+ horzOverflow: "overflow",
22818
+ vert: "horz",
22819
+ wrap: "none",
22820
+ lIns: "91440",
22821
+ tIns: "45720",
22822
+ rIns: "91440",
22823
+ bIns: "45720",
22824
+ numCol: "1",
22825
+ spcCol: "0",
22826
+ rtlCol: "0",
22827
+ fromWordArt: "0",
22828
+ anchor: "t",
22829
+ anchorCtr: "0",
22830
+ forceAA: "0",
22831
+ compatLnSpc: "1"
22832
+ };
22833
+ bodyPr.children = [
22834
+ el6("a:prstTxWarp", { prst: warp }, [el6("a:avLst")]),
22835
+ el6("a:noAutofit")
22836
+ ];
22837
+ }
22807
22838
  doc.refresh();
22808
22839
  return drawing;
22809
22840
  }
@@ -38409,4 +38440,4 @@ export {
38409
38440
  cfb/cfb.js:
38410
38441
  (*! crc32.js (C) 2014-present SheetJS -- http://sheetjs.com *)
38411
38442
  */
38412
- //# sourceMappingURL=chunk-QH2L3NPL.js.map
38443
+ //# sourceMappingURL=chunk-ALLQ5KWP.js.map