node-pptx-templater 1.0.20 → 1.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -5,8 +5,47 @@ All notable changes to this project will be documented in this file.
5
5
  The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
6
6
  and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
7
 
8
+ ## [1.1.0] - 2026-06-12
9
+
10
+ ### Added
11
+
12
+ - **Runtime Log Level Control**: `PPTXTemplater.load(path, { logLevel: 'debug' })` — configure logging at load time without environment variables. Also added `PPTXTemplater.setLogLevel(level)` static method and `ppt.enableDebug()` instance shortcut. Supported levels: `verbose`, `debug`, `info`, `warn` (default), `error`, `silent`. The new `setGlobalLogLevel()` and `resetLogLevel()` functions are now exported from the public API.
13
+
14
+ - **`verbose` Log Level**: New log level below `debug` for maximum diagnostic output. Use `PPTXTemplater.setLogLevel('verbose')` to enable.
15
+
16
+ - **`getTableRows(tableId, options)`**: Extract table data as structured JSON. Supports three modes: default (array of objects using header row as keys), `{ raw: true }` (array of string arrays), and `{ includeMetadata: true }` (full metadata including row/column count and merged cell info).
17
+
18
+ - **Nested `addTableRow()` with `mergeStrategy`**: Add rows with nested arrays to create rowspan-merged cells. Options: `'rowspan'` (OpenXML vertical spans), `'auto'` (merge identical adjacent values), `'none'` (expand to flat rows).
19
+
20
+ - **8 new example files** in `examples/`: `image-operations.js`, `shape-operations.js`, `z-order.js`, `slide-import.js`, `text-search.js`, `table-extraction.js`, `nested-table-rows.js`, `xml-folder-workflow.js`.
21
+
22
+ - **Documentation Validation Tooling** (`scripts/validate-docs.js`): Checks that every public method has JSDoc. Exits with code 1 on violations. Run via `npm run docs:validate`.
23
+
24
+ - **Feature Inventory Generator** (`scripts/generate-feature-inventory.js`): Parses `PPTXTemplater.js` and outputs `docs/feature-inventory.json` and `docs/feature-inventory.md` with all methods grouped by category. Run via `npm run docs:inventory`.
25
+
26
+ - **Professional logo** (`assets/logo.png`): Library logo suitable for GitHub, NPM, and documentation.
27
+
28
+ - **New npm scripts**: `docs:validate`, `docs:inventory`, `example:images`, `example:shapes`, `example:zorder`, `example:slide-import`, `example:text-search`, `example:table-extraction`, `example:nested-rows`, `example:xml-folder`.
29
+
30
+ ### Fixed
31
+
32
+ - **Horizontal merge preservation**: Fixed PowerPoint "repair mode" errors when using `addTableRow()` with rows containing `gridSpan`/`hMerge` attributes. The cloning logic now correctly preserves horizontal merge attributes and only clears vertical merge state.
33
+
34
+ - **`console.log` violations** in `ChartManager.js` (3 calls in `updateChartAsync()`), `OutputWriter.js` (5 calls in `printDebugZip()`), and `PPTXTemplater.js` (8 calls across `debugRelationships()`, `inspectSlide()`, `inspectXML()`, `inspectChart()`, `debugChartRelationships()`). All replaced with structured `logger.debug()` / `logger.info()` calls that respect the configured log level. **The library is now completely silent by default** — no terminal output at all unless explicitly enabled.
35
+
36
+ ### Changed
37
+
38
+ - **Logger system overhauled**: Added `verbose` level, runtime `setGlobalLogLevel()` function, `resetLogLevel()` function, and module-level `runtimeLevel` override. All logger instances now share a mutable runtime level for live updates.
39
+
40
+ - **README**: Rewritten to be concise, modern, and SEO-friendly. Detailed API docs now live at https://jsuyog2.github.io/node-pptx-templater/.
41
+
42
+ - **Version**: Bumped from `1.0.21` → `1.1.0`.
43
+
44
+ ---
45
+
8
46
  ## [1.0.6] - 2026-06-02
9
47
 
48
+
10
49
  ### Added
11
50
 
12
51
  - **XML Validation & Diagnostics Engine**: Introduced a suite of tools in `src/utils/xmlUtils.js` for XML safety and diagnostics: