postext 1.4.2 → 1.5.1

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 (1072) hide show
  1. package/README.md +76 -202
  2. package/dist/__tests__/breakOpportunities.test.d.ts +2 -0
  3. package/dist/__tests__/breakOpportunities.test.d.ts.map +1 -0
  4. package/dist/__tests__/breakOpportunities.test.js +204 -0
  5. package/dist/__tests__/breakOpportunities.test.js.map +1 -0
  6. package/dist/__tests__/bundle.test.js +405 -1
  7. package/dist/__tests__/bundle.test.js.map +1 -1
  8. package/dist/__tests__/bundleLocaleAndBytes.test.d.ts +2 -0
  9. package/dist/__tests__/bundleLocaleAndBytes.test.d.ts.map +1 -0
  10. package/dist/__tests__/bundleLocaleAndBytes.test.js +177 -0
  11. package/dist/__tests__/bundleLocaleAndBytes.test.js.map +1 -0
  12. package/dist/__tests__/colorAlpha.test.d.ts +2 -0
  13. package/dist/__tests__/colorAlpha.test.d.ts.map +1 -0
  14. package/dist/__tests__/colorAlpha.test.js +87 -0
  15. package/dist/__tests__/colorAlpha.test.js.map +1 -0
  16. package/dist/__tests__/columnBalancing.test.js +88 -0
  17. package/dist/__tests__/columnBalancing.test.js.map +1 -1
  18. package/dist/__tests__/columnClip.test.js +20 -0
  19. package/dist/__tests__/columnClip.test.js.map +1 -1
  20. package/dist/__tests__/columnRuleBands.test.d.ts +2 -0
  21. package/dist/__tests__/columnRuleBands.test.d.ts.map +1 -0
  22. package/dist/__tests__/columnRuleBands.test.js +146 -0
  23. package/dist/__tests__/columnRuleBands.test.js.map +1 -0
  24. package/dist/__tests__/contentWarnings.test.d.ts +2 -0
  25. package/dist/__tests__/contentWarnings.test.d.ts.map +1 -0
  26. package/dist/__tests__/contentWarnings.test.js +226 -0
  27. package/dist/__tests__/contentWarnings.test.js.map +1 -0
  28. package/dist/__tests__/continuation.test.js +2 -1
  29. package/dist/__tests__/continuation.test.js.map +1 -1
  30. package/dist/__tests__/createLayout.test.js +18 -1
  31. package/dist/__tests__/createLayout.test.js.map +1 -1
  32. package/dist/__tests__/cropMarks.test.d.ts +2 -0
  33. package/dist/__tests__/cropMarks.test.d.ts.map +1 -0
  34. package/dist/__tests__/cropMarks.test.js +138 -0
  35. package/dist/__tests__/cropMarks.test.js.map +1 -0
  36. package/dist/__tests__/defaults/calloutStyles.test.js +30 -0
  37. package/dist/__tests__/defaults/calloutStyles.test.js.map +1 -1
  38. package/dist/__tests__/defaults/headingsBreakBefore.test.d.ts +2 -0
  39. package/dist/__tests__/defaults/headingsBreakBefore.test.d.ts.map +1 -0
  40. package/dist/__tests__/defaults/headingsBreakBefore.test.js +78 -0
  41. package/dist/__tests__/defaults/headingsBreakBefore.test.js.map +1 -0
  42. package/dist/__tests__/defaults/paragraphStyles.test.js +22 -0
  43. package/dist/__tests__/defaults/paragraphStyles.test.js.map +1 -1
  44. package/dist/__tests__/design/bleedClip.test.d.ts +2 -0
  45. package/dist/__tests__/design/bleedClip.test.d.ts.map +1 -0
  46. package/dist/__tests__/design/bleedClip.test.js +91 -0
  47. package/dist/__tests__/design/bleedClip.test.js.map +1 -0
  48. package/dist/__tests__/design/boxBorderInside.test.d.ts +2 -0
  49. package/dist/__tests__/design/boxBorderInside.test.d.ts.map +1 -0
  50. package/dist/__tests__/design/boxBorderInside.test.js +102 -0
  51. package/dist/__tests__/design/boxBorderInside.test.js.map +1 -0
  52. package/dist/__tests__/design/designLineHeight.test.d.ts +2 -0
  53. package/dist/__tests__/design/designLineHeight.test.d.ts.map +1 -0
  54. package/dist/__tests__/design/designLineHeight.test.js +108 -0
  55. package/dist/__tests__/design/designLineHeight.test.js.map +1 -0
  56. package/dist/__tests__/design/designText.test.d.ts +2 -0
  57. package/dist/__tests__/design/designText.test.d.ts.map +1 -0
  58. package/dist/__tests__/design/designText.test.js +331 -0
  59. package/dist/__tests__/design/designText.test.js.map +1 -0
  60. package/dist/__tests__/design/designTextJustify.test.d.ts +2 -0
  61. package/dist/__tests__/design/designTextJustify.test.d.ts.map +1 -0
  62. package/dist/__tests__/design/designTextJustify.test.js +119 -0
  63. package/dist/__tests__/design/designTextJustify.test.js.map +1 -0
  64. package/dist/__tests__/design/designTextNegativeTracking.test.d.ts +2 -0
  65. package/dist/__tests__/design/designTextNegativeTracking.test.d.ts.map +1 -0
  66. package/dist/__tests__/design/designTextNegativeTracking.test.js +95 -0
  67. package/dist/__tests__/design/designTextNegativeTracking.test.js.map +1 -0
  68. package/dist/__tests__/design/designTextRender.test.d.ts +2 -0
  69. package/dist/__tests__/design/designTextRender.test.d.ts.map +1 -0
  70. package/dist/__tests__/design/designTextRender.test.js +106 -0
  71. package/dist/__tests__/design/designTextRender.test.js.map +1 -0
  72. package/dist/__tests__/design/dropCap.test.d.ts +2 -0
  73. package/dist/__tests__/design/dropCap.test.d.ts.map +1 -0
  74. package/dist/__tests__/design/dropCap.test.js +205 -0
  75. package/dist/__tests__/design/dropCap.test.js.map +1 -0
  76. package/dist/__tests__/design/ellipsis.test.d.ts +2 -0
  77. package/dist/__tests__/design/ellipsis.test.d.ts.map +1 -0
  78. package/dist/__tests__/design/ellipsis.test.js +113 -0
  79. package/dist/__tests__/design/ellipsis.test.js.map +1 -0
  80. package/dist/__tests__/design/headingDesignClip.test.d.ts +2 -0
  81. package/dist/__tests__/design/headingDesignClip.test.d.ts.map +1 -0
  82. package/dist/__tests__/design/headingDesignClip.test.js +60 -0
  83. package/dist/__tests__/design/headingDesignClip.test.js.map +1 -0
  84. package/dist/__tests__/design/headingDesignSideChannel.test.d.ts +2 -0
  85. package/dist/__tests__/design/headingDesignSideChannel.test.d.ts.map +1 -0
  86. package/dist/__tests__/design/headingDesignSideChannel.test.js +187 -0
  87. package/dist/__tests__/design/headingDesignSideChannel.test.js.map +1 -0
  88. package/dist/__tests__/design/inColumnTitleBreak.test.d.ts +2 -0
  89. package/dist/__tests__/design/inColumnTitleBreak.test.d.ts.map +1 -0
  90. package/dist/__tests__/design/inColumnTitleBreak.test.js +60 -0
  91. package/dist/__tests__/design/inColumnTitleBreak.test.js.map +1 -0
  92. package/dist/__tests__/design/openerBottomAnchor.test.d.ts +2 -0
  93. package/dist/__tests__/design/openerBottomAnchor.test.d.ts.map +1 -0
  94. package/dist/__tests__/design/openerBottomAnchor.test.js +106 -0
  95. package/dist/__tests__/design/openerBottomAnchor.test.js.map +1 -0
  96. package/dist/__tests__/design/openerChapterNumber.test.d.ts +2 -0
  97. package/dist/__tests__/design/openerChapterNumber.test.d.ts.map +1 -0
  98. package/dist/__tests__/design/openerChapterNumber.test.js +163 -0
  99. package/dist/__tests__/design/openerChapterNumber.test.js.map +1 -0
  100. package/dist/__tests__/design/openerImageReserve.test.d.ts +2 -0
  101. package/dist/__tests__/design/openerImageReserve.test.d.ts.map +1 -0
  102. package/dist/__tests__/design/openerImageReserve.test.js +83 -0
  103. package/dist/__tests__/design/openerImageReserve.test.js.map +1 -0
  104. package/dist/__tests__/design/openerReserve.test.d.ts +2 -0
  105. package/dist/__tests__/design/openerReserve.test.d.ts.map +1 -0
  106. package/dist/__tests__/design/openerReserve.test.js +147 -0
  107. package/dist/__tests__/design/openerReserve.test.js.map +1 -0
  108. package/dist/__tests__/design/ruleDefaults.test.d.ts +2 -0
  109. package/dist/__tests__/design/ruleDefaults.test.d.ts.map +1 -0
  110. package/dist/__tests__/design/ruleDefaults.test.js +59 -0
  111. package/dist/__tests__/design/ruleDefaults.test.js.map +1 -0
  112. package/dist/__tests__/design/runningHeads.test.js +4 -2
  113. package/dist/__tests__/design/runningHeads.test.js.map +1 -1
  114. package/dist/__tests__/design/titleTextWrapped.test.d.ts +2 -0
  115. package/dist/__tests__/design/titleTextWrapped.test.d.ts.map +1 -0
  116. package/dist/__tests__/design/titleTextWrapped.test.js +258 -0
  117. package/dist/__tests__/design/titleTextWrapped.test.js.map +1 -0
  118. package/dist/__tests__/design/trackingAlignment.test.d.ts +2 -0
  119. package/dist/__tests__/design/trackingAlignment.test.d.ts.map +1 -0
  120. package/dist/__tests__/design/trackingAlignment.test.js +101 -0
  121. package/dist/__tests__/design/trackingAlignment.test.js.map +1 -0
  122. package/dist/__tests__/design/verticalAlignOverflow.test.d.ts +2 -0
  123. package/dist/__tests__/design/verticalAlignOverflow.test.d.ts.map +1 -0
  124. package/dist/__tests__/design/verticalAlignOverflow.test.js +68 -0
  125. package/dist/__tests__/design/verticalAlignOverflow.test.js.map +1 -0
  126. package/dist/__tests__/exports.test.js +24 -0
  127. package/dist/__tests__/exports.test.js.map +1 -1
  128. package/dist/__tests__/fontStack.test.d.ts +2 -0
  129. package/dist/__tests__/fontStack.test.d.ts.map +1 -0
  130. package/dist/__tests__/fontStack.test.js +100 -0
  131. package/dist/__tests__/fontStack.test.js.map +1 -0
  132. package/dist/__tests__/frontmatterValues.test.d.ts +2 -0
  133. package/dist/__tests__/frontmatterValues.test.d.ts.map +1 -0
  134. package/dist/__tests__/frontmatterValues.test.js +119 -0
  135. package/dist/__tests__/frontmatterValues.test.js.map +1 -0
  136. package/dist/__tests__/gradedRunt.test.d.ts +2 -0
  137. package/dist/__tests__/gradedRunt.test.d.ts.map +1 -0
  138. package/dist/__tests__/gradedRunt.test.js +66 -0
  139. package/dist/__tests__/gradedRunt.test.js.map +1 -0
  140. package/dist/__tests__/headingAlign.test.d.ts +2 -0
  141. package/dist/__tests__/headingAlign.test.d.ts.map +1 -0
  142. package/dist/__tests__/headingAlign.test.js +92 -0
  143. package/dist/__tests__/headingAlign.test.js.map +1 -0
  144. package/dist/__tests__/headingInlineMarks.test.d.ts +2 -0
  145. package/dist/__tests__/headingInlineMarks.test.d.ts.map +1 -0
  146. package/dist/__tests__/headingInlineMarks.test.js +126 -0
  147. package/dist/__tests__/headingInlineMarks.test.js.map +1 -0
  148. package/dist/__tests__/headingLetterSpacing.test.d.ts +2 -0
  149. package/dist/__tests__/headingLetterSpacing.test.d.ts.map +1 -0
  150. package/dist/__tests__/headingLetterSpacing.test.js +135 -0
  151. package/dist/__tests__/headingLetterSpacing.test.js.map +1 -0
  152. package/dist/__tests__/headingNumberPlaceholders.test.d.ts +2 -0
  153. package/dist/__tests__/headingNumberPlaceholders.test.d.ts.map +1 -0
  154. package/dist/__tests__/headingNumberPlaceholders.test.js +104 -0
  155. package/dist/__tests__/headingNumberPlaceholders.test.js.map +1 -0
  156. package/dist/__tests__/headingNumberingStyles.test.d.ts +2 -0
  157. package/dist/__tests__/headingNumberingStyles.test.d.ts.map +1 -0
  158. package/dist/__tests__/headingNumberingStyles.test.js +151 -0
  159. package/dist/__tests__/headingNumberingStyles.test.js.map +1 -0
  160. package/dist/__tests__/headingSourceTitle.test.d.ts +2 -0
  161. package/dist/__tests__/headingSourceTitle.test.d.ts.map +1 -0
  162. package/dist/__tests__/headingSourceTitle.test.js +35 -0
  163. package/dist/__tests__/headingSourceTitle.test.js.map +1 -0
  164. package/dist/__tests__/headingStyleBreakAfterPagebreak.test.d.ts +2 -0
  165. package/dist/__tests__/headingStyleBreakAfterPagebreak.test.d.ts.map +1 -0
  166. package/dist/__tests__/headingStyleBreakAfterPagebreak.test.js +52 -0
  167. package/dist/__tests__/headingStyleBreakAfterPagebreak.test.js.map +1 -0
  168. package/dist/__tests__/hiddenHeadings.test.d.ts +2 -0
  169. package/dist/__tests__/hiddenHeadings.test.d.ts.map +1 -0
  170. package/dist/__tests__/hiddenHeadings.test.js +137 -0
  171. package/dist/__tests__/hiddenHeadings.test.js.map +1 -0
  172. package/dist/__tests__/htmlHostReset.test.d.ts +2 -0
  173. package/dist/__tests__/htmlHostReset.test.d.ts.map +1 -0
  174. package/dist/__tests__/htmlHostReset.test.js +63 -0
  175. package/dist/__tests__/htmlHostReset.test.js.map +1 -0
  176. package/dist/__tests__/hyphenationLocale.test.d.ts +2 -0
  177. package/dist/__tests__/hyphenationLocale.test.d.ts.map +1 -0
  178. package/dist/__tests__/hyphenationLocale.test.js +143 -0
  179. package/dist/__tests__/hyphenationLocale.test.js.map +1 -0
  180. package/dist/__tests__/justifyTracking.test.d.ts +2 -0
  181. package/dist/__tests__/justifyTracking.test.d.ts.map +1 -0
  182. package/dist/__tests__/justifyTracking.test.js +217 -0
  183. package/dist/__tests__/justifyTracking.test.js.map +1 -0
  184. package/dist/__tests__/layoutWorkerClient.test.d.ts +2 -0
  185. package/dist/__tests__/layoutWorkerClient.test.d.ts.map +1 -0
  186. package/dist/__tests__/layoutWorkerClient.test.js +140 -0
  187. package/dist/__tests__/layoutWorkerClient.test.js.map +1 -0
  188. package/dist/__tests__/links.test.d.ts +2 -0
  189. package/dist/__tests__/links.test.d.ts.map +1 -0
  190. package/dist/__tests__/links.test.js +227 -0
  191. package/dist/__tests__/links.test.js.map +1 -0
  192. package/dist/__tests__/localisedStrings.test.d.ts +2 -0
  193. package/dist/__tests__/localisedStrings.test.d.ts.map +1 -0
  194. package/dist/__tests__/localisedStrings.test.js +118 -0
  195. package/dist/__tests__/localisedStrings.test.js.map +1 -0
  196. package/dist/__tests__/looseLines.test.d.ts +2 -0
  197. package/dist/__tests__/looseLines.test.d.ts.map +1 -0
  198. package/dist/__tests__/looseLines.test.js +72 -0
  199. package/dist/__tests__/looseLines.test.js.map +1 -0
  200. package/dist/__tests__/mainEntryReact.test.d.ts +2 -0
  201. package/dist/__tests__/mainEntryReact.test.d.ts.map +1 -0
  202. package/dist/__tests__/mainEntryReact.test.js +13 -0
  203. package/dist/__tests__/mainEntryReact.test.js.map +1 -0
  204. package/dist/__tests__/mathBundle.test.d.ts +2 -0
  205. package/dist/__tests__/mathBundle.test.d.ts.map +1 -0
  206. package/dist/__tests__/mathBundle.test.js +80 -0
  207. package/dist/__tests__/mathBundle.test.js.map +1 -0
  208. package/dist/__tests__/mathEngine.test.d.ts +2 -0
  209. package/dist/__tests__/mathEngine.test.d.ts.map +1 -0
  210. package/dist/__tests__/mathEngine.test.js +69 -0
  211. package/dist/__tests__/mathEngine.test.js.map +1 -0
  212. package/dist/__tests__/mathEngineInit.test.d.ts +2 -0
  213. package/dist/__tests__/mathEngineInit.test.d.ts.map +1 -0
  214. package/dist/__tests__/mathEngineInit.test.js +33 -0
  215. package/dist/__tests__/mathEngineInit.test.js.map +1 -0
  216. package/dist/__tests__/mathSize.test.d.ts +2 -0
  217. package/dist/__tests__/mathSize.test.d.ts.map +1 -0
  218. package/dist/__tests__/mathSize.test.js +168 -0
  219. package/dist/__tests__/mathSize.test.js.map +1 -0
  220. package/dist/__tests__/mathSizeMigration.test.d.ts +2 -0
  221. package/dist/__tests__/mathSizeMigration.test.d.ts.map +1 -0
  222. package/dist/__tests__/mathSizeMigration.test.js +188 -0
  223. package/dist/__tests__/mathSizeMigration.test.js.map +1 -0
  224. package/dist/__tests__/measureCache.test.js +148 -4
  225. package/dist/__tests__/measureCache.test.js.map +1 -1
  226. package/dist/__tests__/measureCacheKeepBreaks.test.d.ts +2 -0
  227. package/dist/__tests__/measureCacheKeepBreaks.test.d.ts.map +1 -0
  228. package/dist/__tests__/measureCacheKeepBreaks.test.js +59 -0
  229. package/dist/__tests__/measureCacheKeepBreaks.test.js.map +1 -0
  230. package/dist/__tests__/noBreakSpaces.test.d.ts +2 -0
  231. package/dist/__tests__/noBreakSpaces.test.d.ts.map +1 -0
  232. package/dist/__tests__/noBreakSpaces.test.js +208 -0
  233. package/dist/__tests__/noBreakSpaces.test.js.map +1 -0
  234. package/dist/__tests__/numberFormats.test.d.ts +2 -0
  235. package/dist/__tests__/numberFormats.test.d.ts.map +1 -0
  236. package/dist/__tests__/numberFormats.test.js +142 -0
  237. package/dist/__tests__/numberFormats.test.js.map +1 -0
  238. package/dist/__tests__/paletteEverywhere.test.d.ts +2 -0
  239. package/dist/__tests__/paletteEverywhere.test.d.ts.map +1 -0
  240. package/dist/__tests__/paletteEverywhere.test.js +228 -0
  241. package/dist/__tests__/paletteEverywhere.test.js.map +1 -0
  242. package/dist/__tests__/paragraphStyleIndent.test.d.ts +2 -0
  243. package/dist/__tests__/paragraphStyleIndent.test.d.ts.map +1 -0
  244. package/dist/__tests__/paragraphStyleIndent.test.js +91 -0
  245. package/dist/__tests__/paragraphStyleIndent.test.js.map +1 -0
  246. package/dist/__tests__/parse/attrQuoting.test.d.ts +2 -0
  247. package/dist/__tests__/parse/attrQuoting.test.d.ts.map +1 -0
  248. package/dist/__tests__/parse/attrQuoting.test.js +87 -0
  249. package/dist/__tests__/parse/attrQuoting.test.js.map +1 -0
  250. package/dist/__tests__/parse/codeSpans.test.d.ts +2 -0
  251. package/dist/__tests__/parse/codeSpans.test.d.ts.map +1 -0
  252. package/dist/__tests__/parse/codeSpans.test.js +31 -0
  253. package/dist/__tests__/parse/codeSpans.test.js.map +1 -0
  254. package/dist/__tests__/parse/intrawordUnderscore.test.d.ts +2 -0
  255. package/dist/__tests__/parse/intrawordUnderscore.test.d.ts.map +1 -0
  256. package/dist/__tests__/parse/intrawordUnderscore.test.js +69 -0
  257. package/dist/__tests__/parse/intrawordUnderscore.test.js.map +1 -0
  258. package/dist/__tests__/parse/scripts.test.js +4 -1
  259. package/dist/__tests__/parse/scripts.test.js.map +1 -1
  260. package/dist/__tests__/parts.test.js +103 -0
  261. package/dist/__tests__/parts.test.js.map +1 -1
  262. package/dist/__tests__/pipeline/balancingRecord.test.d.ts +2 -0
  263. package/dist/__tests__/pipeline/balancingRecord.test.d.ts.map +1 -0
  264. package/dist/__tests__/pipeline/balancingRecord.test.js +176 -0
  265. package/dist/__tests__/pipeline/balancingRecord.test.js.map +1 -0
  266. package/dist/__tests__/pipeline/blockquoteStyle.test.d.ts +2 -0
  267. package/dist/__tests__/pipeline/blockquoteStyle.test.d.ts.map +1 -0
  268. package/dist/__tests__/pipeline/blockquoteStyle.test.js +99 -0
  269. package/dist/__tests__/pipeline/blockquoteStyle.test.js.map +1 -0
  270. package/dist/__tests__/pipeline/calloutContinuation.test.d.ts +2 -0
  271. package/dist/__tests__/pipeline/calloutContinuation.test.d.ts.map +1 -0
  272. package/dist/__tests__/pipeline/calloutContinuation.test.js +133 -0
  273. package/dist/__tests__/pipeline/calloutContinuation.test.js.map +1 -0
  274. package/dist/__tests__/pipeline/calloutContinuationInset.test.d.ts +2 -0
  275. package/dist/__tests__/pipeline/calloutContinuationInset.test.d.ts.map +1 -0
  276. package/dist/__tests__/pipeline/calloutContinuationInset.test.js +116 -0
  277. package/dist/__tests__/pipeline/calloutContinuationInset.test.js.map +1 -0
  278. package/dist/__tests__/pipeline/calloutCornerWideIcon.test.d.ts +2 -0
  279. package/dist/__tests__/pipeline/calloutCornerWideIcon.test.d.ts.map +1 -0
  280. package/dist/__tests__/pipeline/calloutCornerWideIcon.test.js +69 -0
  281. package/dist/__tests__/pipeline/calloutCornerWideIcon.test.js.map +1 -0
  282. package/dist/__tests__/pipeline/calloutFloatMargins.test.d.ts +2 -0
  283. package/dist/__tests__/pipeline/calloutFloatMargins.test.d.ts.map +1 -0
  284. package/dist/__tests__/pipeline/calloutFloatMargins.test.js +104 -0
  285. package/dist/__tests__/pipeline/calloutFloatMargins.test.js.map +1 -0
  286. package/dist/__tests__/pipeline/calloutInlineResourceGap.test.d.ts +2 -0
  287. package/dist/__tests__/pipeline/calloutInlineResourceGap.test.d.ts.map +1 -0
  288. package/dist/__tests__/pipeline/calloutInlineResourceGap.test.js +148 -0
  289. package/dist/__tests__/pipeline/calloutInlineResourceGap.test.js.map +1 -0
  290. package/dist/__tests__/pipeline/calloutListColor.test.d.ts +2 -0
  291. package/dist/__tests__/pipeline/calloutListColor.test.d.ts.map +1 -0
  292. package/dist/__tests__/pipeline/calloutListColor.test.js +86 -0
  293. package/dist/__tests__/pipeline/calloutListColor.test.js.map +1 -0
  294. package/dist/__tests__/pipeline/calloutRaggedLines.test.d.ts +2 -0
  295. package/dist/__tests__/pipeline/calloutRaggedLines.test.d.ts.map +1 -0
  296. package/dist/__tests__/pipeline/calloutRaggedLines.test.js +65 -0
  297. package/dist/__tests__/pipeline/calloutRaggedLines.test.js.map +1 -0
  298. package/dist/__tests__/pipeline/calloutRuntTracking.test.d.ts +2 -0
  299. package/dist/__tests__/pipeline/calloutRuntTracking.test.d.ts.map +1 -0
  300. package/dist/__tests__/pipeline/calloutRuntTracking.test.js +84 -0
  301. package/dist/__tests__/pipeline/calloutRuntTracking.test.js.map +1 -0
  302. package/dist/__tests__/pipeline/calloutSplitMinLinesChild.test.d.ts +2 -0
  303. package/dist/__tests__/pipeline/calloutSplitMinLinesChild.test.d.ts.map +1 -0
  304. package/dist/__tests__/pipeline/calloutSplitMinLinesChild.test.js +187 -0
  305. package/dist/__tests__/pipeline/calloutSplitMinLinesChild.test.js.map +1 -0
  306. package/dist/__tests__/pipeline/calloutStripeRadius.test.d.ts +2 -0
  307. package/dist/__tests__/pipeline/calloutStripeRadius.test.d.ts.map +1 -0
  308. package/dist/__tests__/pipeline/calloutStripeRadius.test.js +127 -0
  309. package/dist/__tests__/pipeline/calloutStripeRadius.test.js.map +1 -0
  310. package/dist/__tests__/pipeline/calloutTitleLineHeight.test.d.ts +2 -0
  311. package/dist/__tests__/pipeline/calloutTitleLineHeight.test.d.ts.map +1 -0
  312. package/dist/__tests__/pipeline/calloutTitleLineHeight.test.js +81 -0
  313. package/dist/__tests__/pipeline/calloutTitleLineHeight.test.js.map +1 -0
  314. package/dist/__tests__/pipeline/calloutTypography.test.d.ts +2 -0
  315. package/dist/__tests__/pipeline/calloutTypography.test.d.ts.map +1 -0
  316. package/dist/__tests__/pipeline/calloutTypography.test.js +97 -0
  317. package/dist/__tests__/pipeline/calloutTypography.test.js.map +1 -0
  318. package/dist/__tests__/pipeline/capUnderHeadFloats.test.d.ts +2 -0
  319. package/dist/__tests__/pipeline/capUnderHeadFloats.test.d.ts.map +1 -0
  320. package/dist/__tests__/pipeline/capUnderHeadFloats.test.js +68 -0
  321. package/dist/__tests__/pipeline/capUnderHeadFloats.test.js.map +1 -0
  322. package/dist/__tests__/pipeline/captionAlign.test.d.ts +2 -0
  323. package/dist/__tests__/pipeline/captionAlign.test.d.ts.map +1 -0
  324. package/dist/__tests__/pipeline/captionAlign.test.js +99 -0
  325. package/dist/__tests__/pipeline/captionAlign.test.js.map +1 -0
  326. package/dist/__tests__/pipeline/chipPalette.test.d.ts +2 -0
  327. package/dist/__tests__/pipeline/chipPalette.test.d.ts.map +1 -0
  328. package/dist/__tests__/pipeline/chipPalette.test.js +80 -0
  329. package/dist/__tests__/pipeline/chipPalette.test.js.map +1 -0
  330. package/dist/__tests__/pipeline/chipVerticalPadding.test.d.ts +2 -0
  331. package/dist/__tests__/pipeline/chipVerticalPadding.test.d.ts.map +1 -0
  332. package/dist/__tests__/pipeline/chipVerticalPadding.test.js +66 -0
  333. package/dist/__tests__/pipeline/chipVerticalPadding.test.js.map +1 -0
  334. package/dist/__tests__/pipeline/chips.test.js +32 -0
  335. package/dist/__tests__/pipeline/chips.test.js.map +1 -1
  336. package/dist/__tests__/pipeline/closingBoxLever.test.d.ts +2 -0
  337. package/dist/__tests__/pipeline/closingBoxLever.test.d.ts.map +1 -0
  338. package/dist/__tests__/pipeline/closingBoxLever.test.js +68 -0
  339. package/dist/__tests__/pipeline/closingBoxLever.test.js.map +1 -0
  340. package/dist/__tests__/pipeline/closingBoxOrder.test.d.ts +2 -0
  341. package/dist/__tests__/pipeline/closingBoxOrder.test.d.ts.map +1 -0
  342. package/dist/__tests__/pipeline/closingBoxOrder.test.js +87 -0
  343. package/dist/__tests__/pipeline/closingBoxOrder.test.js.map +1 -0
  344. package/dist/__tests__/pipeline/closingPageAfterFloat.test.d.ts +2 -0
  345. package/dist/__tests__/pipeline/closingPageAfterFloat.test.d.ts.map +1 -0
  346. package/dist/__tests__/pipeline/closingPageAfterFloat.test.js +159 -0
  347. package/dist/__tests__/pipeline/closingPageAfterFloat.test.js.map +1 -0
  348. package/dist/__tests__/pipeline/closingPageAfterFloatPage.test.d.ts +2 -0
  349. package/dist/__tests__/pipeline/closingPageAfterFloatPage.test.d.ts.map +1 -0
  350. package/dist/__tests__/pipeline/closingPageAfterFloatPage.test.js +90 -0
  351. package/dist/__tests__/pipeline/closingPageAfterFloatPage.test.js.map +1 -0
  352. package/dist/__tests__/pipeline/colonBalancing.test.js +19 -15
  353. package/dist/__tests__/pipeline/colonBalancing.test.js.map +1 -1
  354. package/dist/__tests__/pipeline/colonListRoom.test.d.ts +2 -0
  355. package/dist/__tests__/pipeline/colonListRoom.test.d.ts.map +1 -0
  356. package/dist/__tests__/pipeline/colonListRoom.test.js +127 -0
  357. package/dist/__tests__/pipeline/colonListRoom.test.js.map +1 -0
  358. package/dist/__tests__/pipeline/columnWidthRebreak.test.d.ts +2 -0
  359. package/dist/__tests__/pipeline/columnWidthRebreak.test.d.ts.map +1 -0
  360. package/dist/__tests__/pipeline/columnWidthRebreak.test.js +124 -0
  361. package/dist/__tests__/pipeline/columnWidthRebreak.test.js.map +1 -0
  362. package/dist/__tests__/pipeline/compoundBreaks.test.d.ts +2 -0
  363. package/dist/__tests__/pipeline/compoundBreaks.test.d.ts.map +1 -0
  364. package/dist/__tests__/pipeline/compoundBreaks.test.js +368 -0
  365. package/dist/__tests__/pipeline/compoundBreaks.test.js.map +1 -0
  366. package/dist/__tests__/pipeline/continuationUnderFloat.test.d.ts +2 -0
  367. package/dist/__tests__/pipeline/continuationUnderFloat.test.d.ts.map +1 -0
  368. package/dist/__tests__/pipeline/continuationUnderFloat.test.js +64 -0
  369. package/dist/__tests__/pipeline/continuationUnderFloat.test.js.map +1 -0
  370. package/dist/__tests__/pipeline/crossChapterRef.test.d.ts +2 -0
  371. package/dist/__tests__/pipeline/crossChapterRef.test.d.ts.map +1 -0
  372. package/dist/__tests__/pipeline/crossChapterRef.test.js +124 -0
  373. package/dist/__tests__/pipeline/crossChapterRef.test.js.map +1 -0
  374. package/dist/__tests__/pipeline/dashBreaks.test.d.ts +2 -0
  375. package/dist/__tests__/pipeline/dashBreaks.test.d.ts.map +1 -0
  376. package/dist/__tests__/pipeline/dashBreaks.test.js +358 -0
  377. package/dist/__tests__/pipeline/dashBreaks.test.js.map +1 -0
  378. package/dist/__tests__/pipeline/defaultOpenerPaint.test.d.ts +2 -0
  379. package/dist/__tests__/pipeline/defaultOpenerPaint.test.d.ts.map +1 -0
  380. package/dist/__tests__/pipeline/defaultOpenerPaint.test.js +128 -0
  381. package/dist/__tests__/pipeline/defaultOpenerPaint.test.js.map +1 -0
  382. package/dist/__tests__/pipeline/displayMathFlow.test.d.ts +2 -0
  383. package/dist/__tests__/pipeline/displayMathFlow.test.d.ts.map +1 -0
  384. package/dist/__tests__/pipeline/displayMathFlow.test.js +156 -0
  385. package/dist/__tests__/pipeline/displayMathFlow.test.js.map +1 -0
  386. package/dist/__tests__/pipeline/emptyResourceTemplate.test.d.ts +2 -0
  387. package/dist/__tests__/pipeline/emptyResourceTemplate.test.d.ts.map +1 -0
  388. package/dist/__tests__/pipeline/emptyResourceTemplate.test.js +66 -0
  389. package/dist/__tests__/pipeline/emptyResourceTemplate.test.js.map +1 -0
  390. package/dist/__tests__/pipeline/figureBodyAlign.test.d.ts +2 -0
  391. package/dist/__tests__/pipeline/figureBodyAlign.test.d.ts.map +1 -0
  392. package/dist/__tests__/pipeline/figureBodyAlign.test.js +92 -0
  393. package/dist/__tests__/pipeline/figureBodyAlign.test.js.map +1 -0
  394. package/dist/__tests__/pipeline/floatAfterCitingLine.test.d.ts +2 -0
  395. package/dist/__tests__/pipeline/floatAfterCitingLine.test.d.ts.map +1 -0
  396. package/dist/__tests__/pipeline/floatAfterCitingLine.test.js +217 -0
  397. package/dist/__tests__/pipeline/floatAfterCitingLine.test.js.map +1 -0
  398. package/dist/__tests__/pipeline/floatFirstSlot.test.js +15 -0
  399. package/dist/__tests__/pipeline/floatFirstSlot.test.js.map +1 -1
  400. package/dist/__tests__/pipeline/floatOverInlineResource.test.d.ts +2 -0
  401. package/dist/__tests__/pipeline/floatOverInlineResource.test.d.ts.map +1 -0
  402. package/dist/__tests__/pipeline/floatOverInlineResource.test.js +75 -0
  403. package/dist/__tests__/pipeline/floatOverInlineResource.test.js.map +1 -0
  404. package/dist/__tests__/pipeline/floatPlacementRules.test.d.ts +2 -0
  405. package/dist/__tests__/pipeline/floatPlacementRules.test.d.ts.map +1 -0
  406. package/dist/__tests__/pipeline/floatPlacementRules.test.js +177 -0
  407. package/dist/__tests__/pipeline/floatPlacementRules.test.js.map +1 -0
  408. package/dist/__tests__/pipeline/floatSlots.test.js +35 -1
  409. package/dist/__tests__/pipeline/floatSlots.test.js.map +1 -1
  410. package/dist/__tests__/pipeline/hardHyphenBreaks.test.d.ts +2 -0
  411. package/dist/__tests__/pipeline/hardHyphenBreaks.test.d.ts.map +1 -0
  412. package/dist/__tests__/pipeline/hardHyphenBreaks.test.js +165 -0
  413. package/dist/__tests__/pipeline/hardHyphenBreaks.test.js.map +1 -0
  414. package/dist/__tests__/pipeline/headingDesignCuts.test.d.ts +2 -0
  415. package/dist/__tests__/pipeline/headingDesignCuts.test.d.ts.map +1 -0
  416. package/dist/__tests__/pipeline/headingDesignCuts.test.js +96 -0
  417. package/dist/__tests__/pipeline/headingDesignCuts.test.js.map +1 -0
  418. package/dist/__tests__/pipeline/headingSnapPerLevel.test.d.ts +2 -0
  419. package/dist/__tests__/pipeline/headingSnapPerLevel.test.d.ts.map +1 -0
  420. package/dist/__tests__/pipeline/headingSnapPerLevel.test.js +97 -0
  421. package/dist/__tests__/pipeline/headingSnapPerLevel.test.js.map +1 -0
  422. package/dist/__tests__/pipeline/headingSplitOrphans.test.d.ts +2 -0
  423. package/dist/__tests__/pipeline/headingSplitOrphans.test.d.ts.map +1 -0
  424. package/dist/__tests__/pipeline/headingSplitOrphans.test.js +134 -0
  425. package/dist/__tests__/pipeline/headingSplitOrphans.test.js.map +1 -0
  426. package/dist/__tests__/pipeline/hyphenAcrossColumns.test.d.ts +2 -0
  427. package/dist/__tests__/pipeline/hyphenAcrossColumns.test.d.ts.map +1 -0
  428. package/dist/__tests__/pipeline/hyphenAcrossColumns.test.js +232 -0
  429. package/dist/__tests__/pipeline/hyphenAcrossColumns.test.js.map +1 -0
  430. package/dist/__tests__/pipeline/indentAfterOutOfFlow.test.d.ts +2 -0
  431. package/dist/__tests__/pipeline/indentAfterOutOfFlow.test.d.ts.map +1 -0
  432. package/dist/__tests__/pipeline/indentAfterOutOfFlow.test.js +93 -0
  433. package/dist/__tests__/pipeline/indentAfterOutOfFlow.test.js.map +1 -0
  434. package/dist/__tests__/pipeline/inlineFigureSpace.test.d.ts +2 -0
  435. package/dist/__tests__/pipeline/inlineFigureSpace.test.d.ts.map +1 -0
  436. package/dist/__tests__/pipeline/inlineFigureSpace.test.js +195 -0
  437. package/dist/__tests__/pipeline/inlineFigureSpace.test.js.map +1 -0
  438. package/dist/__tests__/pipeline/lineSourceEdges.test.d.ts +2 -0
  439. package/dist/__tests__/pipeline/lineSourceEdges.test.d.ts.map +1 -0
  440. package/dist/__tests__/pipeline/lineSourceEdges.test.js +143 -0
  441. package/dist/__tests__/pipeline/lineSourceEdges.test.js.map +1 -0
  442. package/dist/__tests__/pipeline/lineSourceRanges.test.d.ts +2 -0
  443. package/dist/__tests__/pipeline/lineSourceRanges.test.d.ts.map +1 -0
  444. package/dist/__tests__/pipeline/lineSourceRanges.test.js +96 -0
  445. package/dist/__tests__/pipeline/lineSourceRanges.test.js.map +1 -0
  446. package/dist/__tests__/pipeline/listTopSnap.test.d.ts +2 -0
  447. package/dist/__tests__/pipeline/listTopSnap.test.d.ts.map +1 -0
  448. package/dist/__tests__/pipeline/listTopSnap.test.js +90 -0
  449. package/dist/__tests__/pipeline/listTopSnap.test.js.map +1 -0
  450. package/dist/__tests__/pipeline/looseParagraphLimit.test.d.ts +2 -0
  451. package/dist/__tests__/pipeline/looseParagraphLimit.test.d.ts.map +1 -0
  452. package/dist/__tests__/pipeline/looseParagraphLimit.test.js +63 -0
  453. package/dist/__tests__/pipeline/looseParagraphLimit.test.js.map +1 -0
  454. package/dist/__tests__/pipeline/nestedListSpacing.test.d.ts +2 -0
  455. package/dist/__tests__/pipeline/nestedListSpacing.test.d.ts.map +1 -0
  456. package/dist/__tests__/pipeline/nestedListSpacing.test.js +62 -0
  457. package/dist/__tests__/pipeline/nestedListSpacing.test.js.map +1 -0
  458. package/dist/__tests__/pipeline/openerColumnStarts.test.d.ts +2 -0
  459. package/dist/__tests__/pipeline/openerColumnStarts.test.d.ts.map +1 -0
  460. package/dist/__tests__/pipeline/openerColumnStarts.test.js +189 -0
  461. package/dist/__tests__/pipeline/openerColumnStarts.test.js.map +1 -0
  462. package/dist/__tests__/pipeline/openerFillsPage.test.d.ts +2 -0
  463. package/dist/__tests__/pipeline/openerFillsPage.test.d.ts.map +1 -0
  464. package/dist/__tests__/pipeline/openerFillsPage.test.js +133 -0
  465. package/dist/__tests__/pipeline/openerFillsPage.test.js.map +1 -0
  466. package/dist/__tests__/pipeline/openerTallerThanColumn.test.d.ts +2 -0
  467. package/dist/__tests__/pipeline/openerTallerThanColumn.test.d.ts.map +1 -0
  468. package/dist/__tests__/pipeline/openerTallerThanColumn.test.js +139 -0
  469. package/dist/__tests__/pipeline/openerTallerThanColumn.test.js.map +1 -0
  470. package/dist/__tests__/pipeline/orderedNumberWidth.test.d.ts +2 -0
  471. package/dist/__tests__/pipeline/orderedNumberWidth.test.d.ts.map +1 -0
  472. package/dist/__tests__/pipeline/orderedNumberWidth.test.js +69 -0
  473. package/dist/__tests__/pipeline/orderedNumberWidth.test.js.map +1 -0
  474. package/dist/__tests__/pipeline/pageSpanHeadingWidth.test.d.ts +2 -0
  475. package/dist/__tests__/pipeline/pageSpanHeadingWidth.test.d.ts.map +1 -0
  476. package/dist/__tests__/pipeline/pageSpanHeadingWidth.test.js +74 -0
  477. package/dist/__tests__/pipeline/pageSpanHeadingWidth.test.js.map +1 -0
  478. package/dist/__tests__/pipeline/paragraphContainerTail.test.d.ts +2 -0
  479. package/dist/__tests__/pipeline/paragraphContainerTail.test.d.ts.map +1 -0
  480. package/dist/__tests__/pipeline/paragraphContainerTail.test.js +218 -0
  481. package/dist/__tests__/pipeline/paragraphContainerTail.test.js.map +1 -0
  482. package/dist/__tests__/pipeline/paragraphStyleFaces.test.d.ts +2 -0
  483. package/dist/__tests__/pipeline/paragraphStyleFaces.test.d.ts.map +1 -0
  484. package/dist/__tests__/pipeline/paragraphStyleFaces.test.js +121 -0
  485. package/dist/__tests__/pipeline/paragraphStyleFaces.test.js.map +1 -0
  486. package/dist/__tests__/pipeline/paragraphStyles.test.js +85 -0
  487. package/dist/__tests__/pipeline/paragraphStyles.test.js.map +1 -1
  488. package/dist/__tests__/pipeline/raggedOptimal.test.d.ts +2 -0
  489. package/dist/__tests__/pipeline/raggedOptimal.test.d.ts.map +1 -0
  490. package/dist/__tests__/pipeline/raggedOptimal.test.js +231 -0
  491. package/dist/__tests__/pipeline/raggedOptimal.test.js.map +1 -0
  492. package/dist/__tests__/pipeline/resolvedPaletteCopy.test.d.ts +2 -0
  493. package/dist/__tests__/pipeline/resolvedPaletteCopy.test.d.ts.map +1 -0
  494. package/dist/__tests__/pipeline/resolvedPaletteCopy.test.js +68 -0
  495. package/dist/__tests__/pipeline/resolvedPaletteCopy.test.js.map +1 -0
  496. package/dist/__tests__/pipeline/resourceNumberingRules.test.d.ts +2 -0
  497. package/dist/__tests__/pipeline/resourceNumberingRules.test.d.ts.map +1 -0
  498. package/dist/__tests__/pipeline/resourceNumberingRules.test.js +103 -0
  499. package/dist/__tests__/pipeline/resourceNumberingRules.test.js.map +1 -0
  500. package/dist/__tests__/pipeline/sectionPageOwnership.test.d.ts +2 -0
  501. package/dist/__tests__/pipeline/sectionPageOwnership.test.d.ts.map +1 -0
  502. package/dist/__tests__/pipeline/sectionPageOwnership.test.js +89 -0
  503. package/dist/__tests__/pipeline/sectionPageOwnership.test.js.map +1 -0
  504. package/dist/__tests__/pipeline/sectionPaletteSharedBase.test.d.ts +2 -0
  505. package/dist/__tests__/pipeline/sectionPaletteSharedBase.test.d.ts.map +1 -0
  506. package/dist/__tests__/pipeline/sectionPaletteSharedBase.test.js +278 -0
  507. package/dist/__tests__/pipeline/sectionPaletteSharedBase.test.js.map +1 -0
  508. package/dist/__tests__/pipeline/sectionPaletteTables.test.d.ts +2 -0
  509. package/dist/__tests__/pipeline/sectionPaletteTables.test.d.ts.map +1 -0
  510. package/dist/__tests__/pipeline/sectionPaletteTables.test.js +104 -0
  511. package/dist/__tests__/pipeline/sectionPaletteTables.test.js.map +1 -0
  512. package/dist/__tests__/pipeline/sideBoxAtColumnEnd.test.d.ts +2 -0
  513. package/dist/__tests__/pipeline/sideBoxAtColumnEnd.test.d.ts.map +1 -0
  514. package/dist/__tests__/pipeline/sideBoxAtColumnEnd.test.js +176 -0
  515. package/dist/__tests__/pipeline/sideBoxAtColumnEnd.test.js.map +1 -0
  516. package/dist/__tests__/pipeline/sideColumnPercent.test.d.ts +2 -0
  517. package/dist/__tests__/pipeline/sideColumnPercent.test.d.ts.map +1 -0
  518. package/dist/__tests__/pipeline/sideColumnPercent.test.js +114 -0
  519. package/dist/__tests__/pipeline/sideColumnPercent.test.js.map +1 -0
  520. package/dist/__tests__/pipeline/snippetDollarEscape.test.d.ts +2 -0
  521. package/dist/__tests__/pipeline/snippetDollarEscape.test.d.ts.map +1 -0
  522. package/dist/__tests__/pipeline/snippetDollarEscape.test.js +112 -0
  523. package/dist/__tests__/pipeline/snippetDollarEscape.test.js.map +1 -0
  524. package/dist/__tests__/pipeline/snippetLineBreaks.test.d.ts +2 -0
  525. package/dist/__tests__/pipeline/snippetLineBreaks.test.d.ts.map +1 -0
  526. package/dist/__tests__/pipeline/snippetLineBreaks.test.js +178 -0
  527. package/dist/__tests__/pipeline/snippetLineBreaks.test.js.map +1 -0
  528. package/dist/__tests__/pipeline/spanCutUnderColumnFloat.test.d.ts +2 -0
  529. package/dist/__tests__/pipeline/spanCutUnderColumnFloat.test.d.ts.map +1 -0
  530. package/dist/__tests__/pipeline/spanCutUnderColumnFloat.test.js +90 -0
  531. package/dist/__tests__/pipeline/spanCutUnderColumnFloat.test.js.map +1 -0
  532. package/dist/__tests__/pipeline/splitBoxCappedBand.test.d.ts +2 -0
  533. package/dist/__tests__/pipeline/splitBoxCappedBand.test.d.ts.map +1 -0
  534. package/dist/__tests__/pipeline/splitBoxCappedBand.test.js +64 -0
  535. package/dist/__tests__/pipeline/splitBoxCappedBand.test.js.map +1 -0
  536. package/dist/__tests__/pipeline/tableCellNoBreakSpaces.test.d.ts +2 -0
  537. package/dist/__tests__/pipeline/tableCellNoBreakSpaces.test.d.ts.map +1 -0
  538. package/dist/__tests__/pipeline/tableCellNoBreakSpaces.test.js +97 -0
  539. package/dist/__tests__/pipeline/tableCellNoBreakSpaces.test.js.map +1 -0
  540. package/dist/__tests__/pipeline/tableHeaderTracking.test.d.ts +2 -0
  541. package/dist/__tests__/pipeline/tableHeaderTracking.test.d.ts.map +1 -0
  542. package/dist/__tests__/pipeline/tableHeaderTracking.test.js +139 -0
  543. package/dist/__tests__/pipeline/tableHeaderTracking.test.js.map +1 -0
  544. package/dist/__tests__/pipeline/tableSplitTextRoom.test.d.ts +2 -0
  545. package/dist/__tests__/pipeline/tableSplitTextRoom.test.d.ts.map +1 -0
  546. package/dist/__tests__/pipeline/tableSplitTextRoom.test.js +90 -0
  547. package/dist/__tests__/pipeline/tableSplitTextRoom.test.js.map +1 -0
  548. package/dist/__tests__/pipeline/tableStyles.test.js +94 -1
  549. package/dist/__tests__/pipeline/tableStyles.test.js.map +1 -1
  550. package/dist/__tests__/pipeline/tallParagraphShortColumn.test.d.ts +2 -0
  551. package/dist/__tests__/pipeline/tallParagraphShortColumn.test.d.ts.map +1 -0
  552. package/dist/__tests__/pipeline/tallParagraphShortColumn.test.js +79 -0
  553. package/dist/__tests__/pipeline/tallParagraphShortColumn.test.js.map +1 -0
  554. package/dist/__tests__/pipeline/textFaces.test.d.ts +2 -0
  555. package/dist/__tests__/pipeline/textFaces.test.d.ts.map +1 -0
  556. package/dist/__tests__/pipeline/textFaces.test.js +258 -0
  557. package/dist/__tests__/pipeline/textFaces.test.js.map +1 -0
  558. package/dist/__tests__/pipeline/trailingBand.test.js +29 -0
  559. package/dist/__tests__/pipeline/trailingBand.test.js.map +1 -1
  560. package/dist/__tests__/pipeline/trailingCapHeading.test.d.ts +2 -0
  561. package/dist/__tests__/pipeline/trailingCapHeading.test.d.ts.map +1 -0
  562. package/dist/__tests__/pipeline/trailingCapHeading.test.js +69 -0
  563. package/dist/__tests__/pipeline/trailingCapHeading.test.js.map +1 -0
  564. package/dist/__tests__/pipeline/trailingCapOverflow.test.d.ts +2 -0
  565. package/dist/__tests__/pipeline/trailingCapOverflow.test.d.ts.map +1 -0
  566. package/dist/__tests__/pipeline/trailingCapOverflow.test.js +116 -0
  567. package/dist/__tests__/pipeline/trailingCapOverflow.test.js.map +1 -0
  568. package/dist/__tests__/placeholders.test.js +100 -2
  569. package/dist/__tests__/placeholders.test.js.map +1 -1
  570. package/dist/__tests__/punctuationGlue.test.d.ts +2 -0
  571. package/dist/__tests__/punctuationGlue.test.d.ts.map +1 -0
  572. package/dist/__tests__/punctuationGlue.test.js +165 -0
  573. package/dist/__tests__/punctuationGlue.test.js.map +1 -0
  574. package/dist/__tests__/raggedHyphenation.test.d.ts +2 -0
  575. package/dist/__tests__/raggedHyphenation.test.d.ts.map +1 -0
  576. package/dist/__tests__/raggedHyphenation.test.js +184 -0
  577. package/dist/__tests__/raggedHyphenation.test.js.map +1 -0
  578. package/dist/__tests__/renderWarnings.test.d.ts +2 -0
  579. package/dist/__tests__/renderWarnings.test.d.ts.map +1 -0
  580. package/dist/__tests__/renderWarnings.test.js +72 -0
  581. package/dist/__tests__/renderWarnings.test.js.map +1 -0
  582. package/dist/__tests__/resolvedLocale.test.d.ts +2 -0
  583. package/dist/__tests__/resolvedLocale.test.d.ts.map +1 -0
  584. package/dist/__tests__/resolvedLocale.test.js +51 -0
  585. package/dist/__tests__/resolvedLocale.test.js.map +1 -0
  586. package/dist/__tests__/runningChapter.test.d.ts +2 -0
  587. package/dist/__tests__/runningChapter.test.d.ts.map +1 -0
  588. package/dist/__tests__/runningChapter.test.js +161 -0
  589. package/dist/__tests__/runningChapter.test.js.map +1 -0
  590. package/dist/__tests__/runtFixStretchLimit.test.d.ts +2 -0
  591. package/dist/__tests__/runtFixStretchLimit.test.d.ts.map +1 -0
  592. package/dist/__tests__/runtFixStretchLimit.test.js +145 -0
  593. package/dist/__tests__/runtFixStretchLimit.test.js.map +1 -0
  594. package/dist/__tests__/scriptStacking.test.d.ts +2 -0
  595. package/dist/__tests__/scriptStacking.test.d.ts.map +1 -0
  596. package/dist/__tests__/scriptStacking.test.js +331 -0
  597. package/dist/__tests__/scriptStacking.test.js.map +1 -0
  598. package/dist/__tests__/sectionPaletteFlow.test.d.ts +2 -0
  599. package/dist/__tests__/sectionPaletteFlow.test.d.ts.map +1 -0
  600. package/dist/__tests__/sectionPaletteFlow.test.js +51 -0
  601. package/dist/__tests__/sectionPaletteFlow.test.js.map +1 -0
  602. package/dist/__tests__/singleInk.test.js +64 -2
  603. package/dist/__tests__/singleInk.test.js.map +1 -1
  604. package/dist/__tests__/singleInkRender.test.d.ts +2 -0
  605. package/dist/__tests__/singleInkRender.test.d.ts.map +1 -0
  606. package/dist/__tests__/singleInkRender.test.js +396 -0
  607. package/dist/__tests__/singleInkRender.test.js.map +1 -0
  608. package/dist/__tests__/spaceDirective.test.js +75 -0
  609. package/dist/__tests__/spaceDirective.test.js.map +1 -1
  610. package/dist/__tests__/table/model.test.js +124 -1
  611. package/dist/__tests__/table/model.test.js.map +1 -1
  612. package/dist/__tests__/tableFillSeams.test.d.ts +2 -0
  613. package/dist/__tests__/tableFillSeams.test.d.ts.map +1 -0
  614. package/dist/__tests__/tableFillSeams.test.js +180 -0
  615. package/dist/__tests__/tableFillSeams.test.js.map +1 -0
  616. package/dist/__tests__/toc.test.js +23 -2
  617. package/dist/__tests__/toc.test.js.map +1 -1
  618. package/dist/__tests__/tocLeaderKerning.test.d.ts +2 -0
  619. package/dist/__tests__/tocLeaderKerning.test.d.ts.map +1 -0
  620. package/dist/__tests__/tocLeaderKerning.test.js +83 -0
  621. package/dist/__tests__/tocLeaderKerning.test.js.map +1 -0
  622. package/dist/__tests__/tocNumberBaseline.test.d.ts +2 -0
  623. package/dist/__tests__/tocNumberBaseline.test.d.ts.map +1 -0
  624. package/dist/__tests__/tocNumberBaseline.test.js +90 -0
  625. package/dist/__tests__/tocNumberBaseline.test.js.map +1 -0
  626. package/dist/__tests__/tocPartsHeight.test.d.ts +2 -0
  627. package/dist/__tests__/tocPartsHeight.test.d.ts.map +1 -0
  628. package/dist/__tests__/tocPartsHeight.test.js +41 -0
  629. package/dist/__tests__/tocPartsHeight.test.js.map +1 -0
  630. package/dist/__tests__/trackedLineAlign.test.d.ts +2 -0
  631. package/dist/__tests__/trackedLineAlign.test.d.ts.map +1 -0
  632. package/dist/__tests__/trackedLineAlign.test.js +96 -0
  633. package/dist/__tests__/trackedLineAlign.test.js.map +1 -0
  634. package/dist/bundle/adapters.d.ts +10 -3
  635. package/dist/bundle/adapters.d.ts.map +1 -1
  636. package/dist/bundle/adapters.js +13 -5
  637. package/dist/bundle/adapters.js.map +1 -1
  638. package/dist/bundle/api.d.ts +32 -0
  639. package/dist/bundle/api.d.ts.map +1 -1
  640. package/dist/bundle/api.js +18 -3
  641. package/dist/bundle/api.js.map +1 -1
  642. package/dist/bundle/book.d.ts +6 -1
  643. package/dist/bundle/book.d.ts.map +1 -1
  644. package/dist/bundle/book.js +89 -17
  645. package/dist/bundle/book.js.map +1 -1
  646. package/dist/bundle/codec.d.ts +87 -3
  647. package/dist/bundle/codec.d.ts.map +1 -1
  648. package/dist/bundle/codec.js +193 -13
  649. package/dist/bundle/codec.js.map +1 -1
  650. package/dist/bundle/configVersion.d.ts +295 -0
  651. package/dist/bundle/configVersion.d.ts.map +1 -0
  652. package/dist/bundle/configVersion.js +788 -0
  653. package/dist/bundle/configVersion.js.map +1 -0
  654. package/dist/bundle/index.d.ts +6 -4
  655. package/dist/bundle/index.d.ts.map +1 -1
  656. package/dist/bundle/index.js +2 -1
  657. package/dist/bundle/index.js.map +1 -1
  658. package/dist/bundle/manifest.d.ts +19 -5
  659. package/dist/bundle/manifest.d.ts.map +1 -1
  660. package/dist/bundle/manifest.js +53 -21
  661. package/dist/bundle/manifest.js.map +1 -1
  662. package/dist/bundle/types.d.ts +19 -0
  663. package/dist/bundle/types.d.ts.map +1 -1
  664. package/dist/bundle/zip.d.ts +14 -1
  665. package/dist/bundle/zip.d.ts.map +1 -1
  666. package/dist/bundle/zip.js +13 -2
  667. package/dist/bundle/zip.js.map +1 -1
  668. package/dist/canvas-backend/blockRender.d.ts +3 -1
  669. package/dist/canvas-backend/blockRender.d.ts.map +1 -1
  670. package/dist/canvas-backend/blockRender.js +27 -17
  671. package/dist/canvas-backend/blockRender.js.map +1 -1
  672. package/dist/canvas-backend/decorations.d.ts.map +1 -1
  673. package/dist/canvas-backend/decorations.js +6 -36
  674. package/dist/canvas-backend/decorations.js.map +1 -1
  675. package/dist/canvas-backend/headerFooter.d.ts +3 -1
  676. package/dist/canvas-backend/headerFooter.d.ts.map +1 -1
  677. package/dist/canvas-backend/headerFooter.js +85 -22
  678. package/dist/canvas-backend/headerFooter.js.map +1 -1
  679. package/dist/canvas-backend/index.d.ts +17 -3
  680. package/dist/canvas-backend/index.d.ts.map +1 -1
  681. package/dist/canvas-backend/index.js +75 -14
  682. package/dist/canvas-backend/index.js.map +1 -1
  683. package/dist/canvas-backend/renderResourceBlock.d.ts +45 -5
  684. package/dist/canvas-backend/renderResourceBlock.d.ts.map +1 -1
  685. package/dist/canvas-backend/renderResourceBlock.js +133 -22
  686. package/dist/canvas-backend/renderResourceBlock.js.map +1 -1
  687. package/dist/columnClip.d.ts +13 -2
  688. package/dist/columnClip.d.ts.map +1 -1
  689. package/dist/columnClip.js +37 -4
  690. package/dist/columnClip.js.map +1 -1
  691. package/dist/columnRule.d.ts +7 -2
  692. package/dist/columnRule.d.ts.map +1 -1
  693. package/dist/columnRule.js +27 -2
  694. package/dist/columnRule.js.map +1 -1
  695. package/dist/configWarnings.d.ts +26 -0
  696. package/dist/configWarnings.d.ts.map +1 -0
  697. package/dist/configWarnings.js +223 -0
  698. package/dist/configWarnings.js.map +1 -0
  699. package/dist/createLayout.d.ts +16 -1
  700. package/dist/createLayout.d.ts.map +1 -1
  701. package/dist/createLayout.js +25 -22
  702. package/dist/createLayout.js.map +1 -1
  703. package/dist/cropMarks.d.ts +28 -0
  704. package/dist/cropMarks.d.ts.map +1 -0
  705. package/dist/cropMarks.js +40 -0
  706. package/dist/cropMarks.js.map +1 -0
  707. package/dist/defaults/bodyText.d.ts +12 -2
  708. package/dist/defaults/bodyText.d.ts.map +1 -1
  709. package/dist/defaults/bodyText.js +132 -7
  710. package/dist/defaults/bodyText.js.map +1 -1
  711. package/dist/defaults/calloutStyles.d.ts +13 -2
  712. package/dist/defaults/calloutStyles.d.ts.map +1 -1
  713. package/dist/defaults/calloutStyles.js +64 -4
  714. package/dist/defaults/calloutStyles.js.map +1 -1
  715. package/dist/defaults/chipStyles.d.ts +4 -3
  716. package/dist/defaults/chipStyles.d.ts.map +1 -1
  717. package/dist/defaults/chipStyles.js +11 -3
  718. package/dist/defaults/chipStyles.js.map +1 -1
  719. package/dist/defaults/headerFooter.d.ts +11 -1
  720. package/dist/defaults/headerFooter.d.ts.map +1 -1
  721. package/dist/defaults/headerFooter.js +52 -4
  722. package/dist/defaults/headerFooter.js.map +1 -1
  723. package/dist/defaults/headingStyles.d.ts +7 -3
  724. package/dist/defaults/headingStyles.d.ts.map +1 -1
  725. package/dist/defaults/headingStyles.js +34 -6
  726. package/dist/defaults/headingStyles.js.map +1 -1
  727. package/dist/defaults/headings.d.ts +10 -2
  728. package/dist/defaults/headings.d.ts.map +1 -1
  729. package/dist/defaults/headings.js +79 -16
  730. package/dist/defaults/headings.js.map +1 -1
  731. package/dist/defaults/index.d.ts +1 -1
  732. package/dist/defaults/index.d.ts.map +1 -1
  733. package/dist/defaults/index.js +1 -1
  734. package/dist/defaults/index.js.map +1 -1
  735. package/dist/defaults/layout.d.ts.map +1 -1
  736. package/dist/defaults/layout.js +27 -0
  737. package/dist/defaults/layout.js.map +1 -1
  738. package/dist/defaults/lists-shared.d.ts +2 -0
  739. package/dist/defaults/lists-shared.d.ts.map +1 -1
  740. package/dist/defaults/lists-shared.js +2 -0
  741. package/dist/defaults/lists-shared.js.map +1 -1
  742. package/dist/defaults/math.d.ts.map +1 -1
  743. package/dist/defaults/math.js +12 -0
  744. package/dist/defaults/math.js.map +1 -1
  745. package/dist/defaults/orderedLists.d.ts +7 -1
  746. package/dist/defaults/orderedLists.d.ts.map +1 -1
  747. package/dist/defaults/orderedLists.js +30 -4
  748. package/dist/defaults/orderedLists.js.map +1 -1
  749. package/dist/defaults/page.d.ts.map +1 -1
  750. package/dist/defaults/page.js +7 -2
  751. package/dist/defaults/page.js.map +1 -1
  752. package/dist/defaults/paragraphStyles.d.ts +2 -1
  753. package/dist/defaults/paragraphStyles.d.ts.map +1 -1
  754. package/dist/defaults/paragraphStyles.js +26 -1
  755. package/dist/defaults/paragraphStyles.js.map +1 -1
  756. package/dist/defaults/resourceTypes.d.ts +5 -1
  757. package/dist/defaults/resourceTypes.d.ts.map +1 -1
  758. package/dist/defaults/resourceTypes.js +37 -6
  759. package/dist/defaults/resourceTypes.js.map +1 -1
  760. package/dist/defaults/shared.d.ts +10 -0
  761. package/dist/defaults/shared.d.ts.map +1 -1
  762. package/dist/defaults/shared.js +79 -0
  763. package/dist/defaults/shared.js.map +1 -1
  764. package/dist/defaults/tableStyle.d.ts +1 -1
  765. package/dist/defaults/tableStyle.d.ts.map +1 -1
  766. package/dist/defaults/tableStyle.js +40 -6
  767. package/dist/defaults/tableStyle.js.map +1 -1
  768. package/dist/defaults/toc.d.ts +2 -1
  769. package/dist/defaults/toc.d.ts.map +1 -1
  770. package/dist/defaults/toc.js +2 -1
  771. package/dist/defaults/toc.js.map +1 -1
  772. package/dist/defaults/unorderedLists.d.ts +1 -0
  773. package/dist/defaults/unorderedLists.d.ts.map +1 -1
  774. package/dist/defaults/unorderedLists.js +7 -1
  775. package/dist/defaults/unorderedLists.js.map +1 -1
  776. package/dist/design/layout.d.ts +41 -3
  777. package/dist/design/layout.d.ts.map +1 -1
  778. package/dist/design/layout.js +322 -90
  779. package/dist/design/layout.js.map +1 -1
  780. package/dist/design/placeholders.d.ts +39 -4
  781. package/dist/design/placeholders.d.ts.map +1 -1
  782. package/dist/design/placeholders.js +61 -11
  783. package/dist/design/placeholders.js.map +1 -1
  784. package/dist/design/richText.d.ts +110 -0
  785. package/dist/design/richText.d.ts.map +1 -0
  786. package/dist/design/richText.js +458 -0
  787. package/dist/design/richText.js.map +1 -0
  788. package/dist/frontmatter.d.ts +14 -0
  789. package/dist/frontmatter.d.ts.map +1 -1
  790. package/dist/frontmatter.js +61 -0
  791. package/dist/frontmatter.js.map +1 -1
  792. package/dist/html-backend.d.ts +60 -2
  793. package/dist/html-backend.d.ts.map +1 -1
  794. package/dist/html-backend.js +317 -62
  795. package/dist/html-backend.js.map +1 -1
  796. package/dist/hyphenate.d.ts +30 -4
  797. package/dist/hyphenate.d.ts.map +1 -1
  798. package/dist/hyphenate.js +71 -5
  799. package/dist/hyphenate.js.map +1 -1
  800. package/dist/index.d.ts +28 -19
  801. package/dist/index.d.ts.map +1 -1
  802. package/dist/index.js +17 -11
  803. package/dist/index.js.map +1 -1
  804. package/dist/knuthPlass/breakpoints.d.ts +21 -0
  805. package/dist/knuthPlass/breakpoints.d.ts.map +1 -1
  806. package/dist/knuthPlass/breakpoints.js +205 -14
  807. package/dist/knuthPlass/breakpoints.js.map +1 -1
  808. package/dist/knuthPlass/constants.d.ts +15 -0
  809. package/dist/knuthPlass/constants.d.ts.map +1 -1
  810. package/dist/knuthPlass/constants.js +15 -0
  811. package/dist/knuthPlass/constants.js.map +1 -1
  812. package/dist/knuthPlass/pretextAdapter.d.ts +23 -2
  813. package/dist/knuthPlass/pretextAdapter.d.ts.map +1 -1
  814. package/dist/knuthPlass/pretextAdapter.js +95 -9
  815. package/dist/knuthPlass/pretextAdapter.js.map +1 -1
  816. package/dist/knuthPlass/richAdapter.d.ts +26 -2
  817. package/dist/knuthPlass/richAdapter.d.ts.map +1 -1
  818. package/dist/knuthPlass/richAdapter.js +79 -18
  819. package/dist/knuthPlass/richAdapter.js.map +1 -1
  820. package/dist/knuthPlass/tracking.d.ts +24 -0
  821. package/dist/knuthPlass/tracking.d.ts.map +1 -0
  822. package/dist/knuthPlass/tracking.js +77 -0
  823. package/dist/knuthPlass/tracking.js.map +1 -0
  824. package/dist/knuthPlass/types.d.ts +66 -4
  825. package/dist/knuthPlass/types.d.ts.map +1 -1
  826. package/dist/lineInk.d.ts +12 -0
  827. package/dist/lineInk.d.ts.map +1 -0
  828. package/dist/lineInk.js +20 -0
  829. package/dist/lineInk.js.map +1 -0
  830. package/dist/locale.d.ts +26 -0
  831. package/dist/locale.d.ts.map +1 -0
  832. package/dist/locale.js +63 -0
  833. package/dist/locale.js.map +1 -0
  834. package/dist/looseLines.d.ts +44 -0
  835. package/dist/looseLines.d.ts.map +1 -0
  836. package/dist/looseLines.js +46 -0
  837. package/dist/looseLines.js.map +1 -0
  838. package/dist/math/THIRD_PARTY_LICENSES.txt +221 -0
  839. package/dist/math/engine.d.ts +24 -0
  840. package/dist/math/engine.d.ts.map +1 -1
  841. package/dist/math/engine.js +252 -83
  842. package/dist/math/engine.js.map +1 -1
  843. package/dist/math/index.d.ts +1 -1
  844. package/dist/math/index.d.ts.map +1 -1
  845. package/dist/math/index.js +1 -1
  846. package/dist/math/index.js.map +1 -1
  847. package/dist/math/mathjax.d.ts +20 -0
  848. package/dist/math/mathjax.d.ts.map +1 -0
  849. package/dist/math/mathjax.js +29 -0
  850. package/dist/measure/breakRules.d.ts +50 -0
  851. package/dist/measure/breakRules.d.ts.map +1 -0
  852. package/dist/measure/breakRules.js +116 -0
  853. package/dist/measure/breakRules.js.map +1 -0
  854. package/dist/measure/cache.d.ts.map +1 -1
  855. package/dist/measure/cache.js +26 -5
  856. package/dist/measure/cache.js.map +1 -1
  857. package/dist/measure/cjk.d.ts +19 -0
  858. package/dist/measure/cjk.d.ts.map +1 -0
  859. package/dist/measure/cjk.js +70 -0
  860. package/dist/measure/cjk.js.map +1 -0
  861. package/dist/measure/font.d.ts +21 -5
  862. package/dist/measure/font.d.ts.map +1 -1
  863. package/dist/measure/font.js +61 -4
  864. package/dist/measure/font.js.map +1 -1
  865. package/dist/measure/index.d.ts +16 -2
  866. package/dist/measure/index.d.ts.map +1 -1
  867. package/dist/measure/index.js +61 -1
  868. package/dist/measure/index.js.map +1 -1
  869. package/dist/measure/links.d.ts +15 -0
  870. package/dist/measure/links.d.ts.map +1 -0
  871. package/dist/measure/links.js +115 -0
  872. package/dist/measure/links.js.map +1 -0
  873. package/dist/measure/plain.d.ts +10 -2
  874. package/dist/measure/plain.d.ts.map +1 -1
  875. package/dist/measure/plain.js +175 -25
  876. package/dist/measure/plain.js.map +1 -1
  877. package/dist/measure/rich.d.ts +86 -6
  878. package/dist/measure/rich.d.ts.map +1 -1
  879. package/dist/measure/rich.js +808 -131
  880. package/dist/measure/rich.js.map +1 -1
  881. package/dist/measure/spaces.d.ts +34 -0
  882. package/dist/measure/spaces.d.ts.map +1 -0
  883. package/dist/measure/spaces.js +42 -0
  884. package/dist/measure/spaces.js.map +1 -0
  885. package/dist/measure/types.d.ts +99 -0
  886. package/dist/measure/types.d.ts.map +1 -1
  887. package/dist/measure/types.js +19 -0
  888. package/dist/measure/types.js.map +1 -1
  889. package/dist/numberWords.d.ts +22 -0
  890. package/dist/numberWords.d.ts.map +1 -0
  891. package/dist/numberWords.js +155 -0
  892. package/dist/numberWords.js.map +1 -0
  893. package/dist/numbering.d.ts +52 -3
  894. package/dist/numbering.d.ts.map +1 -1
  895. package/dist/numbering.js +116 -16
  896. package/dist/numbering.js.map +1 -1
  897. package/dist/parse/blockParser.d.ts.map +1 -1
  898. package/dist/parse/blockParser.js +54 -7
  899. package/dist/parse/blockParser.js.map +1 -1
  900. package/dist/parse/index.d.ts +1 -1
  901. package/dist/parse/index.d.ts.map +1 -1
  902. package/dist/parse/index.js.map +1 -1
  903. package/dist/parse/injectSpans.d.ts +3 -1
  904. package/dist/parse/injectSpans.d.ts.map +1 -1
  905. package/dist/parse/injectSpans.js +8 -4
  906. package/dist/parse/injectSpans.js.map +1 -1
  907. package/dist/parse/inlineFormatting.d.ts +50 -2
  908. package/dist/parse/inlineFormatting.d.ts.map +1 -1
  909. package/dist/parse/inlineFormatting.js +441 -26
  910. package/dist/parse/inlineFormatting.js.map +1 -1
  911. package/dist/parse/inlineSnippet.d.ts +12 -3
  912. package/dist/parse/inlineSnippet.d.ts.map +1 -1
  913. package/dist/parse/inlineSnippet.js +10 -3
  914. package/dist/parse/inlineSnippet.js.map +1 -1
  915. package/dist/parse/links.d.ts +9 -0
  916. package/dist/parse/links.d.ts.map +1 -0
  917. package/dist/parse/links.js +23 -0
  918. package/dist/parse/links.js.map +1 -0
  919. package/dist/parse/sourceMapping.d.ts.map +1 -1
  920. package/dist/parse/sourceMapping.js +68 -7
  921. package/dist/parse/sourceMapping.js.map +1 -1
  922. package/dist/parse/types.d.ts +32 -0
  923. package/dist/parse/types.d.ts.map +1 -1
  924. package/dist/pipeline/bandCaps.d.ts +26 -5
  925. package/dist/pipeline/bandCaps.d.ts.map +1 -1
  926. package/dist/pipeline/bandCaps.js +47 -20
  927. package/dist/pipeline/bandCaps.js.map +1 -1
  928. package/dist/pipeline/build.d.ts.map +1 -1
  929. package/dist/pipeline/build.js +1417 -172
  930. package/dist/pipeline/build.js.map +1 -1
  931. package/dist/pipeline/buildBlockKind.d.ts +4 -0
  932. package/dist/pipeline/buildBlockKind.d.ts.map +1 -1
  933. package/dist/pipeline/buildBlockKind.js +38 -7
  934. package/dist/pipeline/buildBlockKind.js.map +1 -1
  935. package/dist/pipeline/buildHelpers.d.ts +5 -2
  936. package/dist/pipeline/buildHelpers.d.ts.map +1 -1
  937. package/dist/pipeline/buildHelpers.js +101 -25
  938. package/dist/pipeline/buildHelpers.js.map +1 -1
  939. package/dist/pipeline/buildMeasurement.d.ts.map +1 -1
  940. package/dist/pipeline/buildMeasurement.js +6 -2
  941. package/dist/pipeline/buildMeasurement.js.map +1 -1
  942. package/dist/pipeline/calloutLayout.d.ts +34 -7
  943. package/dist/pipeline/calloutLayout.d.ts.map +1 -1
  944. package/dist/pipeline/calloutLayout.js +331 -44
  945. package/dist/pipeline/calloutLayout.js.map +1 -1
  946. package/dist/pipeline/chips.d.ts.map +1 -1
  947. package/dist/pipeline/chips.js +3 -0
  948. package/dist/pipeline/chips.js.map +1 -1
  949. package/dist/pipeline/columnBalancing.d.ts +26 -6
  950. package/dist/pipeline/columnBalancing.d.ts.map +1 -1
  951. package/dist/pipeline/columnBalancing.js +82 -21
  952. package/dist/pipeline/columnBalancing.js.map +1 -1
  953. package/dist/pipeline/config.d.ts +18 -0
  954. package/dist/pipeline/config.d.ts.map +1 -1
  955. package/dist/pipeline/config.js +44 -7
  956. package/dist/pipeline/config.js.map +1 -1
  957. package/dist/pipeline/contentWarnings.d.ts +50 -0
  958. package/dist/pipeline/contentWarnings.d.ts.map +1 -0
  959. package/dist/pipeline/contentWarnings.js +363 -0
  960. package/dist/pipeline/contentWarnings.js.map +1 -0
  961. package/dist/pipeline/continuation.d.ts.map +1 -1
  962. package/dist/pipeline/continuation.js +25 -5
  963. package/dist/pipeline/continuation.js.map +1 -1
  964. package/dist/pipeline/floatPlacement.d.ts +16 -7
  965. package/dist/pipeline/floatPlacement.d.ts.map +1 -1
  966. package/dist/pipeline/floatPlacement.js +22 -5
  967. package/dist/pipeline/floatPlacement.js.map +1 -1
  968. package/dist/pipeline/floatSlots.d.ts +30 -4
  969. package/dist/pipeline/floatSlots.d.ts.map +1 -1
  970. package/dist/pipeline/floatSlots.js +42 -7
  971. package/dist/pipeline/floatSlots.js.map +1 -1
  972. package/dist/pipeline/headerFooter.d.ts +125 -11
  973. package/dist/pipeline/headerFooter.d.ts.map +1 -1
  974. package/dist/pipeline/headerFooter.js +444 -69
  975. package/dist/pipeline/headerFooter.js.map +1 -1
  976. package/dist/pipeline/headingDesignCuts.d.ts +40 -0
  977. package/dist/pipeline/headingDesignCuts.d.ts.map +1 -0
  978. package/dist/pipeline/headingDesignCuts.js +72 -0
  979. package/dist/pipeline/headingDesignCuts.js.map +1 -0
  980. package/dist/pipeline/headingStyles.d.ts +12 -0
  981. package/dist/pipeline/headingStyles.d.ts.map +1 -1
  982. package/dist/pipeline/headingStyles.js +45 -1
  983. package/dist/pipeline/headingStyles.js.map +1 -1
  984. package/dist/pipeline/lists.d.ts +33 -1
  985. package/dist/pipeline/lists.d.ts.map +1 -1
  986. package/dist/pipeline/lists.js +53 -2
  987. package/dist/pipeline/lists.js.map +1 -1
  988. package/dist/pipeline/measureContentBlock.d.ts +25 -1
  989. package/dist/pipeline/measureContentBlock.d.ts.map +1 -1
  990. package/dist/pipeline/measureContentBlock.js +137 -17
  991. package/dist/pipeline/measureContentBlock.js.map +1 -1
  992. package/dist/pipeline/outline.d.ts +10 -5
  993. package/dist/pipeline/outline.d.ts.map +1 -1
  994. package/dist/pipeline/outline.js +38 -14
  995. package/dist/pipeline/outline.js.map +1 -1
  996. package/dist/pipeline/paragraphContainers.d.ts +13 -4
  997. package/dist/pipeline/paragraphContainers.d.ts.map +1 -1
  998. package/dist/pipeline/paragraphContainers.js +4 -3
  999. package/dist/pipeline/paragraphContainers.js.map +1 -1
  1000. package/dist/pipeline/partPalette.d.ts +49 -3
  1001. package/dist/pipeline/partPalette.d.ts.map +1 -1
  1002. package/dist/pipeline/partPalette.js +414 -46
  1003. package/dist/pipeline/partPalette.js.map +1 -1
  1004. package/dist/pipeline/parts.d.ts +5 -1
  1005. package/dist/pipeline/parts.d.ts.map +1 -1
  1006. package/dist/pipeline/parts.js +16 -0
  1007. package/dist/pipeline/parts.js.map +1 -1
  1008. package/dist/pipeline/placeholders.d.ts +152 -3
  1009. package/dist/pipeline/placeholders.d.ts.map +1 -1
  1010. package/dist/pipeline/placeholders.js +259 -33
  1011. package/dist/pipeline/placeholders.js.map +1 -1
  1012. package/dist/pipeline/placement.d.ts +6 -1
  1013. package/dist/pipeline/placement.d.ts.map +1 -1
  1014. package/dist/pipeline/placement.js +13 -2
  1015. package/dist/pipeline/placement.js.map +1 -1
  1016. package/dist/pipeline/raggedLines.d.ts +5 -0
  1017. package/dist/pipeline/raggedLines.d.ts.map +1 -1
  1018. package/dist/pipeline/raggedLines.js +24 -3
  1019. package/dist/pipeline/raggedLines.js.map +1 -1
  1020. package/dist/pipeline/resourceLayout.d.ts +6 -4
  1021. package/dist/pipeline/resourceLayout.d.ts.map +1 -1
  1022. package/dist/pipeline/resourceLayout.js +137 -36
  1023. package/dist/pipeline/resourceLayout.js.map +1 -1
  1024. package/dist/pipeline/resourceNumbering.d.ts.map +1 -1
  1025. package/dist/pipeline/resourceNumbering.js +5 -15
  1026. package/dist/pipeline/resourceNumbering.js.map +1 -1
  1027. package/dist/pipeline/styles.d.ts +38 -5
  1028. package/dist/pipeline/styles.d.ts.map +1 -1
  1029. package/dist/pipeline/styles.js +99 -46
  1030. package/dist/pipeline/styles.js.map +1 -1
  1031. package/dist/pipeline/toc.d.ts.map +1 -1
  1032. package/dist/pipeline/toc.js +41 -5
  1033. package/dist/pipeline/toc.js.map +1 -1
  1034. package/dist/react/createLayout.d.ts +20 -0
  1035. package/dist/react/createLayout.d.ts.map +1 -0
  1036. package/dist/react/createLayout.js +50 -0
  1037. package/dist/react/createLayout.js.map +1 -0
  1038. package/dist/react/index.d.ts +3 -0
  1039. package/dist/react/index.d.ts.map +1 -0
  1040. package/dist/react/index.js +4 -0
  1041. package/dist/react/index.js.map +1 -0
  1042. package/dist/svg/singleInk.d.ts +46 -1
  1043. package/dist/svg/singleInk.d.ts.map +1 -1
  1044. package/dist/svg/singleInk.js +180 -10
  1045. package/dist/svg/singleInk.js.map +1 -1
  1046. package/dist/table/model.d.ts +36 -1
  1047. package/dist/table/model.d.ts.map +1 -1
  1048. package/dist/table/model.js +163 -20
  1049. package/dist/table/model.js.map +1 -1
  1050. package/dist/types.d.ts +979 -68
  1051. package/dist/types.d.ts.map +1 -1
  1052. package/dist/vdt.d.ts +439 -13
  1053. package/dist/vdt.d.ts.map +1 -1
  1054. package/dist/vdt.js +91 -0
  1055. package/dist/vdt.js.map +1 -1
  1056. package/dist/worker/client.d.ts +15 -1
  1057. package/dist/worker/client.d.ts.map +1 -1
  1058. package/dist/worker/client.js +52 -3
  1059. package/dist/worker/client.js.map +1 -1
  1060. package/dist/worker/entryUrl.d.ts +15 -0
  1061. package/dist/worker/entryUrl.d.ts.map +1 -0
  1062. package/dist/worker/entryUrl.js +33 -0
  1063. package/dist/worker/entryUrl.js.map +1 -0
  1064. package/dist/worker/fonts.d.ts +18 -0
  1065. package/dist/worker/fonts.d.ts.map +1 -0
  1066. package/dist/worker/fonts.js +53 -0
  1067. package/dist/worker/fonts.js.map +1 -0
  1068. package/dist/worker/layout.worker.js +41 -6
  1069. package/dist/worker/layout.worker.js.map +1 -1
  1070. package/dist/worker/protocol.d.ts +4 -0
  1071. package/dist/worker/protocol.d.ts.map +1 -1
  1072. package/package.json +12 -5
@@ -3,6 +3,12 @@ export interface KPBox {
3
3
  width: number;
4
4
  sourceIndex: number;
5
5
  meta?: unknown;
6
+ /** Characters the box paints as text: what tracking would spread (see
7
+ * `KPOptions.trackingPerChar`). 0 or absent for a formula or a swatch. */
8
+ chars?: number;
9
+ /** A box tracking must not reach (a chip paints its own runs): a line
10
+ * that holds one takes no tracking. */
11
+ noTracking?: boolean;
6
12
  }
7
13
  export interface KPGlue {
8
14
  type: 'glue';
@@ -19,6 +25,17 @@ export interface KPPenalty {
19
25
  flagged: boolean;
20
26
  sourceIndex: number;
21
27
  meta?: unknown;
28
+ /** Characters the break adds to its line (the hyphen of a syllable). */
29
+ chars?: number;
30
+ /** A dictionary syllable of ragged text: taken only where sending the
31
+ * word whole to the next line would leave more than
32
+ * `KPOptions.hyphenationZone` empty (see there). */
33
+ zoned?: boolean;
34
+ /** Width (px) the break adds at the start of the next line, and its
35
+ * characters: the hyphen of a compound repeated there
36
+ * (`MeasureBlockOptions.repeatHyphen`). TeX's post-break text. */
37
+ postWidth?: number;
38
+ postChars?: number;
22
39
  }
23
40
  export type KPItem = KPBox | KPGlue | KPPenalty;
24
41
  export interface KPOptions {
@@ -43,14 +60,36 @@ export interface KPOptions {
43
60
  /** Minimum content width (in px) the final line must have to avoid the runt
44
61
  * penalty. Typically `runtMinCharacters * normalSpaceWidth`. */
45
62
  runtMinWidth?: number;
63
+ /** Scale `runtPenalty` by the final line's shortfall: a last line of
64
+ * content width `w` pays `runtPenalty × (1 − w / runtMinWidth)`, so the
65
+ * shorter the runt the dearer it is. Default false: every runt pays the
66
+ * whole penalty. */
67
+ runtGraded?: boolean;
68
+ /** Line numbers (1-based) that must not end on a hyphen: the lines that
69
+ * close a column or a page (`BodyTextConfig.hyphenateAcrossColumns`). A
70
+ * hyphenated break ending one of them costs
71
+ * {@link COLUMN_END_HYPHEN_BADNESS} more, so the breaker takes a
72
+ * whole-word break there whenever one keeps the spaces within their
73
+ * limits. Line counts are kept apart up to the last of them. */
74
+ avoidHyphenAtLines?: readonly number[];
75
+ /** Item positions the first lines must break at, in order: line 1 ends
76
+ * at `fixedBreaks[0]`, line 2 at `fixedBreaks[1]`, and so on. A
77
+ * paragraph broken again after its first lines were placed keeps them
78
+ * this way (see `MeasureBlockOptions.keepBreaks`); the rest of it is
79
+ * broken as usual. Line counts are kept apart up to the last of them. */
80
+ fixedBreaks?: readonly number[];
46
81
  /** TeX-style \looseness: prefer a final break sequence with exactly
47
82
  * (natural + looseness) lines. A positive value runs the paragraph long
48
83
  * and is taken only when every line of that sequence stays within the
49
84
  * configured stretch limit (adjustment ratio < 1.0, i.e. word spacing
50
- * below `maxStretchRatio`); a negative one runs it short, and every
51
- * feasible sequence already keeps its spaces at or above
52
- * `minShrinkRatio`, so no further gate applies. Falls back silently to
53
- * the natural solution when no such sequence exists. Default 0 (off). */
85
+ * below `maxStretchRatio`); a negative one runs it short (every feasible
86
+ * sequence keeps its spaces at or above `minShrinkRatio`) and is taken
87
+ * only when none of its lines that stay justified sets its word spaces
88
+ * wider than `maxStretchRatio` or than the natural sequence's loosest
89
+ * such line, whichever is looser, and it has no more lines past 3× the
90
+ * normal space (which the pipeline sets ragged) than the natural one
91
+ * (EF-65). Falls back silently to the natural solution when no such
92
+ * sequence exists. Default 0 (off). */
54
93
  looseness?: number;
55
94
  /** The line index from which `lineWidth` no longer varies (1 when only
56
95
  * the first line is indented, 0 when no line is). Lets the DP merge
@@ -60,6 +99,27 @@ export interface KPOptions {
60
99
  * nodes grows with the paragraph and the search goes quadratic. Ignored
61
100
  * while `looseness` asks for an exact line count, long or short. */
62
101
  lineWidthUniformFrom?: number;
102
+ /** Tracking a justified line may take, in px added after every character
103
+ * (either way), when its word spaces alone would stretch past the
104
+ * stretch limit or shrink past the shrink limit: the part of the
105
+ * adjustment beyond the limit goes into the letters, up to this much a
106
+ * character (`bodyText.maxJustifyTracking`). A line of one word, or one
107
+ * holding a chip, takes none. 0 or absent: off. See `adjustLine`. */
108
+ trackingPerChar?: number;
109
+ /** A ragged setting (`MeasureBlockOptions.optimalRagged`): every line
110
+ * but the last gets this much stretch (px) on top of its glue's, the
111
+ * right-hand glue of Knuth and Plass's ragged model, and the word spaces
112
+ * are given none. A line short of its measure by this much has the
113
+ * badness of a justified line at its stretch limit. The looseness gate
114
+ * on word spacing does not apply. Unset or 0: justified. */
115
+ raggedStretch?: number;
116
+ /** Hyphenation zone of ragged text (px), the rule of the line-by-line
117
+ * breaker: a penalty marked `zoned` ends a line only inside a word that
118
+ * does not fit the rest of the line, and only when the line, ended
119
+ * instead at the word space before that word, would fall short of its
120
+ * measure by more than this (a word that opens its line cannot go down).
121
+ * Unset: every penalty is a candidate. */
122
+ hyphenationZone?: number;
63
123
  }
64
124
  export interface RichTokenMeta {
65
125
  bold: boolean;
@@ -72,5 +132,7 @@ export interface RichTokenMeta {
72
132
  /** On a penalty: the break is bare (a hard hyphen the word carries), so
73
133
  * the line ends as it is and no hyphen is added. */
74
134
  bare?: boolean;
135
+ /** On a penalty: a break between ideographs — no hyphen, no penalty. */
136
+ free?: boolean;
75
137
  }
76
138
  //# sourceMappingURL=types.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/knuthPlass/types.ts"],"names":[],"mappings":"AAIA,MAAM,WAAW,KAAK;IACpB,IAAI,EAAE,KAAK,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB;AAED,MAAM,WAAW,MAAM;IACrB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB;AAED,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,SAAS,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,OAAO,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB;AAED,MAAM,MAAM,MAAM,GAAG,KAAK,GAAG,MAAM,GAAG,SAAS,CAAC;AAMhD,MAAM,WAAW,SAAS;IACxB,0DAA0D;IAC1D,SAAS,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,MAAM,CAAC;IACzC,uCAAuC;IACvC,gBAAgB,EAAE,MAAM,CAAC;IACzB,sEAAsE;IACtE,eAAe,EAAE,MAAM,CAAC;IACxB,oEAAoE;IACpE,cAAc,EAAE,MAAM,CAAC;IACvB,oDAAoD;IACpD,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,8DAA8D;IAC9D,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B;;;;uEAImE;IACnE,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;qEACiE;IACjE,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;;;;;8EAO0E;IAC1E,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;;;yEAMqE;IACrE,oBAAoB,CAAC,EAAE,MAAM,CAAC;CAC/B;AAMD,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,OAAO,CAAC;IACd,MAAM,EAAE,OAAO,CAAC;IAChB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,2EAA2E;IAC3E,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,yEAAyE;IACzE,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;yDACqD;IACrD,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB"}
1
+ {"version":3,"file":"types.d.ts","sourceRoot":"","sources":["../../src/knuthPlass/types.ts"],"names":[],"mappings":"AAIA,MAAM,WAAW,KAAK;IACpB,IAAI,EAAE,KAAK,CAAC;IACZ,KAAK,EAAE,MAAM,CAAC;IACd,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf;+EAC2E;IAC3E,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;4CACwC;IACxC,UAAU,CAAC,EAAE,OAAO,CAAC;CACtB;AAED,MAAM,WAAW,MAAM;IACrB,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB;AAED,MAAM,WAAW,SAAS;IACxB,IAAI,EAAE,SAAS,CAAC;IAChB,KAAK,EAAE,MAAM,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,OAAO,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,wEAAwE;IACxE,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;yDAEqD;IACrD,KAAK,CAAC,EAAE,OAAO,CAAC;IAChB;;uEAEmE;IACnE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,MAAM,MAAM,GAAG,KAAK,GAAG,MAAM,GAAG,SAAS,CAAC;AAMhD,MAAM,WAAW,SAAS;IACxB,0DAA0D;IAC1D,SAAS,EAAE,CAAC,SAAS,EAAE,MAAM,KAAK,MAAM,CAAC;IACzC,uCAAuC;IACvC,gBAAgB,EAAE,MAAM,CAAC;IACzB,sEAAsE;IACtE,eAAe,EAAE,MAAM,CAAC;IACxB,oEAAoE;IACpE,cAAc,EAAE,MAAM,CAAC;IACvB,oDAAoD;IACpD,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,8DAA8D;IAC9D,mBAAmB,CAAC,EAAE,MAAM,CAAC;IAC7B;;;;uEAImE;IACnE,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB;qEACiE;IACjE,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB;;;yBAGqB;IACrB,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;;;;qEAKiE;IACjE,kBAAkB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IACvC;;;;8EAI0E;IAC1E,WAAW,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAChC;;;;;;;;;;;4CAWwC;IACxC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;;;yEAMqE;IACrE,oBAAoB,CAAC,EAAE,MAAM,CAAC;IAC9B;;;;;0EAKsE;IACtE,eAAe,CAAC,EAAE,MAAM,CAAC;IACzB;;;;;iEAK6D;IAC7D,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB;;;;;+CAK2C;IAC3C,eAAe,CAAC,EAAE,MAAM,CAAC;CAC1B;AAMD,MAAM,WAAW,aAAa;IAC5B,IAAI,EAAE,OAAO,CAAC;IACd,MAAM,EAAE,OAAO,CAAC;IAChB,kBAAkB,EAAE,MAAM,CAAC;IAC3B,2EAA2E;IAC3E,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,yEAAyE;IACzE,MAAM,CAAC,EAAE,MAAM,CAAC;IAChB;yDACqD;IACrD,IAAI,CAAC,EAAE,OAAO,CAAC;IACf,wEAAwE;IACxE,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB"}
@@ -0,0 +1,12 @@
1
+ import type { VDTLine } from './vdt';
2
+ /**
3
+ * The tracking a flow line's measured width carries after its last glyph:
4
+ * `tracking` (the block's `letterSpacing` plus the line's) when the line
5
+ * ends on text, else 0. Canvas, CSS and PDF add tracking after every
6
+ * character, the last one included; that last share is advance, not ink,
7
+ * so a centred or right-aligned line leaves it out, as design text does
8
+ * (EF-153). A line that ends on a formula, a chip, a swatch or a space
9
+ * keeps its width as it is.
10
+ */
11
+ export declare function lineTrailingTracking(line: VDTLine, tracking: number): number;
12
+ //# sourceMappingURL=lineInk.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lineInk.d.ts","sourceRoot":"","sources":["../src/lineInk.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAErC;;;;;;;;GAQG;AACH,wBAAgB,oBAAoB,CAAC,IAAI,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,GAAG,MAAM,CAQ5E"}
@@ -0,0 +1,20 @@
1
+ /**
2
+ * The tracking a flow line's measured width carries after its last glyph:
3
+ * `tracking` (the block's `letterSpacing` plus the line's) when the line
4
+ * ends on text, else 0. Canvas, CSS and PDF add tracking after every
5
+ * character, the last one included; that last share is advance, not ink,
6
+ * so a centred or right-aligned line leaves it out, as design text does
7
+ * (EF-153). A line that ends on a formula, a chip, a swatch or a space
8
+ * keeps its width as it is.
9
+ */
10
+ export function lineTrailingTracking(line, tracking) {
11
+ if (tracking === 0)
12
+ return 0;
13
+ const segments = line.segments;
14
+ if (segments && segments.length > 0) {
15
+ const last = segments[segments.length - 1];
16
+ return last.kind === 'text' && last.text.length > 0 ? tracking : 0;
17
+ }
18
+ return /\S$/.test(line.text) ? tracking : 0;
19
+ }
20
+ //# sourceMappingURL=lineInk.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"lineInk.js","sourceRoot":"","sources":["../src/lineInk.ts"],"names":[],"mappings":"AAEA;;;;;;;;GAQG;AACH,MAAM,UAAU,oBAAoB,CAAC,IAAa,EAAE,QAAgB;IAClE,IAAI,QAAQ,KAAK,CAAC;QAAE,OAAO,CAAC,CAAC;IAC7B,MAAM,QAAQ,GAAG,IAAI,CAAC,QAAQ,CAAC;IAC/B,IAAI,QAAQ,IAAI,QAAQ,CAAC,MAAM,GAAG,CAAC,EAAE,CAAC;QACpC,MAAM,IAAI,GAAG,QAAQ,CAAC,QAAQ,CAAC,MAAM,GAAG,CAAC,CAAE,CAAC;QAC5C,OAAO,IAAI,CAAC,IAAI,KAAK,MAAM,IAAI,IAAI,CAAC,IAAI,CAAC,MAAM,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC;IACrE,CAAC;IACD,OAAO,KAAK,CAAC,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC;AAC9C,CAAC"}
@@ -0,0 +1,26 @@
1
+ import type { HyphenationLocale, LocaleTag } from './types';
2
+ /** The languages whose hyphenation patterns ship with the engine. */
3
+ export declare const HYPHENATION_LOCALES: readonly HyphenationLocale[];
4
+ /** The primary language subtag of a BCP 47 tag, lower-cased (`'pt_BR'` →
5
+ * `'pt'`, `'en-us'` → `'en'`). The key of the built-in string tables. */
6
+ export declare function languageOf(tag: string): string;
7
+ /** A configured tag, trimmed, or `undefined` when it is missing, blank or not
8
+ * a string: such a tag counts as unset wherever a locale falls back. */
9
+ export declare function presentTag(tag: unknown): string | undefined;
10
+ /**
11
+ * The bundled hyphenation locale for a BCP 47 language tag, or `undefined`
12
+ * when no patterns ship for its language. Case, `_` separators and any
13
+ * region, script or variant subtags are ignored: `'es-ES'`, `'es_MX'` and
14
+ * `'es-419'` give `'es'`, `'pt-BR'` gives `'pt'`, and every English tag
15
+ * (`'en'`, `'en-GB'`) gives `'en-us'`, the only English patterns.
16
+ */
17
+ export declare function matchHyphenationLocale(tag: string): HyphenationLocale | undefined;
18
+ /**
19
+ * {@link matchHyphenationLocale}, falling back to `'en-us'` for a language
20
+ * with no bundled patterns. The fallback is reported once per tag on the
21
+ * console, since the text is then hyphenated with another language's rules;
22
+ * `warn: false` skips the report (hyphenation is off, so no text uses the
23
+ * patterns). A missing or blank tag gives `'en-us'` silently.
24
+ */
25
+ export declare function hyphenationLocaleFor(tag: LocaleTag, warn?: boolean): HyphenationLocale;
26
+ //# sourceMappingURL=locale.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"locale.d.ts","sourceRoot":"","sources":["../src/locale.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,iBAAiB,EAAE,SAAS,EAAE,MAAM,SAAS,CAAC;AAE5D,qEAAqE;AACrE,eAAO,MAAM,mBAAmB,EAAE,SAAS,iBAAiB,EAEjD,CAAC;AAIZ;0EAC0E;AAC1E,wBAAgB,UAAU,CAAC,GAAG,EAAE,MAAM,GAAG,MAAM,CAE9C;AAQD;yEACyE;AACzE,wBAAgB,UAAU,CAAC,GAAG,EAAE,OAAO,GAAG,MAAM,GAAG,SAAS,CAE3D;AAED;;;;;;GAMG;AACH,wBAAgB,sBAAsB,CAAC,GAAG,EAAE,MAAM,GAAG,iBAAiB,GAAG,SAAS,CAQjF;AAKD;;;;;;GAMG;AACH,wBAAgB,oBAAoB,CAAC,GAAG,EAAE,SAAS,EAAE,IAAI,UAAO,GAAG,iBAAiB,CAYnF"}
package/dist/locale.js ADDED
@@ -0,0 +1,63 @@
1
+ /** The languages whose hyphenation patterns ship with the engine. */
2
+ export const HYPHENATION_LOCALES = Object.freeze([
3
+ 'en-us', 'es', 'fr', 'de', 'it', 'pt', 'ca', 'nl',
4
+ ]);
5
+ const BUNDLED = new Set(HYPHENATION_LOCALES);
6
+ /** The primary language subtag of a BCP 47 tag, lower-cased (`'pt_BR'` →
7
+ * `'pt'`, `'en-us'` → `'en'`). The key of the built-in string tables. */
8
+ export function languageOf(tag) {
9
+ return isTag(tag) ? tag.trim().toLowerCase().split(/[-_]/)[0] ?? '' : '';
10
+ }
11
+ /** A tag worth matching: a non-blank string. A missing, blank or non-string
12
+ * tag (an untyped caller passing an unset `config.locale`) counts as unset. */
13
+ function isTag(tag) {
14
+ return typeof tag === 'string' && tag.trim() !== '';
15
+ }
16
+ /** A configured tag, trimmed, or `undefined` when it is missing, blank or not
17
+ * a string: such a tag counts as unset wherever a locale falls back. */
18
+ export function presentTag(tag) {
19
+ return isTag(tag) ? tag.trim() : undefined;
20
+ }
21
+ /**
22
+ * The bundled hyphenation locale for a BCP 47 language tag, or `undefined`
23
+ * when no patterns ship for its language. Case, `_` separators and any
24
+ * region, script or variant subtags are ignored: `'es-ES'`, `'es_MX'` and
25
+ * `'es-419'` give `'es'`, `'pt-BR'` gives `'pt'`, and every English tag
26
+ * (`'en'`, `'en-GB'`) gives `'en-us'`, the only English patterns.
27
+ */
28
+ export function matchHyphenationLocale(tag) {
29
+ if (!isTag(tag))
30
+ return undefined;
31
+ if (BUNDLED.has(tag))
32
+ return tag;
33
+ const t = tag.trim().toLowerCase().replace(/_/g, '-');
34
+ if (BUNDLED.has(t))
35
+ return t;
36
+ const lang = languageOf(t);
37
+ if (lang === 'en')
38
+ return 'en-us';
39
+ return BUNDLED.has(lang) ? lang : undefined;
40
+ }
41
+ /** Tags already reported as unsupported: each is reported once. */
42
+ const warnedTags = new Set();
43
+ /**
44
+ * {@link matchHyphenationLocale}, falling back to `'en-us'` for a language
45
+ * with no bundled patterns. The fallback is reported once per tag on the
46
+ * console, since the text is then hyphenated with another language's rules;
47
+ * `warn: false` skips the report (hyphenation is off, so no text uses the
48
+ * patterns). A missing or blank tag gives `'en-us'` silently.
49
+ */
50
+ export function hyphenationLocaleFor(tag, warn = true) {
51
+ if (!isTag(tag))
52
+ return 'en-us';
53
+ const match = matchHyphenationLocale(tag);
54
+ if (match)
55
+ return match;
56
+ if (warn && !warnedTags.has(tag)) {
57
+ warnedTags.add(tag);
58
+ console.warn(`[postext] No hyphenation patterns for locale "${tag}"; hyphenating with en-us. `
59
+ + `Bundled locales: ${HYPHENATION_LOCALES.join(', ')}.`);
60
+ }
61
+ return 'en-us';
62
+ }
63
+ //# sourceMappingURL=locale.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"locale.js","sourceRoot":"","sources":["../src/locale.ts"],"names":[],"mappings":"AAEA,qEAAqE;AACrE,MAAM,CAAC,MAAM,mBAAmB,GAAiC,MAAM,CAAC,MAAM,CAAC;IAC7E,OAAO,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI,EAAE,IAAI;CACzC,CAAC,CAAC;AAEZ,MAAM,OAAO,GAAG,IAAI,GAAG,CAAS,mBAAmB,CAAC,CAAC;AAErD;0EAC0E;AAC1E,MAAM,UAAU,UAAU,CAAC,GAAW;IACpC,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;AAC3E,CAAC;AAED;gFACgF;AAChF,SAAS,KAAK,CAAC,GAAY;IACzB,OAAO,OAAO,GAAG,KAAK,QAAQ,IAAI,GAAG,CAAC,IAAI,EAAE,KAAK,EAAE,CAAC;AACtD,CAAC;AAED;yEACyE;AACzE,MAAM,UAAU,UAAU,CAAC,GAAY;IACrC,OAAO,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,SAAS,CAAC;AAC7C,CAAC;AAED;;;;;;GAMG;AACH,MAAM,UAAU,sBAAsB,CAAC,GAAW;IAChD,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC;QAAE,OAAO,SAAS,CAAC;IAClC,IAAI,OAAO,CAAC,GAAG,CAAC,GAAG,CAAC;QAAE,OAAO,GAAwB,CAAC;IACtD,MAAM,CAAC,GAAG,GAAG,CAAC,IAAI,EAAE,CAAC,WAAW,EAAE,CAAC,OAAO,CAAC,IAAI,EAAE,GAAG,CAAC,CAAC;IACtD,IAAI,OAAO,CAAC,GAAG,CAAC,CAAC,CAAC;QAAE,OAAO,CAAsB,CAAC;IAClD,MAAM,IAAI,GAAG,UAAU,CAAC,CAAC,CAAC,CAAC;IAC3B,IAAI,IAAI,KAAK,IAAI;QAAE,OAAO,OAAO,CAAC;IAClC,OAAO,OAAO,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,CAAC,CAAE,IAA0B,CAAC,CAAC,CAAC,SAAS,CAAC;AACrE,CAAC;AAED,mEAAmE;AACnE,MAAM,UAAU,GAAG,IAAI,GAAG,EAAU,CAAC;AAErC;;;;;;GAMG;AACH,MAAM,UAAU,oBAAoB,CAAC,GAAc,EAAE,IAAI,GAAG,IAAI;IAC9D,IAAI,CAAC,KAAK,CAAC,GAAG,CAAC;QAAE,OAAO,OAAO,CAAC;IAChC,MAAM,KAAK,GAAG,sBAAsB,CAAC,GAAG,CAAC,CAAC;IAC1C,IAAI,KAAK;QAAE,OAAO,KAAK,CAAC;IACxB,IAAI,IAAI,IAAI,CAAC,UAAU,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC;QACjC,UAAU,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC;QACpB,OAAO,CAAC,IAAI,CACV,iDAAiD,GAAG,6BAA6B;cAC/E,oBAAoB,mBAAmB,CAAC,IAAI,CAAC,IAAI,CAAC,GAAG,CACxD,CAAC;IACJ,CAAC;IACD,OAAO,OAAO,CAAC;AACjB,CAAC"}
@@ -0,0 +1,44 @@
1
+ import type { VDTBlock, VDTDocument, VDTLine, VDTPage } from './vdt';
2
+ /** A justified line whose word spaces stretch past the loose-line threshold,
3
+ * with the band the highlight covers. */
4
+ export interface LooseLine {
5
+ block: VDTBlock;
6
+ line: VDTLine;
7
+ /** Applied word-space width over the font's normal space
8
+ * (`line.justifiedSpaceRatio`). */
9
+ ratio: number;
10
+ /** The highlight band, in page pixels: the block's full width across the
11
+ * line's box. */
12
+ x: number;
13
+ y: number;
14
+ width: number;
15
+ height: number;
16
+ }
17
+ export interface FindLooseLinesOptions {
18
+ /** A line counts as loose when its ratio exceeds this. Default: 3, the
19
+ * default `debug.looseLineHighlight.threshold`; pass a config's own with
20
+ * `resolveDebugConfig(config.debug).looseLineHighlight.threshold`. */
21
+ threshold?: number;
22
+ /** Only the lines of this page. Default: every page. */
23
+ pageIndex?: number;
24
+ }
25
+ export interface DrawLooseLinesOptions {
26
+ /** See {@link FindLooseLinesOptions.threshold}. */
27
+ threshold?: number;
28
+ /** Any canvas fill style. Default: `#ff000040` (a translucent red), the
29
+ * default `debug.looseLineHighlight.color`. */
30
+ color?: string;
31
+ }
32
+ /**
33
+ * The loose lines of a laid-out document, in block and line order: the lines
34
+ * the Sandbox's loose-line highlight and its `looseLine` check mark.
35
+ */
36
+ export declare function findLooseLines(doc: VDTDocument, options?: FindLooseLinesOptions): LooseLine[];
37
+ /**
38
+ * Paint the loose-line highlight of one page onto a 2D context, in page
39
+ * pixels under the context's current transform — call it right after
40
+ * `renderPage` / `renderPageToCanvas` on the same canvas, which leave the
41
+ * context scaled to the page. Returns the lines it painted.
42
+ */
43
+ export declare function drawLooseLines(ctx: CanvasRenderingContext2D | OffscreenCanvasRenderingContext2D, page: VDTPage, doc: VDTDocument, options?: DrawLooseLinesOptions): LooseLine[];
44
+ //# sourceMappingURL=looseLines.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"looseLines.d.ts","sourceRoot":"","sources":["../src/looseLines.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,QAAQ,EAAE,WAAW,EAAE,OAAO,EAAE,OAAO,EAAE,MAAM,OAAO,CAAC;AAGrE;0CAC0C;AAC1C,MAAM,WAAW,SAAS;IACxB,KAAK,EAAE,QAAQ,CAAC;IAChB,IAAI,EAAE,OAAO,CAAC;IACd;wCACoC;IACpC,KAAK,EAAE,MAAM,CAAC;IACd;sBACkB;IAClB,CAAC,EAAE,MAAM,CAAC;IACV,CAAC,EAAE,MAAM,CAAC;IACV,KAAK,EAAE,MAAM,CAAC;IACd,MAAM,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,qBAAqB;IACpC;;2EAEuE;IACvE,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,wDAAwD;IACxD,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAED,MAAM,WAAW,qBAAqB;IACpC,mDAAmD;IACnD,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;oDACgD;IAChD,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED;;;GAGG;AACH,wBAAgB,cAAc,CAAC,GAAG,EAAE,WAAW,EAAE,OAAO,GAAE,qBAA0B,GAAG,SAAS,EAAE,CAoBjG;AAED;;;;;GAKG;AACH,wBAAgB,cAAc,CAC5B,GAAG,EAAE,wBAAwB,GAAG,iCAAiC,EACjE,IAAI,EAAE,OAAO,EACb,GAAG,EAAE,WAAW,EAChB,OAAO,GAAE,qBAA0B,GAClC,SAAS,EAAE,CAQb"}
@@ -0,0 +1,46 @@
1
+ import { DEFAULT_DEBUG_CONFIG } from './defaults/debug';
2
+ /**
3
+ * The loose lines of a laid-out document, in block and line order: the lines
4
+ * the Sandbox's loose-line highlight and its `looseLine` check mark.
5
+ */
6
+ export function findLooseLines(doc, options = {}) {
7
+ const threshold = options.threshold ?? DEFAULT_DEBUG_CONFIG.looseLineHighlight.threshold;
8
+ const out = [];
9
+ for (const block of doc.blocks) {
10
+ if (options.pageIndex !== undefined && block.pageIndex !== options.pageIndex)
11
+ continue;
12
+ for (const line of block.lines) {
13
+ const ratio = line.justifiedSpaceRatio;
14
+ if (ratio === undefined || ratio <= threshold)
15
+ continue;
16
+ out.push({
17
+ block,
18
+ line,
19
+ ratio,
20
+ x: block.bbox.x,
21
+ y: line.bbox.y,
22
+ width: block.bbox.width,
23
+ height: line.bbox.height,
24
+ });
25
+ }
26
+ }
27
+ return out;
28
+ }
29
+ /**
30
+ * Paint the loose-line highlight of one page onto a 2D context, in page
31
+ * pixels under the context's current transform — call it right after
32
+ * `renderPage` / `renderPageToCanvas` on the same canvas, which leave the
33
+ * context scaled to the page. Returns the lines it painted.
34
+ */
35
+ export function drawLooseLines(ctx, page, doc, options = {}) {
36
+ const lines = findLooseLines(doc, { threshold: options.threshold, pageIndex: page.index });
37
+ if (lines.length === 0)
38
+ return lines;
39
+ ctx.save();
40
+ ctx.fillStyle = options.color ?? DEFAULT_DEBUG_CONFIG.looseLineHighlight.color.hex;
41
+ for (const l of lines)
42
+ ctx.fillRect(l.x, l.y, l.width, l.height);
43
+ ctx.restore();
44
+ return lines;
45
+ }
46
+ //# sourceMappingURL=looseLines.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"looseLines.js","sourceRoot":"","sources":["../src/looseLines.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAmCxD;;;GAGG;AACH,MAAM,UAAU,cAAc,CAAC,GAAgB,EAAE,UAAiC,EAAE;IAClF,MAAM,SAAS,GAAG,OAAO,CAAC,SAAS,IAAI,oBAAoB,CAAC,kBAAkB,CAAC,SAAS,CAAC;IACzF,MAAM,GAAG,GAAgB,EAAE,CAAC;IAC5B,KAAK,MAAM,KAAK,IAAI,GAAG,CAAC,MAAM,EAAE,CAAC;QAC/B,IAAI,OAAO,CAAC,SAAS,KAAK,SAAS,IAAI,KAAK,CAAC,SAAS,KAAK,OAAO,CAAC,SAAS;YAAE,SAAS;QACvF,KAAK,MAAM,IAAI,IAAI,KAAK,CAAC,KAAK,EAAE,CAAC;YAC/B,MAAM,KAAK,GAAG,IAAI,CAAC,mBAAmB,CAAC;YACvC,IAAI,KAAK,KAAK,SAAS,IAAI,KAAK,IAAI,SAAS;gBAAE,SAAS;YACxD,GAAG,CAAC,IAAI,CAAC;gBACP,KAAK;gBACL,IAAI;gBACJ,KAAK;gBACL,CAAC,EAAE,KAAK,CAAC,IAAI,CAAC,CAAC;gBACf,CAAC,EAAE,IAAI,CAAC,IAAI,CAAC,CAAC;gBACd,KAAK,EAAE,KAAK,CAAC,IAAI,CAAC,KAAK;gBACvB,MAAM,EAAE,IAAI,CAAC,IAAI,CAAC,MAAM;aACzB,CAAC,CAAC;QACL,CAAC;IACH,CAAC;IACD,OAAO,GAAG,CAAC;AACb,CAAC;AAED;;;;;GAKG;AACH,MAAM,UAAU,cAAc,CAC5B,GAAiE,EACjE,IAAa,EACb,GAAgB,EAChB,UAAiC,EAAE;IAEnC,MAAM,KAAK,GAAG,cAAc,CAAC,GAAG,EAAE,EAAE,SAAS,EAAE,OAAO,CAAC,SAAS,EAAE,SAAS,EAAE,IAAI,CAAC,KAAK,EAAE,CAAC,CAAC;IAC3F,IAAI,KAAK,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,KAAK,CAAC;IACrC,GAAG,CAAC,IAAI,EAAE,CAAC;IACX,GAAG,CAAC,SAAS,GAAG,OAAO,CAAC,KAAK,IAAI,oBAAoB,CAAC,kBAAkB,CAAC,KAAK,CAAC,GAAG,CAAC;IACnF,KAAK,MAAM,CAAC,IAAI,KAAK;QAAE,GAAG,CAAC,QAAQ,CAAC,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,KAAK,EAAE,CAAC,CAAC,MAAM,CAAC,CAAC;IACjE,GAAG,CAAC,OAAO,EAAE,CAAC;IACd,OAAO,KAAK,CAAC;AACf,CAAC"}
@@ -0,0 +1,221 @@
1
+ Third-party code in postext
2
+ ===========================
3
+
4
+ dist/math/mathjax.js bundles the following packages, each licensed under the
5
+ Apache License, Version 2.0, reproduced in full below. The bundle is made by
6
+ scripts/bundle-mathjax.mjs in the postext repository
7
+ (https://github.com/drnachio/postext): the packages' modules are bundled into
8
+ one ES module and minified, and method calls named like React hooks
9
+ (`x.useLocalID(…)`) are written as computed member calls (x[`useLocalID`](…)).
10
+
11
+ MathJax 3.2.2 (npm package mathjax-full)
12
+ Copyright (c) 2017-2022 The MathJax Consortium
13
+ https://github.com/mathjax/MathJax-src
14
+
15
+ mhchemParser 4.2.1 (npm package mhchemparser)
16
+ Copyright (c) 2015-2023 Martin Hensel
17
+ https://github.com/mhchem/mhchemParser
18
+
19
+ -------------------------------------------------------------------------------
20
+
21
+ Apache License
22
+ Version 2.0, January 2004
23
+ http://www.apache.org/licenses/
24
+
25
+ TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
26
+
27
+ 1. Definitions.
28
+
29
+ "License" shall mean the terms and conditions for use, reproduction,
30
+ and distribution as defined by Sections 1 through 9 of this document.
31
+
32
+ "Licensor" shall mean the copyright owner or entity authorized by
33
+ the copyright owner that is granting the License.
34
+
35
+ "Legal Entity" shall mean the union of the acting entity and all
36
+ other entities that control, are controlled by, or are under common
37
+ control with that entity. For the purposes of this definition,
38
+ "control" means (i) the power, direct or indirect, to cause the
39
+ direction or management of such entity, whether by contract or
40
+ otherwise, or (ii) ownership of fifty percent (50%) or more of the
41
+ outstanding shares, or (iii) beneficial ownership of such entity.
42
+
43
+ "You" (or "Your") shall mean an individual or Legal Entity
44
+ exercising permissions granted by this License.
45
+
46
+ "Source" form shall mean the preferred form for making modifications,
47
+ including but not limited to software source code, documentation
48
+ source, and configuration files.
49
+
50
+ "Object" form shall mean any form resulting from mechanical
51
+ transformation or translation of a Source form, including but
52
+ not limited to compiled object code, generated documentation,
53
+ and conversions to other media types.
54
+
55
+ "Work" shall mean the work of authorship, whether in Source or
56
+ Object form, made available under the License, as indicated by a
57
+ copyright notice that is included in or attached to the work
58
+ (an example is provided in the Appendix below).
59
+
60
+ "Derivative Works" shall mean any work, whether in Source or Object
61
+ form, that is based on (or derived from) the Work and for which the
62
+ editorial revisions, annotations, elaborations, or other modifications
63
+ represent, as a whole, an original work of authorship. For the purposes
64
+ of this License, Derivative Works shall not include works that remain
65
+ separable from, or merely link (or bind by name) to the interfaces of,
66
+ the Work and Derivative Works thereof.
67
+
68
+ "Contribution" shall mean any work of authorship, including
69
+ the original version of the Work and any modifications or additions
70
+ to that Work or Derivative Works thereof, that is intentionally
71
+ submitted to Licensor for inclusion in the Work by the copyright owner
72
+ or by an individual or Legal Entity authorized to submit on behalf of
73
+ the copyright owner. For the purposes of this definition, "submitted"
74
+ means any form of electronic, verbal, or written communication sent
75
+ to the Licensor or its representatives, including but not limited to
76
+ communication on electronic mailing lists, source code control systems,
77
+ and issue tracking systems that are managed by, or on behalf of, the
78
+ Licensor for the purpose of discussing and improving the Work, but
79
+ excluding communication that is conspicuously marked or otherwise
80
+ designated in writing by the copyright owner as "Not a Contribution."
81
+
82
+ "Contributor" shall mean Licensor and any individual or Legal Entity
83
+ on behalf of whom a Contribution has been received by Licensor and
84
+ subsequently incorporated within the Work.
85
+
86
+ 2. Grant of Copyright License. Subject to the terms and conditions of
87
+ this License, each Contributor hereby grants to You a perpetual,
88
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
89
+ copyright license to reproduce, prepare Derivative Works of,
90
+ publicly display, publicly perform, sublicense, and distribute the
91
+ Work and such Derivative Works in Source or Object form.
92
+
93
+ 3. Grant of Patent License. Subject to the terms and conditions of
94
+ this License, each Contributor hereby grants to You a perpetual,
95
+ worldwide, non-exclusive, no-charge, royalty-free, irrevocable
96
+ (except as stated in this section) patent license to make, have made,
97
+ use, offer to sell, sell, import, and otherwise transfer the Work,
98
+ where such license applies only to those patent claims licensable
99
+ by such Contributor that are necessarily infringed by their
100
+ Contribution(s) alone or by combination of their Contribution(s)
101
+ with the Work to which such Contribution(s) was submitted. If You
102
+ institute patent litigation against any entity (including a
103
+ cross-claim or counterclaim in a lawsuit) alleging that the Work
104
+ or a Contribution incorporated within the Work constitutes direct
105
+ or contributory patent infringement, then any patent licenses
106
+ granted to You under this License for that Work shall terminate
107
+ as of the date such litigation is filed.
108
+
109
+ 4. Redistribution. You may reproduce and distribute copies of the
110
+ Work or Derivative Works thereof in any medium, with or without
111
+ modifications, and in Source or Object form, provided that You
112
+ meet the following conditions:
113
+
114
+ (a) You must give any other recipients of the Work or
115
+ Derivative Works a copy of this License; and
116
+
117
+ (b) You must cause any modified files to carry prominent notices
118
+ stating that You changed the files; and
119
+
120
+ (c) You must retain, in the Source form of any Derivative Works
121
+ that You distribute, all copyright, patent, trademark, and
122
+ attribution notices from the Source form of the Work,
123
+ excluding those notices that do not pertain to any part of
124
+ the Derivative Works; and
125
+
126
+ (d) If the Work includes a "NOTICE" text file as part of its
127
+ distribution, then any Derivative Works that You distribute must
128
+ include a readable copy of the attribution notices contained
129
+ within such NOTICE file, excluding those notices that do not
130
+ pertain to any part of the Derivative Works, in at least one
131
+ of the following places: within a NOTICE text file distributed
132
+ as part of the Derivative Works; within the Source form or
133
+ documentation, if provided along with the Derivative Works; or,
134
+ within a display generated by the Derivative Works, if and
135
+ wherever such third-party notices normally appear. The contents
136
+ of the NOTICE file are for informational purposes only and
137
+ do not modify the License. You may add Your own attribution
138
+ notices within Derivative Works that You distribute, alongside
139
+ or as an addendum to the NOTICE text from the Work, provided
140
+ that such additional attribution notices cannot be construed
141
+ as modifying the License.
142
+
143
+ You may add Your own copyright statement to Your modifications and
144
+ may provide additional or different license terms and conditions
145
+ for use, reproduction, or distribution of Your modifications, or
146
+ for any such Derivative Works as a whole, provided Your use,
147
+ reproduction, and distribution of the Work otherwise complies with
148
+ the conditions stated in this License.
149
+
150
+ 5. Submission of Contributions. Unless You explicitly state otherwise,
151
+ any Contribution intentionally submitted for inclusion in the Work
152
+ by You to the Licensor shall be under the terms and conditions of
153
+ this License, without any additional terms or conditions.
154
+ Notwithstanding the above, nothing herein shall supersede or modify
155
+ the terms of any separate license agreement you may have executed
156
+ with Licensor regarding such Contributions.
157
+
158
+ 6. Trademarks. This License does not grant permission to use the trade
159
+ names, trademarks, service marks, or product names of the Licensor,
160
+ except as required for reasonable and customary use in describing the
161
+ origin of the Work and reproducing the content of the NOTICE file.
162
+
163
+ 7. Disclaimer of Warranty. Unless required by applicable law or
164
+ agreed to in writing, Licensor provides the Work (and each
165
+ Contributor provides its Contributions) on an "AS IS" BASIS,
166
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
167
+ implied, including, without limitation, any warranties or conditions
168
+ of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
169
+ PARTICULAR PURPOSE. You are solely responsible for determining the
170
+ appropriateness of using or redistributing the Work and assume any
171
+ risks associated with Your exercise of permissions under this License.
172
+
173
+ 8. Limitation of Liability. In no event and under no legal theory,
174
+ whether in tort (including negligence), contract, or otherwise,
175
+ unless required by applicable law (such as deliberate and grossly
176
+ negligent acts) or agreed to in writing, shall any Contributor be
177
+ liable to You for damages, including any direct, indirect, special,
178
+ incidental, or consequential damages of any character arising as a
179
+ result of this License or out of the use or inability to use the
180
+ Work (including but not limited to damages for loss of goodwill,
181
+ work stoppage, computer failure or malfunction, or any and all
182
+ other commercial damages or losses), even if such Contributor
183
+ has been advised of the possibility of such damages.
184
+
185
+ 9. Accepting Warranty or Additional Liability. While redistributing
186
+ the Work or Derivative Works thereof, You may choose to offer,
187
+ and charge a fee for, acceptance of support, warranty, indemnity,
188
+ or other liability obligations and/or rights consistent with this
189
+ License. However, in accepting such obligations, You may act only
190
+ on Your own behalf and on Your sole responsibility, not on behalf
191
+ of any other Contributor, and only if You agree to indemnify,
192
+ defend, and hold each Contributor harmless for any liability
193
+ incurred by, or claims asserted against, such Contributor by reason
194
+ of your accepting any such warranty or additional liability.
195
+
196
+ END OF TERMS AND CONDITIONS
197
+
198
+ APPENDIX: How to apply the Apache License to your work.
199
+
200
+ To apply the Apache License to your work, attach the following
201
+ boilerplate notice, with the fields enclosed by brackets "[]"
202
+ replaced with your own identifying information. (Don't include
203
+ the brackets!) The text should be enclosed in the appropriate
204
+ comment syntax for the file format. We also recommend that a
205
+ file or class name and description of purpose be included on the
206
+ same "printed page" as the copyright notice for easier
207
+ identification within third-party archives.
208
+
209
+ Copyright [yyyy] [name of copyright owner]
210
+
211
+ Licensed under the Apache License, Version 2.0 (the "License");
212
+ you may not use this file except in compliance with the License.
213
+ You may obtain a copy of the License at
214
+
215
+ http://www.apache.org/licenses/LICENSE-2.0
216
+
217
+ Unless required by applicable law or agreed to in writing, software
218
+ distributed under the License is distributed on an "AS IS" BASIS,
219
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
220
+ See the License for the specific language governing permissions and
221
+ limitations under the License.
@@ -1,7 +1,20 @@
1
1
  import type { MathRender } from './types';
2
2
  export declare function isMathReady(): boolean;
3
3
  export declare function onMathReady(fn: () => void): () => void;
4
+ /**
5
+ * Load MathJax and start the TeX → SVG converter. Await it before laying
6
+ * out a document with `$…$` / `$$…$$` on the main thread (the layout worker
7
+ * calls it itself): until it resolves, every formula is set as a grey
8
+ * placeholder box. Idempotent; a failed start can be retried.
9
+ */
4
10
  export declare function initMathEngine(): Promise<void>;
11
+ /**
12
+ * Called when the layout sets a formula with no engine running, so it gets a
13
+ * grey placeholder box. Warns once, and only when nobody asked for the
14
+ * engine: a host that lays out now and again from `onMathReady` has
15
+ * `initMathEngine` in flight and expects the placeholders.
16
+ */
17
+ export declare function noteMathWithoutEngine(): void;
5
18
  export interface RenderOptions {
6
19
  /** Body line-box in px. Inline math is scaled down to fit. Display math
7
20
  * is not clamped. */
@@ -9,7 +22,18 @@ export interface RenderOptions {
9
22
  /** Override the default colour (MathJax emits "currentColor" which is a
10
23
  * CSS construct; we substitute here so the SVG is self-contained). */
11
24
  color?: string;
25
+ /** Display math: the width of the measure the formula is set in, in px.
26
+ * A numbered equation (`\tag{…}`) takes this width, the equation
27
+ * centred and its number flush right; without it, it takes the least
28
+ * width that holds both. Other formulas keep their own width. */
29
+ containerWidthPx?: number;
12
30
  }
31
+ /**
32
+ * Typeset TeX as SVG at `fontSizePx`: one em of the formula is
33
+ * `fontSizePx` (MathJax sizes in `ex`, the TeX font's x-height, 0.442 em).
34
+ * Cached; before {@link initMathEngine} resolves it returns a placeholder
35
+ * box instead (not cached).
36
+ */
13
37
  export declare function renderMath(tex: string, displayMode: boolean, fontSizePx: number, options?: RenderOptions): MathRender;
14
38
  export declare function placeholderRender(tex: string, displayMode: boolean, fontSizePx: number): MathRender;
15
39
  export declare function clearMathCache(): void;
@@ -1 +1 @@
1
- {"version":3,"file":"engine.d.ts","sourceRoot":"","sources":["../../src/math/engine.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAyB,MAAM,SAAS,CAAC;AA+BjE,wBAAgB,WAAW,IAAI,OAAO,CAErC;AAED,wBAAgB,WAAW,CAAC,EAAE,EAAE,MAAM,IAAI,GAAG,MAAM,IAAI,CAOtD;AAED,wBAAsB,cAAc,IAAI,OAAO,CAAC,IAAI,CAAC,CAwBpD;AA6JD,MAAM,WAAW,aAAa;IAC5B;0BACsB;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;2EACuE;IACvE,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAuBD,wBAAgB,UAAU,CACxB,GAAG,EAAE,MAAM,EACX,WAAW,EAAE,OAAO,EACpB,UAAU,EAAE,MAAM,EAClB,OAAO,GAAE,aAAkB,GAC1B,UAAU,CAiGZ;AAmBD,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,MAAM,EAAE,WAAW,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,GAAG,UAAU,CAenG;AAED,wBAAgB,cAAc,IAAI,IAAI,CAErC"}
1
+ {"version":3,"file":"engine.d.ts","sourceRoot":"","sources":["../../src/math/engine.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,UAAU,EAAyB,MAAM,SAAS,CAAC;AAmBjE,wBAAgB,WAAW,IAAI,OAAO,CAErC;AAED,wBAAgB,WAAW,CAAC,EAAE,EAAE,MAAM,IAAI,GAAG,MAAM,IAAI,CAOtD;AAED;;;;;GAKG;AACH,wBAAsB,cAAc,IAAI,OAAO,CAAC,IAAI,CAAC,CAmBpD;AAED;;;;;GAKG;AACH,wBAAgB,qBAAqB,IAAI,IAAI,CAO5C;AA0RD,MAAM,WAAW,aAAa;IAC5B;0BACsB;IACtB,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;2EACuE;IACvE,KAAK,CAAC,EAAE,MAAM,CAAC;IACf;;;sEAGkE;IAClE,gBAAgB,CAAC,EAAE,MAAM,CAAC;CAC3B;AAsGD;;;;;GAKG;AACH,wBAAgB,UAAU,CACxB,GAAG,EAAE,MAAM,EACX,WAAW,EAAE,OAAO,EACpB,UAAU,EAAE,MAAM,EAClB,OAAO,GAAE,aAAkB,GAC1B,UAAU,CAgEZ;AA4BD,wBAAgB,iBAAiB,CAAC,GAAG,EAAE,MAAM,EAAE,WAAW,EAAE,OAAO,EAAE,UAAU,EAAE,MAAM,GAAG,UAAU,CAenG;AAED,wBAAgB,cAAc,IAAI,IAAI,CAErC"}