dwml-ts 0.5.1 → 0.5.2

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/index.js CHANGED
@@ -1,4 +1,5 @@
1
1
  import { parse } from "txml/txml";
2
+ import { decodeXML } from "entities";
2
3
  const UNI2LATEX = {
3
4
  34: "''",
4
5
  35: "\\#",
@@ -1946,7 +1947,7 @@ function isElement(node) {
1946
1947
  }
1947
1948
  function textContent(node) {
1948
1949
  let out = '';
1949
- for (const child of node.children)out += 'string' == typeof child ? child : textContent(child);
1950
+ for (const child of node.children)out += 'string' == typeof child ? decodeXML(child) : textContent(child);
1950
1951
  return out;
1951
1952
  }
1952
1953
  function pyFormat(template, positional = [], named = {}) {