@depup/mammoth 1.12.0-depup.54

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.
Files changed (118) hide show
  1. package/.eslintrc.json +75 -0
  2. package/.github/ISSUE_TEMPLATE.md +12 -0
  3. package/.github/pull_request_template.md +3 -0
  4. package/.github/workflows/tests.yml +26 -0
  5. package/LICENSE +22 -0
  6. package/NEWS +530 -0
  7. package/README.md +37 -0
  8. package/bin/mammoth +38 -0
  9. package/browser/docx/files.js +14 -0
  10. package/browser/unzip.js +12 -0
  11. package/changes.json +34 -0
  12. package/lib/document-to-html.js +469 -0
  13. package/lib/documents.js +254 -0
  14. package/lib/docx/body-reader.js +798 -0
  15. package/lib/docx/comments-reader.js +31 -0
  16. package/lib/docx/content-types-reader.js +58 -0
  17. package/lib/docx/document-xml-reader.js +30 -0
  18. package/lib/docx/docx-reader.js +226 -0
  19. package/lib/docx/files.js +80 -0
  20. package/lib/docx/notes-reader.js +28 -0
  21. package/lib/docx/numbering-xml.js +111 -0
  22. package/lib/docx/office-xml-reader.js +73 -0
  23. package/lib/docx/relationships-reader.js +43 -0
  24. package/lib/docx/style-map.js +75 -0
  25. package/lib/docx/styles-reader.js +90 -0
  26. package/lib/docx/uris.js +21 -0
  27. package/lib/html/ast.js +51 -0
  28. package/lib/html/index.js +41 -0
  29. package/lib/html/simplify.js +88 -0
  30. package/lib/images.js +31 -0
  31. package/lib/index.d.ts +86 -0
  32. package/lib/index.js +111 -0
  33. package/lib/main.js +63 -0
  34. package/lib/options-reader.js +107 -0
  35. package/lib/promises.js +42 -0
  36. package/lib/raw-text.js +14 -0
  37. package/lib/results.js +72 -0
  38. package/lib/style-reader.js +365 -0
  39. package/lib/styles/document-matchers.js +100 -0
  40. package/lib/styles/html-paths.js +75 -0
  41. package/lib/styles/parser/tokeniser.js +30 -0
  42. package/lib/transforms.js +62 -0
  43. package/lib/underline.js +11 -0
  44. package/lib/unzip.js +20 -0
  45. package/lib/writers/html-writer.js +159 -0
  46. package/lib/writers/index.js +14 -0
  47. package/lib/writers/markdown-writer.js +163 -0
  48. package/lib/xml/index.js +8 -0
  49. package/lib/xml/nodes.js +70 -0
  50. package/lib/xml/reader.js +69 -0
  51. package/lib/xml/writer.js +61 -0
  52. package/lib/xml/xmldom.js +23 -0
  53. package/lib/zipfile.js +72 -0
  54. package/mammoth.browser.js +22096 -0
  55. package/mammoth.browser.min.js +20 -0
  56. package/package.json +106 -0
  57. package/test/.eslintrc.json +7 -0
  58. package/test/document-to-html.tests.js +892 -0
  59. package/test/docx/body-reader.tests.js +2037 -0
  60. package/test/docx/comments-reader.tests.js +53 -0
  61. package/test/docx/content-types-reader.tests.js +45 -0
  62. package/test/docx/document-matchers.js +42 -0
  63. package/test/docx/document-xml-reader.tests.js +41 -0
  64. package/test/docx/docx-reader.tests.js +179 -0
  65. package/test/docx/files.tests.js +107 -0
  66. package/test/docx/notes-reader.tests.js +36 -0
  67. package/test/docx/numbering-xml.tests.js +183 -0
  68. package/test/docx/office-xml-reader.tests.js +41 -0
  69. package/test/docx/relationships-reader.tests.js +65 -0
  70. package/test/docx/style-map.tests.js +113 -0
  71. package/test/docx/styles-reader.tests.js +143 -0
  72. package/test/docx/testing.js +12 -0
  73. package/test/docx/uris.tests.js +22 -0
  74. package/test/html/simplify.tests.js +141 -0
  75. package/test/html/write.tests.js +42 -0
  76. package/test/images.tests.js +112 -0
  77. package/test/main.tests.js +89 -0
  78. package/test/mammoth.tests.js +523 -0
  79. package/test/mocha.opts +1 -0
  80. package/test/options-reader.tests.js +63 -0
  81. package/test/raw-text.tests.js +61 -0
  82. package/test/results.tests.js +15 -0
  83. package/test/style-reader.tests.js +291 -0
  84. package/test/styles/document-matchers.tests.js +91 -0
  85. package/test/styles/html-paths.tests.js +20 -0
  86. package/test/styles/parser/tokeniser.tests.js +104 -0
  87. package/test/test-data/comments.docx +0 -0
  88. package/test/test-data/embedded-style-map.docx +0 -0
  89. package/test/test-data/empty.docx +0 -0
  90. package/test/test-data/empty.zip +0 -0
  91. package/test/test-data/endnotes.docx +0 -0
  92. package/test/test-data/external-picture.docx +0 -0
  93. package/test/test-data/footnote-hyperlink.docx +0 -0
  94. package/test/test-data/footnotes.docx +0 -0
  95. package/test/test-data/hello.zip +0 -0
  96. package/test/test-data/hyperlinks/word/_rels/document.xml.rels +10 -0
  97. package/test/test-data/hyperlinks/word/document.xml +18 -0
  98. package/test/test-data/simple/word/document.xml +18 -0
  99. package/test/test-data/simple-list.docx +0 -0
  100. package/test/test-data/single-paragraph.docx +0 -0
  101. package/test/test-data/strict-format.docx +0 -0
  102. package/test/test-data/strikethrough.docx +0 -0
  103. package/test/test-data/tables.docx +0 -0
  104. package/test/test-data/text-box.docx +0 -0
  105. package/test/test-data/tiny-picture-target-base-relative.docx +0 -0
  106. package/test/test-data/tiny-picture.docx +0 -0
  107. package/test/test-data/tiny-picture.png +0 -0
  108. package/test/test-data/underline.docx +0 -0
  109. package/test/test-data/utf8-bom.docx +0 -0
  110. package/test/test.js +11 -0
  111. package/test/testing.js +55 -0
  112. package/test/transforms.tests.js +125 -0
  113. package/test/unzip.tests.js +38 -0
  114. package/test/writers/html-writer.tests.js +133 -0
  115. package/test/writers/markdown-writer.tests.js +304 -0
  116. package/test/xml/reader.tests.js +85 -0
  117. package/test/xml/writer.tests.js +81 -0
  118. package/test/zipfile.tests.js +61 -0
package/package.json ADDED
@@ -0,0 +1,106 @@
1
+ {
2
+ "name": "@depup/mammoth",
3
+ "version": "1.12.0-depup.54",
4
+ "author": "Michael Williamson <mike@zwobble.org>",
5
+ "description": "Convert Word documents from docx to simple HTML and Markdown (with updated dependencies)",
6
+ "keywords": [
7
+ "mammoth",
8
+ "depup",
9
+ "updated-dependencies",
10
+ "security",
11
+ "latest",
12
+ "patched",
13
+ "docx",
14
+ "html",
15
+ "office",
16
+ "word",
17
+ "markdown",
18
+ "md"
19
+ ],
20
+ "main": "./lib/index.js",
21
+ "repository": {
22
+ "type": "git",
23
+ "url": "https://github.com/mwilliamson/mammoth.js.git"
24
+ },
25
+ "dependencies": {
26
+ "@xmldom/xmldom": "^0.9.10",
27
+ "argparse": "^3.0.0",
28
+ "base64-js": "^1.5.1",
29
+ "bluebird": "^3.7.2",
30
+ "dingbat-to-unicode": "^1.0.1",
31
+ "jszip": "^3.10.1",
32
+ "lop": "^0.4.2",
33
+ "path-is-absolute": "^2.0.0",
34
+ "underscore": "^1.13.8",
35
+ "xmlbuilder": "^15.1.1"
36
+ },
37
+ "devDependencies": {
38
+ "@types/node": "^20.2.5",
39
+ "browserify": "~13.0.1",
40
+ "browserify-prepend-licenses": "~1.0.0",
41
+ "duck": "^0.1.12",
42
+ "eslint": "2.13.1",
43
+ "hamjest": "^4.0.1",
44
+ "mocha": "~2.2.5",
45
+ "temp": "^0.9.4",
46
+ "typescript": "^5.0.4",
47
+ "uglify-js": "~2.4.8"
48
+ },
49
+ "browser": {
50
+ "./lib/unzip.js": "./browser/unzip.js",
51
+ "./lib/docx/files.js": "./browser/docx/files.js"
52
+ },
53
+ "bin": {
54
+ "mammoth": "bin/mammoth"
55
+ },
56
+ "scripts": {
57
+ "pretest": "eslint lib test",
58
+ "test": "mocha 'test/**/*.tests.js'",
59
+ "check-typescript": "tsc --noEmit lib/index.d.ts"
60
+ },
61
+ "license": "BSD-2-Clause",
62
+ "engines": {
63
+ "node": ">=12.0.0"
64
+ },
65
+ "volta": {
66
+ "node": "16.18.1",
67
+ "npm": "8.19.2"
68
+ },
69
+ "depup": {
70
+ "changes": {
71
+ "@xmldom/xmldom": {
72
+ "from": "^0.8.6",
73
+ "to": "^0.9.10"
74
+ },
75
+ "argparse": {
76
+ "from": "~1.0.3",
77
+ "to": "^3.0.0"
78
+ },
79
+ "bluebird": {
80
+ "from": "~3.4.0",
81
+ "to": "^3.7.2"
82
+ },
83
+ "jszip": {
84
+ "from": "^3.7.1",
85
+ "to": "^3.10.1"
86
+ },
87
+ "path-is-absolute": {
88
+ "from": "^1.0.0",
89
+ "to": "^2.0.0"
90
+ },
91
+ "underscore": {
92
+ "from": "^1.13.1",
93
+ "to": "^1.13.8"
94
+ },
95
+ "xmlbuilder": {
96
+ "from": "^10.0.0",
97
+ "to": "^15.1.1"
98
+ }
99
+ },
100
+ "depsUpdated": 7,
101
+ "originalPackage": "mammoth",
102
+ "originalVersion": "1.12.0",
103
+ "processedAt": "2026-07-21T17:17:31.847Z",
104
+ "smokeTest": "passed"
105
+ }
106
+ }
@@ -0,0 +1,7 @@
1
+ {
2
+ "globals": {
3
+ "__dirname": false,
4
+ "describe": false,
5
+ "it": false
6
+ }
7
+ }