kordoc 4.25.13 → 4.25.14

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 (108) hide show
  1. package/README.md +2 -2
  2. package/dist/{chunk-6CHKXHKR.js → chunk-666E6PCD.js} +6 -6
  3. package/dist/{chunk-NEVZP6O3.js → chunk-6R5LKBDR.js} +2 -2
  4. package/dist/{chunk-NL4434I2.js → chunk-AI4QLMQ7.js} +2 -2
  5. package/dist/{chunk-QVZEBMYW.js → chunk-AX6H5A6L.js} +2 -2
  6. package/dist/{chunk-MQAUBK77.js → chunk-B4SR2WN2.js} +2 -2
  7. package/dist/{chunk-NLZ44M5L.js → chunk-CLNT4AC2.js} +6 -6
  8. package/dist/{chunk-RQPM72FM.js → chunk-CNTHWEXI.js} +2 -2
  9. package/dist/{chunk-NQXM6MED.js → chunk-DBWZXUE3.js} +2 -2
  10. package/dist/{chunk-ZRXXCZRZ.js → chunk-EDHMC2S4.js} +2 -2
  11. package/dist/{chunk-N2EOYLZX.js → chunk-EECP4SO4.js} +10 -10
  12. package/dist/{chunk-I52IXA2S.js → chunk-FVFK6NH4.js} +2 -2
  13. package/dist/{chunk-AII6CXYG.js → chunk-GYNZYVLJ.js} +2 -2
  14. package/dist/{chunk-32WLCR37.js → chunk-HKTFGBPF.js} +2 -2
  15. package/dist/{chunk-YSOBUGNT.js → chunk-I7YIGKSR.js} +6 -6
  16. package/dist/{chunk-VCLEQ7GS.js → chunk-IFOXI2IN.js} +3 -3
  17. package/dist/{chunk-CGXJE6Y5.js → chunk-ILMDSJ3Y.js} +5 -5
  18. package/dist/{chunk-4J2DUBJJ.js → chunk-ONJVFGL6.js} +2 -2
  19. package/dist/{chunk-TSEJQZ7C.js → chunk-OSPBEBQS.js} +2 -2
  20. package/dist/{chunk-KRP74WIV.js → chunk-P63SI5NQ.js} +8 -8
  21. package/dist/{chunk-DQDATFAC.js → chunk-PD4VKYKK.js} +8 -5
  22. package/dist/chunk-PD4VKYKK.js.map +1 -0
  23. package/dist/{chunk-BPY62DTT.js → chunk-RALNP6DD.js} +2 -2
  24. package/dist/{chunk-QYS4V2OA.js → chunk-SZVFIUCJ.js} +4 -4
  25. package/dist/{chunk-SKIWLEZA.js → chunk-U2ZH4OPZ.js} +3 -3
  26. package/dist/{chunk-SPFCULY3.js → chunk-VOE2HG2R.js} +2 -2
  27. package/dist/{chunk-C4TGNDQY.js → chunk-WBYMDKAB.js} +18 -18
  28. package/dist/{chunk-42FWJVN5.js → chunk-WSKQF3TO.js} +4 -4
  29. package/dist/chunks-RBGC7NVV.js +10 -0
  30. package/dist/cli.js +37 -37
  31. package/dist/{formula-ZM2EYXWB.js → formula-SYNYG6KB.js} +4 -4
  32. package/dist/{generator-AUA3RJD6.js → generator-CDSRPQUE.js} +7 -7
  33. package/dist/{hancom-M6DIM23B.js → hancom-267SACBC.js} +2 -2
  34. package/dist/{image-ocr-LZH6Q32C.js → image-ocr-4WPYRRML.js} +11 -11
  35. package/dist/index.cjs +6 -3
  36. package/dist/index.cjs.map +1 -1
  37. package/dist/index.js +21 -21
  38. package/dist/mcp.js +33 -33
  39. package/dist/memo-NZMDF2MD.js +15 -0
  40. package/dist/{model-bundle-C4A7JHYJ.js → model-bundle-5ZR57OO7.js} +5 -5
  41. package/dist/{models-K5FUWGWQ.js → models-NWC6OXOG.js} +5 -5
  42. package/dist/{page-images-O6SF454R.js → page-images-CDXNXG2T.js} +2 -2
  43. package/dist/{parse-worker-v2-Y7SF2Q6I.js → parse-worker-v2-7T5HXMWF.js} +23 -23
  44. package/dist/{parser-ZHK66LCI.js → parser-I37ALW6Y.js} +14 -14
  45. package/dist/{pdf-ocr-IU2UUBMJ.js → pdf-ocr-MYTZU6JE.js} +9 -9
  46. package/dist/{profile-io-ZF7UPT6V.js → profile-io-N3F5ZRKX.js} +3 -3
  47. package/dist/{rasterize-QO3NBE33.js → rasterize-LQSVOURH.js} +3 -3
  48. package/dist/{redact-doc-KIA2A3RM.js → redact-doc-UMBUDI6Y.js} +22 -22
  49. package/dist/{render-7UZDAEZ7.js → render-6EKZYXRH.js} +10 -10
  50. package/dist/{rewrite-fallback-YO6ZVEAI.js → rewrite-fallback-E3G5RVEC.js} +12 -12
  51. package/dist/seal-6OAT2P3O.js +14 -0
  52. package/dist/{setup-X5GNUS4Q.js → setup-U6FAD4LD.js} +3 -3
  53. package/dist/{to-hwpx-TE7TLCR5.js → to-hwpx-CRYZUOV6.js} +7 -7
  54. package/dist/visual-KRKJIJHO.js +42 -0
  55. package/dist/{watch-FMCC23HZ.js → watch-4ZWREI4Z.js} +22 -22
  56. package/package.json +1 -1
  57. package/dist/chunk-DQDATFAC.js.map +0 -1
  58. package/dist/chunks-SIAIY4VX.js +0 -10
  59. package/dist/memo-W2SNZRX5.js +0 -15
  60. package/dist/seal-W2BHUQA4.js +0 -14
  61. package/dist/visual-KFHP6RKA.js +0 -42
  62. /package/dist/{chunk-6CHKXHKR.js.map → chunk-666E6PCD.js.map} +0 -0
  63. /package/dist/{chunk-NEVZP6O3.js.map → chunk-6R5LKBDR.js.map} +0 -0
  64. /package/dist/{chunk-NL4434I2.js.map → chunk-AI4QLMQ7.js.map} +0 -0
  65. /package/dist/{chunk-QVZEBMYW.js.map → chunk-AX6H5A6L.js.map} +0 -0
  66. /package/dist/{chunk-MQAUBK77.js.map → chunk-B4SR2WN2.js.map} +0 -0
  67. /package/dist/{chunk-NLZ44M5L.js.map → chunk-CLNT4AC2.js.map} +0 -0
  68. /package/dist/{chunk-RQPM72FM.js.map → chunk-CNTHWEXI.js.map} +0 -0
  69. /package/dist/{chunk-NQXM6MED.js.map → chunk-DBWZXUE3.js.map} +0 -0
  70. /package/dist/{chunk-ZRXXCZRZ.js.map → chunk-EDHMC2S4.js.map} +0 -0
  71. /package/dist/{chunk-N2EOYLZX.js.map → chunk-EECP4SO4.js.map} +0 -0
  72. /package/dist/{chunk-I52IXA2S.js.map → chunk-FVFK6NH4.js.map} +0 -0
  73. /package/dist/{chunk-AII6CXYG.js.map → chunk-GYNZYVLJ.js.map} +0 -0
  74. /package/dist/{chunk-32WLCR37.js.map → chunk-HKTFGBPF.js.map} +0 -0
  75. /package/dist/{chunk-YSOBUGNT.js.map → chunk-I7YIGKSR.js.map} +0 -0
  76. /package/dist/{chunk-VCLEQ7GS.js.map → chunk-IFOXI2IN.js.map} +0 -0
  77. /package/dist/{chunk-CGXJE6Y5.js.map → chunk-ILMDSJ3Y.js.map} +0 -0
  78. /package/dist/{chunk-4J2DUBJJ.js.map → chunk-ONJVFGL6.js.map} +0 -0
  79. /package/dist/{chunk-TSEJQZ7C.js.map → chunk-OSPBEBQS.js.map} +0 -0
  80. /package/dist/{chunk-KRP74WIV.js.map → chunk-P63SI5NQ.js.map} +0 -0
  81. /package/dist/{chunk-BPY62DTT.js.map → chunk-RALNP6DD.js.map} +0 -0
  82. /package/dist/{chunk-QYS4V2OA.js.map → chunk-SZVFIUCJ.js.map} +0 -0
  83. /package/dist/{chunk-SKIWLEZA.js.map → chunk-U2ZH4OPZ.js.map} +0 -0
  84. /package/dist/{chunk-SPFCULY3.js.map → chunk-VOE2HG2R.js.map} +0 -0
  85. /package/dist/{chunk-C4TGNDQY.js.map → chunk-WBYMDKAB.js.map} +0 -0
  86. /package/dist/{chunk-42FWJVN5.js.map → chunk-WSKQF3TO.js.map} +0 -0
  87. /package/dist/{chunks-SIAIY4VX.js.map → chunks-RBGC7NVV.js.map} +0 -0
  88. /package/dist/{formula-ZM2EYXWB.js.map → formula-SYNYG6KB.js.map} +0 -0
  89. /package/dist/{generator-AUA3RJD6.js.map → generator-CDSRPQUE.js.map} +0 -0
  90. /package/dist/{hancom-M6DIM23B.js.map → hancom-267SACBC.js.map} +0 -0
  91. /package/dist/{image-ocr-LZH6Q32C.js.map → image-ocr-4WPYRRML.js.map} +0 -0
  92. /package/dist/{memo-W2SNZRX5.js.map → memo-NZMDF2MD.js.map} +0 -0
  93. /package/dist/{model-bundle-C4A7JHYJ.js.map → model-bundle-5ZR57OO7.js.map} +0 -0
  94. /package/dist/{models-K5FUWGWQ.js.map → models-NWC6OXOG.js.map} +0 -0
  95. /package/dist/{page-images-O6SF454R.js.map → page-images-CDXNXG2T.js.map} +0 -0
  96. /package/dist/{parse-worker-v2-Y7SF2Q6I.js.map → parse-worker-v2-7T5HXMWF.js.map} +0 -0
  97. /package/dist/{parser-ZHK66LCI.js.map → parser-I37ALW6Y.js.map} +0 -0
  98. /package/dist/{pdf-ocr-IU2UUBMJ.js.map → pdf-ocr-MYTZU6JE.js.map} +0 -0
  99. /package/dist/{profile-io-ZF7UPT6V.js.map → profile-io-N3F5ZRKX.js.map} +0 -0
  100. /package/dist/{rasterize-QO3NBE33.js.map → rasterize-LQSVOURH.js.map} +0 -0
  101. /package/dist/{redact-doc-KIA2A3RM.js.map → redact-doc-UMBUDI6Y.js.map} +0 -0
  102. /package/dist/{render-7UZDAEZ7.js.map → render-6EKZYXRH.js.map} +0 -0
  103. /package/dist/{rewrite-fallback-YO6ZVEAI.js.map → rewrite-fallback-E3G5RVEC.js.map} +0 -0
  104. /package/dist/{seal-W2BHUQA4.js.map → seal-6OAT2P3O.js.map} +0 -0
  105. /package/dist/{setup-X5GNUS4Q.js.map → setup-U6FAD4LD.js.map} +0 -0
  106. /package/dist/{to-hwpx-TE7TLCR5.js.map → to-hwpx-CRYZUOV6.js.map} +0 -0
  107. /package/dist/{visual-KFHP6RKA.js.map → visual-KRKJIJHO.js.map} +0 -0
  108. /package/dist/{watch-FMCC23HZ.js.map → watch-4ZWREI4Z.js.map} +0 -0
@@ -1,6 +1,6 @@
1
1
  // src/utils.ts
2
2
  import { format } from "util";
3
- var VERSION = true ? "4.25.13" : "0.0.0-dev";
3
+ var VERSION = true ? "4.25.14" : "0.0.0-dev";
4
4
  function toArrayBuffer(buf) {
5
5
  if (buf.byteOffset === 0 && buf.byteLength === buf.buffer.byteLength) {
6
6
  return buf.buffer;
@@ -195,4 +195,4 @@ export {
195
195
  classifyError,
196
196
  partExtension
197
197
  };
198
- //# sourceMappingURL=chunk-BPY62DTT.js.map
198
+ //# sourceMappingURL=chunk-RALNP6DD.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  patchZipEntries
3
- } from "./chunk-I52IXA2S.js";
3
+ } from "./chunk-FVFK6NH4.js";
4
4
  import {
5
5
  applySplices,
6
6
  scanSectionXml
@@ -8,11 +8,11 @@ import {
8
8
  import {
9
9
  parseRenderStyles,
10
10
  readZipEntry
11
- } from "./chunk-QVZEBMYW.js";
11
+ } from "./chunk-AX6H5A6L.js";
12
12
  import {
13
13
  KordocError,
14
14
  precheckZipSize
15
- } from "./chunk-BPY62DTT.js";
15
+ } from "./chunk-RALNP6DD.js";
16
16
 
17
17
  // src/form/seal.ts
18
18
  import JSZip from "jszip";
@@ -318,4 +318,4 @@ export {
318
318
  collectSites,
319
319
  placeSealHwpx
320
320
  };
321
- //# sourceMappingURL=chunk-QYS4V2OA.js.map
321
+ //# sourceMappingURL=chunk-SZVFIUCJ.js.map
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  parse
3
- } from "./chunk-C4TGNDQY.js";
3
+ } from "./chunk-WBYMDKAB.js";
4
4
  import {
5
5
  classifyError,
6
6
  sanitizeError,
7
7
  toArrayBuffer
8
- } from "./chunk-BPY62DTT.js";
8
+ } from "./chunk-RALNP6DD.js";
9
9
 
10
10
  // src/cli/worker-parse.ts
11
11
  import { readFile, stat } from "fs/promises";
@@ -25,4 +25,4 @@ async function parseWorkerFile(absPath, options) {
25
25
  export {
26
26
  parseWorkerFile
27
27
  };
28
- //# sourceMappingURL=chunk-SKIWLEZA.js.map
28
+ //# sourceMappingURL=chunk-U2ZH4OPZ.js.map
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  KordocError
3
- } from "./chunk-BPY62DTT.js";
3
+ } from "./chunk-RALNP6DD.js";
4
4
 
5
5
  // src/shared/offline.ts
6
6
  import { realpathSync } from "fs";
@@ -48,4 +48,4 @@ export {
48
48
  getAccessRoot,
49
49
  assertWithinRoot
50
50
  };
51
- //# sourceMappingURL=chunk-SPFCULY3.js.map
51
+ //# sourceMappingURL=chunk-VOE2HG2R.js.map
@@ -1,7 +1,7 @@
1
1
  import {
2
2
  extractRenderedRegions,
3
3
  renderDocumentToScene
4
- } from "./chunk-KRP74WIV.js";
4
+ } from "./chunk-P63SI5NQ.js";
5
5
  import {
6
6
  EV,
7
7
  blocksToPages,
@@ -17,7 +17,7 @@ import {
17
17
  restoreUnmappedGlyphs,
18
18
  spaceMappedDots,
19
19
  wmfBitmap
20
- } from "./chunk-AII6CXYG.js";
20
+ } from "./chunk-GYNZYVLJ.js";
21
21
  import {
22
22
  applyCellEdit,
23
23
  buildOrigUnits,
@@ -30,13 +30,13 @@ import {
30
30
  resolveParagraphMappings,
31
31
  resolveSectionEntryNames,
32
32
  stripCellTokens
33
- } from "./chunk-N2EOYLZX.js";
33
+ } from "./chunk-EECP4SO4.js";
34
34
  import {
35
35
  dcxPages,
36
36
  hasLibheif,
37
37
  heicToRgba,
38
38
  pcxToRgba
39
- } from "./chunk-32WLCR37.js";
39
+ } from "./chunk-HKTFGBPF.js";
40
40
  import {
41
41
  WEBP_OPTIONS,
42
42
  flushHeifCache,
@@ -69,10 +69,10 @@ import {
69
69
  summarize,
70
70
  topLevelParagraphs,
71
71
  usesV5Engine
72
- } from "./chunk-6CHKXHKR.js";
72
+ } from "./chunk-666E6PCD.js";
73
73
  import {
74
74
  patchZipEntries
75
- } from "./chunk-I52IXA2S.js";
75
+ } from "./chunk-FVFK6NH4.js";
76
76
  import {
77
77
  ANNOTATION_BLANK_RE,
78
78
  ValueCursor,
@@ -111,7 +111,7 @@ import {
111
111
  rawTextContent,
112
112
  readZipEntry,
113
113
  warnInto
114
- } from "./chunk-QVZEBMYW.js";
114
+ } from "./chunk-AX6H5A6L.js";
115
115
  import {
116
116
  comResultToParseResult,
117
117
  extractTextViaCom,
@@ -128,7 +128,7 @@ import {
128
128
  memosMarkdown,
129
129
  parseHwp5Document,
130
130
  resolveImageBlocks
131
- } from "./chunk-CGXJE6Y5.js";
131
+ } from "./chunk-ILMDSJ3Y.js";
132
132
  import {
133
133
  MAX_PIXELS,
134
134
  bmpToPng,
@@ -166,7 +166,7 @@ import {
166
166
  stripScriptTags,
167
167
  tidyScriptTags,
168
168
  wrapScript
169
- } from "./chunk-NL4434I2.js";
169
+ } from "./chunk-AI4QLMQ7.js";
170
170
  import {
171
171
  MAX_COLS,
172
172
  MAX_ROWS,
@@ -177,7 +177,7 @@ import {
177
177
  flattenLayoutTables,
178
178
  hasStructuredCellContent,
179
179
  sanitizeText
180
- } from "./chunk-MQAUBK77.js";
180
+ } from "./chunk-B4SR2WN2.js";
181
181
  import {
182
182
  hangulAmount,
183
183
  mapPuaText
@@ -188,7 +188,7 @@ import {
188
188
  import {
189
189
  ensureModelsIn,
190
190
  getModelsDir
191
- } from "./chunk-NEVZP6O3.js";
191
+ } from "./chunk-6R5LKBDR.js";
192
192
  import {
193
193
  BARE_URL,
194
194
  KordocError,
@@ -206,7 +206,7 @@ import {
206
206
  toArrayBuffer,
207
207
  unescapeHtml,
208
208
  unzipLimitBytes
209
- } from "./chunk-BPY62DTT.js";
209
+ } from "./chunk-RALNP6DD.js";
210
210
 
211
211
  // src/table/visual.ts
212
212
  import { readFile as readFile4 } from "node:fs/promises";
@@ -16984,7 +16984,7 @@ var MIN_SIDE = 24;
16984
16984
  async function ocrEmbeddedImages(blocks, options, warnings) {
16985
16985
  const ocr = options?.ocr;
16986
16986
  if (ocr !== true && ocr !== "force" && typeof ocr !== "function") return false;
16987
- const { parseImageDocument } = await import("./image-ocr-LZH6Q32C.js");
16987
+ const { parseImageDocument } = await import("./image-ocr-4WPYRRML.js");
16988
16988
  let inserted = false, unreadable = 0;
16989
16989
  let failed = null;
16990
16990
  const walk = async (list, depth) => {
@@ -21342,8 +21342,8 @@ var MAX_MULTIPAGE_PIXELS = 1e9;
21342
21342
  var MIN_PAGE_PIXELS = 1e6;
21343
21343
  async function parseImage(buffer, options) {
21344
21344
  try {
21345
- const { parseImageDocument, imagePageCount, imagePage, imagePagePixels, decodeToRgba } = await import("./image-ocr-LZH6Q32C.js");
21346
- const pageRasters = options?.pageImages ? new (await import("./page-images-O6SF454R.js")).PageImageSink(options.pageImages) : null;
21345
+ const { parseImageDocument, imagePageCount, imagePage, imagePagePixels, decodeToRgba } = await import("./image-ocr-4WPYRRML.js");
21346
+ const pageRasters = options?.pageImages ? new (await import("./page-images-CDXNXG2T.js")).PageImageSink(options.pageImages) : null;
21347
21347
  const pageCount = await imagePageCount(buffer);
21348
21348
  const wanted = pageCount > 1 && options?.pages ? parsePageRange(options.pages, pageCount) : null;
21349
21349
  const blocks = [], warnings = [], lines = [], images = [];
@@ -21450,7 +21450,7 @@ async function parseHwp(buffer, options) {
21450
21450
  async function parsePdf(buffer, options) {
21451
21451
  let parsePdfDocument;
21452
21452
  try {
21453
- const mod = await import("./parser-ZHK66LCI.js");
21453
+ const mod = await import("./parser-I37ALW6Y.js");
21454
21454
  parsePdfDocument = mod.parsePdfDocument;
21455
21455
  } catch (err) {
21456
21456
  return { success: false, fileType: "pdf", error: sanitizeError(err), code: classifyError(err) };
@@ -21527,7 +21527,7 @@ async function fillForm(input, values, outputFormat = "markdown") {
21527
21527
  throw new Error(`hwpx-preserve 포맷은 HWPX·HWP 5.x 입력만 지원합니다 (감지된 포맷: ${zipFormat})`);
21528
21528
  }
21529
21529
  } else if (format2 === "hwp" && detectOle2Format(buffer) === "hwp") {
21530
- const { hwpToHwpx: hwpToHwpx2 } = await import("./to-hwpx-TE7TLCR5.js");
21530
+ const { hwpToHwpx: hwpToHwpx2 } = await import("./to-hwpx-CRYZUOV6.js");
21531
21531
  const hwpx = await hwpToHwpx2(new Uint8Array(buffer));
21532
21532
  buffer = hwpx.buffer.slice(hwpx.byteOffset, hwpx.byteOffset + hwpx.byteLength);
21533
21533
  } else {
@@ -21683,4 +21683,4 @@ export {
21683
21683
  parseHwpml,
21684
21684
  fillForm
21685
21685
  };
21686
- //# sourceMappingURL=chunk-C4TGNDQY.js.map
21686
+ //# sourceMappingURL=chunk-WBYMDKAB.js.map
@@ -29,7 +29,7 @@ import {
29
29
  stackedGlyphBands,
30
30
  starRun,
31
31
  tallInkCount
32
- } from "./chunk-DQDATFAC.js";
32
+ } from "./chunk-PD4VKYKK.js";
33
33
  import {
34
34
  validateOcrOptions
35
35
  } from "./chunk-67I4YNFQ.js";
@@ -45,14 +45,14 @@ import {
45
45
  ocrSourcePath,
46
46
  parseCharacterDict,
47
47
  resolveOcrModels
48
- } from "./chunk-4J2DUBJJ.js";
48
+ } from "./chunk-ONJVFGL6.js";
49
49
  import {
50
50
  disableOrtTelemetry
51
51
  } from "./chunk-AY66PEUP.js";
52
52
  import {
53
53
  KordocError,
54
54
  OPTIONAL_DEP_INSTALL_HINT
55
- } from "./chunk-BPY62DTT.js";
55
+ } from "./chunk-RALNP6DD.js";
56
56
 
57
57
  // src/ocr/ocr-stacked-rows.ts
58
58
  var NUMERIC = /^[-+−△▲▽▼]?[\d.,]+[%p원]?$|^[-–—·∼~]원?$|^\([-+−△▲▽▼]?[\d.,]+%?\)$/;
@@ -3669,4 +3669,4 @@ export {
3669
3669
  ocrItemsToBlocks,
3670
3670
  markOcrHeadings
3671
3671
  };
3672
- //# sourceMappingURL=chunk-42FWJVN5.js.map
3672
+ //# sourceMappingURL=chunk-WSKQF3TO.js.map
@@ -0,0 +1,10 @@
1
+ import {
2
+ blocksToChunks
3
+ } from "./chunk-EDHMC2S4.js";
4
+ import "./chunk-B4SR2WN2.js";
5
+ import "./chunk-QXQX4AN7.js";
6
+ import "./chunk-RALNP6DD.js";
7
+ export {
8
+ blocksToChunks
9
+ };
10
+ //# sourceMappingURL=chunks-RBGC7NVV.js.map
package/dist/cli.js CHANGED
@@ -1,10 +1,10 @@
1
1
  #!/usr/bin/env node
2
2
  import {
3
3
  parseWorkerFile
4
- } from "./chunk-SKIWLEZA.js";
4
+ } from "./chunk-U2ZH4OPZ.js";
5
5
  import {
6
6
  parseFormatProfileJson
7
- } from "./chunk-TSEJQZ7C.js";
7
+ } from "./chunk-OSPBEBQS.js";
8
8
  import {
9
9
  BODY_FONTS,
10
10
  BULLET2_CHARS,
@@ -50,14 +50,14 @@ import {
50
50
  unknownFontWarnings,
51
51
  usesGaejosikMunche,
52
52
  usesLogicStructure
53
- } from "./chunk-C4TGNDQY.js";
54
- import "./chunk-KRP74WIV.js";
55
- import "./chunk-NQXM6MED.js";
56
- import "./chunk-AII6CXYG.js";
53
+ } from "./chunk-WBYMDKAB.js";
54
+ import "./chunk-P63SI5NQ.js";
55
+ import "./chunk-DBWZXUE3.js";
56
+ import "./chunk-GYNZYVLJ.js";
57
57
  import {
58
58
  extractClickHereFields
59
- } from "./chunk-N2EOYLZX.js";
60
- import "./chunk-32WLCR37.js";
59
+ } from "./chunk-EECP4SO4.js";
60
+ import "./chunk-HKTFGBPF.js";
61
61
  import "./chunk-YVFNHYJK.js";
62
62
  import {
63
63
  PRESET_ALIAS,
@@ -66,11 +66,11 @@ import {
66
66
  markdownToHwpx,
67
67
  parseLeadingMarker,
68
68
  resolveSectionPaths
69
- } from "./chunk-6CHKXHKR.js";
70
- import "./chunk-VCLEQ7GS.js";
71
- import "./chunk-YSOBUGNT.js";
72
- import "./chunk-QYS4V2OA.js";
73
- import "./chunk-I52IXA2S.js";
69
+ } from "./chunk-666E6PCD.js";
70
+ import "./chunk-IFOXI2IN.js";
71
+ import "./chunk-I7YIGKSR.js";
72
+ import "./chunk-SZVFIUCJ.js";
73
+ import "./chunk-FVFK6NH4.js";
74
74
  import {
75
75
  extractFormFields,
76
76
  fillPlan,
@@ -79,20 +79,20 @@ import {
79
79
  import {
80
80
  createXmlParser,
81
81
  readZipEntry
82
- } from "./chunk-QVZEBMYW.js";
82
+ } from "./chunk-AX6H5A6L.js";
83
83
  import "./chunk-IXQ45P43.js";
84
84
  import {
85
85
  hwpToHwpx
86
- } from "./chunk-NLZ44M5L.js";
86
+ } from "./chunk-CLNT4AC2.js";
87
87
  import {
88
88
  detectImageMime
89
- } from "./chunk-CGXJE6Y5.js";
89
+ } from "./chunk-ILMDSJ3Y.js";
90
90
  import "./chunk-PCOKS4ZE.js";
91
91
  import "./chunk-AASNBZDZ.js";
92
- import "./chunk-RQPM72FM.js";
92
+ import "./chunk-CNTHWEXI.js";
93
93
  import "./chunk-WIIPAV2D.js";
94
94
  import "./chunk-F5EARPSA.js";
95
- import "./chunk-ZRXXCZRZ.js";
95
+ import "./chunk-EDHMC2S4.js";
96
96
  import "./chunk-Y56TLZ42.js";
97
97
  import {
98
98
  detectFormat,
@@ -102,14 +102,14 @@ import "./chunk-Y6BVOW4Y.js";
102
102
  import "./chunk-DUAZNEQ6.js";
103
103
  import "./chunk-67I4YNFQ.js";
104
104
  import "./chunk-L3U4XTBO.js";
105
- import "./chunk-NL4434I2.js";
105
+ import "./chunk-AI4QLMQ7.js";
106
106
  import {
107
107
  blocksToMarkdown
108
- } from "./chunk-MQAUBK77.js";
108
+ } from "./chunk-B4SR2WN2.js";
109
109
  import "./chunk-QXQX4AN7.js";
110
110
  import "./chunk-AY66PEUP.js";
111
- import "./chunk-NEVZP6O3.js";
112
- import "./chunk-SPFCULY3.js";
111
+ import "./chunk-6R5LKBDR.js";
112
+ import "./chunk-VOE2HG2R.js";
113
113
  import {
114
114
  KordocError,
115
115
  VERSION,
@@ -119,7 +119,7 @@ import {
119
119
  sanitizeError,
120
120
  stripDtd,
121
121
  toArrayBuffer
122
- } from "./chunk-BPY62DTT.js";
122
+ } from "./chunk-RALNP6DD.js";
123
123
 
124
124
  // src/cli.ts
125
125
  import { Command, Option } from "commander";
@@ -270,7 +270,7 @@ async function convertFiles(files, opts, writeOutput = (text) => {
270
270
  `);
271
271
  }
272
272
  } else if (opts.format === "chunks") {
273
- const { blocksToChunks } = await import("./chunks-SIAIY4VX.js");
273
+ const { blocksToChunks } = await import("./chunks-RBGC7NVV.js");
274
274
  const chunks = blocksToChunks(result.blocks, { tableFormat: parseOptions.tableFormat }).map((c) => {
275
275
  let text = c.text;
276
276
  if (opts.plain) text = toPlainMarkdown(text);
@@ -454,7 +454,7 @@ function registerDocCommands(program2) {
454
454
  if (command.getOptionValueSource("format") === "default" && program2.getOptionValueSource("format") === "cli") {
455
455
  opts.format = rootOpts.format;
456
456
  }
457
- const { watchDirectory } = await import("./watch-FMCC23HZ.js");
457
+ const { watchDirectory } = await import("./watch-4ZWREI4Z.js");
458
458
  await watchDirectory({
459
459
  dir,
460
460
  outDir: opts.outDir,
@@ -853,7 +853,7 @@ function registerDocCommands(program2) {
853
853
  const result = format === "hwp" ? await patchHwp(originalBuf, editedMarkdown, { verify: opts.verify !== false, keepLineseg: opts.keepLineseg === true }) : await patchHwpx(originalBuf, editedMarkdown, { verify: opts.verify !== false, structure: opts.structure !== false });
854
854
  const ext = format === "hwp" ? ".hwp" : ".hwpx";
855
855
  const outPath = resolve3(output ?? original.replace(/\.hwpx?$/i, "") + ".patched" + ext);
856
- const { needsRewrite, rewriteEdited, rewritePath } = await import("./rewrite-fallback-YO6ZVEAI.js");
856
+ const { needsRewrite, rewriteEdited, rewritePath } = await import("./rewrite-fallback-E3G5RVEC.js");
857
857
  const rewrite = needsRewrite(result) ? await rewriteEdited(originalBuf, format !== "hwp", editedMarkdown, result.success) : null;
858
858
  const rewriteOut = rewrite ? rewritePath(outPath) : void 0;
859
859
  if (rewrite && rewriteOut) {
@@ -1737,7 +1737,7 @@ function registerGenerateCommands(program2) {
1737
1737
  });
1738
1738
  program2.command("redact <files...>").description("개인정보 서식 보존 마스킹 — 주민·외국인등록번호·전화·이메일·카드·계좌·사업자등록번호·여권·운전면허(--rules 로 인명·주소 opt-in)를 탐지해 HWPX/HWP는 원본 서식 그대로 같은 길이로 가린 파일(본문·표·머리말/꼬리말·각주·글상자·미리보기·메타데이터 포함), 그 외 포맷(PDF 등)은 원본을 건드리지 않고 마스킹된 마크다운만 출력. 자동 검출 보조 도구이므로 결과는 반드시 사람이 최종 확인하세요 (이미지 속 글자는 탐지 불가)").option("--rules <csv>", "적용 룰 (기본: rrn,phone,email,card,account,brn,passport,driver — crn(법인등록번호),ip,name(인명),address(주소)는 opt-in)").option("--model [variant]", "인명·주소를 학습 모델(schift-ko-pii-ax-v1)로도 탐지 — name·address 룰을 함께 켬. variant: int8(기본, 처음 151MB 받음)·q4(81MB). onnxruntime-node 필요, 모델은 Schift License v2.0").option("--mask-char <ch>", "마스크 문자 1글자 (기본: ●)").option("-o, --output <path>", "출력 경로 (단일 파일 시)").option("-d, --out-dir <dir>", "출력 디렉토리 (다중 파일 시)").option("--dry-run", "탐지 리포트만 출력, 파일 미생성").option("--json", "리포트를 JSON으로 stdout 출력").option("--silent", "진행 메시지 숨기기").action(async (files, opts) => {
1739
1739
  const { ALL_REDACT_RULES, DEFAULT_REDACT_RULES, redactText } = await import("./redact-JY72ESQ6.js");
1740
- const { redactDocument } = await import("./redact-doc-KIA2A3RM.js");
1740
+ const { redactDocument } = await import("./redact-doc-UMBUDI6Y.js");
1741
1741
  const rootOpts = program2.opts();
1742
1742
  const output = opts.output ?? rootOpts.output;
1743
1743
  const outDir = opts.outDir ?? rootOpts.outDir;
@@ -1958,7 +1958,7 @@ function registerRenderCommands(program2) {
1958
1958
  const absPath = resolve7(file);
1959
1959
  const stem = file.replace(/\.hwpx?$/i, "");
1960
1960
  if (fmt === "svg" && !outDir && !pages && !/\.hwp$/i.test(absPath)) {
1961
- const { renderHwpxToSvg } = await import("./render-7UZDAEZ7.js");
1961
+ const { renderHwpxToSvg } = await import("./render-6EKZYXRH.js");
1962
1962
  const buffer = readFileSync6(absPath);
1963
1963
  const result = await renderHwpxToSvg(toArrayBuffer(buffer), { highlights, reflow: opts.reflow, reflowMode: opts.reflowMode, password: rootOpts.password });
1964
1964
  const outPath = resolve7(output ?? stem + ".svg");
@@ -1972,7 +1972,7 @@ function registerRenderCommands(program2) {
1972
1972
  }
1973
1973
  return;
1974
1974
  }
1975
- const { renderDocument } = await import("./render-7UZDAEZ7.js");
1975
+ const { renderDocument } = await import("./render-6EKZYXRH.js");
1976
1976
  const { scene, assets } = await renderDocument(absPath, {
1977
1977
  format: fmt,
1978
1978
  pages,
@@ -2023,7 +2023,7 @@ function registerRenderCommands(program2) {
2023
2023
  if (!outDir) throw new KordocError("--out-dir 이 필요합니다 (crop 은 파일 여러 개를 냅니다)");
2024
2024
  const types = String(opts.target).split(",").map((t) => t.trim()).filter(Boolean);
2025
2025
  for (const t of types) if (!["table", "image", "paragraph", "shape"].includes(t)) throw new KordocError(`--target 유형 오류: ${t}`);
2026
- const { extractRenderedRegions } = await import("./render-7UZDAEZ7.js");
2026
+ const { extractRenderedRegions } = await import("./render-6EKZYXRH.js");
2027
2027
  const regions = await extractRenderedRegions(resolve7(file), {
2028
2028
  types,
2029
2029
  format: fmt,
@@ -2061,7 +2061,7 @@ function registerRenderCommands(program2) {
2061
2061
  if (policy !== "none" && !outDir) throw new KordocError("--visual 은 crop 파일을 내므로 --out-dir 이 필요합니다");
2062
2062
  const cropFmt = String(opts.cropFormat);
2063
2063
  if (!["png", "jpeg"].includes(cropFmt)) throw new KordocError(`--crop-format 은 png|jpeg: ${cropFmt}`);
2064
- const { extractTables } = await import("./visual-KFHP6RKA.js");
2064
+ const { extractTables } = await import("./visual-KRKJIJHO.js");
2065
2065
  const tables = await extractTables(resolve7(file), { policy, format: cropFmt, paddingPt: Number(opts.padding) || 0 });
2066
2066
  const dir = outDir ? resolve7(outDir) : void 0;
2067
2067
  if (dir) mkdirSync6(dir, { recursive: true });
@@ -2105,7 +2105,7 @@ function registerRenderCommands(program2) {
2105
2105
  });
2106
2106
  program2.command("render-worker").description("persistent 렌더 워커 — stdin NDJSON 요청 → 조판 SVG 파일 출력 (프로세스 유지, 콜드스타트 제거)").action(async () => {
2107
2107
  const { createInterface } = await import("node:readline");
2108
- const { renderHwpxToSvg } = await import("./render-7UZDAEZ7.js");
2108
+ const { renderHwpxToSvg } = await import("./render-6EKZYXRH.js");
2109
2109
  const rl = createInterface({ input: process.stdin });
2110
2110
  const write = (o) => void process.stdout.write(JSON.stringify(o) + "\n");
2111
2111
  write({ ready: true, version: VERSION });
@@ -2154,12 +2154,12 @@ function registerSystemCommands(program2) {
2154
2154
  await startMcpServer();
2155
2155
  });
2156
2156
  program2.command("setup").description("대화형 설치 마법사 — AI 클라이언트 자동 등록 (Mac/Win/Linux)").action(async () => {
2157
- const { runSetup } = await import("./setup-X5GNUS4Q.js");
2157
+ const { runSetup } = await import("./setup-U6FAD4LD.js");
2158
2158
  await runSetup();
2159
2159
  });
2160
2160
  program2.command("check-formula-models").description("PDF 수식 OCR 모델(MFD + MFR + tokenizer, ~155MB) 상태 확인 — 없거나 SHA 불일치면 다운로드").option("--status-only", "상태만 JSON 으로 출력 (다운로드 안 함)").action(async (opts) => {
2161
2161
  try {
2162
- const { getFormulaModelStatus, ensureFormulaModels, getFormulaModelsDir } = await import("./formula-ZM2EYXWB.js");
2162
+ const { getFormulaModelStatus, ensureFormulaModels, getFormulaModelsDir } = await import("./formula-SYNYG6KB.js");
2163
2163
  const dir = getFormulaModelsDir();
2164
2164
  if (opts.statusOnly) {
2165
2165
  const status = await getFormulaModelStatus();
@@ -2213,7 +2213,7 @@ function registerSystemCommands(program2) {
2213
2213
  });
2214
2214
  program2.command("check-ocr-models").description("텍스트 OCR 모델(PP-OCRv5 korean det+rec, ~18MB) 상태 확인 — 없거나 SHA 불일치면 다운로드").option("--status-only", "상태만 JSON 으로 출력 (다운로드 안 함)").action(async (opts) => {
2215
2215
  try {
2216
- const { getOcrModelStatus, ensureOcrModels, getOcrModelsDir } = await import("./models-K5FUWGWQ.js");
2216
+ const { getOcrModelStatus, ensureOcrModels, getOcrModelsDir } = await import("./models-NWC6OXOG.js");
2217
2217
  const dir = getOcrModelsDir();
2218
2218
  if (opts.statusOnly) {
2219
2219
  const status = await getOcrModelStatus();
@@ -2267,7 +2267,7 @@ function registerSystemCommands(program2) {
2267
2267
  });
2268
2268
  program2.command("models").description("OCR/수식 모델 오프라인 사이드로드 — 폐쇄망 반입용 내보내기/가져오기 (SHA-256 검증)").option("--status", "캐시에 설치된 모델 상태를 JSON 으로 출력").option("--export <dir>", "로컬 캐시 → 번들 디렉토리로 내보내기 (온라인 PC에서 실행)").option("--import <dir>", "번들 디렉토리 → 로컬 캐시로 설치 (내부망 PC에서 실행)").action(async (opts) => {
2269
2269
  try {
2270
- const { exportModels, importModels, modelCacheStatus } = await import("./model-bundle-C4A7JHYJ.js");
2270
+ const { exportModels, importModels, modelCacheStatus } = await import("./model-bundle-5ZR57OO7.js");
2271
2271
  if (opts.status) {
2272
2272
  process.stdout.write(JSON.stringify(await modelCacheStatus(), null, 2) + "\n");
2273
2273
  return;
@@ -2333,7 +2333,7 @@ function registerWorkerCommands(program2) {
2333
2333
  const maxRequestBytes = limit(opts.maxRequestBytes, "--max-request-bytes");
2334
2334
  const maxResponseBytes = limit(opts.maxResponseBytes, "--max-response-bytes");
2335
2335
  routeConsoleToStderr();
2336
- const { runParseWorkerV2 } = await import("./parse-worker-v2-Y7SF2Q6I.js");
2336
+ const { runParseWorkerV2 } = await import("./parse-worker-v2-7T5HXMWF.js");
2337
2337
  await runParseWorkerV2({ maxRequestBytes, maxResponseBytes });
2338
2338
  process.exit(0);
2339
2339
  }
@@ -11,9 +11,9 @@ import {
11
11
  ensureSingleModel,
12
12
  getFormulaModelStatus,
13
13
  getFormulaModelsDir
14
- } from "./chunk-NEVZP6O3.js";
15
- import "./chunk-SPFCULY3.js";
16
- import "./chunk-BPY62DTT.js";
14
+ } from "./chunk-6R5LKBDR.js";
15
+ import "./chunk-VOE2HG2R.js";
16
+ import "./chunk-RALNP6DD.js";
17
17
 
18
18
  // src/pdf/formula/postprocess.ts
19
19
  var TRAILING_WHITESPACE_CMDS = [
@@ -1176,4 +1176,4 @@ export {
1176
1176
  getFormulaModelsDir,
1177
1177
  postProcessLatex
1178
1178
  };
1179
- //# sourceMappingURL=formula-ZM2EYXWB.js.map
1179
+ //# sourceMappingURL=formula-SYNYG6KB.js.map
@@ -1,18 +1,18 @@
1
1
  import {
2
2
  markdownToHwpx
3
- } from "./chunk-6CHKXHKR.js";
4
- import "./chunk-VCLEQ7GS.js";
3
+ } from "./chunk-666E6PCD.js";
4
+ import "./chunk-IFOXI2IN.js";
5
5
  import "./chunk-B2SRYWEY.js";
6
- import "./chunk-QVZEBMYW.js";
6
+ import "./chunk-AX6H5A6L.js";
7
7
  import "./chunk-IXQ45P43.js";
8
8
  import "./chunk-AASNBZDZ.js";
9
9
  import "./chunk-WIIPAV2D.js";
10
10
  import "./chunk-L3U4XTBO.js";
11
- import "./chunk-NL4434I2.js";
12
- import "./chunk-MQAUBK77.js";
11
+ import "./chunk-AI4QLMQ7.js";
12
+ import "./chunk-B4SR2WN2.js";
13
13
  import "./chunk-QXQX4AN7.js";
14
- import "./chunk-BPY62DTT.js";
14
+ import "./chunk-RALNP6DD.js";
15
15
  export {
16
16
  markdownToHwpx
17
17
  };
18
- //# sourceMappingURL=generator-AUA3RJD6.js.map
18
+ //# sourceMappingURL=generator-CDSRPQUE.js.map
@@ -5,7 +5,7 @@ import {
5
5
  } from "./chunk-IXQ45P43.js";
6
6
  import {
7
7
  KordocError
8
- } from "./chunk-BPY62DTT.js";
8
+ } from "./chunk-RALNP6DD.js";
9
9
 
10
10
  // src/hwp5/to-hwpx/hancom.ts
11
11
  import { execFileSync } from "child_process";
@@ -87,4 +87,4 @@ export {
87
87
  hancomSaveInvocation,
88
88
  hwpToHwpxViaHancom
89
89
  };
90
- //# sourceMappingURL=hancom-M6DIM23B.js.map
90
+ //# sourceMappingURL=hancom-267SACBC.js.map
@@ -2,7 +2,7 @@ import {
2
2
  dcxPages,
3
3
  heicToRgba,
4
4
  pcxToRgba
5
- } from "./chunk-32WLCR37.js";
5
+ } from "./chunk-HKTFGBPF.js";
6
6
  import {
7
7
  flushHeifCache
8
8
  } from "./chunk-YVFNHYJK.js";
@@ -30,30 +30,30 @@ import {
30
30
  rescueEmptyCells,
31
31
  rotateQuarter,
32
32
  rulingToPdfLines
33
- } from "./chunk-42FWJVN5.js";
34
- import "./chunk-DQDATFAC.js";
33
+ } from "./chunk-WSKQF3TO.js";
34
+ import "./chunk-PD4VKYKK.js";
35
35
  import "./chunk-DUAZNEQ6.js";
36
36
  import "./chunk-67I4YNFQ.js";
37
37
  import "./chunk-L3U4XTBO.js";
38
- import "./chunk-NL4434I2.js";
39
- import "./chunk-MQAUBK77.js";
38
+ import "./chunk-AI4QLMQ7.js";
39
+ import "./chunk-B4SR2WN2.js";
40
40
  import "./chunk-QXQX4AN7.js";
41
41
  import {
42
42
  ensureOcrModelsFor
43
- } from "./chunk-4J2DUBJJ.js";
43
+ } from "./chunk-ONJVFGL6.js";
44
44
  import "./chunk-AY66PEUP.js";
45
- import "./chunk-NEVZP6O3.js";
46
- import "./chunk-SPFCULY3.js";
45
+ import "./chunk-6R5LKBDR.js";
46
+ import "./chunk-VOE2HG2R.js";
47
47
  import {
48
48
  KordocError,
49
49
  OPTIONAL_DEP_INSTALL_HINT
50
- } from "./chunk-BPY62DTT.js";
50
+ } from "./chunk-RALNP6DD.js";
51
51
 
52
52
  // src/ocr/image-formula.ts
53
53
  async function applyImageFormulas(items, rgba, width, height, warnings) {
54
54
  let regions;
55
55
  try {
56
- const { FormulaPipeline, ensureFormulaModels } = await import("./formula-ZM2EYXWB.js");
56
+ const { FormulaPipeline, ensureFormulaModels } = await import("./formula-SYNYG6KB.js");
57
57
  await ensureFormulaModels();
58
58
  const pipeline = await FormulaPipeline.create();
59
59
  try {
@@ -288,4 +288,4 @@ export {
288
288
  imageScale,
289
289
  parseImageDocument
290
290
  };
291
- //# sourceMappingURL=image-ocr-LZH6Q32C.js.map
291
+ //# sourceMappingURL=image-ocr-4WPYRRML.js.map
package/dist/index.cjs CHANGED
@@ -381,7 +381,7 @@ var VERSION, KordocError, MAX_UNZIP_ENV_MB, SAFE_HREF_RE, HREF_ESCAPE, BARE_URL,
381
381
  var init_utils = __esm({
382
382
  "src/utils.ts"() {
383
383
  "use strict";
384
- VERSION = true ? "4.25.13" : "0.0.0-dev";
384
+ VERSION = true ? "4.25.14" : "0.0.0-dev";
385
385
  KordocError = class extends Error {
386
386
  constructor(message) {
387
387
  super(message);
@@ -38402,6 +38402,7 @@ function wrapJoiner(prevText, nextText, lex, heads = true) {
38402
38402
  if (joins != null) return joins ? "" : " ";
38403
38403
  }
38404
38404
  const ev = lex?.evidence(left, right);
38405
+ if (ev === " " && heads && dictJoins(left, right)) return "";
38405
38406
  if (ev != null) return ev;
38406
38407
  if (lex && /[가-힣A-Za-z0-9]$/.test(left) && /^[가-힣A-Za-z0-9]/.test(right) && (lex.joinedWord(left, right.replace(/[.,)」』’”;:]+$/, "")) || heads && lex.joinedStem(left, right))) return "";
38407
38408
  if (/\d$/.test(left) && COUNTER.test(right)) return "";
@@ -38422,8 +38423,10 @@ function stemOf(token) {
38422
38423
  }
38423
38424
  function dictJoins(left, right) {
38424
38425
  const tail = left.match(/[가-힣]+$/)?.[0], run = right.match(/^[가-힣]+/)?.[0];
38425
- if (!tail || !run || tail.length !== left.replace(/^[(\[「『‘“"']+/, "").length) return false;
38426
- if (run.length !== right.replace(/[.,)」』’”;:]+$/, "").length) return false;
38426
+ if (!tail || !run) return false;
38427
+ const lead = left.replace(/^[(\[「『‘“"']+/, ""), head = lead.slice(0, lead.length - tail.length);
38428
+ if (head && !/[·ㆍ‧・)」』’”A-Za-z0-9]$/.test(head)) return false;
38429
+ if (run.length !== right.replace(/[.,)」』’”;:]+$/, "").length && right[run.length] !== "(") return false;
38427
38430
  DICT ??= unpackDict(WRAP_DICT_PACKED);
38428
38431
  const stem = run.replace(DICT_PARTICLE, "");
38429
38432
  return DICT.has(tail + run) || stem.length > 0 && stem !== run && DICT.has(tail + stem);