@evotecit/officeimo 0.0.0-stage → 0.1.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 (261) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +1222 -2
  3. package/bundles/officeimo-canopyx.js +11741 -0
  4. package/bundles/officeimo-canopyx.mjs +11639 -0
  5. package/bundles/officeimo-csv.js +1264 -0
  6. package/bundles/officeimo-csv.mjs +1239 -0
  7. package/bundles/officeimo-datatables.js +12018 -0
  8. package/bundles/officeimo-datatables.mjs +11915 -0
  9. package/bundles/officeimo-execution.js +1513 -0
  10. package/bundles/officeimo-execution.mjs +1489 -0
  11. package/bundles/officeimo-pdf.js +7009 -0
  12. package/bundles/officeimo-pdf.mjs +6946 -0
  13. package/bundles/officeimo-xlsx.js +5344 -0
  14. package/bundles/officeimo-xlsx.mjs +5290 -0
  15. package/bundles/officeimo.js +11468 -0
  16. package/bundles/officeimo.mjs +11369 -0
  17. package/dist/core/dates.d.ts +1 -0
  18. package/dist/core/dates.js +16 -0
  19. package/dist/core/errors.d.ts +12 -0
  20. package/dist/core/errors.js +31 -0
  21. package/dist/core/grouped-report.d.ts +87 -0
  22. package/dist/core/grouped-report.js +252 -0
  23. package/dist/core/index.d.ts +74 -0
  24. package/dist/core/index.js +37 -0
  25. package/dist/core/iteration.d.ts +7 -0
  26. package/dist/core/iteration.js +149 -0
  27. package/dist/core/limits.d.ts +7 -0
  28. package/dist/core/limits.js +56 -0
  29. package/dist/core/links.d.ts +5 -0
  30. package/dist/core/links.js +14 -0
  31. package/dist/core/presentation.d.ts +29 -0
  32. package/dist/core/presentation.js +59 -0
  33. package/dist/core/progress.d.ts +1 -0
  34. package/dist/core/progress.js +10 -0
  35. package/dist/core/sinks.d.ts +33 -0
  36. package/dist/core/sinks.js +102 -0
  37. package/dist/core/table.d.ts +8 -0
  38. package/dist/core/table.js +1 -0
  39. package/dist/core/value-text.d.ts +7 -0
  40. package/dist/core/value-text.js +13 -0
  41. package/dist/csv/index.d.ts +44 -0
  42. package/dist/csv/index.js +133 -0
  43. package/dist/csv/options.d.ts +1 -0
  44. package/dist/csv/options.js +8 -0
  45. package/dist/csv/structured-rows.d.ts +3 -0
  46. package/dist/csv/structured-rows.js +15 -0
  47. package/dist/execution/host.d.ts +5 -0
  48. package/dist/execution/host.js +164 -0
  49. package/dist/execution/index.d.ts +3 -0
  50. package/dist/execution/index.js +2 -0
  51. package/dist/execution/protocol.d.ts +48 -0
  52. package/dist/execution/protocol.js +173 -0
  53. package/dist/execution/types.d.ts +42 -0
  54. package/dist/execution/types.js +1 -0
  55. package/dist/execution/worker.d.ts +3 -0
  56. package/dist/execution/worker.js +147 -0
  57. package/dist/index.d.ts +32 -0
  58. package/dist/index.js +14 -0
  59. package/dist/integrations/canopyx/dates.d.ts +1 -0
  60. package/dist/integrations/canopyx/dates.js +34 -0
  61. package/dist/integrations/canopyx/index.d.ts +10 -0
  62. package/dist/integrations/canopyx/index.js +45 -0
  63. package/dist/integrations/canopyx/source.d.ts +3 -0
  64. package/dist/integrations/canopyx/source.js +122 -0
  65. package/dist/integrations/canopyx/types.d.ts +83 -0
  66. package/dist/integrations/canopyx/types.js +1 -0
  67. package/dist/integrations/datatables/api.d.ts +1 -0
  68. package/dist/integrations/datatables/api.js +27 -0
  69. package/dist/integrations/datatables/headings.d.ts +1 -0
  70. package/dist/integrations/datatables/headings.js +65 -0
  71. package/dist/integrations/datatables/index.d.ts +12 -0
  72. package/dist/integrations/datatables/index.js +167 -0
  73. package/dist/integrations/datatables/snapshot.d.ts +3 -0
  74. package/dist/integrations/datatables/snapshot.js +206 -0
  75. package/dist/integrations/datatables/types.d.ts +98 -0
  76. package/dist/integrations/datatables/types.js +1 -0
  77. package/dist/integrations/options.d.ts +13 -0
  78. package/dist/integrations/options.js +34 -0
  79. package/dist/internal/capture.d.ts +4 -0
  80. package/dist/internal/capture.js +14 -0
  81. package/dist/internal/columns.d.ts +27 -0
  82. package/dist/internal/columns.js +1 -0
  83. package/dist/internal/crc32.d.ts +6 -0
  84. package/dist/internal/crc32.js +17 -0
  85. package/dist/internal/export-values.d.ts +3 -0
  86. package/dist/internal/export-values.js +14 -0
  87. package/dist/internal/rows.d.ts +6 -0
  88. package/dist/internal/rows.js +77 -0
  89. package/dist/internal/table-spans.d.ts +11 -0
  90. package/dist/internal/table-spans.js +58 -0
  91. package/dist/internal/totals.d.ts +15 -0
  92. package/dist/internal/totals.js +42 -0
  93. package/dist/opc/index.d.ts +67 -0
  94. package/dist/opc/index.js +233 -0
  95. package/dist/opc/properties.d.ts +15 -0
  96. package/dist/opc/properties.js +18 -0
  97. package/dist/opc/uri.d.ts +5 -0
  98. package/dist/opc/uri.js +41 -0
  99. package/dist/pdf/annotations.d.ts +1 -0
  100. package/dist/pdf/annotations.js +38 -0
  101. package/dist/pdf/binary.d.ts +6 -0
  102. package/dist/pdf/binary.js +24 -0
  103. package/dist/pdf/document-drawings.d.ts +15 -0
  104. package/dist/pdf/document-drawings.js +237 -0
  105. package/dist/pdf/document-grouped.d.ts +1 -0
  106. package/dist/pdf/document-grouped.js +244 -0
  107. package/dist/pdf/document-images.d.ts +19 -0
  108. package/dist/pdf/document-images.js +125 -0
  109. package/dist/pdf/document-types.d.ts +160 -0
  110. package/dist/pdf/document-types.js +1 -0
  111. package/dist/pdf/document-vectors.d.ts +11 -0
  112. package/dist/pdf/document-vectors.js +77 -0
  113. package/dist/pdf/document.d.ts +9 -0
  114. package/dist/pdf/document.js +270 -0
  115. package/dist/pdf/drawing-types.d.ts +53 -0
  116. package/dist/pdf/drawing-types.js +1 -0
  117. package/dist/pdf/font-resources.d.ts +43 -0
  118. package/dist/pdf/font-resources.js +202 -0
  119. package/dist/pdf/font-support.d.ts +1 -0
  120. package/dist/pdf/font-support.js +60 -0
  121. package/dist/pdf/font.d.ts +17 -0
  122. package/dist/pdf/font.js +56 -0
  123. package/dist/pdf/grouped-table.d.ts +6 -0
  124. package/dist/pdf/grouped-table.js +40 -0
  125. package/dist/pdf/grouped-types.d.ts +34 -0
  126. package/dist/pdf/grouped-types.js +1 -0
  127. package/dist/pdf/grouped.d.ts +10 -0
  128. package/dist/pdf/grouped.js +37 -0
  129. package/dist/pdf/index.d.ts +22 -0
  130. package/dist/pdf/index.js +8 -0
  131. package/dist/pdf/inline-text.d.ts +30 -0
  132. package/dist/pdf/inline-text.js +183 -0
  133. package/dist/pdf/inline-types.d.ts +15 -0
  134. package/dist/pdf/inline-types.js +1 -0
  135. package/dist/pdf/list-layout.d.ts +6 -0
  136. package/dist/pdf/list-layout.js +49 -0
  137. package/dist/pdf/objects.d.ts +2 -0
  138. package/dist/pdf/objects.js +320 -0
  139. package/dist/pdf/outlines.d.ts +1 -0
  140. package/dist/pdf/outlines.js +55 -0
  141. package/dist/pdf/page-context.d.ts +1 -0
  142. package/dist/pdf/page-context.js +12 -0
  143. package/dist/pdf/pages.d.ts +1 -0
  144. package/dist/pdf/pages.js +678 -0
  145. package/dist/pdf/paragraph-layout.d.ts +21 -0
  146. package/dist/pdf/paragraph-layout.js +71 -0
  147. package/dist/pdf/paragraph-styles.d.ts +1 -0
  148. package/dist/pdf/paragraph-styles.js +66 -0
  149. package/dist/pdf/png.d.ts +9 -0
  150. package/dist/pdf/png.js +259 -0
  151. package/dist/pdf/preflight.d.ts +7 -0
  152. package/dist/pdf/preflight.js +32 -0
  153. package/dist/pdf/presentation-settings.d.ts +5 -0
  154. package/dist/pdf/presentation-settings.js +28 -0
  155. package/dist/pdf/providers/harfbuzz.d.ts +60 -0
  156. package/dist/pdf/providers/harfbuzz.js +112 -0
  157. package/dist/pdf/providers/unicode13-profile.d.ts +2 -0
  158. package/dist/pdf/providers/unicode13-profile.js +115 -0
  159. package/dist/pdf/section-types.d.ts +15 -0
  160. package/dist/pdf/section-types.js +40 -0
  161. package/dist/pdf/session.d.ts +25 -0
  162. package/dist/pdf/session.js +55 -0
  163. package/dist/pdf/settings.d.ts +17 -0
  164. package/dist/pdf/settings.js +196 -0
  165. package/dist/pdf/shaped-text.d.ts +5 -0
  166. package/dist/pdf/shaped-text.js +205 -0
  167. package/dist/pdf/standard-widths.d.ts +1 -0
  168. package/dist/pdf/standard-widths.js +317 -0
  169. package/dist/pdf/structure-parent-tree.d.ts +1 -0
  170. package/dist/pdf/structure-parent-tree.js +57 -0
  171. package/dist/pdf/structure.d.ts +6 -0
  172. package/dist/pdf/structure.js +302 -0
  173. package/dist/pdf/table-band-flow.d.ts +34 -0
  174. package/dist/pdf/table-band-flow.js +129 -0
  175. package/dist/pdf/table-band-plan.d.ts +10 -0
  176. package/dist/pdf/table-band-plan.js +83 -0
  177. package/dist/pdf/table-layout.d.ts +75 -0
  178. package/dist/pdf/table-layout.js +217 -0
  179. package/dist/pdf/table-structure.d.ts +1 -0
  180. package/dist/pdf/table-structure.js +108 -0
  181. package/dist/pdf/text-shaping-types.d.ts +39 -0
  182. package/dist/pdf/text-shaping-types.js +1 -0
  183. package/dist/pdf/text.d.ts +13 -0
  184. package/dist/pdf/text.js +101 -0
  185. package/dist/pdf/truetype-subset.d.ts +5 -0
  186. package/dist/pdf/truetype-subset.js +217 -0
  187. package/dist/pdf/truetype.d.ts +1 -0
  188. package/dist/pdf/truetype.js +235 -0
  189. package/dist/pdf/types.d.ts +171 -0
  190. package/dist/pdf/types.js +1 -0
  191. package/dist/pdf/write.d.ts +6 -0
  192. package/dist/pdf/write.js +57 -0
  193. package/dist/pdf/xref.d.ts +1 -0
  194. package/dist/pdf/xref.js +30 -0
  195. package/dist/xlsx/attachments.d.ts +30 -0
  196. package/dist/xlsx/attachments.js +67 -0
  197. package/dist/xlsx/chart-bindings.d.ts +1 -0
  198. package/dist/xlsx/chart-bindings.js +122 -0
  199. package/dist/xlsx/chart-types.d.ts +73 -0
  200. package/dist/xlsx/chart-types.js +1 -0
  201. package/dist/xlsx/chart-xml.d.ts +2 -0
  202. package/dist/xlsx/chart-xml.js +103 -0
  203. package/dist/xlsx/charts.d.ts +1 -0
  204. package/dist/xlsx/charts.js +159 -0
  205. package/dist/xlsx/conditional-formatting.d.ts +1 -0
  206. package/dist/xlsx/conditional-formatting.js +158 -0
  207. package/dist/xlsx/conditional-types.d.ts +64 -0
  208. package/dist/xlsx/conditional-types.js +1 -0
  209. package/dist/xlsx/data-row-ranges.d.ts +5 -0
  210. package/dist/xlsx/data-row-ranges.js +39 -0
  211. package/dist/xlsx/differential-styles.d.ts +1 -0
  212. package/dist/xlsx/differential-styles.js +102 -0
  213. package/dist/xlsx/formula.d.ts +8 -0
  214. package/dist/xlsx/formula.js +104 -0
  215. package/dist/xlsx/grouped-layout.d.ts +61 -0
  216. package/dist/xlsx/grouped-layout.js +79 -0
  217. package/dist/xlsx/grouped.d.ts +16 -0
  218. package/dist/xlsx/grouped.js +161 -0
  219. package/dist/xlsx/index.d.ts +24 -0
  220. package/dist/xlsx/index.js +10 -0
  221. package/dist/xlsx/layout.d.ts +1 -0
  222. package/dist/xlsx/layout.js +186 -0
  223. package/dist/xlsx/options.d.ts +1 -0
  224. package/dist/xlsx/options.js +16 -0
  225. package/dist/xlsx/portable.d.ts +27 -0
  226. package/dist/xlsx/portable.js +44 -0
  227. package/dist/xlsx/preservation.d.ts +1 -0
  228. package/dist/xlsx/preservation.js +60 -0
  229. package/dist/xlsx/ranges.d.ts +1 -0
  230. package/dist/xlsx/ranges.js +24 -0
  231. package/dist/xlsx/regions.d.ts +1 -0
  232. package/dist/xlsx/regions.js +97 -0
  233. package/dist/xlsx/structured-rows.d.ts +11 -0
  234. package/dist/xlsx/structured-rows.js +28 -0
  235. package/dist/xlsx/style-xml.d.ts +1 -0
  236. package/dist/xlsx/style-xml.js +6 -0
  237. package/dist/xlsx/styles.d.ts +70 -0
  238. package/dist/xlsx/styles.js +203 -0
  239. package/dist/xlsx/table.d.ts +12 -0
  240. package/dist/xlsx/table.js +35 -0
  241. package/dist/xlsx/types.d.ts +180 -0
  242. package/dist/xlsx/types.js +1 -0
  243. package/dist/xlsx/validation-types.d.ts +18 -0
  244. package/dist/xlsx/validation-types.js +1 -0
  245. package/dist/xlsx/validation.d.ts +1 -0
  246. package/dist/xlsx/validation.js +92 -0
  247. package/dist/xlsx/values.d.ts +13 -0
  248. package/dist/xlsx/values.js +87 -0
  249. package/dist/xlsx/workbook.d.ts +50 -0
  250. package/dist/xlsx/workbook.js +452 -0
  251. package/dist/xlsx/worksheet.d.ts +71 -0
  252. package/dist/xlsx/worksheet.js +700 -0
  253. package/dist/xlsx/write.d.ts +15 -0
  254. package/dist/xlsx/write.js +47 -0
  255. package/dist/xml/index.d.ts +24 -0
  256. package/dist/xml/index.js +74 -0
  257. package/dist/zip/entry.d.ts +39 -0
  258. package/dist/zip/entry.js +122 -0
  259. package/dist/zip/index.d.ts +44 -0
  260. package/dist/zip/index.js +248 -0
  261. package/package.json +104 -4
@@ -0,0 +1,56 @@
1
+ import { TrueTypeFont } from "./truetype.js";
2
+ import { beginTask, checkAbort } from "../core/iteration.js";
3
+ const programs = new WeakMap();
4
+ const fontBrand = Symbol.for("@evotecit/officeimo/PdfFont");
5
+ /** @internal Font bytes stay private even in plain JavaScript consumers. */
6
+ export function fontProgram(font) {
7
+ let program = programs.get(font);
8
+ if (!program) {
9
+ if (!(font instanceof PdfFont) || typeof font.toBytes !== "function")
10
+ throw new TypeError("Invalid PdfFont instance.");
11
+ // Standalone ESM assemblies have separate class/WeakMap identities. Import a
12
+ // defensive copy once while preserving the same public reusable-font contract.
13
+ const copied = new PdfFont(font.toBytes());
14
+ program = programs.get(copied);
15
+ programs.set(font, program);
16
+ }
17
+ return program;
18
+ }
19
+ /** Immutable, reusable static TrueType font. Bytes are copied; no fetch, DOM or installed-font lookup occurs. */
20
+ export class PdfFont {
21
+ static [Symbol.hasInstance](value) { return !!value && typeof value === "object" && value[fontBrand] === true; }
22
+ brand = true;
23
+ constructor(bytes) {
24
+ if (!(bytes instanceof Uint8Array))
25
+ throw new TypeError("PdfFont requires TrueType bytes as a Uint8Array.");
26
+ if (bytes.length > 64 * 1024 * 1024)
27
+ throw new RangeError("A TrueType font must not exceed 64 MiB.");
28
+ programs.set(this, new TrueTypeFont(bytes.slice()));
29
+ void this.brand;
30
+ Object.defineProperty(this, fontBrand, { value: true });
31
+ Object.freeze(this);
32
+ }
33
+ /** Prepare the same immutable font with cooperative parsing and cancellation.
34
+ * The bounded source snapshot is synchronous so later host mutation cannot change the prepared font. */
35
+ static async create(bytes, options = {}) {
36
+ checkAbort(options.signal);
37
+ if (!(bytes instanceof Uint8Array))
38
+ throw new TypeError("PdfFont requires TrueType bytes as a Uint8Array.");
39
+ const maximum = options.maxBytes ?? 16 * 1024 * 1024;
40
+ if (!Number.isSafeInteger(maximum) || maximum < 0 || maximum > 64 * 1024 * 1024)
41
+ throw new RangeError("Font preparation maxBytes must be a nonnegative safe integer at most 64 MiB.");
42
+ if (bytes.length > maximum)
43
+ throw new RangeError("TrueType font exceeds the preparation byte limit.");
44
+ beginTask();
45
+ const program = await TrueTypeFont.create(new Uint8Array(bytes), options.signal);
46
+ checkAbort(options.signal);
47
+ const font = Object.create(PdfFont.prototype);
48
+ programs.set(font, program);
49
+ Object.defineProperty(font, "brand", { value: true });
50
+ Object.defineProperty(font, fontBrand, { value: true });
51
+ Object.freeze(font);
52
+ return font;
53
+ }
54
+ /** Return an independent copy, for storage or delivery to another worker. */
55
+ toBytes() { return fontProgram(this).bytes.slice(); }
56
+ }
@@ -0,0 +1,6 @@
1
+ import type { GroupedReportSource } from "../core/grouped-report.js";
2
+ import type { PdfGroupedTableBlock } from "./document-types.js";
3
+ import type { GroupedPdfTableOptions } from "./grouped-types.js";
4
+ /** Capture an analytical table without opening its row iterator or attaching cancellation listeners.
5
+ * Ownership begins when the document reaches the block; unused blocks leave their sources unconsumed. */
6
+ export declare function pdfGroupedTable(report: GroupedReportSource, options: GroupedPdfTableOptions): PdfGroupedTableBlock;
@@ -0,0 +1,40 @@
1
+ import { assertGroupedReportSource } from "../core/grouped-report.js";
2
+ import { captureFields } from "../internal/capture.js";
3
+ import { captureWideTable } from "./settings.js";
4
+ import { presentation } from "./presentation-settings.js";
5
+ /** @internal Capture schemas shared by the block factory and standalone convenience writers. */
6
+ export const groupedPdfLabelFields = ["labelColumn", "subtotalLabel", "grandTotalLabel", "includeGrandTotal", "continuationLabel", "groupHeadingLevel"];
7
+ /** @internal A grouped table may override presentation but not its document's resource/lifetime policy. */
8
+ export const groupedPdfTableFields = ["includeHeader", "headerPresentation", "footerPresentation", "alternateRowColor", "columnWidths", "wideTable", "formatValue", "formatRuns", ...groupedPdfLabelFields];
9
+ /** Capture an analytical table without opening its row iterator or attaching cancellation listeners.
10
+ * Ownership begins when the document reaches the block; unused blocks leave their sources unconsumed. */
11
+ export function pdfGroupedTable(report, options) {
12
+ assertGroupedReportSource(report);
13
+ return Object.freeze({ kind: "groupedTable", report, options: captureGroupedPdfTableOptions(options) });
14
+ }
15
+ /** @internal Capture the same public table contract for factory-created and structural document blocks. */
16
+ export function captureGroupedPdfTableOptions(configuration) {
17
+ if (!configuration || typeof configuration !== "object" || Array.isArray(configuration) ||
18
+ Object.keys(configuration).some(key => !groupedPdfTableFields.includes(key)))
19
+ throw new TypeError("Grouped PDF table options support table presentation and labels; document settings belong on writePdfDocument.");
20
+ const captured = captureFields(configuration, groupedPdfTableFields);
21
+ const { labelColumn, subtotalLabel, grandTotalLabel, includeGrandTotal, continuationLabel, groupHeadingLevel } = captured;
22
+ if (!labelColumn || typeof labelColumn !== "object")
23
+ throw new TypeError("Grouped PDF needs a leading labelColumn.");
24
+ const { header, width } = labelColumn;
25
+ if (typeof header !== "string")
26
+ throw new TypeError("The grouped label column header must be text.");
27
+ for (const [name, value] of [["subtotalLabel", subtotalLabel], ["grandTotalLabel", grandTotalLabel]])
28
+ if (typeof value !== "function")
29
+ throw new TypeError(name + " must be a synchronous text callback.");
30
+ if (continuationLabel !== undefined && typeof continuationLabel !== "function")
31
+ throw new TypeError("continuationLabel must be a synchronous text callback.");
32
+ if (includeGrandTotal !== undefined && typeof includeGrandTotal !== "boolean")
33
+ throw new TypeError("includeGrandTotal must be boolean.");
34
+ if (groupHeadingLevel !== undefined && (!Number.isInteger(groupHeadingLevel) || groupHeadingLevel < 1 || groupHeadingLevel > 6))
35
+ throw new TypeError("groupHeadingLevel must be an integer from 1 through 6.");
36
+ return Object.freeze({ ...captured, ...(captured.wideTable === undefined ? {} : { wideTable: captureWideTable(captured.wideTable) }), labelColumn: Object.freeze({ header, ...(width === undefined ? {} : { width }) }),
37
+ ...(captured.columnWidths === undefined ? {} : { columnWidths: Object.freeze([...captured.columnWidths]) }),
38
+ ...(captured.headerPresentation === undefined ? {} : { headerPresentation: presentation(captured.headerPresentation) }),
39
+ ...(captured.footerPresentation === undefined ? {} : { footerPresentation: presentation(captured.footerPresentation) }) });
40
+ }
@@ -0,0 +1,34 @@
1
+ import type { GroupedReportEvent, GroupedReportSummary } from "../core/grouped-report.js";
2
+ import type { ExportValue } from "../core/index.js";
3
+ import type { PdfOptions } from "./types.js";
4
+ import type { PdfTableOptions } from "./document-types.js";
5
+ /** Host-authored labels shared by standalone and composed analytical PDF tables. */
6
+ interface GroupedPdfLabels {
7
+ /** An additional leading text column leaves every original data column and numeric total intact. */
8
+ readonly labelColumn: {
9
+ readonly header: string;
10
+ readonly width?: number;
11
+ };
12
+ /** Explicit host-authored label; the event includes the group label and all accepted body-row count. */
13
+ readonly subtotalLabel: (group: Extract<GroupedReportEvent, {
14
+ readonly kind: "groupEnd";
15
+ }>) => string;
16
+ /** Explicit host-authored label for the final summary. */
17
+ readonly grandTotalLabel: (summary: GroupedReportSummary) => string;
18
+ /** Include the final summary row, including an empty report's zero/null totals. Default true. */
19
+ readonly includeGrandTotal?: boolean;
20
+ /** Repeated before column headings on continued group pages. Defaults to the exact captured group label. */
21
+ readonly continuationLabel?: (group: Extract<GroupedReportEvent, {
22
+ readonly kind: "groupStart";
23
+ }>) => string;
24
+ /** Tagged heading level for the outermost group, followed by one level per nested group. Default 2.
25
+ * Every opened group must fit through heading level 6; choose 1 for a titleless standalone report. */
26
+ readonly groupHeadingLevel?: 1 | 2 | 3 | 4 | 5 | 6;
27
+ }
28
+ /** A composed analytical table inherits fonts, page geometry, cancellation and cumulative limits from its document. */
29
+ export interface GroupedPdfTableOptions extends Omit<PdfTableOptions<readonly ExportValue[]>, "columns" | "footer" | "headerRows">, GroupedPdfLabels {
30
+ }
31
+ /** Analytical groups use the composed document/table layout owner and its resource policy. */
32
+ export interface GroupedPdfOptions extends Omit<PdfOptions<readonly ExportValue[]>, "columns" | "footer" | "headerRows">, GroupedPdfLabels {
33
+ }
34
+ export {};
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,10 @@
1
+ import type { GroupedReportSource } from "../core/grouped-report.js";
2
+ import type { ExportResult, OutputDestination } from "../core/index.js";
3
+ import type { GroupedPdfOptions } from "./grouped-types.js";
4
+ export { pdfGroupedTable } from "./grouped-table.js";
5
+ /** Stream analytical groups through the composed document owner. No group body is retained. */
6
+ export declare function writeGroupedPdf(report: GroupedReportSource, configuration: GroupedPdfOptions): Promise<Blob>;
7
+ /** Result/progress rows count source data. Generated subtotals and grand totals also consume maxRows.
8
+ * Tagged output uses nested group sections and separately headed summary tables. Untagged oversized
9
+ * detail/subtotal bundles use ordinary row pagination. */
10
+ export declare function writeGroupedPdfTo(report: GroupedReportSource, destination: OutputDestination, configuration: GroupedPdfOptions): Promise<ExportResult>;
@@ -0,0 +1,37 @@
1
+ import { assertGroupedReportSource } from "../core/grouped-report.js";
2
+ import { BlobByteSink } from "../core/sinks.js";
3
+ import { writePdfDocumentTo } from "./document.js";
4
+ import { pdfOptionFields } from "./settings.js";
5
+ import { captureFields } from "../internal/capture.js";
6
+ import { pdfGroupedTable, groupedPdfLabelFields, groupedPdfTableFields } from "./grouped-table.js";
7
+ export { pdfGroupedTable } from "./grouped-table.js";
8
+ const groupedOptionFields = [...pdfOptionFields, ...groupedPdfLabelFields];
9
+ /** Stream analytical groups through the composed document owner. No group body is retained. */
10
+ export async function writeGroupedPdf(report, configuration) {
11
+ const sink = new BlobByteSink();
12
+ try {
13
+ await writeGroupedPdfTo(report, sink, configuration);
14
+ return sink.toBlob("application/pdf");
15
+ }
16
+ catch (error) {
17
+ sink.discard();
18
+ throw error;
19
+ }
20
+ }
21
+ /** Result/progress rows count source data. Generated subtotals and grand totals also consume maxRows.
22
+ * Tagged output uses nested group sections and separately headed summary tables. Untagged oversized
23
+ * detail/subtotal bundles use ordinary row pagination. */
24
+ export async function writeGroupedPdfTo(report, destination, configuration) {
25
+ assertGroupedReportSource(report);
26
+ if (!configuration || typeof configuration !== "object")
27
+ throw new TypeError("Grouped PDF options are required.");
28
+ const captured = captureFields(configuration, groupedOptionFields);
29
+ const tableOptions = Object.fromEntries(groupedPdfTableFields.filter(name => Object.hasOwn(captured, name)).map(name => [name, captured[name]]));
30
+ const documentOptions = { ...captured };
31
+ for (const name of groupedPdfTableFields)
32
+ delete documentOptions[name];
33
+ delete documentOptions.columns;
34
+ delete documentOptions.headerRows;
35
+ delete documentOptions.footer;
36
+ return writePdfDocumentTo([pdfGroupedTable(report, tableOptions)], destination, documentOptions);
37
+ }
@@ -0,0 +1,22 @@
1
+ export { writePdf, writePdfTo } from "./write.js";
2
+ export { writeGroupedPdf, writeGroupedPdfTo, pdfGroupedTable } from "./grouped.js";
3
+ export type { GroupedPdfOptions, GroupedPdfTableOptions } from "./grouped-types.js";
4
+ export type { PdfPageNumberLabels } from "./types.js";
5
+ export type { BooleanText } from "../core/value-text.js";
6
+ export { createGroupedReport } from "../core/grouped-report.js";
7
+ export type { GroupedReportSource, GroupedReportOptions, GroupedReportEvent, GroupedReportSummary, GroupedReportValueContext, GroupedReportLevel, GroupedReportGroup } from "../core/grouped-report.js";
8
+ export { writePdfDocument, writePdfDocumentTo, pdfTable } from "./document.js";
9
+ export type { PdfDocumentOptions, PdfDocumentBlock, PdfTableOptions, PdfTableBlock, PdfParagraphBlock, PdfParagraphStyle, PdfCaption, PdfListBlock, PdfListItem, PdfGroupBlock, PdfPageBreakBlock, PdfImageBlock, PdfRawImage, PdfJpegImage, PdfPngImage, PdfVectorBlock, PdfPathCommand } from "./document-types.js";
10
+ export type { PdfTextRun, PdfText } from "./inline-types.js";
11
+ export type { PdfTextDirection, PdfShapingRun, PdfShapedGlyph, PdfShapedRun, PdfShapeLineRequest, PdfTextShaper } from "./text-shaping-types.js";
12
+ export type { PdfDrawing, PdfDrawingBlock, PdfDrawingElement, PdfDrawingPath, PdfDrawingText, PdfDrawingGroup, PdfDrawingClip, PdfDrawingFont } from "./drawing-types.js";
13
+ export { PdfFont } from "./font.js";
14
+ export type { PdfFontPreparationOptions } from "./font.js";
15
+ export { preflightPdfText } from "./preflight.js";
16
+ export { ExportCell } from "../core/presentation.js";
17
+ export { saveBlob } from "../core/index.js";
18
+ export type { PdfOptions, PdfTableBands, PdfPageSize, PdfMargins, PdfFonts, PdfLimits, PdfTaggedOptions, PdfTableFooter, PdfPageContext, PdfTotal } from "./types.js";
19
+ export type { PdfTextPreflightOptions, PdfTextPreflightResult, PdfTextIssueCode } from "./types.js";
20
+ export type { CellValue, Column, ColumnValueContext, ExportValue, CellPresentation, ExportResult, ExportProgress, OutputDestination, ByteSink, TableSpanCell, TableSpanRows } from "../core/index.js";
21
+ export type { PdfSectionBlock, PdfBookmark } from "./section-types.js";
22
+ export type { PdfGroupedTableBlock } from "./document-types.js";
@@ -0,0 +1,8 @@
1
+ export { writePdf, writePdfTo } from "./write.js";
2
+ export { writeGroupedPdf, writeGroupedPdfTo, pdfGroupedTable } from "./grouped.js";
3
+ export { createGroupedReport } from "../core/grouped-report.js";
4
+ export { writePdfDocument, writePdfDocumentTo, pdfTable } from "./document.js";
5
+ export { PdfFont } from "./font.js";
6
+ export { preflightPdfText } from "./preflight.js";
7
+ export { ExportCell } from "../core/presentation.js";
8
+ export { saveBlob } from "../core/index.js";
@@ -0,0 +1,30 @@
1
+ import type { CellPresentation, ExportLink } from "../core/index.js";
2
+ import type { PdfFontResource } from "./font-resources.js";
3
+ import type { PdfShapedGlyph } from "./text-shaping-types.js";
4
+ import { PdfFont } from "./font.js";
5
+ export interface CapturedRun {
6
+ readonly text: string;
7
+ readonly style: Readonly<CellPresentation>;
8
+ readonly link?: Readonly<ExportLink>;
9
+ readonly font?: PdfFont;
10
+ }
11
+ export interface PdfInlineSegment {
12
+ readonly text: string;
13
+ readonly width: number;
14
+ readonly font: PdfFontResource;
15
+ readonly color?: string;
16
+ readonly link?: Readonly<ExportLink>;
17
+ readonly glyphs?: readonly (PdfShapedGlyph & {
18
+ readonly logicalText: string;
19
+ })[];
20
+ readonly logicalStart?: number;
21
+ readonly actualText?: string;
22
+ }
23
+ export interface PdfInlineLine {
24
+ readonly text: string;
25
+ readonly width: number;
26
+ readonly segments: readonly PdfInlineSegment[];
27
+ readonly lineHeight: number;
28
+ readonly ascent: number;
29
+ readonly actualText?: string;
30
+ }
@@ -0,0 +1,183 @@
1
+ import { NotSupportedError, OfficeIMOError } from "../core/errors.js";
2
+ import { copyExportLink } from "../core/links.js";
3
+ import { checkAbort, pause, taskYieldDue } from "../core/iteration.js";
4
+ import { presentation, color } from "./settings.js";
5
+ import { wrapShapedPdfText } from "./shaped-text.js";
6
+ import { PdfFont } from "./font.js";
7
+ import { pdfBudgetText } from "./text.js";
8
+ /** @internal Callers supply an owned, validated, frozen base presentation. A run list is a PDF presentation value, never an alternate shared table value model. */
9
+ export function capturePdfText(value, base, settings, fonts, countEmpty = true, reserveBudget = true) {
10
+ if (typeof value === "string") {
11
+ if (value.length > settings.limits.maxCellCharacters)
12
+ throw new OfficeIMOError("RESOURCE_LIMIT", "maxCellCharacters exceeded.");
13
+ if (reserveBudget && (value.length || countEmpty))
14
+ settings.budget.reserve(1, pdfBudgetText(value, settings.budget).length);
15
+ return Object.freeze({ text: value, runs: Object.freeze([Object.freeze({ text: value, style: base })]) });
16
+ }
17
+ const input = value;
18
+ if (!Array.isArray(input)) {
19
+ if (input && typeof input.then === "function")
20
+ void Promise.resolve(input).catch(() => { });
21
+ throw new TypeError("PDF text must be a string or a synchronous array of text runs.");
22
+ }
23
+ if (input.length > settings.limits.maxTextRuns)
24
+ throw new OfficeIMOError("RESOURCE_LIMIT", "maxTextRuns exceeded.");
25
+ let characters = 0, budgetCharacters = 0;
26
+ const runs = [];
27
+ for (const run of input) {
28
+ if (!run || typeof run !== "object" || Object.keys(run).some(key => !["text", "bold", "italic", "color", "link", "font"].includes(key)))
29
+ throw new TypeError("PDF text runs support text, bold, italic, color, link and font.");
30
+ const { text, bold, italic, color, link, font } = run;
31
+ if (typeof text !== "string")
32
+ throw new TypeError("PDF run text must be a string.");
33
+ if (font !== undefined) {
34
+ if (!(font instanceof PdfFont))
35
+ throw new TypeError("A PDF run font must be a PdfFont.");
36
+ fonts.registerFont(font);
37
+ }
38
+ characters += text.length;
39
+ if (characters > settings.limits.maxCellCharacters)
40
+ throw new OfficeIMOError("RESOURCE_LIMIT", "maxCellCharacters exceeded.");
41
+ if (reserveBudget)
42
+ budgetCharacters += pdfBudgetText(text, settings.budget).length;
43
+ const style = presentation({ ...base, ...(bold === undefined ? {} : { bold }), ...(italic === undefined ? {} : { italic }), ...(color === undefined ? {} : { color }) });
44
+ if (settings.options.tagged && link !== undefined && text.length && !text.trim())
45
+ throw new TypeError("Tagged PDF inline links require nonempty displayed text.");
46
+ runs.push(Object.freeze({ text, style, ...(font === undefined ? {} : { font }), ...(link === undefined ? {} : { link: copyExportLink(link) }) }));
47
+ }
48
+ // Reserve before allocating a joined rich-text value or retaining it in a kept paragraph chain.
49
+ if (reserveBudget && (characters || countEmpty))
50
+ settings.budget.reserve(1, budgetCharacters);
51
+ return Object.freeze({ text: runs.map(run => run.text).join(""), runs: Object.freeze(runs) });
52
+ }
53
+ /** @internal Greedy wrapping over the continuous text stream, preserving run emphasis and URI geometry. */
54
+ export async function wrapPdfText(captured, fonts, size, width, settings, wrap = true) {
55
+ if (settings.options.textShaper)
56
+ return wrapShapedPdfText(captured, fonts, size, width, settings, wrap);
57
+ const { signal } = settings.options, { text, runs } = captured;
58
+ checkAbort(signal);
59
+ // Keep font-selection order while deferring a single-run face array until wrapping needs it.
60
+ const single = runs.length === 1 ? runs[0] : undefined;
61
+ const singleFace = single && fonts.select(single.style.bold, single.style.italic, single.font);
62
+ const selectedFaces = singleFace ? undefined : runs.map(run => fonts.select(run.style.bold, run.style.italic, run.font));
63
+ const fallback = fonts.select();
64
+ // Short fitting runs need no per-character layout arrays. Longer text keeps the existing
65
+ // cooperative checkpoints; controls or the first overflowing advance use the general path.
66
+ if (single && text.length > 0 && text.length < 4096) {
67
+ const run = single, font = singleFace;
68
+ let widthSoFar = 0, fits = true;
69
+ for (let offset = 0; offset < text.length;) {
70
+ const scalar = text.codePointAt(offset);
71
+ if (scalar === 9 || scalar === 10 || scalar === 13) {
72
+ fits = false;
73
+ break;
74
+ }
75
+ const advance = font.width(scalar) * size / 1000;
76
+ if (advance > width + .001 || widthSoFar + advance > width + .001) {
77
+ fits = false;
78
+ break;
79
+ }
80
+ widthSoFar += advance;
81
+ offset += scalar > 0xffff ? 2 : 1;
82
+ }
83
+ if (fits) {
84
+ if (settings.limits.maxRowLines < 1)
85
+ throw new OfficeIMOError("RESOURCE_LIMIT", "maxRowLines exceeded.");
86
+ return [{ text, width: widthSoFar, segments: [{ text, width: widthSoFar, font,
87
+ ...(run.style.color === undefined ? {} : { color: run.style.color }), ...(run.link ? { link: run.link } : {}) }],
88
+ lineHeight: font.lineHeight(size), ascent: Math.max(0, (font.program?.ascent ?? 800) * size / 1000) }];
89
+ }
90
+ }
91
+ const faces = selectedFaces ?? [singleFace], lines = [];
92
+ let chars = [], advances = [], owners = [], measured = 0, breakAt = -1;
93
+ let runIndex = 0, runEnd = runs[0]?.text.length ?? 0, scanned = 0;
94
+ const emit = (count) => {
95
+ if (lines.length >= settings.limits.maxRowLines)
96
+ throw new OfficeIMOError("RESOURCE_LIMIT", "maxRowLines exceeded.");
97
+ const segments = [];
98
+ let lineWidth = 0, lineHeight = 0, ascent = 0;
99
+ for (let begin = 0; begin < count;) {
100
+ const owner = owners[begin], run = runs[owner], font = faces[owner];
101
+ let end = begin + 1;
102
+ while (end < count && owners[end] === owner)
103
+ end++;
104
+ const segmentWidth = advances.slice(begin, end).reduce((total, advance) => total + advance, 0);
105
+ segments.push({ text: chars.slice(begin, end).join(""), width: segmentWidth, font,
106
+ ...(run.style.color === undefined ? {} : { color: run.style.color }), ...(run.link ? { link: run.link } : {}) });
107
+ lineWidth += segmentWidth;
108
+ lineHeight = Math.max(lineHeight, font.lineHeight(size));
109
+ ascent = Math.max(ascent, (font.program?.ascent ?? 800) * size / 1000);
110
+ begin = end;
111
+ }
112
+ // Empty physical lines remain observable line breaks without creating zero-area links.
113
+ if (!segments.length) {
114
+ const font = faces[0] ?? fallback;
115
+ segments.push({ text: "", width: 0, font, ...(runs[0]?.style.color === undefined ? {} : { color: runs[0].style.color }) });
116
+ lineHeight = font.lineHeight(size);
117
+ ascent = (font.program?.ascent ?? 800) * size / 1000;
118
+ }
119
+ lines.push({ text: chars.slice(0, count).join(""), width: lineWidth, segments, lineHeight, ascent });
120
+ chars = chars.slice(count);
121
+ advances = advances.slice(count);
122
+ owners = owners.slice(count);
123
+ measured = advances.reduce((total, advance) => total + advance, 0);
124
+ breakAt = -1;
125
+ for (let i = 0; i < chars.length; i++)
126
+ if (chars[i] === " ")
127
+ breakAt = i;
128
+ };
129
+ const append = (character, owner) => {
130
+ const advance = faces[owner].width(character.codePointAt(0)) * size / 1000;
131
+ if (advance > width + .001)
132
+ throw new RangeError("PDF column is too narrow for a glyph. Increase page/column width or reduce padding/font size.");
133
+ if (measured + advance > width + .001) {
134
+ if (!wrap)
135
+ throw new RangeError("Unwrapped PDF cell exceeds its column width.");
136
+ emit(breakAt >= 0 ? breakAt + 1 : chars.length);
137
+ if (measured + advance > width + .001)
138
+ emit(chars.length);
139
+ }
140
+ chars.push(character);
141
+ advances.push(advance);
142
+ owners.push(owner);
143
+ measured += advance;
144
+ if (character === " ")
145
+ breakAt = chars.length - 1;
146
+ };
147
+ for (let offset = 0; offset < text.length;) {
148
+ while (offset >= runEnd && runIndex < runs.length - 1)
149
+ runEnd += runs[++runIndex].text.length;
150
+ const owner = runIndex, scalar = text.codePointAt(offset), character = String.fromCodePoint(scalar);
151
+ if (offset + character.length > runEnd && runIndex < runs.length - 1) {
152
+ let next = runIndex + 1;
153
+ while (!runs[next].text.length)
154
+ next++;
155
+ const first = runs[owner], other = runs[next], firstFace = faces[owner], nextFace = faces[next];
156
+ const sameFace = firstFace.font === nextFace.font && (firstFace.font ?
157
+ firstFace.syntheticBold === nextFace.syntheticBold && firstFace.syntheticItalic === nextFace.syntheticItalic :
158
+ firstFace.bold === nextFace.bold && firstFace.italic === nextFace.italic);
159
+ if (!sameFace || color(first.style.color ?? "111827") !== color(other.style.color ?? "111827") ||
160
+ first.link?.target !== other.link?.target || first.link?.tooltip !== other.link?.tooltip)
161
+ throw new NotSupportedError("A PDF presentation boundary cannot split a UTF-16 scalar.");
162
+ }
163
+ offset += character.length;
164
+ if (character === "\r" || character === "\n") {
165
+ if (character === "\r" && text[offset] === "\n")
166
+ offset++;
167
+ emit(chars.length);
168
+ }
169
+ else if (character === "\t") {
170
+ for (let i = 0; i < 4; i++)
171
+ append(" ", owner);
172
+ }
173
+ else
174
+ append(character, owner);
175
+ if ((++scanned & 4095) === 0) {
176
+ if (taskYieldDue())
177
+ await pause();
178
+ checkAbort(signal);
179
+ }
180
+ }
181
+ emit(chars.length);
182
+ return lines;
183
+ }
@@ -0,0 +1,15 @@
1
+ import type { ExportLink } from "../core/links.js";
2
+ import type { PdfFont } from "./font.js";
3
+ /** One text run. Omitted emphasis/color inherits the paragraph or cell presentation. */
4
+ export interface PdfTextRun {
5
+ readonly text: string;
6
+ readonly bold?: boolean;
7
+ readonly italic?: boolean;
8
+ readonly color?: string;
9
+ /** Exact embedded face. Bold/italic flags apply synthetic emphasis to an explicit face. No font fallback occurs. */
10
+ readonly font?: PdfFont;
11
+ /** Native URI annotation over each painted run fragment. */
12
+ readonly link?: ExportLink;
13
+ }
14
+ /** Literal text or ordered inline runs; run boundaries do not introduce spaces or line breaks. */
15
+ export type PdfText = string | readonly PdfTextRun[];
@@ -0,0 +1 @@
1
+ export {};
@@ -0,0 +1,6 @@
1
+ import type { PdfListBlock, PdfListItem } from "./document-types.js";
2
+ import type { PdfFontResources } from "./font-resources.js";
3
+ import type { PdfSettings } from "./settings.js";
4
+ export declare function captureListOptions(block: PdfListBlock, settings: PdfSettings): PdfCapturedListOptions;
5
+ /** Capture the whole rich item before layout can yield; marker and body share fonts, bounds and cancellation. */
6
+ export declare function prepareListItem(item: PdfListItem, index: number, options: PdfCapturedListOptions, settings: PdfSettings, fonts: PdfFontResources): Promise<PdfPreparedListItem>;
@@ -0,0 +1,49 @@
1
+ import { capturePdfText, wrapPdfText } from "./inline-text.js";
2
+ import { captureParagraph, prepareParagraph } from "./paragraph-layout.js";
3
+ import { resolveParagraphStyle } from "./paragraph-styles.js";
4
+ export function captureListOptions(block, settings) {
5
+ const { items, ordered = false, start: inputStart, itemStyle, indent, markerGap } = block;
6
+ const start = inputStart === undefined ? 1 : inputStart;
7
+ if (typeof ordered !== "boolean")
8
+ throw new TypeError("PDF list ordered must be boolean.");
9
+ if (!Number.isSafeInteger(start) || start < 1)
10
+ throw new RangeError("PDF list start must be a positive safe integer.");
11
+ if (!ordered && inputStart !== undefined)
12
+ throw new TypeError("PDF list start requires ordered:true.");
13
+ for (const [name, value] of [["indent", indent], ["markerGap", markerGap]])
14
+ if (value !== undefined && (!Number.isFinite(value) || value < 0 || value > 14400))
15
+ throw new RangeError("PDF list " + name + " must be from zero through 14,400 points.");
16
+ if (resolveParagraphStyle(itemStyle, {}, settings.paragraphStyles).keepWithNext)
17
+ throw new TypeError("PDF list item styles cannot use keepWithNext.");
18
+ return Object.freeze({ items, ordered, start, ...(itemStyle === undefined ? {} : { itemStyle }),
19
+ ...(indent === undefined ? {} : { indent }), ...(markerGap === undefined ? {} : { markerGap }) });
20
+ }
21
+ /** Capture the whole rich item before layout can yield; marker and body share fonts, bounds and cancellation. */
22
+ export async function prepareListItem(item, index, options, settings, fonts) {
23
+ if (!item || typeof item !== "object" || Array.isArray(item) || Object.keys(item).some(key => !["text", "style", "keepTogether"].includes(key)))
24
+ throw new TypeError("PDF list items support text, style and keepTogether.");
25
+ if (!Number.isSafeInteger(index) || index < 0 || !Number.isSafeInteger(options.start + index))
26
+ throw new RangeError("PDF list numbering must remain within positive safe integers.");
27
+ const { text, style = options.itemStyle, keepTogether } = item;
28
+ const captured = captureParagraph({ kind: "paragraph", text, ...(style === undefined ? {} : { style }),
29
+ ...(keepTogether === undefined ? {} : { keepTogether }) }, settings, fonts);
30
+ if (captured.keepWithNext)
31
+ throw new TypeError("PDF list item styles cannot use keepWithNext.");
32
+ if (!captured.text.text.trim().length)
33
+ throw new TypeError("PDF list items require nonempty text.");
34
+ const markerText = options.ordered ? String(options.start + index) + "." : "•";
35
+ const capturedMarker = capturePdfText(markerText, captured.style, settings, fonts);
36
+ settings.budget.cell(markerText, markerText.length);
37
+ const width = settings.page.width - settings.margins.left - settings.margins.right;
38
+ const marker = (await wrapPdfText(capturedMarker, fonts, captured.size, width, settings, false))[0];
39
+ const markerGap = options.markerGap ?? captured.size / 2, indent = options.indent ?? Math.max(captured.size * 2, marker.width + markerGap);
40
+ if (marker.width + markerGap > indent + .001)
41
+ throw new RangeError("PDF list indent cannot fit its marker and gap.");
42
+ if (indent >= width)
43
+ throw new RangeError("PDF list indent leaves no body text area.");
44
+ const paragraph = await prepareParagraph(captured, settings, fonts, width - indent), first = paragraph.lines[0];
45
+ const lineHeight = Math.max(first.lineHeight, marker.lineHeight), ascent = Math.max(first.ascent, marker.ascent);
46
+ return { marker, indent, markerGap, paragraph: { ...paragraph,
47
+ lines: [{ ...first, lineHeight, ascent }, ...paragraph.lines.slice(1)],
48
+ height: paragraph.height + lineHeight - first.lineHeight, firstHeight: paragraph.spaceBefore + lineHeight } };
49
+ }
@@ -0,0 +1,2 @@
1
+ export declare function pdfNumber(value: number): string;
2
+ export declare function unicodeHex(text: string): string;