gp-dimm-city 1.1.1 → 1.1.2

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
@@ -7,6 +7,100 @@ cut a version that has no `## [X.Y.Z]` heading below.
7
7
 
8
8
  ## [Unreleased]
9
9
 
10
+ ## [1.1.2] - 2026-10-08
11
+
12
+ **Notes for books upgrading from 1.1.1:**
13
+
14
+ - Build on gutterpress 0.11.15 or later and drop `@page .dc-printer-page`
15
+ and your own `print.signature`: the `dtrpg` preset now does both.
16
+ - Field Guide classes that moved into the package: `.fg-snug` becomes
17
+ `.dc-snug`, and the book-wide two-column skill cards become
18
+ `.dc-cards-two-col` on the specialty markers.
19
+ - Section panels, padding and splitting are tokens now. A book that
20
+ restyled `.section` chrome by overriding properties should set the
21
+ tokens instead (see the palette reference's Section table).
22
+
23
+ ### Added
24
+
25
+ - **`.dc-cards-two-col`**: on any ancestor (`@specialty`, `@chapter`,
26
+ `@page`, `@section`), every skill card inside gets a two-column body.
27
+ This is the Field Guide's book-wide form as an opt-in. A card's own
28
+ `.dc-two-col`, or `.dc-allow-split`, keeps its own form.
29
+ - **`.dc-snug`**: tighter paragraph and list-item spacing on a section or
30
+ page, for one that would otherwise overflow by a line or two (from the
31
+ Field Guide's `.fg-snug`).
32
+ - **Split skill cards keep their lead-ins with what follows.**
33
+ `.dc-specialty .dc-skill-card.dc-allow-split` keeps its tab, first
34
+ blocks and lead-in paragraphs with the next block (from the Field
35
+ Guide's own sheet).
36
+ - **Section tokens.** A section's panel, shadow and padding now come from
37
+ tokens (`--dc-section-surface`, `--dc-section-shadow`,
38
+ `--dc-section-pad-*`), as does whether a box may split
39
+ (`--dc-section-break-inside`, `--dc-alert-break-inside`). Variants and
40
+ page templates set tokens instead of cancelling properties.
41
+ - **`test/integrity.test.js`**, which checks that:
42
+ - every class the books use is styled;
43
+ - every token that is read, or that the palette reference documents,
44
+ is declared;
45
+ - each stylesheet keeps its stated contract.
46
+
47
+ ### Changed
48
+
49
+ - **Tested against gutterpress 0.11.15** (stable; was 0.11.15-alpha.1).
50
+ - **CSS quick wins from an architecture review.**
51
+ - New tokens: `--shadow-ink` (the opaque wall-shadow colour, written
52
+ out five times before) and four exact-value `--tint-*` mix sources
53
+ for the literal `rgb()` colours inside `color-mix()`.
54
+ - `--dc-section-tab-overlap` and `--dc-section-tab-indent` are now
55
+ public `:root` tokens.
56
+ - The TOC/credits masthead `h1` is now one rule instead of two.
57
+ - Dead declarations are gone: the `--shadow-poster` layer a specialty
58
+ card's own `clip-path` clipped away, `page-break-inside`, an empty
59
+ rule, a no-op height reset, three `opacity: 1`, and the
60
+ `break-before: always` Chromium ignores on learning paths.
61
+ - `dc-native.css` loses its tombstones and is renumbered §1–8.
62
+ - Pixel-identical in both books, except the even specialty cards,
63
+ whose left border is now `1.5pt` like the rest (was `1.5px`).
64
+
65
+ - **Section styling is opt-in per variant, not cancelled by a central list.**
66
+ - `.dc-plain`, `.dc-tabbed`, `.dc-column-panel` and `.dc-card-grid` set
67
+ the section tokens.
68
+ - The header bar's negative margins are derived from the padding.
69
+ - The shared page templates (intro, credits, chapter opener) own their
70
+ styling in `page-templates.css`; the chapter opener moves there from
71
+ `section.css`.
72
+ - Pixel-identical in both books.
73
+ - **The credits colophon shows its 4px front-matter rail again.** A rule in
74
+ `dc-native.css` had overridden it. This is the one visible change, on
75
+ each book's credits page.
76
+ - **Box splitting is decided in one place.**
77
+ - Multi-column runs and `.dc-allow-split` set the break-inside tokens.
78
+ - This replaces an avoid → auto → avoid override chain.
79
+
80
+ ### Removed
81
+
82
+ - **`.dc-printer-page` and its `@page printer-blank`** (deprecated in
83
+ 1.1.1). gutterpress 0.11.15's `dtrpg` preset pads the interior to the
84
+ 4-page signature and reserves the blank last page itself, so a book
85
+ needs neither the marker nor its own `print.signature`. The Field
86
+ Guide, built on 0.11.15 without either, keeps its 232 pages
87
+ pixel-identical and still ends on four blank pages.
88
+ - `--shadow-tint`, and `.dc-roll-the-die`'s `box-shadow: var(--shadow-tint)`:
89
+ a bare colour is not a valid shadow, so it never rendered.
90
+ - `.dc-suppress-footer` and its `@page clean` (and the design guide's
91
+ mirror of it): no book used footer suppression.
92
+ - The design guide's dual specialist and generalist skill-tree specimens
93
+ (Variant Gallery; The Specialty System's "One source" section, now
94
+ "eight shapes"). Those two specialties take their skills from the other
95
+ eight and have no trees of their own, so the specimens printed a
96
+ generic `PATH1` sticker for something that cannot exist.
97
+
98
+ ### Fixed
99
+
100
+ - The catalog's glossary entries: a glossary item is a plain paragraph
101
+ inside `@glossary`, and no doc or gallery page writes `.dc-terms-item`
102
+ any more, so `glossary-item-authored` is retired.
103
+
10
104
  ## [1.1.1] - 2026-10-08
11
105
 
12
106
  **Notes for books upgrading from 1.1.0:**
package/components.yaml CHANGED
@@ -234,11 +234,11 @@ components:
234
234
  - name: glossary
235
235
  status: live
236
236
  origin: plugin
237
- recipe: "@glossary … @end-glossary (the macro is used by neither book; the raw <div class=\"dc-terms\"> wrapper is)"
237
+ recipe: "@glossary … @end-glossary (items are plain `**term** — gloss` paragraphs)"
238
238
  emits: div.dc-terms
239
239
  css: styles/components/images.css
240
240
  breaks: "break-inside: avoid"
241
- notes: "CSS styles the children as .dc-terms .dc-item (see glossary-item); the docs and gallery author .dc-terms-item instead (see glossary-item-authored)."
241
+ notes: "Used by the design guide (06-panels-and-cards). Items take no class of their own; the old item classes are retired (glossary-item, glossary-item-authored)."
242
242
 
243
243
  - name: outcome
244
244
  status: live
@@ -602,8 +602,8 @@ components:
602
602
  origin: author
603
603
  recipe: "@skill {.dc-allow-split} or @section .dc-allow-split"
604
604
  emits: .dc-allow-split (on the skill card or section it is written on)
605
- css: styles/components/section.css
606
- breaks: "break-inside: auto — opts a section or skill card out of the default avoid"
605
+ css: [styles/components/section.css, styles/components/cards.css]
606
+ breaks: "break-inside: auto — opts a section or skill card out of the default avoid. A split specialty card also keeps its first two blocks, and any lead-in (ability row, bold-only line, paragraph before a list or table), with what follows (break-after: avoid)"
607
607
  notes: "The plugin reads this class (to drop data-break-inside=avoid) but never adds it."
608
608
 
609
609
  - name: two-col
@@ -614,6 +614,22 @@ components:
614
614
  css: styles/components/cards.css
615
615
  breaks: "list items and paragraphs break-inside: avoid within the columns"
616
616
 
617
+ - name: cards-two-col
618
+ status: live
619
+ origin: author
620
+ recipe: "@specialty .augmerc .dc-cards-two-col (or on @chapter / @page / @section)"
621
+ emits: .dc-cards-two-col (on the ancestor it is written on; styles the .dc-skill-card inside it)
622
+ css: styles/components/cards.css
623
+ breaks: "list items break-inside: avoid; a paragraph may break between columns. Flavor line, ability rows, tables, sub-heads and rules span both columns. A card with .dc-allow-split stays single-column; a card with its own .dc-two-col keeps the per-card form"
624
+
625
+ - name: snug
626
+ status: live
627
+ origin: author
628
+ recipe: "@section .dc-snug / @page .dc-snug"
629
+ emits: .dc-snug (on the section or page it is written on)
630
+ css: styles/page-templates.css
631
+ notes: "Paragraph and list-item margin-bottom drops to 0.04in so a section or page that overflows by a line or two fits. Type size and leading are untouched."
632
+
617
633
  - name: plain
618
634
  status: live
619
635
  origin: author
@@ -631,15 +647,6 @@ components:
631
647
  breaks: "break-before: page; page: full"
632
648
  notes: "Used by SysOps (chapter-00); the design guide documents it in a fenced example (08-page-templates)."
633
649
 
634
- - name: printer-page
635
- status: live
636
- origin: author
637
- recipe: "@page .dc-printer-page (the last marker of a book's last chapter)"
638
- emits: div.page.dc-printer-page
639
- css: [styles/page-rules.css, styles/dc-native.css]
640
- breaks: "page: printer-blank; break-before: page"
641
- notes: "DEPRECATED in 1.1.1: gutterpress 0.11.15+ reserves the blank last page itself (dtrpg preset, `print.reserveLastPage`). A completely blank final page — no wall, no footer — kept so books that still use it build unchanged. The Field Guide still ends with it (chapter-05) until it builds on a stable gutterpress 0.11.15; drop it then."
642
-
643
650
  - name: img-float
644
651
  status: live
645
652
  origin: author
@@ -655,9 +662,9 @@ components:
655
662
  recipe: "@section (bare; core markers.js emits the wrapper)"
656
663
  emits: div.section
657
664
  css: styles/components/section.css
658
- tokens: [--dc-section-bg, --dc-section-accent]
665
+ tokens: [--dc-section-bg, --dc-section-accent, --dc-section-surface, --dc-section-shadow, --dc-section-pad-top, --dc-section-pad-right, --dc-section-pad-bottom, --dc-section-pad-left]
659
666
  breaks: "break-inside: avoid (core MARKER_CSS)"
660
- notes: "The panel chrome is opt-out; .dc-plain is the escape."
667
+ notes: "Panel chrome is token-driven: variants and templates set --dc-section-surface/-shadow/-pad-* on their own rule; .dc-plain turns both layers off."
661
668
 
662
669
  - name: chapter-opener
663
670
  status: live
@@ -675,16 +682,21 @@ components:
675
682
  - --dc-chapter-opener-pad-right
676
683
  notes: "There is no @chapter-opener macro."
677
684
 
678
- # ── Author classes currently unused by the books ──────────────────────────────
685
+ # ── Retired: no CSS, no emission, no use (tombstone comments only) ─────
686
+ - name: printer-page
687
+ status: retired
688
+ origin: author
689
+ recipe: "@page .dc-printer-page (the last marker of a book's last chapter)"
690
+ emits: div.page.dc-printer-page
691
+ notes: "Removed in 1.1.2 with its @page printer-blank: gutterpress 0.11.15's dtrpg preset pads to the 4-page signature and reserves the blank last page itself (print.reserveLastPage)."
692
+
679
693
  - name: suppress-footer
680
- status: unused
694
+ status: retired
681
695
  origin: author
682
696
  recipe: "@page .dc-suppress-footer"
683
697
  emits: div.page.dc-suppress-footer
684
- css: styles/page-rules.css
685
- breaks: "page: clean"
698
+ notes: "Removed 2026-10-08 with its `@page clean` (page-rules.css, and the design guide's mirror): no book used it."
686
699
 
687
- # ── Retired: no CSS, no emission, no use (tombstone comments only) ─────
688
700
  - name: cover-page
689
701
  status: retired
690
702
  origin: author
@@ -813,6 +825,13 @@ components:
813
825
  emits: [.dc-gear-entry, div.section.dc-gear-list]
814
826
  notes: "Removed 2026-08-21 (data.css GEAR ENTRY tombstone); neither could ever match what @gear emits."
815
827
 
828
+ - name: glossary-item-authored
829
+ status: retired
830
+ origin: author
831
+ recipe: "raw <div class=\"dc-terms-item\"> inside .dc-terms"
832
+ emits: div.dc-terms-item
833
+ notes: "Never styled, and no doc or gallery page writes it any more (2026-10-08): a glossary item is a plain paragraph inside @glossary."
834
+
816
835
  # ── Unimplemented: documented or authored, never built ────────────────
817
836
  - name: skill-card-continuation-marker
818
837
  status: unimplemented
@@ -821,11 +840,4 @@ components:
821
840
  emits: [.dc-card-cont-marker, .dc-card-fwd-marker]
822
841
  notes: "Nothing ever emitted these; they needed a runtime script hook gutterpress does not have (cards.css comment, removed 2026-07-25). The docs describing them are stale."
823
842
 
824
- - name: glossary-item-authored
825
- status: unimplemented
826
- origin: author
827
- recipe: "raw <div class=\"dc-terms-item\"> inside .dc-terms (as the docs and gallery write it)"
828
- emits: div.dc-terms-item
829
- notes: "No CSS has ever styled .dc-terms-item — images.css styles .dc-terms .dc-item. The gallery specimen renders unstyled. Resolve by renaming one side; a separate decision."
830
-
831
843
  # Classes a book uses that are not components.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "gp-dimm-city",
3
- "version": "1.1.1",
3
+ "version": "1.1.2",
4
4
  "description": "Dimm City design system for Gutterpress: the markdown-it macros (@skill, @specialty, @learning-path, @callout, …), print stylesheets, design tokens, fonts and page templates the Dimm City TTRPG books are set in.",
5
5
  "type": "module",
6
6
  "main": "plugin.js",
@@ -68,7 +68,7 @@
68
68
  "pack:check": "npm pack --dry-run"
69
69
  },
70
70
  "devDependencies": {
71
- "gutterpress": "0.11.15-alpha.1",
71
+ "gutterpress": "0.11.15",
72
72
  "markdown-it": "^14.1.0"
73
73
  },
74
74
  "peerDependencies": {
@@ -100,7 +100,7 @@
100
100
  line-height: var(--lh-normal);
101
101
  padding: var(--space-lg) var(--space-xl);
102
102
  margin-top: var(--dc-alert-margin-top);
103
- break-inside: avoid;
103
+ break-inside: var(--dc-alert-break-inside);
104
104
  /* Alerts are full-width callouts that interrupt the reading flow; they
105
105
  should NEVER overlap a preceding right-floated image (observed 2026-05-25
106
106
  with the portrait in the citizen-file intro). Block elements don't wrap
@@ -7,8 +7,6 @@
7
7
  --dc-card-surface → card body background (default --paper-cream)
8
8
  --dc-card-tab-bg → tab background (default --ink-dark)
9
9
  --dc-card-tab-title-color → tab title text color (default --paper-cream)
10
- --dc-card-tier-color → tier-badge fill (default --hud-magenta)
11
- --dc-card-tier-border → tier-badge border (default --hud-magenta)
12
10
  --dc-card-body-mark → decorative ::before mark color (default --crimson)
13
11
  Specialty themes override these via .dc-specialty.<name> .dc-skill-card { }.
14
12
  Adding a new specialty: copy a sibling block (.dc-specialty.augmerc .dc-skill-card)
@@ -258,7 +256,7 @@
258
256
  right: calc(-2pt - 2px);
259
257
  bottom: calc(-3pt - 2px);
260
258
  left: calc(2pt - 2px);
261
- background: color-mix(in srgb, #000 28%, var(--wall-tone));
259
+ background: var(--shadow-ink);
262
260
  clip-path: var(--dc-skill-body-shape);
263
261
  z-index: -4;
264
262
  }
@@ -284,15 +282,6 @@
284
282
  z-index: -2;
285
283
  }
286
284
 
287
- /* Two-column body variant for short skill cards. Applied via
288
- `@skill {.dc-two-col}` in markdown. The .dc-card-inner content flows in
289
- 2 columns so a 4in single-column skill becomes ~2in tall, doubling
290
- horizontal packing density. Suitable for skills with shorter mechanics
291
- text (no large tables, no outcomes ladder). */
292
- .dc-skill-card.dc-two-col .dc-card-inner {
293
- /* column-count/gap/fill owned by page-templates.css */
294
- }
295
-
296
285
  /* `.section.dc-rules-definition` (this file's columns block + the chrome/
297
286
  tokens/doc block in components/*.css) and `.two-column-list` (both here
298
287
  and its two tombstone bodies in components/*.css) were here and are
@@ -325,7 +314,71 @@
325
314
  .dc-skill-card.dc-two-col .dc-card-inner ul > li,
326
315
  .dc-skill-card.dc-two-col .dc-card-inner p {
327
316
  break-inside: avoid;
328
- page-break-inside: avoid;
317
+ }
318
+
319
+ /* ── SKILL-CARD TWO-COLUMN FORM, BY ANCESTOR ───────────────────────────────── */
320
+ /* `.dc-cards-two-col` on ANY ancestor of skill cards (a `@specialty` marker,
321
+ a `@chapter`/`@page`, a `@section`) makes every skill card inside it
322
+ two-column: `@specialty .augmerc .dc-cards-two-col`. It is the book-wide
323
+ counterpart of the per-card `.dc-two-col` above, and the two differ on
324
+ purpose. Here only running text (paragraphs and lists) flows in the two
325
+ columns, a paragraph MAY break between them so the columns balance, and a
326
+ list item stays whole. Everything else spans the card: the flavor line,
327
+ ability rows (AP pill + text: in a column they ran taller than the whole
328
+ card and could not balance), tables, outcome ladders, alerts, sub-heads
329
+ and rules. Per-card `.dc-two-col` instead keeps every paragraph whole and
330
+ spans only tables.
331
+ A card with its own `.dc-two-col` keeps the per-card form entirely: every
332
+ rule below excludes it, so its own, stricter form wins over the inherited
333
+ one. A card marked `.dc-allow-split` stays single-column: a balanced
334
+ multicol that fragments across pages leaves the first fragment's right
335
+ column empty.
336
+ Column authority for both forms is this file (COLUMNS_ALLOWLIST in
337
+ test/integrity.test.js): this is component-internal layout of the card
338
+ body, not a page or section template. */
339
+ .dc-cards-two-col .dc-skill-card:not(.dc-two-col, .dc-allow-split) > .dc-card-body > .dc-card-inner {
340
+ column-count: 2;
341
+ column-gap: 16px;
342
+ }
343
+
344
+ /* The second selector: a text block left alone between two spanning pieces
345
+ (or at either end) cannot balance and would leave a column empty. */
346
+ .dc-cards-two-col .dc-skill-card:not(.dc-two-col, .dc-allow-split) .dc-card-inner > :not(ul, ol, p:not(.dc-flavor)),
347
+ .dc-cards-two-col .dc-skill-card:not(.dc-two-col, .dc-allow-split) .dc-card-inner > :is(:first-child, :not(ul, ol, p:not(.dc-flavor)) + *):is(:last-child, :has(+ :not(ul, ol, p))) {
348
+ column-span: all;
349
+ }
350
+
351
+ .dc-cards-two-col .dc-skill-card:not(.dc-two-col, .dc-allow-split) .dc-card-inner li {
352
+ break-inside: avoid;
353
+ }
354
+
355
+ /* An ability row under text that runs in the two columns sat flush on its
356
+ last line: the column row drops that text's bottom margin at the
357
+ spanning row. The row is moved down, not given a margin: a 0.08in margin
358
+ cost two pages in the Field Guide and split a card across a page turn, and
359
+ 0.04in cost one page (measured). */
360
+ .dc-cards-two-col .dc-skill-card:not(.dc-two-col, .dc-allow-split) .dc-card-inner > :is(p:not(.dc-flavor), ul, ol) + :is(p:not(.dc-flavor), ul, ol) + .dc-ability {
361
+ position: relative;
362
+ top: 0.06in;
363
+ }
364
+
365
+ /* A split card (`.dc-allow-split`) never opens with just its tab and a line
366
+ or two at a page foot: its first two blocks (the flavor line and a
367
+ possibly one-line ability) stay with the first two lines of what follows,
368
+ or the card moves to the next page. */
369
+ .dc-specialty .dc-skill-card.dc-allow-split .dc-card-inner > :nth-child(-n+2) {
370
+ break-after: avoid;
371
+ }
372
+
373
+ /* In a split card a lead-in stays with what it introduces: an ability row
374
+ with its first lines, a bold-only pseudo-heading with the paragraph under
375
+ it, a paragraph with the list or table it opens. CSS cannot see text
376
+ nodes, so `strong:only-child` also takes a paragraph whose only markup is
377
+ one bold run. A last child is left out: its break-after would pass up to
378
+ the card and glue the next path banner to it. */
379
+ .dc-specialty .dc-skill-card.dc-allow-split .dc-card-inner > :is(.dc-ability, p:has(> strong:only-child)):not(:last-child),
380
+ .dc-specialty .dc-skill-card.dc-allow-split .dc-card-inner > p:has(+ :is(ul, ol, table)) {
381
+ break-after: avoid;
329
382
  }
330
383
 
331
384
  /* Horizontal skill placement — not currently attempted. `.dc-specialty
@@ -373,7 +426,7 @@
373
426
 
374
427
  .dc-skill-card.dc-highlight .dc-highlight-body > .dc-card-inner::after {
375
428
  background:
376
- linear-gradient(to bottom, color-mix(in srgb, rgb(180 40 40) 10%, var(--dc-card-surface)) 0%, var(--dc-card-surface) 45%),
429
+ linear-gradient(to bottom, color-mix(in srgb, var(--tint-brick-red) 10%, var(--dc-card-surface)) 0%, var(--dc-card-surface) 45%),
377
430
  var(--dc-card-surface);
378
431
  }
379
432
 
@@ -436,7 +489,6 @@
436
489
  vertical-align: middle;
437
490
  background-color: var(--paper-aged);
438
491
  padding: 0.5em;
439
- box-shadow: var(--shadow-tint);
440
492
  border: 2px dashed var(--dc-roll-the-die-border);
441
493
  }
442
494
 
@@ -140,7 +140,6 @@
140
140
  bottom: 0;
141
141
  height: 3px;
142
142
  background: var(--hud-magenta);
143
- opacity: 1;
144
143
  width: auto;
145
144
  }
146
145
 
@@ -300,7 +299,6 @@
300
299
  font-weight: 700;
301
300
  letter-spacing: 0.03em;
302
301
  color: var(--dc-outcome-key-color);
303
- opacity: 1;
304
302
  display: block;
305
303
  line-height: 1;
306
304
  white-space: nowrap;
@@ -781,13 +779,6 @@
781
779
  max-width: 7.25in;
782
780
  }
783
781
 
784
- /* Universal card layout fixes — apply to any book using dc-skill-card. */
785
-
786
- :is(.dc-skill-card, .dc-skill-card .dc-card-body) {
787
- height: auto;
788
- min-height: 0;
789
- }
790
-
791
782
  /* `.two-column-list` (this tombstone + the base one below + both real
792
783
  rules in page-templates.css) is DELETED (2026-09-02) — 0 uses, 0
793
784
  emissions; see page-templates.css's note at its old location. */