@presentation-md/export 1.24.0 → 1.24.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/dist/index.js CHANGED
@@ -16,9 +16,11 @@ const LAYOUT_NAME = "PMD_16x9";
16
16
  */
17
17
  export async function buildPptx(deck, theme, opts = {}) {
18
18
  const warnings = [];
19
+ let currentSlide = 0;
19
20
  const warn = (msg) => {
20
- warnings.push(msg);
21
- opts.onWarn?.(msg);
21
+ const prefixed = currentSlide > 0 && !/^Slide\s+\d+/i.test(msg) ? `Slide ${currentSlide}: ${msg}` : msg;
22
+ warnings.push(prefixed);
23
+ opts.onWarn?.(prefixed);
22
24
  };
23
25
  let working = deck;
24
26
  if (opts.prefetchImages) {
@@ -44,6 +46,7 @@ export async function buildPptx(deck, theme, opts = {}) {
44
46
  pptx.author = "presentation-md";
45
47
  const slides = Array.isArray(working.slides) ? working.slides : [];
46
48
  slides.forEach((slideData, i) => {
49
+ currentSlide = i + 1;
47
50
  const slide = pptx.addSlide();
48
51
  renderSlide(slide, ctx, slideData);
49
52
  const notes = typeof slideData.notes === "string" ? slideData.notes.trim() : "";
@@ -66,6 +69,7 @@ export async function buildPptx(deck, theme, opts = {}) {
66
69
  });
67
70
  }
68
71
  });
72
+ currentSlide = 0;
69
73
  return { pptx, slideCount: slides.length, warnings };
70
74
  }
71
75
  /** Serialize the deck to a PPTX ArrayBuffer (works in Node and the browser). */
package/dist/index.js.map CHANGED
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,SAAS,EAAa,MAAM,WAAW,CAAC;AACjD,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAC5C,OAAO,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAE3C,OAAO,EACL,kBAAkB,GAGnB,MAAM,sBAAsB,CAAC;AAe9B,OAAO,EAAE,kBAAkB,EAAE,CAAC;AA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C,CAAC;IACH,YAAY,GAAG,CAAC,CAAC;IAEjB,OAAO,EAAE,IAAI,EAAE,UAAU,EAAE,MAAM,CAAC,MAAM,EAAE,QAAQ,EAAE,CAAC;AACvD,CAAC;AAED,gFAAgF;AAChF,MAAM,CAAC,KAAK,UAAU,qBAAqB,CACzC,IAAc,EACd,KAAoB,EACpB,IAAkB;IAElB,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,SAAS,CAAC,IAAI,EAAE,KAAK,EAAE,IAAI,CAAC,CAAC;IACpD,OAAO,CAAC,MAAM,IAAI,CAAC,KAAK,CAAC,EAAE,UAAU,EAAE,aAAa,EAAE,CAAC,CAAgB,CAAC;AAC1E,CAAC;AAED,+CAA+C;AAC/C,MAAM,CAAC,KAAK,UAAU,gBAAgB,CACpC,IAAc,EACd,KAAoB,EACpB,IAAkB;IAElB,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,SAAS,CAAC,IAAI,EAAE,KAAK,EAAE,IAAI,CAAC,CAAC;IACpD,OAAO,CAAC,MAAM,IAAI,CAAC,KAAK,CAAC,EAAE,UAAU,EAAE,YAAY,EAAE,CAAC,CAAW,CAAC;AACpE,CAAC;AAED,qDAAqD;AACrD,MAAM,CAAC,KAAK,UAAU,cAAc,CAClC,IAAc,EACd,KAAoB,EACpB,IAAkB;IAElB,MAAM,EAAE,IAAI,EAAE,GAAG,MAAM,SAAS,CAAC,IAAI,EAAE,KAAK,EAAE,IAAI,CAAC,CAAC;IACpD,OAAO,CAAC,MAAM,IAAI,CAAC,KAAK,CAAC,EAAE,UAAU,EAAE,MAAM,EAAE,CAAC,CAAS,CAAC;AAC5D,CAAC"}
package/dist/layouts.js CHANGED
@@ -1,4 +1,16 @@
1
1
  import { candyMarqueeText } from "@presentation-md/core/candy-marquee";
2
+ /** Hard 0-blur card offset shadows from HTML neobrutalist peers (raw-grid / hard-bento / …). */
3
+ function cardHardOffset(ctx) {
4
+ if (ctx.themeName === "raw-grid")
5
+ return { color: "0A0A0A", size: 0.045 };
6
+ if (ctx.themeName === "genz-bento")
7
+ return { color: ctx.colors.text, size: 0.045 };
8
+ if (ctx.themeName === "creative-mode")
9
+ return { color: ctx.colors.text, size: 0.045 };
10
+ if (ctx.themeName === "block-frame")
11
+ return { color: "000000", size: 0.065 };
12
+ return null;
13
+ }
2
14
  /** Candy-pop cards use hard ink strokes + plump radius (candy-blob `.card`). */
3
15
  function cardStroke(ctx, opts = {}) {
4
16
  if (ctx.themeName === "candy-pop") {
@@ -68,9 +80,9 @@ function cardStroke(ctx, opts = {}) {
68
80
  if (ctx.themeName === "mat") {
69
81
  return { color: "1E2820", width: opts.hero || opts.highlighted ? 1.5 : 1.25 };
70
82
  }
71
- // hard-bento (genz-bento) cards: 2.5px ink
83
+ // hard-bento (genz-bento) cards: 2.5px ink + hard offset
72
84
  if (ctx.themeName === "genz-bento") {
73
- return { color: ctx.colors.text, width: opts.hero || opts.highlighted ? 2.75 : 2.5 };
85
+ return { color: ctx.colors.text, width: opts.hero || opts.highlighted ? 2.9 : 2.65 };
74
86
  }
75
87
  // acid-block (brutalist-acid) cards: 2px accent, square
76
88
  if (ctx.themeName === "brutalist-acid") {
@@ -80,15 +92,15 @@ function cardStroke(ctx, opts = {}) {
80
92
  if (ctx.themeName === "bauhaus") {
81
93
  return { color: ctx.colors.text, width: opts.hero || opts.highlighted ? 2.25 : 2 };
82
94
  }
83
- // neo-grid-panels / bold-poster-ink / tri-tone-blocks cards: 2px ink, square
95
+ // neo-grid-panels / bold-poster-ink / tri-tone-blocks cards: hard ink, square
84
96
  if (ctx.themeName === "neo-grid-bold" ||
85
97
  ctx.themeName === "bold-poster" ||
86
98
  ctx.themeName === "editorial-tri-tone") {
87
- return { color: ctx.colors.text, width: opts.hero || opts.highlighted ? 2.25 : 2 };
99
+ return { color: ctx.colors.text, width: opts.hero || opts.highlighted ? 2.5 : 2.25 };
88
100
  }
89
- // raw-grid-brutal cards: 3px ink, square
101
+ // raw-grid-brutal cards: 3px ink + hard offset (via cardHardOffset), square
90
102
  if (ctx.themeName === "raw-grid") {
91
- return { color: "0A0A0A", width: opts.hero || opts.highlighted ? 3.25 : 3 };
103
+ return { color: "0A0A0A", width: opts.hero || opts.highlighted ? 3.5 : 3.25 };
92
104
  }
93
105
  // creative-voltage-split cards: 1px neon accent, square
94
106
  if (ctx.themeName === "creative-voltage") {
@@ -266,6 +278,19 @@ function cardStroke(ctx, opts = {}) {
266
278
  function drawCardFace(slide, ctx, x, y, w, h, fill, opts = {}) {
267
279
  const stroke = cardStroke(ctx, opts);
268
280
  const radius = cardRadius(ctx);
281
+ const offset = cardHardOffset(ctx);
282
+ if (offset && !(stroke.topRule || stroke.leftRule)) {
283
+ // Paint hard offset plate first (HTML box-shadow Nx N 0 ink).
284
+ slide.addShape(ctx.shapeRoundRect, {
285
+ x: x + offset.size,
286
+ y: y + offset.size,
287
+ w,
288
+ h,
289
+ fill: { color: offset.color },
290
+ line: { color: offset.color, width: 0 },
291
+ rectRadius: radius,
292
+ });
293
+ }
269
294
  if (stroke.topRule || stroke.leftRule) {
270
295
  slide.addShape(ctx.shapeRoundRect, {
271
296
  x,
@@ -3390,25 +3415,25 @@ function paintSlideChrome(slide, ctx, data) {
3390
3415
  }
3391
3416
  }
3392
3417
  if (theme === "swiss-typographic") {
3393
- // Light modular grid + signal-red left rail (swiss-grid).
3394
- for (let i = 1; i < 12; i++) {
3418
+ // Denser modular grid (~64px) + thicker signal-red left rail (swiss-grid).
3419
+ for (let i = 1; i < 20; i++) {
3395
3420
  slide.addShape(ctx.shapeRoundRect, {
3396
- x: (ctx.width / 12) * i,
3421
+ x: (ctx.width / 20) * i,
3397
3422
  y: 0,
3398
- w: 0.012,
3423
+ w: 0.011,
3399
3424
  h: ctx.height,
3400
- fill: { color: ctx.colors.border, transparency: 55 },
3425
+ fill: { color: ctx.colors.border, transparency: 48 },
3401
3426
  line: { color: ctx.colors.border, width: 0 },
3402
3427
  rectRadius: 0,
3403
3428
  });
3404
3429
  }
3405
- for (let i = 1; i < 8; i++) {
3430
+ for (let i = 1; i < 12; i++) {
3406
3431
  slide.addShape(ctx.shapeRoundRect, {
3407
3432
  x: 0,
3408
- y: (ctx.height / 8) * i,
3433
+ y: (ctx.height / 12) * i,
3409
3434
  w: ctx.width,
3410
- h: 0.012,
3411
- fill: { color: ctx.colors.border, transparency: 55 },
3435
+ h: 0.011,
3436
+ fill: { color: ctx.colors.border, transparency: 48 },
3412
3437
  line: { color: ctx.colors.border, width: 0 },
3413
3438
  rectRadius: 0,
3414
3439
  });
@@ -3416,12 +3441,22 @@ function paintSlideChrome(slide, ctx, data) {
3416
3441
  slide.addShape(ctx.shapeRoundRect, {
3417
3442
  x: 0,
3418
3443
  y: 0,
3419
- w: 0.08,
3444
+ w: 0.1,
3420
3445
  h: ctx.height,
3421
3446
  fill: { color: ctx.colors.accent },
3422
3447
  line: { color: ctx.colors.accent, width: 0 },
3423
3448
  rectRadius: 0,
3424
3449
  });
3450
+ // Quiet outer hairline (HTML border).
3451
+ slide.addShape(ctx.shapeRoundRect, {
3452
+ x: 0.1,
3453
+ y: 0.08,
3454
+ w: ctx.width - 0.18,
3455
+ h: ctx.height - 0.16,
3456
+ fill: { color: ctx.colors.bg, transparency: 100 },
3457
+ line: { color: ctx.colors.border, width: 0.9 },
3458
+ rectRadius: 0,
3459
+ });
3425
3460
  }
3426
3461
  if (theme === "ft-editorial") {
3427
3462
  // Broadsheet masthead + double rule + quiet outer frame + accent mid stub.
@@ -3652,6 +3687,7 @@ function paintSlideChrome(slide, ctx, data) {
3652
3687
  }
3653
3688
  if (theme === "genz-bento") {
3654
3689
  // Hard border + 10px offset shadow strips + accent2 corner blot (hard-bento).
3690
+ // Cards get 4px hard offsets via cardHardOffset.
3655
3691
  const shadow = 0.12;
3656
3692
  slide.addShape(ctx.shapeRoundRect, {
3657
3693
  x: ctx.width - shadow,
@@ -3672,22 +3708,32 @@ function paintSlideChrome(slide, ctx, data) {
3672
3708
  rectRadius: 0,
3673
3709
  });
3674
3710
  slide.addShape(ctx.shapeRoundRect, {
3675
- x: 0.12,
3676
- y: 0.12,
3677
- w: ctx.width - 0.24,
3678
- h: ctx.height - 0.24,
3711
+ x: 0.1,
3712
+ y: 0.1,
3713
+ w: ctx.width - 0.2,
3714
+ h: ctx.height - 0.2,
3679
3715
  fill: { color: ctx.colors.bg, transparency: 100 },
3680
- line: { color: ctx.colors.text, width: 2.5 },
3716
+ line: { color: ctx.colors.text, width: 3 },
3681
3717
  rectRadius: 0,
3682
3718
  });
3683
3719
  slide.addShape(ctx.shapeOval, {
3684
- x: ctx.width - 1.6,
3685
- y: -0.5,
3686
- w: 1.8,
3687
- h: 1.8,
3688
- fill: { color: ctx.colors.accent2, transparency: 45 },
3720
+ x: ctx.width - 1.75,
3721
+ y: -0.55,
3722
+ w: 2.05,
3723
+ h: 2.05,
3724
+ fill: { color: ctx.colors.accent2, transparency: 38 },
3689
3725
  line: { color: ctx.colors.accent2, width: 0 },
3690
3726
  });
3727
+ // Secondary accent chip (HTML hard-bento energy).
3728
+ slide.addShape(ctx.shapeRoundRect, {
3729
+ x: ctx.width - 1.35 - shadow,
3730
+ y: ctx.height - 0.95 - shadow,
3731
+ w: 0.55,
3732
+ h: 0.55,
3733
+ fill: { color: ctx.colors.accent, transparency: 12 },
3734
+ line: { color: ctx.colors.text, width: 2 },
3735
+ rectRadius: 0.08,
3736
+ });
3691
3737
  }
3692
3738
  if (theme === "heritage-editorial") {
3693
3739
  // Parchment wash + quiet hairlines + mid stub (heritage-wash).
@@ -4006,8 +4052,8 @@ function paintSlideChrome(slide, ctx, data) {
4006
4052
  });
4007
4053
  }
4008
4054
  if (theme === "neo-grid-bold") {
4009
- // Modular grid + lemon corner panel + hard border + 8px accent offset
4010
- // shadow (neo-grid-panels).
4055
+ // Denser modular grid (~80px) + lemon corner panel + hard 3pt border +
4056
+ // 8px accent offset shadow (neo-grid-panels).
4011
4057
  const shadow = 0.1;
4012
4058
  slide.addShape(ctx.shapeRoundRect, {
4013
4059
  x: ctx.width - shadow,
@@ -4027,24 +4073,24 @@ function paintSlideChrome(slide, ctx, data) {
4027
4073
  line: { color: ctx.colors.accent, width: 0 },
4028
4074
  rectRadius: 0,
4029
4075
  });
4030
- for (let i = 1; i < 10; i++) {
4076
+ for (let i = 1; i < 16; i++) {
4031
4077
  slide.addShape(ctx.shapeRoundRect, {
4032
- x: (ctx.width / 10) * i,
4078
+ x: (ctx.width / 16) * i,
4033
4079
  y: 0,
4034
4080
  w: 0.012,
4035
4081
  h: ctx.height - shadow,
4036
- fill: { color: ctx.colors.text, transparency: 85 },
4082
+ fill: { color: ctx.colors.text, transparency: 78 },
4037
4083
  line: { color: ctx.colors.text, width: 0 },
4038
4084
  rectRadius: 0,
4039
4085
  });
4040
4086
  }
4041
- for (let i = 1; i < 6; i++) {
4087
+ for (let i = 1; i < 9; i++) {
4042
4088
  slide.addShape(ctx.shapeRoundRect, {
4043
4089
  x: 0,
4044
- y: (ctx.height / 6) * i,
4090
+ y: (ctx.height / 9) * i,
4045
4091
  w: ctx.width - shadow,
4046
4092
  h: 0.012,
4047
- fill: { color: ctx.colors.text, transparency: 85 },
4093
+ fill: { color: ctx.colors.text, transparency: 78 },
4048
4094
  line: { color: ctx.colors.text, width: 0 },
4049
4095
  rectRadius: 0,
4050
4096
  });
@@ -4055,29 +4101,50 @@ function paintSlideChrome(slide, ctx, data) {
4055
4101
  w: ctx.width - 0.08 - shadow,
4056
4102
  h: ctx.height - 0.08 - shadow,
4057
4103
  fill: { color: ctx.colors.bg, transparency: 100 },
4058
- line: { color: ctx.colors.text, width: 2.5 },
4104
+ line: { color: ctx.colors.text, width: 3 },
4059
4105
  rectRadius: 0,
4060
4106
  });
4107
+ // Lemon corner panel (HTML ::after 96px) — always-on for PPTX densify.
4061
4108
  slide.addShape(ctx.shapeRoundRect, {
4062
- x: ctx.width - 1.55 - shadow,
4063
- y: 0.55,
4064
- w: 0.95,
4065
- h: 0.95,
4109
+ x: ctx.width - 1.7 - shadow,
4110
+ y: 0.45,
4111
+ w: 1.15,
4112
+ h: 1.15,
4066
4113
  fill: { color: ctx.colors.accent },
4067
4114
  line: { color: ctx.colors.accent, width: 0 },
4068
4115
  rectRadius: 0,
4069
4116
  });
4117
+ // Ink L registration marks (grid craft).
4118
+ slide.addShape(ctx.shapeRoundRect, {
4119
+ x: 0.22,
4120
+ y: 0.22,
4121
+ w: 0.48,
4122
+ h: 0.028,
4123
+ fill: { color: ctx.colors.text, transparency: 35 },
4124
+ line: { color: ctx.colors.text, width: 0 },
4125
+ rectRadius: 0,
4126
+ });
4127
+ slide.addShape(ctx.shapeRoundRect, {
4128
+ x: 0.22,
4129
+ y: 0.22,
4130
+ w: 0.028,
4131
+ h: 0.48,
4132
+ fill: { color: ctx.colors.text, transparency: 35 },
4133
+ line: { color: ctx.colors.text, width: 0 },
4134
+ rectRadius: 0,
4135
+ });
4070
4136
  }
4071
4137
  if (theme === "bold-poster") {
4072
- // Hard frame + offset shadow every slide; ink top bar; poster block on heroes.
4138
+ // Hard frame + accent-tinted offset shadow every slide; thicker ink top bar;
4139
+ // poster block on heroes (bold-poster-ink HTML uses accent@35% shadow).
4073
4140
  const shadow = 0.11;
4074
4141
  slide.addShape(ctx.shapeRoundRect, {
4075
4142
  x: ctx.width - shadow,
4076
4143
  y: shadow,
4077
4144
  w: shadow,
4078
4145
  h: ctx.height - shadow,
4079
- fill: { color: ctx.colors.text },
4080
- line: { color: ctx.colors.text, width: 0 },
4146
+ fill: { color: ctx.colors.accent },
4147
+ line: { color: ctx.colors.accent, width: 0 },
4081
4148
  rectRadius: 0,
4082
4149
  });
4083
4150
  slide.addShape(ctx.shapeRoundRect, {
@@ -4085,8 +4152,8 @@ function paintSlideChrome(slide, ctx, data) {
4085
4152
  y: ctx.height - shadow,
4086
4153
  w: ctx.width - shadow,
4087
4154
  h: shadow,
4088
- fill: { color: ctx.colors.text },
4089
- line: { color: ctx.colors.text, width: 0 },
4155
+ fill: { color: ctx.colors.accent },
4156
+ line: { color: ctx.colors.accent, width: 0 },
4090
4157
  rectRadius: 0,
4091
4158
  });
4092
4159
  slide.addShape(ctx.shapeRoundRect, {
@@ -4095,26 +4162,38 @@ function paintSlideChrome(slide, ctx, data) {
4095
4162
  w: ctx.width - 0.2,
4096
4163
  h: ctx.height - 0.2,
4097
4164
  fill: { color: ctx.colors.bg, transparency: 100 },
4098
- line: { color: ctx.colors.text, width: 2.25 },
4165
+ line: { color: ctx.colors.text, width: 2.75 },
4099
4166
  rectRadius: 0,
4100
4167
  });
4101
4168
  slide.addShape(ctx.shapeRoundRect, {
4102
4169
  x: 0,
4103
4170
  y: 0,
4104
4171
  w: ctx.width,
4105
- h: 0.14,
4172
+ h: 0.16,
4106
4173
  fill: { color: ctx.colors.accent },
4107
4174
  line: { color: ctx.colors.accent, width: 0 },
4108
4175
  rectRadius: 0,
4109
4176
  });
4110
4177
  if (isHero) {
4111
4178
  slide.addShape(ctx.shapeRoundRect, {
4112
- x: ctx.width * 0.62,
4113
- y: ctx.height * 0.55,
4114
- w: ctx.width * 0.28,
4115
- h: ctx.height * 0.28,
4179
+ x: ctx.width * 0.6,
4180
+ y: ctx.height * 0.52,
4181
+ w: ctx.width * 0.3,
4182
+ h: ctx.height * 0.3,
4116
4183
  fill: { color: ctx.colors.bg2 },
4117
- line: { color: ctx.colors.text, width: 2 },
4184
+ line: { color: ctx.colors.text, width: 2.25 },
4185
+ rectRadius: 0,
4186
+ });
4187
+ }
4188
+ else {
4189
+ // Quiet poster stub on body slides so chrome doesn't go flat.
4190
+ slide.addShape(ctx.shapeRoundRect, {
4191
+ x: ctx.width - 1.35 - shadow,
4192
+ y: ctx.height - 1.15 - shadow,
4193
+ w: 0.85,
4194
+ h: 0.85,
4195
+ fill: { color: ctx.colors.bg2, transparency: 35 },
4196
+ line: { color: ctx.colors.text, width: 1.5 },
4118
4197
  rectRadius: 0,
4119
4198
  });
4120
4199
  }
@@ -4363,7 +4442,8 @@ function paintSlideChrome(slide, ctx, data) {
4363
4442
  });
4364
4443
  }
4365
4444
  if (theme === "brutalist-mono") {
4366
- // Dense mono grid + hard outer frame + 8px ink offset shadow (brutalist-grid).
4445
+ // Denser mono grid (~24px) + hard 3pt outer frame + 8px ink offset shadow
4446
+ // (brutalist-grid).
4367
4447
  const shadow = 0.1;
4368
4448
  slide.addShape(ctx.shapeRoundRect, {
4369
4449
  x: ctx.width - shadow,
@@ -4383,24 +4463,24 @@ function paintSlideChrome(slide, ctx, data) {
4383
4463
  line: { color: ctx.colors.text, width: 0 },
4384
4464
  rectRadius: 0,
4385
4465
  });
4386
- for (let i = 1; i < 16; i++) {
4466
+ for (let i = 1; i < 28; i++) {
4387
4467
  slide.addShape(ctx.shapeRoundRect, {
4388
- x: (ctx.width / 16) * i,
4468
+ x: (ctx.width / 28) * i,
4389
4469
  y: 0,
4390
- w: 0.01,
4470
+ w: 0.009,
4391
4471
  h: ctx.height - shadow,
4392
- fill: { color: ctx.colors.border, transparency: 55 },
4472
+ fill: { color: ctx.colors.border, transparency: 48 },
4393
4473
  line: { color: ctx.colors.border, width: 0 },
4394
4474
  rectRadius: 0,
4395
4475
  });
4396
4476
  }
4397
- for (let i = 1; i < 10; i++) {
4477
+ for (let i = 1; i < 16; i++) {
4398
4478
  slide.addShape(ctx.shapeRoundRect, {
4399
4479
  x: 0,
4400
- y: (ctx.height / 10) * i,
4480
+ y: (ctx.height / 16) * i,
4401
4481
  w: ctx.width - shadow,
4402
- h: 0.01,
4403
- fill: { color: ctx.colors.border, transparency: 55 },
4482
+ h: 0.009,
4483
+ fill: { color: ctx.colors.border, transparency: 48 },
4404
4484
  line: { color: ctx.colors.border, width: 0 },
4405
4485
  rectRadius: 0,
4406
4486
  });
@@ -4411,7 +4491,7 @@ function paintSlideChrome(slide, ctx, data) {
4411
4491
  w: ctx.width - 0.1 - shadow,
4412
4492
  h: ctx.height - 0.1 - shadow,
4413
4493
  fill: { color: ctx.colors.bg, transparency: 100 },
4414
- line: { color: ctx.colors.text, width: 2.5 },
4494
+ line: { color: ctx.colors.text, width: 3 },
4415
4495
  rectRadius: 0,
4416
4496
  });
4417
4497
  }
@@ -4826,9 +4906,9 @@ function paintSlideChrome(slide, ctx, data) {
4826
4906
  });
4827
4907
  }
4828
4908
  if (theme === "raw-grid") {
4829
- // Blush/sage bands + cross rules + hard frame + 6px ink offset shadow
4830
- // (raw-grid-brutal box-shadow is always-on).
4831
- const shadow = 0.08;
4909
+ // Blush/sage bands + cross rules + hard 3pt frame + 6px ink offset shadow
4910
+ // (raw-grid-brutal). Cards get 4px hard offsets via cardHardOffset.
4911
+ const shadow = 0.09;
4832
4912
  slide.addShape(ctx.shapeRoundRect, {
4833
4913
  x: ctx.width - shadow,
4834
4914
  y: shadow,
@@ -4879,7 +4959,7 @@ function paintSlideChrome(slide, ctx, data) {
4879
4959
  x: 0,
4880
4960
  y: ctx.height * 0.28,
4881
4961
  w: ctx.width - shadow,
4882
- h: 0.035,
4962
+ h: 0.04,
4883
4963
  fill: { color: "0A0A0A" },
4884
4964
  line: { color: "0A0A0A", width: 0 },
4885
4965
  rectRadius: 0,
@@ -4887,7 +4967,7 @@ function paintSlideChrome(slide, ctx, data) {
4887
4967
  slide.addShape(ctx.shapeRoundRect, {
4888
4968
  x: ctx.width * 0.22,
4889
4969
  y: 0,
4890
- w: 0.035,
4970
+ w: 0.04,
4891
4971
  h: ctx.height - shadow,
4892
4972
  fill: { color: "0A0A0A" },
4893
4973
  line: { color: "0A0A0A", width: 0 },
@@ -4899,7 +4979,26 @@ function paintSlideChrome(slide, ctx, data) {
4899
4979
  w: ctx.width - 0.08 - shadow,
4900
4980
  h: ctx.height - 0.08 - shadow,
4901
4981
  fill: { color: ctx.colors.bg, transparency: 100 },
4902
- line: { color: "0A0A0A", width: 2.5 },
4982
+ line: { color: "0A0A0A", width: 3 },
4983
+ rectRadius: 0,
4984
+ });
4985
+ // Ink corner blot + sage secondary stub (brutal grid craft).
4986
+ slide.addShape(ctx.shapeRoundRect, {
4987
+ x: ctx.width - 1.25 - shadow,
4988
+ y: ctx.height - 1.15 - shadow,
4989
+ w: 0.72,
4990
+ h: 0.72,
4991
+ fill: { color: "0A0A0A" },
4992
+ line: { color: "0A0A0A", width: 0 },
4993
+ rectRadius: 0,
4994
+ });
4995
+ slide.addShape(ctx.shapeRoundRect, {
4996
+ x: ctx.width - 1.4 - shadow,
4997
+ y: ctx.height - 1.3 - shadow,
4998
+ w: 0.72,
4999
+ h: 0.72,
5000
+ fill: { color: "E5EDD6" },
5001
+ line: { color: "0A0A0A", width: 2 },
4903
5002
  rectRadius: 0,
4904
5003
  });
4905
5004
  }