gutterpress 0.10.11 → 0.11.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/README.md +1 -1
- package/dist/{README-7x5akcns.md → README-3nj919rm.md} +10 -8
- package/dist/{README-3zk4tgnj.md → README-8b33qbjw.md} +14 -21
- package/dist/api/index.js +2 -2
- package/dist/{audit-ebbbhpx7.js → audit-9vv4ncjv.js} +4 -4
- package/dist/{build-zrajk3s2.js → build-ea05bvs0.js} +4 -4
- package/dist/{cli-gxq7yz5f.js → cli-6gg8vwaj.js} +1 -1
- package/dist/{cli-hz44te1m.js → cli-cwv73tkx.js} +1426 -1405
- package/dist/{cli-k8f9eb12.js → cli-sekhwex4.js} +5 -5
- package/dist/{cli-36r50yr3.js → cli-y4vrycpn.js} +1 -1
- package/dist/cli.js +14 -14
- package/dist/{doctor-78qft9g7.js → doctor-k529b5et.js} +2 -2
- package/dist/{engine-qtmvaqt7.js → engine-cbc17ne4.js} +1 -1
- package/dist/{engine-pt2acjb5.js → engine-w5ed5hmb.js} +2 -2
- package/dist/{ext-3g1mk8mb.js → ext-hbt1sdg5.js} +4 -4
- package/dist/{index-a0e2253t.js → index-12pvhbyz.js} +1 -1
- package/dist/{index-5dgxeevv.js → index-6n15e1ze.js} +5 -5
- package/dist/{index-03cqyyyk.js → index-qmvmvetj.js} +1764 -1748
- package/dist/index.js +3 -3
- package/dist/lib/markdown/index.d.ts +8 -16
- package/dist/lib/markdown/plugins.d.ts +9 -4
- package/dist/lib/markdown/renderer.d.ts +18 -0
- package/dist/lib/project-scaffold.d.ts +1 -1
- package/dist/{lint-va95zh6j.js → lint-cwb6h2n5.js} +4 -4
- package/dist/{new-3ex11eyq.js → new-sja9wn5c.js} +4 -4
- package/dist/plugin-spbcem4j.css +103 -0
- package/dist/{plugin.test.js-k2r87k04.tpl → plugin.test.js-nw7c84s6.tpl} +5 -6
- package/dist/{preflight-q8w6dnjh.js → preflight-maw8h45k.js} +4 -4
- package/dist/{preview-azatsrtp.js → preview-vjwpj4tf.js} +4 -4
- package/dist/{publish-5tqzepkb.js → publish-spej40gd.js} +4 -4
- package/dist/render.js +1 -1
- package/dist/{tokens-2sracx1w.css → tokens-7984461t.css} +8 -8
- package/dist/{validate-rp613ejg.js → validate-3ppsdngq.js} +4 -4
- package/package.json +1 -1
- package/dist/plugin-m2w7g47v.css +0 -114
package/README.md
CHANGED
|
@@ -537,7 +537,7 @@ An extension folder (or npm package) describes itself in its **`package.json`**
|
|
|
537
537
|
|
|
538
538
|
`main` is the markdown-it plugin — npm's own convention — so a plain markdown-it plugin package needs nothing else at all. A look needs only `gutterpress.styles` (an ordered list, relative to the folder); a component library carries both. `gutterpress.markdown` exists for the one case `main` can't express: a package whose `main` is not the plugin. Folders still carrying the removed `gutterpress.json` or `theme.json` fail to load with a message showing the package.json that replaces them.
|
|
539
539
|
|
|
540
|
-
Order is load order: a later entry's markdown runs after earlier entries' (and sees their output) and its CSS wins ties; the project's own `styles:`
|
|
540
|
+
Order is load order: a later entry's markdown runs after earlier entries' (and sees their output) and its CSS wins ties — each extension's stylesheets are wrapped in their own cascade layer (`@layer ext.<name>`), declared in list order, so this holds however an extension writes its CSS; the project's own `styles:` stay unlayered and load after every extension, beating all of them at any specificity. There is no `priority` and no `path:`/`name:` wrapper — a manifest still carrying `plugins:` fails with a message that prints the same entries rewritten as `extensions:`. The `engine:` and `engineStyles:` keys are gone too (there is one engine; move any `engineStyles` entries to the end of `styles:`).
|
|
541
541
|
|
|
542
542
|
Pinned npm packages and their runtime dependencies live under `plugins/npm/`,
|
|
543
543
|
with a receipt that records the exact graph and hashes the complete tree. They
|
|
@@ -134,14 +134,16 @@ settled by that one line rather than by which sheet `package.json`'s
|
|
|
134
134
|
`gutterpress.styles` lists last, so splitting a sheet or reordering that list
|
|
135
135
|
can no longer silently flip who wins.
|
|
136
136
|
|
|
137
|
-
The trap, and it catches everyone once: a rule left OUTSIDE all the layers
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
`
|
|
144
|
-
|
|
137
|
+
The trap, and it catches everyone once: a rule left OUTSIDE all the layers
|
|
138
|
+
beats every layered rule in the theme at any specificity. So one stray rule
|
|
139
|
+
at the bottom of `components.css` will out-rank every rule in `book.css`.
|
|
140
|
+
Adopt the convention for a whole sheet at a time.
|
|
141
|
+
|
|
142
|
+
Gutterpress wraps the whole theme in a cascade layer of its own
|
|
143
|
+
(`ext.<name>`), after core's `gp.marker`/`gp.vocab` and before the book's own
|
|
144
|
+
`styles:`. These layers nest inside it: they settle ties between the theme's
|
|
145
|
+
own files, every one of them beats core, and the book's own rules beat every
|
|
146
|
+
one of them.
|
|
145
147
|
|
|
146
148
|
### 3. Authors write semantic markdown
|
|
147
149
|
|
|
@@ -110,27 +110,20 @@ Marker names are global across every plugin a book loads. Two plugins
|
|
|
110
110
|
declaring `@callout` is a hard load error naming both — which is a good
|
|
111
111
|
outcome, and another reason to prefix.
|
|
112
112
|
|
|
113
|
-
### 5.
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
look
|
|
121
|
-
|
|
122
|
-
author
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
its layer sorts first and is the weakest thing in the book — the right place
|
|
128
|
-
for a plugin to sit. Listed below the look, its component rules win ties over
|
|
129
|
-
the look's layered rules instead. Either way the author moves one line to
|
|
130
|
-
change it; that is the whole point of the list.
|
|
131
|
-
|
|
132
|
-
Adopt it for the whole file: a rule left outside the layer is unlayered and
|
|
133
|
-
beats everything inside it, including your own.
|
|
113
|
+
### 5. Leave the cascade to Gutterpress
|
|
114
|
+
|
|
115
|
+
Gutterpress wraps every extension's CSS in a cascade layer of its own
|
|
116
|
+
(`@layer ext.<name>`), in `extensions:` list order, before the book's own
|
|
117
|
+
`styles:`. So `styles/plugin.css` needs no `@layer` of its own: the book's
|
|
118
|
+
unlayered `styles:` always beat you, at any specificity, which is right — a
|
|
119
|
+
plugin should be the easiest thing in the book to override — and against a
|
|
120
|
+
look, position decides. Listed above the look, this plugin's layer sorts first
|
|
121
|
+
and the look wins ties; listed below it, the plugin's component rules win.
|
|
122
|
+
Either way the author moves one line to change it; that is the whole point of
|
|
123
|
+
the list.
|
|
124
|
+
|
|
125
|
+
If you do declare layers inside this sheet, they nest inside your extension's
|
|
126
|
+
layer and only settle ties between your own rules.
|
|
134
127
|
|
|
135
128
|
## Theming: the token pattern
|
|
136
129
|
|
package/dist/api/index.js
CHANGED
|
@@ -124,12 +124,12 @@ import {
|
|
|
124
124
|
syncProject,
|
|
125
125
|
testRemoteAccess,
|
|
126
126
|
validateProjectExtensions
|
|
127
|
-
} from "../index-
|
|
127
|
+
} from "../index-qmvmvetj.js";
|
|
128
128
|
import {
|
|
129
129
|
BuildError,
|
|
130
130
|
DEFAULT_PRINT_OPTS,
|
|
131
131
|
readyProbeExpr
|
|
132
|
-
} from "../index-
|
|
132
|
+
} from "../index-6n15e1ze.js";
|
|
133
133
|
import {
|
|
134
134
|
AUTO_SNAPSHOT_MESSAGE,
|
|
135
135
|
HISTORY_PAGE_LIMIT,
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import {
|
|
2
2
|
executeAndReport
|
|
3
|
-
} from "./cli-
|
|
3
|
+
} from "./cli-cwv73tkx.js";
|
|
4
4
|
import {
|
|
5
5
|
log
|
|
6
|
-
} from "./cli-
|
|
6
|
+
} from "./cli-y4vrycpn.js";
|
|
7
7
|
import {
|
|
8
8
|
UsageError,
|
|
9
9
|
rejectExtraPositionals,
|
|
10
10
|
rejectUnknownFlags
|
|
11
|
-
} from "./cli-
|
|
12
|
-
import"./cli-
|
|
11
|
+
} from "./cli-6gg8vwaj.js";
|
|
12
|
+
import"./cli-sekhwex4.js";
|
|
13
13
|
import"./cli-c41yr7he.js";
|
|
14
14
|
import {
|
|
15
15
|
EXIT_CODES
|
|
@@ -1,18 +1,18 @@
|
|
|
1
1
|
import {
|
|
2
2
|
runBuild,
|
|
3
3
|
splitOutPath
|
|
4
|
-
} from "./cli-
|
|
4
|
+
} from "./cli-cwv73tkx.js";
|
|
5
5
|
import {
|
|
6
6
|
log
|
|
7
|
-
} from "./cli-
|
|
7
|
+
} from "./cli-y4vrycpn.js";
|
|
8
8
|
import {
|
|
9
9
|
UsageError,
|
|
10
10
|
parseFormat,
|
|
11
11
|
parsePdfxFlavor,
|
|
12
12
|
rejectExtraPositionals,
|
|
13
13
|
rejectUnknownFlags
|
|
14
|
-
} from "./cli-
|
|
15
|
-
import"./cli-
|
|
14
|
+
} from "./cli-6gg8vwaj.js";
|
|
15
|
+
import"./cli-sekhwex4.js";
|
|
16
16
|
import"./cli-c41yr7he.js";
|
|
17
17
|
import {
|
|
18
18
|
BuildError
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
// package.json
|
|
5
5
|
var package_default = {
|
|
6
6
|
name: "gutterpress",
|
|
7
|
-
version: "0.
|
|
7
|
+
version: "0.11.1",
|
|
8
8
|
description: "Markdown-to-PDF converter for professional print layout using a native Chromium print engine and Ghostscript.",
|
|
9
9
|
author: "itlackey",
|
|
10
10
|
license: "MPL-2.0",
|