@heroiclands/package-build 22.14.0 → 22.14.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.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # @heroiclands/package-build
2
2
 
3
+ ## 22.14.1
4
+
5
+ ### Patch Changes
6
+
7
+ Item-field reference pages generated inside content packages pass note validation and formatting checks.
8
+
3
9
  ## 22.14.0
4
10
 
5
11
  ### Minor Changes
@@ -36,6 +36,7 @@
36
36
 
37
37
  import path from "node:path";
38
38
  import matter from "gray-matter";
39
+ import { formatNoteFrontmatter } from "./note-format.mjs";
39
40
 
40
41
  import { authoredFields, runtimeOnlyFields } from "./field-spec.mjs";
41
42
  import { loadPackConfig } from "./pack-config.mjs";
@@ -389,7 +390,7 @@ export function shortcodeFromBasename(destination) {
389
390
  * The universal keys every note in the format carries: `type: doc`,
390
391
  * `subType: reference` — this page is out-of-world lookup material, the same
391
392
  * genre as every other generated reference — a `shortcode`, `name.full` from
392
- * the page's title, and `pack: none`, since the page publishes to the website
393
+ * the page's title, and `data.pack: none`, since the page publishes to the website
393
394
  * and compiles into no compendium document. A consumer's own
394
395
  * `docs.itemFields.frontmatter` is deep-merged over it, so it may add keys or
395
396
  * override any of the derived ones, `shortcode` included.
@@ -409,7 +410,7 @@ export function itemFieldsEnvelope({ title, shortcode, frontmatter }) {
409
410
  subType: "reference",
410
411
  shortcode,
411
412
  name: { full: title },
412
- pack: "none",
413
+ data: { pack: "none" },
413
414
  },
414
415
  frontmatter,
415
416
  );
@@ -448,5 +449,5 @@ export function renderItemFieldsPage(body, { title, destination, contentRoot, fr
448
449
  // between them, so a page written without one fails a consumer's
449
450
  // `lint:format` the moment it is committed. Insert it here rather than
450
451
  // let the generator and the formatter rewrite the file back and forth.
451
- return page.replace(/^(---\n[\s\S]*?\n---\n)/, "$1\n");
452
+ return formatNoteFrontmatter(page.replace(/^(---\n[\s\S]*?\n---\n)/, "$1\n"));
452
453
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@heroiclands/package-build",
3
- "version": "22.14.0",
3
+ "version": "22.14.1",
4
4
  "description": "Shared toolchain for building and shipping a HeroicLands Foundry VTT package — content compilation, manifest, localization, staging, bundle, release and deployment.",
5
5
  "license": "GPL-3.0-or-later",
6
6
  "type": "module",
@@ -52,7 +52,7 @@ export function shortcodeFromBasename(destination: string): string;
52
52
  * The universal keys every note in the format carries: `type: doc`,
53
53
  * `subType: reference` — this page is out-of-world lookup material, the same
54
54
  * genre as every other generated reference — a `shortcode`, `name.full` from
55
- * the page's title, and `pack: none`, since the page publishes to the website
55
+ * the page's title, and `data.pack: none`, since the page publishes to the website
56
56
  * and compiles into no compendium document. A consumer's own
57
57
  * `docs.itemFields.frontmatter` is deep-merged over it, so it may add keys or
58
58
  * override any of the derived ones, `shortcode` included.