gutterpress 0.11.23-beta.2 → 0.11.23
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/README.md +12 -2
- package/dist/api/index.d.ts +5 -5
- package/dist/api/index.js +19 -7
- package/dist/{build-3e18wnqj.js → build-ph6jn930.js} +9 -9
- package/dist/checks/asset/approved-fonts.d.ts +8 -0
- package/dist/checks/asset/extensions.d.ts +1 -1
- package/dist/checks/asset/index.d.ts +1 -0
- package/dist/{cli-88arpdke.js → cli-axqsy7xn.js} +296 -65
- package/dist/{cli-9n9kg58f.js → cli-b8rmyy7t.js} +1 -1
- package/dist/{cli-x7gcdg6w.js → cli-ep43hgqb.js} +1 -1
- package/dist/{cli-v0evdpdf.js → cli-eymdsefg.js} +1 -1
- package/dist/{cli-pd2cje5b.js → cli-fsjre61x.js} +1 -1
- package/dist/{cli-0ep11b0q.js → cli-gy95bxec.js} +1 -1
- package/dist/{cli-pnrararp.js → cli-vqt6808y.js} +162 -55
- package/dist/{cli-tgnyvra3.js → cli-w6ywbxym.js} +35 -16
- package/dist/cli.js +12 -12
- package/dist/{doctor-2f4s9dyn.js → doctor-rx93cd3j.js} +3 -3
- package/dist/{engine-c4pxz79g.js → engine-17v87vq5.js} +1 -1
- package/dist/{engine-cs5g2ez0.js → engine-y9fnarfa.js} +2 -2
- package/dist/{ext-70gv86v5.js → ext-3b64v44z.js} +27 -10
- package/dist/{extension-restore-chj5nx3t.js → extension-restore-3yy4pzy9.js} +3 -3
- package/dist/{extension-restore-pd87p8r2.js → extension-restore-6hsxgmvn.js} +5 -5
- package/dist/{index-80vg3ed6.js → index-37cxffyb.js} +35 -16
- package/dist/{index-ytjkvwy5.js → index-7wgf4bqz.js} +321 -66
- package/dist/{index-swfdgn2n.js → index-d9w3r89w.js} +1 -1
- package/dist/{index-5x42amh8.js → index-g3te5ey1.js} +2 -1
- package/dist/{index-7j3hkwya.js → index-kw4tbthz.js} +1 -1
- package/dist/{index-0k43evt0.js → index-rzdn6r10.js} +186 -60
- package/dist/{index-2t1gdma7.js → index-santcs4q.js} +1 -1
- package/dist/index.js +35 -8
- package/dist/lib/check-options.d.ts +70 -0
- package/dist/lib/extension-manager.d.ts +16 -1
- package/dist/lib/extension-scaffold.d.ts +15 -2
- package/dist/lib/extension-specifier.d.ts +8 -1
- package/dist/lib/manifest-config.d.ts +3 -1
- package/dist/lib/manifest-old-spellings.d.ts +32 -9
- package/dist/lib/markdown/math.d.ts +1 -1
- package/dist/lib/markdown/typography.d.ts +1 -0
- package/dist/lib/page-size.d.ts +12 -4
- package/dist/lib/plugin-vendor.d.ts +6 -0
- package/dist/lib/presets.d.ts +2 -2
- package/dist/lib/root-tokens.d.ts +2 -1
- package/dist/lib/style-resolver.d.ts +2 -1
- package/dist/lib/version-changes.d.ts +9 -3
- package/dist/{manifest.schema-0jgj0jt1.json → manifest.schema-5cm13vr3.json} +215 -5
- package/dist/{new-d61n5cn0.js → new-3xrnhzr8.js} +22 -15
- package/dist/{plugins-0hhw6s17.js → plugins-1ed7bbxn.js} +2 -2
- package/dist/{plugins-e0n46s6m.js → plugins-ar5wrek4.js} +4 -4
- package/dist/{preflight-fjayhjr5.js → preflight-shmd1cnr.js} +9 -9
- package/dist/{preview-h815jrfb.js → preview-dadmsstg.js} +9 -9
- package/dist/{publish-ft39zgma.js → publish-s7vb3q2y.js} +9 -9
- package/dist/render.js +43 -11
- package/dist/schema/manifest.types.d.ts +45 -7
- package/dist/{source-provider-j1w7byeq.js → source-provider-3g3yrn1f.js} +2 -2
- package/dist/{source-provider-tjaf303m.js → source-provider-azg9ywhb.js} +2 -2
- package/dist/{validate-b201dbrb.js → validate-0h3b5vq4.js} +9 -9
- package/package.json +1 -1
- /package/dist/{cli-y28j019d.js → cli-1dha1nxk.js} +0 -0
|
@@ -7,6 +7,42 @@ type CheckSeverity = "error" | "warning" | "info";
|
|
|
7
7
|
* check's own severity; `false` is `off`. `warning` is accepted for `warn`.
|
|
8
8
|
*/
|
|
9
9
|
export type CheckLevelInput = "off" | "on" | "info" | "warn" | "warning" | "error" | boolean;
|
|
10
|
+
/**
|
|
11
|
+
* A `checks:` entry that also sets options: the numbers or the list a check
|
|
12
|
+
* measures against, which the preset and the publish target otherwise set
|
|
13
|
+
* (`lib/check-options.ts` lists which check takes which). `level` is optional;
|
|
14
|
+
* left out, the check keeps the level the preset and target give it.
|
|
15
|
+
*
|
|
16
|
+
* checks:
|
|
17
|
+
* pdf.print.ink-coverage: { maxTac: 300 }
|
|
18
|
+
* pdf.print.image-resolution: { level: error, minImageResolution: 200 }
|
|
19
|
+
*/
|
|
20
|
+
export interface CheckEntry {
|
|
21
|
+
level?: CheckLevelInput;
|
|
22
|
+
/** `pdf.print.ink-coverage`: the total ink limit in percent (and what a PDF/X build holds the ink to). */
|
|
23
|
+
maxTac?: number;
|
|
24
|
+
/** `pdf.print.ink-coverage`: how far over `maxTac` a page may measure before it is reported. */
|
|
25
|
+
tacTolerance?: number;
|
|
26
|
+
/** `pdf.print.page-size`: how far (pt) the built PDF's page may differ from the manifest's size. */
|
|
27
|
+
tolerance?: number;
|
|
28
|
+
/** `pdf.print.image-resolution`: the lowest DPI a placed image may print at; 0 = no floor. */
|
|
29
|
+
minImageResolution?: number;
|
|
30
|
+
/** `pdf.print.bleed`: the bleed (pt) each side must have. */
|
|
31
|
+
bleedSize?: number;
|
|
32
|
+
/** `asset.image.file-size`: the largest image file in bytes; 0 = no limit. */
|
|
33
|
+
maxImageSize?: number;
|
|
34
|
+
/** `asset.font.approved-files`: the font files a book may ship (glob patterns, relative to the book); empty = any. */
|
|
35
|
+
approvedFontFiles?: string[];
|
|
36
|
+
/** `heuristic.decoration.layer-count`: the most decorative layers on one page. */
|
|
37
|
+
maxDecorativeLayers?: number;
|
|
38
|
+
/** `heuristic.whitespace.text-density`: the characters a page should carry. */
|
|
39
|
+
textDensityRange?: {
|
|
40
|
+
min?: number;
|
|
41
|
+
max?: number;
|
|
42
|
+
};
|
|
43
|
+
/** `heuristic.chunking.section-density`: the most paragraphs in one section. */
|
|
44
|
+
maxParagraphsPerSection?: number;
|
|
45
|
+
}
|
|
10
46
|
/**
|
|
11
47
|
* A check's resolved level: `off`, `on` (runs at its own severity) or the
|
|
12
48
|
* severity every finding is reported at.
|
|
@@ -161,9 +197,10 @@ export interface GutterpressManifest {
|
|
|
161
197
|
/**
|
|
162
198
|
* Per-check and per-rule levels, keyed by a check id
|
|
163
199
|
* (`pdf.print.image-resolution`) or a lint rule id
|
|
164
|
-
* (`printsafe/no-risky-print-effects`)
|
|
200
|
+
* (`printsafe/no-risky-print-effects`), and the options a check takes
|
|
201
|
+
* ({@link CheckEntry}). A key that names nothing is ignored.
|
|
165
202
|
*/
|
|
166
|
-
checks?: Record<string, CheckLevelInput>;
|
|
203
|
+
checks?: Record<string, CheckLevelInput | CheckEntry>;
|
|
167
204
|
pdfx?: {
|
|
168
205
|
flavor?: "x1a" | "x3";
|
|
169
206
|
icc?: string;
|
|
@@ -339,7 +376,7 @@ export interface ResolvedConfig {
|
|
|
339
376
|
page: {
|
|
340
377
|
width: number;
|
|
341
378
|
height: number;
|
|
342
|
-
/** Allowed deviation (pt) of a built PDF's page size
|
|
379
|
+
/** Allowed deviation (pt) of a built PDF's page size: the preset's, or `checks.pdf.print.page-size.tolerance`. */
|
|
343
380
|
tolerance: number;
|
|
344
381
|
/** In-sheet bleed in pt (top, bottom, outer edge; see the manifest field); absent = none. */
|
|
345
382
|
bleed?: number;
|
|
@@ -357,15 +394,16 @@ export interface ResolvedConfig {
|
|
|
357
394
|
tacTolerance: number;
|
|
358
395
|
};
|
|
359
396
|
/**
|
|
360
|
-
* The numbers the checks measure against
|
|
361
|
-
*
|
|
362
|
-
*
|
|
363
|
-
* `checks:`.
|
|
397
|
+
* The numbers the checks measure against: the preset's and the publish
|
|
398
|
+
* target's (a printer's specification), overridden by a book's
|
|
399
|
+
* `checks.<id>` options ({@link CheckEntry}). `ink` above too.
|
|
364
400
|
*/
|
|
365
401
|
validate: {
|
|
366
402
|
assets: {
|
|
367
403
|
/** Largest image file in bytes; 0 = no limit. */
|
|
368
404
|
maxImageSize: number;
|
|
405
|
+
/** Glob patterns of the font files a book may ship; empty = any (`asset.font.approved-files`). */
|
|
406
|
+
approvedFontFiles: string[];
|
|
369
407
|
};
|
|
370
408
|
pdf: {
|
|
371
409
|
/** Lowest effective image resolution in DPI; 0 = no floor. */
|
|
@@ -29,9 +29,9 @@ import {
|
|
|
29
29
|
switchBranch,
|
|
30
30
|
whenGitIdle,
|
|
31
31
|
withRepoLock
|
|
32
|
-
} from "./cli-
|
|
32
|
+
} from "./cli-eymdsefg.js";
|
|
33
33
|
import"./cli-v5mp7a6q.js";
|
|
34
|
-
import"./cli-
|
|
34
|
+
import"./cli-1dha1nxk.js";
|
|
35
35
|
import"./cli-37x76zdn.js";
|
|
36
36
|
export {
|
|
37
37
|
withRepoLock,
|
|
@@ -29,8 +29,8 @@ import {
|
|
|
29
29
|
switchBranch,
|
|
30
30
|
whenGitIdle,
|
|
31
31
|
withRepoLock
|
|
32
|
-
} from "./index-
|
|
33
|
-
import"./index-
|
|
32
|
+
} from "./index-kw4tbthz.js";
|
|
33
|
+
import"./index-g3te5ey1.js";
|
|
34
34
|
import"./index-v5mp7a6q.js";
|
|
35
35
|
import"./index-37x76zdn.js";
|
|
36
36
|
export {
|
|
@@ -1,31 +1,31 @@
|
|
|
1
1
|
import {
|
|
2
2
|
executeAndReport
|
|
3
|
-
} from "./cli-
|
|
4
|
-
import"./cli-
|
|
3
|
+
} from "./cli-vqt6808y.js";
|
|
4
|
+
import"./cli-gy95bxec.js";
|
|
5
5
|
import"./cli-ht1bcqdd.js";
|
|
6
|
-
import"./cli-
|
|
6
|
+
import"./cli-fsjre61x.js";
|
|
7
7
|
import"./cli-5crpmz42.js";
|
|
8
8
|
import"./cli-eyyggect.js";
|
|
9
9
|
import"./cli-asap4t1z.js";
|
|
10
|
-
import"./cli-
|
|
10
|
+
import"./cli-eymdsefg.js";
|
|
11
11
|
import"./cli-v5mp7a6q.js";
|
|
12
|
-
import"./cli-
|
|
13
|
-
import"./cli-
|
|
12
|
+
import"./cli-axqsy7xn.js";
|
|
13
|
+
import"./cli-w6ywbxym.js";
|
|
14
14
|
import {
|
|
15
15
|
log
|
|
16
|
-
} from "./cli-
|
|
16
|
+
} from "./cli-b8rmyy7t.js";
|
|
17
17
|
import {
|
|
18
18
|
UsageError,
|
|
19
19
|
rejectExtraPositionals,
|
|
20
20
|
rejectUnknownFlags
|
|
21
21
|
} from "./cli-d8xjns66.js";
|
|
22
|
-
import"./cli-
|
|
22
|
+
import"./cli-ep43hgqb.js";
|
|
23
23
|
import"./cli-65gy8ask.js";
|
|
24
24
|
import {
|
|
25
25
|
BuildError,
|
|
26
26
|
EXIT_CODES
|
|
27
27
|
} from "./cli-46ycxe6r.js";
|
|
28
|
-
import"./cli-
|
|
28
|
+
import"./cli-1dha1nxk.js";
|
|
29
29
|
import"./cli-37x76zdn.js";
|
|
30
30
|
|
|
31
31
|
// src/commands/validate.ts
|
package/package.json
CHANGED
|
File without changes
|